1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2 * See cxx source for full Copyright notice */
4 /** @file AliHLTPHOSClusterizer.h
5 @author Øystein Djuvsland
7 @brief A temporary clusterizer for PHOS
10 #ifndef ALIHLTPHOSCLUSTERIZER_H
11 #define ALIHLTPHOSCLUSTERIZER_H
13 #include "AliHLTPHOSCommonDefs.h"
15 struct AliHLTPHOSClusterDataStruct;
16 struct AliHLTPHOSRecPointDataStruct;
17 struct AliHLTPHOSValidCellDataStruct;
18 struct AliHLTPHOSRecPointListDataStruct;
19 struct AliHLTPHOSRcuCellEnergyDataStruct;
21 class AliHLTPHOSClusterizer
26 AliHLTPHOSClusterizer();
27 virtual ~AliHLTPHOSClusterizer();
28 AliHLTPHOSClusterizer(const AliHLTPHOSClusterizer &);
29 AliHLTPHOSClusterizer & operator = (const AliHLTPHOSClusterizer &) {return *this;}
31 void SetThreshold(Float_t threshold) {fThreshold = threshold;}
32 void SetClusterThreshold(Float_t clusterThreshold) {fClusterThreshold = clusterThreshold;}
34 void SetHighGainFactor(Float_t highGain) {fHighGainFactor = highGain;}
35 void SetLowGainFactor(Float_t lowGain) {fLowGainFactor = lowGain;}
36 void SetArraySize(Int_t size)
39 fMultiplicity = fArraySize * fArraySize;
42 Float_t GetHighGainFactor() {return fHighGainFactor;}
43 Float_t GetLowGainFactor() {return fLowGainFactor;}
45 Int_t BuildCellEnergyArray(AliHLTPHOSRcuCellEnergyDataStruct *structPtr, AliHLTPHOSRecPointListDataStruct* recPointList);
46 Int_t CreateRecPointStructArray(AliHLTPHOSRecPointDataStruct* rectStructsPtr, AliHLTPHOSRecPointListDataStruct* list, Int_t nPoints);
47 Int_t CalculateCenterOfGravity(AliHLTPHOSRecPointDataStruct* recPointPtr);
48 Int_t ClusterizeStruct(AliHLTPHOSRecPointDataStruct* recArrayPtr, AliHLTPHOSClusterDataStruct* clusterArrayPtr);
49 Int_t ResetCellEnergyArray();
54 AliHLTUInt8_t fPHOSModule; /**<Number of the PHOSModule*/
55 Float_t fEnergyArray[N_COLUMNS_MOD][N_ROWS_MOD]; /**<2D array of cell energies*/
56 Float_t fThreshold; /**<Energy threshold*/
57 Float_t fClusterThreshold; /**<Cluster threshold*/
58 Float_t fHighGainFactor; /**<High gain factor*/
59 Float_t fLowGainFactor; /**<Low gain factor*/
60 Int_t fArraySize; /**<Size of the array which the energies are summed*/
61 Int_t fMultiplicity; /**<Number of crystals the energies are summed for*/
63 ClassDef(AliHLTPHOSClusterizer, 1);