oaubert / python-vlc

Python vlc bindings
GNU Lesser General Public License v2.1
387 stars 111 forks source link

libvlc_vlm_add_broadcast - cannot find video decoder - cannot reproduce cvlv behaviour #167

Open gnthibault opened 3 years ago

gnthibault commented 3 years ago

Dear all,

First, thank you for those bindings, in case they work, they'll be incredibly useful for me.

Up to recently, I was using the following command (that was working perfectly) in order to broadcast a rtsp h264 stream onto http protocol for web embeding with the following exact command:

cvlc -v rtsp://user:password@192.168.0.16 --sout='#transcode{vcodec=theo,vb=800,acodec=vorb,ab=128,channels=2,samplerate=44100,scodedec=none}:http{dst=:8080/webcam.ogg}'

Now, I have tried, what I think should be the exact translation of the up-above command with python-vlc version 3.0.11115 :

import vlc
import time

instance = vlc.Instance('--verbose 2'.split())
stream_name = "webcam".encode()
rtsp_url = "rtsp://user:password@192.168.0.16".encode()

ret = vlc.libvlc_vlm_add_broadcast(
    p_instance=instance,
    psz_name=stream_name,
    psz_input=rtsp_url,
    psz_output=f"#transcode{{vcodec=theo,vb=800,acodec=vorb,ab=128,channels=2,samplerate=44100}}:http{{dst=:8080/webcam.ogg}}".encode(),
    i_options=0,
    ppsz_options=[],
    b_enabled=True,
    b_loop=False
)
assert (ret == 0)
vlc.libvlc_vlm_play_media(instance, stream_name)

time.sleep(60)

Unfortunately, it looks like the main error relates to the following lines in the logs (full logs down below)

[00007f5970000e00] main stream output debug: adding a new sout input for h264 (sout_input: 0x7f59580010c0) [00007f597001f3c0] stream_out_transcode stream out debug: creating video transcoding from fcc=h264' to fcc=theo' [00007f59580013c0] main generic debug: looking for video decoder module matching "any": 16 candidates [00007f59580013c0] main generic warning: cannot load module /usr/lib/x86_64-linux-gnu/vlc/plugins/codec/libsvgdec_plugin.so' (/usr/lib/x86_64-linux-gnu/librsvg-2.so.2: undefined symbol: cairo_tag_end) [00007f59580013c0] main generic warning: cannot load module/usr/lib/x86_64-linux-gnu/vlc/plugins/codec/libavcodec_plugin.so' (/usr/lib/x86_64-linux-gnu/librsvg-2.so.2: undefined symbol: cairo_tagend) **[00007f59580013c0] main generic debug: no video decoder modules matched [00007f597001f3c0] stream_outtranscode stream out error: cannot find video decoder** [00007f597001f3c0] stream_out_transcode stream out error: cannot create video chain [00007f5970000e00] main stream output warning: new sout input failed (sout_input: 0x7f59580010c0) [00007f5970037450] [Media: webcam] main decoder error: cannot create packetizer output (h264) [000056282a4761e0] [Media: webcam] main input debug: Buffering 52% [000056282a4761e0] [Media: webcam] main input debug: Buffering 61% [000056282a4761e0] [Media: webcam] main input debug: Buffering 76% [000056282a4761e0] [Media: webcam] main input debug: Buffering 77% [000056282a4761e0] [Media: webcam] main input debug: Buffering 86% [000056282a4761e0] [Media: webcam] main input debug: Buffering 94% [000056282a4761e0] [Media: webcam] main input debug: Stream buffering done (1028 ms in 1040 ms) [00007f5970037450] [Media: webcam] main decoder error: buffer deadlock prevented [000056282a4761e0] [Media: webcam] main input debug: Decoder wait done in 0 ms [00007f595c00b390] faad generic warning: decoded zero sample

It is quite surprising, than, when launching the equivalent cvlc command in bash, it works successfully and I get the following except:

