X-Wing Alliance VR mod

Here you can find help for how to best run and setup your XWA VR experience.
Post Reply

Re: X-Wing Alliance VR mod

aaadmiral
Cadet 4th Class
Posts: 24
Joined: Fri Apr 17, 2020 8:54 pm

Post by aaadmiral » Tue Jun 16, 2020 8:23 pm

what specs are people using with these low fps? just wondering if it's possible to run at 90fps on any system haha.. I have a 4790k and 1080ti

User avatar
Mouseplay
Recruit
Posts: 7
Joined: Thu Apr 14, 2011 4:45 pm
Contact:

Post by Mouseplay » Tue Jun 16, 2020 9:16 pm

Haven't been here since 2011. Just wanted to chime in and say I'm very excited for this mod. Don't have my rig setup to test but look forward to it in the future.

Also curious about the performance. Is it really demanding? Is the overhead so huge going to 3D/VR?
Asus® P5K Pro
Corsair X64 SSD System Drive
Intel® Core™ 2 Quad Q6600 @ 3.6 GHz
Gigabyte™ GTX 460 1GB OC @ 840/2100
OCZ Platinum 2x 1GB PC2-6400 4-5-4-15
Corsair® Dominator™ 2x 1GB PC2-8500 5-5-5-15

User avatar
m0rgg
XWAU Member
Posts: 266
Joined: Wed Apr 01, 2020 10:33 pm

Post by m0rgg » Tue Jun 16, 2020 10:20 pm

Mouseplay wrote:
Tue Jun 16, 2020 9:16 pm
Also curious about the performance. Is it really demanding? Is the overhead so huge going to 3D/VR?
The effects are of course heavier on the GPU, but the real drop in performance seems to be related to SteamVR.
I'm sure blue_max will end up figuring it out, and hopefully we can help.

I was just testing yesterday, trying to trace the execution with Nvidia Nsight System and the SteamVR Frame Timing tool.
Some things I have noted:

- If I select VR_Mode = None, the game still launches SteamVR and displays the right FOV and resolution. It even picks up headtracking, but doesn't display anything in the HMD (makes sense). However, the performance in this case is rock solid at 60fps, even when moving the headset around. This seems to indicate that it't not a real problem of GPU power. The GPU is used only up to 33% (RTX2080).
- When rendering to the HMD, the maximum FPS is 60, while it should be 90 in my case (Oculus CV1). Is it possible that ddraw.dll or the fps hook is syncing/limiting to the monitor refresh rate instead?
- Trying to trace with Nidia Nsight System, the VSYNC doesn't seem to happen at 90hz. I'm still trying to figure out how to read what I see. @blue_max have you tried it? Or GPUView, something similar from Microsoft.
- The SteamVR frame timing tool clearly shows that it's application rendering time what runs longer than the available 11ms for each frame. If it was WaitGetPoses() blocking, I guess it would appear differently?

From what I have read, WaitGetPoses() should be called ideally around 3ms before the vsync to get the GPU to actually start working when the vsync happens. Or at the very end of the rendering loop, when you have finished rendering this frame (both to the HMD and to the monitor) and you can afford to block and wait for vsync to start rendering the next frame with the right tracking info.

I am probably missing something but I don't understand why the renderer being monothreaded is so relevant. If your performance is good enough to maintain the FPS (each frame takes less than 11ms to do everything you need to do), you can finish all the processing and WaitGetPoses() will not block when it doesn't need to. It's a matter of calling it at the right time, and only once. Don't ask me where that is in ddraw.dll, I still don't fully understand the rendering flow...

Not sure anything of this makes too much sense, but I write it in the hopes that it makes the real expert realise something :)

Image

User avatar
blue_max
XWAU Member
Posts: 2295
Joined: Wed Mar 20, 2019 5:12 am

Post by blue_max » Wed Jun 17, 2020 4:09 am

