API / geotoolkit3d / util / surface / GridTriangulator / GridTriangulator
surface.GridTriangulator.GridTriangulator
Type Aliases
Type Aliases
Ƭ Data: Object
data object
| Name | Type | Description |
|---|---|---|
elevation? | number[] | The elevation values of each point on the grid data. Should be an array of size (width * height). If not defined, the resulting surface will be flat. |
height | number | The height of the grid data (how many rows). |
normals? | boolean | true for creating normals, default is false. Normals can be generated by the THREE.js geometry themselves, and is usually not necessary to compute here. |
nullvalue? | number | Define the null value, for which grid points with a value equal to nullvalue will be ignored (no triangle will be generated for this point). |
width | number | The width of the grid data (how many columns). |
xmin? | number | The minimum x coordinate of the grid data (will be used as an offset). |
xstep? | number | The spacing between columns (along the X axis). Is only necessary if the true X and Y coordinates are not provided. Default is 1. |
xvalues? | number[] | The X coordinates of each point on the grid data. Should be an array of size (width * height). If not defined along with yvalues, the grid will procedurally generate X and Y coordinates based on height, width, Xstep/Ystep size and Xmin/Ymin coordinates. |
ymin? | number | The minimum y coordinate of the grid data (will be used as an offset). |
ystep? | number | The spacing between rows (along the Y axis). Is only necessary if the true X and Y coordinates are not provided. Default is 1. |
yvalues? | number[] | The X coordinates of each point on the grid data. Should be an array of size (width * height). If not defined along with yvalues, the grid will procedurally generate X and Y coordinates based on height, width, Xstep/Ystep size and Xmin/Ymin coordinates. |
Ƭ Options: Object
options object
| Name | Type | Description |
|---|---|---|
data | Data | data object |
surfacesmooth? | boolean | If true, surface data will be interpolated and smoothed |
Ƭ ResultObject: Object
result object
| Name | Type | Description |
|---|---|---|
bufferused | number | number of components for data |
triangles | { index: BufferAttribute ; normal?: BufferAttribute ; position: BufferAttribute ; vertexcount: number } | triangles object |
triangles.index | BufferAttribute | indices |
triangles.normal? | BufferAttribute | normals |
triangles.position | BufferAttribute | positions |
triangles.vertexcount | number | vertex count |
xmax | number | maximum x |
xmin | number | minimum x |
ymax | number | maximum y |
ymin | number | minimum y |
zmax | number | maximum z |
zmin | number | minimum z |