Front-back relation

Good day everyone,

I have question regarding spacial relations between objects.
In an attached scene I have a following situation:
There are two light sources and a camera.
One of the light sources is at the layer, which is blurred in the post-process.
Second is unmodified.
Camera rotates a system in such a way, that in the beginning blurred light source completely eclipses unmodified one, then both light sources are visible, then unmodified light source is eclipsing blurred light source, again both are visible, then blurred one for the second time eclipses unmodified one. Of course for some time there are partial eclipses.

For now I have placed both light sources in separate layers, but when I mix them (using “screen” in a mixer") I see both of them all the time, even when one actually should eclipse the other.

My question is - is there a way to inform blender about spatial relations and actually force him to show only the visible light source (including partial eclipses, where one can see one full light source, and part of the other from behind it)?

All help will be appreciated.

Best regards,
Marian Siwiak


light_problem.blend (597 KB)

I think in the Render panel, under the Layers section, if you check “All Z” the layers only render what should be visible, so it leaves out the eclipsed parts.


Thank you for the reply. I forgot to mention, that I need to use cycles… AllZ is not present there… Do you know where did it go in cycles?

best regards