Add option: autozoom treshold
Currently the autozoom doesn't kick in until the crop window gets below 50% screen size. I'd like it to be a bit more aggressive.
In the code these seem to be hard coded values, i.e. triggers at 0.5, then zooms to 0.65. It'd be nice if these values can be changed as options. It should assert that the zoom to value is always higher than the treshold of course.
This is the code where the values are currently hard coded:
// keep the cropping window covered area to 50%-65% of zoomed sub-area
if (mZoom < mMaxZoom && cropRect.width() < width * 0.5f && cropRect.height() < height * 0.5f) {
newZoom = min(
mMaxZoom.toFloat(),
min(
width / (cropRect.width() / mZoom / 0.64f),
height / (cropRect.height() / mZoom / 0.64f)
)
)
}
if (mZoom > 1 && (cropRect.width() > width * 0.65f || cropRect.height() > height * 0.65f)) {
newZoom = max(
1f,
min(
width / (cropRect.width() / mZoom / 0.51f),
height / (cropRect.height() / mZoom / 0.51f)
)
)
}
I've been seeing a lot more options being added lately, can this be one of them?
Yes! is a great option. Let's add
Let's keep this mess organised! This issue has been automatically marked as stale because it has not had recent activity. =( It will be closed if no further activity occurs. Thank you for your contributions.