EvergineTeam / Feedback

Feedback, feature requests, and bug reports for Evergine.
https://evergine.com
14 stars 1 forks source link

Model select #162

Closed JuandreG closed 1 year ago

JuandreG commented 1 year ago

Hello.

How can I go about selecting a model in the scene at runtime? The scene contains multiple models and I'd like to be able to select and manipulate a model. a Service could be used to track which model is selected to ensure only 1 model can be manipulated at a time.

If someone could guide me in the right direction I would appreciate it a lot.

I want to be able to translate and rotate a model at runtime of the resulting UWP or WPF application.

Trifido commented 1 year ago

Hello @JuandreG , A simple way could be to create a boundig (box, sphere, etc) to those models and perform a ray casting from the mouse. Keeping the first element that intercepts with the ray. Bounding info: https://docs.evergine.com/2023.3.1/api/Evergine.Mathematics.BoundingBox.html Ray info: https://docs.evergine.com/2023.3.1/api/Evergine.Mathematics.Ray.html