#include <opennurbs_3dm_settings.h>
Public Member Functions | |
ON_EarthAnchorPoint ()=default | |
ON_EarthAnchorPoint (const ON_EarthAnchorPoint &)=default | |
~ON_EarthAnchorPoint ()=default | |
ON::EarthCoordinateSystem | EarthCoordinateSystem () const |
System used to define latiude, longitude and elevation. More... | |
ON_3dPoint | EarthLocation () const |
ON_3dPoint | EarthLocation (ON_3dPoint unset_location) const |
bool | EarthLocationIsSet () const |
double | Elevation (const class ON_UnitSystem &elevation_unit_system) const |
double | Elevation (ON::LengthUnitSystem elevation_unit_system) const |
double | Elevation (const class ON_UnitSystem &elevation_unit_system, double unset_elevation) const |
double | Elevation (ON::LengthUnitSystem elevation_unit_system, double unset_elevation) const |
double | ElevationInMeters () const |
bool | GetModelCompass (ON_Plane &model_compass) const |
bool | GetModelToEarthXform (const ON_UnitSystem &model_unit_system, ON_Xform &model_to_earth) const |
Get a transformation from model coordinates to earth coordinates. This transformation assumes the model is small enough that the curvature of the earth can be ignored. More... | |
double | Latitude () const |
double | Latitude (double unset_latitude) const |
double | Longitude () const |
double | Longitude (double unset_longitude) const |
const ON_3dVector & | ModelEast () const |
bool | ModelLocationIsSet () const |
const ON_3dVector & | ModelNorth () const |
const ON_3dPoint & | ModelPoint () const |
ON_EarthAnchorPoint & | operator= (const ON_EarthAnchorPoint &)=default |
bool | Read (ON_BinaryArchive &) |
void | SetEarthCoordinateSystem (ON::EarthCoordinateSystem earth_coordinate_system) |
System used to define Earth latiude, longitude, and elevation coordinates. More... | |
void | SetEarthLocation (ON::EarthCoordinateSystem earth_coordinate_system, const class ON_UnitSystem &elevation_unit_system, double latitude_degrees, double longitude_degrees, double elevation) |
void | SetEarthLocation (ON::EarthCoordinateSystem earth_coordinate_system, ON::LengthUnitSystem elevation_unit_system, double latitude_degrees, double longitude_degrees, double elevation) |
void | SetElevation (const ON_UnitSystem &elevation_unit_system, double elevation) |
void | SetElevation (ON::LengthUnitSystem elevation_unit_system, double elevation) |
void | SetLatitude (double latitude_degrees) |
void | SetLatitudeAndLongitude (double latitude_degrees, double longitude_degrees) |
void | SetLongitude (double longitude_degrees) |
void | SetModelEast (ON_3dVector model_east) |
void | SetModelLocation (ON_3dPoint model_point, ON_3dVector model_north, ON_3dVector model_east) |
void | SetModelNorth (ON_3dVector model_north) |
void | SetModelPoint (ON_3dPoint model_point) |
bool | Write (ON_BinaryArchive &) const |
Static Public Member Functions | |
static int | Compare (const ON_EarthAnchorPoint *, const ON_EarthAnchorPoint *) |
static int | CompareEarthLocation (const ON_EarthAnchorPoint *, const ON_EarthAnchorPoint *) |
static int | CompareIdentification (const ON_EarthAnchorPoint *, const ON_EarthAnchorPoint *) |
static int | CompareModelDirection (const ON_EarthAnchorPoint *, const ON_EarthAnchorPoint *) |
Public Attributes | |
ON_wString | m_description |
ON_UUID | m_id = ON_nil_uuid |
Identification information about this location. More... | |
ON_wString | m_name |
ON_wString | m_url |
ON_wString | m_url_tag |
Static Public Attributes | |
static const ON_EarthAnchorPoint | SeattleSpaceNeedle |
Latitude, longitude, and elevation are the Seattle Space Needle. More... | |
static const ON_EarthAnchorPoint | Unset |
Latitude, longitude, and elevation are ON_UNSET_VALUE. More... | |
|
default |
|
default |
|
default |
|
static |
|
static |
|
static |
|
static |
ON::EarthCoordinateSystem ON_EarthAnchorPoint::EarthCoordinateSystem | ( | ) | const |
System used to define latiude, longitude and elevation.
ON_3dPoint ON_EarthAnchorPoint::EarthLocation | ( | ) | const |
Some coordinates may be ON_UNSET_VALUE.
ON_3dPoint ON_EarthAnchorPoint::EarthLocation | ( | ON_3dPoint | unset_location | ) | const |
unset_location | [in] Location to return if EarlocationIsSet() is false. |
bool ON_EarthAnchorPoint::EarthLocationIsSet | ( | ) | const |
double ON_EarthAnchorPoint::Elevation | ( | const class ON_UnitSystem & | elevation_unit_system | ) | const |
elevation_unit_system | [in] length unit system for returned value. |
double ON_EarthAnchorPoint::Elevation | ( | ON::LengthUnitSystem | elevation_unit_system | ) | const |
elevation_unit_system | [in] length unit system for returned value. |
double ON_EarthAnchorPoint::Elevation | ( | const class ON_UnitSystem & | elevation_unit_system, |
double | unset_elevation | ||
) | const |
elevation_unit_system | [in] length unit system for returned value. |
unset_elevation | [in] Value to return if the Earth location elevation is not set. |
double ON_EarthAnchorPoint::Elevation | ( | ON::LengthUnitSystem | elevation_unit_system, |
double | unset_elevation | ||
) | const |
elevation_unit_system | [in] length unit system for returned value. |
unset_elevation | [in] Value to return if the Earth location elevation is not set. |
double ON_EarthAnchorPoint::ElevationInMeters | ( | ) | const |
bool ON_EarthAnchorPoint::GetModelCompass | ( | ON_Plane & | model_compass | ) | const |
model_compass | [out] A plane in model coordinates whose xaxis points East, yaxis points North and zaxis points up. The origin is set to m_model_basepoint. |
bool ON_EarthAnchorPoint::GetModelToEarthXform | ( | const ON_UnitSystem & | model_unit_system, |
ON_Xform & | model_to_earth | ||
) | const |
Get a transformation from model coordinates to earth coordinates. This transformation assumes the model is small enough that the curvature of the earth can be ignored.
model_unit_system | [in] |
model_to_earth | [out] Transformation from model coordinates to earth locations (degrees latitude,degrees longitude,elevation in meters) |
If M is a point in model coordinates and E = model_to_earth*M, then E.x = latitude in decimal degrees E.y = longitude in decimal degrees E.z = elevation in meters above mean sea level
Because the earth is not flat, there is a small amount of error when using a linear transformation to calculate oblate spherical coordinates. This error is small. If the distance from P to M is d meters, then the approximation error is
latitude error <= longitude error <= elevation error <= 6379000*((1 + (d/6356000)^2)-1) meters
In particular, if every point in the model is within 1000 meters of the m_model_basepoint, then the maximum approximation errors are
latitude error <= longitude error <= elevation error <= 8 centimeters
double ON_EarthAnchorPoint::Latitude | ( | ) | const |
double ON_EarthAnchorPoint::Latitude | ( | double | unset_latitude | ) | const |
unset_latitude | [in] Value to return if the Earth location latitude is not set. |
double ON_EarthAnchorPoint::Longitude | ( | ) | const |
double ON_EarthAnchorPoint::Longitude | ( | double | unset_longitude | ) | const |
unset_longitude | [in] Value to return if the Earth location latitude is not set. |
const ON_3dVector& ON_EarthAnchorPoint::ModelEast | ( | ) | const |
bool ON_EarthAnchorPoint::ModelLocationIsSet | ( | ) | const |
const ON_3dVector& ON_EarthAnchorPoint::ModelNorth | ( | ) | const |
const ON_3dPoint& ON_EarthAnchorPoint::ModelPoint | ( | ) | const |
|
default |
bool ON_EarthAnchorPoint::Read | ( | ON_BinaryArchive & | ) |
void ON_EarthAnchorPoint::SetEarthCoordinateSystem | ( | ON::EarthCoordinateSystem | earth_coordinate_system | ) |
System used to define Earth latiude, longitude, and elevation coordinates.
void ON_EarthAnchorPoint::SetEarthLocation | ( | ON::EarthCoordinateSystem | earth_coordinate_system, |
const class ON_UnitSystem & | elevation_unit_system, | ||
double | latitude_degrees, | ||
double | longitude_degrees, | ||
double | elevation | ||
) |
elevation_unit_system | [in] |
elevation | [in] |
void ON_EarthAnchorPoint::SetEarthLocation | ( | ON::EarthCoordinateSystem | earth_coordinate_system, |
ON::LengthUnitSystem | elevation_unit_system, | ||
double | latitude_degrees, | ||
double | longitude_degrees, | ||
double | elevation | ||
) |
void ON_EarthAnchorPoint::SetElevation | ( | const ON_UnitSystem & | elevation_unit_system, |
double | elevation | ||
) |
elevation_unit_system | [in] |
elevation | [in] |
void ON_EarthAnchorPoint::SetElevation | ( | ON::LengthUnitSystem | elevation_unit_system, |
double | elevation | ||
) |
void ON_EarthAnchorPoint::SetLatitude | ( | double | latitude_degrees | ) |
void ON_EarthAnchorPoint::SetLatitudeAndLongitude | ( | double | latitude_degrees, |
double | longitude_degrees | ||
) |
void ON_EarthAnchorPoint::SetLongitude | ( | double | longitude_degrees | ) |
void ON_EarthAnchorPoint::SetModelEast | ( | ON_3dVector | model_east | ) |
void ON_EarthAnchorPoint::SetModelLocation | ( | ON_3dPoint | model_point, |
ON_3dVector | model_north, | ||
ON_3dVector | model_east | ||
) |
void ON_EarthAnchorPoint::SetModelNorth | ( | ON_3dVector | model_north | ) |
void ON_EarthAnchorPoint::SetModelPoint | ( | ON_3dPoint | model_point | ) |
bool ON_EarthAnchorPoint::Write | ( | ON_BinaryArchive & | ) | const |
ON_wString ON_EarthAnchorPoint::m_description |
ON_UUID ON_EarthAnchorPoint::m_id = ON_nil_uuid |
Identification information about this location.
ON_wString ON_EarthAnchorPoint::m_name |
ON_wString ON_EarthAnchorPoint::m_url |
ON_wString ON_EarthAnchorPoint::m_url_tag |
|
static |
Latitude, longitude, and elevation are the Seattle Space Needle.
|
static |
Latitude, longitude, and elevation are ON_UNSET_VALUE.