#[repr(C)]pub struct LineInstance {
pub p0: [f32; 2],
pub p1: [f32; 2],
pub color: u32,
pub width: f32,
pub dist0: f32,
pub dash: [f32; 4],
}Expand description
Screen-constant line segment (instanced; expanded in the vertex shader).
Fields§
§p0: [f32; 2]Start (local units).
p1: [f32; 2]End (local units).
color: u32Premultiplied RGBA8.
width: f32Width in CSS pixels.
dist0: f32Distance along the path at p0 (local units), for dash phase.
dash: [f32; 4]Dash pattern in CSS pixels ([on, off, on, off]; x <= 0 = solid).
Trait Implementations§
Source§impl Clone for LineInstance
impl Clone for LineInstance
Source§fn clone(&self) -> LineInstance
fn clone(&self) -> LineInstance
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for LineInstance
Source§impl Debug for LineInstance
impl Debug for LineInstance
Source§impl PartialEq for LineInstance
impl PartialEq for LineInstance
Source§fn eq(&self, other: &LineInstance) -> bool
fn eq(&self, other: &LineInstance) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Pod for LineInstance
impl StructuralPartialEq for LineInstance
Auto Trait Implementations§
impl Freeze for LineInstance
impl RefUnwindSafe for LineInstance
impl Send for LineInstance
impl Sync for LineInstance
impl Unpin for LineInstance
impl UnsafeUnpin for LineInstance
impl UnwindSafe for LineInstance
Blanket Implementations§
impl<T> AnyBitPattern for Twhere
T: Pod,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self.