Logo ROOT  
Reference Guide
REveViewer.hxx
Go to the documentation of this file.
1// @(#)root/eve7:$Id$
2// Authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007, 2018
3
4/*************************************************************************
5 * Copyright (C) 1995-2019, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#ifndef ROOT7_REveViewer
13#define ROOT7_REveViewer
14
15#include <ROOT/REveElement.hxx>
16
17namespace ROOT {
18namespace Experimental {
19
20class REveScene;
21
22////////////////////////////////////////////////////////////////////////////////
23/// REveViewer
24/// Reve representation of TGLViewer.
25////////////////////////////////////////////////////////////////////////////////
26
27class REveViewer : public REveElement
28{
29public:
31
32private:
33 REveViewer(const REveViewer&) = delete;
34 REveViewer& operator=(const REveViewer&) = delete;
35
37
38public:
39 REveViewer(const std::string &n="REveViewer", const std::string &t="");
40 virtual ~REveViewer();
41
42 void Redraw(Bool_t resetCameras=kFALSE);
43
44 virtual void AddScene(REveScene* scene);
45 // XXX Missing RemoveScene() ????
46
49
50 void RemoveElementLocal(REveElement *el) override;
51 void RemoveElementsLocal() override;
52 Int_t WriteCoreJson(nlohmann::json &cj, Int_t rnr_offset) override;
53};
54
55
56////////////////////////////////////////////////////////////////////////////////
57/// REveViewerList
58/// List of Viewers providing common operations on REveViewer collections.
59////////////////////////////////////////////////////////////////////////////////
60
62{
63private:
66
67protected:
69
72
73 void HandleTooltip();
74
75public:
76 REveViewerList(const std::string &n="REveViewerList", const std::string &t="");
77 virtual ~REveViewerList();
78
79 void AddElement(REveElement* el) override;
80 void RemoveElementLocal(REveElement* el) override;
81 void RemoveElementsLocal() override;
82
83 // --------------------------------
84
85 virtual void Connect();
86 virtual void Disconnect();
87
88 void RepaintChangedViewers(Bool_t resetCameras, Bool_t dropLogicals);
89 void RepaintAllViewers(Bool_t resetCameras, Bool_t dropLogicals);
90 void DeleteAnnotations();
91
92 void SceneDestructing(REveScene* scene);
93
94 // --------------------------------
95
96 void OnMouseOver(TObject* obj, UInt_t state);
97 void OnReMouseOver(TObject* obj, UInt_t state);
98 void OnUnMouseOver(TObject* obj, UInt_t state);
99 void OnClicked(TObject *obj, UInt_t button, UInt_t state);
100 void OnReClicked(TObject *obj, UInt_t button, UInt_t state);
101 void OnUnClicked(TObject *obj, UInt_t button, UInt_t state);
102
103 // --------------------------------
104
107
110
112 void SwitchColorSet();
113};
114
115} // namespace Experimental
116} // namespace ROOT
117
118#endif
#define b(i)
Definition: RSha256.hxx:100
int Int_t
Definition: RtypesCore.h:45
unsigned int UInt_t
Definition: RtypesCore.h:46
const Bool_t kFALSE
Definition: RtypesCore.h:101
bool Bool_t
Definition: RtypesCore.h:63
float Float_t
Definition: RtypesCore.h:57
Eve representation of TGLScene.
REveViewerList List of Viewers providing common operations on REveViewer collections.
Definition: REveViewer.hxx:62
void RemoveElementsLocal() override
Decompoundofy children, call base-class version.
Definition: REveViewer.cxx:164
void OnUnClicked(TObject *obj, UInt_t button, UInt_t state)
Slot for global TGLViewer::UnClicked().
Definition: REveViewer.cxx:421
REveViewerList & operator=(const REveViewerList &)=delete
void AddElement(REveElement *el) override
Call base-class implementation.
Definition: REveViewer.cxx:145
void OnReClicked(TObject *obj, UInt_t button, UInt_t state)
Slot for global TGLViewer::ReClicked().
Definition: REveViewer.cxx:404
void OnClicked(TObject *obj, UInt_t button, UInt_t state)
Slot for global TGLViewer::Clicked().
Definition: REveViewer.cxx:387
void HandleTooltip()
Show / hide tooltip for various MouseOver events.
Definition: REveViewer.cxx:290
void SceneDestructing(REveScene *scene)
Callback done from a REveScene destructor allowing proper removal of the scene from affected viewers.
Definition: REveViewer.cxx:275
void OnMouseOver(TObject *obj, UInt_t state)
Slot for global TGLViewer::MouseOver() signal.
Definition: REveViewer.cxx:321
void SetColorBrightness(Float_t b)
Set color brightness.
Definition: REveViewer.cxx:432
void RepaintAllViewers(Bool_t resetCameras, Bool_t dropLogicals)
Repaint all viewers.
Definition: REveViewer.cxx:246
void OnUnMouseOver(TObject *obj, UInt_t state)
Slot for global TGLViewer::UnMouseOver().
Definition: REveViewer.cxx:365
virtual void Disconnect()
Disconnect from TGLViewer class-signals.
Definition: REveViewer.cxx:203
void RepaintChangedViewers(Bool_t resetCameras, Bool_t dropLogicals)
Repaint viewers that are tagged as changed.
Definition: REveViewer.cxx:227
void OnReMouseOver(TObject *obj, UInt_t state)
Slot for global TGLViewer::ReMouseOver().
Definition: REveViewer.cxx:343
virtual ~REveViewerList()
Destructor.
Definition: REveViewer.cxx:135
void SwitchColorSet()
Switch background color.
Definition: REveViewer.cxx:440
REveViewerList(const REveViewerList &)=delete
virtual void Connect()
Connect to TGLViewer class-signals.
Definition: REveViewer.cxx:179
void DeleteAnnotations()
Delete annotations from all viewers.
Definition: REveViewer.cxx:263
void RemoveElementLocal(REveElement *el) override
Decompoundofy el, call base-class version.
Definition: REveViewer.cxx:153
REveViewer Reve representation of TGLViewer.
Definition: REveViewer.hxx:28
void RemoveElementLocal(REveElement *el) override
Remove element 'el' from the list of children and also remove appropriate GLScene from GLViewer's lis...
Definition: REveViewer.cxx:78
void RemoveElementsLocal() override
Remove all children, forwarded to GLViewer.
Definition: REveViewer.cxx:89
virtual ~REveViewer()
Destructor.
Definition: REveViewer.cxx:41
REveViewer(const REveViewer &)=delete
void SetCameraType(ECameraType t)
Definition: REveViewer.hxx:47
REveViewer & operator=(const REveViewer &)=delete
Int_t WriteCoreJson(nlohmann::json &cj, Int_t rnr_offset) override
Stream Camera Info.
Definition: REveViewer.cxx:105
ECameraType GetCameraType() const
Definition: REveViewer.hxx:48
void Redraw(Bool_t resetCameras=kFALSE)
Redraw viewer immediately.
Definition: REveViewer.cxx:47
virtual void AddScene(REveScene *scene)
Add 'scene' to the list of scenes.
Definition: REveViewer.cxx:56
Mother of all ROOT objects.
Definition: TObject.h:37
Double_t x[n]
Definition: legend1.C:17
const Int_t n
Definition: legend1.C:16
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...