fbx triangle mesh calculation

Discuss any questions about BEPUphysics or problems encountered.
Post Reply
thiago
Posts: 22
Joined: Sat Oct 16, 2010 10:32 pm

fbx triangle mesh calculation

Post by thiago »

is there any problem with the fbx automatic extraction of the .fbx models ?
i used that with lots of .x models and everything works good, when i changed to .fbx some models dont works correctly

iam using

Code: Select all

            StaticTriangleGroup.GetVerticesAndIndicesFromModel(model, out vertices, out indices);
            triangleMesh = new TriangleMesh(vertices, indices, 0.05f);
            triangleGroup = new StaticTriangleGroup(triangleMesh);
            triangleGroup.WorldMatrix = Matrix.CreateScale(Scale) * Matrix.CreateTranslation(pos) * Rotation;
to construct the object, but it dont colides with nothing ? Again, with .x models, everything works wonderfull !!!
Norbo
Site Admin
Posts: 4929
Joined: Tue Jul 04, 2006 4:45 am

Re: fbx triangle mesh calculation

Post by Norbo »

The BEPUphysics demos all use .fbx files for models, so it shouldn't be a universal problem.

If you are deploying to a WP7 device, make sure you're using the latest BEPUphysics version compatible with the XNA 4.0 RTM.

Otherwise, the BEPUphysicsDrawer that comes in the BEPUphysicsDemos source has a triangle mesh drawer in it which is used to draw things like StaticTriangleGroups. You could use it to visualize the problem and see what it is doing.
thiago
Posts: 22
Joined: Sat Oct 16, 2010 10:32 pm

Re: fbx triangle mesh calculation

Post by thiago »

thanks, i looked at BEPUphysicsDrawer and i got the problems
it was my fault ;) , i exported the model in 3ds with wrong parameters ....
Post Reply