
Recherche avancée
Autres articles (101)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
Le super Cron (gestion_mutu_super_cron)
Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...) -
Emballe Médias : Mettre en ligne simplement des documents
29 octobre 2010, parLe plugin emballe médias a été développé principalement pour la distribution mediaSPIP mais est également utilisé dans d’autres projets proches comme géodiversité par exemple. Plugins nécessaires et compatibles
Pour fonctionner ce plugin nécessite que d’autres plugins soient installés : CFG Saisies SPIP Bonux Diogène swfupload jqueryui
D’autres plugins peuvent être utilisés en complément afin d’améliorer ses capacités : Ancres douces Légendes photo_infos spipmotion (...)
Sur d’autres sites (13748)
-
Matomo Launches Global Partner Programme to Deepen Local Connections and Champion Ethical Analytics
25 juin, par Matomo Core Team — Press Releases -
How to generate a fixed duration and fps for a video using FFmpeg C++ libraries ? [closed]
4 novembre 2024, par BlueSky Light ProgrammerI'm following the mux official example to write a C++ class that generates a video with a fixed duration (5s) and a fixed fps (60). For some reason, the duration of the output video is 3-4 seconds, although I call the function to write frames 300 times and set the fps to 60.


Can you take a look at the code below and spot what I'm doing wrong ?


#include "ffmpeg.h"

#include <iostream>

static int writeFrame(AVFormatContext *fmt_ctx, AVCodecContext *c,
 AVStream *st, AVFrame *frame, AVPacket *pkt);

static void addStream(OutputStream *ost, AVFormatContext *formatContext,
 const AVCodec **codec, enum AVCodecID codec_id,
 int width, int height, int fps);

static AVFrame *allocFrame(enum AVPixelFormat pix_fmt, int width, int height);

static void openVideo(AVFormatContext *formatContext, const AVCodec *codec,
 OutputStream *ost, AVDictionary *opt_arg);

static AVFrame *getVideoFrame(OutputStream *ost,
 const std::vector<glubyte>& pixels,
 int duration);

static int writeVideoFrame(AVFormatContext *formatContext,
 OutputStream *ost,
 const std::vector<glubyte>& pixels,
 int duration);

static void closeStream(AVFormatContext *formatContext, OutputStream *ost);

static void fillRGBImage(AVFrame *frame, int width, int height,
 const std::vector<glubyte>& pixels);

#ifdef av_err2str
#undef av_err2str
#include <string>
av_always_inline std::string av_err2string(int errnum) {
 char str[AV_ERROR_MAX_STRING_SIZE];
 return av_make_error_string(str, AV_ERROR_MAX_STRING_SIZE, errnum);
}
#define av_err2str(err) av_err2string(err).c_str()
#endif // av_err2str

FFmpeg::FFmpeg(int width, int height, int fps, const char *fileName)
: videoStream{ 0 }
, formatContext{ nullptr } {
 const AVOutputFormat *outputFormat;
 const AVCodec *videoCodec{ nullptr };
 AVDictionary *opt{ nullptr };
 int ret{ 0 };

 av_dict_set(&opt, "crf", "17", 0);

 /* Allocate the output media context. */
 avformat_alloc_output_context2(&this->formatContext, nullptr, nullptr, fileName);
 if (!this->formatContext) {
 std::cout << "Could not deduce output format from file extension: using MPEG." << std::endl;
 avformat_alloc_output_context2(&this->formatContext, nullptr, "mpeg", fileName);
 
 if (!formatContext)
 exit(-14);
 }

 outputFormat = this->formatContext->oformat;

 /* Add the video stream using the default format codecs
 * and initialize the codecs. */
 if (outputFormat->video_codec == AV_CODEC_ID_NONE) {
 std::cout << "The output format doesn't have a default codec video." << std::endl;
 exit(-15);
 }

 addStream(
 &this->videoStream,
 this->formatContext,
 &videoCodec,
 outputFormat->video_codec,
 width,
 height,
 fps
 );
 openVideo(this->formatContext, videoCodec, &this->videoStream, opt);
 av_dump_format(this->formatContext, 0, fileName, 1);
 
 /* open the output file, if needed */
 if (!(outputFormat->flags & AVFMT_NOFILE)) {
 ret = avio_open(&this->formatContext->pb, fileName, AVIO_FLAG_WRITE);
 if (ret < 0) {
 std::cout << "Could not open '" << fileName << "': " << std::string{ av_err2str(ret) } << std::endl;
 exit(-16);
 }
 }

 /* Write the stream header, if any. */
 ret = avformat_write_header(this->formatContext, &opt);
 if (ret < 0) {
 std::cout << "Error occurred when opening output file: " << av_err2str(ret) << std::endl;
 exit(-17);
 }

 av_dict_free(&opt);
}

