 |
Belle II Software
release-05-01-25
|
13 #include <framework/core/Module.h>
14 #include <framework/datastore/StoreArray.h>
15 #include <framework/datastore/StoreObjPtr.h>
16 #include <pxd/dataobjects/PXDRawHit.h>
17 #include <pxd/dataobjects/PXDDigit.h>
18 #include <pxd/dataobjects/PXDDAQStatus.h>
39 class PXDRawHitSorterModule :
public Module {
48 virtual void event()
override;
59 inline bool goodHit(
const PXDRawHit*
const rawhit)
const
61 short u = rawhit->getColumn();
62 bool goodU = (u == std::min(std::max(u,
short(0)),
short(249)));
63 short v = rawhit->getRow();
64 bool goodV = (v == std::min(std::max(v,
short(0)),
short(767)));
65 return (goodU && goodV);
std::string m_storeDigitsName
Name of the collection to use for the PXDDigits.
virtual void initialize() override
Initialize the module.
bool m_mergeDuplicates
Mode: if true, merge duplicate pixels, otherwise only keep the first.
bool m_trimOutOfRange
Discard out-of-range hits.
virtual void event() override
do the sorting
Abstract base class for different kinds of events.
StoreArray< PXDRawHit > m_storeRawHits
Required input for PXDRawHit.
StoreArray< PXDDigit > m_storeDigits
Output array for PXDDigits.
PXDRawHitSorterModule()
Constructor defining the parameters.
std::string m_storeRawHitsName
Name of the collection to use for PXDRawHits.
int m_0cut
Minimum charge for a digit to carry.
bool goodHit(const PXDRawHit *const rawhit) const
Utility function to check pixel coordinates.
StoreObjPtr< PXDDAQStatus > m_storeDaqStatus
Required input for PXD Daq Status.