Display boxes for pads in display
authordibari <dibari@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 12 Mar 2007 22:53:03 +0000 (22:53 +0000)
committerdibari <dibari@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 12 Mar 2007 22:53:03 +0000 (22:53 +0000)
HMPID/AliHMPIDDigit.cxx
HMPID/Hdisp.C

index 3da39ef..ba2353b 100644 (file)
@@ -16,6 +16,7 @@
 #include "AliHMPIDDigit.h"    //class header
 #include <TClonesArray.h>     //WriteRaw() 
 #include <TBox.h>             //Draw() 
+#include <TPolyLine.h>        //Draw() 
 #include <AliRawDataHeader.h> //WriteRaw()
 #include <AliDAQ.h>           //WriteRaw()
 #include <Riostream.h>        //WriteRaw()
@@ -106,6 +107,12 @@ void AliHMPIDDigit::Draw(Option_t*)
 {
 //  TMarker *pMark=new TMarker(LorsX(),LorsY(),25); pMark->SetMarkerColor(kGreen);pMark->Draw();
   TBox *pad = new TBox(LorsX()-0.5*SizePadX(),LorsY()-0.5*SizePadY(),LorsX()+0.5*SizePadX(),LorsY()+0.5*SizePadY());
+  TPolyLine *line=new TPolyLine(5);
+  line->SetPoint(0,LorsX()-0.5*SizePadX(),LorsY()-0.5*SizePadY());
+  line->SetPoint(1,LorsX()-0.5*SizePadX(),LorsY()+0.5*SizePadY());
+  line->SetPoint(2,LorsX()+0.5*SizePadX(),LorsY()+0.5*SizePadY());
+  line->SetPoint(3,LorsX()+0.5*SizePadX(),LorsY()-0.5*SizePadY());
+  line->SetPoint(4,LorsX()-0.5*SizePadX(),LorsY()-0.5*SizePadY());
   Int_t slice=(Int_t)fQ/20;
   switch(slice){
     case 0: pad->SetFillColor(kBlue); break;
@@ -119,7 +126,7 @@ void AliHMPIDDigit::Draw(Option_t*)
     default: pad->SetFillColor(kRed);      break;
   }
    pad->SetUniqueID((Int_t)fQ);
-  pad->Draw();
+  pad->Draw();line->Draw();
 }
 //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 void AliHMPIDDigit::Print(Option_t *opt)const
index bb21a50..cba9446 100644 (file)
@@ -189,15 +189,16 @@ void DrawEvt(TClonesArray *pHitLst,TObjArray *pDigLst,TObjArray *pCluLst,AliESD
     gPad->SetEditable(kTRUE); gPad->Clear(); 
     DrawCh(iCh);
                            
-    for(Int_t iHit=0;iHit<pHitLst->GetEntriesFast();iHit++){
+    ((TClonesArray*)pDigLst->At(iCh))->Draw();               //draw digits
+    
+    for(Int_t iHit=0;iHit<pHitLst->GetEntriesFast();iHit++){ // Draw hits
       AliHMPIDHit *pHit=(AliHMPIDHit*)pHitLst->At(iHit);
       if(pHit->Ch()==iCh) pHit->Draw();
     }    
            
-    ((TClonesArray*)pDigLst->At(iCh))->Draw();  //draw digits
-    ((TClonesArray*)pCluLst->At(iCh))->Draw();  //draw clusters
-                            pTxC[iCh]->Draw();  //draw intersections
-                            pRin[iCh]->Draw("CLP");  //draw rings
+    ((TClonesArray*)pCluLst->At(iCh))->Draw();              //draw clusters
+                            pTxC[iCh]->Draw();              //draw intersections
+                            pRin[iCh]->Draw("CLP");         //draw rings
     gPad->SetEditable(kFALSE);
   }//chambers loop