question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

DllNotFoundException: XRSDKOpenVR

See original GitHub issue

Hi,

I tried setting up a new project for VR. Went through the following steps:

  • Created project using HDRP template
  • Imported the XR Plugin unitypackage
  • Enabled the OpenVR Loader in the Project Settings
  • Made sure I’m in a scene where the Main Camera has been converted to an XRRig
  • Started SteamVR just to be sure

Press Play and this error pops up. I can see the DLL in the Package Cache just fine.

DllNotFoundException: XRSDKOpenVR Unity.XR.OpenVR.OpenVRLoader.Initialize () (at Library/PackageCache/com.valvesoftware.unity.openvr@1.0.0-preview.6/Runtime/OpenVRLoader.cs:183) UnityEngine.XR.Management.XRManagerSettings.InitializeLoaderSync () (at Library/PackageCache/com.unity.xr.management@3.2.13/Runtime/XRManagerSettings.cs:169) UnityEngine.XR.Management.XRGeneralSettings.InitXRSDK () (at Library/PackageCache/com.unity.xr.management@3.2.13/Runtime/XRGeneralSettings.cs:175) UnityEngine.XR.Management.XRGeneralSettings.AttemptInitializeXRSDKOnLoad () (at Library/PackageCache/com.unity.xr.management@3.2.13/Runtime/XRGeneralSettings.cs:148) I’ve tried this in both 2019.4 and 2020.1 and both have the same error. I’m using Valve Index and version 1.0.0-preview.6 of the OpenVR XR Plugin

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:23

github_iconTop GitHub Comments

2reactions
zitecommented, Jul 22, 2020

I was able to replicate (and fix) this locally by uninstalling visual studio and some tools. Looks like we’ve fixed it now by compiling with static linking. Please update to preview-9 and let me know if that fixes things.

For people having a similar issue with cmake and unity native plugins that won’t load due to missing dependencies: We added this to our cmake lists file:

if(MSVC)
    message(WARNING "Adding static link option.")
    add_compile_options(
        $<$<CONFIG:>:/MT> #---------|
        $<$<CONFIG:Debug>:/MTd> #---|-- Statically link the runtime libraries
        $<$<CONFIG:Release>:/MT> #--|
    )
endif()
1reaction
halfpasttensecommented, Jul 21, 2020

Also, just to give you a heads up - the XR Interaction system won’t fully work with this plugin since it doesn’t provide input. You’ll need to use the SteamVR Unity Plugin for input ( https://github.com/ValveSoftware/steamvr_unity_plugin/releases/tag/2.6.0b3 )

Can you please give us an idea of when it will support XR Interaction system again? A previous version supported it and I started using it. Now that it’s gone again I need to decide whether to take the time to go back again to the old way of doing input. This has really thrown a wrench in my development plans and having no idea when it will be supported again is making it pretty damn difficult to plan ahead.

Read more comments on GitHub >

github_iconTop Results From Across the Web

UnityOpenXR when trying to run deviceless on Mac - ...
Bug DllNotFoundException: UnityOpenXR when trying to run deviceless on Mac. Discussion in 'VR' started by laurie71, Jan 31, 2022. openxr ...
Read more >
DllNotFoundException: XRSDKOpenVR 原创
Unity中使用SteamVR 2.0 时异常: DllNotFoundException: XRSDKOpenVR. Unity.XR.OpenVR.OpenVRLoader.
Read more >
"DllNotFoundException: aristo_interface". What should I do?
My Unity build throws this exception: "DllNotFoundException: aristo_interface". What should I do? Guide Downloads. SDK ...
Read more >
Problems with steam vr files after unity update :: SteamVR ...
Hey so i updated unity to 2018.3.1f1 today and it started spitting out three errors with the steam vr code, been trying to...
Read more >
InterceptFeaturePlugin assembly:<unknown ...
DllNotFoundException : InterceptFeaturePlugin assembly:<unknown assembly> type:<unknown type> member:(null) UnityEngine.XR.OpenXR.Samples.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found