Board index FlightGear Support Hardware

Oculus Rift Development

Joysticks, pedals, monitors.

Oculus Rift Development

Postby fg4drt » Thu Jun 13, 2013 1:07 am

If I bought an Oculus Rift Developer's Kit, would I, not being a developer, be able to get head tracking to work with FlightGear? If I couldn't do it completely on my own, would there be people on this forum who'd be willing to help me implement it?

Or has this work already been done? What is the status of Oculus Rift integration with FlightGear?
fg4drt
 
Posts: 64
Joined: Tue Apr 23, 2013 9:55 am

Re: Oculus Rift Development

Postby Hooray » Thu Jun 13, 2013 11:09 am

I don't think there's anything OR specific, but there are a bunch of unrelated "head tracking" solutions for FG available, i.e. side-projects, such as "FaceTrack IR" - I would suggest to look into these and see if/how they can be adapted for OR, so that certain parts could be reused and integrated, given the availability of SDK docs, that shouldn't be overly difficult. You could probably come up with a dedicated I/O protocol - or even just use the telnet protocol for prototyping.

Finally, look at their FAQs
I’m not a developer. Should I buy a developer kit now or wait for the consumer version?

If you are asking this question, the answer is most likely “Wait”.

The consumer product will improve on almost every aspect of the developer kit, which is essentially an early prototype of the consumer version. This includes comfort, immersion, features, software support, etc… for the absolute best virtual reality experience possible.

If you absolutely must have one, please understand that the developer kits are more or less early prototypes of the consumer version and with very limited software/game support when they ship.

So if you’re not a developer or hardcore enthusiast, sit tight for now. We promise the consumer Rift will be worth the wait!

The two main steps for integrating the Oculus Rift are:

(1) Integrate Rift motion tracking with your character’s view camera transformation, enabling looking around the world, and

(2) Implement stereoscopic 3D rendering and optical distortion adjustment that produces the correct left/right eye image on the device.

Our SDK will assist with both of these tasks, providing accelerometer and gyro data, screen size information, as well as pre-made shaders to simplify development and abstract away hardware details.


FlightGear already supports #1 and #2 here, it's all exposed through the property tree, so the difficult stuff is already done, now it's just a matter of integration/interfacing.

Also, see: http://en.wikipedia.org/wiki/Oculus_Rift
Connection Developer kit: DVI/HDMI and USB,[4] Consumer version: TBA

A USB interface is used for sending tracking data to the host machine and powering the device, potentially negating the need for an external power supply. However, since its power requirements slightly exceed the rating for USB, it will come with a power adapter that can optionally be used to connect the control box to a power outlet for those computers that don't provide enough USB power.


Thus, the most relevant FG-specific feature request is (feel free to leave a vote there): https://code.google.com/p/flightgear-bu ... ail?id=619
Also see: http://www.mtbs3d.com/phpbb/viewtopic.php?f=140&t=15628
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 Development

Postby fg4drt » Thu Jun 13, 2013 5:27 pm

Hooray wrote in Thu Jun 13, 2013 11:09 am:FlightGear already supports #1 and #2 here, it's all exposed through the property tree, so the difficult stuff is already done, now it's just a matter of integration/interfacing.

That sounds like you're saying it wouldn't be difficult to do the integration. How likely is it that no one has done it?
fg4drt
 
Posts: 64
Joined: Tue Apr 23, 2013 9:55 am

Re: Oculus Rift Development

Postby Hooray » Thu Jun 13, 2013 5:52 pm

see my previous posting, there are several options for integrating things - the "best" being proper USB/HID support built right into FlightGear, i.e. through Nasal/cppbind bindings or by mapping USB/HID devices into the property tree. A simple workaround would be a standalone application that supports USB/HID devices, and simply uses a custom protocol to talk to FlightGear, which is the more traditional way, but also more complicated to set up for people.

Given you that you seem to have the hardware already, I'd suggest to get in touch with the OR community and ask them if anybody has considered supporting FlightGear. A standalone application would not be difficult to create, but the right solution would be directly supporting USB/HID devices through FlightGear, without any shim layers needed.

Overall, the whole FSWeekend 2012/Saitek discussion is also primarily about supporting USB devices:

Subject: Saitek Panels

