[{"id":23415,"web_url":"https://patchwork.libcamera.org/comment/23415/","msgid":"<YqrnQ9ybwS0Sxt2J@pendragon.ideasonboard.com>","date":"2022-06-16T08:18:11","subject":"Re: [libcamera-devel] [PATCH v2 1/5] pipeline: rkisp1: Support IPA\n\ttuning file","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Florian,\n\nThank you for the patch.\n\nOn Thu, Jun 16, 2022 at 10:07:40AM +0200, Florian Sylvestre via libcamera-devel wrote:\n> Allow the usage of a Yaml IPA tuning file that is either defined by\n\ns/Yaml/YAML/\n\n> the sensor name (sensor_name.yaml) or defined by\n> LIBCAMERA_RKISP1_TUNING_FILE environment variable.\n> \n> Signed-off-by: Florian Sylvestre <fsylvestre@baylibre.com>\n\nYou can pick the tags that you have received for the previous version of\na patch when you post the new version. This would be\n\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\nReviewed-by: Paul Elder <paul.elder@ideasonboard.com>\n\nwith the small changes from this review applied.\n\nIf there's no other reason to send a v3, I can handle this when\napplying.\n\n> ---\n>  src/libcamera/pipeline/rkisp1/rkisp1.cpp | 13 ++++++++++++-\n>  1 file changed, 12 insertions(+), 1 deletion(-)\n> \n> diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> index 4b3d2cf7..96bf09e3 100644\n> --- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> +++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> @@ -322,7 +322,18 @@ int RkISP1CameraData::loadIPA(unsigned int hwRevision)\n>  \tipa_->paramsBufferReady.connect(this, &RkISP1CameraData::paramFilled);\n>  \tipa_->metadataReady.connect(this, &RkISP1CameraData::metadataReady);\n>  \n> -\tint ret = ipa_->init(IPASettings{ \"\", sensor_->model() }, hwRevision);\n> +\t/*\n> +\t * The API tuning file is made from the sensor name unless\n> +\t * the environment variable overrides it.\n> +\t */\n> +\tstd::string IPATunigFile;\n\nipaTuningFile\n\n> +\tchar const *configFromEnv = utils::secure_getenv(\"LIBCAMERA_RKISP1_TUNING_FILE\");\n> +\tif (!configFromEnv || *configFromEnv == '\\0')\n> +\t\tIPATunigFile = ipa_->configurationFile(sensor_->model() + \".yaml\");\n> +\telse\n> +\t\tIPATunigFile = std::string(configFromEnv);\n> +\n> +\tint ret = ipa_->init({ IPATunigFile, sensor_->model() }, hwRevision);\n>  \tif (ret < 0) {\n>  \t\tLOG(RkISP1, Error) << \"IPA initialization failure\";\n>  \t\treturn ret;","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 2E37FBD808\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 16 Jun 2022 08:18:25 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 8359065637;\n\tThu, 16 Jun 2022 10:18:24 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 39B99601F1\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 16 Jun 2022 10:18:23 +0200 (CEST)","from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi\n\t[62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id AA9D030B;\n\tThu, 16 Jun 2022 10:18:22 +0200 (CEST)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1655367504;\n\tbh=z2poZKhnC5KS7DAAdxBZfVr3pUThMzzj1/0Xzq7uS9w=;\n\th=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=1VIA0eJSHcTt8CkWb3lIEISCTQuSh+x0q9lt+Ha3qdiAy9ht7GClJCz8htWlZ7kMP\n\tAinnj4yWlWproNfWInxarDM7PQXwnoHYj7UzYh60E8pLaULVV1FHCY+TQCz9VosmrM\n\tJZjYcfeoZD8xXDZ1GDfpp/RMzVHiaSJAEBkxBtgUnm3u48w3erTUzUybB7lZg59M40\n\tEPQMRbkW2SpP1/hdsq98s2T+KMSWKFkJ6ffz6HRRpRmWEXnCFz7LotWxJpOYDdcGeD\n\trGUyrk+F8AgwfrhYxL1YW+6lMGyClMwed4YKt4T5C81uh6zSIE350BcofqgEqLkYVH\n\t+xOO8o0GNH/vw==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1655367502;\n\tbh=z2poZKhnC5KS7DAAdxBZfVr3pUThMzzj1/0Xzq7uS9w=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=Os6/L7hoSQRqapdpnKQ2nbtvCLp53m3stpinqstPPeSYSIat1tryqQi5/OiYAvPIi\n\trj2DIX8QrvznDfU//QRCMBNj7OcF+F6793VFCW7dkfq1q1unWVwScLSBHZaf5eg0uM\n\t5jQXN5eWJQbuYCACT2u+gtov5f9IA5ZuTju3iVRE="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"Os6/L7ho\"; dkim-atps=neutral","Date":"Thu, 16 Jun 2022 11:18:11 +0300","To":"Florian Sylvestre <fsylvestre@baylibre.com>","Message-ID":"<YqrnQ9ybwS0Sxt2J@pendragon.ideasonboard.com>","References":"<20220616080744.548995-1-fsylvestre@baylibre.com>\n\t<20220616080744.548995-2-fsylvestre@baylibre.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20220616080744.548995-2-fsylvestre@baylibre.com>","Subject":"Re: [libcamera-devel] [PATCH v2 1/5] pipeline: rkisp1: Support IPA\n\ttuning file","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>","From":"Laurent Pinchart via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]