Track Redirection & Synchronization 3.4 (2012-10-08) [MM3+]

Download and get help for different MediaMonkey for Windows 4 Addons.

Moderators: Peke, Gurus

benzo8
Posts: 47
Joined: Tue Feb 19, 2008 4:31 am

Re: Track Redirection & Synchronization 3.1.1 (2009-08-23) [MM3]

Post by benzo8 »

ZvezdanD wrote:
benzo8 wrote:I can't quite see why this should be the case for bitrate or track volume. Surely the data that MediaMonkey needs to refer to is that of the file that actually gets played, not of the file that's been deleted?
No, the main purpose of this script was at begin to replace some audio file with much smaller redirecting file which should have same metadata as replaced file. If this small file has same metadata as master track then you would lose its main advantage, so you could use simple .m3u or .pls files instead. If I have two same tracks from two different albums, I want to see different metadata for those two tracks, e.g. metadata of official album and metadata of compilation album. If I put metadata of master tracks into .asx files, then I would lose information about compilation (album name, release year, publisher...).
TR&S basically lets us use the same file in multiple places, but saves space by replacing all but one instance of that file with a smaller reference file. If you were to just make a copy of the Master file and move it, and edit the Metadata to reflect it's new position, what would change and what would stay the same?

I think there are two types of metadata that need to be considered:

1. Textual (and other) data describing the replaced track: Artist, AlbumName, AlbumArtist, Year, ArtWork, etc. In the .asx, these should come from the Replaced track. In the "actual file" situation above, these are things that should change. The album is different, the year of release, etc.

2. Technical data utilised by MediaMonkey to play the track: BitRate, FileLength, SampleRate, TrackVolume, etc. In the .asx, these should come from the Master track. In the "actual file" situation above, these things remain the same - the file itself hasn't changed. This data should be consistent, in the eyes of MM, with the file that actually gets played once the .asx is chosen.
ZvezdanD wrote:Your description seem to be very reasonable and maybe I could make an exception with the track volume, but what about the album volume? If the replaced track had 2.1 dB, when I change the track volume of .asx file to -4.2 dB the album volume of all tracks from that album should change as well. So, I need to calculate that new album volume and to put it into all tracks from that album. This is something that I don't like to do.
AlbumVolume is (the only instance that I can see of) a 3rd type of data - it's technical data for MediaMonkey, but you don't actually have it, either in the Reference Track, or in the Master Track. In terms of our the "actual file" situation above you would need to recalculate the AlbumGain, so I guess that for your .asx's, technically, the correct thing to do would be to do just that... I can see that that would be a pain for you, but it would be the most comprehensive, professional approach. Is there not a way of hooking into the MediaMonkey methods to just say "Here, I've given you a new file - calculate its gain please?"
ZvezdanD wrote:One more thing, what if some user change mind and decide to apply Remove Redirection from the Track option? The .asx file would be replaced with the originally replaced audio file which have 2.1 dB in your case, but database contains information of -4.2 dB about it taken from master file. So, if the user decide to apply the mentioned option I need to extract the original track volume from the audio file somehow and to put it back into database which is another thing that I don't like.
Again, while I can see it's a lot of work for you, the correct thing to do would be to recalculate the gains again - after all, you're adding a new file to the database (despite it replacing an old one "identically") and it has data that needs to be correct.
benzo8
Posts: 47
Joined: Tue Feb 19, 2008 4:31 am

Re: Track Redirection & Synchronization 3.1.1 (2009-08-23) [MM3]

Post by benzo8 »

ZvezdanD wrote:Actually, I already though to add such option, but it would complicate things with the table of possible redirections, especially if some song has three or more duplicates. For example:
Master -> Redirected
Track1 -> Track2
Track1 -> Track3
Track1 -> Track4

So, if I swap Track1 with Track2, the Track2 would be set as master and I would get one inconsistency where same Track1 is redirected (Track2 -> Track1) and master (Track1 -> Tarck3, Track1 -> Track4).
I hadn't considered this situation; you're right, it complicates things, but it's not insurmountable.

