Panda PhysX


#7

I’m on Windows. When I type that command in, I get the same as before.
The output of the console is this:

DirectStart: Starting the game. 
Warning: DirectNotify: category 'Interval' already exists 
Known pipe types: 
  glxGraphicsPipe 
(all display modules loaded.)
:util(warning): Adjusting global clock's real time by 1.8599e-005 seconds.

And the Panda window is still unresponsive.


#8

Of course it is still unresponsive. You didn’t change anything. Running it from the command prompt is purely to collect information. Now I know WHERE it hangs. Next I want to find out WHY it hangs.

So please provide some more information. Starting with your OS (version, service pack), the Panda3D version (did you compile yourself?), Panda PhysX version (there are already two, yay!). What I am most interested in is you PhysX System Software version, the PhysX info and settings from the Windows Controll Panel and please create a logfile from the “extended diagnosis” if you can (depending on your hardware you don’t have this option). How did you install the PhysX System Software (standalone or included with the NVIDIA graphics drivers), and what is your graphics card and which driver version do you have?

enn0x


#9

I am running (as reported in system properties)Windows XP Media Center Edition 2002 SP2, Panda3d 1.5.3 Windows binaries, PandaPhysX 0.4.1, PhysX system software 08.09.04, installed with the Geforce PhysX for 8800s update, running in GeForce PhysX mode on my 9600GSO(8800GS rebranded), running forceware 178.13, and the extended diagnosis is only available to real physX cards.


#10

Back again. I would try to uninstall the “NVIDIA PhysX v8.09.04” via Control Panel (but not the “NVIDIA Drivers”), and then re-install it again. The PhysX System Software alone can be downloaded from from the NVIDIA page above. If this doesn’t help try to use an older PhysX System Software version, for example v8.04.25. I have heard rumors that the combined installer has some problems.

But before you do please download the following dll and replace it with your version. It adds a few debug outputs at the time of engine initialization. Then run this small script and post the console output:

http://enn0x.p3dp.com/libpandaphysx.pyd

from pandac.PandaModules import loadPrcFileData
loadPrcFileData( '', 'notify-level-physx spam' )

#import direct.directbase.DirectStart

print '--pre--'
from libpandaphysx import PhysEngine
print '--post--'

enn0x


#11

Looks like I need to redownload. (should I get the sdk?)

--pre--
:physx(spam): init module
:physx(spam): @enter: _sdk=00000000

Also, (this may or may not be useful information) the physx demos, including the water physics demo, work fine.

EDIT: I reinstalled the system software, and it still hangs after:
:physx(spam): @enter: _sdk=00000000
Maybe I need to wait longer for the import to complete?
Or do I need the SDK.


#12

I don’t think that the SDK will help. Please try to disable hardware acceleration in PhysX settings, and if this does not help try to install the older PhysX_8.04.25_SystemSoftware.exe driver:

http://developer.nvidia.com/object/physx_archives.html

enn0x


#13

BMCha, how could you get glxGraphicsPipe on Windows ?


#14

Success! Disabling Geforce PhysX worked. Thanks for all the help.

And I don’t exactly understand you question ynjh_jo. That refers to Panda using OpenGL to display, right?


#15

Up to v1.5.3, on Linux, it’s glx.
On Windows, it’s wgl or wdx.


#16

Now I remember, I didn’t feel like typing all the generic console messages, so I found someone’s console log and copied in the first few lines. For me it actually is wgl, though.


#17

