Can blender do "deep compositing"?
You can get depth information and use it the compositor (e.g. with the Z combine node) or put it in an EXR layer.

However there is no support currently for true deep compositing, which allows for transparency and compositing tricky things such as a motion blurred object.

I don't see it on any of the todos, however it's being mentioned in the mailing lists a bit, so it's hopefully only a matter of time.



If all you need is depth information, then it's currently possible:

The Z output contains depth information. It appears white since most of it's values are greater than 1. To view it, you need to map it's range to the 0-1 range, so you can use a Map range node or a Normalize node:



If you want to put it in an EXR, enable Z buffer in Render settings > Output:



You can use this with the Z combine node, which combines images based on Z depth values. For example, with two renderlayers (one with a sphere and one with some random objects), I can render them separately and then combine them almost as if I rendered them as one: