Feature request

Right now MPD server doesn't deal with binary metadata of the audio file, especially cover arts. It's also impossible to add it through metadata_to_use, as non-defined tags like +METADATA_BLOCK_PICTURE cause MPD failing to start with exception: error parsing metadata item "METADATA_BLOCK_PICTURE" message. Adding it as an option to metadata_to_use would probably work, but would also put unnecessary overhead due to caching as part of tag_cache and being available for queries, which is suboptimal considering it's binary and doesn't need to be cached in advance, just as audio stream.

I'd like to request a way for MPD to treat certain metadata blocks as binary, such as adding binary_metadata_to_use property. That is, they wouldn't be normally cached in tag_cache (as they're not readable text), but rather be read as part of the file (same as audio stream currently) and sent to the listener as usual by being appended to appropriate metadata tags, such as OpusTags for opus codec. This way, I could use binary_metadata_to_use "+METADATA_BLOCK_PICTURE" in order to tell MPD to extract METADATA_BLOCK_PICTURE (if available) as part of the file read, and broadcast it with the rest of the tags.

There are also other use cases that would benefit from the above, mainly tags that we'd like to send, but not necessarily read in advance and cache. Examples might include stuff like encoded lyrics, band logotype (part of ID3v2), METADATA_BLOCK_CUESHEET and other metadata that we might potentially want to transmit, but we don't need to cache and read in advance.

I found similar issue #42, but based on reading it, it covers MPD clients and not MPD server. I don't need mpc to return me the art, I need MPD to send the tag as part of the currently played file to the icecast2 stream.

As usual I'm attaching a sample file to make testing a bit easier. The end goal is to connect to icecast2 mpd stream (I use opus encoder with opustags "true") and see the cover art in program like VLC.

sample.zip

Thank you in advance for considering this feature request. As usual the above is only my suggestion as to what can be done, I'll be happy with any solution that would allow me to embed METADATA_BLOCK_PICTURE in my opus icecast2 stream, read directly from the files.