Graphviz  2.41.20171026.1811
Data Structures | Macros | Typedefs | Functions
legal.c File Reference
#include "neato.h"
#include "pathutil.h"
#include <setjmp.h>
Include dependency graph for legal.c:

Go to the source code of this file.

Data Structures

struct  vertex
 
struct  polygon
 
struct  intersection
 
struct  active_edge
 
struct  active_edge_list
 
struct  data
 

Macros

#define MAXINTS
 
#define SLOPE(p, q)   ( ( ( p.y ) - ( q.y ) ) / ( ( p.x ) - ( q.x ) ) )
 
#define EQ_PT(v, w)   (((v).x == (w).x) && ((v).y == (w).y))
 
#define after(v)   (((v)==((v)->poly->finish))?((v)->poly->start):((v)+1))
 
#define prior(v)   (((v)==((v)->poly->start))?((v)->poly->finish):((v)-1))
 
#define INBOX(p, bb)   ((p.x <= bb.UR.x) && (p.x >= bb.LL.x) && (p.y <= bb.UR.y) && (p.y >= bb.LL.y))
 
#define NESTED(a, b)   (INBOX(a.LL,b) && INBOX(a.UR,b))
 

Typedefs

typedef struct active_edge active_edge
 
typedef struct polygon polygon
 
typedef struct active_edge_list active_edge_list
 

Functions

int Plegal_arrangement (Ppoly_t **polys, int n_polys)
 

Macro Definition Documentation

#define after (   v)    (((v)==((v)->poly->finish))?((v)->poly->start):((v)+1))

Definition at line 27 of file legal.c.

#define EQ_PT (   v,
 
)    (((v).x == (w).x) && ((v).y == (w).y))

Definition at line 25 of file legal.c.

#define INBOX (   p,
  bb 
)    ((p.x <= bb.UR.x) && (p.x >= bb.LL.x) && (p.y <= bb.UR.y) && (p.y >= bb.LL.y))

Definition at line 376 of file legal.c.

#define MAXINTS
Value:
10000 /* modify this line to reflect the max no. of
intersections you want reported -- 50000 seems to break the program */

Definition at line 20 of file legal.c.

Referenced by Plegal_arrangement().

#define NESTED (   a,
 
)    (INBOX(a.LL,b) && INBOX(a.UR,b))

Definition at line 377 of file legal.c.

#define prior (   v)    (((v)==((v)->poly->start))?((v)->poly->finish):((v)-1))

Definition at line 28 of file legal.c.

#define SLOPE (   p,
 
)    ( ( ( p.y ) - ( q.y ) ) / ( ( p.x ) - ( q.x ) ) )

Definition at line 23 of file legal.c.

Typedef Documentation

typedef struct active_edge active_edge

Definition at line 30 of file legal.c.

typedef struct polygon polygon

Definition at line 31 of file legal.c.

Function Documentation

int Plegal_arrangement ( Ppoly_t **  polys,
int  n_polys 
)