00001
00002
00003
00004
00005 #ifndef CAJUN_DRAW_STATIC_LAS_H
00006 #define CAJUN_DRAW_STATIC_LAS_H
00007
00008 #include "data_queue.H"
00009 #include "conf.H"
00010 #include "component_interface.H"
00011 #include <vector>
00012
00013 #ifdef VR_JUGGLER
00014 #include <vrj/Draw/OGL/GlContextData.h>
00015 #endif
00016 namespace cajun
00017 {
00018 class draw_static_las_t : public component_interface_t
00019 {
00020 public:
00021 draw_static_las_t (conf_t &conf, char const *static_file);
00022 virtual ~draw_static_las_t ();
00023 void update_data (double bot_pos_[3]);
00024 void display (double bot_pos[3]);
00025 void toggle_display ();
00026 void flush_buffer ();
00027 void init_data ();
00028 void get_origin (double origin_[3]);
00029 private:
00030 double min_x, min_y, min_z, max_x, max_y, max_z;
00031 struct point_t
00032 {
00033 float x, y, z;
00034 unsigned char r, g, b;
00035 };
00036
00037 #define DL_MAX_SIZE 500000
00038
00039 std::vector<point_t> vertices;
00040 #ifdef VR_JUGGLER
00041 vrj::GlContextData<GLuint> las_listname;
00042
00043 #else
00044 GLuint las_listname;
00045 #endif
00046 char m_static_file[100];
00047 unsigned m_num_dl;
00048 unsigned *m_dl_indices;
00049 };
00050 }
00051 #endif