Encoding FFMPEG:无法在过滤器支持的格式之间转换-重新初始化过滤器时出错

Encoding FFMPEG:无法在过滤器支持的格式之间转换-重新初始化过滤器时出错,encoding,ffmpeg,http-live-streaming,Encoding,Ffmpeg,Http Live Streaming,尝试使用NVIDIA Cuda使用以下命令将mp4文件编码为HLS[.m3u8]: 我正在尝试将1080p视频文件转换为4种格式副本分辨率:1080p720p480p360p下面是720p示例 ffmpeg -y -vsync 0 -hwaccel cuda -hwaccel_output_format cuda -i input.mp4 -vf scale=w=1280:h=720:force_original_aspect_ratio=decrease -c:a aac -ar 48000

尝试使用NVIDIA Cuda使用以下命令将mp4文件编码为HLS[.m3u8]:

我正在尝试将1080p视频文件转换为4种格式副本分辨率:
1080p
720p
480p
360p
下面是
720p
示例

ffmpeg -y -vsync 0 -hwaccel cuda -hwaccel_output_format cuda -i input.mp4 -vf scale=w=1280:h=720:force_original_aspect_ratio=decrease -c:a aac -ar 48000 -b:a 128k -c:v h264_nvenc -profile:v main -crf 20 -g 48 -keyint_min 48 -sc_threshold 0 -b:v 2500k -maxrate 2675k -bufsize 3750k -hls_time 4 -hls_playlist_type vod -hls_segment_filename output/720p_%03d.ts output/720p.m3u8
但这是我在运行命令时遇到的错误

Impossible to convert between the formats supported by the filter 'graph 0 input from stream 0:0' and the filter 'auto_scaler_0'
Error reinitializing filters!
Failed to inject frame into filter network: Function not implemented
Error while processing the decoded data for stream #0:0
我想我的问题出在
-vf scale=w=1280:h=720:force\u original\u aspect\u ratio=decrease
命令的某个地方,但我不确定可以用什么替换它,因为我需要scale函数

这也是
ffmpeg-version

ffmpeg version 4.3.1 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 7 (Ubuntu 7.5.0-3ubuntu1~18.04)
configuration: --enable-cuda-nvcc --enable-cuvid --enable-nvenc --enable-libnpp --enable-cuda-llvm --pkgconfigdir=/content/workspace/lib/pkgconfig --prefix=/content/workspace --pkg-config-flags=--static --extra-cflags='-I/content/workspace/include -I/usr/local/cuda/include' --extra-ldflags='-L/content/workspace/lib -L/usr/local/cuda/lib64' --extra-libs='-lpthread -lm' --enable-static --disable-debug --disable-shared --disable-ffplay --disable-doc --enable-openssl --enable-gpl --enable-version3 --enable-nonfree --enable-pthreads --enable-libvpx --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libx265 --enable-runtime-cpudetect --enable-libfdk-aac --enable-avfilter --enable-libopencore_amrwb --enable-libopencore_amrnb --enable-filters --enable-libvidstab --enable-libaom --enable-libsrt
libavutil      56. 51.100 / 56. 51.100
libavcodec     58. 91.100 / 58. 91.100
libavformat    58. 45.100 / 58. 45.100
libavdevice    58. 10.100 / 58. 10.100
libavfilter     7. 85.100 /  7. 85.100
libswscale      5.  7.100 /  5.  7.100
libswresample   3.  7.100 /  3.  7.100
libpostproc    55.  7.100 / 55.  7.100

回答我自己的问题。。。我将
-vf scale=w=1280:h=720:force\u original\u aspect\u ratio=reduce
替换为
-vf scale\u cuda=1280:720:1:4

-vf scale\u npp=1280:720,如果ffmpeg说没有scale\u cuda过滤器*ffmpeg-要检查的过滤器| grep scale