summaryrefslogtreecommitdiffstats
path: root/libhb
diff options
context:
space:
mode:
authorJohn Stebbins <[email protected]>2015-09-03 10:16:03 -0700
committerJohn Stebbins <[email protected]>2015-09-04 08:44:03 -0700
commit85133c49d2dc34060159c8f9f16cd508bb9d08d2 (patch)
tree2bc98d6385873e0b6699a8a2708f44d72220a538 /libhb
parent93a0685f2cad12828ad62d112eb1ddaac1af3a32 (diff)
libhb: remove unused hb_buffer_t.sub
Diffstat (limited to 'libhb')
-rw-r--r--libhb/cropscale.c1
-rw-r--r--libhb/deblock.c1
-rw-r--r--libhb/decomb.c3
-rw-r--r--libhb/deinterlace.c5
-rw-r--r--libhb/denoise.c2
-rw-r--r--libhb/detelecine.c2
-rw-r--r--libhb/fifo.c38
-rw-r--r--libhb/internal.h13
-rw-r--r--libhb/rendersub.c6
-rw-r--r--libhb/rotate.c3
-rw-r--r--libhb/sync.c1
11 files changed, 2 insertions, 73 deletions
diff --git a/libhb/cropscale.c b/libhb/cropscale.c
index a8a995a6c..733602457 100644
--- a/libhb/cropscale.c
+++ b/libhb/cropscale.c
@@ -217,7 +217,6 @@ static hb_buffer_t* crop_scale( hb_filter_private_t * pv, hb_buffer_t * in )
}
out->s = in->s;
- hb_buffer_move_subs( out, in );
return out;
}
diff --git a/libhb/deblock.c b/libhb/deblock.c
index e05f2e21e..e48d89ced 100644
--- a/libhb/deblock.c
+++ b/libhb/deblock.c
@@ -439,7 +439,6 @@ static int hb_deblock_work( hb_filter_object_t * filter,
0 );
out->s = in->s;
- hb_buffer_move_subs( out, in );
*buf_out = out;
}
diff --git a/libhb/decomb.c b/libhb/decomb.c
index 1f6be45c8..b00d7ce27 100644
--- a/libhb/decomb.c
+++ b/libhb/decomb.c
@@ -2655,9 +2655,6 @@ static int hb_decomb_work( hb_filter_object_t * filter,
}
}
}
- // Copy subs only to first output buffer
- hb_buffer_move_subs( out, pv->ref[1] );
-
hb_buffer_close(&o_buf[0]);
hb_buffer_close(&o_buf[1]);
diff --git a/libhb/deinterlace.c b/libhb/deinterlace.c
index 0e8de8d8e..cd68a6070 100644
--- a/libhb/deinterlace.c
+++ b/libhb/deinterlace.c
@@ -427,7 +427,6 @@ static hb_buffer_t * deint_fast(hb_filter_private_t * pv, hb_buffer_t * in)
last = dst;
dst->s = src->s;
- hb_buffer_move_subs(dst, src);
hb_buffer_close(&src);
}
if (in == NULL)
@@ -675,10 +674,6 @@ static int hb_deinterlace_work( hb_filter_object_t * filter,
idx ^= 1;
}
}
-
- // Copy subs only to first output buffer
- hb_buffer_move_subs( out, pv->yadif_ref[1] );
-
hb_buffer_close(&o_buf[0]);
hb_buffer_close(&o_buf[1]);
diff --git a/libhb/denoise.c b/libhb/denoise.c
index 8057b6c7d..2b6c6c4cf 100644
--- a/libhb/denoise.c
+++ b/libhb/denoise.c
@@ -364,8 +364,6 @@ static int hb_denoise_work( hb_filter_object_t * filter,
}
out->s = in->s;
- hb_buffer_move_subs( out, in );
-
*buf_out = out;
return HB_FILTER_OK;
diff --git a/libhb/detelecine.c b/libhb/detelecine.c
index 983db217f..3d79d2595 100644
--- a/libhb/detelecine.c
+++ b/libhb/detelecine.c
@@ -1023,8 +1023,6 @@ static int hb_detelecine_work( hb_filter_object_t * filter,
pullup_release_frame( frame );
out->s = in->s;
- hb_buffer_move_subs( out, in );
-
*buf_out = out;
output_frame:
diff --git a/libhb/fifo.c b/libhb/fifo.c
index 72c1c181f..0a4c0ae3d 100644
--- a/libhb/fifo.c
+++ b/libhb/fifo.c
@@ -686,9 +686,6 @@ void hb_buffer_close( hb_buffer_t ** _b )
hb_list_rem(buffers.alloc_list, b);
hb_unlock(buffers.lock);
#endif
- // Close any attached subtitle buffers
- hb_buffer_close( &b->sub );
-
if( buffer_pool && b->data && !hb_fifo_is_full( buffer_pool ) )
{
hb_fifo_push_head( buffer_pool, b );
@@ -723,18 +720,6 @@ void hb_buffer_close( hb_buffer_t ** _b )
*_b = NULL;
}
-void hb_buffer_move_subs( hb_buffer_t * dst, hb_buffer_t * src )
-{
- // Note that dst takes ownership of the subtitles
- dst->sub = src->sub;
- src->sub = NULL;
-
-#ifdef USE_QSV
- memcpy(&dst->qsv_details, &src->qsv_details, sizeof(src->qsv_details));
-#endif
-
-}
-
hb_image_t * hb_image_init(int pix_fmt, int width, int height)
{
const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmt);
@@ -1175,29 +1160,6 @@ void hb_fifo_push_head( hb_fifo_t * f, hb_buffer_t * b )
hb_unlock( f->lock );
}
-// Pushes a list of packets onto the specified FIFO as a single element.
-void hb_fifo_push_list_element( hb_fifo_t *fifo, hb_buffer_t *buffer_list )
-{
- hb_buffer_t *container = hb_buffer_init( 0 );
- // XXX: Using an arbitrary hb_buffer_t pointer (other than 'next')
- // to carry the list inside a single "container" buffer
- container->sub = buffer_list;
-
- hb_fifo_push( fifo, container );
-}
-
-// Removes a list of packets from the specified FIFO that were stored as a single element.
-hb_buffer_t *hb_fifo_get_list_element( hb_fifo_t *fifo )
-{
- hb_buffer_t *container = hb_fifo_get( fifo );
- // XXX: Using an arbitrary hb_buffer_t pointer (other than 'next')
- // to carry the list inside a single "container" buffer
- hb_buffer_t *buffer_list = container->sub;
- hb_buffer_close( &container );
-
- return buffer_list;
-}
-
void hb_fifo_close( hb_fifo_t ** _f )
{
hb_fifo_t * f = *_f;
diff --git a/libhb/internal.h b/libhb/internal.h
index 4be0dffc3..0192dab66 100644
--- a/libhb/internal.h
+++ b/libhb/internal.h
@@ -160,16 +160,6 @@ struct hb_buffer_s
// Store this data here when read and pass to decoder.
hb_buffer_t * palette;
- // PICTURESUB subtitle packets:
-
- // Video packets (after processing by the hb_sync_video work-object):
- // A (copy of a) PICTURESUB subtitle packet that needs to be burned into
- // this video packet by the vobsub renderer filter
- //
- // Subtitles that are simply passed thru are NOT attached to the
- // associated video packets.
- hb_buffer_t * sub;
-
// Packets in a list:
// the next packet in the list
hb_buffer_t * next;
@@ -189,7 +179,6 @@ void hb_buffer_close( hb_buffer_t ** );
hb_buffer_t * hb_buffer_dup( const hb_buffer_t * src );
int hb_buffer_copy( hb_buffer_t * dst, const hb_buffer_t * src );
void hb_buffer_swap_copy( hb_buffer_t *src, hb_buffer_t *dst );
-void hb_buffer_move_subs( hb_buffer_t * dst, hb_buffer_t * src );
hb_image_t * hb_image_init(int pix_fmt, int width, int height);
hb_image_t * hb_buffer_to_image(hb_buffer_t *buf);
@@ -208,8 +197,6 @@ void hb_fifo_push( hb_fifo_t *, hb_buffer_t * );
void hb_fifo_push_wait( hb_fifo_t *, hb_buffer_t * );
int hb_fifo_full_wait( hb_fifo_t * f );
void hb_fifo_push_head( hb_fifo_t *, hb_buffer_t * );
-void hb_fifo_push_list_element( hb_fifo_t *fifo, hb_buffer_t *buffer_list );
-hb_buffer_t * hb_fifo_get_list_element( hb_fifo_t *fifo );
void hb_fifo_close( hb_fifo_t ** );
void hb_fifo_flush( hb_fifo_t * f );
diff --git a/libhb/rendersub.c b/libhb/rendersub.c
index 3c17c4a01..dee178d19 100644
--- a/libhb/rendersub.c
+++ b/libhb/rendersub.c
@@ -775,11 +775,7 @@ static void ApplyPGSSubs( hb_filter_private_t * pv, hb_buffer_t * buf )
sub = hb_list_item( pv->sub_list, 0 );
if ( sub->s.start <= buf->s.start )
{
- while ( sub )
- {
- ApplySub( pv, buf, sub );
- sub = sub->sub;
- }
+ ApplySub( pv, buf, sub );
}
}
}
diff --git a/libhb/rotate.c b/libhb/rotate.c
index 090a1b418..7c96e99c0 100644
--- a/libhb/rotate.c
+++ b/libhb/rotate.c
@@ -419,9 +419,8 @@ static int hb_rotate_work( hb_filter_object_t * filter,
// Rotate!
rotate_filter( pv, out, in );
+
out->s = in->s;
- hb_buffer_move_subs( out, in );
-
*buf_out = out;
return HB_FILTER_OK;
diff --git a/libhb/sync.c b/libhb/sync.c
index 3c2a7ffbd..688e1cd53 100644
--- a/libhb/sync.c
+++ b/libhb/sync.c
@@ -904,7 +904,6 @@ int syncVideoWork( hb_work_object_t * w, hb_buffer_t ** buf_in,
*buf_out = cur;
int64_t duration = next_start - cur->s.start;
sync->cur = cur = next;
- cur->sub = NULL;
cur->s.start -= pv->common->video_pts_slip;
if (cur->s.renderOffset != AV_NOPTS_VALUE)
cur->s.renderOffset -= pv->common->video_pts_slip;