1.9 KiB
obsdc
OBS control from D-Bus messages
Send a D-Bus signal to perform an operation with src/obsdc-signal, which takes a single operation name
as an argument.
Operations
See Op for a list of operations.
Configuration
Configuration is in $XDG_CONFIG_HOME/net.eksb.obsdc/config.properties
Configuration options
host- OBS websocket host (default:localhost)port- OBS websocket port (default:4455)password- OBS websocket password (required)
Build
gradle build
Run
tar xf build/distributions/obsdc.tarcd obsdc- Create config file. See [#Configuration].
bin/obsdcbin/obsdc-signalto send an op.
Code
Start at Main.
Obs is a wrapper around obs-websocket-java that handles reconnects and queuing operations until the websocket it ready.
OpRunner has the logic to run Ops
using an Obs.
DBus listens for the D-Bus signals and calls OpRunner.
History/Rationale
I usually code on a 4k monitor in portrait mode. To show what I am doing on video calls, I use OBS to share that monitor, but it is a 2160x4096 source in a 1920x1080 scene.
I have a macropad with two knobs.
My window manager is configured to call obsdc-signal with PAN_UP/PAN_DOWN for the
keys emitted by one knob and PAN_RIGHT/PAN_LEFT for the keys emitted by the other knob.
The regular keys on the macropad are mapped to the other actions.
So now I can quickly control what people can see without having to focus (or even make visible) the OBS window.