How does Stencil Outline work and is it efficient on mobile GPUs?

Godot Version

4.6

Question

I’m working on the artistic direction of a mobile godot game and i’d like to add an outline for a simple cell shaded effect. I’ve read on this post from the Godot Forum that depth related work tends to be expensive on mobile GPUs, so I’m guessing I shouldn’t use an edge detection method based on depth.

From what I know (as a beginner in realtime rendering ), I have two options left :

  • Either use the inverted hull method, but I think it looks ugly and the thickness is unconsistent imo
  • Either use the stencil outline feature

**My question is : What is the “stencil”, how does the outline work with it, is it a smart choice for an outline on a mobile GPU and if possible why ? **

This is all to understand different mobile rendering techniques better :slight_smile:

Thank you for your time !