You could make it so that the swap only affected pairs which had the check box ticked, and that updates were reflected in the table, so:

[x] Track1 -> Track2
[ ] Track1 -> Track3
[ ] Track1 -> Track4

[SWAP] becomes...

[ ] Track2 -> Track1
[ ] Track2 -> Track3
[ ] Track2 -> Track4

From here, the user can continue to move things around by checking other boxes and hitting [SWAP], or they can just go ahead now and do the Redirections...
ZvezdanD
Posts: 3265
Joined: Thu Jun 08, 2006 7:40 pm

Re: Track Redirection & Synchronization 3.1.1 (2009-08-23) [MM3]

Post by ZvezdanD »

benzo8 wrote:If you were to just make a copy of the Master file and move it, and edit the Metadata to reflect it's new position, what would change and what would stay the same?
Sorry, but I am not sure that understand your question. You don't need to create duplicates by simple copying of master tracks. For example, you could get two duplicates ripping same track from same album using two encoders, e.g. one rip could be 192 KB MP3 or even better xxx KB FLAC for desktop usage and the second rip could be 80 KB AAC for mobile phones. If you take a look at several previous posts of this thread you would see that there are some (many?) users of this script which actually do exactly such thing.
benzo8 wrote:This data should be consistent, in the eyes of MM, with the file that actually gets played once the .asx is chosen.
What if user choose the Create Redirections > Create links between audio files option and has turned on the Replace redirected audio file with corresponding master on playback or drag & drop to NP option in the Options dialog box? For example, user could have one 192 KB MP3 track as master and 80 KB AAC file as redirected one - if s/he press the Play button after selecting AAC file, the program would play MP3 file instead. Should I change bitrate, sample rate, file length and other metadata that you suggested for AAC files as well to be consistent with the MP3 file which is actually played?
benzo8 wrote:AlbumVolume is (the only instance that I can see of) a 3rd type of data - it's technical data for MediaMonkey, but you don't actually have it, either in the Reference Track, or in the Master Track.
Actually, the Album volume is not only the technical data for MediaMonkey, it is written as TXXX:replaygain_album_gain tag in MP3 files, REPLAYGAIN_ALBUM_GAIN in OGG files, ... Every player which has a support for that value could use it. That value is actually contained in both master tracks as well as redirected ones.
benzo8 wrote:Is there not a way of hooking into the MediaMonkey methods to just say "Here, I've given you a new file - calculate its gain please?"
Yes, the script could ask MM to return Album volume for some track, but it cannot ask MM to return real album volume for all affected tracks. Here is one example. Let say that I have one compilation album which have 10 tracks with same song length and same track volume e.g. -3.0 dB. Obviously, all tracks from that album would have -3.0 dB album volume. Now, let say that I want to replace one of those tracks with .asx file which references some master track that has +6.0 dB track volume. Considering that master track has same song length as replaced one, the new album volume for .asx file should be (-3.0 * 9 + 6.0 * 1) / 10. But as I said in the previous post, it is not enough to write that value only to the .asx file - it should be written to all tracks from that album. This is all possible, but it is something that I really don't like to do.
benzo8 wrote:Again, while I can see it's a lot of work for you, the correct thing to do would be to recalculate the gains again - after all, you're adding a new file to the database (despite it replacing an old one "identically") and it has data that needs to be correct.
Actually, I am not adding a new file to the database, but I am replacing it. This means that it would have same song ID, same metadata, same play history, same playlists... The only information which is changed is the Path, more precisely its extension. Well, actually I am changing storage for Album Arts as well, but this is because .asx files cannot contain bitmaps inside of them.
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4.1  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.3  Add Currently Playing/Selected Track(s) to Playlist 1.2
ZvezdanD
Posts: 3265
Joined: Thu Jun 08, 2006 7:40 pm

Re: Track Redirection & Synchronization 3.1.1 (2009-08-23) [MM3]

Post by ZvezdanD »

benzo8 wrote:[x] Track1 -> Track2
[ ] Track1 -> Track3
[ ] Track1 -> Track4

[SWAP] becomes...

