MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/PhysX / handleOriginShift

Method handleOriginShift

physx/source/lowlevelaabb/src/BpAABBManager.cpp:1421–1454  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1419}
1420
1421void AABBManager::handleOriginShift()
1422{
1423 mOriginShifted = false;
1424 mPersistentStateChanged = true;
1425 // PT: TODO: isn't the following loop potentially updating removed objects?
1426 // PT: TODO: check that aggregates code is correct here
1427 for(PxU32 i=0; i<mUsedSize; i++)
1428 {
1429 if(mGroups[i] == Bp::FilterGroup::eINVALID)
1430 continue;
1431
1432 {
1433 if(mVolumeData[i].isSingleActor())
1434 {
1435 if(!mAddedHandleMap.test(i))
1436 mUpdatedHandles.pushBack(i); // PT: TODO: BoundsIndex-to-ShapeHandle confusion here
1437 }
1438 else if(mVolumeData[i].isAggregate())
1439 {
1440 const AggregateHandle aggregateHandle = mVolumeData[i].getAggregate();
1441 Aggregate* aggregate = getAggregateFromHandle(aggregateHandle);
1442 if(aggregate->getNbAggregated())
1443 {
1444 aggregate->markAsDirty(mDirtyAggregates);
1445 aggregate->allocateBounds();
1446 aggregate->computeBounds(mBoundsArray.begin(), mContactDistance.begin());
1447 mBoundsArray.begin()[aggregate->mIndex] = aggregate->getMergedBounds();
1448 if(!mAddedHandleMap.test(i))
1449 mUpdatedHandles.pushBack(i); // PT: TODO: BoundsIndex-to-ShapeHandle confusion here
1450 }
1451 }
1452 }
1453 }
1454}
1455
1456void AggregateBoundsComputationTask::runInternal()
1457{

Callers

nothing calls this directly

Calls 10

getAggregateFromHandleFunction · 0.85
isSingleActorMethod · 0.80
getNbAggregatedMethod · 0.80
markAsDirtyMethod · 0.80
allocateBoundsMethod · 0.80
testMethod · 0.45
pushBackMethod · 0.45
getAggregateMethod · 0.45
computeBoundsMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected