FFmpeg
Data Structures | Macros | Functions
mpegpicture.h File Reference
#include <stdint.h>
#include "libavutil/frame.h"
#include "avcodec.h"
#include "motion_est.h"
#include "threadframe.h"

Go to the source code of this file.

Data Structures

struct  ScratchpadContext
 
struct  Picture
 Picture. More...
 

Macros

#define MPEGVIDEO_MAX_PLANES   4
 
#define MAX_PICTURE_COUNT   36
 
#define EDGE_WIDTH   16
 

Functions

int ff_alloc_picture (AVCodecContext *avctx, Picture *pic, MotionEstContext *me, ScratchpadContext *sc, int encoding, int out_format, int mb_stride, int mb_width, int mb_height, int b8_stride, ptrdiff_t *linesize, ptrdiff_t *uvlinesize)
 Allocate a Picture's accessories, but not the AVFrame's buffer itself. More...
 
int ff_mpeg_framesize_alloc (AVCodecContext *avctx, MotionEstContext *me, ScratchpadContext *sc, int linesize)
 
int ff_mpeg_ref_picture (Picture *dst, Picture *src)
 
void ff_mpeg_unref_picture (Picture *picture)
 Deallocate a picture; frees the picture tables in case they need to be reallocated anyway. More...
 
void ff_mpv_picture_free (Picture *pic)
 
int ff_update_picture_tables (Picture *dst, const Picture *src)
 
int ff_find_unused_picture (AVCodecContext *avctx, Picture *picture, int shared)
 

Macro Definition Documentation

◆ MPEGVIDEO_MAX_PLANES

#define MPEGVIDEO_MAX_PLANES   4

Definition at line 32 of file mpegpicture.h.

◆ MAX_PICTURE_COUNT

#define MAX_PICTURE_COUNT   36

Definition at line 33 of file mpegpicture.h.

◆ EDGE_WIDTH

#define EDGE_WIDTH   16

Definition at line 34 of file mpegpicture.h.

Function Documentation

◆ ff_alloc_picture()

int ff_alloc_picture ( AVCodecContext avctx,
Picture pic,
MotionEstContext me,
ScratchpadContext sc,
int  encoding,
int  out_format,
int  mb_stride,
int  mb_width,
int  mb_height,
int  b8_stride,
ptrdiff_t *  linesize,
ptrdiff_t *  uvlinesize 
)

Allocate a Picture's accessories, but not the AVFrame's buffer itself.

Allocate a Picture's accessories, but not the AVFrame's buffer itself.

The pixels are allocated/set by calling get_buffer() if shared = 0

Definition at line 203 of file mpegpicture.c.

Referenced by alloc_picture().

◆ ff_mpeg_framesize_alloc()

int ff_mpeg_framesize_alloc ( AVCodecContext avctx,
MotionEstContext me,
ScratchpadContext sc,
int  linesize 
)

◆ ff_mpeg_ref_picture()

int ff_mpeg_ref_picture ( Picture dst,
Picture src 
)

Definition at line 304 of file mpegpicture.c.

Referenced by ff_mpeg_update_thread_context(), ff_mpv_frame_start(), and frame_start().

◆ ff_mpeg_unref_picture()

void ff_mpeg_unref_picture ( Picture picture)

◆ ff_mpv_picture_free()

void ff_mpv_picture_free ( Picture pic)

Definition at line 392 of file mpegpicture.c.

Referenced by ff_mpv_common_end().

◆ ff_update_picture_tables()

int ff_update_picture_tables ( Picture dst,
const Picture src 
)

Definition at line 272 of file mpegpicture.c.

Referenced by ff_mpeg_ref_picture().

◆ ff_find_unused_picture()

int ff_find_unused_picture ( AVCodecContext avctx,
Picture picture,
int  shared 
)

Definition at line 380 of file mpegpicture.c.

Referenced by ff_mpv_frame_start(), load_input_picture(), and select_input_picture().