2.54 beta Exporting 3ds couses errors

The interface, modeling, 3d editing tools, import/export, feature requests, etc

Moderators: jesterKing, stiv

Post Reply
ninodelafortuna
Posts: 0
Joined: Wed Sep 29, 2010 10:48 pm
Location: Poland

2.54 beta Exporting 3ds couses errors

Post by ninodelafortuna »

Hello i'm new.

I tried to export model from blender 2.54beta to 3ds but i get this kind of error:
Traceback (most recent call last):
File "C:\Users\Sebastian\AppData\Roaming\Blender Foundation\Blender\2.54\scrip
ts\op\io_scene_3ds\__init__.py", line 58, in execute
return io_scene_3ds.export_3ds.save(self, context, **self.properties)
File "C:\Users\Sebastian\AppData\Roaming\Blender Foundation\Blender\2.54\scrip
ts\op\io_scene_3ds\export_3ds.py", line 969, in save
object_info.add_subchunk(make_material_chunk(mat_and_image[0], mat_and_image
[1]))
File "C:\Users\Sebastian\AppData\Roaming\Blender Foundation\Blender\2.54\scrip
ts\op\io_scene_3ds\export_3ds.py", line 473, in make_material_chunk
material_chunk.add_subchunk(make_material_texture_chunk(MATMAP, images))
File "C:\Users\Sebastian\AppData\Roaming\Blender Foundation\Blender\2.54\scrip
ts\op\io_scene_3ds\export_3ds.py", line 440, in make_material_texture_chunk
add_image(image)
File "C:\Users\Sebastian\AppData\Roaming\Blender Foundation\Blender\2.54\scrip
ts\op\io_scene_3ds\export_3ds.py", line 434, in add_image
filename = os.path.basename(image.filepath)
NameError: global name 'os' is not defined
Can anybody tell me if it's common problem or i did something wrong?
My model is a simple object with default material and texture (jpg image 512x512 ).
Problem doesn't exist when I remove material.

Maybe i have to install Python or something. My current version is Python 2.66 amd64. I'm using Win7 64bit.

tushantin
Posts: 0
Joined: Tue Oct 05, 2010 9:09 am

Post by tushantin »

Hmm your best bet would be to ditch the materials and use 3DsMax's material tool. :?

I'm having 3Ds export problems too though (Blender 2.54, Win32 Zip). After exporting all my 4-sided polygons turn to 3-side and quite a lot of normals and vertices shift and separate, forcing me to use Collada format instead (can't seem to export in FBX and OBJ for some reason).

ninodelafortuna
Posts: 0
Joined: Wed Sep 29, 2010 10:48 pm
Location: Poland

Post by ninodelafortuna »

hi tushantin. Thanks for Your advice. I'm importing 3ds files into Away3d/Flash application. I need files to be small. So i can't use collada format.

I solved my problem this way:
- after baking texture I save it to JPG file
- I delete material linked to the Object ( problem exist when object has material)
- then export to 3ds file
- I put source paths to the texture files and 3ds models in a XML file I've created ( simple furniture library )
- in Action Script I load a model and texture separately using XML library

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<models>
<furnitures name="Sypialnia">
<elem thumb="model_01.jpg" model="model_01.3ds" >
<texture name="Texture 1" src="model_01_tex1.jpg"></texture>
<texture name="Texture 2" src="model_01_tex2.jpg"></texture>
<texture name="Texture 3" src="model_01_tex3.jpg"></texture>
</elem>
<elem thumb="model_02.jpg" model="model_02.3ds" >
<texture name="Texture 1" src="model_02_tex1.jpg"></texture>
<texture name="Texture 2" src="model_02_tex2.jpg"></texture>
<texture name="Texture 3" src="model_02_tex3.jpg"></texture>
</elem>
<elem thumb="model_03.jpg" model="model_03.3ds" >
<texture name="Texture 1" src="model_03_tex1.jpg"></texture>
<texture name="Texture 2" src="model_03_tex2.jpg"></texture>
<texture name="Texture 3" src="model_03_tex3.jpg"></texture>
</elem>
</furnitures>
</models>

It works

Post Reply