pub struct ElementSpec {
pub count: u32,
pub instances: u32,
pub use_dots: bool,
pub thick: bool,
pub additive: bool,
}Expand description
The structural numbers a custom element’s geometry is sized from — the parts
of a MilkElement the draw layer needs and the VM does not.
Fields§
§count: u32Points (a wave) or sides (a shape), already clamped to the format’s own limit.
instances: u32How many copies a shape draws; 1 for a wave.
use_dots: boolPast 0.5 in the source, a wave draws dots.
thick: boolPast 0.5 in the source, the stroke is thick.
additive: boolPast 0.5 in the source, a wave adds rather than blends.
A wave’s flag is a file key (wavecode_N_bAdditive) and so is per element;
a shape’s is a register its own per-frame program may write, so that one
lives on ShapeInstance instead.
Trait Implementations§
Source§impl Clone for ElementSpec
impl Clone for ElementSpec
Source§fn clone(&self) -> ElementSpec
fn clone(&self) -> ElementSpec
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 moreSource§impl Debug for ElementSpec
impl Debug for ElementSpec
Source§impl PartialEq for ElementSpec
impl PartialEq for ElementSpec
Source§fn eq(&self, other: &ElementSpec) -> bool
fn eq(&self, other: &ElementSpec) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for ElementSpec
impl Eq for ElementSpec
impl StructuralPartialEq for ElementSpec
Auto Trait Implementations§
impl Freeze for ElementSpec
impl RefUnwindSafe for ElementSpec
impl Send for ElementSpec
impl Sync for ElementSpec
impl Unpin for ElementSpec
impl UnsafeUnpin for ElementSpec
impl UnwindSafe for ElementSpec
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.