Various questions about 0.9 limitations

Backov

30-05-2007 00:35:40

I have some questions about the limitations of this version of the wrapper..

First off, I have track meshes that are dynamically generated. Am I going to be able to just throw those into NxOgre and have it bake up the collision structures for me? I sure hope so, otherwise I am in trouble.

Also, what's the problem with duplicate vertices? Several of my dynamically generated meshes have duplicate verts - they need them for texturing. NxOgre chokes on meshes with duplicate verts?

What happenned to the "Static Geometry" class? It seems to be gone - that's what i was going to use for my track.

betajaen

30-05-2007 00:46:50

1. Not at the moment, but I would like some constructor in the MeshShape so it'll handle a bunch of NxVec3's and NxU32 for vertices and triangles for things like this. It's pretty to do as well.

2. PhysX has a problem with duplicate vertices, not NxOgre. I could probably write an algorithm to remove the duplicate vertices for you, but it introduces laziness, just like people who dump entire "uncleaned" meshes into the ConvexShape and expecting it to work.

You should just create a duplicate track creating function, that just creates the track without texturing so it wouldn't have duplicated vertices, pass that into the future MeshShape constructor I said in point 1, and you should be good to go.

3. It never existed in the first place, the class in 0.6 was just a prototype with no actual code. In 0.9, I'll bring it back, but via a parameter ("node-static-geometry: yes") in the Body constructor.

Backov

30-05-2007 00:55:22

Ya I was reading the docs again and found the cooking interface, which is pretty much what I need. It looks like the code is in place to use it in NxOgre as well. Is there anything that would bite me in the ass there? I assume if I use NxCookTriangleMesh and save it out I can interface that with your class system easily enough.

It's been a week or two now since I've looked at the physics code, but it's starting to come back to me. I had to port my engine from XNA to Ogre first. :)

betajaen

30-05-2007 00:58:21

Pretty much. If you really wanted to you could run the Ogre Mesh to NxCookTriangleMesh to an NxTriangleMesh, then feed it into your own NxActor by created by hand.

I'd wait though, my solution would be neater. ;)