Question: Is it possible to zoom&pan to a specific region (rectangle/point) of the given image, similar to center-crop, but customizable?
There are various scaling methods here, but let's say I want to use something like center-crop, yet not always to the center, and also not always on one of the edges (start/end).
This means, for example, that sometimes I prefer to focus on a specific region of the given bitmap.
This is important if I know that this region is more important than the rest.
For example, suppose I have a photo of a person, and the face of the person is in some given rectangle in the bitmap. I want the library to focus this region at the beginning, but still fit to the space that it has, keeping aspect-ratio.
Another example is when I have a landscape image, and I want to show it in a portrait container, yet it's not exactly the center that I want to focus on, and instead some percentage in start-X and end-X of the given image. Still, again, it's a rectangle to focus on.
Is such a thing possible here?
Yes I think it's possible, you just need to modify SSIV to support this feature.
Best regards. Piasy Xu
此致,祝好! 许建林
https://github.com/Piasy https://www.linkedin.com/in/piasy/
On Tue, Dec 17, 2024 at 09:33 AndroidDeveloperLB @.***> wrote:
There are various scaling methods here, but let's say I want to use something like center-crop, yet not always to the center, and also not always on one of the edges (start/end).
This means, for example, that sometimes I prefer to focus on a specific region of the given bitmap.
This is important if I know that this region is more important than the rest.
For example, suppose I have a photo of a person, and the face of the person is in some given rectangle in the bitmap. I want the library to focus this region at the beginning, but still fit to the space that it has, keeping aspect-ratio.
Another example is when I have a landscape image, and I want to show it in a portrait container, yet it's not exactly the center that I want to focus on, and instead some percentage in start-X and end-X of the given image. Still, again, it's a rectangle to focus on.
Is such a thing possible here?
— Reply to this email directly, view it on GitHub https://github.com/Piasy/BigImageViewer/issues/253, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXUQUEKFO5CA5UQQKEHXV32F55PPAVCNFSM6AAAAABTXLH7WOVHI2DSMVQWIX3LMV43ASLTON2WKOZSG42DGNZTGMZDAMY . You are receiving this because you are subscribed to this thread.Message ID: @.***>
@Piasy What do you mean SSIV ? Can you please give me more clues, or if it's easy, let me know how to do it using your own code?
sub sampling image view, it's the dependency of BigImageView.
Best regards. Piasy Xu
此致,祝好! 许建林
https://github.com/Piasy https://www.linkedin.com/in/piasy/
On Tue, Dec 17, 2024 at 20:16 AndroidDeveloperLB @.***> wrote:
@Piasy https://github.com/Piasy What do you mean SSIV ? Can you please give me more clues, or if it's easy, let me know how to do it using your own code?
— Reply to this email directly, view it on GitHub https://github.com/Piasy/BigImageViewer/issues/253#issuecomment-2548303389, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXUQUBGPCTITT7CGGVS7QD2GAI2PAVCNFSM6AAAAABTXLH7WOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNBYGMYDGMZYHE . You are receiving this because you were mentioned.Message ID: @.***>
So it can't be here? I need to fork the dependency there, and then fork from here, to add this? Is there any other alternative? The repository here offers to reach any zoom&movement in the image by the user. I think it should be possible to do it via code...