Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TGeoPatternFinder.h
Go to the documentation of this file.
1// @(#)root/geom:$Id$
2// Author: Andrei Gheata 30/10/01
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, 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#ifndef ROOT_TGeoPatternFinder
13#define ROOT_TGeoPatternFinder
14
15#include "TObject.h"
16
17#include <mutex>
18#include <vector>
19
20#include "TGeoVolume.h"
21
22class TGeoMatrix;
23
24/// base finder class for patterns. A pattern is specifying a division type
25class TGeoPatternFinder : public TObject {
26public:
27 struct ThreadData_t {
28 TGeoMatrix *fMatrix; //! generic matrix
29 Int_t fCurrent; //! current division element
30 Int_t fNextIndex; //! index of next node
31
34
35 private:
36 ThreadData_t(const ThreadData_t &) = delete;
38 };
40 void ClearThreadData() const;
42
43protected:
45 Double_t fStep; // division step length
46 Double_t fStart; // starting point on divided axis
47 Double_t fEnd; // ending point
48 Int_t fNdivisions; // number of divisions
49 Int_t fDivIndex; // index of first div. node
50 TGeoVolume *fVolume; // volume to which applies
51
52 mutable std::vector<ThreadData_t *> fThreadData; //! Vector of thread private transient data
53 mutable Int_t fThreadSize; //! Size of the thread vector
54 mutable std::mutex fMutex; //! Mutex for thread data
55
56protected:
59
60public:
61 // constructors
64 // destructor
65 ~TGeoPatternFinder() override;
66 // methods
67 virtual TGeoMatrix *CreateMatrix() const = 0;
68 virtual void cd(Int_t /*idiv*/) {}
69 virtual TGeoNode *CdNext();
70 virtual TGeoNode *FindNode(Double_t * /*point*/, const Double_t * /*dir*/ = nullptr) { return nullptr; }
71 virtual Int_t GetByteCount() const { return 36; }
72 Int_t GetCurrent(); // {return fCurrent;}
74 virtual Int_t GetDivAxis() { return 1; }
75 virtual TGeoMatrix *GetMatrix(); // {return fMatrix;}
76 Int_t GetNdiv() const { return fNdivisions; }
77 Int_t GetNext() const; // {return fNextIndex;}
79 Double_t GetStart() const { return fStart; }
80 Double_t GetStep() const { return fStep; }
81 Double_t GetEnd() const { return fEnd; }
82 TGeoVolume *GetVolume() const { return fVolume; }
83 virtual Bool_t IsOnBoundary(const Double_t * /*point*/) const { return kFALSE; }
89 void SetNext(Int_t index); // {fNextIndex = index;}
90 void SetRange(Double_t start, Double_t step, Int_t ndivisions);
92 void SetVolume(TGeoVolume *vol) { fVolume = vol; }
93 virtual void UpdateMatrix(Int_t, TGeoHMatrix &) const {}
94
95 ClassDefOverride(TGeoPatternFinder, 4) // patterns to divide volumes
96};
97
98/// a X axis divison pattern
99class TGeoTranslation;
100
102public:
103 // constructors
104 TGeoPatternX();
110
111 // destructor
112 ~TGeoPatternX() override;
113 // methods
114 TGeoMatrix *CreateMatrix() const override;
115 void cd(Int_t idiv) override;
116 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
117 virtual Double_t FindNextBoundary(Double_t *point, Double_t *dir, Int_t &indnext);
118 Int_t GetDivAxis() override { return 1; }
119 Bool_t IsOnBoundary(const Double_t *point) const override;
120
122 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
123 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
124
125 ClassDefOverride(TGeoPatternX, 1) // X division pattern
126};
127
128/// a Y axis divison pattern
130public:
131 // constructors
132 TGeoPatternY();
138 // destructor
139 ~TGeoPatternY() override;
140 // methods
141 TGeoMatrix *CreateMatrix() const override;
142 void cd(Int_t idiv) override;
143 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
144 virtual Double_t FindNextBoundary(Double_t *point, Double_t *dir, Int_t &indnext);
145 Int_t GetDivAxis() override { return 2; }
146 Bool_t IsOnBoundary(const Double_t *point) const override;
147
149 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
150 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
151
152 ClassDefOverride(TGeoPatternY, 1) // Y division pattern
153};
154
155/// a Z axis divison pattern
157public:
158 // constructors
159 TGeoPatternZ();
165 // destructor
166 ~TGeoPatternZ() override;
167 // methods
168 TGeoMatrix *CreateMatrix() const override;
169 void cd(Int_t idiv) override;
170 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
171 virtual Double_t FindNextBoundary(Double_t *point, Double_t *dir, Int_t &indnext);
172 Int_t GetDivAxis() override { return 3; }
173 Bool_t IsOnBoundary(const Double_t *point) const override;
174
176 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
177 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
178
179 ClassDefOverride(TGeoPatternZ, 1) // Z division pattern
180};
181
182/// a X axis divison pattern for PARA shapes
184public:
185 // constructors
192
193 // destructor
194 ~TGeoPatternParaX() override;
195 // methods
196 TGeoMatrix *CreateMatrix() const override;
197 void cd(Int_t idiv) override;
198 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
199 Int_t GetDivAxis() override { return 1; }
200 Bool_t IsOnBoundary(const Double_t *point) const override;
201
203 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
204 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
205
206 ClassDefOverride(TGeoPatternParaX, 1) // Para X division pattern
207};
208
209/// a Y axis divison pattern for PARA shapes
211private:
212 // data members
213 Double_t fTxy = 0.; // tangent of alpha
214public:
215 // constructors
222
223 // destructor
224 ~TGeoPatternParaY() override;
225 // methods
226 TGeoMatrix *CreateMatrix() const override;
227 void cd(Int_t idiv) override;
228 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
229 Int_t GetDivAxis() override { return 2; }
230 Bool_t IsOnBoundary(const Double_t *point) const override;
231
233 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
234 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
235
236 ClassDefOverride(TGeoPatternParaY, 1) // Para Y division pattern
237};
238
239/// a Z axis divison pattern for PARA shapes
241private:
242 // data members
243 Double_t fTxz = 0.; // tangent of alpha xz
244 Double_t fTyz = 0.; // tangent of alpha yz
245public:
246 // constructors
253
254 // destructor
255 ~TGeoPatternParaZ() override;
256 // methods
257 TGeoMatrix *CreateMatrix() const override;
258 void cd(Int_t idiv) override;
259 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
260 Int_t GetDivAxis() override { return 3; }
261 Bool_t IsOnBoundary(const Double_t *point) const override;
262
264 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
265 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
266
267 ClassDefOverride(TGeoPatternParaZ, 1) // Para Z division pattern
268};
269
270/// a Z axis divison pattern for TRAP or GTRA shapes
272private:
273 // data members
274 Double_t fTxz = 0.; // tangent of alpha xz
275 Double_t fTyz = 0.; // tangent of alpha yz
276public:
277 // constructors
284
285 // destructor
286 ~TGeoPatternTrapZ() override;
287 // methods
288 TGeoMatrix *CreateMatrix() const override;
289 Double_t GetTxz() const { return fTxz; }
290 Double_t GetTyz() const { return fTyz; }
291 void cd(Int_t idiv) override;
292 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
293 Int_t GetDivAxis() override { return 3; }
294 Bool_t IsOnBoundary(const Double_t *point) const override;
295
297 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
298 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
299
300 ClassDefOverride(TGeoPatternTrapZ, 1) // Trap od Gtra Z division pattern
301};
302
303/// a cylindrical R divison pattern
305public:
306 // constructors
313 // destructor
314 ~TGeoPatternCylR() override;
315 // methods
316 TGeoMatrix *CreateMatrix() const override;
317 void cd(Int_t idiv) override;
318 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
319 Int_t GetDivAxis() override { return 1; }
320 Bool_t IsOnBoundary(const Double_t *point) const override;
321
323 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
324 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
325
326 ClassDefOverride(TGeoPatternCylR, 1) // Cylindrical R division pattern
327};
328
329/// a cylindrical phi divison pattern
331private:
332 // data members
333 Double_t *fSinCos = nullptr; //![2*fNdivisions] table of sines/cosines
334
335protected:
341 {
342 if (this != &pfc) {
344 fSinCos = pfc.fSinCos;
346 }
347 return *this;
348 }
349
350public:
351 // constructors
356 // destructor
357 ~TGeoPatternCylPhi() override;
358 // methods
359 TGeoMatrix *CreateMatrix() const override;
360 void cd(Int_t idiv) override;
361 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
362 Int_t GetDivAxis() override { return 2; }
363 Bool_t IsOnBoundary(const Double_t *point) const override;
364
366 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
367 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
368
369 ClassDefOverride(TGeoPatternCylPhi, 1) // Cylindrical phi division pattern
370};
371
372/// a spherical R divison pattern
374public:
375 // constructors
382 // destructor
383 ~TGeoPatternSphR() override;
384 // methods
385 TGeoMatrix *CreateMatrix() const override;
386 void cd(Int_t idiv) override;
387 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
388 Int_t GetDivAxis() override { return 1; }
389
391 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
392 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
393
394 ClassDefOverride(TGeoPatternSphR, 1) // spherical R division pattern
395};
396
397/// a spherical theta divison pattern
399public:
400 // constructors
407 // destructor
408 ~TGeoPatternSphTheta() override;
409 // methods
410 TGeoMatrix *CreateMatrix() const override;
411 void cd(Int_t idiv) override;
412 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
413 Int_t GetDivAxis() override { return 3; }
414
416 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
417 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
418
419 ClassDefOverride(TGeoPatternSphTheta, 1) // spherical theta division pattern
420};
421
422/// a spherical phi divison pattern
424private:
425 Double_t *fSinCos = nullptr; //! Sincos table
426
427protected:
431
432public:
433 // constructors
438 // destructor
439 ~TGeoPatternSphPhi() override;
440 // methods
441 TGeoMatrix *CreateMatrix() const override;
442 void cd(Int_t idiv) override;
443 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
444 Int_t GetDivAxis() override { return 2; }
445 Bool_t IsOnBoundary(const Double_t *point) const override;
446
448 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
449 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
450
451 ClassDefOverride(TGeoPatternSphPhi, 1) // Spherical phi division pattern
452};
453
454/// a divison pattern specialized for honeycombs
456private:
457 // data members
458 Int_t fNrows; // number of rows
459 Int_t fAxisOnRows; // axis along each row
460 Int_t *fNdivisions; // [fNrows] number of divisions for each row
461 Double_t *fStart; // [fNrows] starting points for each row
462
463protected:
466
467public:
468 // constructors
471 // destructor
472 ~TGeoPatternHoneycomb() override;
473 // methods
474 TGeoPatternFinder *MakeCopy(Bool_t) override { return nullptr; }
475 TGeoMatrix *CreateMatrix() const override;
476 void cd(Int_t idiv) override;
477 TGeoNode *FindNode(Double_t *point, const Double_t *dir = nullptr) override;
478 void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override;
479
480 ClassDefOverride(TGeoPatternHoneycomb, 1) // pattern for honeycomb divisions
481};
482
483#endif
bool Bool_t
Definition RtypesCore.h:63
int Int_t
Definition RtypesCore.h:45
constexpr Bool_t kFALSE
Definition RtypesCore.h:94
double Double_t
Definition RtypesCore.h:59
constexpr Bool_t kTRUE
Definition RtypesCore.h:93
const char Option_t
Definition RtypesCore.h:66
#define BIT(n)
Definition Rtypes.h:91
#define ClassDefOverride(name, id)
Definition Rtypes.h:348
Option_t Option_t option
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t index
Matrix class used for computing global transformations Should NOT be used for node definition.
Definition TGeoMatrix.h:458
Geometrical transformation package.
Definition TGeoMatrix.h:38
A node represent a volume positioned inside another.They store links to both volumes and to the TGeoM...
Definition TGeoNode.h:39
a cylindrical phi divison pattern
TGeoPatternCylPhi()
Default constructor.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoPatternCylPhi(const TGeoPatternCylPhi &pfc)
[2*fNdivisions] table of sines/cosines
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
find the node containing the query point
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
~TGeoPatternCylPhi() override
Destructor.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
Int_t GetDivAxis() override
TGeoPatternCylPhi & operator=(const TGeoPatternCylPhi &pfc)
a cylindrical R divison pattern
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
TGeoPatternCylR()
Default constructor.
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
find the node containing the query point
TGeoPatternCylR & operator=(const TGeoPatternCylR &)
assignment operator
Int_t GetDivAxis() override
~TGeoPatternCylR() override
Destructor.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
base finder class for patterns. A pattern is specifying a division type
ThreadData_t & GetThreadData() const
virtual void cd(Int_t)
void Reflect(Bool_t flag=kTRUE)
virtual TGeoNode * CdNext()
Make next node (if any) current.
void SetSpacedOut(Bool_t flag)
void SetDivIndex(Int_t index)
virtual TGeoMatrix * GetMatrix()
Return current matrix.
void SetRange(Double_t start, Double_t step, Int_t ndivisions)
Set division range. Use this method only when dividing an assembly.
virtual TGeoNode * FindNode(Double_t *, const Double_t *=nullptr)
virtual void UpdateMatrix(Int_t, TGeoHMatrix &) const
std::vector< ThreadData_t * > fThreadData
Int_t fThreadSize
Vector of thread private transient data.
TGeoPatternFinder & operator=(const TGeoPatternFinder &)
assignment operator
void SetNext(Int_t index)
Set index of next division.
virtual TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE)=0
virtual Int_t GetDivAxis()
~TGeoPatternFinder() override
Destructor.
virtual Bool_t IsOnBoundary(const Double_t *) const
Int_t GetNdiv() const
TGeoVolume * GetVolume() const
Bool_t IsReflected() const
void SetVolume(TGeoVolume *vol)
Double_t GetStep() const
Int_t GetCurrent()
Return current index.
void ClearThreadData() const
Bool_t IsSpacedOut() const
Double_t GetStart() const
TGeoPatternFinder()
Default constructor.
Int_t GetNext() const
Get index of next division.
virtual Int_t GetByteCount() const
std::mutex fMutex
Size of the thread vector.
Double_t GetEnd() const
TGeoNode * GetNodeOffset(Int_t idiv)
void CreateThreadData(Int_t nthreads)
Create thread data for n threads max.
virtual TGeoMatrix * CreateMatrix() const =0
a divison pattern specialized for honeycombs
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoPatternFinder * MakeCopy(Bool_t) override
TGeoPatternHoneycomb()
Default constructor.
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
~TGeoPatternHoneycomb() override
destructor
TGeoPatternHoneycomb & operator=(const TGeoPatternHoneycomb &)
assignment operator
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
find the node containing the query point
a X axis divison pattern for PARA shapes
~TGeoPatternParaX() override
Destructor.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
get the node division containing the query point
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
TGeoPatternParaX()
Default constructor.
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
Int_t GetDivAxis() override
TGeoPatternParaX & operator=(const TGeoPatternParaX &)
assignment operator
a Y axis divison pattern for PARA shapes
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
Int_t GetDivAxis() override
~TGeoPatternParaY() override
Destructor.
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
get the node division containing the query point
TGeoPatternParaY()
Default constructor.
TGeoPatternParaY & operator=(const TGeoPatternParaY &)
assignment operator
a Z axis divison pattern for PARA shapes
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
~TGeoPatternParaZ() override
Destructor.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoPatternParaZ & operator=(const TGeoPatternParaZ &)
assignment operator
Int_t GetDivAxis() override
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
get the node division containing the query point
TGeoPatternParaZ()
Default constructor.
a spherical phi divison pattern
TGeoPatternSphPhi()
Default constructor.
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
find the node containing the query point
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
Int_t GetDivAxis() override
TGeoPatternSphPhi & operator=(const TGeoPatternSphPhi &pfc)=delete
~TGeoPatternSphPhi() override
Destructor.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
TGeoPatternSphPhi(const TGeoPatternSphPhi &pfc)=delete
Sincos table.
Double_t * CreateSinCos()
Create the sincos table if it does not exist.
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
a spherical R divison pattern
Int_t GetDivAxis() override
~TGeoPatternSphR() override
Destructor.
TGeoPatternSphR()
Default constructor.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
find the node containing the query point
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
TGeoPatternSphR & operator=(const TGeoPatternSphR &)
assignment operator
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
a spherical theta divison pattern
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
find the node containing the query point
~TGeoPatternSphTheta() override
Destructor.
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
TGeoPatternSphTheta()
Default constructor.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
TGeoPatternSphTheta & operator=(const TGeoPatternSphTheta &)
assignment operator
Int_t GetDivAxis() override
a Z axis divison pattern for TRAP or GTRA shapes
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
Double_t GetTxz() const
Double_t GetTyz() const
TGeoPatternTrapZ()
Default constructor.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
get the node division containing the query point
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
Int_t GetDivAxis() override
TGeoPatternTrapZ & operator=(const TGeoPatternTrapZ &)
assignment operator
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
~TGeoPatternTrapZ() override
Destructor.
TGeoPatternX & operator=(const TGeoPatternX &)
assignment operator
~TGeoPatternX() override
Destructor.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
virtual Double_t FindNextBoundary(Double_t *point, Double_t *dir, Int_t &indnext)
Compute distance to next division layer returning the index of next section.
TGeoPatternX()
Default constructor.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
Int_t GetDivAxis() override
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
Find the cell corresponding to point and next cell along dir (if asked)
a Y axis divison pattern
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
Find the cell corresponding to point and next cell along dir (if asked)
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
TGeoPatternY & operator=(const TGeoPatternY &)
assignment operator
Int_t GetDivAxis() override
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
~TGeoPatternY() override
Destructor.
TGeoPatternY()
Default constructor.
virtual Double_t FindNextBoundary(Double_t *point, Double_t *dir, Int_t &indnext)
Compute distance to next division layer returning the index of next section.
a Z axis divison pattern
void cd(Int_t idiv) override
Update current division index and global matrix to point to a given slice.
TGeoMatrix * CreateMatrix() const override
Return new matrix of type used by this finder.
TGeoNode * FindNode(Double_t *point, const Double_t *dir=nullptr) override
Find the cell corresponding to point and next cell along dir (if asked)
virtual Double_t FindNextBoundary(Double_t *point, Double_t *dir, Int_t &indnext)
Compute distance to next division layer returning the index of next section.
TGeoPatternZ()
Default constructor.
~TGeoPatternZ() override
Destructor.
Int_t GetDivAxis() override
TGeoPatternFinder * MakeCopy(Bool_t reflect=kFALSE) override
Make a copy of this finder. Reflect by Z if required.
TGeoPatternZ & operator=(const TGeoPatternZ &)
assignment operator
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a primitive as a C++ statement(s) on output stream "out".
Bool_t IsOnBoundary(const Double_t *point) const override
Checks if the current point is on division boundary.
void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const override
Fills external matrix with the local one corresponding to the given division index.
Class describing translations.
Definition TGeoMatrix.h:116
TGeoVolume, TGeoVolumeMulti, TGeoVolumeAssembly are the volume classes.
Definition TGeoVolume.h:43
TGeoNode * GetNode(const char *name) const
get the pointer to a daughter node
Mother of all ROOT objects.
Definition TObject.h:41
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
Definition TObject.h:202
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
Definition TObject.cxx:864
ThreadData_t(const ThreadData_t &)=delete
Int_t fNextIndex
current division element
ThreadData_t & operator=(const ThreadData_t &)=delete