2 // $MpId: testSectorPadIterators.C,v 1.9 2005/10/28 15:36:08 ivana Exp $
4 // Test macro for reading sector, and iterate over it
6 void testSectorPadIterators(AliMpStationType station = kStation1,
7 AliMpPlaneType plane = kBendingPlane,
8 Bool_t rootInput = false)
10 AliMpSector *sector = 0;
12 AliMpSectorReader r(station, plane);
13 sector=r.BuildSector();
16 TString filePath = AliMpFiles::SectorFilePath(station,plane);
17 filePath.ReplaceAll("zones.dat", "sector.root");
19 TFile f(filePath.Data(), "READ");
20 sector = (AliMpSector*)f.Get("Sector");
25 TCanvas *can = new TCanvas("canv");
27 const Double_t xmax=150;
28 const Double_t ymax=250;
30 AliMpSectorPadIterator it = AliMpSectorPadIterator(sector);
32 for (it.First(); ! it.IsDone(); it.Next()) {
33 AliMpIntPair indices = it.CurrentItem().GetIndices();
34 cout<<"Iterator number "<< num++ << " at "<< indices <<endl;
35 TMarker* marker = new TMarker( (Double_t)indices.GetFirst() /xmax,
36 (Double_t)indices.GetSecond()/ymax,