[FFmpeg-devel] [libav-devel] [PATCH] qpeg: use reget_buffer() in decode_frame()

Michael Niedermayer michaelni at gmx.at
Thu Apr 28 01:26:45 CEST 2011


On Wed, Apr 27, 2011 at 10:59:51PM +0200, Reimar Döffinger wrote:
> On Wed, Apr 27, 2011 at 02:39:28PM +0000, Ronald S. Bultje wrote:
> > Hi,
> > 
> > On Wed, Apr 27, 2011 at 10:52 AM, Stefano Sabatini
> > <stefano.sabatini-lala at poste.it> wrote:
> > > On date Tuesday 2011-04-26 19:20:46 +0200, Reimar Döffinger encoded:
> > >> On Tue, Apr 26, 2011 at 11:53:25AM +0200, Stefano Sabatini wrote:
> > >> > Also remove unnecessary call to avctx->release_buffer(). reget_buffer
> > >> > is required since apparently the coded needs to be passed the previous
> > >> > frame data again.
> > >>
> > >> If that is correct
> > >>
> > >> >      p->reference= 0;
> > >> > -    if(avctx->get_buffer(avctx, p) < 0){
> > >> > -        av_log(avctx, AV_LOG_ERROR, "get_buffer() failed\n");
> > >> > +    if (avctx->reget_buffer(avctx, p) < 0) {
> > >>
> > >> This can't work.
> > >> Setting reference=0 means (I think) e.g. it is ok for libavfilter to
> > >> just draw an OSD directly on the frame instead of making a copy.

i would check the buffer hints too before doing that


> > >> Or to say it differently: Always using reference = 0 and reget_buffer together
> > >> make no sense.

it seems FF_BUFFER_HINTS_REUSABLE is beimhg forgotten in this thread



[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The real ebay dictionary, page 2
"100% positive feedback" - "All either got their money back or didnt complain"
"Best seller ever, very honest" - "Seller refunded buyer after failed scam"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20110428/99b2680e/attachment.asc>


More information about the ffmpeg-devel mailing list