OpenCV中文网站

 找回密码
 立即注册
搜索
热搜: 安装 配置
查看: 2766|回复: 1

讨论一下关于OpenCV定标示例代码的几个问题

[复制链接]
发表于 2008-8-1 15:35:50 | 显示全部楼层 |阅读模式
试验了OpenCV文档上的棋盘定标例子,有几个问题不太清楚,请教大家:
1.while (captured_frames < NImages)//为什么要等找到角点的帧数到达20帧之后才在result窗口显示结果图片?
2.原来的宽度和高度是320和240,但是我在实验中只能使用640和480,否则cvCopy会出错。如何控制cvQueryFrame采集图像的宽度和高度?
int image_width = 640;//320;
int image_height = 480;//240;
3.代码中对内参矩阵初始化,没看懂。内参矩阵不是定标要求的结果吗,为何在这里初始化?这些值有什么意义?
        intrinsics->data.fl[0] = 256.8093262;   //fx               
        intrinsics->data.fl[2] = 160.2826538;   //cx
        intrinsics->data.fl[4] = 254.7511139;   //fy
        intrinsics->data.fl[5] = 127.6264572;   //cy

        intrinsics->data.fl[1] = 0;   
        intrinsics->data.fl[3] = 0;   
        intrinsics->data.fl[6] = 0;   
        intrinsics->data.fl[7] = 0;   
        intrinsics->data.fl[8] = 1;          

        distortion_coeff->data.fl[0] = -0.193740;  //k1
        distortion_coeff->data.fl[1] = -0.378588;  //k2
        distortion_coeff->data.fl[2] = 0.028980;   //p1
        distortion_coeff->data.fl[3] = 0.008136;   //p2
4.image_points和object_points对应问题:
调试代码,发现通过cvFindChessboardCorners找出的角点,顺序是按照每行从左到右排列;而InitCorners3D初始化的object_points却是按列从小到大排列,为何?
5.我的摄像头和棋盘都没有变化,照理说应该固定不变。为何每次运行,最后输出的内外参数结果相差都很大?
回复

使用道具 举报

发表于 2008-12-12 00:59:55 | 显示全部楼层

讨论一下关于OpenCV定标示例代码的几个问题

我也有相同的疑问呢
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|OpenCV中文网站

GMT+8, 2024-5-5 02:47 , Processed in 0.011864 second(s), 16 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表