di.fm TV is an AppleTV application for streaming Digitally Imported radio.
I am a long-time loyal fan of Digitally Imported Radio. Digitally Imported has a very nice iOS application that works perfectly (and even works with CarPlay), however, they never released an official app for the AppleTV.
I wanted a Digitally Imported app for a set-top box system because these kinds of computers are always connected to great sound systems and have a lot of visualization potential thanks to often being connected to very large screens. Therefore, I created this application which contains a full implementation of the AudioAddict streaming protocol and my own unique visualization in the Now Playing screen.
The di.fm app is written in pure Swift with some Objective-C to handle the low-level audio streaming code. I had to drop down to using the
AudioQueue API on OS X in order to be able to install processing taps on the audio code and handle the unique way that the AudioAddict protocol sends metadata down to applications. The streaming code is localized to the reusable
ZANStreamPlayer class which allows clients to do both of these things really easily with any kind of audio stream.
The source code for this project is freely available on my sourcehut.
You can watch a demonstration video of the software here.