Board index FlightGear Development New features

Oculus Rift Support

Discussion and requests for new features. Please note that FlightGear developers are volunteers and may or may not be able to consider these requests.

Re: Oculus Rift Support

Postby mike4 » Thu Mar 02, 2017 10:24 am

Which makes it useless. Simply use:
https://github.com/ValveSoftware/openvr
for all devices without headache.
Swiss (non GPL) airports:
http://fgfs.sgier.com/
mike4
 
Posts: 80
Joined: Mon May 28, 2012 6:03 am
Version: GIT
OS: Ubuntu etc.

Re: Oculus Rift Support

Postby mich » Thu Mar 02, 2017 11:25 am

Sorry mike4, which is your idea about FG and Oculus?
How can I use https://github.com/ValveSoftware/openvr to adapt the Oculus to FG?
Mich
mich
 
Posts: 22
Joined: Fri Nov 11, 2016 11:08 am

Re: Oculus Rift Support

Postby Michael.George.Hart » Tue Apr 11, 2017 2:30 pm

I am just starting to work out how to make HTC Vive work with FG. I am still reading through the Oculus pages and blog to see what was done prior... Oculus seems to be a dead project ... I am wonder what happened to it
Michael.George.Hart
 
Posts: 1
Joined: Tue Apr 11, 2017 2:16 pm

Re: Oculus Rift Support

Postby Johan G » Sun Apr 16, 2017 1:27 am

Michael.George.Hart wrote in Tue Apr 11, 2017 2:30 pm:Oculus seems to be a dead project ... I am wonder what happened to it

I am under the impression that many early potential developers and integrators who supported it through buying development kits was a bit put off when it did not stand on it own legs but instead was bought by Facebook who seemed to have different agenda than they had.
Low-level flying — It's all fun and games till someone looses an engine. (Paraphrased from a YouTube video)
Improving the Dassault Mirage F1 (Wiki, Forum, GitLab. Work in slow progress)
Some YouTube videos
Johan G
Moderator
 
Posts: 6629
Joined: Fri Aug 06, 2010 6:33 pm
Location: Sweden
Callsign: SE-JG
IRC name: Johan_G
Version: 2020.3.4
OS: Windows 10, 64 bit

Re: Oculus Rift Support

Postby mike4 » Tue Apr 18, 2017 6:21 am

Not only that, they even broke compatibility between dev. kits. X-plane had it working but after the dk2 update they would have needed to redo all, hence they've put it on ice.
Another reason to use steamvr/openvr, which is also opensource and supports all devices.
Swiss (non GPL) airports:
http://fgfs.sgier.com/
mike4
 
Posts: 80
Joined: Mon May 28, 2012 6:03 am
Version: GIT
OS: Ubuntu etc.

Re: Oculus Rift Support

Postby ludomotico » Tue Apr 18, 2017 12:29 pm

mike4 wrote in Tue Apr 18, 2017 6:21 am:Another reason to use steamvr/openvr, which is also opensource and supports all devices.


openvr is NOT open source and it does NOT support all devices.

(Disclaimer: the core of openvr has a BSD-like license. But the core is not functional "as is", it needs specific drivers for each hardware. Drivers do not need to be open source. Currently and afaik, none of them are open source.)

openvr is a specification for the vendors of VR hardware. The idea is similar to OpenGL: the vendors must implement the drivers compatible with the specification.

Last time I checked, the Oculus SDK did not support Linux in any form, open or not. Hence, Oculus does not provide drivers for Linux. Hence, openvr does not support oculus in Linux.
User avatar
ludomotico
 
Posts: 1269
Joined: Tue Apr 24, 2012 2:01 pm
Version: nightly
OS: Windows 10

Re: Oculus Rift Support

Postby paju1986 » Mon May 15, 2017 10:28 am

I think the best way will be to integrate it with OSVR wich is truly open source and has plugins to make it work with HTC vive and Oculus rift.
paju1986
 
Posts: 246
Joined: Sun Oct 30, 2011 8:42 pm
Location: Badajoz (Spain) - LEBZ
OS: Arch Linux

Re: Oculus Rift Support

Postby MrMinimal » Wed Jun 14, 2017 10:18 am

SteamVR is not open source and not all HMDs are supported.
At the same time, there is a lot of involvement with Steam itself.

I think the best way will be to integrate it with OSVR wich is truly open source and has plugins to make it work with HTC vive and Oculus rift.


I agree.
It adds another abstraction layer between the hardware and the HMDs.
FlightGear has to be compatible to the OSVR interface, so all HMDs supported by it, will work for FG as well.

That would be the best solution, the performance trade off should be minimal.
MrMinimal
 
Posts: 17
Joined: Fri Sep 19, 2014 2:29 pm

Re: Oculus Rift Support

Postby juergen » Sun Jul 02, 2017 9:01 am

DK2 integration.

If somone is interested here is my really simple integration of the Oculus DK2:

