public class SinProjection extends SkyviewProjection
INSTANCE
.Modifier and Type | Field and Description |
---|---|
static SinProjection |
INSTANCE
Singleton instance.
|
Modifier and Type | Method and Description |
---|---|
SkyAspect |
createAspect(boolean reflect,
double[] r3,
double radiusRad,
Range[] vxyzRanges)
Creates a SkyAspect from configuration information.
|
double[] |
cursorRotate(double[] rot0,
Point2D.Double pos0,
Point2D.Double pos1)
Attempts to return a rotation matrix corresponding to moving the
cursor between two plane positions.
|
SkyFov |
getFov(SkySurface surf)
Returns the field of view represented by this aspect.
|
boolean |
isContinuous()
Indicates whether this projection is known to be continous over
its whole range.
|
boolean |
isContinuousLine(double[] r3a,
double[] r3b)
Indicates whether a line between the two given sky positions
is (believed to be) continuous.
|
boolean |
project(double rx,
double ry,
double rz,
Point2D.Double pos)
Overridden for slight efficiency gain.
|
double[] |
projRotate(double[] rot0,
Point2D.Double pos0,
Point2D.Double pos1)
Attempts to return a rotation matrix that will transform
a sky position from one plane position to another.
|
boolean |
useRanges(boolean reflect,
double[] r3,
double radiusRad)
Indicates whether ranges should be provided to generate a SkyAspect.
|
static double[] |
verticalRotate(double delta,
double alpha,
boolean reflect)
Rotation matrix which results in an orientation with the
viewing plane X coordinate of the north pole equal to zero.
|
getProjectionDescription, getProjectionName, getProjectionShape, getSkyviewProjecter, unproject
public static SinProjection INSTANCE
public boolean project(double rx, double ry, double rz, Point2D.Double pos)
project
in interface Projection
project
in class SkyviewProjection
rx
- 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 isContinuous()
Projection
isContinuousLine
returns false.public boolean isContinuousLine(double[] r3a, double[] r3b)
Projection
r3a
- 3-element array giving normalised X,Y,Z coordinates of
line startr3b
- 3-element array giving normalised X,Y,Z coordinates of
line endpublic double[] cursorRotate(double[] rot0, Point2D.Double pos0, Point2D.Double pos1)
Projection
projRotate
,
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.
rot0
- initial rotation matrixpos0
- initial cursor positionpos1
- destination cursor positionpublic double[] projRotate(double[] rot0, Point2D.Double pos0, Point2D.Double pos1)
Projection
Consider 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.
rot0
- initial rotation matrixpos0
- initial projected positionpos1
- destination projected positionpublic boolean useRanges(boolean reflect, double[] r3, double radiusRad)
Projection
reflect
- 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[] vxyzRanges)
Projection
reflect
- whether requested aspect will be reflectedr3
- central position of field of view (may be null)radiusRad
- radius of field of view (may be NaN)vxyzRanges
- 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)
Projection
surf
- sky surface, which must be set up using this projectionpublic static double[] verticalRotate(double delta, double alpha, boolean reflect)
delta
- rotation of pole from vertical (0..pi)alpha
- rotation around pole (0..2pi)reflect
- if true, alpha increases right to leftCopyright © 2025 Central Laboratory of the Research Councils. All Rights Reserved.