summaryrefslogtreecommitdiff
path: root/src/qcam/format_converter.h
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-09-06 22:15:35 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-09-22 10:58:38 +0300
commit4abbd832feb9999824c8b7d1ba8bd5319e8d640a (patch)
tree8a3d45cf7347340528de204637434e5d01801edd /src/qcam/format_converter.h
parentf3671b33d90cf2bb13ee59ac83822a3294689b22 (diff)
qcam: format_converter: Add configurable stride support
Make the stride configurable to support conversion of images with padding at the end of lines. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
Diffstat (limited to 'src/qcam/format_converter.h')
-rw-r--r--src/qcam/format_converter.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/qcam/format_converter.h b/src/qcam/format_converter.h
index 2220a62b..bb04aa95 100644
--- a/src/qcam/format_converter.h
+++ b/src/qcam/format_converter.h
@@ -19,7 +19,8 @@ class QImage;
class FormatConverter
{
public:
- int configure(const libcamera::PixelFormat &format, const QSize &size);
+ int configure(const libcamera::PixelFormat &format, const QSize &size,
+ unsigned int stride);
void convert(const Image *src, size_t size, QImage *dst);
@@ -38,6 +39,7 @@ private:
libcamera::PixelFormat format_;
unsigned int width_;
unsigned int height_;
+ unsigned int stride_;
enum FormatFamily formatFamily_;