Android-Image-Cropper icon indicating copy to clipboard operation
Android-Image-Cropper copied to clipboard

[BUG] - CropRect has mixed up width / height ⚠️ ⚠️

Open vanniktech opened this issue 3 years ago • 5 comments

Using a Pixel 6 XL.

  1. Click on sample of customactivity
  2. Select Camera as the source
  3. Take a portrait! picture
  4. Have a breakpoint in onSetImageUriComplete: https://github.com/CanHub/Android-Image-Cropper/blob/85c98bbda8ec2024b9572518baaa894ac7ea55d5/cropper/src/main/java/com/canhub/cropper/CropImageActivity.kt#L274

Expected behavior: view.cropRect should have the correct dimensions (height > width) Actual behavior: view.cropRect mixed up height with width (I get width of 3226 & height of 1814)

vanniktech avatar Sep 21 '22 17:09 vanniktech

If you look at the image: BitmapFactory.decodeStream(view.context.contentResolver.openInputStream(uri)) - you can also see that the orientation is messed up:

Screen Shot 2022-09-21 at 19 30 21

vanniktech avatar Sep 21 '22 17:09 vanniktech

Hey welcome 👋 to the library and thanks for the Issue.

Can you please follow the template we have for issues? 🙏 There are many points on the template that will help me to help you.

I will close 🔴 this issue so you can reopen following the template

Is important to remember that my work here is a volunteer and to save time and have better answer help me that people use the templates.

Thanks!! 🎉

Canato avatar Sep 21 '22 21:09 Canato

Are you serious?

vanniktech avatar Sep 22 '22 02:09 vanniktech

Are you serious?

Yeah, man, to be fair, if I see an issue without the template, I already send this automated message without reading it. I spent too much time doing free volunteer work here and dealing with many people who don't read documentation or FAQ or don't know how to raise an issue.

It is for my time management and sanity that I put this type of template to help, sadly I have a limited amount of time. No other people so far have joined me to support this 200k monthly download library, so yeah, sorry that was so abrupt.

I don't use this library in any of my projects today, and I support to help the community. I ask just for people to follow the setup I put in place so I can be more effective... as you can see, we have an open PR that I didn't have the time yet to check, and no one else did and probably won't since no one never did before.

Indeed your issue is good, just missing the library version, but as a previous contributor, please use the templates and or already drop a PR with a fix.

Canato avatar Sep 22 '22 07:09 Canato

Thanks for reopening! Library version is latest, I tried this out on the main branch at https://github.com/CanHub/Android-Image-Cropper/commit/85c98bbda8ec2024b9572518baaa894ac7ea55d5

vanniktech avatar Sep 22 '22 08:09 vanniktech

This will NOT be closed by https://github.com/CanHub/Android-Image-Cropper/pull/440

vanniktech avatar Sep 26 '22 10:09 vanniktech