pub enum PrimitiveTemplateKind {
Rectangle {
color: PropertyBinding<ColorF>,
},
Clear,
}
Expand description
The shared information for a given primitive. This is interned and retained both across frames and display lists, by comparing the matching PrimitiveKey.
Variants§
Implementations§
source§impl PrimitiveTemplateKind
impl PrimitiveTemplateKind
sourcepub fn write_prim_gpu_blocks(
&self,
request: &mut GpuDataRequest<'_>,
scene_properties: &SceneProperties,
)
pub fn write_prim_gpu_blocks( &self, request: &mut GpuDataRequest<'_>, scene_properties: &SceneProperties, )
Write any GPU blocks for the primitive template to the given request object.
Trait Implementations§
source§impl From<PrimitiveKeyKind> for PrimitiveTemplateKind
impl From<PrimitiveKeyKind> for PrimitiveTemplateKind
Construct the primitive template data from a primitive key. This is invoked when a primitive key is created and the interner doesn’t currently contain a primitive with this key.
source§fn from(kind: PrimitiveKeyKind) -> Self
fn from(kind: PrimitiveKeyKind) -> Self
Converts to this type from the input type.
source§impl MallocSizeOf for PrimitiveTemplateKind
impl MallocSizeOf for PrimitiveTemplateKind
source§fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
Measure the heap usage of all descendant heap-allocated structures, but
not the space taken up by the value itself.
Auto Trait Implementations§
impl Freeze for PrimitiveTemplateKind
impl RefUnwindSafe for PrimitiveTemplateKind
impl Send for PrimitiveTemplateKind
impl Sync for PrimitiveTemplateKind
impl Unpin for PrimitiveTemplateKind
impl UnwindSafe for PrimitiveTemplateKind
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