00001 #ifndef Geom_RectangularPlaneBounds_H 00002 #define Geom_RectangularPlaneBounds_H 00003 00004 00005 #include "DataFormats/GeometryVector/interface/LocalPoint.h" 00006 #include "DataFormats/GeometrySurface/interface/Bounds.h" 00007 00008 00014 class RectangularPlaneBounds : public Bounds { 00015 public: 00016 00019 RectangularPlaneBounds( float w, float h, float t); 00020 00022 virtual float length() const { return 2*halfLength;} 00024 virtual float width() const { return 2*halfWidth;} 00026 virtual float thickness() const { return 2*halfThickness;} 00027 00028 // basic bounds function 00029 virtual bool inside( const Local2DPoint& p) const; 00030 00031 virtual bool inside( const Local3DPoint& p) const; 00032 00033 virtual bool inside( const Local3DPoint& p, const LocalError& err, 00034 float scale=1.) const; 00035 00036 virtual bool inside( const Local2DPoint& p, const LocalError& err, float scale=1.) const; 00037 00038 virtual Bounds* clone() const; 00039 00040 private: 00041 float halfWidth; 00042 float halfLength; 00043 float halfThickness; 00044 00045 }; 00046 00047 #endif