ROOT logo
// @(#)root/eve:$Id$
// Author: Matevz Tadel 2007

/*************************************************************************
 * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#include "TEveGeoShape.h"
#include "TEveTrans.h"
#include "TEveManager.h"
#include "TEvePolygonSetProjected.h"
#include "TEveProjections.h"
#include "TEveProjectionManager.h"

#include "TEveGeoShapeExtract.h"
#include "TEveGeoPolyShape.h"

#include "TROOT.h"
#include "TBuffer3D.h"
#include "TBuffer3DTypes.h"
#include "TVirtualViewer3D.h"
#include "TColor.h"
#include "TFile.h"

#include "TGeoShape.h"
#include "TGeoVolume.h"
#include "TGeoNode.h"
#include "TGeoShapeAssembly.h"
#include "TGeoCompositeShape.h"
#include "TGeoBoolNode.h"
#include "TGeoManager.h"
#include "TGeoMatrix.h"
#include "TVirtualGeoPainter.h"

namespace
{
   TGeoManager* init_geo_mangeur()
   {
      // Create a phony geo manager that can be used for storing free
      // shapes. Otherwise shapes register themselves to current
      // geo-manager (or even create one).

      TGeoManager  *old    = gGeoManager;
      TGeoIdentity *old_id = gGeoIdentity;
      gGeoManager = 0;
      TGeoManager* mgr = new TGeoManager();
      mgr->SetNameTitle("TEveGeoShape::fgGeoMangeur",
                        "Static geo manager used for wrapped TGeoShapes.");
      gGeoIdentity = new TGeoIdentity("Identity");
      gGeoManager  = old;
      gGeoIdentity = old_id;
      return mgr;
   }

  TGeoHMatrix localGeoHMatrixIdentity;
}

//==============================================================================
//==============================================================================
// TEveGeoShape
//==============================================================================

//______________________________________________________________________________
//
// Wrapper for TGeoShape with absolute positioning and color
// attributes allowing display of extracted TGeoShape's (without an
// active TGeoManager) and simplified geometries (needed for non-linear
// projections).
//
// TGeoCompositeShapes and TGeoAssemblies are supported.
//
// If fNSegments data-member is < 2 (0 by default), the default number of
// segments is used for tesselation and special GL objects are
// instantiated for selected shapes (spheres, tubes). If fNSegments is > 2,
// it gets forwarded to geo-manager and this tesselation detail is
// used when creating the buffer passed to GL.

ClassImp(TEveGeoShape);

TGeoManager* TEveGeoShape::fgGeoMangeur = init_geo_mangeur();

//______________________________________________________________________________
TGeoManager* TEveGeoShape::GetGeoMangeur()
{
   // Return static geo-manager that is used intenally to make shapes
   // lead a happy life.
   // Set gGeoManager to this object when creating TGeoShapes to be
   // passed into TEveGeoShapes.

   return fgGeoMangeur;
}

//______________________________________________________________________________
TGeoHMatrix* TEveGeoShape::GetGeoHMatrixIdentity()
{
   // Return static identity matrix in homogeneous representation.
   // This is needed because TGeoCompositeShape::PaintComposite()
   // assumes TGeoShape::fgTransform is a TGeoHMatrix and we need to pass in
   // an identity matrix when painting a composite shape.

   return &localGeoHMatrixIdentity;
}

//______________________________________________________________________________
TEveGeoShape::TEveGeoShape(const char* name, const char* title) :
   TEveShape       (name, title),
   fNSegments      (0),
   fShape          (0),
   fCompositeShape (0)
{
   // Constructor.

   InitMainTrans();
}

//______________________________________________________________________________
TEveGeoShape::~TEveGeoShape()
{
   // Destructor.

   SetShape(0);
}

//______________________________________________________________________________
TGeoShape* TEveGeoShape::MakePolyShape()
{
   // Create derived TEveGeoShape form a TGeoCompositeShape.

   return TEveGeoPolyShape::Construct(fCompositeShape, fNSegments);
}

//______________________________________________________________________________
void TEveGeoShape::SetNSegments(Int_t s)
{
   // Set number of segments.

   if (s != fNSegments && fCompositeShape != 0)
   {
      delete fShape;
      fShape = MakePolyShape();
   }
   fNSegments = s;
}

//______________________________________________________________________________
void TEveGeoShape::SetShape(TGeoShape* s)
{
   // Set TGeoShape shown by this object.
   //
   // The shape is owned by TEveGeoShape but TGeoShape::fUniqueID is
   // used for reference counting so you can pass the same shape to
   // several TEveGeoShapes.
   //
   // If it if is taken from an existing TGeoManager, manually
   // increase the fUniqueID before passing it to TEveGeoShape.

   TEveGeoManagerHolder gmgr(fgGeoMangeur);

   if (fCompositeShape)
   {
      delete fShape;
      fShape = fCompositeShape;
   }
   if (fShape)
   {
      fShape->SetUniqueID(fShape->GetUniqueID() - 1);
      if (fShape->GetUniqueID() == 0)
      {
         delete fShape;
      }
   }
   fShape = s;
   if (fShape)
   {
      fShape->SetUniqueID(fShape->GetUniqueID() + 1);
      fCompositeShape = dynamic_cast<TGeoCompositeShape*>(fShape);
      if (fCompositeShape)
      {
         fShape = MakePolyShape();
      }
   }
}

/******************************************************************************/

