FairRoot
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FairEveRecoTrackList.cxx
Go to the documentation of this file.
1 /********************************************************************************
2  * Copyright (C) 2020 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
3  * *
4  * This software is distributed under the terms of the *
5  * GNU Lesser General Public Licence (LGPL) version 3, *
6  * copied verbatim in the file "LICENSE" *
7  ********************************************************************************/
8 /*
9  * FairEveRecoTrackList.cxx
10  *
11  * Created on: 17 cze 2020
12  * Author: Daniel Wielanek
13  * E-mail: daniel.wielanek@gmail.com
14  * Warsaw University of Technology, Faculty of Physics
15  */
16 
17  #include "FairEveRecoTrackList.h"
18  #include <TEveElement.h> // for TEveElement::List_i
19  #include <TEvePointSet.h> // for TEvePointSet
20  #include <list> // for operator!=, __list_iterator
21  #include "FairEveTrack.h" // for FairEveTrack
22  class TEveTrackPropagator;
23 
24 FairEveRecoTrackList::FairEveRecoTrackList(TString name, TEveTrackPropagator* prop)
25  : TEveTrackList(name, prop)
26 {
27  fChildClass = FairEveRecoTrack::Class();
28 }
29 
31 {
32  for (List_i i = BeginChildren(); i != EndChildren(); ++i) {
33  FairEveRecoTrack* track = (FairEveRecoTrack*)(*i);
34  if (track->GetRecoTrack()->GetLineColor() == fLineColor)
35  track->GetRecoTrack()->SetLineColor(col);
36  if (track->GetMCTrack()) {
37  track->GetMCTrack()->SetLineColor(col);
38  }
39  }
40  fLineColor = col;
41 }
42 
44 {
45  for (List_i i = BeginChildren(); i != EndChildren(); ++i) {
46  FairEveRecoTrack* track = (FairEveRecoTrack*)(*i);
47  if (track->GetRecoTrack()->GetLineStyle() == fLineStyle)
48  track->GetRecoTrack()->SetLineStyle(s);
49  if (track->GetMCTrack()) {
50  // track->GetMCTrack()->SetLineStyle(s);
51  }
52  }
53  fLineStyle = s;
54 }
55 
57 {
58  for (List_i i = BeginChildren(); i != EndChildren(); ++i) {
59  FairEveRecoTrack* track = (FairEveRecoTrack*)(*i);
60  if (track->GetRecoTrack()->GetLineWidth() == fLineWidth)
61  track->GetRecoTrack()->SetLineWidth(w);
62  if (track->GetMCTrack()) {
63  track->GetMCTrack()->SetLineWidth(w);
64  }
65  }
66  fLineWidth = w;
67 }
68 
70 {
71  for (List_i i = BeginChildren(); i != EndChildren(); ++i) {
72  FairEveRecoTrack* track = (FairEveRecoTrack*)(*i);
73  if (track->GetHits()) {
74  if (track->GetHits()->GetMarkerColor() == fMarkerColor) {
75  track->GetHits()->SetMarkerColor(c);
76  }
77  }
78  }
79  fMarkerColor = c;
80 }
81 
83 {
84  for (List_i i = BeginChildren(); i != EndChildren(); ++i) {
85  FairEveRecoTrack* track = (FairEveRecoTrack*)(*i);
86  if (track->GetHits()) {
87  if (track->GetHits()->GetMarkerSize() == fMarkerSize) {
88  track->GetHits()->SetMarkerSize(s);
89  }
90  }
91  }
92  fMarkerSize = s;
93 }
94 
96 {
97  for (List_i i = BeginChildren(); i != EndChildren(); ++i) {
98  FairEveRecoTrack* track = (FairEveRecoTrack*)(*i);
99  if (track->GetHits()) {
100  if (track->GetHits()->GetMarkerStyle() == fMarkerStyle) {
101  track->GetHits()->SetMarkerStyle(s);
102  }
103  }
104  }
105  fMarkerStyle = s;
106 }
107 
TEvePointSet * GetHits() const
FairEveTrack * GetMCTrack() const
FairEveTrack * GetRecoTrack() const
void SetLineColor(Color_t col)
void SetMarkerStyle(Style_t s)
void SetMarkerColor(Color_t c)