RgbaTexture

open class RgbaTexture(rgba: ByteArray, width: Int, height: Int) : Texture

Texture backed by a tightly-packed, top-row-first RGBA8 byte array — the output of the KTX2 / Basis-Universal transcoder (KHR_texture_basisu), which has no platform image object to wrap. Mirrors ImageTexture's vertical flip and mipmap policy so basisu textures line up with glTF UVs exactly like the JPEG/PNG path, and premultiplies alpha to match the engine's premultiplied blend (GL_ONE, GL_ONE_MINUS_SRC_ALPHA).

Unsized GL_RGBA internal format keeps it valid on WebGL1 / GLES2.

Constructors

Link copied to clipboard
constructor(rgba: ByteArray, width: Int, height: Int)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Caller opt-out for mipmap generation.

Link copied to clipboard
val height: Int
Link copied to clipboard
val target: Int
Link copied to clipboard
val width: Int

Functions

Link copied to clipboard
Link copied to clipboard
fun getTexParameter(name: Int): Int
Link copied to clipboard
Link copied to clipboard
open override fun release(dc: DrawContext)

Frees any resources associated with this instance. After this method returns the rendering resource is invalid, and any associated GL object is deleted.

Link copied to clipboard
fun setTexParameter(name: Int, param: Int)