It is currently April 19th, 2024, 10:18 am

NowPlaying plugin - Multiple Media Player Support

Share and get help with Plugins and Addons
poiru
Developer
Posts: 2872
Joined: April 17th, 2009, 12:18 pm

NowPlaying plugin

Post by poiru »

dQuille wrote:Does this plugin pull the default album art that the app is using (i.e. can it pull embedded art if that's what foobar is using for the currently playing track)?
Yes (although I have yet to add support for foobar2k). In the case of Winamp, for example, the plugin tries the following:
- Check for embedded art in audio file
- Check for %album%.jpg/cover.jpg/folder.jpg (in same directory as audio file)
- Download album art from Last.fm or Amazon
- Use default album art (specified by the DefaultArtwork= option)

The process will likely be similar with fooobar2k.
CybOrSpasm
Posts: 146
Joined: January 8th, 2011, 7:12 pm
Location: Tennessee

Re: NowPlaying plugin [WIP]

Post by CybOrSpasm »

Is waiting patiently for VLC.... };] Sounds very cool though!
dQuille
Posts: 5
Joined: April 26th, 2011, 3:10 pm

Re: NowPlaying plugin

Post by dQuille »

poiru wrote: Yes (although I have yet to add support for foobar2k). In the case of Winamp, for example, the plugin tries the following:
- Check for embedded art in audio file
- Check for %album%.jpg/cover.jpg/folder.jpg (in same directory as audio file)
- Download album art from Last.fm or Amazon
- Use default album art (specified by the DefaultArtwork= option)

The process will likely be similar with fooobar2k.
Great! I've been using a customized skin based on the foo_httpcontrol method of pulling the info, which works ok but has problems with embedded art. "CD Art Display" is a standalone app I've also used that is great for displaying this kind of info but it also doesn't support embedded art. Sounds like this plugin will solve that issue I have and I'm sure your dedicated plugin will be nice and fast at pulling the data.

I'd also recommend if you haven't done it already that your component has a way to return the directory of the currently playing song - that way users can set up a slideshow meter to slideshow all of the art they have in a particular artist's directory if they like. I've done that in the past by customizing the foo_httpcontrol method and it works well.
Scream81
Posts: 10
Joined: April 21st, 2011, 12:00 pm

Re: NowPlaying plugin [WIP]

Post by Scream81 »

will this plugin also be able to control the volume of media player? always nice to have :)
poiru
Developer
Posts: 2872
Joined: April 17th, 2009, 12:18 pm

Re: NowPlaying plugin [WIP]

Post by poiru »

Scream81 wrote:will this plugin also be able to control the volume of media player? always nice to have :)
Yes, if the media player is fully supported.
poiru
Developer
Posts: 2872
Joined: April 17th, 2009, 12:18 pm

Version 0.9

Post by poiru »

After a long wait, I finally have something to show. Grab the alpha version from http://poiru.net/np090.zip.

Note: You must be using Rainmeter 2.1 beta. Also, you must open Skin.ini and set MediaPlayer= on line 12 to one of the following (haven't implemented auto-detect yet):
- Spotify (partial support only)
- WMP
- iTunes
- Winamp

Note 2: This is not the final version. There is still work left to do, but the essential bits should work. Do not distribute the .dll with your own skin -- bad things (crashes) can happen.

The example skin covers it pretty well, I think. There are several things that have not yet been implemented (e.g. setting volume), so this is really only a pre-release version.

Result should resemble:

Let me know how it works :)

Implementation details for those interested:
- The album art cache is at %TEMP%\Rainmeter-Cache

Winamp:
- Track info is read directly from file (I haven't tested with audio files other than MP3)
- Cover art is determined in the following order:
1) Cache
2) Embedded art (if found, it's moved into the cache)
3) %album%.jpg, cover.jpg, and folder.jpg (in the folder of the audio file)

iTunes:
- Track info and cover art obtained through iTunes interface (if found, cover art is stored in cache)

WMP:
- Track info obtained through WMP interface
- Cover art is determined in the following order:
1) "AlbumArt_GUID_Large.jpg" (in the folder of the audio file, GUID is a unique identifier)
2) Cache
2) Embedded art (if found, it's moved into the cache)

Spotify: (limited support)
- Track/artist obtained through the title of the Spotify window
- Cover art is downloaded from Amazon (may or may not work depending on the track) and stored in cache
User avatar
Waldensamkeit
Posts: 83
Joined: March 15th, 2011, 12:39 pm
Location: Hamilton, New Jersey

Re: NowPlaying plugin [version 0.9]

Post by Waldensamkeit »

Well, First off, my windows wouldn't let me run the skin, (Closed Rainmeter and refused to let me open it) until I set MediaPlayer=XXX in the skin.ini

SO in case anyone is having problems, try setting that first. Now I'll go play with it for a bit and see what's what.

I can't even tell you how long I've been waiting for something like this for Winamp. Did not want to download CAD or Foobar as I love my Winamp.

Thank you thank you.

EDIT: Hopefully this isn't jumping the gun as this is an Alpha release but I figured I would throw in what I see.

1.(Using the play button to pause. Not sure if it was meant to but it does pause and resume the track...) Pausing the music and restarting it causes all info to clear, including artwork. While paused the progress resets to zero. Resuming playback will pick up the progress where it left off but only current progress will show, not even total song length or percentage returns.

2. Clicking next or previous will cause the skin to display ALL info once again. This is after playback is resumed from being paused which caused all info to be cleared.

Hopefully that's worth something.

Simpley awesome plugin...
poiru
Developer
Posts: 2872
Joined: April 17th, 2009, 12:18 pm

Re: NowPlaying plugin [version 0.9]

Post by poiru »

Waldensamkeit wrote:EDIT: Hopefully this isn't jumping the gun as this is an Alpha release but I figured I would throw in what I see.
Not at all -- much thanks for your input. The play button is actually a "Play/Pause" button. I'll rename it (as well as add dedicated commands for Play and Pause).

The other issues will be fixed for next release.
Waldensamkeit wrote:Well, First off, my windows wouldn't let me run the skin, (Closed Rainmeter and refused to let me open it) until I set MediaPlayer=XXX in the skin.ini

SO in case anyone is having problems, try setting that first. Now I'll go play with it for a bit and see what's what
That's why "must" is underlined ;)
User avatar
santa_ryan
Posts: 397
Joined: June 22nd, 2010, 4:11 am

Re: NowPlaying plugin [version 0.9]

Post by santa_ryan »

It would be nice if you could reset the album image when the next song comes on.

If the next song doesn't have album art, it uses the previous album art, which doesn't look good. This problem also occurs with the iTunesPlugin.dll.
I have three rules when I'm trying to help you.
  • Don't get mad when you don't understand something
  • Be VERY specific with what you ask for.
    The more specific you are, the higher the quality of support you receive.
  • Do not just copy and paste what I put in examples and come back saying it doesn't work.
    It does work, but I purposely left blanks that you need to fill for your specific needs.
poiru
Developer
Posts: 2872
Joined: April 17th, 2009, 12:18 pm

Re: NowPlaying plugin [version 0.9]

Post by poiru »

santa_ryan wrote:It would be nice if you could reset the album image when the next song comes on.
It does that for me. Did you modify the skin?