Struct webrender::command_buffer::Command
source · pub struct Command(u32);
Expand description
A tightly packed command stored in a command buffer
Tuple Fields§
§0: u32
Implementations§
source§impl Command
impl Command
sourceconst CMD_DRAW_SIMPLE_PRIM: u32 = 0u32
const CMD_DRAW_SIMPLE_PRIM: u32 = 0u32
Draw a simple primitive that needs prim instance index only.
sourceconst CMD_SET_SPATIAL_NODE: u32 = 268_435_456u32
const CMD_SET_SPATIAL_NODE: u32 = 268_435_456u32
Change the current spatial node.
sourceconst CMD_DRAW_COMPLEX_PRIM: u32 = 536_870_912u32
const CMD_DRAW_COMPLEX_PRIM: u32 = 536_870_912u32
Draw a complex (3d-split) primitive, that has multiple GPU cache addresses.
sourceconst CMD_DRAW_INSTANCE: u32 = 805_306_368u32
const CMD_DRAW_INSTANCE: u32 = 805_306_368u32
Draw a primitive, that has a single GPU buffer addresses.
sourceconst CMD_DRAW_QUAD: u32 = 1_073_741_824u32
const CMD_DRAW_QUAD: u32 = 1_073_741_824u32
Draw a generic quad primitive
sourceconst CMD_SET_SEGMENTS: u32 = 1_342_177_280u32
const CMD_SET_SEGMENTS: u32 = 1_342_177_280u32
Set a list of variable-length segments
sourceconst PARAM_MASK: u32 = 268_435_455u32
const PARAM_MASK: u32 = 268_435_455u32
Bitmask for param bits of the command.
sourcefn draw_simple_prim(prim_instance_index: PrimitiveInstanceIndex) -> Self
fn draw_simple_prim(prim_instance_index: PrimitiveInstanceIndex) -> Self
Encode drawing a simple primitive.
sourcefn set_spatial_node(spatial_node_index: SpatialNodeIndex) -> Self
fn set_spatial_node(spatial_node_index: SpatialNodeIndex) -> Self
Encode changing spatial node.
sourcefn set_segments(count: usize) -> Self
fn set_segments(count: usize) -> Self
Encode a list of segments that follow
sourcefn draw_complex_prim(prim_instance_index: PrimitiveInstanceIndex) -> Self
fn draw_complex_prim(prim_instance_index: PrimitiveInstanceIndex) -> Self
Encode drawing a complex prim.
fn draw_instance(prim_instance_index: PrimitiveInstanceIndex) -> Self
fn draw_quad(prim_instance_index: PrimitiveInstanceIndex) -> Self
Trait Implementations§
impl Copy for Command
Auto Trait Implementations§
impl Freeze for Command
impl RefUnwindSafe for Command
impl Send for Command
impl Sync for Command
impl Unpin for Command
impl UnwindSafe for Command
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>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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