Added new case to read MC infomration from the AOD (AODMC))
authorkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 3 Sep 2009 16:04:13 +0000 (16:04 +0000)
committerkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 3 Sep 2009 16:04:13 +0000 (16:04 +0000)
PWG4/macros/AddTaskJets.C

index a4eb1ce..d035087 100644 (file)
@@ -185,7 +185,16 @@ AliJetReader *CreateJetReader(Char_t *jr){
     er = new AliJetAODReader();\r
     er->SetReaderHeader(jrh);\r
     break;\r
-\r
+  case "AODMC":\r
+    AliJetAODReaderHeader *jrh = new AliJetAODReaderHeader();\r
+    jrh->SetComment("AOD MC Reader");\r
+    jrh->SetPtCut(0.);\r
+    jrh->SetFiducialEta(-2.1,2.1); // to take all MC particles default is 0.9\r
+    jrh->SetReadAODMC(1);// 1 all primary MC , 2 all primary charged\r
+    // Define reader and set its header\r
+    er = new AliJetAODReader();\r
+    er->SetReaderHeader(jrh);\r
+    break;\r
   default:\r
     ::Error("AddTaskJets", "Wrong jet reader selected\n");\r
     return 0;\r