Improved inverted hull (simplest outline shader improved++)
This shader is like CountingClowns simplest outline shader improved, but a bit more improved. So its improved++ 🤡
This one allows more control over border width in each point, so you can workaround some problems of the inverted hull technique.
But it requires to store border width in the vertex color’s red channel. That’s why in my video tutorial (its in spanish buts is quite simple to follow, see below) I’m using blender and a python script in order to save that border width in the vertex colors in a very simple and fast way.
A sample project with that blender script is also available in my github repo (see below).
Shader code
shader_type spatial;
render_mode unshaded, cull_front;
uniform float weight = 0.1;
uniform vec4 color : source_color = vec4(0.0, 0.0, 0.0, 1.0);
void vertex() {
VERTEX += NORMAL * weight * COLOR.r;
}
void fragment() {
ALBEDO = color.rgb;
}

