From patchwork Tue Sep 7 00:20:39 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 13703 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 1640ABDC71 for ; Tue, 7 Sep 2021 00:21:11 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 1717169176; Tue, 7 Sep 2021 02:21:10 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="rVjBtz2B"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 7338B60253 for ; Tue, 7 Sep 2021 02:21:07 +0200 (CEST) Received: from pendragon.lan (62-78-145-57.bb.dnainternet.fi [62.78.145.57]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id D977F891 for ; Tue, 7 Sep 2021 02:21:06 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1630974067; bh=CCT2sQJosRy/kEkc8m9Qplhlgjf/rreDMmqZzgSEXlY=; h=From:To:Subject:Date:From; b=rVjBtz2BhNmJjj7XSmRk1lMTjgvWYl1iSTzF/oR8t32MZFkzf3IMM9S6yL8ap+/GG bTRC8D3x9DGE0V8/mjAXd6E5Ywrj0cEd1WShUlcytcoIy65lVXwL55URMB5N6hYkhH a2lZ/97jnpsWrS3mhXVcQpay0qOpKyJ2GRUnh7ZE= From: Laurent Pinchart To: libcamera-devel@lists.libcamera.org Date: Tue, 7 Sep 2021 03:20:39 +0300 Message-Id: <20210907002044.7319-1-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v2 0/5] qcam: Fix stride handling X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Hello, Now this is embarassing, v1 was rebased incorrectly and changes got squashed in the wrong place. This should be fixed in this version. I came to realize that stride support was broken in qcam when testing [1] on Raspberry Pi with the YUV420 format. This patch series fixes it for all RGB and YUV formats, and also adds YUV420 support to the software converter. The patches apply on top of [1]. I've tested ARGB8888, YUYV, NV12 and YUV420, with both viewfinders. Only YUV420 had padding at the end of lines, so other formats may not work properly when padding is present, but there should at least be no regression. [1] https://lists.libcamera.org/pipermail/libcamera-devel/2021-September/024477.html Laurent Pinchart (5): qcam: viewfinder: Pass stride value to viewfinder qcam: format_converter: Add configurable stride support qcam: format_converter: Rename YUV and NV to YUVPacked and YUVSemiPlanar qcam: format_converter: Add fully-planar YUV formats support qcam: viewfinder_gl: Support configurable stride in shaders src/qcam/assets/shader/identity.vert | 4 +- src/qcam/format_converter.cpp | 187 ++++++++++++++++++--------- src/qcam/format_converter.h | 14 +- src/qcam/main_window.cpp | 3 +- src/qcam/viewfinder.h | 3 +- src/qcam/viewfinder_gl.cpp | 61 ++++++--- src/qcam/viewfinder_gl.h | 4 +- src/qcam/viewfinder_qt.cpp | 4 +- src/qcam/viewfinder_qt.h | 3 +- 9 files changed, 195 insertions(+), 88 deletions(-)