[{"id":5309,"web_url":"https://patchwork.libcamera.org/comment/5309/","msgid":"<20200622015748.GD25355@pendragon.ideasonboard.com>","date":"2020-06-22T01:57:48","subject":"Re: [libcamera-devel] [PATCH 0/3] libcamera sharpness strength\n\tcontrol","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi David,\n\nOn Fri, Jun 19, 2020 at 10:27:22AM +0100, David Plowman wrote:\n> Hi\n> \n> Here is a set of patches to implement a sharpness strength control for\n> libcamera. Unfortunately I couldn't quite bring myself to do it as an\n> int32_t control because it seems so similar to existing float controls\n> like contrast, or saturation. But if we'd rather go back to ints, as\n> previously suggested, just let me know and I'll redo the changes!\n\nI was going to ask after reading patch 1/3 :-) I think you're right\nhere, and if we want to go for int32_t, we should conver contract and\nsaturation (and brightness). That's a separate discussion.\n\n> There are 3 small patches in this set:\n> \n> 1. The first one just adds the \"sharpness\" control. This commit is\n> the only Raspberry Pi indpendent change (and doesn't even involve\n> any C++ code).\n> \n> 2. The second implements the control's effect in Raspberry Pi's\n> sharpness control algorithm.\n> \n> 3. The final patch just plumbs the two together.\n\nBonus points if someone could implement support for this control in the\nUVC pipeline handler ;-) As a reference, the two UVC devices I use most\noften for development report the V4L2 sharpeness control as\n\n- Integrated webcam\n\ncontrol 0x0098091b `Sharpness' min 1 max 7 step 1 default 2 current 2\n\n- Logitech C905\n\ncontrol 0x0098091b `Sharpness' min 0 max 255 step 1 default 191 current 191\n\nThe default value for the second one is quite \"interesting\".\n\n> David Plowman (3):\n>   libcamera: add a sharpness strength control\n>   libcamera: raspberrypi: add sharpness strength control to Raspberry Pi\n>     IPAs\n>   libcamera: raspberrypi: plumb the libcamera sharpness control through\n>     to the Raspberry Pi implementation\n> \n>  include/libcamera/ipa/raspberrypi.h           |  1 +\n>  .../raspberrypi/controller/rpi/sharpen.cpp    | 23 +++++++++++++++----\n>  .../raspberrypi/controller/rpi/sharpen.hpp    |  6 +++--\n>  .../controller/sharpen_algorithm.hpp          | 21 +++++++++++++++++\n>  .../raspberrypi/controller/sharpen_status.h   |  2 ++\n>  src/ipa/raspberrypi/raspberrypi.cpp           | 12 ++++++++++\n>  src/libcamera/control_ids.yaml                | 11 +++++++++\n>  7 files changed, 70 insertions(+), 6 deletions(-)\n>  create mode 100644 src/ipa/raspberrypi/controller/sharpen_algorithm.hpp","headers":{"Return-Path":"<laurent.pinchart@ideasonboard.com>","Received":["from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4CCBC609A3\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 22 Jun 2020 03:58:13 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-216-236.bb.dnainternet.fi\n\t[81.175.216.236])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id B8C51BB8;\n\tMon, 22 Jun 2020 03:58:12 +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=\"WnU2zRrq\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1592791092;\n\tbh=9tL00igNVMb3FNDmh5AV/9N3pfdAeqTZrI4im/HSTVc=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=WnU2zRrqscda8cWQCN8eqgMtAnd755bEL9czc2hB03TG1WuSroRkVZWTVXo5fQh14\n\t38cbrgSN7ve1cIvG/mD7xFsRDw0zltUip+HgrPzTovOYtpPYRWdS9Jcpj3V0sQAvfC\n\tW7gkfZ9a13xGyPszwmt97+CTsf6/qrPVQDDigxEI=","Date":"Mon, 22 Jun 2020 04:57:48 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"David Plowman <david.plowman@raspberrypi.com>","Cc":"libcamera-devel@lists.libcamera.org","Message-ID":"<20200622015748.GD25355@pendragon.ideasonboard.com>","References":"<20200619092725.19109-1-david.plowman@raspberrypi.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20200619092725.19109-1-david.plowman@raspberrypi.com>","Subject":"Re: [libcamera-devel] [PATCH 0/3] libcamera sharpness strength\n\tcontrol","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":"Mon, 22 Jun 2020 01:58:13 -0000"}}]