forked from jontodd/r.refine
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtriangle.h
48 lines (42 loc) · 1.37 KB
/
triangle.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/* ************************************************************
*
* MODULE: r.refine
*
* Authors: Jon Todd <[email protected]>, Laura Toma <[email protected]>
* Bowdoin College, USA
*
* Purpose: convert grid data to TIN
*
* COPYRIGHT:
* This program is free software under the GNU General Public
* License (>=v2). Read the file COPYING that comes with GRASS
* for details.
*
*
************************************************************ */
/******************************************************************************
*
* triangle.h defines the triangle structure
*
* AUTHOR(S): Jonathan Todd - <[email protected]>
*
* UPDATED: jt 2005-08-15
*
* COMMENTS:
*
*****************************************************************************/
#ifndef TRIANGLE_H
#define TRIANGLE_H
#include "queue.h"
#include "point.h"
typedef struct Triangle {
R_POINT *maxE; // Pointer to the point with the max error
R_POINT *p1,*p2,*p3; // Three corner points
ELEV_TYPE maxErrorValue; // Value of the max error point
struct Triangle* p1p2; // Neighbor triangle
struct Triangle* p1p3; // Neighbor triangle
struct Triangle* p2p3; // Neighbor triangle
unsigned int pqIndex; // Pointer to this triangles in the PQ
QUEUE points; // Queue of points inside the tri (NULL if done)
} TRIANGLE;
#endif