mirror of
https://github.com/SimpleMobileTools/Simple-Camera.git
synced 2025-02-17 20:00:57 +01:00
add flipping horizontally and photo quality
This commit is contained in:
parent
c398370446
commit
1f3dd341d0
@ -233,6 +233,7 @@ class CameraXPreview(
|
|||||||
return ImageCapture.Builder()
|
return ImageCapture.Builder()
|
||||||
.setCaptureMode(CAPTURE_MODE_MAXIMIZE_QUALITY)
|
.setCaptureMode(CAPTURE_MODE_MAXIMIZE_QUALITY)
|
||||||
.setFlashMode(flashMode)
|
.setFlashMode(flashMode)
|
||||||
|
.setJpegQuality(config.photoQuality)
|
||||||
.setTargetAspectRatio(aspectRatio)
|
.setTargetAspectRatio(aspectRatio)
|
||||||
.setTargetRotation(rotation)
|
.setTargetRotation(rotation)
|
||||||
.build()
|
.build()
|
||||||
@ -305,7 +306,7 @@ class CameraXPreview(
|
|||||||
val imageCapture = imageCapture ?: throw IllegalStateException("Camera initialization failed.")
|
val imageCapture = imageCapture ?: throw IllegalStateException("Camera initialization failed.")
|
||||||
|
|
||||||
val metadata = Metadata().apply {
|
val metadata = Metadata().apply {
|
||||||
isReversedHorizontal = frontCameraInUse
|
isReversedHorizontal = config.flipPhotos
|
||||||
}
|
}
|
||||||
|
|
||||||
val contentValues = ContentValues().apply {
|
val contentValues = ContentValues().apply {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user