00001 #ifndef NDT_DISPLAY_H 00002 #define NDT_DISPLAY_H 00003 00004 #include <boost/circular_buffer.hpp> 00005 00006 #include <ndt_map/NDTMapMsg.h> 00007 #include <rviz/message_filter_display.h> 00008 00009 namespace Ogre 00010 { 00011 class SceneNode; 00012 } 00013 00014 namespace rviz 00015 { 00016 class ColorProperty; 00017 class FloatProperty; 00018 class IntProperty; 00019 } 00020 00021 namespace lslgeneric{ 00022 00023 class NDTVisual; 00024 00025 class NDTDisplay: public rviz::MessageFilterDisplay<ndt_map::NDTMapMsg>{ 00026 Q_OBJECT 00027 public: 00028 00029 NDTDisplay(); 00030 virtual ~NDTDisplay(); 00031 00032 protected: 00033 virtual void onInitialize(); 00034 00035 virtual void reset(); 00036 00037 private Q_SLOTS: 00038 void updateColorAndAlpha(); 00039 void updateHistoryLength(); 00040 00041 private: 00042 void processMessage(const ndt_map::NDTMapMsg::ConstPtr& msg); 00043 00044 std::vector<boost::shared_ptr<NDTVisual> > visuals_; 00045 00046 rviz::ColorProperty* color_property_; 00047 rviz::FloatProperty* alpha_property_; 00048 rviz::IntProperty* history_length_property_; 00049 }; 00050 } 00051 00052 #endif 00053