[Question] Can OBS record a single video file with multiple video tracks using different sources? #9948
Closed
gerardbosch
started this conversation in
General
Replies: 2 comments 10 replies
-
It's possible. LibOBS's API can handle this. But it may have not got a Graphics User Interface to operate. |
Beta Was this translation helpful? Give feedback.
5 replies
-
This sounds more likely to be a support request, and we are not currently accepting support requests on GitHub Discussions. Make sure you read any pinned posts on discussion boards before opening a new discussion. Please use our forums or Discord for further assistance. Thank you! |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, I couldn't find a clear answer to this, so I try to ask here :)
Some video containers like MKV (not sure if MP4) support multiple video tracks for the same file. Would it be possible to record multiple sources as different video tracks in the resulting file?
The goal
So I'd like to record both screens in a way that after the video is recorded, I can either play it and switch from one track to the other, or ideally, that the video player opens in 2 windows, where each window plays one track and I can lay it out side-by-side or put every window on each screen.
Any chance to achieve it either natively or scripting something from the shell? I'd also want to be able to automate and start the recording from command line with a script so it can run in background.
Thank you!
P.S. This idea could be extended to further sources, like third monitor or webcam as independent track.
EDIT:
I found a plugin that allows to record several sources: https://obsproject.com/forum/resources/source-record.1285/
susing this you can enable a filter on the second source to record on a separate file. Then using ffmpeg they can be joined as a multi-track video:
ffmpeg -i vid1 -i video2 -c copy -map 0 -map 1 dual-vid.mkv
This may help as starting point to wrap and run everything it from a bash script.
Beta Was this translation helpful? Give feedback.
All reactions