diff options
author | jstebbins <[email protected]> | 2011-03-08 16:12:57 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2011-03-08 16:12:57 +0000 |
commit | 673a841b1ef2dcd31647fce00829dc4a3f2b0715 (patch) | |
tree | b11d12d19c798463a8756d8f5f989e6d2865765b /libhb/muxmkv.c | |
parent | 6444014c71cd881ad4874e96a6138ea268be8b4d (diff) |
make keyint match between 1st and 2nd passes of vfr and pfr encodes.
make keyint and fps settings consistent across video encoders.
make interjob->vrate changes for pfr mode like we do for vfr since
pfr is the same as vfr except when it hits it's peak.
in mkv, set track default duration to actual measured vrate on 2 pass encodes.
thanks to Rodeo for the corrections in encx264
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3831 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/muxmkv.c')
-rw-r--r-- | libhb/muxmkv.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/libhb/muxmkv.c b/libhb/muxmkv.c index 073b39f45..f169e3de1 100644 --- a/libhb/muxmkv.c +++ b/libhb/muxmkv.c @@ -148,8 +148,19 @@ static int MKVInit( hb_mux_object_t * m ) track->extra.video.displayWidth = job->width; } - - track->defaultDuration = (int64_t)(((float)job->vrate_base / (float)job->vrate) * 1000000000); + int vrate_base, vrate; + if( job->pass == 2 ) + { + hb_interjob_t * interjob = hb_interjob_get( job->h ); + vrate_base = interjob->vrate_base; + vrate = interjob->vrate; + } + else + { + vrate_base = job->vrate_base; + vrate = job->vrate; + } + track->defaultDuration = (int64_t)(((float)vrate_base / (float)vrate) * 1000000000); mux_data->track = mk_createTrack(m->file, track); |