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: removing album art updates modified date even if no art present (Read 1313 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

removing album art updates modified date even if no art present

I had noticed that unbeknownst to me some of my files had embedded cover art. I just selected the whole library and removed album art from all (flac) files.
What I noticed now is that this changes the files' "modified date" even if no art was present (so the files should not have been changed).
This is a problem because now backup software sees all the file as new and thus copies the file again even if not necessary. This was a bit annoying when I ran the "remove art" option on my entire library...

As there is no easy way that I know of to find files with embedded art the easiest way to get rid of unnecessary embedded art is just to run the option on all files. But I don't want to have to re-copy all files to my backup every time.

Is there a reason why the modified date should be touched in this case?

Re: removing album art updates modified date even if no art present

Reply #1
Might be a duplicate of: https://hydrogenaud.io/index.php/topic,123714.0.html

Re: removing album art updates modified date even if no art present

Reply #2
Could it have something to do with the FLAC cover removal process also removing slack that was present in the no-art files?  Have you tried comparing a before/after example with "Bit-Compare tracks"?

Re: removing album art updates modified date even if no art present

Reply #3
The size of the files do not change.

Re: removing album art updates modified date even if no art present

Reply #4
As there is no easy way that I know of to find files with embedded art the easiest way to get rid of unnecessary embedded art is just to run the option on all files. But I don't want to have to re-copy all files to my backup every time.
You'd probably like this:
No such field is available in default fb2k.

However, I do have a component that can scan your collection for embedded covers.

https://marc2k3.github.io/component/cover-info/

After installing/scanning, you can use %front_cover_width% PRESENT or %front_cover_width% MISSING for a filter.

edit: this is for fb2k 2.0 only.

I was also going to mention Mp3tag but then I read this thread this thread where someone says
Quote
The advice on deleting pictures: don't.
and
Quote
Removing coverart from a flac file requires an extra tool to access the (little) extra space as otherwise the new space is used as padding and you don't see any of it.
The second part is delved into here.

So I think that, assuming Foobar2000 deletes the covers properly, you're definitely better off using marc2k3's component (I haven't tried it, though) and fb2k to delete the covers.

Lastly, if you aren't using fb2k v2, and you don't want to go through this rigmarole, you could in fact use Mp3tag to find them and then come back to fb2k to delete them.

Add a new field to all your tracks in fb2k like hascover or something. Leave it empty for now.
In Mp3tag, Ctrl+D and point to your library. (Wait a bit. The first scan takes a while on a big library.)
Type %_covers% PRESENT in the Filter: box at the bottom
You'll see all the tracks have a "1" in the Covers column.
Select them all
Alt+T
Put "True" or whatever in the hascover field
OK
There's a Save button top left but I think it saves automatically anyway, not sure. No harm in clicking it to make sure, as long as you're happy adding True to the hascover field for all those files.
Now you can find them all in fb2k.

[If you want to do this with mp3s instead of FLACs, it's straightforward to remove the covers within Mp3tag, with no need for all that hascover tagging stuff. Just Alt+T and press the red cross near the cover image.]

Re: removing album art updates modified date even if no art present

Reply #5
Thanks. This indeed seems to be a route to avoid touching all the files. I am running it now. Will probably take a long time on a large library though.
I would much rather understand if the is a reason for the current behaviour though. And if not then it seems like something that should be fixed and maybe affects other things too.

Re: removing album art updates modified date even if no art present

Reply #6
FWIW the batch file below will remove all covers and padding from any FLAC files within the directory it is executed from.  Change the path of metaflac to match yours and be aware that the latest versions require the presence of libFLAC.dll in the same directory as metaflac.exe:
Code: [Select]
@echo off
:: Enter metaflac directory inside the ""
set metaflac="C:\Program Files (x86)\Exact Audio Copy\Flac\metaflac.exe"

cd %1
echo. 1>&2
for %%A in (*.flac) do (
%metaflac% --dont-use-padding --remove --block-type=PICTURE,PADDING "%%A"
echo [Processed %%A]
)
echo. 1>&2
@PAUSE
Will take a while with large directories.

 

Re: removing album art updates modified date even if no art present

Reply #7
BTW, using "Optimize file layout + minimize file size" in fb2k after removing embedded pictures will remove all padding in FLAC files.

Re: removing album art updates modified date even if no art present

Reply #8
Nice find, thanks.
Fixing for the next update so it stops rewriting unchanged tags in this case.
Microsoft Windows: We can't script here, this is bat country.

Re: removing album art updates modified date even if no art present

Reply #9
Thanks! I can confirm that modified date is unchanged now.