Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: fb2k corrupts iTunes cover art (Read 5740 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

fb2k corrupts iTunes cover art

I'm working on my own SW app for AAC files that uses faad2/mp4ff for tagging (same as fb2k). I found that calling mp4ff_meta_get_by_index to read all the tags and then calling mp4ff_meta_update to write back (modified) values corrupts the 'covr' tag used by iTunes to store album cover art.

I thought this might by a bug in my own code, but I was able to duplicate the problem in fb2k as follows:

a) add cover art with iTunes to an AAC (.m4a) file
b) open the same file with fb2k and analyze replaygain
c) go back to iTunes and the cover art no longer displays

Could it be that the cover art is a binary field with embedded 0's and the use of strlen in mp4ff_meta_update does not yield the correct length?

I couldn't find any reference to problem anywhere on the net - the closest I got was this post:
http://www.hydrogenaudio.org/forums/index....showtopic=29120

I'll do some more debugging to try to pin this down further but would appreciate it if anyone else has any insight into this problem.

Thanks for the help!

Dave

fb2k corrupts iTunes cover art

Reply #1
It is not corrupted. It is simply ignored by the tag reader, and removed by the act of regenerating the tags with only the supported plaintext information.

fb2k corrupts iTunes cover art

Reply #2
Quote
It is not corrupted. It is simply ignored by the tag reader, and removed by the act of regenerating the tags with only the supported plaintext information.
[{POST_SNAPBACK}][/a]


That's not what happened to me. The corrupted 'covr' tag was left in the file.

It sure looks to me like fb2k is trying to process the mp4 'covr' tag's binary data as a utf8 string. In my original post I forgot to mention that I also got assertion failures for invalid utf-8 characters when trying to read or write the replaygain tags via fb2k.

The particular [a href="http://images.amazon.com/images/P/B0000032E2.01.LZZZZZZZ.jpg]image[/url] I was using for my cover art, when added via iTunes, had a zero as the 5th data byte of the data field of the 'covr' tag. After fb2k rewrote the metadata, the 'covr' tag's length was reduced from 38KB to 4 bytes. This caused iTunes to display it as a white box.

In my own application I am going to stop using faad2's libmp4ff and switch to libmp4v2, which appears to handle mp4 binary metadata correctly (i.e. there are explicit length fields). I would humbly suggest that fb2k do the same.

For more info, see my thread in the audiocoding.com faad2 forum.

Thanks...

Dave

fb2k corrupts iTunes cover art

Reply #3
I haven't read this topic before and i used masstagger to add "auto track number" to my m4a and mp3 files i tagged with itunes or wmp10 (including cover arts). After masstagger i lost all covers stored in the files and it's very annoying - it has been more than 2000 files... 
The cover tag's still there, but itunes shows only a white box instead of the cover (and wmp for mp3 shows nothing)
Is there any solution for this annoying behaviour of foobar? I don't want to miss foobar's ingenious masstagger...

fb2k corrupts iTunes cover art

Reply #4
I don't think this is a bug.  The masstagger in foobar is intended to delete all embedded images.

fb2k corrupts iTunes cover art

Reply #5
And there's no solution to around this?
When foobar's masstagger always deletes embedded images and is intended to do so, then i have to look for an other tagging solution. I don't want to miss embedded covers cos i've sorted my music as "best of the year's" and want every file with the original cover from the cd i ripped it from. I don't like the foobar solution (one cover in the folder for every file in it).
So i must "renumber" my files by hand in the future (puh, what an effort...) 

fb2k corrupts iTunes cover art

Reply #6
Quote
So i must "renumber" my files by hand in the future (puh, what an effort...) 
[a href="index.php?act=findpost&pid=282511"][{POST_SNAPBACK}][/a]

No. You don't have to do this by hand - there are taggers out there which support renumbering and cover images.

fb2k corrupts iTunes cover art

Reply #7
With a function like foobar's "auto track number"? And perhaps some other goodies like foobar's masstagger and similar tagging options (like custom fields like "cpopyright", "composer" and so on)? AND support for cover images? Freeware? 
I don't know one. Could you please give me a link?

fb2k corrupts iTunes cover art

Reply #8
Same issue happens with MP3 files. I tagged them in MediaMonkey and once Foobar2000 scaned those files and added replaygain info coverart doesn't display anymore. Even after re-downloading cover art for some files, they tend to disappear if you switch between foobar2000 and Media Monkey, although I would just play them in foobar and not tag them.

fb2k corrupts iTunes cover art

Reply #9
I hope there will be support for embedded images in the near future in foobar2000.
This would be great.
Now i decided to first renumber my files in foobar2000 and add cover arts later with "audioshell 1.0" for the next time. But it's too late for my about 10,000 files i saved to my "HD-Media Library" until now...
Good that i noticed it on the first 2,000 files, so i can renumber the other files with an other program. But which program is able to do (especially for aac) with preserving all other tags (like copyright, comments and composer/writer tags)?
"MP3tag" doesn't seem to handle these "custom" tags, "Media Tagger" 1.3.5 can't save the mp4 tags...

fb2k corrupts iTunes cover art

Reply #10
Quote
"MP3tag" doesn't seem to handle these "custom" tags.
[a href="index.php?act=findpost&pid=282652"][{POST_SNAPBACK}][/a]

Mp3tag has full support for these custom tag fields via the extended tag dialog ("View, Tags..." or Alt+T) or directly by adding a column for the tag field to the file view ("View, Columns...").

Best regards,
~ Florian

fb2k corrupts iTunes cover art

Reply #11
Quote
I don't think this is a bug.  The masstagger in foobar is intended to delete all embedded images.
[a href="index.php?act=findpost&pid=282506"][{POST_SNAPBACK}][/a]


Is this feature planned to continue in the next version? I must admit that I don't like the fact that the user can't decide for himself what tag-info to remove from files.

AtW

 

fb2k corrupts iTunes cover art

Reply #12
@Ganymed
Thank you. I'll try it.