{"id":20283,"url":"https://patchwork.libcamera.org/api/1.1/patches/20283/?format=json","web_url":"https://patchwork.libcamera.org/patch/20283/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20240613013944.23344-12-laurent.pinchart@ideasonboard.com>","date":"2024-06-13T01:39:44","name":"[11/11] ipa: libipa: pwl: Drop readYaml() function","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"d788f6d79d72179cc43156773fa54914ad6096e5","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/1.1/people/2/?format=json","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/20283/mbox/","series":[{"id":4386,"url":"https://patchwork.libcamera.org/api/1.1/series/4386/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=4386","date":"2024-06-13T01:39:33","name":"ipa: libipa: Vector and Pwl improvements","version":1,"mbox":"https://patchwork.libcamera.org/series/4386/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/20283/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/20283/checks/","tags":{},"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 9FBA1C3237\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 13 Jun 2024 01:40:33 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id A3B136549D;\n\tThu, 13 Jun 2024 03:40:32 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 84619654A1\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 13 Jun 2024 03:40:19 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id C2EE614F6;\n\tThu, 13 Jun 2024 03:40:05 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"hTz5uDl+\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1718242805;\n\tbh=+wDculNBA42w46q7XROhdckmjwuZrNAg860CH+vBi2g=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=hTz5uDl+WDcgJBOePD6ASOArqdNCow6A345psH+yx8XV+oMHpBYNyEtDcN2CpYGCN\n\tSe5UbfI1beCwaWF1JK7i9wOUb1fFHIlY/Tbm8cImhNdJo3+0xJKGWpeRL7wHZaCUME\n\t8aCSpc1ijTIwz4/0ouU2uLm3M66u+6d7TBI1DZ7U=","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"libcamera-devel@lists.libcamera.org","Cc":"Paul Elder <paul.elder@ideasonboard.com>,\n\tDavid Plowman <david.plowman@raspberrypi.com>,\n\tNaushir Patuck <naush@raspberrypi.com>","Subject":"[PATCH 11/11] ipa: libipa: pwl: Drop readYaml() function","Date":"Thu, 13 Jun 2024 04:39:44 +0300","Message-ID":"<20240613013944.23344-12-laurent.pinchart@ideasonboard.com>","X-Mailer":"git-send-email 2.44.2","In-Reply-To":"<20240613013944.23344-1-laurent.pinchart@ideasonboard.com>","References":"<20240613013944.23344-1-laurent.pinchart@ideasonboard.com>","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":"All users of the Pwl::readYaml() function have been removed. The\nfunction is not used, and is deprecated in favour of YamlObject::get().\nDrop it.\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n src/ipa/libipa/pwl.cpp | 38 --------------------------------------\n src/ipa/libipa/pwl.h   |  2 --\n 2 files changed, 40 deletions(-)","diff":"diff --git a/src/ipa/libipa/pwl.cpp b/src/ipa/libipa/pwl.cpp\nindex 3c639645fa3d..9b213754ec7d 100644\n--- a/src/ipa/libipa/pwl.cpp\n+++ b/src/ipa/libipa/pwl.cpp\n@@ -125,44 +125,6 @@ Pwl::Pwl(std::vector<Point> &&points)\n {\n }\n \n-/**\n- * \\brief Populate the piecewise linear function from yaml data\n- * \\param[in] params Yaml data to populate the piecewise linear function with\n- *\n- * Any existing points in the piecewise linear function *will* be overwritten.\n- *\n- * The yaml data is expected to be a list with an even number of numerical\n- * elements. These will be parsed in pairs into x and y points in the piecewise\n- * linear function, and added in order. x must be monotonically increasing.\n- *\n- * \\return 0 on success, negative error code otherwise\n- */\n-int Pwl::readYaml(const libcamera::YamlObject &params)\n-{\n-\tif (!params.size() || params.size() % 2)\n-\t\treturn -EINVAL;\n-\n-\tconst auto &list = params.asList();\n-\n-\tpoints_.clear();\n-\n-\tfor (auto it = list.begin(); it != list.end(); it++) {\n-\t\tauto x = it->get<double>();\n-\t\tif (!x)\n-\t\t\treturn -EINVAL;\n-\t\tif (it != list.begin() && *x <= points_.back().x())\n-\t\t\treturn -EINVAL;\n-\n-\t\tauto y = (++it)->get<double>();\n-\t\tif (!y)\n-\t\t\treturn -EINVAL;\n-\n-\t\tpoints_.push_back(Point({ *x, *y }));\n-\t}\n-\n-\treturn 0;\n-}\n-\n /**\n  * \\brief Append a point to the end of the piecewise linear function\n  * \\param[in] x x-coordinate of the point to add to the piecewise linear function\ndiff --git a/src/ipa/libipa/pwl.h b/src/ipa/libipa/pwl.h\nindex 8edb4d33dc71..b6f93494d807 100644\n--- a/src/ipa/libipa/pwl.h\n+++ b/src/ipa/libipa/pwl.h\n@@ -49,8 +49,6 @@ public:\n \tPwl(const std::vector<Point> &points);\n \tPwl(std::vector<Point> &&points);\n \n-\tint readYaml(const libcamera::YamlObject &params);\n-\n \tvoid append(double x, double y, double eps = 1e-6);\n \n \tbool empty() const { return points_.empty(); }\n","prefixes":["11/11"]}