Trait librashader_runtime::scaling::MipmapSize
source · 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.