Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3799 in orxonox.OLD


Ignore:
Timestamp:
Apr 13, 2005, 5:51:48 PM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: using G_LIKELY() as Atilla suggested, seems only to work on linux, so its in ifdef

Location:
orxonox/trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/coord/p_node.cc

    r3729 r3799  
    2929#include "null_parent.h"
    3030
     31#ifdef __unix__
     32 #include <glib-2.0/glib/gmacros.h>
     33#endif
    3134
    3235//#include "vector.h"
     
    4851  np->addChild(this);
    4952}
     53
    5054
    5155
     
    6064
    6165  *this->absCoordinate = *absCoordinate;
    62   if (parent != NULL)
     66#ifdef __unix__
     67  if ( G_UNLIKELY(parent != NULL))
     68#else
     69  if ( parent != NULL)
     70#endif
    6371    {
    6472      *this->relCoordinate = *this->absCoordinate - parent->getAbsCoor ();
     
    244252void PNode::shiftCoor (Vector* shift)
    245253{
     254#ifdef __unix__
     255  if( G_UNLIKELY(this->bAbsCoorChanged))
     256#else
    246257  if( this->bAbsCoorChanged)
     258#endif
    247259    {
    248260      *this->absCoordinate = *this->absCoordinate + *shift;
     
    279291void PNode::shiftCoor (Vector shift)
    280292{
     293#ifdef __unix__
     294  if( G_UNLIKELY(this->bAbsCoorChanged))
     295#else
    281296  if( this->bAbsCoorChanged)
     297#endif
    282298    {
    283299      *this->absCoordinate = *this->absCoordinate + shift;
     
    421437float PNode::getSpeed()
    422438{
     439#ifdef __unix__
     440  if( G_UNLIKELY(this->time == 0))
     441#else
    423442  if(this->time == 0)
     443#endif
    424444    return 1000;
    425445  Vector diff;
  • orxonox/trunk/src/world_entities/world_entity.h

    r3658 r3799  
    2727
    2828
    29 
    30  
    3129  //void setCollision (CollisionCluster* newhull);
    3230 
Note: See TracChangeset for help on using the changeset viewer.