From patchwork Fri Jul 24 14:56:16 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Plowman X-Patchwork-Id: 8976 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 14170BD86F for ; Fri, 24 Jul 2020 14:56:40 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id D806D61223; Fri, 24 Jul 2020 16:56:39 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=raspberrypi.com header.i=@raspberrypi.com header.b="quoIVa/X"; dkim-atps=neutral Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 3CE60611B0 for ; Fri, 24 Jul 2020 16:56:37 +0200 (CEST) Received: by mail-wm1-x344.google.com with SMTP id f18so8543001wml.3 for ; Fri, 24 Jul 2020 07:56:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=raspberrypi.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=0OcLxwAHjQXyW5pyhRAe0/bGMfnLFfe6P8GufHkoqaY=; b=quoIVa/XXI3JVTKVcDwRsh0H4unsfkY5onhw7R9bX3IvdpGGRRgEGfLx/EXA1ujtSy t+bfCrcLhfoF/prcdIY9DtzHFtF2C9uVMaFUx0P+erfNbM2WBGAOUH98d0J1p8YK3vqe qPBnN/rCG2i9DAlPS3d/eGvIbrGpo7azdHAXo0xZJtMoRs4q+BGQIxRZ56FIsWXeBvJF uG0FclKPu7da5nCWKj7ONVyywJcK3n0KNCjPwsC1kL6rm7AN80U3fAiIZ0mqds1BqhjG 1Py2TZPvWUthhDLId3OhNaRZZ2Lv584ZlhsgO7obukFKFW1FZ6wyo5wWmHfEDbOIC1qZ zZFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=0OcLxwAHjQXyW5pyhRAe0/bGMfnLFfe6P8GufHkoqaY=; b=EPzVZowsBdjBPYqn0R+5+qsMg42CPrMLyNC++/OM4z1EmLnEfgYKtl36hXsrAtZYy7 OcAN/87+SUTL9diUnCkYXJtvWikTBiQgMmiGo2qfozW8P4i2l/4PpqAtmYMglOj5J2a0 fvoYqGgYGq3x/FR0+A/39EVUep/wJ0Qn1LcX6lZrR/znw2MMsb8zq2oXSvvijxO2ZyKX PhMczGX6WSP8NFv+J8dWoQInLiWMs0Omw84D6tAZgZ8ecEhnfDp5vhZS+X+1DPy0qWXz j3JuJ+450uo5a7WxMpHl7+rpV+rA2BrogesTJSsV/n0sR7nmYnKF+1ujrjQ5ix2HqW73 tuPg== X-Gm-Message-State: AOAM5309UDl9HT7WkVogvlCd4oT09BoL00kFt7Qhr92y4Cyfd46wczZo 9HM9FQIH6kVS2BDG/tmA08eVs6BHTX0wuA== X-Google-Smtp-Source: ABdhPJyI7de/tFoSH9LipkLbsnu5zuSxRFndvPO/9C0GJ3e0gT2GxHNciAqT7DasynMuHv2pCfTLYw== X-Received: by 2002:a05:600c:2154:: with SMTP id v20mr9826065wml.185.1595602596659; Fri, 24 Jul 2020 07:56:36 -0700 (PDT) Received: from pi4-davidp.lan (plowpeople3.plus.com. [80.229.223.72]) by smtp.gmail.com with ESMTPSA id h5sm2073156wrc.97.2020.07.24.07.56.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 Jul 2020 07:56:36 -0700 (PDT) From: David Plowman To: libcamera-devel@lists.libcamera.org Date: Fri, 24 Jul 2020 15:56:16 +0100 Message-Id: <20200724145618.26304-2-david.plowman@raspberrypi.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200724145618.26304-1-david.plowman@raspberrypi.com> References: <20200724145618.26304-1-david.plowman@raspberrypi.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v2 1/3] libcamera: Add ColourCorrectionMatrix control 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" This control is principally for returning, in the image metadata, the CCM (Colour Correction Matrix) used by the imaging pipeline. By which we mean the 3x3 matrix that is applied to the camera RGB pixels after subtraction of black levels and white-balancing, but before any gamma transformation. Some implementations may also choose to let an application set explicit colour matrices, using this as a control. Signed-off-by: David Plowman --- src/libcamera/control_ids.yaml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/libcamera/control_ids.yaml b/src/libcamera/control_ids.yaml index 988b501..3560d4a 100644 --- a/src/libcamera/control_ids.yaml +++ b/src/libcamera/control_ids.yaml @@ -262,4 +262,15 @@ controls: In this respect, it is not necessarily aimed at providing a way to implement a focus algorithm by the application, rather an indication of how in-focus a frame is. + + - ColourCorrectionMatrix: + type: float + description: | + The 3x3 matrix that converts camera RGB to sRGB within the + imaging pipeline. This should describe the matrix that is used + after pixels have been white-balanced, but before any gamma + transformation. The 3x3 matrix is stored in conventional reading + order in an array of 9 floating point values. + + size: [3x3] ...