Mercurial > libavcodec.hg
changeset 7838:88f4153caa21 libavcodec
vorbis_enc : set coded_frame->pts value to running sample count.
This is a temporary fix for issue 502 and will not be required when
we start using AVFrame for audio codecs.
author | jai_menon |
---|---|
date | Tue, 09 Sep 2008 14:42:50 +0000 |
parents | 20a0f6aba1cb |
children | e6348a5656e0 |
files | vorbis_enc.c |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/vorbis_enc.c Mon Sep 08 23:47:50 2008 +0000 +++ b/vorbis_enc.c Tue Sep 09 14:42:50 2008 +0000 @@ -118,6 +118,8 @@ int nmodes; vorbis_mode_t * modes; + + int64_t sample_count; } venc_context_t; typedef struct { @@ -1010,6 +1012,8 @@ residue_encode(venc, &venc->residues[mapping->residue[mapping->mux[0]]], &pb, venc->coeffs, samples, venc->channels); + avccontext->coded_frame->pts = venc->sample_count; + venc->sample_count += avccontext->frame_size; flush_put_bits(&pb); return (put_bits_count(&pb) + 7) / 8; }