|
Oracle® Spatial Java API Reference 10g Release 2 (10.2) B14373-02 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.spatial.topo.CompGeom
public class CompGeom
Constructor Summary | |
---|---|
CompGeom() |
Method Summary | |
---|---|
static void |
augmentMBR(Point2DD[] mbrAdd, Point2DD[] mbrTarget) Expands target MBR to encompass added one. |
static void |
crossProduct(double[] r1, double[] r2, double[] result) 3-D crossproduct via arrays. |
static double |
crossProduct(double x1, double y1, double x2, double y2) |
static double |
crossProduct(Point2DD p1, Point2DD p2) |
static double |
dotProduct(double x1, double y1, double x2, double y2) |
static double |
dotProduct(Point2DD p1, Point2DD p2) |
static boolean |
incPointInPolygon(Point2DD p, Point2DD[] q, boolean state) Incremental Point in Polygon routine taking a string of coordinates representing a part (or all) of a ring boundary. |
static boolean |
inSector(double px, double py, double sp1x, double sp1y, double sp2x, double sp2y, double sp3x, double sp3y) inSector determines whether a line drawn from the middle vertex of a triad of vertices to a test point lies within the sector defined by the triad. |
static boolean |
inSector(Point2DD p, Point2DD[] sectorPoints) inSector determines whether a line drawn from the middle vertex of a triad of vertices to a test point lies within the sector defined by the triad. |
static boolean |
lineLineIntersect(Point2DD a1, Point2DD a2, Point2DD b1, Point2DD b2, Point2DD c) Finds the open-set intersection of two line segments, if any. |
static void |
main(java.lang.String[] args) |
static boolean |
pointInMBR(double px, double py, double[][] mbr) Determines if a point is within the bounds of the specified rectangle. |
static boolean |
pointInMBR(Point2DD p, Point2DD[] mbr) Determines if a point is within the bounds of the specified rectangle. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CompGeom()
Method Detail |
---|
public static double dotProduct(Point2DD p1, Point2DD p2)
public static double crossProduct(Point2DD p1, Point2DD p2)
public static double dotProduct(double x1, double y1, double x2, double y2)
public static double crossProduct(double x1, double y1, double x2, double y2)
public static void crossProduct(double[] r1, double[] r2, double[] result)
public static boolean inSector(Point2DD p, Point2DD[] sectorPoints)
p
- The test pointsectorPoints
- The triad to be tested. Vertex [0] and [2] are the endpoints. Vertex [1] is the central vertex.public static boolean inSector(double px, double py, double sp1x, double sp1y, double sp2x, double sp2y, double sp3x, double sp3y)
px
- The test point x valuepy
- The test point y valuesp1x
- x value of triad point 1sp1y
- y value of triad point 1sp2x
- x value of triad point 2, the central vertexsp2y
- y value of triad point 2sp3x
- x value of triad point 3sp3y
- y value of triad point 3public static void augmentMBR(Point2DD[] mbrAdd, Point2DD[] mbrTarget)
mbrAdd
- the one to be addedmbrTarget
- the one that is augmented if necessarypublic static boolean pointInMBR(Point2DD p, Point2DD[] mbr) throws java.lang.Exception
p
- the point to be tested.mbr
- an array of Point2DD. [0] is the rectangle lower left corner. [1] is the rectangle upper right corner.java.lang.Exception
public static boolean pointInMBR(double px, double py, double[][] mbr)
px
- x component of the point to be tested.py
- y component of the point to be tested.mbr
- a 2x2 array of doubles. First index is x,y. Second is min,maxpublic static boolean incPointInPolygon(Point2DD p, Point2DD[] q, boolean state)
p
- The test pointq
- The portion or all of the polygon perimeterstate
- the current in/out status of the determination. Set false intitiallypublic static boolean lineLineIntersect(Point2DD a1, Point2DD a2, Point2DD b1, Point2DD b2, Point2DD c)
a1
- the first endpoint of line segment aa2
- the second endpoint of line segment ab1
- the first endpoint of line segment bb2
- the second endpoint of line segment bc
- the intersection (if any). Not set if there is no intersection.public static void main(java.lang.String[] args) throws java.io.IOException
java.io.IOException
|
Oracle® Spatial Java API Reference 10g Release 2 (10.2) B14373-02 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |