Mainly to get up to speed with Ogre I made a couple of changes to the XSI exporter to get it to work with CVS HEAD as at 7 Jan 2005. I've noted them here just in case anyone wants to try it:
(1) In OgreXSIMeshExporter.cpp replace the lines in exportMesh() up to
DefaultHardwareBufferManager *hardwareBufMgr = new DefaultHardwareBufferManager();
with this:
Ogre::Root* root = new Ogre::Root();
root->showConfigDialog();
root->saveConfig();
root->initialise( false, "whatever" );
LogManager logMgr;
MeshManager& meshMgr = Ogre::MeshManager::getSingleton();
It seemed to me necessary to create the Root object so that the necessary singletons are created - could be wrong here.
Then change:
Mesh* pMesh = MeshManager::getSingleton().createManual("XSIExport");
to this, adding a dummy 2nd parameter
MeshPtr pMesh = MeshManager::getSingleton().createManual("XSIExport", "GroupName" );
(2) In OgreXSIHelper.h there seems to be a bug converting the XSI file name to an Ogre string. At line 51 add this:
tmp[c] = 0;
after the call to wcstombs()
(3) I also had to copy zlib1.dll to my C:\Softimage\XSI_4.0_Foundation\Application\bin directory.
(4) I could not see how to initialise the Ore::Root without a renderer, so in the C:\Softimage\XSI_4.0_Foundation\Application\bin bin directory I put a plugins.cfg file in which the only plugin is RenderSystem_GL. No other plugins are required. You also need to copy OgrePlatform.dll to the C:\Softimage\XSI_4.0_Foundation\Application\bin directory.
---
Using the XSI Exporter with CVS HEAD
-
- Gnoblar
- Posts: 6
- Joined: Mon Jan 03, 2005 1:19 am
Using the XSI Exporter with CVS HEAD
Last edited by klepto on Fri Jan 07, 2005 3:23 am, edited 1 time in total.
- sinbad
- OGRE Retired Team Member
- Posts: 19269
- Joined: Sun Oct 06, 2002 11:19 pm
- Location: Guernsey, Channel Islands
- x 66
- Contact:
-
- Gnoblar
- Posts: 6
- Joined: Mon Jan 03, 2005 1:19 am
It does export a mesh, which can be be displayed in Ogre 0.15.1, although some of the vertices seem to be drawn in the wrong order, or maybe some tris are created from the wrong vertexes.
I'm just trying to build the MeshViewer added in HEAD at the moment.
Is the mesh format the same in HEAD and 0.15.1. ?
I'm just trying to build the MeshViewer added in HEAD at the moment.
Is the mesh format the same in HEAD and 0.15.1. ?
- sinbad
- OGRE Retired Team Member
- Posts: 19269
- Joined: Sun Oct 06, 2002 11:19 pm
- Location: Guernsey, Channel Islands
- x 66
- Contact:
Yes, the 0.15.1 mesh format is the same in HEAD.
My TODO list is always bursting, but spending more time on XSI is definitely there. Because it's separate from the rest of 1.0.0 (and can be back-ported to 0.15.x) I'm currently leaving it till later in the list, since it not being finished won't stop 1.0.0 being released; it can be refined as we go on.
My TODO list is always bursting, but spending more time on XSI is definitely there. Because it's separate from the rest of 1.0.0 (and can be back-ported to 0.15.x) I'm currently leaving it till later in the list, since it not being finished won't stop 1.0.0 being released; it can be refined as we go on.