do not mess with CONTROL_AF_MODE at touch-to-focus

This commit is contained in:
tibbi 2018-06-01 21:26:11 +02:00
parent 4d640d7d5a
commit ac529cd07f

View File

@ -442,7 +442,6 @@ class PreviewCameraTwo : ViewGroup, TextureView.SurfaceTextureListener, MyPrevie
mCaptureSession!!.stopRepeating()
mPreviewRequestBuilder!!.apply {
set(CaptureRequest.CONTROL_AF_TRIGGER, CameraMetadata.CONTROL_AF_TRIGGER_CANCEL)
set(CaptureRequest.CONTROL_AF_MODE, CaptureRequest.CONTROL_AF_MODE_OFF)
mCaptureSession!!.capture(build(), captureCallbackHandler, mBackgroundHandler)
val characteristics = getCameraCharacteristics()
@ -456,7 +455,6 @@ class PreviewCameraTwo : ViewGroup, TextureView.SurfaceTextureListener, MyPrevie
}
set(CaptureRequest.CONTROL_MODE, CameraMetadata.CONTROL_MODE_AUTO)
set(CaptureRequest.CONTROL_AF_MODE, CaptureRequest.CONTROL_AF_MODE_AUTO)
set(CaptureRequest.CONTROL_AF_TRIGGER, CameraMetadata.CONTROL_AF_TRIGGER_START)
setTag(FOCUS_TAG)
mCaptureSession!!.capture(build(), captureCallbackHandler, mBackgroundHandler)