It is currently April 26th, 2024, 7:27 pm
Media controls, music players, video and animated visualizers
FuzzyLizard530
Posts: 75 Joined: August 5th, 2014, 2:09 am
Post
by FuzzyLizard530 » September 16th, 2014, 4:41 am
I like a lot of the "Now Playing" skins, but didn't want to have to edit code just to switch between players, so I came up with this:
Code: Select all
[Rainmeter]
BackgroundMode=0
Update=1000
AccurateText=1
DynamicWindowSize=0
[Metadata]
Author=FuzzyLizard530 [a.k.a. David Dwight II ]
Name=Now PLaying with easy switch buttons
Information=Seconds-per-day counter, 4 Core CPU Mon, Battery and Wifi Meters, With Some Power State Buttons
Version=0.0.1
License=Creative Commons BY-NC-SA 3.0
;Data Mining :)
[Variables]
IconSize=32
HiLite=5
BGAlpha=128
Player=Foobar
Foolite=1
Spotlite=0
WAlite=0
AIMPlite=0
PlayerType=CAD
[TxtStyle]
StringAlign=LEFT
StringCase=NONE
StringStyle=BOLD
StringEffect=Border
FontEffectColor=0,0,0,255
FontColor=255,255,255,255
FontFace=Linux Biolinum G
FontSize=18
AntiAlias=1
[mTitle]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=TITLE
PlayerPath=
DisableLeadingZero=1
[mArtist]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mTitle]
PlayerType=ARTIST
[mAlbum]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mTitle]
PlayerType=ALBUM
[mPosition]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mTitle]
PlayerType=POSITION
[mDuration]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mTitle]
PlayerType=DURATION
[mProgress]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mTitle]
PlayerType=PROGRESS
[mStateButton]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=[mTitle]
PlayerType=STATE
Substitute="0":"Play.png","1":"Pause.png","2":"Play.png"
IfEqualValue=0
IfEqualAction=[!SetOption ProgressFrame ImageTint #colorText3#][!SetOption ProgressBitmap ImageTint #colorText3#][!SetOption CoverFrame ImageTint #colorText3#][!ShowMeter NoMusic]
IfAboveValue=0
IfAboveAction=[!SetOption ProgressFrame ImageTint #colorText#][!SetOption ProgressBitmap ImageTint #colorText#][!SetOption CoverFrame ImageTint #colorText#][!HideMeter NoMusic]
[Background]
Meter=Image
H=((#IconSize#)*4)+((#HiLite#)*8)
W=#SCREENAREAWIDTH#
SolidColor=0,0,0,128
X=0
Y=0
[FoobarHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#Foolite#)
X=0
Y=0
[SpotHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#Spotlite#)
X=0
Y=((#IconSize#)+(#HiLite#))r
[WAHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#WALite#)
X=0
Y=((#IconSize#)+(#HiLite#))r
[AIMPHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#AIMPlite#)
X=0
Y=((#IconSize#)+(#HiLite#))r
[FooBarSwitch]
Meter=Image
ImageName=#@#Icon\Foobar.png
X=#HiLite#
Y=#HiLite#
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Foobar"][!WriteKeyValue Variables PlayerType "CAD"][!WriteKeyValue Variables Foolite "1"][!WriteKeyValue Variables Spotlite "0"][!WriteKeyValue Variables WAlite "0"][!WriteKeyValue Variables AIMPlite "0"][!Refresh]
[SpotifySwitch]
Meter=Image
ImageName=#@#Icon\Spotify.png
X=#HiLite#
Y=((#HiLite#)+(#IconSize#))r
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Spotify"][!WriteKeyValue Variables PlayerType "Spotify"][!WriteKeyValue Variables Foolite "0"][!WriteKeyValue Variables Spotlite "1"][!WriteKeyValue Variables WAlite "0"][!WriteKeyValue Variables AIMPlite "0"][!Refresh]
[WinAmpSwitch]
Meter=Image
ImageName=#@#Icon\Winamp.png
X=#HiLite#
Y=((#HiLite#)+(#IconSize#))r
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Winamp"][!WriteKeyValue Variables PlayerType "Winamp"][!WriteKeyValue Variables Foolite "0"][!WriteKeyValue Variables Spotlite "0"][!WriteKeyValue Variables WAlite "1"][!WriteKeyValue Variables AIMPlite "0"][!Refresh]
[AimpSwitch]
Meter=Image
ImageName=#@#Icon\Aimp.png
X=#HiLite#
Y=((#HiLite#)+(#IconSize#))r
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Aimp"][!WriteKeyValue Variables PlayerType "Aimp"][!WriteKeyValue Variables Foolite "0"][!WriteKeyValue Variables Spotlite "0"][!WriteKeyValue Variables WAlite "0"][!WriteKeyValue Variables AIMPlite "1"][!Refresh]
[CoverGet]
Measure=Plugin
Plugin=NowPlaying
PlayerType=Cover
PlayerName=#PlayerType#
[NoCover]
Meter=Image
ImageName=#@#Icon\#Player#.PNG
X=((#HiLite#)+(#IconSize#))r
Y=#HiLite#
W=(((#IconSize#)*4)+((#HiLite#)*3))
H=(((#IconSize#)*4)+((#HiLite#)*3))
DynamicVariables=1
[CoverArt]
Meter=Image
MeasureName=CoverGet
X=r
Y=r
W=(((#IconSize#)*4)+((#HiLite#)*3))
H=(((#IconSize#)*4)+((#HiLite#)*3))
DynamicVariables=1
[TITLE]
Meter=String
MeasureName=mTitle
MeasureName2=mArtist
MeasureName3=mAlbum
MeasureName4=mPosition
MeasureName5=mDuration
X=(((#IconSize#)*5)+((#HiLite#)*6))
Y=((#HiLite#)*2)+((#IconSize#)*1)
Text=%2#CRLF#%1#CRLF#%3#CRLF#%5 %4
MeterStyle=TxtStyle
[SeekBarBG]
Meter=Bar
MeterStyle=styleBar
X=#HiLite#
Y=(((#IconSize#)*4)+(#HiLite#)*5)
W=((#SCREENAREAWIDTH#)-((#HiLite#)*2))
H=(2*(#HiLite#))
SolidColor=0,0,0,255
[SeekBar]
Meter=Bar
MeasureName=mProgress
BarOrientation=HORIZONTAL
X=r
Y=r
W=((#SCREENAREAWIDTH#)-((#HiLite#)*2))
H=(2*(#HiLite#))
Feel free to remix, and edit to your heart's content! All I ask is that you add a link to your version here! I may use it in place of what I've got here!
Sidenote: I do realize that it needs control buttons, but I'll get round to it soon!
eclectic-tech
Rainmeter Sage
Posts: 5407 Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA
Post
by eclectic-tech » September 18th, 2014, 12:41 am
NOW PLAYING w/BI-DIRECTIONAL MOUSE-SCROLL INTERFACE SELECTION
When mouse scrolling was added to Rainmeter, I wrote this code to scroll select any of the 10 available player interfaces... based on Kaelri's examples of swapping variables values using the !WriteKeyValue prior to refreshing the skin.
It is simply 1 meter that when scrolled over changes the variable used in the main nowplaying measure. (No buttons, No clicks, just Scrolling needed)
You should be able to add the variables and main player measure and player meter sections to almost any skin to achieve a list that can scroll select multiple interfaces.
Someone may have a better code to step through the 10 interfaces, but this has worked well for me...
EDIT: Removed 'PLAY...' command from the MouseScroll actions...
FuzzyLizard530
Posts: 75 Joined: August 5th, 2014, 2:09 am
Post
by FuzzyLizard530 » October 5th, 2014, 3:25 am
All that code makes my head and eyes hurt! LOL! Your idea is great, but it could cause me trouble when trying to use my touch pad (It doesn't always recognize 2-finger scrolling).
I did manage to get it to look how I wanted it to, though when asian characters appear, it bumps everything down a bit. Not sure if I'll fix that or not yet. I used the icons from
http://dakirby309.deviantart.com/art/Metro-UI-Icon-Set-725-Icons-280724102 .
Here's my code:
Code: Select all
[Rainmeter]
BackgroundMode=0
Update=1000
AccurateText=1
DynamicWindowSize=0
[Metadata]
Author=FuzzyLizard530 [a.k.a. David Dwight II ]
Name=Now PLaying with easy switch buttons
Information=Seconds-per-day counter, 4 Core CPU Mon, Battery and Wifi Meters, With Some Power State Buttons
Version=0.0.1
License=Creative Commons BY-NC-SA 3.0
;Data Mining :)
[Variables]
IconSize=32
HiLite=5
BGAlpha=128
Player=Foobar
Foolite=1
Spotlite=0
WAlite=0
AIMPlite=0
PlayerType=CAD
[TxtStyle]
StringAlign=LEFT
StringCase=NONE
StringStyle=BOLD
StringEffect=Border
FontEffectColor=0,0,0,255
FontColor=255,255,255,255
FontFace=Linux Biolinum G
FontSize=18
AntiAlias=1
[MeasureAudio]
Measure=Plugin
Plugin=AudioLevel
Port=Output
RMSAttack=100
RMSDecay=300
RMSGain=2.5
PeakAttack=15
PeakDecay=2700
PeakGain=1.0
[MeasureL]
Measure=Plugin
Plugin=AudioLevel
Parent=MeasureAudio
Channel=L
Type=RMS
[MeasureR]
Measure=Plugin
Plugin=AudioLevel
Parent=MeasureAudio
Channel=R
Type=RMS
[mTitle]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=TITLE
DisableLeadingZero=1
[mArtist]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=ARTIST
[mAlbum]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=ALBUM
[mYear]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=YEAR
Format=<[mYear]>
[mPosition]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=POSITION
[mDuration]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=DURATION
[mProgress]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=PROGRESS
[mStateButton]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=STATE
Substitute="0":"Play","1":"Pause","2":"Play"
IfEqualValue=0
IfEqualAction=[!SetOption ProgressFrame ImageTint #colorText3#][!SetOption ProgressBitmap ImageTint #colorText3#][!SetOption CoverFrame ImageTint #colorText3#][!ShowMeter NoMusic]
IfAboveValue=0
IfAboveAction=[!SetOption ProgressFrame ImageTint #colorText#][!SetOption ProgressBitmap ImageTint #colorText#][!SetOption CoverFrame ImageTint #colorText#][!HideMeter NoMusic]
[Background]
Meter=Image
H=((#IconSize#)*4)+((#HiLite#)*8)
W=#SCREENAREAWIDTH#
SolidColor=0,0,0,128
X=0
Y=0
[FoobarHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#Foolite#)
X=0
Y=0
[SpotHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#Spotlite#)
X=0
Y=((#IconSize#)+(#HiLite#))r
[WAHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#WALite#)
X=0
Y=((#IconSize#)+(#HiLite#))r
[AIMPHiLite]
Meter=Image
H=((#IconSize#)+(#HiLite#)*2)
W=((#IconSize#)+(#HiLite#)*2)
SolidColor=255,255,255,(255*#AIMPlite#)
X=0
Y=((#IconSize#)+(#HiLite#))r
[FooBarSwitch]
Meter=Image
ImageName=#@#Icon\Prog\Foobar.png
X=#HiLite#
Y=#HiLite#
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Foobar"][!WriteKeyValue Variables PlayerType "CAD"][!WriteKeyValue Variables Foolite "1"][!WriteKeyValue Variables Spotlite "0"][!WriteKeyValue Variables WAlite "0"][!WriteKeyValue Variables AIMPlite "0"][!Refresh]
[SpotifySwitch]
Meter=Image
ImageName=#@#Icon\Prog\Spotify.png
X=#HiLite#
Y=((#HiLite#)+(#IconSize#))r
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Spotify"][!WriteKeyValue Variables PlayerType "Spotify"][!WriteKeyValue Variables Foolite "0"][!WriteKeyValue Variables Spotlite "1"][!WriteKeyValue Variables WAlite "0"][!WriteKeyValue Variables AIMPlite "0"][!Refresh]
[WinAmpSwitch]
Meter=Image
ImageName=#@#Icon\Prog\Winamp.png
X=#HiLite#
Y=((#HiLite#)+(#IconSize#))r
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Winamp"][!WriteKeyValue Variables PlayerType "Winamp"][!WriteKeyValue Variables Foolite "0"][!WriteKeyValue Variables Spotlite "0"][!WriteKeyValue Variables WAlite "1"][!WriteKeyValue Variables AIMPlite "0"][!Refresh]
[AimpSwitch]
Meter=Image
ImageName=#@#Icon\Prog\Aimp.png
X=#HiLite#
Y=((#HiLite#)+(#IconSize#))r
W=#IconSize#
H=#IconSize#
LeftMouseDownAction=!Execute [!WriteKeyValue Variables Player "Aimp"][!WriteKeyValue Variables PlayerType "Aimp"][!WriteKeyValue Variables Foolite "0"][!WriteKeyValue Variables Spotlite "0"][!WriteKeyValue Variables WAlite "0"][!WriteKeyValue Variables AIMPlite "1"][!Refresh]
[CoverGet]
Measure=Plugin
Plugin=NowPlaying
PlayerType=Cover
PlayerName=#PlayerType#
[NoCover]
Meter=Image
ImageName=#@#Icon\Prog\#Player#.PNG
X=((#HiLite#)+(#IconSize#))r
Y=#HiLite#
W=(((#IconSize#)*4)+((#HiLite#)*3))
H=(((#IconSize#)*4)+((#HiLite#)*3))
DynamicVariables=1
[CoverArt]
Meter=Image
MeasureName=CoverGet
X=r
Y=r
W=(((#IconSize#)*4)+((#HiLite#)*3))
H=(((#IconSize#)*4)+((#HiLite#)*3))
DynamicVariables=1
PreserveAspectRatio=1
ToolTipText=Open #Player#
LeftMouseUpAction=[!CommandMeasure "CoverGet" "OpenPlayer"]
MouseActionCursor=0
[mVolume]
Measure=Plugin
Plugin=NowPlaying.dll
PlayerName=#PlayerType#
PlayerType=VOLUME
[Volumebar]
Meter=bar
Measurename=mVolume
x=r
y=r
H=(((#IconSize#)*4)+((#HiLite#)*3))
W=(((#IconSize#)*4)+((#HiLite#)*3))
SolidColor=0,0,0,0
BarColor=255,255,255,32
BarOrientation=Vertical
MouseScrollUpAction=[!CommandMeasure mVolume "SetVolume +10"]
MouseScrollDownAction=[!CommandMeasure mVolume "SetVolume -10"]
[Previous]
Meter=Image
ImageName=#@#Icon\MControl\Previous.png
X=((#IconSize#*5)+(#HiLite#*6))
Y=r
W=#IconSize#
H=#IconSize#
ToolTipText=Previous Track
LeftMouseUpAction=[!CommandMeasure mProgress "Previous"]
MouseActionCursor=0
[Play]
Meter=Image
ImageName=#@#Icon\MControl\[mStateButton].png
X=(#IconSize#+#HiLite#)r
Y=r
W=#IconSize#
H=#IconSize#
ToolTipText=Play/Pause
LeftMouseUpAction=[!CommandMeasure mProgress "PlayPause"]
DynamicVariables=1
MouseActionCursor=0
[Next]
Meter=Image
ImageName=#@#Icon\MControl\Next.png
X=(#IconSize#+#HiLite#)r
Y=r
W=#IconSize#
H=#IconSize#
ToolTipText=Next
LeftMouseUpAction=[!CommandMeasure mProgress "Next"]
MouseActionCursor=0
[Stop]
Meter=Image
ImageName=#@#Icon\MControl\Stop.png
X=(#IconSize#+#HiLite#)r
Y=r
W=#IconSize#
H=#IconSize#
ToolTipText=Stop
LeftMouseUpAction=[!CommandMeasure mProgress "Stop"]
MouseActionCursor=0
; [MeterL]
; Meter=Bar
; MeasureName=MeasureL
; X=(((#IconSize#)*5)+((#HiLite#)*6))
; Y=#HiLite#
; W=#HiLite#
; H=
; [MeterR]
; Meter=Bar
; MeasureName=MeasureR
; X=5
; Y=5
[TITLE]
Meter=String
MeasureName=mTitle
MeasureName2=mArtist
MeasureName3=mAlbum
MeasureName4=mPosition
MeasureName5=mDuration
MeasureName6=mYear
X=(((#IconSize#)*5)+((#HiLite#)*6))
Y=((#HiLite#)*2)+((#IconSize#)*1)
Text=%1#CRLF#%2#CRLF#%3 <%6>#CRLF#%5 %4
MeterStyle=TxtStyle
[SeekBarBG]
Meter=Bar
MeterStyle=styleBar
X=#HiLite#
Y=(((#IconSize#)*4)+(#HiLite#)*5)
W=((#SCREENAREAWIDTH#)-((#HiLite#)*2))
H=(2*(#HiLite#))
SolidColor=0,0,0,255
[SeekBar]
Meter=Bar
MeasureName=mProgress
BarOrientation=HORIZONTAL
X=r
Y=r
W=((#SCREENAREAWIDTH#)-((#HiLite#)*2))
H=(2*(#HiLite#))
and an animated screen shot. (This has a couple of other skins displaying with it...)
You do not have the required permissions to view the files attached to this post.