Fork me on GitHub

source: svn/trunk/examples/DelphesBrowser.C@ 1347

Last change on this file since 1347 was 975, checked in by Pavel Demin, 12 years ago

fix examples

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id Revision Date
File size: 795 bytes
Line 
1/*
2root -l examples/DelphesBrowser.C
3*/
4
5{
6 #include <stdexcept>
7 gSystem->Load("libDelphes");
8
9 TFile *outputFile = TFile::Open("test.root", "RECREATE");
10 ExRootTreeWriter *treeWriter = new ExRootTreeWriter(outputFile, "Delphes");
11
12 ExRootConfReader *confReader = new ExRootConfReader;
13
14 Delphes *modularDelphes = new Delphes("Delphes");
15
16 TObjArray *allParticleOutputArray = modularDelphes->ExportArray("allParticles");
17 TObjArray *stableParticleOutputArray = modularDelphes->ExportArray("stableParticles");
18 TObjArray *partonOutputArray = modularDelphes->ExportArray("partons");
19
20 confReader->ReadFile("examples/delphes_card_CMS.tcl");
21
22 modularDelphes->SetConfReader(confReader);
23 modularDelphes->SetTreeWriter(treeWriter);
24
25 modularDelphes->InitTask();
26
27 TBrowser browser;
28}
Note: See TracBrowser for help on using the repository browser.