/// <summary> /// Class level dispose method /// </summary> /// <param name="disposeManagedResources">True if Unmanaged resources should be released.</param> protected override void dispose(bool disposeManagedResources) { if (!IsDisposed) { if (disposeManagedResources) { // Delete viewports if (ViewportList != null) { RemoveAllViewports(); ViewportList = null; } //DepthBuffer keeps track of us, avoid a dangling pointer DetachDepthBuffer(); // Write final performance stats if (LogManager.Instance != null) LogManager.Instance.Write("Final Stats [{0}]: FPS <A,B,W> : {1:#.00} {2:#.00} {3:#.00}", name, stats.AverageFPS, stats.BestFPS, stats.WorstFPS); } } base.dispose(disposeManagedResources); }
/// <summary> /// Default constructor. /// </summary> public RenderTarget() { this.viewportList = new ViewportCollection(this); numFaces = 0; }