Struct glitter::context::program_context::ProgramBuilder
[−]
[src]
pub struct ProgramBuilder<'a, C> where
C: AContext + 'a, { /* fields omitted */ }
Provides a safe interface for creating program objects. A
ProgramBuilder
can be created using the gl.build_program
method.
Methods
impl<'a, C> ProgramBuilder<'a, C> where
C: AContext,
[src]
C: AContext,
fn new(gl: &'a C, shaders: &'a [Shader]) -> Self
[src]
Create a new program builder.
fn try_unwrap(self) -> Result<Program, GLError>
[src]
Create and link the program object with the provided shaders, or return an error.
Failures
An error will be returned if there was an error linking the program object.
Panics
This function will panic if an OpenGL error was generated with debug assertions enabled.
fn unwrap(self) -> Program
[src]
Create and link the program object with the provided shaders, or panic.
Panics
This function will panic if there was an error linking the program object or if an OpenGL error was generated with debug assertions enabled.