Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 13, 2008, 8:50:03 PM (16 years ago)
Author:
rgrieder
Message:
  • Added orxonox TransformSpace enum (needed by WorldEntity.h)
  • Switched from "typedef Ogre::Vector3 Vector3;" to "using Ogre::Vector3;" because it really is an Ogre::Vector3
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/physics/src/util/Math.h

    r2087 r2424  
    5252namespace orxonox
    5353{
    54   typedef Ogre::Radian Radian;
    55   typedef Ogre::Degree Degree;
    56   typedef Ogre::Vector2 Vector2;
    57   typedef Ogre::Vector3 Vector3;
    58   typedef Ogre::Vector4 Vector4;
    59   typedef Ogre::Matrix3 Matrix3;
    60   typedef Ogre::Matrix4 Matrix4;
    61   typedef Ogre::Quaternion Quaternion;
    62   typedef Ogre::ColourValue ColourValue;
     54    using Ogre::Radian;
     55    using Ogre::Degree;
     56    using Ogre::Vector2;
     57    using Ogre::Vector3;
     58    using Ogre::Vector4;
     59    using Ogre::Matrix3;
     60    using Ogre::Matrix4;
     61    using Ogre::Quaternion;
     62    using Ogre::ColourValue;
     63
     64    // Also define our own transform space enum
     65    namespace TransformSpace
     66    {
     67        /**
     68        @brief
     69            Enumeration denoting the spaces which a transform can be relative to.
     70        */
     71        enum Space
     72        {
     73            /// Transform is relative to the local space
     74            Local,
     75            /// Transform is relative to the space of the parent node
     76            Parent,
     77            /// Transform is relative to world space
     78            World
     79        };
     80    }
    6381}
    6482
     
    193211inline T zeroise()
    194212{
    195     BOOST_STATIC_ASSERT(sizeof(T) == 0);
    196     return T();
     213    // Default, raise a compiler error without including large boost header cascade.
     214    T temp();
     215    *********temp; // If you reach this code, you abused zeroise()!
     216    return temp;
    197217}
    198218
Note: See TracChangeset for help on using the changeset viewer.