ROOT logo
// @@(#)root/g3d:$Id: TXTRU.cxx 31652 2009-12-08 13:17:57Z couet $
// Author: Robert Hatcher (rhatcher@fnal.gov) 2000.09.06

#include "TXTRU.h"
#include "TVirtualPad.h"

///#include "GLConstants.h"

#include "TBuffer3D.h"
#include "TBuffer3DTypes.h"
#include "TGeometry.h"
#include "TMath.h"

#include "Riostream.h"


ClassImp(TXTRU)


//_____________________________________________________________________________
// Begin_Html <P ALIGN=CENTER> <IMG SRC="gif/xtru.gif"> </P> End_Html
//
// XTRU is an poly-extrusion with fixed outline shape in x-y,
// a sequence of z extents (segments) and two end faces perpendicular
// to the z axis.  The x-y outline is defined by an ordered list of
// points; the overall scale of the outline scales linearly between
// z points and the center can have an x-y offset specified
// at each segment end.
//
// A TXTRU has the following parameters:
//
//     - name       name of the shape
//     - title      shape's title
//     - material  (see TMaterial)
//     - nxy        number of x-y vertex points constituting the outline --
//                  this number should be at least 3
//     - nz         number of planes perpendicular to the z axis where
//                  the scaling dimension of the section is given --
//                  this number should be at least 2
//     - Xvtx       array [nxy] of X coordinates of vertices
//     - Yvtx       array [nxy] of Y coordinates of vertices
//     - z          array [nz] of z plane positions
//     - scale      array [nz] of scale factors
//     - x0         array [nz] of x offsets
//     - y0         array [nz] of y offsets
//
// Author:  R. Hatcher 2000.04.21
//
// All XTRU shapes are correctly rendered in wire mode but can encounter
// difficulty when rendered as a solid with hidden surfaces.  These
// exceptions occur if the outline shape is not a convex polygon.
// Both the X3D and OpenGL renderers expect polygons to be convex.
// The OpenGL spec specifies that points defining a polygon using the
// GL_POLYGON primitive may be rendered as the convex hull of that set.
//
// Solid rendering under X3D can also give unexpected artifacts if
// the combination of x-y-z offsets and scales for the segments are
// chosen in such a manner that they represent a concave shape when
// sliced along a plane parallel to the z axis.
//
// Choosing sets of point that represent a malformed polygon is
// not supported, but testing for such a condition is not implemented
// and thus it is left to the user to avoid this mistake.
//
// Begin_Html <P ALIGN=CENTER> <IMG SRC="gif/polytype.gif"> </P> End_Html


//______________________________________________________________________________
TXTRU::TXTRU()
   : fNxy(0), fNxyAlloc(0), fNz(0), fNzAlloc(0), fXvtx(0), fYvtx(0),
     fZ(0), fScale(0), fX0(0), fY0(0)
{
   // TXTRU shape - default constructor

   fPolygonShape  = kUncheckedXY;
   fZOrdering     = kUncheckedZ;
   fSplitConcave  = kFALSE;
}


//______________________________________________________________________________
TXTRU::TXTRU(const char *name, const char *title, const char *material,
             Int_t nxy, Int_t nz)
   : TShape (name,title,material)
{
   // TXTRU shape - normal constructor
   //
   // Parameters of Nxy positions must be entered via TXTRU::DefineVertex
   // Parameters of Nz  positions must be entered via TXTRU::DefineSection

   // start in a known state even if "Error" is encountered
   fNxy      = 0;
   fNxyAlloc = 0;
   fNz       = 0;
   fNzAlloc  = 0;
   fXvtx     = 0;
   fYvtx     = 0;
   fZ        = 0;
   fScale    = 0;
   fX0       = 0;
   fY0       = 0;

   fPolygonShape  = kUncheckedXY;
   fZOrdering     = kUncheckedZ;
   fSplitConcave  = kFALSE;

   if ( nxy < 3 ) {
      Error(name,"number of x-y points for %s must be at least three!",name);
      return;
   }
   if ( nz < 2 ) {
      Error(name,"number of z points for %s must be at least two!",name);
      return;
   }

   // allocate space for Nxy vertex points
   fNxy       = nxy;
   fNxyAlloc  = nxy;
   fXvtx      = new Float_t [fNxyAlloc];
   fYvtx      = new Float_t [fNxyAlloc];
   // zero out the vertex points
   Int_t i = 0;
   for (i = 0; i < fNxyAlloc; i++) {
      fXvtx[i] = 0;
      fYvtx[i] = 0;
   }

   // allocate space for Nz sections
   fNz        = nz;
   fNzAlloc   = nz;
   fZ         = new Float_t [fNzAlloc];
   fScale     = new Float_t [fNzAlloc];
   fX0        = new Float_t [fNzAlloc];
   fY0        = new Float_t [fNzAlloc];
   // zero out the z points
   Int_t j = 0;
   for (j = 0; j < fNzAlloc; j++) {
      fZ[j]     = 0;
      fScale[j] = 0;
      fX0[j]    = 0;
      fY0[j]    = 0;
   }

}


//______________________________________________________________________________
TXTRU::TXTRU(const TXTRU &xtru) : TShape(xtru)
{
   // TXTRU copy constructor

   // patterned after other ROOT objects

   ((TXTRU&)xtru).Copy(*this);
}


//______________________________________________________________________________
TXTRU::~TXTRU()
{
   // TXTRU destructor deallocates arrays

   if (fXvtx) delete [] fXvtx;
   if (fYvtx) delete [] fYvtx;
   fXvtx     = 0;
   fYvtx     = 0;
   fNxy      = 0;
   fNxyAlloc = 0;

   if (fZ)     delete [] fZ;
   if (fScale) delete [] fScale;
   if (fX0)    delete [] fX0;
   if (fY0)    delete [] fY0;
   fZ        = 0;
   fScale    = 0;
   fX0       = 0;
   fY0       = 0;
   fNz       = 0;
   fNzAlloc  = 0;

   fPolygonShape  = kUncheckedXY;
   fZOrdering     = kUncheckedZ;
}


//______________________________________________________________________________
TXTRU& TXTRU::operator=(const TXTRU &rhs)
{
   // Deep assignment operator

   // protect against self-assignment
   if (this == &rhs) return *this;

   if (fNxyAlloc) {
      delete [] fXvtx;
      delete [] fYvtx;
   }
   if (fNzAlloc) {
      delete [] fZ;
      delete [] fScale;
      delete [] fX0;
      delete [] fY0;
   }
   ((TXTRU&)rhs).Copy(*this);

   return *this;
}


