CMS 3D CMS Logo

List of all members | Static Public Member Functions
BladeShapeBuilderFromDet Class Reference

#include <BladeShapeBuilderFromDet.h>

Static Public Member Functions

static BoundDiskSectorbuild (const std::vector< const GeomDet * > &dets) __attribute__((cold))
 

Detailed Description

The trapezoid has the minimal size fully containing all Dets.

Definition at line 18 of file BladeShapeBuilderFromDet.h.

Member Function Documentation

BoundDiskSector * BladeShapeBuilderFromDet::build ( const std::vector< const GeomDet * > &  dets)
static

Definition at line 123 of file BladeShapeBuilderFromDet.cc.

References objects.autophobj::float, mps_fire::i, and idealTransformation::rotation.

Referenced by Phase1PixelBlade::Phase1PixelBlade(), and PixelBlade::PixelBlade().

124 {
125  // find mean position
127  Vector posSum(0,0,0);
128  for (vector<const GeomDet*>::const_iterator i=dets.begin(); i!=dets.end(); i++) {
129  posSum += (**i).surface().position().basicVector();
130  }
131  Surface::PositionType meanPos( 0.,0.,posSum.z()/float(dets.size()) );
132 
133  // temporary plane - for the computation of bounds
134  Surface::RotationType rotation = computeRotation( dets, meanPos);
135  Plane tmpPlane( meanPos, rotation);
136 
137 
138  auto bo =
139  computeBounds( dets,tmpPlane );
140  GlobalPoint pos = meanPos+bo.second;
141  //edm::LogInfo(TkDetLayers) << "global pos in operator: " << pos ;
142  return new BoundDiskSector( pos, rotation, bo.first);
143 }
ROOT::Math::Plane3D::Vector Vector
Definition: EcalHitMaker.cc:29
Definition: Plane.h:17