I want to capture image while recording video using camera2 API.
Two separate demos are available. 1. To capture image and 2. To record video
I tried to combine them into one app. But confused in many things. Like
mCameraDevice.createCaptureRequest(CameraDevice.TEMPLATE_PREVIEW);
and for video mCameraDevice.createCaptureRequest(CameraDevice.TEMPLATE_RECORD);
CameraCaptureSession.StateCallback is needed in createCaptureSession method for both image and video.
And camera2 APIs are new. So no more examples available on Google.
Anyone has any idea about this? like how to capture photo while recording in android?
For camera2 API, and video snapshots, you'll need to improve the camera2video sample somewhat.