//______________________________________________________________________________
void TEveGeoShape::ComputeBBox()
{
   // Compute bounding-box.

   TGeoBBox *bb = dynamic_cast<TGeoBBox*>(fShape);
   if (bb)
   {
      BBoxInit();
      const Double_t *o = bb->GetOrigin();
      BBoxCheckPoint(o[0] - bb->GetDX(), o[0] - bb->GetDY(), o[0] - bb->GetDZ());
      BBoxCheckPoint(o[0] + bb->GetDX(), o[0] + bb->GetDY(), o[0] + bb->GetDZ());
   }
   else
   {
      BBoxZero();
   }
}

//______________________________________________________________________________
void TEveGeoShape::Paint(Option_t* /*option*/)
{
   // Paint object.

   static const TEveException eh("TEveGeoShape::Paint ");

   if (fShape == 0)
      return;

   TEveGeoManagerHolder gmgr(fgGeoMangeur, fNSegments);

   if (fCompositeShape)
   {
      Double_t halfLengths[3] = { fCompositeShape->GetDX(), fCompositeShape->GetDY(), fCompositeShape->GetDZ() };

      TBuffer3D buff(TBuffer3DTypes::kComposite);
      buff.fID           = this;
      buff.fColor        = GetMainColor();
      buff.fTransparency = GetMainTransparency();
      RefMainTrans().SetBuffer3D(buff);
      buff.fLocalFrame   = kTRUE; // Always enforce local frame (no geo manager).
      buff.SetAABoundingBox(fCompositeShape->GetOrigin(), halfLengths);
      buff.SetSectionsValid(TBuffer3D::kCore|TBuffer3D::kBoundingBox);

      Bool_t paintComponents = kTRUE;

      // Start a composite shape, identified by this buffer
      if (TBuffer3D::GetCSLevel() == 0)
         paintComponents = gPad->GetViewer3D()->OpenComposite(buff);

      TBuffer3D::IncCSLevel();

      // Paint the boolean node - will add more buffers to viewer
      TGeoMatrix *gst = TGeoShape::GetTransform();
      TGeoShape::SetTransform(TEveGeoShape::GetGeoHMatrixIdentity());
      if (paintComponents) fCompositeShape->GetBoolNode()->Paint("");
      TGeoShape::SetTransform(gst);
      // Close the composite shape
      if (TBuffer3D::DecCSLevel() == 0)
         gPad->GetViewer3D()->CloseComposite();
   }
   else
   {
      TBuffer3D& buff = (TBuffer3D&) fShape->GetBuffer3D
         (TBuffer3D::kCore, kFALSE);

      buff.fID           = this;
      buff.fColor        = GetMainColor();
      buff.fTransparency = GetMainTransparency();
      RefMainTrans().SetBuffer3D(buff);
      buff.fLocalFrame   = kTRUE; // Always enforce local frame (no geo manager).

      Int_t sections = TBuffer3D::kBoundingBox | TBuffer3D::kShapeSpecific;
      if (fNSegments > 2)
         sections |= TBuffer3D::kRawSizes | TBuffer3D::kRaw;
      fShape->GetBuffer3D(sections, kTRUE);

      Int_t reqSec = gPad->GetViewer3D()->AddObject(buff);

      if (reqSec != TBuffer3D::kNone) {
         // This shouldn't happen, but I suspect it does sometimes.
         if (reqSec & TBuffer3D::kCore)
            Warning(eh, "Core section required again for shape='%s'. This shouldn't happen.", GetName());
         fShape->GetBuffer3D(reqSec, kTRUE);
         reqSec = gPad->GetViewer3D()->AddObject(buff);
      }

      if (reqSec != TBuffer3D::kNone)
         Warning(eh, "Extra section required: reqSec=%d, shape=%s.", reqSec, GetName());
   }
}

//==============================================================================

//______________________________________________________________________________
void TEveGeoShape::Save(const char* file, const char* name)
{
   // Save the shape tree as TEveGeoShapeExtract.
   // File is always recreated.
   // This function is obsolete, use SaveExtractInstead().

   Warning("Save()", "This function is deprecated, use SaveExtract() instead.");
   SaveExtract(file, name);
}

//______________________________________________________________________________
void TEveGeoShape::SaveExtract(const char* file, const char* name)
{
   // Save the shape tree as TEveGeoShapeExtract.
   // File is always recreated.

   TEveGeoShapeExtract* gse = DumpShapeTree(this, 0);

   TFile f(file, "RECREATE");
   gse->Write(name);
   f.Close();
}

//______________________________________________________________________________
void TEveGeoShape::WriteExtract(const char* name)
{
   // Write the shape tree as TEveGeoShapeExtract to current directory.

   TEveGeoShapeExtract* gse = DumpShapeTree(this, 0);
   gse->Write(name);
}

