definePixelTexture
Call Signature
Section titled “Call Signature”definePixelTexture(
options):PixelTexture
Declares a texture at module scope: painted on the CPU from a painter and its size, or drawn from image files. A painted texture’s normal map comes from its painter’s height. Nothing paints or loads until a view first uses it, so a room paints nothing. Checks its values here, throwing with its name.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
PixelImageTextureOptions |
Returns
Section titled “Returns”Call Signature
Section titled “Call Signature”definePixelTexture<
Paint>(options):PixelTexture
Declares a texture at module scope: painted on the CPU from a painter and its size, or drawn from image files. A painted texture’s normal map comes from its painter’s height. Nothing paints or loads until a view first uses it, so a room paints nothing. Checks its values here, throwing with its name.
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
Paint extends (context) => unknown |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
Omit<PaintedPixelTextureOptions, "paint"> & object |