API

Interface ICustomAnimationFrameRequester

Interface for any object that can request an animation frame

interface ICustomAnimationFrameRequester {
    cancelAnimationFrame?: Function;
    renderFunction?: Function;
    requestAnimationFrame: Function;
    requestID?: number;
}
Index
cancelAnimationFrame?: Function

Called to cancel the next frame request

renderFunction?: Function

This function will be called when the render loop is ready. If this is not populated, the engine's renderloop function will be called

requestAnimationFrame: Function

Called to request the next frame to render to

requestID?: number

You can pass this value to cancelAnimationFrame() to cancel the refresh callback request