66 if (!
ctx->hwframes_ref)
82 if (!
ctx->hwframes_ref)
106 outlink->
w = inlink->
w;
107 outlink->
h = inlink->
h;
127 "hwframe context.\n");
133 ctx->hwframes->height);
145 output->
width = outlink->
w;
196 .
name =
"hwdownload",
static const AVFilterPad inputs[]
static const AVFilterPad outputs[]
int ff_filter_frame(AVFilterLink *link, AVFrame *frame)
Send a frame of data to the next filter.
Main libavfilter public API header.
refcounted data buffer API
void av_buffer_unref(AVBufferRef **buf)
Free a given reference and automatically free the buffer if there are no more references to it.
AVBufferRef * av_buffer_ref(AVBufferRef *buf)
Create a new reference to an AVBuffer.
void av_frame_free(AVFrame **frame)
Free the frame and any dynamically allocated objects in it, e.g.
int av_frame_copy_props(AVFrame *dst, const AVFrame *src)
Copy only "metadata" fields from src to dst.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
const char * av_default_item_name(void *ptr)
Return the context name.
#define LIBAVUTIL_VERSION_INT
int av_hwframe_transfer_get_formats(AVBufferRef *hwframe_ref, enum AVHWFrameTransferDirection dir, enum AVPixelFormat **formats, int flags)
Get a list of possible source or target formats usable in av_hwframe_transfer_data().
int av_hwframe_transfer_data(AVFrame *dst, const AVFrame *src, int flags)
Copy data to or from a hw surface.
@ AV_HWFRAME_TRANSFER_DIRECTION_FROM
Transfer the data from the queried hw frame.
#define FF_FILTER_FLAG_HWFRAME_AWARE
The filter is aware of hardware frames, and any hardware frame context should not be automatically pr...
common internal API header
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Memory handling functions.
const char * av_get_pix_fmt_name(enum AVPixelFormat pix_fmt)
Return the short name for a pixel format, NULL in case pix_fmt is unknown.
#define AV_PIX_FMT_FLAG_HWACCEL
Pixel format is an HW accelerated format.
AVPixelFormat
Pixel format.
A reference to a data buffer.
uint8_t * data
The data buffer.
Describe the class of an AVClass context structure.
const char * class_name
The name of the class; usually it is the same name as the context structure type to which the AVClass...
AVFilterLink ** inputs
array of pointers to input links
void * priv
private data for use by the filter
AVFilterLink ** outputs
array of pointers to output links
A link between two filters.
AVFilterFormatsConfig incfg
Lists of supported formats / etc.
int w
agreed upon image width
int h
agreed upon image height
AVFilterFormatsConfig outcfg
Lists of supported formats / etc.
AVFilterContext * src
source filter
AVBufferRef * hw_frames_ctx
For hwaccel pixel formats, this should be a reference to the AVHWFramesContext describing the frames.
AVFilterContext * dst
dest filter
int format
agreed upon media format
A filter pad used for either input or output.
const char * name
Pad name.
const char * name
Filter name.
This structure describes decoded (raw) audio or video data.
AVBufferRef * hw_frames_ctx
For hwaccel-format frames, this should be a reference to the AVHWFramesContext describing the frame.
This struct describes a set or pool of "hardware" frames (i.e.
AVBufferRef * hwframes_ref
AVHWFramesContext * hwframes
static const AVClass hwdownload_class
static const AVFilterPad hwdownload_outputs[]
static int hwdownload_config_input(AVFilterLink *inlink)
static int hwdownload_config_output(AVFilterLink *outlink)
static av_cold void hwdownload_uninit(AVFilterContext *avctx)
static const AVFilterPad hwdownload_inputs[]
static int hwdownload_filter_frame(AVFilterLink *link, AVFrame *input)
AVFilter ff_vf_hwdownload
static int hwdownload_query_formats(AVFilterContext *avctx)
AVFrame * ff_get_video_buffer(AVFilterLink *link, int w, int h)
Request a picture buffer with a specific set of permissions.