摘要: 白底换红底局部阈值调整边界高斯滤波function demoglobal Rglobal thresholdglobal imgglobal dstColorglobal rectglobal maskglobal biasStepbiasStep = 5;dstColor = [255 0 0]; %% background colorimg = imread('g.jpg'); %% load photoR = img(:,:,1);[mm, nn] = size(R);rect = [1 1 nn, mm];threshold = 200 * ones(mm, nn); 阅读全文
posted @ 2013-09-06 20:36 goooooooooo 阅读(1255) 评论(1) 推荐(1) 编辑
摘要: http://www.it-ebooks.info/ 阅读全文
posted @ 2013-08-01 10:52 goooooooooo 阅读(357) 评论(0) 推荐(0) 编辑
摘要: http://blog.sina.com.cn/s/blog_7321be1101013aua.htmlhttp://soft.chinabyte.com/os/51/12324551.shtmlhttp://blog.chinaunix.net/uid-14735472-id-3400847.htmlhttp://www.leewei.org/?p=1016http://www.cnblogs.com/kevinGaoblog/archive/2012/03/23/2413102.html 阅读全文
posted @ 2013-07-30 23:52 goooooooooo 阅读(175) 评论(0) 推荐(0) 编辑
摘要: opencv c++ mat获取像素及像素赋值For accessing pixel's channel value :for (int i = 0; i (j, i); for(int k = 0; k (j, i); for(int k = 0; k (j, i);//intensity是image.at返回的引用的另一个别名 Vec3b &intensity = image.at(j, i); 阅读全文
posted @ 2013-07-22 11:18 goooooooooo 阅读(14010) 评论(0) 推荐(0) 编辑
摘要: opencv提供了很多Mat的操作,其中涉及到两个重要的类:MatOp和MatExprC++: MatExpr abs(const Mat& m)C++: void absdiff(InputArray src1, InputArray src2, OutputArray dst)C = abs(A-B) is equivalent to absdiff(A, B, C)C = abs(A) is equivalent to absdiff(A, Scalar::all(0), C)C++: void add(InputArray src1, InputArray src2, Outp 阅读全文
posted @ 2013-07-12 16:13 goooooooooo 阅读(4112) 评论(0) 推荐(0) 编辑
摘要: 转自:How Physics Engines Work高中物理全还给老师了啊啊啊啊啊啊牛顿第二定律物体加速度的大小跟物体受到的作用力成正比,跟物体的质量成反比,加速度的方向跟合外力的方向相同。 而以物理学的观点来看,牛顿运动第二定律亦可以表述为“物体随时间变化之动量变化率和所受外力之和成正比”,即动量对时间的一阶导数等 于外力之和。牛顿第二定律说明了在宏观低速下,a∝F/m,F∝ma,用数学表达式可以写成F=kma,其中的k为比例系数,是一个常数。但由于当时没有 规定多大的力作为力的单位,比例系数k的选取就有一定的任意性,如果取k=1,就有F=ma,这就是今天我们熟知的牛顿第二定律的数学表达式 阅读全文
posted @ 2013-07-10 16:55 goooooooooo 阅读(786) 评论(0) 推荐(0) 编辑
摘要: DataType : 将C++数据类型转换为对应的opencv数据类型enum { CV_8U=0, CV_8S=1, CV_16U=2, CV_16S=3, CV_32S=4, CV_32F=5, CV_64F=6 };// allocates a 30x40 floating-point matrix // CV_32FMat A(30, 40, DataType::type);Mat B = Mat_ >(3, 3);// the statement below will print 6, 2 /*, that is depth == CV_64F, channels == 2*/ 阅读全文
posted @ 2013-07-07 20:19 goooooooooo 阅读(28161) 评论(1) 推荐(7) 编辑
摘要: http://blog.csdn.net/fdl19881/article/details/7275203ctags .vim: http://www.vim.org/scripts/script.php?script_id=610taglist.vim : http://www.vim.org/scripts/script.php?script_id=273tags for std c++ :http://www.vim.org/scripts/script.php?script_id=2358$ ctags -R --sort=yes --c++-kinds=+p --fields=+ia 阅读全文
posted @ 2013-07-07 10:16 goooooooooo 阅读(1237) 评论(0) 推荐(0) 编辑
摘要: #!/bin/sh find . -name "*.h" -o -name "*.c" -o -name "*.cc" > cscope.files cscope -bkq -i cscope.files ctags -Rcscope生成三个索引文件cscope.out, cscope.in.out, cscope.po.outadd : Add a new database (Usage: add file|dir pre-path ):cscope add cscope.out在 vim 中可以使用命令缩写:cs a csc 阅读全文
posted @ 2013-07-04 15:11 goooooooooo 阅读(805) 评论(0) 推荐(0) 编辑
摘要: http://docs.opencv.org/opencv 2.x APIopencv包含以下模块 core 基本数据机构 imgproc 图像处理方法 video 视频处理方法 calib3d 图形学方法 features2d 区域检测算子和描述算子 objdetect 目标检测方法 highgui GUI相关 gup GPU加速方法 ......opencv中有些函数名称会与其他包提供的名称冲突,因此:using namespace cv;OpenCV内存管理opencv的基本数据结构如Mat包含析构函数,在引用数为0时,释放空间;引用数非0时调用则引用数减1。copy只是增加引用,clo 阅读全文
posted @ 2013-07-04 09:02 goooooooooo 阅读(870) 评论(0) 推荐(0) 编辑