1 #if !defined(__CINT__) || defined(__MAKECINT__)
2 #include <TClonesArray.h>
4 #include <TGeoMatrix.h>
7 #include <TEveElement.h>
8 #include <TEveFrameBox.h>
9 #include <TEveManager.h>
10 #include <TEvePointSet.h>
11 #include <TEveRGBAPalette.h>
12 #include <TEveTrans.h>
13 #include <TEveQuadSet.h>
15 #include <HMPID/AliHMPIDDigit.h>
16 #include <HMPID/AliHMPIDv3.h>
17 #include <STEER/STEER/AliCluster3D.h>
18 #include <STEER/STEER/AliRunLoader.h>
19 #include <EVE/EveBase/AliEveEventManager.h>
24 const Char_t *name[]={ "HMPID0", "HMPID1", "HMPID2", "HMPID3",
25 "HMPID4", "HMPID5", "HMPID6" };
27 AliRunLoader* rl = AliEveEventManager::AssertRunLoader();
28 rl->LoadDigits("HMPID");
30 TTree *dTree = rl->GetTreeD("HMPID", kFALSE);
33 TEveElementList* list = new TEveElementList("HMPID Digits");
34 gEve->AddElement(list);
36 gStyle->SetPalette(1, 0);
38 TEveRGBAPalette *pal = new TEveRGBAPalette(0, 3000);
40 TEveFrameBox *box = new TEveFrameBox();
41 box->SetAAQuadXY(0, 0, 0, 144, 121);
42 box->SetFrameColor(kGray);
44 TClonesArray* digits = new TClonesArray("AliHMPIDDigit");
45 for (Int_t iCh = 0; iCh < 7; ++iCh)
47 TBranch *br = dTree->GetBranch(name[iCh]);
48 br->SetAddress(&digits);
51 TEveQuadSet* q = new TEveQuadSet(Form("Chamber %d", iCh));
55 q->SetAntiFlick(kTRUE);
56 q->SetPickable(kTRUE);
58 q->Reset(TEveQuadSet::kQT_RectangleXYFixedDimZ, kFALSE, 64);
60 q->SetDefHeight(0.84f);
63 for(Int_t iDig = 0; iDig < digits->GetEntriesFast(); ++iDig)
65 AliHMPIDDigit *pDig = (AliHMPIDDigit*) digits->At(iDig);
67 q->AddQuad(pDig->PadChX()*0.8f, pDig->PadChY()*0.84f);
68 q->QuadValue(TMath::Nint(pDig->Q()));
69 q->QuadId(new AliHMPIDDigit(*pDig));
75 AliHMPIDv3::IdealPosition(iCh, &mat);
76 q->RefMainTrans().SetFrom(mat);
77 q->RefMainTrans().Move3LF(-0.5f*144, -0.5f*121, 0);
83 rl->UnloadDigits("HMPID");