Created
January 29, 2017 22:07
-
-
Save nakaly/0c7a0e9cbe570a2374759e9d18e3b82f to your computer and use it in GitHub Desktop.
filter_frame in vf_copy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static int filter_frame(AVFilterLink *inlink, AVFrame *in) | |
{ | |
AVFilterLink *outlink = inlink->dst->outputs[0]; | |
AVFrame *out = ff_get_video_buffer(outlink, in->width, in->height); | |
if (!out) { | |
av_frame_free(&in); | |
return AVERROR(ENOMEM); | |
} | |
av_frame_copy_props(out, in); | |
av_frame_copy(out, in); | |
av_frame_free(&in); | |
return ff_filter_frame(outlink, out); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment