Resource icon

Zoom and Follow 0.1.0

DexNeXuS

New Member
[zoom_and_follow_mouse.py] Traceback (most recent call last):

[zoom_and_follow_mouse.py] File "C:/Users/dex-8.DESKTOP-5OIUGUR/OneDrive/Desktop/OBS/OBS ASSETS/OBS Effects/obs-zoom-and-follow-master\zoom_and_follow_mouse.py", line 3, in <module>

[zoom_and_follow_mouse.py] from screeninfo import get_monitors # python -m pip install screeninfo

[zoom_and_follow_mouse.py] ModuleNotFoundError: No module named 'screeninfo'

This is all I am getting. I have Python 3.6.8. I have tried reinstalling this 3 times to see if that was the problem. I have downloaded the PiP things I needed but this just still is not working for me. any help would be appreciated greatly.
 

cognitiaclaeves

New Member
I'm really having a hard time getting this to work. I see it zooming in, but it seems off, somehow, more off the further right I am compared to the point that it shows. Then, when it zooms out, it doesn't contain the entire screen. I'm on a retina 16-inch (3072 × 1920) display , zooming to 1280 x 720. I can get the full screen back by going into filters and deleting the ZoomCrop filter ... One other thing ... I don't see any other option other than "Manual Monitor Size" for "Select monitor to use for the base for scaling" ... this is different than I've seen in youtube videos.
 

cognitiaclaeves

New Member
I'm really having a hard time getting this to work. I see it zooming in, but it seems off, somehow, more off the further right I am compared to the point that it shows. Then, when it zooms out, it doesn't contain the entire screen. I'm on a retina 16-inch (3072 × 1920) display , zooming to 1280 x 720. I can get the full screen back by going into filters and deleting the ZoomCrop filter ... One other thing ... I don't see any other option other than "Manual Monitor Size" for "Select monitor to use for the base for scaling" ... this is different than I've seen in youtube videos.

The issue appears to be the retina display and the python libs used. https://github.com/tryptech/obs-zoom-and-follow/issues/20#issuecomment-859408073 .
 
I tried the idea of just assigning a hotkey to only do a zoom in and out…. and yet panning is activated along with it.

Also, if I create a 150% zoom and a 200% zoom, anybody got an idea on how to go to 200% _from_ 150%, without zooming out to 100% first?
 
Let me ask it another way:
  • I have been able to set up a hotkey to toggle between 100% (1920x1080) to 150% (1280x720).
  • I have been able to set up a hotkey to toggle between 100% (1920x1080) to 200% (960x540).
  • But I cannot toggle between 150% and 200% -- instead, I have to from from 150% -> 100% -> 200% -> 100% -> 150%.

I want to toggle directly between 150% (1280x720) and 200% (960x540).

Any ideas, please?
 
Is it possible to add a feature that, when zoomed in and panning, that a source object would get moved when the cursor moves near that object, or at least when in the same quadrant, or even the same half, of the screen?
 

Sumaher4

New Member
Thanks for helping me out. I don't have much experience with Python but expected the link to download a .py file. (as happened with other python scripts I downloaded) However, it showed a page with code. I copy pasted it into a .txt file and changed the extension into .py.
This time, I get another error message:

[zoom_and_follow_mouse.py] Traceback (most recent call last):
[zoom_and_follow_mouse.py] File "C:/Program Files/obs-studio/data/obs-plugins/frontend-tools/scripts\zoom_and_follow_mouse.py", line 2, in <module>
[zoom_and_follow_mouse.py] from pynput.mouse import Controller # python -m pip install pynput
[zoom_and_follow_mouse.py] ModuleNotFoundError: No module named 'pynput'

Not sure what I should do now.
Hey man, I recently installed this and got it working thanks to a friend of mine who dwells in python.

You basically need to install the modules and to do that, Run CMD in Administrator mode and individually enter these lines


py -m pip install pynput

py -m pip install screeninfo

No $ sign and just py at the start. I got it working for me like that. Thought I should help you out as well.
 

Virtualdjlefave

New Member
Is there a way to make this work on, say, display 3? I'd like to keep my center monitor (display 2) as my main display, but in OBS, I use display 3 as my screen share.
 

NoobCre8r

New Member
Need help - Script stopped working.