FFmpeg::~FFmpeg() {
 if (this->formatContext) {
 /* Close codec. */
 closeStream(this->formatContext, &this->videoStream);

 if (!(this->formatContext->oformat->flags & AVFMT_NOFILE)) {
 /* Close the output file. */
 avio_closep(&this->formatContext->pb);
 }

 /* free the stream */
 avformat_free_context(this->formatContext);
 }
}

void FFmpeg::Record(
 const std::vector<glubyte>& pixels,
 unsigned frameIndex,
 int duration,
 bool isLastIndex
) {
 static bool encodeVideo{ true };
 if (encodeVideo)
 encodeVideo = !writeVideoFrame(this->formatContext,
 &this->videoStream,
 pixels,
 duration);

 if (isLastIndex) {
 av_write_trailer(this->formatContext);
 encodeVideo = false;
 }
}

int writeFrame(AVFormatContext *fmt_ctx, AVCodecContext *c,
 AVStream *st, AVFrame *frame, AVPacket *pkt) {
 int ret;

 // send the frame to the encoder
 ret = avcodec_send_frame(c, frame);
 if (ret < 0) {
 std::cout << "Error sending a frame to the encoder: " << av_err2str(ret) << std::endl;
 exit(-2);
 }

 while (ret >= 0) {
 ret = avcodec_receive_packet(c, pkt);
 if (ret == AVERROR(EAGAIN) || ret == AVERROR_EOF)
 break;
 else if (ret < 0) {
 std::cout << "Error encoding a frame: " << av_err2str(ret) << std::endl;
 exit(-3);
 }

 /* rescale output packet timestamp values from codec to stream timebase */
 av_packet_rescale_ts(pkt, c->time_base, st->time_base);
 pkt->stream_index = st->index;

 /* Write the compressed frame to the media file. */
 ret = av_interleaved_write_frame(fmt_ctx, pkt);
 /* pkt is now blank (av_interleaved_write_frame() takes ownership of
 * its contents and resets pkt), so that no unreferencing is necessary.
 * This would be different if one used av_write_frame(). */
 if (ret < 0) {
 std::cout << "Error while writing output packet: " << av_err2str(ret) << std::endl;
 exit(-4);
 }
 }

 return ret == AVERROR_EOF ? 1 : 0;
}

void addStream(OutputStream *ost, AVFormatContext *formatContext,
 const AVCodec **codec, enum AVCodecID codec_id,
 int width, int height, int fps) {
 AVCodecContext *c;
 int i;

 /* find the encoder */
 *codec = avcodec_find_encoder(codec_id);
 if (!(*codec)) {
 std::cout << "Could not find encoder for " << avcodec_get_name(codec_id) << "." << std::endl;
 exit(-5);
 }

 ost->tmpPkt = av_packet_alloc();
 if (!ost->tmpPkt) {
 std::cout << "Could not allocate AVPacket." << std::endl;
 exit(-6);
 }

 ost->st = avformat_new_stream(formatContext, nullptr);
 if (!ost->st) {
 std::cout << "Could not allocate stream." << std::endl;
 exit(-7);
 }

 ost->st->id = formatContext->nb_streams-1;
 c = avcodec_alloc_context3(*codec);
 if (!c) {
 std::cout << "Could not alloc an encoding context." << std::endl;
 exit(-8);
 }
 ost->enc = c;

 switch ((*codec)->type) {
 case AVMEDIA_TYPE_VIDEO:
 c->codec_id = codec_id;
 c->bit_rate = 6000000;
 /* Resolution must be a multiple of two. */
 c->width = width;
 c->height = height;
 /* timebase: This is the fundamental unit of time (in seconds) in terms
 * of which frame timestamps are represented. For fixed-fps content,
 * timebase should be 1/framerate and timestamp increments should be
 * identical to 1. */
 ost->st->time_base = { 1, fps };
 c->time_base = ost->st->time_base;
 c->framerate = { fps, 1 };

 c->gop_size = 0; /* emit one intra frame every twelve frames at most */
 c->pix_fmt = AV_PIX_FMT_YUV420P;
 if (c->codec_id == AV_CODEC_ID_MPEG2VIDEO) {
 /* just for testing, we also add B-frames */
 c->max_b_frames = 2;
 }
 if (c->codec_id == AV_CODEC_ID_MPEG1VIDEO) {
 /* Needed to avoid using macroblocks in which some coeffs overflow.
 * This does not happen with normal video, it just happens here as
 * the motion of the chroma plane does not match the luma plane.*/
 c->mb_decision = 2;
 }
 break;

 default:
 break;
 }

 /* Some formats want stream headers to be separate. */
 if (formatContext->oformat->flags & AVFMT_GLOBALHEADER)
 c->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
}

