Rockbox Technical Forums

Support and General Use => Audio Playback, Database and Playlists => Topic started by: mrzapp on December 06, 2020, 12:26:53 AM

Title: Some files won't play (Sansa Clip Zip)
Post by: mrzapp on December 06, 2020, 12:26:53 AM
I've got some very specific cases of whole albums that won't play.

For example, all MC Frontalot's albums that I got from Bandcamp all play just fine, except for the latest one: "Net Split"

Here's what I've tried:

From a technical standpoint, everything seems the same across the albums, sampling rate and all. There are no extra audio channels either.

Is there anywhere I could get maybe a log or something detailing why the Sansa Clip Zip won't play certain files?
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: saratoga on December 07, 2020, 11:20:51 PM
Can you post a link to one of the files (maybe a short one) that doesn't play?  It would be surprising for mp3, flac and ogg to all have the same problem since the codecs have little in common.
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: mrzapp on December 08, 2020, 03:38:36 AM
I was trying to slice up some of the audio to avoid copyright violation when I noticed something really odd.

The files that won't play will actually play if I move them to another folder  ???

One of the files in question is called "01 Internet Sucks.ogg"

When it's located in "/Music/MC Frontalot/Net Split", it won't play

But when I copy/paste the file to "/Test" (from within Rockbox or from my PC) it does play.

Permissions are the same for both folders

I feel like I'm missing something obvious, but I still can't see it.
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: mrzapp on December 08, 2020, 03:59:44 AM
OK, I think I've found out why it won't play.

When I remove the "cover.jpg" file from the folder, all songs play as they should. Turns out that image is huge, about 6MB. Why Bandcamp would include a cover file of that size in the download is beyond me.

Could it be that player is running out of RAM trying to display such a big image? If that's the case, it would probably be useful to perform a check before attempting to display the cover image, rather than playback just failing entirely.
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: saratoga on December 08, 2020, 09:32:36 AM
Could you post a link to the cover? Decoding large jpegs uses only a little ram so it should work.
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: mrzapp on December 08, 2020, 09:41:58 AM
Sure, the cover is here: https://we.tl/t-cYqoRqOrsf
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: saratoga on December 08, 2020, 11:47:09 AM
I took a quick look and the issue is memory related, basically the image is so wide the scalar cannot fit one horizontal row of pixels into memory.  I'm a little confused why that freezes playback, the decoder correctly notices that this is an issue and tries to fail gracefully, so I'm not sure why playback stops.
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: saratoga on December 09, 2020, 01:24:12 PM
I put up a fix for this on gerrit:  https://gerrit.rockbox.org/r/c/rockbox/+/3074

If there are no issues I'll push to the main build in a few days.

Also, while looking at this, I fixed an unrelated crash in resizing:

https://gerrit.rockbox.org/r/c/rockbox/+/3073

I'll also commit that at the same time.
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: mrzapp on December 09, 2020, 03:56:39 PM
Cool! I'm glad this incident turned out to be useful  :)
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: saratoga on December 29, 2020, 12:05:22 PM
Fix is committed. If you have further problems with album art in the current build please let us know.
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: mrzapp on December 29, 2020, 11:29:37 PM
I'll check it out right away. Thank you! 🙏
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: KeithSPG on April 24, 2021, 12:14:59 PM
I am running this on an Ipod Video with the current image (not the development version) and have the same issue with a large jpg. As was suggested above, I deleted the jpg and I was able to play the flacs.
The image is here:(https://drive.google.com/file/d/1ZpXTaUbEWa106hKk_dRaEvYDXYZZQZUF/view?usp=sharing)
It is 11,605KB as reported by Windows.
Should I try with the development version?
Title: Re: Some files won't play (Sansa Clip Zip)
Post by: saratoga on April 24, 2021, 12:30:47 PM
Should I try with the development version?

Only if you want the fix discussed in this thread :)