33 const auto *
const transArray = fv.
trans();
37 string volName =
name;
38 volName.erase(0, volName.rfind(
'_') + 1);
39 volumeno =
static_cast<unsigned short>(std::atoi(volName.c_str()));
41 for (
int i = 0;
i < 6; ++
i) {
62 LogError(
"magneticfield::volumeHandle")
63 <<
"ctor: Unexpected shape # " <<
static_cast<int>(
theShape) <<
" for vol " <<
name;
74 LogTrace(
"magneticfield::volumeHandle") <<
"*** WARNING: wrong RMin/RN/RMax";
76 LogTrace(
"magneticfield::volumeHandle")
81 LogTrace(
"magneticfield::volumeHandle") <<
" Orientation of surfaces:";
82 std::string sideName[3] = {
"positiveSide",
"negativeSide",
"onSurface"};
83 for (
int i = 0;
i < 6; ++
i) {
124 dd4hep::Rotation3D refRot;
126 refRot.GetComponents(x, y, z);
128 if (x.Cross(y).Dot(z) < 0.5) {
129 LogTrace(
"magneticfield::volumeHandle") <<
"*** WARNING: Rotation is not RH ";
159 globalZdir = -globalZdir;
163 LogTrace(
"magneticfield::volumeHandle") <<
"*** WARNING RefPlane check failed!***" << chk;
168 std::vector<VolumeSide>
result;
169 for (
int i = 0;
i < 6; ++
i) {
191 template <
class NumType>
192 inline constexpr NumType convertUnits(NumType centimeters) {
193 return (centimeters);
199 #include "buildBox.icc" 200 #include "buildTrap.icc" 201 #include "buildTubs.icc" 202 #include "buildCons.icc" 203 #include "buildTruncTubs.icc"
MagGeoBuilderFromDDD::volumeHandle volumeHandle
DDSolidShape getCurrentShape(const cms::DDFilteredView &fview)
std::string_view materialName() const
Geom::Phi< T > phi() const
unsigned short volumeno
volume number
unsigned short copyno
copy number
unsigned short copyNum() const
GloballyPositioned< float > * refPlane
void referencePlane(const cms::DDFilteredView &fv)
const DDSolidShape theShape
Surface::GlobalPoint GlobalPoint
const Double_t * rot() const
The absolute rotation of the current node.
int masterSector
The sector for which an interpolator for this class of volumes should be built.
std::string_view name() const
const GlobalPoint & center() const
Return the center of the volume.
Namespace of DDCMS conversion namespace.
GlobalPoint toGlobal(const LocalPoint &lp) const
const Double_t * trans() const
The absolute translation of the current node.
XYZVectorD XYZVector
spatial vector with cartesian internal representation
std::string name
Name of the volume.
const PositionType & position() const
std::string magFile
Name of magnetic field table file.
Global3DVector GlobalVector
std::vector< VolumeSide > sides() const override
The surfaces and they orientation, as required to build a MagVolume.