Ticket #1734: libmpeg2-patch.diff

File libmpeg2-patch.diff, 622 bytes (added by rectalogic@…, 16 years ago)

add back some code deleted by commit r31354

  • libmpeg2/decode.c

     
    345345    fbuf->buf[1] = buf[1];
    346346    fbuf->buf[2] = buf[2];
    347347    fbuf->id = id;
     348    // HACK! FIXME! At first I frame, copy pointers to prediction frame too!
     349    if (mpeg2dec->custom_fbuf && !mpeg2dec->fbuf[1]->buf[0]){
     350        mpeg2dec->fbuf[1]->buf[0]=buf[0];
     351        mpeg2dec->fbuf[1]->buf[1]=buf[1];
     352        mpeg2dec->fbuf[1]->buf[2]=buf[2];
     353        mpeg2dec->fbuf[1]->id=NULL;
     354    }
    348355}
    349356
    350357void mpeg2_custom_fbuf (mpeg2dec_t * mpeg2dec, int custom_fbuf)