//-*- Mode: C++ -*-
// @(#) $Id$
-
-//* This file is property of and copyright by the ALICE HLT Project *
-//* ALICE Experiment at CERN, All rights reserved. *
-//* See cxx source for full Copyright notice *
+// *************************************************************************
+// This file is property of and copyright by the ALICE HLT Project *
+// ALICE Experiment at CERN, All rights reserved. *
+// See cxx source for full Copyright notice *
+// *
+// AliHLTTPCCADisplay class is a debug utility. *
+// It is not used in the normal data processing. *
+// *
+//***************************************************************************
#ifndef ALIHLTTPCCADISPLAY_H
#define ALIHLTTPCCADISPLAY_H
+
class AliHLTTPCCATracker;
-class AliHLTTPCCACell;
class AliHLTTPCCATrack;
+class AliHLTTPCCATrackParam;
+class AliHLTTPCCAPerformance;
-#include "TCanvas.h"
+class TCanvas;
#include "TArc.h"
#include "TLine.h"
#include "TPolyLine.h"
#include "TLatex.h"
+
/**
* @class AliHLTTPCCADisplay
*/
class AliHLTTPCCADisplay
{
- public:
- static AliHLTTPCCADisplay &Instance();
-
- AliHLTTPCCADisplay();
- AliHLTTPCCADisplay( const AliHLTTPCCADisplay& );
- AliHLTTPCCADisplay& operator=(const AliHLTTPCCADisplay&);
+ public:
+
+ class AliHLTTPCCADisplayTmpHit;
+
+ static AliHLTTPCCADisplay &Instance();
+
+ AliHLTTPCCADisplay();
+ AliHLTTPCCADisplay( const AliHLTTPCCADisplay& );
+ const AliHLTTPCCADisplay& operator=( const AliHLTTPCCADisplay& ) const ;
+
+ virtual ~AliHLTTPCCADisplay();
+
+ void Init();
+ void Update();
+ void ClearView();
+ void Ask();
+ void SetSliceView();
+ void SetTPCView();
+ void SetCurrentSlice( AliHLTTPCCATracker *slice );
+ void Set2Slices( AliHLTTPCCATracker * const slice );
+
+ int GetColor( int i ) const;
+ int GetColorZ( double z ) const ;
+ int GetColorY( double y ) const ;
+ int GetColorK( double k ) const ;
+ void Global2View( double x, double y, double *xv, double *yv ) const ;
+ void Slice2View( double x, double y, double *xv, double *yv ) const ;
+ int GetTrackMC( const AliHLTTPCCADisplayTmpHit *vHits, int NHits );
- virtual ~AliHLTTPCCADisplay();
+ void DrawTPC();
+ void DrawSlice( AliHLTTPCCATracker *slice, bool DrawRows = 0 );
+ void DrawSliceOutTrack( int itr, int color = -1, int width = -1 );
+ void DrawSliceOutTrack( AliHLTTPCCATrackParam &t, double Alpha, int itr, int color = -1, int width = -1 );
+ void DrawSliceTrack( int itr, int color = -1 );
+ bool DrawTrack( AliHLTTPCCATrackParam t, double Alpha, const AliHLTTPCCADisplayTmpHit *vHits,
+ int NHits, int color = -1, int width = -1, bool pPoint = 0 );
- void Init();
- void Update();
- void Clear();
- void Ask();
- void SetSectorView();
- void SetTPCView();
- void SetCurrentSector( AliHLTTPCCATracker *sec );
+ bool DrawTracklet( AliHLTTPCCATrackParam &track, const int *hitstore, int color = -1, int width = -1, bool pPoint = 0 );
- Int_t GetColor( Double_t z ) const ;
- void Global2View( Double_t x, Double_t y, Double_t *xv, Double_t *yv ) const ;
- void Sec2View( Double_t x, Double_t y, Double_t *xv, Double_t *yv ) const ;
+ void DrawSliceHit( int iRow, int iHit, int color = -1, Size_t width = -1 );
+ void DrawSliceHits( int color = -1, Size_t width = -1 );
+ void DrawSliceLinks( int colorUp = -1, int colorDn = -1, int width = -1 );
+ void DrawSliceLink( int iRow, int iHit, int colorUp = -1, int colorDn = -1, int width = -1 );
- void DrawTPC();
- void DrawSector( AliHLTTPCCATracker *sec );
- void DrawHit( Int_t iRow,Int_t iHit, Int_t color=-1 );
- void DrawCell( Int_t iRow, AliHLTTPCCACell &cell, Int_t width=1, Int_t color=-1 );
- void DrawCell( Int_t iRow, Int_t iCell, Int_t width=1, Int_t color=-1 );
+ void SetSliceTransform( double alpha );
- void ConnectCells( Int_t iRow1, AliHLTTPCCACell &cell1, Int_t iRow2, AliHLTTPCCACell &cell2, Int_t color=-1 );
+ void SetSliceTransform( AliHLTTPCCATracker *slice );
- void DrawTrack( AliHLTTPCCATrack &track, Int_t color=-1 );
+ TCanvas *CanvasYX() const { return fYX; }
+ TCanvas *CanvasZX() const { return fZX; }
- protected:
+ protected:
- TCanvas *fXY, *fZY; // two views
- Bool_t fAsk; // flag to ask for the pressing key
- Bool_t fSectorView; // switch between sector/TPC zoomv
- AliHLTTPCCATracker *fSector; // current CA tracker, includes sector geometry
- Double_t fCos, fSin, fZMin, fZMax;// view parameters
- Double_t fRInnerMin, fRInnerMax, fROuterMin, fROuterMax,fTPCZMin, fTPCZMax; // view parameters
+ TCanvas *fYX, *fZX; // two views
+ bool fAsk; // flag to ask for the pressing key
+ bool fSliceView; // switch between slice/TPC zoom
+ AliHLTTPCCATracker *fSlice; // current CA tracker, includes slice geometry
+ AliHLTTPCCAPerformance *fPerf; // Performance class (mc labels etc)
+ double fCos, fSin, fZMin, fZMax, fYMin, fYMax;// view parameters
+ double fSliceCos, fSliceSin; // current slice angle
+ double fRInnerMin, fRInnerMax, fROuterMin, fROuterMax, fTPCZMin, fTPCZMax; // view parameters
- TArc fArc; // parameters of drawing objects are copied from this members
- TLine fLine; //!
- TPolyLine fPLine;//!
- TMarker fMarker; //!
- TBox fBox; //!
- TCrown fCrown; //!
- TLatex fLatex; //!
+ TArc fArc; // parameters of drawing objects are copied from this members
+ TLine fLine; //!
+ TPolyLine fPLine;//!
+ TMarker fMarker; //!
+ TBox fBox; //!
+ TCrown fCrown; //!
+ TLatex fLatex; //!
- ClassDef(AliHLTTPCCADisplay,1);
+ bool fDrawOnlyRef; // draw only clusters from ref. mc tracks
};