UNPKG

@spearwolf/twopoint5d

Version:

a library to create 2.5d realtime graphics and pixelart with three.js

26 lines 1.17 kB
import { TextureCoords } from './TextureCoords.js'; export type TextureAtlasFrameData = Record<string, any>; export interface TextureAtlasFrame { coords: TextureCoords; data?: TextureAtlasFrameData; } type TextureAtlasArgs = [coords: TextureCoords, data?: TextureAtlasFrameData]; type TextureAtlasFrameName = string | symbol; type NamedTextureAtlasArgs = [name: TextureAtlasFrameName, coords: TextureCoords, data?: TextureAtlasFrameData]; export declare class TextureAtlas { #private; add(...args: TextureAtlasArgs | NamedTextureAtlasArgs): number; get size(): number; get(id: number): TextureAtlasFrame | undefined; frameId(name: TextureAtlasFrameName): number | undefined; frame(name: TextureAtlasFrameName): TextureAtlasFrame | undefined; frameNames(match?: string | RegExp): TextureAtlasFrameName[]; randomFrameId(): number; randomFrame(): TextureAtlasFrame; randomFrameName(): TextureAtlasFrameName; randomFrameIds(count: number): number[]; randomFrames(count: number): TextureAtlasFrame[]; randomFrameNames(count: number): TextureAtlasFrameName[]; } export {}; //# sourceMappingURL=TextureAtlas.d.ts.map