~maus-maintainers/maus/merge

« back to all changes in this revision

Viewing changes to src/map/MapCppGlobalRawTracks/MapCppGlobalRawTracks.cc

  • Committer: Peter G Lane
  • Date: 2014-01-02 21:14:30 UTC
  • mto: (663.40.7 merge)
  • mto: This revision was merged to the branch mainline in revision 693.
  • Revision ID: lane@shibuya-20140102211430-9ijm1wztx55j1zs0
Fixed typo in configuration defaults. Fixed particle event and detector associations in raw and reconstructed track points.

Show diffs side-by-side

added added

removed removed

Lines of Context:
217
217
void MapCppGlobalRawTracks::LoadTOFTrack(
218
218
    MAUS::ReconEvent const * const recon_event,
219
219
    GlobalDS::TrackPArray & tof_tracks) {
 
220
  const int particle_event_number = recon_event->GetPartEventNumber();
220
221
  const TOFEvent * tof_event = recon_event->GetTOFEvent();
221
222
  const TOFEventSpacePoint space_point_events
222
223
    = tof_event->GetTOFEventSpacePoint();
267
268
       tof0_space_point != tof0_space_points.end();
268
269
       ++tof0_space_point) {
269
270
    GlobalDS::TrackPoint * track_point = new GlobalDS::TrackPoint();
 
271
    track_point->set_particle_event(particle_event_number);
270
272
    PopulateTOFTrackPoint(tof0, tof0_space_point, 40., 10, track_point);
271
273
    track_points.push_back(track_point);
272
274
 
286
288
       tof1_space_point != tof1_space_points.end();
287
289
       ++tof1_space_point) {
288
290
    GlobalDS::TrackPoint * track_point = new GlobalDS::TrackPoint();
 
291
    track_point->set_particle_event(particle_event_number);
289
292
    PopulateTOFTrackPoint(tof1, tof1_space_point, 60., 7, track_point);
290
293
    track_points.push_back(track_point);
291
294
 
307
310
       tof2_space_point != tof2_space_points.end();
308
311
       ++tof2_space_point) {
309
312
    GlobalDS::TrackPoint * track_point = new GlobalDS::TrackPoint();
 
313
    track_point->set_particle_event(particle_event_number);
310
314
    PopulateTOFTrackPoint(tof2, tof2_space_point, 60., 10, track_point);
311
315
    track_points.push_back(track_point);
312
316
 
390
394
  space_point->set_position(position);
391
395
  static_cast<GlobalDS::BasePoint*>(track_point)->operator=(*space_point);
392
396
  track_point->set_space_point(space_point);
393
 
  track_point->set_particle_event(tof_space_point->GetPhysEventNumber());
394
397
  track_point->set_mapper_name(kClassname);
395
398
 
396
399
  track_point->set_position(position);
555
558
    tracks.push_back(track);
556
559
  }
557
560
 
 
561
  const int particle_event_number = recon_event->GetPartEventNumber();
558
562
  SciFiEvent const * const scifi_event = recon_event->GetSciFiEvent();
559
563
  SciFiTrackPArray scifi_tracks = scifi_event->scifitracks();
560
564
  SciFiTrackPArray::const_iterator scifi_track = scifi_tracks.begin();
580
584
      }
581
585
      const Detector& detector = detector_mapping->second;
582
586
      GlobalDS::TrackPoint * track_point = new GlobalDS::TrackPoint();
 
587
      track_point->set_particle_event(particle_event_number);
583
588
      PopulateSciFiTrackPoint(detector, scifi_track_point, track_point);
584
589
 
585
590
      MAUSGeant4Manager * const simulator = MAUSGeant4Manager::GetInstance();
628
633
  static_cast<GlobalDS::BasePoint*>(track_point)->operator=(*space_point);
629
634
  track_point->set_space_point(space_point);
630
635
 
631
 
  // FIXME(Lane) Need to get event number, but now using SciFi track points
632
 
  // track_point->set_particle_event((*scifi_space_point)->get_event());
633
636
  track_point->set_mapper_name(kClassname);
634
637
 
635
638
  const double Px = (*scifi_track_point)->px();