Menu

MusicPlayer / Blog: Recent posts

Improving the audio callback. Removing audio glitches

From time to time I noticed that there are audio glitches at playback. These were usually in form of small gaps and sounded like a small jitter.

Audio callback

Audio in a PC works roughly like this: The soundcard tells the OS that it needs more data, maybe 10ms of audio data. And it needs those fast, maybe within the next 10ms. The OS then tells the audio application that it needs more data. That is where our code is called. This is called the audio callback. We must return a certain amount of data and we must return it fast. If we fail to be fast enough, the soundcard will not get the data fast enough and there will be a small gap / audio glitch.... read more

Posted by Albert Zeyer 2014-01-11 Labels: audio

Embedded Python and MacOSX 10.8 compatibility

Yesterday, I noticed that the current MusicPlayer build does not work on MacOSX 10.8. I'm on MacOSX 10.9 since some time and a month ago, I added back MacOSX 10.6 support, where I started to use an own embedded Python build (see here for details).

It turns out that I still added Python paths to the system Python at startup. And this turned out to be necessary to make it work at all because the embedded Python lacked quite some modules. Funilly, it seems to be broken only on MacOSX 10.8 and works on 10.6 and 10.9 (didn't tested on 10.7). It took a while to add module after module and stumble through all the error messages at runtime or at compiling, but finally this does it: Changes on embedded Python branch and changes on MusicPlayer.... read more

Posted by Albert Zeyer 2013-12-29 Labels: macosx python

MacOSX 10.6 compatibility

I don't have the ability to test MacOSX 10.6 that often. I recently did and the support was totally broken. It did not even start at all.

In short: The support is fully back, the latest version known to work on MacOSX 10.6 is 20131108-1-a92441c.zip.

It took a while to get that support back.

The first problem was that my FFmpeg build somehow was not working on MacOSX 10.6. It seems that I cannot use my own Homebrew builds anymore because there is no good way to build MacOSX 10.6 compatible libraries with Homebrew on a newer MacOSX version. In the end, that lead my contributions to some custom build script which is here now.... read more

Posted by Albert Zeyer 2013-11-08 Labels: macosx10.6 macosx