1/* $Id$ $Revision$ */
2/* vim:set shiftwidth=4 ts=8: */
3
4/*************************************************************************
5 * Copyright (c) 2011 AT&T Intellectual Property
6 * All rights reserved. This program and the accompanying materials
7 * are made available under the terms of the Eclipse Public License v1.0
8 * which accompanies this distribution, and is available at
9 * http://www.eclipse.org/legal/epl-v10.html
10 *
11 * Contributors: See CVS logs. Details at http://www.graphviz.org/
12 *************************************************************************/
13
14#ifndef DELAUNAY_H
15#define DELAUNAY_H
16
17#include "sparsegraph.h"
18
19typedef struct {
20 int nedges; /* no. of edges in triangulation */
21 int* edges; /* 2*nsegs indices of points */
22 int nfaces; /* no. of faces in triangulation */
23 int* faces; /* 3*nfaces indices of points */
24 int* neigh; /* 3*nfaces indices of neighbor triangles */
25} surface_t;
26
27v_data *delaunay_triangulation(double *x, double *y, int n);
28
29int *delaunay_tri (double *x, double *y, int n, int* nedges);
30
31int *get_triangles (double *x, int n, int* ntris);
32
33v_data *UG_graph(double *x, double *y, int n, int accurate_computation);
34
35surface_t* mkSurface (double *x, double *y, int n, int* segs, int nsegs);
36
37void freeSurface (surface_t* s);
38
39#endif
40