Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-10-25 09:50:10

0001 // Make the change for "big" pixels. 3/06 d.k.
0002 #include "Geometry/TrackerGeometryBuilder/interface/PixelTopologyBuilder.h"
0003 #include "Geometry/TrackerGeometryBuilder/interface/RectangularPixelTopology.h"
0004 #include "DataFormats/GeometrySurface/interface/Bounds.h"
0005 
0006 PixelTopologyBuilder::PixelTopologyBuilder(void) {}
0007 
0008 PixelTopology* PixelTopologyBuilder::build(
0009     const Bounds* bs,
0010     bool upgradeGeometry,
0011     int pixelROCRows,       // Num of Rows per ROC
0012     int pixelROCCols,       // Num of Cols per ROC
0013     int BIG_PIX_PER_ROC_X,  // in x direction, rows. BIG_PIX_PER_ROC_X = 0 for SLHC
0014     int BIG_PIX_PER_ROC_Y,  // in y direction, cols. BIG_PIX_PER_ROC_Y = 0 for SLHC
0015     int pixelROCsInX,
0016     int pixelROCsInY) {
0017   float width = bs->width();    // module width = Xsize
0018   float length = bs->length();  // module length = Ysize
0019 
0020   // Number of pixel rows (x) and columns (y) per module
0021   int nrows = pixelROCRows * pixelROCsInX;
0022   int ncols = pixelROCCols * pixelROCsInY;
0023 
0024   // Take into account the large edge pixles
0025   // 1 big pixel per ROC
0026   float pitchX = width / (nrows + pixelROCsInX * BIG_PIX_PER_ROC_X);
0027   // 2 big pixels per ROC
0028   float pitchY = length / (ncols + pixelROCsInY * BIG_PIX_PER_ROC_Y);
0029 
0030   return (new RectangularPixelTopology(nrows,
0031                                        ncols,
0032                                        pitchX,
0033                                        pitchY,
0034                                        upgradeGeometry,
0035                                        pixelROCRows,  // (int)rocRow
0036                                        pixelROCCols,  // (int)rocCol
0037                                        BIG_PIX_PER_ROC_X,
0038                                        BIG_PIX_PER_ROC_Y,
0039                                        pixelROCsInX,
0040                                        pixelROCsInY));  // (int)rocInX, (int)rocInY
0041 }