Mesh Format Specification?

Problems building or running the engine, queries about how to use features etc.
Post Reply
Slinky730
Gnoblar
Posts: 2
Joined: Mon Mar 05, 2007 6:09 am

Mesh Format Specification?

Post by Slinky730 » Mon Mar 05, 2007 6:11 am

Hey, there. I'm certain this has to be somewhere in the forums or documentation, but I've been searching for two days now, and everything's come up dry. Is there a nice piece of documentation for the OGRE mesh format? Not having to dissect the code would be awesome.

Thanks!
0 x

User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US

Post by xavier » Mon Mar 05, 2007 6:24 am

The XML format is described in ogrenew/Tools/XmlConverter/docs. The binary format is always subject to change at any time, which is why it's not documented. If you need to read/write it, just use the Ogre::MeshSerializer class.
0 x
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.

Slinky730
Gnoblar
Posts: 2
Joined: Mon Mar 05, 2007 6:09 am

Post by Slinky730 » Mon Mar 19, 2007 7:52 pm

The reason I was asking is I was under the impression that it was a completely open format? It seemed like a more convenient choice than md2 for a non-OGRE project. What sort of license is the format under? LGPL, right?
0 x

User avatar
haffax
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 4823
Joined: Fri Jun 18, 2004 1:40 pm
Location: Berlin, Germany
Contact:

Post by haffax » Mon Mar 19, 2007 8:23 pm

The format itself doesn't need a license. You are free to use it for you own project, but of course you are not free to derive your implementation of a loader from the Ogre source, unless you stick to the LGPL terms. Implementing a loader of your own from scratch is ok and a few sneaky peeks at Ogre's source are covered by most countries copyright laws too.

The binary format is tersely documented.
You'll find all you need in ogrenew/OgreMain/include/OgreMeshFileFormat.h

The file format is versioned, newer versions can come up without notice, but they are identifyable by their header.
0 x
team-pantheon programmer
creators of Rastullahs Lockenpracht

User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US

Post by xavier » Mon Mar 19, 2007 8:31 pm

Slinky730 wrote:The reason I was asking is I was under the impression that it was a completely open format? It seemed like a more convenient choice than md2 for a non-OGRE project. What sort of license is the format under? LGPL, right?
The .mesh format is optimized for Ogre's consumption -- you can use it for other purposes I suppose but I don't really see why you would. If you just want a general binary mesh format, creating your own is fairly straightforward.
0 x
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.

User avatar
sinbad
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 19261
Joined: Sun Oct 06, 2002 11:19 pm
Location: Guernsey, Channel Islands
Contact:

Post by sinbad » Tue Mar 20, 2007 12:19 pm

Someone else ripping our mesh file format? Jeez ;)

The format is open in that you can see the guts quite easily but the structure is subject to change at our whims. We have serializer classes that handle all the binary work and manage things like upgrading previous versions of the mesh format automatically, so we always tell people to use those classes and not access the binary format directly. If you want to directly use the binary format that's your choice, but don't expect us to support it.

In design terms the binary format is an implementation, not an interface - the interfaces are the serializer classes and the XML format. So we reserve the right to change the implementation any time we like.
0 x

Post Reply