Python 3.6 installed.

I had the script working last night, but I deleted the folder the script file itself was stored in (yeah... I'm an idiot). When I loaded OBS I got a script not found error. So I downloaded the script again, put it in a folder I'm not going to delete, went to tools > scripts and removed and re-added the script, then went into Hot Keys and re-added the hot key.... but it will not work. :-( Any guidance would be greatly appreciated.
 

paolo0166

New Member
Hi.

I'm a new OBS user: thank you for this wonderful app and for tons great tutorials.

I'm using OBS on MAC OS 12.1 Monteray.
The OS install python 2.7 but I have installed also Python 3.10.

For me, with LUA scripts all works fine but with python scripts no description appear and no activity works.

Can anyone help me?
I'm try to use zoom-and-follow_mouse.py script.

Below my screenshots.
Thank you!

1644262255635.png


1644262229006.png
 

keiraxlicious

New Member
first I had an issue with pywinctl not found and now it's win32api not found. I tried doing many installs force reinstalls and I can 't get it to work yet it says "" pywin32-304 is installed"" i am so confused...
 

evilTweedle

New Member
HI, Have I got the wrong version of something here installed in my python? I only have python 3.6.8 installed. and and managed to successfully install pynput, screeninfo and pywinctl after Alef fixed it for me.

These are the versions I have installed. If python needs to be 3.6.8 - are some of these other scripts perhaps too new?
1651839360681.png


My issue is that the script's obviously not working in OBS yet all the various python elements have installed correctly.
1651839447874.png
 

lokeshkapoor

New Member
Hi.

I'm a new OBS user: thank you for this wonderful app and for tons great tutorials.

I'm using OBS on MAC OS 12.1 Monteray.
The OS install python 2.7 but I have installed also Python 3.10.

For me, with LUA scripts all works fine but with python scripts no description appear and no activity works.

Can anyone help me?
I'm try to use zoom-and-follow_mouse.py script.

Below my screenshots.
Thank you!

View attachment 79894

View attachment 79893
Hey, please install python version 3.6
 

lokeshkapoor

New Member
HI, Have I got the wrong version of something here installed in my python? I only have python 3.6.8 installed. and and managed to successfully install pynput, screeninfo and pywinctl after Alef fixed it for me.

These are the versions I have installed. If python needs to be 3.6.8 - are some of these other scripts perhaps too new?
View attachment 83264

My issue is that the script's obviously not working in OBS yet all the various python elements have installed correctly.
View attachment 83265
1653909360951.png

They have removed the dependency of pynput and screeninfo from the code. So please install https://github.com/Kalmat/PyWinCtl/ to get it to work for you.
 

GM Rod

Member
Hello!
When I attempt to install this, I get this:
View attachment 84080
What gives?
Solved that, now getting this:
[zoom_and_follow_mouse.py] Traceback (most recent call last):
[zoom_and_follow_mouse.py] File "X:/OBS/Plugins/obs-zoom-and-follow-master\zoom_and_follow_mouse.py", line 386, in toggle_zoom
[zoom_and_follow_mouse.py] zoom.update_source_size()
[zoom_and_follow_mouse.py] File "X:/OBS/Plugins/obs-zoom-and-follow-master\zoom_and_follow_mouse.py", line 76, in update_source_size
[zoom_and_follow_mouse.py] self.window = pwc.getWindowsWithTitle(self.windows[data[2]][0])[0]
[zoom_and_follow_mouse.py] IndexError: list index out of range
 

shibetpc

New Member
Ubuntu Linux 21.10
Python 3.9.7
OBS 27.2.4

I add the script, but 'Zoom Source' box is empty even with 'refresh source list'.

However, I also don't have a 'Python' tab in the Scripts Window indicated in the install instructions. Any advice as to what I'm doing wrong?

thx
 

Cmac31

New Member
UPDATE: I got it working and I must say it's really useful. The fix was staring me in the face but only triggered for me when I saw another users comment elsewhere about ...put very simply the fix was just NOT use the same Hotkey for both the Zoom and the Follow functions. In fact it works with just a single hotkey for me as well on the Zoom. Hope that helps anyone experiencing a similar issue.
I’m having trouble getting it to work are you available to help? Ty
 
Top