I work with big mesh files (up to 1 million polygons) imported from different file format. For simplicity I convert them to xml first then apply the converter to get binary mesh file.
The converter is very memory consuming as it loads the xml file entirely in memory before converting. It should be fine to load/unload it incrementally while building the geometry buffers...
OgreXMLConverter and big xml file
-
- Goblin
- Posts: 278
- Joined: Thu Mar 23, 2006 10:35 am
- Location: Toulouse, France
- Contact:
- Game_Ender
- Ogre Magi
- Posts: 1269
- Joined: Wed May 25, 2005 2:31 am
- Location: Rockville, MD, USA
I believe it currently uses tinyxml which is a dom based parser, that by its very nature always loads everything into memory. You would have to rewrite the the tool to use what I believe is called a SAX based parser.
Robotics @ Maryland AUV Team - Software Lead
- sinbad
- OGRE Retired Team Member
- Posts: 19269
- Joined: Sun Oct 06, 2002 11:19 pm
- Location: Guernsey, Channel Islands
- x 66
- Contact:
-
- Goblin
- Posts: 278
- Joined: Thu Mar 23, 2006 10:35 am
- Location: Toulouse, France
- Contact:
Of course I can, but it is far simple to go with XML :sinbad wrote:For very large meshes you would be better not to go via XML at all - can you not write your converter to go direct to binary via MeshSerializer instead of writing XML?
- my converter does not have to depend on Ogre
- my converter does not have to manage the evolution of the mesh file format (transfered to the OgreConverter)
- my converter has a small and comprehensive source code (even for a person that don't know Ogre)
What I should do is to copy the OgreConverter code as a base, you know, reinventing the wheel
-
- Goblin
- Posts: 278
- Joined: Thu Mar 23, 2006 10:35 am
- Location: Toulouse, France
- Contact:
- sinbad
- OGRE Retired Team Member
- Posts: 19269
- Joined: Sun Oct 06, 2002 11:19 pm
- Location: Guernsey, Channel Islands
- x 66
- Contact: