2 // Main authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007
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 **************************************************************************/
11 tpc_hits(const char *varexp = "TPC2.fArray.fR:TPC2.fArray.fFi:TPC2.fArray.fZ",
12 const char *selection = "TPC2.fArray.fR>80",
13 TEveElement *cont = 0)
15 // Extracts 'major' TPC hits (not the compressed ones).
16 // This gives ~2.5% of all hits.
18 AliRunLoader* rl = AliEveEventManager::AssertRunLoader();
21 TTree* ht = rl->GetTreeH("TPC", false);
23 //PH The line below is replaced waiting for a fix in Root
24 //PH which permits to use variable siza arguments in CINT
25 //PH on some platforms (alphalinuxgcc, solariscc5, etc.)
26 //PH TEvePointSet* points = new TEvePointSet(Form("TPC Hits '%s'", selection));
28 sprintf(form,"TPC Hits '%s'", selection);
29 TEvePointSet* points = new TEvePointSet(form);
30 points->SetSourceCS(TEvePointSelectorConsumer::kTVT_RPhiZ);
32 TEvePointSelector ps(ht, points, varexp, selection);
35 if (points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) {
36 Warning("tpc_hits", Form("No hits match '%s'", selection));
41 //PH points->SetTitle(Form("N=%d", points->Size()));
42 sprintf(form,"N=%d", points->Size());
43 points->SetTitle(form);
44 points->SetMarkerSize(.5);
45 points->SetMarkerColor((Color_t)3);
47 gEve->AddElement(points, cont);