Horde3D

Next-Generation Graphics Engine
It is currently 21.08.2018, 04:47

All times are UTC + 1 hour




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Blender Exporter
PostPosted: 16.06.2010, 11:43 
Offline

Joined: 13.06.2010, 02:11
Posts: 11
Hello,
I found that the Blender exporter has a problem in that it assumes that people have set their resource paths for materials, models and textures, as the referenced paths in the exported files don't have prefixes such as "materials/" or whatever regardless of where you make the exporter create them. To rectify this, I've added a new field to the exporter dialog called "base path", which I have by default set to ".." so that if you're outputting your model in "/some/path/myproject/models/mymodel.scene.xml" and your materials in "../materials", the material referenced in the scene file will be prefixed with "materials/". Currently there's no way to go back to the old behavior. I'm not sure if that's needed or not. I did find that this at least makes working with the Scene Editor easier, and it matches the type of paths used in the sample models.
Edit: I forgot to add the relative path to the .geo filename. This updated patch replaces the old one. This is the changed line:
# Write model header
- sceneFile.write('<Model name="%s" geometry="%s.geo">\n' % (fileName, fileName) )
+ sceneFile.write('<Model name="%s" geometry="%s.geo">\n' % (fileName, os.path.relpath(fileName, self.__basePath) ) )


Attachments:
File comment: Forgot to add the relative path to the .geo filename.
Horde3D Blender Export.patch [6.81 KiB]
Downloaded 486 times
Top
 Profile  
Reply with quote  
 Post subject: Re: Blender Exporter
PostPosted: 17.06.2010, 23:43 
Offline

Joined: 13.06.2010, 02:11
Posts: 11
On a separate note about the exporter, it seems like animation support is a bit broken. The result I got was that the joints were being animated, but they had no effect on the model inside the engine. Also another problem is that the exporter only exports the currently selected animation, so it's a bit of a pain to get all of them exported. That shouldn't be too hard to fix though.
I think I'll try to fix that at some point when I really need the feature, but if anyone else wants to take a stab at it, please do.


Top
 Profile  
Reply with quote  
 Post subject: Re: Blender Exporter
PostPosted: 26.06.2010, 18:37 
Offline
Engine Developer

Joined: 10.09.2006, 15:52
Posts: 1217
Thanks for your patch. Unfortunately, I think no one is really maintaining the export script at the moment :/


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group