From: Byron W. <bsl...@mi...> - 2002-06-20 16:00:38
|
If you are looking for some code that parses the 3DS file format go here: http://www.gametutorials.com/Tutorials/OpenGL/OpenGL_Pg4.htm It's in C++ so you'll have to convert all the structs into classes and you'll also have flip bits to get the data from little endian to big endian. Here is another place, it's a Quake III model viewer in Java with full source. You can use the LittleEndianDataInputStream class to do the bit flipping dirty work. It's also an example on how to convert the data to something you can use in Java. http://md3view.fragland.net/ I recently wrote a Quake 2 model viewer/animator which also supports loading of milkshape3d ascii models (no skeletal animation yet) and was contemplating writing another loader of 3DS files.... just gotta find the motivation. One of the most challenging things was reading the data correctly, it's actually pretty funny view the results of an incorrectly parsed model :). When I am happy with the structure of the code I'll be releasing the source. If you choose to use XML as a model format it would be cool to convert known model formats into a similar XML format. Just a thought. Oh yeah, here is a link to the unofficial 3DS file format : http://www.the-labs.com/Blender/3DS-details.html -Byron -----Original Message----- From: gl4...@li... [mailto:gl4...@li...]On Behalf Of Drake Woodring Sent: Thursday, June 20, 2002 7:24 AM To: gl4...@li... Subject: [gl4java-usergroup] xml 3d file format I have been looking around for a decent file format that I could parse for some objects I want to define. Originally I wanted to go W3D or 3DS formats since I already had some models that would be way cool to use. (anyone know of a parser for these? of a good reference to the file format?) I decided to start a simple XML file format. I haven't decided on the schema yet. If nobody else is interested in it, I will probably just make the schema to follow my engine. Since the project I'm working on is open source... and I would do it anyway... I would like to create a simple expandable parser for others to use also. Does anyone want to give input? Or anyone know any good ascii based file formats I could follow (for name and feature lists). thanks ps... everything is going to xml anyway.... why not this? ------------------------------------------------------- Bringing you mounds of caffeinated joy >>> http://thinkgeek.com/sf <<< _______________________________________________ gl4java-usergroup mailing list gl4...@li... https://lists.sourceforge.net/lists/listinfo/gl4java-usergroup |