For new Samsung S21 devices Image analysis is not working together with video recording.
If I'm adding surfaces for my capture session:
//surface of TextureView for preview
addTarget(previewSurface)
//surface of media recorder for video recording
addTarget(mediaRecorder.surface)
//surface of image reader for frame analysis
addTarget(imageReader.surface)
where imageReader is
ImageReader.newInstance(previewWidth, previewHeight, ImageFormat.YUV_420_888, 1)
Preview is not starting and the system output in log is:
Camera3-Status: addComponent: Adding new component 3 - streamId = 1, format = 35, width = 1280, height = 720
Camera3-OutputStream: configureConsumerQueueLocked: Consumer wants 1 buffers, HAL wants 0
Camera3-OutputStream: configureConsumerQueueLocked: Camera HAL requested max_buffer count: 0, requires at least 1
Camera3-Stream: finishConfiguration: Unable to configure stream 1 queue: Function not implemented (-38)
Camera3-Device: Camera 0: configureStreamsLocked: Can't finish configuring output stream 1: Function not implemented (-38)
CameraDeviceClient: endConfigure: Camera 0: Unsupported set of inputs/outputs provided
CameraDevice-JV-0: Stream configuration failed due to: endConfigure:593: Camera 0: Unsupported set of inputs/outputs provided
CameraCaptureSession: Session 0: Failed to create capture session; configuration failed
It worth to note, that image reader with ImageFormat.JPEG is working fine.
Is there anybody from Samsung to help me with workaround?