Is Cycles Mist pass just an antialiased Z pass?

In Blender Internal, the mist pass has a ‘height’ to it; that is, the mist can cling to the floor and fades out upwardly. But in the Cycles mist pass, there seems to be no upward fade out and so that makes it littel different from the Z pass, except it has antialiasing.

Am I missing something?

It’s almost an antialiased z-pass. There are a couple of other important differences:

-It’s normalized based on distance from the camera (set by the mist start and end points, same as BI)
-It’s inverted, white is far, black is close. (since it’s meant as a mask for a far-fog layer. BI’s should be flipped like this too, but I don’t think it is)
-It passes transparency as-is. Z-pass is either 100% transparent, or 100% opaque, depending on whether the transparency is greater than the “transparency threshold” value. Mist-pass simply uses the shader transparency amount.

It would be a little more accurate to say it’s the BI pass but without the height controls. The height option would be nice though, I’m not entirely sure why it was never brought over.

Thanks.
I wonder why the Z-pass isn’t anti-aliased then!?

Anti-aliasing on the depth pass tends to mess up the DOF blur. Say, you have something in the foreground that would be white (close), against something that would be black (far). If the renderer anti-aliases the edges of the foreground element, the edges of the close object will now have varying degrees of gray in them, which gives conflicting depth information. The DOF blur doesn’t know if the edge of the object is close, or if it is far, or if it is somewhere between, so you get strange edge artefacts with your blur.

Brilliant answer. Makes sense. Thanks.