PxCreateFoundation error

I’m getting error during creation of m_Foundation. I’m using x86 debug libraties (PhysX3DEBUG.lib).

Error which I’m getting is about 16-byte alignment when triggering assert in PxDefaultAllocator. All libs are in pragmas in my own header wrapper.
PhysX libraties version is 3.2.4. My CPU is i7 3630QM, with GF 660M (integrated intels gpu is off btw).

class PhysXWrapper {
(...)
private:
  PxDefaultErrorCallback gDefaultErrorCallback;
  PxDefaultAllocator gDefaultAllocatorCallback;
(...)
}

PhysXWrapper::init() {
   printf("initializing PhysX\n");
    printf("creating Foundation\n");
   // create foundation object with default error and allocator callbacks.
   m_Foundation = PxCreateFoundation(PX_PHYSICS_VERSION,gDefaultAllocatorCallback,gDefaultErrorCallback);
(...)

gDefaultErrorCallback & gDefaultAllocatorCallback are initiated, pointers to their structure looks valid.

Hi,

I dont know which version I had (PhysX 3.2.x) but I had similar problems -
you should check your error/warning messages.

When I remember correctly, the error was the PX_PHYSICS_VERSION - the PxCreateFoundation(…)
need another value than PX_PHYSICS_VERSION - the number should be in the log.

It was only in one of the PhysX 3.2.x version - its a little versionising bug from Nvidia I guess.
After I wrote the “hard” number of the version into PxCreateFoundation(…) and maybe also
in PxCreatePhysics and PxCreateCooking everything works again.

Now I use the PhysX 3.3.x - so I dont have this error.

Update to 3.3.x resolved problem. I didn’t checked PX_PHYSICS_VERSION, just replaced libraty with some code refactor.

Thank you.