File “C:\Users\claas\Desktop\Release\untitled.blend/export_threejs.py”, line 2
00, in menu_func
AttributeError: ‘Main’ object has no attribute ‘filename’
Traceback (most recent call last):
File “C:\Users\claas\Desktop\Release\scripts\modules\bpy_types.py”, line 580,
in draw_ls
func(self, context)
File “C:\Users\claas\Desktop\Release\untitled.blend/export_threejs.py”, line 2
00, in menu_func
AttributeError: ‘Main’ object has no attribute ‘filename’
I’ve been having a little trouble implementing this.
I created a basic scene with Suzanne, which I unwrapped and baked AO to UV. I exported the model as “monkey.js” (object name: monkey) and the texture as “texture.png”. All that seems to work fine.
By placing “document.write()” commands into “display_monkey.js” and observing what shows up on my page, I have learned that the script hangs on a line in the init function:
camera = new THREE.Camera( 75, canvasWidth / canvastHeight, 0.0001, 10000 );
Here’s where I am stuck. I’m not sure why this line isn’t working.
When I start up firefox in a terminal, refreshing my page gives the error:
It was my understanding that this is a problem with firefox in linux 64 bit environments (which is where I have been working). However, the script stalls in the same place in Windows Vista-32 (using Chrome).