summaryrefslogtreecommitdiffstats
path: root/libhb/deca52.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2012-03-27 20:11:26 +0000
committerjstebbins <[email protected]>2012-03-27 20:11:26 +0000
commit45b8f81a2e184e2b7deaf47afc49483766191a27 (patch)
tree30ed0892995cb4ad3255909f69269c453000800a /libhb/deca52.c
parent7eb7737023be00fa0dc9be75a4984b80c0e5ce57 (diff)
Rework filter pipeline
This patch enhances the filter objects. The 2 key improvements are: 1. A filter can change the image dimensions as frames pass through it. 2. A filter can output more than one frame. In addition, I have: Moved cropping & scalling into a filter object Added 90 degree rotation to the rotate filter Moved subtitle burn-in rendering to a filter object. Moved VFR/CFR handling into a framerate shaping filter object. Removed render.c since all it's responsibilities got moved to filters. Improves VOBSUB and SSA subtitle handling. Allows subtitle animations. SSA karaoke support. My apologies in advance if anything breaks ;) git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4546 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/deca52.c')
-rw-r--r--libhb/deca52.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/libhb/deca52.c b/libhb/deca52.c
index a8d537d52..1f05cc829 100644
--- a/libhb/deca52.c
+++ b/libhb/deca52.c
@@ -153,7 +153,7 @@ static int deca52Work( hb_work_object_t * w, hb_buffer_t ** buf_in,
return HB_WORK_DONE;
}
- if ( (*buf_in)->start < -1 && pv->next_expected_pts == 0 )
+ if ( (*buf_in)->s.start < -1 && pv->next_expected_pts == 0 )
{
// discard buffers that start before video time 0
*buf_out = NULL;
@@ -264,9 +264,9 @@ static hb_buffer_t * Decode( hb_work_object_t * w )
{
buf = hb_buffer_init( size );
memcpy( buf->data, pv->frame, size );
- buf->start = pts;
+ buf->s.start = pts;
pts += frame_dur;
- buf->stop = pts;
+ buf->s.stop = pts;
pv->next_expected_pts = pts;
return buf;
}
@@ -288,9 +288,9 @@ static hb_buffer_t * Decode( hb_work_object_t * w )
/* 6 blocks per frame, 256 samples per block, channelsused channels */
buf = hb_buffer_init( 6 * 256 * pv->out_discrete_channels * sizeof( float ) );
- buf->start = pts;
+ buf->s.start = pts;
pts += frame_dur;
- buf->stop = pts;
+ buf->s.stop = pts;
pv->next_expected_pts = pts;
for( i = 0; i < 6; i++ )
@@ -374,7 +374,7 @@ static int deca52BSInfo( hb_work_object_t *w, const hb_buffer_t *b,
// discard enough bytes from the front of the buffer to make
// room for the new stuff
int newlen = sizeof(w->audio->priv.config.a52.buf) - blen;
- memcpy( buf, buf + len - newlen, newlen );
+ memmove( buf, buf + len - newlen, newlen );
len = newlen;
}
}