gpt4 book ai didi

android - FFmpeg 创建空调色板,以获得更好的 GIF 转换质量

转载 作者:行者123 更新时间:2023-12-04 23:14:46 25 4
gpt4 key购买 nike

FFmpeg 创建空调色板,以获得更好的 GIF 转换质量

我已经提到

https://ffmpeg.org/ffmpeg-filters.html#palettegen-1

https://superuser.com/a/556031/724432

但它会创建一个空的托盘文件

我在安卓上试试

使用的命令是

{"-y", "-i", j, "-ss", 10, "-t",3,"-vf","fps=15,scale=300:-1:flags=lanczos,palettegen", palette};

并且显示的错误是
ffmpeg version n3.0.1 Copyright (c) 2000-2016 the FFmpeg developers
built with gcc 4.8 (GCC)
configuration: --target-os=linux --cross-prefix=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/bin/arm-linux-androideabi- --arch=arm --cpu=cortex-a8 --enable-runtime-cpudetect --sysroot=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/sysroot --enable-pic --enable-libx264 --enable-libass --enable-libfreetype --enable-libfribidi --enable-libmp3lame --enable-fontconfig --enable-pthreads --disable-debug --disable-ffserver --enable-version3 --enable-hardcoded-tables --disable-ffplay --disable-ffprobe --enable-gpl --enable-yasm --disable-doc --disable-shared --enable-static --pkg-config=/home/vagrant/SourceCode/ffmpeg-android/ffmpeg-pkg-config --prefix=/home/vagrant/SourceCode/ffmpeg-android/build/armeabi-v7a --extra-cflags='-I/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/include -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fno-strict-overflow -fstack-protector-all' --extra-ldflags='-L/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/lib -Wl,-z,relro -Wl,-z,now -pie' --extra-libs='-lpng -lexpat -lm' --extra-cxxflags=
libavutil 55. 17.103 / 55. 17.103
libavcodec 57. 24.102 / 57. 24.102
libavformat 57. 25.100 / 57. 25.100
libavdevice 57. 0.101 / 57. 0.101
libavfilter 6. 31.100 / 6. 31.100
libswscale 4. 0.100 / 4. 0.100
libswresample 2. 0.101 / 2. 0.101
libpostproc 54. 0.100 / 54. 0.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/storage/sdcard0/try/Videos/2018-03-13-15-47-29.mp4.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: isommp42
creation_time : 2018-03-13 15:47:33
Duration: 00:00:03.39, start: 0.000000, bitrate: 615 kb/s
Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 960x540, 637 kb/s, SAR 1:1 DAR 16:9, 22.95 fps, 60 tbr, 90k tbn, 180k tbc (default)
Metadata:
creation_time : 2018-03-13 15:47:33
handler_name : VideoHandle
Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 16000 Hz, mono, fltp, 12 kb/s (default)
Metadata:
creation_time : 2018-03-13 15:47:33
handler_name : SoundHandle
Output #0, image2, to '/storage/sdcard0/try/Gifs//2018-03-16-11-36-48.png':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: isommp42
encoder : Lavf57.25.100
Stream #0:0(eng): Video: png, rgba, 16x16 [SAR 1:1 DAR 1:1], q=2-31, 200 kb/s, 10 fps, 10 tbn, 10 tbc (default)
Metadata:
creation_time : 2018-03-13 15:47:33
handler_name : VideoHandle
encoder : Lavc57.24.102 png
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> png (native))
Press [q] to stop, [?] for help
frame= 0 fps=0.0 q=0.0 size=N/A time=00:00:00.00 bitrate=N/A speed= 0x
frame= 0 fps=0.0 q=0.0 size=N/A time=00:00:00.00 bitrate=N/A speed= 0x
[Parsed_palettegen_2 @ 0xac96ed80] 255(+1) colors generated out of 3594 colors; ratio=0.070952
[Parsed_palettegen_2 @ 0xac96ed80] Dupped color: FF5F5F5F
frame= 0 fps=0.0 q=0.0 Lsize=N/A time=00:00:00.00 bitrate=N/A speed= 0x
video:0kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)

任何帮助都会有用

最佳答案

删除 "-ss", 10, "-t",3, .您的输入只有 3 秒长。

关于android - FFmpeg 创建空调色板,以获得更好的 GIF 转换质量,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49314213/

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