Hooray wrote:I think you should be getting in touch with Saitek and explicitly ask them about their FG support. You probably didn't (yet) look at the link that I posted, but according to the FSWeekend 2012 discussion, Saitek seemed interested in supporting FG and actually sponsored /some/ hardware - so it would be a matter of asking them, and check back regarding their priorities - which could in turn could mean that they might prioritize supporting and further support/funding of the effort. I cannot speak with authority obviously, but the developers who did get access to some Saitek hardware are extremely involved in other parts of the project, and according to the commit history, none of the Saitek development seemed really a priority since FSWeekend 2012 - which in turn means, that Saitek apparently did not really look at contracting FG developers to get some of their hardware supported. But it is something that developers are interested in: https://code.google.com/p/flightgear-bu ... ail?id=619

So, please check back with Saitek before purchasing anything to be specifically used with FlightGear.

For the full Saitek/FSWeekend 2012 discussion, see: http://www.mail-archive.com/flightgear- ... 38667.html



http://www.mail-archive.com/search?q=fs ... eforge.net
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 Development

Postby fg4drt » Thu Jun 13, 2013 7:00 pm

I don't have the Oculus Rift already. I'm trying to decide if I should order one. I would only order one if I thought I could get it to work with FlightGear. If all the difficult work to accomplish that has already been done, how likely is it that no FlightGear core developers or enthusiasts have also done the easy work that remains?
fg4drt
 
Posts: 64
Joined: Tue Apr 23, 2013 9:55 am

Re: Oculus Rift Development

Postby Hooray » Thu Jun 13, 2013 7:12 pm

See my previous posting. You seem to be looking for someone who has a ready-to-go solution, which isn't going to happen anytime soon. We only have a bunch of active core developers, who are fairly busy with other aspects of FG. Not even USB/HID support is very high on their todo lists. However, that would obviously the topmost requirement for a 100% native FG solution.
Coming up with a standalone, platform-specific, application that talks USB/HID and connects to fgfs would not be very difficult - but it would be of little use to people using other platforms (FG supporting Windows, Mac OSX and Linux/Unix).

There are not too many cross-platform OSS libs for USB/HID communications, which is another concern. And then there are the OR SDK's legal requirements (i.e. license)
For example, see: http://www.signal11.us/oss/hidapi/

In other words, if you are specifically interested in using OR in combination with FlightGear, I would really only consider getting the development version, if you:

  • know how to build SG/FG from source
  • know about USB/HID communications
  • know about cross-platform programming
  • know C/C++
  • have some spare time/funding to get this started

We have a bunch of people here who would easily satisfy those requirements, but who are not really interested in OR obviously - which might be because of the costs involved in getting a development kit, i.e. there's a certain entry barrier.

I don't know of any experienced FG developers/contributors who have publicly stated having access to the corresponding hardware - which ultimately boils down to the same problem that Saitek/CH Products hardware has: developers need to have access to the hardware and specs, before it can be supported - and then, developers would ideally be sponsored, or it may take another eternity until support really materializes.

None of that means that it's difficult or even impossible, you could probably even team up with other contributors to get this started, or even use crowd-funding to sponsor such an effort to a certain degree. But at the moment, I don't see anybody "in the know" interested in helping out - most people will only be interested in working on this, once they get access to the hardware/specs and some spare time/funding.

In general, you'll be well-advised to get in touch with the OR folks, even just searching their forums would have yielded a bunch of relevant matches:
https://developer.oculusvr.com/forums/v ... f=42&t=362
We have people working with flight gear here and might look into rift support in the future. However, FlightGear is a GPL program and I'm pretty sure the Apache license that the SDK uses isn't compatible with GPL, so it might be "illegal" to use it...


