@bloopjs/toodle / scene/QuadNode / QuadOptions
Type Alias: QuadOptions
QuadOptions =
NodeOptions&object
Defined in: scene/QuadNode.ts:292
Type declaration
assetManager?
optionalassetManager:AssetManager
atlasCoords?
optionalatlasCoords:AtlasCoords
Atlas coordinates are almost always set by toodle and the asset manager. For advanced use cases, you can set these yourself to control what uvs are sampled from the texture atlas.
atlasSize?
optionalatlasSize:Size
The size of the texture atlas in texels. This is almost always set by toodle.
color?
optionalcolor:Color
cropOffset?
optionalcropOffset:Vec2
The offset of the cropped texture from the original texture If uncropped, this will be 0,0
flipX?
optionalflipX:boolean
flipX mirrors the image horizontally (equivalent to a scale.x multiplication by -1) but allows for independent scaling
flipY?
optionalflipY:boolean
flipY mirrors the image vertically (equivalent to a scale.y multiplication by -1) but allows for independent scaling
matrixPool?
optionalmatrixPool:Pool<Mat3>
The matrix pool to use for the quad. This is used to avoid creating new matrices for each quad.
region?
optionalregion:TexelRegion
A subregion of the texture to render. This is useful for rendering a single sprite from a spritesheet for instance. It defaults to the full texture.
shader?
optionalshader:IBackendShader
textureId?
optionaltextureId:TextureId
writeInstance()?
optionalwriteInstance: (array,offset) =>void
Parameters
array
Float32Array
offset
number
Returns
void