Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4519 in orxonox.OLD for orxonox/trunk/src/util/collision_detection


Ignore:
Timestamp:
Jun 6, 2005, 2:36:04 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: changed all getInstances into inline functions to save some (minor) time

Location:
orxonox/trunk/src/util/collision_detection
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/util/collision_detection/cd_engine.cc

    r4511 r4519  
    3636
    3737/**
    38    \returns a Pointer to this Class
    39 */
    40 CDEngine* CDEngine::getInstance(void)
    41 {
    42   if (!CDEngine::singletonRef)
    43     CDEngine::singletonRef = new CDEngine();
    44   return CDEngine::singletonRef;
    45 }
    46 
    47 /**
    4838   \brief standard deconstructor
    4939
  • orxonox/trunk/src/util/collision_detection/cd_engine.h

    r4511 r4519  
    1515
    1616 public:
    17   static CDEngine* getInstance(void);
    1817  virtual ~CDEngine(void);
     18  /** \returns a Pointer to the only object of this Class */
     19  inline static CDEngine* getInstance(void) { if (!singletonRef) singletonRef = new CDEngine();  return singletonRef; };
    1920
    2021 private:
Note: See TracChangeset for help on using the changeset viewer.