예제 #1
0
        public override void imagedraw(cGraphics pgraphics, int drawflags)
        {
            if ((Edged & !Filled) || ((drawflags & ACView.DF_WIREFRAME) != 0))

            /* If the sphere is filled, lets not draw its edges unless we're in wireframe
             * The reason I put this in is because in many games the sprite by default is
             * edged and filled for the sake of the polygonal sprites, and then if we select
             * a sphere sprite and its edged as well as filled it runs too slow. */
            {
                pgraphics.setMaterialColor(LineColor);
                glshape.glutWireSphere(_radius, _slices, _stacks);
            }
            if (Filled && ((drawflags & ACView.DF_WIREFRAME) == 0))
            {
                pgraphics.setMaterialColor(FillColor);
                glshape.glutSolidSphere(_radius, _slices, _stacks);
            }
        }
 public override void imagedraw(cGraphics pgraphics, int drawflags)
 {
     /*
      * if (( Edged & !Filled ) || ( (drawflags & ACView.DF_WIREFRAME) != 0 ))
      *          {
      *                  pgraphics.setMaterialColor( LineColor );
      *                  glshape.glutWireSphere( _radius, _slices, _stacks );
      *          }
      *          if ( Filled && ( (drawflags & ACView.DF_WIREFRAME) == 0 ))
      *          {
      *                  pgraphics.setMaterialColor( FillColor );
      *                  glshape.glutSolidSphere( _radius, _slices, _stacks );
      *          }
      */
     pgraphics.setMaterialColor(LineColor);
     glshape.glutWireSphere(_radius, _slices, _stacks);
     if (Filled)
     {
         pgraphics.setMaterialColor(FillColor);
         glshape.glutSolidSphere(_radius, _slices, _stacks);
     }
 }