Page 3 of 11
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 1:53 pm
by lacilaci
B.Y.O.B. wrote: Fri Sep 27, 2019 1:30 pm
Are volumes supported yet by the modified cache? Wouldn't you need to store photons inside the 3D volume for it to work with the "orange juice scene"?
It works, but I have to use very high radius and low amount of photons to get it look good and also to have good performance. So I kinda have to decide if I want things like drinks to look good or if I want pool caustics to look good.
EDIT: Also open scenes have worse performance so I guess there is some issue there..
and since I would use higher radius the edges are kinda dark
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 2:06 pm
by provisory
I did some tests, and some caustics don't wanna show up with caustics cache.
(LuxCore version:
https://dev.azure.com/LuxCoreRender/Lux ... uildId=801)
Light Tracing:
Caustic Cache:
Settings:
Code: Select all
path.hybridbackforward.enable = 0
path.photongi.caustic.enabled = 1
path.photongi.caustic.lookup.normalangle = 90
path.photongi.caustic.lookup.radius = 0.0001
path.photongi.caustic.updatespp.rediusreduction = 0.95
path.photongi.caustic.updatespp.minradius = 0.0001
path.photongi.caustic.maxsize = 5000000
path.photongi.caustic.updatespp = 8
I tried larger radius too, but it was the same except the more blur:
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 2:41 pm
by B.Y.O.B.
Btw., shouldn't the property be named "radiusreduction" instead of "rediusreduction"? (a instead of e)
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 4:06 pm
by Dade
provisory wrote: Fri Sep 27, 2019 2:06 pm
I did some tests, and some caustics don't wanna show up with caustics cache.
Have you changed the photon path max. depth ? The default is something like 4...
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 4:12 pm
by Dade
lacilaci wrote: Fri Sep 27, 2019 1:53 pm
It works, but I have to use very high radius and low amount of photons to get it look good and also to have good performance.
Filling a volume with cache entries requires a lot more work than a surface (i.e. 3D Vs 2D).
lacilaci wrote: Fri Sep 27, 2019 1:53 pm
EDIT: Also open scenes have worse performance so I guess there is some issue there..
Shooting photons in the right direction in an open large scene from the sun is a lot harder than in a close small scene with an area light.
The visibility map (the place where cache entries are created), at the moment cover all visibile scene. If I use the cache only for SDS paths, I can use a visibility map of area seen trough only (nearly) specular surfaces (i.e. a lot smaller).
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 4:39 pm
by provisory
Dade wrote: Fri Sep 27, 2019 4:06 pm
Have you changed the photon path max. depth ? The default is something like 4...
This was the solution, thanks!
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 5:03 pm
by provisory
Dade wrote: Fri Sep 27, 2019 10:00 am
No, no, I will still add an option for "use_caustic_cache_only_for_SDS_paths" so you use PATHOCL + Hybrid rendering + SDS Caustic cache to get the best of all modes.
From the UI point of view it should be just a combo box in Blender with:
1) path tracing
2) path tracing + light tracing
3) path tracing + light tracing + SDS cache
I would not expose PhotonGI caustic cache at all in Blender, I would use it internally only if #3 is selected.
If "normal" and SDS caustics will be treated differently, won't be a hazard that they will look differently?
E.g. caustics in a mirror will be lower resolution than the original caustics in front of it.
Re: PhotonGI caustic cache re-factoring
Posted: Fri Sep 27, 2019 6:12 pm
by Dade
provisory wrote: Fri Sep 27, 2019 5:03 pm
If "normal" and SDS caustics will be treated differently, won't be a hazard that they will look differently?
E.g. caustics in a mirror will be lower resolution than the original caustics in front of it.
I doubt the difference will be noticeable in any real world scenario (and in vast majority of the tests).
Re: PhotonGI caustic cache re-factoring
Posted: Sun Sep 29, 2019 10:27 am
by provisory
Are you sure that caustic cache works with volumes?
It didn't seem to me in my scene, so I made a simple test case.
BiDir + metro:

- CCvsVol-bidir.jpg (22.61 KiB) Viewed 6766 times
PT Sobol + Light Tracing:

- CCvsVol-lt.jpg (7.34 KiB) Viewed 6766 times
PT Sobol + Caustic Cache:

- CCvsVol-cc.jpg (5.92 KiB) Viewed 6766 times
Re: PhotonGI caustic cache re-factoring
Posted: Sun Sep 29, 2019 11:32 am
by lacilaci
provisory wrote: Sun Sep 29, 2019 10:27 am
Are you sure that caustic cache works with volumes?
It didn't seem to me in my scene, so I made a simple test case.
BiDir + metro:
CCvsVol-bidir.jpg
PT Sobol + Light Tracing:
CCvsVol-lt.jpg
PT Sobol + Caustic Cache:
CCvsVol-cc.jpg
I use homogenous volume with .1 scattering in my pool so I guess I wouldn't see much if it didn't work.
But I think theres some problem when there isn't much in the scene to bounce photons (hdri+a glass will render extremely slowly) that's why I suspected that photons might be shooting into infinity never being killed...?