[00007efe1c000ee0] main stream output debug: adding a new sout input for h264 (sout_input: 0x7efe0c0010c0) [00007efe1c4c9f40] stream_out_transcode stream out debug: creating video transcoding from fcc=h264' to fcc=theo' [00007efe0c0013a0] main generic debug: looking for video decoder module matching "any": 16 candidates [00007efe0c0013a0] avcodec generic debug: using ffmpeg Lavc58.54.100 [00007efe0c0013a0] avcodec generic debug: CPU flags: 0x000853db [00007efe0c0013a0] avcodec generic debug: allowing 6 thread(s) for decoding [h264 @ 0x7efe0c054780] nal_unit_type: 7(SPS), nal_ref_idc: 3 [h264 @ 0x7efe0c054780] nal_unit_type: 8(PPS), nal_ref_idc: 3 [00007efe0c0013a0] avcodec generic debug: codec (h264) started [00007efe0c0013a0] avcodec generic debug: using frame thread mode with 6 threads [00007efe0c0013a0] main generic debug: using video decoder module "avcodec" [00007efe0c001770] main encoder debug: looking for encoder module matching "any": 22 candidates [00007efe0c001770] main encoder debug: using encoder module "theora" [00007efe0c001770] main encoder debug: removing module "theora"

I checked for some examples and documentation here and here but I did not eventually managed to fix the problem.

I case it helps, here is the content of ls /usr/lib/x86_64-linux-gnu/vlc/plugins/codec/ :

liba52_plugin.so libcc_plugin.so libfaad_plugin.so liblpcm_plugin.so librtpvideo_plugin.so libspudec_plugin.so libt140_plugin.so libvaapi_plugin.so libzvbi_plugin.so libadpcm_plugin.so libcdg_plugin.so libflac_plugin.so libmpg123_plugin.so libscte18_plugin.so libstl_plugin.so libtextst_plugin.so libvorbis_plugin.so libaes3_plugin.so libcvdsub_plugin.so libg711_plugin.so liboggspots_plugin.so libscte27_plugin.so libsubsdec_plugin.so libtheora_plugin.so libwebvtt_plugin.so libaom_plugin.so libdca_plugin.so libjpeg_plugin.so libomxil_plugin.so libsdl_image_plugin.so libsubstx3g_plugin.so libttml_plugin.so libx26410b_plugin.so libaraw_plugin.so libddummy_plugin.so libkate_plugin.so libopus_plugin.so libshine_plugin.so libsubsusf_plugin.so libtwolame_plugin.so libx264_plugin.so libaribsub_plugin.so libdvbsub_plugin.so liblibass_plugin.so libpng_plugin.so libspdif_plugin.so libsvcdsub_plugin.so libuleaddvaudio_plugin.so libx265_plugin.so libavcodec_plugin.so libedummy_plugin.so liblibmpeg2_plugin.so librawvideo_plugin.so libspeex_plugin.so libsvgdec_plugin.so libvaapi_drm_plugin.so libxwd_plugin.so

