194 |
|
Detid = CaloDets[i]; |
195 |
|
SubDet = Detid.subdetId(); |
196 |
|
|
197 |
< |
if(! (Detid.det()==DetId::Ecal||Detid.det()==DetId::Hcal)) continue; |
197 |
> |
if(Detid.det()!=DetId::Ecal) continue; |
198 |
|
|
199 |
|
//EcalBarrel=1, EcalEndcap=2, EcalPreshower=3, EcalTriggerTower=4, EcalLaserPnDiode=5 |
200 |
< |
// if(SubDet!=EcalBarrel)continue; |
200 |
> |
if(SubDet!=EcalBarrel)continue; |
201 |
|
|
202 |
|
const CaloCellGeometry* CellGeom = CaloGeom->getGeometry(Detid); |
203 |
|
GlobalPoint CellPos = CellGeom->getPosition(); |
204 |
|
|
205 |
|
const CaloCellGeometry::CornersVec CellCorners = CellGeom->getCorners(); |
206 |
< |
|
207 |
< |
float Coord[24]; |
208 |
< |
for(unsigned int i=0;i<8;i++){ |
209 |
< |
Coord[i*3+0] = CellCorners[i].x(); |
210 |
< |
Coord[i*3+1] = CellCorners[i].y(); |
211 |
< |
Coord[i*3+2] = CellCorners[i].z(); |
212 |
< |
} |
213 |
< |
|
214 |
< |
Geom->Add_CaloDet(Detid.rawId(), |
215 |
< |
CellPos.x(), CellPos.y(), CellPos.z(), |
216 |
< |
Coord[0 ] , Coord[1 ] , Coord[2 ] , |
217 |
< |
Coord[3 ] , Coord[4 ] , Coord[5 ] , |
218 |
< |
Coord[6 ] , Coord[7 ] , Coord[8 ] , |
219 |
< |
Coord[9 ] , Coord[10] , Coord[11] , |
220 |
< |
Coord[12] , Coord[13] , Coord[14] , |
221 |
< |
Coord[15] , Coord[16] , Coord[17] , |
222 |
< |
Coord[18] , Coord[19] , Coord[20] , |
223 |
< |
Coord[21] , Coord[22] , Coord[23] ); |
224 |
< |
|
206 |
> |
|
207 |
|
printf("Det = %i Subdet = %i --> %6.2f %6.2f %6.2f - %i\n", Detid.det(), SubDet, CellPos.x(), CellPos.y(), CellPos.z(), CellCorners.size()); |
208 |
|
} |
209 |
|
|