LuxC4D 0.03

Discussion related to the 'LuxC4D' exporter plugin for Maxon Cinema 4D.

Moderators: Ratow, coordinators

LuxC4D 0.03

Postby abstrax » Wed Nov 19, 2008 6:26 am

Hi all,

Here is version 0.03 of LuxC4D:

LuxC4D_0.03b_mac32_debug.zip
(289.89 KiB) Downloaded 82 times

LuxC4D_0.03b_mac32_release.zip
(280.25 KiB) Downloaded 116 times

LuxC4D_0.03b_win32_debug.zip
(148.78 KiB) Downloaded 133 times

LuxC4D_0.03b_win32_release.zip
(133.94 KiB) Downloaded 199 times


This version comes with export of light sources. The conversion is done automatically, but a light tag is in the making, where you will be able specify the light type and attributes manually. As the lights in C4D are made for classic lighting, while the Lux lights are (more or less) physically based, you cannot really convert them. I tried my best to approximate the behaviour in C4D as much as possible, but I don't think it will work very well in your scenes. But please try it out and give me some feedback. Keep in mind though, that the falloff is always inverse square in Lux. The current conversion table between C4D and Lux light types is:
- Omni -> Point
- Spot, Square Spot -> Spot
- Infinite, Parallel, Parallel Spot, Square Parallel Spot -> Distant
- Area -> Area

That means that special lights like sun and sky are not supported in this version (yet), but will follow with the implementation of the light tag.

Anothe limitation: Because in Lux area lights emit light only from the outside (i.e. one side of the surface is emitting, the other one is not), there will be an option in the light tag that allows you to reverse the surface orientation to let e.g. a hemisphere shine inside and not outside. For now the surface staysonly oriented as it is.

The brightness scaling is tuned for the very latest CVS weekly build and will be too dark in older Lux versions.

The cylinder area light has no caps. I will add them later.

Another change is the addition of preferences in the program preferences, where you can specify scene independent settings for LuxC4D. For the time being there is only one option: A path to the Lux executable. Which brings us to te next addition:

In the plugins menu there is now a new command "LuxC4D Export and Render", which exports your scene and launches the application specified in the preferences.

I also added a tab "Export" where you can specify the output scale (default: 0.01) and which filename you want to use for the exported scene.

After cleaning up the code, I will commit the changes to CVS and then continue working on the light tag.

As always, feedback is very welcome.

Cheers,
Marcus
Last edited by abstrax on Wed Nov 19, 2008 2:18 pm, edited 2 times in total.
abstrax
 
Posts: 247
Joined: Sat Dec 08, 2007 3:52 am
Location: Auckland, New Zealand

Re: LuxC4D 0.03

Postby Stromberg90 » Wed Nov 19, 2008 7:29 am

Great :)
Just the light tag, and materials left and it will be useable ;)
Stromberg90
 
Posts: 52
Joined: Sat Aug 09, 2008 4:52 pm

Re: LuxC4D 0.03

Postby Szasa » Wed Nov 19, 2008 1:54 pm

Hey Marcus, let me say that your work is freaking awesome.

Thx so much for your time and effort!

Bye

- Sascha
Szasa
 
Posts: 7
Joined: Wed Aug 27, 2008 5:14 pm

Re: LuxC4D 0.03

Postby abstrax » Wed Nov 19, 2008 2:21 pm

Hi,

Sorry, but I had to upload a new build, as I messed up the brightness scaling in a last minute fix... The changes in light behaviour done in Lux applied only to area lights. Due to that, the non-physical lights (like point, spot ...) were too dark by a factor of 100.

It should work now better. If you have already downloaded the plugin, please download the new version again.

Cheers,
Marcus
abstrax
 
Posts: 247
Joined: Sat Dec 08, 2007 3:52 am
Location: Auckland, New Zealand

Re: LuxC4D 0.03

Postby Radiance » Wed Nov 19, 2008 6:28 pm

Hey,

Is this release for luxrender v0.5 or for the weekly builds ?

