Z-Passes fluctuate darkness over frames


I have noticed that my Z-passes sometimes go darker for one or two frames, even though nothing has happened in the scene to create a sudden change in Z-depth. For example, a smoothly animated camera getting closer to a scene should produce Z-passes with a smooth change in levels, and yet 1 in every 10 or-so goes darker, only on the next frame to go back to it’s proper levels again.

I thought at first it might be due to rendering a sequence with interruption, so I tried redering let’s say frames 0001 to 0055, then stopping the render, then starting the render again from 0056 to 0100, but this did not reproduce the problem.

Even though the Z-pass outputs via a normalize node, this shouldn’t really affect it in this seemingly random way.

Is it related to fireflies or changing sampling settings? I have restarted render with different sampling settings, but even then, most of the frames look the same levels as before restarting render with different sampling, with only a random 1 or 2 going dark.

Any idea? Thanks.

Normalize compresses the Z-pass to 0-1 range. If something appears that increases the highest value in the pass, normalize will darken everything else to compensate. Use the map value node instead to scale down so this isn’t an issue.

Many thanks… so you just put a ‘Map Value’ node in between the Render Layer’s Z-out and the ‘File Ouput’ node’s Z-in - simply a straight swapping out of the ‘Normalize’ node?

Map Value or a Math node in Multiply mode. Connect one input to the z-pass and change the other value (or the size for the Map Value node) until you get what you want (probably something under 1).

Thanks, I got it working!