Sign in to follow this  
Waaayoff

Can't get a decent Collada file from Blender?

Recommended Posts

Waaayoff    952
I wrote a converter that converts a Collada file to my own binary format. However since Blender's exporter is a useless piece of shit, i have to go through this everytime i need to load a model into my game:

Export .fbx file from Blender -> Convert to .dae using Autodesk Converter -> Use Collada Refinery on .dae file -> Finally convert .dae file to my format.

But then i realized that for some reason, the Autodesk Converter converts the animation keyframes into interpolated keyframes. So instead of reading 2 keyframe data and doing the interpolation in real-time, i have to read 10^10 keyframes. And i can't reverse it because the original keyframe data isn't there anymore.

So, FOR THE LOVE OF EVERYTHING THAT IS HOLY, does anyone have a working collada exporter for blender?! If not, could you at least tell me how do you convert your Collada files? Assuming that you do..

I need a drink.

Share this post


Link to post
Share on other sites
teutonicus    612
I can't help you with the Blender exporter, but I can suggest instead using [url="http://assimp.sourceforge.net/"]Assimp[/url] to import from Blender and then dumping Assimp's structures into your own file format. It supports import of .blend files (among others, including COLLADA).

I recently replaced my old COLLADA parser with Assimp after being fed up with the different COLLADA formats that I was getting from different exporters. Took me an afternoon and I no longer have hassles with broken COLLADA exports whenever a new version of Maya is released. Assimp does the boring stuff for me :)

Share this post


Link to post
Share on other sites
kuroioranda    304
[quote name='Waaayoff' timestamp='1319742887' post='4877648']
I wrote a converter that converts a Collada file to my own binary format. However since Blender's exporter is a useless piece of shit, i have to go through this everytime i need to load a model into my game:

Export .fbx file from Blender -> Convert to .dae using Autodesk Converter -> Use Collada Refinery on .dae file -> Finally convert .dae file to my format.

But then i realized that for some reason, the Autodesk Converter converts the animation keyframes into interpolated keyframes. So instead of reading 2 keyframe data and doing the interpolation in real-time, i have to read 10^10 keyframes. And i can't reverse it because the original keyframe data isn't there anymore.

So, FOR THE LOVE OF EVERYTHING THAT IS HOLY, does anyone have a working collada exporter for blender?! If not, could you at least tell me how do you convert your Collada files? Assuming that you do..

I need a drink.
[/quote]

Have you considered writing your own exporter directly from blender? The python API for blender is actually fairly easy to use, and you can do some really slick stuff with it like opening and dumping scenes directly from the command line. In my project, I don't manually export anything, I just run my build script and any changes in the game's blend files are automatically built into data for my engine and posted to the output directories for use.

[url="http://www.blender.org/documentation/blender_python_api_2_59_0/info_quickstart.html"]http://www.blender.org/documentation/blender_python_api_2_59_0/info_quickstart.html[/url]

Share this post


Link to post
Share on other sites
Waaayoff    952
[quote name='teutonicus' timestamp='1319748109' post='4877680']
I can't help you with the Blender exporter, but I can suggest instead using [url="http://assimp.sourceforge.net/"]Assimp[/url] to import from Blender and then dumping Assimp's structures into your own file format. It supports import of .blend files (among others, including COLLADA).

I recently replaced my old COLLADA parser with Assimp after being fed up with the different COLLADA formats that I was getting from different exporters. Took me an afternoon and I no longer have hassles with broken COLLADA exports whenever a new version of Maya is released. Assimp does the boring stuff for me :)
[/quote]
[font="arial, verdana, tahoma, sans-serif"][size="2"]Assimp look promising. Though on their website they say .blend files aren't fully-supported yet. And i can't use COLLADA because Blender doesn't export animation to it correctly. Anyway i'll take a look at it thanks :)[/size][/font]



[quote name='kuroioranda' timestamp='1319752731' post='4877692']
[quote name='Waaayoff' timestamp='1319742887' post='4877648']
I wrote a converter that converts a Collada file to my own binary format. However since Blender's exporter is a useless piece of shit, i have to go through this everytime i need to load a model into my game:

Export .fbx file from Blender -> Convert to .dae using Autodesk Converter -> Use Collada Refinery on .dae file -> Finally convert .dae file to my format.

But then i realized that for some reason, the Autodesk Converter converts the animation keyframes into interpolated keyframes. So instead of reading 2 keyframe data and doing the interpolation in real-time, i have to read 10^10 keyframes. And i can't reverse it because the original keyframe data isn't there anymore.

So, FOR THE LOVE OF EVERYTHING THAT IS HOLY, does anyone have a working collada exporter for blender?! If not, could you at least tell me how do you convert your Collada files? Assuming that you do..

I need a drink.
[/quote]

Have you considered writing your own exporter directly from blender? The python API for blender is actually fairly easy to use, and you can do some really slick stuff with it like opening and dumping scenes directly from the command line. In my project, I don't manually export anything, I just run my build script and any changes in the game's blend files are automatically built into data for my engine and posted to the output directories for use.

[url="http://www.blender.org/documentation/blender_python_api_2_59_0/info_quickstart.html"]http://www.blender.o...quickstart.html[/url]
[/quote]
[font="arial, verdana, tahoma, sans-serif"][size="2"][font="arial, verdana, tahoma, sans-serif"][size="2"]I really don't want to keep maintaining an exporter, the Blender API changes way too often. I did write a simple exporter that i had to update 3 times. I just can't be bothered.[/size][/font][/size][/font]

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this