Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changes between Version 6 and Version 7 of content/tools/BlenderExport


Ignore:
Timestamp:
Mar 29, 2008, 2:40:01 PM (17 years ago)
Author:
FelixSchulthess
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • content/tools/BlenderExport

    v6 v7  
    44
    55== mesh Files ==
     6
     7Ogre understands only the Ogre-specific .mesh files, so we have to export our objects from Blender to a .mesh file. A .mesh file is a binary file, that contains one single mesh (object).
     8
    69=== Prerequisites ===
    7 Blender Mesh exporter from the [http://www.ogre3d.org/index.php?option=com_content&task=view&id=413&Itemid=133 Ogre Webpage].
    810
    9 If a system wide installation is intended, unpack the zip file into /usr/share/blender/scripts. If only a local installation in required or possible - due to the lack of permissions - unpack them somewhere in your home dir - ~/.blender/scripts/ is suggested - and adapt the script path in blender (User Preferences->File Paths->Python). Don't forget to save your default settings (Ctrl+U).
     11To export to mesh we first need the Blender Mesh Exporter, a python plugin for Blender. Get it from the [http://www.ogre3d.org/index.php?option=com_content&task=view&id=413&Itemid=133 Ogre webpage]. To use this plugin, python must be installed on your system.
     12
     13If a system wide installation is intended, unpack the zip file into /usr/share/blender/scripts. If only a local installation in required or possible (probably due to the lack of permissions), unpack them somewhere in your home dir, ~/.blender/scripts/ is suggested. Then adapt the script path in Blender (User Preferences -> File Paths -> Python). Don't forget to save your default settings (Ctrl+U), so you don't have to do this every time you start Blender.
    1014
    1115=== Exporting to mesh ===
    12  1. Check if all textures are loaded in the blend-file
    13  1. Open the export dialog (File->Export->OGRE Mesh)
    14    * Select the model, check "OgreXML Converter", uncheck "Copy Textures", if your texture resides in the same folder as your blend file.
    15  1. Hit Export
    1616
    17 This will create (at least) 3 new files in the blend-file-folder: <model>.mesh, <model>.mesh.xml, and Scene.material. While the .material name can be chosen while exporting, the mesh cannot. It is recommended to rename the mesh-file into something more sensible.
     17 1. Check if all textures for your objects are loaded into Blender.
     18 1. It is very helpful, to name your objects and data blocks if you have not done so already (see picture).
     19 1. Open the export dialog (File -> Export -> OGRE Meshes). If this option doesn't show up, update the menus (Scripts Windows -> Scripts -> Update Menus). If it still doesn't show up, make sure you have installed the script correctly and you have python installed.
     20 1. Select the model, check "OgreXML Converter", uncheck "Copy Textures", if your texture resides in the same folder as your blend file. Pick a sensible filename for your material under Material Settings.
     21 1. Hit Export.
     22
     23This will create (at least) 3 new files in the blend-file-folder: a .mesh file, a .mesh.xml file, and a .material file.
     24
     25The material filename will be the one you chose in the export dialog. This file contains all materials that are used in your scene, so if you export several meshes from the same scene (blend-file), you will only need one material file.
     26
     27The name of the two mesh files will be the one you picked in the material window (see picture). The .mesh.xml file is a xml file containing the data of your object. Because you checked "OgreXML Converter", the xml file was directly converted to the binary .mesh file, which we need to load the model into the game.
    1828
    1929== obj Files ==