diff options
author | Anton Khirnov <anton@khirnov.net> | 2012-03-12 17:20:20 +0100 |
---|---|---|
committer | Reinhard Tartler <siretart@tauware.de> | 2012-03-14 21:00:12 +0100 |
commit | 6548cb25782d05c1ea52bb6904c2b2b398079b8b (patch) | |
tree | 5748d8ace1ee558c06b940b6c2a91fece0d4fade /libavcodec | |
parent | f6257cf4b710eed9f05d9dcbca853d236d3cdd56 (diff) | |
download | ffmpeg-6548cb25782d05c1ea52bb6904c2b2b398079b8b.tar.gz |
libx264: add 'stats' private option for setting 2pass stats filename.
x264 always opens the file itself with fopen, so we cannot use the
standard lavc stats mechanism.
CC: libav-stable@libav.org
(cherry picked from commit d533e395e14d403948ca2424efbcee92429ef8e1)
Signed-off-by: Reinhard Tartler <siretart@tauware.de>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/libx264.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c index 96c9588ece..ac0f6b6d05 100644 --- a/libavcodec/libx264.c +++ b/libavcodec/libx264.c @@ -66,6 +66,7 @@ typedef struct X264Context { char *partitions; int direct_pred; int slice_max_size; + char *stats; } X264Context; static void X264_log(void *p, int level, const char *fmt, va_list args) @@ -379,6 +380,7 @@ static av_cold int X264_init(AVCodecContext *avctx) PARSE_X264_OPT("psy-rd", psy_rd); PARSE_X264_OPT("deblock", deblock); PARSE_X264_OPT("partitions", partitions); + PARSE_X264_OPT("stats", stats); if (x4->psy >= 0) x4->params.analyse.b_psy = x4->psy; if (x4->rc_lookahead >= 0) @@ -553,6 +555,7 @@ static const AVOption options[] = { { "temporal", NULL, 0, AV_OPT_TYPE_CONST, { X264_DIRECT_PRED_TEMPORAL }, 0, 0, VE, "direct-pred" }, { "auto", NULL, 0, AV_OPT_TYPE_CONST, { X264_DIRECT_PRED_AUTO }, 0, 0, VE, "direct-pred" }, { "slice-max-size","Limit the size of each slice in bytes", OFFSET(slice_max_size),AV_OPT_TYPE_INT, {-1 }, -1, INT_MAX, VE }, + { "stats", "Filename for 2 pass stats", OFFSET(stats), AV_OPT_TYPE_STRING, { 0 }, 0, 0, VE }, { NULL }, }; |