This isn't the full Oculus Injector, I removed everything besides the X-Plane fix. So there's no vibration disabling, hand steadying, height adjust, touch emulation using Xbox or DS4 controllers, etc.
If somebody wants to verify this works, I'll do a more public release. For now I'm just keeping it here, I've never had anybody run OculusInjector before.
I've tested it with X-Plane 11.41 stable and 11.50b9 beta.
This is what it looks like out of the box:
Setup
First thing to do is click on Add Entry. That adds a list box to the panel, and a new secondary panel appears with details.
On the secondary panel, you'll see a few things:
- A Launch button. This plays the selected game.
- An empty text box with "Process Name" next to it. Actually I should rename that, it's the Profile Name. You can type whatever name you want here to identify the selected game.
- A Select button. This opens a windows file requestor. This is how you choose an executable for the profile.
- An empty text box next to Select. This shows the selected executable.
Fill in a name for the profile on the Process Name field.
Click Select and find your X-Plane.exe file.
Go to the File menu at the top and save if you want to keep the profile.
Note: You can add as many profiles as you want, if you have several X-Planes installed, such as stable and beta versions.
Now press Launch and hopefully a working X-Plane will start.
You MUST use the OculusInjector program to launch X-Plane. The way the fix works is all in memory during loading, it doesn't modify your installed X-Plane files. If you run X-Plane normally (from Oculus Dash, from explorer, etc) it will be the regular X-Plane. No uninstalling is needed, just don't run the injector if you don't want it active.
You can close OculusInjector once X-Plane is running, it is only needed to start.
Here's what mine looks like:
What is the Fix?
This is specifically the fix for X-Plane hanging or crashing on startup in OpenGL mode using the Oculus v17 runtime. It doesn't fix the hang when you exit.
What's the issue? Who's to blame?
X-Plane uses Oculus SDK 1.23, which is from 2 years ago. When enabling the VR headset in OpenGL, they try to create a cubic texture swap chain. This cubic texture swap chain is only used once, it's not used when rendering normally.
1.5 years ago Oculus updated the SDK source code to include a warning to not make cubic swap chains. X-Plane's devs apparently never saw this warning. Fast forward to now, and in Oculus v17 the thing that they've warned to not do for 1.5 years no longer works. So technically Oculus broke it, but X-Plane is doing something it shouldn't be doing which just happened to not break in the past.
How the fix works
When X-Plane calls ovr_CreateTextureSwapChainGL it passes in ovrTexture_Cube. I intercept the call and replace it with ovrTexture_2D. That's it. It's basically changing a 2 to a 0 with one line of code. It would have taken Laminar less time to fix this than it took me, if they believed my bug report that detailed how to fix it.
Why does Vulkan in 11.50b9 work fine without a fix?
The Vulkan code in X-Plane never tries to make a cube texture swap chain, and therefore runs correctly. It's only the OpenGL code that does the wrong thing.
Important Note
Oculus Injector uses DLL injection to intercept functions in X-Plane and the Oculus runtime. This kind of technique is sometimes used by game cheats and hacks, so if you did this to games with anti-cheat tech like VAC, maybe it will get upset. I haven't had any problem with Oculus games or X-Plane, but be warned.
(I hate releasing first versions of things. So stressful)
Hopefully if that works, it won't preclude Laminar looking into their code too. It sounds like their VR implemetation is maybe a little overdue for an update?
Intel 5820K [email protected], Titan X (Maxwell), 32GB Corsair Vengeance DDR4, ASRock X99 Taichi, Samsung 500Gb 960 Evo M.2, Corsair H100i v2 Cooler, Inateck KTU3FR-4P USB 3 card, Windows 10 Pro v2004 (19042.662)
I hate to think of all the guys who have stuffed up their Oculus systems trying to use silly hacks. Thanks again mate.
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
Hehe, I was waiting for somebody here to say it worked before telling the X-Plane forum. Guess word spreads fast.
Ya, usually only BAD news travels so fast, lol! Again, good job mate.
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
Hello, does it work on Steam X-plane version? I can't find the X-plane11.exe
You should find this where you installed it. Usually is is drive: steam library/steamapps/common/bin/ name of app/ should see the application exe file.
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
Thanks for your help (both) I found the .exe and I run the injector but x-plane is still saying that headset is disabled and automatically unchecks the box for enable VR hardware. I don't know how to make the Xplane runs with Oculus Rift S. I will very appreciate if you can help me.
Thanks for the great work. Install the Injector and define an Entry. I use an X-plane 11.41 validated with a CD. and steamVR version 1.11.13) for occulus rift. Xplane 11.41 the VR doesn't work as already mention multiple time.
With the injector I was able to start twice X-plane 11 after a lot of attempt. When X-plane starts with the injector the VR works.May be a security problem? Any idea? Thanks
Did more test and can not find why the process X-plane failed to start 99% of the time and need a lot of attempt to finally successfully start. It seems to be random. Very strange.
Thanks for your help (both) I found the .exe and I run the injector but x-plane is still saying that headset is disabled and automatically unchecks the box for enable VR hardware. I don't know how to make the Xplane runs with Oculus Rift S. I will very appreciate if you can help me.
Im having the same problem here. I think i read somewhere that steam version has differences from the laminar download. i dont know if that's the reason
Thanks for your help (both) I found the .exe and I run the injector but x-plane is still saying that headset is disabled and automatically unchecks the box for enable VR hardware. I don't know how to make the Xplane runs with Oculus Rift S. I will very appreciate if you can help me.
Im having the same problem here. I think i read somewhere that steam version has differences from the laminar download. i dont know if that's the reason
Never had any problem with steamVR it was running fine until we get this problem that X-pane VR won't load with version 17.
I managed to install the kojak Oculus Injector program and now Xplane VR is working fine. Both the Rift headset and Quest link headset are working so this is a great fix. Great work kojak! Why doesn't Xplane buy your app??
I'm pretty sure I know why people with the Steam version can't run the fix: X-Plane uses Steam DRM.
This encrypts the X-Plane executable. When OculusInjector loads the executable, it's really loading Steam's copy protection code and hooking that. Steam decrypts the game into memory and runs that. Without trying to bypass Steam's protection, there's no way I can get access to where the oculus library is really loaded. At least not with the technique I'm using. I've got an idea, but that will have to come later.
The same thing happens with Euro Truck Sim 2, I can't hook into it because it uses Steam DRM.
The Oculus store's entitlement check is much less intrusive and doesn't get in the way of my code.
Thanks for the solution, it is really neat, compared to other proposed options. However, for some reason Orbx products and sceneries do not load up when using injector, everything else, like 3rd party airports from other developers load normally. Anybody else came accross the same issue? For reference, I have XP11.41 and I was flying over TrueEarth Washington state (default landclass and not photoreal as it supposed to be) and landing at Israel's farm (WA56 - default look). When I run 11.41 without the injector, the sceneries appear as they are supposed to. It seems that Orbx uses or adds something to either command line that direct link with the injector to xplane.exe misses.
Good to see Laminar and Oculus working together to at least provide a hotfix for 11.41 OpenGL. Only applicable for Oculus headsets with xp11 download and/or CD versions. Does not apparently work with Steam versions yet. Hopefully the next xp11 and Oculus updates will sort this out for all. It would be nice if they can fix the xp11 shutdown bug that reappeared with Oculus v13 as well.
Thanks again for all your efforts kojack.
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
I guess this is a good reason for not buying from Steam when a company has their own store. Laminar has full control over releases on their own version and 100% of the money goes to the actual game company (instead of the 30% cut most stores like Oculus and Steam take).
Even if it's cheaper on Steam, I like to support the developers when I can.
Comments
Hardware: Threadripper 1950x, MSI Gaming Trio 2080TI, Asrock X399 Taich
Headsets: Wrap 1200VR, DK1, DK2, CV1, Rift-S, GearVR, Go, Quest, Quest 2, Reverb G2
https://forums.x-plane.org/index.php?/forums/topic/213584-oculus-v17-not-working-and-v16-forces-update/&page=8&tab=comments#comment-1940239
I hate to think of all the guys who have stuffed up their Oculus systems trying to use silly hacks. Thanks again mate.
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
Hardware: Threadripper 1950x, MSI Gaming Trio 2080TI, Asrock X399 Taich
Headsets: Wrap 1200VR, DK1, DK2, CV1, Rift-S, GearVR, Go, Quest, Quest 2, Reverb G2
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
Hardware: Threadripper 1950x, MSI Gaming Trio 2080TI, Asrock X399 Taich
Headsets: Wrap 1200VR, DK1, DK2, CV1, Rift-S, GearVR, Go, Quest, Quest 2, Reverb G2
Never had any problem with steamVR it was running fine until we get this problem that X-pane VR won't load with version 17.
Hardware: Threadripper 1950x, MSI Gaming Trio 2080TI, Asrock X399 Taich
Headsets: Wrap 1200VR, DK1, DK2, CV1, Rift-S, GearVR, Go, Quest, Quest 2, Reverb G2
Hardware: Threadripper 1950x, MSI Gaming Trio 2080TI, Asrock X399 Taich
Headsets: Wrap 1200VR, DK1, DK2, CV1, Rift-S, GearVR, Go, Quest, Quest 2, Reverb G2
Hardware: Threadripper 1950x, MSI Gaming Trio 2080TI, Asrock X399 Taich
Headsets: Wrap 1200VR, DK1, DK2, CV1, Rift-S, GearVR, Go, Quest, Quest 2, Reverb G2
Thanks again for all your efforts kojack.
Custom built gaming desktop; i9 9900k (water cooled) oc to 5ghz, gtx 1080 ti, 32 gb 3000hz ram, 1 tb ssd, 4 tb hdd. Asus ROG Maximus xi hero wifi mb, StarTech 4 port/4 controller sata powered usb3.0 pcie card, PCI-E PCI Express to USB 3.1 Gen 2 card, Asus VG248QE 1080p 144hz gaming monitor, Oculus Rift cv1 w/2x sensors, Vive Pro w/2.0 base stations/Index controllers, Quest 1 w/Link and VD wireless (good/close 5Ghz wifi and PC with Ethernet cable to my Router).
Hardware: Threadripper 1950x, MSI Gaming Trio 2080TI, Asrock X399 Taich
Headsets: Wrap 1200VR, DK1, DK2, CV1, Rift-S, GearVR, Go, Quest, Quest 2, Reverb G2