[][src]Struct luminance::shader::Program

pub struct Program<B: ?Sized, Sem, Out, Uni> where
    B: Shader
{ /* fields omitted */ }

A shader program.

Shader programs are GPU binaries that execute when a draw command is issued.

Parametricity

Implementations

impl<B: ?Sized, Sem, Out, Uni> Program<B, Sem, Out, Uni> where
    B: Shader,
    Sem: Semantics
[src]

pub fn adapt<Q>(
    self
) -> Result<BuiltProgram<B, Sem, Out, Q>, AdaptationFailure<B, Sem, Out, Uni>> where
    Q: UniformInterface<B>, 
[src]

Create a new UniformInterface but keep the Program around without rebuilding it.

Parametricity

pub fn adapt_env<Q, E>(
    self,
    env: &mut E
) -> Result<BuiltProgram<B, Sem, Out, Q>, AdaptationFailure<B, Sem, Out, Uni>> where
    Q: UniformInterface<B, E>, 
[src]

Create a new UniformInterface but keep the Program around without rebuilding it, by using a mutable environment variable.

Parametricity

pub fn readapt_env<E>(
    self,
    env: &mut E
) -> Result<BuiltProgram<B, Sem, Out, Uni>, AdaptationFailure<B, Sem, Out, Uni>> where
    Uni: UniformInterface<B, E>, 
[src]

Re-create the UniformInterface but keep the Program around without rebuilding it.

Parametricity

  • E is the mutable environment variable.

Auto Trait Implementations

impl<B: ?Sized, Sem, Out, Uni> RefUnwindSafe for Program<B, Sem, Out, Uni> where
    Out: RefUnwindSafe,
    Sem: RefUnwindSafe,
    Uni: RefUnwindSafe,
    <B as Shader>::ProgramRepr: RefUnwindSafe

impl<B, Sem, Out, Uni> !Send for Program<B, Sem, Out, Uni>

impl<B, Sem, Out, Uni> !Sync for Program<B, Sem, Out, Uni>

impl<B: ?Sized, Sem, Out, Uni> Unpin for Program<B, Sem, Out, Uni> where
    Uni: Unpin,
    <B as Shader>::ProgramRepr: Unpin

impl<B: ?Sized, Sem, Out, Uni> UnwindSafe for Program<B, Sem, Out, Uni> where
    Out: RefUnwindSafe,
    Sem: RefUnwindSafe,
    Uni: UnwindSafe,
    <B as Shader>::ProgramRepr: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.