50 T
Min() const noexcept
72 T
Max() const noexcept
97 return !(value < min_ || value < max_);
109 return !(min_ > other.max_ || max_ < other.min_);
120 return min_ == valueRange.min_
121 && max_ == valueRange.max_;
132 return !(*
this == valueRange);
140 "CVB: Unsupported data type - target must be floating point, source must be numeric!");
141 return ValueRange<C>(static_cast<C>(min_), static_cast<C>(max_));
163 return ValueRange<int>(static_cast<int>(std::round(rhs.Min())), static_cast<int>(std::round(rhs.Max())));
void SetMin(T min)
Sets the minimum value.
Definition: value_range.hpp:60
bool Contains(T value) const noexcept
Checks if a value is within the range.
Definition: value_range.hpp:95
Point2D< int > Round(const Point2D< T > &rhs) noexcept
Round to an integer point.
Definition: point_2d.hpp:380
void SetMax(T max)
Sets the maximum value.
Definition: value_range.hpp:82
T Min() const noexcept
Gets the minimum value.
Definition: value_range.hpp:50
T Max() const noexcept
Gets the maximum value.
Definition: value_range.hpp:72
Root namespace for the Image Manager interface.
Definition: version.hpp:11
bool IntersectsWith(ValueRange< T > other) const noexcept
Checks if this value range intersects with another value range.
Definition: value_range.hpp:107
ValueRange() noexcept=default
Creates a default value range e.g. from 0 to 0.
bool operator==(const ValueRange< T > &valueRange) const noexcept
Compares to an other value range.
Definition: value_range.hpp:118
Container for range definitions.
Definition: value_range.hpp:16
ValueRange(T min, T max)
Initializes a ValueRange object.
Definition: value_range.hpp:34
bool operator!=(const ValueRange< T > &valueRange) const noexcept
Compares to an other value range.
Definition: value_range.hpp:130