Synopsis
converts a scattered grid into triangular or tetrahedral unstructured mesh
Input Ports
in_field |
Mesh |
ui_parent |
user interface parent object |
Parameters
2D(triangles) |
UItoggle |
if 3D, make 2D triangular surface |
Output Ports
out_fld |
Mesh |
out_obj |
output renderable object |
Description
scat_to_tri converts a field with a scattered grid into a triangular or tetrahedral mesh. A "scattered grid" means that there is a mesh made up of disconnected nodes in space. An example is seismic data, where the coordinates are the latitude, longitude, (and perhaps elevation) of a sensing station, and the Node_Data was a set of observations. The grid is "scattered" because there is not data for every latitude, longitude, and elevation that exists.
Fields whose meshes have nspace=2 are converted to triangular unstructured meshes. For meshes having nspace=3, if the 2D(triangles) toggle is off, they are converted to tetrahedral unstructured meshes; if the 2D(triangles) toggle is on, they are converted to a triangular unstructured mesh (a surface existing in 3-space).
Input Ports
in_field
The input is a field with any mesh. If Node_Data is present, a reference to it is copied to the output field.
ui_parent
A port to connect to a user interface object that contains the macro's widgets. By default, it is connected to the default user interface object in the application in which the macro is instanced. (This default connection is not drawn.)
Parameters
2D(triangles)
UItoggle. This toggle only has meaning if the input is nspace=3. If off, the scattered grid is converted to a tetrahedral unstructured mesh (essentially a three-dimensional volume existing in 3-space. If on, the scattered grid is converted to a triangular unstructured mesh (essentially a two-dimensional surface existing in 3-space). The default is off.
Output Ports
out_fld
The output is a new unstructured mesh with cell type Tri (for nspace=2 or nspace=3 with 2D toggle on input) or Tet (nspace =3 input). If Node_Data was present in the input field, the output field contains a reference to it.
out_obj
This is a renderable version of the output field.
Algorithm
scat_to_tri uses a proprietary version of the Delaunay tessellation algorithm.
Example
Libraries.Examples.Visualization.Scat_to_Tet
examples/sct2tet.v
File
v/modules.v
See also
Related modules