Main Page   File List  

Constants.h

00001 #ifndef Constants_H
00002 #define Constants_H
00003 
00004 #include <math.h>
00005 
00006  //Image
00007 #define ORIG_IMAGE_WIDTH   176
00008 #define ORIG_IMAGE_HEIGHT  144
00009 #define SOBEL_IMAGE_WIDTH  175
00010 #define SOBEL_IMAGE_HEIGHT 143
00011 const int ORIG_IMAGE_SIZE  = ORIG_IMAGE_WIDTH * ORIG_IMAGE_HEIGHT;
00012 const int SOBEL_IMAGE_SIZE = SOBEL_IMAGE_WIDTH * SOBEL_IMAGE_HEIGHT;
00013 
00014 //Histogram
00015 #define NUMBER_OF_GREYS  256
00016 #define K_MIN            -0.2
00017 #define K_MAX            0.02 //not currently used
00018 #define INTERVAL         5
00019 #define SMOOTH_INTERVAL  4
00020 
00021 //Blob information
00022 #define MAX_DISTANCE_TO_PIXEL  11 //10 seems reasonable for this size
00023 #define ON_PIXEL        255
00024 #define OFF_PIXEL       0
00025 #define BLOB_PIXEL      128
00026 #define MAX_BLOB_RADIUS 8
00027 #define MIN_BLOB_SIZE   6
00028 const int MAX_BLOB_SIZE = (int)(pow(MAX_BLOB_RADIUS,2)*M_PI);
00029 
00030 //Ball recognition
00031 #define DISTANCE_TOLERANCE  2
00032 #define ANGLE_TOLERANCE  10
00033 #define OPTIMAL_ANGLE  60
00034 const float MIN_ANGLE = cos((OPTIMAL_ANGLE - ANGLE_TOLERANCE)*(M_PI/180));
00035 const float MAX_ANGLE = cos((OPTIMAL_ANGLE + ANGLE_TOLERANCE)*(M_PI/180));
00036 #define SCALE_TO_REAL_WORLD  10/100.0 //I have nooo clue about this!! Needs testing
00037 
00038 #endif

Generated on Wed May 28 09:10:45 2003 by doxygen1.2.18