Changeset bbfa9a4 for src/spectral/dct.c
- Timestamp:
- Nov 26, 2018, 6:53:43 PM (5 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/timestretch, fix/ffmpeg5, master
- Children:
- adc6e02
- Parents:
- 8a11e2f (diff), db3eb5c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/spectral/dct.c
r8a11e2f rbbfa9a4 82 82 aubio_dct_t* new_aubio_dct (uint_t size) { 83 83 aubio_dct_t * s = AUBIO_NEW(aubio_dct_t); 84 if ((sint_t)size <= 0) goto beach;85 84 #if defined(HAVE_ACCELERATE) 86 85 // vDSP supports sizes = f * 2 ** n, where n >= 4 and f in [1, 3, 5, 15] … … 89 88 uint_t radix = size; 90 89 uint_t order = 0; 91 while ((radix / 2) * 2 == radix) {90 while ((radix >= 1) && ((radix / 2) * 2 == radix)) { 92 91 radix /= 2; 93 92 order++; … … 113 112 return s; 114 113 } else { 115 AUBIO_WRN("dct: unex cepected error while creating dct_fftw with size %d",114 AUBIO_WRN("dct: unexpected error while creating dct_fftw with size %d\n", 116 115 size); 117 116 goto plain; … … 126 125 return s; 127 126 } else { 128 AUBIO_WRN("dct: unex cepected error while creating dct_ipp with size %d",127 AUBIO_WRN("dct: unexpected error while creating dct_ipp with size %d\n", 129 128 size); 130 129 goto plain; … … 144 143 #endif 145 144 // falling back to plain mode 146 AUBIO_WRN("dct: d no optimised implementation could be created for size %d",145 AUBIO_WRN("dct: no optimised implementation could be created for size %d\n", 147 146 size); 148 147 plain: … … 157 156 } 158 157 beach: 159 AUBIO_ERROR("dct: failed creating with size %d, should be > 0 ", size);160 AUBIO_FREE(s);158 AUBIO_ERROR("dct: failed creating with size %d, should be > 0\n", size); 159 del_aubio_dct(s); 161 160 return NULL; 162 161 }
Note: See TracChangeset
for help on using the changeset viewer.