Your Digital Media Has Never Looked So Good

 
grommet
Topic Author
Posts: 1718
Joined: Thu Dec 16, 2004 9:31 pm
Location: S.F. Bay Area, CA

WMA User Rating tag not parsed correctly?

Mon Jun 12, 2006 1:14 pm

Parsing of WMA's WM/SharedUserRating metadata into Firefly doesn't seem to work correctly. I only see items rated as "5 Star"... the others don't appear and look unrated.

This is what the metadata in WMA stores:

WM/SharedUserRating: 99 = 5 Star
WM/SharedUserRating: 75 = 4 Star
WM/SharedUserRating: 50 = 3 Star
WM/SharedUserRating: 25 = 2 Star
WM/SharedUserRating: 1 = 1 Star

I only see ones tagged with 99... which appear as 5 star. (I assume you used a numeric range to convert to whatever Firefly's native database and DAAP/RSP uses?)
 
rpedde
Posts: 1015
Joined: Fri Sep 10, 2004 6:25 pm

Re: WMA User Rating tag not parsed correctly?

Mon Jun 12, 2006 7:58 pm

grommet wrote:
Parsing of WMA's WM/SharedUserRating metadata into Firefly doesn't seem to work correctly. I only see items rated as "5 Star"... the others don't appear and look unrated.

This is what the metadata in WMA stores:

WM/SharedUserRating: 99 = 5 Star
WM/SharedUserRating: 75 = 4 Star
WM/SharedUserRating: 50 = 3 Star
WM/SharedUserRating: 25 = 2 Star
WM/SharedUserRating: 1 = 1 Star

I only see ones tagged with 99... which appear as 5 star. (I assume you used a numeric range to convert to whatever Firefly's native database and DAAP/RSP uses?)


Ack. you are right. I was trying to convert it into a rating system that wasn't completely brain-damaged.

The "internal" format is 0-100, with 0 being unrated and 20, 40, 60, 80, and 100 being 1,2,3,4, and 5 stars respectively. Sadly, I appear to have something less than a third-grade math ability, as I completely fumbled the conversion.

Should be fixed in r1214. As an aside, I wasn't able to test this (obviously) as the windows media dingus doesn't seem to add a sm/shareduserrating when you rate music. Is there another way to do this, or am I missing something?
 
Ted Harper
Posts: 154
Joined: Fri Mar 24, 2006 1:39 pm
Location: Sydney, Australia
Contact:

Re: WMA User Rating tag not parsed correctly?

Mon Jun 12, 2006 8:30 pm

rpedde wrote:
As an aside, I wasn't able to test this (obviously) as the windows media dingus doesn't seem to add a sm/shareduserrating when you rate music. Is there another way to do this, or am I missing something?


There is a checkbox on the Options/Library tab in WMP (10) - down the bottom of the tab. I think when checked (which is NOT the default) then the star ratings are actually maintained within the music files, but when not checked (default) they are in the library database and hence not visible to anything other than WMP.


ted.h.
 
grommet
Topic Author
Posts: 1718
Joined: Thu Dec 16, 2004 9:31 pm
Location: S.F. Bay Area, CA

Mon Jun 12, 2006 8:33 pm

Yep, they left that off by default for some reason. I guess some folks don't want "permanent" ratings in the actual files... which might be more personal than traditional metadata.

Thanks for the fix, Ron!
Last edited by grommet on Mon Jun 12, 2006 10:07 pm, edited 1 time in total.
 
rpedde
Posts: 1015
Joined: Fri Sep 10, 2004 6:25 pm

Mon Jun 12, 2006 8:48 pm

grommet wrote:
Yep, they left that off by default for some reason. I guess some folks don't want "permanent" ratings in the actual files... which might be more personal that traditional metadata.

Thanks for the fix, Ron!


That's actually pretty reasonable, in retrospect. Thanks for the heads-up. Now I guess I can test this stuff. hehe.
 
Ted Harper
Posts: 154
Joined: Fri Mar 24, 2006 1:39 pm
Location: Sydney, Australia
Contact:

Mon Jun 12, 2006 8:51 pm

But, but, but...

If I'm not sharing/copying the files (ie even if I have multiple users on my PC, or serving the library to several devices via Firefly or WMC), they're _my_ ratings and _my_ files, so it shouldn't be a problem to store the ratings within the files by default, right?

I guess I can understand there being some scenarios where several users of the same PC have wildly differing views on a particular artist/track (I have three kids, so I know a lot about this kind of variation!), but having a rating tag and _not_ using it by default isn't what I would have expected the default behaviour to be.


ted.h. (being a bit facetious, sorry)

p.s. It's a pity that play count and last played date/time aren't in the file metadata too. I think it would be nice for Firefly (etc) to be able to update that information when the track is played (and also for the Soundbridge to have a "rate this song" capability back into the library via the media server software, like the iPod does back to iTunes). Can't be done in a generally useable sense without there being tags supporting that though unfortunately.
 
grommet
Topic Author
Posts: 1718
Joined: Thu Dec 16, 2004 9:31 pm
Location: S.F. Bay Area, CA

Mon Jun 12, 2006 9:01 pm

By the way, for the curious out there... the "official" ranges for WM/SharedUserRating is:

0 = Not rated
1 to 24 = 1 Star
25 to 49 = 2 Star
50 to 74 = 3 Star
75 to 98 = 4 Star
99 = 5 Star

Hey Ron... What about ID3v2's "POPM" frame? That's what Microsoft uses on MP3 files as the equivalent of WM/SharedUserRating. Really. Microsoft is probably one of 3 on the planet to actually implement the use this tag. I think libid3tag supports it. How about it? :-D
 
rpedde
Posts: 1015
Joined: Fri Sep 10, 2004 6:25 pm

Mon Jun 12, 2006 9:05 pm

Ted Harper wrote:
I think it would be nice for Firefly (etc) to be able to update that information when the track is played


Actually, it does store that info in "play_count" and "date_played". They are both useable when building smart playlists.

(and also for the Soundbridge to have a "rate this song" capability back into the library via the media server software, like the iPod does back to iTunes).


That's exactly the kind of thing I'd like to be able to do as well.
 
rpedde
Posts: 1015
Joined: Fri Sep 10, 2004 6:25 pm

Mon Jun 12, 2006 9:08 pm

grommet wrote:
By the way, for the curious out there... the "official" ranges for WM/SharedUserRating is:

0 = Not rated
1 to 24 = 1 Star
25 to 49 = 2 Star
50 to 74 = 3 Star
75 to 98 = 4 Star
99 = 5 Star


That's how I converted it, from msft's docs. 99=100, otherwise, rating = (rating/25 + 1) * 20 to convert to a 0,20,40,60,80,100 range.

Hey Ron... What about ID3v2's "POPM" frame? That's what Microsoft uses on MP3 files as the equivalent of WM/SharedUserRating. Really. Microsoft is probably one of 3 on the planet to actually implement the use this tag. I think libid3tag supports it. How about it? :-D


I can code it, but you'll have to test it. Unsurprisingly, I have zero files with this tag, or I'd already have that support.

-- Ron

p.s. is there a format you *DON'T* have??

p.p.s. ticket #149
 
grommet
Topic Author
Posts: 1718
Joined: Thu Dec 16, 2004 9:31 pm
Location: S.F. Bay Area, CA

Mon Jun 12, 2006 9:46 pm

p.s. is there a format you *DON'T* have??
Muahahaha! :twisted:

Cool. The "Popularimeter" is a very strange ID3v2 tag. Let's help you get started:

WMP 9/10/11 sets the "e-mail to user" field in POPM to "Windows Media Player 9 Series" and it sets the rating to:

0 Star = 0x00
1 Star = 0x01
2 Star = 0x40
3 Star = 0x80
4 Star = 0xC4
5 Star = 0xFF

(There can be multiple POPM frames, hence the "user" field. Ugh.)

Microsoft doesn't use the optional & very odd counter feature of POPM... and I doubt anyone else does, either. (It's different than the PCNT tag that nobody uses, either. Ugh. I love poor pseudo-standards.)

There you go... Enjoy! Yes, it's a number between 0 and 255. I guess 100 just wasn't enough granularity. 8)
 
rpedde
Posts: 1015
Joined: Fri Sep 10, 2004 6:25 pm

Mon Jun 12, 2006 10:31 pm

grommet wrote:
p.s. is there a format you *DON'T* have??
Muahahaha! :twisted:

Cool. The "Popularimeter" is a very strange ID3v2 tag. Let's help you get started:

WMP 9/10/11 sets the "e-mail to user" field in POPM to "Windows Media Player 9 Series" and it sets the rating to:

0 Star = 0x00
1 Star = 0x01
2 Star = 0x40
3 Star = 0x80
4 Star = 0xC4
5 Star = 0xFF

(There can be multiple POPM frames, hence the "user" field. Ugh.)

Microsoft doesn't use the optional & very odd counter feature of POPM... and I doubt anyone else does, either. (It's different than the PCNT tag that nobody uses, either. Ugh. I love poor pseudo-standards.)

There you go... Enjoy! Yes, it's a number between 0 and 255. I guess 100 just wasn't enough granularity. 8)


Implemented (with no testing whatsoever) in r1215. Do you have a sample you could send me before I make a nightly?

Who is online

Users browsing this forum: No registered users and 1 guest