I was hoping if I changed the method to non-static, I could have multiple instances of espeak in play at once. Maybe the lib itself just doesn’t support this, but asking just in case there’s something I can do on the c++ side. I confess that I don’t yet understand typedef usage and lib-interface…
@roymacdonald std::bind() requires me to include the method arguments, but it looks like these would normally be set from inside the api as synthcall is defined, but never called in the src files except for when it’s set as a callback:
hi, you have to pass placeholders for the arguments.
So, the following should work if called from within ofxEspeakSynth. std::bind(&ofxEspeakSynth::synthcall, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3)
The espeak_setSynthCallback takes an argument of type t_espeak_callback*, but the original code accepts a static method name. How can I use the bound method as an argument?
@roymacdonald So espeak_SetSynthCallback() takes as an argument a method without parentheses, but only works with static methods. How would I use std::bind in this situation?