geometryData

vgl. geometryData

new geometryData() → {vgl.geometryData}

Description:
  • Create a new instance of class geometryData.

Source:
Returns:
Type
vgl.geometryData

Methods

addPrimitive(primitive) → {boolean}

Description:
  • Add new primitive.

Source:
Parameters:
Name Type Description
primitive vgl.primitive
Returns:
Type
boolean

addSource(source) → {boolean}

Description:
  • Add new source.

Source:
Parameters:
Name Type Description
source vgl.sourceData
Returns:

True is the source was added.

Type
boolean

bounds() → {Array.<number>}

Description:
  • Return bounds.

Source:
Returns:

Array of minX, maxX, minY, maxY, minZ, maxZ.

Type
Array.<number>

boundsDirty(dirty) → {boolean}

Description:
  • Check if bounds are dirty or mark them as such.

Source:
Parameters:
Name Type Description
dirty boolean

true to set bounds as dirty.

Returns:

true if bounds are dirty.

Type
boolean

name() → {string}

Description:
  • Return ID of the geometry data.

Source:
Returns:
Type
string

numberOfPrimitives() → {number}

Description:
  • Return number of primitives.

Source:
Returns:
Type
number

numberOfSources() → {number}

Description:
  • Return number of sources.

Source:
Returns:
Type
number

primitive(index) → {vgl.primitive|null}

Description:
  • Return primitive for a given index. Returns null if not found.

Source:
Parameters:
Name Type Description
index number
Returns:
Type
vgl.primitive | null

setBounds(minX, maxX, minY, maxY, minZ, maxZ) → {boolean}

Description:
  • Set bounds.

Source:
Parameters:
Name Type Description
minX number
maxX number
minY number
maxY number
minZ number
maxZ number
Returns:

True if set.

Type
boolean

source(index) → {vgl.sourceData|number}

Description:
  • Return source for a given index. Returns 0 if not found.

Source:
Parameters:
Name Type Description
index number
Returns:
Type
vgl.sourceData | number

sourceByName(sourceName) → {vgl.sourceData|number}

Description:
  • Return source with a specified name. Returns 0 if not found.

Source:
Parameters:
Name Type Description
sourceName string
Returns:
Type
vgl.sourceData | number

sourceData(key) → {vgl.sourceData|null}

Description:
  • Return source data given a key.

Source:
Parameters:
Name Type Description
key string
Returns:
Type
vgl.sourceData | null

type() → {number}

Description:
  • Return type.

Source:
Returns:
Type
number