Commit 46c40e48 authored by Stefano Sabatini's avatar Stefano Sabatini

Add w and h fields to AVFilterPic.

See the thread:
"[FFmpeg-devel] [PATCH] Add w,h fields to AVFilterPic".

Originally committed as revision 20189 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 9797ce58
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
#define LIBAVFILTER_VERSION_MAJOR 0 #define LIBAVFILTER_VERSION_MAJOR 0
#define LIBAVFILTER_VERSION_MINOR 5 #define LIBAVFILTER_VERSION_MINOR 5
#define LIBAVFILTER_VERSION_MICRO 0 #define LIBAVFILTER_VERSION_MICRO 1
#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \ #define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
LIBAVFILTER_VERSION_MINOR, \ LIBAVFILTER_VERSION_MINOR, \
...@@ -71,6 +71,8 @@ typedef struct AVFilterPic ...@@ -71,6 +71,8 @@ typedef struct AVFilterPic
* reallocating it from scratch. * reallocating it from scratch.
*/ */
void (*free)(struct AVFilterPic *pic); void (*free)(struct AVFilterPic *pic);
int w, h; ///< width and height of the allocated buffer
} AVFilterPic; } AVFilterPic;
/** /**
......
...@@ -40,8 +40,8 @@ AVFilterPicRef *avfilter_default_get_video_buffer(AVFilterLink *link, int perms) ...@@ -40,8 +40,8 @@ AVFilterPicRef *avfilter_default_get_video_buffer(AVFilterLink *link, int perms)
char *buf; char *buf;
ref->pic = pic; ref->pic = pic;
ref->w = link->w; ref->w = pic->w = link->w;
ref->h = link->h; ref->h = pic->h = link->h;
/* make sure the buffer gets read permission or it's useless for output */ /* make sure the buffer gets read permission or it's useless for output */
ref->perms = perms | AV_PERM_READ; ref->perms = perms | AV_PERM_READ;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment