Skip to main content

PrepareCx

Struct PrepareCx 

Source
pub struct PrepareCx<'a, T: 'static> { /* private fields */ }
Expand description

Borrowed context for LayerInstance::prepare.

Implementations§

Source§

impl<'a, T: 'static> PrepareCx<'a, T>

Source

pub fn evaluated(&self) -> EvaluatedLayer<'a>

Source

pub fn frame(&self) -> Frame<'a>

Source

pub fn projection_variant(&self) -> ProjectionVariant

Source

pub fn tile_count(&self) -> usize

Source

pub fn tile(&self, index: usize) -> Option<Tile<'a>>

Source

pub fn tiles(&self) -> impl Iterator<Item = Tile<'a>> + '_

Source

pub fn resources(&mut self) -> Resources<'_>

Source

pub fn tile_resources_and_allocator( &mut self, tile_id: TileId, ) -> (Option<&mut T>, Resources<'_>)

Mutably borrows the tile resources for tile_id together with Resources.

Source

pub fn tile_resources_mut(&mut self, tile_id: TileId) -> Option<&mut T>

Source

pub fn take_tile_changes(&mut self, tile_id: TileId) -> TileChanges

Source

pub fn picked_tiles(&self) -> Vec<TileId>

Source

pub fn read_shared_target(&mut self, name: &str) -> Option<Texture>

Auto Trait Implementations§

§

impl<'a, T> !RefUnwindSafe for PrepareCx<'a, T>

§

impl<'a, T> !Send for PrepareCx<'a, T>

§

impl<'a, T> !Sync for PrepareCx<'a, T>

§

impl<'a, T> !UnwindSafe for PrepareCx<'a, T>

§

impl<'a, T> Forget for PrepareCx<'a, T>

§

impl<'a, T> Freeze for PrepareCx<'a, T>
where &'a dyn EvaluatedLayerBackend: Freeze, &'a dyn FrameBackend: Freeze, &'a dyn PrepareCxReadBackend: Freeze, &'a mut dyn PrepareCxMutBackend: Freeze, PhantomData<*mut T>: Freeze,

§

impl<'a, T> Move for PrepareCx<'a, T>

§

impl<'a, T> Unpin for PrepareCx<'a, T>
where &'a dyn EvaluatedLayerBackend: Unpin, &'a dyn FrameBackend: Unpin, &'a dyn PrepareCxReadBackend: Unpin, &'a mut dyn PrepareCxMutBackend: Unpin, *mut T: Unpin,

§

impl<'a, T> UnsafeUnpin for PrepareCx<'a, T>
where &'a dyn EvaluatedLayerBackend: UnsafeUnpin, &'a dyn FrameBackend: UnsafeUnpin, &'a dyn PrepareCxReadBackend: UnsafeUnpin, &'a mut dyn PrepareCxMutBackend: UnsafeUnpin, PhantomData<*mut T>: UnsafeUnpin,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.