Closed HerrAugust closed 3 years ago
Of course. It is all about how you set the canvas and camera of the workspace.
RenderMode
of Canvas to World space
.Hello,
Thank you for your feedback, actually I could make it work. However, it seems that drag&drop does not work properly and I run out of ideas. The video shows the not working parts, any idea for the drag&drop?
Thanks again!
https://user-images.githubusercontent.com/5053385/126512178-518b33d3-0fea-4d5a-9e95-42ee204ea9d0.mp4
It works fine with me, please see the video. I guess maybe there is something wrong with your pointer position map. https://user-images.githubusercontent.com/2181062/126595064-cd768336-9e40-4ae9-8b88-c8181b27661d.mov
Hello and thank you for your feedback. Yes, with the mouse it works great. My problem comes when used on Oculus Quest 2 and using the controller with ray-casting.
https://user-images.githubusercontent.com/5053385/126512178-518b33d3-0fea-4d5a-9e95-42ee204ea9d0.mp4
Just a quick discover, it seems that the blocks can be moved around with the head (but only with its rotation) once you put them on the programming box. The Oculus Quest 2 controllers do not work properly instead. Any tip?
Please check the position calculation code when dragging blocks in BlockView.cs:
OnBeginDrag
, OnDrag
.
I use a helper function RectTransformUtility.ScreenPointToLocalPointInRectangle
to calculate the local position of blocks from mouse position.
There might be some additional work to do with 3D conversion. I haven't tried Oculus Quest 2. Sorry that I couldn't help you more currently.
Hi,
I would like to use this project in a virtual world created for Oculus Quest 2. Is there any way to visualize this program in a Canvas? I mean, I do not want the program to take all the space, I want to embed it in my virtual world, as shown in the attachment.
Thanks!