Skip to content
pixi-silk
GitHub repository
Interface

FrameGate

import type { FrameGate } from 'pixi-silk';

What renderOnDemand returns.

Properties#

PropertyModifierTypeDescriptionDefined in
statsreadonly{ rendered: number; skipped: number; }Frames rendered and frames skipped since the gate was made.packages/pixi-silk/src/frames.ts:42
stats.renderedpublicnumber-packages/pixi-silk/src/frames.ts:42
stats.skippedpublicnumber-packages/pixi-silk/src/frames.ts:42

Methods#

destroy()#

destroy(): void;

Puts the application’s own render listener back.

Returns#

void


hold()#

hold(): () => void;

Renders every frame until the returned function is called. Hold it while something animates that the gate does not know about, such as spinning reels or a Spine animation.

Returns#

() => void


invalidate()#

invalidate(): void;

Renders the next frame. Call it after you change the scene outside a BlockSurface.

Returns#

void