1
$\begingroup$

Hey there Blender Community,

I am attempting to render just the outline of a fully transparent object on a transparent background (in Cycles). Using a material index pass and an inverse Sobel filter, I am able to produce the outline effect successfully on a white background. See below:

Functioning Object Outline on White Background

However, when I make the film (the background) transparent, the outline disappears. Is there a way to keep the black outline of the fully transparent object on an a transparent background?

The same node setup, but with film set to transparent:

Nonfunctional Object Outline on Transparent Background

My thanks in advance for any assistance or pointers in the right direction.

$\endgroup$
1
$\begingroup$

Not the most elegant solution, and probably there is a better one, but if I understand correctly maybe this will help:

enter image description here

click to enlarge

Using a Color Key node to replace the white with transparent pixels, and adding the key to the image seems to work well in this case.

$\endgroup$
  • 1
    $\begingroup$ This worked beautifully for me. (And I'd say that adding only one node is a pretty elegant solution.) Thanks very much! @Timaroberts $\endgroup$ – Colin Conwell Jan 23 '18 at 19:37
  • $\begingroup$ @ColinConwell, you're welcome. Glad to help. $\endgroup$ – Timaroberts Jan 23 '18 at 21:42
  • $\begingroup$ One question: Would it possible to somehow animate this? Such that the color drained out over some number of frames? $\endgroup$ – Colin Conwell Jan 23 '18 at 22:14

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.