Classes

The following classes are available globally.

ValueAssistant protocol

  • A singleton configuration class for MotionMachine.

    See more

    Declaration

    Swift

    @MainActor
    public final class MMConfiguration
  • MotionSequence moves a collection of objects conforming to the Moveable protocol in sequential order. MotionSequence provides a powerful and easy way of chaining together individual motions to create complex animations.

    See more

    Declaration

    Swift

    @MainActor
    public class MotionSequence : Moveable, MoveableCollection, TempoDriven, MotionUpdateDelegate
  • PathMotion handles a single motion operation of a coordinate point along a CGPath. It does not directly accept PropertyData objects, but instead transforms a value between 0.0 and 1.0, representing the length of the associated path. Using this value, it updates the current point on the path.

    See more

    Declaration

    Swift

    @MainActor
    public class PathMotion : Moveable, TempoDriven, PropertyDataDelegate
  • PathPhysicsMotion handles a single motion operation of a coordinate point along a CGPath using a physics system to update the value with a decaying velocity. It does not directly accept PropertyData objects, but instead transforms a value between 0.0 and 1.0, representing the length of the associated path. Using this value, it updates the current point on the path.

    See more

    Declaration

    Swift

    @MainActor
    public class PathPhysicsMotion : Moveable, TempoDriven, PropertyDataDelegate
  • This state object is used in conjunction with PathMotion to handle the movement of a point along a path.

    See more

    Declaration

    Swift

    public final class PathState : NSObject, @unchecked Sendable
  • PhysicsMotion handles a single motion operation on one or more properties, using a physics system to update values with decaying velocity.

    See more

    Declaration

    Swift

    @MainActor
    public class PhysicsMotion : Moveable, Additive, TempoDriven, PropertyDataDelegate
  • A simple physics engine used with PhysicsMotion and PathPhysicsMotion to calculate values for motions. It primarily uses a constant velocity, plus a friction component, to update movements of values over time. As of version 2.2.0 it also supports simple collision handling between two optional fixed start and end points, and a restitution value to control the value’s elasticity when colliding.

    See more

    Declaration

    Swift

    public class PhysicsSystem : PhysicsSolving
  • CATempo uses a CADisplayLink object to send out tempo updates that are synchronized with the refresh rate of the display on iOS.

    See more

    Declaration

    Swift

    @MainActor
    public class CATempo : Tempo
  • Tempo is an abstract class that provides a basic structure for sending update beats. Moveable classes use these beats to calculate new motion interpolation values. Concrete subclasses should call tempoBeatUpdate with incremental timestamps as necessary.

    Warning

    This class should not be instantiated directly, as it provides no updates on its own.
    See more

    Declaration

    Swift

    @MainActor
    public class Tempo
  • TimerTempo uses an internal NSTimer object to send out tempo updates.

    See more

    Declaration

    Swift

    @MainActor
    public class TimerTempo : Tempo
  • CGStructAssistant provides support for several Core Graphics struct types, including CGPoint, CGSize, CGRect, CGVector, CGAffineTransform, as well as QuartzCore’s CATransform3D type. It also provides support for the NSNumber type.

    See more

    Declaration

    Swift

    @MainActor
    public final class CGStructAssistant : ValueAssistant
  • CIColorAssistant provides support for Core Image’s CIColor type.

    See more

    Declaration

    Swift

    @MainActor
    public final class CIColorAssistant : ValueAssistant
  • UIColorAssistant provides support for the UIColor type.

    See more

    Declaration

    Swift

    @MainActor
    public final class UIColorAssistant : ValueAssistant
  • UIKitStructAssistant provides support for the UIKit structs UIEdgeInsets and UIOffset.

    See more

    Declaration

    Swift

    @MainActor
    public final class UIKitStructAssistant : ValueAssistant
  • The ValueAssistantGroup class enables multiple ValueAssistant objects to be attached to a single motion class.

    See more

    Declaration

    Swift

    @MainActor
    public final class ValueAssistantGroup : ValueAssistant