Package | Description |
---|---|
pythagoras.f |
The Pythagoras geometry utility classes specialized on
float . |
Modifier and Type | Interface and Description |
---|---|
interface |
IPoint
Provides read-only access to a
Point . |
interface |
IVector
Provides read-only access to a
Vector . |
Modifier and Type | Class and Description |
---|---|
class |
AbstractPoint
Provides most of the implementation of
IPoint , obtaining only the location from the
derived class. |
class |
AbstractVector
Provides most of the implementation of
IVector , obtaining only x and y from the derived
class. |
class |
Point
Represents a point on a plane.
|
class |
Vector
Represents a vector in a plane.
|
Modifier and Type | Method and Description |
---|---|
void |
Rectangle.add(XY p)
Expands the bounds of this rectangle to contain the supplied point.
|
Point |
IPoint.add(XY other,
Point result)
Translates this point by the specified offset and stores the result in the object provided.
|
Point |
AbstractPoint.add(XY other,
Point result) |
boolean |
RectangularShape.contains(XY point) |
boolean |
Path.contains(XY p) |
boolean |
IShape.contains(XY point)
Returns true if this shape contains the supplied point.
|
boolean |
ICircle.contains(XY p)
Returns true if this circle contains the supplied point.
|
boolean |
Area.contains(XY p) |
boolean |
AbstractQuadCurve.contains(XY p) |
boolean |
AbstractLine.contains(XY point) |
boolean |
AbstractCubicCurve.contains(XY p) |
boolean |
AbstractCircle.contains(XY p) |
float |
IPoint.direction(XY other)
Returns the angle (in radians) of the vector starting at this point and ending at the
supplied other point.
|
float |
AbstractPoint.direction(XY other) |
float |
IPoint.distance(XY p)
Returns the Euclidian distance between this point and the supplied point.
|
float |
AbstractPoint.distance(XY p) |
float |
IPoint.distanceSq(XY p)
Returns the squared Euclidian distance between this point and the supplied point.
|
float |
AbstractPoint.distanceSq(XY p) |
static Vector |
Vectors.from(XY from,
XY to)
Creates a vector from
from to to . |
int |
IRectangle.outcode(XY point)
Returns a set of flags indicating where the supplied point lies in relation to the bounds of
this rectangle.
|
int |
AbstractRectangle.outcode(XY p) |
float |
ILine.pointLineDist(XY p)
Returns the distance from the supplied point to the line defined by this line segment.
|
float |
AbstractLine.pointLineDist(XY p) |
float |
ILine.pointLineDistSq(XY p)
Returns the square of the distance from the supplied point to the line defined by this line
segment.
|
float |
AbstractLine.pointLineDistSq(XY p) |
float |
ILine.pointSegDist(XY p)
Returns the distance from the supplied point this line segment.
|
float |
AbstractLine.pointSegDist(XY p) |
float |
ILine.pointSegDistSq(XY p)
Returns the square of the distance from the supplied point this line segment.
|
float |
AbstractLine.pointSegDistSq(XY p) |
int |
ILine.relativeCCW(XY p)
Returns an indicator of where the specified point lies with respect to this line segment.
|
int |
AbstractLine.relativeCCW(XY p) |
Vector |
Vector.set(XY other)
Copies the elements of another vector.
|
Point |
Point.set(XY p)
Sets the coordinates of this point to be equal to those of the supplied point.
|
void |
Arc.setAngles(XY p1,
XY p2)
Sets the starting angle and angular extent of this arc using two sets of coordinates.
|
void |
Arc.setAngleStart(XY point)
Sets the starting angle of this arc to the angle defined by the supplied point relative to
the center of this arc.
|
void |
Arc.setArc(XY point,
IDimension size,
float start,
float extent,
int type)
Sets the location, size, angular extents, and closure type of this arc to the specified
values.
|
void |
Arc.setArcByTangent(XY p1,
XY p2,
XY p3,
float radius)
Sets the location, size, angular extents, and closure type of this arc based on the
specified values.
|
void |
QuadCurve.setCurve(XY[] points,
int offset)
Configures the start, control, and end points for this curve, using the values at the
specified offset in the
points array. |
void |
CubicCurve.setCurve(XY[] points,
int offset)
Configures the start, control and end points for this curve, using the values at the
specified offset in the
points array. |
void |
QuadCurve.setCurve(XY p1,
XY cp,
XY p2)
Configures the start, control, and end points for this curve.
|
void |
CubicCurve.setCurve(XY p1,
XY cp1,
XY cp2,
XY p2)
Configures the start, control and end points for this curve.
|
void |
RectangularShape.setFrame(XY loc,
IDimension size)
Sets the location and size of the framing rectangle of this shape to the supplied values.
|
void |
RectangularShape.setFrameFromCenter(XY center,
XY corner)
Sets the location and size of the framing rectangle of this shape based on the supplied
center and corner points.
|
void |
RectangularShape.setFrameFromDiagonal(XY p1,
XY p2)
Sets the location and size of the framing rectangle of this shape based on the supplied
diagonal line.
|
void |
Line.setLine(XY p1,
XY p2)
Sets the start and end of this line to the specified points.
|
void |
Rectangle.setLocation(XY p)
Sets the upper-left corner of this rectangle to the supplied point.
|
Point |
IPoint.subtract(XY other,
Point result)
Subtracts the supplied point from
this and stores the result in result . |
Point |
AbstractPoint.subtract(XY other,
Point result) |
Constructor and Description |
---|
Circle(XY p,
float radius)
Constructs a circle with the specified properties
|
Line(XY p1,
XY p2)
Creates a line from p1 to p2.
|
Point(XY p)
Constructs a point with coordinates equal to the supplied point.
|
Rectangle(XY p)
Constructs a rectangle with the supplied upper-left corner and dimensions (0,0).
|
Rectangle(XY p,
IDimension d)
Constructs a rectangle with upper-left corner at the supplied point and with the supplied
dimensions.
|
Vector(XY other)
Creates a vector equal to
other . |
Copyright © 2017. All rights reserved.