m0rgg wrote:
Tue Jun 16, 2020 10:20 pm
- If I select VR_Mode = None, the game still launches SteamVR and displays the right FOV and resolution. It even picks up headtracking, but doesn't display anything in the HMD (makes sense). However, the performance in this case is rock solid at 60fps, even when moving the headset around. This seems to indicate that it't not a real problem of GPU power. The GPU is used only up to 33% (RTX2080).
This is because the cockpit look hook will also load SteamVR if you leave tracker_type=SteamVR. This hook won't call WaitGetPoses, so it runs as fast as the system will allow it. What you're seeing is the same performance I get in DirectSBS mode because I don't go through SteamVR using that mode.
- When rendering to the HMD, the maximum FPS is 60, while it should be 90 in my case (Oculus CV1). Is it possible that ddraw.dll or the fps hook is syncing/limiting to the monitor refresh rate instead?
Yes, now that I remember, I always do "EnableVSync = 0" in DDraw.cfg because I've never seen any benefit of enabling VSync. This may actually explain why others see a drop in performance. Disabling VSync may help improve the performance in SteamVR as well.
- Trying to trace with Nidia Nsight System, the VSYNC doesn't seem to happen at 90hz. I'm still trying to figure out how to read what I see. @blue_max have you tried it?
Not yet, this is a tool I still have to learn. You're correct that the fix may be in timing when to call WaitGetPoses so that it only blocks for 3ms. This is something that I tried once a long time ago; but I definitely need to try this again with the use of tools. Any help is appreciated of course.
I am probably missing something but I don't understand why the renderer being monothreaded is so relevant.
The last time I read about the subject this seemed to be important because the CPU would continue to compute the next frame while the renderer thread was blocked behind WaitGetPoses. If the program is monothreaded, then both the CPU and the GPU will be blocked. However, as you pointed out, maybe this can be fixed with a more judicious use of WaitGetPoses.

Thanks for the suggestions! This is something I'll be looking at again soon.

Wiiplay123
Cadet 4th Class
Posts: 16
Joined: Fri Oct 03, 2014 9:08 pm

Post by Wiiplay123 » Fri Jun 19, 2020 9:40 pm

On versions 1.1.0 and 1.1.1, the only SteamVR tracking that's working is roll. Pitch, yaw, and all the lateral movements are completely broken.

I'm using an original HTC Vive, with SteamVR 1.12.5.

Any idea what's going on? On 1.0.9, I could move around slightly and roll but pitch and yaw were broken.

EDIT: Same problem in 1.1.3.2.

User avatar
blue_max
XWAU Member
Posts: 2295
Joined: Wed Mar 20, 2019 5:12 am

Post by blue_max » Sat Jun 20, 2020 1:19 am

Wiiplay123 wrote:
Fri Jun 19, 2020 9:40 pm
On versions 1.1.0 and 1.1.1, the only SteamVR tracking that's working is roll.
Make sure your cockpitlook.cfg has "tracker_type = SteamVR"

ptisinge
Cadet 4th Class
Posts: 10
Joined: Tue Jun 02, 2020 5:08 am

Post by ptisinge » Sat Jun 20, 2020 5:55 am

To report back on further testing with the preview you PMed to me Blue_max:

Performance is now a really big issue - even with a 1 on 1 skirmish where things used to be smooth, I now get very big stutters, and that's at 50% in steamVR.
It's still awesome to finally feel like I'm in the cockpit of all of these crafts with now distortion (and there seems to be a much stronger sense of depth now), but it's not playable as it is right now.

User avatar
blue_max
XWAU Member
Posts: 2295
Joined: Wed Mar 20, 2019 5:12 am

Post by blue_max » Sat Jun 20, 2020 6:59 am

ptisinge wrote:
Sat Jun 20, 2020 5:55 am
Performance is now a really big issue
Try disabling VSync in DDraw.cfg:

EnableVSync = 0

