TGeoBBox


class description - source file - inheritance tree

class TGeoBBox : public TGeoShape


    public:
TGeoBBox TGeoBBox() TGeoBBox TGeoBBox(Double_t dx, Double_t dy, Double_t dz, Double_t* origin = 0) TGeoBBox TGeoBBox(const char* name, Double_t dx, Double_t dy, Double_t dz, Double_t* origin = 0) TGeoBBox TGeoBBox(Double_t* param) TGeoBBox TGeoBBox(const TGeoBBox&) virtual void ~TGeoBBox() static TClass* Class() virtual void ComputeBBox() virtual Bool_t Contains(Double_t* point) const virtual Bool_t CouldBeCrossed(Double_t* point, Double_t* dir) const virtual Int_t DistancetoPrimitive(Int_t px, Int_t py) virtual Double_t DistToIn(Double_t* point, Double_t* dir, Int_t iact = 1, Double_t step = 0, Double_t* safe = 0) const virtual Double_t DistToOut(Double_t* point, Double_t* dir, Int_t iact = 1, Double_t step = 0, Double_t* safe = 0) const virtual Double_t DistToSurf(Double_t* point, Double_t* dir) const virtual TGeoVolume* Divide(TGeoVolume* voldiv, const char* divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step) virtual TGeoVolume* Divide(TGeoVolume* voldiv, const char* divname, Int_t iaxis, Double_t step) virtual void GetBoundingCylinder(Double_t* param) const virtual Int_t GetByteCount() const virtual Double_t GetDX() const virtual Double_t GetDY() const virtual Double_t GetDZ() const virtual TGeoShape* GetMakeRuntimeShape(TGeoShape* mother) const virtual Double_t* GetOrigin() virtual void InspectShape() const virtual TClass* IsA() const virtual Bool_t IsCylType() const virtual Bool_t IsNullBox() const virtual Bool_t IsValidBox() const virtual void NextCrossing(TGeoParamCurve* c, Double_t* point) const virtual void Paint(Option_t* option) virtual void PaintNext(TGeoHMatrix* glmat, Option_t* option) virtual Double_t Safety(Double_t* point, Double_t* spoint, Option_t* option) const void SetBoxDimensions(Double_t dx, Double_t dy, Double_t dz, Double_t* origin = 0) void SetBoxPoints(Double_t* buff) const virtual void SetDimensions(Double_t* param) virtual void SetPoints(Double_t* buff) const virtual void SetPoints(Float_t* buff) const virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Sizeof3D() const virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b)

Data Members


    protected:
Double_t fDX X half-length Double_t fDY Y half-length Double_t fDZ Z half-length Double_t fOrigin[3] box origin


See also

TGeoArb8, TGeoCompositeShape, TGeoCone, TGeoPara, TGeoPcon, TGeoSphere, TGeoTrd1, TGeoTrd2, TGeoTube

Class Description


TGeoBBox()
 Default constructor

TGeoBBox(Double_t dx, Double_t dy, Double_t dz, Double_t *origin) :TGeoShape()
 Constructor

TGeoBBox(const char *name, Double_t dx, Double_t dy, Double_t dz, Double_t *origin) :TGeoShape(name)
 Constructor

TGeoBBox(Double_t *param) :TGeoShape()
 constructor based on the array of parameters
 param[0] - half-length in x
 param[1] - half-length in y
 param[2] - half-length in z

~TGeoBBox()
 Destructor

Bool_t CouldBeCrossed(Double_t *point, Double_t *dir) const
 decide fast if the bounding box could be crossed by a vector

Int_t DistancetoPrimitive(Int_t px, Int_t py)
 compute closest distance from point px,py to each corner

TGeoVolume* Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step)
--- Divide this box shape belonging to volume "voldiv" into ndiv equal volumes
 called divname, from start position with the given step. Returns pointer
 to created division cell volume. In case a wrong division axis is supplied,
 returns pointer to volume to be divided.

TGeoVolume* Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Double_t step)
 Divide all range of iaxis in range/step cells

void ComputeBBox()
 compute bounding box - already computed in this case

Bool_t Contains(Double_t *point) const
 test if point is inside this shape

Double_t DistToOut(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const
 compute distance from inside point to surface of the box

Double_t DistToIn(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const
 compute distance from outside point to surface of the box

Double_t DistToSurf(Double_t *point, Double_t *dir) const
 computes the distance to next surface of the box along a ray
 starting from given point to the given direction.

void GetBoundingCylinder(Double_t *param) const
--- Fill vector param[4] with the bounding cylinder parameters. The order
 is the following : Rmin, Rmax, Phi1, Phi2

TGeoShape* GetMakeRuntimeShape(TGeoShape *mother) const
 in case shape has some negative parameters, these has to be computed
 in order to fit the mother

void InspectShape() const
 print shape parameters

void NextCrossing(TGeoParamCurve *c, Double_t *point) const
 computes next intersection point of curve c with this shape

void Paint(Option_t *option)
 paint this shape according to option

void PaintNext(TGeoHMatrix *glmat, Option_t *option)
 paint this shape according to option

Double_t Safety(Double_t *point, Double_t *spoint, Option_t *option) const
 computes the closest distance from given point to this shape, according
 to option. The matching point on the shape is stored in spoint.

void SetBoxDimensions(Double_t dx, Double_t dy, Double_t dz, Double_t *origin)
 set parameters of box

void SetDimensions(Double_t *param)
 constructor based on the array of parameters
 param[0] - half-length in x
 param[1] - half-length in y
 param[2] - half-length in z

void SetBoxPoints(Double_t *buff) const

void SetPoints(Double_t *buff) const
 create box points

void SetPoints(Float_t *buff) const
 create box points

void Sizeof3D() const
 fill size of this 3-D object



Inline Functions


              Int_t GetByteCount() const
           Double_t GetDX() const
           Double_t GetDY() const
           Double_t GetDZ() const
          Double_t* GetOrigin()
             Bool_t IsCylType() const
             Bool_t IsValidBox() const
             Bool_t IsNullBox() const
            TClass* Class()
            TClass* IsA() const
               void ShowMembers(TMemberInspector& insp, char* parent)
               void Streamer(TBuffer& b)
               void StreamerNVirtual(TBuffer& b)
           TGeoBBox TGeoBBox(const TGeoBBox&)


Author: Andrei Gheata 24/10/01
Last update: root/geom:$Name: $:$Id: TGeoBBox.cxx,v 1.4 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.