I'm currently working on the lights in the CVS version. (as you can see in my spectral textures/SPD post)
I'll update the scene file documentation when i'm done (in a few days)

Radiance
User avatar
Radiance
 
Posts: 3968
Joined: Wed Sep 19, 2007 2:13 am

Re: LuxC4D 0.03

Postby abstrax » Wed Nov 19, 2008 6:35 pm

Radiance wrote:Hey,

Is this release for luxrender v0.5 or for the weekly builds ?

I'm currently working on the lights in the CVS version. (as you can see in my spectral textures/SPD post)
I'll update the scene file documentation when i'm done (in a few days)

Radiance



Hi Radiance,

I have tested and tweaked this release to the current CVS version (== weekly build). All the spectral features are not included yet, but they will be at some point, when the light tag is done. As parameter reference I was using the source code Create...() functions.

Cheers,
Marcus
abstrax
 
Posts: 247
Joined: Sat Dec 08, 2007 3:52 am
Location: Auckland, New Zealand

Re: LuxC4D 0.03

Postby Szasa » Thu Nov 20, 2008 11:09 am

Hey Marcus,

I don't know why but as soon as I use area lights in Cinema and export and loading it to Lux, Lux is crashing.
When I use omni lights in the same scene, Lux is just working fine. Hmm...I've to look further into this...this seems really weird, because evrything else is working like expected.

Again great work!

Bye

Sascha
Szasa
 
Posts: 7
Joined: Wed Aug 27, 2008 5:14 pm

Re: LuxC4D 0.03

Postby abstrax » Thu Nov 20, 2008 12:57 pm

Szasa wrote:I don't know why but as soon as I use area lights in Cinema and export and loading it to Lux, Lux is crashing.
When I use omni lights in the same scene, Lux is just working fine. Hmm...I've to look further into this...this seems really weird, because evrything else is working like expected.


Hi Sascha,

Thanks for testing. Could you please send me a file (C4D + LXS) that crashes? Is it happening under Windows or Mac? Which Lux version are you using? When Lux crashes while loading, it's very likely due to some things in the scene file, Lux doesn't know. There seems to be no real error handling in the scene file parsing.

Thanks,
Marcus
abstrax
 
Posts: 247
Joined: Sat Dec 08, 2007 3:52 am
Location: Auckland, New Zealand

Re: LuxC4D 0.03

Postby Szasa » Thu Nov 20, 2008 7:20 pm

abstrax wrote:Could you please send me a file (C4D + LXS) that crashes? Is it happening under Windows or Mac? Which Lux version are you using? When Lux crashes while loading, it's very likely due to some things in the scene file, Lux doesn't know. There seems to be no real error handling in the scene file parsing.


Hey Marcus,

I'm on a Windows Xp Pro Sp2 32bit and Lux 0.5.
Sorry I can only send you the .lxs file since I'm testing it with the Cinema R11 Demo, but anyway here you go...the two files have the same settings beside the fact, that one is with an omni light, which renders fine in Lux and the other with an area light, which crashes Lux at loading.

LuxFiles.zip
LuxFiles
(31.55 KiB) Downloaded 100 times


Maybe it is only a typo in the export routine, typos can be really bad :D, I know that from my plugins ;)

Good hunting!

Bye

Sascha
Szasa
 
Posts: 7
Joined: Wed Aug 27, 2008 5:14 pm

Re: LuxC4D 0.03

Postby abstrax » Thu Nov 20, 2008 7:36 pm

Hi Sascha,

Ok, that explains it. I forgot to mention that the exported files do not work correctly with Lux version 0.5 anymore as I now started to migrate to the new mesh shape and to use quads.

Please try it with the last weekly build from here: viewtopic.php?f=30&t=1181

With this build it works fine for me.

Cheers,
Marcus
abstrax
 
Posts: 247
Joined: Sat Dec 08, 2007 3:52 am
Location: Auckland, New Zealand

Next

Return to LuxC4D (Maxon Cinema 4D Exporter)

Who is online

Users browsing this forum: No registered users and 0 guests