summaryrefslogtreecommitdiff
path: root/src/ipa/libipa/pwl.cpp
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2024-06-13 03:21:46 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2024-06-16 03:28:25 +0300
commit0706c67711839c88accaf577ac27f7473137febe (patch)
tree4b0e1c62c14464d9dd49dedba20f4699526d7b60 /src/ipa/libipa/pwl.cpp
parente127e63c93f8d04de0a564eae5e5cb40b80260f5 (diff)
ipa: libipa: pwl: Add a size() function
Add a size() function to the Pwl class to return the number of points in the piecewise linear function. This is useful, for instance, to validate that all points added with append() or prepend() have been taken into account. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'src/ipa/libipa/pwl.cpp')
-rw-r--r--src/ipa/libipa/pwl.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/ipa/libipa/pwl.cpp b/src/ipa/libipa/pwl.cpp
index d8ea92be..8b437dd1 100644
--- a/src/ipa/libipa/pwl.cpp
+++ b/src/ipa/libipa/pwl.cpp
@@ -189,6 +189,12 @@ void Pwl::prepend(double x, double y, const double eps)
*/
/**
+ * \fn Pwl::size() const
+ * \brief Retrieve the number of points in the piecewise linear function
+ * \return The number of points in the piecewise linear function
+ */
+
+/**
* \brief Get the domain of the piecewise linear function
* \return An interval representing the domain
*/