FFmpeg
Loading...
Searching...
No Matches
vf_hwdownload.c File Reference
#include "libavutil/buffer.h"
#include "libavutil/hwcontext.h"
#include "libavutil/log.h"
#include "libavutil/mem.h"
#include "libavutil/opt.h"
#include "libavutil/pixdesc.h"
#include "avfilter.h"
#include "filters.h"
#include "formats.h"
#include "video.h"

Go to the source code of this file.

Data Structures

struct  HWDownloadContext
 

Functions

static int hwdownload_query_formats (const AVFilterContext *avctx, AVFilterFormatsConfig **cfg_in, AVFilterFormatsConfig **cfg_out)
 
static int hwdownload_config_input (AVFilterLink *inlink)
 
static int hwdownload_config_output (AVFilterLink *outlink)
 
static int hwdownload_filter_frame (AVFilterLink *link, AVFrame *input)
 
static av_cold void hwdownload_uninit (AVFilterContext *avctx)
 

Variables

static const AVClass hwdownload_class
 
static const AVFilterPad hwdownload_inputs []
 
static const AVFilterPad hwdownload_outputs []
 
const FFFilter ff_vf_hwdownload
 

Function Documentation

◆ hwdownload_query_formats()

static int hwdownload_query_formats ( const AVFilterContext * avctx,
AVFilterFormatsConfig ** cfg_in,
AVFilterFormatsConfig ** cfg_out )
static

Definition at line 38 of file vf_hwdownload.c.

◆ hwdownload_config_input()

static int hwdownload_config_input ( AVFilterLink * inlink)
static

Definition at line 53 of file vf_hwdownload.c.

◆ hwdownload_config_output()

static int hwdownload_config_output ( AVFilterLink * outlink)
static

Definition at line 76 of file vf_hwdownload.c.

◆ hwdownload_filter_frame()

static int hwdownload_filter_frame ( AVFilterLink * link,
AVFrame * input )
static

Definition at line 114 of file vf_hwdownload.c.

◆ hwdownload_uninit()

static av_cold void hwdownload_uninit ( AVFilterContext * avctx)
static

Definition at line 164 of file vf_hwdownload.c.

Variable Documentation

◆ hwdownload_class

const AVClass hwdownload_class
static
Initial value:
= {
.class_name = "hwdownload",
.item_name = av_default_item_name,
.option = NULL,
}
#define NULL
Definition coverity.c:32
const char * av_default_item_name(void *ptr)
Return the context name.
Definition log.c:241
#define LIBAVUTIL_VERSION_INT
Definition version.h:85

Definition at line 171 of file vf_hwdownload.c.

◆ hwdownload_inputs

const AVFilterPad hwdownload_inputs[]
static
Initial value:
= {
{
.name = "default",
.config_props = hwdownload_config_input,
.filter_frame = hwdownload_filter_frame,
},
}
@ AVMEDIA_TYPE_VIDEO
Definition avutil.h:200
static int hwdownload_config_input(AVFilterLink *inlink)
static int hwdownload_filter_frame(AVFilterLink *link, AVFrame *input)

Definition at line 178 of file vf_hwdownload.c.

◆ hwdownload_outputs

const AVFilterPad hwdownload_outputs[]
static
Initial value:
= {
{
.name = "default",
.config_props = hwdownload_config_output,
},
}
static int hwdownload_config_output(AVFilterLink *outlink)

Definition at line 187 of file vf_hwdownload.c.

◆ ff_vf_hwdownload

const FFFilter ff_vf_hwdownload
Initial value:
= {
.p.name = "hwdownload",
.p.description = NULL_IF_CONFIG_SMALL("Download a hardware frame to a normal frame"),
.p.priv_class = &hwdownload_class,
.uninit = hwdownload_uninit,
.priv_size = sizeof(HWDownloadContext),
.flags_internal = FF_FILTER_FLAG_HWFRAME_AWARE,
}
#define FILTER_INPUTS(array)
Definition filters.h:264
#define FILTER_OUTPUTS(array)
Definition filters.h:265
#define FF_FILTER_FLAG_HWFRAME_AWARE
The filter is aware of hardware frames, and any hardware frame context should not be automatically pr...
Definition filters.h:208
#define FILTER_QUERY_FUNC2(func)
Definition filters.h:241
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition internal.h:88
static const AVClass hwdownload_class
static const AVFilterPad hwdownload_outputs[]
static int hwdownload_query_formats(const AVFilterContext *avctx, AVFilterFormatsConfig **cfg_in, AVFilterFormatsConfig **cfg_out)
static av_cold void hwdownload_uninit(AVFilterContext *avctx)
static const AVFilterPad hwdownload_inputs[]

Definition at line 195 of file vf_hwdownload.c.