diff options
author | Rodeo <[email protected]> | 2011-12-23 19:47:28 +0000 |
---|---|---|
committer | Rodeo <[email protected]> | 2011-12-23 19:47:28 +0000 |
commit | 015a2a45691dee523047f3b2a1a3628a2dd106f9 (patch) | |
tree | ab5d16dc8926008392562065f4c94101d3f062c8 | |
parent | eef8f901a34f163693bd3f79d0e2265d592b880e (diff) |
Use -2 to 10 range for Vorbis audio quality (same as what oggenc uses), instead of the native libvorbis API values. This is what users will expect.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4385 b64f7644-9d1e-0410-96f1-a4d463321fa5
-rw-r--r-- | libhb/common.c | 6 | ||||
-rw-r--r-- | libhb/encvorbis.c | 3 |
2 files changed, 5 insertions, 4 deletions
diff --git a/libhb/common.c b/libhb/common.c index 65be729b8..5f0d058ed 100644 --- a/libhb/common.c +++ b/libhb/common.c @@ -518,9 +518,9 @@ void hb_get_audio_quality_limits(uint32_t codec, float *low, float *high, float case HB_ACODEC_VORBIS: *direction = 0; - *granularity = 0.05; - *low = -0.2; - *high = 1.0; + *granularity = 0.5; + *low = -2.0; + *high = 10.0; break; case HB_ACODEC_CA_AAC: diff --git a/libhb/encvorbis.c b/libhb/encvorbis.c index 5507fac47..bbbc19785 100644 --- a/libhb/encvorbis.c +++ b/libhb/encvorbis.c @@ -87,8 +87,9 @@ int encvorbisInit( hb_work_object_t * w, hb_job_t * job ) } else if( audio->config.out.quality != -1 ) { + // map VBR quality to Vorbis API (divide by 10) if( vorbis_encode_setup_vbr( &pv->vi, pv->out_discrete_channels, - audio->config.out.samplerate, audio->config.out.quality ) ) + audio->config.out.samplerate, audio->config.out.quality/10 ) ) { hb_error( "encvorbis: vorbis_encode_setup_vbr failed.\n" ); *job->die = 1; |