23#include <geos/export.h>
24#include <geos/geom/Quadrant.h>
25#include <geos/geom/Coordinate.h>
26#include <geos/util/IllegalArgumentException.h>
56 static const int NE = 0;
57 static const int NW = 1;
58 static const int SW = 2;
59 static const int SE = 3;
69 if(dx == 0.0 && dy == 0.0) {
71 s <<
"Cannot compute the quadrant for point ";
72 s <<
"(" << dx <<
"," << dy <<
")" << std::endl;
98 static int quadrant(
const geom::CoordinateXY& p0,
const geom::CoordinateXY& p1)
100 if(p1.x == p0.x && p1.y == p0.y) {
130 int diff = (quad1 - quad2 + 4) % 4;
144 static int commonHalfPlane(
int quad1,
int quad2);
157 return quad == NE || quad == NW;
Utility functions for working with quadrants.
Definition Quadrant.h:52
static int quadrant(double dx, double dy)
Definition Quadrant.h:67
static bool isOpposite(int quad1, int quad2)
Definition Quadrant.h:125
static int quadrant(const geom::CoordinateXY &p0, const geom::CoordinateXY &p1)
Definition Quadrant.h:98
static bool isInHalfPlane(int quad, int halfPlane)
static bool isNorthern(int quad)
Definition Quadrant.h:155
Indicates one or more illegal arguments.
Definition IllegalArgumentException.h:33
Basic namespace for all GEOS functionalities.
Definition geos.h:39