diff options
author | jbrjake <[email protected]> | 2007-08-17 20:57:52 +0000 |
---|---|---|
committer | jbrjake <[email protected]> | 2007-08-17 20:57:52 +0000 |
commit | 83dff35ea5df6925b065f16fdfb4982ad1f75107 (patch) | |
tree | a76f26a10d218be9996213078edd343d8addee72 /libhb | |
parent | 37b46c3c36e4f12caeb8743e102876db96711017 (diff) |
Prevents a bus error at scan time with DVDs that have a weird cell structure. Much gratitude to dynaflash, as without his patient assistance tele-debugging this, I would have been forced to buy a copy of Young Guns.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@828 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb')
-rw-r--r-- | libhb/decmpeg2.c | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/libhb/decmpeg2.c b/libhb/decmpeg2.c index 359a79e35..77c6c0b98 100644 --- a/libhb/decmpeg2.c +++ b/libhb/decmpeg2.c @@ -302,16 +302,19 @@ void hb_libmpeg2_info( hb_libmpeg2_t * m, int * width, int * height, { *width = m->width; *height = m->height; - if( (m->info->display_picture->flags & PROGRESSIVE) && (m->height == 480) ) - { - /* The frame is progressive and it's NTSC DVD height, so change its FPS to 23.976. - This might not be correct for the title. It's really just for scan.c's benefit. - Scan.c will reset the fps to 29.97, until a simple majority of the preview - frames report at 23.976. - */ - //hb_log("Detecting NTSC Progressive Frame"); - m->rate = 1126125; - } + if (m->info->display_fbuf) + { + if( (m->info->display_picture->flags & PROGRESSIVE) && (m->height == 480) ) + { + /* The frame is progressive and it's NTSC DVD height, so change its FPS to 23.976. + This might not be correct for the title. It's really just for scan.c's benefit. + Scan.c will reset the fps to 29.97, until a simple majority of the preview + frames report at 23.976. + */ + //hb_log("Detecting NTSC Progressive Frame"); + m->rate = 1126125; + } + } *rate = m->rate; *aspect_ratio = m->aspect_ratio; } |