2 /**************************************************************************
3 * This file is property of and copyright by the ALICE HLT Project *
4 * All rights reserved. *
6 * Primary Authors: Oystein Djuvsland *
8 * Permission to use, copy, modify and distribute this software and its *
9 * documentation strictly for non-commercial purposes is hereby granted *
10 * without fee, provided that the above copyright notice appears in all *
11 * copies and that both the copyright notice and this permission notice *
12 * appear in the supporting documentation. The authors make no claims *
13 * about the suitability of this software for any purpose. It is *
14 * provided "as is" without express or implied warranty. *
15 **************************************************************************/
16 #ifndef ALIHLTPHOSDIGITMAKER_H
17 #define ALIHLTPHOSDIGITMAKER_H
20 * Class makes digits from information from raw data
22 * @file AliHLTPHOSDigitMaker.h
23 * @author Oystein Djuvsland
25 * @brief Digit maker for PHOS HLT
28 // see below for class documentation
30 // refer to README to build package
32 // visit http://web.ift.uib.no/~kjeks/doc/alice-hlt
34 #include "AliHLTPHOSBase.h"
35 #include "AliHLTPHOSConstants.h"
38 * @class AliHLTPHOSDigitMaker
39 * Digit maker for PHOS HLT. Takes input from AliHLTPHOSRawAnalyzer, and
40 * outputs an AliHLTPHOSDigitDataStruct container, or a TClonesArray of
41 * AliHLTPHOSDigit. Can do software zero suppression
42 * @ingroup alihlt_phos
45 class AliHLTPHOSDigit;
48 class AliHLTPHOSValidCellDataStruct;
49 class AliHLTPHOSRcuCellEnergyDataStruct;
50 class AliHLTPHOSDigitContainerDataStruct;
51 class AliHLTPHOSDigitDataStruct;
52 class AliHLTPHOSSharedMemoryInterface; // added by PTH
54 using namespace PhosHLTConst;
56 class AliHLTPHOSDigitMaker : public AliHLTPHOSBase
61 AliHLTPHOSDigitMaker();
64 virtual ~AliHLTPHOSDigitMaker();
66 // void SetValidCellData(AliHLTPHOSValidCellDataStruct *data) { fCellDataPtr = data; }
67 // void SetDigitContainerStruct(AliHLTPHOSDigitContainerStruct *container)
68 //{ fDigitContainerStructPtr = container; }
71 * Sets the AliHLTPHOSDigitDataStruct container
72 * @param container the digit container
74 void SetDigitContainerStruct(AliHLTPHOSDigitContainerDataStruct *container)
75 { fDigitContainerStructPtr = container; }
78 * Sets the TClonesArray of AliHLTPHOSDigit
79 * @param array the array
81 void SetDigitArray(TClonesArray *array) { fDigitArrayPtr = array; }
84 * Sets the digit threshold
85 * @param threshold the threshold
87 void SetDigitThreshold(Int_t threshold) { fDigitThreshold = threshold; }
90 * Sets the number of pre samples
91 * @param n the number of pre samples
93 void SetNrPresamples(Int_t n) { fNrPresamples = n; }
96 * Make the digits for one event.
97 * @param rcuCellEnergies is the data from the AliHLTPHOSRawAnalyzer
98 * @return the number of digits found
100 Int_t MakeDigits(AliHLTPHOSRcuCellEnergyDataStruct* rcuCellEnergies);
102 /** Reset the digit maker */
107 /** Pointer to valid cell list */
108 AliHLTPHOSValidCellDataStruct *fCellDataPtr; //! transient
110 /** Pointer to the digit container */
111 AliHLTPHOSDigitContainerDataStruct *fDigitContainerStructPtr; //! transient
113 /** Pointer to the digit TClonesArray */
114 TClonesArray *fDigitArrayPtr; //! transient
116 /** Pointer to a AliHLTPHOSDigit */
117 AliHLTPHOSDigit *fDigitPtr; //! transient
119 /** Pointer to a AliHLTPHOSDigitDataStruct */
120 AliHLTPHOSDigitDataStruct *fDigitStructPtr; //! transient
125 /** Number of presamples */
128 /** Threshold for making digit ( zero suppression threshold) */
129 Float_t fDigitThreshold;
130 AliHLTPHOSSharedMemoryInterface *fShmPtr; //added by PTH
131 ClassDef(AliHLTPHOSDigitMaker, 1);