I am currently experimenting with modifying the OutlinePass in threejs to create outlines of connected objects in clip space (after applying the projection matrix). While these objects may appear separate in 3D space, they are considered connected after projection.
Before Implementing Outline Pass:
After Implementing Outline Pass:
My goal is to outline only those objects that are connected to the object selected by the user's mouse. Currently, I have successfully managed to draw outlines of objects in their projected state.
However, when selecting the middle object with the mouse, I encountered a challenge where the torusgeometry object on the left side of the sample image does not display an outline as desired.
If anyone has suggestions or alternative methods for achieving this effect, I would greatly appreciate any input or examples shared.