Class SelectableSphere
- java.lang.Object
-
- org.jzy3d.plot3d.primitives.Drawable
-
- org.jzy3d.plot3d.primitives.Wireframeable
-
- org.jzy3d.plot3d.primitives.Sphere
-
- org.jzy3d.plot3d.primitives.selectable.SelectableSphere
-
- All Implemented Interfaces:
ISingleColorable,IGLRenderer,ISortableDraw,Selectable
public class SelectableSphere extends Sphere implements Selectable
-
-
Field Summary
Fields Modifier and Type Field Description protected List<Coord3d>anchorsprotected booleanisHighlightedprotected intPRECISIONprotected List<Coord3d>projection-
Fields inherited from class org.jzy3d.plot3d.primitives.Sphere
color, position, radius, slices, stacks
-
Fields inherited from class org.jzy3d.plot3d.primitives.Wireframeable
faceDisplayed, polygonOffsetFactor, polygonOffsetFillEnable, polygonOffsetUnit, polygonWireframeDepthTrick, wireframeColor, wireframeColorFromPolygonPoints, wireframeDisplayed, wireframeWidth
-
Fields inherited from class org.jzy3d.plot3d.primitives.Drawable
bbox, boundingBoxColor, boundingBoxDisplayed, displayed, hasListeners, legend, legendDisplayed, listeners, spaceTransformer, transform, transformBefore
-
-
Constructor Summary
Constructors Constructor Description SelectableSphere()SelectableSphere(Coord3d position, float radius, int slicing, Color color)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidbuildAnchors()protected List<Coord3d>buildAnchors(Coord3d position, float radius)voiddraw(IPainter painter)Call OpenGL2 routines for rendering the object.Polygon2dgetHull2d()List<Coord3d>getLastProjection()List<Coord3d>getProjection()booleanisHighlighted()voidproject(IPainter painter, Camera cam)voidresetHighlighting()voidsetHighlighted(boolean value)voidsetPosition(Coord3d position)Set the position of the Sphere and the dimensions of its boundingbox.voidsetVolume(float radius)Set the radius of the sphere, and the dimensions of its boundingbox.-
Methods inherited from class org.jzy3d.plot3d.primitives.Sphere
applyGeometryTransform, doDrawSphere, getColor, getPosition, setColor, setData, setSlicing, toString, updateBounds
-
Methods inherited from class org.jzy3d.plot3d.primitives.Wireframeable
applyDepthRangeForOverlying, applyDepthRangeForUnderlying, getFaceDisplayed, getPolygonOffsetFactor, getPolygonOffsetUnit, getWireframeColor, getWireframeDisplayed, getWireframeWidth, isPolygonOffsetFillEnable, isPolygonWireframeDepthTrick, isWireframeColorFromPolygonPoints, polygonOffseFillEnable, polygonOffsetFillDisable, polygonOffsetLineDisable, polygonOffsetLineEnable, setFaceDisplayed, setPolygonOffsetFactor, setPolygonOffsetFillEnable, setPolygonOffsetUnit, setPolygonWireframeDepthTrick, setWireframeColor, setWireframeColorFromPolygonPoints, setWireframeDisplayed, setWireframeWidth
-
Methods inherited from class org.jzy3d.plot3d.primitives.Drawable
addDrawableListener, dispose, doDrawBoundsIfDisplayed, doTransform, fireDrawableChanged, fireDrawableChanged, getBarycentre, getBoundingBoxColor, getBounds, getDistance, getLegend, getLongestDistance, getShortestDistance, getSpaceTransformer, getTransform, getTransformBefore, hasLegend, isBoundingBoxDisplayed, isDisplayed, isLegendDisplayed, negative, removeDrawableListener, setBoundingBoxColor, setBoundingBoxDisplayed, setDisplayed, setLegend, setLegendDisplayed, setSpaceTransformer, setTransform, setTransformBefore, toString
-
-
-
-
Method Detail
-
draw
public void draw(IPainter painter)
Description copied from class:DrawableCall OpenGL2 routines for rendering the object.- Specified by:
drawin interfaceIGLRenderer- Overrides:
drawin classSphere
-
project
public void project(IPainter painter, Camera cam)
- Specified by:
projectin interfaceSelectable
-
setPosition
public void setPosition(Coord3d position)
Description copied from class:SphereSet the position of the Sphere and the dimensions of its boundingbox. Note that this position will be use to translate the object before drawing it (meaning a glTranslate(position) is performed right after the Translate.execute).- Overrides:
setPositionin classSphere
-
setVolume
public void setVolume(float radius)
Description copied from class:SphereSet the radius of the sphere, and the dimensions of its boundingbox.
-
buildAnchors
protected void buildAnchors()
-
getHull2d
public Polygon2d getHull2d()
- Specified by:
getHull2din interfaceSelectable
-
getLastProjection
public List<Coord3d> getLastProjection()
- Specified by:
getLastProjectionin interfaceSelectable
-
setHighlighted
public void setHighlighted(boolean value)
-
isHighlighted
public boolean isHighlighted()
-
resetHighlighting
public void resetHighlighting()
-
-