Commit bf808fac authored by Gary Bradski's avatar Gary Bradski

created parameter description doc and output

parent a4385b18
...@@ -4,6 +4,16 @@ ...@@ -4,6 +4,16 @@
using namespace cv; using namespace cv;
void help()
{
printf( "This program demonstrated the use of the latentSVM detector.\n"
"It reads in a trained object model and then uses that to detect the object in an image\n"
"Call:\n"
"./latentsvmdetect [<image_filename> <model_filename]\n"
" The defaults for image_filename and model_filename are cat.jpg and cat.xml respectively\n"
" Press any key to quit.\n");
}
const char* model_filename = "cat.xml"; const char* model_filename = "cat.xml";
const char* image_filename = "cat.jpg"; const char* image_filename = "cat.jpg";
...@@ -31,9 +41,9 @@ void detect_and_draw_objects( IplImage* image, CvLatentSvmDetector* detector) ...@@ -31,9 +41,9 @@ void detect_and_draw_objects( IplImage* image, CvLatentSvmDetector* detector)
cvReleaseMemStorage( &storage ); cvReleaseMemStorage( &storage );
} }
int main(int argc, char* argv[]) int main(int argc, char* argv[])
{ {
help();
if (argc > 2) if (argc > 2)
{ {
image_filename = argv[1]; image_filename = argv[1];
...@@ -63,4 +73,4 @@ int main(int argc, char* argv[]) ...@@ -63,4 +73,4 @@ int main(int argc, char* argv[])
cvDestroyAllWindows(); cvDestroyAllWindows();
return 0; return 0;
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment