It is currently March 28th, 2024, 11:25 pm

Spotify Plugin Released! Now with less bugs!

Plugins and Addons popular with the Community
User avatar
.raptor
Posts: 220
Joined: April 3rd, 2013, 11:03 pm
Location: Norway

Re: Spotify Plugin Released! Now with less bugs!

Post by .raptor »

Pretty much completely rewrote the plugin. The only reason this isn't released as version 2 is that my testing capabilities are quite limited at the moment. I do not recommend updating if the previous version is working well for you, unless you want to help me test the new one. The commands available are

Code: Select all

playpause, play, pause, next, previous, volume %percent%, seek %millisec%, seekpercent %percent%, shuffle %true or false%, repeat %Track, Context or Off%
You do not have the required permissions to view the files attached to this post.
User avatar
tjhrulz
Developer
Posts: 267
Joined: October 13th, 2016, 1:28 am
Location: Earth

Re: Spotify Plugin Released! Now with less bugs!

Post by tjhrulz »

.raptor wrote:Pretty much completely rewrote the plugin. The only reason this isn't released as version 2 is that my testing capabilities are quite limited at the moment. I do not recommend updating if the previous version is working well for you, unless you want to help me test the new one. The commands available are

Code: Select all

playpause, play, pause, next, previous, volume %percent%, seek %millisec%, seekpercent %percent%, shuffle %true or false%, repeat %Track, Context or Off%
I assume all those commands though are spotify premium only as they were before?

Edit: Also any chance the repo can by update to help with debugging issue with this? A few people are telling me they are getting crashes when testing it.

Edit2: Also if we are going to do a complete rewrite I would like it if it conformed to the NowPlaying options a little more
User avatar
.raptor
Posts: 220
Joined: April 3rd, 2013, 11:03 pm
Location: Norway

Re: Spotify Plugin Released! Now with less bugs!

Post by .raptor »

tjhrulz wrote:I assume all those commands though are spotify premium only as they were before?

Edit: Also any chance the repo can by update to help with debugging issue with this? A few people are telling me they are getting crashes when testing it.

Edit2: Also if we are going to do a complete rewrite I would like it if it conformed to the NowPlaying options a little more
I assume they are premium only yes.

I will update Github now, so please bear with me and my spaghetti code. Feel free to make a branch with the NowPlaying options implemented so I can merge it.
User avatar
tjhrulz
Developer
Posts: 267
Joined: October 13th, 2016, 1:28 am
Location: Earth

Re: Spotify Plugin Released! Now with less bugs!

Post by tjhrulz »

.raptor wrote:I assume they are premium only yes.

I will update Github now, so please bear with me and my spaghetti code. Feel free to make a branch with the NowPlaying options implemented so I can merge it.
Kk, I will look into it when I get a chance. Also I am gonna send you a pm about something.
User avatar
.raptor
Posts: 220
Joined: April 3rd, 2013, 11:03 pm
Location: Norway

Re: Spotify Plugin Released! Now with less bugs!

Post by .raptor »

Stability improvements. Have high hopes for this patch, so keep me posted.
You do not have the required permissions to view the files attached to this post.
reloaded1212
Posts: 5
Joined: August 11th, 2014, 3:05 am

Re: Spotify Plugin Released! Now with less bugs!

Post by reloaded1212 »

Hi .raptor, firstly, thank you so much for putting this plugin together, it is really useful!

Just wanted to bring up one issue - in regards to v 1.9.1.0, it works great, but it opens up the default Internet browser at computer startup every time for me, linking to a blank page from spotify (I assume this is for account credentials). This is only a minor inconvenience but I have switched back to v1.4 for the time being.
waffleberry
Posts: 3
Joined: October 13th, 2017, 3:18 pm

Re: Spotify Plugin Released! Now with less bugs!

Post by waffleberry »

Hello.
I am unsuccessful in implementing seek.
MouseScrollUpAction=[!CommandMeasure "mProgress" "seek 6000"
I've used this bit to try get it to work but nothing happened except some weird issues where rainmeter was unclickable. I could either wait it or or force close and restart rainmeter itself..

Sometimes SpotifyPlugin won't work with next, playpause and next in executing the commands, but the playpause state still updates properly if using Spotify itself. I have not been able to successfully recreate the circumstances.

I'll drop my code in too. (It might be a lil' messy)

Code: Select all

[Rainmeter]
Author=waffleberry
Update=200

[Metadata]
Version=0.19
Description=A WIP implementation of .raptor's SpotifyPlugin.

[Variables]
AlbumArtSize=240
AlbumArtFix=18
TextWidth=300

[mSpotifyOpen]
Measure=Plugin
Plugin=Process
ProcessName=Spotify.exe
IfAboveValue=0
IfAboveAction=[!ShowMeterGroup PlayerShow]
;[!HideMeter SpotifyOpen]
IfBelowValue=0
IfBelowAction=[!HideMeterGroup PlayerShow]
;[!ShowMeter SpotifyOpen]

