/KlakNDIWithOpenCVForUnityExample

This is an example of using KlakNDI to receive a video stream delivered by NDI®, convert it to the OpenCV Mat class and apply image processing.

Primary LanguageC#

KlakNDI With OpenCVForUnity Example

KlakNDIWithOpenCVForUnityExample_1 KlakNDIWithOpenCVForUnityExample_2

YouTube Live --> OBS Studio + DistroAV --> KlakNDI --> OpenCV for Unity

Overview

  • Integrate "KlakNDI" with "OpenCV for Unity".
  • This is an example of using KlakNDI to receive a video stream delivered by NDI®, convert it to the OpenCV Mat class and apply image processing.

Environment

  • Windows / macOS / Linux / Android / iOS
  • Unity >= 2022.3.54f1+
  • Scripting backend MONO / IL2CPP
  • OpenCV for Unity 2.6.5+
  • KlakNDI

Setup

  1. Download the latest release unitypackage. KlakNDIWithOpenCVForUnityExample.unitypackage
  2. Create a new project. (KlakNDIWithOpenCVForUnityExample)
  3. Import and Setup OpenCV for Unity.
    • Download Dnn model files by ExampleAssetsDownloader.
      download_dnn_models.png
    • Move the files from the "OpenCVForUnity/StreamingAssets/" folder to the "Assets/StreamingAssets" folder.
      move_streamingassetsfolder.png
  4. Import and Setup KlakNDI.
  5. Import KlakNDIWithOpenCVForUnityExample.unitypackage.
  6. Add the "Assets/KlakNDIWithOpenCVForUnityExample/*.unity" files to the "Scenes In Build" list in the "Build Settings" window.
  7. Build and Deploy.
    setup.png

ScreenShot

screenshot01.png screenshot02.png screenshot03.png screenshot04.png