Discussion:
[Flac] Tags lost when decoding
David Balažic
2018-01-27 19:37:26 UTC
Permalink
Hi!

On windows x64: flac -d "Some file.flac"
decodes the file to WAVE format, but the tags (like artists and title) are
lost.

Reading the docs, I understand that tags should be kept.

Even if I force some tags: flac -d -T "ARTIST=Queen" -T "TITLE=aaaor"
"Some file.flac"
they are missing from the destination file (even check with a hex editor)

Is this some known issue? Am I missing something?

PS: I used this:
https://ftp.osuosl.org/pub/xiph/releases/flac/flac-1.3.2-win.zip
But v1.3.0 behaves the same.

Regards,
David
spaceman
2018-01-27 21:43:33 UTC
Permalink
Hi,
On windows x64: flac -d "Some file.flac" decodes the file to WAVE format,
but the tags (like artists and title) are lost.
Reading the docs, I understand that tags should be kept.
As far as I know the WAVE format doesn't support tags, that's why they
are not kept.

Regards,
spaceman
Brian Willoughby
2018-01-28 01:00:18 UTC
Permalink
Try decoding to AIFF instead.

flac -d —force-aiff “Some file.flac”

and see how that works.

I don’t enter tags manually, so I can’t guarantee that this works any better. However, I do use iTunes and enter lots of meta information that is presumably stored in standard tags. With iTunes, I find that WAVE format will not accept the information that I want to add, so I have a habit of converting to AIFF instead, just so I can have all the features that I’m used to.


On a side note, any WAVE-specific tags can be preserved in the FLAC file using the —keep-foreign-metadata option when encoding the FLAC. If this is done, then anything that was in the original WAVE file will still exist in the uncompressed copy. However, tags that aren’t supported by WAVE obviously cannot be preserved.

I believe that you have to use the —keep-foreign-metadata on both encode and decode, otherwise the WAVE is created from scratch with only the header and audio, and nothing else.

Sounds like you’re decoding only, not encoding, so —keep-foreign-metadata might not help you.


Finally, —keep-foreign-metadata will not translate non-audio data between WAVE and AIFF. This option only works when restoring the original file format. It also does not compress the metadata, so the FLAC will be larger.

Brian
On windows x64: flac -d "Some file.flac" decodes the file to WAVE format,
but the tags (like artists and title) are lost.
Reading the docs, I understand that tags should be kept.
As far as I know the WAVE format doesn't support tags, that's why they
are not kept.
Regards,
spaceman
Loading...