ArthurHub / ArthurHub/Android-Image-Cropper
Rotation issue
- Dominant language
- Java
- Stars
- 6.4k
- Forks
- 1.4k
- PR merge metrics
- No merged PRs in 30d
Description
First, this is a fantastic lib.
The issue I am facing is that the crop rect changes during rotation.
I would expect the crop rect stays in place, and the image is zoom out/in to make enough room for the crop rect.
Setup of the CropImageView
`
viewPhotoCropping = new CropImageView(this);
viewPhotoCropping.setGuidelines(CropImageView.Guidelines.ON);
viewPhotoCropping.setShowProgressBar(false);
viewPhotoCropping.setAutoZoomEnabled(true);
viewPhotoCropping.setScaleType(CropImageView.ScaleType.CENTER_CROP);
`
Rotate
`viewPhotoCropping.setRotatedDegrees(-degree);`
[Video of the issue](https://youtu.be/sp1JuZXIU1g)
In some instances, the crop rect actually went outside of the picture too.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at CropImageView.setRotatedDegrees(-degree) and trace how rotation updates the crop rect, using the supplied setup and video as reproduction context. Verify that the crop rect remains fixed, the image zooms to contain it, and the rect never leaves the image bounds.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100