mesh.xml to ASE converter

A place for users of OGRE to discuss ideas and experiences of utilitising OGRE in their games / demos / applications.
mac
Kobold
Posts: 34
Joined: Wed Jun 25, 2003 5:17 pm
Location: Berlin, Germany

mesh.xml to ASE converter

Post by mac »

I have written a simple Perl program that converts the mesh.xml format from Ogre to 3ds ASCII format (ASE). It is very limited and cannot handle all types of meshes. Here an example where I used Gile[s] (which can import ASE) to add a static lightmap to the well known ogrehead. Then I exported it with the ogre exporter from walaber and made a screenshot using the meshviewer:

Image

I couldn't resist do do a little paintwork on the lightmap layer (with gile[s] you can do that). Note that it is strawberry jam in this case... although ogres are known to eat human flesh... ;)

Probably this is not very useful for most people, cause they use other formats... But it would be possible to write a dotscene to ase converter - which would be interesting for more people...

If anybody is interested in the Perl code, I am willing to share it...

Cheers, mac

[Edit]ogre exporter for gile[s]...[/Edit]
User avatar
sinbad
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 19269
Joined: Sun Oct 06, 2002 11:19 pm
Location: Guernsey, Channel Islands
x 66

Post by sinbad »

If it's a perl script, you could post it on the wiki - then people could enhance it if they wanted.
mac
Kobold
Posts: 34
Joined: Wed Jun 25, 2003 5:17 pm
Location: Berlin, Germany

Post by mac »

I guess the code is a bit too long for the wiki and it consists of 3 different files...

Anyway, here is the link: mesh2ase.pl

Everybody is invited to improve this... but I think it makes more sense to rewrite it in c++. Then you could use the routines provided by Ogre to load the mesh. At least it can serve as a good start.

Enjoy, mac