1 #ifndef ALIFMDHITDIGITIZER_H
2 #define ALIFMDHITDIGITIZER_H
3 /* Copyright(c) 1998-2000, ALICE Experiment at CERN, All rights
6 * See cxx source for full Copyright notice
8 // Classses to make Hits into digits and summable digits
15 // - ADC count in this channel
17 /** @file AliFMDHitDigitizer.h
18 @author Christian Holm Christensen <cholm@nbi.dk>
19 @date Mon Mar 27 12:38:26 2006
20 @brief FMD Digitizers declaration
23 #ifndef ALIFMDBASEDIGITIZER_H
24 # include <AliFMDBaseDigitizer.h>
27 //====================================================================
37 //====================================================================
38 /** @class AliFMDHitDigitizer
39 @brief Concrete digitizer to make digits from hits. See also
40 AliFMDBaseDigitizer documentation.
43 class AliFMDHitDigitizer : public AliFMDBaseDigitizer
53 : AliFMDBaseDigitizer(),
60 AliFMDHitDigitizer(AliFMD* fmd, Output_t output);
62 virtual ~AliFMDHitDigitizer() {}
63 /** Run over the input events (retrieved via run loader) */
64 void Digitize(Option_t* option="");
66 * Set the end of integration
68 * @param holdT Time when integration ends (nominally @f$
71 void SetHoldTime(Double_t holdT=2e-6) { fHoldTime = holdT; }
75 * @return Hold time in seconds
77 Double_t GetHoldTime() const { return fHoldTime; }
80 @param o Object to copy from */
81 AliFMDHitDigitizer(const AliFMDHitDigitizer& o)
82 : AliFMDBaseDigitizer(o),
90 * @param o Object to assign from
91 * @return Reference to this
93 AliFMDHitDigitizer& operator=(const AliFMDHitDigitizer& o);
95 * Make the output tree using the passed loader
98 * @return The generated tree.
100 TTree* MakeOutputTree(AliLoader* loader);
101 /** Sum energy deposited contributions from each hit in a cache
102 @param hitsBranch Branch in input tree */
103 void SumContributions(TBranch* hitsBranch);
105 @param detector Detector #
107 @param sector Sector #
109 @return Pedestal value */
110 UShort_t MakePedestal(UShort_t detector,
113 UShort_t strip) const;
114 /** Add a digit to output.
115 @param fmd Pointer to detector object
116 @param detector Detector #
118 @param sector Sector number
119 @param strip Strip number
120 @param edep Energy deposited (not used)
121 @param count1 ADC count 1
122 @param count2 ADC count 2 (-1 if not used)
123 @param count3 ADC count 3 (-1 if not used)
124 @param count4 ADC count 4 (-1 if not used) */
125 void AddDigit(UShort_t detector,
136 const TArrayI& trackrefs) const;
137 /** Check that digit data is consistent
139 @param nhits Number of hits
140 @param counts ADC counts */
141 void CheckDigit(AliFMDDigit* digit,
143 const TArrayI& counts);
145 * Store the data using the loader
147 * @param loader The loader
149 void StoreDigits(const AliLoader* loader);
152 Output_t fOutput; // Output mode
153 Double_t fHoldTime; // Stop of integration
154 AliStack* fStack; // Kinematics
156 ClassDef(AliFMDHitDigitizer,1) // Make Digits from Hits
161 //____________________________________________________________________