13#define TRGCDC_SHORT_NAMES
15#include "trg/cdc/HoughPlaneMulti.h"
24 const TCHTransformation& trans,
36 for (
unsigned i = 0; i <
N_LAYERS; i++)
38 for (
unsigned i = 0; i <
_nLayers; i++)
48 std::cout <<
"Too many layers requested("
56 for (
unsigned i = 0; i <
_nLayers; i++)
71 std::cout <<
"TRGCDCHoughPlaneMulti::vote !!! (" <<
name()
72 <<
") given layerId(" << layerId <<
") is too big : max="
79 _layers[layerId]->vote(rx, ry, (
int) targetCharge, weight);
85 const unsigned nCells =
nX() *
nY();
96 memset(
_cell, 0, nCells *
sizeof(
unsigned));
98 for (
unsigned j = 0; j <
_nLayers; j++) {
101 if (!
_usage[j])
continue;
102 for (
unsigned i = 0; i < nCells; i++) {
112 _layers[layerId]->vote(phi, weight);
unsigned _nLayers
number of layers
TRGCDCHoughPlane * _layers[N_LAYERS]
layers of TRGCDCHoughPlane
bool _usage[N_LAYERS]
usage of each layer
int *const _cell
Counters.
TRGCDCHoughPlane(const std::string &name, const TRGCDCHoughTransformation &transformation, unsigned nX, float xMin, float xMax, unsigned nY, float yMin, float yMax)
Constructor.
float xMin(void) const
returns min. of x.
unsigned nY(void) const
return # of y bins.
virtual ~TRGCDCHoughPlaneMulti()
Destructor.
float xMax(void) const
returns max. of x.
#define N_LAYERS
number of layers
void vote(float rx, float ry, float charge, const TRGCDCHoughTransformation &hough, unsigned weight, unsigned layerId)
vote
void merge(void)
merge function
float yMax(void) const
returns max. of y.
TRGCDCHoughPlaneMulti(const std::string &name, const TRGCDCHoughTransformation &transformation, unsigned nX, float xMin, float xMax, unsigned nY, float yMin, float yMax, unsigned nLayers)
Constructor.
std::string name(void) const
returns name.
unsigned nX(void) const
returns # of x bins.
float yMin(void) const
returns min. of y.
Abstract base class for different kinds of events.