-
-
Notifications
You must be signed in to change notification settings - Fork 267
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CanHub Image Cropper not taking up full crop image container #582
Comments
The aspect ratio probably? There are a few options to configure this thing for you though: |
I think an easier way to ask my question would be if I had a very small image. Say 50x50 pixels. It's much smaller than the cropImageView, so it would not take the full width or height. Is there a way to automatically zoom in so that it does take up the full width and height of the cropImageView |
I think you might need to tweak |
I think tweaking scaleX and scaleY will do the trick, but as for my first issue I have an image that's 4000x6000....the aspect ratio is 0.66 and another image that's 1440x3088, its aspect ratio is 0.466. The CropImageView is set to the width of the parent and a height of 300dp. The 1440x3088 takes up the full width and height, while the 4000x6000 does not. I'm not sure why. An image that's 679x452 and has an aspect ratio of 1.50 will also fit the whole width and height of the CropImageView. Any images that are 0.66, 0.75, etc. do not fit the whole width and height of the CropImageView |
@razer56 did you come back to this problem and found a solution? I still think for now the best solution is to calculcate the zoom factors yourself. You have all of the data (how big is your view/how big is the image). |
The problem I am facing is that an image that's 4000x6000 won't fill the cropImageView container fully. While an image that's 1440x3088 will. All I want to do is when a user uploads an image, it always fills the entire cropImageView container. If that image is smaller than the container size, then it should zoom all the way up until it takes up the full container size. How do I achieve this?
and here's the code of when I load the image into the cropImageView after I select an image from my camera roll:
The text was updated successfully, but these errors were encountered: