Jump to content

Pull rating from ID3 (specifically the WMP written one)


Recommended Posts

Windows Media Player has an option in it that will allow you to save your ratings IN the MP3 files (does it as a ID3 tag from what I can make out)

Anyone know how to extract this information from the MP3 file with AutoIT?

Yes, I know about the ID3 UDF but I've already posted there and tried a number of things that should have worked but to no avail.

I d/l'ed a couple of ID3 tag editors and they seem to be able to pull the info. I want to write my own library manager as WMP is choking on my collection of over 20,000 files.

TIA

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

According to a quick test I just did, Windows Media Player does not store the data in the MP3 itself. The Date Modified on the test file did not change after changing the rating, which I think means that WMP is storing it in it's own database.

I'm curious, which ID3 tag editors did you try that were able to retrieve the information?

[font="Fixedsys"][list][*]All of my AutoIt Example Scripts[*]http://saneasylum.com[/list][/font]

Link to comment
Share on other sites

By default WMP doesn't write ratings to the file. You need to enable the option in WMP:

Tools | Options, Library tab, "Maintain my star ratings as global ratings in files"

The editor I used was ID3-TagIT (http://www.id3-tagit.de/english/index.htm). In the util, it has a ratings category. Clicking on this returned the WMP rating info

On a side note, it would be great to be able to write value as well. I'm trying to make a streamlined library manager that would allow me to implement a ratings system that would use my already defined ratings in these files and allow me to update them without having to use WMP. I'm not sure if the ID3 UDF supports writing...I'll look into this now. :-)

Edited by sshrum

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

Link to comment
Share on other sites

By default WMP doesn't write ratings to the file. You need to enable the option in WMP:

Tools | Options, Library tab, "Maintain my star ratings as global ratings in files"

I'm aware of that option. I tried setting the rating with that both turned on and off. The file was not modified in either instance. Are you finding that the file's Date Modified value (right click on file, select Properties) is changing when you do this? If so, our machines behave differently.

[font="Fixedsys"][list][*]All of my AutoIt Example Scripts[*]http://saneasylum.com[/list][/font]

Link to comment
Share on other sites

I don't have that garbage player installed, but I believe that what you seek is stored in "POPM" tag frame. Of the data inside the frame, only the last byte matters (value 00-FF representing rating 1-5). The rest is just Micro$oft pimpin' their own name as usual: a zero terminated ASCII string "Windows Media Player 9 Series".

At least that's what Mp3Tag (which claims supporting "WMP RATING" among other things) writes into ID3v2 tag.

Edited by Siao

"be smart, drink your wine"

Link to comment
Share on other sites

I'm aware of that option. I tried setting the rating with that both turned on and off. The file was not modified in either instance. Are you finding that the file's Date Modified value (right click on file, select Properties) is changing when you do this? If so, our machines behave differently.

This is from the WMP11 help:

When this setting is selected, your user ratings are stored in your individual media files instead of in your library database file. Even though the rating information is stored in a different file location, your ratings will still appear in your library as normal.

Hmmm....I can't seem to get it to do anything to my test MP3 file with WMP11. I checked the date, opened it, rated it, closed WMP, relaunched WMP and my rating was retained. Modified date on the file was not changed (but that is possible...one could modify a file and tell the system to not update its modified date). Opened the MP3 in ID3-TagIT but the rating was not in the MP3. :-S

I've included a screencap of the ratings dialog from ID3-TagIT on a file that does have a rating saved to it. Granted it sez WMP 9 so I wonder if something changed since then.

http://www.shrum.net/uploads/ratings.gif

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

I don't have that garbage player installed...

It has its pro's and con's...

Most media managers are set up to deal with smaller libraries (~1,000)...mine is approaching 30,000 files. I even went as far as to try iTunes but had the same result -> bogged my system.

This is why I'm trying to write something functional (without all the glitz) for larger libraries.

...pimpin' their own name as usual: a zero terminated ASCII string "Windows Media Player 9 Series".

Yeah...that's what I'm seeing in ID3-TagIT. But I can't seem to get WMP11 to write anything to the files. Odd. Edited by sshrum

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

But I can't seem to get WMP11 to write anything to the files. Odd.

You're not the only one

This dude here came to the conclusion that WMP11 only stores ratings in its database.

Edited by Siao

"be smart, drink your wine"

Link to comment
Share on other sites

I guess I just have to pull from the WMP DB :-(

On another note, I found the motherload on WMP calls for the WMMEDIA UDF. I was able to pull the WMP "UserEffectiveRating" for the rating. Here is the listing I found:

AcquisitionTime
AlbumID
AlbumIDAlbumArtist
Author
AverageLevel
Bitrate
BuyNow
BuyTickets
Copyright
CurrentBitrate
Duration
FileSize
FileType
Is_Protected
IsVBR
MediaType
MoreInfo
PeakValue
ProviderLogoURL
ProviderURL
RecordingTime
ReleaseDate
RequestState
SourceURL
SyncState
Title
TrackingID
UserCustom1
UserCustom2
UserEffectiveRating
UserLastPlayedTime
UserPlayCount
UserPlaycountAfternoon
UserPlaycountEvening
UserPlaycountMorning
UserPlaycountNight
UserPlaycountWeekday
UserPlaycountWeekend
UserRating
UserServiceRating
WM/AlbumArtist
WM/AlbumTitle
WM/Category
WM/Composer
WM/Conductor
WM/ContentDistributor
WM/ContentGroupDescription
WM/EncodingTime
WM/Genre
WM/GenreID
WM/InitialKey
WM/Language
WM/Lyrics
WM/MCDI
WM/MediaClassPrimaryID
WM/MediaClassSecondaryID
WM/Mood
WM/ParentalRating
WM/Period
WM/ProtectionType
WM/Provider
WM/ProviderRating
WM/ProviderStyle
WM/Publisher
WM/SubscriptionContentID
WM/SubTitle
WM/TrackNumber
WM/UniqueFileIdentifier
WM/WMCollectionGroupID
WM/WMCollectionID
WM/WMContentID
WM/Writer

I'm going to see how many of these I can get working.

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...