//______________________________________________________________________________
void TXTRU::Copy(TObject &obj) const
{
   // TXTRU Copy method

   // patterned after other ROOT objects

   TObject::Copy(obj);
   ((TXTRU&)obj).fNxy       = fNxy;
   ((TXTRU&)obj).fNxyAlloc  = fNxyAlloc;
   ((TXTRU&)obj).fXvtx = new Float_t [fNxyAlloc];
   ((TXTRU&)obj).fYvtx = new Float_t [fNxyAlloc];
   Int_t i = 0;
   for (i = 0; i < fNxyAlloc; i++) {
      ((TXTRU&)obj).fXvtx[i] = fXvtx[i];
      ((TXTRU&)obj).fYvtx[i] = fYvtx[i];
   }

   ((TXTRU&)obj).fNz       = fNz;
   ((TXTRU&)obj).fNzAlloc  = fNzAlloc;
   ((TXTRU&)obj).fZ     = new Float_t [fNzAlloc];
   ((TXTRU&)obj).fScale = new Float_t [fNzAlloc];
   ((TXTRU&)obj).fX0    = new Float_t [fNzAlloc];
   ((TXTRU&)obj).fY0    = new Float_t [fNzAlloc];
   Int_t j = 0;
   for (j = 0; j < fNzAlloc; j++) {
      ((TXTRU&)obj).fZ[j]     = fZ[j];
      ((TXTRU&)obj).fScale[j] = fScale[j];
      ((TXTRU&)obj).fX0[j]    = fX0[j];
      ((TXTRU&)obj).fY0[j]    = fY0[j];
   }

   ((TXTRU&)obj).fPolygonShape = fPolygonShape;
   ((TXTRU&)obj).fZOrdering    = fZOrdering;
}


//______________________________________________________________________________
void TXTRU::DefineSection(Int_t iz, Float_t z, Float_t scale, Float_t x0, Float_t y0)
{
   // Set z section iz information
   // expand size of array if necessary

   if (iz < 0) return;

   // setting a new section makes things unverified
   fZOrdering  = kUncheckedZ;

   if (!fZ || !fScale || iz >= fNzAlloc) {
      // re-allocate the z positions/scales
      Int_t   newNalloc = iz + 1;
      Float_t *newZ = new Float_t [newNalloc];
      Float_t *newS = new Float_t [newNalloc];
      Float_t *newX = new Float_t [newNalloc];
      Float_t *newY = new Float_t [newNalloc];
      Int_t i = 0;
      for (i = 0; i < newNalloc; i++) {
         if (i<fNz) {
            // copy the old points
            newZ[i] = fZ[i];
            newS[i] = fScale[i];
            newX[i] = fX0[i];
            newY[i] = fY0[i];
         } else {
            // zero out the new points
            newZ[i] = 0;
            newS[i] = 0;
            newX[i] = 0;
            newY[i] = 0;
         }
      }
      delete [] fZ;
      delete [] fScale;
      delete [] fX0;
      delete [] fY0;
      fZ     = newZ;
      fScale = newS;
      fX0    = newX;
      fY0    = newY;
      fNzAlloc = newNalloc;
   }

   // filled z "iz" means indices 0...iz have values -> iz+1 entries
   fNz = TMath::Max(iz+1,fNz);

   fZ[iz]     = z;
   fScale[iz] = scale;
   fX0[iz]    = x0;
   fY0[iz]    = y0;
}


//______________________________________________________________________________
void TXTRU::DefineVertex(Int_t ipt, Float_t x, Float_t y) {

   // Set vertex point ipt to (x,y)
   // expand size of array if necessary

   if (ipt < 0) return;

   // setting a new vertex makes things unverified
   fPolygonShape  = kUncheckedXY;

   if (!fXvtx || !fYvtx || ipt >= fNxyAlloc) {
      // re-allocate the outline points
      Int_t   newNalloc = ipt + 1;
      Float_t *newX = new Float_t [newNalloc];
      Float_t *newY = new Float_t [newNalloc];
      Int_t i = 0;
      for (i = 0; i < newNalloc; i++) {
         if (i<fNxy) {
            // copy the old points
            newX[i] = fXvtx[i];
            newY[i] = fYvtx[i];
         } else {
            // zero out the new points
            newX[i] = 0;
            newY[i] = 0;
         }
      }
      delete [] fXvtx;
      delete [] fYvtx;
      fXvtx = newX;
      fYvtx = newY;
      fNxyAlloc = newNalloc;
   }

   // filled point "ipt" means indices 0...ipt have values -> ipt+1 entries
   fNxy = TMath::Max(ipt+1,fNxy);

   fXvtx[ipt] = x;
   fYvtx[ipt] = y;
}


//______________________________________________________________________________
Int_t TXTRU::DistancetoPrimitive(Int_t px, Int_t py)
{
   // Compute the distance from point px,py to a TXTRU
   // by calculating the closest approach to each corner

   Int_t numPoints = fNz*fNxy;
   return ShapeDistancetoPrimitive(numPoints,px,py);
}


//______________________________________________________________________________
Float_t TXTRU::GetOutlinePointX(Int_t n) const {

   // Return x coordinate of a vertex point

   if ((n < 0) || (n >= fNxy)) {
      Error(fName,"no such point %d [of %d]",n,fNxy);
      return 0.0;
   }
   return fXvtx[n];
}


//______________________________________________________________________________
Float_t TXTRU::GetOutlinePointY(Int_t n) const {

   // Return y coordinate of a vertex point

   if ((n < 0) || (n >= fNxy)) {
      Error(fName,"no such point %d [of %d]",n,fNxy);
      return 0.0;
   }
   return fYvtx[n];
}


//______________________________________________________________________________
Float_t TXTRU::GetSectionX0(Int_t n) const {

   // Return x0 shift of a z section

   if ((n < 0) || (n >= fNz)) {
      Error(fName,"no such section %d [of %d]",n,fNz);
      return 0.0;
   }
   return fX0[n];
}


//______________________________________________________________________________
Float_t TXTRU::GetSectionY0(Int_t n) const {

   // Return y0 shift of a z section

   if ((n < 0) || (n >= fNz)) {
      Error(fName,"no such section %d [of %d]",n,fNz);
      return 0.0;
   }
   return fY0[n];
}


//______________________________________________________________________________
Float_t TXTRU::GetSectionScale(Int_t n) const {

   // Return scale factor for a z section

   if ((n < 0) || (n >= fNz)) {
      Error(fName,"no such section %d [of %d]",n,fNz);
      return 0.0;
   }
   return fScale[n];
}


//______________________________________________________________________________
Float_t TXTRU::GetSectionZ(Int_t n) const {

   // Return z of a z section

   if ((n < 0) || (n >= fNz)) {
      Error(fName,"no such section %d [of %d]",n,fNz);
      return 0.0;
   }
   return fZ[n];
}


