Status Update
Comments
sp...@gmail.com <sp...@gmail.com> #2
After some googling I found https://github.com/android/camera-samples/blob/master/CameraXBasic/app/src/main/java/com/android/example/cameraxbasic/utils/AutoFitPreviewBuilder.kt which does what I want. Would it be possible to fold this into the main library or at least make it configurable without the need for that class?
po...@google.com <po...@google.com> #3
Hi Charcoal,
Are we getting a crop mode here? Thanks!
Are we getting a crop mode here? Thanks!
Description
Android Studio Build: Arctic Fox Canary 5
Steps to Reproduce:
1. Run app from code at
2. Initially the camera preview will seem zoomed in.
3. Flip the switch, this shows a correct preview
Also see:
On Alpha08 the camera preview, likely using SurfaceView underneath, was correctly scaled, and can be demonstrated by not using the second commit on the above repo.
In Alpha11 of Compose, the preview isn't scaling correctly, and seems to be showing a small part of the camera preview as if it is cropping a larger image.
In the Slack it was suggested to do the following:
view.implementationMode = PreviewView.ImplementationMode.COMPATIBLE
Which I will try as a workaround.