@@ -78,8 +78,8 @@ grid3D< complex< T >, if_pod_type< T > >
7878 inline complex < pod_type >& operator ()(const size_t & row, const size_t & col, const size_t & lay);
7979 inline const complex < pod_type >& operator ()(const size_t & row, const size_t & col, const size_t & lay) const ;
8080
81- inline void layer_wise_DFT2 (const complex < double >& scale = complex < pod_type >(1 , 0 ));
82- inline void layer_wise_IDFT2 (const complex < double >& scale = complex < pod_type >(1 , 0 ));
81+ inline void layer_wise_DFT2 (const complex < double >& scale = complex < pod_type >(1 , 0 ), int threads = 1 );
82+ inline void layer_wise_IDFT2 (const complex < double >& scale = complex < pod_type >(1 , 0 ), int threads = 1 );
8383};
8484
8585
@@ -306,7 +306,7 @@ const complex< T >& grid3D< complex< T >, if_pod_type< T > >::operator()(const s
306306
307307template < typename T >
308308inline
309- void grid3D< complex < T >, if_pod_type< T > >::layer_wise_DFT2(const complex < double >& scale)
309+ void grid3D< complex < T >, if_pod_type< T > >::layer_wise_DFT2(const complex < double >& scale, int threads )
310310{
311311 // declare variables
312312 size_t i;
@@ -336,7 +336,7 @@ void grid3D< complex< T >, if_pod_type< T > >::layer_wise_DFT2(const complex< do
336336 }
337337
338338 // perform layerwise FFT2
339- uzl_fftw_layer_wise_DFT2_grid3D (cols, rows, lays, data);
339+ uzl_fftw_layer_wise_DFT2_grid3D (cols, rows, lays, data, threads );
340340
341341 // skip if scale is default
342342 if (scale.re != 1 || scale.im != 0 )
@@ -367,7 +367,7 @@ void grid3D< complex< T >, if_pod_type< T > >::layer_wise_DFT2(const complex< do
367367
368368template < typename T >
369369inline
370- void grid3D< complex < T >, if_pod_type< T > >::layer_wise_IDFT2(const complex < double >& scale)
370+ void grid3D< complex < T >, if_pod_type< T > >::layer_wise_IDFT2(const complex < double >& scale, int threads )
371371{
372372 // declare variables
373373 size_t i;
@@ -397,7 +397,7 @@ void grid3D< complex< T >, if_pod_type< T > >::layer_wise_IDFT2(const complex< d
397397 }
398398
399399 // perform layerwise FFT2
400- uzl_fftw_layer_wise_IDFT2_grid3D (cols, rows, lays, data);
400+ uzl_fftw_layer_wise_IDFT2_grid3D (cols, rows, lays, data, threads );
401401
402402 // skip if scale is default
403403 if (scale.re != 1 || scale.im != 0 )
0 commit comments