[libcamera-devel] [RFC PATCH 2/6] android: camera_device: Report configuration changes from validate()
Jacopo Mondi
jacopo at jmondi.org
Wed Jul 22 12:36:00 CEST 2020
Hi Kieran,
On Tue, Jul 21, 2020 at 11:01:22PM +0100, Kieran Bingham wrote:
> When we call validate on a configuration, if there are any adjustments
> on the configuration, we fail without showing why.
>
> Display the stream configuration after the validate stage to aid
> debugging stream startup failures.
>
> Signed-off-by: Kieran Bingham <kieran.bingham at ideasonboard.com>
> ---
> src/android/camera_device.cpp | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/src/android/camera_device.cpp b/src/android/camera_device.cpp
> index f51542b282d5..3f3d7857f0ab 100644
> --- a/src/android/camera_device.cpp
> +++ b/src/android/camera_device.cpp
> @@ -1032,6 +1032,14 @@ int CameraDevice::configureStreams(camera3_stream_configuration_t *stream_list)
> break;
> case CameraConfiguration::Adjusted:
> LOG(HAL, Info) << "Camera configuration adjusted";
> +
> + for (unsigned int i = 0; i < stream_list->num_streams; ++i) {
> + CameraStream *cameraStream = &streams_[i];
> + StreamConfiguration &cfg = config_->at(cameraStream->index);
> +
> + LOG(HAL, Info) << i << " : " << cfg.toString();
Debug maybe ?
> + }
> +
> config_.reset();
> return -EINVAL;
> case CameraConfiguration::Invalid:
> --
> 2.25.1
>
> _______________________________________________
> libcamera-devel mailing list
> libcamera-devel at lists.libcamera.org
> https://lists.libcamera.org/listinfo/libcamera-devel
More information about the libcamera-devel
mailing list