Package org.lwjgl.opengl
Class ARBBufferObject
- java.lang.Object
-
- org.lwjgl.opengl.ARBBufferObject
-
- Direct Known Subclasses:
ARBPixelBufferObject
,ARBVertexBufferObject
,EXTPixelBufferObject
public class ARBBufferObject extends Object
-
-
Field Summary
Fields Modifier and Type Field Description 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 GetBufferParameterivARB: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_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_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_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_WRITE_ONLY_ARB
Accepted by the <access> parameter of MapBufferARB:
-
Constructor Summary
Constructors Constructor Description ARBBufferObject()
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static void
glBindBufferARB(int target, int buffer)
static void
glBufferDataARB(int target, long data_size, int usage)
static void
glBufferDataARB(int target, ByteBuffer data, int usage)
static void
glBufferDataARB(int target, DoubleBuffer data, int usage)
static void
glBufferDataARB(int target, FloatBuffer data, int usage)
static void
glBufferDataARB(int target, IntBuffer data, int usage)
static void
glBufferDataARB(int target, ShortBuffer data, int usage)
static void
glBufferSubDataARB(int target, long offset, ByteBuffer data)
static void
glBufferSubDataARB(int target, long offset, DoubleBuffer data)
static void
glBufferSubDataARB(int target, long offset, FloatBuffer data)
static void
glBufferSubDataARB(int target, long offset, IntBuffer data)
static void
glBufferSubDataARB(int target, long offset, ShortBuffer data)
static void
glDeleteBuffersARB(int buffer)
Overloads glDeleteBuffersARB.static void
glDeleteBuffersARB(IntBuffer buffers)
static int
glGenBuffersARB()
Overloads glGenBuffersARB.static void
glGenBuffersARB(IntBuffer buffers)
static int
glGetBufferParameterARB(int target, int pname)
Deprecated.Will be removed in 3.0.static void
glGetBufferParameterARB(int target, int pname, IntBuffer params)
static int
glGetBufferParameteriARB(int target, int pname)
Overloads glGetBufferParameterivARB.static ByteBuffer
glGetBufferPointerARB(int target, int pname)
static void
glGetBufferSubDataARB(int target, long offset, ByteBuffer data)
static void
glGetBufferSubDataARB(int target, long offset, DoubleBuffer data)
static void
glGetBufferSubDataARB(int target, long offset, FloatBuffer data)
static void
glGetBufferSubDataARB(int target, long offset, IntBuffer data)
static void
glGetBufferSubDataARB(int target, long offset, ShortBuffer data)
static boolean
glIsBufferARB(int buffer)
static ByteBuffer
glMapBufferARB(int target, int access, long length, ByteBuffer old_buffer)
glMapBufferARB maps a GL buffer object to a ByteBuffer.static ByteBuffer
glMapBufferARB(int target, int access, ByteBuffer old_buffer)
glMapBufferARB maps a GL buffer object to a ByteBuffer.static boolean
glUnmapBufferARB(int target)
-
-
-
Field Detail
-
GL_STREAM_DRAW_ARB
public static final int GL_STREAM_DRAW_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_STREAM_READ_ARB
public static final int GL_STREAM_READ_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_STREAM_COPY_ARB
public static final int GL_STREAM_COPY_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_STATIC_DRAW_ARB
public static final int GL_STATIC_DRAW_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_STATIC_READ_ARB
public static final int GL_STATIC_READ_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_STATIC_COPY_ARB
public static final int GL_STATIC_COPY_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_DYNAMIC_DRAW_ARB
public static final int GL_DYNAMIC_DRAW_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_DYNAMIC_READ_ARB
public static final int GL_DYNAMIC_READ_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_DYNAMIC_COPY_ARB
public static final int GL_DYNAMIC_COPY_ARB
Accepted by the <usage> parameter of BufferDataARB:- See Also:
- Constant Field Values
-
GL_READ_ONLY_ARB
public static final int GL_READ_ONLY_ARB
Accepted by the <access> parameter of MapBufferARB:- See Also:
- Constant Field Values
-
GL_WRITE_ONLY_ARB
public static final int GL_WRITE_ONLY_ARB
Accepted by the <access> parameter of MapBufferARB:- See Also:
- Constant Field Values
-
GL_READ_WRITE_ARB
public static final int GL_READ_WRITE_ARB
Accepted by the <access> parameter of MapBufferARB:- See Also:
- Constant Field Values
-
GL_BUFFER_SIZE_ARB
public static final int GL_BUFFER_SIZE_ARB
Accepted by the <pname> parameter of GetBufferParameterivARB:- See Also:
- Constant Field Values
-
GL_BUFFER_USAGE_ARB
public static final int GL_BUFFER_USAGE_ARB
Accepted by the <pname> parameter of GetBufferParameterivARB:- See Also:
- Constant Field Values
-
GL_BUFFER_ACCESS_ARB
public static final int GL_BUFFER_ACCESS_ARB
Accepted by the <pname> parameter of GetBufferParameterivARB:- See Also:
- Constant Field Values
-
GL_BUFFER_MAPPED_ARB
public static final int GL_BUFFER_MAPPED_ARB
Accepted by the <pname> parameter of GetBufferParameterivARB:- See Also:
- Constant Field Values
-
GL_BUFFER_MAP_POINTER_ARB
public static final int GL_BUFFER_MAP_POINTER_ARB
Accepted by the <pname> parameter of GetBufferParameterivARB:- See Also:
- Constant Field Values
-
-
Method Detail
-
glBindBufferARB
public static void glBindBufferARB(int target, int buffer)
-
glDeleteBuffersARB
public static void glDeleteBuffersARB(IntBuffer buffers)
-
glDeleteBuffersARB
public static void glDeleteBuffersARB(int buffer)
Overloads glDeleteBuffersARB.
-
glGenBuffersARB
public static void glGenBuffersARB(IntBuffer buffers)
-
glGenBuffersARB
public static int glGenBuffersARB()
Overloads glGenBuffersARB.
-
glIsBufferARB
public static boolean glIsBufferARB(int buffer)
-
glBufferDataARB
public static void glBufferDataARB(int target, long data_size, int usage)
-
glBufferDataARB
public static void glBufferDataARB(int target, ByteBuffer data, int usage)
-
glBufferDataARB
public static void glBufferDataARB(int target, DoubleBuffer data, int usage)
-
glBufferDataARB
public static void glBufferDataARB(int target, FloatBuffer data, int usage)
-
glBufferDataARB
public static void glBufferDataARB(int target, IntBuffer data, int usage)
-
glBufferDataARB
public static void glBufferDataARB(int target, ShortBuffer data, int usage)
-
glBufferSubDataARB
public static void glBufferSubDataARB(int target, long offset, ByteBuffer data)
-
glBufferSubDataARB
public static void glBufferSubDataARB(int target, long offset, DoubleBuffer data)
-
glBufferSubDataARB
public static void glBufferSubDataARB(int target, long offset, FloatBuffer data)
-
glBufferSubDataARB
public static void glBufferSubDataARB(int target, long offset, IntBuffer data)
-
glBufferSubDataARB
public static void glBufferSubDataARB(int target, long offset, ShortBuffer data)
-
glGetBufferSubDataARB
public static void glGetBufferSubDataARB(int target, long offset, ByteBuffer data)
-
glGetBufferSubDataARB
public static void glGetBufferSubDataARB(int target, long offset, DoubleBuffer data)
-
glGetBufferSubDataARB
public static void glGetBufferSubDataARB(int target, long offset, FloatBuffer data)
-
glGetBufferSubDataARB
public static void glGetBufferSubDataARB(int target, long offset, IntBuffer data)
-
glGetBufferSubDataARB
public static void glGetBufferSubDataARB(int target, long offset, ShortBuffer data)
-
glMapBufferARB
public static ByteBuffer glMapBufferARB(int target, int access, ByteBuffer old_buffer)
glMapBufferARB maps a GL buffer object to a ByteBuffer. The old_buffer argument can be null, in which case a new ByteBuffer will be created, pointing to the returned memory. If old_buffer is non-null, it will be returned if it points to the same mapped memory and has the same capacity as the buffer object, otherwise a new ByteBuffer is created. That way, an application will normally use glMapBufferARB like this: ByteBuffer mapped_buffer; mapped_buffer = glMapBufferARB(..., ..., null); ... // Another map on the same buffer mapped_buffer = glMapBufferARB(..., ..., mapped_buffer); Only ByteBuffers returned from this method are to be passed as the old_buffer argument. User-created ByteBuffers cannot be reused. The version of this method without an explicit length argument calls glGetBufferParameterARB internally to retrieve the current buffer object size, which may cause a pipeline flush and reduce application performance. The version of this method with an explicit length argument is a fast alternative to the one without. No GL call is made to retrieve the buffer object size, so the user is responsible for tracking and using the appropriate length.
Security warning: The length argument should match the buffer object size. Reading from or writing to outside the memory region that corresponds to the mapped buffer object will cause native crashes.- Parameters:
length
- the length of the mapped memory in bytes.old_buffer
- A ByteBuffer. If this argument points to the same address and has the same capacity as the new mapping, it will be returned and no new buffer will be created.- Returns:
- A ByteBuffer representing the mapped buffer memory.
-
glMapBufferARB
public static ByteBuffer glMapBufferARB(int target, int access, long length, ByteBuffer old_buffer)
glMapBufferARB maps a GL buffer object to a ByteBuffer. The old_buffer argument can be null, in which case a new ByteBuffer will be created, pointing to the returned memory. If old_buffer is non-null, it will be returned if it points to the same mapped memory and has the same capacity as the buffer object, otherwise a new ByteBuffer is created. That way, an application will normally use glMapBufferARB like this: ByteBuffer mapped_buffer; mapped_buffer = glMapBufferARB(..., ..., null); ... // Another map on the same buffer mapped_buffer = glMapBufferARB(..., ..., mapped_buffer); Only ByteBuffers returned from this method are to be passed as the old_buffer argument. User-created ByteBuffers cannot be reused. The version of this method without an explicit length argument calls glGetBufferParameterARB internally to retrieve the current buffer object size, which may cause a pipeline flush and reduce application performance. The version of this method with an explicit length argument is a fast alternative to the one without. No GL call is made to retrieve the buffer object size, so the user is responsible for tracking and using the appropriate length.
Security warning: The length argument should match the buffer object size. Reading from or writing to outside the memory region that corresponds to the mapped buffer object will cause native crashes.- Parameters:
length
- the length of the mapped memory in bytes.old_buffer
- A ByteBuffer. If this argument points to the same address and has the same capacity as the new mapping, it will be returned and no new buffer will be created.- Returns:
- A ByteBuffer representing the mapped buffer memory.
-
glUnmapBufferARB
public static boolean glUnmapBufferARB(int target)
-
glGetBufferParameterARB
public static void glGetBufferParameterARB(int target, int pname, IntBuffer params)
-
glGetBufferParameterARB
@Deprecated public static int glGetBufferParameterARB(int target, int pname)
Deprecated.Will be removed in 3.0. UseglGetBufferParameteriARB(int, int)
instead.Overloads glGetBufferParameterivARB.
-
glGetBufferParameteriARB
public static int glGetBufferParameteriARB(int target, int pname)
Overloads glGetBufferParameterivARB.
-
glGetBufferPointerARB
public static ByteBuffer glGetBufferPointerARB(int target, int pname)
-
-