none
Body tracking application stopped working (it freezes every 2 seconds) in Windows 10 RRS feed

  • Question

  • A few weeks ago my Body tracking application using Kinect V2 depth sensor started to freeze every 2 seconds (approx). To isolate the problem I tried running the Kinect Studio. To my surprise, when I opened the Kinect Studio and connected it to the camera, my application was still running and it stopped freezing and started running smoothly. As soon as I closed the Kinect Studio, the freezing came back.

    I haven't changed anything in my application for years, and it used to work without this problem. Any ideas about what could be causing this and any possible solution?

    Monday, April 30, 2018 11:46 AM

All replies

  • Does that also happen when using Configuration Verifier? What about the samples of the SDK?
    Friday, May 4, 2018 8:46 AM
  • I think I found (more or less) what's causing the problem. I was using Kinect in a videogame running at 50 fps. The game made a request to Kinect per frame. I completely changed this approach, and now I have a thread coninously requesting frames to Kinect and storing them in a variable replacing the last one. Every 1/50 seconds the game reads the last Kinect frame stored in the variable. Doing that, I solved my problem. I guess there's some "economy mode" that brings Kinect to a weird state if it does not receive requests at some rate.

    In any case, this behavior is new. It didn't happen some weeks/months ago. I guess this is related to a Windows 10 update.

    Wednesday, May 9, 2018 8:33 AM
  • It could be an update issue but I doubt the problem was the per-frame calls. Kinect has a service running in the background and updates its data every 30FPS.The service is the one responsible for getting the raw data from the sensor,sending them to GPU for processing and then distributing them to applications. If you try to query in between the 30FPS, you will get cached results. Doesn't have to do with the Kinect itself, more like your application. Are you sure you're acquiring and releasing the frames properly? I've been using the polling approach per-frame for 2 years now in a desktop app and haven't had an issue, with the app(disregarding the Kinect input) running at 60FPS. Also the design philosophy was that you could run multiple apps simultaneously.

    Since it works now, my only advice is, check your memory management and check that you properly release the frames before doing anything. Also don't cache the frames, but their data.


    Wednesday, May 9, 2018 9:33 AM
  • Thank you for your reply.

    I had also been using the polling approach per frame for years without an issue until now. In fact, I hadn't change my code for years. It is not happening with all our Windows 10, but with some of them. I am not sure about the cause of our problem, but, with the very same code in an independent thread it is working fine.

    In fact, my application worked if Kinect studio or a Kinect SDK sample was running at the same time. If I closed them, after some seconds, the issue came back again.

    Since nothing changed in our application, I assumed that something had changed in Windows/Kinect software.

    Wednesday, May 9, 2018 9:51 AM
  • After reading your post I tried to run the Configuration Verifier, and I started to see that in "Verify Kinect Depth and Color Streams" at some point fps drop down and stays between 0 and 6. At this point, If I open Kinect studio even without clicking "connect", fps go back to 30. As soon as I close Kinect Studio, it goes down again between 0 and 6.
    Wednesday, May 9, 2018 11:56 AM
  • Have you tried reinstalling the SDK? Sounds like either a bad driver or a problem with the sensor.
    Wednesday, May 9, 2018 12:06 PM