Changeset 3aac194 for src


Ignore:
Timestamp:
Sep 15, 2018, 4:27:29 PM (14 months ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/constantq, feature/pitchshift, feature/pydocstrings, feature/timestretch, master
Children:
c9ca2608
Parents:
d8b1161 (diff), 95e3cba (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.
Message:

Merge branch 'feature/dct_multiopt' into feature/fastmfcc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/spectral/dct_accelerate.c

    rd8b1161 r3aac194  
    2929#endif
    3030
    31 struct _aubio_dct_t {
     31struct _aubio_dct_accelerate_t {
    3232  uint_t size;
    3333  fvec_t *tmp;
     
    3636};
    3737
    38 aubio_dct_t * new_aubio_dct (uint_t size) {
    39   aubio_dct_t * s = AUBIO_NEW(aubio_dct_t);
     38typedef struct _aubio_dct_accelerate_t aubio_dct_accelerate_t;
     39
     40void del_aubio_dct_accelerate (aubio_dct_accelerate_t *s);
     41
     42aubio_dct_accelerate_t * new_aubio_dct_accelerate (uint_t size) {
     43  aubio_dct_accelerate_t * s = AUBIO_NEW(aubio_dct_accelerate_t);
    4044
    4145  if ((sint_t)size < 16 || !aubio_is_power_of_two(size)) {
    4246    AUBIO_ERR("dct: can only create with sizes greater than 16 and"
    43         "that are powers of two, requested %d\n", size);
     47        " that are powers of two, requested %d\n", size);
    4448    goto beach;
    4549  }
     
    5660
    5761beach:
    58   del_aubio_dct(s);
     62  del_aubio_dct_accelerate(s);
    5963  return NULL;
    6064}
    6165
    62 void del_aubio_dct(aubio_dct_t *s) {
     66void del_aubio_dct_accelerate(aubio_dct_accelerate_t *s) {
    6367  if (s->setup) vDSP_DFT_DestroySetup(s->setup);
    6468  if (s->setupInv) vDSP_DFT_DestroySetup(s->setupInv);
     
    6670}
    6771
    68 void aubio_dct_do(aubio_dct_t *s, const fvec_t *input, fvec_t *output) {
     72void aubio_dct_accelerate_do(aubio_dct_accelerate_t *s, const fvec_t *input, fvec_t *output) {
    6973
    7074  vDSP_DCT_Execute(s->setup, (const float *)input->data, (float *)output->data);
     
    7983}
    8084
    81 void aubio_dct_rdo(aubio_dct_t *s, const fvec_t *input, fvec_t *output) {
     85void aubio_dct_accelerate_rdo(aubio_dct_accelerate_t *s, const fvec_t *input, fvec_t *output) {
    8286
    8387  output->data[0] = input->data[0] / SQRT(1./s->size);
Note: See TracChangeset for help on using the changeset viewer.