[Flac] Flac] Where Cover Art?

Santiago Jimeno sjimeno at ya.com
Sun Jan 23 02:21:57 PST 2011


OK Martin. Thank you for the explanations and for your time.

I am writing a program that reads and writes all existent Tags types. It 
lacks only to end the edition (rewriting) of "Native" Flac and Matroska. 
Both cases for the same problem: the separation of Tags and Picture in 
different blocks. In Flac I resolved it, but now I have to add 
METADATA_BLOCK_PICTURE. Reading Vorbis Comments of different file types as 
binary I found they were not compatible.

I don't use in any case the libraries provided. All code is own Visual C #. 
For that reason I have these problems. In Vorbis Comments case is maybe 
already solved in the libraries provided, but I have to write it with my own 
code and I have not found documentation until you have explained to me it. 
In Matroska case, libraries doesn't exist for editing Tags.

Another question:  which is the maximum size of an oggs stream? In the 
sample files with covers, one has 4335 bytes (17 page_segments) and the 
other one 65025 (255 page_segments). Is the size decision free? And if it's 
this way, why not to put the whole comments in a stream without split?

Lastly I inform you, revising other programs, Easytag 2.1.6 (last revision 
using libraries provided) uses COVERART and COVERTARTMIME tag names for 
pictures, and also adds (mentioning them as not official) COVERARTTYPE and 
COVERARTDESCRIPTION.

Regards. Santiago

----- Original Message ----- 
From: "Martin Leese" <martin.leese at stanfordalumni.org>
To: "Santiago Jimeno" <sjimeno at ya.com>
Sent: Sunday, January 23, 2011 2:25 AM
Subject: Re: [Flac] Flac] Where Cover Art?


> On 1/22/11, Santiago Jimeno <sjimeno at ya.com> wrote:
>> You said "With the exception of where to put a picture file, 
>> VorbisComments
>> in a Vorbis stream are the same as VorbisComments in a FLAC stream."
>>
>> In METADATA_BLOCK_PICTURE case they would not be the same. Up to now we
>> could exchange the complete block of VorbisComments. But with the 
>> addiction
>> of METADATA_BLOCK_PICTURE doesn't happen this way.
>>
>> In Ogg files the METADATA_BLOCK_PICTURE data are split in numerous 
>> pieces,
>> each one of them with a Oggs header (44 up to 282 bytes of non Base64 
>> data
>> among each piece). Just as they are written would be impossible to put 
>> them
>> in the block 4 of Flac Metadata.
>
> You seem to be confusing the Ogg container
> with the Vorbis stream.  An Ogg container can
> contain many streams.  When it contains a
> single Vorbis stream the result is called Ogg
> Vorbis.  When it contains a single FLAC
> stream the result is called Ogg FLAC.  A FLAC
> stream can also be placed in its own container,
> the result being called Native FLAC.
>
> The Ogg container chops up the streams it
> contains; that is part of what it does.  When
> VorbisComments are part of a Vorbis stream
> and placed in an Ogg container (Ogg Vorbis),
> the stream is chopped up.  When
> VorbisComments are part of a FLAC stream
> and placed in an Ogg container (Ogg FLAC),
> the stream will also be chopped up.  When
> VorbisComments are part of a FLAC stream
> and placed within its own container (Native
> FLAC), the stream is not chopped up.
>
> If you wish to extract VorbisComments from an
> Ogg Vorbis file then you should use the
> libraries provided.  (I don't do this so cannot
> give you details.)
>
>> But the specifications are only for Ogg files. For Flac is not specified 
>> if
>> the data, after METADATA_BLOCK_PICTURE=, would be a long string of Base64
>> format (without split) or otherwise. It seems that the decision is of Ogg
>> team and Flac team has not said anything on this matter.
>
> This in incorrect.  When a Vorbis stream is
> extracted from the Ogg container then any
> VorbisComments it contains are no longer
> split.
>
>> I thought I could choose among both forms of inserting a picture. But
>> thinking it well, the decision is made because of the silence of Flac. 
>> Flac
>> will continue using the block 6. And in METADATA_BLOCK_PICTURE case,
>> VorbisComments are not compatible. I continue thinking that to have two
>> different blocks for this is very bad design.
>
> As I have already explained, you can choose
> to include a picture file in a FLAC stream in
> either a VorbisComment or in a FLAC
> METADATA_BLOCK.
>
> Regards,
> Martin
> -- 
> Martin J Leese
> E-mail: martin.leese  stanfordalumni.org
> Web: http://members.tripod.com/martin_leese/
> 




More information about the Flac mailing list