FFmpeg
Functions
encode.h File Reference
#include "libavutil/frame.h"
#include "avcodec.h"
#include "packet.h"

Go to the source code of this file.

Functions

int ff_encode_get_frame (AVCodecContext *avctx, AVFrame *frame)
 Called by encoders to get the next frame for encoding. More...
 
int ff_get_encode_buffer (AVCodecContext *avctx, AVPacket *avpkt, int64_t size, int flags)
 Get a buffer for a packet. More...
 
int ff_encode_preinit (AVCodecContext *avctx)
 

Function Documentation

◆ ff_encode_get_frame()

int ff_encode_get_frame ( AVCodecContext avctx,
AVFrame frame 
)

Called by encoders to get the next frame for encoding.

Parameters
frameAn empty frame to be filled with data.
Returns
0 if a new reference has been successfully written to frame AVERROR(EAGAIN) if no data is currently available AVERROR_EOF if end of stream has been reached, so no more data will be available

Definition at line 160 of file encode.c.

Referenced by eb_receive_packet(), encode_simple_internal(), ff_amf_receive_packet(), ff_nvenc_receive_packet(), ff_vaapi_encode_receive_packet(), librav1e_receive_packet(), mf_receive_packet(), and v4l2_receive_packet().

◆ ff_get_encode_buffer()

int ff_get_encode_buffer ( AVCodecContext avctx,
AVPacket avpkt,
int64_t  size,
int  flags 
)

◆ ff_encode_preinit()

int ff_encode_preinit ( AVCodecContext avctx)

Definition at line 416 of file encode.c.

Referenced by avcodec_open2().