The ogreexport script exports Blender meshes and armatures to Ogre -XML files. Using the OgreXmlConverter command line tool from the ogrenew/Tools/XMLConverter directory of your Ogre installation, these -XML files can be further converted into .mesh and .skeleton files.
Blender has two notions of material: Materials as displayed in the rendering engine and materials as displayed in the game engine. The script option "Game Engine Materials" let you choose which material properties should be converted. The export script already supports a multitude of material properties, most notably: ambient, diffuse, specular, emissive, UV textures with and without alpha channel, vertex colours, normal maps, two sided faces. Support for other properties can easily be added.
The script fully supports armature keyframe animations. If you use IK solver or other constraints, you have to enable blender pose sampling in the exporter before exporting.
To export your meshes, simply highlight them and choose File->Export->OgreXML. You can also select armatures to get meshes in form of your armatures, which may be useful for debug purposes. After hitting the export button, you should get a set of .material, .mesh.xml and .skeleton.xml (if using armatures) files. Use the OgreXMLConverter utility to convert the .mesh.xml and .skeleton.xml files to their binary counterparts.
To automatically convert the -XML files on export, set the OGRE_XML_CONVERTER script variable to a command line that executes the OgreXMLConverter tool, e. g.,
# OGRE_XML_CONVERTER # the command line used to run the OgreXMLConverter tool. # Set to '' to disable automatical conversion of -XML files. OGRE_XML_CONVERTER = 'OgreXMLConverter'
Depending on your Ogre installation and operating system you may need to specify the full path to the OgreXMLConverter tool.