FairRoot/PandaRoot
Functions
GeoDisplay.C File Reference

Go to the source code of this file.

Functions

 GeoDisplay ()
 

Function Documentation

GeoDisplay ( )

d/pndint02/asanchez/FOct09/sim_hypFSG41TCIPAxxbG.root");//sim_with_vis.root");

Definition at line 3 of file GeoDisplay.C.

References fRun, gGeoManager, parInput1, rootlogon(), rtdb, top, and trk.

4 {
5  // Load basic libraries
6  gROOT->LoadMacro("$VMCWORKDIR/gconfig/rootlogon.C");
7  rootlogon();
8  gSystem->Load("libEve");
9  gSystem->Load("libEventDisplay");
10  //gSystem->Load("libHypGe");
11  //gSystem->Load("librazhyp");
12  gSystem->Load("libHyp");
13  //gSystem->Load("libTof");
14 
15  // ----- Reconstruction run -------------------------------------------
16  FairRunAna *fRun= new FairRunAna();
17  //fRun->SetInputFile("points.x3872.jpsipipi.phsp.root");
18  // fRun->SetInputFile("../qa/lhetrack/points_tpccombi.root");
19  fRun->SetInputFile("sim_piTr.root");//sim_pidC.root");
21  // fRun->SetInputFile("../drc/testrun1.root");
22  // fRun->SetInputFile("../dsk/sim_dsk.g4native.root");
23  fRun->SetOutputFile("tst.root");
24  // fRun->LoadGeometry();
25 
26 
27 
28  FairRuntimeDb* rtdb = fRun->GetRuntimeDb();
29  FairParRootFileIo* parInput1 = new FairParRootFileIo();
30  // parInput1->open("../drc/testparams.root");
31  parInput1->open("PiTrparams.root");
32  //../hyp/SimG41TCIPAxxbGparams.root");//params_with_vis.root");
33 
34  rtdb->setFirstInput(parInput1);
35 
36 
37 
38  char str[80];
39  char str1[80];
40  char str2[80];
41  char str3[80];
42 
43  TGeoNode* trk;
44  TGeoNode* trl;
45  TGeoNode* trab;
46  TGeoNode* trsi;
47 
48  std::cout<<" gGeoM "<<gGeoManager<<std::endl;
49  int k;
50  gGeoManager->SetVisLevel(0);
51 
52  TGeoVolume* top = gGeoManager->GetTopVolume();
53  //gGeoManager->SetVisLevel(4);
54 
55 // the secondary target (detetctor volume) consist of 4 blocks
56 // denominated by "stg0%d ", each of this block acts as a mother volume
57 // contains 20 layers which also mother volume for a double layer "stglay%d_1".
58 // the double layer is composed by one silicon and one absorber layers
59 // These are the "real" detector volumes,
60 // the names of these volumes are given by "stglAb%d_1" and "stglSi%d_1".
61 /*
62  for(int i=0;i<4;i++)
63  {
64 
65 
66  sprintf(str,"stg0%d_1",i+1);
67  std::cout<<" name "<<str<<std::endl;
68 
69  TGeoNode* trk = top->FindNode(str);
70  cout<<" tr "<<trk<<endl;
71 
72  for(int j=0;j<20;j++){
73  if(i==0) k = j;
74  if(i==1) k = j+20;
75  if(i==2) k = j+40;
76  if(i==3) k = j+60;
77 
78  sprintf(str1,"stglay%d_1",k);
79  TGeoNode* trl = trk->GetVolume()->FindNode(str1);
80  //cout<<" trl "<<trl<<" name "<<str1<<endl;
81 
82 
83  sprintf(str2,"stglAb%d_1",k);
84  TGeoNode* tra = trl->GetVolume()->FindNode(str2);
85  //cout<<" tra "<<tra<< " same "<<str2<<endl;
86  tra->GetVolume()->SetLineColor(kYellow);
87  sprintf(str3,"stglSi%d_1",k);
88  TGeoNode* trs = trl->GetVolume()->FindNode(str3);
89  //cout<<" tra "<<tra<< " same "<<str2<<endl;
90  trs->GetVolume()->SetLineColor(kMagenta);
91  //fMan->AddGlobalElement(tra[k]);
92  }
93  }
94 */
95 
96 }
TGeoManager * gGeoManager
TGeoVolume * top
FairRunAna * fRun
Definition: hit_dirc.C:58
FairRuntimeDb * rtdb
Definition: hit_dirc.C:66
FairParRootFileIo * parInput1
Definition: hit_dirc.C:67
GFTrack * trk
Definition: checkgenfit.C:13