Message ID | 20240613155949.1041061-8-dan.scally@ideasonboard.com |
---|---|
State | Superseded |
Headers | show |
Series |
|
Related | show |
Quoting Daniel Scally (2024-06-13 16:59:49) > The DNGWriter class needs to know the stride of a RAW image for some > of its uses. Add stride to rawConfig in the mali-c55 pipeline handler > so that it's available to DNGWriter. > > Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com> > --- > src/libcamera/pipeline/mali-c55/mali-c55.cpp | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/src/libcamera/pipeline/mali-c55/mali-c55.cpp b/src/libcamera/pipeline/mali-c55/mali-c55.cpp > index 9cd243a3..a9ea2e04 100644 > --- a/src/libcamera/pipeline/mali-c55/mali-c55.cpp > +++ b/src/libcamera/pipeline/mali-c55/mali-c55.cpp > @@ -382,6 +382,9 @@ CameraConfiguration::Status MaliC55CameraConfiguration::validate() > > maxSize = rawSize; > > + const PixelFormatInfo &info = PixelFormatInfo::info(rawConfig->pixelFormat); > + rawConfig->stride = info.stride(rawConfig->size.width, 0, 64); > + Does the frameSize also get set? I would anticipate the two being together. We should add such tests to lc-compliance to make sure the configurations are fully populated after validation. But I think this one stands... Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> > rawConfig->setStream(const_cast<Stream *>(&data_->frStream_)); > frPipeAvailable = false; > } > -- > 2.30.2 >
On Thu, Jun 13, 2024 at 08:38:15PM +0100, Kieran Bingham wrote: > Quoting Daniel Scally (2024-06-13 16:59:49) > > The DNGWriter class needs to know the stride of a RAW image for some > > of its uses. Add stride to rawConfig in the mali-c55 pipeline handler > > so that it's available to DNGWriter. As mentioned by Kieran in the review of a previous patch, this may be true, but it's hardly the reason. > > Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com> > > --- > > src/libcamera/pipeline/mali-c55/mali-c55.cpp | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/src/libcamera/pipeline/mali-c55/mali-c55.cpp b/src/libcamera/pipeline/mali-c55/mali-c55.cpp > > index 9cd243a3..a9ea2e04 100644 > > --- a/src/libcamera/pipeline/mali-c55/mali-c55.cpp > > +++ b/src/libcamera/pipeline/mali-c55/mali-c55.cpp > > @@ -382,6 +382,9 @@ CameraConfiguration::Status MaliC55CameraConfiguration::validate() > > > > maxSize = rawSize; > > > > + const PixelFormatInfo &info = PixelFormatInfo::info(rawConfig->pixelFormat); > > + rawConfig->stride = info.stride(rawConfig->size.width, 0, 64); > > + > > Does the frameSize also get set? I would anticipate the two being > together. This patch should set both. > We should add such tests to lc-compliance to make sure the > configurations are fully populated after validation. > > But I think this one stands... > > Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> > > > rawConfig->setStream(const_cast<Stream *>(&data_->frStream_)); > > frPipeAvailable = false; > > }
diff --git a/src/libcamera/pipeline/mali-c55/mali-c55.cpp b/src/libcamera/pipeline/mali-c55/mali-c55.cpp index 9cd243a3..a9ea2e04 100644 --- a/src/libcamera/pipeline/mali-c55/mali-c55.cpp +++ b/src/libcamera/pipeline/mali-c55/mali-c55.cpp @@ -382,6 +382,9 @@ CameraConfiguration::Status MaliC55CameraConfiguration::validate() maxSize = rawSize; + const PixelFormatInfo &info = PixelFormatInfo::info(rawConfig->pixelFormat); + rawConfig->stride = info.stride(rawConfig->size.width, 0, 64); + rawConfig->setStream(const_cast<Stream *>(&data_->frStream_)); frPipeAvailable = false; }
The DNGWriter class needs to know the stride of a RAW image for some of its uses. Add stride to rawConfig in the mali-c55 pipeline handler so that it's available to DNGWriter. Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com> --- src/libcamera/pipeline/mali-c55/mali-c55.cpp | 3 +++ 1 file changed, 3 insertions(+)