Function ffmpeg_sys_next::avcodec_receive_packet
source · [−]pub unsafe extern "C" fn avcodec_receive_packet(
avctx: *mut AVCodecContext,
avpkt: *mut AVPacket
) -> c_int
Expand description
Read encoded data from the encoder.
@param avctx codec context @param avpkt This will be set to a reference-counted packet allocated by the encoder. Note that the function will always call av_frame_unref(frame) before doing anything else. @return 0 on success, otherwise negative error code: AVERROR(EAGAIN): output is not available in the current state - user must try to send input AVERROR_EOF: the encoder has been fully flushed, and there will be no more output packets AVERROR(EINVAL): codec not opened, or it is an encoder other errors: legitimate decoding errors