pub trait MipmapSize<T> {
// Required methods
fn calculate_miplevels(self) -> T;
fn scale_mipmap(self, miplevel: T) -> Size<T>;
}
Expand description
Trait for size scaling relating to mipmap generation.
Required Methods§
Sourcefn calculate_miplevels(self) -> T
fn calculate_miplevels(self) -> T
Calculate the number of mipmap levels for a given size.
Sourcefn scale_mipmap(self, miplevel: T) -> Size<T>
fn scale_mipmap(self, miplevel: T) -> Size<T>
Scale the size according to the given mipmap level. The size will at minimum be 1x1, and at a maximum 16384x16384.