public class QuadMeshBuffer extends VertexBuffer
Modifier and Type | Field and Description |
---|---|
protected short[] |
mIndices |
protected boolean |
mInvalidated |
protected int |
mNumCells |
protected float[] |
mVertices |
static int |
NUM_INDICES_PER_CELL |
static int |
NUM_VERTICES_PER_CELL |
mIndexBuffer, mIndicesNum, mIndicesNumUsed, mPrimitive, mVertexPointerSize, mVerticesNum
mBuffer
Constructor and Description |
---|
QuadMeshBuffer(int numCells) |
Modifier and Type | Method and Description |
---|---|
void |
draw(GLState glState) |
int |
getNumCells() |
float[] |
getVertices() |
void |
setNumCells(int numCells) |
void |
setRectAt(int index,
float x,
float y,
float width,
float height)
Sets a Rect at a specified index but doesn't apply untill applyValues() gets called
|
void |
setRectFlipVerticalAt(int index,
float x,
float y,
float width,
float height)
Sets a Rect at a specified index but doesn't apply untill applyValues() gets called
|
void |
setValuesAt(int index,
float... values) |
void |
setValuesAt(int index,
int numCells,
float... values) |
void |
setValuesAt(int index,
int numCells,
int srcOffset,
float... values) |
protected void |
validate()
Applies the values set by
#setRectAt(int, float...) |
dispose, getIndexBuffer, getIndicesNum, getIndicesNumUsed, getPrimitive, getVertexPointerSize, getVerticesNum, setIndices, setIndicesNumUsed, setPrimitive, setVertexPointerSize, setVertices
setValues
public static final int NUM_VERTICES_PER_CELL
public static final int NUM_INDICES_PER_CELL
protected float[] mVertices
protected short[] mIndices
protected int mNumCells
protected boolean mInvalidated
public void setNumCells(int numCells)
public int getNumCells()
public float[] getVertices()
public void setRectAt(int index, float x, float y, float width, float height)
index
- x
- y
- width
- height
- validate()
public void setRectFlipVerticalAt(int index, float x, float y, float width, float height)
index
- x
- y
- width
- height
- validate()
public void setValuesAt(int index, float... values)
public void setValuesAt(int index, int numCells, float... values)
public void setValuesAt(int index, int numCells, int srcOffset, float... values)
protected void validate()
#setRectAt(int, float...)
public void draw(GLState glState)
draw
in class VertexBuffer