/******************************************************************************/

//______________________________________________________________________________
TEveGeoShapeExtract* TEveGeoShape::DumpShapeTree(TEveGeoShape* gsre,
                                                 TEveGeoShapeExtract* parent)
{
   // Export this shape and its descendants into a geoshape-extract.

   TEveGeoShapeExtract* she = new TEveGeoShapeExtract(gsre->GetName(), gsre->GetTitle());
   she->SetTrans(gsre->RefMainTrans().Array());
   {
      Int_t   ci = gsre->GetFillColor();
      TColor *c  = gROOT->GetColor(ci);
      Float_t rgba[4] = { 1, 0, 0, Float_t(1 - gsre->GetMainTransparency()/100.) };
      if (c)
      {
         rgba[0] = c->GetRed();
         rgba[1] = c->GetGreen();
         rgba[2] = c->GetBlue();
      }
      she->SetRGBA(rgba);
   }
   {
      Int_t   ci = gsre->GetLineColor();
      TColor *c  = gROOT->GetColor(ci);
      Float_t rgba[4] = { 1, 0, 0, 1 };
      if (c)
      {
         rgba[0] = c->GetRed();
         rgba[1] = c->GetGreen();
         rgba[2] = c->GetBlue();
      }
      she->SetRGBALine(rgba);
   }
   she->SetRnrSelf(gsre->GetRnrSelf());
   she->SetRnrElements(gsre->GetRnrChildren());
   she->SetRnrFrame(gsre->GetDrawFrame());
   she->SetMiniFrame(gsre->GetMiniFrame());
   she->SetShape(gsre->GetShape());
   if (gsre->HasChildren())
   {
      TList* ele = new TList();
      she->SetElements(ele);
      she->GetElements()->SetOwner(true);
      TEveElement::List_i i = gsre->BeginChildren();
      while (i != gsre->EndChildren()) {
         TEveGeoShape* l = dynamic_cast<TEveGeoShape*>(*i);
         DumpShapeTree(l, she);
         i++;
      }
   }
   if (parent)
      parent->GetElements()->Add(she);

   return she;
}

//______________________________________________________________________________
TEveGeoShape* TEveGeoShape::ImportShapeExtract(TEveGeoShapeExtract* gse,
                                               TEveElement*         parent)
{
   // Import a shape extract 'gse' under element 'parent'.

   TEveGeoManagerHolder gmgr(fgGeoMangeur);
   TEveManager::TRedrawDisabler redrawOff(gEve);
   TEveGeoShape* gsre = SubImportShapeExtract(gse, parent);
   gsre->ElementChanged();
   return gsre;
}


//______________________________________________________________________________
TEveGeoShape* TEveGeoShape::SubImportShapeExtract(TEveGeoShapeExtract* gse,
                                                  TEveElement*         parent)
{
   // Recursive version for importing a shape extract tree.

   TEveGeoShape* gsre = new TEveGeoShape(gse->GetName(), gse->GetTitle());
   gsre->RefMainTrans().SetFromArray(gse->GetTrans());
   const Float_t* rgba = gse->GetRGBA();
   gsre->SetMainColorRGB(rgba[0], rgba[1], rgba[2]);
   gsre->SetMainAlpha(rgba[3]);
   rgba = gse->GetRGBALine();
   gsre->SetLineColor(TColor::GetColor(rgba[0], rgba[1], rgba[2]));
   gsre->SetRnrSelf(gse->GetRnrSelf());
   gsre->SetRnrChildren(gse->GetRnrElements());
   gsre->SetDrawFrame(gse->GetRnrFrame());
   gsre->SetMiniFrame(gse->GetMiniFrame());
   gsre->SetShape(gse->GetShape());

   if (parent)
      parent->AddElement(gsre);

   if (gse->HasElements())
   {
      TIter next(gse->GetElements());
      TEveGeoShapeExtract* chld;
      while ((chld = (TEveGeoShapeExtract*) next()) != 0)
         SubImportShapeExtract(chld, gsre);
   }

   return gsre;
}

/******************************************************************************/

//______________________________________________________________________________
TClass* TEveGeoShape::ProjectedClass(const TEveProjection* p) const
{
   // Return class for projected objects:
   //  - 2D projections: TEvePolygonSetProjected,
   //  - 3D projections: TEveGeoShapeProjected.
   // Virtual from TEveProjectable.

   if (p->Is2D())
      return TEvePolygonSetProjected::Class();
   else
      return TEveGeoShapeProjected::Class();
}

/******************************************************************************/

