Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

Modules/SpecialVision/ChallengeSpecialVision.h

Go to the documentation of this file.
00001 /**
00002 * @file ChallengeSpecialVision.h
00003 * 
00004 * Definition of class ChallengeSpecialVision
00005 * This class finds out the orientation of the robot for the "Almost-Slam-Challenge"
00006 *
00007 * @author Thomas Kindler
00008 * @author Matthias Hülsbusch
00009 * @author Michael Wachter
00010 */
00011 
00012 #ifndef __ChallengeSpecialVision_h_
00013 #define __ChallengeSpecialVision_h_
00014 
00015 #include "SpecialVision.h"
00016 
00017 
00018 #define NUMBEROFSECTORS 36
00019 
00020 class ChallengeSectorData
00021 {
00022 public:
00023   int numPixels[numOfColors];
00024 };
00025 
00026 
00027 class ChallengeSpecialVision : public SpecialVision
00028 {
00029 public:
00030   /** Constructor 
00031   * @param interfaces The interfaces of the SpecialVision module */
00032   ChallengeSpecialVision(const SpecialVisionInterfaces& interfaces);
00033 
00034   /** Executes the module */
00035   virtual void execute();
00036   
00037 private:
00038   void executeLearnOrientation();
00039   void executeFindOrientation();
00040   void executeGetOrientation();
00041   void executeReset();
00042   ChallengeSectorData countPixels(int x1,int x2,int y1,int y2);
00043   
00044 private:
00045   void sort( double* a, const int number);
00046   double alngleDifDegree(double a, double b);
00047   double flagAngle[MAXLEARNFLAGS];
00048   double foundAngle[MAXLEARNFLAGS];
00049   int flagCount;
00050   int foundAngleCount;
00051 
00052 private:
00053   ChallengeSectorData data[NUMBEROFSECTORS];
00054 
00055 };
00056 
00057 #endif// __BarCodeReader_h_
00058 
00059 /*
00060 * Change log :
00061 * 
00062 * $Log: ChallengeSpecialVision.h,v $
00063 * Revision 1.3  2004/07/01 18:42:08  hamerla
00064 * SLAM challenge find Orientation
00065 *
00066 * Revision 1.2  2004/06/28 16:02:37  wachter
00067 * First lines of code for challenge-special-vision
00068 *
00069 * Revision 1.1  2004/06/28 11:54:55  wachter
00070 * Added Special-Vision classes for Challenge
00071 *
00072 *
00073 */

Generated on Thu Sep 23 19:57:32 2004 for GT2004 by doxygen 1.3.6