B3.2 - Outline shader in cycles

Hi there :smiley:

Blendermarket refused my subscription ( i guess they prefer big expensive complicated things more than simple free ones… A matter of margin, probably :smiley: ) therefore i’m forced to post this here :smiley: ( and i think BA community might be glad of it ! )

Look at this:

Those of you know this outline shader works perfectly in EEVEE 3D view render but cycles uses to render this kind of thing in a black blob ( except if the object has an emit node…

Well, this one is a diffuse node with an outline, rendered in cycles :smiley:

I guess you can’t wait for the outline node. Here it is:

The common material node is anything you want; from emit to principled… The render is perfect.

For having this outline effect, just take your mesh, add a solitify mod and flip normals.
Choose the outline material for the rim and voilà :smiley:

For those wanting the blend i’ll post it here on demand ( provided it’s not too big^^ )

Happy blending !

1 Like

Here’s another nodes that seem to work in cycles:

image

2 Likes

This is a long standing technique in Eevee, it’s quite promising that you can do it in Cycles now. To be fair, without a Shader to RGB node, Cycles still can’t do NPR work, but this is a huge step in that direction. If they ever make the Shader to RGB node in Cycles I’ll have to seriously consider switching my workflow over to get the benefits of Cycles

1 Like

indeed ! grabbing the shader output is a big lack in cycles !
Imagine what we could dou with R, G, B and moreover A !!! :smiley:

I posted this here as rim display is a pain in cycles and i confess this workaround is not from me but i found it… errrr… somewhere on the web XD ( i sincerely don’t remember where…)

I also tried the rim calculation we use in unity3D but the result was not totally satisfying.

Now, even without any update, community can do outlines in cycles :smiley:
Hope this will be usefull !
Anyone could make an output shader called principled outline or diffuse outline or emit outline… ( i didn’t try other hair and volume shaders… )

1 Like

Here we go :slight_smile:

I know it’s pretty much ugly in a closer view but it is pretty much what i expect for my lil vid:

I want those toons very roughly drawn just like did Eugene Viollet-Le-Duc in the drawings of his works:
image
Mine will be as big as this in full res video:

As usual in 3D, perfection is conditionned to point of view :smiley:

Hope you like it !
And happy blending !
EDIT: note we can add alpha on rim !!! this is as unexpected as marvellous ! :star_struck:

EDIT2: I’m reaaaaaaly glad this can be done in blender ! Formerly i made my vids and anims in unity just because blender was kinda shitty in one thing or another ( hey devs ! don’t sleep ! there are many points you still gotta work :stuck_out_tongue: )
But… it appears to me that ( even after some dirty or strange hacks for materials ) blender is IMHO ready for an ‘in the great courtyard’ intrusion. I’m a technically bad, dumb and lazy user. And when those kind of people can easily do amazing things, we can say the tool is mature :slight_smile:

So i have to congrat the devs ! But also kikass as work has to be kept-up :stuck_out_tongue:

As i already said, B3.2 is a great turn to me :slight_smile:

Happy blending !

2 Likes

You might have inadvertently broken some terms of use with your project (or account).

1 Like

hi @RPaladin :slight_smile:

Thanks for taking some of you time for my case :smiley: <3 even if it is out of topic :wink:

In fact i created my account with << small usefull things in many domains >> in the ‘what you do’ field.
I rarely sell things and prefer sharing as do many people in the community ( i’m not a commercial excited with money; i’m more a geek excited with hacks-to-share :stuck_out_tongue: )
BM answered me ( and even if i’ve been deceived, i have to say this was totally clear ) they preferred bigger things ( tools, assets, tuts, etc… ) with more added-value and just don’t care share of simple things.
I’m okay with this :slight_smile: I’m not the center of universe and i know that i just wont take a peek at their website anymore as i’m at the opposite of their point of view.

Thanks again for your kindness and feel free to remove this OOT post :wink:

Happy blending !

Hi, really appreciate the workaround ! I’ve been looking to make this work for Cycles. It can be further improved by using a logic NOT for camera rays, instead of adding together diffuse and shadow. This way it allows every ray (even glossy) to appear through the outline shell.

1 Like

Glad you like it @Hadriscus :smiley:

Hmmm your idea seems interresting !!!

Would you have some few time for an example node setup and result please ? :smiley:

Happy blending !

silhouette_passthrough.blend (1.5 MB)

Yes, here is a comparison. I positioned a mix shader and a render border focused on an area that shows changes, so that you can see the difference. Tell me what you think

1 Like

I think it looks much better than my method !

Am not sure why but, the smaller details look better… Maybe because of your solidify params, of sibdiv modifiers ?

I keep this in my drawer and will surely use it when i need it agan :smiley:

Thanks a lot @Hadriscus !!!
And happy blending !

EDIT: now i have to find a way of simulating irregularities in outline, just like if it were drawn with a paper pen^^ :wink:

1 Like

It should really only let glossy rays through (in addition to diffuse), but tbh I haven’t tested on anything else than Suzanne…

1 Like

For the particular use i make of those outline shaders ( you can see my lil vid here: Carcassonne Medieval city - #382 by pitibonom ) i don’t need gloss. My toons are often seen from far away and are intended to be ‘paper-pen’ drawn.

But no doubt that gloss will be usefull for many other users who want an outline shader in cycles^^

Happy blending !

1 Like

I’ve watched it already, the technique does a good job of looking like an actual pencil outline !

1 Like