This is the bug/patch tracker for Rockbox. Click here for more information.
Quick links: Bugs · Patches · Rockbox frontpage
FS#11139 - music pause on buffer refill - FS#10919 not completely solved
Attached to Project:
Rockbox
Opened by Ronald Malbosc (Chiyo-chan) - Tuesday, 23 March 2010, 11:26 GMT+1
Opened by Ronald Malbosc (Chiyo-chan) - Tuesday, 23 March 2010, 11:26 GMT+1
|
DetailsHi,
I think that the problem reported on But now, I get the feeling that the pause only happens when the buffer refill is triggered via a track skip. During normal playback, it don't seem to happen any more. The build I tried it on is r25249. TIA |
This task depends upon
If you let it play normally it starts to rebuffer shortly *in advance* of running out of data, so that there is no gap..
But I forgot to mention that the pause occurs after a few hundreds ms of the next track.
The action to go to the next track when the next track is not buffered is a little longer, so I presume it's doing something on the disk.
It plays a few hundreds ms of the track, then pause and resume.
Once or twice, I got the feeling that these few hundreds ms were pure audio garbage, but most of the time it's really the start of the new track.
It's exactly the same symptoms that the one I described in
FS#11016(which was a duplicate of theFS#10919I mentioned when opening this bug) excepts that it not longer occurs on normal playback refills.In fact, it's getting stranger.
If I understand correctly, the 'track count' under the buffering thread debug screen counts the number of track currently in the buffer, including the one playing.
Meaning that 1 means that the next song isn't buffered yet.
The strange thing is that the music pause happens when you skip to the next track when the track count is showing 2.
Then the next track plays for half a second then playback pause and shortly after the status bar shows that rockbox is reading something from the disk.
After that, going to the buffering thread debug screen shows that the buffer is now filled.
When skipping to the next track when the track count is 1 doesn't produce this pause.
The next track skip is a little longer to kick in though, probably waiting for the buffer to have a few pieces of the next track.
The first buffer fill, the one that occurs at startup) and the next ones (buffer RE-fill) don't do the same thing.
The difference lies in how they treat the last track, the one that doesn't completly fit in the buffer.
The first buffer fill will fill the buffer with as much data as possible while the buffer re-fill will simply put a really small part of the track in the buffer, leaving a relatively big part of the buffer empty.
I'm saying that it put a really small part because it would explain the track count being 2 just before AND the few hundred ms I can ear before the playback pause.
Since I've already discovered that this playback pause happens when I activate DB + dircache + WPS with an unicode font (see
FS#11016), it should be interesting to see how buffer re-fill works then.The bug is still here.
I've discovered another interesting thing : when dircache is deactivated, the buffer re-fills work as the first buffer fill, meaning that the last track (the one that doesn't fill entirely) gets partially (more than a few ms) buffered.
The 2 log entries show in debug screen (show & dump), but none of them seem to work.
show log only clears the screen & dump shows a splash saying that the log file was dumped, but I can't find any file name logf.txt.
Something special needs to be done ?
This time I tried to disable this (load tagcache to ram): the re-fills worked has it should!
tagcache not loaded to ram exhibits the same symptoms that when loaded to ram.
It *looks* like it happens when you skip ahead to a partially buffered handle (i.e. when track count is 2) and the skip results in the watermark for rebuffering being passed; if so, then the problem should happen less often if you use a larger value for the antiskip buffer (as this makes the watermark higher). It won't eliminate it, though, if you have long tracks or switch codecs mid-playlist or similar...
I could be wrong though.