How would you go about creating a mask ONLY of the silhouette/outline of your mesh?

I want to use it to fade the outline of the mesh into transparency but using popular methods like the fresnel into a greater than math node will also affect e.g. the nose of my character even though I only want to fade the silhouette. I essentially want an even white line/gradient from the silhouette of the model going inwards.

Can you use geo node for something like this? Maybe have somehow compare vectors of the mesh with that of the camera view? Don't know how to proceed. Would prefer a non geo nodes solution but I'll take any.

Thanks a lot and here is to hoping we can figure this out!


1 Answer 1


Soo after a lot of research I have found two viable solutions for this. First one, not really practical but will still work: For this you will create a cryptomatte in compositing and feather the edges of said cryptomatte with a dilate/erode node and save those images in a dedicated folder via a file output node. If you need the actual outline, use the subtract output from the attached picture, if you want to use it as a mask it's cleaner to use the marked mask output. You can then import that image(sequence) in the shader editor and connect the texture coordinate output "window" to your vector input in the mapping node. Fun Fact: I found a bug that doesn't allow you to use cryptomattes when using the Blend Mode: Alpha Blend, so make sure to set it to Hashed or Opaque. enter image description here

The other, and easier method is to use goo engine. This is a custom build optimized for 3d anime in blender. It has a node in the sahder editor called "curvature" that allows you to give objects outline a mask - in realtime without rendering the cryptomatte. To install this follow this reddit post, it sounds daunting but it's a really easy step by step requiring no input other than a few clicks and some copy pasting. You essentially download and install their version of blender. https://www.reddit.com/r/blenderhelp/comments/ywupnw/how_do_i_build_goo_engine/

You can also go to goo engines patreon and buy a built version there for 5€. It will be the same result in the end but the patreon supports their work. enter image description here

For objects with flat surfaces such as cubes it may be better to use the first method, depends on your needs. Feel free to ask if you need help at any step.

Another edit: So, I came across the raycast node in geometry nodes. Compare the raycast of your original geometry with the geometry of an object that was scaled along its normals. You will get an outline, maybe you can blur this further to get a better result, but it's a start. You could then send this to the shader editor via attributes. BUT this isn't nearly as good of a version as the cryptomask. enter image description here enter image description here


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .