ASE loader and objects

I like to use xith3d for my project and I am creating my scenes which can be exported as ASE files. I know that the GROUP feature is not implemented which is a bit of problem but I try to get round it.

But, once I load my scene (as ASE) into the world, can I then move around individual objects that I have in the ASE progarmaticaly?

For example, if I have a ball, how can I start moving it using cursor keys?

goosebump

Yes you can move parts of a model. You can give parts of the model names when you create them. These names can be retrieved by using the method AseFile.getNamedNodes(). The nodes are BranchGroups, so you can insert TransformGroups or whatever you want as parents of them in the scenegraph. Have a look at the tutorial about geometry loaders.

I don’t understand the example with the ball, because the ball is a model on its own, isn’t it?

Thanks, I check out the tutorial. Regarding ball, ASE is normally used to export the whole scene including many models in it (its too heavweight to use for a simple model like a ball which should really be a primitive).
I have many objects in the scene that I want to move around.

If the practice is to export each as ASE, then can you load multiple ASE’s into the same world? If yes, then how do you link them to the universe?

goosebump

Is there a tutorial on how to move objects around in xith?

g.

[quote]Is there a tutorial on how to move objects around in xith?

g.
[/quote]
Yes, there’s a section about interaction in the Getting Started Guide. If you have some time, download the PDF-version of the GSG (see my signature for links) and read through the sections.

[quote]Thanks, I check out the tutorial. Regarding ball, ASE is normally used to export the whole scene including many models in it (its too heavweight to use for a simple model like a ball which should really be a primitive).
I have many objects in the scene that I want to move around.
[/quote]
Why do you think ASE is “heavyweight”? I’m not sure if there is really such a significant difference between having several small ASE models and one large model. If you have the same materials several times, you save some bytes. What are other advantages?

[quote]If the practice is to export each as ASE, then can you load multiple ASE’s into the same world? If yes, then how do you link them to the universe?
[/quote]
It’s up to the programmer if he wants to have several small ASE files or one large file. Xith3D supports both. Loading several ASE files is easy, because you can insert them as BranchGroups in the scenegraph.

Great, I checked out your tutorial on interaction and its pretty good. My reluctance to use ASE for small models is that each ASE file carries a lot of scene information as we all as the model information. So you end up getting rid of a lot of stuff. I guess you dont have to read it all and this is one way of stream lining it. But If we had something like Milkshape model, then we only carry the model information.

Anyways its good that I can load up multiple ASE’s and put them all in the same Scenegraph as branchgroups.

How easy is it to add a terrain to the scenegraph?
goosebump

[quote]Great, I checked out your tutorial on interaction and its pretty good. My reluctance to use ASE for small models is that each ASE file carries a lot of scene information as we all as the model information. So you end up getting rid of a lot of stuff. I guess you dont have to read it all and this is one way of stream lining it. But If we had something like Milkshape model, then we only carry the model information.
[/quote]
The xith-tk (sub)project hosts various loaders for Xith3D. If you need an md3 loader you have to search this forum a bit.

[quote]How easy is it to add a terrain to the scenegraph?
[/quote]
It depends on if you need random generated terrain or static terrain. For the first case there’s a demo in the Xith3D source. For the latter one I guess you create a large model file and load it. (I think performance wise you need octree or something.) Terrain following is not implemented in Xith3D currently. I’d like to have more information (e.g. a demo/tutorial) about this myself. Would be great if someone, who has already made some experience, could do this. ::slight_smile:

Thanks for that. I saw a few loaders there which are good to use. I tried to download the AC3D loader but there is a problem and the file can not be found. I wonder if the link is broken.

On the terrain stuff, I really like the “terrain following” which I guess uses some kind of collision detection, but have not done one myself ???. So I guess the terrain example (which I havent run at the moment) has no collision detection and you can basically go through the terrain (I mean to the other side of it).

goosebump

You really should run the demo - it does have terrain following.

Since it’s JWS enabled - running it is not much more than a click… Goto http://xith.org/demo/

Did you download the AC3D loader from here: https://xith-tk.dev.java.net/servlets/ProjectDocumentList?folderID=403 ?

The very nice thing I find with ASE files is the ability to load them in a text editor and edit them (good when the loader doesn’t support groups, or for removing absolute paths).

Will.

As a side note, AC3D and OBJ are both text editable also. :slight_smile:

Kev

[quote]I tried to download the AC3D loader but there is a problem and the file can not be found. I wonder if the link is broken.
[/quote]
Hi
The zip file had the wrong permissions, fixed it now.

Cheers

Endolf

[quote]You really should run the demo - it does have terrain following.
[/quote]
Great, it does have terrain following. I wonder if I can put an object in the world say a box and then move the box round the terrain and see how it behaves.

[quote] The zip file had the wrong permissions, fixed it now.
[/quote]
Thanks for fixing it, I have now downloaded the file.
goosebump