TGeoNode


class description - source file - inheritance tree

class TGeoNode : public TNamed, public TGeoAtt


    public:
virtual void ~TGeoNode() virtual void Browse(TBrowser* b) virtual void cd() const void CheckShapes() static TClass* Class() virtual void Draw(Option_t* option) void DrawOnly(Option_t* option) void DrawOverlaps() Int_t FindNode(TGeoNode* node, Int_t level) virtual Int_t GetByteCount() const Int_t GetColour() const TGeoNode* GetDaughter(Int_t ind) const virtual TGeoPatternFinder* GetFinder() const virtual Int_t GetIndex() const virtual TGeoMatrix* GetMatrix() const Int_t GetMedia() const TGeoVolume* GetMotherVolume() const Int_t GetNdaughters() const TObjArray* GetNodes() const virtual Int_t GetOptimalVoxels() const Int_t* GetOverlaps(Int_t& novlp) const TGeoVolume* GetVolume() const void InspectNode() const virtual TClass* IsA() const virtual Bool_t IsFolder() const Bool_t IsOffset() const Bool_t IsOnScreen() const Bool_t IsOverlapping() const Bool_t IsVirtual() const virtual Bool_t IsVisible() const virtual void LocalToMaster(const Double_t* local, Double_t* master) const virtual void LocalToMasterVect(const Double_t* local, Double_t* master) const virtual void ls(Option_t* option) const virtual TGeoNode* MakeCopyNode() const virtual void MasterToLocal(const Double_t* master, Double_t* local) const virtual void MasterToLocalVect(const Double_t* master, Double_t* local) const virtual void Paint(Option_t* option) void PrintCandidates() const void PrintOverlaps() const void SaveAttributes(ofstream& out) const void SetCurrentPoint(Double_t x, Double_t y, Double_t z) void SetMotherVolume(TGeoVolume* mother) void SetOverlaps(Int_t* ovlp, Int_t novlp) void SetVirtual() void SetVolume(TGeoVolume* volume) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b) void VisibleDaughters(Bool_t vis)

Data Members


    protected:
Int_t fNovlp ! number of overlaps Int_t* fOverlaps ![fNovlp] list of indices for overlapping brothers TGeoVolume* fVolume volume associated with this TGeoVolume* fMother mother volume public:
static const enum TObject:: kGeoNodeMatrix static const enum TObject:: kGeoNodeOffset static const enum TObject:: kGeoNodeVC


See also

TGeoNodeMatrix, TGeoNodeOffset

Class Description

 TGeoNode
----------
   Nodes are positioned volumes. They have a pointer to the corresponding
 volume. Nodes always belong to a mother container volume, so they also
 have a pointer to this. The base class for nodes is TGeoNode, describing only
 the logical tree. The position of the node with respect to its mother is
 defined by classes deriving from TGeoNode and is stored as a transformation
 matrix by TGeoNodeMatrix or just an offset by division nodes (TGeoNodeXXX).
   Nodes are invisible to user at build time : to create a node one has only
 to call TGeoVolume::AddNode() or TGeoVolume::Divide() methods. In the first
 case, the volume pointed by the node and the geometrical transformation with
 respect to the mother must be created a priori :

   TGeoVolume *vol = new TGeoSphere("SPH", 200, 400);
   TGeoVolume *mother = gGeoManager->MakeBox("HALL", "mat1", 1000, 1000, 3000);
   TGeoTranslation *t1 = new TGeoTranslation(0, 0, 300);
   mother->AddNode(vol, t1);

   The last line will create a branch : HALL->SPH . A node named SPH:0 will
 be created. If trying to place the same volume many times inside the same
 mother, the automatic naming scheme for the corresponding nodes is just
 appending <:copy_number> to the name of the volume. Therefore :

   TGeoTranslation *t2 = new TGeoTranslation(0,0,-300);
   mother->AddNode(vol, t2);

 will create a TGeoNodeMatrix named SPH:1 inside HALL.

   When creating division nodes (TGeoVolume::Divide()), one has to specify the
 number of divisions, optionally the range for dividing and an string option
 specifying the division type. A list of TGeoNodeOffset will be generated :

   mother->Divide(5, "X");

 will create five TGeoNodeOffset nodes, pointing to the same basic cell volume
 which is automatically generated :

   HALL:0 --|
   HALL:1 --|
   HALL:2 --|---> HALL_C = gGeoManager->MakeBox("HALL_C", "mat1", 200, 1000, 3000)
   HALL:3 --|
   HALL:4 --|

   One can subsequently add usual nodes inside HALL_C cell or divide it, and the
 action will affect all nodes HALL:i .
   If the basic cell volumes coming from a division operation are not identical,
 a volume will be generated per division node, and the naming sheme for them
 will be HALL_d1, HALL_d2, ... .

 Browsing nodes. (to be added)

 Node flags.(to be added)


