aboutsummaryrefslogtreecommitdiff
path: root/samples/SampleBase/physx/PhysXController.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'samples/SampleBase/physx/PhysXController.cpp')
-rwxr-xr-xsamples/SampleBase/physx/PhysXController.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/samples/SampleBase/physx/PhysXController.cpp b/samples/SampleBase/physx/PhysXController.cpp
index cc9ade0..1f91d1d 100755
--- a/samples/SampleBase/physx/PhysXController.cpp
+++ b/samples/SampleBase/physx/PhysXController.cpp
@@ -52,7 +52,6 @@
#include "PxRigidDynamic.h"
#include "PxRigidStatic.h"
#include "PxMaterial.h"
-#include "PxFoundationVersion.h"
#include "PxMath.h"
#include <imgui.h>
@@ -110,7 +109,7 @@ void PhysXController::onTerminate()
void PhysXController::initPhysX()
{
- m_foundation = PxCreateFoundation(PX_FOUNDATION_VERSION, NvBlastGetPxAllocatorCallback(), NvBlastGetPxErrorCallback());
+ m_foundation = PxCreateFoundation(PX_PHYSICS_VERSION, NvBlastGetPxAllocatorCallback(), NvBlastGetPxErrorCallback());
m_pvd = PxCreatePvd(*m_foundation);
@@ -139,11 +138,11 @@ void PhysXController::initPhysX()
sceneDesc.gravity = PxVec3(0.0f, -9.81f, 0.0f);
m_dispatcher = PxDefaultCpuDispatcherCreate(4);
sceneDesc.cpuDispatcher = m_dispatcher;
- sceneDesc.gpuDispatcher = m_cudaContext != NULL ? m_cudaContext->getGpuDispatcher() : NULL;
+ sceneDesc.cudaContextManager = m_cudaContext;
sceneDesc.filterShader = m_filterShader;
sceneDesc.flags |= PxSceneFlag::eENABLE_STABILIZATION;
sceneDesc.flags |= PxSceneFlag::eENABLE_PCM;
- if (sceneDesc.gpuDispatcher == nullptr)
+ if (sceneDesc.cudaContextManager == nullptr)
{
m_gpuPhysicsAvailable = false;
m_useGPUPhysics = false;