diff options
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/src/audiohandler.c | 4 | ||||
-rw-r--r-- | gtk/src/hb-backend.c | 21 |
2 files changed, 8 insertions, 17 deletions
diff --git a/gtk/src/audiohandler.c b/gtk/src/audiohandler.c index 78d405fd8..6ca014895 100644 --- a/gtk/src/audiohandler.c +++ b/gtk/src/audiohandler.c @@ -99,10 +99,10 @@ ghb_adjust_audio_rate_combos(signal_user_data_t *ud) } else { - ghb_ui_update(ud, "AudioBitrate", ghb_int64_value(384)); ghb_ui_update(ud, "AudioSamplerate", ghb_int64_value(0)); ghb_ui_update(ud, "AudioMixdown", ghb_int64_value(0)); - select_acodec = HB_ACODEC_AC3; + bitrate = 448; + mix = ghb_get_best_mix( titleindex, track, select_acodec, 0); } ghb_ui_update(ud, "AudioTrackDRCSlider", ghb_double_value(0)); } diff --git a/gtk/src/hb-backend.c b/gtk/src/hb-backend.c index 20ced8f69..5f8347858 100644 --- a/gtk/src/hb-backend.c +++ b/gtk/src/hb-backend.c @@ -1656,22 +1656,13 @@ ghb_find_closest_audio_bitrate(gint codec, gint rate) gint ghb_get_best_audio_bitrate(gint acodec, gint br, gint channels) { - if (acodec & HB_ACODEC_FAAC) - { - int maxbr; + int low, high; - if (channels == 2) - maxbr = 320; - else - maxbr = 768; - if (br > maxbr) - br = maxbr; - } - if (acodec & HB_ACODEC_AC3) - { - if (br > 640) - br = 640; - } + ghb_get_audio_bitrate_limits(acodec, channels, &low, &high); + if (br > high) + br = high; + if (br < low) + br = low; br = ghb_find_closest_audio_bitrate(acodec, br); return br; } |