public class FloatBackingBuffer extends Object implements MatrixBackingBuffer, Cloneable
FloatBuffer
internally.Constructor and Description |
---|
FloatBackingBuffer(boolean direct)
Creates the backing buffer without actually creating the internal data structure.
|
Modifier and Type | Method and Description |
---|---|
void |
allocate(int size)
Allocates the internal data structure.
|
Object |
clone() |
float |
get(int index)
Reads a value.
|
boolean |
isAllocated()
Indicates whether the internal data structure is already allocated.
|
void |
set(int index,
float value)
Write a value.
|
public FloatBackingBuffer(boolean direct)
direct
- should the underlying FloatBuffer
be native/direct or not?allocate(int)
public void allocate(int size)
MatrixBackingBuffer
allocate
in interface MatrixBackingBuffer
size
- sizepublic boolean isAllocated()
MatrixBackingBuffer
isAllocated
in interface MatrixBackingBuffer
public void set(int index, float value)
MatrixBackingBuffer
set
in interface MatrixBackingBuffer
index
- indexvalue
- valuepublic float get(int index)
MatrixBackingBuffer
get
in interface MatrixBackingBuffer
index
- indexpublic Object clone() throws CloneNotSupportedException
clone
in class Object
CloneNotSupportedException
Copyright © 2011–2020 tagtraum industries incorporated. All rights reserved.