diff options
| author | Bryan Galdrikian <[email protected]> | 2017-08-28 13:55:34 -0700 |
|---|---|---|
| committer | Bryan Galdrikian <[email protected]> | 2017-08-28 13:55:34 -0700 |
| commit | 1e887d827e65a084a0ad0ba933c61a8330aeee07 (patch) | |
| tree | 1e2aab418dadd37f5dc0aae4d8b00e81d909fd24 /sdk/extensions/physx/source/physics/NvBlastExtPxFamilyImpl.cpp | |
| parent | Removing ArtistTools and CurveEditor projects (diff) | |
| download | blast-1e887d827e65a084a0ad0ba933c61a8330aeee07.tar.xz blast-1e887d827e65a084a0ad0ba933c61a8330aeee07.zip | |
Candidate 1.1 release.
* SampleAssetViewer now unconditionally loads the commandline-defined asset.
* Better error handling in AuthoringTool (stderr and user error handler).
* More consistent commandline switches in AuthoringTool and ApexImporter (--ll, --tx, --px flags).
* NvBlastExtAuthoring
** Mesh cleaner, tries to remove self intersections and open edges in the interior of a mesh.
** Ability to set interior material to existing (external) material, or a new material id.
** Material ID remapping API.
** Rotation of voronoi cells used for fracturing.
* Fixed smoothing groups in FBX exporter code.
* Impulse passing from parent to child chunks fixed.
* Reading unskinned fbx meshes correctly.
* Collision hull generation from fbx meshes fixed.
* Win32/64 PerfTest crash fix.
Diffstat (limited to 'sdk/extensions/physx/source/physics/NvBlastExtPxFamilyImpl.cpp')
| -rw-r--r-- | sdk/extensions/physx/source/physics/NvBlastExtPxFamilyImpl.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/sdk/extensions/physx/source/physics/NvBlastExtPxFamilyImpl.cpp b/sdk/extensions/physx/source/physics/NvBlastExtPxFamilyImpl.cpp index 530bbe3..09e26d4 100644 --- a/sdk/extensions/physx/source/physics/NvBlastExtPxFamilyImpl.cpp +++ b/sdk/extensions/physx/source/physics/NvBlastExtPxFamilyImpl.cpp @@ -118,8 +118,8 @@ bool ExtPxFamilyImpl::spawn(const physx::PxTransform& pose, const physx::PxVec3& for (uint32_t i = 0; i < actorCount; ++i) { PxActorCreateInfo& pxActorInfo = m_newActorCreateInfo[i]; - pxActorInfo.m_angularVelocity = PxVec3(PxZero); - pxActorInfo.m_linearVelocity = PxVec3(PxZero); + pxActorInfo.m_parentAngularVelocity = PxVec3(PxZero); + pxActorInfo.m_parentLinearVelocity = PxVec3(PxZero); pxActorInfo.m_transform = pose; pxActorInfo.m_scale = scale; } @@ -176,13 +176,15 @@ void ExtPxFamilyImpl::receive(const TkEvent* events, uint32_t eventCount) for (uint32_t j = totalNewActorsCount; j < totalNewActorsCount + newActorsCount; ++j) { - m_newActorCreateInfo[j].m_transform = parentPxActor ? parentPxActor->getGlobalPose() : m_initialTransform; + const PxTransform parentTransform = parentPxActor ? parentPxActor->getGlobalPose() : m_initialTransform; + m_newActorCreateInfo[j].m_transform = parentTransform; + m_newActorCreateInfo[j].m_parentCOM = parentTransform.transform(parentPxActor ? parentPxActor->getCMassLocalPose().p : PxVec3(PxZero)); //TODO: Get the current scale of the actor! m_newActorCreateInfo[j].m_scale = m_initialScale; - m_newActorCreateInfo[j].m_linearVelocity = parentPxActor ? parentPxActor->getLinearVelocity() : PxVec3(PxZero); - m_newActorCreateInfo[j].m_angularVelocity = parentPxActor ? parentPxActor->getAngularVelocity() : PxVec3(PxZero); + m_newActorCreateInfo[j].m_parentLinearVelocity = parentPxActor ? parentPxActor->getLinearVelocity() : PxVec3(PxZero); + m_newActorCreateInfo[j].m_parentAngularVelocity = parentPxActor ? parentPxActor->getAngularVelocity() : PxVec3(PxZero); m_newActorsBuffer[j] = splitEvent->children[j - totalNewActorsCount]; } |