Patch Detail
Show a patch.
GET /api/1.1/patches/4143/?format=api
{ "id": 4143, "url": "https://patchwork.libcamera.org/api/1.1/patches/4143/?format=api", "web_url": "https://patchwork.libcamera.org/patch/4143/", "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": "<20200623091404.15155-5-david.plowman@raspberrypi.com>", "date": "2020-06-23T09:14:04", "name": "[libcamera-devel,v3,4/4] libcamera: ipa: raspberrypi: plumb in the libcamera sharpness control", "commit_ref": "58732e4b49583e0b035980d71e8d15e76bbaf77b", "pull_url": null, "state": "accepted", "archived": false, "hash": "2e889b40d242e3f6b0f9e591095ea039fd384489", "submitter": { "id": 42, "url": "https://patchwork.libcamera.org/api/1.1/people/42/?format=api", "name": "David Plowman", "email": "david.plowman@raspberrypi.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/4143/mbox/", "series": [ { "id": 1029, "url": "https://patchwork.libcamera.org/api/1.1/series/1029/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=1029", "date": "2020-06-23T09:14:00", "name": "libcamera sharpness strength control", "version": 3, "mbox": "https://patchwork.libcamera.org/series/1029/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/4143/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/4143/checks/", "tags": {}, "headers": { "Return-Path": "<david.plowman@raspberrypi.com>", "Received": [ "from mail-wm1-x341.google.com (mail-wm1-x341.google.com\n\t[IPv6:2a00:1450:4864:20::341])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 2C8F8603BA\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 23 Jun 2020 11:14:14 +0200 (CEST)", "by mail-wm1-x341.google.com with SMTP id j18so2261542wmi.3\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 23 Jun 2020 02:14:14 -0700 (PDT)", "from pi4-davidp.lan (plowpeople3.plus.com. [80.229.223.72])\n\tby smtp.gmail.com with ESMTPSA id\n\tt125sm2931616wmf.10.2020.06.23.02.14.13\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tTue, 23 Jun 2020 02:14:13 -0700 (PDT)" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (2048-bit key; \n\tunprotected) header.d=raspberrypi.com\n\theader.i=@raspberrypi.com\n\theader.b=\"PQK1AD7h\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references\n\t:mime-version:content-transfer-encoding;\n\tbh=szZXl6QaV/4cRk25Zk5zyFZjAjLl0G9Vvu2sYyyNpS8=;\n\tb=PQK1AD7hL/a5xwomvk8/WvnAHXYRFTtU/iz73r5pnFlwWvXbcUJo13hDxACn0JWvZa\n\tFc0bDQYYfg4XtiMwgCnNLnujNmY3yst7ha/N8EAvtzjTaDNjJkX2kqWb9tGftOT3Jtn3\n\toeAUwU7qlznkd5LZWTVd8BI3u8BgxeE94v9y+5ve4YrZyCNKmNj0uyeXA7OFrwIL5T2M\n\tGcEfWLz9HhxqsIn84dLEv0SWGFveA7lTv08ZNvt3rLtNzwPCkEXjWqdaqaNPHuhEGAJU\n\t313C27DmC9kHCnlHo+3wzwhdr83UkZQMNYTsFyNhG8/LD50oqFl6QPfgO9i1g+CGMVpv\n\toAsw==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references:mime-version:content-transfer-encoding;\n\tbh=szZXl6QaV/4cRk25Zk5zyFZjAjLl0G9Vvu2sYyyNpS8=;\n\tb=X2StBMjASNr86sxYw8YWVhfUupdXRyOJOK093KDwUpXE5SzIcCjcCK5opbAtEAQspL\n\tQxKx1itC1SNhN5yoJPruvDX8LTf7eu3PIMd0y6rOdW/bzD+K6gElCq9bJ1p0kazV+zp9\n\t63drCmcDrFU/R0UBKVhjg5mz6BizFbdQMqVxk0fM78HTKZYPIcoSB7vBZ3LsWncWfseP\n\tkVwFEtX705RWrhdEIFBIp2WclX5WZvj1z9LChQGBJoLhSdVg3zvgTsNMbT8QCGyxwInO\n\tHypDUPcf/gyau0eN6ui63LvZYxmjj0HdKMxsdvZZ7+03/uGP+Pp/4rvr+NaqEDs+dKcb\n\t6n9Q==", "X-Gm-Message-State": "AOAM5305WwE02u+hm9c35lGC6IeTk65awlMnY53zU0NEOf2dO0KKRb1v\n\t4i2tNVtmML5uh/p987G/QC/godrFQ5o=", "X-Google-Smtp-Source": "ABdhPJxaXcGiDODwbcAaWs+EHYGtwgBt5GYEbE+9dE1HsOHv+Eof1u452eiNQOoswOuaGeCnCWxEHw==", "X-Received": "by 2002:a1c:308:: with SMTP id 8mr21819050wmd.125.1592903653663; \n\tTue, 23 Jun 2020 02:14:13 -0700 (PDT)", "From": "David Plowman <david.plowman@raspberrypi.com>", "To": "libcamera-devel@lists.libcamera.org", "Date": "Tue, 23 Jun 2020 10:14:04 +0100", "Message-Id": "<20200623091404.15155-5-david.plowman@raspberrypi.com>", "X-Mailer": "git-send-email 2.20.1", "In-Reply-To": "<20200623091404.15155-1-david.plowman@raspberrypi.com>", "References": "<20200623091404.15155-1-david.plowman@raspberrypi.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[libcamera-devel] [PATCH v3 4/4] libcamera: ipa: raspberrypi: plumb\n\tin the libcamera sharpness control", "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": "Tue, 23 Jun 2020 09:14:14 -0000" }, "content": "This simply wires up the libcamera sharpness control in the Raspberry\nPi IPAs so that it controls the strength of the Raspberry Pi sharpness\ncontrol algorithm.\n\nSigned-off-by: David Plowman <david.plowman@raspberrypi.com>\n---\n include/libcamera/ipa/raspberrypi.h | 1 +\n src/ipa/raspberrypi/raspberrypi.cpp | 12 ++++++++++++\n 2 files changed, 13 insertions(+)", "diff": "diff --git a/include/libcamera/ipa/raspberrypi.h b/include/libcamera/ipa/raspberrypi.h\nindex c109469..a18ce9a 100644\n--- a/include/libcamera/ipa/raspberrypi.h\n+++ b/include/libcamera/ipa/raspberrypi.h\n@@ -51,6 +51,7 @@ static const ControlInfoMap RPiControls = {\n \t{ &controls::Brightness, ControlInfo(-1.0f, 1.0f) },\n \t{ &controls::Contrast, ControlInfo(0.0f, 32.0f) },\n \t{ &controls::Saturation, ControlInfo(0.0f, 32.0f) },\n+\t{ &controls::Sharpness, ControlInfo(0.0f, 16.0f, 1.0f) },\n };\n \n } /* namespace libcamera */\ndiff --git a/src/ipa/raspberrypi/raspberrypi.cpp b/src/ipa/raspberrypi/raspberrypi.cpp\nindex 42c84b1..bc89ab5 100644\n--- a/src/ipa/raspberrypi/raspberrypi.cpp\n+++ b/src/ipa/raspberrypi/raspberrypi.cpp\n@@ -47,6 +47,7 @@\n #include \"metadata.hpp\"\n #include \"noise_status.h\"\n #include \"sdn_status.h\"\n+#include \"sharpen_algorithm.hpp\"\n #include \"sharpen_status.h\"\n \n namespace libcamera {\n@@ -633,6 +634,17 @@ void IPARPi::queueRequest(const ControlList &controls)\n \t\t\tbreak;\n \t\t}\n \n+\t\tcase controls::SHARPNESS: {\n+\t\t\tRPi::SharpenAlgorithm *sharpen = dynamic_cast<RPi::SharpenAlgorithm *>(\n+\t\t\t\tcontroller_.GetAlgorithm(\"sharpen\"));\n+\t\t\tASSERT(sharpen);\n+\n+\t\t\tsharpen->SetStrength(ctrl.second.get<float>());\n+\t\t\tlibcameraMetadata_.set(controls::Sharpness,\n+\t\t\t\t\t ctrl.second.get<float>());\n+\t\t\tbreak;\n+\t\t}\n+\n \t\tdefault:\n \t\t\tLOG(IPARPI, Warning)\n \t\t\t\t<< \"Ctrl \" << controls::controls.at(ctrl.first)->name()\n", "prefixes": [ "libcamera-devel", "v3", "4/4" ] }