Glad it works now, but it’s not yet “success”. Current state is that some users (you are the only one so far :slight_smile: can’t use hardware accelleration even if it should be possbile on their hardware. Not a satisfying status for me.

I will try to find a solution, but move this to PM until we have a result.

No need to typ everything.
In the console window, upper left corner of the window decoration, there is a icon, and the icon has a context menu. Select “Properties”, and in the properties window enable “Quick edit mode” and “Insert mode”. Then you can mark text with your mouse and copy it by pressing the “enter” key.

enn0x


#18

Hi enn0x,

Thanx for all the effort you are putting into this. I am just wondering, does the current version of your work support cloth simulations? or not yet?


#19

Not yet. It’s on my todo list, but somewhere in the middle. Next things will be vehicles and more maintenance for basic features. I don’t want to propose a date, but maybe around christmas.

enn0x


#20

http://enn0x.p3dp.com/libpandaphysx_0.4.2.zip (3.3M)

Another maintainance release. Also some code cleanup has happened and some new features have been added:

  • Adds overlap testing (sphere, capsule).
  • Adds shapeType parameter to raycasting and overlap testing.
  • Classes without PUBLISHED methods get now wrapped too, e.g. PhysConvexShape.
  • Adds a method to set ShapeFlags on shape descriptors.
  • Adds methods to set the global position & orientation on PhysActors.
  • Adds methods to set the maximum angular velocity on PhysActors.
  • Adds methods to set/get the skin width of a shape or shape descriptor.
  • Adds wheel shapes (PhysWheelShape, PhysWheelShapeDesc).
  • Adds contact reporting.
  • Adds methods to query/control sleeping of PhysActor.
  • Fixed a bug in PhysController.setH().
  • Adds documentation for several more methods.

(see included file doc/RELEASE-NOTES.txt)

The included binaries are built for Panda3D-1.5.4.

enn0x


#21

I’m in need of some help with the cooking process. When cooking a custom model, the kitchen returns a status of 1, so it does work. But when loading the model in the convex sample (04_Convex.py), I replace the tetra model with my custom model, I get these assertion failures:

I am quite new to Panda, Python and PhysX, but just editing a filename can’t be the problem, must be the model. The egg model was exported from 3dsmax 8.
Please help.


#22

There are three possible problems:

1.) How did you cook the mesh? Using PhysKitchen( ).cookTriangleMesh or using PhysKitchen( ).cookConvexMesh? If you open the .nxb file created by the Kitchen, what are the first characters (“NXSMESH” or “NXSCVXM”)?

2.) The implementations of the Kitchen methods are not very clever, they just try to find vertices and use them as a vertex cloud. This is fine for simple meshes. Maybe the Max exporter has some features which cause problems. Can you send me the .egg file for analysis?

3.) Problems with the filepath. I assume you checked this already.

enn0x


#23

Ok…

  1. It’s using cookTriangleMesh.

  2. I tried the steps.egg model that comes with your samples.

  3. Yip, checked the paths. I believe it would give a different error for this though, would it not? The start in path is same as the 04_Convex.py file’s folder.


#24

If you cook something as a triangle mesh then you have to load it again as a triangle mesh. If you cook something as a convex mesh then you have to load it as a convex mesh.

Triangle meshes and convex meshes are not the same binary files, even though I use the same filename extension (.nxb) for both in my samples. You can use different extensions if this helps you keeping your models organized.

Please note that triangle meshes are for static geometry (things that never move), and convex meshes are for dynamic geometry (things that move around in the scene).

enn0x


#25

Thanks, I’m getting things to work now, finally.

Just want to know…
When I want to use a shape like the capsule, does my model have to be centered over the origin, or must it be placed above the origin? Is there a way to set the direction of it?


#26

I don’t understand your question, sorry. Can you elaborate a little bit about what you mean with “model” and “origin”? Best would be to use Pand3D or PandaPhysX class names.

You mean the NodePath assigend to a PhysActor, or the PhysShape added to the PhysActor?

“Origin” is a property of a coordinate system. There are several coordinate systems involved, for example the global CS or rendered geometry (NodePath “render”), the local CS of a NodePath (relative to it’s parent NodePath), the CS of the PhysScene, the global CS of a PhysActor (relative to the PhysScene), the local CS of a physShape (relative to PhysActor), just to name the most important ones.

enn0x