Audio cuts out after "EOF reached" message
Posted: 06 Mar 2019 17:55
Been really going crazy on this issue. Would appreciate ANY suggestions.
I'm using libvlc with libvlc_media_new_callbacks. I have it using a buffer that gets written to in real time. The video plays no problem but the last second or few seconds of audio get cut off at the end. The video plays just fine with audio throughout. However, the last few seconds or so the audio just goes quiet. The following appears in the logs just when the audio gets cut off:
HOWEVER! I've created a minimal example using basically the same principal in the same dev environment and the minimal example WORKS and the audio does NOT cut off.
I've also tried to write an output file with the same data that VLC is reading from my buffer to see if maybe the video file is cutting off the end or the buffer corrupted. However, the test result video file written from the buffer matches the file being sent exactly. So it's not the buffer causing this issue.
I'm pretty stumped.
Windows 7 MSYS2 environment here is the VLC info
This is the code in full. Excuse all of the debug logging stuff. I've been going crazy trying to find out what's wrong:
https://pastebin.com/vhzR6vV0
Here is the minimal example I've created that works:
https://pastebin.com/fFr6XUHP
I'm using libvlc with libvlc_media_new_callbacks. I have it using a buffer that gets written to in real time. The video plays no problem but the last second or few seconds of audio get cut off at the end. The video plays just fine with audio throughout. However, the last few seconds or so the audio just goes quiet. The following appears in the logs just when the audio gets cut off:
Code: Select all
2019-03-06, 11:18:29.626200: <debug> (0x00000404) [VLC] EOF reached
2019-03-06, 11:18:29.875200: <debug> (0x00000404) [VLC] waiting decoder fifos to empty
I've also tried to write an output file with the same data that VLC is reading from my buffer to see if maybe the video file is cutting off the end or the buffer corrupted. However, the test result video file written from the buffer matches the file being sent exactly. So it's not the buffer causing this issue.
I'm pretty stumped.
Windows 7 MSYS2 environment here is the VLC info
Code: Select all
2019-03-06, 10:47:24.611200: <debug> (0x000000e0) [VLC] VLC media player - 3.0.6 Vetinari
2019-03-06, 10:47:24.612200: <debug> (0x000000e0) [VLC] Copyright ▒ 1996-2018 the VideoLAN team
2019-03-06, 10:47:24.612200: <debug> (0x000000e0) [VLC] revision 3.0.6-0-g5803e85f73
2019-03-06, 10:47:24.612200: <debug> (0x000000e0) [VLC] configured with /scripts/mingw-w64-vlc/src/vlc-3.0.6/configure '--prefix=/mingw32' '--sysconfdir=/mingw32/etc' '--build=i686-w64-mingw32' '--host=i686-w64-mingw32' '--target=i686-w64-mingw32' '--enable-qt' '--disable-ncurses' '--disable-dbus' '--disable-telx' '--enable-nls' '--disable-lua' '--disable-gst-decode' 'build_alias=i686-w64-mingw32' 'host_alias=i686-w64-mingw32' 'target_alias=i686-w64-mingw32' 'CFLAGS=-march=i686 -mtune=generic -O2 -pipe' 'LDFLAGS=-pipe' 'CPPFLAGS=-D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -IC:/building/msys64/mingw32/include/QtGui/5.12.0/QtGui' 'CXXFLAGS=-march=i686 -mtune=generic -O2 -pipe' 'BUILDCC=/mingw32/bin/gcc' 'PKG_CONFIG_PATH=/mingw32/lib/pkgconfig:/mingw32/share/pkgconfig'
This is the code in full. Excuse all of the debug logging stuff. I've been going crazy trying to find out what's wrong:
https://pastebin.com/vhzR6vV0
Here is the minimal example I've created that works:
https://pastebin.com/fFr6XUHP