MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ read_normalized_at() [3/4]

MAYAFLUX_API double MayaFlux::Kakshya::read_normalized_at ( const DataVariant v,
Portal::Graphics::ImageFormat  format,
const std::optional< DataDimension::ValueRange > &  range,
size_t  elem_index 
)

Read one element as a normalised double, with optional range remapping.

Same as read_normalized_at, but if range is provided, the value is linearly remapped from [range.min, range.max] to [0.0, 1.0]. Values outside the range are clamped to 0.0 or 1.0.

Parameters
vSource variant.
formatPixel format governing the uint16 interpretation.
rangeOptional value range for remapping.
elem_indexElement index. Returns 0.0 when out of range.