Page 1 of 2

Distorted window

Posted: Sat Nov 03, 2018 6:22 pm
by lighting_freak
Hi,

I tried to copy the node tree from this thread:
http://www.luxrender.net/forum/viewtopi ... on#p125301

Unfortunatly the "multiply" doesn't contain this "Fac" anylonger.
Does anyone know a way to influence the IOR with a texture like that.

BR

Re: Distorted window

Posted: Sat Nov 03, 2018 7:27 pm
by B.Y.O.B.
Fac was done like this internally:

Re: Distorted window

Posted: Mon Nov 05, 2018 5:34 pm
by lighting_freak
Hi,

I've tried to integrate your suggestion into a working node tree.
This is my attempt and I think it's too complicated:
Fenster_tree.jpg
At least it seems to work somehow, my goal is to distort the direct reflection of the windows.
distortion by IOR
distortion by IOR
no distortion
no distortion
Comparing this two results it seems that the reflections that are generated by the complicated tree are much brighter than the "regular" ones.
This leads to the conclusion that the IOR of the glass that is finally used is much higher than the target range of 1.4 to 1.6.
And finally this means the tree doesn't work as I wish.

This is the scene and the necessary texture file:
Fenster3.blend
(758.21 KiB) Downloaded 305 times
12373-normal_grey.jpg
Thanks in advance for all your support and help.

BR

Re: Distorted window

Posted: Mon Nov 05, 2018 5:40 pm
by B.Y.O.B.
Why don't you use the texture to modulate the bump? That's what happens in real windows.

Re: Distorted window

Posted: Mon Nov 05, 2018 6:06 pm
by B.Y.O.B.
Here's an example scene.

Re: Distorted window

Posted: Mon Nov 05, 2018 6:11 pm
by lighting_freak
Simply because I know that distorting a window with bump is working.
bump distortion
bump distortion
My goal is to figure out how works while influencing the IOR.

Are you 100% sure that in real world only geometric variations are the root cause of this reflections.
I believe that glass production also creates some IOR variations due to tempering processes, rolling and diecasting etc.

So maybe a nice combination leads to impressive results.

BR

Re: Distorted window

Posted: Mon Nov 05, 2018 7:54 pm
by Dade
lighting_freak wrote: Mon Nov 05, 2018 6:11 pm I believe that glass production also creates some IOR variations due to tempering processes, rolling and diecasting etc.
In this case, you would need heterogeneous volume of varying IORs (aka densities): something not supported. The refraction of light is due to the passage between volumes with different densities. This is easy in a case of a glass where you have a sharp boundary (i.e. the surface), between two homogeneous volumes, where the light is refracted while passing from air to glass (and glass to air).

In your case however, there isn't a sharp boundary but and heterogeneous volume of glass so it would require some kind of ray marching. It is like rendering desert mirage due to different air temperature (and density):

Image

Re: Distorted window

Posted: Mon Nov 05, 2018 8:07 pm
by wasd
From my observation, main cause of window glass distortion is:
1) frame distortion – distorted frame bends glass
2) gravity and atmospheric pressure forces
3) uneven (imperfect) surface

For frame distortion I use geometry distortion. For unevennes it would be normal map.

I don't like architectural glass and path engine, so I switched to normal glass and bidir.

Re: Distorted window

Posted: Mon Nov 05, 2018 10:06 pm
by Dade
wasd wrote: Mon Nov 05, 2018 8:07 pm From my observation, main cause of window glass distortion is:
1) frame distortion – distorted frame bends glass
2) gravity and atmospheric pressure forces
3) uneven (imperfect) surface
All of 3 should be doable with the current code (as I wrote, it is a different history if you need glass with heterogeneous density).

Re: Distorted window

Posted: Mon Nov 05, 2018 11:26 pm
by kintuX
^ Yup, most simple is true.
;)

BTW
This is an older post. Was sitting in the back... now posted here, so to remind me - what for untrained eye seems, looks easy to make or is almost unnoticeable, almost invisible, is a work of a master.

lighting_freak wrote: Mon Nov 05, 2018 6:11 pm Simply because I know that distorting a window with bump is working.

Fenster_4.jpg

My goal is to figure out how works while influencing the IOR.

Are you 100% sure that in real world only geometric variations are the root cause of this reflections.
I believe that glass production also creates some IOR variations due to tempering processes, rolling and diecasting etc.

So maybe a nice combination leads to impressive results.

BR
In homogeneous volumes, IOR is more constant than not (99,9%). Especially in the matter/medium which is stable/hard, as glass is.
Effect that you're describing is commonly observed as air distortion, hot air rising above hot surface, since difference in temperature leads to different IOR, thus mirage. It is simply visualized by applying normal or bump map to fully transparent material (didn't try with LuxCore yet).

For the glass, visually more common is Birefringence.

Infinite numbers of inner reflections & interfering light wave frequencies... few words on paper, but true cosmos in reality. Yes, proper simulation in full is futile, such cases only show how common human can become the artist.

So sometimes, it's best to just a simple trick and call it a day! - use bump/normal map to distort the rayzzz...

Curiosity killed the cat, but satisfaction brought it back.
Joys of rediscovering the wheel.