From 45b8f81a2e184e2b7deaf47afc49483766191a27 Mon Sep 17 00:00:00 2001 From: jstebbins Date: Tue, 27 Mar 2012 20:11:26 +0000 Subject: 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 --- libhb/encavcodecaudio.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'libhb/encavcodecaudio.c') diff --git a/libhb/encavcodecaudio.c b/libhb/encavcodecaudio.c index 3a23256fa..fc692e4be 100644 --- a/libhb/encavcodecaudio.c +++ b/libhb/encavcodecaudio.c @@ -260,10 +260,11 @@ static hb_buffer_t * Encode( hb_work_object_t * w ) buf->size = avcodec_encode_audio( pv->context, buf->data, buf->alloc, (short*)pv->buf ); - buf->start = pts + 90000 * pos / pv->out_discrete_channels / sizeof( float ) / audio->config.out.samplerate; - buf->stop = buf->start + 90000 * pv->samples_per_frame / audio->config.out.samplerate; + buf->s.start = pts + 90000 * pos / pv->out_discrete_channels / sizeof( float ) / audio->config.out.samplerate; + buf->s.stop = buf->s.start + 90000 * pv->samples_per_frame / audio->config.out.samplerate; - buf->frametype = HB_FRAME_AUDIO; + buf->s.type = AUDIO_BUF; + buf->s.frametype = HB_FRAME_AUDIO; if ( !buf->size ) { -- cgit v1.2.3