public class RoundEarthMethod extends VRHorzCalcMethod
Constructor and Description |
---|
RoundEarthMethod(VRControl vrControl) |
Modifier and Type | Method and Description |
---|---|
void |
configure() |
RangeDialogPanel |
dialogPanel() |
double |
getAngle(double height,
double range)
Converts a range into an angle below the horizon.
|
double |
getHorizonDistance(double height)
Calculate the distance to the horizon from a given height.
|
double |
getRange(double height,
double angle)
Converts a height and an angle below the horizon to a distance in metres.
|
double |
psiFromRange(double height,
double range)
Convert a range to an angle up from the vertical
(cosine rule).
|
double |
rangeFromPsi(double height,
double psi)
Many calcls, including those in the refractionmethoduse the anlge
from the vertical, so put that as a separate calculation.
|
public RoundEarthMethod(VRControl vrControl)
public void configure()
public RangeDialogPanel dialogPanel()
dialogPanel
in class VRHorzCalcMethod
public double getRange(double height, double angle)
VRHorzCalcMethod
getRange
in class VRHorzCalcMethod
height
- platform height (metres)angle
- angle below the horizon (radians)public double rangeFromPsi(double height, double psi)
Eq. 1. From Leaper and Gordon.
rangeFromPsi
in class VRHorzCalcMethod
height
- camera heightpsi
- angle up from verticalpublic double getAngle(double height, double range)
VRHorzCalcMethod
Or returns -1 if the range is beyond the horizon.
getAngle
in class VRHorzCalcMethod
height
- platofrm height (metres)range
- range to object.public double psiFromRange(double height, double range)
psiFromRange
in class VRHorzCalcMethod
height
- platofrm heightrange
- range to objectpublic double getHorizonDistance(double height)
VRHorzCalcMethod
getHorizonDistance
in class VRHorzCalcMethod