Newer
Older
#ifndef ROOT_THcRawAdcHit
#define ROOT_THcRawAdcHit
#include "TObject.h"
class THcRawAdcHit : public TObject {
public:
THcRawAdcHit();
THcRawAdcHit& operator=(const THcRawAdcHit& right);
virtual ~THcRawAdcHit();
virtual void Clear(Option_t* opt="");
void SetData(Int_t data);
void SetSample(Int_t data);
void SetDataTimePedestalPeak(
Int_t data, Int_t time, Int_t pedestal, Int_t peak
);
Int_t GetRawData(UInt_t iPulse=0);
Int_t GetAdcTime(UInt_t iPulse=0);
Int_t GetAdcPedestal(UInt_t iPulse=0);
Int_t GetAdcPeak(UInt_t iPulse=0);
Int_t GetSample(UInt_t iSample);
Double_t GetAverage(UInt_t iSampleLow, UInt_t iSampleHigh);
Int_t GetIntegral(UInt_t iSampleLow, UInt_t iSampleHigh);
Double_t GetData(
UInt_t iPedLow, UInt_t iPedHigh, UInt_t iIntLow, UInt_t iIntHigh
);
UInt_t GetNPulses();
UInt_t GetNSamples();
Bool_t HasMulti();
Int_t GetPedRaw();
Int_t GetPeakIntRaw(UInt_t iPulse=0);
Int_t GetPeakAmpRaw(UInt_t iPulse=0);
//Int_t GetPeakTimeRaw(UInt_t iPulse=0); // TODO: Figure out what to do with time.
Double_t GetPed();
Double_t GetPeakInt(UInt_t iPulse=0);
Double_t GetPeakAmp(UInt_t iPulse=0);
//Double_t GetPeakTime(UInt_t iPulse=0);
protected:
static const UInt_t fMaxNPulses = 4;
Int_t fNPedestalSamples; // TODO: Get this from prestart event...
Int_t fNPeakSamples;
Double_t fPeakPedestalRatio;
Int_t fAdc[fMaxNPulses]; // TODO: Rename these...
Int_t fAdcTime[fMaxNPulses];
Int_t fAdcPedestal[fMaxNPulses]; // TODO: There should only be 1 pedestal...