Search code examples
c#unity-game-engineuwphololensopenxr

Openxr_runtime_debugger.pdb not loaded


I am working on an app that performs face recognition on the Hololens 2 using Unity 2021.3.4f1. I'm having trouble debugging with the Hololens while everything works fine when I'm running the app via the editor.

Basically, I take a picture and save it to disk (as in this tutorial) and it should then be read and used by azure's face detection client like so:

        using (Stream faceimagestream = File.OpenRead(filepath))
        {
            detectedFaces = await client.Face.DetectWithStreamAsync(
                faceimagestream, 
                returnFaceAttributes: features, 
                detectionModel: DetectionModel.Detection01, 
                recognitionModel: recognitionModel);
        }

The exception I get when the app stops is an access violation in a reading process, though I already included the capabilities "Picture Library" and "Removable Storage" (as suggested here) in Unity.

However, I cannot really debug anything because debugging stops automatically and I get a "openxr_runtime_debugger.pdb not loaded" screen. I am already using the microsoft symbolserver to search for .pdbs, but it seems like it is nowhere to be found. I also cannot find any information about this specific .pdb file. The only other cue that I have that may have something to do with this issue is a warning in Unity : "Importer(NativeFormatImporter) generated inconsistent result for asset(guid:6475d5bfdd00d214fbd2816e4c83512a) "Assets/XR/Settings/Open XR Package Settings.asset"". It appears after every build, even though I reimported all assets, deleted the library folder, updated the Unity Version from 2020.3.22 to 2021.3.4.

This is the error in Visual Studio: This is the error in Visual Studio

Update:

It seems to work sometimes (!) if I delete the unity build folder before building again AND delete the app on the Hololens.

More debugging information about loading symbols: enter image description here


Solution

  • The solution was to switch back to the MRTK "DefaultHololens2ConfigurationProfile".