2011-05-25, 00:19
I was wondering if it was possible to implement a Pandora player as a plugin?
Something that might Pandora a different that other streaming music options
is that each song has a unique URL that is only good for a short period of time.
Pandora hands you 4 URLs at a time (like a mini playlist). When you've played
the 4 songs, you can go back to Pandora to request more.
I attempted a Pandora plugin unsuccessfully in the past. The place where
I stumbled was figuring out when to tell the player to play the next song
in the playlist. I had subclasses Player however the notifications were not
specific enough for me to distinquish between the user hitting stop in their
remote and the current song just ending. I was thinking that I might have to
seperately keep track of when the user has hit stop & use that information in
OnPlayBackEnded(). It seems ugly to me so I didn't persue it.
Can someone suggest the proper way to implement a plugin with a dynamic
playlist? If there is an exsting example of something like this, I woudl apprecaite
it if someone can point me in the direction of it...
Thanks,
Steve
Something that might Pandora a different that other streaming music options
is that each song has a unique URL that is only good for a short period of time.
Pandora hands you 4 URLs at a time (like a mini playlist). When you've played
the 4 songs, you can go back to Pandora to request more.
I attempted a Pandora plugin unsuccessfully in the past. The place where
I stumbled was figuring out when to tell the player to play the next song
in the playlist. I had subclasses Player however the notifications were not
specific enough for me to distinquish between the user hitting stop in their
remote and the current song just ending. I was thinking that I might have to
seperately keep track of when the user has hit stop & use that information in
OnPlayBackEnded(). It seems ugly to me so I didn't persue it.
Can someone suggest the proper way to implement a plugin with a dynamic
playlist? If there is an exsting example of something like this, I woudl apprecaite
it if someone can point me in the direction of it...
Thanks,
Steve