亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? bit_allocate.c

?? ac3的解碼程序
?? C
?? 第 1 頁 / 共 2 頁
字號:
/*  *  bit_allocate.c * *	Copyright (C) Aaron Holtzman - May 1999 * *  This file is part of ac3dec, a free Dolby AC-3 stream decoder. *	 *  ac3dec is free software; you can redistribute it and/or modify *  it under the terms of the GNU General Public License as published by *  the Free Software Foundation; either version 2, or (at your option) *  any later version. *    *  ac3dec is distributed in the hope that it will be useful, *  but WITHOUT ANY WARRANTY; without even the implied warranty of *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the *  GNU General Public License for more details. *    *  You should have received a copy of the GNU General Public License *  along with GNU Make; see the file COPYING.  If not, write to *  the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  * */#include <stdlib.h>#include <string.h>#include "ac3.h"static inline sint_16 logadd(sint_16 a,sint_16  b);static sint_16 calc_lowcomp(sint_16 a,sint_16 b0,sint_16 b1,sint_16 bin);static inline uint_16 min(sint_16 a,sint_16 b);static inline uint_16 max(sint_16 a,sint_16 b);static void ba_compute_psd(sint_16 start, sint_16 end, sint_16 exps[], 		sint_16 psd[], sint_16 bndpsd[]);static void ba_compute_excitation(sint_16 start, sint_16 end,sint_16 fgain,		sint_16 fastleak, sint_16 slowleak, sint_16 is_lfe, sint_16 bndpsd[],		sint_16 excite[]);static void ba_compute_mask(sint_16 start, sint_16 end, uint_16 fscod,		uint_16 deltbae, uint_16 deltnseg, uint_16 deltoffst[], uint_16 deltba[],		uint_16 deltlen[], sint_16 excite[], sint_16 mask[]);static void ba_compute_bap(sint_16 start, sint_16 end, sint_16 snroffset,		sint_16 psd[], sint_16 mask[], sint_16 bap[]);/* Misc LUTs for bit allocation process */static sint_16 slowdec[]  = { 0x0f,  0x11,  0x13,  0x15  };static sint_16 fastdec[]  = { 0x3f,  0x53,  0x67,  0x7b  };static sint_16 slowgain[] = { 0x540, 0x4d8, 0x478, 0x410 };static sint_16 dbpbtab[]  = { 0x000, 0x700, 0x900, 0xb00 };static uint_16 floortab[] = { 0x2f0, 0x2b0, 0x270, 0x230, 0x1f0, 0x170, 0x0f0, 0xf800 };static sint_16 fastgain[] = { 0x080, 0x100, 0x180, 0x200, 0x280, 0x300, 0x380, 0x400  };static sint_16 bndtab[] = {  0,  1,  2,   3,   4,   5,   6,   7,   8,   9,                      10, 11, 12,  13,  14,  15,  16,  17,  18,  19,                     20, 21, 22,  23,  24,  25,  26,  27,  28,  31,                     34, 37, 40,  43,  46,  49,  55,  61,  67,  73,                     79, 85, 97, 109, 121, 133, 157, 181, 205, 229 };static sint_16 bndsz[]  = { 1,  1,  1,  1,  1,  1,  1,  1,  1,  1,                     1,  1,  1,  1,  1,  1,  1,  1,  1,  1,                     1,  1,  1,  1,  1,  1,  1,  1,  3,  3,                     3,  3,  3,  3,  3,  6,  6,  6,  6,  6,                     6, 12, 12, 12, 12, 24, 24, 24, 24, 24 };static sint_16 masktab[] = { 0,  1,  2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14, 15,                     16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 28, 28, 29,                     29, 29, 30, 30, 30, 31, 31, 31, 32, 32, 32, 33, 33, 33, 34, 34,                     34, 35, 35, 35, 35, 35, 35, 36, 36, 36, 36, 36, 36, 37, 37, 37,                     37, 37, 37, 38, 38, 38, 38, 38, 38, 39, 39, 39, 39, 39, 39, 40,                     40, 40, 40, 40, 40, 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, 41,                     41, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 43, 43, 43,                     43, 43, 43, 43, 43, 43, 43, 43, 43, 44, 44, 44, 44, 44, 44, 44,                     44, 44, 44, 44, 44, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45,                     45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 46, 46, 46,                     46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46,                     46, 46, 46, 46, 46, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47,                     47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, 48, 48, 48,                     48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,                     48, 48, 48, 48, 48, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,                     49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49,  0,  0,  0 };static sint_16 latab[] = { 0x0040, 0x003f, 0x003e, 0x003d, 0x003c, 0x003b, 0x003a, 0x0039,                    0x0038, 0x0037, 0x0036, 0x0035, 0x0034, 0x0034, 0x0033, 0x0032,                    0x0031, 0x0030, 0x002f, 0x002f, 0x002e, 0x002d, 0x002c, 0x002c,                    0x002b, 0x002a, 0x0029, 0x0029, 0x0028, 0x0027, 0x0026, 0x0026,                    0x0025, 0x0024, 0x0024, 0x0023, 0x0023, 0x0022, 0x0021, 0x0021,                    0x0020, 0x0020, 0x001f, 0x001e, 0x001e, 0x001d, 0x001d, 0x001c,                    0x001c, 0x001b, 0x001b, 0x001a, 0x001a, 0x0019, 0x0019, 0x0018,                    0x0018, 0x0017, 0x0017, 0x0016, 0x0016, 0x0015, 0x0015, 0x0015,                    0x0014, 0x0014, 0x0013, 0x0013, 0x0013, 0x0012, 0x0012, 0x0012,                    0x0011, 0x0011, 0x0011, 0x0010, 0x0010, 0x0010, 0x000f, 0x000f,                    0x000f, 0x000e, 0x000e, 0x000e, 0x000d, 0x000d, 0x000d, 0x000d,                    0x000c, 0x000c, 0x000c, 0x000c, 0x000b, 0x000b, 0x000b, 0x000b,                    0x000a, 0x000a, 0x000a, 0x000a, 0x000a, 0x0009, 0x0009, 0x0009,                    0x0009, 0x0009, 0x0008, 0x0008, 0x0008, 0x0008, 0x0008, 0x0008,                    0x0007, 0x0007, 0x0007, 0x0007, 0x0007, 0x0007, 0x0006, 0x0006,                    0x0006, 0x0006, 0x0006, 0x0006, 0x0006, 0x0006, 0x0005, 0x0005,                    0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0004, 0x0004,                    0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004,                    0x0004, 0x0003, 0x0003, 0x0003, 0x0003, 0x0003, 0x0003, 0x0003,                    0x0003, 0x0003, 0x0003, 0x0003, 0x0003, 0x0003, 0x0003, 0x0002,                    0x0002, 0x0002, 0x0002, 0x0002, 0x0002, 0x0002, 0x0002, 0x0002,                    0x0002, 0x0002, 0x0002, 0x0002, 0x0002, 0x0002, 0x0002, 0x0002,                    0x0002, 0x0002, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001,                    0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001,                    0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001,                    0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001,                    0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,                    0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,                    0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,                    0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,                    0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,                    0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,                    0x0000, 0x0000, 0x0000, 0x0000};static sint_16 hth[][50] = {{ 0x04d0, 0x04d0, 0x0440, 0x0400, 0x03e0, 0x03c0, 0x03b0, 0x03b0,                        0x03a0, 0x03a0, 0x03a0, 0x03a0, 0x03a0, 0x0390, 0x0390, 0x0390,                        0x0380, 0x0380, 0x0370, 0x0370, 0x0360, 0x0360, 0x0350, 0x0350,                        0x0340, 0x0340, 0x0330, 0x0320, 0x0310, 0x0300, 0x02f0, 0x02f0,                      0x02f0, 0x02f0, 0x0300, 0x0310, 0x0340, 0x0390, 0x03e0, 0x0420,                      0x0460, 0x0490, 0x04a0, 0x0460, 0x0440, 0x0440, 0x0520, 0x0800,                      0x0840, 0x0840 },                                          { 0x04f0, 0x04f0, 0x0460, 0x0410, 0x03e0, 0x03d0, 0x03c0, 0x03b0,                       0x03b0, 0x03a0, 0x03a0, 0x03a0, 0x03a0, 0x03a0, 0x0390, 0x0390,                       0x0390, 0x0380, 0x0380, 0x0380, 0x0370, 0x0370, 0x0360, 0x0360,                       0x0350, 0x0350, 0x0340, 0x0340, 0x0320, 0x0310, 0x0300, 0x02f0,                       0x02f0, 0x02f0, 0x02f0, 0x0300, 0x0320, 0x0350, 0x0390, 0x03e0,                       0x0420, 0x0450, 0x04a0, 0x0490, 0x0460, 0x0440, 0x0480, 0x0630,                       0x0840, 0x0840 },                                          { 0x0580, 0x0580, 0x04b0, 0x0450, 0x0420, 0x03f0, 0x03e0, 0x03d0,                       0x03c0, 0x03b0, 0x03b0, 0x03b0, 0x03a0, 0x03a0, 0x03a0, 0x03a0,                       0x03a0, 0x03a0, 0x03a0, 0x03a0, 0x0390, 0x0390, 0x0390, 0x0390,                       0x0380, 0x0380, 0x0380, 0x0370, 0x0360, 0x0350, 0x0340, 0x0330,                       0x0320, 0x0310, 0x0300, 0x02f0, 0x02f0, 0x02f0, 0x0300, 0x0310,                       0x0330, 0x0350, 0x03c0, 0x0410, 0x0470, 0x04a0, 0x0460, 0x0440,                       0x0450, 0x04e0 }};static sint_16 baptab[] = { 0,  1,  1,  1,  1,  1,  2,  2,  3,  3,  3,  4,  4,  5,  5,  6,                     6,  6,  6,  7,  7,  7,  7,  8,  8,  8,  8,  9,  9,  9,  9, 10,                      10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 14,                     14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15 };static sint_16 sdecay;static sint_16 fdecay;static sint_16 sgain;static sint_16 dbknee;static sint_16 floor;static sint_16 psd[256];static sint_16 bndpsd[256];static sint_16 excite[256];static sint_16 mask[256];static inline uint_16max(sint_16 a,sint_16 b){	return (a > b ? a : b);}	static inline uint_16min(sint_16 a,sint_16 b){	return (a < b ? a : b);}static inline sint_16 logadd(sint_16 a,sint_16  b) { 	sint_16 c;	sint_16 address;	c = a - b; 	address = min((abs(c) >> 1), 255); 		if (c >= 0) 		return(a + latab[address]); 	else 		return(b + latab[address]); }void bit_allocate(uint_16 fscod, bsi_t *bsi, audblk_t *audblk){	uint_16 i;	sint_16 fgain;	sint_16 snroffset;	sint_16 start;	sint_16 end;	sint_16 fastleak;	sint_16 slowleak;	/* Only perform bit_allocation if the exponents have changed or we	 * have new sideband information */	if (audblk->chexpstr[0]  == 0 && audblk->chexpstr[1] == 0 &&			audblk->chexpstr[2]  == 0 && audblk->chexpstr[3] == 0 &&			audblk->chexpstr[4]  == 0 && audblk->cplexpstr   == 0 &&			audblk->lfeexpstr    == 0 && audblk->baie        == 0 &&			audblk->snroffste    == 0 && audblk->deltbaie    == 0)		return;	/* Do some setup before we do the bit alloc */	sdecay = slowdec[audblk->sdcycod]; 	fdecay = fastdec[audblk->fdcycod];	sgain = slowgain[audblk->sgaincod]; 	dbknee = dbpbtab[audblk->dbpbcod]; 	floor = floortab[audblk->floorcod]; 	/* if all the SNR offset constants are zero then the whole block is zero */	if(!audblk->csnroffst    && !audblk->fsnroffst[0] && 		 !audblk->fsnroffst[1] && !audblk->fsnroffst[2] && 		 !audblk->fsnroffst[3] && !audblk->fsnroffst[4] &&		 !audblk->cplfsnroffst && !audblk->lfefsnroffst)	{		memset(audblk->fbw_bap,0,sizeof(uint_16) * 256 * 5);		memset(audblk->cpl_bap,0,sizeof(uint_16) * 256);		memset(audblk->lfe_bap,0,sizeof(uint_16) * 7);		return;	}		 	for(i = 0; i < bsi->nfchans; i++)	{		start = 0;		end = audblk->endmant[i] ; 		fgain = fastgain[audblk->fgaincod[i]]; 		snroffset = (((audblk->csnroffst - 15) << 4) + audblk->fsnroffst[i]) << 2 ;		fastleak = 0;		slowleak = 0;		ba_compute_psd(start, end, (short int *)audblk->fbw_exp[i], psd, bndpsd);		ba_compute_excitation(start, end , fgain, fastleak, slowleak, 0, bndpsd, excite);		ba_compute_mask(start, end, fscod, audblk->deltbae[i], audblk->deltnseg[i], 				audblk->deltoffst[i], audblk->deltba[i], audblk->deltlen[i], excite, mask);		ba_compute_bap(start, end, snroffset, psd, mask, (short int *)audblk->fbw_bap[i]);	}	if(audblk->cplinu)	{

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
视频一区在线播放| 欧美日韩和欧美的一区二区| 欧美午夜理伦三级在线观看| 国产精品欧美一区喷水| 理论电影国产精品| 欧美大片一区二区| 香蕉乱码成人久久天堂爱免费| 欧美日韩国产综合视频在线观看 | 久久黄色级2电影| 欧美一区二区三区四区在线观看| 丝袜美腿亚洲综合| 337p亚洲精品色噜噜| 丝袜美腿亚洲综合| 欧美大片在线观看一区二区| 国内精品写真在线观看| 国产欧美综合在线| 播五月开心婷婷综合| 亚洲欧洲美洲综合色网| 色综合中文字幕国产 | 欧美久久一二区| 热久久免费视频| 日韩美女视频在线| 成人免费观看av| 亚洲精选视频在线| 91小视频免费观看| 亚洲自拍偷拍麻豆| 日韩午夜在线观看| 国产一区二区三区美女| 国产精品美日韩| 亚洲美女淫视频| 欧美日韩精品电影| 国产乱码精品一区二区三区忘忧草 | 亚洲va国产天堂va久久en| 不卡欧美aaaaa| 久久综合久久综合九色| 成人综合在线网站| 亚洲一区二区三区三| 欧美一区二区私人影院日本| 亚洲一级二级三级| 久久在线免费观看| 99精品久久免费看蜜臀剧情介绍| 亚洲一区二区三区国产| 欧美电视剧在线观看完整版| 亚洲va国产va欧美va观看| 精品日韩在线一区| 91福利精品视频| 亚洲成av人片一区二区梦乃| 2024国产精品| 成人一区二区在线观看| 性做久久久久久免费观看欧美| 欧美猛男男办公室激情| 国产丶欧美丶日本不卡视频| 亚洲成人黄色小说| 久久婷婷综合激情| 欧美在线看片a免费观看| 精品一区二区免费看| 亚洲三级免费电影| 在线免费观看成人短视频| 国产成人高清在线| 日韩av一区二| 亚洲曰韩产成在线| 精品久久国产老人久久综合| 色综合久久66| 成人一二三区视频| 久久99精品国产麻豆婷婷洗澡| 一区二区在线看| 国产精品无人区| 日韩免费观看高清完整版| 欧美在线不卡一区| 成人网页在线观看| 奇米色一区二区三区四区| 亚洲女同ⅹxx女同tv| 国产精品女同互慰在线看| 欧美一级黄色大片| 色综合天天综合色综合av| 岛国av在线一区| 国产乱码精品一品二品| 黑人精品欧美一区二区蜜桃| 日本不卡一二三区黄网| 毛片av中文字幕一区二区| 亚洲国产精品一区二区www | 激情av综合网| 亚洲第一福利视频在线| 亚洲女人的天堂| 国产精品短视频| 中文字幕欧美日韩一区| 久久精品亚洲精品国产欧美kt∨| 久久一区二区三区四区| 日韩一区二区精品| 91精品国产综合久久精品app| 91精品欧美综合在线观看最新 | 欧美日韩免费在线视频| 99精品久久免费看蜜臀剧情介绍| 99精品欧美一区二区三区小说| jizzjizzjizz欧美| www.av亚洲| 欧洲一区二区av| 欧美丝袜丝交足nylons| 91麻豆精品91久久久久久清纯| 欧美精品99久久久**| 欧美高清dvd| 日韩手机在线导航| 欧美成人官网二区| 国产精品激情偷乱一区二区∴| 中文字幕中文字幕一区| 亚洲综合小说图片| 日韩在线一区二区三区| 精品夜夜嗨av一区二区三区| 国产精品一区二区免费不卡 | 亚洲高清免费观看高清完整版在线观看| 亚洲一区自拍偷拍| 精品无码三级在线观看视频| 国产一区二区伦理片| 懂色av一区二区三区蜜臀| 日本精品一级二级| 欧美日韩国产成人在线免费| 日韩精品一区二区三区老鸭窝| 国产日韩欧美亚洲| 亚洲国产精品嫩草影院| 男人操女人的视频在线观看欧美| 日韩精品国产欧美| 久久97超碰色| 99国产麻豆精品| 日韩久久久精品| 中文字幕在线观看一区二区| 日韩电影在线观看网站| 国产精品一区免费视频| 欧美日韩精品一区二区天天拍小说| 日韩午夜中文字幕| 一区二区三区波多野结衣在线观看| 午夜视频在线观看一区| 成人黄色软件下载| 欧美日本一区二区| 国产精品久久免费看| 亚洲成人一区二区| av高清不卡在线| 欧美一区二区性放荡片| 中文字幕亚洲视频| 免费不卡在线观看| 色av成人天堂桃色av| 精品国产一区二区三区四区四| 亚洲午夜视频在线观看| 高清日韩电视剧大全免费| 制服丝袜国产精品| 国产精品国模大尺度视频| 国产在线精品一区二区夜色| 91国在线观看| 日韩理论电影院| 国产一区二区免费视频| 欧美一级精品在线| 亚洲已满18点击进入久久| 99re这里只有精品首页| 欧美xxxx老人做受| 视频在线观看一区二区三区| 9i在线看片成人免费| 国产亚洲精品aa| 男女激情视频一区| 欧美图区在线视频| 国产精品福利一区二区三区| 成人美女视频在线看| 26uuu精品一区二区| 激情亚洲综合在线| 91福利国产成人精品照片| 中文字幕一区二区三区色视频| 丁香亚洲综合激情啪啪综合| 精品三级在线看| 国模娜娜一区二区三区| 欧美一激情一区二区三区| 日本亚洲天堂网| 欧美日本一区二区| 日本不卡在线视频| 欧美日韩一区二区在线视频| 亚洲一区二区精品视频| 色综合天天综合网天天狠天天| 亚洲精品视频在线| 91片黄在线观看| 一区二区三区四区蜜桃| 91视频国产资源| 亚洲激情自拍视频| 国产精品国产精品国产专区不片 | 91久久精品网| 午夜激情久久久| 欧洲在线/亚洲| 亚洲h精品动漫在线观看| 久久精品噜噜噜成人88aⅴ| 日韩欧美久久久| 另类小说综合欧美亚洲| 2024国产精品| 国产成人精品免费网站| 国产精品欧美久久久久无广告| 日本久久一区二区三区| 亚洲一区在线观看免费 | 日韩福利视频导航| 在线电影院国产精品| 美女性感视频久久| 精品女同一区二区| 北条麻妃国产九九精品视频| 自拍偷拍国产精品| 5566中文字幕一区二区电影| 喷白浆一区二区|