- //Get the current tile center
- Point3D currentCenter = globals->get_scenery()->get_center();
- Point3D tileCenter = currentCenter;
- if (center != currentCenter) //if changing tiles
- tileCenter = center; //use last center
-
- double alt = current_aircraft.fdm_state->get_Runway_altitude() * SG_FEET_TO_METER;
- double length = (_runway._length / 2.0) * SG_FEET_TO_METER;
- double width = (_runway._width / 2.0) * SG_FEET_TO_METER;
- double frontLat, frontLon, backLat, backLon,az, tempLat, tempLon;
-
- geo_direct_wgs_84(alt, _runway._lat, _runway._lon, _runway._heading, length, &backLat, &backLon, &az);
+ geo_direct_wgs_84(alt, _runway->latitude(), _runway->longitude(), _runway->headingDeg(), length, &backLat, &backLon, &az);