Struct radiant_rs::postprocessors::Basic
[−]
[src]
pub struct Basic { /* fields omitted */ }
A basic postprocessor that applies a Program to the given input once.
Methods
impl Basic
[src]
fn new(context: &RenderContext,
program: Program,
texture_uniform_name: &str)
-> Self
program: Program,
texture_uniform_name: &str)
-> Self
Creates a new instance. Takes the name of the program uniform that is to receive the input sampler2D.
Trait Implementations
impl Postprocessor for Basic
[src]
type T = BlendMode
Custom type for the args parameter supplied to process()
and draw()
.
fn target(&self) -> &Texture
Expected to return a texture to draw to.
fn draw(&self, renderer: &Renderer, blendmode: &Self::T)
Expected to draw final result. Draws issued within this function will target the rendertarget that the postprocessor is supposed to render to. Read more
fn process(&self, renderer: &Renderer, args: &Self::T)
Expected to processes input data. Draws issued within this function will target the texure returned by target()
unless overridden via Renderer::render_to()
. This function is provided as you could also do this in draw()
. Read more