[FFmpeg-cvslog] bavfilter/filtfmts: fix type for channel layouts

Michael Niedermayer git at videolan.org
Wed Sep 19 22:43:49 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Sep 19 22:19:06 2012 +0200| [f5326dc68e802495980241ff9c38a635a3926e11] | committer: Michael Niedermayer

bavfilter/filtfmts: fix type for channel layouts

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f5326dc68e802495980241ff9c38a635a3926e11
---

 libavfilter/filtfmts.c |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/libavfilter/filtfmts.c b/libavfilter/filtfmts.c
index f47bf38..3a3bde6 100644
--- a/libavfilter/filtfmts.c
+++ b/libavfilter/filtfmts.c
@@ -45,6 +45,7 @@ static void print_formats(AVFilterContext *filter_ctx)
                        av_get_pix_fmt_name(fmts->formats[j]));          \
         } else if (filter_ctx->inout##puts[i]->type == AVMEDIA_TYPE_AUDIO) { \
             AVFilterFormats *fmts;                                      \
+            AVFilterChannelLayouts *layouts;                            \
                                                                         \
             fmts = filter_ctx->inout##puts[i]->outin##_formats;         \
             for (j = 0; j < fmts->format_count; j++)                    \
@@ -52,11 +53,11 @@ static void print_formats(AVFilterContext *filter_ctx)
                        i, filter_ctx->filter->inout##puts[i].name,      \
                        av_get_sample_fmt_name(fmts->formats[j]));       \
                                                                         \
-            fmts = filter_ctx->inout##puts[i]->outin##_channel_layouts; \
-            for (j = 0; j < fmts->format_count; j++) {                  \
+            layouts = filter_ctx->inout##puts[i]->outin##_channel_layouts; \
+            for (j = 0; j < layouts->nb_channel_layouts; j++) {                  \
                 char buf[256];                                          \
                 av_get_channel_layout_string(buf, sizeof(buf), -1,      \
-                                             fmts->formats[j]);         \
+                                             layouts->channel_layouts[j]);         \
                 printf(#INOUT "PUT[%d] %s: chlayout:%s\n",              \
                        i, filter_ctx->filter->inout##puts[i].name, buf); \
             }                                                           \



More information about the ffmpeg-cvslog mailing list