视频处理FFmpeg和video-thumbextractor
  pBjmnObxvu04 2023年11月02日 49 0

一、视频处理FFmpeg和video-thumbextractor

  一、nginx+video-thumbextractor生成视频缩略图安装所需的环境

  1、安装ImageMagick

yum install

  2、安装libjpeg

wget https://github.com/yasm/yasm/archive/master.zip
unzip master.zip
cd yasm-master
./autogen.sh
make
make install

  3、安装ffmpeg

wget http://ffmpeg.org/releases/ffmpeg-3.3.3.tar.gz
tar -xzvf ffmpeg-3.3.3.tar.gz
cd ffmpeg
#配置参数,不同版本不同(注意)/configure --prefix=/usr/local/ffmpeg-3.3.3 --enable-shared --disable-ffserver --disable-ffplay --enable-postproc --enable-gpl

make
make install

  4、安装nginx

wget https://codeload.github.com/wandenberg/nginx-video-thumbextractor-module/zip/master -O nginx-video-thumbextractor-module-master.zip
unzip nginx-video-thumbextractor-module-master.zip

yum install gcc make git libgcc libstdc++ subversion ruby ncurses-devel -y
yum -y install openssl openssl-devel gd gd-devel
yum -y install lua-devel pcre pcre-devel

wget http://nginx.org/download/nginx-1.14.1.tar.gz
tar -xzvf nginx-1.14.1.tar.gz
cd nginx-1.14.1
./configure --prefix=/usr/local/nginx-1.14.1 --with-http_image_filter_module --with-http_stub_status_module --with-http_ssl_module --add-module=../nginx-video-thumbextractor-module-master --with-cc-opt='-I /usr/include/ImageMagick' --with-http_sub_module --with-ld-opt="-L /usr/local/ffmpeg/lib" --with-cc-opt="-I /usr/local/ffmpeg/include"
make
make install

  5、Nginx的配置

server {

listen 80;
server_name wzs.test.com/;
access_log /data/logs/nginx/wzs.test.com.access.log main;

index index.html index.php index.html;
root /data/site/wzs.test.com;

location / {

}

location ~ /2687/(.*)
{
alias /data/site/wzs.test.com/2687/;
video_thumbextractor;
video_thumbextractor_video_filename $1;
video_thumbextractor_video_second $arg_second;
video_thumbextractor_image_width $arg_width;
video_thumbextractor_image_height $arg_height;
}
}

  二、nginx+video-thumbextractor生成视频缩略图实战

 

  三、FFmpeg

  1、FFmpeg源代码简单分析:configure

  2、FFmpeg简单使用

 



【版权声明】本文内容来自摩杜云社区用户原创、第三方投稿、转载,内容版权归原作者所有。本网站的目的在于传递更多信息,不拥有版权,亦不承担相应法律责任。如果您发现本社区中有涉嫌抄袭的内容,欢迎发送邮件进行举报,并提供相关证据,一经查实,本社区将立刻删除涉嫌侵权内容,举报邮箱: cloudbbs@moduyun.com

  1. 分享:
最后一次编辑于 2023年11月08日 0

暂无评论

推荐阅读
  b1UHV4WKBb2S   2023年11月13日   39   0   0 ide抗锯齿
  b1UHV4WKBb2S   2023年11月13日   33   0   0 裁剪ideflutter
  zSWNgACtCQuP   2023年11月13日   29   0   0 ide
pBjmnObxvu04