It is currently November 15th, 2019, 3:50 am

WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

Plugins and Addons popular with the Community
User avatar
balala
Rainmeter Sage
Posts: 9052
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

balala » September 8th, 2017, 9:12 pm

tjhrulz wrote:Do you want the mp3 or the page? Because returning the URL the page is currently on is easy and I would be willing to add but returning the URL of the song itself for several of these is not possible with the current implementation because they have safeties to prevent getting that easily.
Just a simple idea on how a video can be downloaded from YouTube. I don't know if this can be implemented in Rainmeter (never tried), but if you want to download it, you have just to add a ss, before the youtube.com, in the URL. Eg to download the video with the https://www.youtube.com/watch?v=s-YsO84qYak URL, you have to open the https://www.ssyoutube.com/watch?v=s-YsO84qYak URL. This URL will open a site where the video can be downloaded.
Again, I never tried to implement this procedure in Rainmeter, but someone could try.
User avatar
StArL0rd84
Posts: 336
Joined: February 8th, 2015, 10:07 pm
Location: EU, Denmark.

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

StArL0rd84 » October 4th, 2017, 11:00 am

Not a big coder so when I followed the link to the extension to the master files on the github page I got really confused as to how to install it in my browser. But then I searched the official Chrome extension site for it and found it.
Maybe you should mention in your post to find it there or provide a link.
(#WorkTime# = 1 ? #Work# : ([mEnergyLoss:%] > 100 ? #SleepMode# : #Rainmeter#))
dvo
Posts: 657
Joined: February 7th, 2016, 6:08 am

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

dvo » October 4th, 2017, 1:24 pm

User avatar
StArL0rd84
Posts: 336
Joined: February 8th, 2015, 10:07 pm
Location: EU, Denmark.

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

StArL0rd84 » October 4th, 2017, 3:34 pm

REALLY awesome plugin man, been looking for this...

I am trying to make a clickable seekbar, but it has proven to be quite difficult because of the way the command works.
[!CommandMeasure "mProgress" "SetPosition +10"] works to skip 10% forward,
but i am using a invisible overlay over the bar to calculate the mouse position over the bar.
I then send that calculation to mProgress as shown below.
But that percentage i arrive at from my calculation is from the beginning of the bar to the point i am clicking at.
Not from the point of progression of the song to where i am clicking.
I guess what i am trying to say is that i might need a little help with the math ;P
Or even another approach to this.
But i feel like it should be possible some how.
seekbar.png

Code: Select all

[mProgress]
 Measure=Plugin
 Plugin=WebNowPlaying
 PlayerType=Progress

[Progress]
 Meter=Bar
 MeasureName=mProgress
 X=r
 Y=30r
 W=200
 H=6
 BarColor=255,255,255
 SolidColor=0,0,0,100
 BarOrientation=Horizontal
 
[mProgressFormula]
  Measure=Calc
 
[ProgressClickArea]
  Meter=Image
  X=r
  Y=-9r
  W=[Progress:W]
  H=24
  SolidColor=55,10,0,100
  LeftMouseDownAction=[!SetOption mProgressFormula Formula "(($MouseX$)/([Progress:W])*100)"][!Update]
  LeftMouseUpAction=[!CommandMeasure "mProgress" "SetPosition [mProgressFormula]"]
  DynamicVariables=1
SeekbarExample_1.0.rmskin
EDIT: So i managed to get the math right, but it just skips to the end or beginning of the song still. hmm
And if i spam the bar it some times work. double hmm

Code: Select all

[mProgressFormula]
 Measure=Calc
 OnChangeAction=[!CommandMeasure mProgress "SetPosition [mProgressFormula]"]
[ProgressClickArea]
 Meter=Image
 X=r
 Y=-9r
 W=[Progress:W]
 H=24
 SolidColor=55,10,0,100
 LeftMouseUpAction=[!SetOption mProgressFormula Formula "((($MouseX$)/([Progress:W])*100)-[mProgress])"]
 DynamicVariables=1
You do not have the required permissions to view the files attached to this post.
(#WorkTime# = 1 ? #Work# : ([mEnergyLoss:%] > 100 ? #SleepMode# : #Rainmeter#))
User avatar
CyberTheWorm
Posts: 667
Joined: August 22nd, 2016, 11:32 pm
Location: Surrey, B.C., Canada

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

CyberTheWorm » October 5th, 2017, 4:19 pm

Try adding this to your skin

Code: Select all


[Progress]
 Meter=Bar
 MeasureName=mProgress
 X=r
 Y=30r
 W=200
 H=6
 BarColor=255,255,255
 SolidColor=0,0,0,100
 BarOrientation=Horizontal
LeftMouseUpAction=[!CommandMeasure WebNowPlaying "SetPosition $MouseX:%$"]
Have not used the WebNowPlaying plugin but the following mouse action does work for the NowPlaying plugin
The only source of knowledge is experience. Albert Einstein
Deviant Art Page
User avatar
eclectic-tech
Rainmeter Sage
Posts: 3597
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

eclectic-tech » October 5th, 2017, 4:28 pm

If you check the log, you should see this message:
Nothing to see here... had the previous version of the plugin :uhuh:
Last edited by eclectic-tech on October 5th, 2017, 7:12 pm, edited 1 time in total.
User avatar
StArL0rd84
Posts: 336
Joined: February 8th, 2015, 10:07 pm
Location: EU, Denmark.

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

StArL0rd84 » October 5th, 2017, 4:33 pm

CyberTheWorm wrote:Have not used the WebNowPlaying plugin but the following mouse action does work for the NowPlaying plugin
Wow! Thanks, $MouseX:%$ totally works.
And it's so simple too, cleans up my code a lot.

Here's my almost finished skin:
Applied the same trick to the volume bar :)
almostfinished.png
YoutubePlayer_1.0.rmskin
You do not have the required permissions to view the files attached to this post.
(#WorkTime# = 1 ? #Work# : ([mEnergyLoss:%] > 100 ? #SleepMode# : #Rainmeter#))
User avatar
CyberTheWorm
Posts: 667
Joined: August 22nd, 2016, 11:32 pm
Location: Surrey, B.C., Canada

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

CyberTheWorm » October 5th, 2017, 7:25 pm

StArL0rd84 wrote:Wow! Thanks, $MouseX:%$ totally works.
And it's so simple too, cleans up my code a lot.

Here's my almost finished skin:
Applied the same trick to the volume bar :)
That will only work for a horizontal bar, just a FYI, vertical bar gets weird.
Just paying back for all the help I got ;-)
The only source of knowledge is experience. Albert Einstein
Deviant Art Page
User avatar
fonpaolo
Moderator
Posts: 1343
Joined: April 11th, 2013, 8:08 pm
Location: Italy

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

fonpaolo » October 6th, 2017, 4:11 pm

CyberTheWorm wrote:That will only work for a horizontal bar, just a FYI, vertical bar gets weird.
Just paying back for all the help I got ;-)
Maybe you say it gets weird because it's inverted, when using with a vertical bar?
Use the formula 100-$MouseY:%$ *

*Since $MouseY:%$ is calculated from top to bottom, but the bar increases from bottom to top.
User avatar
CyberTheWorm
Posts: 667
Joined: August 22nd, 2016, 11:32 pm
Location: Surrey, B.C., Canada

Re: WebNowPlaying plugin. Supports sites like Youtube and Soundcloud

CyberTheWorm » October 6th, 2017, 4:56 pm

fonpaolo wrote:Maybe you say it gets weird because it's inverted, when using with a vertical bar?
Use the formula 100-$MouseY:%$ *

*Since $MouseY:%$ is calculated from top to bottom, but the bar increases from bottom to top.
Yes that is what I meant :D
The only source of knowledge is experience. Albert Einstein
Deviant Art Page