1. I had the Oculus DK2 already running on a Windows 7 PC
2. After trying a lot of solutions withot success I installed freePIE
3. I searched for the exact (old) version number of the Oculus software they used to program freePIE and installed it on my PC
4. I downloaded a FreePIE Script (Python) that supports Oculus as a Joystick/Mouse in Flightgear
5. It took me half an hour to correct a Bug in the Script
6. I run Flightgear in 3D View with "split screen"
7. I press the TAB Key two times so the Oculus contolls my view by controlling the computer mouse

The immersion is great even if the screen is stretched by about 15%. The Head Tracking works really well if I correct the view angle and the zoom from time to time with the keys on my joystick.
I use a Saitek Yoke and Peddals what I really reccomend for a realistic feeling.
On the keyboard I attached little plastic dots on the needed keys to find them while wearing the Oculus.

Is someone is interested I could post more details.
juergen
 
Posts: 1
Joined: Sat Jun 24, 2017 12:03 pm

Re: Oculus Rift Support

Postby Hooray » Sun Jul 02, 2017 10:13 am

juergen wrote in Sun Jul 02, 2017 9:01 am:Is someone is interested I could post more details.


Actually, it would be great if you could document your journey by creating a corresponding wiki article and adding screenshots/videos to that - we have a number of similar tutorials, some of them also covering hardware interfacing, for instance, check out the following articles:

http://wiki.flightgear.org/Howto:Use_Ar ... ut_Arduino
http://wiki.flightgear.org/Howto:Build_ ... rototyping
http://wiki.flightgear.org/Howto:Build_ ... _5_minutes
http://wiki.flightgear.org/Howto:Create ... instrument
http://wiki.flightgear.org/Howto:Build_ ... re_trainer


Creating a similar article for the wiki covering your approach would have the added advantage that we could add this to the upcoming July newsletter
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: Oculus Rift Support

Postby sdef » Mon Oct 30, 2017 9:04 am

Does Oculus touch or HTC vive support integration with flightgear. Kindly please suggest any support and integration techniques to configure flightgear for HTC Vive or Oculus touch.
sdef
 
Posts: 7
Joined: Tue Mar 21, 2017 10:02 am

Re: Oculus Rift Support

Postby xcvb » Sat Feb 17, 2018 7:52 am

Barrel distortion is possible in Rembrandt:

Image

Too bad that 3D isn't really working here:

Image

I did't find a way to do the same in ALS. You need access to a texture with the framebuffer content inside an extra fragment shader (I used display.frag here):

Code: Select all
#version 120

uniform sampler2D lighting_tex;
uniform sampler2D bloom_tex;

uniform sampler2D bufferNW_tex;
uniform sampler2D bufferNE_tex;
uniform sampler2D bufferSW_tex;
uniform sampler2D bufferSE_tex;

uniform bool showBuffers;

uniform bool bloomEnabled;
uniform float bloomStrength;
uniform bool bloomBuffers;

uniform bool bufferNW_enabled;
uniform bool bufferNE_enabled;
uniform bool bufferSW_enabled;
uniform bool bufferSE_enabled;

void main() {
   vec4 color = vec4(0.0, 0.0, 0.0, 1.0);
   float alpha = 0.2;

   vec2 position = vec2(2.0 * gl_TexCoord[0].xy - 1.0);
   position = position / (1.0 - alpha * length(position));
   position = (position + 1.0) * 0.5;

   if(position.x > 0.0 && position.y > 0.0 && position.x < 1.0 && position.y < 1.0)
   {
      color = vec4(texture2D(lighting_tex, position).rgb, 1.0);
   }
   gl_FragColor = color;
}
xcvb
 
Posts: 132
Joined: Sat Mar 14, 2015 3:08 pm
Version: Next
OS: Fedora Kinoite

Re: Oculus Rift Support

Postby Thorsten » Sat Feb 17, 2018 8:00 am

You need access to a texture with the framebuffer content inside an extra fragment shader (I used display.frag here):


I don't think so - you just need to make sure every fragment shader runs the operation, which is what filters_ALS. frag is for - of course declaring the uniforms for every effect is cumbersome, but conceptually it is possible.
Thorsten
 
Posts: 12490
Joined: Mon Nov 02, 2009 9:33 am

Re: Oculus Rift Support

Postby xcvb » Sat Feb 17, 2018 8:09 am

Thorsten wrote in Sat Feb 17, 2018 8:00 am:
You need access to a texture with the framebuffer content inside an extra fragment shader (I used display.frag here):


I don't think so - you just need to make sure every fragment shader runs the operation, which is what filters_ALS. frag is for - of course declaring the uniforms for every effect is cumbersome, but conceptually it is possible.


The crucial part is:

Code: Select all
texture2D(lighting_tex, position)


I wonder what to use instead of lighting_tex in filters_ALS.frag. Besides of that filters_ALS.frag seems not to be the final step. If I return vec4(0.0, 0.0, 0.0, 1.0) the sun is still present.
xcvb
 
Posts: 132
Joined: Sat Mar 14, 2015 3:08 pm
Version: Next
OS: Fedora Kinoite

Previous

Return to New features

Who is online

Users browsing this forum: No registered users and 7 guests