# HG changeset patch # User kostya # Date 1234593530 0 # Node ID 03ea23e85f428d0f0c7a78f36e9a2ed6479d661d # Parent bffe8e6cb10efb8411c4be0deb863cb536b5205d Enable dropping frames for RV3/4 diff -r bffe8e6cb10e -r 03ea23e85f42 rv34.c --- a/rv34.c Fri Feb 13 22:05:55 2009 +0000 +++ b/rv34.c Sat Feb 14 06:38:50 2009 +0000 @@ -1408,6 +1408,15 @@ } if((!s->last_picture_ptr || !s->last_picture_ptr->data[0]) && si.type == FF_B_TYPE) return -1; + /* skip b frames if we are in a hurry */ + if(avctx->hurry_up && si.type==FF_B_TYPE) return buf_size; + if( (avctx->skip_frame >= AVDISCARD_NONREF && si.type==FF_B_TYPE) + || (avctx->skip_frame >= AVDISCARD_NONKEY && si.type!=FF_I_TYPE) + || avctx->skip_frame >= AVDISCARD_ALL) + return buf_size; + /* skip everything if we are in a hurry>=5 */ + if(avctx->hurry_up>=5) + return buf_size; for(i=0; i