API changes, most recent first:
+2012-03-26 - xxxxxxx - lavfi 2.66.100
+ Add avfilter_fill_frame_from_{audio_,}buffer_ref() functions.
+
2012-03-21 - xxxxxxx - lavu 51.43.100
Add bprint.h for bprint API.
return picref;
}
+int avfilter_fill_frame_from_audio_buffer_ref(AVFrame *frame,
+ const AVFilterBufferRef *samplesref)
+{
+ if (!samplesref || !samplesref->audio || !frame)
+ return AVERROR(EINVAL);
+
+ memcpy(frame->data, samplesref->data, sizeof(frame->data));
+ frame->pkt_pos = samplesref->pos;
+ frame->format = samplesref->format;
+ frame->nb_samples = samplesref->audio->nb_samples;
+
+ return 0;
+}
+
int avfilter_fill_frame_from_video_buffer_ref(AVFrame *frame,
const AVFilterBufferRef *picref)
{
return 0;
}
+
+int avfilter_fill_frame_from_buffer_ref(AVFrame *frame,
+ const AVFilterBufferRef *ref)
+{
+ if (!ref)
+ return AVERROR(EINVAL);
+ return ref->video ? avfilter_fill_frame_from_video_buffer_ref(frame, ref)
+ : avfilter_fill_frame_from_audio_buffer_ref(frame, ref);
+}
*/
AVFilterBufferRef *avfilter_get_video_buffer_ref_from_frame(const AVFrame *frame, int perms);
+/**
+ * Fill an AVFrame with the information stored in samplesref.
+ *
+ * @param frame an already allocated AVFrame
+ * @param samplesref an audio buffer reference
+ * @return 0 in case of success, a negative AVERROR code in case of
+ * failure
+ */
+int avfilter_fill_frame_from_audio_buffer_ref(AVFrame *frame,
+ const AVFilterBufferRef *samplesref);
+
/**
* Fill an AVFrame with the information stored in picref.
*
int avfilter_fill_frame_from_video_buffer_ref(AVFrame *frame,
const AVFilterBufferRef *picref);
+/**
+ * Fill an AVFrame with information stored in ref.
+ *
+ * @param frame an already allocated AVFrame
+ * @param ref a video or audio buffer reference
+ * @return 0 in case of success, a negative AVERROR code in case of
+ * failure
+ */
+int avfilter_fill_frame_from_buffer_ref(AVFrame *frame,
+ const AVFilterBufferRef *ref);
+
/**
* Add frame data to buffer_src.
*
#include "libavutil/avutil.h"
#define LIBAVFILTER_VERSION_MAJOR 2
-#define LIBAVFILTER_VERSION_MINOR 65
-#define LIBAVFILTER_VERSION_MICRO 102
+#define LIBAVFILTER_VERSION_MINOR 66
+#define LIBAVFILTER_VERSION_MICRO 100
#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
LIBAVFILTER_VERSION_MINOR, \