[ ] Track2 -> Track1
[ ] Track2 -> Track3
[ ] Track2 -> Track4
Yeah, I though about the same thing, but I am not sure if this is all that should be considered. For example, what if Track1 is already entered into table of redirections as master? I need to check that too and who knows what else more. Anyway, I will see what could be done...
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4.1  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.3  Add Currently Playing/Selected Track(s) to Playlist 1.2
ZvezdanD
Posts: 3265
Joined: Thu Jun 08, 2006 7:40 pm

Re: Track Redirection & Synchronization 3.1.1 (2009-08-23) [MM3]

Post by ZvezdanD »

benzo8 wrote:You could make it so that the swap only affected pairs which had the check box ticked, and that updates were reflected in the table
There is a new update which has added such option: v3.2 - 2009-08-26
- Added: Swap button to the Create Redirections/Copy Metadata dialog box which could swap selected masters with redirecting tracks;
- Added: possibility to use the Replace with Duplicate and Replace with Linked Tracks options with multiple selected tracks;
- Fixed: Create Redirections > Folders option.

By the way, I just tried to change manually Track Volume of some .asx file with several different values and MM played master track with same volume every time. I suppose it is using replaygain value stored in the master file, not value which is in database for .asx file. So, I think you are wrongly noticed some kind of distortion, maybe it is a placebo effect. ;)
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4.1  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.3  Add Currently Playing/Selected Track(s) to Playlist 1.2
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Track Redirection & Synchronization 3.2 (2009-08-26) [MM3]

Post by nynaevelan »

Z:

I am having trouble in the Select Sync section of Maintain Redirections. I completely syncronized all the tracks prior to adding new tracks to my library and then I added new tracks and ran the Select Sync option to catch the new tracks but every track within my library is showing up. Although I had not done anything to the library in between adding the new tracks. How are the unsyncronized tracks selected??

Nyn
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
ZvezdanD
Posts: 3265
Joined: Thu Jun 08, 2006 7:40 pm

Re: Track Redirection & Synchronization 3.2 (2009-08-26) [MM3]

Post by ZvezdanD »

nynaevelan wrote:How are the unsyncronized tracks selected??
I don't understand. The option is called Select unsync, not Select sync. When you click on that button you should get selected track pairs which have unsynchronized metadata. If you wanted to ask "how are the synchronized track selected", the only possibility which comes to my mind is that you have synchronized tracks with some uchecked option for metadata in the Option dialog box and in the meantime you checked the same option. For example, maybe you had unchecked Album, did synchronization and now have checked Album. What you get in the panel on the bottom of dialog box when you click on some row which has ticked check box? It should display metadata which are different between master and redirected track.
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4.1  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.3  Add Currently Playing/Selected Track(s) to Playlist 1.2
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Track Redirection & Synchronization 3.2 (2009-08-26) [MM3]

Post by nynaevelan »

Sorry I didn't realize that it would go through and check all the ones that need it.
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Track Redirection & Synchronization 3.2 (2009-08-26) [MM3]

Post by nynaevelan »

Z:

Is there a way to add a menu item for the Select Unsync option rather than going to Maintain Redirections -- Select Unsync? I ask because of my portable player I have the auto sync option turned off. Also, is there a way to add an option sheet selection to create redirections to always link to audio files instead of creating asx files? I ask for this because I always run into problems if I forget to select the option then I have to go back and remove the asx/art files and start over.
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
ZvezdanD
Posts: 3265
Joined: Thu Jun 08, 2006 7:40 pm

Re: Track Redirection & Synchronization 3.2 (2009-08-26) [MM3]

Post by ZvezdanD »

