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>
This commit is contained in:
David Plowman
2020-09-07 08:16:00 +01:00
committed by Kieran Bingham
parent 78cbd6a93f
commit dcae0513f7
8 changed files with 48 additions and 1 deletions
@@ -250,6 +250,11 @@ CameraConfiguration::Status RPiCameraConfiguration::validate()
if (config_.empty())
return Invalid;
if (transform != Transform::Identity) {
transform = Transform::Identity;
status = Adjusted;
}
unsigned int rawCount = 0, outCount = 0, count = 0, maxIndex = 0;
std::pair<int, Size> outSize[2];
Size maxSize;