[RFC 5/9] fixups: Make it compile
Jacopo Mondi
jacopo.mondi at ideasonboard.com
Wed Jul 17 12:09:08 CEST 2024
Signed-off-by: Jacopo Mondi <jacopo.mondi at ideasonboard.com>
---
src/libcamera/converter.cpp | 4 ++--
src/libcamera/converter/converter_v4l2_m2m.cpp | 8 ++------
2 files changed, 4 insertions(+), 8 deletions(-)
diff --git a/src/libcamera/converter.cpp b/src/libcamera/converter.cpp
index 65f4f96bafa5..a959003aaa73 100644
--- a/src/libcamera/converter.cpp
+++ b/src/libcamera/converter.cpp
@@ -177,7 +177,7 @@ Converter::~Converter()
*/
int Converter::setCrop([[maybe_unused]] const Stream *stream, [[maybe_unused]] Rectangle *rect)
{
- if (!(getFeatures() & Feature::Crop)) {
+ if (!(features() & Feature::Crop)) {
LOG(Converter, Error) << "Converter doesn't support cropping capabilities";
return -ENOTSUP;
}
@@ -200,7 +200,7 @@ std::pair<Rectangle, Rectangle> Converter::getCropBounds([[maybe_unused]] const
const StreamConfiguration &config = stream->configuration();
Rectangle rect;
- if (!(getFeatures() & Feature::Crop))
+ if (!(features() & Feature::Crop))
LOG(Converter, Error) << "Converter doesn't support cropping capabilities";
/*
diff --git a/src/libcamera/converter/converter_v4l2_m2m.cpp b/src/libcamera/converter/converter_v4l2_m2m.cpp
index eaae35288194..e381e474c1c7 100644
--- a/src/libcamera/converter/converter_v4l2_m2m.cpp
+++ b/src/libcamera/converter/converter_v4l2_m2m.cpp
@@ -389,7 +389,7 @@ int V4L2M2MConverter::exportBuffers(const Stream *stream, unsigned int count,
*/
int V4L2M2MConverter::setCrop(const Stream *stream, Rectangle *rect)
{
- if (!(getFeatures() & Feature::Crop))
+ if (!(features() & Feature::Crop))
return -ENOTSUP;
auto iter = streams_.find(stream);
@@ -414,7 +414,7 @@ V4L2M2MConverter::getCropBounds(const Stream *stream)
maxCrop.width = UINT_MAX;
maxCrop.height = UINT_MAX;
- if (!(getFeatures() & Feature::Crop)) {
+ if (!(features() & Feature::Crop)) {
LOG(Converter, Error) << "Crop functionality is not supported";
return {};
}
@@ -532,10 +532,6 @@ int V4L2M2MConverter::queueBuffers(FrameBuffer *input,
return 0;
}
-/*
- * \todo: This should be extended to include Feature::Flag to denote
- * what each converter supports feature-wise.
- */
static std::initializer_list<std::string> compatibles = {
"mtk-mdp",
"pxp",
--
2.45.2
More information about the libcamera-devel
mailing list