Graphviz  2.29.20120523.0446
Defines | Functions
lib/common/geom.c File Reference
#include "geom.h"
#include "geomprocs.h"
Include dependency graph for geom.c:

Go to the source code of this file.

Defines

#define SMALL   0.0000000001
#define dot(v, w)   (v.x*w.x+v.y*w.y)

Functions

box mkbox (point p, point q)
boxf mkboxf (pointf p, pointf q)
int lineToBox (pointf p, pointf q, boxf b)
void rect2poly (pointf *p)
point cwrotatep (point p, int cwrot)
pointf cwrotatepf (pointf p, int cwrot)
point ccwrotatep (point p, int ccwrot)
pointf ccwrotatepf (pointf p, int ccwrot)
box flip_rec_box (box b, point p)
boxf flip_rec_boxf (boxf b, pointf p)
double ptToLine2 (pointf a, pointf b, pointf p)
int line_intersect (pointf a, pointf b, pointf c, pointf d, pointf *p)

Define Documentation

#define dot (   v,
 
)    (v.x*w.x+v.y*w.y)

Definition at line 402 of file geom.c.

Referenced by line_intersect(), lu_solve(), power_iteration(), and norm().

#define SMALL   0.0000000001

Definition at line 387 of file geom.c.

Referenced by ptToLine2(), and line_intersect().


Function Documentation

point ccwrotatep ( point  p,
int  ccwrot 
)

Definition at line 294 of file geom.c.

References point::x, point::y, cwrotatep(), and ccwrotatep().

Referenced by cwrotatep(), and ccwrotatep().

pointf ccwrotatepf ( pointf  p,
int  ccwrot 
)

Definition at line 322 of file geom.c.

References pointf_s::x, pointf_s::y, cwrotatepf(), and ccwrotatepf().

Referenced by cwrotatepf(), and ccwrotatepf().

point cwrotatep ( point  p,
int  cwrot 
)

Definition at line 238 of file geom.c.

References point::x, point::y, ccwrotatep(), and cwrotatep().

Referenced by cwrotatep(), and ccwrotatep().

pointf cwrotatepf ( pointf  p,
int  cwrot 
)

Definition at line 266 of file geom.c.

References pointf_s::x, pointf_s::y, ccwrotatepf(), and cwrotatepf().

Referenced by cwrotatepf(), and ccwrotatepf().

box flip_rec_box ( box  b,
point  p 
) [inline]

Definition at line 350 of file geom.c.

References box::UR, point::x, point::y, and box::LL.

boxf flip_rec_boxf ( boxf  b,
pointf  p 
)

Definition at line 366 of file geom.c.

References boxf::UR, pointf_s::x, pointf_s::y, and boxf::LL.

int line_intersect ( pointf  a,
pointf  b,
pointf  c,
pointf  d,
pointf p 
)

Definition at line 409 of file geom.c.

References dot, and SMALL.

int lineToBox ( pointf  p,
pointf  q,
boxf  b 
)

Definition at line 91 of file geom.c.

References pointf_s::x, boxf::LL, boxf::UR, and pointf_s::y.

box mkbox ( point  p,
point  q 
)

Definition at line 27 of file geom.c.

References point::x, box::LL, box::UR, and point::y.

boxf mkboxf ( pointf  p,
pointf  q 
)

Definition at line 48 of file geom.c.

References pointf_s::x, boxf::LL, boxf::UR, and pointf_s::y.

double ptToLine2 ( pointf  a,
pointf  b,
pointf  p 
)

Definition at line 392 of file geom.c.

References pointf_s::x, pointf_s::y, and SMALL.

void rect2poly ( pointf p)

Definition at line 203 of file geom.c.

References pointf_s::x, and pointf_s::y.

Referenced by emit_map_rect().