- 1、本文档共10页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
OpenCVCanny源码解析解读
OpenCV Canny 源码解析
1986年,John F.Canny 完善了边缘检测理论,Canny算法以此命名。
Canny 算法的步骤:
1. 使用滤波器卷积降噪
2. 使用Sobel导数计算梯度幅值和方向
3. 非极大值抑制 + 滞后阈值
在正式处理前,用高斯滤平滑波器对图像做滤波降噪的操作,避免噪声点的干扰,但在OpenCV的canny源码中,没有进行高斯滤波,需要使用者自行滤波;有些资料将非极大值抑制和滞后阈值视为两个步骤也是可行的,但是在源码中非极大值抑制 和滞后阈值是同时进行的。
canny源码的位置:\opencv\sources\modules\imgproc\src\canny.cpp
参考了网上许多资料,有不足之处请指正,谢谢。
[cpp] view plain copy 在CODE上查看代码片派生到我的代码片
/*M///////////////////////////////////////////////////////////////////////////////////////
//
// IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING.
//
// By downloading, copying, installing or using the software you agree to this license.
// If you do not agree to this license, do not download, install,
// copy or use the software.
//
//
// Intel License Agreement
// For Open Source Computer Vision Library
//
// Copyright (C) 2000, Intel Corporation, all rights reserved.
// Third party copyrights are property of their respective owners.
//
// Redistribution and use in source and binary forms, with or without modification,
// are permitted provided that the following conditions are met:
//
// * Redistributions of source code must retain the above copyright notice,
// this list of conditions and the following disclaimer.
//
// * Redistributions in binary form must reproduce the above copyright notice,
// this list of conditions and the following disclaimer in the documentation
// and/or other materials provided with the distribution.
//
// * The name of Intel Corporation may not be used to endorse or promote products
// derived from this software without specific prior written permission.
//
// This software is provided by the copyright holders and contributors as is and
// any express or implied warranties, including, but not limited to, the implied
// warranties of merchantability and fitness for a particular purpose are disclaimed.
// In no event sh
您可能关注的文档
最近下载
- 幼儿园《滚进球门》大班科学活动课件.pptx
- 五年级快乐读书吧 整本书阅读名师优课《中国民间故事》导读课课件.pptx VIP
- 粉体科学工艺手册handbook-of-powder-science--technology-1997.pdf
- 网络营销基础与实务第二版何晓兵各章案例分析答案.docx
- 国家开放大学计算机网络(本)形考任务答案作业四实验报告答案.docx
- Unit 1Let’s be friends! 综合素质达标2024-2025- 外研版(2024)英语三年级上册.doc VIP
- 《合成树脂工业污染物排放标准》(GB 31572-2015)修改单(征.pdf VIP
- GB18351-2015车用乙醇汽油(E10).pdf
- 汽车机械基础 孙杰 任务二 液压元件新.ppt
- 非线性大作业—直流电动机调速系统的建模与控制系统的设计.docx
文档评论(0)