From: Gary Bradski Date: Mon, 29 Nov 2010 07:57:03 +0000 (+0000) Subject: updated docs X-Git-Tag: accepted/2.0/20130307.220821~4053 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9ebaaecc85b4ac8b9582559ee3b0f1d880b529c7;p=profile%2Fivi%2Fopencv.git updated docs --- diff --git a/samples/cpp/morphology2.cpp b/samples/cpp/morphology2.cpp index 4d7a64e..31cbd5d 100644 --- a/samples/cpp/morphology2.cpp +++ b/samples/cpp/morphology2.cpp @@ -7,6 +7,20 @@ using namespace cv; +void help() +{ + +printf("Show off image morphology: erosion, dialation, open and close\n" + "Call:\n morphology2 [image]\n" + "This program also shows use of rect, elipse and cross kernels\n\n"); +printf( "Hot keys: \n" + "\tESC - quit the program\n" + "\tr - use rectangle structuring element\n" + "\te - use elliptic structuring element\n" + "\tc - use cross-shaped structuring element\n" + "\tSPACE - loop through all the options\n" ); +} + Mat src, dst; int element_shape = MORPH_RECT; @@ -49,12 +63,7 @@ int main( int argc, char** argv ) if( (src = imread(filename,1)).data == 0 ) return -1; - printf( "Hot keys: \n" - "\tESC - quit the program\n" - "\tr - use rectangle structuring element\n" - "\te - use elliptic structuring element\n" - "\tc - use cross-shaped structuring element\n" - "\tSPACE - loop through all the options\n" ); + help(); //create windows for output images namedWindow("Open/Close",1);