//______________________________________________________________________________
void TXTRU::Print(Option_t *option) const
{
   // Dump the info of this TXTRU shape
   // Option: "xy" to get x-y information
   //         "z"  to get z information
   //         "alloc" to show full allocated arrays (not just used values)

   TString opt = option;
   opt.ToLower();

   printf("TXTRU %s Nxy=%d [of %d] Nz=%d [of %d] Option=%s\n",
          GetName(),fNxy,fNxyAlloc,fNz,fNzAlloc,option);

   const char *shape = 0;
   const char *zorder = 0;

   switch (fPolygonShape) {
   case kUncheckedXY:   shape = "Unchecked  ";  break;
   case kMalformedXY:   shape = "Malformed  ";  break;
   case kConvexCCW:     shape = "Convex CCW ";  break;
   case kConvexCW:      shape = "Convex CW  ";  break;
   case kConcaveCCW:    shape = "Concave CCW";  break;
   case kConcaveCW:     shape = "Concave CW ";  break;
   }

   switch (fZOrdering) {
   case kUncheckedZ:    zorder = "Unchecked Z";  break;
   case kMalformedZ:    zorder = "Malformed Z";  break;
   case kConvexIncZ:    zorder = "Convex Increasing Z";  break;
   case kConvexDecZ:    zorder = "Convex Decreasing Z";  break;
   case kConcaveIncZ:   zorder = "Concave Increasing Z";  break;
   case kConcaveDecZ:   zorder = "Concave Decreasing Z";  break;
   }

   printf("  XY shape '%s', '%s'\n",shape,zorder);

   Int_t       nxy, nz;

   if (opt.Contains("alloc")) {
      nxy    = fNxy;
      nz     = fNz;
   } else {
      nxy    = fNxyAlloc;
      nz    = fNzAlloc;
   }

   const char *name;
   Float_t *p;
   Int_t   nlimit;
   Bool_t  print_vtx = opt.Contains("xy");
   Bool_t  print_z   = opt.Contains("z");

   Int_t ixyz=0;
   for (ixyz=0; ixyz<6; ixyz++) {
      switch (ixyz) {
      case 0: p = fXvtx;  name = "x";     nlimit = nxy; break;
      case 1: p = fYvtx;  name = "y";     nlimit = nxy; break;
      case 2: p = fZ;     name = "z";     nlimit = nz;  break;
      case 3: p = fScale; name = "scale"; nlimit = nz;  break;
      case 4: p = fX0;    name = "x0";    nlimit = nz;  break;
      case 5: p = fY0;    name = "y0";    nlimit = nz;  break;
      default: continue;
      }
      if (ixyz<=1 && !print_vtx) continue;
      if (ixyz>=2 && !print_z) continue;

      printf(" Float_t %s[] = \n    { %10g",name,*p++);
      Int_t i=1;
      for (i=1;i<nlimit;i++) {
         printf(", %10g",*p++);
         if (i%6==5) printf("\n    ");
      }
      printf(" };\n");
   }

}


//______________________________________________________________________________
void TXTRU::SetPoints(Double_t *points) const
{
   // Create TXTRU points in buffer
   // order as expected by other methods (counterclockwise xy, increasing z)

   if (points) {
      Int_t ipt, ixy, iz, ioff;
      Float_t x, y;

      // put xy in counterclockwise order
      Bool_t iscw = (fPolygonShape == kConvexCW ||
                     fPolygonShape == kConcaveCW  );

      // put z
      Bool_t reversez = (fZOrdering == kConvexDecZ ||
                         fZOrdering == kConcaveDecZ  );

      ipt = 0; // point number
      Int_t i=0;
      for (i=0; i<fNz; i++) {        // loop over sections
         iz = (reversez) ? fNz-1 - i : i;
         Int_t j=0;
         for (j=0; j<fNxy; j++) {    // loop over points in section
            ixy = (iscw) ? fNxy-1 - j : j;
            ioff = ipt*3;                  // 3 words per point (x,y,z)
            x = fXvtx[ixy];
            y = fYvtx[ixy];
            points[ioff  ] = x*fScale[iz] + fX0[iz];
            points[ioff+1] = y*fScale[iz] + fY0[iz];
            points[ioff+2] = fZ[iz];
            ipt++;
         }
      }
   }
}


//______________________________________________________________________________
void TXTRU::Sizeof3D() const
{
   // Return total X3D needed by TNode::ls (when called with option "x")

   gSize3D.numPoints += fNz*fNxy;
   gSize3D.numSegs   += (2*fNz-1)*fNxy;
   gSize3D.numPolys  += (fNz-1)*fNxy+2;
}


//______________________________________________________________________________
void TXTRU::SplitConcavePolygon(Bool_t split)
{
   // (Dis)Enable the splitting of concave polygon outlines into
   // multiple convex polygons.  This would make for better rendering
   // in solid mode, but introduces extra, potentially confusing, lines
   // in wireframe mode.
   // *** Not yet implemented ***

   fSplitConcave = split;

   // Not implemented yet
   if (split) {
      fSplitConcave = kFALSE;
      cout << TNamed::GetName()
           << " TXTRU::SplitConcavePolygon is not yet implemented" << endl;
   }

}


//______________________________________________________________________________
void TXTRU::TruncateNxy(Int_t npts) {

   // Truncate the vertex list

   if ((npts < 0) || (npts > fNxy)) {
      Error(fName,"truncate to %d impossible on %d points",npts,fNxy);
      return;
   }
   fNxy = npts;
   return;
}


//______________________________________________________________________________
void TXTRU::TruncateNz(Int_t nz) {

   // Truncate the z section list

   if ((nz < 0) || (nz > fNz)) {
      Error(fName,"truncate to %d impossible on %d points",nz,fNz);
      return;
   }
   fNz = nz;
   return;
}


//______________________________________________________________________________
void TXTRU::CheckOrdering()
{
   // Determine ordering over which to process points, segments, surfaces
   // so that they render correctly.  Generally this has to do
   // with getting outward normals in the hidden/solid surface case.

   Float_t plus, minus, zero;

   // Check on polygon's shape
   // Convex vs. Concave and ClockWise vs. Counter-ClockWise
   plus = minus = zero = 0;
   Int_t ixy=0;
   for (ixy=0; ixy<fNxy; ixy++) {
      // calculate the cross product of the two segments that
      // meet at vertex "ixy"
      // concave polygons have a mixture of + and - values
      Int_t ixyprev = (ixy + fNxy - 1)%fNxy;
      Int_t ixynext = (ixy + fNxy + 1)%fNxy;

      Float_t dxprev = fXvtx[ixy]     - fXvtx[ixyprev];
      Float_t dyprev = fYvtx[ixy]     - fYvtx[ixyprev];
      Float_t dxnext = fXvtx[ixynext] - fXvtx[ixy];
      Float_t dynext = fYvtx[ixynext] - fYvtx[ixy];

      Float_t xprod = dxprev*dynext - dxnext*dyprev;

      if (xprod > 0) {
         plus += xprod;
      } else if (xprod < 0) {
         minus -= xprod;
      } else {
         zero++;
      }
   }

   if (fNxy<3) {
      // no check yet written for checking that the segments don't cross
      fPolygonShape = kMalformedXY;
   } else {
      if (plus==0 || minus==0) {
         // convex polygons have all of one sign
         if (plus>minus) {
            fPolygonShape = kConvexCCW;
         } else {
            fPolygonShape = kConvexCW;
         }
      } else {
         // concave
         if (plus>minus) {
            fPolygonShape = kConcaveCCW;
         } else {
            fPolygonShape = kConcaveCW;
         }
      }
   }

   // Check on z ordering
   // Convex vs. Concave and increasing or decreasing in z
   plus = minus = zero = 0;
   Bool_t scaleSignChange = kFALSE;
   Int_t iz=0;
   for (iz=0; iz<fNz; iz++) {
      // calculate the cross product of the two segments that
      // meet at vertex "iz"
      // concave polygons have a mixture of + and - values
      Int_t izprev = (iz + fNz - 1)%fNz;
      Int_t iznext = (iz + fNz + 1)%fNz;

      Float_t dzprev = fZ[iz]         - fZ[izprev];
      Float_t dsprev = fScale[iz]     - fScale[izprev];
      Float_t dznext = fZ[iznext]     - fZ[iz];
      Float_t dsnext = fScale[iznext] - fScale[iz];

      // special cases for end faces
      if (iz==0) {
         dzprev = 0;
         dsprev = fScale[0];
      } else if (iz==fNz-1) {
         dznext = 0;
         dsnext = -fScale[iz];
      }

      Float_t xprod = dznext*dsprev - dzprev*dsnext;

      if (xprod > 0) {
         plus += xprod;
      } else if (xprod < 0) {
         minus -= xprod;
      } else {
         zero++;
      }
      // also check for scale factors that change sign...
      if (fScale[iz]*fScale[iznext] < 0) scaleSignChange = kTRUE;
   }

   if (fNz<1 || scaleSignChange) {
      // no check yet written for checking that the segments don't cross
      fZOrdering = kMalformedZ;
   } else {
      if (plus==0 || minus==0) {
         // convex polygons have all of one sign
         if (plus>minus) {
            fZOrdering = kConvexIncZ;
         } else {
            fZOrdering = kConvexDecZ;
         }
      } else {
         // concave
         if (plus>minus) {
            fZOrdering = kConcaveIncZ;
         } else {
            fZOrdering = kConcaveDecZ;
         }
      }
   }
}


