pub fn from_array_slice_mut<T>(values: &mut [T::Array]) -> &mut [T]
where T: ArrayCast,
Expand description

Cast from a mutable slice of arrays to a mutable slice of colors.

use palette::{cast, Srgb};

let arrays = &mut [[64, 139, 10], [93, 18, 214]];
assert_eq!(
    cast::from_array_slice_mut::<Srgb<u8>>(arrays),
    &mut [Srgb::new(64u8, 139, 10), Srgb::new(93, 18, 214)]
)