Package nl.colorize.multimedialib.math
Class Circle
- java.lang.Object
-
- nl.colorize.multimedialib.math.Circle
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description floatcalculateDistance(Circle other)Returns the distance between the center of this circle and the center of the specified other circle.floatcalculateDistance(Point2D p)Returns the distance between the center of this circle and the specified point.booleancontains(Point2D p)Point2DgetCenter()floatgetCenterX()floatgetCenterY()floatgetDiameter()floatgetRadius()booleanintersects(Circle other)
-
-
-
Constructor Detail
-
Circle
public Circle(Point2D center, float radius)
-
Circle
public Circle(float x, float y, float radius)
-
-
Method Detail
-
getCenter
public Point2D getCenter()
-
getCenterX
public float getCenterX()
-
getCenterY
public float getCenterY()
-
getRadius
public float getRadius()
-
getDiameter
public float getDiameter()
-
intersects
public boolean intersects(Circle other)
-
calculateDistance
public float calculateDistance(Point2D p)
Returns the distance between the center of this circle and the specified point.
-
calculateDistance
public float calculateDistance(Circle other)
Returns the distance between the center of this circle and the center of the specified other circle.
-
-