Interaction of mouse with 3D *.obj file
I have imported a car as *.stl file. I want to add some "devices" onto it for visualization.So When I perform a right click on the Car, at this position a Sphere should come up. I want to do a doubleclick on that sphere, and enter something like name, filepath for a text file and so on.
Also I want to ensure, that the user can not add multiple spheres over each other on the same position.
It tried to cath this situation with the following:
if (!CreatedDevices.Any(t => Math.Abs(t.Center.X) + 300 > mousePos.X))
So the mousePos is the position of my mouse and the CreatedDevices is a list of spheres with their properties like center and radius etc..
However, I am not able to doubleclick on a sphere and do something, and in addition to that the mouse position.x is sometimes -83 and the sphere position.x is 1200. I think it has something to do with the Coodinate system of my obj file and that my mouse is not in the same coordinate system. is this possible? I attached my whole project - I need some urgent help because I have no clue how to go on from here... thanks a lot!My project should be attached.
Customer support service by UserEcho
This is the Link to the project: