]> git.uio.no Git - u/mrichter/AliRoot.git/blame - EVE/EveDet/AliEveTRDLoader.h
Merge changes from branches/dev/EVE. This branch was following development in ROOT...
[u/mrichter/AliRoot.git] / EVE / EveDet / AliEveTRDLoader.h
CommitLineData
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 **************************************************************************/
a15e6d7d 9#ifndef AliEveTRDLoader_H
10#define AliEveTRDLoader_H
a282bf09 11
12////////////////////////////////////////////////////////////////////////
a15e6d7d 13// - ALIEVE implementation -
51346b82 14// Loader for the TRD detector - base class
d810d0de 15// - AliEveTRDLoader - loader of TRD data (simulation + measured)
16// - AliEveTRDLoaderEditor - UI
a282bf09 17//
18// by A.Bercuci (A.Bercuci@gsi.de) Fri Oct 27 2006
19////////////////////////////////////////////////////////////////////////
20
84aff7a4 21#include <TEveElement.h>
a282bf09 22#include <TGedFrame.h>
84aff7a4 23#include <TString.h>
a282bf09 24
a282bf09 25class AliTRDv1;
14217b5f 26class AliTRDgeometry;
a282bf09 27
a282bf09 28class TGNumberEntry;
29class TGColorSelect;
30class TGTextEntry;
31class TTree;
84aff7a4 32
33class TEveGValuator;
34
fd31e9de 35class AliEveTRDChamber;
36class AliEveTRDLoaderManager;
37
38class AliEveTRDLoader : public TEveElementList
39{
40 friend class AliEveTRDLoaderEditor;
41
42private:
43 AliEveTRDLoader(const AliEveTRDLoader&); // Not implemented
44 AliEveTRDLoader& operator=(const AliEveTRDLoader&); // Not implemented
45
46public:
47 enum TRDDataTypes {
48 kHits = 0,
49 kDigits = 1,
50 kClusters = 2,
51 kTracks = 3,
52 kRawRoot = 4,
53 kRawData = 5
54 };
55
56public:
57 AliEveTRDLoader(const Text_t* n="AliEveTRDLoader", const Text_t* t=0);
a15e6d7d 58 virtual ~AliEveTRDLoader() {}
59
fd31e9de 60 virtual void Paint(Option_t *option="");
61 virtual void SetDataType(TRDDataTypes type);
62
63protected:
64 virtual void AddChambers(int sm=-1, int stk=-1, int ly=-1);
65 virtual AliEveTRDChamber* GetChamber(int d);
66 virtual Bool_t GoToEvent(int ev);
67 virtual Bool_t LoadClusters(TTree *tC);
68 virtual Bool_t LoadDigits(TTree *tD);
69 virtual Bool_t LoadTracklets(TTree *tT);
70 virtual Bool_t Open(const char *file, const char *dir = ".");
71 virtual void Unload();
72
73protected:
74 Bool_t fLoadHits, fLoadDigits, fLoadClusters, fLoadTracks; // flags for data-loading
75 Int_t fSM, fStack, fLy; // supermodule, stack, layer
76 TString fFilename; // name of data file
77 TString fDir; // data directory
78 Int_t fEvent; // current event to be displayed
79
fd31e9de 80 AliTRDv1 *fTRD; // the TRD detector
81 AliTRDgeometry *fGeo; // the TRD geometry
82
a15e6d7d 83 ClassDef(AliEveTRDLoader, 1); // Alieve Loader class for the TRD detector.
fd31e9de 84};
85
86
87class AliEveTRDLoaderEditor : public TGedFrame
88{
89private:
90 AliEveTRDLoaderEditor(const AliEveTRDLoaderEditor&); // Not implemented
91 AliEveTRDLoaderEditor& operator=(const AliEveTRDLoaderEditor&); // Not implemented
92
93public:
94 AliEveTRDLoaderEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30,
95 UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground());
a15e6d7d 96 virtual ~AliEveTRDLoaderEditor() {}
fd31e9de 97
98 virtual void AddChambers();
99 virtual void FileOpen();
100 virtual void Load();
101 virtual void SetEvent(Double_t ev){fM->fEvent = (Int_t)ev;}
102 virtual void SetModel(TObject* obj);
103
104protected:
a15e6d7d 105 AliEveTRDLoader *fM; // Model object.
106 TGTextEntry *fFile; // File name weed.
107 TEveGValuator *fEvent; // Event no weed.
108 TEveGValuator *fSMNumber, *fStackNumber, *fPlaneNumber; // Detector id weeds.
fd31e9de 109
a15e6d7d 110 ClassDef(AliEveTRDLoaderEditor,1); // Editor for AliEveTRDLoader.
fd31e9de 111};
51346b82 112
a282bf09 113#endif