Changeset 22796042 in ffmpeg


Ignore:
Timestamp:
Dec 16, 2011, 5:55:04 PM (13 years ago)
Author:
Michael Niedermayer <michaelni@gmx.at>
Branches:
master
Children:
3d07e0ab
Parents:
902c0904
Message:

h264: retuen the amount read in case of NAL_END_SEQUENCE

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libavcodec/h264.c

    r902c0904 r22796042  
    40474047    AVFrame *pict = data;
    40484048    int buf_index;
     4049    Picture *out;
     4050    int i, out_idx;
    40494051
    40504052    s->flags= avctx->flags;
     
    40524054
    40534055   /* end of stream, output what is still in the buffers */
     4056    if (buf_size == 0) {
    40544057 out:
    4055     if (buf_size == 0) {
    4056         Picture *out;
    4057         int i, out_idx;
    40584058
    40594059        s->current_picture_ptr = NULL;
     
    40764076        }
    40774077
    4078         return 0;
     4078        return buf_size;
    40794079    }
    40804080    if(h->is_avc && buf_size >= 9 && buf[0]==1 && buf[2]==0 && (buf[4]&0xFC)==0xFC && (buf[5]&0x1F) && buf[8]==0x67){
     
    41064106
    41074107    if (!s->current_picture_ptr && h->nal_unit_type == NAL_END_SEQUENCE) {
    4108         buf_size = 0;
     4108        av_assert0(buf_index <= buf_size);
     4109        buf_size = buf_index;
    41094110        goto out;
    41104111    }
Note: See TracChangeset for help on using the changeset viewer.