Revision 938
OpenCV now works directly with firewire, coriander is not needed
New vision algorithm integrated, a few issues left with algorithm that
tracks the movement of a specific robot
Removed experimental interface to send images over commands socket
--plan to use php in webserver instead
Separated processing of client requests into a separate thread
Fixed bugs updating UI of java client
capturetest.c | ||
---|---|---|
7 | 7 |
|
8 | 8 |
#define MIN_PADDING 70 |
9 | 9 |
|
10 |
//#define CAPTURE
|
|
10 |
#define CAPTURE |
|
11 | 11 |
|
12 | 12 |
struct CenterP { |
13 | 13 |
CvPoint center; |
... | ... | |
21 | 21 |
int main(int argc, char *argv[]) |
22 | 22 |
{ |
23 | 23 |
#ifdef CAPTURE |
24 |
CvCapture* capture = cvCaptureFromCAM( -1 );
|
|
24 |
CvCapture* capture = cvCaptureFromCAM( 0 );
|
|
25 | 25 |
if( !capture ) { |
26 | 26 |
fprintf( stderr, "ERROR: capture is NULL \n" ); |
27 | 27 |
return -1; |
... | ... | |
104 | 104 |
|
105 | 105 |
//If ESC key pressed, Key=0x10001B under OpenCV 0.9.7(linux version), |
106 | 106 |
//remove higher bits using AND operator |
107 |
} while((cvWaitKey(0) & 255) != 27); |
|
107 |
} while((cvWaitKey(10) & 255) != 27);
|
|
108 | 108 |
|
109 | 109 |
#ifdef CAPTURE |
110 | 110 |
// Release the capture device housekeeping |
Also available in: Unified diff