Getting Started

Since WinRT Components use C++/CX the wrapper can be used in Universal Windows Platform (UWP) apps that are written in C#, Visual Basic, JavaScript, and other languages that support the Windows Runtime. For example, it can be used in a HoloLens application like CompanionMR.

Feel free to use the provided sample app as a starting point. Unfortunately CMake is currently not able to integrate the C# project to the generated Visual Studio Solution automatically. Follow these steps to do that manually:

  1. Open the generated project file CompanionWinRT.sln in Visual Studio.
  2. Go to File > Add > Existing Project... and select the project file <build_dir>\CompanionUWPSample\CompanionUWPSample.csproj. > Be aware that the sample project is being copied to the build directory so it won’t be under version control.

  3. Add CompanionWinRT as a reference to the CompanionUWPSample project: right click on the project name and choose Add > Reference....

  4. Right click on CompanionUWPSample and choose Set as StartUp Project.

  5. Add your OpenCV DLLs to the project by right clicking on CompanionUWPSample and choosing Add > Existing Item....