Top Description Fields Constructors Methods
org.lwjgl.opengl

public Class ARBTextureStorage

extends Object
Class Inheritance
Imports
org.lwjgl.system.*

Native bindings to the ARB_texture_storage extension.

The texture image specification commands in OpenGL allow each level to be separately specified with different sizes, formats, types and so on, and only imposes consistency checks at draw time. This adds overhead for implementations.

This extension provides a mechanism for specifying the entire structure of a texture in a single call, allowing certain consistency checks and memory allocations to be done up front. Once specified, the format and dimensions of the image array become immutable, to simplify completeness checks in the implementation.

When using this extension, it is no longer possible to supply texture data using TexImage*. Instead, data can be uploaded using TexSubImage*, or produced by other means (such as render-to-texture, mipmap generation, or rendering to a sibling EGLImage).

This extension has complicated interactions with other extensions. The goal of most of these interactions is to ensure that a texture is always mipmap complete (and cube complete for cubemap textures).

Requires OpenGL 1.2. Promoted to core in OpenGL 4.2.

Field Summary

Modifier and TypeField and Description
public static final int
GL_TEXTURE_IMMUTABLE_FORMAT

Accepted by the value parameter of GetTexParameter{if}v.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static void
glTexStorage1D(int
the target of the operation. One of:
TEXTURE_1DPROXY_TEXTURE_1D
target
,
int
the number of texture levels
levels
,
int
the sized internal format to be used to store texture image data
internalformat
,
int
the width of the texture, in texels
width
)

Simultaneously specifies storage for all levels of a one-dimensional texture.

public static void
glTexStorage2D(int target, int
the number of texture levels
levels
,
int
the sized internal format to be used to store texture image data
internalformat
,
int
the width of the texture, in texels
width
,
int
the height of the texture, in texels
height
)

Simultaneously specifies storage for all levels of a two-dimensional or one-dimensional array texture.

public static void
glTexStorage3D(int target, int
the number of texture levels
levels
,
int
the sized internal format to be used to store texture image data
internalformat
,
int
the width of the texture, in texels
width
,
int
the height of the texture, in texels
height
,
int
the depth of the texture, in texels
depth
)

Simultaneously specifies storage for all levels of a three-dimensional, two-dimensional array or cube-map array texture.

public static native void
glTextureStorage1DEXT(int
the texture object to update
texture
,
int
the target of the operation. One of:
TEXTURE_1DPROXY_TEXTURE_1D
target
,
int
the number of texture levels
levels
,
int
the sized internal format to be used to store texture image data
internalformat
,
int
the width of the texture, in texels
width
)

DSA version of TexStorage1D.

public static native void
glTextureStorage2DEXT(int
the texture object to update
texture
,
int target, int
the number of texture levels
levels
,
int
the sized internal format to be used to store texture image data
internalformat
,
int
the width of the texture, in texels
width
,
int
the height of the texture, in texels
height
)

DSA version of TexStorage2D.

public static native void
glTextureStorage3DEXT(int
the texture object to update
texture
,
int target, int
the number of texture levels
levels
,
int
the sized internal format to be used to store texture image data
internalformat
,
int
the width of the texture, in texels
width
,
int
the height of the texture, in texels
height
,
int
the depth of the texture, in texels
depth
)

DSA version of TexStorage3D.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

GL_TEXTURE_IMMUTABLE_FORMATback to summary
public static final int GL_TEXTURE_IMMUTABLE_FORMAT

Accepted by the value parameter of GetTexParameter{if}v.

Constructor Detail

ARBTextureStorageback to summary
protected ARBTextureStorage()

Method Detail

glTexStorage1Dback to summary
public static void glTexStorage1D(int target, int levels, int internalformat, int width)

Simultaneously specifies storage for all levels of a one-dimensional texture.

Parameters
target:int

the target of the operation. One of:

TEXTURE_1DPROXY_TEXTURE_1D
levels:int

the number of texture levels

internalformat:int

the sized internal format to be used to store texture image data

width:int

the width of the texture, in texels

glTexStorage2Dback to summary
public static void glTexStorage2D(int target, int levels, int internalformat, int width, int height)

Simultaneously specifies storage for all levels of a two-dimensional or one-dimensional array texture.

Parameters
target:int

the target of the operation. One of:

TEXTURE_2DTEXTURE_1D_ARRAYTEXTURE_RECTANGLETEXTURE_CUBE_MAP
PROXY_TEXTURE_2DPROXY_TEXTURE_1D_ARRAYPROXY_TEXTURE_RECTANGLEPROXY_TEXTURE_CUBE_MAP
levels:int

the number of texture levels

internalformat:int

the sized internal format to be used to store texture image data

width:int

the width of the texture, in texels

height:int

the height of the texture, in texels

glTexStorage3Dback to summary
public static void glTexStorage3D(int target, int levels, int internalformat, int width, int height, int depth)

Simultaneously specifies storage for all levels of a three-dimensional, two-dimensional array or cube-map array texture.

Parameters
target:int

the target of the operation. One of:

TEXTURE_3DTEXTURE_2D_ARRAYTEXTURE_CUBE_MAP_ARRAYPROXY_TEXTURE_3D
PROXY_TEXTURE_2D_ARRAYPROXY_TEXTURE_CUBE_MAP_ARRAY
levels:int

the number of texture levels

internalformat:int

the sized internal format to be used to store texture image data

width:int

the width of the texture, in texels

height:int

the height of the texture, in texels

depth:int

the depth of the texture, in texels

glTextureStorage1DEXTback to summary
public static native void glTextureStorage1DEXT(int texture, int target, int levels, int internalformat, int width)

DSA version of TexStorage1D.

Parameters
texture:int

the texture object to update

target:int

the target of the operation. One of:

TEXTURE_1DPROXY_TEXTURE_1D
levels:int

the number of texture levels

internalformat:int

the sized internal format to be used to store texture image data

width:int

the width of the texture, in texels

glTextureStorage2DEXTback to summary
public static native void glTextureStorage2DEXT(int texture, int target, int levels, int internalformat, int width, int height)

DSA version of TexStorage2D.

Parameters
texture:int

the texture object to update

target:int

the target of the operation. One of:

TEXTURE_2DTEXTURE_1D_ARRAYTEXTURE_RECTANGLETEXTURE_CUBE_MAP
PROXY_TEXTURE_2DPROXY_TEXTURE_1D_ARRAYPROXY_TEXTURE_RECTANGLEPROXY_TEXTURE_CUBE_MAP
levels:int

the number of texture levels

internalformat:int

the sized internal format to be used to store texture image data

width:int

the width of the texture, in texels

height:int

the height of the texture, in texels

glTextureStorage3DEXTback to summary
public static native void glTextureStorage3DEXT(int texture, int target, int levels, int internalformat, int width, int height, int depth)

DSA version of TexStorage3D.

Parameters
texture:int

the texture object to update

target:int

the target of the operation. One of:

TEXTURE_3DTEXTURE_2D_ARRAYTEXTURE_CUBE_MAP_ARRAYPROXY_TEXTURE_3D
PROXY_TEXTURE_2D_ARRAYPROXY_TEXTURE_CUBE_MAP_ARRAY
levels:int

the number of texture levels

internalformat:int

the sized internal format to be used to store texture image data

width:int

the width of the texture, in texels

height:int

the height of the texture, in texels

depth:int

the depth of the texture, in texels