Next / Previous / Contents / NM Tech homepage

6.34. CBCData.__terraCircle(): Convert a circle center to a terrestrial position

pycbc.py
# - - -   C B C D a t a . _ _ t e r r a C i r c l e

    def __terraCircle(self, circle):
        '''Convert a circle center to a terrestrial position.

          [ circle is a Circle instance ->
              return circle's center as a terrapos.LatLon instance ]
        '''
        latDeg = int(circle.lat[:2])
        latMin = int(circle.lat[2:])
        lonDeg = int(circle.lon[:3])
        lonMin = int(circle.lon[3:])
        return terrapos.LatLon ( (latDeg, latMin), (lonDeg, lonMin) )