1) the first song begins to stream after a few kbytes are cached up
2) the music continues to play while the rest of the track is still being downloaded.
3) once the full track is downloaded the playback stops and there is an exception logged in the app's logcat output....
I/AudioService( 356): AudioFocus requestAudioFocus() from android.media.AudioManager@41b2c988
I/AudioService( 356): AudioFocus abandonAudioFocus() from android.media.AudioManager@41b2c988
E/MediaPlayer( 2892): error (1, -1004)
E/MediaPlayer( 2892): Error (1,-1004)
W/DownloadServiceImpl( 2892): Media player error: java.lang.Exception: MediaPlayer error: 1 (-1004)
W/DownloadServiceImpl( 2892): java.lang.Exception: MediaPlayer error: 1 (-1004)
W/DownloadServiceImpl( 2892): at net.sourceforge.subsonic.androidapp.service.DownloadServiceImpl$1.onError(DownloadServiceImpl.java:120)
4) at this point, I can restart the track again and it will play all the way through, but needless to say, that's not exactly streaming.
I am using the suggested transcode line that I found on the wiki page, i.e.:
ffmpeg -i %s -acodec libvorbis -ab %bk -f ogg -
I was seeing this problem with 4.6 and after I upgraded to the latest release 4.7, it's still happening. I should note that I don't have this problem if I use the FLAC->mp3 transcoding*, only with OGG, however I'd prefer to use OGG since it handles low bitrates better than MP3, IMHO.
I know there are other folks here who are doing this so could you please share your secret sauce to getting this working? Ideally, I'd like the transcoded OGG's that end up on the phone to have the music metadata so that the tracks can also be played via the Google Play Music app at a later time, but that's not a must-have. Right now, I just want to get it working correctly.
* - there is another problem with transcoding to MP3, where the music pauses briefly during the caching of the first track in the playlist, but that's outside the scope of this post.
