pub fn decode_dds_rgba(data: &[u8], mipmap: u32) -> Result<RgbaImage>Expand description
Decodes a mipmap of a DDS texture to RGBA pixels.
§Arguments
data- The DDS file.mipmap- Level to decode, 0 being the largest. Levels past the last one decode the last one.
§Returns
The pixels of the mipmap.
§Errors
Returns an error if the data is not a DDS texture, or its format can’t be decoded.