134 bool barrel = fabs(
i->eta()) < 1.5;
135 if (
i->isEnergyValid())
136 barrel = fabs(
i->calEnergy().ecal_position.eta()) < 1.5;
139 Double_t
delta(0.01);
140 TEveStraightLineSet* direction =
new TEveStraightLineSet(
"Direction at vertex");
141 direction->SetPickable(kTRUE);
142 direction->SetTitle(
"Muon direction at vertex");
143 direction->SetPickable(kTRUE);
148 x = 310 * fabs(
tan(
i->theta())) *
cos(
i->phi());
149 y = 310 * fabs(
tan(
i->theta())) *
sin(
i->phi());
153 direction->SetLineColor(kYellow);
154 direction->SetDepthTest(kFALSE);
155 tList->AddElement(direction);
157 if (!
i->isEnergyValid())
161 TEveStraightLineSet* ecalposition =
new TEveStraightLineSet(
"ecal position");
162 ecalposition->SetPickable(kTRUE);
163 ecalposition->SetTitle(
"Muon position at ECAL surface");
165 x =
i->calEnergy().ecal_position.eta();
166 y =
i->calEnergy().ecal_position.phi();
168 x =
i->calEnergy().ecal_position.x();
169 y =
i->calEnergy().ecal_position.y();
174 ecalposition->SetLineColor(kRed);
175 ecalposition->SetLineWidth(2);
176 ecalposition->SetDepthTest(kFALSE);
177 tList->AddElement(ecalposition);
180 TEveStraightLineSet* hcalposition =
new TEveStraightLineSet(
"hcal position");
181 hcalposition->SetPickable(kTRUE);
182 hcalposition->SetTitle(
"Muon position at HCAL surface");
184 x =
i->calEnergy().hcal_position.eta();
185 y =
i->calEnergy().hcal_position.phi();
187 x =
i->calEnergy().hcal_position.x();
188 y =
i->calEnergy().hcal_position.y();
193 hcalposition->SetLineColor(kBlue);
194 hcalposition->SetLineWidth(2);
195 hcalposition->SetDepthTest(kFALSE);
196 tList->AddElement(hcalposition);
199 TEveStraightLineSet*
lines =
new TEveStraightLineSet(
"Muon trajectory in ECAL",
"Muon trajectory in ECAL");
200 lines->SetPickable(kTRUE);
202 lines->AddLine(
i->calEnergy().ecal_position.eta(),
203 i->calEnergy().ecal_position.phi(),
205 i->calEnergy().hcal_position.eta(),
206 i->calEnergy().hcal_position.phi(),
209 lines->AddLine(
i->calEnergy().ecal_position.x(),
210 i->calEnergy().ecal_position.y(),
212 i->calEnergy().hcal_position.x(),
213 i->calEnergy().hcal_position.y(),
216 lines->SetLineColor(kRed);
217 lines->SetDepthTest(kFALSE);
218 tList->AddElement(
lines);