[SpotifyOpen]
Meter=Button
ButtonImage=#@#Open.png
ButtonCommand=["C:\Users\MENJIE\AppData\Roaming\Spotify\Spotify.exe"]
SolidColor=0,0,0,1
 
[mSpotifyNowPLaying]
Measure=Plugin
Plugin=NowPlaying
PlayerName=Spotify
PlayerType=TITLE


[mPlaying]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Playing

[mRepeat]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Repeat

[mShuffle]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Shuffle

[mTrack]
Measure=Plugin
Plugin=SpotifyPlugin
Type=TrackName
Substitute="":"N\A","0":"Spotify"

[mArtist]
Measure=Plugin
Plugin=SpotifyPlugin
Type=ArtistName
Substitute="":"N\A","0":"is"

[mAlbum]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=AlbumName
Substitute="":"N\A","0":"loading..."

[mCover]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=AlbumArt
;Substitute="":"#@#Default.png"
;Res=300
DefaultPath=#@#Default.png
CoverPath=#@#Cover.png

[mDuration]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Length

[mPosition]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Position

[mProgress]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Progress

[mStateButton]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Playing
Substitute="0":"#@#Play.png","1":"#@#Pause.png","2":"#@#Play.png"

[mVolume]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Volume

[mVolumeRound]
Measure=Calc
Formula=Round([mVolume])
DynamicVariables=1

