I hope I can get some fix in as well, but first I need to know that my analysis is right. I have never written shader code before nor tried to build Babylon. I can for sure give it a shot though, but that probably can’t happen on company time, unfortunately.
Here is how it looks in our production code, running Babylon 4.2.
SSAO off
SSAO2 on, before the blur steps
This is of course very noisy but shows where the occlusions should be. Notice how dark it is between the drawer fronts, as expected.
SSAO2 on, including the blur steps
Notice how the occluded areas in between the drawer fronts are suddenly no longer occluded, but the extremely non-occluded areas on the top and bottom of the drawer fronts are suddenly rendered as they were occluded.
Manually blurred SSAO2
For this image, I extracted the SSAO2 buffer using Spector. Then I manually blurred the SSAO2 buffer using a gaussian blur and composited that on top of the first image using paint.NET. The results are in my opinion much, much better. However, there you get the occluded areas spilling over into areas with very different Z values, which is what the bilatteral filter tries to remove. Or at least I think it does.