Twin TopoDS_Edge

waldeinsamkeit05

CAD practitioner
Hi Guys,
Is there any way to detect and select an Edge which is someway connected to another Edge? The edges can not be connected via makeWire methods. When one of the edges is higlighted via mouse move, the other will be higlighted. It is like quantum entanglement :)).

I thought reediting mouseMoveEvent() function can work but will require much computation. The other method would be that the edges are connected via hidden shape but don't know how to.

Can you help me?
Thanks
 

natalia

Moderator
Staff member
Hi waldeinsamkeit05,

One of possible solution is managing it in AIS presentation.

Highlight is processed on AIS level in OCCT. One of possible ways is implementing your own presentation(a child from AIS_InteractiveObject). This presentation will have your couple of edges. When the mouse is over one of the edges, you'll paint another edge as also highlithed.

The sample of how doing this is for example AIS_TrihedronOwner(or AIS_ManipulatorOwner). Highlight paining is performed in the HilightWithColor method of the owner, this is the point to start from)
 
Top