From ac3bf7428bf4c3c79280ec7e1f174c0b47ec2b5b Mon Sep 17 00:00:00 2001 From: prigaux Date: Thu, 18 Jan 2007 10:26:35 +0000 Subject: [PATCH] PixelRatio Test branch with mp4 working and latest contrib libs git-svn-id: svn://svn.handbrake.fr/HandBrake/branches/PixelRatioWorking@122 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- work.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/work.c b/work.c index 127ff8315..8afff0aec 100644 --- a/work.c +++ b/work.c @@ -103,6 +103,12 @@ static void do_job( hb_job_t * job, int cpu_count ) hb_log( " + device %s", title->dvd ); hb_log( " + title %d, chapter(s) %d to %d", title->index, job->chapter_start, job->chapter_end ); + if ( job->pixel_ratio == 1 ) + { + /* Correct the geometry of the output movie when using PixelRatio */ + job->height=title->height-job->crop[0]-job->crop[1]; + job->width=title->width-job->crop[2]-job->crop[3]; + } hb_log( " + %dx%d -> %dx%d, crop %d/%d/%d/%d", title->width, title->height, job->width, job->height, job->crop[0], job->crop[1], job->crop[2], job->crop[3] ); @@ -119,7 +125,7 @@ static void do_job( hb_job_t * job, int cpu_count ) (float) job->vrate / (float) job->vrate_base, job->vbitrate, job->pass ); } - + hb_log ("PixelRatio: %d, width:%d, height: %d",job->pixel_ratio,job->width, job->height); job->fifo_mpeg2 = hb_fifo_init( 2048, "mpeg2" ); job->fifo_raw = hb_fifo_init( 8, "raw" ); job->fifo_sync = hb_fifo_init( 8, "sync" ); -- 2.40.0