Using AliGeomManager in the macros (Raffaele)
[u/mrichter/AliRoot.git] / FMD / MakeFMDResMisAlignment.C
... / ...
CommitLineData
1void MakeFMDResMisAlignment()
2{
3 // Create TClonesArray of residual misalignment objects for FMD
4 //
5 if(!AliGeomManager::GetGeometry()){
6 if(!(AliCDBManager::Instance())->IsDefaultStorageSet())
7 AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT");
8 AliCDBManager::Instance()->SetRun(0);
9 AliGeomManager::LoadGeometry();
10 }
11
12 gSystem->Load("libFMDutil.so");
13 if( gSystem->Getenv("TOCDB") != TString("kTRUE") ){
14 // save on file
15 AliFMDAlignFaker faker(AliFMDAlignFaker::kAll, "geometry.root","FMDresidualMisalignment.root");
16 }else{
17 // save in CDB storage
18 const char* Storage = gSystem->Getenv("STORAGE");
19 AliFMDAlignFaker faker(AliFMDAlignFaker::kAll, "geometry.root", Storage);
20 }
21
22 // fRunMax should be changed in the constructor
23
24 faker.SetSensorDisplacement(-0.005, -0.005, -0.005, 0.005, 0.005, 0.005);
25 faker.SetSensorRotation(-0.5, -0.5, -0.5, 0.5, 0.5, 0.5);
26 faker.SetHalfDisplacement(-0.25, -0.25, -0.25, 0.25, 0.25, 0.25);
27 faker.SetHalfRotation(-0.5, -0.5, -0.5, 0.5, 0.5, 0.5);
28 faker.Exec();
29
30
31}