{"id":19119705,"url":"https://github.com/enoxsoftware/hololenswithdlibfacelandmarkdetectorexample","last_synced_at":"2025-05-05T14:42:29.165Z","repository":{"id":49715923,"uuid":"91197620","full_name":"EnoxSoftware/HoloLensWithDlibFaceLandmarkDetectorExample","owner":"EnoxSoftware","description":"HoloLens With DlibFaceLandmarkDetector Example (Support for Hololens1 and Hololens2)","archived":false,"fork":false,"pushed_at":"2024-12-11T16:44:22.000Z","size":354737,"stargazers_count":32,"open_issues_count":0,"forks_count":12,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-19T09:58:50.489Z","etag":null,"topics":["augmented-reality","dlib-face-detection","face-detection","face-landmarks","hololens","hololens2","mixed-reality","mrtk","opencv","unity"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/EnoxSoftware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-05-13T19:19:41.000Z","updated_at":"2025-04-06T14:39:58.000Z","dependencies_parsed_at":"2024-11-25T18:19:45.447Z","dependency_job_id":"247d865a-5da9-4e9a-9fae-398a7a10e21f","html_url":"https://github.com/EnoxSoftware/HoloLensWithDlibFaceLandmarkDetectorExample","commit_stats":null,"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EnoxSoftware%2FHoloLensWithDlibFaceLandmarkDetectorExample","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EnoxSoftware%2FHoloLensWithDlibFaceLandmarkDetectorExample/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EnoxSoftware%2FHoloLensWithDlibFaceLandmarkDetectorExample/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EnoxSoftware%2FHoloLensWithDlibFaceLandmarkDetectorExample/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/EnoxSoftware","download_url":"https://codeload.github.com/EnoxSoftware/HoloLensWithDlibFaceLandmarkDetectorExample/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252516182,"owners_count":21760742,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["augmented-reality","dlib-face-detection","face-detection","face-landmarks","hololens","hololens2","mixed-reality","mrtk","opencv","unity"],"created_at":"2024-11-09T05:10:42.708Z","updated_at":"2025-05-05T14:42:29.144Z","avatar_url":"https://github.com/EnoxSoftware.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# HoloLens With DlibFaceLandmarkDetector Example\r\n\r\n\r\n## Demo Video (old version)\r\n[![](http://img.youtube.com/vi/egMZB_3DGVc/0.jpg)](https://youtu.be/egMZB_3DGVc)\r\n\r\n\r\n## Environment\r\n* HoloLens1 10.0.17763.316 / HoloLens2 22621.1399\r\n* Windows 10 SDK 10.0.19041.0 / 10.0.22621.0\r\n* Unity 2021.3.35f1 (Built-in Render Pipeline / OpenXR 1.11.1 / MRTK 2.8.3 / DirectX 11 / Visual Studio 2022 MSVC v143)\r\n* Unity 2021.3.35f1 (Built-in Render Pipeline / OpenXR 1.11.1 / MRTK 3.2.2 / DirectX 11 / Visual Studio 2022 MSVC v143)\r\n* [Mixed Reality Feature Tool](https://learn.microsoft.com/en-us/windows/mixed-reality/develop/unity/welcome-to-mr-feature-tool)\r\n* [OpenCV for Unity](https://assetstore.unity.com/packages/tools/integration/opencv-for-unity-21088?aid=1011l4ehR) 2.6.4+ \r\n* [Dlib FaceLandmarkDetector](https://assetstore.unity.com/packages/tools/integration/dlib-facelandmark-detector-64314?aid=1011l4ehR) 1.4.1+ \r\n* [EnoxSoftware/HoloLensCameraStream](https://github.com/EnoxSoftware/HoloLensCameraStream)\r\n\r\n\r\n\r\n## Setup (Common)\r\n1. Download the latest release unitypackage. [HoloLensWithDlibFaceLandmarkDetectorExample.unitypackage](https://github.com/EnoxSoftware/HoloLensWithDlibFaceLandmarkDetectorExample/releases)\r\n1. Create a new project. (`HoloLensWithDlibFaceLandmarkDetectorExample`)\r\n    * Change the platform to `UWP` in the \"Build Settings\" window.\r\n1. Import and setup the Microsoft Mixed Reality Toolkit. (Recommend using [MixedRealityFeatureTool](https://www.microsoft.com/en-us/download/details.aspx?id=102778))\r\n1. Import the OpenCVForUnity.\r\n    * Select MenuItem[Tools/OpenCV for Unity/Open Setup Tools].\r\n    * Click the [Move StreamingAssets Folder] button.\r\n    * Leave the following files and delete the rest. (\"StreamingAssets/OpenCVForUnity/objdetect/haarcascade_frontalface_alt.xml\", \"lbpcascade_ frontalface.xml\")\r\n1. Import the DlibFaceLandmarkDetector.\r\n    * Select MenuItem[Tools/Dlib FaceLandmark Detector/Open Setup Tools].\r\n    * Click the [Move StreamingAssets Folder] button.\r\n    * Leave the following files and delete the rest. (\"StreamingAssets/DlibFaceLandmarkDetector/sp_human_face_68.dat\", \"sp_human_face_68_for_mobile.dat\", \"sp_human_face_17.dat\", \"sp_human_face_17_for_mobile.dat\" and \"sp_human_face_6.dat\")\r\n1. Clone HoloLensCameraStream repository.\r\n    * Copy the \"HoloLensCameraStream/HoloLensVideoCaptureExample/Assets/CamStream/\" folder to the \"Assets/\" folder.\r\n1. Import the HoloLensWithDlibFaceLandmarkDetectorExample.unitypackage.\r\n1. Add the \"Assets/HoloLensWithDlibFaceLandmarkDetectorExample/*.unity\" files to the \"Scenes In Build\" list in the \"Build Settings\" window.\r\n1. Configure settings in the \"Project Settings\" window.\r\n    * Add Define Symbols: the following to `Scripting Define Symbols` depending on the XR system used in your project; Legacy built-in XR: `BUILTIN_XR`; XR Plugin Management (Windows Mixed Reality): `XR_PLUGIN_WINDOWSMR`; XR Plugin Management (OpenXR):`XR_PLUGIN_OPENXR`.\r\n    * Enable `WebCam` Capabilties in Publishing settings tab.\r\n1. (Optional) Setup a performance environment suitable for Holorens. (See [https://docs.microsoft.com/en-us/windows/mixed-reality/develop/unity/recommended-settings-for-unity](https://docs.microsoft.com/en-us/windows/mixed-reality/develop/unity/recommended-settings-for-unity))\r\n1. **Build the project:** You can now build the Unity project, which generates a Visual Studio Solution (which you will then have to also build). With the Build Settings window still open, click **Build**. In the explorer window that appears, make a new folder called `App`, which should live as a sibling next to the 'Assets` folder. Then click Select Folder to generate the VS solution in that folder. Then wait for Unity to build the solution.\r\n1. **Open the VS Solution:** When the solution is built, a Windows explorer folder will open. Open the newly-built VS solution, which lives in `App/HoloLensWithDlibFaceLandmarkDetectorExample.sln`. This is the solution that ultimately gets deployed to your HoloLens.\r\n1. **Configure the deploy settings:** In the Visual Studio toolbar, change the solution platform from `ARM` to `x86` if you are building for Hololens1 or to `ARM64` if you are building for Hololens2; Change the deploy target (the green play button) to `Device` (if your HoloLens is plugged into your computer), or `Remote Machine` (if your HoloLens is connected via WiFi).\r\n1. **Run the app:** Go to **Debug \u003e Start Debugging**. Once the app is deployed to the HoloLens, you should see some confirmation output in the Output window.\r\n    *  (Print the AR marker \"CanonicalMarker-d10-i1-sp500-bb1.pdf\" on an A4 size paper)  \r\n\r\n* [Choosing a Unity version and XR plugin](https://learn.microsoft.com/en-us/windows/mixed-reality/develop/unity/choosing-unity-version)\r\n* [Known issues in Unity versions and packages](https://learn.microsoft.com/en-us/windows/mixed-reality/develop/unity/known-issues)\r\n\r\n\r\n## Setup (Unity 2021 (Built-in Render Pipeline / OpenXR / MRTK 2 / DirectX 11 / Visual Studio 2022))\r\n1. Download the latest release unitypackage.\r\n1. Create a new project. (`HoloLensWithDlibFaceLandmarkDetectorExample`)\r\n1. Import the Microsoft Mixed Reality Toolkit.\r\n    * Add MRTK2 (Mixed Reality Toolkit - Mixed Reality Toolkit Foundation) and OpenXR(Platform Support - Mixed Reality OpenXR Plugin) to the project using \"Mixed Reality Feature Tool\".\r\n    * Follow the MRTK2 configuration dialog to set up the project. (XR System: OpenXR)\r\n1. Import the OpenCVForUnity.\r\n1. Import the DlibFaceLandmarkDetector.\r\n1. Import the HoloLensCameraStream.\r\n1. Import the HoloLensWithDlibFaceLandmarkDetectorExampleMRTK2.unitypackage.\r\n1. Add the \"Assets/HoloLensWithDlibFaceLandmarkDetectorExample/*.unity\" files to the \"Scenes In Build\" list in the \"Build Settings\" window.\r\n1. Configure settings in the \"Project Settings\" window.\r\n    * Add `XR_PLUGIN_OPENXR` to the list of Define Symbols.\r\n    * Enable `WebCam` Capabilties in Publishing settings tab.\r\n1. Build the project; open it in VS2022, set the deployment target to `ARM64` and deploy it to the Hololens2 actual device.\r\n\r\n* [Set up a new OpenXR project with MRTK](https://learn.microsoft.com/en-us/windows/mixed-reality/develop/unity/new-openxr-project-with-mrtk)\r\n\r\n\r\n## Setup (Unity 2021 (Built-in Render Pipeline / OpenXR / MRTK 3 / DirectX 11 / Visual Studio 2022))\r\n1. Download the latest release unitypackage.\r\n1. Create a new project. (`HoloLensWithDlibFaceLandmarkDetectorExample`)\r\n1. Import the Microsoft Mixed Reality Toolkit.\r\n    * Add MRTK3 (MRTK3 - MRTK Input, MRTK UX Components, MRTK UX Components (Non-Canvas)) and OpenXR(Platform Support - Mixed Reality OpenXR Plugin) to the project using \"Mixed Reality Feature Tool\".\r\n    * * Set up the MRTK3. (XR System: OpenXR)\r\n1. Import the OpenCVForUnity.\r\n1. Import the DlibFaceLandmarkDetector.\r\n1. Import the HoloLensCameraStream.\r\n1. Import the HoloLensWithDlibFaceLandmarkDetectorExampleMRTK3.unitypackage.\r\n1. Add the \"Assets/HoloLensWithDlibFaceLandmarkDetectorExample/*.unity\" files to the \"Scenes In Build\" list in the \"Build Settings\" window.\r\n1. Configure settings in the \"Project Settings\" window.\r\n    * Add `XR_PLUGIN_OPENXR` to the list of Define Symbols.\r\n    * Enable `WebCam` Capabilties in Publishing settings tab.\r\n1. Build the project; open it in VS2022, set the deployment target to `ARM64` and deploy it to the Hololens2 actual device.\r\n\r\n* [Setting up a new Unity project with MRTK3](https://learn.microsoft.com/en-us/windows/mixed-reality/mrtk-unity/mrtk3-overview/getting-started/setting-up/setup-new-project)\r\n\r\n\r\n\r\n\r\n\r\n|Project Assets|Build Settings|\r\n|---|---|\r\n|![ProjectAssets.jpg](ProjectAssets.jpg)|![BuildSettings.jpg](BuildSettings.jpg)|\r\n\r\n|Player Settings|\r\n|---|\r\n|![PlayerSettings.jpg](PlayerSettings.jpg)|\r\n\r\n\r\n## ScreenShot (old version)\r\n![screenshot01.jpg](screenshot01.jpg) \r\n\r\n![screenshot02.jpg](screenshot02.jpg) \r\n\r\n![screenshot03.jpg](screenshot03.jpg) \r\n\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fenoxsoftware%2Fhololenswithdlibfacelandmarkdetectorexample","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fenoxsoftware%2Fhololenswithdlibfacelandmarkdetectorexample","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fenoxsoftware%2Fhololenswithdlibfacelandmarkdetectorexample/lists"}