pub struct MorphLayerStack { /* private fields */ }Expand description
Ordered stack of morph layers
Implementations§
Source§impl MorphLayerStack
impl MorphLayerStack
pub fn new() -> Self
pub fn push(&mut self, layer: MorphLayer)
pub fn pop(&mut self) -> Option<MorphLayer>
pub fn insert(&mut self, index: usize, layer: MorphLayer)
pub fn remove(&mut self, index: usize) -> MorphLayer
pub fn move_up(&mut self, index: usize)
pub fn move_down(&mut self, index: usize)
pub fn layer_count(&self) -> usize
pub fn get(&self, index: usize) -> Option<&MorphLayer>
pub fn get_mut(&mut self, index: usize) -> Option<&mut MorphLayer>
pub fn get_by_name(&self, name: &str) -> Option<&MorphLayer>
pub fn get_by_name_mut(&mut self, name: &str) -> Option<&mut MorphLayer>
Sourcepub fn evaluate(&self) -> HashMap<String, f32>
pub fn evaluate(&self) -> HashMap<String, f32>
Evaluate all layers bottom-to-top, return composite morph weights
Sourcepub fn all_morphs(&self) -> Vec<String>
pub fn all_morphs(&self) -> Vec<String>
All unique morph names across all layers
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MorphLayerStack
impl RefUnwindSafe for MorphLayerStack
impl Send for MorphLayerStack
impl Sync for MorphLayerStack
impl Unpin for MorphLayerStack
impl UnsafeUnpin for MorphLayerStack
impl UnwindSafe for MorphLayerStack
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