Code from MUON-dev joined
[u/mrichter/AliRoot.git] / MUON / AliMUONDisplay.h
CommitLineData
a9e2aefa 1#ifndef ALIMUONDISPLAY_H
2#define ALIMUONDISPLAY_H
3
3da30618 4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7/* $Id$ */
fe4da5cc 8
9//////////////////////////////////////////////////////////////////////////
10// //
11// AliDisplay //
12// //
13// Utility class to display ALice outline, tracks, hits,.. //
14// //
15//////////////////////////////////////////////////////////////////////////
16
17//#ifndef ROOT_TObject
18#include <TObject.h>
19//#endif
20#include "AliDisplay.h"
21
22class TCanvas;
23class TPad;
24class TList;
25class TSlider;
26class TButton;
27class TArc;
28
29const Int_t kMAXZOOM = 20;
30
a9e2aefa 31class AliMUONDisplay : /*splaypublic TObject,*/ public AliDisplay {
fe4da5cc 32public:
a9e2aefa 33 AliMUONDisplay();
34 AliMUONDisplay(Int_t size);
35 AliMUONDisplay(const AliMUONDisplay& display);
36
37 virtual ~AliMUONDisplay();
fe4da5cc 38 virtual void Clear(Option_t *option="");
39 virtual void DisplayButtons();
40 virtual void CreateColors();
41 virtual void DisplayColorScale();
42 virtual Int_t DistancetoPrimitive(Int_t px, Int_t py);
43 virtual void Draw(Option_t *option="");
44 virtual void DrawClusters();
45 virtual void DrawHits();
a897a37a 46 virtual void DrawCoG();
47 virtual void DrawCoG2();
a9e2aefa 48 virtual void DrawSegmentation();
fe4da5cc 49 virtual void DrawTitle(Option_t *option="");
50 virtual void DrawView(Float_t theta, Float_t phi, Float_t psi=0);
a9e2aefa 51 virtual void DrawP(Float_t,Float_t,Float_t,Float_t,Float_t,Int_t){}
fe4da5cc 52 virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py);
53 Int_t GetZoomMode() {return fZoomMode;}
54 Int_t GetChamber() {return fChamber;}
55 Int_t GetCathode() {return fCathode;}
56 virtual void LoadDigits(Int_t chamber, Int_t cathode);
57 virtual void LoadHits(Int_t chamber);
a897a37a 58 virtual void LoadCoG(Int_t chamber, Int_t cathode);
59 virtual void LoadCoG2(Int_t chamber, Int_t cathode);
fe4da5cc 60 TPad *Pad() {return fPad;}
61 TObjArray *Points() {return fPoints;}
62 TObjArray *Phits() {return fPhits;}
a897a37a 63 TObjArray *Rpoints() {return fRpoints;}
64 TObjArray *R2points() {return fR2points;}
65 TObjArray *Cpoints() {return fCpoints;}
fe4da5cc 66 virtual void Paint(Option_t *option="");
67 virtual void SetDrawClusters(Bool_t draw=kTRUE) {fDrawClusters=draw;} // *MENU*
a9e2aefa 68 virtual void SetChamberAndCathode(Int_t chamber=1, Int_t cathode=1); // *MENU*
69 virtual void SetDrawCoG(Bool_t draw=kTRUE) {fDrawCoG=draw;} // *MENU*
70 virtual void SetRange(Float_t rrange=250., Float_t zrange=1050.); // *MENU*
71 virtual void SetEvent(Int_t newevent=0); // *MENU*
a897a37a 72 virtual void SetView(Float_t theta=0, Float_t phi=-90, Float_t psi=0);
fe4da5cc 73 virtual void SetPickMode();
74 virtual void SetZoomMode();
75 virtual void ShowNextEvent(Int_t delta=1);
a9e2aefa 76 virtual void UnZoom(); // *MENU*
fe4da5cc 77 virtual void ResetPoints();
78 virtual void ResetPhits();
a897a37a 79 virtual void ResetRpoints();
80 virtual void ResetR2points();
81 virtual void ResetCpoints();
a9e2aefa 82 virtual void NextChamber(Int_t delta=1);
83 virtual void NextCathode();
84 void Trigger();
85 AliMUONDisplay& operator = (const AliMUONDisplay& rhs);
86
87
88private:
89 Int_t fEvent; // Current event
90 Int_t fChamber; // Current Chamber
91 Int_t fCathode; // Current cathode plane
92 Int_t fZoomMode; // =1 if in zoom mode
fe4da5cc 93
a9e2aefa 94 Bool_t fDrawClusters; //Flag True if Clusters to be drawn
95 Bool_t fDrawCoG; //Flag True if CoG to be drawn
96 //to be drawn
97 Float_t fTheta; //Viewing angle theta
98 Float_t fPhi; //Viewing angle phi
99 Float_t fPsi; //Viewving angle psi (rotation on display)
100 Float_t fRrange; //Size of view in R
101 Float_t fZrange; //Size of view along Z
102 Float_t fZoomX0[20]; //Low x range of zoom number i
103 Float_t fZoomY0[20]; //Low y range of zoom number i
104 Float_t fZoomX1[20]; //High x range of zoom number i
105 Float_t fZoomY1[20]; //High y range of zoom number i
106 Int_t fZooms; //Number of zooms
107 Int_t fHitsCuts; //Number of hits surviving cuts
108 Int_t fClustersCuts; //Number of clusters surviving cuts
109 TCanvas *fCanvas; //Pointer to the display canvas
110 TPad *fTrigPad; //Pointer to the trigger pad
111 TPad *fColPad; //Pointer to the colors pad
112 TPad *fButtons; //Pointer to the buttons pad
113 TPad *fPad; //Pointer to the event display main pad
114 TSlider *fRangeSlider; //Range slider
115 TButton *fPickButton; //Button to activate Pick mode
116 TButton *fZoomButton; //Button to activate Zoom mode
117 TArc *fArcButton; //Gren/Red button to show Pick/Zoom mode
118 TObjArray *fPoints; //Array of points for each cathode
119 TObjArray *fPhits; //Array of hit points for each chamber
120 TObjArray *fRpoints; //Array of cog points for each cathode
121 TObjArray *fR2points; //Array of cog points for each cathode
122 TObjArray *fCpoints; //Array of correlated points for each first cathode
123 Int_t fNextCathode; //Flagging next cathode
124 ClassDef(AliMUONDisplay, 0) //Utility class to display MUON clusters...
fe4da5cc 125};
126
127#endif
a9e2aefa 128
129
130
131
132
133
134
135