Google Art Finder 2.7 [MM2+3]

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

Moderators: Peke, Gurus

trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Google Art Finder 2.7 [MM2+3]

Post by trixmoto »

This script has been discussed here.

In the script file you set the File Mask for where you store your images (saving in tags is currently no available, nor is adding to the library. A rescan should assign the images to the files in that folder though).

When playing a song that does not have art, run the script and the best match will be shown from Google. This image can then be saved to your harddrive.
Last edited by trixmoto on Tue Apr 03, 2007 4:08 am, edited 3 times in total.
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Post by trixmoto »

:o NEW CODE BELOW :o
Last edited by trixmoto on Tue Feb 14, 2006 7:00 am, edited 1 time in total.
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Post by trixmoto »

GoogleArtFinder2.vbs

Code: Select all

'
' MediaMonkey Script
'
' NAME: GoogleArtFinder 1.0
'
' AUTHOR: trixmoto (http://trix.dork.com)
' DATE : 02/02/2006
'
' INSTALL: Helper script for 'GoogleArtFinder.vbs'
'          Needs to be in '{MM}\Scripts\'
'

Set SDB = CreateObject("SongsDB.SDBApplication")
Set IE = SDB.Objects("ArtFinderShell")
Do While IE.ReadyState <> 4
  WScript.Sleep 500
Loop
Set IE = Nothing
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
Teknojnky
Posts: 5537
Joined: Tue Sep 06, 2005 11:01 pm
Contact:

Post by Teknojnky »

Been using this off and on and had a couple questions.

I've hardcoded the FileMask to FileMask = "J:\music\metadata\<artist>-<album>" and it puts it in the right folder but adds the "+" sign instead of spaces to the files name and uses the % escape codes for other characters.

"Carter%2C+The+Unstoppable+Sex+Machine-1992%3A+The+Love+Album.jpg"

I am wondering if there is an easy to way to normalize that without a bunch of parsing/search/replace.

Edit: I am guessing that the filename should be built from the library tags instead of the google query?


----

Can scripts be activated by toolbar icons and how would that be added?


----

I am assuming there must be some way to check if album art exists for the album in the library, because it can be done via the files to edit node and magic nodes... I am wondering the best way to automatically trigger this script if no album art exists in the library (not checking tag or filesystem).

A background helper script I assume?
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Post by trixmoto »

All these suggestions are useful, and I will try to include as many (if not all) of them in the next version.

Cheers! :)
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
Teknojnky
Posts: 5537
Joined: Tue Sep 06, 2005 11:01 pm
Contact:

Post by Teknojnky »

I figured out an awesome shortcut using this to tag files easier...

Activate the script, let the image load, drag the image (assuming its the correct one) to the album art window of MM.

A dialog should pop up (unless you got confirmations disabled) asking to store it tag or file, and to tag all files in the album.

You can also drag and drop images from your hardrive or other 'drag/droppable' sources like most web browsers and other windows programs.

As soon as the script can auto-run when no album art exists, it will be nearly perfect... there is no need to try to manually write tags...

In fact, with this newly realized ability it would probly be better if the script displayed the top 1-5 (user selectable) images and just drag/drop whichever is most correct.
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Post by trixmoto »

Sounds like a good plan. Should be releasing a new version tomorrow then. :)
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Post by trixmoto »

New version (1.1) has the bug with the filename fixed. It also has an automatic part which will show the screen for any track that is played which doesn't have any artwork. The screen can still be launched from the scripts menu.

As Teknojnky has pointed out, the best way to add the image found to the track is to drag the image directly to the artwork display window in MM.

:o NEW CODE BELOW :o
Last edited by trixmoto on Fri Feb 17, 2006 11:42 am, edited 1 time in total.
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
Teknojnky
Posts: 5537
Joined: Tue Sep 06, 2005 11:01 pm
Contact:

Post by Teknojnky »

Too freaking cool!!!

ImageImageImageImage
Teknojnky
Posts: 5537
Joined: Tue Sep 06, 2005 11:01 pm
Contact:

Post by Teknojnky »

Is there an easy way to get the window to persist size/position changes?

Sometimes I want it off to the side more, or larger/smaller etc..

I see I can set the height/width via:

Form.Common.SetRect 100, 100, 400, 300

But the first 2 numbers don't see to do anything?

There is also:

Form.FormPosition = 4

Which 1 thru 3 appear to be the same position, then 4 is more down/right, and 5 is far right and 6 is lower center.

I'll keep tweakin and see if I can figure out a good combo.
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Post by trixmoto »

Well the 100,100 is the x,y coordinates, but FormPosition=4 means centered so these values are overridden. I will create a new version which stores screen size/position in the .ini file. :)
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
Teknojnky
Posts: 5537
Joined: Tue Sep 06, 2005 11:01 pm
Contact:

Post by Teknojnky »

Super!

I checked the scripting help and the position 4 is centered as you noted, 0 is as specified by the other properties, 1 is windows defautl position, however none of the other numbers are noted.

Thanks again Trixmoto, this script saves a huge amount of time manually searching for album art!
jiri
Posts: 5417
Joined: Tue Aug 14, 2001 7:00 pm
Location: Czech Republic
Contact:

Post by jiri »

You can use

Code: Select all

Form.SavePositionName = "Some name here"
which ensures that window position and size is saved/restored the next use.

Jiri
trixmoto
Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK
Contact:

Post by trixmoto »

It's like a Two Ronnie's sketch. I open the form in position A, move it to position B, then close the form. I open the form and it's in position A, so I move it to position C and close the form. Now I open the form and it's in position B, so I move it to position D ............ it's always one step behind.

How does it know whether to GET or LET the position with this line?
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.
Teknojnky
Posts: 5537
Joined: Tue Sep 06, 2005 11:01 pm
Contact:

Post by Teknojnky »

This has been working superbly for me but there are 3 other minor quirks:

- If the image is unavailable, it shows the infamous red X.. it would be nifty if it autonavigated past images that cant be loaded (not sure how dead image would be detected tho) and went to the next image as the button does. (a previous image button could be convenient too)

- I am using an autoexec script, I have the option "SDB.Player.Play" so that MM will begin playing immediately upon start up... however, possibly because of timing/limitations within MM, the script fails to detect existing album art on startup and always runs on start up.

- An option/variable to autoclose a previously open window.. ie if the next track has album art, close the window then exit the script.


edit:
Oh I also changed the search url from 'newwindow=1' to 0 so that I can browse the other images within the goog art finder window instead of a new IE window and removed the 'medium' so that I get more image from less common artists/albums.
Post Reply