AutoMovie API
    Preparing search index...

    Interface IAutoMovieMotionClock

    An action clock resolving named instants and progress in seconds since that action starts. AutoMovieMotionClock constructs and admits the clock; action primitives share this capability.

    interface IAutoMovieMotionClock {
        duration: number;
        instants: readonly IAutoMovieMotionClockInstant[];
        at(name: string): number;
        envelope(
            rise: readonly [string, string],
            fall: readonly [string, string],
            seconds: number,
        ): number;
        events(): IAutoMovieMotionEvent[];
        linear(from: string, to: string, seconds: number): number;
        progress(from: string, to: string, seconds: number): number;
    }
    Index
    duration: number

    Duration, seconds; positive.

    instants: readonly IAutoMovieMotionClockInstant[]

    The named instants in time order, without start and end.

    • How present something is that rises over one window and falls over a later one: the rise's progress less the fall's.

      Parameters

      • rise: readonly [string, string]

        The window it rises over.

      • fall: readonly [string, string]

        The window it falls over.

      • seconds: number

        Seconds since the action's start.

      Returns number

      A value in [0, 1].

    • Uniform progress between two instants.

      Parameters

      • from: string

        The opening instant.

      • to: string

        The closing instant.

      • seconds: number

        Seconds since the action's start.

      Returns number

      0 until from, 1 from to, linear between; a window of no length steps at to.

    • Minimum-jerk progress between two instants (Flash and Hogan 1985): the bell-shaped speed of a point-to-point movement, at rest at both ends.

      Parameters

      • from: string

        The opening instant.

      • to: string

        The closing instant.

      • seconds: number

        Seconds since the action's start.

      Returns number

      0 until from, 1 from to.