X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=libhb%2Fscan.c;h=68188a25344b30d3593bdb5ead33e2795895fa68;hb=4f0019f03c2e85e8634150ff0c9a31bee6d35ce5;hp=f93e6a24b05494c1523a50441867b613a259a1fa;hpb=e3bda03cee4f86a664057ba1ebfd85eb71e3128f;p=handbrake-jp%2Fhandbrake-jp-git.git diff --git a/libhb/scan.c b/libhb/scan.c index f93e6a24..68188a25 100644 --- a/libhb/scan.c +++ b/libhb/scan.c @@ -69,6 +69,7 @@ static void ScanFunc( void * _data ) hb_scan_t * data = (hb_scan_t *) _data; hb_title_t * title; int i; + int feature = 0; data->dvd = NULL; data->stream = NULL; @@ -93,6 +94,7 @@ static void ScanFunc( void * _data ) hb_list_add( data->list_title, hb_dvd_title_scan( data->dvd, i + 1 ) ); } + feature = hb_dvd_main_feature( data->dvd, data->list_title ); } } else if ( ( data->batch = hb_batch_init( data->path ) ) ) @@ -171,6 +173,22 @@ static void ScanFunc( void * _data ) j++; } + if ( data->dvd ) + { + // The subtitle width and height needs to be set to the + // title widht and height for DVDs. title width and + // height don't get set until we decode previews, so + // we can't set subtitle width/height till we get here. + for( j = 0; j < hb_list_count( title->list_subtitle ); j++ ) + { + hb_subtitle_t *subtitle = hb_list_item( title->list_subtitle, j ); + if ( subtitle->source == VOBSUB ) + { + subtitle->width = title->width; + subtitle->height = title->height; + } + } + } i++; } @@ -184,6 +202,7 @@ static void ScanFunc( void * _data ) title->job = job; job->title = title; + job->feature = feature; /* Set defaults settings */ job->chapter_start = 1;