ComponentDatatype
Enumerations for WebGL component datatypes. Components are intrinsics, which form attributes, which form vertices.
Members
-
<static, constant> BYTE :Enumeration
-
8-bit signed byte enumeration corresponding to
gl.BYTEand the type of an element inInt8Array.- Default Value:
- 0x1400
-
<static, constant> DOUBLE :Enumeration
-
64-bit floating-point enumeration corresponding to
gl.DOUBLE(in Desktop OpenGL; this is not supported in WebGL, and is emulated in Cesium via GeometryPipeline.encodeAttribute) and the type of an element inFloat64Array.- Default Value:
- 0x140A
-
<static, constant> FLOAT :Enumeration
-
32-bit floating-point enumeration corresponding to
FLOATand the type of an element inFloat32Array.- Default Value:
- 0x1406
-
<static, constant> SHORT :Enumeration
-
16-bit signed short enumeration corresponding to
SHORTand the type of an element inInt16Array.- Default Value:
- 0x1402
-
<static, constant> UNSIGNED_BYTE :Enumeration
-
8-bit unsigned byte enumeration corresponding to
UNSIGNED_BYTEand the type of an element inUint8Array.- Default Value:
- 0x1401
-
<static, constant> UNSIGNED_INT :Enumeration
-
32-bit unsigned int enumeration corresponding to
UNSIGNED_INTand the type of an element inUint32Array. -
<static, constant> UNSIGNED_SHORT :Enumeration
-
16-bit unsigned short enumeration corresponding to
UNSIGNED_SHORTand the type of an element inUint16Array.- Default Value:
- 0x1403
Methods
-
<static> validate
-
Validates that the provided component datatype is a valid ComponentDatatype
Parameters:
Name Type Description componentDatatypeComponentDatatype The component datatype to validate. Returns:
Booleantrueif the provided component datatype is a valid enumeration value; otherwise,false.Example
if (!ComponentDatatype.validate(componentDatatype)) { throw new DeveloperError('componentDatatype must be a valid enumeration value.'); }
