Changeset 7983 for code/branches/kicklib/src/external/bullet/BulletCollision/BroadphaseCollision/btDbvt.h
- Timestamp:
- Feb 27, 2011, 7:43:24 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/kicklib/src/external/bullet/BulletCollision/BroadphaseCollision/btDbvt.h
r5781 r7983 33 33 34 34 // Template implementation of ICollide 35 #ifdef WIN3235 #ifdef _WIN32 36 36 #if (defined (_MSC_VER) && _MSC_VER >= 1400) 37 37 #define DBVT_USE_TEMPLATE 1 … … 58 58 59 59 //SSE gives errors on a MSVC 7.1 60 #if def BT_USE_SSE60 #if defined (BT_USE_SSE) && defined (_WIN32) 61 61 #define DBVT_SELECT_IMPL DBVT_IMPL_SSE 62 62 #define DBVT_MERGE_IMPL DBVT_IMPL_SSE … … 93 93 94 94 #if DBVT_USE_MEMMOVE 95 #if ndef __CELLOS_LV2__95 #if !defined( __CELLOS_LV2__) && !defined(__MWERKS__) 96 96 #include <memory.h> 97 97 #endif … … 485 485 pi=btVector3(mi.x(),mi.y(),mi.z());break; 486 486 } 487 if(( dot(n,px)+o)<0) return(-1);488 if(( dot(n,pi)+o)>=0) return(+1);487 if((btDot(n,px)+o)<0) return(-1); 488 if((btDot(n,pi)+o)>=0) return(+1); 489 489 return(0); 490 490 } … … 497 497 b[(signs>>1)&1]->y(), 498 498 b[(signs>>2)&1]->z()); 499 return( dot(p,v));499 return(btDot(p,v)); 500 500 } 501 501 … … 948 948 DBVT_IPOLICY) const 949 949 { 950 (void) rayTo; 950 951 DBVT_CHECKTYPE 951 952 if(root) … … 962 963 { 963 964 const btDbvtNode* node=stack[--depth]; 964 bounds[0] = node->volume.Mins() +aabbMin;965 bounds[1] = node->volume.Maxs() +aabbMax;965 bounds[0] = node->volume.Mins()-aabbMax; 966 bounds[1] = node->volume.Maxs()-aabbMin; 966 967 btScalar tmin=1.f,lambda_min=0.f; 967 968 unsigned int result1=false; … … 1001 1002 rayDir.normalize (); 1002 1003 1003 ///what about division by zero? --> just set rayDirection[i] to INF/ 1e301004 ///what about division by zero? --> just set rayDirection[i] to INF/BT_LARGE_FLOAT 1004 1005 btVector3 rayDirectionInverse; 1005 rayDirectionInverse[0] = rayDir[0] == btScalar(0.0) ? btScalar( 1e30) : btScalar(1.0) / rayDir[0];1006 rayDirectionInverse[1] = rayDir[1] == btScalar(0.0) ? btScalar( 1e30) : btScalar(1.0) / rayDir[1];1007 rayDirectionInverse[2] = rayDir[2] == btScalar(0.0) ? btScalar( 1e30) : btScalar(1.0) / rayDir[2];1006 rayDirectionInverse[0] = rayDir[0] == btScalar(0.0) ? btScalar(BT_LARGE_FLOAT) : btScalar(1.0) / rayDir[0]; 1007 rayDirectionInverse[1] = rayDir[1] == btScalar(0.0) ? btScalar(BT_LARGE_FLOAT) : btScalar(1.0) / rayDir[1]; 1008 rayDirectionInverse[2] = rayDir[2] == btScalar(0.0) ? btScalar(BT_LARGE_FLOAT) : btScalar(1.0) / rayDir[2]; 1008 1009 unsigned int signs[3] = { rayDirectionInverse[0] < 0.0, rayDirectionInverse[1] < 0.0, rayDirectionInverse[2] < 0.0}; 1009 1010
Note: See TracChangeset
for help on using the changeset viewer.