24 #include "CLHEP/Units/GlobalSystemOfUnits.h"
45 const std::vector<DetId>& detids(rig.
detIds());
51 while(idt < detids.size()) {
56 if (chamber) theGeometry->add(chamber);
60 chamber = buildChamber(chid, rig, idt);
65 sl = buildSuperLayer(chamber, slid, rig, idt);
71 DTLayer* lay = buildLayer(sl, lid, rig, idt);
72 theGeometry->add(lay);
74 cout <<
"What is this?" << endl;
78 if (chamber) theGeometry->add(chamber);
88 float length = (*(rig.
shapeStart(idt) + 2))/cm;
89 float thickness = (*(rig.
shapeStart(idt) + 3))/cm;
111 float length = (*(rig.
shapeStart(idt) + 2))/cm;
112 float thickness = (*(rig.
shapeStart(idt) + 3))/cm;
120 chamber->
add(slayer);
134 float length = (*(rig.
shapeStart(idt) + 2))/cm;
135 float thickness = (*(rig.
shapeStart(idt) + 3))/cm;
141 int firstWire=int(*(rig.
shapeStart(idt) + 4 ));
142 int WCounter=int(*(rig.
shapeStart(idt) + 5 ));
143 double sensibleLenght=(*(rig.
shapeStart(idt) + 6 ))/cm;
144 DTTopology topology(firstWire, WCounter, sensibleLenght);
148 DTLayer* layer =
new DTLayer(layId, surf, topology, layerType, sl);
157 const vector<double>::const_iterator rotStart,
163 *(rotStart+3), *(rotStart+4), *(rotStart+5),
164 *(rotStart+6), *(rotStart+7), *(rotStart+8) );
std::vector< double >::const_iterator rotStart(size_t ind) const
void add(DTLayer *l)
Add layer to the SL which owns it.
void build(boost::shared_ptr< DTGeometry > theGeometry, const RecoIdealGeometry &rig)
std::vector< double >::const_iterator tranStart(size_t ind) const
DTChamber * buildChamber(const DetId &id, const RecoIdealGeometry &rig, size_t idt) const
const std::vector< DetId > & detIds() const
DTLayer * buildLayer(DTSuperLayer *sl, const DetId &id, const RecoIdealGeometry &rig, size_t idt) const
virtual ~DTGeometryBuilderFromCondDB()
std::vector< double >::const_iterator shapeStart(size_t ind) const
DTGeometryBuilderFromCondDB()
void add(DTSuperLayer *sl)
Add SL to the chamber which takes ownership.
DTSuperLayer * buildSuperLayer(DTChamber *chamber, const DetId &id, const RecoIdealGeometry &rig, size_t idt) const
RCPPlane plane(const std::vector< double >::const_iterator tranStart, const std::vector< double >::const_iterator rotStart, Bounds *bounds) const