aboutsummaryrefslogtreecommitdiffstats
path: root/libavfilter
diff options
context:
space:
mode:
authorS.N. Hemanth Meenakshisundaram <smeenaks@ucsd.edu>2010-08-07 00:02:26 +0000
committerStefano Sabatini <stefano.sabatini-lala@poste.it>2010-08-07 00:02:26 +0000
commitd54e0948e0fc8c17e9f409b716f982faf0470101 (patch)
tree1dd675bcd4d23a9c26956a4eee7826afba64d0d0 /libavfilter
parent59ff3fd536051b005f1cec53ca60e4d0e2cde126 (diff)
downloadffmpeg-d54e0948e0fc8c17e9f409b716f982faf0470101.tar.gz
Move format from AVFilterBuffer to AVFilterPicRef.
Patch by S.N. Hemanth Meenakshisundaram |smeenaks|ucsd|edu|. Originally committed as revision 24728 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavfilter')
-rw-r--r--libavfilter/avfilter.h6
-rw-r--r--libavfilter/defaults.c8
-rw-r--r--libavfilter/vsrc_buffer.c2
3 files changed, 8 insertions, 8 deletions
diff --git a/libavfilter/avfilter.h b/libavfilter/avfilter.h
index c0193789ba..5746b6c998 100644
--- a/libavfilter/avfilter.h
+++ b/libavfilter/avfilter.h
@@ -25,8 +25,8 @@
#include "libavutil/avutil.h"
#define LIBAVFILTER_VERSION_MAJOR 1
-#define LIBAVFILTER_VERSION_MINOR 27
-#define LIBAVFILTER_VERSION_MICRO 1
+#define LIBAVFILTER_VERSION_MINOR 28
+#define LIBAVFILTER_VERSION_MICRO 0
#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
LIBAVFILTER_VERSION_MINOR, \
@@ -68,7 +68,6 @@ typedef struct AVFilterBuffer
{
uint8_t *data[8]; ///< buffer data for each plane/channel
int linesize[8]; ///< number of bytes per line
- int format; ///< media format
unsigned refcount; ///< number of references to this buffer
@@ -104,6 +103,7 @@ typedef struct AVFilterPicRef
int linesize[4]; ///< number of bytes per line
int w; ///< image width
int h; ///< image height
+ int format; ///< media format
int64_t pts; ///< presentation timestamp in units of 1/AV_TIME_BASE
int64_t pos; ///< byte position in stream, -1 if unknown
diff --git a/libavfilter/defaults.c b/libavfilter/defaults.c
index 47ae1e9c90..8f58cfe069 100644
--- a/libavfilter/defaults.c
+++ b/libavfilter/defaults.c
@@ -47,17 +47,17 @@ AVFilterPicRef *avfilter_default_get_video_buffer(AVFilterLink *link, int perms,
ref->perms = perms | AV_PERM_READ;
pic->refcount = 1;
- pic->format = link->format;
+ ref->format = link->format;
pic->free = avfilter_default_free_buffer;
- av_fill_image_linesizes(pic->linesize, pic->format, ref->w);
+ av_fill_image_linesizes(pic->linesize, ref->format, ref->w);
for (i=0; i<4;i++)
pic->linesize[i] = FFALIGN(pic->linesize[i], 16);
- tempsize = av_fill_image_pointers(pic->data, pic->format, ref->h, NULL, pic->linesize);
+ tempsize = av_fill_image_pointers(pic->data, ref->format, ref->h, NULL, pic->linesize);
buf = av_malloc(tempsize + 16); // +2 is needed for swscaler, +16 to be
// SIMD-friendly
- av_fill_image_pointers(pic->data, pic->format, ref->h, buf, pic->linesize);
+ av_fill_image_pointers(pic->data, ref->format, ref->h, buf, pic->linesize);
memcpy(ref->data, pic->data, 4*sizeof(pic->data[0]));
memcpy(ref->linesize, pic->linesize, 4*sizeof(pic->linesize[0]));
diff --git a/libavfilter/vsrc_buffer.c b/libavfilter/vsrc_buffer.c
index 9e84c27e43..57dea94695 100644
--- a/libavfilter/vsrc_buffer.c
+++ b/libavfilter/vsrc_buffer.c
@@ -120,7 +120,7 @@ static int request_frame(AVFilterLink *link)
link->w, link->h);
av_picture_copy((AVPicture *)&picref->data, (AVPicture *)&c->frame,
- picref->pic->format, link->w, link->h);
+ picref->format, link->w, link->h);
picref->pts = c->pts;
picref->pixel_aspect = c->pixel_aspect;