UNPKG

modern-canvas

Version:

A JavaScript WebGL rendering engine. only the ESM.

25 lines (24 loc) 688 B
type Callback = () => void; interface QueueItem { cb: Callback; once: boolean; } interface Options { sort?: number; once?: boolean; } export declare class Ticker { protected static _queue: QueueItem[][]; protected static _currentTime: number; protected static _elapsed: number; protected static _requestId?: number; static get currentTime(): number; static get elapsed(): number; static on(cb: Callback, options?: Options): void; static off(cb: Callback, options?: Options): void; static start(): void; static stop(): void; protected static _update(time: number): void; protected static _performUpdate(): void; } export {};