Struct bevy_retrograde::core::luminance::shader::Program [−]
Expand description
A shader program.
Shader programs are GPU binaries that execute when a draw command is issued.
Parametricity
B
is the backend type.Sem
is theSemantics
type.Out
is the render target type.Uni
is theUniformInterface
type.
Implementations
pub fn adapt<Q>(
self
) -> Result<BuiltProgram<B, Sem, Out, Q>, AdaptationFailure<B, Sem, Out, Uni>> where
Q: UniformInterface<B, ()>,
pub fn adapt<Q>(
self
) -> Result<BuiltProgram<B, Sem, Out, Q>, AdaptationFailure<B, Sem, Out, Uni>> where
Q: UniformInterface<B, ()>,
Create a new UniformInterface
but keep the Program
around without rebuilding it.
Parametricity
Q
is the newUniformInterface
.
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>,
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>,
Create a new UniformInterface
but keep the Program
around without rebuilding it, by
using a mutable environment variable.
Parametricity
Q
is the newUniformInterface
.E
is the mutable environment variable.
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>,
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>,
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: ?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
Mutably borrows from an owned value. Read more
impl<T> Downcast for T where
T: Any,
impl<T> Downcast for T where
T: Any,
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read more
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read more
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read more
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
pub fn vzip(self) -> V