[000056282a2bada0] main libvlc debug: VLC media player - 3.0.9.2 Vetinari [000056282a2bada0] main libvlc debug: Copyright © 1996-2020 the VideoLAN team [000056282a2bada0] main libvlc debug: revision 3.0.9.2-0-gd4c1aefe4d [000056282a2bada0] main libvlc debug: configured with ./configure '--build=x86_64-linux-gnu' '--prefix=/usr' '--includedir=${prefix}/include' '--mandir=${prefix}/share/man' '--infodir=${prefix}/share/info' '--sysconfdir=/etc' '--localstatedir=/var' '--disable-silent-rules' '--libdir=${prefix}/lib/x86_64-linux-gnu' '--runstatedir=/run' '--disable-maintainer-mode' '--disable-dependency-tracking' '--disable-debug' '--config-cache' '--disable-update-check' '--enable-fast-install' '--docdir=/usr/share/doc/vlc' '--with-binary-version=3.0.9.2-1' '--enable-a52' '--enable-aa' '--enable-aom' '--enable-aribsub' '--enable-avahi' '--enable-bluray' '--enable-caca' '--enable-chromaprint' '--enable-chromecast' '--enable-dbus' '--enable-dca' '--enable-dvbpsi' '--enable-dvdnav' '--enable-faad' '--enable-flac' '--enable-fluidsynth' '--enable-freetype' '--enable-fribidi' '--enable-gles2' '--enable-gnutls' '--enable-harfbuzz' '--enable-jack' '--enable-kate' '--enable-libass' '--enable-libmpeg2' '--enable-libxml2' '--enable-lirc' '--enable-live555' '--enable-mad' '--enable-matroska' '--enable-mod' '--enable-mpc' '--enable-mpg123' '--enable-mtp' '--enable-ncurses' '--enable-notify' '--enable-ogg' '--enable-opus' '--enable-pulse' '--enable-qt' '--enable-realrtsp' '--enable-samplerate' '--enable-sdl-image' '--enable-sftp' '--enable-shine' '--enable-shout' '--enable-skins2' '--enable-sndio' '--enable-soxr' '--enable-spatialaudio' '--enable-speex' '--enable-srt' '--enable-svg' '--enable-svgdec' '--enable-taglib' '--enable-theora' '--enable-twolame' '--enable-upnp' '--enable-vdpau' '--enable-vnc' '--enable-vorbis' '--enable-x264' '--enable-x265' '--enable-zvbi' '--with-kde-solid=/usr/share/solid/actions/' '--disable-crystalhd' '--disable-d3d11va' '--disable-decklink' '--disable-directx' '--disable-dsm' '--disable-dxva2' '--disable-fdkaac' '--disable-fluidlite' '--disable-freerdp' '--disable-goom' '--disable-gst-decode' '--disable-libtar' '--disable-macosx' '--disable-macosx-avfoundation' '--disable-macosx-qtkit' '--disable-microdns' '--disable-mfx' '--disable-opencv' '--disable-projectm' '--disable-schroedinger' '--disable-sparkle' '--disable-telx' '--disable-vpx' '--disable-vsxu' '--disable-wasapi' '--enable-alsa' '--enable-dc1394' '--enable-dv1394' '--enable-libplacebo' '--enable-linsys' '--enable-nfs' '--enable-omxil' '--enable-udev' '--enable-v4l2' '--enable-wayland' '--enable-libva' '--enable-vcd' '--enable-smbclient' '--disable-oss' '--enable-mmx' '--enable-sse' '--disable-neon' '--disable-altivec' 'build_alias=x86_64-linux-gnu' 'CFLAGS=-g -O2 -fdebug-prefix-map=/build/vlc-sUx6OI/vlc-3.0.9.2=. -fstack-protector-strong -Wformat -Werror=format-security ' 'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now -Wl,--as-needed' 'CPPFLAGS=-Wdate-time -D_FORTIFY_SOURCE=2' 'CXXFLAGS=-g -O2 -fdebug-prefix-map=/build/vlc-sUx6OI/vlc-3.0.9.2=. -fstack-protector-strong -Wformat -Werror=format-security ' 'OBJCFLAGS=-g -O2 -fdebug-prefix-map=/build/vlc-sUx6OI/vlc-3.0.9.2=. -fstack-protector-strong -Wformat -Werror=format-security' [000056282a2bada0] main libvlc debug: searching plug-in modules [000056282a2bada0] main libvlc debug: loading plugins cache file /usr/lib/x86_64-linux-gnu/vlc/plugins/plugins.dat [000056282a2bada0] main libvlc debug: recursively browsing /usr/lib/x86_64-linux-gnu/vlc/plugins' [000056282a2bada0] main libvlc debug: plug-ins loaded: 521 modules [000056282a3a4ed0] main logger debug: looking for logger module matching "any": 4 candidates [000056282a3a4ed0] main logger debug: using logger module "console" [000056282a2bada0] main libvlc debug: translation test: code is "C" [000056282a461cc0] main keystore debug: looking for keystore module matching "memory": 4 candidates [000056282a461cc0] main keystore debug: using keystore module "memory" [000056282a2bada0] main libvlc debug: CPU has capabilities MMX MMXEXT SSE SSE2 SSE3 SSSE3 SSE4.1 SSE4.2 AVX FPU [000056282a2a1280] main playlist debug: creating audio output [000056282a46b770] main audio output debug: looking for audio output module matching "any": 6 candidates [000056282a46b770] vlcpulse audio output debug: using library version 13.99.0 [000056282a46b770] vlcpulse audio output debug: (compiled with version 13.99.0, protocol 33) [000056282a46b770] vlcpulse audio output debug: connected locally to /run/user/1000/pulse/native as client #1195 [000056282a46b770] vlcpulse audio output debug: using protocol 33, server protocol 33 [000056282a46b770] pulse audio output debug: adding sink 1: alsa_output.pci-0000_00_1b.0.analog-stereo (Audio interne Stéréo analogique) [000056282a46b770] pulse audio output debug: adding sink 2: alsa_output.usb-M-Audio_Fast_Track_Ultra-00.analog-surround-71 (M-Audio Fast Track Ultra Analog Surround 7.1) [000056282a46b770] main audio output debug: using audio output module "pulse" [000056282a2a1280] main playlist debug: keeping audio output [00007f596c000c20] main input debug: Creating an input for preparsing 'vlc' [000056282a2bada0] main libvlc debug: creating VLM [000056282a4761e0] main input debug: Creating an input for 'rtsp://192.168.0.16' [00007f5970000e00] main stream output debug: using sout chain=transcode{vcodec=theo,vb=800,acodec=vorb,ab=128,channels=2,samplerate=44100}:http{dst=:8080/webcam.ogg}' [00007f5970000e00] main stream output debug: stream=http' [00007f5970006490] main stream out debug: looking for sout stream module matching "http": 23 candidates [00007f595c000c40] main meta fetcher debug: looking for meta fetcher module matching "any": 1 candidates [00007f5970006490] main stream out debug: set config option: sout-standard-dst to :8080/webcam.ogg [00007f597001c990] main access out debug: looking for sout access module matching "http": 10 candidates [00007f595c000c40] lua meta fetcher debug: Trying Lua scripts in /home/gnthibault/.local/share/vlc/lua/meta/fetcher [00007f595c000c40] lua meta fetcher debug: Trying Lua scripts in /usr/lib/x86_64-linux-gnu/vlc/lua/meta/fetcher [00007f595c000c40] lua meta fetcher debug: Trying Lua scripts in /usr/share/vlc/lua/meta/fetcher [00007f595c000c40] main meta fetcher debug: no meta fetcher modules matched [00007f597001c990] main access out debug: net: listening to * port 8080 [00007f595c000c40] main art finder debug: looking for art finder module matching "any": 2 candidates [00007f595c000c40] lua art finder debug: Trying Lua scripts in /home/gnthibault/.local/share/vlc/lua/meta/art [00007f595c000c40] lua art finder debug: Trying Lua scripts in /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art [00007f595c000c40] lua art finder debug: Trying Lua playlist script /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/00_musicbrainz.luac [00007f597001c990] main access out debug: using sout access module "http" [00007f597001e900] main mux debug: looking for sout mux module matching "ogg": 11 candidates [00007f597001e900] mux_ogg mux: Open [00007f597001e900] main mux debug: using sout mux module "mux_ogg" [00007f5970000e00] main stream output debug: muxer support adding stream at any time [00007f5970000e00] main stream output debug: muxer prefers to wait for all ES before starting to mux [00007f5970006490] stream_out_standard stream out debug: usinghttp/ogg://:8080/webcam.ogg' [00007f5970006490] main stream out debug: using sout stream module "stream_out_standard" [00007f5970000e00] main stream output debug: stream=transcode' [00007f597001f3c0] main stream out debug: looking for sout stream module matching "transcode": 23 candidates [00007f595c000c40] lua art finder debug: skipping script (unmatched scope) /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/00_musicbrainz.luac [00007f595c000c40] lua art finder debug: Trying Lua playlist script /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/01_googleimage.luac [00007f597001f3c0] main stream out debug: set config option: sout-transcode-vcodec to theo [00007f597001f3c0] main stream out debug: set config option: sout-transcode-vb to 800 [00007f597001f3c0] main stream out debug: set config option: sout-transcode-acodec to vorb [00007f597001f3c0] main stream out debug: set config option: sout-transcode-ab to 128 [00007f597001f3c0] main stream out debug: set config option: sout-transcode-channels to 2 [00007f597001f3c0] main stream out debug: set config option: sout-transcode-samplerate to 44100 [00007f595c000c40] lua art finder debug: skipping script (unmatched scope) /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/01_googleimage.luac [00007f597001f3c0] stream_out_transcode stream out debug: Checking codec mapping for vorb got vorb [00007f597001f3c0] stream_out_transcode stream out debug: codec audio=vorb 44100Hz 2 channels 128Kb/s [00007f597001f3c0] stream_out_transcode stream out debug: Checking video codec mapping for theo got theo [00007f597001f3c0] stream_out_transcode stream out debug: codec video=theo 0x0 scaling: 0.000000 800kb/s [00007f597001f3c0] main stream out debug: using sout stream module "stream_out_transcode" [000056282a4761e0] [Media: webcam] main input debug: using timeshift granularity of 50 MiB [000056282a4761e0] [Media: webcam] main input debug: using default timeshift path [00007f595c000c40] lua art finder debug: Trying Lua playlist script /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/02_frenchtv.luac [000056282a4761e0] [Media: webcam] main input debug:rtsp://user:password@192.168.0.16' gives access rtsp' demuxany' path `user:password@192.168.0.16' [00007f5970021440] [Media: webcam] main input source debug: creating demux: access='rtsp' demux='any' location='user:password@192.168.0.16' file='(null)' [00007f59700215d0] [Media: webcam] main demux debug: looking for access_demux module matching "rtsp": 17 candidates [00007f595c000c40] lua art finder debug: skipping script (unmatched scope) /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/02_frenchtv.luac [00007f595c000c40] lua art finder debug: Trying Lua playlist script /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/03_lastfm.luac [00007f595c000c40] lua art finder debug: skipping script (unmatched scope) /usr/lib/x86_64-linux-gnu/vlc/lua/meta/art/03_lastfm.luac [00007f595c000c40] lua art finder debug: Trying Lua scripts in /usr/share/vlc/lua/meta/art [00007f595c000c40] main art finder debug: no art finder modules matched [00007f59700215d0] [Media: webcam] live555 demux debug: version 2020.01.19 [00007f59700215d0] [Media: webcam] main demux warning: Password in a URI is DEPRECATED Created new TCP socket 11 for connection Connecting to 192.168.0.16, port 554 on socket 11... ...remote connection opened Sending request: OPTIONS rtsp://192.168.0.16:554 RTSP/1.0 CSeq: 2 User-Agent: LibVLC/3.0.9.2 (LIVE555 Streaming Media v2020.01.19)

