summaryrefslogtreecommitdiff
path: root/src/libcamera/pipeline/uvcvideo
diff options
context:
space:
mode:
authorDavid Plowman <david.plowman@raspberrypi.com>2020-09-07 08:16:00 +0100
committerKieran Bingham <kieran.bingham@ideasonboard.com>2020-09-29 11:43:06 +0100
commitdcae0513f799c78ad513c9c9c7dc5426e7a25161 (patch)
tree62d17d43aaea2c493eabab2169199bd34084a236 /src/libcamera/pipeline/uvcvideo
parent78cbd6a93fbb49a20b97793b925769eefb52e516 (diff)
libcamera: Add user Transform to CameraConfiguration
Add a field to the CameraConfiguration (including the necessary documentation) to represent a 2D transform requested by the application. All pipeline handlers are amended to coerce this to the Identity, marking the configuration as "adjusted" if something different had been requested. Pipeline handlers that support Transforms can be amended subsequently. Signed-off-by: David Plowman <david.plowman@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'src/libcamera/pipeline/uvcvideo')
-rw-r--r--src/libcamera/pipeline/uvcvideo/uvcvideo.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp b/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp
index bafe6f19..ba0efc8b 100644
--- a/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp
+++ b/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp
@@ -109,6 +109,11 @@ CameraConfiguration::Status UVCCameraConfiguration::validate()
if (config_.empty())
return Invalid;
+ if (transform != Transform::Identity) {
+ transform = Transform::Identity;
+ status = Adjusted;
+ }
+
/* Cap the number of entries to the available streams. */
if (config_.size() > 1) {
config_.resize(1);