4 #include "TClonesArray.h"
6 #include "$(ALICE_ROOT)/STEER/AliRun.h"
7 #include "$(ALICE_ROOT)/ITS/AliITS.h"
8 #include "$(ALICE_ROOT)/ITS/AliITSgeom.h"
9 #include "$(ALICE_ROOT)/ITS/AliITSHit.h"
11 void AliITSPrintGeom(TString hfn="galice.root",Int_t mod=-1){
12 // Macro to print out the information kept in the AliITSgeom class, for
13 //all or a specific module
15 // Dynamically link some shared libs
16 if (gClassTable->GetID("AliRun") < 0) {
17 gROOT->LoadMacro("loadlibs.C");
21 TFile *hf = (TFile*)gROOT->GetListOfFiles()->FindObject(hfn);
27 hf = new TFile(hfn,"READ");
28 // Get AliRun object from file or return if not on file
29 if (gAlice) {delete gAlice; gAlice = 0;}
30 gAlice = (AliRun*)hf->Get("gAlice");
32 cerr << "AliRun object not found on file "<< FileName << "!" << endl;
33 file->Close(); // close file and return error.
38 gROOT->LoadMacro("$(ALICE_ROOT)/ITS/AliITSstandard.C");
40 hf = AccessFile(hfn,"R"); // Set up to read in Data
42 AliITS *ITS = (AliITS*)gAlice->GetDetector("ITS");
44 cout << "Error: no ITS found. Aborting"<<endl;
47 AliITSgeom *gm = ITS->GetITSgeom();
49 Int_t mod2 = gm->GetIndexMax();
54 AliITSgeomMatrix *gmm = gm->GetGeomMatrix(0);
56 gmm->PrintComment(&cout); cout << endl;
57 for(m=mod1;m<mod2;m++){
58 gmm = gm->GetGeomMatrix(m);
59 gmm->Print(&cout); cout << endl;