Received 152 new bytes of response data. Received a complete OPTIONS response: RTSP/1.0 200 OK CSeq: 2 Date: Sat, Feb 13 2021 23:31:48 GMT Public: OPTIONS, DESCRIBE, SETUP, TEARDOWN, PLAY, PAUSE, GET_PARAMETER, SET_PARAMETER

Sending request: DESCRIBE rtsp://192.168.0.16:554 RTSP/1.0 CSeq: 3 User-Agent: LibVLC/3.0.9.2 (LIVE555 Streaming Media v2020.01.19) Accept: application/sdp

Received 175 new bytes of response data. Received a complete DESCRIBE response: RTSP/1.0 401 Unauthorized CSeq: 3 Date: Sat, Feb 13 2021 23:31:48 GMT WWW-Authenticate: Digest realm="LIVE555 Streaming Media", nonce="ff0347839b17a14d04b7547aecbe7a1e"

Resending... Sending request: DESCRIBE rtsp://192.168.0.16:554 RTSP/1.0 CSeq: 4 Authorization: Digest username="user", realm="LIVE555 Streaming Media", nonce="ff0347839b17a14d04b7547aecbe7a1e", uri="rtsp://192.168.0.16:554", response="c89ad3f8b48007b770fcf3ec10f0cdb0" User-Agent: LibVLC/3.0.9.2 (LIVE555 Streaming Media v2020.01.19) Accept: application/sdp

