TIN with breaklines

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

TIN

Triangular irregular networks (TIN) are widely spread in GIS community (in ESRI software, other commercial GIS and CAD) to represent surface morphology.

The most common way of TIN construction is Delaunay triangulation. GRASS has module <v.delaunay> to do this task, but it don't work with "breaklines", e.g. with constrained Delaunay triangulation.

<v.triangle> module

Add-on module <a rel="nofollow" class="external text" href="https://raw.github.com/amuriy/GRASS-scripts/master/v.triangle">v.triangle</a> was written as attempt to close this gap. It's simply a "front-end" to the famous <a rel="nofollow" class="external text" href="http://www.cs.cmu.edu/~quake/triangle.html">Triangle</a> utility of J.R. Shewchuk. <Triangle> makes exact Delaunay triangulations, constrained Delaunay triangulations, conforming Delaunay triangulations and high-quality triangular meshes. On GIS terminology, it produces 2D TIN, optionally with "breaklines".

Module is a shell script that implements the main <Triangle> options and use it as "filter" to produce 2D TIN from the vector points/lines data.

Usage:
v.triangle [-cdqalysif] points=name [lines=name] tin=name
[max_area=name] [min_angle=name] [steiner_points=name] [save=name]

Flags:
-c Conforming constrained Delaunay triangulation without angle or area constraints
-d Conforming Delaunay triangulation
-q Quality mesh generation (all angles are between 20 and 140 degrees)
-a Imposes a maximum triangle area constraint
-l Uses only vertical cuts in the divide-and-conquer algorithm
-y Prohibits the insertion of Steiner points on the mesh boundary
-s Specifies the maximum number of added Steiner points
-i Uses the incremental algorithm for Delaunay triangulation, rather than the divide-and-conquer algorithm
-f Uses Steven Fortune's sweepline algorithm for Delaunay triangulation, rather than the divide-and-conquer algorithm
--o Allow output files to overwrite existing files
--v Verbose module output
--q Quiet module output
Parameters:
points Input vector map containing points
lines Input vector map containing breaklines
tin Name of output vector map (TIN)
max_area Maximum triangle area (use with "-a" flag)
min_angle Minimum mesh angle (use with "-q" flag)
steiner_points Specifies the maximum number of Steiner points that may be inserted into the mesh (use with "-s" flag)
save Path to save <Triangle> working files (*.node,*.poly,*.edge,*.ele). By default uses current location directory

Example

The following example was produced using ESRI sample data (masspoints and breaklines) to compare ArcView 3D Analyst TIN and <Triangle> TIN.

The command used: v.triangle -c points=pts lines=lines tin=tin

<a href="/wiki/File:ArcView_GRASS_TIN_breaklines_l.png" class="image"><img alt="ArcView GRASS TIN breaklines l.png" src="/grass-wiki/images/ArcView_GRASS_TIN_breaklines_l.png" width="1481" height="716" /></a>

<a href="/grass-wiki/index.php?title=Sv:Main_Page/sv&action=edit&redlink=1" class="new" title="Sv:Main Page/sv (страница не существует)">sv:Main Page/sv</a>