FFmpeg
Data Structures | Macros | Enumerations | Functions | Variables
f_graphmonitor.c File Reference
#include "config_components.h"
#include "float.h"
#include "libavutil/pixdesc.h"
#include "libavutil/eval.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/opt.h"
#include "libavutil/timestamp.h"
#include "libavutil/xga_font_data.h"
#include "audio.h"
#include "avfilter.h"
#include "filters.h"
#include "formats.h"
#include "internal.h"
#include "video.h"

Go to the source code of this file.

Data Structures

struct  CacheItem
 
struct  GraphMonitorContext
 

Macros

#define OFFSET(x)   offsetof(GraphMonitorContext, x)
 
#define VF   AV_OPT_FLAG_VIDEO_PARAM|AV_OPT_FLAG_FILTERING_PARAM
 
#define VFR   AV_OPT_FLAG_VIDEO_PARAM|AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_RUNTIME_PARAM
 

Enumerations

enum  {
  MODE_FULL = 0, MODE_COMPACT = 1, MODE_NOZERO = 2, MODE_NOEOF = 4,
  MODE_NODISABLED = 8, MODE_MAX = 15
}
 
enum  {
  FLAG_NONE = 0 << 0, FLAG_QUEUE = 1 << 0, FLAG_FCIN = 1 << 1, FLAG_FCOUT = 1 << 2,
  FLAG_PTS = 1 << 3, FLAG_TIME = 1 << 4, FLAG_TB = 1 << 5, FLAG_FMT = 1 << 6,
  FLAG_SIZE = 1 << 7, FLAG_RATE = 1 << 8, FLAG_EOF = 1 << 9, FLAG_SCIN = 1 << 10,
  FLAG_SCOUT = 1 << 11, FLAG_PTS_DELTA = 1 << 12, FLAG_TIME_DELTA = 1 << 13, FLAG_FC_DELTA = 1 << 14,
  FLAG_SC_DELTA = 1 << 15, FLAG_DISABLED = 1 << 16
}
 

Functions

static av_cold int init (AVFilterContext *ctx)
 
static int query_formats (AVFilterContext *ctx)
 
static void clear_image (GraphMonitorContext *s, AVFrame *out, AVFilterLink *outlink)
 
static void drawtext (AVFrame *pic, int x, int y, const char *txt, const int len, uint8_t *color)
 
static int filter_have_eof (AVFilterContext *filter)
 
static int filter_have_queued (AVFilterContext *filter)
 
static int draw_items (AVFilterContext *ctx, AVFilterContext *filter, AVFrame *out, int xpos, int ypos, AVFilterLink *l, size_t frames)
 
static int create_frame (AVFilterContext *ctx, int64_t pts)
 
static int activate (AVFilterContext *ctx)
 
static int config_output (AVFilterLink *outlink)
 
static av_cold void uninit (AVFilterContext *ctx)
 
 AVFILTER_DEFINE_CLASS_EXT (graphmonitor, "(a)graphmonitor", graphmonitor_options)
 

Variables

static const AVOption graphmonitor_options []
 
static const AVFilterPad graphmonitor_outputs []
 

Macro Definition Documentation

◆ OFFSET

#define OFFSET (   x)    offsetof(GraphMonitorContext, x)

Definition at line 98 of file f_graphmonitor.c.

◆ VF

Definition at line 99 of file f_graphmonitor.c.

◆ VFR

Definition at line 100 of file f_graphmonitor.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
MODE_FULL 
MODE_COMPACT 
MODE_NOZERO 
MODE_NOEOF 
MODE_NODISABLED 
MODE_MAX 

Definition at line 68 of file f_graphmonitor.c.

◆ anonymous enum

anonymous enum
Enumerator
FLAG_NONE 
FLAG_QUEUE 
FLAG_FCIN 
FLAG_FCOUT 
FLAG_PTS 
FLAG_TIME 
FLAG_TB 
FLAG_FMT 
FLAG_SIZE 
FLAG_RATE 
FLAG_EOF 
FLAG_SCIN 
FLAG_SCOUT 
FLAG_PTS_DELTA 
FLAG_TIME_DELTA 
FLAG_FC_DELTA 
FLAG_SC_DELTA 
FLAG_DISABLED 

Definition at line 77 of file f_graphmonitor.c.

Function Documentation

◆ init()

static av_cold int init ( AVFilterContext ctx)
static

Definition at line 140 of file f_graphmonitor.c.

◆ query_formats()

static int query_formats ( AVFilterContext ctx)
static

Definition at line 152 of file f_graphmonitor.c.

◆ clear_image()

static void clear_image ( GraphMonitorContext s,
AVFrame out,
AVFilterLink outlink 
)
static

Definition at line 168 of file f_graphmonitor.c.

Referenced by create_frame().

◆ drawtext()

static void drawtext ( AVFrame pic,
int  x,
int  y,
const char *  txt,
const int  len,
uint8_t *  color 
)
static

Definition at line 184 of file f_graphmonitor.c.

Referenced by create_frame(), and draw_items().

◆ filter_have_eof()

static int filter_have_eof ( AVFilterContext filter)
static

Definition at line 215 of file f_graphmonitor.c.

Referenced by create_frame().

◆ filter_have_queued()

static int filter_have_queued ( AVFilterContext filter)
static

Definition at line 234 of file f_graphmonitor.c.

Referenced by create_frame().

◆ draw_items()

static int draw_items ( AVFilterContext ctx,
AVFilterContext filter,
AVFrame out,
int  xpos,
int  ypos,
AVFilterLink l,
size_t  frames 
)
static

Definition at line 255 of file f_graphmonitor.c.

Referenced by create_frame().

◆ create_frame()

static int create_frame ( AVFilterContext ctx,
int64_t  pts 
)
static

Definition at line 387 of file f_graphmonitor.c.

Referenced by activate().

◆ activate()

static int activate ( AVFilterContext ctx)
static

Definition at line 483 of file f_graphmonitor.c.

◆ config_output()

static int config_output ( AVFilterLink outlink)
static

Definition at line 540 of file f_graphmonitor.c.

◆ uninit()

static av_cold void uninit ( AVFilterContext ctx)
static

Definition at line 561 of file f_graphmonitor.c.

◆ AVFILTER_DEFINE_CLASS_EXT()

AVFILTER_DEFINE_CLASS_EXT ( graphmonitor  ,
"(a)graphmonitor"  ,
graphmonitor_options   
)

Variable Documentation

◆ graphmonitor_options

const AVOption graphmonitor_options[]
static

Definition at line 102 of file f_graphmonitor.c.

◆ graphmonitor_outputs

const AVFilterPad graphmonitor_outputs[]
static
Initial value:
= {
{
.name = "default",
.config_props = config_output,
},
}

Definition at line 571 of file f_graphmonitor.c.

config_output
static int config_output(AVFilterLink *outlink)
Definition: f_graphmonitor.c:540
AVMEDIA_TYPE_VIDEO
@ AVMEDIA_TYPE_VIDEO
Definition: avutil.h:201