Skip to content

added pinch zoom to QR code scanner#549

Merged
LucientZ merged 4 commits into
devfrom
qr-code-zoom
Oct 3, 2024
Merged

added pinch zoom to QR code scanner#549
LucientZ merged 4 commits into
devfrom
qr-code-zoom

Conversation

@JosiahAlexanderr
Copy link
Copy Markdown
Collaborator

Added pinch zoom to QR code scanning screen

Added circular button for displaying and resetting zoom

@JosiahAlexanderr JosiahAlexanderr changed the base branch from main to dev September 25, 2024 03:48
@LucientZ LucientZ self-requested a review September 25, 2024 16:47
Copy link
Copy Markdown
Collaborator

@LucientZ LucientZ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very good implementation! Though, while it does zoom, the scale change isn't that drastic on my device. I use a Pixel 6a. This could be solved by simply giving more weight to the zoom (eg. zoom={zoom * 5}).

If the scale is much greater on iOS, then we might need to do a little more testing with other devices (we can do that during the next meeting). Also, don't worry about the unit tests; Jason is in the middle of fixing them.

image

image

Copy link
Copy Markdown
Collaborator

@LucientZ LucientZ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I modified the code on android to use event.scale without velocity and it seems to work pretty well. I would do some testing to see if it's possible to use this implementation on iOS too since it's much simpler (or if I broke anything on iOS), but otherwise this appears good to go.

@JasonIsAzn
Copy link
Copy Markdown
Member

JasonIsAzn commented Oct 3, 2024

IOS overall is good. I tested it more and noticed that pinch in/out is a bit off. But trying to go for absolute perfection might be a waste of time.
feel free to merge.

@LucientZ LucientZ merged commit 72b3189 into dev Oct 3, 2024
@LucientZ LucientZ deleted the qr-code-zoom branch October 3, 2024 14:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

3 participants