Uses of Class
org.djutils.draw.point.Point2d
Package
Description
The draw package contains the generic classes for device-independent drawing.
Methods for Bounds of an object to quickly determine whether an object needs to be drawn or not.
The d1 package provides an interface and different implementations for lines.
The d0 package provides a set of interfaces and implementations of Points.
-
Uses of Point2d in org.djutils.draw
Modifier and TypeMethodDescriptionApply the stored transform on the provided point and return a point with the transformed coordinate.Modifier and TypeMethodDescriptionApply the stored transform on the points generated by the provided pointIterator.Modifier and TypeMethodDescriptionApply the stored transform on the provided point and return a point with the transformed coordinate.Translate coordinates by a the x and y values contained in a Point2d. -
Uses of Point2d in org.djutils.draw.bounds
Modifier and TypeMethodDescriptionBounds2d.getPoints()
Bounds2d.pointsOf
(Collection<Drawable2d> drawableCollection) Return an iterator that will return all points of one or more Drawable2d objects.Bounds2d.pointsOf
(Drawable2d... drawable2d) Return an iterator that will return all points of one or more Drawable objects.Modifier and TypeMethodDescriptionboolean
boolean
ModifierConstructorDescriptionConstruct a Bounds2d from an array of Point2d, finding the lowest and highest x and y coordinates. -
Uses of Point2d in org.djutils.draw.line
Modifier and TypeClassDescriptionclass
Ray2d is a half-line; it has one end point with finite coordinates; the other end point is infinitely far away.Modifier and TypeMethodDescriptionPolyLine2d.closestPointOnPolyLine
(Point2d point) Ray2d.closestPointOnRay
(Point2d point) LineSegment2d.closestPointOnSegment
(Point2d point) final Point2d
PolyLine2d.get
(int i) LineSegment2d.getEndPoint()
LineSegment2d.getStartPoint()
LineSegment2d.projectOrthogonal
(Point2d point) PolyLine2d.projectOrthogonal
(Point2d point) Ray2d.projectOrthogonal
(Point2d point) LineSegment2d.projectOrthogonalExtended
(Point2d point) PolyLine2d.projectOrthogonalExtended
(Point2d point) Ray2d.projectOrthogonalExtended
(Point2d point) Modifier and TypeMethodDescriptionPolyLine2d.cleanPoints
(boolean filter, Iterator<Point2d> iterator) Return an iterator that optionally skips identical successive points.LineSegment2d.getPoints()
PolyLine2d.getPoints()
PolyLine2d.iteratorToList
(Iterator<Point2d> iterator) Build a list from the Point2d objects that an iterator provides.Modifier and TypeMethodDescriptionstatic PolyLine2d
Approximate a Bézier curve of degree n with a specified precision.static PolyLine2d
Approximate a Bézier curve of degree n.static PolyLine2d
Approximate a Bézier curve of degree n usingDEFAULT_BEZIER_SIZE
points.PolyLine2d.closestPointOnPolyLine
(Point2d point) Ray2d.closestPointOnRay
(Point2d point) LineSegment2d.closestPointOnSegment
(Point2d point) boolean
Determine if a point is inside this Polygon.static PolyLine2d
Approximate a cubic Bézier curve from start to end with two control points with a specified precision.static PolyLine2d
Approximate a cubic Bézier curve from start to end with two control points.protected static double[]
Make an array of double an fill it with the appropriate coordinate of points.LineSegment2d.projectOrthogonal
(Point2d point) PolyLine2d.projectOrthogonal
(Point2d point) Ray2d.projectOrthogonal
(Point2d point) LineSegment2d.projectOrthogonalExtended
(Point2d point) PolyLine2d.projectOrthogonalExtended
(Point2d point) Ray2d.projectOrthogonalExtended
(Point2d point) double
LineSegment2d.projectOrthogonalFractional
(Point2d point) final double
PolyLine2d.projectOrthogonalFractional
(Point2d point) double
Ray2d.projectOrthogonalFractional
(Point2d point) double
LineSegment2d.projectOrthogonalFractionalExtended
(Point2d point) double
PolyLine2d.projectOrthogonalFractionalExtended
(Point2d point) double
Ray2d.projectOrthogonalFractionalExtended
(Point2d point) Modifier and TypeMethodDescriptionPolyLine2d.cleanPoints
(boolean filter, Iterator<Point2d> iterator) Return an iterator that optionally skips identical successive points.static Polygon2d
ConvexHull.convexHull
(Iterator<Point2d> iterator) Compute the convex hull of a collection of Point2d objects.static Polygon2d
ConvexHull.convexHull
(List<Point2d> list) Compute the convex hull of a list of Point2d objects.static Polygon2d
ConvexHull.convexHullAlshamrani
(List<Point2d> list) Implementation of the convex hull algorithm by Reham Alshamrani c.s.; see A Preprocessing Technique for Fast Convex Hull Computation.static Polygon2d
ConvexHull.convexHullMonotone
(List<Point2d> list) Implementation of Andrew's Monotone Chain convex hull algorithm.PolyLine2d.instantiate
(List<Point2d> pointList) PolyLine2d.iteratorToList
(Iterator<Point2d> iterator) Build a list from the Point2d objects that an iterator provides.protected static double[]
Make an array of double an fill it with the appropriate coordinate of points.ModifierConstructorDescriptionLineSegment2d
(double startX, double startY, Point2d end) Construct a new LineSegment2d from two coordinates and a Point2d.LineSegment2d
(Point2d start, double endX, double endY) Construct a new LineSegment2d from a Point2d and two coordinates.LineSegment2d
(Point2d start, Point2d end) Construct a new LineSegment2d from two Point2d objects.Create a new Polygon2d, optionally filtering out repeating successive points.Construct a new Polygon2d.Construct a new Polygon2d.PolyLine2d
(boolean filterDuplicates, Point2d... points) Create a new PolyLine2d, optionally filtering out repeating successive points.PolyLine2d
(Point2d[] points) Construct a new PolyLine2d from an array of Point2d.PolyLine2d
(Point2d p, double heading) Construct a degenerate PolyLine2d (consisting of only one point).PolyLine2d
(Point2d point1, Point2d point2, Point2d... otherPoints) Construct a new PolyLine2d from two or more Point2d arguments.Construct a new Ray2d.Construct a new Ray2d from a Point2d and a direction.Construct a new Ray2d.Construct a new Ray2d.ModifierConstructorDescriptionCreate a new Polygon2d, optionally filtering out repeating successive points.Construct a new Polygon2d from an iterator that yields Point2d.Construct a new Polygon2d from a list of Point2d objects.PolyLine2d
(boolean filterDuplicates, List<Point2d> pointList) Create a new PolyLine2d, optionally filtering out repeating successive points.PolyLine2d
(Iterator<Point2d> iterator) Construct a new PolyLine2d from an iterator that yields Point2d objects.PolyLine2d
(List<Point2d> pointList) Construct a new PolyLine2d from a List<Point2d>. -
Uses of Point2d in org.djutils.draw.point
Modifier and TypeMethodDescriptionPoint2d.abs()
final Point2d
Point2d.closestPointOnLine
(double p1X, double p1Y, double p2X, double p2Y) Project a point on a line.Point2d.closestPointOnLine
(double p1X, double p1Y, double p2X, double p2Y, Boolean lowLimitHandling, Boolean highLimitHandling) Compute the closest point on a line with optional limiting of the result on either end.Point2d.closestPointOnLine
(Point2d linePoint1, Point2d linePoint2) final Point2d
Point2d.closestPointOnSegment
(double p1X, double p1Y, double p2X, double p2Y) Project a point on a line segment.Point2d.closestPointOnSegment
(Point2d segmentPoint1, Point2d segmentPoint2) Point2d.interpolate
(Point2d otherPoint, double fraction) static Point2d
Point2d.intersectionOfLines
(double line1P1X, double line1P1Y, double line1P2X, double line1P2Y, boolean lowLimitLine1, boolean highLimitLine1, double line2P1X, double line2P1Y, double line2P2X, double line2P2Y, boolean lowLimitLine2, boolean highLimitLine2) Compute the 2D intersection of two lines.static Point2d
Point2d.intersectionOfLines
(double l1P1X, double l1P1Y, double l1P2X, double l1P2Y, double l2P1X, double l2P1Y, double l2P2X, double l2P2Y) Compute the 2D intersection of two lines.static Point2d
Point2d.intersectionOfLines
(Point2d line1P1, Point2d line1P2, Point2d line2P1, Point2d line2P2) Compute the 2D intersection of two lines.static Point2d
Point2d.intersectionOfLineSegments
(double line1P1X, double line1P1Y, double line1P2X, double line1P2Y, double line2P1X, double line2P1Y, double line2P2X, double line2P2Y) Compute the 2D intersection of two line segments.static Point2d
Point2d.intersectionOfLineSegments
(LineSegment2d segment1, LineSegment2d segment2) Compute the 2D intersection of two line segments.static Point2d
Point2d.intersectionOfLineSegments
(Point2d line1P1, Point2d line1P2, Point2d line2P1, Point2d line2P2) Compute the 2D intersection of two line segments.Point2d.neg()
Point2d.normalize()
Point3d.project()
Point2d.scale
(double factor) Point2d.translate
(double dx, double dy) Return a new Point2d with a translation by the provided dx and dy.Modifier and TypeMethodDescriptionPoint2d.circleIntersections
(Point2d center1, double radius1, Point2d center2, double radius2) Return the zero, one or two intersections between two circles.Point2d.getPoints()
Modifier and TypeMethodDescriptionPoint2d.circleIntersections
(Point2d center1, double radius1, Point2d center2, double radius2) Return the zero, one or two intersections between two circles.Point2d.closestPointOnLine
(Point2d linePoint1, Point2d linePoint2) Point2d.closestPointOnSegment
(Point2d segmentPoint1, Point2d segmentPoint2) double
Point2d.directionTo
(Point2d otherPoint) Return the direction to another Point2d.double
double
Point2d.distanceSquared
(Point2d otherPoint) boolean
Point2d.epsilonEquals
(Point2d otherPoint, double epsilon) Point2d.interpolate
(Point2d otherPoint, double fraction) static Point2d
Point2d.intersectionOfLines
(Point2d line1P1, Point2d line1P2, Point2d line2P1, Point2d line2P2) Compute the 2D intersection of two lines.static Point2d
Point2d.intersectionOfLineSegments
(Point2d line1P1, Point2d line1P2, Point2d line2P1, Point2d line2P2) Compute the 2D intersection of two line segments.ModifierConstructorDescriptionDirectedPoint2d
(Point2d point, double dirZ) Construct a new DirectedPoint2d from a Point2d and a direction.DirectedPoint2d
(Point2d point, double throughX, double throughY) Construct a new DirectedPoint2d from a Point2d and the coordinates of a point that the direction goes through.Create a new Point3d from x, y stored in a java.awt.geom.Point2D and double z.