pub struct CompositionAnimation { /* private fields */ }Expand description
This is the base class for ExpressionAnimation and KeyFrameAnimation.
Use the start_animation method of a composition object to start the
animation. Value parameters (as opposed to reference parameters which
are set using set_reference_parameter)
are copied and “embedded” into an expression at the time
start_animation is called. Changing the value of the variable after
start_animation is called will not affect the value of the
ExpressionAnimation. See the remarks of
ExpressionAnimation for additional
information.
A class derives from it by embedding it (base) and dereferencing to
it; the class implements ICompositionAnimation,
whose Rc<dyn ..> is the handle of an animation of any class.
Implementations§
Source§impl CompositionAnimation
impl CompositionAnimation
Sourcepub fn object(&self) -> &CompositionObject
pub fn object(&self) -> &CompositionObject
The embedded CompositionObject.
Sourcepub fn compositor(&self) -> &Rc<Compositor>
pub fn compositor(&self) -> &Rc<Compositor>
The associated compositor.
Sourcepub fn clear_all_parameters(&self)
pub fn clear_all_parameters(&self)
Clears all of the parameters of the animation.
Sourcepub fn clear_parameter(&self, key: &str)
pub fn clear_parameter(&self, key: &str)
Clears a parameter from the animation.
pub fn set_color_parameter(&self, key: &str, value: Color)
pub fn set_matrix3x2_parameter(&self, key: &str, value: Matrix3x2)
pub fn set_matrix4x4_parameter(&self, key: &str, value: Matrix4x4)
pub fn set_quaternion_parameter(&self, key: &str, value: Quaternion)
pub fn set_reference_parameter( &self, key: &str, composition_object: Rc<dyn AsCompositionObject>, )
pub fn set_scalar_parameter(&self, key: &str, value: f32)
pub fn set_vector2_parameter(&self, key: &str, value: Vector2)
pub fn set_vector3_parameter(&self, key: &str, value: Vector3)
pub fn set_vector4_parameter(&self, key: &str, value: Vector4)
pub fn set_target(&self, value: Option<String>)
Auto Trait Implementations§
impl !Freeze for CompositionAnimation
impl !RefUnwindSafe for CompositionAnimation
impl !Send for CompositionAnimation
impl !Sync for CompositionAnimation
impl !UnwindSafe for CompositionAnimation
impl Unpin for CompositionAnimation
impl UnsafeUnpin for CompositionAnimation
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
Source§impl<T> ClassDefaults for Twhere
T: ?Sized,
impl<T> ClassDefaults for Twhere
T: ?Sized,
Source§fn static_constructor()
fn static_constructor()
affects_render, metadata
overrides). Read more