public interface JCGLArrayBuffersType
Modifier and Type | Method and Description |
---|---|
JCGLArrayBufferType |
arrayBufferAllocate(long size,
JCGLUsageHint usage)
Allocate and bind an array buffer of
size bytes, informing the
implementation that the buffer will be used in the manner specified by
usage . |
boolean |
arrayBufferAnyIsBound() |
void |
arrayBufferBind(JCGLArrayBufferUsableType a)
Bind the given array buffer.
|
void |
arrayBufferDelete(JCGLArrayBufferType a)
Deletes the buffer referenced by
a . |
Optional<JCGLArrayBufferUsableType> |
arrayBufferGetCurrentlyBound() |
boolean |
arrayBufferIsBound(JCGLArrayBufferUsableType a) |
ByteBuffer |
arrayBufferRead(JCGLArrayBufferUsableType a,
JCGLByteBufferProducerType f) |
void |
arrayBufferReallocate(JCGLArrayBufferUsableType a)
Reallocate the storage associated with the array buffer
a . |
void |
arrayBufferUnbind()
Unbind the current array buffer.
|
void |
arrayBufferUpdate(JCGLBufferUpdateType<JCGLArrayBufferType> u)
Perform the array buffer update
u . |
ByteBuffer arrayBufferRead(JCGLArrayBufferUsableType a, JCGLByteBufferProducerType f) throws JCGLException, JCGLExceptionDeleted, JCGLExceptionBufferNotBound
a
- The array buffer that will be readf
- A function used to allocate the bufferJCGLException
- Iff an OpenGL error occursJCGLExceptionDeleted
- If the array buffer has already been
deletedJCGLExceptionBufferNotBound
- If the array buffer a
is not
boundJCGLArrayBufferType arrayBufferAllocate(long size, JCGLUsageHint usage) throws JCGLException
Allocate and bind an array buffer of size
bytes, informing the
implementation that the buffer will be used in the manner specified by
usage
.
Calling this method will unbind any currently bound array buffer.
size
- The size in bytes of the array bufferusage
- The usage hintJCGLException
- Iff an OpenGL error occurs.void arrayBufferReallocate(JCGLArrayBufferUsableType a) throws JCGLException, JCGLExceptionDeleted, JCGLExceptionBufferNotBound
Reallocate the storage associated with the array buffer a
.
This is intended to facilitate streaming of buffer contents without incurring implicit synchronization by the OpenGL driver. The existing array buffer storage is "orphaned" and replaced by storage of the same size and with the same usage hint.
a
- The array bufferJCGLException
- Iff an OpenGL error occursJCGLExceptionDeleted
- If the array buffer has already been
deletedJCGLExceptionBufferNotBound
- If the array buffer a
is not
boundOptional<JCGLArrayBufferUsableType> arrayBufferGetCurrentlyBound() throws JCGLException
JCGLException
- Iff an OpenGL error occursboolean arrayBufferAnyIsBound() throws JCGLException
true
iff any array buffer is boundJCGLException
- Iff an OpenGL error occursboolean arrayBufferIsBound(JCGLArrayBufferUsableType a) throws JCGLException
a
- The array buffertrue
iff the given array buffer is boundJCGLException
- Iff an OpenGL error occursvoid arrayBufferBind(JCGLArrayBufferUsableType a) throws JCGLException, JCGLExceptionDeleted
a
- The array bufferJCGLException
- Iff an OpenGL error occursJCGLExceptionDeleted
- Iff the given array buffer has already been
deletedvoid arrayBufferUnbind() throws JCGLException
JCGLException
- Iff an OpenGL error occursvoid arrayBufferDelete(JCGLArrayBufferType a) throws JCGLException, JCGLExceptionDeleted
Deletes the buffer referenced by a
.
Calling this method will unbind a
iff it is bound.
a
- The array bufferJCGLExceptionDeleted
- If the array is already deletedJCGLException
- Iff an OpenGL error occursvoid arrayBufferUpdate(JCGLBufferUpdateType<JCGLArrayBufferType> u) throws JCGLException, JCGLExceptionDeleted, JCGLExceptionBufferNotBound
Perform the array buffer update u
.
u
- The updateJCGLException
- Iff an OpenGL error occursJCGLExceptionDeleted
- If the array buffer has already been
deletedJCGLExceptionBufferNotBound
- If the array buffer in u
is not
boundCopyright © 2017 <code@io7m.com> http://io7m.com