]>
Commit | Line | Data |
---|---|---|
319f3084 | 1 | /************************************************************************** |
2 | * Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. * | |
3 | * See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for * | |
4 | * full copyright notice. * | |
5 | **************************************************************************/ | |
6 | ||
4d62585e | 7 | TEveGeoShape *gGeomGentle = 0; |
de33999e | 8 | |
9 | void alieve_online_init() | |
319f3084 | 10 | { |
de33999e | 11 | gROOT->LoadMacro("geom_gentle.C"); |
12 | ||
13 | gROOT->LoadMacro("primary_vertex.C"); | |
14 | gROOT->LoadMacro("esd_tracks.C"); | |
9fb2a3ed | 15 | gROOT->LoadMacro("trd_tracks.C++"); |
16 | gROOT->LoadMacro("trd_detectors.C++"); | |
de33999e | 17 | |
dc9dec4d | 18 | gROOT->LoadMacro("its_clusters.C++"); |
19 | gROOT->LoadMacro("tpc_clusters.C++"); | |
f1fa3b4b | 20 | gROOT->LoadMacro("hmpid_clusters.C++"); |
de33999e | 21 | |
22 | gROOT->LoadMacro("acorde_raw.C"); | |
23 | gROOT->LoadMacro("its_raw.C"); | |
24 | gROOT->LoadMacro("tpc_raw.C"); | |
25 | ||
a9e18d1c | 26 | TEveUtil::AssertMacro("VizDB_scan.C"); |
27 | ||
2a8440b7 | 28 | // Temp fix !!! |
29 | TGeoManager *man = gGeoManager; | |
de33999e | 30 | gGeomGentle = geom_gentle(); |
2a8440b7 | 31 | // Temp fix !!! |
32 | gGeoManager = man; | |
de33999e | 33 | |
dc9dec4d | 34 | gROOT->ProcessLine(".L SplitGLView.C++g"); // !!!! debug-mode |
b631c5f2 | 35 | |
de33999e | 36 | TEveBrowser* browser = gEve->GetBrowser(); |
b631c5f2 | 37 | browser->ShowCloseTab(kFALSE); |
38 | ||
de33999e | 39 | browser->ExecPlugin("SplitGLView", 0, "new SplitGLView(gClient->GetRoot(), 600, 450, kTRUE)"); |
40 | ||
41 | if (gRPhiMgr) { | |
42 | TEveProjectionAxes* a = new TEveProjectionAxes(gRPhiMgr); | |
b631c5f2 | 43 | a->SetMainColor(kWhite); |
68ca2fe7 | 44 | a->SetTitle("R-Phi"); |
b631c5f2 | 45 | a->SetTitleSize(0.05); |
115b6655 | 46 | a->SetTitleFont(); |
b631c5f2 | 47 | a->SetLabelSize(0.025); |
115b6655 | 48 | a->SetLabelFont(); |
de33999e | 49 | gEve->GetScenes()->FindChild("R-Phi Projection")->AddElement(a); |
50 | } | |
51 | if (gRhoZMgr) { | |
52 | TEveProjectionAxes* a = new TEveProjectionAxes(gRhoZMgr); | |
b631c5f2 | 53 | a->SetMainColor(kWhite); |
54 | a->SetTitle("Rho-Phi"); | |
55 | a->SetTitleSize(0.05); | |
115b6655 | 56 | a->SetTitleFont(); |
b631c5f2 | 57 | a->SetLabelSize(0.025); |
115b6655 | 58 | a->SetLabelFont(); |
de33999e | 59 | gEve->GetScenes()->FindChild("Rho-Z Projection")->AddElement(a); |
60 | } | |
61 | ||
47aab29b | 62 | browser->StartEmbedding(TRootBrowser::kBottom); |
4d62585e | 63 | new AliEveEventManagerWindow(AliEveEventManager::GetMaster()); |
47aab29b | 64 | browser->StopEmbedding("EventCtrl"); |
65 | ||
b631c5f2 | 66 | browser->ShowCloseTab(kTRUE); |
67 | ||
de33999e | 68 | gEve->Redraw3D(kTRUE); |
69 | } | |
70 | ||
71 | void alieve_online_on_new_event() | |
72 | { | |
effa8d5d | 73 | if (AliEveEventManager::HasRawReader()) |
74 | its_raw(); | |
de33999e | 75 | its_clusters(); |
76 | ||
effa8d5d | 77 | if (AliEveEventManager::HasRawReader()) |
78 | tpc_raw(); | |
de33999e | 79 | tpc_clusters(); |
80 | ||
f1fa3b4b | 81 | hmpid_clusters(); |
82 | ||
effa8d5d | 83 | if (AliEveEventManager::HasRawReader()) |
84 | acorde_raw(); | |
de33999e | 85 | |
86 | primary_vertex(); | |
87 | esd_tracks(); | |
88 | ||
9fb2a3ed | 89 | if (AliEveEventManager::HasESDfriend()) trd_tracks(); |
90 | trd_detectors(); | |
91 | ||
de33999e | 92 | AliESDEvent* esd = AliEveEventManager::AssertESD(); |
93 | Double_t x[3]; | |
94 | esd->GetPrimaryVertex()->GetXYZ(x); | |
95 | ||
96 | TEveElement* top = gEve->GetCurrentEvent(); | |
97 | ||
98 | if (gRPhiMgr && top) { | |
99 | gRPhiMgr->DestroyElements(); | |
100 | gRPhiMgr->SetCenter(x[0], x[1], x[2]); | |
101 | gRPhiMgr->ImportElements(gGeomGentle); | |
102 | gRPhiMgr->ImportElements(top); | |
103 | } | |
104 | if (gRhoZMgr && top) { | |
105 | gRhoZMgr->DestroyElements(); | |
106 | gRhoZMgr->SetCenter(x[0], x[1], x[2]); | |
107 | gRhoZMgr->ImportElements(gGeomGentle); | |
108 | gRhoZMgr->ImportElements(top); | |
109 | } | |
110 | ||
111 | gROOT->ProcessLine("SplitGLView::UpdateSummary()"); | |
319f3084 | 112 | } |