You can also reduce the FOV a little bit. The bigger the FOV, the more objects XWA has to compute and display. My performance over here is about the same (I'd say ~30-40fps on average, not great; but playable)

What resolution are you using?

User avatar
m0rgg
XWAU Member
Posts: 266
Joined: Wed Apr 01, 2020 10:33 pm

Post by m0rgg » Sat Jun 20, 2020 7:13 am

Disabling vsync helped me a lot. If enabled it will limit FPS to your monitor refresh, not to the HMD.

With vsync off, FPS go between 90 when no objects on sight, like looking up, to 45 when I look down or back.

One thing that should help is Async reprojection, or ASW in Oculus. It will maintain 90fps for tracking even if rendering is made at half the FPS.

I am trying to figure out where the bottleneck is, but so far with GPUView it just seems that rendering just takes more than the available frametime to keep 90fps (11ms). No obvious blocking from SteamVR, the call to WaitGetPoses seems at the right time.
I am trying to improve the tracing to identify what functions take more time.

User avatar
disneyjedi87
Recruit
Posts: 2
Joined: Sat Jun 20, 2020 8:39 am

Post by disneyjedi87 » Sat Jun 20, 2020 8:46 am

Hello all,

Blue_Max suggested I drop by after I commented on his YouTube video about the VR Mod. I had mentioned that despite some early issues I was able to get the game running in VR on my Oculus Quest headset. If anyone has a Quest and is looking to play on it what I did was basically use Virtual Desktop. I then sideloaded an update to it that allowed for Steam VR to run through it and detect the headset. I just updated Virtual Desktop tonight using the standard update and did not seem to have any issues. Once Steam VR is running I was able to open XWA and it loaded up. I am not sure if my computer was just running better tonight or if there was something in the most recent update to the effects mod, but it ran a lot better for me tonight. I might play with some of the setting so things do not seem so tiny in my FOV but for the most part I was able to get everything running, plus I was able to shoot down some fighters.

Thanks for all the hard work on this mod! It's great!

MetalHut
Recruit
Posts: 5
Joined: Fri Jun 05, 2020 6:49 am

Post by MetalHut » Sat Jun 20, 2020 9:49 am

Hi, greats mods.

However I have one issue. Is there any command to recenter the view ? like other VR games ?
After XWA has CTD, when I relaunch the game, my Point of view in the cockpit is totally misalign and out of the ship.

User avatar
m0rgg
XWAU Member
Posts: 266
Joined: Wed Apr 01, 2020 10:33 pm

Post by m0rgg » Sat Jun 20, 2020 10:25 am

MetalHut wrote:
Sat Jun 20, 2020 9:49 am
Hi, greats mods.

However I have one issue. Is there any command to recenter the view ? like other VR games ?
After XWA has CTD, when I relaunch the game, my Point of view in the cockpit is totally misalign and out of the ship.
Press the dot (.) in the keyboard several times until you are back in the cockpit, re-entered.

MetalHut
Recruit
Posts: 5
Joined: Fri Jun 05, 2020 6:49 am

Post by MetalHut » Sat Jun 20, 2020 3:25 pm

m0rgg wrote:
Sat Jun 20, 2020 10:25 am
MetalHut wrote:
Sat Jun 20, 2020 9:49 am
Hi, greats mods.

However I have one issue. Is there any command to recenter the view ? like other VR games ?
After XWA has CTD, when I relaunch the game, my Point of view in the cockpit is totally misalign and out of the ship.
Press the dot (.) in the keyboard several times until you are back in the cockpit, re-entered.
Since I'm playing with AZERTY keyboard, the dot key doesn't seem to do anything. If I take a QWERTY keyboard in mind and push the dot key, I'm changing view, but it doesn't really recenter my headset view. But it is an improvement.

Is there any profile I could download for HTC Vive Cosmos Elite ?

HanSolo77
Cadet 4th Class
Posts: 12
Joined: Sat Jun 20, 2020 4:44 pm

Post by HanSolo77 » Sat Jun 20, 2020 5:35 pm

Hi everybody :)

