Struct glitter::program::Program [] [src]

pub struct Program {
    // some fields omitted
}

An OpenGL program object.

A program is used in OpenGL to customize the render pipeline. A program is composed of multiple Shader objects, each of which computes one step in the render pipeline, and feed data to the next program.

A program will automatically be deleted after going out of scope.

See also

gl.build_shader: Build and link a new program object

gl.create_program: Create a new, empty program object.

gl.use_program: Bind a program to use for drawing calls, returning a ProgramBinding type.

Trait Implementations

impl Drop for Program
[src]

fn drop(&mut self)

A method called when the value goes out of scope. Read more

impl GLObject for Program
[src]

type Id = GLuint

The type of the object's internal ID.

unsafe fn from_raw(id: Self::Id) -> Self

Get a new object from an OpenGL ID. Read more

fn id(&self) -> Self::Id

Get the object's ID.

fn into_raw(self) -> Self::Id where Self: Sized

Consume the object without cleaning up its resources, returning the object's ID. Read more