summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/libcamera/geometry.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/libcamera/geometry.cpp b/src/libcamera/geometry.cpp
index 1ea10293..e598f6ad 100644
--- a/src/libcamera/geometry.cpp
+++ b/src/libcamera/geometry.cpp
@@ -267,6 +267,20 @@ bool operator<(const Size &lhs, const Size &rhs)
*/
/**
+ * \brief Assemble and return a string describing the size range
+ * \return A string describing the SizeRange
+ */
+std::string SizeRange::toString() const
+{
+ std::stringstream ss;
+
+ ss << "(" << min.toString() << ")-(" << max.toString() << ")/(+"
+ << hStep << ",+" << vStep << ")";
+
+ return ss.str();
+}
+
+/**
* \brief Compare size ranges for equality
* \return True if the two size ranges are equal, false otherwise
*/