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 TEvePointSet* points = new TEvePointSet(Form("TPC Hits '%s'", selection));
24 points->SetSourceCS(TEvePointSelectorConsumer::kTVT_RPhiZ);
26 TEvePointSelector ps(ht, points, varexp, selection);
29 if (points->Size() == 0 && gEve->GetKeepEmptyCont() == kFALSE) {
30 Warning("tpc_hits", Form("No hits match '%s'", selection));
35 points->SetName(Form("TPC Hits"));
36 const TString viz_tag("SIM Hits TPC");
37 points->ApplyVizTag(viz_tag, "Hits");
39 points->SetTitle(Form("N=%d", points->Size()));
40 points->SetMarkerSize(.5);
41 points->SetMarkerColor(3);
45 gEve->AddElement(points, cont);