Creating a mixer in order to resample?

Started by kafffee,

kafffee

QuoteCombining "--ogg" and "--picture" is supported by BASSenc_FLAC, and appears to be supported by the official FLAC encoder too.  Does removing the "--ogg" option help?

Yes, when I remove the "--ogg" then the file that is produced will contain a picture. There seems to be a limit in file size though, my tag editor only displays half the picture.

QuoteThe image will be in a METADATA_BLOCK_PICTURE block like in a normal FLAC file, but I guess some software may expect embedded images to be in the Ogg comments when it's an Ogg file.

I read that when an OGG FLAC file contains a picture then METADATA_BLOCK_PICTURE data is saved as a "translated" Base64 string within a Vorbis comment. Is that correct?
Maybe it's really my tag editor, because I checked: My file definitely contains the string "reference libFLAC" but still it displays that there is no Vorbis Comment included.

QuoteIs it definitely adding Ogg/FLAC tags? Perhaps it's adding ID3 tags instead? You could check that in a hex editor.

It is. My file starts like this:

OggS␂!i€ú+␟2␁3�FLAC␁␃fLaC"␐␐
ÄCp␒woOggS!i€␁S§j8␁ƒ,,� reference libFLAC 1.4.3 20230623␅␓ARTIST=testerartist
TRACKNUMBER=1␌TRACKTOTAL=1␌DISCNUMBER=1␋DISCTOTAL=1OggS!i€␂+£þ␅!ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ$�

You can see the pages starting with "OggS". There's no sign for any ID3 tag. Also I'm sure that ID3 supports pictures.

Ian @ un4seen

Quote from: kafffeeI read that when an OGG FLAC file contains a picture then METADATA_BLOCK_PICTURE data is saved as a "translated" Base64 string within a Vorbis comment. Is that correct?
Maybe it's really my tag editor, because I checked: My file definitely contains the string "reference libFLAC" but still it displays that there is no Vorbis Comment included.

Opus and Vorbis files can have METADATA_BLOCK_PICTURE blocks base64-encoded in the text comments, but Ogg FLAC files don't currently. METADATA_BLOCK_PICTURE blocks are instead kept in their original binary form. If you open your Ogg FLAC file in a hex editor, you should see "image/png" where the METADATA_BLOCK_PICTURE block is but no "METADATA_BLOCK_PICTURE" text.

kafffee

Ah okay that makes it a lot clearer  :)

I was confused by the fact that my OGG Vorbis and OGG OPUS files all contain pics but not OGG FLAC, even though they 're all in a OGG container right? Respectively have a OGG Vorbis Comment...

QuoteIf you open your Ogg FLAC file in a hex editor, you should see "image/png" where the METADATA_BLOCK_PICTURE block is but no "METADATA_BLOCK_PICTURE" text.

You mean there's literally a string like "image/png" instead of the Base64 string?

QuoteMETADATA_BLOCK_PICTURE blocks are instead kept in their original binary form.

At what part of the file?

Ian @ un4seen

METADATA_BLOCK_PICTURE block(s) will be after the text tags (Vorbis comments), so near the start. The "image/png" is part of the METADATA_BLOCK_PICTURE block (the media type string):

    https://www.rfc-editor.org/rfc/rfc9639.html#name-picture