First a big big thanks to the whole team of XWAUP. What you did achieve with my old favorite game is just awesome - very well done :D
And especially that VR mode just gives me the mood to restart the game and the campaign after over 15 years once again :^^:


But concerning VR, I have the same problem as MetalHut:

Pressing "." to recenter the view does not recenter. It just switches to the external view - there, I am perfectly centered to the crosshair.
But when pressing "." again and reentering the cockpit, my view is still "centered" much too low: I look directly on the upper part of the cockpit instruments and mountings, and the crosshair is just out of center/focus. So, I always have to look upwards a bit which makes it quite a bit strenuous in combat over time...
Pressing "." numerous times - 10-20x - doesn't change anything.


Furthermore, as I am playing with a Pimax 5K+ and as everything runs smoother than smooth @1920x1200 resolution, I wonder whether the whole FOV can't be extended to the sides...?
Not at least, because everything just looks a bit elongated in vertical direction.

I am searching through the game directorie's .TXT-files, this forum and this topic since hours, but there's so much text and deep detail explanations, I simply cannot find (in short) what I am looking for...

I'd be glad if I could get some help concerning those two points - recentering and increasing the FOV.

Thanks already :)

HanSolo77

User avatar
blue_max
XWAU Member
Posts: 2295
Joined: Wed Mar 20, 2019 5:12 am

Post by blue_max » Sat Jun 20, 2020 6:03 pm

disneyjedi87 wrote:
Sat Jun 20, 2020 8:46 am
Blue_Max suggested I drop by after I commented on his YouTube video about the VR Mod. I had mentioned that despite some early issues I was able to get the game running in VR on my Oculus Quest headset. If anyone has a Quest and is looking to play on it what I did was basically use Virtual Desktop. I then sideloaded an update to it that allowed for Steam VR to run through it and detect the headset.
Hello, thanks for sharing these details. Where you running the game in DirectSBS mode or the SteamVR mode? Does head tracking work when using Virtual Desktop?

@MetalHut: The dot key is overloaded to re-center the view in SteamVR since it also centers the view in-game. Maybe you need to configure a re-center key for your headset and assign it to the dot key?

@HanSolo77: I'm aware the VR mod has some distortion issues, and I believe I have fixed them, but I haven't released a public preview yet. The POV and FOV can be changed too. Just give me a little more time to publish something. I may be able to finish something decent this weekend :)

User avatar
disneyjedi87
Recruit
Posts: 2
Joined: Sat Jun 20, 2020 8:39 am

Post by disneyjedi87 » Sat Jun 20, 2020 6:07 pm

blue_max wrote:
Sat Jun 20, 2020 6:03 pm
disneyjedi87 wrote:
Sat Jun 20, 2020 8:46 am
Blue_Max suggested I drop by after I commented on his YouTube video about the VR Mod. I had mentioned that despite some early issues I was able to get the game running in VR on my Oculus Quest headset. If anyone has a Quest and is looking to play on it what I did was basically use Virtual Desktop. I then sideloaded an update to it that allowed for Steam VR to run through it and detect the headset.
Hello, thanks for sharing these details. Where you running the game in DirectSBS mode or the SteamVR mode? Does head tracking work when using Virtual Desktop?
Last night I was running in SteamVR mode. And yes head tracking was working in Virtual Desktop.

ptisinge
Cadet 4th Class
Posts: 10
Joined: Tue Jun 02, 2020 5:08 am

Post by ptisinge » Sat Jun 20, 2020 11:58 pm

blue_max wrote:
Sat Jun 20, 2020 6:59 am

Try disabling VSync in DDraw.cfg:

EnableVSync = 0

