提取YUV数据
ffmpeg -i input.mp4 -an -c:v rawvideo -pix_fmt yuv420p out.yuv
-i 输入文件
-an audio no
-c:v 等于-vcodec
-pix_fmt 像素格式
提取PCM数据
ffmpeg -i out.flv -vn -ar 44100 -ac 2 -f s16le out.pcm
-i 输入文件
-vn video no
-ar audio read 采样率
-ac audio count 声道数
-f 数据格式 s16le s代表有符号 16表示每一个数值用16位表示 le表示为little end 小头存储
gensees-iMac:study gensee$ ffmpeg -i out.flv -vn -ar 44100 -ac 2 -f s16le out.pcm
ffmpeg version N-94063-g86f04b918c Copyright (c) 2000-2019 the FFmpeg developers
built with Apple LLVM version 8.1.0 (clang-802.0.38)
configuration: --prefix=/usr/local/ffmpeg --enable-gpl --enable-nonfree --enable-libfdk-aac --enable-libx264 --enable-libx265 --enable-filter=delogo --enable-debug --disable-optimizations --enable-libspeex --enable-videotoolbox --enable-shared --enable-pthreads --enable-version3 --cc=clang --host-cflags= --host-ldflags=
libavutil 56. 29.100 / 56. 29.100
libavcodec 58. 53.100 / 58. 53.100
libavformat 58. 27.103 / 58. 27.103
libavdevice 58. 7.100 / 58.