summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJacopo Mondi <jacopo.mondi@ideasonboard.com>2022-11-24 10:10:26 +0100
committerJacopo Mondi <jacopo.mondi@ideasonboard.com>2023-01-28 15:37:49 +0100
commitaf543d3c9ee4ed336c0db09a965086c418896326 (patch)
treef8e9f2655eb959e6a85cb55420218163823920bd /include
parentbfab60e5c4c9f159c6f7bf674c63fffb40159368 (diff)
libcamera: camera_sensor: Validate Transform
The two pipeline handlers that currently support Transform (IPU3 and RkISP1) implement it by operating H/V flips on the image sensor. Centralize the code that validates a Transform request against the sensor rotation capabilities in the CameraSensor class. The implementation in the IPU3 pipeline handler was copied from the RaspberryPi implementation, and is now centralized in CameraSensor to make it easier for other platforms. The CameraSensor::validateTransform() implementation comes directly from the RaspberryPi pipeline handler, no functional changes intended. Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
Diffstat (limited to 'include')
-rw-r--r--include/libcamera/internal/camera_sensor.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/libcamera/internal/camera_sensor.h b/include/libcamera/internal/camera_sensor.h
index 878f3c28..bea52bad 100644
--- a/include/libcamera/internal/camera_sensor.h
+++ b/include/libcamera/internal/camera_sensor.h
@@ -29,6 +29,8 @@ class BayerFormat;
class CameraLens;
class MediaEntity;
+enum class Transform;
+
struct CameraSensorProperties;
class CameraSensor : protected Loggable
@@ -68,6 +70,8 @@ public:
CameraLens *focusLens() { return focusLens_.get(); }
+ Transform validateTransform(Transform *transform) const;
+
protected:
std::string logPrefix() const override;