aboutsummaryrefslogtreecommitdiff
path: root/APEX_1.4/module/clothing/embedded/Simulation.cpp
diff options
context:
space:
mode:
authorsschirm <[email protected]>2017-02-27 16:40:12 +0100
committersschirm <[email protected]>2017-03-01 18:04:26 +0100
commit7840347c32755e94a807f978f1cbb558717ac8cf (patch)
tree295cd3ca93a45f8fcc43cf3cbf3887c0e0c5526b /APEX_1.4/module/clothing/embedded/Simulation.cpp
parentPre-release comments marking end of beta. (diff)
downloadphysx-3.4-7840347c32755e94a807f978f1cbb558717ac8cf.tar.xz
physx-3.4-7840347c32755e94a807f978f1cbb558717ac8cf.zip
PhysX 3.4, APEX 1.4 final release @21757769v3.4.0-rc-2
Diffstat (limited to 'APEX_1.4/module/clothing/embedded/Simulation.cpp')
-rw-r--r--APEX_1.4/module/clothing/embedded/Simulation.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/APEX_1.4/module/clothing/embedded/Simulation.cpp b/APEX_1.4/module/clothing/embedded/Simulation.cpp
index 2bb17402..1ed2e94d 100644
--- a/APEX_1.4/module/clothing/embedded/Simulation.cpp
+++ b/APEX_1.4/module/clothing/embedded/Simulation.cpp
@@ -1677,6 +1677,7 @@ void Simulation::getVelocities(PxVec3* velocities) const
PX_PROFILE_ZONE("SimulationPxCloth::getVelocities", GetInternalApexSDK()->getContextId());
PX_ALIGN(16, PxMat44 oldFrameDiff) = PxMat44(PxIdentity);
+
bool useOldFrame = false;
if (mGlobalPose != mGlobalPosePrevious && mLocalSpaceSim && mLastTimestep > 0.0f)
{
@@ -1687,6 +1688,7 @@ void Simulation::getVelocities(PxVec3* velocities) const
const float w = mCloth->getPreviousIterationDt() / mLastTimestep;
oldFrameDiff = interpolateMatrix(w, oldFrameDiff, mGlobalPoseNormalized);
oldFrameDiff = mGlobalPoseNormalized.inverseRT() * oldFrameDiff;
+ oldFrameDiff.column3[3] = 0.f; //V3StoreU internally check that vec3 has zero at index 3
useOldFrame = true;
}