Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • python/lib/gen_code.py

    rc96e6c0 rce79a9e  
    33    'buf_size': 'Py_default_vector_length',
    44    'win_s': 'Py_default_vector_length',
    5     'size': 'Py_default_vector_length',
    65    # and here too
    76    'hop_size': 'Py_default_vector_length / 2',
     
    8483        'filterbank': 'self->n_filters',
    8584        'tss': 'self->buf_size',
    86         'dct': 'self->size',
    8785        }
    8886
     
    193191            out += self.gen_del()
    194192            out += self.gen_do()
    195             if len(self.prototypes['rdo']):
    196                 self.do_proto = self.prototypes['rdo'][0]
    197                 self.do_inputs = [get_params_types_names(self.do_proto)[1]]
    198                 self.do_outputs = get_params_types_names(self.do_proto)[2:]
    199                 out += self.gen_do(method='rdo')
    200193            out += self.gen_memberdef()
    201194            out += self.gen_set()
     
    378371        return out
    379372
    380     def gen_do(self, method = 'do'):
     373    def gen_do(self):
    381374        out = """
    382375// do {shortname}
    383376static PyObject*
    384 Pyaubio_{shortname}_{method}  (Py_{shortname} * self, PyObject * args)
    385 {{""".format(**self.__dict__, method = method)
     377Py_{shortname}_do  (Py_{shortname} * self, PyObject * args)
     378{{""".format(**self.__dict__)
    386379        input_params = self.do_inputs
    387380        output_params = self.do_outputs
     
    523516  {{"{shortname}", (PyCFunction) Py{name},
    524517    METH_NOARGS, ""}},""".format(name = name, shortname = shortname)
    525         for m in self.prototypes['rdo']:
    526             name = get_name(m)
    527             shortname = name.replace('aubio_%s_' % self.shortname, '')
    528             out += """
    529   {{"{shortname}", (PyCFunction) Py{name},
    530     METH_VARARGS, ""}},""".format(name = name, shortname = shortname)
    531518        out += """
    532519  {NULL} /* sentinel */
     
    554541  0,
    555542  0,
    556   (ternaryfunc)Pyaubio_{shortname}_do,
     543  (ternaryfunc)Py_{shortname}_do,
    557544  0,
    558545  0,
Note: See TracChangeset for help on using the changeset viewer.