obsws-python/examples/scene_rotate/__main__.py
onyx-and-iris b5b69de218 add support for toml config.
subject module added, supports callbacks.

events module added. Provides an event listener and callback trigger.

import isorted, code run through black.

toml section added to readme.

added a couple of examples.
2022-07-25 23:51:30 +01:00

20 lines
365 B
Python

import time
import obsstudio_sdk as obs
def main():
res = cl.GetSceneList()
scenes = reversed(tuple(d["sceneName"] for d in res["d"]["responseData"]["scenes"]))
for sc in scenes:
print(f"Switching to scene {sc}")
cl.SetCurrentProgramScene(sc)
time.sleep(0.5)
if __name__ == "__main__":
cl = obs.ReqClient()
main()