Received 833 new bytes of response data. Received a complete DESCRIBE response: RTSP/1.0 200 OK CSeq: 4 Date: Sat, Feb 13 2021 23:31:48 GMT Content-Base: rtsp://192.168.0.16// Content-Type: application/sdp Content-Length: 679

v=0 o=- 1612659635742355 1 IN IP4 192.168.0.16 s=Session streamed by "preview" i= t=0 0 a=tool:LIVE555 Streaming Media v2013.04.08 a=type:broadcast a=control:* a=range:npt=0- a=x-qt-text-nam:Session streamed by "preview" a=x-qt-text-inf: m=video 0 RTP/AVP 96 c=IN IP4 0.0.0.0 b=AS:500 a=rtpmap:96 H264/90000 a=fmtp:96 packetization-mode=1;profile-level-id=420032;sprop-parameter-sets=Z0IAMvQBIAUYgA==,aM48gA== a=control:trackID=1 m=audio 0 RTP/AVP 97 c=IN IP4 0.0.0.0 b=AS:256 a=rtpmap:97 MPEG4-GENERIC/16000 a=fmtp:97 streamtype=5;profile-level-id=15;mode=AAC-hbr;sizelength=13;indexlength=3;indexdeltalength=3;config=1408; profile=1; a=control:trackID=2

