How do I remove padding after deleting metadata?, Was: Compressing metadata? |
![]() ![]() |
How do I remove padding after deleting metadata?, Was: Compressing metadata? |
Apr 11 2012, 14:56
Post
#1
|
|
|
Group: Members Posts: 339 Joined: 24-November 08 Member No.: 63072 |
HI!! Is there something able to rebuild a FLAC file from scratch or simply compress ezisting metadata? I figured out that when I insert an exhaustive tag such as large cover picture then remove it, the FLAC file won't shrink! Replacing an attachment by a bigger one obviously biggers the file. Of course I need the tool to preserve all existing metadata.
|
|
|
|
Apr 11 2012, 15:11
Post
#2
|
|
|
Group: Members Posts: 109 Joined: 20-August 07 Member No.: 46367 |
With metaflac, you're looking for the --dont-use-padding option which tells it not to replace the removed picture with padding, such as:
CODE metaflac --remove --block-type=PICTURE --dont-use-padding file.flac
|
|
|
|
Apr 11 2012, 15:18
Post
#3
|
|
|
Group: Members Posts: 339 Joined: 24-November 08 Member No.: 63072 |
Thanks for quick response, unfortunatelly I don't use metaflac to handle a flac metadata, so I already have a FLAC with superfluous padding block(s).
What does --merge-padding --sort-padding do and is there a option that flushes spare padding blocks? |
|
|
|
Apr 11 2012, 15:53
Post
#4
|
|
|
Group: Members Posts: 3083 Joined: 1-September 05 From: SE Pennsylvania Member No.: 24233 |
How serious of a problem could this be? Generally metadata is a tiny fraction of a lossless file.
|
|
|
|
Apr 11 2012, 16:13
Post
#5
|
|
|
Group: Members Posts: 339 Joined: 24-November 08 Member No.: 63072 |
In case of pure text metadata this issue is negligible but imagine 10 album tracks containing each 1MB cover image, now wanting to cleanup the superfluous non audio data there's total 10MB of discardable data blocks that can't be freed?
|
|
|
|
Apr 11 2012, 21:07
Post
#6
|
|
|
Group: Members Posts: 43 Joined: 27-November 11 Member No.: 95439 |
unfortunatelly I don't use metaflac to handle a flac metadata, so I already have a FLAC with superfluous padding block(s). What does --merge-padding --sort-padding do and is there a option that flushes spare padding blocks? This should do it: CODE metaflac --dont-use-padding --remove --block-type=PADDING file.flac
|
|
|
|
Apr 11 2012, 21:28
Post
#7
|
|
|
Group: Members Posts: 339 Joined: 24-November 08 Member No.: 63072 |
|
|
|
|
Apr 11 2012, 21:36
Post
#8
|
|
|
Group: Super Moderator Posts: 4355 Joined: 23-June 06 Member No.: 32180 |
“Rewrite file tags”?
|
|
|
|
Apr 11 2012, 21:45
Post
#9
|
|
|
Group: Members Posts: 339 Joined: 24-November 08 Member No.: 63072 |
“Rewrite file tags”? Tried that and it won't opt out free blocks. I`m trying with "Run services" and command string cmd /c for %i in ("%directoryname%\*.flac") do D:\media\lossless\metaflac.exe --dont-use-padding --remove --block-type=PADDING "%~fi" It won't work for some reason however. |
|
|
|
Apr 11 2012, 22:44
Post
#10
|
|
![]() Group: Members Posts: 3291 Joined: 27-January 05 From: England Member No.: 19379 |
as you're using foobar2000, highlight all fields in the properties dialog for the selected files. right click>copy. now click on the tools button>remove tags. finally right click and paste fields.
as always, test on a subset of copied files first. This post has been edited by marc2003: Apr 11 2012, 22:45 |
|
|
|
Apr 11 2012, 23:38
Post
#11
|
|
|
Group: Members Posts: 339 Joined: 24-November 08 Member No.: 63072 |
as you're using foobar2000, highlight all fields in the properties dialog for the selected files. right click>copy. now click on the tools button>remove tags. finally right click and paste fields. as always, test on a subset of copied files first. This didnot rebuild FLACs either. Seems metaflac only does the optimization. Anyway I'd like the same function as Utilites->Optimize MP4 Layout for FLACs as those apply a fragmentation effect too. |
|
|
|
Apr 12 2012, 00:51
Post
#12
|
|
![]() Group: Members Posts: 3291 Joined: 27-January 05 From: England Member No.: 19379 |
apologies for not testing before posting. using "remove tags" doesn't even remove the artwork like it should.
|
|
|
|
Apr 12 2012, 01:16
Post
#13
|
|
![]() Group: Members Posts: 469 Joined: 5-June 11 Member No.: 91257 |
Create a custom foobar2000 converter action...
For example: Encoder: metaflac.exe Extension: flac Parameters: -s --dont-use-padding --remove --block-type=PADDING -o %d Converter name: METAFLAC Bitrate: blank Settings: Strip padding from FLAC files |
|
|
|
Apr 12 2012, 08:24
Post
#14
|
|
|
Group: Members Posts: 339 Joined: 24-November 08 Member No.: 63072 |
Create a custom foobar2000 converter action... I'm trying this profile and get error console with 18 out of 18 tracks converted with major problems. For each file I get error Source: "E:\test\01 - Track01.flac" Unable to open file for writing (File is already in use) : "E:\test\01 - Track01.flac" Conversion failed: File is already in use Using Destination: Output folder: source file folder. Output type: tracks into individual files. File name pattern: %filename% Overwrite existing files. Processing: None. Other: When finished: do nothing. What did I set wrong? |
|
|
|
Apr 12 2012, 09:18
Post
#15
|
|
|
Group: Developer Posts: 648 Joined: 26-September 07 Member No.: 47369 |
|
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 25th May 2013 - 07:26 |