API / geotoolkit / contour / grid / ContourTriangularGrid / ContourTriangularGrid
grid.ContourTriangularGrid.ContourTriangularGrid
Contour grid built on a set of triangles.
↳
ContourTriangularGrid
Constructors
Accessors
Methods
Constructors
• new ContourTriangularGrid()
ContourAbstractGrid.constructor
Accessors
• Static get SpaceReserveRatio(): number
The space reserve ratio
number
ContourAbstractGrid.SpaceReserveRatio
Methods
▸ addHoleValue(holeValue): void
Adds a value that will serve as an indicator for a hole in data grid. It is assumed that grid data may have more than one hole value.
| Name | Type | Description |
|---|---|---|
holeValue | number | The hole value |
void
▸ clear(): void
Removes all grid data
void
▸ clearGrid(): void
Clears grid data
void
▸ convertToSafeFloat64(value): number
Converts the value that is not altered when setting to a Float64Array value.
| Name | Type | Description |
|---|---|---|
value | number | The value that will be converted to a safe double. |
number
safeValue The converted value.
ContourAbstractGrid.convertToSafeFloat64
▸ getBuildRange(netRange, realRange): void
Gets the build range
| Name | Type | Description |
|---|---|---|
netRange | GridRange | The range for the net |
realRange | GridRange | The range for the data |
void
ContourAbstractGrid.getBuildRange
▸ getClassName(): string
string
ContourAbstractGrid.getClassName
▸ getGridToModel(): Transformation
Gets the grid-to-model transformation
transformation Grid-To-Model transformation
ContourAbstractGrid.getGridToModel
▸ getMaxValue(): number
Gets the maximum value in the contour grid. If the max value has not been set this method will scan whole grid to find maximum altitude value (but only once, then it will remember it).
number
max The maximum value
ContourAbstractGrid.getMaxValue
▸ getMinValue(): number
Gets the minimum value in the contour grid. If the max value has not been set this method will scan whole grid to find maximum altitude value (but only once, then it will remember it).
number
max The maximum value
ContourAbstractGrid.getMinValue
▸ getModelLimits(): Rect
Gets the model limits of the data
modelLimits The model limits
ContourAbstractGrid.getModelLimits
▸ getNumberPoints(): number
Gets the number of points
number
number The number of points
▸ getNumberTriangles(): number
Gets the number of triangles
number
number The number of triangles
▸ getPointValue(indexPoint): number
Value current altitude values for point
| Name | Type | Description |
|---|---|---|
indexPoint | number | The number value point |
number
altitudeValue The altitude value for the point
▸ getPointsX(): Float64Array
Gets the X points.
Float64Array
xPoints The array of X points.
▸ getPointsY(): Float64Array
Gets the Y points.
Float64Array
yPoints The array of Y points.
▸ getPointsZ(): Float64Array
Gets the Z points.
Float64Array
zPoints The array of Z points.
▸ getRange(): GridRange
Gets the Grid Range (Reserved. Always returns SetGridRange(0,0,0,0))
gridRange
▸ getRemoveDuplicatePoints(): boolean
This property gets the duplicates removal mode for the triangular grid. If set to TRUE, then the system will attempt to fix errors in input data. This feature is enabled by default.
boolean
removeDuplicatePoints If True duplicates will be removed.
▸ getTriangleGrid2ModelTransformation(): Transformation
Get grid to model mapping transformation for triangle grid data.
transformation The grid to model transformation
▸ getTrianglesAB(): Int32Array
Gets the array of first point index for triangles
Int32Array
Triangles AB
▸ getTrianglesBC(): Int32Array
Gets the array of second point index for triangles
Int32Array
Triangles BC
▸ getTrianglesCA(): Int32Array
Gets the array of third point index for triangles
Int32Array
Triangles CA
▸ getValueAtModelPoint(modelPoint): number
Gets the altitude at the give model point location.
| Name | Type | Description |
|---|---|---|
modelPoint | Point | The model point |
number
modelPoint The model point's value
ContourAbstractGrid.getValueAtModelPoint
▸ needRebuild(): boolean
Returns grid rebuild state.
boolean
needRebuild True if grid is to be rebuilt (data changed)
ContourAbstractGrid.needRebuild
▸ setGridToModel(transformation): void
Sets the grid-to-model transformation
| Name | Type | Description |
|---|---|---|
transformation | Transformation | Grid-To-Model transformation |
void
ContourAbstractGrid.setGridToModel
▸ setMaxValue(value): ContourTriangularGrid
Sets the maximum value in the contour grid
| Name | Type | Description |
|---|---|---|
value | number | The new maximum value |
this
▸ setMinValue(value): ContourTriangularGrid
Sets the minimum value in the contour grid
| Name | Type | Description |
|---|---|---|
value | number | The new maximum value |
this
▸ setRange(gridRange): void
Sets the Grid Range (Reserved. Always sets SetGridRange(0,0,0,0))
| Name | Type | Description |
|---|---|---|
gridRange | GridRange | The grid z-value range. |
void
▸ setRemoveDuplicatePoints(removeDuplicatePoints): ContourTriangularGrid
This property enables/disables duplicates removal from triangular grid. If set to TRUE, then the system will attempt to fix errors in input data. This feature is enabled by default.
| Name | Type | Description |
|---|---|---|
removeDuplicatePoints | boolean | If True duplicates will be removed. |
this
▸ setTrianglesAdvanced(pointsX, pointsY, pointsZ, nPoints, edgesPoint1, edgesPoint2, nEdges, trianglesEdgeAB, trianglesEdgeBC, trianglesEdgeCA, nTriangles, defaultBorder, borderEdges, nBorderEdges): ContourTriangularGrid
Sets data for grid. This is the more complicated method of two setTriangles but is faster and has more advanced border visualization handling.
| Name | Type | Description |
|---|---|---|
pointsX | number[] | Float64Array | array of x-coordinates for points. |
pointsY | number[] | Float64Array | array of y-coordinates for points. |
pointsZ | number[] | Float64Array | array of altitude values for points. |
nPoints | number | The number of points. |
edgesPoint1 | number[] | Int32Array | Array of first point index for edges. |
edgesPoint2 | number[] | Int32Array | Array of second point index for edges. |
nEdges | number | The number of edges. |
trianglesEdgeAB | number[] | Int32Array | Array of first edge index for triangles. |
trianglesEdgeBC | number[] | Int32Array | Array of second edge index for triangles. |
trianglesEdgeCA | number[] | Int32Array | Array of third edge index for triangles. |
nTriangles | number | The number of triangles. |
defaultBorder | boolean | The default border. |
borderEdges | Int32Array | The border edges (can be null). |
nBorderEdges | number | The number of border edges. |
this
▸ setTrianglesSimple(pointsX, pointsY, pointsZ, nPoints, trianglesPointsA, trianglesPointsB, trianglesPointsC, nTriangles, defaultBorder): ContourTriangularGrid
Sets data for grid.
| Name | Type | Description |
|---|---|---|
pointsX | number[] | Float64Array | array of x-coordinates for points. |
pointsY | number[] | Float64Array | array of y-coordinates for points. |
pointsZ | number[] | Float64Array | array of altitude values for points. |
nPoints | number | The number of points. |
trianglesPointsA | number[] | Int32Array | Array of first point index for triangles. |
trianglesPointsB | number[] | Int32Array | Array of second point index for triangles. |
trianglesPointsC | number[] | Int32Array | Array of third point index for triangles. |
nTriangles | number | The number of triangles. |
defaultBorder | boolean | if true, all edges that belong to only one triangle are included into contour border for visualization |
this
▸ Static getClassName(): string
string