Cover Letter Detail
Show a cover letter.
GET /api/1.1/covers/19786/?format=api
{ "id": 19786, "url": "https://patchwork.libcamera.org/api/1.1/covers/19786/?format=api", "web_url": "https://patchwork.libcamera.org/cover/19786/", "project": { "id": 1, "url": "https://patchwork.libcamera.org/api/1.1/projects/1/?format=api", "name": "libcamera", "link_name": "libcamera", "list_id": "libcamera_core", "list_email": "libcamera-devel@lists.libcamera.org", "web_url": "", "scm_url": "", "webscm_url": "" }, "msgid": "<20240322131451.3092931-1-dan.scally@ideasonboard.com>", "date": "2024-03-22T13:14:41", "name": "[00/10] Centralise Agc into libipa", "submitter": { "id": 156, "url": "https://patchwork.libcamera.org/api/1.1/people/156/?format=api", "name": "Dan Scally", "email": "dan.scally@ideasonboard.com" }, "mbox": "https://patchwork.libcamera.org/cover/19786/mbox/", "series": [ { "id": 4236, "url": "https://patchwork.libcamera.org/api/1.1/series/4236/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=4236", "date": "2024-03-22T13:14:41", "name": "Centralise Agc into libipa", "version": 1, "mbox": "https://patchwork.libcamera.org/series/4236/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/covers/19786/comments/", "headers": { "Return-Path": "<libcamera-devel-bounces@lists.libcamera.org>", "X-Original-To": "parsemail@patchwork.libcamera.org", "Delivered-To": "parsemail@patchwork.libcamera.org", "Received": [ "from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id AAFCAC3272\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 22 Mar 2024 13:15:11 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 7609363097;\n\tFri, 22 Mar 2024 14:15:09 +0100 (CET)", "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4559961C45\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 22 Mar 2024 14:15:07 +0100 (CET)", "from mail.ideasonboard.com\n\t(cpc141996-chfd3-2-0-cust928.12-3.cable.virginm.net [86.13.91.161])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 26A5D842;\n\tFri, 22 Mar 2024 14:14:38 +0100 (CET)" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"G3oJXN4J\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1711113278;\n\tbh=5j/atG6eDn795uXolt3wlIvNnN4mqiwi+rpX3oN6AnI=;\n\th=From:To:Cc:Subject:Date:From;\n\tb=G3oJXN4JH4J8HrUknRt/mngvAJHBrvRzzw8PTa8CTiY1kbre8kwmBKoVsiQQOosD9\n\t4xJqIKB2QOhx5glVsnnaFPy5BNIdSPbCiVuxtPDhc3OIz9TXHpWlIi8YeB+VkaL4vJ\n\tIHFzJHJjHQ5yekbhcP4VWUjelCFgNZ7RCpsntn8M=", "From": "Daniel Scally <dan.scally@ideasonboard.com>", "To": "libcamera-devel@lists.libcamera.org", "Cc": "Daniel Scally <dan.scally@ideasonboard.com>", "Subject": "[PATCH 00/10] Centralise Agc into libipa", "Date": "Fri, 22 Mar 2024 13:14:41 +0000", "Message-Id": "<20240322131451.3092931-1-dan.scally@ideasonboard.com>", "X-Mailer": "git-send-email 2.34.1", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "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>", "Errors-To": "libcamera-devel-bounces@lists.libcamera.org", "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>" }, "content": "Hello all\n\nThe IPU3 and RkISP1 IPAs do Agc the same way (following the Rpi method closely),\nbut the implementations are wholly separate. This introduces the potential for\ndivergence and also makes both maintenance and improvement more difficult. This\nseries unifies them as derivations of a new MeanLuminanceAgc class within\nlibipa. The algorithm itself is done through functions of the base class\nwith the IPA's derived classes providing a function through which the mean\nluminance input to the algorithm can be calculated from their specific stats\nformats.\n\nThe old implementations effectively hard coded values for the AeConstraintMode\nand AeExposureMode controls; they adhered to a single lower-bound constraint of\n0.5 across the top 2% of a Histogram and acted as though the AeExposureMode\nexpected shutter time to be driven to its maximum before touching gain at all.\nThe base class additionally adds infrastructure to discover the supported values\nfor AeConstraintMode and AeExposureMode controls from a camera sensor tuning\nfile and uses the values defined in those files with the algorithm instead,\nthough as no tuning files are modified in this series the behaviour currently\nremains as it was before.\n\nThe series **does** alter the calculated shutter time and gain for both the\nIPU3 and RkISP1 compared to their bespoke implementations, for two reasons:\n\n1. A bug in the way they were implemented meant that an over-exposed image was\n corrected more slowly than an under-exposed one. This is fixed and will\n improve both IPAs' response to a too-bright image.\n2. The default kRelativeLuminanceTarget is centrally set to 0.16 which matches\n the value from the IPU3 implementation. In the RkISP1 implementation that\n value was set to 0.4 with a \\todo to see why they were different. My belief\n is that they were different because they were implemented in different\n lighting conditions. In my very imperfect testing setup the 0.16 target\n produced reasonable images on both.\n\nWithout those two changes, the shutter time and gain calculated after this\nseries matches those calculated by their independent implementations.\n\nThanks\nDan\n\nDaniel Scally (9):\n ipa: libipa: Allow creation of empty Histogram\n libcamera: controls: Generate enum value-name maps\n ipa: libipa: Add MeanLuminanceAgc base class\n ipa: ipu3: Parse and store Agc stats\n ipa: ipu3: Derive ipu3::algorithms::Agc from MeanLuminanceAgc\n ipa: ipu3: Remove bespoke AGC functions from IPU3\n ipa: rkisp1: Add parseStatistics() to Agc\n ipa: rkisp1: Derive rkisp1::algorithms::Agc from MeanLuminanceAgc\n ipa: rkisp1: Remove bespoke Agc functions\n\nPaul Elder (1):\n ipa: libipa: Add ExposureModeHelper\n\n include/libcamera/control_ids.h.in | 2 +\n include/libcamera/property_ids.h.in | 2 +\n src/ipa/ipu3/algorithms/agc.cpp | 306 ++++----------\n src/ipa/ipu3/algorithms/agc.h | 27 +-\n src/ipa/ipu3/ipa_context.cpp | 3 +\n src/ipa/ipu3/ipa_context.h | 5 +\n src/ipa/ipu3/ipu3.cpp | 2 +-\n src/ipa/libipa/agc.cpp | 526 ++++++++++++++++++++++++\n src/ipa/libipa/agc.h | 82 ++++\n src/ipa/libipa/exposure_mode_helper.cpp | 307 ++++++++++++++\n src/ipa/libipa/exposure_mode_helper.h | 61 +++\n src/ipa/libipa/histogram.h | 1 +\n src/ipa/libipa/meson.build | 4 +\n src/ipa/rkisp1/algorithms/agc.cpp | 303 ++++----------\n src/ipa/rkisp1/algorithms/agc.h | 19 +-\n src/ipa/rkisp1/ipa_context.h | 5 +\n src/ipa/rkisp1/rkisp1.cpp | 2 +-\n utils/gen-controls.py | 19 +\n 18 files changed, 1219 insertions(+), 457 deletions(-)\n create mode 100644 src/ipa/libipa/agc.cpp\n create mode 100644 src/ipa/libipa/agc.h\n create mode 100644 src/ipa/libipa/exposure_mode_helper.cpp\n create mode 100644 src/ipa/libipa/exposure_mode_helper.h" }