shaka-project / shaka-streamer

A simple config-file based approach to preparing streaming media, based on FFmpeg and Shaka Packager.
https://shaka-project.github.io/shaka-streamer/
Apache License 2.0
198 stars 62 forks source link

Not playing when using the vp9 codec in HLS #136

Open sgbai78 opened 1 year ago

sgbai78 commented 1 year ago

When vp9 is used for video_codecs, an error occurs in the final webm file and it does not play.

The pipeline file I used is below.

streaming_mode: vod

resolutions: - 4k - 1080p - 720p - 432p - 360p

channel_layouts: - stereo - surround

audio_codecs: - aac - opus video_codecs: - vp9

manifest_format: # - dash - hls

segment_size: 4

When I checked the intermediate file created by ffmpeg using ffprobe, I could see that vp9 was normally applied.

This is the ffprobe result of the file generated by ffmpeg.

ffprobe version N-110653-g01d9a84ef5 Copyright (c) 2007-2023 the FFmpeg developers built with gcc 11 (Ubuntu 11.3.0-1ubuntu1~22.04) configuration: --prefix=/usr/local --enable-static --enable-nonfree --enable-gpl --enable-version3 --enable-runtime-cpudetect --enable-libaom --enable-libfreetype --enable-libfontconfig --enable-libass --enable-libbluray --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libtheora --enable-libvpx --enable-libwebp --enable-opencl --enable-opengl --cpu=native --enable-nvenc --enable-vaapi --enable-ladspa --enable-libass --enable-libsmbclient --enable-libsoxr --enable-libssh --enable-libxvid --enable-libx264 --enable-libx265 --enable-openal --enable-openssl --enable-cuda --enable-omx libavutil 58. 7.100 / 58. 7.100 libavcodec 60. 14.100 / 60. 14.100 libavformat 60. 5.100 / 60. 5.100 libavdevice 60. 2.100 / 60. 2.100 libavfilter 9. 8.100 / 9. 8.100 libswscale 7. 2.100 / 7. 2.100 libswresample 4. 11.100 / 4. 11.100 libpostproc 57. 2.100 / 57. 2.100 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'de44b35e-bce8-4891-9601-879dbb017441': Metadata: major_brand : isom minor_version : 512 compatible_brands: isomiso6iso2mp41 encoder : Lavf60.5.100 Duration: 00:01:09.32, start: 0.000000, bitrate: 976 kb/s Stream #0:00x1: Video: vp9 (Profile 0) (vp09 / 0x39307076), yuv420p(tv, progressive), 1280x720, 975 kb/s, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 12800 tbn (default) Metadata: handler_name : VideoHandler vendor_id : [0][0][0][0] encoder : Lavc60.14.100 libvpx-vp9

When checking the files created in the final directory through ffprobe, the following error occurs.

ffprobe version N-110653-g01d9a84ef5 Copyright (c) 2007-2023 the FFmpeg developers built with gcc 11 (Ubuntu 11.3.0-1ubuntu1~22.04) configuration: --prefix=/usr/local --enable-static --enable-nonfree --enable-gpl --enable-version3 --enable-runtime-cpudetect --enable-libaom --enable-libfreetype --enable-libfontconfig --enable-libass --enable-libbluray --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libtheora --enable-libvpx --enable-libwebp --enable-opencl --enable-opengl --cpu=native --enable-nvenc --enable-vaapi --enable-ladspa --enable-libass --enable-libsmbclient --enable-libsoxr --enable-libssh --enable-libxvid --enable-libx264 --enable-libx265 --enable-openal --enable-openssl --enable-cuda --enable-omx libavutil 58. 7.100 / 58. 7.100 libavcodec 60. 14.100 / 60. 14.100 libavformat 60. 5.100 / 60. 5.100 libavdevice 60. 2.100 / 60. 2.100 libavfilter 9. 8.100 / 9. 8.100 libswscale 7. 2.100 / 7. 2.100 libswresample 4. 11.100 / 4. 11.100 libpostproc 57. 2.100 / 57. 2.100 [matroska,webm @ 0x561f8654cf00] Format matroska,webm detected only with low score of 1, misdetection possible! [matroska,webm @ 0x561f8654cf00] EBML header parsing failed video_720p_3.4M_vp9_11.webm: Invalid data found when processing input

joeyparrish commented 11 months ago

I've seen something similar before. You might need to update libvpx or use our statically-built official binaries.