Constructor
Name of texture
Whether texture has alpha or not.
Maximum size of the texture. Default is 4096. May actually become less than the specified value if the GPU does not support it.
Callback invoked when a pixel has changed its value.
Whether texture has alpha or not.
Name of texture
ReadonlyonSize in pixels (RGBA) of texture.
Total size in bytes of the RGBA texture
Attaches the texture to a scene and ensures it is updated before rendering frames or to a render target. A texture can only be attached to one scene.
The scene to attach the texture to.
The LazyResizableRawTexture instance.
Gets a Uint32Bits instance that can be used to manipulate the bits of the RGBA
pixel stored at the offset specified by pixelOffset
WARNING: Never ever store a reference to the Uint32Bits instance. It is reused for all pixels
in the texture. whenever bits or bytes are called again the Uint32Bits instance
will point to a new pixel. This behavior is because of performace.
Pixel offset.
Uint32Bits instance
Gets a Uint32Bytes instance that can be used to manipulate the bytes of the RGBA
pixel stored at the offset specified by pixelOffset
WARNING: Never ever store a reference to the Uint32Bytes instance. It is reused for all pixels
in the texture. whenever bits or bytes are called again the Uint32Bytes instance
will point to a new pixel. This behavior is because of performace.
Pixel offset.
Uint32Bits instance
Gets a BJS RawTexture that represents the current LazyResizableRawTexture instance.
BJS scene.
A BJS RawTexture.
Resets texture. back to 0 size.
Sets the minimum size of the texture. If the texture is already larger then size will not be changed.
Minimum size.
The actual size.
Updates the texture (uploads it to the GPU) if required. Will only be updated if there actually is changes in the texture since the last time that updateIfTextureHasChanges was called.
true if texture was updated, otherwise false.
A resizable RGBA raw texture where bits and bytes can be manipulated freely. The texture will always be square.