diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-08-11 11:44:51 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-08-11 11:44:51 +0000 |
commit | 84c038696097e5d4951ba3ad180e1100d66c0947 (patch) | |
tree | 7fec9365ce84f2dfd64e287b38bb48eda0c41b1e /ffmpeg.c | |
parent | ad0d70c964f852a18e9ab8124f0e7aa8876cac6e (diff) | |
download | ffmpeg-84c038696097e5d4951ba3ad180e1100d66c0947.tar.gz |
Change avfilter_open() signature, from:
AVFilterContext *avfilter_open(AVFilter *filter, const char *inst_name);
to:
int avfilter_open(AVFilterContext **filter_ctx, AVFilter *filter, const char *inst_name);
This way it is possible to propagate an error code telling the reason
of the failure.
Originally committed as revision 24765 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'ffmpeg.c')
-rw-r--r-- | ffmpeg.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -410,9 +410,9 @@ static int configure_filters(AVInputStream *ist, AVOutputStream *ost) graph = av_mallocz(sizeof(AVFilterGraph)); - if (!(ist->input_video_filter = avfilter_open(avfilter_get_by_name("buffer"), "src"))) + if (avfilter_open(&ist->input_video_filter, avfilter_get_by_name("buffer"), "src") < 0) return -1; - if (!(ist->out_video_filter = avfilter_open(&output_filter, "out"))) + if (avfilter_open(&ist->out_video_filter, &output_filter, "out") < 0) return -1; snprintf(args, 255, "%d:%d:%d", ist->st->codec->width, @@ -432,7 +432,7 @@ static int configure_filters(AVInputStream *ist, AVOutputStream *ost) snprintf(args, 255, "%d:%d:%d:%d", ost->leftBand, ost->topBand, codec->width, codec->height); - filter = avfilter_open(avfilter_get_by_name("crop"), NULL); + avfilter_open(&filter, avfilter_get_by_name("crop"), NULL); if (!filter) return -1; if (avfilter_init_filter(filter, args, NULL)) @@ -450,7 +450,7 @@ static int configure_filters(AVInputStream *ist, AVOutputStream *ost) codec->width, codec->height, (int)av_get_int(sws_opts, "sws_flags", NULL)); - filter = avfilter_open(avfilter_get_by_name("scale"), NULL); + avfilter_open(&filter, avfilter_get_by_name("scale"), NULL); if (!filter) return -1; if (avfilter_init_filter(filter, args, NULL)) |