Class SphericalLayout
java.lang.Object
repast.simphony.visualization.visualization3D.layout.SphericalLayout
- All Implemented Interfaces:
Layout
z between -R and R, phi between 0 and 2 pi, each with a uniform distribution
To find the latitude (theta) of this point, note that z=Rsin(theta), so
theta=sin-1(z/R); its longitude is (surprise!) phi. In rectilinear
coordinates, x=Rcos(theta)cos(phi), y=Rcos(theta)sin(phi), z=Rsin(theta)=
(surprise!) z.
- Version:
- $Revision: 1.1 $ $Date: 2006/01/06 22:35:19 $
- Author:
- Nick Collier
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets a bounding box that describes the extent of this layout in location coordinates.Gets the layout properties for this layout.float[]Gets the location of the specified object as determined by this layout.getName()Gets the name of the layoutvoidSets the layout properties for this layout.voidsetProjection(Projection projection) Sets the projection associated with this Layout.voidupdate()Updates this layout.
-
Field Details
-
location
protected float[] location -
radius
protected float radius
-
-
Constructor Details
-
SphericalLayout
public SphericalLayout()
-
-
Method Details
-
getLocation
Description copied from interface:LayoutGets the location of the specified object as determined by this layout.- Specified by:
getLocationin interfaceLayout- Parameters:
o- the object whose location we want.- Returns:
- the location of the object.
-
setProjection
Description copied from interface:LayoutSets the projection associated with this Layout.- Specified by:
setProjectionin interfaceLayout- Parameters:
projection- the associated projection.
-
setLayoutProperties
Sets the layout properties for this layout.- Specified by:
setLayoutPropertiesin interfaceLayout- Parameters:
props- the layout properties
-
getLayoutProperties
Gets the layout properties for this layout.- Specified by:
getLayoutPropertiesin interfaceLayout- Returns:
- the layout properties for this layout.
-
update
public void update()Description copied from interface:LayoutUpdates this layout. -
getName
Description copied from interface:LayoutGets the name of the layout -
getBoundingBox
Description copied from interface:LayoutGets a bounding box that describes the extent of this layout in location coordinates.- Specified by:
getBoundingBoxin interfaceLayout- Returns:
- a bounding box that describes the extent of this layout in location coordinates, or a 0 size box if the extent is unknown.
-