https://developer.oculusvr.com/forums/v ... 487&p=4583
That raises a good point. Linking the oculus sdk with the released source code for any of the Quake or Doom series would be a gpl violation.
(Not that I wanted to, I avoid touching GPL code, but I'm sure some people might want to try)

Other games that are open source but incompatible due to gpl:
- flightgear
- oolite
- arx fatalis
- duke nukem 3d
- penumbra overture
- jedi outcast
- jedi academy
plus more.
(many more, but I only listed the ones that I thought would be good in vr)

Until making this list I didn't know arx fatalis had it's source released 2 years ago. It's one of the best first person rpgs, a spiritual successor to the Ultima Underworld series. It also uses a magic system where you write runes in the air with your hand, that would be awesome with a rift and a wiimote!
Last edited by Hooray on Fri Jun 14, 2013 11:27 am, edited 2 times in total.
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 Development

Postby fg4drt » Fri Jun 14, 2013 2:43 am

How does one get "crowd-funding" going? Would just enough money to get the Oculus Rift Developer Kit into the hands of an FG developer be sufficient, or would there be a need for funding beyond that?

It might be worth pointing out that the cost of having an Oculus Rift developer kit is in the same ballpark as adding a couple of decent monitors to one's system to have a multi-screen setup. So if there are folks thinking of doing that, they might consider looking into how much more amazing the Oculus Rift would be instead. I'm really surprised that' there's so little talk about it here on the forum.
fg4drt
 
Posts: 64
Joined: Tue Apr 23, 2013 9:55 am

Re: Oculus Rift Development

Postby Hooray » Fri Jun 14, 2013 11:26 am

The legal concerns voiced by some OR developers are not really justified, because these folks don't understand that linking apache/bsd code into GPL'ed code is no issue, vs. doing the same vice versa would be "viral" due to the GPL: http://www.apache.org/licenses/GPL-compatibility.html

crowd-funding would be a matter of starting a campaign, e.g. see kickstarter.com - which is also where oculus rift started: the project initiators ask for a certain amount of money, within a certain period of time - and promise something in return, in the case of OR, they asked for 250k USD and almost exceeded their funding goal by 1000%, see: http://www.kickstarter.com/projects/152 ... o-the-game

And yes, there's more to do than just providing the kit: people will need to spend their time developing code, which would be ideally paid time - keep in mind that some guys from Saitek have actually donated hardware to the project (well some individual core developers), but that didn't automatically make FG support a top-priority, because it's "just" hardware. But overall, the whole effort could be done for less than $5k, certainly less than $10k, within 3-6 months of spare-time hacking.

My suggestion would be to get in touch with the OR folks through their forum and post a follow-up there, including a link to the discussion you started here, because there seem to be a bunch of misconceptions, in particular regarding the legal repercussions of linking the Apache-licensed SDK into FG's GPL code.
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 Development

Postby fg4drt » Fri Jun 14, 2013 4:52 pm

Hooray wrote in Fri Jun 14, 2013 11:26 am:The legal concerns voiced by some OR developers are not really justified, because these folks don't understand that linking apache/bsd code into GPL'ed code is no issue, vs. doing the same vice versa would be "viral" due to the GPL: http://www.apache.org/licenses/GPL-compatibility.html

crowd-funding would be a matter of starting a campaign, e.g. see kickstarter.com - which is also where oculus rift started: the project initiators ask for a certain amount of money, within a certain period of time - and promise something in return, in the case of OR, they asked for 250k USD and almost exceeded their funding goal by 1000%, see: http://www.kickstarter.com/projects/152 ... o-the-game


When you mentioned crowd-funding, I thought you might have been referring to a more-or-less FlightGear specific mechanism that had been established to fund worthy projects. I doubt if I would be up to the task of creating such a mechanism myself.

And yes, there's more to do than just providing the kit: people will need to spend their time developing code, which would be ideally paid time - keep in mind that some guys from Saitek have actually donated hardware to the project (well some individual core developers), but that didn't automatically make FG support a top-priority, because it's "just" hardware. But overall, the whole effort could be done for less than $5k, certainly less than $10k, within 3-6 months of spare-time hacking.


It's looking like the "easy" work left to be done to accomplish this isn't as easy as I first thought. I did see one video though where a guy apparently made a *plugin* to integrate the Oculus Rift with a flightsim called X-Plane. As I recall, he did it with just a couple of nights of hacking. I have no idea though if that kind of approach would work with FlightGear. Do you?

My suggestion would be to get in touch with the OR folks through their forum and post a follow-up there, including a link to the discussion you started here, because there seem to be a bunch of misconceptions, in particular regarding the legal repercussions of linking the Apache-licensed SDK into FG's GPL code.


I know nothing about the legal matters you mention. Wouldn't it be better if someone who knows about such things posts a follow-up?

Meanwhile, I just found out my boss's son is a software engineer for an RC aircraft company, and he just got an Oculus Rift. In fact his boss offered to pay for it when he found out. It does make sense to me that the Oculus Rift would probably take RC aviation as well to a whole new level. Anyway, I'll be trying to get in touch with my boss's son soon to see if he'd be willing to help in some way with FlightGear integration. Who knows, maybe he's flightsim fan already. Wouldn't it be great if he was already a FlightGear fan? haha If not, I'll see what I can do...
fg4drt
 
Posts: 64
Joined: Tue Apr 23, 2013 9:55 am

Re: Oculus Rift Development

Postby Hooray » Fri Jun 14, 2013 5:41 pm

When you mentioned crowd-funding, I thought you might have been referring to a more-or-less FlightGear specific mechanism that had been established to fund worthy projects. I doubt if I would be up to the task of creating such a mechanism myself.

There's nothing FG-specific about it, the mechanism itself is in place, just see kickstarter.com - Oculus Rift just proves the point that crowdfunding actually works.

It's looking like the "easy" work left to be done to accomplish this isn't as easy as I first thought. I did see one video though where a guy apparently made a *plugin* to integrate the Oculus Rift with a flightsim called X-Plane. As I recall, he did it with just a couple of nights of hacking. I have no idea though if that kind of approach would work with FlightGear. Do you?


FlightGear doesn't really support conventional binary plugins in the form of DSOs/DLLs (shared libraries) in the traditional way. FlightGear is a multi-platform flight simulator. However, traditional enhancements can be easily made in the form of standalone applications that communicate with FlightGear using one of many existing I/O protocols, or even a custom I/O protocol. Like I said previously, that would not be overly difficult and it would also address any legal/licensing issues, because that's the traditional method of interfacing proprietary software with FlightGear.

I know nothing about the legal matters you mention. Wouldn't it be better if someone who knows about such things posts a follow-up?

As you can probably tell meanwhile, there are not many people interested in OR here - I am not even interested myself, even if FG had OR support in one form or another, it would only be useful to people who have the corresponding hardware. I don't have the hardware, so I am simply not interested :D

But there are a number of people who have considered hacking FG to support OR: http://www.mtbs3d.com/phpbb/viewtopic.php?f=140&t=15628
There are space flight simulators that will be supporting the Rift, which I prefer to atmospheric flight, but I haven't heard about any normal flight simulators.

Flight Gear is open source, so we don't have to worry about what the "devs" do. We can add Rift support ourselves. The same with any other open source games we can find.


Prototyping some form of FG<->OR integration really should not be overly difficult for someone who has the hardware, the specs and who knows how to build FG from source and how to program in C++. This thread, and the interfacing subforum should contain plenty of pointers: viewforum.php?f=36

But like I said earlier, people who don't have the corresponding hardware (or skills) are obviously not in a good position to make it happen, unless they happen to have lots of spare time or some form of funding to get this started.

From a FG-centric standpoint, the right approach would be adding USB/HID support first and foremost, and then adding OR-support on top of that. OR support could then be prototyped as a custom I/O protocol, for which we have a plethora of examples in $FG_SRC/Network
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 Development

Postby fg4drt » Sat Jun 15, 2013 3:33 pm

Hooray wrote in Fri Jun 14, 2013 5:41 pm:...there are not many people interested in OR here - I am not even interested myself, even if FG had OR support in one form or another, it would only be useful to people who have the corresponding hardware. I don't have the hardware, so I am simply not interested :D


I don't think I buy that. I *know* you're interested in making FlightGear the best it can be regardless of whether or not a particular improvement/enchancment would immediately benefit you personally. I'll bet that's true of the active developers too.

Besides, someone could buy you a Rift for your birthday or something, and *then* you'd be sorry you weren't more supportive of getting it integrated with FlightGear :( .

You said earlier that the active FG developers were busy working on other aspects of the program. I can't think of one thing in the world that would enhance the FlightGear flying experience even a tenth as much the Oculus Rift would. Can you? If not, it seems to me that that would make it a top priority to those who want FlightGear to be the best it can be :) .
fg4drt
 
Posts: 64
Joined: Tue Apr 23, 2013 9:55 am

Re: Oculus Rift Development

Postby Gijs » Sat Jun 15, 2013 3:52 pm

Interesting yes, but when it comes to deciding what to spend one's limited spare time on, you'll generally choose for something that you can enjoy yourself ;-)

And even if I had access to an OR, there would be tons of other things that are equally important (if not more important) to be done.
Airports: EHAM, EHLE, KSFO
Aircraft: 747-400
User avatar
Gijs
Moderator
 
Posts: 9544
Joined: Tue Jul 03, 2007 3:55 pm
Location: Delft, the Netherlands
Callsign: PH-GYS
Version: Git
OS: Windows 10

Re: Oculus Rift Development

Postby Hooray » Sat Jun 15, 2013 3:57 pm

You don't need to believe me, but I am telling you the truth - and don't tell me that I wouldn't be supportive - have you even noticed that I am the only one to respond here ? :D
I have no doubt that it will be of interest to some folks, but most developers are not in it for the gaming aspects...
Seriously, even if I had the OR here next to me, I would not be particularly interested in using it - heck, I don't even own a joystick ... :lol:

All of us have different priorities and roadmaps, what may seem useful and even important to some of us, may be irrelevant to others - part of the "game", just accept it.

I am not saying that OR support wouldn't possibly be great for FG (and OR), but I don't see it happen the way you are envisioning it obviously - donating some hardware and manpower would only be the first step, donating hardware and code would be even better - and if that's not possible, some form of funding is required.

All that said, FG also supports stereoscopic goggles through OSG, I actually do have such goggles (a freebie that came with a new laptop), truth being spoken, I have never ever used them, let alone tried making them work with FG - I am simply not interested in it. All contributors have different reasons and priorities for contributing, and we just need to recognize and accept that - what may seem important to me, may be irrelevant to you (and vice versa).
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 Development

Postby fg4drt » Sat Jun 15, 2013 4:55 pm

Hooray wrote in Sat Jun 15, 2013 3:57 pm:You don't need to believe me, but I am telling you the truth - and don't tell me that I wouldn't be supportive - have you even noticed that I am the only one to respond here ? :D


I sure have! I'm puzzled by that.

I have no doubt that it will be of interest to some folks, but most developers are not in it for the gaming aspects...


I'm in it for the flying experience at this time. I may get interested in gaming at some point. Are we talking about the same thing? What's left besides the flying experience and gaming? What *are* most developers in it for?

Seriously, even if I had the OR here next to me, I would not be particularly interested in using it - heck, I don't even own a joystick ... :lol:


How *do* you use FG then? That is, what do you use it for? Realism doesn't appear to be your thing. What is?

All of us have different priorities and roadmaps, what may seem useful and even important to some of us, may be irrelevant to others - part of the "game", just accept it.

I am not saying that OR support wouldn't possibly be great for FG (and OR), but I don't see it happen the way you are envisioning it obviously - donating some hardware and manpower would only be the first step, donating hardware and code would be even better - and if that's not possible, some form of funding is required.

All that said, FG also supports stereoscopic goggles through OSG, I actually do have such goggles (a freebie that came with a new laptop), truth being spoken, I have never ever used them, let alone tried making them work with FG - I am simply not interested in it.


But that has no bearing on whether or not you're interested in making FlightGear more realistic *for the sake of others*, right?

All contributors have different reasons and priorities for contributing, and we just need to recognize and accept that - what may seem important to me, may be irrelevant to you (and vice versa).


Well sure, but do you think there are any developers who think that making FlightGear be the best it can be is unimportant?
fg4drt
 
Posts: 64
Joined: Tue Apr 23, 2013 9:55 am

Re: Oculus Rift Development

Postby Hooray » Sat Jun 15, 2013 4:57 pm

We are both right to a certain degree, but you completely disregard how the project actually works, vs. how it would ideally ought to work.
I suggest to do some reading first, or you won't understand responses like mine or Gijs's:

viewtopic.php?f=42&t=15267
http://wiki.flightgear.org/How_to_the_F ... ject_works
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

Next

Return to Hardware

Who is online

Users browsing this forum: No registered users and 8 guests