Go to the documentation of this file.00001 #include "TrackingTools/GeomPropagators/interface/TrackerBounds.h"
00002
00003 #include "DataFormats/GeometrySurface/interface/BoundCylinder.h"
00004 #include "DataFormats/GeometrySurface/interface/BoundDisk.h"
00005 #include "DataFormats/GeometrySurface/interface/SimpleCylinderBounds.h"
00006 #include "DataFormats/GeometrySurface/interface/SimpleDiskBounds.h"
00007
00008
00009
00010
00011
00012 void TrackerBounds::initialize()
00013 {
00014 const float epsilon = 0.001;
00015
00016 Surface::RotationType rot;
00017 auto cb = new SimpleCylinderBounds( radius()-epsilon,
00018 radius()+epsilon,
00019 -halfLength(), halfLength()
00020 );
00021
00022 theCylinder = new Cylinder(Cylinder::computeRadius(*cb), Surface::PositionType(0,0,0), rot, cb);
00023
00024
00025 theNegativeDisk =
00026 new Disk( Surface::PositionType( 0, 0, -halfLength()), rot,
00027 new SimpleDiskBounds( 0, radius(), -epsilon, epsilon));
00028
00029 thePositiveDisk =
00030 new Disk( Surface::PositionType( 0, 0, halfLength()), rot,
00031 new SimpleDiskBounds( 0, radius(), -epsilon, epsilon));
00032
00033
00034 theInit = true;
00035 }
00036
00037 bool TrackerBounds::isInside(const GlobalPoint &point){
00038 return (point.perp() <= radius() &&
00039 fabs(point.z()) <= halfLength());
00040 }
00041
00042
00043
00044
00045 ReferenceCountingPointer<BoundCylinder> TrackerBounds::theCylinder = 0;
00046 ReferenceCountingPointer<BoundDisk> TrackerBounds::theNegativeDisk = 0;
00047 ReferenceCountingPointer<BoundDisk> TrackerBounds::thePositiveDisk = 0;
00048
00049 bool TrackerBounds::theInit = false;
00050
00051