Jump to content

Visualizer interaction


photo

Recommended Posts

Hi everyone,

is there any way to get callbacks when clicking on/hovering over a shape drawn by the Visualizer class ? I'm interested in achieving stuff like :

- Changing the color of a point drawn with Visualizer::renderPoint3D(...) when hovering over it.

- Receiving the XYZ coordinates of that point when clicking on it

It seems that intersections won't help since the shapes drawn aren't objects and have no physical properties.

I know there must be some way to do it since the XYZ axis in the editor are drawn by visualizer (or something similar I guess) and it is interactive. It changes color when you put your mouse over it, and clicking on it makes you able to move nodes around. Is it achieved by applying an invisible body to the shapes drawn and then using raycasting from the mouse position to the shape ?

Link to comment
×
×
  • Create New...