Notice
Recent Posts
Recent Comments
Link
«   2025/07   »
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31
Tags
more
Archives
Today
Total
관리 메뉴

저장소

edge detection(canny) 본문

OpenCV

edge detection(canny)

김연호님 2016. 4. 9. 18:38

#include <opencv/cv.h>

#include <opencv/highgui.h>


using namespace cv;

using namespace std;


int main(void)

{

// Original Image

Mat image = imread("C:/Users/Administrator/Desktop/pop.png", CV_LOAD_IMAGE_COLOR);

imshow("Original image", image);


// Original Image to Gray Image

Mat gray;

cvtColor(image, gray, CV_BGR2GRAY);


// Canny Filter

Mat canny;

Canny(gray, canny, 100, 150);


// Result Image

imshow("image", canny);


waitKey(0);

return 0;

}


'OpenCV' 카테고리의 다른 글

영상반전  (0) 2016.04.10
이미지 띄우기  (0) 2016.04.09
edge detection(sobel)  (0) 2016.04.09
이미지 회전  (0) 2016.04.08
템플릿 매칭  (0) 2016.03.04
Comments