public static class BufferWrapper.ShortBufferWrapper extends BufferWrapper.AbstractBufferWrapper<ShortBuffer>
BufferWrapper.AbstractBufferWrapper<T extends Buffer>, BufferWrapper.ByteBufferWrapper, BufferWrapper.DoubleBufferWrapper, BufferWrapper.EmptyBufferWrapper, BufferWrapper.FloatBufferWrapper, BufferWrapper.IntBufferWrapper, BufferWrapper.ShortBufferWrapperbufferEMPTY_BUFFER_WRAPPER| Constructor and Description |
|---|
ShortBufferWrapper(ShortBuffer buffer) |
| Modifier and Type | Method and Description |
|---|---|
BufferWrapper |
copyOf(int newSize)
Returns a copy of this buffer with the specified new size.
|
protected void |
doGetByte(byte[] array,
int offset,
int length) |
protected void |
doGetDouble(double[] array,
int offset,
int length) |
protected void |
doGetFloat(float[] array,
int offset,
int length) |
protected void |
doGetInt(int[] array,
int offset,
int length) |
protected void |
doGetShort(short[] array,
int offset,
int length) |
protected BufferWrapper |
doGetSubBuffer() |
protected void |
doPutByte(byte[] array,
int offset,
int length) |
protected void |
doPutDouble(double[] array,
int offset,
int length) |
protected void |
doPutFloat(float[] array,
int offset,
int length) |
protected void |
doPutInt(int[] array,
int offset,
int length) |
protected void |
doPutShort(short[] array,
int offset,
int length) |
protected boolean |
doPutSubBuffer(int index,
BufferWrapper buffer,
int offset,
int length) |
ShortBuffer |
getBackingShortBuffer() |
byte |
getByte(int index)
Returns the value at the specified index, cast to a byte.
|
double |
getDouble(int index)
Returns the value at the specified index, cast to a double.
|
float |
getFloat(int index)
Returns the value at the specified index, cast to a float.
|
int |
getGLDataType()
Returns the OpenGL data type corresponding to the buffer's underlying data type (e.g.
|
int |
getInt(int index)
Returns the value at the specified index, cast to an int.
|
short |
getShort(int index)
Returns the value at the specified index, cast to a short.
|
long |
getSizeInBytes()
Returns the size of this buffer, in bytes.
|
void |
putByte(int index,
byte value)
Sets the value at the specified index as a byte.
|
void |
putDouble(int index,
double value)
Sets the value at the specified index as a double.
|
void |
putFloat(int index,
float value)
Sets the value at the specified index as a float.
|
void |
putInt(int index,
int value)
Sets the value at the specified index as an int.
|
void |
putShort(int index,
short value)
Sets the value at the specified index as a short.
|
getBackingBuffer, getByte, getDouble, getFloat, getInt, getShort, getSubBuffer, length, putByte, putDouble, putFloat, putInt, putShort, putSubBuffer, putSubBufferemptyBufferWrapper, wrap, wrap, wrappublic ShortBufferWrapper(ShortBuffer buffer)
public BufferWrapper copyOf(int newSize)
BufferWrappercopyOf in class BufferWrappernewSize - the new buffer's size.protected void doGetByte(byte[] array,
int offset,
int length)
doGetByte in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doGetDouble(double[] array,
int offset,
int length)
doGetDouble in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doGetFloat(float[] array,
int offset,
int length)
doGetFloat in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doGetInt(int[] array,
int offset,
int length)
doGetInt in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doGetShort(short[] array,
int offset,
int length)
doGetShort in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected BufferWrapper doGetSubBuffer()
doGetSubBuffer in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doPutByte(byte[] array,
int offset,
int length)
doPutByte in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doPutDouble(double[] array,
int offset,
int length)
doPutDouble in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doPutFloat(float[] array,
int offset,
int length)
doPutFloat in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doPutInt(int[] array,
int offset,
int length)
doPutInt in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected void doPutShort(short[] array,
int offset,
int length)
doPutShort in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>protected boolean doPutSubBuffer(int index,
BufferWrapper buffer,
int offset,
int length)
doPutSubBuffer in class BufferWrapper.AbstractBufferWrapper<ShortBuffer>public ShortBuffer getBackingShortBuffer()
public byte getByte(int index)
BufferWrappergetByte in class BufferWrapperindex - the index of the value to be returned.public double getDouble(int index)
BufferWrappergetDouble in class BufferWrapperindex - the index of the value to be returned.public float getFloat(int index)
BufferWrappergetFloat in class BufferWrapperindex - the index of the value to be returned.public int getGLDataType()
BufferWrappergetGLDataType in class BufferWrapperpublic int getInt(int index)
BufferWrappergetInt in class BufferWrapperindex - the index of the value to be returned.public short getShort(int index)
BufferWrappergetShort in class BufferWrapperindex - the index of the value to be returned.public long getSizeInBytes()
BufferWrappergetSizeInBytes in class BufferWrapperpublic void putByte(int index,
byte value)
BufferWrapperputByte in class BufferWrapperindex - the index of the value to be returned.value - the byte value to be set.public void putDouble(int index,
double value)
BufferWrapperputDouble in class BufferWrapperindex - the index of the value to be returned.value - the double value to be set.public void putFloat(int index,
float value)
BufferWrapperputFloat in class BufferWrapperindex - the index of the value to be returned.value - the float value to be set.public void putInt(int index,
int value)
BufferWrapperputInt in class BufferWrapperindex - the index of the value to be returned.value - the int value to be set.public void putShort(int index,
short value)
BufferWrapperputShort in class BufferWrapperindex - the index of the value to be returned.value - the short value to be set.