- Install the exporters with the installer.
- From Max or Maya:
- From Maya, simply go to File->Export All, then select FxOgre Files (*.Mesh)
- From Max, go to File->Export, and select Ogre (*.MESH)
Note: you can change the .MESH and .SCENE files that are associated with a particular .facefx file with the Actor->Change Render Asset option. The render asset is the name of the .MESH or .SCENE file to look for without the file extension. FaceFX will look for a .SCENE file first, and fall back on the .MESH file. FaceFX Studio will look in the .facefx file directory, as well as the My Documents\FaceFX Studio 20XX\Ogre\Resources\Meshes and Scenes directories.
- Meshes/Textures do not show up properly.
- The MATERIAL file that is exported may need some tweaking by hand to achieve the correct lighting, transparancy, and UV coordinate scaling/rotation. It is a simple text file format.
- A common problem from Max and Maya where textures are transparent causing meshes to be invisible can be resolved by removing the "depth_write off" line from the material file
- The character comes in oriented incorrectly.
- The .SCENE file is responsible for orienting the character. All files exported from Max contain a rotation node like the one below immediately above the node responsible for displaying the character. Changing the rotation will change how the character is oriented.
- <rotation axisX="1" axisY="0" axisZ="0" angle="-90" />
- The lighting is incorrect.
- The .SCENE file is responsible for lighting. If no lights are found, or no scene file is found, a light is attached to the default camera so anything it looks at will be lit. Shadows can be seen by creating a camera other than the default camera. Creating customized lighting is difficult but possible by exporting a .SCENE file that has lights and tweaking the .SCENE file to achieve the desired result.
- If meshes are being lit from the wrong direction, negative scale or a mirrored mesh may be causing a reversal of the winding order of the triangles. From 3ds Max, applying a normal modifier, and resetting xforms before skinning and before export is recommended.
- .MESH - A binary file (convertible to XML) that defines the mesh.
- .MESH files must be in the same folder as the .facefx file, or somewhere else in the Ogre path like the .\Ogre\Resources\Models folder
- The .SKELETON file is referenced by name inside the MESH file, so renaming the skeleton and mesh files will not work.
- .SKELETON - A binary file (convertible to XML) that contains the skeleton and animation data. No animations are exported by default as there is currently no support for OGRE animations in FaceFX Studio.
- .SKELETON files must be in the same folder as the .facefx file, or somewhere else in the Ogre path like the .\Ogre\Resources\Models folder
- .MATERIAL - Material files are text files that specify the location of textures, material parameters, and even pixel shaders for a group of named Ogre materials. These files can require some tweaking by hand to get the content looking exacly like it does in the source package. Ogre materials are named and they must be unique or OGRE will fail to load. For this reason, the FaceFX Ogre exporters prepend the .MESH name in front of the Material name to avoid collisions. All Ogre materials in all .MATERIAL files in the following locations will be loaded when a .facefx file is opened:
- "My Documents"\FaceFX 20XX\Ogre\Resources\Materials\Scripts
- The folder that contains your .facefx file.
- .SCENE - an OC3 Entertainment XML file with a format very similar to that defined here. .SCENE files exported from exporters other than the ones that ship with FaceFX Studio may or may not create a .SCENE file that works with FaceFX. Nested nodes are not supported. The purpose of a .Scene file are:
- Specify the lighting to be loaded by FaceFX Studio (no lights will result in a light being attached to the default camera).
- Specify light types, light positions and orientations, light intensity values, etc.
- Specify meshes to be loaded by FaceFx Studio
- Specify if the meshes should cast shadows. Depending on the .Material file, shadows may not look right.
- Change default positions and rotations of meshes so that they are oriented correctly in FaceFX Studio. For example, Max content needs to be rotated by -90 degrees in the X axis to be viewed properly in Ogre.
- Identify the primary mesh that will be animated by FaceFX Studio. This is the first mesh listed in the .SCENE file. All other meshes are static. Morph targets in this mesh will be hooked up to morph target nodes in the face graph, and the .skeleton file specified by this mesh will be animated by the bone poses in the .facefx file. You can't animate multiple meshes with the same .skeleton file. Multiple meshes should be combined before export (FaceFX exporters will do this automatically).
- Texture Files - Texture files are copied to the export folder.
- The .MATERIAL files do not specify a location for the textures, so all textures must be in the same folder as the .facefx file or somewhere else in the Ogre path like .\Ogre\Resources\Materials\Textures folder.
While not always required, the below steps are recommended:
- Reset XForm from the Utility menu. Do this prior to skinning your character, and prior to exporting it if posssible.
- Collapse the modifier stack form the Utility menu immediately prior to skinning. Not all modifiers and combinations of modifiers are supported by the exporter (for example morph targets can not be exported after you smooth the target mesh).
While not always required, the below steps are recommended:
- Turn off any custom shaders or custom plugins prior to export.
- Delete the history immediately prior to weighting the vertices to the bones.
- If you have IK or other constraints in your file, you may have to turn them off with the Modify -> Evaluate Nodes ->Ignore All option.
Maya outputs log information to the output window. The 3ds Max plugin attempts to write its log to the following location. The folder must exist for the log to be written.
My Documents\FaceFX Plugins\Ogre Exporters\FxOgreMaxExporter_Log.txt
Both the Max and Maya Ogre exporters can be used in conjunction with a script GUI for more advanced use.
The Max and Maya exporters are both licensed under the LGPL. The Maya Exporter is (C) 2006 by Francesco Giordana, and it was modified for use with FaceFX and ported to 3D Studio Max by OC3 Entertainment. Source code to the exporters can be found in the FaceFX Tools Installation directory and is also available upon request.
FaceFX uses standard Ogre files (only the .SCENE file described above is not natively used by OGRE), and use of 3rd party Ogre exporters is possible. OgreMax is a good place to go for XSI exporters for example. The Ogre Artist and Content Creators Forum is the best place to learn more about the exporters available.
Note: There are lots of ways to create content, and we want to support as many of them as possible. If your content doesn't export well, please let us know about it. Even if you find a good workaround, tell us about it and tell us the workaround, too.