Stores a single keyframe of an LED animation. The keyframe is made of a time and a color index.

Constructors

Properties

timeAndColor: number

Accessors

  • get colorIndex(): number
  • Gets the color index, from to 0 to 128 excluded.

    Returns number

  • get time(): number
  • Gets the color index, from to 0 to 128 excluded.

    Returns number

Methods

  • Compares two RgbKeyframe instances.

    Parameters

    • other: RgbKeyframe

      The RgbKeyframe instance to compare with.

    Returns boolean

    Whether the two RgbKeyframe instances have the same data.

  • Gets the 32 bits color for the color index of this instance.

    Parameters

    Returns number

    The 32 bits color for the instance color index.

  • Updates the instance timeAndColor member with the given time and color index.

    Parameters

    • time: number

      The time in milliseconds, from to 0 to 1024 excluded.

    • colorIndex: number

      The color index, from to 0 to 128 excluded.

    Returns void