ROOT
6.07/01
Reference Guide
|
Abstract clipping shape - derives from TGLPhysicalShape Adds clip mode (inside/outside) and pure virtual method to approximate shape as set of planes.
This plane set is used to perform interactive clipping using OpenGL clip planes.
Public Types | |
enum | EMode { kOutside, kInside } |
enum | EType { kClipNone = 0, kClipPlane, kClipBox } |
Public Types inherited from TGLPhysicalShape | |
enum | EManip { kTranslateX = 1 << 0, kTranslateY = 1 << 1, kTranslateZ = 1 << 2, kTranslateAll = kTranslateX | kTranslateY | kTranslateZ, kScaleX = 1 << 3, kScaleY = 1 << 4, kScaleZ = 1 << 5, kScaleAll = kScaleX | kScaleY | kScaleZ, kRotateX = 1 << 6, kRotateY = 1 << 7, kRotateZ = 1 << 8, kRotateAll = kRotateX | kRotateY | kRotateZ, kManipAll = kTranslateAll | kScaleAll | kRotateAll } |
Public Member Functions | |
TGLClip (const TGLLogicalShape &logical, const TGLMatrix &transform, const float color[4]) | |
Construct a stand-alone physical clipping object. More... | |
virtual | ~TGLClip () |
Destroy clip object. More... | |
virtual void | Modified () |
virtual void | Setup (const TGLBoundingBox &bbox)=0 |
virtual void | Setup (const TGLVector3 &, const TGLVector3 &) |
Setup the clipping object with two vectors. More... | |
EMode | GetMode () const |
void | SetMode (EMode mode) |
UInt_t | TimeStamp () const |
void | IncTimeStamp () |
Bool_t | IsValid () const |
void | Invalidate () |
virtual void | Draw (TGLRnrCtx &rnrCtx) const |
Draw out clipping object with blending and back + front filling. More... | |
virtual void | PlaneSet (TGLPlaneSet_t &set) const =0 |
ClassDef (TGLClip, 0) | |
Public Member Functions inherited from TGLPhysicalShape | |
TGLPhysicalShape (UInt_t ID, const TGLLogicalShape &logicalShape, const TGLMatrix &transform, Bool_t invertedWind, const Float_t rgba[4]) | |
TGLPhysicalShape (UInt_t ID, const TGLLogicalShape &logicalShape, const double *transform, Bool_t invertedWind, const Float_t rgba[4]) | |
Construct a physical shape using arguments: More... | |
virtual | ~TGLPhysicalShape () |
Destroy the physical shape. More... | |
void | AddReference (TGLPShapeRef *ref) |
Add reference ref. More... | |
void | RemoveReference (TGLPShapeRef *ref) |
Remove reference ref. More... | |
UInt_t | ID () const |
const TGLBoundingBox & | BoundingBox () const |
virtual void | CalculateShapeLOD (TGLRnrCtx &rnrCtx, Float_t &pixSize, Short_t &shapeLOD) const |
Calculate shape-lod, suitable for use under projection defined by 'rnrCtx', taking account of which local axes of the shape support LOD adjustment, and the global 'sceneFlags' passed. More... | |
virtual void | QuantizeShapeLOD (Short_t shapeLOD, Short_t combiLOD, Short_t &quantLOD) const |
Factor in scene/vierer LOD and Quantize ... More... | |
void | SetupGLColors (TGLRnrCtx &rnrCtx, const Float_t *color=0) const |
Setup colors - avoid setting things not required for current draw flags. More... | |
const TGLLogicalShape * | GetLogical () const |
const TGLPhysicalShape * | GetNextPhysical () const |
EManip | GetManip () const |
void | SetManip (EManip manip) |
void | Modified () |
Call this after modifying the physical so that the information can be propagated to the object referencing it. More... | |
Bool_t | IsModified () const |
Bool_t | IsSelected () const |
UChar_t | GetSelected () const |
void | Select (UChar_t select) |
const Float_t * | Color () const |
Bool_t | IsTransparent () const |
Bool_t | IsInvisible () const |
void | SetColor (const Float_t rgba[17]) |
Set full color attributes - see OpenGL material documentation for full description. More... | |
void | SetColorOnFamily (const Float_t rgba[17]) |
Set full color attributes to all physicals sharing the same logical with this object. More... | |
void | SetDiffuseColor (const Float_t rgba[4]) |
Set color from ROOT color index and transparency [0,100]. More... | |
void | SetDiffuseColor (const UChar_t rgba[4]) |
Set color from RGBA quadruplet. More... | |
void | SetDiffuseColor (Color_t ci, UChar_t transparency) |
Set color from standard ROOT representation, that is color index. More... | |
TGLVector3 | GetScale () const |
TGLVertex3 | GetTranslation () const |
void | SetTransform (const TGLMatrix &transform) |
void | SetTransform (const Double_t vals[16]) |
void | SetTranslation (const TGLVertex3 &translation) |
void | Translate (const TGLVector3 &vect) |
void | Scale (const TGLVector3 &scale) |
void | Rotate (const TGLVertex3 &pivot, const TGLVector3 &axis, Double_t angle) |
void | InvokeContextMenu (TContextMenu &menu, UInt_t x, UInt_t y) const |
Request creation of context menu on shape, attached to 'menu' at screen position 'x' 'y'. More... | |
Protected Attributes | |
EMode | fMode |
UInt_t | fTimeStamp |
Bool_t | fValid |
#include <TGLClip.h>
enum TGLClip::EMode |
enum TGLClip::EType |
TGLClip::TGLClip | ( | const TGLLogicalShape & | logical, |
const TGLMatrix & | transform, | ||
const float | color[4] | ||
) |
Construct a stand-alone physical clipping object.
Definition at line 89 of file TGLClip.cxx.
|
virtual |
Destroy clip object.
Definition at line 101 of file TGLClip.cxx.
TGLClip::ClassDef | ( | TGLClip | , |
0 | |||
) |
Draw out clipping object with blending and back + front filling.
Some clip objects are single face which we want to see both sides of.
Reimplemented from TGLPhysicalShape.
Definition at line 120 of file TGLClip.cxx.
Referenced by TGLClipSet::Render().
|
inline |
Definition at line 60 of file TGLClip.h.
Referenced by TGLClipSetSubEditor::SetModel(), and TGLSceneBase::UpdateSceneInfo().
|
inline |
Definition at line 64 of file TGLClip.h.
Referenced by Modified(), TGLClipPlane::Set(), TGLClipPlane::Setup(), and TGLClipBox::Setup().
|
inline |
Definition at line 67 of file TGLClip.h.
Referenced by TGLClipSet::InvalidateClips(), and TGLClipSet::InvalidateCurrentClip().
|
inline |
Definition at line 66 of file TGLClip.h.
Referenced by TGLClipSet::GetClipState(), and TGLClipSet::SetupCurrentClipIfInvalid().
|
pure virtual |
Implemented in TGLClipBox, and TGLClipPlane.
Referenced by TGLClipSet::FillPlaneSet(), and TGLSceneBase::UpdateSceneInfo().
Definition at line 61 of file TGLClip.h.
Referenced by TGLClipSetSubEditor::UpdateViewerClip().
|
pure virtual |
Implemented in TGLClipBox, and TGLClipPlane.
Referenced by TGLViewerBase::SetupClipObject(), TGLClipSet::SetupCurrentClip(), and TGLClipSet::SetupCurrentClipIfInvalid().
|
virtual |
Setup the clipping object with two vectors.
The interpretation of the two is different for plane and box clipping objects.
Reimplemented in TGLClipBox, and TGLClipPlane.
Definition at line 110 of file TGLClip.cxx.
|
inline |
Definition at line 63 of file TGLClip.h.
Referenced by TGLSceneBase::PreDraw(), and TGLSceneBase::UpdateSceneInfo().
|
protected |
|
protected |
Definition at line 48 of file TGLClip.h.
Referenced by IncTimeStamp(), SetMode(), and TimeStamp().
|
protected |
Definition at line 49 of file TGLClip.h.
Referenced by Invalidate(), IsValid(), TGLClipPlane::Set(), TGLClipPlane::Setup(), TGLClipBox::Setup(), and TGLClipPlane::TGLClipPlane().