[vlc-commits] x264.c: support infinite keyint option with -1
Ilkka Ollakka
git at videolan.org
Thu Jan 5 09:25:18 CET 2012
vlc | branch: master | Ilkka Ollakka <ileoo at videolan.org> | Thu Jan 5 12:41:36 2012 +0200| [d06b1ce64a4438ffbab18b87a5c4eabcc0b90a46] | committer: Ilkka Ollakka
x264.c: support infinite keyint option with -1
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=d06b1ce64a4438ffbab18b87a5c4eabcc0b90a46
---
modules/codec/x264.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/modules/codec/x264.c b/modules/codec/x264.c
index 96cdf3d..c5d63d2 100644
--- a/modules/codec/x264.c
+++ b/modules/codec/x264.c
@@ -57,7 +57,7 @@ static void Close( vlc_object_t * );
#define KEYINT_TEXT N_("Maximum GOP size")
#define KEYINT_LONGTEXT N_( "Sets maximum interval between IDR-frames." \
"Larger values save bits, thus improving quality for a given bitrate at " \
- "the cost of seeking precision." )
+ "the cost of seeking precision. Use -1 for infinite." )
#define MIN_KEYINT_TEXT N_("Minimum GOP size")
#define MIN_KEYINT_LONGTEXT N_( "Sets minimum interval between IDR-frames. " \
@@ -924,6 +924,9 @@ static int Open ( vlc_object_t *p_this )
i_val = var_GetInteger( p_enc, SOUT_CFG_PREFIX "keyint" );
if( i_val > 0 && i_val != 250 ) p_sys->param.i_keyint_max = i_val;
+#if X264_BUILD >= 102
+ if( i_val == -1 ) p_sys->param.i_keyint_max = X264_KEYINT_MAX_INFINITE;
+#endif
i_val = var_GetInteger( p_enc, SOUT_CFG_PREFIX "min-keyint" );
if( i_val > 0 && i_val != 25 ) p_sys->param.i_keyint_min = i_val;
More information about the vlc-commits
mailing list