Changeset 6013 for trunk/MagicSoft
- Timestamp:
- 01/26/05 00:58:00 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mcalib
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mcalib/MCalibColorSet.cc
r6009 r6013 34 34 // 35 35 // Output Containers: 36 // M RawEvtHeader36 // MCalibrationPattern 37 37 // 38 38 ////////////////////////////////////////////////////////////////////////////// … … 48 48 #include "MParList.h" 49 49 50 #include "MRawEvtHeader.h" 50 #include "MCalibrationCam.h" 51 #include "MCalibrationPattern.h" 51 52 #include "MRawRunHeader.h" 52 53 … … 75 76 { 76 77 77 fPattern = 0; 78 fIsValid = kFALSE; 78 fColor = MCalibrationCam::kNONE; 79 fStrength = -1.; 80 fIsValid = kFALSE; 79 81 80 82 } … … 84 86 // 85 87 // The following container are searched for and execution aborted if not in MParList: 86 // - M RawEvtHeader88 // - MCalibrationPattern 87 89 // 88 90 Int_t MCalibColorSet::PreProcess(MParList *pList) 89 91 { 92 93 fPattern = (MCalibrationPattern*)pList->FindObject("MCalibrationPattern"); 94 if (!fPattern) 95 { 96 *fLog << err << "MCalibrationPattern not found... abort." << endl; 97 return kFALSE; 98 } 90 99 91 100 fHeader = (MRawEvtHeader*)pList->FindObject("MRawEvtHeader"); … … 109 118 // repitions of the same piece of code for many many times. 110 119 // 111 void MCalibColorSet::CheckAndSet(const TString &str, const char *regexp, UInt_t &pattern, UInt_t pat, Int_t &color, Int_t col) const120 void MCalibColorSet::CheckAndSet(const TString &str, const char *regexp, MCalibrationCam::PulserColor_t col, Float_t strength) 112 121 { 113 122 if (!str.Contains(TRegexp(regexp))) 114 123 return; 115 124 116 pattern |= pat;117 color= col;125 fStrength = strength; 126 fColor = col; 118 127 } 119 128 … … 159 168 return kTRUE; 160 169 } 161 162 enum { kNONE, kGREEN, kBLUE, kUV, kCT1 }; 163 164 enum ColorCode_t 165 { 166 k01LedGreen = BIT(15), 167 k1LedGreen = BIT(14), 168 k2LedGreen = BIT(1 ), 169 k3LedGreen = k1LedGreen | k2LedGreen, 170 k5LedGreen = BIT(0 ), 171 k6LedGreen = k5LedGreen | k1LedGreen, 172 k7LedGreen = k5LedGreen | k2LedGreen, 173 k8LedGreen = k5LedGreen | k3LedGreen, 174 k1LedUV = BIT(3 ), 175 k2LedUV = BIT(4 ), 176 k3LedUV = k1LedUV | k2LedUV, 177 k5LedUV1 = BIT(11), 178 k5LedUV2 = BIT(12), 179 k6LedUV = k5LedUV1 | k1LedUV, 180 k7LedUV = k5LedUV1 | k2LedUV, 181 k8LedUV = k5LedUV1 | k3LedUV, 182 k10LedUV = k5LedUV1 | k5LedUV2, 183 k11LedUV = k10LedUV | k1LedUV, 184 k12LedUV = k10LedUV | k2LedUV, 185 k13LedUV = k10LedUV | k1LedUV, 186 k01LedBlue = BIT(8 ), 187 k1LedBlue = BIT(10), 188 k2LedBlue = BIT(7 ), 189 k3LedBlue = k1LedBlue | k2LedBlue, 190 k5LedBlue1 = BIT(13), 191 k5LedBlue2 = BIT(2 ), 192 k5LedBlue3 = BIT(5 ), 193 k5LedBlue4 = BIT(6 ), 194 k6LedBlue = k5LedBlue1 | k1LedBlue, 195 k7LedBlue = k5LedBlue1 | k2LedBlue, 196 k8LedBlue = k5LedBlue1 | k3LedBlue, 197 k10LedBlue = k5LedBlue1 | k5LedBlue2, 198 k15LedBlue = k10LedBlue | k5LedBlue3, 199 k20LedBlue = k15LedBlue | k5LedBlue4, 200 k21LedBlue = k20LedBlue | k1LedBlue, 201 k22LedBlue = k20LedBlue | k2LedBlue, 202 k23LedBlue = k22LedBlue | k1LedBlue, 203 kCT1Pulser = BIT(16) 204 }; 205 170 206 171 const Int_t num = header->GetRunNumber(); 207 172 … … 209 174 { 210 175 *fLog << inf << "Assumed MC run ... using GREEN pulser." << endl; 211 f Pattern |= k1LedGreen;176 fColor = MCalibrationCam::kGREEN; 212 177 fIsValid = kTRUE; 213 178 return kTRUE; … … 217 182 { 218 183 *fLog << inf << "Run taken before inauguration of IFAE-box... using CT1 pulser." << endl; 219 fPattern |= kCT1Pulser; 184 fColor = MCalibrationCam::kCT1; 185 fStrength = 10.; 220 186 fIsValid = kTRUE; 221 187 return kTRUE; 222 188 } 223 189 224 Int_t color = kNONE; 225 fPattern = 0; 190 fColor = MCalibrationCam::kNONE; 191 fStrength = 0.; 192 fPattern = 0; 226 193 227 194 switch (num) … … 267 234 case 45607: 268 235 // case 31756: 269 color =kBLUE;236 fColor = MCalibrationCam::kBLUE; 270 237 break; 271 238 … … 294 261 case 45373: 295 262 case 45608: 296 color =kGREEN;263 fColor = MCalibrationCam::kGREEN; 297 264 break; 298 265 … … 327 294 case 45614: 328 295 case 45618: 329 color =kUV;330 break; 331 296 fColor = MCalibrationCam::kUV; 297 break; 298 332 299 case 43914: 333 300 case 43916: … … 335 302 case 43920: 336 303 case 43922: 337 color =kCT1;304 fColor = MCalibrationCam::kCT1; 338 305 break; 339 306 … … 365 332 } 366 333 367 if ( color!=kNONE)334 if (fColor != MCalibrationCam::kNONE) 368 335 { 369 336 *fLog << inf << "Color determined from the run-number... "; 370 switch ( color)337 switch (fColor) 371 338 { 372 case kGREEN: *fLog << "Green."; fPattern |= k5LedGreen; break; 373 case kBLUE: *fLog << "Blue."; fPattern |= k5LedBlue1; break; 374 case kUV: *fLog << "UV."; fPattern |= k10LedUV; break; 375 case kCT1: *fLog << "CT1."; fPattern |= kCT1Pulser; break; 339 case MCalibrationCam::kGREEN: *fLog << "Green."; break; 340 case MCalibrationCam::kBLUE: *fLog << "Blue."; break; 341 case MCalibrationCam::kUV: *fLog << "UV."; break; 342 case MCalibrationCam::kCT1: *fLog << "CT1."; break; 343 default: break; 376 344 } 377 345 *fLog << endl; … … 384 352 385 353 // Possible green combinations 386 CheckAndSet(proj, "0.1led[s]?gree", fPattern, k01LedGreen, color, kGREEN);387 CheckAndSet(proj, "1led[s]?gree", fPattern, k1LedGreen, color, kGREEN);388 CheckAndSet(proj, "2led[s]?gree", fPattern, k2LedGreen, color, kGREEN);389 CheckAndSet(proj, "3led[s]?gree", fPattern, k3LedGreen, color, kGREEN);390 CheckAndSet(proj, "5led[s]?gree", fPattern, k5LedGreen, color, kGREEN);391 CheckAndSet(proj, "6led[s]?gree", fPattern, k6LedGreen, color, kGREEN);392 CheckAndSet(proj, "7led[s]?gree", fPattern, k7LedGreen, color, kGREEN);393 CheckAndSet(proj, "8led[s]?gree", fPattern, k8LedGreen, color, kGREEN);354 CheckAndSet(proj, "0.1led[s]?gree", MCalibrationCam::kGREEN, 0.1); 355 CheckAndSet(proj, "1led[s]?gree", MCalibrationCam::kGREEN, 1. ); 356 CheckAndSet(proj, "2led[s]?gree", MCalibrationCam::kGREEN, 2. ); 357 CheckAndSet(proj, "3led[s]?gree", MCalibrationCam::kGREEN, 3. ); 358 CheckAndSet(proj, "5led[s]?gree", MCalibrationCam::kGREEN, 5. ); 359 CheckAndSet(proj, "6led[s]?gree", MCalibrationCam::kGREEN, 6. ); 360 CheckAndSet(proj, "7led[s]?gree", MCalibrationCam::kGREEN, 7. ); 361 CheckAndSet(proj, "8led[s]?gree", MCalibrationCam::kGREEN, 8. ); 394 362 395 363 // Possible blue combinations 396 CheckAndSet(proj, "0.1led[s]?blue", fPattern, k01LedBlue, color, kBLUE);397 CheckAndSet(proj, "1led[s]?blue", fPattern, k1LedBlue, color, kBLUE);398 CheckAndSet(proj, "2led[s]?blue", fPattern, k2LedBlue, color, kBLUE);399 CheckAndSet(proj, "3led[s]?blue", fPattern, k3LedBlue, color, kBLUE);400 CheckAndSet(proj, "5led[s]?blue", fPattern, k5LedBlue1, color, kBLUE);401 CheckAndSet(proj, "6led[s]?blue", fPattern, k6LedBlue, color, kBLUE);402 CheckAndSet(proj, "7led[s]?blue", fPattern, k7LedBlue, color, kBLUE);403 CheckAndSet(proj, "8led[s]?blue", fPattern, k8LedBlue, color, kBLUE);404 CheckAndSet(proj, "10led[s]?blue", fPattern, k10LedBlue, color, kBLUE);405 CheckAndSet(proj, "15led[s]?blue", fPattern, k15LedBlue, color, kBLUE);406 CheckAndSet(proj, "20led[s]?blue", fPattern, k20LedBlue, color, kBLUE);407 CheckAndSet(proj, "21led[s]?blue", fPattern, k21LedBlue, color, kBLUE);408 CheckAndSet(proj, "22led[s]?blue", fPattern, k22LedBlue, color, kBLUE);409 CheckAndSet(proj, "23led[s]?blue", fPattern, k23LedBlue, color, kBLUE);364 CheckAndSet(proj, "0.1led[s]?blue", MCalibrationCam::kBLUE, 0.1); 365 CheckAndSet(proj, "1led[s]?blue", MCalibrationCam::kBLUE, 1.); 366 CheckAndSet(proj, "2led[s]?blue", MCalibrationCam::kBLUE, 2.); 367 CheckAndSet(proj, "3led[s]?blue", MCalibrationCam::kBLUE, 3.); 368 CheckAndSet(proj, "5led[s]?blue", MCalibrationCam::kBLUE, 5.); 369 CheckAndSet(proj, "6led[s]?blue", MCalibrationCam::kBLUE, 6.); 370 CheckAndSet(proj, "7led[s]?blue", MCalibrationCam::kBLUE, 7.); 371 CheckAndSet(proj, "8led[s]?blue", MCalibrationCam::kBLUE, 8.); 372 CheckAndSet(proj, "10led[s]?blue", MCalibrationCam::kBLUE, 10.); 373 CheckAndSet(proj, "15led[s]?blue", MCalibrationCam::kBLUE, 15.); 374 CheckAndSet(proj, "20led[s]?blue", MCalibrationCam::kBLUE, 20.); 375 CheckAndSet(proj, "21led[s]?blue", MCalibrationCam::kBLUE, 21.); 376 CheckAndSet(proj, "22led[s]?blue", MCalibrationCam::kBLUE, 22.); 377 CheckAndSet(proj, "23led[s]?blue", MCalibrationCam::kBLUE, 23.); 410 378 411 379 // Possible UV combinations 412 CheckAndSet(proj, "1led[s]?uv", fPattern, k1LedUV, color, kUV);413 CheckAndSet(proj, "2led[s]?uv", fPattern, k2LedUV, color, kUV);414 CheckAndSet(proj, "3led[s]?uv", fPattern, k3LedUV, color, kUV);415 CheckAndSet(proj, "5led[s]?uv", fPattern, k5LedUV1, color, kUV);416 CheckAndSet(proj, "6led[s]?uv", fPattern, k6LedUV, color, kUV);417 CheckAndSet(proj, "7led[s]?uv", fPattern, k7LedUV, color, kUV);418 CheckAndSet(proj, "8led[s]?uv", fPattern, k8LedUV, color, kUV);419 CheckAndSet(proj, "10led[s]?uv", fPattern, k10LedUV, color, kUV);420 CheckAndSet(proj, "11led[s]?uv", fPattern, k11LedUV, color, kUV);421 CheckAndSet(proj, "12led[s]?uv", fPattern, k12LedUV, color, kUV);422 CheckAndSet(proj, "13led[s]?uv", fPattern, k13LedUV, color, kUV);380 CheckAndSet(proj, "1led[s]?uv", MCalibrationCam::kUV, 1.); 381 CheckAndSet(proj, "2led[s]?uv", MCalibrationCam::kUV, 2.); 382 CheckAndSet(proj, "3led[s]?uv", MCalibrationCam::kUV, 3.); 383 CheckAndSet(proj, "5led[s]?uv", MCalibrationCam::kUV, 5.); 384 CheckAndSet(proj, "6led[s]?uv", MCalibrationCam::kUV, 6.); 385 CheckAndSet(proj, "7led[s]?uv", MCalibrationCam::kUV, 7.); 386 CheckAndSet(proj, "8led[s]?uv", MCalibrationCam::kUV, 8.); 387 CheckAndSet(proj, "10led[s]?uv", MCalibrationCam::kUV, 10.); 388 CheckAndSet(proj, "11led[s]?uv", MCalibrationCam::kUV, 11.); 389 CheckAndSet(proj, "12led[s]?uv", MCalibrationCam::kUV, 12.); 390 CheckAndSet(proj, "13led[s]?uv", MCalibrationCam::kUV, 13.); 423 391 424 392 // Possible slot combinations … … 439 407 nr = atoi(proj.Data())-1; 440 408 441 fPattern |= BIT(nr); 442 443 color = nr < 2 ? kGREEN : 444 ( nr < 3 ) ? kBLUE : 445 ( nr < 5 ) ? kUV : 446 ( nr < 11 ) ? kBLUE : 447 ( nr < 13 ) ? kUV : 448 ( nr < 14 ) ? kBLUE : 449 ( nr < 16 ) ? kGREEN : 450 kCT1; 409 fColor = nr < 2 ? MCalibrationCam::kGREEN : 410 ( nr < 3 ) ? MCalibrationCam::kBLUE : 411 ( nr < 5 ) ? MCalibrationCam::kUV : 412 ( nr < 11 ) ? MCalibrationCam::kBLUE : 413 ( nr < 13 ) ? MCalibrationCam::kUV : 414 ( nr < 14 ) ? MCalibrationCam::kBLUE : 415 ( nr < 16 ) ? MCalibrationCam::kGREEN : 416 MCalibrationCam::kCT1; 417 418 switch (nr) 419 { 420 case 0: 421 fStrength = 5; 422 break; 423 case 1: 424 fStrength = 2.; 425 break; 426 case 2: 427 fStrength = 5.; 428 break; 429 case 3: 430 fStrength = 1.; 431 break; 432 case 4: 433 fStrength = 2.; 434 break; 435 case 5: 436 fStrength = 5.; 437 break; 438 case 6: 439 fStrength = 5.; 440 break; 441 case 7: 442 fStrength = 2.; 443 break; 444 case 8: 445 fStrength = 0.2; 446 break; 447 case 9: 448 fStrength = 0.; 449 break; 450 case 10: 451 fStrength = 1.; 452 break; 453 case 11: 454 fStrength = 5.; 455 break; 456 case 12: 457 fStrength = 5.; 458 break; 459 case 13: 460 fStrength = 5.; 461 break; 462 case 14: 463 fStrength = 1; 464 break; 465 case 15: 466 fStrength = 0.2; 467 break; 468 } 451 469 } 452 470 } 453 471 454 if ( color ==kNONE)472 if (fColor == MCalibrationCam::kNONE) 455 473 { 456 CheckAndSet(proj, "gree", fPattern, k5LedGreen, color, kGREEN);457 CheckAndSet(proj, "blue", fPattern, k5LedBlue1, color, kBLUE);458 CheckAndSet(proj, "uv", fPattern, k5LedUV1, color, kUV);459 CheckAndSet(proj, "ct1", fPattern, kCT1Pulser, color, kCT1);460 461 if ( color !=kNONE)474 CheckAndSet(proj, "gree", MCalibrationCam::kGREEN, 1.); 475 CheckAndSet(proj, "blue", MCalibrationCam::kBLUE, 1.); 476 CheckAndSet(proj, "uv", MCalibrationCam::kUV, 1.); 477 CheckAndSet(proj, "ct1", MCalibrationCam::kCT1, 1.); 478 479 if (fColor != MCalibrationCam::kNONE) 462 480 *fLog << inf << "Color determined from project-name (" << proj << ")... "; 463 481 else … … 473 491 *fLog << inf << "Color and Intensity determined from project-name (" << proj << ")... "; 474 492 475 if ( color ==kNONE)493 if (fColor == MCalibrationCam::kNONE) 476 494 { 477 495 *fLog << err; … … 482 500 } 483 501 484 switch ( color)502 switch (fColor) 485 503 { 486 case kGREEN: *fLog << "Green."; break; 487 case kBLUE: *fLog << "Blue."; break; 488 case kUV: *fLog << "UV."; break; 489 case kCT1: *fLog << "CT1."; break; 504 case MCalibrationCam::kGREEN: *fLog << "Green."; break; 505 case MCalibrationCam::kBLUE: *fLog << "Blue."; break; 506 case MCalibrationCam::kUV: *fLog << "UV."; break; 507 case MCalibrationCam::kCT1: *fLog << "CT1."; break; 508 default: break; 490 509 } 491 510 *fLog << endl; … … 498 517 // -------------------------------------------------------------------------- 499 518 // 500 // Sets the pattern to M RawEvtHeaderfrom outside, if fIsValid is set.519 // Sets the pattern to MCalibrationPattern from outside, if fIsValid is set. 501 520 // 502 521 Int_t MCalibColorSet::Process() … … 505 524 if (fIsValid) 506 525 { 507 if (f Pattern == 0)526 if (fColor == MCalibrationCam::kNONE) 508 527 return kCONTINUE; 509 528 510 fHeader->SetCalibrationPattern(fPattern); 529 fPattern->SetPulserColor(fColor); 530 fPattern->SetPulserStrength(fStrength); 511 531 } 512 532 -
trunk/MagicSoft/Mars/mcalib/MCalibColorSet.h
r5690 r6013 6 6 #endif 7 7 8 #ifndef MARS_MCalibrationCam 9 #include "MCalibrationCam.h" 10 #endif 11 8 12 class MParList; 13 class MCalibrationPattern; 9 14 class MRawEvtHeader; 10 15 … … 17 22 static const UInt_t gkFirstRunWithFinalBits; //! Run number of first functionning digital modules 18 23 19 MRawEvtHeader *fHeader; //! Event header with the pulse pattern information 24 MCalibrationPattern *fPattern; //! Calibration Pattern with the pulse pattern information 25 MRawEvtHeader *fHeader; //! Event header with the project name 20 26 21 UInt_t fPattern; // Current pulse pattern22 Bool_t fIsValid; // Have to set the pulse pattern?27 MCalibrationCam::PulserColor_t fColor; // Pulser Color to be set 28 Float_t fStrength; // Pulser Strength to be set 23 29 24 void CheckAndSet(const TString &str, const char *regexp, UInt_t &pattern, UInt_t pat, Int_t &color, Int_t col) const; 30 Bool_t fIsValid; // Have to set the pulse pattern? 31 32 void CheckAndSet(const TString &str, const char *regexp, MCalibrationCam::PulserColor_t col, Float_t strength); 25 33 26 34 Bool_t ReInit(MParList *pList); -
trunk/MagicSoft/Mars/mcalib/MCalibColorSteer.cc
r5679 r6013 30 30 // 31 31 // Input Containers: 32 // M RawEvtHeader32 // MCalibrationPattern 33 33 // MParList 34 34 // MCalibrationIntensityChargeCam … … 66 66 #include "MRawRunHeader.h" 67 67 #include "MRawEvtHeader.h" 68 #include "MCalibrationPattern.h" 68 69 69 70 #include "MGeomCam.h" … … 78 79 // 79 80 MCalibColorSteer::MCalibColorSteer(const char *name, const char *title) 80 : f Header(NULL), fGeom(NULL), fParList(NULL),81 : fCalibPattern(NULL), fGeom(NULL), fParList(NULL), 81 82 fIntensCharge(NULL), fIntensRelTime(NULL), fIntensBad(NULL), 82 83 fBad(NULL), fChargeCalc(NULL), fRelTimeCalc(NULL), fPattern(0) … … 91 92 // 92 93 // The following container are searched for and execution aborted if not in MParList: 93 // - M RawEvtHeader94 // - MCalibrationPattern 94 95 // - MTaskList 95 96 // … … 97 98 { 98 99 99 fHeader = (MRawEvtHeader*)pList->FindObject("MRawEvtHeader"); 100 if (!fHeader) 100 fCalibPattern = (MCalibrationPattern*)pList->FindObject("MCalibrationPattern"); 101 if (!fCalibPattern) 102 { 103 *fLog << err << "MCalibrationPattern not found... abort." << endl; 104 return kFALSE; 105 } 106 107 fRunHeader = (MRawRunHeader*)pList->FindObject("MRawRunHeader"); 108 if (!fRunHeader) 109 { 110 *fLog << err << "MRawRunHeader not found... abort." << endl; 111 return kFALSE; 112 } 113 114 fEvtHeader = (MRawEvtHeader*)pList->FindObject("MRawEvtHeader"); 115 if (!fEvtHeader) 101 116 { 102 117 *fLog << err << "MRawEvtHeader not found... abort." << endl; 103 return kFALSE;104 }105 106 fRunHeader = (MRawRunHeader*)pList->FindObject("MRawRunHeader");107 if (!fHeader)108 {109 *fLog << err << "MRawRunHeader not found... abort." << endl;110 118 return kFALSE; 111 119 } … … 226 234 // -------------------------------------------------------------------------- 227 235 // 228 // Reads the pattern from M RawEvtHeaderand initializes new containers in the236 // Reads the pattern from MCalibrationPattern and initializes new containers in the 229 237 // Intensity Cams, if the pattern has changed. Executes Finalize of the 230 238 // MCalibration*Calc classes in that case. … … 233 241 { 234 242 235 const UInt_t pattern = f Header->GetPulserSlotPattern();243 const UInt_t pattern = fEvtHeader->GetPulserSlotPattern(); 236 244 237 245 if (fPattern == 0) … … 290 298 hist->Finalize(); 291 299 hist->ResetHists(); 292 hist->SetColor( f Header->GetPulserColor());300 hist->SetColor( fCalibPattern->GetPulserColor()); 293 301 return kTRUE; 294 302 } … … 322 330 fIntensCharge->AddToList(Form("MCalibrationChargeCam%s",namep.Data()),*fGeom); 323 331 MCalibrationCam *cam = fIntensCharge->GetCam(); 324 cam->SetPulserColor(f Header->GetPulserColor());332 cam->SetPulserColor(fCalibPattern->GetPulserColor()); 325 333 *fLog << inf << "New MCalibrationChargeCam with name: " << cam->GetName() << endl; 326 334 } … … 335 343 fIntensBlind->AddToList(Form("MCalibrationBlindCam%s",namep.Data()),*fGeom); 336 344 MCalibrationCam *cam = fIntensBlind->GetCam(); 337 cam->SetPulserColor(f Header->GetPulserColor());345 cam->SetPulserColor(fCalibPattern->GetPulserColor()); 338 346 *fLog << inf << "New MCalibrationBlindCam with name: " << cam->GetName() << endl; 339 347 } … … 343 351 fIntensRelTime->AddToList(Form("MCalibrationRelTimeCam%s",namep.Data()),*fGeom); 344 352 MCalibrationCam *cam = fIntensRelTime->GetCam(); 345 cam->SetPulserColor(f Header->GetPulserColor());353 cam->SetPulserColor(fCalibPattern->GetPulserColor()); 346 354 *fLog << inf << "New MCalibrationRelTimeCam with name: " << cam->GetName() << endl; 347 355 } … … 354 362 { 355 363 356 const Float_t strength = f Header->GetPulserStrength();357 const MCalibrationCam::PulserColor_t col = f Header->GetPulserColor();364 const Float_t strength = fCalibPattern->GetPulserStrength(); 365 const MCalibrationCam::PulserColor_t col = fCalibPattern->GetPulserColor(); 358 366 359 367 TString result = Form("%2.1f",strength); -
trunk/MagicSoft/Mars/mcalib/MCalibColorSteer.h
r5678 r6013 8 8 class MParList; 9 9 class MGeomCam; 10 class MCalibrationPattern; 11 class MRawRunHeader; 10 12 class MRawEvtHeader; 11 class MRawRunHeader;12 13 class MCalibrationChargeCalc; 13 14 class MCalibrationRelTimeCalc; … … 22 23 private: 23 24 24 MRawEvtHeader *fHeader; //! 25 26 MCalibrationPattern *fCalibPattern; //! 27 MRawEvtHeader *fEvtHeader; //! 25 28 MRawRunHeader *fRunHeader; //! 26 29 MGeomCam *fGeom; //! -
trunk/MagicSoft/Mars/mcalib/MCalibrationChargeCalc.cc
r5984 r6013 194 194 #include "MStatusDisplay.h" 195 195 196 #include "M RawEvtHeader.h"196 #include "MCalibrationPattern.h" 197 197 198 198 #include "MGeomCam.h" … … 271 271 // 272 272 MCalibrationChargeCalc::MCalibrationChargeCalc(const char *name, const char *title) 273 : fGeom(NULL), fSignal(NULL), f EvtHeader(NULL)273 : fGeom(NULL), fSignal(NULL), fCalibPattern(NULL) 274 274 { 275 275 … … 350 350 // The following container are searched for and execution aborted if not in MParList: 351 351 // - MPedestalCam 352 // - M RawEvtHeader352 // - MCalibrationPattern 353 353 // - MExtractedSignalCam 354 354 // … … 368 368 */ 369 369 370 f EvtHeader = (MRawEvtHeader*)pList->FindObject("MRawEvtHeader");371 if (!f EvtHeader)372 { 373 *fLog << err << "M RawEvtHeadernot found... abort." << endl;370 fCalibPattern = (MCalibrationPattern*)pList->FindObject("MCalibrationPattern"); 371 if (!fCalibPattern) 372 { 373 *fLog << err << "MCalibrationPattern not found... abort." << endl; 374 374 return kFALSE; 375 375 } … … 586 586 } 587 587 */ 588 const MCalibrationCam::PulserColor_t col = f EvtHeader->GetPulserColor();588 const MCalibrationCam::PulserColor_t col = fCalibPattern->GetPulserColor(); 589 589 590 590 if (col == fPulserColor) … … 639 639 } 640 640 641 *fLog << inf << " with strength: " << f EvtHeader->GetPulserStrength() << endl;641 *fLog << inf << " with strength: " << fCalibPattern->GetPulserStrength() << endl; 642 642 643 643 fHCam->SetColor(col); -
trunk/MagicSoft/Mars/mcalib/MCalibrationChargeCalc.h
r5852 r6013 27 27 #endif 28 28 29 class M RawEvtHeader;29 class MCalibrationPattern; 30 30 class MPedestalCam; 31 31 class MPedestalPix; … … 44 44 class MBadPixelsIntensityCam; 45 45 class MBadPixelsCam; 46 class MTime;47 46 48 47 class MCalibrationChargeCalc : public MTask … … 102 101 MGeomCam *fGeom; //! Camera geometry 103 102 MExtractedSignalCam *fSignal; //! Extracted Signal 104 M RawEvtHeader *fEvtHeader; //! Evt header103 MCalibrationPattern *fCalibPattern; //! Calibration DM pattern 105 104 MPedestalCam *fPedestals; //! Pedestals all pixels (calculated previously from ped.file) 106 105 -
trunk/MagicSoft/Mars/mcalib/MCalibrationPattern.h
r6004 r6013 35 35 }; 36 36 37 enum PulserColorCode_t38 {39 kSlot1Green = BIT(0),40 kSlot2Green = BIT(1),41 kSlot3Blue = BIT(2),42 kSlot4UV = BIT(3),43 kSlot5UV = BIT(4),44 kSlot6Blue = BIT(5),45 kSlot7Blue = BIT(6),46 kSlot8Blue = BIT(7),47 kSlot9AttBlue = BIT(8),48 kSlot10Blue = BIT(9),49 kSlot11Blue = BIT(10),50 kSlot12UV = BIT(11),51 kSlot13UV = BIT(12),52 kSlot14Blue = BIT(13),53 kSlot15Green = BIT(14),54 kSlot16AttGreen = BIT(15),55 kCT1Pulser = BIT(16),56 kAnyGreen = kSlot1Green | kSlot2Green | kSlot15Green | kSlot16AttGreen,57 kAnyUV = kSlot4UV | kSlot5UV | kSlot12UV | kSlot13UV,58 kAnyBlue = kSlot3Blue | kSlot6Blue | kSlot7Blue | kSlot8Blue59 | kSlot9AttBlue| kSlot10Blue | kSlot11Blue | kSlot14Blue,60 kGreenAndBlue = kAnyGreen & kAnyBlue,61 kBlueAndUV = kAnyBlue & kAnyUV,62 kGreenAndUV = kAnyGreen & kAnyUV,63 kIFAEPulser = kAnyGreen | kAnyBlue | kAnyUV,64 kAny = kAnyGreen | kAnyBlue | kAnyUV | kCT1Pulser65 };66 67 37 private: 68 38
Note:
See TracChangeset
for help on using the changeset viewer.