ROOT logo
ROOT » GRAF3D » GL » TGLSceneInfo

class TGLSceneInfo

 TGLSceneInfo

 Base class for extended scene context.

 Scenes can be shared among several viewers and each scene needs to
 cache some viewer/camera/clipping specific state => this is a
 storage class for this data.

 Sub-classes of TGLSceneBase can override the virtual
 CreateSceneInfo() method and in it instantiate a sub-class of
 TGLSceneInfo containing the needed information. See TGLScene and
 inner class SceneInfo; note that some casting is needed in actual
 methods as TGLRnrCtx holds the base-class pointer.

Function Members (Methods)

public:
TGLSceneInfo(TGLViewerBase* view = 0, TGLSceneBase* scene = 0)
virtual~TGLSceneInfo()
UInt_tCameraStamp() const
static TClass*Class()
TGLClip*Clip() const
Char_tClipMode() const
voidClipMode(Char_t m)
vector<TGLPlane>&ClipPlanes()
UInt_tClipStamp() const
vector<TGLPlane>&FrustumPlanes()
Bool_tGetActive() const
TGLSceneBase*GetScene() const
const TGLBoundingBox&GetTransformedBBox()
TGLViewerBase*GetViewer() const
Bool_tHasUpdateTimeouted() const
voidInClip(Bool_t c)
voidInFrustum(Bool_t f)
virtual TClass*IsA() const
Bool_tIsInClip() const
Bool_tIsInFrustum() const
Bool_tIsVisible() const
TGLCamera*LastCamera() const
TGLClip*LastClip() const
Short_tLastLOD() const
Float_tLastOLLineW() const
Short_tLastStyle() const
Float_tLastWFLineW() const
Short_tLOD() const
Float_tOLLineW() const
TGLSceneBase&RefScene() const
TGLViewerBase&RefViewer() const
voidResetCameraStamp()
voidResetClipStamp()
voidResetSceneStamp()
voidResetUpdateTimeouted()
UInt_tSceneStamp() const
voidSetActive(Bool_t a)
voidSetCameraStamp(UInt_t ts)
voidSetClip(TGLClip* p)
voidSetClipStamp(UInt_t ts)
voidSetLastCamera(TGLCamera* p)
voidSetLastClip(TGLClip* p)
voidSetLastLOD(Short_t ld)
voidSetLastOLLineW(Float_t w)
voidSetLastStyle(Short_t st)
voidSetLastWFLineW(Float_t w)
voidSetLOD(Short_t lod)
voidSetOLLineW(Float_t w)
voidSetSceneStamp(UInt_t ts)
virtual voidSetSceneTrans(TGLMatrix&)
voidSetStyle(Short_t st)
voidSetupTransformsAndBBox()
voidSetWFLineW(Float_t w)
Bool_tShouldClip() const
virtual voidShowMembers(TMemberInspector&)
virtual voidStreamer(TBuffer&)
voidStreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
Short_tStyle() const
voidUpdateTimeouted()
Bool_tViewCheck() const
voidViewCheck(Bool_t c)
Float_tWFLineW() const

Data Members

public:
enum EClipTest { kClipNone
kClipOutside
kClipInside
};
protected:
Bool_tfActiveShow fScene in fViewer
UInt_tfCameraStampCamera's time-stamp on last update.
TGLClip*fClipOptional override of clipping-plane
Char_tfClipModeClipping mode, can be disbled.
TGLPlaneSet_tfClipPlanesClipping planes from clip-object; which planes are kept depends on inside/outside mode.
UInt_tfClipStampClip's time-stamp on last update.
TGLPlaneSet_tfFrustumPlanesClipping planes defined by frustum; only those intersecting the scene volume are kept.
Bool_tfInClipIs scene contained within clipping-volume.
Bool_tfInFrustumIs scene intersecting view-frustum.
Short_tfLODOptional override of scene lod
TGLCamera*fLastCameraLast camera used.
TGLClip*fLastClipLast combined viewer/scene clip (set in scene::update)
Short_tfLastLODLast combined viewer/scene lod (set in scene::lodify-scene-info).
Float_tfLastOLLineWLast combined viewer/scene outline line-width (set in scene::pre-draw).
Short_tfLastStyleLast combined viewer/scene style (set in scene::pre-draw).
Float_tfLastWFLineWLast combined viewer/scene wire-frame line-width (set in scene::pre-draw).
Float_tfOLLineWOptional override of scene outline line-width
TGLSceneBase*fScene
UInt_tfSceneStampScene's time-stamp on last update.
Short_tfStyleOptional override of scene style
TGLBoundingBoxfTransformedBBox
Bool_tfUpdateTimeoutedSet if update was interrupted.
Bool_tfViewCheckViewer side check if render is necessary.
TGLViewerBase*fViewer
Float_tfWFLineWOptional override of scene wire-frame line-width

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

