none
How to record videos using kinect

    Question

  • Hi everyone

     

    I'd like to write a GUI to record videos(depth and RGB) using kinect camera.

    My basic idea is to write every frame to disk and then merge them to a video 

    using 3rd API, like OpenCV.

     

    But in this way, some frames will be missed because writing to disk is slow.

    Can anyone give me some hints?

     

    Thanks,

     

     

    Tuesday, July 19, 2011 5:04 AM

Answers

  • Multithread your application.

    In one thread, copy Kinect data to one of a pool of shared buffers.

    In a second thread, save the shared buffers to disk and release the buffers back to the pool.

    Adjust pool size and buffer size to write to disk efficiently.

    Make sure you use proper synchronization on the buffer pool.

    • Marked as answer by zzinuta Wednesday, July 20, 2011 4:51 PM
    Tuesday, July 19, 2011 9:00 PM

All replies

  • Multithread your application.

    In one thread, copy Kinect data to one of a pool of shared buffers.

    In a second thread, save the shared buffers to disk and release the buffers back to the pool.

    Adjust pool size and buffer size to write to disk efficiently.

    Make sure you use proper synchronization on the buffer pool.

    • Marked as answer by zzinuta Wednesday, July 20, 2011 4:51 PM
    Tuesday, July 19, 2011 9:00 PM
  • Hi zzinuta,

    i'm having the same problem than you had 6 month ago!

    Using   e.ImageFrame.ToBitmapSource() from http://c4fkinect.codeplex.com/ i've got each frame saved on my hard disk... now need to merge them in a single video!!

    How can i do this?

    Friday, January 20, 2012 4:28 PM
  • Hi again,

    solved my problem just making a timer that each 30 millisecond load a new picture in the window

    Tuesday, February 07, 2012 8:04 PM
  • Hi,

    how can i making a timer that each 30 millisecond load a new picture in the window?

    i'm try it before, but doesn't work, please help me.....

    Wednesday, October 10, 2012 2:59 PM
  • I am not sure of the scope of your question, but as far as timing things, you might look at the Stopwatch class in the System.Diagnostics namespace.  This class contains a property of ElapsedMilliseconds that you can compare to a long integer.  Does that help you?

    Walt Smith Senior Architect

    Wednesday, October 10, 2012 4:39 PM
  • Hi,

    I am using Color Basics-WPF and Depth Basics-WPF project in the kinect SDK, 

    it can save one frame when you press the button, but i want to know how to save continuous frame automatic,

    because i can find the way to do it. Thanks!!

    Thursday, October 11, 2012 4:10 AM
  • Hi zzinuta,

    I am new to Kinect and facing this problem. Do you have any code to solve this problem that I can take a look, or any other online source. I searched a lot, but no luck yet. I also need to save skeletal data, but probably I can deal with the same way of RGB and depth image.

    Thanks in advance for your help.


    Wednesday, January 09, 2013 1:22 AM
  • Hi zzinuta,

    i'm having the same problem than you had 6 month ago!

    Using   e.ImageFrame.ToBitmapSource() from http://c4fkinect.codeplex.com/ i've got each frame saved on my hard disk... now need to merge them in a single video!!

    How can i do this?

    Hi, Vincenzo_r,

    c4f is a C# library, but I work on C++, so I wander is there same function with e.ImageFrame.ToBitmapSource() that can use for C++?

    Thank you very much.

    Tuesday, January 22, 2013 8:22 AM