printf( "---- Graphics-State Stats -----\n"); printf( "  GStates requested:       %d\n", mCount); printf( "  Actual GStates created:  %d\n", mPeak);
PRINTF( "---- Graphics-State Stats -----\n"); PRINTF( "  GStates requested:       %d\n", mCount); PRINTF( "  Actual GStates created:  %d\n", mPeak);
  ~GraphicsStateCache()   {#ifdef PROFILE_GSTATE      printf( "---- Graphics-State Stats -----\n");      printf( "  GStates requested:       %d\n", mCount);      printf( "  Actual GStates created:  %d\n", mPeak);      double d = mCount ? (double)(mCount - mPeak) / (double)mCount : 0;      printf( "  Gstates recycled:        %d (%d%%)\n", mCount - mPeak, (int)(d*100.0));      UINT i = mSize+mDeleted;      printf( "  Cached+Deleted:          %d\n", i);      if( i != mPeak)         printf( "  WARNING: GStates leaked: %d\n", mPeak - i);      printf( "------------------------------\n\n");#endif      // Clear up the cache      GraphicsState *pTemp, *pNext = mFirst;      while( pNext)      {         pTemp = pNext->mNext;         delete pNext;         pNext = pTemp;      }   }