Struct allegro::shader::Shader

source ·
pub struct Shader { /* private fields */ }
Expand description

A shader program comprising of a pixel (fragment) and a vertex shader. Wraps ALLEGRO_SHADER.

Implementations

Return the wrapped Allegro shader pointer.

Attach a source to the shader. Passing None clears the source.

Returns the log if there was an error.

Attach a source to the shader that is loaded from a file.

Returns the log if there was an error.

Build the shader. Call this after attaching the sources.

Returns the log if there was an error.

Get the log from the shader. Call this function if any of the attach/build functions fail to determine what went wrong.

Return the platform of this shader.

Trait Implementations

Executes the destructor for this type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.