NXS Body

mahdie9

28-08-2011 19:39:07

Hi all,
Im a newbie in NxOgre.
When I want to create a body using a .nxs mesh file it crashes.

NxOgre::Mesh * khiaboonmesh = NxOgre::MeshManager::getSingleton()->load("file://khiaboon.nxs");
Critter::KinematicBody * str = mRenderSystem->createKinematicBody( NxOgre::TriangleGeometryDescription(khiaboonmesh) , NxOgre::Matrix44::IDENTITY , "khiaboon.mesh" , Critter::BodyDescription() );


any help is appreciated.

PS: I cannot convert it to convex mesh. I tried Flour and GD_VRD and both had difficulties in the process.

betajaen

28-08-2011 20:46:25

Can't use Triangle Meshes in anything but StaticGeometries.

It crashes when converting to a Convex shape, probably because it's not a convex shape.

mahdie9

29-08-2011 07:14:37

So, is there anyway that I can reduce the number of vertices of the ogre mesh?
I know about the convex vertex limitation and my mesh is a huge one which i dont have access to its 3ds model.

betajaen

29-08-2011 07:32:05

Not without doing it through a 3D modeller.

mahdie9

29-08-2011 18:44:04

I have now got a hand on the original 3ds model.
After a few changes in the number of vertices, it is now clear for converting to nxs.
I've also installed the physx plugin for 3ds max, but it only exports the scene in 3 forms of xml , nxb and dae which I don't think are suitable for being converted to nxs. (The xml output file can not be read by the ruby script!)
My problem here is that the flour source code I've compiled against physx-2.8.4 crashes through the converting process.
As all the nxogre.org links are broken, it is not possible for me to obtain the binary version of flour.
I wonder if anyone here can send me a working binary of their flour source code with the proper dll files, so I can use it to convert my meshes into nxs files.
It would be a great help to me in my project process, because it is almost a week that I'm stuck in this step.
Thanks in advance :)

betajaen

29-08-2011 19:06:24

Have a read of this;

viewtopic.php?f=6&t=13773

It tells you where to download anything, and answers most things.

p.s. XML is Ogre XML. Not just any XML file.

mahdie9

30-08-2011 08:40:25

I really should have missed the ending part of that post. my mistake.
But now I've come to the worst part.
Flour outputs emty .nxs files when converting to convex.
but it is ok with converting to triangle.
I've already read all the forum on this problem.
I've installed proper physx-software-system and ogrexmltoflower ruby script works fine in making the .flower files.
Any help?

mahdie9

30-08-2011 08:46:59

Something else,
When I run:

flour.exe test


it outputs:

*Creating world
*Creating scene
*Creating Actor


then it crashes.
I've added my physx-2.8.4 dll files to the directory. what is wrong with my work?

mahdie9

30-08-2011 08:55:50

And:
Can you please show a one-line code how to create a static actor and give it a mesh?
I'm going to create a floor which is not flat and also has various slopes.
Critter::KinematicBody does not accept triangle meshes. showing a runtime error that it can not attach triangle mesh to dynamic actors.