public class InvertedRay2D extends AbstractLine2D implements Cloneable
x(t) = x0+t*dx
y(t) = y0+t*dy
t comprised between -INFINITY and 0.
This is complementary class to Ray2D.dx, dy, x0, y0| Constructor and Description |
|---|
InvertedRay2D()
Empty constructor for Ray2D.
|
InvertedRay2D(double x,
double y,
double angle)
Creates a new Ray2D, originating from point
(x, y)<\code>, and going
in the direction specified by |
InvertedRay2D(double x1,
double y1,
double dx,
double dy)
Creates a new Ray2D, originating from point
(x1,y1)<\code>, and going
in the direction defined by vector |
InvertedRay2D(LinearShape2D line)
Define a new Ray, with same characteristics as given object.
|
InvertedRay2D(Point2D point,
double angle)
Creates a new Ray2D, originating from point
point<\code>, and going
in the direction specified by |
InvertedRay2D(Point2D point,
double dx,
double dy)
Creates a new Ray2D, originating from point
point<\code>, and going
in the direction defined by vector |
InvertedRay2D(Point2D point1,
Point2D point2)
Creates a new Ray2D, originating from
point1<\code>, and going in the
direction of |
InvertedRay2D(Point2D point,
Vector2D vector)
Creates a new Ray2D, originating from point
point<\code>, and going
in the direction specified by |
| Modifier and Type | Method and Description |
|---|---|
GeneralPath |
appendPath(GeneralPath path)
Throws an infiniteShapeException
|
InvertedRay2D |
clone()
Ensures public declaration of clone(), and ensures valid return type.
|
boolean |
contains(double x,
double y)
Checks if the shape contains the planar point defined by (x,y).
|
static InvertedRay2D |
create(Point2D target,
Vector2D direction)
Static factory for creating a new inverted ray with given direction
to target.
|
boolean |
equals(Object obj) |
Box2D |
getBoundingBox()
Returns the bounding box of the shape.
|
GeneralPath |
getGeneralPath()
Throws an infiniteShapeException
|
InvertedRay2D |
getParallel(double d)
Creates a new curve, formed by the points with parameterization:
p(t) = c(t) + d*n(t)/|n(t)|, with p(t) being a point of
the original curve, n(t) the normal of the curve, and |n| being the
norm of n.In the case of a continuous curve formed by several smooth circulinear elements, the parallels of contiguous elements are joined by a circle arc. |
Point2D |
getPoint(double t)
Gets the point from a parametric representation of the curve.
|
Ray2D |
getReverseCurve()
Returns the curve with same trace on the plane with parametrization in
reverse order.
|
double |
getT0()
Get value of parameter t for the first point of the curve.
|
double |
getT1()
Get value of parameter t for the last point of the curve.
|
boolean |
isBounded()
Always returns false, because n inverted ray is not bounded.
|
void |
setRay(double x0,
double y0,
double dx,
double dy)
Deprecated.
lines will become immutable in a future release
|
void |
setRay(Point2D p1,
Point2D p2)
Deprecated.
lines will become immutable in a future release
|
void |
setRay(Point2D point,
Vector2D vect)
Deprecated.
lines will become immutable in a future release
|
String |
toString() |
InvertedRay2D |
transform(AffineTransform2D trans)
Transforms the curve by an affine transform.
|
clip, contains, getBuffer, getCartesianEquation, getContinuousCurves, getCurvature, getDistance, getDistance, getHorizontalAngle, getIntersection, getIntersection, getIntersections, getLength, getLength, getOrigin, getParallel, getParametric, getPerpendicular, getPolarCoefficients, getPosition, getPosition, getPositionOnLine, getPositionOnLine, getProjectedPoint, getProjectedPoint, getSignedDistance, getSignedDistance, getSignedPolarCoefficients, getSmoothPieces, getSubCurve, getSupportingLine, getSymmetric, getSymmetric, getTangent, getVector, getWindingAngle, isClosed, isColinear, isColinear, isEmpty, isInside, isParallel, isParallel, project, supportContains, transformgetLeftTangent, getRightTangent, getSingularPoints, isSingulardraw, getAsAWTShape, getAsPolyline, getFirstPoint, getLastPoint, wrapCurvefinalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetAsPolyline, getLeftTangent, getRightTangentdraw, getAsAWTShape, getFirstPoint, getLastPoint, getSingularPoints, isSingularpublic InvertedRay2D()
public InvertedRay2D(Point2D point1, Point2D point2)
point1<\code>, and going in the
direction of point2<\code>.public InvertedRay2D(double x1,
double y1,
double dx,
double dy)
(x1,y1)<\code>, and going
in the direction defined by vector (dx, dy)<\code>.public InvertedRay2D(Point2D point, double dx, double dy)
point<\code>, and going
in the direction defined by vector (dx,dy)<\code>.public InvertedRay2D(Point2D point, Vector2D vector)
point<\code>, and going
in the direction specified by vector<\code>.public InvertedRay2D(Point2D point, double angle)
point<\code>, and going
in the direction specified by angle<\code> (in radians).public InvertedRay2D(double x,
double y,
double angle)
(x, y)<\code>, and going
in the direction specified by angle<\code> (in radians).public InvertedRay2D(LinearShape2D line)
public static final InvertedRay2D create(Point2D target, Vector2D direction)
@Deprecated public void setRay(double x0, double y0, double dx, double dy)
@Deprecated public void setRay(Point2D p1, Point2D p2)
@Deprecated public void setRay(Point2D point, Vector2D vect)
public InvertedRay2D getParallel(double d)
CirculinearCurve2D p(t) = c(t) + d*n(t)/|n(t)|, with p(t) being a point of
the original curve, n(t) the normal of the curve, and |n| being the
norm of n.getParallel in interface CirculinearContinuousCurve2DgetParallel in interface CirculinearCurve2DgetParallel in interface CirculinearElement2DgetParallel in interface ContinuousCirculinearCurve2Dd - the distance between the original curve and he parallel curve.public GeneralPath appendPath(GeneralPath path)
appendPath in interface ContinuousCurve2Dpath - a path to modifypublic GeneralPath getGeneralPath()
public Point2D getPoint(double t)
Curve2Dpublic double getT0()
Curve2Dpublic double getT1()
Curve2Dpublic Ray2D getReverseCurve()
Curve2DgetReverseCurve in interface CirculinearContinuousCurve2DgetReverseCurve in interface CirculinearCurve2DgetReverseCurve in interface CirculinearElement2DgetReverseCurve in interface ContinuousCirculinearCurve2DgetReverseCurve in interface ContinuousCurve2DgetReverseCurve in interface Curve2DgetReverseCurve in interface SmoothCurve2DgetReverseCurve in interface ContinuousOrientedCurve2DgetReverseCurve in interface OrientedCurve2DgetReverseCurve in interface SmoothOrientedCurve2Dpublic boolean isBounded()
public boolean contains(double x,
double y)
Shape2Dpublic Box2D getBoundingBox()
Shape2DgetBoundingBox in interface Shape2Dpublic InvertedRay2D transform(AffineTransform2D trans)
Curve2Dtransform in interface ContinuousCurve2Dtransform in interface Curve2Dtransform in interface SmoothCurve2Dtransform in interface ContinuousOrientedCurve2Dtransform in interface OrientedCurve2Dtransform in interface SmoothOrientedCurve2Dtransform in interface LinearShape2Dtransform in interface Shape2Dtransform in class AbstractLine2Dtrans - an affine transformpublic InvertedRay2D clone()
AbstractLine2Dclone in interface Curve2Dclone in class AbstractLine2DCopyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.