/** * @file BackProject_Demo1.cpp * @brief Sample code for backproject function usage * @author OpenCV team */ #include "opencv2/imgproc.hpp" #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp" #include using namespace cv; using namespace std; /// Global Variables Mat src; Mat hsv; Mat hue; int bins = 25; /// Function Headers void Hist_and_Backproj(int, void* ); /** * @function main */ int main( int, char** argv ) { /// Read the image src = imread( argv[1], IMREAD_COLOR ); if( src.empty() ) { cout<<"Usage: ./calcBackProject_Demo1 "<(i)*h/255.0 ) ), Scalar( 0, 0, 255 ), -1 ); } imshow( "Histogram", histImg ); }