-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use camera-compose and restore double-tap to flip camera #263
Use camera-compose and restore double-tap to flip camera #263
Conversation
temcguir
commented
Sep 10, 2024
- Move HDR color mode code out of CameraXViewfinder
- Replace CameraXViewfinder with camera-compose version
- Move double tap logic to same pointerInput as tapToFocus
val colorModeSnapshotFlow = | ||
snapshotFlow { Pair(currentSurfaceRequest.dynamicRange, currentImplementationMode) } | ||
.map { (dynamicRange, implMode) -> | ||
val isSourceHdr = dynamicRange.encoding != CXDynamicRange.ENCODING_SDR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any possible isSourceHdr
would be not HDR Encoding, even it is not Encoding SDR, such as Encoding Dolby Vision, Encoding HLG, Encoding Unspecified?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dolby Vision, HLG10, HDR10 and HDR10+ are all considered HDR formats. Technically, the DynamicRange here from CameraX should never be UNSPECIFIED, since it is coming from SurfaceRequest
. I'll make a note to update the CameraX documentation to better communicate that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The CameraX documentation improvements will be tracked with https://issuetracker.google.com/366536534
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for everything.
…ersion_for_viewfinder