diff options
author | jstebbins <[email protected]> | 2011-10-15 21:32:20 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2011-10-15 21:32:20 +0000 |
commit | 0646bd60a8f672a003195e1c83ebbcb08d05aa99 (patch) | |
tree | 7a0655dddf26d2a5463f6ea59a0e6e802119e867 /libhb/encavcodec.c | |
parent | e3cbf2a342b7093d0b0b1720d3b3c933c3a4fa69 (diff) |
bump Libav from v0.7.1 to v0.7-1241-g5f3fb59
Fixes VC-1 decode issue
Adds partial support for interlaced VC-1 decode
Adds ProRes decoder
Fixes ac3 encoder dolby flag
Fixes DCA frame size setting (delete patch A04)
Fixes VC-1 repeat field processing (delete patch A05)
Numerous other bug fixes and enhancements
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4291 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/encavcodec.c')
-rw-r--r-- | libhb/encavcodec.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/libhb/encavcodec.c b/libhb/encavcodec.c index 965752aa9..a3164f4a8 100644 --- a/libhb/encavcodec.c +++ b/libhb/encavcodec.c @@ -167,6 +167,7 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) the left side of the equals sign in "name" and the right side into "value." Then you hand those strings off to avutil for interpretation. */ + AVDictionary *av_opts = NULL; if( job->advanced_opts != NULL && *job->advanced_opts != '\0' ) { char *opts, *opts_start; @@ -179,7 +180,6 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) { char *name = opts; char *value; - int ret; opts += strcspn( opts, ":" ); if( *opts ) @@ -196,15 +196,7 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) } /* Here's where the strings are passed to avutil for parsing. */ - ret = hb_av_set_string( context, codec, name, value ); - - /* Let avutil sanity check the options for us*/ - if( ret == AVERROR_OPTION_NOT_FOUND ) - hb_log( "avcodec options: Unknown option %s", name ); - - if( ret == AVERROR(EINVAL) ) - hb_log( "avcodec options: Bad argument %s=%s", - name, value ? value : "(null)" ); + av_dict_set( &av_opts, name, value, 0 ); } } free(opts_start); @@ -282,10 +274,19 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job ) } } - if( hb_avcodec_open( context, codec, 0 ) ) + if( hb_avcodec_open( context, codec, &av_opts, 0 ) ) { hb_log( "encavcodecInit: avcodec_open failed" ); } + // avcodec_open populates the opts dictionary with the + // things it didn't recognize. + AVDictionaryEntry *t = NULL; + while( ( t = av_dict_get( av_opts, "", t, AV_DICT_IGNORE_SUFFIX ) ) ) + { + hb_log( "encavcodecInit: Unknown avcodec option %s", t->key ); + } + av_dict_free( &av_opts ); + pv->context = context; job->areBframes = 0; |