pub enum MarkBatch {
Points {
positions: Vec<[f32; 2]>,
sizes: BatchAttr<f32>,
fills: BatchAttr<FillStyle>,
shape: MarkerShape,
strokes: BatchAttr<StrokeStyle>,
},
Rules {
segments: Vec<([f32; 2], [f32; 2])>,
stroke: StrokeStyle,
},
Rects {
rects: Vec<BoundingBox>,
fills: BatchAttr<FillStyle>,
strokes: BatchAttr<StrokeStyle>,
corner_radius: f32,
},
}Expand description
A batch of homogeneous marks for instanced rendering.
Variants§
Points
Batch of scatter points.
Fields
§
shape: MarkerShapeMarker shape (uniform for whole batch).
§
strokes: BatchAttr<StrokeStyle>Per-point stroke styles.
Rules
Batch of rule segments.
Rects
Batch of rectangles.
Implementations§
Source§impl MarkBatch
impl MarkBatch
Sourcepub fn points(
positions: Vec<[f32; 2]>,
sizes: BatchAttr<f32>,
fills: BatchAttr<FillStyle>,
shape: MarkerShape,
strokes: BatchAttr<StrokeStyle>,
) -> Result<Self, String>
pub fn points( positions: Vec<[f32; 2]>, sizes: BatchAttr<f32>, fills: BatchAttr<FillStyle>, shape: MarkerShape, strokes: BatchAttr<StrokeStyle>, ) -> Result<Self, String>
Create a validated Points batch.
Auto Trait Implementations§
impl Freeze for MarkBatch
impl RefUnwindSafe for MarkBatch
impl Send for MarkBatch
impl Sync for MarkBatch
impl Unpin for MarkBatch
impl UnsafeUnpin for MarkBatch
impl UnwindSafe for MarkBatch
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