AVFrame *allocFrame(enum AVPixelFormat pix_fmt, int width, int height) {
 AVFrame *frame{ av_frame_alloc() };
 int ret;

 if (!frame)
 return nullptr;

 frame->format = pix_fmt;
 frame->width = width;
 frame->height = height;

 /* allocate the buffers for the frame data */
 ret = av_frame_get_buffer(frame, 0);
 if (ret < 0) {
 std::cout << "Could not allocate frame data." << std::endl;
 exit(-8);
 }

 return frame;
}

void openVideo(AVFormatContext *formatContext, const AVCodec *codec,
 OutputStream *ost, AVDictionary *opt_arg) {
 int ret;
 AVCodecContext *c{ ost->enc };
 AVDictionary *opt{ nullptr };

 av_dict_copy(&opt, opt_arg, 0);

 /* open the codec */
 ret = avcodec_open2(c, codec, &opt);
 av_dict_free(&opt);
 if (ret < 0) {
 std::cout << "Could not open video codec: " << av_err2str(ret) << std::endl;
 exit(-9);
 }

 /* Allocate and init a re-usable frame. */
 ost->frame = allocFrame(c->pix_fmt, c->width, c->height);
 if (!ost->frame) {
 std::cout << "Could not allocate video frame." << std::endl;
 exit(-10);
 }

 /* If the output format is not RGB24, then a temporary RGB24
 * picture is needed too. It is then converted to the required
 * output format. */
 ost->tmpFrame = nullptr;
 if (c->pix_fmt != AV_PIX_FMT_RGB24) {
 ost->tmpFrame = allocFrame(AV_PIX_FMT_RGB24, c->width, c->height);
 if (!ost->tmpFrame) {
 std::cout << "Could not allocate temporary video frame." << std::endl;
 exit(-11);
 }
 }

 /* Copy the stream parameters to the muxer. */
 ret = avcodec_parameters_from_context(ost->st->codecpar, c);
 if (ret < 0) {
 std::cout << "Could not copy the stream parameters." << std::endl;
 exit(-12);
 }
}

AVFrame *getVideoFrame(OutputStream *ost,
 const std::vector<glubyte>& pixels,
 int duration) {
 AVCodecContext *c{ ost->enc };

 /* check if we want to generate more frames */
 if (av_compare_ts(ost->nextPts, c->time_base,
 duration, { 1, 1 }) > 0) {
 return nullptr;
 }

 /* when we pass a frame to the encoder, it may keep a reference to it
 * internally; make sure we do not overwrite it here */
 if (av_frame_make_writable(ost->frame) < 0) {
 std::cout << "It wasn't possible to make frame writable." << std::endl;
 exit(-12);
 }

 if (c->pix_fmt != AV_PIX_FMT_RGB24) {
 /* as we only generate a YUV420P picture, we must convert it
 * to the codec pixel format if needed */
 if (!ost->swsContext) {
 ost->swsContext = sws_getContext(c->width, c->height,
 AV_PIX_FMT_RGB24,
 c->width, c->height,
 c->pix_fmt,
 SWS_BICUBIC, nullptr, nullptr, nullptr);
 if (!ost->swsContext) {
 std::cout << "Could not initialize the conversion context." << std::endl;
 exit(-13);
 }
 }

 fillRGBImage(ost->tmpFrame, c->width, c->height, pixels);
 sws_scale(ost->swsContext, (const uint8_t * const *) ost->tmpFrame->data,
 ost->tmpFrame->linesize, 0, c->height, ost->frame->data,
 ost->frame->linesize);
 } else
 fillRGBImage(ost->frame, c->width, c->height, pixels);

 ost->frame->pts = ost->nextPts++;

 return ost->frame;
}

