if ( ret == AVERROR(EAGAIN) && !frame ) continue;
FFPacket opkt;
ret = avcodec_receive_packet(avctx, opkt);
- if( !frame && ret == AVERROR_EOF ) return pkts;
- if( ret < 0 ) break;
+ if( !frame && (ret == AVERROR_EOF || ret == AVERROR(EAGAIN) )) return pkts;
+ //if( ret < 0 ) break;
ret = write_packet(opkt);
if( ret < 0 ) break;
++pkts;
plugin->input_ptr->get_color_model(),
plugin->input_ptr->get_w(),
local_package->row2 - local_package->row1);
- if( plugin->config.pits )
+ if( plugin->config.pits && plugin->config.pits_interval > 0 )
pits(output_rows,
plugin->input_ptr->get_color_model(),
plugin->input_ptr->get_w(),
local_package->row2 - local_package->row1);
- if( plugin->config.dust )
+ if( plugin->config.dust && plugin->config.dust_interval > 0 )
dusts(output_rows,
plugin->input_ptr->get_color_model(),
plugin->input_ptr->get_w(),