Skip to content

Commit

Permalink
Recompute ambisonics -> 3.1.2 gains by rendering to 5.1.2 then down-m…
Browse files Browse the repository at this point in the history
…ixing using (§7.6.2 matrices) .

PiperOrigin-RevId: 665350791
  • Loading branch information
jwcullen committed Aug 20, 2024
1 parent e0130d2 commit 1d2e00a
Showing 1 changed file with 112 additions and 108 deletions.
220 changes: 112 additions & 108 deletions iamf/cli/renderer/precomputed_gains.cc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ namespace iamf_tools {
PrecomputedGains InitPrecomputedGains() {
PrecomputedGains gains;

// Generated on Tue Aug 20 13:40:43 2024, GMT
// Generated on Tue Aug 20 13:42:37 2024, GMT

// -------------------------------------------------------
// Input layout: 0+1+0
Expand Down Expand Up @@ -1102,9 +1102,9 @@ PrecomputedGains InitPrecomputedGains() {
0.3188473884483216, 0.3188501095310373, 0.3739736354306449,
0.3739472908142024, 0.2906380377661857, 0.2906211331547076,
0.2911221418496587, 0.2911284648059639}};
gains["A0"]["3.1.2"] = {{0.2154513872061713, 0.2154622268603212,
0.6012813579019585, 0.6453189902061011,
0.1631927661554572, 0.1631747758277981}};
gains["A0"]["3.1.2"] = {{0.671766543304041, 0.6717716608635106,
0.1449662018040889, 0, 0.1631927661554572,
0.1631747758277981}};
gains["A0"]["7.1.2"] = {
{0.2507372882764423, 0.250752746687216, 0.2297672082690357, 0,
0.3188473884483216, 0.3188501095310373, 0.3739736354306449,
Expand Down Expand Up @@ -1292,10 +1292,14 @@ PrecomputedGains InitPrecomputedGains() {
-0.3723280143207133, 0.1740053652023914, 0.1740048192374424,
-0.1744302573087335, -0.1744278435315092}};
gains["A1"]["3.1.2"] = {
{0.5014949, 0.5014987, 0.108221836, 0, 0.121828541, 0.12181511},
{0.5585162, -0.5585061, 1.23793408e-05, 0, 0.10433729, -0.104327601},
{-0.1888202, -0.1888209, -0.140756775, 0, 0.237360549, 0.237361986},
{-0.09461285, -0.0946002, 0.20319182, 0, 0.153929699, 0.153897349}};
{0.5014948853466521, 0.5014987057660003, 0.1082218361088837, 0,
0.1218285405373234, 0.1218151101910272},
{0.5585162348047247, -0.5585060705167022, 1.237934076772879e-05, 0,
0.1043372896418495, -0.1043276013308286},
{-0.1888202008954813, -0.1888208736759966, -0.140756774646952, 0,
0.2373605493064364, 0.2373619861653989},
{-0.09461285079483217, -0.09460019988222401, 0.2031918204312814, 0,
0.1539296985579603, 0.1538973485815448}};
gains["A1"]["7.1.2"] = {
{0.1532499448838317, 0.1532593930222213, 0.140433089331811, 0,
0.1948786518429054, 0.1948803149612197, 0.2285716632404736,
Expand Down Expand Up @@ -1715,24 +1719,24 @@ PrecomputedGains InitPrecomputedGains() {
0.1819470766749066, 0.0005325513355549107, 0.0005226083211512367,
0.0003140644028496443, 0.000285769130708684}};
gains["A2"]["3.1.2"] = {
{0.1515980545815242, 0.1516056816871222, 0.4230795879111567,
0.4540657861076717, 0.1148273222639815, 0.114814663730148},
{0.2152678790143128, -0.2152736385428219, 0.311163324111618,
-0.4400131985228399, 0.0983412550869769, -0.09833212354188181},
{-0.1840079134444613, -0.1840176620176594, -0.1266289981896011,
0.008553034446216325, 0.2237199605917945, 0.2237213148776326},
{0.2005447441365009, 0.200569056241842, -0.09820556907500561,
-0.4097440420746801, 0.1450836973368931, 0.1450532064424711},
{0.2830854141580555, -0.2830949265373006, -0.06619205864611488,
0.09366082486360675, 0.1251282027622235, -0.1251021019900302},
{-0.1309265544872823, 0.1309477245110413, 0.003472599526760136,
-0.004921393833860412, 0.1420999094327114, -0.1421055234355264},
{-0.002629455876297716, -0.002630630460167377, 0.1005289459111843,
0.09134483548098761, 0.1275855237890106, 0.1276223589331018},
{-0.1541428513964222, -0.154153180522775, -0.1163609476674447,
0.004014925426875235, 0.2195165951879353, 0.2195204713808656},
{-0.03801155637226188, -0.03797900342288847, 0.1532712523317638,
-0.08494516160399154, 0.037350700372262, 0.03731617243668121}};
{0.4726750772804064, 0.4726786781486573, 0.1020025652122746, 0,
0.1148273222639815, 0.114814663730148},
{0.5264195351986497, -0.5264099550299046, 1.166792728109675e-05, 0,
0.0983412550869769, -0.09833212354188181},
{-0.1779691192437189, -0.1779697533610177, -0.1326677923903435, 0,
0.2237199605917945, 0.2237213148776326},
{-0.08917565835243543, -0.08916373445995035, 0.1915148334139307, 0,
0.1450836973368931, 0.1450532064424711},
{0.216861123071042, -0.2168667221447187, 3.223244089864202e-05, 0,
0.1251282027622235, -0.1251021019900302},
{-0.1274445647181197, 0.127467773558229, -9.390242402424657e-06, 0,
0.1420999094327114, -0.1421055234355264},
{0.06197194662949289, 0.06195992213480852, 0.03592754340539372, 0,
0.1275855237890106, 0.1276223589331018},
{-0.1513110662123996, -0.1513141995274732, -0.1191927328514673, 0,
0.2195165951879353, 0.2195204713808656},
{-0.09806415590616065, -0.09804430322205804, 0.2133238518656626, 0,
0.037350700372262, 0.03731617243668121}};
gains["A2"]["7.1.2"] = {
{0.1313810026949889, 0.1313891025732379, 0.1203931270706435, 0,
0.1670692456194794, 0.1670706714089105, 0.1959542258038554,
Expand Down Expand Up @@ -2479,38 +2483,38 @@ PrecomputedGains InitPrecomputedGains() {
-0.002911040680991749, -0.0281262986225574, -0.02815811896337869,
0.02848595602497726, 0.02850031179624819}};
gains["A3"]["3.1.2"] = {
{0.1475432207484164, 0.1475506438497748, 0.4117633646793015,
0.4419207667203945, 0.1117560050721716, 0.1117436851195383},
{0.2095100513072349, -0.20951565678409, 0.3028405552099129,
-0.428244047465397, 0.0957108951564507, -0.09570200785524186},
{-0.17908620442218, -0.1790956922476756, -0.1232420184059283,
0.008324264139473339, 0.2177360627914349, 0.2177373808538265},
{0.1951807200675815, 0.1952043818905192, -0.09557883837464023,
-0.3987845082646646, 0.1412031047645282, 0.1411734294182388},
{0.2755136526459698, -0.2755229105950556, -0.06442160189703441,
0.09115565365582247, 0.1217813651564454, -0.1217559625086076},
{-0.1274246268124665, 0.1274452305959211, 0.003379716975669289,
-0.004789759992788563, 0.1382991250358413, -0.138304588879417},
{-0.002559125114604843, -0.002560268281564652, 0.09784007122732,
0.08890161066250024, 0.1241729595585358, 0.1242088094631468},
{-0.1500199512002471, -0.1500300040506864, -0.1132486101855628,
0.003907537139451374, 0.2136451259296143, 0.2136488984449724},
{-0.0369948510771128, -0.03696316883020883, 0.1491716650295835,
-0.08267311057944851, 0.03635167116982406, 0.03631806676219861},
{0.1261164656878066, -0.1261335520518729, -0.1164502967043728,
0.1647454620999331, 0.06785954761722965, -0.06782207605859106},
{-0.1527409386831182, 0.1527428834945877, 0.005162292867218172,
-0.007358045766753297, 0.1732515053364818, -0.173246377527131},
{-0.05389082301656458, 0.05387427827121506, 0.03218652285693112,
-0.04550564660310515, 0.06485935332604253, -0.06488206577719892},
{-0.01868360212403054, -0.0186963735952166, -0.06467712082557694,
0.001566640422048306, -0.01129650672322881, -0.01128750313103734},
{-0.005840771200524682, -0.005847013818204486, -0.04666461187743512,
-0.04067038145674867, 0.1236321152318951, 0.1236767028264234},
{0.01144901756054266, 0.01145625992040252, -0.08912237197153156,
-0.007751790271912551, 0.04362752093129507, 0.04363237973449083},
{-0.1539606498102968, -0.1539356811716762, 0.2016163078180213,
-0.02839981975016615, -0.005882757815817798, -0.005932942836583561}};
{0.4600323101900624, 0.4600358147449242, 0.09927427523765553, 0,
0.1117560050721716, 0.1117436851195383},
{0.5123392506750477, -0.5123299267496459, 1.135584210010789e-05, 0,
0.0957108951564507, -0.09570200785524186},
{-0.1732089314698727, -0.173209548626266, -0.1291192913582355, 0,
0.2177360627914349, 0.2177373808538265},
{-0.08679045309650202, -0.08677884813556791, 0.1863923347894433, 0,
0.1412031047645282, 0.1411734294182388},
{0.2110606804377801, -0.2110661297515312, 3.137031115535313e-05, 0,
0.1217813651564454, -0.1217559625086076},
{-0.1240357707577273, 0.1240583588247642, -9.139079069890202e-06, 0,
0.1382991250358413, -0.138304588879417},
{0.06031436634859495, 0.06030266347629555, 0.03496657976412021, 0,
0.1241729595585358, 0.1242088094631468},
{-0.1472639085341873, -0.1472669580416421, -0.1160046528516226, 0,
0.2136451259296143, 0.2136488984449724},
{-0.09544120762175748, -0.09542188594272218, 0.2076180215742282, 0,
0.03635167116982406, 0.03631806676219861},
{0.009626709371755512, -0.009640918631298873, 3.945961167825228e-05, 0,
0.06785954761722965, -0.06782207605859106},
{-0.1475498516744137, 0.1475399594366354, -2.87941414863721e-05, 0,
0.1732515053364818, -0.173246377527131},
{-0.02170847952470226, 0.02169692697588083, 4.179365068804624e-06, 0,
0.06485935332604253, -0.06488206577719892},
{-0.01757221242275774, -0.01758859152910528, -0.06578851052684974, 0,
-0.01129650672322881, -0.01128750313103734},
{-0.03459537443031531, -0.03460531633971509, -0.0179100086476445, 0,
0.1236321152318951, 0.1236767028264234},
{0.005974535674267993, 0.005974916452797245, -0.08364789008525689, 0,
0.04362752093129507, 0.04363237973449083},
{-0.1740530536567975, -0.1740173863014943, 0.2217087116645219, 0,
-0.005882757815817798, -0.005932942836583561}};
gains["A3"]["7.1.2"] = {
{0.1248431441013129, 0.1248508409086648, 0.1144020535950842, 0,
0.1587554477278004, 0.1587568025662607, 0.1862030365690383,
Expand Down Expand Up @@ -3686,56 +3690,56 @@ PrecomputedGains InitPrecomputedGains() {
-0.04109704100014992, 0.005538562796747306, 0.005533280181741028,
0.006019209685390341, 0.006017921582705248}};
gains["A4"]["3.1.2"] = {
{0.1462018099601641, 0.14620916557331, 0.4080197577769574,
0.4379029793830675, 0.110739958993637, 0.1107277510496565},
{0.2076052600084871, -0.2076108145223289, 0.3000872359735682,
-0.4243506040231231, 0.09484072554333738, -0.09483191904232836},
{-0.1774580159807152, -0.1774674175462565, -0.1221215455558907,
0.00824858287357505, 0.2157564835051861, 0.2157577895842205},
{0.1934062059812723, 0.1934296526792832, -0.09470986937508874,
-0.39515890053521, 0.1399193360687857, 0.1398899305202508},
{0.2730087799442937, -0.2730179537233802, -0.06383590347359737,
0.09032689868759111, 0.1206741720492304, -0.1206490003532838},
{-0.1262661271658665, 0.1262865436270079, 0.003348989784074817,
-0.004746213188707194, 0.1370417582968757, -0.1370471724651177},
{-0.002535858454030369, -0.00253699122772043, 0.09695054389829764,
0.08809334865608097, 0.1230440229207417, 0.1230795468906973},
{-0.1486560228545576, -0.1486659843080357, -0.112218993869158,
0.003872011193577561, 0.2117027399946606, 0.2117064782116432},
{-0.036658506973379, -0.03662711277026029, 0.1478154490017835,
-0.08192147589323855, 0.03602117463036362, 0.03598787574212899},
{0.1249698593795552, -0.1249867904004416, -0.1153915717863315,
0.1632476546164346, 0.06724259260704396, -0.06720546172656568},
{-0.1513522720814404, 0.1513541992113717, 0.005115359125978975,
-0.00729114901662198, 0.1716763639158158, -0.1716712827266944},
{-0.05340086671077486, 0.05338447238439945, 0.03189389437303598,
-0.04509192535606877, 0.06426967502141225, -0.06429218097899439},
{-0.01851373742048498, -0.01852639277797131, -0.06408909931439916,
0.00155239708133236, -0.01119380287881469, -0.01118488114409955},
{-0.005787668974205138, -0.005793854836212536, -0.04624035372796222,
-0.0403006207305582, 0.1225080957594634, 0.1225522779793495},
{0.01134492714152714, 0.01135210365641223, -0.088312102881357,
-0.00768131373597775, 0.04323087493871688, 0.04323568956739216},
{-0.1525608940263695, -0.1525361523937817, 0.199783283643662,
-0.02814161863184943, -0.005829273862039476, -0.005879002618343052},
{0.01412323846151805, -0.014142542713965, -0.002896079900029607,
0.004177806287295372, 0.02993874181069809, -0.02988874161702849},
{-0.07385242829535196, 0.07384489318766099, -0.0005182516965744813,
0.0006739799362763605, 0.08941864012551172, -0.08941340311575782},
{-0.01628133267900135, 0.01629280671527291, -0.03339954199002353,
0.04729560528764545, 0.1018459070595283, -0.1018616268525024},
{0.01266494622276221, -0.01265189964088581, -0.008197530074767851,
0.0115276140846517, -0.0354355013392288, 0.03543132505175703},
{0.0886331125194126, 0.08865965753588724, 0.09703518778842241,
0.0207982314451996, -0.02958143074967187, -0.02961213650031968},
{-0.01434464642095774, -0.01438436757936817, -0.04178132974422319,
-0.002036600895772512, -0.01396867346787669, -0.01398252961382916},
{-0.01395984764086068, -0.01397672966124555, -0.04262655622872778,
-0.005121320976400627, 0.007491534145955856, 0.007537812674159464},
{0.0506447241593551, 0.05065939925705726, -0.1011584535761442,
-0.01110501160603743, -0.00942221053779083, -0.009446864569104436},
{-0.09906252610411573, -0.09903145500687446, 0.2071371920638354,
0.005352194077466755, 0.002873839167100622, 0.002838434086452182}};
{0.4558498591041816, 0.4558533317968699, 0.09837170863293987, 0,
0.110739958993637, 0.1107277510496565},
{0.5076812433832559, -0.5076720042276867, 1.125259879942959e-05, 0,
0.09484072554333738, -0.09483191904232836},
{-0.1716341771157468, -0.1716347886611724, -0.1279453844208592, 0,
0.2157564835051861, 0.2157577895842205},
{-0.0860013849881173, -0.08598988553538417, 0.1846977215943009, 0,
0.1399193360687857, 0.1398899305202508},
{0.2091417913673167, -0.2091471911378342, 3.108510337961687e-05, 0,
0.1206741720492304, -0.1206490003532838},
{-0.122908081391997, 0.1229304640963161, -9.055989794782506e-06, 0,
0.1370417582968757, -0.1370471724651177},
{0.05976600945834812, 0.05975441298442526, 0.03464867598591916, 0,
0.1230440229207417, 0.1230795468906973},
{-0.1459250371538154, -0.1459280589362268, -0.1149499795699002, 0,
0.2117027399946606, 0.2117064782116432},
{-0.09457348991234169, -0.09455434389917955, 0.2057304319407462, 0,
0.03602117463036362, 0.03598787574212899},
{0.009539186734380978, -0.009553266808361272, 3.91008588427309e-05, 0,
0.06724259260704396, -0.06720546172656568},
{-0.1462083806001271, 0.1461985782990767, -2.853235533427135e-05, 0,
0.1716763639158158, -0.1716712827266944},
{-0.0215111137054984, 0.02149966618836559, 4.141367759521952e-06, 0,
0.06426967502141225, -0.06429218097899439},
{-0.01741245208136232, -0.01742868227466699, -0.06519038465352181, 0,
-0.01119380287881469, -0.01118488114409955},
{-0.03428084551974217, -0.03429069704081739, -0.01774717718242519, 0,
0.1225080957594634, 0.1225522779793495},
{0.005920217308655475, 0.005920594625280991, -0.08288739304848533, 0,
0.04323087493871688, 0.04323568956739216},
{-0.1724706248422497, -0.1724352817619282, 0.2196930144595422, 0,
-0.005829273862039476, -0.005879002618343052},
{0.01119056114756904, -0.01118838755773465, 3.659741391940125e-05, 0,
0.02993874181069809, -0.02988874161702849},
{-0.07434502506871775, 0.07432146897098568, -2.565492320869307e-05, 0,
0.08941864012551172, -0.08941340311575782},
{-0.04970647726743763, 0.04973584993448934, 2.560259841274747e-05, 0,
0.1018459070595283, -0.1018616268525024},
{0.004479661978943183, -0.004500645550727038, -1.224583094881937e-05, 0,
-0.0354355013392288, 0.03543132505175703},
{0.1033368131343678, 0.1033662280274752, 0.08233148717346719, 0,
-0.02958143074967187, -0.02961213650031968},
{-0.01581036396500888, -0.01582446188333951, -0.04031561220017205, 0,
-0.01396867346787669, -0.01398252961382916},
{-0.01758423895975371, -0.01759805045229135, -0.03900216490983474, 0,
0.007491534145955856, 0.007537812674159464},
{0.04278257865744881, 0.04280697024527288, -0.09329630807423786, 0,
-0.00942221053779083, -0.009446864569104436},
{-0.09528297291134599, -0.09524688228047125, 0.2033576388710656, 0,
0.002873839167100622, 0.002838434086452182}};
gains["A4"]["7.1.2"] = {
{0.1227392522233813, 0.1227468193219647, 0.1124741179194009, 0,
0.156080056143775, 0.1560813881501154, 0.1830650904759321,
Expand Down

0 comments on commit 1d2e00a

Please sign in to comment.