Top Description Constructors Methods
org.lwjgl.opengles

public Class EXTClearTexture

extends Object
Class Inheritance
Imports
javax.annotation.*, java.nio.*, org.lwjgl.system.*

Native bindings to the EXT_clear_texture extension.

Texture objects are fundamental to the operation of OpenGL. They are used as a source for texture sampling and destination for rendering as well as being accessed in shaders for image load/store operations It is also possible to invalidate the contents of a texture. It is currently only possible to set texture image data to known values by uploading some or all of a image array from application memory or by attaching it to a framebuffer object and using the Clear or ClearBuffer commands.

Both uploading initial texture data and clearing by attaching to a framebuffer have potential disadvantages when one simply wants to initialize texture data to a known value. Uploading initial data requires the application to allocate a (potentially large) chunk of memory and transferring that to the GL. This can be a costly operation both in terms of memory bandwidth and power usage. Alternatively, attaching a texture level to a framebuffer to clear it may not be possible if the texture format isn't supported for rendering, or even if it is, attaching the image to a framebuffer object may cause the texture to be allocated in certain types of memory, which it may otherwise not need to be placed in.

This extension solves these problems by providing a mechanism whereby the contents of a texture image array can be set to known values by using the ClearTexImageEXT or ClearTexSubImageEXT commands. These commands can also be useful for initializing an image that will be used for atomic shader operations.

Requires GLES 3.1.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static void
glClearTexImageEXT(int texture, int level, int format, int type, ByteBuffer data)

public static void
glClearTexImageEXT(int texture, int level, int format, int type, ShortBuffer data)

public static void
glClearTexImageEXT(int texture, int level, int format, int type, IntBuffer data)

public static void
glClearTexImageEXT(int texture, int level, int format, int type, FloatBuffer data)

public static void
glClearTexImageEXT(int texture, int level, int format, int type, short[] data)

Array version of: ClearTexImageEXT

public static void
glClearTexImageEXT(int texture, int level, int format, int type, int[] data)

Array version of: ClearTexImageEXT

public static void
glClearTexImageEXT(int texture, int level, int format, int type, float[] data)

Array version of: ClearTexImageEXT

public static void
glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, ByteBuffer data)

public static void
glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, ShortBuffer data)

public static void
glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, IntBuffer data)

public static void
glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, FloatBuffer data)

public static void
glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, short[] data)

Array version of: ClearTexSubImageEXT

public static void
glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, int[] data)

Array version of: ClearTexSubImageEXT

public static void
glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, float[] data)

Array version of: ClearTexSubImageEXT

public static native void
nglClearTexImageEXT(int texture, int level, int format, int type, long data)

public static native void
nglClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, long data)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

EXTClearTextureback to summary
protected EXTClearTexture()

Method Detail

glClearTexImageEXTback to summary
public static void glClearTexImageEXT(int texture, int level, int format, int type, ByteBuffer data)
glClearTexImageEXTback to summary
public static void glClearTexImageEXT(int texture, int level, int format, int type, ShortBuffer data)
glClearTexImageEXTback to summary
public static void glClearTexImageEXT(int texture, int level, int format, int type, IntBuffer data)
glClearTexImageEXTback to summary
public static void glClearTexImageEXT(int texture, int level, int format, int type, FloatBuffer data)
glClearTexImageEXTback to summary
public static void glClearTexImageEXT(int texture, int level, int format, int type, short[] data)

Array version of: ClearTexImageEXT

glClearTexImageEXTback to summary
public static void glClearTexImageEXT(int texture, int level, int format, int type, int[] data)

Array version of: ClearTexImageEXT

glClearTexImageEXTback to summary
public static void glClearTexImageEXT(int texture, int level, int format, int type, float[] data)

Array version of: ClearTexImageEXT

glClearTexSubImageEXTback to summary
public static void glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, ByteBuffer data)
glClearTexSubImageEXTback to summary
public static void glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, ShortBuffer data)
glClearTexSubImageEXTback to summary
public static void glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, IntBuffer data)
glClearTexSubImageEXTback to summary
public static void glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, FloatBuffer data)
glClearTexSubImageEXTback to summary
public static void glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, short[] data)

Array version of: ClearTexSubImageEXT

glClearTexSubImageEXTback to summary
public static void glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, int[] data)

Array version of: ClearTexSubImageEXT

glClearTexSubImageEXTback to summary
public static void glClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, float[] data)

Array version of: ClearTexSubImageEXT

nglClearTexImageEXTback to summary
public static native void nglClearTexImageEXT(int texture, int level, int format, int type, long data)
nglClearTexSubImageEXTback to summary
public static native void nglClearTexSubImageEXT(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, long data)