aboutsummaryrefslogtreecommitdiff
path: root/PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp
diff options
context:
space:
mode:
authorSheikh Dawood Abdul Ajees <[email protected]>2018-09-25 11:33:48 -0500
committerSheikh Dawood Abdul Ajees <[email protected]>2018-09-25 11:33:48 -0500
commitad993f2926db6fe4ba2c75e17c4f099d9d853038 (patch)
tree426f831e7aa870a4704b8dd082538ff292e751f9 /PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp
parentPhysX 3.4, APEX 1.4 patch release @24698370 (diff)
downloadphysx-3.4-ad993f2926db6fe4ba2c75e17c4f099d9d853038.tar.xz
physx-3.4-ad993f2926db6fe4ba2c75e17c4f099d9d853038.zip
PhysX 3.4, APEX 1.4 patch release @24990349
Diffstat (limited to 'PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp')
-rw-r--r--PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp19
1 files changed, 16 insertions, 3 deletions
diff --git a/PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp b/PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp
index e295ca78..53c3dcfe 100644
--- a/PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp
+++ b/PhysX_3.4/Source/LowLevelAABB/src/BpBroadPhaseSap.cpp
@@ -461,9 +461,7 @@ void BroadPhaseSap::update(const PxU32 numCpuTasks, PxcScratchAllocator* scratch
if(narrowPhaseUnblockTask)
narrowPhaseUnblockTask->removeReference();
- const bool success = setUpdateData(updateData);
-
- if(success)
+ if(setUpdateData(updateData))
{
mScratchAllocator = scratchAllocator;
@@ -483,6 +481,21 @@ void BroadPhaseSap::update(const PxU32 numCpuTasks, PxcScratchAllocator* scratch
}
}
+void BroadPhaseSap::singleThreadedUpdate(PxcScratchAllocator* scratchAllocator, const BroadPhaseUpdateData& updateData)
+{
+#if PX_CHECKED
+ PX_CHECK_AND_RETURN(scratchAllocator, "BroadPhaseSap::singleThreadedUpdate - scratchAllocator must be non-NULL \n");
+#endif
+
+ if(setUpdateData(updateData))
+ {
+ mScratchAllocator = scratchAllocator;
+ resizeBuffers();
+ update();
+ postUpdate();
+ }
+}
+
bool BroadPhaseSap::setUpdateData(const BroadPhaseUpdateData& updateData)
{
PX_ASSERT(0==mCreatedPairsSize);