/*

*/


~TGeoNode()
 Destructor

void Browse(TBrowser *b)

Bool_t IsOnScreen() const
 check if this node is drawn. Assumes that this node is current

void InspectNode() const

void CheckShapes()
 check for wrong parameters in shapes

void DrawOnly(Option_t *option)
 draw only this node independently of its vis options

void Draw(Option_t *option)
 draw current node according to option

void DrawOverlaps()

Int_t FindNode(TGeoNode *node, Int_t level)

void SaveAttributes(ofstream &out) const
 save attributes for this node

void MasterToLocal(const Double_t *master, Double_t *local) const
 Convert the point coordinates from mother reference to local reference system

void MasterToLocalVect(const Double_t *master, Double_t *local) const
 Convert a vector from mother reference to local reference system

void LocalToMaster(const Double_t *local, Double_t *master) const
 Convert the point coordinates from local reference system to mother reference

void LocalToMasterVect(const Double_t *local, Double_t *master) const
 Convert a vector from local reference system to mother reference

void ls(Option_t *option) const
 Print the path (A/B/C/...) to this node on stdout

void Paint(Option_t *option)
 Paint this node and its content according to visualization settings.

void PrintCandidates() const
 print daughters candidates for containing current point
   cd();

void PrintOverlaps() const
 print possible overlapping nodes

void SetOverlaps(Int_t *ovlp, Int_t novlp)
 set the list of overlaps for this node (ovlp must be created with operator new)

void VisibleDaughters(Bool_t vis)



Inline Functions


                      void cd() const
                     Int_t GetByteCount() const
                 TGeoNode* GetDaughter(Int_t ind) const
               TGeoMatrix* GetMatrix() const
                     Int_t GetColour() const
                     Int_t GetIndex() const
        TGeoPatternFinder* GetFinder() const
                     Int_t GetMedia() const
               TGeoVolume* GetMotherVolume() const
                     Int_t GetNdaughters() const
                TObjArray* GetNodes() const
                    Int_t* GetOverlaps(Int_t& novlp) const
               TGeoVolume* GetVolume() const
                     Int_t GetOptimalVoxels() const
                    Bool_t IsFolder() const
                    Bool_t IsOffset() const
                    Bool_t IsOverlapping() const
                    Bool_t IsVirtual() const
                    Bool_t IsVisible() const
                 TGeoNode* MakeCopyNode() const
                      void SetCurrentPoint(Double_t x, Double_t y, Double_t z)
                      void SetVolume(TGeoVolume* volume)
                      void SetVirtual()
                      void SetMotherVolume(TGeoVolume* mother)
                   TClass* Class()
                   TClass* IsA() const
                      void ShowMembers(TMemberInspector& insp, char* parent)
                      void Streamer(TBuffer& b)
                      void StreamerNVirtual(TBuffer& b)


Author: Andrei Gheata 24/10/01
Last update: root/geom:$Name: $:$Id: TGeoNode.cxx,v 1.7 2002/09/27 16:16:06 brun Exp $
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *


ROOT page - Class index - Top of the page

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.