int writeVideoFrame(AVFormatContext *formatContext,
 OutputStream *ost,
 const std::vector<glubyte>& pixels,
 int duration) {
 return writeFrame(formatContext,
 ost->enc,
 ost->st,
 getVideoFrame(ost, pixels, duration),
 ost->tmpPkt);
}

void closeStream(AVFormatContext *formatContext, OutputStream *ost) {
 avcodec_free_context(&ost->enc);
 av_frame_free(&ost->frame);
 av_frame_free(&ost->tmpFrame);
 av_packet_free(&ost->tmpPkt);
 sws_freeContext(ost->swsContext);
}

static void fillRGBImage(AVFrame *frame, int width, int height,
 const std::vector<glubyte>& pixels) {
 // Copy pixel data into the frame
 int inputLineSize{ 3 * width }; // 3 bytes per pixel for RGB
 for (int y{ 0 }; y < height; ++y) {
 memcpy(frame->data[0] + y * frame->linesize[0],
 pixels.data() + y * inputLineSize,
 inputLineSize);
 }
}
</glubyte></glubyte></glubyte></glubyte></string></glubyte></glubyte></glubyte></iostream>


-
ffmpeg got stuck while trying to crossfade merge two videos
30 juin 2017, par JeflopoI’m trying to do a crossfade merge (1s) between two videos. An intro (39secs duration) video with the main video. When I executed the command it started working without throwing errors but at some frame ffmpeg gets stuck.
I read a lot of q/a here in stackoverflow, and the official docs but I can’t solve this so :
This is the command :
ffmpeg -i "inputs/intro.mp4" -i "inputs/240p.mp4" -an -filter_complex \
"[0:v]trim=start=0:end=38,setpts=PTS-STARTPTS[firstclip]; \
[0:v]trim=start=38:end=39,setpts=PTS-STARTPTS[fadeoutsrc]; \
[1:v]trim=start=1,setpts=PTS-STARTPTS[secondclip]; \
[1:v]trim=start=0:end=1,setpts=PTS-STARTPTS[fadeinsrc]; \
[fadeinsrc]format=pix_fmts=yuva420p, fade=t=in:st=0:d=1:alpha=1[fadein]; \
[fadeoutsrc]format=pix_fmts=yuva420p, fade=t=out:st=0:d=1:alpha=1[fadeout]; \
[fadein]fifo[fadeinfifo]; \
[fadeout]fifo[fadeoutfifo]; \
[fadeoutfifo][fadeinfifo]overlay[crossfade]; \
[firstclip][crossfade][secondclip]concat=n=3[output]; \
[0:a][1:a] acrossfade=d=1 [audio]" -vcodec libx264 -map "[output]" -map "[audio]" "outputs/240p.mp4"Here’s the raw command (the exact command I used) :
ffmpeg -i "inputs/intro.mp4" -i "inputs/240p.mp4" -an -filter_complex "[0:v]trim=start=0:end=38,setpts=PTS-STARTPTS[firstclip]; [0:v]trim=start=38:end=39,setpts=PTS-STARTPTS[fadeoutsrc]; [1:v]trim=start=1,setpts=PTS-STARTPTS[secondclip]; [1:v]trim=start=0:end=1,setpts=PTS-STARTPTS[fadeinsrc]; [fadeinsrc]format=pix_fmts=yuva420p, fade=t=in:st=0:d=1:alpha=1[fadein]; [fadeoutsrc]format=pix_fmts=yuva420p, fade=t=out:st=0:d=1:alpha=1[fadeout]; [fadein]fifo[fadeinfifo]; [fadeout]fifo[fadeoutfifo]; [fadeoutfifo][fadeinfifo]overlay[crossfade]; [firstclip][crossfade][secondclip]concat=n=3[output]; [0:a][1:a] acrossfade=d=1 [audio]" -vcodec libx264 -map "[output]" -map "[audio]" "outputs/240p.mp4"
The "error" is reproducible with and without the
-an
and theacrossfade
filters.This is the output :
PS C:\scripts\ffmpeg> ffmpeg -i "inputs/intro.mp4" -i "inputs/240p.mp4" -an -filter_complex "[0:v]trim=start=0:end=38,setpts=PTS-STARTPTS[firstclip]; [0:v]trim=start=38:end=39,setpts=PTS-STARTPTS[fadeoutsrc]; [1:v]trim=start=1,setpts=PTS-STARTPTS[secondclip]; [1:v]trim=start=0:end=1,setpts=PTS-STARTPTS[fadeinsrc]; [fadeinsrc]format=pix_fmts=yuva420p, fade=t=in:st=0:d=1:alpha=1[fadein]; [fadeoutsrc]format=pix_fmts=yuva420p, fade=t=out:st=0:d=1:alpha=1[fadeout]; [fadein]fifo[fadeinfifo]; [fadeout]fifo[fadeoutfifo]; [fadeoutfifo][fadeinfifo]overlay[crossfade]; [firstclip][crossfade][secondclip]concat=n=3[output]; [0:a][1:a] acrossfade=d=1 [audio]" -map "[output]" -map "[audio]" "outputs/240p.mp4"
ffmpeg version N-86669-gc1d1274 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 7.1.0 (GCC)
configuration: --enable-gpl --enable-version3 --enable-cuda --enable-cuvid --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-nvenc --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-zlib
libavutil 55. 67.100 / 55. 67.100
libavcodec 57.100.102 / 57.100.102
libavformat 57. 75.100 / 57. 75.100
libavdevice 57. 7.100 / 57. 7.100
libavfilter 6. 94.100 / 6. 94.100
libswscale 4. 7.101 / 4. 7.101
libswresample 2. 8.100 / 2. 8.100
libpostproc 54. 6.100 / 54. 6.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'inputs/intro.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf57.72.101
Duration: 00:06:24.45, start: 0.000000, bitrate: 491 kb/s
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 426x240 [SAR 1:1 DAR 71:40], 353 kb/s, 25 fps, 25 tbr, 12800 tbn, 50 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 130 kb/s (default)
Metadata:
handler_name : SoundHandler
Input #1, mov,mp4,m4a,3gp,3g2,mj2, from 'inputs/240p.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.40.101
Duration: 00:06:24.43, start: 0.000000, bitrate: 375 kb/s
Stream #1:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p, 426x240 [SAR 1:1 DAR 71:40], 243 kb/s, 25 fps, 25 tbr, 90k tbn, 50 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #1:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 125 kb/s (default)
Metadata:
handler_name : SoundHandler
Stream mapping:
Stream #0:0 (h264) -> trim
Stream #0:0 (h264) -> trim
Stream #0:1 (aac) -> acrossfade:crossfade0
Stream #1:0 (h264) -> trim
Stream #1:0 (h264) -> trim
Stream #1:1 (aac) -> acrossfade:crossfade1
concat -> Stream #0:0 (libx264)
acrossfade -> Stream #0:1 (aac)
Press [q] to stop, [?] for help
[libx264 @ 00000000026b2240] using SAR=1/1
[libx264 @ 00000000026b2240] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 00000000026b2240] profile High, level 2.1
[libx264 @ 00000000026b2240] 264 - core 152 r2851 ba24899 - H.264/MPEG-4 AVC codec - Copyleft 2003-2017 - http://www.videolan.org/x264.html - options: 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=7 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
Output #0, mp4, to 'outputs/240p.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf57.75.100
Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 426x240 [SAR 1:1 DAR 71:40], q=-1--1, 25 fps, 12800 tbn, 25 tbc (default)
Metadata:
encoder : Lavc57.100.102 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
Stream #0:1: Audio: aac (LC) ([64][0][0][0] / 0x0040), 44100 Hz, stereo, fltp, 128 kb/s (default)
Metadata:
encoder : Lavc57.100.102 aac
frame=10369 fps=503 q=28.0 size= 24064kB time=00:06:55.68 bitrate= 474.2kbits/s speed=20.2xAt frame 10000 it gets stuck... I waited for 1hour but it keeps stuck.
I’ve updated ffmpeg :
ffmpeg -version
ffmpeg version N-86669-gc1d1274 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 7.1.0 (GCC)
configuration: --enable-gpl --enable-version3 --enable-cuda --enable-cuvid --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-nvenc --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-zlib
libavutil 55. 67.100 / 55. 67.100
libavcodec 57.100.102 / 57.100.102
libavformat 57. 75.100 / 57. 75.100
libavdevice 57. 7.100 / 57. 7.100
libavfilter 6. 94.100 / 6. 94.100
libswscale 4. 7.101 / 4. 7.101
libswresample 2. 8.100 / 2. 8.100
libpostproc 54. 6.100 / 54. 6.100I used these references :