You can also reduce the FOV a little bit. The bigger the FOV, the more objects XWA has to compute and display. My performance over here is about the same (I'd say ~30-40fps on average, not great; but playable)

What resolution are you using?
I'm already disabling VSync.

Isn't the resolution purely determined by the steamVR setting now (I thought that's how it worked in the recent versions). I'm at 50% of the Vive OG in steamVR, I'll have to check how much that is, and ingame I didn't touch anything from a new fresh install (so I'd be on 640x480, but that's not the effective resolution as far as I can tell).

Re the fov, I guess that if I decrease it I need to have black bars around the screen, otherwise things will look wrong?

To be precise: I have periods of smoothness, especially if I fly straight but look around, then everything is smooth, but when turning I then get strong stutters, i.e. the whole screen clearly freezes for half a second or so. Before the preview in skirmish Vs 1 TIE figther everything was smooth at all times.

Anyway, I'll do some more experimenting to find out whether I can solve this with further lowered settings

User avatar
blue_max
XWAU Member
Posts: 2295
Joined: Wed Mar 20, 2019 5:12 am

Post by blue_max » Sun Jun 21, 2020 7:22 am

ptisinge wrote:
Sat Jun 20, 2020 11:58 pm
I'm already disabling VSync.
OK, how about setting ProcessAffinityCore=0. You'll also need the Music Freeze Hook, but maybe that'll help?
Isn't the resolution purely determined by the steamVR setting now (I thought that's how it worked in the recent versions). I'm at 50% of the Vive OG in steamVR.
Yes, the GPU uses the resolution set by SteamVR. So the smaller the resolution, the faster the GPU will render. The in-game resolution is totally different, but the FOV can be used to compensate for the difference.
To be precise: I have periods of smoothness, especially if I fly straight but look around, then everything is smooth, but when turning I then get strong stutters, i.e. the whole screen clearly freezes for half a second or so.
I honestly don't know what's the problem here. Any extra details you can share may help.

@disneyjedi87: Thanks for the confirmation!

Anyway, here's a preview of what's coming soon. In this version, there should be no distortion, but if there is, feel free to let me know!

https://www.dropbox.com/s/bad4uezpdydj9 ... 0.zip?dl=0

ptisinge
Cadet 4th Class
Posts: 10
Joined: Tue Jun 02, 2020 5:08 am

Post by ptisinge » Sun Jun 21, 2020 12:31 pm

Blue_max, it could very well be the core affinity setting - I had it set to 0 before but when I installed the files you PMed to me, I forgot to check that and sure enough if was set to 2, so I'll try this back to 0 when I have a chance. With some luck that's where the stutters came from!

User avatar
Ace Antilles
Admiral (Moderator)
Posts: 7829
Joined: Sat Jan 22, 2000 12:01 am
Contact:

Post by Ace Antilles » Sun Jun 21, 2020 1:56 pm

ptisinge wrote:
Sun Jun 21, 2020 12:31 pm
Blue_max, it could very well be the core affinity setting - I had it set to 0 before but when I installed the files you PMed to me, I forgot to check that and sure enough if was set to 2, so I'll try this back to 0 when I have a chance. With some luck that's where the stutters came from!
If affinity is set to 2 then the FPS will be bad. With it set to 0 it will be good but you may experience some music issues.
Chief XWAU Team annoying nitpicker.
Ace Antilles - The X-Wing Outpost
Image

Wiiplay123
Cadet 4th Class
Posts: 16
Joined: Fri Oct 03, 2014 9:08 pm

Post by Wiiplay123 » Sun Jun 21, 2020 11:40 pm

blue_max wrote:
Sat Jun 20, 2020 1:19 am
Make sure your cockpitlook.cfg has "tracker_type = SteamVR"
Yep, it is.

CockpitLook.log says:

Code: Select all

Cockpit Hook Loaded
Using SteamVR for tracking
Yaw multiplier: 1.000
Pitch multiplier: 1.000
Yaw offset: 0.000
Pitch offset: 0.000
External tilt: -1820
Parameters loaded
InitSteamVR()
EDIT: Reinstalled from scratch, now the HUD tracks perfectly while the 3D part of the game (including crosshairs for some reason) stay stuck in place except for roll. Manual camera rotation controls (both mouselook and keyboard) still work as expected, though.

