diff options
author | jstebbins <[email protected]> | 2012-03-27 20:11:26 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2012-03-27 20:11:26 +0000 |
commit | 45b8f81a2e184e2b7deaf47afc49483766191a27 (patch) | |
tree | 30ed0892995cb4ad3255909f69269c453000800a /libhb/encvorbis.c | |
parent | 7eb7737023be00fa0dc9be75a4984b80c0e5ce57 (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/encvorbis.c')
-rw-r--r-- | libhb/encvorbis.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/libhb/encvorbis.c b/libhb/encvorbis.c index cb38351cd..d48373e09 100644 --- a/libhb/encvorbis.c +++ b/libhb/encvorbis.c @@ -224,9 +224,12 @@ static hb_buffer_t * Flush( hb_work_object_t * w ) memcpy( buf->data + sizeof( ogg_packet ), op.packet, op.bytes ); blocksize = vorbis_packet_blocksize(&pv->vi, &op); - buf->frametype = HB_FRAME_AUDIO; - buf->start = (int64_t)(vorbis_granule_time(&pv->vd, op.granulepos) * 90000); - buf->stop = (int64_t)(vorbis_granule_time(&pv->vd, (pv->prev_blocksize + blocksize)/4 + op.granulepos) * 90000); + + buf->s.type = AUDIO_BUF; + buf->s.frametype = HB_FRAME_AUDIO; + + buf->s.start = (int64_t)(vorbis_granule_time(&pv->vd, op.granulepos) * 90000); + buf->s.stop = (int64_t)(vorbis_granule_time(&pv->vd, (pv->prev_blocksize + blocksize)/4 + op.granulepos) * 90000); /* The stop time isn't accurate for the first ~3 packets, as the actual blocksize depends on the previous _and_ current packets. */ pv->prev_blocksize = blocksize; return buf; |