Class TLcdEarthVertexArray
java.lang.Object
com.luciad.earth.tileset.datatype.TLcdEarthVertexArray
- All Implemented Interfaces:
ILcdBounded
- Direct Known Subclasses:
TLcdEarthIndexedVertexArray
,TLcdEarthTerrainTileVertexArray
A container for vertex array data that can be drawn directly with OpenGL
(for instance using
glDrawArrays()
). A vertex array contains
the following data:
- a FloatBuffer that contains the vertex coordinates and any other vertex attributes, in an interleaved fashion;
- a vertex format, which defines the layout of the aforementioned
FloatBuffer; the vertex format is one of the symbolic constants
accepted by
glInterleavedArrays()
; - a primitive type, which defines the type of primitive to be used when
drawing from this vertex array; the primitive type is one of the
symbolic constants accepted by
glBegin()
;
- the bounds of the vertices in the array;
- an optional local coordinate origin against which the vertices are defined; if this is set, the camera should be transformed to the local coordinate system before drawing the vertex array.
- Since:
- 8.2
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs an emptyTLcdEarthVertexArray
.TLcdEarthVertexArray
(TLcdEarthVertexArray aVertexArray) Constructs aTLcdEarthVertexArray
with the same properties as the specified vertex array. -
Method Summary
Modifier and TypeMethodDescriptionReturns theILcdBounds
by which the geometry of thisILcdBounded
object is bounded.int
int
void
setBounds
(ILcdBounds aBounds) void
setCoordinateOrigin
(ILcdPoint aCoordinateOrigin) void
setPrimitiveType
(int aPrimitiveType) void
setVertexFormat
(int aVertexFormat) void
setVertices
(FloatBuffer aVertices)
-
Field Details
-
GL_POINTS
public static final int GL_POINTS- See Also:
-
GL_LINES
public static final int GL_LINES- See Also:
-
GL_LINE_LOOP
public static final int GL_LINE_LOOP- See Also:
-
GL_LINE_STRIP
public static final int GL_LINE_STRIP- See Also:
-
GL_TRIANGLES
public static final int GL_TRIANGLES- See Also:
-
GL_TRIANGLE_STRIP
public static final int GL_TRIANGLE_STRIP- See Also:
-
GL_TRIANGLE_FAN
public static final int GL_TRIANGLE_FAN- See Also:
-
GL_QUADS
public static final int GL_QUADS- See Also:
-
GL_QUAD_STRIP
public static final int GL_QUAD_STRIP- See Also:
-
GL_POLYGON
public static final int GL_POLYGON- See Also:
-
GL_V2F
public static final int GL_V2F- See Also:
-
GL_V3F
public static final int GL_V3F- See Also:
-
GL_C3F_V3F
public static final int GL_C3F_V3F- See Also:
-
GL_N3F_V3F
public static final int GL_N3F_V3F- See Also:
-
GL_C4F_N3F_V3F
public static final int GL_C4F_N3F_V3F- See Also:
-
GL_T2F_V3F
public static final int GL_T2F_V3F- See Also:
-
GL_T4F_V4F
public static final int GL_T4F_V4F- See Also:
-
GL_T2F_C3F_V3F
public static final int GL_T2F_C3F_V3F- See Also:
-
GL_T2F_N3F_V3F
public static final int GL_T2F_N3F_V3F- See Also:
-
GL_T2F_C4F_N3F_V3F
public static final int GL_T2F_C4F_N3F_V3F- See Also:
-
GL_T4F_C4F_N3F_V4F
public static final int GL_T4F_C4F_N3F_V4F- See Also:
-
-
Constructor Details
-
TLcdEarthVertexArray
public TLcdEarthVertexArray()Constructs an emptyTLcdEarthVertexArray
. -
TLcdEarthVertexArray
Constructs aTLcdEarthVertexArray
with the same properties as the specified vertex array. Note that no actual data is copied. For example writing to the vertices buffer will also affect the specified vertex array.- Parameters:
aVertexArray
- a vertex array
-
-
Method Details
-
getVertices
-
setVertices
-
getVertexFormat
public int getVertexFormat() -
setVertexFormat
public void setVertexFormat(int aVertexFormat) - Parameters:
aVertexFormat
- the OpenGL interleaved vertex format or-1
if it is custom
-
getPrimitiveType
public int getPrimitiveType() -
setPrimitiveType
public void setPrimitiveType(int aPrimitiveType) -
getBounds
Description copied from interface:ILcdBounded
Returns theILcdBounds
by which the geometry of thisILcdBounded
object is bounded.If the geometry does not allow retrieving valid bounds (for example a polyline with 0 points) the return value is unspecified. It is highly recommended to return an
undefined
bounds. You can create undefined bounds using the default constructors ofTLcdLonLatBounds
orTLcdXYBounds
.- Specified by:
getBounds
in interfaceILcdBounded
- Returns:
- the
ILcdBounds
by which the geometry of thisILcdBounded
object is bounded.
-
setBounds
-
getCoordinateOrigin
-
setCoordinateOrigin
-