]>
Commit | Line | Data |
---|---|---|
1 | // $Id$ | |
2 | // Main authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007 | |
3 | ||
4 | /************************************************************************** | |
5 | * Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. * | |
6 | * See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for * | |
7 | * full copyright notice. * | |
8 | **************************************************************************/ | |
9 | ||
10 | #ifndef AliEveTRDModule_H | |
11 | #define AliEveTRDModule_H | |
12 | ||
13 | ///////////////////////////////////////////////////////////////////////// | |
14 | // | |
15 | // - AliEVE implementation - | |
16 | // The common structure of a TRD module (SM, Stack or Chamber) | |
17 | // - AliEveTRDModule - structure of TRD module for visualisation | |
18 | // - AliEveTRDModuleEditor - UI | |
19 | // | |
20 | // by A.Bercuci (A.Bercuci@gsi.de) Fri Oct 27 2006 | |
21 | /////////////////////////////////////////////////////////////////////// | |
22 | ||
23 | #include <TNamed.h> | |
24 | #include <TGedFrame.h> | |
25 | ||
26 | class TObject; | |
27 | class TGWindow; | |
28 | class TGCheckButton; | |
29 | class TGNumberEntry; | |
30 | class TGColorSelect; | |
31 | ||
32 | ||
33 | class AliEveTRDModule : public TNamed | |
34 | { | |
35 | friend class AliEveTRDModuleEditor; | |
36 | friend class AliEveTRDNode; | |
37 | friend class AliEveTRDChamber; | |
38 | ||
39 | public: | |
40 | AliEveTRDModule(const char *typ="XXX", Int_t id=0); | |
41 | virtual ~AliEveTRDModule() {} | |
42 | ||
43 | virtual Bool_t GetDigitsBox() const {return fDigitsBox;} | |
44 | virtual Bool_t GetDigitsLog() const {return fDigitsLog;} | |
45 | virtual UShort_t GetDigitsThreshold() const {return fDigitsThreshold;} | |
46 | virtual Int_t GetID() const {return fDet;} | |
47 | ||
48 | protected: | |
49 | // UI section | |
50 | Bool_t fLoadHits, fRnrHits, fLoadDigits; // What to load. | |
51 | Bool_t fRnrDigits, fDigitsLog, fDigitsBox; // What to show. | |
52 | Bool_t fDigitsNeedRecompute; // Need to recompute digits. | |
53 | ||
54 | Bool_t fLoadRecPoints, fRnrRecPoints; // What to do with recpoints. | |
55 | Bool_t fLoadTracklets, fRnrTracklets; // What to do with tracklets. | |
56 | ||
57 | Int_t fDet; // detector number | |
58 | UShort_t fDigitsThreshold; // digits threshold | |
59 | ||
60 | private: | |
61 | AliEveTRDModule(const AliEveTRDModule&); // Not implemented | |
62 | AliEveTRDModule& operator=(const AliEveTRDModule&); // Not implemented | |
63 | ||
64 | ClassDef(AliEveTRDModule, 0); // Structure holder for TRD chamber. | |
65 | }; | |
66 | ||
67 | ||
68 | class AliEveTRDModuleEditor : public TGedFrame | |
69 | { | |
70 | public: | |
71 | AliEveTRDModuleEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, | |
72 | UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); | |
73 | virtual ~AliEveTRDModuleEditor() {} | |
74 | ||
75 | virtual void SetModel(TObject* obj); | |
76 | ||
77 | void ModifyDigitsView(); | |
78 | void SetThreshold(Long_t thres); | |
79 | void UpdateChamber(); | |
80 | void UpdateClusters(Pixel_t); | |
81 | void UpdateHits(Pixel_t); | |
82 | ||
83 | protected: | |
84 | AliEveTRDModule* fM; // Model object. | |
85 | ||
86 | private: | |
87 | TGCheckButton *fDisplayHits; // Hit control. | |
88 | TGColorSelect *fHitsColor; // Hit color. | |
89 | TGCheckButton *fDisplayDigits, *fToggleLog, *fToggleBox, *fThreshold; // Display toggles. | |
90 | TGNumberEntry *fThresValue; // Threshold weed. | |
91 | TGCheckButton *fDisplayClusters; // Cluster control. | |
92 | TGColorSelect *fClustersColor; // Cluster color. | |
93 | TGCheckButton *fDisplayTracks; // Track control. | |
94 | ||
95 | AliEveTRDModuleEditor(const AliEveTRDModuleEditor&); // Not implemented | |
96 | AliEveTRDModuleEditor& operator=(const AliEveTRDModuleEditor&); // Not implemented | |
97 | ||
98 | ClassDef(AliEveTRDModuleEditor, 0); // Editor for AliEveTRDModule. | |
99 | }; | |
100 | ||
101 | #endif |