Enum webrender::render_task::RenderTaskLocation
source · pub enum RenderTaskLocation {
Unallocated {
size: DeviceIntSize,
},
CacheRequest {
size: DeviceIntSize,
},
Existing {
parent_task_id: RenderTaskId,
size: DeviceIntSize,
},
Dynamic {
texture_id: CacheTextureId,
rect: DeviceIntRect,
},
Static {
surface: StaticRenderTaskSurface,
rect: DeviceIntRect,
},
}
Expand description
Identifies the output buffer location for a given RenderTask
.
Variants§
Unallocated
Fields
§
size: DeviceIntSize
Requested size of this render task
A dynamic task that has not yet been allocated a texture and rect.
CacheRequest
Fields
§
size: DeviceIntSize
Will be replaced by a Static location after the texture cache update.
Existing
Same allocation as an existing task deeper in the dependency graph
Dynamic
Fields
§
texture_id: CacheTextureId
Texture that this task was allocated to render on
§
rect: DeviceIntRect
Rectangle in the texture this task occupies
The RenderTask
should be drawn to a target provided by the atlas
allocator. This is the most common case.
Static
Fields
§
surface: StaticRenderTaskSurface
Target to draw to
§
rect: DeviceIntRect
Rectangle in the texture this task occupies
A task that is output to a persistent / retained target.
Implementations§
source§impl RenderTaskLocation
impl RenderTaskLocation
sourcepub fn is_dynamic(&self) -> bool
pub fn is_dynamic(&self) -> bool
Returns true if this is a dynamic location.
pub fn size(&self) -> DeviceIntSize
Trait Implementations§
source§impl Clone for RenderTaskLocation
impl Clone for RenderTaskLocation
source§fn clone(&self) -> RenderTaskLocation
fn clone(&self) -> RenderTaskLocation
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for RenderTaskLocation
impl Debug for RenderTaskLocation
Auto Trait Implementations§
impl RefUnwindSafe for RenderTaskLocation
impl Send for RenderTaskLocation
impl Sync for RenderTaskLocation
impl Unpin for RenderTaskLocation
impl UnwindSafe for RenderTaskLocation
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
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>where
F: FnOnce(&Self) -> bool,
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>where F: FnOnce(&Self) -> bool,
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more