private void Dispose(bool disposing) { if (disposing) { ComputeBuffer.DestroyBuffer(this); } else if (this.m_Ptr != IntPtr.Zero) { Debug.LogWarning("GarbageCollector disposing of ComputeBuffer. Please use ComputeBuffer.Release() or .Dispose() to manually release the buffer."); } this.m_Ptr = IntPtr.Zero; }
private void Dispose(bool disposing) { if (disposing) { ComputeBuffer.DestroyBuffer(this); } else if (this.m_Ptr != IntPtr.Zero) { Debug.LogWarning(string.Format("GarbageCollector disposing of ComputeBuffer allocated in {0} at line {1}. Please use ComputeBuffer.Release() or .Dispose() to manually release the buffer.", this.GetFileName(), this.GetLineNumber())); } this.m_Ptr = IntPtr.Zero; }
private void Dispose(bool disposing) { ComputeBuffer.DestroyBuffer(this); this.m_Ptr = IntPtr.Zero; }