pub trait Sample<T> {
// Required method
fn sample(
&self,
shutter: &Shutter,
samples: NonZeroU16,
) -> Result<Vec<(T, SampleWeight)>>;
}Expand description
Required Methods§
Sourcefn sample(
&self,
shutter: &Shutter,
samples: NonZeroU16,
) -> Result<Vec<(T, SampleWeight)>>
fn sample( &self, shutter: &Shutter, samples: NonZeroU16, ) -> Result<Vec<(T, SampleWeight)>>
Generate samples across the shutter interval.
Returns a vector of value-weight pairs for the specified number of samples distributed across the shutter’s time range.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementors§
impl Sample<Color> for AnimatedData
impl Sample<Color> for TimeDataMap<Color>
impl Sample<Color> for Value
impl Sample<Integer> for AnimatedData
impl Sample<Integer> for TimeDataMap<Integer>
impl Sample<Integer> for Value
impl Sample<Matrix3> for AnimatedData
Available on crate feature
matrix3 only.impl Sample<Matrix3> for TimeDataMap<Matrix3>
Available on crate features
builtin-types and matrix3 only.impl Sample<Matrix3> for Value
impl Sample<Real> for AnimatedData
impl Sample<Real> for TimeDataMap<Real>
impl Sample<Real> for Value
impl Sample<Vector2> for AnimatedData
Available on crate feature
vector2 only.