Hey, I've looked at the wiki and I've done some searching on the forums, but there are still some gaps in the information on how to get models from Blender to Ogre. I'm trying to export a model of a viper2 space ship that I downloaded. I downloaded the OgreXML export python script and added it to Blender scripts so I can select the format in the File > Export menu. But it says it can't import the pickle module and perminent settings are disabled.
Not sure what it means, but I will continue anyway. When I select Game Engine Materials and click export it says Python script error: check console.
In the consol it says:
Using Python version 2.4
'import site' failed; use -v for traceback
Traceback (most recent call last):
File "<string>", line 3550, in buttonCallback
File "<string>", line 3203, in export
File "<string>", line 3070, in export_mesh
ValueError: face has no texture values
If I don't have Game Engine Materials selected, it exports fine with the name NoName+Turbine and Scene.material. I convert NoName+Turbine.mesh.xml with XMLConverter.exe and rename the resulting file to viper2.mesh. I copy this and the Scene.material file into Media/models and Media/materials/scripts respectively. When I run my Ogre scene with this mesh loaded all I see are the Turbines of the ship and there is an Error in the output:
Mesh: Loading viper2.mesh.
Can't assign material Turbine to SubEntity of Viper 2 because this Material does not exist. Have you forgotten to define it in a .material script?
I don't really know anything about blender, all I want to do is convert this .blend file to a .mesh file. Can anyone tell me what I'm missing?
Thanks.
need more info on blender exporter
- jacmoe
- OGRE Retired Moderator

- Posts: 20570
- Joined: Thu Jan 22, 2004 10:13 am
- Location: Denmark
- x 179
- Contact:
The Pickle module is from the standard Python library, not the internal Blender mini-Python:
Install Python 2.4 - and provide an environment variable called PYTHON_HOME, pointing to the newly created python directory.
Install Python 2.4 - and provide an environment variable called PYTHON_HOME, pointing to the newly created python directory.
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
-
themoebius
- Kobold
- Posts: 39
- Joined: Sat Mar 04, 2006 5:43 pm
OK I installed Python and I no longer got the error about pickle, but I still got this error:
Using Python version 2.4
Traceback (most recent call last):
File "<string>", line 3550, in buttonCallback
File "<string>", line 3203, in export
File "<string>", line 3070, in export_mesh
ValueError: face has no texture values
I tried exporting it using my linux box and I got something a bit different. I guess blender only exports the selected object and thats why I was only getting the turbines, so I selected all by layer before exporting. I didn't get any errors this time, but it produced a seperate xml file for each component. How can I just load the whole thing as one mesh?
I didn't get the error about loading the material script when I tried it with the code from one of the tutorials so it must be my code that is the problem there. I will pursue that part of it in the programming help forum.
Using Python version 2.4
Traceback (most recent call last):
File "<string>", line 3550, in buttonCallback
File "<string>", line 3203, in export
File "<string>", line 3070, in export_mesh
ValueError: face has no texture values
I tried exporting it using my linux box and I got something a bit different. I guess blender only exports the selected object and thats why I was only getting the turbines, so I selected all by layer before exporting. I didn't get any errors this time, but it produced a seperate xml file for each component. How can I just load the whole thing as one mesh?
I didn't get the error about loading the material script when I tried it with the code from one of the tutorials so it must be my code that is the problem there. I will pursue that part of it in the programming help forum.
- jacmoe
- OGRE Retired Moderator

- Posts: 20570
- Joined: Thu Jan 22, 2004 10:13 am
- Location: Denmark
- x 179
- Contact:
Find the Dungeon Hack tutorials in this forum.
Give your model/mesh a material.
Export.
If you want just one mesh, you should combine the individual meshes in Blender to one.
Give your model/mesh a material.
Export.
If you want just one mesh, you should combine the individual meshes in Blender to one.
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.