Track Redirection & Synchronization
- MediaMonkey Add-on - by Zvezdan Dimitrijević
This add-on works with MediaMonkey v3.0-4.x. If you like to store and play whole albums and if you have many albums with same songs (official studio, compilation, soundtrack, ...), especially if they are in some lossless format, then this add-on is right for you. Instead of having multiple large audio files with same song for every album, you could keep just one file for one album and on another albums you could have small .asx files (1-2 KB) as redirection files.
With this add-on you could create .asx files and use them instead of original audio files, you could play them and you could modify their metadata using Track Properties dialog box. Beside of the master audio file, the .asx file could also refers to its album cover bitmaps. There is also an option to update the playcount and the last played date of the master (referenced) file whenever you play some .asx file which refers to it. Many software and hardware players could reproduce audio files referenced by .asx files.
This add-on is mainly intended for "one song-many albums" situations, but it could be also used for any kind of redirections, for example if you want to store metadata for some file format which doesn't support tags. Version 1.2 has added an option to create redirections between two (or more) audio files instead of .asx files (e.g. master could be a .flac and redirected file a .mp3), for users who prefer to keep duplicates on disk. Version 2.0 has added an option to synchronize specified metadata between linked tracks and version 3.0 has added an option to copy tags from the one set of tracks to the another one even if they are not previously linked with redirections.
For a discussion about this add-on, you could visit its related MediaMonkey forum thread.
This add-on is donationware. It is developed by me in my own free time. I am not employed by Ventis Media, the company behind MediaMonkey, nor I've been paid by them for this add-on. So, if you found any of my add-ons useful and want to help their further development, it would be nice if you send me some small donation using PayPal. You could donate as much as you think that is appropriate, any amount would be really appreciated.
This add-on doesn't work with MediaMonkey v5! Actually, none add-on made for some previous version of program could work with MM5, either by me or by another authors, since MM5 has completely different programming interface than before. If you really like my add-on and think that it is essential for your work with the program, you have several possibilities:
- you could stay with MM4;
- you could ask MM developers to implement support for old add-ons in MM5;
- you could wait for me to port the add-on to MM5, but don't hold your breath.
Added: options to find master track in the Library/Location folder or in the current tracklist (Find Referenced Master sub-menu);
Added: possibility to specify the name of some nested playlist in the Options dialog box without its full path if that name is unique;
Fixed: remembering of Copy Audio Tracks and Transfer Playstats options in the Create Redirections for Specified Tracks dialog box;
Fixed: error when some HideMenu option is set to 1 in the .ini file.
v3.3.9 - 2012-06-28
Fixed: suggested redirection file in Create Redirections for Specified Tracks dialog box with some faulty databases and UNC paths;
Improved: speed of synchronization of album arts.
v3.3.8 - 2011-06-26
Fixed: references to cover arts if they are stored in tags of original audio files when creating .asx files;
Fixed: .asx files for tracks with double qoutes in tags causing some media players to refuse their reproduction;
Fixed: .asx files containing Comment/Lyrics with more then one line of text;
Fixed: error with non-numeric Track # and Disc # in Create Redirections for Specified Tracks dialog box;
Fixed: suggested redirection track in Create Redirections for Specified Tracks when Filtered is unchecked and none filter is applied;
Fixed: remembering of Filtered option in Create Redirections for Specified Tracks dialog box.
v3.3.7 - 2011-06-10
Fixed: AV error when turning on the Update playlist option in the Options dialog (and probably in some another occasions) [MM4].
v3.3.6 - 2011-06-03
Fixed: error with Add/Rescan .asx Files to the Library option [MM4].
v3.3.5 - 2011-04-03
Fixed: removing of tracks from playlists with "Remove Duplicates / Linked Tracks from the Tracklist / Keep Only Linked Tracks in the Tracklist" options when some playlist node is selected.
v3.3.4 - 2011-01-17
Fixed: specifying playlist used for updating when add/remove redirections other then "Redirected Tracks".
v3.3.3 - 2011-01-15
Fixed: suggested redirection file in Create Redirections for Specified Tracks dialog box in some cases;
Fixed: some bugs introduced with MediaMonkey 4.0, e.g. LastPlayed not updated for the master track when the redirected one finishes with reproduction.
v3.3.2 - 2010-03-21
Changed: the list of playlists in the Options dialog box is now limited to playlists on the first level because the large number of nested playlists have slowed down its display; if you need to specify some nested playlist, you could still write it using "\" as a separator between nested levels.
v3.3.1 - 2009-10-03
Fixed: error when checking tracks in the Maintain Redirections dialog box after opened Create Redirections dialog (bug introduced in v3.2).
Just double click on the TrackRedirection-xx.mmip file; if you are on Vista or Win7 and you got "Product installation error", make sure you have MM3 set to "Run as Administrator"; if you downloaded the installation package with IE7 and it changed its extension to a .zip, you should first change it back to a .mmip.
When you choose the Track Redirection from the context or the Tools menu, you have several options available:
Find Referenced Master Track
You could choose this option if you want to find the master track referenced by the selected .asx or audio file in: 1) the Library/Album folder, 2) the Library/Location folder or 3) the current tracklist.
Find Duplicate Titles and Select Max. Bitrate/Ext. (MM 188.8.131.528 or up required)
When you choose this option, the Library/Files To Edit/Duplicate Tracks node will be activated and tracks with maximal bitrate will be selected in the main tracklist since in most cases you want such tracks to keep as masters; alternatively, you could choose extensions which you prefer to keep as masters. This option could be used before creating of redirections for all duplicates in the library. However, this option could return tracks which you don't want to keep as masters, so it could be better if you create one playlist with masters and their duplicates which you want to replace and choose the next option. In both cases you should check the result of selection and manually adjust selected tracks with Ctrl+click, since sometimes you could want to replace tracks with higher bitrate or maybe you want to keep some specific version of track.
Select Duplicates Using Specified Criteria (MM 184.108.40.2068 or up required)
This option selects tracks from the current tracklist/NP list using a criteria specified in the Options dialog box (it could be a maximal Bitrate or a list of extensions); you could use this option before creating of redirection for some duplicates.
Select Linked Tracks - Master/Redirected/All Linked (MM 220.127.116.118 or up required)
You could use those options if you want to select only masters, redirected tracks or both masters and redirected tracks.
Select Unsynchronized Master Tracks (MM 18.104.22.1688 or up required)
This option selects master tracks with metadata different from redirected ones.
Remove Duplicates from the Tracklist/Now Playing List (MM 22.214.171.1248 or up required)
You could choose this option if you want to remove all duplicate tracks from the main tracklist or Now Playing list, i.e. tracks with same Artist and Title, leaving only duplicates with maximal bitrate or master tracks which are already referenced.
Remove Linked Tracks from the Tracklist/Now Playing List - Master/Redirected/All Linked (MM 126.96.36.1998 or up required)
You could use those options if you want to remove masters, redirected tracks or both masters and redirected tracks from the main tracklist or Now Playing list.
Keep Only Linked Tracks in the Tracklist/Now Playing List - Master/Redirected/All Linked (MM 188.8.131.528 or up required)
Those options are complement to previous. You could use those options if you want to keep only masters, redirected tracks or both masters and redirected tracks in the main tracklist or Now Playing list - other tracks would be removed.
Replace with Duplicate from Album (MM 184.108.40.2068 or up required)
If you choose this option you would get sub-menu with a list of all tracks with same Artist and Title as the currently selected one. After you select some of those tracks, it will replace the track selected in the main tracklist/Now Playing list.
Replace with Linked Track (MM 220.127.116.118 or up required)
If you choose this option you would get sub-menu with a list of all tracks linked to the currently selected one (master or redirected). After you select some of those tracks, it will replace the track selected in the main tracklist/Now Playing list.
Create Redirections for Specified Tracks
This is the most important step which you should take when you want to replace your duplicated audio files with .asx files or to create links between two audio tracks. First, you should select track(s) which you want to keep as masters and after you choose this option you will get the new dialog box. In this dialog you should specify what you want to do with duplicates: to replace them with .asx files or to keep them and just to create links to master tracks. If you choose the Tracks from specified Album option you should specify some existing album which contains same tracks as selected ones; if you choose the Unselected tracks in tracklist option, the add-on will create redirections for all unselected tracks that have same Artist and Title as selected ones (it could be for all duplicates in the library); this add-on in both cases automatically determine which tracks should be redirected considering their Artist and Title. Audio track(s) replaced with .asx file(s) could be deleted from the disk if you choose the Delete audio file(s) option in case that you choose the option Replace with .asx metafile). If you choose the Create redirection link option instead, you could turn on/off the Copy master (selected) track to the Album folder if it doesn't contain duplicate file option.
Create Redirections/Copy Metadata for Duplicates/Folders (MM 18.104.22.1688 or up required)
You could use this option to create redirections instead of the previous one. As with the previous option, you should first select master tracks and after choosing this option you will get a new dialog box with the table of all possible redirections. If you select Duplicates option you would get the list of all duplicates of selected tracks which have same Artist and Title if they are not already redirected. If you select Folders option you could specify [i]Master[/i] folder (e.g. Z:\My Music\) where you have stored master tracks (e.g. Artist\Album\Song.flac) and you could specify [i]Copy[/i] folder (e.g. Z:\My Music Compressed\) where you have stored linked tracks (e.g. Artist\Album\Song.mp3) and add-on would create redirections for all tracks which have similar path/filename. Check boxes next to the each redirection allow specifying which redirections you actually want to create. There are also options to choose if you want to replace duplicates with .asx files or to keep them and just to create links to master tracks. This dialog box is more descriptive and somewhat easier to use then the previous one, but it is also less flexible.
Add/Rescan .asx Files to the Library
Scan for existing .asx files and add or update them in the library, similar as the built-in Add/Rescan Tracks to the Library option, but for .asx files (only one folder with its child folders could be specified).
Synchronize Metadata of .asx Files
Update metadata of selected .asx files to match the library, similar as the built-in Synchronize Tags option, but for .asx files (it could be useful if you have turned off the Update tags when editing properties option).
Synchronize References in .asx Files
Update paths for tracks referenced in .asx files to match the library; it could be applied for selected tracks or for all .asx files in the library and could be used after changing of the Save references with relative paths option.
Edit .asx File with Notepad
Well, you could use the Track Properties dialog box to modify metadata for specified .asx file(s), but you could choose this option instead if you want to change some property which cannot be modified within Properties dialog box, e.g. a bitrate or track length, although it is not so much useful.
Assign Redirection to the .asx Files
You could use this option if you have audio file in the Library that you want to replace with corresponding .asx file which is already created before (the Path information would be changed).
Remove Redirection from the Track
This option is opposite to the previous, i.e. if you still have original audio file which is replaced by corresponding .asx file (but not deleted) and if it is still in the same folder with the same filename, then you could choose this option if you have changed your mind and want to return back that file to the Library (the Path information would be changed).
Transfer Redirected Playstats to Master Tracks
You could use this command if you want to transfer play counts and play dates manually from redirected tracks (selected or all) to the masters. If you want those data to be updated automatically whenever you play some redirected .asx or audio file, you should turn on the Update playcount & play dates for master track on playback option in the Options dialog box. This command would be disabled if you choose the Placount/lastdate option for synchronization in the Options dialog box.
Synchronize Metadata of Redirected Tracks
You could use this option if you want to synchronize tags manually, i.e. to update metadata of linked tracks to match the selected ones or to update all redirected tracks to match their corresponding masters. If you want those data to be updated automatically whenever you modify some linked track, you should turn on the Automatically synchronize metadata option in the Options dialog box.
Maintain Redirections (MM 22.214.171.1248 or up required)
When you choose this option you will get a new dialog box with a table of all redirections. Check boxes next to the each redirection allow specifying which redirections you want to remove. However, this dialog box could be used to see which tracks are redirected, even if you don't want to remove any redirection.
When you choose the Options option from the context or Tools menu, you will get a new dialog box with following options:
Save .asx files in ANSI / UTF-8 format
You could choose a format for .asx files, depending of the player support and used character code page for tags.
Save references with absolute / relative paths
You could choose if you want to save .asx files will references to master tracks using absolute or relative paths. Absolute paths are supported with all players, but relative paths could be used even after copying to another drive. You need MediaMonkey 126.96.36.1995 or up if you want to play .asx files with relative paths, but they are recommended if you want to copy tracks to some portable player or external drive. If you change your mind, you could convert relative paths in .asx files to the absolute paths or vice versa using the Synchronize .asx References option.
Update (specified) playlist when add/remove redirection
This option allows you to have one static playlist with redirected tracks automatically updated whenever you add or remove some redirection; such playlist could be used to create an auto-playlist without redireceted ones, i.e. without duplicates, using criteria Playlist is not specified_playlist.
Update playcount & play dates for master track on playback of redirected .asx/audio file
This option is very valuable if you want to have single playstats for same tracks, without a regard on which album they reside (official, compilation, ...); if you turn on this option, the playcount and play dates of the master (referenced) tracks will be updated whenever you play some .asx or audio file that redirects to them. This option is mutually exclusive with the option for synchronization of playcount/lastdate.
Synchronize metadata for all linked tracks
This option should be turned on if you want to synchronize any linked tracks whichever track you select or choose to modify. For example, if you change the Title in one track, all linked track would be updated with same Title.
Synchronize metadata of redirected to match masters only
Similar as previous, but synchronization is done only if you change some master track; if you change some redirected track, other tracks linked to it will be keept unchanged.
You could specify which tags should be updated during synchronization: Title, Artist, Album, ... Specified metadata could be synchronized automatically (if you turn on the next option) when some track is changed e.g. using Properties dialog box or manually using the Synchronize Metadata of Redirected Tracks command. The option Playcount/lastdate is mutually exclusive with the option Update playcount & play dates for master track on playback.
Automatically synchronize metadata on modification of linked/master track
You should turn on this option if you want metadata to be updated automatically whenever you modify some linked track (master or both master and redirected, depending on the previous Synchronize metadata options) e.g. using Properties dialog box.
Select Duplicates' main criteria: Maximal bitrate / Extensions (MM 188.8.131.528 or up required)
You could choose which criteria should have a priority when selecting tracks using the Select Duplicates Using Specified Criteria command. It could be a maximal Bitrate or a list of extensions separated with the vertical line "|", e.g. if you specify mp4|ogg, such files would be selected even if you have .mp3's with a larger bitrate.
Replace redirected audio file with corresponding master on playback or drag & drop to NP (MM 184.108.40.2068 or up required)
If you turn on this option, redirected audio files will be replaced in the Now Playing panel with corresponding masters whenever you start playback or drag & drop them to the Now Playing panel. This option has an effect only on linked audio files, not on .asx files (when you start "playing" of some .asx file, MM will play master track anyway).
select tracks which you want to synchronize (if you click on the left topmost check box you would select all contained tracks);
click on the Synchronize button if you want to copy tags or Transfer ps. if you want to transfer play counts and play dates.
If you want to copy tags using this method, you should specify which of them you want to copy in Tools \ Track Redirection \ Options dialog box before you apply the suggested steps.
The requirements to copy metadata are that both sets of tracks (old and new) should be previously entered into the Library (e.g. using Add/Rescan Tracks to the Library option) and both sets of tracks should have exactly same file names, e.g. "03 - blah blah.flac" and "03 - blah blah.mp3".
You could synchronize more than one album at once as long as you have the same folder structure with the old and new files, e.g. for the old files:
c:\My Music\Lossless\Rock\Pink Floyd\The Dark Side of the Moon\xxx.flac
c:\My Music\Lossless\Rock\Pink Floyd\Wish You Were Here\xxx.flac
and the new files:
d:\My Music\Compressed\Rock\Pink Floyd\The Dark Side of the Moon\xxx.mp3
d:\My Music\Compressed\Rock\Pink Floyd\Wish You Were Here\xxx.mp3
you should specify: Master folder: c:\My Music\Lossless\ Copy folder: d:\My Music\Compressed\
drastically reduced space for duplicated files; instead of 10-100 MB for some audio file you could have just 1-2 KB with .asx file;
every .asx file could contain their own metadata (track number, album name, ...) taken from the audio file that it replaces; those metadata are different from metadata of the master (referenced) track which is on another album;
play stats could be updated for referenced tracks whenever you play some .asx file;
.asx files could be played with many software and hardware players without a regard on used OS or its file system.
List of tested software players that support .asx files:
direct playback of .asx files in MediaMonkey using this add-on is possible only with MM v3.1 or up;
.asx files could be played with older MediaMonkey versions if you choose Winamp player in the Options dialog box, but in such case the playcount and play dates are not updated after reproduction;
.asx files cannot contain bitmap files for covers inside of them; if you want to replace some audio file which contains covers stored in tags, when you choose the Create .asx Files(s) option, those covers would be saved in the same folder as .asx file and will be referenced to it;
although MM from 220.127.116.110 has a possibility to add .asx fies to the Library using the Add/Rescan Tracks to the Library option, this option doesn't create redirection links between tracks; you should use the Add/Rescan .asx Files to the Library option instead;
the Synchronize Tags option doesn't work with .asx files; you should use the Synchronize .asx Metadata option instead;
if you update track info using Add/Rescan .asx files to the Library or Edit .asx File with Notepad, the cover art is not automatically updated in the Album Art panel; however, you could switch to the another track or node and return back to the same track to see changes;
reference paths inside of the .asx files cannot be automatically updated if you copy masters tracks and/or .asx files themselves (however, if you rename or move tracks, the paths will be updated automatically); because of that it is recommended to turn on the Save references with relative paths option and to update all .asx files to relative paths using the Synchronize .asx References option before copyng to some portable player; you could resume the previous action and convert paths to absolute form after you have copied files by turning off the Save references with relative paths option and updating .asx files using the Synchronize .asx References option again.
This add-on could be very dangerous! If you choose the "Delete audio files from the specified album" option in the Create .asx File(s) dialog box, all files with the same album and title names as selected file(s) will be removed! Well, the main purpose of this add-on is to replace some large audio files with much smaller redirectional files, so you should be aware of such behavior. However, it is highly recommended to turn off the mentioned option, at least until you get comfortable using this add-on. Also, playing stats of referenced files and ones which refers to them could be messed up if something goes wrong. Because of that it would be the best if you try this add-on with some small test database and backup copies of audio files.
This software is provided 'as-is', without any express or implied warranty. In no event will the author be held liable for any damages arising from the use of this software.
This add-on is a false positive reported as a worm by F-Secure. The author of F-Secure promised me that will update its database and put the add-on on white-list, but still didn't. If you go to the www.virustotal.com/en/ site, you will see that it is safe tested by 54 popular anti-virus engines; the only one reporting a worm in it is F-Secure.