Trait palette::num::FromScalar
source · pub trait FromScalar {
type Scalar;
// Required method
fn from_scalar(scalar: Self::Scalar) -> Self;
}
Expand description
Trait for creating a vectorized value from a scalar value.
Required Associated Types§
Required Methods§
sourcefn from_scalar(scalar: Self::Scalar) -> Self
fn from_scalar(scalar: Self::Scalar) -> Self
Create a new vectorized value where each lane is scalar
. This
corresponds to splat
for SIMD types.
Object Safety§
This trait is not object safe.