2014-05-07 17:10:26 -0600 | commented question | image moment normalization well actually i am not copying anything , i am trying to understand a method in the thesis , and i put the link only if more info is needed ! and i provided the number f pages and another equations that if found from a book . |
2014-05-07 00:01:58 -0600 | asked a question | image moment normalization I am doing a sign language to voice recognition ,i am using normalized moments to compare databse images and captured frame , moments are used to calculate the orientation of the image and rotate it so that between orientation and reference angle there's a 5 degree difference ,i am following the method in this thesis link text more explaination of normalizarion is from page 28 to 30 . The problem is when i am trying to implement the code the results are as follows ! when trying to compare the final result with an image captured by subtracting pixels and defining a threshold value of 80 percent , only input images which are the same give the correct answer , so the problem is in the normalization part but i can't identify how to improve it this is the normalization method :: (more) |
2014-04-28 03:52:03 -0600 | asked a question | Unrecognized Array type in cvGetMAt ,Moment Normalization I am trying to understand and run this function of moment normalization for hand gesture recognition ,however i am getting this error unrecognized or unsupported Array type in function cvGetMAt or cvGetSIze , i think it is something with input to the function normalize2 it take char* test , in the main i called it with normalize2("hand.jpg") , It loads successfuly so this isn't the problem, and i also tried different images with jpg structute but it didn't help .
char * imageDB="hands.jpg"; //Any image with standard size in DB test="hands.jpg"; //name of captured image to be tested with images in DB char * name=0; cvNamedWindow("show",1); cvShowImage("show",test); CvMoments moments; cvNamedWindow("Tobe_Modified",1); cvMoveWindow( "Tobe_Modified", 0, 50); cvNamedWindow("final",1); cvMoveWindow( "final", 500, 50); cvNamedWindow("compare",1); cvMoveWindow( "compare", 250, 400); pic1 = cvLoadImage( test,0); //Size of captured image pic2 = cvLoadImage( test,0); //Size of standard-size image in dB(Standard) w=cvGetSize(pic2).width/2; //Set rotation axes from size of image h=cvGetSize(pic2).width/2; temp1 = cvCreateImage( cvGetSize(pic1), IPL_DEPTH_8U, 1 ); temp1 = cvLoadImage( test,0); cvResize( temp1,temp2, CV_INTER_NN ); // Normalize SIZE to standard size of Temp2 temp3 = cvCreateImage( cvGetSize(temp2), IPL_DEPTH_8U, 1 ); temp4 = cvCreateImage( cvGetSize(temp2), IPL_DEPTH_8U, 3 );
Main int main(int argc, char* argv) { IplImage img = cvLoadImage("hand.jpg"); if (!img) { cout <<"NOT LOADED= "<<endl; return="" 1;="" }else="" {="" cout="" <<"loaded="" "="" <<endl;="" normalize2("hand.jpg");="" }="" cvreleaseimage(&img);<="" p=""> return 0; } |
2014-04-19 12:29:41 -0600 | asked a question | Visual studio 2012 closes immediately I know this question is asked before but i tried all solutions and it didn't work out in my case , from changing properties linker system adding cvwaity() key all didn't work , also ctrl +f5 didn't work , so can you please help , i need to go on with my project and this is making me late . the windows opens and closes immediately , sometimes it opens and stays and then when i try running again and it goes back to the habit of closing immediately //Code for hand detection and tracking; include <iostream>include "opencv/cv.h"include "opencv/highgui.h"using namespace std; IplImage image = 0, *hsv = 0, *hue = 0, *mask = 0, *backproject = 0, *histimg = 0,back = 0, back2 = 0,image2 = 0,image3 = 0,bg = 0; CvHistogram *hist = 0; //IplImage * ContrastBrightness(IplImage *, int , int ); int backproject_mode = 0; int select_object = 0; int track_object = 0; int show_hist = 1; CvPoint origin; CvPoint RECT1; CvPoint RECT2; CvPoint p1; CvPoint p2; CvRect selection; CvRect track_window; CvRect roiS; //Rect for size of ROI CvBox2D track_box; CvConnectedComp track_comp; int hdims = 16; float hranges_arr[] = {0,180}; float* hranges = hranges_arr; int vmin = 10, vmax = 256, smin = 30; int area=0; int contrast=100, bright=50,smooth=7; double x,y,h,w; void on_mouse( int event, int x, int y, int flags, void* param ) { if( !image ) return; if( image->origin ) y = image->height - y; if( select_object ) { selection.x = MIN(x,origin.x); selection.y = MIN(y,origin.y); selection.width = selection.x + CV_IABS(x - origin.x); selection.height = selection.y + CV_IABS(y - origin.y); selection.x = MAX( selection.x, 0 ); selection.y = MAX( selection.y, 0 ); selection.width = MIN( selection.width, image->width ); selection.height = MIN( selection.height, image->height ); selection.width -= selection.x; selection.height -= selection.y; } switch( event ) { //on left mouse click ,mark as origin and intialize rectangle case CV_EVENT_LBUTTONDOWN: origin = cvPoint(x,y); selection = cvRect(x,y,0,0); select_object = 1; break; case CV_EVENT_LBUTTONUP: select_object = 0; if( selection.width > 0 && selection.height > 0 ) track_object = -1; break; } } //Page 61of 83 //Audible Sign Language FYP Report- Spring 2006 CvScalar hsv2rgb( float hue ) { int rgb[3], p, sector; static const int sector_data[][3]= {{0,2,1}, {1,2,0}, {1,0,2}, {2,0,1}, {2,1,0}, {0,1,2}}; hue = 0.033333333333333333333333333333333f; sector = cvFloor(hue); p = cvRound(255(hue - sector)); p ^= sector & 1 ? 255 : 0; rgb[sector_data[sector][0]] = 255; rgb[sector_data[sector][1]] = 0; rgb[sector_data[sector][2]] = p; return cvScalar(rgb[2], rgb[1], rgb[0],0); } int main( int argc, char** argv ) { CvCapture* capture = 0; capture = cvCaptureFromCAM(0); //creating 3 windows and co controlling their position cvNamedWindow( "CamShiftDemo", 1 ); cvMoveWindow( "CamShiftDemo", 335, 100 ); cvNamedWindow( "ROI", 1 ); cvMoveWindow( "ROI", 10, 100 ); cvNamedWindow( "grey", 1 ); cvMoveWindow( "grey", 670, 100 ); bg=cvLoadImage ("bg.jpg",1); //C++: void setMouseCallback(const string& winname, MouseCallback onMouse, void* userdata=0 ) //cvSetMouseCallback( "CamShiftDemo", on_mouse, 0 ); //C++: int createTrackbar(const string& trackbarname, const string& winname, int* value Optional pointer to an integer variable whose value reflects the position of the slider ... (more) |
2014-04-14 18:37:25 -0600 | answered a question | background subtraction help check this out link text |
2014-04-14 18:14:52 -0600 | received badge | ● Supporter (source) |
2014-04-10 18:41:01 -0600 | answered a question | hand detect -android Hello can you please inform me where did u reach in this project and provide help Thank u |
2014-04-05 14:30:54 -0600 | commented question | OpenCV Image blob detection and Gesture support on Android Hello Did u reach any finding , can you please share Thanks |
2014-04-05 12:08:54 -0600 | commented answer | opencv4android - hand detection using viola jones (haar cascade) Hello , Can you please share the links or if you find anything that could help this is my project too . Thanks |
2014-04-05 10:43:27 -0600 | received badge | ● Editor (source) |
2014-04-05 10:42:37 -0600 | asked a question | HelloOpencvAndroid Error Hello , I am a newbie for both android and OpenCv , My project is Gesture recognition I started with the helloOpencV example here http://docs.opencv.org/doc/tutorials/introduction/android_binary_package/dev_with_OCV_on_Android.html#dev-with-ocv-on-android I imported Opencv and all the samples work with no errors , but when i try to do my own project i click android-properties-add-openCv library it gives a red X like this Also any suggestions of steps i can to take to do my project as i feel clueless about it. Thanks Alot |