BlendLuxCore Development

Discussion related to the LuxCore functionality, implementations and API.
kintuX
Posts: 814
Joined: Wed Jan 10, 2018 2:37 am

Re: BlendLuxCore Development

Post by kintuX »

B.Y.O.B. wrote: Mon Feb 19, 2018 8:00 pm
kintuX wrote: Mon Feb 19, 2018 6:59 pm 1. Glossy Material is still missing "Use IOR" option ;)
By the way I'm not sure why people keep nagging me about this feature and seem to be super keen on it.
If I look at the code, it just seems to be a scale factor for the specular color: https://github.com/LuxCoreRender/LuxCor ... y2.cpp#L56
So if your IOR is higher, you get a brigher specular color, and if it is lower, you get a darker specular color.
Please enlighten me why this is such a big deal.

Not meaning to sound rude, I'm genuinely interested.
By the way, the wiki says:
https://wiki.luxcorerender.org/LuxCore_SDL_Reference_Manual_v2.0#Type:_glossy2 wrote: IOR of the coating. IOR overrides color Ks if both are specified
But this does not seem to be the case in the actual code.
Which of the two is wrong?
From top of my head (& excuse my ignorance)... but isn't Fresnel on dielectrics always pure white, defined by IOR (excluding surface roughness influence, iridescence & other minute detailing)?


Thank you for everything & sorry for bothering, didn't want to sound rude or pushy... :oops:
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: BlendLuxCore Development

Post by B.Y.O.B. »

Ok I implemented IOR for glossy (glossy coating still to do).
I wrote the attached tooltip. Hope the explanation is correct.

However I could also implement this differently:
If "use IOR" is enabled, I could hide the "Specular Color" socket and export specular color as (1, 1, 1) so the user can not make a mistake here.
It would take away the user's choice (to do something wrong).
I could also make a special socket for glossy IORs that are limited to 1 as minimum value. Values below 1 seem to break the implementation.
What do you think about that?
Attachments
s.png
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: BlendLuxCore Development

Post by B.Y.O.B. »

By the way, a more important issue about the glossy material in my opinion is the following:
Even if the specular color is set to pure black, glossy shows specular reflections at grazing angles.
This is especially a problem if you try to use specularity maps - they can never switch off the reflections completely, making them rather pointless.

A workaround is to use the specular map as mix factor to mix glossy with matte.
But this has an impact on performance.
Attachments
scrn_2018-02-19_22-49-18.png
User avatar
Dade
Developer
Developer
Posts: 5675
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: BlendLuxCore Development

Post by Dade »

B.Y.O.B. wrote: Mon Feb 19, 2018 9:44 pm I could also make a special socket for glossy IORs that are limited to 1 as minimum value. Values below 1 seem to break the implementation.
IOR < 1.0 isn't possible (you can not go faster than light and there isn't something more empty than void :mrgreen:): https://en.wikipedia.org/wiki/Refractive_index

P.S. don't start with claim of FTL drives :D
Support LuxCoreRender project with salts and bounties
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: BlendLuxCore Development

Post by B.Y.O.B. »

Then it should be clamped in LuxCore (after index->GetFloatValue(hitPoint)).
I can limit the scalar default value of a socket, but I can't limit every pixel in a texture in the exporter.
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: BlendLuxCore Development

Post by B.Y.O.B. »

B.Y.O.B. wrote: Mon Feb 19, 2018 9:44 pm However I could also implement this differently:
If "use IOR" is enabled, I could hide the "Specular Color" socket and export specular color as (1, 1, 1) so the user can not make a mistake here.
It would take away the user's choice (to do something wrong).
I could also make a special socket for glossy IORs that are limited to 1 as minimum value. Values below 1 seem to break the implementation.
I have now implemented this behaviour.
Actually it does not even take away any possibilities (the only possibility was to darken the specular reflections in IOR mode through specular color, and this can simply be achieved by switching to specular color mode and making it darker).
kintuX
Posts: 814
Joined: Wed Jan 10, 2018 2:37 am

Re: BlendLuxCore Development

Post by kintuX »

thanks for the nice work... looking forward :)

So moving on... "Halt Conditions" don't work when Tiled with Multipass is used. Is that OK?
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: BlendLuxCore Development

Post by B.Y.O.B. »

kintuX wrote: Fri Feb 23, 2018 5:20 pm So moving on... "Halt Conditions" don't work when Tiled with Multipass is used. Is that OK?
This system still needs some work, it's logged in the github issue.
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: BlendLuxCore Development

Post by B.Y.O.B. »

Over the last days I implemented support for Blender's render layers in BlendLuxCore.
This is now possible thanks to the new "camerainvisible" option for LuxCore objects.

The AOVs are now set per render layer (like in Cycles).
You can also override all materials on a render layer, just like in Cycles, and you can override the halt conditions for each render layer.
This is cool if you have for example an object that is later blurred in compositing and only needs 10 samples to render, while the rest of the sceen needs 1000 samples.

Here is an example usage:
The luxball is on a different render layer than the rest of the room.
Room and LuxBall are rendered separately and combined with an alpha over node.
This is useful if you later need to re-render just the LuxBall (or the room).
You can also create all kinds of unrealistic effects with render layers ;)

I think this is a great tool for power users. I myself have rarely used render layers so far, so I don't even know of all the possibilities. However, they make it possible to use the full power of Blender's compositor with LuxCore.
Attachments
scrn_2018-02-26_11-34-59.png
User avatar
Sharlybg
Donor
Donor
Posts: 3104
Joined: Mon Dec 04, 2017 10:11 pm
Location: Ivory Coast

Re: BlendLuxCore Development

Post by Sharlybg »

:shock: This ---- IS ---- Great ! Never mind this possible for luxcore. I really like the ability allowed by this feature to render scene larger than GPU memory !

God Bless Guy :D woww i'm amazed.
Support LuxCoreRender project with salts and bounties

Portfolio : https://www.behance.net/DRAVIA
Post Reply