CMS 3D CMS Logo

DDCutTubsFromPoints.h
Go to the documentation of this file.
1 #ifndef DD_CutTubsFromPoints_h
2 #define DD_CutTubsFromPoints_h
3 
4 #include <map>
5 #include <string>
6 #include <vector>
10 
11 // This algorithm creates a ring made of CutTubs segments from the phi,z points
12 // of the rings "corners".
13 // The algorithm only defines and places two copies of a single Solid with the given name.
14 class DDCutTubsFromPoints : public DDAlgorithm {
15  public:
16  //Constructor and Destructor
18  virtual ~DDCutTubsFromPoints();
19 
20  void initialize(const DDNumericArguments & nArgs,
21  const DDVectorArguments & vArgs,
22  const DDMapArguments & mArgs,
23  const DDStringArguments & sArgs,
24  const DDStringVectorArguments & vsArgs);
25 
26  void execute(DDCompactView& cpv);
27 
28 private:
29  struct Section {
30  double phi; // phi position of this edge
31  double z_l; // -Z end (cuttubs l plane)
32  double z_t; // +Z end (cuttubs t plane)
33  // radius is implicitly r_min
34  };
35 
36  double r_min;
37  double r_max;
38  double z_pos;
40 
41  // a segment is produced between each two consecutive sections that have a
42  // non-zero phi distance. Sections with zero phi distance can be used to
43  // create sharp jumps.
44  std::vector<Section> sections;
45  // this solid will be defined.
47 
48 
49 };
50 
51 #endif
DDMaterial is used to define and access material information.
Definition: DDMaterial.h:41
std::vector< Section > sections
DDName is used to identify DDD entities uniquely.
Definition: DDName.h:15
type of data representation of DDCompactView
Definition: DDCompactView.h:90
void execute(DDCompactView &cpv)
void initialize(const DDNumericArguments &nArgs, const DDVectorArguments &vArgs, const DDMapArguments &mArgs, const DDStringArguments &sArgs, const DDStringVectorArguments &vsArgs)