diff options
author | Rodeo <[email protected]> | 2012-03-29 13:31:33 +0000 |
---|---|---|
committer | Rodeo <[email protected]> | 2012-03-29 13:31:33 +0000 |
commit | a0fd4604194e63f5219b1da61afcd19d4bdcfc9f (patch) | |
tree | d7de3205ae96abb67f906525abcb8676bec750ba /libhb/encx264.c | |
parent | 5cfc8521de5547646afd47b46c8565dac351c50d (diff) |
encx264: add functionality to retrieve the "preferred" option name for options that have multiple names.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4554 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/encx264.c')
-rw-r--r-- | libhb/encx264.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/libhb/encx264.c b/libhb/encx264.c index 7345ab20e..4316ea427 100644 --- a/libhb/encx264.c +++ b/libhb/encx264.c @@ -179,7 +179,7 @@ int encx264Init( hb_work_object_t * w, hb_job_t * job ) hb_dict_t * x264_opts = NULL; if( job->advanced_opts != NULL && *job->advanced_opts != '\0' ) { - x264_opts = hb_encopts_to_dict( job->advanced_opts ); + x264_opts = hb_encopts_to_dict( job->advanced_opts, job->vcodec ); } /* iterate through x264_opts and have libx264 parse the options for us */ int ret; @@ -835,3 +835,12 @@ const char * const * hb_h264_levels() { return h264_level_names; } + +const char * hb_x264_encopt_name( const char * name ) +{ + int i; + for( i = 0; x264_encopt_synonyms[i] && x264_encopt_synonyms[i+1]; i += 2 ) + if( !strcmp( name, x264_encopt_synonyms[i+1] ) ) + return x264_encopt_synonyms[i]; + return name; +} |