StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
runTrgTree.C
1 void runTrgTree(char* file="test.lis", Int_t nevt=1000){
2 
3  gROOT->LoadMacro("bfc.C");
4  bfc(-2,"StEvent,RMudst");
5 
6  StMuDstMaker* muDstMaker = new StMuDstMaker(0, 0, "", file,".", 1000, "MuDst");
7 
8  int n=muDstMaker->tree()->GetEntries();
9  printf("Found %d entries in Mudst\n",n);
10  int start=0, stop=n;
11  if(nevt>=0 && nevt<n){
12  stop=nevt;
13  }
14  printf("Doing Event=%d to %d\n",start,stop);
15 
16  gSystem->Load("StTriggerDataMaker");
17  StTrgTreeMaker* trgtree = new StTrgTreeMaker("trgTree");
18 
19  chain->Init();
20  chain->EventLoop(start,stop);
21  chain->Finish();
22 }
TTree * tree()
Returns pointer to the current TTree, the top level io structure that holds the event, track, v0, etc. information in branches of that tree.
Definition: StMuDstMaker.h:427
virtual Int_t Finish()
Definition: StChain.cxx:85