Is there a clever way to get selection of faces at silhouette of mesh?

Hi everyone,

I’m looking for a way to get an array of faces that make up the silhouette of a mesh.

I’ve attached an example: I’ve colored the faces of a sphere green, together they form the silhouette.

The only idea I’m having is to get Custom Depth for the mesh and from there on cast rays around its edges to find faces. But that seems too complicated, expensive and I would end up with more faces than I need.

Maybe you have a clever way to approach this or is this kind of information accessible through C++ already and I missed it?

Thank you for any ideas or feedback!