//*-- AUTHOR : J. Markert //_HADES_CLASS_DESCRIPTION //////////////////////////////////////////////////////////////////////////// // HOnlineShowerHistFiller // // Container class for the shower hists //////////////////////////////////////////////////////////////////////////// //#include #include "honlineshowerhistfiller.h" #include "hparamlist.h" #include "honlinemonhist.h" #include "honlinetrendhist.h" #include "honlinehistarray.h" #include "honlineshowerconfig.h" #include "showerdef.h" #include "hshowerraw.h" #include "hshowercal.h" #include "hshowerhit.h" #include "hades.h" #include "hevent.h" #include "hcategory.h" #include "TList.h" #include "TArrayI.h" #include "TString.h" #define RAW 0 #define CAL 1 #define HIT 2 // Color definitions TArrayI HOnlineShowerHistFiller::colorsSector; TArrayI HOnlineShowerHistFiller::colorsModule; TArrayI HOnlineShowerHistFiller::colorsCuts; // Hist Pointers HOnlineMonHist2* HOnlineShowerHistFiller::hhitsRaw=0; HOnlineMonHist2* HOnlineShowerHistFiller::hhitsCal=0; HOnlineMonHist2* HOnlineShowerHistFiller::hhitsHit=0; HOnlineMonHist* HOnlineShowerHistFiller::hCalCol=0; HOnlineMonHist* HOnlineShowerHistFiller::hCalRow=0; HOnlineMonHist* HOnlineShowerHistFiller::hRawMultTemp=0; HOnlineTrendHist* HOnlineShowerHistFiller::hRawMultTrend=0; HOnlineMonHist* HOnlineShowerHistFiller::hCalMultTemp=0; HOnlineTrendHist* HOnlineShowerHistFiller::hCalMultTrend=0; HOnlineMonHist* HOnlineShowerHistFiller::hHitMultTemp=0; HOnlineHistArray* HOnlineShowerHistFiller::hSumTemp=0; HOnlineTrendHist* HOnlineShowerHistFiller::hHitMultTrend=0; HOnlineTrendArray* HOnlineShowerHistFiller::hMultTrend=0; HOnlineTrendArray* HOnlineShowerHistFiller::hSumTrend_0=0; HOnlineTrendArray* HOnlineShowerHistFiller::hSumTrend_1=0; HOnlineTrendArray* HOnlineShowerHistFiller::hSumTrend_2=0; HOnlineTrendArray* HOnlineShowerHistFiller::hSumTrend_3=0; HOnlineTrendArray* HOnlineShowerHistFiller::hSumTrend_4=0; HOnlineTrendArray* HOnlineShowerHistFiller::hSumTrend_5=0; HOnlineHistArray* HOnlineShowerHistFiller::hSums_0=0; //! HOnlineHistArray* HOnlineShowerHistFiller::hSums_1=0; //! HOnlineHistArray* HOnlineShowerHistFiller::hSums_2=0; //! HOnlineHistArray* HOnlineShowerHistFiller::hSums_3=0; //! HOnlineHistArray* HOnlineShowerHistFiller::hSums_4=0; //! HOnlineHistArray* HOnlineShowerHistFiller::hSums_5=0; //! HOnlineHistArray* HOnlineShowerHistFiller::hCalRows[3]={0,0,0}; //! HOnlineHistArray* HOnlineShowerHistFiller::hCalCols[3]={0,0,0}; //! HOnlineMonHist2* HOnlineShowerHistFiller::hshowermult_raw=0; HOnlineMonHist2* HOnlineShowerHistFiller::hshowermulttemp_raw=0; HOnlineTrendArray* HOnlineShowerHistFiller::hshowermulttrend_raw=0; // Hist Addon Pointers HOnlineMonHistAddon* HOnlineShowerHistFiller::hhitsRawA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hhitsCalA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hhitsHitA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hCalRowA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hCalColA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hRawMultTempA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hRawMultTrendA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hCalMultTempA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hCalMultTrendA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hHitMultTempA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hHitMultTrendA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hMultTrendA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumTempA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumTrendA_0=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumTrendA_1=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumTrendA_2=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumTrendA_3=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumTrendA_4=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumTrendA_5=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumsA_0=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumsA_1=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumsA_2=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumsA_3=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumsA_4=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hSumsA_5=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hCalRowsA[3]={0,0,0}; HOnlineMonHistAddon* HOnlineShowerHistFiller::hCalColsA[3]={0,0,0}; HOnlineMonHistAddon* HOnlineShowerHistFiller::hshowermult_rawA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hshowermulttemp_rawA=0; HOnlineMonHistAddon* HOnlineShowerHistFiller::hshowermulttrend_rawA=0; ClassImp(HOnlineShowerHistFiller) HOnlineShowerHistFiller::HOnlineShowerHistFiller(const Char_t* name,const Char_t* title) : TNamed(name,title) { colorsSector.Set(6); colorsModule.Set(3); colorsCuts.Set(4); showerconfig = new HOnlineShowerConfig("ShowerConfig","ShowerConfig"); } HOnlineShowerHistFiller::~HOnlineShowerHistFiller() { if(showerconfig)delete showerconfig; } void HOnlineShowerHistFiller::fillRaw(HShowerRaw* raw) { Int_t loc[4] = {raw->getSector(),raw->getModule(),raw->getRow(),raw->getCol()}; //Int_t col =raw->getCol(); //Float_t charge=raw->getCharge(); showerconfig->setHits(RAW,loc[0]); if(hhitsRaw)hhitsRaw->getP()->Fill(loc[0],loc[1]); if(hRawMultTemp) hRawMultTemp->getP()->Fill(gHades->getCurrentEvent()->getCategory(catShowerRaw)->getEntries()); if(hshowermult_raw) hshowermult_raw ->getP()->Fill(loc[1],loc[0]); if(hshowermulttemp_raw)hshowermulttemp_raw->getP()->Fill(loc[1],loc[0]); } void HOnlineShowerHistFiller::fillCal(HShowerCal* cal){ Int_t loc[4] = {cal->getSector(),cal->getModule(),cal->getRow(),cal->getCol()}; showerconfig->setHits(CAL,loc[0]); switch (loc[1]){ case 0: if(hCalCols[0])hCalCols[0]->getP(0,loc[0])->Fill(loc[3]); if(hCalRows[0])hCalRows[0]->getP(0,loc[0])->Fill(loc[2]); break; case 1: if(hCalCols[1])hCalCols[1]->getP(0,loc[0])->Fill(loc[3]); if(hCalRows[1])hCalRows[1]->getP(0,loc[0])->Fill(loc[2]); break; case 2: if(hCalCols[2])hCalCols[2]->getP(0,loc[0])->Fill(loc[3]); if(hCalRows[2])hCalRows[2]->getP(0,loc[0])->Fill(loc[2]); break; default: break; } if(hhitsCal) hhitsCal->getP()->Fill(loc[0],loc[1]); if(hCalCol){ hCalCol->getP()->Fill(loc[2]+(loc[0]*32)+50); } if(hCalRow){ hCalRow->getP()->Fill(loc[3]+(loc[0]*32)+50); } if(hCalMultTemp) hCalMultTemp->getP()->Fill( gHades->getCurrentEvent()->getCategory(catShowerCal)->getEntries()); } void HOnlineShowerHistFiller::fillSums(HOnlineHistArray* hist,Int_t mod, Float_t *sums){ if(sums[mod]) hist->fill(0,mod,sums[mod]); } void HOnlineShowerHistFiller::fillHit(HShowerHit* hit) { //Int_t nIndex = hit->getSector()*3 + hit->getModule(); Float_t sums[3] = {hit->getSum(0),hit->getSum(1),hit->getSum(2)}; Int_t loc[4] = {hit->getSector(),hit->getModule(),hit->getRow(),hit->getCol()}; if(sums[0]) hSumTemp->getP(0,loc[0]*3)->Fill(sums[0]); if(sums[1]) hSumTemp->getP(0,loc[0]*3+1)->Fill(sums[1]); if(sums[2]) hSumTemp->getP(0,loc[0]*3+2)->Fill(sums[2]); showerconfig->setHits(HIT,loc[0]); switch(loc[0]){ case 0: fillSums(hSums_0,loc[1],sums); break; case 1: fillSums(hSums_1,loc[1],sums); break; case 2: fillSums(hSums_2,loc[1],sums); break; case 3: fillSums(hSums_3,loc[1],sums); break; case 4: fillSums(hSums_4,loc[1],sums); break; case 5: fillSums(hSums_5,loc[1],sums); break; default: break; } if(hhitsHit) hhitsHit->getP()->Fill(loc[0],loc[1]); if(hHitMultTemp) hHitMultTemp->getP()->Fill( gHades->getCurrentEvent()->getCategory(catShowerHit)->getEntries()); } void HOnlineShowerHistFiller::fillTrend(Int_t nEvents){ if(hRawMultTrend) hRawMultTrend->fill( hRawMultTemp->getP()->GetMean(), hRawMultTemp->getP()->GetRMS()); if(hRawMultTemp) hRawMultTemp->getP()->Reset(); if(hCalMultTrend) hCalMultTrend->fill( hCalMultTemp->getP()->GetMean(), hCalMultTemp->getP()->GetRMS()); if(hCalMultTemp) hCalMultTemp->getP()->Reset(); if(hHitMultTrend) hHitMultTrend->fill( hHitMultTemp->getP()->GetMean(), hHitMultTemp->getP()->GetRMS()); if(hHitMultTemp) hHitMultTemp->getP()->Reset(); if(hSumTemp &&nEvents==0){ for(Int_t m=0;m<3;m++){ hSumTrend_0->fill(0,m,hSumTemp->getP(0,m)->GetMean()); hSumTrend_1->fill(0,m,hSumTemp->getP(0,m+3)->GetMean()); hSumTrend_2->fill(0,m,hSumTemp->getP(0,m+6)->GetMean()); hSumTrend_3->fill(0,m,hSumTemp->getP(0,m+9)->GetMean()); hSumTrend_4->fill(0,m,hSumTemp->getP(0,m+12)->GetMean()); hSumTrend_5->fill(0,m,hSumTemp->getP(0,m+15)->GetMean()); hSumTemp->getP(0,m)->Reset(); hSumTemp->getP(0,3+m)->Reset(); hSumTemp->getP(0,6+m)->Reset(); hSumTemp->getP(0,9+m)->Reset(); hSumTemp->getP(0,12+m)->Reset(); hSumTemp->getP(0,15+m)->Reset(); } } for(Int_t s=0;s<6;s++){ if(hshowermulttemp_raw&&hshowermulttrend_raw){ hshowermulttrend_raw->fill(0,s,hshowermulttemp_raw->getP()->Integral(1,3,s+1,s+1)); } } if(hshowermulttemp_raw)hshowermulttemp_raw->getP()->Reset(); } void HOnlineShowerHistFiller::putShowerParams(HParamList* l,TList* histpool) { // Puts all params of HOnlineShowerHistFiller to the parameter list of // HParamList (which ist used by the io); Char_t buf[80]; Text_t mytemp[500]; l->add("colorsSector" ,colorsSector); l->add("colorsModule" ,colorsModule); l->add("colorsCuts" ,colorsCuts ); showerconfig->setColorsSector(colorsSector); hCalColA->getText(mytemp); l->add("hCalCol" ,mytemp); hCalRowA->getText(mytemp); l->add("hCalRow" ,mytemp); hhitsRawA->getText(mytemp); l->add("hhitsRaw" ,mytemp); hhitsCalA->getText(mytemp); l->add("hhitsCal" ,mytemp); hhitsHitA->getText(mytemp); l->add("hhitsHit" ,mytemp); hRawMultTempA->getText(mytemp); l->add("hRawMultTemp" ,mytemp); hRawMultTrendA->getText(mytemp); l->add("hRawMultTrend" ,mytemp); hCalMultTempA->getText(mytemp); l->add("hCalMultTemp" ,mytemp); hCalMultTrendA->getText(mytemp); l->add("hCalMultTrend" ,mytemp); hHitMultTempA->getText(mytemp); l->add("hHitMultTemp" ,mytemp); hHitMultTrendA->getText(mytemp); l->add("hHitMultTrend" ,mytemp); hMultTrendA->getText(mytemp); l->add("hMultTrend" ,mytemp); hSumsA_0->getText(mytemp); l->add("hSums_0" ,mytemp); hSumsA_1->getText(mytemp); l->add("hSums_1" ,mytemp); hSumsA_2->getText(mytemp); l->add("hSums_2" ,mytemp); hSumsA_3->getText(mytemp); l->add("hSums_3" ,mytemp); hSumsA_4->getText(mytemp); l->add("hSums_4" ,mytemp); hSumsA_5->getText(mytemp); l->add("hSums_5" ,mytemp); hSumTrendA_0->getText(mytemp); l->add("hSumTrend_0" ,mytemp); hSumTrendA_1->getText(mytemp); l->add("hSumTrend_1" ,mytemp); hSumTrendA_2->getText(mytemp); l->add("hSumTrend_2" ,mytemp); hSumTrendA_3->getText(mytemp); l->add("hSumTrend_3" ,mytemp); hSumTrendA_4->getText(mytemp); l->add("hSumTrend_4" ,mytemp); hSumTrendA_5->getText(mytemp); l->add("hSumTrend_5" ,mytemp); hSumTemp->getText(mytemp); l->add("hSumTemp",mytemp); for(Int_t m=0; m<3;m++) { sprintf(buf,"hCalRows_%d",m); hCalRows[m]->getText(mytemp); l->add(buf ,mytemp); sprintf(buf,"hCalCols_%d",m); hCalCols[m]->getText(mytemp); l->add(buf ,mytemp); } hshowermult_rawA->getText(mytemp); l->add("hshowermult_raw" ,mytemp); hshowermulttemp_rawA->getText(mytemp); l->add("hshowermulttemp_raw" ,mytemp); hshowermulttrend_rawA->getText(mytemp); l->add("hshowermulttrend_raw" ,mytemp); } Bool_t HOnlineShowerHistFiller::getShowerParams(HParamList* l,TList* histpool,TList* activeHists) { Char_t buf[80]; if(!(l->fill("colorsSector",&colorsSector))) return kFALSE; if(!(l->fill("colorsModule",&colorsModule))) return kFALSE; if(!(l->fill("colorsCuts" ,&colorsCuts ))) return kFALSE; Text_t mytemp[500]; if(!(l->fill("hhitsRaw",mytemp,500))) {return kFALSE;} else { histpool->Add(hhitsRawA=new HOnlineMonHistAddon(mytemp)); if(hhitsRawA->getActive()==1){ activeHists->Add(hhitsRaw=new HOnlineMonHist2(*hhitsRawA)); } } if(!(l->fill("hhitsCal",mytemp,500))) {return kFALSE;} else { histpool->Add(hhitsCalA=new HOnlineMonHistAddon(mytemp)); if(hhitsCalA->getActive()==1){ activeHists->Add(hhitsCal=new HOnlineMonHist2(*hhitsCalA)); } } if(!(l->fill("hhitsHit",mytemp,500))) {return kFALSE;} else { histpool->Add(hhitsHitA=new HOnlineMonHistAddon(mytemp)); if(hhitsHitA->getActive()==1){ activeHists->Add(hhitsHit=new HOnlineMonHist2(*hhitsHitA)); } } if(!(l->fill("hCalCol",mytemp,500))) {return kFALSE;} else { histpool->Add(hCalColA=new HOnlineMonHistAddon(mytemp)); if(hCalColA->getActive()==1){ activeHists->Add(hCalCol=new HOnlineMonHist(*hCalColA)); } } if(!(l->fill("hCalRow",mytemp,500))) {return kFALSE;} else { histpool->Add(hCalRowA=new HOnlineMonHistAddon(mytemp)); if(hCalRowA->getActive()==1){ activeHists->Add(hCalRow=new HOnlineMonHist(*hCalRowA)); } } if(!(l->fill("hRawMultTrend",mytemp,500))) {return kFALSE;} else { histpool->Add(hRawMultTrendA = new HOnlineMonHistAddon(mytemp)); if(hRawMultTrendA->getActive()==1) { activeHists->Add(hRawMultTrend=new HOnlineTrendHist(*hRawMultTrendA)); } } if(!(l->fill("hRawMultTemp",mytemp,500))) {return kFALSE;} else { histpool->Add(hRawMultTempA = new HOnlineMonHistAddon(mytemp)); if(hRawMultTempA->getActive()==1) { activeHists->Add(hRawMultTemp = new HOnlineMonHist(*hRawMultTempA)); } } if(!(l->fill("hCalMultTrend",mytemp,500))) {return kFALSE;} else { histpool->Add(hCalMultTrendA = new HOnlineMonHistAddon(mytemp)); if(hCalMultTrendA->getActive()==1) { activeHists->Add(hCalMultTrend=new HOnlineTrendHist(*hCalMultTrendA)); } } if(!(l->fill("hCalMultTemp",mytemp,500))) {return kFALSE;} else { histpool->Add(hCalMultTempA = new HOnlineMonHistAddon(mytemp)); if(hCalMultTempA->getActive()==1) { activeHists->Add(hCalMultTemp = new HOnlineMonHist(*hCalMultTempA)); } } if(!(l->fill("hHitMultTrend",mytemp,500))) {return kFALSE;} else { histpool->Add(hHitMultTrendA = new HOnlineMonHistAddon(mytemp)); if(hHitMultTrendA->getActive()==1) { activeHists->Add(hHitMultTrend=new HOnlineTrendHist(*hHitMultTrendA)); } } if(!(l->fill("hMultTrend",mytemp,500))) {return kFALSE;} else { histpool->Add(hMultTrendA = new HOnlineMonHistAddon(mytemp)); if(hMultTrendA->getActive()==1) { activeHists->Add(hMultTrend=new HOnlineTrendArray(*hMultTrendA)); } } if(!(l->fill("hHitMultTemp",mytemp,500))) {return kFALSE;} else { histpool->Add(hHitMultTempA = new HOnlineMonHistAddon(mytemp)); if(hHitMultTempA->getActive()==1) { activeHists->Add(hHitMultTemp = new HOnlineMonHist(*hHitMultTempA)); } } if(!(l->fill("hSums_0",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumsA_0 = new HOnlineMonHistAddon(mytemp)); if(hSumsA_0->getActive()==1) { activeHists->Add(hSums_0 = new HOnlineHistArray(*hSumsA_0)); hSums_0->getP(0,0)->SetLineColor(colorsModule[0]); hSums_0->getP(0,1)->SetLineColor(colorsModule[1]); hSums_0->getP(0,2)->SetLineColor(colorsModule[2]); } } if(!(l->fill("hSums_1",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumsA_1 = new HOnlineMonHistAddon(mytemp)); if(hSumsA_1->getActive()==1) { activeHists->Add(hSums_1 = new HOnlineHistArray(*hSumsA_1)); hSums_1->getP(0,0)->SetLineColor(colorsModule[0]); hSums_1->getP(0,1)->SetLineColor(colorsModule[1]); hSums_1->getP(0,2)->SetLineColor(colorsModule[2]); } } if(!(l->fill("hSums_2",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumsA_2 = new HOnlineMonHistAddon(mytemp)); if(hSumsA_2->getActive()==1) { activeHists->Add(hSums_2 = new HOnlineHistArray(*hSumsA_2)); hSums_2->getP(0,0)->SetLineColor(colorsModule[0]); hSums_2->getP(0,1)->SetLineColor(colorsModule[1]); hSums_2->getP(0,2)->SetLineColor(colorsModule[2]); } } if(!(l->fill("hSums_3",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumsA_3 = new HOnlineMonHistAddon(mytemp)); if(hSumsA_3->getActive()==1) { activeHists->Add(hSums_3 = new HOnlineHistArray(*hSumsA_3)); hSums_3->getP(0,0)->SetLineColor(colorsModule[0]); hSums_3->getP(0,1)->SetLineColor(colorsModule[1]); hSums_3->getP(0,2)->SetLineColor(colorsModule[2]); } } if(!(l->fill("hSums_4",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumsA_4 = new HOnlineMonHistAddon(mytemp)); if(hSumsA_4->getActive()==1) { activeHists->Add(hSums_4 = new HOnlineHistArray(*hSumsA_4)); hSums_4->getP(0,0)->SetLineColor(colorsModule[0]); hSums_4->getP(0,1)->SetLineColor(colorsModule[1]); hSums_4->getP(0,2)->SetLineColor(colorsModule[2]); } } if(!(l->fill("hSums_5",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumsA_5 = new HOnlineMonHistAddon(mytemp)); if(hSumsA_5->getActive()==1) { activeHists->Add(hSums_5 = new HOnlineHistArray(*hSumsA_5)); hSums_5->getP(0,0)->SetLineColor(colorsModule[0]); hSums_5->getP(0,1)->SetLineColor(colorsModule[1]); hSums_5->getP(0,2)->SetLineColor(colorsModule[2]); } } if(!(l->fill("hSumTrend_0",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumTrendA_0 = new HOnlineMonHistAddon(mytemp)); if(hSumTrendA_0->getActive()==1) { activeHists->Add(hSumTrend_0=new HOnlineTrendArray(*hSumTrendA_0)); hSumTrend_0->getP(0,0)->SetLineColor(colorsModule[0]); hSumTrend_0->getP(0,2)->SetLineColor(colorsModule[2]); hSumTrend_0->getP(0,1)->SetLineColor(colorsModule[1]); } } if(!(l->fill("hSumTrend_1",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumTrendA_1 = new HOnlineMonHistAddon(mytemp)); if(hSumTrendA_0->getActive()==1) { activeHists->Add(hSumTrend_1=new HOnlineTrendArray(*hSumTrendA_1)); hSumTrend_1->getP(0,0)->SetLineColor(colorsModule[0]); hSumTrend_1->getP(0,2)->SetLineColor(colorsModule[2]); hSumTrend_1->getP(0,1)->SetLineColor(colorsModule[1]); } } if(!(l->fill("hSumTrend_2",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumTrendA_2 = new HOnlineMonHistAddon(mytemp)); if(hSumTrendA_2->getActive()==1) { activeHists->Add(hSumTrend_2=new HOnlineTrendArray(*hSumTrendA_2)); hSumTrend_2->getP(0,0)->SetLineColor(colorsModule[0]); hSumTrend_2->getP(0,2)->SetLineColor(colorsModule[2]); hSumTrend_2->getP(0,1)->SetLineColor(colorsModule[1]); } } if(!(l->fill("hSumTrend_3",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumTrendA_3 = new HOnlineMonHistAddon(mytemp)); if(hSumTrendA_3->getActive()==1) { activeHists->Add(hSumTrend_3=new HOnlineTrendArray(*hSumTrendA_3)); hSumTrend_3->getP(0,0)->SetLineColor(colorsModule[0]); hSumTrend_3->getP(0,2)->SetLineColor(colorsModule[2]); hSumTrend_3->getP(0,1)->SetLineColor(colorsModule[1]); } } if(!(l->fill("hSumTrend_4",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumTrendA_4 = new HOnlineMonHistAddon(mytemp)); if(hSumTrendA_0->getActive()==1) { activeHists->Add(hSumTrend_4=new HOnlineTrendArray(*hSumTrendA_4)); hSumTrend_4->getP(0,0)->SetLineColor(colorsModule[0]); hSumTrend_4->getP(0,2)->SetLineColor(colorsModule[2]); hSumTrend_4->getP(0,1)->SetLineColor(colorsModule[1]); } } if(!(l->fill("hSumTrend_5",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumTrendA_5 = new HOnlineMonHistAddon(mytemp)); if(hSumTrendA_5->getActive()==1) { activeHists->Add(hSumTrend_5=new HOnlineTrendArray(*hSumTrendA_5)); hSumTrend_5->getP(0,0)->SetLineColor(colorsModule[0]); hSumTrend_5->getP(0,2)->SetLineColor(colorsModule[2]); hSumTrend_5->getP(0,1)->SetLineColor(colorsModule[1]); } } if(!(l->fill("hSumTemp",mytemp,500))) {return kFALSE;} else { histpool->Add(hSumTempA = new HOnlineMonHistAddon(mytemp)); if(hSumTempA->getActive()==1) { activeHists->Add(hSumTemp = new HOnlineHistArray(*hSumTempA)); } } for(Int_t m=0; m<3; m++ ) { sprintf(buf,"hCalRows_%d",m); if(!(l->fill(buf,mytemp,500))) {return kFALSE;} else { histpool->Add(hCalRowsA[m] = new HOnlineMonHistAddon(mytemp)); if(hCalRowsA[m]->getActive()==1) { activeHists->Add(hCalRows[m] = new HOnlineHistArray(*hCalRowsA[m])); for(Int_t s =0;s<6;s++){ hCalRows[m]->getP(0,s)->SetLineColor(colorsSector[s]); } } } sprintf(buf,"hCalCols_%d",m); if(!(l->fill(buf,mytemp,500))) {return kFALSE;} else { histpool->Add(hCalColsA[m] = new HOnlineMonHistAddon(mytemp)); if(hCalColsA[m]->getActive()==1) { activeHists->Add(hCalCols[m] = new HOnlineHistArray(*hCalColsA[m])); for(Int_t s =0;s<6;s++){ hCalCols[m]->getP(0,s)->SetLineColor(colorsSector[s]); } } } } if(!(l->fill("hshowermult_raw",mytemp,500))) {return kFALSE;} else { histpool->Add(hshowermult_rawA=new HOnlineMonHistAddon(mytemp)); if(hshowermult_rawA->getActive()==1) { activeHists->Add(hshowermult_raw=new HOnlineMonHist2(*hshowermult_rawA)); } } if(!(l->fill("hshowermulttemp_raw",mytemp,500))) {return kFALSE;} else { histpool->Add(hshowermulttemp_rawA=new HOnlineMonHistAddon(mytemp)); if(hshowermulttemp_rawA->getActive()==1) { activeHists->Add(hshowermulttemp_raw=new HOnlineMonHist2(*hshowermulttemp_rawA)); } } if(!(l->fill("hshowermulttrend_raw",mytemp,500))) {return kFALSE;} else { histpool->Add(hshowermulttrend_rawA=new HOnlineMonHistAddon(mytemp)); if(hshowermulttrend_rawA->getActive()==1) { activeHists->Add(hshowermulttrend_raw=new HOnlineTrendArray(*hshowermulttrend_rawA)); for(Int_t s=0;s<6;s++){ hshowermulttrend_raw->getP(0,s)->SetLineColor(colorsSector[s]); hshowermulttrend_raw->getP(0,s)->SetMarkerColor(colorsSector[s]); } } } return kTRUE; } void HOnlineShowerHistFiller::fillShowerConfig(Int_t fCount) { HCategory* catRaw=gHades->getCurrentEvent()->getCategory(catShowerRaw); if(catRaw) { showerconfig->setEvtSeqNb(catRaw->getEntries()); showerconfig->setEvtNb(fCount); showerconfig->setRawMult(catRaw->getEntries()); } HCategory* catCal=gHades->getCurrentEvent()->getCategory(catShowerCal); if(catCal) { showerconfig->setCalMult(catCal->getEntries()); } } void HOnlineShowerHistFiller::resetHits(){ if (showerconfig) { showerconfig->resetHits(RAW); showerconfig->resetHits(CAL); showerconfig->resetHits(HIT); } }