I’m having a problem building my Unity Kinect v2 app to Windows Store.
It says:
First-chance exception at 0x76064598 in Template.exe: Microsoft C++ exception: Platform::ClassNotRegisteredException ^ at memory location 0x07A8F63C. HRESULT:0x80040154 Class not registered
This error means the assembly was not added to AppXManifest.xml file. This maybe related to recent bug introduced in Visual Studio 2013 Update 4, if you’re not using this update, maybe you incorrectly added the library to the project
I even tried it to Update 3, same thing happens. I also tried to changed the debug architecture to x86, it runs smoothly but there’s no color image display or Kinect Tracking.
If ever how can I add the assembly to AppXManifest.xml?
Or how do I properly export Unity App with plugin/s to Windows Store?
Sorry for the noob question.
Hey @Tomas1856 ,
I am experiencing the same error trying to run a windows store app with the kinectv2 unity plugin. I am unsure what a correct AppXManifest.xml looks like with KinectUnityAddin.dll referenced. I do not see KinectUnityAddin referenced in my appx at all. Could someone post a correct AppXManifest.xml with the reference? @mangjoey123 were you able to resolve this issue?
VS 2013.3
VS 2013.4
Unity 4.6
My Error
First-chance exception at 0x76F42F71 in Template.exe: Microsoft C++ exception: Platform::ClassNotRegisteredException ^ at memory location 0x092BF3B8. HRESULT:0x80040154 Class not registered
I’ve tried manually editing the Appxmanifest.xml in the AppX dir with the following, (and using a cut-down version of the Kinect API that only calls Windows.Kinect.KinectSensor.GetDefault()) I then manually re-package, re-sign & deploy but still no joy:
From the Kinect SDK Release notes, it looks like it should be possible to build a Windows Store app on Windows 8.1:
Ok, I’ve made progress. Thanks to @Artiom-K , I pulled apart the “Earth” XAML / Unity / Kinect example and figured out why we’re getting the “Class Not Registered.” Basically, the Visual Studio project created from Unity is missing some required Win 8.1 SDK References, in particular: “WindowsPreview.Kinect” and “Microsoft.Kinect.VisualGestureBuilder”(see the attached screenshot.)
I suppose this makes sense, Unity doesn’t know that the KinectUnityAddin requires specific windows sdk frameworks.
EDIT: Adding these references updates the Appxmanfiest.xml file (among others), so that it contains these extra entries:
Thanks @ . I feel like we are getting close to a solution here. It feels like it’s all related to the export from unity.
My project shouldn’t need the VisualGestureBuilder extension and I believe that WindowsPreview.Kinect was needed for Kinect support only during the Kinect V2 beta.
I did add them to my projects and received this error when building
Sadly, there’s no such option, Unity cannot know, that you are required to add such references.
But that’s also the reason, why Unity doesn’t overwrite the generated solution and project if they’re already present, so if you add these extra references, the next time you export from Unity, they won’t be gone.
@kbo4sho88 I can’t see why the snippet you pasted errored. I’d recommend making sure all the paths in your UnityCommon.props file are correct, then clearing / creating a new Windows Store build folder and try “build & run” from within Unity. Hope that helps!
I believe I had some conflicts with the pre release version of the Kinect SDK. I uninstalled all versions of the SDK and reinstalled the latest one.
To get my Unity app with the Kinect package to export and work in windows store I do this…
-In Unity build project as 8.1 w/ C# projects
-Make sure apppackage.manifest has webcam and mic capabilities
-Add references to KinectPreview extension to the two supporting projects in my solution
-Change build configuration to x86 on the two supporting projects and in the configuration manager
-Run and smile
Thanks @ @Tomas1856 and everyone else who helped out.
UPDATE: I did notice that at least on my hardware, if all of the steps are not taken, running and receiving errors can cause the Kinect sensor to get into a state where it can not be connected to. The only way I am able to resolve when this occurs is to restart my computer.
Hi, I’ve been trying to achieve the same thing and I’m having similar errors.
"
First-chance exception at 0x76004598 in Template.exe: Microsoft C++ exception: Platform::ClassNotRegisteredException ^ at memory location 0x0643F1C0. HRESULT:0x80040154 Class not registered
If there is a handler for this exception, the program may be safely continued.
"
Ive followed bko4sh088’s steps in the above post but I still get the same error. Could you please post some more detailed instructions? Also has anyone done this with Unity 5? Thats what I’m using
Set up the dll in metro folder to build for WSAPlayer
Tick microphone and webcam boxes in player settings, publishing settings, capabilities
Build for windows 8.1 (do not tick C# project box)
One project will be created in the VS solution. Right click on references\ add reference\Windows8.1\Extensions\ then tick the box for WindowsPreview.Kinect (x86 windows 8.1 version)