AliHMPID *h; AliLoader *hl; AliHMPIDParam *hp;
Bool_t isGeomType=kFALSE;
+Int_t nEvent=0;
+
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
void GetParam()
{
status+="No galice.root";
GetParam();
-
TControlBar *pMenu = new TControlBar("horizontal",status.Data(),0,0);
pMenu->AddButton(" ","","");
pMenu->AddButton(" General ","General()" ,"general items which do not depend on any files");
pMenu->AddButton(" Sim data ","SimData()" ,"items which expect to have simulated files" );
pMenu->AddButton(" ","" ,"");
pMenu->AddButton(" Raw data ","RawData()" ,"items which expect to have raw files" );
- pMenu->AddButton(" ","print()" ,"");
+ pMenu->AddButton(" "," " ,"");
pMenu->AddButton(" Test ","Test()" ,"all test utilities");
- pMenu->AddButton(" ","GetParam()" ,"");
- pMenu->AddButton(" Quit ",".q" ,"close session" );
+ pMenu->AddButton(" PREV EVENT ","PrevEvent()" ,"Set the previous event" );
+ pMenu->AddButton(" NEXT EVENT ","NextEvent()","Set the next event" );
+ pMenu->AddButton(" Quit ",".q" ,"close session" );
pMenu->Show();
}//Menu()
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
void SimData()
{
TControlBar *pMenu = new TControlBar("vertical","Sim data",310,50);
- pMenu->AddButton("Display from files","hed();" ,"Display Fast");
- pMenu->AddButton("Display simulated" ,"sed();" ,"Display Fast");
+ pMenu->AddButton("Display ","hed();" ,"Display Fast");
pMenu->AddButton("HITS QA" ,"hqa()" ,"QA plots for hits: hqa()");
pMenu->AddButton("Print stack" ,"stack();" ,"To print hits: hp(evt)");
pMenu->AddButton("Print hits" ,"hp();" ,"To print hits: hp(evt)");
void Test()
{
TControlBar *pMenu = new TControlBar("vertical","Test",820,50);
+ pMenu->AddButton("TEST Display " ,"sed();" ,"Display Fast");
pMenu->AddButton("Hits->Digits" ,"thd();" ,"test hits->sdigits->digits" );
pMenu->AddButton("Segmentation" ,"ts()" ,"test segmentation methods" );
pMenu->AddButton("Test response" ,"AliHMPIDParam::TestResp();","Test AliHMPIDParam response methods" );
void du ( ) {h->Dump ( );} //utility display
-void hp (Int_t evt=0 ) {h->HitPrint (evt);} //print hits for requested event
+void hp ( ) {h->HitPrint (nEvent);} //print hits for requested event
void hq ( ) {h->HitQA ( );} //hits QA plots for all events
-void sp (Int_t evt=0 ) {h->SdiPrint (evt);} //print sdigits for requested event
-void sq (Int_t evt=0 ) {h->SdiPrint (evt);} //print sdigits for requested event
-void dp (Int_t evt=0 ) {h->DigPrint (evt);} //print digits for requested event
+void sp ( ) {h->SdiPrint (nEvent);} //print sdigits for requested event
+void sq ( ) {h->SdiPrint (nEvent);} //print sdigits for requested event
+void dp ( ) {h->DigPrint (nEvent);} //print digits for requested event
void dq ( ) {AliHMPIDReconstructor::DigQA (al );} //digits QA plots for all events
-void cp (Int_t evt=0 ) {h->CluPrint (evt); } //print clusters for requested event
+void cp ( ) {h->CluPrint (nEvent); } //print clusters for requested event
void cq ( ) {AliHMPIDReconstructor::CluQA (al );} //clusters QA plots for all events
void ep ( ) {AliHMPIDTracker::EsdQA(1); }
void eq ( ) {AliHMPIDTracker::EsdQA(); }
void mp (Double_t probCut=0.7 ) {AliHMPIDTracker::MatrixPrint(probCut);}
-
-void stack( ) {AliHMPIDParam::Stack();}
-void tid (Int_t tid,Int_t evt=0) {AliHMPIDParam::Stack(evt,tid);}
+void PrevEvent() {nEvent--;if(nEvent<0)nEvent=0;Printf("Current event is %i",nEvent);}
+void NextEvent() {nEvent++;Printf("Current event is %i",nEvent);}
+void stack( ) {AliHMPIDParam::Stack();}
+void tid (Int_t tid,Int_t evt=0) {AliHMPIDParam::Stack(evt,tid);}
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
void PrintMap()
{//event display from files
static TCanvas *pC=0;
static Int_t iEvt=0;
- static Int_t iEvtTot=0;
+ static Int_t iEvtTot=999;
static TFile *pEsdFl=0;
static TTree *pEsdTr=0;
static AliESD *pEsd=0;
-
- if(!pC){
+ if(!pC&&iEvt<iEvtTot){
if(hl==0) {Printf("hed: no HMPID loader");return;}
Printf("Opening session");
pEsdFl=TFile::Open("AliESDs.root"); if(!pEsdFl || !pEsdFl->IsOpen()) return;//open AliESDs.root
if(iEvt<iEvtTot){
pEsdTr->GetEntry(iEvt); al->GetEvent(iEvt); hl->TreeD()->GetEntry(0); hl->TreeR()->GetEntry(0);
- TLatex txt; pC->cd(3); txt.DrawLatex(0.2,0.2,Form("Event %i Total %i",iEvt,iEvtTot));
+ TLatex txt; pC->cd(3); gPad->Clear();
+ txt.SetTextSize(0.1);txt.DrawLatex(0.2,0.2,Form("Event %i (total %i)",iEvt,iEvtTot));
DrawEvt(pC,h->DigLst(),h->CluLst(),pEsd);
iEvt++;
}else{
- Printf("Last event");
- pC->Clear();
+ Printf("--- No more events available...Bye.");
+ pC->Close();
}
}
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
void sed()
{
- static TCanvas *pC=0;
+ static TCanvas *pC1=0;
- if(!pC){
- pC=new TCanvas("hed","Simulated evets-View from electronics side, IP is behind the picture.",1000,900); pC->Divide(3,3);
- pC->cd(7); TButton *pBtn=new TButton("Next","sed()",0,0,0.2,0.1); pBtn->Draw();
+ if(!pC1){
+ pC1=new TCanvas("hed","Simulated evets-View from electronics side, IP is behind the picture.",1000,900); pC1->Divide(3,3);
+ pC1->cd(7); TButton *pBtn=new TButton("Next","sed()",0,0,0.2,0.1); pBtn->Draw();
}
AliHMPIDReconstructor::Dig2Clu(&ld,&lc);
// AliHMPIDTracker::Recon(&esd,&cl);
- DrawEvt(pC,&ld,&lc,&esd);
+ DrawEvt(pC1,&ld,&lc,&esd);
}//SimEvt()
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
void DrawEvt(TCanvas *pC,TObjArray *pDigLst,TObjArray *pCluLst,AliESD *pEsd)