[00007f59700215d0] [Media: webcam] live555 demux debug: RTP subsession 'video/H264' Sending request: SETUP rtsp://192.168.0.16//trackID=1 RTSP/1.0 CSeq: 5 Authorization: Digest username="user", realm="LIVE555 Streaming Media", nonce="ff0347839b17a14d04b7547aecbe7a1e", uri="rtsp://192.168.0.16//", response="59bcd18092678832a0e02aedb7a7e41e" User-Agent: LibVLC/3.0.9.2 (LIVE555 Streaming Media v2020.01.19) Transport: RTP/AVP;unicast;client_port=43950-43951

Received 202 new bytes of response data. Received a complete SETUP response: RTSP/1.0 200 OK CSeq: 5 Date: Sat, Feb 13 2021 23:31:48 GMT Transport: RTP/AVP;unicast;destination=192.168.0.8;source=192.168.0.16;client_port=43950-43951;server_port=6974-6975 Session: 559F93F2

[000056282a4761e0] [Media: webcam] main input debug: selecting program id=0 [00007f59700215d0] [Media: webcam] live555 demux debug: RTP subsession 'audio/MPEG4-GENERIC' Sending request: SETUP rtsp://192.168.0.16//trackID=2 RTSP/1.0 CSeq: 6 Authorization: Digest username="user", realm="LIVE555 Streaming Media", nonce="ff0347839b17a14d04b7547aecbe7a1e", uri="rtsp://192.168.0.16//", response="59bcd18092678832a0e02aedb7a7e41e" User-Agent: LibVLC/3.0.9.2 (LIVE555 Streaming Media v2020.01.19) Transport: RTP/AVP;unicast;client_port=57108-57109 Session: 559F93F2

Received 202 new bytes of response data. Received a complete SETUP response: RTSP/1.0 200 OK CSeq: 6 Date: Sat, Feb 13 2021 23:31:48 GMT Transport: RTP/AVP;unicast;destination=192.168.0.8;source=192.168.0.16;client_port=57108-57109;server_port=6976-6977 Session: 559F93F2

[00007f59700215d0] [Media: webcam] live555 demux debug: setup start: 0.000000 stop:0.000000 Sending request: PLAY rtsp://192.168.0.16// RTSP/1.0 CSeq: 7 Authorization: Digest username="user", realm="LIVE555 Streaming Media", nonce="ff0347839b17a14d04b7547aecbe7a1e", uri="rtsp://192.168.0.16//", response="6061ef59237af5f70b332402e67cbf98" User-Agent: LibVLC/3.0.9.2 (LIVE555 Streaming Media v2020.01.19) Session: 559F93F2 Range: npt=0.000-

Received 252 new bytes of response data. Received a complete PLAY response: RTSP/1.0 200 OK Server: Rtsp Server/2.0 CSeq: 7 Date: Sat, Feb 13 2021 23:31:48 GMT Range: npt=0.000- Session: 559F93F2 RTP-Info: url=trackID=1;seq=49182;rtptime=957503449;ssrc=64d7664c,url=trackID=2;seq=57553;rtptime=4063185161;ssrc=c37aedcf