//______________________________________________________________________________
void TXTRU::DumpPoints(int npoints, float *pointbuff) const
{
   // Dump the vertex points for visual inspection

   cout << "TXTRU::DumpPoints - " << npoints << " points" << endl;
   int ioff = 0;
   float x,y,z;
   int ipt=0;
   for (ipt=0; ipt<npoints; ipt++) {
      x = pointbuff[ioff++];
      y = pointbuff[ioff++];
      z = pointbuff[ioff++];
      printf(" [%4d] %6.1f %6.1f %6.1f \n",ipt,x,y,z);
   }
}


//______________________________________________________________________________
void TXTRU::DumpSegments(int nsegments, int *segbuff) const
{
   // Dump the segment info for visual inspection

   cout << "TXTRU::DumpSegments - " << nsegments << " segments" << endl;
   int ioff = 0;
   int icol, p1, p2;
   int iseg=0;
   for (iseg=0; iseg<nsegments; iseg++) {
      icol = segbuff[ioff++];
      p1   = segbuff[ioff++];
      p2   = segbuff[ioff++];
      printf(" [%4d] %3d (%4d,%4d)\n",iseg,icol,p1,p2);
   }
}


//______________________________________________________________________________
void TXTRU::DumpPolygons(int npolygons, int *polybuff, int buffsize) const
{
   // Dump the derived polygon info for visual inspection

   cout << "TXTRU::DumpPolygons - " << npolygons << " polygons" << endl;
   int ioff = 0;
   int icol, nseg, iseg;
   int ipoly=0;
   for (ipoly=0; ipoly<npolygons; ipoly++) {
      icol = polybuff[ioff++];
      nseg = polybuff[ioff++];
#ifndef R__MACOSX
      cout << "  [" << setw(4) << ipoly << "] icol " << setw(3) << icol
           << " nseg " << setw(3) << nseg << "  (";
#else
      printf(" [%d4] icol %d3 nseg %d3  (", ipoly, icol, nseg);
#endif
      for (iseg=0; iseg<nseg-1; iseg++) {
         cout << polybuff[ioff++] << ",";
      }
      cout << polybuff[ioff++] << ")" << endl;
   }
   cout << " buffer size " << buffsize << " last used " << --ioff << endl;
}


