Projectionpublic class HemisphereProjection extends java.lang.Object implements Projection
| Constructor | Description |
|---|---|
HemisphereProjection() |
Constructs a HemisphereProjection with default characteristics.
|
HemisphereProjection(boolean upNorth) |
Constructs a HemisphereProjection optionally
with north fixed pointing up.
|
| Modifier and Type | Method | Description |
|---|---|---|
SkyAspect |
createAspect(boolean reflect,
double[] r3,
double radiusRad,
Range[] ranges) |
Creates a SkyAspect from configuration information.
|
double[] |
cursorRotate(double[] rot0,
java.awt.geom.Point2D.Double pos0,
java.awt.geom.Point2D.Double pos1) |
Attempts to return a rotation matrix corresponding to moving the
cursor between two plane positions.
|
boolean |
equals(java.lang.Object o) |
|
SkyFov |
getFov(SkySurface surf) |
Returns the field of view represented by this aspect.
|
java.lang.String |
getProjectionDescription() |
Returns a short description of the projection.
|
java.lang.String |
getProjectionName() |
Returns the projection name.
|
java.awt.Shape |
getProjectionShape() |
Returns the shape which encloses all the plane positions to which
legal sky coordinates can be projected.
|
int |
hashCode() |
|
boolean |
isContinuous() |
Indicates whether this projection is known to be continous over
its whole range.
|
boolean |
project(double rx,
double ry,
double rz,
java.awt.geom.Point2D.Double pos) |
Transforms a sky position to a plane position.
|
double[] |
projRotate(double[] rot0,
java.awt.geom.Point2D.Double pos0,
java.awt.geom.Point2D.Double pos1) |
Attempts to return a rotation matrix that will transform
a sky position from one plane position to another.
|
boolean |
unproject(java.awt.geom.Point2D.Double ppos,
double[] r3) |
Transforms a plane position to a sky position.
|
boolean |
useRanges(boolean reflect,
double[] r3,
double radiusRad) |
Indicates whether ranges should be provided to generate a SkyAspect.
|
public HemisphereProjection()
public HemisphereProjection(boolean upNorth)
upNorth - whether north is fixed to align with the
screen Y directionpublic java.lang.String getProjectionName()
ProjectiongetProjectionName in interface Projectionpublic java.lang.String getProjectionDescription()
ProjectiongetProjectionDescription in interface Projectionpublic boolean isContinuous()
ProjectionisContinuous in interface Projectionpublic boolean project(double rx,
double ry,
double rz,
java.awt.geom.Point2D.Double pos)
Projectionproject in interface Projectionrx - normalised 3D X coordinatery - normalised 3D Y coordinaterz - normalised 3D Z coordinatepos - point object into which projected dimensionless X,Y
coordinates will be written on successpublic boolean unproject(java.awt.geom.Point2D.Double ppos,
double[] r3)
Projectionunproject in interface Projectionppos - contains dimensionless X,Y coordinates of plane positionr3 - 3-element array into which normalised X,Y,Z sky coordinates
will be written on successpublic java.awt.Shape getProjectionShape()
ProjectiongetProjectionShape in interface Projectionpublic double[] cursorRotate(double[] rot0,
java.awt.geom.Point2D.Double pos0,
java.awt.geom.Point2D.Double pos1)
ProjectionprojRotate,
for both positions on the sky, and provide some other intuitive
behaviour if one or both is out of the projection range.
Null may be returned if this projection does not support rotation.
cursorRotate in interface Projectionrot0 - initial rotation matrixpos0 - initial cursor positionpos1 - destination cursor positionpublic double[] projRotate(double[] rot0,
java.awt.geom.Point2D.Double pos0,
java.awt.geom.Point2D.Double pos1)
ProjectionConsider a sky point S, rotated by an initial rotation
matrix rotmat to S', which when projected by
this projection lands on the plane at pos0.
This method attempts to determine a rotation matrix
which when used instead of rotmat would
end up with the rotated and projected point at pos1.
Null may be returned if this projection does not support projection.
projRotate in interface Projectionrot0 - initial rotation matrixpos0 - initial projected positionpos1 - destination projected positionpublic boolean useRanges(boolean reflect,
double[] r3,
double radiusRad)
ProjectionuseRanges in interface Projectionreflect - whether requested aspect will be reflectedr3 - central position of field of view (may be null)radiusRad - radius of field of view (may be NaN)SurfaceFactory.readRanges(P, uk.ac.starlink.ttools.plot2.PlotLayer[], uk.ac.starlink.ttools.plot2.data.DataStore)public SkyAspect createAspect(boolean reflect, double[] r3, double radiusRad, Range[] ranges)
ProjectioncreateAspect in interface Projectionreflect - whether requested aspect will be reflectedr3 - central position of field of view (may be null)radiusRad - radius of field of view (may be NaN)ranges - definite ranges for normalised X,Y,Z coordinates
acquired from dataSurfaceFactory.createAspect(P, uk.ac.starlink.ttools.plot2.config.ConfigMap, uk.ac.starlink.ttools.plot.Range[])public SkyFov getFov(SkySurface surf)
ProjectiongetFov in interface Projectionsurf - sky surface, which must be set up using this projectionpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.ObjectCopyright © 2018 Central Laboratory of the Research Councils. All Rights Reserved.