createTexture

fun createTexture(engine: Engine, internalFormat: Texture.InternalFormat): Texture?

Uploads the image into a mipmapped 2D texture and frees it, on the engine's thread; null if that fails or it's gone.