pub struct ConvertSettings {
pub format: Option<TargetFormat>,
pub container: Container,
pub quality: Quality,
pub output_color_space: Option<ColorSpace>,
pub output_alpha: Option<AlphaMode>,
pub allow_discarding_alpha: bool,
pub swizzle: Option<Swizzle>,
pub mipmap: bool,
pub mipmap_count: Option<usize>,
pub mipmap_filter: MipmapFilter,
}Expand description
Settings for the high-level convert function.
Fields§
§format: Option<TargetFormat>Target format. If None, the input format is preserved without compression.
container: ContainerOutput container format. Defaults to KTX2 with no supercompression
(Container::Ktx2(None)).
quality: QualityEncoder quality preset for compressed targets. Ignored for uncompressed output.
output_color_space: Option<ColorSpace>Override the output color space. None keeps the input’s color space.
output_alpha: Option<AlphaMode>Override the output alpha mode. None keeps the input’s alpha mode.
allow_discarding_alpha: boolSuppress the warning emitted when a meaningful (Straight) alpha
channel is dropped because the target format has none. Does not change
pixel output.
swizzle: Option<Swizzle>Optional channel swizzle applied to each pixel before encoding.
mipmap: boolComplete the mip chain when true, preserving existing levels and
generating only the missing tail. When false, any existing mip levels
are preserved (and converted).
mipmap_count: Option<usize>Number of mip levels to retain or generate when mipmap is true.
None builds the full chain; larger-than-full values are clamped.
mipmap_filter: MipmapFilterDownsampling filter used for mipmap generation.