//______________________________________________________________________________
TBuffer3D* TEveGeoShape::MakeBuffer3D()
{
   // Create a TBuffer3D suitable for presentation of the shape.
   // Transformation matrix is also applied.

   if (fShape == 0) return 0;

   if (dynamic_cast<TGeoShapeAssembly*>(fShape)) {
      // TGeoShapeAssembly makes a bad TBuffer3D.
      return 0;
   }

   TEveGeoManagerHolder gmgr(fgGeoMangeur, fNSegments);

   TBuffer3D* buff  = fShape->MakeBuffer3D();
   TEveTrans& mx    = RefMainTrans();
   if (mx.GetUseTrans())
   {
      Int_t n = buff->NbPnts();
      Double_t* pnts = buff->fPnts;
      for(Int_t k = 0; k < n; ++k)
      {
         mx.MultiplyIP(&pnts[3*k]);
      }
   }
   return buff;
}


//==============================================================================
//==============================================================================
// TEveGeoShapeProjected
//==============================================================================

//______________________________________________________________________________
//
// A 3D projected TEveGeoShape.

ClassImp(TEveGeoShapeProjected);

//______________________________________________________________________________
TEveGeoShapeProjected::TEveGeoShapeProjected() :
   TEveShape("TEveGeoShapeProjected"),
   fBuff(0)
{
   // Constructor.
}

//______________________________________________________________________________
void TEveGeoShapeProjected::SetDepthLocal(Float_t /*d*/)
{
   // This should never be called as this class is only used for 3D
   // projections.
   // The implementation is required as this metod is abstract.
   // Just emits a warning if called.

   Warning("SetDepthLocal", "This function only exists to fulfill an abstract interface.");
}

//______________________________________________________________________________
void TEveGeoShapeProjected::SetProjection(TEveProjectionManager* mng,
                                          TEveProjectable* model)
{
   // This is virtual method from base-class TEveProjected.

   TEveProjected::SetProjection(mng, model);

   TEveGeoShape* gre = dynamic_cast<TEveGeoShape*>(fProjectable);
   CopyVizParams(gre);
}

//______________________________________________________________________________
void TEveGeoShapeProjected::UpdateProjection()
{
   // This is virtual method from base-class TEveProjected.

   TEveGeoShape   *gre = dynamic_cast<TEveGeoShape*>(fProjectable);
   TEveProjection *prj = fManager->GetProjection();

   delete fBuff;
   fBuff = gre->MakeBuffer3D();

   if (fBuff)
   {
      fBuff->SetSectionsValid(TBuffer3D::kCore | TBuffer3D::kRawSizes | TBuffer3D::kRaw);

      Double_t *p = fBuff->fPnts;
      for (UInt_t i = 0; i < fBuff->NbPnts(); ++i, p+=3)
      {
         prj->ProjectPointdv(p, 0);
      }
   }

   ResetBBox();
}

