Type Alias png::decoder::transform::TransformFn
source · pub type TransformFn = Box<dyn Fn(&[u8], &mut [u8], &Info<'_>) + Send + Sync>;
Expand description
Type of a function that can transform a decompressed, unfiltered row (the 1st argument) into the final pixels (the 2nd argument), optionally using image metadata (e.g. PLTE data can be accessed using the 3rd argument).
TODO: If some precomputed state is needed (e.g. to make expand_paletted...
faster) then consider changing this into Box<dyn Fn(...)>
.
Aliased Type§
struct TransformFn(/* private fields */);