nynaevelan wrote:Is there a way to add a menu item for the Select Unsync option rather than going to Maintain Redirections -- Select Unsync? I ask because of my portable player I have the auto sync option turned off.
What should I select? In the Maintain Redirections dialog box there are redirection pairs of tracks, some master track could have linked two or more redirected tracks and each of those redirection pairs could be un/selected independently. Maybe I could select a master track if any of redirected tracks linked to it is out of sync?
nynaevelan wrote:Also, is there a way to add an option sheet selection to create redirections to always link to audio files instead of creating asx files?
The Create links between audio files option would be remembered if you click on the Create button, next time when you open the Create Redirections dialog box it should be selected automatically. Maybe you have some of problematic scripts mentioned before and your program crushed not allowing the program to write to the .ini file. ;) You could check that in the MediaMonkey.ini file, in the [TracksRedirection] section the AudioFileRedirect option should be = 1 after you click on the Create button.
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4.1  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.3  Add Currently Playing/Selected Track(s) to Playlist 1.2
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Track Redirection & Synchronization 3.2 (2009-08-26) [MM3]

Post by nynaevelan »

ZvezdanD wrote:
nynaevelan wrote:Is there a way to add a menu item for the Select Unsync option rather than going to Maintain Redirections -- Select Unsync? I ask because of my portable player I have the auto sync option turned off.
What should I select? In the Maintain Redirections dialog box there are redirection pairs of tracks, some master track could have linked two or more redirected tracks and each of those redirection pairs could be un/selected independently. Maybe I could select a master track if any of redirected tracks linked to it is out of sync?
Yes that will work.
ZvezdanD wrote:
nynaevelan wrote:Also, is there a way to add an option sheet selection to create redirections to always link to audio files instead of creating asx files?
The Create links between audio files option would be remembered if you click on the Create button, next time when you open the Create Redirections dialog box it should be selected automatically. Maybe you have some of problematic scripts mentioned before and your program crushed not allowing the program to write to the .ini file. ;) You could check that in the MediaMonkey.ini file, in the [TracksRedirection] section the AudioFileRedirect option should be = 1 after you click on the Create button.
Yes I do have instances where MM is crashing, not sure if it is MM or script related, and there have been a few times when I restored from a backup, but whichever it is it always happens to me after I've run a list that has a couple hundred tracks in it. Which leads me to sit there cursing myself out for forgetting to check it. :lol: :lol:
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
ZvezdanD
Posts: 3265
Joined: Thu Jun 08, 2006 7:40 pm

Re: Track Redirection & Synchronization 3.3 (2009-09-14) [MM3]

Post by ZvezdanD »

There is a new update: v3.3 - 2009-09-14
- Added: Select Unsynchronized Master Tracks option.
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4.1  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.3  Add Currently Playing/Selected Track(s) to Playlist 1.2
nynaevelan
Posts: 5559
Joined: Wed Feb 07, 2007 11:07 pm
Location: New Jersey, USA
Contact:

Re: Track Redirection & Synchronization 3.3 (2009-09-14) [MM3]

Post by nynaevelan »

ZvezdanD wrote:There is a new update: v3.3 - 2009-09-14
- Added: Select Unsynchronized Master Tracks option.
Thank you, it worked perfectly and quickly. :D :D Is it my imagingation or does this way work faster than when you select the Maintain Redirections Option??

Nyn
3.2x - Win7 Ultimate (Zen Touch 2 16 GB/Zen 8GB)
Link to Favorite Scripts/Skins

Join Dropbox, the online site to share your files
ZvezdanD
Posts: 3265
Joined: Thu Jun 08, 2006 7:40 pm

Re: Track Redirection & Synchronization 3.3 (2009-09-14) [MM3]

Post by ZvezdanD »

nynaevelan wrote:Is it my imagingation or does this way work faster than when you select the Maintain Redirections Option??
I am not sure. It is using another algorithm based on SQL, so probably you are right.
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4.1  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.3  Add Currently Playing/Selected Track(s) to Playlist 1.2
kitkat
Posts: 26
Joined: Mon Dec 05, 2005 11:10 pm

Re: Track Redirection & Synchronization 3.3 (2009-09-14) [MM3]

Post by kitkat »

Hi ZvezdanD--thanks for this script. I'm still getting used to it, and may have some questions about it at some point, but at the moment, I'd like to point out an error I'm getting.

When I go to "Maintain Redirections" and start using the checkboxes (so I can remove some of the redirections I overhastily added), each time I click a checkbox I get an error message pop-up (with "OK" as its only option). It says "Error executing script event." Thought you might want to know.
Post Reply