Ejemplo n.º 1
0
 /// <inheritdoc />
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         CuFFTException.ThrowIfFailed(
             API.Destroy(PlanHandle));
         PlanHandle = IntPtr.Zero;
     }
     base.Dispose(disposing);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Overrides the work area associated with a plan.
 /// </summary>
 public void SetWorkArea(ArrayView <byte> workArea) =>
 CuFFTException.ThrowIfFailed(
     API.SetWorkArea(PlanHandle, workArea));
Ejemplo n.º 3
0
 /// <summary>
 /// Indicates whether to allocate work area.
 /// </summary>
 public void SetAutoAllocate(bool autoAllocate) =>
 CuFFTException.ThrowIfFailed(
     API.SetAutoAllocation(PlanHandle, autoAllocate ? 1 : 0));
Ejemplo n.º 4
0
 /// <summary>
 /// Associates a CUDA stream with a cuFFT plan.
 /// </summary>
 public void SetStream(CudaStream cudaStream)
 {
     CuFFTException.ThrowIfFailed(
         API.SetStream(PlanHandle, cudaStream));
 }
Ejemplo n.º 5
0
 /// <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));