【问题标题】:How do I synchronize the color and depth sensors for Kinect for Windows using MATLAB?如何使用 MATLAB 同步 Kinect for Windows 的颜色和深度传感器?
【发布时间】:2013-08-07 20:00:07
【问题描述】:

我正在使用 MATLAB 和官方 Kinect SDK 从 Kinect for Windows 捕获颜色和深度图像。我希望两个传感器同步,以便每个传感器的图像在同一时刻。不幸的是,我当前的实现在两个传感器之间存在延迟(几乎 1 秒!)。请帮我找到一种同步传感器的方法。这是我当前的代码:

colorVid = videoinput('kinect',1,'RGB_640x480');
depthVid = videoinput('kinect',2,'Depth_640x480');
triggerconfig([colorVid depthVid],'Manual');
set([colorVid depthVid], 'FramesPerTrigger', 300);
start([colorVid depthVid]);
trigger([colorVid depthVid]);
pause(10);
[imgColor, ts_color, metaData_Color] = getdata(colorVid);
[imgDepth, ts_depth, metaData_Depth] = getdata(depthVid);
stop([colorVid depthVid]);
delete([colorVid depthVid]);
clear colorVid depthVid;

【问题讨论】:

    标签: matlab kinect


    【解决方案1】:

    我已经玩了一段时间了,似乎在 start() 和 trigger() 函数之间添加一个暂停可以解决这个问题!

    start([colorVid depthVid],'FramesPerTrigger',300);
    pause(1);
    trigger([colorVid depthVid]);
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-08-12
      • 2013-01-06
      • 2013-04-02
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多