TGLSceneInfo(TGLViewerBase* view = 0, TGLSceneBase* scene = 0)
 Default constructor.
void SetActive(Bool_t a)
 Set active state of the scene, mark viewer as changed.
void SetupTransformsAndBBox()
 Combine information from scene, scene-info and camera (should be
 optional) into transformation matrices.

 Transform scene bounding box using this transformation.
TGLSceneInfo(const TGLSceneInfo& )
TGLSceneInfo& operator=(const TGLSceneInfo& )
virtual ~TGLSceneInfo()
{}
TGLViewerBase * GetViewer() const
{ return fViewer; }
TGLViewerBase & RefViewer() const
{ return *fViewer; }
TGLSceneBase * GetScene() const
{ return fScene; }
TGLSceneBase & RefScene() const
{ return *fScene; }
Bool_t GetActive() const
{ return fActive; }
const TGLBoundingBox& GetTransformedBBox()
{ return fTransformedBBox; }
void SetSceneTrans(TGLMatrix& )
Bool_t ViewCheck() const
{ return fViewCheck; }
void ViewCheck(Bool_t c)
{ fViewCheck = c; }
Bool_t IsInFrustum() const
{ return fInFrustum; }
void InFrustum(Bool_t f)
{ fInFrustum = f; }
Bool_t IsInClip() const
{ return fInClip; }
void InClip(Bool_t c)
{ fInClip = c; }
Char_t ClipMode() const
{ return fClipMode; }
void ClipMode(Char_t m)
{ fClipMode = m; }
Bool_t ShouldClip() const
{ return fClipMode != kClipNone; }
Bool_t IsVisible() const
{ return fInFrustum && fInClip; }
std::vector<TGLPlane>& FrustumPlanes()
{ return fFrustumPlanes; }
std::vector<TGLPlane>& ClipPlanes()
{ return fClipPlanes; }
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; }
Float_t WFLineW() const
{ return fWFLineW; }
void SetWFLineW(Float_t w)
{ fWFLineW = w; }
Float_t OLLineW() const
{ return fOLLineW; }
void SetOLLineW(Float_t w)
{ fOLLineW = w; }
void SetClip(TGLClip* p)
{ fClip = p; }
Short_t LastLOD() const
{ return fLastLOD; }
void SetLastLOD(Short_t ld)
{ fLastLOD = ld; }
Short_t LastStyle() const
{ return fLastStyle; }
void SetLastStyle(Short_t st)
{ fLastStyle = st; }
Float_t LastWFLineW() const
{ return fLastWFLineW; }
void SetLastWFLineW(Float_t w)
{ fLastWFLineW = w; }
Float_t LastOLLineW() const
{ return fLastOLLineW; }
void SetLastOLLineW(Float_t w)
{ fLastOLLineW = w; }
TGLClip* LastClip() const
{ return fLastClip; }
void SetLastClip(TGLClip* p)
{ fLastClip = p; }
TGLCamera* LastCamera() const
{ return fLastCamera; }
void SetLastCamera(TGLCamera* p)
{ fLastCamera = p; }
UInt_t SceneStamp() const
{ return fSceneStamp; }
void SetSceneStamp(UInt_t ts)
{ fSceneStamp = ts; }
void ResetSceneStamp()
{ fSceneStamp = 0; }
UInt_t ClipStamp() const
{ return fClipStamp; }
void SetClipStamp(UInt_t ts)
{ fClipStamp = ts; }
void ResetClipStamp()
{ fClipStamp = 0; }
UInt_t CameraStamp() const
{ return fCameraStamp; }
void SetCameraStamp(UInt_t ts)
{ fCameraStamp = ts; }
void ResetCameraStamp()
{ fCameraStamp = 0; }
Bool_t HasUpdateTimeouted() const
{ return fUpdateTimeouted; }
void UpdateTimeouted()
void ResetUpdateTimeouted()