ptisinge
Cadet 4th Class
Posts: 10
Joined: Tue Jun 02, 2020 5:08 am

Post by ptisinge » Mon Jun 22, 2020 4:07 am

I knew about the core affinity setting - I just forgot to set it back to zero after I downloaded the files Blue_max has PMed me.

Anyway, this is it - after changing this back to zero my skirmishes are smooth again. Perfect! Missions from the main campaign are still hard to run smoothly that was always the case.

User avatar
blue_max
XWAU Member
Posts: 2295
Joined: Wed Mar 20, 2019 5:12 am

Post by blue_max » Mon Jun 22, 2020 7:23 pm

Wiiplay123 wrote:
Sun Jun 21, 2020 11:40 pm
EDIT: Reinstalled from scratch, now the HUD tracks perfectly while the 3D part of the game (including crosshairs for some reason) stay stuck in place except for roll. Manual camera rotation controls (both mouselook and keyboard) still work as expected, though.
What versions are you installing? Can you post a picture of what you're describing here (I find it a little hard to picture what's going on). Please send me your VRParams.cfg and CockpitLook.cfg files so I can take a look.

fesiri
Recruit
Posts: 1
Joined: Mon Jun 22, 2020 8:27 pm

Post by fesiri » Mon Jun 22, 2020 8:59 pm

blue_max wrote:
Sun Jun 21, 2020 7:22 am
Anyway, here's a preview of what's coming soon. In this version, there should be no distortion, but if there is, feel free to let me know!

https://www.dropbox.com/s/bad4uezpdydj9 ... 0.zip?dl=0
Hi. I can confirm this files remove all VR distortion I had, making XWA great in VR ! Thank you very much !

I am a noob here, a big fan of X-Wing and Tie-fighter, but Alliance was release while I was not gaming... bought a VR headset and was looking for X-Wing mod with VR and found you guys...
Coincidently I installed XWAU on 18/06 and you just uploaded this distiortion fix that made everithing work perfectly here. Was so amazed that I left the game and registed on the forum to thank you guys (Upgrade as a whole and VR mod).
If you need any feedback on XWA(I have GOG version) in VR, I use Windows Mixed Reality (Odyssey+). I am new on XWA and upgrade, but if I could help, specially about VR feedback...

I will put my specs here:
ASUS Rog Strix B450F / Ryzen 5 2600X / Zotac GTX 1070Ti mini / 2x8 + 2x4 GB ddr4 @2666MHz / Intel 1TB 660 M.2 SSD / WMR Samsung Odyssey+ / ThrustMaster T.Flight Hotas X

Wiiplay123
Cadet 4th Class
Posts: 16
Joined: Fri Oct 03, 2014 9:08 pm

Post by Wiiplay123 » Mon Jun 22, 2020 9:51 pm

blue_max wrote:
Mon Jun 22, 2020 7:23 pm
What versions are you installing? Can you post a picture of what you're describing here (I find it a little hard to picture what's going on). Please send me your VRParams.cfg and CockpitLook.cfg files so I can take a look.
I've recorded a video of the issue, showing me moving the mouse in the hangar to show that the camera does move with the mouse when mouselook is enabled but not with the VR headset.

https://youtu.be/HBUUEesnkpo

I installed XWAUCPv1.6.exe on top of CD X-Wing Alliance with the 2.02 patch, then installed EffectsByBlueMax_v1.1.3.2.exe with the SteamVR option, and Active Cockpit disabled (although I've tried it with that option too and it doesn't change anything).

I can't upload .cfg files as attachments so I'm using Pastebin.
CockpitLook.cfg: https://pastebin.com/rVT3zvmM
VRParams.cfg: https://pastebin.com/jXsbZE49

Post Reply