/// <inheritdoc /> protected override void Dispose(bool disposing) { if (disposing) { CuFFTException.ThrowIfFailed( API.Destroy(PlanHandle)); PlanHandle = IntPtr.Zero; } base.Dispose(disposing); }
/// <summary> /// Overrides the work area associated with a plan. /// </summary> public void SetWorkArea(ArrayView <byte> workArea) => CuFFTException.ThrowIfFailed( API.SetWorkArea(PlanHandle, workArea));
/// <summary> /// Indicates whether to allocate work area. /// </summary> public void SetAutoAllocate(bool autoAllocate) => CuFFTException.ThrowIfFailed( API.SetAutoAllocation(PlanHandle, autoAllocate ? 1 : 0));
/// <summary> /// Associates a CUDA stream with a cuFFT plan. /// </summary> public void SetStream(CudaStream cudaStream) { CuFFTException.ThrowIfFailed( API.SetStream(PlanHandle, cudaStream)); }
/// <summary> /// Returns the work size. /// </summary> /// <param name="workSize">Populated with the estimated size in bytes.</param> public void GetSize(UIntPtr[] workSize) => CuFFTException.ThrowIfFailed( API.GetSize( PlanHandle, workSize));