12 #include "VectorMath.h"
13 #include "EarthConstants.h"
14 #include "LatLongAltitude.h"
15 #include "MortonKey.h"
35 double x = radius * cos(latitudeInRadians) * cos(longitudeInRadians);
36 double y = radius * cos(latitudeInRadians) * sin(longitudeInRadians);
37 double z = radius * sin(latitudeInRadians);
59 return Eegeo::Space::CubeMap::EcefToKey(ecefPosition, level);
70 double p = sqrt((z * z) + (-x * -x));
72 double lat = atan(y / p);
73 double lon = atan2(-x, z);
92 return Space::CubeMap::KeyToECEF(key);
112 int screenPixelCoordinateY,