VGM Version 5.3
Loading...
Searching...
No Matches
Hype.cxx
Go to the documentation of this file.
1// $Id$
2
3// -----------------------------------------------------------------------
4// The RootGM package of the Virtual Geometry Model
5// Copyright (C) 2007, Ivana Hrivnacova
6// All rights reserved.
7//
8// For the licensing terms see vgm/LICENSE.
9// Contact: ivana@ipno.in2p3.fr
10// -----------------------------------------------------------------------
11
12//
13// Class Hype
14// -----------
15// VGM implementation for Root hyperboloid solid.
16//
17// Author: Ivana Hrivnacova; IPN Orsay
18
19#include "RootGM/solids/Hype.h"
20#include "RootGM/common/Units.h"
22
23#include "TGeoHype.h"
24#include "TGeoShape.h"
25
26//_____________________________________________________________________________
27RootGM::Hype::Hype(const std::string& name, double r1, double r2,
28 double stereo1, double stereo2, double hz)
29 : VGM::ISolid(),
30 VGM::IHype(),
31 BaseVGM::VHype(),
32 fHype(new TGeoHype(name.data(), r1 / RootGM::Units::Length(),
33 stereo1 / RootGM::Units::Angle(), r2 / RootGM::Units::Length(),
34 stereo2 / RootGM::Units::Angle(), hz / RootGM::Units::Length()))
35{
42
44}
45
46//_____________________________________________________________________________
47RootGM::Hype::Hype(TGeoHype* hype)
48 : VGM::ISolid(), VGM::IHype(), BaseVGM::VHype(), fHype(hype)
49{
51
53}
54
55//_____________________________________________________________________________
56RootGM::Hype::Hype() : VGM::ISolid(), VGM::IHype(), BaseVGM::VHype()
57{
59}
60
61//_____________________________________________________________________________
63 : VGM::ISolid(rhs), VGM::IHype(rhs), BaseVGM::VHype(rhs)
64{
66}
67
68//_____________________________________________________________________________
70{
71 //
72}
73
74//_____________________________________________________________________________
75std::string RootGM::Hype::Name() const { return fHype->GetName(); }
76
77//_____________________________________________________________________________
79{
80 return fHype->GetRmin() * RootGM::Units::Length();
81}
82
83//_____________________________________________________________________________
85{
86 return fHype->GetStIn() * RootGM::Units::Angle();
87}
88
89//_____________________________________________________________________________
91{
92 return fHype->GetRmax() * RootGM::Units::Length();
93}
94
95//_____________________________________________________________________________
97{
98 return fHype->GetStOut() * RootGM::Units::Angle();
99}
100
101//_____________________________________________________________________________
103{
104 return fHype->GetDz() * RootGM::Units::Length();
105}
VGM implementation for Root hyperboloid solid.
Definition Hype.h:32
virtual double InnerStereoAngle() const
Return the inner stereo angle.
Definition Hype.cxx:84
virtual double OuterStereoAngle() const
Return the inner stereo angle.
Definition Hype.cxx:96
virtual ~Hype()
Definition Hype.cxx:69
virtual double ZHalfLength() const
Return the half-length along the z axis in mm.
Definition Hype.cxx:102
virtual std::string Name() const
Return the name of this solid.
Definition Hype.cxx:75
virtual double OuterRadius() const
Return the outer radius in mm.
Definition Hype.cxx:90
virtual double InnerRadius() const
Return the inner radius in mm.
Definition Hype.cxx:78
void AddSolid(VGM::ISolid *, TGeoShape *)
Definition SolidMap.cxx:59
static SolidMap * Instance()
Definition SolidMap.cxx:28
Conversion from Root physical units to VGM units.
Definition Units.h:28
static double Length()
Return Root length unit in VGM units.
Definition Units.h:84
static double Angle()
Return Root angle unit in VGM units.
Definition Units.h:85
BaseVGM utilities.
Definition utilities.h:23
VGM implementation for Root.
Definition axis.h:28
VGM interfaces.
Definition VMedium.h:28