OpenXR/OpenVR (virtual reality support), new Python workbench WiP

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
mr_guy99493
Posts: 1
Joined: Fri Jul 31, 2020 10:58 am

Re: OpenXR/OpenVR (virtual reality support)

Post by mr_guy99493 »

Do you imagine it will be straightforward to add tools for use within the VR view?
Ie, open a sketch and pull a rectangle from some pallette before drawing and constraining as usual?
Or will this just be for viewing models?
User avatar
kwahoo
Posts: 680
Joined: Fri Nov 29, 2013 3:09 pm
Contact:

Re: OpenXR/OpenVR (virtual reality support)

Post by kwahoo »

My initial idea is to expose VR events to Python and then create some kind of Python shim between VR navigation/picking/view and standard FreeCAD tools.
Eg. you are pressing a trigger when a controller is near an 3D object, and FreeCAD opens a widget above the controller gizmo. The widget would contain info about the object and editable fields. If object is draggable (eg. a sketch's point) the controller should be able to drag the object.

Edit, this may be useful
phpBB [video]


and this https://github.com/belab/widgetTo3dTexture
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: OpenXR/OpenVR (virtual reality support)

Post by Kunda1 »

That would be so awesome!
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
User avatar
openfablab
Posts: 62
Joined: Wed Nov 02, 2016 4:42 pm
Contact:

Re: FreeCAD-VR: Oculus Rift

Post by openfablab »

I think sketching can be done with some device like pen and auto recognition of geometric features and numbers. And also with voice commands.

I imagine transparent rectangle situated where real user table is. When model face is selected for sketching, it is aligned to table.

What we would really miss in VR is feeling of tactile feedback from things we touch.
User avatar
kwahoo
Posts: 680
Joined: Fri Nov 29, 2013 3:09 pm
Contact:

Re: OpenXR/OpenVR (virtual reality support)

Post by kwahoo »

openfablab wrote: Fri Aug 14, 2020 4:43 pm I think sketching can be done with some device like pen and auto recognition of geometric features and numbers. And also with voice commands.
There is no need for an additional device. Standard motion controllers are precise enough.
phpBB [video]


I'm afraid that auto recognition and voice command would be slow and unreliable. Also a lot of code to write. Tilt brush style menus are convenient and reliable.
openfablab wrote: Fri Aug 14, 2020 4:43 pm What we would really miss in VR is feeling of tactile feedback from things we touch.
Not really, a human brain is quite easy to cheat. If you see object collision, you think it really happened, unless you move the hand too far. This works similarly to mirror therapy.
User avatar
kwahoo
Posts: 680
Joined: Fri Nov 29, 2013 3:09 pm
Contact:

Re: OpenXR/OpenVR (virtual reality support)

Post by kwahoo »

Small performance update.

The Linkstage3 branch rendering is noticeable faster than the main one. I noticed it could run even 3x faster on my hardware. So, for testing I applied the VR patches on top of the Linkstage3.
An improvement is clearly visible. Running two render targets 2016x2240 pixels and MSAAx8 antialiasing, I got about 7ms frametime for medium detailed engine model, and 37ms for very fine detailed Mars Rover model. The hardware is Radeon 5700XT and Ryzen 1700.
User avatar
HakanSeven12
Veteran
Posts: 1481
Joined: Wed Feb 06, 2019 10:30 pm

Re: OpenXR/OpenVR (virtual reality support)

Post by HakanSeven12 »

+1 nice job ;)
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: OpenXR/OpenVR (virtual reality support)

Post by Kunda1 »

That is so cool to hear. Have you told realthunder ?
realthunder wrote: pinged by pinger macro
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
realthunder
Veteran
Posts: 2190
Joined: Tue Jan 03, 2017 10:55 am

Re: OpenXR/OpenVR (virtual reality support)

Post by realthunder »

That's awesome. You know I started using FreeCAD because I want to build my own AR device. I still believe that dream will come to a full circle one day. I am currently refactoring the rendering part to try to catch up with modern graphics. Maybe soon we'll be able to walk inside a FC project like some kind of game.
Try Assembly3 with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal
User avatar
kwahoo
Posts: 680
Joined: Fri Nov 29, 2013 3:09 pm
Contact:

Re: OpenXR/OpenVR (virtual reality support)

Post by kwahoo »

realthunder wrote: Sat Sep 12, 2020 12:43 am Maybe soon we'll be able to walk inside a FC project like some kind of game.
Do you mean mixed reality? Because in VR room scale locomotion does work for a while. That's why my test project is a simple room Fcstd Video

There is not collision detection, but I fell it would be more distracting than useful.
Post Reply