[Cover]
Meter=Image
MeasureName=mCover
X=0
Y=0
W=(#AlbumArtSize#)
H=(#AlbumArtSize#)
SolidColor=FFFFFF10
Group=PlayerShow

[Track]
Meter=STRING
MeasureName=mTrack
X=(#AlbumArtSize#-1)
Y=1
W=300
;H=22
FontFace=Trebuchet MS
FontSize=14
FontColor=FFFFFFFF
AntiAlias=1
ClipString=1
Text="%1"
Group=PlayerShow

[Artist]
Meter=STRING
MeasureName=mArtist
X=(#AlbumArtSize#+1)
Y=20r
W=#TextWidth#
;H=22
FontFace=Trebuchet MS
FontColor=FFFFFFFF
AntiAlias=1
ClipString=1
Text="%1"
Group=PlayerShow

[Album]
Meter=STRING
MeasureName=mAlbum
X=(#AlbumArtSize#+1)
Y=20r
W=#TextWidth#
;H=22
FontFace=Trebuchet MS
FontColor=FFFFFFFF
AntiAlias=1
ClipString=1
Text="%1"
Group=PlayerShow

[Time]
Meter=STRING
MeasureName=mPosition
MeasureName2=mDuration
SolidColor=0,0,0,1
X=(#AlbumArtSize#+1)
Y=20r
H=16
W=#TextWidth#
FontFace=Trebuchet MS
FontColor=FFFFFF99
AntiAlias=1
ClipString=1
Text="%1/%2"
DynamicVariables=1
Group=PlayerShow
;LeftMouseUpAction=[!CommandMeasure "mProgress" "seekpercent +2"]
;MouseScrollDownAction=[!CommandMeasure "mProgress" "seekpercent -2"]


[Previous]
Meter=BUTTON
ButtonImage=#@#Previous.png
X=(#AlbumArtSize#)
Y=(#AlbumArtSize#-#AlbumArtFix#)
;LeftMouseUpAction=[!CommandMeasure "mSpotifyNowPlaying" "previous"]
LeftMouseUpAction=[!CommandMeasure "mProgress" "previous"]
DynamicVariables=1
Group=PlayerShow

[Play]
Meter=BUTTON
ButtonImage=[mStateButton]
X=20r
Y=0r
;LeftMouseUpAction=[!CommandMeasure "mSpotifyNowPlaying" "playpause"]
LeftMouseUpAction=[!CommandMeasure "mProgress" "playpause"]
DynamicVariables=1
Group=PlayerShow

[Next]
Meter=BUTTON
ButtonImage=#@#Next.png
X=20r
Y=0r
;LeftMouseUpAction=[!CommandMeasure "mSpotifyNowPlaying" "next"]
LeftMouseUpAction=[!CommandMeasure "mProgress" "next"]
;MouseScrollUpAction=[!CommandMeasure "mProgress" "seek 6000"
DynamicVariables=1
Group=PlayerShow

[VolumeText]
Meter=String
MeasureName=mVolumeRound
X=(#AlbumArtSize#+#TextWidth#)
Y=(#AlbumArtSize#-#AlbumArtFix#-1)
W=30
H=16
StringAlign=Right
FontSize=10
FontFace=Trebuchet MS
FontColor=FFFFFF99
AntiAlias=1
SolidColor=0,0,0,1
NumOfDecimals=0
ClipString=2
Text="%1%"
DynamicVariables=1
Group=PlayerShow

[Volume]
Meter=IMAGE
ImageName=#@#Volume.png
X=(#AlbumArtSize#+#TextWidth#-43)
Y=(#AlbumArtSize#-#AlbumArtFix#)
Group=PlayerShow

[ProgressBar]
Meter=BAR
MeasureName=mProgress
X=#AlbumArtSize#
Y=(#AlbumArtSize#-2)
W=#TextWidth#
H=2
BarColor=FFFFFFFF
SolidColor=FFFFFF10
BarOrientation=HORIZONTAL
Group=PlayerShow
MouseOverAction=[!SetOption ProgressBar H "5"][!SetOption ProgressBar Y "(#AlbumArtSize#-5)"]
MouseLeaveAction=[!SetOption ProgressBar H "2"][!SetOption ProgressBar Y "(#AlbumArtSize#-2)"]
DynamicVariables=1
I haven;t done anything for the shuffle and repeat buttons yet, but the measures seem to work fine.
User avatar
.raptor
Posts: 220
Joined: April 3rd, 2013, 11:03 pm
Location: Norway

Re: Spotify Plugin Released! Now with less bugs!

Post by .raptor »

reloaded1212 wrote:Hi .raptor, firstly, thank you so much for putting this plugin together, it is really useful!

Just wanted to bring up one issue - in regards to v 1.9.1.0, it works great, but it opens up the default Internet browser at computer startup every time for me, linking to a blank page from spotify (I assume this is for account credentials). This is only a minor inconvenience but I have switched back to v1.4 for the time being.
Hopefully fixed.

waffleberry wrote:Hello.
I am unsuccessful in implementing seek.
MouseScrollUpAction=[!CommandMeasure "mProgress" "seek 6000"
I've used this bit to try get it to work but nothing happened except some weird issues where rainmeter was unclickable. I could either wait it or or force close and restart rainmeter itself..

Sometimes SpotifyPlugin won't work with next, playpause and next in executing the commands, but the playpause state still updates properly if using Spotify itself. I have not been able to successfully recreate the circumstances.

I'll drop my code in too. (It might be a lil' messy)

Code: Select all

[Rainmeter]
Author=waffleberry
Update=200

[Metadata]
Version=0.19
Description=A WIP implementation of .raptor's SpotifyPlugin.

[Variables]
AlbumArtSize=240
AlbumArtFix=18
TextWidth=300

[mSpotifyOpen]
Measure=Plugin
Plugin=Process
ProcessName=Spotify.exe
IfAboveValue=0
IfAboveAction=[!ShowMeterGroup PlayerShow]
;[!HideMeter SpotifyOpen]
IfBelowValue=0
IfBelowAction=[!HideMeterGroup PlayerShow]
;[!ShowMeter SpotifyOpen]

[SpotifyOpen]
Meter=Button
ButtonImage=#@#Open.png
ButtonCommand=["C:\Users\MENJIE\AppData\Roaming\Spotify\Spotify.exe"]
SolidColor=0,0,0,1
 
[mSpotifyNowPLaying]
Measure=Plugin
Plugin=NowPlaying
PlayerName=Spotify
PlayerType=TITLE


[mPlaying]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Playing

[mRepeat]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Repeat

[mShuffle]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Shuffle

[mTrack]
Measure=Plugin
Plugin=SpotifyPlugin
Type=TrackName
Substitute="":"N\A","0":"Spotify"

[mArtist]
Measure=Plugin
Plugin=SpotifyPlugin
Type=ArtistName
Substitute="":"N\A","0":"is"

[mAlbum]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=AlbumName
Substitute="":"N\A","0":"loading..."

[mCover]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=AlbumArt
;Substitute="":"#@#Default.png"
;Res=300
DefaultPath=#@#Default.png
CoverPath=#@#Cover.png

[mDuration]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Length

[mPosition]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Position

[mProgress]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Progress

[mStateButton]
Measure=Plugin
Plugin=SpotifyPlugin
Type=Playing
Substitute="0":"#@#Play.png","1":"#@#Pause.png","2":"#@#Play.png"

[mVolume]
Measure=Plugin
Plugin=SpotifyPlugin.dll
Type=Volume

[mVolumeRound]
Measure=Calc
Formula=Round([mVolume])
DynamicVariables=1

[Cover]
Meter=Image
MeasureName=mCover
X=0
Y=0
W=(#AlbumArtSize#)
H=(#AlbumArtSize#)
SolidColor=FFFFFF10
Group=PlayerShow

[Track]
Meter=STRING
MeasureName=mTrack
X=(#AlbumArtSize#-1)
Y=1
W=300
;H=22
FontFace=Trebuchet MS
FontSize=14
FontColor=FFFFFFFF
AntiAlias=1
ClipString=1
Text="%1"
Group=PlayerShow

[Artist]
Meter=STRING
MeasureName=mArtist
X=(#AlbumArtSize#+1)
Y=20r
W=#TextWidth#
;H=22
FontFace=Trebuchet MS
FontColor=FFFFFFFF
AntiAlias=1
ClipString=1
Text="%1"
Group=PlayerShow

[Album]
Meter=STRING
MeasureName=mAlbum
X=(#AlbumArtSize#+1)
Y=20r
W=#TextWidth#
;H=22
FontFace=Trebuchet MS
FontColor=FFFFFFFF
AntiAlias=1
ClipString=1
Text="%1"
Group=PlayerShow

[Time]
Meter=STRING
MeasureName=mPosition
MeasureName2=mDuration
SolidColor=0,0,0,1
X=(#AlbumArtSize#+1)
Y=20r
H=16
W=#TextWidth#
FontFace=Trebuchet MS
FontColor=FFFFFF99
AntiAlias=1
ClipString=1
Text="%1/%2"
DynamicVariables=1
Group=PlayerShow
;LeftMouseUpAction=[!CommandMeasure "mProgress" "seekpercent +2"]
;MouseScrollDownAction=[!CommandMeasure "mProgress" "seekpercent -2"]


[Previous]
Meter=BUTTON
ButtonImage=#@#Previous.png
X=(#AlbumArtSize#)
Y=(#AlbumArtSize#-#AlbumArtFix#)
;LeftMouseUpAction=[!CommandMeasure "mSpotifyNowPlaying" "previous"]
LeftMouseUpAction=[!CommandMeasure "mProgress" "previous"]
DynamicVariables=1
Group=PlayerShow

[Play]
Meter=BUTTON
ButtonImage=[mStateButton]
X=20r
Y=0r
;LeftMouseUpAction=[!CommandMeasure "mSpotifyNowPlaying" "playpause"]
LeftMouseUpAction=[!CommandMeasure "mProgress" "playpause"]
DynamicVariables=1
Group=PlayerShow

[Next]
Meter=BUTTON
ButtonImage=#@#Next.png
X=20r
Y=0r
;LeftMouseUpAction=[!CommandMeasure "mSpotifyNowPlaying" "next"]
LeftMouseUpAction=[!CommandMeasure "mProgress" "next"]
;MouseScrollUpAction=[!CommandMeasure "mProgress" "seek 6000"
DynamicVariables=1
Group=PlayerShow

[VolumeText]
Meter=String
MeasureName=mVolumeRound
X=(#AlbumArtSize#+#TextWidth#)
Y=(#AlbumArtSize#-#AlbumArtFix#-1)
W=30
H=16
StringAlign=Right
FontSize=10
FontFace=Trebuchet MS
FontColor=FFFFFF99
AntiAlias=1
SolidColor=0,0,0,1
NumOfDecimals=0
ClipString=2
Text="%1%"
DynamicVariables=1
Group=PlayerShow

[Volume]
Meter=IMAGE
ImageName=#@#Volume.png
X=(#AlbumArtSize#+#TextWidth#-43)
Y=(#AlbumArtSize#-#AlbumArtFix#)
Group=PlayerShow

[ProgressBar]
Meter=BAR
MeasureName=mProgress
X=#AlbumArtSize#
Y=(#AlbumArtSize#-2)
W=#TextWidth#
H=2
BarColor=FFFFFFFF
SolidColor=FFFFFF10
BarOrientation=HORIZONTAL
Group=PlayerShow
MouseOverAction=[!SetOption ProgressBar H "5"][!SetOption ProgressBar Y "(#AlbumArtSize#-5)"]
MouseLeaveAction=[!SetOption ProgressBar H "2"][!SetOption ProgressBar Y "(#AlbumArtSize#-2)"]
DynamicVariables=1
I haven;t done anything for the shuffle and repeat buttons yet, but the measures seem to work fine.
Can't get the seek function to work here either, even tho the Spotify API tells me nothing went wrong. Will look into it.
You do not have the required permissions to view the files attached to this post.
waffleberry
Posts: 3
Joined: October 13th, 2017, 3:18 pm

Re: Spotify Plugin Released! Now with less bugs!

Post by waffleberry »

Heyo

Seem to be having some issues with the repeat function. The plugin allows for Off/Context/Track but the measure only provides an On/Off scenario. Workarounds have not been panning out.
reloaded1212
Posts: 5
Joined: August 11th, 2014, 3:05 am

Re: Spotify Plugin Released! Now with less bugs!

Post by reloaded1212 »

Hi .raptor,

Latest release 1.9.2.0 works for me! No more internet browser popup at windows boot. Thank you!