1016 |
// |
// |
1017 |
if ( level.file == 2 ){ |
if ( level.file == 2 ){ |
1018 |
cintcom.str(""); |
cintcom.str(""); |
1019 |
cintcom << "PamLevel2 *L2 = (PamLevel2*)0x" << hex; |
cintcom << "PamLevel2 *L2 = (PamLevel2*)" << hex; //con const e l2 funziona |
1020 |
cintcom << L2; |
cintcom << L2; |
1021 |
gROOT->ProcessLine(cintcom.str().c_str()); |
gROOT->ProcessLine(cintcom.str().c_str()); |
1022 |
|
// printf(" comando: %s \n",cintcom.str().c_str()); |
1023 |
} else { |
} else { |
1024 |
cintcom.str(""); |
cintcom.str(""); |
1025 |
cintcom << "TTree *otr = (TTree*)0x" << hex; |
cintcom << "TTree *otr = (TTree*)" << hex; |
1026 |
cintcom << otr; |
cintcom << otr; |
1027 |
gROOT->ProcessLine(cintcom.str().c_str()); |
gROOT->ProcessLine(cintcom.str().c_str()); |
1028 |
// |
// |
1029 |
cintcom.str(""); |
cintcom.str(""); |
1030 |
cintcom << "struct Variables &var = (struct Variables &)0x" << hex; |
cintcom << "struct Variables &var = (struct Variables &)" << hex; |
1031 |
cintcom << &var; |
cintcom << &var; |
1032 |
gROOT->ProcessLine(cintcom.str().c_str()); |
gROOT->ProcessLine(cintcom.str().c_str()); |
1033 |
}; |
}; |
1449 |
text->DrawLatex(var.xxvc+0.17*var.sfx,var.yxvc-0.08*var.sfy,"CAS1"); |
text->DrawLatex(var.xxvc+0.17*var.sfx,var.yxvc-0.08*var.sfy,"CAS1"); |
1450 |
text->DrawLatex(var.xyvc-0.192*var.sfx,var.yyvc-0.08*var.sfy,"CAS4"); |
text->DrawLatex(var.xyvc-0.192*var.sfx,var.yyvc-0.08*var.sfy,"CAS4"); |
1451 |
text->DrawLatex(var.xyvc+0.17*var.sfx,var.yyvc-0.08*var.sfy,"CAS3"); |
text->DrawLatex(var.xyvc+0.17*var.sfx,var.yyvc-0.08*var.sfy,"CAS3"); |
1452 |
text->DrawLatex(var.xxvc-0.192*var.sfx,var.yxvc+0.48*var.sfy,"CARD2"); |
text->DrawLatex(var.xxvc-0.222*var.sfx,var.yxvc+0.48*var.sfy,"CARD2"); |
1453 |
text->DrawLatex(var.xxvc+0.155*var.sfx,var.yxvc+0.48*var.sfy,"CARD3"); |
text->DrawLatex(var.xxvc+0.185*var.sfx,var.yxvc+0.48*var.sfy,"CARD3"); |
1454 |
text->DrawLatex(var.xyvc-0.170*var.sfx,var.yyvc+0.48*var.sfy,"CARD1"); |
text->DrawLatex(var.xyvc-0.190*var.sfx,var.yyvc+0.48*var.sfy,"CARD1"); |
1455 |
text->DrawLatex(var.xyvc+0.13*var.sfx,var.yyvc+0.48*var.sfy,"CARD4"); |
text->DrawLatex(var.xyvc+0.16*var.sfx,var.yyvc+0.48*var.sfy,"CARD4"); |
1456 |
text->DrawLatex(var.xxvc-0.192*var.sfx,var.yxvc+0.39*var.sfy,"CAT3"); |
text->DrawLatex(var.xxvc-0.192*var.sfx,var.yxvc+0.39*var.sfy,"CAT3"); |
1457 |
text->DrawLatex(var.xxvc+0.155*var.sfx,var.yxvc+0.39*var.sfy,"CAT4"); |
text->DrawLatex(var.xxvc+0.155*var.sfx,var.yxvc+0.39*var.sfy,"CAT4"); |
1458 |
text->DrawLatex(var.xyvc-0.170*var.sfx,var.yyvc+0.39*var.sfy,"CAT2"); |
text->DrawLatex(var.xyvc-0.170*var.sfx,var.yyvc+0.39*var.sfy,"CAT2"); |
1914 |
if ( !var.TOF ) return; |
if ( !var.TOF ) return; |
1915 |
// |
// |
1916 |
Int_t tt = 0; |
Int_t tt = 0; |
1917 |
|
Int_t rj = 0; |
1918 |
// |
// |
1919 |
// force level0, i.e. show patterntrig variable! |
// force level0, i.e. show patterntrig variable! |
1920 |
// |
// |
2108 |
Float_t s12p = 0.055; |
Float_t s12p = 0.055; |
2109 |
ocolo = 10; |
ocolo = 10; |
2110 |
TPolyLine *ftof12ya[6]; |
TPolyLine *ftof12ya[6]; |
2111 |
|
rj=6; |
2112 |
for ( Int_t j=0; j<6; j++){ |
for ( Int_t j=0; j<6; j++){ |
2113 |
|
rj--; |
2114 |
Float_t xc1[4]={ (s12p*j), s12p*(j), s12p*(j+1), (s12p*j)}; |
Float_t xc1[4]={ (s12p*j), s12p*(j), s12p*(j+1), (s12p*j)}; |
2115 |
Float_t yc1[4]={ -ws13, 0., 0., -ws13}; |
Float_t yc1[4]={ -ws13, 0., 0., -ws13}; |
2116 |
Float_t xc[4]; |
Float_t xc[4]; |
2126 |
} else { |
} else { |
2127 |
colo = 1; |
colo = 1; |
2128 |
}; |
}; |
2129 |
ColorMIP(ms12a[j],colo); |
ColorMIP(ms12a[rj],colo); |
2130 |
// |
// |
2131 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2132 |
if ( mt12[0][j] == 4095. ) colo = noadc; |
if ( mt12[0][rj] == 4095. ) colo = noadc; |
2133 |
// |
// |
2134 |
ftof12ya[j]->SetFillColor(colo); |
ftof12ya[j]->SetFillColor(colo); |
2135 |
ftof12ya[j]->SetLineWidth(1); |
ftof12ya[j]->SetLineWidth(1); |
2139 |
// B |
// B |
2140 |
s12p = 0.055; |
s12p = 0.055; |
2141 |
TPolyLine *ftof12yb[6]; |
TPolyLine *ftof12yb[6]; |
2142 |
|
rj=6; |
2143 |
for ( Int_t j=0; j<6; j++){ |
for ( Int_t j=0; j<6; j++){ |
2144 |
|
rj--; |
2145 |
Float_t xc1[4]={ (s12p*j), s12p*(j+1), s12p*(j+1), (s12p*j)}; |
Float_t xc1[4]={ (s12p*j), s12p*(j+1), s12p*(j+1), (s12p*j)}; |
2146 |
Float_t yc1[4]={ -ws13, -ws13, 0., -ws13}; |
Float_t yc1[4]={ -ws13, -ws13, 0., -ws13}; |
2147 |
Float_t xc[4]; |
Float_t xc[4]; |
2157 |
} else { |
} else { |
2158 |
colo = 1; |
colo = 1; |
2159 |
}; |
}; |
2160 |
ColorMIP(ms12b[j],colo); |
ColorMIP(ms12b[rj],colo); |
2161 |
// |
// |
2162 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2163 |
if ( mt12[1][j] == 4095. ) colo = noadc; |
if ( mt12[1][rj] == 4095. ) colo = noadc; |
2164 |
// |
// |
2165 |
ftof12yb[j]->SetFillColor(colo); |
ftof12yb[j]->SetFillColor(colo); |
2166 |
ftof12yb[j]->SetLineWidth(1); |
ftof12yb[j]->SetLineWidth(1); |
2194 |
Float_t s21p = 0.075; |
Float_t s21p = 0.075; |
2195 |
ocolo = 10; |
ocolo = 10; |
2196 |
TPolyLine *ftof21ya[2]; |
TPolyLine *ftof21ya[2]; |
2197 |
|
rj=2; |
2198 |
for ( Int_t j=0; j<2; j++){ |
for ( Int_t j=0; j<2; j++){ |
2199 |
|
rj--; |
2200 |
Float_t xc1[4]={ s21p*(j-1), s21p*(j-1), s21p*j, s21p*(j-1)}; |
Float_t xc1[4]={ s21p*(j-1), s21p*(j-1), s21p*j, s21p*(j-1)}; |
2201 |
Float_t yc1[4]={ 0., ws2, ws2, 0.}; |
Float_t yc1[4]={ 0., ws2, ws2, 0.}; |
2202 |
Float_t xc[4]; |
Float_t xc[4]; |
2212 |
} else { |
} else { |
2213 |
colo = 1; |
colo = 1; |
2214 |
}; |
}; |
2215 |
ColorMIP(ms21a[j],colo); |
ColorMIP(ms21a[rj],colo); |
2216 |
// |
// |
2217 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2218 |
if ( mt21[0][j] == 4095. ) colo = noadc; |
if ( mt21[0][rj] == 4095. ) colo = noadc; |
2219 |
// |
// |
2220 |
ftof21ya[j]->SetFillColor(colo); |
ftof21ya[j]->SetFillColor(colo); |
2221 |
ftof21ya[j]->SetLineWidth(1); |
ftof21ya[j]->SetLineWidth(1); |
2225 |
// B |
// B |
2226 |
s21p = 0.075; |
s21p = 0.075; |
2227 |
TPolyLine *ftof21yb[2]; |
TPolyLine *ftof21yb[2]; |
2228 |
|
rj=2; |
2229 |
for ( Int_t j=0; j<2; j++){ |
for ( Int_t j=0; j<2; j++){ |
2230 |
|
rj--; |
2231 |
Float_t xc1[4]={ s21p*(j-1), s21p*j, s21p*j, s21p*(j-1)}; |
Float_t xc1[4]={ s21p*(j-1), s21p*j, s21p*j, s21p*(j-1)}; |
2232 |
Float_t yc1[4]={ 0., 0., ws2, 0.}; |
Float_t yc1[4]={ 0., 0., ws2, 0.}; |
2233 |
Float_t xc[4]; |
Float_t xc[4]; |
2243 |
} else { |
} else { |
2244 |
colo = 1; |
colo = 1; |
2245 |
}; |
}; |
2246 |
ColorMIP(ms21b[j],colo); |
ColorMIP(ms21b[rj],colo); |
2247 |
// |
// |
2248 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2249 |
if ( mt21[1][j] == 4095. ) colo = noadc; |
if ( mt21[1][rj] == 4095. ) colo = noadc; |
2250 |
// |
// |
2251 |
ftof21yb[j]->SetFillColor(colo); |
ftof21yb[j]->SetFillColor(colo); |
2252 |
ftof21yb[j]->SetLineWidth(1); |
ftof21yb[j]->SetLineWidth(1); |
2361 |
Float_t s31p = 0.060; |
Float_t s31p = 0.060; |
2362 |
ocolo = 10; |
ocolo = 10; |
2363 |
TPolyLine *ftof31xa[3]; |
TPolyLine *ftof31xa[3]; |
2364 |
|
rj=3; |
2365 |
for ( Int_t j=0; j<3; j++){ |
for ( Int_t j=0; j<3; j++){ |
2366 |
|
rj--; |
2367 |
Float_t xc1[4]={ (s31p*j), (s31p*j), s31p*(j+1), (s31p*j)}; |
Float_t xc1[4]={ (s31p*j), (s31p*j), s31p*(j+1), (s31p*j)}; |
2368 |
Float_t yc1[4]={ 0., ws13, ws13, 0.}; |
Float_t yc1[4]={ 0., ws13, ws13, 0.}; |
2369 |
Float_t xc[4]; |
Float_t xc[4]; |
2379 |
} else { |
} else { |
2380 |
colo = 1; |
colo = 1; |
2381 |
}; |
}; |
2382 |
ColorMIP(ms31a[j],colo); |
ColorMIP(ms31a[rj],colo); |
2383 |
// |
// |
2384 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2385 |
if ( mt31[0][j] == 4095. ) colo = noadc; |
if ( mt31[0][rj] == 4095. ) colo = noadc; |
2386 |
// |
// |
2387 |
ftof31xa[j]->SetFillColor(colo); |
ftof31xa[j]->SetFillColor(colo); |
2388 |
ftof31xa[j]->SetLineWidth(1); |
ftof31xa[j]->SetLineWidth(1); |
2392 |
// B |
// B |
2393 |
s31p = 0.060; |
s31p = 0.060; |
2394 |
TPolyLine *ftof31xb[3]; |
TPolyLine *ftof31xb[3]; |
2395 |
|
rj=3; |
2396 |
for ( Int_t j=0; j<3; j++){ |
for ( Int_t j=0; j<3; j++){ |
2397 |
|
rj--; |
2398 |
Float_t xc1[4]={ (s31p*j), s31p*(j+1), s31p*(j+1), (s31p*j)}; |
Float_t xc1[4]={ (s31p*j), s31p*(j+1), s31p*(j+1), (s31p*j)}; |
2399 |
Float_t yc1[4]={ 0., 0., ws13, 0.}; |
Float_t yc1[4]={ 0., 0., ws13, 0.}; |
2400 |
Float_t xc[4]; |
Float_t xc[4]; |
2410 |
} else { |
} else { |
2411 |
colo = 1; |
colo = 1; |
2412 |
}; |
}; |
2413 |
ColorMIP(ms31b[j],colo); |
ColorMIP(ms31b[rj],colo); |
2414 |
// |
// |
2415 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2416 |
if ( mt31[1][j] == 4095. ) colo = noadc; |
if ( mt31[1][rj] == 4095. ) colo = noadc; |
2417 |
// |
// |
2418 |
ftof31xb[j]->SetFillColor(colo); |
ftof31xb[j]->SetFillColor(colo); |
2419 |
ftof31xb[j]->SetLineWidth(1); |
ftof31xb[j]->SetLineWidth(1); |
2445 |
Float_t s32p = 0.050; |
Float_t s32p = 0.050; |
2446 |
ocolo = 10; |
ocolo = 10; |
2447 |
TPolyLine *ftof32ya[3]; |
TPolyLine *ftof32ya[3]; |
2448 |
|
rj=3; |
2449 |
for ( Int_t j=0; j<3; j++){ |
for ( Int_t j=0; j<3; j++){ |
2450 |
|
rj--; |
2451 |
Float_t xc1[4]={ (s32p*j), (s32p*j), s32p*(j+1), (s32p*j)}; |
Float_t xc1[4]={ (s32p*j), (s32p*j), s32p*(j+1), (s32p*j)}; |
2452 |
Float_t yc1[4]={ -ws13, 0., 0., -ws13}; |
Float_t yc1[4]={ -ws13, 0., 0., -ws13}; |
2453 |
Float_t xc[4]; |
Float_t xc[4]; |
2463 |
} else { |
} else { |
2464 |
colo = 1; |
colo = 1; |
2465 |
}; |
}; |
2466 |
ColorMIP(ms32a[j],colo); |
ColorMIP(ms32a[rj],colo); |
2467 |
// |
// |
2468 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2469 |
if ( mt32[0][j] == 4095. ) colo = noadc; |
if ( mt32[0][rj] == 4095. ) colo = noadc; |
2470 |
// |
// |
2471 |
ftof32ya[j]->SetFillColor(colo); |
ftof32ya[j]->SetFillColor(colo); |
2472 |
ftof32ya[j]->SetLineWidth(1); |
ftof32ya[j]->SetLineWidth(1); |
2475 |
}; |
}; |
2476 |
s32p = 0.050; |
s32p = 0.050; |
2477 |
TPolyLine *ftof32yb[3]; |
TPolyLine *ftof32yb[3]; |
2478 |
|
rj=3; |
2479 |
for ( Int_t j=0; j<3; j++){ |
for ( Int_t j=0; j<3; j++){ |
2480 |
|
rj--; |
2481 |
Float_t xc1[4]={ (s32p*j), s32p*(j+1), s32p*(j+1), (s32p*j)}; |
Float_t xc1[4]={ (s32p*j), s32p*(j+1), s32p*(j+1), (s32p*j)}; |
2482 |
Float_t yc1[4]={ -ws13, -ws13, 0., -ws13}; |
Float_t yc1[4]={ -ws13, -ws13, 0., -ws13}; |
2483 |
Float_t xc[4]; |
Float_t xc[4]; |
2493 |
} else { |
} else { |
2494 |
colo = 1; |
colo = 1; |
2495 |
}; |
}; |
2496 |
ColorMIP(ms32b[j],colo); |
ColorMIP(ms32b[rj],colo); |
2497 |
// |
// |
2498 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
2499 |
if ( mt32[1][j] == 4095. ) colo = noadc; |
if ( mt32[1][rj] == 4095. ) colo = noadc; |
2500 |
// |
// |
2501 |
ftof32yb[j]->SetFillColor(colo); |
ftof32yb[j]->SetFillColor(colo); |
2502 |
ftof32yb[j]->SetLineWidth(1); |
ftof32yb[j]->SetLineWidth(1); |
2940 |
ftof11y->Draw(); |
ftof11y->Draw(); |
2941 |
TPolyLine *sftof11[8]; |
TPolyLine *sftof11[8]; |
2942 |
tt = 1; |
tt = 1; |
2943 |
if ( level.file == -1 ) tt = 8; |
rj=1; |
2944 |
|
if ( level.file == -1 ){ |
2945 |
|
tt = 8; |
2946 |
|
rj = 8; |
2947 |
|
}; |
2948 |
for ( Int_t j=0; j<tt; j++){ |
for ( Int_t j=0; j<tt; j++){ |
2949 |
if ( (mt11[0][j]<4095. || mt11[1][j]<4095.)){ |
rj--; |
2950 |
|
if ( (mt11[0][rj]<4095. || mt11[1][rj]<4095.)){ |
2951 |
if ( ocolo == 10 ) ocolo = noadc; |
if ( ocolo == 10 ) ocolo = noadc; |
2952 |
Float_t lowp = (xp11[j]-E11[j])/100.; |
Float_t lowp = -(xp11[rj]+E11[rj])/100.; |
2953 |
Float_t higp = (xp11[j]+E11[j])/100.; |
Float_t higp = -(xp11[rj]-E11[rj])/100.; |
2954 |
if ( lowp < -0.164 ) lowp = -0.164; |
if ( lowp < -0.164 ) lowp = -0.164; |
2955 |
if ( higp > 0.164 ) higp = 0.164; |
if ( higp > 0.164 ) higp = 0.164; |
2956 |
if ( lowp < higp && ( level.file == -1 || (level.file == 2 && xp11[j] != 0.))){ |
if ( lowp < higp && ( level.file == -1 || (level.file == 2 && xp11[rj] != 0.))){ |
2957 |
Float_t nxc1[5]={ lowp, higp, higp, lowp, lowp}; |
Float_t nxc1[5]={ lowp, higp, higp, lowp, lowp}; |
2958 |
Float_t nyc1[5]={ 0.0015, 0.0015, ws13-0.0015, ws13-0.0015, 0.0015}; |
Float_t nyc1[5]={ 0.0015, 0.0015, ws13-0.0015, ws13-0.0015, 0.0015}; |
2959 |
Float_t nxc[5]; |
Float_t nxc[5]; |
2978 |
Float_t s12p = 0.055; |
Float_t s12p = 0.055; |
2979 |
ocolo = 10; |
ocolo = 10; |
2980 |
TPolyLine *ftof12y[6]; |
TPolyLine *ftof12y[6]; |
2981 |
|
rj = 6; |
2982 |
for ( Int_t j=0; j<6; j++){ |
for ( Int_t j=0; j<6; j++){ |
2983 |
|
rj--; |
2984 |
Float_t nxc1[5]={ (s12p*j), (s12p*j), s12p*(j+1), s12p*(j+1), (s12p*j)}; |
Float_t nxc1[5]={ (s12p*j), (s12p*j), s12p*(j+1), s12p*(j+1), (s12p*j)}; |
2985 |
Float_t nyc1[5]={ -ws13, 0., 0., -ws13, -ws13}; |
Float_t nyc1[5]={ -ws13, 0., 0., -ws13, -ws13}; |
2986 |
Float_t nxc[5]; |
Float_t nxc[5]; |
2997 |
colo = 1; |
colo = 1; |
2998 |
}; |
}; |
2999 |
if ( level.file == -1 ){ |
if ( level.file == -1 ){ |
3000 |
ColorMIP(ms12a[j]+ms12b[j],colo); |
ColorMIP(ms12a[rj]+ms12b[rj],colo); |
3001 |
} else { |
} else { |
3002 |
ColorTOFMIP(ms12a[j]+ms12b[j],colo); |
ColorTOFMIP(ms12a[rj]+ms12b[rj],colo); |
3003 |
}; |
}; |
3004 |
// |
// |
3005 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
3066 |
Float_t s21p = 0.075; |
Float_t s21p = 0.075; |
3067 |
ocolo = 10; |
ocolo = 10; |
3068 |
TPolyLine *ftof21y[2]; |
TPolyLine *ftof21y[2]; |
3069 |
|
rj=2; |
3070 |
for ( Int_t j=0; j<2; j++){ |
for ( Int_t j=0; j<2; j++){ |
3071 |
|
rj--; |
3072 |
Float_t nxc1[5]={ s21p*(j-1), s21p*(j-1), s21p*j,s21p*j, s21p*(j-1)}; |
Float_t nxc1[5]={ s21p*(j-1), s21p*(j-1), s21p*j,s21p*j, s21p*(j-1)}; |
3073 |
Float_t nyc1[5]={ 0., ws2, ws2, 0., 0.}; |
Float_t nyc1[5]={ 0., ws2, ws2, 0., 0.}; |
3074 |
Float_t nxc[5]; |
Float_t nxc[5]; |
3085 |
colo = 1; |
colo = 1; |
3086 |
}; |
}; |
3087 |
if ( level.file == -1 ){ |
if ( level.file == -1 ){ |
3088 |
ColorMIP(ms21a[j]+ms21b[j],colo); |
ColorMIP(ms21a[rj]+ms21b[rj],colo); |
3089 |
} else { |
} else { |
3090 |
ColorTOFMIP(ms21a[j]+ms21b[j],colo); |
ColorTOFMIP(ms21a[rj]+ms21b[rj],colo); |
3091 |
}; |
}; |
3092 |
// |
// |
3093 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
3204 |
ftof22y->Draw(); |
ftof22y->Draw(); |
3205 |
TPolyLine *sftof22[2]; |
TPolyLine *sftof22[2]; |
3206 |
tt = 1; |
tt = 1; |
3207 |
if ( level.file == -1 ) tt = 2; |
rj = 1; |
3208 |
|
if ( level.file == -1 ){ |
3209 |
|
tt = 2; |
3210 |
|
rj = 2; |
3211 |
|
}; |
3212 |
for (Int_t j=0; j<tt; j++){ |
for (Int_t j=0; j<tt; j++){ |
3213 |
|
rj--; |
3214 |
// for ( Int_t j=0; j<2; j++){ |
// for ( Int_t j=0; j<2; j++){ |
3215 |
if ( (mt22[0][j]<4095. || mt22[1][j]<4095.) ){ |
if ( (mt22[0][rj]<4095. || mt22[1][rj]<4095.) ){ |
3216 |
if ( ocolo == 10 ) ocolo = noadc; |
if ( ocolo == 10 ) ocolo = noadc; |
3217 |
Float_t lowp = (xp22[j]-E22[j])/100.; |
Float_t lowp = -(xp22[rj]+E22[rj])/100.; |
3218 |
Float_t higp = (xp22[j]+E22[j])/100.; |
Float_t higp = -(xp22[rj]-E22[rj])/100.; |
3219 |
if ( lowp < -0.074 ) lowp = -0.074; |
if ( lowp < -0.074 ) lowp = -0.074; |
3220 |
if ( higp > 0.074 ) higp = 0.074; |
if ( higp > 0.074 ) higp = 0.074; |
3221 |
if ( lowp < higp && ( level.file == -1 || (level.file == 2 && xp22[j] != 0.))){ |
if ( lowp < higp && ( level.file == -1 || (level.file == 2 && xp22[rj] != 0.))){ |
3222 |
Float_t nxc1[5]={ lowp, higp, higp, lowp, lowp}; |
Float_t nxc1[5]={ lowp, higp, higp, lowp, lowp}; |
3223 |
Float_t nyc1[5]={ -0.0015, -0.0015, -ws2+0.0015, -ws2+0.0015, -0.0015}; |
Float_t nyc1[5]={ -0.0015, -0.0015, -ws2+0.0015, -ws2+0.0015, -0.0015}; |
3224 |
Float_t nxc[5]; |
Float_t nxc[5]; |
3238 |
}; |
}; |
3239 |
}; |
}; |
3240 |
// |
// |
3241 |
|
//daquiinbasso |
3242 |
// |
// |
3243 |
// S31 X-view |
// S31 X-view |
3244 |
// |
// |
3295 |
ftof31y->Draw(); |
ftof31y->Draw(); |
3296 |
TPolyLine *sftof31[3]; |
TPolyLine *sftof31[3]; |
3297 |
tt = 1; |
tt = 1; |
3298 |
if ( level.file == -1 ) tt = 3; |
rj = 1; |
3299 |
|
if ( level.file == -1 ){ |
3300 |
|
tt = 3; |
3301 |
|
rj = 3; |
3302 |
|
}; |
3303 |
for (Int_t j=0; j<tt; j++){ |
for (Int_t j=0; j<tt; j++){ |
3304 |
|
rj--; |
3305 |
// for ( Int_t j=0; j<3; j++){ |
// for ( Int_t j=0; j<3; j++){ |
3306 |
if ( (mt31[0][j]<4095. || mt31[1][j]<4095.)){ |
if ( (mt31[0][rj]<4095. || mt31[1][rj]<4095.)){ |
3307 |
if ( ocolo == 10 ) ocolo = noadc; |
if ( ocolo == 10 ) ocolo = noadc; |
3308 |
Float_t lowp = (xp31[j]-E31[j])/100.; |
Float_t lowp = -(xp31[rj]+E31[rj])/100.; |
3309 |
Float_t higp = (xp31[j]+E31[j])/100.; |
Float_t higp = -(xp31[rj]-E31[rj])/100.; |
3310 |
if ( lowp < -0.074 ) lowp = -0.074; |
if ( lowp < -0.074 ) lowp = -0.074; |
3311 |
if ( higp > 0.074 ) higp = 0.074; |
if ( higp > 0.074 ) higp = 0.074; |
3312 |
if ( lowp < higp && ( level.file == -1 || (level.file == 2 && xp31[j] != 0.))){ |
if ( lowp < higp && ( level.file == -1 || (level.file == 2 && xp31[rj] != 0.))){ |
3313 |
Float_t nxc1[5]={ lowp, higp, higp, lowp, lowp}; |
Float_t nxc1[5]={ lowp, higp, higp, lowp, lowp}; |
3314 |
Float_t nyc1[5]={ 0.0015, 0.0015, ws13-0.0015, ws13-0.0015, 0.0015}; |
Float_t nyc1[5]={ 0.0015, 0.0015, ws13-0.0015, ws13-0.0015, 0.0015}; |
3315 |
Float_t nxc[5]; |
Float_t nxc[5]; |
3336 |
Float_t s32p = 0.050; |
Float_t s32p = 0.050; |
3337 |
ocolo = 10; |
ocolo = 10; |
3338 |
TPolyLine *ftof32y[3]; |
TPolyLine *ftof32y[3]; |
3339 |
|
rj = 3; |
3340 |
for ( Int_t j=0; j<3; j++){ |
for ( Int_t j=0; j<3; j++){ |
3341 |
|
rj--; |
3342 |
Float_t nxc1[5]={ (s32p*j), (s32p*j), s32p*(j+1),s32p*(j+1), (s32p*j)}; |
Float_t nxc1[5]={ (s32p*j), (s32p*j), s32p*(j+1),s32p*(j+1), (s32p*j)}; |
3343 |
Float_t nyc1[5]={ -ws13, 0., 0., -ws13, -ws13}; |
Float_t nyc1[5]={ -ws13, 0., 0., -ws13, -ws13}; |
3344 |
Float_t nxc[5]; |
Float_t nxc[5]; |
3355 |
colo = 1; |
colo = 1; |
3356 |
}; |
}; |
3357 |
if ( level.file == -1 ){ |
if ( level.file == -1 ){ |
3358 |
ColorMIP(ms32a[j]+ms32b[j],colo); |
ColorMIP(ms32a[rj]+ms32b[rj],colo); |
3359 |
} else { |
} else { |
3360 |
ColorTOFMIP(ms32a[j]+ms32b[j],colo); |
ColorTOFMIP(ms32a[rj]+ms32b[rj],colo); |
3361 |
}; |
}; |
3362 |
// |
// |
3363 |
if ( colo != 10 ) ocolo = colo; |
if ( colo != 10 ) ocolo = colo; |
5071 |
for (Int_t m = 0; m<3; m++){ |
for (Int_t m = 0; m<3; m++){ |
5072 |
if ( trk->signcluster[l][m] != 0. ){ |
if ( trk->signcluster[l][m] != 0. ){ |
5073 |
if ( planeno == 10 ) { |
if ( planeno == 10 ) { |
|
x = 1024 - trk->addrcluster[l][m]; |
|
|
} else { |
|
5074 |
x = trk->addrcluster[l][m]; |
x = trk->addrcluster[l][m]; |
5075 |
|
} else { |
5076 |
|
x = 1024 - trk->addrcluster[l][m]; |
5077 |
}; |
}; |
5078 |
linea = new TLine(14.+x,0.01,14.+x,0.3); |
linea = new TLine(14.+x,0.01,14.+x,0.3); |
5079 |
linea->SetLineWidth(2); |
linea->SetLineWidth(2); |
5143 |
trkpad[planepad]->cd(); |
trkpad[planepad]->cd(); |
5144 |
trkpad[planepad]->Range(-7.05,0.,7.05,8.); |
trkpad[planepad]->Range(-7.05,0.,7.05,8.); |
5145 |
for (Int_t img=0; img<2; img++){ |
for (Int_t img=0; img<2; img++){ |
5146 |
x = singlet->coord[img]; |
x = -singlet->coord[img]; |
5147 |
Float_t xsig = singlet->sgnl; |
Float_t xsig = singlet->sgnl; |
5148 |
if ( xsig > 8. ) xsig = 8.; |
if ( xsig > 8. ) xsig = 8.; |
5149 |
// |
// |
5228 |
planepad = plane * 2; |
planepad = plane * 2; |
5229 |
trkpad[planepad]->cd(); |
trkpad[planepad]->cd(); |
5230 |
trkpad[planepad]->Range(-7.05,0.,7.05,8.); |
trkpad[planepad]->Range(-7.05,0.,7.05,8.); |
5231 |
x = track->ym[plane]; |
x = -track->ym[plane]; |
5232 |
xsig = track->dedx_y[plane]; |
xsig = track->dedx_y[plane]; |
5233 |
if ( track->YGood(plane) ){ |
if ( track->YGood(plane) ){ |
5234 |
// if ( x > -100 ){ |
// if ( x > -100 ){ |
5290 |
for (Int_t plane = 0; plane<6; plane++){ |
for (Int_t plane = 0; plane<6; plane++){ |
5291 |
// |
// |
5292 |
x = track->xm[plane]; |
x = track->xm[plane]; |
5293 |
Float_t y = track->ym[plane]; |
Float_t y = -track->ym[plane]; |
5294 |
Float_t xsig = track->dedx_x[plane]; |
Float_t xsig = track->dedx_x[plane]; |
5295 |
Float_t ysig = track->dedx_y[plane]; |
Float_t ysig = track->dedx_y[plane]; |
5296 |
// if ( x > -100 && y > -100. ){ |
// if ( x > -100 && y > -100. ){ |
5412 |
for (Int_t sing = 0; sing < min(totsx,totsy); sing++){ |
for (Int_t sing = 0; sing < min(totsx,totsy); sing++){ |
5413 |
// |
// |
5414 |
x = arrax->At(orderx->At(sing)); |
x = arrax->At(orderx->At(sing)); |
5415 |
Float_t y1 = array1->At(ordery->At(sing)); |
Float_t y1 = -array1->At(ordery->At(sing)); |
5416 |
Float_t y2 = array2->At(ordery->At(sing)); |
Float_t y2 = -array2->At(ordery->At(sing)); |
5417 |
Float_t xsig = sigarrax->At(orderx->At(sing)); |
Float_t xsig = sigarrax->At(orderx->At(sing)); |
5418 |
Float_t ysig = sigarray->At(ordery->At(sing)); |
Float_t ysig = sigarray->At(ordery->At(sing)); |
5419 |
if ( x > -100 && y1 > -100. ){ |
if ( x > -100 && y1 > -100. ){ |
5506 |
for (Int_t m = 0; m<3; m++){ |
for (Int_t m = 0; m<3; m++){ |
5507 |
if ( trk->signcluster[l][m] != 0. ){ |
if ( trk->signcluster[l][m] != 0. ){ |
5508 |
if ( planeno == 10 ) { |
if ( planeno == 10 ) { |
|
x = 1024 - trk->addrcluster[l][m]; |
|
|
} else { |
|
5509 |
x = trk->addrcluster[l][m]; |
x = trk->addrcluster[l][m]; |
5510 |
|
} else { |
5511 |
|
x = 1024 - trk->addrcluster[l][m]; |
5512 |
}; |
}; |
5513 |
x += 1024.; |
x += 1024.; |
5514 |
if ( trk->signcluster[l][m]> ysig ){ |
if ( trk->signcluster[l][m]> ysig ){ |
5515 |
ysig = trk->signcluster[l][m]; |
ysig = trk->signcluster[l][m]; |
5516 |
yh1[ncro] = x-1024.; |
yh1[ncro] = x - 1024.; |
5517 |
yh2[ncro] = x; |
yh2[ncro] = x; |
5518 |
}; |
}; |
5519 |
}; |
}; |
5541 |
for (Int_t m = 0; m<3; m++){ |
for (Int_t m = 0; m<3; m++){ |
5542 |
if ( trk->signcluster[e][m] != 0. ){ |
if ( trk->signcluster[e][m] != 0. ){ |
5543 |
if ( planeno == 10 ) { |
if ( planeno == 10 ) { |
|
x = 1024 - trk->addrcluster[e][m]; |
|
|
} else { |
|
5544 |
x = trk->addrcluster[e][m]; |
x = trk->addrcluster[e][m]; |
5545 |
|
} else { |
5546 |
|
x = 1024 - trk->addrcluster[e][m]; |
5547 |
}; |
}; |
5548 |
x += 1024.; |
x += 1024.; |
5549 |
if ( trk->signcluster[e][m]> ysig ){ |
if ( trk->signcluster[e][m]> ysig ){ |
5550 |
ysig = trk->signcluster[e][m]; |
ysig = trk->signcluster[e][m]; |
5551 |
yh1[ncro] = x-1024.; |
yh1[ncro] = x - 1024.; |
5552 |
yh2[ncro] = x; |
yh2[ncro] = x; |
5553 |
}; |
}; |
5554 |
}; |
}; |
5621 |
}; |
}; |
5622 |
for (Int_t plane = 0; plane < 22; plane++){ |
for (Int_t plane = 0; plane < 22; plane++){ |
5623 |
calx[plane] = (L2->GetCaloLevel2()->cbar[plane][0]/100.)*var.sfx + var.xxvc;; |
calx[plane] = (L2->GetCaloLevel2()->cbar[plane][0]/100.)*var.sfx + var.xxvc;; |
5624 |
caly[plane] = (L2->GetCaloLevel2()->cbar[plane][1]/100.)*var.sfx + var.xyvc; |
caly[plane] = (-L2->GetCaloLevel2()->cbar[plane][1]/100.)*var.sfx + var.xyvc; |
5625 |
// calzx[plane] = zpiano[plane] -5.81*var.sfy/1000. + var.yxvc; |
// calzx[plane] = zpiano[plane] -5.81*var.sfy/1000. + var.yxvc; |
5626 |
calzx[plane] = zpiano[plane] + var.yxvc; |
calzx[plane] = zpiano[plane] + var.yxvc; |
5627 |
calzy[plane] = zpiano[plane] + var.yyvc; |
calzy[plane] = zpiano[plane] + var.yyvc; |
5670 |
// |
// |
5671 |
for (Int_t plane = 0; plane < 22; plane++){ |
for (Int_t plane = 0; plane < 22; plane++){ |
5672 |
calx[plane] = (ctra->tbar[plane][0]/100.)*var.sfx + var.xxvc;; |
calx[plane] = (ctra->tbar[plane][0]/100.)*var.sfx + var.xxvc;; |
5673 |
caly[plane] = (ctra->tbar[plane][1]/100.)*var.sfx + var.xyvc; |
caly[plane] = (-ctra->tbar[plane][1]/100.)*var.sfx + var.xyvc; |
5674 |
// calzx[plane] = zpiano[plane] -5.81*var.sfy/1000. + var.yxvc; |
// calzx[plane] = zpiano[plane] -5.81*var.sfy/1000. + var.yxvc; |
5675 |
calzx[plane] = zpiano[plane] + var.yxvc; |
calzx[plane] = zpiano[plane] + var.yxvc; |
5676 |
calzy[plane] = zpiano[plane] + var.yyvc; |
calzy[plane] = zpiano[plane] + var.yyvc; |
5762 |
if ( !ifail ){ |
if ( !ifail ){ |
5763 |
for ( Int_t e = 0; e < npoint ; e++) { |
for ( Int_t e = 0; e < npoint ; e++) { |
5764 |
tx[e] = ((float)tr->x[e]/100.)*var.sfx + var.xxvc; |
tx[e] = ((float)tr->x[e]/100.)*var.sfx + var.xxvc; |
5765 |
ty[e] = ((float)tr->y[e]/100.)*var.sfx + var.xyvc; |
ty[e] = (-(float)tr->y[e]/100.)*var.sfx + var.xyvc; |
5766 |
if ( e < 50 ) { |
if ( e < 50 ) { |
5767 |
ptx1[e] = ((float)tr->y[e]/100.)*var.sfx + var.xcat; |
ptx1[e] = (-(float)tr->y[e]/100.)*var.sfx + var.xcat; |
5768 |
pty1[e] = ((float)tr->x[e]/100.)*var.sfy + var.ycat; |
pty1[e] = ((float)tr->x[e]/100.)*var.sfy + var.ycat; |
5769 |
} else { |
} else { |
5770 |
ptx2[e-50] = ((float)tr->y[e]/100.)*var.sfx + var.xcat; |
ptx2[e-50] = (-(float)tr->y[e]/100.)*var.sfx + var.xcat; |
5771 |
pty2[e-50] = ((float)tr->x[e]/100.)*var.sfy + var.ycat; |
pty2[e-50] = ((float)tr->x[e]/100.)*var.sfy + var.ycat; |
5772 |
}; |
}; |
5773 |
if ( e > 84 ) { |
if ( e > 84 ) { |
5774 |
tx1[e-85] = ((float)tr->x[e]/100.)*var.nds4 + var.xxvc; |
tx1[e-85] = ((float)tr->x[e]/100.)*var.nds4 + var.xxvc; |
5775 |
ty1[e-85] = ((float)tr->y[e]/100.)*var.nds4 + var.xyvc; |
ty1[e-85] = (-(float)tr->y[e]/100.)*var.nds4 + var.xyvc; |
5776 |
tzx1[e-85] = (0.112)*var.sfy+((float)zin[e]/100.)*var.sfy + var.yxvc; |
tzx1[e-85] = (0.112)*var.sfy+((float)zin[e]/100.)*var.sfy + var.yxvc; |
5777 |
tzy1[e-85] = (0.112)*var.sfy+((float)zin[e]/100.)*var.sfy + var.yyvc; |
tzy1[e-85] = (0.112)*var.sfy+((float)zin[e]/100.)*var.sfy + var.yyvc; |
5778 |
}; |
}; |
6012 |
Xview->Draw("box same"); |
Xview->Draw("box same"); |
6013 |
}; |
}; |
6014 |
if ( l == 1 ) { |
if ( l == 1 ) { |
6015 |
Yview->Fill(n,21-m,1.); |
Yview->Fill(95-n,21-m,1.); |
6016 |
pd2->cd(); |
pd2->cd(); |
6017 |
Yview->Draw("box same"); |
Yview->Draw("box same"); |
6018 |
}; |
}; |
6241 |
Xview->Draw("box same"); |
Xview->Draw("box same"); |
6242 |
}; |
}; |
6243 |
if ( l == 1 ) { |
if ( l == 1 ) { |
6244 |
Yview->Fill(n,21-m,1.); |
Yview->Fill(96-n,21-m,1.); |
6245 |
pd2->cd(); |
pd2->cd(); |
6246 |
Yview->Draw("box same"); |
Yview->Draw("box same"); |
6247 |
}; |
}; |
6333 |
Int_t l; |
Int_t l; |
6334 |
Int_t m; |
Int_t m; |
6335 |
Int_t n; |
Int_t n; |
6336 |
Float_t mip = L2->GetCaloLevel1()->DecodeEstrip(ii,l,m,n); |
Bool_t satura = false; |
6337 |
|
Float_t mip = L2->GetCaloLevel1()->DecodeEstrip(ii,l,m,n,satura); |
6338 |
if ( var.bw ){ |
if ( var.bw ){ |
6339 |
colo = -1; |
colo = -1; |
6340 |
} else { |
} else { |
6341 |
colo = 1; |
colo = 1; |
6342 |
}; |
}; |
6343 |
ColorMIP(mip,colo); |
ColorMIP(mip,colo); |
6344 |
if ( l == 0 ) { |
if ( l == 0 ) { |
6345 |
xvev.str(""); |
xvev.str(""); |
6348 |
xvev << " " << l; |
xvev << " " << l; |
6349 |
gDirectory->Delete(xvev.str().c_str()); |
gDirectory->Delete(xvev.str().c_str()); |
6350 |
TH2F *Xview = new TH2F(xvev.str().c_str(),"",96,-0.5,95.5,22,-0.5,21.5); |
TH2F *Xview = new TH2F(xvev.str().c_str(),"",96,-0.5,95.5,22,-0.5,21.5); |
6351 |
Xview->SetFillColor(colo); |
if ( satura ){ |
6352 |
|
Xview->SetFillColor(kBlack); |
6353 |
|
} else { |
6354 |
|
Xview->SetFillColor(colo); |
6355 |
|
}; |
6356 |
Xview->Fill(n,21-m,1.); |
Xview->Fill(n,21-m,1.); |
6357 |
pd1->cd(); |
pd1->cd(); |
6358 |
Xview->Draw("box same"); |
Xview->Draw("box same"); |
6364 |
yvev << " " << l; |
yvev << " " << l; |
6365 |
gDirectory->Delete(yvev.str().c_str()); |
gDirectory->Delete(yvev.str().c_str()); |
6366 |
TH2F *Yview = new TH2F(yvev.str().c_str(),"",96,-0.5,95.5,22,-0.5,21.5); |
TH2F *Yview = new TH2F(yvev.str().c_str(),"",96,-0.5,95.5,22,-0.5,21.5); |
6367 |
Yview->SetFillColor(colo); |
if ( satura ){ |
6368 |
Yview->Fill(n,21-m,1.); |
Yview->SetFillColor(kBlack); |
6369 |
|
} else { |
6370 |
|
Yview->SetFillColor(colo); |
6371 |
|
}; |
6372 |
|
Yview->Fill(96-n,21-m,1.); |
6373 |
pd2->cd(); |
pd2->cd(); |
6374 |
Yview->Draw("box same"); |
Yview->Draw("box same"); |
6375 |
}; |
}; |