[00007f59700215d0] [Media: webcam] live555 demux debug: We have a timeout of 60 seconds [00007f59700215d0] [Media: webcam] live555 demux debug: play start: 0.000000 stop:0.000000 [00007f59700215d0] [Media: webcam] main demux debug: using access_demux module "live555" [00007f5970037450] [Media: webcam] main decoder debug: looking for packetizer module matching "any": 25 candidates [00007f5970037450] [Media: webcam] h264 decoder debug: found NAL_SPS (sps_id=0) [00007f5970037450] [Media: webcam] h264 decoder debug: found NAL_PPS (pps_id=0 sps_id=0) [00007f5970037450] [Media: webcam] main decoder debug: using packetizer module "h264" [00007f59700bd5d0] [Media: webcam] main decoder debug: looking for packetizer module matching "any": 25 candidates [00007f59700bd5d0] [Media: webcam] mpeg4audio decoder debug: running MPEG4 audio packetizer [00007f59700bd5d0] [Media: webcam] mpeg4audio decoder debug: HE-AACv2 32000Hz 1024 samples/frame [00007f59700bd5d0] [Media: webcam] main decoder debug: using packetizer module "mpeg4audio" [000056282a4761e0] [Media: webcam] main input debug: starting in async mode [00007f59700c20a0] [Media: webcam] main demux meta debug: looking for meta reader module matching "any": 2 candidates [00007f59700c20a0] [Media: webcam] lua demux meta debug: Trying Lua scripts in /home/gnthibault/.local/share/vlc/lua/meta/reader [00007f59700c20a0] [Media: webcam] lua demux meta debug: Trying Lua scripts in /usr/lib/x86_64-linux-gnu/vlc/lua/meta/reader [00007f59700c20a0] [Media: webcam] lua demux meta debug: Trying Lua playlist script /usr/lib/x86_64-linux-gnu/vlc/lua/meta/reader/filename.luac [00007f59700c20a0] [Media: webcam] lua demux meta debug: Trying Lua scripts in /usr/share/vlc/lua/meta/reader [00007f59700c20a0] [Media: webcam] main demux meta debug: no meta reader modules matched [000056282a4761e0] [Media: webcam] main input debug: rtsp://user:password@192.168.0.16' successfully opened [000056282a4761e0] [Media: webcam] main input debug: switching to sync mode [00007f5970000e00] main stream output debug: adding a new sout input formp4a(sout_input: 0x7f595c001d80) [000056282a4761e0] [Media: webcam] main input debug: Buffering 0% [00007f597001f3c0] stream_out_transcode stream out debug: creating audio transcoding from fcc=mp4a' to fcc=vorb' [00007f595c00b390] main generic debug: looking for audio decoder module matching "any": 21 candidates [00007f595c00b390] main generic debug: using audio decoder module "faad" [00007f595c0097b0] main encoder debug: looking for encoder module matching "any": 22 candidates [00007f595c0097b0] main encoder debug: using encoder module "vorbis" [00007f597001f3c0] main stream out debug: input 'f32l' 32000 Hz Stereo frame=1 samples/8 bytes [00007f597001f3c0] main stream out debug: conversion: 'f32l'->'f32l' 32000 Hz->32000 Hz Stereo->Stereo [00007f597001f3c0] main stream out debug: conversion pipeline complete [00007f595c06b520] main audio resampler debug: looking for audio resampler module matching "any": 4 candidates [00007f595c06b520] main audio resampler debug: using audio resampler module "samplerate" [00007f595c0097b0] main encoder debug: removing module "vorbis" [00007f595c06b520] main audio resampler debug: removing module "samplerate" [000056282a4761e0] [Media: webcam] main input debug: Buffering 6% [000056282a4761e0] [Media: webcam] main input debug: Buffering 12% [00007f5970000e00] main stream output debug: adding a new sout input forh264(sout_input: 0x7f59580010c0) [00007f597001f3c0] stream_out_transcode stream out debug: creating video transcoding from fcc=h264' to fcc=theo' [00007f59580013c0] main generic debug: looking for video decoder module matching "any": 16 candidates [00007f59580013c0] main generic warning: cannot load module/usr/lib/x86_64-linux-gnu/vlc/plugins/codec/libsvgdec_plugin.so' (/usr/lib/x86_64-linux-gnu/librsvg-2.so.2: undefined symbol: cairo_tag_end) [00007f59580013c0] main generic warning: cannot load module `/usr/lib/x86_64-linux-gnu/vlc/plugins/codec/libavcodec_plugin.so' (/usr/lib/x86_64-linux-gnu/librsvg-2.so.2: undefined symbol: cairo_tag_end) [00007f59580013c0] main generic debug: no video decoder modules matched [00007f597001f3c0] stream_out_transcode stream out error: cannot find video decoder [00007f597001f3c0] stream_out_transcode stream out error: cannot create video chain [00007f5970000e00] main stream output warning: new sout input failed (sout_input: 0x7f59580010c0) [00007f5970037450] [Media: webcam] main decoder error: cannot create packetizer output (h264) [000056282a4761e0] [Media: webcam] main input debug: Buffering 52% [000056282a4761e0] [Media: webcam] main input debug: Buffering 61% [000056282a4761e0] [Media: webcam] main input debug: Buffering 76% [000056282a4761e0] [Media: webcam] main input debug: Buffering 77% [000056282a4761e0] [Media: webcam] main input debug: Buffering 86% [000056282a4761e0] [Media: webcam] main input debug: Buffering 94% [000056282a4761e0] [Media: webcam] main input debug: Stream buffering done (1028 ms in 1040 ms) [00007f5970037450] [Media: webcam] main decoder error: buffer deadlock prevented [000056282a4761e0] [Media: webcam] main input debug: Decoder wait done in 0 ms [00007f595c00b390] faad generic warning: decoded zero sample [00007f595c0097b0] main encoder debug: looking for encoder module matching "any": 22 candidates [00007f595c0097b0] main encoder debug: using encoder module "vorbis" [00007f597001f3c0] main stream out debug: input 'f32l' 32000 Hz Stereo frame=1 samples/8 bytes [00007f597001f3c0] main stream out debug: conversion: 'f32l'->'f32l' 32000 Hz->32000 Hz Stereo->Stereo [00007f597001f3c0] main stream out debug: conversion pipeline complete [00007f595c06b520] main audio resampler debug: looking for audio resampler module matching "any": 4 candidates [00007f595c06b520] main audio resampler debug: using audio resampler module "samplerate" [00007f597001e900] main mux debug: adding a new input [00007f597001e900] mux_ogg mux debug: adding input [00007f597001e900] mux_ogg mux debug: vorbis stream [00007f597001e900] mux_ogg mux debug: writing streams headers [00007f597001e900] mux_ogg mux debug: creating header for vorb [00007f597001e900] mux_ogg mux debug: adding non bos, secondary header [00007f597001e900] mux_ogg mux debug: adding non bos, secondary header [00007f597001e900] mux_ogg mux debug: data starts from 4340 [00007f59700215d0] [Media: webcam] live555 demux debug: tk->rtpSource->hasBeenSynchronizedUsingRTCP() [000056282a4761e0] [Media: webcam] main input debug: ES_OUT_RESET_PCR called [000056282a4761e0] [Media: webcam] main input debug: Buffering 0% [00007f59700215d0] [Media: webcam] live555 demux debug: tk->rtpSource->hasBeenSynchronizedUsingRTCP() [000056282a4761e0] [Media: webcam] main input debug: ES_OUT_RESET_PCR called [000056282a4761e0] [Media: webcam] main input debug: Buffering 0% [000056282a4761e0] [Media: webcam] main input debug: Buffering 41% [000056282a4761e0] [Media: webcam] main input debug: Buffering 49% [000056282a4761e0] [Media: webcam] main input debug: Buffering 58% [000056282a4761e0] [Media: webcam] main input debug: Buffering 66% [000056282a4761e0] [Media: webcam] main input debug: Buffering 72% [000056282a4761e0] [Media: webcam] main input debug: Buffering 74% [000056282a4761e0] [Media: webcam] main input debug: Buffering 91% [000056282a4761e0] [Media: webcam] main input debug: Buffering 99% [000056282a4761e0] [Media: webcam] main input debug: Stream buffering done (1081 ms in 1112 ms) [00007f5970037450] [Media: webcam] main decoder error: buffer deadlock prevented [000056282a4761e0] [Media: webcam] main input debug: Decoder wait done in 0 ms

oaubert commented 3 years ago

Did you try to play a local h264 file through the bindings ? Simply calling python3 vlc.py /path/to/file.mp4 should play the video file with a basic console control interface. You should also specify your platform, since it looks like a module loading issue, which may have peculiarities on different platforms. And FYI, cvlc is an alias to vlc, which itself is not built using libvlc, which may sometimes explain different behaviours.