summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Stebbins <[email protected]>2019-01-18 16:40:14 -0800
committerJohn Stebbins <[email protected]>2019-01-21 16:26:14 -0800
commita4f27a449479afbd69b96bb52f36ddd5a00b8e04 (patch)
treeb9d382ea60f4bc1ac5e9001251a524f8cd2a4d3f
parent2a313ee5c3e12c2f75e88f99d4ad4ce0f78f17a5 (diff)
scan: only apply min duration filter to BD and DVD
Fixes https://github.com/HandBrake/HandBrake/issues/1590
-rw-r--r--gtk/src/ghb.m42
-rw-r--r--libhb/batch.c7
-rw-r--r--libhb/internal.h3
-rw-r--r--libhb/scan.c5
4 files changed, 5 insertions, 12 deletions
diff --git a/gtk/src/ghb.m4 b/gtk/src/ghb.m4
index 514403aae..d9dea4c8a 100644
--- a/gtk/src/ghb.m4
+++ b/gtk/src/ghb.m4
@@ -6572,7 +6572,7 @@ filter_output([
<object class="GtkLabel" id="label70">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">Filter short titles (seconds)</property>
+ <property name="label" translatable="yes">Filter short DVD and Blu-ray titles (seconds)</property>
<property name="use_markup">True</property>
</object>
<packing>
diff --git a/libhb/batch.c b/libhb/batch.c
index 9af32393a..02c79893a 100644
--- a/libhb/batch.c
+++ b/libhb/batch.c
@@ -120,7 +120,7 @@ int hb_batch_title_count( hb_batch_t * d )
/***********************************************************************
* hb_batch_title_scan
**********************************************************************/
-hb_title_t * hb_batch_title_scan( hb_batch_t * d, int t, uint64_t min_duration )
+hb_title_t * hb_batch_title_scan( hb_batch_t * d, int t )
{
hb_title_t * title;
@@ -145,11 +145,6 @@ hb_title_t * hb_batch_title_scan( hb_batch_t * d, int t, uint64_t min_duration )
title = hb_stream_title_scan( stream, title );
hb_stream_close( &stream );
- if( title != NULL && title->duration < min_duration )
- {
- hb_log( "batch: ignoring title (too short)" );
- hb_title_close(&title);
- }
return title;
}
diff --git a/libhb/internal.h b/libhb/internal.h
index dde908397..1284a1ff0 100644
--- a/libhb/internal.h
+++ b/libhb/internal.h
@@ -303,8 +303,7 @@ typedef struct hb_batch_s hb_batch_t;
hb_batch_t * hb_batch_init( hb_handle_t *h, char * path );
void hb_batch_close( hb_batch_t ** _d );
int hb_batch_title_count( hb_batch_t * d );
-hb_title_t * hb_batch_title_scan( hb_batch_t * d, int t,
- uint64_t min_duration );
+hb_title_t * hb_batch_title_scan( hb_batch_t * d, int t );
/***********************************************************************
* dvd.c
diff --git a/libhb/scan.c b/libhb/scan.c
index a6c5d2eae..b034acc88 100644
--- a/libhb/scan.c
+++ b/libhb/scan.c
@@ -155,7 +155,7 @@ static void ScanFunc( void * _data )
if( data->title_index )
{
/* Scan this title only */
- title = hb_batch_title_scan(data->batch, data->title_index, 0);
+ title = hb_batch_title_scan(data->batch, data->title_index);
if ( title )
{
hb_list_add( data->title_set->list_title, title );
@@ -169,8 +169,7 @@ static void ScanFunc( void * _data )
hb_title_t * title;
UpdateState1(data, i + 1);
- title = hb_batch_title_scan(data->batch, i + 1,
- data->min_title_duration);
+ title = hb_batch_title_scan(data->batch, i + 1);
if ( title != NULL )
{
hb_list_add( data->title_set->list_title, title );