Well, I am using Java3D, but have occasionally used Xith3D for a couple of app's... Anyway, yeah, I am keen to see what you have done. Post it if you can. I think a lot of people might benifit from it!

privatestaticStringnewName() {num++;return("GeneratedName"+num); }//this is from the old xith to ode converter that was located in org.odejava.xith3d.* or something like that.publicGeomTriMeshcreateTriMesh(TriangleArrayta, Stringname) {

I don't know anymore, but I think it was because I thought I might have to change it or so. But from this POV it now seems irrational. A reference would be better. Mmh maybe we could add this code to org.odejava.xith3d.Xith3DToOdejava ?

A totally different thing: my program can only convert BranchgroupS whose Shape3DS contain of TriangleArrayS.

um.. ähm I've noticed a big error in my code. In odejava it is not possible to add different Geoms to one GeomTransform (ofcourse not, but all these guys comparing GeomTransform with TransformGroups irritated me ) So now I can't simply return a PlaceableGeom, but a Vector of such Geoms, because such a BranchGroup can contain different TriangleArrays - so also different GeomTriMesh.

Here is the new code (I've changed it also to use org.odejava.xith3d.Xith3DToOdejava - I didn't before [yes I know now why], because I was to lazy to download the whole "[odejava] / odejava-xith3d / src" from cvs):

I didn't get to test it with an .obj file, because OBJLoader seems to have it's own issues with Mayaexported files.

2. can I collide 2 TriMeshES in Odejava? Ode documentation suggest's it works, butI couldn't get it to work. how would you implement the position cache that is mentionedin Ode documentation for two moving colliding TriMeshES in Odejava ?

mmh - yes it only works for normal TriangleArrays, if you want it to work also for IndexedTriangleArrays, simply add another if-block, where you transform the Xith representation to the ODEJava rep. I just was lucky, because I was able to use the predifined function in Xith3DToOdejava

I didn't get to test it with an .obj file, because OBJLoader seems to have it's own issues with Mayaexportet files.

I don't know, but I had only issues with textures and stuff using the OBJLoader, but, because only the geom data is needed, it might work. (I actually I have no experience with exporting .OBJ from Maya, so it could be a problem)

There are two files: SimpleExample.java and MeshBody.java . If you have Xith3D and Odejava installed, you shouldn't have problems compiling and running it. I also included the kiostudios loader for your convenience.

It's a TriMesh Cube colliding with a GeomBox. Now what's the big deal? Take a closer look at MeshBody.java and its constructor and try to move that line:

It should be included in one of the libs of the gamma project. Really.

Actually it belongs to ODEJava.+If you haven't deleted it (which I believe you did) then it would be in the gamma project already. (Like my terrainloader)But - didn't you say you don't want to use ODEJava?

It should be included in one of the libs of the gamma project. Really.

Actually it belongs to ODEJava.+If you haven't deleted it (which I believe you did) then it would be in the gamma project already. (Like my terrainloader)But - didn't you say you don't want to use ODEJava?

I think that "Loaders" and "Converters between raw geometry and ODEJava geometry" should be separated. So the loaders don't belongs to ODEJava (IMHO).I haven't deleted anything, I just changed of server We could add generic loaders one of these days.And you're right, I still don't want to use ODEJava. JOODE why not.

PS: I think this is obvious, but I think I should state it: This will only work for people who got Xith3d installed - Java3D and others won't be able to use this

Good idea arne. canyou modify them so they return raw geometry instead of xith nodes ?

Heah I don't that. I don't return Xith-nodes. I use Xith-nodes for input.

OK didnt know, but I mean so they returned general stuff ? like indexed geometry in a float array and a int array. Or similar with stripified geometry. The big job with loaders are to parse the files, I think it would be a shame to limit all that work to a single 3d library..They OBJ loader from sun is insane.. it just returns a java 3d scene object, theres no way you can get the geometry (unless you download their code and modify it..like I did he he )

java-gaming.org is not responsible for the content posted by its members, including references to external websites,
and other references that may or may not have a relation with our primarily
gaming and game production oriented community.
inquiries and complaints can be sent via email to the info‑account of the
company managing the website of java‑gaming.org