Struct librashader::presets::ShaderPassConfig
source · pub struct ShaderPassConfig {
pub id: i32,
pub name: PathBuf,
pub alias: Option<String>,
pub filter: FilterMode,
pub wrap_mode: WrapMode,
pub frame_count_mod: u32,
pub srgb_framebuffer: bool,
pub float_framebuffer: bool,
pub mipmap_input: bool,
pub scaling: Scale2D,
}
presets
only.Expand description
The configuration for a single shader pass.
Fields§
§id: i32
The index of the shader pass relative to its parent preset.
name: PathBuf
The fully qualified path to the shader pass source file.
alias: Option<String>
The alias of the shader pass if available.
filter: FilterMode
The filtering mode that this shader pass should expect.
wrap_mode: WrapMode
The texture addressing (wrap) mode that this shader pass expects.
frame_count_mod: u32
The number to which to wrap the frame count before passing it to the uniforms.
srgb_framebuffer: bool
Whether or not this shader pass expects an SRGB framebuffer output.
float_framebuffer: bool
Whether or not this shader pass expects an float framebuffer output.
mipmap_input: bool
Whether or not to generate mipmaps for the input texture before passing to the shader.
scaling: Scale2D
Specifies the scaling of the output framebuffer for this shader pass.
Implementations§
source§impl ShaderPassConfig
impl ShaderPassConfig
sourcepub fn get_format_override(&self) -> Option<ImageFormat>
pub fn get_format_override(&self) -> Option<ImageFormat>
If the framebuffer expects a different format than what was defined in the shader source, returns such format.
pub fn get_frame_count(&self, count: usize) -> u32
Trait Implementations§
source§impl Clone for ShaderPassConfig
impl Clone for ShaderPassConfig
source§fn clone(&self) -> ShaderPassConfig
fn clone(&self) -> ShaderPassConfig
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more