Comments (9)
Hi @anuj77!
Thanks a lot for that! I'm glad you like the look of my library!
Ummm, not at the moment... The cropper lets you choose a specific aspect ratio to clamp to, but no explicit size limiting yet.
That's definitely a good idea though. I'll leave this issue open to remind me to add that at some point.
If you feel up to it, feel free to try adding it yourself!
from tocropviewcontroller.
This is definitely something I could use as well. My biggest issue with PEPhotoCropEditor was a lack of minimum crop support.
from tocropviewcontroller.
Thanks for the feedback!
I'm still swamped, so I've got no time to look into this myself. Feel free to try it yourself and file a PR! :)
from tocropviewcontroller.
Hey @TimOliver ,
Thanks for the amazing cropping code. Did you got chance to implement the minimum image size limit?
Thanks.
from tocropviewcontroller.
Hi @harishchopra86! Thanks a lot! Glad you're liking it!
Nope, nothing yet sorry! I've been incredibly busy helping my company launch a new thing as of late, so I've only now gotten a chance to start looking at my open source libraries again.
I'm interested in doing this one for the challenge, but there's still a few nitty gritty implementation details to work out:
- What is required to calculate the minimum size the crop box can be when the user resizes it.
- What is required to calculate the maximum zoom a user can pinch-in.
- What happens when the screen rotates.
Honestly, if anyone else wants to try adding it, that would be a huge help. :)
from tocropviewcontroller.
Hi @TimOliver
I had a look into https://realm.io and it is a revolutionary product. Below are my inline thoughts over the image size implementation points:
What is required to calculate the minimum size the crop box can be when the user resizes it.
- I think minimising the size of crop box should be allowed until the image's size(height OR width) is greater then the crop box's size. As soon as the image's height OR width reaches cropbox's size then no more resizing should be allowed.
What is required to calculate the maximum zoom a user can pinch-in.
- Maximum zoom should depend on the quality of the image. While zooming if an image's resolution becomes same as the crop box resolution then zoom should be disabled OR you can provide a constant to set maximum zoom scale.
What happens when the screen rotates.
- If the screen rotates then image and crop box should get resized but their aspect ratio should remain same.
Regards,
Harish
from tocropviewcontroller.
Thanks @harishchopra86! Glad you like the look of it! :)
Haha yeah, you're right in all of those points; what I was referring to was the actual code logic necessary to enforce those types of constraints. It shouldn't be much code... but it's all math. XD
from tocropviewcontroller.
Hi @TimOliver,
I am facing one problem by using this code that is Zoom scale limitation. I want to fix zoom scale because when I zoom my image then it is reduced from actual required image size.
For example :- If I require my image to fit in size 300_450 so I have given crop box with 2:3 aspect ratio and can crop the image in it. But I can keep zooming the image and the zooming is not restricted and at last I get image of very small size like 50_75, etc. So, is there any mechanism by which I can stop image zoom when the image size has reached the minimum size OR Dropbox size. Please advise.
Regards,
Anubha
from tocropviewcontroller.
Hey tim,
Thanks for such a great library.
Even i want this capping feature of minimum resolution.
Please can you let me know if you will update it soon.
from tocropviewcontroller.
Related Issues (20)
- how to set dimming view
- Grid
- Make TOCropToolbar.backgroundView public, to enable manipulating background color. HOT 1
- how to change bottom toolbar's height?
- [BUG]pushing done button with dragging
- Constrained crop aspect ratio in range HOT 4
- [Question] How to change cropping square size HOT 4
- Let the user move the image with mouse hold HOT 1
- Manually import folders doesnt work
- customAspectRatioName is missing in CropViewController
- Running on M1 Mac fails HOT 1
- Simply rotating image looses pixels each time
- Circular Croping not working on iPad HOT 1
- Xcode 14 built error HOT 13
- how to change color of title HOT 1
- Option (totally new functionality) to just set a rectangle inside image
- Crop view freezes on iOS until the background image is loaded completely.
- Support UIModalPresentationStyle.overFullScreen
- ToCropViewController not working HOT 1
- Tuist support HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tocropviewcontroller.