Open Farwalker3 opened 1 year ago
I have been able to run the following command (terminal in desktop mode) which would open an UDP stream from the Steam Deck in the local network, which OBS (on my main computer) opened and used for recording:
ffmpeg -f x11grab -s 1280x800 -i :0.0+0,0 -c:v libx264 -preset ultrafast -crf 18 -profile:v high -tune zerolatency -qp 0 -r 30 -maxrate 4000k -bufsize 500k -pix_fmt yuv420p -f mpegts 'udp://[remote machine IP]:6881?pkt_size=1316'
Delay on the recording was between 0.5 and 1 seconds.
Would it be feasible to use the command above in the Plugin backend service?
No, because gamemode does not use x11. You either need KMSGrab with ffmpeg (which needs special permissions) or need to figure out how to use pipewire as a source.
Probably something similar to this
https://gist.github.com/DirkHeinke/dfc14c8f0552212f1693
I don't think recorder is necessarily the right plugin to do this, but I'll look into making a twitch streaming plugin.
When your plugin does work, it manages to record every game I play. While OBS on the other hand only manages to capture a handful of certain games. I would like to have a plugin that allows me to connect to my twitch account, type in the name for my stream, and then with the click of a button start streaming my Steam Deck on Twitch.
Also, Amazon's Luna cloud gaming service has this functionality (streaming gameplay to twitch on device) built in. So, I think building it for the Steam Deck would be worthwhile.
(I'm also interested in working with you, because I would like to learn how to make my own steam deck plugins. It sounds like a lot of fun.)