Re: mpg123 porting: libmp3lame non-parallel init code?
Thomas Orgis <[email protected]> Fri, 1 Sep 2017 08:02:44 +0200
| Newsgroups | gmane.comp.audio.mp3.lame |
|---|---|
| Message-ID | <20170901080244.33d38387@sturbolzen> |
Am Sun, 27 Aug 2017 13:41:37 +0200 schrieb Thomas Orgis <[email protected]>: > Am I right in assuming that lame_init() is _not_ the right place, as it > can be called many times to create multiple instances in a parallel > program? Well, so far I settled for calling mpg123_init() on each call to hip_decode_exit() (it has internal flag to only run once, and even if tho concurring instances end up running, the filling of static buffers should be safe even then). I dropped mpg123_exit() as that does nothing and I don't see what it should do in future. I will mark it as a dud in mpg123 API. I am ignoring the deprecated lame_decode API for now. Should it stay? The name lame_decode() is arguably better than hip_decode(). I am confident that a patch will arrive … for sure within September. I do not have so much to change in libmpg123. I got most of the pinfo extraction already, even. One might add the option to do a minimal build with existing libmpg123 that does not extract the raw ID3 nor pinfo for the analyser. Oh, and one thing so far is just a stub: the use of error reporting functions. But I guess I can configure libmpg123 to be silent also on errors and instead reconstruct a message in the lame binding using mpg123_strerror(), which then is handed to the user-supplied callback. This is more tricky for debugging and general messages. There so far is no way in mpg123 to route those through a callback. It might be an idea to add it, though. And in the end, if I tell libmpg123 to be quiet, it won't produce those … I see that the libmp3lame API nicely supports integer or float decoding. I still would like the get_audio() stuff also get floats from libmpg123. I guess this is a separate patch, though, that should be obvious once I demonstrated float output in the libmp3lame patch. Alrighty then, Thomas ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Lame-dev mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/lame-dev