1
0
Fork 0
forked from len0rd/rockbox

Describe the magic of search_albumart_files (still not complete)

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21120 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Alexander Levin 2009-05-28 20:05:31 +00:00
parent 96165abec2
commit a484054d55

View file

@ -120,16 +120,20 @@ static bool try_exts(char *path, int len)
#endif #endif
/* Look for the first matching album art bitmap in the following list: /* Look for the first matching album art bitmap in the following list:
* ./<trackname><size>.bmp * ./<trackname><size>.{jpeg,jpg,bmp}
* ./<albumname><size>.bmp * ./<albumname><size>.{jpeg,jpg,bmp}
* ./cover<size>.bmp * ./cover<size>.bmp
* ../<albumname><size>.bmp * ../<albumname><size>.{jpeg,jpg,bmp}
* ../cover<size>.bmp * ../cover<size>.{jpeg,jpg,bmp}
* ROCKBOX_DIR/albumart/<artist>-<albumname><size>.bmp * ROCKBOX_DIR/albumart/<artist>-<albumname><size>.{jpeg,jpg,bmp}
* <size> is the value of the size_string parameter, <trackname> and * <size> is the value of the size_string parameter, <trackname> and
* <albumname> are read from the ID3 metadata. * <albumname> are read from the ID3 metadata.
* If a matching bitmap is found, its filename is stored in buf. * If a matching bitmap is found, its filename is stored in buf.
* Return value is true if a bitmap was found, false otherwise. * Return value is true if a bitmap was found, false otherwise.
*
* If the first symbol in size_string is a colon (e.g. ":100x100")
* then the colon is skipped ("100x100" will be used) and the track
* specific image (./<trackname><size>.bmp) is not tried.
*/ */
bool search_albumart_files(const struct mp3entry *id3, const char *size_string, bool search_albumart_files(const struct mp3entry *id3, const char *size_string,
char *buf, int buflen) char *buf, int buflen)