@woosh/meep-engine
Version:
Pure JavaScript game engine. Fully featured and production ready.
88 lines (76 loc) • 2.04 kB
JavaScript
import { ImpostorCaptureType } from "./ImpostorCaptureType.js";
export class ImpostorDescription {
/**
* How many XY frames should be captured
* More frames will result in less distortion, but lower texel density (lower resolution for each individual frame)
* @type {number}
*/
frame_count = 16;
/**
* How the impostor is being captured
* @type {number}
*/
capture_type = ImpostorCaptureType.FullSphere;
/**
* Resolution of the texture atlas used for baking. All "frames" will be packed here
* Must be power of two
* @type {number}
*/
resolution = 1024;
/**
* Radius of baking sphere, this is centered on origin
* @type {number}
*/
sphere_radius = 0;
/**
* How much space to leave between frames to ensure that there is no bleeding across frames
* @type {number}
*/
padding = 0;
/**
* Baking offset
* @type {number[]}
*/
offset = [0, 0, 0];
/**
* Actual baked data
* @type {Sampler2D|null}
*/
atlas = null;
/**
* Source scene from which impostor was baked
* @type {number}
*/
source_geometry_polygon_count = 0;
/**
* @type {number}
*/
source_geometry_vertex_count = 0;
/**
*
* @type {number}
*/
source_material_count = 0;
/**
*
* @type {number}
*/
source_instance_count = 0;
/**
* Frame-relative sequence of points defining a hole-free shape
* Normalized between 0,0 and 1,1; Might extend further in some cases, should be clipped in shader in those cases
* @type {number[]}
*/
cutout = [
0, 0,
1, 0,
1, 1,
0, 1
];
/**
* TODO: replace with something non-three.js specific
* @deprecated use non-three.js specific accessors instead
* @type {THREE.WebGLMultipleRenderTargets}
*/
rt = null;
}