1)Added SCE Physics Effects boxBoxDistance
BulletMultiThreaded/NarrowPhaseCollision makes use of this boxBoxDistance. Cache some values in src/BulletMultiThreaded/SpuContactManifoldCollisionAlgorithm.cpp, to avoid DMA transfers 2) Added btConvexSeparatingDistanceUtil: this allows caching of separating distance/vector as early-out to avoid convex-convex collision detection. btConvexSeparatingDistanceUtil is used in src/BulletCollision/CollisionDispatch/btConvexConvexAlgorithm.cpp and can be controlled by btDispatcherInfo.m_useConvexConservativeDistanceUtil/m_convexConservativeDistanceThreshold 3) Use BulletMultiThreaded/vectormath/scalar/cpp/vectormath/scalar/cpp/vectormath_aos.h as fallback for non-PlayStation 3 Cell SPU/PPU platforms (used by boxBoxDistance). Note there are other implementations in Extras/vectormath folder, that are potentially faster for IBM Cell SDK 3.0 SPU (libspe2)
This commit is contained in:
@@ -26,6 +26,11 @@ subject to the following restrictions:
|
||||
#include "Taru.mdl"
|
||||
#include "landscape.mdl"
|
||||
#include "BulletCollision/BroadphaseCollision/btDbvtBroadphase.h"
|
||||
#include "BulletMultiThreaded/SpuGatheringCollisionDispatcher.h"
|
||||
#include "BulletMultiThreaded/SequentialThreadSupport.h"
|
||||
#include "BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuGatheringCollisionTask.h"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -268,6 +273,16 @@ void BenchmarkDemo::initPhysics()
|
||||
///use the default collision dispatcher. For parallel processing you can use a diffent dispatcher (see Extras/BulletMultiThreaded)
|
||||
m_dispatcher = new btCollisionDispatcher(m_collisionConfiguration);
|
||||
|
||||
#if 0
|
||||
SequentialThreadSupport::SequentialThreadConstructionInfo sci("spuCD",
|
||||
processCollisionTask,
|
||||
createCollisionLocalStoreMemory);
|
||||
|
||||
SequentialThreadSupport* seq = new SequentialThreadSupport(sci);
|
||||
m_dispatcher = new SpuGatheringCollisionDispatcher(seq,1,m_collisionConfiguration);
|
||||
#endif
|
||||
|
||||
|
||||
///the maximum size of the collision world. Make sure objects stay within these boundaries
|
||||
///Don't make the world AABB size too large, it will harm simulation quality and performance
|
||||
btVector3 worldAabbMin(-10000,-10000,-10000);
|
||||
@@ -1132,9 +1147,9 @@ void BenchmarkDemo::castRays()
|
||||
|
||||
void BenchmarkDemo::createTest7()
|
||||
{
|
||||
setCameraDistance(btScalar(150.));
|
||||
|
||||
createTest6();
|
||||
|
||||
setCameraDistance(btScalar(150.));
|
||||
initRays();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user