|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectvooga.physicsEngine.geometry.shapes.Circle
public class Circle
Shape class that represents a circle.
Constructor Summary | |
---|---|
Circle(double radius)
Creates a circle |
Method Summary | |
---|---|
java.awt.image.BufferedImage |
createBufferedImage(double angularPosition)
Creates a BufferedImage representing the given
Shape . |
BoundingBox |
getBoundingBox()
Returns the bounding box of a shape. |
Vector2f |
getCentroid()
|
double |
getR2IntegralEstimate()
Obtain an estimate of the integral of R^2 over the whole shape, where R is the distance between each point and the centroid. |
double |
getRadius()
Return the radius of the circle |
Vector2f |
getSmallestCorner()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Circle(double radius)
radius
- The radius of the circleMethod Detail |
---|
public BoundingBox getBoundingBox()
Shape
getBoundingBox
in interface Shape
public double getRadius()
public java.awt.image.BufferedImage createBufferedImage(double angularPosition)
Shape
BufferedImage
representing the given
Shape
. This image will have the same bounding box as the
given shape. The image will have black outline and white interior. This
is mostly for simple games and internal testing.
createBufferedImage
in interface Shape
public double getR2IntegralEstimate()
Shape
getR2IntegralEstimate
in interface Shape
public Vector2f getCentroid()
getCentroid
in interface Shape
public Vector2f getSmallestCorner()
getSmallestCorner
in interface Shape
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |