[libcamera-devel] [PATCH] libcamera: camera_sensor: Add OV5640 sensor properties
Kieran Bingham
kieran.bingham at ideasonboard.com
Wed Mar 16 10:52:58 CET 2022
Quoting Paul Elder via libcamera-devel (2022-03-16 08:16:58)
> Add an entry to the sensor properties for the ov5640. Only the first
> test pattern is included as the others that are exposed by the kernel
> don't correspond to any that are defined in the libcamera control.
Indeed, I see:
static const char * const test_pattern_menu[] = {
"Disabled",
"Color bars",
"Color bars w/ rolling bar",
"Color squares",
"Color squares w/ rolling bar",
};
I think this patch is fine so
Reviewed-by: Kieran Bingham <kieran.bingham at ideasonboard.com>
But I wonder how we're going to map so many potential combinations of
test pattern.
A test pattern with motion is probably useful to be able to enable but
how do we then define the motion etc...
I almost wish we could just represent test patterns as a string menu and
report the underlying V4L2 strings directly to applications ... then the
users could choose directly.
>
> Signed-off-by: Paul Elder <paul.elder at ideasonboard.com>
> ---
> src/libcamera/camera_sensor_properties.cpp | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/src/libcamera/camera_sensor_properties.cpp b/src/libcamera/camera_sensor_properties.cpp
> index 48305ac4..027d74e1 100644
> --- a/src/libcamera/camera_sensor_properties.cpp
> +++ b/src/libcamera/camera_sensor_properties.cpp
> @@ -90,6 +90,13 @@ const CameraSensorProperties *CameraSensorProperties::get(const std::string &sen
> { controls::draft::TestPatternModePn9, 4 },
> },
> } },
> + { "ov5640", {
> + .unitCellSize = { 1400, 1400 },
> + .testPatternModes = {
> + { controls::draft::TestPatternModeOff, 0 },
> + { controls::draft::TestPatternModeColorBars, 1 },
> + },
> + } },
> { "ov5647", {
> .unitCellSize = { 1400, 1400 },
> .testPatternModes = {},
> --
> 2.30.2
>
More information about the libcamera-devel
mailing list