I'm making an application for HoloLens 2 that also use Azure Kinect DK to implement some body tracking features (with walking gesture). I have been testing it smoothly in the Unity Editor using Holographic Remoting, but when I build and deploy the app onto the HoloLens 2, I got this error showing on the HoloLens:
DllNotFoundException: Unable to load DLL 'k4a'. Tried the load the following dynamic libraries: Unable to load dynamic library 'k4a' because of 'Failed to open the requested dynamic library (0x06000000) - The specified module could not be found. (WinError: 0000007e)
What I've tried and failed so far:
build\bin\ARM64\Release
folder of the visual studio UWP project that was built by Unity.Assets\Plugins
folder of the Unity project.For context, I use this package to help integrate Azure Kinect DK into Unity: https://assetstore.unity.com/packages/tools/integration/azure-kinect-examples-for-unity-149700. They put the sensor's dlls in this folder Assets\AzureKinectExamples\SDK\Kinect4AzureSDK\Plugins
. For the body tracking SDK dlls, they copy the dlls from the Azure Kinect Body Tracking SDK
install location to the project's root directory. This configuration works for Unity Editor and for "Windows, Mac, Linux" platform, but not for my case.
Currently, Azure Kinect DK does not support UWP. For more information about the operating systems and architectures currently supported by Azure Kinect DK, please refer to Azure Kinect Sensor SDK system requirements | Microsoft Learn.