Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 6137 for code


Ignore:
Timestamp:
Nov 24, 2009, 3:11:31 AM (15 years ago)
Author:
landauf
Message:

Ogre introduced overloadings of the << operator for Radian and Degree in version 1.6.3
So exclude our own implementation of this if the version is greater or equal.

Location:
code/branches/presentation2/src/libraries/util
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/presentation2/src/libraries/util/Math.cc

    r5738 r6137  
    4343namespace orxonox
    4444{
     45#if OGRE_VERSION < 0x010603
    4546    /**
    4647        @brief Function for writing a Radian to a stream.
     
    5152        return out;
    5253    }
     54
     55    /**
     56        @brief Function for writing a Degree to a stream.
     57    */
     58    std::ostream& operator<<(std::ostream& out, const orxonox::Degree& degree)
     59    {
     60        out << degree.valueDegrees();
     61        return out;
     62    }
     63#endif
    5364
    5465    /**
     
    6172        radian = temp;
    6273        return in;
    63     }
    64 
    65     /**
    66         @brief Function for writing a Degree to a stream.
    67     */
    68     std::ostream& operator<<(std::ostream& out, const orxonox::Degree& degree)
    69     {
    70         out << degree.valueDegrees();
    71         return out;
    7274    }
    7375
  • code/branches/presentation2/src/libraries/util/Math.h

    r5738 r6137  
    5959namespace orxonox
    6060{
     61#if OGRE_VERSION < 0x010603
    6162    _UtilExport std::ostream& operator<<(std::ostream& out, const orxonox::Radian& radian);
     63    _UtilExport std::ostream& operator<<(std::ostream& out, const orxonox::Degree& degree);
     64#endif
    6265    _UtilExport std::istream& operator>>(std::istream& in, orxonox::Radian& radian);
    63     _UtilExport std::ostream& operator<<(std::ostream& out, const orxonox::Degree& degree);
    6466    _UtilExport std::istream& operator>>(std::istream& in, orxonox::Degree& degree);
    6567
Note: See TracChangeset for help on using the changeset viewer.