Geometry for MFT (Brigitte)
[u/mrichter/AliRoot.git] / EVE / alice-macros / geom_vzero.C
CommitLineData
197639c0 1// $Id$
d810d0de 2// Main authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007
3
4/**************************************************************************
5 * Copyright(c) 1998-2008, ALICE Experiment at CERN, all rights reserved. *
6 * See http://aliceinfo.cern.ch/Offline/AliRoot/License.html for *
51346b82 7 * full copyright notice. *
d810d0de 8 **************************************************************************/
197639c0 9
ba978640 10#if !defined(__CINT__) || defined(__MAKECINT__)
11#include <TGeoManager.h>
12#include <TGeoNode.h>
13#include <TEveManager.h>
14#include <TEveElement.h>
15#include <TEveGeoNode.h>
290113e6 16
17#include <AliEveEventManager.h>
ba978640 18#endif
19
197639c0 20void geom_vzero()
21{
a15e6d7d 22 static const TEveException kEH("geom_vzero() ");
c74b78cd 23
290113e6 24 AliEveEventManager::AssertGeometry();
197639c0 25
84aff7a4 26 TEveElementList* list = new TEveElementList("VZero");
27 gEve->AddGlobalElement(list);
197639c0 28
c74b78cd 29 TGeoNode* node = 0;
84aff7a4 30 TEveGeoTopNode* re;
197639c0 31
c74b78cd 32 TGeoNode* mnode = gGeoManager->GetTopVolume()->FindNode("VZERO_1");
33 if (!mnode) {
a15e6d7d 34 Error(kEH, "mother node not found.");
c74b78cd 35 return;
36 }
37
38 node = mnode->GetVolume()->FindNode("V0RI_1");
39 printf("opofoih %p\n", node);
40 if (!node) {
a15e6d7d 41 Error(kEH, "V0R not found.");
c74b78cd 42 return;
43 }
84aff7a4 44 re = new TEveGeoTopNode(gGeoManager, node);
9a5c8f9c 45 re->UseNodeTrans();
84aff7a4 46 gEve->AddGlobalElement(re, list);
197639c0 47
c74b78cd 48 node = mnode->GetVolume()->FindNode("V0LE_1");
49 if (!node) {
a15e6d7d 50 Error(kEH, "V0L not found.");
c74b78cd 51 return;
52 }
84aff7a4 53 re = new TEveGeoTopNode(gGeoManager, node);
9a5c8f9c 54 re->UseNodeTrans();
84aff7a4 55 gEve->AddGlobalElement(re, list);
197639c0 56
84aff7a4 57 gEve->Redraw3D();
197639c0 58}