Author Topic: blender cycles to corona converter/exporter  (Read 11094 times)

2013-07-08, 21:30:21

elindell

  • Active Users
  • **
  • Posts: 55
    • View Profile
I wrote a script that outputs a blender scene to something the corona standalone can render, right now its rather constrained to how a scene can be setup but I hope to ease that in the future. It mainly uses a node group I created in blender that I tried to match with how the 3dsmax corona material works. I haven't added textures yet so that will be the next hurdle for me but I don't imagine that being hard. ohsnapitsjoel sounds like he's also working on a export addon so maybe we can work together to get a fully implemented addon.

In the blend file is a Readme in the text editor that explains how to use it. Here a sample scene rendered in cycles and how the script exported it into corona (5 min on 480gtx for cycles, 5 min on i7 950 for corona, neither render optimized for speed just using default settings).

About the standalone, are displacement, motion blur and proxies available or will be added at some point? Thanks.

2013-07-08, 21:45:06
Reply #1

maru

  • Corona Team
  • Active Users
  • ****
  • Posts: 10907
  • Marcin
    • View Profile
Interesting. But I know nothing about blender. Its interface makes me cry probably like max's interface for new users. :)

Cycles is also a path tracing renderer, right? But does it use any bias? Why could it be there is more noise in Corona render?

Could you write more about Cycles? I tried googling it but found only video tutorials and some very brief documentation. Are these two images rendered using similar settings?

2013-07-08, 22:11:31
Reply #2

elindell

  • Active Users
  • **
  • Posts: 55
    • View Profile
Yes cycles is a pure path tracer. I don't think there is any bias but I could be wrong. The reason corona is noisier is because cycles has the option to render using your GPU card, specifically CUDA cores, which in my case is 450 cores parallel processing the scene on a 480gtx.  Usually GPU renders steamroll CPU renders in time, the only catch being that the scene has to fit on the video card's memory (which is a huge limit!). So for corona to be very close to a gpu render is actually testament to corona's speed, imo.  One of the best uses of cycles though is that it doesn't do any precacheing so if you make a change to a material the preview render will update immediately, its very nice for instant feedback on rendering.

Cycles uses node material setting, like octane or max. In blender you can create a node group, which is what I did here, I tried to get the node group to render the same as it would in corona. This scene was rendered/previewed in cycles then I ran my script which outputs the files needed for the standalone and then ran that. No tweaking to any scenes files after I ran the script(but you could for ultimate control).

The biggest problem is getting the settings to match from cycles to corona, for instance in cycles reflection glossiness is inverted and called roughness, but even inverting them they didn't really match so I had to do some noodling in the material group to get close. It's never going to be a perfect conversion but if I can get it close I'll be happy.

edit: also keep in mind no changes to configuration settings were made to either renderer, so its very possible I could speed up corona considerably, but I could also say the same for cycles.
« Last Edit: 2013-07-08, 22:15:50 by elindell »

2013-07-08, 22:22:05
Reply #3

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2560
  • Just another user
    • View Profile
    • My Portfolio
There are wrong defaults in corona standalone. That might be the reason why it appears noisier. It would be interesting to see contents of .conf file for this scene :)

2013-07-08, 22:36:23
Reply #4

elindell

  • Active Users
  • **
  • Posts: 55
    • View Profile
I used the conf that came with the sample scene standalone download, only thing I changed was resolution.  I'm curious what settings are wrong.

2013-07-09, 00:38:35
Reply #5

ohsnapitsjoel

  • Active Users
  • **
  • Posts: 54
    • View Profile
There are wrong defaults in corona standalone. That might be the reason why it appears noisier. It would be interesting to see contents of .conf file for this scene :)

I'm really curious about this too; which defaults are incorrect?

Also, does anyone know - is there anywhere we could see the minimums and maximums of the parameters that are in the .conf file?  The interactive docs are helpful, but in general they don't show what the minimums and maximum values are, only some of the defaults.