I use an -Mp3tag- »Export« to a Windows batch file to tackle this
problem. This allows me to set up whatever grouping I decide to be an
»album« in Mp3tag’s »$loop()« construct. (I had to add RG to my mixed
FLAC/OGG/MP3 collection a few months ago, about 25,000 titles.)

For things like this, I usually let Mp3tag create a »pseudo batch file«
which then gets handled by another batch process (conveniently located
as a link in my Quick Launch Bar).

The code isn’t (yet) really »fit for publishing« since it contains a
lot of hard-coded references to files and folders, but if anyone is
interested, here it is:


Code:
--------------------
    
  $filename('C:\Programme\Mp3tag\Process-Data.txt',utf-16)@ECHO OFF
  REM Remove old and calculate new Track (=Radio) and Album (=Audiophile) 
Replay Gain for all files marked.
  REM Uses Tycho''s "metamp3.exe" v0.92 beta 5, vorbisgain v0.34, metaflac 1.2.1
  REM Will only operate on .mp3 files with ID3v2.3 tags in ISO-8859-1 encoding! 
(No UTF support yet.)
  REM Will also operate on .ogg (Vorbis Type I) and .flac files.
  REM At least '%artist%, %title% and %album%' must be set for Album Gain to 
function correctly!
  $loop($if2(%albumartistsort%,%artist%) - $if2(%album%,'['unknown']'))
  ECHO.
  ECHO ALBUM: "$replace($if2(%albumartistsort%,%artist%) - 
$if2(%album%,'['unknown']'),'%','%%')"
  $loop($num(%track%,2) 
%title%.%_extension%)$puts(fm,$get(fm)$if($eql($lower(%_extension%),'mp3'), 
"$replace(%_path%,'%','%%')",))$puts(fo,$get(fo)$if($eql($lower(%_extension%),'ogg'),
 
"$replace(%_path%,'%','%%')",))$puts(ff,$get(ff)$if($eql($lower(%_extension%),'flac'),
 "$replace(%_path%,'%','%%')",))$loopend()$iflonger($get(fm),0,
  ECHO Calculating MP3 Replay Gain...
  "C:\Programme\Tools\metamp3.exe" --2 --remove TXXX'[replaygain_*]'$get(fm)
  "C:\Programme\Tools\metamp3.exe" --2 
--replay-gain$get(fm),)$puts(fm,)$iflonger($get(fo),0,
  ECHO Calculating OGG Vorbis Replay Gain...
  "C:\Programme\Tools\vorbisgain.exe" --quiet --clean$get(fo)
  "C:\Programme\Tools\vorbisgain.exe" --quiet 
--album$get(fo),)$puts(fo,)$iflonger($get(ff),0,
  ECHO Calculating FLAC Replay Gain...
  "C:\Programme\Tools\metaflac.exe" --remove-replay-gain$get(ff)
  "C:\Programme\Tools\metaflac.exe" --add-replay-gain$get(ff),)$puts(ff,)
  $loopend()
  
--------------------

This ought to be saved as »Batch - ReplayGain force new calculation
(Album+Track).mte« into the -%APPDATA%\Mp3tag\export- folder to be
accessible as a standard Mp3tag »export«.

You then select the albums (or all files) to be handled in Mp3tag,
right-click, and export to »Batch - ReplayGain forece new …«.

For Windows filenaming reasons, the resulting (UTF-16 encoded) text
file has to be »TYPEd« into the »real« batch file, and executed, which
I do thusly:


Code:
--------------------
    
  @echo off
  type Process-Data.txt > Process-Data.bat
  call Process-Data.bat
  del Process-Data.bat
  
--------------------

This goes into a file called »Process.bat« in my -C:\Programme\Mp3tag-
folder. (This one is linked to a button on the Quick Launch Bar, for
easy access.)

If using non-ANSI characters in file names, you might need to change
this to

Code:
--------------------
    
  @echo off
  cmd /u /c type Process-Data.txt > Process-Data.bat
  cmd /u /c Process-Data.bat
  del Process-Data.bat
  
--------------------

(The »/u« will use Unicode for interprocess communication.)

(The last one is untested—I only use ANSI in music filenames, for
compatibility reasons.)


-- 
Moonbase

Moonbase: 'The Problem Solver' (http://www.kaufen-ist-toll.de/moonbase)
------------------------------------------------------------------------
Moonbase's Profile: http://forums.slimdevices.com/member.php?userid=21594
View this thread: http://forums.slimdevices.com/showthread.php?t=57543

_______________________________________________
ripping mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/ripping

Reply via email to