Topic: Adapt map control for VR
I have the chance to work with an oculus rift this week, and i'm trying some experiments.
I'm trying to virtualize my application. I mean that i did set up the main camera to render to a texture instead of rendering on the screen, an put this texture to a "fake screen". Now i want to be able to interact with the map.
As you can see in this Gif, i'm trying to control the map using the oculus touch.
Right now i'm performing a raycast, and retrieving the texture coordinate of the hit point.
So i think that i should trigger a mouse click, using the texture coordinate to "emulate" a screen position. This would give me the ability to use the map control, add marker at certain coordinates, etc ...
1) Is that a good approach ? How would you proceed to call a mouse clic at a certain position ?
2) Or are there any functions to control the map that i could call to do this job ?
3) Would this also give me the abilitie to press my UI buttons ? (my ui is on a canvas which is set to overlay the "map" camera.) I know i could set those ui elements to world space, position them onto the fake screen, add a box collider to every button and trigger them with my controller but if i could just simulate a screen click that should work without having to change anything in my UI right?