]> git.sesse.net Git - ffmpeg/commitdiff
use avfilter_pad_get_{type,name} accessor functions
authorAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Sat, 8 Aug 2015 08:41:31 +0000 (10:41 +0200)
committerAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Sat, 8 Aug 2015 19:59:02 +0000 (21:59 +0200)
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
cmdutils.c
libavdevice/lavfi.c

index 5aa56f15d0bff27fef0d1e96a781859b3d696eb7..78b0094dc03ea596ac705182c102daa514454085 100644 (file)
@@ -1573,10 +1573,10 @@ int show_filters(void *optctx, const char *opt, const char *arg)
                 *(descr_cur++) = '>';
             }
             pad = i ? filter->outputs : filter->inputs;
-            for (j = 0; pad && pad[j].name; j++) {
+            for (j = 0; pad && avfilter_pad_get_name(pad, j); j++) {
                 if (descr_cur >= descr + sizeof(descr) - 4)
                     break;
-                *(descr_cur++) = get_media_type_char(pad[j].type);
+                *(descr_cur++) = get_media_type_char(avfilter_pad_get_type(pad, j));
             }
             if (!j)
                 *(descr_cur++) = ((!i && (filter->flags & AVFILTER_FLAG_DYNAMIC_INPUTS)) ||
index 126e5f62ce1c0032832346f50f58e5638ac54282..0160f9fac8a01510b7f89d4489ba8f03b5e1837e 100644 (file)
@@ -247,7 +247,7 @@ av_cold static int lavfi_read_header(AVFormatContext *avctx)
     for (i = 0, inout = output_links; inout; i++, inout = inout->next) {
         AVFilterContext *sink;
 
-        type = inout->filter_ctx->output_pads[inout->pad_idx].type;
+        type = avfilter_pad_get_type(inout->filter_ctx->output_pads, inout->pad_idx);
 
         if (type == AVMEDIA_TYPE_VIDEO && ! buffersink ||
             type == AVMEDIA_TYPE_AUDIO && ! abuffersink) {