HoloViveObserver icon indicating copy to clipboard operation
HoloViveObserver copied to clipboard

alignmentManagerObject has not been assigned

Open MaximeGL opened this issue 7 years ago • 13 comments

Hello, I launched my project in Play Mode with Holographic Remoting, my Hololens joined the match and is connected to the server but I have this error :

UnassignedReferenceException: The variable alignmentManagerObject of PlayerController has not been assigned. You probably need to assign the alignmentManagerObject variable of the PlayerController script in the inspector.

No need to assign in the inspector because alignmentManagerObject has the attribute [HideInInspector] and normally alignmentManagerObject is set by HoloViveNetworkManager.cs with the SpawnPlayer() method.

What is my mistake?

MaximeGL avatar Jun 06 '17 12:06 MaximeGL

Which Unity Version do you use?

mrwellmann avatar Jun 06 '17 14:06 mrwellmann

Unity 5.6 I modified Holotoolkit and SteamVr and I haven't any problem for compile

MaximeGL avatar Jun 06 '17 15:06 MaximeGL

I had issues with 5.6. Using currently Unity 5.5.2f1 and for the Hololens build I used UWP SDK 10.0.1493.0. See my issue (https://github.com/dag10/HoloViveObserver/issues/9) for more infos.

mrwellmann avatar Jun 06 '17 15:06 mrwellmann

Not all my problems are fixed but it help to fix the detection controller problem in Unity 5.6: https://github.com/ValveSoftware/steamvr_unity_plugin/pull/14/files

MaximeGL avatar Jun 06 '17 17:06 MaximeGL

Did you fix your UnassignedReferenceException problem? Have you tried to use the Hololens without holographic remoting? I've got it running directly on the device and I have voice output on Hololens but no visuals.

mrwellmann avatar Jun 07 '17 07:06 mrwellmann

~~Yes it fixed my UnassignedReferenceException problem~~ Now I can see the Vive controllers in the Vive application

But I still have this problems: -Only when I deploy on Hololens (without holographic remoting) I have a skybox in the Hololens camera (Is my Vive camera active? And why?) -The Alignment system doesn't work, I don't see the pink ViveController in Hololens (May be obstructed by my hologram in the center of my scene)

MaximeGL avatar Jun 07 '17 08:06 MaximeGL

You should not have a sky box on your Hololens http://images.devs-on.net/Image/KEzoIYE6H3bkWC3B-Bereich.png. Except you changed the sky box setting of course.

May I ask which UWP SDK you use for the build of Hololens.

mrwellmann avatar Jun 07 '17 08:06 mrwellmann

For the build in Hololens in Unity 5.6.1f1, UWP SDK is set on Latest Installed which is 10.0.14393.0

MaximeGL avatar Jun 07 '17 08:06 MaximeGL

Oh I didn't solve my UnassignedReferenceException problem ! My Alignment Manager was unactive that's why. It just solved the detection of Vive controller in Unity 5.6.

My Bad.

Yes I know for the skybox that's the problem. My Hololens camera is OK. Maybe it appeared because my app makes an error.

MaximeGL avatar Jun 07 '17 09:06 MaximeGL

You can see the debug output of an app if you deploy with VS to Hololens with debugging enabled (F5). Output will be shown in VS Output Window.

I've created an empty scene in the Project and run Holographic Remoting and also run the app with Debug enabled over VS. With both I get a similar error output. Holographic Remoting: "D3D11: Failed to create render texture primary RTV (error 0x80070057)" VS Debug: "D3D11: Failed to create render texture SRV (error 0x80070057)"

Just to make sure I also debugged another Hololens App and there I did not get the error.

mrwellmann avatar Jun 07 '17 11:06 mrwellmann

Ok my error was not to read the solved issues https://github.com/dag10/HoloViveObserver/issues/4 This fixed my prob.

For me everything works now. How about you?

mrwellmann avatar Jun 07 '17 14:06 mrwellmann

-I still have a problem with the Hololens camera. As soon as Hololens connect to the server, it changes the camera and I have a skybox like the Vive camera

-I can align the environment but I can't see the pink controller

In your Player prefab: Are your NetworkTransform script and your AlignmentClient script uncheck?

MaximeGL avatar Jun 07 '17 15:06 MaximeGL

Here are some Screens which might help to find your prob: Player Prefabs: http://images.devs-on.net/Image/A0B5gDjyPAARQECd-Bereich.png Player Prefabs ingame after Hololens sync: http://images.devs-on.net/Image/DtVsXTpbt6ibq4JZ-Bereich.png NetworkManager: http://images.devs-on.net/Image/vwRxcwrz0sET2rYj-Bereich.png VR Camera Rig and Hololens Camera: http://images.devs-on.net/Image/xYe3LCjdBX2tepMr-Bereich.png Running Hololens in Holographic Remoting: http://images.devs-on.net/Image/gMwZ8eak6BSQl0vR-Bereich.png

As you can see from the last screen Holographic Remoting is partially working now. The important piece of code is at Utils.cs there its gettinge determied which camera will be used. http://images.devs-on.net/Image/FtD1gzEjEdTSKHtu-Bereich.png

I hope this helps I would be happy to see a working Unity 5.6 version.

I've you are not able to get it working you can also take my Unity 5.5.2 version https://github.com/mrwellmann/HoloViveObserver.

mrwellmann avatar Jun 08 '17 09:06 mrwellmann