//______________________________________________________________________________
void TEveGeoShapeProjected::ComputeBBox()
{
   // Override of virtual method from TAttBBox.

   if (fBuff && fBuff->NbPnts() > 0)
   {
      BBoxInit();

      Double_t *p = fBuff->fPnts;
      for (UInt_t i = 0; i < fBuff->NbPnts(); ++i, p+=3)
      {
         BBoxCheckPoint(p[0], p[1], p[2]);
      }
   }
   else
   {
      BBoxZero();
   }
}
 TEveGeoShape.cxx:1
 TEveGeoShape.cxx:2
 TEveGeoShape.cxx:3
 TEveGeoShape.cxx:4
 TEveGeoShape.cxx:5
 TEveGeoShape.cxx:6
 TEveGeoShape.cxx:7
 TEveGeoShape.cxx:8
 TEveGeoShape.cxx:9
 TEveGeoShape.cxx:10
 TEveGeoShape.cxx:11
 TEveGeoShape.cxx:12
 TEveGeoShape.cxx:13
 TEveGeoShape.cxx:14
 TEveGeoShape.cxx:15
 TEveGeoShape.cxx:16
 TEveGeoShape.cxx:17
 TEveGeoShape.cxx:18
 TEveGeoShape.cxx:19
 TEveGeoShape.cxx:20
 TEveGeoShape.cxx:21
 TEveGeoShape.cxx:22
 TEveGeoShape.cxx:23
 TEveGeoShape.cxx:24
 TEveGeoShape.cxx:25
 TEveGeoShape.cxx:26
 TEveGeoShape.cxx:27
 TEveGeoShape.cxx:28
 TEveGeoShape.cxx:29
 TEveGeoShape.cxx:30
 TEveGeoShape.cxx:31
 TEveGeoShape.cxx:32
 TEveGeoShape.cxx:33
 TEveGeoShape.cxx:34
 TEveGeoShape.cxx:35
 TEveGeoShape.cxx:36
 TEveGeoShape.cxx:37
 TEveGeoShape.cxx:38
 TEveGeoShape.cxx:39
 TEveGeoShape.cxx:40
 TEveGeoShape.cxx:41
 TEveGeoShape.cxx:42
 TEveGeoShape.cxx:43
 TEveGeoShape.cxx:44
 TEveGeoShape.cxx:45
 TEveGeoShape.cxx:46
 TEveGeoShape.cxx:47
 TEveGeoShape.cxx:48
 TEveGeoShape.cxx:49
 TEveGeoShape.cxx:50
 TEveGeoShape.cxx:51
 TEveGeoShape.cxx:52
 TEveGeoShape.cxx:53
 TEveGeoShape.cxx:54
 TEveGeoShape.cxx:55
 TEveGeoShape.cxx:56
 TEveGeoShape.cxx:57
 TEveGeoShape.cxx:58
 TEveGeoShape.cxx:59
 TEveGeoShape.cxx:60
 TEveGeoShape.cxx:61
 TEveGeoShape.cxx:62
 TEveGeoShape.cxx:63
 TEveGeoShape.cxx:64
 TEveGeoShape.cxx:65
 TEveGeoShape.cxx:66
 TEveGeoShape.cxx:67
 TEveGeoShape.cxx:68
 TEveGeoShape.cxx:69
 TEveGeoShape.cxx:70
 TEveGeoShape.cxx:71
 TEveGeoShape.cxx:72
 TEveGeoShape.cxx:73
 TEveGeoShape.cxx:74
 TEveGeoShape.cxx:75
 TEveGeoShape.cxx:76
 TEveGeoShape.cxx:77
 TEveGeoShape.cxx:78
 TEveGeoShape.cxx:79
 TEveGeoShape.cxx:80
 TEveGeoShape.cxx:81
 TEveGeoShape.cxx:82
 TEveGeoShape.cxx:83
 TEveGeoShape.cxx:84
 TEveGeoShape.cxx:85
 TEveGeoShape.cxx:86
 TEveGeoShape.cxx:87
 TEveGeoShape.cxx:88
 TEveGeoShape.cxx:89
 TEveGeoShape.cxx:90
 TEveGeoShape.cxx:91
 TEveGeoShape.cxx:92
 TEveGeoShape.cxx:93
 TEveGeoShape.cxx:94
 TEveGeoShape.cxx:95
 TEveGeoShape.cxx:96
 TEveGeoShape.cxx:97
 TEveGeoShape.cxx:98
 TEveGeoShape.cxx:99
 TEveGeoShape.cxx:100
 TEveGeoShape.cxx:101
 TEveGeoShape.cxx:102
 TEveGeoShape.cxx:103
 TEveGeoShape.cxx:104
 TEveGeoShape.cxx:105
 TEveGeoShape.cxx:106
 TEveGeoShape.cxx:107
 TEveGeoShape.cxx:108
 TEveGeoShape.cxx:109
 TEveGeoShape.cxx:110
 TEveGeoShape.cxx:111
 TEveGeoShape.cxx:112
 TEveGeoShape.cxx:113
 TEveGeoShape.cxx:114
 TEveGeoShape.cxx:115
 TEveGeoShape.cxx:116
 TEveGeoShape.cxx:117
 TEveGeoShape.cxx:118
 TEveGeoShape.cxx:119
 TEveGeoShape.cxx:120
 TEveGeoShape.cxx:121
 TEveGeoShape.cxx:122
 TEveGeoShape.cxx:123
 TEveGeoShape.cxx:124
 TEveGeoShape.cxx:125
 TEveGeoShape.cxx:126
 TEveGeoShape.cxx:127
 TEveGeoShape.cxx:128
 TEveGeoShape.cxx:129
 TEveGeoShape.cxx:130
 TEveGeoShape.cxx:131
 TEveGeoShape.cxx:132
 TEveGeoShape.cxx:133
 TEveGeoShape.cxx:134
 TEveGeoShape.cxx:135
 TEveGeoShape.cxx:136
 TEveGeoShape.cxx:137
 TEveGeoShape.cxx:138
 TEveGeoShape.cxx:139
 TEveGeoShape.cxx:140
 TEveGeoShape.cxx:141
 TEveGeoShape.cxx:142
 TEveGeoShape.cxx:143
 TEveGeoShape.cxx:144
 TEveGeoShape.cxx:145
 TEveGeoShape.cxx:146
 TEveGeoShape.cxx:147
 TEveGeoShape.cxx:148
 TEveGeoShape.cxx:149
 TEveGeoShape.cxx:150
 TEveGeoShape.cxx:151
 TEveGeoShape.cxx:152
 TEveGeoShape.cxx:153
 TEveGeoShape.cxx:154
 TEveGeoShape.cxx:155
 TEveGeoShape.cxx:156
 TEveGeoShape.cxx:157
 TEveGeoShape.cxx:158
 TEveGeoShape.cxx:159
 TEveGeoShape.cxx:160
 TEveGeoShape.cxx:161
 TEveGeoShape.cxx:162
 TEveGeoShape.cxx:163
 TEveGeoShape.cxx:164
 TEveGeoShape.cxx:165
 TEveGeoShape.cxx:166
 TEveGeoShape.cxx:167
 TEveGeoShape.cxx:168
 TEveGeoShape.cxx:169
 TEveGeoShape.cxx:170
 TEveGeoShape.cxx:171
 TEveGeoShape.cxx:172
 TEveGeoShape.cxx:173
 TEveGeoShape.cxx:174
 TEveGeoShape.cxx:175
 TEveGeoShape.cxx:176
 TEveGeoShape.cxx:177
 TEveGeoShape.cxx:178
 TEveGeoShape.cxx:179
 TEveGeoShape.cxx:180
 TEveGeoShape.cxx:181
 TEveGeoShape.cxx:182
 TEveGeoShape.cxx:183
 TEveGeoShape.cxx:184
 TEveGeoShape.cxx:185
 TEveGeoShape.cxx:186
 TEveGeoShape.cxx:187
 TEveGeoShape.cxx:188
 TEveGeoShape.cxx:189
 TEveGeoShape.cxx:190
 TEveGeoShape.cxx:191
 TEveGeoShape.cxx:192
 TEveGeoShape.cxx:193
 TEveGeoShape.cxx:194
 TEveGeoShape.cxx:195
 TEveGeoShape.cxx:196
 TEveGeoShape.cxx:197
 TEveGeoShape.cxx:198
 TEveGeoShape.cxx:199
 TEveGeoShape.cxx:200
 TEveGeoShape.cxx:201
 TEveGeoShape.cxx:202
 TEveGeoShape.cxx:203
 TEveGeoShape.cxx:204
 TEveGeoShape.cxx:205
 TEveGeoShape.cxx:206
 TEveGeoShape.cxx:207
 TEveGeoShape.cxx:208
 TEveGeoShape.cxx:209
 TEveGeoShape.cxx:210
 TEveGeoShape.cxx:211
 TEveGeoShape.cxx:212
 TEveGeoShape.cxx:213
 TEveGeoShape.cxx:214
 TEveGeoShape.cxx:215
 TEveGeoShape.cxx:216
 TEveGeoShape.cxx:217
 TEveGeoShape.cxx:218
 TEveGeoShape.cxx:219
 TEveGeoShape.cxx:220
 TEveGeoShape.cxx:221
 TEveGeoShape.cxx:222
 TEveGeoShape.cxx:223
 TEveGeoShape.cxx:224
 TEveGeoShape.cxx:225
 TEveGeoShape.cxx:226
 TEveGeoShape.cxx:227
 TEveGeoShape.cxx:228
 TEveGeoShape.cxx:229
 TEveGeoShape.cxx:230
 TEveGeoShape.cxx:231
 TEveGeoShape.cxx:232
 TEveGeoShape.cxx:233
 TEveGeoShape.cxx:234
 TEveGeoShape.cxx:235
 TEveGeoShape.cxx:236
 TEveGeoShape.cxx:237
 TEveGeoShape.cxx:238
 TEveGeoShape.cxx:239
 TEveGeoShape.cxx:240
 TEveGeoShape.cxx:241
 TEveGeoShape.cxx:242
 TEveGeoShape.cxx:243
 TEveGeoShape.cxx:244
 TEveGeoShape.cxx:245
 TEveGeoShape.cxx:246
 TEveGeoShape.cxx:247
 TEveGeoShape.cxx:248
 TEveGeoShape.cxx:249
 TEveGeoShape.cxx:250
 TEveGeoShape.cxx:251
 TEveGeoShape.cxx:252
 TEveGeoShape.cxx:253
 TEveGeoShape.cxx:254
 TEveGeoShape.cxx:255
 TEveGeoShape.cxx:256
 TEveGeoShape.cxx:257
 TEveGeoShape.cxx:258
 TEveGeoShape.cxx:259
 TEveGeoShape.cxx:260
 TEveGeoShape.cxx:261
 TEveGeoShape.cxx:262
 TEveGeoShape.cxx:263
 TEveGeoShape.cxx:264
 TEveGeoShape.cxx:265
 TEveGeoShape.cxx:266
 TEveGeoShape.cxx:267
 TEveGeoShape.cxx:268
 TEveGeoShape.cxx:269
 TEveGeoShape.cxx:270
 TEveGeoShape.cxx:271
 TEveGeoShape.cxx:272
 TEveGeoShape.cxx:273
 TEveGeoShape.cxx:274
 TEveGeoShape.cxx:275
 TEveGeoShape.cxx:276
 TEveGeoShape.cxx:277
 TEveGeoShape.cxx:278
 TEveGeoShape.cxx:279
 TEveGeoShape.cxx:280
 TEveGeoShape.cxx:281
 TEveGeoShape.cxx:282
 TEveGeoShape.cxx:283
 TEveGeoShape.cxx:284
 TEveGeoShape.cxx:285
 TEveGeoShape.cxx:286
 TEveGeoShape.cxx:287
 TEveGeoShape.cxx:288
 TEveGeoShape.cxx:289
 TEveGeoShape.cxx:290
 TEveGeoShape.cxx:291
 TEveGeoShape.cxx:292
 TEveGeoShape.cxx:293
 TEveGeoShape.cxx:294
 TEveGeoShape.cxx:295
 TEveGeoShape.cxx:296
 TEveGeoShape.cxx:297
 TEveGeoShape.cxx:298
 TEveGeoShape.cxx:299
 TEveGeoShape.cxx:300
 TEveGeoShape.cxx:301
 TEveGeoShape.cxx:302
 TEveGeoShape.cxx:303
 TEveGeoShape.cxx:304
 TEveGeoShape.cxx:305
 TEveGeoShape.cxx:306
 TEveGeoShape.cxx:307
 TEveGeoShape.cxx:308
 TEveGeoShape.cxx:309
 TEveGeoShape.cxx:310
 TEveGeoShape.cxx:311
 TEveGeoShape.cxx:312
 TEveGeoShape.cxx:313
 TEveGeoShape.cxx:314
 TEveGeoShape.cxx:315
 TEveGeoShape.cxx:316
 TEveGeoShape.cxx:317
 TEveGeoShape.cxx:318
 TEveGeoShape.cxx:319
 TEveGeoShape.cxx:320
 TEveGeoShape.cxx:321
 TEveGeoShape.cxx:322
 TEveGeoShape.cxx:323
 TEveGeoShape.cxx:324
 TEveGeoShape.cxx:325
 TEveGeoShape.cxx:326
 TEveGeoShape.cxx:327
 TEveGeoShape.cxx:328
 TEveGeoShape.cxx:329
 TEveGeoShape.cxx:330
 TEveGeoShape.cxx:331
 TEveGeoShape.cxx:332
 TEveGeoShape.cxx:333
 TEveGeoShape.cxx:334
 TEveGeoShape.cxx:335
 TEveGeoShape.cxx:336
 TEveGeoShape.cxx:337
 TEveGeoShape.cxx:338
 TEveGeoShape.cxx:339
 TEveGeoShape.cxx:340
 TEveGeoShape.cxx:341
 TEveGeoShape.cxx:342
 TEveGeoShape.cxx:343
 TEveGeoShape.cxx:344
 TEveGeoShape.cxx:345
 TEveGeoShape.cxx:346
 TEveGeoShape.cxx:347
 TEveGeoShape.cxx:348
 TEveGeoShape.cxx:349
 TEveGeoShape.cxx:350
 TEveGeoShape.cxx:351
 TEveGeoShape.cxx:352
 TEveGeoShape.cxx:353
 TEveGeoShape.cxx:354
 TEveGeoShape.cxx:355
 TEveGeoShape.cxx:356
 TEveGeoShape.cxx:357
 TEveGeoShape.cxx:358
 TEveGeoShape.cxx:359
 TEveGeoShape.cxx:360
 TEveGeoShape.cxx:361
 TEveGeoShape.cxx:362
 TEveGeoShape.cxx:363
 TEveGeoShape.cxx:364
 TEveGeoShape.cxx:365
 TEveGeoShape.cxx:366
 TEveGeoShape.cxx:367
 TEveGeoShape.cxx:368
 TEveGeoShape.cxx:369
 TEveGeoShape.cxx:370
 TEveGeoShape.cxx:371
 TEveGeoShape.cxx:372
 TEveGeoShape.cxx:373
 TEveGeoShape.cxx:374
 TEveGeoShape.cxx:375
 TEveGeoShape.cxx:376
 TEveGeoShape.cxx:377
 TEveGeoShape.cxx:378
 TEveGeoShape.cxx:379
 TEveGeoShape.cxx:380
 TEveGeoShape.cxx:381
 TEveGeoShape.cxx:382
 TEveGeoShape.cxx:383
 TEveGeoShape.cxx:384
 TEveGeoShape.cxx:385
 TEveGeoShape.cxx:386
 TEveGeoShape.cxx:387
 TEveGeoShape.cxx:388
 TEveGeoShape.cxx:389
 TEveGeoShape.cxx:390
 TEveGeoShape.cxx:391
 TEveGeoShape.cxx:392
 TEveGeoShape.cxx:393
 TEveGeoShape.cxx:394
 TEveGeoShape.cxx:395
 TEveGeoShape.cxx:396
 TEveGeoShape.cxx:397
 TEveGeoShape.cxx:398
 TEveGeoShape.cxx:399
 TEveGeoShape.cxx:400
 TEveGeoShape.cxx:401
 TEveGeoShape.cxx:402
 TEveGeoShape.cxx:403
 TEveGeoShape.cxx:404
 TEveGeoShape.cxx:405
 TEveGeoShape.cxx:406
 TEveGeoShape.cxx:407
 TEveGeoShape.cxx:408
 TEveGeoShape.cxx:409
 TEveGeoShape.cxx:410
 TEveGeoShape.cxx:411
 TEveGeoShape.cxx:412
 TEveGeoShape.cxx:413
 TEveGeoShape.cxx:414
 TEveGeoShape.cxx:415
 TEveGeoShape.cxx:416
 TEveGeoShape.cxx:417
 TEveGeoShape.cxx:418
 TEveGeoShape.cxx:419
 TEveGeoShape.cxx:420
 TEveGeoShape.cxx:421
 TEveGeoShape.cxx:422
 TEveGeoShape.cxx:423
 TEveGeoShape.cxx:424
 TEveGeoShape.cxx:425
 TEveGeoShape.cxx:426
 TEveGeoShape.cxx:427
 TEveGeoShape.cxx:428
 TEveGeoShape.cxx:429
 TEveGeoShape.cxx:430
 TEveGeoShape.cxx:431
 TEveGeoShape.cxx:432
 TEveGeoShape.cxx:433
 TEveGeoShape.cxx:434
 TEveGeoShape.cxx:435
 TEveGeoShape.cxx:436
 TEveGeoShape.cxx:437
 TEveGeoShape.cxx:438
 TEveGeoShape.cxx:439
 TEveGeoShape.cxx:440
 TEveGeoShape.cxx:441
 TEveGeoShape.cxx:442
 TEveGeoShape.cxx:443
 TEveGeoShape.cxx:444
 TEveGeoShape.cxx:445
 TEveGeoShape.cxx:446
 TEveGeoShape.cxx:447
 TEveGeoShape.cxx:448
 TEveGeoShape.cxx:449
 TEveGeoShape.cxx:450
 TEveGeoShape.cxx:451
 TEveGeoShape.cxx:452
 TEveGeoShape.cxx:453
 TEveGeoShape.cxx:454
 TEveGeoShape.cxx:455
 TEveGeoShape.cxx:456
 TEveGeoShape.cxx:457
 TEveGeoShape.cxx:458
 TEveGeoShape.cxx:459
 TEveGeoShape.cxx:460
 TEveGeoShape.cxx:461
 TEveGeoShape.cxx:462
 TEveGeoShape.cxx:463
 TEveGeoShape.cxx:464
 TEveGeoShape.cxx:465
 TEveGeoShape.cxx:466
 TEveGeoShape.cxx:467
 TEveGeoShape.cxx:468
 TEveGeoShape.cxx:469
 TEveGeoShape.cxx:470
 TEveGeoShape.cxx:471
 TEveGeoShape.cxx:472
 TEveGeoShape.cxx:473
 TEveGeoShape.cxx:474
 TEveGeoShape.cxx:475
 TEveGeoShape.cxx:476
 TEveGeoShape.cxx:477
 TEveGeoShape.cxx:478
 TEveGeoShape.cxx:479
 TEveGeoShape.cxx:480
 TEveGeoShape.cxx:481
 TEveGeoShape.cxx:482
 TEveGeoShape.cxx:483
 TEveGeoShape.cxx:484
 TEveGeoShape.cxx:485
 TEveGeoShape.cxx:486
 TEveGeoShape.cxx:487
 TEveGeoShape.cxx:488
 TEveGeoShape.cxx:489
 TEveGeoShape.cxx:490
 TEveGeoShape.cxx:491
 TEveGeoShape.cxx:492
 TEveGeoShape.cxx:493
 TEveGeoShape.cxx:494
 TEveGeoShape.cxx:495
 TEveGeoShape.cxx:496
 TEveGeoShape.cxx:497
 TEveGeoShape.cxx:498
 TEveGeoShape.cxx:499
 TEveGeoShape.cxx:500
 TEveGeoShape.cxx:501
 TEveGeoShape.cxx:502
 TEveGeoShape.cxx:503
 TEveGeoShape.cxx:504
 TEveGeoShape.cxx:505
 TEveGeoShape.cxx:506
 TEveGeoShape.cxx:507
 TEveGeoShape.cxx:508
 TEveGeoShape.cxx:509
 TEveGeoShape.cxx:510
 TEveGeoShape.cxx:511
 TEveGeoShape.cxx:512
 TEveGeoShape.cxx:513
 TEveGeoShape.cxx:514
 TEveGeoShape.cxx:515
 TEveGeoShape.cxx:516
 TEveGeoShape.cxx:517
 TEveGeoShape.cxx:518
 TEveGeoShape.cxx:519
 TEveGeoShape.cxx:520
 TEveGeoShape.cxx:521
 TEveGeoShape.cxx:522
 TEveGeoShape.cxx:523
 TEveGeoShape.cxx:524
 TEveGeoShape.cxx:525
 TEveGeoShape.cxx:526
 TEveGeoShape.cxx:527
 TEveGeoShape.cxx:528
 TEveGeoShape.cxx:529
 TEveGeoShape.cxx:530
 TEveGeoShape.cxx:531
 TEveGeoShape.cxx:532
 TEveGeoShape.cxx:533
 TEveGeoShape.cxx:534
 TEveGeoShape.cxx:535
 TEveGeoShape.cxx:536
 TEveGeoShape.cxx:537
 TEveGeoShape.cxx:538
 TEveGeoShape.cxx:539
 TEveGeoShape.cxx:540
 TEveGeoShape.cxx:541
 TEveGeoShape.cxx:542
 TEveGeoShape.cxx:543
 TEveGeoShape.cxx:544
 TEveGeoShape.cxx:545
 TEveGeoShape.cxx:546
 TEveGeoShape.cxx:547
 TEveGeoShape.cxx:548
 TEveGeoShape.cxx:549
 TEveGeoShape.cxx:550
 TEveGeoShape.cxx:551
 TEveGeoShape.cxx:552
 TEveGeoShape.cxx:553
 TEveGeoShape.cxx:554
 TEveGeoShape.cxx:555