CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
PixelLimits Struct Reference

#include <ClusterShapeHitFilter.h>

Public Member Functions

bool isInside (const std::pair< float, float > &pred) const
 
 PixelLimits ()
 

Public Attributes

float data [2][2][2]
 

Detailed Description

Definition at line 79 of file ClusterShapeHitFilter.h.

Constructor & Destructor Documentation

PixelLimits::PixelLimits ( )
inline

Definition at line 80 of file ClusterShapeHitFilter.h.

References data, and MessageLogger_cfi::limit.

80  {
81  // init to make sure inside is true;
82  auto limit = data[0];
83  limit[0][0] = -10e10;
84  limit[0][1] = 10e10;
85  limit[1][0] = -10e10;
86  limit[1][1] = 10e10;
87  limit = data[1];
88  limit[0][0] = -10e10;
89  limit[0][1] = 10e10;
90  limit[1][0] = -10e10;
91  limit[1][1] = 10e10;
92  }
float data[2][2][2]

Member Function Documentation

bool PixelLimits::isInside ( const std::pair< float, float > &  pred) const
inline

Definition at line 96 of file ClusterShapeHitFilter.h.

References MessageLogger_cfi::limit.

96  {
97  auto limit = data[0];
98  bool one = (pred.first > limit[0][0]) && ( pred.first < limit[0][1] )
99  && (pred.second > limit[1][0]) && (pred.second < limit[1][1]);
100 
101  limit = data[1];
102  bool two = (pred.first > limit[0][0]) && ( pred.first < limit[0][1] )
103  && (pred.second > limit[1][0]) && (pred.second < limit[1][1]);
104 
105  return one || two;
106  }
float data[2][2][2]

Member Data Documentation

float PixelLimits::data[2][2][2]