Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

Scene.h

Go to the documentation of this file.
00001 //     $Id: Scene.h,v 1.1.1.1 2001/01/04 01:01:11 burnett Exp $
00002 //  Author: Toby Burnett
00003 //
00004 
00005 #ifndef SCENE_H
00006 #define SCENE_H
00007 
00008 #include "gui/DisplayRep.h"
00009 #include <list>
00010 
00011 namespace gui {
00012 class ViewPort;
00013 
00014 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00015 class Scene 
00016 {
00017 public:
00018     Scene();
00019     ~Scene();
00020     
00021   
00022     void add(DisplayRep*);
00023     // add to the rep to the list to display 
00024         
00025     void remove(DisplayRep*);
00026     // remove from the list
00027 
00028     void draw(ViewPort *v);
00029     // have the members of the list draw themselves onto the ViewPort
00030 
00031     void clear();
00032     // send clear message to all attached reps
00033 
00034     void update();
00035     // ask all representations to update
00036 
00037     void enable();
00038     // enable the display
00039 
00040     void disable();
00041     // disable the display
00042 
00043     bool enabled()const;
00044     // return enabled status
00045 
00046 
00047 private:
00048     typedef std::list<DisplayRep*> RepList;
00049     RepList m_replist;  // list of Reps
00050     
00051     bool    m_enabled;  // can disable display 
00052 
00053 };
00055 inline bool Scene::enabled()const{return m_enabled;}
00056 
00057 } // namespaced gui
00058 
00059 #endif //SCENE_H
00060 
00061 
00062 
00063 
00064 
00065 

Generated at Mon Nov 26 18:18:11 2001 by doxygen1.2.3 written by Dimitri van Heesch, © 1997-2000