aboutsummaryrefslogtreecommitdiff
path: root/PhysX_3.4/Source/SimulationController/src/ScContactStream.h
diff options
context:
space:
mode:
authorsschirm <[email protected]>2016-12-23 14:20:36 +0100
committersschirm <[email protected]>2016-12-23 14:56:17 +0100
commitef6937e69e8ee3f409cf9d460d5ad300a65d5924 (patch)
tree710426e8daa605551ce3f34b581897011101c30f /PhysX_3.4/Source/SimulationController/src/ScContactStream.h
parentInitial commit: (diff)
downloadphysx-3.4-ef6937e69e8ee3f409cf9d460d5ad300a65d5924.tar.xz
physx-3.4-ef6937e69e8ee3f409cf9d460d5ad300a65d5924.zip
PhysX 3.4 / APEX 1.4 release candidate @21506124
Diffstat (limited to 'PhysX_3.4/Source/SimulationController/src/ScContactStream.h')
-rw-r--r--PhysX_3.4/Source/SimulationController/src/ScContactStream.h15
1 files changed, 3 insertions, 12 deletions
diff --git a/PhysX_3.4/Source/SimulationController/src/ScContactStream.h b/PhysX_3.4/Source/SimulationController/src/ScContactStream.h
index 163f119c..db6cf648 100644
--- a/PhysX_3.4/Source/SimulationController/src/ScContactStream.h
+++ b/PhysX_3.4/Source/SimulationController/src/ScContactStream.h
@@ -317,21 +317,12 @@ PX_FORCE_INLINE void Sc::ContactStreamManager::fillInContactReportExtraData(PxCo
PX_FORCE_INLINE void Sc::ContactStreamManager::fillInContactReportExtraData(PxContactPairPose* cpPose, PxU32 index, const RigidSim& rs, bool isCCDPass, const bool useCurrentTransform)
{
- if (rs.getActorType() != PxActorType::eRIGID_STATIC)
+ if(rs.getActorType() != PxActorType::eRIGID_STATIC)
{
const BodySim& bs = static_cast<const BodySim&>(rs);
const BodyCore& bc = bs.getBodyCore();
-
- if (!isCCDPass)
- {
- if (useCurrentTransform)
- cpPose->globalPose[index] = bc.getBody2World() * bc.getBody2Actor().getInverse();
- else
- cpPose->globalPose[index] = bs.getLowLevelBody().getLastCCDTransform() * bc.getBody2Actor().getInverse();
- }
- else
- cpPose->globalPose[index] = bs.getLowLevelBody().getLastCCDTransform() * bc.getBody2Actor().getInverse();
-
+ const PxTransform& src = (!isCCDPass && useCurrentTransform) ? bc.getBody2World() : bs.getLowLevelBody().getLastCCDTransform();
+ cpPose->globalPose[index] = src * bc.getBody2Actor().getInverse();
}
else
{