Closed ahmettaydinn closed 11 months ago
Did you try adding overflow: 'hidden'
?
Did you try adding
overflow: 'hidden'
?
Yes I tried, it solves my issue. Might hiding cause any problem in terms of scanning since it might scan in the part which is outside the view? Just out of curiosity, Does this issue happens due to Android native camera behaviour?
Gotcha, yea I might just use that as a default prop. This is just how the SurfaceView works under the hood on Android, and no it does not affect any Camera behaviour, this is simply the preview.
Let's leave this open until I fix it on the native side
Gotcha, yea I might just use that as a default prop. This is just how the SurfaceView works under the hood on Android, and no it does not affect any Camera behaviour, this is simply the preview.
Let's leave this open until I fix it on the native side
I see, thank you in advance
What's happening?
I am building a form on top of which has a barcode scanner. I want the camera to fill the whole width and roughly 1/5 height of the view. However, In Android camera height grows 3 times bigger than the width. I want width bigger than height. I cannot set custom width in Android. In IOS same issue does not take place. I'll leave my component down below. Resize mode does not solve my problem since it fits the camera inside the container in the same proportion (roughly 3x height 1x width) ... I have read this issue but it does not provide necessary or useful solution for my case. ... I'll attach two images representing IOS and Android versions with the same code. My expectation is android being resizable as IOS . (Second one is IOS as it seems) ... Thank you for your great contribution on the RN open source btw.
Reproduceable Code
Relevant log output
Camera Device
Device
Redmi Note 8 Pro (Android 11)
VisionCamera Version
3.3.1
Can you reproduce this issue in the VisionCamera Example app?
Yes, I can reproduce the same issue in the Example app here
Additional information