playing with caustics

Post your tests, experiments and unfinished renderings here.
epilectrolytics
Donor
Donor
Posts: 790
Joined: Thu Oct 04, 2018 6:06 am

caustics from indirect light

Post by epilectrolytics »

While waiting for the SDS solution to mature I started experimenting with caustics from indirect light.
The first attempt made from two old scenes seemed to me as if the caustics were too weak.
room3b.jpg
Then I realized that when rendering with indirect PGI indirect caustic paths don't connect to lights but end with a cache lookup.
Also rendering a reference with Metropolis took too long on a scene that complex.

So I made a test scene with a glass cube in a room with an opening in a wall to another room illuminated by an area light.
indircauPCM.jpg
Test results:
Neither light tracing nor caustic cache render indirect caustics :cry:
But Metropolis sampling does, better with PathCPU than BiDir :)
PathOCL Metro shows the best caustics, but more fireflies and doesn't really converge even when approaching 100.000 samples.
Also it renders way brighter with brightness change during render :?:
indircauPOM.jpg
indicaustest_LuxCore.zip
(110.32 KiB) Downloaded 431 times
Conclusion: For difficult path combinations PathCPU+Metropolis is the way to go.

This makes me wish path guiding would be considered as the next render development project after Path Regularization is finished.
Because right now we are piling up quick fixes that cover single problems leaving others unsolved.
Like: PathOCL + PGI: Blazingly fast but unbiased and no good caustis
First fix: Hybrid Path with fast caustics but missing SDS
Second fix: Path Regularization for SDS (fast or slow, easy or tricky - yet unknown)
Still no indirect caustics.

Compared with this path guiding (Corona style) would be slower (CPU only) but faster than BiDir is now and cover all path type combinations.
Also it would work "under the hood" without requiring the user to decide which engine/sampler combination to use or long trial & error parameter tweaking sessions.
epilectrolytics
Donor
Donor
Posts: 790
Joined: Thu Oct 04, 2018 6:06 am

Re: playing with caustics

Post by epilectrolytics »

Made an overnight render with BiDir (11000 samples, 80%OIDN) of the original scene and a realistic stone material and now caustics are not visible at all :cry:
In the simple test scene indirect caustics appear instantly so the engines work as expected, need to investigate further...
roomb4.jpg
provisory
Posts: 235
Joined: Wed Aug 01, 2018 4:26 pm

Re: caustics from indirect light

Post by provisory »

epilectrolytics wrote: Mon Sep 09, 2019 9:27 am ...
Then I realized that when rendering with indirect PGI indirect caustic paths don't connect to lights but end with a cache lookup.
...
Why don't you try it with Light Tracing?
epilectrolytics
Donor
Donor
Posts: 790
Joined: Thu Oct 04, 2018 6:06 am

Re: playing with caustics

Post by epilectrolytics »

I tested that in the simple scene posted above and found that light tracing (and caustic cache) don't work with with indirect light.
provisory
Posts: 235
Joined: Wed Aug 01, 2018 4:26 pm

Re: playing with caustics

Post by provisory »

epilectrolytics wrote: Wed Sep 11, 2019 6:07 pm I tested that in the simple scene posted above and found that light tracing (and caustic cache) don't work with with indirect light.
Now I see you have already written.
You could try Glossy (or Disney) walls and door frame, and increased Glossiness Threshold of Light Tracing.
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: playing with caustics

Post by Dade »

provisory wrote: Wed Sep 11, 2019 8:46 pm
epilectrolytics wrote: Wed Sep 11, 2019 6:07 pm I tested that in the simple scene posted above and found that light tracing (and caustic cache) don't work with with indirect light.
Now I see you have already written.
You could try Glossy (or Disney) walls and door frame, and increased Glossiness Threshold of Light Tracing.
The paths for "indirect caustics" are assigned to normal path tracing rendering (i.e. eye paths), not light tracing. Light tracing renders only light paths of the type:

[LuxCore v2.2 and v2.3] Light => Specular (or glossy-nearly-specular) bounce(s) => Diffuse (or glossy-not-nearly-specular) bounce => Eye (aka LS*DE)

[only LuxCore v2.3 with PSR] Light => Specular (or glossy-nearly-specular) bounce(s) => Diffuse (or glossy-not-nearly-specular) bounce => Specular (or glossy-nearly-specular) bounce(s) =>Eye (aka LS*DS*E)

Everything else is rendered by normal path tracing (i.e eye paths).
Support LuxCoreRender project with salts and bounties
epilectrolytics
Donor
Donor
Posts: 790
Joined: Thu Oct 04, 2018 6:06 am

Re: playing with caustics

Post by epilectrolytics »

Dade wrote: Wed Sep 11, 2019 9:47 pm The paths for "indirect caustics" are assigned to normal path tracing rendering (i.e. eye paths), not light tracing.
Yep, that's what my testing suggested, thanks for confirmation!

Now the question is, why do indirect caustics work so much better in the simple test scene than in the original one?

Probably it is a problem with Metropolis sampling on glossy surfaces.
The simple test scene is all diffuse wall materials and works well.
In the original scene I use a metal shader for the door and the door frame.
That means several glossy bounces for eye paths before reaching a light source.
It seems to me Metropolis is struggling with that and converges slower.
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: playing with caustics

Post by Dade »

epilectrolytics wrote: Thu Sep 12, 2019 7:27 am Now the question is, why do indirect caustics work so much better in the simple test scene than in the original one?
Are you sure the original scene should have caustics ?

I don't think so: you need to have a direct line of sight between the bottle/glass and the other room: from the rendering, it looks like they are inside door shadow.

Try to move the table a lot right/front so bottle/glass can see directly other room.
Support LuxCoreRender project with salts and bounties
epilectrolytics
Donor
Donor
Posts: 790
Joined: Thu Oct 04, 2018 6:06 am

Re: playing with caustics

Post by epilectrolytics »

Dade wrote: Thu Sep 12, 2019 7:47 am Are you sure the original scene should have caustics ?
I replaced door and table material with diffuse and sunsky with flat color, then rendered with LightCPU:
Screenshot.jpg
Caustics are weak but visible.
Probably I was expecting too much or it takes 100 000 samples to reach final brightness.

Looks like the engines work as expected, though any improvement of Metropolis sampling would be welcome, given that the new advancements since v2.2 like PGI, Hybrid and PSR don't help in scenes like these.
epilectrolytics
Donor
Donor
Posts: 790
Joined: Thu Oct 04, 2018 6:06 am

Re: caustics from indirect light

Post by epilectrolytics »

So here is the final version, a mix from PathCPU and PathOCL with PGI,
caustics look better than in the BiDir render and also the reflections help a lot.
room6b.jpg
Post Reply