Fork me on GitHub

Changeset d07e957 in git for modules/TreeWriter.cc


Ignore:
Timestamp:
Nov 8, 2013, 5:09:58 PM (11 years ago)
Author:
pavel <pavel@…>
Branches:
ImprovedOutputFile, Timing, dual_readout, llp, master
Children:
87cadbd
Parents:
984cd31
Message:

add vertex block

File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/TreeWriter.cc

    r984cd31 rd07e957  
    213213//------------------------------------------------------------------------------
    214214
     215void TreeWriter::ProcessVertices(ExRootTreeBranch *branch, TObjArray *array)
     216{
     217  TIter iterator(array);
     218  Candidate *candidate = 0;
     219  Vertex *entry = 0;
     220
     221  // loop over all vertices
     222  iterator.Reset();
     223  while((candidate = static_cast<Candidate*>(iterator.Next())))
     224  {
     225    const TLorentzVector &position = candidate->Position;
     226
     227    entry = static_cast<Vertex*>(branch->NewEntry());
     228
     229    entry->X = position.X();
     230    entry->Y = position.Y();
     231    entry->Z = position.Z();
     232    entry->T = position.T();
     233  }
     234}
     235
     236//------------------------------------------------------------------------------
     237
    215238void TreeWriter::ProcessTracks(ExRootTreeBranch *branch, TObjArray *array)
    216239{
     
    221244  Double_t pt, signz, cosTheta, eta, rapidity;
    222245
    223   // loop over all jets
     246  // loop over all tracks
    224247  iterator.Reset();
    225248  while((candidate = static_cast<Candidate*>(iterator.Next())))
     
    280303  Double_t pt, signPz, cosTheta, eta, rapidity;
    281304
    282   // loop over all jets
     305  // loop over all towers
    283306  iterator.Reset();
    284307  while((candidate = static_cast<Candidate*>(iterator.Next())))
Note: See TracChangeset for help on using the changeset viewer.