public class ARBVertexBufferObject
extends java.lang.Object
This extension defines an interface that allows various types of data (especially vertex array data) to be cached in high-performance graphics memory on the server, thereby increasing the rate of data transfers.
Chunks of data are encapsulated within "buffer objects", which conceptually are nothing more than arrays of bytes, just like any chunk of memory. An API
is provided whereby applications can read from or write to buffers, either via the GL itself (BufferDataARB, BufferSubDataARB,
GetBufferSubDataARB) or via a pointer to the memory.
The latter technique is known as "mapping" a buffer. When an application maps a buffer, it is given a pointer to the memory. When the application finishes reading from or writing to the memory, it is required to "unmap" the buffer before it is once again permitted to use that buffer as a GL data source or sink. Mapping often allows applications to eliminate an extra data copy otherwise required to access the buffer, thereby enhancing performance. In addition, requiring that applications unmap the buffer to use it as a data source or sink ensures that certain classes of latent synchronization bugs cannot occur.
Although this extension only defines hooks for buffer objects to be used with OpenGL's vertex array APIs, the API defined in this extension permits buffer objects to be used as either data sources or sinks for any GL command that takes a pointer as an argument. Normally, in the absence of this extension, a pointer passed into the GL is simply a pointer to the user's data. This extension defines a mechanism whereby this pointer is used not as a pointer to the data itself, but as an offset into a currently bound buffer object. The buffer object ID zero is reserved, and when buffer object zero is bound to a given target, the commands affected by that buffer binding behave normally. When a nonzero buffer ID is bound, then the pointer represents an offset.
In the case of vertex arrays, this extension defines not merely one binding for all attributes, but a separate binding for each individual attribute. As a result, applications can source their attributes from multiple buffers. An application might, for example, have a model with constant texture coordinates and variable geometry. The texture coordinates might be retrieved from a buffer object with the usage mode "STATIC_DRAW", indicating to the GL that the application does not expect to update the contents of the buffer frequently or even at all, while the vertices might be retrieved from a buffer object with the usage mode "STREAM_DRAW", indicating that the vertices will be updated on a regular basis.
In addition, a binding is defined by which applications can source index data (as used by DrawElements, DrawRangeElements, and
MultiDrawElements) from a buffer object. On some platforms, this enables very large models to be rendered with no more than a few small commands
to the graphics device.
It is expected that a future extension will allow sourcing pixel data from and writing pixel data to a buffer object.
Promoted to core in OpenGL 1.5.
| Modifier and Type | Field and Description |
|---|---|
static int |
GL_ARRAY_BUFFER_ARB
Accepted by the
target parameters of BindBufferARB, BufferDataARB, BufferSubDataARB, MapBufferARB, UnmapBufferARB, GetBufferSubDataARB,
GetBufferParameterivARB, and GetBufferPointervARB. |
static int |
GL_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_BUFFER_ACCESS_ARB
Accepted by the
pname parameter of GetBufferParameterivARB. |
static int |
GL_BUFFER_MAP_POINTER_ARB
Accepted by the
pname parameter of GetBufferPointervARB. |
static int |
GL_BUFFER_MAPPED_ARB
Accepted by the
pname parameter of GetBufferParameterivARB. |
static int |
GL_BUFFER_SIZE_ARB
Accepted by the
pname parameter of GetBufferParameterivARB. |
static int |
GL_BUFFER_USAGE_ARB
Accepted by the
pname parameter of GetBufferParameterivARB. |
static int |
GL_COLOR_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_DYNAMIC_COPY_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_DYNAMIC_DRAW_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_DYNAMIC_READ_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_ELEMENT_ARRAY_BUFFER_ARB
Accepted by the
target parameters of BindBufferARB, BufferDataARB, BufferSubDataARB, MapBufferARB, UnmapBufferARB, GetBufferSubDataARB,
GetBufferParameterivARB, and GetBufferPointervARB. |
static int |
GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_INDEX_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_NORMAL_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_READ_ONLY_ARB
Accepted by the
access parameter of MapBufferARB. |
static int |
GL_READ_WRITE_ARB
Accepted by the
access parameter of MapBufferARB. |
static int |
GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_STATIC_COPY_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_STATIC_DRAW_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_STATIC_READ_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_STREAM_COPY_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_STREAM_DRAW_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_STREAM_READ_ARB
Accepted by the
usage parameter of BufferDataARB. |
static int |
GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_VERTEX_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetVertexAttribivARB. |
static int |
GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB
Accepted by the
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev. |
static int |
GL_WRITE_ONLY_ARB
Accepted by the
access parameter of MapBufferARB. |
| Modifier and Type | Method and Description |
|---|---|
static void |
glBindBufferARB(int target,
int buffer)
Binds a named buffer object.
|
static void |
glBufferDataARB(int target,
java.nio.ByteBuffer data,
int usage)
Creates and initializes a buffer object's data store.
|
static void |
glBufferDataARB(int target,
double[] data,
int usage)
Array version of:
BufferDataARB |
static void |
glBufferDataARB(int target,
java.nio.DoubleBuffer data,
int usage)
Creates and initializes a buffer object's data store.
|
static void |
glBufferDataARB(int target,
float[] data,
int usage)
Array version of:
BufferDataARB |
static void |
glBufferDataARB(int target,
java.nio.FloatBuffer data,
int usage)
Creates and initializes a buffer object's data store.
|
static void |
glBufferDataARB(int target,
int[] data,
int usage)
Array version of:
BufferDataARB |
static void |
glBufferDataARB(int target,
java.nio.IntBuffer data,
int usage)
Creates and initializes a buffer object's data store.
|
static void |
glBufferDataARB(int target,
long size,
int usage)
Creates and initializes a buffer object's data store.
|
static void |
glBufferDataARB(int target,
short[] data,
int usage)
Array version of:
BufferDataARB |
static void |
glBufferDataARB(int target,
java.nio.ShortBuffer data,
int usage)
Creates and initializes a buffer object's data store.
|
static void |
glBufferSubDataARB(int target,
long offset,
java.nio.ByteBuffer data)
Updates a subset of a buffer object's data store.
|
static void |
glBufferSubDataARB(int target,
long offset,
double[] data)
Array version of:
BufferSubDataARB |
static void |
glBufferSubDataARB(int target,
long offset,
java.nio.DoubleBuffer data)
Updates a subset of a buffer object's data store.
|
static void |
glBufferSubDataARB(int target,
long offset,
float[] data)
Array version of:
BufferSubDataARB |
static void |
glBufferSubDataARB(int target,
long offset,
java.nio.FloatBuffer data)
Updates a subset of a buffer object's data store.
|
static void |
glBufferSubDataARB(int target,
long offset,
int[] data)
Array version of:
BufferSubDataARB |
static void |
glBufferSubDataARB(int target,
long offset,
java.nio.IntBuffer data)
Updates a subset of a buffer object's data store.
|
static void |
glBufferSubDataARB(int target,
long offset,
short[] data)
Array version of:
BufferSubDataARB |
static void |
glBufferSubDataARB(int target,
long offset,
java.nio.ShortBuffer data)
Updates a subset of a buffer object's data store.
|
static void |
glDeleteBuffersARB(int buffer)
Deletes named buffer objects.
|
static void |
glDeleteBuffersARB(int[] buffers)
Array version of:
DeleteBuffersARB |
static void |
glDeleteBuffersARB(java.nio.IntBuffer buffers)
Deletes named buffer objects.
|
static int |
glGenBuffersARB()
Generates buffer object names.
|
static void |
glGenBuffersARB(int[] buffers)
Array version of:
GenBuffersARB |
static void |
glGenBuffersARB(java.nio.IntBuffer buffers)
Generates buffer object names.
|
static int |
glGetBufferParameteriARB(int target,
int pname)
Returns the value of a buffer object parameter.
|
static void |
glGetBufferParameterivARB(int target,
int pname,
int[] params)
Array version of:
GetBufferParameterivARB |
static void |
glGetBufferParameterivARB(int target,
int pname,
java.nio.IntBuffer params)
Returns the value of a buffer object parameter.
|
static long |
glGetBufferPointerARB(int target,
int pname)
Returns the pointer to a mapped buffer object's data store.
|
static void |
glGetBufferPointervARB(int target,
int pname,
org.lwjgl.PointerBuffer params)
Returns the pointer to a mapped buffer object's data store.
|
static void |
glGetBufferSubDataARB(int target,
long offset,
java.nio.ByteBuffer data)
Returns a subset of a buffer object's data store.
|
static void |
glGetBufferSubDataARB(int target,
long offset,
double[] data)
Array version of:
GetBufferSubDataARB |
static void |
glGetBufferSubDataARB(int target,
long offset,
java.nio.DoubleBuffer data)
Returns a subset of a buffer object's data store.
|
static void |
glGetBufferSubDataARB(int target,
long offset,
float[] data)
Array version of:
GetBufferSubDataARB |
static void |
glGetBufferSubDataARB(int target,
long offset,
java.nio.FloatBuffer data)
Returns a subset of a buffer object's data store.
|
static void |
glGetBufferSubDataARB(int target,
long offset,
int[] data)
Array version of:
GetBufferSubDataARB |
static void |
glGetBufferSubDataARB(int target,
long offset,
java.nio.IntBuffer data)
Returns a subset of a buffer object's data store.
|
static void |
glGetBufferSubDataARB(int target,
long offset,
short[] data)
Array version of:
GetBufferSubDataARB |
static void |
glGetBufferSubDataARB(int target,
long offset,
java.nio.ShortBuffer data)
Returns a subset of a buffer object's data store.
|
static boolean |
glIsBufferARB(int buffer)
Determines if a name corresponds to a buffer object.
|
static java.nio.ByteBuffer |
glMapBufferARB(int target,
int access)
Maps a buffer object's data store.
|
static java.nio.ByteBuffer |
glMapBufferARB(int target,
int access,
java.nio.ByteBuffer old_buffer)
Maps a buffer object's data store.
|
static java.nio.ByteBuffer |
glMapBufferARB(int target,
int access,
long length,
java.nio.ByteBuffer old_buffer)
Maps a buffer object's data store.
|
static boolean |
glUnmapBufferARB(int target)
Relinquishes the mapping of a buffer object and invalidates the pointer to its data store.
|
static void |
nglBufferDataARB(int target,
long size,
long data,
int usage)
Unsafe version of:
BufferDataARB |
static void |
nglBufferSubDataARB(int target,
long offset,
long size,
long data)
Unsafe version of:
BufferSubDataARB |
static void |
nglDeleteBuffersARB(int n,
long buffers)
Unsafe version of:
DeleteBuffersARB |
static void |
nglGenBuffersARB(int n,
long buffers)
Unsafe version of:
GenBuffersARB |
static void |
nglGetBufferParameterivARB(int target,
int pname,
long params)
Unsafe version of:
GetBufferParameterivARB |
static void |
nglGetBufferPointervARB(int target,
int pname,
long params)
Unsafe version of:
GetBufferPointervARB |
static void |
nglGetBufferSubDataARB(int target,
long offset,
long size,
long data)
Unsafe version of:
GetBufferSubDataARB |
static long |
nglMapBufferARB(int target,
int access)
Unsafe version of:
MapBufferARB |
public static final int GL_ARRAY_BUFFER_ARB
target parameters of BindBufferARB, BufferDataARB, BufferSubDataARB, MapBufferARB, UnmapBufferARB, GetBufferSubDataARB,
GetBufferParameterivARB, and GetBufferPointervARB.public static final int GL_ELEMENT_ARRAY_BUFFER_ARB
target parameters of BindBufferARB, BufferDataARB, BufferSubDataARB, MapBufferARB, UnmapBufferARB, GetBufferSubDataARB,
GetBufferParameterivARB, and GetBufferPointervARB.public static final int GL_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_VERTEX_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_NORMAL_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_COLOR_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_INDEX_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.public static final int GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB
pname parameter of GetVertexAttribivARB.public static final int GL_STREAM_DRAW_ARB
usage parameter of BufferDataARB.public static final int GL_STREAM_READ_ARB
usage parameter of BufferDataARB.public static final int GL_STREAM_COPY_ARB
usage parameter of BufferDataARB.public static final int GL_STATIC_DRAW_ARB
usage parameter of BufferDataARB.public static final int GL_STATIC_READ_ARB
usage parameter of BufferDataARB.public static final int GL_STATIC_COPY_ARB
usage parameter of BufferDataARB.public static final int GL_DYNAMIC_DRAW_ARB
usage parameter of BufferDataARB.public static final int GL_DYNAMIC_READ_ARB
usage parameter of BufferDataARB.public static final int GL_DYNAMIC_COPY_ARB
usage parameter of BufferDataARB.public static final int GL_READ_ONLY_ARB
access parameter of MapBufferARB.public static final int GL_WRITE_ONLY_ARB
access parameter of MapBufferARB.public static final int GL_READ_WRITE_ARB
access parameter of MapBufferARB.public static final int GL_BUFFER_SIZE_ARB
pname parameter of GetBufferParameterivARB.public static final int GL_BUFFER_USAGE_ARB
pname parameter of GetBufferParameterivARB.public static final int GL_BUFFER_ACCESS_ARB
pname parameter of GetBufferParameterivARB.public static final int GL_BUFFER_MAPPED_ARB
pname parameter of GetBufferParameterivARB.public static final int GL_BUFFER_MAP_POINTER_ARB
pname parameter of GetBufferPointervARB.public static void glBindBufferARB(int target,
int buffer)
target - the target to which the buffer object is bound. One of:buffer - the name of a buffer objectpublic static void nglDeleteBuffersARB(int n,
long buffers)
DeleteBuffersARBn - the number of buffer objects to be deletedpublic static void glDeleteBuffersARB(java.nio.IntBuffer buffers)
buffers - an array of buffer objects to be deletedpublic static void glDeleteBuffersARB(int buffer)
public static void nglGenBuffersARB(int n,
long buffers)
GenBuffersARBn - the number of buffer object names to be generatedpublic static void glGenBuffersARB(java.nio.IntBuffer buffers)
buffers - a buffer in which the generated buffer object names are storedpublic static int glGenBuffersARB()
public static boolean glIsBufferARB(int buffer)
buffer - a value that may be the name of a buffer objectpublic static void nglBufferDataARB(int target,
long size,
long data,
int usage)
BufferDataARBsize - the size in bytes of the buffer object's new data storepublic static void glBufferDataARB(int target,
long size,
int usage)
usage is a hint to the GL implementation as to how a buffer object's data store will be accessed. This enables the GL implementation to make
more intelligent decisions that may significantly impact buffer object performance. It does not, however, constrain the actual usage of the data store.
usage can be broken down into two parts: first, the frequency of access (modification and usage), and second, the nature of that access. The
frequency of access may be one of these:
The nature of access may be one of these:
target - the target buffer object. One of:size - the size in bytes of the buffer object's new data storeusage - the expected usage pattern of the data store. One of:STREAM_DRAW_ARB | STREAM_READ_ARB | STREAM_COPY_ARB | STATIC_DRAW_ARB | STATIC_READ_ARB |
STATIC_COPY_ARB | DYNAMIC_DRAW_ARB | DYNAMIC_READ_ARB | DYNAMIC_COPY_ARB |
public static void glBufferDataARB(int target,
java.nio.ByteBuffer data,
int usage)
usage is a hint to the GL implementation as to how a buffer object's data store will be accessed. This enables the GL implementation to make
more intelligent decisions that may significantly impact buffer object performance. It does not, however, constrain the actual usage of the data store.
usage can be broken down into two parts: first, the frequency of access (modification and usage), and second, the nature of that access. The
frequency of access may be one of these:
The nature of access may be one of these:
target - the target buffer object. One of:data - a pointer to data that will be copied into the data store for initialization, or NULL if no data is to be copiedusage - the expected usage pattern of the data store. One of:STREAM_DRAW_ARB | STREAM_READ_ARB | STREAM_COPY_ARB | STATIC_DRAW_ARB | STATIC_READ_ARB |
STATIC_COPY_ARB | DYNAMIC_DRAW_ARB | DYNAMIC_READ_ARB | DYNAMIC_COPY_ARB |
public static void glBufferDataARB(int target,
java.nio.ShortBuffer data,
int usage)
usage is a hint to the GL implementation as to how a buffer object's data store will be accessed. This enables the GL implementation to make
more intelligent decisions that may significantly impact buffer object performance. It does not, however, constrain the actual usage of the data store.
usage can be broken down into two parts: first, the frequency of access (modification and usage), and second, the nature of that access. The
frequency of access may be one of these:
The nature of access may be one of these:
target - the target buffer object. One of:data - a pointer to data that will be copied into the data store for initialization, or NULL if no data is to be copiedusage - the expected usage pattern of the data store. One of:STREAM_DRAW_ARB | STREAM_READ_ARB | STREAM_COPY_ARB | STATIC_DRAW_ARB | STATIC_READ_ARB |
STATIC_COPY_ARB | DYNAMIC_DRAW_ARB | DYNAMIC_READ_ARB | DYNAMIC_COPY_ARB |
public static void glBufferDataARB(int target,
java.nio.IntBuffer data,
int usage)
usage is a hint to the GL implementation as to how a buffer object's data store will be accessed. This enables the GL implementation to make
more intelligent decisions that may significantly impact buffer object performance. It does not, however, constrain the actual usage of the data store.
usage can be broken down into two parts: first, the frequency of access (modification and usage), and second, the nature of that access. The
frequency of access may be one of these:
The nature of access may be one of these:
target - the target buffer object. One of:data - a pointer to data that will be copied into the data store for initialization, or NULL if no data is to be copiedusage - the expected usage pattern of the data store. One of:STREAM_DRAW_ARB | STREAM_READ_ARB | STREAM_COPY_ARB | STATIC_DRAW_ARB | STATIC_READ_ARB |
STATIC_COPY_ARB | DYNAMIC_DRAW_ARB | DYNAMIC_READ_ARB | DYNAMIC_COPY_ARB |
public static void glBufferDataARB(int target,
java.nio.FloatBuffer data,
int usage)
usage is a hint to the GL implementation as to how a buffer object's data store will be accessed. This enables the GL implementation to make
more intelligent decisions that may significantly impact buffer object performance. It does not, however, constrain the actual usage of the data store.
usage can be broken down into two parts: first, the frequency of access (modification and usage), and second, the nature of that access. The
frequency of access may be one of these:
The nature of access may be one of these:
target - the target buffer object. One of:data - a pointer to data that will be copied into the data store for initialization, or NULL if no data is to be copiedusage - the expected usage pattern of the data store. One of:STREAM_DRAW_ARB | STREAM_READ_ARB | STREAM_COPY_ARB | STATIC_DRAW_ARB | STATIC_READ_ARB |
STATIC_COPY_ARB | DYNAMIC_DRAW_ARB | DYNAMIC_READ_ARB | DYNAMIC_COPY_ARB |
public static void glBufferDataARB(int target,
java.nio.DoubleBuffer data,
int usage)
usage is a hint to the GL implementation as to how a buffer object's data store will be accessed. This enables the GL implementation to make
more intelligent decisions that may significantly impact buffer object performance. It does not, however, constrain the actual usage of the data store.
usage can be broken down into two parts: first, the frequency of access (modification and usage), and second, the nature of that access. The
frequency of access may be one of these:
The nature of access may be one of these:
target - the target buffer object. One of:data - a pointer to data that will be copied into the data store for initialization, or NULL if no data is to be copiedusage - the expected usage pattern of the data store. One of:STREAM_DRAW_ARB | STREAM_READ_ARB | STREAM_COPY_ARB | STATIC_DRAW_ARB | STATIC_READ_ARB |
STATIC_COPY_ARB | DYNAMIC_DRAW_ARB | DYNAMIC_READ_ARB | DYNAMIC_COPY_ARB |
public static void nglBufferSubDataARB(int target,
long offset,
long size,
long data)
BufferSubDataARBsize - the size in bytes of the data store region being replacedpublic static void glBufferSubDataARB(int target,
long offset,
java.nio.ByteBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store where data replacement will begin, measured in bytesdata - a pointer to the new data that will be copied into the data storepublic static void glBufferSubDataARB(int target,
long offset,
java.nio.ShortBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store where data replacement will begin, measured in bytesdata - a pointer to the new data that will be copied into the data storepublic static void glBufferSubDataARB(int target,
long offset,
java.nio.IntBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store where data replacement will begin, measured in bytesdata - a pointer to the new data that will be copied into the data storepublic static void glBufferSubDataARB(int target,
long offset,
java.nio.FloatBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store where data replacement will begin, measured in bytesdata - a pointer to the new data that will be copied into the data storepublic static void glBufferSubDataARB(int target,
long offset,
java.nio.DoubleBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store where data replacement will begin, measured in bytesdata - a pointer to the new data that will be copied into the data storepublic static void nglGetBufferSubDataARB(int target,
long offset,
long size,
long data)
GetBufferSubDataARBsize - the size in bytes of the data store region being returnedpublic static void glGetBufferSubDataARB(int target,
long offset,
java.nio.ByteBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store from which data will be returned, measured in bytesdata - a pointer to the location where buffer object data is returnedpublic static void glGetBufferSubDataARB(int target,
long offset,
java.nio.ShortBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store from which data will be returned, measured in bytesdata - a pointer to the location where buffer object data is returnedpublic static void glGetBufferSubDataARB(int target,
long offset,
java.nio.IntBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store from which data will be returned, measured in bytesdata - a pointer to the location where buffer object data is returnedpublic static void glGetBufferSubDataARB(int target,
long offset,
java.nio.FloatBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store from which data will be returned, measured in bytesdata - a pointer to the location where buffer object data is returnedpublic static void glGetBufferSubDataARB(int target,
long offset,
java.nio.DoubleBuffer data)
target - the target buffer object. One of:offset - the offset into the buffer object's data store from which data will be returned, measured in bytesdata - a pointer to the location where buffer object data is returnedpublic static long nglMapBufferARB(int target,
int access)
MapBufferARB@Nullable
public static java.nio.ByteBuffer glMapBufferARB(int target,
int access)
LWJGL note: This method comes in 3 flavors:
glMapBufferARB(int, int) - Calls GetBufferParameterivARB to retrieve the buffer size and a new ByteBuffer instance is always returned.glMapBufferARB(int, int, ByteBuffer) - Calls GetBufferParameterivARB to retrieve the buffer size and the old_buffer parameter is reused if not null.glMapBufferARB(int, int, long, ByteBuffer) - The buffer size is explicitly specified and the old_buffer parameter is reused if not null. This is the most efficient method.target - the target buffer object being mapped. One of:access - the access policy, indicating whether it will be possible to read from, write to, or both read from and write to the buffer object's mapped data store. One of:READ_ONLY_ARB | WRITE_ONLY_ARB | READ_WRITE_ARB |
@Nullable
public static java.nio.ByteBuffer glMapBufferARB(int target,
int access,
@Nullable
java.nio.ByteBuffer old_buffer)
LWJGL note: This method comes in 3 flavors:
glMapBufferARB(int, int) - Calls GetBufferParameterivARB to retrieve the buffer size and a new ByteBuffer instance is always returned.glMapBufferARB(int, int, ByteBuffer) - Calls GetBufferParameterivARB to retrieve the buffer size and the old_buffer parameter is reused if not null.glMapBufferARB(int, int, long, ByteBuffer) - The buffer size is explicitly specified and the old_buffer parameter is reused if not null. This is the most efficient method.target - the target buffer object being mapped. One of:access - the access policy, indicating whether it will be possible to read from, write to, or both read from and write to the buffer object's mapped data store. One of:READ_ONLY_ARB | WRITE_ONLY_ARB | READ_WRITE_ARB |
@Nullable
public static java.nio.ByteBuffer glMapBufferARB(int target,
int access,
long length,
@Nullable
java.nio.ByteBuffer old_buffer)
LWJGL note: This method comes in 3 flavors:
glMapBufferARB(int, int) - Calls GetBufferParameterivARB to retrieve the buffer size and a new ByteBuffer instance is always returned.glMapBufferARB(int, int, ByteBuffer) - Calls GetBufferParameterivARB to retrieve the buffer size and the old_buffer parameter is reused if not null.glMapBufferARB(int, int, long, ByteBuffer) - The buffer size is explicitly specified and the old_buffer parameter is reused if not null. This is the most efficient method.target - the target buffer object being mapped. One of:access - the access policy, indicating whether it will be possible to read from, write to, or both read from and write to the buffer object's mapped data store. One of:READ_ONLY_ARB | WRITE_ONLY_ARB | READ_WRITE_ARB |
public static boolean glUnmapBufferARB(int target)
Returns TRUE unless data values in the buffer’s data store have become corrupted during the period that the buffer was mapped. Such corruption can be the result of a screen resolution change or other window system-dependent event that causes system heaps such as those for high-performance graphics memory to be discarded. GL implementations must guarantee that such corruption can occur only during the periods that a buffer’s data store is mapped. If such corruption has occurred, UnmapBuffer returns FALSE, and the contents of the buffer’s data store become undefined.
target - the target buffer object being unmapped. One of:public static void nglGetBufferParameterivARB(int target,
int pname,
long params)
GetBufferParameterivARBpublic static void glGetBufferParameterivARB(int target,
int pname,
java.nio.IntBuffer params)
target - the target buffer object. One of:pname - the symbolic name of a buffer object parameter. One of:BUFFER_SIZE | BUFFER_USAGE | BUFFER_ACCESS | BUFFER_MAPPED |
BUFFER_ACCESS_FLAGS | BUFFER_MAP_LENGTH | BUFFER_MAP_OFFSET | BUFFER_IMMUTABLE_STORAGE |
BUFFER_STORAGE_FLAGS |
params - the requested parameterpublic static int glGetBufferParameteriARB(int target,
int pname)
target - the target buffer object. One of:pname - the symbolic name of a buffer object parameter. One of:BUFFER_SIZE | BUFFER_USAGE | BUFFER_ACCESS | BUFFER_MAPPED |
BUFFER_ACCESS_FLAGS | BUFFER_MAP_LENGTH | BUFFER_MAP_OFFSET | BUFFER_IMMUTABLE_STORAGE |
BUFFER_STORAGE_FLAGS |
public static void nglGetBufferPointervARB(int target,
int pname,
long params)
GetBufferPointervARBpublic static void glGetBufferPointervARB(int target,
int pname,
org.lwjgl.PointerBuffer params)
target - the target buffer object. One of:pname - the pointer to be returned. Must be:BUFFER_MAP_POINTER_ARB |
params - the pointer value specified by pnamepublic static long glGetBufferPointerARB(int target,
int pname)
target - the target buffer object. One of:pname - the pointer to be returned. Must be:BUFFER_MAP_POINTER_ARB |
public static void glDeleteBuffersARB(int[] buffers)
DeleteBuffersARBpublic static void glGenBuffersARB(int[] buffers)
GenBuffersARBpublic static void glBufferDataARB(int target,
short[] data,
int usage)
BufferDataARBpublic static void glBufferDataARB(int target,
int[] data,
int usage)
BufferDataARBpublic static void glBufferDataARB(int target,
float[] data,
int usage)
BufferDataARBpublic static void glBufferDataARB(int target,
double[] data,
int usage)
BufferDataARBpublic static void glBufferSubDataARB(int target,
long offset,
short[] data)
BufferSubDataARBpublic static void glBufferSubDataARB(int target,
long offset,
int[] data)
BufferSubDataARBpublic static void glBufferSubDataARB(int target,
long offset,
float[] data)
BufferSubDataARBpublic static void glBufferSubDataARB(int target,
long offset,
double[] data)
BufferSubDataARBpublic static void glGetBufferSubDataARB(int target,
long offset,
short[] data)
GetBufferSubDataARBpublic static void glGetBufferSubDataARB(int target,
long offset,
int[] data)
GetBufferSubDataARBpublic static void glGetBufferSubDataARB(int target,
long offset,
float[] data)
GetBufferSubDataARBpublic static void glGetBufferSubDataARB(int target,
long offset,
double[] data)
GetBufferSubDataARBpublic static void glGetBufferParameterivARB(int target,
int pname,
int[] params)
GetBufferParameterivARBCopyright LWJGL. All Rights Reserved. License terms.