diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2011-06-02 15:43:21 +0200 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2011-06-06 01:35:27 +0200 |
commit | 27bcf55f459e038e81f09c17e72e6d44898b9015 (patch) | |
tree | 34ba7668ad2c828fc1ff087901e5b59fbee3d030 /libavfilter/avcodec.h | |
parent | 612d0782fc885aaa0bbb8f8966d425ea91a606cf (diff) | |
download | ffmpeg-27bcf55f459e038e81f09c17e72e6d44898b9015.tar.gz |
vsrc_buffer: add flags param to av_vsrc_buffer_add_video_buffer_ref
The new flags parameter allows to specify if the video ref to add
should overwrite the cache, if the flag is not set vsrc_buffer will
complain and abort; otherwise it will clean the already cached video
ref before to overwrite it, thus avoiding a leak.
Diffstat (limited to 'libavfilter/avcodec.h')
-rw-r--r-- | libavfilter/avcodec.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libavfilter/avcodec.h b/libavfilter/avcodec.h index 74434e819d..4eed6b2d2c 100644 --- a/libavfilter/avcodec.h +++ b/libavfilter/avcodec.h @@ -30,6 +30,7 @@ #include "libavcodec/avcodec.h" // AVFrame #include "avfilter.h" +#include "vsrc_buffer.h" /** * Copy the frame properties of src to dst, without copying the actual @@ -49,9 +50,11 @@ AVFilterBufferRef *avfilter_get_video_buffer_ref_from_frame(const AVFrame *frame * Add frame data to buffer_src. * * @param buffer_src pointer to a buffer source context + * @param flags a combination of AV_VSRC_BUF_FLAG_* flags * @return >= 0 in case of success, a negative AVERROR code in case of * failure */ -int av_vsrc_buffer_add_frame(AVFilterContext *buffer_src, const AVFrame *frame); +int av_vsrc_buffer_add_frame(AVFilterContext *buffer_src, + const AVFrame *frame, int flags); #endif /* AVFILTER_AVCODEC_H */ |