Using ONI files as Unity input

Hello all,
I have been trying to use pre-recorded .oni files as input for Unity with no success.
What I’ve done so far:

  1. Recorded .oni using NiViewer on TVico.(only depth video is available to record)
  2. Copied .oni files to my PC through USB.
  3. Changed nuitrack.config in my PC:
"OpenNIModule": {
        "FileRecord": "D:\\VIDEOS\video.oni"
    },
  1. Video is working and skeleton appears correctly on nuitrack samples.

When using live feed from TVico using WiFi, the app works correctly. What I intend to do is to pre-record some files to avoid having to walk up to the camera everytime I want to test something.
So, what to do next? Setting Wifi Connect to “None” in Unity Nuitrack Manager script doesn’t do anything.

Thanks.

Solved: Some of the preprocessing directives in the NuitrackManager.cs

#if (UNITY_IOS || UNITY_ANDROID)”

caused this problem. For now I’ve commented the lines related to this, but a better workaround should be done.
Also, be careful when setting the mirror boolean in the DepthModule or it will screw the arm tracking up.

Hey, I think my issue is related to this, not 100% certain though.
I have .oni recordings that I would like to use as input for the TVico to provide a pre-recorded feed via wifi instead of the live image. I have the .oni file on the TVIco, referenced it in the nuitrack.config and the recording is playing on the TVIco when i run the Nuitrack-App.
But Unity stays in “skeleton not found” state, when changing to live input everything works fine.
Regarding your solution:
NuitrackManager.cs in the recent version does not have the “UNITY_IOS” preprocessor directives, and commenting out the ones left for “UNITY_ANDROID” did not change anything, do you maybe have any more info on how you got it working or which version you were using where you got it fixed?

And thank you for posting your solution :slight_smile: