OGRE 14.3
Object-Oriented Graphics Rendering Engine
|
There are a number of mesh tools available with OGRE to help you manipulate your meshes.
This tool can convert binary .mesh and .skeleton files to XML and back again - this is a very useful tool for debugging the contents of meshes, or for exchanging mesh data easily - many of the modeller mesh exporters export to XML because it is simpler to do, and OgreXMLConverter
can then produce a binary from it.
-v | Display version information |
-merge | [n0,n1] Merge texcoordn0 with texcoordn1. The , separator must be present, otherwise only n0 is provided assuming n1 = n0+1; n0 and n1 must be in the same buffer source & adjacent to each other for the merge to work. |
-o | DON'T optimise out redundant tracks & keyframes |
-E | Set endian mode big little or native (default) |
-x | Generate no more than num eXtremes for every submesh (default 0) |
-q | Quiet mode, less output |
-log | name of the log file (default: OgreXMLConverter.log ) |
This tool is provided to allow you to upgrade your meshes when the binary format changes - sometimes we alter it to add new features and as such you need to keep your own assets up to date. Furthermore, OgreMeshUpgrader
can generate additional information for the mesh, like bounding regions and level-of-detail reduction. See the Automatic Mesh LOD Generator Tutorial for details.
-pack | Pack normals and tangents as int_10_10_10_2 |
-optvtxcache | Reorder the indexes to optimise vertex cache utilisation |
-autogen | Generate autoconfigured LOD. No LOD options needed |
-l | number of LOD levels |
-d | distance increment to reduce LOD |
-p | Percentage triangle reduction amount per LOD |
-f | Fixed vertex reduction per LOD |
-el | generate edge lists (for stencil shadows) |
-t | Generate tangents (for normal mapping) |
-ts | Tangent size (4 includes parity, default: 3) |
-tm | Split tangent vertices at UV mirror points |
-tr | Split tangent vertices where basis is rotated > 90 degrees |
-r | DON'T reorganise buffers to recommended format |
-E | Set endian mode big little or native (default) |
-b | Recalculate bounding box (static meshes only) |
-V | Specify OGRE version format to write instead of latest Options are: 1.10, 1.8, 1.7, 1.4, 1.0 |
-log | filename name of the log file (default: OgreMeshUpgrader.log ) |
This tool converts 3D-formats supported by assimp to native OGRE .mesh .skeleton and .material files.
-q | Quiet mode, less output |
-log | filename name of the log file (default: OgreAssimp.log ) |
-aniSpeedMod | [0..1] Factor to scale the animation speed (default: 1.0) |
-3ds_ani_fix | Fix for 3ds max, which exports the animation over a longer time frame than the animation actually plays |
-max_edge_angle | deg When normals are generated, max angle between two faces to smooth over |
Exporters are plugins to 3D modelling tools which write meshes and skeletal animation to file formats which OGRE can use for realtime rendering. The files the exporters write end in .mesh
and .skeleton
respectively.
Each exporter has to be written specifically for the modeller in question, although they all use a common set of facilities provided by Ogre::MeshSerializer and Ogre::SkeletonSerializer. They also normally require you to own the modelling tool.
Full documentation for each exporter is provided along with the exporter itself, and there is a selection of the currently supported modelling tools at OGRECave.
All mesh files are required to have a material name set, otherwise most mesh tools will fail with an exception. Even if they don't, the exception will happen deep inside the render-loop which is way harder to debug (unless you set the material programmatically).
To set a material name for the mesh, you have these options:
OgreXMLConverter
.There are a few rules when creating an animated model:
If you’re creating non-animated meshes, then you do not need to be concerned with the above.