textalive-app-api - v0.5.2
    Preparing search index...

    Interface IRenderingUnit

    描画ユニット:

    • TextAlive における画面描画処理の最小単位
    • 種類(フレーズ、単語、文字、グラフィック)を getType で取得できる
    • 前後のユニットを previousnext で取得できる
    • (存在する場合)親要素と子要素の一覧をそれぞれ parentchildren で取得できる
    • 開始時刻、終了時刻、その差分を startTime endTime および duration で取得できる

    Rendering unit:

    • The base interface for all rendering unit implementations in TextAlive
    • getType returns the implementation type (phrase, word, character, or graphic)
    • previous and next return the previous and next unit
    • parent and children return the parent unit and the list of child units (if applicable)
    • startTime and endTime return the timing information and duration returns the duration i.e. endTime - startTime
    interface IRenderingUnit {
        animate: RenderingUnitFunction;
        children: IRenderingUnit[];
        duration: number;
        endTime: number;
        next: IRenderingUnit;
        parent: IRenderingUnit;
        previous: IRenderingUnit;
        startTime: number;
        contains(time: number): boolean;
        getType(): number;
        overlaps(obj: TimedObject): boolean;
        overlaps(startTime: number, endTime: number): boolean;
        progress(time: number): number;
        toString(): string;
    }

    Hierarchy (View Summary)

    Index

    このプロパティに関数が定義されているとき、 TextAlive の通常動作(割り当て済みテンプレートの animate 関数を呼ぶ)はスキップされ、この関数が呼ばれる

    When animate function is defined, TextAlive default behavior (call animate functions of all assigned template instances) is suppressed and this function is called instead

    children: IRenderingUnit[]
    duration: number

    描画ユニットの長さ [ms] / Duration of this rendering unit [ms]

    endTime: number
    previous: IRenderingUnit
    startTime: number
    • Returns whether this time range contains the specified time (start and end inclusive).

      Parameters

      • time: number

        時刻 [ms] / Time [ms]

      Returns boolean

    • この描画ユニットの種類 / Type of this rendering unit

      Returns number

    • Returns whether the specified range overlaps with this time range (start and end inclusive).

      Parameters

      • obj: TimedObject

        時刻付きオブジェクト / Timed object

      Returns boolean

    • Returns whether the specified range overlaps with this time range (start and end inclusive).

      Parameters

      • startTime: number

        開始時刻 [ms] / Start time [ms]

      • endTime: number

        終了時刻 [ms] / End time [ms]

      Returns boolean

    • 指定された楽曲中の位置をこの描画ユニット中の位置 [0, 1] にマッピングして返す

      Returns the position in this rendering unit [0, 1]

      Parameters

      • time: number

        楽曲中の位置 / Position in a song

      Returns number

    • この描画ユニットの文字表現 / String representation of this rendering unit

      Returns string