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

Modules/SensorBehaviorControl/SimpleMotionRecognition.h

Go to the documentation of this file.
00001 /**
00002 * @file SimpleMotionRecognition.h
00003 *
00004 * Definition of class SimpleMotionRecognition
00005 *
00006 * @author <a href="mailto:ordyniak@informatik.hu-berlin.de">Sebastian Ordyniak</a>
00007 * @author <a href="mailto:richert@informatik.hu-berlin.de">Marten Richert</a>
00008 */
00009 
00010 #ifndef __SimpleMotionRecognition_h_
00011 #define __SimpleMotionRecognition_h_
00012 
00013 #include "Modules/SensorBehaviorControl/SensorBehaviorControl.h"
00014 #include "Tools/Debugging/DebugDrawings.h"
00015 #include "Tools/Math/Geometry.h"
00016 #include "Tools/Debugging/DebugImages.h"
00017 #include "Tools/Actorics/RobotDimensions.h"
00018 
00019 #define SIMPLEIMAGEBUFFERSIZE 3
00020 #define MINDIFF 30
00021 #define WAITCONST 28 
00022 #define WAITMIN 17
00023 #define SPEEDFAKTOR Vector2<int>(2,1)
00024 #define RESETCONST 40
00025 
00026 /**
00027 * @class SimpleMotionRecognition
00028 *
00029 * @author <a href="mailto:ordyniak@informatik.hu-berlin.de">Sebastian Ordyniak</a>
00030 * @author <a href="mailto:richert@informatik.hu-berlin.de">Marten Richert</a>
00031 */ 
00032 
00033 class SimpleMotionRecognition : public SensorBehaviorControl
00034 {
00035 public:
00036   /** 
00037   * Constructor.
00038   * @param interfaces The paramters of the SimpleMotionRecognition module.
00039   */
00040   SimpleMotionRecognition(const SensorBehaviorControlInterfaces& interfaces);
00041 
00042 
00043   int searchTilt();
00044   int searchPan();
00045   bool headIsNotInMotion();
00046   Vector2<long> getAngleYZ(Vector2<int> point);
00047   Vector2<int> *getMotion();
00048 
00049   /** Executes the module */
00050   virtual void execute();
00051   virtual bool handleMessage(InMessage& message);
00052 
00053 private:
00054   CameraMatrix previousCameraMatrix;
00055   Image imageBuffer[SIMPLEIMAGEBUFFERSIZE];
00056   int start, currentImage, imagesLeft, wait, reset, frameDiff,searchStatus,
00057     halfCameraResolutionHeigth, halfCameraResolutionWidth;
00058   double  halfCameraOpeningAngleHeigth, halfCameraOpeningAngleWidth;
00059   Vector2<int> *motion;
00060   Vector2<long> newHeadPos;
00061 };
00062 #endif// __SimpleMotionRecognition_h_
00063 
00064 /*
00065 * Change log :
00066 * 
00067 * $Log: SimpleMotionRecognition.h,v $
00068 * Revision 1.1.1.1  2004/05/22 17:20:53  cvsadm
00069 * created new repository GT2004_WM
00070 *
00071 * Revision 1.5  2004/03/08 02:11:51  roefer
00072 * Interfaces should be const
00073 *
00074 * Revision 1.4  2004/01/13 02:17:01  richert
00075 * finetuning SimpleMotionDetector
00076 *
00077 * Revision 1.3  2004/01/09 20:09:50  richert
00078 * some improovements
00079 *
00080 * Revision 1.2  2004/01/08 22:01:26  richert
00081 * warning removed
00082 *
00083 * Revision 1.1  2004/01/08 21:51:40  richert
00084 * beginning of "old" SimpleMotionRecognition
00085 *
00086 */

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