diff options
author | Rodeo <[email protected]> | 2012-07-29 14:27:59 +0000 |
---|---|---|
committer | Rodeo <[email protected]> | 2012-07-29 14:27:59 +0000 |
commit | cb166e012b97a2dc164dc2f7602f64b79a757412 (patch) | |
tree | 2df0e76f529ed1b8e4eedb550f3879c3f8cafeb3 /libhb/work.c | |
parent | d3593cb63f7a6c8602faae00f04da378f060fb4c (diff) |
work: don't sanitize output bitrate etc. for passthrough audio.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4880 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/work.c')
-rw-r--r-- | libhb/work.c | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/libhb/work.c b/libhb/work.c index 6e49687da..acd57b4f6 100644 --- a/libhb/work.c +++ b/libhb/work.c @@ -816,9 +816,22 @@ static void do_job( hb_job_t * job ) { audio = hb_list_item( title->list_audio, i ); + /* set up the audio work structures */ + audio->priv.fifo_raw = hb_fifo_init(FIFO_SMALL, FIFO_SMALL_WAKE); + audio->priv.fifo_sync = hb_fifo_init(FIFO_SMALL, FIFO_SMALL_WAKE); + audio->priv.fifo_out = hb_fifo_init(FIFO_LARGE, FIFO_LARGE_WAKE); + audio->priv.fifo_in = hb_fifo_init(FIFO_LARGE, FIFO_LARGE_WAKE); + + /* Passthru audio, nothing to sanitize here */ + if (audio->config.out.codec & HB_ACODEC_PASS_FLAG) + continue; + + /* Vorbis language information */ + if (audio->config.out.codec == HB_ACODEC_VORBIS) + audio->priv.config.vorbis.language = audio->config.lang.simple; + /* sense-check the requested mixdown */ - if( audio->config.out.mixdown <= HB_AMIXDOWN_NONE && - !( audio->config.out.codec & HB_ACODEC_PASS_FLAG ) ) + if (audio->config.out.mixdown <= HB_AMIXDOWN_NONE) { /* * Mixdown wasn't specified and this is not pass-through, @@ -964,15 +977,6 @@ static void do_job( hb_job_t * job ) } audio->config.out.bitrate = best_bitrate; } - - if (audio->config.out.codec == HB_ACODEC_VORBIS) - audio->priv.config.vorbis.language = audio->config.lang.simple; - - /* set up the audio work structures */ - audio->priv.fifo_raw = hb_fifo_init( FIFO_SMALL, FIFO_SMALL_WAKE ); - audio->priv.fifo_sync = hb_fifo_init( FIFO_SMALL, FIFO_SMALL_WAKE ); - audio->priv.fifo_out = hb_fifo_init( FIFO_LARGE, FIFO_LARGE_WAKE ); - audio->priv.fifo_in = hb_fifo_init( FIFO_LARGE, FIFO_LARGE_WAKE ); } } |