![]() |
#321 |
Join Date: Sep 2003
Posts: 27,873
|
i'd assume shane uses the code he posted to get the selected playlist items so yes, it would be broken by the change. as is in the post i made at the start of the thread, it's simple to fix
-daz |
![]() |
![]() |
![]() |
#322 |
Feed me a stray dog
(Major Dude) Join Date: Oct 2004
Posts: 1,122
|
I read that & it's good to hear that it's simple to fix. I brought it to this thread b/c I noticed Shane hasn't posted in a while & wanted to show how I like activewinamp. Thanks for the info.
Best, |
![]() |
![]() |
![]() |
#323 |
Join Date: Sep 2003
Posts: 27,873
|
Since the activewinamp source is available in cvs then anyone could provide a patched version of the plugin. Yeah, there's been no posting in some time though i've noticed a certain name in the 'users browsing this forum' info...
-daz |
![]() |
![]() |
![]() |
#324 |
Major Dude
Join Date: Jan 2004
Location: Brisbane, Australia
Posts: 1,193
|
Yes I still come in and read the posts when I can. Though it takes a lot longer to reply than read, and I unfortuantly don't have time for support anymore. I have around 200 unanswered emails in my inbox, hundreds of things to do, and basically no time anymore to do it. Its quite depressing to think that if I were to try handle all of that, all my free time for the forseeable future would be consumed.
Nonetheless... I will try take a look at this stuff soon. I desperately need to get a new version of AW out, as the one in the CVS fixes a few things, though it too needs a few fixes. The method I used to get the selection seems to still work for now in the beta, but I will add support for the newer method for newer versions of Winamp. With these ATF changes I will need to update a few of my plugins anyway. |
![]() |
![]() |
![]() |
#325 |
Junior Member
Join Date: May 2005
Posts: 23
|
I wrote a script that will prompt for a year (inputbox) and change the mp3 tag (using id3co). Although the mp3 gets updated, the winamp ml keeps the previous year data.
I'm using a sendto: "for each track in x" and I've tried track.year=songyear, but I get an error. For the time being I'm running my script then using CTRL-E to update the ml. (I know you can update the mp3 tag with CTRL-E, but it's considerable slower - than even this method). I have about 3000 songs without the year data in them & it's tedious enough to find the year data. I guess I could remove it from the database & re-add (I keep all my playcount & rating info in the mp3 tag), but again that's a bit tedious. Is there anyway to update the ml from the file using a script? |
![]() |
![]() |
![]() |
#326 |
Junior Member
Join Date: May 2005
Posts: 23
|
Another question:
Is there a way to have a script run after a file has been played? This way I can update my mp3 tag with playcount & rating everytime an mp3 is played. |
![]() |
![]() |
![]() |
#327 |
Major Dude
Join Date: Jan 2004
Location: Brisbane, Australia
Posts: 1,193
|
As I explained in my email, the reason many fields are read only is because :
a. I havent got around to exposing them properly b. I wasnt sure these fields should be made writeable anyway - ie filesize and time etc shouldnt really be modified. The file itself should be, and then the ml told to re-read the info. As AW doesnt modify file tags, I wasnt sure about the ml and id3 tag getting out of sync. c. I would prefer to have the cached object modified, then issuing a 'update to ml' type function so that all the info would be updated in one update rather than one for each meta data item modified. Currently, meta data is updated into the ml as the property is modified, which Im not a massive fan of, but it does simplify programming. I have updated the cvs version to expose year, length and track in this way. I will do bitrate,filetime and filesize etc later. I may possibly use a flag in the media item to switch between on-demand ml updates or not for better performance when needed. There is a 'track change' event that you can hook for performing actions when a new song is played. |
![]() |
![]() |
![]() |
#328 |
Junior Member
Join Date: May 2005
Posts: 23
|
Script To Download Album Cover Art
Here's something I wrote yesterday. Not sure if it should get its own thread, but since it's a winamp script, I'll include it here.
You need to download AlbumArtAggregator, which you can get free online. I have the script download the file into the folder with the mp3, but have it named by the album cover. I added this to toaster "%dir%\\%album%.jpg;" because that way I can have multiple album covers in one directory. It should be fairly easy to substitute the location of AAA.exe or the name of the image file downloaded. Save it as sendto_AAA.vbs in your WA scripts folder. PHP Code:
|
![]() |
![]() |
![]() |
#329 |
Junior Member
Join Date: May 2005
Posts: 23
|
This script goes through every song in your playlist** and notes the artist. It then runs through & repopulates the playlist with the first song from each artist. Then it enqueues the second (if any) song from each artist, and so forth.
One application of this is if you want to listen to 10 or 20 different albums, but don't want to hear any song by the same artist twice in a row (until the very end). You may want to enqueue 20 albums from different artists & randomize it, because if not you'll hear every first song on the albums first, then all the second songs on each album, etc. Another use for this is if you make a playlist with a few random collections, but you don't want to hear the same artist twice in a row. ** (I used x = playlist.getselection(), because I don't know how to get the entire playlist). playlist_Dupe_Artist_Move PHP Code:
|
![]() |
![]() |
![]() |
#330 |
Junior Member
Join Date: May 2005
Posts: 23
|
Oh and if you want a script that will give you X number of albums, without repeating the same artist, use this script.
You'll want to edit this section, it should be relatively self explanatory. The genres are comma seperated, and each one will give you Genre Begins 'XXX'. Year will give me a year between today & 1977. PHP Code:
PHP Code:
|
![]() |
![]() |
![]() |
#331 |
Junior Member
Join Date: May 2005
Posts: 23
|
And for those that are too lazy to copy & paste...
|
![]() |
![]() |
![]() |
#332 |
Major Dude
Join Date: Jan 2004
Location: Brisbane, Australia
Posts: 1,193
|
Ive added those scripts to : http://www.myplugins.info/activewina.../examples:root
You and everyone else has access to add and edit entries on these pages. Note, to get every item in your playlist, just use the playlist object. ie. msgbox playlist(1).artist or for each song in playlist msgbox song.artist next |
![]() |
![]() |
![]() |
#333 |
Feed me a stray dog
(Major Dude) Join Date: Oct 2004
Posts: 1,122
|
Neat albums script. Thanks, MarquisEXB
/edit Excellent albums script. Last edited by Thunder Pussy; 19th February 2006 at 00:55. |
![]() |
![]() |
![]() |
#334 | |
Junior Member
Join Date: May 2005
Posts: 23
|
Quote:
Thanks for the code. |
|
![]() |
![]() |
![]() |
#335 |
Junior Member
Join Date: May 2005
Posts: 23
|
Question how would you know which is the next song, or the selected song in Winamp?
For example, I can randomize all the songs in the playlist, but I would like to put the currently playing or highlighted song as #1 in the playlist. How would I get this info from AW? |
![]() |
![]() |
![]() |
#336 |
Junior Member
Join Date: May 2005
Posts: 23
|
I'll answer my own question:
playlist.position ![]() |
![]() |
![]() |
![]() |
#337 |
Junior Member
Join Date: May 2005
Posts: 23
|
Added script to wiki: delete duplicately titled songs.
This script will delete any songs with the same title from your playlist. Good if you make a playlist from multiple queries, have lots of compilations/greatest hits, cover songs, or live albums & don't want to hear the same song in different version. http://www.myplugins.info/activewinamp/doku.php/examples ![]() Anyway it's on the wiki if the above link doesn't work. http://www.myplugins.info/activewina.../examples:root |
![]() |
![]() |
![]() |
#338 |
Junior Member
Join Date: Feb 2006
Posts: 36
|
ACTIVEWINAMP in WA 5.20 not working?
could anybody confirm that the basic ACTIVEWINAMP is not working anymore in 5.20? upgraded this morning, and noticed
a while later that while the scriting menue still appeared, none of the functions (sort/random/whatever) had any effect at all. i am a rather basic user, having just used the most easy setup to sort by track number and similar, so if there is a workaround or update, could somebody kindly put this in simple words and let me know? or just confirm it is over with for the time being? greetings - heinz - |
![]() |
![]() |
![]() |
#339 |
Junior Member
Join Date: May 2005
Posts: 23
|
The swapindex command seems to be broken. Not sure what else.
|
![]() |
![]() |
![]() |
#340 |
Junior Member
Join Date: May 2005
Posts: 23
|
Hmm this is odd. I can run my playlist randomizer on the entire playlist. However if I run it with just the selected items (the default script that comes with AW) it doesn't work.
|
![]() |
![]() |
![]() |
#341 |
Forum King, M.D.
|
@heinz
you can try downloading the latest version of AW. save the .dll file in dir\winamp\plugins. it should replace existing copy of gen_activewinamp.dll CVS @marquis... hey I've noticed youve been doing some scripts and i wonder if you take requests. Take the ratings from the songs in playlist, and add song x number of times to the playlist. (songs rated 5 will appear a total of 5 times in the playlist) This should help weigh the songs with shuffle on. |
![]() |
![]() |
![]() |
#342 | |
Junior Member
Join Date: May 2005
Posts: 23
|
Quote:
PHP Code:
|
|
![]() |
![]() |
![]() |
#343 | |
Junior Member
Join Date: May 2005
Posts: 23
|
Quote:
For example, highlight a few items in your playlist (not more than 5, unless you like hitting OK a lot), and run this script. PHP Code:
|
|
![]() |
![]() |
![]() |
#344 |
Forum King, M.D.
|
yeah, cool thanks a bunch. works as desired in 5.13
Ive confirmed activeWA doesnt work as you described as well in 5.2, and im positive ShaneH already knows its broke ![]() |
![]() |
![]() |
![]() |
#345 |
Junior Member
Join Date: Feb 2006
Posts: 36
|
well, tks to all that chimed in, consensus seems to be even latest versions (which i have) dont work, right? at least i dont have to stay up all night scratching my head ...
there might be workarounds, but i am not firm enough to use them (yet). so i will wait for an update. greetings - heinz - |
![]() |
![]() |
![]() |
#346 |
Major Dude
Join Date: Jan 2004
Location: Brisbane, Australia
Posts: 1,193
|
Yes, playlist.getselection() is probably broken in 5.2. Even if it isn't there is a better method in Winamp 5.2 which Ive added support for. The CVS has been updated.
Ticket: https://sourceforge.net/tracker/inde...65&atid=723332 |
![]() |
![]() |
![]() |
#347 |
Junior Member
Join Date: Feb 2006
Posts: 36
|
shaneh, pls bear with people who are not quite as 'fit' as you: what am i supposed to do now? download a new version (from where?) and install it over the old one?
greetings - heinz - |
![]() |
![]() |
![]() |
#348 |
Junior Member
Join Date: Feb 2005
Posts: 5
|
Hi, very nice plugin, but I have a problem when I try to create a instance of the playlist class in Visual Basic .NET 2005 express edition.
I've this piece of code: code: And this is the error: Retrieving the COM class factory for component with CLSID {5108E2F5-A7E8-4284-9555-9FA8C3994B9C} failed due to the following error: 80040154. But when I use this: code: I get this error: Object reference not set to an instance of an object. So i tried this: code: But then I get the error: Type 'winamp.Playlist.Item' is not defined. Does anybody know how to fix this? |
![]() |
![]() |
![]() |
#349 |
Major Dude
Join Date: Jan 2004
Location: Brisbane, Australia
Posts: 1,193
|
@heinz57g:
Use the 'latest cvs version download' link on: http://www.myplugins.info/activewina...p/activewinamp and just copy it over your old version in your winamp plugins directoy. Note it may break a couple scripts, in particular ones that use the media library queries, as this has changed a little in this version. Generally all it should require is adding a '?' to the start of the query in most cases. I will make a new interim release of ActiveWinamp pretty soon, seeing as it is broken for 5.2. I wanted to add a bunch more stuff before the next release but I think I will just push it out as a beta seeing as the one on the plugin page wouldnt work for a lot of people. |
![]() |
![]() |
![]() |
#350 |
Junior Member
Join Date: Feb 2006
Posts: 36
|
shaney, tks alot. this worked as far as SORT/RAND goes, my main worries. and once i get into those scripts a bit deeper (AFTER your real 5.2 update), i am sure, you'll hear from me. meantime many tks for a great job well done.
greetings - heinz - |
![]() |
![]() |
![]() |
#351 |
Junior Member
Join Date: Feb 2005
Posts: 5
|
Informations disappear after updating Media Library with "MediaLibrary.Insert"
Hi scripters,
I'm using a slightly modified version of the script to call Mp3Tag. All functions well but informations YEAR and BITRATE disappear and PLAYCOUNT is set to the maximum possible unsigned integer value 4294967295 :-) :-( Gerd Script follows: On Error Resume Next Const ForReading = 1, ForWriting = 2 Dim fso, WshShell, TmpPlaylist, SendTo_Items Dim TmpPlaylistPath, Mp3TagPath Set fso = CreateObject("Scripting.FileSystemObject") Set WshShell = CreateObject("WScript.Shell") '===== Get path where Mp3Tag is installed Mp3TagPath = RegistryRead( _ "HKCU\Software\Moebius\Install\Mp3tag", "InstDir") & _ "\Mp3tag.exe" '===== Get filename of temporary playlist TmpPlaylistPath = GetEnvString("%TEMP%") & _ "\temp_mp3tag_playlist.m3u" '===== Create tmp. playlist Set TmpPlaylist = fso.OpenTextFile(TmpPlaylistPath, _ ForWriting, True) '===== Get selected "Send To" items (either from '===== MediaLibrary or from playlist) SendTo_Items = GetSendToItems '===== Write selection to tmp. playlist TmpPlaylist.WriteLine ("#EXTM3U") For Each track In SendTo_Items TmpPlaylist.WriteLine (track.Filename) Next TmpPlaylist.Close '===== Run Mp3tag and wait until it is finished WshShell.Run """" & Mp3TagPath & """ ""/m3u:" & _ TmpPlaylistPath & """", 1, True '===== Update entries in Media Library --> Errors in ML For Each track In SendTo_Items set theItem = LoadItem(track.filename) MediaLibrary.Delete(theItem) MediaLibrary.Insert(theItem) next '=== Have also tried MediaLibrary.RefreshMeta here. '=== No difference. Quit |
![]() |
![]() |
![]() |
#352 |
Junior Member
Join Date: Feb 2005
Posts: 5
|
Aaaahhhh...
must use MediaLibrary.ADD (instead of INSERT). |
![]() |
![]() |
![]() |
#353 |
Major Dude
Join Date: Jan 2004
Location: Brisbane, Australia
Posts: 1,193
|
There isn't a MediaLibrary.Add function though??
Unfortuantly Winamp provides no means to just send a filename to the ML and have it read the info itself, you have to actually supply it. Which is what MediaLibrary::Insert attempts to do, but has some bugs. I can see why playcount might be munged if there is no playcount for an item and you try to insert it. Although bitrate shouldnt have the problem and should just not be set - I will look at fixing it sometime. When you run mp3tag, does it change the filenames? For Each track In SendTo_Items set theItem = LoadItem(track.filename) If the filename changed the above wont work. Otherwise, it should be ok. Last edited by shaneh; 11th March 2006 at 00:12. |
![]() |
![]() |
![]() |
#354 |
Junior Member
Join Date: Feb 2005
Posts: 5
|
Shaneh,
you are right... the "MediaLibrary.Add" is completely ignored by the interpreter (probably because of "ON ERROR RESUME NEXT" ?). I now simply change the properties of theItem -- that's enough! I havent't tried yet to INSERT a completely new entry (in case of changing filenames inside Mp3Tag) but will test it soon. Regards and thanks for this wonderful tool Gerd |
![]() |
![]() |
![]() |
#355 | ||
Forum Sot
(Major Dude) Join Date: Mar 2004
Location: Marietta, Ga. U.S.A.
Posts: 3,916
|
Re: Activewinamp questions
Quote:
Quote:
|
||
![]() |
![]() |
![]() |
#356 |
Junior Member
Join Date: Mar 2006
Posts: 1
|
Can I use ActiveWinamp from Delphi?
|
![]() |
![]() |
![]() |
#357 |
Junior Member
Join Date: Mar 2006
Posts: 3
|
nice plugin
just found this plugin, very nice!
whipped this up last night, will find and display nfos for all unique folders in selection, please excuse any bugs or bad code, very rusty on vb! code: oh and this quick one appends a cue file for the currently playing file at the end of the playlist (if u have a cue handler like ape cue it can then be expanded by playing it) code: is there a workaround for playlist.position because id like to be able to insert items immediately after the currently selection? thanks again! edit: sorry forgot to ask. i know u can create a fake playlist entry with "X:blah", are there any other playlist commands like this? |
![]() |
![]() |
![]() |
#358 | |
Feed me a stray dog
(Major Dude) Join Date: Oct 2004
Posts: 1,122
|
Re: nice plugin
Quote:
.insert(x(1).position) for .enqueue |
|
![]() |
![]() |
![]() |
#359 |
Junior Member
Join Date: Mar 2006
Posts: 3
|
yeah i tried that but position as a result of getselection() always returns 1236129 - is it just my system or is there a bug in getselection()?
|
![]() |
![]() |
![]() |
#360 | |
Junior Member
Join Date: Mar 2006
Posts: 3
|
whilst im in the mood, another quick one. displays all images in folders from selected items. little bug that if u have an item from folder1, then an item from folder2, then an item from folder1 again it will display folder1's images twice (as the view nfo script does) - have to shoot now so if u want to use it fix it yourself!
Quote:
filename display open full size image set image as folder.jpg search on web for new art some thoughts on activewinamp: do these scripts carry on running to recieve events? how can i exit a script? could do some real nice stuff with xmlhttprequest |
|
![]() |
![]() |
![]() |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|