gov.nasa.worldwind.geom.Angle.<init>()方法的使用及代码示例

x33g5p2x  于2022-01-17 转载在 其他  
字(5.8k)|赞(0)|评价(0)|浏览(97)

本文整理了Java中gov.nasa.worldwind.geom.Angle.<init>()方法的一些代码示例,展示了Angle.<init>()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Angle.<init>()方法的具体详情如下:
包路径:gov.nasa.worldwind.geom.Angle
类名称:Angle
方法名:<init>

Angle.<init>介绍

暂无

代码示例

代码示例来源:origin: com.bitplan.radolan/com.bitplan.radolan

public static Angle fromDegreesLatitude(double degrees)
{
  degrees = degrees < -90 ? -90 : degrees > 90 ? 90 : degrees;
  double radians = DEGREES_TO_RADIANS * degrees;
  radians = radians < -PIOver2 ? -PIOver2 : radians > PIOver2 ? PIOver2 : radians;
  return new Angle(degrees, radians);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

public static Angle fromDegreesLongitude(double degrees)
{
  degrees = degrees < -180 ? -180 : degrees > 180 ? 180 : degrees;
  double radians = DEGREES_TO_RADIANS * degrees;
  radians = radians < -Math.PI ? -Math.PI : radians > Math.PI ? Math.PI : radians;
  return new Angle(degrees, radians);
}

代码示例来源:origin: com.bitplan.radolan/com.bitplan.radolan

/**
 * Obtains an angle from a specified number of degrees.
 *
 * @param degrees the size in degrees of the angle to be obtained
 *
 * @return a new angle, whose size in degrees is given by <code>degrees</code>
 */
public static Angle fromDegrees(double degrees)
{
  return new Angle(degrees, DEGREES_TO_RADIANS * degrees);
}

代码示例来源:origin: com.bitplan.radolan/com.bitplan.radolan

/**
 * Obtains an angle from a specified number of radians.
 *
 * @param radians the size in radians of the angle to be obtained.
 *
 * @return a new angle, whose size in radians is given by <code>radians</code>.
 */
public static Angle fromRadians(double radians)
{
  return new Angle(RADIANS_TO_DEGREES * radians, radians);
}

代码示例来源:origin: com.bitplan.radolan/com.bitplan.radolan

public static Angle fromRadiansLatitude(double radians)
{
  radians = radians < -PIOver2 ? -PIOver2 : radians > PIOver2 ? PIOver2 : radians;
  double degrees = RADIANS_TO_DEGREES * radians;
  degrees = degrees < -90 ? -90 : degrees > 90 ? 90 : degrees;
  return new Angle(degrees, radians);
}

代码示例来源:origin: com.bitplan.radolan/com.bitplan.radolan

public static Angle fromDegreesLongitude(double degrees)
{
  degrees = degrees < -180 ? -180 : degrees > 180 ? 180 : degrees;
  double radians = DEGREES_TO_RADIANS * degrees;
  radians = radians < -Math.PI ? -Math.PI : radians > Math.PI ? Math.PI : radians;
  return new Angle(degrees, radians);
}

代码示例来源:origin: com.bitplan.radolan/com.bitplan.radolan

public static Angle fromRadiansLongitude(double radians)
{
  radians = radians < -Math.PI ? -Math.PI : radians > Math.PI ? Math.PI : radians;
  double degrees = RADIANS_TO_DEGREES * radians;
  degrees = degrees < -180 ? -180 : degrees > 180 ? 180 : degrees;
  return new Angle(degrees, radians);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

/**
 * Obtains an angle from a specified number of radians.
 *
 * @param radians the size in radians of the angle to be obtained.
 *
 * @return a new angle, whose size in radians is given by <code>radians</code>.
 */
public static Angle fromRadians(double radians)
{
  return new Angle(RADIANS_TO_DEGREES * radians, radians);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

public static Angle fromRadiansLatitude(double radians)
{
  radians = radians < -PIOver2 ? -PIOver2 : radians > PIOver2 ? PIOver2 : radians;
  double degrees = RADIANS_TO_DEGREES * radians;
  degrees = degrees < -90 ? -90 : degrees > 90 ? 90 : degrees;
  return new Angle(degrees, radians);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

/**
 * Obtains an angle from a specified number of degrees.
 *
 * @param degrees the size in degrees of the angle to be obtained
 *
 * @return a new angle, whose size in degrees is given by <code>degrees</code>
 */
public static Angle fromDegrees(double degrees)
{
  return new Angle(degrees, DEGREES_TO_RADIANS * degrees);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

public static Angle fromDegreesLatitude(double degrees)
{
  degrees = degrees < -90 ? -90 : degrees > 90 ? 90 : degrees;
  double radians = DEGREES_TO_RADIANS * degrees;
  radians = radians < -PIOver2 ? -PIOver2 : radians > PIOver2 ? PIOver2 : radians;
  return new Angle(degrees, radians);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

public static Angle fromRadiansLongitude(double radians)
{
  radians = radians < -Math.PI ? -Math.PI : radians > Math.PI ? Math.PI : radians;
  double degrees = RADIANS_TO_DEGREES * radians;
  degrees = degrees < -180 ? -180 : degrees > 180 ? 180 : degrees;
  return new Angle(degrees, radians);
}

代码示例来源:origin: com.bitplan.radolan/com.bitplan.radolan

/**
 * Obtains an angle from rectangular coordinates.
 *
 * @param x the abscissa coordinate.
 * @param y the ordinate coordinate.
 *
 * @return a new angle, whose size is determined from <code>x</code> and <code>y</code>.
 */
public static Angle fromXY(double x, double y)
{
  double radians = Math.atan2(y, x);
  return new Angle(RADIANS_TO_DEGREES * radians, radians);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

/**
 * Obtains an angle from rectangular coordinates.
 *
 * @param x the abscissa coordinate.
 * @param y the ordinate coordinate.
 *
 * @return a new angle, whose size is determined from <code>x</code> and <code>y</code>.
 */
public static Angle fromXY(double x, double y)
{
  double radians = Math.atan2(y, x);
  return new Angle(RADIANS_TO_DEGREES * radians, radians);
}

代码示例来源:origin: Berico-Technologies/Geo-Coordinate-Conversion-Java

public Sector(Sector sector)
{
  if (sector == null)
  {
    throw new IllegalArgumentException("Sector Is Null");
  }
  this.minLatitude = new Angle(sector.getMinLatitude());
  this.maxLatitude = new Angle(sector.getMaxLatitude());
  this.minLongitude = new Angle(sector.getMinLongitude());
  this.maxLongitude = new Angle(sector.getMaxLongitude());
  this.deltaLat = Angle.fromDegrees(this.maxLatitude.degrees - this.minLatitude.degrees);
  this.deltaLon = Angle.fromDegrees(this.maxLongitude.degrees - this.minLongitude.degrees);
}

代码示例来源:origin: it.tidalwave.geo/it-tidalwave-geo-viewer-spi-worldwindprovider

@Nonnull
public static MercatorSector fromSector (final @Nonnull Sector sector)
 {
  return new MercatorSector(gudermannianInverse(sector.getMinLatitude()),
               gudermannianInverse(sector.getMaxLatitude()),
               new Angle(sector.getMinLongitude()),
               new Angle(sector.getMaxLongitude()));
 }

相关文章