Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Performance Problems with all steamvr overlays with HP reverb G2 #21

Closed
fritzcloud opened this issue Jan 30, 2022 · 17 comments
Closed

Performance Problems with all steamvr overlays with HP reverb G2 #21

fritzcloud opened this issue Jan 30, 2022 · 17 comments
Labels
needs more info Further information is requested

Comments

@fritzcloud
Copy link

fritzcloud commented Jan 30, 2022

I am having performance issues using OpenKneeboard, but also using VR Kneeboard. I tried the latest build from the GitHub action. Tested F/A-18 "airfield defense" instant action on Syria to put some strain on my PC. Mods On/Off does not make a difference.

Without openkneeboard: around 35 fps, but pretty smooth picture.
With openkneeboard: 29 fps, laggy picture, seeing double vision.
My GPU is at over 95% utilization with the kneeboard on or off, doesn't change much.

Settings:

Specs:
Ryzen 5 5600X
RTX 3070
32GB Ram @3000
Up to date Win10, fresh install
DCS and OS on NVME SSD
Reverb G2 (Windows Mixed reality -> SteamVR -> DCS)

@fredemmott fredemmott changed the title Performance Problems Performance Problems with all steamvr overlays with HP reverb G2 Jan 30, 2022
@fredemmott
Copy link
Collaborator

Retitled based on discord discussion - in particular that this isn’t specific to openkneeboard.

@fredemmott
Copy link
Collaborator

fredemmott commented Jan 30, 2022

This is fine for me with steamvr with a 3090ti and Oculus Quest; most obvious differences are:

  • GPU memory - and 3070 (8gb) vs 3090 (24gb) more generally
  • Oculus vs WMR+HP drivers

Things to check performance of:

  • getting an IVROverlay* (this is the API, not the object representing our specific overlay)
  • handling gaze zoom
    • fetching position
    • built-in "is headset pointing at this overlay" function
  • SetOverlayWidthInMeters, even when no change
  • polling for overlay events
  • texture
    • BGRA vs RGBA textures (BGRA is needed for other systems, e.g. Direct2D, but conversion can be done outside of OpenVR if needed)
    • alpha (translucency); already done in the most efficient way, may need to be disabled or optional
  • SetOverlayTransformAbsolute, even if no change (unlikely: only done when page/tab changes)
  • GPU RAM
  • some other issue in SteamVR/WMR/HP drivers
  • some other issue in OpenKneeboard

I don't currently have ideas for distinguishing between the last 3 cases.

fredemmott added a commit that referenced this issue Jan 30, 2022
Must use Snapshot::GetSharedTexture() instead

This also means that OpenVR does not call SetOverlayWidthInMeters unless the sequence number has changed

refs #21
@fredemmott
Copy link
Collaborator

fredemmott commented Jan 30, 2022

SetOverlayWidthInMeters, even when no change

If 30115cb (and corresponding build, click on the colored dot when it's green if you're not building yourself) fixes it, this was the problem, otherwise it's ruled out

handling gaze zoom

If commenting out the lines I mentioned in discord fixes it, it's one of these subproblems, otherwise it's ruled out

fredemmott added a commit that referenced this issue Jan 30, 2022
No noticable difference with oculus+steamvr, but may affect other implementations

refs #21
@fredemmott
Copy link
Collaborator

Ticked options are addressed in latest build, don't know if they're the cause though.

@fritzcloud
Copy link
Author

Ticked options are addressed in latest build, don't know if they're the cause though.

So with the latest GitHub action build I can try again?

@fredemmott
Copy link
Collaborator

Yes, but please separately try commenting out the gaze stuff (https://github.com/fredemmott/OpenKneeboard/blob/master/src/app/okOpenVRThread.cpp#L141-L180) if the latest version doesn't resolve it

@fredemmott
Copy link
Collaborator

GPU RAM
some other issue in OpenKneeboard

I'm not able to get meaningful numbers for OpenKneeboard here - https://docs.microsoft.com/en-us/troubleshoot/windows-client/performance/gpu-process-memory-counters-report-wrong-value kicks in so they're nonsense. I can easily make it say I'm using 3TB of GPU memory.

@000Ready000
Copy link

000Ready000 commented Feb 1, 2022

Hi I am also using a G2 and am having similar degraded performance with VRK. Is there any way I can help to test? I would really love to have OpenKneeboard working, because it is very promising.

@fredemmott
Copy link
Collaborator

Are you able to build yourself? If not, try downloading the 'OpenKneeboard-RelWithDebInfo' version from https://github.com/fredemmott/OpenKneeboard/actions/runs/1779544249

If that works without issues for you, great, this might be fixed :)

If that doesn't fix the problem, you're comfortable building from source and already familiar with cmake + visual studio, the next step is seeing if commenting out https://github.com/fredemmott/OpenKneeboard/blob/master/src/app/okOpenVRThread.cpp#L141-L180 fixes it; if not https://github.com/fredemmott/OpenKneeboard/blob/master/src/app/okOpenVRThread.cpp#L130-L139

If neither, and you're familiar with direct2d or direct3d, try changing the texture format

If none of those, seems likely to be an unworkable issue with steamvr/winvr/HP drivers

@fredemmott
Copy link
Collaborator

commenting those sections out removes functionality - the purpose of commenting them out isn't to fix it, just to identify which parts of the openvr API are slowing things down.

@000Ready000
Copy link

Hi sorry I forgot to say, I am not a programmer, just an enthusiastic DCS player. I am only able to put files in folders using OVGME and adjusting some basic configuration files in plain text.

@fredemmott
Copy link
Collaborator

If not, try downloading the 'OpenKneeboard-RelWithDebInfo' version from https://github.com/fredemmott/OpenKneeboard/actions/runs/1779544249

You should see this in the artifacts section - it's a zip file; extract it, then in bin/ you'll have OpenKneeboard.exe - try that :)

@fredemmott
Copy link
Collaborator

Can anyone confirm whether or not this is still an issue?

@000Ready000
Copy link

000Ready000 commented Feb 17, 2022 via email

@fredemmott fredemmott added the needs more info Further information is requested label Feb 20, 2022
@fritzcloud
Copy link
Author

I am not at home as well. Can only test in a week or so

@fredemmott
Copy link
Collaborator

Closing: no reports of this in a long time, and several g2 users are happy

built-in "is headset pointing at this overlay" function

Coincidentally removes this in 64b5656 as part of #39

@fredemmott
Copy link
Collaborator

Following up, problems resolved for original reporter (@Sirtz ) by using OpenComposite + the openxr alpha instead of steamvr

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs more info Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants