Resource icon

OBS Studio mouse cursor skin 2.1.1

upgradeQ

Member
upgradeQ submitted a new resource:

OBS Studio cursor skin - Change cursor to image or video source.

Selected source will follow mouse pointer. It will update position of the source according to mouse movement.

Usage:
Create source with desired cursor. In scripts select that source(name).Tweak refresh rate (max 60 FPS aka 15 ms ), test it press Start, press Stop when you are done.
Installation:
Make sure your OBS Studio supports scripting scripting
Download and extract source code from...

Read more about this resource...
 

upgradeQ

Member
upgradeQ updated OBS Studio mouse cursor skin with a new update entry:

Added crop auto update

Crop auto update

Shape of higlight , shape of zoom etc...
  • Create 2 display captures.
  • Create crop filter with this name: cropXY.
  • Check relative.
  • Set Width and Height to relatively small numbers e.g : 64x64 .
  • Image mask blend + color correction might be an option too.
  • Run script,select this source as cursor source , check Update crop, click start.

Read the rest of this update entry...
 

wyllian

New Member
Please, could you help me?


OBS Studio 25.0.8 64bit, SO: Ubuntu 20.04.1 LTS with mouse package (sudo pip3 install mouse and sudo pip2 install mouse).

Screenshot_20200910_162943.png


Error:

Screenshot_20200910_162745.png
 

upgradeQ

Member
Please, could you help me?


OBS Studio 25.0.8 64bit, SO: Ubuntu 20.04.1 LTS with mouse package (sudo pip3 install mouse and sudo pip2 install mouse).

View attachment 60854

Error:

View attachment 60853
It is problem with library, for some reason it's not working inside obs , I also tried using sudo obs from terminal, same error, however mouse library working fine if used outside of obs. I've tested pynput and it works (install pip3 install pynput --user ). So you need to change the line from mouse import get_position # python -m pip install mouse to
Python:
from pynput.mouse import Controller
c = Controller()
get_position = lambda : c.position
 

upgradeQ

Member
With one display selected, this should be straightforward - just check if it in selected space by offsetting to selected monitor coordinates and move sceneitem accordingly. With multi monitors there are orientations, different placings, etc. there is related PR with PyWinCtl package https://github.com/tryptech/obs-zoom-and-follow/pull/32 it handles MacOS support better and currently under review.
If you have tested and working solution, there is a way to contribute
 

Rediflow

New Member
I have upgraded to OBS 28 which finally allowed to update the python version higher than 3.6.
I switched to python 3.10 with all my other scripts running fine, just this one does not do the job anymore.
Script log says:


[mouse_skin_obs.py] Traceback (most recent call last):

[mouse_skin_obs.py] File "C:\Program Files/obs-studio/data/obs-plugins/frontend-tools/scripts/OBS-Studio-Cursor-skin-2.1.1\mouse_skin_obs.py", line 4, in <module>

[mouse_skin_obs.py] from pynput.mouse import Controller # python -m pip install pynput

[mouse_skin_obs.py] ModuleNotFoundError: No module named 'pynput'

any suggestions how to fix it or any updates planed?
 

upgradeQ

Member
I have upgraded to OBS 28 which finally allowed to update the python version higher than 3.6.
I switched to python 3.10 with all my other scripts running fine, just this one does not do the job anymore.
Script log says:




any suggestions how to fix it or any updates planed?
You could try to move pynput directory from site packages folder of your 3.6 Python to path where mouse_skin_obs.py is, or install as comment on that line of code suggests python -m pip install pynput , you would run that command from terminal in the path where you python.exe resides which you set as Python path in OBS Studio scripting submenu. Keep in mind that this package might not work with new version of Python. ModuleNotFoundError - is path / wrong installation problem, trivial to fix.
 

greenscreen

New Member
Hi, I'm wondering if there's someone here who could help me, cause I'm totally green about all this script stuff (I'm just a mathematician, I can solve a math problem for you in return :D). I'm using a 64-bit Windows 10 and OBS Studio 27.2.4 and I'd like to highlight my pen cursor (MS Surface pen). About a million Win apps doesn't work for the pen. My last hope is this OBS script, but I totally don't know what I should do to start this script (I really don't have a single idea, I don't understand what is written in this resource descriptions). I want to record films for YT and I also want to make live transmissions (teaching maths).
Can you tell me, what to do, or is there a place in this world where it's all written in a very, very simple way? Thanks!
 

upgradeQ

Member
Hi, I'm wondering if there's someone here who could help me, cause I'm totally green about all this script stuff (I'm just a mathematician, I can solve a math problem for you in return :D). I'm using a 64-bit Windows 10 and OBS Studio 27.2.4 and I'd like to highlight my pen cursor (MS Surface pen). About a million Win apps doesn't work for the pen. My last hope is this OBS script, but I totally don't know what I should do to start this script (I really don't have a single idea, I don't understand what is written in this resource descriptions). I want to record films for YT and I also want to make live transmissions (teaching maths).
Can you tell me, what to do, or is there a place in this world where it's all written in a very, very simple way? Thanks!
Here is the link to specific version of Python for your OBS Studio version download and set path where you've installed it
Once it is installed, insturctions should be easy to follow
I do not have tablet nor pen , If there is a Python library which supports them its gonna be easy to add that to program. If your pen moves the mouse cursor it might work with no changes.
 

greenscreen

New Member
Here is the link to specific version of Python for your OBS Studio version download and set path where you've installed it
Once it is installed, insturctions should be easy to follow
I do not have tablet nor pen , If there is a Python library which supports them its gonna be easy to add that to program. If your pen moves the mouse cursor it might work with no changes.
Thank you for your answer! I've installed Python and I set path in OBS where it is installed. I'm ready for further instructions:)).
 

upgradeQ

Member
Thank you for your answer! I've installed Python and I set path in OBS where it is installed. I'm ready for further instructions:)).
There is no need to install Python into OBS Studio directory as you might reinstall or delete the app later, better to create a new folder and Python install there. Just saying. To complete setup download and unzip script to some permanent path e.g folder on your homescreen, so that it will have less chance to accidentally be deleted.Next, open Explorer in path where you have Python 3.6 installed, click on that path address ( it will be highlighted in blue) type cmd , then press enter , then proceed to install pynput package with pip like this: python -m pip install pynput
In scripting submenu click + sign add unzipped script, the rest of insturctions are in the descriptions of this resources and on GitHub.
 

tenes9999

New Member
i use obs 27.24,and i upload was python 3.6,and the mouse skin obs dont work
Script log :

mouse_skin_obs.py", line 4, in <module>

[mouse_skin_obs.py] from pynput.mouse import Controller #python -m pip install pynput

[mouse_skin_obs.py] ModuleNotFoundError: No module named 'pynput'
 
Top