]>
Commit | Line | Data |
---|---|---|
d810d0de | 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 * | |
51346b82 | 7 | * full copyright notice. * |
d810d0de | 8 | **************************************************************************/ |
fd31e9de | 9 | |
a282bf09 | 10 | #ifndef ALIEVE_TRDModule_H |
11 | #define ALIEVE_TRDModule_H | |
12 | ||
13 | ///////////////////////////////////////////////////////////////////////// | |
14 | // | |
15 | // - AliEVE implementation - | |
16 | // The common structure of a TRD module (SM, Stack or Chamber) | |
d810d0de | 17 | // - AliEveTRDModule - structure of TRD module for visualisation |
18 | // - AliEveTRDModuleEditor - UI | |
a282bf09 | 19 | // |
20 | // by A.Bercuci (A.Bercuci@gsi.de) Fri Oct 27 2006 | |
21 | /////////////////////////////////////////////////////////////////////// | |
22 | ||
23 | #ifndef ROOT_TNamed | |
24 | #include <TNamed.h> | |
25 | #endif | |
26 | ||
27 | #ifndef ROOT_TGedFrame | |
28 | #include <TGedFrame.h> | |
29 | #endif | |
30 | ||
31 | class TObject; | |
32 | class TGWindow; | |
33 | class TGCheckButton; | |
34 | class TGNumberEntry; | |
35 | class TGColorSelect; | |
36 | ||
a282bf09 | 37 | |
fd31e9de | 38 | class AliEveTRDModule : public TNamed |
39 | { | |
40 | friend class AliEveTRDModuleEditor; | |
41 | friend class AliEveTRDNode; | |
42 | friend class AliEveTRDChamber; | |
43 | ||
44 | private: | |
45 | AliEveTRDModule(const AliEveTRDModule&); // Not implemented | |
46 | AliEveTRDModule& operator=(const AliEveTRDModule&); // Not implemented | |
47 | ||
48 | public: | |
49 | AliEveTRDModule(const char *typ="XXX", Int_t id=0); | |
50 | virtual ~AliEveTRDModule() {} | |
51 | ||
52 | virtual Bool_t GetDigitsBox(){return fDigitsBox;} | |
53 | virtual Bool_t GetDigitsLog(){return fDigitsLog;} | |
54 | virtual UShort_t GetDigitsThreshold(){return fDigitsThreshold;} | |
55 | virtual Int_t GetID(){return fDet;} | |
56 | virtual void Paint(Option_t* option="")=0; | |
57 | virtual void Reset()=0; | |
58 | ||
59 | protected: | |
60 | // UI section | |
61 | Bool_t fLoadHits, fRnrHits; | |
62 | Bool_t fLoadDigits, fRnrDigits, fDigitsLog, fDigitsBox; | |
63 | Bool_t fDigitsNeedRecompute; | |
64 | ||
65 | Bool_t fLoadRecPoints, fRnrRecPoints; | |
66 | Bool_t fLoadTracklets, fRnrTracklets; | |
67 | ||
68 | Int_t fDet; // detector number | |
69 | UShort_t fDigitsThreshold; // digits threshold | |
70 | ||
71 | ClassDef(AliEveTRDModule,1); // Structure holder for TRD chamber | |
72 | }; | |
73 | ||
74 | ||
75 | class AliEveTRDModuleEditor : public TGedFrame | |
76 | { | |
77 | private: | |
78 | AliEveTRDModuleEditor(const AliEveTRDModuleEditor&); // Not implemented | |
79 | AliEveTRDModuleEditor& operator=(const AliEveTRDModuleEditor&); // Not implemented | |
80 | ||
81 | public: | |
82 | AliEveTRDModuleEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, | |
83 | UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground()); | |
84 | ~AliEveTRDModuleEditor(); | |
85 | ||
86 | virtual void SetModel(TObject* obj); | |
87 | ||
88 | void ModifyDigitsView(); | |
89 | void SetThreshold(Long_t thres); | |
90 | void UpdateChamber(); | |
91 | void UpdateClusters(Pixel_t); | |
92 | void UpdateHits(Pixel_t); | |
93 | ||
94 | protected: | |
95 | AliEveTRDModule* fM; | |
96 | ||
97 | private: | |
98 | TGCheckButton *fDisplayHits; | |
99 | TGColorSelect *fHitsColor; | |
100 | TGCheckButton *fDisplayDigits, *fToggleLog, *fToggleBox, *fThreshold; | |
101 | TGNumberEntry *fThresValue; | |
102 | TGCheckButton *fDisplayClusters; | |
103 | TGColorSelect *fClustersColor; | |
104 | TGCheckButton *fDisplayTracks; | |
105 | ||
106 | ClassDef(AliEveTRDModuleEditor,1); // Editor for AliEveTRDModule | |
107 | }; | |
108 | ||
a282bf09 | 109 | #endif |