|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.threerings.tudey.space.SimpleSpaceElement
com.threerings.tudey.shape.ShapeElement
public class ShapeElement
A shape element.
| Constructor Summary | |
|---|---|
ShapeElement(Shape localShape)
Creates a new shape element. |
|
ShapeElement(ShapeConfig config)
Creates a new shape element. |
|
| Method Summary | |
|---|---|
boolean |
getIntersection(Ray2D ray,
Vector2f result)
Finds the intersection of a ray with this element and places it in the supplied vector (if it exists). |
Shape |
getLocalShape()
Returns a reference to the element's local shape. |
void |
getNearestPoint(Vector2f point,
Vector2f result)
Finds the nearest point of this element to the supplied point and places it in the supplied vector. |
Shape |
getWorldShape()
Returns a reference to the element's transformed shape. |
boolean |
intersects(Capsule capsule)
Determines whether this element intersects the supplied capsule. |
boolean |
intersects(Circle circle)
Determines whether this element intersects the supplied circle. |
boolean |
intersects(Compound compound)
Determines whether this element intersects the supplied compound. |
boolean |
intersects(Point point)
Determines whether this element intersects the supplied point. |
boolean |
intersects(Polygon polygon)
Determines whether this element intersects the supplied polygon. |
boolean |
intersects(Segment segment)
Determines whether this element intersects the supplied segment. |
void |
setConfig(ShapeConfig config)
Sets the configuration of the shape. |
void |
setLocalShape(Shape shape)
Sets the local shape reference. |
void |
updateBounds()
Updates the bounds of the element. |
| Methods inherited from class com.threerings.tudey.space.SimpleSpaceElement |
|---|
getBounds, getSpace, getTransform, getUserObject, intersects, setTransform, setUserObject, updateLastVisit, wasAdded, willBeRemoved |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ShapeElement(ShapeConfig config)
public ShapeElement(Shape localShape)
| Method Detail |
|---|
public void setConfig(ShapeConfig config)
public void setLocalShape(Shape shape)
public Shape getLocalShape()
public Shape getWorldShape()
public void updateBounds()
SimpleSpaceElement
updateBounds in class SimpleSpaceElement
public boolean getIntersection(Ray2D ray,
Vector2f result)
SpaceElement
getIntersection in interface SpaceElementgetIntersection in class SimpleSpaceElement
public void getNearestPoint(Vector2f point,
Vector2f result)
SpaceElement
getNearestPoint in interface SpaceElementgetNearestPoint in class SimpleSpaceElementpublic boolean intersects(Point point)
SpaceElement
intersects in interface SpaceElementintersects in class SimpleSpaceElementpublic boolean intersects(Segment segment)
SpaceElement
intersects in interface SpaceElementintersects in class SimpleSpaceElementpublic boolean intersects(Circle circle)
SpaceElement
intersects in interface SpaceElementintersects in class SimpleSpaceElementpublic boolean intersects(Capsule capsule)
SpaceElement
intersects in interface SpaceElementintersects in class SimpleSpaceElementpublic boolean intersects(Polygon polygon)
SpaceElement
intersects in interface SpaceElementintersects in class SimpleSpaceElementpublic boolean intersects(Compound compound)
SpaceElement
intersects in interface SpaceElementintersects in class SimpleSpaceElement
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||