]> git.uio.no Git - u/mrichter/AliRoot.git/blob - EVE/Alieve/AliEveJetPlane.cxx
Remove trailing whitespace.
[u/mrichter/AliRoot.git] / EVE / Alieve / AliEveJetPlane.cxx
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 #include "AliEveJetPlane.h"
11 #include <TString.h>
12 #include <TBuffer3D.h>
13 #include <TBuffer3DTypes.h>
14 #include <TVirtualPad.h>
15 #include <TVirtualViewer3D.h>
16
17
18 //______________________________________________________________________
19 // AliEveJetPlane
20 //
21
22
23 Bool_t AliEveJetPlane::fgOneMomentumXYZ      = kFALSE;
24 Bool_t AliEveJetPlane::fgOneMomentumPhiTheta = kFALSE;
25 Bool_t AliEveJetPlane::fgOneEta     = kFALSE;
26 Bool_t AliEveJetPlane::fgOneE       = kFALSE;
27 Bool_t AliEveJetPlane::fgOneChgMass = kFALSE;
28
29
30 ClassImp(AliEveJetPlane)
31
32 AliEveJetPlane::AliEveJetPlane(Int_t iev) :
33   TEveElementList(Form("AliEveJetPlane %i",iev), Form("%i",iev)),
34
35   fMinEta (-1.5 ),
36   fMaxEta ( 1.5 ),
37   fMinPhi (-TMath::Pi() ),
38   fMaxPhi ( TMath::Pi() ),
39
40   fNEtaDiv(30),
41   fNPhiDiv(30),
42
43   fEtaScale(350/1.5),
44   fPhiScale(350/TMath::Pi()),
45   fEnergyScale(100.0),
46
47   fEnergyColorScale (0.),
48
49   fGridColor(5),
50
51   fRnrJets (kTRUE),
52   fRnrTracks (kTRUE),
53
54   fOneSelection (kTRUE),
55   fTwoSelection (kFALSE),
56
57   fSelectionFlag (1)
58 {
59   SetMainColorPtr(&fGridColor);
60 }
61
62 /**************************************************************************/
63
64 void AliEveJetPlane::AddJet(AliAODJet jet)
65 {
66   fJets.push_back(jet);
67 }
68
69 /**************************************************************************/
70
71 void AliEveJetPlane::AddTrack(AliAODTrack track)
72 {
73   fTracks.push_back(track);
74 }
75
76
77 /**************************************************************************/
78
79 void AliEveJetPlane::ComputeBBox()
80 {
81   BBoxInit();
82   BBoxCheckPoint(-350, -350, -20);
83   BBoxCheckPoint( 350,  350,  20);
84 }
85
86 void AliEveJetPlane::Paint(Option_t* /*option*/)
87 {
88   TBuffer3D buff(TBuffer3DTypes::kGeneric);
89
90   // Section kCore
91   buff.fID           = this;
92   buff.fColor        = fGridColor;
93   buff.fTransparency = 0;
94   fHMTrans.SetBuffer3D(buff);
95   buff.SetSectionsValid(TBuffer3D::kCore);
96
97   Int_t reqSections = gPad->GetViewer3D()->AddObject(buff);
98   if (reqSections == TBuffer3D::kNone) {
99     // printf("AliEveJetPlane::Paint viewer was happy with Core buff3d.\n");
100     return;
101   }
102 }