oa::image::channel_reorder

Reorder one to four channels and explicitly assign the resulting format. order[c] selects the source channel for output channel c. The output format must have the same channel count as the input so pixel data and semantic metadata cannot diverge.

FnRust public API

Function Documentation

pub fn channel_reorder( input: &Image, order: [u32; 4], output_format: ImageFormat ) -> Result<Image>
Reorder one to four channels and explicitly assign the resulting format. order[c] selects the source channel for output channel c. The output format must have the same channel count as the input so pixel data and semantic metadata cannot diverge.