obs-cmd icon indicating copy to clipboard operation
obs-cmd copied to clipboard

'scene-item toggle' in tree structure

Open talon35 opened this issue 5 months ago • 3 comments

Hi,

first of all, thanks a lot for this project! I switched to Linux recently and this really keeps me going with my OBS and Stream Deck, so thanks for your work!

Now my issue might be more around a lack of knowledge regarding the desired syntax. In OBS, I have a source folder called "Cam", which contains a PNG frame, the actual webcam feed and some things more:

Image

I can toggle the whole folder with the 'scene-item toggle' prompt and it works like a charm:

obs-cmd -w obsws://localhost:4455/<passwd> scene-item toggle "Gaming" Cam

However, when I try to specifically toggle the visibility of one single item within my Cam folder, I fail to do so:

obs-cmd -w obsws://localhost:4455/<passwd> scene-item toggle "Gaming" CamFrame obs-cmd -w obsws://localhost:4455/<passwd> scene-item toggle "Gaming" Cam/Camframe

Am I missing the correct syntax (if yes, what is it?) or is toggling the visibility of an item only possible on the top layer? Would it be possible to add that feature?

Again, thanks a lot!

talon35 avatar Jul 13 '25 08:07 talon35

Hi, honestly I don't use that feature. Do you see a specif error? Have you tried obs-cmd -w obsws://localhost:4455/<passwd> scene-item toggle "Gaming" "Cam/Camframe"

grigio avatar Jul 14 '25 18:07 grigio

Hi, thanks for your reply.

Yes, I have. And to be sure, I just tried again. But it doesn't do the trick. I tried loads of other combinations of quotes, slashes and spaces, but to no avail.

Is there a command that lists all available source items? Maybe that gives me a hint.

talon35 avatar Jul 15 '25 15:07 talon35

Yes, nested scene items in folder are an issue but it seems that are passed correctly to the obs-websocket server

Scene Item: "toggle" "@desk-cam" "Group/cam-circle"
Error: Api { code: ResourceNotFound, message: Some("No scene items were found in the specified scene by that name or offset.") }

grigio avatar Jul 15 '25 20:07 grigio