ColorSensor callback is not called when restarted

Hi,

I am trying to respond to plugging / unplugging of the camera with the application.

  1. Check the camera device and start with Nuitrack::init().
  2. Acquire depth data with DepthSensor::connectOnNewFrame(), RGB data with ColorSensor::connectOnNewFrame(), and skeleton data with SkeletonTracker::connectOnUpdate().
  3. When camera device is unplugged, call Nuitrack :: release () to exit Nuitrack.

There is no problem so far.

  1. The camera device is inserted and restarted from Nuitrack :: init ().
  2. Attempt to obtain depth data with DepthSensor::connectOnNewFrame (), RGB data with ColorSensor::connectOnNewFrame(), and skeleton data with SkeletonTracker::connectOnUpdate().
    ColorSensor::connectOnNewFrame() callback is not called.

Visual Studio 2017 C++
Camera : Astro Pro
Nuitrack SDK : ver.1.3.7

I would appreciate any help
Thanks

Hi Takahashi,

Please advise did you describe the operating cycle for one application launch (i.e. the application wasn’t closed and restarted) (pp. 1-5)? Or you unplug the device, close the app, plug in the device and run the app once again?

The correct operating cycle for an app using Nuitrack is as follows:

  1. Plug in the sensor
  2. Call Nuitrack::init()
  3. Call Nuitrack::release()
  4. Unplug the sensor

Unplugging the sensor before calling Nuitrack::release() can cause incorrect release of resources.