00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef ROOT_TGeoScaledShape
00013 #define ROOT_TGeoScaledShape
00014
00015 #ifndef ROOT_TGeoBBox
00016 #include "TGeoBBox.h"
00017 #endif
00018
00019
00020
00021
00022
00023
00024
00025
00026 class TGeoScale;
00027 class TGeoShape;
00028
00029 class TGeoScaledShape : public TGeoBBox
00030 {
00031 protected :
00032
00033 TGeoShape *fShape;
00034 TGeoScale *fScale;
00035
00036 public:
00037
00038 TGeoScaledShape();
00039 TGeoScaledShape(const char *name, TGeoShape *shape, TGeoScale *scale);
00040 TGeoScaledShape(TGeoShape *shape, TGeoScale *scale);
00041
00042 virtual ~TGeoScaledShape();
00043
00044 virtual Double_t Capacity() const;
00045 virtual void ComputeBBox();
00046 virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm);
00047 virtual Bool_t Contains(Double_t *point) const;
00048 virtual Int_t DistancetoPrimitive(Int_t px, Int_t py);
00049 virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1,
00050 Double_t step=TGeoShape::Big(), Double_t *safe=0) const;
00051 virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1,
00052 Double_t step=TGeoShape::Big(), Double_t *safe=0) const;
00053 virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv,
00054 Double_t start, Double_t step);
00055 virtual TGeoShape *GetMakeRuntimeShape(TGeoShape *mother, TGeoMatrix *mat) const;
00056 virtual const TBuffer3D &GetBuffer3D(Int_t reqSections, Bool_t localFrame) const;
00057 virtual void GetMeshNumbers(Int_t &nvert, Int_t &nsegs, Int_t &npols) const;
00058 virtual Int_t GetNmeshVertices() const {return fShape->GetNmeshVertices();}
00059 TGeoShape *GetShape() const {return fShape;}
00060 TGeoScale *GetScale() const {return fScale;}
00061 virtual void InspectShape() const;
00062 virtual Bool_t IsCylType() const {return fShape->IsCylType();}
00063 virtual Bool_t IsReflected() const;
00064 virtual TBuffer3D *MakeBuffer3D() const;
00065 static TGeoShape *MakeScaledShape(const char *name, TGeoShape *shape, TGeoScale *scale);
00066 virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const;
00067 virtual void SavePrimitive(ostream &out, Option_t *option = "");
00068 void SetScale(TGeoScale *scale) {fScale = scale;}
00069 virtual void SetPoints(Double_t *points) const;
00070 virtual void SetPoints(Float_t *points) const;
00071 virtual void SetSegsAndPols(TBuffer3D &buffer) const;
00072
00073 ClassDef(TGeoScaledShape, 1)
00074 };
00075
00076 #endif