Graphviz  2.41.20171026.1811
Macros | Functions
poly.c File Reference
#include "neato.h"
#include <assert.h>
#include <string.h>
#include <math.h>
#include "poly.h"
#include "geom.h"
#include "mem.h"
Include dependency graph for poly.c:

Go to the source code of this file.

Macros

#define BOX   1
 
#define ISBOX(p)   ((p)->kind & BOX)
 
#define CIRCLE   2
 
#define ISCIRCLE(p)   ((p)->kind & CIRCLE)
 
#define PUTPT(P, X, Y)   ((P).x=(X),(P).y=(Y))
 
#define Pin   1
 
#define Qin   2
 
#define Unknown   0
 
#define advance(A, B, N)   (B++, A = (A+1)%N)
 

Functions

void polyFree ()
 
void breakPoly (Poly *pp)
 
int makeAddPoly (Poly *pp, Agnode_t *n, float xmargin, float ymargin)
 
int makePoly (Poly *pp, Agnode_t *n, float xmargin, float ymargin)
 
int polyOverlap (Point p, Poly *pp, Point q, Poly *qp)
 

Macro Definition Documentation

#define advance (   A,
  B,
 
)    (B++, A = (A+1)%N)

Definition at line 367 of file poly.c.

#define BOX   1

Definition at line 25 of file poly.c.

Referenced by makeAddPoly(), and makePoly().

#define CIRCLE   2

Definition at line 27 of file poly.c.

Referenced by makeAddPoly(), and makePoly().

#define ISBOX (   p)    ((p)->kind & BOX)

Definition at line 26 of file poly.c.

Referenced by polyOverlap().

#define ISCIRCLE (   p)    ((p)->kind & CIRCLE)

Definition at line 28 of file poly.c.

Referenced by polyOverlap().

#define Pin   1

Definition at line 363 of file poly.c.

#define PUTPT (   P,
  X,
 
)    ((P).x=(X),(P).y=(Y))

Definition at line 181 of file poly.c.

Referenced by makeAddPoly(), and makePoly().

#define Qin   2

Definition at line 364 of file poly.c.

#define Unknown   0

Definition at line 365 of file poly.c.

Function Documentation

void breakPoly ( Poly pp)

Definition at line 46 of file poly.c.

References Poly::verts.

int makeAddPoly ( Poly pp,
Agnode_t n,
float  xmargin,
float  ymargin 
)
int makePoly ( Poly pp,
Agnode_t n,
float  xmargin,
float  ymargin 
)
void polyFree ( void  )

Definition at line 35 of file poly.c.

References NULL.

int polyOverlap ( Point  p,
Poly pp,
Point  q,
Poly qp 
)

Definition at line 504 of file poly.c.

References addpt(), Poly::corner, ISBOX, ISCIRCLE, N_GNEW, NULL, Poly::nverts, Poly::origin, Poly::verts, Point::x, and Point::y.