- Is it possible to create a Mosaic (2x2, 4 videos) without transcoding?
For the initial phase of testing, I simply wanna see if it's working. I don't wanna set up a Mosaic & not see the output. Most Mosaic scripts just STREAM out into the ether, without any indication of how to VIEW what's going on.
So, the harder question for this topic... (besides just "how the hell do you get Mosaic to work AT ALL?")
- Can someone post the most-simple example, using VLC 2.0.x, of a 2x2 Mosaic, that displays the Mosaic on the screen & doesn't (necessarily) stream anywhere...& uses NO transcoding or as LITTLE transcoding as possible (I wanna preserve the original videos as much as possible, without quality loss & without taxing the CPU for unnecessary transcoding)
I'd actually like 2 examples: Example 1 would just be 1 VLC process creating & displaying the Mosaic (call this "debug mode"). Example 2 would be 2 VLC processes (on the same computer), 1 streaming (somewhere) & NOT displaying its output & another VLC displaying the stream created by the other process. I've read UDP streaming is "legacy", so use whatever streaming is "current" or "best". RTP? The stream does not need to leave the computer.
Also, the examples should be robust enough, that I can change any of the "inputs" for the Mosaic (video1, video2, video3, video4...or the bg) & not need to rewrite the whole script. Most of my inputs are images (for testing), so they need an "image-duration" applied to keep them running. However, even tho my inputs are images...that is ONLY for testing, so the Mosaic should transfer audio!...& the user should have some way of switching to that audio (in my tests so far, I can't). The Mosaic should transfer/accept/include ANYTHING in the original source...for example, if video1 has 5 audio tracks, the Mosaic should too...likewise, if video1 has 5 audio tracks & video 2, 3 & 4 have 1 & the background has 0, then the Mosaic should have 8 audio tracks (that the user can choose from) -- or perhaps 9, the 9th would be a mix of all the other tracks (the audio of videos 1, 2, 3 & 4 all mixed together & happening at once {you are seeing 4 videos in a Mosaic, you should hear them all too! [right?]}). Speaking of which, I'd like the same for video: I'd like the Mosaic to include 1 Mosaic video track (all 4 videos+the bg {"the Mosaic"}), plus 1 extra, separate, video track for each input: with 4 videos the Mosaic should have 5 or 6 video tracks (the Mosaic, the 4 separate input video tracks, plus perhaps the background track as another video track). The user could switch between Video tracks using the normal VLC menus. Those separate video tracks should have NO transcoding at all on them, pass thru the original signal. Transcoding should not be involved anywhere, except where extremely necessary...if it is necessary, then I want the most CPU-loving, least CPU-intensive type of transcoding (my current computer can't handle much).
More questions: Does Mosaic = VLM? I saw the VLM forum, but it says it's "a stream scheduler"...I'd like to ignore VLM, for now, if that's not 100% necessary for Mosaic. I understand that it might be necessary & that's fine (I even use --vlm-conf below). If Mosaic is 100% intertwined with VLM, then please move this topic there.
Why is Mosaic soo hard? It would be much simpler for me to just run 4 (or 5, including the bg) VLC processes & move & size the windows to fake a Mosaic. Why is playing 4 videos in 1 VLC so hard?
To get started, here's my most-recent test...
- 2x2_mosaic.conf...
Code: Select all
new video1 broadcast enabled setup video1 option image-duration=119 setup video1 input "T:\VLC - Mosaic\Pix\VLC - Mosaic - Video 1.640x360.png" setup video1 output #duplicate{dst=mosaic-bridge{id=1,width=640,height=360},select=video,dst=bridge-out{id=1},select=audio} new video2 broadcast enabled setup video2 option image-duration=119 setup video2 input "T:\VLC - Mosaic\Pix\VLC - Mosaic - Video 2.640x360.png" setup video2 output #duplicate{dst=mosaic-bridge{id=2,width=640,height=360},select=video,dst=bridge-out{id=2},select=audio} new video3 broadcast enabled setup video3 option image-duration=119 setup video3 input "T:\VLC - Mosaic\Pix\VLC - Mosaic - Video 3.640x360.png" setup video3 output #duplicate{dst=mosaic-bridge{id=3,width=640,height=360},select=video,dst=bridge-out{id=3},select=audio} new video4 broadcast enabled setup video4 option image-duration=119 setup video4 input "T:\VLC - Mosaic\Pix\VLC - Mosaic - Video 4.640x360.png" setup video4 output #duplicate{dst=mosaic-bridge{id=4,width=640,height=360},select=video,dst=bridge-out{id=4},select=audio} new bg broadcast enabled setup bg option image-duration=-1 setup bg input "T:\VLC - Mosaic\Pix\VLC - Mosaic - Background.1280x720.png" setup bg output #transcode{sfilter=mosaic,vcodec=mp4v,vb=4000}:bridge-in{id-offset=100}:display control bg play control video1 play control video2 play control video3 play control video4 play
Code: Select all
start "" "C:\Program Files\VLC\2.0.5\vlc.exe" -vvv --color --vlm-conf=2x2_mosaic.conf --mosaic-width=1280 --mosaic-height=720 --mosaic-keep-picture --mosaic-rows=2 --mosaic-cols=2 --mosaic-position=1 --mosaic-order=1,2,3,4 --file-logging
In fact, change EVERYTHING about my code to "do it the right way"...that was only mashed together from years of examples all over the internet. Do I even need to use "#duplicate" in "setup video1 output"?...or can it be done another, better, way? Specifically, I need help on the "output" syntax...that weird "#duplicate" & "#transcode" syntax (& "#whatever" else might be possible)...are there any current Docs about that syntax? What is possible? What is CPU-intensive?