#[non_exhaustive]pub struct GpuFrame<'a> { /* private fields */ }Expand description
One frame of a GPU view, as its renderer encodes it.
Implementations§
Source§impl<'a> GpuFrame<'a>
impl<'a> GpuFrame<'a>
Sourcepub fn new(parts: GpuFrameParts<'a>) -> Self
pub fn new(parts: GpuFrameParts<'a>) -> Self
A frame of parts (made by the runtime that runs renderers).
Sourcepub fn queue(&self) -> &Queue
pub fn queue(&self) -> &Queue
The device’s queue: buffer and texture writes made here land before the frame’s commands.
Sourcepub fn target(&self) -> &TextureView
pub fn target(&self) -> &TextureView
Where the frame is drawn: clear it first.
Sourcepub fn format(&self) -> TextureFormat
pub fn format(&self) -> TextureFormat
The target’s format: 8-bit unsigned normalized, RGBA or BGRA.
Sourcepub fn encoder(&mut self) -> &mut CommandEncoder
pub fn encoder(&mut self) -> &mut CommandEncoder
The encoder the frame’s commands go to; NSH submits it.
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for GpuFrame<'a>
impl<'a> !UnwindSafe for GpuFrame<'a>
impl<'a> Forget for GpuFrame<'a>
impl<'a> Freeze for GpuFrame<'a>
impl<'a> Move for GpuFrame<'a>
impl<'a> Send for GpuFrame<'a>where
&'a Device: Send,
&'a Queue: Send,
&'a TextureView: Send,
Arc<Global>: Send,
NonZero<u64>: Send,
Arc<Mutex<ErrorSinkRaw>>: Send,
Arc<Mutex<DeferredCommandBufferActions>>: Send,
RawVecInner: Send,
Arc<str>: Send,
NodeRef<Owned, String, Value, LeafOrInternal>: Send,
BoxRaw<(String, Value)>: Send,
impl<'a> Sync for GpuFrame<'a>where
Arc<CoreDevice>: Sync,
Arc<CoreQueue>: Sync,
Arc<CoreTextureView>: Sync,
Arc<CoreTexture>: Sync,
InternalBitFlags: Sync,
Arc<Global>: Sync,
NonZero<u64>: Sync,
Arc<Mutex<ErrorSinkRaw>>: Sync,
Arc<Mutex<DeferredCommandBufferActions>>: Sync,
RawVecInner: Sync,
Arc<str>: Sync,
NodeRef<Owned, String, Value, LeafOrInternal>: Sync,
BoxRaw<(String, Value)>: Sync,
impl<'a> Unpin for GpuFrame<'a>
impl<'a> UnsafeUnpin for GpuFrame<'a>where
&'a Device: UnsafeUnpin,
&'a Queue: UnsafeUnpin,
&'a TextureView: UnsafeUnpin,
&'a mut CommandEncoder: UnsafeUnpin,
&'a mut Vec<GpuEvent>: UnsafeUnpin,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more