//______________________________________________________________________________
const TBuffer3D & TXTRU::GetBuffer3D(Int_t reqSections) const
{
   // Get buffer 3d.

   static TBuffer3D buffer(TBuffer3DTypes::kGeneric);

   TShape::FillBuffer3D(buffer, reqSections);

   if (reqSections & TBuffer3D::kRawSizes) {
      // Check that the polygon is well formed
      // convex vs. concave, z ordered monotonically

      if (fPolygonShape == kUncheckedXY ||
          fZOrdering    == kUncheckedZ) {
         const_cast<TXTRU *>(this)->CheckOrdering();
      }
      Int_t nbPnts = fNz*fNxy;
      Int_t nbSegs = fNxy*(2*fNz-1);
      Int_t nbPols = fNxy*(fNz-1)+2;
      if (buffer.SetRawSizes(nbPnts, 3*nbPnts, nbSegs, 3*nbSegs, nbPols, 6*(nbPols-2)+2*(2+fNxy))) {
         buffer.SetSectionsValid(TBuffer3D::kRawSizes);
      }
   }
   if (reqSections & TBuffer3D::kRaw) {
      // Points
      SetPoints(buffer.fPnts);
      if (!buffer.fLocalFrame) {
         TransformPoints(buffer.fPnts, buffer.NbPnts());
      }

      Int_t c = GetBasicColor();

      Int_t i,j, k;
      Int_t indx, indx2;
      indx = indx2 = 0;

      // Segments
      for (i=0; i<fNz; i++) {
         // loop Z planes
         indx2 = i*fNxy;
         // loop polygon segments
         for (j=0; j<fNxy; j++) {
            k = (j+1)%fNxy;
            buffer.fSegs[indx++] = c;
            buffer.fSegs[indx++] = indx2+j;
            buffer.fSegs[indx++] = indx2+k;
         }
      } // total: fNz*fNxy polygon segments
      for (i=0; i<fNz-1; i++) {
         // loop Z planes
         indx2 = i*fNxy;
         // loop polygon segments
         for (j=0; j<fNxy; j++) {
            k = j + fNxy;
            buffer.fSegs[indx++] = c;
            buffer.fSegs[indx++] = indx2+j;
            buffer.fSegs[indx++] = indx2+k;
         }
      } // total (fNz-1)*fNxy lateral segments

            // Polygons
      indx = 0;

      // fill lateral polygons
      for (i=0; i<fNz-1; i++) {
         indx2 = i*fNxy;
         for (j=0; j<fNxy; j++) {
         k = (j+1)%fNxy;
         buffer.fPols[indx++] = c+j%3;
         buffer.fPols[indx++] = 4;
         buffer.fPols[indx++] = indx2+j;
         buffer.fPols[indx++] = fNz*fNxy+indx2+k;
         buffer.fPols[indx++] = indx2+fNxy+j;
         buffer.fPols[indx++] = fNz*fNxy+indx2+j;
         }
      } // total (fNz-1)*fNxy polys
      buffer.fPols[indx++] = c+2;
      buffer.fPols[indx++] = fNxy;
      indx2 = 0;
      for (j = fNxy - 1; j >= 0; --j) {
         buffer.fPols[indx++] = indx2+j;
      }

      buffer.fPols[indx++] = c;
      buffer.fPols[indx++] = fNxy;
      indx2 = (fNz-1)*fNxy;
    
      for (j=0; j<fNxy; j++) {
         buffer.fPols[indx++] = indx2+j;
      }

      buffer.SetSectionsValid(TBuffer3D::kRaw);
   }

   return buffer;
}
 TXTRU.cxx:1
 TXTRU.cxx:2
 TXTRU.cxx:3
 TXTRU.cxx:4
 TXTRU.cxx:5
 TXTRU.cxx:6
 TXTRU.cxx:7
 TXTRU.cxx:8
 TXTRU.cxx:9
 TXTRU.cxx:10
 TXTRU.cxx:11
 TXTRU.cxx:12
 TXTRU.cxx:13
 TXTRU.cxx:14
 TXTRU.cxx:15
 TXTRU.cxx:16
 TXTRU.cxx:17
 TXTRU.cxx:18
 TXTRU.cxx:19
 TXTRU.cxx:20
 TXTRU.cxx:21
 TXTRU.cxx:22
 TXTRU.cxx:23
 TXTRU.cxx:24
 TXTRU.cxx:25
 TXTRU.cxx:26
 TXTRU.cxx:27
 TXTRU.cxx:28
 TXTRU.cxx:29
 TXTRU.cxx:30
 TXTRU.cxx:31
 TXTRU.cxx:32
 TXTRU.cxx:33
 TXTRU.cxx:34
 TXTRU.cxx:35
 TXTRU.cxx:36
 TXTRU.cxx:37
 TXTRU.cxx:38
 TXTRU.cxx:39
 TXTRU.cxx:40
 TXTRU.cxx:41
 TXTRU.cxx:42
 TXTRU.cxx:43
 TXTRU.cxx:44
 TXTRU.cxx:45
 TXTRU.cxx:46
 TXTRU.cxx:47
 TXTRU.cxx:48
 TXTRU.cxx:49
 TXTRU.cxx:50
 TXTRU.cxx:51
 TXTRU.cxx:52
 TXTRU.cxx:53
 TXTRU.cxx:54
 TXTRU.cxx:55
 TXTRU.cxx:56
 TXTRU.cxx:57
 TXTRU.cxx:58
 TXTRU.cxx:59
 TXTRU.cxx:60
 TXTRU.cxx:61
 TXTRU.cxx:62
 TXTRU.cxx:63
 TXTRU.cxx:64
 TXTRU.cxx:65
 TXTRU.cxx:66
 TXTRU.cxx:67
 TXTRU.cxx:68
 TXTRU.cxx:69
 TXTRU.cxx:70
 TXTRU.cxx:71
 TXTRU.cxx:72
 TXTRU.cxx:73
 TXTRU.cxx:74
 TXTRU.cxx:75
 TXTRU.cxx:76
 TXTRU.cxx:77
 TXTRU.cxx:78
 TXTRU.cxx:79
 TXTRU.cxx:80
 TXTRU.cxx:81
 TXTRU.cxx:82
 TXTRU.cxx:83
 TXTRU.cxx:84
 TXTRU.cxx:85
 TXTRU.cxx:86
 TXTRU.cxx:87
 TXTRU.cxx:88
 TXTRU.cxx:89
 TXTRU.cxx:90
 TXTRU.cxx:91
 TXTRU.cxx:92
 TXTRU.cxx:93
 TXTRU.cxx:94
 TXTRU.cxx:95
 TXTRU.cxx:96
 TXTRU.cxx:97
 TXTRU.cxx:98
 TXTRU.cxx:99
 TXTRU.cxx:100
 TXTRU.cxx:101
 TXTRU.cxx:102
 TXTRU.cxx:103
 TXTRU.cxx:104
 TXTRU.cxx:105
 TXTRU.cxx:106
 TXTRU.cxx:107
 TXTRU.cxx:108
 TXTRU.cxx:109
 TXTRU.cxx:110
 TXTRU.cxx:111
 TXTRU.cxx:112
 TXTRU.cxx:113
 TXTRU.cxx:114
 TXTRU.cxx:115
 TXTRU.cxx:116
 TXTRU.cxx:117
 TXTRU.cxx:118
 TXTRU.cxx:119
 TXTRU.cxx:120
 TXTRU.cxx:121
 TXTRU.cxx:122
 TXTRU.cxx:123
 TXTRU.cxx:124
 TXTRU.cxx:125
 TXTRU.cxx:126
 TXTRU.cxx:127
 TXTRU.cxx:128
 TXTRU.cxx:129
 TXTRU.cxx:130
 TXTRU.cxx:131
 TXTRU.cxx:132
 TXTRU.cxx:133
 TXTRU.cxx:134
 TXTRU.cxx:135
 TXTRU.cxx:136
 TXTRU.cxx:137
 TXTRU.cxx:138
 TXTRU.cxx:139
 TXTRU.cxx:140
 TXTRU.cxx:141
 TXTRU.cxx:142
 TXTRU.cxx:143
 TXTRU.cxx:144
 TXTRU.cxx:145
 TXTRU.cxx:146
 TXTRU.cxx:147
 TXTRU.cxx:148
 TXTRU.cxx:149
 TXTRU.cxx:150
 TXTRU.cxx:151
 TXTRU.cxx:152
 TXTRU.cxx:153
 TXTRU.cxx:154
 TXTRU.cxx:155
 TXTRU.cxx:156
 TXTRU.cxx:157
 TXTRU.cxx:158
 TXTRU.cxx:159
 TXTRU.cxx:160
 TXTRU.cxx:161
 TXTRU.cxx:162
 TXTRU.cxx:163
 TXTRU.cxx:164
 TXTRU.cxx:165
 TXTRU.cxx:166
 TXTRU.cxx:167
 TXTRU.cxx:168
 TXTRU.cxx:169
 TXTRU.cxx:170
 TXTRU.cxx:171
 TXTRU.cxx:172
 TXTRU.cxx:173
 TXTRU.cxx:174
 TXTRU.cxx:175
 TXTRU.cxx:176
 TXTRU.cxx:177
 TXTRU.cxx:178
 TXTRU.cxx:179
 TXTRU.cxx:180
 TXTRU.cxx:181
 TXTRU.cxx:182
 TXTRU.cxx:183
 TXTRU.cxx:184
 TXTRU.cxx:185
 TXTRU.cxx:186
 TXTRU.cxx:187
 TXTRU.cxx:188
 TXTRU.cxx:189
 TXTRU.cxx:190
 TXTRU.cxx:191
 TXTRU.cxx:192
 TXTRU.cxx:193
 TXTRU.cxx:194
 TXTRU.cxx:195
 TXTRU.cxx:196
 TXTRU.cxx:197
 TXTRU.cxx:198
 TXTRU.cxx:199
 TXTRU.cxx:200
 TXTRU.cxx:201
 TXTRU.cxx:202
 TXTRU.cxx:203
 TXTRU.cxx:204
 TXTRU.cxx:205
 TXTRU.cxx:206
 TXTRU.cxx:207
 TXTRU.cxx:208
 TXTRU.cxx:209
 TXTRU.cxx:210
 TXTRU.cxx:211
 TXTRU.cxx:212
 TXTRU.cxx:213
 TXTRU.cxx:214
 TXTRU.cxx:215
 TXTRU.cxx:216
 TXTRU.cxx:217
 TXTRU.cxx:218
 TXTRU.cxx:219
 TXTRU.cxx:220
 TXTRU.cxx:221
 TXTRU.cxx:222
 TXTRU.cxx:223
 TXTRU.cxx:224
 TXTRU.cxx:225
 TXTRU.cxx:226
 TXTRU.cxx:227
 TXTRU.cxx:228
 TXTRU.cxx:229
 TXTRU.cxx:230
 TXTRU.cxx:231
 TXTRU.cxx:232
 TXTRU.cxx:233
 TXTRU.cxx:234
 TXTRU.cxx:235
 TXTRU.cxx:236
 TXTRU.cxx:237
 TXTRU.cxx:238
 TXTRU.cxx:239
 TXTRU.cxx:240
 TXTRU.cxx:241
 TXTRU.cxx:242
 TXTRU.cxx:243
 TXTRU.cxx:244
 TXTRU.cxx:245
 TXTRU.cxx:246
 TXTRU.cxx:247
 TXTRU.cxx:248
 TXTRU.cxx:249
 TXTRU.cxx:250
 TXTRU.cxx:251
 TXTRU.cxx:252
 TXTRU.cxx:253
 TXTRU.cxx:254
 TXTRU.cxx:255
 TXTRU.cxx:256
 TXTRU.cxx:257
 TXTRU.cxx:258
 TXTRU.cxx:259
 TXTRU.cxx:260
 TXTRU.cxx:261
 TXTRU.cxx:262
 TXTRU.cxx:263
 TXTRU.cxx:264
 TXTRU.cxx:265
 TXTRU.cxx:266
 TXTRU.cxx:267
 TXTRU.cxx:268
 TXTRU.cxx:269
 TXTRU.cxx:270
 TXTRU.cxx:271
 TXTRU.cxx:272
 TXTRU.cxx:273
 TXTRU.cxx:274
 TXTRU.cxx:275
 TXTRU.cxx:276
 TXTRU.cxx:277
 TXTRU.cxx:278
 TXTRU.cxx:279
 TXTRU.cxx:280
 TXTRU.cxx:281
 TXTRU.cxx:282
 TXTRU.cxx:283
 TXTRU.cxx:284
 TXTRU.cxx:285
 TXTRU.cxx:286
 TXTRU.cxx:287
 TXTRU.cxx:288
 TXTRU.cxx:289
 TXTRU.cxx:290
 TXTRU.cxx:291
 TXTRU.cxx:292
 TXTRU.cxx:293
 TXTRU.cxx:294
 TXTRU.cxx:295
 TXTRU.cxx:296
 TXTRU.cxx:297
 TXTRU.cxx:298
 TXTRU.cxx:299
 TXTRU.cxx:300
 TXTRU.cxx:301
 TXTRU.cxx:302
 TXTRU.cxx:303
 TXTRU.cxx:304
 TXTRU.cxx:305
 TXTRU.cxx:306
 TXTRU.cxx:307
 TXTRU.cxx:308
 TXTRU.cxx:309
 TXTRU.cxx:310
 TXTRU.cxx:311
 TXTRU.cxx:312
 TXTRU.cxx:313
 TXTRU.cxx:314
 TXTRU.cxx:315
 TXTRU.cxx:316
 TXTRU.cxx:317
 TXTRU.cxx:318
 TXTRU.cxx:319
 TXTRU.cxx:320
 TXTRU.cxx:321
 TXTRU.cxx:322
 TXTRU.cxx:323
 TXTRU.cxx:324
 TXTRU.cxx:325
 TXTRU.cxx:326
 TXTRU.cxx:327
 TXTRU.cxx:328
 TXTRU.cxx:329
 TXTRU.cxx:330
 TXTRU.cxx:331
 TXTRU.cxx:332
 TXTRU.cxx:333
 TXTRU.cxx:334
 TXTRU.cxx:335
 TXTRU.cxx:336
 TXTRU.cxx:337
 TXTRU.cxx:338
 TXTRU.cxx:339
 TXTRU.cxx:340
 TXTRU.cxx:341
 TXTRU.cxx:342
 TXTRU.cxx:343
 TXTRU.cxx:344
 TXTRU.cxx:345
 TXTRU.cxx:346
 TXTRU.cxx:347
 TXTRU.cxx:348
 TXTRU.cxx:349
 TXTRU.cxx:350
 TXTRU.cxx:351
 TXTRU.cxx:352
 TXTRU.cxx:353
 TXTRU.cxx:354
 TXTRU.cxx:355
 TXTRU.cxx:356
 TXTRU.cxx:357
 TXTRU.cxx:358
 TXTRU.cxx:359
 TXTRU.cxx:360
 TXTRU.cxx:361
 TXTRU.cxx:362
 TXTRU.cxx:363
 TXTRU.cxx:364
 TXTRU.cxx:365
 TXTRU.cxx:366
 TXTRU.cxx:367
 TXTRU.cxx:368
 TXTRU.cxx:369
 TXTRU.cxx:370
 TXTRU.cxx:371
 TXTRU.cxx:372
 TXTRU.cxx:373
 TXTRU.cxx:374
 TXTRU.cxx:375
 TXTRU.cxx:376
 TXTRU.cxx:377
 TXTRU.cxx:378
 TXTRU.cxx:379
 TXTRU.cxx:380
 TXTRU.cxx:381
 TXTRU.cxx:382
 TXTRU.cxx:383
 TXTRU.cxx:384
 TXTRU.cxx:385
 TXTRU.cxx:386
 TXTRU.cxx:387
 TXTRU.cxx:388
 TXTRU.cxx:389
 TXTRU.cxx:390
 TXTRU.cxx:391
 TXTRU.cxx:392
 TXTRU.cxx:393
 TXTRU.cxx:394
 TXTRU.cxx:395
 TXTRU.cxx:396
 TXTRU.cxx:397
 TXTRU.cxx:398
 TXTRU.cxx:399
 TXTRU.cxx:400
 TXTRU.cxx:401
 TXTRU.cxx:402
 TXTRU.cxx:403
 TXTRU.cxx:404
 TXTRU.cxx:405
 TXTRU.cxx:406
 TXTRU.cxx:407
 TXTRU.cxx:408
 TXTRU.cxx:409
 TXTRU.cxx:410
 TXTRU.cxx:411
 TXTRU.cxx:412
 TXTRU.cxx:413
 TXTRU.cxx:414
 TXTRU.cxx:415
 TXTRU.cxx:416
 TXTRU.cxx:417
 TXTRU.cxx:418
 TXTRU.cxx:419
 TXTRU.cxx:420
 TXTRU.cxx:421
 TXTRU.cxx:422
 TXTRU.cxx:423
 TXTRU.cxx:424
 TXTRU.cxx:425
 TXTRU.cxx:426
 TXTRU.cxx:427
 TXTRU.cxx:428
 TXTRU.cxx:429
 TXTRU.cxx:430
 TXTRU.cxx:431
 TXTRU.cxx:432
 TXTRU.cxx:433
 TXTRU.cxx:434
 TXTRU.cxx:435
 TXTRU.cxx:436
 TXTRU.cxx:437
 TXTRU.cxx:438
 TXTRU.cxx:439
 TXTRU.cxx:440
 TXTRU.cxx:441
 TXTRU.cxx:442
 TXTRU.cxx:443
 TXTRU.cxx:444
 TXTRU.cxx:445
 TXTRU.cxx:446
 TXTRU.cxx:447
 TXTRU.cxx:448
 TXTRU.cxx:449
 TXTRU.cxx:450
 TXTRU.cxx:451
 TXTRU.cxx:452
 TXTRU.cxx:453
 TXTRU.cxx:454
 TXTRU.cxx:455
 TXTRU.cxx:456
 TXTRU.cxx:457
 TXTRU.cxx:458
 TXTRU.cxx:459
 TXTRU.cxx:460
 TXTRU.cxx:461
 TXTRU.cxx:462
 TXTRU.cxx:463
 TXTRU.cxx:464
 TXTRU.cxx:465
 TXTRU.cxx:466
 TXTRU.cxx:467
 TXTRU.cxx:468
 TXTRU.cxx:469
 TXTRU.cxx:470
 TXTRU.cxx:471
 TXTRU.cxx:472
 TXTRU.cxx:473
 TXTRU.cxx:474
 TXTRU.cxx:475
 TXTRU.cxx:476
 TXTRU.cxx:477
 TXTRU.cxx:478
 TXTRU.cxx:479
 TXTRU.cxx:480
 TXTRU.cxx:481
 TXTRU.cxx:482
 TXTRU.cxx:483
 TXTRU.cxx:484
 TXTRU.cxx:485
 TXTRU.cxx:486
 TXTRU.cxx:487
 TXTRU.cxx:488
 TXTRU.cxx:489
 TXTRU.cxx:490
 TXTRU.cxx:491
 TXTRU.cxx:492
 TXTRU.cxx:493
 TXTRU.cxx:494
 TXTRU.cxx:495
 TXTRU.cxx:496
 TXTRU.cxx:497
 TXTRU.cxx:498
 TXTRU.cxx:499
 TXTRU.cxx:500
 TXTRU.cxx:501
 TXTRU.cxx:502
 TXTRU.cxx:503
 TXTRU.cxx:504
 TXTRU.cxx:505
 TXTRU.cxx:506
 TXTRU.cxx:507
 TXTRU.cxx:508
 TXTRU.cxx:509
 TXTRU.cxx:510
 TXTRU.cxx:511
 TXTRU.cxx:512
 TXTRU.cxx:513
 TXTRU.cxx:514
 TXTRU.cxx:515
 TXTRU.cxx:516
 TXTRU.cxx:517
 TXTRU.cxx:518
 TXTRU.cxx:519
 TXTRU.cxx:520
 TXTRU.cxx:521
 TXTRU.cxx:522
 TXTRU.cxx:523
 TXTRU.cxx:524
 TXTRU.cxx:525
 TXTRU.cxx:526
 TXTRU.cxx:527
 TXTRU.cxx:528
 TXTRU.cxx:529
 TXTRU.cxx:530
 TXTRU.cxx:531
 TXTRU.cxx:532
 TXTRU.cxx:533
 TXTRU.cxx:534
 TXTRU.cxx:535
 TXTRU.cxx:536
 TXTRU.cxx:537
 TXTRU.cxx:538
 TXTRU.cxx:539
 TXTRU.cxx:540
 TXTRU.cxx:541
 TXTRU.cxx:542
 TXTRU.cxx:543
 TXTRU.cxx:544
 TXTRU.cxx:545
 TXTRU.cxx:546
 TXTRU.cxx:547
 TXTRU.cxx:548
 TXTRU.cxx:549
 TXTRU.cxx:550
 TXTRU.cxx:551
 TXTRU.cxx:552
 TXTRU.cxx:553
 TXTRU.cxx:554
 TXTRU.cxx:555
 TXTRU.cxx:556
 TXTRU.cxx:557
 TXTRU.cxx:558
 TXTRU.cxx:559
 TXTRU.cxx:560
 TXTRU.cxx:561
 TXTRU.cxx:562
 TXTRU.cxx:563
 TXTRU.cxx:564
 TXTRU.cxx:565
 TXTRU.cxx:566
 TXTRU.cxx:567
 TXTRU.cxx:568
 TXTRU.cxx:569
 TXTRU.cxx:570
 TXTRU.cxx:571
 TXTRU.cxx:572
 TXTRU.cxx:573
 TXTRU.cxx:574
 TXTRU.cxx:575
 TXTRU.cxx:576
 TXTRU.cxx:577
 TXTRU.cxx:578
 TXTRU.cxx:579
 TXTRU.cxx:580
 TXTRU.cxx:581
 TXTRU.cxx:582
 TXTRU.cxx:583
 TXTRU.cxx:584
 TXTRU.cxx:585
 TXTRU.cxx:586
 TXTRU.cxx:587
 TXTRU.cxx:588
 TXTRU.cxx:589
 TXTRU.cxx:590
 TXTRU.cxx:591
 TXTRU.cxx:592
 TXTRU.cxx:593
 TXTRU.cxx:594
 TXTRU.cxx:595
 TXTRU.cxx:596
 TXTRU.cxx:597
 TXTRU.cxx:598
 TXTRU.cxx:599
 TXTRU.cxx:600
 TXTRU.cxx:601
 TXTRU.cxx:602
 TXTRU.cxx:603
 TXTRU.cxx:604
 TXTRU.cxx:605
 TXTRU.cxx:606
 TXTRU.cxx:607
 TXTRU.cxx:608
 TXTRU.cxx:609
 TXTRU.cxx:610
 TXTRU.cxx:611
 TXTRU.cxx:612
 TXTRU.cxx:613
 TXTRU.cxx:614
 TXTRU.cxx:615
 TXTRU.cxx:616
 TXTRU.cxx:617
 TXTRU.cxx:618
 TXTRU.cxx:619
 TXTRU.cxx:620
 TXTRU.cxx:621
 TXTRU.cxx:622
 TXTRU.cxx:623
 TXTRU.cxx:624
 TXTRU.cxx:625
 TXTRU.cxx:626
 TXTRU.cxx:627
 TXTRU.cxx:628
 TXTRU.cxx:629
 TXTRU.cxx:630
 TXTRU.cxx:631
 TXTRU.cxx:632
 TXTRU.cxx:633
 TXTRU.cxx:634
 TXTRU.cxx:635
 TXTRU.cxx:636
 TXTRU.cxx:637
 TXTRU.cxx:638
 TXTRU.cxx:639
 TXTRU.cxx:640
 TXTRU.cxx:641
 TXTRU.cxx:642
 TXTRU.cxx:643
 TXTRU.cxx:644
 TXTRU.cxx:645
 TXTRU.cxx:646
 TXTRU.cxx:647
 TXTRU.cxx:648
 TXTRU.cxx:649
 TXTRU.cxx:650
 TXTRU.cxx:651
 TXTRU.cxx:652
 TXTRU.cxx:653
 TXTRU.cxx:654
 TXTRU.cxx:655
 TXTRU.cxx:656
 TXTRU.cxx:657
 TXTRU.cxx:658
 TXTRU.cxx:659
 TXTRU.cxx:660
 TXTRU.cxx:661
 TXTRU.cxx:662
 TXTRU.cxx:663
 TXTRU.cxx:664
 TXTRU.cxx:665
 TXTRU.cxx:666
 TXTRU.cxx:667
 TXTRU.cxx:668
 TXTRU.cxx:669
 TXTRU.cxx:670
 TXTRU.cxx:671
 TXTRU.cxx:672
 TXTRU.cxx:673
 TXTRU.cxx:674
 TXTRU.cxx:675
 TXTRU.cxx:676
 TXTRU.cxx:677
 TXTRU.cxx:678
 TXTRU.cxx:679
 TXTRU.cxx:680
 TXTRU.cxx:681
 TXTRU.cxx:682
 TXTRU.cxx:683
 TXTRU.cxx:684
 TXTRU.cxx:685
 TXTRU.cxx:686
 TXTRU.cxx:687
 TXTRU.cxx:688
 TXTRU.cxx:689
 TXTRU.cxx:690
 TXTRU.cxx:691
 TXTRU.cxx:692
 TXTRU.cxx:693
 TXTRU.cxx:694
 TXTRU.cxx:695
 TXTRU.cxx:696
 TXTRU.cxx:697
 TXTRU.cxx:698
 TXTRU.cxx:699
 TXTRU.cxx:700
 TXTRU.cxx:701
 TXTRU.cxx:702
 TXTRU.cxx:703
 TXTRU.cxx:704
 TXTRU.cxx:705
 TXTRU.cxx:706
 TXTRU.cxx:707
 TXTRU.cxx:708
 TXTRU.cxx:709
 TXTRU.cxx:710
 TXTRU.cxx:711
 TXTRU.cxx:712
 TXTRU.cxx:713
 TXTRU.cxx:714
 TXTRU.cxx:715
 TXTRU.cxx:716
 TXTRU.cxx:717
 TXTRU.cxx:718
 TXTRU.cxx:719
 TXTRU.cxx:720
 TXTRU.cxx:721
 TXTRU.cxx:722
 TXTRU.cxx:723
 TXTRU.cxx:724
 TXTRU.cxx:725
 TXTRU.cxx:726
 TXTRU.cxx:727
 TXTRU.cxx:728
 TXTRU.cxx:729
 TXTRU.cxx:730
 TXTRU.cxx:731
 TXTRU.cxx:732
 TXTRU.cxx:733
 TXTRU.cxx:734
 TXTRU.cxx:735
 TXTRU.cxx:736
 TXTRU.cxx:737
 TXTRU.cxx:738
 TXTRU.cxx:739
 TXTRU.cxx:740
 TXTRU.cxx:741
 TXTRU.cxx:742
 TXTRU.cxx:743
 TXTRU.cxx:744
 TXTRU.cxx:745
 TXTRU.cxx:746
 TXTRU.cxx:747
 TXTRU.cxx:748
 TXTRU.cxx:749
 TXTRU.cxx:750
 TXTRU.cxx:751
 TXTRU.cxx:752
 TXTRU.cxx:753
 TXTRU.cxx:754
 TXTRU.cxx:755
 TXTRU.cxx:756
 TXTRU.cxx:757
 TXTRU.cxx:758
 TXTRU.cxx:759
 TXTRU.cxx:760
 TXTRU.cxx:761
 TXTRU.cxx:762
 TXTRU.cxx:763
 TXTRU.cxx:764
 TXTRU.cxx:765
 TXTRU.cxx:766
 TXTRU.cxx:767
 TXTRU.cxx:768
 TXTRU.cxx:769
 TXTRU.cxx:770
 TXTRU.cxx:771
 TXTRU.cxx:772
 TXTRU.cxx:773
 TXTRU.cxx:774
 TXTRU.cxx:775
 TXTRU.cxx:776
 TXTRU.cxx:777
 TXTRU.cxx:778
 TXTRU.cxx:779
 TXTRU.cxx:780
 TXTRU.cxx:781
 TXTRU.cxx:782
 TXTRU.cxx:783
 TXTRU.cxx:784
 TXTRU.cxx:785
 TXTRU.cxx:786
 TXTRU.cxx:787
 TXTRU.cxx:788
 TXTRU.cxx:789
 TXTRU.cxx:790
 TXTRU.cxx:791
 TXTRU.cxx:792
 TXTRU.cxx:793
 TXTRU.cxx:794
 TXTRU.cxx:795
 TXTRU.cxx:796
 TXTRU.cxx:797
 TXTRU.cxx:798
 TXTRU.cxx:799
 TXTRU.cxx:800
 TXTRU.cxx:801
 TXTRU.cxx:802
 TXTRU.cxx:803
 TXTRU.cxx:804
 TXTRU.cxx:805
 TXTRU.cxx:806
 TXTRU.cxx:807
 TXTRU.cxx:808
 TXTRU.cxx:809
 TXTRU.cxx:810
 TXTRU.cxx:811
 TXTRU.cxx:812
 TXTRU.cxx:813
 TXTRU.cxx:814
 TXTRU.cxx:815
 TXTRU.cxx:816
 TXTRU.cxx:817
 TXTRU.cxx:818
 TXTRU.cxx:819
 TXTRU.cxx:820
 TXTRU.cxx:821
 TXTRU.cxx:822
 TXTRU.cxx:823
 TXTRU.cxx:824
 TXTRU.cxx:825
 TXTRU.cxx:826
 TXTRU.cxx:827
 TXTRU.cxx:828
 TXTRU.cxx:829
 TXTRU.cxx:830
 TXTRU.cxx:831
 TXTRU.cxx:832
 TXTRU.cxx:833
 TXTRU.cxx:834
 TXTRU.cxx:835
 TXTRU.cxx:836
 TXTRU.cxx:837
 TXTRU.cxx:838
 TXTRU.cxx:839
 TXTRU.cxx:840
 TXTRU.cxx:841
 TXTRU.cxx:842
 TXTRU.cxx:843
 TXTRU.cxx:844
 TXTRU.cxx:845
 TXTRU.cxx:846
 TXTRU.cxx:847
 TXTRU.cxx:848
 TXTRU.cxx:849
 TXTRU.cxx:850
 TXTRU.cxx:851
 TXTRU.cxx:852
 TXTRU.cxx:853
 TXTRU.cxx:854
 TXTRU.cxx:855
 TXTRU.cxx:856
 TXTRU.cxx:857
 TXTRU.cxx:858
 TXTRU.cxx:859
 TXTRU.cxx:860
 TXTRU.cxx:861
 TXTRU.cxx:862
 TXTRU.cxx:863
 TXTRU.cxx:864
 TXTRU.cxx:865
 TXTRU.cxx:866
 TXTRU.cxx:867
 TXTRU.cxx:868
 TXTRU.cxx:869
 TXTRU.cxx:870
 TXTRU.cxx:871
 TXTRU.cxx:872
 TXTRU.cxx:873
 TXTRU.cxx:874
 TXTRU.cxx:875
 TXTRU.cxx:876
 TXTRU.cxx:877
 TXTRU.cxx:878
 TXTRU.cxx:879
 TXTRU.cxx:880
 TXTRU.cxx:881
 TXTRU.cxx:882
 TXTRU.cxx:883
 TXTRU.cxx:884
 TXTRU.cxx:885
 TXTRU.cxx:886
 TXTRU.cxx:887
 TXTRU.cxx:888
 TXTRU.cxx:889