Page 2 of 5

Re: Light tracing and pool

Posted: Tue Aug 06, 2019 1:24 pm
by FarbigeWelt
lacilaci wrote: Tue Aug 06, 2019 12:13 pm
epilectrolytics wrote: Tue Aug 06, 2019 11:27 am
lacilaci wrote: Tue Aug 06, 2019 8:11 am now look what we got here!!!

PATHCPU! + Metropolis:
Yes, somehow PathCPU metro does faster pool caustics than BiDir, the other solution would be caustic cache.
From what I read you figured out everything yourself already, but if you might provide a scene with the wave bump texture I could do some testing as well.
Sure, this is the scene I'm testing all the possibilities in:
poolCaustics_testscene.blend

Right now it seems building cache (in limited conditions) and reusing for full scene render is a way... (shitty and overcomplicated but it's something) the closest I can get is really only cycles+faking the whole thing... which can also look good but... not that good...
hmm...
Sounds like a case for CPU+Metropolis computing in a cloud. ⛅️

Re: Light tracing and pool

Posted: Tue Aug 06, 2019 1:29 pm
by lacilaci
FarbigeWelt wrote: Tue Aug 06, 2019 1:24 pm
hmm...
Sounds like a case for CPU+Metropolis computing in a cloud. ⛅️
Or, we actually need to wait until light tracing+VM to to master the rendering universe :D

Re: Light tracing and pool

Posted: Tue Aug 06, 2019 8:30 pm
by epilectrolytics
lacilaci wrote: Tue Aug 06, 2019 12:13 pm Sure, this is the scene I'm testing all the possibilities in:
poolCaustics_testscene.blend
Thanks!

Sadly I'm not able to get any better results :(

First I tried PathCPU+Metro (no PGI). In order to speed up things, I reduced path depth, set relative sun size to 4, roughness of glossy materials to 0.19 and added light tracing with glossiness threshold 0.2, hoping that would take care of the noise above the water.
Also I changed the water bump from procedural to image texture which is faster.

But then the whole thing took 2h50min for 10000 samples and still very noisy (OIDN at 70%):
poolh7.jpg
Than I tested the caustic cache (without indirect because it influences caustic in a bad way) and could not get rid of the issues either.
I didn't like the straight water surface edges and replaced the flat plane with a wavy plane (no speed difference, but waves should have been smaller).
With PathOCL+PGI there is the problem that the periods of newly built caches increase with time, so there is no equal sampling ratio and not enough cache instances in the end.
Switching to PathCPU+PGI things are slow but steady, but firefllies take too long to disappear and some are very strong and don't disappear at all.
Also there are some dark artefacts in the underwater caustics and the shadows appear too dark.
Result after 1000 samples in 25min:
poolc0.jpg
In the end there is no satisfying result.

Path+Metro kinda works but a 4k render might take 12h to finish which is not feasible if more than one of those are requested.
(I used sky background because I like it better than the grey color, especially in reflections.)

Re: Light tracing and pool

Posted: Tue Aug 06, 2019 8:52 pm
by lacilaci
epilectrolytics wrote: Tue Aug 06, 2019 8:30 pm
lacilaci wrote: Tue Aug 06, 2019 12:13 pm Sure, this is the scene I'm testing all the possibilities in:
poolCaustics_testscene.blend
Thanks!

Sadly I'm not able to get any better results :(

First I tried PathCPU+Metro (no PGI). In order to speed up things, I reduced path depth, set relative sun size to 4, roughness of glossy materials to 0.19 and added light tracing with glossiness threshold 0.2, hoping that would take care of the noise above the water.
Also I changed the water bump from procedural to image texture which is faster.

But then the whole thing took 2h50min for 10000 samples and still very noisy (OIDN at 70%):
poolh7.jpg

Than I tested the caustic cache (without indirect because it influences caustic in a bad way) and could not get rid of the issues either.
I didn't like the straight water surface edges and replaced the flat plane with a wavy plane (no speed difference, but waves should have been smaller).
With PathOCL+PGI there is the problem that the periods of newly built caches increase with time, so there is no equal sampling ratio and not enough cache instances in the end.
Switching to PathCPU+PGI things are slow but steady, but firefllies take too long to disappear and some are very strong and don't disappear at all.
Also there are some dark artefacts in the underwater caustics and the shadows appear too dark.
Result after 1000 samples in 25min:
poolc0.jpg
In the end there is no satisfying result.

Path+Metro kinda works but a 4k render might take 12h to finish which is not feasible if more than one of those are requested.
(I used sky background because I like it better than the grey color, especially in reflections.)
ha, you were already using the improved shadow terminator build or did you simply subdivide the sphere? Anyways, there is no "free lunch" or whatever...

Re: Light tracing and pool

Posted: Tue Aug 06, 2019 9:10 pm
by B.Y.O.B.
lacilaci wrote: Tue Aug 06, 2019 5:35 am the closest I could get is with lowered opacity on the water... but it looks a bit weak
What about taking this solution, and increasing the contrast of the water in compositing by using a mask created from an AOV (like "material ID color")?

Re: Light tracing and pool

Posted: Tue Aug 06, 2019 9:12 pm
by epilectrolytics
lacilaci wrote: Tue Aug 06, 2019 8:52 pmdid you simply subdivide the sphere?
Yep :P

Re: Light tracing and pool

Posted: Wed Aug 07, 2019 4:49 am
by lacilaci
B.Y.O.B. wrote: Tue Aug 06, 2019 9:10 pm
lacilaci wrote: Tue Aug 06, 2019 5:35 am the closest I could get is with lowered opacity on the water... but it looks a bit weak
What about taking this solution, and increasing the contrast of the water in compositing by using a mask created from an AOV (like "material ID color")?
I'm using something along those lines for cycles and can get somewhat acceptable results... but now that I've seen those caustics with bidir+metro I cannot unsee it.. I'll try to make the caustic cache work somehow to get as close to that result as possible

Re: Light tracing and pool

Posted: Thu Aug 08, 2019 2:04 pm
by Fox
epilectrolytics wrote: Tue Aug 06, 2019 8:30 pm Switching to PathCPU+PGI things are slow but steady, but firefllies take too long to disappear and some are very strong and don't disappear at all.
Also there are some dark artefacts in the underwater caustics and the shadows appear too dark.
About dark shadows and reinhard tonemapping in luxcoreui.
The luxcoreui has only linear gain, but it works pretty well to shift the average brightness of reinhard tonemapping.
I use reinhard to brighten the shadows and pull down highlights. The sun and hdr are very contrasty, especially between shadow brightness about 150 to fireflyes inf (inf is about 10 000 000 000 on exr file).

With fireflyes in render and clamping turned on at 100 000, the linear gain in luxcoreui has no effect.

With BiDirVM when is set bidirvm.lightpath.count to very high value like 65536, the tonemapping looks very natural to eye.
But then it seems, what ever pass the BiDirVM does next in very short time, makes the inf values, then shadows get very dark with reinhard.
With LIGHT_WORLD_RADIUS_SCALE set to 100.05 in light.cpp, the tonemapping looks natural to eye but no underwater caustic never happen.

So maybe if reinhard would use clamped data, the render would look better. :roll: Or maybe it uses clamped data, and i need to go smaller on clamping value.

Re: Light tracing and pool

Posted: Thu Aug 08, 2019 2:52 pm
by lacilaci
Don't know anything about bidirVM, it's not exposed to blender addon and I'm guessing there's good reason for that.

Anyways, there is no way to get good pool caustics now it seems. Caustic cache is super slow and never converges to a decent looking result, not even mentioning denoiser cannot handle it's fireflies.

Closest I'm getting to somewhat good looking although very fake result is this:
causticsfake.jpg
It's just 2 renders with one having disabled camera visibility for the water body and then crappy compositing with overlay in post..

It's pretty shitty but I guess there's no way around the problem until 2.3 and light tracing + VM

Re: Light tracing and pool

Posted: Thu Aug 08, 2019 3:52 pm
by marcatore
It's turning out quite well.. I can feel the freshness of the water and the hot sun ... :)
Please...a cocktail, please! :)