BowlerKernel
|
Public Member Functions | |
Plane (Vector3d normal, double dist) | |
Plane | clone () |
void | flip () |
void | splitPolygon (Polygon polygon, List< Polygon > coplanarFront, List< Polygon > coplanarBack, List< Polygon > front, List< Polygon > back) |
Static Public Member Functions | |
static Plane | createFromPoints (Vector3d a, Vector3d b, Vector3d c) |
static IPolygonDebugger | getDebugger () |
static void | setDebugger (IPolygonDebugger debugger) |
static boolean | isUseDebugger () |
static void | setUseDebugger (boolean useDebugger) |
Public Attributes | |
Vector3d | normal |
double | dist |
Static Public Attributes | |
static final double | EPSILON = 1.0e-9 |
static final double | EPSILON_Point = EPSILON |
static final double | EPSILON_duplicate = 1.0e-4 |
static final Plane | XY_PLANE = new Plane(Vector3d.Z_ONE, 1) |
static final Plane | XZ_PLANE = new Plane(Vector3d.Y_ONE, 1) |
static final Plane | YZ_PLANE = new Plane(Vector3d.X_ONE, 1) |
Static Private Attributes | |
static IPolygonDebugger | debugger = null |
static boolean | useDebugger = false |
Represents a plane in 3D space.
Definition at line 46 of file Plane.java.
eu.mihosoft.vrl.v3d.Plane.Plane | ( | Vector3d | normal, |
double | dist | ||
) |
Constructor. Creates a new plane defined by its normal vector and the distance to the origin.
normal | plane normal |
dist | distance from origin |
Definition at line 87 of file Plane.java.
References eu.mihosoft.vrl.v3d.Plane.dist, eu.mihosoft.vrl.v3d.Plane.normal, and eu.mihosoft.vrl.v3d.Vector3d.normalized().
Referenced by eu.mihosoft.vrl.v3d.Plane.clone(), and eu.mihosoft.vrl.v3d.Plane.createFromPoints().
Plane eu.mihosoft.vrl.v3d.Plane.clone | ( | ) |
Definition at line 109 of file Plane.java.
References eu.mihosoft.vrl.v3d.Vector3d.clone(), eu.mihosoft.vrl.v3d.Plane.dist, eu.mihosoft.vrl.v3d.Plane.normal, and eu.mihosoft.vrl.v3d.Plane.Plane().
|
static |
Creates a plane defined by the the specified points.
a | first point |
b | second point |
c | third point |
Definition at line 100 of file Plane.java.
References eu.mihosoft.vrl.v3d.Vector3d.cross(), eu.mihosoft.vrl.v3d.Vector3d.dot(), eu.mihosoft.vrl.v3d.Vector3d.minus(), eu.mihosoft.vrl.v3d.Vector3d.normalized(), and eu.mihosoft.vrl.v3d.Plane.Plane().
Referenced by eu.mihosoft.vrl.v3d.Polygon.Polygon().
void eu.mihosoft.vrl.v3d.Plane.flip | ( | ) |
Flips this plane.
Definition at line 116 of file Plane.java.
References eu.mihosoft.vrl.v3d.Plane.dist, eu.mihosoft.vrl.v3d.Vector3d.negated(), and eu.mihosoft.vrl.v3d.Plane.normal.
Referenced by eu.mihosoft.vrl.v3d.Polygon.flip().
|
static |
Definition at line 240 of file Plane.java.
References eu.mihosoft.vrl.v3d.Plane.debugger.
|
static |
Definition at line 248 of file Plane.java.
References eu.mihosoft.vrl.v3d.Plane.useDebugger.
|
static |
Definition at line 244 of file Plane.java.
References eu.mihosoft.vrl.v3d.Plane.debugger.
|
static |
Definition at line 252 of file Plane.java.
References eu.mihosoft.vrl.v3d.Plane.useDebugger.
void eu.mihosoft.vrl.v3d.Plane.splitPolygon | ( | Polygon | polygon, |
List< Polygon > | coplanarFront, | ||
List< Polygon > | coplanarBack, | ||
List< Polygon > | front, | ||
List< Polygon > | back | ||
) |
Splits a Polygon by this plane if needed. After that it puts the polygons or the polygon fragments in the appropriate lists (
,
). Coplanar polygons go into either
,
depending on their orientation with respect to this plane. Polygons in front or back of this plane go into either
or
.
polygon | polygon to split |
coplanarFront | "coplanar front" polygons |
coplanarBack | "coplanar back" polygons |
front | front polygons |
back | back polgons |
Definition at line 135 of file Plane.java.
References eu.mihosoft.vrl.v3d.Vertex.clone(), eu.mihosoft.vrl.v3d.Plane.debugger, eu.mihosoft.vrl.v3d.Plane.dist, eu.mihosoft.vrl.v3d.Vector3d.dot(), eu.mihosoft.vrl.v3d.Plane.EPSILON, eu.mihosoft.vrl.v3d.Polygon.getStorage(), eu.mihosoft.vrl.v3d.Vertex.interpolate(), eu.mihosoft.vrl.v3d.Vector3d.minus(), eu.mihosoft.vrl.v3d.Plane.normal, eu.mihosoft.vrl.v3d.Polygon.plane, eu.mihosoft.vrl.v3d.Vertex.pos, eu.mihosoft.vrl.v3d.Plane.useDebugger, and eu.mihosoft.vrl.v3d.Polygon.vertices.
|
staticprivate |
Definition at line 47 of file Plane.java.
Referenced by eu.mihosoft.vrl.v3d.Plane.getDebugger(), eu.mihosoft.vrl.v3d.Plane.setDebugger(), and eu.mihosoft.vrl.v3d.Plane.splitPolygon().
double eu.mihosoft.vrl.v3d.Plane.dist |
Distance to origin.
Definition at line 78 of file Plane.java.
Referenced by eu.mihosoft.vrl.v3d.Plane.clone(), eu.mihosoft.vrl.v3d.Plane.flip(), eu.mihosoft.vrl.v3d.Transform.mirror(), eu.mihosoft.vrl.v3d.Plane.Plane(), eu.mihosoft.vrl.v3d.Plane.splitPolygon(), and eu.mihosoft.vrl.v3d.Polygon.transform().
|
static |
EPSILON is the tolerance used by splitPolygon(eu.mihosoft.vrl.v3d.Polygon, java.util.List, java.util.List, java.util.List, java.util.List) to decide if a point is on the plane. public static final double EPSILON = 0.00000001;
Definition at line 55 of file Plane.java.
Referenced by eu.mihosoft.vrl.v3d.ext.org.poly2tri.PolygonUtil.concaveToConvex(), eu.mihosoft.vrl.v3d.Edge.contains(), eu.mihosoft.vrl.v3d.Edge.getClosestPoint(), and eu.mihosoft.vrl.v3d.Plane.splitPolygon().
|
static |
Definition at line 57 of file Plane.java.
Referenced by eu.mihosoft.vrl.v3d.ext.org.poly2tri.PolygonUtil.pruneDuplicatePoints().
|
static |
Definition at line 56 of file Plane.java.
Referenced by eu.mihosoft.vrl.v3d.Edge.colinear(), eu.mihosoft.vrl.v3d.Edge.equals(), eu.mihosoft.vrl.v3d.Vector3d.equals(), eu.mihosoft.vrl.v3d.Vertex.equals(), and eu.mihosoft.vrl.v3d.Edge.isThisPointOneOfMine().
Vector3d eu.mihosoft.vrl.v3d.Plane.normal |
Normal vector.
Definition at line 74 of file Plane.java.
Referenced by eu.mihosoft.vrl.v3d.Plane.clone(), eu.mihosoft.vrl.v3d.Plane.flip(), eu.mihosoft.vrl.v3d.Polygon.fromPoints(), eu.mihosoft.vrl.v3d.Transform.mirror(), eu.mihosoft.vrl.v3d.Plane.Plane(), eu.mihosoft.vrl.v3d.Edge.searchPlaneGroups(), eu.mihosoft.vrl.v3d.Plane.splitPolygon(), eu.mihosoft.vrl.v3d.Edge.toPolygon(), eu.mihosoft.vrl.v3d.Polygon.toStlString(), eu.mihosoft.vrl.v3d.Polygon.transform(), eu.mihosoft.vrl.v3d.Polygon.translate(), and eu.mihosoft.vrl.v3d.Polygon.validateAndInit().
|
staticprivate |
Definition at line 48 of file Plane.java.
Referenced by eu.mihosoft.vrl.v3d.Plane.isUseDebugger(), eu.mihosoft.vrl.v3d.Plane.setUseDebugger(), and eu.mihosoft.vrl.v3d.Plane.splitPolygon().
|
static |
XY plane.
Definition at line 61 of file Plane.java.
|
static |
XZ plane.
Definition at line 65 of file Plane.java.
|
static |
YZ plane.
Definition at line 69 of file Plane.java.