[Blend2cs-user] blend2cs conversion story

Thomas Degris blend2cs-user@blender.org
Tue, 22 Jul 2003 19:05:36 +0200


Hello,

I wanted to show the different possibilities of CrystalSpace to the 
people of my team that were using blender as a 3D editor but also as a 
real time engine. Since the real time engine if not anymore available in 
Blender, they are interesting in moving to a new real time engine. So, I 
asked them to send me one of their blender files, to check how the 
conversion works. So, here is the different steps of this conversion, I 
think it may be representative of what people can experience if they are 
trying to convert their Blender maps to CS maps.

1)  So, I first get the latest source of blend2cs, after some emails to 
this mailing list, I discover I have to use the blend2cs tool and not 
blendconv. Compiling it was easy and I got the binary working quite fast.

2) After some reading in the documentation, I learn that blend2cs 
doesn't extract the textures packed in the blend file. It is not a very 
big map, so I decided to extract the textures manually from the UV 
mapping menu of Blender and put them in a textures folder. You can find 
the blender file and the textures folder in the bz2 file :
http://www-poleia.lip6.fr/~degris/crystal/question.tar.bz2

3) So, now everything is ready for me to convert the map. I am using the 
following command :
# blend2cs -t textures/ question.blend world
warning: object OBPlane.019 has no UV coordinates assigned, using dummy 
texture.
warning: object OBCube.009 has no UV coordinates assigned, using dummy 
texture.
warning: object OBNuke has no UV coordinates assigned, using dummy texture.
Skipping Camera 'OBCamera': cameras as parent/child objects not 
supported yet.

The last line makes me verify if there is a camera somewhere in the 
world file. That is not the case, so I go back to Blender to remove the 
parents of the camera and I save the file under question_camera.blend, 
you can find it at :
http://www-poleia.lip6.fr/~degris/crystal/question_camera.tar.bz2

4) So, I am retrying to convert the map by using the same kind of command :
# blend2cs -t textures/ question_camera.blend world
warning: object OBPlane.019 has no UV coordinates assigned, using dummy 
texture.
warning: object OBCube.009 has no UV coordinates assigned, using dummy 
texture.
warning: object OBNuke has no UV coordinates assigned, using dummy texture.

These are only warnings, so I decide to make the zip file to be able to 
load the map with walktest :
# zip question_camera01.zip world textures/*
# walktest -relight question_camera01.zip

After this command, walktest starts and then just stops whitout an error 
message (only warnings about some textures files). The output file of 
walktest can be found at :
http://www-poleia.lip6.fr/~degris/crystal/walktest01.txt
and the zip file at :
http://www-poleia.lip6.fr/~degris/crystal/question_camera01.zip

The thing is I would have expect to be able to walk into the scene (with 
some missing textures) but I just got nothing : walktest exists with no 
error message.

5)  After some debugging of CS, it seems that CS stops to load the map 
because of the OBCube.009 mesh that doesn't have any parameters (line 
633 of the world file). So, I remove the mesh directly from world file 
to check if it changes something and then.... yeeeeaaaaah the map is 
loaded by walktest. Here is the command I run :
# zip question_camera02.zip world textures/*
# walktest -relight question_camera02.zip

The output file of walktest and the zip file can be found at :
http://www-poleia.lip6.fr/~degris/crystal/walktest02.txt
http://www-poleia.lip6.fr/~degris/crystal/question_camera02.zip

6) The bad thing is there lot of bugs in the drawing. I fix few problems 
of textures by modifing the world file and some file names. You can find 
the zip file at :
http://www-poleia.lip6.fr/~degris/crystal/question_camera03.zip
and some screenshot of the scene with the bugs rendered by CS at :
http://www-poleia.lip6.fr/~degris/crystal/cs_screenshot01.jpg
http://www-poleia.lip6.fr/~degris/crystal/cs_screenshot02.jpg
http://www-poleia.lip6.fr/~degris/crystal/cs_screenshot03.jpg
http://www-poleia.lip6.fr/~degris/crystal/cs_screenshot04.jpg
So, I don't know if I did something wrong or if it comes from blend2cs 
(or even CrystalSpace).

As a conclusion, I would say blend2cs is going to be a good tool. I hope 
this email will help the authors to debug it. Of course, the best would 
be that the output of blend2cs outputs a zip file (as map2cs does) that 
is able to be loaded directly by CS. I think I will wait some more weeks 
before using Blender as a CS editor but it will be definitly a good way 
of making maps when this will be fully functional.

Best of lucks to the developer and thank you for working on such tools,

Thomas