{"id":3473,"url":"https://patchwork.libcamera.org/api/1.1/patches/3473/?format=json","web_url":"https://patchwork.libcamera.org/patch/3473/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20200416220558.32136-1-laurent.pinchart@ideasonboard.com>","date":"2020-04-16T22:05:58","name":"[libcamera-devel] libcamera: v4l2_videodevice: Return correct format for metadata","commit_ref":"35269f04578082675778ef7ce6eab2fb4d559d9a","pull_url":null,"state":"accepted","archived":false,"hash":"fda30702d08a2fc80d0ba52ab518af35f312d295","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/1.1/people/2/?format=json","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/3473/mbox/","series":[{"id":814,"url":"https://patchwork.libcamera.org/api/1.1/series/814/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=814","date":"2020-04-16T22:05:58","name":"[libcamera-devel] libcamera: v4l2_videodevice: Return correct format for metadata","version":1,"mbox":"https://patchwork.libcamera.org/series/814/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/3473/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/3473/checks/","tags":{},"headers":{"Return-Path":"<laurent.pinchart@ideasonboard.com>","Received":["from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 6096660406\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 17 Apr 2020 00:06:15 +0200 (CEST)","from pendragon.bb.dnainternet.fi (81-175-216-236.bb.dnainternet.fi\n\t[81.175.216.236])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id DD6EA97D\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 17 Apr 2020 00:06:14 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"J18iS6zc\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1587074775;\n\tbh=AVylLCuoraGMDNfK7pn2NjYfq2vHXUQ5p25WCP4sqSU=;\n\th=From:To:Subject:Date:From;\n\tb=J18iS6zc07ycPmbj5OvA8ZeLa77SMLhK7vLrDNxMkdCSq/ayU1GVGDtClFpFK0FHx\n\tGSQSixeJZ5Aus89OxezkjvH981oNwqg8vK5vggT3LTtE3jCjhDNXNfJPdIx3mV8LO5\n\tSoQGlsUpOTsR6oUhtjBl6VvoNTnNG+jQvZDPFXck=","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Fri, 17 Apr 2020 01:05:58 +0300","Message-Id":"<20200416220558.32136-1-laurent.pinchart@ideasonboard.com>","X-Mailer":"git-send-email 2.24.1","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH] libcamera: v4l2_videodevice: Return\n\tcorrect format for metadata","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","X-List-Received-Date":"Thu, 16 Apr 2020 22:06:15 -0000"},"content":"When setting format on a metadata video device, the returned format\nisn't updated with the actual set format due to a typo. Fix it.\n\nFixes: 629e9301c518 (\"libcamera: v4l2_device: Add META support in g/s_fmt\")\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n src/libcamera/v4l2_videodevice.cpp | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)","diff":"diff --git a/src/libcamera/v4l2_videodevice.cpp b/src/libcamera/v4l2_videodevice.cpp\nindex 439a9c90dbf7..a959cfe65c43 100644\n--- a/src/libcamera/v4l2_videodevice.cpp\n+++ b/src/libcamera/v4l2_videodevice.cpp\n@@ -848,7 +848,7 @@ int V4L2VideoDevice::setFormatMeta(V4L2DeviceFormat *format)\n \t */\n \tformat->size.width = 0;\n \tformat->size.height = 0;\n-\tformat->fourcc = format->fourcc;\n+\tformat->fourcc = V4L2PixelFormat(pix->dataformat);\n \tformat->planesCount = 1;\n \tformat->planes[0].bpl = pix->buffersize;\n \tformat->planes[0].size = pix->buffersize;\n","prefixes":["libcamera-devel"]}