pub trait IntoUnitInterval {
// Required method
fn into_unit_interval(self) -> Result<UnitIntervalValue, ImagePyramidError>;
}
Expand description
A trait describing some floating-point type that can be converted to a unit-interval value (0.0 to 1.0, exclusive)
Required Methods§
Sourcefn into_unit_interval(self) -> Result<UnitIntervalValue, ImagePyramidError>
fn into_unit_interval(self) -> Result<UnitIntervalValue, ImagePyramidError>
Attempts to convert this value into a guaranteed unit-interval value.
Returns an error string if the value is not valid.
§Errors
- The value is not within the unit range