▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
OBS script that can execute CLI commands when a scene is activated.
The original version of this script was written by marklagendijk
in Lua. marklagendijk’s version of the script called the CLI command
from Lua using os.execute(scene_command)
which opens a
command window that stayed open while the command is run. This got very
annoying when screen captuing and switching scenes, because the command
prompt would pop-up and be visible on stream!
To solve this, I rewrote the script in python and instead call the
CLI command using
subprocess.run(scene_command, shell=True)
. My version of
the script functions identically to the original, except for silent
execution (ie. no window pop-up) and a more detailed description.
Happy obs-ing!
Site generated 2024-09-20