#ifndef ROOT_TGLViewerBase
#define ROOT_TGLViewerBase
#include <TObject.h>
#include "TGLLockable.h"
#include <TGLBoundingBox.h>
#include <list>
#include <vector>
class TGLSceneBase;
class TGLSceneInfo;
class TGLCamera;
class TGLClip;
class TGLRnrCtx;
class TGLSelectRecord;
class TGLOvlSelectRecord;
class TGLOverlayElement;
class TGLViewerBase : public TGLLockable
{
private:
TGLViewerBase(const TGLViewerBase&);
TGLViewerBase& operator=(const TGLViewerBase&);
protected:
typedef std::list<TGLSceneInfo*> SceneInfoList_t;
typedef std::list<TGLSceneInfo*>::iterator SceneInfoList_i;
typedef std::vector<TGLSceneInfo*> SceneInfoVec_t;
typedef std::vector<TGLSceneInfo*>::iterator SceneInfoVec_i;
typedef std::vector<TGLOverlayElement*> OverlayElmVec_t;
SceneInfoList_i FindScene(TGLSceneBase* scene);
typedef void (TGLSceneBase::* SubRender_foo) (TGLRnrCtx &);
void SubRenderScenes(SubRender_foo render_foo);
TGLRnrCtx *fRnrCtx;
TGLCamera *fCamera;
TGLClip *fClip;
Short_t fLOD;
Short_t fStyle;
Bool_t fResetSceneInfosOnRender;
Bool_t fChanged;
SceneInfoList_t fScenes;
SceneInfoVec_t fVisScenes;
TGLBoundingBox fOverallBoundingBox;
OverlayElmVec_t fOverlay;
public:
TGLViewerBase();
virtual ~TGLViewerBase();
virtual const char* LockIdStr() const;
TGLSceneInfo* AddScene(TGLSceneBase* scene);
void RemoveScene(TGLSceneBase* scene);
void RemoveAllScenes();
void SceneDestructing(TGLSceneBase* scene);
TGLSceneInfo* GetSceneInfo(TGLSceneBase* scene);
void AddOverlayElement(TGLOverlayElement* el);
void RemoveOverlayElement(TGLOverlayElement* el);
TGLClip* Clip() const { return fClip; }
void SetClip(TGLClip *p) { fClip = p; }
Short_t LOD() const { return fLOD; }
void SetLOD(Short_t lod) { fLOD = lod; }
Short_t Style() const { return fStyle; }
void SetStyle(Short_t st) { fStyle = st; }
virtual void ResetSceneInfos();
virtual void Changed() { fChanged = kTRUE; }
virtual Bool_t IsChanged() const { return fChanged; }
virtual void MergeSceneBBoxes(TGLBoundingBox& bbox);
virtual void PreRender();
virtual void Render();
virtual void RenderNonSelected();
virtual void RenderSelected();
virtual void RenderOverlay();
virtual void PostRender();
virtual void PreRenderOverlaySelection();
virtual void PostRenderOverlaySelection();
Bool_t ResolveSelectRecord(TGLSelectRecord& rec, Int_t recIdx);
Bool_t FindClosestRecord (TGLSelectRecord& rec, Int_t& recIdx);
Bool_t FindClosestOpaqueRecord(TGLSelectRecord& rec, Int_t& recIdx);
Bool_t FindClosestOverlayRecord(TGLOvlSelectRecord& rec, Int_t& recIdx);
TGLRnrCtx* GetRnrCtx() const { return fRnrCtx;}
ClassDef(TGLViewerBase, 0)
};
#endif
Last change: Wed Jun 25 08:41:34 2008
Last generated: 2008-06-25 08:41
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.