1
$\begingroup$

enter image description here The Z pass is only defocussing inside the boundaries of the Tea Caddy. I presume this because the Caddy is divided against the background? Is there a way to extend the defocus effect of the edges of the object so it fits naturally into the scene?

$\endgroup$
2
$\begingroup$

The problem is the ID mask node. You blur your image and then crop it to the bounds of your object. so every pixel outside those boundaries get deleted.

I'd suggest adding the depth of field pre comp by adding the values for focus and aperture to your camera (you can often see the f-stop of the background image in the meta data, otherwise, just try and error).

enter image description here enter image description here

Make sure, that your background is transparent by checking "transparent" in the film section of the render settings.

enter image description here

Then just add your object via an alpha over node to the background. Done.

enter image description here

If you do want to add DoF in the compositor, just skip the step with the camera settings, use the defocus node and the alpha over. Done (even quicker).

enter image description here

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.