installBitmapFont
installBitmapFont(
source,opts):Promise<string>
Defined in: renderer/src/assets.ts:91
Load a .ttf/.woff and bake a bitmap glyph atlas from it via Pixi v8’s
BitmapFont.install. Returns the registered font name, ready to hand to
the bitmap: { font } option on UIText / TextComponent.
const font = await installBitmapFont("fonts/PressStart2P.ttf", { name: "PressStart", size: 16,});entity.add(new TextComponent({ text: "READY", bitmap: { font } }));Parameters
Section titled “Parameters”source
Section titled “source”string | AssetHandle<unknown>
Returns
Section titled “Returns”Promise<string>