Logo ROOT  
Reference Guide
Loading...
Searching...
No Matches
TEveGeoShape.cxx
Go to the documentation of this file.
1// @(#)root/eve:$Id$
2// Author: Matevz Tadel 2007
3
4/*************************************************************************
5 * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#include "TEveGeoShape.h"
13#include "TEveTrans.h"
14#include "TEveManager.h"
16#include "TEveProjections.h"
18
19#include "TEveGeoShapeExtract.h"
20#include "TEveGeoPolyShape.h"
21
22#include "TROOT.h"
23#include "TBuffer3D.h"
24#include "TBuffer3DTypes.h"
25#include "TVirtualViewer3D.h"
26#include "TColor.h"
27#include "TFile.h"
28
29#include "TGeoShape.h"
30#include "TGeoVolume.h"
31#include "TGeoNode.h"
32#include "TGeoShapeAssembly.h"
33#include "TGeoCompositeShape.h"
34#include "TGeoBoolNode.h"
35#include "TGeoManager.h"
36#include "TGeoMatrix.h"
37#include "TVirtualGeoPainter.h"
38
39namespace
40{
41 TGeoManager* init_geo_mangeur()
42 {
43 // Create a phony geo manager that can be used for storing free
44 // shapes. Otherwise shapes register themselves to current
45 // geo-manager (or even create one).
46
48 TGeoIdentity *old_id = gGeoIdentity;
49 gGeoManager = nullptr;
50 TGeoManager* mgr = new TGeoManager();
51 mgr->SetNameTitle("TEveGeoShape::fgGeoMangeur",
52 "Static geo manager used for wrapped TGeoShapes.");
53 gGeoIdentity = new TGeoIdentity("Identity");
54 gGeoManager = old;
55 gGeoIdentity = old_id;
56 return mgr;
57 }
58
59 TGeoHMatrix localGeoHMatrixIdentity;
60}
61
62/** \class TEveGeoShape
63\ingroup TEve
64Wrapper for TGeoShape with absolute positioning and color
65attributes allowing display of extracted TGeoShape's (without an
66active TGeoManager) and simplified geometries (needed for non-linear
67projections).
68
69TGeoCompositeShapes and TGeoAssemblies are supported.
70
71If fNSegments data-member is < 2 (0 by default), the default number of
72segments is used for tesselation and special GL objects are
73instantiated for selected shapes (spheres, tubes). If fNSegments is > 2,
74it gets forwarded to geo-manager and this tesselation detail is
75used when creating the buffer passed to GL.
76*/
77
78
79TGeoManager* TEveGeoShape::fgGeoMangeur = init_geo_mangeur();
80
81////////////////////////////////////////////////////////////////////////////////
82/// Return static geo-manager that is used internally to make shapes
83/// lead a happy life.
84/// Set gGeoManager to this object when creating TGeoShapes to be
85/// passed into TEveGeoShapes.
86
91
92////////////////////////////////////////////////////////////////////////////////
93/// Return static identity matrix in homogeneous representation.
94/// This is needed because TGeoCompositeShape::PaintComposite()
95/// assumes TGeoShape::fgTransform is a TGeoHMatrix and we need to pass in
96/// an identity matrix when painting a composite shape.
97
99{
100 return &localGeoHMatrixIdentity;
101}
102
103////////////////////////////////////////////////////////////////////////////////
104/// Constructor.
105
106TEveGeoShape::TEveGeoShape(const char* name, const char* title) :
107 TEveShape (name, title),
108 fNSegments (0),
109 fShape (nullptr),
110 fCompositeShape (nullptr)
111{
113}
114
115////////////////////////////////////////////////////////////////////////////////
116/// Destructor.
117
119{
120 SetShape(nullptr);
121}
122
123////////////////////////////////////////////////////////////////////////////////
124/// Create derived TEveGeoShape form a TGeoCompositeShape.
125
130
131////////////////////////////////////////////////////////////////////////////////
132/// Set number of segments.
133
135{
136 if (s != fNSegments && fCompositeShape != nullptr)
137 {
138 delete fShape;
140 }
141 fNSegments = s;
142}
143
144////////////////////////////////////////////////////////////////////////////////
145/// Set TGeoShape shown by this object.
146///
147/// The shape is owned by TEveGeoShape but TGeoShape::fUniqueID is
148/// used for reference counting so you can pass the same shape to
149/// several TEveGeoShapes.
150///
151/// If it if is taken from an existing TGeoManager, manually
152/// increase the fUniqueID before passing it to TEveGeoShape.
153
155{
157
158 if (fCompositeShape)
159 {
160 delete fShape;
162 }
163 if (fShape)
164 {
165 fShape->SetUniqueID(fShape->GetUniqueID() - 1);
166 if (fShape->GetUniqueID() == 0)
167 {
168 delete fShape;
169 }
170 }
171 fShape = s;
172 if (fShape)
173 {
174 fShape->SetUniqueID(fShape->GetUniqueID() + 1);
175 fCompositeShape = dynamic_cast<TGeoCompositeShape*>(fShape);
176 if (fCompositeShape)
177 {
179 }
180 }
181}
182
183////////////////////////////////////////////////////////////////////////////////
184/// Compute bounding-box.
185
187{
188 TGeoBBox *bb = dynamic_cast<TGeoBBox*>(fShape);
189 if (bb)
190 {
191 BBoxInit();
192 const Double_t *o = bb->GetOrigin();
193 BBoxCheckPoint(o[0] - bb->GetDX(), o[0] - bb->GetDY(), o[0] - bb->GetDZ());
194 BBoxCheckPoint(o[0] + bb->GetDX(), o[0] + bb->GetDY(), o[0] + bb->GetDZ());
195 }
196 else
197 {
198 BBoxZero();
199 }
200}
201
202////////////////////////////////////////////////////////////////////////////////
203/// Paint object.
204
206{
207 static const TEveException eh("TEveGeoShape::Paint ");
208
209 if (fShape == nullptr)
210 return;
211
213
214 if (fCompositeShape)
215 {
216 Double_t halfLengths[3] = { fCompositeShape->GetDX(), fCompositeShape->GetDY(), fCompositeShape->GetDZ() };
217
219 buff.fID = this;
220 buff.fColor = GetMainColor();
223 buff.fLocalFrame = kTRUE; // Always enforce local frame (no geo manager).
224 buff.SetAABoundingBox(fCompositeShape->GetOrigin(), halfLengths);
226
227 Bool_t paintComponents = kTRUE;
228
229 // Start a composite shape, identified by this buffer
230 if (TBuffer3D::GetCSLevel() == 0)
231 paintComponents = gPad->GetViewer3D()->OpenComposite(buff);
232
234
235 // Paint the boolean node - will add more buffers to viewer
238 if (paintComponents) fCompositeShape->GetBoolNode()->Paint("");
240 // Close the composite shape
241 if (TBuffer3D::DecCSLevel() == 0)
242 gPad->GetViewer3D()->CloseComposite();
243 }
244 else
245 {
246 TBuffer3D& buff = (TBuffer3D&) fShape->GetBuffer3D
248
249 buff.fID = this;
250 buff.fColor = GetMainColor();
253 buff.fLocalFrame = kTRUE; // Always enforce local frame (no geo manager).
254
256 if (fNSegments > 2)
258 fShape->GetBuffer3D(sections, kTRUE);
259
260 Int_t reqSec = gPad->GetViewer3D()->AddObject(buff);
261
262 if (reqSec != TBuffer3D::kNone) {
263 // This shouldn't happen, but I suspect it does sometimes.
264 if (reqSec & TBuffer3D::kCore)
265 Warning(eh, "Core section required again for shape='%s'. This shouldn't happen.", GetName());
266 fShape->GetBuffer3D(reqSec, kTRUE);
267 reqSec = gPad->GetViewer3D()->AddObject(buff);
268 }
269
270 if (reqSec != TBuffer3D::kNone)
271 Warning(eh, "Extra section required: reqSec=%d, shape=%s.", reqSec, GetName());
272 }
273}
274
275////////////////////////////////////////////////////////////////////////////////
276/// Save the shape tree as TEveGeoShapeExtract.
277/// File is always recreated.
278/// This function is obsolete, use SaveExtractInstead().
279
280void TEveGeoShape::Save(const char* file, const char* name)
281{
282 Warning("Save()", "This function is deprecated, use SaveExtract() instead.");
283 SaveExtract(file, name);
284}
285
286////////////////////////////////////////////////////////////////////////////////
287/// Save the shape tree as TEveGeoShapeExtract.
288/// File is always recreated.
289
290void TEveGeoShape::SaveExtract(const char* file, const char* name)
291{
292 TEveGeoShapeExtract* gse = DumpShapeTree(this, nullptr);
293
294 TFile f(file, "RECREATE");
295 gse->Write(name);
296 f.Close();
297}
298
299////////////////////////////////////////////////////////////////////////////////
300/// Write the shape tree as TEveGeoShapeExtract to current directory.
301
303{
304 TEveGeoShapeExtract* gse = DumpShapeTree(this, nullptr);
305 gse->Write(name);
306}
307
308////////////////////////////////////////////////////////////////////////////////
309/// Export this shape and its descendants into a geoshape-extract.
310
312 TEveGeoShapeExtract* parent)
313{
314 TEveGeoShapeExtract* she = new TEveGeoShapeExtract(gsre->GetName(), gsre->GetTitle());
315 she->SetTrans(gsre->RefMainTrans().Array());
316 {
317 Int_t ci = gsre->GetFillColor();
318 TColor *c = gROOT->GetColor(ci);
319 Float_t rgba[4] = { 1, 0, 0, Float_t(1 - gsre->GetMainTransparency()/100.) };
320 if (c)
321 {
322 rgba[0] = c->GetRed();
323 rgba[1] = c->GetGreen();
324 rgba[2] = c->GetBlue();
325 }
326 she->SetRGBA(rgba);
327 }
328 {
329 Int_t ci = gsre->GetLineColor();
330 TColor *c = gROOT->GetColor(ci);
331 Float_t rgba[4] = { 1, 0, 0, 1 };
332 if (c)
333 {
334 rgba[0] = c->GetRed();
335 rgba[1] = c->GetGreen();
336 rgba[2] = c->GetBlue();
337 }
338 she->SetRGBALine(rgba);
339 }
340 she->SetRnrSelf(gsre->GetRnrSelf());
341 she->SetRnrElements(gsre->GetRnrChildren());
342 she->SetRnrFrame(gsre->GetDrawFrame());
343 she->SetMiniFrame(gsre->GetMiniFrame());
344 she->SetShape(gsre->GetShape());
345 if (gsre->HasChildren())
346 {
347 TList* ele = new TList();
348 she->SetElements(ele);
349 she->GetElements()->SetOwner(true);
351 while (i != gsre->EndChildren()) {
352 TEveGeoShape* l = dynamic_cast<TEveGeoShape*>(*i);
353 DumpShapeTree(l, she);
354 i++;
355 }
356 }
357 if (parent)
358 parent->GetElements()->Add(she);
359
360 return she;
361}
362
363////////////////////////////////////////////////////////////////////////////////
364/// Import a shape extract 'gse' under element 'parent'.
365
375
376////////////////////////////////////////////////////////////////////////////////
377/// Recursive version for importing a shape extract tree.
378
380 TEveElement* parent)
381{
382 TEveGeoShape* gsre = new TEveGeoShape(gse->GetName(), gse->GetTitle());
383 gsre->RefMainTrans().SetFromArray(gse->GetTrans());
384 const Float_t* rgba = gse->GetRGBA();
385 gsre->SetMainColorRGB(rgba[0], rgba[1], rgba[2]);
386 gsre->SetMainAlpha(rgba[3]);
387 rgba = gse->GetRGBALine();
388 gsre->SetLineColor(TColor::GetColor(rgba[0], rgba[1], rgba[2]));
389 gsre->SetRnrSelf(gse->GetRnrSelf());
390 gsre->SetRnrChildren(gse->GetRnrElements());
391 gsre->SetDrawFrame(gse->GetRnrFrame());
392 gsre->SetMiniFrame(gse->GetMiniFrame());
393 gsre->SetShape(gse->GetShape());
394
395 if (parent)
396 parent->AddElement(gsre);
397
398 if (gse->HasElements())
399 {
400 TIter next(gse->GetElements());
402 while ((chld = (TEveGeoShapeExtract*) next()) != nullptr)
403 SubImportShapeExtract(chld, gsre);
404 }
405
406 return gsre;
407}
408
409////////////////////////////////////////////////////////////////////////////////
410/// Return class for projected objects:
411/// - 2D projections: TEvePolygonSetProjected,
412/// - 3D projections: TEveGeoShapeProjected.
413/// Virtual from TEveProjectable.
414
416{
417 if (p->Is2D())
419 else
421}
422
423////////////////////////////////////////////////////////////////////////////////
424/// Create a TBuffer3D suitable for presentation of the shape.
425/// Transformation matrix is also applied.
426
428{
429 if (fShape == nullptr) return nullptr;
430
431 if (dynamic_cast<TGeoShapeAssembly*>(fShape)) {
432 // TGeoShapeAssembly makes a bad TBuffer3D.
433 return nullptr;
434 }
435
437
438 TBuffer3D* buff = fShape->MakeBuffer3D();
439 TEveTrans& mx = RefMainTrans();
440 if (mx.GetUseTrans())
441 {
442 Int_t n = buff->NbPnts();
443 Double_t* pnts = buff->fPnts;
444 for(Int_t k = 0; k < n; ++k)
445 {
446 mx.MultiplyIP(&pnts[3*k]);
447 }
448 }
449 return buff;
450}
451
452
453/** \class TEveGeoShapeProjected
454\ingroup TEve
455A 3D projected TEveGeoShape.
456*/
457
458
459////////////////////////////////////////////////////////////////////////////////
460/// Constructor.
461
463 TEveShape("TEveGeoShapeProjected"),
464 fBuff(nullptr)
465{
466}
467
468////////////////////////////////////////////////////////////////////////////////
469/// Destructor.
470
475
476////////////////////////////////////////////////////////////////////////////////
477/// This should never be called as this class is only used for 3D
478/// projections.
479/// The implementation is required as this metod is abstract.
480/// Just emits a warning if called.
481
483{
484 Warning("SetDepthLocal", "This function only exists to fulfill an abstract interface.");
485}
486
487////////////////////////////////////////////////////////////////////////////////
488/// This is virtual method from base-class TEveProjected.
489
498
499////////////////////////////////////////////////////////////////////////////////
500/// This is virtual method from base-class TEveProjected.
501
503{
504 TEveGeoShape *gre = dynamic_cast<TEveGeoShape*>(fProjectable);
505 TEveProjection *prj = fManager->GetProjection();
506
507 delete fBuff;
508 fBuff = gre->MakeBuffer3D();
509
510 if (fBuff)
511 {
513
514 Double_t *p = fBuff->fPnts;
515 for (UInt_t i = 0; i < fBuff->NbPnts(); ++i, p+=3)
516 {
517 prj->ProjectPointdv(p, 0);
518 }
519 }
520
521 ResetBBox();
522}
523
524////////////////////////////////////////////////////////////////////////////////
525/// Override of virtual method from TAttBBox.
526
528{
529 if (fBuff && fBuff->NbPnts() > 0)
530 {
531 BBoxInit();
532
533 Double_t *p = fBuff->fPnts;
534 for (UInt_t i = 0; i < fBuff->NbPnts(); ++i, p+=3)
535 {
536 BBoxCheckPoint(p[0], p[1], p[2]);
537 }
538 }
539 else
540 {
541 BBoxZero();
542 }
543}
#define f(i)
Definition RSha256.hxx:104
#define c(i)
Definition RSha256.hxx:101
int Int_t
Signed integer 4 bytes (int).
Definition RtypesCore.h:59
unsigned int UInt_t
Unsigned integer 4 bytes (unsigned int).
Definition RtypesCore.h:60
bool Bool_t
Boolean (0=false, 1=true) (bool).
Definition RtypesCore.h:77
constexpr Bool_t kFALSE
Definition RtypesCore.h:108
double Double_t
Double 8 bytes.
Definition RtypesCore.h:73
float Float_t
Float 4 bytes (float).
Definition RtypesCore.h:71
constexpr Bool_t kTRUE
Definition RtypesCore.h:107
const char Option_t
Option string (const char).
Definition RtypesCore.h:80
externTEveManager * gEve
char name[80]
Definition TGX11.cxx:148
externTGeoManager * gGeoManager
externTGeoIdentity * gGeoIdentity
Definition TGeoMatrix.h:538
#define gROOT
Definition TROOT.h:417
#define gPad
void BBoxCheckPoint(Float_t x, Float_t y, Float_t z)
Definition TAttBBox.h:69
void ResetBBox()
Definition TAttBBox.h:57
void BBoxZero(Float_t epsilon=0, Float_t x=0, Float_t y=0, Float_t z=0)
Create cube of volume (2*epsilon)^3 at (x,y,z).
Definition TAttBBox.cxx:41
void BBoxInit(Float_t infinity=1e6)
Allocate and prepare for incremental filling.
Definition TAttBBox.cxx:28
Generic 3D primitive description class.
Definition TBuffer3D.h:18
UInt_t NbPnts() const
Definition TBuffer3D.h:89
@ kBoundingBox
Definition TBuffer3D.h:60
@ kShapeSpecific
Definition TBuffer3D.h:61
static UInt_t DecCSLevel()
Decrement CS level.
static UInt_t GetCSLevel()
Return CS level.
void SetSectionsValid(UInt_t mask)
Definition TBuffer3D.h:74
Bool_t fLocalFrame
Definition TBuffer3D.h:99
Int_t fColor
Definition TBuffer3D.h:97
static void IncCSLevel()
Increment CS level.
Short_t fTransparency
Definition TBuffer3D.h:98
void SetAABoundingBox(const Double_t origin[3], const Double_t halfLengths[3])
Set fBBVertex in kBoundingBox section to a axis aligned (local) BB using supplied origin and box half...
TObject * fID
Definition TBuffer3D.h:96
Double_t * fPnts
Definition TBuffer3D.h:122
TClass instances represent classes, structs and namespaces in the ROOT type system.
Definition TClass.h:84
virtual void SetOwner(Bool_t enable=kTRUE)
Set whether this collection is the owner (enable==true) of its content.
static Int_t GetColor(const char *hexcolor)
virtual void InitMainTrans(Bool_t can_edit=kTRUE)
Initialize the main transformation to identity matrix.
virtual void AddElement(TEveElement *el)
Add el to the list of children.
virtual TEveTrans & RefMainTrans()
Return reference to main transformation.
List_i EndChildren()
Bool_t HasChildren() const
virtual Bool_t SetRnrChildren(Bool_t rnr)
Set render state of this element's children, i.e.
void SetMainColorRGB(UChar_t r, UChar_t g, UChar_t b)
Convert RGB values to Color_t and call SetMainColor.
void SetMainAlpha(Float_t alpha)
Set main-transparency via float alpha variable.
virtual Color_t GetMainColor() const
virtual void ElementChanged(Bool_t update_scenes=kTRUE, Bool_t redraw=kFALSE)
Call this after an element has been changed so that the state can be propagated around the framework.
virtual Bool_t GetRnrChildren() const
TEveElement()
Default constructor.
virtual Char_t GetMainTransparency() const
virtual Bool_t GetRnrSelf() const
List_i BeginChildren()
List_t::iterator List_i
Definition TEveElement.h:72
virtual Bool_t SetRnrSelf(Bool_t rnr)
Set render state of this element, i.e.
Exception class thrown by TEve classes and macros.
Definition TEveUtil.h:102
Exception safe wrapper for setting gGeoManager.
Definition TEveUtil.h:142
static TEveGeoPolyShape * Construct(TGeoCompositeShape *cshp, Int_t n_seg)
Static constructor from a composite shape.
Globally positioned TGeoShape with rendering attributes and an optional list of daughter shape-extrac...
void SetShape(TGeoShape *s)
void SetMiniFrame(Bool_t r)
Bool_t HasElements()
True if has at least one element.
void SetRGBA(const Float_t arr[4])
Set RGBA color.
void SetRGBALine(const Float_t arr[4])
Set RGBA color for line.
void SetRnrElements(Bool_t r)
void SetTrans(const Double_t arr[16])
Set transformation matrix.
void UpdateProjection() override
This is virtual method from base-class TEveProjected.
TEveGeoShapeProjected()
Constructor.
void SetDepthLocal(Float_t d) override
This should never be called as this class is only used for 3D projections.
static TClass * Class()
void ComputeBBox() override
Override of virtual method from TAttBBox.
~TEveGeoShapeProjected() override
Destructor.
void SetProjection(TEveProjectionManager *proj, TEveProjectable *model) override
This is virtual method from base-class TEveProjected.
Wrapper for TGeoShape with absolute positioning and color attributes allowing display of extracted TG...
TEveGeoShape(const TEveGeoShape &)
virtual TBuffer3D * MakeBuffer3D()
Create a TBuffer3D suitable for presentation of the shape.
void SetShape(TGeoShape *s)
Set TGeoShape shown by this object.
void SetNSegments(Int_t s)
Set number of segments.
void Save(const char *file, const char *name="Extract")
Save the shape tree as TEveGeoShapeExtract.
static TGeoManager * GetGeoMangeur()
Return static geo-manager that is used internally to make shapes lead a happy life.
TGeoCompositeShape * fCompositeShape
! Temporary holder (if passed shape is composite shape).
void SaveExtract(const char *file, const char *name)
Save the shape tree as TEveGeoShapeExtract.
TClass * ProjectedClass(const TEveProjection *p) const override
Return class for projected objects:
static TGeoHMatrix * GetGeoHMatrixIdentity()
Return static identity matrix in homogeneous representation.
static TEveGeoShape * ImportShapeExtract(TEveGeoShapeExtract *gse, TEveElement *parent=nullptr)
Import a shape extract 'gse' under element 'parent'.
static TEveGeoShape * SubImportShapeExtract(TEveGeoShapeExtract *gse, TEveElement *parent)
Recursive version for importing a shape extract tree.
static TGeoManager * fgGeoMangeur
TGeoShape * fShape
~TEveGeoShape() override
Destructor.
void ComputeBBox() override
Compute bounding-box.
void Paint(Option_t *option="") override
Paint object.
TGeoShape * MakePolyShape()
Create derived TEveGeoShape form a TGeoCompositeShape.
TEveGeoShapeExtract * DumpShapeTree(TEveGeoShape *geon, TEveGeoShapeExtract *parent=nullptr)
Export this shape and its descendants into a geoshape-extract.
TGeoShape * GetShape() const
void WriteExtract(const char *name)
Write the shape tree as TEveGeoShapeExtract to current directory.
static TClass * Class()
TEveProjectable(const TEveProjectable &)
TEveProjectable * fProjectable
TEveProjectionManager * fManager
virtual void SetProjection(TEveProjectionManager *mng, TEveProjectable *model)
Sets projection manager and reference in the projectable object.
Manager class for steering of projections and managing projected objects.
Base-class for non-linear projections.
virtual Bool_t Is2D() const =0
void ProjectPointdv(Double_t *v, Float_t d)
Project double array.
virtual void SetLineColor(Color_t c)
Definition TEveShape.h:61
TEveShape(const TEveShape &)=delete
virtual Bool_t GetMiniFrame() const
Definition TEveShape.h:58
virtual Bool_t GetDrawFrame() const
Definition TEveShape.h:56
virtual Color_t GetFillColor() const
Definition TEveShape.h:53
virtual Color_t GetLineColor() const
Definition TEveShape.h:54
virtual void SetDrawFrame(Bool_t f)
Definition TEveShape.h:63
void CopyVizParams(const TEveElement *el) override
Copy visualization parameters from element el.
Definition TEveShape.cxx:69
virtual void SetMiniFrame(Bool_t r)
Definition TEveShape.h:65
TEveTrans is a 4x4 transformation matrix for homogeneous coordinates stored internally in a column-ma...
Definition TEveTrans.h:27
void SetFromArray(const Double_t arr[16])
Set matrix from Double_t array.
Bool_t GetUseTrans() const
Definition TEveTrans.h:168
void SetBuffer3D(TBuffer3D &buff)
Fill transformation part TBuffer3D core section.
void MultiplyIP(TVector3 &v, Double_t w=1) const
Multiply vector in-place.
Double_t * Array()
Definition TEveTrans.h:94
A file, usually with extension .root, that stores data and code in the form of serialized objects in ...
Definition TFile.h:130
virtual const Double_t * GetOrigin() const
Definition TGeoBBox.h:81
virtual Double_t GetDX() const
Definition TGeoBBox.h:78
virtual Double_t GetDZ() const
Definition TGeoBBox.h:80
virtual Double_t GetDY() const
Definition TGeoBBox.h:79
Composite shapes are Boolean combinations of two or more shape components.
Matrix class used for computing global transformations Should NOT be used for node definition.
Definition TGeoMatrix.h:459
An identity transformation.
Definition TGeoMatrix.h:407
The manager class for any TGeo geometry.
Definition TGeoManager.h:46
Geometrical transformation package.
Definition TGeoMatrix.h:39
The shape encapsulating an assembly (union) of volumes.
Base abstract class for all shapes.
Definition TGeoShape.h:25
static void SetTransform(TGeoMatrix *matrix)
Set current transformation matrix that applies to shape.
static TGeoMatrix * GetTransform()
Returns current transformation matrix that applies to shape.
A doubly linked list.
Definition TList.h:38
void Add(TObject *obj) override
Definition TList.h:81
const char * GetName() const override
Returns name of object.
Definition TNamed.h:49
const char * GetTitle() const override
Returns title of object.
Definition TNamed.h:50
virtual void SetNameTitle(const char *name, const char *title)
Set all the TNamed parameters (name and title).
Definition TNamed.cxx:163
virtual void Warning(const char *method, const char *msgfmt,...) const
Issue warning message.
Definition TObject.cxx:1084
virtual Int_t Write(const char *name=nullptr, Int_t option=0, Int_t bufsize=0)
Write this object to the current directory.
Definition TObject.cxx:989
const Int_t n
Definition legend1.C:16
TLine l
Definition textangle.C:4