VLC Current Song

OBS Python VLC Current Song 2018-04-01

Hawezo

New Member
Hawezo submitted a new resource:

VLC Current Song - Displays the name of VLC's now playing in a Text Source.

THIS SCRIPT IS AN ENHANCED VERSION OF TYPHER88'S VLC NOW PLAYING.

Latest version:
0.1
Python version: 3.6+

This is a python script that will update a GDI+ Text Source in OBS Studio with the name of the song currently played in VLC.
You may follow the instructions below for it to work properly.

Installation instructions:...

Read more about this resource...
 

CoMmAnDrX

New Member
Got the VLC side working but cannot get script to show anything. When I query this http://localhost:8080/requests/status.xml I do get the proper output.

But after installing script I see this under description is shows 'No Properties. Available'

Also from script log:
Code:
[current_song.py] Traceback (most recent call last):


[current_song.py]   File "C:/Program Files (x86)/obs-studio/data/obs-plugins/frontend-tools/scripts\current_song.py", line 43, in <module>


[current_song.py]     import os, time, datetime, requests, codecs


[current_song.py] ModuleNotFoundError: No module named 'requests'

I have Python ver. 3.6 x64 installed, only issue I had was installing PIP

Code:
C:\Windows\system32>pip install requests

'pip' is not recognized as an internal or external command,

operable program or batch file.

Not sure what I'm doing wrong here.
 

Attachments

  • Current  Song.png
    Current Song.png
    115.1 KB · Views: 274

CoMmAnDrX

New Member
UPDATE:

OK I got Python working and the script is now working. But when I run the script it takes my framerate down to 0.97 FPS

CPU Usage shows 3.1% and .006 FPS

When I remove the script it shoots right up to 30FPS
 

Quizicalgin

New Member
Exactly what is requests? I've tried googling "python requests" but I'm not finding any pages with installtion files for it, and I don't remember seeing it as an option for the python install itself.

Edit: Ok I found it but I have no idea what I'm doing? How the hell do I install this thing? I only get that pip install requests isn't valid.

https://www.youtube.com/watch?v=cGW70Hc0W4M

For anyone that couldnt figure it out either.

Edit: Ok so now OBS reads the scripts, but now it doesnt even seem to work. Can it be seen working in previews or only when streaming? Adding screenshots for the settings. I'm 99% sure I have them right, so I'm not sure why it isnt working.I've got VLC up trying to test it but its just refusing to work.

LAST Edit: I'm a moron. I didn't have the http://localhost:8080/requests/status.xml in the url of the script settings
 

Attachments

  • Screenshot_462.png
    Screenshot_462.png
    32.2 KB · Views: 180
  • Screenshot_463.png
    Screenshot_463.png
    35.1 KB · Views: 198
  • Screenshot_464.png
    Screenshot_464.png
    31.1 KB · Views: 204
  • Screenshot_465.png
    Screenshot_465.png
    20.8 KB · Views: 203
Last edited:

mrbeefy87

New Member
I have done everything as it says but when I load the script it has "no properties" so I can't do anything else.
What must i do - what have I done wrong?
 

Methanoid

New Member
hmm ok, ive come back to this on a 2nd pc, when i install the script and try to access it, in the OBS Scripts page, under Description it says "no properties available" instead of what is shown in the example picture, any idea whats gone wrong?

EDIT: I see now, only Python 3.6x works, with 3.7x the script is non functional.

As mentioned above, the script works but it totally destroys your CPU, the script seems to be constantly hammering OBS and everything grinds to a slow laggy mess, any way to fix this?
 
Last edited:

Gabriell

New Member
Hello Everybody,

it does'nt work. :(
what is it which I know nothing?
 

Attachments

  • problem.JPG
    problem.JPG
    39.9 KB · Views: 84
Last edited:

Methanoid

New Member
Still cant use this script very well, again provided you are using python 3.6x instead of newer it works fine, but only fine "IF" VLC is active, if VLC is not running then FPS drops to insane low speeds and the preview pane is just a world of lag even though the CPU useage is incredibly low, in my case 1.7%, run VLC and bam it pops back up to 60fps instantly and all is well.

So is there something in the script that should be checking for VLC running but currently is not and ends up causing the lag? and can this be fixed, its pretty much the only downside to this good script.
 

prodbyshad

New Member
Yeah, I would suggest if you want to make sure this goes smoothly for people, do a video tutorial. I have followed your instructions only to get more problems than expected. This script/instructions do not work.
 
Top