Display every copy of duplicated stream in VLC

775 views Asked by At

I'm trying this simple thing in VLC 2.0.1 (I'm using Ubuntu 12.04 being run on a Virtual Machine):

vlc "/mnt/vlc/videos/all.ts" --sout="#duplicate{dst=display,dst=display}"

That means I'm trying to duplicate TS and display every copy of it. I thought that in this case VLC will create two independent display stream outs. But everytime I run the code I mentioned below I get one of the two following results:

  1. VLC creates two media player windows (one for each copy of TS), but video is shown only in one of them (usually with many artefacts). The second media player remains black or contains a static image: Ans this is the original file opened in VLC as usual (notice that there are no artifacts contained in it):
  2. VLC crushes with Signal SIGSEGV, Segmentation fault. A backtrace always end up with the following:

(gdb) bt #0 0x00007fffaa7f7935 in ?? () from /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1 #1 0x00007fffaa7f86b8 in ?? () from /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1 #2 0x00007fffaa56da69 in llvm::FPPassManager::runOnFunction(llvm::Function&) () from /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1 #3 0x00007fffaa56dbb1 in llvm::FunctionPassManagerImpl::run(llvm::Function&) () from /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1 #4 0x00007fffaa56dc91 in llvm::FunctionPassManager::run(llvm::Function&) () from /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1 #5 0x00007fffaa502da9 in LLVMRunFunctionPassManager () from /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1 #6 0x00007fffabe73511 in ?? () from /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so #7 0x00007fffabe7434b in draw_llvm_create_variant () from /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so #8 0x00007fffabe76375 in ?? () from /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so #9 0x00007fffabdf63c5 in ?? () from /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so #10 0x00007fffabdf1bfb in ?? () from /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so #11 0x00007fffabdf1f3c in draw_vbo () from /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so #12 0x00007fffabdcfc21 in ?? () from /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so #13 0x00007fffab46a6c3 in st_draw_vbo () from /usr/lib/x86_64-linux-gnu/dri/libgallium.so #14 0x00007fffaba10078 in vbo_exec_vtx_flush () from /usr/lib/x86_64-linux-gnu/dri/libdricore.so #15 0x00007fffaba0534c in ?? () from /usr/lib/x86_64-linux-gnu/dri/libdricore.so #16 0x00007fffaba0ddec in vbo_exec_FlushVertices () from /usr/lib/x86_64-linux-gnu/dri/libdricore.so #17 0x00007fffab9686f4 in _mesa_set_enable () from /usr/lib/x86_64-linux-gnu/dri/libdricore.so #18 0x00007fffad448bd4 in vout_display_opengl_Display (vgl=0x7fffdc65a950, source=<optimized out>) at opengl.c:704 #19 0x00007fffad4456ab in PictureDisplay (vd=<optimized out>, pic=0x7fffdc891590, subpicture=0x0) at xcb/glx.c:510 #20 0x00007ffff79237f9 in vout_display_Display (subpicture=0x0, picture=<optimized out>, vd=0x7fffdc4c89c8) at ../include/vlc_vout_wrapper.h:57 #21 ThreadDisplayRenderPicture (is_forced=true, vout=0x7fffb8050ee8) at video_output/video_output.c:1053 #22 ThreadDisplayPicture (vout=0x7fffb8050ee8, now=<optimized out>, deadline=<optimized out>) at video_output/video_output.c:1126 #23 0x00007ffff792490a in ThreadManage (postprocessing=0x7fffae8f8ea0, interlacing=0x7fffae8f8e70, deadline=0x7fffae8f8e90, vout=0x7fffb8050ee8) at video_output/video_output.c:1138 #24 Thread (object=0x7fffb8050ee8) at video_output/video_output.c:1581 #25 0x00007ffff76a8e9a in start_thread () from /lib/x86_64-linux-gnu/libpthread.so.0 #26 0x00007ffff71d173d in clone () from /lib/x86_64-linux-gnu/libc.so.6 #27 0x0000000000000000 in ?? ()

My question is how to make it all work? Or is it even possible to display every duplicated stream simultaneously that way?

2

There are 2 answers

2
denex On BEST ANSWER

You can broadcast with VLC server:

vlc movie_name --sout="#standard{mux=ts,dst=239.255.1.1:1234,access=udp}"

And then connect two VLC clients:

vlc udp://@239.255.1.1:1234

PS: Not sure about 239.255.1.1 address, but it works

0
Anton Serov On

Seems like this is a problem, provided by a Virtual Machine, since libLLVM that raises error is a Low Level Virtual Machine library. I tried the same query in OS Windows:

--sout="#duplicate{dst=display,dst=display}"

And it work just fine