CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
HBHENegativeFlag.cc
Go to the documentation of this file.
4 
6  const HBHEDataFrame &digi,
7  const HcalCoder &coder,
8  const HcalCalibrations &calib) {
9  if (filter_) {
11  coder.adc2fC(digi, cs);
12  const int nRead = cs.size();
13 
14  double ts[CaloSamples::MAXSAMPLES];
15  for (int i = 0; i < nRead; i++) {
16  const int capid = digi[i].capid();
17  ts[i] = cs[i] - calib.pedestal(capid);
18  }
19 
20  const bool passes = filter_->checkPassFilter(hbhe.id(), &ts[0], nRead);
21  if (!passes)
23  }
24 }
static const int MAXSAMPLES
Definition: CaloSamples.h:86
unique_ptr< ClusterSequence > cs
constexpr void setFlagField(uint32_t value, int base, int width=1)
Definition: CaloRecHit.h:36
bool checkPassFilter(const HcalDetId &id, const double *ts, unsigned lenTS) const
constexpr HcalDetId id() const
get the id
Definition: HBHERecHit.h:41
const HBHENegativeEFilter * filter_
constexpr double pedestal(int fCapId) const
get pedestal for capid=0..3
int size() const
get the size
Definition: CaloSamples.h:24
void setPulseShapeFlags(HBHERecHit &hbhe, const HBHEDataFrame &digi, const HcalCoder &coder, const HcalCalibrations &calib)
virtual void adc2fC(const HBHEDataFrame &df, CaloSamples &lf) const =0