]> git.uio.no Git - u/mrichter/AliRoot.git/blob - EVE/alice-macros/geom_fmd.C
Avoid direct instantiation of AliMagF.
[u/mrichter/AliRoot.git] / EVE / alice-macros / geom_fmd.C
1 // $Id$
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          *
7  * full copyright notice.                                                 *
8  **************************************************************************/
9
10 void geom_fmd()
11 {
12   gGeoManager = AliEveEventManager::AssertGeometry();
13
14   TEveElementList* list = new TEveElementList("FMD");
15   gEve->AddGlobalElement(list);
16
17   for(Int_t i=1; i<=3; ++i)
18   {
19     TGeoNode       *node = 0;
20     TEveGeoTopNode *re   = 0;
21
22     //PH The line below is replaced waiting for a fix in Root
23     //PH which permits to use variable siza arguments in CINT
24     //PH on some platforms (alphalinuxgcc, solariscc5, etc.)
25     //PH node = gGeoManager->GetTopVolume()->FindNode(Form("F%dMT_%d", i, i));
26     char form[1000];
27     sprintf(form,"F%dMT_%d", i, i);
28     node = gGeoManager->GetTopVolume()->FindNode(form);
29     re = new TEveGeoTopNode(gGeoManager, node);
30     re->UseNodeTrans();
31     gEve->AddGlobalElement(re, list);
32
33     sprintf(form,"F%dMB_%d", i, i);
34     node = gGeoManager->GetTopVolume()->FindNode(form);
35     re = new TEveGeoTopNode(gGeoManager, node);
36     re->UseNodeTrans();
37     gEve->AddGlobalElement(re, list);
38   }
39
40   gEve->Redraw3D();
41 }