From b2170247069184acd068b39f24dd8ef5d4e4e7a4 Mon Sep 17 00:00:00 2001 From: Benjamin Larsson Date: Sun, 15 Mar 2009 19:36:45 +0000 Subject: [PATCH] Add cook channel count function, part of multichannel cook Originally committed as revision 17992 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/cook.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/libavcodec/cook.c b/libavcodec/cook.c index 1c1bf72c62..e476dede2d 100644 --- a/libavcodec/cook.c +++ b/libavcodec/cook.c @@ -1018,6 +1018,16 @@ static void dump_cook_context(COOKContext *q) } #endif +static av_cold int cook_count_channels(unsigned int mask){ + int i; + int channels = 0; + for(i = 0;i<32;i++){ + if(mask & (1<