00001 // Copyright (C) 2002 Dominic Letourneau 00002 #ifndef _PTZCONTROL_H_ 00003 #define _PTZCONTROL_H_ 00004 #include "BufferedNode.h" 00005 #include <pthread.h> 00006 #include <gnome.h> 00007 #include <list> 00008 00009 namespace RobotFlow { 00010 00011 class PTZControl : public FD::BufferedNode { 00012 00013 protected: 00014 00015 //widgets 00016 GtkWidget *window1; 00017 00018 //commands 00019 std::list<int> m_absPanCommands; 00020 std::list<int> m_absTiltCommands; 00021 std::list<int> m_absZoomCommands; 00022 std::list<int> m_relPanCommands; 00023 std::list<int> m_relTiltCommands; 00024 std::list<int> m_relZoomCommands; 00025 00026 //outputs 00027 int m_relPanID; 00028 int m_relTiltID; 00029 int m_relZoomID; 00030 int m_absPanID; 00031 int m_absTiltID; 00032 int m_absZoomID; 00033 00034 //parameters 00035 int m_minZoomSliderVal; 00036 int m_maxZoomSliderVal; 00037 00038 public: 00039 00040 PTZControl(std::string nodeName, FD::ParameterSet params); 00041 00042 virtual ~PTZControl(); 00043 00044 /**Class specific initialization routine. 00045 Each class will call its subclass specificInitialize() method*/ 00046 virtual void initialize(); 00047 00048 virtual void calculate(int output_id, int count, FD::Buffer &out); 00049 00050 void addAbsPanCommand(int command); 00051 void addAbsTiltCommand(int command); 00052 void addAbsZoomCommand(int command); 00053 void addRelPanCommand(int command); 00054 void addRelTiltCommand(int command); 00055 void addRelZoomCommand(int command); 00056 00057 }; 00058 }//namespace RobotFlow 00059 00060 #endif