gpt4 book ai didi

macos - ffmpeg 错误 : Could not write header for output file #0 (incorrect codec parameters ?):找不到 Muxer

转载 作者:行者123 更新时间:2023-12-04 22:49:32 33 4
gpt4 key购买 nike

我正在尝试为 HLS 播放分割 mp4 视频文件,但出现以下错误:

"Could not write header for output file #0 (incorrect codec parameters ?): Muxer not found"

有人知道我做错了什么吗?

输入指令:

sudo ffmpeg -y -i adwd.mp4 -vcodec copy -acodec copy -force_key_frames 30 -map 0  -f segment segment_list adwd.m3u8 -segment_time 10 -segment_format mpeg_ts -segment_list_type m3u8 segment%d.ts


ffmpeg version 2.8.5 Copyright (c) 2000-2016 the FFmpeg developers
built with Apple LLVM version 7.0.2 (clang-700.1.81)
configuration: --prefix=/usr/local/Cellar/ffmpeg/2.8.5 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-vda
libavutil 54. 31.100 / 54. 31.100
libavcodec 56. 60.100 / 56. 60.100
libavformat 56. 40.101 / 56. 40.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 40.101 / 5. 40.101
libavresample 2. 1. 0 / 2. 1. 0
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.101 / 1. 2.101
libpostproc 53. 3.100 / 53. 3.100

视频信息:

General / Container Stream #1
Total Video Streams for this File.................1
Total Audio Streams for this File.................1
Video Codecs Used.................................AVC
Audio Codecs Used.................................AAC LC
File Format.......................................MPEG-4
Play Time.........................................9h 1mn
Total File Size...................................588 MiB
Total Stream BitRate..............................152 Kbps
Encoded with......................................Lavf56.40.101
Video Stream #1
Codec (Human Name)................................AVC
Codec (FourCC)....................................avc1
Codec Profile.....................................High@L2.1
Frame Width.......................................426 pixels
Frame Height......................................240 pixels
Frame Rate........................................29.970 fps
Total Frames......................................973039
Display Aspect Ratio..............................16:9
Scan Type.........................................Progressive
Color Space.......................................YUV
Codec Settings (Summary)..........................CABAC / 4 Ref Frames
QF (like Gordian Knot)............................0.005
Codec Settings (CABAC)............................Yes
Codec Settings (Reference Frames).................4
Video Stream Length...............................9h 1mn 7s 68ms
Video Stream BitRate..............................15.2 Kbps
Video Stream BitRate Mode.........................VBR
Bit Depth.........................................8 bits
Video Stream Size.................................58.9 MiB (10%)
Video Encoder.....................................x264 - core 148 r2601 a0cd7d3
Video Encoder (Settings)..........................cabac=1 / ref=3 / deblock=1:0:0 / analyse=0x3:0x113 / me=hex / subme=7 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=1 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=3 / lookahead_threads=1 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=1 / b_bias=0 / direct=1 / weightb=1 / open_gop=0 / weightp=2 / keyint=250 / keyint_min=25 / scenecut=40 / intra_refresh=0 / rc_lookahead=40 / rc=crf / mbtree=1 / crf=23.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / ip_ratio=1.40 / aq=1:1.00
Audio Stream #1
Codec.............................................AAC
Codec (FourCC)....................................40
Audio Stream Length...............................9h 1mn 7s 104ms
Audio Stream BitRate..............................128 Kbps
Audio Stream BitRate Mode.........................CBR
Number of Audio Channels..........................2
Audio Channel's Positions.........................Front: L R
Sampling Rate.....................................44.1 KHz
Audio Stream Size.................................495 MiB (84%)

最佳答案

我已经通过删除强制关键帧(我的原始编码遗留下来的命令并设置 -flags -global_header 参数)解决了这个编码问题。

这是我使用的最后一个命令:

sudo ffmpeg -i adwd.mp4 -bsf:v h264_mp4toannexb -c copy -map 0 -flags -global_header  -f segment -segment_time 10 -segment_list adwd.m3u8 -segment_format mpegts adwd%d.ts 

关于macos - ffmpeg 错误 : Could not write header for output file #0 (incorrect codec parameters ?):找不到 Muxer,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35097424/

33 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com