will not play if there is no keyframe in the first frame
Activity
-
Newest first Oldest first
-
Show all activity Show comments only Show history only
- Ronald S. Bultje assigned to @rbultje
assigned to @rbultje
- Author
I uploaded a test video
- Author
Test video cannot be played on VLC
But Test video can be played on VLC for patched dav1d
- Developer
I've tested this (on
tools/dav1d
) before and after the patch, and it plays identically. I think VLC uses the dav1d API slightly differently in a way that causes it to not be able to resume after an error. The issue should probably be fixed there.Also, ffmpeg plays it correctly for me (using libdav1d):
$ ffmpeg -i ~/Downloads/test.mkv -c:v copy /tmp/test.ivf ffmpeg version 4.4.1 Copyright (c) 2000-2021 the FFmpeg developers built with Apple clang version 13.0.0 (clang-1300.0.29.3) configuration: --prefix=/opt/local --enable-swscale --enable-avfilter --enable-avresample --enable-libmp3lame --enable-libvorbis --enable-libopus --enable-librsvg --enable-libtheora --enable-libopenjpeg --enable-libmodplug --enable-libvpx --enable-libsoxr --enable-libspeex --enable-libass --enable-libbluray --enable-lzma --enable-gnutls --enable-fontconfig --enable-libfreetype --enable-libfribidi --enable-zlib --disable-libjack --disable-libopencore-amrnb --disable-libopencore-amrwb --disable-libxcb --disable-libxcb-shm --disable-libxcb-xfixes --disable-indev=jack --enable-opencl --disable-outdev=xv --enable-audiotoolbox --enable-videotoolbox --enable-sdl2 --disable-securetransport --mandir=/opt/local/share/man --enable-shared --enable-pthreads --cc=/usr/bin/clang --enable-libzimg --enable-libdav1d --arch=x86_64 --enable-x86asm --enable-libx265 --enable-gpl --enable-postproc --enable-libx264 --enable-libxvid libavutil 56. 70.100 / 56. 70.100 libavcodec 58.134.100 / 58.134.100 libavformat 58. 76.100 / 58. 76.100 libavdevice 58. 13.100 / 58. 13.100 libavfilter 7.110.100 / 7.110.100 libavresample 4. 0. 0 / 4. 0. 0 libswscale 5. 9.100 / 5. 9.100 libswresample 3. 9.100 / 3. 9.100 libpostproc 55. 9.100 / 55. 9.100 [libdav1d @ 0x7f9b1801a400] libdav1d 0.9.2 [libdav1d @ 0x7f9b1801a400] Error parsing OBU data Last message repeated 150 times [matroska,webm @ 0x7f9b18008200] decoding for stream 0 failed [matroska,webm @ 0x7f9b18008200] Could not find codec parameters for stream 0 (Video: av1 (libdav1d) (Main), none(tv, progressive), 512x384): unspecified pixel format Consider increasing the value for the 'analyzeduration' (0) and 'probesize' (5000000) options Input #0, matroska,webm, from '/Users/ronaldbultje/Downloads/test.mkv': Metadata: COMPATIBLE_BRANDS: isomiso2mp41 MAJOR_BRAND : isom MINOR_VERSION : 512 ENCODER : Lavf59.16.100 Duration: N/A, start: 9.055000, bitrate: N/A Stream #0:0: Video: av1 (Main), none(tv, progressive), 512x384, SAR 1:1 DAR 4:3, 30 fps, 30 tbr, 1k tbn, 1k tbc (default) Metadata: HANDLER_NAME : VideoHandler VENDOR_ID : [0][0][0][0] ENCODER : Lavc59.18.100 libsvtav1 Stream #0:1: Audio: aac (LC), 44100 Hz, stereo, fltp (default) Metadata: HANDLER_NAME : SoundHandler VENDOR_ID : [0][0][0][0] Output #0, ivf, to '/tmp/test.ivf': Metadata: COMPATIBLE_BRANDS: isomiso2mp41 MAJOR_BRAND : isom MINOR_VERSION : 512 encoder : Lavf58.76.100 Stream #0:0: Video: av1 (Main) (AV01 / 0x31305641), none(tv, progressive), 512x384 [SAR 1:1 DAR 4:3], q=2-31, 30 fps, 30 tbr, 1k tbn, 1k tbc (default) Metadata: HANDLER_NAME : VideoHandler VENDOR_ID : [0][0][0][0] ENCODER : Lavc59.18.100 libsvtav1 Stream mapping: Stream #0:0 -> #0:0 (copy) Press [q] to stop, [?] for help [matroska,webm @ 0x7f9b18008200] File ended prematurely0.00 bitrate=N/A speed= 0x frame= 669 fps=0.0 q=-1.0 Lsize= 1267kB time=00:00:23.25 bitrate= 446.4kbits/s speed=1.81e+03x video:1258kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.729443%
Edited by Ronald S. Bultje - Ronald S. Bultje mentioned in merge request !1362 (closed)
mentioned in merge request !1362 (closed)
- Developer
We found a bug in FFmpeg which prevented this from working correctly. After 61b104caaa, FFmpeg decodes the provided sample correctly.
I'm not yet sure why VLC fails to play it. It's possible VLC aborts media processing after the first packet decoding error. This is obviously unwanted for live streams. The correct way to resolve this would be to fix VLC, not to workaround the packet decoding errors in dav1d.
- Developer
I've tried to build VLC myself but I can't get it working. I think the build instructions don't work on Mac 12.0. I would recommend that someone who can build VLC fix their API usage. I think they need to re-try decoding video packets if the first packet fails. I can help further if someone can help me build VLC.
- Ronald S. Bultje closed
closed
- tokumei kibou reopened
reopened
- Author
ffmpeg also doesn't decode correctly
test.webm does play in ffplay for libaom-av1
ffplay -codec:v libaom-av1 -i test.webm
test.webm does not play in ffplay for libdav1d
ffplay -codec:v libdav1d -i test.webm
But test.webm does play in ffplay for patched libdav1d
AV1 Video Extension(using dav1d) also doesn't decode correctly
https://www.microsoft.com/en-us/p/av1-video-extension/9mvzqvxjbq9v
I think it's better to fix Dav1d than VLC
- Developer
ffmpeg also doesn't decode correctly
Did you try again using an ffmpeg build that includes the fix Ronald talked about, namely commit hash 61b104caaa? It's available in the master branch, and releases 5.0, 4.4, and 4.3 branches.
- Author
ffmpeg fixed with 61b104caaa.
Thank you
- tokumei kibou closed
closed
- Developer
I think it's better to fix Dav1d than VLC
I don't think we should disable one particular case of error reporting when applications don't use the API correctly. I understand this can be infuriating, but it's better (long-term) to fix the applications.
- Developer
I got some help building VLC. Bugfix for VLC is here: vlc!1346 (merged)
- Ronald S. Bultje mentioned in merge request vlc!1346 (merged)
mentioned in merge request vlc!1346 (merged)
- Jean-Baptiste Kempf mentioned in merge request vlc!1405 (merged)
mentioned in merge request vlc!1405 (merged)
- Owner
See also vlc!1405 (merged) for VLC 3.0.x
- Jean-Baptiste Kempf changed milestone to %1.0.0
changed milestone to %1.0.0
- Jean-Baptiste Kempf added bug label
added bug label