This commit is contained in:
oitsjustjose 2026-06-18 23:21:00 -05:00
commit 3967e285b6
27 changed files with 63 additions and 0 deletions

View file

@ -0,0 +1,16 @@
from subprocess import Popen
from pathlib import Path
cwd = Path(__file__).parent.parent.resolve()
print(f"cwd={cwd}")
def on_event(event):
if event == obspython.OBS_FRONTEND_EVENT_SCRIPTING_SHUTDOWN:
proc = Popen(["MonitorSwitcher.exe", "-load:Normal.xml"], cwd=cwd, shell=True)
_ = proc.communicate()
def script_load(settings):
obspython.obs_frontend_add_event_callback(on_event)
proc = Popen(["MonitorSwitcher.exe", "-load:Recording.xml"], cwd=cwd, shell=True)
_ = proc.communicate()