Trait amethyst_renderer::target::Target
[−]
[src]
pub trait Target: Any { }
A Target or a RenderTarget is any object that can be the target of a Layer This is normally a framebuffer
Methods
impl Target
fn is<T: Target>(&self) -> bool
Returns true if the boxed type is the same as T
fn downcast_ref<T: Target>(&self) -> Option<&T>
Returns some reference to the boxed value if it is of type T
, or
None
if it isn't.
unsafe fn downcast_ref_unchecked<T: Target>(&self) -> &T
Returns a reference to the boxed value, blindly assuming it to be of type T
.
If you are not absolutely certain of T
, you must not call this.
fn downcast_mut<T: Target>(&mut self) -> Option<&mut T>
Returns some mutable reference to the boxed value if it is of type T
, or
None
if it isn't.
unsafe fn downcast_mut_unchecked<T: Target>(&mut self) -> &mut T
Returns a mutable reference to the boxed value, blindly assuming it to be of type T
.
If you are not absolutely certain of T
, you must not call this.
impl Target
fn downcast<T: Target>(self: Box<Self>) -> Result<Box<T>, Box<Self>>
Returns the boxed value if it is of type T
, or Err(Self)
if it isn't.
unsafe fn downcast_unchecked<T: Target>(self: Box<Self>) -> Box<T>
Returns the boxed value, blindly assuming it to be of type T
.
If you are not absolutely certain of T
, you must not call this.
Implementors
impl<R: Resources> Target for ColorBuffer<R>
impl<R: Resources> Target for GeometryBuffer<R>