static void on_trackbar(int pos)
{
- (void)pos;
IplImage* cnt_img = cvCreateImage( cvSize(w,w), 8, 3 );
CvSeq* _contours = contours;
int _levels = levels - 3;
+ (void)pos;
+
if( _levels <= 0 ) // get to the nearest face to make it look more funny
_contours = _contours->h_next->h_next->h_next;
cvZero( cnt_img );
int main(int argc, char* argv[])
{
- (void)argc; (void)argv;
int i, j;
CvMemStorage* storage = cvCreateMemStorage(0);
IplImage* img = cvCreateImage( cvSize(w,w), 8, 1 );
IplImage* img32f = cvCreateImage( cvSize(w,w), IPL_DEPTH_32F, 1 );
IplImage* img32s = cvCreateImage( cvSize(w,w), IPL_DEPTH_32S, 1 );
IplImage* img3 = cvCreateImage( cvSize(w,w), 8, 3 );
+ (void)argc; (void)argv;
+
help();
cvZero( img );
static void drawOptFlowMap(const CvMat* flow, CvMat* cflowmap, int step,
double scale, CvScalar color)
{
- (void)scale;
int x, y;
+ (void)scale;
for( y = 0; y < cflowmap->rows; y += step)
for( x = 0; x < cflowmap->cols; x += step)
{
int main( int argc, char** argv )
{
- (void)argc; (void)argv;
CvCapture* capture = cvCreateCameraCapture(0);
CvMat* prevgray = 0, *gray = 0, *flow = 0, *cflow = 0;
+ (void)argc; (void)argv;
help();
// callback function for open/close trackbar
static void OpenClose(int pos)
{
- (void)pos;
int n = open_close_pos - max_iters;
int an = n > 0 ? n : -n;
+ (void)pos;
+
element = cvCreateStructuringElementEx( an*2+1, an*2+1, an, an, element_shape, 0 );
if( n < 0 )
{
// callback function for erode/dilate trackbar
static void ErodeDilate(int pos)
{
- (void)pos;
int n = erode_dilate_pos - max_iters;
int an = n > 0 ? n : -n;
+ (void)pos;
+
element = cvCreateStructuringElementEx( an*2+1, an*2+1, an, an, element_shape, 0 );
if( n < 0 )
{