In case there is any other interested user, these are my advances so far:
- Using Oculus Rift DK2 and Oculus SDK 0.3 on Linux. FlightGear fully updated to current GIT. OpenSceneGraph 3.2.0
- Image: using stereoscopic mode, fullscreen, eyes distance=0. Obviously, the 3D effect is lost but the immersion is not. I'm still researching how applying the barrel distortion the Oculus needs to create the 3D effect, but my bet is still on an OpenSceneGraph plugin without any modification in FlightGear or SimGear (apart from the switch in the stereoscopic menu to activate this mode) I'll wait for the 0.4 version of the Oculus SDK for Linux.
- tracking position: you'll find below a standalone program that tracks the position of the headset and moves the view accordingly. This assumes FligthGear is running with a telnet server in port 9000. It seems the heading needs some reset if you put the headset on the table, so do not put the headset on the table while running the tracker I'm guessing and not really sure, but I think v0.3 of the SDK uses internal accelerometers to track the position and does not use the external camera for synchronization. I think the external camera is only supported from v0.4 of the SDK. I have only tested this program in Linux.
To build the position tracker, you have to download and build the Oculus SDK (v0.3 at the time of writing this, 0.4 version is not yet available for Linux) and change the paths of the Oculus SDK in the Makefile. Then, "make demo1" and run "demo1" with the Oculus and FligthGear activated.
https://dl.dropboxusercontent.com/u/13130748/oculus.zip
This is only a test, it is not optimized and full of debug messages and it uses some classes for Sockets with no clear license. Do not assume it is GPL because it is not!
Apart from the lacking of the 3D effect, flying with this needs some minutes to get used to. Once you get the idea, the feeling of complete immersion and being able to move your head to see the environment is awesome! The resolution is not the best and the pixels are very evident, but I'm still not sure if I'm using the max resolution the Oculus supports