38 if(shape->typeID() == GeoBox::getClassTypeID() ) {
39 const GeoBox* theBox =
dynamic_cast<const GeoBox*
> (shape);
42 out <<
" =========> Box:";
47 }
else if(shape->typeID() == GeoTube::getClassTypeID() ) {
48 const GeoTube* theTube =
dynamic_cast<const GeoTube*
> (shape);
51 out <<
" =========> Tube:";
56 }
else if(shape->typeID() == GeoTubs::getClassTypeID() ) {
57 const GeoTubs* theTubs =
dynamic_cast<const GeoTubs*
> (shape);
60 out <<
" =========> Tubs:";
67 }
else if(shape->typeID() == GeoTrd::getClassTypeID() ) {
68 const GeoTrd* theTrd =
dynamic_cast<const GeoTrd*
> (shape);
71 out <<
" =========> Trd:";
78 }
else if(shape->typeID() == GeoPcon::getClassTypeID()) {
79 const GeoPcon* thePcon =
dynamic_cast<const GeoPcon*
>(shape);
82 out <<
" =========> Pcon:";
91 }
else if(shape->typeID() == GeoCons::getClassTypeID()) {
92 const GeoCons* theCons =
dynamic_cast<const GeoCons*
>(shape);
95 out <<
" =========> Cons:";
104 }
else if(shape->typeID() == GeoPara::getClassTypeID()) {
105 const GeoPara* thePara =
dynamic_cast<const GeoPara*
>(shape);
108 out <<
" =========> Para:";
116 }
else if(shape->typeID() == GeoPgon::getClassTypeID()) {
117 const GeoPgon* thePgon =
dynamic_cast<const GeoPgon*
>(shape);
120 out <<
" =========> Pgon:";
129 }
else if(shape->typeID() == GeoTrap::getClassTypeID()) {
130 const GeoTrap* theTrap =
dynamic_cast<const GeoTrap*
>(shape);
133 out <<
" =========> Trap:";
148 else if (shape->typeID() == GeoShapeShift::getClassTypeID() ) {
149 const GeoShapeShift* theShift =
dynamic_cast<const GeoShapeShift*
>(shape);
152 out <<
" =========> GeoShapeShift:";
155 float translation_x, translation_y, translation_z, rotaxis_x, rotaxis_y, rotaxis_z, rotangle_radians;
157 translation_x, translation_y, translation_z,
158 rotaxis_x, rotaxis_y, rotaxis_z, rotangle_radians );
159 out <<
" Information about contained transformation:";
160 out <<
"===> Translation:";
164 out <<
"===> Rotation:";
170 out <<
" Information about contained GeoShape:";
175 }
else if (shape->typeID() == GeoShapeUnion::getClassTypeID() ) {
176 const GeoShapeUnion* theUnion =
dynamic_cast<const GeoShapeUnion*
>(shape);
179 out <<
" =========> GeoShapeUnion:";
180 out <<
" First operand:";
183 out <<
" Second operand:";
187 }
else if (shape->typeID() == GeoShapeIntersection::getClassTypeID() ) {
188 const GeoShapeIntersection* theIntersection =
dynamic_cast<const GeoShapeIntersection*
>(shape);
189 assert(theIntersection);
190 if (theIntersection){
191 out <<
" =========> GeoShapeIntersection:";
192 out <<
" First operand:";
195 out <<
" Second operand:";
199 }
else if (shape->typeID() == GeoShapeSubtraction::getClassTypeID() ) {
200 const GeoShapeSubtraction* theSubtraction =
dynamic_cast<const GeoShapeSubtraction*
>(shape);
201 assert(theSubtraction);
203 out <<
" =========> GeoShapeSubtraction:";
204 out <<
" First operand:";
207 out <<
" Second operand:";
211 }
else if (shape->typeID() == GeoGenericTrap::getClassTypeID() ) {
212 const GeoGenericTrap* theGenericTrap =
dynamic_cast<const GeoGenericTrap*
>(shape);
213 assert(theGenericTrap);
215 out <<
" =========> GenericTrap:";
217 std::vector<CLHEP::Hep2Vector> vertices;
218 vertices.reserve(theGenericTrap->getVertices().size());
219 for(
const auto& geoVertex : theGenericTrap->getVertices()) {
220 vertices.push_back(CLHEP::Hep2Vector(geoVertex.x(),geoVertex.y()));
223 out <<
"==> First 4 vertices at - hz/2";
228 out <<
"==> Second 4 vertices at +hz/2";
235 out <<
" =========> Unknown shape...";