From dea689e1f260b904697a9c2f3d05b7b5068d85e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20S=C3=B6derlund?= Date: Fri, 22 Nov 2019 17:31:08 +0100 Subject: libcamera: request: In addBuffer() do not fetch stream from Buffer MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In the FrameBuffer interface the stream will not be available from the buffer object as the buffer might be allocated externally. The application needs to explicitly state which stream the buffer is being added for to the request. Extend the addBuffer() function to get this information explicitly from the caller. Signed-off-by: Niklas Söderlund Reviewed-by: Jacopo Mondi Reviewed-by: Laurent Pinchart --- src/v4l2/v4l2_camera.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/v4l2') diff --git a/src/v4l2/v4l2_camera.cpp b/src/v4l2/v4l2_camera.cpp index 7221755d..b6e0bb76 100644 --- a/src/v4l2/v4l2_camera.cpp +++ b/src/v4l2/v4l2_camera.cpp @@ -192,7 +192,7 @@ int V4L2Camera::qbuf(unsigned int index) return -ENOMEM; } - int ret = request->addBuffer(std::move(buffer)); + int ret = request->addBuffer(stream, std::move(buffer)); if (ret < 0) { LOG(V4L2Compat, Error) << "Can't set buffer for request"; return -ENOMEM; -- cgit v1.2.1