10-28-2008, 06:58 AM
No replies after so many views? Did I post this in the wrong section? :P
You can render out a depth pass in maya using the maya render layers.
Just create a new render layer, rightclick on it and choose presets -> luminance depth. If you open the shader attributes (just click on the icon with a little sphere on it on your depth render layer), you can see that maya mapped a setRange on a surface shader. Now put the distance from camera from the object you want to be in focus in the Old Min (first break the connection within the first box), in the Old Max you put the distance at wich you want the objects to be totally out of focus. Always testrender ofcourse.
Then when rendered (if you render in batch, Maya automatically creates folders for al the renderlayers), you bring the depth sequence into shake.
There you use a reorder node to copy the red channel into the z channel and a copy-node to bring the depth-layer in the z channel of your beautyPass (or whichhever pass you want to have depth of field).
Attach a zBlur-node or zDefocuse-node.
A way to control the point of focus is by attaching a pixelAnalyzer-node on your depth-sequence and after analyzing the color of the object you want to be in focus, use the color information of the averageRed to drive the focus center of the zBlur.
Hope this helps.
11-05-2008, 01:52 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.