textures_image_drawing.js 1.5 MB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486134871348813489134901349113492134931349413495134961349713498134991350013501135021350313504135051350613507135081350913510135111351213513135141351513516135171351813519135201352113522135231352413525135261352713528135291353013531135321353313534135351353613537135381353913540135411354213543135441354513546135471354813549135501355113552135531355413555135561355713558135591356013561135621356313564135651356613567135681356913570135711357213573135741357513576135771357813579135801358113582135831358413585135861358713588135891359013591135921359313594135951359613597135981359913600136011360213603136041360513606136071360813609136101361113612136131361413615136161361713618136191362013621136221362313624136251362613627136281362913630136311363213633136341363513636136371363813639136401364113642136431364413645136461364713648136491365013651136521365313654136551365613657136581365913660136611366213663136641366513666136671366813669136701367113672136731367413675136761367713678136791368013681136821368313684136851368613687136881368913690136911369213693136941369513696136971369813699137001370113702137031370413705137061370713708137091371013711137121371313714137151371613717137181371913720137211372213723137241372513726137271372813729137301373113732137331373413735137361373713738137391374013741137421374313744137451374613747137481374913750137511375213753137541375513756137571375813759137601376113762137631376413765137661376713768137691377013771137721377313774137751377613777137781377913780137811378213783137841378513786137871378813789137901379113792137931379413795137961379713798137991380013801138021380313804138051380613807138081380913810138111381213813138141381513816138171381813819138201382113822138231382413825138261382713828138291383013831138321383313834138351383613837138381383913840138411384213843138441384513846138471384813849138501385113852138531385413855138561385713858138591386013861138621386313864138651386613867138681386913870138711387213873138741387513876138771387813879138801388113882138831388413885138861388713888138891389013891138921389313894138951389613897138981389913900139011390213903139041390513906139071390813909139101391113912139131391413915139161391713918139191392013921139221392313924139251392613927139281392913930139311393213933139341393513936139371393813939139401394113942139431394413945139461394713948139491395013951139521395313954139551395613957139581395913960139611396213963139641396513966139671396813969139701397113972139731397413975139761397713978139791398013981139821398313984139851398613987139881398913990139911399213993139941399513996139971399813999140001400114002140031400414005140061400714008140091401014011140121401314014140151401614017140181401914020140211402214023140241402514026140271402814029140301403114032140331403414035140361403714038140391404014041140421404314044140451404614047140481404914050140511405214053140541405514056140571405814059140601406114062140631406414065140661406714068140691407014071140721407314074140751407614077140781407914080140811408214083140841408514086140871408814089140901409114092140931409414095140961409714098140991410014101141021410314104141051410614107141081410914110141111411214113141141411514116141171411814119141201412114122141231412414125141261412714128141291413014131141321413314134141351413614137141381413914140141411414214143141441414514146141471414814149141501415114152141531415414155141561415714158141591416014161141621416314164141651416614167141681416914170141711417214173141741417514176141771417814179141801418114182141831418414185141861418714188141891419014191141921419314194141951419614197141981419914200142011420214203142041420514206142071420814209142101421114212142131421414215142161421714218142191422014221142221422314224142251422614227142281422914230142311423214233142341423514236142371423814239142401424114242142431424414245142461424714248142491425014251142521425314254142551425614257142581425914260142611426214263142641426514266142671426814269142701427114272142731427414275142761427714278142791428014281142821428314284142851428614287142881428914290142911429214293142941429514296142971429814299143001430114302143031430414305143061430714308143091431014311143121431314314143151431614317143181431914320143211432214323143241432514326143271432814329143301433114332143331433414335143361433714338143391434014341143421434314344143451434614347143481434914350143511435214353143541435514356143571435814359143601436114362143631436414365143661436714368143691437014371143721437314374143751437614377143781437914380143811438214383143841438514386143871438814389143901439114392143931439414395143961439714398143991440014401144021440314404144051440614407144081440914410144111441214413144141441514416144171441814419144201442114422144231442414425144261442714428144291443014431144321443314434144351443614437144381443914440144411444214443144441444514446144471444814449144501445114452144531445414455144561445714458144591446014461144621446314464144651446614467144681446914470144711447214473144741447514476144771447814479144801448114482144831448414485144861448714488144891449014491144921449314494144951449614497144981449914500145011450214503145041450514506145071450814509145101451114512145131451414515145161451714518145191452014521145221452314524145251452614527145281452914530145311453214533145341453514536145371453814539145401454114542145431454414545145461454714548145491455014551145521455314554145551455614557145581455914560145611456214563145641456514566145671456814569145701457114572145731457414575145761457714578145791458014581145821458314584145851458614587145881458914590145911459214593145941459514596145971459814599146001460114602146031460414605146061460714608146091461014611146121461314614146151461614617146181461914620146211462214623146241462514626146271462814629146301463114632146331463414635146361463714638146391464014641146421464314644146451464614647146481464914650146511465214653146541465514656146571465814659146601466114662146631466414665146661466714668146691467014671146721467314674146751467614677146781467914680146811468214683146841468514686146871468814689146901469114692146931469414695146961469714698146991470014701147021470314704147051470614707147081470914710147111471214713147141471514716147171471814719147201472114722147231472414725147261472714728147291473014731147321473314734147351473614737147381473914740147411474214743147441474514746147471474814749147501475114752147531475414755147561475714758147591476014761147621476314764147651476614767147681476914770147711477214773147741477514776147771477814779147801478114782147831478414785147861478714788147891479014791147921479314794147951479614797147981479914800148011480214803148041480514806148071480814809148101481114812148131481414815148161481714818148191482014821148221482314824148251482614827148281482914830148311483214833148341483514836148371483814839148401484114842148431484414845148461484714848148491485014851148521485314854148551485614857148581485914860148611486214863148641486514866148671486814869148701487114872148731487414875148761487714878148791488014881148821488314884148851488614887148881488914890148911489214893148941489514896148971489814899149001490114902149031490414905149061490714908149091491014911149121491314914149151491614917149181491914920149211492214923149241492514926149271492814929149301493114932149331493414935149361493714938149391494014941149421494314944149451494614947149481494914950149511495214953149541495514956149571495814959149601496114962149631496414965149661496714968149691497014971149721497314974149751497614977149781497914980149811498214983149841498514986149871498814989149901499114992149931499414995149961499714998149991500015001150021500315004150051500615007150081500915010150111501215013150141501515016150171501815019150201502115022150231502415025150261502715028150291503015031150321503315034150351503615037150381503915040150411504215043150441504515046150471504815049150501505115052150531505415055150561505715058150591506015061150621506315064150651506615067150681506915070150711507215073150741507515076150771507815079150801508115082150831508415085150861508715088150891509015091150921509315094150951509615097150981509915100151011510215103151041510515106151071510815109151101511115112151131511415115151161511715118151191512015121151221512315124151251512615127151281512915130151311513215133151341513515136151371513815139151401514115142151431514415145151461514715148151491515015151151521515315154151551515615157151581515915160151611516215163151641516515166151671516815169151701517115172151731517415175151761517715178151791518015181151821518315184151851518615187151881518915190151911519215193151941519515196151971519815199152001520115202152031520415205152061520715208152091521015211152121521315214152151521615217152181521915220152211522215223152241522515226152271522815229152301523115232152331523415235152361523715238152391524015241152421524315244152451524615247152481524915250152511525215253152541525515256152571525815259152601526115262152631526415265152661526715268152691527015271152721527315274152751527615277152781527915280152811528215283152841528515286152871528815289152901529115292152931529415295152961529715298152991530015301153021530315304153051530615307153081530915310153111531215313153141531515316153171531815319153201532115322153231532415325153261532715328153291533015331153321533315334153351533615337153381533915340153411534215343153441534515346153471534815349153501535115352153531535415355153561535715358153591536015361153621536315364153651536615367153681536915370153711537215373153741537515376153771537815379153801538115382153831538415385153861538715388153891539015391153921539315394153951539615397153981539915400154011540215403154041540515406154071540815409154101541115412154131541415415154161541715418154191542015421154221542315424154251542615427154281542915430154311543215433154341543515436154371543815439154401544115442154431544415445154461544715448154491545015451154521545315454154551545615457154581545915460154611546215463154641546515466154671546815469154701547115472154731547415475154761547715478154791548015481154821548315484154851548615487154881548915490154911549215493154941549515496154971549815499155001550115502155031550415505155061550715508155091551015511155121551315514155151551615517155181551915520155211552215523155241552515526155271552815529155301553115532155331553415535155361553715538155391554015541155421554315544155451554615547155481554915550155511555215553155541555515556155571555815559155601556115562155631556415565155661556715568155691557015571155721557315574155751557615577155781557915580155811558215583155841558515586155871558815589155901559115592155931559415595155961559715598155991560015601156021560315604156051560615607156081560915610156111561215613156141561515616156171561815619156201562115622156231562415625156261562715628156291563015631156321563315634156351563615637156381563915640156411564215643156441564515646156471564815649156501565115652156531565415655156561565715658156591566015661156621566315664156651566615667156681566915670156711567215673156741567515676156771567815679156801568115682156831568415685156861568715688156891569015691156921569315694156951569615697156981569915700157011570215703157041570515706157071570815709157101571115712157131571415715157161571715718157191572015721157221572315724157251572615727157281572915730157311573215733157341573515736157371573815739157401574115742157431574415745157461574715748157491575015751157521575315754157551575615757157581575915760157611576215763157641576515766157671576815769157701577115772157731577415775157761577715778157791578015781157821578315784157851578615787157881578915790157911579215793157941579515796157971579815799158001580115802158031580415805158061580715808158091581015811158121581315814158151581615817158181581915820158211582215823158241582515826158271582815829158301583115832158331583415835158361583715838158391584015841158421584315844158451584615847158481584915850158511585215853158541585515856158571585815859158601586115862158631586415865158661586715868158691587015871158721587315874158751587615877158781587915880158811588215883158841588515886158871588815889158901589115892158931589415895158961589715898158991590015901159021590315904159051590615907159081590915910159111591215913159141591515916159171591815919159201592115922159231592415925159261592715928159291593015931159321593315934159351593615937159381593915940159411594215943159441594515946159471594815949159501595115952159531595415955159561595715958159591596015961159621596315964159651596615967159681596915970159711597215973159741597515976159771597815979159801598115982159831598415985159861598715988159891599015991159921599315994159951599615997159981599916000160011600216003160041600516006160071600816009160101601116012160131601416015160161601716018160191602016021160221602316024160251602616027160281602916030160311603216033160341603516036160371603816039160401604116042160431604416045160461604716048160491605016051160521605316054160551605616057160581605916060160611606216063160641606516066160671606816069160701607116072160731607416075160761607716078160791608016081160821608316084160851608616087160881608916090160911609216093160941609516096160971609816099161001610116102161031610416105161061610716108161091611016111161121611316114161151611616117161181611916120161211612216123161241612516126161271612816129161301613116132161331613416135161361613716138161391614016141161421614316144161451614616147161481614916150161511615216153161541615516156161571615816159161601616116162161631616416165161661616716168161691617016171161721617316174161751617616177161781617916180161811618216183161841618516186161871618816189161901619116192161931619416195161961619716198161991620016201162021620316204162051620616207162081620916210162111621216213162141621516216162171621816219162201622116222162231622416225162261622716228162291623016231162321623316234162351623616237162381623916240162411624216243162441624516246162471624816249162501625116252162531625416255162561625716258162591626016261162621626316264162651626616267162681626916270162711627216273162741627516276162771627816279162801628116282162831628416285162861628716288162891629016291162921629316294162951629616297162981629916300163011630216303163041630516306163071630816309163101631116312163131631416315163161631716318163191632016321163221632316324163251632616327163281632916330163311633216333163341633516336163371633816339163401634116342163431634416345163461634716348163491635016351163521635316354163551635616357163581635916360163611636216363163641636516366163671636816369163701637116372163731637416375163761637716378163791638016381163821638316384163851638616387163881638916390163911639216393163941639516396163971639816399164001640116402164031640416405164061640716408164091641016411164121641316414164151641616417164181641916420164211642216423164241642516426164271642816429164301643116432164331643416435164361643716438164391644016441164421644316444164451644616447164481644916450164511645216453164541645516456164571645816459164601646116462164631646416465164661646716468164691647016471164721647316474164751647616477164781647916480164811648216483164841648516486164871648816489164901649116492164931649416495164961649716498164991650016501165021650316504165051650616507165081650916510165111651216513165141651516516165171651816519165201652116522165231652416525165261652716528165291653016531165321653316534165351653616537165381653916540165411654216543165441654516546165471654816549165501655116552165531655416555165561655716558165591656016561165621656316564165651656616567165681656916570165711657216573165741657516576165771657816579165801658116582165831658416585165861658716588165891659016591165921659316594165951659616597165981659916600166011660216603166041660516606166071660816609166101661116612166131661416615166161661716618166191662016621166221662316624166251662616627166281662916630166311663216633166341663516636166371663816639166401664116642166431664416645166461664716648166491665016651166521665316654166551665616657166581665916660166611666216663166641666516666166671666816669166701667116672166731667416675166761667716678166791668016681166821668316684166851668616687166881668916690166911669216693166941669516696166971669816699167001670116702167031670416705167061670716708167091671016711167121671316714167151671616717167181671916720167211672216723167241672516726167271672816729167301673116732167331673416735167361673716738167391674016741167421674316744167451674616747167481674916750167511675216753167541675516756167571675816759167601676116762167631676416765167661676716768167691677016771167721677316774167751677616777167781677916780167811678216783167841678516786167871678816789167901679116792167931679416795167961679716798167991680016801168021680316804168051680616807168081680916810168111681216813168141681516816168171681816819168201682116822168231682416825168261682716828168291683016831168321683316834168351683616837168381683916840168411684216843168441684516846168471684816849168501685116852168531685416855168561685716858168591686016861168621686316864168651686616867168681686916870168711687216873168741687516876168771687816879168801688116882168831688416885168861688716888168891689016891168921689316894168951689616897168981689916900169011690216903169041690516906169071690816909169101691116912169131691416915169161691716918169191692016921169221692316924169251692616927169281692916930169311693216933169341693516936169371693816939169401694116942169431694416945169461694716948169491695016951169521695316954169551695616957169581695916960169611696216963169641696516966169671696816969169701697116972169731697416975169761697716978169791698016981169821698316984169851698616987169881698916990169911699216993169941699516996169971699816999170001700117002170031700417005170061700717008170091701017011170121701317014170151701617017170181701917020170211702217023170241702517026170271702817029170301703117032170331703417035170361703717038170391704017041170421704317044170451704617047170481704917050170511705217053170541705517056170571705817059170601706117062170631706417065170661706717068170691707017071170721707317074170751707617077170781707917080170811708217083170841708517086170871708817089170901709117092170931709417095170961709717098170991710017101171021710317104171051710617107171081710917110171111711217113171141711517116171171711817119171201712117122171231712417125171261712717128171291713017131171321713317134171351713617137171381713917140171411714217143171441714517146171471714817149171501715117152171531715417155171561715717158171591716017161171621716317164171651716617167171681716917170171711717217173171741717517176171771717817179171801718117182171831718417185171861718717188171891719017191171921719317194171951719617197171981719917200172011720217203172041720517206172071720817209172101721117212172131721417215172161721717218172191722017221172221722317224172251722617227172281722917230172311723217233172341723517236172371723817239172401724117242172431724417245172461724717248172491725017251172521725317254172551725617257172581725917260172611726217263172641726517266172671726817269172701727117272172731727417275172761727717278172791728017281172821728317284172851728617287172881728917290172911729217293172941729517296172971729817299173001730117302173031730417305173061730717308173091731017311173121731317314173151731617317173181731917320173211732217323173241732517326173271732817329173301733117332173331733417335173361733717338173391734017341173421734317344173451734617347173481734917350173511735217353173541735517356173571735817359173601736117362173631736417365173661736717368173691737017371173721737317374173751737617377173781737917380173811738217383173841738517386173871738817389173901739117392173931739417395173961739717398173991740017401174021740317404174051740617407174081740917410174111741217413174141741517416174171741817419174201742117422174231742417425174261742717428174291743017431174321743317434174351743617437174381743917440174411744217443174441744517446174471744817449174501745117452174531745417455174561745717458174591746017461174621746317464174651746617467174681746917470174711747217473174741747517476174771747817479174801748117482174831748417485174861748717488174891749017491174921749317494174951749617497174981749917500175011750217503175041750517506175071750817509175101751117512175131751417515175161751717518175191752017521175221752317524175251752617527175281752917530175311753217533175341753517536175371753817539175401754117542175431754417545175461754717548175491755017551175521755317554175551755617557175581755917560175611756217563175641756517566175671756817569175701757117572175731757417575175761757717578175791758017581175821758317584175851758617587175881758917590175911759217593175941759517596175971759817599176001760117602176031760417605176061760717608176091761017611176121761317614176151761617617176181761917620176211762217623176241762517626176271762817629176301763117632176331763417635176361763717638176391764017641176421764317644176451764617647176481764917650176511765217653176541765517656176571765817659176601766117662176631766417665176661766717668176691767017671176721767317674176751767617677176781767917680176811768217683176841768517686176871768817689176901769117692176931769417695176961769717698176991770017701177021770317704177051770617707177081770917710177111771217713177141771517716177171771817719177201772117722177231772417725177261772717728177291773017731177321773317734177351773617737177381773917740177411774217743177441774517746177471774817749177501775117752177531775417755177561775717758177591776017761177621776317764177651776617767177681776917770177711777217773177741777517776177771777817779177801778117782177831778417785177861778717788177891779017791177921779317794177951779617797177981779917800178011780217803178041780517806178071780817809178101781117812178131781417815178161781717818178191782017821178221782317824178251782617827178281782917830178311783217833178341783517836178371783817839178401784117842178431784417845178461784717848178491785017851178521785317854178551785617857178581785917860178611786217863178641786517866178671786817869178701787117872178731787417875178761787717878178791788017881178821788317884178851788617887178881788917890178911789217893178941789517896178971789817899179001790117902179031790417905179061790717908179091791017911179121791317914179151791617917179181791917920179211792217923179241792517926179271792817929179301793117932179331793417935179361793717938179391794017941179421794317944179451794617947179481794917950179511795217953179541795517956179571795817959179601796117962179631796417965179661796717968179691797017971179721797317974179751797617977179781797917980179811798217983179841798517986179871798817989179901799117992179931799417995179961799717998179991800018001180021800318004180051800618007180081800918010180111801218013180141801518016180171801818019180201802118022180231802418025180261802718028180291803018031180321803318034180351803618037180381803918040180411804218043180441804518046180471804818049180501805118052180531805418055180561805718058180591806018061180621806318064180651806618067180681806918070180711807218073180741807518076180771807818079180801808118082180831808418085180861808718088180891809018091180921809318094180951809618097180981809918100181011810218103181041810518106181071810818109181101811118112181131811418115181161811718118181191812018121181221812318124181251812618127181281812918130181311813218133181341813518136181371813818139181401814118142181431814418145181461814718148181491815018151181521815318154181551815618157181581815918160181611816218163181641816518166181671816818169181701817118172181731817418175181761817718178181791818018181181821818318184181851818618187181881818918190181911819218193181941819518196181971819818199182001820118202182031820418205182061820718208182091821018211182121821318214182151821618217182181821918220182211822218223182241822518226182271822818229182301823118232182331823418235182361823718238182391824018241182421824318244182451824618247182481824918250182511825218253182541825518256182571825818259182601826118262182631826418265182661826718268182691827018271182721827318274182751827618277182781827918280182811828218283182841828518286182871828818289182901829118292182931829418295182961829718298182991830018301183021830318304183051830618307183081830918310183111831218313183141831518316183171831818319183201832118322183231832418325183261832718328183291833018331183321833318334183351833618337183381833918340183411834218343183441834518346183471834818349183501835118352183531835418355183561835718358183591836018361183621836318364183651836618367183681836918370183711837218373183741837518376183771837818379183801838118382183831838418385183861838718388183891839018391183921839318394183951839618397183981839918400184011840218403184041840518406184071840818409184101841118412184131841418415184161841718418184191842018421184221842318424184251842618427184281842918430184311843218433184341843518436184371843818439184401844118442184431844418445184461844718448184491845018451184521845318454184551845618457184581845918460184611846218463184641846518466184671846818469184701847118472184731847418475184761847718478184791848018481184821848318484184851848618487184881848918490184911849218493184941849518496184971849818499185001850118502185031850418505185061850718508185091851018511185121851318514185151851618517185181851918520185211852218523185241852518526185271852818529185301853118532185331853418535185361853718538185391854018541185421854318544185451854618547185481854918550185511855218553185541855518556185571855818559185601856118562185631856418565185661856718568185691857018571185721857318574185751857618577185781857918580185811858218583185841858518586185871858818589185901859118592185931859418595185961859718598185991860018601186021860318604186051860618607186081860918610186111861218613186141861518616186171861818619186201862118622186231862418625186261862718628186291863018631186321863318634186351863618637186381863918640186411864218643186441864518646186471864818649186501865118652186531865418655186561865718658186591866018661186621866318664186651866618667186681866918670186711867218673186741867518676186771867818679186801868118682186831868418685186861868718688186891869018691186921869318694186951869618697186981869918700187011870218703187041870518706187071870818709187101871118712187131871418715187161871718718187191872018721187221872318724187251872618727187281872918730187311873218733187341873518736187371873818739187401874118742187431874418745187461874718748187491875018751187521875318754187551875618757187581875918760187611876218763187641876518766187671876818769187701877118772187731877418775187761877718778187791878018781187821878318784187851878618787187881878918790187911879218793187941879518796187971879818799188001880118802188031880418805188061880718808188091881018811188121881318814188151881618817188181881918820188211882218823188241882518826188271882818829188301883118832188331883418835188361883718838188391884018841188421884318844188451884618847188481884918850188511885218853188541885518856188571885818859188601886118862188631886418865188661886718868188691887018871188721887318874188751887618877188781887918880188811888218883188841888518886188871888818889188901889118892188931889418895188961889718898188991890018901189021890318904189051890618907189081890918910189111891218913189141891518916189171891818919189201892118922189231892418925189261892718928189291893018931189321893318934189351893618937189381893918940189411894218943189441894518946189471894818949189501895118952189531895418955189561895718958189591896018961189621896318964189651896618967189681896918970189711897218973189741897518976189771897818979189801898118982189831898418985189861898718988189891899018991189921899318994189951899618997189981899919000190011900219003190041900519006190071900819009190101901119012190131901419015190161901719018190191902019021190221902319024190251902619027190281902919030190311903219033190341903519036190371903819039190401904119042190431904419045190461904719048190491905019051190521905319054190551905619057190581905919060190611906219063190641906519066190671906819069190701907119072190731907419075190761907719078190791908019081190821908319084190851908619087190881908919090190911909219093190941909519096190971909819099191001910119102191031910419105191061910719108191091911019111191121911319114191151911619117191181911919120191211912219123191241912519126191271912819129191301913119132191331913419135191361913719138191391914019141191421914319144191451914619147191481914919150191511915219153191541915519156191571915819159191601916119162191631916419165191661916719168191691917019171191721917319174191751917619177191781917919180191811918219183191841918519186191871918819189191901919119192191931919419195191961919719198191991920019201192021920319204192051920619207192081920919210192111921219213192141921519216192171921819219192201922119222192231922419225192261922719228192291923019231192321923319234192351923619237192381923919240192411924219243192441924519246192471924819249192501925119252192531925419255192561925719258192591926019261192621926319264192651926619267192681926919270192711927219273192741927519276192771927819279192801928119282192831928419285192861928719288192891929019291192921929319294192951929619297192981929919300193011930219303193041930519306193071930819309193101931119312193131931419315193161931719318193191932019321193221932319324193251932619327193281932919330193311933219333193341933519336193371933819339193401934119342193431934419345193461934719348193491935019351193521935319354193551935619357193581935919360193611936219363193641936519366193671936819369193701937119372193731937419375193761937719378193791938019381193821938319384193851938619387193881938919390193911939219393193941939519396193971939819399194001940119402194031940419405194061940719408194091941019411194121941319414194151941619417194181941919420194211942219423194241942519426194271942819429194301943119432194331943419435194361943719438194391944019441194421944319444194451944619447194481944919450194511945219453194541945519456194571945819459194601946119462194631946419465194661946719468194691947019471194721947319474194751947619477194781947919480194811948219483194841948519486194871948819489194901949119492194931949419495194961949719498194991950019501195021950319504195051950619507195081950919510195111951219513195141951519516195171951819519195201952119522195231952419525195261952719528195291953019531195321953319534195351953619537195381953919540195411954219543195441954519546195471954819549195501955119552195531955419555195561955719558195591956019561195621956319564195651956619567195681956919570195711957219573195741957519576195771957819579195801958119582195831958419585195861958719588195891959019591195921959319594195951959619597195981959919600196011960219603196041960519606196071960819609196101961119612196131961419615196161961719618196191962019621196221962319624196251962619627196281962919630196311963219633196341963519636196371963819639196401964119642196431964419645196461964719648196491965019651196521965319654196551965619657196581965919660196611966219663196641966519666196671966819669196701967119672196731967419675196761967719678196791968019681196821968319684196851968619687196881968919690196911969219693196941969519696196971969819699197001970119702197031970419705197061970719708197091971019711197121971319714197151971619717197181971919720197211972219723197241972519726197271972819729197301973119732197331973419735197361973719738197391974019741197421974319744197451974619747197481974919750197511975219753197541975519756197571975819759197601976119762197631976419765197661976719768197691977019771197721977319774197751977619777197781977919780197811978219783197841978519786197871978819789197901979119792197931979419795197961979719798197991980019801198021980319804198051980619807198081980919810198111981219813198141981519816198171981819819198201982119822198231982419825198261982719828198291983019831198321983319834198351983619837198381983919840198411984219843198441984519846198471984819849198501985119852198531985419855198561985719858198591986019861198621986319864198651986619867198681986919870198711987219873198741987519876198771987819879198801988119882198831988419885198861988719888198891989019891198921989319894198951989619897198981989919900199011990219903199041990519906199071990819909199101991119912199131991419915199161991719918199191992019921199221992319924199251992619927199281992919930199311993219933199341993519936199371993819939199401994119942199431994419945199461994719948199491995019951199521995319954199551995619957199581995919960199611996219963199641996519966199671996819969199701997119972199731997419975199761997719978199791998019981199821998319984199851998619987199881998919990199911999219993199941999519996199971999819999200002000120002200032000420005200062000720008200092001020011200122001320014200152001620017200182001920020200212002220023200242002520026200272002820029200302003120032200332003420035200362003720038200392004020041200422004320044200452004620047200482004920050200512005220053200542005520056200572005820059200602006120062200632006420065200662006720068200692007020071200722007320074200752007620077200782007920080200812008220083200842008520086200872008820089200902009120092200932009420095200962009720098200992010020101201022010320104201052010620107201082010920110201112011220113201142011520116201172011820119201202012120122201232012420125201262012720128201292013020131201322013320134201352013620137201382013920140201412014220143201442014520146201472014820149201502015120152201532015420155201562015720158201592016020161201622016320164201652016620167201682016920170201712017220173201742017520176201772017820179201802018120182201832018420185201862018720188201892019020191201922019320194201952019620197201982019920200202012020220203202042020520206202072020820209202102021120212202132021420215202162021720218202192022020221202222022320224202252022620227202282022920230202312023220233202342023520236202372023820239202402024120242202432024420245202462024720248202492025020251202522025320254202552025620257202582025920260202612026220263202642026520266202672026820269202702027120272202732027420275202762027720278202792028020281202822028320284202852028620287202882028920290202912029220293202942029520296202972029820299203002030120302203032030420305203062030720308203092031020311203122031320314203152031620317203182031920320203212032220323203242032520326203272032820329203302033120332203332033420335203362033720338203392034020341203422034320344203452034620347203482034920350203512035220353203542035520356203572035820359203602036120362203632036420365203662036720368203692037020371203722037320374203752037620377203782037920380203812038220383203842038520386203872038820389203902039120392203932039420395203962039720398203992040020401204022040320404204052040620407204082040920410204112041220413204142041520416204172041820419204202042120422204232042420425204262042720428204292043020431204322043320434204352043620437204382043920440204412044220443204442044520446204472044820449204502045120452204532045420455204562045720458204592046020461204622046320464204652046620467204682046920470204712047220473204742047520476204772047820479204802048120482204832048420485204862048720488204892049020491204922049320494204952049620497204982049920500205012050220503205042050520506205072050820509205102051120512205132051420515205162051720518205192052020521205222052320524205252052620527205282052920530205312053220533205342053520536205372053820539205402054120542205432054420545205462054720548205492055020551205522055320554205552055620557205582055920560205612056220563205642056520566205672056820569205702057120572205732057420575205762057720578205792058020581205822058320584205852058620587205882058920590205912059220593205942059520596205972059820599206002060120602206032060420605206062060720608206092061020611206122061320614206152061620617206182061920620206212062220623206242062520626206272062820629206302063120632206332063420635206362063720638206392064020641206422064320644206452064620647206482064920650206512065220653206542065520656206572065820659206602066120662206632066420665206662066720668206692067020671206722067320674206752067620677206782067920680206812068220683206842068520686206872068820689206902069120692206932069420695206962069720698206992070020701207022070320704207052070620707207082070920710207112071220713207142071520716207172071820719207202072120722207232072420725207262072720728207292073020731207322073320734207352073620737207382073920740207412074220743207442074520746207472074820749207502075120752207532075420755207562075720758207592076020761207622076320764207652076620767207682076920770207712077220773207742077520776207772077820779207802078120782207832078420785207862078720788207892079020791207922079320794207952079620797207982079920800208012080220803208042080520806208072080820809208102081120812208132081420815208162081720818208192082020821208222082320824208252082620827208282082920830208312083220833208342083520836208372083820839208402084120842208432084420845208462084720848208492085020851208522085320854208552085620857208582085920860208612086220863208642086520866208672086820869208702087120872208732087420875208762087720878208792088020881208822088320884208852088620887208882088920890208912089220893208942089520896208972089820899209002090120902209032090420905209062090720908209092091020911209122091320914209152091620917209182091920920209212092220923209242092520926209272092820929209302093120932209332093420935209362093720938209392094020941209422094320944209452094620947209482094920950209512095220953209542095520956209572095820959209602096120962209632096420965209662096720968209692097020971209722097320974209752097620977209782097920980209812098220983209842098520986209872098820989209902099120992209932099420995209962099720998209992100021001210022100321004210052100621007210082100921010210112101221013210142101521016210172101821019210202102121022210232102421025210262102721028210292103021031210322103321034210352103621037210382103921040210412104221043210442104521046210472104821049210502105121052210532105421055210562105721058210592106021061210622106321064210652106621067210682106921070210712107221073210742107521076210772107821079210802108121082210832108421085210862108721088210892109021091210922109321094210952109621097210982109921100211012110221103211042110521106211072110821109211102111121112211132111421115211162111721118211192112021121211222112321124211252112621127211282112921130211312113221133211342113521136211372113821139211402114121142211432114421145211462114721148211492115021151211522115321154211552115621157211582115921160211612116221163211642116521166211672116821169211702117121172211732117421175211762117721178211792118021181211822118321184211852118621187211882118921190211912119221193211942119521196211972119821199212002120121202212032120421205212062120721208212092121021211212122121321214212152121621217212182121921220212212122221223212242122521226212272122821229212302123121232212332123421235212362123721238212392124021241212422124321244212452124621247212482124921250212512125221253212542125521256212572125821259212602126121262212632126421265212662126721268212692127021271212722127321274212752127621277212782127921280212812128221283212842128521286212872128821289212902129121292212932129421295212962129721298212992130021301213022130321304213052130621307213082130921310213112131221313213142131521316213172131821319213202132121322213232132421325213262132721328213292133021331213322133321334213352133621337213382133921340213412134221343213442134521346213472134821349213502135121352213532135421355213562135721358213592136021361213622136321364213652136621367213682136921370213712137221373213742137521376213772137821379213802138121382213832138421385213862138721388213892139021391213922139321394213952139621397213982139921400214012140221403214042140521406214072140821409214102141121412214132141421415214162141721418214192142021421214222142321424214252142621427214282142921430214312143221433214342143521436214372143821439214402144121442214432144421445214462144721448214492145021451214522145321454214552145621457214582145921460214612146221463214642146521466214672146821469214702147121472214732147421475214762147721478214792148021481214822148321484214852148621487214882148921490214912149221493214942149521496214972149821499215002150121502215032150421505215062150721508215092151021511215122151321514215152151621517215182151921520215212152221523215242152521526215272152821529215302153121532215332153421535215362153721538215392154021541215422154321544215452154621547215482154921550215512155221553215542155521556215572155821559215602156121562215632156421565215662156721568215692157021571215722157321574215752157621577215782157921580215812158221583215842158521586215872158821589215902159121592215932159421595215962159721598215992160021601216022160321604216052160621607216082160921610216112161221613216142161521616216172161821619216202162121622216232162421625216262162721628216292163021631216322163321634216352163621637216382163921640216412164221643216442164521646216472164821649216502165121652216532165421655216562165721658216592166021661216622166321664216652166621667216682166921670216712167221673216742167521676216772167821679216802168121682216832168421685216862168721688216892169021691216922169321694216952169621697216982169921700217012170221703217042170521706217072170821709217102171121712217132171421715217162171721718217192172021721217222172321724217252172621727217282172921730217312173221733217342173521736217372173821739217402174121742217432174421745217462174721748217492175021751217522175321754217552175621757217582175921760217612176221763217642176521766217672176821769217702177121772217732177421775217762177721778217792178021781217822178321784217852178621787217882178921790217912179221793217942179521796217972179821799218002180121802218032180421805218062180721808218092181021811218122181321814218152181621817218182181921820218212182221823218242182521826218272182821829218302183121832218332183421835218362183721838218392184021841218422184321844218452184621847218482184921850218512185221853218542185521856218572185821859218602186121862218632186421865218662186721868218692187021871218722187321874218752187621877218782187921880218812188221883218842188521886218872188821889218902189121892218932189421895218962189721898218992190021901219022190321904219052190621907219082190921910219112191221913219142191521916219172191821919219202192121922219232192421925219262192721928219292193021931219322193321934219352193621937219382193921940219412194221943219442194521946219472194821949219502195121952219532195421955219562195721958219592196021961219622196321964219652196621967219682196921970219712197221973219742197521976219772197821979219802198121982219832198421985219862198721988219892199021991219922199321994219952199621997219982199922000220012200222003220042200522006220072200822009220102201122012220132201422015220162201722018220192202022021220222202322024220252202622027220282202922030220312203222033220342203522036220372203822039220402204122042220432204422045220462204722048220492205022051220522205322054220552205622057220582205922060220612206222063220642206522066220672206822069220702207122072220732207422075220762207722078220792208022081220822208322084220852208622087220882208922090220912209222093220942209522096220972209822099221002210122102221032210422105221062210722108221092211022111221122211322114221152211622117221182211922120221212212222123221242212522126221272212822129221302213122132221332213422135221362213722138221392214022141221422214322144221452214622147221482214922150221512215222153221542215522156221572215822159221602216122162221632216422165221662216722168221692217022171221722217322174221752217622177221782217922180221812218222183221842218522186221872218822189221902219122192221932219422195221962219722198221992220022201222022220322204222052220622207222082220922210222112221222213222142221522216222172221822219222202222122222222232222422225222262222722228222292223022231222322223322234222352223622237222382223922240222412224222243222442224522246222472224822249222502225122252222532225422255222562225722258222592226022261222622226322264222652226622267222682226922270222712227222273222742227522276222772227822279222802228122282222832228422285222862228722288222892229022291222922229322294222952229622297222982229922300223012230222303223042230522306223072230822309223102231122312223132231422315223162231722318223192232022321223222232322324223252232622327223282232922330223312233222333223342233522336223372233822339223402234122342223432234422345223462234722348223492235022351223522235322354223552235622357223582235922360223612236222363223642236522366223672236822369223702237122372223732237422375223762237722378223792238022381223822238322384223852238622387223882238922390223912239222393223942239522396223972239822399224002240122402224032240422405224062240722408224092241022411224122241322414224152241622417224182241922420224212242222423224242242522426224272242822429224302243122432224332243422435224362243722438224392244022441224422244322444224452244622447224482244922450224512245222453224542245522456224572245822459224602246122462224632246422465224662246722468224692247022471224722247322474224752247622477224782247922480224812248222483224842248522486224872248822489224902249122492224932249422495224962249722498224992250022501225022250322504225052250622507225082250922510225112251222513225142251522516225172251822519225202252122522225232252422525225262252722528225292253022531225322253322534225352253622537225382253922540225412254222543225442254522546225472254822549225502255122552225532255422555225562255722558225592256022561225622256322564225652256622567225682256922570225712257222573225742257522576225772257822579225802258122582225832258422585225862258722588225892259022591225922259322594225952259622597225982259922600226012260222603226042260522606226072260822609226102261122612226132261422615226162261722618226192262022621226222262322624226252262622627226282262922630226312263222633226342263522636226372263822639226402264122642226432264422645226462264722648226492265022651226522265322654226552265622657226582265922660226612266222663226642266522666226672266822669226702267122672226732267422675226762267722678226792268022681226822268322684226852268622687226882268922690226912269222693226942269522696226972269822699227002270122702227032270422705227062270722708227092271022711227122271322714227152271622717227182271922720227212272222723227242272522726227272272822729227302273122732227332273422735227362273722738227392274022741227422274322744227452274622747227482274922750227512275222753227542275522756227572275822759227602276122762227632276422765227662276722768227692277022771227722277322774227752277622777227782277922780227812278222783227842278522786227872278822789227902279122792227932279422795227962279722798227992280022801228022280322804228052280622807228082280922810228112281222813228142281522816228172281822819228202282122822228232282422825228262282722828228292283022831228322283322834228352283622837228382283922840228412284222843228442284522846228472284822849228502285122852228532285422855228562285722858228592286022861228622286322864228652286622867228682286922870228712287222873228742287522876228772287822879228802288122882228832288422885228862288722888228892289022891228922289322894228952289622897228982289922900229012290222903229042290522906229072290822909229102291122912229132291422915229162291722918229192292022921229222292322924229252292622927229282292922930229312293222933229342293522936229372293822939229402294122942229432294422945229462294722948229492295022951229522295322954229552295622957229582295922960229612296222963229642296522966229672296822969229702297122972229732297422975229762297722978229792298022981229822298322984229852298622987229882298922990229912299222993229942299522996229972299822999230002300123002230032300423005230062300723008230092301023011230122301323014230152301623017230182301923020230212302223023230242302523026230272302823029230302303123032230332303423035230362303723038230392304023041230422304323044230452304623047230482304923050230512305223053230542305523056230572305823059230602306123062230632306423065230662306723068230692307023071230722307323074230752307623077230782307923080230812308223083230842308523086230872308823089230902309123092230932309423095230962309723098230992310023101231022310323104231052310623107231082310923110231112311223113231142311523116231172311823119231202312123122231232312423125231262312723128231292313023131231322313323134231352313623137231382313923140231412314223143231442314523146231472314823149231502315123152231532315423155231562315723158231592316023161231622316323164231652316623167231682316923170231712317223173231742317523176231772317823179231802318123182231832318423185231862318723188231892319023191231922319323194231952319623197231982319923200232012320223203232042320523206232072320823209232102321123212232132321423215232162321723218232192322023221232222322323224232252322623227232282322923230232312323223233232342323523236232372323823239232402324123242232432324423245232462324723248232492325023251232522325323254232552325623257232582325923260232612326223263232642326523266232672326823269232702327123272232732327423275232762327723278232792328023281232822328323284232852328623287232882328923290232912329223293232942329523296232972329823299233002330123302233032330423305233062330723308233092331023311233122331323314233152331623317233182331923320233212332223323233242332523326233272332823329233302333123332233332333423335233362333723338233392334023341233422334323344233452334623347233482334923350233512335223353233542335523356233572335823359233602336123362233632336423365233662336723368233692337023371233722337323374233752337623377233782337923380233812338223383233842338523386233872338823389233902339123392233932339423395233962339723398233992340023401234022340323404234052340623407234082340923410234112341223413234142341523416234172341823419234202342123422234232342423425234262342723428234292343023431234322343323434234352343623437234382343923440234412344223443234442344523446234472344823449234502345123452234532345423455234562345723458234592346023461234622346323464234652346623467234682346923470234712347223473234742347523476234772347823479234802348123482234832348423485234862348723488234892349023491234922349323494234952349623497234982349923500235012350223503235042350523506235072350823509235102351123512235132351423515235162351723518235192352023521235222352323524235252352623527235282352923530235312353223533235342353523536235372353823539235402354123542235432354423545235462354723548235492355023551235522355323554235552355623557235582355923560235612356223563235642356523566235672356823569235702357123572235732357423575235762357723578235792358023581235822358323584235852358623587235882358923590235912359223593235942359523596235972359823599236002360123602236032360423605236062360723608236092361023611236122361323614236152361623617236182361923620236212362223623236242362523626236272362823629236302363123632236332363423635236362363723638236392364023641236422364323644236452364623647236482364923650236512365223653236542365523656236572365823659236602366123662236632366423665236662366723668236692367023671236722367323674236752367623677236782367923680236812368223683236842368523686236872368823689236902369123692236932369423695236962369723698236992370023701237022370323704237052370623707237082370923710237112371223713237142371523716237172371823719237202372123722237232372423725237262372723728237292373023731237322373323734237352373623737237382373923740237412374223743237442374523746237472374823749237502375123752237532375423755237562375723758237592376023761237622376323764237652376623767237682376923770237712377223773237742377523776237772377823779237802378123782237832378423785237862378723788237892379023791237922379323794237952379623797237982379923800238012380223803238042380523806238072380823809238102381123812238132381423815238162381723818238192382023821238222382323824238252382623827238282382923830238312383223833238342383523836238372383823839238402384123842238432384423845238462384723848238492385023851238522385323854238552385623857238582385923860238612386223863238642386523866238672386823869238702387123872238732387423875238762387723878238792388023881238822388323884238852388623887238882388923890238912389223893238942389523896238972389823899239002390123902239032390423905239062390723908239092391023911239122391323914239152391623917239182391923920239212392223923239242392523926239272392823929239302393123932239332393423935239362393723938239392394023941239422394323944239452394623947239482394923950239512395223953239542395523956239572395823959239602396123962239632396423965239662396723968239692397023971239722397323974239752397623977239782397923980239812398223983239842398523986239872398823989239902399123992239932399423995239962399723998239992400024001240022400324004240052400624007240082400924010240112401224013240142401524016240172401824019240202402124022240232402424025240262402724028240292403024031240322403324034240352403624037240382403924040240412404224043240442404524046240472404824049240502405124052240532405424055240562405724058240592406024061240622406324064240652406624067240682406924070240712407224073240742407524076240772407824079240802408124082240832408424085240862408724088240892409024091240922409324094240952409624097240982409924100241012410224103241042410524106241072410824109241102411124112241132411424115241162411724118241192412024121241222412324124241252412624127241282412924130241312413224133241342413524136241372413824139241402414124142241432414424145241462414724148241492415024151241522415324154241552415624157241582415924160241612416224163241642416524166241672416824169241702417124172241732417424175241762417724178241792418024181241822418324184241852418624187241882418924190241912419224193241942419524196241972419824199242002420124202242032420424205242062420724208242092421024211242122421324214242152421624217242182421924220242212422224223242242422524226242272422824229242302423124232242332423424235242362423724238242392424024241242422424324244242452424624247242482424924250242512425224253242542425524256242572425824259242602426124262242632426424265242662426724268242692427024271242722427324274242752427624277242782427924280242812428224283242842428524286242872428824289242902429124292242932429424295242962429724298242992430024301243022430324304243052430624307243082430924310243112431224313243142431524316243172431824319243202432124322243232432424325243262432724328243292433024331243322433324334243352433624337243382433924340243412434224343243442434524346243472434824349243502435124352243532435424355243562435724358243592436024361243622436324364243652436624367243682436924370243712437224373243742437524376243772437824379243802438124382243832438424385243862438724388243892439024391243922439324394243952439624397243982439924400244012440224403244042440524406244072440824409244102441124412244132441424415244162441724418244192442024421244222442324424244252442624427244282442924430244312443224433244342443524436244372443824439244402444124442244432444424445244462444724448244492445024451244522445324454244552445624457244582445924460244612446224463244642446524466244672446824469244702447124472244732447424475244762447724478244792448024481244822448324484244852448624487244882448924490244912449224493244942449524496244972449824499245002450124502245032450424505245062450724508245092451024511245122451324514245152451624517245182451924520245212452224523245242452524526245272452824529245302453124532245332453424535245362453724538245392454024541245422454324544245452454624547245482454924550245512455224553245542455524556245572455824559245602456124562245632456424565245662456724568245692457024571245722457324574245752457624577245782457924580245812458224583245842458524586245872458824589245902459124592245932459424595245962459724598245992460024601246022460324604246052460624607246082460924610246112461224613246142461524616246172461824619246202462124622246232462424625246262462724628246292463024631246322463324634246352463624637246382463924640246412464224643246442464524646246472464824649246502465124652246532465424655246562465724658246592466024661246622466324664246652466624667246682466924670246712467224673246742467524676246772467824679246802468124682246832468424685246862468724688246892469024691246922469324694246952469624697246982469924700247012470224703247042470524706247072470824709247102471124712247132471424715247162471724718247192472024721247222472324724247252472624727247282472924730247312473224733247342473524736247372473824739247402474124742247432474424745247462474724748247492475024751247522475324754247552475624757247582475924760247612476224763247642476524766247672476824769247702477124772247732477424775247762477724778247792478024781247822478324784247852478624787247882478924790247912479224793247942479524796247972479824799248002480124802248032480424805248062480724808248092481024811248122481324814248152481624817248182481924820248212482224823248242482524826248272482824829248302483124832248332483424835248362483724838248392484024841248422484324844248452484624847248482484924850248512485224853248542485524856248572485824859248602486124862248632486424865248662486724868248692487024871248722487324874248752487624877248782487924880248812488224883248842488524886248872488824889248902489124892248932489424895248962489724898248992490024901249022490324904249052490624907249082490924910249112491224913249142491524916249172491824919249202492124922249232492424925249262492724928249292493024931249322493324934249352493624937249382493924940249412494224943249442494524946249472494824949249502495124952249532495424955249562495724958249592496024961249622496324964249652496624967249682496924970249712497224973249742497524976249772497824979249802498124982249832498424985249862498724988249892499024991249922499324994249952499624997249982499925000250012500225003250042500525006250072500825009250102501125012250132501425015250162501725018250192502025021250222502325024250252502625027250282502925030250312503225033250342503525036250372503825039250402504125042250432504425045250462504725048250492505025051250522505325054250552505625057250582505925060250612506225063250642506525066250672506825069250702507125072250732507425075250762507725078250792508025081250822508325084250852508625087250882508925090250912509225093250942509525096250972509825099251002510125102251032510425105251062510725108251092511025111251122511325114251152511625117251182511925120251212512225123251242512525126251272512825129251302513125132251332513425135251362513725138251392514025141251422514325144251452514625147251482514925150251512515225153251542515525156251572515825159251602516125162251632516425165251662516725168251692517025171251722517325174251752517625177251782517925180251812518225183251842518525186251872518825189251902519125192251932519425195251962519725198251992520025201252022520325204252052520625207252082520925210252112521225213252142521525216252172521825219252202522125222252232522425225252262522725228252292523025231252322523325234252352523625237252382523925240252412524225243252442524525246252472524825249252502525125252252532525425255252562525725258252592526025261252622526325264252652526625267252682526925270252712527225273252742527525276252772527825279252802528125282252832528425285252862528725288252892529025291252922529325294252952529625297252982529925300253012530225303253042530525306253072530825309253102531125312253132531425315253162531725318253192532025321253222532325324253252532625327253282532925330253312533225333253342533525336253372533825339253402534125342253432534425345253462534725348253492535025351253522535325354253552535625357253582535925360253612536225363253642536525366253672536825369253702537125372253732537425375253762537725378253792538025381253822538325384253852538625387253882538925390253912539225393253942539525396253972539825399254002540125402254032540425405254062540725408254092541025411254122541325414254152541625417254182541925420254212542225423254242542525426254272542825429254302543125432254332543425435254362543725438254392544025441254422544325444254452544625447254482544925450254512545225453254542545525456254572545825459254602546125462254632546425465254662546725468254692547025471254722547325474254752547625477254782547925480254812548225483254842548525486254872548825489254902549125492254932549425495254962549725498254992550025501255022550325504255052550625507255082550925510255112551225513255142551525516255172551825519255202552125522255232552425525255262552725528255292553025531255322553325534255352553625537255382553925540255412554225543255442554525546255472554825549255502555125552255532555425555255562555725558255592556025561255622556325564255652556625567255682556925570255712557225573255742557525576255772557825579255802558125582255832558425585255862558725588255892559025591255922559325594255952559625597255982559925600256012560225603256042560525606256072560825609256102561125612256132561425615256162561725618256192562025621256222562325624256252562625627256282562925630256312563225633256342563525636256372563825639256402564125642256432564425645256462564725648256492565025651256522565325654256552565625657256582565925660256612566225663256642566525666256672566825669256702567125672256732567425675256762567725678256792568025681256822568325684256852568625687256882568925690256912569225693256942569525696256972569825699257002570125702257032570425705257062570725708257092571025711257122571325714257152571625717257182571925720257212572225723257242572525726257272572825729257302573125732257332573425735257362573725738257392574025741257422574325744257452574625747257482574925750257512575225753257542575525756257572575825759257602576125762257632576425765257662576725768257692577025771257722577325774257752577625777257782577925780257812578225783257842578525786257872578825789257902579125792257932579425795257962579725798257992580025801258022580325804258052580625807258082580925810258112581225813258142581525816258172581825819258202582125822258232582425825258262582725828258292583025831258322583325834258352583625837258382583925840258412584225843258442584525846258472584825849258502585125852258532585425855258562585725858258592586025861258622586325864258652586625867258682586925870258712587225873258742587525876258772587825879258802588125882258832588425885258862588725888258892589025891258922589325894258952589625897258982589925900259012590225903259042590525906259072590825909259102591125912259132591425915259162591725918259192592025921259222592325924259252592625927259282592925930259312593225933259342593525936259372593825939259402594125942259432594425945259462594725948259492595025951259522595325954259552595625957259582595925960259612596225963259642596525966259672596825969259702597125972259732597425975259762597725978259792598025981259822598325984259852598625987259882598925990259912599225993259942599525996259972599825999260002600126002260032600426005260062600726008260092601026011260122601326014260152601626017260182601926020260212602226023260242602526026260272602826029260302603126032260332603426035260362603726038260392604026041260422604326044260452604626047260482604926050260512605226053260542605526056260572605826059260602606126062260632606426065260662606726068260692607026071260722607326074260752607626077260782607926080260812608226083260842608526086260872608826089260902609126092260932609426095260962609726098260992610026101261022610326104261052610626107261082610926110261112611226113261142611526116261172611826119261202612126122261232612426125261262612726128261292613026131261322613326134261352613626137261382613926140261412614226143261442614526146261472614826149261502615126152261532615426155261562615726158261592616026161261622616326164261652616626167261682616926170261712617226173261742617526176261772617826179261802618126182261832618426185261862618726188261892619026191261922619326194261952619626197261982619926200262012620226203262042620526206262072620826209262102621126212262132621426215262162621726218262192622026221262222622326224262252622626227262282622926230262312623226233262342623526236262372623826239262402624126242262432624426245262462624726248262492625026251262522625326254262552625626257262582625926260262612626226263262642626526266262672626826269262702627126272262732627426275262762627726278262792628026281262822628326284262852628626287262882628926290262912629226293262942629526296262972629826299263002630126302263032630426305263062630726308263092631026311263122631326314263152631626317263182631926320263212632226323263242632526326263272632826329263302633126332263332633426335263362633726338263392634026341263422634326344263452634626347263482634926350263512635226353263542635526356263572635826359263602636126362263632636426365263662636726368263692637026371263722637326374263752637626377263782637926380263812638226383263842638526386263872638826389263902639126392263932639426395263962639726398263992640026401264022640326404264052640626407264082640926410264112641226413264142641526416264172641826419264202642126422264232642426425264262642726428264292643026431264322643326434264352643626437264382643926440264412644226443264442644526446264472644826449264502645126452264532645426455264562645726458264592646026461264622646326464264652646626467264682646926470264712647226473264742647526476264772647826479264802648126482264832648426485264862648726488264892649026491264922649326494264952649626497264982649926500265012650226503265042650526506265072650826509265102651126512265132651426515265162651726518265192652026521265222652326524265252652626527265282652926530265312653226533265342653526536265372653826539265402654126542265432654426545265462654726548265492655026551265522655326554265552655626557265582655926560265612656226563265642656526566265672656826569265702657126572265732657426575265762657726578265792658026581265822658326584265852658626587265882658926590265912659226593265942659526596265972659826599266002660126602266032660426605266062660726608266092661026611266122661326614266152661626617266182661926620266212662226623266242662526626266272662826629266302663126632266332663426635266362663726638266392664026641266422664326644266452664626647266482664926650266512665226653266542665526656266572665826659266602666126662266632666426665266662666726668266692667026671266722667326674266752667626677266782667926680266812668226683266842668526686266872668826689266902669126692266932669426695266962669726698266992670026701267022670326704267052670626707267082670926710267112671226713267142671526716267172671826719267202672126722267232672426725267262672726728267292673026731267322673326734267352673626737267382673926740267412674226743267442674526746267472674826749267502675126752267532675426755267562675726758267592676026761267622676326764267652676626767267682676926770267712677226773267742677526776267772677826779267802678126782267832678426785267862678726788267892679026791267922679326794267952679626797267982679926800268012680226803268042680526806268072680826809268102681126812268132681426815268162681726818268192682026821268222682326824268252682626827268282682926830268312683226833268342683526836268372683826839268402684126842268432684426845268462684726848268492685026851268522685326854268552685626857268582685926860268612686226863268642686526866268672686826869268702687126872268732687426875268762687726878268792688026881268822688326884268852688626887268882688926890268912689226893268942689526896268972689826899269002690126902269032690426905269062690726908269092691026911269122691326914269152691626917269182691926920269212692226923269242692526926269272692826929269302693126932269332693426935269362693726938269392694026941269422694326944269452694626947269482694926950269512695226953269542695526956269572695826959269602696126962269632696426965269662696726968269692697026971269722697326974269752697626977269782697926980269812698226983269842698526986269872698826989269902699126992269932699426995269962699726998269992700027001270022700327004270052700627007270082700927010270112701227013270142701527016270172701827019270202702127022270232702427025270262702727028270292703027031270322703327034270352703627037270382703927040270412704227043270442704527046270472704827049270502705127052270532705427055270562705727058270592706027061270622706327064270652706627067270682706927070270712707227073270742707527076270772707827079270802708127082270832708427085270862708727088270892709027091270922709327094270952709627097270982709927100271012710227103271042710527106271072710827109271102711127112271132711427115271162711727118271192712027121271222712327124271252712627127271282712927130271312713227133271342713527136271372713827139271402714127142271432714427145271462714727148271492715027151271522715327154271552715627157271582715927160271612716227163271642716527166271672716827169271702717127172271732717427175271762717727178271792718027181271822718327184271852718627187271882718927190271912719227193271942719527196271972719827199272002720127202272032720427205272062720727208272092721027211272122721327214272152721627217272182721927220272212722227223272242722527226272272722827229272302723127232272332723427235272362723727238272392724027241272422724327244272452724627247272482724927250272512725227253272542725527256272572725827259272602726127262272632726427265272662726727268272692727027271272722727327274272752727627277272782727927280272812728227283272842728527286272872728827289272902729127292272932729427295272962729727298272992730027301273022730327304273052730627307273082730927310273112731227313273142731527316273172731827319273202732127322273232732427325273262732727328273292733027331273322733327334273352733627337273382733927340273412734227343273442734527346273472734827349273502735127352273532735427355273562735727358273592736027361273622736327364273652736627367273682736927370273712737227373273742737527376273772737827379273802738127382273832738427385273862738727388273892739027391273922739327394273952739627397273982739927400274012740227403274042740527406274072740827409274102741127412274132741427415274162741727418274192742027421274222742327424274252742627427274282742927430274312743227433274342743527436274372743827439274402744127442274432744427445274462744727448274492745027451274522745327454274552745627457274582745927460274612746227463274642746527466274672746827469274702747127472274732747427475274762747727478274792748027481274822748327484274852748627487274882748927490274912749227493274942749527496274972749827499275002750127502275032750427505275062750727508275092751027511275122751327514275152751627517275182751927520275212752227523275242752527526275272752827529275302753127532275332753427535275362753727538275392754027541275422754327544275452754627547275482754927550275512755227553275542755527556275572755827559275602756127562275632756427565275662756727568275692757027571275722757327574275752757627577275782757927580275812758227583275842758527586275872758827589275902759127592275932759427595275962759727598275992760027601276022760327604276052760627607276082760927610276112761227613276142761527616276172761827619276202762127622276232762427625276262762727628276292763027631276322763327634276352763627637276382763927640276412764227643276442764527646276472764827649276502765127652276532765427655276562765727658276592766027661276622766327664276652766627667276682766927670276712767227673276742767527676276772767827679276802768127682276832768427685276862768727688276892769027691276922769327694276952769627697276982769927700277012770227703277042770527706277072770827709277102771127712277132771427715277162771727718277192772027721277222772327724277252772627727277282772927730277312773227733277342773527736277372773827739277402774127742277432774427745277462774727748277492775027751277522775327754277552775627757277582775927760277612776227763277642776527766277672776827769277702777127772277732777427775277762777727778277792778027781277822778327784277852778627787277882778927790277912779227793277942779527796277972779827799278002780127802278032780427805278062780727808278092781027811278122781327814278152781627817278182781927820278212782227823278242782527826278272782827829278302783127832278332783427835278362783727838278392784027841278422784327844278452784627847278482784927850278512785227853278542785527856278572785827859278602786127862278632786427865278662786727868278692787027871278722787327874278752787627877278782787927880278812788227883278842788527886278872788827889278902789127892278932789427895278962789727898278992790027901279022790327904279052790627907279082790927910279112791227913279142791527916279172791827919279202792127922279232792427925279262792727928279292793027931279322793327934279352793627937279382793927940279412794227943279442794527946279472794827949279502795127952279532795427955279562795727958279592796027961279622796327964279652796627967279682796927970279712797227973279742797527976279772797827979279802798127982279832798427985279862798727988279892799027991279922799327994279952799627997279982799928000280012800228003280042800528006280072800828009280102801128012280132801428015280162801728018280192802028021280222802328024280252802628027280282802928030280312803228033280342803528036280372803828039280402804128042280432804428045280462804728048280492805028051280522805328054280552805628057280582805928060280612806228063280642806528066280672806828069280702807128072280732807428075280762807728078280792808028081280822808328084280852808628087280882808928090280912809228093280942809528096280972809828099281002810128102281032810428105281062810728108281092811028111281122811328114281152811628117281182811928120281212812228123281242812528126281272812828129281302813128132281332813428135281362813728138281392814028141281422814328144281452814628147281482814928150281512815228153281542815528156281572815828159281602816128162281632816428165281662816728168281692817028171281722817328174281752817628177281782817928180281812818228183281842818528186281872818828189281902819128192281932819428195281962819728198281992820028201282022820328204282052820628207282082820928210282112821228213282142821528216282172821828219282202822128222282232822428225282262822728228282292823028231282322823328234282352823628237282382823928240282412824228243282442824528246282472824828249282502825128252282532825428255282562825728258282592826028261282622826328264282652826628267282682826928270282712827228273282742827528276282772827828279282802828128282282832828428285282862828728288282892829028291282922829328294282952829628297282982829928300283012830228303283042830528306283072830828309283102831128312283132831428315283162831728318283192832028321283222832328324283252832628327283282832928330283312833228333283342833528336283372833828339283402834128342283432834428345283462834728348283492835028351283522835328354283552835628357283582835928360283612836228363283642836528366283672836828369283702837128372283732837428375283762837728378283792838028381283822838328384283852838628387283882838928390283912839228393283942839528396283972839828399284002840128402284032840428405284062840728408284092841028411284122841328414284152841628417284182841928420284212842228423284242842528426284272842828429284302843128432284332843428435284362843728438284392844028441284422844328444284452844628447284482844928450284512845228453284542845528456284572845828459284602846128462284632846428465284662846728468284692847028471284722847328474284752847628477284782847928480284812848228483284842848528486284872848828489284902849128492284932849428495284962849728498284992850028501285022850328504285052850628507285082850928510285112851228513285142851528516285172851828519285202852128522285232852428525285262852728528285292853028531285322853328534285352853628537285382853928540285412854228543285442854528546285472854828549285502855128552285532855428555285562855728558285592856028561285622856328564285652856628567285682856928570285712857228573285742857528576285772857828579285802858128582285832858428585285862858728588285892859028591285922859328594285952859628597285982859928600286012860228603286042860528606286072860828609286102861128612286132861428615286162861728618286192862028621286222862328624286252862628627286282862928630286312863228633286342863528636286372863828639286402864128642286432864428645286462864728648286492865028651286522865328654286552865628657286582865928660286612866228663286642866528666286672866828669286702867128672286732867428675286762867728678286792868028681286822868328684286852868628687286882868928690286912869228693286942869528696286972869828699287002870128702287032870428705287062870728708287092871028711287122871328714287152871628717287182871928720287212872228723287242872528726287272872828729287302873128732287332873428735287362873728738287392874028741287422874328744287452874628747287482874928750287512875228753287542875528756287572875828759287602876128762287632876428765287662876728768287692877028771287722877328774287752877628777287782877928780287812878228783287842878528786287872878828789287902879128792287932879428795287962879728798287992880028801288022880328804288052880628807288082880928810288112881228813288142881528816288172881828819288202882128822288232882428825288262882728828288292883028831288322883328834288352883628837288382883928840288412884228843288442884528846288472884828849288502885128852288532885428855288562885728858288592886028861288622886328864288652886628867288682886928870288712887228873288742887528876288772887828879288802888128882288832888428885288862888728888288892889028891288922889328894288952889628897288982889928900289012890228903289042890528906289072890828909289102891128912289132891428915289162891728918289192892028921289222892328924289252892628927289282892928930289312893228933289342893528936289372893828939289402894128942289432894428945289462894728948289492895028951289522895328954289552895628957289582895928960289612896228963289642896528966289672896828969289702897128972289732897428975289762897728978289792898028981289822898328984289852898628987289882898928990289912899228993289942899528996289972899828999290002900129002290032900429005290062900729008290092901029011290122901329014290152901629017290182901929020290212902229023290242902529026290272902829029290302903129032290332903429035290362903729038290392904029041290422904329044290452904629047290482904929050290512905229053290542905529056290572905829059290602906129062290632906429065290662906729068290692907029071290722907329074290752907629077290782907929080290812908229083290842908529086290872908829089290902909129092290932909429095290962909729098290992910029101291022910329104291052910629107291082910929110291112911229113291142911529116291172911829119291202912129122291232912429125291262912729128291292913029131291322913329134291352913629137291382913929140291412914229143291442914529146291472914829149291502915129152291532915429155291562915729158291592916029161291622916329164291652916629167291682916929170291712917229173291742917529176291772917829179291802918129182291832918429185291862918729188291892919029191291922919329194291952919629197291982919929200292012920229203292042920529206292072920829209292102921129212292132921429215292162921729218292192922029221292222922329224292252922629227292282922929230292312923229233292342923529236292372923829239292402924129242292432924429245292462924729248292492925029251292522925329254292552925629257292582925929260292612926229263292642926529266292672926829269292702927129272292732927429275292762927729278292792928029281292822928329284292852928629287292882928929290292912929229293292942929529296292972929829299293002930129302293032930429305293062930729308293092931029311293122931329314293152931629317293182931929320293212932229323293242932529326293272932829329293302933129332293332933429335293362933729338293392934029341293422934329344293452934629347293482934929350293512935229353293542935529356293572935829359293602936129362293632936429365293662936729368293692937029371293722937329374293752937629377293782937929380293812938229383293842938529386293872938829389293902939129392293932939429395293962939729398293992940029401294022940329404294052940629407294082940929410294112941229413294142941529416294172941829419294202942129422294232942429425294262942729428294292943029431294322943329434294352943629437294382943929440294412944229443294442944529446294472944829449294502945129452294532945429455294562945729458294592946029461294622946329464294652946629467294682946929470294712947229473294742947529476294772947829479294802948129482294832948429485294862948729488294892949029491294922949329494294952949629497294982949929500295012950229503295042950529506295072950829509295102951129512295132951429515295162951729518295192952029521295222952329524295252952629527295282952929530295312953229533295342953529536295372953829539295402954129542295432954429545295462954729548295492955029551295522955329554295552955629557295582955929560295612956229563295642956529566295672956829569295702957129572295732957429575295762957729578295792958029581295822958329584295852958629587295882958929590295912959229593295942959529596295972959829599296002960129602296032960429605296062960729608296092961029611296122961329614296152961629617296182961929620296212962229623296242962529626296272962829629296302963129632296332963429635296362963729638296392964029641296422964329644296452964629647296482964929650296512965229653296542965529656296572965829659296602966129662296632966429665296662966729668296692967029671296722967329674296752967629677296782967929680296812968229683296842968529686296872968829689296902969129692296932969429695296962969729698296992970029701297022970329704297052970629707297082970929710297112971229713297142971529716297172971829719297202972129722297232972429725297262972729728297292973029731297322973329734297352973629737297382973929740297412974229743297442974529746297472974829749297502975129752297532975429755297562975729758297592976029761297622976329764297652976629767297682976929770297712977229773297742977529776297772977829779297802978129782297832978429785297862978729788297892979029791297922979329794297952979629797297982979929800298012980229803298042980529806298072980829809298102981129812298132981429815298162981729818298192982029821298222982329824298252982629827298282982929830298312983229833298342983529836298372983829839298402984129842298432984429845298462984729848298492985029851298522985329854298552985629857298582985929860298612986229863298642986529866298672986829869298702987129872298732987429875298762987729878298792988029881298822988329884298852988629887298882988929890298912989229893298942989529896298972989829899299002990129902299032990429905299062990729908299092991029911299122991329914299152991629917299182991929920299212992229923299242992529926299272992829929299302993129932299332993429935299362993729938299392994029941299422994329944299452994629947299482994929950299512995229953299542995529956299572995829959299602996129962299632996429965299662996729968299692997029971299722997329974299752997629977299782997929980299812998229983299842998529986299872998829989299902999129992299932999429995299962999729998299993000030001300023000330004300053000630007300083000930010300113001230013300143001530016300173001830019300203002130022300233002430025300263002730028300293003030031300323003330034300353003630037300383003930040300413004230043300443004530046300473004830049300503005130052300533005430055300563005730058300593006030061300623006330064300653006630067300683006930070300713007230073300743007530076300773007830079300803008130082300833008430085300863008730088300893009030091300923009330094300953009630097300983009930100301013010230103301043010530106301073010830109301103011130112301133011430115301163011730118301193012030121301223012330124301253012630127301283012930130301313013230133301343013530136301373013830139301403014130142301433014430145301463014730148301493015030151301523015330154301553015630157301583015930160301613016230163301643016530166301673016830169301703017130172301733017430175301763017730178301793018030181301823018330184301853018630187301883018930190301913019230193301943019530196301973019830199302003020130202302033020430205302063020730208302093021030211302123021330214302153021630217302183021930220302213022230223302243022530226302273022830229302303023130232302333023430235302363023730238302393024030241302423024330244302453024630247302483024930250302513025230253302543025530256302573025830259302603026130262302633026430265302663026730268302693027030271302723027330274302753027630277302783027930280302813028230283302843028530286302873028830289302903029130292302933029430295302963029730298302993030030301303023030330304303053030630307303083030930310303113031230313303143031530316303173031830319303203032130322303233032430325303263032730328303293033030331303323033330334303353033630337303383033930340303413034230343303443034530346303473034830349303503035130352303533035430355303563035730358303593036030361303623036330364303653036630367303683036930370303713037230373303743037530376303773037830379303803038130382303833038430385303863038730388303893039030391303923039330394303953039630397303983039930400304013040230403304043040530406304073040830409304103041130412304133041430415304163041730418304193042030421304223042330424304253042630427304283042930430304313043230433304343043530436304373043830439304403044130442304433044430445304463044730448304493045030451304523045330454304553045630457304583045930460304613046230463304643046530466304673046830469304703047130472304733047430475304763047730478304793048030481304823048330484304853048630487304883048930490304913049230493304943049530496304973049830499305003050130502305033050430505305063050730508305093051030511305123051330514305153051630517305183051930520305213052230523305243052530526305273052830529305303053130532305333053430535305363053730538305393054030541305423054330544305453054630547305483054930550305513055230553305543055530556305573055830559305603056130562305633056430565305663056730568305693057030571305723057330574305753057630577305783057930580305813058230583305843058530586305873058830589305903059130592305933059430595305963059730598305993060030601306023060330604306053060630607306083060930610306113061230613306143061530616306173061830619306203062130622306233062430625306263062730628306293063030631306323063330634306353063630637306383063930640306413064230643306443064530646306473064830649306503065130652306533065430655306563065730658306593066030661306623066330664306653066630667306683066930670306713067230673306743067530676306773067830679306803068130682306833068430685306863068730688306893069030691306923069330694306953069630697306983069930700307013070230703307043070530706307073070830709307103071130712307133071430715307163071730718307193072030721307223072330724307253072630727307283072930730307313073230733307343073530736307373073830739307403074130742307433074430745307463074730748307493075030751307523075330754307553075630757307583075930760307613076230763307643076530766307673076830769307703077130772307733077430775307763077730778307793078030781307823078330784307853078630787307883078930790307913079230793307943079530796307973079830799308003080130802308033080430805308063080730808308093081030811308123081330814308153081630817308183081930820308213082230823308243082530826308273082830829308303083130832308333083430835308363083730838308393084030841308423084330844308453084630847308483084930850308513085230853308543085530856308573085830859308603086130862308633086430865308663086730868308693087030871308723087330874308753087630877308783087930880308813088230883308843088530886308873088830889308903089130892308933089430895308963089730898308993090030901309023090330904309053090630907309083090930910309113091230913309143091530916309173091830919309203092130922309233092430925309263092730928309293093030931309323093330934309353093630937309383093930940309413094230943309443094530946309473094830949309503095130952309533095430955309563095730958309593096030961309623096330964309653096630967309683096930970309713097230973309743097530976309773097830979309803098130982309833098430985309863098730988309893099030991309923099330994309953099630997309983099931000310013100231003310043100531006310073100831009310103101131012310133101431015310163101731018310193102031021310223102331024310253102631027310283102931030310313103231033310343103531036310373103831039310403104131042310433104431045310463104731048310493105031051310523105331054310553105631057310583105931060310613106231063310643106531066310673106831069310703107131072310733107431075310763107731078310793108031081310823108331084310853108631087310883108931090310913109231093310943109531096310973109831099311003110131102311033110431105311063110731108311093111031111311123111331114311153111631117311183111931120311213112231123311243112531126311273112831129311303113131132311333113431135311363113731138311393114031141311423114331144311453114631147311483114931150311513115231153311543115531156311573115831159311603116131162311633116431165311663116731168311693117031171311723117331174311753117631177311783117931180311813118231183311843118531186311873118831189311903119131192311933119431195311963119731198311993120031201312023120331204312053120631207312083120931210312113121231213312143121531216312173121831219312203122131222312233122431225312263122731228312293123031231312323123331234312353123631237312383123931240312413124231243312443124531246312473124831249312503125131252312533125431255312563125731258312593126031261312623126331264312653126631267312683126931270312713127231273312743127531276312773127831279312803128131282312833128431285312863128731288312893129031291312923129331294312953129631297312983129931300313013130231303313043130531306313073130831309313103131131312313133131431315313163131731318313193132031321313223132331324313253132631327313283132931330313313133231333313343133531336313373133831339313403134131342313433134431345313463134731348313493135031351313523135331354313553135631357313583135931360313613136231363313643136531366313673136831369313703137131372313733137431375313763137731378313793138031381313823138331384313853138631387313883138931390313913139231393313943139531396313973139831399314003140131402314033140431405314063140731408314093141031411314123141331414314153141631417314183141931420314213142231423314243142531426314273142831429314303143131432314333143431435314363143731438314393144031441314423144331444314453144631447314483144931450314513145231453314543145531456314573145831459314603146131462314633146431465314663146731468314693147031471314723147331474314753147631477314783147931480314813148231483314843148531486314873148831489314903149131492314933149431495314963149731498314993150031501315023150331504315053150631507315083150931510315113151231513315143151531516315173151831519315203152131522315233152431525315263152731528315293153031531315323153331534315353153631537315383153931540315413154231543315443154531546315473154831549315503155131552315533155431555315563155731558315593156031561315623156331564315653156631567315683156931570315713157231573315743157531576315773157831579315803158131582315833158431585315863158731588315893159031591315923159331594315953159631597315983159931600316013160231603316043160531606316073160831609316103161131612316133161431615316163161731618316193162031621316223162331624316253162631627316283162931630316313163231633316343163531636316373163831639316403164131642316433164431645316463164731648316493165031651316523165331654316553165631657316583165931660316613166231663316643166531666316673166831669316703167131672316733167431675316763167731678316793168031681316823168331684316853168631687316883168931690316913169231693316943169531696316973169831699317003170131702317033170431705317063170731708317093171031711317123171331714317153171631717317183171931720317213172231723317243172531726317273172831729317303173131732317333173431735317363173731738317393174031741317423174331744317453174631747317483174931750317513175231753317543175531756317573175831759317603176131762317633176431765317663176731768317693177031771317723177331774317753177631777317783177931780317813178231783317843178531786317873178831789317903179131792317933179431795317963179731798317993180031801318023180331804318053180631807318083180931810318113181231813318143181531816318173181831819318203182131822318233182431825318263182731828318293183031831318323183331834318353183631837318383183931840318413184231843318443184531846318473184831849318503185131852318533185431855318563185731858318593186031861318623186331864318653186631867318683186931870318713187231873318743187531876318773187831879318803188131882318833188431885318863188731888318893189031891318923189331894318953189631897318983189931900319013190231903319043190531906319073190831909319103191131912319133191431915319163191731918319193192031921319223192331924319253192631927319283192931930319313193231933319343193531936319373193831939319403194131942319433194431945319463194731948319493195031951319523195331954319553195631957319583195931960319613196231963319643196531966319673196831969319703197131972319733197431975319763197731978319793198031981319823198331984319853198631987319883198931990319913199231993319943199531996319973199831999320003200132002320033200432005320063200732008320093201032011320123201332014320153201632017320183201932020320213202232023320243202532026320273202832029320303203132032320333203432035320363203732038320393204032041320423204332044320453204632047320483204932050320513205232053320543205532056320573205832059320603206132062320633206432065320663206732068320693207032071320723207332074320753207632077320783207932080320813208232083320843208532086320873208832089320903209132092320933209432095320963209732098320993210032101321023210332104321053210632107321083210932110321113211232113321143211532116321173211832119321203212132122321233212432125321263212732128321293213032131321323213332134321353213632137321383213932140321413214232143321443214532146321473214832149321503215132152321533215432155321563215732158321593216032161321623216332164321653216632167321683216932170321713217232173321743217532176321773217832179321803218132182321833218432185321863218732188321893219032191321923219332194321953219632197321983219932200322013220232203322043220532206322073220832209322103221132212322133221432215322163221732218322193222032221322223222332224322253222632227322283222932230322313223232233322343223532236322373223832239322403224132242322433224432245322463224732248322493225032251322523225332254322553225632257322583225932260322613226232263322643226532266322673226832269322703227132272322733227432275322763227732278322793228032281322823228332284322853228632287322883228932290322913229232293322943229532296322973229832299323003230132302323033230432305323063230732308323093231032311323123231332314323153231632317323183231932320323213232232323323243232532326323273232832329323303233132332323333233432335323363233732338323393234032341323423234332344323453234632347323483234932350323513235232353323543235532356323573235832359323603236132362323633236432365323663236732368323693237032371323723237332374323753237632377323783237932380323813238232383323843238532386323873238832389323903239132392323933239432395323963239732398323993240032401324023240332404324053240632407324083240932410324113241232413324143241532416324173241832419324203242132422324233242432425324263242732428324293243032431324323243332434324353243632437324383243932440324413244232443324443244532446324473244832449324503245132452324533245432455324563245732458324593246032461324623246332464324653246632467324683246932470324713247232473324743247532476324773247832479324803248132482324833248432485324863248732488324893249032491324923249332494324953249632497324983249932500325013250232503325043250532506325073250832509325103251132512325133251432515325163251732518325193252032521325223252332524325253252632527325283252932530325313253232533325343253532536325373253832539325403254132542325433254432545325463254732548325493255032551325523255332554325553255632557325583255932560325613256232563325643256532566325673256832569325703257132572325733257432575325763257732578325793258032581325823258332584325853258632587325883258932590325913259232593325943259532596325973259832599326003260132602326033260432605326063260732608326093261032611326123261332614326153261632617326183261932620326213262232623326243262532626326273262832629326303263132632326333263432635326363263732638326393264032641326423264332644326453264632647326483264932650326513265232653326543265532656326573265832659326603266132662326633266432665326663266732668326693267032671326723267332674326753267632677326783267932680326813268232683326843268532686326873268832689326903269132692326933269432695326963269732698326993270032701327023270332704327053270632707327083270932710327113271232713327143271532716327173271832719327203272132722327233272432725327263272732728327293273032731327323273332734327353273632737327383273932740327413274232743327443274532746327473274832749327503275132752327533275432755327563275732758327593276032761327623276332764327653276632767327683276932770327713277232773327743277532776327773277832779327803278132782327833278432785327863278732788327893279032791327923279332794327953279632797327983279932800328013280232803328043280532806328073280832809328103281132812328133281432815328163281732818328193282032821328223282332824328253282632827328283282932830328313283232833328343283532836328373283832839328403284132842328433284432845328463284732848328493285032851328523285332854328553285632857328583285932860328613286232863328643286532866328673286832869328703287132872328733287432875328763287732878328793288032881328823288332884328853288632887328883288932890328913289232893328943289532896328973289832899329003290132902329033290432905329063290732908329093291032911329123291332914329153291632917329183291932920329213292232923329243292532926329273292832929329303293132932329333293432935329363293732938329393294032941329423294332944329453294632947329483294932950329513295232953329543295532956329573295832959329603296132962329633296432965329663296732968329693297032971329723297332974329753297632977329783297932980329813298232983329843298532986329873298832989329903299132992329933299432995329963299732998329993300033001330023300333004330053300633007330083300933010330113301233013330143301533016330173301833019330203302133022330233302433025330263302733028330293303033031330323303333034330353303633037330383303933040330413304233043330443304533046330473304833049330503305133052330533305433055330563305733058330593306033061330623306333064330653306633067330683306933070330713307233073330743307533076330773307833079330803308133082330833308433085330863308733088330893309033091330923309333094330953309633097330983309933100331013310233103331043310533106331073310833109331103311133112331133311433115331163311733118331193312033121331223312333124331253312633127331283312933130331313313233133331343313533136331373313833139331403314133142331433314433145331463314733148331493315033151331523315333154331553315633157331583315933160331613316233163331643316533166331673316833169331703317133172331733317433175331763317733178331793318033181331823318333184331853318633187331883318933190331913319233193331943319533196331973319833199332003320133202332033320433205332063320733208332093321033211332123321333214332153321633217332183321933220332213322233223332243322533226332273322833229332303323133232332333323433235332363323733238332393324033241332423324333244332453324633247332483324933250332513325233253332543325533256332573325833259332603326133262332633326433265332663326733268332693327033271332723327333274332753327633277332783327933280332813328233283332843328533286332873328833289332903329133292332933329433295332963329733298332993330033301333023330333304333053330633307333083330933310333113331233313333143331533316333173331833319333203332133322333233332433325333263332733328333293333033331333323333333334333353333633337333383333933340333413334233343333443334533346333473334833349333503335133352333533335433355333563335733358333593336033361333623336333364333653336633367333683336933370333713337233373333743337533376333773337833379333803338133382333833338433385333863338733388333893339033391333923339333394333953339633397333983339933400334013340233403334043340533406334073340833409334103341133412334133341433415334163341733418334193342033421334223342333424334253342633427334283342933430334313343233433334343343533436334373343833439334403344133442334433344433445334463344733448334493345033451334523345333454334553345633457334583345933460334613346233463334643346533466334673346833469334703347133472334733347433475334763347733478334793348033481334823348333484334853348633487334883348933490334913349233493334943349533496334973349833499335003350133502335033350433505335063350733508335093351033511335123351333514335153351633517335183351933520335213352233523335243352533526335273352833529335303353133532335333353433535335363353733538335393354033541335423354333544335453354633547335483354933550335513355233553335543355533556335573355833559335603356133562335633356433565335663356733568335693357033571335723357333574335753357633577335783357933580335813358233583335843358533586335873358833589335903359133592335933359433595335963359733598335993360033601336023360333604336053360633607336083360933610336113361233613336143361533616336173361833619336203362133622336233362433625336263362733628336293363033631336323363333634336353363633637336383363933640336413364233643336443364533646336473364833649336503365133652336533365433655336563365733658336593366033661336623366333664336653366633667336683366933670336713367233673336743367533676336773367833679336803368133682336833368433685336863368733688336893369033691336923369333694336953369633697336983369933700337013370233703337043370533706337073370833709337103371133712337133371433715337163371733718337193372033721337223372333724337253372633727337283372933730337313373233733337343373533736337373373833739337403374133742337433374433745337463374733748337493375033751337523375333754337553375633757337583375933760337613376233763337643376533766337673376833769337703377133772337733377433775337763377733778337793378033781337823378333784337853378633787337883378933790337913379233793337943379533796337973379833799338003380133802338033380433805338063380733808338093381033811338123381333814338153381633817338183381933820338213382233823338243382533826338273382833829338303383133832338333383433835338363383733838338393384033841338423384333844338453384633847338483384933850338513385233853338543385533856338573385833859338603386133862338633386433865338663386733868338693387033871338723387333874338753387633877338783387933880338813388233883338843388533886338873388833889338903389133892338933389433895338963389733898338993390033901339023390333904339053390633907339083390933910339113391233913339143391533916339173391833919339203392133922339233392433925339263392733928339293393033931339323393333934339353393633937339383393933940339413394233943339443394533946339473394833949339503395133952339533395433955339563395733958339593396033961339623396333964339653396633967339683396933970339713397233973339743397533976339773397833979339803398133982339833398433985339863398733988339893399033991339923399333994339953399633997339983399934000340013400234003340043400534006340073400834009340103401134012340133401434015340163401734018340193402034021340223402334024340253402634027340283402934030340313403234033340343403534036340373403834039340403404134042340433404434045340463404734048340493405034051340523405334054340553405634057340583405934060340613406234063340643406534066340673406834069340703407134072340733407434075340763407734078340793408034081340823408334084340853408634087340883408934090340913409234093340943409534096340973409834099341003410134102341033410434105341063410734108341093411034111341123411334114341153411634117341183411934120341213412234123341243412534126341273412834129341303413134132341333413434135341363413734138341393414034141341423414334144341453414634147341483414934150341513415234153341543415534156341573415834159341603416134162341633416434165341663416734168341693417034171341723417334174341753417634177341783417934180341813418234183341843418534186341873418834189341903419134192341933419434195341963419734198341993420034201342023420334204342053420634207342083420934210342113421234213342143421534216342173421834219342203422134222342233422434225342263422734228342293423034231342323423334234342353423634237342383423934240342413424234243342443424534246342473424834249342503425134252342533425434255342563425734258342593426034261342623426334264342653426634267342683426934270342713427234273342743427534276342773427834279342803428134282342833428434285342863428734288342893429034291342923429334294342953429634297342983429934300343013430234303343043430534306343073430834309343103431134312343133431434315343163431734318343193432034321343223432334324343253432634327343283432934330343313433234333343343433534336343373433834339343403434134342343433434434345343463434734348343493435034351343523435334354343553435634357343583435934360343613436234363343643436534366343673436834369343703437134372343733437434375343763437734378343793438034381343823438334384343853438634387343883438934390343913439234393343943439534396343973439834399344003440134402344033440434405344063440734408344093441034411344123441334414344153441634417344183441934420344213442234423344243442534426344273442834429344303443134432344333443434435344363443734438344393444034441344423444334444344453444634447344483444934450344513445234453344543445534456344573445834459344603446134462344633446434465344663446734468344693447034471344723447334474344753447634477344783447934480344813448234483344843448534486344873448834489344903449134492344933449434495344963449734498344993450034501345023450334504345053450634507345083450934510345113451234513345143451534516345173451834519345203452134522345233452434525345263452734528345293453034531345323453334534345353453634537345383453934540345413454234543345443454534546345473454834549345503455134552345533455434555345563455734558345593456034561345623456334564345653456634567345683456934570345713457234573345743457534576345773457834579345803458134582345833458434585345863458734588345893459034591345923459334594345953459634597345983459934600346013460234603346043460534606346073460834609346103461134612346133461434615346163461734618346193462034621346223462334624346253462634627346283462934630346313463234633346343463534636346373463834639346403464134642346433464434645346463464734648346493465034651346523465334654346553465634657346583465934660346613466234663346643466534666346673466834669346703467134672346733467434675346763467734678346793468034681346823468334684346853468634687346883468934690346913469234693346943469534696346973469834699347003470134702347033470434705347063470734708347093471034711347123471334714347153471634717347183471934720347213472234723347243472534726347273472834729347303473134732347333473434735347363473734738347393474034741347423474334744347453474634747347483474934750347513475234753347543475534756347573475834759347603476134762347633476434765347663476734768347693477034771347723477334774347753477634777347783477934780347813478234783347843478534786347873478834789347903479134792347933479434795347963479734798347993480034801348023480334804348053480634807348083480934810348113481234813348143481534816348173481834819348203482134822348233482434825348263482734828348293483034831348323483334834348353483634837348383483934840348413484234843348443484534846348473484834849348503485134852348533485434855348563485734858348593486034861348623486334864348653486634867348683486934870348713487234873348743487534876348773487834879348803488134882348833488434885348863488734888348893489034891348923489334894348953489634897348983489934900349013490234903349043490534906349073490834909349103491134912349133491434915349163491734918349193492034921349223492334924349253492634927349283492934930349313493234933349343493534936349373493834939349403494134942349433494434945349463494734948349493495034951349523495334954349553495634957349583495934960349613496234963349643496534966349673496834969349703497134972349733497434975349763497734978349793498034981349823498334984349853498634987349883498934990349913499234993349943499534996349973499834999350003500135002350033500435005350063500735008350093501035011350123501335014350153501635017350183501935020350213502235023350243502535026350273502835029350303503135032350333503435035350363503735038350393504035041350423504335044350453504635047350483504935050350513505235053350543505535056350573505835059350603506135062350633506435065350663506735068350693507035071350723507335074350753507635077350783507935080350813508235083350843508535086350873508835089350903509135092350933509435095350963509735098350993510035101351023510335104351053510635107351083510935110351113511235113351143511535116351173511835119351203512135122351233512435125351263512735128351293513035131351323513335134351353513635137351383513935140351413514235143351443514535146351473514835149351503515135152351533515435155351563515735158351593516035161351623516335164351653516635167351683516935170351713517235173351743517535176351773517835179351803518135182351833518435185351863518735188351893519035191351923519335194351953519635197351983519935200352013520235203352043520535206352073520835209352103521135212352133521435215352163521735218352193522035221352223522335224352253522635227352283522935230352313523235233352343523535236352373523835239352403524135242352433524435245352463524735248352493525035251352523525335254352553525635257352583525935260352613526235263352643526535266352673526835269352703527135272352733527435275352763527735278352793528035281352823528335284352853528635287352883528935290352913529235293352943529535296352973529835299353003530135302353033530435305353063530735308353093531035311353123531335314353153531635317353183531935320353213532235323353243532535326353273532835329353303533135332353333533435335353363533735338353393534035341353423534335344353453534635347353483534935350353513535235353353543535535356353573535835359353603536135362353633536435365353663536735368353693537035371353723537335374353753537635377353783537935380353813538235383353843538535386353873538835389353903539135392353933539435395353963539735398353993540035401354023540335404354053540635407354083540935410354113541235413354143541535416354173541835419354203542135422354233542435425354263542735428354293543035431354323543335434354353543635437354383543935440354413544235443354443544535446354473544835449354503545135452354533545435455354563545735458354593546035461354623546335464354653546635467354683546935470354713547235473354743547535476354773547835479354803548135482354833548435485354863548735488354893549035491354923549335494354953549635497354983549935500355013550235503355043550535506355073550835509355103551135512355133551435515355163551735518355193552035521355223552335524355253552635527355283552935530355313553235533355343553535536355373553835539355403554135542355433554435545355463554735548355493555035551355523555335554355553555635557355583555935560355613556235563355643556535566355673556835569355703557135572355733557435575355763557735578355793558035581355823558335584355853558635587355883558935590355913559235593355943559535596355973559835599356003560135602356033560435605356063560735608356093561035611356123561335614356153561635617356183561935620356213562235623356243562535626356273562835629356303563135632356333563435635356363563735638356393564035641356423564335644356453564635647356483564935650356513565235653356543565535656356573565835659356603566135662356633566435665356663566735668356693567035671356723567335674356753567635677356783567935680356813568235683356843568535686356873568835689356903569135692356933569435695356963569735698356993570035701357023570335704357053570635707357083570935710357113571235713357143571535716357173571835719357203572135722357233572435725357263572735728357293573035731357323573335734357353573635737357383573935740357413574235743357443574535746357473574835749357503575135752357533575435755357563575735758357593576035761357623576335764357653576635767357683576935770357713577235773357743577535776357773577835779357803578135782357833578435785357863578735788357893579035791357923579335794357953579635797357983579935800358013580235803358043580535806358073580835809358103581135812358133581435815358163581735818358193582035821358223582335824358253582635827358283582935830358313583235833358343583535836358373583835839358403584135842358433584435845358463584735848358493585035851358523585335854358553585635857358583585935860358613586235863358643586535866358673586835869358703587135872358733587435875358763587735878358793588035881358823588335884358853588635887358883588935890358913589235893358943589535896358973589835899359003590135902359033590435905359063590735908359093591035911359123591335914359153591635917359183591935920359213592235923359243592535926359273592835929359303593135932359333593435935359363593735938359393594035941359423594335944359453594635947359483594935950359513595235953359543595535956359573595835959359603596135962359633596435965359663596735968359693597035971359723597335974359753597635977359783597935980359813598235983359843598535986359873598835989359903599135992359933599435995359963599735998359993600036001360023600336004360053600636007360083600936010360113601236013360143601536016360173601836019360203602136022360233602436025360263602736028360293603036031360323603336034360353603636037360383603936040360413604236043360443604536046360473604836049360503605136052360533605436055360563605736058360593606036061360623606336064360653606636067360683606936070360713607236073360743607536076360773607836079360803608136082360833608436085360863608736088360893609036091360923609336094360953609636097360983609936100361013610236103361043610536106361073610836109361103611136112361133611436115361163611736118361193612036121361223612336124361253612636127361283612936130361313613236133361343613536136361373613836139361403614136142361433614436145361463614736148361493615036151361523615336154361553615636157361583615936160361613616236163361643616536166361673616836169361703617136172361733617436175361763617736178361793618036181361823618336184361853618636187361883618936190361913619236193361943619536196361973619836199362003620136202362033620436205362063620736208362093621036211362123621336214362153621636217362183621936220362213622236223362243622536226362273622836229362303623136232362333623436235362363623736238362393624036241362423624336244362453624636247362483624936250362513625236253362543625536256362573625836259362603626136262362633626436265362663626736268362693627036271362723627336274362753627636277362783627936280362813628236283362843628536286362873628836289362903629136292362933629436295362963629736298362993630036301363023630336304363053630636307363083630936310363113631236313363143631536316363173631836319363203632136322363233632436325363263632736328363293633036331363323633336334363353633636337363383633936340363413634236343363443634536346363473634836349363503635136352363533635436355363563635736358363593636036361363623636336364363653636636367363683636936370363713637236373363743637536376363773637836379363803638136382363833638436385363863638736388363893639036391363923639336394363953639636397363983639936400364013640236403364043640536406364073640836409364103641136412364133641436415364163641736418364193642036421364223642336424364253642636427364283642936430364313643236433364343643536436364373643836439364403644136442364433644436445364463644736448364493645036451364523645336454364553645636457364583645936460364613646236463364643646536466364673646836469364703647136472364733647436475364763647736478364793648036481364823648336484364853648636487364883648936490364913649236493364943649536496364973649836499365003650136502365033650436505365063650736508365093651036511365123651336514365153651636517365183651936520365213652236523365243652536526365273652836529365303653136532365333653436535365363653736538365393654036541365423654336544365453654636547365483654936550365513655236553365543655536556365573655836559365603656136562365633656436565365663656736568365693657036571365723657336574365753657636577365783657936580365813658236583365843658536586365873658836589365903659136592365933659436595365963659736598365993660036601366023660336604366053660636607366083660936610366113661236613366143661536616366173661836619366203662136622366233662436625366263662736628366293663036631366323663336634366353663636637366383663936640366413664236643366443664536646366473664836649366503665136652366533665436655366563665736658366593666036661366623666336664366653666636667366683666936670366713667236673366743667536676366773667836679366803668136682366833668436685366863668736688366893669036691366923669336694366953669636697366983669936700367013670236703367043670536706367073670836709367103671136712367133671436715367163671736718367193672036721367223672336724367253672636727367283672936730367313673236733367343673536736367373673836739367403674136742367433674436745367463674736748367493675036751367523675336754367553675636757367583675936760367613676236763367643676536766367673676836769367703677136772367733677436775367763677736778367793678036781367823678336784367853678636787367883678936790367913679236793367943679536796367973679836799368003680136802368033680436805368063680736808368093681036811368123681336814368153681636817368183681936820368213682236823368243682536826368273682836829368303683136832368333683436835368363683736838368393684036841368423684336844368453684636847368483684936850368513685236853368543685536856368573685836859368603686136862368633686436865368663686736868368693687036871368723687336874368753687636877368783687936880368813688236883368843688536886368873688836889368903689136892368933689436895368963689736898368993690036901369023690336904369053690636907369083690936910369113691236913369143691536916369173691836919369203692136922369233692436925369263692736928369293693036931369323693336934369353693636937369383693936940369413694236943369443694536946369473694836949369503695136952369533695436955369563695736958369593696036961369623696336964369653696636967369683696936970369713697236973369743697536976369773697836979369803698136982369833698436985369863698736988369893699036991369923699336994369953699636997369983699937000370013700237003370043700537006370073700837009370103701137012370133701437015370163701737018370193702037021370223702337024370253702637027370283702937030370313703237033370343703537036370373703837039370403704137042370433704437045370463704737048370493705037051370523705337054370553705637057370583705937060370613706237063370643706537066370673706837069370703707137072370733707437075370763707737078370793708037081370823708337084370853708637087370883708937090370913709237093370943709537096370973709837099371003710137102371033710437105371063710737108371093711037111371123711337114371153711637117371183711937120371213712237123371243712537126371273712837129371303713137132371333713437135371363713737138371393714037141371423714337144371453714637147371483714937150371513715237153371543715537156371573715837159371603716137162371633716437165371663716737168371693717037171371723717337174371753717637177371783717937180371813718237183371843718537186371873718837189371903719137192371933719437195371963719737198371993720037201372023720337204372053720637207372083720937210372113721237213372143721537216372173721837219372203722137222372233722437225372263722737228372293723037231372323723337234372353723637237372383723937240372413724237243372443724537246372473724837249372503725137252372533725437255372563725737258372593726037261372623726337264372653726637267372683726937270372713727237273372743727537276372773727837279372803728137282372833728437285372863728737288372893729037291372923729337294372953729637297372983729937300373013730237303373043730537306373073730837309373103731137312373133731437315373163731737318373193732037321373223732337324373253732637327373283732937330373313733237333373343733537336373373733837339373403734137342373433734437345373463734737348373493735037351373523735337354373553735637357373583735937360373613736237363373643736537366373673736837369373703737137372373733737437375373763737737378373793738037381373823738337384373853738637387373883738937390373913739237393373943739537396373973739837399374003740137402374033740437405374063740737408374093741037411374123741337414374153741637417374183741937420374213742237423374243742537426374273742837429374303743137432374333743437435374363743737438374393744037441374423744337444374453744637447374483744937450374513745237453374543745537456374573745837459374603746137462374633746437465374663746737468374693747037471374723747337474374753747637477374783747937480374813748237483374843748537486374873748837489374903749137492374933749437495374963749737498374993750037501375023750337504375053750637507375083750937510375113751237513375143751537516375173751837519375203752137522375233752437525375263752737528375293753037531375323753337534375353753637537375383753937540375413754237543375443754537546375473754837549375503755137552375533755437555375563755737558375593756037561375623756337564375653756637567375683756937570375713757237573375743757537576375773757837579375803758137582375833758437585375863758737588375893759037591375923759337594375953759637597375983759937600376013760237603376043760537606376073760837609376103761137612376133761437615376163761737618376193762037621376223762337624376253762637627376283762937630376313763237633376343763537636376373763837639376403764137642376433764437645376463764737648376493765037651376523765337654376553765637657376583765937660376613766237663376643766537666376673766837669376703767137672376733767437675376763767737678376793768037681376823768337684376853768637687376883768937690376913769237693376943769537696376973769837699377003770137702377033770437705377063770737708377093771037711377123771337714377153771637717377183771937720377213772237723377243772537726377273772837729377303773137732377333773437735377363773737738377393774037741377423774337744377453774637747377483774937750377513775237753377543775537756377573775837759377603776137762377633776437765377663776737768377693777037771377723777337774377753777637777377783777937780377813778237783377843778537786377873778837789377903779137792377933779437795377963779737798377993780037801378023780337804378053780637807378083780937810378113781237813378143781537816378173781837819378203782137822378233782437825378263782737828378293783037831378323783337834378353783637837378383783937840378413784237843378443784537846378473784837849378503785137852378533785437855378563785737858378593786037861378623786337864378653786637867378683786937870378713787237873378743787537876378773787837879378803788137882378833788437885378863788737888378893789037891378923789337894378953789637897378983789937900379013790237903379043790537906379073790837909379103791137912379133791437915379163791737918379193792037921379223792337924379253792637927379283792937930379313793237933379343793537936379373793837939379403794137942379433794437945379463794737948379493795037951379523795337954379553795637957379583795937960379613796237963379643796537966379673796837969379703797137972379733797437975379763797737978379793798037981379823798337984379853798637987379883798937990379913799237993379943799537996379973799837999380003800138002380033800438005380063800738008380093801038011380123801338014380153801638017380183801938020380213802238023380243802538026380273802838029380303803138032380333803438035380363803738038380393804038041380423804338044380453804638047380483804938050380513805238053380543805538056380573805838059380603806138062380633806438065380663806738068380693807038071380723807338074380753807638077380783807938080380813808238083380843808538086380873808838089380903809138092380933809438095380963809738098380993810038101381023810338104381053810638107381083810938110381113811238113381143811538116381173811838119381203812138122381233812438125381263812738128381293813038131381323813338134381353813638137381383813938140381413814238143381443814538146381473814838149381503815138152381533815438155381563815738158381593816038161381623816338164381653816638167381683816938170381713817238173381743817538176381773817838179381803818138182381833818438185381863818738188381893819038191381923819338194381953819638197381983819938200382013820238203382043820538206382073820838209382103821138212382133821438215382163821738218382193822038221382223822338224382253822638227382283822938230382313823238233382343823538236382373823838239382403824138242382433824438245382463824738248382493825038251382523825338254382553825638257382583825938260382613826238263382643826538266382673826838269382703827138272382733827438275382763827738278382793828038281382823828338284382853828638287382883828938290382913829238293382943829538296382973829838299383003830138302383033830438305383063830738308383093831038311383123831338314383153831638317383183831938320383213832238323383243832538326383273832838329383303833138332383333833438335383363833738338383393834038341383423834338344383453834638347383483834938350383513835238353383543835538356383573835838359383603836138362383633836438365383663836738368383693837038371383723837338374383753837638377383783837938380383813838238383383843838538386383873838838389383903839138392383933839438395383963839738398383993840038401384023840338404384053840638407384083840938410384113841238413384143841538416384173841838419384203842138422384233842438425384263842738428384293843038431384323843338434384353843638437384383843938440384413844238443384443844538446384473844838449384503845138452384533845438455384563845738458384593846038461384623846338464384653846638467384683846938470384713847238473384743847538476384773847838479384803848138482384833848438485384863848738488384893849038491384923849338494384953849638497384983849938500385013850238503385043850538506385073850838509385103851138512385133851438515385163851738518385193852038521385223852338524385253852638527385283852938530385313853238533385343853538536385373853838539385403854138542385433854438545385463854738548385493855038551385523855338554385553855638557385583855938560385613856238563385643856538566385673856838569385703857138572385733857438575385763857738578385793858038581385823858338584385853858638587385883858938590385913859238593385943859538596385973859838599386003860138602386033860438605386063860738608386093861038611386123861338614386153861638617386183861938620386213862238623386243862538626386273862838629386303863138632386333863438635386363863738638386393864038641386423864338644386453864638647386483864938650386513865238653386543865538656386573865838659386603866138662386633866438665386663866738668386693867038671386723867338674386753867638677386783867938680386813868238683386843868538686386873868838689386903869138692386933869438695386963869738698386993870038701387023870338704387053870638707387083870938710387113871238713387143871538716387173871838719387203872138722387233872438725387263872738728387293873038731387323873338734387353873638737387383873938740387413874238743387443874538746387473874838749387503875138752387533875438755387563875738758387593876038761387623876338764387653876638767387683876938770387713877238773387743877538776387773877838779387803878138782387833878438785387863878738788387893879038791387923879338794387953879638797387983879938800388013880238803388043880538806388073880838809388103881138812388133881438815388163881738818388193882038821388223882338824388253882638827388283882938830388313883238833388343883538836388373883838839388403884138842388433884438845388463884738848388493885038851388523885338854388553885638857388583885938860388613886238863388643886538866388673886838869388703887138872388733887438875388763887738878388793888038881388823888338884388853888638887388883888938890388913889238893388943889538896388973889838899389003890138902389033890438905389063890738908389093891038911389123891338914389153891638917389183891938920389213892238923389243892538926389273892838929389303893138932389333893438935389363893738938389393894038941389423894338944389453894638947389483894938950389513895238953389543895538956389573895838959389603896138962389633896438965389663896738968389693897038971389723897338974389753897638977389783897938980389813898238983389843898538986389873898838989389903899138992389933899438995389963899738998389993900039001390023900339004390053900639007390083900939010390113901239013390143901539016390173901839019390203902139022390233902439025390263902739028390293903039031390323903339034390353903639037390383903939040390413904239043390443904539046390473904839049390503905139052390533905439055390563905739058390593906039061390623906339064390653906639067390683906939070390713907239073390743907539076390773907839079390803908139082390833908439085390863908739088390893909039091390923909339094390953909639097390983909939100391013910239103391043910539106391073910839109391103911139112391133911439115391163911739118391193912039121391223912339124391253912639127391283912939130391313913239133391343913539136391373913839139391403914139142391433914439145391463914739148391493915039151391523915339154391553915639157391583915939160391613916239163391643916539166391673916839169391703917139172391733917439175391763917739178391793918039181391823918339184391853918639187391883918939190391913919239193391943919539196391973919839199392003920139202392033920439205392063920739208392093921039211392123921339214392153921639217392183921939220392213922239223392243922539226392273922839229392303923139232392333923439235392363923739238392393924039241392423924339244392453924639247392483924939250392513925239253392543925539256392573925839259392603926139262392633926439265392663926739268392693927039271392723927339274392753927639277392783927939280392813928239283392843928539286392873928839289392903929139292392933929439295392963929739298392993930039301393023930339304393053930639307393083930939310393113931239313393143931539316393173931839319393203932139322393233932439325393263932739328393293933039331393323933339334393353933639337393383933939340393413934239343393443934539346393473934839349393503935139352393533935439355393563935739358393593936039361393623936339364393653936639367393683936939370393713937239373393743937539376393773937839379393803938139382393833938439385393863938739388393893939039391393923939339394393953939639397393983939939400394013940239403394043940539406394073940839409394103941139412394133941439415394163941739418394193942039421394223942339424394253942639427394283942939430394313943239433394343943539436394373943839439394403944139442394433944439445394463944739448394493945039451394523945339454394553945639457394583945939460394613946239463394643946539466394673946839469394703947139472394733947439475394763947739478394793948039481394823948339484394853948639487394883948939490394913949239493394943949539496394973949839499395003950139502395033950439505395063950739508395093951039511395123951339514395153951639517395183951939520395213952239523395243952539526395273952839529395303953139532395333953439535395363953739538395393954039541395423954339544395453954639547395483954939550395513955239553395543955539556395573955839559395603956139562395633956439565395663956739568395693957039571395723957339574395753957639577395783957939580395813958239583395843958539586395873958839589395903959139592395933959439595395963959739598395993960039601396023960339604396053960639607396083960939610396113961239613396143961539616396173961839619396203962139622396233962439625396263962739628396293963039631396323963339634396353963639637396383963939640396413964239643396443964539646396473964839649396503965139652396533965439655396563965739658396593966039661396623966339664396653966639667396683966939670396713967239673396743967539676396773967839679396803968139682396833968439685396863968739688396893969039691396923969339694396953969639697396983969939700397013970239703397043970539706397073970839709397103971139712397133971439715397163971739718397193972039721397223972339724397253972639727397283972939730397313973239733397343973539736397373973839739397403974139742397433974439745397463974739748397493975039751397523975339754397553975639757397583975939760397613976239763397643976539766397673976839769397703977139772397733977439775397763977739778397793978039781397823978339784397853978639787397883978939790397913979239793397943979539796397973979839799398003980139802398033980439805398063980739808398093981039811398123981339814398153981639817398183981939820398213982239823398243982539826398273982839829398303983139832398333983439835398363983739838398393984039841398423984339844398453984639847398483984939850398513985239853398543985539856398573985839859398603986139862398633986439865398663986739868398693987039871398723987339874398753987639877398783987939880398813988239883398843988539886398873988839889398903989139892398933989439895398963989739898398993990039901399023990339904399053990639907399083990939910399113991239913399143991539916399173991839919399203992139922399233992439925399263992739928399293993039931399323993339934399353993639937399383993939940399413994239943399443994539946399473994839949399503995139952399533995439955399563995739958399593996039961399623996339964399653996639967399683996939970399713997239973399743997539976399773997839979399803998139982399833998439985399863998739988399893999039991399923999339994399953999639997399983999940000400014000240003400044000540006400074000840009400104001140012400134001440015400164001740018400194002040021400224002340024400254002640027400284002940030400314003240033400344003540036400374003840039400404004140042400434004440045400464004740048400494005040051400524005340054400554005640057400584005940060400614006240063400644006540066400674006840069400704007140072400734007440075400764007740078400794008040081400824008340084400854008640087400884008940090400914009240093400944009540096400974009840099401004010140102401034010440105401064010740108401094011040111401124011340114401154011640117401184011940120401214012240123401244012540126401274012840129401304013140132401334013440135401364013740138401394014040141401424014340144401454014640147401484014940150401514015240153401544015540156401574015840159401604016140162401634016440165401664016740168401694017040171401724017340174401754017640177401784017940180401814018240183401844018540186401874018840189401904019140192401934019440195401964019740198401994020040201402024020340204402054020640207402084020940210402114021240213402144021540216402174021840219402204022140222402234022440225402264022740228402294023040231402324023340234402354023640237402384023940240402414024240243402444024540246402474024840249402504025140252402534025440255402564025740258402594026040261402624026340264402654026640267402684026940270402714027240273402744027540276402774027840279402804028140282402834028440285402864028740288402894029040291402924029340294402954029640297402984029940300403014030240303403044030540306403074030840309403104031140312403134031440315403164031740318403194032040321403224032340324403254032640327403284032940330403314033240333403344033540336403374033840339403404034140342403434034440345403464034740348403494035040351403524035340354403554035640357403584035940360403614036240363403644036540366403674036840369403704037140372403734037440375403764037740378403794038040381403824038340384403854038640387403884038940390403914039240393403944039540396403974039840399404004040140402404034040440405404064040740408404094041040411404124041340414404154041640417404184041940420404214042240423404244042540426404274042840429404304043140432404334043440435404364043740438404394044040441404424044340444404454044640447404484044940450404514045240453404544045540456404574045840459404604046140462404634046440465404664046740468404694047040471404724047340474404754047640477404784047940480404814048240483404844048540486404874048840489404904049140492404934049440495404964049740498404994050040501405024050340504405054050640507405084050940510405114051240513405144051540516405174051840519405204052140522405234052440525405264052740528405294053040531405324053340534405354053640537405384053940540405414054240543405444054540546405474054840549405504055140552405534055440555405564055740558405594056040561405624056340564405654056640567405684056940570405714057240573405744057540576405774057840579405804058140582405834058440585405864058740588405894059040591405924059340594405954059640597405984059940600406014060240603406044060540606406074060840609406104061140612406134061440615406164061740618406194062040621406224062340624406254062640627406284062940630406314063240633406344063540636406374063840639406404064140642406434064440645406464064740648406494065040651406524065340654406554065640657406584065940660406614066240663406644066540666406674066840669406704067140672406734067440675406764067740678406794068040681406824068340684406854068640687406884068940690406914069240693406944069540696406974069840699407004070140702407034070440705407064070740708407094071040711407124071340714407154071640717407184071940720407214072240723407244072540726407274072840729407304073140732407334073440735407364073740738407394074040741407424074340744407454074640747407484074940750407514075240753407544075540756407574075840759407604076140762407634076440765407664076740768407694077040771407724077340774407754077640777407784077940780407814078240783407844078540786407874078840789407904079140792407934079440795407964079740798407994080040801408024080340804408054080640807408084080940810408114081240813408144081540816408174081840819408204082140822408234082440825408264082740828408294083040831408324083340834408354083640837408384083940840408414084240843408444084540846408474084840849408504085140852408534085440855408564085740858408594086040861408624086340864408654086640867408684086940870408714087240873408744087540876408774087840879408804088140882408834088440885408864088740888408894089040891408924089340894408954089640897408984089940900409014090240903409044090540906409074090840909409104091140912409134091440915409164091740918409194092040921409224092340924409254092640927409284092940930409314093240933409344093540936409374093840939409404094140942409434094440945409464094740948409494095040951409524095340954409554095640957409584095940960409614096240963409644096540966409674096840969409704097140972409734097440975409764097740978409794098040981409824098340984409854098640987409884098940990409914099240993409944099540996409974099840999410004100141002410034100441005410064100741008410094101041011410124101341014410154101641017410184101941020410214102241023410244102541026410274102841029410304103141032410334103441035410364103741038410394104041041410424104341044410454104641047410484104941050410514105241053410544105541056410574105841059410604106141062410634106441065410664106741068410694107041071410724107341074410754107641077410784107941080410814108241083410844108541086410874108841089410904109141092410934109441095410964109741098410994110041101411024110341104411054110641107411084110941110411114111241113411144111541116411174111841119411204112141122411234112441125411264112741128411294113041131411324113341134411354113641137411384113941140411414114241143411444114541146411474114841149411504115141152411534115441155411564115741158411594116041161411624116341164411654116641167411684116941170411714117241173411744117541176411774117841179411804118141182411834118441185411864118741188411894119041191411924119341194411954119641197411984119941200412014120241203412044120541206412074120841209412104121141212412134121441215412164121741218412194122041221412224122341224412254122641227412284122941230412314123241233412344123541236412374123841239412404124141242412434124441245412464124741248412494125041251412524125341254412554125641257412584125941260412614126241263412644126541266412674126841269412704127141272412734127441275412764127741278412794128041281412824128341284412854128641287412884128941290412914129241293412944129541296412974129841299413004130141302413034130441305413064130741308413094131041311413124131341314413154131641317413184131941320413214132241323413244132541326413274132841329413304133141332413334133441335413364133741338413394134041341413424134341344413454134641347413484134941350413514135241353413544135541356413574135841359413604136141362413634136441365413664136741368413694137041371413724137341374413754137641377413784137941380413814138241383413844138541386413874138841389413904139141392413934139441395413964139741398413994140041401414024140341404414054140641407414084140941410414114141241413414144141541416414174141841419414204142141422414234142441425414264142741428414294143041431414324143341434414354143641437414384143941440414414144241443414444144541446414474144841449414504145141452414534145441455414564145741458414594146041461414624146341464414654146641467414684146941470414714147241473414744147541476414774147841479414804148141482414834148441485414864148741488414894149041491414924149341494414954149641497414984149941500415014150241503415044150541506415074150841509415104151141512415134151441515415164151741518415194152041521415224152341524415254152641527415284152941530415314153241533415344153541536415374153841539415404154141542415434154441545415464154741548415494155041551415524155341554415554155641557415584155941560415614156241563415644156541566415674156841569415704157141572415734157441575415764157741578415794158041581415824158341584415854158641587415884158941590415914159241593415944159541596415974159841599416004160141602416034160441605416064160741608416094161041611416124161341614416154161641617416184161941620416214162241623416244162541626416274162841629416304163141632416334163441635416364163741638416394164041641416424164341644416454164641647416484164941650416514165241653416544165541656416574165841659416604166141662416634166441665416664166741668416694167041671416724167341674416754167641677416784167941680416814168241683416844168541686416874168841689416904169141692416934169441695416964169741698416994170041701417024170341704417054170641707417084170941710417114171241713417144171541716417174171841719417204172141722417234172441725417264172741728417294173041731417324173341734417354173641737417384173941740417414174241743417444174541746417474174841749417504175141752417534175441755417564175741758417594176041761417624176341764417654176641767417684176941770417714177241773417744177541776417774177841779417804178141782417834178441785417864178741788417894179041791417924179341794417954179641797417984179941800418014180241803418044180541806418074180841809418104181141812418134181441815418164181741818418194182041821418224182341824418254182641827418284182941830418314183241833418344183541836418374183841839418404184141842418434184441845418464184741848418494185041851418524185341854418554185641857418584185941860418614186241863418644186541866418674186841869418704187141872418734187441875418764187741878418794188041881418824188341884418854188641887418884188941890418914189241893418944189541896418974189841899419004190141902419034190441905419064190741908419094191041911419124191341914419154191641917419184191941920419214192241923419244192541926419274192841929419304193141932419334193441935419364193741938419394194041941419424194341944419454194641947419484194941950419514195241953419544195541956419574195841959419604196141962419634196441965419664196741968419694197041971419724197341974419754197641977419784197941980419814198241983419844198541986419874198841989419904199141992419934199441995419964199741998419994200042001420024200342004420054200642007420084200942010420114201242013420144201542016420174201842019420204202142022420234202442025420264202742028420294203042031420324203342034420354203642037420384203942040420414204242043420444204542046420474204842049420504205142052420534205442055420564205742058420594206042061420624206342064420654206642067420684206942070420714207242073420744207542076420774207842079420804208142082420834208442085420864208742088420894209042091420924209342094420954209642097420984209942100421014210242103421044210542106421074210842109421104211142112421134211442115421164211742118421194212042121421224212342124421254212642127421284212942130421314213242133421344213542136421374213842139421404214142142421434214442145421464214742148421494215042151421524215342154421554215642157421584215942160421614216242163421644216542166421674216842169421704217142172421734217442175421764217742178421794218042181421824218342184421854218642187421884218942190421914219242193421944219542196421974219842199422004220142202422034220442205422064220742208422094221042211422124221342214422154221642217422184221942220422214222242223422244222542226422274222842229422304223142232422334223442235422364223742238422394224042241422424224342244422454224642247422484224942250422514225242253422544225542256422574225842259422604226142262422634226442265422664226742268422694227042271422724227342274422754227642277422784227942280422814228242283422844228542286422874228842289422904229142292422934229442295422964229742298422994230042301423024230342304423054230642307423084230942310423114231242313423144231542316423174231842319423204232142322423234232442325423264232742328423294233042331423324233342334423354233642337423384233942340423414234242343423444234542346423474234842349423504235142352423534235442355423564235742358423594236042361423624236342364423654236642367423684236942370423714237242373423744237542376423774237842379423804238142382423834238442385423864238742388423894239042391423924239342394423954239642397423984239942400424014240242403424044240542406424074240842409424104241142412424134241442415424164241742418424194242042421424224242342424424254242642427424284242942430424314243242433424344243542436424374243842439424404244142442424434244442445424464244742448424494245042451424524245342454424554245642457424584245942460424614246242463424644246542466424674246842469424704247142472424734247442475424764247742478424794248042481424824248342484424854248642487424884248942490424914249242493424944249542496424974249842499425004250142502425034250442505425064250742508425094251042511425124251342514425154251642517425184251942520425214252242523425244252542526425274252842529425304253142532425334253442535425364253742538425394254042541425424254342544425454254642547425484254942550425514255242553425544255542556425574255842559425604256142562425634256442565425664256742568425694257042571425724257342574425754257642577425784257942580425814258242583425844258542586425874258842589425904259142592425934259442595425964259742598425994260042601426024260342604426054260642607426084260942610426114261242613426144261542616426174261842619426204262142622426234262442625426264262742628426294263042631426324263342634426354263642637426384263942640426414264242643426444264542646426474264842649426504265142652426534265442655426564265742658426594266042661426624266342664426654266642667426684266942670426714267242673426744267542676426774267842679426804268142682426834268442685426864268742688426894269042691426924269342694426954269642697426984269942700427014270242703427044270542706427074270842709427104271142712427134271442715427164271742718427194272042721427224272342724427254272642727427284272942730427314273242733427344273542736427374273842739427404274142742427434274442745427464274742748427494275042751427524275342754427554275642757427584275942760427614276242763427644276542766427674276842769427704277142772427734277442775427764277742778427794278042781427824278342784427854278642787427884278942790427914279242793427944279542796427974279842799428004280142802428034280442805428064280742808428094281042811428124281342814428154281642817428184281942820428214282242823428244282542826428274282842829428304283142832428334283442835428364283742838428394284042841428424284342844428454284642847428484284942850428514285242853428544285542856428574285842859428604286142862428634286442865428664286742868428694287042871428724287342874428754287642877428784287942880428814288242883428844288542886428874288842889428904289142892428934289442895428964289742898428994290042901429024290342904429054290642907429084290942910429114291242913429144291542916429174291842919429204292142922429234292442925429264292742928429294293042931429324293342934429354293642937429384293942940429414294242943429444294542946429474294842949429504295142952429534295442955429564295742958429594296042961429624296342964429654296642967429684296942970429714297242973429744297542976429774297842979429804298142982429834298442985429864298742988429894299042991429924299342994429954299642997429984299943000430014300243003430044300543006430074300843009430104301143012430134301443015430164301743018430194302043021430224302343024430254302643027430284302943030430314303243033430344303543036430374303843039430404304143042430434304443045430464304743048430494305043051430524305343054430554305643057430584305943060430614306243063430644306543066430674306843069430704307143072430734307443075430764307743078430794308043081430824308343084430854308643087430884308943090430914309243093430944309543096430974309843099431004310143102431034310443105431064310743108431094311043111431124311343114431154311643117431184311943120431214312243123431244312543126431274312843129431304313143132431334313443135431364313743138431394314043141431424314343144431454314643147431484314943150431514315243153431544315543156431574315843159431604316143162431634316443165431664316743168431694317043171431724317343174431754317643177431784317943180431814318243183431844318543186431874318843189431904319143192431934319443195431964319743198431994320043201432024320343204432054320643207432084320943210432114321243213432144321543216432174321843219432204322143222432234322443225432264322743228432294323043231432324323343234432354323643237432384323943240432414324243243432444324543246432474324843249432504325143252432534325443255432564325743258432594326043261432624326343264432654326643267432684326943270432714327243273432744327543276432774327843279432804328143282432834328443285432864328743288432894329043291432924329343294432954329643297432984329943300433014330243303433044330543306433074330843309433104331143312433134331443315433164331743318433194332043321433224332343324433254332643327433284332943330433314333243333433344333543336433374333843339433404334143342433434334443345433464334743348433494335043351433524335343354433554335643357433584335943360433614336243363433644336543366433674336843369433704337143372433734337443375433764337743378433794338043381433824338343384433854338643387433884338943390433914339243393433944339543396433974339843399434004340143402434034340443405434064340743408434094341043411434124341343414434154341643417434184341943420434214342243423434244342543426434274342843429434304343143432434334343443435434364343743438434394344043441434424344343444434454344643447434484344943450434514345243453434544345543456434574345843459434604346143462434634346443465434664346743468434694347043471434724347343474434754347643477434784347943480434814348243483434844348543486434874348843489434904349143492434934349443495434964349743498434994350043501435024350343504435054350643507435084350943510435114351243513435144351543516435174351843519435204352143522435234352443525435264352743528435294353043531435324353343534435354353643537435384353943540435414354243543435444354543546435474354843549435504355143552435534355443555435564355743558435594356043561435624356343564435654356643567435684356943570435714357243573435744357543576435774357843579435804358143582435834358443585435864358743588435894359043591435924359343594435954359643597435984359943600436014360243603436044360543606436074360843609436104361143612436134361443615436164361743618436194362043621436224362343624436254362643627436284362943630436314363243633436344363543636436374363843639436404364143642436434364443645436464364743648436494365043651436524365343654436554365643657436584365943660436614366243663436644366543666436674366843669436704367143672436734367443675436764367743678436794368043681436824368343684436854368643687436884368943690436914369243693436944369543696436974369843699437004370143702437034370443705437064370743708437094371043711437124371343714437154371643717437184371943720437214372243723437244372543726437274372843729437304373143732437334373443735437364373743738437394374043741437424374343744437454374643747437484374943750437514375243753437544375543756437574375843759437604376143762437634376443765437664376743768437694377043771437724377343774437754377643777437784377943780437814378243783437844378543786437874378843789437904379143792437934379443795437964379743798437994380043801438024380343804438054380643807438084380943810438114381243813438144381543816438174381843819438204382143822438234382443825438264382743828438294383043831438324383343834438354383643837438384383943840438414384243843438444384543846438474384843849438504385143852438534385443855438564385743858438594386043861438624386343864438654386643867438684386943870438714387243873438744387543876
  1. var Module;
  2. if (typeof Module === 'undefined') Module = {};
  3. if (!Module.expectedDataFileDownloads) {
  4. Module.expectedDataFileDownloads = 0;
  5. Module.finishedDataFileDownloads = 0;
  6. }
  7. Module.expectedDataFileDownloads++;
  8. (function() {
  9. var loadPackage = function(metadata) {
  10. var PACKAGE_PATH;
  11. if (typeof window === 'object') {
  12. PACKAGE_PATH = window['encodeURIComponent'](window.location.pathname.toString().substring(0, window.location.pathname.toString().lastIndexOf('/')) + '/');
  13. } else if (typeof location !== 'undefined') {
  14. // worker
  15. PACKAGE_PATH = encodeURIComponent(location.pathname.toString().substring(0, location.pathname.toString().lastIndexOf('/')) + '/');
  16. } else {
  17. throw 'using preloaded data can only be done on a web page or in a web worker';
  18. }
  19. var PACKAGE_NAME = 'textures/textures_image_drawing.data';
  20. var REMOTE_PACKAGE_BASE = 'textures_image_drawing.data';
  21. if (typeof Module['locateFilePackage'] === 'function' && !Module['locateFile']) {
  22. Module['locateFile'] = Module['locateFilePackage'];
  23. Module.printErr('warning: you defined Module.locateFilePackage, that has been renamed to Module.locateFile (using your locateFilePackage for now)');
  24. }
  25. var REMOTE_PACKAGE_NAME = typeof Module['locateFile'] === 'function' ?
  26. Module['locateFile'](REMOTE_PACKAGE_BASE) :
  27. ((Module['filePackagePrefixURL'] || '') + REMOTE_PACKAGE_BASE);
  28. var REMOTE_PACKAGE_SIZE = metadata.remote_package_size;
  29. var PACKAGE_UUID = metadata.package_uuid;
  30. function fetchRemotePackage(packageName, packageSize, callback, errback) {
  31. var xhr = new XMLHttpRequest();
  32. xhr.open('GET', packageName, true);
  33. xhr.responseType = 'arraybuffer';
  34. xhr.onprogress = function(event) {
  35. var url = packageName;
  36. var size = packageSize;
  37. if (event.total) size = event.total;
  38. if (event.loaded) {
  39. if (!xhr.addedTotal) {
  40. xhr.addedTotal = true;
  41. if (!Module.dataFileDownloads) Module.dataFileDownloads = {};
  42. Module.dataFileDownloads[url] = {
  43. loaded: event.loaded,
  44. total: size
  45. };
  46. } else {
  47. Module.dataFileDownloads[url].loaded = event.loaded;
  48. }
  49. var total = 0;
  50. var loaded = 0;
  51. var num = 0;
  52. for (var download in Module.dataFileDownloads) {
  53. var data = Module.dataFileDownloads[download];
  54. total += data.total;
  55. loaded += data.loaded;
  56. num++;
  57. }
  58. total = Math.ceil(total * Module.expectedDataFileDownloads/num);
  59. if (Module['setStatus']) Module['setStatus']('Downloading data... (' + loaded + '/' + total + ')');
  60. } else if (!Module.dataFileDownloads) {
  61. if (Module['setStatus']) Module['setStatus']('Downloading data...');
  62. }
  63. };
  64. xhr.onerror = function(event) {
  65. throw new Error("NetworkError for: " + packageName);
  66. }
  67. xhr.onload = function(event) {
  68. if (xhr.status == 200 || xhr.status == 304 || xhr.status == 206 || (xhr.status == 0 && xhr.response)) { // file URLs can return 0
  69. var packageData = xhr.response;
  70. callback(packageData);
  71. } else {
  72. throw new Error(xhr.statusText + " : " + xhr.responseURL);
  73. }
  74. };
  75. xhr.send(null);
  76. };
  77. function handleError(error) {
  78. console.error('package error:', error);
  79. };
  80. var fetchedCallback = null;
  81. var fetched = Module['getPreloadedPackage'] ? Module['getPreloadedPackage'](REMOTE_PACKAGE_NAME, REMOTE_PACKAGE_SIZE) : null;
  82. if (!fetched) fetchRemotePackage(REMOTE_PACKAGE_NAME, REMOTE_PACKAGE_SIZE, function(data) {
  83. if (fetchedCallback) {
  84. fetchedCallback(data);
  85. fetchedCallback = null;
  86. } else {
  87. fetched = data;
  88. }
  89. }, handleError);
  90. function runWithFS() {
  91. function assert(check, msg) {
  92. if (!check) throw msg + new Error().stack;
  93. }
  94. Module['FS_createPath']('/', 'resources', true, true);
  95. function DataRequest(start, end, crunched, audio) {
  96. this.start = start;
  97. this.end = end;
  98. this.crunched = crunched;
  99. this.audio = audio;
  100. }
  101. DataRequest.prototype = {
  102. requests: {},
  103. open: function(mode, name) {
  104. this.name = name;
  105. this.requests[name] = this;
  106. Module['addRunDependency']('fp ' + this.name);
  107. },
  108. send: function() {},
  109. onload: function() {
  110. var byteArray = this.byteArray.subarray(this.start, this.end);
  111. this.finish(byteArray);
  112. },
  113. finish: function(byteArray) {
  114. var that = this;
  115. Module['FS_createDataFile'](this.name, null, byteArray, true, true, true); // canOwn this data in the filesystem, it is a slide into the heap that will never change
  116. Module['removeRunDependency']('fp ' + that.name);
  117. this.requests[this.name] = null;
  118. }
  119. };
  120. var files = metadata.files;
  121. for (i = 0; i < files.length; ++i) {
  122. new DataRequest(files[i].start, files[i].end, files[i].crunched, files[i].audio).open('GET', files[i].filename);
  123. }
  124. function processPackageData(arrayBuffer) {
  125. Module.finishedDataFileDownloads++;
  126. assert(arrayBuffer, 'Loading data file failed.');
  127. assert(arrayBuffer instanceof ArrayBuffer, 'bad input to processPackageData');
  128. var byteArray = new Uint8Array(arrayBuffer);
  129. var curr;
  130. // copy the entire loaded file into a spot in the heap. Files will refer to slices in that. They cannot be freed though
  131. // (we may be allocating before malloc is ready, during startup).
  132. if (Module['SPLIT_MEMORY']) Module.printErr('warning: you should run the file packager with --no-heap-copy when SPLIT_MEMORY is used, otherwise copying into the heap may fail due to the splitting');
  133. var ptr = Module['getMemory'](byteArray.length);
  134. Module['HEAPU8'].set(byteArray, ptr);
  135. DataRequest.prototype.byteArray = Module['HEAPU8'].subarray(ptr, ptr+byteArray.length);
  136. var files = metadata.files;
  137. for (i = 0; i < files.length; ++i) {
  138. DataRequest.prototype.requests[files[i].filename].onload();
  139. }
  140. Module['removeRunDependency']('datafile_textures/textures_image_drawing.data');
  141. };
  142. Module['addRunDependency']('datafile_textures/textures_image_drawing.data');
  143. if (!Module.preloadResults) Module.preloadResults = {};
  144. Module.preloadResults[PACKAGE_NAME] = {fromCache: false};
  145. if (fetched) {
  146. processPackageData(fetched);
  147. fetched = null;
  148. } else {
  149. fetchedCallback = processPackageData;
  150. }
  151. }
  152. if (Module['calledRun']) {
  153. runWithFS();
  154. } else {
  155. if (!Module['preRun']) Module['preRun'] = [];
  156. Module["preRun"].push(runWithFS); // FS is not initialized yet, wait for it
  157. }
  158. }
  159. loadPackage({"files": [{"audio": 0, "start": 0, "crunched": 0, "end": 295054, "filename": "/resources/parrots.png"}, {"audio": 0, "start": 295054, "crunched": 0, "end": 683586, "filename": "/resources/cat.png"}], "remote_package_size": 683586, "package_uuid": "d150a03e-5a56-4cec-8b52-e648777bc2ce"});
  160. })();
  161. // The Module object: Our interface to the outside world. We import
  162. // and export values on it, and do the work to get that through
  163. // closure compiler if necessary. There are various ways Module can be used:
  164. // 1. Not defined. We create it here
  165. // 2. A function parameter, function(Module) { ..generated code.. }
  166. // 3. pre-run appended it, var Module = {}; ..generated code..
  167. // 4. External script tag defines var Module.
  168. // We need to do an eval in order to handle the closure compiler
  169. // case, where this code here is minified but Module was defined
  170. // elsewhere (e.g. case 4 above). We also need to check if Module
  171. // already exists (e.g. case 3 above).
  172. // Note that if you want to run closure, and also to use Module
  173. // after the generated code, you will need to define var Module = {};
  174. // before the code. Then that object will be used in the code, and you
  175. // can continue to use Module afterwards as well.
  176. var Module;
  177. if (!Module) Module = (typeof Module !== 'undefined' ? Module : null) || {};
  178. // Sometimes an existing Module object exists with properties
  179. // meant to overwrite the default module functionality. Here
  180. // we collect those properties and reapply _after_ we configure
  181. // the current environment's defaults to avoid having to be so
  182. // defensive during initialization.
  183. var moduleOverrides = {};
  184. for (var key in Module) {
  185. if (Module.hasOwnProperty(key)) {
  186. moduleOverrides[key] = Module[key];
  187. }
  188. }
  189. // The environment setup code below is customized to use Module.
  190. // *** Environment setup code ***
  191. var ENVIRONMENT_IS_WEB = false;
  192. var ENVIRONMENT_IS_WORKER = false;
  193. var ENVIRONMENT_IS_NODE = false;
  194. var ENVIRONMENT_IS_SHELL = false;
  195. // Three configurations we can be running in:
  196. // 1) We could be the application main() thread running in the main JS UI thread. (ENVIRONMENT_IS_WORKER == false and ENVIRONMENT_IS_PTHREAD == false)
  197. // 2) We could be the application main() thread proxied to worker. (with Emscripten -s PROXY_TO_WORKER=1) (ENVIRONMENT_IS_WORKER == true, ENVIRONMENT_IS_PTHREAD == false)
  198. // 3) We could be an application pthread running in a worker. (ENVIRONMENT_IS_WORKER == true and ENVIRONMENT_IS_PTHREAD == true)
  199. if (Module['ENVIRONMENT']) {
  200. if (Module['ENVIRONMENT'] === 'WEB') {
  201. ENVIRONMENT_IS_WEB = true;
  202. } else if (Module['ENVIRONMENT'] === 'WORKER') {
  203. ENVIRONMENT_IS_WORKER = true;
  204. } else if (Module['ENVIRONMENT'] === 'NODE') {
  205. ENVIRONMENT_IS_NODE = true;
  206. } else if (Module['ENVIRONMENT'] === 'SHELL') {
  207. ENVIRONMENT_IS_SHELL = true;
  208. } else {
  209. throw new Error('The provided Module[\'ENVIRONMENT\'] value is not valid. It must be one of: WEB|WORKER|NODE|SHELL.');
  210. }
  211. } else {
  212. ENVIRONMENT_IS_WEB = typeof window === 'object';
  213. ENVIRONMENT_IS_WORKER = typeof importScripts === 'function';
  214. ENVIRONMENT_IS_NODE = typeof process === 'object' && typeof require === 'function' && !ENVIRONMENT_IS_WEB && !ENVIRONMENT_IS_WORKER;
  215. ENVIRONMENT_IS_SHELL = !ENVIRONMENT_IS_WEB && !ENVIRONMENT_IS_NODE && !ENVIRONMENT_IS_WORKER;
  216. }
  217. if (ENVIRONMENT_IS_NODE) {
  218. // Expose functionality in the same simple way that the shells work
  219. // Note that we pollute the global namespace here, otherwise we break in node
  220. if (!Module['print']) Module['print'] = console.log;
  221. if (!Module['printErr']) Module['printErr'] = console.warn;
  222. var nodeFS;
  223. var nodePath;
  224. Module['read'] = function read(filename, binary) {
  225. if (!nodeFS) nodeFS = require('fs');
  226. if (!nodePath) nodePath = require('path');
  227. filename = nodePath['normalize'](filename);
  228. var ret = nodeFS['readFileSync'](filename);
  229. return binary ? ret : ret.toString();
  230. };
  231. Module['readBinary'] = function readBinary(filename) {
  232. var ret = Module['read'](filename, true);
  233. if (!ret.buffer) {
  234. ret = new Uint8Array(ret);
  235. }
  236. assert(ret.buffer);
  237. return ret;
  238. };
  239. Module['load'] = function load(f) {
  240. globalEval(read(f));
  241. };
  242. if (!Module['thisProgram']) {
  243. if (process['argv'].length > 1) {
  244. Module['thisProgram'] = process['argv'][1].replace(/\\/g, '/');
  245. } else {
  246. Module['thisProgram'] = 'unknown-program';
  247. }
  248. }
  249. Module['arguments'] = process['argv'].slice(2);
  250. if (typeof module !== 'undefined') {
  251. module['exports'] = Module;
  252. }
  253. process['on']('uncaughtException', function(ex) {
  254. // suppress ExitStatus exceptions from showing an error
  255. if (!(ex instanceof ExitStatus)) {
  256. throw ex;
  257. }
  258. });
  259. Module['inspect'] = function () { return '[Emscripten Module object]'; };
  260. }
  261. else if (ENVIRONMENT_IS_SHELL) {
  262. if (!Module['print']) Module['print'] = print;
  263. if (typeof printErr != 'undefined') Module['printErr'] = printErr; // not present in v8 or older sm
  264. if (typeof read != 'undefined') {
  265. Module['read'] = read;
  266. } else {
  267. Module['read'] = function read() { throw 'no read() available' };
  268. }
  269. Module['readBinary'] = function readBinary(f) {
  270. if (typeof readbuffer === 'function') {
  271. return new Uint8Array(readbuffer(f));
  272. }
  273. var data = read(f, 'binary');
  274. assert(typeof data === 'object');
  275. return data;
  276. };
  277. if (typeof scriptArgs != 'undefined') {
  278. Module['arguments'] = scriptArgs;
  279. } else if (typeof arguments != 'undefined') {
  280. Module['arguments'] = arguments;
  281. }
  282. if (typeof quit === 'function') {
  283. Module['quit'] = function(status, toThrow) {
  284. quit(status);
  285. }
  286. }
  287. }
  288. else if (ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER) {
  289. Module['read'] = function read(url) {
  290. var xhr = new XMLHttpRequest();
  291. xhr.open('GET', url, false);
  292. xhr.send(null);
  293. return xhr.responseText;
  294. };
  295. if (ENVIRONMENT_IS_WORKER) {
  296. Module['readBinary'] = function read(url) {
  297. var xhr = new XMLHttpRequest();
  298. xhr.open('GET', url, false);
  299. xhr.responseType = 'arraybuffer';
  300. xhr.send(null);
  301. return xhr.response;
  302. };
  303. }
  304. Module['readAsync'] = function readAsync(url, onload, onerror) {
  305. var xhr = new XMLHttpRequest();
  306. xhr.open('GET', url, true);
  307. xhr.responseType = 'arraybuffer';
  308. xhr.onload = function xhr_onload() {
  309. if (xhr.status == 200 || (xhr.status == 0 && xhr.response)) { // file URLs can return 0
  310. onload(xhr.response);
  311. } else {
  312. onerror();
  313. }
  314. };
  315. xhr.onerror = onerror;
  316. xhr.send(null);
  317. };
  318. if (typeof arguments != 'undefined') {
  319. Module['arguments'] = arguments;
  320. }
  321. if (typeof console !== 'undefined') {
  322. if (!Module['print']) Module['print'] = function print(x) {
  323. console.log(x);
  324. };
  325. if (!Module['printErr']) Module['printErr'] = function printErr(x) {
  326. console.warn(x);
  327. };
  328. } else {
  329. // Probably a worker, and without console.log. We can do very little here...
  330. var TRY_USE_DUMP = false;
  331. if (!Module['print']) Module['print'] = (TRY_USE_DUMP && (typeof(dump) !== "undefined") ? (function(x) {
  332. dump(x);
  333. }) : (function(x) {
  334. // self.postMessage(x); // enable this if you want stdout to be sent as messages
  335. }));
  336. }
  337. if (ENVIRONMENT_IS_WORKER) {
  338. Module['load'] = importScripts;
  339. }
  340. if (typeof Module['setWindowTitle'] === 'undefined') {
  341. Module['setWindowTitle'] = function(title) { document.title = title };
  342. }
  343. }
  344. else {
  345. // Unreachable because SHELL is dependant on the others
  346. throw 'Unknown runtime environment. Where are we?';
  347. }
  348. function globalEval(x) {
  349. eval.call(null, x);
  350. }
  351. if (!Module['load'] && Module['read']) {
  352. Module['load'] = function load(f) {
  353. globalEval(Module['read'](f));
  354. };
  355. }
  356. if (!Module['print']) {
  357. Module['print'] = function(){};
  358. }
  359. if (!Module['printErr']) {
  360. Module['printErr'] = Module['print'];
  361. }
  362. if (!Module['arguments']) {
  363. Module['arguments'] = [];
  364. }
  365. if (!Module['thisProgram']) {
  366. Module['thisProgram'] = './this.program';
  367. }
  368. if (!Module['quit']) {
  369. Module['quit'] = function(status, toThrow) {
  370. throw toThrow;
  371. }
  372. }
  373. // *** Environment setup code ***
  374. // Closure helpers
  375. Module.print = Module['print'];
  376. Module.printErr = Module['printErr'];
  377. // Callbacks
  378. Module['preRun'] = [];
  379. Module['postRun'] = [];
  380. // Merge back in the overrides
  381. for (var key in moduleOverrides) {
  382. if (moduleOverrides.hasOwnProperty(key)) {
  383. Module[key] = moduleOverrides[key];
  384. }
  385. }
  386. // Free the object hierarchy contained in the overrides, this lets the GC
  387. // reclaim data used e.g. in memoryInitializerRequest, which is a large typed array.
  388. moduleOverrides = undefined;
  389. // {{PREAMBLE_ADDITIONS}}
  390. // === Preamble library stuff ===
  391. // Documentation for the public APIs defined in this file must be updated in:
  392. // site/source/docs/api_reference/preamble.js.rst
  393. // A prebuilt local version of the documentation is available at:
  394. // site/build/text/docs/api_reference/preamble.js.txt
  395. // You can also build docs locally as HTML or other formats in site/
  396. // An online HTML version (which may be of a different version of Emscripten)
  397. // is up at http://kripken.github.io/emscripten-site/docs/api_reference/preamble.js.html
  398. //========================================
  399. // Runtime code shared with compiler
  400. //========================================
  401. var Runtime = {
  402. setTempRet0: function (value) {
  403. tempRet0 = value;
  404. return value;
  405. },
  406. getTempRet0: function () {
  407. return tempRet0;
  408. },
  409. stackSave: function () {
  410. return STACKTOP;
  411. },
  412. stackRestore: function (stackTop) {
  413. STACKTOP = stackTop;
  414. },
  415. getNativeTypeSize: function (type) {
  416. switch (type) {
  417. case 'i1': case 'i8': return 1;
  418. case 'i16': return 2;
  419. case 'i32': return 4;
  420. case 'i64': return 8;
  421. case 'float': return 4;
  422. case 'double': return 8;
  423. default: {
  424. if (type[type.length-1] === '*') {
  425. return Runtime.QUANTUM_SIZE; // A pointer
  426. } else if (type[0] === 'i') {
  427. var bits = parseInt(type.substr(1));
  428. assert(bits % 8 === 0);
  429. return bits/8;
  430. } else {
  431. return 0;
  432. }
  433. }
  434. }
  435. },
  436. getNativeFieldSize: function (type) {
  437. return Math.max(Runtime.getNativeTypeSize(type), Runtime.QUANTUM_SIZE);
  438. },
  439. STACK_ALIGN: 16,
  440. prepVararg: function (ptr, type) {
  441. if (type === 'double' || type === 'i64') {
  442. // move so the load is aligned
  443. if (ptr & 7) {
  444. assert((ptr & 7) === 4);
  445. ptr += 4;
  446. }
  447. } else {
  448. assert((ptr & 3) === 0);
  449. }
  450. return ptr;
  451. },
  452. getAlignSize: function (type, size, vararg) {
  453. // we align i64s and doubles on 64-bit boundaries, unlike x86
  454. if (!vararg && (type == 'i64' || type == 'double')) return 8;
  455. if (!type) return Math.min(size, 8); // align structures internally to 64 bits
  456. return Math.min(size || (type ? Runtime.getNativeFieldSize(type) : 0), Runtime.QUANTUM_SIZE);
  457. },
  458. dynCall: function (sig, ptr, args) {
  459. if (args && args.length) {
  460. assert(args.length == sig.length-1);
  461. assert(('dynCall_' + sig) in Module, 'bad function pointer type - no table for sig \'' + sig + '\'');
  462. return Module['dynCall_' + sig].apply(null, [ptr].concat(args));
  463. } else {
  464. assert(sig.length == 1);
  465. assert(('dynCall_' + sig) in Module, 'bad function pointer type - no table for sig \'' + sig + '\'');
  466. return Module['dynCall_' + sig].call(null, ptr);
  467. }
  468. },
  469. functionPointers: [],
  470. addFunction: function (func) {
  471. for (var i = 0; i < Runtime.functionPointers.length; i++) {
  472. if (!Runtime.functionPointers[i]) {
  473. Runtime.functionPointers[i] = func;
  474. return 2*(1 + i);
  475. }
  476. }
  477. throw 'Finished up all reserved function pointers. Use a higher value for RESERVED_FUNCTION_POINTERS.';
  478. },
  479. removeFunction: function (index) {
  480. Runtime.functionPointers[(index-2)/2] = null;
  481. },
  482. warnOnce: function (text) {
  483. if (!Runtime.warnOnce.shown) Runtime.warnOnce.shown = {};
  484. if (!Runtime.warnOnce.shown[text]) {
  485. Runtime.warnOnce.shown[text] = 1;
  486. Module.printErr(text);
  487. }
  488. },
  489. funcWrappers: {},
  490. getFuncWrapper: function (func, sig) {
  491. assert(sig);
  492. if (!Runtime.funcWrappers[sig]) {
  493. Runtime.funcWrappers[sig] = {};
  494. }
  495. var sigCache = Runtime.funcWrappers[sig];
  496. if (!sigCache[func]) {
  497. // optimize away arguments usage in common cases
  498. if (sig.length === 1) {
  499. sigCache[func] = function dynCall_wrapper() {
  500. return Runtime.dynCall(sig, func);
  501. };
  502. } else if (sig.length === 2) {
  503. sigCache[func] = function dynCall_wrapper(arg) {
  504. return Runtime.dynCall(sig, func, [arg]);
  505. };
  506. } else {
  507. // general case
  508. sigCache[func] = function dynCall_wrapper() {
  509. return Runtime.dynCall(sig, func, Array.prototype.slice.call(arguments));
  510. };
  511. }
  512. }
  513. return sigCache[func];
  514. },
  515. getCompilerSetting: function (name) {
  516. throw 'You must build with -s RETAIN_COMPILER_SETTINGS=1 for Runtime.getCompilerSetting or emscripten_get_compiler_setting to work';
  517. },
  518. stackAlloc: function (size) { var ret = STACKTOP;STACKTOP = (STACKTOP + size)|0;STACKTOP = (((STACKTOP)+15)&-16);(assert((((STACKTOP|0) < (STACK_MAX|0))|0))|0); return ret; },
  519. staticAlloc: function (size) { var ret = STATICTOP;STATICTOP = (STATICTOP + (assert(!staticSealed),size))|0;STATICTOP = (((STATICTOP)+15)&-16); return ret; },
  520. dynamicAlloc: function (size) { assert(DYNAMICTOP_PTR);var ret = HEAP32[DYNAMICTOP_PTR>>2];var end = (((ret + size + 15)|0) & -16);HEAP32[DYNAMICTOP_PTR>>2] = end;if (end >= TOTAL_MEMORY) {var success = enlargeMemory();if (!success) {HEAP32[DYNAMICTOP_PTR>>2] = ret;return 0;}}return ret;},
  521. alignMemory: function (size,quantum) { var ret = size = Math.ceil((size)/(quantum ? quantum : 16))*(quantum ? quantum : 16); return ret; },
  522. makeBigInt: function (low,high,unsigned) { var ret = (unsigned ? ((+((low>>>0)))+((+((high>>>0)))*4294967296.0)) : ((+((low>>>0)))+((+((high|0)))*4294967296.0))); return ret; },
  523. GLOBAL_BASE: 8,
  524. QUANTUM_SIZE: 4,
  525. __dummy__: 0
  526. }
  527. Module["Runtime"] = Runtime;
  528. //========================================
  529. // Runtime essentials
  530. //========================================
  531. var ABORT = 0; // whether we are quitting the application. no code should run after this. set in exit() and abort()
  532. var EXITSTATUS = 0;
  533. function assert(condition, text) {
  534. if (!condition) {
  535. abort('Assertion failed: ' + text);
  536. }
  537. }
  538. var globalScope = this;
  539. // Returns the C function with a specified identifier (for C++, you need to do manual name mangling)
  540. function getCFunc(ident) {
  541. var func = Module['_' + ident]; // closure exported function
  542. if (!func) {
  543. try { func = eval('_' + ident); } catch(e) {}
  544. }
  545. assert(func, 'Cannot call unknown function ' + ident + ' (perhaps LLVM optimizations or closure removed it?)');
  546. return func;
  547. }
  548. var cwrap, ccall;
  549. (function(){
  550. var JSfuncs = {
  551. // Helpers for cwrap -- it can't refer to Runtime directly because it might
  552. // be renamed by closure, instead it calls JSfuncs['stackSave'].body to find
  553. // out what the minified function name is.
  554. 'stackSave': function() {
  555. Runtime.stackSave()
  556. },
  557. 'stackRestore': function() {
  558. Runtime.stackRestore()
  559. },
  560. // type conversion from js to c
  561. 'arrayToC' : function(arr) {
  562. var ret = Runtime.stackAlloc(arr.length);
  563. writeArrayToMemory(arr, ret);
  564. return ret;
  565. },
  566. 'stringToC' : function(str) {
  567. var ret = 0;
  568. if (str !== null && str !== undefined && str !== 0) { // null string
  569. // at most 4 bytes per UTF-8 code point, +1 for the trailing '\0'
  570. var len = (str.length << 2) + 1;
  571. ret = Runtime.stackAlloc(len);
  572. stringToUTF8(str, ret, len);
  573. }
  574. return ret;
  575. }
  576. };
  577. // For fast lookup of conversion functions
  578. var toC = {'string' : JSfuncs['stringToC'], 'array' : JSfuncs['arrayToC']};
  579. // C calling interface.
  580. ccall = function ccallFunc(ident, returnType, argTypes, args, opts) {
  581. var func = getCFunc(ident);
  582. var cArgs = [];
  583. var stack = 0;
  584. assert(returnType !== 'array', 'Return type should not be "array".');
  585. if (args) {
  586. for (var i = 0; i < args.length; i++) {
  587. var converter = toC[argTypes[i]];
  588. if (converter) {
  589. if (stack === 0) stack = Runtime.stackSave();
  590. cArgs[i] = converter(args[i]);
  591. } else {
  592. cArgs[i] = args[i];
  593. }
  594. }
  595. }
  596. var ret = func.apply(null, cArgs);
  597. if ((!opts || !opts.async) && typeof EmterpreterAsync === 'object') {
  598. assert(!EmterpreterAsync.state, 'cannot start async op with normal JS calling ccall');
  599. }
  600. if (opts && opts.async) assert(!returnType, 'async ccalls cannot return values');
  601. if (returnType === 'string') ret = Pointer_stringify(ret);
  602. if (stack !== 0) {
  603. if (opts && opts.async) {
  604. EmterpreterAsync.asyncFinalizers.push(function() {
  605. Runtime.stackRestore(stack);
  606. });
  607. return;
  608. }
  609. Runtime.stackRestore(stack);
  610. }
  611. return ret;
  612. }
  613. var sourceRegex = /^function\s*[a-zA-Z$_0-9]*\s*\(([^)]*)\)\s*{\s*([^*]*?)[\s;]*(?:return\s*(.*?)[;\s]*)?}$/;
  614. function parseJSFunc(jsfunc) {
  615. // Match the body and the return value of a javascript function source
  616. var parsed = jsfunc.toString().match(sourceRegex).slice(1);
  617. return {arguments : parsed[0], body : parsed[1], returnValue: parsed[2]}
  618. }
  619. // sources of useful functions. we create this lazily as it can trigger a source decompression on this entire file
  620. var JSsource = null;
  621. function ensureJSsource() {
  622. if (!JSsource) {
  623. JSsource = {};
  624. for (var fun in JSfuncs) {
  625. if (JSfuncs.hasOwnProperty(fun)) {
  626. // Elements of toCsource are arrays of three items:
  627. // the code, and the return value
  628. JSsource[fun] = parseJSFunc(JSfuncs[fun]);
  629. }
  630. }
  631. }
  632. }
  633. cwrap = function cwrap(ident, returnType, argTypes) {
  634. argTypes = argTypes || [];
  635. var cfunc = getCFunc(ident);
  636. // When the function takes numbers and returns a number, we can just return
  637. // the original function
  638. var numericArgs = argTypes.every(function(type){ return type === 'number'});
  639. var numericRet = (returnType !== 'string');
  640. if ( numericRet && numericArgs) {
  641. return cfunc;
  642. }
  643. // Creation of the arguments list (["$1","$2",...,"$nargs"])
  644. var argNames = argTypes.map(function(x,i){return '$'+i});
  645. var funcstr = "(function(" + argNames.join(',') + ") {";
  646. var nargs = argTypes.length;
  647. if (!numericArgs) {
  648. // Generate the code needed to convert the arguments from javascript
  649. // values to pointers
  650. ensureJSsource();
  651. funcstr += 'var stack = ' + JSsource['stackSave'].body + ';';
  652. for (var i = 0; i < nargs; i++) {
  653. var arg = argNames[i], type = argTypes[i];
  654. if (type === 'number') continue;
  655. var convertCode = JSsource[type + 'ToC']; // [code, return]
  656. funcstr += 'var ' + convertCode.arguments + ' = ' + arg + ';';
  657. funcstr += convertCode.body + ';';
  658. funcstr += arg + '=(' + convertCode.returnValue + ');';
  659. }
  660. }
  661. // When the code is compressed, the name of cfunc is not literally 'cfunc' anymore
  662. var cfuncname = parseJSFunc(function(){return cfunc}).returnValue;
  663. // Call the function
  664. funcstr += 'var ret = ' + cfuncname + '(' + argNames.join(',') + ');';
  665. if (!numericRet) { // Return type can only by 'string' or 'number'
  666. // Convert the result to a string
  667. var strgfy = parseJSFunc(function(){return Pointer_stringify}).returnValue;
  668. funcstr += 'ret = ' + strgfy + '(ret);';
  669. }
  670. funcstr += "if (typeof EmterpreterAsync === 'object') { assert(!EmterpreterAsync.state, 'cannot start async op with normal JS calling cwrap') }";
  671. if (!numericArgs) {
  672. // If we had a stack, restore it
  673. ensureJSsource();
  674. funcstr += JSsource['stackRestore'].body.replace('()', '(stack)') + ';';
  675. }
  676. funcstr += 'return ret})';
  677. return eval(funcstr);
  678. };
  679. })();
  680. Module["ccall"] = ccall;
  681. Module["cwrap"] = cwrap;
  682. function setValue(ptr, value, type, noSafe) {
  683. type = type || 'i8';
  684. if (type.charAt(type.length-1) === '*') type = 'i32'; // pointers are 32-bit
  685. switch(type) {
  686. case 'i1': HEAP8[((ptr)>>0)]=value; break;
  687. case 'i8': HEAP8[((ptr)>>0)]=value; break;
  688. case 'i16': HEAP16[((ptr)>>1)]=value; break;
  689. case 'i32': HEAP32[((ptr)>>2)]=value; break;
  690. case 'i64': (tempI64 = [value>>>0,(tempDouble=value,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[((ptr)>>2)]=tempI64[0],HEAP32[(((ptr)+(4))>>2)]=tempI64[1]); break;
  691. case 'float': HEAPF32[((ptr)>>2)]=value; break;
  692. case 'double': HEAPF64[((ptr)>>3)]=value; break;
  693. default: abort('invalid type for setValue: ' + type);
  694. }
  695. }
  696. Module["setValue"] = setValue;
  697. function getValue(ptr, type, noSafe) {
  698. type = type || 'i8';
  699. if (type.charAt(type.length-1) === '*') type = 'i32'; // pointers are 32-bit
  700. switch(type) {
  701. case 'i1': return HEAP8[((ptr)>>0)];
  702. case 'i8': return HEAP8[((ptr)>>0)];
  703. case 'i16': return HEAP16[((ptr)>>1)];
  704. case 'i32': return HEAP32[((ptr)>>2)];
  705. case 'i64': return HEAP32[((ptr)>>2)];
  706. case 'float': return HEAPF32[((ptr)>>2)];
  707. case 'double': return HEAPF64[((ptr)>>3)];
  708. default: abort('invalid type for setValue: ' + type);
  709. }
  710. return null;
  711. }
  712. Module["getValue"] = getValue;
  713. var ALLOC_NORMAL = 0; // Tries to use _malloc()
  714. var ALLOC_STACK = 1; // Lives for the duration of the current function call
  715. var ALLOC_STATIC = 2; // Cannot be freed
  716. var ALLOC_DYNAMIC = 3; // Cannot be freed except through sbrk
  717. var ALLOC_NONE = 4; // Do not allocate
  718. Module["ALLOC_NORMAL"] = ALLOC_NORMAL;
  719. Module["ALLOC_STACK"] = ALLOC_STACK;
  720. Module["ALLOC_STATIC"] = ALLOC_STATIC;
  721. Module["ALLOC_DYNAMIC"] = ALLOC_DYNAMIC;
  722. Module["ALLOC_NONE"] = ALLOC_NONE;
  723. // allocate(): This is for internal use. You can use it yourself as well, but the interface
  724. // is a little tricky (see docs right below). The reason is that it is optimized
  725. // for multiple syntaxes to save space in generated code. So you should
  726. // normally not use allocate(), and instead allocate memory using _malloc(),
  727. // initialize it with setValue(), and so forth.
  728. // @slab: An array of data, or a number. If a number, then the size of the block to allocate,
  729. // in *bytes* (note that this is sometimes confusing: the next parameter does not
  730. // affect this!)
  731. // @types: Either an array of types, one for each byte (or 0 if no type at that position),
  732. // or a single type which is used for the entire block. This only matters if there
  733. // is initial data - if @slab is a number, then this does not matter at all and is
  734. // ignored.
  735. // @allocator: How to allocate memory, see ALLOC_*
  736. function allocate(slab, types, allocator, ptr) {
  737. var zeroinit, size;
  738. if (typeof slab === 'number') {
  739. zeroinit = true;
  740. size = slab;
  741. } else {
  742. zeroinit = false;
  743. size = slab.length;
  744. }
  745. var singleType = typeof types === 'string' ? types : null;
  746. var ret;
  747. if (allocator == ALLOC_NONE) {
  748. ret = ptr;
  749. } else {
  750. ret = [typeof _malloc === 'function' ? _malloc : Runtime.staticAlloc, Runtime.stackAlloc, Runtime.staticAlloc, Runtime.dynamicAlloc][allocator === undefined ? ALLOC_STATIC : allocator](Math.max(size, singleType ? 1 : types.length));
  751. }
  752. if (zeroinit) {
  753. var ptr = ret, stop;
  754. assert((ret & 3) == 0);
  755. stop = ret + (size & ~3);
  756. for (; ptr < stop; ptr += 4) {
  757. HEAP32[((ptr)>>2)]=0;
  758. }
  759. stop = ret + size;
  760. while (ptr < stop) {
  761. HEAP8[((ptr++)>>0)]=0;
  762. }
  763. return ret;
  764. }
  765. if (singleType === 'i8') {
  766. if (slab.subarray || slab.slice) {
  767. HEAPU8.set(slab, ret);
  768. } else {
  769. HEAPU8.set(new Uint8Array(slab), ret);
  770. }
  771. return ret;
  772. }
  773. var i = 0, type, typeSize, previousType;
  774. while (i < size) {
  775. var curr = slab[i];
  776. if (typeof curr === 'function') {
  777. curr = Runtime.getFunctionIndex(curr);
  778. }
  779. type = singleType || types[i];
  780. if (type === 0) {
  781. i++;
  782. continue;
  783. }
  784. assert(type, 'Must know what type to store in allocate!');
  785. if (type == 'i64') type = 'i32'; // special case: we have one i32 here, and one i32 later
  786. setValue(ret+i, curr, type);
  787. // no need to look up size unless type changes, so cache it
  788. if (previousType !== type) {
  789. typeSize = Runtime.getNativeTypeSize(type);
  790. previousType = type;
  791. }
  792. i += typeSize;
  793. }
  794. return ret;
  795. }
  796. Module["allocate"] = allocate;
  797. // Allocate memory during any stage of startup - static memory early on, dynamic memory later, malloc when ready
  798. function getMemory(size) {
  799. if (!staticSealed) return Runtime.staticAlloc(size);
  800. if (!runtimeInitialized) return Runtime.dynamicAlloc(size);
  801. return _malloc(size);
  802. }
  803. Module["getMemory"] = getMemory;
  804. function Pointer_stringify(ptr, /* optional */ length) {
  805. if (length === 0 || !ptr) return '';
  806. // TODO: use TextDecoder
  807. // Find the length, and check for UTF while doing so
  808. var hasUtf = 0;
  809. var t;
  810. var i = 0;
  811. while (1) {
  812. assert(ptr + i < TOTAL_MEMORY);
  813. t = HEAPU8[(((ptr)+(i))>>0)];
  814. hasUtf |= t;
  815. if (t == 0 && !length) break;
  816. i++;
  817. if (length && i == length) break;
  818. }
  819. if (!length) length = i;
  820. var ret = '';
  821. if (hasUtf < 128) {
  822. var MAX_CHUNK = 1024; // split up into chunks, because .apply on a huge string can overflow the stack
  823. var curr;
  824. while (length > 0) {
  825. curr = String.fromCharCode.apply(String, HEAPU8.subarray(ptr, ptr + Math.min(length, MAX_CHUNK)));
  826. ret = ret ? ret + curr : curr;
  827. ptr += MAX_CHUNK;
  828. length -= MAX_CHUNK;
  829. }
  830. return ret;
  831. }
  832. return Module['UTF8ToString'](ptr);
  833. }
  834. Module["Pointer_stringify"] = Pointer_stringify;
  835. // Given a pointer 'ptr' to a null-terminated ASCII-encoded string in the emscripten HEAP, returns
  836. // a copy of that string as a Javascript String object.
  837. function AsciiToString(ptr) {
  838. var str = '';
  839. while (1) {
  840. var ch = HEAP8[((ptr++)>>0)];
  841. if (!ch) return str;
  842. str += String.fromCharCode(ch);
  843. }
  844. }
  845. Module["AsciiToString"] = AsciiToString;
  846. // Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr',
  847. // null-terminated and encoded in ASCII form. The copy will require at most str.length+1 bytes of space in the HEAP.
  848. function stringToAscii(str, outPtr) {
  849. return writeAsciiToMemory(str, outPtr, false);
  850. }
  851. Module["stringToAscii"] = stringToAscii;
  852. // Given a pointer 'ptr' to a null-terminated UTF8-encoded string in the given array that contains uint8 values, returns
  853. // a copy of that string as a Javascript String object.
  854. var UTF8Decoder = typeof TextDecoder !== 'undefined' ? new TextDecoder('utf8') : undefined;
  855. function UTF8ArrayToString(u8Array, idx) {
  856. var endPtr = idx;
  857. // TextDecoder needs to know the byte length in advance, it doesn't stop on null terminator by itself.
  858. // Also, use the length info to avoid running tiny strings through TextDecoder, since .subarray() allocates garbage.
  859. while (u8Array[endPtr]) ++endPtr;
  860. if (endPtr - idx > 16 && u8Array.subarray && UTF8Decoder) {
  861. return UTF8Decoder.decode(u8Array.subarray(idx, endPtr));
  862. } else {
  863. var u0, u1, u2, u3, u4, u5;
  864. var str = '';
  865. while (1) {
  866. // For UTF8 byte structure, see http://en.wikipedia.org/wiki/UTF-8#Description and https://www.ietf.org/rfc/rfc2279.txt and https://tools.ietf.org/html/rfc3629
  867. u0 = u8Array[idx++];
  868. if (!u0) return str;
  869. if (!(u0 & 0x80)) { str += String.fromCharCode(u0); continue; }
  870. u1 = u8Array[idx++] & 63;
  871. if ((u0 & 0xE0) == 0xC0) { str += String.fromCharCode(((u0 & 31) << 6) | u1); continue; }
  872. u2 = u8Array[idx++] & 63;
  873. if ((u0 & 0xF0) == 0xE0) {
  874. u0 = ((u0 & 15) << 12) | (u1 << 6) | u2;
  875. } else {
  876. u3 = u8Array[idx++] & 63;
  877. if ((u0 & 0xF8) == 0xF0) {
  878. u0 = ((u0 & 7) << 18) | (u1 << 12) | (u2 << 6) | u3;
  879. } else {
  880. u4 = u8Array[idx++] & 63;
  881. if ((u0 & 0xFC) == 0xF8) {
  882. u0 = ((u0 & 3) << 24) | (u1 << 18) | (u2 << 12) | (u3 << 6) | u4;
  883. } else {
  884. u5 = u8Array[idx++] & 63;
  885. u0 = ((u0 & 1) << 30) | (u1 << 24) | (u2 << 18) | (u3 << 12) | (u4 << 6) | u5;
  886. }
  887. }
  888. }
  889. if (u0 < 0x10000) {
  890. str += String.fromCharCode(u0);
  891. } else {
  892. var ch = u0 - 0x10000;
  893. str += String.fromCharCode(0xD800 | (ch >> 10), 0xDC00 | (ch & 0x3FF));
  894. }
  895. }
  896. }
  897. }
  898. Module["UTF8ArrayToString"] = UTF8ArrayToString;
  899. // Given a pointer 'ptr' to a null-terminated UTF8-encoded string in the emscripten HEAP, returns
  900. // a copy of that string as a Javascript String object.
  901. function UTF8ToString(ptr) {
  902. return UTF8ArrayToString(HEAPU8,ptr);
  903. }
  904. Module["UTF8ToString"] = UTF8ToString;
  905. // Copies the given Javascript String object 'str' to the given byte array at address 'outIdx',
  906. // encoded in UTF8 form and null-terminated. The copy will require at most str.length*4+1 bytes of space in the HEAP.
  907. // Use the function lengthBytesUTF8 to compute the exact number of bytes (excluding null terminator) that this function will write.
  908. // Parameters:
  909. // str: the Javascript string to copy.
  910. // outU8Array: the array to copy to. Each index in this array is assumed to be one 8-byte element.
  911. // outIdx: The starting offset in the array to begin the copying.
  912. // maxBytesToWrite: The maximum number of bytes this function can write to the array. This count should include the null
  913. // terminator, i.e. if maxBytesToWrite=1, only the null terminator will be written and nothing else.
  914. // maxBytesToWrite=0 does not write any bytes to the output, not even the null terminator.
  915. // Returns the number of bytes written, EXCLUDING the null terminator.
  916. function stringToUTF8Array(str, outU8Array, outIdx, maxBytesToWrite) {
  917. if (!(maxBytesToWrite > 0)) // Parameter maxBytesToWrite is not optional. Negative values, 0, null, undefined and false each don't write out any bytes.
  918. return 0;
  919. var startIdx = outIdx;
  920. var endIdx = outIdx + maxBytesToWrite - 1; // -1 for string null terminator.
  921. for (var i = 0; i < str.length; ++i) {
  922. // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! So decode UTF16->UTF32->UTF8.
  923. // See http://unicode.org/faq/utf_bom.html#utf16-3
  924. // For UTF8 byte structure, see http://en.wikipedia.org/wiki/UTF-8#Description and https://www.ietf.org/rfc/rfc2279.txt and https://tools.ietf.org/html/rfc3629
  925. var u = str.charCodeAt(i); // possibly a lead surrogate
  926. if (u >= 0xD800 && u <= 0xDFFF) u = 0x10000 + ((u & 0x3FF) << 10) | (str.charCodeAt(++i) & 0x3FF);
  927. if (u <= 0x7F) {
  928. if (outIdx >= endIdx) break;
  929. outU8Array[outIdx++] = u;
  930. } else if (u <= 0x7FF) {
  931. if (outIdx + 1 >= endIdx) break;
  932. outU8Array[outIdx++] = 0xC0 | (u >> 6);
  933. outU8Array[outIdx++] = 0x80 | (u & 63);
  934. } else if (u <= 0xFFFF) {
  935. if (outIdx + 2 >= endIdx) break;
  936. outU8Array[outIdx++] = 0xE0 | (u >> 12);
  937. outU8Array[outIdx++] = 0x80 | ((u >> 6) & 63);
  938. outU8Array[outIdx++] = 0x80 | (u & 63);
  939. } else if (u <= 0x1FFFFF) {
  940. if (outIdx + 3 >= endIdx) break;
  941. outU8Array[outIdx++] = 0xF0 | (u >> 18);
  942. outU8Array[outIdx++] = 0x80 | ((u >> 12) & 63);
  943. outU8Array[outIdx++] = 0x80 | ((u >> 6) & 63);
  944. outU8Array[outIdx++] = 0x80 | (u & 63);
  945. } else if (u <= 0x3FFFFFF) {
  946. if (outIdx + 4 >= endIdx) break;
  947. outU8Array[outIdx++] = 0xF8 | (u >> 24);
  948. outU8Array[outIdx++] = 0x80 | ((u >> 18) & 63);
  949. outU8Array[outIdx++] = 0x80 | ((u >> 12) & 63);
  950. outU8Array[outIdx++] = 0x80 | ((u >> 6) & 63);
  951. outU8Array[outIdx++] = 0x80 | (u & 63);
  952. } else {
  953. if (outIdx + 5 >= endIdx) break;
  954. outU8Array[outIdx++] = 0xFC | (u >> 30);
  955. outU8Array[outIdx++] = 0x80 | ((u >> 24) & 63);
  956. outU8Array[outIdx++] = 0x80 | ((u >> 18) & 63);
  957. outU8Array[outIdx++] = 0x80 | ((u >> 12) & 63);
  958. outU8Array[outIdx++] = 0x80 | ((u >> 6) & 63);
  959. outU8Array[outIdx++] = 0x80 | (u & 63);
  960. }
  961. }
  962. // Null-terminate the pointer to the buffer.
  963. outU8Array[outIdx] = 0;
  964. return outIdx - startIdx;
  965. }
  966. Module["stringToUTF8Array"] = stringToUTF8Array;
  967. // Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr',
  968. // null-terminated and encoded in UTF8 form. The copy will require at most str.length*4+1 bytes of space in the HEAP.
  969. // Use the function lengthBytesUTF8 to compute the exact number of bytes (excluding null terminator) that this function will write.
  970. // Returns the number of bytes written, EXCLUDING the null terminator.
  971. function stringToUTF8(str, outPtr, maxBytesToWrite) {
  972. assert(typeof maxBytesToWrite == 'number', 'stringToUTF8(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!');
  973. return stringToUTF8Array(str, HEAPU8,outPtr, maxBytesToWrite);
  974. }
  975. Module["stringToUTF8"] = stringToUTF8;
  976. // Returns the number of bytes the given Javascript string takes if encoded as a UTF8 byte array, EXCLUDING the null terminator byte.
  977. function lengthBytesUTF8(str) {
  978. var len = 0;
  979. for (var i = 0; i < str.length; ++i) {
  980. // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! So decode UTF16->UTF32->UTF8.
  981. // See http://unicode.org/faq/utf_bom.html#utf16-3
  982. var u = str.charCodeAt(i); // possibly a lead surrogate
  983. if (u >= 0xD800 && u <= 0xDFFF) u = 0x10000 + ((u & 0x3FF) << 10) | (str.charCodeAt(++i) & 0x3FF);
  984. if (u <= 0x7F) {
  985. ++len;
  986. } else if (u <= 0x7FF) {
  987. len += 2;
  988. } else if (u <= 0xFFFF) {
  989. len += 3;
  990. } else if (u <= 0x1FFFFF) {
  991. len += 4;
  992. } else if (u <= 0x3FFFFFF) {
  993. len += 5;
  994. } else {
  995. len += 6;
  996. }
  997. }
  998. return len;
  999. }
  1000. Module["lengthBytesUTF8"] = lengthBytesUTF8;
  1001. // Given a pointer 'ptr' to a null-terminated UTF16LE-encoded string in the emscripten HEAP, returns
  1002. // a copy of that string as a Javascript String object.
  1003. var UTF16Decoder = typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-16le') : undefined;
  1004. function UTF16ToString(ptr) {
  1005. assert(ptr % 2 == 0, 'Pointer passed to UTF16ToString must be aligned to two bytes!');
  1006. var endPtr = ptr;
  1007. // TextDecoder needs to know the byte length in advance, it doesn't stop on null terminator by itself.
  1008. // Also, use the length info to avoid running tiny strings through TextDecoder, since .subarray() allocates garbage.
  1009. var idx = endPtr >> 1;
  1010. while (HEAP16[idx]) ++idx;
  1011. endPtr = idx << 1;
  1012. if (endPtr - ptr > 32 && UTF16Decoder) {
  1013. return UTF16Decoder.decode(HEAPU8.subarray(ptr, endPtr));
  1014. } else {
  1015. var i = 0;
  1016. var str = '';
  1017. while (1) {
  1018. var codeUnit = HEAP16[(((ptr)+(i*2))>>1)];
  1019. if (codeUnit == 0) return str;
  1020. ++i;
  1021. // fromCharCode constructs a character from a UTF-16 code unit, so we can pass the UTF16 string right through.
  1022. str += String.fromCharCode(codeUnit);
  1023. }
  1024. }
  1025. }
  1026. // Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr',
  1027. // null-terminated and encoded in UTF16 form. The copy will require at most str.length*4+2 bytes of space in the HEAP.
  1028. // Use the function lengthBytesUTF16() to compute the exact number of bytes (excluding null terminator) that this function will write.
  1029. // Parameters:
  1030. // str: the Javascript string to copy.
  1031. // outPtr: Byte address in Emscripten HEAP where to write the string to.
  1032. // maxBytesToWrite: The maximum number of bytes this function can write to the array. This count should include the null
  1033. // terminator, i.e. if maxBytesToWrite=2, only the null terminator will be written and nothing else.
  1034. // maxBytesToWrite<2 does not write any bytes to the output, not even the null terminator.
  1035. // Returns the number of bytes written, EXCLUDING the null terminator.
  1036. function stringToUTF16(str, outPtr, maxBytesToWrite) {
  1037. assert(outPtr % 2 == 0, 'Pointer passed to stringToUTF16 must be aligned to two bytes!');
  1038. assert(typeof maxBytesToWrite == 'number', 'stringToUTF16(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!');
  1039. // Backwards compatibility: if max bytes is not specified, assume unsafe unbounded write is allowed.
  1040. if (maxBytesToWrite === undefined) {
  1041. maxBytesToWrite = 0x7FFFFFFF;
  1042. }
  1043. if (maxBytesToWrite < 2) return 0;
  1044. maxBytesToWrite -= 2; // Null terminator.
  1045. var startPtr = outPtr;
  1046. var numCharsToWrite = (maxBytesToWrite < str.length*2) ? (maxBytesToWrite / 2) : str.length;
  1047. for (var i = 0; i < numCharsToWrite; ++i) {
  1048. // charCodeAt returns a UTF-16 encoded code unit, so it can be directly written to the HEAP.
  1049. var codeUnit = str.charCodeAt(i); // possibly a lead surrogate
  1050. HEAP16[((outPtr)>>1)]=codeUnit;
  1051. outPtr += 2;
  1052. }
  1053. // Null-terminate the pointer to the HEAP.
  1054. HEAP16[((outPtr)>>1)]=0;
  1055. return outPtr - startPtr;
  1056. }
  1057. // Returns the number of bytes the given Javascript string takes if encoded as a UTF16 byte array, EXCLUDING the null terminator byte.
  1058. function lengthBytesUTF16(str) {
  1059. return str.length*2;
  1060. }
  1061. function UTF32ToString(ptr) {
  1062. assert(ptr % 4 == 0, 'Pointer passed to UTF32ToString must be aligned to four bytes!');
  1063. var i = 0;
  1064. var str = '';
  1065. while (1) {
  1066. var utf32 = HEAP32[(((ptr)+(i*4))>>2)];
  1067. if (utf32 == 0)
  1068. return str;
  1069. ++i;
  1070. // Gotcha: fromCharCode constructs a character from a UTF-16 encoded code (pair), not from a Unicode code point! So encode the code point to UTF-16 for constructing.
  1071. // See http://unicode.org/faq/utf_bom.html#utf16-3
  1072. if (utf32 >= 0x10000) {
  1073. var ch = utf32 - 0x10000;
  1074. str += String.fromCharCode(0xD800 | (ch >> 10), 0xDC00 | (ch & 0x3FF));
  1075. } else {
  1076. str += String.fromCharCode(utf32);
  1077. }
  1078. }
  1079. }
  1080. // Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr',
  1081. // null-terminated and encoded in UTF32 form. The copy will require at most str.length*4+4 bytes of space in the HEAP.
  1082. // Use the function lengthBytesUTF32() to compute the exact number of bytes (excluding null terminator) that this function will write.
  1083. // Parameters:
  1084. // str: the Javascript string to copy.
  1085. // outPtr: Byte address in Emscripten HEAP where to write the string to.
  1086. // maxBytesToWrite: The maximum number of bytes this function can write to the array. This count should include the null
  1087. // terminator, i.e. if maxBytesToWrite=4, only the null terminator will be written and nothing else.
  1088. // maxBytesToWrite<4 does not write any bytes to the output, not even the null terminator.
  1089. // Returns the number of bytes written, EXCLUDING the null terminator.
  1090. function stringToUTF32(str, outPtr, maxBytesToWrite) {
  1091. assert(outPtr % 4 == 0, 'Pointer passed to stringToUTF32 must be aligned to four bytes!');
  1092. assert(typeof maxBytesToWrite == 'number', 'stringToUTF32(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!');
  1093. // Backwards compatibility: if max bytes is not specified, assume unsafe unbounded write is allowed.
  1094. if (maxBytesToWrite === undefined) {
  1095. maxBytesToWrite = 0x7FFFFFFF;
  1096. }
  1097. if (maxBytesToWrite < 4) return 0;
  1098. var startPtr = outPtr;
  1099. var endPtr = startPtr + maxBytesToWrite - 4;
  1100. for (var i = 0; i < str.length; ++i) {
  1101. // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! We must decode the string to UTF-32 to the heap.
  1102. // See http://unicode.org/faq/utf_bom.html#utf16-3
  1103. var codeUnit = str.charCodeAt(i); // possibly a lead surrogate
  1104. if (codeUnit >= 0xD800 && codeUnit <= 0xDFFF) {
  1105. var trailSurrogate = str.charCodeAt(++i);
  1106. codeUnit = 0x10000 + ((codeUnit & 0x3FF) << 10) | (trailSurrogate & 0x3FF);
  1107. }
  1108. HEAP32[((outPtr)>>2)]=codeUnit;
  1109. outPtr += 4;
  1110. if (outPtr + 4 > endPtr) break;
  1111. }
  1112. // Null-terminate the pointer to the HEAP.
  1113. HEAP32[((outPtr)>>2)]=0;
  1114. return outPtr - startPtr;
  1115. }
  1116. // Returns the number of bytes the given Javascript string takes if encoded as a UTF16 byte array, EXCLUDING the null terminator byte.
  1117. function lengthBytesUTF32(str) {
  1118. var len = 0;
  1119. for (var i = 0; i < str.length; ++i) {
  1120. // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! We must decode the string to UTF-32 to the heap.
  1121. // See http://unicode.org/faq/utf_bom.html#utf16-3
  1122. var codeUnit = str.charCodeAt(i);
  1123. if (codeUnit >= 0xD800 && codeUnit <= 0xDFFF) ++i; // possibly a lead surrogate, so skip over the tail surrogate.
  1124. len += 4;
  1125. }
  1126. return len;
  1127. }
  1128. function demangle(func) {
  1129. var __cxa_demangle_func = Module['___cxa_demangle'] || Module['__cxa_demangle'];
  1130. if (__cxa_demangle_func) {
  1131. try {
  1132. var s =
  1133. func.substr(1);
  1134. var len = lengthBytesUTF8(s)+1;
  1135. var buf = _malloc(len);
  1136. stringToUTF8(s, buf, len);
  1137. var status = _malloc(4);
  1138. var ret = __cxa_demangle_func(buf, 0, 0, status);
  1139. if (getValue(status, 'i32') === 0 && ret) {
  1140. return Pointer_stringify(ret);
  1141. }
  1142. // otherwise, libcxxabi failed
  1143. } catch(e) {
  1144. // ignore problems here
  1145. } finally {
  1146. if (buf) _free(buf);
  1147. if (status) _free(status);
  1148. if (ret) _free(ret);
  1149. }
  1150. // failure when using libcxxabi, don't demangle
  1151. return func;
  1152. }
  1153. Runtime.warnOnce('warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling');
  1154. return func;
  1155. }
  1156. function demangleAll(text) {
  1157. var regex =
  1158. /__Z[\w\d_]+/g;
  1159. return text.replace(regex,
  1160. function(x) {
  1161. var y = demangle(x);
  1162. return x === y ? x : (x + ' [' + y + ']');
  1163. });
  1164. }
  1165. function jsStackTrace() {
  1166. var err = new Error();
  1167. if (!err.stack) {
  1168. // IE10+ special cases: It does have callstack info, but it is only populated if an Error object is thrown,
  1169. // so try that as a special-case.
  1170. try {
  1171. throw new Error(0);
  1172. } catch(e) {
  1173. err = e;
  1174. }
  1175. if (!err.stack) {
  1176. return '(no stack trace available)';
  1177. }
  1178. }
  1179. return err.stack.toString();
  1180. }
  1181. function stackTrace() {
  1182. var js = jsStackTrace();
  1183. if (Module['extraStackTrace']) js += '\n' + Module['extraStackTrace']();
  1184. return demangleAll(js);
  1185. }
  1186. Module["stackTrace"] = stackTrace;
  1187. // Memory management
  1188. var PAGE_SIZE = 16384;
  1189. var WASM_PAGE_SIZE = 65536;
  1190. var ASMJS_PAGE_SIZE = 16777216;
  1191. var MIN_TOTAL_MEMORY = 16777216;
  1192. function alignUp(x, multiple) {
  1193. if (x % multiple > 0) {
  1194. x += multiple - (x % multiple);
  1195. }
  1196. return x;
  1197. }
  1198. var HEAP;
  1199. var buffer;
  1200. var HEAP8, HEAPU8, HEAP16, HEAPU16, HEAP32, HEAPU32, HEAPF32, HEAPF64;
  1201. function updateGlobalBuffer(buf) {
  1202. Module['buffer'] = buffer = buf;
  1203. }
  1204. function updateGlobalBufferViews() {
  1205. Module['HEAP8'] = HEAP8 = new Int8Array(buffer);
  1206. Module['HEAP16'] = HEAP16 = new Int16Array(buffer);
  1207. Module['HEAP32'] = HEAP32 = new Int32Array(buffer);
  1208. Module['HEAPU8'] = HEAPU8 = new Uint8Array(buffer);
  1209. Module['HEAPU16'] = HEAPU16 = new Uint16Array(buffer);
  1210. Module['HEAPU32'] = HEAPU32 = new Uint32Array(buffer);
  1211. Module['HEAPF32'] = HEAPF32 = new Float32Array(buffer);
  1212. Module['HEAPF64'] = HEAPF64 = new Float64Array(buffer);
  1213. }
  1214. var STATIC_BASE, STATICTOP, staticSealed; // static area
  1215. var STACK_BASE, STACKTOP, STACK_MAX; // stack area
  1216. var DYNAMIC_BASE, DYNAMICTOP_PTR; // dynamic area handled by sbrk
  1217. STATIC_BASE = STATICTOP = STACK_BASE = STACKTOP = STACK_MAX = DYNAMIC_BASE = DYNAMICTOP_PTR = 0;
  1218. staticSealed = false;
  1219. // Initializes the stack cookie. Called at the startup of main and at the startup of each thread in pthreads mode.
  1220. function writeStackCookie() {
  1221. assert((STACK_MAX & 3) == 0);
  1222. HEAPU32[(STACK_MAX >> 2)-1] = 0x02135467;
  1223. HEAPU32[(STACK_MAX >> 2)-2] = 0x89BACDFE;
  1224. }
  1225. function checkStackCookie() {
  1226. if (HEAPU32[(STACK_MAX >> 2)-1] != 0x02135467 || HEAPU32[(STACK_MAX >> 2)-2] != 0x89BACDFE) {
  1227. abort('Stack overflow! Stack cookie has been overwritten, expected hex dwords 0x89BACDFE and 0x02135467, but received 0x' + HEAPU32[(STACK_MAX >> 2)-2].toString(16) + ' ' + HEAPU32[(STACK_MAX >> 2)-1].toString(16));
  1228. }
  1229. // Also test the global address 0 for integrity. This check is not compatible with SAFE_SPLIT_MEMORY though, since that mode already tests all address 0 accesses on its own.
  1230. if (HEAP32[0] !== 0x63736d65 /* 'emsc' */) throw 'Runtime error: The application has corrupted its heap memory area (address zero)!';
  1231. }
  1232. function abortStackOverflow(allocSize) {
  1233. abort('Stack overflow! Attempted to allocate ' + allocSize + ' bytes on the stack, but stack has only ' + (STACK_MAX - asm.stackSave() + allocSize) + ' bytes available!');
  1234. }
  1235. function abortOnCannotGrowMemory() {
  1236. abort('Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value ' + TOTAL_MEMORY + ', (2) compile with -s ALLOW_MEMORY_GROWTH=1 which adjusts the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ');
  1237. }
  1238. function enlargeMemory() {
  1239. abortOnCannotGrowMemory();
  1240. }
  1241. var TOTAL_STACK = Module['TOTAL_STACK'] || 5242880;
  1242. var TOTAL_MEMORY = Module['TOTAL_MEMORY'] || 16777216;
  1243. if (TOTAL_MEMORY < TOTAL_STACK) Module.printErr('TOTAL_MEMORY should be larger than TOTAL_STACK, was ' + TOTAL_MEMORY + '! (TOTAL_STACK=' + TOTAL_STACK + ')');
  1244. // Initialize the runtime's memory
  1245. // check for full engine support (use string 'subarray' to avoid closure compiler confusion)
  1246. assert(typeof Int32Array !== 'undefined' && typeof Float64Array !== 'undefined' && !!(new Int32Array(1)['subarray']) && !!(new Int32Array(1)['set']),
  1247. 'JS engine does not provide full typed array support');
  1248. // Use a provided buffer, if there is one, or else allocate a new one
  1249. if (Module['buffer']) {
  1250. buffer = Module['buffer'];
  1251. assert(buffer.byteLength === TOTAL_MEMORY, 'provided buffer should be ' + TOTAL_MEMORY + ' bytes, but it is ' + buffer.byteLength);
  1252. } else {
  1253. // Use a WebAssembly memory where available
  1254. {
  1255. buffer = new ArrayBuffer(TOTAL_MEMORY);
  1256. }
  1257. assert(buffer.byteLength === TOTAL_MEMORY);
  1258. }
  1259. updateGlobalBufferViews();
  1260. function getTotalMemory() {
  1261. return TOTAL_MEMORY;
  1262. }
  1263. // Endianness check (note: assumes compiler arch was little-endian)
  1264. HEAP32[0] = 0x63736d65; /* 'emsc' */
  1265. HEAP16[1] = 0x6373;
  1266. if (HEAPU8[2] !== 0x73 || HEAPU8[3] !== 0x63) throw 'Runtime error: expected the system to be little-endian!';
  1267. Module['HEAP'] = HEAP;
  1268. Module['buffer'] = buffer;
  1269. Module['HEAP8'] = HEAP8;
  1270. Module['HEAP16'] = HEAP16;
  1271. Module['HEAP32'] = HEAP32;
  1272. Module['HEAPU8'] = HEAPU8;
  1273. Module['HEAPU16'] = HEAPU16;
  1274. Module['HEAPU32'] = HEAPU32;
  1275. Module['HEAPF32'] = HEAPF32;
  1276. Module['HEAPF64'] = HEAPF64;
  1277. function callRuntimeCallbacks(callbacks) {
  1278. while(callbacks.length > 0) {
  1279. var callback = callbacks.shift();
  1280. if (typeof callback == 'function') {
  1281. callback();
  1282. continue;
  1283. }
  1284. var func = callback.func;
  1285. if (typeof func === 'number') {
  1286. if (callback.arg === undefined) {
  1287. Module['dynCall_v'](func);
  1288. } else {
  1289. Module['dynCall_vi'](func, callback.arg);
  1290. }
  1291. } else {
  1292. func(callback.arg === undefined ? null : callback.arg);
  1293. }
  1294. }
  1295. }
  1296. var __ATPRERUN__ = []; // functions called before the runtime is initialized
  1297. var __ATINIT__ = []; // functions called during startup
  1298. var __ATMAIN__ = []; // functions called when main() is to be run
  1299. var __ATEXIT__ = []; // functions called during shutdown
  1300. var __ATPOSTRUN__ = []; // functions called after the runtime has exited
  1301. var runtimeInitialized = false;
  1302. var runtimeExited = false;
  1303. function preRun() {
  1304. // compatibility - merge in anything from Module['preRun'] at this time
  1305. if (Module['preRun']) {
  1306. if (typeof Module['preRun'] == 'function') Module['preRun'] = [Module['preRun']];
  1307. while (Module['preRun'].length) {
  1308. addOnPreRun(Module['preRun'].shift());
  1309. }
  1310. }
  1311. callRuntimeCallbacks(__ATPRERUN__);
  1312. }
  1313. function ensureInitRuntime() {
  1314. checkStackCookie();
  1315. if (runtimeInitialized) return;
  1316. runtimeInitialized = true;
  1317. callRuntimeCallbacks(__ATINIT__);
  1318. }
  1319. function preMain() {
  1320. checkStackCookie();
  1321. callRuntimeCallbacks(__ATMAIN__);
  1322. }
  1323. function exitRuntime() {
  1324. checkStackCookie();
  1325. callRuntimeCallbacks(__ATEXIT__);
  1326. runtimeExited = true;
  1327. }
  1328. function postRun() {
  1329. checkStackCookie();
  1330. // compatibility - merge in anything from Module['postRun'] at this time
  1331. if (Module['postRun']) {
  1332. if (typeof Module['postRun'] == 'function') Module['postRun'] = [Module['postRun']];
  1333. while (Module['postRun'].length) {
  1334. addOnPostRun(Module['postRun'].shift());
  1335. }
  1336. }
  1337. callRuntimeCallbacks(__ATPOSTRUN__);
  1338. }
  1339. function addOnPreRun(cb) {
  1340. __ATPRERUN__.unshift(cb);
  1341. }
  1342. Module["addOnPreRun"] = addOnPreRun;
  1343. function addOnInit(cb) {
  1344. __ATINIT__.unshift(cb);
  1345. }
  1346. Module["addOnInit"] = addOnInit;
  1347. function addOnPreMain(cb) {
  1348. __ATMAIN__.unshift(cb);
  1349. }
  1350. Module["addOnPreMain"] = addOnPreMain;
  1351. function addOnExit(cb) {
  1352. __ATEXIT__.unshift(cb);
  1353. }
  1354. Module["addOnExit"] = addOnExit;
  1355. function addOnPostRun(cb) {
  1356. __ATPOSTRUN__.unshift(cb);
  1357. }
  1358. Module["addOnPostRun"] = addOnPostRun;
  1359. // Tools
  1360. function intArrayFromString(stringy, dontAddNull, length /* optional */) {
  1361. var len = length > 0 ? length : lengthBytesUTF8(stringy)+1;
  1362. var u8array = new Array(len);
  1363. var numBytesWritten = stringToUTF8Array(stringy, u8array, 0, u8array.length);
  1364. if (dontAddNull) u8array.length = numBytesWritten;
  1365. return u8array;
  1366. }
  1367. Module["intArrayFromString"] = intArrayFromString;
  1368. function intArrayToString(array) {
  1369. var ret = [];
  1370. for (var i = 0; i < array.length; i++) {
  1371. var chr = array[i];
  1372. if (chr > 0xFF) {
  1373. assert(false, 'Character code ' + chr + ' (' + String.fromCharCode(chr) + ') at offset ' + i + ' not in 0x00-0xFF.');
  1374. chr &= 0xFF;
  1375. }
  1376. ret.push(String.fromCharCode(chr));
  1377. }
  1378. return ret.join('');
  1379. }
  1380. Module["intArrayToString"] = intArrayToString;
  1381. // Deprecated: This function should not be called because it is unsafe and does not provide
  1382. // a maximum length limit of how many bytes it is allowed to write. Prefer calling the
  1383. // function stringToUTF8Array() instead, which takes in a maximum length that can be used
  1384. // to be secure from out of bounds writes.
  1385. function writeStringToMemory(string, buffer, dontAddNull) {
  1386. Runtime.warnOnce('writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!');
  1387. var lastChar, end;
  1388. if (dontAddNull) {
  1389. // stringToUTF8Array always appends null. If we don't want to do that, remember the
  1390. // character that existed at the location where the null will be placed, and restore
  1391. // that after the write (below).
  1392. end = buffer + lengthBytesUTF8(string);
  1393. lastChar = HEAP8[end];
  1394. }
  1395. stringToUTF8(string, buffer, Infinity);
  1396. if (dontAddNull) HEAP8[end] = lastChar; // Restore the value under the null character.
  1397. }
  1398. Module["writeStringToMemory"] = writeStringToMemory;
  1399. function writeArrayToMemory(array, buffer) {
  1400. assert(array.length >= 0, 'writeArrayToMemory array must have a length (should be an array or typed array)')
  1401. HEAP8.set(array, buffer);
  1402. }
  1403. Module["writeArrayToMemory"] = writeArrayToMemory;
  1404. function writeAsciiToMemory(str, buffer, dontAddNull) {
  1405. for (var i = 0; i < str.length; ++i) {
  1406. assert(str.charCodeAt(i) === str.charCodeAt(i)&0xff);
  1407. HEAP8[((buffer++)>>0)]=str.charCodeAt(i);
  1408. }
  1409. // Null-terminate the pointer to the HEAP.
  1410. if (!dontAddNull) HEAP8[((buffer)>>0)]=0;
  1411. }
  1412. Module["writeAsciiToMemory"] = writeAsciiToMemory;
  1413. function unSign(value, bits, ignore) {
  1414. if (value >= 0) {
  1415. return value;
  1416. }
  1417. return bits <= 32 ? 2*Math.abs(1 << (bits-1)) + value // Need some trickery, since if bits == 32, we are right at the limit of the bits JS uses in bitshifts
  1418. : Math.pow(2, bits) + value;
  1419. }
  1420. function reSign(value, bits, ignore) {
  1421. if (value <= 0) {
  1422. return value;
  1423. }
  1424. var half = bits <= 32 ? Math.abs(1 << (bits-1)) // abs is needed if bits == 32
  1425. : Math.pow(2, bits-1);
  1426. if (value >= half && (bits <= 32 || value > half)) { // for huge values, we can hit the precision limit and always get true here. so don't do that
  1427. // but, in general there is no perfect solution here. With 64-bit ints, we get rounding and errors
  1428. // TODO: In i64 mode 1, resign the two parts separately and safely
  1429. value = -2*half + value; // Cannot bitshift half, as it may be at the limit of the bits JS uses in bitshifts
  1430. }
  1431. return value;
  1432. }
  1433. // check for imul support, and also for correctness ( https://bugs.webkit.org/show_bug.cgi?id=126345 )
  1434. if (!Math['imul'] || Math['imul'](0xffffffff, 5) !== -5) Math['imul'] = function imul(a, b) {
  1435. var ah = a >>> 16;
  1436. var al = a & 0xffff;
  1437. var bh = b >>> 16;
  1438. var bl = b & 0xffff;
  1439. return (al*bl + ((ah*bl + al*bh) << 16))|0;
  1440. };
  1441. Math.imul = Math['imul'];
  1442. if (!Math['clz32']) Math['clz32'] = function(x) {
  1443. x = x >>> 0;
  1444. for (var i = 0; i < 32; i++) {
  1445. if (x & (1 << (31 - i))) return i;
  1446. }
  1447. return 32;
  1448. };
  1449. Math.clz32 = Math['clz32']
  1450. if (!Math['trunc']) Math['trunc'] = function(x) {
  1451. return x < 0 ? Math.ceil(x) : Math.floor(x);
  1452. };
  1453. Math.trunc = Math['trunc'];
  1454. var Math_abs = Math.abs;
  1455. var Math_cos = Math.cos;
  1456. var Math_sin = Math.sin;
  1457. var Math_tan = Math.tan;
  1458. var Math_acos = Math.acos;
  1459. var Math_asin = Math.asin;
  1460. var Math_atan = Math.atan;
  1461. var Math_atan2 = Math.atan2;
  1462. var Math_exp = Math.exp;
  1463. var Math_log = Math.log;
  1464. var Math_sqrt = Math.sqrt;
  1465. var Math_ceil = Math.ceil;
  1466. var Math_floor = Math.floor;
  1467. var Math_pow = Math.pow;
  1468. var Math_imul = Math.imul;
  1469. var Math_fround = Math.fround;
  1470. var Math_round = Math.round;
  1471. var Math_min = Math.min;
  1472. var Math_clz32 = Math.clz32;
  1473. var Math_trunc = Math.trunc;
  1474. // A counter of dependencies for calling run(). If we need to
  1475. // do asynchronous work before running, increment this and
  1476. // decrement it. Incrementing must happen in a place like
  1477. // PRE_RUN_ADDITIONS (used by emcc to add file preloading).
  1478. // Note that you can add dependencies in preRun, even though
  1479. // it happens right before run - run will be postponed until
  1480. // the dependencies are met.
  1481. var runDependencies = 0;
  1482. var runDependencyWatcher = null;
  1483. var dependenciesFulfilled = null; // overridden to take different actions when all run dependencies are fulfilled
  1484. var runDependencyTracking = {};
  1485. function getUniqueRunDependency(id) {
  1486. var orig = id;
  1487. while (1) {
  1488. if (!runDependencyTracking[id]) return id;
  1489. id = orig + Math.random();
  1490. }
  1491. return id;
  1492. }
  1493. function addRunDependency(id) {
  1494. runDependencies++;
  1495. if (Module['monitorRunDependencies']) {
  1496. Module['monitorRunDependencies'](runDependencies);
  1497. }
  1498. if (id) {
  1499. assert(!runDependencyTracking[id]);
  1500. runDependencyTracking[id] = 1;
  1501. if (runDependencyWatcher === null && typeof setInterval !== 'undefined') {
  1502. // Check for missing dependencies every few seconds
  1503. runDependencyWatcher = setInterval(function() {
  1504. if (ABORT) {
  1505. clearInterval(runDependencyWatcher);
  1506. runDependencyWatcher = null;
  1507. return;
  1508. }
  1509. var shown = false;
  1510. for (var dep in runDependencyTracking) {
  1511. if (!shown) {
  1512. shown = true;
  1513. Module.printErr('still waiting on run dependencies:');
  1514. }
  1515. Module.printErr('dependency: ' + dep);
  1516. }
  1517. if (shown) {
  1518. Module.printErr('(end of list)');
  1519. }
  1520. }, 10000);
  1521. }
  1522. } else {
  1523. Module.printErr('warning: run dependency added without ID');
  1524. }
  1525. }
  1526. Module["addRunDependency"] = addRunDependency;
  1527. function removeRunDependency(id) {
  1528. runDependencies--;
  1529. if (Module['monitorRunDependencies']) {
  1530. Module['monitorRunDependencies'](runDependencies);
  1531. }
  1532. if (id) {
  1533. assert(runDependencyTracking[id]);
  1534. delete runDependencyTracking[id];
  1535. } else {
  1536. Module.printErr('warning: run dependency removed without ID');
  1537. }
  1538. if (runDependencies == 0) {
  1539. if (runDependencyWatcher !== null) {
  1540. clearInterval(runDependencyWatcher);
  1541. runDependencyWatcher = null;
  1542. }
  1543. if (dependenciesFulfilled) {
  1544. var callback = dependenciesFulfilled;
  1545. dependenciesFulfilled = null;
  1546. callback(); // can add another dependenciesFulfilled
  1547. }
  1548. }
  1549. }
  1550. Module["removeRunDependency"] = removeRunDependency;
  1551. Module["preloadedImages"] = {}; // maps url to image data
  1552. Module["preloadedAudios"] = {}; // maps url to audio data
  1553. var memoryInitializer = null;
  1554. // === Body ===
  1555. var ASM_CONSTS = [function($0, $1) { { Module.printErr('bad name in getProcAddress: ' + [Pointer_stringify($0), Pointer_stringify($1)]); } }];
  1556. function _emscripten_asm_const_iii(code, a0, a1) {
  1557. return ASM_CONSTS[code](a0, a1);
  1558. }
  1559. STATIC_BASE = 8;
  1560. STATICTOP = STATIC_BASE + 26512;
  1561. /* global initializers */ __ATINIT__.push();
  1562. /* memory initializer */ allocate([32,3,0,0,194,1,0,0,255,255,255,255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,0,32,0,0,176,1,0,0,0,0,0,0,0,0,0,32,37,249,142,0,10,2,0,0,128,190,125,95,244,125,31,160,242,43,74,30,9,82,8,0,64,34,65,80,20,4,16,32,32,41,46,18,8,34,8,0,32,34,65,80,20,4,16,32,32,249,16,76,8,250,62,60,16,34,125,222,247,125,16,32,32,161,232,50,8,34,8,0,8,34,5,16,4,69,16,0,240,163,164,50,8,82,8,0,4,34,5,16,4,69,16,32,32,249,226,94,8,2,0,129,2,62,125,31,244,125,16,0,0,32,0,0,176,1,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,190,15,0,192,15,224,247,251,125,126,191,95,232,190,80,0,162,8,8,68,232,47,20,10,133,2,129,80,72,160,80,0,162,40,228,73,40,40,20,10,132,2,129,64,72,160,72,0,190,15,2,16,175,235,247,9,132,62,159,216,79,160,71,0,34,136,228,9,161,42,20,10,132,2,129,80,72,160,72,0,34,40,8,4,160,47,20,10,133,2,129,80,72,162,80,0,190,143,0,0,33,32,244,251,125,126,129,95,232,156,208,7,0,128,0,0,224,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,1,12,0,130,66,191,223,239,247,251,11,5,5,133,66,191,4,72,0,198,66,161,80,40,20,64,8,5,37,133,66,160,8,168,0,170,70,161,80,40,20,64,8,5,37,133,66,144,16,8,0,146,74,161,95,232,247,67,8,5,37,121,126,136,32,8,0,130,82,161,64,40,1,66,8,137,36,133,64,132,64,8,0,130,98,161,64,42,2,66,8,81,36,133,64,130,128,8,0,130,66,191,192,47,244,67,248,33,252,133,126,191,0,9,62,0,0,0,0,4,0,0,0,0,0,0,0,128,1,12,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,0,4,0,32,72,65,0,0,0,0,0,8,0,0,4,4,0,4,60,32,0,65,0,0,0,0,0,8,0,0,240,125,223,247,133,239,75,81,190,239,251,190,239,59,81,4,0,69,65,20,133,40,74,73,170,40,138,162,32,8,81,4,240,69,65,244,157,40,74,71,170,40,138,162,224,11,81,4,16,69,65,20,132,40,74,73,170,40,138,162,0,10,145,2,240,125,223,247,133,47,74,209,170,232,251,190,224,123,31,1,0,0,0,0,4,8,64,0,0,0,8,32,0,0,0,0,0,0,0,0,132,15,96,0,0,0,8,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,172,1,15,0,0,0,0,0,0,0,0,0,0,0,0,0,36,1,9,0,0,0,0,0,0,0,0,0,6,0,0,0,36,1,9,0,0,0,0,0,0,0,128,16,9,162,40,250,36,1,9,0,0,0,0,0,0,0,0,62,1,42,37,66,34,82,9,0,0,0,0,0,0,0,128,138,3,42,34,34,36,41,9,0,0,0,0,0,0,0,128,10,1,42,37,18,36,1,9,0,0,0,0,0,0,0,128,10,1,190,232,251,36,1,9,0,0,0,0,0,0,0,128,190,14,0,0,2,172,1,15,0,0,0,0,0,0,0,128,4,0,0,224,3,0,0,0,0,0,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,56,0,0,0,14,184,67,132,3,58,32,0,128,160,190,2,32,0,0,240,138,32,82,196,2,43,32,4,34,145,2,248,59,0,240,7,142,56,75,228,2,58,32,2,28,138,30,8,42,233,17,4,224,11,66,244,2,130,36,1,20,4,20,232,186,4,209,5,128,184,195,231,10,58,137,0,28,14,60,40,2,9,80,4,128,0,64,196,2,128,68,0,34,132,32,232,2,0,80,4,0,0,64,128,2,0,32,5,0,142,62,8,2,0,16,4,224,3,64,128,66,0,0,7,0,132,0,248,3,0,240,7,0,0,64,128,34,0,0,4,0,0,0,0,0,0,0,0,0,0,64,128,2,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,7,128,0,194,160,72,24,0,0,1,132,33,9,146,2,66,38,4,1,33,81,0,0,127,63,2,66,2,16,41,0,34,20,192,239,247,251,253,126,9,161,223,239,247,187,187,3,18,15,68,40,20,10,133,66,9,129,64,32,16,16,17,1,8,4,68,40,20,10,133,66,127,129,64,32,16,16,17,1,4,130,199,239,247,251,253,126,9,129,207,231,243,17,17,1,50,169,80,40,20,10,133,66,9,161,64,32,16,16,17,1,64,184,80,40,20,10,133,66,121,191,223,239,247,187,187,3,32,160,31,0,0,0,0,0,0,16,0,0,0,0,0,0,112,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,40,2,8,131,34,1,0,2,8,67,2,1,0,1,1,124,20,4,132,68,1,0,32,4,132,4,128,8,63,130,0,132,66,191,223,239,247,3,126,161,80,40,20,10,33,0,0,132,70,161,80,40,20,138,82,161,80,40,20,122,161,239,3,158,74,161,80,40,20,82,82,161,80,40,20,74,31,8,2,132,82,161,80,40,20,34,74,161,80,40,244,75,161,239,3,132,98,161,80,40,20,82,74,161,80,40,4,122,161,40,2,124,66,191,223,239,247,139,126,191,223,239,247,11,189,239,3,0,0,0,0,0,0,0,4,0,0,0,0,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,5,32,0,0,4,132,0,34,129,69,17,16,66,1,0,148,66,81,0,0,8,66,81,148,42,162,32,8,165,80,0,0,0,32,0,0,0,0,0,0,0,5,0,0,0,0,8,190,239,251,254,251,190,239,251,20,145,235,251,190,239,251,0,32,8,130,32,10,162,40,138,20,145,40,138,162,40,138,62,190,239,251,254,11,190,239,251,20,145,40,138,162,40,138,0,162,40,138,34,8,130,32,8,20,145,40,138,162,40,138,8,190,239,251,254,251,190,239,251,20,145,47,250,190,239,251,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,33,0,4,0,0,0,0,0,0,0,0,0,0,0,0,130,80,20,2,20,0,0,0,0,0,0,0,0,0,0,16,0,0,0,32,0,0,0,0,0,0,0,0,0,0,0,190,40,138,162,40,34,0,0,0,0,0,0,0,0,0,0,170,40,138,162,232,34,0,0,0,0,0,0,0,0,0,0,170,40,138,162,168,34,0,0,0,0,0,0,0,0,0,0,170,40,138,162,232,34,0,0,0,0,0,0,0,0,0,0,190,239,251,190,47,62,0,0,0,0,0,0,0,0,0,0,4,0,0,0,40,32,0,0,0,0,0,0,0,0,0,0,0,0,0,128,15,62,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,0,0,0,1,0,0,0,4,0,0,0,6,0,0,0,5,0,0,0,7,0,0,0,6,0,0,0,2,0,0,0,3,0,0,0,3,0,0,0,5,0,0,0,5,0,0,0,2,0,0,0,4,0,0,0,1,0,0,0,7,0,0,0,5,0,0,0,2,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,1,0,0,0,1,0,0,0,3,0,0,0,4,0,0,0,3,0,0,0,6,0,0,0,7,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,3,0,0,0,5,0,0,0,6,0,0,0,5,0,0,0,7,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,7,0,0,0,6,0,0,0,7,0,0,0,7,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,2,0,0,0,7,0,0,0,2,0,0,0,3,0,0,0,5,0,0,0,2,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,4,0,0,0,5,0,0,0,5,0,0,0,1,0,0,0,2,0,0,0,5,0,0,0,2,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,4,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,3,0,0,0,1,0,0,0,3,0,0,0,4,0,0,0,4,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,7,0,0,0,1,0,0,0,5,0,0,0,3,0,0,0,7,0,0,0,3,0,0,0,5,0,0,0,4,0,0,0,1,0,0,0,7,0,0,0,4,0,0,0,3,0,0,0,5,0,0,0,3,0,0,0,3,0,0,0,2,0,0,0,5,0,0,0,6,0,0,0,1,0,0,0,2,0,0,0,2,0,0,0,3,0,0,0,5,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,7,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,3,0,0,0,3,0,0,0,3,0,0,0,3,0,0,0,7,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,5,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,6,0,0,0,4,0,0,0,6,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,9,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,2,0,0,0,2,0,0,0,3,0,0,0,3,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,3,0,0,0,5,0,0,0,255,255,255,255,0,1,0,0,255,255,255,255,0,0,128,191,0,0,0,0,4,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,8,0,0,0,8,0,0,0,4,0,0,0,4,0,0,0,2,0,0,0,2,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,4,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,1,0,0,0,8,0,0,0,8,0,0,0,8,0,0,0,4,0,0,0,4,0,0,0,2,0,0,0,2,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,2,0,0,0,2,0,0,0,3,0,0,0,3,0,0,0,4,0,0,0,4,0,0,0,4,0,0,0,5,0,0,0,4,0,0,0,0,0,0,0,48,98,159,57,21,31,31,58,45,208,110,58,21,31,159,58,161,247,198,58,159,174,238,58,150,67,11,59,21,31,31,59,91,11,51,59,218,230,70,59,88,89,91,59,211,249,112,59,38,228,131,59,97,226,143,59,97,136,156,59,196,205,169,59,38,170,183,59,177,54,198,59,158,98,213,59,80,54,229,59,44,186,245,59,231,114,3,60,204,96,12,60,198,166,21,60,212,68,31,60,41,63,41,60,146,145,51,60,66,64,62,60,56,75,73,60,166,182,84,60,90,126,96,60,135,166,108,60,43,47,121,60,11,10,131,60,213,174,137,60,245,133,144,60,80,141,151,60,0,199,158,60,30,53,166,60,120,211,173,60,64,166,181,60,92,171,189,60,255,230,197,60,248,84,206,60,94,247,214,60,74,208,223,60,165,221,232,60,134,33,242,60,212,153,251,60,97,165,2,61,28,153,7,61,26,168,12,61,91,210,17,61,236,24,23,61,204,123,28,61,253,250,33,61,125,150,39,61,77,78,45,61,121,35,51,61,245,20,57,61,205,35,63,61,1,80,69,61,145,153,75,61,113,255,81,61,199,132,88,61,108,38,95,61,121,230,101,61,240,196,108,61,206,193,115,61,22,221,122,61,99,11,129,61,111,183,132,61,54,115,136,61,50,62,140,61,231,24,144,61,88,3,148,61,130,253,151,61,226,6,156,61,129,32,160,61,98,74,164,61,253,131,168,61,83,205,172,61,233,38,177,61,71,145,181,61,95,11,186,61,184,149,190,61,81,48,195,61,177,219,199,61,217,151,204,61,65,100,209,61,234,64,214,61,224,46,219,61,157,45,224,61,155,60,229,61,230,92,234,61,126,142,239,61,87,208,244,61,3,36,250,61,118,136,255,61,27,127,2,62,95,66,5,62,141,14,8,62,97,227,10,62,30,193,13,62,63,167,16,62,74,150,19,62,63,142,22,62,29,143,25,62,162,152,28,62,17,171,31,62,172,198,34,62,238,234,37,62,93,24,41,62,181,78,44,62,59,142,47,62,170,214,50,62,70,40,54,62,14,131,57,62,4,231,60,62,38,84,64,62,117,202,67,62,241,73,71,62,154,210,74,62,178,100,78,62,59,0,82,62,240,164,85,62,21,83,89,62,170,10,93,62,108,203,96,62,225,149,100,62,198,105,104,62,27,71,108,62,35,46,112,62,155,30,116,62,131,24,120,62,29,28,124,62,182,20,128,62,54,32,130,62,144,48,132,62,195,69,134,62,208,95,136,62,183,126,138,62,119,162,140,62,50,203,142,62,232,248,144,62,119,43,147,62,2,99,149,62,102,159,151,62,231,224,153,62,66,39,156,62,185,114,158,62,43,195,160,62,152,24,163,62,0,115,165,62,133,210,167,62,38,55,170,62,195,160,172,62,90,15,175,62,48,131,177,62,34,252,179,62,16,122,182,62,59,253,184,62,131,133,187,62,232,18,190,62,106,165,192,62,41,61,195,62,39,218,197,62,66,124,200,62,121,35,203,62,15,208,205,62,195,129,208,62,214,56,211,62,6,245,213,62,149,182,216,62,99,125,219,62,111,73,222,62,185,26,225,62,99,241,227,62,108,205,230,62,180,174,233,62,91,149,236,62,98,129,239,62,201,114,242,62,110,105,245,62,149,101,248,62,27,103,251,62,1,110,254,62,52,189,0,63,6,70,2,63,171,209,3,63,254,95,5,63,2,241,6,63,199,132,8,63,92,27,10,63,162,180,11,63,152,80,13,63,95,239,14,63,247,144,16,63,63,53,18,63,89,220,19,63,35,134,21,63,207,50,23,63,59,226,24,63,104,148,26,63,119,73,28,63,71,1,30,63,216,187,31,63,74,121,33,63,143,57,35,63,164,252,36,63,139,194,38,63,68,139,40,63,205,86,42,63,57,37,44,63,136,246,45,63,151,202,47,63,152,161,49,63,108,123,51,63,33,88,53,63,185,55,55,63,34,26,57,63,126,255,58,63,188,231,60,63,204,210,62,63,207,192,64,63,196,177,66,63,139,165,68,63,69,156,70,63,242,149,72,63,129,146,74,63,4,146,76,63,104,148,78,63,208,153,80,63,26,162,82,63,88,173,84,63,136,187,86,63,171,204,88,63,210,224,90,63,219,247,92,63,232,17,95,63,232,46,97,63,236,78,99,63,227,113,101,63,221,151,103,63,219,192,105,63,204,236,107,63,193,27,110,63,186,77,112,63,182,130,114,63,182,186,116,63,169,245,118,63,177,51,121,63,205,116,123,63,220,184,125,63,0,0,128,63,13,0,115,0,13,0,122,0,13,0,128,0,13,0,135,0,13,0,141,0,13,0,148,0,13,0,154,0,13,0,161,0,26,0,167,0,26,0,180,0,26,0,193,0,26,0,206,0,26,0,218,0,26,0,231,0,26,0,244,0,26,0,1,1,51,0,14,1,51,0,40,1,51,0,65,1,51,0,91,1,51,0,117,1,51,0,143,1,51,0,168,1,51,0,194,1,103,0,220,1,103,0,15,2,103,0,67,2,103,0,118,2,103,0,170,2,103,0,221,2,103,0,17,3,103,0,68,3,206,0,120,3,206,0,223,3,206,0,70,4,206,0,173,4,206,0,20,5,197,0,123,5,188,0,221,5,181,0,59,6,88,1,151,6,66,1,66,7,48,1,227,7,32,1,123,8,18,1,11,9,6,1,148,9,252,0,23,10,242,0,149,10,203,1,15,11,174,1,244,11,149,1,203,12,128,1,149,13,110,1,86,14,94,1,13,15,80,1,188,15,67,1,99,16,100,2,7,17,62,2,56,18,29,2,87,19,1,2,102,20,233,1,102,21,211,1,90,22,192,1,68,23,175,1,36,24,49,3,254,24,254,2,150,26,210,2,21,28,173,2,126,29,141,2,212,30,112,2,26,32,86,2,82,33,64,2,125,34,67,4,159,35,254,3,192,37,196,3,191,39,146,3,161,41,103,3,106,43,65,3,29,45,31,3,190,46,0,3,77,48,176,5,209,49,85,5,168,52,7,5,82,55,197,4,213,57,139,4,55,60,88,4,124,62,42,4,168,64,1,4,189,66,152,7,194,68,30,7,142,72,182,6,28,76,93,6,118,79,16,6,165,82,204,5,172,85,143,5,146,88,89,5,89,91,35,10,12,94,128,9,28,99,246,8,219,103,127,8,85,108,24,8,148,112,189,7,160,116,108,7,125,120,35,7,51,124,1,1,0,0,1,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,3,0,0,0,3,0,0,0,3,0,0,0,3,0,0,0,4,0,0,0,4,0,0,0,4,0,0,0,4,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,0,0,0,4,0,0,0,5,0,0,0,6,0,0,0,7,0,0,0,8,0,0,0,9,0,0,0,10,0,0,0,11,0,0,0,13,0,0,0,15,0,0,0,17,0,0,0,19,0,0,0,23,0,0,0,27,0,0,0,31,0,0,0,35,0,0,0,43,0,0,0,51,0,0,0,59,0,0,0,67,0,0,0,83,0,0,0,99,0,0,0,115,0,0,0,131,0,0,0,163,0,0,0,195,0,0,0,227,0,0,0,2,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,2,0,0,0,2,0,0,0,3,0,0,0,3,0,0,0,4,0,0,0,4,0,0,0,5,0,0,0,5,0,0,0,6,0,0,0,6,0,0,0,7,0,0,0,7,0,0,0,8,0,0,0,8,0,0,0,9,0,0,0,9,0,0,0,10,0,0,0,10,0,0,0,11,0,0,0,11,0,0,0,12,0,0,0,12,0,0,0,13,0,0,0,13,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,2,0,0,0,3,0,0,0,4,0,0,0,5,0,0,0,7,0,0,0,9,0,0,0,13,0,0,0,17,0,0,0,25,0,0,0,33,0,0,0,49,0,0,0,65,0,0,0,97,0,0,0,129,0,0,0,193,0,0,0,1,1,0,0,129,1,0,0,1,2,0,0,1,3,0,0,1,4,0,0,1,6,0,0,1,8,0,0,1,12,0,0,1,16,0,0,1,24,0,0,1,32,0,0,1,48,0,0,1,64,0,0,1,96,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,104,92,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,236,20,0,0,5,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,3,0,0,0,143,99,0,0,0,4,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,10,255,255,255,255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,236,20,0,0,114,97,121,108,105,98,32,91,116,101,120,116,117,114,101,115,93,32,101,120,97,109,112,108,101,32,45,32,105,109,97,103,101,32,100,114,97,119,105,110,103,0,114,101,115,111,117,114,99,101,115,47,99,97,116,46,112,110,103,0,114,101,115,111,117,114,99,101,115,47,112,97,114,114,111,116,115,46,112,110,103,0,87,101,32,97,114,101,32,100,114,97,119,105,110,103,32,111,110,108,121,32,111,110,101,32,116,101,120,116,117,114,101,32,102,114,111,109,32,118,97,114,105,111,117,115,32,105,109,97,103,101,115,32,99,111,109,112,111,115,101,100,33,0,83,111,117,114,99,101,32,105,109,97,103,101,115,32,104,97,118,101,32,98,101,101,110,32,99,114,111,112,112,101,100,44,32,115,99,97,108,101,100,44,32,102,108,105,112,112,101,100,32,97,110,100,32,99,111,112,105,101,100,32,111,110,101,32,111,118,101,114,32,116,104,101,32,111,116,104,101,114,46,0,73,110,105,116,105,97,108,105,122,105,110,103,32,114,97,121,108,105,98,32,40,118,49,46,55,46,48,41,0,35,99,97,110,118,97,115,0,84,97,114,103,101,116,32,116,105,109,101,32,112,101,114,32,102,114,97,109,101,58,32,37,48,50,46,48,51,102,32,109,105,108,108,105,115,101,99,111,110,100,115,0,69,115,99,97,112,101,0,67,97,110,118,97,115,32,115,99,97,108,101,100,32,116,111,32,102,117,108,108,115,99,114,101,101,110,46,32,69,108,101,109,101,110,116,83,105,122,101,58,32,40,37,105,120,37,105,41,44,32,83,99,114,101,101,110,83,105,122,101,40,37,105,120,37,105,41,0,67,97,110,118,97,115,32,115,99,97,108,101,100,32,116,111,32,119,105,110,100,111,119,101,100,46,32,69,108,101,109,101,110,116,83,105,122,101,58,32,40,37,105,120,37,105,41,44,32,83,99,114,101,101,110,83,105,122,101,40,37,105,120,37,105,41,0,91,84,69,88,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,102,111,110,116,32,108,111,97,100,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,68,88,84,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,32,102,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,69,84,67,49,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,32,102,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,69,84,67,50,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,32,102,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,80,86,82,84,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,32,102,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,65,83,84,67,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,32,102,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,84,101,120,116,117,114,101,32,102,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,91,84,69,88,32,73,68,32,37,105,93,32,84,101,120,116,117,114,101,32,99,114,101,97,116,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,37,105,120,37,105,41,0,84,101,120,116,117,114,101,32,99,111,117,108,100,32,110,111,116,32,98,101,32,99,114,101,97,116,101,100,0,73,109,97,103,101,32,100,97,116,97,32,102,111,114,109,97,116,32,105,115,32,99,111,109,112,114,101,115,115,101,100,44,32,99,97,110,32,110,111,116,32,98,101,32,99,111,110,118,101,114,116,101,100,0,70,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,32,102,111,114,32,112,105,120,101,108,32,100,97,116,97,32,114,101,116,114,105,101,118,97,108,0,70,97,105,108,101,100,32,116,111,32,105,110,105,116,105,97,108,105,122,101,32,71,76,70,87,0,84,114,121,105,110,103,32,116,111,32,101,110,97,98,108,101,32,77,83,65,65,32,120,52,0,67,108,111,115,101,115,116,32,102,117,108,108,115,99,114,101,101,110,32,118,105,100,101,111,109,111,100,101,58,32,37,105,32,120,32,37,105,0,71,76,70,87,32,70,97,105,108,101,100,32,116,111,32,105,110,105,116,105,97,108,105,122,101,32,87,105,110,100,111,119,0,68,105,115,112,108,97,121,32,100,101,118,105,99,101,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,82,101,110,100,101,114,32,115,105,122,101,58,32,37,105,32,120,32,37,105,0,83,99,114,101,101,110,32,115,105,122,101,58,32,37,105,32,120,32,37,105,0,86,105,101,119,112,111,114,116,32,111,102,102,115,101,116,115,58,32,37,105,44,32,37,105,0,84,114,121,105,110,103,32,116,111,32,101,110,97,98,108,101,32,86,83,89,78,67,0,71,80,85,58,32,86,101,110,100,111,114,58,32,32,32,37,115,0,71,80,85,58,32,82,101,110,100,101,114,101,114,58,32,37,115,0,71,80,85,58,32,86,101,114,115,105,111,110,58,32,32,37,115,0,71,80,85,58,32,71,76,83,76,58,32,32,32,32,32,37,115,0,32,0,78,117,109,98,101,114,32,111,102,32,115,117,112,112,111,114,116,101,100,32,101,120,116,101,110,115,105,111,110,115,58,32,37,105,0,71,76,95,79,69,83,95,118,101,114,116,101,120,95,97,114,114,97,121,95,111,98,106,101,99,116,0,103,108,71,101,110,86,101,114,116,101,120,65,114,114,97,121,115,79,69,83,0,103,108,66,105,110,100,86,101,114,116,101,120,65,114,114,97,121,79,69,83,0,103,108,68,101,108,101,116,101,86,101,114,116,101,120,65,114,114,97,121,115,79,69,83,0,71,76,95,79,69,83,95,116,101,120,116,117,114,101,95,110,112,111,116,0,71,76,95,69,88,84,95,116,101,120,116,117,114,101,95,99,111,109,112,114,101,115,115,105,111,110,95,115,51,116,99,0,71,76,95,87,69,66,71,76,95,99,111,109,112,114,101,115,115,101,100,95,116,101,120,116,117,114,101,95,115,51,116,99,0,71,76,95,87,69,66,75,73,84,95,87,69,66,71,76,95,99,111,109,112,114,101,115,115,101,100,95,116,101,120,116,117,114,101,95,115,51,116,99,0,71,76,95,79,69,83,95,99,111,109,112,114,101,115,115,101,100,95,69,84,67,49,95,82,71,66,56,95,116,101,120,116,117,114,101,0,71,76,95,87,69,66,71,76,95,99,111,109,112,114,101,115,115,101,100,95,116,101,120,116,117,114,101,95,101,116,99,49,0,71,76,95,65,82,66,95,69,83,51,95,99,111,109,112,97,116,105,98,105,108,105,116,121,0,71,76,95,73,77,71,95,116,101,120,116,117,114,101,95,99,111,109,112,114,101,115,115,105,111,110,95,112,118,114,116,99,0,71,76,95,75,72,82,95,116,101,120,116,117,114,101,95,99,111,109,112,114,101,115,115,105,111,110,95,97,115,116,99,95,104,100,114,0,71,76,95,69,88,84,95,116,101,120,116,117,114,101,95,102,105,108,116,101,114,95,97,110,105,115,111,116,114,111,112,105,99,0,71,76,95,69,88,84,95,116,101,120,116,117,114,101,95,109,105,114,114,111,114,95,99,108,97,109,112,0,91,69,88,84,69,78,83,73,79,78,93,32,86,65,79,32,101,120,116,101,110,115,105,111,110,32,100,101,116,101,99,116,101,100,44,32,86,65,79,32,102,117,110,99,116,105,111,110,115,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,91,69,88,84,69,78,83,73,79,78,93,32,86,65,79,32,101,120,116,101,110,115,105,111,110,32,110,111,116,32,102,111,117,110,100,44,32,86,65,79,32,117,115,97,103,101,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,91,69,88,84,69,78,83,73,79,78,93,32,78,80,79,84,32,116,101,120,116,117,114,101,115,32,101,120,116,101,110,115,105,111,110,32,100,101,116,101,99,116,101,100,44,32,102,117,108,108,32,78,80,79,84,32,116,101,120,116,117,114,101,115,32,115,117,112,112,111,114,116,101,100,0,91,69,88,84,69,78,83,73,79,78,93,32,78,80,79,84,32,116,101,120,116,117,114,101,115,32,101,120,116,101,110,115,105,111,110,32,110,111,116,32,102,111,117,110,100,44,32,108,105,109,105,116,101,100,32,78,80,79,84,32,115,117,112,112,111,114,116,32,40,110,111,45,109,105,112,109,97,112,115,44,32,110,111,45,114,101,112,101,97,116,41,0,91,69,88,84,69,78,83,73,79,78,93,32,68,88,84,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,115,32,115,117,112,112,111,114,116,101,100,0,91,69,88,84,69,78,83,73,79,78,93,32,69,84,67,49,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,115,32,115,117,112,112,111,114,116,101,100,0,91,69,88,84,69,78,83,73,79,78,93,32,69,84,67,50,47,69,65,67,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,115,32,115,117,112,112,111,114,116,101,100,0,91,69,88,84,69,78,83,73,79,78,93,32,80,86,82,84,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,115,32,115,117,112,112,111,114,116,101,100,0,91,69,88,84,69,78,83,73,79,78,93,32,65,83,84,67,32,99,111,109,112,114,101,115,115,101,100,32,116,101,120,116,117,114,101,115,32,115,117,112,112,111,114,116,101,100,0,91,69,88,84,69,78,83,73,79,78,93,32,65,110,105,115,111,116,114,111,112,105,99,32,116,101,120,116,117,114,101,115,32,102,105,108,116,101,114,105,110,103,32,115,117,112,112,111,114,116,101,100,32,40,109,97,120,58,32,37,46,48,102,88,41,0,91,69,88,84,69,78,83,73,79,78,93,32,67,108,97,109,112,32,109,105,114,114,111,114,32,119,114,97,112,32,116,101,120,116,117,114,101,32,109,111,100,101,32,115,117,112,112,111,114,116,101,100,0,91,84,69,88,32,73,68,32,37,105,93,32,66,97,115,101,32,119,104,105,116,101,32,116,101,120,116,117,114,101,32,108,111,97,100,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,66,97,115,101,32,119,104,105,116,101,32,116,101,120,116,117,114,101,32,99,111,117,108,100,32,110,111,116,32,98,101,32,108,111,97,100,101,100,0,79,112,101,110,71,76,32,100,101,102,97,117,108,116,32,115,116,97,116,101,115,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,91,67,80,85,93,32,68,101,102,97,117,108,116,32,98,117,102,102,101,114,115,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,108,105,110,101,115,44,32,116,114,105,97,110,103,108,101,115,44,32,113,117,97,100,115,41,0,91,86,65,79,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,98,117,102,102,101,114,115,32,86,65,79,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,108,105,110,101,115,41,0,91,86,66,79,32,73,68,32,37,105,93,91,86,66,79,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,98,117,102,102,101,114,115,32,86,66,79,115,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,108,105,110,101,115,41,0,91,86,65,79,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,98,117,102,102,101,114,115,32,86,65,79,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,116,114,105,97,110,103,108,101,115,41,0,91,86,66,79,32,73,68,32,37,105,93,91,86,66,79,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,98,117,102,102,101,114,115,32,86,66,79,115,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,116,114,105,97,110,103,108,101,115,41,0,91,86,65,79,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,98,117,102,102,101,114,115,32,86,65,79,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,113,117,97,100,115,41,0,91,86,66,79,32,73,68,32,37,105,93,91,86,66,79,32,73,68,32,37,105,93,91,86,66,79,32,73,68,32,37,105,93,91,86,66,79,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,98,117,102,102,101,114,115,32,86,66,79,115,32,105,110,105,116,105,97,108,105,122,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,113,117,97,100,115,41,0,35,118,101,114,115,105,111,110,32,49,48,48,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,97,116,116,114,105,98,117,116,101,32,118,101,99,51,32,118,101,114,116,101,120,80,111,115,105,116,105,111,110,59,32,32,32,32,32,10,97,116,116,114,105,98,117,116,101,32,118,101,99,50,32,118,101,114,116,101,120,84,101,120,67,111,111,114,100,59,32,32,32,32,32,10,97,116,116,114,105,98,117,116,101,32,118,101,99,52,32,118,101,114,116,101,120,67,111,108,111,114,59,32,32,32,32,32,32,32,32,10,118,97,114,121,105,110,103,32,118,101,99,50,32,102,114,97,103,84,101,120,67,111,111,114,100,59,32,32,32,32,32,32,32,32,32,10,118,97,114,121,105,110,103,32,118,101,99,52,32,102,114,97,103,67,111,108,111,114,59,32,32,32,32,32,32,32,32,32,32,32,32,10,117,110,105,102,111,114,109,32,109,97,116,52,32,109,118,112,77,97,116,114,105,120,59,32,32,32,32,32,32,32,32,32,32,32,32,10,118,111,105,100,32,109,97,105,110,40,41,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,123,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,32,32,32,32,102,114,97,103,84,101,120,67,111,111,114,100,32,61,32,118,101,114,116,101,120,84,101,120,67,111,111,114,100,59,32,10,32,32,32,32,102,114,97,103,67,111,108,111,114,32,61,32,118,101,114,116,101,120,67,111,108,111,114,59,32,32,32,32,32,32,32,10,32,32,32,32,103,108,95,80,111,115,105,116,105,111,110,32,61,32,109,118,112,77,97,116,114,105,120,42,118,101,99,52,40,118,101,114,116,101,120,80,111,115,105,116,105,111,110,44,32,49,46,48,41,59,32,10,125,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,0,35,118,101,114,115,105,111,110,32,49,48,48,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,112,114,101,99,105,115,105,111,110,32,109,101,100,105,117,109,112,32,102,108,111,97,116,59,32,32,32,32,32,32,32,32,32,32,32,10,118,97,114,121,105,110,103,32,118,101,99,50,32,102,114,97,103,84,101,120,67,111,111,114,100,59,32,32,32,32,32,32,32,32,32,10,118,97,114,121,105,110,103,32,118,101,99,52,32,102,114,97,103,67,111,108,111,114,59,32,32,32,32,32,32,32,32,32,32,32,32,10,117,110,105,102,111,114,109,32,115,97,109,112,108,101,114,50,68,32,116,101,120,116,117,114,101,48,59,32,32,32,32,32,32,32,32,10,117,110,105,102,111,114,109,32,118,101,99,52,32,99,111,108,68,105,102,102,117,115,101,59,32,32,32,32,32,32,32,32,32,32,32,10,118,111,105,100,32,109,97,105,110,40,41,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,123,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,32,32,32,32,118,101,99,52,32,116,101,120,101,108,67,111,108,111,114,32,61,32,116,101,120,116,117,114,101,50,68,40,116,101,120,116,117,114,101,48,44,32,102,114,97,103,84,101,120,67,111,111,114,100,41,59,32,10,32,32,32,32,103,108,95,70,114,97,103,67,111,108,111,114,32,61,32,116,101,120,101,108,67,111,108,111,114,42,99,111,108,68,105,102,102,117,115,101,42,102,114,97,103,67,111,108,111,114,59,32,32,32,32,32,32,10,125,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,10,0,91,83,72,68,82,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,115,104,97,100,101,114,32,108,111,97,100,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,91,83,72,68,82,32,73,68,32,37,105,93,32,68,101,102,97,117,108,116,32,115,104,97,100,101,114,32,99,111,117,108,100,32,110,111,116,32,98,101,32,108,111,97,100,101,100,0,118,101,114,116,101,120,80,111,115,105,116,105,111,110,0,118,101,114,116,101,120,84,101,120,67,111,111,114,100,0,118,101,114,116,101,120,84,101,120,67,111,111,114,100,50,0,118,101,114,116,101,120,78,111,114,109,97,108,0,118,101,114,116,101,120,84,97,110,103,101,110,116,0,118,101,114,116,101,120,67,111,108,111,114,0,109,118,112,77,97,116,114,105,120,0,99,111,108,68,105,102,102,117,115,101,0,99,111,108,65,109,98,105,101,110,116,0,99,111,108,83,112,101,99,117,108,97,114,0,116,101,120,116,117,114,101,48,0,116,101,120,116,117,114,101,49,0,116,101,120,116,117,114,101,50,0,91,86,83,72,68,82,32,73,68,32,37,105,93,32,70,97,105,108,101,100,32,116,111,32,99,111,109,112,105,108,101,32,118,101,114,116,101,120,32,115,104,97,100,101,114,46,46,46,0,37,115,0,91,86,83,72,68,82,32,73,68,32,37,105,93,32,86,101,114,116,101,120,32,115,104,97,100,101,114,32,99,111,109,112,105,108,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,91,70,83,72,68,82,32,73,68,32,37,105,93,32,70,97,105,108,101,100,32,116,111,32,99,111,109,112,105,108,101,32,102,114,97,103,109,101,110,116,32,115,104,97,100,101,114,46,46,46,0,91,70,83,72,68,82,32,73,68,32,37,105,93,32,70,114,97,103,109,101,110,116,32,115,104,97,100,101,114,32,99,111,109,112,105,108,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,91,83,72,68,82,32,73,68,32,37,105,93,32,70,97,105,108,101,100,32,116,111,32,108,105,110,107,32,115,104,97,100,101,114,32,112,114,111,103,114,97,109,46,46,46,0,91,83,72,68,82,32,73,68,32,37,105,93,32,83,104,97,100,101,114,32,112,114,111,103,114,97,109,32,108,111,97,100,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,68,79,87,78,83,67,65,76,73,78,71,58,32,82,101,113,117,105,114,101,100,32,115,99,114,101,101,110,32,115,105,122,101,32,40,37,105,120,37,105,41,32,105,115,32,98,105,103,103,101,114,32,116,104,97,110,32,100,105,115,112,108,97,121,32,115,105,122,101,32,40,37,105,120,37,105,41,0,68,111,119,110,115,99,97,108,101,32,109,97,116,114,105,120,32,103,101,110,101,114,97,116,101,100,44,32,99,111,110,116,101,110,116,32,119,105,108,108,32,98,101,32,114,101,110,100,101,114,101,100,32,97,116,58,32,37,105,32,120,32,37,105,0,85,80,83,67,65,76,73,78,71,58,32,82,101,113,117,105,114,101,100,32,115,99,114,101,101,110,32,115,105,122,101,58,32,37,105,32,120,32,37,105,32,45,62,32,68,105,115,112,108,97,121,32,115,105,122,101,58,32,37,105,32,120,32,37,105,0,91,71,76,70,87,51,32,69,114,114,111,114,93,32,67,111,100,101,58,32], "i8", ALLOC_NONE, Runtime.GLOBAL_BASE);
  1563. /* memory initializer */ allocate([37,105,32,68,101,99,114,105,112,116,105,111,110,58,32,37,115,0,73,78,70,79,58,32,0,87,65,82,78,73,78,71,58,32,0,87,105,110,100,111,119,32,99,108,111,115,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,91,84,69,88,32,73,68,32,37,105,93,32,85,110,108,111,97,100,101,100,32,116,101,120,116,117,114,101,32,100,97,116,97,32,40,98,97,115,101,32,119,104,105,116,101,32,116,101,120,116,117,114,101,41,32,102,114,111,109,32,86,82,65,77,0,91,84,69,88,32,73,68,32,37,105,93,32,85,110,108,111,97,100,101,100,32,116,101,120,116,117,114,101,32,100,97,116,97,32,102,114,111,109,32,86,82,65,77,32,40,71,80,85,41,0,83,116,97,99,107,32,66,117,102,102,101,114,32,79,118,101,114,102,108,111,119,32,40,77,65,88,32,37,105,32,77,97,116,114,105,120,41,0,77,65,88,95,76,73,78,69,83,95,66,65,84,67,72,32,111,118,101,114,102,108,111,119,0,77,65,88,95,84,82,73,65,78,71,76,69,83,95,66,65,84,67,72,32,111,118,101,114,102,108,111,119,0,77,65,88,95,81,85,65,68,83,95,66,65,84,67,72,32,111,118,101,114,102,108,111,119,0,114,105,46,98,105,116,115,95,112,101,114,95,99,104,97,110,110,101,108,32,61,61,32,49,54,0,46,47,101,120,116,101,114,110,97,108,47,115,116,98,95,105,109,97,103,101,46,104,0,115,116,98,105,95,95,108,111,97,100,95,97,110,100,95,112,111,115,116,112,114,111,99,101,115,115,95,56,98,105,116,0,111,117,116,111,102,109,101,109,0,117,110,107,110,111,119,110,32,105,109,97,103,101,32,116,121,112,101,0,98,97,100,32,114,101,113,95,99,111,109,112,0,114,101,113,95,99,111,109,112,32,62,61,32,49,32,38,38,32,114,101,113,95,99,111,109,112,32,60,61,32,52,0,115,116,98,105,95,95,99,111,110,118,101,114,116,95,102,111,114,109,97,116,49,54,0,48,0,115,116,98,105,95,95,99,111,110,118,101,114,116,95,102,111,114,109,97,116,0,109,117,108,116,105,112,108,101,32,73,72,68,82,0,98,97,100,32,73,72,68,82,32,108,101,110,0,116,111,111,32,108,97,114,103,101,0,49,47,50,47,52,47,56,47,49,54,45,98,105,116,32,111,110,108,121,0,98,97,100,32,99,116,121,112,101,0,98,97,100,32,99,111,109,112,32,109,101,116,104,111,100,0,98,97,100,32,102,105,108,116,101,114,32,109,101,116,104,111,100,0,98,97,100,32,105,110,116,101,114,108,97,99,101,32,109,101,116,104,111,100,0,48,45,112,105,120,101,108,32,105,109,97,103,101,0,102,105,114,115,116,32,110,111,116,32,73,72,68,82,0,105,110,118,97,108,105,100,32,80,76,84,69,0,116,82,78,83,32,97,102,116,101,114,32,73,68,65,84,0,116,82,78,83,32,98,101,102,111,114,101,32,80,76,84,69,0,98,97,100,32,116,82,78,83,32,108,101,110,0,116,82,78,83,32,119,105,116,104,32,97,108,112,104,97,0,0,255,85,0,17,0,0,0,1,110,111,32,80,76,84,69,0,111,117,116,111,102,100,97,116,97,0,110,111,32,73,68,65,84,0,88,88,88,88,32,80,78,71,32,99,104,117,110,107,32,110,111,116,32,107,110,111,119,110,0,115,45,62,105,109,103,95,111,117,116,95,110,32,61,61,32,52,0,115,116,98,105,95,95,100,101,95,105,112,104,111,110,101,0,111,117,116,95,110,32,61,61,32,50,32,124,124,32,111,117,116,95,110,32,61,61,32,52,0,115,116,98,105,95,95,99,111,109,112,117,116,101,95,116,114,97,110,115,112,97,114,101,110,99,121,0,115,116,98,105,95,95,99,111,109,112,117,116,101,95,116,114,97,110,115,112,97,114,101,110,99,121,49,54,0,111,117,116,95,110,32,61,61,32,115,45,62,105,109,103,95,110,32,124,124,32,111,117,116,95,110,32,61,61,32,115,45,62,105,109,103,95,110,43,49,0,115,116,98,105,95,95,99,114,101,97,116,101,95,112,110,103,95,105,109,97,103,101,95,114,97,119,0,110,111,116,32,101,110,111,117,103,104,32,112,105,120,101,108,115,0,105,109,103,95,119,105,100,116,104,95,98,121,116,101,115,32,60,61,32,120,0,0,1,0,5,6,105,109,103,95,110,43,49,32,61,61,32,111,117,116,95,110,0,105,110,118,97,108,105,100,32,102,105,108,116,101,114,0,105,109,103,95,110,32,61,61,32,51,0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,8,8,8,8,8,8,8,8,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,98,97,100,32,104,117,102,102,109,97,110,32,99,111,100,101,0,98,97,100,32,100,105,115,116,0,111,117,116,112,117,116,32,98,117,102,102,101,114,32,108,105,109,105,116,0,122,45,62,115,105,122,101,91,98,93,32,61,61,32,115,0,115,116,98,105,95,95,122,104,117,102,102,109,97,110,95,100,101,99,111,100,101,95,115,108,111,119,112,97,116,104,0,98,105,116,115,32,60,61,32,49,54,0,115,116,98,105,95,95,98,105,116,95,114,101,118,101,114,115,101,0,122,45,62,99,111,100,101,95,98,117,102,102,101,114,32,60,32,40,49,85,32,60,60,32,122,45,62,110,117,109,95,98,105,116,115,41,0,115,116,98,105,95,95,102,105,108,108,95,98,105,116,115,0,98,97,100,32,99,111,100,101,108,101,110,103,116,104,115,0,99,32,61,61,32,49,56,0,115,116,98,105,95,95,99,111,109,112,117,116,101,95,104,117,102,102,109,97,110,95,99,111,100,101,115,0,98,97,100,32,115,105,122,101,115,0,97,45,62,110,117,109,95,98,105,116,115,32,61,61,32,48,0,115,116,98,105,95,95,112,97,114,115,101,95,117,110,99,111,109,112,114,101,115,115,101,100,95,98,108,111,99,107,0,122,108,105,98,32,99,111,114,114,117,112,116,0,114,101,97,100,32,112,97,115,116,32,98,117,102,102,101,114,0,98,97,100,32,122,108,105,98,32,104,101,97,100,101,114,0,110,111,32,112,114,101,115,101,116,32,100,105,99,116,0,98,97,100,32,99,111,109,112,114,101,115,115,105,111,110,0,98,97,100,32,112,110,103,32,115,105,103,0,1,2,4,4,105,110,102,111,45,62,99,104,97,110,110,101,108,115,32,62,61,32,48,0,46,47,101,120,116,101,114,110,97,108,47,115,116,98,95,105,109,97,103,101,95,114,101,115,105,122,101,46,104,0,115,116,98,105,114,95,95,114,101,115,105,122,101,95,97,108,108,111,99,97,116,101,100,0,105,110,102,111,45,62,99,104,97,110,110,101,108,115,32,60,61,32,54,52,0,105,110,102,111,45,62,104,111,114,105,122,111,110,116,97,108,95,102,105,108,116,101,114,32,60,32,40,115,105,122,101,111,102,40,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,41,41,47,115,105,122,101,111,102,40,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,41,91,48,93,41,41,0,105,110,102,111,45,62,118,101,114,116,105,99,97,108,95,102,105,108,116,101,114,32,60,32,40,115,105,122,101,111,102,40,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,41,41,47,115,105,122,101,111,102,40,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,41,91,48,93,41,41,0,97,108,112,104,97,95,99,104,97,110,110,101,108,32,62,61,32,48,32,38,38,32,97,108,112,104,97,95,99,104,97,110,110,101,108,32,60,32,105,110,102,111,45,62,99,104,97,110,110,101,108,115,0,116,101,109,112,109,101,109,0,116,101,109,112,109,101,109,95,115,105,122,101,95,105,110,95,98,121,116,101,115,32,62,61,32,109,101,109,111,114,121,95,114,101,113,117,105,114,101,100,0,40,115,105,122,101,95,116,41,40,117,110,115,105,103,110,101,100,32,99,104,97,114,42,41,40,40,40,117,110,115,105,103,110,101,100,32,99,104,97,114,42,41,105,110,102,111,45,62,101,110,99,111,100,101,95,98,117,102,102,101,114,41,32,43,32,105,110,102,111,45,62,101,110,99,111,100,101,95,98,117,102,102,101,114,95,115,105,122,101,41,32,61,61,32,40,115,105,122,101,95,116,41,116,101,109,112,109,101,109,32,43,32,116,101,109,112,109,101,109,95,115,105,122,101,95,105,110,95,98,121,116,101,115,0,40,115,105,122,101,95,116,41,40,117,110,115,105,103,110,101,100,32,99,104,97,114,42,41,40,40,40,117,110,115,105,103,110,101,100,32,99,104,97,114,42,41,105,110,102,111,45,62,114,105,110,103,95,98,117,102,102,101,114,41,32,43,32,105,110,102,111,45,62,114,105,110,103,95,98,117,102,102,101,114,95,115,105,122,101,41,32,61,61,32,40,115,105,122,101,95,116,41,116,101,109,112,109,101,109,32,43,32,116,101,109,112,109,101,109,95,115,105,122,101,95,105,110,95,98,121,116,101,115,0,33,115,116,98,105,114,95,95,117,115,101,95,104,101,105,103,104,116,95,117,112,115,97,109,112,108,105,110,103,40,115,116,98,105,114,95,105,110,102,111,41,0,115,116,98,105,114,95,95,98,117,102,102,101,114,95,108,111,111,112,95,100,111,119,110,115,97,109,112,108,101,0,111,117,116,95,108,97,115,116,95,115,99,97,110,108,105,110,101,32,45,32,111,117,116,95,102,105,114,115,116,95,115,99,97,110,108,105,110,101,32,43,32,49,32,60,61,32,115,116,98,105,114,95,105,110,102,111,45,62,114,105,110,103,95,98,117,102,102,101,114,95,110,117,109,95,101,110,116,114,105,101,115,0,115,116,98,105,114,95,95,114,101,115,97,109,112,108,101,95,118,101,114,116,105,99,97,108,95,100,111,119,110,115,97,109,112,108,101,0,114,105,110,103,95,98,117,102,102,101,114,95,105,110,100,101,120,32,33,61,32,115,116,98,105,114,95,105,110,102,111,45,62,114,105,110,103,95,98,117,102,102,101,114,95,98,101,103,105,110,95,105,110,100,101,120,0,115,116,98,105,114,95,95,97,100,100,95,101,109,112,116,121,95,114,105,110,103,95,98,117,102,102,101,114,95,101,110,116,114,121,0,33,115,116,98,105,114,95,95,117,115,101,95,119,105,100,116,104,95,117,112,115,97,109,112,108,105,110,103,40,115,116,98,105,114,95,105,110,102,111,41,0,115,116,98,105,114,95,95,114,101,115,97,109,112,108,101,95,104,111,114,105,122,111,110,116,97,108,95,100,111,119,110,115,97,109,112,108,101,0,99,111,101,102,102,105,99,105,101,110,116,32,33,61,32,48,0,110,49,32,62,61,32,110,48,0,115,116,98,105,114,95,95,114,101,115,97,109,112,108,101,95,104,111,114,105,122,111,110,116,97,108,95,117,112,115,97,109,112,108,101,0,110,48,32,62,61,32,45,115,116,98,105,114,95,105,110,102,111,45,62,104,111,114,105,122,111,110,116,97,108,95,102,105,108,116,101,114,95,112,105,120,101,108,95,109,97,114,103,105,110,0,110,49,32,62,61,32,45,115,116,98,105,114,95,105,110,102,111,45,62,104,111,114,105,122,111,110,116,97,108,95,102,105,108,116,101,114,95,112,105,120,101,108,95,109,97,114,103,105,110,0,110,48,32,60,32,115,116,98,105,114,95,105,110,102,111,45,62,105,110,112,117,116,95,119,32,43,32,115,116,98,105,114,95,105,110,102,111,45,62,104,111,114,105,122,111,110,116,97,108,95,102,105,108,116,101,114,95,112,105,120,101,108,95,109,97,114,103,105,110,0,110,49,32,60,32,115,116,98,105,114,95,105,110,102,111,45,62,105,110,112,117,116,95,119,32,43,32,115,116,98,105,114,95,105,110,102,111,45,62,104,111,114,105,122,111,110,116,97,108,95,102,105,108,116,101,114,95,112,105,120,101,108,95,109,97,114,103,105,110,0,33,34,85,110,107,110,111,119,110,32,116,121,112,101,47,99,111,108,111,114,115,112,97,99,101,47,99,104,97,110,110,101,108,115,32,99,111,109,98,105,110,97,116,105,111,110,46,34,0,115,116,98,105,114,95,95,100,101,99,111,100,101,95,115,99,97,110,108,105,110,101,0,33,34,85,110,105,109,112,108,101,109,101,110,116,101,100,32,101,100,103,101,32,116,121,112,101,34,0,115,116,98,105,114,95,95,101,100,103,101,95,119,114,97,112,95,115,108,111,119,0,115,116,98,105,114,95,95,101,110,99,111,100,101,95,115,99,97,110,108,105,110,101,0,115,99,97,108,101,32,60,61,32,49,0,115,116,98,105,114,95,95,115,117,112,112,111,114,116,95,116,114,97,112,101,122,111,105,100,0,115,116,98,105,114,95,95,102,105,108,116,101,114,95,116,114,97,112,101,122,111,105,100,0,115,116,98,105,114,95,95,117,115,101,95,104,101,105,103,104,116,95,117,112,115,97,109,112,108,105,110,103,40,115,116,98,105,114,95,105,110,102,111,41,0,115,116,98,105,114,95,95,98,117,102,102,101,114,95,108,111,111,112,95,117,112,115,97,109,112,108,101,0,105,110,95,108,97,115,116,95,115,99,97,110,108,105,110,101,32,45,32,105,110,95,102,105,114,115,116,95,115,99,97,110,108,105,110,101,32,43,32,49,32,60,61,32,115,116,98,105,114,95,105,110,102,111,45,62,114,105,110,103,95,98,117,102,102,101,114,95,110,117,109,95,101,110,116,114,105,101,115,0,115,116,98,105,114,95,95,114,101,115,97,109,112,108,101,95,118,101,114,116,105,99,97,108,95,117,112,115,97,109,112,108,101,0,116,111,116,97,108,32,62,32,48,46,57,102,0,115,116,98,105,114,95,95,110,111,114,109,97,108,105,122,101,95,100,111,119,110,115,97,109,112,108,101,95,99,111,101,102,102,105,99,105,101,110,116,115,0,116,111,116,97,108,32,60,32,49,46,49,102,0,111,117,116,95,108,97,115,116,95,112,105,120,101,108,32,45,32,111,117,116,95,102,105,114,115,116,95,112,105,120,101,108,32,60,61,32,40,105,110,116,41,99,101,105,108,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,91,102,105,108,116,101,114,93,46,115,117,112,112,111,114,116,40,115,99,97,108,101,95,114,97,116,105,111,41,32,42,32,50,41,0,115,116,98,105,114,95,95,99,97,108,99,117,108,97,116,101,95,99,111,101,102,102,105,99,105,101,110,116,115,95,100,111,119,110,115,97,109,112,108,101,0,99,111,110,116,114,105,98,117,116,111,114,45,62,110,49,32,62,61,32,99,111,110,116,114,105,98,117,116,111,114,45,62,110,48,0,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,91,102,105,108,116,101,114,93,46,107,101,114,110,101,108,40,40,102,108,111,97,116,41,40,111,117,116,95,108,97,115,116,95,112,105,120,101,108,32,43,32,49,41,32,43,32,48,46,53,102,32,45,32,111,117,116,95,99,101,110,116,101,114,95,111,102,95,105,110,44,32,115,99,97,108,101,95,114,97,116,105,111,41,32,61,61,32,48,0,105,110,95,108,97,115,116,95,112,105,120,101,108,32,45,32,105,110,95,102,105,114,115,116,95,112,105,120,101,108,32,60,61,32,40,105,110,116,41,99,101,105,108,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,91,102,105,108,116,101,114,93,46,115,117,112,112,111,114,116,40,49,47,115,99,97,108,101,41,32,42,32,50,41,0,115,116,98,105,114,95,95,99,97,108,99,117,108,97,116,101,95,99,111,101,102,102,105,99,105,101,110,116,115,95,117,112,115,97,109,112,108,101,0,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,91,102,105,108,116,101,114,93,46,107,101,114,110,101,108,40,40,102,108,111,97,116,41,40,105,110,95,108,97,115,116,95,112,105,120,101,108,32,43,32,49,41,32,43,32,48,46,53,102,32,45,32,105,110,95,99,101,110,116,101,114,95,111,102,95,111,117,116,44,32,49,47,115,99,97,108,101,41,32,61,61,32,48,0,116,111,116,97,108,95,102,105,108,116,101,114,32,62,32,48,46,57,0,116,111,116,97,108,95,102,105,108,116,101,114,32,60,32,49,46,49,102,0,102,105,108,116,101,114,32,33,61,32,48,0,115,116,98,105,114,95,95,103,101,116,95,102,105,108,116,101,114,95,112,105,120,101,108,95,119,105,100,116,104,0,102,105,108,116,101,114,32,60,32,40,115,105,122,101,111,102,40,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,41,41,47,115,105,122,101,111,102,40,40,115,116,98,105,114,95,95,102,105,108,116,101,114,95,105,110,102,111,95,116,97,98,108,101,41,91,48,93,41,41,0,105,110,102,111,45,62,104,111,114,105,122,111,110,116,97,108,95,102,105,108,116,101,114,32,33,61,32,48,0,115,116,98,105,114,95,95,99,97,108,99,117,108,97,116,101,95,109,101,109,111,114,121,0,105,110,102,111,45,62,118,101,114,116,105,99,97,108,95,102,105,108,116,101,114,32,33,61,32,48,0,46,114,114,101,115,0,91,37,115,93,32,82,101,115,111,117,114,99,101,32,102,105,108,101,32,100,111,101,115,32,110,111,116,32,99,111,110,116,97,105,110,32,105,109,97,103,101,32,100,97,116,97,0,46,112,110,103,0,91,37,115,93,32,73,109,97,103,101,32,102,105,108,101,102,111,114,109,97,116,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,91,37,115,93,32,73,109,97,103,101,32,108,111,97,100,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,40,37,105,120,37,105,41,0,91,37,115,93,32,73,109,97,103,101,32,99,111,117,108,100,32,110,111,116,32,98,101,32,108,111,97,100,101,100,0,73,109,97,103,101,32,102,111,114,109,97,116,32,110,111,116,32,114,101,99,111,103,110,105,122,101,100,0,114,98,0,91,37,115,93,32,114,82,69,83,32,114,97,121,108,105,98,32,114,101,115,111,117,114,99,101,32,102,105,108,101,32,99,111,117,108,100,32,110,111,116,32,98,101,32,111,112,101,110,101,100,0,91,37,115,93,32,84,104,105,115,32,105,115,32,110,111,116,32,97,32,118,97,108,105,100,32,114,97,121,108,105,98,32,114,101,115,111,117,114,99,101,32,102,105,108,101,0,91,37,115,93,91,73,68,32,37,105,93,32,82,101,115,111,117,114,99,101,32,100,97,116,97,32,108,111,97,100,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,0,91,37,115,93,91,73,68,32,37,105,93,32,82,101,113,117,101,115,116,101,100,32,114,101,115,111,117,114,99,101,32,99,111,117,108,100,32,110,111,116,32,98,101,32,102,111,117,110,100,0,79,117,116,32,111,102,32,109,101,109,111,114,121,32,119,104,105,108,101,32,100,101,99,111,109,112,114,101,115,115,105,110,103,32,100,97,116,97,0,68,97,116,97,32,100,101,99,111,109,112,114,101,115,115,105,111,110,32,102,97,105,108,101,100,0,69,120,112,101,99,116,101,100,32,117,110,99,111,109,112,114,101,115,115,101,100,32,115,105,122,101,32,100,111,32,110,111,116,32,109,97,116,99,104,44,32,100,97,116,97,32,109,97,121,32,98,101,32,99,111,114,114,117,112,116,101,100,0,32,45,45,32,69,120,112,101,99,116,101,100,32,117,110,99,111,109,112,114,101,115,115,101,100,32,115,105,122,101,58,32,37,105,0,32,45,45,32,82,101,116,117,114,110,101,100,32,117,110,99,111,109,112,114,101,115,115,101,100,32,115,105,122,101,58,32,37,105,0,68,97,116,97,32,100,101,99,111,109,112,114,101,115,115,101,100,32,115,117,99,99,101,115,115,102,117,108,108,121,32,102,114,111,109,32,37,117,32,98,121,116,101,115,32,116,111,32,37,117,32,98,121,116,101,115,0,5,5,4,0,16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15,2,3,7,0,3,3,11,0,67,114,111,112,32,114,101,99,116,97,110,103,108,101,32,119,105,100,116,104,32,111,117,116,32,111,102,32,98,111,117,110,100,115,44,32,114,101,115,99,97,108,101,100,32,99,114,111,112,32,119,105,100,116,104,58,32,37,105,0,67,114,111,112,32,114,101,99,116,97,110,103,108,101,32,104,101,105,103,104,116,32,111,117,116,32,111,102,32,98,111,117,110,100,115,44,32,114,101,115,99,97,108,101,100,32,99,114,111,112,32,104,101,105,103,104,116,58,32,37,105,0,73,109,97,103,101,32,99,97,110,32,110,111,116,32,98,101,32,99,114,111,112,112,101,100,44,32,99,114,111,112,32,114,101,99,116,97,110,103,108,101,32,111,117,116,32,111,102,32,98,111,117,110,100,115,0,83,111,117,114,99,101,32,114,101,99,116,97,110,103,108,101,32,119,105,100,116,104,32,111,117,116,32,111,102,32,98,111,117,110,100,115,44,32,114,101,115,99,97,108,101,100,32,119,105,100,116,104,58,32,37,105,0,83,111,117,114,99,101,32,114,101,99,116,97,110,103,108,101,32,104,101,105,103,104,116,32,111,117,116,32,111,102,32,98,111,117,110,100,115,44,32,114,101,115,99,97,108,101,100,32,104,101,105,103,104,116,58,32,37,105,0,68,101,115,116,105,110,97,116,105,111,110,32,114,101,99,116,97,110,103,108,101,32,119,105,100,116,104,32,111,117,116,32,111,102,32,98,111,117,110,100,115,44,32,114,101,115,99,97,108,101,100,32,119,105,100,116,104,58,32,37,105,0,68,101,115,116,105,110,97,116,105,111,110,32,114,101,99,116,97,110,103,108,101,32,104,101,105,103,104,116,32,111,117,116,32,111,102,32,98,111,117,110,100,115,44,32,114,101,115,99,97,108,101,100,32,104,101,105,103,104,116,58,32,37,105,0,69,88,84,0,65,82,66,0,79,69,83,0,65,78,71,76,69,0,103,108,67,114,101,97,116,101,80,114,111,103,114,97,109,79,98,106,101,99,116,0,103,108,67,114,101,97,116,101,80,114,111,103,114,97,109,0,103,108,85,115,101,80,114,111,103,114,97,109,79,98,106,101,99,116,0,103,108,85,115,101,80,114,111,103,114,97,109,0,103,108,67,114,101,97,116,101,83,104,97,100,101,114,79,98,106,101,99,116,0,103,108,67,114,101,97,116,101,83,104,97,100,101,114,0,103,108,65,116,116,97,99,104,79,98,106,101,99,116,0,103,108,65,116,116,97,99,104,83,104,97,100,101,114,0,103,108,68,101,116,97,99,104,79,98,106,101,99,116,0,103,108,68,101,116,97,99,104,83,104,97,100,101,114,0,103,108,80,105,120,101,108,83,116,111,114,101,105,0,103,108,71,101,116,83,116,114,105,110,103,0,103,108,71,101,116,73,110,116,101,103,101,114,118,0,103,108,71,101,116,70,108,111,97,116,118,0,103,108,71,101,116,66,111,111,108,101,97,110,118,0,103,108,71,101,110,84,101,120,116,117,114,101,115,0,103,108,68,101,108,101,116,101,84,101,120,116,117,114,101,115,0,103,108,67,111,109,112,114,101,115,115,101,100,84,101,120,73,109,97,103,101,50,68,0,103,108,67,111,109,112,114,101,115,115,101,100,84,101,120,83,117,98,73,109,97,103,101,50,68,0,103,108,84,101,120,73,109,97,103,101,50,68,0,103,108,84,101,120,83,117,98,73,109,97,103,101,50,68,0,103,108,82,101,97,100,80,105,120,101,108,115,0,103,108,66,105,110,100,84,101,120,116,117,114,101,0,103,108,71,101,116,84,101,120,80,97,114,97,109,101,116,101,114,102,118,0,103,108,71,101,116,84,101,120,80,97,114,97,109,101,116,101,114,105,118,0,103,108,84,101,120,80,97,114,97,109,101,116,101,114,102,118,0,103,108,84,101,120,80,97,114,97,109,101,116,101,114,105,118,0,103,108,73,115,84,101,120,116,117,114,101,0,103,108,71,101,110,66,117,102,102,101,114,115,0,103,108,68,101,108,101,116,101,66,117,102,102,101,114,115,0,103,108,71,101,116,66,117,102,102,101,114,80,97,114,97,109,101,116,101,114,105,118,0,103,108,66,117,102,102,101,114,68,97,116,97,0,103,108,66,117,102,102,101,114,83,117,98,68,97,116,97,0,103,108,73,115,66,117,102,102,101,114,0,103,108,71,101,110,82,101,110,100,101,114,98,117,102,102,101,114,115,0,103,108,68,101,108,101,116,101,82,101,110,100,101,114,98,117,102,102,101,114,115,0,103,108,66,105,110,100,82,101,110,100,101,114,98,117,102,102,101,114,0,103,108,71,101,116,82,101,110,100,101,114,98,117,102,102,101,114,80,97,114,97,109,101,116,101,114,105,118,0,103,108,73,115,82,101,110,100,101,114,98,117,102,102,101,114,0,103,108,71,101,116,85,110,105,102,111,114,109,102,118,0,103,108,71,101,116,85,110,105,102,111,114,109,105,118,0,103,108,71,101,116,85,110,105,102,111,114,109,76,111,99,97,116,105,111,110,0,103,108,71,101,116,86,101,114,116,101,120,65,116,116,114,105,98,102,118,0,103,108,71,101,116,86,101,114,116,101,120,65,116,116,114,105,98,105,118,0,103,108,71,101,116,86,101,114,116,101,120,65,116,116,114,105,98,80,111,105,110,116,101,114,118,0,103,108,71,101,116,65,99,116,105,118,101,85,110,105,102,111,114,109,0,103,108,85,110,105,102,111,114,109,49,102,0,103,108,85,110,105,102,111,114,109,50,102,0,103,108,85,110,105,102,111,114,109,51,102,0,103,108,85,110,105,102,111,114,109,52,102,0,103,108,85,110,105,102,111,114,109,49,105,0,103,108,85,110,105,102,111,114,109,50,105,0,103,108,85,110,105,102,111,114,109,51,105,0,103,108,85,110,105,102,111,114,109,52,105,0,103,108,85,110,105,102,111,114,109,49,105,118,0,103,108,85,110,105,102,111,114,109,50,105,118,0,103,108,85,110,105,102,111,114,109,51,105,118,0,103,108,85,110,105,102,111,114,109,52,105,118,0,103,108,85,110,105,102,111,114,109,49,102,118,0,103,108,85,110,105,102,111,114,109,50,102,118,0,103,108,85,110,105,102,111,114,109,51,102,118,0,103,108,85,110,105,102,111,114,109,52,102,118,0,103,108,85,110,105,102,111,114,109,77,97,116,114,105,120,50,102,118,0,103,108,85,110,105,102,111,114,109,77,97,116,114,105,120,51,102,118,0,103,108,85,110,105,102,111,114,109,77,97,116,114,105,120,52,102,118,0,103,108,66,105,110,100,66,117,102,102,101,114,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,49,102,118,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,50,102,118,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,51,102,118,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,52,102,118,0,103,108,71,101,116,65,116,116,114,105,98,76,111,99,97,116,105,111,110,0,103,108,71,101,116,65,99,116,105,118,101,65,116,116,114,105,98,0,103,108,68,101,108,101,116,101,83,104,97,100,101,114,0,103,108,71,101,116,65,116,116,97,99,104,101,100,83,104,97,100,101,114,115,0,103,108,83,104,97,100,101,114,83,111,117,114,99,101,0,103,108,71,101,116,83,104,97,100,101,114,83,111,117,114,99,101,0,103,108,67,111,109,112,105,108,101,83,104,97,100,101,114,0,103,108,71,101,116,83,104,97,100,101,114,73,110,102,111,76,111,103,0,103,108,71,101,116,83,104,97,100,101,114,105,118,0,103,108,71,101,116,80,114,111,103,114,97,109,105,118,0,103,108,73,115,83,104,97,100,101,114,0,103,108,68,101,108,101,116,101,80,114,111,103,114,97,109,0,103,108,71,101,116,83,104,97,100,101,114,80,114,101,99,105,115,105,111,110,70,111,114,109,97,116,0,103,108,76,105,110,107,80,114,111,103,114,97,109,0,103,108,71,101,116,80,114,111,103,114,97,109,73,110,102,111,76,111,103,0,103,108,86,97,108,105,100,97,116,101,80,114,111,103,114,97,109,0,103,108,73,115,80,114,111,103,114,97,109,0,103,108,66,105,110,100,65,116,116,114,105,98,76,111,99,97,116,105,111,110,0,103,108,66,105,110,100,70,114,97,109,101,98,117,102,102,101,114,0,103,108,71,101,110,70,114,97,109,101,98,117,102,102,101,114,115,0,103,108,68,101,108,101,116,101,70,114,97,109,101,98,117,102,102,101,114,115,0,103,108,70,114,97,109,101,98,117,102,102,101,114,82,101,110,100,101,114,98,117,102,102,101,114,0,103,108,70,114,97,109,101,98,117,102,102,101,114,84,101,120,116,117,114,101,50,68,0,103,108,71,101,116,70,114,97,109,101,98,117,102,102,101,114,65,116,116,97,99,104,109,101,110,116,80,97,114,97,109,101,116,101,114,105,118,0,103,108,73,115,70,114,97,109,101,98,117,102,102,101,114,0,103,108,68,101,108,101,116,101,79,98,106,101,99,116,0,103,108,71,101,116,79,98,106,101,99,116,80,97,114,97,109,101,116,101,114,105,118,0,103,108,71,101,116,73,110,102,111,76,111,103,0,103,108,66,105,110,100,80,114,111,103,114,97,109,0,103,108,71,101,116,80,111,105,110,116,101,114,118,0,103,108,68,114,97,119,82,97,110,103,101,69,108,101,109,101,110,116,115,0,103,108,69,110,97,98,108,101,67,108,105,101,110,116,83,116,97,116,101,0,103,108,86,101,114,116,101,120,80,111,105,110,116,101,114,0,103,108,84,101,120,67,111,111,114,100,80,111,105,110,116,101,114,0,103,108,78,111,114,109,97,108,80,111,105,110,116,101,114,0,103,108,67,111,108,111,114,80,111,105,110,116,101,114,0,103,108,67,108,105,101,110,116,65,99,116,105,118,101,84,101,120,116,117,114,101,0,103,108,71,101,110,86,101,114,116,101,120,65,114,114,97,121,115,0,103,108,68,101,108,101,116,101,86,101,114,116,101,120,65,114,114,97,121,115,0,103,108,66,105,110,100,86,101,114,116,101,120,65,114,114,97,121,0,103,108,77,97,116,114,105,120,77,111,100,101,0,103,108,76,111,97,100,73,100,101,110,116,105,116,121,0,103,108,76,111,97,100,77,97,116,114,105,120,102,0,103,108,70,114,117,115,116,117,109,0,103,108,82,111,116,97,116,101,102,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,80,111,105,110,116,101,114,0,103,108,69,110,97,98,108,101,86,101,114,116,101,120,65,116,116,114,105,98,65,114,114,97,121,0,103,108,68,105,115,97,98,108,101,86,101,114,116,101,120,65,116,116,114,105,98,65,114,114,97,121,0,103,108,68,114,97,119,65,114,114,97,121,115,0,103,108,68,114,97,119,69,108,101,109,101,110,116,115,0,103,108,83,104,97,100,101,114,66,105,110,97,114,121,0,103,108,82,101,108,101,97,115,101,83,104,97,100,101,114,67,111,109,112,105,108,101,114,0,103,108,71,101,116,69,114,114,111,114,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,68,105,118,105,115,111,114,0,103,108,68,114,97,119,65,114,114,97,121,115,73,110,115,116,97,110,99,101,100,0,103,108,68,114,97,119,69,108,101,109,101,110,116,115,73,110,115,116,97,110,99,101,100,0,103,108,70,105,110,105,115,104,0,103,108,70,108,117,115,104,0,103,108,67,108,101,97,114,68,101,112,116,104,0,103,108,67,108,101,97,114,68,101,112,116,104,102,0,103,108,68,101,112,116,104,70,117,110,99,0,103,108,69,110,97,98,108,101,0,103,108,68,105,115,97,98,108,101,0,103,108,70,114,111,110,116,70,97,99,101,0,103,108,67,117,108,108,70,97,99,101,0,103,108,67,108,101,97,114,0,103,108,76,105,110,101,87,105,100,116,104,0,103,108,67,108,101,97,114,83,116,101,110,99,105,108,0,103,108,68,101,112,116,104,77,97,115,107,0,103,108,83,116,101,110,99,105,108,77,97,115,107,0,103,108,67,104,101,99,107,70,114,97,109,101,98,117,102,102,101,114,83,116,97,116,117,115,0,103,108,71,101,110,101,114,97,116,101,77,105,112,109,97,112,0,103,108,65,99,116,105,118,101,84,101,120,116,117,114,101,0,103,108,66,108,101,110,100,69,113,117,97,116,105,111,110,0,103,108,73,115,69,110,97,98,108,101,100,0,103,108,66,108,101,110,100,70,117,110,99,0,103,108,66,108,101,110,100,69,113,117,97,116,105,111,110,83,101,112,97,114,97,116,101,0,103,108,68,101,112,116,104,82,97,110,103,101,0,103,108,68,101,112,116,104,82,97,110,103,101,102,0,103,108,83,116,101,110,99,105,108,77,97,115,107,83,101,112,97,114,97,116,101,0,103,108,72,105,110,116,0,103,108,80,111,108,121,103,111,110,79,102,102,115,101,116,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,49,102,0,103,108,83,97,109,112,108,101,67,111,118,101,114,97,103,101,0,103,108,84,101,120,80,97,114,97,109,101,116,101,114,105,0,103,108,84,101,120,80,97,114,97,109,101,116,101,114,102,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,50,102,0,103,108,83,116,101,110,99,105,108,70,117,110,99,0,103,108,83,116,101,110,99,105,108,79,112,0,103,108,86,105,101,119,112,111,114,116,0,103,108,67,108,101,97,114,67,111,108,111,114,0,103,108,83,99,105,115,115,111,114,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,51,102,0,103,108,67,111,108,111,114,77,97,115,107,0,103,108,82,101,110,100,101,114,98,117,102,102,101,114,83,116,111,114,97,103,101,0,103,108,66,108,101,110,100,70,117,110,99,83,101,112,97,114,97,116,101,0,103,108,66,108,101,110,100,67,111,108,111,114,0,103,108,83,116,101,110,99,105,108,70,117,110,99,83,101,112,97,114,97,116,101,0,103,108,83,116,101,110,99,105,108,79,112,83,101,112,97,114,97,116,101,0,103,108,86,101,114,116,101,120,65,116,116,114,105,98,52,102,0,103,108,67,111,112,121,84,101,120,73,109,97,103,101,50,68,0,103,108,67,111,112,121,84,101,120,83,117,98,73,109,97,103,101,50,68,0,103,108,68,114,97,119,66,117,102,102,101,114,115,0,123,32,77,111,100,117,108,101,46,112,114,105,110,116,69,114,114,40,39,98,97,100,32,110,97,109,101,32,105,110,32,103,101,116,80,114,111,99,65,100,100,114,101,115,115,58,32,39,32,43,32,91,80,111,105,110,116,101,114,95,115,116,114,105,110,103,105,102,121,40,36,48,41,44,32,80,111,105,110,116,101,114,95,115,116,114,105,110,103,105,102,121,40,36,49,41,93,41,59,32,125,0,17,0,10,0,17,17,17,0,0,0,0,5,0,0,0,0,0,0,9,0,0,0,0,11,0,0,0,0,0,0,0,0,17,0,15,10,17,17,17,3,10,7,0,1,19,9,11,11,0,0,9,6,11,0,0,11,0,6,17,0,0,0,17,17,17,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,11,0,0,0,0,0,0,0,0,17,0,10,10,17,17,17,0,10,0,0,2,0,9,11,0,0,0,9,0,11,0,0,11,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,12,0,0,0,0,0,0,0,0,0,0,0,12,0,0,0,0,12,0,0,0,0,9,12,0,0,0,0,0,12,0,0,12,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,14,0,0,0,0,0,0,0,0,0,0,0,13,0,0,0,4,13,0,0,0,0,9,14,0,0,0,0,0,14,0,0,14,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,0,0,0,0,0,0,0,0,0,0,0,15,0,0,0,0,15,0,0,0,0,9,16,0,0,0,0,0,16,0,0,16,0,0,18,0,0,0,18,18,18,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,18,0,0,0,18,18,18,0,0,0,0,0,0,9,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,11,0,0,0,0,0,0,0,0,0,0,0,10,0,0,0,0,10,0,0,0,0,9,11,0,0,0,0,0,11,0,0,11,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,12,0,0,0,0,0,0,0,0,0,0,0,12,0,0,0,0,12,0,0,0,0,9,12,0,0,0,0,0,12,0,0,12,0,0,45,43,32,32,32,48,88,48,120,0,40,110,117,108,108,41,0,45,48,88,43,48,88,32,48,88,45,48,120,43,48,120,32,48,120,0,105,110,102,0,73,78,70,0,110,97,110,0,78,65,78,0,48,49,50,51,52,53,54,55,56,57,65,66,67,68,69,70,46,0,84,33,34,25,13,1,2,3,17,75,28,12,16,4,11,29,18,30,39,104,110,111,112,113,98,32,5,6,15,19,20,21,26,8,22,7,40,36,23,24,9,10,14,27,31,37,35,131,130,125,38,42,43,60,61,62,63,67,71,74,77,88,89,90,91,92,93,94,95,96,97,99,100,101,102,103,105,106,107,108,114,115,116,121,122,123,124,0,73,108,108,101,103,97,108,32,98,121,116,101,32,115,101,113,117,101,110,99,101,0,68,111,109,97,105,110,32,101,114,114,111,114,0,82,101,115,117,108,116,32,110,111,116,32,114,101,112,114,101,115,101,110,116,97,98,108,101,0,78,111,116,32,97,32,116,116,121,0,80,101,114,109,105,115,115,105,111,110,32,100,101,110,105,101,100,0,79,112,101,114,97,116,105,111,110,32,110,111,116,32,112,101,114,109,105,116,116,101,100,0,78,111,32,115,117,99,104,32,102,105,108,101,32,111,114,32,100,105,114,101,99,116,111,114,121,0,78,111,32,115,117,99,104,32,112,114,111,99,101,115,115,0,70,105,108,101,32,101,120,105,115,116,115,0,86,97,108,117,101,32,116,111,111,32,108,97,114,103,101,32,102,111,114,32,100,97,116,97,32,116,121,112,101,0,78,111,32,115,112,97,99,101,32,108,101,102,116,32,111,110,32,100,101,118,105,99,101,0,79,117,116,32,111,102,32,109,101,109,111,114,121,0,82,101,115,111,117,114,99,101,32,98,117,115,121,0,73,110,116,101,114,114,117,112,116,101,100,32,115,121,115,116,101,109,32,99,97,108,108,0,82,101,115,111,117,114,99,101,32,116,101,109,112,111,114,97,114,105,108,121,32,117,110,97,118,97,105,108,97,98,108,101,0,73,110,118,97,108,105,100,32,115,101,101,107,0,67,114,111,115,115,45,100,101,118,105,99,101,32,108,105,110,107,0,82,101,97,100,45,111,110,108,121,32,102,105,108,101,32,115,121,115,116,101,109,0,68,105,114,101,99,116,111,114,121,32,110,111,116,32,101,109,112,116,121,0,67,111,110,110,101,99,116,105,111,110,32,114,101,115,101,116,32,98,121,32,112,101,101,114,0,79,112,101,114,97,116,105,111,110,32,116,105,109,101,100,32,111,117,116,0,67,111,110,110,101,99,116,105,111,110,32,114,101,102,117,115,101,100,0,72,111,115,116,32,105,115,32,100,111,119,110,0,72,111,115,116,32,105,115,32,117,110,114,101,97,99,104,97,98,108,101,0,65,100,100,114,101,115,115,32,105,110,32,117,115,101,0,66,114,111,107,101,110,32,112,105,112,101,0,73,47,79,32,101,114,114,111,114,0,78,111,32,115,117,99,104,32,100,101,118,105,99,101,32,111,114,32,97,100,100,114,101,115,115,0,66,108,111,99,107,32,100,101,118,105,99,101,32,114,101,113,117,105,114,101,100,0,78,111,32,115,117,99,104,32,100,101,118,105,99,101,0,78,111,116,32,97,32,100,105,114,101,99,116,111,114,121,0,73,115,32,97,32,100,105,114,101,99,116,111,114,121,0,84,101,120,116,32,102,105,108,101,32,98,117,115,121,0,69,120,101,99,32,102,111,114,109,97,116,32,101,114,114,111,114,0,73,110,118,97,108,105,100,32,97,114,103,117,109,101,110,116,0,65,114,103,117,109,101,110,116,32,108,105,115,116,32,116,111,111,32,108,111,110,103,0,83,121,109,98,111,108,105,99,32,108,105,110,107,32,108,111,111,112,0,70,105,108,101,110,97,109,101,32,116,111,111,32,108,111,110,103,0,84,111,111,32,109,97,110,121,32,111,112,101,110,32,102,105,108,101,115,32,105,110,32,115,121,115,116,101,109,0,78,111,32,102,105,108,101,32,100,101,115,99,114,105,112,116,111,114,115,32,97,118,97,105,108,97,98,108,101,0,66,97,100,32,102,105,108,101,32,100,101,115,99,114,105,112,116,111,114,0,78,111,32,99,104,105,108,100,32,112,114,111,99,101,115,115,0,66,97,100,32,97,100,100,114,101,115,115,0,70,105,108,101,32,116,111,111,32,108,97,114,103,101,0,84,111,111,32,109,97,110,121,32,108,105,110,107,115,0,78,111,32,108,111,99,107,115,32,97,118,97,105,108,97,98,108,101,0,82,101,115,111,117,114,99,101,32,100,101,97,100,108,111,99,107,32,119,111,117,108,100,32,111,99,99,117,114,0,83,116,97,116,101,32,110,111,116,32,114,101,99,111,118,101,114,97,98,108,101,0,80,114,101,118,105,111,117,115,32,111,119,110,101,114,32,100,105,101,100,0,79,112,101,114,97,116,105,111,110,32,99,97,110,99,101,108,101,100,0,70,117,110,99,116,105,111,110,32,110,111,116,32,105,109,112,108,101,109,101,110,116,101,100,0,78,111,32,109,101,115,115,97,103,101,32,111,102,32,100,101,115,105,114,101,100,32,116,121,112,101,0,73,100,101,110,116,105,102,105,101,114,32,114,101,109,111,118,101,100,0,68,101,118,105,99,101,32,110,111,116,32,97,32,115,116,114,101,97,109,0,78,111,32,100,97,116,97,32,97,118,97,105,108,97,98,108,101,0,68,101,118,105,99,101,32,116,105,109,101,111,117,116,0,79,117,116,32,111,102,32,115,116,114,101,97,109,115,32,114,101,115,111,117,114,99,101,115,0,76,105,110,107,32,104,97,115,32,98,101,101,110,32,115,101,118,101,114,101,100,0,80,114,111,116,111,99,111,108,32,101,114,114,111,114,0,66,97,100,32,109,101,115,115,97,103,101,0,70,105,108,101,32,100,101,115,99,114,105,112,116,111,114,32,105,110,32,98,97,100,32,115,116,97,116,101,0,78,111,116,32,97,32,115,111,99,107,101,116,0,68,101,115,116,105,110,97,116,105,111,110,32,97,100,100,114,101,115,115,32,114,101,113,117,105,114,101,100,0,77,101,115,115,97,103,101,32,116,111,111,32,108,97,114,103,101,0,80,114,111,116,111,99,111], "i8", ALLOC_NONE, Runtime.GLOBAL_BASE+10240);
  1564. /* memory initializer */ allocate([108,32,119,114,111,110,103,32,116,121,112,101,32,102,111,114,32,115,111,99,107,101,116,0,80,114,111,116,111,99,111,108,32,110,111,116,32,97,118,97,105,108,97,98,108,101,0,80,114,111,116,111,99,111,108,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,83,111,99,107,101,116,32,116,121,112,101,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,78,111,116,32,115,117,112,112,111,114,116,101,100,0,80,114,111,116,111,99,111,108,32,102,97,109,105,108,121,32,110,111,116,32,115,117,112,112,111,114,116,101,100,0,65,100,100,114,101,115,115,32,102,97,109,105,108,121,32,110,111,116,32,115,117,112,112,111,114,116,101,100,32,98,121,32,112,114,111,116,111,99,111,108,0,65,100,100,114,101,115,115,32,110,111,116,32,97,118,97,105,108,97,98,108,101,0,78,101,116,119,111,114,107,32,105,115,32,100,111,119,110,0,78,101,116,119,111,114,107,32,117,110,114,101,97,99,104,97,98,108,101,0,67,111,110,110,101,99,116,105,111,110,32,114,101,115,101,116,32,98,121,32,110,101,116,119,111,114,107,0,67,111,110,110,101,99,116,105,111,110,32,97,98,111,114,116,101,100,0,78,111,32,98,117,102,102,101,114,32,115,112,97,99,101,32,97,118,97,105,108,97,98,108,101,0,83,111,99,107,101,116,32,105,115,32,99,111,110,110,101,99,116,101,100,0,83,111,99,107,101,116,32,110,111,116,32,99,111,110,110,101,99,116,101,100,0,67,97,110,110,111,116,32,115,101,110,100,32,97,102,116,101,114,32,115,111,99,107,101,116,32,115,104,117,116,100,111,119,110,0,79,112,101,114,97,116,105,111,110,32,97,108,114,101,97,100,121,32,105,110,32,112,114,111,103,114,101,115,115,0,79,112,101,114,97,116,105,111,110,32,105,110,32,112,114,111,103,114,101,115,115,0,83,116,97,108,101,32,102,105,108,101,32,104,97,110,100,108,101,0,82,101,109,111,116,101,32,73,47,79,32,101,114,114,111,114,0,81,117,111,116,97,32,101,120,99,101,101,100,101,100,0,78,111,32,109,101,100,105,117,109,32,102,111,117,110,100,0,87,114,111,110,103,32,109,101,100,105,117,109,32,116,121,112,101,0,78,111,32,101,114,114,111,114,32,105,110,102,111,114,109,97,116,105,111,110,0,0,114,119,97,0], "i8", ALLOC_NONE, Runtime.GLOBAL_BASE+20480);
  1565. /* no memory initializer */
  1566. var tempDoublePtr = STATICTOP; STATICTOP += 16;
  1567. assert(tempDoublePtr % 8 == 0);
  1568. function copyTempFloat(ptr) { // functions, because inlining this code increases code size too much
  1569. HEAP8[tempDoublePtr] = HEAP8[ptr];
  1570. HEAP8[tempDoublePtr+1] = HEAP8[ptr+1];
  1571. HEAP8[tempDoublePtr+2] = HEAP8[ptr+2];
  1572. HEAP8[tempDoublePtr+3] = HEAP8[ptr+3];
  1573. }
  1574. function copyTempDouble(ptr) {
  1575. HEAP8[tempDoublePtr] = HEAP8[ptr];
  1576. HEAP8[tempDoublePtr+1] = HEAP8[ptr+1];
  1577. HEAP8[tempDoublePtr+2] = HEAP8[ptr+2];
  1578. HEAP8[tempDoublePtr+3] = HEAP8[ptr+3];
  1579. HEAP8[tempDoublePtr+4] = HEAP8[ptr+4];
  1580. HEAP8[tempDoublePtr+5] = HEAP8[ptr+5];
  1581. HEAP8[tempDoublePtr+6] = HEAP8[ptr+6];
  1582. HEAP8[tempDoublePtr+7] = HEAP8[ptr+7];
  1583. }
  1584. // {{PRE_LIBRARY}}
  1585. var GL={counter:1,lastError:0,buffers:[],mappedBuffers:{},programs:[],framebuffers:[],renderbuffers:[],textures:[],uniforms:[],shaders:[],vaos:[],contexts:[],currentContext:null,offscreenCanvases:{},timerQueriesEXT:[],byteSizeByTypeRoot:5120,byteSizeByType:[1,1,2,2,4,4,4,2,3,4,8],programInfos:{},stringCache:{},tempFixedLengthArray:[],packAlignment:4,unpackAlignment:4,init:function () {
  1586. GL.miniTempBuffer = new Float32Array(GL.MINI_TEMP_BUFFER_SIZE);
  1587. for (var i = 0; i < GL.MINI_TEMP_BUFFER_SIZE; i++) {
  1588. GL.miniTempBufferViews[i] = GL.miniTempBuffer.subarray(0, i+1);
  1589. }
  1590. // For functions such as glDrawBuffers, glInvalidateFramebuffer and glInvalidateSubFramebuffer that need to pass a short array to the WebGL API,
  1591. // create a set of short fixed-length arrays to avoid having to generate any garbage when calling those functions.
  1592. for (var i = 0; i < 32; i++) {
  1593. GL.tempFixedLengthArray.push(new Array(i));
  1594. }
  1595. },recordError:function recordError(errorCode) {
  1596. if (!GL.lastError) {
  1597. GL.lastError = errorCode;
  1598. }
  1599. },getNewId:function (table) {
  1600. var ret = GL.counter++;
  1601. for (var i = table.length; i < ret; i++) {
  1602. table[i] = null;
  1603. }
  1604. return ret;
  1605. },MINI_TEMP_BUFFER_SIZE:256,miniTempBuffer:null,miniTempBufferViews:[0],getSource:function (shader, count, string, length) {
  1606. var source = '';
  1607. for (var i = 0; i < count; ++i) {
  1608. var frag;
  1609. if (length) {
  1610. var len = HEAP32[(((length)+(i*4))>>2)];
  1611. if (len < 0) {
  1612. frag = Pointer_stringify(HEAP32[(((string)+(i*4))>>2)]);
  1613. } else {
  1614. frag = Pointer_stringify(HEAP32[(((string)+(i*4))>>2)], len);
  1615. }
  1616. } else {
  1617. frag = Pointer_stringify(HEAP32[(((string)+(i*4))>>2)]);
  1618. }
  1619. source += frag;
  1620. }
  1621. return source;
  1622. },createContext:function (canvas, webGLContextAttributes) {
  1623. if (typeof webGLContextAttributes['majorVersion'] === 'undefined' && typeof webGLContextAttributes['minorVersion'] === 'undefined') {
  1624. webGLContextAttributes['majorVersion'] = 1;
  1625. webGLContextAttributes['minorVersion'] = 0;
  1626. }
  1627. var ctx;
  1628. var errorInfo = '?';
  1629. function onContextCreationError(event) {
  1630. errorInfo = event.statusMessage || errorInfo;
  1631. }
  1632. try {
  1633. canvas.addEventListener('webglcontextcreationerror', onContextCreationError, false);
  1634. try {
  1635. if (webGLContextAttributes['majorVersion'] == 1 && webGLContextAttributes['minorVersion'] == 0) {
  1636. ctx = canvas.getContext("webgl", webGLContextAttributes) || canvas.getContext("experimental-webgl", webGLContextAttributes);
  1637. } else if (webGLContextAttributes['majorVersion'] == 2 && webGLContextAttributes['minorVersion'] == 0) {
  1638. ctx = canvas.getContext("webgl2", webGLContextAttributes) || canvas.getContext("experimental-webgl2", webGLContextAttributes);
  1639. } else {
  1640. throw 'Unsupported WebGL context version ' + majorVersion + '.' + minorVersion + '!'
  1641. }
  1642. } finally {
  1643. canvas.removeEventListener('webglcontextcreationerror', onContextCreationError, false);
  1644. }
  1645. if (!ctx) throw ':(';
  1646. } catch (e) {
  1647. Module.print('Could not create canvas: ' + [errorInfo, e, JSON.stringify(webGLContextAttributes)]);
  1648. return 0;
  1649. }
  1650. // possible GL_DEBUG entry point: ctx = wrapDebugGL(ctx);
  1651. if (!ctx) return 0;
  1652. return GL.registerContext(ctx, webGLContextAttributes);
  1653. },registerContext:function (ctx, webGLContextAttributes) {
  1654. var handle = GL.getNewId(GL.contexts);
  1655. var context = {
  1656. handle: handle,
  1657. attributes: webGLContextAttributes,
  1658. version: webGLContextAttributes['majorVersion'],
  1659. GLctx: ctx
  1660. };
  1661. // Store the created context object so that we can access the context given a canvas without having to pass the parameters again.
  1662. if (ctx.canvas) ctx.canvas.GLctxObject = context;
  1663. GL.contexts[handle] = context;
  1664. if (typeof webGLContextAttributes['enableExtensionsByDefault'] === 'undefined' || webGLContextAttributes['enableExtensionsByDefault']) {
  1665. GL.initExtensions(context);
  1666. }
  1667. return handle;
  1668. },makeContextCurrent:function (contextHandle) {
  1669. var context = GL.contexts[contextHandle];
  1670. if (!context) return false;
  1671. GLctx = Module.ctx = context.GLctx; // Active WebGL context object.
  1672. GL.currentContext = context; // Active Emscripten GL layer context object.
  1673. return true;
  1674. },getContext:function (contextHandle) {
  1675. return GL.contexts[contextHandle];
  1676. },deleteContext:function (contextHandle) {
  1677. if (GL.currentContext === GL.contexts[contextHandle]) GL.currentContext = null;
  1678. if (typeof JSEvents === 'object') JSEvents.removeAllHandlersOnTarget(GL.contexts[contextHandle].GLctx.canvas); // Release all JS event handlers on the DOM element that the GL context is associated with since the context is now deleted.
  1679. if (GL.contexts[contextHandle] && GL.contexts[contextHandle].GLctx.canvas) GL.contexts[contextHandle].GLctx.canvas.GLctxObject = undefined; // Make sure the canvas object no longer refers to the context object so there are no GC surprises.
  1680. GL.contexts[contextHandle] = null;
  1681. },initExtensions:function (context) {
  1682. // If this function is called without a specific context object, init the extensions of the currently active context.
  1683. if (!context) context = GL.currentContext;
  1684. if (context.initExtensionsDone) return;
  1685. context.initExtensionsDone = true;
  1686. var GLctx = context.GLctx;
  1687. context.maxVertexAttribs = GLctx.getParameter(GLctx.MAX_VERTEX_ATTRIBS);
  1688. // Detect the presence of a few extensions manually, this GL interop layer itself will need to know if they exist.
  1689. if (context.version < 2) {
  1690. // Extension available from Firefox 26 and Google Chrome 30
  1691. var instancedArraysExt = GLctx.getExtension('ANGLE_instanced_arrays');
  1692. if (instancedArraysExt) {
  1693. GLctx['vertexAttribDivisor'] = function(index, divisor) { instancedArraysExt['vertexAttribDivisorANGLE'](index, divisor); };
  1694. GLctx['drawArraysInstanced'] = function(mode, first, count, primcount) { instancedArraysExt['drawArraysInstancedANGLE'](mode, first, count, primcount); };
  1695. GLctx['drawElementsInstanced'] = function(mode, count, type, indices, primcount) { instancedArraysExt['drawElementsInstancedANGLE'](mode, count, type, indices, primcount); };
  1696. }
  1697. // Extension available from Firefox 25 and WebKit
  1698. var vaoExt = GLctx.getExtension('OES_vertex_array_object');
  1699. if (vaoExt) {
  1700. GLctx['createVertexArray'] = function() { return vaoExt['createVertexArrayOES'](); };
  1701. GLctx['deleteVertexArray'] = function(vao) { vaoExt['deleteVertexArrayOES'](vao); };
  1702. GLctx['bindVertexArray'] = function(vao) { vaoExt['bindVertexArrayOES'](vao); };
  1703. GLctx['isVertexArray'] = function(vao) { return vaoExt['isVertexArrayOES'](vao); };
  1704. }
  1705. var drawBuffersExt = GLctx.getExtension('WEBGL_draw_buffers');
  1706. if (drawBuffersExt) {
  1707. GLctx['drawBuffers'] = function(n, bufs) { drawBuffersExt['drawBuffersWEBGL'](n, bufs); };
  1708. }
  1709. }
  1710. GLctx.disjointTimerQueryExt = GLctx.getExtension("EXT_disjoint_timer_query");
  1711. // These are the 'safe' feature-enabling extensions that don't add any performance impact related to e.g. debugging, and
  1712. // should be enabled by default so that client GLES2/GL code will not need to go through extra hoops to get its stuff working.
  1713. // As new extensions are ratified at http://www.khronos.org/registry/webgl/extensions/ , feel free to add your new extensions
  1714. // here, as long as they don't produce a performance impact for users that might not be using those extensions.
  1715. // E.g. debugging-related extensions should probably be off by default.
  1716. var automaticallyEnabledExtensions = [ "OES_texture_float", "OES_texture_half_float", "OES_standard_derivatives",
  1717. "OES_vertex_array_object", "WEBGL_compressed_texture_s3tc", "WEBGL_depth_texture",
  1718. "OES_element_index_uint", "EXT_texture_filter_anisotropic", "ANGLE_instanced_arrays",
  1719. "OES_texture_float_linear", "OES_texture_half_float_linear", "WEBGL_compressed_texture_atc",
  1720. "WEBGL_compressed_texture_pvrtc", "EXT_color_buffer_half_float", "WEBGL_color_buffer_float",
  1721. "EXT_frag_depth", "EXT_sRGB", "WEBGL_draw_buffers", "WEBGL_shared_resources",
  1722. "EXT_shader_texture_lod", "EXT_color_buffer_float"];
  1723. function shouldEnableAutomatically(extension) {
  1724. var ret = false;
  1725. automaticallyEnabledExtensions.forEach(function(include) {
  1726. if (ext.indexOf(include) != -1) {
  1727. ret = true;
  1728. }
  1729. });
  1730. return ret;
  1731. }
  1732. var exts = GLctx.getSupportedExtensions();
  1733. if (exts && exts.length > 0) {
  1734. GLctx.getSupportedExtensions().forEach(function(ext) {
  1735. if (automaticallyEnabledExtensions.indexOf(ext) != -1) {
  1736. GLctx.getExtension(ext); // Calling .getExtension enables that extension permanently, no need to store the return value to be enabled.
  1737. }
  1738. });
  1739. }
  1740. },populateUniformTable:function (program) {
  1741. var p = GL.programs[program];
  1742. GL.programInfos[program] = {
  1743. uniforms: {},
  1744. maxUniformLength: 0, // This is eagerly computed below, since we already enumerate all uniforms anyway.
  1745. maxAttributeLength: -1, // This is lazily computed and cached, computed when/if first asked, "-1" meaning not computed yet.
  1746. maxUniformBlockNameLength: -1 // Lazily computed as well
  1747. };
  1748. var ptable = GL.programInfos[program];
  1749. var utable = ptable.uniforms;
  1750. // A program's uniform table maps the string name of an uniform to an integer location of that uniform.
  1751. // The global GL.uniforms map maps integer locations to WebGLUniformLocations.
  1752. var numUniforms = GLctx.getProgramParameter(p, GLctx.ACTIVE_UNIFORMS);
  1753. for (var i = 0; i < numUniforms; ++i) {
  1754. var u = GLctx.getActiveUniform(p, i);
  1755. var name = u.name;
  1756. ptable.maxUniformLength = Math.max(ptable.maxUniformLength, name.length+1);
  1757. // Strip off any trailing array specifier we might have got, e.g. "[0]".
  1758. if (name.indexOf(']', name.length-1) !== -1) {
  1759. var ls = name.lastIndexOf('[');
  1760. name = name.slice(0, ls);
  1761. }
  1762. // Optimize memory usage slightly: If we have an array of uniforms, e.g. 'vec3 colors[3];', then
  1763. // only store the string 'colors' in utable, and 'colors[0]', 'colors[1]' and 'colors[2]' will be parsed as 'colors'+i.
  1764. // Note that for the GL.uniforms table, we still need to fetch the all WebGLUniformLocations for all the indices.
  1765. var loc = GLctx.getUniformLocation(p, name);
  1766. if (loc != null)
  1767. {
  1768. var id = GL.getNewId(GL.uniforms);
  1769. utable[name] = [u.size, id];
  1770. GL.uniforms[id] = loc;
  1771. for (var j = 1; j < u.size; ++j) {
  1772. var n = name + '['+j+']';
  1773. loc = GLctx.getUniformLocation(p, n);
  1774. id = GL.getNewId(GL.uniforms);
  1775. GL.uniforms[id] = loc;
  1776. }
  1777. }
  1778. }
  1779. }};function _emscripten_glIsRenderbuffer(renderbuffer) {
  1780. var rb = GL.renderbuffers[renderbuffer];
  1781. if (!rb) return 0;
  1782. return GLctx.isRenderbuffer(rb);
  1783. }
  1784. function _emscripten_glStencilMaskSeparate(x0, x1) { GLctx['stencilMaskSeparate'](x0, x1) }
  1785. function _emscripten_get_now() { abort() }
  1786. function _emscripten_set_main_loop_timing(mode, value) {
  1787. Browser.mainLoop.timingMode = mode;
  1788. Browser.mainLoop.timingValue = value;
  1789. if (!Browser.mainLoop.func) {
  1790. console.error('emscripten_set_main_loop_timing: Cannot set timing mode for main loop since a main loop does not exist! Call emscripten_set_main_loop first to set one up.');
  1791. return 1; // Return non-zero on failure, can't set timing mode when there is no main loop.
  1792. }
  1793. if (mode == 0 /*EM_TIMING_SETTIMEOUT*/) {
  1794. Browser.mainLoop.scheduler = function Browser_mainLoop_scheduler_setTimeout() {
  1795. var timeUntilNextTick = Math.max(0, Browser.mainLoop.tickStartTime + value - _emscripten_get_now())|0;
  1796. setTimeout(Browser.mainLoop.runner, timeUntilNextTick); // doing this each time means that on exception, we stop
  1797. };
  1798. Browser.mainLoop.method = 'timeout';
  1799. } else if (mode == 1 /*EM_TIMING_RAF*/) {
  1800. Browser.mainLoop.scheduler = function Browser_mainLoop_scheduler_rAF() {
  1801. Browser.requestAnimationFrame(Browser.mainLoop.runner);
  1802. };
  1803. Browser.mainLoop.method = 'rAF';
  1804. } else if (mode == 2 /*EM_TIMING_SETIMMEDIATE*/) {
  1805. if (!window['setImmediate']) {
  1806. // Emulate setImmediate. (note: not a complete polyfill, we don't emulate clearImmediate() to keep code size to minimum, since not needed)
  1807. var setImmediates = [];
  1808. var emscriptenMainLoopMessageId = 'setimmediate';
  1809. function Browser_setImmediate_messageHandler(event) {
  1810. if (event.source === window && event.data === emscriptenMainLoopMessageId) {
  1811. event.stopPropagation();
  1812. setImmediates.shift()();
  1813. }
  1814. }
  1815. window.addEventListener("message", Browser_setImmediate_messageHandler, true);
  1816. window['setImmediate'] = function Browser_emulated_setImmediate(func) {
  1817. setImmediates.push(func);
  1818. if (ENVIRONMENT_IS_WORKER) {
  1819. if (Module['setImmediates'] === undefined) Module['setImmediates'] = [];
  1820. Module['setImmediates'].push(func);
  1821. window.postMessage({target: emscriptenMainLoopMessageId}); // In --proxy-to-worker, route the message via proxyClient.js
  1822. } else window.postMessage(emscriptenMainLoopMessageId, "*"); // On the main thread, can just send the message to itself.
  1823. }
  1824. }
  1825. Browser.mainLoop.scheduler = function Browser_mainLoop_scheduler_setImmediate() {
  1826. window['setImmediate'](Browser.mainLoop.runner);
  1827. };
  1828. Browser.mainLoop.method = 'immediate';
  1829. }
  1830. return 0;
  1831. }function _emscripten_set_main_loop(func, fps, simulateInfiniteLoop, arg, noSetTiming) {
  1832. Module['noExitRuntime'] = true;
  1833. assert(!Browser.mainLoop.func, 'emscripten_set_main_loop: there can only be one main loop function at once: call emscripten_cancel_main_loop to cancel the previous one before setting a new one with different parameters.');
  1834. Browser.mainLoop.func = func;
  1835. Browser.mainLoop.arg = arg;
  1836. var browserIterationFunc;
  1837. if (typeof arg !== 'undefined') {
  1838. browserIterationFunc = function() {
  1839. Module['dynCall_vi'](func, arg);
  1840. };
  1841. } else {
  1842. browserIterationFunc = function() {
  1843. Module['dynCall_v'](func);
  1844. };
  1845. }
  1846. var thisMainLoopId = Browser.mainLoop.currentlyRunningMainloop;
  1847. Browser.mainLoop.runner = function Browser_mainLoop_runner() {
  1848. if (ABORT) return;
  1849. if (Browser.mainLoop.queue.length > 0) {
  1850. var start = Date.now();
  1851. var blocker = Browser.mainLoop.queue.shift();
  1852. blocker.func(blocker.arg);
  1853. if (Browser.mainLoop.remainingBlockers) {
  1854. var remaining = Browser.mainLoop.remainingBlockers;
  1855. var next = remaining%1 == 0 ? remaining-1 : Math.floor(remaining);
  1856. if (blocker.counted) {
  1857. Browser.mainLoop.remainingBlockers = next;
  1858. } else {
  1859. // not counted, but move the progress along a tiny bit
  1860. next = next + 0.5; // do not steal all the next one's progress
  1861. Browser.mainLoop.remainingBlockers = (8*remaining + next)/9;
  1862. }
  1863. }
  1864. console.log('main loop blocker "' + blocker.name + '" took ' + (Date.now() - start) + ' ms'); //, left: ' + Browser.mainLoop.remainingBlockers);
  1865. Browser.mainLoop.updateStatus();
  1866. // catches pause/resume main loop from blocker execution
  1867. if (thisMainLoopId < Browser.mainLoop.currentlyRunningMainloop) return;
  1868. setTimeout(Browser.mainLoop.runner, 0);
  1869. return;
  1870. }
  1871. // catch pauses from non-main loop sources
  1872. if (thisMainLoopId < Browser.mainLoop.currentlyRunningMainloop) return;
  1873. // Implement very basic swap interval control
  1874. Browser.mainLoop.currentFrameNumber = Browser.mainLoop.currentFrameNumber + 1 | 0;
  1875. if (Browser.mainLoop.timingMode == 1/*EM_TIMING_RAF*/ && Browser.mainLoop.timingValue > 1 && Browser.mainLoop.currentFrameNumber % Browser.mainLoop.timingValue != 0) {
  1876. // Not the scheduled time to render this frame - skip.
  1877. Browser.mainLoop.scheduler();
  1878. return;
  1879. } else if (Browser.mainLoop.timingMode == 0/*EM_TIMING_SETTIMEOUT*/) {
  1880. Browser.mainLoop.tickStartTime = _emscripten_get_now();
  1881. }
  1882. // Signal GL rendering layer that processing of a new frame is about to start. This helps it optimize
  1883. // VBO double-buffering and reduce GPU stalls.
  1884. if (Browser.mainLoop.method === 'timeout' && Module.ctx) {
  1885. Module.printErr('Looks like you are rendering without using requestAnimationFrame for the main loop. You should use 0 for the frame rate in emscripten_set_main_loop in order to use requestAnimationFrame, as that can greatly improve your frame rates!');
  1886. Browser.mainLoop.method = ''; // just warn once per call to set main loop
  1887. }
  1888. Browser.mainLoop.runIter(browserIterationFunc);
  1889. checkStackCookie();
  1890. // catch pauses from the main loop itself
  1891. if (thisMainLoopId < Browser.mainLoop.currentlyRunningMainloop) return;
  1892. // Queue new audio data. This is important to be right after the main loop invocation, so that we will immediately be able
  1893. // to queue the newest produced audio samples.
  1894. // TODO: Consider adding pre- and post- rAF callbacks so that GL.newRenderingFrameStarted() and SDL.audio.queueNewAudioData()
  1895. // do not need to be hardcoded into this function, but can be more generic.
  1896. if (typeof SDL === 'object' && SDL.audio && SDL.audio.queueNewAudioData) SDL.audio.queueNewAudioData();
  1897. Browser.mainLoop.scheduler();
  1898. }
  1899. if (!noSetTiming) {
  1900. if (fps && fps > 0) _emscripten_set_main_loop_timing(0/*EM_TIMING_SETTIMEOUT*/, 1000.0 / fps);
  1901. else _emscripten_set_main_loop_timing(1/*EM_TIMING_RAF*/, 1); // Do rAF by rendering each frame (no decimating)
  1902. Browser.mainLoop.scheduler();
  1903. }
  1904. if (simulateInfiniteLoop) {
  1905. throw 'SimulateInfiniteLoop';
  1906. }
  1907. }var Browser={mainLoop:{scheduler:null,method:"",currentlyRunningMainloop:0,func:null,arg:0,timingMode:0,timingValue:0,currentFrameNumber:0,queue:[],pause:function () {
  1908. Browser.mainLoop.scheduler = null;
  1909. Browser.mainLoop.currentlyRunningMainloop++; // Incrementing this signals the previous main loop that it's now become old, and it must return.
  1910. },resume:function () {
  1911. Browser.mainLoop.currentlyRunningMainloop++;
  1912. var timingMode = Browser.mainLoop.timingMode;
  1913. var timingValue = Browser.mainLoop.timingValue;
  1914. var func = Browser.mainLoop.func;
  1915. Browser.mainLoop.func = null;
  1916. _emscripten_set_main_loop(func, 0, false, Browser.mainLoop.arg, true /* do not set timing and call scheduler, we will do it on the next lines */);
  1917. _emscripten_set_main_loop_timing(timingMode, timingValue);
  1918. Browser.mainLoop.scheduler();
  1919. },updateStatus:function () {
  1920. if (Module['setStatus']) {
  1921. var message = Module['statusMessage'] || 'Please wait...';
  1922. var remaining = Browser.mainLoop.remainingBlockers;
  1923. var expected = Browser.mainLoop.expectedBlockers;
  1924. if (remaining) {
  1925. if (remaining < expected) {
  1926. Module['setStatus'](message + ' (' + (expected - remaining) + '/' + expected + ')');
  1927. } else {
  1928. Module['setStatus'](message);
  1929. }
  1930. } else {
  1931. Module['setStatus']('');
  1932. }
  1933. }
  1934. },runIter:function (func) {
  1935. if (ABORT) return;
  1936. if (Module['preMainLoop']) {
  1937. var preRet = Module['preMainLoop']();
  1938. if (preRet === false) {
  1939. return; // |return false| skips a frame
  1940. }
  1941. }
  1942. try {
  1943. func();
  1944. } catch (e) {
  1945. if (e instanceof ExitStatus) {
  1946. return;
  1947. } else {
  1948. if (e && typeof e === 'object' && e.stack) Module.printErr('exception thrown: ' + [e, e.stack]);
  1949. throw e;
  1950. }
  1951. }
  1952. if (Module['postMainLoop']) Module['postMainLoop']();
  1953. }},isFullscreen:false,pointerLock:false,moduleContextCreatedCallbacks:[],workers:[],init:function () {
  1954. if (!Module["preloadPlugins"]) Module["preloadPlugins"] = []; // needs to exist even in workers
  1955. if (Browser.initted) return;
  1956. Browser.initted = true;
  1957. try {
  1958. new Blob();
  1959. Browser.hasBlobConstructor = true;
  1960. } catch(e) {
  1961. Browser.hasBlobConstructor = false;
  1962. console.log("warning: no blob constructor, cannot create blobs with mimetypes");
  1963. }
  1964. Browser.BlobBuilder = typeof MozBlobBuilder != "undefined" ? MozBlobBuilder : (typeof WebKitBlobBuilder != "undefined" ? WebKitBlobBuilder : (!Browser.hasBlobConstructor ? console.log("warning: no BlobBuilder") : null));
  1965. Browser.URLObject = typeof window != "undefined" ? (window.URL ? window.URL : window.webkitURL) : undefined;
  1966. if (!Module.noImageDecoding && typeof Browser.URLObject === 'undefined') {
  1967. console.log("warning: Browser does not support creating object URLs. Built-in browser image decoding will not be available.");
  1968. Module.noImageDecoding = true;
  1969. }
  1970. // Support for plugins that can process preloaded files. You can add more of these to
  1971. // your app by creating and appending to Module.preloadPlugins.
  1972. //
  1973. // Each plugin is asked if it can handle a file based on the file's name. If it can,
  1974. // it is given the file's raw data. When it is done, it calls a callback with the file's
  1975. // (possibly modified) data. For example, a plugin might decompress a file, or it
  1976. // might create some side data structure for use later (like an Image element, etc.).
  1977. var imagePlugin = {};
  1978. imagePlugin['canHandle'] = function imagePlugin_canHandle(name) {
  1979. return !Module.noImageDecoding && /\.(jpg|jpeg|png|bmp)$/i.test(name);
  1980. };
  1981. imagePlugin['handle'] = function imagePlugin_handle(byteArray, name, onload, onerror) {
  1982. var b = null;
  1983. if (Browser.hasBlobConstructor) {
  1984. try {
  1985. b = new Blob([byteArray], { type: Browser.getMimetype(name) });
  1986. if (b.size !== byteArray.length) { // Safari bug #118630
  1987. // Safari's Blob can only take an ArrayBuffer
  1988. b = new Blob([(new Uint8Array(byteArray)).buffer], { type: Browser.getMimetype(name) });
  1989. }
  1990. } catch(e) {
  1991. Runtime.warnOnce('Blob constructor present but fails: ' + e + '; falling back to blob builder');
  1992. }
  1993. }
  1994. if (!b) {
  1995. var bb = new Browser.BlobBuilder();
  1996. bb.append((new Uint8Array(byteArray)).buffer); // we need to pass a buffer, and must copy the array to get the right data range
  1997. b = bb.getBlob();
  1998. }
  1999. var url = Browser.URLObject.createObjectURL(b);
  2000. assert(typeof url == 'string', 'createObjectURL must return a url as a string');
  2001. var img = new Image();
  2002. img.onload = function img_onload() {
  2003. assert(img.complete, 'Image ' + name + ' could not be decoded');
  2004. var canvas = document.createElement('canvas');
  2005. canvas.width = img.width;
  2006. canvas.height = img.height;
  2007. var ctx = canvas.getContext('2d');
  2008. ctx.drawImage(img, 0, 0);
  2009. Module["preloadedImages"][name] = canvas;
  2010. Browser.URLObject.revokeObjectURL(url);
  2011. if (onload) onload(byteArray);
  2012. };
  2013. img.onerror = function img_onerror(event) {
  2014. console.log('Image ' + url + ' could not be decoded');
  2015. if (onerror) onerror();
  2016. };
  2017. img.src = url;
  2018. };
  2019. Module['preloadPlugins'].push(imagePlugin);
  2020. var audioPlugin = {};
  2021. audioPlugin['canHandle'] = function audioPlugin_canHandle(name) {
  2022. return !Module.noAudioDecoding && name.substr(-4) in { '.ogg': 1, '.wav': 1, '.mp3': 1 };
  2023. };
  2024. audioPlugin['handle'] = function audioPlugin_handle(byteArray, name, onload, onerror) {
  2025. var done = false;
  2026. function finish(audio) {
  2027. if (done) return;
  2028. done = true;
  2029. Module["preloadedAudios"][name] = audio;
  2030. if (onload) onload(byteArray);
  2031. }
  2032. function fail() {
  2033. if (done) return;
  2034. done = true;
  2035. Module["preloadedAudios"][name] = new Audio(); // empty shim
  2036. if (onerror) onerror();
  2037. }
  2038. if (Browser.hasBlobConstructor) {
  2039. try {
  2040. var b = new Blob([byteArray], { type: Browser.getMimetype(name) });
  2041. } catch(e) {
  2042. return fail();
  2043. }
  2044. var url = Browser.URLObject.createObjectURL(b); // XXX we never revoke this!
  2045. assert(typeof url == 'string', 'createObjectURL must return a url as a string');
  2046. var audio = new Audio();
  2047. audio.addEventListener('canplaythrough', function() { finish(audio) }, false); // use addEventListener due to chromium bug 124926
  2048. audio.onerror = function audio_onerror(event) {
  2049. if (done) return;
  2050. console.log('warning: browser could not fully decode audio ' + name + ', trying slower base64 approach');
  2051. function encode64(data) {
  2052. var BASE = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
  2053. var PAD = '=';
  2054. var ret = '';
  2055. var leftchar = 0;
  2056. var leftbits = 0;
  2057. for (var i = 0; i < data.length; i++) {
  2058. leftchar = (leftchar << 8) | data[i];
  2059. leftbits += 8;
  2060. while (leftbits >= 6) {
  2061. var curr = (leftchar >> (leftbits-6)) & 0x3f;
  2062. leftbits -= 6;
  2063. ret += BASE[curr];
  2064. }
  2065. }
  2066. if (leftbits == 2) {
  2067. ret += BASE[(leftchar&3) << 4];
  2068. ret += PAD + PAD;
  2069. } else if (leftbits == 4) {
  2070. ret += BASE[(leftchar&0xf) << 2];
  2071. ret += PAD;
  2072. }
  2073. return ret;
  2074. }
  2075. audio.src = 'data:audio/x-' + name.substr(-3) + ';base64,' + encode64(byteArray);
  2076. finish(audio); // we don't wait for confirmation this worked - but it's worth trying
  2077. };
  2078. audio.src = url;
  2079. // workaround for chrome bug 124926 - we do not always get oncanplaythrough or onerror
  2080. Browser.safeSetTimeout(function() {
  2081. finish(audio); // try to use it even though it is not necessarily ready to play
  2082. }, 10000);
  2083. } else {
  2084. return fail();
  2085. }
  2086. };
  2087. Module['preloadPlugins'].push(audioPlugin);
  2088. // Canvas event setup
  2089. function pointerLockChange() {
  2090. Browser.pointerLock = document['pointerLockElement'] === Module['canvas'] ||
  2091. document['mozPointerLockElement'] === Module['canvas'] ||
  2092. document['webkitPointerLockElement'] === Module['canvas'] ||
  2093. document['msPointerLockElement'] === Module['canvas'];
  2094. }
  2095. var canvas = Module['canvas'];
  2096. if (canvas) {
  2097. // forced aspect ratio can be enabled by defining 'forcedAspectRatio' on Module
  2098. // Module['forcedAspectRatio'] = 4 / 3;
  2099. canvas.requestPointerLock = canvas['requestPointerLock'] ||
  2100. canvas['mozRequestPointerLock'] ||
  2101. canvas['webkitRequestPointerLock'] ||
  2102. canvas['msRequestPointerLock'] ||
  2103. function(){};
  2104. canvas.exitPointerLock = document['exitPointerLock'] ||
  2105. document['mozExitPointerLock'] ||
  2106. document['webkitExitPointerLock'] ||
  2107. document['msExitPointerLock'] ||
  2108. function(){}; // no-op if function does not exist
  2109. canvas.exitPointerLock = canvas.exitPointerLock.bind(document);
  2110. document.addEventListener('pointerlockchange', pointerLockChange, false);
  2111. document.addEventListener('mozpointerlockchange', pointerLockChange, false);
  2112. document.addEventListener('webkitpointerlockchange', pointerLockChange, false);
  2113. document.addEventListener('mspointerlockchange', pointerLockChange, false);
  2114. if (Module['elementPointerLock']) {
  2115. canvas.addEventListener("click", function(ev) {
  2116. if (!Browser.pointerLock && Module['canvas'].requestPointerLock) {
  2117. Module['canvas'].requestPointerLock();
  2118. ev.preventDefault();
  2119. }
  2120. }, false);
  2121. }
  2122. }
  2123. },createContext:function (canvas, useWebGL, setInModule, webGLContextAttributes) {
  2124. if (useWebGL && Module.ctx && canvas == Module.canvas) return Module.ctx; // no need to recreate GL context if it's already been created for this canvas.
  2125. var ctx;
  2126. var contextHandle;
  2127. if (useWebGL) {
  2128. // For GLES2/desktop GL compatibility, adjust a few defaults to be different to WebGL defaults, so that they align better with the desktop defaults.
  2129. var contextAttributes = {
  2130. antialias: false,
  2131. alpha: false
  2132. };
  2133. if (webGLContextAttributes) {
  2134. for (var attribute in webGLContextAttributes) {
  2135. contextAttributes[attribute] = webGLContextAttributes[attribute];
  2136. }
  2137. }
  2138. contextHandle = GL.createContext(canvas, contextAttributes);
  2139. if (contextHandle) {
  2140. ctx = GL.getContext(contextHandle).GLctx;
  2141. }
  2142. } else {
  2143. ctx = canvas.getContext('2d');
  2144. }
  2145. if (!ctx) return null;
  2146. if (setInModule) {
  2147. if (!useWebGL) assert(typeof GLctx === 'undefined', 'cannot set in module if GLctx is used, but we are a non-GL context that would replace it');
  2148. Module.ctx = ctx;
  2149. if (useWebGL) GL.makeContextCurrent(contextHandle);
  2150. Module.useWebGL = useWebGL;
  2151. Browser.moduleContextCreatedCallbacks.forEach(function(callback) { callback() });
  2152. Browser.init();
  2153. }
  2154. return ctx;
  2155. },destroyContext:function (canvas, useWebGL, setInModule) {},fullscreenHandlersInstalled:false,lockPointer:undefined,resizeCanvas:undefined,requestFullscreen:function (lockPointer, resizeCanvas, vrDevice) {
  2156. Browser.lockPointer = lockPointer;
  2157. Browser.resizeCanvas = resizeCanvas;
  2158. Browser.vrDevice = vrDevice;
  2159. if (typeof Browser.lockPointer === 'undefined') Browser.lockPointer = true;
  2160. if (typeof Browser.resizeCanvas === 'undefined') Browser.resizeCanvas = false;
  2161. if (typeof Browser.vrDevice === 'undefined') Browser.vrDevice = null;
  2162. var canvas = Module['canvas'];
  2163. function fullscreenChange() {
  2164. Browser.isFullscreen = false;
  2165. var canvasContainer = canvas.parentNode;
  2166. if ((document['fullscreenElement'] || document['mozFullScreenElement'] ||
  2167. document['msFullscreenElement'] || document['webkitFullscreenElement'] ||
  2168. document['webkitCurrentFullScreenElement']) === canvasContainer) {
  2169. canvas.exitFullscreen = document['exitFullscreen'] ||
  2170. document['cancelFullScreen'] ||
  2171. document['mozCancelFullScreen'] ||
  2172. document['msExitFullscreen'] ||
  2173. document['webkitCancelFullScreen'] ||
  2174. function() {};
  2175. canvas.exitFullscreen = canvas.exitFullscreen.bind(document);
  2176. if (Browser.lockPointer) canvas.requestPointerLock();
  2177. Browser.isFullscreen = true;
  2178. if (Browser.resizeCanvas) Browser.setFullscreenCanvasSize();
  2179. } else {
  2180. // remove the full screen specific parent of the canvas again to restore the HTML structure from before going full screen
  2181. canvasContainer.parentNode.insertBefore(canvas, canvasContainer);
  2182. canvasContainer.parentNode.removeChild(canvasContainer);
  2183. if (Browser.resizeCanvas) Browser.setWindowedCanvasSize();
  2184. }
  2185. if (Module['onFullScreen']) Module['onFullScreen'](Browser.isFullscreen);
  2186. if (Module['onFullscreen']) Module['onFullscreen'](Browser.isFullscreen);
  2187. Browser.updateCanvasDimensions(canvas);
  2188. }
  2189. if (!Browser.fullscreenHandlersInstalled) {
  2190. Browser.fullscreenHandlersInstalled = true;
  2191. document.addEventListener('fullscreenchange', fullscreenChange, false);
  2192. document.addEventListener('mozfullscreenchange', fullscreenChange, false);
  2193. document.addEventListener('webkitfullscreenchange', fullscreenChange, false);
  2194. document.addEventListener('MSFullscreenChange', fullscreenChange, false);
  2195. }
  2196. // create a new parent to ensure the canvas has no siblings. this allows browsers to optimize full screen performance when its parent is the full screen root
  2197. var canvasContainer = document.createElement("div");
  2198. canvas.parentNode.insertBefore(canvasContainer, canvas);
  2199. canvasContainer.appendChild(canvas);
  2200. // use parent of canvas as full screen root to allow aspect ratio correction (Firefox stretches the root to screen size)
  2201. canvasContainer.requestFullscreen = canvasContainer['requestFullscreen'] ||
  2202. canvasContainer['mozRequestFullScreen'] ||
  2203. canvasContainer['msRequestFullscreen'] ||
  2204. (canvasContainer['webkitRequestFullscreen'] ? function() { canvasContainer['webkitRequestFullscreen'](Element['ALLOW_KEYBOARD_INPUT']) } : null) ||
  2205. (canvasContainer['webkitRequestFullScreen'] ? function() { canvasContainer['webkitRequestFullScreen'](Element['ALLOW_KEYBOARD_INPUT']) } : null);
  2206. if (vrDevice) {
  2207. canvasContainer.requestFullscreen({ vrDisplay: vrDevice });
  2208. } else {
  2209. canvasContainer.requestFullscreen();
  2210. }
  2211. },requestFullScreen:function (lockPointer, resizeCanvas, vrDevice) {
  2212. Module.printErr('Browser.requestFullScreen() is deprecated. Please call Browser.requestFullscreen instead.');
  2213. Browser.requestFullScreen = function(lockPointer, resizeCanvas, vrDevice) {
  2214. return Browser.requestFullscreen(lockPointer, resizeCanvas, vrDevice);
  2215. }
  2216. return Browser.requestFullscreen(lockPointer, resizeCanvas, vrDevice);
  2217. },nextRAF:0,fakeRequestAnimationFrame:function (func) {
  2218. // try to keep 60fps between calls to here
  2219. var now = Date.now();
  2220. if (Browser.nextRAF === 0) {
  2221. Browser.nextRAF = now + 1000/60;
  2222. } else {
  2223. while (now + 2 >= Browser.nextRAF) { // fudge a little, to avoid timer jitter causing us to do lots of delay:0
  2224. Browser.nextRAF += 1000/60;
  2225. }
  2226. }
  2227. var delay = Math.max(Browser.nextRAF - now, 0);
  2228. setTimeout(func, delay);
  2229. },requestAnimationFrame:function requestAnimationFrame(func) {
  2230. if (typeof window === 'undefined') { // Provide fallback to setTimeout if window is undefined (e.g. in Node.js)
  2231. Browser.fakeRequestAnimationFrame(func);
  2232. } else {
  2233. if (!window.requestAnimationFrame) {
  2234. window.requestAnimationFrame = window['requestAnimationFrame'] ||
  2235. window['mozRequestAnimationFrame'] ||
  2236. window['webkitRequestAnimationFrame'] ||
  2237. window['msRequestAnimationFrame'] ||
  2238. window['oRequestAnimationFrame'] ||
  2239. Browser.fakeRequestAnimationFrame;
  2240. }
  2241. window.requestAnimationFrame(func);
  2242. }
  2243. },safeCallback:function (func) {
  2244. return function() {
  2245. if (!ABORT) return func.apply(null, arguments);
  2246. };
  2247. },allowAsyncCallbacks:true,queuedAsyncCallbacks:[],pauseAsyncCallbacks:function () {
  2248. Browser.allowAsyncCallbacks = false;
  2249. },resumeAsyncCallbacks:function () { // marks future callbacks as ok to execute, and synchronously runs any remaining ones right now
  2250. Browser.allowAsyncCallbacks = true;
  2251. if (Browser.queuedAsyncCallbacks.length > 0) {
  2252. var callbacks = Browser.queuedAsyncCallbacks;
  2253. Browser.queuedAsyncCallbacks = [];
  2254. callbacks.forEach(function(func) {
  2255. func();
  2256. });
  2257. }
  2258. },safeRequestAnimationFrame:function (func) {
  2259. return Browser.requestAnimationFrame(function() {
  2260. if (ABORT) return;
  2261. if (Browser.allowAsyncCallbacks) {
  2262. func();
  2263. } else {
  2264. Browser.queuedAsyncCallbacks.push(func);
  2265. }
  2266. });
  2267. },safeSetTimeout:function (func, timeout) {
  2268. Module['noExitRuntime'] = true;
  2269. return setTimeout(function() {
  2270. if (ABORT) return;
  2271. if (Browser.allowAsyncCallbacks) {
  2272. func();
  2273. } else {
  2274. Browser.queuedAsyncCallbacks.push(func);
  2275. }
  2276. }, timeout);
  2277. },safeSetInterval:function (func, timeout) {
  2278. Module['noExitRuntime'] = true;
  2279. return setInterval(function() {
  2280. if (ABORT) return;
  2281. if (Browser.allowAsyncCallbacks) {
  2282. func();
  2283. } // drop it on the floor otherwise, next interval will kick in
  2284. }, timeout);
  2285. },getMimetype:function (name) {
  2286. return {
  2287. 'jpg': 'image/jpeg',
  2288. 'jpeg': 'image/jpeg',
  2289. 'png': 'image/png',
  2290. 'bmp': 'image/bmp',
  2291. 'ogg': 'audio/ogg',
  2292. 'wav': 'audio/wav',
  2293. 'mp3': 'audio/mpeg'
  2294. }[name.substr(name.lastIndexOf('.')+1)];
  2295. },getUserMedia:function (func) {
  2296. if(!window.getUserMedia) {
  2297. window.getUserMedia = navigator['getUserMedia'] ||
  2298. navigator['mozGetUserMedia'];
  2299. }
  2300. window.getUserMedia(func);
  2301. },getMovementX:function (event) {
  2302. return event['movementX'] ||
  2303. event['mozMovementX'] ||
  2304. event['webkitMovementX'] ||
  2305. 0;
  2306. },getMovementY:function (event) {
  2307. return event['movementY'] ||
  2308. event['mozMovementY'] ||
  2309. event['webkitMovementY'] ||
  2310. 0;
  2311. },getMouseWheelDelta:function (event) {
  2312. var delta = 0;
  2313. switch (event.type) {
  2314. case 'DOMMouseScroll':
  2315. delta = event.detail;
  2316. break;
  2317. case 'mousewheel':
  2318. delta = event.wheelDelta;
  2319. break;
  2320. case 'wheel':
  2321. delta = event['deltaY'];
  2322. break;
  2323. default:
  2324. throw 'unrecognized mouse wheel event: ' + event.type;
  2325. }
  2326. return delta;
  2327. },mouseX:0,mouseY:0,mouseMovementX:0,mouseMovementY:0,touches:{},lastTouches:{},calculateMouseEvent:function (event) { // event should be mousemove, mousedown or mouseup
  2328. if (Browser.pointerLock) {
  2329. // When the pointer is locked, calculate the coordinates
  2330. // based on the movement of the mouse.
  2331. // Workaround for Firefox bug 764498
  2332. if (event.type != 'mousemove' &&
  2333. ('mozMovementX' in event)) {
  2334. Browser.mouseMovementX = Browser.mouseMovementY = 0;
  2335. } else {
  2336. Browser.mouseMovementX = Browser.getMovementX(event);
  2337. Browser.mouseMovementY = Browser.getMovementY(event);
  2338. }
  2339. // check if SDL is available
  2340. if (typeof SDL != "undefined") {
  2341. Browser.mouseX = SDL.mouseX + Browser.mouseMovementX;
  2342. Browser.mouseY = SDL.mouseY + Browser.mouseMovementY;
  2343. } else {
  2344. // just add the mouse delta to the current absolut mouse position
  2345. // FIXME: ideally this should be clamped against the canvas size and zero
  2346. Browser.mouseX += Browser.mouseMovementX;
  2347. Browser.mouseY += Browser.mouseMovementY;
  2348. }
  2349. } else {
  2350. // Otherwise, calculate the movement based on the changes
  2351. // in the coordinates.
  2352. var rect = Module["canvas"].getBoundingClientRect();
  2353. var cw = Module["canvas"].width;
  2354. var ch = Module["canvas"].height;
  2355. // Neither .scrollX or .pageXOffset are defined in a spec, but
  2356. // we prefer .scrollX because it is currently in a spec draft.
  2357. // (see: http://www.w3.org/TR/2013/WD-cssom-view-20131217/)
  2358. var scrollX = ((typeof window.scrollX !== 'undefined') ? window.scrollX : window.pageXOffset);
  2359. var scrollY = ((typeof window.scrollY !== 'undefined') ? window.scrollY : window.pageYOffset);
  2360. // If this assert lands, it's likely because the browser doesn't support scrollX or pageXOffset
  2361. // and we have no viable fallback.
  2362. assert((typeof scrollX !== 'undefined') && (typeof scrollY !== 'undefined'), 'Unable to retrieve scroll position, mouse positions likely broken.');
  2363. if (event.type === 'touchstart' || event.type === 'touchend' || event.type === 'touchmove') {
  2364. var touch = event.touch;
  2365. if (touch === undefined) {
  2366. return; // the "touch" property is only defined in SDL
  2367. }
  2368. var adjustedX = touch.pageX - (scrollX + rect.left);
  2369. var adjustedY = touch.pageY - (scrollY + rect.top);
  2370. adjustedX = adjustedX * (cw / rect.width);
  2371. adjustedY = adjustedY * (ch / rect.height);
  2372. var coords = { x: adjustedX, y: adjustedY };
  2373. if (event.type === 'touchstart') {
  2374. Browser.lastTouches[touch.identifier] = coords;
  2375. Browser.touches[touch.identifier] = coords;
  2376. } else if (event.type === 'touchend' || event.type === 'touchmove') {
  2377. var last = Browser.touches[touch.identifier];
  2378. if (!last) last = coords;
  2379. Browser.lastTouches[touch.identifier] = last;
  2380. Browser.touches[touch.identifier] = coords;
  2381. }
  2382. return;
  2383. }
  2384. var x = event.pageX - (scrollX + rect.left);
  2385. var y = event.pageY - (scrollY + rect.top);
  2386. // the canvas might be CSS-scaled compared to its backbuffer;
  2387. // SDL-using content will want mouse coordinates in terms
  2388. // of backbuffer units.
  2389. x = x * (cw / rect.width);
  2390. y = y * (ch / rect.height);
  2391. Browser.mouseMovementX = x - Browser.mouseX;
  2392. Browser.mouseMovementY = y - Browser.mouseY;
  2393. Browser.mouseX = x;
  2394. Browser.mouseY = y;
  2395. }
  2396. },asyncLoad:function (url, onload, onerror, noRunDep) {
  2397. var dep = !noRunDep ? getUniqueRunDependency('al ' + url) : '';
  2398. Module['readAsync'](url, function(arrayBuffer) {
  2399. assert(arrayBuffer, 'Loading data file "' + url + '" failed (no arrayBuffer).');
  2400. onload(new Uint8Array(arrayBuffer));
  2401. if (dep) removeRunDependency(dep);
  2402. }, function(event) {
  2403. if (onerror) {
  2404. onerror();
  2405. } else {
  2406. throw 'Loading data file "' + url + '" failed.';
  2407. }
  2408. });
  2409. if (dep) addRunDependency(dep);
  2410. },resizeListeners:[],updateResizeListeners:function () {
  2411. var canvas = Module['canvas'];
  2412. Browser.resizeListeners.forEach(function(listener) {
  2413. listener(canvas.width, canvas.height);
  2414. });
  2415. },setCanvasSize:function (width, height, noUpdates) {
  2416. var canvas = Module['canvas'];
  2417. Browser.updateCanvasDimensions(canvas, width, height);
  2418. if (!noUpdates) Browser.updateResizeListeners();
  2419. },windowedWidth:0,windowedHeight:0,setFullscreenCanvasSize:function () {
  2420. // check if SDL is available
  2421. if (typeof SDL != "undefined") {
  2422. var flags = HEAPU32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)];
  2423. flags = flags | 0x00800000; // set SDL_FULLSCREEN flag
  2424. HEAP32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)]=flags
  2425. }
  2426. Browser.updateResizeListeners();
  2427. },setWindowedCanvasSize:function () {
  2428. // check if SDL is available
  2429. if (typeof SDL != "undefined") {
  2430. var flags = HEAPU32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)];
  2431. flags = flags & ~0x00800000; // clear SDL_FULLSCREEN flag
  2432. HEAP32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)]=flags
  2433. }
  2434. Browser.updateResizeListeners();
  2435. },updateCanvasDimensions:function (canvas, wNative, hNative) {
  2436. if (wNative && hNative) {
  2437. canvas.widthNative = wNative;
  2438. canvas.heightNative = hNative;
  2439. } else {
  2440. wNative = canvas.widthNative;
  2441. hNative = canvas.heightNative;
  2442. }
  2443. var w = wNative;
  2444. var h = hNative;
  2445. if (Module['forcedAspectRatio'] && Module['forcedAspectRatio'] > 0) {
  2446. if (w/h < Module['forcedAspectRatio']) {
  2447. w = Math.round(h * Module['forcedAspectRatio']);
  2448. } else {
  2449. h = Math.round(w / Module['forcedAspectRatio']);
  2450. }
  2451. }
  2452. if (((document['fullscreenElement'] || document['mozFullScreenElement'] ||
  2453. document['msFullscreenElement'] || document['webkitFullscreenElement'] ||
  2454. document['webkitCurrentFullScreenElement']) === canvas.parentNode) && (typeof screen != 'undefined')) {
  2455. var factor = Math.min(screen.width / w, screen.height / h);
  2456. w = Math.round(w * factor);
  2457. h = Math.round(h * factor);
  2458. }
  2459. if (Browser.resizeCanvas) {
  2460. if (canvas.width != w) canvas.width = w;
  2461. if (canvas.height != h) canvas.height = h;
  2462. if (typeof canvas.style != 'undefined') {
  2463. canvas.style.removeProperty( "width");
  2464. canvas.style.removeProperty("height");
  2465. }
  2466. } else {
  2467. if (canvas.width != wNative) canvas.width = wNative;
  2468. if (canvas.height != hNative) canvas.height = hNative;
  2469. if (typeof canvas.style != 'undefined') {
  2470. if (w != wNative || h != hNative) {
  2471. canvas.style.setProperty( "width", w + "px", "important");
  2472. canvas.style.setProperty("height", h + "px", "important");
  2473. } else {
  2474. canvas.style.removeProperty( "width");
  2475. canvas.style.removeProperty("height");
  2476. }
  2477. }
  2478. }
  2479. },wgetRequests:{},nextWgetRequestHandle:0,getNextWgetRequestHandle:function () {
  2480. var handle = Browser.nextWgetRequestHandle;
  2481. Browser.nextWgetRequestHandle++;
  2482. return handle;
  2483. }};var GLFW={Window:function (id, width, height, title, monitor, share) {
  2484. this.id = id;
  2485. this.x = 0;
  2486. this.y = 0;
  2487. this.fullscreen = false; // Used to determine if app in fullscreen mode
  2488. this.storedX = 0; // Used to store X before fullscreen
  2489. this.storedY = 0; // Used to store Y before fullscreen
  2490. this.width = width;
  2491. this.height = height;
  2492. this.storedWidth = width; // Used to store width before fullscreen
  2493. this.storedHeight = height; // Used to store height before fullscreen
  2494. this.title = title;
  2495. this.monitor = monitor;
  2496. this.share = share;
  2497. this.attributes = GLFW.hints;
  2498. this.inputModes = {
  2499. 0x00033001:0x00034001, // GLFW_CURSOR (GLFW_CURSOR_NORMAL)
  2500. 0x00033002:0, // GLFW_STICKY_KEYS
  2501. 0x00033003:0, // GLFW_STICKY_MOUSE_BUTTONS
  2502. };
  2503. this.buttons = 0;
  2504. this.keys = new Array();
  2505. this.shouldClose = 0;
  2506. this.title = null;
  2507. this.windowPosFunc = null; // GLFWwindowposfun
  2508. this.windowSizeFunc = null; // GLFWwindowsizefun
  2509. this.windowCloseFunc = null; // GLFWwindowclosefun
  2510. this.windowRefreshFunc = null; // GLFWwindowrefreshfun
  2511. this.windowFocusFunc = null; // GLFWwindowfocusfun
  2512. this.windowIconifyFunc = null; // GLFWwindowiconifyfun
  2513. this.framebufferSizeFunc = null; // GLFWframebuffersizefun
  2514. this.mouseButtonFunc = null; // GLFWmousebuttonfun
  2515. this.cursorPosFunc = null; // GLFWcursorposfun
  2516. this.cursorEnterFunc = null; // GLFWcursorenterfun
  2517. this.scrollFunc = null; // GLFWscrollfun
  2518. this.keyFunc = null; // GLFWkeyfun
  2519. this.charFunc = null; // GLFWcharfun
  2520. this.userptr = null;
  2521. },WindowFromId:function (id) {
  2522. if (id <= 0 || !GLFW.windows) return null;
  2523. return GLFW.windows[id - 1];
  2524. },errorFunc:null,monitorFunc:null,active:null,windows:null,monitors:null,monitorString:null,versionString:null,initialTime:null,extensions:null,hints:null,defaultHints:{131073:0,131074:0,131075:1,131076:1,131077:1,135169:8,135170:8,135171:8,135172:8,135173:24,135174:8,135175:0,135176:0,135177:0,135178:0,135179:0,135180:0,135181:0,135182:0,135183:0,139265:196609,139266:1,139267:0,139268:0,139269:0,139270:0,139271:0,139272:0},DOMToGLFWKeyCode:function (keycode) {
  2525. switch (keycode) {
  2526. // these keycodes are only defined for GLFW3, assume they are the same for GLFW2
  2527. case 0x20:return 32; // DOM_VK_SPACE -> GLFW_KEY_SPACE
  2528. case 0xDE:return 39; // DOM_VK_QUOTE -> GLFW_KEY_APOSTROPHE
  2529. case 0xBC:return 44; // DOM_VK_COMMA -> GLFW_KEY_COMMA
  2530. case 0xAD:return 45; // DOM_VK_HYPHEN_MINUS -> GLFW_KEY_MINUS
  2531. case 0xBD:return 45; // DOM_VK_MINUS -> GLFW_KEY_MINUS
  2532. case 0xBE:return 46; // DOM_VK_PERIOD -> GLFW_KEY_PERIOD
  2533. case 0xBF:return 47; // DOM_VK_SLASH -> GLFW_KEY_SLASH
  2534. case 0x30:return 48; // DOM_VK_0 -> GLFW_KEY_0
  2535. case 0x31:return 49; // DOM_VK_1 -> GLFW_KEY_1
  2536. case 0x32:return 50; // DOM_VK_2 -> GLFW_KEY_2
  2537. case 0x33:return 51; // DOM_VK_3 -> GLFW_KEY_3
  2538. case 0x34:return 52; // DOM_VK_4 -> GLFW_KEY_4
  2539. case 0x35:return 53; // DOM_VK_5 -> GLFW_KEY_5
  2540. case 0x36:return 54; // DOM_VK_6 -> GLFW_KEY_6
  2541. case 0x37:return 55; // DOM_VK_7 -> GLFW_KEY_7
  2542. case 0x38:return 56; // DOM_VK_8 -> GLFW_KEY_8
  2543. case 0x39:return 57; // DOM_VK_9 -> GLFW_KEY_9
  2544. case 0x3B:return 59; // DOM_VK_SEMICOLON -> GLFW_KEY_SEMICOLON
  2545. case 0x3D:return 61; // DOM_VK_EQUALS -> GLFW_KEY_EQUAL
  2546. case 0xBB:return 61; // DOM_VK_EQUALS -> GLFW_KEY_EQUAL
  2547. case 0x41:return 65; // DOM_VK_A -> GLFW_KEY_A
  2548. case 0x42:return 66; // DOM_VK_B -> GLFW_KEY_B
  2549. case 0x43:return 67; // DOM_VK_C -> GLFW_KEY_C
  2550. case 0x44:return 68; // DOM_VK_D -> GLFW_KEY_D
  2551. case 0x45:return 69; // DOM_VK_E -> GLFW_KEY_E
  2552. case 0x46:return 70; // DOM_VK_F -> GLFW_KEY_F
  2553. case 0x47:return 71; // DOM_VK_G -> GLFW_KEY_G
  2554. case 0x48:return 72; // DOM_VK_H -> GLFW_KEY_H
  2555. case 0x49:return 73; // DOM_VK_I -> GLFW_KEY_I
  2556. case 0x4A:return 74; // DOM_VK_J -> GLFW_KEY_J
  2557. case 0x4B:return 75; // DOM_VK_K -> GLFW_KEY_K
  2558. case 0x4C:return 76; // DOM_VK_L -> GLFW_KEY_L
  2559. case 0x4D:return 77; // DOM_VK_M -> GLFW_KEY_M
  2560. case 0x4E:return 78; // DOM_VK_N -> GLFW_KEY_N
  2561. case 0x4F:return 79; // DOM_VK_O -> GLFW_KEY_O
  2562. case 0x50:return 80; // DOM_VK_P -> GLFW_KEY_P
  2563. case 0x51:return 81; // DOM_VK_Q -> GLFW_KEY_Q
  2564. case 0x52:return 82; // DOM_VK_R -> GLFW_KEY_R
  2565. case 0x53:return 83; // DOM_VK_S -> GLFW_KEY_S
  2566. case 0x54:return 84; // DOM_VK_T -> GLFW_KEY_T
  2567. case 0x55:return 85; // DOM_VK_U -> GLFW_KEY_U
  2568. case 0x56:return 86; // DOM_VK_V -> GLFW_KEY_V
  2569. case 0x57:return 87; // DOM_VK_W -> GLFW_KEY_W
  2570. case 0x58:return 88; // DOM_VK_X -> GLFW_KEY_X
  2571. case 0x59:return 89; // DOM_VK_Y -> GLFW_KEY_Y
  2572. case 0x5a:return 90; // DOM_VK_Z -> GLFW_KEY_Z
  2573. case 0xDB:return 91; // DOM_VK_OPEN_BRACKET -> GLFW_KEY_LEFT_BRACKET
  2574. case 0xDC:return 92; // DOM_VK_BACKSLASH -> GLFW_KEY_BACKSLASH
  2575. case 0xDD:return 93; // DOM_VK_CLOSE_BRACKET -> GLFW_KEY_RIGHT_BRACKET
  2576. case 0xC0:return 94; // DOM_VK_BACK_QUOTE -> GLFW_KEY_GRAVE_ACCENT
  2577. case 0x1B:return 256; // DOM_VK_ESCAPE -> GLFW_KEY_ESCAPE
  2578. case 0x0D:return 257; // DOM_VK_RETURN -> GLFW_KEY_ENTER
  2579. case 0x09:return 258; // DOM_VK_TAB -> GLFW_KEY_TAB
  2580. case 0x08:return 259; // DOM_VK_BACK -> GLFW_KEY_BACKSPACE
  2581. case 0x2D:return 260; // DOM_VK_INSERT -> GLFW_KEY_INSERT
  2582. case 0x2E:return 261; // DOM_VK_DELETE -> GLFW_KEY_DELETE
  2583. case 0x27:return 262; // DOM_VK_RIGHT -> GLFW_KEY_RIGHT
  2584. case 0x25:return 263; // DOM_VK_LEFT -> GLFW_KEY_LEFT
  2585. case 0x28:return 264; // DOM_VK_DOWN -> GLFW_KEY_DOWN
  2586. case 0x26:return 265; // DOM_VK_UP -> GLFW_KEY_UP
  2587. case 0x21:return 266; // DOM_VK_PAGE_UP -> GLFW_KEY_PAGE_UP
  2588. case 0x22:return 267; // DOM_VK_PAGE_DOWN -> GLFW_KEY_PAGE_DOWN
  2589. case 0x24:return 268; // DOM_VK_HOME -> GLFW_KEY_HOME
  2590. case 0x23:return 269; // DOM_VK_END -> GLFW_KEY_END
  2591. case 0x14:return 280; // DOM_VK_CAPS_LOCK -> GLFW_KEY_CAPS_LOCK
  2592. case 0x91:return 281; // DOM_VK_SCROLL_LOCK -> GLFW_KEY_SCROLL_LOCK
  2593. case 0x90:return 282; // DOM_VK_NUM_LOCK -> GLFW_KEY_NUM_LOCK
  2594. case 0x2C:return 283; // DOM_VK_SNAPSHOT -> GLFW_KEY_PRINT_SCREEN
  2595. case 0x13:return 284; // DOM_VK_PAUSE -> GLFW_KEY_PAUSE
  2596. case 0x70:return 290; // DOM_VK_F1 -> GLFW_KEY_F1
  2597. case 0x71:return 291; // DOM_VK_F2 -> GLFW_KEY_F2
  2598. case 0x72:return 292; // DOM_VK_F3 -> GLFW_KEY_F3
  2599. case 0x73:return 293; // DOM_VK_F4 -> GLFW_KEY_F4
  2600. case 0x74:return 294; // DOM_VK_F5 -> GLFW_KEY_F5
  2601. case 0x75:return 295; // DOM_VK_F6 -> GLFW_KEY_F6
  2602. case 0x76:return 296; // DOM_VK_F7 -> GLFW_KEY_F7
  2603. case 0x77:return 297; // DOM_VK_F8 -> GLFW_KEY_F8
  2604. case 0x78:return 298; // DOM_VK_F9 -> GLFW_KEY_F9
  2605. case 0x79:return 299; // DOM_VK_F10 -> GLFW_KEY_F10
  2606. case 0x7A:return 300; // DOM_VK_F11 -> GLFW_KEY_F11
  2607. case 0x7B:return 301; // DOM_VK_F12 -> GLFW_KEY_F12
  2608. case 0x7C:return 302; // DOM_VK_F13 -> GLFW_KEY_F13
  2609. case 0x7D:return 303; // DOM_VK_F14 -> GLFW_KEY_F14
  2610. case 0x7E:return 304; // DOM_VK_F15 -> GLFW_KEY_F15
  2611. case 0x7F:return 305; // DOM_VK_F16 -> GLFW_KEY_F16
  2612. case 0x80:return 306; // DOM_VK_F17 -> GLFW_KEY_F17
  2613. case 0x81:return 307; // DOM_VK_F18 -> GLFW_KEY_F18
  2614. case 0x82:return 308; // DOM_VK_F19 -> GLFW_KEY_F19
  2615. case 0x83:return 309; // DOM_VK_F20 -> GLFW_KEY_F20
  2616. case 0x84:return 310; // DOM_VK_F21 -> GLFW_KEY_F21
  2617. case 0x85:return 311; // DOM_VK_F22 -> GLFW_KEY_F22
  2618. case 0x86:return 312; // DOM_VK_F23 -> GLFW_KEY_F23
  2619. case 0x87:return 313; // DOM_VK_F24 -> GLFW_KEY_F24
  2620. case 0x88:return 314; // 0x88 (not used?) -> GLFW_KEY_F25
  2621. case 0x60:return 320; // DOM_VK_NUMPAD0 -> GLFW_KEY_KP_0
  2622. case 0x61:return 321; // DOM_VK_NUMPAD1 -> GLFW_KEY_KP_1
  2623. case 0x62:return 322; // DOM_VK_NUMPAD2 -> GLFW_KEY_KP_2
  2624. case 0x63:return 323; // DOM_VK_NUMPAD3 -> GLFW_KEY_KP_3
  2625. case 0x64:return 324; // DOM_VK_NUMPAD4 -> GLFW_KEY_KP_4
  2626. case 0x65:return 325; // DOM_VK_NUMPAD5 -> GLFW_KEY_KP_5
  2627. case 0x66:return 326; // DOM_VK_NUMPAD6 -> GLFW_KEY_KP_6
  2628. case 0x67:return 327; // DOM_VK_NUMPAD7 -> GLFW_KEY_KP_7
  2629. case 0x68:return 328; // DOM_VK_NUMPAD8 -> GLFW_KEY_KP_8
  2630. case 0x69:return 329; // DOM_VK_NUMPAD9 -> GLFW_KEY_KP_9
  2631. case 0x6E:return 330; // DOM_VK_DECIMAL -> GLFW_KEY_KP_DECIMAL
  2632. case 0x6F:return 331; // DOM_VK_DIVIDE -> GLFW_KEY_KP_DIVIDE
  2633. case 0x6A:return 332; // DOM_VK_MULTIPLY -> GLFW_KEY_KP_MULTIPLY
  2634. case 0x6D:return 333; // DOM_VK_SUBTRACT -> GLFW_KEY_KP_SUBTRACT
  2635. case 0x6B:return 334; // DOM_VK_ADD -> GLFW_KEY_KP_ADD
  2636. // case 0x0D:return 335; // DOM_VK_RETURN -> GLFW_KEY_KP_ENTER (DOM_KEY_LOCATION_RIGHT)
  2637. // case 0x61:return 336; // DOM_VK_EQUALS -> GLFW_KEY_KP_EQUAL (DOM_KEY_LOCATION_RIGHT)
  2638. case 0x10:return 340; // DOM_VK_SHIFT -> GLFW_KEY_LEFT_SHIFT
  2639. case 0x11:return 341; // DOM_VK_CONTROL -> GLFW_KEY_LEFT_CONTROL
  2640. case 0x12:return 342; // DOM_VK_ALT -> GLFW_KEY_LEFT_ALT
  2641. case 0x5B:return 343; // DOM_VK_WIN -> GLFW_KEY_LEFT_SUPER
  2642. // case 0x10:return 344; // DOM_VK_SHIFT -> GLFW_KEY_RIGHT_SHIFT (DOM_KEY_LOCATION_RIGHT)
  2643. // case 0x11:return 345; // DOM_VK_CONTROL -> GLFW_KEY_RIGHT_CONTROL (DOM_KEY_LOCATION_RIGHT)
  2644. // case 0x12:return 346; // DOM_VK_ALT -> GLFW_KEY_RIGHT_ALT (DOM_KEY_LOCATION_RIGHT)
  2645. // case 0x5B:return 347; // DOM_VK_WIN -> GLFW_KEY_RIGHT_SUPER (DOM_KEY_LOCATION_RIGHT)
  2646. case 0x5D:return 348; // DOM_VK_CONTEXT_MENU -> GLFW_KEY_MENU
  2647. // XXX: GLFW_KEY_WORLD_1, GLFW_KEY_WORLD_2 what are these?
  2648. default:return -1; // GLFW_KEY_UNKNOWN
  2649. };
  2650. },getModBits:function (win) {
  2651. var mod = 0;
  2652. if (win.keys[340]) mod |= 0x0001; // GLFW_MOD_SHIFT
  2653. if (win.keys[341]) mod |= 0x0002; // GLFW_MOD_CONTROL
  2654. if (win.keys[342]) mod |= 0x0004; // GLFW_MOD_ALT
  2655. if (win.keys[343]) mod |= 0x0008; // GLFW_MOD_SUPER
  2656. return mod;
  2657. },onKeyPress:function (event) {
  2658. if (!GLFW.active || !GLFW.active.charFunc) return;
  2659. // correct unicode charCode is only available with onKeyPress event
  2660. var charCode = event.charCode;
  2661. if (charCode == 0 || (charCode >= 0x00 && charCode <= 0x1F)) return;
  2662. Module['dynCall_vii'](GLFW.active.charFunc, GLFW.active.id, charCode);
  2663. },onKeyChanged:function (event, status) {
  2664. if (!GLFW.active) return;
  2665. var key = GLFW.DOMToGLFWKeyCode(event.keyCode);
  2666. if (key == -1) return;
  2667. var repeat = status && GLFW.active.keys[key];
  2668. GLFW.active.keys[key] = status;
  2669. if (!GLFW.active.keyFunc) return;
  2670. if (repeat) status = 2; // GLFW_REPEAT
  2671. Module['dynCall_viiiii'](GLFW.active.keyFunc, GLFW.active.id, key, event.keyCode, status, GLFW.getModBits(GLFW.active));
  2672. },onKeydown:function (event) {
  2673. GLFW.onKeyChanged(event, 1); // GLFW_PRESS or GLFW_REPEAT
  2674. // This logic comes directly from the sdl implementation. We cannot
  2675. // call preventDefault on all keydown events otherwise onKeyPress will
  2676. // not get called
  2677. if (event.keyCode === 8 /* backspace */ || event.keyCode === 9 /* tab */) {
  2678. event.preventDefault();
  2679. }
  2680. },onKeyup:function (event) {
  2681. GLFW.onKeyChanged(event, 0); // GLFW_RELEASE
  2682. },onMousemove:function (event) {
  2683. if (!GLFW.active) return;
  2684. Browser.calculateMouseEvent(event);
  2685. if (event.target != Module["canvas"] || !GLFW.active.cursorPosFunc) return;
  2686. Module['dynCall_vidd'](GLFW.active.cursorPosFunc, GLFW.active.id, Browser.mouseX, Browser.mouseY);
  2687. },DOMToGLFWMouseButton:function (event) {
  2688. // DOM and glfw have different button codes.
  2689. // See http://www.w3schools.com/jsref/event_button.asp.
  2690. var eventButton = event['button'];
  2691. if (eventButton > 0) {
  2692. if (eventButton == 1) {
  2693. eventButton = 2;
  2694. } else {
  2695. eventButton = 1;
  2696. }
  2697. }
  2698. return eventButton;
  2699. },onMouseenter:function (event) {
  2700. if (!GLFW.active) return;
  2701. if (event.target != Module["canvas"] || !GLFW.active.cursorEnterFunc) return;
  2702. Module['dynCall_vii'](GLFW.active.cursorEnterFunc, GLFW.active.id, 1);
  2703. },onMouseleave:function (event) {
  2704. if (!GLFW.active) return;
  2705. if (event.target != Module["canvas"] || !GLFW.active.cursorEnterFunc) return;
  2706. Module['dynCall_vii'](GLFW.active.cursorEnterFunc, GLFW.active.id, 0);
  2707. },onMouseButtonChanged:function (event, status) {
  2708. if (!GLFW.active) return;
  2709. Browser.calculateMouseEvent(event);
  2710. if (event.target != Module["canvas"]) return;
  2711. eventButton = GLFW.DOMToGLFWMouseButton(event);
  2712. if (status == 1) { // GLFW_PRESS
  2713. GLFW.active.buttons |= (1 << eventButton);
  2714. try {
  2715. event.target.setCapture();
  2716. } catch (e) {}
  2717. } else { // GLFW_RELEASE
  2718. GLFW.active.buttons &= ~(1 << eventButton);
  2719. }
  2720. if (!GLFW.active.mouseButtonFunc) return;
  2721. Module['dynCall_viiii'](GLFW.active.mouseButtonFunc, GLFW.active.id, eventButton, status, GLFW.getModBits(GLFW.active));
  2722. },onMouseButtonDown:function (event) {
  2723. if (!GLFW.active) return;
  2724. GLFW.onMouseButtonChanged(event, 1); // GLFW_PRESS
  2725. },onMouseButtonUp:function (event) {
  2726. if (!GLFW.active) return;
  2727. GLFW.onMouseButtonChanged(event, 0); // GLFW_RELEASE
  2728. },onMouseWheel:function (event) {
  2729. // Note the minus sign that flips browser wheel direction (positive direction scrolls page down) to native wheel direction (positive direction is mouse wheel up)
  2730. var delta = -Browser.getMouseWheelDelta(event);
  2731. delta = (delta == 0) ? 0 : (delta > 0 ? Math.max(delta, 1) : Math.min(delta, -1)); // Quantize to integer so that minimum scroll is at least +/- 1.
  2732. GLFW.wheelPos += delta;
  2733. if (!GLFW.active || !GLFW.active.scrollFunc || event.target != Module['canvas']) return;
  2734. var sx = 0;
  2735. var sy = 0;
  2736. if (event.type == 'mousewheel') {
  2737. sx = event.wheelDeltaX;
  2738. sy = event.wheelDeltaY;
  2739. } else {
  2740. sx = event.deltaX;
  2741. sy = event.deltaY;
  2742. }
  2743. Module['dynCall_vidd'](GLFW.active.scrollFunc, GLFW.active.id, sx, sy);
  2744. event.preventDefault();
  2745. },onCanvasResize:function (width, height) {
  2746. if (!GLFW.active) return;
  2747. var resizeNeeded = true;
  2748. // If the client is requestiong fullscreen mode
  2749. if (document["fullscreen"] || document["fullScreen"] || document["mozFullScreen"] || document["webkitIsFullScreen"]) {
  2750. GLFW.active.storedX = GLFW.active.x;
  2751. GLFW.active.storedY = GLFW.active.y;
  2752. GLFW.active.storedWidth = GLFW.active.width;
  2753. GLFW.active.storedHeight = GLFW.active.height;
  2754. GLFW.active.x = GLFW.active.y = 0;
  2755. GLFW.active.width = screen.width;
  2756. GLFW.active.height = screen.height;
  2757. GLFW.active.fullscreen = true;
  2758. // If the client is reverting from fullscreen mode
  2759. } else if (GLFW.active.fullscreen == true) {
  2760. GLFW.active.x = GLFW.active.storedX;
  2761. GLFW.active.y = GLFW.active.storedY;
  2762. GLFW.active.width = GLFW.active.storedWidth;
  2763. GLFW.active.height = GLFW.active.storedHeight;
  2764. GLFW.active.fullscreen = false;
  2765. // If the width/height values do not match current active window sizes
  2766. } else if (GLFW.active.width != width || GLFW.active.height != height) {
  2767. GLFW.active.width = width;
  2768. GLFW.active.height = height;
  2769. } else {
  2770. resizeNeeded = false;
  2771. }
  2772. // If any of the above conditions were true, we need to resize the canvas
  2773. if (resizeNeeded) {
  2774. // resets the canvas size to counter the aspect preservation of Browser.updateCanvasDimensions
  2775. Browser.setCanvasSize(GLFW.active.width, GLFW.active.height, true);
  2776. // TODO: Client dimensions (clientWidth/clientHeight) vs pixel dimensions (width/height) of
  2777. // the canvas should drive window and framebuffer size respectfully.
  2778. GLFW.onWindowSizeChanged();
  2779. GLFW.onFramebufferSizeChanged();
  2780. }
  2781. },onWindowSizeChanged:function () {
  2782. if (!GLFW.active) return;
  2783. if (!GLFW.active.windowSizeFunc) return;
  2784. Module['dynCall_viii'](GLFW.active.windowSizeFunc, GLFW.active.id, GLFW.active.width, GLFW.active.height);
  2785. },onFramebufferSizeChanged:function () {
  2786. if (!GLFW.active) return;
  2787. if (!GLFW.active.framebufferSizeFunc) return;
  2788. Module['dynCall_viii'](GLFW.active.framebufferSizeFunc, GLFW.active.id, GLFW.active.width, GLFW.active.height);
  2789. },requestFullscreen:function () {
  2790. var RFS = Module["canvas"]['requestFullscreen'] ||
  2791. Module["canvas"]['mozRequestFullScreen'] ||
  2792. Module["canvas"]['webkitRequestFullScreen'] ||
  2793. (function() {});
  2794. RFS.apply(Module["canvas"], []);
  2795. },requestFullScreen:function () {
  2796. Module.printErr('GLFW.requestFullScreen() is deprecated. Please call GLFW.requestFullscreen instead.');
  2797. GLFW.requestFullScreen = function() {
  2798. return GLFW.requestFullscreen();
  2799. }
  2800. return GLFW.requestFullscreen();
  2801. },exitFullscreen:function () {
  2802. var CFS = document['exitFullscreen'] ||
  2803. document['cancelFullScreen'] ||
  2804. document['mozCancelFullScreen'] ||
  2805. document['webkitCancelFullScreen'] ||
  2806. (function() {});
  2807. CFS.apply(document, []);
  2808. },cancelFullScreen:function () {
  2809. Module.printErr('GLFW.cancelFullScreen() is deprecated. Please call GLFW.exitFullscreen instead.');
  2810. GLFW.cancelFullScreen = function() {
  2811. return GLFW.exitFullscreen();
  2812. }
  2813. return GLFW.exitFullscreen();
  2814. },getTime:function () {
  2815. return _emscripten_get_now() / 1000;
  2816. },setWindowTitle:function (winid, title) {
  2817. var win = GLFW.WindowFromId(winid);
  2818. if (!win) return;
  2819. win.title = Pointer_stringify(title);
  2820. if (GLFW.active.id == win.id) {
  2821. document.title = win.title;
  2822. }
  2823. },setKeyCallback:function (winid, cbfun) {
  2824. var win = GLFW.WindowFromId(winid);
  2825. if (!win) return;
  2826. win.keyFunc = cbfun;
  2827. },setCharCallback:function (winid, cbfun) {
  2828. var win = GLFW.WindowFromId(winid);
  2829. if (!win) return;
  2830. win.charFunc = cbfun;
  2831. },setMouseButtonCallback:function (winid, cbfun) {
  2832. var win = GLFW.WindowFromId(winid);
  2833. if (!win) return;
  2834. win.mouseButtonFunc = cbfun;
  2835. },setCursorPosCallback:function (winid, cbfun) {
  2836. var win = GLFW.WindowFromId(winid);
  2837. if (!win) return;
  2838. win.cursorPosFunc = cbfun;
  2839. },setScrollCallback:function (winid, cbfun) {
  2840. var win = GLFW.WindowFromId(winid);
  2841. if (!win) return;
  2842. win.scrollFunc = cbfun;
  2843. },setWindowSizeCallback:function (winid, cbfun) {
  2844. var win = GLFW.WindowFromId(winid);
  2845. if (!win) return;
  2846. win.windowSizeFunc = cbfun;
  2847. },setWindowCloseCallback:function (winid, cbfun) {
  2848. var win = GLFW.WindowFromId(winid);
  2849. if (!win) return;
  2850. win.windowCloseFunc = cbfun;
  2851. },setWindowRefreshCallback:function (winid, cbfun) {
  2852. var win = GLFW.WindowFromId(winid);
  2853. if (!win) return;
  2854. win.windowRefreshFunc = cbfun;
  2855. },onClickRequestPointerLock:function (e) {
  2856. if (!Browser.pointerLock && Module['canvas'].requestPointerLock) {
  2857. Module['canvas'].requestPointerLock();
  2858. e.preventDefault();
  2859. }
  2860. },setInputMode:function (winid, mode, value) {
  2861. var win = GLFW.WindowFromId(winid);
  2862. if (!win) return;
  2863. switch(mode) {
  2864. case 0x00033001: { // GLFW_CURSOR
  2865. switch(value) {
  2866. case 0x00034001: { // GLFW_CURSOR_NORMAL
  2867. win.inputModes[mode] = value;
  2868. Module['canvas'].removeEventListener('click', GLFW.onClickRequestPointerLock, true);
  2869. Module['canvas'].exitPointerLock();
  2870. break;
  2871. }
  2872. case 0x00034002: { // GLFW_CURSOR_HIDDEN
  2873. console.log("glfwSetInputMode called with GLFW_CURSOR_HIDDEN value not implemented.");
  2874. break;
  2875. }
  2876. case 0x00034003: { // GLFW_CURSOR_DISABLED
  2877. win.inputModes[mode] = value;
  2878. Module['canvas'].addEventListener('click', GLFW.onClickRequestPointerLock, true);
  2879. Module['canvas'].requestPointerLock();
  2880. break;
  2881. }
  2882. default: {
  2883. console.log("glfwSetInputMode called with unknown value parameter value: " + value + ".");
  2884. break;
  2885. }
  2886. }
  2887. break;
  2888. }
  2889. case 0x00033002: { // GLFW_STICKY_KEYS
  2890. console.log("glfwSetInputMode called with GLFW_STICKY_KEYS mode not implemented.");
  2891. break;
  2892. }
  2893. case 0x00033003: { // GLFW_STICKY_MOUSE_BUTTONS
  2894. console.log("glfwSetInputMode called with GLFW_STICKY_MOUSE_BUTTONS mode not implemented.");
  2895. break;
  2896. }
  2897. default: {
  2898. console.log("glfwSetInputMode called with unknown mode parameter value: " + mode + ".");
  2899. break;
  2900. }
  2901. }
  2902. },getKey:function (winid, key) {
  2903. var win = GLFW.WindowFromId(winid);
  2904. if (!win) return 0;
  2905. return win.keys[key];
  2906. },getMouseButton:function (winid, button) {
  2907. var win = GLFW.WindowFromId(winid);
  2908. if (!win) return 0;
  2909. return (win.buttons & (1 << button)) > 0;
  2910. },getCursorPos:function (winid, x, y) {
  2911. setValue(x, Browser.mouseX, 'double');
  2912. setValue(y, Browser.mouseY, 'double');
  2913. },getMousePos:function (winid, x, y) {
  2914. setValue(x, Browser.mouseX, 'i32');
  2915. setValue(y, Browser.mouseY, 'i32');
  2916. },setCursorPos:function (winid, x, y) {
  2917. },getWindowPos:function (winid, x, y) {
  2918. var wx = 0;
  2919. var wy = 0;
  2920. var win = GLFW.WindowFromId(winid);
  2921. if (win) {
  2922. wx = win.x;
  2923. wy = win.y;
  2924. }
  2925. setValue(x, wx, 'i32');
  2926. setValue(y, wy, 'i32');
  2927. },setWindowPos:function (winid, x, y) {
  2928. var win = GLFW.WindowFromId(winid);
  2929. if (!win) return;
  2930. win.x = x;
  2931. win.y = y;
  2932. },getWindowSize:function (winid, width, height) {
  2933. var ww = 0;
  2934. var wh = 0;
  2935. var win = GLFW.WindowFromId(winid);
  2936. if (win) {
  2937. ww = win.width;
  2938. wh = win.height;
  2939. }
  2940. setValue(width, ww, 'i32');
  2941. setValue(height, wh, 'i32');
  2942. },setWindowSize:function (winid, width, height) {
  2943. var win = GLFW.WindowFromId(winid);
  2944. if (!win) return;
  2945. if (GLFW.active.id == win.id) {
  2946. if (width == screen.width && height == screen.height) {
  2947. GLFW.requestFullscreen();
  2948. } else {
  2949. GLFW.exitFullscreen();
  2950. Browser.setCanvasSize(width, height);
  2951. win.width = width;
  2952. win.height = height;
  2953. }
  2954. }
  2955. if (!win.windowSizeFunc) return;
  2956. Module['dynCall_viii'](win.windowSizeFunc, win.id, width, height);
  2957. },createWindow:function (width, height, title, monitor, share) {
  2958. var i, id;
  2959. for (i = 0; i < GLFW.windows.length && GLFW.windows[i] !== null; i++);
  2960. if (i > 0) throw "glfwCreateWindow only supports one window at time currently";
  2961. // id for window
  2962. id = i + 1;
  2963. // not valid
  2964. if (width <= 0 || height <= 0) return 0;
  2965. if (monitor) {
  2966. GLFW.requestFullscreen();
  2967. } else {
  2968. Browser.setCanvasSize(width, height);
  2969. }
  2970. // Create context when there are no existing alive windows
  2971. for (i = 0; i < GLFW.windows.length && GLFW.windows[i] == null; i++);
  2972. if (i == GLFW.windows.length) {
  2973. var contextAttributes = {
  2974. antialias: (GLFW.hints[0x0002100D] > 1), // GLFW_SAMPLES
  2975. depth: (GLFW.hints[0x00021005] > 0), // GLFW_DEPTH_BITS
  2976. stencil: (GLFW.hints[0x00021006] > 0), // GLFW_STENCIL_BITS
  2977. alpha: (GLFW.hints[0x00021004] > 0) // GLFW_ALPHA_BITS
  2978. }
  2979. Module.ctx = Browser.createContext(Module['canvas'], true, true, contextAttributes);
  2980. }
  2981. // If context creation failed, do not return a valid window
  2982. if (!Module.ctx) return 0;
  2983. // Get non alive id
  2984. var win = new GLFW.Window(id, width, height, title, monitor, share);
  2985. // Set window to array
  2986. if (id - 1 == GLFW.windows.length) {
  2987. GLFW.windows.push(win);
  2988. } else {
  2989. GLFW.windows[id - 1] = win;
  2990. }
  2991. GLFW.active = win;
  2992. return win.id;
  2993. },destroyWindow:function (winid) {
  2994. var win = GLFW.WindowFromId(winid);
  2995. if (!win) return;
  2996. if (win.windowCloseFunc)
  2997. Module['dynCall_vi'](win.windowCloseFunc, win.id);
  2998. GLFW.windows[win.id - 1] = null;
  2999. if (GLFW.active.id == win.id)
  3000. GLFW.active = null;
  3001. // Destroy context when no alive windows
  3002. for (var i = 0; i < GLFW.windows.length; i++)
  3003. if (GLFW.windows[i] !== null) return;
  3004. Module.ctx = Browser.destroyContext(Module['canvas'], true, true);
  3005. },swapBuffers:function (winid) {
  3006. },GLFW2ParamToGLFW3Param:function (param) {
  3007. table = {
  3008. 0x00030001:0, // GLFW_MOUSE_CURSOR
  3009. 0x00030002:0, // GLFW_STICKY_KEYS
  3010. 0x00030003:0, // GLFW_STICKY_MOUSE_BUTTONS
  3011. 0x00030004:0, // GLFW_SYSTEM_KEYS
  3012. 0x00030005:0, // GLFW_KEY_REPEAT
  3013. 0x00030006:0, // GLFW_AUTO_POLL_EVENTS
  3014. 0x00020001:0, // GLFW_OPENED
  3015. 0x00020002:0, // GLFW_ACTIVE
  3016. 0x00020003:0, // GLFW_ICONIFIED
  3017. 0x00020004:0, // GLFW_ACCELERATED
  3018. 0x00020005:0x00021001, // GLFW_RED_BITS
  3019. 0x00020006:0x00021002, // GLFW_GREEN_BITS
  3020. 0x00020007:0x00021003, // GLFW_BLUE_BITS
  3021. 0x00020008:0x00021004, // GLFW_ALPHA_BITS
  3022. 0x00020009:0x00021005, // GLFW_DEPTH_BITS
  3023. 0x0002000A:0x00021006, // GLFW_STENCIL_BITS
  3024. 0x0002000B:0x0002100F, // GLFW_REFRESH_RATE
  3025. 0x0002000C:0x00021007, // GLFW_ACCUM_RED_BITS
  3026. 0x0002000D:0x00021008, // GLFW_ACCUM_GREEN_BITS
  3027. 0x0002000E:0x00021009, // GLFW_ACCUM_BLUE_BITS
  3028. 0x0002000F:0x0002100A, // GLFW_ACCUM_ALPHA_BITS
  3029. 0x00020010:0x0002100B, // GLFW_AUX_BUFFERS
  3030. 0x00020011:0x0002100C, // GLFW_STEREO
  3031. 0x00020012:0, // GLFW_WINDOW_NO_RESIZE
  3032. 0x00020013:0x0002100D, // GLFW_FSAA_SAMPLES
  3033. 0x00020014:0x00022002, // GLFW_OPENGL_VERSION_MAJOR
  3034. 0x00020015:0x00022003, // GLFW_OPENGL_VERSION_MINOR
  3035. 0x00020016:0x00022006, // GLFW_OPENGL_FORWARD_COMPAT
  3036. 0x00020017:0x00022007, // GLFW_OPENGL_DEBUG_CONTEXT
  3037. 0x00020018:0x00022008, // GLFW_OPENGL_PROFILE
  3038. };
  3039. return table[param];
  3040. }};function _glfwGetVideoModes(monitor, count) {
  3041. setValue(count, 0, 'i32');
  3042. return 0;
  3043. }
  3044. function _glLinkProgram(program) {
  3045. GLctx.linkProgram(GL.programs[program]);
  3046. GL.programInfos[program] = null; // uniforms no longer keep the same names after linking
  3047. GL.populateUniformTable(program);
  3048. }
  3049. function _glBindTexture(target, texture) {
  3050. GLctx.bindTexture(target, texture ? GL.textures[texture] : null);
  3051. }
  3052. function _emscripten_glStencilFunc(x0, x1, x2) { GLctx['stencilFunc'](x0, x1, x2) }
  3053. function _glGetString(name_) {
  3054. if (GL.stringCache[name_]) return GL.stringCache[name_];
  3055. var ret;
  3056. switch(name_) {
  3057. case 0x1F00 /* GL_VENDOR */:
  3058. case 0x1F01 /* GL_RENDERER */:
  3059. case 0x9245 /* UNMASKED_VENDOR_WEBGL */:
  3060. case 0x9246 /* UNMASKED_RENDERER_WEBGL */:
  3061. ret = allocate(intArrayFromString(GLctx.getParameter(name_)), 'i8', ALLOC_NORMAL);
  3062. break;
  3063. case 0x1F02 /* GL_VERSION */:
  3064. var glVersion = GLctx.getParameter(GLctx.VERSION);
  3065. // return GLES version string corresponding to the version of the WebGL context
  3066. {
  3067. glVersion = 'OpenGL ES 2.0 (' + glVersion + ')';
  3068. }
  3069. ret = allocate(intArrayFromString(glVersion), 'i8', ALLOC_NORMAL);
  3070. break;
  3071. case 0x1F03 /* GL_EXTENSIONS */:
  3072. var exts = GLctx.getSupportedExtensions();
  3073. var gl_exts = [];
  3074. for (var i = 0; i < exts.length; ++i) {
  3075. gl_exts.push(exts[i]);
  3076. gl_exts.push("GL_" + exts[i]);
  3077. }
  3078. ret = allocate(intArrayFromString(gl_exts.join(' ')), 'i8', ALLOC_NORMAL);
  3079. break;
  3080. case 0x8B8C /* GL_SHADING_LANGUAGE_VERSION */:
  3081. var glslVersion = GLctx.getParameter(GLctx.SHADING_LANGUAGE_VERSION);
  3082. // extract the version number 'N.M' from the string 'WebGL GLSL ES N.M ...'
  3083. var ver_re = /^WebGL GLSL ES ([0-9]\.[0-9][0-9]?)(?:$| .*)/;
  3084. var ver_num = glslVersion.match(ver_re);
  3085. if (ver_num !== null) {
  3086. if (ver_num[1].length == 3) ver_num[1] = ver_num[1] + '0'; // ensure minor version has 2 digits
  3087. glslVersion = 'OpenGL ES GLSL ES ' + ver_num[1] + ' (' + glslVersion + ')';
  3088. }
  3089. ret = allocate(intArrayFromString(glslVersion), 'i8', ALLOC_NORMAL);
  3090. break;
  3091. default:
  3092. GL.recordError(0x0500/*GL_INVALID_ENUM*/);
  3093. return 0;
  3094. }
  3095. GL.stringCache[name_] = ret;
  3096. return ret;
  3097. }
  3098. function _emscripten_glUniform3iv(location, count, value) {
  3099. GLctx.uniform3iv(GL.uniforms[location], HEAP32.subarray((value)>>2,(value+count*12)>>2));
  3100. }
  3101. function _emscripten_glShaderSource(shader, count, string, length) {
  3102. var source = GL.getSource(shader, count, string, length);
  3103. GLctx.shaderSource(GL.shaders[shader], source);
  3104. }
  3105. function _emscripten_glReleaseShaderCompiler() {
  3106. // NOP (as allowed by GLES 2.0 spec)
  3107. }
  3108. function _glfwSetScrollCallback(winid, cbfun) {
  3109. GLFW.setScrollCallback(winid, cbfun);
  3110. }
  3111. function _emscripten_glTexParameterf(x0, x1, x2) { GLctx['texParameterf'](x0, x1, x2) }
  3112. function _emscripten_glTexParameteri(x0, x1, x2) { GLctx['texParameteri'](x0, x1, x2) }
  3113. function _glCompileShader(shader) {
  3114. GLctx.compileShader(GL.shaders[shader]);
  3115. }
  3116. var ERRNO_CODES={EPERM:1,ENOENT:2,ESRCH:3,EINTR:4,EIO:5,ENXIO:6,E2BIG:7,ENOEXEC:8,EBADF:9,ECHILD:10,EAGAIN:11,EWOULDBLOCK:11,ENOMEM:12,EACCES:13,EFAULT:14,ENOTBLK:15,EBUSY:16,EEXIST:17,EXDEV:18,ENODEV:19,ENOTDIR:20,EISDIR:21,EINVAL:22,ENFILE:23,EMFILE:24,ENOTTY:25,ETXTBSY:26,EFBIG:27,ENOSPC:28,ESPIPE:29,EROFS:30,EMLINK:31,EPIPE:32,EDOM:33,ERANGE:34,ENOMSG:42,EIDRM:43,ECHRNG:44,EL2NSYNC:45,EL3HLT:46,EL3RST:47,ELNRNG:48,EUNATCH:49,ENOCSI:50,EL2HLT:51,EDEADLK:35,ENOLCK:37,EBADE:52,EBADR:53,EXFULL:54,ENOANO:55,EBADRQC:56,EBADSLT:57,EDEADLOCK:35,EBFONT:59,ENOSTR:60,ENODATA:61,ETIME:62,ENOSR:63,ENONET:64,ENOPKG:65,EREMOTE:66,ENOLINK:67,EADV:68,ESRMNT:69,ECOMM:70,EPROTO:71,EMULTIHOP:72,EDOTDOT:73,EBADMSG:74,ENOTUNIQ:76,EBADFD:77,EREMCHG:78,ELIBACC:79,ELIBBAD:80,ELIBSCN:81,ELIBMAX:82,ELIBEXEC:83,ENOSYS:38,ENOTEMPTY:39,ENAMETOOLONG:36,ELOOP:40,EOPNOTSUPP:95,EPFNOSUPPORT:96,ECONNRESET:104,ENOBUFS:105,EAFNOSUPPORT:97,EPROTOTYPE:91,ENOTSOCK:88,ENOPROTOOPT:92,ESHUTDOWN:108,ECONNREFUSED:111,EADDRINUSE:98,ECONNABORTED:103,ENETUNREACH:101,ENETDOWN:100,ETIMEDOUT:110,EHOSTDOWN:112,EHOSTUNREACH:113,EINPROGRESS:115,EALREADY:114,EDESTADDRREQ:89,EMSGSIZE:90,EPROTONOSUPPORT:93,ESOCKTNOSUPPORT:94,EADDRNOTAVAIL:99,ENETRESET:102,EISCONN:106,ENOTCONN:107,ETOOMANYREFS:109,EUSERS:87,EDQUOT:122,ESTALE:116,ENOTSUP:95,ENOMEDIUM:123,EILSEQ:84,EOVERFLOW:75,ECANCELED:125,ENOTRECOVERABLE:131,EOWNERDEAD:130,ESTRPIPE:86};
  3117. var ERRNO_MESSAGES={0:"Success",1:"Not super-user",2:"No such file or directory",3:"No such process",4:"Interrupted system call",5:"I/O error",6:"No such device or address",7:"Arg list too long",8:"Exec format error",9:"Bad file number",10:"No children",11:"No more processes",12:"Not enough core",13:"Permission denied",14:"Bad address",15:"Block device required",16:"Mount device busy",17:"File exists",18:"Cross-device link",19:"No such device",20:"Not a directory",21:"Is a directory",22:"Invalid argument",23:"Too many open files in system",24:"Too many open files",25:"Not a typewriter",26:"Text file busy",27:"File too large",28:"No space left on device",29:"Illegal seek",30:"Read only file system",31:"Too many links",32:"Broken pipe",33:"Math arg out of domain of func",34:"Math result not representable",35:"File locking deadlock error",36:"File or path name too long",37:"No record locks available",38:"Function not implemented",39:"Directory not empty",40:"Too many symbolic links",42:"No message of desired type",43:"Identifier removed",44:"Channel number out of range",45:"Level 2 not synchronized",46:"Level 3 halted",47:"Level 3 reset",48:"Link number out of range",49:"Protocol driver not attached",50:"No CSI structure available",51:"Level 2 halted",52:"Invalid exchange",53:"Invalid request descriptor",54:"Exchange full",55:"No anode",56:"Invalid request code",57:"Invalid slot",59:"Bad font file fmt",60:"Device not a stream",61:"No data (for no delay io)",62:"Timer expired",63:"Out of streams resources",64:"Machine is not on the network",65:"Package not installed",66:"The object is remote",67:"The link has been severed",68:"Advertise error",69:"Srmount error",70:"Communication error on send",71:"Protocol error",72:"Multihop attempted",73:"Cross mount point (not really error)",74:"Trying to read unreadable message",75:"Value too large for defined data type",76:"Given log. name not unique",77:"f.d. invalid for this operation",78:"Remote address changed",79:"Can access a needed shared lib",80:"Accessing a corrupted shared lib",81:".lib section in a.out corrupted",82:"Attempting to link in too many libs",83:"Attempting to exec a shared library",84:"Illegal byte sequence",86:"Streams pipe error",87:"Too many users",88:"Socket operation on non-socket",89:"Destination address required",90:"Message too long",91:"Protocol wrong type for socket",92:"Protocol not available",93:"Unknown protocol",94:"Socket type not supported",95:"Not supported",96:"Protocol family not supported",97:"Address family not supported by protocol family",98:"Address already in use",99:"Address not available",100:"Network interface is not configured",101:"Network is unreachable",102:"Connection reset by network",103:"Connection aborted",104:"Connection reset by peer",105:"No buffer space available",106:"Socket is already connected",107:"Socket is not connected",108:"Can't send after socket shutdown",109:"Too many references",110:"Connection timed out",111:"Connection refused",112:"Host is down",113:"Host is unreachable",114:"Socket already connected",115:"Connection already in progress",116:"Stale file handle",122:"Quota exceeded",123:"No medium (in tape drive)",125:"Operation canceled",130:"Previous owner died",131:"State not recoverable"};
  3118. function ___setErrNo(value) {
  3119. if (Module['___errno_location']) HEAP32[((Module['___errno_location']())>>2)]=value;
  3120. else Module.printErr('failed to set errno from JS');
  3121. return value;
  3122. }
  3123. var PATH={splitPath:function (filename) {
  3124. var splitPathRe = /^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;
  3125. return splitPathRe.exec(filename).slice(1);
  3126. },normalizeArray:function (parts, allowAboveRoot) {
  3127. // if the path tries to go above the root, `up` ends up > 0
  3128. var up = 0;
  3129. for (var i = parts.length - 1; i >= 0; i--) {
  3130. var last = parts[i];
  3131. if (last === '.') {
  3132. parts.splice(i, 1);
  3133. } else if (last === '..') {
  3134. parts.splice(i, 1);
  3135. up++;
  3136. } else if (up) {
  3137. parts.splice(i, 1);
  3138. up--;
  3139. }
  3140. }
  3141. // if the path is allowed to go above the root, restore leading ..s
  3142. if (allowAboveRoot) {
  3143. for (; up--; up) {
  3144. parts.unshift('..');
  3145. }
  3146. }
  3147. return parts;
  3148. },normalize:function (path) {
  3149. var isAbsolute = path.charAt(0) === '/',
  3150. trailingSlash = path.substr(-1) === '/';
  3151. // Normalize the path
  3152. path = PATH.normalizeArray(path.split('/').filter(function(p) {
  3153. return !!p;
  3154. }), !isAbsolute).join('/');
  3155. if (!path && !isAbsolute) {
  3156. path = '.';
  3157. }
  3158. if (path && trailingSlash) {
  3159. path += '/';
  3160. }
  3161. return (isAbsolute ? '/' : '') + path;
  3162. },dirname:function (path) {
  3163. var result = PATH.splitPath(path),
  3164. root = result[0],
  3165. dir = result[1];
  3166. if (!root && !dir) {
  3167. // No dirname whatsoever
  3168. return '.';
  3169. }
  3170. if (dir) {
  3171. // It has a dirname, strip trailing slash
  3172. dir = dir.substr(0, dir.length - 1);
  3173. }
  3174. return root + dir;
  3175. },basename:function (path) {
  3176. // EMSCRIPTEN return '/'' for '/', not an empty string
  3177. if (path === '/') return '/';
  3178. var lastSlash = path.lastIndexOf('/');
  3179. if (lastSlash === -1) return path;
  3180. return path.substr(lastSlash+1);
  3181. },extname:function (path) {
  3182. return PATH.splitPath(path)[3];
  3183. },join:function () {
  3184. var paths = Array.prototype.slice.call(arguments, 0);
  3185. return PATH.normalize(paths.join('/'));
  3186. },join2:function (l, r) {
  3187. return PATH.normalize(l + '/' + r);
  3188. },resolve:function () {
  3189. var resolvedPath = '',
  3190. resolvedAbsolute = false;
  3191. for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
  3192. var path = (i >= 0) ? arguments[i] : FS.cwd();
  3193. // Skip empty and invalid entries
  3194. if (typeof path !== 'string') {
  3195. throw new TypeError('Arguments to path.resolve must be strings');
  3196. } else if (!path) {
  3197. return ''; // an invalid portion invalidates the whole thing
  3198. }
  3199. resolvedPath = path + '/' + resolvedPath;
  3200. resolvedAbsolute = path.charAt(0) === '/';
  3201. }
  3202. // At this point the path should be resolved to a full absolute path, but
  3203. // handle relative paths to be safe (might happen when process.cwd() fails)
  3204. resolvedPath = PATH.normalizeArray(resolvedPath.split('/').filter(function(p) {
  3205. return !!p;
  3206. }), !resolvedAbsolute).join('/');
  3207. return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.';
  3208. },relative:function (from, to) {
  3209. from = PATH.resolve(from).substr(1);
  3210. to = PATH.resolve(to).substr(1);
  3211. function trim(arr) {
  3212. var start = 0;
  3213. for (; start < arr.length; start++) {
  3214. if (arr[start] !== '') break;
  3215. }
  3216. var end = arr.length - 1;
  3217. for (; end >= 0; end--) {
  3218. if (arr[end] !== '') break;
  3219. }
  3220. if (start > end) return [];
  3221. return arr.slice(start, end - start + 1);
  3222. }
  3223. var fromParts = trim(from.split('/'));
  3224. var toParts = trim(to.split('/'));
  3225. var length = Math.min(fromParts.length, toParts.length);
  3226. var samePartsLength = length;
  3227. for (var i = 0; i < length; i++) {
  3228. if (fromParts[i] !== toParts[i]) {
  3229. samePartsLength = i;
  3230. break;
  3231. }
  3232. }
  3233. var outputParts = [];
  3234. for (var i = samePartsLength; i < fromParts.length; i++) {
  3235. outputParts.push('..');
  3236. }
  3237. outputParts = outputParts.concat(toParts.slice(samePartsLength));
  3238. return outputParts.join('/');
  3239. }};
  3240. var TTY={ttys:[],init:function () {
  3241. // https://github.com/kripken/emscripten/pull/1555
  3242. // if (ENVIRONMENT_IS_NODE) {
  3243. // // currently, FS.init does not distinguish if process.stdin is a file or TTY
  3244. // // device, it always assumes it's a TTY device. because of this, we're forcing
  3245. // // process.stdin to UTF8 encoding to at least make stdin reading compatible
  3246. // // with text files until FS.init can be refactored.
  3247. // process['stdin']['setEncoding']('utf8');
  3248. // }
  3249. },shutdown:function () {
  3250. // https://github.com/kripken/emscripten/pull/1555
  3251. // if (ENVIRONMENT_IS_NODE) {
  3252. // // inolen: any idea as to why node -e 'process.stdin.read()' wouldn't exit immediately (with process.stdin being a tty)?
  3253. // // isaacs: because now it's reading from the stream, you've expressed interest in it, so that read() kicks off a _read() which creates a ReadReq operation
  3254. // // inolen: I thought read() in that case was a synchronous operation that just grabbed some amount of buffered data if it exists?
  3255. // // isaacs: it is. but it also triggers a _read() call, which calls readStart() on the handle
  3256. // // isaacs: do process.stdin.pause() and i'd think it'd probably close the pending call
  3257. // process['stdin']['pause']();
  3258. // }
  3259. },register:function (dev, ops) {
  3260. TTY.ttys[dev] = { input: [], output: [], ops: ops };
  3261. FS.registerDevice(dev, TTY.stream_ops);
  3262. },stream_ops:{open:function (stream) {
  3263. var tty = TTY.ttys[stream.node.rdev];
  3264. if (!tty) {
  3265. throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
  3266. }
  3267. stream.tty = tty;
  3268. stream.seekable = false;
  3269. },close:function (stream) {
  3270. // flush any pending line data
  3271. stream.tty.ops.flush(stream.tty);
  3272. },flush:function (stream) {
  3273. stream.tty.ops.flush(stream.tty);
  3274. },read:function (stream, buffer, offset, length, pos /* ignored */) {
  3275. if (!stream.tty || !stream.tty.ops.get_char) {
  3276. throw new FS.ErrnoError(ERRNO_CODES.ENXIO);
  3277. }
  3278. var bytesRead = 0;
  3279. for (var i = 0; i < length; i++) {
  3280. var result;
  3281. try {
  3282. result = stream.tty.ops.get_char(stream.tty);
  3283. } catch (e) {
  3284. throw new FS.ErrnoError(ERRNO_CODES.EIO);
  3285. }
  3286. if (result === undefined && bytesRead === 0) {
  3287. throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
  3288. }
  3289. if (result === null || result === undefined) break;
  3290. bytesRead++;
  3291. buffer[offset+i] = result;
  3292. }
  3293. if (bytesRead) {
  3294. stream.node.timestamp = Date.now();
  3295. }
  3296. return bytesRead;
  3297. },write:function (stream, buffer, offset, length, pos) {
  3298. if (!stream.tty || !stream.tty.ops.put_char) {
  3299. throw new FS.ErrnoError(ERRNO_CODES.ENXIO);
  3300. }
  3301. for (var i = 0; i < length; i++) {
  3302. try {
  3303. stream.tty.ops.put_char(stream.tty, buffer[offset+i]);
  3304. } catch (e) {
  3305. throw new FS.ErrnoError(ERRNO_CODES.EIO);
  3306. }
  3307. }
  3308. if (length) {
  3309. stream.node.timestamp = Date.now();
  3310. }
  3311. return i;
  3312. }},default_tty_ops:{get_char:function (tty) {
  3313. if (!tty.input.length) {
  3314. var result = null;
  3315. if (ENVIRONMENT_IS_NODE) {
  3316. // we will read data by chunks of BUFSIZE
  3317. var BUFSIZE = 256;
  3318. var buf = new Buffer(BUFSIZE);
  3319. var bytesRead = 0;
  3320. var isPosixPlatform = (process.platform != 'win32'); // Node doesn't offer a direct check, so test by exclusion
  3321. var fd = process.stdin.fd;
  3322. if (isPosixPlatform) {
  3323. // Linux and Mac cannot use process.stdin.fd (which isn't set up as sync)
  3324. var usingDevice = false;
  3325. try {
  3326. fd = fs.openSync('/dev/stdin', 'r');
  3327. usingDevice = true;
  3328. } catch (e) {}
  3329. }
  3330. try {
  3331. bytesRead = fs.readSync(fd, buf, 0, BUFSIZE, null);
  3332. } catch(e) {
  3333. // Cross-platform differences: on Windows, reading EOF throws an exception, but on other OSes,
  3334. // reading EOF returns 0. Uniformize behavior by treating the EOF exception to return 0.
  3335. if (e.toString().indexOf('EOF') != -1) bytesRead = 0;
  3336. else throw e;
  3337. }
  3338. if (usingDevice) { fs.closeSync(fd); }
  3339. if (bytesRead > 0) {
  3340. result = buf.slice(0, bytesRead).toString('utf-8');
  3341. } else {
  3342. result = null;
  3343. }
  3344. } else if (typeof window != 'undefined' &&
  3345. typeof window.prompt == 'function') {
  3346. // Browser.
  3347. result = window.prompt('Input: '); // returns null on cancel
  3348. if (result !== null) {
  3349. result += '\n';
  3350. }
  3351. } else if (typeof readline == 'function') {
  3352. // Command line.
  3353. result = readline();
  3354. if (result !== null) {
  3355. result += '\n';
  3356. }
  3357. }
  3358. if (!result) {
  3359. return null;
  3360. }
  3361. tty.input = intArrayFromString(result, true);
  3362. }
  3363. return tty.input.shift();
  3364. },put_char:function (tty, val) {
  3365. if (val === null || val === 10) {
  3366. Module['print'](UTF8ArrayToString(tty.output, 0));
  3367. tty.output = [];
  3368. } else {
  3369. if (val != 0) tty.output.push(val); // val == 0 would cut text output off in the middle.
  3370. }
  3371. },flush:function (tty) {
  3372. if (tty.output && tty.output.length > 0) {
  3373. Module['print'](UTF8ArrayToString(tty.output, 0));
  3374. tty.output = [];
  3375. }
  3376. }},default_tty1_ops:{put_char:function (tty, val) {
  3377. if (val === null || val === 10) {
  3378. Module['printErr'](UTF8ArrayToString(tty.output, 0));
  3379. tty.output = [];
  3380. } else {
  3381. if (val != 0) tty.output.push(val);
  3382. }
  3383. },flush:function (tty) {
  3384. if (tty.output && tty.output.length > 0) {
  3385. Module['printErr'](UTF8ArrayToString(tty.output, 0));
  3386. tty.output = [];
  3387. }
  3388. }}};
  3389. var MEMFS={ops_table:null,mount:function (mount) {
  3390. return MEMFS.createNode(null, '/', 16384 | 511 /* 0777 */, 0);
  3391. },createNode:function (parent, name, mode, dev) {
  3392. if (FS.isBlkdev(mode) || FS.isFIFO(mode)) {
  3393. // no supported
  3394. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  3395. }
  3396. if (!MEMFS.ops_table) {
  3397. MEMFS.ops_table = {
  3398. dir: {
  3399. node: {
  3400. getattr: MEMFS.node_ops.getattr,
  3401. setattr: MEMFS.node_ops.setattr,
  3402. lookup: MEMFS.node_ops.lookup,
  3403. mknod: MEMFS.node_ops.mknod,
  3404. rename: MEMFS.node_ops.rename,
  3405. unlink: MEMFS.node_ops.unlink,
  3406. rmdir: MEMFS.node_ops.rmdir,
  3407. readdir: MEMFS.node_ops.readdir,
  3408. symlink: MEMFS.node_ops.symlink
  3409. },
  3410. stream: {
  3411. llseek: MEMFS.stream_ops.llseek
  3412. }
  3413. },
  3414. file: {
  3415. node: {
  3416. getattr: MEMFS.node_ops.getattr,
  3417. setattr: MEMFS.node_ops.setattr
  3418. },
  3419. stream: {
  3420. llseek: MEMFS.stream_ops.llseek,
  3421. read: MEMFS.stream_ops.read,
  3422. write: MEMFS.stream_ops.write,
  3423. allocate: MEMFS.stream_ops.allocate,
  3424. mmap: MEMFS.stream_ops.mmap,
  3425. msync: MEMFS.stream_ops.msync
  3426. }
  3427. },
  3428. link: {
  3429. node: {
  3430. getattr: MEMFS.node_ops.getattr,
  3431. setattr: MEMFS.node_ops.setattr,
  3432. readlink: MEMFS.node_ops.readlink
  3433. },
  3434. stream: {}
  3435. },
  3436. chrdev: {
  3437. node: {
  3438. getattr: MEMFS.node_ops.getattr,
  3439. setattr: MEMFS.node_ops.setattr
  3440. },
  3441. stream: FS.chrdev_stream_ops
  3442. }
  3443. };
  3444. }
  3445. var node = FS.createNode(parent, name, mode, dev);
  3446. if (FS.isDir(node.mode)) {
  3447. node.node_ops = MEMFS.ops_table.dir.node;
  3448. node.stream_ops = MEMFS.ops_table.dir.stream;
  3449. node.contents = {};
  3450. } else if (FS.isFile(node.mode)) {
  3451. node.node_ops = MEMFS.ops_table.file.node;
  3452. node.stream_ops = MEMFS.ops_table.file.stream;
  3453. node.usedBytes = 0; // The actual number of bytes used in the typed array, as opposed to contents.length which gives the whole capacity.
  3454. // When the byte data of the file is populated, this will point to either a typed array, or a normal JS array. Typed arrays are preferred
  3455. // for performance, and used by default. However, typed arrays are not resizable like normal JS arrays are, so there is a small disk size
  3456. // penalty involved for appending file writes that continuously grow a file similar to std::vector capacity vs used -scheme.
  3457. node.contents = null;
  3458. } else if (FS.isLink(node.mode)) {
  3459. node.node_ops = MEMFS.ops_table.link.node;
  3460. node.stream_ops = MEMFS.ops_table.link.stream;
  3461. } else if (FS.isChrdev(node.mode)) {
  3462. node.node_ops = MEMFS.ops_table.chrdev.node;
  3463. node.stream_ops = MEMFS.ops_table.chrdev.stream;
  3464. }
  3465. node.timestamp = Date.now();
  3466. // add the new node to the parent
  3467. if (parent) {
  3468. parent.contents[name] = node;
  3469. }
  3470. return node;
  3471. },getFileDataAsRegularArray:function (node) {
  3472. if (node.contents && node.contents.subarray) {
  3473. var arr = [];
  3474. for (var i = 0; i < node.usedBytes; ++i) arr.push(node.contents[i]);
  3475. return arr; // Returns a copy of the original data.
  3476. }
  3477. return node.contents; // No-op, the file contents are already in a JS array. Return as-is.
  3478. },getFileDataAsTypedArray:function (node) {
  3479. if (!node.contents) return new Uint8Array;
  3480. if (node.contents.subarray) return node.contents.subarray(0, node.usedBytes); // Make sure to not return excess unused bytes.
  3481. return new Uint8Array(node.contents);
  3482. },expandFileStorage:function (node, newCapacity) {
  3483. // If we are asked to expand the size of a file that already exists, revert to using a standard JS array to store the file
  3484. // instead of a typed array. This makes resizing the array more flexible because we can just .push() elements at the back to
  3485. // increase the size.
  3486. if (node.contents && node.contents.subarray && newCapacity > node.contents.length) {
  3487. node.contents = MEMFS.getFileDataAsRegularArray(node);
  3488. node.usedBytes = node.contents.length; // We might be writing to a lazy-loaded file which had overridden this property, so force-reset it.
  3489. }
  3490. if (!node.contents || node.contents.subarray) { // Keep using a typed array if creating a new storage, or if old one was a typed array as well.
  3491. var prevCapacity = node.contents ? node.contents.length : 0;
  3492. if (prevCapacity >= newCapacity) return; // No need to expand, the storage was already large enough.
  3493. // Don't expand strictly to the given requested limit if it's only a very small increase, but instead geometrically grow capacity.
  3494. // For small filesizes (<1MB), perform size*2 geometric increase, but for large sizes, do a much more conservative size*1.125 increase to
  3495. // avoid overshooting the allocation cap by a very large margin.
  3496. var CAPACITY_DOUBLING_MAX = 1024 * 1024;
  3497. newCapacity = Math.max(newCapacity, (prevCapacity * (prevCapacity < CAPACITY_DOUBLING_MAX ? 2.0 : 1.125)) | 0);
  3498. if (prevCapacity != 0) newCapacity = Math.max(newCapacity, 256); // At minimum allocate 256b for each file when expanding.
  3499. var oldContents = node.contents;
  3500. node.contents = new Uint8Array(newCapacity); // Allocate new storage.
  3501. if (node.usedBytes > 0) node.contents.set(oldContents.subarray(0, node.usedBytes), 0); // Copy old data over to the new storage.
  3502. return;
  3503. }
  3504. // Not using a typed array to back the file storage. Use a standard JS array instead.
  3505. if (!node.contents && newCapacity > 0) node.contents = [];
  3506. while (node.contents.length < newCapacity) node.contents.push(0);
  3507. },resizeFileStorage:function (node, newSize) {
  3508. if (node.usedBytes == newSize) return;
  3509. if (newSize == 0) {
  3510. node.contents = null; // Fully decommit when requesting a resize to zero.
  3511. node.usedBytes = 0;
  3512. return;
  3513. }
  3514. if (!node.contents || node.contents.subarray) { // Resize a typed array if that is being used as the backing store.
  3515. var oldContents = node.contents;
  3516. node.contents = new Uint8Array(new ArrayBuffer(newSize)); // Allocate new storage.
  3517. if (oldContents) {
  3518. node.contents.set(oldContents.subarray(0, Math.min(newSize, node.usedBytes))); // Copy old data over to the new storage.
  3519. }
  3520. node.usedBytes = newSize;
  3521. return;
  3522. }
  3523. // Backing with a JS array.
  3524. if (!node.contents) node.contents = [];
  3525. if (node.contents.length > newSize) node.contents.length = newSize;
  3526. else while (node.contents.length < newSize) node.contents.push(0);
  3527. node.usedBytes = newSize;
  3528. },node_ops:{getattr:function (node) {
  3529. var attr = {};
  3530. // device numbers reuse inode numbers.
  3531. attr.dev = FS.isChrdev(node.mode) ? node.id : 1;
  3532. attr.ino = node.id;
  3533. attr.mode = node.mode;
  3534. attr.nlink = 1;
  3535. attr.uid = 0;
  3536. attr.gid = 0;
  3537. attr.rdev = node.rdev;
  3538. if (FS.isDir(node.mode)) {
  3539. attr.size = 4096;
  3540. } else if (FS.isFile(node.mode)) {
  3541. attr.size = node.usedBytes;
  3542. } else if (FS.isLink(node.mode)) {
  3543. attr.size = node.link.length;
  3544. } else {
  3545. attr.size = 0;
  3546. }
  3547. attr.atime = new Date(node.timestamp);
  3548. attr.mtime = new Date(node.timestamp);
  3549. attr.ctime = new Date(node.timestamp);
  3550. // NOTE: In our implementation, st_blocks = Math.ceil(st_size/st_blksize),
  3551. // but this is not required by the standard.
  3552. attr.blksize = 4096;
  3553. attr.blocks = Math.ceil(attr.size / attr.blksize);
  3554. return attr;
  3555. },setattr:function (node, attr) {
  3556. if (attr.mode !== undefined) {
  3557. node.mode = attr.mode;
  3558. }
  3559. if (attr.timestamp !== undefined) {
  3560. node.timestamp = attr.timestamp;
  3561. }
  3562. if (attr.size !== undefined) {
  3563. MEMFS.resizeFileStorage(node, attr.size);
  3564. }
  3565. },lookup:function (parent, name) {
  3566. throw FS.genericErrors[ERRNO_CODES.ENOENT];
  3567. },mknod:function (parent, name, mode, dev) {
  3568. return MEMFS.createNode(parent, name, mode, dev);
  3569. },rename:function (old_node, new_dir, new_name) {
  3570. // if we're overwriting a directory at new_name, make sure it's empty.
  3571. if (FS.isDir(old_node.mode)) {
  3572. var new_node;
  3573. try {
  3574. new_node = FS.lookupNode(new_dir, new_name);
  3575. } catch (e) {
  3576. }
  3577. if (new_node) {
  3578. for (var i in new_node.contents) {
  3579. throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
  3580. }
  3581. }
  3582. }
  3583. // do the internal rewiring
  3584. delete old_node.parent.contents[old_node.name];
  3585. old_node.name = new_name;
  3586. new_dir.contents[new_name] = old_node;
  3587. old_node.parent = new_dir;
  3588. },unlink:function (parent, name) {
  3589. delete parent.contents[name];
  3590. },rmdir:function (parent, name) {
  3591. var node = FS.lookupNode(parent, name);
  3592. for (var i in node.contents) {
  3593. throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
  3594. }
  3595. delete parent.contents[name];
  3596. },readdir:function (node) {
  3597. var entries = ['.', '..']
  3598. for (var key in node.contents) {
  3599. if (!node.contents.hasOwnProperty(key)) {
  3600. continue;
  3601. }
  3602. entries.push(key);
  3603. }
  3604. return entries;
  3605. },symlink:function (parent, newname, oldpath) {
  3606. var node = MEMFS.createNode(parent, newname, 511 /* 0777 */ | 40960, 0);
  3607. node.link = oldpath;
  3608. return node;
  3609. },readlink:function (node) {
  3610. if (!FS.isLink(node.mode)) {
  3611. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  3612. }
  3613. return node.link;
  3614. }},stream_ops:{read:function (stream, buffer, offset, length, position) {
  3615. var contents = stream.node.contents;
  3616. if (position >= stream.node.usedBytes) return 0;
  3617. var size = Math.min(stream.node.usedBytes - position, length);
  3618. assert(size >= 0);
  3619. if (size > 8 && contents.subarray) { // non-trivial, and typed array
  3620. buffer.set(contents.subarray(position, position + size), offset);
  3621. } else {
  3622. for (var i = 0; i < size; i++) buffer[offset + i] = contents[position + i];
  3623. }
  3624. return size;
  3625. },write:function (stream, buffer, offset, length, position, canOwn) {
  3626. if (!length) return 0;
  3627. var node = stream.node;
  3628. node.timestamp = Date.now();
  3629. if (buffer.subarray && (!node.contents || node.contents.subarray)) { // This write is from a typed array to a typed array?
  3630. if (canOwn) {
  3631. assert(position === 0, 'canOwn must imply no weird position inside the file');
  3632. node.contents = buffer.subarray(offset, offset + length);
  3633. node.usedBytes = length;
  3634. return length;
  3635. } else if (node.usedBytes === 0 && position === 0) { // If this is a simple first write to an empty file, do a fast set since we don't need to care about old data.
  3636. node.contents = new Uint8Array(buffer.subarray(offset, offset + length));
  3637. node.usedBytes = length;
  3638. return length;
  3639. } else if (position + length <= node.usedBytes) { // Writing to an already allocated and used subrange of the file?
  3640. node.contents.set(buffer.subarray(offset, offset + length), position);
  3641. return length;
  3642. }
  3643. }
  3644. // Appending to an existing file and we need to reallocate, or source data did not come as a typed array.
  3645. MEMFS.expandFileStorage(node, position+length);
  3646. if (node.contents.subarray && buffer.subarray) node.contents.set(buffer.subarray(offset, offset + length), position); // Use typed array write if available.
  3647. else {
  3648. for (var i = 0; i < length; i++) {
  3649. node.contents[position + i] = buffer[offset + i]; // Or fall back to manual write if not.
  3650. }
  3651. }
  3652. node.usedBytes = Math.max(node.usedBytes, position+length);
  3653. return length;
  3654. },llseek:function (stream, offset, whence) {
  3655. var position = offset;
  3656. if (whence === 1) { // SEEK_CUR.
  3657. position += stream.position;
  3658. } else if (whence === 2) { // SEEK_END.
  3659. if (FS.isFile(stream.node.mode)) {
  3660. position += stream.node.usedBytes;
  3661. }
  3662. }
  3663. if (position < 0) {
  3664. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  3665. }
  3666. return position;
  3667. },allocate:function (stream, offset, length) {
  3668. MEMFS.expandFileStorage(stream.node, offset + length);
  3669. stream.node.usedBytes = Math.max(stream.node.usedBytes, offset + length);
  3670. },mmap:function (stream, buffer, offset, length, position, prot, flags) {
  3671. if (!FS.isFile(stream.node.mode)) {
  3672. throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
  3673. }
  3674. var ptr;
  3675. var allocated;
  3676. var contents = stream.node.contents;
  3677. // Only make a new copy when MAP_PRIVATE is specified.
  3678. if ( !(flags & 2) &&
  3679. (contents.buffer === buffer || contents.buffer === buffer.buffer) ) {
  3680. // We can't emulate MAP_SHARED when the file is not backed by the buffer
  3681. // we're mapping to (e.g. the HEAP buffer).
  3682. allocated = false;
  3683. ptr = contents.byteOffset;
  3684. } else {
  3685. // Try to avoid unnecessary slices.
  3686. if (position > 0 || position + length < stream.node.usedBytes) {
  3687. if (contents.subarray) {
  3688. contents = contents.subarray(position, position + length);
  3689. } else {
  3690. contents = Array.prototype.slice.call(contents, position, position + length);
  3691. }
  3692. }
  3693. allocated = true;
  3694. ptr = _malloc(length);
  3695. if (!ptr) {
  3696. throw new FS.ErrnoError(ERRNO_CODES.ENOMEM);
  3697. }
  3698. buffer.set(contents, ptr);
  3699. }
  3700. return { ptr: ptr, allocated: allocated };
  3701. },msync:function (stream, buffer, offset, length, mmapFlags) {
  3702. if (!FS.isFile(stream.node.mode)) {
  3703. throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
  3704. }
  3705. if (mmapFlags & 2) {
  3706. // MAP_PRIVATE calls need not to be synced back to underlying fs
  3707. return 0;
  3708. }
  3709. var bytesWritten = MEMFS.stream_ops.write(stream, buffer, 0, length, offset, false);
  3710. // should we check if bytesWritten and length are the same?
  3711. return 0;
  3712. }}};
  3713. var IDBFS={dbs:{},indexedDB:function () {
  3714. if (typeof indexedDB !== 'undefined') return indexedDB;
  3715. var ret = null;
  3716. if (typeof window === 'object') ret = window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB;
  3717. assert(ret, 'IDBFS used, but indexedDB not supported');
  3718. return ret;
  3719. },DB_VERSION:21,DB_STORE_NAME:"FILE_DATA",mount:function (mount) {
  3720. // reuse all of the core MEMFS functionality
  3721. return MEMFS.mount.apply(null, arguments);
  3722. },syncfs:function (mount, populate, callback) {
  3723. IDBFS.getLocalSet(mount, function(err, local) {
  3724. if (err) return callback(err);
  3725. IDBFS.getRemoteSet(mount, function(err, remote) {
  3726. if (err) return callback(err);
  3727. var src = populate ? remote : local;
  3728. var dst = populate ? local : remote;
  3729. IDBFS.reconcile(src, dst, callback);
  3730. });
  3731. });
  3732. },getDB:function (name, callback) {
  3733. // check the cache first
  3734. var db = IDBFS.dbs[name];
  3735. if (db) {
  3736. return callback(null, db);
  3737. }
  3738. var req;
  3739. try {
  3740. req = IDBFS.indexedDB().open(name, IDBFS.DB_VERSION);
  3741. } catch (e) {
  3742. return callback(e);
  3743. }
  3744. if (!req) {
  3745. return callback("Unable to connect to IndexedDB");
  3746. }
  3747. req.onupgradeneeded = function(e) {
  3748. var db = e.target.result;
  3749. var transaction = e.target.transaction;
  3750. var fileStore;
  3751. if (db.objectStoreNames.contains(IDBFS.DB_STORE_NAME)) {
  3752. fileStore = transaction.objectStore(IDBFS.DB_STORE_NAME);
  3753. } else {
  3754. fileStore = db.createObjectStore(IDBFS.DB_STORE_NAME);
  3755. }
  3756. if (!fileStore.indexNames.contains('timestamp')) {
  3757. fileStore.createIndex('timestamp', 'timestamp', { unique: false });
  3758. }
  3759. };
  3760. req.onsuccess = function() {
  3761. db = req.result;
  3762. // add to the cache
  3763. IDBFS.dbs[name] = db;
  3764. callback(null, db);
  3765. };
  3766. req.onerror = function(e) {
  3767. callback(this.error);
  3768. e.preventDefault();
  3769. };
  3770. },getLocalSet:function (mount, callback) {
  3771. var entries = {};
  3772. function isRealDir(p) {
  3773. return p !== '.' && p !== '..';
  3774. };
  3775. function toAbsolute(root) {
  3776. return function(p) {
  3777. return PATH.join2(root, p);
  3778. }
  3779. };
  3780. var check = FS.readdir(mount.mountpoint).filter(isRealDir).map(toAbsolute(mount.mountpoint));
  3781. while (check.length) {
  3782. var path = check.pop();
  3783. var stat;
  3784. try {
  3785. stat = FS.stat(path);
  3786. } catch (e) {
  3787. return callback(e);
  3788. }
  3789. if (FS.isDir(stat.mode)) {
  3790. check.push.apply(check, FS.readdir(path).filter(isRealDir).map(toAbsolute(path)));
  3791. }
  3792. entries[path] = { timestamp: stat.mtime };
  3793. }
  3794. return callback(null, { type: 'local', entries: entries });
  3795. },getRemoteSet:function (mount, callback) {
  3796. var entries = {};
  3797. IDBFS.getDB(mount.mountpoint, function(err, db) {
  3798. if (err) return callback(err);
  3799. var transaction = db.transaction([IDBFS.DB_STORE_NAME], 'readonly');
  3800. transaction.onerror = function(e) {
  3801. callback(this.error);
  3802. e.preventDefault();
  3803. };
  3804. var store = transaction.objectStore(IDBFS.DB_STORE_NAME);
  3805. var index = store.index('timestamp');
  3806. index.openKeyCursor().onsuccess = function(event) {
  3807. var cursor = event.target.result;
  3808. if (!cursor) {
  3809. return callback(null, { type: 'remote', db: db, entries: entries });
  3810. }
  3811. entries[cursor.primaryKey] = { timestamp: cursor.key };
  3812. cursor.continue();
  3813. };
  3814. });
  3815. },loadLocalEntry:function (path, callback) {
  3816. var stat, node;
  3817. try {
  3818. var lookup = FS.lookupPath(path);
  3819. node = lookup.node;
  3820. stat = FS.stat(path);
  3821. } catch (e) {
  3822. return callback(e);
  3823. }
  3824. if (FS.isDir(stat.mode)) {
  3825. return callback(null, { timestamp: stat.mtime, mode: stat.mode });
  3826. } else if (FS.isFile(stat.mode)) {
  3827. // Performance consideration: storing a normal JavaScript array to a IndexedDB is much slower than storing a typed array.
  3828. // Therefore always convert the file contents to a typed array first before writing the data to IndexedDB.
  3829. node.contents = MEMFS.getFileDataAsTypedArray(node);
  3830. return callback(null, { timestamp: stat.mtime, mode: stat.mode, contents: node.contents });
  3831. } else {
  3832. return callback(new Error('node type not supported'));
  3833. }
  3834. },storeLocalEntry:function (path, entry, callback) {
  3835. try {
  3836. if (FS.isDir(entry.mode)) {
  3837. FS.mkdir(path, entry.mode);
  3838. } else if (FS.isFile(entry.mode)) {
  3839. FS.writeFile(path, entry.contents, { encoding: 'binary', canOwn: true });
  3840. } else {
  3841. return callback(new Error('node type not supported'));
  3842. }
  3843. FS.chmod(path, entry.mode);
  3844. FS.utime(path, entry.timestamp, entry.timestamp);
  3845. } catch (e) {
  3846. return callback(e);
  3847. }
  3848. callback(null);
  3849. },removeLocalEntry:function (path, callback) {
  3850. try {
  3851. var lookup = FS.lookupPath(path);
  3852. var stat = FS.stat(path);
  3853. if (FS.isDir(stat.mode)) {
  3854. FS.rmdir(path);
  3855. } else if (FS.isFile(stat.mode)) {
  3856. FS.unlink(path);
  3857. }
  3858. } catch (e) {
  3859. return callback(e);
  3860. }
  3861. callback(null);
  3862. },loadRemoteEntry:function (store, path, callback) {
  3863. var req = store.get(path);
  3864. req.onsuccess = function(event) { callback(null, event.target.result); };
  3865. req.onerror = function(e) {
  3866. callback(this.error);
  3867. e.preventDefault();
  3868. };
  3869. },storeRemoteEntry:function (store, path, entry, callback) {
  3870. var req = store.put(entry, path);
  3871. req.onsuccess = function() { callback(null); };
  3872. req.onerror = function(e) {
  3873. callback(this.error);
  3874. e.preventDefault();
  3875. };
  3876. },removeRemoteEntry:function (store, path, callback) {
  3877. var req = store.delete(path);
  3878. req.onsuccess = function() { callback(null); };
  3879. req.onerror = function(e) {
  3880. callback(this.error);
  3881. e.preventDefault();
  3882. };
  3883. },reconcile:function (src, dst, callback) {
  3884. var total = 0;
  3885. var create = [];
  3886. Object.keys(src.entries).forEach(function (key) {
  3887. var e = src.entries[key];
  3888. var e2 = dst.entries[key];
  3889. if (!e2 || e.timestamp > e2.timestamp) {
  3890. create.push(key);
  3891. total++;
  3892. }
  3893. });
  3894. var remove = [];
  3895. Object.keys(dst.entries).forEach(function (key) {
  3896. var e = dst.entries[key];
  3897. var e2 = src.entries[key];
  3898. if (!e2) {
  3899. remove.push(key);
  3900. total++;
  3901. }
  3902. });
  3903. if (!total) {
  3904. return callback(null);
  3905. }
  3906. var errored = false;
  3907. var completed = 0;
  3908. var db = src.type === 'remote' ? src.db : dst.db;
  3909. var transaction = db.transaction([IDBFS.DB_STORE_NAME], 'readwrite');
  3910. var store = transaction.objectStore(IDBFS.DB_STORE_NAME);
  3911. function done(err) {
  3912. if (err) {
  3913. if (!done.errored) {
  3914. done.errored = true;
  3915. return callback(err);
  3916. }
  3917. return;
  3918. }
  3919. if (++completed >= total) {
  3920. return callback(null);
  3921. }
  3922. };
  3923. transaction.onerror = function(e) {
  3924. done(this.error);
  3925. e.preventDefault();
  3926. };
  3927. // sort paths in ascending order so directory entries are created
  3928. // before the files inside them
  3929. create.sort().forEach(function (path) {
  3930. if (dst.type === 'local') {
  3931. IDBFS.loadRemoteEntry(store, path, function (err, entry) {
  3932. if (err) return done(err);
  3933. IDBFS.storeLocalEntry(path, entry, done);
  3934. });
  3935. } else {
  3936. IDBFS.loadLocalEntry(path, function (err, entry) {
  3937. if (err) return done(err);
  3938. IDBFS.storeRemoteEntry(store, path, entry, done);
  3939. });
  3940. }
  3941. });
  3942. // sort paths in descending order so files are deleted before their
  3943. // parent directories
  3944. remove.sort().reverse().forEach(function(path) {
  3945. if (dst.type === 'local') {
  3946. IDBFS.removeLocalEntry(path, done);
  3947. } else {
  3948. IDBFS.removeRemoteEntry(store, path, done);
  3949. }
  3950. });
  3951. }};
  3952. var NODEFS={isWindows:false,staticInit:function () {
  3953. NODEFS.isWindows = !!process.platform.match(/^win/);
  3954. },mount:function (mount) {
  3955. assert(ENVIRONMENT_IS_NODE);
  3956. return NODEFS.createNode(null, '/', NODEFS.getMode(mount.opts.root), 0);
  3957. },createNode:function (parent, name, mode, dev) {
  3958. if (!FS.isDir(mode) && !FS.isFile(mode) && !FS.isLink(mode)) {
  3959. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  3960. }
  3961. var node = FS.createNode(parent, name, mode);
  3962. node.node_ops = NODEFS.node_ops;
  3963. node.stream_ops = NODEFS.stream_ops;
  3964. return node;
  3965. },getMode:function (path) {
  3966. var stat;
  3967. try {
  3968. stat = fs.lstatSync(path);
  3969. if (NODEFS.isWindows) {
  3970. // On Windows, directories return permission bits 'rw-rw-rw-', even though they have 'rwxrwxrwx', so
  3971. // propagate write bits to execute bits.
  3972. stat.mode = stat.mode | ((stat.mode & 146) >> 1);
  3973. }
  3974. } catch (e) {
  3975. if (!e.code) throw e;
  3976. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  3977. }
  3978. return stat.mode;
  3979. },realPath:function (node) {
  3980. var parts = [];
  3981. while (node.parent !== node) {
  3982. parts.push(node.name);
  3983. node = node.parent;
  3984. }
  3985. parts.push(node.mount.opts.root);
  3986. parts.reverse();
  3987. return PATH.join.apply(null, parts);
  3988. },flagsToPermissionStringMap:{0:"r",1:"r+",2:"r+",64:"r",65:"r+",66:"r+",129:"rx+",193:"rx+",514:"w+",577:"w",578:"w+",705:"wx",706:"wx+",1024:"a",1025:"a",1026:"a+",1089:"a",1090:"a+",1153:"ax",1154:"ax+",1217:"ax",1218:"ax+",4096:"rs",4098:"rs+"},flagsToPermissionString:function (flags) {
  3989. flags &= ~0x200000 /*O_PATH*/; // Ignore this flag from musl, otherwise node.js fails to open the file.
  3990. flags &= ~0x800 /*O_NONBLOCK*/; // Ignore this flag from musl, otherwise node.js fails to open the file.
  3991. flags &= ~0x8000 /*O_LARGEFILE*/; // Ignore this flag from musl, otherwise node.js fails to open the file.
  3992. flags &= ~0x80000 /*O_CLOEXEC*/; // Some applications may pass it; it makes no sense for a single process.
  3993. if (flags in NODEFS.flagsToPermissionStringMap) {
  3994. return NODEFS.flagsToPermissionStringMap[flags];
  3995. } else {
  3996. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  3997. }
  3998. },node_ops:{getattr:function (node) {
  3999. var path = NODEFS.realPath(node);
  4000. var stat;
  4001. try {
  4002. stat = fs.lstatSync(path);
  4003. } catch (e) {
  4004. if (!e.code) throw e;
  4005. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4006. }
  4007. // node.js v0.10.20 doesn't report blksize and blocks on Windows. Fake them with default blksize of 4096.
  4008. // See http://support.microsoft.com/kb/140365
  4009. if (NODEFS.isWindows && !stat.blksize) {
  4010. stat.blksize = 4096;
  4011. }
  4012. if (NODEFS.isWindows && !stat.blocks) {
  4013. stat.blocks = (stat.size+stat.blksize-1)/stat.blksize|0;
  4014. }
  4015. return {
  4016. dev: stat.dev,
  4017. ino: stat.ino,
  4018. mode: stat.mode,
  4019. nlink: stat.nlink,
  4020. uid: stat.uid,
  4021. gid: stat.gid,
  4022. rdev: stat.rdev,
  4023. size: stat.size,
  4024. atime: stat.atime,
  4025. mtime: stat.mtime,
  4026. ctime: stat.ctime,
  4027. blksize: stat.blksize,
  4028. blocks: stat.blocks
  4029. };
  4030. },setattr:function (node, attr) {
  4031. var path = NODEFS.realPath(node);
  4032. try {
  4033. if (attr.mode !== undefined) {
  4034. fs.chmodSync(path, attr.mode);
  4035. // update the common node structure mode as well
  4036. node.mode = attr.mode;
  4037. }
  4038. if (attr.timestamp !== undefined) {
  4039. var date = new Date(attr.timestamp);
  4040. fs.utimesSync(path, date, date);
  4041. }
  4042. if (attr.size !== undefined) {
  4043. fs.truncateSync(path, attr.size);
  4044. }
  4045. } catch (e) {
  4046. if (!e.code) throw e;
  4047. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4048. }
  4049. },lookup:function (parent, name) {
  4050. var path = PATH.join2(NODEFS.realPath(parent), name);
  4051. var mode = NODEFS.getMode(path);
  4052. return NODEFS.createNode(parent, name, mode);
  4053. },mknod:function (parent, name, mode, dev) {
  4054. var node = NODEFS.createNode(parent, name, mode, dev);
  4055. // create the backing node for this in the fs root as well
  4056. var path = NODEFS.realPath(node);
  4057. try {
  4058. if (FS.isDir(node.mode)) {
  4059. fs.mkdirSync(path, node.mode);
  4060. } else {
  4061. fs.writeFileSync(path, '', { mode: node.mode });
  4062. }
  4063. } catch (e) {
  4064. if (!e.code) throw e;
  4065. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4066. }
  4067. return node;
  4068. },rename:function (oldNode, newDir, newName) {
  4069. var oldPath = NODEFS.realPath(oldNode);
  4070. var newPath = PATH.join2(NODEFS.realPath(newDir), newName);
  4071. try {
  4072. fs.renameSync(oldPath, newPath);
  4073. } catch (e) {
  4074. if (!e.code) throw e;
  4075. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4076. }
  4077. },unlink:function (parent, name) {
  4078. var path = PATH.join2(NODEFS.realPath(parent), name);
  4079. try {
  4080. fs.unlinkSync(path);
  4081. } catch (e) {
  4082. if (!e.code) throw e;
  4083. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4084. }
  4085. },rmdir:function (parent, name) {
  4086. var path = PATH.join2(NODEFS.realPath(parent), name);
  4087. try {
  4088. fs.rmdirSync(path);
  4089. } catch (e) {
  4090. if (!e.code) throw e;
  4091. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4092. }
  4093. },readdir:function (node) {
  4094. var path = NODEFS.realPath(node);
  4095. try {
  4096. return fs.readdirSync(path);
  4097. } catch (e) {
  4098. if (!e.code) throw e;
  4099. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4100. }
  4101. },symlink:function (parent, newName, oldPath) {
  4102. var newPath = PATH.join2(NODEFS.realPath(parent), newName);
  4103. try {
  4104. fs.symlinkSync(oldPath, newPath);
  4105. } catch (e) {
  4106. if (!e.code) throw e;
  4107. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4108. }
  4109. },readlink:function (node) {
  4110. var path = NODEFS.realPath(node);
  4111. try {
  4112. path = fs.readlinkSync(path);
  4113. path = NODEJS_PATH.relative(NODEJS_PATH.resolve(node.mount.opts.root), path);
  4114. return path;
  4115. } catch (e) {
  4116. if (!e.code) throw e;
  4117. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4118. }
  4119. }},stream_ops:{open:function (stream) {
  4120. var path = NODEFS.realPath(stream.node);
  4121. try {
  4122. if (FS.isFile(stream.node.mode)) {
  4123. stream.nfd = fs.openSync(path, NODEFS.flagsToPermissionString(stream.flags));
  4124. }
  4125. } catch (e) {
  4126. if (!e.code) throw e;
  4127. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4128. }
  4129. },close:function (stream) {
  4130. try {
  4131. if (FS.isFile(stream.node.mode) && stream.nfd) {
  4132. fs.closeSync(stream.nfd);
  4133. }
  4134. } catch (e) {
  4135. if (!e.code) throw e;
  4136. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4137. }
  4138. },read:function (stream, buffer, offset, length, position) {
  4139. if (length === 0) return 0; // node errors on 0 length reads
  4140. // FIXME this is terrible.
  4141. var nbuffer = new Buffer(length);
  4142. var res;
  4143. try {
  4144. res = fs.readSync(stream.nfd, nbuffer, 0, length, position);
  4145. } catch (e) {
  4146. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4147. }
  4148. if (res > 0) {
  4149. for (var i = 0; i < res; i++) {
  4150. buffer[offset + i] = nbuffer[i];
  4151. }
  4152. }
  4153. return res;
  4154. },write:function (stream, buffer, offset, length, position) {
  4155. // FIXME this is terrible.
  4156. var nbuffer = new Buffer(buffer.subarray(offset, offset + length));
  4157. var res;
  4158. try {
  4159. res = fs.writeSync(stream.nfd, nbuffer, 0, length, position);
  4160. } catch (e) {
  4161. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4162. }
  4163. return res;
  4164. },llseek:function (stream, offset, whence) {
  4165. var position = offset;
  4166. if (whence === 1) { // SEEK_CUR.
  4167. position += stream.position;
  4168. } else if (whence === 2) { // SEEK_END.
  4169. if (FS.isFile(stream.node.mode)) {
  4170. try {
  4171. var stat = fs.fstatSync(stream.nfd);
  4172. position += stat.size;
  4173. } catch (e) {
  4174. throw new FS.ErrnoError(ERRNO_CODES[e.code]);
  4175. }
  4176. }
  4177. }
  4178. if (position < 0) {
  4179. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  4180. }
  4181. return position;
  4182. }}};
  4183. var WORKERFS={DIR_MODE:16895,FILE_MODE:33279,reader:null,mount:function (mount) {
  4184. assert(ENVIRONMENT_IS_WORKER);
  4185. if (!WORKERFS.reader) WORKERFS.reader = new FileReaderSync();
  4186. var root = WORKERFS.createNode(null, '/', WORKERFS.DIR_MODE, 0);
  4187. var createdParents = {};
  4188. function ensureParent(path) {
  4189. // return the parent node, creating subdirs as necessary
  4190. var parts = path.split('/');
  4191. var parent = root;
  4192. for (var i = 0; i < parts.length-1; i++) {
  4193. var curr = parts.slice(0, i+1).join('/');
  4194. // Issue 4254: Using curr as a node name will prevent the node
  4195. // from being found in FS.nameTable when FS.open is called on
  4196. // a path which holds a child of this node,
  4197. // given that all FS functions assume node names
  4198. // are just their corresponding parts within their given path,
  4199. // rather than incremental aggregates which include their parent's
  4200. // directories.
  4201. if (!createdParents[curr]) {
  4202. createdParents[curr] = WORKERFS.createNode(parent, parts[i], WORKERFS.DIR_MODE, 0);
  4203. }
  4204. parent = createdParents[curr];
  4205. }
  4206. return parent;
  4207. }
  4208. function base(path) {
  4209. var parts = path.split('/');
  4210. return parts[parts.length-1];
  4211. }
  4212. // We also accept FileList here, by using Array.prototype
  4213. Array.prototype.forEach.call(mount.opts["files"] || [], function(file) {
  4214. WORKERFS.createNode(ensureParent(file.name), base(file.name), WORKERFS.FILE_MODE, 0, file, file.lastModifiedDate);
  4215. });
  4216. (mount.opts["blobs"] || []).forEach(function(obj) {
  4217. WORKERFS.createNode(ensureParent(obj["name"]), base(obj["name"]), WORKERFS.FILE_MODE, 0, obj["data"]);
  4218. });
  4219. (mount.opts["packages"] || []).forEach(function(pack) {
  4220. pack['metadata'].files.forEach(function(file) {
  4221. var name = file.filename.substr(1); // remove initial slash
  4222. WORKERFS.createNode(ensureParent(name), base(name), WORKERFS.FILE_MODE, 0, pack['blob'].slice(file.start, file.end));
  4223. });
  4224. });
  4225. return root;
  4226. },createNode:function (parent, name, mode, dev, contents, mtime) {
  4227. var node = FS.createNode(parent, name, mode);
  4228. node.mode = mode;
  4229. node.node_ops = WORKERFS.node_ops;
  4230. node.stream_ops = WORKERFS.stream_ops;
  4231. node.timestamp = (mtime || new Date).getTime();
  4232. assert(WORKERFS.FILE_MODE !== WORKERFS.DIR_MODE);
  4233. if (mode === WORKERFS.FILE_MODE) {
  4234. node.size = contents.size;
  4235. node.contents = contents;
  4236. } else {
  4237. node.size = 4096;
  4238. node.contents = {};
  4239. }
  4240. if (parent) {
  4241. parent.contents[name] = node;
  4242. }
  4243. return node;
  4244. },node_ops:{getattr:function (node) {
  4245. return {
  4246. dev: 1,
  4247. ino: undefined,
  4248. mode: node.mode,
  4249. nlink: 1,
  4250. uid: 0,
  4251. gid: 0,
  4252. rdev: undefined,
  4253. size: node.size,
  4254. atime: new Date(node.timestamp),
  4255. mtime: new Date(node.timestamp),
  4256. ctime: new Date(node.timestamp),
  4257. blksize: 4096,
  4258. blocks: Math.ceil(node.size / 4096),
  4259. };
  4260. },setattr:function (node, attr) {
  4261. if (attr.mode !== undefined) {
  4262. node.mode = attr.mode;
  4263. }
  4264. if (attr.timestamp !== undefined) {
  4265. node.timestamp = attr.timestamp;
  4266. }
  4267. },lookup:function (parent, name) {
  4268. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  4269. },mknod:function (parent, name, mode, dev) {
  4270. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4271. },rename:function (oldNode, newDir, newName) {
  4272. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4273. },unlink:function (parent, name) {
  4274. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4275. },rmdir:function (parent, name) {
  4276. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4277. },readdir:function (node) {
  4278. var entries = ['.', '..'];
  4279. for (var key in node.contents) {
  4280. if (!node.contents.hasOwnProperty(key)) {
  4281. continue;
  4282. }
  4283. entries.push(key);
  4284. }
  4285. return entries;
  4286. },symlink:function (parent, newName, oldPath) {
  4287. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4288. },readlink:function (node) {
  4289. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4290. }},stream_ops:{read:function (stream, buffer, offset, length, position) {
  4291. if (position >= stream.node.size) return 0;
  4292. var chunk = stream.node.contents.slice(position, position + length);
  4293. var ab = WORKERFS.reader.readAsArrayBuffer(chunk);
  4294. buffer.set(new Uint8Array(ab), offset);
  4295. return chunk.size;
  4296. },write:function (stream, buffer, offset, length, position) {
  4297. throw new FS.ErrnoError(ERRNO_CODES.EIO);
  4298. },llseek:function (stream, offset, whence) {
  4299. var position = offset;
  4300. if (whence === 1) { // SEEK_CUR.
  4301. position += stream.position;
  4302. } else if (whence === 2) { // SEEK_END.
  4303. if (FS.isFile(stream.node.mode)) {
  4304. position += stream.node.size;
  4305. }
  4306. }
  4307. if (position < 0) {
  4308. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  4309. }
  4310. return position;
  4311. }}};
  4312. var _stdin=STATICTOP; STATICTOP += 16;;
  4313. var _stdout=STATICTOP; STATICTOP += 16;;
  4314. var _stderr=STATICTOP; STATICTOP += 16;;var FS={root:null,mounts:[],devices:[null],streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:false,ignorePermissions:true,trackingDelegate:{},tracking:{openFlags:{READ:1,WRITE:2}},ErrnoError:null,genericErrors:{},filesystems:null,syncFSRequests:0,handleFSError:function (e) {
  4315. if (!(e instanceof FS.ErrnoError)) throw e + ' : ' + stackTrace();
  4316. return ___setErrNo(e.errno);
  4317. },lookupPath:function (path, opts) {
  4318. path = PATH.resolve(FS.cwd(), path);
  4319. opts = opts || {};
  4320. if (!path) return { path: '', node: null };
  4321. var defaults = {
  4322. follow_mount: true,
  4323. recurse_count: 0
  4324. };
  4325. for (var key in defaults) {
  4326. if (opts[key] === undefined) {
  4327. opts[key] = defaults[key];
  4328. }
  4329. }
  4330. if (opts.recurse_count > 8) { // max recursive lookup of 8
  4331. throw new FS.ErrnoError(ERRNO_CODES.ELOOP);
  4332. }
  4333. // split the path
  4334. var parts = PATH.normalizeArray(path.split('/').filter(function(p) {
  4335. return !!p;
  4336. }), false);
  4337. // start at the root
  4338. var current = FS.root;
  4339. var current_path = '/';
  4340. for (var i = 0; i < parts.length; i++) {
  4341. var islast = (i === parts.length-1);
  4342. if (islast && opts.parent) {
  4343. // stop resolving
  4344. break;
  4345. }
  4346. current = FS.lookupNode(current, parts[i]);
  4347. current_path = PATH.join2(current_path, parts[i]);
  4348. // jump to the mount's root node if this is a mountpoint
  4349. if (FS.isMountpoint(current)) {
  4350. if (!islast || (islast && opts.follow_mount)) {
  4351. current = current.mounted.root;
  4352. }
  4353. }
  4354. // by default, lookupPath will not follow a symlink if it is the final path component.
  4355. // setting opts.follow = true will override this behavior.
  4356. if (!islast || opts.follow) {
  4357. var count = 0;
  4358. while (FS.isLink(current.mode)) {
  4359. var link = FS.readlink(current_path);
  4360. current_path = PATH.resolve(PATH.dirname(current_path), link);
  4361. var lookup = FS.lookupPath(current_path, { recurse_count: opts.recurse_count });
  4362. current = lookup.node;
  4363. if (count++ > 40) { // limit max consecutive symlinks to 40 (SYMLOOP_MAX).
  4364. throw new FS.ErrnoError(ERRNO_CODES.ELOOP);
  4365. }
  4366. }
  4367. }
  4368. }
  4369. return { path: current_path, node: current };
  4370. },getPath:function (node) {
  4371. var path;
  4372. while (true) {
  4373. if (FS.isRoot(node)) {
  4374. var mount = node.mount.mountpoint;
  4375. if (!path) return mount;
  4376. return mount[mount.length-1] !== '/' ? mount + '/' + path : mount + path;
  4377. }
  4378. path = path ? node.name + '/' + path : node.name;
  4379. node = node.parent;
  4380. }
  4381. },hashName:function (parentid, name) {
  4382. var hash = 0;
  4383. for (var i = 0; i < name.length; i++) {
  4384. hash = ((hash << 5) - hash + name.charCodeAt(i)) | 0;
  4385. }
  4386. return ((parentid + hash) >>> 0) % FS.nameTable.length;
  4387. },hashAddNode:function (node) {
  4388. var hash = FS.hashName(node.parent.id, node.name);
  4389. node.name_next = FS.nameTable[hash];
  4390. FS.nameTable[hash] = node;
  4391. },hashRemoveNode:function (node) {
  4392. var hash = FS.hashName(node.parent.id, node.name);
  4393. if (FS.nameTable[hash] === node) {
  4394. FS.nameTable[hash] = node.name_next;
  4395. } else {
  4396. var current = FS.nameTable[hash];
  4397. while (current) {
  4398. if (current.name_next === node) {
  4399. current.name_next = node.name_next;
  4400. break;
  4401. }
  4402. current = current.name_next;
  4403. }
  4404. }
  4405. },lookupNode:function (parent, name) {
  4406. var err = FS.mayLookup(parent);
  4407. if (err) {
  4408. throw new FS.ErrnoError(err, parent);
  4409. }
  4410. var hash = FS.hashName(parent.id, name);
  4411. for (var node = FS.nameTable[hash]; node; node = node.name_next) {
  4412. var nodeName = node.name;
  4413. if (node.parent.id === parent.id && nodeName === name) {
  4414. return node;
  4415. }
  4416. }
  4417. // if we failed to find it in the cache, call into the VFS
  4418. return FS.lookup(parent, name);
  4419. },createNode:function (parent, name, mode, rdev) {
  4420. if (!FS.FSNode) {
  4421. FS.FSNode = function(parent, name, mode, rdev) {
  4422. if (!parent) {
  4423. parent = this; // root node sets parent to itself
  4424. }
  4425. this.parent = parent;
  4426. this.mount = parent.mount;
  4427. this.mounted = null;
  4428. this.id = FS.nextInode++;
  4429. this.name = name;
  4430. this.mode = mode;
  4431. this.node_ops = {};
  4432. this.stream_ops = {};
  4433. this.rdev = rdev;
  4434. };
  4435. FS.FSNode.prototype = {};
  4436. // compatibility
  4437. var readMode = 292 | 73;
  4438. var writeMode = 146;
  4439. // NOTE we must use Object.defineProperties instead of individual calls to
  4440. // Object.defineProperty in order to make closure compiler happy
  4441. Object.defineProperties(FS.FSNode.prototype, {
  4442. read: {
  4443. get: function() { return (this.mode & readMode) === readMode; },
  4444. set: function(val) { val ? this.mode |= readMode : this.mode &= ~readMode; }
  4445. },
  4446. write: {
  4447. get: function() { return (this.mode & writeMode) === writeMode; },
  4448. set: function(val) { val ? this.mode |= writeMode : this.mode &= ~writeMode; }
  4449. },
  4450. isFolder: {
  4451. get: function() { return FS.isDir(this.mode); }
  4452. },
  4453. isDevice: {
  4454. get: function() { return FS.isChrdev(this.mode); }
  4455. }
  4456. });
  4457. }
  4458. var node = new FS.FSNode(parent, name, mode, rdev);
  4459. FS.hashAddNode(node);
  4460. return node;
  4461. },destroyNode:function (node) {
  4462. FS.hashRemoveNode(node);
  4463. },isRoot:function (node) {
  4464. return node === node.parent;
  4465. },isMountpoint:function (node) {
  4466. return !!node.mounted;
  4467. },isFile:function (mode) {
  4468. return (mode & 61440) === 32768;
  4469. },isDir:function (mode) {
  4470. return (mode & 61440) === 16384;
  4471. },isLink:function (mode) {
  4472. return (mode & 61440) === 40960;
  4473. },isChrdev:function (mode) {
  4474. return (mode & 61440) === 8192;
  4475. },isBlkdev:function (mode) {
  4476. return (mode & 61440) === 24576;
  4477. },isFIFO:function (mode) {
  4478. return (mode & 61440) === 4096;
  4479. },isSocket:function (mode) {
  4480. return (mode & 49152) === 49152;
  4481. },flagModes:{"r":0,"rs":1052672,"r+":2,"w":577,"wx":705,"xw":705,"w+":578,"wx+":706,"xw+":706,"a":1089,"ax":1217,"xa":1217,"a+":1090,"ax+":1218,"xa+":1218},modeStringToFlags:function (str) {
  4482. var flags = FS.flagModes[str];
  4483. if (typeof flags === 'undefined') {
  4484. throw new Error('Unknown file open mode: ' + str);
  4485. }
  4486. return flags;
  4487. },flagsToPermissionString:function (flag) {
  4488. var perms = ['r', 'w', 'rw'][flag & 3];
  4489. if ((flag & 512)) {
  4490. perms += 'w';
  4491. }
  4492. return perms;
  4493. },nodePermissions:function (node, perms) {
  4494. if (FS.ignorePermissions) {
  4495. return 0;
  4496. }
  4497. // return 0 if any user, group or owner bits are set.
  4498. if (perms.indexOf('r') !== -1 && !(node.mode & 292)) {
  4499. return ERRNO_CODES.EACCES;
  4500. } else if (perms.indexOf('w') !== -1 && !(node.mode & 146)) {
  4501. return ERRNO_CODES.EACCES;
  4502. } else if (perms.indexOf('x') !== -1 && !(node.mode & 73)) {
  4503. return ERRNO_CODES.EACCES;
  4504. }
  4505. return 0;
  4506. },mayLookup:function (dir) {
  4507. var err = FS.nodePermissions(dir, 'x');
  4508. if (err) return err;
  4509. if (!dir.node_ops.lookup) return ERRNO_CODES.EACCES;
  4510. return 0;
  4511. },mayCreate:function (dir, name) {
  4512. try {
  4513. var node = FS.lookupNode(dir, name);
  4514. return ERRNO_CODES.EEXIST;
  4515. } catch (e) {
  4516. }
  4517. return FS.nodePermissions(dir, 'wx');
  4518. },mayDelete:function (dir, name, isdir) {
  4519. var node;
  4520. try {
  4521. node = FS.lookupNode(dir, name);
  4522. } catch (e) {
  4523. return e.errno;
  4524. }
  4525. var err = FS.nodePermissions(dir, 'wx');
  4526. if (err) {
  4527. return err;
  4528. }
  4529. if (isdir) {
  4530. if (!FS.isDir(node.mode)) {
  4531. return ERRNO_CODES.ENOTDIR;
  4532. }
  4533. if (FS.isRoot(node) || FS.getPath(node) === FS.cwd()) {
  4534. return ERRNO_CODES.EBUSY;
  4535. }
  4536. } else {
  4537. if (FS.isDir(node.mode)) {
  4538. return ERRNO_CODES.EISDIR;
  4539. }
  4540. }
  4541. return 0;
  4542. },mayOpen:function (node, flags) {
  4543. if (!node) {
  4544. return ERRNO_CODES.ENOENT;
  4545. }
  4546. if (FS.isLink(node.mode)) {
  4547. return ERRNO_CODES.ELOOP;
  4548. } else if (FS.isDir(node.mode)) {
  4549. if (FS.flagsToPermissionString(flags) !== 'r' || // opening for write
  4550. (flags & 512)) { // TODO: check for O_SEARCH? (== search for dir only)
  4551. return ERRNO_CODES.EISDIR;
  4552. }
  4553. }
  4554. return FS.nodePermissions(node, FS.flagsToPermissionString(flags));
  4555. },MAX_OPEN_FDS:4096,nextfd:function (fd_start, fd_end) {
  4556. fd_start = fd_start || 0;
  4557. fd_end = fd_end || FS.MAX_OPEN_FDS;
  4558. for (var fd = fd_start; fd <= fd_end; fd++) {
  4559. if (!FS.streams[fd]) {
  4560. return fd;
  4561. }
  4562. }
  4563. throw new FS.ErrnoError(ERRNO_CODES.EMFILE);
  4564. },getStream:function (fd) {
  4565. return FS.streams[fd];
  4566. },createStream:function (stream, fd_start, fd_end) {
  4567. if (!FS.FSStream) {
  4568. FS.FSStream = function(){};
  4569. FS.FSStream.prototype = {};
  4570. // compatibility
  4571. Object.defineProperties(FS.FSStream.prototype, {
  4572. object: {
  4573. get: function() { return this.node; },
  4574. set: function(val) { this.node = val; }
  4575. },
  4576. isRead: {
  4577. get: function() { return (this.flags & 2097155) !== 1; }
  4578. },
  4579. isWrite: {
  4580. get: function() { return (this.flags & 2097155) !== 0; }
  4581. },
  4582. isAppend: {
  4583. get: function() { return (this.flags & 1024); }
  4584. }
  4585. });
  4586. }
  4587. // clone it, so we can return an instance of FSStream
  4588. var newStream = new FS.FSStream();
  4589. for (var p in stream) {
  4590. newStream[p] = stream[p];
  4591. }
  4592. stream = newStream;
  4593. var fd = FS.nextfd(fd_start, fd_end);
  4594. stream.fd = fd;
  4595. FS.streams[fd] = stream;
  4596. return stream;
  4597. },closeStream:function (fd) {
  4598. FS.streams[fd] = null;
  4599. },chrdev_stream_ops:{open:function (stream) {
  4600. var device = FS.getDevice(stream.node.rdev);
  4601. // override node's stream ops with the device's
  4602. stream.stream_ops = device.stream_ops;
  4603. // forward the open call
  4604. if (stream.stream_ops.open) {
  4605. stream.stream_ops.open(stream);
  4606. }
  4607. },llseek:function () {
  4608. throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
  4609. }},major:function (dev) {
  4610. return ((dev) >> 8);
  4611. },minor:function (dev) {
  4612. return ((dev) & 0xff);
  4613. },makedev:function (ma, mi) {
  4614. return ((ma) << 8 | (mi));
  4615. },registerDevice:function (dev, ops) {
  4616. FS.devices[dev] = { stream_ops: ops };
  4617. },getDevice:function (dev) {
  4618. return FS.devices[dev];
  4619. },getMounts:function (mount) {
  4620. var mounts = [];
  4621. var check = [mount];
  4622. while (check.length) {
  4623. var m = check.pop();
  4624. mounts.push(m);
  4625. check.push.apply(check, m.mounts);
  4626. }
  4627. return mounts;
  4628. },syncfs:function (populate, callback) {
  4629. if (typeof(populate) === 'function') {
  4630. callback = populate;
  4631. populate = false;
  4632. }
  4633. FS.syncFSRequests++;
  4634. if (FS.syncFSRequests > 1) {
  4635. console.log('warning: ' + FS.syncFSRequests + ' FS.syncfs operations in flight at once, probably just doing extra work');
  4636. }
  4637. var mounts = FS.getMounts(FS.root.mount);
  4638. var completed = 0;
  4639. function doCallback(err) {
  4640. assert(FS.syncFSRequests > 0);
  4641. FS.syncFSRequests--;
  4642. return callback(err);
  4643. }
  4644. function done(err) {
  4645. if (err) {
  4646. if (!done.errored) {
  4647. done.errored = true;
  4648. return doCallback(err);
  4649. }
  4650. return;
  4651. }
  4652. if (++completed >= mounts.length) {
  4653. doCallback(null);
  4654. }
  4655. };
  4656. // sync all mounts
  4657. mounts.forEach(function (mount) {
  4658. if (!mount.type.syncfs) {
  4659. return done(null);
  4660. }
  4661. mount.type.syncfs(mount, populate, done);
  4662. });
  4663. },mount:function (type, opts, mountpoint) {
  4664. var root = mountpoint === '/';
  4665. var pseudo = !mountpoint;
  4666. var node;
  4667. if (root && FS.root) {
  4668. throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
  4669. } else if (!root && !pseudo) {
  4670. var lookup = FS.lookupPath(mountpoint, { follow_mount: false });
  4671. mountpoint = lookup.path; // use the absolute path
  4672. node = lookup.node;
  4673. if (FS.isMountpoint(node)) {
  4674. throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
  4675. }
  4676. if (!FS.isDir(node.mode)) {
  4677. throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
  4678. }
  4679. }
  4680. var mount = {
  4681. type: type,
  4682. opts: opts,
  4683. mountpoint: mountpoint,
  4684. mounts: []
  4685. };
  4686. // create a root node for the fs
  4687. var mountRoot = type.mount(mount);
  4688. mountRoot.mount = mount;
  4689. mount.root = mountRoot;
  4690. if (root) {
  4691. FS.root = mountRoot;
  4692. } else if (node) {
  4693. // set as a mountpoint
  4694. node.mounted = mount;
  4695. // add the new mount to the current mount's children
  4696. if (node.mount) {
  4697. node.mount.mounts.push(mount);
  4698. }
  4699. }
  4700. return mountRoot;
  4701. },unmount:function (mountpoint) {
  4702. var lookup = FS.lookupPath(mountpoint, { follow_mount: false });
  4703. if (!FS.isMountpoint(lookup.node)) {
  4704. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  4705. }
  4706. // destroy the nodes for this mount, and all its child mounts
  4707. var node = lookup.node;
  4708. var mount = node.mounted;
  4709. var mounts = FS.getMounts(mount);
  4710. Object.keys(FS.nameTable).forEach(function (hash) {
  4711. var current = FS.nameTable[hash];
  4712. while (current) {
  4713. var next = current.name_next;
  4714. if (mounts.indexOf(current.mount) !== -1) {
  4715. FS.destroyNode(current);
  4716. }
  4717. current = next;
  4718. }
  4719. });
  4720. // no longer a mountpoint
  4721. node.mounted = null;
  4722. // remove this mount from the child mounts
  4723. var idx = node.mount.mounts.indexOf(mount);
  4724. assert(idx !== -1);
  4725. node.mount.mounts.splice(idx, 1);
  4726. },lookup:function (parent, name) {
  4727. return parent.node_ops.lookup(parent, name);
  4728. },mknod:function (path, mode, dev) {
  4729. var lookup = FS.lookupPath(path, { parent: true });
  4730. var parent = lookup.node;
  4731. var name = PATH.basename(path);
  4732. if (!name || name === '.' || name === '..') {
  4733. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  4734. }
  4735. var err = FS.mayCreate(parent, name);
  4736. if (err) {
  4737. throw new FS.ErrnoError(err);
  4738. }
  4739. if (!parent.node_ops.mknod) {
  4740. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4741. }
  4742. return parent.node_ops.mknod(parent, name, mode, dev);
  4743. },create:function (path, mode) {
  4744. mode = mode !== undefined ? mode : 438 /* 0666 */;
  4745. mode &= 4095;
  4746. mode |= 32768;
  4747. return FS.mknod(path, mode, 0);
  4748. },mkdir:function (path, mode) {
  4749. mode = mode !== undefined ? mode : 511 /* 0777 */;
  4750. mode &= 511 | 512;
  4751. mode |= 16384;
  4752. return FS.mknod(path, mode, 0);
  4753. },mkdirTree:function (path, mode) {
  4754. var dirs = path.split('/');
  4755. var d = '';
  4756. for (var i = 0; i < dirs.length; ++i) {
  4757. if (!dirs[i]) continue;
  4758. d += '/' + dirs[i];
  4759. try {
  4760. FS.mkdir(d, mode);
  4761. } catch(e) {
  4762. if (e.errno != ERRNO_CODES.EEXIST) throw e;
  4763. }
  4764. }
  4765. },mkdev:function (path, mode, dev) {
  4766. if (typeof(dev) === 'undefined') {
  4767. dev = mode;
  4768. mode = 438 /* 0666 */;
  4769. }
  4770. mode |= 8192;
  4771. return FS.mknod(path, mode, dev);
  4772. },symlink:function (oldpath, newpath) {
  4773. if (!PATH.resolve(oldpath)) {
  4774. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  4775. }
  4776. var lookup = FS.lookupPath(newpath, { parent: true });
  4777. var parent = lookup.node;
  4778. if (!parent) {
  4779. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  4780. }
  4781. var newname = PATH.basename(newpath);
  4782. var err = FS.mayCreate(parent, newname);
  4783. if (err) {
  4784. throw new FS.ErrnoError(err);
  4785. }
  4786. if (!parent.node_ops.symlink) {
  4787. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4788. }
  4789. return parent.node_ops.symlink(parent, newname, oldpath);
  4790. },rename:function (old_path, new_path) {
  4791. var old_dirname = PATH.dirname(old_path);
  4792. var new_dirname = PATH.dirname(new_path);
  4793. var old_name = PATH.basename(old_path);
  4794. var new_name = PATH.basename(new_path);
  4795. // parents must exist
  4796. var lookup, old_dir, new_dir;
  4797. try {
  4798. lookup = FS.lookupPath(old_path, { parent: true });
  4799. old_dir = lookup.node;
  4800. lookup = FS.lookupPath(new_path, { parent: true });
  4801. new_dir = lookup.node;
  4802. } catch (e) {
  4803. throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
  4804. }
  4805. if (!old_dir || !new_dir) throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  4806. // need to be part of the same mount
  4807. if (old_dir.mount !== new_dir.mount) {
  4808. throw new FS.ErrnoError(ERRNO_CODES.EXDEV);
  4809. }
  4810. // source must exist
  4811. var old_node = FS.lookupNode(old_dir, old_name);
  4812. // old path should not be an ancestor of the new path
  4813. var relative = PATH.relative(old_path, new_dirname);
  4814. if (relative.charAt(0) !== '.') {
  4815. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  4816. }
  4817. // new path should not be an ancestor of the old path
  4818. relative = PATH.relative(new_path, old_dirname);
  4819. if (relative.charAt(0) !== '.') {
  4820. throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
  4821. }
  4822. // see if the new path already exists
  4823. var new_node;
  4824. try {
  4825. new_node = FS.lookupNode(new_dir, new_name);
  4826. } catch (e) {
  4827. // not fatal
  4828. }
  4829. // early out if nothing needs to change
  4830. if (old_node === new_node) {
  4831. return;
  4832. }
  4833. // we'll need to delete the old entry
  4834. var isdir = FS.isDir(old_node.mode);
  4835. var err = FS.mayDelete(old_dir, old_name, isdir);
  4836. if (err) {
  4837. throw new FS.ErrnoError(err);
  4838. }
  4839. // need delete permissions if we'll be overwriting.
  4840. // need create permissions if new doesn't already exist.
  4841. err = new_node ?
  4842. FS.mayDelete(new_dir, new_name, isdir) :
  4843. FS.mayCreate(new_dir, new_name);
  4844. if (err) {
  4845. throw new FS.ErrnoError(err);
  4846. }
  4847. if (!old_dir.node_ops.rename) {
  4848. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4849. }
  4850. if (FS.isMountpoint(old_node) || (new_node && FS.isMountpoint(new_node))) {
  4851. throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
  4852. }
  4853. // if we are going to change the parent, check write permissions
  4854. if (new_dir !== old_dir) {
  4855. err = FS.nodePermissions(old_dir, 'w');
  4856. if (err) {
  4857. throw new FS.ErrnoError(err);
  4858. }
  4859. }
  4860. try {
  4861. if (FS.trackingDelegate['willMovePath']) {
  4862. FS.trackingDelegate['willMovePath'](old_path, new_path);
  4863. }
  4864. } catch(e) {
  4865. console.log("FS.trackingDelegate['willMovePath']('"+old_path+"', '"+new_path+"') threw an exception: " + e.message);
  4866. }
  4867. // remove the node from the lookup hash
  4868. FS.hashRemoveNode(old_node);
  4869. // do the underlying fs rename
  4870. try {
  4871. old_dir.node_ops.rename(old_node, new_dir, new_name);
  4872. } catch (e) {
  4873. throw e;
  4874. } finally {
  4875. // add the node back to the hash (in case node_ops.rename
  4876. // changed its name)
  4877. FS.hashAddNode(old_node);
  4878. }
  4879. try {
  4880. if (FS.trackingDelegate['onMovePath']) FS.trackingDelegate['onMovePath'](old_path, new_path);
  4881. } catch(e) {
  4882. console.log("FS.trackingDelegate['onMovePath']('"+old_path+"', '"+new_path+"') threw an exception: " + e.message);
  4883. }
  4884. },rmdir:function (path) {
  4885. var lookup = FS.lookupPath(path, { parent: true });
  4886. var parent = lookup.node;
  4887. var name = PATH.basename(path);
  4888. var node = FS.lookupNode(parent, name);
  4889. var err = FS.mayDelete(parent, name, true);
  4890. if (err) {
  4891. throw new FS.ErrnoError(err);
  4892. }
  4893. if (!parent.node_ops.rmdir) {
  4894. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4895. }
  4896. if (FS.isMountpoint(node)) {
  4897. throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
  4898. }
  4899. try {
  4900. if (FS.trackingDelegate['willDeletePath']) {
  4901. FS.trackingDelegate['willDeletePath'](path);
  4902. }
  4903. } catch(e) {
  4904. console.log("FS.trackingDelegate['willDeletePath']('"+path+"') threw an exception: " + e.message);
  4905. }
  4906. parent.node_ops.rmdir(parent, name);
  4907. FS.destroyNode(node);
  4908. try {
  4909. if (FS.trackingDelegate['onDeletePath']) FS.trackingDelegate['onDeletePath'](path);
  4910. } catch(e) {
  4911. console.log("FS.trackingDelegate['onDeletePath']('"+path+"') threw an exception: " + e.message);
  4912. }
  4913. },readdir:function (path) {
  4914. var lookup = FS.lookupPath(path, { follow: true });
  4915. var node = lookup.node;
  4916. if (!node.node_ops.readdir) {
  4917. throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
  4918. }
  4919. return node.node_ops.readdir(node);
  4920. },unlink:function (path) {
  4921. var lookup = FS.lookupPath(path, { parent: true });
  4922. var parent = lookup.node;
  4923. var name = PATH.basename(path);
  4924. var node = FS.lookupNode(parent, name);
  4925. var err = FS.mayDelete(parent, name, false);
  4926. if (err) {
  4927. // According to POSIX, we should map EISDIR to EPERM, but
  4928. // we instead do what Linux does (and we must, as we use
  4929. // the musl linux libc).
  4930. throw new FS.ErrnoError(err);
  4931. }
  4932. if (!parent.node_ops.unlink) {
  4933. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4934. }
  4935. if (FS.isMountpoint(node)) {
  4936. throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
  4937. }
  4938. try {
  4939. if (FS.trackingDelegate['willDeletePath']) {
  4940. FS.trackingDelegate['willDeletePath'](path);
  4941. }
  4942. } catch(e) {
  4943. console.log("FS.trackingDelegate['willDeletePath']('"+path+"') threw an exception: " + e.message);
  4944. }
  4945. parent.node_ops.unlink(parent, name);
  4946. FS.destroyNode(node);
  4947. try {
  4948. if (FS.trackingDelegate['onDeletePath']) FS.trackingDelegate['onDeletePath'](path);
  4949. } catch(e) {
  4950. console.log("FS.trackingDelegate['onDeletePath']('"+path+"') threw an exception: " + e.message);
  4951. }
  4952. },readlink:function (path) {
  4953. var lookup = FS.lookupPath(path);
  4954. var link = lookup.node;
  4955. if (!link) {
  4956. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  4957. }
  4958. if (!link.node_ops.readlink) {
  4959. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  4960. }
  4961. return PATH.resolve(FS.getPath(link.parent), link.node_ops.readlink(link));
  4962. },stat:function (path, dontFollow) {
  4963. var lookup = FS.lookupPath(path, { follow: !dontFollow });
  4964. var node = lookup.node;
  4965. if (!node) {
  4966. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  4967. }
  4968. if (!node.node_ops.getattr) {
  4969. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4970. }
  4971. return node.node_ops.getattr(node);
  4972. },lstat:function (path) {
  4973. return FS.stat(path, true);
  4974. },chmod:function (path, mode, dontFollow) {
  4975. var node;
  4976. if (typeof path === 'string') {
  4977. var lookup = FS.lookupPath(path, { follow: !dontFollow });
  4978. node = lookup.node;
  4979. } else {
  4980. node = path;
  4981. }
  4982. if (!node.node_ops.setattr) {
  4983. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  4984. }
  4985. node.node_ops.setattr(node, {
  4986. mode: (mode & 4095) | (node.mode & ~4095),
  4987. timestamp: Date.now()
  4988. });
  4989. },lchmod:function (path, mode) {
  4990. FS.chmod(path, mode, true);
  4991. },fchmod:function (fd, mode) {
  4992. var stream = FS.getStream(fd);
  4993. if (!stream) {
  4994. throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  4995. }
  4996. FS.chmod(stream.node, mode);
  4997. },chown:function (path, uid, gid, dontFollow) {
  4998. var node;
  4999. if (typeof path === 'string') {
  5000. var lookup = FS.lookupPath(path, { follow: !dontFollow });
  5001. node = lookup.node;
  5002. } else {
  5003. node = path;
  5004. }
  5005. if (!node.node_ops.setattr) {
  5006. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  5007. }
  5008. node.node_ops.setattr(node, {
  5009. timestamp: Date.now()
  5010. // we ignore the uid / gid for now
  5011. });
  5012. },lchown:function (path, uid, gid) {
  5013. FS.chown(path, uid, gid, true);
  5014. },fchown:function (fd, uid, gid) {
  5015. var stream = FS.getStream(fd);
  5016. if (!stream) {
  5017. throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  5018. }
  5019. FS.chown(stream.node, uid, gid);
  5020. },truncate:function (path, len) {
  5021. if (len < 0) {
  5022. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5023. }
  5024. var node;
  5025. if (typeof path === 'string') {
  5026. var lookup = FS.lookupPath(path, { follow: true });
  5027. node = lookup.node;
  5028. } else {
  5029. node = path;
  5030. }
  5031. if (!node.node_ops.setattr) {
  5032. throw new FS.ErrnoError(ERRNO_CODES.EPERM);
  5033. }
  5034. if (FS.isDir(node.mode)) {
  5035. throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
  5036. }
  5037. if (!FS.isFile(node.mode)) {
  5038. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5039. }
  5040. var err = FS.nodePermissions(node, 'w');
  5041. if (err) {
  5042. throw new FS.ErrnoError(err);
  5043. }
  5044. node.node_ops.setattr(node, {
  5045. size: len,
  5046. timestamp: Date.now()
  5047. });
  5048. },ftruncate:function (fd, len) {
  5049. var stream = FS.getStream(fd);
  5050. if (!stream) {
  5051. throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  5052. }
  5053. if ((stream.flags & 2097155) === 0) {
  5054. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5055. }
  5056. FS.truncate(stream.node, len);
  5057. },utime:function (path, atime, mtime) {
  5058. var lookup = FS.lookupPath(path, { follow: true });
  5059. var node = lookup.node;
  5060. node.node_ops.setattr(node, {
  5061. timestamp: Math.max(atime, mtime)
  5062. });
  5063. },open:function (path, flags, mode, fd_start, fd_end) {
  5064. if (path === "") {
  5065. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  5066. }
  5067. flags = typeof flags === 'string' ? FS.modeStringToFlags(flags) : flags;
  5068. mode = typeof mode === 'undefined' ? 438 /* 0666 */ : mode;
  5069. if ((flags & 64)) {
  5070. mode = (mode & 4095) | 32768;
  5071. } else {
  5072. mode = 0;
  5073. }
  5074. var node;
  5075. if (typeof path === 'object') {
  5076. node = path;
  5077. } else {
  5078. path = PATH.normalize(path);
  5079. try {
  5080. var lookup = FS.lookupPath(path, {
  5081. follow: !(flags & 131072)
  5082. });
  5083. node = lookup.node;
  5084. } catch (e) {
  5085. // ignore
  5086. }
  5087. }
  5088. // perhaps we need to create the node
  5089. var created = false;
  5090. if ((flags & 64)) {
  5091. if (node) {
  5092. // if O_CREAT and O_EXCL are set, error out if the node already exists
  5093. if ((flags & 128)) {
  5094. throw new FS.ErrnoError(ERRNO_CODES.EEXIST);
  5095. }
  5096. } else {
  5097. // node doesn't exist, try to create it
  5098. node = FS.mknod(path, mode, 0);
  5099. created = true;
  5100. }
  5101. }
  5102. if (!node) {
  5103. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  5104. }
  5105. // can't truncate a device
  5106. if (FS.isChrdev(node.mode)) {
  5107. flags &= ~512;
  5108. }
  5109. // if asked only for a directory, then this must be one
  5110. if ((flags & 65536) && !FS.isDir(node.mode)) {
  5111. throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
  5112. }
  5113. // check permissions, if this is not a file we just created now (it is ok to
  5114. // create and write to a file with read-only permissions; it is read-only
  5115. // for later use)
  5116. if (!created) {
  5117. var err = FS.mayOpen(node, flags);
  5118. if (err) {
  5119. throw new FS.ErrnoError(err);
  5120. }
  5121. }
  5122. // do truncation if necessary
  5123. if ((flags & 512)) {
  5124. FS.truncate(node, 0);
  5125. }
  5126. // we've already handled these, don't pass down to the underlying vfs
  5127. flags &= ~(128 | 512);
  5128. // register the stream with the filesystem
  5129. var stream = FS.createStream({
  5130. node: node,
  5131. path: FS.getPath(node), // we want the absolute path to the node
  5132. flags: flags,
  5133. seekable: true,
  5134. position: 0,
  5135. stream_ops: node.stream_ops,
  5136. // used by the file family libc calls (fopen, fwrite, ferror, etc.)
  5137. ungotten: [],
  5138. error: false
  5139. }, fd_start, fd_end);
  5140. // call the new stream's open function
  5141. if (stream.stream_ops.open) {
  5142. stream.stream_ops.open(stream);
  5143. }
  5144. if (Module['logReadFiles'] && !(flags & 1)) {
  5145. if (!FS.readFiles) FS.readFiles = {};
  5146. if (!(path in FS.readFiles)) {
  5147. FS.readFiles[path] = 1;
  5148. Module['printErr']('read file: ' + path);
  5149. }
  5150. }
  5151. try {
  5152. if (FS.trackingDelegate['onOpenFile']) {
  5153. var trackingFlags = 0;
  5154. if ((flags & 2097155) !== 1) {
  5155. trackingFlags |= FS.tracking.openFlags.READ;
  5156. }
  5157. if ((flags & 2097155) !== 0) {
  5158. trackingFlags |= FS.tracking.openFlags.WRITE;
  5159. }
  5160. FS.trackingDelegate['onOpenFile'](path, trackingFlags);
  5161. }
  5162. } catch(e) {
  5163. console.log("FS.trackingDelegate['onOpenFile']('"+path+"', flags) threw an exception: " + e.message);
  5164. }
  5165. return stream;
  5166. },close:function (stream) {
  5167. if (stream.getdents) stream.getdents = null; // free readdir state
  5168. try {
  5169. if (stream.stream_ops.close) {
  5170. stream.stream_ops.close(stream);
  5171. }
  5172. } catch (e) {
  5173. throw e;
  5174. } finally {
  5175. FS.closeStream(stream.fd);
  5176. }
  5177. },llseek:function (stream, offset, whence) {
  5178. if (!stream.seekable || !stream.stream_ops.llseek) {
  5179. throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
  5180. }
  5181. stream.position = stream.stream_ops.llseek(stream, offset, whence);
  5182. stream.ungotten = [];
  5183. return stream.position;
  5184. },read:function (stream, buffer, offset, length, position) {
  5185. if (length < 0 || position < 0) {
  5186. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5187. }
  5188. if ((stream.flags & 2097155) === 1) {
  5189. throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  5190. }
  5191. if (FS.isDir(stream.node.mode)) {
  5192. throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
  5193. }
  5194. if (!stream.stream_ops.read) {
  5195. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5196. }
  5197. var seeking = true;
  5198. if (typeof position === 'undefined') {
  5199. position = stream.position;
  5200. seeking = false;
  5201. } else if (!stream.seekable) {
  5202. throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
  5203. }
  5204. var bytesRead = stream.stream_ops.read(stream, buffer, offset, length, position);
  5205. if (!seeking) stream.position += bytesRead;
  5206. return bytesRead;
  5207. },write:function (stream, buffer, offset, length, position, canOwn) {
  5208. if (length < 0 || position < 0) {
  5209. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5210. }
  5211. if ((stream.flags & 2097155) === 0) {
  5212. throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  5213. }
  5214. if (FS.isDir(stream.node.mode)) {
  5215. throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
  5216. }
  5217. if (!stream.stream_ops.write) {
  5218. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5219. }
  5220. if (stream.flags & 1024) {
  5221. // seek to the end before writing in append mode
  5222. FS.llseek(stream, 0, 2);
  5223. }
  5224. var seeking = true;
  5225. if (typeof position === 'undefined') {
  5226. position = stream.position;
  5227. seeking = false;
  5228. } else if (!stream.seekable) {
  5229. throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
  5230. }
  5231. var bytesWritten = stream.stream_ops.write(stream, buffer, offset, length, position, canOwn);
  5232. if (!seeking) stream.position += bytesWritten;
  5233. try {
  5234. if (stream.path && FS.trackingDelegate['onWriteToFile']) FS.trackingDelegate['onWriteToFile'](stream.path);
  5235. } catch(e) {
  5236. console.log("FS.trackingDelegate['onWriteToFile']('"+path+"') threw an exception: " + e.message);
  5237. }
  5238. return bytesWritten;
  5239. },allocate:function (stream, offset, length) {
  5240. if (offset < 0 || length <= 0) {
  5241. throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
  5242. }
  5243. if ((stream.flags & 2097155) === 0) {
  5244. throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  5245. }
  5246. if (!FS.isFile(stream.node.mode) && !FS.isDir(node.mode)) {
  5247. throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
  5248. }
  5249. if (!stream.stream_ops.allocate) {
  5250. throw new FS.ErrnoError(ERRNO_CODES.EOPNOTSUPP);
  5251. }
  5252. stream.stream_ops.allocate(stream, offset, length);
  5253. },mmap:function (stream, buffer, offset, length, position, prot, flags) {
  5254. // TODO if PROT is PROT_WRITE, make sure we have write access
  5255. if ((stream.flags & 2097155) === 1) {
  5256. throw new FS.ErrnoError(ERRNO_CODES.EACCES);
  5257. }
  5258. if (!stream.stream_ops.mmap) {
  5259. throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
  5260. }
  5261. return stream.stream_ops.mmap(stream, buffer, offset, length, position, prot, flags);
  5262. },msync:function (stream, buffer, offset, length, mmapFlags) {
  5263. if (!stream || !stream.stream_ops.msync) {
  5264. return 0;
  5265. }
  5266. return stream.stream_ops.msync(stream, buffer, offset, length, mmapFlags);
  5267. },munmap:function (stream) {
  5268. return 0;
  5269. },ioctl:function (stream, cmd, arg) {
  5270. if (!stream.stream_ops.ioctl) {
  5271. throw new FS.ErrnoError(ERRNO_CODES.ENOTTY);
  5272. }
  5273. return stream.stream_ops.ioctl(stream, cmd, arg);
  5274. },readFile:function (path, opts) {
  5275. opts = opts || {};
  5276. opts.flags = opts.flags || 'r';
  5277. opts.encoding = opts.encoding || 'binary';
  5278. if (opts.encoding !== 'utf8' && opts.encoding !== 'binary') {
  5279. throw new Error('Invalid encoding type "' + opts.encoding + '"');
  5280. }
  5281. var ret;
  5282. var stream = FS.open(path, opts.flags);
  5283. var stat = FS.stat(path);
  5284. var length = stat.size;
  5285. var buf = new Uint8Array(length);
  5286. FS.read(stream, buf, 0, length, 0);
  5287. if (opts.encoding === 'utf8') {
  5288. ret = UTF8ArrayToString(buf, 0);
  5289. } else if (opts.encoding === 'binary') {
  5290. ret = buf;
  5291. }
  5292. FS.close(stream);
  5293. return ret;
  5294. },writeFile:function (path, data, opts) {
  5295. opts = opts || {};
  5296. opts.flags = opts.flags || 'w';
  5297. opts.encoding = opts.encoding || 'utf8';
  5298. if (opts.encoding !== 'utf8' && opts.encoding !== 'binary') {
  5299. throw new Error('Invalid encoding type "' + opts.encoding + '"');
  5300. }
  5301. var stream = FS.open(path, opts.flags, opts.mode);
  5302. if (opts.encoding === 'utf8') {
  5303. var buf = new Uint8Array(lengthBytesUTF8(data)+1);
  5304. var actualNumBytes = stringToUTF8Array(data, buf, 0, buf.length);
  5305. FS.write(stream, buf, 0, actualNumBytes, 0, opts.canOwn);
  5306. } else if (opts.encoding === 'binary') {
  5307. FS.write(stream, data, 0, data.length, 0, opts.canOwn);
  5308. }
  5309. FS.close(stream);
  5310. },cwd:function () {
  5311. return FS.currentPath;
  5312. },chdir:function (path) {
  5313. var lookup = FS.lookupPath(path, { follow: true });
  5314. if (lookup.node === null) {
  5315. throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
  5316. }
  5317. if (!FS.isDir(lookup.node.mode)) {
  5318. throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
  5319. }
  5320. var err = FS.nodePermissions(lookup.node, 'x');
  5321. if (err) {
  5322. throw new FS.ErrnoError(err);
  5323. }
  5324. FS.currentPath = lookup.path;
  5325. },createDefaultDirectories:function () {
  5326. FS.mkdir('/tmp');
  5327. FS.mkdir('/home');
  5328. FS.mkdir('/home/web_user');
  5329. },createDefaultDevices:function () {
  5330. // create /dev
  5331. FS.mkdir('/dev');
  5332. // setup /dev/null
  5333. FS.registerDevice(FS.makedev(1, 3), {
  5334. read: function() { return 0; },
  5335. write: function(stream, buffer, offset, length, pos) { return length; }
  5336. });
  5337. FS.mkdev('/dev/null', FS.makedev(1, 3));
  5338. // setup /dev/tty and /dev/tty1
  5339. // stderr needs to print output using Module['printErr']
  5340. // so we register a second tty just for it.
  5341. TTY.register(FS.makedev(5, 0), TTY.default_tty_ops);
  5342. TTY.register(FS.makedev(6, 0), TTY.default_tty1_ops);
  5343. FS.mkdev('/dev/tty', FS.makedev(5, 0));
  5344. FS.mkdev('/dev/tty1', FS.makedev(6, 0));
  5345. // setup /dev/[u]random
  5346. var random_device;
  5347. if (typeof crypto !== 'undefined') {
  5348. // for modern web browsers
  5349. var randomBuffer = new Uint8Array(1);
  5350. random_device = function() { crypto.getRandomValues(randomBuffer); return randomBuffer[0]; };
  5351. } else if (ENVIRONMENT_IS_NODE) {
  5352. // for nodejs
  5353. random_device = function() { return require('crypto').randomBytes(1)[0]; };
  5354. } else {
  5355. // default for ES5 platforms
  5356. random_device = function() { return (Math.random()*256)|0; };
  5357. }
  5358. FS.createDevice('/dev', 'random', random_device);
  5359. FS.createDevice('/dev', 'urandom', random_device);
  5360. // we're not going to emulate the actual shm device,
  5361. // just create the tmp dirs that reside in it commonly
  5362. FS.mkdir('/dev/shm');
  5363. FS.mkdir('/dev/shm/tmp');
  5364. },createSpecialDirectories:function () {
  5365. // create /proc/self/fd which allows /proc/self/fd/6 => readlink gives the name of the stream for fd 6 (see test_unistd_ttyname)
  5366. FS.mkdir('/proc');
  5367. FS.mkdir('/proc/self');
  5368. FS.mkdir('/proc/self/fd');
  5369. FS.mount({
  5370. mount: function() {
  5371. var node = FS.createNode('/proc/self', 'fd', 16384 | 511 /* 0777 */, 73);
  5372. node.node_ops = {
  5373. lookup: function(parent, name) {
  5374. var fd = +name;
  5375. var stream = FS.getStream(fd);
  5376. if (!stream) throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  5377. var ret = {
  5378. parent: null,
  5379. mount: { mountpoint: 'fake' },
  5380. node_ops: { readlink: function() { return stream.path } }
  5381. };
  5382. ret.parent = ret; // make it look like a simple root node
  5383. return ret;
  5384. }
  5385. };
  5386. return node;
  5387. }
  5388. }, {}, '/proc/self/fd');
  5389. },createStandardStreams:function () {
  5390. // TODO deprecate the old functionality of a single
  5391. // input / output callback and that utilizes FS.createDevice
  5392. // and instead require a unique set of stream ops
  5393. // by default, we symlink the standard streams to the
  5394. // default tty devices. however, if the standard streams
  5395. // have been overwritten we create a unique device for
  5396. // them instead.
  5397. if (Module['stdin']) {
  5398. FS.createDevice('/dev', 'stdin', Module['stdin']);
  5399. } else {
  5400. FS.symlink('/dev/tty', '/dev/stdin');
  5401. }
  5402. if (Module['stdout']) {
  5403. FS.createDevice('/dev', 'stdout', null, Module['stdout']);
  5404. } else {
  5405. FS.symlink('/dev/tty', '/dev/stdout');
  5406. }
  5407. if (Module['stderr']) {
  5408. FS.createDevice('/dev', 'stderr', null, Module['stderr']);
  5409. } else {
  5410. FS.symlink('/dev/tty1', '/dev/stderr');
  5411. }
  5412. // open default streams for the stdin, stdout and stderr devices
  5413. var stdin = FS.open('/dev/stdin', 'r');
  5414. assert(stdin.fd === 0, 'invalid handle for stdin (' + stdin.fd + ')');
  5415. var stdout = FS.open('/dev/stdout', 'w');
  5416. assert(stdout.fd === 1, 'invalid handle for stdout (' + stdout.fd + ')');
  5417. var stderr = FS.open('/dev/stderr', 'w');
  5418. assert(stderr.fd === 2, 'invalid handle for stderr (' + stderr.fd + ')');
  5419. },ensureErrnoError:function () {
  5420. if (FS.ErrnoError) return;
  5421. FS.ErrnoError = function ErrnoError(errno, node) {
  5422. //Module.printErr(stackTrace()); // useful for debugging
  5423. this.node = node;
  5424. this.setErrno = function(errno) {
  5425. this.errno = errno;
  5426. for (var key in ERRNO_CODES) {
  5427. if (ERRNO_CODES[key] === errno) {
  5428. this.code = key;
  5429. break;
  5430. }
  5431. }
  5432. };
  5433. this.setErrno(errno);
  5434. this.message = ERRNO_MESSAGES[errno];
  5435. if (this.stack) this.stack = demangleAll(this.stack);
  5436. };
  5437. FS.ErrnoError.prototype = new Error();
  5438. FS.ErrnoError.prototype.constructor = FS.ErrnoError;
  5439. // Some errors may happen quite a bit, to avoid overhead we reuse them (and suffer a lack of stack info)
  5440. [ERRNO_CODES.ENOENT].forEach(function(code) {
  5441. FS.genericErrors[code] = new FS.ErrnoError(code);
  5442. FS.genericErrors[code].stack = '<generic error, no stack>';
  5443. });
  5444. },staticInit:function () {
  5445. FS.ensureErrnoError();
  5446. FS.nameTable = new Array(4096);
  5447. FS.mount(MEMFS, {}, '/');
  5448. FS.createDefaultDirectories();
  5449. FS.createDefaultDevices();
  5450. FS.createSpecialDirectories();
  5451. FS.filesystems = {
  5452. 'MEMFS': MEMFS,
  5453. 'IDBFS': IDBFS,
  5454. 'NODEFS': NODEFS,
  5455. 'WORKERFS': WORKERFS,
  5456. };
  5457. },init:function (input, output, error) {
  5458. assert(!FS.init.initialized, 'FS.init was previously called. If you want to initialize later with custom parameters, remove any earlier calls (note that one is automatically added to the generated code)');
  5459. FS.init.initialized = true;
  5460. FS.ensureErrnoError();
  5461. // Allow Module.stdin etc. to provide defaults, if none explicitly passed to us here
  5462. Module['stdin'] = input || Module['stdin'];
  5463. Module['stdout'] = output || Module['stdout'];
  5464. Module['stderr'] = error || Module['stderr'];
  5465. FS.createStandardStreams();
  5466. },quit:function () {
  5467. FS.init.initialized = false;
  5468. // force-flush all streams, so we get musl std streams printed out
  5469. var fflush = Module['_fflush'];
  5470. if (fflush) fflush(0);
  5471. // close all of our streams
  5472. for (var i = 0; i < FS.streams.length; i++) {
  5473. var stream = FS.streams[i];
  5474. if (!stream) {
  5475. continue;
  5476. }
  5477. FS.close(stream);
  5478. }
  5479. },getMode:function (canRead, canWrite) {
  5480. var mode = 0;
  5481. if (canRead) mode |= 292 | 73;
  5482. if (canWrite) mode |= 146;
  5483. return mode;
  5484. },joinPath:function (parts, forceRelative) {
  5485. var path = PATH.join.apply(null, parts);
  5486. if (forceRelative && path[0] == '/') path = path.substr(1);
  5487. return path;
  5488. },absolutePath:function (relative, base) {
  5489. return PATH.resolve(base, relative);
  5490. },standardizePath:function (path) {
  5491. return PATH.normalize(path);
  5492. },findObject:function (path, dontResolveLastLink) {
  5493. var ret = FS.analyzePath(path, dontResolveLastLink);
  5494. if (ret.exists) {
  5495. return ret.object;
  5496. } else {
  5497. ___setErrNo(ret.error);
  5498. return null;
  5499. }
  5500. },analyzePath:function (path, dontResolveLastLink) {
  5501. // operate from within the context of the symlink's target
  5502. try {
  5503. var lookup = FS.lookupPath(path, { follow: !dontResolveLastLink });
  5504. path = lookup.path;
  5505. } catch (e) {
  5506. }
  5507. var ret = {
  5508. isRoot: false, exists: false, error: 0, name: null, path: null, object: null,
  5509. parentExists: false, parentPath: null, parentObject: null
  5510. };
  5511. try {
  5512. var lookup = FS.lookupPath(path, { parent: true });
  5513. ret.parentExists = true;
  5514. ret.parentPath = lookup.path;
  5515. ret.parentObject = lookup.node;
  5516. ret.name = PATH.basename(path);
  5517. lookup = FS.lookupPath(path, { follow: !dontResolveLastLink });
  5518. ret.exists = true;
  5519. ret.path = lookup.path;
  5520. ret.object = lookup.node;
  5521. ret.name = lookup.node.name;
  5522. ret.isRoot = lookup.path === '/';
  5523. } catch (e) {
  5524. ret.error = e.errno;
  5525. };
  5526. return ret;
  5527. },createFolder:function (parent, name, canRead, canWrite) {
  5528. var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
  5529. var mode = FS.getMode(canRead, canWrite);
  5530. return FS.mkdir(path, mode);
  5531. },createPath:function (parent, path, canRead, canWrite) {
  5532. parent = typeof parent === 'string' ? parent : FS.getPath(parent);
  5533. var parts = path.split('/').reverse();
  5534. while (parts.length) {
  5535. var part = parts.pop();
  5536. if (!part) continue;
  5537. var current = PATH.join2(parent, part);
  5538. try {
  5539. FS.mkdir(current);
  5540. } catch (e) {
  5541. // ignore EEXIST
  5542. }
  5543. parent = current;
  5544. }
  5545. return current;
  5546. },createFile:function (parent, name, properties, canRead, canWrite) {
  5547. var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
  5548. var mode = FS.getMode(canRead, canWrite);
  5549. return FS.create(path, mode);
  5550. },createDataFile:function (parent, name, data, canRead, canWrite, canOwn) {
  5551. var path = name ? PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name) : parent;
  5552. var mode = FS.getMode(canRead, canWrite);
  5553. var node = FS.create(path, mode);
  5554. if (data) {
  5555. if (typeof data === 'string') {
  5556. var arr = new Array(data.length);
  5557. for (var i = 0, len = data.length; i < len; ++i) arr[i] = data.charCodeAt(i);
  5558. data = arr;
  5559. }
  5560. // make sure we can write to the file
  5561. FS.chmod(node, mode | 146);
  5562. var stream = FS.open(node, 'w');
  5563. FS.write(stream, data, 0, data.length, 0, canOwn);
  5564. FS.close(stream);
  5565. FS.chmod(node, mode);
  5566. }
  5567. return node;
  5568. },createDevice:function (parent, name, input, output) {
  5569. var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
  5570. var mode = FS.getMode(!!input, !!output);
  5571. if (!FS.createDevice.major) FS.createDevice.major = 64;
  5572. var dev = FS.makedev(FS.createDevice.major++, 0);
  5573. // Create a fake device that a set of stream ops to emulate
  5574. // the old behavior.
  5575. FS.registerDevice(dev, {
  5576. open: function(stream) {
  5577. stream.seekable = false;
  5578. },
  5579. close: function(stream) {
  5580. // flush any pending line data
  5581. if (output && output.buffer && output.buffer.length) {
  5582. output(10);
  5583. }
  5584. },
  5585. read: function(stream, buffer, offset, length, pos /* ignored */) {
  5586. var bytesRead = 0;
  5587. for (var i = 0; i < length; i++) {
  5588. var result;
  5589. try {
  5590. result = input();
  5591. } catch (e) {
  5592. throw new FS.ErrnoError(ERRNO_CODES.EIO);
  5593. }
  5594. if (result === undefined && bytesRead === 0) {
  5595. throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
  5596. }
  5597. if (result === null || result === undefined) break;
  5598. bytesRead++;
  5599. buffer[offset+i] = result;
  5600. }
  5601. if (bytesRead) {
  5602. stream.node.timestamp = Date.now();
  5603. }
  5604. return bytesRead;
  5605. },
  5606. write: function(stream, buffer, offset, length, pos) {
  5607. for (var i = 0; i < length; i++) {
  5608. try {
  5609. output(buffer[offset+i]);
  5610. } catch (e) {
  5611. throw new FS.ErrnoError(ERRNO_CODES.EIO);
  5612. }
  5613. }
  5614. if (length) {
  5615. stream.node.timestamp = Date.now();
  5616. }
  5617. return i;
  5618. }
  5619. });
  5620. return FS.mkdev(path, mode, dev);
  5621. },createLink:function (parent, name, target, canRead, canWrite) {
  5622. var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
  5623. return FS.symlink(target, path);
  5624. },forceLoadFile:function (obj) {
  5625. if (obj.isDevice || obj.isFolder || obj.link || obj.contents) return true;
  5626. var success = true;
  5627. if (typeof XMLHttpRequest !== 'undefined') {
  5628. throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread.");
  5629. } else if (Module['read']) {
  5630. // Command-line.
  5631. try {
  5632. // WARNING: Can't read binary files in V8's d8 or tracemonkey's js, as
  5633. // read() will try to parse UTF8.
  5634. obj.contents = intArrayFromString(Module['read'](obj.url), true);
  5635. obj.usedBytes = obj.contents.length;
  5636. } catch (e) {
  5637. success = false;
  5638. }
  5639. } else {
  5640. throw new Error('Cannot load without read() or XMLHttpRequest.');
  5641. }
  5642. if (!success) ___setErrNo(ERRNO_CODES.EIO);
  5643. return success;
  5644. },createLazyFile:function (parent, name, url, canRead, canWrite) {
  5645. // Lazy chunked Uint8Array (implements get and length from Uint8Array). Actual getting is abstracted away for eventual reuse.
  5646. function LazyUint8Array() {
  5647. this.lengthKnown = false;
  5648. this.chunks = []; // Loaded chunks. Index is the chunk number
  5649. }
  5650. LazyUint8Array.prototype.get = function LazyUint8Array_get(idx) {
  5651. if (idx > this.length-1 || idx < 0) {
  5652. return undefined;
  5653. }
  5654. var chunkOffset = idx % this.chunkSize;
  5655. var chunkNum = (idx / this.chunkSize)|0;
  5656. return this.getter(chunkNum)[chunkOffset];
  5657. }
  5658. LazyUint8Array.prototype.setDataGetter = function LazyUint8Array_setDataGetter(getter) {
  5659. this.getter = getter;
  5660. }
  5661. LazyUint8Array.prototype.cacheLength = function LazyUint8Array_cacheLength() {
  5662. // Find length
  5663. var xhr = new XMLHttpRequest();
  5664. xhr.open('HEAD', url, false);
  5665. xhr.send(null);
  5666. if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status);
  5667. var datalength = Number(xhr.getResponseHeader("Content-length"));
  5668. var header;
  5669. var hasByteServing = (header = xhr.getResponseHeader("Accept-Ranges")) && header === "bytes";
  5670. var usesGzip = (header = xhr.getResponseHeader("Content-Encoding")) && header === "gzip";
  5671. var chunkSize = 1024*1024; // Chunk size in bytes
  5672. if (!hasByteServing) chunkSize = datalength;
  5673. // Function to get a range from the remote URL.
  5674. var doXHR = (function(from, to) {
  5675. if (from > to) throw new Error("invalid range (" + from + ", " + to + ") or no bytes requested!");
  5676. if (to > datalength-1) throw new Error("only " + datalength + " bytes available! programmer error!");
  5677. // TODO: Use mozResponseArrayBuffer, responseStream, etc. if available.
  5678. var xhr = new XMLHttpRequest();
  5679. xhr.open('GET', url, false);
  5680. if (datalength !== chunkSize) xhr.setRequestHeader("Range", "bytes=" + from + "-" + to);
  5681. // Some hints to the browser that we want binary data.
  5682. if (typeof Uint8Array != 'undefined') xhr.responseType = 'arraybuffer';
  5683. if (xhr.overrideMimeType) {
  5684. xhr.overrideMimeType('text/plain; charset=x-user-defined');
  5685. }
  5686. xhr.send(null);
  5687. if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status);
  5688. if (xhr.response !== undefined) {
  5689. return new Uint8Array(xhr.response || []);
  5690. } else {
  5691. return intArrayFromString(xhr.responseText || '', true);
  5692. }
  5693. });
  5694. var lazyArray = this;
  5695. lazyArray.setDataGetter(function(chunkNum) {
  5696. var start = chunkNum * chunkSize;
  5697. var end = (chunkNum+1) * chunkSize - 1; // including this byte
  5698. end = Math.min(end, datalength-1); // if datalength-1 is selected, this is the last block
  5699. if (typeof(lazyArray.chunks[chunkNum]) === "undefined") {
  5700. lazyArray.chunks[chunkNum] = doXHR(start, end);
  5701. }
  5702. if (typeof(lazyArray.chunks[chunkNum]) === "undefined") throw new Error("doXHR failed!");
  5703. return lazyArray.chunks[chunkNum];
  5704. });
  5705. if (usesGzip || !datalength) {
  5706. // if the server uses gzip or doesn't supply the length, we have to download the whole file to get the (uncompressed) length
  5707. chunkSize = datalength = 1; // this will force getter(0)/doXHR do download the whole file
  5708. datalength = this.getter(0).length;
  5709. chunkSize = datalength;
  5710. console.log("LazyFiles on gzip forces download of the whole file when length is accessed");
  5711. }
  5712. this._length = datalength;
  5713. this._chunkSize = chunkSize;
  5714. this.lengthKnown = true;
  5715. }
  5716. if (typeof XMLHttpRequest !== 'undefined') {
  5717. if (!ENVIRONMENT_IS_WORKER) throw 'Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc';
  5718. var lazyArray = new LazyUint8Array();
  5719. Object.defineProperties(lazyArray, {
  5720. length: {
  5721. get: function() {
  5722. if(!this.lengthKnown) {
  5723. this.cacheLength();
  5724. }
  5725. return this._length;
  5726. }
  5727. },
  5728. chunkSize: {
  5729. get: function() {
  5730. if(!this.lengthKnown) {
  5731. this.cacheLength();
  5732. }
  5733. return this._chunkSize;
  5734. }
  5735. }
  5736. });
  5737. var properties = { isDevice: false, contents: lazyArray };
  5738. } else {
  5739. var properties = { isDevice: false, url: url };
  5740. }
  5741. var node = FS.createFile(parent, name, properties, canRead, canWrite);
  5742. // This is a total hack, but I want to get this lazy file code out of the
  5743. // core of MEMFS. If we want to keep this lazy file concept I feel it should
  5744. // be its own thin LAZYFS proxying calls to MEMFS.
  5745. if (properties.contents) {
  5746. node.contents = properties.contents;
  5747. } else if (properties.url) {
  5748. node.contents = null;
  5749. node.url = properties.url;
  5750. }
  5751. // Add a function that defers querying the file size until it is asked the first time.
  5752. Object.defineProperties(node, {
  5753. usedBytes: {
  5754. get: function() { return this.contents.length; }
  5755. }
  5756. });
  5757. // override each stream op with one that tries to force load the lazy file first
  5758. var stream_ops = {};
  5759. var keys = Object.keys(node.stream_ops);
  5760. keys.forEach(function(key) {
  5761. var fn = node.stream_ops[key];
  5762. stream_ops[key] = function forceLoadLazyFile() {
  5763. if (!FS.forceLoadFile(node)) {
  5764. throw new FS.ErrnoError(ERRNO_CODES.EIO);
  5765. }
  5766. return fn.apply(null, arguments);
  5767. };
  5768. });
  5769. // use a custom read function
  5770. stream_ops.read = function stream_ops_read(stream, buffer, offset, length, position) {
  5771. if (!FS.forceLoadFile(node)) {
  5772. throw new FS.ErrnoError(ERRNO_CODES.EIO);
  5773. }
  5774. var contents = stream.node.contents;
  5775. if (position >= contents.length)
  5776. return 0;
  5777. var size = Math.min(contents.length - position, length);
  5778. assert(size >= 0);
  5779. if (contents.slice) { // normal array
  5780. for (var i = 0; i < size; i++) {
  5781. buffer[offset + i] = contents[position + i];
  5782. }
  5783. } else {
  5784. for (var i = 0; i < size; i++) { // LazyUint8Array from sync binary XHR
  5785. buffer[offset + i] = contents.get(position + i);
  5786. }
  5787. }
  5788. return size;
  5789. };
  5790. node.stream_ops = stream_ops;
  5791. return node;
  5792. },createPreloadedFile:function (parent, name, url, canRead, canWrite, onload, onerror, dontCreateFile, canOwn, preFinish) {
  5793. Browser.init(); // XXX perhaps this method should move onto Browser?
  5794. // TODO we should allow people to just pass in a complete filename instead
  5795. // of parent and name being that we just join them anyways
  5796. var fullname = name ? PATH.resolve(PATH.join2(parent, name)) : parent;
  5797. var dep = getUniqueRunDependency('cp ' + fullname); // might have several active requests for the same fullname
  5798. function processData(byteArray) {
  5799. function finish(byteArray) {
  5800. if (preFinish) preFinish();
  5801. if (!dontCreateFile) {
  5802. FS.createDataFile(parent, name, byteArray, canRead, canWrite, canOwn);
  5803. }
  5804. if (onload) onload();
  5805. removeRunDependency(dep);
  5806. }
  5807. var handled = false;
  5808. Module['preloadPlugins'].forEach(function(plugin) {
  5809. if (handled) return;
  5810. if (plugin['canHandle'](fullname)) {
  5811. plugin['handle'](byteArray, fullname, finish, function() {
  5812. if (onerror) onerror();
  5813. removeRunDependency(dep);
  5814. });
  5815. handled = true;
  5816. }
  5817. });
  5818. if (!handled) finish(byteArray);
  5819. }
  5820. addRunDependency(dep);
  5821. if (typeof url == 'string') {
  5822. Browser.asyncLoad(url, function(byteArray) {
  5823. processData(byteArray);
  5824. }, onerror);
  5825. } else {
  5826. processData(url);
  5827. }
  5828. },indexedDB:function () {
  5829. return window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB;
  5830. },DB_NAME:function () {
  5831. return 'EM_FS_' + window.location.pathname;
  5832. },DB_VERSION:20,DB_STORE_NAME:"FILE_DATA",saveFilesToDB:function (paths, onload, onerror) {
  5833. onload = onload || function(){};
  5834. onerror = onerror || function(){};
  5835. var indexedDB = FS.indexedDB();
  5836. try {
  5837. var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION);
  5838. } catch (e) {
  5839. return onerror(e);
  5840. }
  5841. openRequest.onupgradeneeded = function openRequest_onupgradeneeded() {
  5842. console.log('creating db');
  5843. var db = openRequest.result;
  5844. db.createObjectStore(FS.DB_STORE_NAME);
  5845. };
  5846. openRequest.onsuccess = function openRequest_onsuccess() {
  5847. var db = openRequest.result;
  5848. var transaction = db.transaction([FS.DB_STORE_NAME], 'readwrite');
  5849. var files = transaction.objectStore(FS.DB_STORE_NAME);
  5850. var ok = 0, fail = 0, total = paths.length;
  5851. function finish() {
  5852. if (fail == 0) onload(); else onerror();
  5853. }
  5854. paths.forEach(function(path) {
  5855. var putRequest = files.put(FS.analyzePath(path).object.contents, path);
  5856. putRequest.onsuccess = function putRequest_onsuccess() { ok++; if (ok + fail == total) finish() };
  5857. putRequest.onerror = function putRequest_onerror() { fail++; if (ok + fail == total) finish() };
  5858. });
  5859. transaction.onerror = onerror;
  5860. };
  5861. openRequest.onerror = onerror;
  5862. },loadFilesFromDB:function (paths, onload, onerror) {
  5863. onload = onload || function(){};
  5864. onerror = onerror || function(){};
  5865. var indexedDB = FS.indexedDB();
  5866. try {
  5867. var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION);
  5868. } catch (e) {
  5869. return onerror(e);
  5870. }
  5871. openRequest.onupgradeneeded = onerror; // no database to load from
  5872. openRequest.onsuccess = function openRequest_onsuccess() {
  5873. var db = openRequest.result;
  5874. try {
  5875. var transaction = db.transaction([FS.DB_STORE_NAME], 'readonly');
  5876. } catch(e) {
  5877. onerror(e);
  5878. return;
  5879. }
  5880. var files = transaction.objectStore(FS.DB_STORE_NAME);
  5881. var ok = 0, fail = 0, total = paths.length;
  5882. function finish() {
  5883. if (fail == 0) onload(); else onerror();
  5884. }
  5885. paths.forEach(function(path) {
  5886. var getRequest = files.get(path);
  5887. getRequest.onsuccess = function getRequest_onsuccess() {
  5888. if (FS.analyzePath(path).exists) {
  5889. FS.unlink(path);
  5890. }
  5891. FS.createDataFile(PATH.dirname(path), PATH.basename(path), getRequest.result, true, true, true);
  5892. ok++;
  5893. if (ok + fail == total) finish();
  5894. };
  5895. getRequest.onerror = function getRequest_onerror() { fail++; if (ok + fail == total) finish() };
  5896. });
  5897. transaction.onerror = onerror;
  5898. };
  5899. openRequest.onerror = onerror;
  5900. }};var SYSCALLS={DEFAULT_POLLMASK:5,mappings:{},umask:511,calculateAt:function (dirfd, path) {
  5901. if (path[0] !== '/') {
  5902. // relative path
  5903. var dir;
  5904. if (dirfd === -100) {
  5905. dir = FS.cwd();
  5906. } else {
  5907. var dirstream = FS.getStream(dirfd);
  5908. if (!dirstream) throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  5909. dir = dirstream.path;
  5910. }
  5911. path = PATH.join2(dir, path);
  5912. }
  5913. return path;
  5914. },doStat:function (func, path, buf) {
  5915. try {
  5916. var stat = func(path);
  5917. } catch (e) {
  5918. if (e && e.node && PATH.normalize(path) !== PATH.normalize(FS.getPath(e.node))) {
  5919. // an error occurred while trying to look up the path; we should just report ENOTDIR
  5920. return -ERRNO_CODES.ENOTDIR;
  5921. }
  5922. throw e;
  5923. }
  5924. HEAP32[((buf)>>2)]=stat.dev;
  5925. HEAP32[(((buf)+(4))>>2)]=0;
  5926. HEAP32[(((buf)+(8))>>2)]=stat.ino;
  5927. HEAP32[(((buf)+(12))>>2)]=stat.mode;
  5928. HEAP32[(((buf)+(16))>>2)]=stat.nlink;
  5929. HEAP32[(((buf)+(20))>>2)]=stat.uid;
  5930. HEAP32[(((buf)+(24))>>2)]=stat.gid;
  5931. HEAP32[(((buf)+(28))>>2)]=stat.rdev;
  5932. HEAP32[(((buf)+(32))>>2)]=0;
  5933. HEAP32[(((buf)+(36))>>2)]=stat.size;
  5934. HEAP32[(((buf)+(40))>>2)]=4096;
  5935. HEAP32[(((buf)+(44))>>2)]=stat.blocks;
  5936. HEAP32[(((buf)+(48))>>2)]=(stat.atime.getTime() / 1000)|0;
  5937. HEAP32[(((buf)+(52))>>2)]=0;
  5938. HEAP32[(((buf)+(56))>>2)]=(stat.mtime.getTime() / 1000)|0;
  5939. HEAP32[(((buf)+(60))>>2)]=0;
  5940. HEAP32[(((buf)+(64))>>2)]=(stat.ctime.getTime() / 1000)|0;
  5941. HEAP32[(((buf)+(68))>>2)]=0;
  5942. HEAP32[(((buf)+(72))>>2)]=stat.ino;
  5943. return 0;
  5944. },doMsync:function (addr, stream, len, flags) {
  5945. var buffer = new Uint8Array(HEAPU8.subarray(addr, addr + len));
  5946. FS.msync(stream, buffer, 0, len, flags);
  5947. },doMkdir:function (path, mode) {
  5948. // remove a trailing slash, if one - /a/b/ has basename of '', but
  5949. // we want to create b in the context of this function
  5950. path = PATH.normalize(path);
  5951. if (path[path.length-1] === '/') path = path.substr(0, path.length-1);
  5952. FS.mkdir(path, mode, 0);
  5953. return 0;
  5954. },doMknod:function (path, mode, dev) {
  5955. // we don't want this in the JS API as it uses mknod to create all nodes.
  5956. switch (mode & 61440) {
  5957. case 32768:
  5958. case 8192:
  5959. case 24576:
  5960. case 4096:
  5961. case 49152:
  5962. break;
  5963. default: return -ERRNO_CODES.EINVAL;
  5964. }
  5965. FS.mknod(path, mode, dev);
  5966. return 0;
  5967. },doReadlink:function (path, buf, bufsize) {
  5968. if (bufsize <= 0) return -ERRNO_CODES.EINVAL;
  5969. var ret = FS.readlink(path);
  5970. var len = Math.min(bufsize, lengthBytesUTF8(ret));
  5971. var endChar = HEAP8[buf+len];
  5972. stringToUTF8(ret, buf, bufsize+1);
  5973. // readlink is one of the rare functions that write out a C string, but does never append a null to the output buffer(!)
  5974. // stringToUTF8() always appends a null byte, so restore the character under the null byte after the write.
  5975. HEAP8[buf+len] = endChar;
  5976. return len;
  5977. },doAccess:function (path, amode) {
  5978. if (amode & ~7) {
  5979. // need a valid mode
  5980. return -ERRNO_CODES.EINVAL;
  5981. }
  5982. var node;
  5983. var lookup = FS.lookupPath(path, { follow: true });
  5984. node = lookup.node;
  5985. var perms = '';
  5986. if (amode & 4) perms += 'r';
  5987. if (amode & 2) perms += 'w';
  5988. if (amode & 1) perms += 'x';
  5989. if (perms /* otherwise, they've just passed F_OK */ && FS.nodePermissions(node, perms)) {
  5990. return -ERRNO_CODES.EACCES;
  5991. }
  5992. return 0;
  5993. },doDup:function (path, flags, suggestFD) {
  5994. var suggest = FS.getStream(suggestFD);
  5995. if (suggest) FS.close(suggest);
  5996. return FS.open(path, flags, 0, suggestFD, suggestFD).fd;
  5997. },doReadv:function (stream, iov, iovcnt, offset) {
  5998. var ret = 0;
  5999. for (var i = 0; i < iovcnt; i++) {
  6000. var ptr = HEAP32[(((iov)+(i*8))>>2)];
  6001. var len = HEAP32[(((iov)+(i*8 + 4))>>2)];
  6002. var curr = FS.read(stream, HEAP8,ptr, len, offset);
  6003. if (curr < 0) return -1;
  6004. ret += curr;
  6005. if (curr < len) break; // nothing more to read
  6006. }
  6007. return ret;
  6008. },doWritev:function (stream, iov, iovcnt, offset) {
  6009. var ret = 0;
  6010. for (var i = 0; i < iovcnt; i++) {
  6011. var ptr = HEAP32[(((iov)+(i*8))>>2)];
  6012. var len = HEAP32[(((iov)+(i*8 + 4))>>2)];
  6013. var curr = FS.write(stream, HEAP8,ptr, len, offset);
  6014. if (curr < 0) return -1;
  6015. ret += curr;
  6016. }
  6017. return ret;
  6018. },varargs:0,get:function (varargs) {
  6019. SYSCALLS.varargs += 4;
  6020. var ret = HEAP32[(((SYSCALLS.varargs)-(4))>>2)];
  6021. return ret;
  6022. },getStr:function () {
  6023. var ret = Pointer_stringify(SYSCALLS.get());
  6024. return ret;
  6025. },getStreamFromFD:function () {
  6026. var stream = FS.getStream(SYSCALLS.get());
  6027. if (!stream) throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  6028. return stream;
  6029. },getSocketFromFD:function () {
  6030. var socket = SOCKFS.getSocket(SYSCALLS.get());
  6031. if (!socket) throw new FS.ErrnoError(ERRNO_CODES.EBADF);
  6032. return socket;
  6033. },getSocketAddress:function (allowNull) {
  6034. var addrp = SYSCALLS.get(), addrlen = SYSCALLS.get();
  6035. if (allowNull && addrp === 0) return null;
  6036. var info = __read_sockaddr(addrp, addrlen);
  6037. if (info.errno) throw new FS.ErrnoError(info.errno);
  6038. info.addr = DNS.lookup_addr(info.addr) || info.addr;
  6039. return info;
  6040. },get64:function () {
  6041. var low = SYSCALLS.get(), high = SYSCALLS.get();
  6042. if (low >= 0) assert(high === 0);
  6043. else assert(high === -1);
  6044. return low;
  6045. },getZero:function () {
  6046. assert(SYSCALLS.get() === 0);
  6047. }};function ___syscall54(which, varargs) {SYSCALLS.varargs = varargs;
  6048. try {
  6049. // ioctl
  6050. var stream = SYSCALLS.getStreamFromFD(), op = SYSCALLS.get();
  6051. switch (op) {
  6052. case 21505: {
  6053. if (!stream.tty) return -ERRNO_CODES.ENOTTY;
  6054. return 0;
  6055. }
  6056. case 21506: {
  6057. if (!stream.tty) return -ERRNO_CODES.ENOTTY;
  6058. return 0; // no-op, not actually adjusting terminal settings
  6059. }
  6060. case 21519: {
  6061. if (!stream.tty) return -ERRNO_CODES.ENOTTY;
  6062. var argp = SYSCALLS.get();
  6063. HEAP32[((argp)>>2)]=0;
  6064. return 0;
  6065. }
  6066. case 21520: {
  6067. if (!stream.tty) return -ERRNO_CODES.ENOTTY;
  6068. return -ERRNO_CODES.EINVAL; // not supported
  6069. }
  6070. case 21531: {
  6071. var argp = SYSCALLS.get();
  6072. return FS.ioctl(stream, op, argp);
  6073. }
  6074. case 21523: {
  6075. // TODO: in theory we should write to the winsize struct that gets
  6076. // passed in, but for now musl doesn't read anything on it
  6077. if (!stream.tty) return -ERRNO_CODES.ENOTTY;
  6078. return 0;
  6079. }
  6080. default: abort('bad ioctl syscall ' + op);
  6081. }
  6082. } catch (e) {
  6083. if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e);
  6084. return -e.errno;
  6085. }
  6086. }
  6087. function _emscripten_glSampleCoverage(value, invert) {
  6088. GLctx.sampleCoverage(value, !!invert);
  6089. }
  6090. function _glDeleteTextures(n, textures) {
  6091. for (var i = 0; i < n; i++) {
  6092. var id = HEAP32[(((textures)+(i*4))>>2)];
  6093. var texture = GL.textures[id];
  6094. if (!texture) continue; // GL spec: "glDeleteTextures silently ignores 0s and names that do not correspond to existing textures".
  6095. GLctx.deleteTexture(texture);
  6096. texture.name = 0;
  6097. GL.textures[id] = null;
  6098. }
  6099. }
  6100. function _emscripten_glFrustum() {
  6101. Module['printErr']('missing function: emscripten_glFrustum'); abort(-1);
  6102. }
  6103. function _glfwSetWindowSizeCallback(winid, cbfun) {
  6104. GLFW.setWindowSizeCallback(winid, cbfun);
  6105. }
  6106. function _emscripten_glGetTexParameterfv(target, pname, params) {
  6107. if (!params) {
  6108. // GLES2 specification does not specify how to behave if params is a null pointer. Since calling this function does not make sense
  6109. // if p == null, issue a GL error to notify user about it.
  6110. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  6111. return;
  6112. }
  6113. HEAPF32[((params)>>2)]=GLctx.getTexParameter(target, pname);
  6114. }
  6115. function _emscripten_glUniform4i(location, v0, v1, v2, v3) {
  6116. GLctx.uniform4i(GL.uniforms[location], v0, v1, v2, v3);
  6117. }
  6118. function _emscripten_glBindRenderbuffer(target, renderbuffer) {
  6119. GLctx.bindRenderbuffer(target, renderbuffer ? GL.renderbuffers[renderbuffer] : null);
  6120. }
  6121. function _emscripten_glViewport(x0, x1, x2, x3) { GLctx['viewport'](x0, x1, x2, x3) }
  6122. var JSEvents={keyEvent:0,mouseEvent:0,wheelEvent:0,uiEvent:0,focusEvent:0,deviceOrientationEvent:0,deviceMotionEvent:0,fullscreenChangeEvent:0,pointerlockChangeEvent:0,visibilityChangeEvent:0,touchEvent:0,lastGamepadState:null,lastGamepadStateFrame:null,numGamepadsConnected:0,previousFullscreenElement:null,previousScreenX:null,previousScreenY:null,removeEventListenersRegistered:false,staticInit:function () {
  6123. if (typeof window !== 'undefined') {
  6124. window.addEventListener("gamepadconnected", function() { ++JSEvents.numGamepadsConnected; });
  6125. window.addEventListener("gamepaddisconnected", function() { --JSEvents.numGamepadsConnected; });
  6126. }
  6127. },registerRemoveEventListeners:function () {
  6128. if (!JSEvents.removeEventListenersRegistered) {
  6129. __ATEXIT__.push(function() {
  6130. for(var i = JSEvents.eventHandlers.length-1; i >= 0; --i) {
  6131. JSEvents._removeHandler(i);
  6132. }
  6133. });
  6134. JSEvents.removeEventListenersRegistered = true;
  6135. }
  6136. },findEventTarget:function (target) {
  6137. if (target) {
  6138. if (typeof target == "number") {
  6139. target = Pointer_stringify(target);
  6140. }
  6141. if (target == '#window') return window;
  6142. else if (target == '#document') return document;
  6143. else if (target == '#screen') return window.screen;
  6144. else if (target == '#canvas') return Module['canvas'];
  6145. if (typeof target == 'string') return document.getElementById(target);
  6146. else return target;
  6147. } else {
  6148. // The sensible target varies between events, but use window as the default
  6149. // since DOM events mostly can default to that. Specific callback registrations
  6150. // override their own defaults.
  6151. return window;
  6152. }
  6153. },deferredCalls:[],deferCall:function (targetFunction, precedence, argsList) {
  6154. function arraysHaveEqualContent(arrA, arrB) {
  6155. if (arrA.length != arrB.length) return false;
  6156. for(var i in arrA) {
  6157. if (arrA[i] != arrB[i]) return false;
  6158. }
  6159. return true;
  6160. }
  6161. // Test if the given call was already queued, and if so, don't add it again.
  6162. for(var i in JSEvents.deferredCalls) {
  6163. var call = JSEvents.deferredCalls[i];
  6164. if (call.targetFunction == targetFunction && arraysHaveEqualContent(call.argsList, argsList)) {
  6165. return;
  6166. }
  6167. }
  6168. JSEvents.deferredCalls.push({
  6169. targetFunction: targetFunction,
  6170. precedence: precedence,
  6171. argsList: argsList
  6172. });
  6173. JSEvents.deferredCalls.sort(function(x,y) { return x.precedence < y.precedence; });
  6174. },removeDeferredCalls:function (targetFunction) {
  6175. for(var i = 0; i < JSEvents.deferredCalls.length; ++i) {
  6176. if (JSEvents.deferredCalls[i].targetFunction == targetFunction) {
  6177. JSEvents.deferredCalls.splice(i, 1);
  6178. --i;
  6179. }
  6180. }
  6181. },canPerformEventHandlerRequests:function () {
  6182. return JSEvents.inEventHandler && JSEvents.currentEventHandler.allowsDeferredCalls;
  6183. },runDeferredCalls:function () {
  6184. if (!JSEvents.canPerformEventHandlerRequests()) {
  6185. return;
  6186. }
  6187. for(var i = 0; i < JSEvents.deferredCalls.length; ++i) {
  6188. var call = JSEvents.deferredCalls[i];
  6189. JSEvents.deferredCalls.splice(i, 1);
  6190. --i;
  6191. call.targetFunction.apply(this, call.argsList);
  6192. }
  6193. },inEventHandler:0,currentEventHandler:null,eventHandlers:[],isInternetExplorer:function () { return navigator.userAgent.indexOf('MSIE') !== -1 || navigator.appVersion.indexOf('Trident/') > 0; },removeAllHandlersOnTarget:function (target, eventTypeString) {
  6194. for(var i = 0; i < JSEvents.eventHandlers.length; ++i) {
  6195. if (JSEvents.eventHandlers[i].target == target &&
  6196. (!eventTypeString || eventTypeString == JSEvents.eventHandlers[i].eventTypeString)) {
  6197. JSEvents._removeHandler(i--);
  6198. }
  6199. }
  6200. },_removeHandler:function (i) {
  6201. var h = JSEvents.eventHandlers[i];
  6202. h.target.removeEventListener(h.eventTypeString, h.eventListenerFunc, h.useCapture);
  6203. JSEvents.eventHandlers.splice(i, 1);
  6204. },registerOrRemoveHandler:function (eventHandler) {
  6205. var jsEventHandler = function jsEventHandler(event) {
  6206. // Increment nesting count for the event handler.
  6207. ++JSEvents.inEventHandler;
  6208. JSEvents.currentEventHandler = eventHandler;
  6209. // Process any old deferred calls the user has placed.
  6210. JSEvents.runDeferredCalls();
  6211. // Process the actual event, calls back to user C code handler.
  6212. eventHandler.handlerFunc(event);
  6213. // Process any new deferred calls that were placed right now from this event handler.
  6214. JSEvents.runDeferredCalls();
  6215. // Out of event handler - restore nesting count.
  6216. --JSEvents.inEventHandler;
  6217. }
  6218. if (eventHandler.callbackfunc) {
  6219. eventHandler.eventListenerFunc = jsEventHandler;
  6220. eventHandler.target.addEventListener(eventHandler.eventTypeString, jsEventHandler, eventHandler.useCapture);
  6221. JSEvents.eventHandlers.push(eventHandler);
  6222. JSEvents.registerRemoveEventListeners();
  6223. } else {
  6224. for(var i = 0; i < JSEvents.eventHandlers.length; ++i) {
  6225. if (JSEvents.eventHandlers[i].target == eventHandler.target
  6226. && JSEvents.eventHandlers[i].eventTypeString == eventHandler.eventTypeString) {
  6227. JSEvents._removeHandler(i--);
  6228. }
  6229. }
  6230. }
  6231. },registerKeyEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6232. if (!JSEvents.keyEvent) {
  6233. JSEvents.keyEvent = _malloc( 164 );
  6234. }
  6235. var handlerFunc = function(event) {
  6236. var e = event || window.event;
  6237. stringToUTF8(e.key ? e.key : "", JSEvents.keyEvent + 0, 32);
  6238. stringToUTF8(e.code ? e.code : "", JSEvents.keyEvent + 32, 32);
  6239. HEAP32[(((JSEvents.keyEvent)+(64))>>2)]=e.location;
  6240. HEAP32[(((JSEvents.keyEvent)+(68))>>2)]=e.ctrlKey;
  6241. HEAP32[(((JSEvents.keyEvent)+(72))>>2)]=e.shiftKey;
  6242. HEAP32[(((JSEvents.keyEvent)+(76))>>2)]=e.altKey;
  6243. HEAP32[(((JSEvents.keyEvent)+(80))>>2)]=e.metaKey;
  6244. HEAP32[(((JSEvents.keyEvent)+(84))>>2)]=e.repeat;
  6245. stringToUTF8(e.locale ? e.locale : "", JSEvents.keyEvent + 88, 32);
  6246. stringToUTF8(e.char ? e.char : "", JSEvents.keyEvent + 120, 32);
  6247. HEAP32[(((JSEvents.keyEvent)+(152))>>2)]=e.charCode;
  6248. HEAP32[(((JSEvents.keyEvent)+(156))>>2)]=e.keyCode;
  6249. HEAP32[(((JSEvents.keyEvent)+(160))>>2)]=e.which;
  6250. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.keyEvent, userData);
  6251. if (shouldCancel) {
  6252. e.preventDefault();
  6253. }
  6254. };
  6255. var eventHandler = {
  6256. target: JSEvents.findEventTarget(target),
  6257. allowsDeferredCalls: JSEvents.isInternetExplorer() ? false : true, // MSIE doesn't allow fullscreen and pointerlock requests from key handlers, others do.
  6258. eventTypeString: eventTypeString,
  6259. callbackfunc: callbackfunc,
  6260. handlerFunc: handlerFunc,
  6261. useCapture: useCapture
  6262. };
  6263. JSEvents.registerOrRemoveHandler(eventHandler);
  6264. },getBoundingClientRectOrZeros:function (target) {
  6265. return target.getBoundingClientRect ? target.getBoundingClientRect() : { left: 0, top: 0 };
  6266. },fillMouseEventData:function (eventStruct, e, target) {
  6267. HEAPF64[((eventStruct)>>3)]=JSEvents.tick();
  6268. HEAP32[(((eventStruct)+(8))>>2)]=e.screenX;
  6269. HEAP32[(((eventStruct)+(12))>>2)]=e.screenY;
  6270. HEAP32[(((eventStruct)+(16))>>2)]=e.clientX;
  6271. HEAP32[(((eventStruct)+(20))>>2)]=e.clientY;
  6272. HEAP32[(((eventStruct)+(24))>>2)]=e.ctrlKey;
  6273. HEAP32[(((eventStruct)+(28))>>2)]=e.shiftKey;
  6274. HEAP32[(((eventStruct)+(32))>>2)]=e.altKey;
  6275. HEAP32[(((eventStruct)+(36))>>2)]=e.metaKey;
  6276. HEAP16[(((eventStruct)+(40))>>1)]=e.button;
  6277. HEAP16[(((eventStruct)+(42))>>1)]=e.buttons;
  6278. HEAP32[(((eventStruct)+(44))>>2)]=e["movementX"] || e["mozMovementX"] || e["webkitMovementX"] || (e.screenX-JSEvents.previousScreenX);
  6279. HEAP32[(((eventStruct)+(48))>>2)]=e["movementY"] || e["mozMovementY"] || e["webkitMovementY"] || (e.screenY-JSEvents.previousScreenY);
  6280. if (Module['canvas']) {
  6281. var rect = Module['canvas'].getBoundingClientRect();
  6282. HEAP32[(((eventStruct)+(60))>>2)]=e.clientX - rect.left;
  6283. HEAP32[(((eventStruct)+(64))>>2)]=e.clientY - rect.top;
  6284. } else { // Canvas is not initialized, return 0.
  6285. HEAP32[(((eventStruct)+(60))>>2)]=0;
  6286. HEAP32[(((eventStruct)+(64))>>2)]=0;
  6287. }
  6288. if (target) {
  6289. var rect = JSEvents.getBoundingClientRectOrZeros(target);
  6290. HEAP32[(((eventStruct)+(52))>>2)]=e.clientX - rect.left;
  6291. HEAP32[(((eventStruct)+(56))>>2)]=e.clientY - rect.top;
  6292. } else { // No specific target passed, return 0.
  6293. HEAP32[(((eventStruct)+(52))>>2)]=0;
  6294. HEAP32[(((eventStruct)+(56))>>2)]=0;
  6295. }
  6296. // wheel and mousewheel events contain wrong screenX/screenY on chrome/opera
  6297. // https://github.com/kripken/emscripten/pull/4997
  6298. // https://bugs.chromium.org/p/chromium/issues/detail?id=699956
  6299. if (e.type !== 'wheel' && e.type !== 'mousewheel') {
  6300. JSEvents.previousScreenX = e.screenX;
  6301. JSEvents.previousScreenY = e.screenY;
  6302. }
  6303. },registerMouseEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6304. if (!JSEvents.mouseEvent) {
  6305. JSEvents.mouseEvent = _malloc( 72 );
  6306. }
  6307. target = JSEvents.findEventTarget(target);
  6308. var handlerFunc = function(event) {
  6309. var e = event || window.event;
  6310. JSEvents.fillMouseEventData(JSEvents.mouseEvent, e, target);
  6311. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.mouseEvent, userData);
  6312. if (shouldCancel) {
  6313. e.preventDefault();
  6314. }
  6315. };
  6316. var eventHandler = {
  6317. target: target,
  6318. allowsDeferredCalls: eventTypeString != 'mousemove' && eventTypeString != 'mouseenter' && eventTypeString != 'mouseleave', // Mouse move events do not allow fullscreen/pointer lock requests to be handled in them!
  6319. eventTypeString: eventTypeString,
  6320. callbackfunc: callbackfunc,
  6321. handlerFunc: handlerFunc,
  6322. useCapture: useCapture
  6323. };
  6324. // In IE, mousedown events don't either allow deferred calls to be run!
  6325. if (JSEvents.isInternetExplorer() && eventTypeString == 'mousedown') eventHandler.allowsDeferredCalls = false;
  6326. JSEvents.registerOrRemoveHandler(eventHandler);
  6327. },registerWheelEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6328. if (!JSEvents.wheelEvent) {
  6329. JSEvents.wheelEvent = _malloc( 104 );
  6330. }
  6331. target = JSEvents.findEventTarget(target);
  6332. // The DOM Level 3 events spec event 'wheel'
  6333. var wheelHandlerFunc = function(event) {
  6334. var e = event || window.event;
  6335. JSEvents.fillMouseEventData(JSEvents.wheelEvent, e, target);
  6336. HEAPF64[(((JSEvents.wheelEvent)+(72))>>3)]=e["deltaX"];
  6337. HEAPF64[(((JSEvents.wheelEvent)+(80))>>3)]=e["deltaY"];
  6338. HEAPF64[(((JSEvents.wheelEvent)+(88))>>3)]=e["deltaZ"];
  6339. HEAP32[(((JSEvents.wheelEvent)+(96))>>2)]=e["deltaMode"];
  6340. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.wheelEvent, userData);
  6341. if (shouldCancel) {
  6342. e.preventDefault();
  6343. }
  6344. };
  6345. // The 'mousewheel' event as implemented in Safari 6.0.5
  6346. var mouseWheelHandlerFunc = function(event) {
  6347. var e = event || window.event;
  6348. JSEvents.fillMouseEventData(JSEvents.wheelEvent, e, target);
  6349. HEAPF64[(((JSEvents.wheelEvent)+(72))>>3)]=e["wheelDeltaX"] || 0;
  6350. HEAPF64[(((JSEvents.wheelEvent)+(80))>>3)]=-(e["wheelDeltaY"] ? e["wheelDeltaY"] : e["wheelDelta"]) /* 1. Invert to unify direction with the DOM Level 3 wheel event. 2. MSIE does not provide wheelDeltaY, so wheelDelta is used as a fallback. */;
  6351. HEAPF64[(((JSEvents.wheelEvent)+(88))>>3)]=0 /* Not available */;
  6352. HEAP32[(((JSEvents.wheelEvent)+(96))>>2)]=0 /* DOM_DELTA_PIXEL */;
  6353. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.wheelEvent, userData);
  6354. if (shouldCancel) {
  6355. e.preventDefault();
  6356. }
  6357. };
  6358. var eventHandler = {
  6359. target: target,
  6360. allowsDeferredCalls: true,
  6361. eventTypeString: eventTypeString,
  6362. callbackfunc: callbackfunc,
  6363. handlerFunc: (eventTypeString == 'wheel') ? wheelHandlerFunc : mouseWheelHandlerFunc,
  6364. useCapture: useCapture
  6365. };
  6366. JSEvents.registerOrRemoveHandler(eventHandler);
  6367. },pageScrollPos:function () {
  6368. if (window.pageXOffset > 0 || window.pageYOffset > 0) {
  6369. return [window.pageXOffset, window.pageYOffset];
  6370. }
  6371. if (typeof document.documentElement.scrollLeft !== 'undefined' || typeof document.documentElement.scrollTop !== 'undefined') {
  6372. return [document.documentElement.scrollLeft, document.documentElement.scrollTop];
  6373. }
  6374. return [document.body.scrollLeft|0, document.body.scrollTop|0];
  6375. },registerUiEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6376. if (!JSEvents.uiEvent) {
  6377. JSEvents.uiEvent = _malloc( 36 );
  6378. }
  6379. if (eventTypeString == "scroll" && !target) {
  6380. target = document; // By default read scroll events on document rather than window.
  6381. } else {
  6382. target = JSEvents.findEventTarget(target);
  6383. }
  6384. var handlerFunc = function(event) {
  6385. var e = event || window.event;
  6386. if (e.target != target) {
  6387. // Never take ui events such as scroll via a 'bubbled' route, but always from the direct element that
  6388. // was targeted. Otherwise e.g. if app logs a message in response to a page scroll, the Emscripten log
  6389. // message box could cause to scroll, generating a new (bubbled) scroll message, causing a new log print,
  6390. // causing a new scroll, etc..
  6391. return;
  6392. }
  6393. var scrollPos = JSEvents.pageScrollPos();
  6394. HEAP32[((JSEvents.uiEvent)>>2)]=e.detail;
  6395. HEAP32[(((JSEvents.uiEvent)+(4))>>2)]=document.body.clientWidth;
  6396. HEAP32[(((JSEvents.uiEvent)+(8))>>2)]=document.body.clientHeight;
  6397. HEAP32[(((JSEvents.uiEvent)+(12))>>2)]=window.innerWidth;
  6398. HEAP32[(((JSEvents.uiEvent)+(16))>>2)]=window.innerHeight;
  6399. HEAP32[(((JSEvents.uiEvent)+(20))>>2)]=window.outerWidth;
  6400. HEAP32[(((JSEvents.uiEvent)+(24))>>2)]=window.outerHeight;
  6401. HEAP32[(((JSEvents.uiEvent)+(28))>>2)]=scrollPos[0];
  6402. HEAP32[(((JSEvents.uiEvent)+(32))>>2)]=scrollPos[1];
  6403. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.uiEvent, userData);
  6404. if (shouldCancel) {
  6405. e.preventDefault();
  6406. }
  6407. };
  6408. var eventHandler = {
  6409. target: target,
  6410. allowsDeferredCalls: false, // Neither scroll or resize events allow running requests inside them.
  6411. eventTypeString: eventTypeString,
  6412. callbackfunc: callbackfunc,
  6413. handlerFunc: handlerFunc,
  6414. useCapture: useCapture
  6415. };
  6416. JSEvents.registerOrRemoveHandler(eventHandler);
  6417. },getNodeNameForTarget:function (target) {
  6418. if (!target) return '';
  6419. if (target == window) return '#window';
  6420. if (target == window.screen) return '#screen';
  6421. return (target && target.nodeName) ? target.nodeName : '';
  6422. },registerFocusEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6423. if (!JSEvents.focusEvent) {
  6424. JSEvents.focusEvent = _malloc( 256 );
  6425. }
  6426. var handlerFunc = function(event) {
  6427. var e = event || window.event;
  6428. var nodeName = JSEvents.getNodeNameForTarget(e.target);
  6429. var id = e.target.id ? e.target.id : '';
  6430. stringToUTF8(nodeName, JSEvents.focusEvent + 0, 128);
  6431. stringToUTF8(id, JSEvents.focusEvent + 128, 128);
  6432. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.focusEvent, userData);
  6433. if (shouldCancel) {
  6434. e.preventDefault();
  6435. }
  6436. };
  6437. var eventHandler = {
  6438. target: JSEvents.findEventTarget(target),
  6439. allowsDeferredCalls: false,
  6440. eventTypeString: eventTypeString,
  6441. callbackfunc: callbackfunc,
  6442. handlerFunc: handlerFunc,
  6443. useCapture: useCapture
  6444. };
  6445. JSEvents.registerOrRemoveHandler(eventHandler);
  6446. },tick:function () {
  6447. if (window['performance'] && window['performance']['now']) return window['performance']['now']();
  6448. else return Date.now();
  6449. },registerDeviceOrientationEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6450. if (!JSEvents.deviceOrientationEvent) {
  6451. JSEvents.deviceOrientationEvent = _malloc( 40 );
  6452. }
  6453. var handlerFunc = function(event) {
  6454. var e = event || window.event;
  6455. HEAPF64[((JSEvents.deviceOrientationEvent)>>3)]=JSEvents.tick();
  6456. HEAPF64[(((JSEvents.deviceOrientationEvent)+(8))>>3)]=e.alpha;
  6457. HEAPF64[(((JSEvents.deviceOrientationEvent)+(16))>>3)]=e.beta;
  6458. HEAPF64[(((JSEvents.deviceOrientationEvent)+(24))>>3)]=e.gamma;
  6459. HEAP32[(((JSEvents.deviceOrientationEvent)+(32))>>2)]=e.absolute;
  6460. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.deviceOrientationEvent, userData);
  6461. if (shouldCancel) {
  6462. e.preventDefault();
  6463. }
  6464. };
  6465. var eventHandler = {
  6466. target: JSEvents.findEventTarget(target),
  6467. allowsDeferredCalls: false,
  6468. eventTypeString: eventTypeString,
  6469. callbackfunc: callbackfunc,
  6470. handlerFunc: handlerFunc,
  6471. useCapture: useCapture
  6472. };
  6473. JSEvents.registerOrRemoveHandler(eventHandler);
  6474. },registerDeviceMotionEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6475. if (!JSEvents.deviceMotionEvent) {
  6476. JSEvents.deviceMotionEvent = _malloc( 80 );
  6477. }
  6478. var handlerFunc = function(event) {
  6479. var e = event || window.event;
  6480. HEAPF64[((JSEvents.deviceOrientationEvent)>>3)]=JSEvents.tick();
  6481. HEAPF64[(((JSEvents.deviceMotionEvent)+(8))>>3)]=e.acceleration.x;
  6482. HEAPF64[(((JSEvents.deviceMotionEvent)+(16))>>3)]=e.acceleration.y;
  6483. HEAPF64[(((JSEvents.deviceMotionEvent)+(24))>>3)]=e.acceleration.z;
  6484. HEAPF64[(((JSEvents.deviceMotionEvent)+(32))>>3)]=e.accelerationIncludingGravity.x;
  6485. HEAPF64[(((JSEvents.deviceMotionEvent)+(40))>>3)]=e.accelerationIncludingGravity.y;
  6486. HEAPF64[(((JSEvents.deviceMotionEvent)+(48))>>3)]=e.accelerationIncludingGravity.z;
  6487. HEAPF64[(((JSEvents.deviceMotionEvent)+(56))>>3)]=e.rotationRate.alpha;
  6488. HEAPF64[(((JSEvents.deviceMotionEvent)+(64))>>3)]=e.rotationRate.beta;
  6489. HEAPF64[(((JSEvents.deviceMotionEvent)+(72))>>3)]=e.rotationRate.gamma;
  6490. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.deviceMotionEvent, userData);
  6491. if (shouldCancel) {
  6492. e.preventDefault();
  6493. }
  6494. };
  6495. var eventHandler = {
  6496. target: JSEvents.findEventTarget(target),
  6497. allowsDeferredCalls: false,
  6498. eventTypeString: eventTypeString,
  6499. callbackfunc: callbackfunc,
  6500. handlerFunc: handlerFunc,
  6501. useCapture: useCapture
  6502. };
  6503. JSEvents.registerOrRemoveHandler(eventHandler);
  6504. },screenOrientation:function () {
  6505. if (!window.screen) return undefined;
  6506. return window.screen.orientation || window.screen.mozOrientation || window.screen.webkitOrientation || window.screen.msOrientation;
  6507. },fillOrientationChangeEventData:function (eventStruct, e) {
  6508. var orientations = ["portrait-primary", "portrait-secondary", "landscape-primary", "landscape-secondary"];
  6509. var orientations2 = ["portrait", "portrait", "landscape", "landscape"];
  6510. var orientationString = JSEvents.screenOrientation();
  6511. var orientation = orientations.indexOf(orientationString);
  6512. if (orientation == -1) {
  6513. orientation = orientations2.indexOf(orientationString);
  6514. }
  6515. HEAP32[((eventStruct)>>2)]=1 << orientation;
  6516. HEAP32[(((eventStruct)+(4))>>2)]=window.orientation;
  6517. },registerOrientationChangeEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6518. if (!JSEvents.orientationChangeEvent) {
  6519. JSEvents.orientationChangeEvent = _malloc( 8 );
  6520. }
  6521. if (!target) {
  6522. target = window.screen; // Orientation events need to be captured from 'window.screen' instead of 'window'
  6523. } else {
  6524. target = JSEvents.findEventTarget(target);
  6525. }
  6526. var handlerFunc = function(event) {
  6527. var e = event || window.event;
  6528. JSEvents.fillOrientationChangeEventData(JSEvents.orientationChangeEvent, e);
  6529. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.orientationChangeEvent, userData);
  6530. if (shouldCancel) {
  6531. e.preventDefault();
  6532. }
  6533. };
  6534. if (eventTypeString == "orientationchange" && window.screen.mozOrientation !== undefined) {
  6535. eventTypeString = "mozorientationchange";
  6536. }
  6537. var eventHandler = {
  6538. target: target,
  6539. allowsDeferredCalls: false,
  6540. eventTypeString: eventTypeString,
  6541. callbackfunc: callbackfunc,
  6542. handlerFunc: handlerFunc,
  6543. useCapture: useCapture
  6544. };
  6545. JSEvents.registerOrRemoveHandler(eventHandler);
  6546. },fullscreenEnabled:function () {
  6547. return document.fullscreenEnabled || document.mozFullScreenEnabled || document.webkitFullscreenEnabled || document.msFullscreenEnabled;
  6548. },fillFullscreenChangeEventData:function (eventStruct, e) {
  6549. var fullscreenElement = document.fullscreenElement || document.mozFullScreenElement || document.webkitFullscreenElement || document.msFullscreenElement;
  6550. var isFullscreen = !!fullscreenElement;
  6551. HEAP32[((eventStruct)>>2)]=isFullscreen;
  6552. HEAP32[(((eventStruct)+(4))>>2)]=JSEvents.fullscreenEnabled();
  6553. // If transitioning to fullscreen, report info about the element that is now fullscreen.
  6554. // If transitioning to windowed mode, report info about the element that just was fullscreen.
  6555. var reportedElement = isFullscreen ? fullscreenElement : JSEvents.previousFullscreenElement;
  6556. var nodeName = JSEvents.getNodeNameForTarget(reportedElement);
  6557. var id = (reportedElement && reportedElement.id) ? reportedElement.id : '';
  6558. stringToUTF8(nodeName, eventStruct + 8, 128);
  6559. stringToUTF8(id, eventStruct + 136, 128);
  6560. HEAP32[(((eventStruct)+(264))>>2)]=reportedElement ? reportedElement.clientWidth : 0;
  6561. HEAP32[(((eventStruct)+(268))>>2)]=reportedElement ? reportedElement.clientHeight : 0;
  6562. HEAP32[(((eventStruct)+(272))>>2)]=screen.width;
  6563. HEAP32[(((eventStruct)+(276))>>2)]=screen.height;
  6564. if (isFullscreen) {
  6565. JSEvents.previousFullscreenElement = fullscreenElement;
  6566. }
  6567. },registerFullscreenChangeEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6568. if (!JSEvents.fullscreenChangeEvent) {
  6569. JSEvents.fullscreenChangeEvent = _malloc( 280 );
  6570. }
  6571. if (!target) {
  6572. target = document; // Fullscreen change events need to be captured from 'document' by default instead of 'window'
  6573. } else {
  6574. target = JSEvents.findEventTarget(target);
  6575. }
  6576. var handlerFunc = function(event) {
  6577. var e = event || window.event;
  6578. JSEvents.fillFullscreenChangeEventData(JSEvents.fullscreenChangeEvent, e);
  6579. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.fullscreenChangeEvent, userData);
  6580. if (shouldCancel) {
  6581. e.preventDefault();
  6582. }
  6583. };
  6584. var eventHandler = {
  6585. target: target,
  6586. allowsDeferredCalls: false,
  6587. eventTypeString: eventTypeString,
  6588. callbackfunc: callbackfunc,
  6589. handlerFunc: handlerFunc,
  6590. useCapture: useCapture
  6591. };
  6592. JSEvents.registerOrRemoveHandler(eventHandler);
  6593. },resizeCanvasForFullscreen:function (target, strategy) {
  6594. var restoreOldStyle = __registerRestoreOldStyle(target);
  6595. var cssWidth = strategy.softFullscreen ? window.innerWidth : screen.width;
  6596. var cssHeight = strategy.softFullscreen ? window.innerHeight : screen.height;
  6597. var rect = target.getBoundingClientRect();
  6598. var windowedCssWidth = rect.right - rect.left;
  6599. var windowedCssHeight = rect.bottom - rect.top;
  6600. var windowedRttWidth = target.width;
  6601. var windowedRttHeight = target.height;
  6602. if (strategy.scaleMode == 3) {
  6603. __setLetterbox(target, (cssHeight - windowedCssHeight) / 2, (cssWidth - windowedCssWidth) / 2);
  6604. cssWidth = windowedCssWidth;
  6605. cssHeight = windowedCssHeight;
  6606. } else if (strategy.scaleMode == 2) {
  6607. if (cssWidth*windowedRttHeight < windowedRttWidth*cssHeight) {
  6608. var desiredCssHeight = windowedRttHeight * cssWidth / windowedRttWidth;
  6609. __setLetterbox(target, (cssHeight - desiredCssHeight) / 2, 0);
  6610. cssHeight = desiredCssHeight;
  6611. } else {
  6612. var desiredCssWidth = windowedRttWidth * cssHeight / windowedRttHeight;
  6613. __setLetterbox(target, 0, (cssWidth - desiredCssWidth) / 2);
  6614. cssWidth = desiredCssWidth;
  6615. }
  6616. }
  6617. // If we are adding padding, must choose a background color or otherwise Chrome will give the
  6618. // padding a default white color. Do it only if user has not customized their own background color.
  6619. if (!target.style.backgroundColor) target.style.backgroundColor = 'black';
  6620. // IE11 does the same, but requires the color to be set in the document body.
  6621. if (!document.body.style.backgroundColor) document.body.style.backgroundColor = 'black'; // IE11
  6622. // Firefox always shows black letterboxes independent of style color.
  6623. target.style.width = cssWidth + 'px';
  6624. target.style.height = cssHeight + 'px';
  6625. if (strategy.filteringMode == 1) {
  6626. target.style.imageRendering = 'optimizeSpeed';
  6627. target.style.imageRendering = '-moz-crisp-edges';
  6628. target.style.imageRendering = '-o-crisp-edges';
  6629. target.style.imageRendering = '-webkit-optimize-contrast';
  6630. target.style.imageRendering = 'optimize-contrast';
  6631. target.style.imageRendering = 'crisp-edges';
  6632. target.style.imageRendering = 'pixelated';
  6633. }
  6634. var dpiScale = (strategy.canvasResolutionScaleMode == 2) ? window.devicePixelRatio : 1;
  6635. if (strategy.canvasResolutionScaleMode != 0) {
  6636. target.width = cssWidth * dpiScale;
  6637. target.height = cssHeight * dpiScale;
  6638. if (target.GLctxObject) target.GLctxObject.GLctx.viewport(0, 0, target.width, target.height);
  6639. }
  6640. return restoreOldStyle;
  6641. },requestFullscreen:function (target, strategy) {
  6642. // EMSCRIPTEN_FULLSCREEN_SCALE_DEFAULT + EMSCRIPTEN_FULLSCREEN_CANVAS_SCALE_NONE is a mode where no extra logic is performed to the DOM elements.
  6643. if (strategy.scaleMode != 0 || strategy.canvasResolutionScaleMode != 0) {
  6644. JSEvents.resizeCanvasForFullscreen(target, strategy);
  6645. }
  6646. if (target.requestFullscreen) {
  6647. target.requestFullscreen();
  6648. } else if (target.msRequestFullscreen) {
  6649. target.msRequestFullscreen();
  6650. } else if (target.mozRequestFullScreen) {
  6651. target.mozRequestFullScreen();
  6652. } else if (target.mozRequestFullscreen) {
  6653. target.mozRequestFullscreen();
  6654. } else if (target.webkitRequestFullscreen) {
  6655. target.webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT);
  6656. } else {
  6657. if (typeof JSEvents.fullscreenEnabled() === 'undefined') {
  6658. return -1;
  6659. } else {
  6660. return -3;
  6661. }
  6662. }
  6663. if (strategy.canvasResizedCallback) {
  6664. Module['dynCall_iiii'](strategy.canvasResizedCallback, 37, 0, strategy.canvasResizedCallbackUserData);
  6665. }
  6666. return 0;
  6667. },fillPointerlockChangeEventData:function (eventStruct, e) {
  6668. var pointerLockElement = document.pointerLockElement || document.mozPointerLockElement || document.webkitPointerLockElement || document.msPointerLockElement;
  6669. var isPointerlocked = !!pointerLockElement;
  6670. HEAP32[((eventStruct)>>2)]=isPointerlocked;
  6671. var nodeName = JSEvents.getNodeNameForTarget(pointerLockElement);
  6672. var id = (pointerLockElement && pointerLockElement.id) ? pointerLockElement.id : '';
  6673. stringToUTF8(nodeName, eventStruct + 4, 128);
  6674. stringToUTF8(id, eventStruct + 132, 128);
  6675. },registerPointerlockChangeEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6676. if (!JSEvents.pointerlockChangeEvent) {
  6677. JSEvents.pointerlockChangeEvent = _malloc( 260 );
  6678. }
  6679. if (!target) {
  6680. target = document; // Pointer lock change events need to be captured from 'document' by default instead of 'window'
  6681. } else {
  6682. target = JSEvents.findEventTarget(target);
  6683. }
  6684. var handlerFunc = function(event) {
  6685. var e = event || window.event;
  6686. JSEvents.fillPointerlockChangeEventData(JSEvents.pointerlockChangeEvent, e);
  6687. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.pointerlockChangeEvent, userData);
  6688. if (shouldCancel) {
  6689. e.preventDefault();
  6690. }
  6691. };
  6692. var eventHandler = {
  6693. target: target,
  6694. allowsDeferredCalls: false,
  6695. eventTypeString: eventTypeString,
  6696. callbackfunc: callbackfunc,
  6697. handlerFunc: handlerFunc,
  6698. useCapture: useCapture
  6699. };
  6700. JSEvents.registerOrRemoveHandler(eventHandler);
  6701. },registerPointerlockErrorEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6702. if (!target) {
  6703. target = document; // Pointer lock events need to be captured from 'document' by default instead of 'window'
  6704. } else {
  6705. target = JSEvents.findEventTarget(target);
  6706. }
  6707. var handlerFunc = function(event) {
  6708. var e = event || window.event;
  6709. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, 0, userData);
  6710. if (shouldCancel) {
  6711. e.preventDefault();
  6712. }
  6713. };
  6714. var eventHandler = {
  6715. target: target,
  6716. allowsDeferredCalls: false,
  6717. eventTypeString: eventTypeString,
  6718. callbackfunc: callbackfunc,
  6719. handlerFunc: handlerFunc,
  6720. useCapture: useCapture
  6721. };
  6722. JSEvents.registerOrRemoveHandler(eventHandler);
  6723. },requestPointerLock:function (target) {
  6724. if (target.requestPointerLock) {
  6725. target.requestPointerLock();
  6726. } else if (target.mozRequestPointerLock) {
  6727. target.mozRequestPointerLock();
  6728. } else if (target.webkitRequestPointerLock) {
  6729. target.webkitRequestPointerLock();
  6730. } else if (target.msRequestPointerLock) {
  6731. target.msRequestPointerLock();
  6732. } else {
  6733. // document.body is known to accept pointer lock, so use that to differentiate if the user passed a bad element,
  6734. // or if the whole browser just doesn't support the feature.
  6735. if (document.body.requestPointerLock || document.body.mozRequestPointerLock || document.body.webkitRequestPointerLock || document.body.msRequestPointerLock) {
  6736. return -3;
  6737. } else {
  6738. return -1;
  6739. }
  6740. }
  6741. return 0;
  6742. },fillVisibilityChangeEventData:function (eventStruct, e) {
  6743. var visibilityStates = [ "hidden", "visible", "prerender", "unloaded" ];
  6744. var visibilityState = visibilityStates.indexOf(document.visibilityState);
  6745. HEAP32[((eventStruct)>>2)]=document.hidden;
  6746. HEAP32[(((eventStruct)+(4))>>2)]=visibilityState;
  6747. },registerVisibilityChangeEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6748. if (!JSEvents.visibilityChangeEvent) {
  6749. JSEvents.visibilityChangeEvent = _malloc( 8 );
  6750. }
  6751. if (!target) {
  6752. target = document; // Visibility change events need to be captured from 'document' by default instead of 'window'
  6753. } else {
  6754. target = JSEvents.findEventTarget(target);
  6755. }
  6756. var handlerFunc = function(event) {
  6757. var e = event || window.event;
  6758. JSEvents.fillVisibilityChangeEventData(JSEvents.visibilityChangeEvent, e);
  6759. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.visibilityChangeEvent, userData);
  6760. if (shouldCancel) {
  6761. e.preventDefault();
  6762. }
  6763. };
  6764. var eventHandler = {
  6765. target: target,
  6766. allowsDeferredCalls: false,
  6767. eventTypeString: eventTypeString,
  6768. callbackfunc: callbackfunc,
  6769. handlerFunc: handlerFunc,
  6770. useCapture: useCapture
  6771. };
  6772. JSEvents.registerOrRemoveHandler(eventHandler);
  6773. },registerTouchEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6774. if (!JSEvents.touchEvent) {
  6775. JSEvents.touchEvent = _malloc( 1684 );
  6776. }
  6777. target = JSEvents.findEventTarget(target);
  6778. var handlerFunc = function(event) {
  6779. var e = event || window.event;
  6780. var touches = {};
  6781. for(var i = 0; i < e.touches.length; ++i) {
  6782. var touch = e.touches[i];
  6783. touches[touch.identifier] = touch;
  6784. }
  6785. for(var i = 0; i < e.changedTouches.length; ++i) {
  6786. var touch = e.changedTouches[i];
  6787. touches[touch.identifier] = touch;
  6788. touch.changed = true;
  6789. }
  6790. for(var i = 0; i < e.targetTouches.length; ++i) {
  6791. var touch = e.targetTouches[i];
  6792. touches[touch.identifier].onTarget = true;
  6793. }
  6794. var ptr = JSEvents.touchEvent;
  6795. HEAP32[(((ptr)+(4))>>2)]=e.ctrlKey;
  6796. HEAP32[(((ptr)+(8))>>2)]=e.shiftKey;
  6797. HEAP32[(((ptr)+(12))>>2)]=e.altKey;
  6798. HEAP32[(((ptr)+(16))>>2)]=e.metaKey;
  6799. ptr += 20; // Advance to the start of the touch array.
  6800. var canvasRect = Module['canvas'] ? Module['canvas'].getBoundingClientRect() : undefined;
  6801. var targetRect = JSEvents.getBoundingClientRectOrZeros(target);
  6802. var numTouches = 0;
  6803. for(var i in touches) {
  6804. var t = touches[i];
  6805. HEAP32[((ptr)>>2)]=t.identifier;
  6806. HEAP32[(((ptr)+(4))>>2)]=t.screenX;
  6807. HEAP32[(((ptr)+(8))>>2)]=t.screenY;
  6808. HEAP32[(((ptr)+(12))>>2)]=t.clientX;
  6809. HEAP32[(((ptr)+(16))>>2)]=t.clientY;
  6810. HEAP32[(((ptr)+(20))>>2)]=t.pageX;
  6811. HEAP32[(((ptr)+(24))>>2)]=t.pageY;
  6812. HEAP32[(((ptr)+(28))>>2)]=t.changed;
  6813. HEAP32[(((ptr)+(32))>>2)]=t.onTarget;
  6814. if (canvasRect) {
  6815. HEAP32[(((ptr)+(44))>>2)]=t.clientX - canvasRect.left;
  6816. HEAP32[(((ptr)+(48))>>2)]=t.clientY - canvasRect.top;
  6817. } else {
  6818. HEAP32[(((ptr)+(44))>>2)]=0;
  6819. HEAP32[(((ptr)+(48))>>2)]=0;
  6820. }
  6821. HEAP32[(((ptr)+(36))>>2)]=t.clientX - targetRect.left;
  6822. HEAP32[(((ptr)+(40))>>2)]=t.clientY - targetRect.top;
  6823. ptr += 52;
  6824. if (++numTouches >= 32) {
  6825. break;
  6826. }
  6827. }
  6828. HEAP32[((JSEvents.touchEvent)>>2)]=numTouches;
  6829. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.touchEvent, userData);
  6830. if (shouldCancel) {
  6831. e.preventDefault();
  6832. }
  6833. };
  6834. var eventHandler = {
  6835. target: target,
  6836. allowsDeferredCalls: false, // XXX Currently disabled, see bug https://bugzilla.mozilla.org/show_bug.cgi?id=966493
  6837. // Once the above bug is resolved, enable the following condition if possible:
  6838. // allowsDeferredCalls: eventTypeString == 'touchstart',
  6839. eventTypeString: eventTypeString,
  6840. callbackfunc: callbackfunc,
  6841. handlerFunc: handlerFunc,
  6842. useCapture: useCapture
  6843. };
  6844. JSEvents.registerOrRemoveHandler(eventHandler);
  6845. },fillGamepadEventData:function (eventStruct, e) {
  6846. HEAPF64[((eventStruct)>>3)]=e.timestamp;
  6847. for(var i = 0; i < e.axes.length; ++i) {
  6848. HEAPF64[(((eventStruct+i*8)+(16))>>3)]=e.axes[i];
  6849. }
  6850. for(var i = 0; i < e.buttons.length; ++i) {
  6851. if (typeof(e.buttons[i]) === 'object') {
  6852. HEAPF64[(((eventStruct+i*8)+(528))>>3)]=e.buttons[i].value;
  6853. } else {
  6854. HEAPF64[(((eventStruct+i*8)+(528))>>3)]=e.buttons[i];
  6855. }
  6856. }
  6857. for(var i = 0; i < e.buttons.length; ++i) {
  6858. if (typeof(e.buttons[i]) === 'object') {
  6859. HEAP32[(((eventStruct+i*4)+(1040))>>2)]=e.buttons[i].pressed;
  6860. } else {
  6861. HEAP32[(((eventStruct+i*4)+(1040))>>2)]=e.buttons[i] == 1.0;
  6862. }
  6863. }
  6864. HEAP32[(((eventStruct)+(1296))>>2)]=e.connected;
  6865. HEAP32[(((eventStruct)+(1300))>>2)]=e.index;
  6866. HEAP32[(((eventStruct)+(8))>>2)]=e.axes.length;
  6867. HEAP32[(((eventStruct)+(12))>>2)]=e.buttons.length;
  6868. stringToUTF8(e.id, eventStruct + 1304, 64);
  6869. stringToUTF8(e.mapping, eventStruct + 1368, 64);
  6870. },registerGamepadEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6871. if (!JSEvents.gamepadEvent) {
  6872. JSEvents.gamepadEvent = _malloc( 1432 );
  6873. }
  6874. var handlerFunc = function(event) {
  6875. var e = event || window.event;
  6876. JSEvents.fillGamepadEventData(JSEvents.gamepadEvent, e.gamepad);
  6877. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.gamepadEvent, userData);
  6878. if (shouldCancel) {
  6879. e.preventDefault();
  6880. }
  6881. };
  6882. var eventHandler = {
  6883. target: JSEvents.findEventTarget(target),
  6884. allowsDeferredCalls: true,
  6885. eventTypeString: eventTypeString,
  6886. callbackfunc: callbackfunc,
  6887. handlerFunc: handlerFunc,
  6888. useCapture: useCapture
  6889. };
  6890. JSEvents.registerOrRemoveHandler(eventHandler);
  6891. },registerBeforeUnloadEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6892. var handlerFunc = function(event) {
  6893. var e = event || window.event;
  6894. var confirmationMessage = Module['dynCall_iiii'](callbackfunc, eventTypeId, 0, userData);
  6895. if (confirmationMessage) {
  6896. confirmationMessage = Pointer_stringify(confirmationMessage);
  6897. }
  6898. if (confirmationMessage) {
  6899. e.preventDefault();
  6900. e.returnValue = confirmationMessage;
  6901. return confirmationMessage;
  6902. }
  6903. };
  6904. var eventHandler = {
  6905. target: JSEvents.findEventTarget(target),
  6906. allowsDeferredCalls: false,
  6907. eventTypeString: eventTypeString,
  6908. callbackfunc: callbackfunc,
  6909. handlerFunc: handlerFunc,
  6910. useCapture: useCapture
  6911. };
  6912. JSEvents.registerOrRemoveHandler(eventHandler);
  6913. },battery:function () { return navigator.battery || navigator.mozBattery || navigator.webkitBattery; },fillBatteryEventData:function (eventStruct, e) {
  6914. HEAPF64[((eventStruct)>>3)]=e.chargingTime;
  6915. HEAPF64[(((eventStruct)+(8))>>3)]=e.dischargingTime;
  6916. HEAPF64[(((eventStruct)+(16))>>3)]=e.level;
  6917. HEAP32[(((eventStruct)+(24))>>2)]=e.charging;
  6918. },registerBatteryEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6919. if (!JSEvents.batteryEvent) {
  6920. JSEvents.batteryEvent = _malloc( 32 );
  6921. }
  6922. var handlerFunc = function(event) {
  6923. var e = event || window.event;
  6924. JSEvents.fillBatteryEventData(JSEvents.batteryEvent, JSEvents.battery());
  6925. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, JSEvents.batteryEvent, userData);
  6926. if (shouldCancel) {
  6927. e.preventDefault();
  6928. }
  6929. };
  6930. var eventHandler = {
  6931. target: JSEvents.findEventTarget(target),
  6932. allowsDeferredCalls: false,
  6933. eventTypeString: eventTypeString,
  6934. callbackfunc: callbackfunc,
  6935. handlerFunc: handlerFunc,
  6936. useCapture: useCapture
  6937. };
  6938. JSEvents.registerOrRemoveHandler(eventHandler);
  6939. },registerWebGlEventCallback:function (target, userData, useCapture, callbackfunc, eventTypeId, eventTypeString) {
  6940. if (!target) {
  6941. target = Module['canvas'];
  6942. }
  6943. var handlerFunc = function(event) {
  6944. var e = event || window.event;
  6945. var shouldCancel = Module['dynCall_iiii'](callbackfunc, eventTypeId, 0, userData);
  6946. if (shouldCancel) {
  6947. e.preventDefault();
  6948. }
  6949. };
  6950. var eventHandler = {
  6951. target: JSEvents.findEventTarget(target),
  6952. allowsDeferredCalls: false,
  6953. eventTypeString: eventTypeString,
  6954. callbackfunc: callbackfunc,
  6955. handlerFunc: handlerFunc,
  6956. useCapture: useCapture
  6957. };
  6958. JSEvents.registerOrRemoveHandler(eventHandler);
  6959. }};function __emscripten_sample_gamepad_data() {
  6960. // Polling gamepads generates garbage, so don't do it when we know there are no gamepads connected.
  6961. if (!JSEvents.numGamepadsConnected) return;
  6962. // Produce a new Gamepad API sample if we are ticking a new game frame, or if not using emscripten_set_main_loop() at all to drive animation.
  6963. if (Browser.mainLoop.currentFrameNumber !== JSEvents.lastGamepadStateFrame || !Browser.mainLoop.currentFrameNumber) {
  6964. JSEvents.lastGamepadState = navigator.getGamepads ? navigator.getGamepads() : (navigator.webkitGetGamepads ? navigator.webkitGetGamepads : null);
  6965. JSEvents.lastGamepadStateFrame = Browser.mainLoop.currentFrameNumber;
  6966. }
  6967. }function _emscripten_get_gamepad_status(index, gamepadState) {
  6968. __emscripten_sample_gamepad_data();
  6969. if (!JSEvents.lastGamepadState) return -1;
  6970. // INVALID_PARAM is returned on a Gamepad index that never was there.
  6971. if (index < 0 || index >= JSEvents.lastGamepadState.length) return -5;
  6972. // NO_DATA is returned on a Gamepad index that was removed.
  6973. // For previously disconnected gamepads there should be an empty slot (null/undefined/false) at the index.
  6974. // This is because gamepads must keep their original position in the array.
  6975. // For example, removing the first of two gamepads produces [null/undefined/false, gamepad].
  6976. if (!JSEvents.lastGamepadState[index]) return -7;
  6977. JSEvents.fillGamepadEventData(gamepadState, JSEvents.lastGamepadState[index]);
  6978. return 0;
  6979. }
  6980. var _llvm_pow_f64=Math_pow;
  6981. function _emscripten_glCopyTexImage2D(x0, x1, x2, x3, x4, x5, x6, x7) { GLctx['copyTexImage2D'](x0, x1, x2, x3, x4, x5, x6, x7) }
  6982. function _emscripten_glTexParameterfv(target, pname, params) {
  6983. var param = HEAPF32[((params)>>2)];
  6984. GLctx.texParameterf(target, pname, param);
  6985. }
  6986. function _emscripten_glLinkProgram(program) {
  6987. GLctx.linkProgram(GL.programs[program]);
  6988. GL.programInfos[program] = null; // uniforms no longer keep the same names after linking
  6989. GL.populateUniformTable(program);
  6990. }
  6991. function _emscripten_glUniform3f(location, v0, v1, v2) {
  6992. GLctx.uniform3f(GL.uniforms[location], v0, v1, v2);
  6993. }
  6994. function _emscripten_glGetObjectParameterivARB() {
  6995. Module['printErr']('missing function: emscripten_glGetObjectParameterivARB'); abort(-1);
  6996. }
  6997. function _emscripten_glBlendFunc(x0, x1) { GLctx['blendFunc'](x0, x1) }
  6998. function _emscripten_glUniform3i(location, v0, v1, v2) {
  6999. GLctx.uniform3i(GL.uniforms[location], v0, v1, v2);
  7000. }
  7001. function _emscripten_glStencilOp(x0, x1, x2) { GLctx['stencilOp'](x0, x1, x2) }
  7002. function _glCreateShader(shaderType) {
  7003. var id = GL.getNewId(GL.shaders);
  7004. GL.shaders[id] = GLctx.createShader(shaderType);
  7005. return id;
  7006. }
  7007. function _glUniform1i(location, v0) {
  7008. GLctx.uniform1i(GL.uniforms[location], v0);
  7009. }
  7010. function _emscripten_glBindAttribLocation(program, index, name) {
  7011. name = Pointer_stringify(name);
  7012. GLctx.bindAttribLocation(GL.programs[program], index, name);
  7013. }
  7014. function _glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data) {
  7015. GLctx['compressedTexImage2D'](target, level, internalFormat, width, height, border, data ? HEAPU8.subarray((data),(data+imageSize)) : null);
  7016. }
  7017. function _glDisable(x0) { GLctx['disable'](x0) }
  7018. function _emscripten_glEnableVertexAttribArray(index) {
  7019. GLctx.enableVertexAttribArray(index);
  7020. }
  7021. Module["_memset"] = _memset;
  7022. function _glfwMakeContextCurrent(winid) {}
  7023. function _emscripten_set_touchcancel_callback(target, userData, useCapture, callbackfunc) {
  7024. JSEvents.registerTouchEventCallback(target, userData, useCapture, callbackfunc, 25, "touchcancel");
  7025. return 0;
  7026. }
  7027. function ___lock() {}
  7028. function _emscripten_glBlendFuncSeparate(x0, x1, x2, x3) { GLctx['blendFuncSeparate'](x0, x1, x2, x3) }
  7029. function _glCullFace(x0) { GLctx['cullFace'](x0) }
  7030. function _emscripten_glGetVertexAttribPointerv(index, pname, pointer) {
  7031. if (!pointer) {
  7032. // GLES2 specification does not specify how to behave if pointer is a null pointer. Since calling this function does not make sense
  7033. // if pointer == null, issue a GL error to notify user about it.
  7034. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7035. return;
  7036. }
  7037. HEAP32[((pointer)>>2)]=GLctx.getVertexAttribOffset(index, pname);
  7038. }
  7039. function _emscripten_glVertexAttrib3f(x0, x1, x2, x3) { GLctx['vertexAttrib3f'](x0, x1, x2, x3) }
  7040. function _emscripten_glEnable(x0) { GLctx['enable'](x0) }
  7041. function _emscripten_glNormalPointer() {
  7042. Module['printErr']('missing function: emscripten_glNormalPointer'); abort(-1);
  7043. }
  7044. var _emscripten_GetProcAddress=undefined;
  7045. Module["_emscripten_GetProcAddress"] = _emscripten_GetProcAddress;
  7046. var EGL={errorCode:12288,defaultDisplayInitialized:false,currentContext:0,currentReadSurface:0,currentDrawSurface:0,stringCache:{},setErrorCode:function (code) {
  7047. EGL.errorCode = code;
  7048. },chooseConfig:function (display, attribList, config, config_size, numConfigs) {
  7049. if (display != 62000 /* Magic ID for Emscripten 'default display' */) {
  7050. EGL.setErrorCode(0x3008 /* EGL_BAD_DISPLAY */);
  7051. return 0;
  7052. }
  7053. // TODO: read attribList.
  7054. if ((!config || !config_size) && !numConfigs) {
  7055. EGL.setErrorCode(0x300C /* EGL_BAD_PARAMETER */);
  7056. return 0;
  7057. }
  7058. if (numConfigs) {
  7059. HEAP32[((numConfigs)>>2)]=1; // Total number of supported configs: 1.
  7060. }
  7061. if (config && config_size > 0) {
  7062. HEAP32[((config)>>2)]=62002;
  7063. }
  7064. EGL.setErrorCode(0x3000 /* EGL_SUCCESS */);
  7065. return 1;
  7066. }};function _eglGetProcAddress(name_) {
  7067. return _emscripten_GetProcAddress(name_);
  7068. }
  7069. function _glDeleteProgram(id) {
  7070. if (!id) return;
  7071. var program = GL.programs[id];
  7072. if (!program) { // glDeleteProgram actually signals an error when deleting a nonexisting object, unlike some other GL delete functions.
  7073. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7074. return;
  7075. }
  7076. GLctx.deleteProgram(program);
  7077. program.name = 0;
  7078. GL.programs[id] = null;
  7079. GL.programInfos[id] = null;
  7080. }
  7081. function _emscripten_get_pointerlock_status(pointerlockStatus) {
  7082. if (pointerlockStatus) JSEvents.fillPointerlockChangeEventData(pointerlockStatus);
  7083. if (!document.body || (!document.body.requestPointerLock && !document.body.mozRequestPointerLock && !document.body.webkitRequestPointerLock && !document.body.msRequestPointerLock)) {
  7084. return -1;
  7085. }
  7086. return 0;
  7087. }
  7088. function _glAttachShader(program, shader) {
  7089. GLctx.attachShader(GL.programs[program],
  7090. GL.shaders[shader]);
  7091. }
  7092. function _glfwGetPrimaryMonitor() {
  7093. return 1;
  7094. }
  7095. function emscriptenWebGLGetVertexAttrib(index, pname, params, type) {
  7096. if (!params) {
  7097. // GLES2 specification does not specify how to behave if params is a null pointer. Since calling this function does not make sense
  7098. // if params == null, issue a GL error to notify user about it.
  7099. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7100. return;
  7101. }
  7102. var data = GLctx.getVertexAttrib(index, pname);
  7103. if (pname == 0x889F/*VERTEX_ATTRIB_ARRAY_BUFFER_BINDING*/) {
  7104. HEAP32[((params)>>2)]=data["name"];
  7105. } else if (typeof data == 'number' || typeof data == 'boolean') {
  7106. switch (type) {
  7107. case 'Integer': HEAP32[((params)>>2)]=data; break;
  7108. case 'Float': HEAPF32[((params)>>2)]=data; break;
  7109. case 'FloatToInteger': HEAP32[((params)>>2)]=Math.fround(data); break;
  7110. default: throw 'internal emscriptenWebGLGetVertexAttrib() error, bad type: ' + type;
  7111. }
  7112. } else {
  7113. for (var i = 0; i < data.length; i++) {
  7114. switch (type) {
  7115. case 'Integer': HEAP32[(((params)+(i))>>2)]=data[i]; break;
  7116. case 'Float': HEAPF32[(((params)+(i))>>2)]=data[i]; break;
  7117. case 'FloatToInteger': HEAP32[(((params)+(i))>>2)]=Math.fround(data[i]); break;
  7118. default: throw 'internal emscriptenWebGLGetVertexAttrib() error, bad type: ' + type;
  7119. }
  7120. }
  7121. }
  7122. }function _emscripten_glGetVertexAttribfv(index, pname, params) {
  7123. // N.B. This function may only be called if the vertex attribute was specified using the function glVertexAttrib*f(),
  7124. // otherwise the results are undefined. (GLES3 spec 6.1.12)
  7125. emscriptenWebGLGetVertexAttrib(index, pname, params, 'Float');
  7126. }
  7127. function _emscripten_set_touchstart_callback(target, userData, useCapture, callbackfunc) {
  7128. JSEvents.registerTouchEventCallback(target, userData, useCapture, callbackfunc, 22, "touchstart");
  7129. return 0;
  7130. }
  7131. function _emscripten_glDeleteShader(id) {
  7132. if (!id) return;
  7133. var shader = GL.shaders[id];
  7134. if (!shader) { // glDeleteShader actually signals an error when deleting a nonexisting object, unlike some other GL delete functions.
  7135. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7136. return;
  7137. }
  7138. GLctx.deleteShader(shader);
  7139. GL.shaders[id] = null;
  7140. }
  7141. function _emscripten_glVertexPointer(){ throw 'Legacy GL function (glVertexPointer) called. If you want legacy GL emulation, you need to compile with -s LEGACY_GL_EMULATION=1 to enable legacy GL emulation.'; }
  7142. function _emscripten_glDeleteBuffers(n, buffers) {
  7143. for (var i = 0; i < n; i++) {
  7144. var id = HEAP32[(((buffers)+(i*4))>>2)];
  7145. var buffer = GL.buffers[id];
  7146. // From spec: "glDeleteBuffers silently ignores 0's and names that do not
  7147. // correspond to existing buffer objects."
  7148. if (!buffer) continue;
  7149. GLctx.deleteBuffer(buffer);
  7150. buffer.name = 0;
  7151. GL.buffers[id] = null;
  7152. if (id == GL.currArrayBuffer) GL.currArrayBuffer = 0;
  7153. if (id == GL.currElementArrayBuffer) GL.currElementArrayBuffer = 0;
  7154. }
  7155. }
  7156. function _emscripten_glTexParameteriv(target, pname, params) {
  7157. var param = HEAP32[((params)>>2)];
  7158. GLctx.texParameteri(target, pname, param);
  7159. }
  7160. function _glDrawElements(mode, count, type, indices) {
  7161. GLctx.drawElements(mode, count, type, indices);
  7162. }
  7163. function _glfwTerminate() {
  7164. window.removeEventListener("keydown", GLFW.onKeydown, true);
  7165. window.removeEventListener("keypress", GLFW.onKeyPress, true);
  7166. window.removeEventListener("keyup", GLFW.onKeyup, true);
  7167. Module["canvas"].removeEventListener("mousemove", GLFW.onMousemove, true);
  7168. Module["canvas"].removeEventListener("mousedown", GLFW.onMouseButtonDown, true);
  7169. Module["canvas"].removeEventListener("mouseup", GLFW.onMouseButtonUp, true);
  7170. Module["canvas"].removeEventListener('wheel', GLFW.onMouseWheel, true);
  7171. Module["canvas"].removeEventListener('mousewheel', GLFW.onMouseWheel, true);
  7172. Module["canvas"].removeEventListener('mouseenter', GLFW.onMouseenter, true);
  7173. Module["canvas"].removeEventListener('mouseleave', GLFW.onMouseleave, true);
  7174. Module["canvas"].width = Module["canvas"].height = 1;
  7175. GLFW.windows = null;
  7176. GLFW.active = null;
  7177. }
  7178. function _emscripten_glUniformMatrix2fv(location, count, transpose, value) {
  7179. var view;
  7180. if (4*count <= GL.MINI_TEMP_BUFFER_SIZE) {
  7181. // avoid allocation when uploading few enough uniforms
  7182. view = GL.miniTempBufferViews[4*count-1];
  7183. for (var i = 0; i < 4*count; i += 4) {
  7184. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  7185. view[i+1] = HEAPF32[(((value)+(4*i+4))>>2)];
  7186. view[i+2] = HEAPF32[(((value)+(4*i+8))>>2)];
  7187. view[i+3] = HEAPF32[(((value)+(4*i+12))>>2)];
  7188. }
  7189. } else {
  7190. view = HEAPF32.subarray((value)>>2,(value+count*16)>>2);
  7191. }
  7192. GLctx.uniformMatrix2fv(GL.uniforms[location], !!transpose, view);
  7193. }
  7194. function ___syscall5(which, varargs) {SYSCALLS.varargs = varargs;
  7195. try {
  7196. // open
  7197. var pathname = SYSCALLS.getStr(), flags = SYSCALLS.get(), mode = SYSCALLS.get() // optional TODO
  7198. var stream = FS.open(pathname, flags, mode);
  7199. return stream.fd;
  7200. } catch (e) {
  7201. if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e);
  7202. return -e.errno;
  7203. }
  7204. }
  7205. function ___syscall6(which, varargs) {SYSCALLS.varargs = varargs;
  7206. try {
  7207. // close
  7208. var stream = SYSCALLS.getStreamFromFD();
  7209. FS.close(stream);
  7210. return 0;
  7211. } catch (e) {
  7212. if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e);
  7213. return -e.errno;
  7214. }
  7215. }
  7216. function _llvm_stacksave() {
  7217. var self = _llvm_stacksave;
  7218. if (!self.LLVM_SAVEDSTACKS) {
  7219. self.LLVM_SAVEDSTACKS = [];
  7220. }
  7221. self.LLVM_SAVEDSTACKS.push(Runtime.stackSave());
  7222. return self.LLVM_SAVEDSTACKS.length-1;
  7223. }
  7224. function _emscripten_glGetVertexAttribiv(index, pname, params) {
  7225. // N.B. This function may only be called if the vertex attribute was specified using the function glVertexAttrib*f(),
  7226. // otherwise the results are undefined. (GLES3 spec 6.1.12)
  7227. emscriptenWebGLGetVertexAttrib(index, pname, params, 'FloatToInteger');
  7228. }
  7229. function _emscripten_glUniformMatrix4fv(location, count, transpose, value) {
  7230. var view;
  7231. if (16*count <= GL.MINI_TEMP_BUFFER_SIZE) {
  7232. // avoid allocation when uploading few enough uniforms
  7233. view = GL.miniTempBufferViews[16*count-1];
  7234. for (var i = 0; i < 16*count; i += 16) {
  7235. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  7236. view[i+1] = HEAPF32[(((value)+(4*i+4))>>2)];
  7237. view[i+2] = HEAPF32[(((value)+(4*i+8))>>2)];
  7238. view[i+3] = HEAPF32[(((value)+(4*i+12))>>2)];
  7239. view[i+4] = HEAPF32[(((value)+(4*i+16))>>2)];
  7240. view[i+5] = HEAPF32[(((value)+(4*i+20))>>2)];
  7241. view[i+6] = HEAPF32[(((value)+(4*i+24))>>2)];
  7242. view[i+7] = HEAPF32[(((value)+(4*i+28))>>2)];
  7243. view[i+8] = HEAPF32[(((value)+(4*i+32))>>2)];
  7244. view[i+9] = HEAPF32[(((value)+(4*i+36))>>2)];
  7245. view[i+10] = HEAPF32[(((value)+(4*i+40))>>2)];
  7246. view[i+11] = HEAPF32[(((value)+(4*i+44))>>2)];
  7247. view[i+12] = HEAPF32[(((value)+(4*i+48))>>2)];
  7248. view[i+13] = HEAPF32[(((value)+(4*i+52))>>2)];
  7249. view[i+14] = HEAPF32[(((value)+(4*i+56))>>2)];
  7250. view[i+15] = HEAPF32[(((value)+(4*i+60))>>2)];
  7251. }
  7252. } else {
  7253. view = HEAPF32.subarray((value)>>2,(value+count*64)>>2);
  7254. }
  7255. GLctx.uniformMatrix4fv(GL.uniforms[location], !!transpose, view);
  7256. }
  7257. function _emscripten_glDrawArraysInstanced(mode, first, count, primcount) {
  7258. GLctx['drawArraysInstanced'](mode, first, count, primcount);
  7259. }
  7260. function _emscripten_glEnableClientState() {
  7261. Module['printErr']('missing function: emscripten_glEnableClientState'); abort(-1);
  7262. }
  7263. function _emscripten_glGetPointerv() {
  7264. Module['printErr']('missing function: emscripten_glGetPointerv'); abort(-1);
  7265. }
  7266. function ___syscall140(which, varargs) {SYSCALLS.varargs = varargs;
  7267. try {
  7268. // llseek
  7269. var stream = SYSCALLS.getStreamFromFD(), offset_high = SYSCALLS.get(), offset_low = SYSCALLS.get(), result = SYSCALLS.get(), whence = SYSCALLS.get();
  7270. var offset = offset_low;
  7271. assert(offset_high === 0);
  7272. FS.llseek(stream, offset, whence);
  7273. HEAP32[((result)>>2)]=stream.position;
  7274. if (stream.getdents && offset === 0 && whence === 0) stream.getdents = null; // reset readdir state
  7275. return 0;
  7276. } catch (e) {
  7277. if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e);
  7278. return -e.errno;
  7279. }
  7280. }
  7281. function ___syscall146(which, varargs) {SYSCALLS.varargs = varargs;
  7282. try {
  7283. // writev
  7284. var stream = SYSCALLS.getStreamFromFD(), iov = SYSCALLS.get(), iovcnt = SYSCALLS.get();
  7285. return SYSCALLS.doWritev(stream, iov, iovcnt);
  7286. } catch (e) {
  7287. if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e);
  7288. return -e.errno;
  7289. }
  7290. }
  7291. function _emscripten_glUniform1i(location, v0) {
  7292. GLctx.uniform1i(GL.uniforms[location], v0);
  7293. }
  7294. function ___syscall145(which, varargs) {SYSCALLS.varargs = varargs;
  7295. try {
  7296. // readv
  7297. var stream = SYSCALLS.getStreamFromFD(), iov = SYSCALLS.get(), iovcnt = SYSCALLS.get();
  7298. return SYSCALLS.doReadv(stream, iov, iovcnt);
  7299. } catch (e) {
  7300. if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e);
  7301. return -e.errno;
  7302. }
  7303. }
  7304. function _emscripten_glStencilMask(x0) { GLctx['stencilMask'](x0) }
  7305. function _emscripten_glStencilFuncSeparate(x0, x1, x2, x3) { GLctx['stencilFuncSeparate'](x0, x1, x2, x3) }
  7306. Module["_i64Subtract"] = _i64Subtract;
  7307. Module["_i64Add"] = _i64Add;
  7308. function _emscripten_set_touchend_callback(target, userData, useCapture, callbackfunc) {
  7309. JSEvents.registerTouchEventCallback(target, userData, useCapture, callbackfunc, 23, "touchend");
  7310. return 0;
  7311. }
  7312. function _glUseProgram(program) {
  7313. GLctx.useProgram(program ? GL.programs[program] : null);
  7314. }
  7315. function _emscripten_glDisableVertexAttribArray(index) {
  7316. GLctx.disableVertexAttribArray(index);
  7317. }
  7318. function _emscripten_glVertexAttrib1f(x0, x1) { GLctx['vertexAttrib1f'](x0, x1) }
  7319. function _emscripten_glFinish() { GLctx['finish']() }
  7320. function _glDrawArrays(mode, first, count) {
  7321. GLctx.drawArrays(mode, first, count);
  7322. }
  7323. function _emscripten_glDepthFunc(x0) { GLctx['depthFunc'](x0) }
  7324. function _emscripten_get_num_gamepads() {
  7325. // Polling gamepads generates garbage, so don't do it when we know there are no gamepads connected.
  7326. if (!JSEvents.numGamepadsConnected) return 0;
  7327. __emscripten_sample_gamepad_data();
  7328. if (!JSEvents.lastGamepadState) return -1;
  7329. return JSEvents.lastGamepadState.length;
  7330. }
  7331. function _glGetProgramInfoLog(program, maxLength, length, infoLog) {
  7332. var log = GLctx.getProgramInfoLog(GL.programs[program]);
  7333. if (log === null) log = '(unknown error)';
  7334. if (maxLength > 0 && infoLog) {
  7335. var numBytesWrittenExclNull = stringToUTF8(log, infoLog, maxLength);
  7336. if (length) HEAP32[((length)>>2)]=numBytesWrittenExclNull;
  7337. } else {
  7338. if (length) HEAP32[((length)>>2)]=0;
  7339. }
  7340. }
  7341. function _emscripten_glUniform4iv(location, count, value) {
  7342. GLctx.uniform4iv(GL.uniforms[location], HEAP32.subarray((value)>>2,(value+count*16)>>2));
  7343. }
  7344. function _glClear(x0) { GLctx['clear'](x0) }
  7345. function _emscripten_glLoadIdentity(){ throw 'Legacy GL function (glLoadIdentity) called. If you want legacy GL emulation, you need to compile with -s LEGACY_GL_EMULATION=1 to enable legacy GL emulation.'; }
  7346. function _emscripten_glUniform3fv(location, count, value) {
  7347. var view;
  7348. if (3*count <= GL.MINI_TEMP_BUFFER_SIZE) {
  7349. // avoid allocation when uploading few enough uniforms
  7350. view = GL.miniTempBufferViews[3*count-1];
  7351. for (var i = 0; i < 3*count; i += 3) {
  7352. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  7353. view[i+1] = HEAPF32[(((value)+(4*i+4))>>2)];
  7354. view[i+2] = HEAPF32[(((value)+(4*i+8))>>2)];
  7355. }
  7356. } else {
  7357. view = HEAPF32.subarray((value)>>2,(value+count*12)>>2);
  7358. }
  7359. GLctx.uniform3fv(GL.uniforms[location], view);
  7360. }
  7361. function _emscripten_glIsTexture(texture) {
  7362. var texture = GL.textures[texture];
  7363. if (!texture) return 0;
  7364. return GLctx.isTexture(texture);
  7365. }
  7366. function _glEnableVertexAttribArray(index) {
  7367. GLctx.enableVertexAttribArray(index);
  7368. }
  7369. function _emscripten_glAttachShader(program, shader) {
  7370. GLctx.attachShader(GL.programs[program],
  7371. GL.shaders[shader]);
  7372. }
  7373. function _glUniform4f(location, v0, v1, v2, v3) {
  7374. GLctx.uniform4f(GL.uniforms[location], v0, v1, v2, v3);
  7375. }
  7376. function _emscripten_request_pointerlock(target, deferUntilInEventHandler) {
  7377. if (!target) target = '#canvas';
  7378. target = JSEvents.findEventTarget(target);
  7379. if (!target) return -4;
  7380. if (!target.requestPointerLock && !target.mozRequestPointerLock && !target.webkitRequestPointerLock && !target.msRequestPointerLock) {
  7381. return -1;
  7382. }
  7383. var canPerformRequests = JSEvents.canPerformEventHandlerRequests();
  7384. // Queue this function call if we're not currently in an event handler and the user saw it appropriate to do so.
  7385. if (!canPerformRequests) {
  7386. if (deferUntilInEventHandler) {
  7387. JSEvents.deferCall(JSEvents.requestPointerLock, 2 /* priority below fullscreen */, [target]);
  7388. return 1;
  7389. } else {
  7390. return -2;
  7391. }
  7392. }
  7393. return JSEvents.requestPointerLock(target);
  7394. }
  7395. function _emscripten_glVertexAttrib2f(x0, x1, x2) { GLctx['vertexAttrib2f'](x0, x1, x2) }
  7396. function _glfwCreateWindow(width, height, title, monitor, share) {
  7397. return GLFW.createWindow(width, height, title, monitor, share);
  7398. }
  7399. function _glfwDefaultWindowHints() {
  7400. GLFW.hints = GLFW.defaultHints;
  7401. }
  7402. function _emscripten_glClearStencil(x0) { GLctx['clearStencil'](x0) }
  7403. function _emscripten_glDetachShader(program, shader) {
  7404. GLctx.detachShader(GL.programs[program],
  7405. GL.shaders[shader]);
  7406. }
  7407. function _emscripten_glDeleteVertexArrays(n, vaos) {
  7408. for (var i = 0; i < n; i++) {
  7409. var id = HEAP32[(((vaos)+(i*4))>>2)];
  7410. GLctx['deleteVertexArray'](GL.vaos[id]);
  7411. GL.vaos[id] = null;
  7412. }
  7413. }
  7414. function _glfwInit() {
  7415. if (GLFW.windows) return 1; // GL_TRUE
  7416. GLFW.initialTime = GLFW.getTime();
  7417. GLFW.hints = GLFW.defaultHints;
  7418. GLFW.windows = new Array()
  7419. GLFW.active = null;
  7420. window.addEventListener("keydown", GLFW.onKeydown, true);
  7421. window.addEventListener("keypress", GLFW.onKeyPress, true);
  7422. window.addEventListener("keyup", GLFW.onKeyup, true);
  7423. Module["canvas"].addEventListener("mousemove", GLFW.onMousemove, true);
  7424. Module["canvas"].addEventListener("mousedown", GLFW.onMouseButtonDown, true);
  7425. Module["canvas"].addEventListener("mouseup", GLFW.onMouseButtonUp, true);
  7426. Module["canvas"].addEventListener('wheel', GLFW.onMouseWheel, true);
  7427. Module["canvas"].addEventListener('mousewheel', GLFW.onMouseWheel, true);
  7428. Module["canvas"].addEventListener('mouseenter', GLFW.onMouseenter, true);
  7429. Module["canvas"].addEventListener('mouseleave', GLFW.onMouseleave, true);
  7430. Browser.resizeListeners.push(function(width, height) {
  7431. GLFW.onCanvasResize(width, height);
  7432. });
  7433. return 1; // GL_TRUE
  7434. }
  7435. function _emscripten_glGetTexParameteriv(target, pname, params) {
  7436. if (!params) {
  7437. // GLES2 specification does not specify how to behave if params is a null pointer. Since calling this function does not make sense
  7438. // if p == null, issue a GL error to notify user about it.
  7439. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7440. return;
  7441. }
  7442. HEAP32[((params)>>2)]=GLctx.getTexParameter(target, pname);
  7443. }
  7444. function _glfwSwapBuffers(winid) {
  7445. GLFW.swapBuffers(winid);
  7446. }
  7447. function _emscripten_glGenerateMipmap(x0) { GLctx['generateMipmap'](x0) }
  7448. function _emscripten_glCullFace(x0) { GLctx['cullFace'](x0) }
  7449. function _emscripten_glUniform4f(location, v0, v1, v2, v3) {
  7450. GLctx.uniform4f(GL.uniforms[location], v0, v1, v2, v3);
  7451. }
  7452. function _glDisableVertexAttribArray(index) {
  7453. GLctx.disableVertexAttribArray(index);
  7454. }
  7455. function _emscripten_glUseProgram(program) {
  7456. GLctx.useProgram(program ? GL.programs[program] : null);
  7457. }
  7458. function _emscripten_glHint(x0, x1) { GLctx['hint'](x0, x1) }
  7459. function _emscripten_glUniform2fv(location, count, value) {
  7460. var view;
  7461. if (2*count <= GL.MINI_TEMP_BUFFER_SIZE) {
  7462. // avoid allocation when uploading few enough uniforms
  7463. view = GL.miniTempBufferViews[2*count-1];
  7464. for (var i = 0; i < 2*count; i += 2) {
  7465. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  7466. view[i+1] = HEAPF32[(((value)+(4*i+4))>>2)];
  7467. }
  7468. } else {
  7469. view = HEAPF32.subarray((value)>>2,(value+count*8)>>2);
  7470. }
  7471. GLctx.uniform2fv(GL.uniforms[location], view);
  7472. }
  7473. function _glfwSwapInterval(interval) {
  7474. interval = Math.abs(interval); // GLFW uses negative values to enable GLX_EXT_swap_control_tear, which we don't have, so just treat negative and positive the same.
  7475. if (interval == 0) _emscripten_set_main_loop_timing(0/*EM_TIMING_SETTIMEOUT*/, 0);
  7476. else _emscripten_set_main_loop_timing(1/*EM_TIMING_RAF*/, interval);
  7477. }
  7478. function _glGetShaderInfoLog(shader, maxLength, length, infoLog) {
  7479. var log = GLctx.getShaderInfoLog(GL.shaders[shader]);
  7480. if (log === null) log = '(unknown error)';
  7481. if (maxLength > 0 && infoLog) {
  7482. var numBytesWrittenExclNull = stringToUTF8(log, infoLog, maxLength);
  7483. if (length) HEAP32[((length)>>2)]=numBytesWrittenExclNull;
  7484. } else {
  7485. if (length) HEAP32[((length)>>2)]=0;
  7486. }
  7487. }
  7488. function _emscripten_glMatrixMode(){ throw 'Legacy GL function (glMatrixMode) called. If you want legacy GL emulation, you need to compile with -s LEGACY_GL_EMULATION=1 to enable legacy GL emulation.'; }
  7489. function _abort() {
  7490. Module['abort']();
  7491. }
  7492. function _emscripten_glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer) {
  7493. GLctx.framebufferRenderbuffer(target, attachment, renderbuffertarget,
  7494. GL.renderbuffers[renderbuffer]);
  7495. }
  7496. function _emscripten_glDeleteFramebuffers(n, framebuffers) {
  7497. for (var i = 0; i < n; ++i) {
  7498. var id = HEAP32[(((framebuffers)+(i*4))>>2)];
  7499. var framebuffer = GL.framebuffers[id];
  7500. if (!framebuffer) continue; // GL spec: "glDeleteFramebuffers silently ignores 0s and names that do not correspond to existing framebuffer objects".
  7501. GLctx.deleteFramebuffer(framebuffer);
  7502. framebuffer.name = 0;
  7503. GL.framebuffers[id] = null;
  7504. }
  7505. }
  7506. function _emscripten_glIsBuffer(buffer) {
  7507. var b = GL.buffers[buffer];
  7508. if (!b) return 0;
  7509. return GLctx.isBuffer(b);
  7510. }
  7511. function _emscripten_glUniform2iv(location, count, value) {
  7512. GLctx.uniform2iv(GL.uniforms[location], HEAP32.subarray((value)>>2,(value+count*8)>>2));
  7513. }
  7514. function _emscripten_glVertexAttrib1fv(index, v) {
  7515. GLctx.vertexAttrib1f(index, HEAPF32[v>>2]);
  7516. }
  7517. function _glEnable(x0) { GLctx['enable'](x0) }
  7518. function emscriptenWebGLComputeImageSize(width, height, sizePerPixel, alignment) {
  7519. function roundedToNextMultipleOf(x, y) {
  7520. return Math.floor((x + y - 1) / y) * y
  7521. }
  7522. var plainRowSize = width * sizePerPixel;
  7523. var alignedRowSize = roundedToNextMultipleOf(plainRowSize, alignment);
  7524. return (height <= 0) ? 0 :
  7525. ((height - 1) * alignedRowSize + plainRowSize);
  7526. }function emscriptenWebGLGetTexPixelData(type, format, width, height, pixels, internalFormat) {
  7527. var sizePerPixel;
  7528. var numChannels;
  7529. switch(format) {
  7530. case 0x1906 /* GL_ALPHA */:
  7531. case 0x1909 /* GL_LUMINANCE */:
  7532. case 0x1902 /* GL_DEPTH_COMPONENT */:
  7533. numChannels = 1;
  7534. break;
  7535. case 0x190A /* GL_LUMINANCE_ALPHA */:
  7536. numChannels = 2;
  7537. break;
  7538. case 0x1907 /* GL_RGB */:
  7539. case 0x8C40 /* GL_SRGB_EXT */:
  7540. numChannels = 3;
  7541. break;
  7542. case 0x1908 /* GL_RGBA */:
  7543. case 0x8C42 /* GL_SRGB_ALPHA_EXT */:
  7544. numChannels = 4;
  7545. break;
  7546. default:
  7547. GL.recordError(0x0500); // GL_INVALID_ENUM
  7548. return null;
  7549. }
  7550. switch (type) {
  7551. case 0x1401 /* GL_UNSIGNED_BYTE */:
  7552. sizePerPixel = numChannels*1;
  7553. break;
  7554. case 0x1403 /* GL_UNSIGNED_SHORT */:
  7555. case 0x8D61 /* GL_HALF_FLOAT_OES */:
  7556. sizePerPixel = numChannels*2;
  7557. break;
  7558. case 0x1405 /* GL_UNSIGNED_INT */:
  7559. case 0x1406 /* GL_FLOAT */:
  7560. sizePerPixel = numChannels*4;
  7561. break;
  7562. case 0x84FA /* GL_UNSIGNED_INT_24_8_WEBGL/GL_UNSIGNED_INT_24_8 */:
  7563. sizePerPixel = 4;
  7564. break;
  7565. case 0x8363 /* GL_UNSIGNED_SHORT_5_6_5 */:
  7566. case 0x8033 /* GL_UNSIGNED_SHORT_4_4_4_4 */:
  7567. case 0x8034 /* GL_UNSIGNED_SHORT_5_5_5_1 */:
  7568. sizePerPixel = 2;
  7569. break;
  7570. default:
  7571. GL.recordError(0x0500); // GL_INVALID_ENUM
  7572. return null;
  7573. }
  7574. var bytes = emscriptenWebGLComputeImageSize(width, height, sizePerPixel, GL.unpackAlignment);
  7575. switch(type) {
  7576. case 0x1401 /* GL_UNSIGNED_BYTE */:
  7577. return HEAPU8.subarray((pixels),(pixels+bytes));
  7578. case 0x1406 /* GL_FLOAT */:
  7579. return HEAPF32.subarray((pixels)>>2,(pixels+bytes)>>2);
  7580. case 0x1405 /* GL_UNSIGNED_INT */:
  7581. case 0x84FA /* GL_UNSIGNED_INT_24_8_WEBGL/GL_UNSIGNED_INT_24_8 */:
  7582. return HEAPU32.subarray((pixels)>>2,(pixels+bytes)>>2);
  7583. case 0x1403 /* GL_UNSIGNED_SHORT */:
  7584. case 0x8363 /* GL_UNSIGNED_SHORT_5_6_5 */:
  7585. case 0x8033 /* GL_UNSIGNED_SHORT_4_4_4_4 */:
  7586. case 0x8034 /* GL_UNSIGNED_SHORT_5_5_5_1 */:
  7587. case 0x8D61 /* GL_HALF_FLOAT_OES */:
  7588. return HEAPU16.subarray((pixels)>>1,(pixels+bytes)>>1);
  7589. default:
  7590. GL.recordError(0x0500); // GL_INVALID_ENUM
  7591. return null;
  7592. }
  7593. }function _emscripten_glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels) {
  7594. var pixelData = null;
  7595. if (pixels) pixelData = emscriptenWebGLGetTexPixelData(type, format, width, height, pixels, 0);
  7596. GLctx.texSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixelData);
  7597. }
  7598. function _emscripten_glPolygonOffset(x0, x1) { GLctx['polygonOffset'](x0, x1) }
  7599. var _emscripten_asm_const_int=true;
  7600. function _emscripten_glUniform2f(location, v0, v1) {
  7601. GLctx.uniform2f(GL.uniforms[location], v0, v1);
  7602. }
  7603. function _glGetAttribLocation(program, name) {
  7604. program = GL.programs[program];
  7605. name = Pointer_stringify(name);
  7606. return GLctx.getAttribLocation(program, name);
  7607. }
  7608. function _glfwWindowHint(target, hint) {
  7609. GLFW.hints[target] = hint;
  7610. }
  7611. function _emscripten_glUniform2i(location, v0, v1) {
  7612. GLctx.uniform2i(GL.uniforms[location], v0, v1);
  7613. }
  7614. function _glBlendFunc(x0, x1) { GLctx['blendFunc'](x0, x1) }
  7615. function _glCreateProgram() {
  7616. var id = GL.getNewId(GL.programs);
  7617. var program = GLctx.createProgram();
  7618. program.name = id;
  7619. GL.programs[id] = program;
  7620. return id;
  7621. }
  7622. function _emscripten_glDeleteRenderbuffers(n, renderbuffers) {
  7623. for (var i = 0; i < n; i++) {
  7624. var id = HEAP32[(((renderbuffers)+(i*4))>>2)];
  7625. var renderbuffer = GL.renderbuffers[id];
  7626. if (!renderbuffer) continue; // GL spec: "glDeleteRenderbuffers silently ignores 0s and names that do not correspond to existing renderbuffer objects".
  7627. GLctx.deleteRenderbuffer(renderbuffer);
  7628. renderbuffer.name = 0;
  7629. GL.renderbuffers[id] = null;
  7630. }
  7631. }
  7632. function _emscripten_glGetBufferParameteriv(target, value, data) {
  7633. if (!data) {
  7634. // GLES2 specification does not specify how to behave if data is a null pointer. Since calling this function does not make sense
  7635. // if data == null, issue a GL error to notify user about it.
  7636. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7637. return;
  7638. }
  7639. HEAP32[((data)>>2)]=GLctx.getBufferParameter(target, value);
  7640. }
  7641. function emscriptenWebGLGetUniform(program, location, params, type) {
  7642. if (!params) {
  7643. // GLES2 specification does not specify how to behave if params is a null pointer. Since calling this function does not make sense
  7644. // if params == null, issue a GL error to notify user about it.
  7645. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7646. return;
  7647. }
  7648. var data = GLctx.getUniform(GL.programs[program], GL.uniforms[location]);
  7649. if (typeof data == 'number' || typeof data == 'boolean') {
  7650. switch (type) {
  7651. case 'Integer': HEAP32[((params)>>2)]=data; break;
  7652. case 'Float': HEAPF32[((params)>>2)]=data; break;
  7653. default: throw 'internal emscriptenWebGLGetUniform() error, bad type: ' + type;
  7654. }
  7655. } else {
  7656. for (var i = 0; i < data.length; i++) {
  7657. switch (type) {
  7658. case 'Integer': HEAP32[(((params)+(i))>>2)]=data[i]; break;
  7659. case 'Float': HEAPF32[(((params)+(i))>>2)]=data[i]; break;
  7660. default: throw 'internal emscriptenWebGLGetUniform() error, bad type: ' + type;
  7661. }
  7662. }
  7663. }
  7664. }function _emscripten_glGetUniformiv(program, location, params) {
  7665. emscriptenWebGLGetUniform(program, location, params, 'Integer');
  7666. }
  7667. function _emscripten_glDepthMask(flag) {
  7668. GLctx.depthMask(!!flag);
  7669. }
  7670. function _emscripten_glDepthRangef(x0, x1) { GLctx['depthRange'](x0, x1) }
  7671. function _emscripten_glDepthRange(x0, x1) { GLctx['depthRange'](x0, x1) }
  7672. function _emscripten_set_fullscreenchange_callback(target, userData, useCapture, callbackfunc) {
  7673. if (typeof JSEvents.fullscreenEnabled() === 'undefined') return -1;
  7674. if (!target) target = document;
  7675. else {
  7676. target = JSEvents.findEventTarget(target);
  7677. if (!target) return -4;
  7678. }
  7679. JSEvents.registerFullscreenChangeEventCallback(target, userData, useCapture, callbackfunc, 19, "fullscreenchange");
  7680. JSEvents.registerFullscreenChangeEventCallback(target, userData, useCapture, callbackfunc, 19, "mozfullscreenchange");
  7681. JSEvents.registerFullscreenChangeEventCallback(target, userData, useCapture, callbackfunc, 19, "webkitfullscreenchange");
  7682. JSEvents.registerFullscreenChangeEventCallback(target, userData, useCapture, callbackfunc, 19, "msfullscreenchange");
  7683. return 0;
  7684. }
  7685. function _emscripten_glGetShaderPrecisionFormat(shaderType, precisionType, range, precision) {
  7686. var result = GLctx.getShaderPrecisionFormat(shaderType, precisionType);
  7687. HEAP32[((range)>>2)]=result.rangeMin;
  7688. HEAP32[(((range)+(4))>>2)]=result.rangeMax;
  7689. HEAP32[((precision)>>2)]=result.precision;
  7690. }
  7691. function _emscripten_glUniform1fv(location, count, value) {
  7692. var view;
  7693. if (count <= GL.MINI_TEMP_BUFFER_SIZE) {
  7694. // avoid allocation when uploading few enough uniforms
  7695. view = GL.miniTempBufferViews[count-1];
  7696. for (var i = 0; i < count; ++i) {
  7697. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  7698. }
  7699. } else {
  7700. view = HEAPF32.subarray((value)>>2,(value+count*4)>>2);
  7701. }
  7702. GLctx.uniform1fv(GL.uniforms[location], view);
  7703. }
  7704. function _glDeleteBuffers(n, buffers) {
  7705. for (var i = 0; i < n; i++) {
  7706. var id = HEAP32[(((buffers)+(i*4))>>2)];
  7707. var buffer = GL.buffers[id];
  7708. // From spec: "glDeleteBuffers silently ignores 0's and names that do not
  7709. // correspond to existing buffer objects."
  7710. if (!buffer) continue;
  7711. GLctx.deleteBuffer(buffer);
  7712. buffer.name = 0;
  7713. GL.buffers[id] = null;
  7714. if (id == GL.currArrayBuffer) GL.currArrayBuffer = 0;
  7715. if (id == GL.currElementArrayBuffer) GL.currElementArrayBuffer = 0;
  7716. }
  7717. }
  7718. function _emscripten_set_gamepaddisconnected_callback(userData, useCapture, callbackfunc) {
  7719. if (!navigator.getGamepads && !navigator.webkitGetGamepads) return -1;
  7720. JSEvents.registerGamepadEventCallback(window, userData, useCapture, callbackfunc, 27, "gamepaddisconnected");
  7721. return 0;
  7722. }
  7723. function _emscripten_glBindProgramARB() {
  7724. Module['printErr']('missing function: emscripten_glBindProgramARB'); abort(-1);
  7725. }
  7726. function _emscripten_glBindTexture(target, texture) {
  7727. GLctx.bindTexture(target, texture ? GL.textures[texture] : null);
  7728. }
  7729. function _emscripten_glCheckFramebufferStatus(x0) { return GLctx['checkFramebufferStatus'](x0) }
  7730. function _emscripten_glDeleteProgram(id) {
  7731. if (!id) return;
  7732. var program = GL.programs[id];
  7733. if (!program) { // glDeleteProgram actually signals an error when deleting a nonexisting object, unlike some other GL delete functions.
  7734. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7735. return;
  7736. }
  7737. GLctx.deleteProgram(program);
  7738. program.name = 0;
  7739. GL.programs[id] = null;
  7740. GL.programInfos[id] = null;
  7741. }
  7742. function _emscripten_glDisable(x0) { GLctx['disable'](x0) }
  7743. function _emscripten_glVertexAttrib3fv(index, v) {
  7744. GLctx.vertexAttrib3f(index, HEAPF32[v>>2], HEAPF32[v+4>>2], HEAPF32[v+8>>2]);
  7745. }
  7746. function _glClearColor(x0, x1, x2, x3) { GLctx['clearColor'](x0, x1, x2, x3) }
  7747. function _emscripten_glGetActiveAttrib(program, index, bufSize, length, size, type, name) {
  7748. program = GL.programs[program];
  7749. var info = GLctx.getActiveAttrib(program, index);
  7750. if (!info) return; // If an error occurs, nothing will be written to length, size and type and name.
  7751. if (bufSize > 0 && name) {
  7752. var numBytesWrittenExclNull = stringToUTF8(info.name, name, bufSize);
  7753. if (length) HEAP32[((length)>>2)]=numBytesWrittenExclNull;
  7754. } else {
  7755. if (length) HEAP32[((length)>>2)]=0;
  7756. }
  7757. if (size) HEAP32[((size)>>2)]=info.size;
  7758. if (type) HEAP32[((type)>>2)]=info.type;
  7759. }
  7760. function _emscripten_glIsFramebuffer(framebuffer) {
  7761. var fb = GL.framebuffers[framebuffer];
  7762. if (!fb) return 0;
  7763. return GLctx.isFramebuffer(fb);
  7764. }
  7765. function _emscripten_glLineWidth(x0) { GLctx['lineWidth'](x0) }
  7766. function _glfwGetCursorPos(winid, x, y) {
  7767. GLFW.getCursorPos(winid, x, y);
  7768. }
  7769. function _emscripten_glGetString(name_) {
  7770. if (GL.stringCache[name_]) return GL.stringCache[name_];
  7771. var ret;
  7772. switch(name_) {
  7773. case 0x1F00 /* GL_VENDOR */:
  7774. case 0x1F01 /* GL_RENDERER */:
  7775. case 0x9245 /* UNMASKED_VENDOR_WEBGL */:
  7776. case 0x9246 /* UNMASKED_RENDERER_WEBGL */:
  7777. ret = allocate(intArrayFromString(GLctx.getParameter(name_)), 'i8', ALLOC_NORMAL);
  7778. break;
  7779. case 0x1F02 /* GL_VERSION */:
  7780. var glVersion = GLctx.getParameter(GLctx.VERSION);
  7781. // return GLES version string corresponding to the version of the WebGL context
  7782. {
  7783. glVersion = 'OpenGL ES 2.0 (' + glVersion + ')';
  7784. }
  7785. ret = allocate(intArrayFromString(glVersion), 'i8', ALLOC_NORMAL);
  7786. break;
  7787. case 0x1F03 /* GL_EXTENSIONS */:
  7788. var exts = GLctx.getSupportedExtensions();
  7789. var gl_exts = [];
  7790. for (var i = 0; i < exts.length; ++i) {
  7791. gl_exts.push(exts[i]);
  7792. gl_exts.push("GL_" + exts[i]);
  7793. }
  7794. ret = allocate(intArrayFromString(gl_exts.join(' ')), 'i8', ALLOC_NORMAL);
  7795. break;
  7796. case 0x8B8C /* GL_SHADING_LANGUAGE_VERSION */:
  7797. var glslVersion = GLctx.getParameter(GLctx.SHADING_LANGUAGE_VERSION);
  7798. // extract the version number 'N.M' from the string 'WebGL GLSL ES N.M ...'
  7799. var ver_re = /^WebGL GLSL ES ([0-9]\.[0-9][0-9]?)(?:$| .*)/;
  7800. var ver_num = glslVersion.match(ver_re);
  7801. if (ver_num !== null) {
  7802. if (ver_num[1].length == 3) ver_num[1] = ver_num[1] + '0'; // ensure minor version has 2 digits
  7803. glslVersion = 'OpenGL ES GLSL ES ' + ver_num[1] + ' (' + glslVersion + ')';
  7804. }
  7805. ret = allocate(intArrayFromString(glslVersion), 'i8', ALLOC_NORMAL);
  7806. break;
  7807. default:
  7808. GL.recordError(0x0500/*GL_INVALID_ENUM*/);
  7809. return 0;
  7810. }
  7811. GL.stringCache[name_] = ret;
  7812. return ret;
  7813. }
  7814. function _emscripten_glGetAttribLocation(program, name) {
  7815. program = GL.programs[program];
  7816. name = Pointer_stringify(name);
  7817. return GLctx.getAttribLocation(program, name);
  7818. }
  7819. function _emscripten_glRotatef() {
  7820. Module['printErr']('missing function: emscripten_glRotatef'); abort(-1);
  7821. }
  7822. function emscriptenWebGLGet(name_, p, type) {
  7823. // Guard against user passing a null pointer.
  7824. // Note that GLES2 spec does not say anything about how passing a null pointer should be treated.
  7825. // Testing on desktop core GL 3, the application crashes on glGetIntegerv to a null pointer, but
  7826. // better to report an error instead of doing anything random.
  7827. if (!p) {
  7828. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7829. return;
  7830. }
  7831. var ret = undefined;
  7832. switch(name_) { // Handle a few trivial GLES values
  7833. case 0x8DFA: // GL_SHADER_COMPILER
  7834. ret = 1;
  7835. break;
  7836. case 0x8DF8: // GL_SHADER_BINARY_FORMATS
  7837. if (type !== 'Integer' && type !== 'Integer64') {
  7838. GL.recordError(0x0500); // GL_INVALID_ENUM
  7839. }
  7840. return; // Do not write anything to the out pointer, since no binary formats are supported.
  7841. case 0x8DF9: // GL_NUM_SHADER_BINARY_FORMATS
  7842. ret = 0;
  7843. break;
  7844. case 0x86A2: // GL_NUM_COMPRESSED_TEXTURE_FORMATS
  7845. // WebGL doesn't have GL_NUM_COMPRESSED_TEXTURE_FORMATS (it's obsolete since GL_COMPRESSED_TEXTURE_FORMATS returns a JS array that can be queried for length),
  7846. // so implement it ourselves to allow C++ GLES2 code get the length.
  7847. var formats = GLctx.getParameter(0x86A3 /*GL_COMPRESSED_TEXTURE_FORMATS*/);
  7848. ret = formats.length;
  7849. break;
  7850. }
  7851. if (ret === undefined) {
  7852. var result = GLctx.getParameter(name_);
  7853. switch (typeof(result)) {
  7854. case "number":
  7855. ret = result;
  7856. break;
  7857. case "boolean":
  7858. ret = result ? 1 : 0;
  7859. break;
  7860. case "string":
  7861. GL.recordError(0x0500); // GL_INVALID_ENUM
  7862. return;
  7863. case "object":
  7864. if (result === null) {
  7865. // null is a valid result for some (e.g., which buffer is bound - perhaps nothing is bound), but otherwise
  7866. // can mean an invalid name_, which we need to report as an error
  7867. switch(name_) {
  7868. case 0x8894: // ARRAY_BUFFER_BINDING
  7869. case 0x8B8D: // CURRENT_PROGRAM
  7870. case 0x8895: // ELEMENT_ARRAY_BUFFER_BINDING
  7871. case 0x8CA6: // FRAMEBUFFER_BINDING
  7872. case 0x8CA7: // RENDERBUFFER_BINDING
  7873. case 0x8069: // TEXTURE_BINDING_2D
  7874. case 0x8514: { // TEXTURE_BINDING_CUBE_MAP
  7875. ret = 0;
  7876. break;
  7877. }
  7878. default: {
  7879. GL.recordError(0x0500); // GL_INVALID_ENUM
  7880. return;
  7881. }
  7882. }
  7883. } else if (result instanceof Float32Array ||
  7884. result instanceof Uint32Array ||
  7885. result instanceof Int32Array ||
  7886. result instanceof Array) {
  7887. for (var i = 0; i < result.length; ++i) {
  7888. switch (type) {
  7889. case 'Integer': HEAP32[(((p)+(i*4))>>2)]=result[i]; break;
  7890. case 'Float': HEAPF32[(((p)+(i*4))>>2)]=result[i]; break;
  7891. case 'Boolean': HEAP8[(((p)+(i))>>0)]=result[i] ? 1 : 0; break;
  7892. default: throw 'internal glGet error, bad type: ' + type;
  7893. }
  7894. }
  7895. return;
  7896. } else if (result instanceof WebGLBuffer ||
  7897. result instanceof WebGLProgram ||
  7898. result instanceof WebGLFramebuffer ||
  7899. result instanceof WebGLRenderbuffer ||
  7900. result instanceof WebGLTexture) {
  7901. ret = result.name | 0;
  7902. } else {
  7903. GL.recordError(0x0500); // GL_INVALID_ENUM
  7904. return;
  7905. }
  7906. break;
  7907. default:
  7908. GL.recordError(0x0500); // GL_INVALID_ENUM
  7909. return;
  7910. }
  7911. }
  7912. switch (type) {
  7913. case 'Integer64': (tempI64 = [ret>>>0,(tempDouble=ret,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[((p)>>2)]=tempI64[0],HEAP32[(((p)+(4))>>2)]=tempI64[1]); break;
  7914. case 'Integer': HEAP32[((p)>>2)]=ret; break;
  7915. case 'Float': HEAPF32[((p)>>2)]=ret; break;
  7916. case 'Boolean': HEAP8[((p)>>0)]=ret ? 1 : 0; break;
  7917. default: throw 'internal glGet error, bad type: ' + type;
  7918. }
  7919. }function _emscripten_glGetIntegerv(name_, p) {
  7920. emscriptenWebGLGet(name_, p, 'Integer');
  7921. }
  7922. function _emscripten_glGetFramebufferAttachmentParameteriv(target, attachment, pname, params) {
  7923. var result = GLctx.getFramebufferAttachmentParameter(target, attachment, pname);
  7924. HEAP32[((params)>>2)]=result;
  7925. }
  7926. function _llvm_stackrestore(p) {
  7927. var self = _llvm_stacksave;
  7928. var ret = self.LLVM_SAVEDSTACKS[p];
  7929. self.LLVM_SAVEDSTACKS.splice(p, 1);
  7930. Runtime.stackRestore(ret);
  7931. }
  7932. function _glfwSetWindowShouldClose(winid, value) {
  7933. var win = GLFW.WindowFromId(winid);
  7934. if (!win) return;
  7935. win.shouldClose = value;
  7936. }
  7937. function _emscripten_glClientActiveTexture() {
  7938. Module['printErr']('missing function: emscripten_glClientActiveTexture'); abort(-1);
  7939. }
  7940. function _glGenBuffers(n, buffers) {
  7941. for (var i = 0; i < n; i++) {
  7942. var buffer = GLctx.createBuffer();
  7943. if (!buffer) {
  7944. GL.recordError(0x0502 /* GL_INVALID_OPERATION */);
  7945. while(i < n) HEAP32[(((buffers)+(i++*4))>>2)]=0;
  7946. return;
  7947. }
  7948. var id = GL.getNewId(GL.buffers);
  7949. buffer.name = id;
  7950. GL.buffers[id] = buffer;
  7951. HEAP32[(((buffers)+(i*4))>>2)]=id;
  7952. }
  7953. }
  7954. function _emscripten_memcpy_big(dest, src, num) {
  7955. HEAPU8.set(HEAPU8.subarray(src, src+num), dest);
  7956. return dest;
  7957. }
  7958. Module["_memcpy"] = _memcpy;
  7959. function _emscripten_glGetShaderInfoLog(shader, maxLength, length, infoLog) {
  7960. var log = GLctx.getShaderInfoLog(GL.shaders[shader]);
  7961. if (log === null) log = '(unknown error)';
  7962. if (maxLength > 0 && infoLog) {
  7963. var numBytesWrittenExclNull = stringToUTF8(log, infoLog, maxLength);
  7964. if (length) HEAP32[((length)>>2)]=numBytesWrittenExclNull;
  7965. } else {
  7966. if (length) HEAP32[((length)>>2)]=0;
  7967. }
  7968. }
  7969. function _glfwGetTime() {
  7970. return GLFW.getTime() - GLFW.initialTime;
  7971. }
  7972. function _emscripten_glGetRenderbufferParameteriv(target, pname, params) {
  7973. if (!params) {
  7974. // GLES2 specification does not specify how to behave if params is a null pointer. Since calling this function does not make sense
  7975. // if params == null, issue a GL error to notify user about it.
  7976. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  7977. return;
  7978. }
  7979. HEAP32[((params)>>2)]=GLctx.getRenderbufferParameter(target, pname);
  7980. }
  7981. function _emscripten_glStencilOpSeparate(x0, x1, x2, x3) { GLctx['stencilOpSeparate'](x0, x1, x2, x3) }
  7982. function _emscripten_glReadPixels(x, y, width, height, format, type, pixels) {
  7983. var pixelData = emscriptenWebGLGetTexPixelData(type, format, width, height, pixels, format);
  7984. if (!pixelData) {
  7985. GL.recordError(0x0500/*GL_INVALID_ENUM*/);
  7986. return;
  7987. }
  7988. GLctx.readPixels(x, y, width, height, format, type, pixelData);
  7989. }
  7990. function _emscripten_glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data) {
  7991. GLctx['compressedTexSubImage2D'](target, level, xoffset, yoffset, width, height, format, data ? HEAPU8.subarray((data),(data+imageSize)) : null);
  7992. }
  7993. function _emscripten_glGetError() {
  7994. // First return any GL error generated by the emscripten library_gl.js interop layer.
  7995. if (GL.lastError) {
  7996. var error = GL.lastError;
  7997. GL.lastError = 0/*GL_NO_ERROR*/;
  7998. return error;
  7999. } else { // If there were none, return the GL error from the browser GL context.
  8000. return GLctx.getError();
  8001. }
  8002. }
  8003. function _emscripten_glFramebufferTexture2D(target, attachment, textarget, texture, level) {
  8004. GLctx.framebufferTexture2D(target, attachment, textarget,
  8005. GL.textures[texture], level);
  8006. }
  8007. function _emscripten_glIsEnabled(x0) { return GLctx['isEnabled'](x0) }
  8008. function _glClearDepthf(x0) { GLctx['clearDepth'](x0) }
  8009. Module["_memmove"] = _memmove;
  8010. function _glGenTextures(n, textures) {
  8011. for (var i = 0; i < n; i++) {
  8012. var texture = GLctx.createTexture();
  8013. if (!texture) {
  8014. GL.recordError(0x0502 /* GL_INVALID_OPERATION */); // GLES + EGL specs don't specify what should happen here, so best to issue an error and create IDs with 0.
  8015. while(i < n) HEAP32[(((textures)+(i++*4))>>2)]=0;
  8016. return;
  8017. }
  8018. var id = GL.getNewId(GL.textures);
  8019. texture.name = id;
  8020. GL.textures[id] = texture;
  8021. HEAP32[(((textures)+(i*4))>>2)]=id;
  8022. }
  8023. }
  8024. function _emscripten_glVertexAttrib4f(x0, x1, x2, x3, x4) { GLctx['vertexAttrib4f'](x0, x1, x2, x3, x4) }
  8025. function _glDepthFunc(x0) { GLctx['depthFunc'](x0) }
  8026. var cttz_i8 = allocate([8,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,7,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,6,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,5,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,4,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0], "i8", ALLOC_STATIC);
  8027. Module["_llvm_cttz_i32"] = _llvm_cttz_i32;
  8028. Module["___udivmoddi4"] = ___udivmoddi4;
  8029. Module["___uremdi3"] = ___uremdi3;
  8030. function _emscripten_glClearDepthf(x0) { GLctx['clearDepth'](x0) }
  8031. function _emscripten_glClear(x0) { GLctx['clear'](x0) }
  8032. function _emscripten_glBindBuffer(target, buffer) {
  8033. var bufferObj = buffer ? GL.buffers[buffer] : null;
  8034. GLctx.bindBuffer(target, bufferObj);
  8035. }
  8036. function _emscripten_glGetUniformfv(program, location, params) {
  8037. emscriptenWebGLGetUniform(program, location, params, 'Float');
  8038. }
  8039. function _glGetProgramiv(program, pname, p) {
  8040. if (!p) {
  8041. // GLES2 specification does not specify how to behave if p is a null pointer. Since calling this function does not make sense
  8042. // if p == null, issue a GL error to notify user about it.
  8043. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  8044. return;
  8045. }
  8046. if (program >= GL.counter) {
  8047. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  8048. return;
  8049. }
  8050. var ptable = GL.programInfos[program];
  8051. if (!ptable) {
  8052. GL.recordError(0x0502 /* GL_INVALID_OPERATION */);
  8053. return;
  8054. }
  8055. if (pname == 0x8B84) { // GL_INFO_LOG_LENGTH
  8056. var log = GLctx.getProgramInfoLog(GL.programs[program]);
  8057. if (log === null) log = '(unknown error)';
  8058. HEAP32[((p)>>2)]=log.length + 1;
  8059. } else if (pname == 0x8B87 /* GL_ACTIVE_UNIFORM_MAX_LENGTH */) {
  8060. HEAP32[((p)>>2)]=ptable.maxUniformLength;
  8061. } else if (pname == 0x8B8A /* GL_ACTIVE_ATTRIBUTE_MAX_LENGTH */) {
  8062. if (ptable.maxAttributeLength == -1) {
  8063. var program = GL.programs[program];
  8064. var numAttribs = GLctx.getProgramParameter(program, GLctx.ACTIVE_ATTRIBUTES);
  8065. ptable.maxAttributeLength = 0; // Spec says if there are no active attribs, 0 must be returned.
  8066. for (var i = 0; i < numAttribs; ++i) {
  8067. var activeAttrib = GLctx.getActiveAttrib(program, i);
  8068. ptable.maxAttributeLength = Math.max(ptable.maxAttributeLength, activeAttrib.name.length+1);
  8069. }
  8070. }
  8071. HEAP32[((p)>>2)]=ptable.maxAttributeLength;
  8072. } else if (pname == 0x8A35 /* GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH */) {
  8073. if (ptable.maxUniformBlockNameLength == -1) {
  8074. var program = GL.programs[program];
  8075. var numBlocks = GLctx.getProgramParameter(program, GLctx.ACTIVE_UNIFORM_BLOCKS);
  8076. ptable.maxUniformBlockNameLength = 0;
  8077. for (var i = 0; i < numBlocks; ++i) {
  8078. var activeBlockName = GLctx.getActiveUniformBlockName(program, i);
  8079. ptable.maxUniformBlockNameLength = Math.max(ptable.maxUniformBlockNameLength, activeBlockName.length+1);
  8080. }
  8081. }
  8082. HEAP32[((p)>>2)]=ptable.maxUniformBlockNameLength;
  8083. } else {
  8084. HEAP32[((p)>>2)]=GLctx.getProgramParameter(GL.programs[program], pname);
  8085. }
  8086. }
  8087. function _glVertexAttribPointer(index, size, type, normalized, stride, ptr) {
  8088. GLctx.vertexAttribPointer(index, size, type, !!normalized, stride, ptr);
  8089. }
  8090. function _emscripten_exit_pointerlock() {
  8091. // Make sure no queued up calls will fire after this.
  8092. JSEvents.removeDeferredCalls(JSEvents.requestPointerLock);
  8093. if (document.exitPointerLock) {
  8094. document.exitPointerLock();
  8095. } else if (document.msExitPointerLock) {
  8096. document.msExitPointerLock();
  8097. } else if (document.mozExitPointerLock) {
  8098. document.mozExitPointerLock();
  8099. } else if (document.webkitExitPointerLock) {
  8100. document.webkitExitPointerLock();
  8101. } else {
  8102. return -1;
  8103. }
  8104. return 0;
  8105. }
  8106. function _glGetUniformLocation(program, name) {
  8107. name = Pointer_stringify(name);
  8108. var arrayOffset = 0;
  8109. // If user passed an array accessor "[index]", parse the array index off the accessor.
  8110. if (name.indexOf(']', name.length-1) !== -1) {
  8111. var ls = name.lastIndexOf('[');
  8112. var arrayIndex = name.slice(ls+1, -1);
  8113. if (arrayIndex.length > 0) {
  8114. arrayOffset = parseInt(arrayIndex);
  8115. if (arrayOffset < 0) {
  8116. return -1;
  8117. }
  8118. }
  8119. name = name.slice(0, ls);
  8120. }
  8121. var ptable = GL.programInfos[program];
  8122. if (!ptable) {
  8123. return -1;
  8124. }
  8125. var utable = ptable.uniforms;
  8126. var uniformInfo = utable[name]; // returns pair [ dimension_of_uniform_array, uniform_location ]
  8127. if (uniformInfo && arrayOffset < uniformInfo[0]) { // Check if user asked for an out-of-bounds element, i.e. for 'vec4 colors[3];' user could ask for 'colors[10]' which should return -1.
  8128. return uniformInfo[1]+arrayOffset;
  8129. } else {
  8130. return -1;
  8131. }
  8132. }
  8133. function _emscripten_glGetAttachedShaders(program, maxCount, count, shaders) {
  8134. var result = GLctx.getAttachedShaders(GL.programs[program]);
  8135. var len = result.length;
  8136. if (len > maxCount) {
  8137. len = maxCount;
  8138. }
  8139. HEAP32[((count)>>2)]=len;
  8140. for (var i = 0; i < len; ++i) {
  8141. var id = GL.shaders.indexOf(result[i]);
  8142. assert(id !== -1, 'shader not bound to local id');
  8143. HEAP32[(((shaders)+(i*4))>>2)]=id;
  8144. }
  8145. }
  8146. function _emscripten_glGenRenderbuffers(n, renderbuffers) {
  8147. for (var i = 0; i < n; i++) {
  8148. var renderbuffer = GLctx.createRenderbuffer();
  8149. if (!renderbuffer) {
  8150. GL.recordError(0x0502 /* GL_INVALID_OPERATION */);
  8151. while(i < n) HEAP32[(((renderbuffers)+(i++*4))>>2)]=0;
  8152. return;
  8153. }
  8154. var id = GL.getNewId(GL.renderbuffers);
  8155. renderbuffer.name = id;
  8156. GL.renderbuffers[id] = renderbuffer;
  8157. HEAP32[(((renderbuffers)+(i*4))>>2)]=id;
  8158. }
  8159. }
  8160. function _emscripten_glFrontFace(x0) { GLctx['frontFace'](x0) }
  8161. function _emscripten_glActiveTexture(x0) { GLctx['activeTexture'](x0) }
  8162. function _emscripten_glUniform1iv(location, count, value) {
  8163. GLctx.uniform1iv(GL.uniforms[location], HEAP32.subarray((value)>>2,(value+count*4)>>2));
  8164. }
  8165. function _emscripten_glTexCoordPointer() {
  8166. Module['printErr']('missing function: emscripten_glTexCoordPointer'); abort(-1);
  8167. }
  8168. function _emscripten_glGetInfoLogARB() {
  8169. Module['printErr']('missing function: emscripten_glGetInfoLogARB'); abort(-1);
  8170. }
  8171. function __exit(status) {
  8172. // void _exit(int status);
  8173. // http://pubs.opengroup.org/onlinepubs/000095399/functions/exit.html
  8174. Module['exit'](status);
  8175. }function _exit(status) {
  8176. __exit(status);
  8177. }
  8178. function _emscripten_glRenderbufferStorage(x0, x1, x2, x3) { GLctx['renderbufferStorage'](x0, x1, x2, x3) }
  8179. function _emscripten_glCopyTexSubImage2D(x0, x1, x2, x3, x4, x5, x6, x7) { GLctx['copyTexSubImage2D'](x0, x1, x2, x3, x4, x5, x6, x7) }
  8180. function _glfwSetCursorPosCallback(winid, cbfun) {
  8181. GLFW.setCursorPosCallback(winid, cbfun);
  8182. }
  8183. function _glBindAttribLocation(program, index, name) {
  8184. name = Pointer_stringify(name);
  8185. GLctx.bindAttribLocation(GL.programs[program], index, name);
  8186. }
  8187. function _emscripten_glShaderBinary() {
  8188. GL.recordError(0x0500/*GL_INVALID_ENUM*/);
  8189. }
  8190. function _emscripten_glIsProgram(program) {
  8191. var program = GL.programs[program];
  8192. if (!program) return 0;
  8193. return GLctx.isProgram(program);
  8194. }
  8195. function _emscripten_glBlendColor(x0, x1, x2, x3) { GLctx['blendColor'](x0, x1, x2, x3) }
  8196. function _emscripten_glGetShaderiv(shader, pname, p) {
  8197. if (!p) {
  8198. // GLES2 specification does not specify how to behave if p is a null pointer. Since calling this function does not make sense
  8199. // if p == null, issue a GL error to notify user about it.
  8200. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  8201. return;
  8202. }
  8203. if (pname == 0x8B84) { // GL_INFO_LOG_LENGTH
  8204. var log = GLctx.getShaderInfoLog(GL.shaders[shader]);
  8205. if (log === null) log = '(unknown error)';
  8206. HEAP32[((p)>>2)]=log.length + 1;
  8207. } else {
  8208. HEAP32[((p)>>2)]=GLctx.getShaderParameter(GL.shaders[shader], pname);
  8209. }
  8210. }
  8211. function _emscripten_glUniformMatrix3fv(location, count, transpose, value) {
  8212. var view;
  8213. if (9*count <= GL.MINI_TEMP_BUFFER_SIZE) {
  8214. // avoid allocation when uploading few enough uniforms
  8215. view = GL.miniTempBufferViews[9*count-1];
  8216. for (var i = 0; i < 9*count; i += 9) {
  8217. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  8218. view[i+1] = HEAPF32[(((value)+(4*i+4))>>2)];
  8219. view[i+2] = HEAPF32[(((value)+(4*i+8))>>2)];
  8220. view[i+3] = HEAPF32[(((value)+(4*i+12))>>2)];
  8221. view[i+4] = HEAPF32[(((value)+(4*i+16))>>2)];
  8222. view[i+5] = HEAPF32[(((value)+(4*i+20))>>2)];
  8223. view[i+6] = HEAPF32[(((value)+(4*i+24))>>2)];
  8224. view[i+7] = HEAPF32[(((value)+(4*i+28))>>2)];
  8225. view[i+8] = HEAPF32[(((value)+(4*i+32))>>2)];
  8226. }
  8227. } else {
  8228. view = HEAPF32.subarray((value)>>2,(value+count*36)>>2);
  8229. }
  8230. GLctx.uniformMatrix3fv(GL.uniforms[location], !!transpose, view);
  8231. }
  8232. Module["___udivdi3"] = ___udivdi3;
  8233. function _emscripten_glUniform4fv(location, count, value) {
  8234. var view;
  8235. if (4*count <= GL.MINI_TEMP_BUFFER_SIZE) {
  8236. // avoid allocation when uploading few enough uniforms
  8237. view = GL.miniTempBufferViews[4*count-1];
  8238. for (var i = 0; i < 4*count; i += 4) {
  8239. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  8240. view[i+1] = HEAPF32[(((value)+(4*i+4))>>2)];
  8241. view[i+2] = HEAPF32[(((value)+(4*i+8))>>2)];
  8242. view[i+3] = HEAPF32[(((value)+(4*i+12))>>2)];
  8243. }
  8244. } else {
  8245. view = HEAPF32.subarray((value)>>2,(value+count*16)>>2);
  8246. }
  8247. GLctx.uniform4fv(GL.uniforms[location], view);
  8248. }
  8249. function _glBufferSubData(target, offset, size, data) {
  8250. GLctx.bufferSubData(target, offset, HEAPU8.subarray(data, data+size));
  8251. }
  8252. function _emscripten_glGenFramebuffers(n, ids) {
  8253. for (var i = 0; i < n; ++i) {
  8254. var framebuffer = GLctx.createFramebuffer();
  8255. if (!framebuffer) {
  8256. GL.recordError(0x0502 /* GL_INVALID_OPERATION */);
  8257. while(i < n) HEAP32[(((ids)+(i++*4))>>2)]=0;
  8258. return;
  8259. }
  8260. var id = GL.getNewId(GL.framebuffers);
  8261. framebuffer.name = id;
  8262. GL.framebuffers[id] = framebuffer;
  8263. HEAP32[(((ids)+(i*4))>>2)]=id;
  8264. }
  8265. }
  8266. function _glGetShaderiv(shader, pname, p) {
  8267. if (!p) {
  8268. // GLES2 specification does not specify how to behave if p is a null pointer. Since calling this function does not make sense
  8269. // if p == null, issue a GL error to notify user about it.
  8270. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  8271. return;
  8272. }
  8273. if (pname == 0x8B84) { // GL_INFO_LOG_LENGTH
  8274. var log = GLctx.getShaderInfoLog(GL.shaders[shader]);
  8275. if (log === null) log = '(unknown error)';
  8276. HEAP32[((p)>>2)]=log.length + 1;
  8277. } else {
  8278. HEAP32[((p)>>2)]=GLctx.getShaderParameter(GL.shaders[shader], pname);
  8279. }
  8280. }
  8281. function _emscripten_glBlendEquationSeparate(x0, x1) { GLctx['blendEquationSeparate'](x0, x1) }
  8282. function _glfwSetWindowIconifyCallback(winid, cbfun) {
  8283. var win = GLFW.WindowFromId(winid);
  8284. if (!win) return;
  8285. win.windowIconifyFunc = cbfun;
  8286. }
  8287. function _emscripten_glDrawRangeElements() {
  8288. Module['printErr']('missing function: emscripten_glDrawRangeElements'); abort(-1);
  8289. }
  8290. function _emscripten_glGenTextures(n, textures) {
  8291. for (var i = 0; i < n; i++) {
  8292. var texture = GLctx.createTexture();
  8293. if (!texture) {
  8294. GL.recordError(0x0502 /* GL_INVALID_OPERATION */); // GLES + EGL specs don't specify what should happen here, so best to issue an error and create IDs with 0.
  8295. while(i < n) HEAP32[(((textures)+(i++*4))>>2)]=0;
  8296. return;
  8297. }
  8298. var id = GL.getNewId(GL.textures);
  8299. texture.name = id;
  8300. GL.textures[id] = texture;
  8301. HEAP32[(((textures)+(i*4))>>2)]=id;
  8302. }
  8303. }
  8304. function _emscripten_glVertexAttrib2fv(index, v) {
  8305. GLctx.vertexAttrib2f(index, HEAPF32[v>>2], HEAPF32[v+4>>2]);
  8306. }
  8307. function _emscripten_glGetActiveUniform(program, index, bufSize, length, size, type, name) {
  8308. program = GL.programs[program];
  8309. var info = GLctx.getActiveUniform(program, index);
  8310. if (!info) return; // If an error occurs, nothing will be written to length, size, type and name.
  8311. if (bufSize > 0 && name) {
  8312. var numBytesWrittenExclNull = stringToUTF8(info.name, name, bufSize);
  8313. if (length) HEAP32[((length)>>2)]=numBytesWrittenExclNull;
  8314. } else {
  8315. if (length) HEAP32[((length)>>2)]=0;
  8316. }
  8317. if (size) HEAP32[((size)>>2)]=info.size;
  8318. if (type) HEAP32[((type)>>2)]=info.type;
  8319. }
  8320. Module["_roundf"] = _roundf;
  8321. function _emscripten_glDeleteObjectARB() {
  8322. Module['printErr']('missing function: emscripten_glDeleteObjectARB'); abort(-1);
  8323. }
  8324. function _emscripten_set_touchmove_callback(target, userData, useCapture, callbackfunc) {
  8325. JSEvents.registerTouchEventCallback(target, userData, useCapture, callbackfunc, 24, "touchmove");
  8326. return 0;
  8327. }
  8328. function _emscripten_glUniform1f(location, v0) {
  8329. GLctx.uniform1f(GL.uniforms[location], v0);
  8330. }
  8331. function _emscripten_glVertexAttribPointer(index, size, type, normalized, stride, ptr) {
  8332. GLctx.vertexAttribPointer(index, size, type, !!normalized, stride, ptr);
  8333. }
  8334. function _glShaderSource(shader, count, string, length) {
  8335. var source = GL.getSource(shader, count, string, length);
  8336. GLctx.shaderSource(GL.shaders[shader], source);
  8337. }
  8338. function _emscripten_glDrawArrays(mode, first, count) {
  8339. GLctx.drawArrays(mode, first, count);
  8340. }
  8341. function _emscripten_glGenBuffers(n, buffers) {
  8342. for (var i = 0; i < n; i++) {
  8343. var buffer = GLctx.createBuffer();
  8344. if (!buffer) {
  8345. GL.recordError(0x0502 /* GL_INVALID_OPERATION */);
  8346. while(i < n) HEAP32[(((buffers)+(i++*4))>>2)]=0;
  8347. return;
  8348. }
  8349. var id = GL.getNewId(GL.buffers);
  8350. buffer.name = id;
  8351. GL.buffers[id] = buffer;
  8352. HEAP32[(((buffers)+(i*4))>>2)]=id;
  8353. }
  8354. }
  8355. function _emscripten_glClearDepth(x0) { GLctx['clearDepth'](x0) }
  8356. function _emscripten_set_keypress_callback(target, userData, useCapture, callbackfunc) {
  8357. JSEvents.registerKeyEventCallback(target, userData, useCapture, callbackfunc, 1, "keypress");
  8358. return 0;
  8359. }
  8360. function _glfwSetCharCallback(winid, cbfun) {
  8361. GLFW.setCharCallback(winid, cbfun);
  8362. }
  8363. function _emscripten_glGetUniformLocation(program, name) {
  8364. name = Pointer_stringify(name);
  8365. var arrayOffset = 0;
  8366. // If user passed an array accessor "[index]", parse the array index off the accessor.
  8367. if (name.indexOf(']', name.length-1) !== -1) {
  8368. var ls = name.lastIndexOf('[');
  8369. var arrayIndex = name.slice(ls+1, -1);
  8370. if (arrayIndex.length > 0) {
  8371. arrayOffset = parseInt(arrayIndex);
  8372. if (arrayOffset < 0) {
  8373. return -1;
  8374. }
  8375. }
  8376. name = name.slice(0, ls);
  8377. }
  8378. var ptable = GL.programInfos[program];
  8379. if (!ptable) {
  8380. return -1;
  8381. }
  8382. var utable = ptable.uniforms;
  8383. var uniformInfo = utable[name]; // returns pair [ dimension_of_uniform_array, uniform_location ]
  8384. if (uniformInfo && arrayOffset < uniformInfo[0]) { // Check if user asked for an out-of-bounds element, i.e. for 'vec4 colors[3];' user could ask for 'colors[10]' which should return -1.
  8385. return uniformInfo[1]+arrayOffset;
  8386. } else {
  8387. return -1;
  8388. }
  8389. }
  8390. function _glBindBuffer(target, buffer) {
  8391. var bufferObj = buffer ? GL.buffers[buffer] : null;
  8392. GLctx.bindBuffer(target, bufferObj);
  8393. }
  8394. function _emscripten_glVertexAttrib4fv(index, v) {
  8395. GLctx.vertexAttrib4f(index, HEAPF32[v>>2], HEAPF32[v+4>>2], HEAPF32[v+8>>2], HEAPF32[v+12>>2]);
  8396. }
  8397. function _emscripten_glScissor(x0, x1, x2, x3) { GLctx['scissor'](x0, x1, x2, x3) }
  8398. function _glfwSetCursorEnterCallback(winid, cbfun) {
  8399. var win = GLFW.WindowFromId(winid);
  8400. if (!win) return;
  8401. win.cursorEnterFunc = cbfun;
  8402. }
  8403. Module["_bitshift64Lshr"] = _bitshift64Lshr;
  8404. function _glBufferData(target, size, data, usage) {
  8405. if (!data) {
  8406. GLctx.bufferData(target, size, usage);
  8407. } else {
  8408. GLctx.bufferData(target, HEAPU8.subarray(data, data+size), usage);
  8409. }
  8410. }
  8411. function _emscripten_glIsShader(shader) {
  8412. var s = GL.shaders[shader];
  8413. if (!s) return 0;
  8414. return GLctx.isShader(s);
  8415. }
  8416. function _emscripten_glDrawBuffers(n, bufs) {
  8417. var bufArray = GL.tempFixedLengthArray[n];
  8418. for (var i = 0; i < n; i++) {
  8419. bufArray[i] = HEAP32[(((bufs)+(i*4))>>2)];
  8420. }
  8421. GLctx['drawBuffers'](bufArray);
  8422. }
  8423. function _glGetFloatv(name_, p) {
  8424. emscriptenWebGLGet(name_, p, 'Float');
  8425. }
  8426. function _emscripten_glBindFramebuffer(target, framebuffer) {
  8427. GLctx.bindFramebuffer(target, framebuffer ? GL.framebuffers[framebuffer] : null);
  8428. }
  8429. function _emscripten_glBlendEquation(x0) { GLctx['blendEquation'](x0) }
  8430. function _emscripten_glBufferSubData(target, offset, size, data) {
  8431. GLctx.bufferSubData(target, offset, HEAPU8.subarray(data, data+size));
  8432. }
  8433. function _emscripten_glBufferData(target, size, data, usage) {
  8434. if (!data) {
  8435. GLctx.bufferData(target, size, usage);
  8436. } else {
  8437. GLctx.bufferData(target, HEAPU8.subarray(data, data+size), usage);
  8438. }
  8439. }
  8440. Module["_sbrk"] = _sbrk;
  8441. Module["_bitshift64Shl"] = _bitshift64Shl;
  8442. function _emscripten_glGetShaderSource(shader, bufSize, length, source) {
  8443. var result = GLctx.getShaderSource(GL.shaders[shader]);
  8444. if (!result) return; // If an error occurs, nothing will be written to length or source.
  8445. if (bufSize > 0 && source) {
  8446. var numBytesWrittenExclNull = stringToUTF8(result, source, bufSize);
  8447. if (length) HEAP32[((length)>>2)]=numBytesWrittenExclNull;
  8448. } else {
  8449. if (length) HEAP32[((length)>>2)]=0;
  8450. }
  8451. }
  8452. Module["_llvm_bswap_i32"] = _llvm_bswap_i32;
  8453. function _emscripten_set_click_callback(target, userData, useCapture, callbackfunc) {
  8454. JSEvents.registerMouseEventCallback(target, userData, useCapture, callbackfunc, 4, "click");
  8455. return 0;
  8456. }
  8457. function _glfwSetKeyCallback(winid, cbfun) {
  8458. GLFW.setKeyCallback(winid, cbfun);
  8459. }
  8460. function _emscripten_set_gamepadconnected_callback(userData, useCapture, callbackfunc) {
  8461. if (!navigator.getGamepads && !navigator.webkitGetGamepads) return -1;
  8462. JSEvents.registerGamepadEventCallback(window, userData, useCapture, callbackfunc, 26, "gamepadconnected");
  8463. return 0;
  8464. }
  8465. function _emscripten_glGetFloatv(name_, p) {
  8466. emscriptenWebGLGet(name_, p, 'Float');
  8467. }
  8468. function _glTexImage2D(target, level, internalFormat, width, height, border, format, type, pixels) {
  8469. var pixelData = null;
  8470. if (pixels) pixelData = emscriptenWebGLGetTexPixelData(type, format, width, height, pixels, internalFormat);
  8471. GLctx.texImage2D(target, level, internalFormat, width, height, border, format, type, pixelData);
  8472. }
  8473. function ___assert_fail(condition, filename, line, func) {
  8474. ABORT = true;
  8475. throw 'Assertion failed: ' + Pointer_stringify(condition) + ', at: ' + [filename ? Pointer_stringify(filename) : 'unknown filename', line, func ? Pointer_stringify(func) : 'unknown function'] + ' at ' + stackTrace();
  8476. }
  8477. function _emscripten_glVertexAttribDivisor(index, divisor) {
  8478. GLctx['vertexAttribDivisor'](index, divisor);
  8479. }
  8480. function _emscripten_glDrawElementsInstanced(mode, count, type, indices, primcount) {
  8481. GLctx['drawElementsInstanced'](mode, count, type, indices, primcount);
  8482. }
  8483. function _emscripten_glDrawElements(mode, count, type, indices) {
  8484. GLctx.drawElements(mode, count, type, indices);
  8485. }
  8486. function _glfwSetMouseButtonCallback(winid, cbfun) {
  8487. GLFW.setMouseButtonCallback(winid, cbfun);
  8488. }
  8489. function _emscripten_glCreateProgram() {
  8490. var id = GL.getNewId(GL.programs);
  8491. var program = GLctx.createProgram();
  8492. program.name = id;
  8493. GL.programs[id] = program;
  8494. return id;
  8495. }
  8496. function _emscripten_glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data) {
  8497. GLctx['compressedTexImage2D'](target, level, internalFormat, width, height, border, data ? HEAPU8.subarray((data),(data+imageSize)) : null);
  8498. }
  8499. function _emscripten_glClearColor(x0, x1, x2, x3) { GLctx['clearColor'](x0, x1, x2, x3) }
  8500. function _emscripten_glBindVertexArray(vao) {
  8501. GLctx['bindVertexArray'](GL.vaos[vao]);
  8502. }
  8503. function _emscripten_glLoadMatrixf() {
  8504. Module['printErr']('missing function: emscripten_glLoadMatrixf'); abort(-1);
  8505. }
  8506. function _glDeleteShader(id) {
  8507. if (!id) return;
  8508. var shader = GL.shaders[id];
  8509. if (!shader) { // glDeleteShader actually signals an error when deleting a nonexisting object, unlike some other GL delete functions.
  8510. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  8511. return;
  8512. }
  8513. GLctx.deleteShader(shader);
  8514. GL.shaders[id] = null;
  8515. }
  8516. function _emscripten_glGetProgramiv(program, pname, p) {
  8517. if (!p) {
  8518. // GLES2 specification does not specify how to behave if p is a null pointer. Since calling this function does not make sense
  8519. // if p == null, issue a GL error to notify user about it.
  8520. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  8521. return;
  8522. }
  8523. if (program >= GL.counter) {
  8524. GL.recordError(0x0501 /* GL_INVALID_VALUE */);
  8525. return;
  8526. }
  8527. var ptable = GL.programInfos[program];
  8528. if (!ptable) {
  8529. GL.recordError(0x0502 /* GL_INVALID_OPERATION */);
  8530. return;
  8531. }
  8532. if (pname == 0x8B84) { // GL_INFO_LOG_LENGTH
  8533. var log = GLctx.getProgramInfoLog(GL.programs[program]);
  8534. if (log === null) log = '(unknown error)';
  8535. HEAP32[((p)>>2)]=log.length + 1;
  8536. } else if (pname == 0x8B87 /* GL_ACTIVE_UNIFORM_MAX_LENGTH */) {
  8537. HEAP32[((p)>>2)]=ptable.maxUniformLength;
  8538. } else if (pname == 0x8B8A /* GL_ACTIVE_ATTRIBUTE_MAX_LENGTH */) {
  8539. if (ptable.maxAttributeLength == -1) {
  8540. var program = GL.programs[program];
  8541. var numAttribs = GLctx.getProgramParameter(program, GLctx.ACTIVE_ATTRIBUTES);
  8542. ptable.maxAttributeLength = 0; // Spec says if there are no active attribs, 0 must be returned.
  8543. for (var i = 0; i < numAttribs; ++i) {
  8544. var activeAttrib = GLctx.getActiveAttrib(program, i);
  8545. ptable.maxAttributeLength = Math.max(ptable.maxAttributeLength, activeAttrib.name.length+1);
  8546. }
  8547. }
  8548. HEAP32[((p)>>2)]=ptable.maxAttributeLength;
  8549. } else if (pname == 0x8A35 /* GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH */) {
  8550. if (ptable.maxUniformBlockNameLength == -1) {
  8551. var program = GL.programs[program];
  8552. var numBlocks = GLctx.getProgramParameter(program, GLctx.ACTIVE_UNIFORM_BLOCKS);
  8553. ptable.maxUniformBlockNameLength = 0;
  8554. for (var i = 0; i < numBlocks; ++i) {
  8555. var activeBlockName = GLctx.getActiveUniformBlockName(program, i);
  8556. ptable.maxUniformBlockNameLength = Math.max(ptable.maxUniformBlockNameLength, activeBlockName.length+1);
  8557. }
  8558. }
  8559. HEAP32[((p)>>2)]=ptable.maxUniformBlockNameLength;
  8560. } else {
  8561. HEAP32[((p)>>2)]=GLctx.getProgramParameter(GL.programs[program], pname);
  8562. }
  8563. }
  8564. function _emscripten_glGetProgramInfoLog(program, maxLength, length, infoLog) {
  8565. var log = GLctx.getProgramInfoLog(GL.programs[program]);
  8566. if (log === null) log = '(unknown error)';
  8567. if (maxLength > 0 && infoLog) {
  8568. var numBytesWrittenExclNull = stringToUTF8(log, infoLog, maxLength);
  8569. if (length) HEAP32[((length)>>2)]=numBytesWrittenExclNull;
  8570. } else {
  8571. if (length) HEAP32[((length)>>2)]=0;
  8572. }
  8573. }
  8574. function _emscripten_glTexImage2D(target, level, internalFormat, width, height, border, format, type, pixels) {
  8575. var pixelData = null;
  8576. if (pixels) pixelData = emscriptenWebGLGetTexPixelData(type, format, width, height, pixels, internalFormat);
  8577. GLctx.texImage2D(target, level, internalFormat, width, height, border, format, type, pixelData);
  8578. }
  8579. function _glPixelStorei(pname, param) {
  8580. if (pname == 0x0D05 /* GL_PACK_ALIGNMENT */) {
  8581. GL.packAlignment = param;
  8582. } else if (pname == 0x0cf5 /* GL_UNPACK_ALIGNMENT */) {
  8583. GL.unpackAlignment = param;
  8584. }
  8585. GLctx.pixelStorei(pname, param);
  8586. }
  8587. function ___unlock() {}
  8588. function _emscripten_glColorPointer() {
  8589. Module['printErr']('missing function: emscripten_glColorPointer'); abort(-1);
  8590. }
  8591. function _glViewport(x0, x1, x2, x3) { GLctx['viewport'](x0, x1, x2, x3) }
  8592. function _glfwDestroyWindow(winid) {
  8593. return GLFW.destroyWindow(winid);
  8594. }
  8595. function _emscripten_glFlush() { GLctx['flush']() }
  8596. function _glfwSetErrorCallback(cbfun) {
  8597. GLFW.errorFunc = cbfun;
  8598. }
  8599. function _emscripten_glCreateShader(shaderType) {
  8600. var id = GL.getNewId(GL.shaders);
  8601. GL.shaders[id] = GLctx.createShader(shaderType);
  8602. return id;
  8603. }
  8604. function _glUniformMatrix4fv(location, count, transpose, value) {
  8605. var view;
  8606. if (16*count <= GL.MINI_TEMP_BUFFER_SIZE) {
  8607. // avoid allocation when uploading few enough uniforms
  8608. view = GL.miniTempBufferViews[16*count-1];
  8609. for (var i = 0; i < 16*count; i += 16) {
  8610. view[i] = HEAPF32[(((value)+(4*i))>>2)];
  8611. view[i+1] = HEAPF32[(((value)+(4*i+4))>>2)];
  8612. view[i+2] = HEAPF32[(((value)+(4*i+8))>>2)];
  8613. view[i+3] = HEAPF32[(((value)+(4*i+12))>>2)];
  8614. view[i+4] = HEAPF32[(((value)+(4*i+16))>>2)];
  8615. view[i+5] = HEAPF32[(((value)+(4*i+20))>>2)];
  8616. view[i+6] = HEAPF32[(((value)+(4*i+24))>>2)];
  8617. view[i+7] = HEAPF32[(((value)+(4*i+28))>>2)];
  8618. view[i+8] = HEAPF32[(((value)+(4*i+32))>>2)];
  8619. view[i+9] = HEAPF32[(((value)+(4*i+36))>>2)];
  8620. view[i+10] = HEAPF32[(((value)+(4*i+40))>>2)];
  8621. view[i+11] = HEAPF32[(((value)+(4*i+44))>>2)];
  8622. view[i+12] = HEAPF32[(((value)+(4*i+48))>>2)];
  8623. view[i+13] = HEAPF32[(((value)+(4*i+52))>>2)];
  8624. view[i+14] = HEAPF32[(((value)+(4*i+56))>>2)];
  8625. view[i+15] = HEAPF32[(((value)+(4*i+60))>>2)];
  8626. }
  8627. } else {
  8628. view = HEAPF32.subarray((value)>>2,(value+count*64)>>2);
  8629. }
  8630. GLctx.uniformMatrix4fv(GL.uniforms[location], !!transpose, view);
  8631. }
  8632. function _emscripten_glValidateProgram(program) {
  8633. GLctx.validateProgram(GL.programs[program]);
  8634. }
  8635. function _glTexParameteri(x0, x1, x2) { GLctx['texParameteri'](x0, x1, x2) }
  8636. function _glFrontFace(x0) { GLctx['frontFace'](x0) }
  8637. function _emscripten_glColorMask(red, green, blue, alpha) {
  8638. GLctx.colorMask(!!red, !!green, !!blue, !!alpha);
  8639. }
  8640. function _emscripten_glPixelStorei(pname, param) {
  8641. if (pname == 0x0D05 /* GL_PACK_ALIGNMENT */) {
  8642. GL.packAlignment = param;
  8643. } else if (pname == 0x0cf5 /* GL_UNPACK_ALIGNMENT */) {
  8644. GL.unpackAlignment = param;
  8645. }
  8646. GLctx.pixelStorei(pname, param);
  8647. }
  8648. function _emscripten_glDeleteTextures(n, textures) {
  8649. for (var i = 0; i < n; i++) {
  8650. var id = HEAP32[(((textures)+(i*4))>>2)];
  8651. var texture = GL.textures[id];
  8652. if (!texture) continue; // GL spec: "glDeleteTextures silently ignores 0s and names that do not correspond to existing textures".
  8653. GLctx.deleteTexture(texture);
  8654. texture.name = 0;
  8655. GL.textures[id] = null;
  8656. }
  8657. }
  8658. function _emscripten_glCompileShader(shader) {
  8659. GLctx.compileShader(GL.shaders[shader]);
  8660. }
  8661. function _emscripten_glGenVertexArrays(n, arrays) {
  8662. for (var i = 0; i < n; i++) {
  8663. var vao = GLctx['createVertexArray']();
  8664. if (!vao) {
  8665. GL.recordError(0x0502 /* GL_INVALID_OPERATION */);
  8666. while(i < n) HEAP32[(((arrays)+(i++*4))>>2)]=0;
  8667. return;
  8668. }
  8669. var id = GL.getNewId(GL.vaos);
  8670. vao.name = id;
  8671. GL.vaos[id] = vao;
  8672. HEAP32[(((arrays)+(i*4))>>2)]=id;
  8673. }
  8674. }
  8675. function _time(ptr) {
  8676. var ret = (Date.now()/1000)|0;
  8677. if (ptr) {
  8678. HEAP32[((ptr)>>2)]=ret;
  8679. }
  8680. return ret;
  8681. }
  8682. function _emscripten_glGetBooleanv(name_, p) {
  8683. emscriptenWebGLGet(name_, p, 'Boolean');
  8684. }
  8685. function ___syscall221(which, varargs) {SYSCALLS.varargs = varargs;
  8686. try {
  8687. // fcntl64
  8688. var stream = SYSCALLS.getStreamFromFD(), cmd = SYSCALLS.get();
  8689. switch (cmd) {
  8690. case 0: {
  8691. var arg = SYSCALLS.get();
  8692. if (arg < 0) {
  8693. return -ERRNO_CODES.EINVAL;
  8694. }
  8695. var newStream;
  8696. newStream = FS.open(stream.path, stream.flags, 0, arg);
  8697. return newStream.fd;
  8698. }
  8699. case 1:
  8700. case 2:
  8701. return 0; // FD_CLOEXEC makes no sense for a single process.
  8702. case 3:
  8703. return stream.flags;
  8704. case 4: {
  8705. var arg = SYSCALLS.get();
  8706. stream.flags |= arg;
  8707. return 0;
  8708. }
  8709. case 12:
  8710. case 12: {
  8711. var arg = SYSCALLS.get();
  8712. var offset = 0;
  8713. // We're always unlocked.
  8714. HEAP16[(((arg)+(offset))>>1)]=2;
  8715. return 0;
  8716. }
  8717. case 13:
  8718. case 14:
  8719. case 13:
  8720. case 14:
  8721. return 0; // Pretend that the locking is successful.
  8722. case 16:
  8723. case 8:
  8724. return -ERRNO_CODES.EINVAL; // These are for sockets. We don't have them fully implemented yet.
  8725. case 9:
  8726. // musl trusts getown return values, due to a bug where they must be, as they overlap with errors. just return -1 here, so fnctl() returns that, and we set errno ourselves.
  8727. ___setErrNo(ERRNO_CODES.EINVAL);
  8728. return -1;
  8729. default: {
  8730. return -ERRNO_CODES.EINVAL;
  8731. }
  8732. }
  8733. } catch (e) {
  8734. if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e);
  8735. return -e.errno;
  8736. }
  8737. }
  8738. var GLctx; GL.init();
  8739. if (ENVIRONMENT_IS_NODE) {
  8740. _emscripten_get_now = function _emscripten_get_now_actual() {
  8741. var t = process['hrtime']();
  8742. return t[0] * 1e3 + t[1] / 1e6;
  8743. };
  8744. } else if (typeof dateNow !== 'undefined') {
  8745. _emscripten_get_now = dateNow;
  8746. } else if (typeof self === 'object' && self['performance'] && typeof self['performance']['now'] === 'function') {
  8747. _emscripten_get_now = function() { return self['performance']['now'](); };
  8748. } else if (typeof performance === 'object' && typeof performance['now'] === 'function') {
  8749. _emscripten_get_now = function() { return performance['now'](); };
  8750. } else {
  8751. _emscripten_get_now = Date.now;
  8752. };
  8753. Module["requestFullScreen"] = function Module_requestFullScreen(lockPointer, resizeCanvas, vrDevice) { Module.printErr("Module.requestFullScreen is deprecated. Please call Module.requestFullscreen instead."); Module["requestFullScreen"] = Module["requestFullscreen"]; Browser.requestFullScreen(lockPointer, resizeCanvas, vrDevice) };
  8754. Module["requestFullscreen"] = function Module_requestFullscreen(lockPointer, resizeCanvas, vrDevice) { Browser.requestFullscreen(lockPointer, resizeCanvas, vrDevice) };
  8755. Module["requestAnimationFrame"] = function Module_requestAnimationFrame(func) { Browser.requestAnimationFrame(func) };
  8756. Module["setCanvasSize"] = function Module_setCanvasSize(width, height, noUpdates) { Browser.setCanvasSize(width, height, noUpdates) };
  8757. Module["pauseMainLoop"] = function Module_pauseMainLoop() { Browser.mainLoop.pause() };
  8758. Module["resumeMainLoop"] = function Module_resumeMainLoop() { Browser.mainLoop.resume() };
  8759. Module["getUserMedia"] = function Module_getUserMedia() { Browser.getUserMedia() }
  8760. Module["createContext"] = function Module_createContext(canvas, useWebGL, setInModule, webGLContextAttributes) { return Browser.createContext(canvas, useWebGL, setInModule, webGLContextAttributes) };
  8761. FS.staticInit();__ATINIT__.unshift(function() { if (!Module["noFSInit"] && !FS.init.initialized) FS.init() });__ATMAIN__.push(function() { FS.ignorePermissions = false });__ATEXIT__.push(function() { FS.quit() });Module["FS_createFolder"] = FS.createFolder;Module["FS_createPath"] = FS.createPath;Module["FS_createDataFile"] = FS.createDataFile;Module["FS_createPreloadedFile"] = FS.createPreloadedFile;Module["FS_createLazyFile"] = FS.createLazyFile;Module["FS_createLink"] = FS.createLink;Module["FS_createDevice"] = FS.createDevice;Module["FS_unlink"] = FS.unlink;;
  8762. __ATINIT__.unshift(function() { TTY.init() });__ATEXIT__.push(function() { TTY.shutdown() });;
  8763. if (ENVIRONMENT_IS_NODE) { var fs = require("fs"); var NODEJS_PATH = require("path"); NODEFS.staticInit(); };
  8764. JSEvents.staticInit();;
  8765. DYNAMICTOP_PTR = allocate(1, "i32", ALLOC_STATIC);
  8766. STACK_BASE = STACKTOP = Runtime.alignMemory(STATICTOP);
  8767. STACK_MAX = STACK_BASE + TOTAL_STACK;
  8768. DYNAMIC_BASE = Runtime.alignMemory(STACK_MAX);
  8769. HEAP32[DYNAMICTOP_PTR>>2] = DYNAMIC_BASE;
  8770. staticSealed = true; // seal the static portion of memory
  8771. assert(DYNAMIC_BASE < TOTAL_MEMORY, "TOTAL_MEMORY not big enough for stack");
  8772. function nullFunc_viiiii(x) { Module["printErr"]("Invalid function pointer called with signature 'viiiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8773. function nullFunc_vd(x) { Module["printErr"]("Invalid function pointer called with signature 'vd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8774. function nullFunc_vid(x) { Module["printErr"]("Invalid function pointer called with signature 'vid'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8775. function nullFunc_vi(x) { Module["printErr"]("Invalid function pointer called with signature 'vi'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8776. function nullFunc_vii(x) { Module["printErr"]("Invalid function pointer called with signature 'vii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8777. function nullFunc_ii(x) { Module["printErr"]("Invalid function pointer called with signature 'ii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8778. function nullFunc_viddd(x) { Module["printErr"]("Invalid function pointer called with signature 'viddd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8779. function nullFunc_vidd(x) { Module["printErr"]("Invalid function pointer called with signature 'vidd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8780. function nullFunc_iiii(x) { Module["printErr"]("Invalid function pointer called with signature 'iiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8781. function nullFunc_viiiiiiii(x) { Module["printErr"]("Invalid function pointer called with signature 'viiiiiiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8782. function nullFunc_viiiiii(x) { Module["printErr"]("Invalid function pointer called with signature 'viiiiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8783. function nullFunc_vdd(x) { Module["printErr"]("Invalid function pointer called with signature 'vdd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8784. function nullFunc_dd(x) { Module["printErr"]("Invalid function pointer called with signature 'dd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8785. function nullFunc_vidddd(x) { Module["printErr"]("Invalid function pointer called with signature 'vidddd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8786. function nullFunc_vdi(x) { Module["printErr"]("Invalid function pointer called with signature 'vdi'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8787. function nullFunc_viiiiiii(x) { Module["printErr"]("Invalid function pointer called with signature 'viiiiiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8788. function nullFunc_viiiiiiiii(x) { Module["printErr"]("Invalid function pointer called with signature 'viiiiiiiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8789. function nullFunc_iii(x) { Module["printErr"]("Invalid function pointer called with signature 'iii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8790. function nullFunc_i(x) { Module["printErr"]("Invalid function pointer called with signature 'i'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8791. function nullFunc_vdddddd(x) { Module["printErr"]("Invalid function pointer called with signature 'vdddddd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8792. function nullFunc_vdddd(x) { Module["printErr"]("Invalid function pointer called with signature 'vdddd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8793. function nullFunc_viii(x) { Module["printErr"]("Invalid function pointer called with signature 'viii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8794. function nullFunc_v(x) { Module["printErr"]("Invalid function pointer called with signature 'v'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8795. function nullFunc_viid(x) { Module["printErr"]("Invalid function pointer called with signature 'viid'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8796. function nullFunc_ddd(x) { Module["printErr"]("Invalid function pointer called with signature 'ddd'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8797. function nullFunc_viiii(x) { Module["printErr"]("Invalid function pointer called with signature 'viiii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this)"); Module["printErr"]("Build with ASSERTIONS=2 for more info.");abort(x) }
  8798. function invoke_viiiii(index,a1,a2,a3,a4,a5) {
  8799. try {
  8800. Module["dynCall_viiiii"](index,a1,a2,a3,a4,a5);
  8801. } catch(e) {
  8802. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8803. Module["setThrew"](1, 0);
  8804. }
  8805. }
  8806. function invoke_vd(index,a1) {
  8807. try {
  8808. Module["dynCall_vd"](index,a1);
  8809. } catch(e) {
  8810. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8811. Module["setThrew"](1, 0);
  8812. }
  8813. }
  8814. function invoke_vid(index,a1,a2) {
  8815. try {
  8816. Module["dynCall_vid"](index,a1,a2);
  8817. } catch(e) {
  8818. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8819. Module["setThrew"](1, 0);
  8820. }
  8821. }
  8822. function invoke_vi(index,a1) {
  8823. try {
  8824. Module["dynCall_vi"](index,a1);
  8825. } catch(e) {
  8826. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8827. Module["setThrew"](1, 0);
  8828. }
  8829. }
  8830. function invoke_vii(index,a1,a2) {
  8831. try {
  8832. Module["dynCall_vii"](index,a1,a2);
  8833. } catch(e) {
  8834. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8835. Module["setThrew"](1, 0);
  8836. }
  8837. }
  8838. function invoke_ii(index,a1) {
  8839. try {
  8840. return Module["dynCall_ii"](index,a1);
  8841. } catch(e) {
  8842. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8843. Module["setThrew"](1, 0);
  8844. }
  8845. }
  8846. function invoke_viddd(index,a1,a2,a3,a4) {
  8847. try {
  8848. Module["dynCall_viddd"](index,a1,a2,a3,a4);
  8849. } catch(e) {
  8850. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8851. Module["setThrew"](1, 0);
  8852. }
  8853. }
  8854. function invoke_vidd(index,a1,a2,a3) {
  8855. try {
  8856. Module["dynCall_vidd"](index,a1,a2,a3);
  8857. } catch(e) {
  8858. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8859. Module["setThrew"](1, 0);
  8860. }
  8861. }
  8862. function invoke_iiii(index,a1,a2,a3) {
  8863. try {
  8864. return Module["dynCall_iiii"](index,a1,a2,a3);
  8865. } catch(e) {
  8866. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8867. Module["setThrew"](1, 0);
  8868. }
  8869. }
  8870. function invoke_viiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8) {
  8871. try {
  8872. Module["dynCall_viiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8);
  8873. } catch(e) {
  8874. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8875. Module["setThrew"](1, 0);
  8876. }
  8877. }
  8878. function invoke_viiiiii(index,a1,a2,a3,a4,a5,a6) {
  8879. try {
  8880. Module["dynCall_viiiiii"](index,a1,a2,a3,a4,a5,a6);
  8881. } catch(e) {
  8882. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8883. Module["setThrew"](1, 0);
  8884. }
  8885. }
  8886. function invoke_vdd(index,a1,a2) {
  8887. try {
  8888. Module["dynCall_vdd"](index,a1,a2);
  8889. } catch(e) {
  8890. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8891. Module["setThrew"](1, 0);
  8892. }
  8893. }
  8894. function invoke_dd(index,a1) {
  8895. try {
  8896. return Module["dynCall_dd"](index,a1);
  8897. } catch(e) {
  8898. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8899. Module["setThrew"](1, 0);
  8900. }
  8901. }
  8902. function invoke_vidddd(index,a1,a2,a3,a4,a5) {
  8903. try {
  8904. Module["dynCall_vidddd"](index,a1,a2,a3,a4,a5);
  8905. } catch(e) {
  8906. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8907. Module["setThrew"](1, 0);
  8908. }
  8909. }
  8910. function invoke_vdi(index,a1,a2) {
  8911. try {
  8912. Module["dynCall_vdi"](index,a1,a2);
  8913. } catch(e) {
  8914. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8915. Module["setThrew"](1, 0);
  8916. }
  8917. }
  8918. function invoke_viiiiiii(index,a1,a2,a3,a4,a5,a6,a7) {
  8919. try {
  8920. Module["dynCall_viiiiiii"](index,a1,a2,a3,a4,a5,a6,a7);
  8921. } catch(e) {
  8922. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8923. Module["setThrew"](1, 0);
  8924. }
  8925. }
  8926. function invoke_viiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9) {
  8927. try {
  8928. Module["dynCall_viiiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9);
  8929. } catch(e) {
  8930. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8931. Module["setThrew"](1, 0);
  8932. }
  8933. }
  8934. function invoke_iii(index,a1,a2) {
  8935. try {
  8936. return Module["dynCall_iii"](index,a1,a2);
  8937. } catch(e) {
  8938. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8939. Module["setThrew"](1, 0);
  8940. }
  8941. }
  8942. function invoke_i(index) {
  8943. try {
  8944. return Module["dynCall_i"](index);
  8945. } catch(e) {
  8946. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8947. Module["setThrew"](1, 0);
  8948. }
  8949. }
  8950. function invoke_vdddddd(index,a1,a2,a3,a4,a5,a6) {
  8951. try {
  8952. Module["dynCall_vdddddd"](index,a1,a2,a3,a4,a5,a6);
  8953. } catch(e) {
  8954. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8955. Module["setThrew"](1, 0);
  8956. }
  8957. }
  8958. function invoke_vdddd(index,a1,a2,a3,a4) {
  8959. try {
  8960. Module["dynCall_vdddd"](index,a1,a2,a3,a4);
  8961. } catch(e) {
  8962. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8963. Module["setThrew"](1, 0);
  8964. }
  8965. }
  8966. function invoke_viii(index,a1,a2,a3) {
  8967. try {
  8968. Module["dynCall_viii"](index,a1,a2,a3);
  8969. } catch(e) {
  8970. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8971. Module["setThrew"](1, 0);
  8972. }
  8973. }
  8974. function invoke_v(index) {
  8975. try {
  8976. Module["dynCall_v"](index);
  8977. } catch(e) {
  8978. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8979. Module["setThrew"](1, 0);
  8980. }
  8981. }
  8982. function invoke_viid(index,a1,a2,a3) {
  8983. try {
  8984. Module["dynCall_viid"](index,a1,a2,a3);
  8985. } catch(e) {
  8986. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8987. Module["setThrew"](1, 0);
  8988. }
  8989. }
  8990. function invoke_ddd(index,a1,a2) {
  8991. try {
  8992. return Module["dynCall_ddd"](index,a1,a2);
  8993. } catch(e) {
  8994. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  8995. Module["setThrew"](1, 0);
  8996. }
  8997. }
  8998. function invoke_viiii(index,a1,a2,a3,a4) {
  8999. try {
  9000. Module["dynCall_viiii"](index,a1,a2,a3,a4);
  9001. } catch(e) {
  9002. if (typeof e !== 'number' && e !== 'longjmp') throw e;
  9003. Module["setThrew"](1, 0);
  9004. }
  9005. }
  9006. Module.asmGlobalArg = { "Math": Math, "Int8Array": Int8Array, "Int16Array": Int16Array, "Int32Array": Int32Array, "Uint8Array": Uint8Array, "Uint16Array": Uint16Array, "Uint32Array": Uint32Array, "Float32Array": Float32Array, "Float64Array": Float64Array, "NaN": NaN, "Infinity": Infinity };
  9007. Module.asmLibraryArg = { "abort": abort, "assert": assert, "enlargeMemory": enlargeMemory, "getTotalMemory": getTotalMemory, "abortOnCannotGrowMemory": abortOnCannotGrowMemory, "abortStackOverflow": abortStackOverflow, "nullFunc_viiiii": nullFunc_viiiii, "nullFunc_vd": nullFunc_vd, "nullFunc_vid": nullFunc_vid, "nullFunc_vi": nullFunc_vi, "nullFunc_vii": nullFunc_vii, "nullFunc_ii": nullFunc_ii, "nullFunc_viddd": nullFunc_viddd, "nullFunc_vidd": nullFunc_vidd, "nullFunc_iiii": nullFunc_iiii, "nullFunc_viiiiiiii": nullFunc_viiiiiiii, "nullFunc_viiiiii": nullFunc_viiiiii, "nullFunc_vdd": nullFunc_vdd, "nullFunc_dd": nullFunc_dd, "nullFunc_vidddd": nullFunc_vidddd, "nullFunc_vdi": nullFunc_vdi, "nullFunc_viiiiiii": nullFunc_viiiiiii, "nullFunc_viiiiiiiii": nullFunc_viiiiiiiii, "nullFunc_iii": nullFunc_iii, "nullFunc_i": nullFunc_i, "nullFunc_vdddddd": nullFunc_vdddddd, "nullFunc_vdddd": nullFunc_vdddd, "nullFunc_viii": nullFunc_viii, "nullFunc_v": nullFunc_v, "nullFunc_viid": nullFunc_viid, "nullFunc_ddd": nullFunc_ddd, "nullFunc_viiii": nullFunc_viiii, "invoke_viiiii": invoke_viiiii, "invoke_vd": invoke_vd, "invoke_vid": invoke_vid, "invoke_vi": invoke_vi, "invoke_vii": invoke_vii, "invoke_ii": invoke_ii, "invoke_viddd": invoke_viddd, "invoke_vidd": invoke_vidd, "invoke_iiii": invoke_iiii, "invoke_viiiiiiii": invoke_viiiiiiii, "invoke_viiiiii": invoke_viiiiii, "invoke_vdd": invoke_vdd, "invoke_dd": invoke_dd, "invoke_vidddd": invoke_vidddd, "invoke_vdi": invoke_vdi, "invoke_viiiiiii": invoke_viiiiiii, "invoke_viiiiiiiii": invoke_viiiiiiiii, "invoke_iii": invoke_iii, "invoke_i": invoke_i, "invoke_vdddddd": invoke_vdddddd, "invoke_vdddd": invoke_vdddd, "invoke_viii": invoke_viii, "invoke_v": invoke_v, "invoke_viid": invoke_viid, "invoke_ddd": invoke_ddd, "invoke_viiii": invoke_viiii, "_emscripten_glGetTexParameterfv": _emscripten_glGetTexParameterfv, "_glUseProgram": _glUseProgram, "_emscripten_glShaderSource": _emscripten_glShaderSource, "_glfwCreateWindow": _glfwCreateWindow, "_emscripten_glReleaseShaderCompiler": _emscripten_glReleaseShaderCompiler, "_emscripten_glBlendFuncSeparate": _emscripten_glBlendFuncSeparate, "_emscripten_glVertexAttribPointer": _emscripten_glVertexAttribPointer, "_emscripten_glGetIntegerv": _emscripten_glGetIntegerv, "_emscripten_glCullFace": _emscripten_glCullFace, "_emscripten_glIsProgram": _emscripten_glIsProgram, "_emscripten_glStencilMaskSeparate": _emscripten_glStencilMaskSeparate, "_emscripten_glViewport": _emscripten_glViewport, "_emscripten_glFrontFace": _emscripten_glFrontFace, "___assert_fail": ___assert_fail, "_glDeleteProgram": _glDeleteProgram, "_emscripten_glUniform3fv": _emscripten_glUniform3fv, "_emscripten_glPolygonOffset": _emscripten_glPolygonOffset, "_emscripten_glUseProgram": _emscripten_glUseProgram, "_emscripten_glBlendColor": _emscripten_glBlendColor, "_glBindBuffer": _glBindBuffer, "_emscripten_glDepthFunc": _emscripten_glDepthFunc, "_glGetShaderInfoLog": _glGetShaderInfoLog, "_emscripten_set_fullscreenchange_callback": _emscripten_set_fullscreenchange_callback, "_emscripten_set_touchmove_callback": _emscripten_set_touchmove_callback, "_emscripten_set_main_loop_timing": _emscripten_set_main_loop_timing, "_emscripten_set_gamepaddisconnected_callback": _emscripten_set_gamepaddisconnected_callback, "_glDisable": _glDisable, "_glBlendFunc": _glBlendFunc, "_emscripten_glDisableVertexAttribArray": _emscripten_glDisableVertexAttribArray, "_glGetAttribLocation": _glGetAttribLocation, "_glDisableVertexAttribArray": _glDisableVertexAttribArray, "_glCreateShader": _glCreateShader, "_emscripten_glSampleCoverage": _emscripten_glSampleCoverage, "_emscripten_glVertexPointer": _emscripten_glVertexPointer, "_emscripten_set_touchstart_callback": _emscripten_set_touchstart_callback, "emscriptenWebGLComputeImageSize": emscriptenWebGLComputeImageSize, "_emscripten_glGetBooleanv": _emscripten_glGetBooleanv, "_emscripten_glGetShaderSource": _emscripten_glGetShaderSource, "_glUniform4f": _glUniform4f, "_llvm_stacksave": _llvm_stacksave, "_emscripten_glUniform1i": _emscripten_glUniform1i, "_emscripten_glStencilFuncSeparate": _emscripten_glStencilFuncSeparate, "_emscripten_glFrustum": _emscripten_glFrustum, "_emscripten_glGenBuffers": _emscripten_glGenBuffers, "_emscripten_glDeleteObjectARB": _emscripten_glDeleteObjectARB, "_glfwSetWindowSizeCallback": _glfwSetWindowSizeCallback, "_emscripten_glGetShaderPrecisionFormat": _emscripten_glGetShaderPrecisionFormat, "_glfwInit": _glfwInit, "_emscripten_glGetPointerv": _emscripten_glGetPointerv, "_glGenBuffers": _glGenBuffers, "_glShaderSource": _glShaderSource, "_emscripten_glGetString": _emscripten_glGetString, "_emscripten_glIsFramebuffer": _emscripten_glIsFramebuffer, "_emscripten_glIsEnabled": _emscripten_glIsEnabled, "_emscripten_glScissor": _emscripten_glScissor, "_emscripten_glVertexAttrib4fv": _emscripten_glVertexAttrib4fv, "_emscripten_glFramebufferTexture2D": _emscripten_glFramebufferTexture2D, "_emscripten_glTexParameteriv": _emscripten_glTexParameteriv, "___syscall145": ___syscall145, "_emscripten_glBindProgramARB": _emscripten_glBindProgramARB, "_emscripten_glStencilOpSeparate": _emscripten_glStencilOpSeparate, "_emscripten_glFramebufferRenderbuffer": _emscripten_glFramebufferRenderbuffer, "___syscall140": ___syscall140, "_glfwSetErrorCallback": _glfwSetErrorCallback, "_glfwDefaultWindowHints": _glfwDefaultWindowHints, "_glfwDestroyWindow": _glfwDestroyWindow, "___syscall146": ___syscall146, "_emscripten_glGetActiveAttrib": _emscripten_glGetActiveAttrib, "_emscripten_glAttachShader": _emscripten_glAttachShader, "_glVertexAttribPointer": _glVertexAttribPointer, "_emscripten_glUniform2i": _emscripten_glUniform2i, "_emscripten_glUniform2f": _emscripten_glUniform2f, "_emscripten_glTexParameterfv": _emscripten_glTexParameterfv, "_emscripten_glUniformMatrix2fv": _emscripten_glUniformMatrix2fv, "_glGetProgramInfoLog": _glGetProgramInfoLog, "_glfwSetScrollCallback": _glfwSetScrollCallback, "_emscripten_glTexParameterf": _emscripten_glTexParameterf, "_emscripten_glGetAttachedShaders": _emscripten_glGetAttachedShaders, "_emscripten_glGenTextures": _emscripten_glGenTextures, "_emscripten_glTexParameteri": _emscripten_glTexParameteri, "_llvm_stackrestore": _llvm_stackrestore, "_glfwMakeContextCurrent": _glfwMakeContextCurrent, "_emscripten_glClear": _emscripten_glClear, "_glDrawElements": _glDrawElements, "_glBufferSubData": _glBufferSubData, "_emscripten_glValidateProgram": _emscripten_glValidateProgram, "_emscripten_glVertexAttrib2fv": _emscripten_glVertexAttrib2fv, "_glViewport": _glViewport, "_emscripten_glUniform4iv": _emscripten_glUniform4iv, "_emscripten_glGetTexParameteriv": _emscripten_glGetTexParameteriv, "___setErrNo": ___setErrNo, "_eglGetProcAddress": _eglGetProcAddress, "_emscripten_glBindAttribLocation": _emscripten_glBindAttribLocation, "_glDeleteTextures": _glDeleteTextures, "_glDepthFunc": _glDepthFunc, "_emscripten_glClientActiveTexture": _emscripten_glClientActiveTexture, "_emscripten_glVertexAttrib2f": _emscripten_glVertexAttrib2f, "_emscripten_glFlush": _emscripten_glFlush, "_emscripten_glCheckFramebufferStatus": _emscripten_glCheckFramebufferStatus, "_emscripten_glGenerateMipmap": _emscripten_glGenerateMipmap, "_emscripten_glGetError": _emscripten_glGetError, "_emscripten_glClearDepthf": _emscripten_glClearDepthf, "_emscripten_glBufferData": _emscripten_glBufferData, "_emscripten_glUniform3i": _emscripten_glUniform3i, "_emscripten_glRotatef": _emscripten_glRotatef, "_emscripten_glDeleteShader": _emscripten_glDeleteShader, "_glEnable": _glEnable, "_emscripten_glReadPixels": _emscripten_glReadPixels, "_emscripten_glMatrixMode": _emscripten_glMatrixMode, "_glGetString": _glGetString, "_emscripten_glClearStencil": _emscripten_glClearStencil, "_emscripten_glGetUniformLocation": _emscripten_glGetUniformLocation, "emscriptenWebGLGet": emscriptenWebGLGet, "_emscripten_glEnableVertexAttribArray": _emscripten_glEnableVertexAttribArray, "_emscripten_glGetAttribLocation": _emscripten_glGetAttribLocation, "_emscripten_get_now": _emscripten_get_now, "_emscripten_glNormalPointer": _emscripten_glNormalPointer, "_glAttachShader": _glAttachShader, "_emscripten_glTexCoordPointer": _emscripten_glTexCoordPointer, "_emscripten_glEnable": _emscripten_glEnable, "_glCreateProgram": _glCreateProgram, "_glUniformMatrix4fv": _glUniformMatrix4fv, "_emscripten_glClearDepth": _emscripten_glClearDepth, "___lock": ___lock, "emscriptenWebGLGetTexPixelData": emscriptenWebGLGetTexPixelData, "___syscall6": ___syscall6, "___syscall5": ___syscall5, "_emscripten_glIsBuffer": _emscripten_glIsBuffer, "_emscripten_glVertexAttrib3f": _emscripten_glVertexAttrib3f, "_time": _time, "_emscripten_glVertexAttrib1f": _emscripten_glVertexAttrib1f, "_emscripten_glGetFramebufferAttachmentParameteriv": _emscripten_glGetFramebufferAttachmentParameteriv, "_emscripten_glBlendEquationSeparate": _emscripten_glBlendEquationSeparate, "_exit": _exit, "_emscripten_glEnableClientState": _emscripten_glEnableClientState, "_emscripten_glUniform4i": _emscripten_glUniform4i, "_emscripten_glDrawRangeElements": _emscripten_glDrawRangeElements, "_glCullFace": _glCullFace, "_llvm_pow_f64": _llvm_pow_f64, "_emscripten_set_keypress_callback": _emscripten_set_keypress_callback, "__emscripten_sample_gamepad_data": __emscripten_sample_gamepad_data, "_emscripten_get_gamepad_status": _emscripten_get_gamepad_status, "_emscripten_glUniform4f": _emscripten_glUniform4f, "_emscripten_glUniform2fv": _emscripten_glUniform2fv, "_glfwGetVideoModes": _glfwGetVideoModes, "_emscripten_set_click_callback": _emscripten_set_click_callback, "_emscripten_glShaderBinary": _emscripten_glShaderBinary, "_emscripten_glDrawElements": _emscripten_glDrawElements, "_emscripten_glBlendFunc": _emscripten_glBlendFunc, "_emscripten_get_num_gamepads": _emscripten_get_num_gamepads, "___syscall221": ___syscall221, "_glCompressedTexImage2D": _glCompressedTexImage2D, "_emscripten_glUniform1iv": _emscripten_glUniform1iv, "_emscripten_glGetVertexAttribPointerv": _emscripten_glGetVertexAttribPointerv, "_glClearDepthf": _glClearDepthf, "_emscripten_glCompressedTexSubImage2D": _emscripten_glCompressedTexSubImage2D, "emscriptenWebGLGetUniform": emscriptenWebGLGetUniform, "_emscripten_glGenRenderbuffers": _emscripten_glGenRenderbuffers, "_emscripten_glDeleteVertexArrays": _emscripten_glDeleteVertexArrays, "_glfwSetWindowShouldClose": _glfwSetWindowShouldClose, "_emscripten_glUniform1fv": _emscripten_glUniform1fv, "_emscripten_glGetActiveUniform": _emscripten_glGetActiveUniform, "_glBindTexture": _glBindTexture, "_emscripten_glUniform3iv": _emscripten_glUniform3iv, "_emscripten_glUniform2iv": _emscripten_glUniform2iv, "_emscripten_glHint": _emscripten_glHint, "_glfwSetCharCallback": _glfwSetCharCallback, "emscriptenWebGLGetVertexAttrib": emscriptenWebGLGetVertexAttrib, "_emscripten_glLoadMatrixf": _emscripten_glLoadMatrixf, "_emscripten_glDeleteProgram": _emscripten_glDeleteProgram, "_emscripten_glDeleteRenderbuffers": _emscripten_glDeleteRenderbuffers, "_emscripten_glDrawElementsInstanced": _emscripten_glDrawElementsInstanced, "_emscripten_glVertexAttrib4f": _emscripten_glVertexAttrib4f, "_glDrawArrays": _glDrawArrays, "_emscripten_glTexSubImage2D": _emscripten_glTexSubImage2D, "_emscripten_memcpy_big": _emscripten_memcpy_big, "_emscripten_glPixelStorei": _emscripten_glPixelStorei, "_glCompileShader": _glCompileShader, "_emscripten_get_pointerlock_status": _emscripten_get_pointerlock_status, "_emscripten_glUniformMatrix3fv": _emscripten_glUniformMatrix3fv, "_emscripten_glColorPointer": _emscripten_glColorPointer, "_emscripten_glGetBufferParameteriv": _emscripten_glGetBufferParameteriv, "_emscripten_glFinish": _emscripten_glFinish, "_emscripten_request_pointerlock": _emscripten_request_pointerlock, "_glGetFloatv": _glGetFloatv, "_emscripten_asm_const_iii": _emscripten_asm_const_iii, "_emscripten_glDepthMask": _emscripten_glDepthMask, "_glfwSetWindowIconifyCallback": _glfwSetWindowIconifyCallback, "_emscripten_glDrawBuffers": _emscripten_glDrawBuffers, "_glfwTerminate": _glfwTerminate, "_glFrontFace": _glFrontFace, "_emscripten_glGetObjectParameterivARB": _emscripten_glGetObjectParameterivARB, "_emscripten_exit_pointerlock": _emscripten_exit_pointerlock, "_glfwSwapInterval": _glfwSwapInterval, "_glUniform1i": _glUniform1i, "_glEnableVertexAttribArray": _glEnableVertexAttribArray, "_emscripten_glStencilFunc": _emscripten_glStencilFunc, "_abort": _abort, "_emscripten_glGetUniformiv": _emscripten_glGetUniformiv, "_glDeleteBuffers": _glDeleteBuffers, "_glBufferData": _glBufferData, "_glTexImage2D": _glTexImage2D, "_emscripten_glGetShaderiv": _emscripten_glGetShaderiv, "_glfwSetKeyCallback": _glfwSetKeyCallback, "_emscripten_glGenFramebuffers": _emscripten_glGenFramebuffers, "_emscripten_glUniformMatrix4fv": _emscripten_glUniformMatrix4fv, "_emscripten_glLoadIdentity": _emscripten_glLoadIdentity, "_glDeleteShader": _glDeleteShader, "_emscripten_glUniform1f": _emscripten_glUniform1f, "_glGetProgramiv": _glGetProgramiv, "_emscripten_glBindFramebuffer": _emscripten_glBindFramebuffer, "_emscripten_glIsRenderbuffer": _emscripten_glIsRenderbuffer, "_glfwGetTime": _glfwGetTime, "_emscripten_glRenderbufferStorage": _emscripten_glRenderbufferStorage, "_emscripten_set_gamepadconnected_callback": _emscripten_set_gamepadconnected_callback, "_emscripten_glGetVertexAttribiv": _emscripten_glGetVertexAttribiv, "_emscripten_glBindVertexArray": _emscripten_glBindVertexArray, "_emscripten_glDrawArraysInstanced": _emscripten_glDrawArraysInstanced, "_emscripten_set_touchcancel_callback": _emscripten_set_touchcancel_callback, "_emscripten_glCreateShader": _emscripten_glCreateShader, "_emscripten_glStencilMask": _emscripten_glStencilMask, "_emscripten_glDeleteTextures": _emscripten_glDeleteTextures, "_emscripten_glBindRenderbuffer": _emscripten_glBindRenderbuffer, "_glfwGetPrimaryMonitor": _glfwGetPrimaryMonitor, "_glLinkProgram": _glLinkProgram, "_emscripten_glVertexAttribDivisor": _emscripten_glVertexAttribDivisor, "_emscripten_set_touchend_callback": _emscripten_set_touchend_callback, "_emscripten_glGetUniformfv": _emscripten_glGetUniformfv, "_emscripten_glGetVertexAttribfv": _emscripten_glGetVertexAttribfv, "_emscripten_glGetRenderbufferParameteriv": _emscripten_glGetRenderbufferParameteriv, "_emscripten_glDeleteFramebuffers": _emscripten_glDeleteFramebuffers, "_glGetShaderiv": _glGetShaderiv, "_emscripten_glVertexAttrib3fv": _emscripten_glVertexAttrib3fv, "_glGetUniformLocation": _glGetUniformLocation, "_emscripten_glGetInfoLogARB": _emscripten_glGetInfoLogARB, "_emscripten_glCompileShader": _emscripten_glCompileShader, "_glClear": _glClear, "_glGenTextures": _glGenTextures, "_emscripten_glDisable": _emscripten_glDisable, "_emscripten_glDepthRangef": _emscripten_glDepthRangef, "__exit": __exit, "_emscripten_glLineWidth": _emscripten_glLineWidth, "_emscripten_glUniform3f": _emscripten_glUniform3f, "_emscripten_glGetShaderInfoLog": _emscripten_glGetShaderInfoLog, "_emscripten_glStencilOp": _emscripten_glStencilOp, "_glBindAttribLocation": _glBindAttribLocation, "_glPixelStorei": _glPixelStorei, "_emscripten_glColorMask": _emscripten_glColorMask, "_emscripten_glLinkProgram": _emscripten_glLinkProgram, "_emscripten_glBlendEquation": _emscripten_glBlendEquation, "_emscripten_glIsTexture": _emscripten_glIsTexture, "_emscripten_glGetProgramiv": _emscripten_glGetProgramiv, "_emscripten_glVertexAttrib1fv": _emscripten_glVertexAttrib1fv, "_emscripten_glBindTexture": _emscripten_glBindTexture, "_glfwSetMouseButtonCallback": _glfwSetMouseButtonCallback, "_glfwGetCursorPos": _glfwGetCursorPos, "_emscripten_glActiveTexture": _emscripten_glActiveTexture, "_emscripten_glDeleteBuffers": _emscripten_glDeleteBuffers, "___syscall54": ___syscall54, "___unlock": ___unlock, "_emscripten_glBufferSubData": _emscripten_glBufferSubData, "_glfwSwapBuffers": _glfwSwapBuffers, "_emscripten_glDepthRange": _emscripten_glDepthRange, "_emscripten_set_main_loop": _emscripten_set_main_loop, "_emscripten_glGetProgramInfoLog": _emscripten_glGetProgramInfoLog, "_glfwWindowHint": _glfwWindowHint, "_emscripten_glIsShader": _emscripten_glIsShader, "_emscripten_glUniform4fv": _emscripten_glUniform4fv, "_emscripten_glGenVertexArrays": _emscripten_glGenVertexArrays, "_emscripten_glDrawArrays": _emscripten_glDrawArrays, "_emscripten_glCompressedTexImage2D": _emscripten_glCompressedTexImage2D, "_emscripten_glClearColor": _emscripten_glClearColor, "_emscripten_glCreateProgram": _emscripten_glCreateProgram, "_emscripten_glCopyTexSubImage2D": _emscripten_glCopyTexSubImage2D, "_glTexParameteri": _glTexParameteri, "_emscripten_glBindBuffer": _emscripten_glBindBuffer, "_emscripten_glGetFloatv": _emscripten_glGetFloatv, "_emscripten_glDetachShader": _emscripten_glDetachShader, "_glClearColor": _glClearColor, "_glfwSetCursorPosCallback": _glfwSetCursorPosCallback, "_glfwSetCursorEnterCallback": _glfwSetCursorEnterCallback, "_emscripten_glCopyTexImage2D": _emscripten_glCopyTexImage2D, "_emscripten_glTexImage2D": _emscripten_glTexImage2D, "DYNAMICTOP_PTR": DYNAMICTOP_PTR, "tempDoublePtr": tempDoublePtr, "ABORT": ABORT, "STACKTOP": STACKTOP, "STACK_MAX": STACK_MAX, "cttz_i8": cttz_i8 };
  9008. // EMSCRIPTEN_START_ASM
  9009. var asm = (function(global, env, buffer) {
  9010. 'use asm';
  9011. var HEAP8 = new global.Int8Array(buffer);
  9012. var HEAP16 = new global.Int16Array(buffer);
  9013. var HEAP32 = new global.Int32Array(buffer);
  9014. var HEAPU8 = new global.Uint8Array(buffer);
  9015. var HEAPU16 = new global.Uint16Array(buffer);
  9016. var HEAPU32 = new global.Uint32Array(buffer);
  9017. var HEAPF32 = new global.Float32Array(buffer);
  9018. var HEAPF64 = new global.Float64Array(buffer);
  9019. var DYNAMICTOP_PTR=env.DYNAMICTOP_PTR|0;
  9020. var tempDoublePtr=env.tempDoublePtr|0;
  9021. var ABORT=env.ABORT|0;
  9022. var STACKTOP=env.STACKTOP|0;
  9023. var STACK_MAX=env.STACK_MAX|0;
  9024. var cttz_i8=env.cttz_i8|0;
  9025. var __THREW__ = 0;
  9026. var threwValue = 0;
  9027. var setjmpId = 0;
  9028. var undef = 0;
  9029. var nan = global.NaN, inf = global.Infinity;
  9030. var tempInt = 0, tempBigInt = 0, tempBigIntP = 0, tempBigIntS = 0, tempBigIntR = 0.0, tempBigIntI = 0, tempBigIntD = 0, tempValue = 0, tempDouble = 0.0;
  9031. var tempRet0 = 0;
  9032. var Math_floor=global.Math.floor;
  9033. var Math_abs=global.Math.abs;
  9034. var Math_sqrt=global.Math.sqrt;
  9035. var Math_pow=global.Math.pow;
  9036. var Math_cos=global.Math.cos;
  9037. var Math_sin=global.Math.sin;
  9038. var Math_tan=global.Math.tan;
  9039. var Math_acos=global.Math.acos;
  9040. var Math_asin=global.Math.asin;
  9041. var Math_atan=global.Math.atan;
  9042. var Math_atan2=global.Math.atan2;
  9043. var Math_exp=global.Math.exp;
  9044. var Math_log=global.Math.log;
  9045. var Math_ceil=global.Math.ceil;
  9046. var Math_imul=global.Math.imul;
  9047. var Math_min=global.Math.min;
  9048. var Math_max=global.Math.max;
  9049. var Math_clz32=global.Math.clz32;
  9050. var abort=env.abort;
  9051. var assert=env.assert;
  9052. var enlargeMemory=env.enlargeMemory;
  9053. var getTotalMemory=env.getTotalMemory;
  9054. var abortOnCannotGrowMemory=env.abortOnCannotGrowMemory;
  9055. var abortStackOverflow=env.abortStackOverflow;
  9056. var nullFunc_viiiii=env.nullFunc_viiiii;
  9057. var nullFunc_vd=env.nullFunc_vd;
  9058. var nullFunc_vid=env.nullFunc_vid;
  9059. var nullFunc_vi=env.nullFunc_vi;
  9060. var nullFunc_vii=env.nullFunc_vii;
  9061. var nullFunc_ii=env.nullFunc_ii;
  9062. var nullFunc_viddd=env.nullFunc_viddd;
  9063. var nullFunc_vidd=env.nullFunc_vidd;
  9064. var nullFunc_iiii=env.nullFunc_iiii;
  9065. var nullFunc_viiiiiiii=env.nullFunc_viiiiiiii;
  9066. var nullFunc_viiiiii=env.nullFunc_viiiiii;
  9067. var nullFunc_vdd=env.nullFunc_vdd;
  9068. var nullFunc_dd=env.nullFunc_dd;
  9069. var nullFunc_vidddd=env.nullFunc_vidddd;
  9070. var nullFunc_vdi=env.nullFunc_vdi;
  9071. var nullFunc_viiiiiii=env.nullFunc_viiiiiii;
  9072. var nullFunc_viiiiiiiii=env.nullFunc_viiiiiiiii;
  9073. var nullFunc_iii=env.nullFunc_iii;
  9074. var nullFunc_i=env.nullFunc_i;
  9075. var nullFunc_vdddddd=env.nullFunc_vdddddd;
  9076. var nullFunc_vdddd=env.nullFunc_vdddd;
  9077. var nullFunc_viii=env.nullFunc_viii;
  9078. var nullFunc_v=env.nullFunc_v;
  9079. var nullFunc_viid=env.nullFunc_viid;
  9080. var nullFunc_ddd=env.nullFunc_ddd;
  9081. var nullFunc_viiii=env.nullFunc_viiii;
  9082. var invoke_viiiii=env.invoke_viiiii;
  9083. var invoke_vd=env.invoke_vd;
  9084. var invoke_vid=env.invoke_vid;
  9085. var invoke_vi=env.invoke_vi;
  9086. var invoke_vii=env.invoke_vii;
  9087. var invoke_ii=env.invoke_ii;
  9088. var invoke_viddd=env.invoke_viddd;
  9089. var invoke_vidd=env.invoke_vidd;
  9090. var invoke_iiii=env.invoke_iiii;
  9091. var invoke_viiiiiiii=env.invoke_viiiiiiii;
  9092. var invoke_viiiiii=env.invoke_viiiiii;
  9093. var invoke_vdd=env.invoke_vdd;
  9094. var invoke_dd=env.invoke_dd;
  9095. var invoke_vidddd=env.invoke_vidddd;
  9096. var invoke_vdi=env.invoke_vdi;
  9097. var invoke_viiiiiii=env.invoke_viiiiiii;
  9098. var invoke_viiiiiiiii=env.invoke_viiiiiiiii;
  9099. var invoke_iii=env.invoke_iii;
  9100. var invoke_i=env.invoke_i;
  9101. var invoke_vdddddd=env.invoke_vdddddd;
  9102. var invoke_vdddd=env.invoke_vdddd;
  9103. var invoke_viii=env.invoke_viii;
  9104. var invoke_v=env.invoke_v;
  9105. var invoke_viid=env.invoke_viid;
  9106. var invoke_ddd=env.invoke_ddd;
  9107. var invoke_viiii=env.invoke_viiii;
  9108. var _emscripten_glGetTexParameterfv=env._emscripten_glGetTexParameterfv;
  9109. var _glUseProgram=env._glUseProgram;
  9110. var _emscripten_glShaderSource=env._emscripten_glShaderSource;
  9111. var _glfwCreateWindow=env._glfwCreateWindow;
  9112. var _emscripten_glReleaseShaderCompiler=env._emscripten_glReleaseShaderCompiler;
  9113. var _emscripten_glBlendFuncSeparate=env._emscripten_glBlendFuncSeparate;
  9114. var _emscripten_glVertexAttribPointer=env._emscripten_glVertexAttribPointer;
  9115. var _emscripten_glGetIntegerv=env._emscripten_glGetIntegerv;
  9116. var _emscripten_glCullFace=env._emscripten_glCullFace;
  9117. var _emscripten_glIsProgram=env._emscripten_glIsProgram;
  9118. var _emscripten_glStencilMaskSeparate=env._emscripten_glStencilMaskSeparate;
  9119. var _emscripten_glViewport=env._emscripten_glViewport;
  9120. var _emscripten_glFrontFace=env._emscripten_glFrontFace;
  9121. var ___assert_fail=env.___assert_fail;
  9122. var _glDeleteProgram=env._glDeleteProgram;
  9123. var _emscripten_glUniform3fv=env._emscripten_glUniform3fv;
  9124. var _emscripten_glPolygonOffset=env._emscripten_glPolygonOffset;
  9125. var _emscripten_glUseProgram=env._emscripten_glUseProgram;
  9126. var _emscripten_glBlendColor=env._emscripten_glBlendColor;
  9127. var _glBindBuffer=env._glBindBuffer;
  9128. var _emscripten_glDepthFunc=env._emscripten_glDepthFunc;
  9129. var _glGetShaderInfoLog=env._glGetShaderInfoLog;
  9130. var _emscripten_set_fullscreenchange_callback=env._emscripten_set_fullscreenchange_callback;
  9131. var _emscripten_set_touchmove_callback=env._emscripten_set_touchmove_callback;
  9132. var _emscripten_set_main_loop_timing=env._emscripten_set_main_loop_timing;
  9133. var _emscripten_set_gamepaddisconnected_callback=env._emscripten_set_gamepaddisconnected_callback;
  9134. var _glDisable=env._glDisable;
  9135. var _glBlendFunc=env._glBlendFunc;
  9136. var _emscripten_glDisableVertexAttribArray=env._emscripten_glDisableVertexAttribArray;
  9137. var _glGetAttribLocation=env._glGetAttribLocation;
  9138. var _glDisableVertexAttribArray=env._glDisableVertexAttribArray;
  9139. var _glCreateShader=env._glCreateShader;
  9140. var _emscripten_glSampleCoverage=env._emscripten_glSampleCoverage;
  9141. var _emscripten_glVertexPointer=env._emscripten_glVertexPointer;
  9142. var _emscripten_set_touchstart_callback=env._emscripten_set_touchstart_callback;
  9143. var emscriptenWebGLComputeImageSize=env.emscriptenWebGLComputeImageSize;
  9144. var _emscripten_glGetBooleanv=env._emscripten_glGetBooleanv;
  9145. var _emscripten_glGetShaderSource=env._emscripten_glGetShaderSource;
  9146. var _glUniform4f=env._glUniform4f;
  9147. var _llvm_stacksave=env._llvm_stacksave;
  9148. var _emscripten_glUniform1i=env._emscripten_glUniform1i;
  9149. var _emscripten_glStencilFuncSeparate=env._emscripten_glStencilFuncSeparate;
  9150. var _emscripten_glFrustum=env._emscripten_glFrustum;
  9151. var _emscripten_glGenBuffers=env._emscripten_glGenBuffers;
  9152. var _emscripten_glDeleteObjectARB=env._emscripten_glDeleteObjectARB;
  9153. var _glfwSetWindowSizeCallback=env._glfwSetWindowSizeCallback;
  9154. var _emscripten_glGetShaderPrecisionFormat=env._emscripten_glGetShaderPrecisionFormat;
  9155. var _glfwInit=env._glfwInit;
  9156. var _emscripten_glGetPointerv=env._emscripten_glGetPointerv;
  9157. var _glGenBuffers=env._glGenBuffers;
  9158. var _glShaderSource=env._glShaderSource;
  9159. var _emscripten_glGetString=env._emscripten_glGetString;
  9160. var _emscripten_glIsFramebuffer=env._emscripten_glIsFramebuffer;
  9161. var _emscripten_glIsEnabled=env._emscripten_glIsEnabled;
  9162. var _emscripten_glScissor=env._emscripten_glScissor;
  9163. var _emscripten_glVertexAttrib4fv=env._emscripten_glVertexAttrib4fv;
  9164. var _emscripten_glFramebufferTexture2D=env._emscripten_glFramebufferTexture2D;
  9165. var _emscripten_glTexParameteriv=env._emscripten_glTexParameteriv;
  9166. var ___syscall145=env.___syscall145;
  9167. var _emscripten_glBindProgramARB=env._emscripten_glBindProgramARB;
  9168. var _emscripten_glStencilOpSeparate=env._emscripten_glStencilOpSeparate;
  9169. var _emscripten_glFramebufferRenderbuffer=env._emscripten_glFramebufferRenderbuffer;
  9170. var ___syscall140=env.___syscall140;
  9171. var _glfwSetErrorCallback=env._glfwSetErrorCallback;
  9172. var _glfwDefaultWindowHints=env._glfwDefaultWindowHints;
  9173. var _glfwDestroyWindow=env._glfwDestroyWindow;
  9174. var ___syscall146=env.___syscall146;
  9175. var _emscripten_glGetActiveAttrib=env._emscripten_glGetActiveAttrib;
  9176. var _emscripten_glAttachShader=env._emscripten_glAttachShader;
  9177. var _glVertexAttribPointer=env._glVertexAttribPointer;
  9178. var _emscripten_glUniform2i=env._emscripten_glUniform2i;
  9179. var _emscripten_glUniform2f=env._emscripten_glUniform2f;
  9180. var _emscripten_glTexParameterfv=env._emscripten_glTexParameterfv;
  9181. var _emscripten_glUniformMatrix2fv=env._emscripten_glUniformMatrix2fv;
  9182. var _glGetProgramInfoLog=env._glGetProgramInfoLog;
  9183. var _glfwSetScrollCallback=env._glfwSetScrollCallback;
  9184. var _emscripten_glTexParameterf=env._emscripten_glTexParameterf;
  9185. var _emscripten_glGetAttachedShaders=env._emscripten_glGetAttachedShaders;
  9186. var _emscripten_glGenTextures=env._emscripten_glGenTextures;
  9187. var _emscripten_glTexParameteri=env._emscripten_glTexParameteri;
  9188. var _llvm_stackrestore=env._llvm_stackrestore;
  9189. var _glfwMakeContextCurrent=env._glfwMakeContextCurrent;
  9190. var _emscripten_glClear=env._emscripten_glClear;
  9191. var _glDrawElements=env._glDrawElements;
  9192. var _glBufferSubData=env._glBufferSubData;
  9193. var _emscripten_glValidateProgram=env._emscripten_glValidateProgram;
  9194. var _emscripten_glVertexAttrib2fv=env._emscripten_glVertexAttrib2fv;
  9195. var _glViewport=env._glViewport;
  9196. var _emscripten_glUniform4iv=env._emscripten_glUniform4iv;
  9197. var _emscripten_glGetTexParameteriv=env._emscripten_glGetTexParameteriv;
  9198. var ___setErrNo=env.___setErrNo;
  9199. var _eglGetProcAddress=env._eglGetProcAddress;
  9200. var _emscripten_glBindAttribLocation=env._emscripten_glBindAttribLocation;
  9201. var _glDeleteTextures=env._glDeleteTextures;
  9202. var _glDepthFunc=env._glDepthFunc;
  9203. var _emscripten_glClientActiveTexture=env._emscripten_glClientActiveTexture;
  9204. var _emscripten_glVertexAttrib2f=env._emscripten_glVertexAttrib2f;
  9205. var _emscripten_glFlush=env._emscripten_glFlush;
  9206. var _emscripten_glCheckFramebufferStatus=env._emscripten_glCheckFramebufferStatus;
  9207. var _emscripten_glGenerateMipmap=env._emscripten_glGenerateMipmap;
  9208. var _emscripten_glGetError=env._emscripten_glGetError;
  9209. var _emscripten_glClearDepthf=env._emscripten_glClearDepthf;
  9210. var _emscripten_glBufferData=env._emscripten_glBufferData;
  9211. var _emscripten_glUniform3i=env._emscripten_glUniform3i;
  9212. var _emscripten_glRotatef=env._emscripten_glRotatef;
  9213. var _emscripten_glDeleteShader=env._emscripten_glDeleteShader;
  9214. var _glEnable=env._glEnable;
  9215. var _emscripten_glReadPixels=env._emscripten_glReadPixels;
  9216. var _emscripten_glMatrixMode=env._emscripten_glMatrixMode;
  9217. var _glGetString=env._glGetString;
  9218. var _emscripten_glClearStencil=env._emscripten_glClearStencil;
  9219. var _emscripten_glGetUniformLocation=env._emscripten_glGetUniformLocation;
  9220. var emscriptenWebGLGet=env.emscriptenWebGLGet;
  9221. var _emscripten_glEnableVertexAttribArray=env._emscripten_glEnableVertexAttribArray;
  9222. var _emscripten_glGetAttribLocation=env._emscripten_glGetAttribLocation;
  9223. var _emscripten_get_now=env._emscripten_get_now;
  9224. var _emscripten_glNormalPointer=env._emscripten_glNormalPointer;
  9225. var _glAttachShader=env._glAttachShader;
  9226. var _emscripten_glTexCoordPointer=env._emscripten_glTexCoordPointer;
  9227. var _emscripten_glEnable=env._emscripten_glEnable;
  9228. var _glCreateProgram=env._glCreateProgram;
  9229. var _glUniformMatrix4fv=env._glUniformMatrix4fv;
  9230. var _emscripten_glClearDepth=env._emscripten_glClearDepth;
  9231. var ___lock=env.___lock;
  9232. var emscriptenWebGLGetTexPixelData=env.emscriptenWebGLGetTexPixelData;
  9233. var ___syscall6=env.___syscall6;
  9234. var ___syscall5=env.___syscall5;
  9235. var _emscripten_glIsBuffer=env._emscripten_glIsBuffer;
  9236. var _emscripten_glVertexAttrib3f=env._emscripten_glVertexAttrib3f;
  9237. var _time=env._time;
  9238. var _emscripten_glVertexAttrib1f=env._emscripten_glVertexAttrib1f;
  9239. var _emscripten_glGetFramebufferAttachmentParameteriv=env._emscripten_glGetFramebufferAttachmentParameteriv;
  9240. var _emscripten_glBlendEquationSeparate=env._emscripten_glBlendEquationSeparate;
  9241. var _exit=env._exit;
  9242. var _emscripten_glEnableClientState=env._emscripten_glEnableClientState;
  9243. var _emscripten_glUniform4i=env._emscripten_glUniform4i;
  9244. var _emscripten_glDrawRangeElements=env._emscripten_glDrawRangeElements;
  9245. var _glCullFace=env._glCullFace;
  9246. var _llvm_pow_f64=env._llvm_pow_f64;
  9247. var _emscripten_set_keypress_callback=env._emscripten_set_keypress_callback;
  9248. var __emscripten_sample_gamepad_data=env.__emscripten_sample_gamepad_data;
  9249. var _emscripten_get_gamepad_status=env._emscripten_get_gamepad_status;
  9250. var _emscripten_glUniform4f=env._emscripten_glUniform4f;
  9251. var _emscripten_glUniform2fv=env._emscripten_glUniform2fv;
  9252. var _glfwGetVideoModes=env._glfwGetVideoModes;
  9253. var _emscripten_set_click_callback=env._emscripten_set_click_callback;
  9254. var _emscripten_glShaderBinary=env._emscripten_glShaderBinary;
  9255. var _emscripten_glDrawElements=env._emscripten_glDrawElements;
  9256. var _emscripten_glBlendFunc=env._emscripten_glBlendFunc;
  9257. var _emscripten_get_num_gamepads=env._emscripten_get_num_gamepads;
  9258. var ___syscall221=env.___syscall221;
  9259. var _glCompressedTexImage2D=env._glCompressedTexImage2D;
  9260. var _emscripten_glUniform1iv=env._emscripten_glUniform1iv;
  9261. var _emscripten_glGetVertexAttribPointerv=env._emscripten_glGetVertexAttribPointerv;
  9262. var _glClearDepthf=env._glClearDepthf;
  9263. var _emscripten_glCompressedTexSubImage2D=env._emscripten_glCompressedTexSubImage2D;
  9264. var emscriptenWebGLGetUniform=env.emscriptenWebGLGetUniform;
  9265. var _emscripten_glGenRenderbuffers=env._emscripten_glGenRenderbuffers;
  9266. var _emscripten_glDeleteVertexArrays=env._emscripten_glDeleteVertexArrays;
  9267. var _glfwSetWindowShouldClose=env._glfwSetWindowShouldClose;
  9268. var _emscripten_glUniform1fv=env._emscripten_glUniform1fv;
  9269. var _emscripten_glGetActiveUniform=env._emscripten_glGetActiveUniform;
  9270. var _glBindTexture=env._glBindTexture;
  9271. var _emscripten_glUniform3iv=env._emscripten_glUniform3iv;
  9272. var _emscripten_glUniform2iv=env._emscripten_glUniform2iv;
  9273. var _emscripten_glHint=env._emscripten_glHint;
  9274. var _glfwSetCharCallback=env._glfwSetCharCallback;
  9275. var emscriptenWebGLGetVertexAttrib=env.emscriptenWebGLGetVertexAttrib;
  9276. var _emscripten_glLoadMatrixf=env._emscripten_glLoadMatrixf;
  9277. var _emscripten_glDeleteProgram=env._emscripten_glDeleteProgram;
  9278. var _emscripten_glDeleteRenderbuffers=env._emscripten_glDeleteRenderbuffers;
  9279. var _emscripten_glDrawElementsInstanced=env._emscripten_glDrawElementsInstanced;
  9280. var _emscripten_glVertexAttrib4f=env._emscripten_glVertexAttrib4f;
  9281. var _glDrawArrays=env._glDrawArrays;
  9282. var _emscripten_glTexSubImage2D=env._emscripten_glTexSubImage2D;
  9283. var _emscripten_memcpy_big=env._emscripten_memcpy_big;
  9284. var _emscripten_glPixelStorei=env._emscripten_glPixelStorei;
  9285. var _glCompileShader=env._glCompileShader;
  9286. var _emscripten_get_pointerlock_status=env._emscripten_get_pointerlock_status;
  9287. var _emscripten_glUniformMatrix3fv=env._emscripten_glUniformMatrix3fv;
  9288. var _emscripten_glColorPointer=env._emscripten_glColorPointer;
  9289. var _emscripten_glGetBufferParameteriv=env._emscripten_glGetBufferParameteriv;
  9290. var _emscripten_glFinish=env._emscripten_glFinish;
  9291. var _emscripten_request_pointerlock=env._emscripten_request_pointerlock;
  9292. var _glGetFloatv=env._glGetFloatv;
  9293. var _emscripten_asm_const_iii=env._emscripten_asm_const_iii;
  9294. var _emscripten_glDepthMask=env._emscripten_glDepthMask;
  9295. var _glfwSetWindowIconifyCallback=env._glfwSetWindowIconifyCallback;
  9296. var _emscripten_glDrawBuffers=env._emscripten_glDrawBuffers;
  9297. var _glfwTerminate=env._glfwTerminate;
  9298. var _glFrontFace=env._glFrontFace;
  9299. var _emscripten_glGetObjectParameterivARB=env._emscripten_glGetObjectParameterivARB;
  9300. var _emscripten_exit_pointerlock=env._emscripten_exit_pointerlock;
  9301. var _glfwSwapInterval=env._glfwSwapInterval;
  9302. var _glUniform1i=env._glUniform1i;
  9303. var _glEnableVertexAttribArray=env._glEnableVertexAttribArray;
  9304. var _emscripten_glStencilFunc=env._emscripten_glStencilFunc;
  9305. var _abort=env._abort;
  9306. var _emscripten_glGetUniformiv=env._emscripten_glGetUniformiv;
  9307. var _glDeleteBuffers=env._glDeleteBuffers;
  9308. var _glBufferData=env._glBufferData;
  9309. var _glTexImage2D=env._glTexImage2D;
  9310. var _emscripten_glGetShaderiv=env._emscripten_glGetShaderiv;
  9311. var _glfwSetKeyCallback=env._glfwSetKeyCallback;
  9312. var _emscripten_glGenFramebuffers=env._emscripten_glGenFramebuffers;
  9313. var _emscripten_glUniformMatrix4fv=env._emscripten_glUniformMatrix4fv;
  9314. var _emscripten_glLoadIdentity=env._emscripten_glLoadIdentity;
  9315. var _glDeleteShader=env._glDeleteShader;
  9316. var _emscripten_glUniform1f=env._emscripten_glUniform1f;
  9317. var _glGetProgramiv=env._glGetProgramiv;
  9318. var _emscripten_glBindFramebuffer=env._emscripten_glBindFramebuffer;
  9319. var _emscripten_glIsRenderbuffer=env._emscripten_glIsRenderbuffer;
  9320. var _glfwGetTime=env._glfwGetTime;
  9321. var _emscripten_glRenderbufferStorage=env._emscripten_glRenderbufferStorage;
  9322. var _emscripten_set_gamepadconnected_callback=env._emscripten_set_gamepadconnected_callback;
  9323. var _emscripten_glGetVertexAttribiv=env._emscripten_glGetVertexAttribiv;
  9324. var _emscripten_glBindVertexArray=env._emscripten_glBindVertexArray;
  9325. var _emscripten_glDrawArraysInstanced=env._emscripten_glDrawArraysInstanced;
  9326. var _emscripten_set_touchcancel_callback=env._emscripten_set_touchcancel_callback;
  9327. var _emscripten_glCreateShader=env._emscripten_glCreateShader;
  9328. var _emscripten_glStencilMask=env._emscripten_glStencilMask;
  9329. var _emscripten_glDeleteTextures=env._emscripten_glDeleteTextures;
  9330. var _emscripten_glBindRenderbuffer=env._emscripten_glBindRenderbuffer;
  9331. var _glfwGetPrimaryMonitor=env._glfwGetPrimaryMonitor;
  9332. var _glLinkProgram=env._glLinkProgram;
  9333. var _emscripten_glVertexAttribDivisor=env._emscripten_glVertexAttribDivisor;
  9334. var _emscripten_set_touchend_callback=env._emscripten_set_touchend_callback;
  9335. var _emscripten_glGetUniformfv=env._emscripten_glGetUniformfv;
  9336. var _emscripten_glGetVertexAttribfv=env._emscripten_glGetVertexAttribfv;
  9337. var _emscripten_glGetRenderbufferParameteriv=env._emscripten_glGetRenderbufferParameteriv;
  9338. var _emscripten_glDeleteFramebuffers=env._emscripten_glDeleteFramebuffers;
  9339. var _glGetShaderiv=env._glGetShaderiv;
  9340. var _emscripten_glVertexAttrib3fv=env._emscripten_glVertexAttrib3fv;
  9341. var _glGetUniformLocation=env._glGetUniformLocation;
  9342. var _emscripten_glGetInfoLogARB=env._emscripten_glGetInfoLogARB;
  9343. var _emscripten_glCompileShader=env._emscripten_glCompileShader;
  9344. var _glClear=env._glClear;
  9345. var _glGenTextures=env._glGenTextures;
  9346. var _emscripten_glDisable=env._emscripten_glDisable;
  9347. var _emscripten_glDepthRangef=env._emscripten_glDepthRangef;
  9348. var __exit=env.__exit;
  9349. var _emscripten_glLineWidth=env._emscripten_glLineWidth;
  9350. var _emscripten_glUniform3f=env._emscripten_glUniform3f;
  9351. var _emscripten_glGetShaderInfoLog=env._emscripten_glGetShaderInfoLog;
  9352. var _emscripten_glStencilOp=env._emscripten_glStencilOp;
  9353. var _glBindAttribLocation=env._glBindAttribLocation;
  9354. var _glPixelStorei=env._glPixelStorei;
  9355. var _emscripten_glColorMask=env._emscripten_glColorMask;
  9356. var _emscripten_glLinkProgram=env._emscripten_glLinkProgram;
  9357. var _emscripten_glBlendEquation=env._emscripten_glBlendEquation;
  9358. var _emscripten_glIsTexture=env._emscripten_glIsTexture;
  9359. var _emscripten_glGetProgramiv=env._emscripten_glGetProgramiv;
  9360. var _emscripten_glVertexAttrib1fv=env._emscripten_glVertexAttrib1fv;
  9361. var _emscripten_glBindTexture=env._emscripten_glBindTexture;
  9362. var _glfwSetMouseButtonCallback=env._glfwSetMouseButtonCallback;
  9363. var _glfwGetCursorPos=env._glfwGetCursorPos;
  9364. var _emscripten_glActiveTexture=env._emscripten_glActiveTexture;
  9365. var _emscripten_glDeleteBuffers=env._emscripten_glDeleteBuffers;
  9366. var ___syscall54=env.___syscall54;
  9367. var ___unlock=env.___unlock;
  9368. var _emscripten_glBufferSubData=env._emscripten_glBufferSubData;
  9369. var _glfwSwapBuffers=env._glfwSwapBuffers;
  9370. var _emscripten_glDepthRange=env._emscripten_glDepthRange;
  9371. var _emscripten_set_main_loop=env._emscripten_set_main_loop;
  9372. var _emscripten_glGetProgramInfoLog=env._emscripten_glGetProgramInfoLog;
  9373. var _glfwWindowHint=env._glfwWindowHint;
  9374. var _emscripten_glIsShader=env._emscripten_glIsShader;
  9375. var _emscripten_glUniform4fv=env._emscripten_glUniform4fv;
  9376. var _emscripten_glGenVertexArrays=env._emscripten_glGenVertexArrays;
  9377. var _emscripten_glDrawArrays=env._emscripten_glDrawArrays;
  9378. var _emscripten_glCompressedTexImage2D=env._emscripten_glCompressedTexImage2D;
  9379. var _emscripten_glClearColor=env._emscripten_glClearColor;
  9380. var _emscripten_glCreateProgram=env._emscripten_glCreateProgram;
  9381. var _emscripten_glCopyTexSubImage2D=env._emscripten_glCopyTexSubImage2D;
  9382. var _glTexParameteri=env._glTexParameteri;
  9383. var _emscripten_glBindBuffer=env._emscripten_glBindBuffer;
  9384. var _emscripten_glGetFloatv=env._emscripten_glGetFloatv;
  9385. var _emscripten_glDetachShader=env._emscripten_glDetachShader;
  9386. var _glClearColor=env._glClearColor;
  9387. var _glfwSetCursorPosCallback=env._glfwSetCursorPosCallback;
  9388. var _glfwSetCursorEnterCallback=env._glfwSetCursorEnterCallback;
  9389. var _emscripten_glCopyTexImage2D=env._emscripten_glCopyTexImage2D;
  9390. var _emscripten_glTexImage2D=env._emscripten_glTexImage2D;
  9391. var tempFloat = 0.0;
  9392. // EMSCRIPTEN_START_FUNCS
  9393. function stackAlloc(size) {
  9394. size = size|0;
  9395. var ret = 0;
  9396. ret = STACKTOP;
  9397. STACKTOP = (STACKTOP + size)|0;
  9398. STACKTOP = (STACKTOP + 15)&-16;
  9399. if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(size|0);
  9400. return ret|0;
  9401. }
  9402. function stackSave() {
  9403. return STACKTOP|0;
  9404. }
  9405. function stackRestore(top) {
  9406. top = top|0;
  9407. STACKTOP = top;
  9408. }
  9409. function establishStackSpace(stackBase, stackMax) {
  9410. stackBase = stackBase|0;
  9411. stackMax = stackMax|0;
  9412. STACKTOP = stackBase;
  9413. STACK_MAX = stackMax;
  9414. }
  9415. function setThrew(threw, value) {
  9416. threw = threw|0;
  9417. value = value|0;
  9418. if ((__THREW__|0) == 0) {
  9419. __THREW__ = threw;
  9420. threwValue = value;
  9421. }
  9422. }
  9423. function setTempRet0(value) {
  9424. value = value|0;
  9425. tempRet0 = value;
  9426. }
  9427. function getTempRet0() {
  9428. return tempRet0|0;
  9429. }
  9430. function _main() {
  9431. var $$byval_copy1 = 0, $$byval_copy2 = 0, $0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0.0, $23 = 0.0, $24 = 0;
  9432. var $25 = 0, $26 = 0, $27 = 0.0, $28 = 0.0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  9433. var $texture$byval_copy = 0, label = 0, sp = 0;
  9434. sp = STACKTOP;
  9435. STACKTOP = STACKTOP + 192|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(192|0);
  9436. $texture$byval_copy = sp + 168|0;
  9437. $$byval_copy2 = sp + 136|0;
  9438. $$byval_copy1 = sp + 96|0;
  9439. $0 = sp + 40|0;
  9440. $1 = sp + 152|0;
  9441. $2 = sp;
  9442. $3 = sp + 120|0;
  9443. $4 = sp + 80|0;
  9444. $5 = sp + 64|0;
  9445. $6 = sp + 20|0;
  9446. $7 = HEAP32[2]|0;
  9447. $8 = HEAP32[3]|0;
  9448. _InitWindow($7,$8,5484);
  9449. _LoadImage($0,5526);
  9450. HEAP32[$1>>2] = 100;
  9451. $9 = ((($1)) + 4|0);
  9452. HEAP32[$9>>2] = 10;
  9453. $10 = ((($1)) + 8|0);
  9454. HEAP32[$10>>2] = 280;
  9455. $11 = ((($1)) + 12|0);
  9456. HEAP32[$11>>2] = 380;
  9457. ;HEAP32[$texture$byval_copy>>2]=HEAP32[$1>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[$1+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[$1+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[$1+12>>2]|0;
  9458. _ImageCrop($0,$texture$byval_copy);
  9459. _ImageFlipHorizontal($0);
  9460. _ImageResize($0,150,200);
  9461. _LoadImage($2,5544);
  9462. HEAP32[$3>>2] = 0;
  9463. $12 = ((($3)) + 4|0);
  9464. HEAP32[$12>>2] = 0;
  9465. $13 = ((($3)) + 8|0);
  9466. $14 = ((($0)) + 4|0);
  9467. $15 = HEAP32[$14>>2]|0;
  9468. HEAP32[$13>>2] = $15;
  9469. $16 = ((($3)) + 12|0);
  9470. $17 = ((($0)) + 8|0);
  9471. $18 = HEAP32[$17>>2]|0;
  9472. HEAP32[$16>>2] = $18;
  9473. HEAP32[$4>>2] = 30;
  9474. $19 = ((($4)) + 4|0);
  9475. HEAP32[$19>>2] = 40;
  9476. $20 = ((($4)) + 8|0);
  9477. $21 = HEAP32[$14>>2]|0;
  9478. $22 = (+($21|0));
  9479. $23 = $22 * 1.5;
  9480. $24 = (~~(($23)));
  9481. HEAP32[$20>>2] = $24;
  9482. $25 = ((($4)) + 12|0);
  9483. $26 = HEAP32[$17>>2]|0;
  9484. $27 = (+($26|0));
  9485. $28 = $27 * 1.5;
  9486. $29 = (~~(($28)));
  9487. HEAP32[$25>>2] = $29;
  9488. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  9489. ;HEAP32[$$byval_copy2>>2]=HEAP32[$3>>2]|0;HEAP32[$$byval_copy2+4>>2]=HEAP32[$3+4>>2]|0;HEAP32[$$byval_copy2+8>>2]=HEAP32[$3+8>>2]|0;HEAP32[$$byval_copy2+12>>2]=HEAP32[$3+12>>2]|0;
  9490. ;HEAP32[$texture$byval_copy>>2]=HEAP32[$4>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[$4+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[$4+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[$4+12>>2]|0;
  9491. _ImageDraw($2,$$byval_copy1,$$byval_copy2,$texture$byval_copy);
  9492. HEAP32[$5>>2] = 0;
  9493. $30 = ((($5)) + 4|0);
  9494. HEAP32[$30>>2] = 50;
  9495. $31 = ((($5)) + 8|0);
  9496. $32 = ((($2)) + 4|0);
  9497. $33 = HEAP32[$32>>2]|0;
  9498. HEAP32[$31>>2] = $33;
  9499. $34 = ((($5)) + 12|0);
  9500. $35 = ((($2)) + 8|0);
  9501. $36 = HEAP32[$35>>2]|0;
  9502. $37 = (($36) + -100)|0;
  9503. HEAP32[$34>>2] = $37;
  9504. ;HEAP32[$texture$byval_copy>>2]=HEAP32[$5>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[$5+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[$5+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[$5+12>>2]|0;
  9505. _ImageCrop($2,$texture$byval_copy);
  9506. ;HEAP32[$texture$byval_copy>>2]=HEAP32[$0>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$texture$byval_copy+16>>2]=HEAP32[$0+16>>2]|0;
  9507. _UnloadImage($texture$byval_copy);
  9508. ;HEAP32[$texture$byval_copy>>2]=HEAP32[$2>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[$2+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[$2+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[$2+12>>2]|0;HEAP32[$texture$byval_copy+16>>2]=HEAP32[$2+16>>2]|0;
  9509. _LoadTextureFromImage($6,$texture$byval_copy);
  9510. ;HEAP32[21312>>2]=HEAP32[$6>>2]|0;HEAP32[21312+4>>2]=HEAP32[$6+4>>2]|0;HEAP32[21312+8>>2]=HEAP32[$6+8>>2]|0;HEAP32[21312+12>>2]=HEAP32[$6+12>>2]|0;HEAP32[21312+16>>2]=HEAP32[$6+16>>2]|0;
  9511. ;HEAP32[$texture$byval_copy>>2]=HEAP32[$2>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[$2+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[$2+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[$2+12>>2]|0;HEAP32[$texture$byval_copy+16>>2]=HEAP32[$2+16>>2]|0;
  9512. _UnloadImage($texture$byval_copy);
  9513. _emscripten_set_main_loop((1|0),0,1);
  9514. ;HEAP32[$texture$byval_copy>>2]=HEAP32[21312>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[21312+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[21312+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[21312+12>>2]|0;HEAP32[$texture$byval_copy+16>>2]=HEAP32[21312+16>>2]|0;
  9515. _UnloadTexture($texture$byval_copy);
  9516. _CloseWindow();
  9517. STACKTOP = sp;return 0;
  9518. }
  9519. function _UpdateDrawFrame() {
  9520. var $$byval_copy3 = 0, $$neg = 0, $$neg1 = 0, $0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  9521. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  9522. var $texture$byval_copy = 0, label = 0, sp = 0;
  9523. sp = STACKTOP;
  9524. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  9525. $$byval_copy3 = sp + 40|0;
  9526. $texture$byval_copy = sp;
  9527. $0 = sp + 36|0;
  9528. $1 = sp + 20|0;
  9529. $2 = sp + 32|0;
  9530. $3 = sp + 28|0;
  9531. $4 = sp + 24|0;
  9532. _BeginDrawing();
  9533. HEAP8[$0>>0] = -11;
  9534. $5 = ((($0)) + 1|0);
  9535. HEAP8[$5>>0] = -11;
  9536. $6 = ((($0)) + 2|0);
  9537. HEAP8[$6>>0] = -11;
  9538. $7 = ((($0)) + 3|0);
  9539. HEAP8[$7>>0] = -1;
  9540. ;HEAP8[$$byval_copy3>>0]=HEAP8[$0>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$0+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$0+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$0+3>>0]|0;
  9541. _ClearBackground($$byval_copy3);
  9542. $8 = HEAP32[2]|0;
  9543. $9 = (($8|0) / 2)&-1;
  9544. $10 = HEAP32[(21316)>>2]|0;
  9545. $11 = (($10|0) / 2)&-1;
  9546. $12 = (($9) - ($11))|0;
  9547. $13 = HEAP32[3]|0;
  9548. $14 = (($13|0) / 2)&-1;
  9549. $15 = HEAP32[(21320)>>2]|0;
  9550. $$neg = (($15|0) / -2)&-1;
  9551. $16 = (($14) + -40)|0;
  9552. $17 = (($16) + ($$neg))|0;
  9553. HEAP32[$1>>2] = -1;
  9554. ;HEAP32[$texture$byval_copy>>2]=HEAP32[21312>>2]|0;HEAP32[$texture$byval_copy+4>>2]=HEAP32[21312+4>>2]|0;HEAP32[$texture$byval_copy+8>>2]=HEAP32[21312+8>>2]|0;HEAP32[$texture$byval_copy+12>>2]=HEAP32[21312+12>>2]|0;HEAP32[$texture$byval_copy+16>>2]=HEAP32[21312+16>>2]|0;
  9555. ;HEAP8[$$byval_copy3>>0]=HEAP8[$1>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$1+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$1+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$1+3>>0]|0;
  9556. _DrawTexture($texture$byval_copy,$12,$17,$$byval_copy3);
  9557. $18 = HEAP32[2]|0;
  9558. $19 = (($18|0) / 2)&-1;
  9559. $20 = HEAP32[(21316)>>2]|0;
  9560. $21 = (($20|0) / 2)&-1;
  9561. $22 = (($19) - ($21))|0;
  9562. $23 = HEAP32[3]|0;
  9563. $24 = (($23|0) / 2)&-1;
  9564. $25 = HEAP32[(21320)>>2]|0;
  9565. $$neg1 = (($25|0) / -2)&-1;
  9566. $26 = (($24) + -40)|0;
  9567. $27 = (($26) + ($$neg1))|0;
  9568. HEAP8[$2>>0] = 80;
  9569. $28 = ((($2)) + 1|0);
  9570. HEAP8[$28>>0] = 80;
  9571. $29 = ((($2)) + 2|0);
  9572. HEAP8[$29>>0] = 80;
  9573. $30 = ((($2)) + 3|0);
  9574. HEAP8[$30>>0] = -1;
  9575. ;HEAP8[$$byval_copy3>>0]=HEAP8[$2>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$2+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$2+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$2+3>>0]|0;
  9576. _DrawRectangleLines($22,$27,$20,$25,$$byval_copy3);
  9577. HEAP8[$3>>0] = 80;
  9578. $31 = ((($3)) + 1|0);
  9579. HEAP8[$31>>0] = 80;
  9580. $32 = ((($3)) + 2|0);
  9581. HEAP8[$32>>0] = 80;
  9582. $33 = ((($3)) + 3|0);
  9583. HEAP8[$33>>0] = -1;
  9584. ;HEAP8[$$byval_copy3>>0]=HEAP8[$3>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$3+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$3+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$3+3>>0]|0;
  9585. _DrawText(5566,240,350,10,$$byval_copy3);
  9586. HEAP8[$4>>0] = 80;
  9587. $34 = ((($4)) + 1|0);
  9588. HEAP8[$34>>0] = 80;
  9589. $35 = ((($4)) + 2|0);
  9590. HEAP8[$35>>0] = 80;
  9591. $36 = ((($4)) + 3|0);
  9592. HEAP8[$36>>0] = -1;
  9593. ;HEAP8[$$byval_copy3>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$4+3>>0]|0;
  9594. _DrawText(5628,190,370,10,$$byval_copy3);
  9595. _EndDrawing();
  9596. STACKTOP = sp;return;
  9597. }
  9598. function _Vector2Distance($0,$1) {
  9599. $0 = $0|0;
  9600. $1 = $1|0;
  9601. var $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $2 = 0.0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0, $7 = 0.0, $8 = 0, $9 = 0.0, label = 0, sp = 0;
  9602. sp = STACKTOP;
  9603. $2 = +HEAPF32[$0>>2];
  9604. $3 = +HEAPF32[$1>>2];
  9605. $4 = $2 - $3;
  9606. $5 = $4 * $4;
  9607. $6 = ((($0)) + 4|0);
  9608. $7 = +HEAPF32[$6>>2];
  9609. $8 = ((($1)) + 4|0);
  9610. $9 = +HEAPF32[$8>>2];
  9611. $10 = $7 - $9;
  9612. $11 = $10 * $10;
  9613. $12 = $5 + $11;
  9614. $13 = (+Math_sqrt((+$12)));
  9615. return (+$13);
  9616. }
  9617. function _Vector2Angle($0,$1) {
  9618. $0 = $0|0;
  9619. $1 = $1|0;
  9620. var $$0 = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0, $13 = 0.0, $2 = 0, $3 = 0.0, $4 = 0, $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0.0, $9 = 0.0, label = 0, sp = 0;
  9621. sp = STACKTOP;
  9622. $2 = ((($1)) + 4|0);
  9623. $3 = +HEAPF32[$2>>2];
  9624. $4 = ((($0)) + 4|0);
  9625. $5 = +HEAPF32[$4>>2];
  9626. $6 = $3 - $5;
  9627. $7 = +HEAPF32[$1>>2];
  9628. $8 = +HEAPF32[$0>>2];
  9629. $9 = $7 - $8;
  9630. $10 = (+Math_atan2((+$6),(+$9)));
  9631. $11 = $10 * 57.2957763671875;
  9632. $12 = $11 < 0.0;
  9633. $13 = $11 + 360.0;
  9634. $$0 = $12 ? $13 : $11;
  9635. return (+$$0);
  9636. }
  9637. function _VectorZero($0) {
  9638. $0 = $0|0;
  9639. var $1 = 0, $2 = 0, label = 0, sp = 0;
  9640. sp = STACKTOP;
  9641. HEAPF32[$0>>2] = 0.0;
  9642. $1 = ((($0)) + 4|0);
  9643. HEAPF32[$1>>2] = 0.0;
  9644. $2 = ((($0)) + 8|0);
  9645. HEAPF32[$2>>2] = 0.0;
  9646. return;
  9647. }
  9648. function _VectorLength($0) {
  9649. $0 = $0|0;
  9650. var $1 = 0.0, $10 = 0.0, $11 = 0.0, $2 = 0.0, $3 = 0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0, $8 = 0.0, $9 = 0.0, label = 0, sp = 0;
  9651. sp = STACKTOP;
  9652. $1 = +HEAPF32[$0>>2];
  9653. $2 = $1 * $1;
  9654. $3 = ((($0)) + 4|0);
  9655. $4 = +HEAPF32[$3>>2];
  9656. $5 = $4 * $4;
  9657. $6 = $2 + $5;
  9658. $7 = ((($0)) + 8|0);
  9659. $8 = +HEAPF32[$7>>2];
  9660. $9 = $8 * $8;
  9661. $10 = $6 + $9;
  9662. $11 = (+Math_sqrt((+$10)));
  9663. return (+$11);
  9664. }
  9665. function _VectorNormalize($0) {
  9666. $0 = $0|0;
  9667. var $$byval_copy = 0, $$op = 0.0, $1 = 0.0, $10 = 0.0, $11 = 0.0, $2 = 0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0, $7 = 0.0, $8 = 0.0, $9 = 0, label = 0, sp = 0;
  9668. sp = STACKTOP;
  9669. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  9670. $$byval_copy = sp;
  9671. ;HEAP32[$$byval_copy>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy+8>>2]=HEAP32[$0+8>>2]|0;
  9672. $1 = (+_VectorLength($$byval_copy));
  9673. $2 = $1 == 0.0;
  9674. $$op = 1.0 / $1;
  9675. $3 = $2 ? 1.0 : $$op;
  9676. $4 = +HEAPF32[$0>>2];
  9677. $5 = $4 * $3;
  9678. HEAPF32[$0>>2] = $5;
  9679. $6 = ((($0)) + 4|0);
  9680. $7 = +HEAPF32[$6>>2];
  9681. $8 = $3 * $7;
  9682. HEAPF32[$6>>2] = $8;
  9683. $9 = ((($0)) + 8|0);
  9684. $10 = +HEAPF32[$9>>2];
  9685. $11 = $3 * $10;
  9686. HEAPF32[$9>>2] = $11;
  9687. STACKTOP = sp;return;
  9688. }
  9689. function _VectorTransform($0,$1) {
  9690. $0 = $0|0;
  9691. $1 = $1|0;
  9692. var $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0, $14 = 0.0, $15 = 0.0, $16 = 0.0, $17 = 0, $18 = 0.0, $19 = 0.0, $2 = 0.0, $20 = 0, $21 = 0.0, $22 = 0.0, $23 = 0, $24 = 0.0, $25 = 0.0, $26 = 0.0, $27 = 0, $28 = 0.0;
  9693. var $29 = 0.0, $3 = 0, $30 = 0.0, $31 = 0, $32 = 0.0, $33 = 0.0, $34 = 0, $35 = 0.0, $36 = 0.0, $37 = 0, $38 = 0.0, $39 = 0.0, $4 = 0.0, $40 = 0.0, $41 = 0, $42 = 0.0, $43 = 0.0, $44 = 0.0, $45 = 0, $46 = 0.0;
  9694. var $47 = 0.0, $5 = 0, $6 = 0.0, $7 = 0.0, $8 = 0.0, $9 = 0, label = 0, sp = 0;
  9695. sp = STACKTOP;
  9696. $2 = +HEAPF32[$0>>2];
  9697. $3 = ((($0)) + 4|0);
  9698. $4 = +HEAPF32[$3>>2];
  9699. $5 = ((($0)) + 8|0);
  9700. $6 = +HEAPF32[$5>>2];
  9701. $7 = +HEAPF32[$1>>2];
  9702. $8 = $2 * $7;
  9703. $9 = ((($1)) + 4|0);
  9704. $10 = +HEAPF32[$9>>2];
  9705. $11 = $4 * $10;
  9706. $12 = $8 + $11;
  9707. $13 = ((($1)) + 8|0);
  9708. $14 = +HEAPF32[$13>>2];
  9709. $15 = $6 * $14;
  9710. $16 = $12 + $15;
  9711. $17 = ((($1)) + 12|0);
  9712. $18 = +HEAPF32[$17>>2];
  9713. $19 = $18 + $16;
  9714. HEAPF32[$0>>2] = $19;
  9715. $20 = ((($1)) + 16|0);
  9716. $21 = +HEAPF32[$20>>2];
  9717. $22 = $2 * $21;
  9718. $23 = ((($1)) + 20|0);
  9719. $24 = +HEAPF32[$23>>2];
  9720. $25 = $4 * $24;
  9721. $26 = $22 + $25;
  9722. $27 = ((($1)) + 24|0);
  9723. $28 = +HEAPF32[$27>>2];
  9724. $29 = $6 * $28;
  9725. $30 = $26 + $29;
  9726. $31 = ((($1)) + 28|0);
  9727. $32 = +HEAPF32[$31>>2];
  9728. $33 = $32 + $30;
  9729. HEAPF32[$3>>2] = $33;
  9730. $34 = ((($1)) + 32|0);
  9731. $35 = +HEAPF32[$34>>2];
  9732. $36 = $2 * $35;
  9733. $37 = ((($1)) + 36|0);
  9734. $38 = +HEAPF32[$37>>2];
  9735. $39 = $4 * $38;
  9736. $40 = $36 + $39;
  9737. $41 = ((($1)) + 40|0);
  9738. $42 = +HEAPF32[$41>>2];
  9739. $43 = $6 * $42;
  9740. $44 = $40 + $43;
  9741. $45 = ((($1)) + 44|0);
  9742. $46 = +HEAPF32[$45>>2];
  9743. $47 = $46 + $44;
  9744. HEAPF32[$5>>2] = $47;
  9745. return;
  9746. }
  9747. function _MatrixTranspose($0) {
  9748. $0 = $0|0;
  9749. var $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $3 = 0, $4 = 0, $5 = 0;
  9750. var $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  9751. sp = STACKTOP;
  9752. $1 = ((($0)) + 4|0);
  9753. $2 = HEAP32[$1>>2]|0;
  9754. $3 = ((($0)) + 8|0);
  9755. $4 = HEAP32[$3>>2]|0;
  9756. $5 = ((($0)) + 12|0);
  9757. $6 = HEAP32[$5>>2]|0;
  9758. $7 = ((($0)) + 16|0);
  9759. $8 = HEAP32[$7>>2]|0;
  9760. $9 = ((($0)) + 24|0);
  9761. $10 = HEAP32[$9>>2]|0;
  9762. $11 = ((($0)) + 28|0);
  9763. $12 = HEAP32[$11>>2]|0;
  9764. $13 = ((($0)) + 32|0);
  9765. $14 = HEAP32[$13>>2]|0;
  9766. $15 = ((($0)) + 36|0);
  9767. $16 = HEAP32[$15>>2]|0;
  9768. $17 = ((($0)) + 44|0);
  9769. $18 = HEAP32[$17>>2]|0;
  9770. $19 = ((($0)) + 48|0);
  9771. $20 = HEAP32[$19>>2]|0;
  9772. $21 = ((($0)) + 52|0);
  9773. $22 = HEAP32[$21>>2]|0;
  9774. $23 = ((($0)) + 56|0);
  9775. $24 = HEAP32[$23>>2]|0;
  9776. HEAP32[$1>>2] = $8;
  9777. HEAP32[$3>>2] = $14;
  9778. HEAP32[$5>>2] = $20;
  9779. HEAP32[$7>>2] = $2;
  9780. HEAP32[$9>>2] = $16;
  9781. HEAP32[$11>>2] = $22;
  9782. HEAP32[$13>>2] = $4;
  9783. HEAP32[$15>>2] = $10;
  9784. HEAP32[$17>>2] = $24;
  9785. HEAP32[$19>>2] = $6;
  9786. HEAP32[$21>>2] = $12;
  9787. HEAP32[$23>>2] = $18;
  9788. return;
  9789. }
  9790. function _MatrixIdentity($0) {
  9791. $0 = $0|0;
  9792. var $$sroa$5$0$$sroa_idx = 0, $$sroa$55$0$$sroa_idx6 = 0, $$sroa$6$0$$sroa_idx = 0, $$sroa$611$0$$sroa_idx12 = 0, $$sroa$7$0$$sroa_idx = 0, $$sroa$717$0$$sroa_idx18 = 0, label = 0, sp = 0;
  9793. sp = STACKTOP;
  9794. HEAPF32[$0>>2] = 1.0;
  9795. $$sroa$5$0$$sroa_idx = ((($0)) + 4|0);
  9796. ;HEAP32[$$sroa$5$0$$sroa_idx>>2]=0|0;HEAP32[$$sroa$5$0$$sroa_idx+4>>2]=0|0;HEAP32[$$sroa$5$0$$sroa_idx+8>>2]=0|0;HEAP32[$$sroa$5$0$$sroa_idx+12>>2]=0|0;
  9797. $$sroa$55$0$$sroa_idx6 = ((($0)) + 20|0);
  9798. HEAPF32[$$sroa$55$0$$sroa_idx6>>2] = 1.0;
  9799. $$sroa$6$0$$sroa_idx = ((($0)) + 24|0);
  9800. ;HEAP32[$$sroa$6$0$$sroa_idx>>2]=0|0;HEAP32[$$sroa$6$0$$sroa_idx+4>>2]=0|0;HEAP32[$$sroa$6$0$$sroa_idx+8>>2]=0|0;HEAP32[$$sroa$6$0$$sroa_idx+12>>2]=0|0;
  9801. $$sroa$611$0$$sroa_idx12 = ((($0)) + 40|0);
  9802. HEAPF32[$$sroa$611$0$$sroa_idx12>>2] = 1.0;
  9803. $$sroa$7$0$$sroa_idx = ((($0)) + 44|0);
  9804. ;HEAP32[$$sroa$7$0$$sroa_idx>>2]=0|0;HEAP32[$$sroa$7$0$$sroa_idx+4>>2]=0|0;HEAP32[$$sroa$7$0$$sroa_idx+8>>2]=0|0;HEAP32[$$sroa$7$0$$sroa_idx+12>>2]=0|0;
  9805. $$sroa$717$0$$sroa_idx18 = ((($0)) + 60|0);
  9806. HEAPF32[$$sroa$717$0$$sroa_idx18>>2] = 1.0;
  9807. return;
  9808. }
  9809. function _MatrixTranslate($0,$1,$2,$3) {
  9810. $0 = $0|0;
  9811. $1 = +$1;
  9812. $2 = +$2;
  9813. $3 = +$3;
  9814. var $$sroa$13$0$$sroa_idx20 = 0, $$sroa$14$0$$sroa_idx22 = 0, $$sroa$15$0$$sroa_idx24 = 0, $$sroa$16$0$$sroa_idx26 = 0, $$sroa$17$0$$sroa_idx28 = 0, $$sroa$18$0$$sroa_idx30 = 0, $$sroa$4$0$$sroa_idx2 = 0, $$sroa$8$0$$sroa_idx10 = 0, $$sroa$9$0$$sroa_idx12 = 0, label = 0, sp = 0;
  9815. sp = STACKTOP;
  9816. HEAPF32[$0>>2] = 1.0;
  9817. $$sroa$4$0$$sroa_idx2 = ((($0)) + 4|0);
  9818. $$sroa$8$0$$sroa_idx10 = ((($0)) + 20|0);
  9819. ;HEAP32[$$sroa$4$0$$sroa_idx2>>2]=0|0;HEAP32[$$sroa$4$0$$sroa_idx2+4>>2]=0|0;HEAP32[$$sroa$4$0$$sroa_idx2+8>>2]=0|0;HEAP32[$$sroa$4$0$$sroa_idx2+12>>2]=0|0;
  9820. HEAPF32[$$sroa$8$0$$sroa_idx10>>2] = 1.0;
  9821. $$sroa$9$0$$sroa_idx12 = ((($0)) + 24|0);
  9822. $$sroa$13$0$$sroa_idx20 = ((($0)) + 40|0);
  9823. ;HEAP32[$$sroa$9$0$$sroa_idx12>>2]=0|0;HEAP32[$$sroa$9$0$$sroa_idx12+4>>2]=0|0;HEAP32[$$sroa$9$0$$sroa_idx12+8>>2]=0|0;HEAP32[$$sroa$9$0$$sroa_idx12+12>>2]=0|0;
  9824. HEAPF32[$$sroa$13$0$$sroa_idx20>>2] = 1.0;
  9825. $$sroa$14$0$$sroa_idx22 = ((($0)) + 44|0);
  9826. HEAPF32[$$sroa$14$0$$sroa_idx22>>2] = 0.0;
  9827. $$sroa$15$0$$sroa_idx24 = ((($0)) + 48|0);
  9828. HEAPF32[$$sroa$15$0$$sroa_idx24>>2] = $1;
  9829. $$sroa$16$0$$sroa_idx26 = ((($0)) + 52|0);
  9830. HEAPF32[$$sroa$16$0$$sroa_idx26>>2] = $2;
  9831. $$sroa$17$0$$sroa_idx28 = ((($0)) + 56|0);
  9832. HEAPF32[$$sroa$17$0$$sroa_idx28>>2] = $3;
  9833. $$sroa$18$0$$sroa_idx30 = ((($0)) + 60|0);
  9834. HEAPF32[$$sroa$18$0$$sroa_idx30>>2] = 1.0;
  9835. return;
  9836. }
  9837. function _MatrixRotate($0,$1,$2) {
  9838. $0 = $0|0;
  9839. $1 = $1|0;
  9840. $2 = +$2;
  9841. var $$ = 0.0, $$221 = 0.0, $$222 = 0.0, $$sroa$10$0$$sroa_idx199 = 0, $$sroa$11$0$$sroa_idx201 = 0, $$sroa$12$0$$sroa_idx203 = 0, $$sroa$13$0$$sroa_idx205 = 0, $$sroa$14$0$$sroa_idx207 = 0, $$sroa$15$0$$sroa_idx209 = 0, $$sroa$16$0$$sroa_idx211 = 0, $$sroa$17$0$$sroa_idx213 = 0, $$sroa$18$0$$sroa_idx215 = 0, $$sroa$4$0$$sroa_idx187 = 0, $$sroa$5$0$$sroa_idx189 = 0, $$sroa$6$0$$sroa_idx191 = 0, $$sroa$7$0$$sroa_idx193 = 0, $$sroa$8$0$$sroa_idx195 = 0, $$sroa$9$0$$sroa_idx197 = 0, $10 = 0.0, $100 = 0.0;
  9842. var $101 = 0.0, $102 = 0.0, $103 = 0.0, $104 = 0.0, $105 = 0.0, $106 = 0.0, $107 = 0.0, $108 = 0.0, $109 = 0.0, $11 = 0.0, $110 = 0.0, $111 = 0.0, $112 = 0.0, $113 = 0.0, $114 = 0.0, $115 = 0.0, $116 = 0.0, $117 = 0.0, $118 = 0.0, $119 = 0.0;
  9843. var $12 = 0.0, $120 = 0.0, $121 = 0.0, $122 = 0.0, $123 = 0.0, $124 = 0.0, $125 = 0.0, $126 = 0.0, $127 = 0.0, $128 = 0.0, $129 = 0.0, $13 = 0.0, $130 = 0.0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0;
  9844. var $138 = 0, $14 = 0.0, $15 = 0, $16 = 0, $17 = 0.0, $18 = 0.0, $19 = 0.0, $20 = 0.0, $21 = 0.0, $22 = 0.0, $23 = 0.0, $24 = 0.0, $25 = 0, $26 = 0.0, $27 = 0, $28 = 0.0, $29 = 0, $3 = 0, $30 = 0.0, $31 = 0;
  9845. var $32 = 0.0, $33 = 0, $34 = 0.0, $35 = 0, $36 = 0.0, $37 = 0, $38 = 0.0, $39 = 0, $4 = 0.0, $40 = 0.0, $41 = 0, $42 = 0.0, $43 = 0, $44 = 0.0, $45 = 0, $46 = 0.0, $47 = 0.0, $48 = 0.0, $49 = 0.0, $5 = 0;
  9846. var $50 = 0.0, $51 = 0.0, $52 = 0.0, $53 = 0.0, $54 = 0.0, $55 = 0.0, $56 = 0.0, $57 = 0.0, $58 = 0.0, $59 = 0.0, $6 = 0.0, $60 = 0.0, $61 = 0.0, $62 = 0.0, $63 = 0.0, $64 = 0.0, $65 = 0.0, $66 = 0.0, $67 = 0.0, $68 = 0.0;
  9847. var $69 = 0.0, $7 = 0, $70 = 0.0, $71 = 0.0, $72 = 0.0, $73 = 0.0, $74 = 0.0, $75 = 0.0, $76 = 0.0, $77 = 0.0, $78 = 0.0, $79 = 0.0, $8 = 0.0, $80 = 0.0, $81 = 0.0, $82 = 0.0, $83 = 0.0, $84 = 0.0, $85 = 0.0, $86 = 0.0;
  9848. var $87 = 0.0, $88 = 0.0, $89 = 0.0, $9 = 0.0, $90 = 0.0, $91 = 0.0, $92 = 0.0, $93 = 0.0, $94 = 0.0, $95 = 0.0, $96 = 0.0, $97 = 0.0, $98 = 0.0, $99 = 0.0, $or$cond = 0, label = 0, sp = 0;
  9849. sp = STACKTOP;
  9850. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  9851. $3 = sp;
  9852. _MatrixIdentity($3);
  9853. $4 = +HEAPF32[$1>>2];
  9854. $5 = ((($1)) + 4|0);
  9855. $6 = +HEAPF32[$5>>2];
  9856. $7 = ((($1)) + 8|0);
  9857. $8 = +HEAPF32[$7>>2];
  9858. $9 = $4 * $4;
  9859. $10 = $6 * $6;
  9860. $11 = $9 + $10;
  9861. $12 = $8 * $8;
  9862. $13 = $11 + $12;
  9863. $14 = (+Math_sqrt((+$13)));
  9864. $15 = $14 != 1.0;
  9865. $16 = $14 != 0.0;
  9866. $or$cond = $15 & $16;
  9867. $17 = 1.0 / $14;
  9868. $18 = $4 * $17;
  9869. $19 = $6 * $17;
  9870. $20 = $8 * $17;
  9871. $$ = $or$cond ? $20 : $8;
  9872. $$221 = $or$cond ? $19 : $6;
  9873. $$222 = $or$cond ? $18 : $4;
  9874. $21 = (+Math_sin((+$2)));
  9875. $22 = (+Math_cos((+$2)));
  9876. $23 = 1.0 - $22;
  9877. $24 = +HEAPF32[$3>>2];
  9878. $25 = ((($3)) + 16|0);
  9879. $26 = +HEAPF32[$25>>2];
  9880. $27 = ((($3)) + 32|0);
  9881. $28 = +HEAPF32[$27>>2];
  9882. $29 = ((($3)) + 48|0);
  9883. $30 = +HEAPF32[$29>>2];
  9884. $31 = ((($3)) + 4|0);
  9885. $32 = +HEAPF32[$31>>2];
  9886. $33 = ((($3)) + 20|0);
  9887. $34 = +HEAPF32[$33>>2];
  9888. $35 = ((($3)) + 36|0);
  9889. $36 = +HEAPF32[$35>>2];
  9890. $37 = ((($3)) + 52|0);
  9891. $38 = +HEAPF32[$37>>2];
  9892. $39 = ((($3)) + 8|0);
  9893. $40 = +HEAPF32[$39>>2];
  9894. $41 = ((($3)) + 24|0);
  9895. $42 = +HEAPF32[$41>>2];
  9896. $43 = ((($3)) + 40|0);
  9897. $44 = +HEAPF32[$43>>2];
  9898. $45 = ((($3)) + 56|0);
  9899. $46 = +HEAPF32[$45>>2];
  9900. $47 = $$222 * $$222;
  9901. $48 = $23 * $47;
  9902. $49 = $22 + $48;
  9903. $50 = $$221 * $$222;
  9904. $51 = $23 * $50;
  9905. $52 = $21 * $$;
  9906. $53 = $52 + $51;
  9907. $54 = $$ * $$222;
  9908. $55 = $23 * $54;
  9909. $56 = $21 * $$221;
  9910. $57 = $55 - $56;
  9911. $58 = $51 - $52;
  9912. $59 = $$221 * $$221;
  9913. $60 = $23 * $59;
  9914. $61 = $22 + $60;
  9915. $62 = $$ * $$221;
  9916. $63 = $23 * $62;
  9917. $64 = $21 * $$222;
  9918. $65 = $64 + $63;
  9919. $66 = $56 + $55;
  9920. $67 = $63 - $64;
  9921. $68 = $$ * $$;
  9922. $69 = $23 * $68;
  9923. $70 = $22 + $69;
  9924. $71 = $24 * $49;
  9925. $72 = $53 * $32;
  9926. $73 = $71 + $72;
  9927. $74 = $57 * $40;
  9928. $75 = $73 + $74;
  9929. $76 = $26 * $49;
  9930. $77 = $53 * $34;
  9931. $78 = $76 + $77;
  9932. $79 = $57 * $42;
  9933. $80 = $78 + $79;
  9934. $81 = $28 * $49;
  9935. $82 = $53 * $36;
  9936. $83 = $81 + $82;
  9937. $84 = $57 * $44;
  9938. $85 = $83 + $84;
  9939. $86 = $30 * $49;
  9940. $87 = $53 * $38;
  9941. $88 = $86 + $87;
  9942. $89 = $57 * $46;
  9943. $90 = $88 + $89;
  9944. $91 = $24 * $58;
  9945. $92 = $61 * $32;
  9946. $93 = $91 + $92;
  9947. $94 = $65 * $40;
  9948. $95 = $93 + $94;
  9949. $96 = $26 * $58;
  9950. $97 = $61 * $34;
  9951. $98 = $96 + $97;
  9952. $99 = $65 * $42;
  9953. $100 = $98 + $99;
  9954. $101 = $28 * $58;
  9955. $102 = $61 * $36;
  9956. $103 = $101 + $102;
  9957. $104 = $65 * $44;
  9958. $105 = $103 + $104;
  9959. $106 = $30 * $58;
  9960. $107 = $61 * $38;
  9961. $108 = $106 + $107;
  9962. $109 = $65 * $46;
  9963. $110 = $108 + $109;
  9964. $111 = $24 * $66;
  9965. $112 = $67 * $32;
  9966. $113 = $111 + $112;
  9967. $114 = $70 * $40;
  9968. $115 = $113 + $114;
  9969. $116 = $26 * $66;
  9970. $117 = $67 * $34;
  9971. $118 = $116 + $117;
  9972. $119 = $70 * $42;
  9973. $120 = $118 + $119;
  9974. $121 = $28 * $66;
  9975. $122 = $67 * $36;
  9976. $123 = $121 + $122;
  9977. $124 = $70 * $44;
  9978. $125 = $123 + $124;
  9979. $126 = $30 * $66;
  9980. $127 = $67 * $38;
  9981. $128 = $126 + $127;
  9982. $129 = $70 * $46;
  9983. $130 = $128 + $129;
  9984. $131 = ((($3)) + 12|0);
  9985. $132 = HEAP32[$131>>2]|0;
  9986. $133 = ((($3)) + 28|0);
  9987. $134 = HEAP32[$133>>2]|0;
  9988. $135 = ((($3)) + 44|0);
  9989. $136 = HEAP32[$135>>2]|0;
  9990. $137 = ((($3)) + 60|0);
  9991. $138 = HEAP32[$137>>2]|0;
  9992. HEAPF32[$0>>2] = $75;
  9993. $$sroa$4$0$$sroa_idx187 = ((($0)) + 4|0);
  9994. HEAPF32[$$sroa$4$0$$sroa_idx187>>2] = $95;
  9995. $$sroa$5$0$$sroa_idx189 = ((($0)) + 8|0);
  9996. HEAPF32[$$sroa$5$0$$sroa_idx189>>2] = $115;
  9997. $$sroa$6$0$$sroa_idx191 = ((($0)) + 12|0);
  9998. HEAP32[$$sroa$6$0$$sroa_idx191>>2] = $132;
  9999. $$sroa$7$0$$sroa_idx193 = ((($0)) + 16|0);
  10000. HEAPF32[$$sroa$7$0$$sroa_idx193>>2] = $80;
  10001. $$sroa$8$0$$sroa_idx195 = ((($0)) + 20|0);
  10002. HEAPF32[$$sroa$8$0$$sroa_idx195>>2] = $100;
  10003. $$sroa$9$0$$sroa_idx197 = ((($0)) + 24|0);
  10004. HEAPF32[$$sroa$9$0$$sroa_idx197>>2] = $120;
  10005. $$sroa$10$0$$sroa_idx199 = ((($0)) + 28|0);
  10006. HEAP32[$$sroa$10$0$$sroa_idx199>>2] = $134;
  10007. $$sroa$11$0$$sroa_idx201 = ((($0)) + 32|0);
  10008. HEAPF32[$$sroa$11$0$$sroa_idx201>>2] = $85;
  10009. $$sroa$12$0$$sroa_idx203 = ((($0)) + 36|0);
  10010. HEAPF32[$$sroa$12$0$$sroa_idx203>>2] = $105;
  10011. $$sroa$13$0$$sroa_idx205 = ((($0)) + 40|0);
  10012. HEAPF32[$$sroa$13$0$$sroa_idx205>>2] = $125;
  10013. $$sroa$14$0$$sroa_idx207 = ((($0)) + 44|0);
  10014. HEAP32[$$sroa$14$0$$sroa_idx207>>2] = $136;
  10015. $$sroa$15$0$$sroa_idx209 = ((($0)) + 48|0);
  10016. HEAPF32[$$sroa$15$0$$sroa_idx209>>2] = $90;
  10017. $$sroa$16$0$$sroa_idx211 = ((($0)) + 52|0);
  10018. HEAPF32[$$sroa$16$0$$sroa_idx211>>2] = $110;
  10019. $$sroa$17$0$$sroa_idx213 = ((($0)) + 56|0);
  10020. HEAPF32[$$sroa$17$0$$sroa_idx213>>2] = $130;
  10021. $$sroa$18$0$$sroa_idx215 = ((($0)) + 60|0);
  10022. HEAP32[$$sroa$18$0$$sroa_idx215>>2] = $138;
  10023. STACKTOP = sp;return;
  10024. }
  10025. function _MatrixScale($0,$1,$2,$3) {
  10026. $0 = $0|0;
  10027. $1 = +$1;
  10028. $2 = +$2;
  10029. $3 = +$3;
  10030. var $$sroa$5$0$$sroa_idx = 0, $$sroa$55$0$$sroa_idx6 = 0, $$sroa$6$0$$sroa_idx = 0, $$sroa$611$0$$sroa_idx12 = 0, $$sroa$7$0$$sroa_idx = 0, $$sroa$717$0$$sroa_idx18 = 0, label = 0, sp = 0;
  10031. sp = STACKTOP;
  10032. HEAPF32[$0>>2] = $1;
  10033. $$sroa$5$0$$sroa_idx = ((($0)) + 4|0);
  10034. ;HEAP32[$$sroa$5$0$$sroa_idx>>2]=0|0;HEAP32[$$sroa$5$0$$sroa_idx+4>>2]=0|0;HEAP32[$$sroa$5$0$$sroa_idx+8>>2]=0|0;HEAP32[$$sroa$5$0$$sroa_idx+12>>2]=0|0;
  10035. $$sroa$55$0$$sroa_idx6 = ((($0)) + 20|0);
  10036. HEAPF32[$$sroa$55$0$$sroa_idx6>>2] = $2;
  10037. $$sroa$6$0$$sroa_idx = ((($0)) + 24|0);
  10038. ;HEAP32[$$sroa$6$0$$sroa_idx>>2]=0|0;HEAP32[$$sroa$6$0$$sroa_idx+4>>2]=0|0;HEAP32[$$sroa$6$0$$sroa_idx+8>>2]=0|0;HEAP32[$$sroa$6$0$$sroa_idx+12>>2]=0|0;
  10039. $$sroa$611$0$$sroa_idx12 = ((($0)) + 40|0);
  10040. HEAPF32[$$sroa$611$0$$sroa_idx12>>2] = $3;
  10041. $$sroa$7$0$$sroa_idx = ((($0)) + 44|0);
  10042. ;HEAP32[$$sroa$7$0$$sroa_idx>>2]=0|0;HEAP32[$$sroa$7$0$$sroa_idx+4>>2]=0|0;HEAP32[$$sroa$7$0$$sroa_idx+8>>2]=0|0;HEAP32[$$sroa$7$0$$sroa_idx+12>>2]=0|0;
  10043. $$sroa$717$0$$sroa_idx18 = ((($0)) + 60|0);
  10044. HEAPF32[$$sroa$717$0$$sroa_idx18>>2] = 1.0;
  10045. return;
  10046. }
  10047. function _MatrixMultiply($0,$1,$2) {
  10048. $0 = $0|0;
  10049. $1 = $1|0;
  10050. $2 = $2|0;
  10051. var $$sroa$10$0$$sroa_idx14 = 0, $$sroa$11$0$$sroa_idx16 = 0, $$sroa$12$0$$sroa_idx18 = 0, $$sroa$13$0$$sroa_idx20 = 0, $$sroa$14$0$$sroa_idx22 = 0, $$sroa$15$0$$sroa_idx24 = 0, $$sroa$16$0$$sroa_idx26 = 0, $$sroa$17$0$$sroa_idx28 = 0, $$sroa$18$0$$sroa_idx30 = 0, $$sroa$4$0$$sroa_idx2 = 0, $$sroa$5$0$$sroa_idx4 = 0, $$sroa$6$0$$sroa_idx6 = 0, $$sroa$7$0$$sroa_idx8 = 0, $$sroa$8$0$$sroa_idx10 = 0, $$sroa$9$0$$sroa_idx12 = 0, $10 = 0.0, $100 = 0.0, $101 = 0.0, $102 = 0.0, $103 = 0.0;
  10052. var $104 = 0.0, $105 = 0, $106 = 0.0, $107 = 0.0, $108 = 0, $109 = 0.0, $11 = 0.0, $110 = 0.0, $111 = 0.0, $112 = 0, $113 = 0.0, $114 = 0.0, $115 = 0.0, $116 = 0, $117 = 0.0, $118 = 0.0, $119 = 0.0, $12 = 0, $120 = 0.0, $121 = 0.0;
  10053. var $122 = 0.0, $123 = 0.0, $124 = 0.0, $125 = 0.0, $126 = 0.0, $127 = 0.0, $128 = 0.0, $129 = 0.0, $13 = 0.0, $130 = 0.0, $131 = 0.0, $132 = 0.0, $133 = 0.0, $134 = 0.0, $135 = 0.0, $136 = 0.0, $137 = 0.0, $138 = 0.0, $139 = 0.0, $14 = 0;
  10054. var $140 = 0.0, $141 = 0, $142 = 0.0, $143 = 0.0, $144 = 0, $145 = 0.0, $146 = 0.0, $147 = 0.0, $148 = 0, $149 = 0.0, $15 = 0.0, $150 = 0.0, $151 = 0.0, $152 = 0, $153 = 0.0, $154 = 0.0, $155 = 0.0, $156 = 0.0, $157 = 0.0, $158 = 0.0;
  10055. var $159 = 0.0, $16 = 0.0, $160 = 0.0, $161 = 0.0, $162 = 0.0, $163 = 0.0, $164 = 0.0, $165 = 0.0, $166 = 0.0, $167 = 0.0, $168 = 0.0, $169 = 0.0, $17 = 0.0, $170 = 0.0, $171 = 0.0, $172 = 0.0, $173 = 0.0, $174 = 0.0, $175 = 0.0, $176 = 0.0;
  10056. var $18 = 0, $19 = 0.0, $20 = 0, $21 = 0.0, $22 = 0.0, $23 = 0.0, $24 = 0, $25 = 0.0, $26 = 0.0, $27 = 0, $28 = 0.0, $29 = 0.0, $3 = 0.0, $30 = 0.0, $31 = 0, $32 = 0.0, $33 = 0.0, $34 = 0.0, $35 = 0, $36 = 0.0;
  10057. var $37 = 0.0, $38 = 0.0, $39 = 0, $4 = 0.0, $40 = 0.0, $41 = 0.0, $42 = 0, $43 = 0.0, $44 = 0.0, $45 = 0.0, $46 = 0, $47 = 0.0, $48 = 0.0, $49 = 0.0, $5 = 0.0, $50 = 0, $51 = 0.0, $52 = 0.0, $53 = 0.0, $54 = 0;
  10058. var $55 = 0.0, $56 = 0.0, $57 = 0, $58 = 0.0, $59 = 0.0, $6 = 0, $60 = 0.0, $61 = 0, $62 = 0.0, $63 = 0.0, $64 = 0.0, $65 = 0, $66 = 0.0, $67 = 0.0, $68 = 0.0, $69 = 0, $7 = 0.0, $70 = 0.0, $71 = 0.0, $72 = 0;
  10059. var $73 = 0.0, $74 = 0.0, $75 = 0.0, $76 = 0, $77 = 0.0, $78 = 0.0, $79 = 0.0, $8 = 0, $80 = 0, $81 = 0.0, $82 = 0.0, $83 = 0.0, $84 = 0.0, $85 = 0.0, $86 = 0.0, $87 = 0.0, $88 = 0.0, $89 = 0.0, $9 = 0.0, $90 = 0.0;
  10060. var $91 = 0.0, $92 = 0.0, $93 = 0.0, $94 = 0.0, $95 = 0.0, $96 = 0.0, $97 = 0.0, $98 = 0.0, $99 = 0.0, label = 0, sp = 0;
  10061. sp = STACKTOP;
  10062. $3 = +HEAPF32[$2>>2];
  10063. $4 = +HEAPF32[$1>>2];
  10064. $5 = $3 * $4;
  10065. $6 = ((($2)) + 16|0);
  10066. $7 = +HEAPF32[$6>>2];
  10067. $8 = ((($1)) + 4|0);
  10068. $9 = +HEAPF32[$8>>2];
  10069. $10 = $7 * $9;
  10070. $11 = $5 + $10;
  10071. $12 = ((($2)) + 32|0);
  10072. $13 = +HEAPF32[$12>>2];
  10073. $14 = ((($1)) + 8|0);
  10074. $15 = +HEAPF32[$14>>2];
  10075. $16 = $13 * $15;
  10076. $17 = $11 + $16;
  10077. $18 = ((($2)) + 48|0);
  10078. $19 = +HEAPF32[$18>>2];
  10079. $20 = ((($1)) + 12|0);
  10080. $21 = +HEAPF32[$20>>2];
  10081. $22 = $19 * $21;
  10082. $23 = $17 + $22;
  10083. $24 = ((($1)) + 16|0);
  10084. $25 = +HEAPF32[$24>>2];
  10085. $26 = $3 * $25;
  10086. $27 = ((($1)) + 20|0);
  10087. $28 = +HEAPF32[$27>>2];
  10088. $29 = $7 * $28;
  10089. $30 = $26 + $29;
  10090. $31 = ((($1)) + 24|0);
  10091. $32 = +HEAPF32[$31>>2];
  10092. $33 = $13 * $32;
  10093. $34 = $30 + $33;
  10094. $35 = ((($1)) + 28|0);
  10095. $36 = +HEAPF32[$35>>2];
  10096. $37 = $19 * $36;
  10097. $38 = $34 + $37;
  10098. $39 = ((($1)) + 32|0);
  10099. $40 = +HEAPF32[$39>>2];
  10100. $41 = $3 * $40;
  10101. $42 = ((($1)) + 36|0);
  10102. $43 = +HEAPF32[$42>>2];
  10103. $44 = $7 * $43;
  10104. $45 = $41 + $44;
  10105. $46 = ((($1)) + 40|0);
  10106. $47 = +HEAPF32[$46>>2];
  10107. $48 = $13 * $47;
  10108. $49 = $45 + $48;
  10109. $50 = ((($1)) + 44|0);
  10110. $51 = +HEAPF32[$50>>2];
  10111. $52 = $19 * $51;
  10112. $53 = $49 + $52;
  10113. $54 = ((($1)) + 48|0);
  10114. $55 = +HEAPF32[$54>>2];
  10115. $56 = $3 * $55;
  10116. $57 = ((($1)) + 52|0);
  10117. $58 = +HEAPF32[$57>>2];
  10118. $59 = $7 * $58;
  10119. $60 = $56 + $59;
  10120. $61 = ((($1)) + 56|0);
  10121. $62 = +HEAPF32[$61>>2];
  10122. $63 = $13 * $62;
  10123. $64 = $60 + $63;
  10124. $65 = ((($1)) + 60|0);
  10125. $66 = +HEAPF32[$65>>2];
  10126. $67 = $19 * $66;
  10127. $68 = $64 + $67;
  10128. $69 = ((($2)) + 4|0);
  10129. $70 = +HEAPF32[$69>>2];
  10130. $71 = $4 * $70;
  10131. $72 = ((($2)) + 20|0);
  10132. $73 = +HEAPF32[$72>>2];
  10133. $74 = $9 * $73;
  10134. $75 = $71 + $74;
  10135. $76 = ((($2)) + 36|0);
  10136. $77 = +HEAPF32[$76>>2];
  10137. $78 = $15 * $77;
  10138. $79 = $75 + $78;
  10139. $80 = ((($2)) + 52|0);
  10140. $81 = +HEAPF32[$80>>2];
  10141. $82 = $21 * $81;
  10142. $83 = $79 + $82;
  10143. $84 = $25 * $70;
  10144. $85 = $28 * $73;
  10145. $86 = $84 + $85;
  10146. $87 = $32 * $77;
  10147. $88 = $86 + $87;
  10148. $89 = $36 * $81;
  10149. $90 = $88 + $89;
  10150. $91 = $40 * $70;
  10151. $92 = $43 * $73;
  10152. $93 = $91 + $92;
  10153. $94 = $47 * $77;
  10154. $95 = $93 + $94;
  10155. $96 = $51 * $81;
  10156. $97 = $95 + $96;
  10157. $98 = $55 * $70;
  10158. $99 = $58 * $73;
  10159. $100 = $98 + $99;
  10160. $101 = $62 * $77;
  10161. $102 = $100 + $101;
  10162. $103 = $66 * $81;
  10163. $104 = $102 + $103;
  10164. $105 = ((($2)) + 8|0);
  10165. $106 = +HEAPF32[$105>>2];
  10166. $107 = $4 * $106;
  10167. $108 = ((($2)) + 24|0);
  10168. $109 = +HEAPF32[$108>>2];
  10169. $110 = $9 * $109;
  10170. $111 = $107 + $110;
  10171. $112 = ((($2)) + 40|0);
  10172. $113 = +HEAPF32[$112>>2];
  10173. $114 = $15 * $113;
  10174. $115 = $111 + $114;
  10175. $116 = ((($2)) + 56|0);
  10176. $117 = +HEAPF32[$116>>2];
  10177. $118 = $21 * $117;
  10178. $119 = $115 + $118;
  10179. $120 = $25 * $106;
  10180. $121 = $28 * $109;
  10181. $122 = $120 + $121;
  10182. $123 = $32 * $113;
  10183. $124 = $122 + $123;
  10184. $125 = $36 * $117;
  10185. $126 = $124 + $125;
  10186. $127 = $40 * $106;
  10187. $128 = $43 * $109;
  10188. $129 = $127 + $128;
  10189. $130 = $47 * $113;
  10190. $131 = $129 + $130;
  10191. $132 = $51 * $117;
  10192. $133 = $131 + $132;
  10193. $134 = $55 * $106;
  10194. $135 = $58 * $109;
  10195. $136 = $134 + $135;
  10196. $137 = $62 * $113;
  10197. $138 = $136 + $137;
  10198. $139 = $66 * $117;
  10199. $140 = $138 + $139;
  10200. $141 = ((($2)) + 12|0);
  10201. $142 = +HEAPF32[$141>>2];
  10202. $143 = $4 * $142;
  10203. $144 = ((($2)) + 28|0);
  10204. $145 = +HEAPF32[$144>>2];
  10205. $146 = $9 * $145;
  10206. $147 = $143 + $146;
  10207. $148 = ((($2)) + 44|0);
  10208. $149 = +HEAPF32[$148>>2];
  10209. $150 = $15 * $149;
  10210. $151 = $147 + $150;
  10211. $152 = ((($2)) + 60|0);
  10212. $153 = +HEAPF32[$152>>2];
  10213. $154 = $21 * $153;
  10214. $155 = $151 + $154;
  10215. $156 = $25 * $142;
  10216. $157 = $28 * $145;
  10217. $158 = $156 + $157;
  10218. $159 = $32 * $149;
  10219. $160 = $158 + $159;
  10220. $161 = $36 * $153;
  10221. $162 = $160 + $161;
  10222. $163 = $40 * $142;
  10223. $164 = $43 * $145;
  10224. $165 = $163 + $164;
  10225. $166 = $47 * $149;
  10226. $167 = $165 + $166;
  10227. $168 = $51 * $153;
  10228. $169 = $167 + $168;
  10229. $170 = $55 * $142;
  10230. $171 = $58 * $145;
  10231. $172 = $170 + $171;
  10232. $173 = $62 * $149;
  10233. $174 = $172 + $173;
  10234. $175 = $66 * $153;
  10235. $176 = $174 + $175;
  10236. HEAPF32[$0>>2] = $23;
  10237. $$sroa$4$0$$sroa_idx2 = ((($0)) + 4|0);
  10238. HEAPF32[$$sroa$4$0$$sroa_idx2>>2] = $83;
  10239. $$sroa$5$0$$sroa_idx4 = ((($0)) + 8|0);
  10240. HEAPF32[$$sroa$5$0$$sroa_idx4>>2] = $119;
  10241. $$sroa$6$0$$sroa_idx6 = ((($0)) + 12|0);
  10242. HEAPF32[$$sroa$6$0$$sroa_idx6>>2] = $155;
  10243. $$sroa$7$0$$sroa_idx8 = ((($0)) + 16|0);
  10244. HEAPF32[$$sroa$7$0$$sroa_idx8>>2] = $38;
  10245. $$sroa$8$0$$sroa_idx10 = ((($0)) + 20|0);
  10246. HEAPF32[$$sroa$8$0$$sroa_idx10>>2] = $90;
  10247. $$sroa$9$0$$sroa_idx12 = ((($0)) + 24|0);
  10248. HEAPF32[$$sroa$9$0$$sroa_idx12>>2] = $126;
  10249. $$sroa$10$0$$sroa_idx14 = ((($0)) + 28|0);
  10250. HEAPF32[$$sroa$10$0$$sroa_idx14>>2] = $162;
  10251. $$sroa$11$0$$sroa_idx16 = ((($0)) + 32|0);
  10252. HEAPF32[$$sroa$11$0$$sroa_idx16>>2] = $53;
  10253. $$sroa$12$0$$sroa_idx18 = ((($0)) + 36|0);
  10254. HEAPF32[$$sroa$12$0$$sroa_idx18>>2] = $97;
  10255. $$sroa$13$0$$sroa_idx20 = ((($0)) + 40|0);
  10256. HEAPF32[$$sroa$13$0$$sroa_idx20>>2] = $133;
  10257. $$sroa$14$0$$sroa_idx22 = ((($0)) + 44|0);
  10258. HEAPF32[$$sroa$14$0$$sroa_idx22>>2] = $169;
  10259. $$sroa$15$0$$sroa_idx24 = ((($0)) + 48|0);
  10260. HEAPF32[$$sroa$15$0$$sroa_idx24>>2] = $68;
  10261. $$sroa$16$0$$sroa_idx26 = ((($0)) + 52|0);
  10262. HEAPF32[$$sroa$16$0$$sroa_idx26>>2] = $104;
  10263. $$sroa$17$0$$sroa_idx28 = ((($0)) + 56|0);
  10264. HEAPF32[$$sroa$17$0$$sroa_idx28>>2] = $140;
  10265. $$sroa$18$0$$sroa_idx30 = ((($0)) + 60|0);
  10266. HEAPF32[$$sroa$18$0$$sroa_idx30>>2] = $176;
  10267. return;
  10268. }
  10269. function _MatrixOrtho($0,$1,$2,$3,$4,$5,$6) {
  10270. $0 = $0|0;
  10271. $1 = +$1;
  10272. $2 = +$2;
  10273. $3 = +$3;
  10274. $4 = +$4;
  10275. $5 = +$5;
  10276. $6 = +$6;
  10277. var $$sroa$10$0$$sroa_idx24 = 0, $$sroa$11$0$$sroa_idx26 = 0, $$sroa$12$0$$sroa_idx28 = 0, $$sroa$13$0$$sroa_idx30 = 0, $$sroa$14$0$$sroa_idx32 = 0, $$sroa$15$0$$sroa_idx34 = 0, $$sroa$16$0$$sroa_idx36 = 0, $$sroa$17$0$$sroa_idx38 = 0, $$sroa$18$0$$sroa_idx40 = 0, $$sroa$4$0$$sroa_idx12 = 0, $$sroa$5$0$$sroa_idx14 = 0, $$sroa$6$0$$sroa_idx16 = 0, $$sroa$7$0$$sroa_idx18 = 0, $$sroa$8$0$$sroa_idx20 = 0, $$sroa$9$0$$sroa_idx22 = 0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $14 = 0.0;
  10278. var $15 = 0.0, $16 = 0.0, $17 = 0.0, $18 = 0.0, $19 = 0.0, $20 = 0.0, $21 = 0.0, $22 = 0.0, $23 = 0.0, $24 = 0.0, $25 = 0.0, $26 = 0.0, $27 = 0.0, $28 = 0.0, $29 = 0.0, $30 = 0.0, $7 = 0.0, $8 = 0.0, $9 = 0.0, label = 0;
  10279. var sp = 0;
  10280. sp = STACKTOP;
  10281. $7 = $2 - $1;
  10282. $8 = $7;
  10283. $9 = $4 - $3;
  10284. $10 = $9;
  10285. $11 = $6 - $5;
  10286. $12 = $11;
  10287. $13 = 2.0 / $8;
  10288. $14 = 2.0 / $10;
  10289. $15 = -2.0 / $12;
  10290. $16 = $1 + $2;
  10291. $17 = -$16;
  10292. $18 = $8;
  10293. $19 = $17 / $18;
  10294. $20 = $19;
  10295. $21 = $3 + $4;
  10296. $22 = -$21;
  10297. $23 = $10;
  10298. $24 = $22 / $23;
  10299. $25 = $24;
  10300. $26 = $5 + $6;
  10301. $27 = -$26;
  10302. $28 = $12;
  10303. $29 = $27 / $28;
  10304. $30 = $29;
  10305. HEAPF32[$0>>2] = $13;
  10306. $$sroa$4$0$$sroa_idx12 = ((($0)) + 4|0);
  10307. HEAPF32[$$sroa$4$0$$sroa_idx12>>2] = 0.0;
  10308. $$sroa$5$0$$sroa_idx14 = ((($0)) + 8|0);
  10309. HEAPF32[$$sroa$5$0$$sroa_idx14>>2] = 0.0;
  10310. $$sroa$6$0$$sroa_idx16 = ((($0)) + 12|0);
  10311. HEAPF32[$$sroa$6$0$$sroa_idx16>>2] = $20;
  10312. $$sroa$7$0$$sroa_idx18 = ((($0)) + 16|0);
  10313. HEAPF32[$$sroa$7$0$$sroa_idx18>>2] = 0.0;
  10314. $$sroa$8$0$$sroa_idx20 = ((($0)) + 20|0);
  10315. HEAPF32[$$sroa$8$0$$sroa_idx20>>2] = $14;
  10316. $$sroa$9$0$$sroa_idx22 = ((($0)) + 24|0);
  10317. HEAPF32[$$sroa$9$0$$sroa_idx22>>2] = 0.0;
  10318. $$sroa$10$0$$sroa_idx24 = ((($0)) + 28|0);
  10319. HEAPF32[$$sroa$10$0$$sroa_idx24>>2] = $25;
  10320. $$sroa$11$0$$sroa_idx26 = ((($0)) + 32|0);
  10321. HEAPF32[$$sroa$11$0$$sroa_idx26>>2] = 0.0;
  10322. $$sroa$12$0$$sroa_idx28 = ((($0)) + 36|0);
  10323. HEAPF32[$$sroa$12$0$$sroa_idx28>>2] = 0.0;
  10324. $$sroa$13$0$$sroa_idx30 = ((($0)) + 40|0);
  10325. HEAPF32[$$sroa$13$0$$sroa_idx30>>2] = $15;
  10326. $$sroa$14$0$$sroa_idx32 = ((($0)) + 44|0);
  10327. HEAPF32[$$sroa$14$0$$sroa_idx32>>2] = $30;
  10328. $$sroa$15$0$$sroa_idx34 = ((($0)) + 48|0);
  10329. HEAPF32[$$sroa$15$0$$sroa_idx34>>2] = 0.0;
  10330. $$sroa$16$0$$sroa_idx36 = ((($0)) + 52|0);
  10331. HEAPF32[$$sroa$16$0$$sroa_idx36>>2] = 0.0;
  10332. $$sroa$17$0$$sroa_idx38 = ((($0)) + 56|0);
  10333. HEAPF32[$$sroa$17$0$$sroa_idx38>>2] = 0.0;
  10334. $$sroa$18$0$$sroa_idx40 = ((($0)) + 60|0);
  10335. HEAPF32[$$sroa$18$0$$sroa_idx40>>2] = 1.0;
  10336. return;
  10337. }
  10338. function _ProcessGestureEvent($0) {
  10339. $0 = $0|0;
  10340. var $$$sink = 0, $$sink = 0, $$sink10 = 0, $$sink11 = 0, $$sink16 = 0, $1 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0.0, $111 = 0.0;
  10341. var $112 = 0.0, $113 = 0.0, $114 = 0.0, $115 = 0.0, $116 = 0.0, $117 = 0, $118 = 0, $119 = 0, $12 = 0.0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0;
  10342. var $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0;
  10343. var $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0.0, $16 = 0, $160 = 0.0, $161 = 0.0, $162 = 0.0, $163 = 0.0, $164 = 0.0, $165 = 0.0, $166 = 0;
  10344. var $167 = 0.0, $168 = 0, $169 = 0.0, $17 = 0, $170 = 0.0, $171 = 0.0, $172 = 0, $173 = 0.0, $174 = 0.0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0;
  10345. var $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0;
  10346. var $46 = 0, $47 = 0, $48 = 0.0, $49 = 0.0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0.0, $56 = 0.0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0;
  10347. var $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0.0, $81 = 0;
  10348. var $82 = 0.0, $83 = 0.0, $84 = 0.0, $85 = 0.0, $86 = 0.0, $87 = 0.0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $moveDownPosition$byval_copy11 = 0;
  10349. var $moveDownPosition2$byval_copy12 = 0, $or$cond = 0, $or$cond3 = 0, $or$cond5 = 0, $or$cond7 = 0, $or$cond9 = 0, label = 0, sp = 0;
  10350. sp = STACKTOP;
  10351. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  10352. $moveDownPosition2$byval_copy12 = sp + 8|0;
  10353. $moveDownPosition$byval_copy11 = sp;
  10354. $1 = ((($0)) + 4|0);
  10355. $2 = HEAP32[$1>>2]|0;
  10356. HEAP32[5334] = $2;
  10357. $3 = ($2|0)<(2);
  10358. $4 = HEAP32[$0>>2]|0;
  10359. $5 = ($4|0)==(1);
  10360. if (!($3)) {
  10361. if ($5) {
  10362. $88 = ((($0)) + 24|0);
  10363. $89 = $88;
  10364. $90 = $89;
  10365. $91 = HEAP32[$90>>2]|0;
  10366. $92 = (($89) + 4)|0;
  10367. $93 = $92;
  10368. $94 = HEAP32[$93>>2]|0;
  10369. $95 = 21040;
  10370. $96 = $95;
  10371. HEAP32[$96>>2] = $91;
  10372. $97 = (($95) + 4)|0;
  10373. $98 = $97;
  10374. HEAP32[$98>>2] = $94;
  10375. $99 = ((($0)) + 32|0);
  10376. $100 = $99;
  10377. $101 = $100;
  10378. $102 = HEAP32[$101>>2]|0;
  10379. $103 = (($100) + 4)|0;
  10380. $104 = $103;
  10381. $105 = HEAP32[$104>>2]|0;
  10382. $106 = 21080;
  10383. $107 = $106;
  10384. HEAP32[$107>>2] = $102;
  10385. $108 = (($106) + 4)|0;
  10386. $109 = $108;
  10387. HEAP32[$109>>2] = $105;
  10388. $110 = +HEAPF32[5270];
  10389. $111 = +HEAPF32[5260];
  10390. $112 = $110 - $111;
  10391. HEAPF32[5272] = $112;
  10392. $113 = +HEAPF32[(21084)>>2];
  10393. $114 = +HEAPF32[(21044)>>2];
  10394. $115 = $113 - $114;
  10395. HEAPF32[(21092)>>2] = $115;
  10396. HEAP32[5333] = 4;
  10397. STACKTOP = sp;return;
  10398. }
  10399. switch ($4|0) {
  10400. case 2: {
  10401. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21072>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21072+4>>2]|0;
  10402. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21096>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21096+4>>2]|0;
  10403. $116 = (+_Vector2Distance($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10404. HEAPF32[5339] = $116;
  10405. $117 = 21072;
  10406. $118 = $117;
  10407. $119 = HEAP32[$118>>2]|0;
  10408. $120 = (($117) + 4)|0;
  10409. $121 = $120;
  10410. $122 = HEAP32[$121>>2]|0;
  10411. $123 = 21040;
  10412. $124 = $123;
  10413. HEAP32[$124>>2] = $119;
  10414. $125 = (($123) + 4)|0;
  10415. $126 = $125;
  10416. HEAP32[$126>>2] = $122;
  10417. $127 = 21096;
  10418. $128 = $127;
  10419. $129 = HEAP32[$128>>2]|0;
  10420. $130 = (($127) + 4)|0;
  10421. $131 = $130;
  10422. $132 = HEAP32[$131>>2]|0;
  10423. $133 = 21080;
  10424. $134 = $133;
  10425. HEAP32[$134>>2] = $129;
  10426. $135 = (($133) + 4)|0;
  10427. $136 = $135;
  10428. HEAP32[$136>>2] = $132;
  10429. $137 = ((($0)) + 24|0);
  10430. $138 = $137;
  10431. $139 = $138;
  10432. $140 = HEAP32[$139>>2]|0;
  10433. $141 = (($138) + 4)|0;
  10434. $142 = $141;
  10435. $143 = HEAP32[$142>>2]|0;
  10436. $144 = 21072;
  10437. $145 = $144;
  10438. HEAP32[$145>>2] = $140;
  10439. $146 = (($144) + 4)|0;
  10440. $147 = $146;
  10441. HEAP32[$147>>2] = $143;
  10442. $148 = ((($0)) + 32|0);
  10443. $149 = $148;
  10444. $150 = $149;
  10445. $151 = HEAP32[$150>>2]|0;
  10446. $152 = (($149) + 4)|0;
  10447. $153 = $152;
  10448. $154 = HEAP32[$153>>2]|0;
  10449. $155 = 21096;
  10450. $156 = $155;
  10451. HEAP32[$156>>2] = $151;
  10452. $157 = (($155) + 4)|0;
  10453. $158 = $157;
  10454. HEAP32[$158>>2] = $154;
  10455. $159 = +HEAPF32[5274];
  10456. $160 = +HEAPF32[5268];
  10457. $161 = $159 - $160;
  10458. HEAPF32[5272] = $161;
  10459. $162 = +HEAPF32[(21100)>>2];
  10460. $163 = +HEAPF32[(21076)>>2];
  10461. $164 = $162 - $163;
  10462. HEAPF32[(21092)>>2] = $164;
  10463. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21040>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21040+4>>2]|0;
  10464. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21072>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21072+4>>2]|0;
  10465. $165 = (+_Vector2Distance($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10466. $166 = !($165 >= 0.004999999888241291);
  10467. if ($166) {
  10468. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21080>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21080+4>>2]|0;
  10469. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21096>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21096+4>>2]|0;
  10470. $167 = (+_Vector2Distance($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10471. $168 = !($167 >= 0.004999999888241291);
  10472. if ($168) {
  10473. $$sink16 = 4;
  10474. } else {
  10475. label = 29;
  10476. }
  10477. } else {
  10478. label = 29;
  10479. }
  10480. if ((label|0) == 29) {
  10481. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21072>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21072+4>>2]|0;
  10482. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21096>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21096+4>>2]|0;
  10483. $169 = (+_Vector2Distance($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10484. $170 = +HEAPF32[5339];
  10485. $171 = $169 - $170;
  10486. $172 = $171 < 0.0;
  10487. $$sink11 = $172 ? 256 : 512;
  10488. $$sink16 = $$sink11;
  10489. }
  10490. HEAP32[5333] = $$sink16;
  10491. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21072>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21072+4>>2]|0;
  10492. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21096>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21096+4>>2]|0;
  10493. $173 = (+_Vector2Angle($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10494. $174 = 360.0 - $173;
  10495. HEAPF32[5340] = $174;
  10496. STACKTOP = sp;return;
  10497. break;
  10498. }
  10499. case 0: {
  10500. HEAPF32[5339] = 0.0;
  10501. HEAPF32[5340] = 0.0;
  10502. HEAPF32[5272] = 0.0;
  10503. HEAPF32[(21092)>>2] = 0.0;
  10504. HEAP32[5334] = 0;
  10505. HEAP32[5333] = 0;
  10506. STACKTOP = sp;return;
  10507. break;
  10508. }
  10509. default: {
  10510. STACKTOP = sp;return;
  10511. }
  10512. }
  10513. }
  10514. if ($5) {
  10515. $6 = HEAP32[5335]|0;
  10516. $7 = (($6) + 1)|0;
  10517. HEAP32[5335] = $7;
  10518. $8 = HEAP32[5333]|0;
  10519. $9 = ($8|0)==(0);
  10520. $10 = ($6|0)>(0);
  10521. $or$cond = $10 & $9;
  10522. if ($or$cond) {
  10523. $11 = ((($0)) + 24|0);
  10524. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21040>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21040+4>>2]|0;
  10525. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[$11>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[$11+4>>2]|0;
  10526. $12 = (+_Vector2Distance($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10527. $13 = $12 < 0.029999999329447746;
  10528. if ($13) {
  10529. HEAP32[5333] = 2;
  10530. HEAP32[5335] = 0;
  10531. } else {
  10532. label = 6;
  10533. }
  10534. } else {
  10535. label = 6;
  10536. }
  10537. if ((label|0) == 6) {
  10538. HEAP32[5335] = 1;
  10539. HEAP32[5333] = 1;
  10540. }
  10541. $14 = ((($0)) + 24|0);
  10542. $15 = $14;
  10543. $16 = $15;
  10544. $17 = HEAP32[$16>>2]|0;
  10545. $18 = (($15) + 4)|0;
  10546. $19 = $18;
  10547. $20 = HEAP32[$19>>2]|0;
  10548. $21 = 21040;
  10549. $22 = $21;
  10550. HEAP32[$22>>2] = $17;
  10551. $23 = (($21) + 4)|0;
  10552. $24 = $23;
  10553. HEAP32[$24>>2] = $20;
  10554. $25 = 21048;
  10555. $26 = $25;
  10556. HEAP32[$26>>2] = $17;
  10557. $27 = (($25) + 4)|0;
  10558. $28 = $27;
  10559. HEAP32[$28>>2] = $20;
  10560. $29 = 21056;
  10561. $30 = $29;
  10562. HEAP32[$30>>2] = $17;
  10563. $31 = (($29) + 4)|0;
  10564. $32 = $31;
  10565. HEAP32[$32>>2] = $20;
  10566. $33 = ((($0)) + 8|0);
  10567. $34 = HEAP32[$33>>2]|0;
  10568. HEAP32[4] = $34;
  10569. HEAPF32[5266] = 0.0;
  10570. HEAPF32[(21068)>>2] = 0.0;
  10571. STACKTOP = sp;return;
  10572. }
  10573. switch ($4|0) {
  10574. case 0: {
  10575. $35 = HEAP32[5333]|0;
  10576. $36 = ($35|0)==(8);
  10577. if ($36) {
  10578. $37 = ((($0)) + 24|0);
  10579. $38 = $37;
  10580. $39 = $38;
  10581. $40 = HEAP32[$39>>2]|0;
  10582. $41 = (($38) + 4)|0;
  10583. $42 = $41;
  10584. $43 = HEAP32[$42>>2]|0;
  10585. $44 = 21056;
  10586. $45 = $44;
  10587. HEAP32[$45>>2] = $40;
  10588. $46 = (($44) + 4)|0;
  10589. $47 = $46;
  10590. HEAP32[$47>>2] = $43;
  10591. }
  10592. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21040>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21040+4>>2]|0;
  10593. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21056>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21056+4>>2]|0;
  10594. $48 = (+_Vector2Distance($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10595. $49 = $48 / 0.0;
  10596. HEAPF32[5336] = $49;
  10597. HEAP32[5337] = 0;
  10598. $50 = $49 > 5.0000002374872565E-4;
  10599. if ($50) {
  10600. $51 = HEAP32[4]|0;
  10601. $52 = ((($0)) + 8|0);
  10602. $53 = HEAP32[$52>>2]|0;
  10603. $54 = ($51|0)==($53|0);
  10604. if ($54) {
  10605. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21040>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21040+4>>2]|0;
  10606. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21056>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21056+4>>2]|0;
  10607. $55 = (+_Vector2Angle($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10608. $56 = 360.0 - $55;
  10609. HEAPF32[5338] = $56;
  10610. $57 = $56 < 30.0;
  10611. $58 = $56 > 330.0;
  10612. $or$cond3 = $57 | $58;
  10613. if ($or$cond3) {
  10614. $$sink10 = 16;
  10615. } else {
  10616. $59 = $56 > 30.0;
  10617. $60 = $56 < 120.0;
  10618. $or$cond5 = $59 & $60;
  10619. if ($or$cond5) {
  10620. $$sink10 = 64;
  10621. } else {
  10622. $61 = $56 > 120.0;
  10623. $62 = $56 < 210.0;
  10624. $or$cond7 = $61 & $62;
  10625. $63 = $56 > 210.0;
  10626. $64 = $56 < 300.0;
  10627. $or$cond9 = $63 & $64;
  10628. $$sink = $or$cond9 ? 128 : 0;
  10629. $$$sink = $or$cond7 ? 32 : $$sink;
  10630. $$sink10 = $$$sink;
  10631. }
  10632. }
  10633. } else {
  10634. label = 16;
  10635. }
  10636. } else {
  10637. label = 16;
  10638. }
  10639. if ((label|0) == 16) {
  10640. HEAPF32[5336] = 0.0;
  10641. HEAPF32[5338] = 0.0;
  10642. $$sink10 = 0;
  10643. }
  10644. HEAP32[5333] = $$sink10;
  10645. HEAPF32[5262] = 0.0;
  10646. HEAPF32[(21052)>>2] = 0.0;
  10647. HEAP32[5334] = 0;
  10648. STACKTOP = sp;return;
  10649. break;
  10650. }
  10651. case 2: {
  10652. $65 = HEAP32[5337]|0;
  10653. $66 = ($65|0)==(0);
  10654. if ($66) {
  10655. HEAP32[5337] = 1;
  10656. }
  10657. $67 = ((($0)) + 24|0);
  10658. $68 = $67;
  10659. $69 = $68;
  10660. $70 = HEAP32[$69>>2]|0;
  10661. $71 = (($68) + 4)|0;
  10662. $72 = $71;
  10663. $73 = HEAP32[$72>>2]|0;
  10664. $74 = 21072;
  10665. $75 = $74;
  10666. HEAP32[$75>>2] = $70;
  10667. $76 = (($74) + 4)|0;
  10668. $77 = $76;
  10669. HEAP32[$77>>2] = $73;
  10670. $78 = HEAP32[5333]|0;
  10671. $79 = ($78|0)==(4);
  10672. if ($79) {
  10673. ;HEAP32[$moveDownPosition$byval_copy11>>2]=HEAP32[21040>>2]|0;HEAP32[$moveDownPosition$byval_copy11+4>>2]=HEAP32[21040+4>>2]|0;
  10674. ;HEAP32[$moveDownPosition2$byval_copy12>>2]=HEAP32[21072>>2]|0;HEAP32[$moveDownPosition2$byval_copy12+4>>2]=HEAP32[21072+4>>2]|0;
  10675. $80 = (+_Vector2Distance($moveDownPosition$byval_copy11,$moveDownPosition2$byval_copy12));
  10676. $81 = !($80 >= 0.014999999664723873);
  10677. if (!($81)) {
  10678. HEAP32[5333] = 8;
  10679. }
  10680. }
  10681. $82 = +HEAPF32[5268];
  10682. $83 = +HEAPF32[5262];
  10683. $84 = $82 - $83;
  10684. HEAPF32[5266] = $84;
  10685. $85 = +HEAPF32[(21076)>>2];
  10686. $86 = +HEAPF32[(21052)>>2];
  10687. $87 = $85 - $86;
  10688. HEAPF32[(21068)>>2] = $87;
  10689. STACKTOP = sp;return;
  10690. break;
  10691. }
  10692. default: {
  10693. STACKTOP = sp;return;
  10694. }
  10695. }
  10696. }
  10697. function _UpdateGestures() {
  10698. var $$off = 0, $0 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $or$cond3 = 0, label = 0, sp = 0;
  10699. sp = STACKTOP;
  10700. $0 = HEAP32[5333]|0;
  10701. $$off = (($0) + -1)|0;
  10702. $1 = ($$off>>>0)<(2);
  10703. $2 = HEAP32[5334]|0;
  10704. $3 = ($2|0)<(2);
  10705. $or$cond3 = $1 & $3;
  10706. if ($or$cond3) {
  10707. HEAP32[5333] = 4;
  10708. }
  10709. $4 = HEAP32[5333]|0;
  10710. $5 = (($4) + -16)|0;
  10711. $6 = $5 >>> 4;
  10712. $7 = $5 << 28;
  10713. $8 = $6 | $7;
  10714. switch ($8|0) {
  10715. case 0: case 1: case 3: case 7: {
  10716. break;
  10717. }
  10718. default: {
  10719. return;
  10720. }
  10721. }
  10722. HEAP32[5333] = 0;
  10723. return;
  10724. }
  10725. function _GetMousePosition($0) {
  10726. $0 = $0|0;
  10727. var $1 = 0, $10 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  10728. sp = STACKTOP;
  10729. $1 = 21104;
  10730. $2 = $1;
  10731. $3 = HEAP32[$2>>2]|0;
  10732. $4 = (($1) + 4)|0;
  10733. $5 = $4;
  10734. $6 = HEAP32[$5>>2]|0;
  10735. $7 = $0;
  10736. $8 = $7;
  10737. HEAP32[$8>>2] = $3;
  10738. $9 = (($7) + 4)|0;
  10739. $10 = $9;
  10740. HEAP32[$10>>2] = $6;
  10741. return;
  10742. }
  10743. function _GetScreenWidth() {
  10744. var $0 = 0, label = 0, sp = 0;
  10745. sp = STACKTOP;
  10746. $0 = HEAP32[5343]|0;
  10747. return ($0|0);
  10748. }
  10749. function _GetScreenHeight() {
  10750. var $0 = 0, label = 0, sp = 0;
  10751. sp = STACKTOP;
  10752. $0 = HEAP32[5342]|0;
  10753. return ($0|0);
  10754. }
  10755. function _InitWindow($0,$1,$2) {
  10756. $0 = $0|0;
  10757. $1 = $1|0;
  10758. $2 = $2|0;
  10759. var $10 = 0, $3 = 0, $4 = 0.0, $5 = 0.0, $6 = 0, $7 = 0.0, $8 = 0.0, $9 = 0, $vararg_buffer = 0, label = 0, sp = 0;
  10760. sp = STACKTOP;
  10761. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  10762. $vararg_buffer = sp;
  10763. _TraceLog(0,5708,$vararg_buffer);
  10764. HEAP32[5345] = $2;
  10765. _InitGraphicsDevice($0,$1);
  10766. _LoadDefaultFont();
  10767. _InitTimer();
  10768. (_emscripten_set_fullscreenchange_callback((0|0),(0|0),1,(4|0))|0);
  10769. (_emscripten_set_keypress_callback((5737|0),(0|0),1,(5|0))|0);
  10770. (_emscripten_set_click_callback((5737|0),(0|0),1,(6|0))|0);
  10771. (_emscripten_set_touchstart_callback((5737|0),(0|0),1,(7|0))|0);
  10772. (_emscripten_set_touchend_callback((5737|0),(0|0),1,(7|0))|0);
  10773. (_emscripten_set_touchmove_callback((5737|0),(0|0),1,(7|0))|0);
  10774. (_emscripten_set_touchcancel_callback((5737|0),(0|0),1,(7|0))|0);
  10775. (_emscripten_set_gamepadconnected_callback((0|0),1,(8|0))|0);
  10776. (_emscripten_set_gamepaddisconnected_callback((0|0),1,(8|0))|0);
  10777. $3 = HEAP32[5343]|0;
  10778. $4 = (+($3|0));
  10779. $5 = $4 * 0.5;
  10780. HEAPF32[5276] = $5;
  10781. $6 = HEAP32[5342]|0;
  10782. $7 = (+($6|0));
  10783. $8 = $7 * 0.5;
  10784. HEAPF32[(21108)>>2] = $8;
  10785. $9 = HEAP32[5346]|0;
  10786. $10 = ($9|0)==(0);
  10787. if ($10) {
  10788. STACKTOP = sp;return;
  10789. }
  10790. _SetTargetFPS(60);
  10791. _LogoAnimation();
  10792. STACKTOP = sp;return;
  10793. }
  10794. function _TraceLog($0,$1,$varargs) {
  10795. $0 = $0|0;
  10796. $1 = $1|0;
  10797. $varargs = $varargs|0;
  10798. var $10 = 0, $11 = 0, $12 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $endptr = 0, $strlen = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  10799. sp = STACKTOP;
  10800. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  10801. $2 = sp;
  10802. switch ($0|0) {
  10803. case 0: {
  10804. ;HEAP8[21144>>0]=HEAP8[10266>>0]|0;HEAP8[21144+1>>0]=HEAP8[10266+1>>0]|0;HEAP8[21144+2>>0]=HEAP8[10266+2>>0]|0;HEAP8[21144+3>>0]=HEAP8[10266+3>>0]|0;HEAP8[21144+4>>0]=HEAP8[10266+4>>0]|0;HEAP8[21144+5>>0]=HEAP8[10266+5>>0]|0;HEAP8[21144+6>>0]=HEAP8[10266+6>>0]|0;
  10805. break;
  10806. }
  10807. case 1: {
  10808. $3 = 21144;
  10809. $4 = $3;
  10810. HEAP32[$4>>2] = 1330795077;
  10811. $5 = (($3) + 4)|0;
  10812. $6 = $5;
  10813. HEAP32[$6>>2] = 2112082;
  10814. break;
  10815. }
  10816. case 2: {
  10817. dest=21144; src=10273; stop=dest+10|0; do { HEAP8[dest>>0]=HEAP8[src>>0]|0; dest=dest+1|0; src=src+1|0; } while ((dest|0) < (stop|0));
  10818. break;
  10819. }
  10820. case 3: {
  10821. $7 = 21144;
  10822. $8 = $7;
  10823. HEAP32[$8>>2] = 1430406468;
  10824. $9 = (($7) + 4)|0;
  10825. $10 = $9;
  10826. HEAP32[$10>>2] = 2112071;
  10827. break;
  10828. }
  10829. default: {
  10830. }
  10831. }
  10832. (_strcat(21144,$1)|0);
  10833. $strlen = (_strlen(21144)|0);
  10834. $endptr = (21144 + ($strlen)|0);
  10835. HEAP8[$endptr>>0]=10&255;HEAP8[$endptr+1>>0]=10>>8;
  10836. HEAP32[$2>>2] = $varargs;
  10837. $11 = ($0|0)==(3);
  10838. if ($11) {
  10839. STACKTOP = sp;return;
  10840. }
  10841. (_vprintf(21144,$2)|0);
  10842. $12 = ($0|0)==(1);
  10843. if ($12) {
  10844. _exit(1);
  10845. // unreachable;
  10846. } else {
  10847. STACKTOP = sp;return;
  10848. }
  10849. }
  10850. function _InitGraphicsDevice($0,$1) {
  10851. $0 = $0|0;
  10852. $1 = $1|0;
  10853. var $$015 = 0, $$byval_copy = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  10854. var $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  10855. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0;
  10856. var $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0.0, $79 = 0, $8 = 0, $80 = 0;
  10857. var $81 = 0, $82 = 0.0, $83 = 0, $84 = 0, $85 = 0, $9 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer10 = 0, $vararg_buffer14 = 0, $vararg_buffer18 = 0, $vararg_buffer22 = 0, $vararg_buffer3 = 0, $vararg_buffer6 = 0, $vararg_buffer8 = 0, $vararg_ptr13 = 0, $vararg_ptr17 = 0, $vararg_ptr21 = 0, $vararg_ptr5 = 0, dest = 0;
  10858. var label = 0, sp = 0, src = 0, stop = 0;
  10859. sp = STACKTOP;
  10860. STACKTOP = STACKTOP + 144|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(144|0);
  10861. $$byval_copy = sp + 136|0;
  10862. $vararg_buffer22 = sp + 64|0;
  10863. $vararg_buffer18 = sp + 56|0;
  10864. $vararg_buffer14 = sp + 48|0;
  10865. $vararg_buffer10 = sp + 40|0;
  10866. $vararg_buffer8 = sp + 32|0;
  10867. $vararg_buffer6 = sp + 24|0;
  10868. $vararg_buffer3 = sp + 16|0;
  10869. $vararg_buffer1 = sp + 8|0;
  10870. $vararg_buffer = sp;
  10871. $2 = sp + 72|0;
  10872. $3 = sp + 140|0;
  10873. HEAP32[5343] = $0;
  10874. HEAP32[5342] = $1;
  10875. _MatrixIdentity($2);
  10876. dest=21460; src=$2; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  10877. (_glfwSetErrorCallback((2|0))|0);
  10878. $4 = (_glfwInit()|0);
  10879. $5 = ($4|0)==(0);
  10880. if ($5) {
  10881. _TraceLog(1,6408,$vararg_buffer);
  10882. }
  10883. $6 = HEAP32[5343]|0;
  10884. HEAP32[5381] = $6;
  10885. $7 = HEAP32[5342]|0;
  10886. HEAP32[5382] = $7;
  10887. _glfwDefaultWindowHints();
  10888. $8 = HEAP8[24192]|0;
  10889. $9 = $8 & 4;
  10890. $10 = ($9<<24>>24)==(0);
  10891. if ($10) {
  10892. _glfwWindowHint(131075,0);
  10893. } else {
  10894. _glfwWindowHint(131075,1);
  10895. }
  10896. $11 = HEAP8[24192]|0;
  10897. $12 = $11 & 8;
  10898. $13 = ($12<<24>>24)==(0);
  10899. if (!($13)) {
  10900. _glfwWindowHint(131077,1);
  10901. }
  10902. $14 = HEAP8[24192]|0;
  10903. $15 = $14 & 32;
  10904. $16 = ($15<<24>>24)==(0);
  10905. if (!($16)) {
  10906. _glfwWindowHint(135181,4);
  10907. _TraceLog(0,6434,$vararg_buffer1);
  10908. }
  10909. $17 = (_rlGetVersion()|0);
  10910. $18 = ($17|0)==(2);
  10911. if ($18) {
  10912. _glfwWindowHint(139266,2);
  10913. _glfwWindowHint(139267,1);
  10914. } else {
  10915. $19 = (_rlGetVersion()|0);
  10916. $20 = ($19|0)==(3);
  10917. if ($20) {
  10918. _glfwWindowHint(139266,3);
  10919. _glfwWindowHint(139267,3);
  10920. _glfwWindowHint(139272,204801);
  10921. _glfwWindowHint(139270,0);
  10922. }
  10923. }
  10924. $21 = HEAP32[5383]|0;
  10925. $22 = ($21|0)==(0);
  10926. if ($22) {
  10927. $47 = HEAP32[5343]|0;
  10928. $48 = HEAP32[5342]|0;
  10929. $49 = HEAP32[5345]|0;
  10930. $50 = (_glfwCreateWindow(($47|0),($48|0),($49|0),(0|0),(0|0))|0);
  10931. HEAP32[5341] = $50;
  10932. $51 = HEAP32[5343]|0;
  10933. HEAP32[5384] = $51;
  10934. $52 = HEAP32[5342]|0;
  10935. HEAP32[5385] = $52;
  10936. $54 = $50;
  10937. } else {
  10938. $23 = (_glfwGetPrimaryMonitor()|0);
  10939. $24 = (_glfwGetVideoModes(($23|0),($$byval_copy|0))|0);
  10940. $25 = HEAP32[$$byval_copy>>2]|0;
  10941. $26 = ($25|0)>(0);
  10942. L22: do {
  10943. if ($26) {
  10944. $27 = HEAP32[5343]|0;
  10945. $28 = HEAP32[$$byval_copy>>2]|0;
  10946. $29 = HEAP32[5342]|0;
  10947. $$015 = 0;
  10948. while(1) {
  10949. $30 = (($24) + (($$015*24)|0)|0);
  10950. $31 = HEAP32[$30>>2]|0;
  10951. $32 = ($31|0)<($27|0);
  10952. if (!($32)) {
  10953. $33 = (((($24) + (($$015*24)|0)|0)) + 4|0);
  10954. $34 = HEAP32[$33>>2]|0;
  10955. $35 = ($34|0)<($29|0);
  10956. if (!($35)) {
  10957. break;
  10958. }
  10959. }
  10960. $36 = (($$015) + 1)|0;
  10961. $37 = ($36|0)<($28|0);
  10962. if ($37) {
  10963. $$015 = $36;
  10964. } else {
  10965. break L22;
  10966. }
  10967. }
  10968. HEAP32[5381] = $31;
  10969. HEAP32[5382] = $34;
  10970. }
  10971. } while(0);
  10972. $38 = HEAP32[5381]|0;
  10973. $39 = HEAP32[5382]|0;
  10974. HEAP32[$vararg_buffer3>>2] = $38;
  10975. $vararg_ptr5 = ((($vararg_buffer3)) + 4|0);
  10976. HEAP32[$vararg_ptr5>>2] = $39;
  10977. _TraceLog(2,6459,$vararg_buffer3);
  10978. $40 = HEAP32[5381]|0;
  10979. $41 = HEAP32[5382]|0;
  10980. _SetupFramebufferSize($40,$41);
  10981. $42 = HEAP32[5381]|0;
  10982. $43 = HEAP32[5382]|0;
  10983. $44 = HEAP32[5345]|0;
  10984. $45 = (_glfwGetPrimaryMonitor()|0);
  10985. $46 = (_glfwCreateWindow(($42|0),($43|0),($44|0),($45|0),(0|0))|0);
  10986. HEAP32[5341] = $46;
  10987. $54 = $46;
  10988. }
  10989. $53 = ($54|0)==(0|0);
  10990. if ($53) {
  10991. _glfwTerminate();
  10992. _TraceLog(1,6497,$vararg_buffer6);
  10993. } else {
  10994. _TraceLog(0,6530,$vararg_buffer8);
  10995. $55 = HEAP32[5384]|0;
  10996. $56 = HEAP32[5385]|0;
  10997. HEAP32[$vararg_buffer10>>2] = $55;
  10998. $vararg_ptr13 = ((($vararg_buffer10)) + 4|0);
  10999. HEAP32[$vararg_ptr13>>2] = $56;
  11000. _TraceLog(0,6570,$vararg_buffer10);
  11001. $57 = HEAP32[5343]|0;
  11002. $58 = HEAP32[5342]|0;
  11003. HEAP32[$vararg_buffer14>>2] = $57;
  11004. $vararg_ptr17 = ((($vararg_buffer14)) + 4|0);
  11005. HEAP32[$vararg_ptr17>>2] = $58;
  11006. _TraceLog(0,6591,$vararg_buffer14);
  11007. $59 = HEAP32[5386]|0;
  11008. $60 = HEAP32[5387]|0;
  11009. HEAP32[$vararg_buffer18>>2] = $59;
  11010. $vararg_ptr21 = ((($vararg_buffer18)) + 4|0);
  11011. HEAP32[$vararg_ptr21>>2] = $60;
  11012. _TraceLog(0,6612,$vararg_buffer18);
  11013. }
  11014. $61 = HEAP32[5341]|0;
  11015. (_glfwSetWindowSizeCallback(($61|0),(1|0))|0);
  11016. $62 = HEAP32[5341]|0;
  11017. (_glfwSetCursorEnterCallback(($62|0),(3|0))|0);
  11018. $63 = HEAP32[5341]|0;
  11019. (_glfwSetKeyCallback(($63|0),(1|0))|0);
  11020. $64 = HEAP32[5341]|0;
  11021. (_glfwSetMouseButtonCallback(($64|0),(1|0))|0);
  11022. $65 = HEAP32[5341]|0;
  11023. (_glfwSetCursorPosCallback(($65|0),(1|0))|0);
  11024. $66 = HEAP32[5341]|0;
  11025. (_glfwSetCharCallback(($66|0),(4|0))|0);
  11026. $67 = HEAP32[5341]|0;
  11027. (_glfwSetScrollCallback(($67|0),(2|0))|0);
  11028. $68 = HEAP32[5341]|0;
  11029. (_glfwSetWindowIconifyCallback(($68|0),(5|0))|0);
  11030. $69 = HEAP32[5341]|0;
  11031. _glfwMakeContextCurrent(($69|0));
  11032. _glfwSwapInterval(0);
  11033. $70 = HEAP8[24192]|0;
  11034. $71 = $70 & 64;
  11035. $72 = ($71<<24>>24)==(0);
  11036. if ($72) {
  11037. $73 = HEAP32[5343]|0;
  11038. $74 = HEAP32[5342]|0;
  11039. _rlglInit($73,$74);
  11040. _SetupViewport();
  11041. _rlMatrixMode(5889);
  11042. _rlLoadIdentity();
  11043. $75 = HEAP32[5384]|0;
  11044. $76 = HEAP32[5386]|0;
  11045. $77 = (($75) - ($76))|0;
  11046. $78 = (+($77|0));
  11047. $79 = HEAP32[5385]|0;
  11048. $80 = HEAP32[5387]|0;
  11049. $81 = (($79) - ($80))|0;
  11050. $82 = (+($81|0));
  11051. _rlOrtho(0.0,$78,$82,0.0,0.0,1.0);
  11052. _rlMatrixMode(5888);
  11053. _rlLoadIdentity();
  11054. HEAP8[$3>>0] = -11;
  11055. $83 = ((($3)) + 1|0);
  11056. HEAP8[$83>>0] = -11;
  11057. $84 = ((($3)) + 2|0);
  11058. HEAP8[$84>>0] = -11;
  11059. $85 = ((($3)) + 3|0);
  11060. HEAP8[$85>>0] = -1;
  11061. ;HEAP8[$$byval_copy>>0]=HEAP8[$3>>0]|0;HEAP8[$$byval_copy+1>>0]=HEAP8[$3+1>>0]|0;HEAP8[$$byval_copy+2>>0]=HEAP8[$3+2>>0]|0;HEAP8[$$byval_copy+3>>0]=HEAP8[$3+3>>0]|0;
  11062. _ClearBackground($$byval_copy);
  11063. STACKTOP = sp;return;
  11064. }
  11065. _glfwSwapInterval(1);
  11066. _TraceLog(0,6637,$vararg_buffer22);
  11067. $73 = HEAP32[5343]|0;
  11068. $74 = HEAP32[5342]|0;
  11069. _rlglInit($73,$74);
  11070. _SetupViewport();
  11071. _rlMatrixMode(5889);
  11072. _rlLoadIdentity();
  11073. $75 = HEAP32[5384]|0;
  11074. $76 = HEAP32[5386]|0;
  11075. $77 = (($75) - ($76))|0;
  11076. $78 = (+($77|0));
  11077. $79 = HEAP32[5385]|0;
  11078. $80 = HEAP32[5387]|0;
  11079. $81 = (($79) - ($80))|0;
  11080. $82 = (+($81|0));
  11081. _rlOrtho(0.0,$78,$82,0.0,0.0,1.0);
  11082. _rlMatrixMode(5888);
  11083. _rlLoadIdentity();
  11084. HEAP8[$3>>0] = -11;
  11085. $83 = ((($3)) + 1|0);
  11086. HEAP8[$83>>0] = -11;
  11087. $84 = ((($3)) + 2|0);
  11088. HEAP8[$84>>0] = -11;
  11089. $85 = ((($3)) + 3|0);
  11090. HEAP8[$85>>0] = -1;
  11091. ;HEAP8[$$byval_copy>>0]=HEAP8[$3>>0]|0;HEAP8[$$byval_copy+1>>0]=HEAP8[$3+1>>0]|0;HEAP8[$$byval_copy+2>>0]=HEAP8[$3+2>>0]|0;HEAP8[$$byval_copy+3>>0]=HEAP8[$3+3>>0]|0;
  11092. _ClearBackground($$byval_copy);
  11093. STACKTOP = sp;return;
  11094. }
  11095. function _LoadDefaultFont() {
  11096. var $$ = 0, $$0101 = 0, $$090100 = 0, $$09299 = 0, $$095104 = 0, $$096103 = 0, $$097102 = 0, $$191 = 0, $$193 = 0, $$byval_copy1 = 0, $$lcssa = 0, $$sroa$0$0$$sroa_idx = 0, $0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0;
  11097. var $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0;
  11098. var $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  11099. var $vararg_buffer = 0, label = 0, sp = 0;
  11100. sp = STACKTOP;
  11101. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  11102. $$byval_copy1 = sp + 44|0;
  11103. $vararg_buffer = sp;
  11104. $0 = sp + 4|0;
  11105. $1 = sp + 24|0;
  11106. HEAP32[(21428)>>2] = 224;
  11107. $2 = (_malloc(65536)|0);
  11108. _memset(($2|0),0,65536)|0;
  11109. $$095104 = 0;$$096103 = 0;
  11110. while(1) {
  11111. $3 = (20 + ($$095104<<2)|0);
  11112. $4 = HEAP32[$3>>2]|0;
  11113. $$097102 = 31;
  11114. while(1) {
  11115. $16 = 1 << $$097102;
  11116. $17 = $4 & $16;
  11117. $18 = ($17|0)==(0);
  11118. if (!($18)) {
  11119. $19 = (($$097102) + ($$096103))|0;
  11120. $$sroa$0$0$$sroa_idx = (($2) + ($19<<2)|0);
  11121. HEAP8[$$sroa$0$0$$sroa_idx>>0]=-1&255;HEAP8[$$sroa$0$0$$sroa_idx+1>>0]=(-1>>8)&255;HEAP8[$$sroa$0$0$$sroa_idx+2>>0]=(-1>>16)&255;HEAP8[$$sroa$0$0$$sroa_idx+3>>0]=-1>>24;
  11122. }
  11123. $20 = (($$097102) + -1)|0;
  11124. $21 = ($$097102|0)>(0);
  11125. if ($21) {
  11126. $$097102 = $20;
  11127. } else {
  11128. break;
  11129. }
  11130. }
  11131. $12 = (($$095104) + 1)|0;
  11132. $13 = ($$095104|0)>(511);
  11133. $$ = $13 ? 0 : $12;
  11134. $14 = (($$096103) + 32)|0;
  11135. $15 = ($14|0)<(16384);
  11136. if ($15) {
  11137. $$095104 = $$;$$096103 = $14;
  11138. } else {
  11139. break;
  11140. }
  11141. }
  11142. _LoadImageEx($0,$2,128,128);
  11143. _ImageFormat($0,2);
  11144. _free($2);
  11145. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  11146. _LoadTextureFromImage($1,$$byval_copy1);
  11147. ;HEAP32[21404>>2]=HEAP32[$1>>2]|0;HEAP32[21404+4>>2]=HEAP32[$1+4>>2]|0;HEAP32[21404+8>>2]=HEAP32[$1+8>>2]|0;HEAP32[21404+12>>2]=HEAP32[$1+12>>2]|0;HEAP32[21404+16>>2]=HEAP32[$1+16>>2]|0;
  11148. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  11149. _UnloadImage($$byval_copy1);
  11150. $5 = HEAP32[(21428)>>2]|0;
  11151. $6 = $5 << 5;
  11152. $7 = (_malloc($6)|0);
  11153. HEAP32[(21432)>>2] = $7;
  11154. $8 = ($5|0)>(0);
  11155. if (!($8)) {
  11156. $$lcssa = $7;
  11157. $22 = ((($$lcssa)) + 16|0);
  11158. $23 = HEAP32[$22>>2]|0;
  11159. HEAP32[(21424)>>2] = $23;
  11160. $24 = HEAP32[5351]|0;
  11161. HEAP32[$vararg_buffer>>2] = $24;
  11162. _TraceLog(0,5932,$vararg_buffer);
  11163. STACKTOP = sp;return;
  11164. }
  11165. $9 = HEAP32[(21408)>>2]|0;
  11166. $10 = HEAP32[(21428)>>2]|0;
  11167. $11 = HEAP32[(21432)>>2]|0;
  11168. $$0101 = 0;$$090100 = 1;$$09299 = 0;$27 = $7;
  11169. while(1) {
  11170. $25 = (($$0101) + 32)|0;
  11171. $26 = (($27) + ($$0101<<5)|0);
  11172. HEAP32[$26>>2] = $25;
  11173. $28 = (((($27) + ($$0101<<5)|0)) + 4|0);
  11174. HEAP32[$28>>2] = $$090100;
  11175. $29 = ($$09299*11)|0;
  11176. $30 = (($29) + 1)|0;
  11177. $31 = (((($27) + ($$0101<<5)|0)) + 8|0);
  11178. HEAP32[$31>>2] = $30;
  11179. $32 = (2068 + ($$0101<<2)|0);
  11180. $33 = HEAP32[$32>>2]|0;
  11181. $34 = (((($27) + ($$0101<<5)|0)) + 12|0);
  11182. HEAP32[$34>>2] = $33;
  11183. $35 = (((($27) + ($$0101<<5)|0)) + 16|0);
  11184. HEAP32[$35>>2] = 10;
  11185. $36 = (($$090100) + 1)|0;
  11186. $37 = (($36) + ($33))|0;
  11187. $38 = ($37|0)<($9|0);
  11188. $39 = (($$09299) + 1)|0;
  11189. if ($38) {
  11190. $$191 = $37;$$193 = $$09299;
  11191. } else {
  11192. $40 = ($39*11)|0;
  11193. $41 = (($40) + 1)|0;
  11194. $42 = (($33) + 2)|0;
  11195. HEAP32[$28>>2] = 1;
  11196. HEAP32[$31>>2] = $41;
  11197. $$191 = $42;$$193 = $39;
  11198. }
  11199. $43 = (((($27) + ($$0101<<5)|0)) + 20|0);
  11200. HEAP32[$43>>2] = 0;
  11201. $44 = (((($27) + ($$0101<<5)|0)) + 24|0);
  11202. HEAP32[$44>>2] = 0;
  11203. $45 = (((($27) + ($$0101<<5)|0)) + 28|0);
  11204. HEAP32[$45>>2] = 0;
  11205. $46 = (($$0101) + 1)|0;
  11206. $47 = ($46|0)<($10|0);
  11207. if ($47) {
  11208. $$0101 = $46;$$090100 = $$191;$$09299 = $$193;$27 = $11;
  11209. } else {
  11210. $$lcssa = $11;
  11211. break;
  11212. }
  11213. }
  11214. $22 = ((($$lcssa)) + 16|0);
  11215. $23 = HEAP32[$22>>2]|0;
  11216. HEAP32[(21424)>>2] = $23;
  11217. $24 = HEAP32[5351]|0;
  11218. HEAP32[$vararg_buffer>>2] = $24;
  11219. _TraceLog(0,5932,$vararg_buffer);
  11220. STACKTOP = sp;return;
  11221. }
  11222. function _InitTimer() {
  11223. var $0 = 0, $1 = 0.0, label = 0, sp = 0;
  11224. sp = STACKTOP;
  11225. $0 = (_time((0|0))|0);
  11226. _srand($0);
  11227. $1 = (+_GetTime());
  11228. HEAPF64[2642] = $1;
  11229. return;
  11230. }
  11231. function _EmscriptenFullscreenChangeCallback($0,$1,$2) {
  11232. $0 = $0|0;
  11233. $1 = $1|0;
  11234. $2 = $2|0;
  11235. var $10 = 0, $11 = 0, $12 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, $vararg_buffer4 = 0, $vararg_ptr1 = 0, $vararg_ptr2 = 0, $vararg_ptr3 = 0, $vararg_ptr7 = 0, $vararg_ptr8 = 0, $vararg_ptr9 = 0, label = 0, sp = 0;
  11236. sp = STACKTOP;
  11237. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  11238. $vararg_buffer4 = sp + 16|0;
  11239. $vararg_buffer = sp;
  11240. $3 = HEAP32[$1>>2]|0;
  11241. $4 = ($3|0)==(0);
  11242. $5 = ((($1)) + 264|0);
  11243. $6 = HEAP32[$5>>2]|0;
  11244. $7 = ((($1)) + 268|0);
  11245. $8 = HEAP32[$7>>2]|0;
  11246. $9 = ((($1)) + 272|0);
  11247. $10 = HEAP32[$9>>2]|0;
  11248. $11 = ((($1)) + 276|0);
  11249. $12 = HEAP32[$11>>2]|0;
  11250. if ($4) {
  11251. HEAP32[$vararg_buffer4>>2] = $6;
  11252. $vararg_ptr7 = ((($vararg_buffer4)) + 4|0);
  11253. HEAP32[$vararg_ptr7>>2] = $8;
  11254. $vararg_ptr8 = ((($vararg_buffer4)) + 8|0);
  11255. HEAP32[$vararg_ptr8>>2] = $10;
  11256. $vararg_ptr9 = ((($vararg_buffer4)) + 12|0);
  11257. HEAP32[$vararg_ptr9>>2] = $12;
  11258. _TraceLog(0,5865,$vararg_buffer4);
  11259. STACKTOP = sp;return 0;
  11260. } else {
  11261. HEAP32[$vararg_buffer>>2] = $6;
  11262. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  11263. HEAP32[$vararg_ptr1>>2] = $8;
  11264. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  11265. HEAP32[$vararg_ptr2>>2] = $10;
  11266. $vararg_ptr3 = ((($vararg_buffer)) + 12|0);
  11267. HEAP32[$vararg_ptr3>>2] = $12;
  11268. _TraceLog(0,5796,$vararg_buffer);
  11269. STACKTOP = sp;return 0;
  11270. }
  11271. return (0)|0;
  11272. }
  11273. function _EmscriptenKeyboardCallback($0,$1,$2) {
  11274. $0 = $0|0;
  11275. $1 = $1|0;
  11276. $2 = $2|0;
  11277. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  11278. sp = STACKTOP;
  11279. $3 = ($0|0)==(1);
  11280. if (!($3)) {
  11281. return 0;
  11282. }
  11283. $4 = ((($1)) + 32|0);
  11284. $5 = (_strcmp($4,5789)|0);
  11285. $6 = ($5|0)==(0);
  11286. if (!($6)) {
  11287. return 0;
  11288. }
  11289. (_emscripten_exit_pointerlock()|0);
  11290. return 0;
  11291. }
  11292. function _EmscriptenMouseCallback($0,$1,$2) {
  11293. $0 = $0|0;
  11294. $1 = $1|0;
  11295. $2 = $2|0;
  11296. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  11297. sp = STACKTOP;
  11298. STACKTOP = STACKTOP + 272|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(272|0);
  11299. $3 = sp;
  11300. $4 = ($0|0)==(4);
  11301. if (!($4)) {
  11302. STACKTOP = sp;return 0;
  11303. }
  11304. (_emscripten_get_pointerlock_status(($3|0))|0);
  11305. $5 = HEAP32[$3>>2]|0;
  11306. $6 = ($5|0)==(0);
  11307. if ($6) {
  11308. (_emscripten_request_pointerlock((0|0),1)|0);
  11309. } else {
  11310. (_emscripten_exit_pointerlock()|0);
  11311. (_emscripten_get_pointerlock_status(($3|0))|0);
  11312. }
  11313. STACKTOP = sp;return 0;
  11314. }
  11315. function _EmscriptenTouchCallback($0,$1,$2) {
  11316. $0 = $0|0;
  11317. $1 = $1|0;
  11318. $2 = $2|0;
  11319. var $$byval_copy = 0, $$sink = 0, $$sroa$0$0$$sroa_idx = 0, $$sroa$03$0$$sroa_idx = 0, $$sroa$2$0$$sroa_idx2 = 0, $$sroa$24$0$$sroa_idx5 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0.0, $15 = 0, $16 = 0, $17 = 0.0, $18 = 0, $19 = 0, $20 = 0.0, $21 = 0, $22 = 0, $23 = 0.0;
  11320. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  11321. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0.0, $48 = 0.0, $49 = 0.0, $5 = 0, $50 = 0, $51 = 0.0, $52 = 0.0, $53 = 0.0, $54 = 0, $55 = 0.0, $56 = 0.0, $57 = 0.0, $58 = 0, $59 = 0.0, $6 = 0;
  11322. var $60 = 0.0, $61 = 0.0, $7 = 0, $8 = 0, $9 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  11323. sp = STACKTOP;
  11324. STACKTOP = STACKTOP + 112|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(112|0);
  11325. $$byval_copy = sp + 56|0;
  11326. $3 = sp;
  11327. switch ($0|0) {
  11328. case 22: {
  11329. $$sink = 1;
  11330. label = 4;
  11331. break;
  11332. }
  11333. case 23: {
  11334. $$sink = 0;
  11335. label = 4;
  11336. break;
  11337. }
  11338. case 24: {
  11339. $$sink = 2;
  11340. label = 4;
  11341. break;
  11342. }
  11343. default: {
  11344. }
  11345. }
  11346. if ((label|0) == 4) {
  11347. HEAP32[$3>>2] = $$sink;
  11348. }
  11349. $4 = HEAP32[$1>>2]|0;
  11350. $5 = ((($3)) + 4|0);
  11351. HEAP32[$5>>2] = $4;
  11352. $6 = ((($1)) + 20|0);
  11353. $7 = HEAP32[$6>>2]|0;
  11354. $8 = ((($3)) + 8|0);
  11355. HEAP32[$8>>2] = $7;
  11356. $9 = ((($1)) + 72|0);
  11357. $10 = HEAP32[$9>>2]|0;
  11358. $11 = ((($3)) + 12|0);
  11359. HEAP32[$11>>2] = $10;
  11360. $12 = ((($1)) + 56|0);
  11361. $13 = HEAP32[$12>>2]|0;
  11362. $14 = (+($13|0));
  11363. $15 = ((($1)) + 60|0);
  11364. $16 = HEAP32[$15>>2]|0;
  11365. $17 = (+($16|0));
  11366. $$sroa$03$0$$sroa_idx = ((($3)) + 24|0);
  11367. HEAPF32[$$sroa$03$0$$sroa_idx>>2] = $14;
  11368. $$sroa$24$0$$sroa_idx5 = ((($3)) + 28|0);
  11369. HEAPF32[$$sroa$24$0$$sroa_idx5>>2] = $17;
  11370. $18 = ((($1)) + 108|0);
  11371. $19 = HEAP32[$18>>2]|0;
  11372. $20 = (+($19|0));
  11373. $21 = ((($1)) + 112|0);
  11374. $22 = HEAP32[$21>>2]|0;
  11375. $23 = (+($22|0));
  11376. $$sroa$0$0$$sroa_idx = ((($3)) + 32|0);
  11377. HEAPF32[$$sroa$0$0$$sroa_idx>>2] = $20;
  11378. $$sroa$2$0$$sroa_idx2 = ((($3)) + 36|0);
  11379. HEAPF32[$$sroa$2$0$$sroa_idx2>>2] = $23;
  11380. $24 = ((($3)) + 24|0);
  11381. $25 = $24;
  11382. $26 = $25;
  11383. $27 = HEAP32[$26>>2]|0;
  11384. $28 = (($25) + 4)|0;
  11385. $29 = $28;
  11386. $30 = HEAP32[$29>>2]|0;
  11387. $31 = 21120;
  11388. $32 = $31;
  11389. HEAP32[$32>>2] = $27;
  11390. $33 = (($31) + 4)|0;
  11391. $34 = $33;
  11392. HEAP32[$34>>2] = $30;
  11393. $35 = ((($3)) + 32|0);
  11394. $36 = $35;
  11395. $37 = $36;
  11396. $38 = HEAP32[$37>>2]|0;
  11397. $39 = (($36) + 4)|0;
  11398. $40 = $39;
  11399. $41 = HEAP32[$40>>2]|0;
  11400. $42 = (21128);
  11401. $43 = $42;
  11402. HEAP32[$43>>2] = $38;
  11403. $44 = (($42) + 4)|0;
  11404. $45 = $44;
  11405. HEAP32[$45>>2] = $41;
  11406. $46 = (_GetScreenWidth()|0);
  11407. $47 = (+($46|0));
  11408. $48 = +HEAPF32[$24>>2];
  11409. $49 = $48 / $47;
  11410. HEAPF32[$24>>2] = $49;
  11411. $50 = (_GetScreenHeight()|0);
  11412. $51 = (+($50|0));
  11413. $52 = +HEAPF32[$$sroa$24$0$$sroa_idx5>>2];
  11414. $53 = $52 / $51;
  11415. HEAPF32[$$sroa$24$0$$sroa_idx5>>2] = $53;
  11416. $54 = (_GetScreenWidth()|0);
  11417. $55 = (+($54|0));
  11418. $56 = +HEAPF32[$35>>2];
  11419. $57 = $56 / $55;
  11420. HEAPF32[$35>>2] = $57;
  11421. $58 = (_GetScreenHeight()|0);
  11422. $59 = (+($58|0));
  11423. $60 = +HEAPF32[$$sroa$2$0$$sroa_idx2>>2];
  11424. $61 = $60 / $59;
  11425. HEAPF32[$$sroa$2$0$$sroa_idx2>>2] = $61;
  11426. dest=$$byval_copy; src=$3; stop=dest+56|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  11427. _ProcessGestureEvent($$byval_copy);
  11428. STACKTOP = sp;return 1;
  11429. }
  11430. function _EmscriptenGamepadCallback($0,$1,$2) {
  11431. $0 = $0|0;
  11432. $1 = $1|0;
  11433. $2 = $2|0;
  11434. var $$sink = 0, $10 = 0, $11 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  11435. sp = STACKTOP;
  11436. $3 = ((($1)) + 1296|0);
  11437. $4 = HEAP32[$3>>2]|0;
  11438. $5 = ($4|0)==(0);
  11439. if ($5) {
  11440. label = 3;
  11441. } else {
  11442. $6 = ((($1)) + 1300|0);
  11443. $7 = HEAP32[$6>>2]|0;
  11444. $8 = ($7|0)<(4);
  11445. if ($8) {
  11446. $$sink = 1;
  11447. } else {
  11448. label = 3;
  11449. }
  11450. }
  11451. if ((label|0) == 3) {
  11452. $$sink = 0;
  11453. }
  11454. $9 = ((($1)) + 1300|0);
  11455. $10 = HEAP32[$9>>2]|0;
  11456. $11 = (21388 + ($10<<2)|0);
  11457. HEAP32[$11>>2] = $$sink;
  11458. return 0;
  11459. }
  11460. function _SetTargetFPS($0) {
  11461. $0 = $0|0;
  11462. var $$ = 0.0, $$op = 0.0, $1 = 0, $2 = 0.0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $vararg_buffer = 0, label = 0, sp = 0;
  11463. sp = STACKTOP;
  11464. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  11465. $vararg_buffer = sp;
  11466. $1 = ($0|0)<(1);
  11467. $2 = (+($0|0));
  11468. $3 = 1.0 / $2;
  11469. $$ = $1 ? 0.0 : $3;
  11470. HEAPF64[2639] = $$;
  11471. $4 = $3;
  11472. $$op = $4 * 1000.0;
  11473. $5 = $$op;
  11474. $6 = $1 ? 0.0 : $5;
  11475. HEAPF64[$vararg_buffer>>3] = $6;
  11476. _TraceLog(0,5745,$vararg_buffer);
  11477. STACKTOP = sp;return;
  11478. }
  11479. function _LogoAnimation() {
  11480. var label = 0, sp = 0;
  11481. sp = STACKTOP;
  11482. HEAP32[5346] = 0;
  11483. return;
  11484. }
  11485. function _GetTime() {
  11486. var $0 = 0.0, label = 0, sp = 0;
  11487. sp = STACKTOP;
  11488. $0 = (+_glfwGetTime());
  11489. return (+$0);
  11490. }
  11491. function _LoadImageEx($0,$1,$2,$3) {
  11492. $0 = $0|0;
  11493. $1 = $1|0;
  11494. $2 = $2|0;
  11495. $3 = $3|0;
  11496. var $$03334 = 0, $$035 = 0, $$sroa$12$0$$sroa_idx21 = 0, $$sroa$15$0$$sroa_idx24 = 0, $$sroa$16$0$$sroa_idx26 = 0, $$sroa$9$0$$sroa_idx18 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  11497. var $24 = 0, $25 = 0, $26 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, label = 0, sp = 0;
  11498. sp = STACKTOP;
  11499. $4 = $2 << 2;
  11500. $5 = Math_imul($4, $3)|0;
  11501. $6 = (_malloc($5)|0);
  11502. $7 = ($5|0)>(0);
  11503. if ($7) {
  11504. $8 = (($5) + -1)|0;
  11505. $9 = $8 >>> 2;
  11506. $$03334 = 0;$$035 = 0;
  11507. while(1) {
  11508. $10 = (($1) + ($$03334<<2)|0);
  11509. $11 = HEAP8[$10>>0]|0;
  11510. $12 = (($6) + ($$035)|0);
  11511. HEAP8[$12>>0] = $11;
  11512. $13 = (((($1) + ($$03334<<2)|0)) + 1|0);
  11513. $14 = HEAP8[$13>>0]|0;
  11514. $15 = $$035 | 1;
  11515. $16 = (($6) + ($15)|0);
  11516. HEAP8[$16>>0] = $14;
  11517. $17 = (((($1) + ($$03334<<2)|0)) + 2|0);
  11518. $18 = HEAP8[$17>>0]|0;
  11519. $19 = $$035 | 2;
  11520. $20 = (($6) + ($19)|0);
  11521. HEAP8[$20>>0] = $18;
  11522. $21 = (((($1) + ($$03334<<2)|0)) + 3|0);
  11523. $22 = HEAP8[$21>>0]|0;
  11524. $23 = $$035 | 3;
  11525. $24 = (($6) + ($23)|0);
  11526. HEAP8[$24>>0] = $22;
  11527. $25 = (($$03334) + 1)|0;
  11528. $26 = (($$035) + 4)|0;
  11529. $exitcond = ($$03334|0)==($9|0);
  11530. if ($exitcond) {
  11531. break;
  11532. } else {
  11533. $$03334 = $25;$$035 = $26;
  11534. }
  11535. }
  11536. }
  11537. HEAP32[$0>>2] = $6;
  11538. $$sroa$9$0$$sroa_idx18 = ((($0)) + 4|0);
  11539. HEAP32[$$sroa$9$0$$sroa_idx18>>2] = $2;
  11540. $$sroa$12$0$$sroa_idx21 = ((($0)) + 8|0);
  11541. HEAP32[$$sroa$12$0$$sroa_idx21>>2] = $3;
  11542. $$sroa$15$0$$sroa_idx24 = ((($0)) + 12|0);
  11543. HEAP32[$$sroa$15$0$$sroa_idx24>>2] = 1;
  11544. $$sroa$16$0$$sroa_idx26 = ((($0)) + 16|0);
  11545. HEAP32[$$sroa$16$0$$sroa_idx26>>2] = 7;
  11546. return;
  11547. }
  11548. function _ImageFormat($0,$1) {
  11549. $0 = $0|0;
  11550. $1 = $1|0;
  11551. var $$0166199 = 0, $$0167197 = 0, $$0168195 = 0, $$0169192 = 0, $$0170190 = 0, $$0171188 = 0, $$0172189 = 0, $$0202 = 0, $$1194 = 0, $$2201 = 0, $$byval_copy = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0.0, $103 = 0.0, $104 = 0.0, $105 = 0, $106 = 0, $107 = 0;
  11552. var $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0;
  11553. var $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0;
  11554. var $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0;
  11555. var $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0.0, $17 = 0, $170 = 0.0, $171 = 0.0, $172 = 0, $173 = 0, $174 = 0, $175 = 0.0, $176 = 0.0, $177 = 0.0, $178 = 0, $179 = 0, $18 = 0;
  11556. var $180 = 0, $181 = 0.0, $182 = 0.0, $183 = 0.0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0.0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0;
  11557. var $199 = 0, $2 = 0, $20 = 0.0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0;
  11558. var $216 = 0, $217 = 0, $218 = 0.0, $219 = 0.0, $22 = 0, $220 = 0.0, $221 = 0, $222 = 0, $223 = 0, $224 = 0.0, $225 = 0.0, $226 = 0.0, $227 = 0, $228 = 0, $229 = 0, $23 = 0.0, $230 = 0.0, $231 = 0.0, $232 = 0.0, $233 = 0;
  11559. var $234 = 0, $235 = 0, $236 = 0.0, $237 = 0.0, $238 = 0.0, $239 = 0, $24 = 0.0, $240 = 0, $241 = 0, $242 = 0, $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0, $249 = 0, $25 = 0.0, $250 = 0, $251 = 0;
  11560. var $252 = 0, $253 = 0, $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0, $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0, $267 = 0, $268 = 0, $269 = 0, $27 = 0;
  11561. var $270 = 0, $271 = 0, $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0, $28 = 0.0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0, $285 = 0, $286 = 0, $287 = 0, $288 = 0;
  11562. var $289 = 0, $29 = 0.0, $290 = 0, $3 = 0, $30 = 0.0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  11563. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0.0, $53 = 0.0, $54 = 0, $55 = 0, $56 = 0.0, $57 = 0.0, $58 = 0.0, $59 = 0, $6 = 0, $60 = 0, $61 = 0.0, $62 = 0.0;
  11564. var $63 = 0.0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0;
  11565. var $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0.0, $91 = 0.0, $92 = 0.0, $93 = 0, $94 = 0, $95 = 0, $96 = 0.0, $97 = 0.0, $98 = 0.0, $99 = 0;
  11566. var $or$cond = 0, $roundf = 0.0, $roundf173 = 0.0, $roundf174 = 0.0, $roundf175 = 0.0, $roundf176 = 0.0, $roundf177 = 0.0, $roundf178 = 0.0, $roundf179 = 0.0, $roundf180 = 0.0, $roundf181 = 0.0, $vararg_buffer = 0, label = 0, sp = 0;
  11567. sp = STACKTOP;
  11568. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  11569. $$byval_copy = sp + 4|0;
  11570. $vararg_buffer = sp;
  11571. $2 = ((($0)) + 16|0);
  11572. $3 = HEAP32[$2>>2]|0;
  11573. $4 = ($3|0)==($1|0);
  11574. if ($4) {
  11575. STACKTOP = sp;return;
  11576. }
  11577. $5 = ($3|0)<(8);
  11578. $6 = ($1|0)<(8);
  11579. $or$cond = $6 & $5;
  11580. if (!($or$cond)) {
  11581. _TraceLog(2,6308,$vararg_buffer);
  11582. STACKTOP = sp;return;
  11583. }
  11584. ;HEAP32[$$byval_copy>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy+16>>2]=HEAP32[$0+16>>2]|0;
  11585. $7 = (_GetImageData($$byval_copy)|0);
  11586. $8 = HEAP32[$0>>2]|0;
  11587. _free($8);
  11588. HEAP32[$2>>2] = $1;
  11589. switch ($1|0) {
  11590. case 1: {
  11591. $9 = ((($0)) + 4|0);
  11592. $10 = HEAP32[$9>>2]|0;
  11593. $11 = ((($0)) + 8|0);
  11594. $12 = HEAP32[$11>>2]|0;
  11595. $13 = Math_imul($12, $10)|0;
  11596. $14 = (_malloc($13)|0);
  11597. HEAP32[$0>>2] = $14;
  11598. $15 = Math_imul($12, $10)|0;
  11599. $16 = ($15|0)>(0);
  11600. if ($16) {
  11601. $$0171188 = 0;
  11602. while(1) {
  11603. $17 = (($7) + ($$0171188<<2)|0);
  11604. $18 = HEAP8[$17>>0]|0;
  11605. $19 = (+($18&255));
  11606. $20 = $19 * 0.29899999499320984;
  11607. $21 = (((($7) + ($$0171188<<2)|0)) + 1|0);
  11608. $22 = HEAP8[$21>>0]|0;
  11609. $23 = (+($22&255));
  11610. $24 = $23 * 0.58700001239776611;
  11611. $25 = $20 + $24;
  11612. $26 = (((($7) + ($$0171188<<2)|0)) + 2|0);
  11613. $27 = HEAP8[$26>>0]|0;
  11614. $28 = (+($27&255));
  11615. $29 = $28 * 0.11400000005960464;
  11616. $30 = $25 + $29;
  11617. $31 = (~~(($30))&255);
  11618. $32 = HEAP32[$0>>2]|0;
  11619. $33 = (($32) + ($$0171188)|0);
  11620. HEAP8[$33>>0] = $31;
  11621. $34 = (($$0171188) + 1)|0;
  11622. $35 = HEAP32[$9>>2]|0;
  11623. $36 = HEAP32[$11>>2]|0;
  11624. $37 = Math_imul($36, $35)|0;
  11625. $38 = ($34|0)<($37|0);
  11626. if ($38) {
  11627. $$0171188 = $34;
  11628. } else {
  11629. break;
  11630. }
  11631. }
  11632. }
  11633. break;
  11634. }
  11635. case 2: {
  11636. $39 = ((($0)) + 4|0);
  11637. $40 = HEAP32[$39>>2]|0;
  11638. $41 = ((($0)) + 8|0);
  11639. $42 = HEAP32[$41>>2]|0;
  11640. $43 = $40 << 1;
  11641. $44 = Math_imul($43, $42)|0;
  11642. $45 = (_malloc($44)|0);
  11643. HEAP32[$0>>2] = $45;
  11644. $46 = HEAP32[$39>>2]|0;
  11645. $47 = $46 << 1;
  11646. $48 = Math_imul($47, $42)|0;
  11647. $49 = ($48|0)>(0);
  11648. if ($49) {
  11649. $$0170190 = 0;$$0172189 = 0;
  11650. while(1) {
  11651. $50 = (($7) + ($$0172189<<2)|0);
  11652. $51 = HEAP8[$50>>0]|0;
  11653. $52 = (+($51&255));
  11654. $53 = $52 * 0.29899999499320984;
  11655. $54 = (((($7) + ($$0172189<<2)|0)) + 1|0);
  11656. $55 = HEAP8[$54>>0]|0;
  11657. $56 = (+($55&255));
  11658. $57 = $56 * 0.58700001239776611;
  11659. $58 = $53 + $57;
  11660. $59 = (((($7) + ($$0172189<<2)|0)) + 2|0);
  11661. $60 = HEAP8[$59>>0]|0;
  11662. $61 = (+($60&255));
  11663. $62 = $61 * 0.11400000005960464;
  11664. $63 = $58 + $62;
  11665. $64 = (~~(($63))&255);
  11666. $65 = HEAP32[$0>>2]|0;
  11667. $66 = (($65) + ($$0170190)|0);
  11668. HEAP8[$66>>0] = $64;
  11669. $67 = (((($7) + ($$0172189<<2)|0)) + 3|0);
  11670. $68 = HEAP8[$67>>0]|0;
  11671. $69 = HEAP32[$0>>2]|0;
  11672. $70 = $$0170190 | 1;
  11673. $71 = (($69) + ($70)|0);
  11674. HEAP8[$71>>0] = $68;
  11675. $72 = (($$0172189) + 1)|0;
  11676. $73 = (($$0170190) + 2)|0;
  11677. $74 = HEAP32[$39>>2]|0;
  11678. $75 = HEAP32[$41>>2]|0;
  11679. $76 = $74 << 1;
  11680. $77 = Math_imul($76, $75)|0;
  11681. $78 = ($73|0)<($77|0);
  11682. if ($78) {
  11683. $$0170190 = $73;$$0172189 = $72;
  11684. } else {
  11685. break;
  11686. }
  11687. }
  11688. }
  11689. break;
  11690. }
  11691. case 3: {
  11692. $79 = ((($0)) + 4|0);
  11693. $80 = HEAP32[$79>>2]|0;
  11694. $81 = ((($0)) + 8|0);
  11695. $82 = HEAP32[$81>>2]|0;
  11696. $83 = $80 << 1;
  11697. $84 = Math_imul($83, $82)|0;
  11698. $85 = (_malloc($84)|0);
  11699. HEAP32[$0>>2] = $85;
  11700. $86 = HEAP32[$79>>2]|0;
  11701. $87 = Math_imul($82, $86)|0;
  11702. $88 = ($87|0)>(0);
  11703. if ($88) {
  11704. $89 = HEAP8[$7>>0]|0;
  11705. $90 = (+($89&255));
  11706. $91 = $90 * 31.0;
  11707. $92 = $91 / 255.0;
  11708. $roundf179 = (+_roundf((+$92)));
  11709. $93 = (~~(($roundf179))&255);
  11710. $94 = ((($7)) + 1|0);
  11711. $95 = HEAP8[$94>>0]|0;
  11712. $96 = (+($95&255));
  11713. $97 = $96 * 63.0;
  11714. $98 = $97 / 255.0;
  11715. $roundf180 = (+_roundf((+$98)));
  11716. $99 = (~~(($roundf180))&255);
  11717. $100 = ((($7)) + 2|0);
  11718. $101 = HEAP8[$100>>0]|0;
  11719. $102 = (+($101&255));
  11720. $103 = $102 * 31.0;
  11721. $104 = $103 / 255.0;
  11722. $roundf181 = (+_roundf((+$104)));
  11723. $105 = (~~(($roundf181))&255);
  11724. $106 = $93&255;
  11725. $107 = $106 << 11;
  11726. $108 = $99&255;
  11727. $109 = $108 << 5;
  11728. $110 = $109 | $107;
  11729. $111 = $105&255;
  11730. $112 = $110 | $111;
  11731. $113 = $112&65535;
  11732. $114 = HEAP32[$0>>2]|0;
  11733. $115 = HEAP32[$79>>2]|0;
  11734. $116 = HEAP32[$81>>2]|0;
  11735. $117 = Math_imul($116, $115)|0;
  11736. $$0169192 = 0;
  11737. while(1) {
  11738. $118 = (($114) + ($$0169192<<1)|0);
  11739. HEAP16[$118>>1] = $113;
  11740. $119 = (($$0169192) + 1)|0;
  11741. $120 = ($119|0)<($117|0);
  11742. if ($120) {
  11743. $$0169192 = $119;
  11744. } else {
  11745. break;
  11746. }
  11747. }
  11748. }
  11749. break;
  11750. }
  11751. case 4: {
  11752. $121 = ((($0)) + 4|0);
  11753. $122 = HEAP32[$121>>2]|0;
  11754. $123 = ((($0)) + 8|0);
  11755. $124 = HEAP32[$123>>2]|0;
  11756. $125 = ($122*3)|0;
  11757. $126 = Math_imul($125, $124)|0;
  11758. $127 = (_malloc($126)|0);
  11759. HEAP32[$0>>2] = $127;
  11760. $128 = HEAP32[$121>>2]|0;
  11761. $129 = ($128*3)|0;
  11762. $130 = Math_imul($129, $124)|0;
  11763. $131 = ($130|0)>(0);
  11764. if ($131) {
  11765. $$0168195 = 0;$$1194 = 0;
  11766. while(1) {
  11767. $132 = (($7) + ($$1194<<2)|0);
  11768. $133 = HEAP8[$132>>0]|0;
  11769. $134 = HEAP32[$0>>2]|0;
  11770. $135 = (($134) + ($$0168195)|0);
  11771. HEAP8[$135>>0] = $133;
  11772. $136 = (((($7) + ($$1194<<2)|0)) + 1|0);
  11773. $137 = HEAP8[$136>>0]|0;
  11774. $138 = HEAP32[$0>>2]|0;
  11775. $139 = (($$0168195) + 1)|0;
  11776. $140 = (($138) + ($139)|0);
  11777. HEAP8[$140>>0] = $137;
  11778. $141 = (((($7) + ($$1194<<2)|0)) + 2|0);
  11779. $142 = HEAP8[$141>>0]|0;
  11780. $143 = HEAP32[$0>>2]|0;
  11781. $144 = (($$0168195) + 2)|0;
  11782. $145 = (($143) + ($144)|0);
  11783. HEAP8[$145>>0] = $142;
  11784. $146 = (($$1194) + 1)|0;
  11785. $147 = (($$0168195) + 3)|0;
  11786. $148 = HEAP32[$121>>2]|0;
  11787. $149 = HEAP32[$123>>2]|0;
  11788. $150 = ($148*3)|0;
  11789. $151 = Math_imul($150, $149)|0;
  11790. $152 = ($147|0)<($151|0);
  11791. if ($152) {
  11792. $$0168195 = $147;$$1194 = $146;
  11793. } else {
  11794. break;
  11795. }
  11796. }
  11797. }
  11798. break;
  11799. }
  11800. case 5: {
  11801. $153 = ((($0)) + 4|0);
  11802. $154 = HEAP32[$153>>2]|0;
  11803. $155 = ((($0)) + 8|0);
  11804. $156 = HEAP32[$155>>2]|0;
  11805. $157 = $154 << 1;
  11806. $158 = Math_imul($157, $156)|0;
  11807. $159 = (_malloc($158)|0);
  11808. HEAP32[$0>>2] = $159;
  11809. $160 = HEAP32[$153>>2]|0;
  11810. $161 = Math_imul($156, $160)|0;
  11811. $162 = ($161|0)>(0);
  11812. if ($162) {
  11813. $163 = HEAP32[$0>>2]|0;
  11814. $164 = HEAP32[$153>>2]|0;
  11815. $165 = HEAP32[$155>>2]|0;
  11816. $166 = Math_imul($165, $164)|0;
  11817. $$0167197 = 0;
  11818. while(1) {
  11819. $167 = (($7) + ($$0167197<<2)|0);
  11820. $168 = HEAP8[$167>>0]|0;
  11821. $169 = (+($168&255));
  11822. $170 = $169 * 31.0;
  11823. $171 = $170 / 255.0;
  11824. $roundf176 = (+_roundf((+$171)));
  11825. $172 = (~~(($roundf176))&255);
  11826. $173 = (((($7) + ($$0167197<<2)|0)) + 1|0);
  11827. $174 = HEAP8[$173>>0]|0;
  11828. $175 = (+($174&255));
  11829. $176 = $175 * 31.0;
  11830. $177 = $176 / 255.0;
  11831. $roundf177 = (+_roundf((+$177)));
  11832. $178 = (~~(($roundf177))&255);
  11833. $179 = (((($7) + ($$0167197<<2)|0)) + 2|0);
  11834. $180 = HEAP8[$179>>0]|0;
  11835. $181 = (+($180&255));
  11836. $182 = $181 * 31.0;
  11837. $183 = $182 / 255.0;
  11838. $roundf178 = (+_roundf((+$183)));
  11839. $184 = (~~(($roundf178))&255);
  11840. $185 = (((($7) + ($$0167197<<2)|0)) + 3|0);
  11841. $186 = HEAP8[$185>>0]|0;
  11842. $187 = ($186&255)>(50);
  11843. $188 = $172&255;
  11844. $189 = $188 << 11;
  11845. $190 = $178&255;
  11846. $191 = $190 << 6;
  11847. $192 = $191 | $189;
  11848. $193 = $184&255;
  11849. $194 = $193 << 1;
  11850. $195 = $192 | $194;
  11851. $196 = $187&1;
  11852. $197 = $195 | $196;
  11853. $198 = $197&65535;
  11854. $199 = (($163) + ($$0167197<<1)|0);
  11855. HEAP16[$199>>1] = $198;
  11856. $200 = (($$0167197) + 1)|0;
  11857. $201 = ($200|0)<($166|0);
  11858. if ($201) {
  11859. $$0167197 = $200;
  11860. } else {
  11861. break;
  11862. }
  11863. }
  11864. }
  11865. break;
  11866. }
  11867. case 6: {
  11868. $202 = ((($0)) + 4|0);
  11869. $203 = HEAP32[$202>>2]|0;
  11870. $204 = ((($0)) + 8|0);
  11871. $205 = HEAP32[$204>>2]|0;
  11872. $206 = $203 << 1;
  11873. $207 = Math_imul($206, $205)|0;
  11874. $208 = (_malloc($207)|0);
  11875. HEAP32[$0>>2] = $208;
  11876. $209 = HEAP32[$202>>2]|0;
  11877. $210 = Math_imul($205, $209)|0;
  11878. $211 = ($210|0)>(0);
  11879. if ($211) {
  11880. $212 = HEAP32[$0>>2]|0;
  11881. $213 = HEAP32[$202>>2]|0;
  11882. $214 = HEAP32[$204>>2]|0;
  11883. $215 = Math_imul($214, $213)|0;
  11884. $$0166199 = 0;
  11885. while(1) {
  11886. $216 = (($7) + ($$0166199<<2)|0);
  11887. $217 = HEAP8[$216>>0]|0;
  11888. $218 = (+($217&255));
  11889. $219 = $218 * 15.0;
  11890. $220 = $219 / 255.0;
  11891. $roundf = (+_roundf((+$220)));
  11892. $221 = (~~(($roundf))&255);
  11893. $222 = (((($7) + ($$0166199<<2)|0)) + 1|0);
  11894. $223 = HEAP8[$222>>0]|0;
  11895. $224 = (+($223&255));
  11896. $225 = $224 * 15.0;
  11897. $226 = $225 / 255.0;
  11898. $roundf173 = (+_roundf((+$226)));
  11899. $227 = (~~(($roundf173))&255);
  11900. $228 = (((($7) + ($$0166199<<2)|0)) + 2|0);
  11901. $229 = HEAP8[$228>>0]|0;
  11902. $230 = (+($229&255));
  11903. $231 = $230 * 15.0;
  11904. $232 = $231 / 255.0;
  11905. $roundf174 = (+_roundf((+$232)));
  11906. $233 = (~~(($roundf174))&255);
  11907. $234 = (((($7) + ($$0166199<<2)|0)) + 3|0);
  11908. $235 = HEAP8[$234>>0]|0;
  11909. $236 = (+($235&255));
  11910. $237 = $236 * 15.0;
  11911. $238 = $237 / 255.0;
  11912. $roundf175 = (+_roundf((+$238)));
  11913. $239 = (~~(($roundf175))&255);
  11914. $240 = $221&255;
  11915. $241 = $240 << 12;
  11916. $242 = $227&255;
  11917. $243 = $242 << 8;
  11918. $244 = $243 | $241;
  11919. $245 = $233&255;
  11920. $246 = $245 << 4;
  11921. $247 = $244 | $246;
  11922. $248 = $239&255;
  11923. $249 = $247 | $248;
  11924. $250 = $249&65535;
  11925. $251 = (($212) + ($$0166199<<1)|0);
  11926. HEAP16[$251>>1] = $250;
  11927. $252 = (($$0166199) + 1)|0;
  11928. $253 = ($252|0)<($215|0);
  11929. if ($253) {
  11930. $$0166199 = $252;
  11931. } else {
  11932. break;
  11933. }
  11934. }
  11935. }
  11936. break;
  11937. }
  11938. case 7: {
  11939. $254 = ((($0)) + 4|0);
  11940. $255 = HEAP32[$254>>2]|0;
  11941. $256 = ((($0)) + 8|0);
  11942. $257 = HEAP32[$256>>2]|0;
  11943. $258 = $255 << 2;
  11944. $259 = Math_imul($258, $257)|0;
  11945. $260 = (_malloc($259)|0);
  11946. HEAP32[$0>>2] = $260;
  11947. $261 = HEAP32[$254>>2]|0;
  11948. $262 = $261 << 2;
  11949. $263 = Math_imul($262, $257)|0;
  11950. $264 = ($263|0)>(0);
  11951. if ($264) {
  11952. $$0202 = 0;$$2201 = 0;
  11953. while(1) {
  11954. $265 = (($7) + ($$2201<<2)|0);
  11955. $266 = HEAP8[$265>>0]|0;
  11956. $267 = HEAP32[$0>>2]|0;
  11957. $268 = (($267) + ($$0202)|0);
  11958. HEAP8[$268>>0] = $266;
  11959. $269 = (((($7) + ($$2201<<2)|0)) + 1|0);
  11960. $270 = HEAP8[$269>>0]|0;
  11961. $271 = HEAP32[$0>>2]|0;
  11962. $272 = $$0202 | 1;
  11963. $273 = (($271) + ($272)|0);
  11964. HEAP8[$273>>0] = $270;
  11965. $274 = (((($7) + ($$2201<<2)|0)) + 2|0);
  11966. $275 = HEAP8[$274>>0]|0;
  11967. $276 = HEAP32[$0>>2]|0;
  11968. $277 = $$0202 | 2;
  11969. $278 = (($276) + ($277)|0);
  11970. HEAP8[$278>>0] = $275;
  11971. $279 = (((($7) + ($$2201<<2)|0)) + 3|0);
  11972. $280 = HEAP8[$279>>0]|0;
  11973. $281 = HEAP32[$0>>2]|0;
  11974. $282 = $$0202 | 3;
  11975. $283 = (($281) + ($282)|0);
  11976. HEAP8[$283>>0] = $280;
  11977. $284 = (($$2201) + 1)|0;
  11978. $285 = (($$0202) + 4)|0;
  11979. $286 = HEAP32[$254>>2]|0;
  11980. $287 = HEAP32[$256>>2]|0;
  11981. $288 = $286 << 2;
  11982. $289 = Math_imul($288, $287)|0;
  11983. $290 = ($285|0)<($289|0);
  11984. if ($290) {
  11985. $$0202 = $285;$$2201 = $284;
  11986. } else {
  11987. break;
  11988. }
  11989. }
  11990. }
  11991. break;
  11992. }
  11993. default: {
  11994. }
  11995. }
  11996. _free($7);
  11997. STACKTOP = sp;return;
  11998. }
  11999. function _LoadTextureFromImage($0,$1) {
  12000. $0 = $0|0;
  12001. $1 = $1|0;
  12002. var $$sroa$11$0$$sroa_idx8 = 0, $$sroa$5$0$$sroa_idx2 = 0, $$sroa$7$0$$sroa_idx4 = 0, $$sroa$9$0$$sroa_idx6 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  12003. sp = STACKTOP;
  12004. $2 = HEAP32[$1>>2]|0;
  12005. $3 = ((($1)) + 4|0);
  12006. $4 = HEAP32[$3>>2]|0;
  12007. $5 = ((($1)) + 8|0);
  12008. $6 = HEAP32[$5>>2]|0;
  12009. $7 = ((($1)) + 16|0);
  12010. $8 = HEAP32[$7>>2]|0;
  12011. $9 = ((($1)) + 12|0);
  12012. $10 = HEAP32[$9>>2]|0;
  12013. $11 = (_rlglLoadTexture($2,$4,$6,$8,$10)|0);
  12014. $12 = HEAP32[$3>>2]|0;
  12015. $13 = HEAP32[$5>>2]|0;
  12016. HEAP32[$0>>2] = $11;
  12017. $$sroa$5$0$$sroa_idx2 = ((($0)) + 4|0);
  12018. HEAP32[$$sroa$5$0$$sroa_idx2>>2] = $12;
  12019. $$sroa$7$0$$sroa_idx4 = ((($0)) + 8|0);
  12020. HEAP32[$$sroa$7$0$$sroa_idx4>>2] = $13;
  12021. $$sroa$9$0$$sroa_idx6 = ((($0)) + 12|0);
  12022. HEAP32[$$sroa$9$0$$sroa_idx6>>2] = $10;
  12023. $$sroa$11$0$$sroa_idx8 = ((($0)) + 16|0);
  12024. HEAP32[$$sroa$11$0$$sroa_idx8>>2] = $8;
  12025. return;
  12026. }
  12027. function _UnloadImage($0) {
  12028. $0 = $0|0;
  12029. var $1 = 0, label = 0, sp = 0;
  12030. sp = STACKTOP;
  12031. $1 = HEAP32[$0>>2]|0;
  12032. _free($1);
  12033. return;
  12034. }
  12035. function _rlglLoadTexture($0,$1,$2,$3,$4) {
  12036. $0 = $0|0;
  12037. $1 = $1|0;
  12038. $2 = $2|0;
  12039. $3 = $3|0;
  12040. $4 = $4|0;
  12041. var $$0 = 0, $$off = 0, $$off92 = 0, $$off93 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  12042. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0;
  12043. var $46 = 0, $47 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond100 = 0, $or$cond7 = 0, $or$cond96 = 0, $or$cond98 = 0, $switch = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer11 = 0, $vararg_buffer15 = 0, $vararg_buffer3 = 0, $vararg_buffer5 = 0, $vararg_buffer7 = 0;
  12044. var $vararg_buffer9 = 0, $vararg_ptr13 = 0, $vararg_ptr14 = 0, label = 0, sp = 0;
  12045. sp = STACKTOP;
  12046. STACKTOP = STACKTOP + 80|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(80|0);
  12047. $vararg_buffer15 = sp + 64|0;
  12048. $vararg_buffer11 = sp + 48|0;
  12049. $vararg_buffer9 = sp + 40|0;
  12050. $vararg_buffer7 = sp + 32|0;
  12051. $vararg_buffer5 = sp + 24|0;
  12052. $vararg_buffer3 = sp + 16|0;
  12053. $vararg_buffer1 = sp + 8|0;
  12054. $vararg_buffer = sp;
  12055. $5 = sp + 68|0;
  12056. _glBindTexture(3553,0);
  12057. HEAP32[$5>>2] = 0;
  12058. $6 = HEAP32[5359]|0;
  12059. $7 = ($6|0)==(0);
  12060. $8 = $3 & -4;
  12061. $switch = ($8|0)==(8);
  12062. $or$cond100 = $switch & $7;
  12063. if ($or$cond100) {
  12064. _TraceLog(2,5977,$vararg_buffer);
  12065. $$0 = HEAP32[$5>>2]|0;
  12066. STACKTOP = sp;return ($$0|0);
  12067. }
  12068. $9 = HEAP32[5360]|0;
  12069. $10 = ($9|0)==(0);
  12070. $11 = ($3|0)==(12);
  12071. $or$cond7 = $11 & $10;
  12072. if ($or$cond7) {
  12073. _TraceLog(2,6021,$vararg_buffer1);
  12074. $$0 = HEAP32[$5>>2]|0;
  12075. STACKTOP = sp;return ($$0|0);
  12076. }
  12077. $12 = HEAP32[5361]|0;
  12078. $13 = ($12|0)==(0);
  12079. $$off = (($3) + -13)|0;
  12080. $14 = ($$off>>>0)<(2);
  12081. $or$cond = $14 & $13;
  12082. if ($or$cond) {
  12083. _TraceLog(2,6066,$vararg_buffer3);
  12084. $$0 = HEAP32[$5>>2]|0;
  12085. STACKTOP = sp;return ($$0|0);
  12086. }
  12087. $15 = HEAP32[5362]|0;
  12088. $16 = ($15|0)==(0);
  12089. $$off92 = (($3) + -15)|0;
  12090. $17 = ($$off92>>>0)<(2);
  12091. $or$cond96 = $17 & $16;
  12092. if ($or$cond96) {
  12093. _TraceLog(2,6111,$vararg_buffer5);
  12094. $$0 = HEAP32[$5>>2]|0;
  12095. STACKTOP = sp;return ($$0|0);
  12096. }
  12097. $18 = HEAP32[5363]|0;
  12098. $19 = ($18|0)==(0);
  12099. $$off93 = (($3) + -17)|0;
  12100. $20 = ($$off93>>>0)<(2);
  12101. $or$cond98 = $20 & $19;
  12102. if ($or$cond98) {
  12103. _TraceLog(2,6156,$vararg_buffer7);
  12104. $$0 = HEAP32[$5>>2]|0;
  12105. STACKTOP = sp;return ($$0|0);
  12106. }
  12107. _glGenTextures(1,($5|0));
  12108. $21 = HEAP32[$5>>2]|0;
  12109. _glBindTexture(3553,($21|0));
  12110. do {
  12111. switch ($3|0) {
  12112. case 1: {
  12113. _glTexImage2D(3553,0,6409,($1|0),($2|0),0,6409,5121,($0|0));
  12114. break;
  12115. }
  12116. case 2: {
  12117. _glTexImage2D(3553,0,6410,($1|0),($2|0),0,6410,5121,($0|0));
  12118. break;
  12119. }
  12120. case 3: {
  12121. _glTexImage2D(3553,0,6407,($1|0),($2|0),0,6407,33635,($0|0));
  12122. break;
  12123. }
  12124. case 4: {
  12125. _glTexImage2D(3553,0,6407,($1|0),($2|0),0,6407,5121,($0|0));
  12126. break;
  12127. }
  12128. case 5: {
  12129. _glTexImage2D(3553,0,6408,($1|0),($2|0),0,6408,32820,($0|0));
  12130. break;
  12131. }
  12132. case 6: {
  12133. _glTexImage2D(3553,0,6408,($1|0),($2|0),0,6408,32819,($0|0));
  12134. break;
  12135. }
  12136. case 7: {
  12137. _glTexImage2D(3553,0,6408,($1|0),($2|0),0,6408,5121,($0|0));
  12138. break;
  12139. }
  12140. case 8: {
  12141. $22 = HEAP32[5359]|0;
  12142. $23 = ($22|0)==(0);
  12143. if (!($23)) {
  12144. _LoadCompressedTexture($0,$1,$2,$4,33776);
  12145. }
  12146. break;
  12147. }
  12148. case 9: {
  12149. $24 = HEAP32[5359]|0;
  12150. $25 = ($24|0)==(0);
  12151. if (!($25)) {
  12152. _LoadCompressedTexture($0,$1,$2,$4,33777);
  12153. }
  12154. break;
  12155. }
  12156. case 10: {
  12157. $26 = HEAP32[5359]|0;
  12158. $27 = ($26|0)==(0);
  12159. if (!($27)) {
  12160. _LoadCompressedTexture($0,$1,$2,$4,33778);
  12161. }
  12162. break;
  12163. }
  12164. case 11: {
  12165. $28 = HEAP32[5359]|0;
  12166. $29 = ($28|0)==(0);
  12167. if (!($29)) {
  12168. _LoadCompressedTexture($0,$1,$2,$4,33779);
  12169. }
  12170. break;
  12171. }
  12172. case 12: {
  12173. $30 = HEAP32[5360]|0;
  12174. $31 = ($30|0)==(0);
  12175. if (!($31)) {
  12176. _LoadCompressedTexture($0,$1,$2,$4,36196);
  12177. }
  12178. break;
  12179. }
  12180. case 13: {
  12181. $32 = HEAP32[5361]|0;
  12182. $33 = ($32|0)==(0);
  12183. if (!($33)) {
  12184. _LoadCompressedTexture($0,$1,$2,$4,37492);
  12185. }
  12186. break;
  12187. }
  12188. case 14: {
  12189. $34 = HEAP32[5361]|0;
  12190. $35 = ($34|0)==(0);
  12191. if (!($35)) {
  12192. _LoadCompressedTexture($0,$1,$2,$4,37496);
  12193. }
  12194. break;
  12195. }
  12196. case 15: {
  12197. $36 = HEAP32[5362]|0;
  12198. $37 = ($36|0)==(0);
  12199. if (!($37)) {
  12200. _LoadCompressedTexture($0,$1,$2,$4,35840);
  12201. }
  12202. break;
  12203. }
  12204. case 16: {
  12205. $38 = HEAP32[5362]|0;
  12206. $39 = ($38|0)==(0);
  12207. if (!($39)) {
  12208. _LoadCompressedTexture($0,$1,$2,$4,35842);
  12209. }
  12210. break;
  12211. }
  12212. case 17: {
  12213. $40 = HEAP32[5363]|0;
  12214. $41 = ($40|0)==(0);
  12215. if (!($41)) {
  12216. _LoadCompressedTexture($0,$1,$2,$4,37808);
  12217. }
  12218. break;
  12219. }
  12220. case 18: {
  12221. $42 = HEAP32[5363]|0;
  12222. $43 = ($42|0)==(0);
  12223. if (!($43)) {
  12224. _LoadCompressedTexture($0,$1,$2,$4,37815);
  12225. }
  12226. break;
  12227. }
  12228. default: {
  12229. _TraceLog(2,6201,$vararg_buffer9);
  12230. }
  12231. }
  12232. } while(0);
  12233. $44 = HEAP32[5364]|0;
  12234. $45 = ($44|0)==(0);
  12235. if ($45) {
  12236. _glTexParameteri(3553,10242,33071);
  12237. _glTexParameteri(3553,10243,33071);
  12238. } else {
  12239. _glTexParameteri(3553,10242,10497);
  12240. _glTexParameteri(3553,10243,10497);
  12241. }
  12242. _glTexParameteri(3553,10240,9728);
  12243. _glTexParameteri(3553,10241,9728);
  12244. _glBindTexture(3553,0);
  12245. $46 = HEAP32[$5>>2]|0;
  12246. $47 = ($46|0)==(0);
  12247. if ($47) {
  12248. _TraceLog(2,6279,$vararg_buffer15);
  12249. $$0 = HEAP32[$5>>2]|0;
  12250. STACKTOP = sp;return ($$0|0);
  12251. } else {
  12252. HEAP32[$vararg_buffer11>>2] = $46;
  12253. $vararg_ptr13 = ((($vararg_buffer11)) + 4|0);
  12254. HEAP32[$vararg_ptr13>>2] = $1;
  12255. $vararg_ptr14 = ((($vararg_buffer11)) + 8|0);
  12256. HEAP32[$vararg_ptr14>>2] = $2;
  12257. _TraceLog(0,6230,$vararg_buffer11);
  12258. $$0 = HEAP32[$5>>2]|0;
  12259. STACKTOP = sp;return ($$0|0);
  12260. }
  12261. return (0)|0;
  12262. }
  12263. function _LoadCompressedTexture($0,$1,$2,$3,$4) {
  12264. $0 = $0|0;
  12265. $1 = $1|0;
  12266. $2 = $2|0;
  12267. $3 = $3|0;
  12268. $4 = $4|0;
  12269. var $$ = 0, $$03645 = 0, $$03744 = 0, $$038 = 0, $$03943 = 0, $$046 = 0, $$140 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0;
  12270. var $23 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond42 = 0, label = 0, sp = 0;
  12271. sp = STACKTOP;
  12272. _glPixelStorei(3317,1);
  12273. switch ($4|0) {
  12274. case 33776: case 33777: case 36196: case 37492: {
  12275. $$038 = 8;
  12276. break;
  12277. }
  12278. default: {
  12279. $$038 = 16;
  12280. }
  12281. }
  12282. $5 = ($3|0)<(1);
  12283. $6 = $1 | $2;
  12284. $7 = ($6|0)==(0);
  12285. $or$cond42 = $5 | $7;
  12286. if ($or$cond42) {
  12287. return;
  12288. } else {
  12289. $$03645 = 0;$$03744 = 0;$$03943 = $2;$$046 = $1;
  12290. }
  12291. while(1) {
  12292. $8 = (($$046) + 3)|0;
  12293. $9 = (($8|0) / 4)&-1;
  12294. $10 = (($$03943) + 3)|0;
  12295. $11 = (($10|0) / 4)&-1;
  12296. $12 = Math_imul($11, $$038)|0;
  12297. $13 = Math_imul($12, $9)|0;
  12298. $14 = (($0) + ($$03744)|0);
  12299. _glCompressedTexImage2D(3553,($$03645|0),($4|0),($$046|0),($$03943|0),0,($13|0),($14|0));
  12300. $15 = (($13) + ($$03744))|0;
  12301. $16 = (($$046|0) / 2)&-1;
  12302. $17 = (($$03943|0) / 2)&-1;
  12303. $18 = ($$046|0)<(2);
  12304. $$ = $18 ? 1 : $16;
  12305. $19 = ($$03943|0)<(2);
  12306. $$140 = $19 ? 1 : $17;
  12307. $20 = (($$03645) + 1)|0;
  12308. $21 = ($20|0)>=($3|0);
  12309. $22 = $$ | $$140;
  12310. $23 = ($22|0)==(0);
  12311. $or$cond = $21 | $23;
  12312. if ($or$cond) {
  12313. break;
  12314. } else {
  12315. $$03645 = $20;$$03744 = $15;$$03943 = $$140;$$046 = $$;
  12316. }
  12317. }
  12318. return;
  12319. }
  12320. function _GetImageData($0) {
  12321. $0 = $0|0;
  12322. var $$0104105 = 0, $$0106 = 0, $$1 = 0, $1 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0.0, $103 = 0.0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0;
  12323. var $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0;
  12324. var $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  12325. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0.0, $4 = 0, $40 = 0.0, $41 = 0;
  12326. var $42 = 0, $43 = 0, $44 = 0, $45 = 0.0, $46 = 0.0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0.0, $52 = 0.0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0;
  12327. var $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0.0, $65 = 0.0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0.0, $71 = 0.0, $72 = 0, $73 = 0, $74 = 0, $75 = 0.0, $76 = 0.0, $77 = 0, $78 = 0;
  12328. var $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0.0, $86 = 0.0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0.0, $92 = 0.0, $93 = 0, $94 = 0, $95 = 0, $96 = 0;
  12329. var $97 = 0.0, $98 = 0.0, $99 = 0, $vararg_buffer = 0, label = 0, sp = 0;
  12330. sp = STACKTOP;
  12331. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  12332. $vararg_buffer = sp;
  12333. $1 = ((($0)) + 4|0);
  12334. $2 = HEAP32[$1>>2]|0;
  12335. $3 = ((($0)) + 8|0);
  12336. $4 = HEAP32[$3>>2]|0;
  12337. $5 = $2 << 2;
  12338. $6 = Math_imul($5, $4)|0;
  12339. $7 = (_malloc($6)|0);
  12340. $8 = HEAP32[$1>>2]|0;
  12341. $9 = Math_imul($4, $8)|0;
  12342. $10 = ($9|0)>(0);
  12343. if (!($10)) {
  12344. STACKTOP = sp;return ($7|0);
  12345. }
  12346. $11 = ((($0)) + 16|0);
  12347. $12 = HEAP32[$11>>2]|0;
  12348. $13 = HEAP32[$0>>2]|0;
  12349. $$0104105 = 0;$$0106 = 0;
  12350. while(1) {
  12351. switch ($12|0) {
  12352. case 1: {
  12353. $14 = (($13) + ($$0106)|0);
  12354. $15 = HEAP8[$14>>0]|0;
  12355. $16 = (($7) + ($$0104105<<2)|0);
  12356. HEAP8[$16>>0] = $15;
  12357. $17 = HEAP8[$14>>0]|0;
  12358. $18 = (((($7) + ($$0104105<<2)|0)) + 1|0);
  12359. HEAP8[$18>>0] = $17;
  12360. $19 = HEAP8[$14>>0]|0;
  12361. $20 = (((($7) + ($$0104105<<2)|0)) + 2|0);
  12362. HEAP8[$20>>0] = $19;
  12363. $21 = (((($7) + ($$0104105<<2)|0)) + 3|0);
  12364. HEAP8[$21>>0] = -1;
  12365. $22 = (($$0106) + 1)|0;
  12366. $$1 = $22;
  12367. break;
  12368. }
  12369. case 2: {
  12370. $23 = (($13) + ($$0106)|0);
  12371. $24 = HEAP8[$23>>0]|0;
  12372. $25 = (($7) + ($$0104105<<2)|0);
  12373. HEAP8[$25>>0] = $24;
  12374. $26 = HEAP8[$23>>0]|0;
  12375. $27 = (((($7) + ($$0104105<<2)|0)) + 1|0);
  12376. HEAP8[$27>>0] = $26;
  12377. $28 = HEAP8[$23>>0]|0;
  12378. $29 = (((($7) + ($$0104105<<2)|0)) + 2|0);
  12379. HEAP8[$29>>0] = $28;
  12380. $30 = (($$0106) + 1)|0;
  12381. $31 = (($13) + ($30)|0);
  12382. $32 = HEAP8[$31>>0]|0;
  12383. $33 = (((($7) + ($$0104105<<2)|0)) + 3|0);
  12384. HEAP8[$33>>0] = $32;
  12385. $34 = (($$0106) + 2)|0;
  12386. $$1 = $34;
  12387. break;
  12388. }
  12389. case 5: {
  12390. $35 = (($13) + ($$0106<<1)|0);
  12391. $36 = HEAP16[$35>>1]|0;
  12392. $37 = $36&65535;
  12393. $38 = $37 >>> 11;
  12394. $39 = (+($38|0));
  12395. $40 = $39 * 8.0;
  12396. $41 = (~~(($40))&255);
  12397. $42 = (($7) + ($$0104105<<2)|0);
  12398. HEAP8[$42>>0] = $41;
  12399. $43 = $37 >>> 6;
  12400. $44 = $43 & 31;
  12401. $45 = (+($44|0));
  12402. $46 = $45 * 8.0;
  12403. $47 = (~~(($46))&255);
  12404. $48 = (((($7) + ($$0104105<<2)|0)) + 1|0);
  12405. HEAP8[$48>>0] = $47;
  12406. $49 = $37 >>> 1;
  12407. $50 = $49 & 31;
  12408. $51 = (+($50|0));
  12409. $52 = $51 * 8.0;
  12410. $53 = (~~(($52))&255);
  12411. $54 = (((($7) + ($$0104105<<2)|0)) + 2|0);
  12412. HEAP8[$54>>0] = $53;
  12413. $55 = $37 & 1;
  12414. $56 = (0 - ($55))|0;
  12415. $57 = $56&255;
  12416. $58 = (((($7) + ($$0104105<<2)|0)) + 3|0);
  12417. HEAP8[$58>>0] = $57;
  12418. $59 = (($$0106) + 1)|0;
  12419. $$1 = $59;
  12420. break;
  12421. }
  12422. case 3: {
  12423. $60 = (($13) + ($$0106<<1)|0);
  12424. $61 = HEAP16[$60>>1]|0;
  12425. $62 = $61&65535;
  12426. $63 = $62 >>> 11;
  12427. $64 = (+($63|0));
  12428. $65 = $64 * 8.0;
  12429. $66 = (~~(($65))&255);
  12430. $67 = (($7) + ($$0104105<<2)|0);
  12431. HEAP8[$67>>0] = $66;
  12432. $68 = $62 >>> 5;
  12433. $69 = $68 & 63;
  12434. $70 = (+($69|0));
  12435. $71 = $70 * 4.0;
  12436. $72 = (~~(($71))&255);
  12437. $73 = (((($7) + ($$0104105<<2)|0)) + 1|0);
  12438. HEAP8[$73>>0] = $72;
  12439. $74 = $62 & 31;
  12440. $75 = (+($74|0));
  12441. $76 = $75 * 8.0;
  12442. $77 = (~~(($76))&255);
  12443. $78 = (((($7) + ($$0104105<<2)|0)) + 2|0);
  12444. HEAP8[$78>>0] = $77;
  12445. $79 = (((($7) + ($$0104105<<2)|0)) + 3|0);
  12446. HEAP8[$79>>0] = -1;
  12447. $80 = (($$0106) + 1)|0;
  12448. $$1 = $80;
  12449. break;
  12450. }
  12451. case 6: {
  12452. $81 = (($13) + ($$0106<<1)|0);
  12453. $82 = HEAP16[$81>>1]|0;
  12454. $83 = $82&65535;
  12455. $84 = $83 >>> 12;
  12456. $85 = (+($84|0));
  12457. $86 = $85 * 17.0;
  12458. $87 = (~~(($86))&255);
  12459. $88 = (($7) + ($$0104105<<2)|0);
  12460. HEAP8[$88>>0] = $87;
  12461. $89 = $83 >>> 8;
  12462. $90 = $89 & 15;
  12463. $91 = (+($90|0));
  12464. $92 = $91 * 17.0;
  12465. $93 = (~~(($92))&255);
  12466. $94 = (((($7) + ($$0104105<<2)|0)) + 1|0);
  12467. HEAP8[$94>>0] = $93;
  12468. $95 = $83 >>> 4;
  12469. $96 = $95 & 15;
  12470. $97 = (+($96|0));
  12471. $98 = $97 * 17.0;
  12472. $99 = (~~(($98))&255);
  12473. $100 = (((($7) + ($$0104105<<2)|0)) + 2|0);
  12474. HEAP8[$100>>0] = $99;
  12475. $101 = $83 & 15;
  12476. $102 = (+($101|0));
  12477. $103 = $102 * 17.0;
  12478. $104 = (~~(($103))&255);
  12479. $105 = (((($7) + ($$0104105<<2)|0)) + 3|0);
  12480. HEAP8[$105>>0] = $104;
  12481. $106 = (($$0106) + 1)|0;
  12482. $$1 = $106;
  12483. break;
  12484. }
  12485. case 7: {
  12486. $107 = (($13) + ($$0106)|0);
  12487. $108 = HEAP8[$107>>0]|0;
  12488. $109 = (($7) + ($$0104105<<2)|0);
  12489. HEAP8[$109>>0] = $108;
  12490. $110 = (($$0106) + 1)|0;
  12491. $111 = (($13) + ($110)|0);
  12492. $112 = HEAP8[$111>>0]|0;
  12493. $113 = (((($7) + ($$0104105<<2)|0)) + 1|0);
  12494. HEAP8[$113>>0] = $112;
  12495. $114 = (($$0106) + 2)|0;
  12496. $115 = (($13) + ($114)|0);
  12497. $116 = HEAP8[$115>>0]|0;
  12498. $117 = (((($7) + ($$0104105<<2)|0)) + 2|0);
  12499. HEAP8[$117>>0] = $116;
  12500. $118 = (($$0106) + 3)|0;
  12501. $119 = (($13) + ($118)|0);
  12502. $120 = HEAP8[$119>>0]|0;
  12503. $121 = (((($7) + ($$0104105<<2)|0)) + 3|0);
  12504. HEAP8[$121>>0] = $120;
  12505. $122 = (($$0106) + 4)|0;
  12506. $$1 = $122;
  12507. break;
  12508. }
  12509. case 4: {
  12510. $123 = (($13) + ($$0106)|0);
  12511. $124 = HEAP8[$123>>0]|0;
  12512. $125 = (($7) + ($$0104105<<2)|0);
  12513. HEAP8[$125>>0] = $124;
  12514. $126 = (($$0106) + 1)|0;
  12515. $127 = (($13) + ($126)|0);
  12516. $128 = HEAP8[$127>>0]|0;
  12517. $129 = (((($7) + ($$0104105<<2)|0)) + 1|0);
  12518. HEAP8[$129>>0] = $128;
  12519. $130 = (($$0106) + 2)|0;
  12520. $131 = (($13) + ($130)|0);
  12521. $132 = HEAP8[$131>>0]|0;
  12522. $133 = (((($7) + ($$0104105<<2)|0)) + 2|0);
  12523. HEAP8[$133>>0] = $132;
  12524. $134 = (((($7) + ($$0104105<<2)|0)) + 3|0);
  12525. HEAP8[$134>>0] = -1;
  12526. $135 = (($$0106) + 3)|0;
  12527. $$1 = $135;
  12528. break;
  12529. }
  12530. default: {
  12531. _TraceLog(2,6362,$vararg_buffer);
  12532. $$1 = $$0106;
  12533. }
  12534. }
  12535. $136 = (($$0104105) + 1)|0;
  12536. $137 = HEAP32[$1>>2]|0;
  12537. $138 = HEAP32[$3>>2]|0;
  12538. $139 = Math_imul($138, $137)|0;
  12539. $140 = ($136|0)<($139|0);
  12540. if ($140) {
  12541. $$0104105 = $136;$$0106 = $$1;
  12542. } else {
  12543. break;
  12544. }
  12545. }
  12546. STACKTOP = sp;return ($7|0);
  12547. }
  12548. function _ErrorCallback($0,$1) {
  12549. $0 = $0|0;
  12550. $1 = $1|0;
  12551. var $vararg_buffer = 0, $vararg_ptr1 = 0, label = 0, sp = 0;
  12552. sp = STACKTOP;
  12553. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  12554. $vararg_buffer = sp;
  12555. HEAP32[$vararg_buffer>>2] = $0;
  12556. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  12557. HEAP32[$vararg_ptr1>>2] = $1;
  12558. _TraceLog(2,10228,$vararg_buffer);
  12559. STACKTOP = sp;return;
  12560. }
  12561. function _rlGetVersion() {
  12562. var label = 0, sp = 0;
  12563. sp = STACKTOP;
  12564. return 4;
  12565. }
  12566. function _SetupFramebufferSize($0,$1) {
  12567. $0 = $0|0;
  12568. $1 = $1|0;
  12569. var $$sink = 0, $$sink1 = 0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0, $14 = 0.0, $15 = 0.0, $16 = 0, $17 = 0, $18 = 0.0, $19 = 0.0, $2 = 0, $20 = 0, $21 = 0, $22 = 0.0, $23 = 0, $24 = 0, $25 = 0, $26 = 0.0;
  12570. var $27 = 0, $28 = 0.0, $29 = 0.0, $3 = 0, $30 = 0, $31 = 0, $32 = 0.0, $33 = 0.0, $34 = 0.0, $35 = 0, $36 = 0.0, $37 = 0, $38 = 0.0, $39 = 0.0, $4 = 0, $40 = 0, $41 = 0.0, $42 = 0, $43 = 0, $44 = 0.0;
  12571. var $45 = 0, $46 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0.0, $9 = 0, $or$cond = 0, $roundf = 0.0, $roundf38 = 0.0, $roundf39 = 0.0, $roundf40 = 0.0, $vararg_buffer = 0, $vararg_buffer4 = 0, $vararg_buffer8 = 0, $vararg_ptr1 = 0, $vararg_ptr11 = 0, $vararg_ptr12 = 0, $vararg_ptr13 = 0, $vararg_ptr2 = 0;
  12572. var $vararg_ptr3 = 0, $vararg_ptr7 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  12573. sp = STACKTOP;
  12574. STACKTOP = STACKTOP + 112|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(112|0);
  12575. $vararg_buffer8 = sp + 24|0;
  12576. $vararg_buffer4 = sp + 16|0;
  12577. $vararg_buffer = sp;
  12578. $2 = sp + 40|0;
  12579. $3 = HEAP32[5343]|0;
  12580. $4 = ($3|0)>($0|0);
  12581. if (!($4)) {
  12582. $5 = HEAP32[5342]|0;
  12583. $6 = ($5|0)>($1|0);
  12584. if (!($6)) {
  12585. $30 = ($3|0)<($0|0);
  12586. $31 = ($5|0)<($1|0);
  12587. $or$cond = $30 | $31;
  12588. if (!($or$cond)) {
  12589. HEAP32[5384] = $3;
  12590. HEAP32[5385] = $5;
  12591. HEAP32[5386] = 0;
  12592. HEAP32[5387] = 0;
  12593. STACKTOP = sp;return;
  12594. }
  12595. HEAP32[$vararg_buffer8>>2] = $3;
  12596. $vararg_ptr11 = ((($vararg_buffer8)) + 4|0);
  12597. HEAP32[$vararg_ptr11>>2] = $5;
  12598. $vararg_ptr12 = ((($vararg_buffer8)) + 8|0);
  12599. HEAP32[$vararg_ptr12>>2] = $0;
  12600. $vararg_ptr13 = ((($vararg_buffer8)) + 12|0);
  12601. HEAP32[$vararg_ptr13>>2] = $1;
  12602. _TraceLog(0,10162,$vararg_buffer8);
  12603. $32 = (+($0|0));
  12604. $33 = (+($1|0));
  12605. $34 = $32 / $33;
  12606. $35 = HEAP32[5343]|0;
  12607. $36 = (+($35|0));
  12608. $37 = HEAP32[5342]|0;
  12609. $38 = (+($37|0));
  12610. $39 = $36 / $38;
  12611. $40 = !($34 <= $39);
  12612. if ($40) {
  12613. $44 = $34 * $38;
  12614. $roundf = (+_roundf((+$44)));
  12615. $45 = (~~(($roundf)));
  12616. HEAP32[5384] = $45;
  12617. HEAP32[5385] = $37;
  12618. $46 = (($45) - ($35))|0;
  12619. HEAP32[5386] = $46;
  12620. $$sink1 = 0;
  12621. } else {
  12622. HEAP32[5384] = $35;
  12623. $41 = $36 / $34;
  12624. $roundf38 = (+_roundf((+$41)));
  12625. $42 = (~~(($roundf38)));
  12626. HEAP32[5385] = $42;
  12627. HEAP32[5386] = 0;
  12628. $43 = (($42) - ($37))|0;
  12629. $$sink1 = $43;
  12630. }
  12631. HEAP32[5387] = $$sink1;
  12632. STACKTOP = sp;return;
  12633. }
  12634. }
  12635. $7 = HEAP32[5342]|0;
  12636. HEAP32[$vararg_buffer>>2] = $3;
  12637. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  12638. HEAP32[$vararg_ptr1>>2] = $7;
  12639. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  12640. HEAP32[$vararg_ptr2>>2] = $0;
  12641. $vararg_ptr3 = ((($vararg_buffer)) + 12|0);
  12642. HEAP32[$vararg_ptr3>>2] = $1;
  12643. _TraceLog(2,10019,$vararg_buffer);
  12644. $8 = (+($0|0));
  12645. $9 = HEAP32[5343]|0;
  12646. $10 = (+($9|0));
  12647. $11 = $8 / $10;
  12648. $12 = (+($1|0));
  12649. $13 = HEAP32[5342]|0;
  12650. $14 = (+($13|0));
  12651. $15 = $12 / $14;
  12652. $16 = !($11 <= $15);
  12653. if ($16) {
  12654. $22 = $10 * $15;
  12655. $roundf39 = (+_roundf((+$22)));
  12656. $23 = (~~(($roundf39)));
  12657. HEAP32[5384] = $23;
  12658. HEAP32[5385] = $1;
  12659. $24 = (($0) - ($23))|0;
  12660. HEAP32[5386] = $24;
  12661. $$sink = 0;
  12662. } else {
  12663. HEAP32[5384] = $0;
  12664. $17 = HEAP32[5342]|0;
  12665. $18 = (+($17|0));
  12666. $19 = $11 * $18;
  12667. $roundf40 = (+_roundf((+$19)));
  12668. $20 = (~~(($roundf40)));
  12669. HEAP32[5385] = $20;
  12670. HEAP32[5386] = 0;
  12671. $21 = (($1) - ($20))|0;
  12672. $$sink = $21;
  12673. }
  12674. HEAP32[5387] = $$sink;
  12675. $25 = HEAP32[5384]|0;
  12676. $26 = (+($25|0));
  12677. $27 = HEAP32[5343]|0;
  12678. $28 = (+($27|0));
  12679. $29 = $26 / $28;
  12680. _MatrixScale($2,$29,$29,$29);
  12681. dest=21460; src=$2; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  12682. HEAP32[5384] = $0;
  12683. HEAP32[5385] = $1;
  12684. HEAP32[$vararg_buffer4>>2] = $0;
  12685. $vararg_ptr7 = ((($vararg_buffer4)) + 4|0);
  12686. HEAP32[$vararg_ptr7>>2] = $1;
  12687. _TraceLog(2,10097,$vararg_buffer4);
  12688. STACKTOP = sp;return;
  12689. }
  12690. function _WindowSizeCallback($0,$1,$2) {
  12691. $0 = $0|0;
  12692. $1 = $1|0;
  12693. $2 = $2|0;
  12694. var $3 = 0.0, $4 = 0.0, label = 0, sp = 0;
  12695. sp = STACKTOP;
  12696. _rlViewport(0,0,$1,$2);
  12697. _rlMatrixMode(5889);
  12698. _rlLoadIdentity();
  12699. $3 = (+($1|0));
  12700. $4 = (+($2|0));
  12701. _rlOrtho(0.0,$3,$4,0.0,0.0,1.0);
  12702. _rlMatrixMode(5888);
  12703. _rlLoadIdentity();
  12704. _rlClearScreenBuffers();
  12705. HEAP32[5343] = $1;
  12706. HEAP32[5342] = $2;
  12707. HEAP32[5384] = $1;
  12708. HEAP32[5385] = $2;
  12709. return;
  12710. }
  12711. function _CursorEnterCallback($0,$1) {
  12712. $0 = $0|0;
  12713. $1 = $1|0;
  12714. var label = 0, sp = 0;
  12715. sp = STACKTOP;
  12716. return;
  12717. }
  12718. function _KeyCallback($0,$1,$2,$3,$4) {
  12719. $0 = $0|0;
  12720. $1 = $1|0;
  12721. $2 = $2|0;
  12722. $3 = $3|0;
  12723. $4 = $4|0;
  12724. var $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, label = 0, sp = 0;
  12725. sp = STACKTOP;
  12726. $5 = HEAP32[742]|0;
  12727. $6 = ($5|0)==($1|0);
  12728. $7 = ($3|0)==(1);
  12729. $or$cond = $7 & $6;
  12730. if ($or$cond) {
  12731. _glfwSetWindowShouldClose(($0|0),1);
  12732. return;
  12733. }
  12734. $8 = $3&255;
  12735. $9 = (24199 + ($1)|0);
  12736. HEAP8[$9>>0] = $8;
  12737. if (!($7)) {
  12738. return;
  12739. }
  12740. HEAP32[741] = $1;
  12741. return;
  12742. }
  12743. function _MouseButtonCallback($0,$1,$2,$3) {
  12744. $0 = $0|0;
  12745. $1 = $1|0;
  12746. $2 = $2|0;
  12747. $3 = $3|0;
  12748. var $$byval_copy = 0, $$sink = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0.0, $27 = 0.0;
  12749. var $28 = 0.0, $29 = 0, $30 = 0.0, $31 = 0, $32 = 0.0, $33 = 0.0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  12750. sp = STACKTOP;
  12751. STACKTOP = STACKTOP + 128|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(128|0);
  12752. $$byval_copy = sp + 64|0;
  12753. $4 = sp + 8|0;
  12754. $5 = sp;
  12755. $6 = $2&255;
  12756. $7 = (24193 + ($1)|0);
  12757. HEAP8[$7>>0] = $6;
  12758. $8 = (_IsMouseButtonPressed(0)|0);
  12759. $9 = ($8|0)==(0);
  12760. if ($9) {
  12761. $10 = (_IsMouseButtonReleased(0)|0);
  12762. $11 = ($10|0)==(0);
  12763. if (!($11)) {
  12764. $$sink = 0;
  12765. label = 3;
  12766. }
  12767. } else {
  12768. $$sink = 1;
  12769. label = 3;
  12770. }
  12771. if ((label|0) == 3) {
  12772. HEAP32[$4>>2] = $$sink;
  12773. }
  12774. $12 = ((($4)) + 8|0);
  12775. HEAP32[$12>>2] = 0;
  12776. $13 = ((($4)) + 4|0);
  12777. HEAP32[$13>>2] = 1;
  12778. $14 = ((($4)) + 24|0);
  12779. _GetMousePosition($5);
  12780. $15 = $5;
  12781. $16 = $15;
  12782. $17 = HEAP32[$16>>2]|0;
  12783. $18 = (($15) + 4)|0;
  12784. $19 = $18;
  12785. $20 = HEAP32[$19>>2]|0;
  12786. $21 = $14;
  12787. $22 = $21;
  12788. HEAP32[$22>>2] = $17;
  12789. $23 = (($21) + 4)|0;
  12790. $24 = $23;
  12791. HEAP32[$24>>2] = $20;
  12792. $25 = (_GetScreenWidth()|0);
  12793. $26 = (+($25|0));
  12794. $27 = +HEAPF32[$14>>2];
  12795. $28 = $27 / $26;
  12796. HEAPF32[$14>>2] = $28;
  12797. $29 = (_GetScreenHeight()|0);
  12798. $30 = (+($29|0));
  12799. $31 = ((($4)) + 28|0);
  12800. $32 = +HEAPF32[$31>>2];
  12801. $33 = $32 / $30;
  12802. HEAPF32[$31>>2] = $33;
  12803. dest=$$byval_copy; src=$4; stop=dest+56|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  12804. _ProcessGestureEvent($$byval_copy);
  12805. STACKTOP = sp;return;
  12806. }
  12807. function _MouseCursorPosCallback($0,$1,$2) {
  12808. $0 = $0|0;
  12809. $1 = +$1;
  12810. $2 = +$2;
  12811. var $$byval_copy = 0, $$sroa$0$0$$sroa_idx = 0, $$sroa$2$0$$sroa_idx1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0.0, $21 = 0.0, $22 = 0.0, $23 = 0, $24 = 0.0, $25 = 0.0, $26 = 0.0;
  12812. var $3 = 0, $4 = 0, $5 = 0, $6 = 0.0, $7 = 0.0, $8 = 0, $9 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  12813. sp = STACKTOP;
  12814. STACKTOP = STACKTOP + 112|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(112|0);
  12815. $$byval_copy = sp + 56|0;
  12816. $3 = sp;
  12817. HEAP32[$3>>2] = 2;
  12818. $4 = ((($3)) + 8|0);
  12819. HEAP32[$4>>2] = 0;
  12820. $5 = ((($3)) + 4|0);
  12821. HEAP32[$5>>2] = 1;
  12822. $6 = $1;
  12823. $7 = $2;
  12824. $$sroa$0$0$$sroa_idx = ((($3)) + 24|0);
  12825. HEAPF32[$$sroa$0$0$$sroa_idx>>2] = $6;
  12826. $$sroa$2$0$$sroa_idx1 = ((($3)) + 28|0);
  12827. HEAPF32[$$sroa$2$0$$sroa_idx1>>2] = $7;
  12828. $8 = ((($3)) + 24|0);
  12829. $9 = $8;
  12830. $10 = $9;
  12831. $11 = HEAP32[$10>>2]|0;
  12832. $12 = (($9) + 4)|0;
  12833. $13 = $12;
  12834. $14 = HEAP32[$13>>2]|0;
  12835. $15 = 21120;
  12836. $16 = $15;
  12837. HEAP32[$16>>2] = $11;
  12838. $17 = (($15) + 4)|0;
  12839. $18 = $17;
  12840. HEAP32[$18>>2] = $14;
  12841. $19 = (_GetScreenWidth()|0);
  12842. $20 = (+($19|0));
  12843. $21 = +HEAPF32[$8>>2];
  12844. $22 = $21 / $20;
  12845. HEAPF32[$8>>2] = $22;
  12846. $23 = (_GetScreenHeight()|0);
  12847. $24 = (+($23|0));
  12848. $25 = +HEAPF32[$$sroa$2$0$$sroa_idx1>>2];
  12849. $26 = $25 / $24;
  12850. HEAPF32[$$sroa$2$0$$sroa_idx1>>2] = $26;
  12851. dest=$$byval_copy; src=$3; stop=dest+56|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  12852. _ProcessGestureEvent($$byval_copy);
  12853. STACKTOP = sp;return;
  12854. }
  12855. function _CharCallback($0,$1) {
  12856. $0 = $0|0;
  12857. $1 = $1|0;
  12858. var label = 0, sp = 0;
  12859. sp = STACKTOP;
  12860. HEAP32[741] = $1;
  12861. return;
  12862. }
  12863. function _ScrollCallback($0,$1,$2) {
  12864. $0 = $0|0;
  12865. $1 = +$1;
  12866. $2 = +$2;
  12867. var $3 = 0, label = 0, sp = 0;
  12868. sp = STACKTOP;
  12869. $3 = (~~(($2)));
  12870. HEAP32[5757] = $3;
  12871. return;
  12872. }
  12873. function _WindowIconifyCallback($0,$1) {
  12874. $0 = $0|0;
  12875. $1 = $1|0;
  12876. var $$sink = 0, $2 = 0, label = 0, sp = 0;
  12877. sp = STACKTOP;
  12878. $2 = ($1|0)!=(0);
  12879. $$sink = $2&1;
  12880. HEAP32[5756] = $$sink;
  12881. return;
  12882. }
  12883. function _rlglInit($0,$1) {
  12884. $0 = $0|0;
  12885. $1 = $1|0;
  12886. var $$05965 = 0, $$06066 = 0, $$06167 = 0, $$062 = 0, $$sink63 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  12887. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  12888. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0;
  12889. var $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0.0, $72 = 0.0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0;
  12890. var $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $9 = 0, $exitcond = 0, $exitcond69 = 0, $exitcond70 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer10 = 0, $vararg_buffer13 = 0, $vararg_buffer15 = 0, $vararg_buffer17 = 0, $vararg_buffer19 = 0;
  12891. var $vararg_buffer21 = 0, $vararg_buffer23 = 0, $vararg_buffer25 = 0, $vararg_buffer27 = 0, $vararg_buffer29 = 0, $vararg_buffer31 = 0, $vararg_buffer34 = 0, $vararg_buffer36 = 0, $vararg_buffer39 = 0, $vararg_buffer4 = 0, $vararg_buffer41 = 0, $vararg_buffer7 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  12892. sp = STACKTOP;
  12893. STACKTOP = STACKTOP + 2464|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(2464|0);
  12894. $vararg_buffer41 = sp + 2184|0;
  12895. $vararg_buffer39 = sp + 2176|0;
  12896. $vararg_buffer36 = sp + 2168|0;
  12897. $vararg_buffer34 = sp + 2160|0;
  12898. $vararg_buffer31 = sp + 2152|0;
  12899. $vararg_buffer29 = sp + 2144|0;
  12900. $vararg_buffer27 = sp + 2136|0;
  12901. $vararg_buffer25 = sp + 2128|0;
  12902. $vararg_buffer23 = sp + 2120|0;
  12903. $vararg_buffer21 = sp + 2112|0;
  12904. $vararg_buffer19 = sp + 2104|0;
  12905. $vararg_buffer17 = sp + 2096|0;
  12906. $vararg_buffer15 = sp + 2088|0;
  12907. $vararg_buffer13 = sp + 2080|0;
  12908. $vararg_buffer10 = sp + 2072|0;
  12909. $vararg_buffer7 = sp + 24|0;
  12910. $vararg_buffer4 = sp + 16|0;
  12911. $vararg_buffer1 = sp + 8|0;
  12912. $vararg_buffer = sp;
  12913. $2 = sp + 2400|0;
  12914. $3 = sp + 2384|0;
  12915. $4 = sp + 2320|0;
  12916. $5 = sp + 2256|0;
  12917. $6 = sp + 2192|0;
  12918. $7 = (_glGetString(7936)|0);
  12919. HEAP32[$vararg_buffer>>2] = $7;
  12920. _TraceLog(0,6660,$vararg_buffer);
  12921. $8 = (_glGetString(7937)|0);
  12922. HEAP32[$vararg_buffer1>>2] = $8;
  12923. _TraceLog(0,6678,$vararg_buffer1);
  12924. $9 = (_glGetString(7938)|0);
  12925. HEAP32[$vararg_buffer4>>2] = $9;
  12926. _TraceLog(0,6696,$vararg_buffer4);
  12927. $10 = (_glGetString(35724)|0);
  12928. HEAP32[$vararg_buffer7>>2] = $10;
  12929. _TraceLog(0,6714,$vararg_buffer7);
  12930. $11 = (_glGetString(7939)|0);
  12931. $12 = (_strlen($11)|0);
  12932. $13 = (($12) + 1)|0;
  12933. $14 = (_malloc($13)|0);
  12934. _memcpy(($14|0),($11|0),($13|0))|0;
  12935. $$062 = 0;$$sink63 = $14;
  12936. while(1) {
  12937. $15 = (_strtok($$sink63,6732)|0);
  12938. $16 = (($vararg_buffer7) + ($$062<<2)|0);
  12939. HEAP32[$16>>2] = $15;
  12940. $17 = ($15|0)==(0|0);
  12941. $18 = (($$062) + 1)|0;
  12942. if ($17) {
  12943. break;
  12944. } else {
  12945. $$062 = $18;$$sink63 = 0;
  12946. }
  12947. }
  12948. _free($14);
  12949. $19 = (($$062) + -1)|0;
  12950. HEAP32[$vararg_buffer10>>2] = $19;
  12951. _TraceLog(0,6734,$vararg_buffer10);
  12952. $20 = ($$062|0)>(1);
  12953. if ($20) {
  12954. $$06167 = 0;
  12955. while(1) {
  12956. $23 = (($vararg_buffer7) + ($$06167<<2)|0);
  12957. $24 = HEAP32[$23>>2]|0;
  12958. $25 = (_strcmp($24,6769)|0);
  12959. $26 = ($25|0)==(0);
  12960. if ($26) {
  12961. HEAP32[5422] = 1;
  12962. $27 = (_eglGetProcAddress((6796|0))|0);
  12963. HEAP32[5423] = $27;
  12964. $28 = (_eglGetProcAddress((6817|0))|0);
  12965. HEAP32[5424] = $28;
  12966. $29 = (_eglGetProcAddress((6838|0))|0);
  12967. HEAP32[5425] = $29;
  12968. }
  12969. $30 = (_strcmp($24,6862)|0);
  12970. $31 = ($30|0)==(0);
  12971. if ($31) {
  12972. HEAP32[5364] = 1;
  12973. }
  12974. $32 = (_strcmp($24,6882)|0);
  12975. $33 = ($32|0)==(0);
  12976. if ($33) {
  12977. label = 12;
  12978. } else {
  12979. $34 = HEAP32[$23>>2]|0;
  12980. $35 = (_strcmp($34,6914)|0);
  12981. $36 = ($35|0)==(0);
  12982. if ($36) {
  12983. label = 12;
  12984. } else {
  12985. $37 = (_strcmp($34,6947)|0);
  12986. $38 = ($37|0)==(0);
  12987. if ($38) {
  12988. label = 12;
  12989. }
  12990. }
  12991. }
  12992. if ((label|0) == 12) {
  12993. label = 0;
  12994. HEAP32[5359] = 1;
  12995. }
  12996. $39 = (_strcmp($24,6987)|0);
  12997. $40 = ($39|0)==(0);
  12998. if ($40) {
  12999. label = 15;
  13000. } else {
  13001. $41 = HEAP32[$23>>2]|0;
  13002. $42 = (_strcmp($41,7023)|0);
  13003. $43 = ($42|0)==(0);
  13004. if ($43) {
  13005. label = 15;
  13006. }
  13007. }
  13008. if ((label|0) == 15) {
  13009. label = 0;
  13010. HEAP32[5360] = 1;
  13011. }
  13012. $44 = HEAP32[$23>>2]|0;
  13013. $45 = (_strcmp($44,7056)|0);
  13014. $46 = ($45|0)==(0);
  13015. if ($46) {
  13016. HEAP32[5361] = 1;
  13017. }
  13018. $47 = (_strcmp($44,7081)|0);
  13019. $48 = ($47|0)==(0);
  13020. if ($48) {
  13021. HEAP32[5362] = 1;
  13022. }
  13023. $49 = (_strcmp($44,7114)|0);
  13024. $50 = ($49|0)==(0);
  13025. if ($50) {
  13026. HEAP32[5363] = 1;
  13027. }
  13028. $51 = (_strcmp($44,7150)|0);
  13029. $52 = ($51|0)==(0);
  13030. if ($52) {
  13031. HEAP32[5426] = 1;
  13032. _glGetFloatv(34047,(21708|0));
  13033. }
  13034. $53 = HEAP32[$23>>2]|0;
  13035. $54 = (_strcmp($53,7184)|0);
  13036. $55 = ($54|0)==(0);
  13037. if ($55) {
  13038. HEAP32[5428] = 1;
  13039. }
  13040. $56 = (($$06167) + 1)|0;
  13041. $exitcond70 = ($56|0)==($19|0);
  13042. if ($exitcond70) {
  13043. break;
  13044. } else {
  13045. $$06167 = $56;
  13046. }
  13047. }
  13048. }
  13049. $21 = HEAP32[5422]|0;
  13050. $22 = ($21|0)==(0);
  13051. if ($22) {
  13052. _TraceLog(2,7287,$vararg_buffer15);
  13053. } else {
  13054. _TraceLog(0,7212,$vararg_buffer13);
  13055. }
  13056. $57 = HEAP32[5364]|0;
  13057. $58 = ($57|0)==(0);
  13058. if ($58) {
  13059. _TraceLog(2,7423,$vararg_buffer19);
  13060. } else {
  13061. _TraceLog(0,7348,$vararg_buffer17);
  13062. }
  13063. $59 = HEAP32[5359]|0;
  13064. $60 = ($59|0)==(0);
  13065. if (!($60)) {
  13066. _TraceLog(0,7515,$vararg_buffer21);
  13067. }
  13068. $61 = HEAP32[5360]|0;
  13069. $62 = ($61|0)==(0);
  13070. if (!($62)) {
  13071. _TraceLog(0,7561,$vararg_buffer23);
  13072. }
  13073. $63 = HEAP32[5361]|0;
  13074. $64 = ($63|0)==(0);
  13075. if (!($64)) {
  13076. _TraceLog(0,7608,$vararg_buffer25);
  13077. }
  13078. $65 = HEAP32[5362]|0;
  13079. $66 = ($65|0)==(0);
  13080. if (!($66)) {
  13081. _TraceLog(0,7659,$vararg_buffer27);
  13082. }
  13083. $67 = HEAP32[5363]|0;
  13084. $68 = ($67|0)==(0);
  13085. if (!($68)) {
  13086. _TraceLog(0,7706,$vararg_buffer29);
  13087. }
  13088. $69 = HEAP32[5426]|0;
  13089. $70 = ($69|0)==(0);
  13090. if (!($70)) {
  13091. $71 = +HEAPF32[5427];
  13092. $72 = $71;
  13093. HEAPF64[$vararg_buffer31>>3] = $72;
  13094. _TraceLog(0,7753,$vararg_buffer31);
  13095. }
  13096. $73 = HEAP32[5428]|0;
  13097. $74 = ($73|0)==(0);
  13098. if (!($74)) {
  13099. _TraceLog(0,7819,$vararg_buffer34);
  13100. }
  13101. HEAP32[$vararg_buffer10>>2] = -1;
  13102. $75 = (_rlglLoadTexture($vararg_buffer10,1,1,7,1)|0);
  13103. HEAP32[5429] = $75;
  13104. $76 = ($75|0)==(0);
  13105. if ($76) {
  13106. _TraceLog(2,7923,$vararg_buffer39);
  13107. } else {
  13108. HEAP32[$vararg_buffer36>>2] = $75;
  13109. _TraceLog(0,7872,$vararg_buffer36);
  13110. }
  13111. _LoadDefaultShader($2);
  13112. dest=21720; src=$2; stop=dest+56|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13113. dest=21776; src=$2; stop=dest+56|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13114. _LoadDefaultBuffers();
  13115. $77 = (_malloc(49152)|0);
  13116. HEAP32[5458] = $77;
  13117. $$06066 = 0;
  13118. while(1) {
  13119. $79 = HEAP32[5458]|0;
  13120. $80 = (($79) + (($$06066*12)|0)|0);
  13121. _VectorZero($3);
  13122. ;HEAP32[$80>>2]=HEAP32[$3>>2]|0;HEAP32[$80+4>>2]=HEAP32[$3+4>>2]|0;HEAP32[$80+8>>2]=HEAP32[$3+8>>2]|0;
  13123. $81 = (($$06066) + 1)|0;
  13124. $exitcond69 = ($81|0)==(4096);
  13125. if ($exitcond69) {
  13126. break;
  13127. } else {
  13128. $$06066 = $81;
  13129. }
  13130. }
  13131. $78 = (_malloc(36864)|0);
  13132. HEAP32[5459] = $78;
  13133. $$05965 = 0;
  13134. while(1) {
  13135. $82 = (((($78) + (($$05965*144)|0)|0)) + 8|0);
  13136. HEAP32[$82>>2] = 0;
  13137. $83 = (($78) + (($$05965*144)|0)|0);
  13138. HEAP32[$83>>2] = 0;
  13139. $84 = (($$05965) + 1)|0;
  13140. $exitcond = ($84|0)==(256);
  13141. if ($exitcond) {
  13142. break;
  13143. } else {
  13144. $$05965 = $84;
  13145. }
  13146. }
  13147. HEAP32[5460] = 1;
  13148. $85 = HEAP32[5429]|0;
  13149. $86 = ((($78)) + 8|0);
  13150. HEAP32[$86>>2] = $85;
  13151. HEAP32[5461] = 4;
  13152. _MatrixIdentity($4);
  13153. dest=21848; src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13154. _MatrixIdentity($4);
  13155. dest=(21912); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13156. _MatrixIdentity($4);
  13157. dest=(21976); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13158. _MatrixIdentity($4);
  13159. dest=(22040); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13160. _MatrixIdentity($4);
  13161. dest=(22104); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13162. _MatrixIdentity($4);
  13163. dest=(22168); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13164. _MatrixIdentity($4);
  13165. dest=(22232); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13166. _MatrixIdentity($4);
  13167. dest=(22296); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13168. _MatrixIdentity($4);
  13169. dest=(22360); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13170. _MatrixIdentity($4);
  13171. dest=(22424); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13172. _MatrixIdentity($4);
  13173. dest=(22488); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13174. _MatrixIdentity($4);
  13175. dest=(22552); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13176. _MatrixIdentity($4);
  13177. dest=(22616); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13178. _MatrixIdentity($4);
  13179. dest=(22680); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13180. _MatrixIdentity($4);
  13181. dest=(22744); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13182. _MatrixIdentity($4);
  13183. dest=(22808); src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13184. _MatrixIdentity($5);
  13185. dest=21556; src=$5; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13186. _MatrixIdentity($6);
  13187. dest=21620; src=$6; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13188. HEAP32[5388] = 21620;
  13189. _glDepthFunc(515);
  13190. _glDisable(2929);
  13191. _glBlendFunc(770,771);
  13192. _glEnable(3042);
  13193. _glCullFace(1029);
  13194. _glFrontFace(2305);
  13195. _glEnable(2884);
  13196. _glClearColor(0.0,0.0,0.0,1.0);
  13197. _glClearDepthf(1.0);
  13198. _glClear(16640);
  13199. HEAP32[5718] = $0;
  13200. HEAP32[5719] = $1;
  13201. _TraceLog(0,7962,$vararg_buffer41);
  13202. STACKTOP = sp;return;
  13203. }
  13204. function _SetupViewport() {
  13205. var $0 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, label = 0, sp = 0;
  13206. sp = STACKTOP;
  13207. $0 = HEAP32[5386]|0;
  13208. $1 = (($0|0) / 2)&-1;
  13209. $2 = HEAP32[5387]|0;
  13210. $3 = (($2|0) / 2)&-1;
  13211. $4 = HEAP32[5384]|0;
  13212. $5 = (($4) - ($0))|0;
  13213. $6 = HEAP32[5385]|0;
  13214. $7 = (($6) - ($2))|0;
  13215. _rlViewport($1,$3,$5,$7);
  13216. return;
  13217. }
  13218. function _rlMatrixMode($0) {
  13219. $0 = $0|0;
  13220. var $modelview$sink = 0, label = 0, sp = 0;
  13221. sp = STACKTOP;
  13222. switch ($0|0) {
  13223. case 5889: {
  13224. $modelview$sink = 21556;
  13225. label = 3;
  13226. break;
  13227. }
  13228. case 5888: {
  13229. $modelview$sink = 21620;
  13230. label = 3;
  13231. break;
  13232. }
  13233. default: {
  13234. }
  13235. }
  13236. if ((label|0) == 3) {
  13237. HEAP32[5388] = $modelview$sink;
  13238. }
  13239. HEAP32[5421] = $0;
  13240. return;
  13241. }
  13242. function _rlLoadIdentity() {
  13243. var $0 = 0, $1 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  13244. sp = STACKTOP;
  13245. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  13246. $0 = sp;
  13247. $1 = HEAP32[5388]|0;
  13248. _MatrixIdentity($0);
  13249. dest=$1; src=$0; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13250. STACKTOP = sp;return;
  13251. }
  13252. function _rlOrtho($0,$1,$2,$3,$4,$5) {
  13253. $0 = +$0;
  13254. $1 = +$1;
  13255. $2 = +$2;
  13256. $3 = +$3;
  13257. $4 = +$4;
  13258. $5 = +$5;
  13259. var $$byval_copy = 0, $$byval_copy1 = 0, $6 = 0, $7 = 0, $8 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  13260. sp = STACKTOP;
  13261. STACKTOP = STACKTOP + 256|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(256|0);
  13262. $$byval_copy1 = sp + 192|0;
  13263. $$byval_copy = sp + 128|0;
  13264. $6 = sp + 64|0;
  13265. $7 = sp;
  13266. _MatrixOrtho($6,$0,$1,$2,$3,$4,$5);
  13267. _MatrixTranspose($6);
  13268. $8 = HEAP32[5388]|0;
  13269. dest=$$byval_copy; src=$8; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13270. dest=$$byval_copy1; src=$6; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13271. _MatrixMultiply($7,$$byval_copy,$$byval_copy1);
  13272. dest=$8; src=$7; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13273. STACKTOP = sp;return;
  13274. }
  13275. function _ClearBackground($0) {
  13276. $0 = $0|0;
  13277. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, label = 0, sp = 0;
  13278. sp = STACKTOP;
  13279. $1 = HEAP8[$0>>0]|0;
  13280. $2 = ((($0)) + 1|0);
  13281. $3 = HEAP8[$2>>0]|0;
  13282. $4 = ((($0)) + 2|0);
  13283. $5 = HEAP8[$4>>0]|0;
  13284. $6 = ((($0)) + 3|0);
  13285. $7 = HEAP8[$6>>0]|0;
  13286. _rlClearColor($1,$3,$5,$7);
  13287. return;
  13288. }
  13289. function _rlClearColor($0,$1,$2,$3) {
  13290. $0 = $0|0;
  13291. $1 = $1|0;
  13292. $2 = $2|0;
  13293. $3 = $3|0;
  13294. var $10 = 0.0, $11 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0.0, $9 = 0.0, label = 0, sp = 0;
  13295. sp = STACKTOP;
  13296. $4 = (+($0&255));
  13297. $5 = $4 / 255.0;
  13298. $6 = (+($1&255));
  13299. $7 = $6 / 255.0;
  13300. $8 = (+($2&255));
  13301. $9 = $8 / 255.0;
  13302. $10 = (+($3&255));
  13303. $11 = $10 / 255.0;
  13304. _glClearColor((+$5),(+$7),(+$9),(+$11));
  13305. return;
  13306. }
  13307. function _rlViewport($0,$1,$2,$3) {
  13308. $0 = $0|0;
  13309. $1 = $1|0;
  13310. $2 = $2|0;
  13311. $3 = $3|0;
  13312. var label = 0, sp = 0;
  13313. sp = STACKTOP;
  13314. _glViewport(($0|0),($1|0),($2|0),($3|0));
  13315. return;
  13316. }
  13317. function _LoadDefaultShader($0) {
  13318. $0 = $0|0;
  13319. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  13320. sp = STACKTOP;
  13321. STACKTOP = STACKTOP + 1008|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(1008|0);
  13322. $vararg_buffer1 = sp + 8|0;
  13323. $vararg_buffer = sp;
  13324. $1 = sp + 16|0;
  13325. $2 = sp + 513|0;
  13326. $3 = sp + 72|0;
  13327. _memcpy(($2|0),(8538|0),489)|0;
  13328. _memcpy(($3|0),(9027|0),441)|0;
  13329. $4 = (_LoadShaderProgram($2,$3)|0);
  13330. HEAP32[$1>>2] = $4;
  13331. $5 = ($4|0)==(0);
  13332. if ($5) {
  13333. HEAP32[$vararg_buffer1>>2] = $4;
  13334. _TraceLog(2,9516,$vararg_buffer1);
  13335. } else {
  13336. HEAP32[$vararg_buffer>>2] = $4;
  13337. _TraceLog(0,9468,$vararg_buffer);
  13338. }
  13339. $6 = HEAP32[$1>>2]|0;
  13340. $7 = ($6|0)==(0);
  13341. if (!($7)) {
  13342. _LoadDefaultShaderLocations($1);
  13343. }
  13344. dest=$0; src=$1; stop=dest+56|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13345. STACKTOP = sp;return;
  13346. }
  13347. function _LoadDefaultBuffers() {
  13348. var $$05365 = 0, $$05467 = 0, $$05770 = 0, $$05972 = 0, $$066 = 0, $0 = 0, $1 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0;
  13349. var $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0;
  13350. var $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0;
  13351. var $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0;
  13352. var $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0;
  13353. var $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $exitcond = 0, $exitcond75 = 0, $exitcond78 = 0, $exitcond80 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer10 = 0, $vararg_buffer14 = 0, $vararg_buffer17 = 0;
  13354. var $vararg_buffer3 = 0, $vararg_buffer7 = 0, $vararg_ptr13 = 0, $vararg_ptr20 = 0, $vararg_ptr21 = 0, $vararg_ptr22 = 0, $vararg_ptr6 = 0, label = 0, sp = 0;
  13355. sp = STACKTOP;
  13356. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  13357. $vararg_buffer17 = sp + 48|0;
  13358. $vararg_buffer14 = sp + 40|0;
  13359. $vararg_buffer10 = sp + 32|0;
  13360. $vararg_buffer7 = sp + 24|0;
  13361. $vararg_buffer3 = sp + 16|0;
  13362. $vararg_buffer1 = sp + 8|0;
  13363. $vararg_buffer = sp;
  13364. $0 = (_malloc(24576)|0);
  13365. HEAP32[(22892)>>2] = $0;
  13366. $1 = (_malloc(8192)|0);
  13367. HEAP32[(22900)>>2] = $1;
  13368. HEAP32[(22896)>>2] = 0;
  13369. HEAP32[(22904)>>2] = 0;
  13370. _memset(($0|0),0,24576)|0;
  13371. $$05972 = 0;
  13372. while(1) {
  13373. $2 = HEAP32[(22900)>>2]|0;
  13374. $3 = (($2) + ($$05972)|0);
  13375. HEAP8[$3>>0] = 0;
  13376. $4 = (($$05972) + 1)|0;
  13377. $exitcond80 = ($4|0)==(8192);
  13378. if ($exitcond80) {
  13379. break;
  13380. } else {
  13381. $$05972 = $4;
  13382. }
  13383. }
  13384. HEAP32[5720] = 0;
  13385. HEAP32[(22888)>>2] = 0;
  13386. HEAP32[(22884)>>2] = 0;
  13387. $5 = (_malloc(73728)|0);
  13388. HEAP32[(22940)>>2] = $5;
  13389. $6 = (_malloc(24576)|0);
  13390. HEAP32[(22948)>>2] = $6;
  13391. HEAP32[(22944)>>2] = 0;
  13392. HEAP32[(22952)>>2] = 0;
  13393. _memset(($5|0),0,73728)|0;
  13394. $$05770 = 0;
  13395. while(1) {
  13396. $7 = HEAP32[(22948)>>2]|0;
  13397. $8 = (($7) + ($$05770)|0);
  13398. HEAP8[$8>>0] = 0;
  13399. $9 = (($$05770) + 1)|0;
  13400. $exitcond78 = ($9|0)==(24576);
  13401. if ($exitcond78) {
  13402. break;
  13403. } else {
  13404. $$05770 = $9;
  13405. }
  13406. }
  13407. HEAP32[5732] = 0;
  13408. HEAP32[(22936)>>2] = 0;
  13409. HEAP32[(22932)>>2] = 0;
  13410. $10 = (_malloc(49152)|0);
  13411. HEAP32[(22988)>>2] = $10;
  13412. $11 = (_malloc(32768)|0);
  13413. HEAP32[(22992)>>2] = $11;
  13414. $12 = (_malloc(16384)|0);
  13415. HEAP32[(22996)>>2] = $12;
  13416. $13 = (_malloc(12288)|0);
  13417. HEAP32[(23000)>>2] = $13;
  13418. $14 = HEAP32[(22988)>>2]|0;
  13419. _memset(($14|0),0,49152)|0;
  13420. $15 = HEAP32[(22992)>>2]|0;
  13421. _memset(($15|0),0,32768)|0;
  13422. $$05467 = 0;
  13423. while(1) {
  13424. $17 = HEAP32[(22996)>>2]|0;
  13425. $18 = (($17) + ($$05467)|0);
  13426. HEAP8[$18>>0] = 0;
  13427. $19 = (($$05467) + 1)|0;
  13428. $exitcond75 = ($19|0)==(16384);
  13429. if ($exitcond75) {
  13430. break;
  13431. } else {
  13432. $$05467 = $19;
  13433. }
  13434. }
  13435. $16 = HEAP32[(23000)>>2]|0;
  13436. $$05365 = 0;$$066 = 0;
  13437. while(1) {
  13438. $22 = $$05365 << 2;
  13439. $23 = $22&65535;
  13440. $24 = (($16) + ($$066<<1)|0);
  13441. HEAP16[$24>>1] = $23;
  13442. $25 = $22 | 1;
  13443. $26 = $25&65535;
  13444. $27 = $$066 | 1;
  13445. $28 = (($16) + ($27<<1)|0);
  13446. HEAP16[$28>>1] = $26;
  13447. $29 = $22 | 2;
  13448. $30 = $29&65535;
  13449. $31 = (($$066) + 2)|0;
  13450. $32 = (($16) + ($31<<1)|0);
  13451. HEAP16[$32>>1] = $30;
  13452. $33 = (($$066) + 3)|0;
  13453. $34 = (($16) + ($33<<1)|0);
  13454. HEAP16[$34>>1] = $23;
  13455. $35 = (($$066) + 4)|0;
  13456. $36 = (($16) + ($35<<1)|0);
  13457. HEAP16[$36>>1] = $30;
  13458. $37 = $22 | 3;
  13459. $38 = $37&65535;
  13460. $39 = (($$066) + 5)|0;
  13461. $40 = (($16) + ($39<<1)|0);
  13462. HEAP16[$40>>1] = $38;
  13463. $41 = (($$05365) + 1)|0;
  13464. $42 = (($$066) + 6)|0;
  13465. $exitcond = ($41|0)==(1024);
  13466. if ($exitcond) {
  13467. break;
  13468. } else {
  13469. $$05365 = $41;$$066 = $42;
  13470. }
  13471. }
  13472. HEAP32[5744] = 0;
  13473. HEAP32[(22980)>>2] = 0;
  13474. HEAP32[(22984)>>2] = 0;
  13475. _TraceLog(0,8009,$vararg_buffer);
  13476. $20 = HEAP32[5422]|0;
  13477. $21 = ($20|0)==(0);
  13478. if (!($21)) {
  13479. $43 = HEAP32[5423]|0;
  13480. FUNCTION_TABLE_vii[$43 & 63](1,(22908));
  13481. $44 = HEAP32[5424]|0;
  13482. $45 = HEAP32[(22908)>>2]|0;
  13483. FUNCTION_TABLE_vi[$44 & 31]($45);
  13484. }
  13485. _glGenBuffers(2,((22912)|0));
  13486. $46 = HEAP32[(22912)>>2]|0;
  13487. _glBindBuffer(34962,($46|0));
  13488. $47 = HEAP32[(22892)>>2]|0;
  13489. _glBufferData(34962,24576,($47|0),35048);
  13490. $48 = HEAP32[(21780)>>2]|0;
  13491. _glEnableVertexAttribArray(($48|0));
  13492. $49 = HEAP32[(21780)>>2]|0;
  13493. _glVertexAttribPointer(($49|0),3,5126,0,0,(0|0));
  13494. _glGenBuffers(2,((22916)|0));
  13495. $50 = HEAP32[(22916)>>2]|0;
  13496. _glBindBuffer(34962,($50|0));
  13497. $51 = HEAP32[(22900)>>2]|0;
  13498. _glBufferData(34962,8192,($51|0),35048);
  13499. $52 = HEAP32[(21800)>>2]|0;
  13500. _glEnableVertexAttribArray(($52|0));
  13501. $53 = HEAP32[(21800)>>2]|0;
  13502. _glVertexAttribPointer(($53|0),4,5121,1,0,(0|0));
  13503. $54 = HEAP32[5422]|0;
  13504. $55 = ($54|0)==(0);
  13505. if ($55) {
  13506. $57 = HEAP32[(22912)>>2]|0;
  13507. $58 = HEAP32[(22916)>>2]|0;
  13508. HEAP32[$vararg_buffer3>>2] = $57;
  13509. $vararg_ptr6 = ((($vararg_buffer3)) + 4|0);
  13510. HEAP32[$vararg_ptr6>>2] = $58;
  13511. _TraceLog(0,8147,$vararg_buffer3);
  13512. } else {
  13513. $56 = HEAP32[(22908)>>2]|0;
  13514. HEAP32[$vararg_buffer1>>2] = $56;
  13515. _TraceLog(0,8082,$vararg_buffer1);
  13516. }
  13517. $59 = HEAP32[5422]|0;
  13518. $60 = ($59|0)==(0);
  13519. if (!($60)) {
  13520. $61 = HEAP32[5423]|0;
  13521. FUNCTION_TABLE_vii[$61 & 63](1,(22956));
  13522. $62 = HEAP32[5424]|0;
  13523. $63 = HEAP32[(22956)>>2]|0;
  13524. FUNCTION_TABLE_vi[$62 & 31]($63);
  13525. }
  13526. _glGenBuffers(1,((22960)|0));
  13527. $64 = HEAP32[(22960)>>2]|0;
  13528. _glBindBuffer(34962,($64|0));
  13529. $65 = HEAP32[(22940)>>2]|0;
  13530. _glBufferData(34962,73728,($65|0),35048);
  13531. $66 = HEAP32[(21780)>>2]|0;
  13532. _glEnableVertexAttribArray(($66|0));
  13533. $67 = HEAP32[(21780)>>2]|0;
  13534. _glVertexAttribPointer(($67|0),3,5126,0,0,(0|0));
  13535. _glGenBuffers(1,((22964)|0));
  13536. $68 = HEAP32[(22964)>>2]|0;
  13537. _glBindBuffer(34962,($68|0));
  13538. $69 = HEAP32[(22948)>>2]|0;
  13539. _glBufferData(34962,24576,($69|0),35048);
  13540. $70 = HEAP32[(21800)>>2]|0;
  13541. _glEnableVertexAttribArray(($70|0));
  13542. $71 = HEAP32[(21800)>>2]|0;
  13543. _glVertexAttribPointer(($71|0),4,5121,1,0,(0|0));
  13544. $72 = HEAP32[5422]|0;
  13545. $73 = ($72|0)==(0);
  13546. if ($73) {
  13547. $75 = HEAP32[(22960)>>2]|0;
  13548. $76 = HEAP32[(22964)>>2]|0;
  13549. HEAP32[$vararg_buffer10>>2] = $75;
  13550. $vararg_ptr13 = ((($vararg_buffer10)) + 4|0);
  13551. HEAP32[$vararg_ptr13>>2] = $76;
  13552. _TraceLog(0,8293,$vararg_buffer10);
  13553. } else {
  13554. $74 = HEAP32[(22956)>>2]|0;
  13555. HEAP32[$vararg_buffer7>>2] = $74;
  13556. _TraceLog(0,8224,$vararg_buffer7);
  13557. }
  13558. $77 = HEAP32[5422]|0;
  13559. $78 = ($77|0)==(0);
  13560. if (!($78)) {
  13561. $79 = HEAP32[5423]|0;
  13562. FUNCTION_TABLE_vii[$79 & 63](1,(23004));
  13563. $80 = HEAP32[5424]|0;
  13564. $81 = HEAP32[(23004)>>2]|0;
  13565. FUNCTION_TABLE_vi[$80 & 31]($81);
  13566. }
  13567. _glGenBuffers(1,((23008)|0));
  13568. $82 = HEAP32[(23008)>>2]|0;
  13569. _glBindBuffer(34962,($82|0));
  13570. $83 = HEAP32[(22988)>>2]|0;
  13571. _glBufferData(34962,49152,($83|0),35048);
  13572. $84 = HEAP32[(21780)>>2]|0;
  13573. _glEnableVertexAttribArray(($84|0));
  13574. $85 = HEAP32[(21780)>>2]|0;
  13575. _glVertexAttribPointer(($85|0),3,5126,0,0,(0|0));
  13576. _glGenBuffers(1,((23012)|0));
  13577. $86 = HEAP32[(23012)>>2]|0;
  13578. _glBindBuffer(34962,($86|0));
  13579. $87 = HEAP32[(22992)>>2]|0;
  13580. _glBufferData(34962,32768,($87|0),35048);
  13581. $88 = HEAP32[(21784)>>2]|0;
  13582. _glEnableVertexAttribArray(($88|0));
  13583. $89 = HEAP32[(21784)>>2]|0;
  13584. _glVertexAttribPointer(($89|0),2,5126,0,0,(0|0));
  13585. _glGenBuffers(1,((23016)|0));
  13586. $90 = HEAP32[(23016)>>2]|0;
  13587. _glBindBuffer(34962,($90|0));
  13588. $91 = HEAP32[(22996)>>2]|0;
  13589. _glBufferData(34962,16384,($91|0),35048);
  13590. $92 = HEAP32[(21800)>>2]|0;
  13591. _glEnableVertexAttribArray(($92|0));
  13592. $93 = HEAP32[(21800)>>2]|0;
  13593. _glVertexAttribPointer(($93|0),4,5121,1,0,(0|0));
  13594. _glGenBuffers(1,((23020)|0));
  13595. $94 = HEAP32[(23020)>>2]|0;
  13596. _glBindBuffer(34963,($94|0));
  13597. $95 = HEAP32[(23000)>>2]|0;
  13598. _glBufferData(34963,12288,($95|0),35044);
  13599. $96 = HEAP32[5422]|0;
  13600. $97 = ($96|0)==(0);
  13601. if ($97) {
  13602. $99 = HEAP32[(23008)>>2]|0;
  13603. $100 = HEAP32[(23012)>>2]|0;
  13604. $101 = HEAP32[(23016)>>2]|0;
  13605. $102 = HEAP32[(23020)>>2]|0;
  13606. HEAP32[$vararg_buffer17>>2] = $99;
  13607. $vararg_ptr20 = ((($vararg_buffer17)) + 4|0);
  13608. HEAP32[$vararg_ptr20>>2] = $100;
  13609. $vararg_ptr21 = ((($vararg_buffer17)) + 8|0);
  13610. HEAP32[$vararg_ptr21>>2] = $101;
  13611. $vararg_ptr22 = ((($vararg_buffer17)) + 12|0);
  13612. HEAP32[$vararg_ptr22>>2] = $102;
  13613. _TraceLog(0,8439,$vararg_buffer17);
  13614. } else {
  13615. $98 = HEAP32[(23004)>>2]|0;
  13616. HEAP32[$vararg_buffer14>>2] = $98;
  13617. _TraceLog(0,8374,$vararg_buffer14);
  13618. }
  13619. $103 = HEAP32[5422]|0;
  13620. $104 = ($103|0)==(0);
  13621. if ($104) {
  13622. STACKTOP = sp;return;
  13623. }
  13624. $105 = HEAP32[5424]|0;
  13625. FUNCTION_TABLE_vi[$105 & 31](0);
  13626. STACKTOP = sp;return;
  13627. }
  13628. function _LoadShaderProgram($0,$1) {
  13629. $0 = $0|0;
  13630. $1 = $1|0;
  13631. var $$0 = 0, $$alloca_mul = 0, $$alloca_mul34 = 0, $$alloca_mul36 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0;
  13632. var $25 = 0, $26 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer10 = 0, $vararg_buffer13 = 0, $vararg_buffer16 = 0, $vararg_buffer19 = 0, $vararg_buffer22 = 0, $vararg_buffer4 = 0, $vararg_buffer7 = 0, label = 0, sp = 0;
  13633. sp = STACKTOP;
  13634. STACKTOP = STACKTOP + 96|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(96|0);
  13635. $vararg_buffer22 = sp + 64|0;
  13636. $vararg_buffer19 = sp + 56|0;
  13637. $vararg_buffer16 = sp + 48|0;
  13638. $vararg_buffer13 = sp + 40|0;
  13639. $vararg_buffer10 = sp + 32|0;
  13640. $vararg_buffer7 = sp + 24|0;
  13641. $vararg_buffer4 = sp + 16|0;
  13642. $vararg_buffer1 = sp + 8|0;
  13643. $vararg_buffer = sp;
  13644. $2 = sp + 80|0;
  13645. $3 = sp + 76|0;
  13646. $4 = sp + 72|0;
  13647. $5 = sp + 68|0;
  13648. $6 = (_glCreateShader(35633)|0);
  13649. $7 = (_glCreateShader(35632)|0);
  13650. HEAP32[$2>>2] = $0;
  13651. HEAP32[$3>>2] = $1;
  13652. _glShaderSource(($6|0),1,($2|0),(0|0));
  13653. _glShaderSource(($7|0),1,($3|0),(0|0));
  13654. HEAP32[$4>>2] = 0;
  13655. _glCompileShader(($6|0));
  13656. _glGetShaderiv(($6|0),35713,($4|0));
  13657. $8 = HEAP32[$4>>2]|0;
  13658. $9 = ($8|0)==(1);
  13659. if ($9) {
  13660. HEAP32[$vararg_buffer4>>2] = $6;
  13661. _TraceLog(0,9772,$vararg_buffer4);
  13662. } else {
  13663. HEAP32[$vararg_buffer>>2] = $6;
  13664. _TraceLog(2,9720,$vararg_buffer);
  13665. HEAP32[$vararg_buffer>>2] = 0;
  13666. _glGetShaderiv(($6|0),35716,($vararg_buffer|0));
  13667. $10 = HEAP32[$vararg_buffer>>2]|0;
  13668. $11 = (_llvm_stacksave()|0);
  13669. $$alloca_mul = $10;
  13670. $12 = STACKTOP; STACKTOP = STACKTOP + ((((1*$$alloca_mul)|0)+15)&-16)|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(((((1*$$alloca_mul)|0)+15)&-16)|0);;
  13671. $13 = HEAP32[$vararg_buffer>>2]|0;
  13672. _glGetShaderInfoLog(($6|0),($13|0),($5|0),($12|0));
  13673. HEAP32[$vararg_buffer1>>2] = $12;
  13674. _TraceLog(0,9769,$vararg_buffer1);
  13675. _llvm_stackrestore(($11|0));
  13676. }
  13677. _glCompileShader(($7|0));
  13678. _glGetShaderiv(($7|0),35713,($4|0));
  13679. $14 = HEAP32[$4>>2]|0;
  13680. $15 = ($14|0)==(1);
  13681. if ($15) {
  13682. HEAP32[$vararg_buffer13>>2] = $7;
  13683. _TraceLog(0,9873,$vararg_buffer13);
  13684. } else {
  13685. HEAP32[$vararg_buffer7>>2] = $7;
  13686. _TraceLog(2,9822,$vararg_buffer7);
  13687. HEAP32[$vararg_buffer7>>2] = 0;
  13688. _glGetShaderiv(($7|0),35716,($vararg_buffer7|0));
  13689. $16 = HEAP32[$vararg_buffer7>>2]|0;
  13690. $17 = (_llvm_stacksave()|0);
  13691. $$alloca_mul34 = $16;
  13692. $18 = STACKTOP; STACKTOP = STACKTOP + ((((1*$$alloca_mul34)|0)+15)&-16)|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(((((1*$$alloca_mul34)|0)+15)&-16)|0);;
  13693. $19 = HEAP32[$vararg_buffer7>>2]|0;
  13694. _glGetShaderInfoLog(($7|0),($19|0),($5|0),($18|0));
  13695. HEAP32[$vararg_buffer10>>2] = $18;
  13696. _TraceLog(0,9769,$vararg_buffer10);
  13697. _llvm_stackrestore(($17|0));
  13698. }
  13699. $20 = (_glCreateProgram()|0);
  13700. _glAttachShader(($20|0),($6|0));
  13701. _glAttachShader(($20|0),($7|0));
  13702. _glBindAttribLocation(($20|0),0,(9564|0));
  13703. _glBindAttribLocation(($20|0),1,(9579|0));
  13704. _glBindAttribLocation(($20|0),2,(9610|0));
  13705. _glBindAttribLocation(($20|0),3,(9637|0));
  13706. _glBindAttribLocation(($20|0),4,(9623|0));
  13707. _glBindAttribLocation(($20|0),5,(9594|0));
  13708. _glLinkProgram(($20|0));
  13709. _glGetProgramiv(($20|0),35714,($4|0));
  13710. $21 = HEAP32[$4>>2]|0;
  13711. $22 = ($21|0)==(0);
  13712. if ($22) {
  13713. HEAP32[$vararg_buffer16>>2] = $20;
  13714. _TraceLog(2,9925,$vararg_buffer16);
  13715. HEAP32[$vararg_buffer16>>2] = 0;
  13716. _glGetProgramiv(($20|0),35716,($vararg_buffer16|0));
  13717. $23 = HEAP32[$vararg_buffer16>>2]|0;
  13718. $24 = (_llvm_stacksave()|0);
  13719. $$alloca_mul36 = $23;
  13720. $25 = STACKTOP; STACKTOP = STACKTOP + ((((1*$$alloca_mul36)|0)+15)&-16)|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(((((1*$$alloca_mul36)|0)+15)&-16)|0);;
  13721. $26 = HEAP32[$vararg_buffer16>>2]|0;
  13722. _glGetProgramInfoLog(($20|0),($26|0),($5|0),($25|0));
  13723. HEAP32[$vararg_buffer19>>2] = $25;
  13724. _TraceLog(0,9769,$vararg_buffer19);
  13725. _glDeleteProgram(($20|0));
  13726. _llvm_stackrestore(($24|0));
  13727. $$0 = 0;
  13728. _glDeleteShader(($6|0));
  13729. _glDeleteShader(($7|0));
  13730. STACKTOP = sp;return ($$0|0);
  13731. } else {
  13732. HEAP32[$vararg_buffer22>>2] = $20;
  13733. _TraceLog(0,9971,$vararg_buffer22);
  13734. $$0 = $20;
  13735. _glDeleteShader(($6|0));
  13736. _glDeleteShader(($7|0));
  13737. STACKTOP = sp;return ($$0|0);
  13738. }
  13739. return (0)|0;
  13740. }
  13741. function _LoadDefaultShaderLocations($0) {
  13742. $0 = $0|0;
  13743. var $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0;
  13744. var $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0;
  13745. var sp = 0;
  13746. sp = STACKTOP;
  13747. $1 = HEAP32[$0>>2]|0;
  13748. $2 = (_glGetAttribLocation(($1|0),(9564|0))|0);
  13749. $3 = ((($0)) + 4|0);
  13750. HEAP32[$3>>2] = $2;
  13751. $4 = HEAP32[$0>>2]|0;
  13752. $5 = (_glGetAttribLocation(($4|0),(9579|0))|0);
  13753. $6 = ((($0)) + 8|0);
  13754. HEAP32[$6>>2] = $5;
  13755. $7 = HEAP32[$0>>2]|0;
  13756. $8 = (_glGetAttribLocation(($7|0),(9594|0))|0);
  13757. $9 = ((($0)) + 12|0);
  13758. HEAP32[$9>>2] = $8;
  13759. $10 = HEAP32[$0>>2]|0;
  13760. $11 = (_glGetAttribLocation(($10|0),(9610|0))|0);
  13761. $12 = ((($0)) + 16|0);
  13762. HEAP32[$12>>2] = $11;
  13763. $13 = HEAP32[$0>>2]|0;
  13764. $14 = (_glGetAttribLocation(($13|0),(9623|0))|0);
  13765. $15 = ((($0)) + 20|0);
  13766. HEAP32[$15>>2] = $14;
  13767. $16 = HEAP32[$0>>2]|0;
  13768. $17 = (_glGetAttribLocation(($16|0),(9637|0))|0);
  13769. $18 = ((($0)) + 24|0);
  13770. HEAP32[$18>>2] = $17;
  13771. $19 = HEAP32[$0>>2]|0;
  13772. $20 = (_glGetUniformLocation(($19|0),(9649|0))|0);
  13773. $21 = ((($0)) + 28|0);
  13774. HEAP32[$21>>2] = $20;
  13775. $22 = HEAP32[$0>>2]|0;
  13776. $23 = (_glGetUniformLocation(($22|0),(9659|0))|0);
  13777. $24 = ((($0)) + 32|0);
  13778. HEAP32[$24>>2] = $23;
  13779. $25 = HEAP32[$0>>2]|0;
  13780. $26 = (_glGetUniformLocation(($25|0),(9670|0))|0);
  13781. $27 = ((($0)) + 36|0);
  13782. HEAP32[$27>>2] = $26;
  13783. $28 = HEAP32[$0>>2]|0;
  13784. $29 = (_glGetUniformLocation(($28|0),(9681|0))|0);
  13785. $30 = ((($0)) + 40|0);
  13786. HEAP32[$30>>2] = $29;
  13787. $31 = HEAP32[$0>>2]|0;
  13788. $32 = (_glGetUniformLocation(($31|0),(9693|0))|0);
  13789. $33 = ((($0)) + 44|0);
  13790. HEAP32[$33>>2] = $32;
  13791. $34 = HEAP32[$0>>2]|0;
  13792. $35 = (_glGetUniformLocation(($34|0),(9702|0))|0);
  13793. $36 = ((($0)) + 48|0);
  13794. HEAP32[$36>>2] = $35;
  13795. $37 = HEAP32[$0>>2]|0;
  13796. $38 = (_glGetUniformLocation(($37|0),(9711|0))|0);
  13797. $39 = ((($0)) + 52|0);
  13798. HEAP32[$39>>2] = $38;
  13799. return;
  13800. }
  13801. function _IsMouseButtonPressed($0) {
  13802. $0 = $0|0;
  13803. var $$0 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $or$cond = 0, label = 0, sp = 0;
  13804. sp = STACKTOP;
  13805. $1 = (24193 + ($0)|0);
  13806. $2 = HEAP8[$1>>0]|0;
  13807. $3 = (24196 + ($0)|0);
  13808. $4 = HEAP8[$3>>0]|0;
  13809. $5 = ($2<<24>>24)!=($4<<24>>24);
  13810. $6 = ($2<<24>>24)==(1);
  13811. $or$cond = $6 & $5;
  13812. $$0 = $or$cond&1;
  13813. return ($$0|0);
  13814. }
  13815. function _IsMouseButtonReleased($0) {
  13816. $0 = $0|0;
  13817. var $$0 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $or$cond = 0, label = 0, sp = 0;
  13818. sp = STACKTOP;
  13819. $1 = (24193 + ($0)|0);
  13820. $2 = HEAP8[$1>>0]|0;
  13821. $3 = (24196 + ($0)|0);
  13822. $4 = HEAP8[$3>>0]|0;
  13823. $5 = ($2<<24>>24)!=($4<<24>>24);
  13824. $6 = ($2<<24>>24)==(0);
  13825. $or$cond = $6 & $5;
  13826. $$0 = $or$cond&1;
  13827. return ($$0|0);
  13828. }
  13829. function _rlClearScreenBuffers() {
  13830. var label = 0, sp = 0;
  13831. sp = STACKTOP;
  13832. _glClear(16640);
  13833. return;
  13834. }
  13835. function _CloseWindow() {
  13836. var $0 = 0, $vararg_buffer = 0, label = 0, sp = 0;
  13837. sp = STACKTOP;
  13838. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  13839. $vararg_buffer = sp;
  13840. _UnloadDefaultFont();
  13841. _rlglClose();
  13842. $0 = HEAP32[5341]|0;
  13843. _glfwDestroyWindow(($0|0));
  13844. _glfwTerminate();
  13845. _TraceLog(0,10283,$vararg_buffer);
  13846. STACKTOP = sp;return;
  13847. }
  13848. function _UnloadDefaultFont() {
  13849. var $$byval_copy = 0, $0 = 0, label = 0, sp = 0;
  13850. sp = STACKTOP;
  13851. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  13852. $$byval_copy = sp;
  13853. ;HEAP32[$$byval_copy>>2]=HEAP32[21404>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[21404+4>>2]|0;HEAP32[$$byval_copy+8>>2]=HEAP32[21404+8>>2]|0;HEAP32[$$byval_copy+12>>2]=HEAP32[21404+12>>2]|0;HEAP32[$$byval_copy+16>>2]=HEAP32[21404+16>>2]|0;
  13854. _UnloadTexture($$byval_copy);
  13855. $0 = HEAP32[(21432)>>2]|0;
  13856. _free($0);
  13857. STACKTOP = sp;return;
  13858. }
  13859. function _rlglClose() {
  13860. var $0 = 0, $1 = 0, $vararg_buffer = 0, label = 0, sp = 0;
  13861. sp = STACKTOP;
  13862. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  13863. $vararg_buffer = sp;
  13864. _UnloadDefaultShader();
  13865. _UnloadDefaultBuffers();
  13866. _glDeleteTextures(1,(21716|0));
  13867. $0 = HEAP32[5429]|0;
  13868. HEAP32[$vararg_buffer>>2] = $0;
  13869. _TraceLog(0,10310,$vararg_buffer);
  13870. $1 = HEAP32[5459]|0;
  13871. _free($1);
  13872. STACKTOP = sp;return;
  13873. }
  13874. function _UnloadDefaultShader() {
  13875. var $0 = 0, label = 0, sp = 0;
  13876. sp = STACKTOP;
  13877. _glUseProgram(0);
  13878. $0 = HEAP32[5430]|0;
  13879. _glDeleteProgram(($0|0));
  13880. return;
  13881. }
  13882. function _UnloadDefaultBuffers() {
  13883. var $0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  13884. sp = STACKTOP;
  13885. $0 = HEAP32[5422]|0;
  13886. $1 = ($0|0)==(0);
  13887. if (!($1)) {
  13888. $2 = HEAP32[5424]|0;
  13889. FUNCTION_TABLE_vi[$2 & 31](0);
  13890. }
  13891. _glDisableVertexAttribArray(0);
  13892. _glDisableVertexAttribArray(1);
  13893. _glDisableVertexAttribArray(2);
  13894. _glDisableVertexAttribArray(3);
  13895. _glBindBuffer(34962,0);
  13896. _glBindBuffer(34963,0);
  13897. _glDeleteBuffers(1,((22912)|0));
  13898. _glDeleteBuffers(1,((22916)|0));
  13899. _glDeleteBuffers(1,((22960)|0));
  13900. _glDeleteBuffers(1,((22964)|0));
  13901. _glDeleteBuffers(1,((23008)|0));
  13902. _glDeleteBuffers(1,((23012)|0));
  13903. _glDeleteBuffers(1,((23016)|0));
  13904. _glDeleteBuffers(1,((23020)|0));
  13905. $3 = HEAP32[5422]|0;
  13906. $4 = ($3|0)==(0);
  13907. if (!($4)) {
  13908. $5 = HEAP32[5425]|0;
  13909. FUNCTION_TABLE_vii[$5 & 63](1,(22908));
  13910. $6 = HEAP32[5425]|0;
  13911. FUNCTION_TABLE_vii[$6 & 63](1,(22956));
  13912. $7 = HEAP32[5425]|0;
  13913. FUNCTION_TABLE_vii[$7 & 63](1,(23004));
  13914. }
  13915. $8 = HEAP32[(22892)>>2]|0;
  13916. _free($8);
  13917. $9 = HEAP32[(22900)>>2]|0;
  13918. _free($9);
  13919. $10 = HEAP32[(22940)>>2]|0;
  13920. _free($10);
  13921. $11 = HEAP32[(22948)>>2]|0;
  13922. _free($11);
  13923. $12 = HEAP32[(22988)>>2]|0;
  13924. _free($12);
  13925. $13 = HEAP32[(22992)>>2]|0;
  13926. _free($13);
  13927. $14 = HEAP32[(22996)>>2]|0;
  13928. _free($14);
  13929. $15 = HEAP32[(23000)>>2]|0;
  13930. _free($15);
  13931. return;
  13932. }
  13933. function _UnloadTexture($0) {
  13934. $0 = $0|0;
  13935. var $1 = 0, $2 = 0, $3 = 0, $vararg_buffer = 0, label = 0, sp = 0;
  13936. sp = STACKTOP;
  13937. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  13938. $vararg_buffer = sp;
  13939. $1 = HEAP32[$0>>2]|0;
  13940. $2 = ($1|0)==(0);
  13941. if ($2) {
  13942. STACKTOP = sp;return;
  13943. }
  13944. _rlDeleteTextures($1);
  13945. $3 = HEAP32[$0>>2]|0;
  13946. HEAP32[$vararg_buffer>>2] = $3;
  13947. _TraceLog(0,10375,$vararg_buffer);
  13948. STACKTOP = sp;return;
  13949. }
  13950. function _rlDeleteTextures($0) {
  13951. $0 = $0|0;
  13952. var $1 = 0, $2 = 0, label = 0, sp = 0;
  13953. sp = STACKTOP;
  13954. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  13955. $1 = sp;
  13956. HEAP32[$1>>2] = $0;
  13957. $2 = ($0|0)==(0);
  13958. if (!($2)) {
  13959. _glDeleteTextures(1,($1|0));
  13960. }
  13961. STACKTOP = sp;return;
  13962. }
  13963. function _BeginDrawing() {
  13964. var $0 = 0.0, $1 = 0.0, $2 = 0.0, $downscaleView$byval_copy = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  13965. sp = STACKTOP;
  13966. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  13967. $downscaleView$byval_copy = sp;
  13968. $0 = (+_GetTime());
  13969. HEAPF64[2659] = $0;
  13970. $1 = +HEAPF64[2642];
  13971. $2 = $0 - $1;
  13972. HEAPF64[2660] = $2;
  13973. HEAPF64[2642] = $0;
  13974. _rlClearScreenBuffers();
  13975. _rlLoadIdentity();
  13976. dest=$downscaleView$byval_copy; src=21460; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  13977. (_MatrixToFloat($downscaleView$byval_copy)|0);
  13978. _rlMultMatrixf(23032);
  13979. STACKTOP = sp;return;
  13980. }
  13981. function _MatrixToFloat($0) {
  13982. $0 = $0|0;
  13983. var $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0;
  13984. var $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  13985. sp = STACKTOP;
  13986. $1 = HEAP32[$0>>2]|0;
  13987. HEAP32[5758] = $1;
  13988. $2 = ((($0)) + 4|0);
  13989. $3 = HEAP32[$2>>2]|0;
  13990. HEAP32[(23036)>>2] = $3;
  13991. $4 = ((($0)) + 8|0);
  13992. $5 = HEAP32[$4>>2]|0;
  13993. HEAP32[(23040)>>2] = $5;
  13994. $6 = ((($0)) + 12|0);
  13995. $7 = HEAP32[$6>>2]|0;
  13996. HEAP32[(23044)>>2] = $7;
  13997. $8 = ((($0)) + 16|0);
  13998. $9 = HEAP32[$8>>2]|0;
  13999. HEAP32[(23048)>>2] = $9;
  14000. $10 = ((($0)) + 20|0);
  14001. $11 = HEAP32[$10>>2]|0;
  14002. HEAP32[(23052)>>2] = $11;
  14003. $12 = ((($0)) + 24|0);
  14004. $13 = HEAP32[$12>>2]|0;
  14005. HEAP32[(23056)>>2] = $13;
  14006. $14 = ((($0)) + 28|0);
  14007. $15 = HEAP32[$14>>2]|0;
  14008. HEAP32[(23060)>>2] = $15;
  14009. $16 = ((($0)) + 32|0);
  14010. $17 = HEAP32[$16>>2]|0;
  14011. HEAP32[(23064)>>2] = $17;
  14012. $18 = ((($0)) + 36|0);
  14013. $19 = HEAP32[$18>>2]|0;
  14014. HEAP32[(23068)>>2] = $19;
  14015. $20 = ((($0)) + 40|0);
  14016. $21 = HEAP32[$20>>2]|0;
  14017. HEAP32[(23072)>>2] = $21;
  14018. $22 = ((($0)) + 44|0);
  14019. $23 = HEAP32[$22>>2]|0;
  14020. HEAP32[(23076)>>2] = $23;
  14021. $24 = ((($0)) + 48|0);
  14022. $25 = HEAP32[$24>>2]|0;
  14023. HEAP32[(23080)>>2] = $25;
  14024. $26 = ((($0)) + 52|0);
  14025. $27 = HEAP32[$26>>2]|0;
  14026. HEAP32[(23084)>>2] = $27;
  14027. $28 = ((($0)) + 56|0);
  14028. $29 = HEAP32[$28>>2]|0;
  14029. HEAP32[(23088)>>2] = $29;
  14030. $30 = ((($0)) + 60|0);
  14031. $31 = HEAP32[$30>>2]|0;
  14032. HEAP32[(23092)>>2] = $31;
  14033. return (23032|0);
  14034. }
  14035. function _rlMultMatrixf($0) {
  14036. $0 = $0|0;
  14037. var $$byval_copy = 0, $$byval_copy1 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  14038. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0;
  14039. var $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14040. sp = STACKTOP;
  14041. STACKTOP = STACKTOP + 256|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(256|0);
  14042. $$byval_copy1 = sp + 192|0;
  14043. $$byval_copy = sp + 128|0;
  14044. $1 = sp + 64|0;
  14045. $2 = sp;
  14046. $3 = HEAP32[$0>>2]|0;
  14047. HEAP32[$1>>2] = $3;
  14048. $4 = ((($1)) + 4|0);
  14049. $5 = ((($0)) + 4|0);
  14050. $6 = HEAP32[$5>>2]|0;
  14051. HEAP32[$4>>2] = $6;
  14052. $7 = ((($1)) + 8|0);
  14053. $8 = ((($0)) + 8|0);
  14054. $9 = HEAP32[$8>>2]|0;
  14055. HEAP32[$7>>2] = $9;
  14056. $10 = ((($1)) + 12|0);
  14057. $11 = ((($0)) + 12|0);
  14058. $12 = HEAP32[$11>>2]|0;
  14059. HEAP32[$10>>2] = $12;
  14060. $13 = ((($1)) + 16|0);
  14061. $14 = ((($0)) + 16|0);
  14062. $15 = HEAP32[$14>>2]|0;
  14063. HEAP32[$13>>2] = $15;
  14064. $16 = ((($1)) + 20|0);
  14065. $17 = ((($0)) + 20|0);
  14066. $18 = HEAP32[$17>>2]|0;
  14067. HEAP32[$16>>2] = $18;
  14068. $19 = ((($1)) + 24|0);
  14069. $20 = ((($0)) + 24|0);
  14070. $21 = HEAP32[$20>>2]|0;
  14071. HEAP32[$19>>2] = $21;
  14072. $22 = ((($1)) + 28|0);
  14073. $23 = ((($0)) + 28|0);
  14074. $24 = HEAP32[$23>>2]|0;
  14075. HEAP32[$22>>2] = $24;
  14076. $25 = ((($1)) + 32|0);
  14077. $26 = ((($0)) + 32|0);
  14078. $27 = HEAP32[$26>>2]|0;
  14079. HEAP32[$25>>2] = $27;
  14080. $28 = ((($1)) + 36|0);
  14081. $29 = ((($0)) + 36|0);
  14082. $30 = HEAP32[$29>>2]|0;
  14083. HEAP32[$28>>2] = $30;
  14084. $31 = ((($1)) + 40|0);
  14085. $32 = ((($0)) + 40|0);
  14086. $33 = HEAP32[$32>>2]|0;
  14087. HEAP32[$31>>2] = $33;
  14088. $34 = ((($1)) + 44|0);
  14089. $35 = ((($0)) + 44|0);
  14090. $36 = HEAP32[$35>>2]|0;
  14091. HEAP32[$34>>2] = $36;
  14092. $37 = ((($1)) + 48|0);
  14093. $38 = ((($0)) + 48|0);
  14094. $39 = HEAP32[$38>>2]|0;
  14095. HEAP32[$37>>2] = $39;
  14096. $40 = ((($1)) + 52|0);
  14097. $41 = ((($0)) + 52|0);
  14098. $42 = HEAP32[$41>>2]|0;
  14099. HEAP32[$40>>2] = $42;
  14100. $43 = ((($1)) + 56|0);
  14101. $44 = ((($0)) + 56|0);
  14102. $45 = HEAP32[$44>>2]|0;
  14103. HEAP32[$43>>2] = $45;
  14104. $46 = ((($1)) + 60|0);
  14105. $47 = ((($0)) + 60|0);
  14106. $48 = HEAP32[$47>>2]|0;
  14107. HEAP32[$46>>2] = $48;
  14108. $49 = HEAP32[5388]|0;
  14109. dest=$$byval_copy; src=$49; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14110. dest=$$byval_copy1; src=$1; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14111. _MatrixMultiply($2,$$byval_copy,$$byval_copy1);
  14112. dest=$49; src=$2; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14113. STACKTOP = sp;return;
  14114. }
  14115. function _EndDrawing() {
  14116. var $0 = 0.0, $1 = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $14 = 0.0, $2 = 0.0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0, $7 = 0.0, $8 = 0.0, $9 = 0.0, label = 0, sp = 0;
  14117. sp = STACKTOP;
  14118. _rlglDraw();
  14119. _SwapBuffers();
  14120. _PollInputEvents();
  14121. $0 = (+_GetTime());
  14122. HEAPF64[2659] = $0;
  14123. $1 = +HEAPF64[2642];
  14124. $2 = $0 - $1;
  14125. HEAPF64[2661] = $2;
  14126. HEAPF64[2642] = $0;
  14127. $3 = +HEAPF64[2660];
  14128. $4 = $2 + $3;
  14129. HEAPF64[2662] = $4;
  14130. $5 = +HEAPF64[2639];
  14131. $6 = $4 < $5;
  14132. if (!($6)) {
  14133. return;
  14134. }
  14135. $7 = $5 - $4;
  14136. $8 = $7 * 1000.0;
  14137. $9 = $8;
  14138. _Wait($9);
  14139. $10 = (+_GetTime());
  14140. HEAPF64[2659] = $10;
  14141. $11 = +HEAPF64[2642];
  14142. $12 = $10 - $11;
  14143. HEAPF64[2642] = $10;
  14144. $13 = +HEAPF64[2662];
  14145. $14 = $12 + $13;
  14146. HEAPF64[2662] = $14;
  14147. return;
  14148. }
  14149. function _rlglDraw() {
  14150. var label = 0, sp = 0;
  14151. sp = STACKTOP;
  14152. _UpdateDefaultBuffers();
  14153. _DrawDefaultBuffers();
  14154. return;
  14155. }
  14156. function _SwapBuffers() {
  14157. var $0 = 0, label = 0, sp = 0;
  14158. sp = STACKTOP;
  14159. $0 = HEAP32[5341]|0;
  14160. _glfwSwapBuffers(($0|0));
  14161. return;
  14162. }
  14163. function _PollInputEvents() {
  14164. var $$04857 = 0, $$05160 = 0, $$058 = 0, $$lcssa = 0, $0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0;
  14165. var $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0.0, $31 = 0.0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0.0, $40 = 0;
  14166. var $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0, $9 = 0, $scevgep = 0, $scevgep67 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14167. sp = STACKTOP;
  14168. STACKTOP = STACKTOP + 1456|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(1456|0);
  14169. $0 = sp + 1440|0;
  14170. $1 = sp + 1432|0;
  14171. $2 = sp;
  14172. _UpdateGestures();
  14173. HEAP32[741] = -1;
  14174. HEAP32[743] = -1;
  14175. HEAP32[5774] = 0;
  14176. $3 = HEAP32[5341]|0;
  14177. _glfwGetCursorPos(($3|0),($0|0),($1|0));
  14178. $4 = +HEAPF64[$0>>3];
  14179. $5 = $4;
  14180. HEAPF32[5276] = $5;
  14181. $6 = +HEAPF64[$1>>3];
  14182. $7 = $6;
  14183. HEAPF32[(21108)>>2] = $7;
  14184. _memcpy((24711|0),(24199|0),512)|0;
  14185. ;HEAP8[24196>>0]=HEAP8[24193>>0]|0;HEAP8[24196+1>>0]=HEAP8[24193+1>>0]|0;HEAP8[24196+2>>0]=HEAP8[24193+2>>0]|0;
  14186. $8 = HEAP32[5757]|0;
  14187. HEAP32[5344] = $8;
  14188. HEAP32[5757] = 0;
  14189. $9 = (_emscripten_get_num_gamepads()|0);
  14190. $10 = ($9|0)>(0);
  14191. if (!($10)) {
  14192. STACKTOP = sp;return;
  14193. }
  14194. $11 = ((($2)) + 12|0);
  14195. $12 = ((($2)) + 8|0);
  14196. $$05160 = 0;
  14197. while(1) {
  14198. $scevgep = (25223 + ($$05160<<5)|0);
  14199. $scevgep67 = (25351 + ($$05160<<5)|0);
  14200. dest=$scevgep; src=$scevgep67; stop=dest+32|0; do { HEAP8[dest>>0]=HEAP8[src>>0]|0; dest=dest+1|0; src=src+1|0; } while ((dest|0) < (stop|0));
  14201. $13 = (_emscripten_get_gamepad_status(($$05160|0),($2|0))|0);
  14202. $14 = ($13|0)==(0);
  14203. if ($14) {
  14204. $15 = HEAP32[$11>>2]|0;
  14205. $16 = ($15|0)>(0);
  14206. if ($16) {
  14207. $17 = HEAP32[$11>>2]|0;
  14208. $$04857 = 0;
  14209. while(1) {
  14210. $21 = (((($2)) + 1040|0) + ($$04857<<2)|0);
  14211. $22 = HEAP32[$21>>2]|0;
  14212. $23 = ($22|0)==(1);
  14213. $24 = ((25351 + ($$05160<<5)|0) + ($$04857)|0);
  14214. if ($23) {
  14215. HEAP8[$24>>0] = 1;
  14216. HEAP32[743] = $$04857;
  14217. } else {
  14218. HEAP8[$24>>0] = 0;
  14219. }
  14220. $25 = (($$04857) + 1)|0;
  14221. $26 = ($25|0)<($17|0);
  14222. $27 = ($25|0)<(32);
  14223. $28 = $27 & $26;
  14224. if ($28) {
  14225. $$04857 = $25;
  14226. } else {
  14227. break;
  14228. }
  14229. }
  14230. }
  14231. $18 = HEAP32[$12>>2]|0;
  14232. $19 = ($18|0)>(0);
  14233. if ($19) {
  14234. $20 = HEAP32[$12>>2]|0;
  14235. $$058 = 0;
  14236. while(1) {
  14237. $29 = (((($2)) + 16|0) + ($$058<<3)|0);
  14238. $30 = +HEAPF64[$29>>3];
  14239. $31 = $30;
  14240. $32 = ((23100 + ($$05160<<5)|0) + ($$058<<2)|0);
  14241. HEAPF32[$32>>2] = $31;
  14242. $33 = (($$058) + 1)|0;
  14243. $34 = ($33|0)<($20|0);
  14244. $35 = ($33|0)<(8);
  14245. $36 = $35 & $34;
  14246. if ($36) {
  14247. $$058 = $33;
  14248. } else {
  14249. $$lcssa = $20;
  14250. break;
  14251. }
  14252. }
  14253. } else {
  14254. $$lcssa = $18;
  14255. }
  14256. HEAP32[5774] = $$lcssa;
  14257. }
  14258. $37 = (($$05160) + 1)|0;
  14259. $38 = ($37|0)<($9|0);
  14260. $39 = ($37|0)<(4);
  14261. $40 = $38 & $39;
  14262. if ($40) {
  14263. $$05160 = $37;
  14264. } else {
  14265. break;
  14266. }
  14267. }
  14268. STACKTOP = sp;return;
  14269. }
  14270. function _Wait($0) {
  14271. $0 = +$0;
  14272. var $1 = 0.0, $2 = 0.0, $3 = 0.0, $4 = 0.0, $5 = 0, $6 = 0.0, $7 = 0.0, $8 = 0, label = 0, sp = 0;
  14273. sp = STACKTOP;
  14274. $1 = (+_GetTime());
  14275. $2 = 0.0 - $1;
  14276. $3 = $0 / 1000.0;
  14277. $4 = $3;
  14278. $5 = $2 < $4;
  14279. if (!($5)) {
  14280. return;
  14281. }
  14282. while(1) {
  14283. $6 = (+_GetTime());
  14284. $7 = $6 - $1;
  14285. $8 = $7 < $4;
  14286. if (!($8)) {
  14287. break;
  14288. }
  14289. }
  14290. return;
  14291. }
  14292. function _UpdateDefaultBuffers() {
  14293. var $0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  14294. var $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  14295. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  14296. sp = STACKTOP;
  14297. $0 = HEAP32[5720]|0;
  14298. $1 = ($0|0)>(0);
  14299. if ($1) {
  14300. $2 = HEAP32[5422]|0;
  14301. $3 = ($2|0)==(0);
  14302. if (!($3)) {
  14303. $4 = HEAP32[5424]|0;
  14304. $5 = HEAP32[(22908)>>2]|0;
  14305. FUNCTION_TABLE_vi[$4 & 31]($5);
  14306. }
  14307. $6 = HEAP32[(22912)>>2]|0;
  14308. _glBindBuffer(34962,($6|0));
  14309. $7 = HEAP32[5720]|0;
  14310. $8 = ($7*12)|0;
  14311. $9 = HEAP32[(22892)>>2]|0;
  14312. _glBufferSubData(34962,0,($8|0),($9|0));
  14313. $10 = HEAP32[(22916)>>2]|0;
  14314. _glBindBuffer(34962,($10|0));
  14315. $11 = HEAP32[(22888)>>2]|0;
  14316. $12 = $11 << 2;
  14317. $13 = HEAP32[(22900)>>2]|0;
  14318. _glBufferSubData(34962,0,($12|0),($13|0));
  14319. }
  14320. $14 = HEAP32[5732]|0;
  14321. $15 = ($14|0)>(0);
  14322. if ($15) {
  14323. $16 = HEAP32[5422]|0;
  14324. $17 = ($16|0)==(0);
  14325. if (!($17)) {
  14326. $18 = HEAP32[5424]|0;
  14327. $19 = HEAP32[(22956)>>2]|0;
  14328. FUNCTION_TABLE_vi[$18 & 31]($19);
  14329. }
  14330. $20 = HEAP32[(22960)>>2]|0;
  14331. _glBindBuffer(34962,($20|0));
  14332. $21 = HEAP32[5732]|0;
  14333. $22 = ($21*12)|0;
  14334. $23 = HEAP32[(22940)>>2]|0;
  14335. _glBufferSubData(34962,0,($22|0),($23|0));
  14336. $24 = HEAP32[(22964)>>2]|0;
  14337. _glBindBuffer(34962,($24|0));
  14338. $25 = HEAP32[(22936)>>2]|0;
  14339. $26 = $25 << 2;
  14340. $27 = HEAP32[(22948)>>2]|0;
  14341. _glBufferSubData(34962,0,($26|0),($27|0));
  14342. }
  14343. $28 = HEAP32[5744]|0;
  14344. $29 = ($28|0)>(0);
  14345. if ($29) {
  14346. $30 = HEAP32[5422]|0;
  14347. $31 = ($30|0)==(0);
  14348. if (!($31)) {
  14349. $32 = HEAP32[5424]|0;
  14350. $33 = HEAP32[(23004)>>2]|0;
  14351. FUNCTION_TABLE_vi[$32 & 31]($33);
  14352. }
  14353. $34 = HEAP32[(23008)>>2]|0;
  14354. _glBindBuffer(34962,($34|0));
  14355. $35 = HEAP32[5744]|0;
  14356. $36 = ($35*12)|0;
  14357. $37 = HEAP32[(22988)>>2]|0;
  14358. _glBufferSubData(34962,0,($36|0),($37|0));
  14359. $38 = HEAP32[(23012)>>2]|0;
  14360. _glBindBuffer(34962,($38|0));
  14361. $39 = HEAP32[5744]|0;
  14362. $40 = $39 << 3;
  14363. $41 = HEAP32[(22992)>>2]|0;
  14364. _glBufferSubData(34962,0,($40|0),($41|0));
  14365. $42 = HEAP32[(23016)>>2]|0;
  14366. _glBindBuffer(34962,($42|0));
  14367. $43 = HEAP32[5744]|0;
  14368. $44 = $43 << 2;
  14369. $45 = HEAP32[(22996)>>2]|0;
  14370. _glBufferSubData(34962,0,($44|0),($45|0));
  14371. }
  14372. $46 = HEAP32[5422]|0;
  14373. $47 = ($46|0)==(0);
  14374. if ($47) {
  14375. return;
  14376. }
  14377. $48 = HEAP32[5424]|0;
  14378. FUNCTION_TABLE_vi[$48 & 31](0);
  14379. return;
  14380. }
  14381. function _DrawDefaultBuffers() {
  14382. var $$ = 0, $$02830 = 0, $$02932 = 0, $$031 = 0, $$byval_copy2 = 0, $0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0;
  14383. var $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0;
  14384. var $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0;
  14385. var $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0;
  14386. var $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $modelview$byval_copy = 0;
  14387. var $or$cond = 0, $or$cond3 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14388. sp = STACKTOP;
  14389. STACKTOP = STACKTOP + 320|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(320|0);
  14390. $$byval_copy2 = sp + 256|0;
  14391. $modelview$byval_copy = sp + 192|0;
  14392. $0 = sp + 128|0;
  14393. $1 = sp + 64|0;
  14394. $2 = sp;
  14395. dest=$0; src=21556; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14396. dest=$1; src=21620; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14397. $3 = HEAP32[5807]|0;
  14398. $4 = ($3|0)!=(0);
  14399. $$ = $4 ? 2 : 1;
  14400. $$02932 = 0;
  14401. while(1) {
  14402. if ($4) {
  14403. dest=$modelview$byval_copy; src=$0; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14404. dest=$$byval_copy2; src=$1; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14405. _SetStereoView($$02932,$modelview$byval_copy,$$byval_copy2);
  14406. }
  14407. $8 = HEAP32[5720]|0;
  14408. $9 = ($8|0)>(0);
  14409. $10 = HEAP32[5732]|0;
  14410. $11 = ($10|0)>(0);
  14411. $or$cond = $9 | $11;
  14412. $12 = HEAP32[5744]|0;
  14413. $13 = ($12|0)>(0);
  14414. $or$cond3 = $or$cond | $13;
  14415. if ($or$cond3) {
  14416. $14 = HEAP32[5444]|0;
  14417. _glUseProgram(($14|0));
  14418. dest=$modelview$byval_copy; src=21620; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14419. dest=$$byval_copy2; src=21556; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14420. _MatrixMultiply($2,$modelview$byval_copy,$$byval_copy2);
  14421. $15 = HEAP32[(21804)>>2]|0;
  14422. dest=$$byval_copy2; src=$2; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14423. $16 = (_MatrixToFloat($$byval_copy2)|0);
  14424. _glUniformMatrix4fv(($15|0),1,0,($16|0));
  14425. $17 = HEAP32[(21808)>>2]|0;
  14426. _glUniform4f(($17|0),1.0,1.0,1.0,1.0);
  14427. $18 = HEAP32[(21820)>>2]|0;
  14428. _glUniform1i(($18|0),0);
  14429. }
  14430. $19 = HEAP32[5720]|0;
  14431. $20 = ($19|0)>(0);
  14432. if ($20) {
  14433. $21 = HEAP32[5429]|0;
  14434. _glBindTexture(3553,($21|0));
  14435. $22 = HEAP32[5422]|0;
  14436. $23 = ($22|0)==(0);
  14437. if ($23) {
  14438. $26 = HEAP32[(22912)>>2]|0;
  14439. _glBindBuffer(34962,($26|0));
  14440. $27 = HEAP32[(21780)>>2]|0;
  14441. _glVertexAttribPointer(($27|0),3,5126,0,0,(0|0));
  14442. $28 = HEAP32[(21780)>>2]|0;
  14443. _glEnableVertexAttribArray(($28|0));
  14444. $29 = HEAP32[(22916)>>2]|0;
  14445. _glBindBuffer(34962,($29|0));
  14446. $30 = HEAP32[(21800)>>2]|0;
  14447. _glVertexAttribPointer(($30|0),4,5121,1,0,(0|0));
  14448. $31 = HEAP32[(21800)>>2]|0;
  14449. _glEnableVertexAttribArray(($31|0));
  14450. } else {
  14451. $24 = HEAP32[5424]|0;
  14452. $25 = HEAP32[(22908)>>2]|0;
  14453. FUNCTION_TABLE_vi[$24 & 31]($25);
  14454. }
  14455. $32 = HEAP32[5720]|0;
  14456. _glDrawArrays(1,0,($32|0));
  14457. $33 = HEAP32[5422]|0;
  14458. $34 = ($33|0)==(0);
  14459. if ($34) {
  14460. _glBindBuffer(34962,0);
  14461. }
  14462. _glBindTexture(3553,0);
  14463. }
  14464. $35 = HEAP32[5732]|0;
  14465. $36 = ($35|0)>(0);
  14466. if ($36) {
  14467. $37 = HEAP32[5429]|0;
  14468. _glBindTexture(3553,($37|0));
  14469. $38 = HEAP32[5422]|0;
  14470. $39 = ($38|0)==(0);
  14471. if ($39) {
  14472. $42 = HEAP32[(22960)>>2]|0;
  14473. _glBindBuffer(34962,($42|0));
  14474. $43 = HEAP32[(21780)>>2]|0;
  14475. _glVertexAttribPointer(($43|0),3,5126,0,0,(0|0));
  14476. $44 = HEAP32[(21780)>>2]|0;
  14477. _glEnableVertexAttribArray(($44|0));
  14478. $45 = HEAP32[(22964)>>2]|0;
  14479. _glBindBuffer(34962,($45|0));
  14480. $46 = HEAP32[(21800)>>2]|0;
  14481. _glVertexAttribPointer(($46|0),4,5121,1,0,(0|0));
  14482. $47 = HEAP32[(21800)>>2]|0;
  14483. _glEnableVertexAttribArray(($47|0));
  14484. } else {
  14485. $40 = HEAP32[5424]|0;
  14486. $41 = HEAP32[(22956)>>2]|0;
  14487. FUNCTION_TABLE_vi[$40 & 31]($41);
  14488. }
  14489. $48 = HEAP32[5732]|0;
  14490. _glDrawArrays(4,0,($48|0));
  14491. $49 = HEAP32[5422]|0;
  14492. $50 = ($49|0)==(0);
  14493. if ($50) {
  14494. _glBindBuffer(34962,0);
  14495. }
  14496. _glBindTexture(3553,0);
  14497. }
  14498. $51 = HEAP32[5744]|0;
  14499. $52 = ($51|0)>(0);
  14500. if ($52) {
  14501. $53 = HEAP32[5422]|0;
  14502. $54 = ($53|0)==(0);
  14503. if ($54) {
  14504. $57 = HEAP32[(23008)>>2]|0;
  14505. _glBindBuffer(34962,($57|0));
  14506. $58 = HEAP32[(21780)>>2]|0;
  14507. _glVertexAttribPointer(($58|0),3,5126,0,0,(0|0));
  14508. $59 = HEAP32[(21780)>>2]|0;
  14509. _glEnableVertexAttribArray(($59|0));
  14510. $60 = HEAP32[(23012)>>2]|0;
  14511. _glBindBuffer(34962,($60|0));
  14512. $61 = HEAP32[(21784)>>2]|0;
  14513. _glVertexAttribPointer(($61|0),2,5126,0,0,(0|0));
  14514. $62 = HEAP32[(21784)>>2]|0;
  14515. _glEnableVertexAttribArray(($62|0));
  14516. $63 = HEAP32[(23016)>>2]|0;
  14517. _glBindBuffer(34962,($63|0));
  14518. $64 = HEAP32[(21800)>>2]|0;
  14519. _glVertexAttribPointer(($64|0),4,5121,1,0,(0|0));
  14520. $65 = HEAP32[(21800)>>2]|0;
  14521. _glEnableVertexAttribArray(($65|0));
  14522. $66 = HEAP32[(23020)>>2]|0;
  14523. _glBindBuffer(34963,($66|0));
  14524. } else {
  14525. $55 = HEAP32[5424]|0;
  14526. $56 = HEAP32[(23004)>>2]|0;
  14527. FUNCTION_TABLE_vi[$55 & 31]($56);
  14528. }
  14529. $67 = HEAP32[5460]|0;
  14530. $68 = ($67|0)>(0);
  14531. if ($68) {
  14532. $$02830 = 0;$$031 = 0;
  14533. while(1) {
  14534. $71 = HEAP32[5459]|0;
  14535. $72 = (($71) + (($$031*144)|0)|0);
  14536. $73 = HEAP32[$72>>2]|0;
  14537. $74 = (($73|0) / 4)&-1;
  14538. $75 = ($74*6)|0;
  14539. $76 = (((($71) + (($$031*144)|0)|0)) + 8|0);
  14540. $77 = HEAP32[$76>>2]|0;
  14541. _glBindTexture(3553,($77|0));
  14542. $78 = $$02830 << 1;
  14543. $79 = $78;
  14544. _glDrawElements(4,($75|0),5123,($79|0));
  14545. $80 = HEAP32[5459]|0;
  14546. $81 = (($80) + (($$031*144)|0)|0);
  14547. $82 = HEAP32[$81>>2]|0;
  14548. $83 = (($82|0) / 4)&-1;
  14549. $84 = ($83*6)|0;
  14550. $85 = (($84) + ($$02830))|0;
  14551. $86 = (($$031) + 1)|0;
  14552. $87 = HEAP32[5460]|0;
  14553. $88 = ($86|0)<($87|0);
  14554. if ($88) {
  14555. $$02830 = $85;$$031 = $86;
  14556. } else {
  14557. break;
  14558. }
  14559. }
  14560. }
  14561. $69 = HEAP32[5422]|0;
  14562. $70 = ($69|0)==(0);
  14563. if ($70) {
  14564. _glBindBuffer(34962,0);
  14565. _glBindBuffer(34963,0);
  14566. }
  14567. _glBindTexture(3553,0);
  14568. }
  14569. $89 = HEAP32[5422]|0;
  14570. $90 = ($89|0)==(0);
  14571. if (!($90)) {
  14572. $91 = HEAP32[5424]|0;
  14573. FUNCTION_TABLE_vi[$91 & 31](0);
  14574. }
  14575. _glUseProgram(0);
  14576. $92 = (($$02932) + 1)|0;
  14577. $93 = ($92|0)<($$|0);
  14578. if ($93) {
  14579. $$02932 = $92;
  14580. } else {
  14581. break;
  14582. }
  14583. }
  14584. HEAP32[5460] = 1;
  14585. $5 = HEAP32[5429]|0;
  14586. $6 = HEAP32[5459]|0;
  14587. $7 = ((($6)) + 8|0);
  14588. HEAP32[$7>>2] = $5;
  14589. HEAP32[$6>>2] = 0;
  14590. HEAP32[5720] = 0;
  14591. HEAP32[(22888)>>2] = 0;
  14592. HEAP32[5732] = 0;
  14593. HEAP32[(22936)>>2] = 0;
  14594. HEAP32[5744] = 0;
  14595. HEAP32[(22980)>>2] = 0;
  14596. HEAP32[(22984)>>2] = 0;
  14597. HEAPF32[744] = -1.0;
  14598. dest=21556; src=$0; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14599. dest=21620; src=$1; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14600. STACKTOP = sp;return;
  14601. }
  14602. function _SetStereoView($0,$1,$2) {
  14603. $0 = $0|0;
  14604. $1 = $1|0;
  14605. $2 = $2|0;
  14606. var $$byval_copy = 0, $$byval_copy3 = 0, $10 = 0, $11 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14607. sp = STACKTOP;
  14608. STACKTOP = STACKTOP + 256|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(256|0);
  14609. $$byval_copy3 = sp + 192|0;
  14610. $$byval_copy = sp + 64|0;
  14611. $3 = sp;
  14612. $4 = sp + 128|0;
  14613. dest=$3; src=$1; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14614. $5 = HEAP32[5718]|0;
  14615. $6 = Math_imul($5, $0)|0;
  14616. $7 = (($6|0) / 2)&-1;
  14617. $8 = (($5|0) / 2)&-1;
  14618. $9 = HEAP32[5719]|0;
  14619. _rlViewport($7,0,$8,$9);
  14620. $10 = (23460 + ($0<<6)|0);
  14621. dest=$$byval_copy; src=$2; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14622. dest=$$byval_copy3; src=$10; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14623. _MatrixMultiply($4,$$byval_copy,$$byval_copy3);
  14624. $11 = (23332 + ($0<<6)|0);
  14625. dest=$3; src=$11; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14626. dest=$$byval_copy3; src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14627. _SetMatrixModelview($$byval_copy3);
  14628. dest=$$byval_copy3; src=$3; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14629. _SetMatrixProjection($$byval_copy3);
  14630. STACKTOP = sp;return;
  14631. }
  14632. function _SetMatrixModelview($0) {
  14633. $0 = $0|0;
  14634. var dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14635. sp = STACKTOP;
  14636. dest=21620; src=$0; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14637. return;
  14638. }
  14639. function _SetMatrixProjection($0) {
  14640. $0 = $0|0;
  14641. var dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14642. sp = STACKTOP;
  14643. dest=21556; src=$0; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14644. return;
  14645. }
  14646. function _rlPushMatrix() {
  14647. var $0 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $vararg_buffer = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14648. sp = STACKTOP;
  14649. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  14650. $vararg_buffer = sp;
  14651. $0 = HEAP32[5897]|0;
  14652. $1 = ($0|0)==(15);
  14653. if ($1) {
  14654. HEAP32[$vararg_buffer>>2] = 16;
  14655. _TraceLog(1,10425,$vararg_buffer);
  14656. }
  14657. $2 = HEAP32[5897]|0;
  14658. $3 = (21848 + ($2<<6)|0);
  14659. $4 = HEAP32[5388]|0;
  14660. dest=$3; src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14661. _rlLoadIdentity();
  14662. $5 = HEAP32[5897]|0;
  14663. $6 = (($5) + 1)|0;
  14664. HEAP32[5897] = $6;
  14665. $7 = HEAP32[5421]|0;
  14666. $8 = ($7|0)==(5888);
  14667. if (!($8)) {
  14668. STACKTOP = sp;return;
  14669. }
  14670. HEAP32[5898] = 1;
  14671. STACKTOP = sp;return;
  14672. }
  14673. function _rlPopMatrix() {
  14674. var $0 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  14675. sp = STACKTOP;
  14676. $0 = HEAP32[5897]|0;
  14677. $1 = ($0|0)>(0);
  14678. if (!($1)) {
  14679. return;
  14680. }
  14681. $2 = HEAP32[5897]|0;
  14682. $3 = (($2) + -1)|0;
  14683. $4 = (21848 + ($3<<6)|0);
  14684. $5 = HEAP32[5388]|0;
  14685. _memmove(($5|0),($4|0),64)|0;
  14686. $6 = (($2) + -1)|0;
  14687. HEAP32[5897] = $6;
  14688. return;
  14689. }
  14690. function _IsFileExtension($0,$1) {
  14691. $0 = $0|0;
  14692. $1 = $1|0;
  14693. var $$ = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, label = 0, sp = 0;
  14694. sp = STACKTOP;
  14695. $2 = (_strrchr($0,46)|0);
  14696. $3 = ($2|0)==(0|0);
  14697. if ($3) {
  14698. return 0;
  14699. } else {
  14700. $4 = (_strcmp($2,$1)|0);
  14701. $5 = ($4|0)==(0);
  14702. $$ = $5&1;
  14703. return ($$|0);
  14704. }
  14705. return (0)|0;
  14706. }
  14707. function _rlTranslatef($0,$1,$2) {
  14708. $0 = +$0;
  14709. $1 = +$1;
  14710. $2 = +$2;
  14711. var $$byval_copy = 0, $$byval_copy1 = 0, $3 = 0, $4 = 0, $5 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14712. sp = STACKTOP;
  14713. STACKTOP = STACKTOP + 256|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(256|0);
  14714. $$byval_copy1 = sp + 192|0;
  14715. $$byval_copy = sp + 128|0;
  14716. $3 = sp + 64|0;
  14717. $4 = sp;
  14718. _MatrixTranslate($3,$0,$1,$2);
  14719. _MatrixTranspose($3);
  14720. $5 = HEAP32[5388]|0;
  14721. dest=$$byval_copy; src=$5; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14722. dest=$$byval_copy1; src=$3; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14723. _MatrixMultiply($4,$$byval_copy,$$byval_copy1);
  14724. dest=$5; src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14725. STACKTOP = sp;return;
  14726. }
  14727. function _rlRotatef($0,$1,$2,$3) {
  14728. $0 = +$0;
  14729. $1 = +$1;
  14730. $2 = +$2;
  14731. $3 = +$3;
  14732. var $$byval_copy1 = 0, $$byval_copy2 = 0, $10 = 0.0, $11 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14733. sp = STACKTOP;
  14734. STACKTOP = STACKTOP + 336|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(336|0);
  14735. $$byval_copy2 = sp + 272|0;
  14736. $$byval_copy1 = sp + 208|0;
  14737. $4 = sp + 144|0;
  14738. $5 = sp + 64|0;
  14739. $6 = sp + 80|0;
  14740. $7 = sp;
  14741. _MatrixIdentity($4);
  14742. HEAPF32[$5>>2] = $1;
  14743. $8 = ((($5)) + 4|0);
  14744. HEAPF32[$8>>2] = $2;
  14745. $9 = ((($5)) + 8|0);
  14746. HEAPF32[$9>>2] = $3;
  14747. _VectorNormalize($5);
  14748. $10 = $0 * 0.01745329238474369;
  14749. ;HEAP32[$$byval_copy2>>2]=HEAP32[$5>>2]|0;HEAP32[$$byval_copy2+4>>2]=HEAP32[$5+4>>2]|0;HEAP32[$$byval_copy2+8>>2]=HEAP32[$5+8>>2]|0;
  14750. _MatrixRotate($6,$$byval_copy2,$10);
  14751. dest=$4; src=$6; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14752. _MatrixTranspose($4);
  14753. $11 = HEAP32[5388]|0;
  14754. dest=$$byval_copy1; src=$11; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14755. dest=$$byval_copy2; src=$4; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14756. _MatrixMultiply($7,$$byval_copy1,$$byval_copy2);
  14757. dest=$11; src=$7; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14758. STACKTOP = sp;return;
  14759. }
  14760. function _rlBegin($0) {
  14761. $0 = $0|0;
  14762. var label = 0, sp = 0;
  14763. sp = STACKTOP;
  14764. HEAP32[5461] = $0;
  14765. return;
  14766. }
  14767. function _rlEnd() {
  14768. var $$03956 = 0, $$04052 = 0, $$04154 = 0, $$04248 = 0, $$04347 = 0, $$byval_copy = 0, $$promoted = 0, $0 = 0, $1 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0;
  14769. var $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0;
  14770. var $128 = 0, $129 = 0, $13 = 0.0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0;
  14771. var $146 = 0, $147 = 0, $148 = 0.0, $149 = 0.0, $15 = 0.0, $16 = 0, $17 = 0.0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0;
  14772. var $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0;
  14773. var $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0;
  14774. var $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0;
  14775. var $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $exitcond = 0, $exitcond60 = 0, $exitcond63 = 0;
  14776. var $scevgep = 0, dest = 0, label = 0, sp = 0, src = 0, stop = 0;
  14777. sp = STACKTOP;
  14778. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  14779. $$byval_copy = sp;
  14780. $0 = HEAP32[5898]|0;
  14781. $1 = ($0|0)==(0);
  14782. if (!($1)) {
  14783. $2 = HEAP32[5899]|0;
  14784. $3 = ($2|0)>(0);
  14785. if ($3) {
  14786. $$03956 = 0;
  14787. while(1) {
  14788. $6 = HEAP32[5458]|0;
  14789. $7 = (($6) + (($$03956*12)|0)|0);
  14790. $8 = HEAP32[5388]|0;
  14791. dest=$$byval_copy; src=$8; stop=dest+64|0; do { HEAP32[dest>>2]=HEAP32[src>>2]|0; dest=dest+4|0; src=src+4|0; } while ((dest|0) < (stop|0));
  14792. _VectorTransform($7,$$byval_copy);
  14793. $9 = (($$03956) + 1)|0;
  14794. $5 = HEAP32[5899]|0;
  14795. $10 = ($9|0)<($5|0);
  14796. if ($10) {
  14797. $$03956 = $9;
  14798. } else {
  14799. break;
  14800. }
  14801. }
  14802. HEAP32[5898] = 0;
  14803. $4 = ($5|0)>(0);
  14804. if ($4) {
  14805. $$04154 = 0;
  14806. while(1) {
  14807. $11 = HEAP32[5458]|0;
  14808. $12 = (($11) + (($$04154*12)|0)|0);
  14809. $13 = +HEAPF32[$12>>2];
  14810. $14 = (((($11) + (($$04154*12)|0)|0)) + 4|0);
  14811. $15 = +HEAPF32[$14>>2];
  14812. $16 = (((($11) + (($$04154*12)|0)|0)) + 8|0);
  14813. $17 = +HEAPF32[$16>>2];
  14814. _rlVertex3f($13,$15,$17);
  14815. $18 = (($$04154) + 1)|0;
  14816. $19 = HEAP32[5899]|0;
  14817. $20 = ($18|0)<($19|0);
  14818. if ($20) {
  14819. $$04154 = $18;
  14820. } else {
  14821. break;
  14822. }
  14823. }
  14824. }
  14825. } else {
  14826. HEAP32[5898] = 0;
  14827. }
  14828. HEAP32[5899] = 0;
  14829. }
  14830. $21 = HEAP32[5461]|0;
  14831. switch ($21|0) {
  14832. case 1: {
  14833. $22 = HEAP32[5720]|0;
  14834. $23 = HEAP32[(22888)>>2]|0;
  14835. $24 = ($22|0)==($23|0);
  14836. if ($24) {
  14837. $148 = +HEAPF32[744];
  14838. $149 = $148 + 4.9999998736893758E-5;
  14839. HEAPF32[744] = $149;
  14840. STACKTOP = sp;return;
  14841. }
  14842. $25 = (($22) - ($23))|0;
  14843. $26 = ($25|0)>(0);
  14844. if ($26) {
  14845. $$04347 = 0;
  14846. } else {
  14847. $148 = +HEAPF32[744];
  14848. $149 = $148 + 4.9999998736893758E-5;
  14849. HEAPF32[744] = $149;
  14850. STACKTOP = sp;return;
  14851. }
  14852. while(1) {
  14853. $27 = HEAP32[(22900)>>2]|0;
  14854. $28 = HEAP32[(22888)>>2]|0;
  14855. $29 = $28 << 2;
  14856. $30 = (($29) + -4)|0;
  14857. $31 = (($27) + ($30)|0);
  14858. $32 = HEAP8[$31>>0]|0;
  14859. $33 = (($27) + ($29)|0);
  14860. HEAP8[$33>>0] = $32;
  14861. $34 = HEAP32[(22900)>>2]|0;
  14862. $35 = HEAP32[(22888)>>2]|0;
  14863. $36 = $35 << 2;
  14864. $37 = (($36) + -3)|0;
  14865. $38 = (($34) + ($37)|0);
  14866. $39 = HEAP8[$38>>0]|0;
  14867. $40 = $36 | 1;
  14868. $41 = (($34) + ($40)|0);
  14869. HEAP8[$41>>0] = $39;
  14870. $42 = HEAP32[(22900)>>2]|0;
  14871. $43 = HEAP32[(22888)>>2]|0;
  14872. $44 = $43 << 2;
  14873. $45 = (($44) + -2)|0;
  14874. $46 = (($42) + ($45)|0);
  14875. $47 = HEAP8[$46>>0]|0;
  14876. $48 = $44 | 2;
  14877. $49 = (($42) + ($48)|0);
  14878. HEAP8[$49>>0] = $47;
  14879. $50 = HEAP32[(22900)>>2]|0;
  14880. $51 = HEAP32[(22888)>>2]|0;
  14881. $52 = $51 << 2;
  14882. $53 = (($52) + -1)|0;
  14883. $54 = (($50) + ($53)|0);
  14884. $55 = HEAP8[$54>>0]|0;
  14885. $56 = $52 | 3;
  14886. $57 = (($50) + ($56)|0);
  14887. HEAP8[$57>>0] = $55;
  14888. $58 = HEAP32[(22888)>>2]|0;
  14889. $59 = (($58) + 1)|0;
  14890. HEAP32[(22888)>>2] = $59;
  14891. $60 = (($$04347) + 1)|0;
  14892. $exitcond = ($60|0)==($25|0);
  14893. if ($exitcond) {
  14894. break;
  14895. } else {
  14896. $$04347 = $60;
  14897. }
  14898. }
  14899. $148 = +HEAPF32[744];
  14900. $149 = $148 + 4.9999998736893758E-5;
  14901. HEAPF32[744] = $149;
  14902. STACKTOP = sp;return;
  14903. break;
  14904. }
  14905. case 4: {
  14906. $61 = HEAP32[5732]|0;
  14907. $62 = HEAP32[(22936)>>2]|0;
  14908. $63 = ($61|0)==($62|0);
  14909. if ($63) {
  14910. $148 = +HEAPF32[744];
  14911. $149 = $148 + 4.9999998736893758E-5;
  14912. HEAPF32[744] = $149;
  14913. STACKTOP = sp;return;
  14914. }
  14915. $64 = (($61) - ($62))|0;
  14916. $65 = ($64|0)>(0);
  14917. if ($65) {
  14918. $$04248 = 0;
  14919. } else {
  14920. $148 = +HEAPF32[744];
  14921. $149 = $148 + 4.9999998736893758E-5;
  14922. HEAPF32[744] = $149;
  14923. STACKTOP = sp;return;
  14924. }
  14925. while(1) {
  14926. $66 = HEAP32[(22948)>>2]|0;
  14927. $67 = HEAP32[(22936)>>2]|0;
  14928. $68 = $67 << 2;
  14929. $69 = (($68) + -4)|0;
  14930. $70 = (($66) + ($69)|0);
  14931. $71 = HEAP8[$70>>0]|0;
  14932. $72 = (($66) + ($68)|0);
  14933. HEAP8[$72>>0] = $71;
  14934. $73 = HEAP32[(22948)>>2]|0;
  14935. $74 = HEAP32[(22936)>>2]|0;
  14936. $75 = $74 << 2;
  14937. $76 = (($75) + -3)|0;
  14938. $77 = (($73) + ($76)|0);
  14939. $78 = HEAP8[$77>>0]|0;
  14940. $79 = $75 | 1;
  14941. $80 = (($73) + ($79)|0);
  14942. HEAP8[$80>>0] = $78;
  14943. $81 = HEAP32[(22948)>>2]|0;
  14944. $82 = HEAP32[(22936)>>2]|0;
  14945. $83 = $82 << 2;
  14946. $84 = (($83) + -2)|0;
  14947. $85 = (($81) + ($84)|0);
  14948. $86 = HEAP8[$85>>0]|0;
  14949. $87 = $83 | 2;
  14950. $88 = (($81) + ($87)|0);
  14951. HEAP8[$88>>0] = $86;
  14952. $89 = HEAP32[(22948)>>2]|0;
  14953. $90 = HEAP32[(22936)>>2]|0;
  14954. $91 = $90 << 2;
  14955. $92 = (($91) + -1)|0;
  14956. $93 = (($89) + ($92)|0);
  14957. $94 = HEAP8[$93>>0]|0;
  14958. $95 = $91 | 3;
  14959. $96 = (($89) + ($95)|0);
  14960. HEAP8[$96>>0] = $94;
  14961. $97 = HEAP32[(22936)>>2]|0;
  14962. $98 = (($97) + 1)|0;
  14963. HEAP32[(22936)>>2] = $98;
  14964. $99 = (($$04248) + 1)|0;
  14965. $exitcond60 = ($99|0)==($64|0);
  14966. if ($exitcond60) {
  14967. break;
  14968. } else {
  14969. $$04248 = $99;
  14970. }
  14971. }
  14972. $148 = +HEAPF32[744];
  14973. $149 = $148 + 4.9999998736893758E-5;
  14974. HEAPF32[744] = $149;
  14975. STACKTOP = sp;return;
  14976. break;
  14977. }
  14978. case 7: {
  14979. $100 = HEAP32[5744]|0;
  14980. $101 = HEAP32[(22984)>>2]|0;
  14981. $102 = ($100|0)==($101|0);
  14982. if (!($102)) {
  14983. $103 = (($100) - ($101))|0;
  14984. $104 = ($103|0)>(0);
  14985. if ($104) {
  14986. $$04052 = 0;
  14987. while(1) {
  14988. $105 = HEAP32[(22996)>>2]|0;
  14989. $106 = HEAP32[(22984)>>2]|0;
  14990. $107 = $106 << 2;
  14991. $108 = (($107) + -4)|0;
  14992. $109 = (($105) + ($108)|0);
  14993. $110 = HEAP8[$109>>0]|0;
  14994. $111 = (($105) + ($107)|0);
  14995. HEAP8[$111>>0] = $110;
  14996. $112 = HEAP32[(22996)>>2]|0;
  14997. $113 = HEAP32[(22984)>>2]|0;
  14998. $114 = $113 << 2;
  14999. $115 = (($114) + -3)|0;
  15000. $116 = (($112) + ($115)|0);
  15001. $117 = HEAP8[$116>>0]|0;
  15002. $118 = $114 | 1;
  15003. $119 = (($112) + ($118)|0);
  15004. HEAP8[$119>>0] = $117;
  15005. $120 = HEAP32[(22996)>>2]|0;
  15006. $121 = HEAP32[(22984)>>2]|0;
  15007. $122 = $121 << 2;
  15008. $123 = (($122) + -2)|0;
  15009. $124 = (($120) + ($123)|0);
  15010. $125 = HEAP8[$124>>0]|0;
  15011. $126 = $122 | 2;
  15012. $127 = (($120) + ($126)|0);
  15013. HEAP8[$127>>0] = $125;
  15014. $128 = HEAP32[(22996)>>2]|0;
  15015. $129 = HEAP32[(22984)>>2]|0;
  15016. $130 = $129 << 2;
  15017. $131 = (($130) + -1)|0;
  15018. $132 = (($128) + ($131)|0);
  15019. $133 = HEAP8[$132>>0]|0;
  15020. $134 = $130 | 3;
  15021. $135 = (($128) + ($134)|0);
  15022. HEAP8[$135>>0] = $133;
  15023. $136 = HEAP32[(22984)>>2]|0;
  15024. $137 = (($136) + 1)|0;
  15025. HEAP32[(22984)>>2] = $137;
  15026. $138 = (($$04052) + 1)|0;
  15027. $exitcond63 = ($138|0)==($103|0);
  15028. if ($exitcond63) {
  15029. break;
  15030. } else {
  15031. $$04052 = $138;
  15032. }
  15033. }
  15034. }
  15035. }
  15036. $139 = HEAP32[5744]|0;
  15037. $140 = HEAP32[(22980)>>2]|0;
  15038. $141 = ($139|0)>($140|0);
  15039. if (!($141)) {
  15040. $148 = +HEAPF32[744];
  15041. $149 = $148 + 4.9999998736893758E-5;
  15042. HEAPF32[744] = $149;
  15043. STACKTOP = sp;return;
  15044. }
  15045. $142 = HEAP32[(22992)>>2]|0;
  15046. $$promoted = HEAP32[(22980)>>2]|0;
  15047. $143 = $$promoted << 1;
  15048. $scevgep = (($142) + ($143<<2)|0);
  15049. $144 = (($139) - ($140))|0;
  15050. $145 = $144 << 3;
  15051. _memset(($scevgep|0),0,($145|0))|0;
  15052. $146 = (($139) + ($$promoted))|0;
  15053. $147 = (($146) - ($140))|0;
  15054. HEAP32[(22980)>>2] = $147;
  15055. $148 = +HEAPF32[744];
  15056. $149 = $148 + 4.9999998736893758E-5;
  15057. HEAPF32[744] = $149;
  15058. STACKTOP = sp;return;
  15059. break;
  15060. }
  15061. default: {
  15062. $148 = +HEAPF32[744];
  15063. $149 = $148 + 4.9999998736893758E-5;
  15064. HEAPF32[744] = $149;
  15065. STACKTOP = sp;return;
  15066. }
  15067. }
  15068. }
  15069. function _rlVertex3f($0,$1,$2) {
  15070. $0 = +$0;
  15071. $1 = +$1;
  15072. $2 = +$2;
  15073. var $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0;
  15074. var $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0;
  15075. var $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer3 = 0, label = 0, sp = 0;
  15076. sp = STACKTOP;
  15077. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  15078. $vararg_buffer3 = sp + 16|0;
  15079. $vararg_buffer1 = sp + 8|0;
  15080. $vararg_buffer = sp;
  15081. $3 = HEAP32[5898]|0;
  15082. $4 = ($3|0)==(0);
  15083. if (!($4)) {
  15084. $5 = HEAP32[5458]|0;
  15085. $6 = HEAP32[5899]|0;
  15086. $7 = (($5) + (($6*12)|0)|0);
  15087. HEAPF32[$7>>2] = $0;
  15088. $8 = (((($5) + (($6*12)|0)|0)) + 4|0);
  15089. HEAPF32[$8>>2] = $1;
  15090. $9 = (((($5) + (($6*12)|0)|0)) + 8|0);
  15091. HEAPF32[$9>>2] = $2;
  15092. $10 = (($6) + 1)|0;
  15093. HEAP32[5899] = $10;
  15094. STACKTOP = sp;return;
  15095. }
  15096. $11 = HEAP32[5461]|0;
  15097. switch ($11|0) {
  15098. case 1: {
  15099. $12 = HEAP32[5720]|0;
  15100. $13 = ($12|0)<(2048);
  15101. if ($13) {
  15102. $14 = HEAP32[(22892)>>2]|0;
  15103. $15 = ($12*3)|0;
  15104. $16 = (($14) + ($15<<2)|0);
  15105. HEAPF32[$16>>2] = $0;
  15106. $17 = (($15) + 1)|0;
  15107. $18 = (($14) + ($17<<2)|0);
  15108. HEAPF32[$18>>2] = $1;
  15109. $19 = (($15) + 2)|0;
  15110. $20 = (($14) + ($19<<2)|0);
  15111. HEAPF32[$20>>2] = $2;
  15112. $21 = (($12) + 1)|0;
  15113. HEAP32[5720] = $21;
  15114. STACKTOP = sp;return;
  15115. } else {
  15116. _TraceLog(1,10463,$vararg_buffer);
  15117. STACKTOP = sp;return;
  15118. }
  15119. break;
  15120. }
  15121. case 4: {
  15122. $22 = HEAP32[5732]|0;
  15123. $23 = ($22|0)<(6144);
  15124. if ($23) {
  15125. $24 = HEAP32[(22940)>>2]|0;
  15126. $25 = ($22*3)|0;
  15127. $26 = (($24) + ($25<<2)|0);
  15128. HEAPF32[$26>>2] = $0;
  15129. $27 = (($25) + 1)|0;
  15130. $28 = (($24) + ($27<<2)|0);
  15131. HEAPF32[$28>>2] = $1;
  15132. $29 = (($25) + 2)|0;
  15133. $30 = (($24) + ($29<<2)|0);
  15134. HEAPF32[$30>>2] = $2;
  15135. $31 = (($22) + 1)|0;
  15136. HEAP32[5732] = $31;
  15137. STACKTOP = sp;return;
  15138. } else {
  15139. _TraceLog(1,10488,$vararg_buffer1);
  15140. STACKTOP = sp;return;
  15141. }
  15142. break;
  15143. }
  15144. case 7: {
  15145. $32 = HEAP32[5744]|0;
  15146. $33 = ($32|0)<(4096);
  15147. if ($33) {
  15148. $34 = HEAP32[(22988)>>2]|0;
  15149. $35 = ($32*3)|0;
  15150. $36 = (($34) + ($35<<2)|0);
  15151. HEAPF32[$36>>2] = $0;
  15152. $37 = (($35) + 1)|0;
  15153. $38 = (($34) + ($37<<2)|0);
  15154. HEAPF32[$38>>2] = $1;
  15155. $39 = (($35) + 2)|0;
  15156. $40 = (($34) + ($39<<2)|0);
  15157. HEAPF32[$40>>2] = $2;
  15158. $41 = (($32) + 1)|0;
  15159. HEAP32[5744] = $41;
  15160. $42 = HEAP32[5459]|0;
  15161. $43 = HEAP32[5460]|0;
  15162. $44 = (($43) + -1)|0;
  15163. $45 = (($42) + (($44*144)|0)|0);
  15164. $46 = HEAP32[$45>>2]|0;
  15165. $47 = (($46) + 1)|0;
  15166. HEAP32[$45>>2] = $47;
  15167. STACKTOP = sp;return;
  15168. } else {
  15169. _TraceLog(1,10517,$vararg_buffer3);
  15170. STACKTOP = sp;return;
  15171. }
  15172. break;
  15173. }
  15174. default: {
  15175. STACKTOP = sp;return;
  15176. }
  15177. }
  15178. }
  15179. function _rlVertex2f($0,$1) {
  15180. $0 = +$0;
  15181. $1 = +$1;
  15182. var $2 = 0.0, label = 0, sp = 0;
  15183. sp = STACKTOP;
  15184. $2 = +HEAPF32[744];
  15185. _rlVertex3f($0,$1,$2);
  15186. return;
  15187. }
  15188. function _rlVertex2i($0,$1) {
  15189. $0 = $0|0;
  15190. $1 = $1|0;
  15191. var $2 = 0.0, $3 = 0.0, $4 = 0.0, label = 0, sp = 0;
  15192. sp = STACKTOP;
  15193. $2 = (+($0|0));
  15194. $3 = (+($1|0));
  15195. $4 = +HEAPF32[744];
  15196. _rlVertex3f($2,$3,$4);
  15197. return;
  15198. }
  15199. function _rlTexCoord2f($0,$1) {
  15200. $0 = +$0;
  15201. $1 = +$1;
  15202. var $10 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  15203. sp = STACKTOP;
  15204. $2 = HEAP32[5461]|0;
  15205. $3 = ($2|0)==(7);
  15206. if (!($3)) {
  15207. return;
  15208. }
  15209. $4 = HEAP32[(22992)>>2]|0;
  15210. $5 = HEAP32[(22980)>>2]|0;
  15211. $6 = $5 << 1;
  15212. $7 = (($4) + ($6<<2)|0);
  15213. HEAPF32[$7>>2] = $0;
  15214. $8 = $6 | 1;
  15215. $9 = (($4) + ($8<<2)|0);
  15216. HEAPF32[$9>>2] = $1;
  15217. $10 = (($5) + 1)|0;
  15218. HEAP32[(22980)>>2] = $10;
  15219. return;
  15220. }
  15221. function _rlNormal3f($0,$1,$2) {
  15222. $0 = +$0;
  15223. $1 = +$1;
  15224. $2 = +$2;
  15225. var label = 0, sp = 0;
  15226. sp = STACKTOP;
  15227. return;
  15228. }
  15229. function _rlColor4ub($0,$1,$2,$3) {
  15230. $0 = $0|0;
  15231. $1 = $1|0;
  15232. $2 = $2|0;
  15233. $3 = $3|0;
  15234. var $$sink37 = 0, $$sink38 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $4 = 0, $5 = 0;
  15235. var $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  15236. sp = STACKTOP;
  15237. $4 = HEAP32[5461]|0;
  15238. switch ($4|0) {
  15239. case 1: {
  15240. $$sink37 = (22888);$$sink38 = (22900);
  15241. break;
  15242. }
  15243. case 4: {
  15244. $$sink37 = (22936);$$sink38 = (22948);
  15245. break;
  15246. }
  15247. case 7: {
  15248. $$sink37 = (22984);$$sink38 = (22996);
  15249. break;
  15250. }
  15251. default: {
  15252. return;
  15253. }
  15254. }
  15255. $5 = HEAP32[$$sink38>>2]|0;
  15256. $6 = HEAP32[$$sink37>>2]|0;
  15257. $7 = $6 << 2;
  15258. $8 = (($5) + ($7)|0);
  15259. HEAP8[$8>>0] = $0;
  15260. $9 = HEAP32[$$sink38>>2]|0;
  15261. $10 = HEAP32[$$sink37>>2]|0;
  15262. $11 = $10 << 2;
  15263. $12 = $11 | 1;
  15264. $13 = (($9) + ($12)|0);
  15265. HEAP8[$13>>0] = $1;
  15266. $14 = HEAP32[$$sink38>>2]|0;
  15267. $15 = HEAP32[$$sink37>>2]|0;
  15268. $16 = $15 << 2;
  15269. $17 = $16 | 2;
  15270. $18 = (($14) + ($17)|0);
  15271. HEAP8[$18>>0] = $2;
  15272. $19 = HEAP32[$$sink38>>2]|0;
  15273. $20 = HEAP32[$$sink37>>2]|0;
  15274. $21 = $20 << 2;
  15275. $22 = $21 | 3;
  15276. $23 = (($19) + ($22)|0);
  15277. HEAP8[$23>>0] = $3;
  15278. $24 = HEAP32[$$sink37>>2]|0;
  15279. $25 = (($24) + 1)|0;
  15280. HEAP32[$$sink37>>2] = $25;
  15281. return;
  15282. }
  15283. function _rlEnableTexture($0) {
  15284. $0 = $0|0;
  15285. var $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  15286. sp = STACKTOP;
  15287. $1 = HEAP32[5459]|0;
  15288. $2 = HEAP32[5460]|0;
  15289. $3 = (($2) + -1)|0;
  15290. $4 = (((($1) + (($3*144)|0)|0)) + 8|0);
  15291. $5 = HEAP32[$4>>2]|0;
  15292. $6 = ($5|0)==($0|0);
  15293. if ($6) {
  15294. return;
  15295. }
  15296. $7 = (($1) + (($3*144)|0)|0);
  15297. $8 = HEAP32[$7>>2]|0;
  15298. $9 = ($8|0)>(0);
  15299. if ($9) {
  15300. $10 = (($2) + 1)|0;
  15301. HEAP32[5460] = $10;
  15302. }
  15303. $11 = HEAP32[5460]|0;
  15304. $12 = (($11) + -1)|0;
  15305. $13 = (((($1) + (($12*144)|0)|0)) + 8|0);
  15306. HEAP32[$13>>2] = $0;
  15307. $14 = (($1) + (($12*144)|0)|0);
  15308. HEAP32[$14>>2] = 0;
  15309. return;
  15310. }
  15311. function _rlDisableTexture() {
  15312. var $0 = 0, $1 = 0, label = 0, sp = 0;
  15313. sp = STACKTOP;
  15314. $0 = HEAP32[5744]|0;
  15315. $1 = ($0|0)>(4095);
  15316. if (!($1)) {
  15317. return;
  15318. }
  15319. _rlglDraw();
  15320. return;
  15321. }
  15322. function _GetDefaultTexture($0) {
  15323. $0 = $0|0;
  15324. var $$sroa$4$0$$sroa_idx2 = 0, $$sroa$5$0$$sroa_idx4 = 0, $$sroa$6$0$$sroa_idx6 = 0, $$sroa$7$0$$sroa_idx8 = 0, $1 = 0, label = 0, sp = 0;
  15325. sp = STACKTOP;
  15326. $1 = HEAP32[5429]|0;
  15327. HEAP32[$0>>2] = $1;
  15328. $$sroa$4$0$$sroa_idx2 = ((($0)) + 4|0);
  15329. HEAP32[$$sroa$4$0$$sroa_idx2>>2] = 1;
  15330. $$sroa$5$0$$sroa_idx4 = ((($0)) + 8|0);
  15331. HEAP32[$$sroa$5$0$$sroa_idx4>>2] = 1;
  15332. $$sroa$6$0$$sroa_idx6 = ((($0)) + 12|0);
  15333. HEAP32[$$sroa$6$0$$sroa_idx6>>2] = 1;
  15334. $$sroa$7$0$$sroa_idx8 = ((($0)) + 16|0);
  15335. HEAP32[$$sroa$7$0$$sroa_idx8>>2] = 7;
  15336. return;
  15337. }
  15338. function _DrawRectangle($0,$1,$2,$3,$4) {
  15339. $0 = $0|0;
  15340. $1 = $1|0;
  15341. $2 = $2|0;
  15342. $3 = $3|0;
  15343. $4 = $4|0;
  15344. var $$byval_copy = 0, $$byval_copy1 = 0, $$byval_copy2 = 0, $10 = 0.0, $11 = 0, $12 = 0.0, $5 = 0, $6 = 0, $7 = 0.0, $8 = 0, $9 = 0.0, label = 0, sp = 0;
  15345. sp = STACKTOP;
  15346. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  15347. $$byval_copy2 = sp + 32|0;
  15348. $$byval_copy1 = sp + 24|0;
  15349. $$byval_copy = sp + 16|0;
  15350. $5 = sp + 8|0;
  15351. $6 = sp;
  15352. $7 = (+($0|0));
  15353. HEAPF32[$5>>2] = $7;
  15354. $8 = ((($5)) + 4|0);
  15355. $9 = (+($1|0));
  15356. HEAPF32[$8>>2] = $9;
  15357. $10 = (+($2|0));
  15358. HEAPF32[$6>>2] = $10;
  15359. $11 = ((($6)) + 4|0);
  15360. $12 = (+($3|0));
  15361. HEAPF32[$11>>2] = $12;
  15362. ;HEAP32[$$byval_copy>>2]=HEAP32[$5>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[$5+4>>2]|0;
  15363. ;HEAP32[$$byval_copy1>>2]=HEAP32[$6>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$6+4>>2]|0;
  15364. ;HEAP8[$$byval_copy2>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy2+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy2+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy2+3>>0]=HEAP8[$4+3>>0]|0;
  15365. _DrawRectangleV($$byval_copy,$$byval_copy1,$$byval_copy2);
  15366. STACKTOP = sp;return;
  15367. }
  15368. function _DrawRectangleV($0,$1,$2) {
  15369. $0 = $0|0;
  15370. $1 = $1|0;
  15371. $2 = $2|0;
  15372. var $10 = 0, $11 = 0, $12 = 0, $13 = 0.0, $14 = 0, $15 = 0, $16 = 0.0, $17 = 0, $18 = 0, $19 = 0.0, $20 = 0.0, $21 = 0, $22 = 0.0, $23 = 0.0, $24 = 0.0, $25 = 0, $26 = 0.0, $27 = 0.0, $28 = 0.0, $29 = 0;
  15373. var $3 = 0, $30 = 0.0, $31 = 0, $32 = 0.0, $33 = 0, $34 = 0.0, $35 = 0.0, $36 = 0, $37 = 0.0, $38 = 0.0, $39 = 0, $4 = 0, $40 = 0.0, $41 = 0.0, $42 = 0.0, $43 = 0, $44 = 0.0, $45 = 0, $46 = 0, $47 = 0;
  15374. var $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0.0, $61 = 0, $62 = 0.0, $63 = 0, $64 = 0.0, $65 = 0.0;
  15375. var $66 = 0.0, $67 = 0.0, $68 = 0.0, $69 = 0.0, $7 = 0, $70 = 0.0, $71 = 0.0, $72 = 0.0, $73 = 0.0, $74 = 0.0, $75 = 0.0, $8 = 0, $9 = 0, label = 0, sp = 0;
  15376. sp = STACKTOP;
  15377. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  15378. $3 = sp;
  15379. $4 = (_rlGetVersion()|0);
  15380. $5 = ($4|0)==(1);
  15381. if ($5) {
  15382. _rlBegin(4);
  15383. $6 = HEAP8[$2>>0]|0;
  15384. $7 = ((($2)) + 1|0);
  15385. $8 = HEAP8[$7>>0]|0;
  15386. $9 = ((($2)) + 2|0);
  15387. $10 = HEAP8[$9>>0]|0;
  15388. $11 = ((($2)) + 3|0);
  15389. $12 = HEAP8[$11>>0]|0;
  15390. _rlColor4ub($6,$8,$10,$12);
  15391. $13 = +HEAPF32[$0>>2];
  15392. $14 = (~~(($13)));
  15393. $15 = ((($0)) + 4|0);
  15394. $16 = +HEAPF32[$15>>2];
  15395. $17 = (~~(($16)));
  15396. _rlVertex2i($14,$17);
  15397. $18 = ((($1)) + 4|0);
  15398. $19 = +HEAPF32[$18>>2];
  15399. $20 = $16 + $19;
  15400. $21 = (~~(($20)));
  15401. _rlVertex2i($14,$21);
  15402. $22 = +HEAPF32[$0>>2];
  15403. $23 = +HEAPF32[$1>>2];
  15404. $24 = $22 + $23;
  15405. $25 = (~~(($24)));
  15406. $26 = +HEAPF32[$15>>2];
  15407. $27 = +HEAPF32[$18>>2];
  15408. $28 = $26 + $27;
  15409. $29 = (~~(($28)));
  15410. _rlVertex2i($25,$29);
  15411. $30 = +HEAPF32[$0>>2];
  15412. $31 = (~~(($30)));
  15413. $32 = +HEAPF32[$15>>2];
  15414. $33 = (~~(($32)));
  15415. _rlVertex2i($31,$33);
  15416. $34 = +HEAPF32[$1>>2];
  15417. $35 = $30 + $34;
  15418. $36 = (~~(($35)));
  15419. $37 = +HEAPF32[$18>>2];
  15420. $38 = $32 + $37;
  15421. $39 = (~~(($38)));
  15422. _rlVertex2i($36,$39);
  15423. $40 = +HEAPF32[$0>>2];
  15424. $41 = +HEAPF32[$1>>2];
  15425. $42 = $40 + $41;
  15426. $43 = (~~(($42)));
  15427. $44 = +HEAPF32[$15>>2];
  15428. $45 = (~~(($44)));
  15429. _rlVertex2i($43,$45);
  15430. _rlEnd();
  15431. STACKTOP = sp;return;
  15432. }
  15433. $46 = (_rlGetVersion()|0);
  15434. $47 = ($46|0)==(2);
  15435. if (!($47)) {
  15436. $48 = (_rlGetVersion()|0);
  15437. $49 = ($48|0)==(3);
  15438. if (!($49)) {
  15439. $50 = (_rlGetVersion()|0);
  15440. $51 = ($50|0)==(4);
  15441. if (!($51)) {
  15442. STACKTOP = sp;return;
  15443. }
  15444. }
  15445. }
  15446. _GetDefaultTexture($3);
  15447. $52 = HEAP32[$3>>2]|0;
  15448. _rlEnableTexture($52);
  15449. _rlBegin(7);
  15450. $53 = HEAP8[$2>>0]|0;
  15451. $54 = ((($2)) + 1|0);
  15452. $55 = HEAP8[$54>>0]|0;
  15453. $56 = ((($2)) + 2|0);
  15454. $57 = HEAP8[$56>>0]|0;
  15455. $58 = ((($2)) + 3|0);
  15456. $59 = HEAP8[$58>>0]|0;
  15457. _rlColor4ub($53,$55,$57,$59);
  15458. _rlTexCoord2f(0.0,0.0);
  15459. $60 = +HEAPF32[$0>>2];
  15460. $61 = ((($0)) + 4|0);
  15461. $62 = +HEAPF32[$61>>2];
  15462. _rlVertex2f($60,$62);
  15463. _rlTexCoord2f(0.0,1.0);
  15464. $63 = ((($1)) + 4|0);
  15465. $64 = +HEAPF32[$63>>2];
  15466. $65 = $62 + $64;
  15467. _rlVertex2f($60,$65);
  15468. _rlTexCoord2f(1.0,1.0);
  15469. $66 = +HEAPF32[$0>>2];
  15470. $67 = +HEAPF32[$1>>2];
  15471. $68 = $66 + $67;
  15472. $69 = +HEAPF32[$61>>2];
  15473. $70 = +HEAPF32[$63>>2];
  15474. $71 = $69 + $70;
  15475. _rlVertex2f($68,$71);
  15476. _rlTexCoord2f(1.0,0.0);
  15477. $72 = +HEAPF32[$0>>2];
  15478. $73 = +HEAPF32[$1>>2];
  15479. $74 = $72 + $73;
  15480. $75 = +HEAPF32[$61>>2];
  15481. _rlVertex2f($74,$75);
  15482. _rlEnd();
  15483. _rlDisableTexture();
  15484. STACKTOP = sp;return;
  15485. }
  15486. function _DrawRectangleLines($0,$1,$2,$3,$4) {
  15487. $0 = $0|0;
  15488. $1 = $1|0;
  15489. $2 = $2|0;
  15490. $3 = $3|0;
  15491. $4 = $4|0;
  15492. var $$byval_copy3 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0;
  15493. var $29 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  15494. sp = STACKTOP;
  15495. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  15496. $$byval_copy3 = sp;
  15497. $5 = (_rlGetVersion()|0);
  15498. $6 = ($5|0)==(1);
  15499. if ($6) {
  15500. _rlBegin(1);
  15501. $7 = HEAP8[$4>>0]|0;
  15502. $8 = ((($4)) + 1|0);
  15503. $9 = HEAP8[$8>>0]|0;
  15504. $10 = ((($4)) + 2|0);
  15505. $11 = HEAP8[$10>>0]|0;
  15506. $12 = ((($4)) + 3|0);
  15507. $13 = HEAP8[$12>>0]|0;
  15508. _rlColor4ub($7,$9,$11,$13);
  15509. $14 = (($0) + 1)|0;
  15510. $15 = (($1) + 1)|0;
  15511. _rlVertex2i($14,$15);
  15512. $16 = (($2) + ($0))|0;
  15513. _rlVertex2i($16,$15);
  15514. _rlVertex2i($16,$15);
  15515. $17 = (($3) + ($1))|0;
  15516. _rlVertex2i($16,$17);
  15517. _rlVertex2i($16,$17);
  15518. _rlVertex2i($14,$17);
  15519. _rlVertex2i($14,$17);
  15520. _rlVertex2i($14,$15);
  15521. _rlEnd();
  15522. STACKTOP = sp;return;
  15523. }
  15524. $18 = (_rlGetVersion()|0);
  15525. $19 = ($18|0)==(2);
  15526. if (!($19)) {
  15527. $20 = (_rlGetVersion()|0);
  15528. $21 = ($20|0)==(3);
  15529. if (!($21)) {
  15530. $22 = (_rlGetVersion()|0);
  15531. $23 = ($22|0)==(4);
  15532. if (!($23)) {
  15533. STACKTOP = sp;return;
  15534. }
  15535. }
  15536. }
  15537. ;HEAP8[$$byval_copy3>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$4+3>>0]|0;
  15538. _DrawRectangle($0,$1,$2,1,$$byval_copy3);
  15539. $24 = (($0) + -1)|0;
  15540. $25 = (($24) + ($2))|0;
  15541. $26 = (($1) + 1)|0;
  15542. $27 = (($3) + -2)|0;
  15543. ;HEAP8[$$byval_copy3>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$4+3>>0]|0;
  15544. _DrawRectangle($25,$26,1,$27,$$byval_copy3);
  15545. $28 = (($1) + -1)|0;
  15546. $29 = (($28) + ($3))|0;
  15547. ;HEAP8[$$byval_copy3>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$4+3>>0]|0;
  15548. _DrawRectangle($0,$29,$2,1,$$byval_copy3);
  15549. ;HEAP8[$$byval_copy3>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$4+3>>0]|0;
  15550. _DrawRectangle($0,$26,1,$27,$$byval_copy3);
  15551. STACKTOP = sp;return;
  15552. }
  15553. function _stbi__err($0) {
  15554. $0 = $0|0;
  15555. var label = 0, sp = 0;
  15556. sp = STACKTOP;
  15557. HEAP32[5900] = $0;
  15558. return;
  15559. }
  15560. function _stbi_load_from_file($0,$1,$2,$3,$4) {
  15561. $0 = $0|0;
  15562. $1 = $1|0;
  15563. $2 = $2|0;
  15564. $3 = $3|0;
  15565. $4 = $4|0;
  15566. var $10 = 0, $11 = 0, $12 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  15567. sp = STACKTOP;
  15568. STACKTOP = STACKTOP + 192|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(192|0);
  15569. $5 = sp;
  15570. _stbi__start_file($5,$0);
  15571. $6 = (_stbi__load_and_postprocess_8bit($5,$1,$2,$3,$4)|0);
  15572. $7 = ($6|0)==(0|0);
  15573. if ($7) {
  15574. STACKTOP = sp;return ($6|0);
  15575. }
  15576. $8 = ((($5)) + 172|0);
  15577. $9 = HEAP32[$8>>2]|0;
  15578. $10 = ((($5)) + 168|0);
  15579. $11 = HEAP32[$10>>2]|0;
  15580. $12 = (($11) - ($9))|0;
  15581. (_fseek($0,$12,1)|0);
  15582. STACKTOP = sp;return ($6|0);
  15583. }
  15584. function _stbi__start_file($0,$1) {
  15585. $0 = $0|0;
  15586. $1 = $1|0;
  15587. var label = 0, sp = 0;
  15588. sp = STACKTOP;
  15589. _stbi__start_callbacks($0,3092,$1);
  15590. return;
  15591. }
  15592. function _stbi__load_and_postprocess_8bit($0,$1,$2,$3,$4) {
  15593. $0 = $0|0;
  15594. $1 = $1|0;
  15595. $2 = $2|0;
  15596. $3 = $3|0;
  15597. $4 = $4|0;
  15598. var $$0 = 0, $$070 = 0, $$07175 = 0, $$07276 = 0, $$07378 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0;
  15599. var $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $5 = 0, $6 = 0;
  15600. var $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond79 = 0, $exitcond80 = 0, label = 0, sp = 0;
  15601. sp = STACKTOP;
  15602. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  15603. $5 = sp;
  15604. $6 = (_stbi__load_main($0,$1,$2,$3,$4,$5)|0);
  15605. $7 = ($6|0)==(0|0);
  15606. if ($7) {
  15607. $$0 = 0;
  15608. STACKTOP = sp;return ($$0|0);
  15609. }
  15610. $8 = HEAP32[$5>>2]|0;
  15611. switch ($8|0) {
  15612. case 8: {
  15613. $$070 = $6;
  15614. break;
  15615. }
  15616. case 16: {
  15617. label = 4;
  15618. break;
  15619. }
  15620. default: {
  15621. ___assert_fail((10542|0),(10568|0),1041,(10591|0));
  15622. // unreachable;
  15623. }
  15624. }
  15625. if ((label|0) == 4) {
  15626. $9 = HEAP32[$1>>2]|0;
  15627. $10 = HEAP32[$2>>2]|0;
  15628. $11 = ($4|0)==(0);
  15629. if ($11) {
  15630. $12 = HEAP32[$3>>2]|0;
  15631. $13 = $12;
  15632. } else {
  15633. $13 = $4;
  15634. }
  15635. $14 = (_stbi__convert_16_to_8($6,$9,$10,$13)|0);
  15636. HEAP32[$5>>2] = 8;
  15637. $$070 = $14;
  15638. }
  15639. $15 = HEAP32[5901]|0;
  15640. $16 = ($15|0)==(0);
  15641. if ($16) {
  15642. $$0 = $$070;
  15643. STACKTOP = sp;return ($$0|0);
  15644. }
  15645. $17 = HEAP32[$1>>2]|0;
  15646. $18 = HEAP32[$2>>2]|0;
  15647. $19 = ($4|0)==(0);
  15648. if ($19) {
  15649. $20 = HEAP32[$3>>2]|0;
  15650. $25 = $20;
  15651. } else {
  15652. $25 = $4;
  15653. }
  15654. $21 = $18 >> 1;
  15655. $22 = ($21|0)>(0);
  15656. if (!($22)) {
  15657. $$0 = $$070;
  15658. STACKTOP = sp;return ($$0|0);
  15659. }
  15660. $23 = ($17|0)>(0);
  15661. $24 = ($25|0)>(0);
  15662. $26 = (($18) + -1)|0;
  15663. $$07378 = 0;
  15664. while(1) {
  15665. if ($23) {
  15666. $27 = Math_imul($$07378, $17)|0;
  15667. $28 = (($26) - ($$07378))|0;
  15668. $29 = Math_imul($28, $17)|0;
  15669. $$07276 = 0;
  15670. while(1) {
  15671. if ($24) {
  15672. $30 = (($$07276) + ($27))|0;
  15673. $31 = Math_imul($30, $25)|0;
  15674. $32 = (($$07276) + ($29))|0;
  15675. $33 = Math_imul($32, $25)|0;
  15676. $$07175 = 0;
  15677. while(1) {
  15678. $34 = (($$07175) + ($31))|0;
  15679. $35 = (($$070) + ($34)|0);
  15680. $36 = HEAP8[$35>>0]|0;
  15681. $37 = (($$07175) + ($33))|0;
  15682. $38 = (($$070) + ($37)|0);
  15683. $39 = HEAP8[$38>>0]|0;
  15684. HEAP8[$35>>0] = $39;
  15685. HEAP8[$38>>0] = $36;
  15686. $40 = (($$07175) + 1)|0;
  15687. $exitcond = ($40|0)==($25|0);
  15688. if ($exitcond) {
  15689. break;
  15690. } else {
  15691. $$07175 = $40;
  15692. }
  15693. }
  15694. }
  15695. $41 = (($$07276) + 1)|0;
  15696. $exitcond79 = ($41|0)==($17|0);
  15697. if ($exitcond79) {
  15698. break;
  15699. } else {
  15700. $$07276 = $41;
  15701. }
  15702. }
  15703. }
  15704. $42 = (($$07378) + 1)|0;
  15705. $exitcond80 = ($42|0)==($21|0);
  15706. if ($exitcond80) {
  15707. $$0 = $$070;
  15708. break;
  15709. } else {
  15710. $$07378 = $42;
  15711. }
  15712. }
  15713. STACKTOP = sp;return ($$0|0);
  15714. }
  15715. function _stbi__load_main($0,$1,$2,$3,$4,$5) {
  15716. $0 = $0|0;
  15717. $1 = $1|0;
  15718. $2 = $2|0;
  15719. $3 = $3|0;
  15720. $4 = $4|0;
  15721. $5 = $5|0;
  15722. var $$0 = 0, $10 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  15723. sp = STACKTOP;
  15724. HEAP32[$5>>2] = 8;
  15725. $6 = ((($5)) + 8|0);
  15726. HEAP32[$6>>2] = 0;
  15727. $7 = ((($5)) + 4|0);
  15728. HEAP32[$7>>2] = 0;
  15729. $8 = (_stbi__png_test($0)|0);
  15730. $9 = ($8|0)==(0);
  15731. if ($9) {
  15732. _stbi__err(10632);
  15733. $$0 = 0;
  15734. return ($$0|0);
  15735. } else {
  15736. $10 = (_stbi__png_load($0,$1,$2,$3,$4,$5)|0);
  15737. $$0 = $10;
  15738. return ($$0|0);
  15739. }
  15740. return (0)|0;
  15741. }
  15742. function _stbi__convert_16_to_8($0,$1,$2,$3) {
  15743. $0 = $0|0;
  15744. $1 = $1|0;
  15745. $2 = $2|0;
  15746. $3 = $3|0;
  15747. var $$0 = 0, $$01819 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, label = 0, sp = 0;
  15748. sp = STACKTOP;
  15749. $4 = Math_imul($2, $1)|0;
  15750. $5 = Math_imul($4, $3)|0;
  15751. $6 = (_stbi__malloc($5)|0);
  15752. $7 = ($6|0)==(0|0);
  15753. if ($7) {
  15754. _stbi__err(10623);
  15755. $$0 = 0;
  15756. return ($$0|0);
  15757. }
  15758. $8 = ($5|0)>(0);
  15759. if ($8) {
  15760. $$01819 = 0;
  15761. while(1) {
  15762. $9 = (($0) + ($$01819<<1)|0);
  15763. $10 = HEAP16[$9>>1]|0;
  15764. $11 = ($10&65535) >>> 8;
  15765. $12 = $11&255;
  15766. $13 = (($6) + ($$01819)|0);
  15767. HEAP8[$13>>0] = $12;
  15768. $14 = (($$01819) + 1)|0;
  15769. $exitcond = ($14|0)==($5|0);
  15770. if ($exitcond) {
  15771. break;
  15772. } else {
  15773. $$01819 = $14;
  15774. }
  15775. }
  15776. }
  15777. _free($0);
  15778. $$0 = $6;
  15779. return ($$0|0);
  15780. }
  15781. function _stbi__malloc($0) {
  15782. $0 = $0|0;
  15783. var $1 = 0, label = 0, sp = 0;
  15784. sp = STACKTOP;
  15785. $1 = (_malloc($0)|0);
  15786. return ($1|0);
  15787. }
  15788. function _stbi__png_test($0) {
  15789. $0 = $0|0;
  15790. var $1 = 0, label = 0, sp = 0;
  15791. sp = STACKTOP;
  15792. $1 = (_stbi__check_png_header($0)|0);
  15793. _stbi__rewind($0);
  15794. return ($1|0);
  15795. }
  15796. function _stbi__png_load($0,$1,$2,$3,$4,$5) {
  15797. $0 = $0|0;
  15798. $1 = $1|0;
  15799. $2 = $2|0;
  15800. $3 = $3|0;
  15801. $4 = $4|0;
  15802. $5 = $5|0;
  15803. var $6 = 0, $7 = 0, label = 0, sp = 0;
  15804. sp = STACKTOP;
  15805. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  15806. $6 = sp;
  15807. HEAP32[$6>>2] = $0;
  15808. $7 = (_stbi__do_png($6,$1,$2,$3,$4,$5)|0);
  15809. STACKTOP = sp;return ($7|0);
  15810. }
  15811. function _stbi__do_png($0,$1,$2,$3,$4,$5) {
  15812. $0 = $0|0;
  15813. $1 = $1|0;
  15814. $2 = $2|0;
  15815. $3 = $3|0;
  15816. $4 = $4|0;
  15817. $5 = $5|0;
  15818. var $$ = 0, $$0 = 0, $$045 = 0, $$1 = 0, $$2 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0;
  15819. var $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $6 = 0, $7 = 0, $8 = 0;
  15820. var $9 = 0, label = 0, sp = 0;
  15821. sp = STACKTOP;
  15822. $6 = ($4>>>0)>(4);
  15823. if ($6) {
  15824. _stbi__err(10651);
  15825. $$045 = 0;
  15826. return ($$045|0);
  15827. }
  15828. $7 = (_stbi__parse_png_file($0,0,$4)|0);
  15829. $8 = ($7|0)==(0);
  15830. if ($8) {
  15831. $$2 = 0;
  15832. } else {
  15833. $9 = ((($0)) + 16|0);
  15834. $10 = HEAP32[$9>>2]|0;
  15835. $11 = ($10|0)>(8);
  15836. $$ = $11 ? $10 : 8;
  15837. HEAP32[$5>>2] = $$;
  15838. $12 = ((($0)) + 12|0);
  15839. $13 = HEAP32[$12>>2]|0;
  15840. HEAP32[$12>>2] = 0;
  15841. $14 = ($4|0)==(0);
  15842. if ($14) {
  15843. $$1 = $13;
  15844. } else {
  15845. $15 = HEAP32[$0>>2]|0;
  15846. $16 = ((($15)) + 12|0);
  15847. $17 = HEAP32[$16>>2]|0;
  15848. $18 = ($17|0)==($4|0);
  15849. if ($18) {
  15850. $$1 = $13;
  15851. } else {
  15852. $19 = HEAP32[$5>>2]|0;
  15853. $20 = ($19|0)==(8);
  15854. $21 = ((($15)) + 4|0);
  15855. $22 = HEAP32[$21>>2]|0;
  15856. $23 = HEAP32[$15>>2]|0;
  15857. if ($20) {
  15858. $24 = (_stbi__convert_format($13,$17,$4,$23,$22)|0);
  15859. $$0 = $24;
  15860. } else {
  15861. $25 = (_stbi__convert_format16($13,$17,$4,$23,$22)|0);
  15862. $$0 = $25;
  15863. }
  15864. $26 = HEAP32[$0>>2]|0;
  15865. $27 = ((($26)) + 12|0);
  15866. HEAP32[$27>>2] = $4;
  15867. $28 = ($$0|0)==(0|0);
  15868. if ($28) {
  15869. $$045 = 0;
  15870. return ($$045|0);
  15871. } else {
  15872. $$1 = $$0;
  15873. }
  15874. }
  15875. }
  15876. $29 = HEAP32[$0>>2]|0;
  15877. $30 = HEAP32[$29>>2]|0;
  15878. HEAP32[$1>>2] = $30;
  15879. $31 = ((($29)) + 4|0);
  15880. $32 = HEAP32[$31>>2]|0;
  15881. HEAP32[$2>>2] = $32;
  15882. $33 = ($3|0)==(0|0);
  15883. if ($33) {
  15884. $$2 = $$1;
  15885. } else {
  15886. $34 = ((($29)) + 8|0);
  15887. $35 = HEAP32[$34>>2]|0;
  15888. HEAP32[$3>>2] = $35;
  15889. $$2 = $$1;
  15890. }
  15891. }
  15892. $36 = ((($0)) + 12|0);
  15893. $37 = HEAP32[$36>>2]|0;
  15894. _free($37);
  15895. HEAP32[$36>>2] = 0;
  15896. $38 = ((($0)) + 8|0);
  15897. $39 = HEAP32[$38>>2]|0;
  15898. _free($39);
  15899. HEAP32[$38>>2] = 0;
  15900. $40 = ((($0)) + 4|0);
  15901. $41 = HEAP32[$40>>2]|0;
  15902. _free($41);
  15903. HEAP32[$40>>2] = 0;
  15904. $$045 = $$2;
  15905. return ($$045|0);
  15906. }
  15907. function _stbi__parse_png_file($0,$1,$2) {
  15908. $0 = $0|0;
  15909. $1 = $1|0;
  15910. $2 = $2|0;
  15911. var $$ = 0, $$$0217 = 0, $$0206 = 0, $$0211 = 0, $$0214 = 0, $$0217 = 0, $$0226593 = 0, $$0228 = 0, $$0231 = 0, $$0235 = 0, $$0239591 = 0, $$0241 = 0, $$0245 = 0, $$1207 = 0, $$1212 = 0, $$1215 = 0, $$1218 = 0, $$1227588 = 0, $$1229 = 0, $$1240589 = 0;
  15912. var $$1246 = 0, $$2219 = 0, $$2233 = 0, $$2237 = 0, $$2243 = 0, $$254 = 0, $$3209 = 0, $$3220 = 0, $$4 = 0, $$6$ph = 0, $$7 = 0, $$lobit = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0;
  15913. var $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0;
  15914. var $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0;
  15915. var $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0;
  15916. var $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0;
  15917. var $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0;
  15918. var $198 = 0, $199 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $22 = 0, $23 = 0;
  15919. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  15920. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0;
  15921. var $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0;
  15922. var $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0;
  15923. var $97 = 0, $98 = 0, $99 = 0, $notlhs = 0, $notrhs = 0, $or$cond = 0, $or$cond11 = 0, $or$cond248 = 0, $or$cond5$not = 0, $or$cond7 = 0, $switch$split112D = 0, $switch$split142D = 0, $switch$split2D = 0, $switch$split52D = 0, $switch$split82D = 0, label = 0, sp = 0;
  15924. sp = STACKTOP;
  15925. STACKTOP = STACKTOP + 1056|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(1056|0);
  15926. $3 = sp + 32|0;
  15927. $4 = sp + 22|0;
  15928. $5 = sp + 16|0;
  15929. $6 = sp + 8|0;
  15930. $7 = sp;
  15931. $8 = HEAP32[$0>>2]|0;
  15932. $9 = ((($0)) + 8|0);
  15933. HEAP32[$9>>2] = 0;
  15934. $10 = ((($0)) + 4|0);
  15935. HEAP32[$10>>2] = 0;
  15936. $11 = ((($0)) + 12|0);
  15937. HEAP32[$11>>2] = 0;
  15938. $12 = (_stbi__check_png_header($8)|0);
  15939. $13 = ($12|0)==(0);
  15940. if ($13) {
  15941. $$7 = 0;
  15942. STACKTOP = sp;return ($$7|0);
  15943. }
  15944. $14 = ($1|0)==(1);
  15945. if ($14) {
  15946. $$7 = 1;
  15947. STACKTOP = sp;return ($$7|0);
  15948. }
  15949. $15 = ((($6)) + 4|0);
  15950. $16 = ((($8)) + 4|0);
  15951. $17 = ((($0)) + 16|0);
  15952. $18 = ((($8)) + 8|0);
  15953. $19 = ($1|0)==(2);
  15954. $20 = ((($8)) + 8|0);
  15955. $21 = ((($8)) + 8|0);
  15956. $22 = ((($0)) + 16|0);
  15957. $23 = ($1|0)==(2);
  15958. $24 = ($1|0)==(2);
  15959. $$0206 = 0;$$0211 = 0;$$0214 = 0;$$0217 = 0;$$0228 = 0;$$0231 = 0;$$0235 = 0;$$0241 = 1;$$0245 = 0;
  15960. L7: while(1) {
  15961. _stbi__get_chunk_header($6,$8);
  15962. $25 = HEAP32[$15>>2]|0;
  15963. $switch$split2D = ($25|0)<(1229472850);
  15964. L9: do {
  15965. if ($switch$split2D) {
  15966. $switch$split52D = ($25|0)<(1229209940);
  15967. if ($switch$split52D) {
  15968. switch ($25|0) {
  15969. case 1130840649: {
  15970. break;
  15971. }
  15972. default: {
  15973. label = 103;
  15974. break L9;
  15975. }
  15976. }
  15977. $26 = HEAP32[$6>>2]|0;
  15978. _stbi__skip($8,$26);
  15979. $$1212 = $$0211;$$1215 = $$0214;$$1229 = 1;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = $$0241;$$3209 = $$0206;$$3220 = $$0217;
  15980. break;
  15981. }
  15982. $switch$split112D = ($25|0)<(1229278788);
  15983. if (!($switch$split112D)) {
  15984. switch ($25|0) {
  15985. case 1229278788: {
  15986. label = 85;
  15987. break L7;
  15988. break;
  15989. }
  15990. default: {
  15991. label = 103;
  15992. break L9;
  15993. }
  15994. }
  15995. }
  15996. switch ($25|0) {
  15997. case 1229209940: {
  15998. break;
  15999. }
  16000. default: {
  16001. label = 103;
  16002. break L9;
  16003. }
  16004. }
  16005. $130 = ($$0241|0)==(0);
  16006. if (!($130)) {
  16007. label = 70;
  16008. break L7;
  16009. }
  16010. $131 = ($$0206<<24>>24)==(0);
  16011. $132 = ($$0245|0)!=(0);
  16012. $or$cond = $132 | $131;
  16013. if (!($or$cond)) {
  16014. label = 72;
  16015. break L7;
  16016. }
  16017. if ($24) {
  16018. label = 74;
  16019. break L7;
  16020. }
  16021. $135 = HEAP32[$6>>2]|0;
  16022. $136 = (($135) + ($$0214))|0;
  16023. $137 = ($136|0)<($$0214|0);
  16024. if ($137) {
  16025. $$6$ph = 0;
  16026. break L7;
  16027. }
  16028. $138 = ($136>>>0)>($$0217>>>0);
  16029. if ($138) {
  16030. $139 = ($$0217|0)==(0);
  16031. $140 = ($135>>>0)>(4096);
  16032. $141 = $140 ? $135 : 4096;
  16033. $$$0217 = $139 ? $141 : $$0217;
  16034. $142 = HEAP32[$6>>2]|0;
  16035. $143 = (($142) + ($$0214))|0;
  16036. $$1218 = $$$0217;
  16037. while(1) {
  16038. $144 = ($143>>>0)>($$1218>>>0);
  16039. $145 = $$1218 << 1;
  16040. if ($144) {
  16041. $$1218 = $145;
  16042. } else {
  16043. break;
  16044. }
  16045. }
  16046. $146 = HEAP32[$10>>2]|0;
  16047. $147 = (_realloc($146,$$1218)|0);
  16048. $148 = ($147|0)==(0|0);
  16049. if ($148) {
  16050. label = 81;
  16051. break L7;
  16052. }
  16053. HEAP32[$10>>2] = $147;
  16054. $$2219 = $$1218;
  16055. } else {
  16056. $$2219 = $$0217;
  16057. }
  16058. $149 = HEAP32[$10>>2]|0;
  16059. $150 = (($149) + ($$0214)|0);
  16060. $151 = HEAP32[$6>>2]|0;
  16061. $152 = (_stbi__getn($8,$150,$151)|0);
  16062. $153 = ($152|0)==(0);
  16063. if ($153) {
  16064. label = 83;
  16065. break L7;
  16066. }
  16067. $154 = HEAP32[$6>>2]|0;
  16068. $155 = (($154) + ($$0214))|0;
  16069. $$1212 = $$0211;$$1215 = $155;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = $$0241;$$3209 = $$0206;$$3220 = $$2219;
  16070. } else {
  16071. $switch$split82D = ($25|0)<(1347179589);
  16072. if ($switch$split82D) {
  16073. switch ($25|0) {
  16074. case 1229472850: {
  16075. break;
  16076. }
  16077. default: {
  16078. label = 103;
  16079. break L9;
  16080. }
  16081. }
  16082. $27 = ($$0241|0)==(0);
  16083. if ($27) {
  16084. label = 7;
  16085. break L7;
  16086. }
  16087. $28 = HEAP32[$6>>2]|0;
  16088. $29 = ($28|0)==(13);
  16089. if (!($29)) {
  16090. label = 9;
  16091. break L7;
  16092. }
  16093. $30 = (_stbi__get32be($8)|0);
  16094. HEAP32[$8>>2] = $30;
  16095. $31 = ($30>>>0)>(16777216);
  16096. if ($31) {
  16097. label = 11;
  16098. break L7;
  16099. }
  16100. $32 = (_stbi__get32be($8)|0);
  16101. HEAP32[$16>>2] = $32;
  16102. $33 = ($32>>>0)>(16777216);
  16103. if ($33) {
  16104. label = 13;
  16105. break L7;
  16106. }
  16107. $34 = (_stbi__get8($8)|0);
  16108. $35 = $34&255;
  16109. HEAP32[$17>>2] = $35;
  16110. switch ($34<<24>>24) {
  16111. case 16: case 8: case 4: case 2: case 1: {
  16112. break;
  16113. }
  16114. default: {
  16115. label = 15;
  16116. break L7;
  16117. }
  16118. }
  16119. $36 = (_stbi__get8($8)|0);
  16120. $37 = $36&255;
  16121. $38 = ($36&255)>(6);
  16122. if ($38) {
  16123. label = 17;
  16124. break L7;
  16125. }
  16126. $39 = ($36<<24>>24)==(3);
  16127. if ($39) {
  16128. $40 = HEAP32[$17>>2]|0;
  16129. $41 = ($40|0)==(16);
  16130. if ($41) {
  16131. label = 20;
  16132. break L7;
  16133. } else {
  16134. $$1207 = 3;
  16135. }
  16136. } else {
  16137. $42 = $37 & 1;
  16138. $43 = ($42|0)==(0);
  16139. if ($43) {
  16140. $$1207 = $$0206;
  16141. } else {
  16142. label = 22;
  16143. break L7;
  16144. }
  16145. }
  16146. $44 = (_stbi__get8($8)|0);
  16147. $45 = ($44<<24>>24)==(0);
  16148. if (!($45)) {
  16149. label = 24;
  16150. break L7;
  16151. }
  16152. $46 = (_stbi__get8($8)|0);
  16153. $47 = ($46<<24>>24)==(0);
  16154. if (!($47)) {
  16155. label = 26;
  16156. break L7;
  16157. }
  16158. $48 = (_stbi__get8($8)|0);
  16159. $49 = $48&255;
  16160. $50 = ($48&255)>(1);
  16161. if ($50) {
  16162. label = 28;
  16163. break L7;
  16164. }
  16165. $51 = HEAP32[$8>>2]|0;
  16166. $52 = ($51|0)==(0);
  16167. if ($52) {
  16168. label = 31;
  16169. break L7;
  16170. }
  16171. $53 = HEAP32[$16>>2]|0;
  16172. $54 = ($53|0)==(0);
  16173. if ($54) {
  16174. label = 31;
  16175. break L7;
  16176. }
  16177. $55 = ($$1207<<24>>24)==(0);
  16178. $56 = (1073741824 / ($51>>>0))&-1;
  16179. if (!($55)) {
  16180. HEAP32[$20>>2] = 1;
  16181. $63 = $56 >>> 2;
  16182. $64 = ($63>>>0)<($53>>>0);
  16183. if ($64) {
  16184. label = 37;
  16185. break L7;
  16186. } else {
  16187. $$1212 = $$0211;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $37;$$2237 = $49;$$2243 = 0;$$3209 = $$1207;$$3220 = $$0217;
  16188. break;
  16189. }
  16190. }
  16191. $57 = $37 & 2;
  16192. $58 = $57 | 1;
  16193. $59 = $37 >>> 2;
  16194. $$lobit = $59 & 1;
  16195. $60 = (($58) + ($$lobit))|0;
  16196. HEAP32[$18>>2] = $60;
  16197. $61 = (($56>>>0) / ($60>>>0))&-1;
  16198. $62 = ($61>>>0)<($53>>>0);
  16199. if ($62) {
  16200. label = 34;
  16201. break L7;
  16202. }
  16203. if ($19) {
  16204. $$6$ph = 1;
  16205. break L7;
  16206. } else {
  16207. $$1212 = $$0211;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $37;$$2237 = $49;$$2243 = 0;$$3209 = 0;$$3220 = $$0217;
  16208. break;
  16209. }
  16210. }
  16211. $switch$split142D = ($25|0)<(1951551059);
  16212. if ($switch$split142D) {
  16213. switch ($25|0) {
  16214. case 1347179589: {
  16215. break;
  16216. }
  16217. default: {
  16218. label = 103;
  16219. break L9;
  16220. }
  16221. }
  16222. $65 = ($$0241|0)==(0);
  16223. if (!($65)) {
  16224. label = 39;
  16225. break L7;
  16226. }
  16227. $66 = HEAP32[$6>>2]|0;
  16228. $67 = ($66>>>0)>(768);
  16229. if ($67) {
  16230. label = 41;
  16231. break L7;
  16232. }
  16233. $68 = (($66>>>0) / 3)&-1;
  16234. $69 = ($68*3)|0;
  16235. $70 = ($69|0)==($66|0);
  16236. if (!($70)) {
  16237. label = 44;
  16238. break L7;
  16239. }
  16240. $71 = ($66>>>0)>(2);
  16241. if ($71) {
  16242. $$0226593 = 0;
  16243. } else {
  16244. $$1212 = $$0211;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $68;$$2233 = $$0231;$$2237 = $$0235;$$2243 = 0;$$3209 = $$0206;$$3220 = $$0217;
  16245. break;
  16246. }
  16247. while(1) {
  16248. $72 = (_stbi__get8($8)|0);
  16249. $73 = $$0226593 << 2;
  16250. $74 = (($3) + ($73)|0);
  16251. HEAP8[$74>>0] = $72;
  16252. $75 = (_stbi__get8($8)|0);
  16253. $76 = $73 | 1;
  16254. $77 = (($3) + ($76)|0);
  16255. HEAP8[$77>>0] = $75;
  16256. $78 = (_stbi__get8($8)|0);
  16257. $79 = $73 | 2;
  16258. $80 = (($3) + ($79)|0);
  16259. HEAP8[$80>>0] = $78;
  16260. $81 = $73 | 3;
  16261. $82 = (($3) + ($81)|0);
  16262. HEAP8[$82>>0] = -1;
  16263. $83 = (($$0226593) + 1)|0;
  16264. $84 = ($83>>>0)<($68>>>0);
  16265. if ($84) {
  16266. $$0226593 = $83;
  16267. } else {
  16268. $$1212 = $$0211;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $68;$$2233 = $$0231;$$2237 = $$0235;$$2243 = $$0241;$$3209 = $$0206;$$3220 = $$0217;
  16269. break L9;
  16270. }
  16271. }
  16272. }
  16273. switch ($25|0) {
  16274. case 1951551059: {
  16275. break;
  16276. }
  16277. default: {
  16278. label = 103;
  16279. break L9;
  16280. }
  16281. }
  16282. $85 = ($$0241|0)==(0);
  16283. if (!($85)) {
  16284. label = 47;
  16285. break L7;
  16286. }
  16287. $86 = HEAP32[$10>>2]|0;
  16288. $87 = ($86|0)==(0|0);
  16289. if (!($87)) {
  16290. label = 49;
  16291. break L7;
  16292. }
  16293. $88 = ($$0206<<24>>24)==(0);
  16294. if (!($88)) {
  16295. if ($23) {
  16296. label = 52;
  16297. break L7;
  16298. }
  16299. $90 = ($$0245|0)==(0);
  16300. if ($90) {
  16301. label = 54;
  16302. break L7;
  16303. }
  16304. $91 = HEAP32[$6>>2]|0;
  16305. $92 = ($91>>>0)>($$0245>>>0);
  16306. if ($92) {
  16307. label = 58;
  16308. break L7;
  16309. }
  16310. $93 = HEAP32[$6>>2]|0;
  16311. $94 = ($93|0)==(0);
  16312. if ($94) {
  16313. $$1212 = $$0211;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = 0;$$3209 = 4;$$3220 = $$0217;
  16314. break;
  16315. }
  16316. $95 = HEAP32[$6>>2]|0;
  16317. $$1227588 = 0;
  16318. while(1) {
  16319. $96 = (_stbi__get8($8)|0);
  16320. $97 = $$1227588 << 2;
  16321. $98 = $97 | 3;
  16322. $99 = (($3) + ($98)|0);
  16323. HEAP8[$99>>0] = $96;
  16324. $100 = (($$1227588) + 1)|0;
  16325. $101 = ($100>>>0)<($95>>>0);
  16326. if ($101) {
  16327. $$1227588 = $100;
  16328. } else {
  16329. $$1212 = $$0211;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = $$0241;$$3209 = 4;$$3220 = $$0217;
  16330. break L9;
  16331. }
  16332. }
  16333. }
  16334. $102 = HEAP32[$21>>2]|0;
  16335. $103 = $102 & 1;
  16336. $104 = ($103|0)==(0);
  16337. if ($104) {
  16338. label = 61;
  16339. break L7;
  16340. }
  16341. $105 = HEAP32[$6>>2]|0;
  16342. $106 = $102 << 1;
  16343. $107 = ($105|0)==($106|0);
  16344. if (!($107)) {
  16345. label = 63;
  16346. break L7;
  16347. }
  16348. $108 = HEAP32[$22>>2]|0;
  16349. $109 = ($108|0)==(16);
  16350. $110 = HEAP32[$21>>2]|0;
  16351. $111 = ($110|0)>(0);
  16352. if ($109) {
  16353. if ($111) {
  16354. $$0239591 = 0;
  16355. } else {
  16356. $$1212 = 1;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = 0;$$3209 = 0;$$3220 = $$0217;
  16357. break;
  16358. }
  16359. while(1) {
  16360. $112 = (_stbi__get16be($8)|0);
  16361. $113 = $112&65535;
  16362. $114 = (($5) + ($$0239591<<1)|0);
  16363. HEAP16[$114>>1] = $113;
  16364. $115 = (($$0239591) + 1)|0;
  16365. $116 = HEAP32[$21>>2]|0;
  16366. $117 = ($115|0)<($116|0);
  16367. if ($117) {
  16368. $$0239591 = $115;
  16369. } else {
  16370. $$1212 = 1;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = $$0241;$$3209 = $$0206;$$3220 = $$0217;
  16371. break;
  16372. }
  16373. }
  16374. } else {
  16375. if ($111) {
  16376. $$1240589 = 0;
  16377. } else {
  16378. $$1212 = 1;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = 0;$$3209 = 0;$$3220 = $$0217;
  16379. break;
  16380. }
  16381. while(1) {
  16382. $118 = (_stbi__get16be($8)|0);
  16383. $119 = $118 & 255;
  16384. $120 = HEAP32[$22>>2]|0;
  16385. $121 = (10967 + ($120)|0);
  16386. $122 = HEAP8[$121>>0]|0;
  16387. $123 = $122&255;
  16388. $124 = Math_imul($123, $119)|0;
  16389. $125 = $124&255;
  16390. $126 = (($4) + ($$1240589)|0);
  16391. HEAP8[$126>>0] = $125;
  16392. $127 = (($$1240589) + 1)|0;
  16393. $128 = HEAP32[$21>>2]|0;
  16394. $129 = ($127|0)<($128|0);
  16395. if ($129) {
  16396. $$1240589 = $127;
  16397. } else {
  16398. $$1212 = 1;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = $$0241;$$3209 = $$0206;$$3220 = $$0217;
  16399. break;
  16400. }
  16401. }
  16402. }
  16403. }
  16404. } while(0);
  16405. if ((label|0) == 103) {
  16406. label = 0;
  16407. $202 = ($$0241|0)==(0);
  16408. if (!($202)) {
  16409. label = 104;
  16410. break;
  16411. }
  16412. $203 = $25 & 536870912;
  16413. $204 = ($203|0)==(0);
  16414. if ($204) {
  16415. label = 106;
  16416. break;
  16417. }
  16418. $213 = HEAP32[$6>>2]|0;
  16419. _stbi__skip($8,$213);
  16420. $$1212 = $$0211;$$1215 = $$0214;$$1229 = $$0228;$$1246 = $$0245;$$2233 = $$0231;$$2237 = $$0235;$$2243 = 0;$$3209 = $$0206;$$3220 = $$0217;
  16421. }
  16422. (_stbi__get32be($8)|0);
  16423. $$0206 = $$3209;$$0211 = $$1212;$$0214 = $$1215;$$0217 = $$3220;$$0228 = $$1229;$$0231 = $$2233;$$0235 = $$2237;$$0241 = $$2243;$$0245 = $$1246;
  16424. }
  16425. switch (label|0) {
  16426. case 7: {
  16427. _stbi__err(10741);
  16428. $$6$ph = 0;
  16429. break;
  16430. }
  16431. case 9: {
  16432. _stbi__err(10755);
  16433. $$6$ph = 0;
  16434. break;
  16435. }
  16436. case 11: {
  16437. _stbi__err(10768);
  16438. $$6$ph = 0;
  16439. break;
  16440. }
  16441. case 13: {
  16442. _stbi__err(10768);
  16443. $$6$ph = 0;
  16444. break;
  16445. }
  16446. case 15: {
  16447. _stbi__err(10778);
  16448. $$6$ph = 0;
  16449. break;
  16450. }
  16451. case 17: {
  16452. _stbi__err(10798);
  16453. $$6$ph = 0;
  16454. break;
  16455. }
  16456. case 20: {
  16457. _stbi__err(10798);
  16458. $$6$ph = 0;
  16459. break;
  16460. }
  16461. case 22: {
  16462. _stbi__err(10798);
  16463. $$6$ph = 0;
  16464. break;
  16465. }
  16466. case 24: {
  16467. _stbi__err(10808);
  16468. $$6$ph = 0;
  16469. break;
  16470. }
  16471. case 26: {
  16472. _stbi__err(10824);
  16473. $$6$ph = 0;
  16474. break;
  16475. }
  16476. case 28: {
  16477. _stbi__err(10842);
  16478. $$6$ph = 0;
  16479. break;
  16480. }
  16481. case 31: {
  16482. _stbi__err(10863);
  16483. $$6$ph = 0;
  16484. break;
  16485. }
  16486. case 34: {
  16487. _stbi__err(10768);
  16488. $$6$ph = 0;
  16489. break;
  16490. }
  16491. case 37: {
  16492. _stbi__err(10768);
  16493. $$6$ph = 0;
  16494. break;
  16495. }
  16496. case 39: {
  16497. _stbi__err(10877);
  16498. $$6$ph = 0;
  16499. break;
  16500. }
  16501. case 41: {
  16502. _stbi__err(10892);
  16503. $$6$ph = 0;
  16504. break;
  16505. }
  16506. case 44: {
  16507. _stbi__err(10892);
  16508. $$6$ph = 0;
  16509. break;
  16510. }
  16511. case 47: {
  16512. _stbi__err(10877);
  16513. $$6$ph = 0;
  16514. break;
  16515. }
  16516. case 49: {
  16517. _stbi__err(10905);
  16518. $$6$ph = 0;
  16519. break;
  16520. }
  16521. case 52: {
  16522. $89 = ((($8)) + 8|0);
  16523. HEAP32[$89>>2] = 4;
  16524. $$6$ph = 1;
  16525. break;
  16526. }
  16527. case 54: {
  16528. _stbi__err(10921);
  16529. $$6$ph = 0;
  16530. break;
  16531. }
  16532. case 58: {
  16533. _stbi__err(10938);
  16534. $$6$ph = 0;
  16535. break;
  16536. }
  16537. case 61: {
  16538. _stbi__err(10951);
  16539. $$6$ph = 0;
  16540. break;
  16541. }
  16542. case 63: {
  16543. _stbi__err(10938);
  16544. $$6$ph = 0;
  16545. break;
  16546. }
  16547. case 70: {
  16548. _stbi__err(10877);
  16549. $$6$ph = 0;
  16550. break;
  16551. }
  16552. case 72: {
  16553. _stbi__err(10976);
  16554. $$6$ph = 0;
  16555. break;
  16556. }
  16557. case 74: {
  16558. $133 = $$0206&255;
  16559. $134 = ((($8)) + 8|0);
  16560. HEAP32[$134>>2] = $133;
  16561. $$6$ph = 1;
  16562. break;
  16563. }
  16564. case 81: {
  16565. _stbi__err(10623);
  16566. $$6$ph = 0;
  16567. break;
  16568. }
  16569. case 83: {
  16570. _stbi__err(10984);
  16571. $$6$ph = 0;
  16572. break;
  16573. }
  16574. case 85: {
  16575. $156 = ($$0241|0)==(0);
  16576. do {
  16577. if ($156) {
  16578. $157 = ($1|0)==(0);
  16579. if ($157) {
  16580. $158 = HEAP32[$10>>2]|0;
  16581. $159 = ($158|0)==(0|0);
  16582. if ($159) {
  16583. _stbi__err(10994);
  16584. $$4 = 0;
  16585. break;
  16586. }
  16587. $160 = HEAP32[$8>>2]|0;
  16588. $161 = ((($0)) + 16|0);
  16589. $162 = HEAP32[$161>>2]|0;
  16590. $163 = Math_imul($162, $160)|0;
  16591. $164 = (($163) + 7)|0;
  16592. $165 = $164 >>> 3;
  16593. $166 = ((($8)) + 4|0);
  16594. $167 = HEAP32[$166>>2]|0;
  16595. $168 = ((($8)) + 8|0);
  16596. $169 = HEAP32[$168>>2]|0;
  16597. $170 = Math_imul($169, $167)|0;
  16598. $171 = Math_imul($170, $165)|0;
  16599. $172 = (($171) + ($167))|0;
  16600. HEAP32[$7>>2] = $172;
  16601. $173 = ($$0228|0)!=(0);
  16602. $174 = $173 ^ 1;
  16603. $175 = $174&1;
  16604. $176 = (_stbi_zlib_decode_malloc_guesssize_headerflag($158,$$0214,$172,$7,$175)|0);
  16605. HEAP32[$9>>2] = $176;
  16606. $177 = ($176|0)==(0|0);
  16607. if ($177) {
  16608. $$4 = 0;
  16609. } else {
  16610. $178 = HEAP32[$10>>2]|0;
  16611. _free($178);
  16612. HEAP32[$10>>2] = 0;
  16613. $179 = HEAP32[$168>>2]|0;
  16614. $180 = (($179) + 1)|0;
  16615. $notlhs = ($180|0)!=($2|0);
  16616. $notrhs = ($2|0)==(3);
  16617. $or$cond5$not = $notrhs | $notlhs;
  16618. $181 = ($$0206<<24>>24)!=(0);
  16619. $or$cond7 = $181 | $or$cond5$not;
  16620. $182 = ($$0211<<24>>24)==(0);
  16621. $or$cond248 = $182 & $or$cond7;
  16622. $$254 = $or$cond248 ? $179 : $180;
  16623. $183 = ((($8)) + 12|0);
  16624. HEAP32[$183>>2] = $$254;
  16625. $184 = HEAP32[$9>>2]|0;
  16626. $185 = HEAP32[$7>>2]|0;
  16627. $186 = HEAP32[$161>>2]|0;
  16628. $187 = (_stbi__create_png_image($0,$184,$185,$$254,$186,$$0231,$$0235)|0);
  16629. $188 = ($187|0)==(0);
  16630. if ($188) {
  16631. $$4 = 0;
  16632. } else {
  16633. do {
  16634. if (!($182)) {
  16635. $189 = HEAP32[$161>>2]|0;
  16636. $190 = ($189|0)==(16);
  16637. if ($190) {
  16638. $191 = HEAP32[$183>>2]|0;
  16639. _stbi__compute_transparency16($0,$5,$191);
  16640. break;
  16641. } else {
  16642. $192 = HEAP32[$183>>2]|0;
  16643. _stbi__compute_transparency($0,$4,$192);
  16644. break;
  16645. }
  16646. }
  16647. } while(0);
  16648. $193 = HEAP32[5902]|0;
  16649. $194 = ($193|0)!=(0);
  16650. $or$cond11 = $173 & $194;
  16651. if ($or$cond11) {
  16652. $195 = HEAP32[$183>>2]|0;
  16653. $196 = ($195|0)>(2);
  16654. if ($196) {
  16655. _stbi__de_iphone($0);
  16656. }
  16657. }
  16658. if ($181) {
  16659. $197 = $$0206&255;
  16660. HEAP32[$168>>2] = $197;
  16661. $198 = ($2|0)>(2);
  16662. $$ = $198 ? $2 : $197;
  16663. HEAP32[$183>>2] = $$;
  16664. $199 = (_stbi__expand_png_palette($0,$3,$$)|0);
  16665. $200 = ($199|0)==(0);
  16666. if ($200) {
  16667. $$4 = 0;
  16668. break;
  16669. }
  16670. }
  16671. $201 = HEAP32[$9>>2]|0;
  16672. _free($201);
  16673. HEAP32[$9>>2] = 0;
  16674. $$4 = 1;
  16675. }
  16676. }
  16677. } else {
  16678. $$4 = 1;
  16679. }
  16680. } else {
  16681. _stbi__err(10877);
  16682. $$4 = 0;
  16683. }
  16684. } while(0);
  16685. $$6$ph = $$4;
  16686. break;
  16687. }
  16688. case 104: {
  16689. _stbi__err(10877);
  16690. $$6$ph = 0;
  16691. break;
  16692. }
  16693. case 106: {
  16694. $205 = $25 >>> 24;
  16695. $206 = $205&255;
  16696. HEAP8[11002] = $206;
  16697. $207 = HEAP32[$15>>2]|0;
  16698. $208 = $207 >>> 16;
  16699. $209 = $208&255;
  16700. HEAP8[(11003)>>0] = $209;
  16701. $210 = $207 >>> 8;
  16702. $211 = $210&255;
  16703. HEAP8[(11004)>>0] = $211;
  16704. $212 = $207&255;
  16705. HEAP8[(11005)>>0] = $212;
  16706. _stbi__err(11002);
  16707. $$6$ph = 0;
  16708. break;
  16709. }
  16710. }
  16711. $$7 = $$6$ph;
  16712. STACKTOP = sp;return ($$7|0);
  16713. }
  16714. function _stbi__convert_format($0,$1,$2,$3,$4) {
  16715. $0 = $0|0;
  16716. $1 = $1|0;
  16717. $2 = $2|0;
  16718. $3 = $3|0;
  16719. $4 = $4|0;
  16720. var $$0151255 = 0, $$0163 = 0, $$0164259 = 0, $$0165 = 0, $$0165254 = 0, $$0165257 = 0, $$0256 = 0, $$10161205 = 0, $$10175 = 0, $$10175204 = 0, $$10175207 = 0, $$10206 = 0, $$11162201 = 0, $$11176 = 0, $$11176200 = 0, $$11176203 = 0, $$11202 = 0, $$1152250 = 0, $$1166 = 0, $$1166249 = 0;
  16721. var $$1166252 = 0, $$1251 = 0, $$2153245 = 0, $$2167 = 0, $$2167244 = 0, $$2167247 = 0, $$2246 = 0, $$3154240 = 0, $$3168 = 0, $$3168239 = 0, $$3168242 = 0, $$3241 = 0, $$4155235 = 0, $$4169 = 0, $$4169234 = 0, $$4169237 = 0, $$4236 = 0, $$5156230 = 0, $$5170 = 0, $$5170229 = 0;
  16722. var $$5170232 = 0, $$5231 = 0, $$6157225 = 0, $$6171 = 0, $$6171224 = 0, $$6171227 = 0, $$6226 = 0, $$7158220 = 0, $$7172 = 0, $$7172219 = 0, $$7172222 = 0, $$7221 = 0, $$8159215 = 0, $$8173 = 0, $$8173214 = 0, $$8173217 = 0, $$8216 = 0, $$9160210 = 0, $$9174 = 0, $$9174209 = 0;
  16723. var $$9174212 = 0, $$9211 = 0, $$off = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0;
  16724. var $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0;
  16725. var $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  16726. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0;
  16727. var $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0;
  16728. var $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0;
  16729. var $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, label = 0;
  16730. var sp = 0;
  16731. sp = STACKTOP;
  16732. $5 = ($2|0)==($1|0);
  16733. if ($5) {
  16734. $$0163 = $0;
  16735. return ($$0163|0);
  16736. }
  16737. $$off = (($2) + -1)|0;
  16738. $6 = ($$off>>>0)<(4);
  16739. if (!($6)) {
  16740. ___assert_fail((10664|0),(10568|0),1477,(10720|0));
  16741. // unreachable;
  16742. }
  16743. $7 = (_stbi__malloc_mad3($2,$3,$4)|0);
  16744. $8 = ($7|0)==(0|0);
  16745. if ($8) {
  16746. _free($0);
  16747. _stbi__err(10623);
  16748. $$0163 = 0;
  16749. return ($$0163|0);
  16750. }
  16751. $9 = ($4|0)>(0);
  16752. L11: do {
  16753. if ($9) {
  16754. $10 = $1 << 3;
  16755. $11 = (($10) + ($2))|0;
  16756. $$0165254 = (($3) + -1)|0;
  16757. $12 = ($$0165254|0)>(-1);
  16758. $$1166249 = (($3) + -1)|0;
  16759. $13 = ($$1166249|0)>(-1);
  16760. $$2167244 = (($3) + -1)|0;
  16761. $14 = ($$2167244|0)>(-1);
  16762. $$3168239 = (($3) + -1)|0;
  16763. $15 = ($$3168239|0)>(-1);
  16764. $$4169234 = (($3) + -1)|0;
  16765. $16 = ($$4169234|0)>(-1);
  16766. $$5170229 = (($3) + -1)|0;
  16767. $17 = ($$5170229|0)>(-1);
  16768. $$6171224 = (($3) + -1)|0;
  16769. $18 = ($$6171224|0)>(-1);
  16770. $$7172219 = (($3) + -1)|0;
  16771. $19 = ($$7172219|0)>(-1);
  16772. $$8173214 = (($3) + -1)|0;
  16773. $20 = ($$8173214|0)>(-1);
  16774. $$9174209 = (($3) + -1)|0;
  16775. $21 = ($$9174209|0)>(-1);
  16776. $$10175204 = (($3) + -1)|0;
  16777. $22 = ($$10175204|0)>(-1);
  16778. $$11176200 = (($3) + -1)|0;
  16779. $23 = ($$11176200|0)>(-1);
  16780. $$0164259 = 0;
  16781. L13: while(1) {
  16782. $24 = Math_imul($$0164259, $3)|0;
  16783. $25 = Math_imul($24, $1)|0;
  16784. $26 = (($0) + ($25)|0);
  16785. $27 = Math_imul($24, $2)|0;
  16786. $28 = (($7) + ($27)|0);
  16787. do {
  16788. switch ($11|0) {
  16789. case 10: {
  16790. if ($12) {
  16791. $$0151255 = $26;$$0165257 = $$0165254;$$0256 = $28;
  16792. while(1) {
  16793. $29 = HEAP8[$$0151255>>0]|0;
  16794. HEAP8[$$0256>>0] = $29;
  16795. $30 = ((($$0256)) + 1|0);
  16796. HEAP8[$30>>0] = -1;
  16797. $31 = ((($$0151255)) + 1|0);
  16798. $32 = ((($$0256)) + 2|0);
  16799. $$0165 = (($$0165257) + -1)|0;
  16800. $33 = ($$0165|0)>(-1);
  16801. if ($33) {
  16802. $$0151255 = $31;$$0165257 = $$0165;$$0256 = $32;
  16803. } else {
  16804. break;
  16805. }
  16806. }
  16807. }
  16808. break;
  16809. }
  16810. case 11: {
  16811. if ($13) {
  16812. $$1152250 = $26;$$1166252 = $$1166249;$$1251 = $28;
  16813. while(1) {
  16814. $34 = HEAP8[$$1152250>>0]|0;
  16815. $35 = ((($$1251)) + 2|0);
  16816. HEAP8[$35>>0] = $34;
  16817. $36 = ((($$1251)) + 1|0);
  16818. HEAP8[$36>>0] = $34;
  16819. HEAP8[$$1251>>0] = $34;
  16820. $37 = ((($$1152250)) + 1|0);
  16821. $38 = ((($$1251)) + 3|0);
  16822. $$1166 = (($$1166252) + -1)|0;
  16823. $39 = ($$1166|0)>(-1);
  16824. if ($39) {
  16825. $$1152250 = $37;$$1166252 = $$1166;$$1251 = $38;
  16826. } else {
  16827. break;
  16828. }
  16829. }
  16830. }
  16831. break;
  16832. }
  16833. case 12: {
  16834. if ($14) {
  16835. $$2153245 = $26;$$2167247 = $$2167244;$$2246 = $28;
  16836. while(1) {
  16837. $40 = HEAP8[$$2153245>>0]|0;
  16838. $41 = ((($$2246)) + 2|0);
  16839. HEAP8[$41>>0] = $40;
  16840. $42 = ((($$2246)) + 1|0);
  16841. HEAP8[$42>>0] = $40;
  16842. HEAP8[$$2246>>0] = $40;
  16843. $43 = ((($$2246)) + 3|0);
  16844. HEAP8[$43>>0] = -1;
  16845. $44 = ((($$2153245)) + 1|0);
  16846. $45 = ((($$2246)) + 4|0);
  16847. $$2167 = (($$2167247) + -1)|0;
  16848. $46 = ($$2167|0)>(-1);
  16849. if ($46) {
  16850. $$2153245 = $44;$$2167247 = $$2167;$$2246 = $45;
  16851. } else {
  16852. break;
  16853. }
  16854. }
  16855. }
  16856. break;
  16857. }
  16858. case 17: {
  16859. if ($15) {
  16860. $$3154240 = $26;$$3168242 = $$3168239;$$3241 = $28;
  16861. while(1) {
  16862. $47 = HEAP8[$$3154240>>0]|0;
  16863. HEAP8[$$3241>>0] = $47;
  16864. $48 = ((($$3154240)) + 2|0);
  16865. $49 = ((($$3241)) + 1|0);
  16866. $$3168 = (($$3168242) + -1)|0;
  16867. $50 = ($$3168|0)>(-1);
  16868. if ($50) {
  16869. $$3154240 = $48;$$3168242 = $$3168;$$3241 = $49;
  16870. } else {
  16871. break;
  16872. }
  16873. }
  16874. }
  16875. break;
  16876. }
  16877. case 19: {
  16878. if ($16) {
  16879. $$4155235 = $26;$$4169237 = $$4169234;$$4236 = $28;
  16880. while(1) {
  16881. $51 = HEAP8[$$4155235>>0]|0;
  16882. $52 = ((($$4236)) + 2|0);
  16883. HEAP8[$52>>0] = $51;
  16884. $53 = ((($$4236)) + 1|0);
  16885. HEAP8[$53>>0] = $51;
  16886. HEAP8[$$4236>>0] = $51;
  16887. $54 = ((($$4155235)) + 2|0);
  16888. $55 = ((($$4236)) + 3|0);
  16889. $$4169 = (($$4169237) + -1)|0;
  16890. $56 = ($$4169|0)>(-1);
  16891. if ($56) {
  16892. $$4155235 = $54;$$4169237 = $$4169;$$4236 = $55;
  16893. } else {
  16894. break;
  16895. }
  16896. }
  16897. }
  16898. break;
  16899. }
  16900. case 20: {
  16901. if ($17) {
  16902. $$5156230 = $26;$$5170232 = $$5170229;$$5231 = $28;
  16903. while(1) {
  16904. $57 = HEAP8[$$5156230>>0]|0;
  16905. $58 = ((($$5231)) + 2|0);
  16906. HEAP8[$58>>0] = $57;
  16907. $59 = ((($$5231)) + 1|0);
  16908. HEAP8[$59>>0] = $57;
  16909. HEAP8[$$5231>>0] = $57;
  16910. $60 = ((($$5156230)) + 1|0);
  16911. $61 = HEAP8[$60>>0]|0;
  16912. $62 = ((($$5231)) + 3|0);
  16913. HEAP8[$62>>0] = $61;
  16914. $63 = ((($$5156230)) + 2|0);
  16915. $64 = ((($$5231)) + 4|0);
  16916. $$5170 = (($$5170232) + -1)|0;
  16917. $65 = ($$5170|0)>(-1);
  16918. if ($65) {
  16919. $$5156230 = $63;$$5170232 = $$5170;$$5231 = $64;
  16920. } else {
  16921. break;
  16922. }
  16923. }
  16924. }
  16925. break;
  16926. }
  16927. case 28: {
  16928. if ($18) {
  16929. $$6157225 = $26;$$6171227 = $$6171224;$$6226 = $28;
  16930. while(1) {
  16931. $66 = HEAP8[$$6157225>>0]|0;
  16932. HEAP8[$$6226>>0] = $66;
  16933. $67 = ((($$6157225)) + 1|0);
  16934. $68 = HEAP8[$67>>0]|0;
  16935. $69 = ((($$6226)) + 1|0);
  16936. HEAP8[$69>>0] = $68;
  16937. $70 = ((($$6157225)) + 2|0);
  16938. $71 = HEAP8[$70>>0]|0;
  16939. $72 = ((($$6226)) + 2|0);
  16940. HEAP8[$72>>0] = $71;
  16941. $73 = ((($$6226)) + 3|0);
  16942. HEAP8[$73>>0] = -1;
  16943. $74 = ((($$6157225)) + 3|0);
  16944. $75 = ((($$6226)) + 4|0);
  16945. $$6171 = (($$6171227) + -1)|0;
  16946. $76 = ($$6171|0)>(-1);
  16947. if ($76) {
  16948. $$6157225 = $74;$$6171227 = $$6171;$$6226 = $75;
  16949. } else {
  16950. break;
  16951. }
  16952. }
  16953. }
  16954. break;
  16955. }
  16956. case 25: {
  16957. if ($19) {
  16958. $$7158220 = $26;$$7172222 = $$7172219;$$7221 = $28;
  16959. while(1) {
  16960. $77 = HEAP8[$$7158220>>0]|0;
  16961. $78 = $77&255;
  16962. $79 = ((($$7158220)) + 1|0);
  16963. $80 = HEAP8[$79>>0]|0;
  16964. $81 = $80&255;
  16965. $82 = ((($$7158220)) + 2|0);
  16966. $83 = HEAP8[$82>>0]|0;
  16967. $84 = $83&255;
  16968. $85 = (_stbi__compute_y($78,$81,$84)|0);
  16969. HEAP8[$$7221>>0] = $85;
  16970. $86 = ((($$7158220)) + 3|0);
  16971. $87 = ((($$7221)) + 1|0);
  16972. $$7172 = (($$7172222) + -1)|0;
  16973. $88 = ($$7172|0)>(-1);
  16974. if ($88) {
  16975. $$7158220 = $86;$$7172222 = $$7172;$$7221 = $87;
  16976. } else {
  16977. break;
  16978. }
  16979. }
  16980. }
  16981. break;
  16982. }
  16983. case 26: {
  16984. if ($20) {
  16985. $$8159215 = $26;$$8173217 = $$8173214;$$8216 = $28;
  16986. while(1) {
  16987. $89 = HEAP8[$$8159215>>0]|0;
  16988. $90 = $89&255;
  16989. $91 = ((($$8159215)) + 1|0);
  16990. $92 = HEAP8[$91>>0]|0;
  16991. $93 = $92&255;
  16992. $94 = ((($$8159215)) + 2|0);
  16993. $95 = HEAP8[$94>>0]|0;
  16994. $96 = $95&255;
  16995. $97 = (_stbi__compute_y($90,$93,$96)|0);
  16996. HEAP8[$$8216>>0] = $97;
  16997. $98 = ((($$8216)) + 1|0);
  16998. HEAP8[$98>>0] = -1;
  16999. $99 = ((($$8159215)) + 3|0);
  17000. $100 = ((($$8216)) + 2|0);
  17001. $$8173 = (($$8173217) + -1)|0;
  17002. $101 = ($$8173|0)>(-1);
  17003. if ($101) {
  17004. $$8159215 = $99;$$8173217 = $$8173;$$8216 = $100;
  17005. } else {
  17006. break;
  17007. }
  17008. }
  17009. }
  17010. break;
  17011. }
  17012. case 33: {
  17013. if ($21) {
  17014. $$9160210 = $26;$$9174212 = $$9174209;$$9211 = $28;
  17015. while(1) {
  17016. $102 = HEAP8[$$9160210>>0]|0;
  17017. $103 = $102&255;
  17018. $104 = ((($$9160210)) + 1|0);
  17019. $105 = HEAP8[$104>>0]|0;
  17020. $106 = $105&255;
  17021. $107 = ((($$9160210)) + 2|0);
  17022. $108 = HEAP8[$107>>0]|0;
  17023. $109 = $108&255;
  17024. $110 = (_stbi__compute_y($103,$106,$109)|0);
  17025. HEAP8[$$9211>>0] = $110;
  17026. $111 = ((($$9160210)) + 4|0);
  17027. $112 = ((($$9211)) + 1|0);
  17028. $$9174 = (($$9174212) + -1)|0;
  17029. $113 = ($$9174|0)>(-1);
  17030. if ($113) {
  17031. $$9160210 = $111;$$9174212 = $$9174;$$9211 = $112;
  17032. } else {
  17033. break;
  17034. }
  17035. }
  17036. }
  17037. break;
  17038. }
  17039. case 34: {
  17040. if ($22) {
  17041. $$10161205 = $26;$$10175207 = $$10175204;$$10206 = $28;
  17042. while(1) {
  17043. $114 = HEAP8[$$10161205>>0]|0;
  17044. $115 = $114&255;
  17045. $116 = ((($$10161205)) + 1|0);
  17046. $117 = HEAP8[$116>>0]|0;
  17047. $118 = $117&255;
  17048. $119 = ((($$10161205)) + 2|0);
  17049. $120 = HEAP8[$119>>0]|0;
  17050. $121 = $120&255;
  17051. $122 = (_stbi__compute_y($115,$118,$121)|0);
  17052. HEAP8[$$10206>>0] = $122;
  17053. $123 = ((($$10161205)) + 3|0);
  17054. $124 = HEAP8[$123>>0]|0;
  17055. $125 = ((($$10206)) + 1|0);
  17056. HEAP8[$125>>0] = $124;
  17057. $126 = ((($$10161205)) + 4|0);
  17058. $127 = ((($$10206)) + 2|0);
  17059. $$10175 = (($$10175207) + -1)|0;
  17060. $128 = ($$10175|0)>(-1);
  17061. if ($128) {
  17062. $$10161205 = $126;$$10175207 = $$10175;$$10206 = $127;
  17063. } else {
  17064. break;
  17065. }
  17066. }
  17067. }
  17068. break;
  17069. }
  17070. case 35: {
  17071. if ($23) {
  17072. $$11162201 = $26;$$11176203 = $$11176200;$$11202 = $28;
  17073. while(1) {
  17074. $129 = HEAP8[$$11162201>>0]|0;
  17075. HEAP8[$$11202>>0] = $129;
  17076. $130 = ((($$11162201)) + 1|0);
  17077. $131 = HEAP8[$130>>0]|0;
  17078. $132 = ((($$11202)) + 1|0);
  17079. HEAP8[$132>>0] = $131;
  17080. $133 = ((($$11162201)) + 2|0);
  17081. $134 = HEAP8[$133>>0]|0;
  17082. $135 = ((($$11202)) + 2|0);
  17083. HEAP8[$135>>0] = $134;
  17084. $136 = ((($$11162201)) + 4|0);
  17085. $137 = ((($$11202)) + 3|0);
  17086. $$11176 = (($$11176203) + -1)|0;
  17087. $138 = ($$11176|0)>(-1);
  17088. if ($138) {
  17089. $$11162201 = $136;$$11176203 = $$11176;$$11202 = $137;
  17090. } else {
  17091. break;
  17092. }
  17093. }
  17094. }
  17095. break;
  17096. }
  17097. default: {
  17098. break L13;
  17099. }
  17100. }
  17101. } while(0);
  17102. $139 = (($$0164259) + 1)|0;
  17103. $140 = ($139|0)<($4|0);
  17104. if ($140) {
  17105. $$0164259 = $139;
  17106. } else {
  17107. break L11;
  17108. }
  17109. }
  17110. ___assert_fail((10718|0),(10568|0),1506,(10720|0));
  17111. // unreachable;
  17112. }
  17113. } while(0);
  17114. _free($0);
  17115. $$0163 = $7;
  17116. return ($$0163|0);
  17117. }
  17118. function _stbi__convert_format16($0,$1,$2,$3,$4) {
  17119. $0 = $0|0;
  17120. $1 = $1|0;
  17121. $2 = $2|0;
  17122. $3 = $3|0;
  17123. $4 = $4|0;
  17124. var $$0151255 = 0, $$0163 = 0, $$0164259 = 0, $$0165 = 0, $$0165254 = 0, $$0165257 = 0, $$0256 = 0, $$10161205 = 0, $$10175 = 0, $$10175204 = 0, $$10175207 = 0, $$10206 = 0, $$11162201 = 0, $$11176 = 0, $$11176200 = 0, $$11176203 = 0, $$11202 = 0, $$1152250 = 0, $$1166 = 0, $$1166249 = 0;
  17125. var $$1166252 = 0, $$1251 = 0, $$2153245 = 0, $$2167 = 0, $$2167244 = 0, $$2167247 = 0, $$2246 = 0, $$3154240 = 0, $$3168 = 0, $$3168239 = 0, $$3168242 = 0, $$3241 = 0, $$4155235 = 0, $$4169 = 0, $$4169234 = 0, $$4169237 = 0, $$4236 = 0, $$5156230 = 0, $$5170 = 0, $$5170229 = 0;
  17126. var $$5170232 = 0, $$5231 = 0, $$6157225 = 0, $$6171 = 0, $$6171224 = 0, $$6171227 = 0, $$6226 = 0, $$7158220 = 0, $$7172 = 0, $$7172219 = 0, $$7172222 = 0, $$7221 = 0, $$8159215 = 0, $$8173 = 0, $$8173214 = 0, $$8173217 = 0, $$8216 = 0, $$9160210 = 0, $$9174 = 0, $$9174209 = 0;
  17127. var $$9174212 = 0, $$9211 = 0, $$off = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0;
  17128. var $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0;
  17129. var $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0;
  17130. var $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0;
  17131. var $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0;
  17132. var $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0;
  17133. var $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0;
  17134. var $98 = 0, $99 = 0, label = 0, sp = 0;
  17135. sp = STACKTOP;
  17136. $5 = ($2|0)==($1|0);
  17137. if ($5) {
  17138. $$0163 = $0;
  17139. return ($$0163|0);
  17140. }
  17141. $$off = (($2) + -1)|0;
  17142. $6 = ($$off>>>0)<(4);
  17143. if (!($6)) {
  17144. ___assert_fail((10664|0),(10568|0),1526,(10695|0));
  17145. // unreachable;
  17146. }
  17147. $7 = $2 << 1;
  17148. $8 = Math_imul($7, $3)|0;
  17149. $9 = Math_imul($8, $4)|0;
  17150. $10 = (_stbi__malloc($9)|0);
  17151. $11 = ($10|0)==(0|0);
  17152. if ($11) {
  17153. _free($0);
  17154. _stbi__err(10623);
  17155. $$0163 = 0;
  17156. return ($$0163|0);
  17157. }
  17158. $12 = ($4|0)>(0);
  17159. L11: do {
  17160. if ($12) {
  17161. $13 = $1 << 3;
  17162. $14 = (($13) + ($2))|0;
  17163. $$0165254 = (($3) + -1)|0;
  17164. $15 = ($$0165254|0)>(-1);
  17165. $$1166249 = (($3) + -1)|0;
  17166. $16 = ($$1166249|0)>(-1);
  17167. $$2167244 = (($3) + -1)|0;
  17168. $17 = ($$2167244|0)>(-1);
  17169. $$3168239 = (($3) + -1)|0;
  17170. $18 = ($$3168239|0)>(-1);
  17171. $$4169234 = (($3) + -1)|0;
  17172. $19 = ($$4169234|0)>(-1);
  17173. $$5170229 = (($3) + -1)|0;
  17174. $20 = ($$5170229|0)>(-1);
  17175. $$6171224 = (($3) + -1)|0;
  17176. $21 = ($$6171224|0)>(-1);
  17177. $$7172219 = (($3) + -1)|0;
  17178. $22 = ($$7172219|0)>(-1);
  17179. $$8173214 = (($3) + -1)|0;
  17180. $23 = ($$8173214|0)>(-1);
  17181. $$9174209 = (($3) + -1)|0;
  17182. $24 = ($$9174209|0)>(-1);
  17183. $$10175204 = (($3) + -1)|0;
  17184. $25 = ($$10175204|0)>(-1);
  17185. $$11176200 = (($3) + -1)|0;
  17186. $26 = ($$11176200|0)>(-1);
  17187. $$0164259 = 0;
  17188. L13: while(1) {
  17189. $27 = Math_imul($$0164259, $3)|0;
  17190. $28 = Math_imul($27, $1)|0;
  17191. $29 = (($0) + ($28<<1)|0);
  17192. $30 = Math_imul($27, $2)|0;
  17193. $31 = (($10) + ($30<<1)|0);
  17194. do {
  17195. switch ($14|0) {
  17196. case 10: {
  17197. if ($15) {
  17198. $$0151255 = $29;$$0165257 = $$0165254;$$0256 = $31;
  17199. while(1) {
  17200. $32 = HEAP16[$$0151255>>1]|0;
  17201. HEAP16[$$0256>>1] = $32;
  17202. $33 = ((($$0256)) + 2|0);
  17203. HEAP16[$33>>1] = -1;
  17204. $34 = ((($$0151255)) + 2|0);
  17205. $35 = ((($$0256)) + 4|0);
  17206. $$0165 = (($$0165257) + -1)|0;
  17207. $36 = ($$0165|0)>(-1);
  17208. if ($36) {
  17209. $$0151255 = $34;$$0165257 = $$0165;$$0256 = $35;
  17210. } else {
  17211. break;
  17212. }
  17213. }
  17214. }
  17215. break;
  17216. }
  17217. case 11: {
  17218. if ($16) {
  17219. $$1152250 = $29;$$1166252 = $$1166249;$$1251 = $31;
  17220. while(1) {
  17221. $37 = HEAP16[$$1152250>>1]|0;
  17222. $38 = ((($$1251)) + 4|0);
  17223. HEAP16[$38>>1] = $37;
  17224. $39 = ((($$1251)) + 2|0);
  17225. HEAP16[$39>>1] = $37;
  17226. HEAP16[$$1251>>1] = $37;
  17227. $40 = ((($$1152250)) + 2|0);
  17228. $41 = ((($$1251)) + 6|0);
  17229. $$1166 = (($$1166252) + -1)|0;
  17230. $42 = ($$1166|0)>(-1);
  17231. if ($42) {
  17232. $$1152250 = $40;$$1166252 = $$1166;$$1251 = $41;
  17233. } else {
  17234. break;
  17235. }
  17236. }
  17237. }
  17238. break;
  17239. }
  17240. case 12: {
  17241. if ($17) {
  17242. $$2153245 = $29;$$2167247 = $$2167244;$$2246 = $31;
  17243. while(1) {
  17244. $43 = HEAP16[$$2153245>>1]|0;
  17245. $44 = ((($$2246)) + 4|0);
  17246. HEAP16[$44>>1] = $43;
  17247. $45 = ((($$2246)) + 2|0);
  17248. HEAP16[$45>>1] = $43;
  17249. HEAP16[$$2246>>1] = $43;
  17250. $46 = ((($$2246)) + 6|0);
  17251. HEAP16[$46>>1] = -1;
  17252. $47 = ((($$2153245)) + 2|0);
  17253. $48 = ((($$2246)) + 8|0);
  17254. $$2167 = (($$2167247) + -1)|0;
  17255. $49 = ($$2167|0)>(-1);
  17256. if ($49) {
  17257. $$2153245 = $47;$$2167247 = $$2167;$$2246 = $48;
  17258. } else {
  17259. break;
  17260. }
  17261. }
  17262. }
  17263. break;
  17264. }
  17265. case 17: {
  17266. if ($18) {
  17267. $$3154240 = $29;$$3168242 = $$3168239;$$3241 = $31;
  17268. while(1) {
  17269. $50 = HEAP16[$$3154240>>1]|0;
  17270. HEAP16[$$3241>>1] = $50;
  17271. $51 = ((($$3154240)) + 4|0);
  17272. $52 = ((($$3241)) + 2|0);
  17273. $$3168 = (($$3168242) + -1)|0;
  17274. $53 = ($$3168|0)>(-1);
  17275. if ($53) {
  17276. $$3154240 = $51;$$3168242 = $$3168;$$3241 = $52;
  17277. } else {
  17278. break;
  17279. }
  17280. }
  17281. }
  17282. break;
  17283. }
  17284. case 19: {
  17285. if ($19) {
  17286. $$4155235 = $29;$$4169237 = $$4169234;$$4236 = $31;
  17287. while(1) {
  17288. $54 = HEAP16[$$4155235>>1]|0;
  17289. $55 = ((($$4236)) + 4|0);
  17290. HEAP16[$55>>1] = $54;
  17291. $56 = ((($$4236)) + 2|0);
  17292. HEAP16[$56>>1] = $54;
  17293. HEAP16[$$4236>>1] = $54;
  17294. $57 = ((($$4155235)) + 4|0);
  17295. $58 = ((($$4236)) + 6|0);
  17296. $$4169 = (($$4169237) + -1)|0;
  17297. $59 = ($$4169|0)>(-1);
  17298. if ($59) {
  17299. $$4155235 = $57;$$4169237 = $$4169;$$4236 = $58;
  17300. } else {
  17301. break;
  17302. }
  17303. }
  17304. }
  17305. break;
  17306. }
  17307. case 20: {
  17308. if ($20) {
  17309. $$5156230 = $29;$$5170232 = $$5170229;$$5231 = $31;
  17310. while(1) {
  17311. $60 = HEAP16[$$5156230>>1]|0;
  17312. $61 = ((($$5231)) + 4|0);
  17313. HEAP16[$61>>1] = $60;
  17314. $62 = ((($$5231)) + 2|0);
  17315. HEAP16[$62>>1] = $60;
  17316. HEAP16[$$5231>>1] = $60;
  17317. $63 = ((($$5156230)) + 2|0);
  17318. $64 = HEAP16[$63>>1]|0;
  17319. $65 = ((($$5231)) + 6|0);
  17320. HEAP16[$65>>1] = $64;
  17321. $66 = ((($$5156230)) + 4|0);
  17322. $67 = ((($$5231)) + 8|0);
  17323. $$5170 = (($$5170232) + -1)|0;
  17324. $68 = ($$5170|0)>(-1);
  17325. if ($68) {
  17326. $$5156230 = $66;$$5170232 = $$5170;$$5231 = $67;
  17327. } else {
  17328. break;
  17329. }
  17330. }
  17331. }
  17332. break;
  17333. }
  17334. case 28: {
  17335. if ($21) {
  17336. $$6157225 = $29;$$6171227 = $$6171224;$$6226 = $31;
  17337. while(1) {
  17338. $69 = HEAP16[$$6157225>>1]|0;
  17339. HEAP16[$$6226>>1] = $69;
  17340. $70 = ((($$6157225)) + 2|0);
  17341. $71 = HEAP16[$70>>1]|0;
  17342. $72 = ((($$6226)) + 2|0);
  17343. HEAP16[$72>>1] = $71;
  17344. $73 = ((($$6157225)) + 4|0);
  17345. $74 = HEAP16[$73>>1]|0;
  17346. $75 = ((($$6226)) + 4|0);
  17347. HEAP16[$75>>1] = $74;
  17348. $76 = ((($$6226)) + 6|0);
  17349. HEAP16[$76>>1] = -1;
  17350. $77 = ((($$6157225)) + 6|0);
  17351. $78 = ((($$6226)) + 8|0);
  17352. $$6171 = (($$6171227) + -1)|0;
  17353. $79 = ($$6171|0)>(-1);
  17354. if ($79) {
  17355. $$6157225 = $77;$$6171227 = $$6171;$$6226 = $78;
  17356. } else {
  17357. break;
  17358. }
  17359. }
  17360. }
  17361. break;
  17362. }
  17363. case 25: {
  17364. if ($22) {
  17365. $$7158220 = $29;$$7172222 = $$7172219;$$7221 = $31;
  17366. while(1) {
  17367. $80 = HEAP16[$$7158220>>1]|0;
  17368. $81 = $80&65535;
  17369. $82 = ((($$7158220)) + 2|0);
  17370. $83 = HEAP16[$82>>1]|0;
  17371. $84 = $83&65535;
  17372. $85 = ((($$7158220)) + 4|0);
  17373. $86 = HEAP16[$85>>1]|0;
  17374. $87 = $86&65535;
  17375. $88 = (_stbi__compute_y_16($81,$84,$87)|0);
  17376. HEAP16[$$7221>>1] = $88;
  17377. $89 = ((($$7158220)) + 6|0);
  17378. $90 = ((($$7221)) + 2|0);
  17379. $$7172 = (($$7172222) + -1)|0;
  17380. $91 = ($$7172|0)>(-1);
  17381. if ($91) {
  17382. $$7158220 = $89;$$7172222 = $$7172;$$7221 = $90;
  17383. } else {
  17384. break;
  17385. }
  17386. }
  17387. }
  17388. break;
  17389. }
  17390. case 26: {
  17391. if ($23) {
  17392. $$8159215 = $29;$$8173217 = $$8173214;$$8216 = $31;
  17393. while(1) {
  17394. $92 = HEAP16[$$8159215>>1]|0;
  17395. $93 = $92&65535;
  17396. $94 = ((($$8159215)) + 2|0);
  17397. $95 = HEAP16[$94>>1]|0;
  17398. $96 = $95&65535;
  17399. $97 = ((($$8159215)) + 4|0);
  17400. $98 = HEAP16[$97>>1]|0;
  17401. $99 = $98&65535;
  17402. $100 = (_stbi__compute_y_16($93,$96,$99)|0);
  17403. HEAP16[$$8216>>1] = $100;
  17404. $101 = ((($$8216)) + 2|0);
  17405. HEAP16[$101>>1] = -1;
  17406. $102 = ((($$8159215)) + 6|0);
  17407. $103 = ((($$8216)) + 4|0);
  17408. $$8173 = (($$8173217) + -1)|0;
  17409. $104 = ($$8173|0)>(-1);
  17410. if ($104) {
  17411. $$8159215 = $102;$$8173217 = $$8173;$$8216 = $103;
  17412. } else {
  17413. break;
  17414. }
  17415. }
  17416. }
  17417. break;
  17418. }
  17419. case 33: {
  17420. if ($24) {
  17421. $$9160210 = $29;$$9174212 = $$9174209;$$9211 = $31;
  17422. while(1) {
  17423. $105 = HEAP16[$$9160210>>1]|0;
  17424. $106 = $105&65535;
  17425. $107 = ((($$9160210)) + 2|0);
  17426. $108 = HEAP16[$107>>1]|0;
  17427. $109 = $108&65535;
  17428. $110 = ((($$9160210)) + 4|0);
  17429. $111 = HEAP16[$110>>1]|0;
  17430. $112 = $111&65535;
  17431. $113 = (_stbi__compute_y_16($106,$109,$112)|0);
  17432. HEAP16[$$9211>>1] = $113;
  17433. $114 = ((($$9160210)) + 8|0);
  17434. $115 = ((($$9211)) + 2|0);
  17435. $$9174 = (($$9174212) + -1)|0;
  17436. $116 = ($$9174|0)>(-1);
  17437. if ($116) {
  17438. $$9160210 = $114;$$9174212 = $$9174;$$9211 = $115;
  17439. } else {
  17440. break;
  17441. }
  17442. }
  17443. }
  17444. break;
  17445. }
  17446. case 34: {
  17447. if ($25) {
  17448. $$10161205 = $29;$$10175207 = $$10175204;$$10206 = $31;
  17449. while(1) {
  17450. $117 = HEAP16[$$10161205>>1]|0;
  17451. $118 = $117&65535;
  17452. $119 = ((($$10161205)) + 2|0);
  17453. $120 = HEAP16[$119>>1]|0;
  17454. $121 = $120&65535;
  17455. $122 = ((($$10161205)) + 4|0);
  17456. $123 = HEAP16[$122>>1]|0;
  17457. $124 = $123&65535;
  17458. $125 = (_stbi__compute_y_16($118,$121,$124)|0);
  17459. HEAP16[$$10206>>1] = $125;
  17460. $126 = ((($$10161205)) + 6|0);
  17461. $127 = HEAP16[$126>>1]|0;
  17462. $128 = ((($$10206)) + 2|0);
  17463. HEAP16[$128>>1] = $127;
  17464. $129 = ((($$10161205)) + 8|0);
  17465. $130 = ((($$10206)) + 4|0);
  17466. $$10175 = (($$10175207) + -1)|0;
  17467. $131 = ($$10175|0)>(-1);
  17468. if ($131) {
  17469. $$10161205 = $129;$$10175207 = $$10175;$$10206 = $130;
  17470. } else {
  17471. break;
  17472. }
  17473. }
  17474. }
  17475. break;
  17476. }
  17477. case 35: {
  17478. if ($26) {
  17479. $$11162201 = $29;$$11176203 = $$11176200;$$11202 = $31;
  17480. while(1) {
  17481. $132 = HEAP16[$$11162201>>1]|0;
  17482. HEAP16[$$11202>>1] = $132;
  17483. $133 = ((($$11162201)) + 2|0);
  17484. $134 = HEAP16[$133>>1]|0;
  17485. $135 = ((($$11202)) + 2|0);
  17486. HEAP16[$135>>1] = $134;
  17487. $136 = ((($$11162201)) + 4|0);
  17488. $137 = HEAP16[$136>>1]|0;
  17489. $138 = ((($$11202)) + 4|0);
  17490. HEAP16[$138>>1] = $137;
  17491. $139 = ((($$11162201)) + 8|0);
  17492. $140 = ((($$11202)) + 6|0);
  17493. $$11176 = (($$11176203) + -1)|0;
  17494. $141 = ($$11176|0)>(-1);
  17495. if ($141) {
  17496. $$11162201 = $139;$$11176203 = $$11176;$$11202 = $140;
  17497. } else {
  17498. break;
  17499. }
  17500. }
  17501. }
  17502. break;
  17503. }
  17504. default: {
  17505. break L13;
  17506. }
  17507. }
  17508. } while(0);
  17509. $142 = (($$0164259) + 1)|0;
  17510. $143 = ($142|0)<($4|0);
  17511. if ($143) {
  17512. $$0164259 = $142;
  17513. } else {
  17514. break L11;
  17515. }
  17516. }
  17517. ___assert_fail((10718|0),(10568|0),1555,(10695|0));
  17518. // unreachable;
  17519. }
  17520. } while(0);
  17521. _free($0);
  17522. $$0163 = $10;
  17523. return ($$0163|0);
  17524. }
  17525. function _stbi__compute_y_16($0,$1,$2) {
  17526. $0 = $0|0;
  17527. $1 = $1|0;
  17528. $2 = $2|0;
  17529. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  17530. sp = STACKTOP;
  17531. $3 = ($0*77)|0;
  17532. $4 = ($1*150)|0;
  17533. $5 = (($4) + ($3))|0;
  17534. $6 = ($2*29)|0;
  17535. $7 = (($5) + ($6))|0;
  17536. $8 = $7 >>> 8;
  17537. $9 = $8&65535;
  17538. return ($9|0);
  17539. }
  17540. function _stbi__malloc_mad3($0,$1,$2) {
  17541. $0 = $0|0;
  17542. $1 = $1|0;
  17543. $2 = $2|0;
  17544. var $$0 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, label = 0, sp = 0;
  17545. sp = STACKTOP;
  17546. $3 = (_stbi__mad3sizes_valid($0,$1,$2)|0);
  17547. $4 = ($3|0)==(0);
  17548. if ($4) {
  17549. $$0 = 0;
  17550. return ($$0|0);
  17551. }
  17552. $5 = Math_imul($1, $0)|0;
  17553. $6 = Math_imul($5, $2)|0;
  17554. $7 = (_stbi__malloc($6)|0);
  17555. $$0 = $7;
  17556. return ($$0|0);
  17557. }
  17558. function _stbi__compute_y($0,$1,$2) {
  17559. $0 = $0|0;
  17560. $1 = $1|0;
  17561. $2 = $2|0;
  17562. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  17563. sp = STACKTOP;
  17564. $3 = ($0*77)|0;
  17565. $4 = ($1*150)|0;
  17566. $5 = (($4) + ($3))|0;
  17567. $6 = ($2*29)|0;
  17568. $7 = (($5) + ($6))|0;
  17569. $8 = $7 >>> 8;
  17570. $9 = $8&255;
  17571. return ($9|0);
  17572. }
  17573. function _stbi__mad3sizes_valid($0,$1,$2) {
  17574. $0 = $0|0;
  17575. $1 = $1|0;
  17576. $2 = $2|0;
  17577. var $10 = 0, $11 = 0, $12 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  17578. sp = STACKTOP;
  17579. $3 = (_stbi__mul2sizes_valid($0,$1)|0);
  17580. $4 = ($3|0)==(0);
  17581. if ($4) {
  17582. $12 = 0;
  17583. } else {
  17584. $5 = Math_imul($1, $0)|0;
  17585. $6 = (_stbi__mul2sizes_valid($5,$2)|0);
  17586. $7 = ($6|0)==(0);
  17587. if ($7) {
  17588. $12 = 0;
  17589. } else {
  17590. $8 = Math_imul($5, $2)|0;
  17591. $9 = (_stbi__addsizes_valid($8)|0);
  17592. $10 = ($9|0)!=(0);
  17593. $12 = $10;
  17594. }
  17595. }
  17596. $11 = $12&1;
  17597. return ($11|0);
  17598. }
  17599. function _stbi__mul2sizes_valid($0,$1) {
  17600. $0 = $0|0;
  17601. $1 = $1|0;
  17602. var $$0 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, label = 0, sp = 0;
  17603. sp = STACKTOP;
  17604. $2 = $1 | $0;
  17605. $3 = ($2|0)<(0);
  17606. if ($3) {
  17607. $$0 = 0;
  17608. } else {
  17609. $4 = ($1|0)==(0);
  17610. if ($4) {
  17611. $$0 = 1;
  17612. } else {
  17613. $5 = (2147483647 / ($1|0))&-1;
  17614. $6 = ($5|0)>=($0|0);
  17615. $7 = $6&1;
  17616. $$0 = $7;
  17617. }
  17618. }
  17619. return ($$0|0);
  17620. }
  17621. function _stbi__addsizes_valid($0) {
  17622. $0 = $0|0;
  17623. var label = 0, sp = 0;
  17624. sp = STACKTOP;
  17625. return 1;
  17626. }
  17627. function _stbi__check_png_header($0) {
  17628. $0 = $0|0;
  17629. var $$05 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  17630. sp = STACKTOP;
  17631. $1 = (_stbi__get8($0)|0);
  17632. $2 = ($1<<24>>24)==(-119);
  17633. if ($2) {
  17634. $3 = (_stbi__get8($0)|0);
  17635. $4 = ($3<<24>>24)==(80);
  17636. if ($4) {
  17637. $5 = (_stbi__get8($0)|0);
  17638. $6 = ($5<<24>>24)==(78);
  17639. if ($6) {
  17640. $7 = (_stbi__get8($0)|0);
  17641. $8 = ($7<<24>>24)==(71);
  17642. if ($8) {
  17643. $9 = (_stbi__get8($0)|0);
  17644. $10 = ($9<<24>>24)==(13);
  17645. if ($10) {
  17646. $11 = (_stbi__get8($0)|0);
  17647. $12 = ($11<<24>>24)==(10);
  17648. if ($12) {
  17649. $13 = (_stbi__get8($0)|0);
  17650. $14 = ($13<<24>>24)==(26);
  17651. if ($14) {
  17652. $15 = (_stbi__get8($0)|0);
  17653. $16 = ($15<<24>>24)==(10);
  17654. if ($16) {
  17655. $$05 = 1;
  17656. return ($$05|0);
  17657. }
  17658. }
  17659. }
  17660. }
  17661. }
  17662. }
  17663. }
  17664. }
  17665. _stbi__err(11979);
  17666. $$05 = 0;
  17667. return ($$05|0);
  17668. }
  17669. function _stbi__get_chunk_header($0,$1) {
  17670. $0 = $0|0;
  17671. $1 = $1|0;
  17672. var $$sroa$4$0$$sroa_idx2 = 0, $2 = 0, $3 = 0, label = 0, sp = 0;
  17673. sp = STACKTOP;
  17674. $2 = (_stbi__get32be($1)|0);
  17675. $3 = (_stbi__get32be($1)|0);
  17676. HEAP32[$0>>2] = $2;
  17677. $$sroa$4$0$$sroa_idx2 = ((($0)) + 4|0);
  17678. HEAP32[$$sroa$4$0$$sroa_idx2>>2] = $3;
  17679. return;
  17680. }
  17681. function _stbi__skip($0,$1) {
  17682. $0 = $0|0;
  17683. $1 = $1|0;
  17684. var $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0;
  17685. var $8 = 0, $9 = 0, label = 0, sp = 0;
  17686. sp = STACKTOP;
  17687. $2 = ($1|0)<(0);
  17688. if ($2) {
  17689. $3 = ((($0)) + 172|0);
  17690. $4 = HEAP32[$3>>2]|0;
  17691. $5 = ((($0)) + 168|0);
  17692. HEAP32[$5>>2] = $4;
  17693. return;
  17694. }
  17695. $6 = ((($0)) + 16|0);
  17696. $7 = HEAP32[$6>>2]|0;
  17697. $8 = ($7|0)==(0|0);
  17698. if (!($8)) {
  17699. $9 = ((($0)) + 172|0);
  17700. $10 = HEAP32[$9>>2]|0;
  17701. $11 = ((($0)) + 168|0);
  17702. $12 = HEAP32[$11>>2]|0;
  17703. $13 = $10;
  17704. $14 = (($13) - ($12))|0;
  17705. $15 = ($14|0)<($1|0);
  17706. if ($15) {
  17707. HEAP32[$11>>2] = $10;
  17708. $16 = ((($0)) + 20|0);
  17709. $17 = HEAP32[$16>>2]|0;
  17710. $18 = ((($0)) + 28|0);
  17711. $19 = HEAP32[$18>>2]|0;
  17712. $20 = (($1) - ($14))|0;
  17713. FUNCTION_TABLE_vii[$17 & 63]($19,$20);
  17714. return;
  17715. }
  17716. }
  17717. $21 = ((($0)) + 168|0);
  17718. $22 = HEAP32[$21>>2]|0;
  17719. $23 = (($22) + ($1)|0);
  17720. HEAP32[$21>>2] = $23;
  17721. return;
  17722. }
  17723. function _stbi__get32be($0) {
  17724. $0 = $0|0;
  17725. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, label = 0, sp = 0;
  17726. sp = STACKTOP;
  17727. $1 = (_stbi__get16be($0)|0);
  17728. $2 = $1 << 16;
  17729. $3 = (_stbi__get16be($0)|0);
  17730. $4 = (($2) + ($3))|0;
  17731. return ($4|0);
  17732. }
  17733. function _stbi__get8($0) {
  17734. $0 = $0|0;
  17735. var $$0 = 0, $$sink6 = 0, $1 = 0, $10 = 0, $11 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  17736. sp = STACKTOP;
  17737. $1 = ((($0)) + 168|0);
  17738. $2 = HEAP32[$1>>2]|0;
  17739. $3 = ((($0)) + 172|0);
  17740. $4 = HEAP32[$3>>2]|0;
  17741. $5 = ($2>>>0)<($4>>>0);
  17742. do {
  17743. if ($5) {
  17744. $$sink6 = $2;
  17745. } else {
  17746. $6 = ((($0)) + 32|0);
  17747. $7 = HEAP32[$6>>2]|0;
  17748. $8 = ($7|0)==(0);
  17749. if ($8) {
  17750. $$0 = 0;
  17751. return ($$0|0);
  17752. } else {
  17753. _stbi__refill_buffer($0);
  17754. $9 = HEAP32[$1>>2]|0;
  17755. $$sink6 = $9;
  17756. break;
  17757. }
  17758. }
  17759. } while(0);
  17760. $10 = ((($$sink6)) + 1|0);
  17761. HEAP32[$1>>2] = $10;
  17762. $11 = HEAP8[$$sink6>>0]|0;
  17763. $$0 = $11;
  17764. return ($$0|0);
  17765. }
  17766. function _stbi__get16be($0) {
  17767. $0 = $0|0;
  17768. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  17769. sp = STACKTOP;
  17770. $1 = (_stbi__get8($0)|0);
  17771. $2 = $1&255;
  17772. $3 = $2 << 8;
  17773. $4 = (_stbi__get8($0)|0);
  17774. $5 = $4&255;
  17775. $6 = $3 | $5;
  17776. return ($6|0);
  17777. }
  17778. function _stbi__getn($0,$1,$2) {
  17779. $0 = $0|0;
  17780. $1 = $1|0;
  17781. $2 = $2|0;
  17782. var $$1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0;
  17783. var $29 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  17784. sp = STACKTOP;
  17785. $3 = ((($0)) + 16|0);
  17786. $4 = HEAP32[$3>>2]|0;
  17787. $5 = ($4|0)==(0|0);
  17788. if (!($5)) {
  17789. $6 = ((($0)) + 172|0);
  17790. $7 = HEAP32[$6>>2]|0;
  17791. $8 = ((($0)) + 168|0);
  17792. $9 = HEAP32[$8>>2]|0;
  17793. $10 = $9;
  17794. $11 = (($7) - ($10))|0;
  17795. $12 = ($11|0)<($2|0);
  17796. if ($12) {
  17797. _memcpy(($1|0),($9|0),($11|0))|0;
  17798. $13 = HEAP32[$3>>2]|0;
  17799. $14 = ((($0)) + 28|0);
  17800. $15 = HEAP32[$14>>2]|0;
  17801. $16 = (($1) + ($11)|0);
  17802. $17 = (($2) - ($11))|0;
  17803. $18 = (FUNCTION_TABLE_iiii[$13 & 15]($15,$16,$17)|0);
  17804. $19 = ($18|0)==($17|0);
  17805. $20 = $19&1;
  17806. $21 = HEAP32[$6>>2]|0;
  17807. HEAP32[$8>>2] = $21;
  17808. $$1 = $20;
  17809. return ($$1|0);
  17810. }
  17811. }
  17812. $22 = ((($0)) + 168|0);
  17813. $23 = HEAP32[$22>>2]|0;
  17814. $24 = (($23) + ($2)|0);
  17815. $25 = ((($0)) + 172|0);
  17816. $26 = HEAP32[$25>>2]|0;
  17817. $27 = ($24>>>0)>($26>>>0);
  17818. if ($27) {
  17819. $$1 = 0;
  17820. return ($$1|0);
  17821. }
  17822. _memcpy(($1|0),($23|0),($2|0))|0;
  17823. $28 = HEAP32[$22>>2]|0;
  17824. $29 = (($28) + ($2)|0);
  17825. HEAP32[$22>>2] = $29;
  17826. $$1 = 1;
  17827. return ($$1|0);
  17828. }
  17829. function _stbi_zlib_decode_malloc_guesssize_headerflag($0,$1,$2,$3,$4) {
  17830. $0 = $0|0;
  17831. $1 = $1|0;
  17832. $2 = $2|0;
  17833. $3 = $3|0;
  17834. $4 = $4|0;
  17835. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  17836. sp = STACKTOP;
  17837. STACKTOP = STACKTOP + 4080|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(4080|0);
  17838. $5 = sp;
  17839. $6 = (_stbi__malloc($2)|0);
  17840. $7 = ($6|0)==(0|0);
  17841. do {
  17842. if ($7) {
  17843. $$0 = 0;
  17844. } else {
  17845. HEAP32[$5>>2] = $0;
  17846. $8 = (($0) + ($1)|0);
  17847. $9 = ((($5)) + 4|0);
  17848. HEAP32[$9>>2] = $8;
  17849. $10 = (_stbi__do_zlib($5,$6,$2,1,$4)|0);
  17850. $11 = ($10|0)==(0);
  17851. $12 = ((($5)) + 20|0);
  17852. $13 = HEAP32[$12>>2]|0;
  17853. if ($11) {
  17854. _free($13);
  17855. $$0 = 0;
  17856. break;
  17857. }
  17858. $14 = ($3|0)==(0|0);
  17859. if ($14) {
  17860. $$0 = $13;
  17861. } else {
  17862. $15 = ((($5)) + 16|0);
  17863. $16 = HEAP32[$15>>2]|0;
  17864. $17 = $13;
  17865. $18 = (($16) - ($17))|0;
  17866. HEAP32[$3>>2] = $18;
  17867. $$0 = $13;
  17868. }
  17869. }
  17870. } while(0);
  17871. STACKTOP = sp;return ($$0|0);
  17872. }
  17873. function _stbi__create_png_image($0,$1,$2,$3,$4,$5,$6) {
  17874. $0 = $0|0;
  17875. $1 = $1|0;
  17876. $2 = $2|0;
  17877. $3 = $3|0;
  17878. $4 = $4|0;
  17879. $5 = $5|0;
  17880. $6 = $6|0;
  17881. var $$0103117 = 0, $$0106116 = 0, $$0107115 = 0, $$095119 = 0, $$099118 = 0, $$3102$ph = 0, $$398$ph = 0, $$4 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0;
  17882. var $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0;
  17883. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $60 = 0, $61 = 0;
  17884. var $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0;
  17885. var $80 = 0, $81 = 0, $82 = 0, $9 = 0, $or$cond = 0, label = 0, sp = 0;
  17886. sp = STACKTOP;
  17887. $7 = ($4|0)==(16);
  17888. $8 = $7 ? 2 : 1;
  17889. $9 = Math_imul($8, $3)|0;
  17890. $10 = ($6|0)==(0);
  17891. $11 = HEAP32[$0>>2]|0;
  17892. $12 = HEAP32[$11>>2]|0;
  17893. $13 = ((($11)) + 4|0);
  17894. $14 = HEAP32[$13>>2]|0;
  17895. if ($10) {
  17896. $15 = (_stbi__create_png_image_raw($0,$1,$2,$3,$12,$14,$4,$5)|0);
  17897. $$4 = $15;
  17898. return ($$4|0);
  17899. }
  17900. $16 = (_stbi__malloc_mad3($12,$14,$9)|0);
  17901. $17 = ((($0)) + 12|0);
  17902. $18 = ((($0)) + 12|0);
  17903. $$0103117 = 0;$$095119 = $1;$$099118 = $2;
  17904. while(1) {
  17905. $19 = HEAP32[$0>>2]|0;
  17906. $20 = HEAP32[$19>>2]|0;
  17907. $21 = (2980 + ($$0103117<<2)|0);
  17908. $22 = HEAP32[$21>>2]|0;
  17909. $23 = (3008 + ($$0103117<<2)|0);
  17910. $24 = HEAP32[$23>>2]|0;
  17911. $25 = (($20) + -1)|0;
  17912. $26 = (($25) - ($22))|0;
  17913. $27 = (($26) + ($24))|0;
  17914. $28 = (($27>>>0) / ($24>>>0))&-1;
  17915. $29 = ((($19)) + 4|0);
  17916. $30 = HEAP32[$29>>2]|0;
  17917. $31 = (3036 + ($$0103117<<2)|0);
  17918. $32 = HEAP32[$31>>2]|0;
  17919. $33 = (3064 + ($$0103117<<2)|0);
  17920. $34 = HEAP32[$33>>2]|0;
  17921. $35 = (($30) + -1)|0;
  17922. $36 = (($35) - ($32))|0;
  17923. $37 = (($36) + ($34))|0;
  17924. $38 = (($37>>>0) / ($34>>>0))&-1;
  17925. $39 = ($24>>>0)<=($27>>>0);
  17926. $40 = ($34>>>0)<=($37>>>0);
  17927. $or$cond = $39 & $40;
  17928. if ($or$cond) {
  17929. $41 = ((($19)) + 8|0);
  17930. $42 = HEAP32[$41>>2]|0;
  17931. $43 = Math_imul($28, $4)|0;
  17932. $44 = Math_imul($43, $42)|0;
  17933. $45 = (($44) + 7)|0;
  17934. $46 = $45 >> 3;
  17935. $47 = (($46) + 1)|0;
  17936. $48 = Math_imul($47, $38)|0;
  17937. $49 = (_stbi__create_png_image_raw($0,$$095119,$$099118,$3,$28,$38,$4,$5)|0);
  17938. $50 = ($49|0)==(0);
  17939. if ($50) {
  17940. label = 13;
  17941. break;
  17942. }
  17943. $51 = ($38|0)>(0);
  17944. if ($51) {
  17945. $52 = ($28|0)>(0);
  17946. $$0106116 = 0;
  17947. while(1) {
  17948. if ($52) {
  17949. $53 = HEAP32[$33>>2]|0;
  17950. $54 = Math_imul($53, $$0106116)|0;
  17951. $55 = HEAP32[$31>>2]|0;
  17952. $56 = (($54) + ($55))|0;
  17953. $57 = HEAP32[$23>>2]|0;
  17954. $58 = HEAP32[$21>>2]|0;
  17955. $59 = Math_imul($56, $9)|0;
  17956. $60 = Math_imul($$0106116, $28)|0;
  17957. $$0107115 = 0;
  17958. while(1) {
  17959. $61 = Math_imul($57, $$0107115)|0;
  17960. $62 = (($61) + ($58))|0;
  17961. $63 = HEAP32[$0>>2]|0;
  17962. $64 = HEAP32[$63>>2]|0;
  17963. $65 = Math_imul($59, $64)|0;
  17964. $66 = (($16) + ($65)|0);
  17965. $67 = Math_imul($62, $9)|0;
  17966. $68 = (($66) + ($67)|0);
  17967. $69 = HEAP32[$18>>2]|0;
  17968. $70 = (($$0107115) + ($60))|0;
  17969. $71 = Math_imul($70, $9)|0;
  17970. $72 = (($69) + ($71)|0);
  17971. _memcpy(($68|0),($72|0),($9|0))|0;
  17972. $73 = (($$0107115) + 1)|0;
  17973. $74 = ($73|0)<($28|0);
  17974. if ($74) {
  17975. $$0107115 = $73;
  17976. } else {
  17977. break;
  17978. }
  17979. }
  17980. }
  17981. $75 = (($$0106116) + 1)|0;
  17982. $76 = ($75|0)<($38|0);
  17983. if ($76) {
  17984. $$0106116 = $75;
  17985. } else {
  17986. break;
  17987. }
  17988. }
  17989. }
  17990. $77 = HEAP32[$17>>2]|0;
  17991. _free($77);
  17992. $78 = (($$095119) + ($48)|0);
  17993. $79 = (($$099118) - ($48))|0;
  17994. $$3102$ph = $79;$$398$ph = $78;
  17995. } else {
  17996. $$3102$ph = $$099118;$$398$ph = $$095119;
  17997. }
  17998. $80 = (($$0103117) + 1)|0;
  17999. $81 = ($80|0)<(7);
  18000. if ($81) {
  18001. $$0103117 = $80;$$095119 = $$398$ph;$$099118 = $$3102$ph;
  18002. } else {
  18003. label = 15;
  18004. break;
  18005. }
  18006. }
  18007. if ((label|0) == 13) {
  18008. _free($16);
  18009. $$4 = 0;
  18010. return ($$4|0);
  18011. }
  18012. else if ((label|0) == 15) {
  18013. $82 = ((($0)) + 12|0);
  18014. HEAP32[$82>>2] = $16;
  18015. $$4 = 1;
  18016. return ($$4|0);
  18017. }
  18018. return (0)|0;
  18019. }
  18020. function _stbi__compute_transparency16($0,$1,$2) {
  18021. $0 = $0|0;
  18022. $1 = $1|0;
  18023. $2 = $2|0;
  18024. var $$0323 = 0, $$04 = 0, $$1335 = 0, $$16 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  18025. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond9 = 0, $not$ = 0, label = 0, sp = 0;
  18026. sp = STACKTOP;
  18027. $3 = HEAP32[$0>>2]|0;
  18028. $4 = HEAP32[$3>>2]|0;
  18029. $5 = ((($3)) + 4|0);
  18030. $6 = HEAP32[$5>>2]|0;
  18031. $7 = Math_imul($6, $4)|0;
  18032. $8 = ((($0)) + 12|0);
  18033. $9 = HEAP32[$8>>2]|0;
  18034. switch ($2|0) {
  18035. case 2: {
  18036. $13 = ($7|0)==(0);
  18037. if ($13) {
  18038. return;
  18039. } else {
  18040. $$0323 = 0;$$04 = $9;
  18041. }
  18042. while(1) {
  18043. $14 = HEAP16[$$04>>1]|0;
  18044. $15 = HEAP16[$1>>1]|0;
  18045. $not$ = ($14<<16>>16)!=($15<<16>>16);
  18046. $16 = $not$ << 31 >> 31;
  18047. $17 = ((($$04)) + 2|0);
  18048. HEAP16[$17>>1] = $16;
  18049. $18 = ((($$04)) + 4|0);
  18050. $19 = (($$0323) + 1)|0;
  18051. $exitcond = ($19|0)==($7|0);
  18052. if ($exitcond) {
  18053. break;
  18054. } else {
  18055. $$0323 = $19;$$04 = $18;
  18056. }
  18057. }
  18058. return;
  18059. break;
  18060. }
  18061. case 4: {
  18062. $10 = ($7|0)==(0);
  18063. if ($10) {
  18064. return;
  18065. }
  18066. $11 = ((($1)) + 2|0);
  18067. $12 = ((($1)) + 4|0);
  18068. $$1335 = 0;$$16 = $9;
  18069. while(1) {
  18070. $20 = HEAP16[$$16>>1]|0;
  18071. $21 = HEAP16[$1>>1]|0;
  18072. $22 = ($20<<16>>16)==($21<<16>>16);
  18073. if ($22) {
  18074. $23 = ((($$16)) + 2|0);
  18075. $24 = HEAP16[$23>>1]|0;
  18076. $25 = HEAP16[$11>>1]|0;
  18077. $26 = ($24<<16>>16)==($25<<16>>16);
  18078. if ($26) {
  18079. $27 = ((($$16)) + 4|0);
  18080. $28 = HEAP16[$27>>1]|0;
  18081. $29 = HEAP16[$12>>1]|0;
  18082. $30 = ($28<<16>>16)==($29<<16>>16);
  18083. if ($30) {
  18084. $31 = ((($$16)) + 6|0);
  18085. HEAP16[$31>>1] = 0;
  18086. }
  18087. }
  18088. }
  18089. $32 = ((($$16)) + 8|0);
  18090. $33 = (($$1335) + 1)|0;
  18091. $exitcond9 = ($33|0)==($7|0);
  18092. if ($exitcond9) {
  18093. break;
  18094. } else {
  18095. $$1335 = $33;$$16 = $32;
  18096. }
  18097. }
  18098. return;
  18099. break;
  18100. }
  18101. default: {
  18102. ___assert_fail((11061|0),(10568|0),4569,(11113|0));
  18103. // unreachable;
  18104. }
  18105. }
  18106. }
  18107. function _stbi__compute_transparency($0,$1,$2) {
  18108. $0 = $0|0;
  18109. $1 = $1|0;
  18110. $2 = $2|0;
  18111. var $$0323 = 0, $$04 = 0, $$1335 = 0, $$16 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  18112. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond9 = 0, $not$ = 0, label = 0, sp = 0;
  18113. sp = STACKTOP;
  18114. $3 = HEAP32[$0>>2]|0;
  18115. $4 = HEAP32[$3>>2]|0;
  18116. $5 = ((($3)) + 4|0);
  18117. $6 = HEAP32[$5>>2]|0;
  18118. $7 = Math_imul($6, $4)|0;
  18119. $8 = ((($0)) + 12|0);
  18120. $9 = HEAP32[$8>>2]|0;
  18121. switch ($2|0) {
  18122. case 2: {
  18123. $13 = ($7|0)==(0);
  18124. if ($13) {
  18125. return;
  18126. } else {
  18127. $$0323 = 0;$$04 = $9;
  18128. }
  18129. while(1) {
  18130. $14 = HEAP8[$$04>>0]|0;
  18131. $15 = HEAP8[$1>>0]|0;
  18132. $not$ = ($14<<24>>24)!=($15<<24>>24);
  18133. $16 = $not$ << 31 >> 31;
  18134. $17 = ((($$04)) + 1|0);
  18135. HEAP8[$17>>0] = $16;
  18136. $18 = ((($$04)) + 2|0);
  18137. $19 = (($$0323) + 1)|0;
  18138. $exitcond = ($19|0)==($7|0);
  18139. if ($exitcond) {
  18140. break;
  18141. } else {
  18142. $$0323 = $19;$$04 = $18;
  18143. }
  18144. }
  18145. return;
  18146. break;
  18147. }
  18148. case 4: {
  18149. $10 = ($7|0)==(0);
  18150. if ($10) {
  18151. return;
  18152. }
  18153. $11 = ((($1)) + 1|0);
  18154. $12 = ((($1)) + 2|0);
  18155. $$1335 = 0;$$16 = $9;
  18156. while(1) {
  18157. $20 = HEAP8[$$16>>0]|0;
  18158. $21 = HEAP8[$1>>0]|0;
  18159. $22 = ($20<<24>>24)==($21<<24>>24);
  18160. if ($22) {
  18161. $23 = ((($$16)) + 1|0);
  18162. $24 = HEAP8[$23>>0]|0;
  18163. $25 = HEAP8[$11>>0]|0;
  18164. $26 = ($24<<24>>24)==($25<<24>>24);
  18165. if ($26) {
  18166. $27 = ((($$16)) + 2|0);
  18167. $28 = HEAP8[$27>>0]|0;
  18168. $29 = HEAP8[$12>>0]|0;
  18169. $30 = ($28<<24>>24)==($29<<24>>24);
  18170. if ($30) {
  18171. $31 = ((($$16)) + 3|0);
  18172. HEAP8[$31>>0] = 0;
  18173. }
  18174. }
  18175. }
  18176. $32 = ((($$16)) + 4|0);
  18177. $33 = (($$1335) + 1)|0;
  18178. $exitcond9 = ($33|0)==($7|0);
  18179. if ($exitcond9) {
  18180. break;
  18181. } else {
  18182. $$1335 = $33;$$16 = $32;
  18183. }
  18184. }
  18185. return;
  18186. break;
  18187. }
  18188. default: {
  18189. ___assert_fail((11061|0),(10568|0),4544,(11086|0));
  18190. // unreachable;
  18191. }
  18192. }
  18193. }
  18194. function _stbi__de_iphone($0) {
  18195. $0 = $0|0;
  18196. var $$05158 = 0, $$059 = 0, $$15263 = 0, $$164 = 0, $$25360 = 0, $$261 = 0, $$sink = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0;
  18197. var $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0;
  18198. var $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond68 = 0, $exitcond69 = 0, label = 0, sp = 0;
  18199. sp = STACKTOP;
  18200. $1 = HEAP32[$0>>2]|0;
  18201. $2 = HEAP32[$1>>2]|0;
  18202. $3 = ((($1)) + 4|0);
  18203. $4 = HEAP32[$3>>2]|0;
  18204. $5 = Math_imul($4, $2)|0;
  18205. $6 = ((($0)) + 12|0);
  18206. $7 = HEAP32[$6>>2]|0;
  18207. $8 = ((($1)) + 12|0);
  18208. $9 = HEAP32[$8>>2]|0;
  18209. switch ($9|0) {
  18210. case 3: {
  18211. $10 = ($5|0)==(0);
  18212. if ($10) {
  18213. return;
  18214. } else {
  18215. $$05158 = $7;$$059 = 0;
  18216. }
  18217. while(1) {
  18218. $11 = HEAP8[$$05158>>0]|0;
  18219. $12 = ((($$05158)) + 2|0);
  18220. $13 = HEAP8[$12>>0]|0;
  18221. HEAP8[$$05158>>0] = $13;
  18222. HEAP8[$12>>0] = $11;
  18223. $14 = ((($$05158)) + 3|0);
  18224. $15 = (($$059) + 1)|0;
  18225. $exitcond = ($15|0)==($5|0);
  18226. if ($exitcond) {
  18227. break;
  18228. } else {
  18229. $$05158 = $14;$$059 = $15;
  18230. }
  18231. }
  18232. return;
  18233. break;
  18234. }
  18235. case 4: {
  18236. $16 = HEAP32[5903]|0;
  18237. $17 = ($16|0)==(0);
  18238. $18 = ($5|0)!=(0);
  18239. if ($17) {
  18240. if ($18) {
  18241. $$25360 = $7;$$261 = 0;
  18242. } else {
  18243. return;
  18244. }
  18245. while(1) {
  18246. $42 = HEAP8[$$25360>>0]|0;
  18247. $43 = ((($$25360)) + 2|0);
  18248. $44 = HEAP8[$43>>0]|0;
  18249. HEAP8[$$25360>>0] = $44;
  18250. HEAP8[$43>>0] = $42;
  18251. $45 = ((($$25360)) + 4|0);
  18252. $46 = (($$261) + 1)|0;
  18253. $exitcond68 = ($46|0)==($5|0);
  18254. if ($exitcond68) {
  18255. break;
  18256. } else {
  18257. $$25360 = $45;$$261 = $46;
  18258. }
  18259. }
  18260. return;
  18261. }
  18262. if ($18) {
  18263. $$15263 = $7;$$164 = 0;
  18264. } else {
  18265. return;
  18266. }
  18267. while(1) {
  18268. $19 = ((($$15263)) + 3|0);
  18269. $20 = HEAP8[$19>>0]|0;
  18270. $21 = HEAP8[$$15263>>0]|0;
  18271. $22 = ($20<<24>>24)==(0);
  18272. $23 = ((($$15263)) + 2|0);
  18273. $24 = HEAP8[$23>>0]|0;
  18274. if ($22) {
  18275. HEAP8[$$15263>>0] = $24;
  18276. $$sink = $21;
  18277. } else {
  18278. $25 = $24&255;
  18279. $26 = ($25*255)|0;
  18280. $27 = $20&255;
  18281. $28 = (($26>>>0) / ($27>>>0))&-1;
  18282. $29 = $28&255;
  18283. HEAP8[$$15263>>0] = $29;
  18284. $30 = ((($$15263)) + 1|0);
  18285. $31 = HEAP8[$30>>0]|0;
  18286. $32 = $31&255;
  18287. $33 = ($32*255)|0;
  18288. $34 = (($33>>>0) / ($27>>>0))&-1;
  18289. $35 = $34&255;
  18290. HEAP8[$30>>0] = $35;
  18291. $36 = $21&255;
  18292. $37 = ($36*255)|0;
  18293. $38 = (($37>>>0) / ($27>>>0))&-1;
  18294. $39 = $38&255;
  18295. $$sink = $39;
  18296. }
  18297. HEAP8[$23>>0] = $$sink;
  18298. $40 = ((($$15263)) + 4|0);
  18299. $41 = (($$164) + 1)|0;
  18300. $exitcond69 = ($41|0)==($5|0);
  18301. if ($exitcond69) {
  18302. break;
  18303. } else {
  18304. $$15263 = $40;$$164 = $41;
  18305. }
  18306. }
  18307. return;
  18308. break;
  18309. }
  18310. default: {
  18311. ___assert_fail((11027|0),(10568|0),4650,(11045|0));
  18312. // unreachable;
  18313. }
  18314. }
  18315. }
  18316. function _stbi__expand_png_palette($0,$1,$2) {
  18317. $0 = $0|0;
  18318. $1 = $1|0;
  18319. $2 = $2|0;
  18320. var $$0 = 0, $$0574 = 0, $$0583 = 0, $$1595 = 0, $$16 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0;
  18321. var $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0;
  18322. var $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond9 = 0, label = 0, sp = 0;
  18323. sp = STACKTOP;
  18324. $3 = HEAP32[$0>>2]|0;
  18325. $4 = HEAP32[$3>>2]|0;
  18326. $5 = ((($3)) + 4|0);
  18327. $6 = HEAP32[$5>>2]|0;
  18328. $7 = Math_imul($6, $4)|0;
  18329. $8 = ((($0)) + 12|0);
  18330. $9 = HEAP32[$8>>2]|0;
  18331. $10 = (_stbi__malloc_mad2($7,$2)|0);
  18332. $11 = ($10|0)==(0|0);
  18333. if ($11) {
  18334. _stbi__err(10623);
  18335. $$0 = 0;
  18336. return ($$0|0);
  18337. }
  18338. $12 = ($2|0)==(3);
  18339. $13 = ($7|0)!=(0);
  18340. if ($12) {
  18341. if ($13) {
  18342. $$0574 = 0;$$0583 = $10;
  18343. while(1) {
  18344. $14 = (($9) + ($$0574)|0);
  18345. $15 = HEAP8[$14>>0]|0;
  18346. $16 = $15&255;
  18347. $17 = $16 << 2;
  18348. $18 = (($1) + ($17)|0);
  18349. $19 = HEAP8[$18>>0]|0;
  18350. HEAP8[$$0583>>0] = $19;
  18351. $20 = $17 | 1;
  18352. $21 = (($1) + ($20)|0);
  18353. $22 = HEAP8[$21>>0]|0;
  18354. $23 = ((($$0583)) + 1|0);
  18355. HEAP8[$23>>0] = $22;
  18356. $24 = $17 | 2;
  18357. $25 = (($1) + ($24)|0);
  18358. $26 = HEAP8[$25>>0]|0;
  18359. $27 = ((($$0583)) + 2|0);
  18360. HEAP8[$27>>0] = $26;
  18361. $28 = ((($$0583)) + 3|0);
  18362. $29 = (($$0574) + 1)|0;
  18363. $exitcond = ($29|0)==($7|0);
  18364. if ($exitcond) {
  18365. break;
  18366. } else {
  18367. $$0574 = $29;$$0583 = $28;
  18368. }
  18369. }
  18370. }
  18371. } else {
  18372. if ($13) {
  18373. $$1595 = $10;$$16 = 0;
  18374. while(1) {
  18375. $30 = (($9) + ($$16)|0);
  18376. $31 = HEAP8[$30>>0]|0;
  18377. $32 = $31&255;
  18378. $33 = $32 << 2;
  18379. $34 = (($1) + ($33)|0);
  18380. $35 = HEAP8[$34>>0]|0;
  18381. HEAP8[$$1595>>0] = $35;
  18382. $36 = $33 | 1;
  18383. $37 = (($1) + ($36)|0);
  18384. $38 = HEAP8[$37>>0]|0;
  18385. $39 = ((($$1595)) + 1|0);
  18386. HEAP8[$39>>0] = $38;
  18387. $40 = $33 | 2;
  18388. $41 = (($1) + ($40)|0);
  18389. $42 = HEAP8[$41>>0]|0;
  18390. $43 = ((($$1595)) + 2|0);
  18391. HEAP8[$43>>0] = $42;
  18392. $44 = $33 | 3;
  18393. $45 = (($1) + ($44)|0);
  18394. $46 = HEAP8[$45>>0]|0;
  18395. $47 = ((($$1595)) + 3|0);
  18396. HEAP8[$47>>0] = $46;
  18397. $48 = ((($$1595)) + 4|0);
  18398. $49 = (($$16) + 1)|0;
  18399. $exitcond9 = ($49|0)==($7|0);
  18400. if ($exitcond9) {
  18401. break;
  18402. } else {
  18403. $$1595 = $48;$$16 = $49;
  18404. }
  18405. }
  18406. }
  18407. }
  18408. $50 = HEAP32[$8>>2]|0;
  18409. _free($50);
  18410. HEAP32[$8>>2] = $10;
  18411. $$0 = 1;
  18412. return ($$0|0);
  18413. }
  18414. function _stbi__malloc_mad2($0,$1) {
  18415. $0 = $0|0;
  18416. $1 = $1|0;
  18417. var $$0 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, label = 0, sp = 0;
  18418. sp = STACKTOP;
  18419. $2 = (_stbi__mad2sizes_valid($0,$1)|0);
  18420. $3 = ($2|0)==(0);
  18421. if ($3) {
  18422. $$0 = 0;
  18423. return ($$0|0);
  18424. }
  18425. $4 = Math_imul($1, $0)|0;
  18426. $5 = (_stbi__malloc($4)|0);
  18427. $$0 = $5;
  18428. return ($$0|0);
  18429. }
  18430. function _stbi__mad2sizes_valid($0,$1) {
  18431. $0 = $0|0;
  18432. $1 = $1|0;
  18433. var $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, label = 0, sp = 0;
  18434. sp = STACKTOP;
  18435. $2 = (_stbi__mul2sizes_valid($0,$1)|0);
  18436. $3 = ($2|0)==(0);
  18437. if ($3) {
  18438. $8 = 0;
  18439. $7 = $8&1;
  18440. return ($7|0);
  18441. }
  18442. $4 = Math_imul($1, $0)|0;
  18443. $5 = (_stbi__addsizes_valid($4)|0);
  18444. $6 = ($5|0)!=(0);
  18445. $8 = $6;
  18446. $7 = $8&1;
  18447. return ($7|0);
  18448. }
  18449. function _stbi__create_png_image_raw($0,$1,$2,$3,$4,$5,$6,$7) {
  18450. $0 = $0|0;
  18451. $1 = $1|0;
  18452. $2 = $2|0;
  18453. $3 = $3|0;
  18454. $4 = $4|0;
  18455. $5 = $5|0;
  18456. $6 = $6|0;
  18457. $7 = $7|0;
  18458. var $$0568 = 0, $$0568724 = 0, $$0568725 = 0, $$0571$lcssa = 0, $$0571715 = 0, $$0574$lcssa = 0, $$0574714 = 0, $$0577817 = 0, $$0588 = 0, $$0597 = 0, $$0608816 = 0, $$0611815 = 0, $$0614 = 0, $$0614793 = 0, $$0614796 = 0, $$0623814 = 0, $$0625734 = 0, $$0731 = 0, $$1 = 0, $$10635764 = 0;
  18459. var $$11$ph = 0, $$11636755 = 0, $$12747 = 0, $$13739 = 0, $$14$lcssa = 0, $$14713 = 0, $$15$lcssa = 0, $$15705 = 0, $$1572$lcssa = 0, $$1572707 = 0, $$1575$lcssa = 0, $$1575706 = 0, $$1578 = 0, $$16$lcssa = 0, $$1609 = 0, $$1612 = 0, $$1615 = 0, $$1615785 = 0, $$1615788 = 0, $$1624727 = 0;
  18460. var $$1626812 = 0, $$16700 = 0, $$1721 = 0, $$1722 = 0, $$2 = 0, $$2573$lcssa = 0, $$2573702 = 0, $$2579795 = 0, $$2599794 = 0, $$2616 = 0, $$2616776 = 0, $$2616780 = 0, $$2627810 = 0, $$3580787 = 0, $$3592778 = 0, $$3600786 = 0, $$3617 = 0, $$3617767 = 0, $$3617771 = 0, $$3628808 = 0;
  18461. var $$4$lcssa = 0, $$4581779 = 0, $$4593769 = 0, $$4601777 = 0, $$4618 = 0, $$4618758 = 0, $$4618762 = 0, $$4629806 = 0, $$4701 = 0, $$5582770 = 0, $$5594760 = 0, $$5602768 = 0, $$5619 = 0, $$5619750 = 0, $$5619753 = 0, $$5630804 = 0, $$6583761 = 0, $$6603759 = 0, $$6620 = 0, $$6620742 = 0;
  18462. var $$6620745 = 0, $$6631802 = 0, $$7584752 = 0, $$7604751 = 0, $$7621798 = 0, $$7632790 = 0, $$8585744 = 0, $$8605743 = 0, $$8622729 = 0, $$8633782 = 0, $$9586 = 0, $$9606799 = 0, $$9634773 = 0, $$not = 0, $$sink = 0, $$sink1 = 0, $$sink641 = 0, $10 = 0, $100 = 0, $101 = 0;
  18463. var $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0;
  18464. var $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0;
  18465. var $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0;
  18466. var $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0;
  18467. var $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0;
  18468. var $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0;
  18469. var $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0, $22 = 0, $220 = 0, $221 = 0, $222 = 0, $223 = 0, $224 = 0, $225 = 0, $226 = 0, $227 = 0, $228 = 0, $229 = 0;
  18470. var $23 = 0, $230 = 0, $231 = 0, $232 = 0, $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0, $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0;
  18471. var $248 = 0, $249 = 0, $25 = 0, $250 = 0, $251 = 0, $252 = 0, $253 = 0, $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0, $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0;
  18472. var $266 = 0, $267 = 0, $268 = 0, $269 = 0, $27 = 0, $270 = 0, $271 = 0, $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0, $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0;
  18473. var $284 = 0, $285 = 0, $286 = 0, $287 = 0, $288 = 0, $289 = 0, $29 = 0, $290 = 0, $291 = 0, $292 = 0, $293 = 0, $294 = 0, $295 = 0, $296 = 0, $297 = 0, $298 = 0, $299 = 0, $30 = 0, $300 = 0, $301 = 0;
  18474. var $302 = 0, $303 = 0, $304 = 0, $305 = 0, $306 = 0, $307 = 0, $308 = 0, $309 = 0, $31 = 0, $310 = 0, $311 = 0, $312 = 0, $313 = 0, $314 = 0, $315 = 0, $316 = 0, $317 = 0, $318 = 0, $319 = 0, $32 = 0;
  18475. var $320 = 0, $321 = 0, $322 = 0, $323 = 0, $324 = 0, $325 = 0, $326 = 0, $327 = 0, $328 = 0, $329 = 0, $33 = 0, $330 = 0, $331 = 0, $332 = 0, $333 = 0, $334 = 0, $335 = 0, $336 = 0, $337 = 0, $338 = 0;
  18476. var $339 = 0, $34 = 0, $340 = 0, $341 = 0, $342 = 0, $343 = 0, $344 = 0, $345 = 0, $346 = 0, $347 = 0, $348 = 0, $349 = 0, $35 = 0, $350 = 0, $351 = 0, $352 = 0, $353 = 0, $354 = 0, $355 = 0, $356 = 0;
  18477. var $357 = 0, $358 = 0, $359 = 0, $36 = 0, $360 = 0, $361 = 0, $362 = 0, $363 = 0, $364 = 0, $365 = 0, $366 = 0, $367 = 0, $368 = 0, $369 = 0, $37 = 0, $370 = 0, $371 = 0, $372 = 0, $373 = 0, $374 = 0;
  18478. var $375 = 0, $376 = 0, $377 = 0, $378 = 0, $379 = 0, $38 = 0, $380 = 0, $381 = 0, $382 = 0, $383 = 0, $384 = 0, $385 = 0, $386 = 0, $387 = 0, $388 = 0, $389 = 0, $39 = 0, $390 = 0, $391 = 0, $392 = 0;
  18479. var $393 = 0, $394 = 0, $395 = 0, $396 = 0, $397 = 0, $398 = 0, $399 = 0, $40 = 0, $400 = 0, $401 = 0, $402 = 0, $403 = 0, $404 = 0, $405 = 0, $406 = 0, $407 = 0, $408 = 0, $409 = 0, $41 = 0, $410 = 0;
  18480. var $411 = 0, $412 = 0, $413 = 0, $414 = 0, $415 = 0, $416 = 0, $417 = 0, $418 = 0, $419 = 0, $42 = 0, $420 = 0, $421 = 0, $422 = 0, $423 = 0, $424 = 0, $425 = 0, $426 = 0, $427 = 0, $428 = 0, $429 = 0;
  18481. var $43 = 0, $430 = 0, $431 = 0, $432 = 0, $433 = 0, $434 = 0, $435 = 0, $436 = 0, $437 = 0, $438 = 0, $439 = 0, $44 = 0, $440 = 0, $441 = 0, $442 = 0, $443 = 0, $444 = 0, $445 = 0, $446 = 0, $447 = 0;
  18482. var $448 = 0, $449 = 0, $45 = 0, $450 = 0, $451 = 0, $452 = 0, $453 = 0, $454 = 0, $455 = 0, $456 = 0, $457 = 0, $458 = 0, $459 = 0, $46 = 0, $460 = 0, $461 = 0, $462 = 0, $463 = 0, $464 = 0, $465 = 0;
  18483. var $466 = 0, $467 = 0, $468 = 0, $469 = 0, $47 = 0, $470 = 0, $471 = 0, $472 = 0, $473 = 0, $474 = 0, $475 = 0, $476 = 0, $477 = 0, $478 = 0, $479 = 0, $48 = 0, $480 = 0, $481 = 0, $482 = 0, $483 = 0;
  18484. var $484 = 0, $485 = 0, $486 = 0, $487 = 0, $488 = 0, $489 = 0, $49 = 0, $490 = 0, $491 = 0, $492 = 0, $493 = 0, $494 = 0, $495 = 0, $496 = 0, $497 = 0, $498 = 0, $499 = 0, $50 = 0, $500 = 0, $501 = 0;
  18485. var $502 = 0, $503 = 0, $504 = 0, $505 = 0, $506 = 0, $507 = 0, $508 = 0, $509 = 0, $51 = 0, $510 = 0, $511 = 0, $512 = 0, $513 = 0, $514 = 0, $515 = 0, $516 = 0, $517 = 0, $518 = 0, $519 = 0, $52 = 0;
  18486. var $520 = 0, $521 = 0, $522 = 0, $523 = 0, $524 = 0, $525 = 0, $526 = 0, $527 = 0, $528 = 0, $529 = 0, $53 = 0, $530 = 0, $531 = 0, $532 = 0, $533 = 0, $534 = 0, $535 = 0, $536 = 0, $537 = 0, $538 = 0;
  18487. var $539 = 0, $54 = 0, $540 = 0, $541 = 0, $542 = 0, $543 = 0, $544 = 0, $545 = 0, $546 = 0, $547 = 0, $548 = 0, $549 = 0, $55 = 0, $550 = 0, $551 = 0, $552 = 0, $553 = 0, $554 = 0, $555 = 0, $556 = 0;
  18488. var $557 = 0, $558 = 0, $559 = 0, $56 = 0, $560 = 0, $561 = 0, $562 = 0, $563 = 0, $564 = 0, $565 = 0, $566 = 0, $567 = 0, $568 = 0, $569 = 0, $57 = 0, $570 = 0, $571 = 0, $572 = 0, $573 = 0, $574 = 0;
  18489. var $575 = 0, $576 = 0, $577 = 0, $578 = 0, $579 = 0, $58 = 0, $580 = 0, $581 = 0, $582 = 0, $583 = 0, $584 = 0, $585 = 0, $586 = 0, $587 = 0, $588 = 0, $589 = 0, $59 = 0, $590 = 0, $591 = 0, $592 = 0;
  18490. var $593 = 0, $594 = 0, $595 = 0, $596 = 0, $597 = 0, $598 = 0, $599 = 0, $60 = 0, $600 = 0, $601 = 0, $602 = 0, $603 = 0, $604 = 0, $605 = 0, $606 = 0, $607 = 0, $608 = 0, $609 = 0, $61 = 0, $610 = 0;
  18491. var $611 = 0, $612 = 0, $613 = 0, $614 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0;
  18492. var $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0;
  18493. var $96 = 0, $97 = 0, $98 = 0, $99 = 0, $brmerge = 0, $brmerge894 = 0, $exitcond = 0, $exitcond864 = 0, $exitcond865 = 0, $exitcond867 = 0, $exitcond869 = 0, $exitcond871 = 0, $exitcond873 = 0, $exitcond875 = 0, $exitcond877 = 0, $exitcond880 = 0, $exitcond881 = 0, $exitcond882 = 0, $exitcond883 = 0, $exitcond884 = 0;
  18494. var $exitcond885 = 0, $exitcond886 = 0, $indvars$iv = 0, $indvars$iv$next = 0, $indvars$iv$next849 = 0, $indvars$iv$next852 = 0, $indvars$iv$next855 = 0, $indvars$iv$next858 = 0, $indvars$iv$next861 = 0, $indvars$iv848 = 0, $indvars$iv851 = 0, $indvars$iv854 = 0, $indvars$iv857 = 0, $indvars$iv860 = 0, $or$cond = 0, $scevgep = 0, $scevgep850 = 0, $scevgep853 = 0, $scevgep856 = 0, $scevgep859 = 0;
  18495. var $scevgep862 = 0, $scevgep866 = 0, $scevgep868 = 0, $scevgep870 = 0, $scevgep872 = 0, $scevgep874 = 0, $scevgep876 = 0, $scevgep879 = 0, $trunc = 0, $trunc637 = 0, $trunc638 = 0, label = 0, sp = 0;
  18496. sp = STACKTOP;
  18497. $8 = ($6|0)==(16);
  18498. $9 = $8 ? 2 : 1;
  18499. $10 = HEAP32[$0>>2]|0;
  18500. $11 = Math_imul($4, $3)|0;
  18501. $12 = Math_imul($9, $11)|0;
  18502. $13 = ((($10)) + 8|0);
  18503. $14 = HEAP32[$13>>2]|0;
  18504. $15 = Math_imul($9, $3)|0;
  18505. $16 = Math_imul($14, $9)|0;
  18506. $17 = ($14|0)==($3|0);
  18507. $18 = (($14) + 1)|0;
  18508. $19 = ($18|0)==($3|0);
  18509. $or$cond = $17 | $19;
  18510. if (!($or$cond)) {
  18511. ___assert_fail((11142|0),(10568|0),4294,(11183|0));
  18512. // unreachable;
  18513. }
  18514. $20 = (_stbi__malloc_mad3($4,$5,$15)|0);
  18515. $21 = ((($0)) + 12|0);
  18516. HEAP32[$21>>2] = $20;
  18517. $22 = ($20|0)==(0|0);
  18518. if ($22) {
  18519. _stbi__err(10623);
  18520. $$2 = 0;
  18521. return ($$2|0);
  18522. }
  18523. $23 = Math_imul($14, $4)|0;
  18524. $24 = Math_imul($23, $6)|0;
  18525. $25 = (($24) + 7)|0;
  18526. $26 = $25 >>> 3;
  18527. $27 = (($26) + 1)|0;
  18528. $28 = Math_imul($27, $5)|0;
  18529. $29 = HEAP32[$10>>2]|0;
  18530. $30 = ($29|0)==($4|0);
  18531. if ($30) {
  18532. $31 = ((($10)) + 4|0);
  18533. $32 = HEAP32[$31>>2]|0;
  18534. $33 = ($32|0)==($5|0);
  18535. if ($33) {
  18536. $34 = ($28|0)==($2|0);
  18537. if (!($34)) {
  18538. _stbi__err(11210);
  18539. $$2 = 0;
  18540. return ($$2|0);
  18541. }
  18542. } else {
  18543. label = 9;
  18544. }
  18545. } else {
  18546. label = 9;
  18547. }
  18548. if ((label|0) == 9) {
  18549. $35 = ($28>>>0)>($2>>>0);
  18550. if ($35) {
  18551. _stbi__err(11210);
  18552. $$2 = 0;
  18553. return ($$2|0);
  18554. }
  18555. }
  18556. $36 = ($5|0)==(0);
  18557. L18: do {
  18558. if (!($36)) {
  18559. $37 = ($6|0)<(8);
  18560. $38 = ($26>>>0)>($4>>>0);
  18561. $39 = (($11) - ($26))|0;
  18562. $40 = (0 - ($12))|0;
  18563. $41 = ($6|0)==(8);
  18564. $brmerge = $37 | $17;
  18565. $42 = ($4|0)==(0);
  18566. $$0614793 = (($4) + -1)|0;
  18567. $43 = ($$0614793|0)==(0);
  18568. $$1615785 = (($4) + -1)|0;
  18569. $44 = ($$1615785|0)==(0);
  18570. $$2616776 = (($4) + -1)|0;
  18571. $45 = ($$2616776|0)==(0);
  18572. $$3617767 = (($4) + -1)|0;
  18573. $46 = ($$3617767|0)==(0);
  18574. $$4618758 = (($4) + -1)|0;
  18575. $47 = ($$4618758|0)==(0);
  18576. $$5619750 = (($4) + -1)|0;
  18577. $48 = ($$5619750|0)==(0);
  18578. $$6620742 = (($4) + -1)|0;
  18579. $49 = ($$6620742|0)==(0);
  18580. $$not = $8 ^ 1;
  18581. $brmerge894 = $42 | $$not;
  18582. $$0577817 = $1;$$0608816 = $4;$$0611815 = $16;$$0623814 = 0;
  18583. while(1) {
  18584. $50 = HEAP32[$21>>2]|0;
  18585. $51 = Math_imul($$0623814, $12)|0;
  18586. $52 = (($50) + ($51)|0);
  18587. $53 = ((($$0577817)) + 1|0);
  18588. $54 = HEAP8[$$0577817>>0]|0;
  18589. $55 = $54&255;
  18590. $56 = ($54&255)>(4);
  18591. if ($56) {
  18592. label = 105;
  18593. break;
  18594. }
  18595. if ($37) {
  18596. if ($38) {
  18597. label = 16;
  18598. break;
  18599. }
  18600. $57 = (($52) + ($39)|0);
  18601. $$0597 = $57;$$1609 = $26;$$1612 = 1;
  18602. } else {
  18603. $$0597 = $52;$$1609 = $$0608816;$$1612 = $$0611815;
  18604. }
  18605. $58 = (($$0597) + ($40)|0);
  18606. $59 = ($$0623814|0)==(0);
  18607. if ($59) {
  18608. $60 = (11249 + ($55)|0);
  18609. $61 = HEAP8[$60>>0]|0;
  18610. $62 = $61&255;
  18611. $$0588 = $62;
  18612. } else {
  18613. $$0588 = $55;
  18614. }
  18615. $63 = ($$1612|0)>(0);
  18616. L30: do {
  18617. if ($63) {
  18618. $trunc638 = $$0588&255;
  18619. $$0625734 = 0;
  18620. while(1) {
  18621. switch ($trunc638<<24>>24) {
  18622. case 0: {
  18623. $64 = (($53) + ($$0625734)|0);
  18624. $65 = HEAP8[$64>>0]|0;
  18625. $$sink = $65;
  18626. label = 30;
  18627. break;
  18628. }
  18629. case 1: {
  18630. $66 = (($53) + ($$0625734)|0);
  18631. $67 = HEAP8[$66>>0]|0;
  18632. $$sink = $67;
  18633. label = 30;
  18634. break;
  18635. }
  18636. case 2: {
  18637. $68 = (($53) + ($$0625734)|0);
  18638. $69 = HEAP8[$68>>0]|0;
  18639. $70 = $69&255;
  18640. $71 = (($58) + ($$0625734)|0);
  18641. $72 = HEAP8[$71>>0]|0;
  18642. $73 = $72&255;
  18643. $74 = (($73) + ($70))|0;
  18644. $75 = $74&255;
  18645. $$sink = $75;
  18646. label = 30;
  18647. break;
  18648. }
  18649. case 3: {
  18650. $76 = (($53) + ($$0625734)|0);
  18651. $77 = HEAP8[$76>>0]|0;
  18652. $78 = $77&255;
  18653. $79 = (($58) + ($$0625734)|0);
  18654. $80 = HEAP8[$79>>0]|0;
  18655. $81 = $80&255;
  18656. $82 = $81 >>> 1;
  18657. $83 = (($82) + ($78))|0;
  18658. $84 = $83&255;
  18659. $$sink = $84;
  18660. label = 30;
  18661. break;
  18662. }
  18663. case 4: {
  18664. $85 = (($53) + ($$0625734)|0);
  18665. $86 = HEAP8[$85>>0]|0;
  18666. $87 = $86&255;
  18667. $88 = (($58) + ($$0625734)|0);
  18668. $89 = HEAP8[$88>>0]|0;
  18669. $90 = $89&255;
  18670. $91 = (_stbi__paeth(0,$90,0)|0);
  18671. $92 = (($91) + ($87))|0;
  18672. $93 = $92&255;
  18673. $$sink = $93;
  18674. label = 30;
  18675. break;
  18676. }
  18677. case 5: {
  18678. $94 = (($53) + ($$0625734)|0);
  18679. $95 = HEAP8[$94>>0]|0;
  18680. $$sink = $95;
  18681. label = 30;
  18682. break;
  18683. }
  18684. case 6: {
  18685. $96 = (($53) + ($$0625734)|0);
  18686. $97 = HEAP8[$96>>0]|0;
  18687. $$sink = $97;
  18688. label = 30;
  18689. break;
  18690. }
  18691. default: {
  18692. }
  18693. }
  18694. if ((label|0) == 30) {
  18695. label = 0;
  18696. $$sink1 = (($$0597) + ($$0625734)|0);
  18697. HEAP8[$$sink1>>0] = $$sink;
  18698. }
  18699. $98 = (($$0625734) + 1)|0;
  18700. $exitcond864 = ($98|0)==($$1612|0);
  18701. if ($exitcond864) {
  18702. break L30;
  18703. } else {
  18704. $$0625734 = $98;
  18705. }
  18706. }
  18707. }
  18708. } while(0);
  18709. do {
  18710. if ($41) {
  18711. if (!($17)) {
  18712. $99 = (($$0597) + ($14)|0);
  18713. HEAP8[$99>>0] = -1;
  18714. }
  18715. $100 = (($53) + ($14)|0);
  18716. $$1578 = $100;$$sink641 = $3;
  18717. } else {
  18718. if (!($8)) {
  18719. $105 = ((($$0577817)) + 2|0);
  18720. $$1578 = $105;$$sink641 = 1;
  18721. break;
  18722. }
  18723. if (!($17)) {
  18724. $101 = (($$1612) + 1)|0;
  18725. $102 = (($$0597) + ($101)|0);
  18726. $103 = (($$0597) + ($$1612)|0);
  18727. HEAP8[$103>>0] = -1;
  18728. HEAP8[$102>>0] = -1;
  18729. }
  18730. $104 = (($53) + ($$1612)|0);
  18731. $$1578 = $104;$$sink641 = $15;
  18732. }
  18733. } while(0);
  18734. $106 = (($$0597) + ($$sink641)|0);
  18735. $107 = (($58) + ($$sink641)|0);
  18736. if ($brmerge) {
  18737. $108 = (($$1609) + -1)|0;
  18738. $109 = Math_imul($108, $$1612)|0;
  18739. $trunc637 = $$0588&255;
  18740. switch ($trunc637<<24>>24) {
  18741. case 0: {
  18742. _memcpy(($106|0),($$1578|0),($109|0))|0;
  18743. break;
  18744. }
  18745. case 1: {
  18746. $115 = ($109|0)>(0);
  18747. if ($115) {
  18748. $$1626812 = 0;
  18749. while(1) {
  18750. $116 = (($$1578) + ($$1626812)|0);
  18751. $117 = HEAP8[$116>>0]|0;
  18752. $118 = $117&255;
  18753. $119 = (($$1626812) - ($$1612))|0;
  18754. $120 = (($106) + ($119)|0);
  18755. $121 = HEAP8[$120>>0]|0;
  18756. $122 = $121&255;
  18757. $123 = (($122) + ($118))|0;
  18758. $124 = $123&255;
  18759. $125 = (($106) + ($$1626812)|0);
  18760. HEAP8[$125>>0] = $124;
  18761. $126 = (($$1626812) + 1)|0;
  18762. $exitcond886 = ($126|0)==($109|0);
  18763. if ($exitcond886) {
  18764. break;
  18765. } else {
  18766. $$1626812 = $126;
  18767. }
  18768. }
  18769. }
  18770. break;
  18771. }
  18772. case 2: {
  18773. $114 = ($109|0)>(0);
  18774. if ($114) {
  18775. $$2627810 = 0;
  18776. while(1) {
  18777. $127 = (($$1578) + ($$2627810)|0);
  18778. $128 = HEAP8[$127>>0]|0;
  18779. $129 = $128&255;
  18780. $130 = (($107) + ($$2627810)|0);
  18781. $131 = HEAP8[$130>>0]|0;
  18782. $132 = $131&255;
  18783. $133 = (($132) + ($129))|0;
  18784. $134 = $133&255;
  18785. $135 = (($106) + ($$2627810)|0);
  18786. HEAP8[$135>>0] = $134;
  18787. $136 = (($$2627810) + 1)|0;
  18788. $exitcond885 = ($136|0)==($109|0);
  18789. if ($exitcond885) {
  18790. break;
  18791. } else {
  18792. $$2627810 = $136;
  18793. }
  18794. }
  18795. }
  18796. break;
  18797. }
  18798. case 3: {
  18799. $113 = ($109|0)>(0);
  18800. if ($113) {
  18801. $$3628808 = 0;
  18802. while(1) {
  18803. $137 = (($$1578) + ($$3628808)|0);
  18804. $138 = HEAP8[$137>>0]|0;
  18805. $139 = $138&255;
  18806. $140 = (($107) + ($$3628808)|0);
  18807. $141 = HEAP8[$140>>0]|0;
  18808. $142 = $141&255;
  18809. $143 = (($$3628808) - ($$1612))|0;
  18810. $144 = (($106) + ($143)|0);
  18811. $145 = HEAP8[$144>>0]|0;
  18812. $146 = $145&255;
  18813. $147 = (($146) + ($142))|0;
  18814. $148 = $147 >>> 1;
  18815. $149 = (($148) + ($139))|0;
  18816. $150 = $149&255;
  18817. $151 = (($106) + ($$3628808)|0);
  18818. HEAP8[$151>>0] = $150;
  18819. $152 = (($$3628808) + 1)|0;
  18820. $exitcond884 = ($152|0)==($109|0);
  18821. if ($exitcond884) {
  18822. break;
  18823. } else {
  18824. $$3628808 = $152;
  18825. }
  18826. }
  18827. }
  18828. break;
  18829. }
  18830. case 4: {
  18831. $112 = ($109|0)>(0);
  18832. if ($112) {
  18833. $$4629806 = 0;
  18834. while(1) {
  18835. $153 = (($$1578) + ($$4629806)|0);
  18836. $154 = HEAP8[$153>>0]|0;
  18837. $155 = $154&255;
  18838. $156 = (($$4629806) - ($$1612))|0;
  18839. $157 = (($106) + ($156)|0);
  18840. $158 = HEAP8[$157>>0]|0;
  18841. $159 = $158&255;
  18842. $160 = (($107) + ($$4629806)|0);
  18843. $161 = HEAP8[$160>>0]|0;
  18844. $162 = $161&255;
  18845. $163 = (($107) + ($156)|0);
  18846. $164 = HEAP8[$163>>0]|0;
  18847. $165 = $164&255;
  18848. $166 = (_stbi__paeth($159,$162,$165)|0);
  18849. $167 = (($166) + ($155))|0;
  18850. $168 = $167&255;
  18851. $169 = (($106) + ($$4629806)|0);
  18852. HEAP8[$169>>0] = $168;
  18853. $170 = (($$4629806) + 1)|0;
  18854. $exitcond883 = ($170|0)==($109|0);
  18855. if ($exitcond883) {
  18856. break;
  18857. } else {
  18858. $$4629806 = $170;
  18859. }
  18860. }
  18861. }
  18862. break;
  18863. }
  18864. case 5: {
  18865. $111 = ($109|0)>(0);
  18866. if ($111) {
  18867. $$5630804 = 0;
  18868. while(1) {
  18869. $171 = (($$1578) + ($$5630804)|0);
  18870. $172 = HEAP8[$171>>0]|0;
  18871. $173 = $172&255;
  18872. $174 = (($$5630804) - ($$1612))|0;
  18873. $175 = (($106) + ($174)|0);
  18874. $176 = HEAP8[$175>>0]|0;
  18875. $177 = $176&255;
  18876. $178 = $177 >>> 1;
  18877. $179 = (($178) + ($173))|0;
  18878. $180 = $179&255;
  18879. $181 = (($106) + ($$5630804)|0);
  18880. HEAP8[$181>>0] = $180;
  18881. $182 = (($$5630804) + 1)|0;
  18882. $exitcond882 = ($182|0)==($109|0);
  18883. if ($exitcond882) {
  18884. break;
  18885. } else {
  18886. $$5630804 = $182;
  18887. }
  18888. }
  18889. }
  18890. break;
  18891. }
  18892. case 6: {
  18893. $110 = ($109|0)>(0);
  18894. if ($110) {
  18895. $$6631802 = 0;
  18896. while(1) {
  18897. $183 = (($$1578) + ($$6631802)|0);
  18898. $184 = HEAP8[$183>>0]|0;
  18899. $185 = $184&255;
  18900. $186 = (($$6631802) - ($$1612))|0;
  18901. $187 = (($106) + ($186)|0);
  18902. $188 = HEAP8[$187>>0]|0;
  18903. $189 = $188&255;
  18904. $190 = (_stbi__paeth($189,0,0)|0);
  18905. $191 = (($190) + ($185))|0;
  18906. $192 = $191&255;
  18907. $193 = (($106) + ($$6631802)|0);
  18908. HEAP8[$193>>0] = $192;
  18909. $194 = (($$6631802) + 1)|0;
  18910. $exitcond881 = ($194|0)==($109|0);
  18911. if ($exitcond881) {
  18912. break;
  18913. } else {
  18914. $$6631802 = $194;
  18915. }
  18916. }
  18917. }
  18918. break;
  18919. }
  18920. default: {
  18921. }
  18922. }
  18923. $195 = (($$1578) + ($109)|0);
  18924. $$11$ph = $195;
  18925. } else {
  18926. if (!($19)) {
  18927. label = 58;
  18928. break;
  18929. }
  18930. $trunc = $$0588&255;
  18931. switch ($trunc<<24>>24) {
  18932. case 0: {
  18933. if ($43) {
  18934. $$9586 = $$1578;
  18935. } else {
  18936. $208 = ($$1612|0)>(0);
  18937. $209 = Math_imul($$6620742, $$1612)|0;
  18938. $$0614796 = $$0614793;$$2579795 = $$1578;$$2599794 = $106;
  18939. while(1) {
  18940. if ($208) {
  18941. $$7632790 = 0;
  18942. while(1) {
  18943. $210 = (($$2579795) + ($$7632790)|0);
  18944. $211 = HEAP8[$210>>0]|0;
  18945. $212 = (($$2599794) + ($$7632790)|0);
  18946. HEAP8[$212>>0] = $211;
  18947. $213 = (($$7632790) + 1)|0;
  18948. $exitcond877 = ($213|0)==($$1612|0);
  18949. if ($exitcond877) {
  18950. break;
  18951. } else {
  18952. $$7632790 = $213;
  18953. }
  18954. }
  18955. }
  18956. $214 = (($$2599794) + ($$1612)|0);
  18957. HEAP8[$214>>0] = -1;
  18958. $215 = (($$2579795) + ($$1612)|0);
  18959. $216 = (($$2599794) + ($15)|0);
  18960. $$0614 = (($$0614796) + -1)|0;
  18961. $217 = ($$0614|0)==(0);
  18962. if ($217) {
  18963. break;
  18964. } else {
  18965. $$0614796 = $$0614;$$2579795 = $215;$$2599794 = $216;
  18966. }
  18967. }
  18968. $scevgep879 = (($$1578) + ($209)|0);
  18969. $$9586 = $scevgep879;
  18970. }
  18971. break;
  18972. }
  18973. case 1: {
  18974. if ($44) {
  18975. $$9586 = $$1578;
  18976. } else {
  18977. $206 = ($$1612|0)>(0);
  18978. $207 = Math_imul($$6620742, $$1612)|0;
  18979. $$1615788 = $$1615785;$$3580787 = $$1578;$$3600786 = $106;
  18980. while(1) {
  18981. if ($206) {
  18982. $$8633782 = 0;
  18983. while(1) {
  18984. $218 = (($$3580787) + ($$8633782)|0);
  18985. $219 = HEAP8[$218>>0]|0;
  18986. $220 = $219&255;
  18987. $221 = (($$8633782) - ($15))|0;
  18988. $222 = (($$3600786) + ($221)|0);
  18989. $223 = HEAP8[$222>>0]|0;
  18990. $224 = $223&255;
  18991. $225 = (($224) + ($220))|0;
  18992. $226 = $225&255;
  18993. $227 = (($$3600786) + ($$8633782)|0);
  18994. HEAP8[$227>>0] = $226;
  18995. $228 = (($$8633782) + 1)|0;
  18996. $exitcond875 = ($228|0)==($$1612|0);
  18997. if ($exitcond875) {
  18998. break;
  18999. } else {
  19000. $$8633782 = $228;
  19001. }
  19002. }
  19003. }
  19004. $229 = (($$3600786) + ($$1612)|0);
  19005. HEAP8[$229>>0] = -1;
  19006. $230 = (($$3580787) + ($$1612)|0);
  19007. $231 = (($$3600786) + ($15)|0);
  19008. $$1615 = (($$1615788) + -1)|0;
  19009. $232 = ($$1615|0)==(0);
  19010. if ($232) {
  19011. break;
  19012. } else {
  19013. $$1615788 = $$1615;$$3580787 = $230;$$3600786 = $231;
  19014. }
  19015. }
  19016. $scevgep876 = (($$1578) + ($207)|0);
  19017. $$9586 = $scevgep876;
  19018. }
  19019. break;
  19020. }
  19021. case 2: {
  19022. if ($45) {
  19023. $$9586 = $$1578;
  19024. } else {
  19025. $204 = ($$1612|0)>(0);
  19026. $205 = Math_imul($$6620742, $$1612)|0;
  19027. $$2616780 = $$2616776;$$3592778 = $107;$$4581779 = $$1578;$$4601777 = $106;
  19028. while(1) {
  19029. if ($204) {
  19030. $$9634773 = 0;
  19031. while(1) {
  19032. $233 = (($$4581779) + ($$9634773)|0);
  19033. $234 = HEAP8[$233>>0]|0;
  19034. $235 = $234&255;
  19035. $236 = (($$3592778) + ($$9634773)|0);
  19036. $237 = HEAP8[$236>>0]|0;
  19037. $238 = $237&255;
  19038. $239 = (($238) + ($235))|0;
  19039. $240 = $239&255;
  19040. $241 = (($$4601777) + ($$9634773)|0);
  19041. HEAP8[$241>>0] = $240;
  19042. $242 = (($$9634773) + 1)|0;
  19043. $exitcond873 = ($242|0)==($$1612|0);
  19044. if ($exitcond873) {
  19045. break;
  19046. } else {
  19047. $$9634773 = $242;
  19048. }
  19049. }
  19050. }
  19051. $243 = (($$4601777) + ($$1612)|0);
  19052. HEAP8[$243>>0] = -1;
  19053. $244 = (($$4581779) + ($$1612)|0);
  19054. $245 = (($$4601777) + ($15)|0);
  19055. $246 = (($$3592778) + ($15)|0);
  19056. $$2616 = (($$2616780) + -1)|0;
  19057. $247 = ($$2616|0)==(0);
  19058. if ($247) {
  19059. break;
  19060. } else {
  19061. $$2616780 = $$2616;$$3592778 = $246;$$4581779 = $244;$$4601777 = $245;
  19062. }
  19063. }
  19064. $scevgep874 = (($$1578) + ($205)|0);
  19065. $$9586 = $scevgep874;
  19066. }
  19067. break;
  19068. }
  19069. case 3: {
  19070. if ($46) {
  19071. $$9586 = $$1578;
  19072. } else {
  19073. $202 = ($$1612|0)>(0);
  19074. $203 = Math_imul($$6620742, $$1612)|0;
  19075. $$3617771 = $$3617767;$$4593769 = $107;$$5582770 = $$1578;$$5602768 = $106;
  19076. while(1) {
  19077. if ($202) {
  19078. $$10635764 = 0;
  19079. while(1) {
  19080. $248 = (($$5582770) + ($$10635764)|0);
  19081. $249 = HEAP8[$248>>0]|0;
  19082. $250 = $249&255;
  19083. $251 = (($$4593769) + ($$10635764)|0);
  19084. $252 = HEAP8[$251>>0]|0;
  19085. $253 = $252&255;
  19086. $254 = (($$10635764) - ($15))|0;
  19087. $255 = (($$5602768) + ($254)|0);
  19088. $256 = HEAP8[$255>>0]|0;
  19089. $257 = $256&255;
  19090. $258 = (($257) + ($253))|0;
  19091. $259 = $258 >>> 1;
  19092. $260 = (($259) + ($250))|0;
  19093. $261 = $260&255;
  19094. $262 = (($$5602768) + ($$10635764)|0);
  19095. HEAP8[$262>>0] = $261;
  19096. $263 = (($$10635764) + 1)|0;
  19097. $exitcond871 = ($263|0)==($$1612|0);
  19098. if ($exitcond871) {
  19099. break;
  19100. } else {
  19101. $$10635764 = $263;
  19102. }
  19103. }
  19104. }
  19105. $264 = (($$5602768) + ($$1612)|0);
  19106. HEAP8[$264>>0] = -1;
  19107. $265 = (($$5582770) + ($$1612)|0);
  19108. $266 = (($$5602768) + ($15)|0);
  19109. $267 = (($$4593769) + ($15)|0);
  19110. $$3617 = (($$3617771) + -1)|0;
  19111. $268 = ($$3617|0)==(0);
  19112. if ($268) {
  19113. break;
  19114. } else {
  19115. $$3617771 = $$3617;$$4593769 = $267;$$5582770 = $265;$$5602768 = $266;
  19116. }
  19117. }
  19118. $scevgep872 = (($$1578) + ($203)|0);
  19119. $$9586 = $scevgep872;
  19120. }
  19121. break;
  19122. }
  19123. case 4: {
  19124. if ($47) {
  19125. $$9586 = $$1578;
  19126. } else {
  19127. $200 = ($$1612|0)>(0);
  19128. $201 = Math_imul($$6620742, $$1612)|0;
  19129. $$4618762 = $$4618758;$$5594760 = $107;$$6583761 = $$1578;$$6603759 = $106;
  19130. while(1) {
  19131. if ($200) {
  19132. $$11636755 = 0;
  19133. while(1) {
  19134. $269 = (($$6583761) + ($$11636755)|0);
  19135. $270 = HEAP8[$269>>0]|0;
  19136. $271 = $270&255;
  19137. $272 = (($$11636755) - ($15))|0;
  19138. $273 = (($$6603759) + ($272)|0);
  19139. $274 = HEAP8[$273>>0]|0;
  19140. $275 = $274&255;
  19141. $276 = (($$5594760) + ($$11636755)|0);
  19142. $277 = HEAP8[$276>>0]|0;
  19143. $278 = $277&255;
  19144. $279 = (($$5594760) + ($272)|0);
  19145. $280 = HEAP8[$279>>0]|0;
  19146. $281 = $280&255;
  19147. $282 = (_stbi__paeth($275,$278,$281)|0);
  19148. $283 = (($282) + ($271))|0;
  19149. $284 = $283&255;
  19150. $285 = (($$6603759) + ($$11636755)|0);
  19151. HEAP8[$285>>0] = $284;
  19152. $286 = (($$11636755) + 1)|0;
  19153. $exitcond869 = ($286|0)==($$1612|0);
  19154. if ($exitcond869) {
  19155. break;
  19156. } else {
  19157. $$11636755 = $286;
  19158. }
  19159. }
  19160. }
  19161. $287 = (($$6603759) + ($$1612)|0);
  19162. HEAP8[$287>>0] = -1;
  19163. $288 = (($$6583761) + ($$1612)|0);
  19164. $289 = (($$6603759) + ($15)|0);
  19165. $290 = (($$5594760) + ($15)|0);
  19166. $$4618 = (($$4618762) + -1)|0;
  19167. $291 = ($$4618|0)==(0);
  19168. if ($291) {
  19169. break;
  19170. } else {
  19171. $$4618762 = $$4618;$$5594760 = $290;$$6583761 = $288;$$6603759 = $289;
  19172. }
  19173. }
  19174. $scevgep870 = (($$1578) + ($201)|0);
  19175. $$9586 = $scevgep870;
  19176. }
  19177. break;
  19178. }
  19179. case 5: {
  19180. if ($48) {
  19181. $$9586 = $$1578;
  19182. } else {
  19183. $198 = ($$1612|0)>(0);
  19184. $199 = Math_imul($$6620742, $$1612)|0;
  19185. $$5619753 = $$5619750;$$7584752 = $$1578;$$7604751 = $106;
  19186. while(1) {
  19187. if ($198) {
  19188. $$12747 = 0;
  19189. while(1) {
  19190. $292 = (($$7584752) + ($$12747)|0);
  19191. $293 = HEAP8[$292>>0]|0;
  19192. $294 = $293&255;
  19193. $295 = (($$12747) - ($15))|0;
  19194. $296 = (($$7604751) + ($295)|0);
  19195. $297 = HEAP8[$296>>0]|0;
  19196. $298 = $297&255;
  19197. $299 = $298 >>> 1;
  19198. $300 = (($299) + ($294))|0;
  19199. $301 = $300&255;
  19200. $302 = (($$7604751) + ($$12747)|0);
  19201. HEAP8[$302>>0] = $301;
  19202. $303 = (($$12747) + 1)|0;
  19203. $exitcond867 = ($303|0)==($$1612|0);
  19204. if ($exitcond867) {
  19205. break;
  19206. } else {
  19207. $$12747 = $303;
  19208. }
  19209. }
  19210. }
  19211. $304 = (($$7604751) + ($$1612)|0);
  19212. HEAP8[$304>>0] = -1;
  19213. $305 = (($$7584752) + ($$1612)|0);
  19214. $306 = (($$7604751) + ($15)|0);
  19215. $$5619 = (($$5619753) + -1)|0;
  19216. $307 = ($$5619|0)==(0);
  19217. if ($307) {
  19218. break;
  19219. } else {
  19220. $$5619753 = $$5619;$$7584752 = $305;$$7604751 = $306;
  19221. }
  19222. }
  19223. $scevgep868 = (($$1578) + ($199)|0);
  19224. $$9586 = $scevgep868;
  19225. }
  19226. break;
  19227. }
  19228. case 6: {
  19229. if ($49) {
  19230. $$9586 = $$1578;
  19231. } else {
  19232. $196 = ($$1612|0)>(0);
  19233. $197 = Math_imul($$6620742, $$1612)|0;
  19234. $$6620745 = $$6620742;$$8585744 = $$1578;$$8605743 = $106;
  19235. while(1) {
  19236. if ($196) {
  19237. $$13739 = 0;
  19238. while(1) {
  19239. $308 = (($$8585744) + ($$13739)|0);
  19240. $309 = HEAP8[$308>>0]|0;
  19241. $310 = $309&255;
  19242. $311 = (($$13739) - ($15))|0;
  19243. $312 = (($$8605743) + ($311)|0);
  19244. $313 = HEAP8[$312>>0]|0;
  19245. $314 = $313&255;
  19246. $315 = (_stbi__paeth($314,0,0)|0);
  19247. $316 = (($315) + ($310))|0;
  19248. $317 = $316&255;
  19249. $318 = (($$8605743) + ($$13739)|0);
  19250. HEAP8[$318>>0] = $317;
  19251. $319 = (($$13739) + 1)|0;
  19252. $exitcond865 = ($319|0)==($$1612|0);
  19253. if ($exitcond865) {
  19254. break;
  19255. } else {
  19256. $$13739 = $319;
  19257. }
  19258. }
  19259. }
  19260. $320 = (($$8605743) + ($$1612)|0);
  19261. HEAP8[$320>>0] = -1;
  19262. $321 = (($$8585744) + ($$1612)|0);
  19263. $322 = (($$8605743) + ($15)|0);
  19264. $$6620 = (($$6620745) + -1)|0;
  19265. $323 = ($$6620|0)==(0);
  19266. if ($323) {
  19267. break;
  19268. } else {
  19269. $$6620745 = $$6620;$$8585744 = $321;$$8605743 = $322;
  19270. }
  19271. }
  19272. $scevgep866 = (($$1578) + ($197)|0);
  19273. $$9586 = $scevgep866;
  19274. }
  19275. break;
  19276. }
  19277. default: {
  19278. $$9586 = $$1578;
  19279. }
  19280. }
  19281. if ($brmerge894) {
  19282. $$11$ph = $$9586;
  19283. } else {
  19284. $324 = HEAP32[$21>>2]|0;
  19285. $325 = (($324) + ($51)|0);
  19286. $326 = (($$1612) + 1)|0;
  19287. $$7621798 = 0;$$9606799 = $325;
  19288. while(1) {
  19289. $327 = (($$9606799) + ($326)|0);
  19290. HEAP8[$327>>0] = -1;
  19291. $328 = (($$7621798) + 1)|0;
  19292. $329 = (($$9606799) + ($15)|0);
  19293. $exitcond880 = ($328|0)==($4|0);
  19294. if ($exitcond880) {
  19295. $$11$ph = $$9586;
  19296. break;
  19297. } else {
  19298. $$7621798 = $328;$$9606799 = $329;
  19299. }
  19300. }
  19301. }
  19302. }
  19303. $330 = (($$0623814) + 1)|0;
  19304. $331 = ($330>>>0)<($5>>>0);
  19305. if ($331) {
  19306. $$0577817 = $$11$ph;$$0608816 = $$1609;$$0611815 = $$1612;$$0623814 = $330;
  19307. } else {
  19308. break L18;
  19309. }
  19310. }
  19311. if ((label|0) == 16) {
  19312. ___assert_fail((11228|0),(10568|0),4315,(11183|0));
  19313. // unreachable;
  19314. }
  19315. else if ((label|0) == 58) {
  19316. ___assert_fail((11254|0),(10568|0),4377,(11183|0));
  19317. // unreachable;
  19318. }
  19319. else if ((label|0) == 105) {
  19320. _stbi__err(11271);
  19321. $$2 = 0;
  19322. return ($$2|0);
  19323. }
  19324. }
  19325. } while(0);
  19326. $332 = ($6|0)<(8);
  19327. if (!($332)) {
  19328. if (!($8)) {
  19329. $$2 = 1;
  19330. return ($$2|0);
  19331. }
  19332. $601 = Math_imul($4, $3)|0;
  19333. $602 = Math_imul($601, $5)|0;
  19334. $603 = ($602|0)==(0);
  19335. if ($603) {
  19336. $$2 = 1;
  19337. return ($$2|0);
  19338. }
  19339. $604 = HEAP32[$21>>2]|0;
  19340. $$0731 = $604;$$8622729 = 0;
  19341. while(1) {
  19342. $605 = HEAP8[$$0731>>0]|0;
  19343. $606 = $605&255;
  19344. $607 = $606 << 8;
  19345. $608 = ((($$0731)) + 1|0);
  19346. $609 = HEAP8[$608>>0]|0;
  19347. $610 = $609&255;
  19348. $611 = $607 | $610;
  19349. $612 = $611&65535;
  19350. HEAP16[$$0731>>1] = $612;
  19351. $613 = (($$8622729) + 1)|0;
  19352. $614 = ((($$0731)) + 2|0);
  19353. $exitcond = ($613|0)==($602|0);
  19354. if ($exitcond) {
  19355. $$2 = 1;
  19356. break;
  19357. } else {
  19358. $$0731 = $614;$$8622729 = $613;
  19359. }
  19360. }
  19361. return ($$2|0);
  19362. }
  19363. $333 = ($5|0)==(0);
  19364. if ($333) {
  19365. $$2 = 1;
  19366. return ($$2|0);
  19367. }
  19368. $334 = (0 - ($26))|0;
  19369. $335 = ($7|0)==(0);
  19370. $336 = (10967 + ($6)|0);
  19371. $$0568724 = (($4) + -1)|0;
  19372. $337 = ($$0568724|0)>(-1);
  19373. $$1721 = (($4) + -1)|0;
  19374. $338 = ($$1721|0)>(-1);
  19375. $339 = ($23|0)>(1);
  19376. $340 = ($23|0)>(3);
  19377. $341 = ($23|0)>(7);
  19378. $342 = (($23) + -8)|0;
  19379. $343 = $342 >>> 3;
  19380. $344 = $343 << 3;
  19381. $345 = (($344) + 8)|0;
  19382. $346 = (($342) - ($344))|0;
  19383. $347 = (($343) + ($11))|0;
  19384. $348 = (($347) + 1)|0;
  19385. $349 = (($348) - ($26))|0;
  19386. $350 = (($23) + -4)|0;
  19387. $351 = $350 >>> 2;
  19388. $352 = $351 << 2;
  19389. $353 = (($352) + 4)|0;
  19390. $354 = (($350) - ($352))|0;
  19391. $355 = (($351) + ($11))|0;
  19392. $356 = (($355) + 1)|0;
  19393. $357 = (($356) - ($26))|0;
  19394. $358 = (($23) + -2)|0;
  19395. $359 = $358 >>> 1;
  19396. $360 = $359 << 1;
  19397. $361 = (($360) + 2)|0;
  19398. $362 = (($358) - ($360))|0;
  19399. $363 = (($359) + ($11))|0;
  19400. $364 = (($363) + 1)|0;
  19401. $365 = (($364) - ($26))|0;
  19402. $$1624727 = 0;$indvars$iv = $345;$indvars$iv848 = $349;$indvars$iv851 = $353;$indvars$iv854 = $357;$indvars$iv857 = $361;$indvars$iv860 = $365;
  19403. L174: while(1) {
  19404. $366 = HEAP32[$21>>2]|0;
  19405. $367 = Math_imul($$1624727, $12)|0;
  19406. $368 = (($366) + ($367)|0);
  19407. $369 = (($368) + ($11)|0);
  19408. $370 = (($369) + ($334)|0);
  19409. if ($335) {
  19410. $371 = HEAP8[$336>>0]|0;
  19411. $372 = $371&255;
  19412. $377 = $372;
  19413. } else {
  19414. $377 = 1;
  19415. }
  19416. switch ($6|0) {
  19417. case 4: {
  19418. if ($339) {
  19419. $scevgep859 = (($366) + ($indvars$iv857)|0);
  19420. $$0571715 = $370;$$0574714 = $368;$$14713 = $23;
  19421. while(1) {
  19422. $373 = HEAP8[$$0571715>>0]|0;
  19423. $374 = $373&255;
  19424. $375 = $374 >>> 4;
  19425. $376 = Math_imul($375, $377)|0;
  19426. $378 = $376&255;
  19427. $379 = ((($$0574714)) + 1|0);
  19428. HEAP8[$$0574714>>0] = $378;
  19429. $380 = HEAP8[$$0571715>>0]|0;
  19430. $381 = $380 & 15;
  19431. $382 = $381&255;
  19432. $383 = Math_imul($382, $377)|0;
  19433. $384 = $383&255;
  19434. $385 = ((($$0574714)) + 2|0);
  19435. HEAP8[$379>>0] = $384;
  19436. $386 = (($$14713) + -2)|0;
  19437. $387 = ((($$0571715)) + 1|0);
  19438. $388 = ($386|0)>(1);
  19439. if ($388) {
  19440. $$0571715 = $387;$$0574714 = $385;$$14713 = $386;
  19441. } else {
  19442. break;
  19443. }
  19444. }
  19445. $scevgep862 = (($366) + ($indvars$iv860)|0);
  19446. $$0571$lcssa = $scevgep862;$$0574$lcssa = $scevgep859;$$14$lcssa = $362;
  19447. } else {
  19448. $$0571$lcssa = $370;$$0574$lcssa = $368;$$14$lcssa = $23;
  19449. }
  19450. $389 = ($$14$lcssa|0)==(1);
  19451. if ($389) {
  19452. $390 = HEAP8[$$0571$lcssa>>0]|0;
  19453. $391 = $390&255;
  19454. $392 = $391 >>> 4;
  19455. $393 = Math_imul($392, $377)|0;
  19456. $394 = $393&255;
  19457. HEAP8[$$0574$lcssa>>0] = $394;
  19458. }
  19459. break;
  19460. }
  19461. case 2: {
  19462. if ($340) {
  19463. $scevgep853 = (($366) + ($indvars$iv851)|0);
  19464. $$15705 = $23;$$1572707 = $370;$$1575706 = $368;
  19465. while(1) {
  19466. $395 = HEAP8[$$1572707>>0]|0;
  19467. $396 = $395&255;
  19468. $397 = $396 >>> 6;
  19469. $398 = Math_imul($397, $377)|0;
  19470. $399 = $398&255;
  19471. $400 = ((($$1575706)) + 1|0);
  19472. HEAP8[$$1575706>>0] = $399;
  19473. $401 = HEAP8[$$1572707>>0]|0;
  19474. $402 = $401&255;
  19475. $403 = $402 >>> 4;
  19476. $404 = $403 & 3;
  19477. $405 = Math_imul($404, $377)|0;
  19478. $406 = $405&255;
  19479. $407 = ((($$1575706)) + 2|0);
  19480. HEAP8[$400>>0] = $406;
  19481. $408 = HEAP8[$$1572707>>0]|0;
  19482. $409 = $408&255;
  19483. $410 = $409 >>> 2;
  19484. $411 = $410 & 3;
  19485. $412 = Math_imul($411, $377)|0;
  19486. $413 = $412&255;
  19487. $414 = ((($$1575706)) + 3|0);
  19488. HEAP8[$407>>0] = $413;
  19489. $415 = HEAP8[$$1572707>>0]|0;
  19490. $416 = $415 & 3;
  19491. $417 = $416&255;
  19492. $418 = Math_imul($417, $377)|0;
  19493. $419 = $418&255;
  19494. $420 = ((($$1575706)) + 4|0);
  19495. HEAP8[$414>>0] = $419;
  19496. $421 = (($$15705) + -4)|0;
  19497. $422 = ((($$1572707)) + 1|0);
  19498. $423 = ($421|0)>(3);
  19499. if ($423) {
  19500. $$15705 = $421;$$1572707 = $422;$$1575706 = $420;
  19501. } else {
  19502. break;
  19503. }
  19504. }
  19505. $scevgep856 = (($366) + ($indvars$iv854)|0);
  19506. $$15$lcssa = $354;$$1572$lcssa = $scevgep856;$$1575$lcssa = $scevgep853;
  19507. } else {
  19508. $$15$lcssa = $23;$$1572$lcssa = $370;$$1575$lcssa = $368;
  19509. }
  19510. $424 = ($$15$lcssa|0)>(0);
  19511. if ($424) {
  19512. $425 = HEAP8[$$1572$lcssa>>0]|0;
  19513. $426 = $425&255;
  19514. $427 = $426 >>> 6;
  19515. $428 = Math_imul($427, $377)|0;
  19516. $429 = $428&255;
  19517. HEAP8[$$1575$lcssa>>0] = $429;
  19518. $430 = ($$15$lcssa|0)==(1);
  19519. if (!($430)) {
  19520. $431 = ((($$1575$lcssa)) + 1|0);
  19521. $432 = HEAP8[$$1572$lcssa>>0]|0;
  19522. $433 = $432&255;
  19523. $434 = $433 >>> 4;
  19524. $435 = $434 & 3;
  19525. $436 = Math_imul($435, $377)|0;
  19526. $437 = $436&255;
  19527. HEAP8[$431>>0] = $437;
  19528. $438 = ($$15$lcssa|0)>(2);
  19529. if ($438) {
  19530. $439 = ((($$1575$lcssa)) + 2|0);
  19531. $440 = HEAP8[$$1572$lcssa>>0]|0;
  19532. $441 = $440&255;
  19533. $442 = $441 >>> 2;
  19534. $443 = $442 & 3;
  19535. $444 = Math_imul($443, $377)|0;
  19536. $445 = $444&255;
  19537. HEAP8[$439>>0] = $445;
  19538. }
  19539. }
  19540. }
  19541. break;
  19542. }
  19543. case 1: {
  19544. if ($341) {
  19545. $scevgep = (($366) + ($indvars$iv)|0);
  19546. $$16700 = $23;$$2573702 = $370;$$4701 = $368;
  19547. while(1) {
  19548. $446 = HEAP8[$$2573702>>0]|0;
  19549. $447 = $446&255;
  19550. $448 = $447 >>> 7;
  19551. $449 = (0 - ($448))|0;
  19552. $450 = $377 & $449;
  19553. $451 = $450&255;
  19554. $452 = ((($$4701)) + 1|0);
  19555. HEAP8[$$4701>>0] = $451;
  19556. $453 = HEAP8[$$2573702>>0]|0;
  19557. $454 = $453&255;
  19558. $455 = $454 >>> 6;
  19559. $456 = $455 & 1;
  19560. $457 = (0 - ($456))|0;
  19561. $458 = $377 & $457;
  19562. $459 = $458&255;
  19563. $460 = ((($$4701)) + 2|0);
  19564. HEAP8[$452>>0] = $459;
  19565. $461 = HEAP8[$$2573702>>0]|0;
  19566. $462 = $461&255;
  19567. $463 = $462 >>> 5;
  19568. $464 = $463 & 1;
  19569. $465 = (0 - ($464))|0;
  19570. $466 = $377 & $465;
  19571. $467 = $466&255;
  19572. $468 = ((($$4701)) + 3|0);
  19573. HEAP8[$460>>0] = $467;
  19574. $469 = HEAP8[$$2573702>>0]|0;
  19575. $470 = $469&255;
  19576. $471 = $470 >>> 4;
  19577. $472 = $471 & 1;
  19578. $473 = (0 - ($472))|0;
  19579. $474 = $377 & $473;
  19580. $475 = $474&255;
  19581. $476 = ((($$4701)) + 4|0);
  19582. HEAP8[$468>>0] = $475;
  19583. $477 = HEAP8[$$2573702>>0]|0;
  19584. $478 = $477&255;
  19585. $479 = $478 >>> 3;
  19586. $480 = $479 & 1;
  19587. $481 = (0 - ($480))|0;
  19588. $482 = $377 & $481;
  19589. $483 = $482&255;
  19590. $484 = ((($$4701)) + 5|0);
  19591. HEAP8[$476>>0] = $483;
  19592. $485 = HEAP8[$$2573702>>0]|0;
  19593. $486 = $485&255;
  19594. $487 = $486 >>> 2;
  19595. $488 = $487 & 1;
  19596. $489 = (0 - ($488))|0;
  19597. $490 = $377 & $489;
  19598. $491 = $490&255;
  19599. $492 = ((($$4701)) + 6|0);
  19600. HEAP8[$484>>0] = $491;
  19601. $493 = HEAP8[$$2573702>>0]|0;
  19602. $494 = $493&255;
  19603. $495 = $494 >>> 1;
  19604. $496 = $495 & 1;
  19605. $497 = (0 - ($496))|0;
  19606. $498 = $377 & $497;
  19607. $499 = $498&255;
  19608. $500 = ((($$4701)) + 7|0);
  19609. HEAP8[$492>>0] = $499;
  19610. $501 = HEAP8[$$2573702>>0]|0;
  19611. $502 = $501 & 1;
  19612. $503 = $502&255;
  19613. $504 = (0 - ($503))|0;
  19614. $505 = $377 & $504;
  19615. $506 = $505&255;
  19616. $507 = ((($$4701)) + 8|0);
  19617. HEAP8[$500>>0] = $506;
  19618. $508 = (($$16700) + -8)|0;
  19619. $509 = ((($$2573702)) + 1|0);
  19620. $510 = ($508|0)>(7);
  19621. if ($510) {
  19622. $$16700 = $508;$$2573702 = $509;$$4701 = $507;
  19623. } else {
  19624. break;
  19625. }
  19626. }
  19627. $scevgep850 = (($366) + ($indvars$iv848)|0);
  19628. $$16$lcssa = $346;$$2573$lcssa = $scevgep850;$$4$lcssa = $scevgep;
  19629. } else {
  19630. $$16$lcssa = $23;$$2573$lcssa = $370;$$4$lcssa = $368;
  19631. }
  19632. $511 = ($$16$lcssa|0)>(0);
  19633. if ($511) {
  19634. $512 = HEAP8[$$2573$lcssa>>0]|0;
  19635. $513 = $512&255;
  19636. $514 = $513 >>> 7;
  19637. $515 = (0 - ($514))|0;
  19638. $516 = $377 & $515;
  19639. $517 = $516&255;
  19640. HEAP8[$$4$lcssa>>0] = $517;
  19641. $518 = ($$16$lcssa|0)==(1);
  19642. if (!($518)) {
  19643. $519 = ((($$4$lcssa)) + 1|0);
  19644. $520 = HEAP8[$$2573$lcssa>>0]|0;
  19645. $521 = $520&255;
  19646. $522 = $521 >>> 6;
  19647. $523 = $522 & 1;
  19648. $524 = (0 - ($523))|0;
  19649. $525 = $377 & $524;
  19650. $526 = $525&255;
  19651. HEAP8[$519>>0] = $526;
  19652. $527 = ($$16$lcssa|0)>(2);
  19653. if ($527) {
  19654. $528 = ((($$4$lcssa)) + 2|0);
  19655. $529 = HEAP8[$$2573$lcssa>>0]|0;
  19656. $530 = $529&255;
  19657. $531 = $530 >>> 5;
  19658. $532 = $531 & 1;
  19659. $533 = (0 - ($532))|0;
  19660. $534 = $377 & $533;
  19661. $535 = $534&255;
  19662. HEAP8[$528>>0] = $535;
  19663. $536 = ($$16$lcssa|0)==(3);
  19664. if (!($536)) {
  19665. $537 = ((($$4$lcssa)) + 3|0);
  19666. $538 = HEAP8[$$2573$lcssa>>0]|0;
  19667. $539 = $538&255;
  19668. $540 = $539 >>> 4;
  19669. $541 = $540 & 1;
  19670. $542 = (0 - ($541))|0;
  19671. $543 = $377 & $542;
  19672. $544 = $543&255;
  19673. HEAP8[$537>>0] = $544;
  19674. $545 = ($$16$lcssa|0)>(4);
  19675. if ($545) {
  19676. $546 = ((($$4$lcssa)) + 4|0);
  19677. $547 = HEAP8[$$2573$lcssa>>0]|0;
  19678. $548 = $547&255;
  19679. $549 = $548 >>> 3;
  19680. $550 = $549 & 1;
  19681. $551 = (0 - ($550))|0;
  19682. $552 = $377 & $551;
  19683. $553 = $552&255;
  19684. HEAP8[$546>>0] = $553;
  19685. $554 = ($$16$lcssa|0)==(5);
  19686. if (!($554)) {
  19687. $555 = ((($$4$lcssa)) + 5|0);
  19688. $556 = HEAP8[$$2573$lcssa>>0]|0;
  19689. $557 = $556&255;
  19690. $558 = $557 >>> 2;
  19691. $559 = $558 & 1;
  19692. $560 = (0 - ($559))|0;
  19693. $561 = $377 & $560;
  19694. $562 = $561&255;
  19695. HEAP8[$555>>0] = $562;
  19696. $563 = ($$16$lcssa|0)>(6);
  19697. if ($563) {
  19698. $564 = ((($$4$lcssa)) + 6|0);
  19699. $565 = HEAP8[$$2573$lcssa>>0]|0;
  19700. $566 = $565&255;
  19701. $567 = $566 >>> 1;
  19702. $568 = $567 & 1;
  19703. $569 = (0 - ($568))|0;
  19704. $570 = $377 & $569;
  19705. $571 = $570&255;
  19706. HEAP8[$564>>0] = $571;
  19707. }
  19708. }
  19709. }
  19710. }
  19711. }
  19712. }
  19713. }
  19714. break;
  19715. }
  19716. default: {
  19717. }
  19718. }
  19719. L213: do {
  19720. if (!($17)) {
  19721. $572 = HEAP32[$21>>2]|0;
  19722. $573 = (($572) + ($367)|0);
  19723. switch ($14|0) {
  19724. case 1: {
  19725. if ($337) {
  19726. $$0568725 = $$0568724;
  19727. } else {
  19728. break L213;
  19729. }
  19730. while(1) {
  19731. $574 = $$0568725 << 1;
  19732. $575 = $574 | 1;
  19733. $576 = (($573) + ($575)|0);
  19734. HEAP8[$576>>0] = -1;
  19735. $577 = (($573) + ($$0568725)|0);
  19736. $578 = HEAP8[$577>>0]|0;
  19737. $579 = (($573) + ($574)|0);
  19738. HEAP8[$579>>0] = $578;
  19739. $$0568 = (($$0568725) + -1)|0;
  19740. $580 = ($$0568|0)>(-1);
  19741. if ($580) {
  19742. $$0568725 = $$0568;
  19743. } else {
  19744. break;
  19745. }
  19746. }
  19747. break;
  19748. }
  19749. case 3: {
  19750. if ($338) {
  19751. $$1722 = $$1721;
  19752. } else {
  19753. break L213;
  19754. }
  19755. while(1) {
  19756. $581 = $$1722 << 2;
  19757. $582 = $581 | 3;
  19758. $583 = (($573) + ($582)|0);
  19759. HEAP8[$583>>0] = -1;
  19760. $584 = ($$1722*3)|0;
  19761. $585 = (($584) + 2)|0;
  19762. $586 = (($573) + ($585)|0);
  19763. $587 = HEAP8[$586>>0]|0;
  19764. $588 = $581 | 2;
  19765. $589 = (($573) + ($588)|0);
  19766. HEAP8[$589>>0] = $587;
  19767. $590 = (($584) + 1)|0;
  19768. $591 = (($573) + ($590)|0);
  19769. $592 = HEAP8[$591>>0]|0;
  19770. $593 = $581 | 1;
  19771. $594 = (($573) + ($593)|0);
  19772. HEAP8[$594>>0] = $592;
  19773. $595 = (($573) + ($584)|0);
  19774. $596 = HEAP8[$595>>0]|0;
  19775. $597 = (($573) + ($581)|0);
  19776. HEAP8[$597>>0] = $596;
  19777. $$1 = (($$1722) + -1)|0;
  19778. $598 = ($$1|0)>(-1);
  19779. if ($598) {
  19780. $$1722 = $$1;
  19781. } else {
  19782. break;
  19783. }
  19784. }
  19785. break;
  19786. }
  19787. default: {
  19788. label = 144;
  19789. break L174;
  19790. }
  19791. }
  19792. }
  19793. } while(0);
  19794. $599 = (($$1624727) + 1)|0;
  19795. $600 = ($599>>>0)<($5>>>0);
  19796. $indvars$iv$next = (($indvars$iv) + ($12))|0;
  19797. $indvars$iv$next849 = (($indvars$iv848) + ($12))|0;
  19798. $indvars$iv$next852 = (($indvars$iv851) + ($12))|0;
  19799. $indvars$iv$next855 = (($indvars$iv854) + ($12))|0;
  19800. $indvars$iv$next858 = (($indvars$iv857) + ($12))|0;
  19801. $indvars$iv$next861 = (($indvars$iv860) + ($12))|0;
  19802. if ($600) {
  19803. $$1624727 = $599;$indvars$iv = $indvars$iv$next;$indvars$iv848 = $indvars$iv$next849;$indvars$iv851 = $indvars$iv$next852;$indvars$iv854 = $indvars$iv$next855;$indvars$iv857 = $indvars$iv$next858;$indvars$iv860 = $indvars$iv$next861;
  19804. } else {
  19805. $$2 = 1;
  19806. label = 151;
  19807. break;
  19808. }
  19809. }
  19810. if ((label|0) == 144) {
  19811. ___assert_fail((11286|0),(10568|0),4466,(11183|0));
  19812. // unreachable;
  19813. }
  19814. else if ((label|0) == 151) {
  19815. return ($$2|0);
  19816. }
  19817. return (0)|0;
  19818. }
  19819. function _stbi__paeth($0,$1,$2) {
  19820. $0 = $0|0;
  19821. $1 = $1|0;
  19822. $2 = $2|0;
  19823. var $$ = 0, $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $ispos = 0, $ispos26 = 0, $ispos28 = 0, $neg = 0, $neg27 = 0, $neg29 = 0, $or$cond = 0;
  19824. var label = 0, sp = 0;
  19825. sp = STACKTOP;
  19826. $3 = (($1) + ($0))|0;
  19827. $4 = (($3) - ($2))|0;
  19828. $5 = (($4) - ($0))|0;
  19829. $ispos = ($5|0)>(-1);
  19830. $neg = (0 - ($5))|0;
  19831. $6 = $ispos ? $5 : $neg;
  19832. $7 = (($4) - ($1))|0;
  19833. $ispos26 = ($7|0)>(-1);
  19834. $neg27 = (0 - ($7))|0;
  19835. $8 = $ispos26 ? $7 : $neg27;
  19836. $9 = (($4) - ($2))|0;
  19837. $ispos28 = ($9|0)>(-1);
  19838. $neg29 = (0 - ($9))|0;
  19839. $10 = $ispos28 ? $9 : $neg29;
  19840. $11 = ($6|0)>($8|0);
  19841. $12 = ($6|0)>($10|0);
  19842. $or$cond = $11 | $12;
  19843. $13 = ($8|0)>($10|0);
  19844. $$ = $13 ? $2 : $1;
  19845. $$0 = $or$cond ? $$ : $0;
  19846. return ($$0|0);
  19847. }
  19848. function _stbi__do_zlib($0,$1,$2,$3,$4) {
  19849. $0 = $0|0;
  19850. $1 = $1|0;
  19851. $2 = $2|0;
  19852. $3 = $3|0;
  19853. $4 = $4|0;
  19854. var $10 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  19855. sp = STACKTOP;
  19856. $5 = ((($0)) + 20|0);
  19857. HEAP32[$5>>2] = $1;
  19858. $6 = ((($0)) + 16|0);
  19859. HEAP32[$6>>2] = $1;
  19860. $7 = (($1) + ($2)|0);
  19861. $8 = ((($0)) + 24|0);
  19862. HEAP32[$8>>2] = $7;
  19863. $9 = ((($0)) + 28|0);
  19864. HEAP32[$9>>2] = $3;
  19865. $10 = (_stbi__parse_zlib($0,$4)|0);
  19866. return ($10|0);
  19867. }
  19868. function _stbi__parse_zlib($0,$1) {
  19869. $0 = $0|0;
  19870. $1 = $1|0;
  19871. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0;
  19872. var $9 = 0, label = 0, sp = 0;
  19873. sp = STACKTOP;
  19874. $2 = ($1|0)==(0);
  19875. if (!($2)) {
  19876. $3 = (_stbi__parse_zlib_header($0)|0);
  19877. $4 = ($3|0)==(0);
  19878. if ($4) {
  19879. $$0 = 0;
  19880. return ($$0|0);
  19881. }
  19882. }
  19883. $5 = ((($0)) + 8|0);
  19884. HEAP32[$5>>2] = 0;
  19885. $6 = ((($0)) + 12|0);
  19886. HEAP32[$6>>2] = 0;
  19887. $7 = ((($0)) + 32|0);
  19888. $8 = ((($0)) + 2052|0);
  19889. L5: while(1) {
  19890. $9 = (_stbi__zreceive($0,1)|0);
  19891. $10 = (_stbi__zreceive($0,2)|0);
  19892. switch ($10|0) {
  19893. case 3: {
  19894. $$0 = 0;
  19895. label = 11;
  19896. break L5;
  19897. break;
  19898. }
  19899. case 0: {
  19900. $11 = (_stbi__parse_uncompressed_block($0)|0);
  19901. $12 = ($11|0)==(0);
  19902. if ($12) {
  19903. $$0 = 0;
  19904. label = 11;
  19905. break L5;
  19906. }
  19907. break;
  19908. }
  19909. case 1: {
  19910. $13 = (_stbi__zbuild_huffman($7,11297,288)|0);
  19911. $14 = ($13|0)==(0);
  19912. if ($14) {
  19913. $$0 = 0;
  19914. label = 11;
  19915. break L5;
  19916. }
  19917. $15 = (_stbi__zbuild_huffman($8,11585,32)|0);
  19918. $16 = ($15|0)==(0);
  19919. if ($16) {
  19920. $$0 = 0;
  19921. label = 11;
  19922. break L5;
  19923. } else {
  19924. label = 9;
  19925. }
  19926. break;
  19927. }
  19928. default: {
  19929. $17 = (_stbi__compute_huffman_codes($0)|0);
  19930. $18 = ($17|0)==(0);
  19931. if ($18) {
  19932. $$0 = 0;
  19933. label = 11;
  19934. break L5;
  19935. } else {
  19936. label = 9;
  19937. }
  19938. }
  19939. }
  19940. if ((label|0) == 9) {
  19941. label = 0;
  19942. $19 = (_stbi__parse_huffman_block($0)|0);
  19943. $20 = ($19|0)==(0);
  19944. if ($20) {
  19945. $$0 = 0;
  19946. label = 11;
  19947. break;
  19948. }
  19949. }
  19950. $21 = ($9|0)==(0);
  19951. if (!($21)) {
  19952. $$0 = 1;
  19953. label = 11;
  19954. break;
  19955. }
  19956. }
  19957. if ((label|0) == 11) {
  19958. return ($$0|0);
  19959. }
  19960. return (0)|0;
  19961. }
  19962. function _stbi__parse_zlib_header($0) {
  19963. $0 = $0|0;
  19964. var $$0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  19965. sp = STACKTOP;
  19966. $1 = (_stbi__zget8($0)|0);
  19967. $2 = $1&255;
  19968. $3 = $2 & 15;
  19969. $4 = (_stbi__zget8($0)|0);
  19970. $5 = $4&255;
  19971. $6 = $2 << 8;
  19972. $7 = $6 | $5;
  19973. $8 = (($7>>>0) % 31)&-1;
  19974. $9 = ($8|0)==(0);
  19975. if (!($9)) {
  19976. _stbi__err(11932);
  19977. $$0 = 0;
  19978. return ($$0|0);
  19979. }
  19980. $10 = $5 & 32;
  19981. $11 = ($10|0)==(0);
  19982. if (!($11)) {
  19983. _stbi__err(11948);
  19984. $$0 = 0;
  19985. return ($$0|0);
  19986. }
  19987. $12 = ($3|0)==(8);
  19988. if ($12) {
  19989. $$0 = 1;
  19990. return ($$0|0);
  19991. }
  19992. _stbi__err(11963);
  19993. $$0 = 0;
  19994. return ($$0|0);
  19995. }
  19996. function _stbi__zreceive($0,$1) {
  19997. $0 = $0|0;
  19998. $1 = $1|0;
  19999. var $10 = 0, $11 = 0, $12 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  20000. sp = STACKTOP;
  20001. $2 = ((($0)) + 8|0);
  20002. $3 = HEAP32[$2>>2]|0;
  20003. $4 = ($3|0)<($1|0);
  20004. if ($4) {
  20005. _stbi__fill_bits($0);
  20006. }
  20007. $5 = ((($0)) + 12|0);
  20008. $6 = HEAP32[$5>>2]|0;
  20009. $7 = 1 << $1;
  20010. $8 = (($7) + -1)|0;
  20011. $9 = $6 & $8;
  20012. $10 = $6 >>> $1;
  20013. HEAP32[$5>>2] = $10;
  20014. $11 = HEAP32[$2>>2]|0;
  20015. $12 = (($11) - ($1))|0;
  20016. HEAP32[$2>>2] = $12;
  20017. return ($9|0);
  20018. }
  20019. function _stbi__parse_uncompressed_block($0) {
  20020. $0 = $0|0;
  20021. var $$0$lcssa = 0, $$034 = 0, $$037 = 0, $$136 = 0, $$lcssa = 0, $$ph = 0, $$pr = 0, $$promoted = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0;
  20022. var $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0;
  20023. var $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0;
  20024. var $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond47 = 0, $smax = 0, label = 0, sp = 0;
  20025. sp = STACKTOP;
  20026. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  20027. $1 = sp;
  20028. $2 = ((($0)) + 8|0);
  20029. $3 = HEAP32[$2>>2]|0;
  20030. $4 = $3 & 7;
  20031. $5 = ($4|0)==(0);
  20032. if ($5) {
  20033. $$ph = $3;
  20034. } else {
  20035. (_stbi__zreceive($0,$4)|0);
  20036. $$pr = HEAP32[$2>>2]|0;
  20037. $$ph = $$pr;
  20038. }
  20039. $6 = ($$ph|0)>(0);
  20040. if ($6) {
  20041. $7 = ((($0)) + 12|0);
  20042. $$promoted = HEAP32[$7>>2]|0;
  20043. $8 = $$ph ^ -1;
  20044. $9 = ($8|0)>(-9);
  20045. $smax = $9 ? $8 : -9;
  20046. $10 = (($$ph) + ($smax))|0;
  20047. $11 = (($10) + 8)|0;
  20048. $12 = $11 >>> 3;
  20049. $13 = (($12) + 1)|0;
  20050. $14 = $12 << 3;
  20051. $$037 = 0;$16 = $$promoted;
  20052. while(1) {
  20053. $15 = $16&255;
  20054. $17 = (($$037) + 1)|0;
  20055. $18 = (($1) + ($$037)|0);
  20056. HEAP8[$18>>0] = $15;
  20057. $19 = $16 >>> 8;
  20058. $exitcond47 = ($17|0)==($13|0);
  20059. if ($exitcond47) {
  20060. break;
  20061. } else {
  20062. $$037 = $17;$16 = $19;
  20063. }
  20064. }
  20065. $20 = (($$ph) + -8)|0;
  20066. $21 = (($20) - ($14))|0;
  20067. HEAP32[$7>>2] = $19;
  20068. HEAP32[$2>>2] = $21;
  20069. $$0$lcssa = $13;$$lcssa = $21;
  20070. } else {
  20071. $$0$lcssa = 0;$$lcssa = $$ph;
  20072. }
  20073. $22 = ($$lcssa|0)==(0);
  20074. if (!($22)) {
  20075. ___assert_fail((11854|0),(10568|0),4033,(11871|0));
  20076. // unreachable;
  20077. }
  20078. $23 = ($$0$lcssa|0)<(4);
  20079. if ($23) {
  20080. $$136 = $$0$lcssa;
  20081. while(1) {
  20082. $24 = (_stbi__zget8($0)|0);
  20083. $25 = (($$136) + 1)|0;
  20084. $26 = (($1) + ($$136)|0);
  20085. HEAP8[$26>>0] = $24;
  20086. $exitcond = ($25|0)==(4);
  20087. if ($exitcond) {
  20088. break;
  20089. } else {
  20090. $$136 = $25;
  20091. }
  20092. }
  20093. }
  20094. $27 = ((($1)) + 1|0);
  20095. $28 = HEAP8[$27>>0]|0;
  20096. $29 = $28&255;
  20097. $30 = $29 << 8;
  20098. $31 = HEAP8[$1>>0]|0;
  20099. $32 = $31&255;
  20100. $33 = $30 | $32;
  20101. $34 = ((($1)) + 3|0);
  20102. $35 = HEAP8[$34>>0]|0;
  20103. $36 = $35&255;
  20104. $37 = $36 << 8;
  20105. $38 = ((($1)) + 2|0);
  20106. $39 = HEAP8[$38>>0]|0;
  20107. $40 = $39&255;
  20108. $41 = $37 | $40;
  20109. $42 = $33 ^ 65535;
  20110. $43 = ($41|0)==($42|0);
  20111. if (!($43)) {
  20112. _stbi__err(11902);
  20113. $$034 = 0;
  20114. STACKTOP = sp;return ($$034|0);
  20115. }
  20116. $44 = HEAP32[$0>>2]|0;
  20117. $45 = (($44) + ($33)|0);
  20118. $46 = ((($0)) + 4|0);
  20119. $47 = HEAP32[$46>>2]|0;
  20120. $48 = ($45>>>0)>($47>>>0);
  20121. if ($48) {
  20122. _stbi__err(11915);
  20123. $$034 = 0;
  20124. STACKTOP = sp;return ($$034|0);
  20125. }
  20126. $49 = ((($0)) + 16|0);
  20127. $50 = HEAP32[$49>>2]|0;
  20128. $51 = (($50) + ($33)|0);
  20129. $52 = ((($0)) + 24|0);
  20130. $53 = HEAP32[$52>>2]|0;
  20131. $54 = ($51>>>0)>($53>>>0);
  20132. if ($54) {
  20133. $55 = (_stbi__zexpand($0,$50,$33)|0);
  20134. $56 = ($55|0)==(0);
  20135. if ($56) {
  20136. $$034 = 0;
  20137. STACKTOP = sp;return ($$034|0);
  20138. }
  20139. }
  20140. $57 = HEAP32[$49>>2]|0;
  20141. $58 = HEAP32[$0>>2]|0;
  20142. _memcpy(($57|0),($58|0),($33|0))|0;
  20143. $59 = HEAP32[$0>>2]|0;
  20144. $60 = (($59) + ($33)|0);
  20145. HEAP32[$0>>2] = $60;
  20146. $61 = HEAP32[$49>>2]|0;
  20147. $62 = (($61) + ($33)|0);
  20148. HEAP32[$49>>2] = $62;
  20149. $$034 = 1;
  20150. STACKTOP = sp;return ($$034|0);
  20151. }
  20152. function _stbi__zbuild_huffman($0,$1,$2) {
  20153. $0 = $0|0;
  20154. $1 = $1|0;
  20155. $2 = $2|0;
  20156. var $$075 = 0, $$07688 = 0, $$07785 = 0, $$07884 = 0, $$081 = 0, $$286 = 0, $$382 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0;
  20157. var $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0;
  20158. var $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0;
  20159. var $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0;
  20160. var $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0;
  20161. var $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $exitcond = 0, $exitcond91 = 0, $or$cond = 0, dest = 0, label = 0, sp = 0, stop = 0;
  20162. sp = STACKTOP;
  20163. STACKTOP = STACKTOP + 144|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(144|0);
  20164. $3 = sp + 72|0;
  20165. $4 = sp;
  20166. dest=$4; stop=dest+68|0; do { HEAP32[dest>>2]=0|0; dest=dest+4|0; } while ((dest|0) < (stop|0));
  20167. _memset(($0|0),0,1024)|0;
  20168. $5 = ($2|0)>(0);
  20169. if ($5) {
  20170. $$07688 = 0;
  20171. while(1) {
  20172. $6 = (($1) + ($$07688)|0);
  20173. $7 = HEAP8[$6>>0]|0;
  20174. $8 = $7&255;
  20175. $9 = (($4) + ($8<<2)|0);
  20176. $10 = HEAP32[$9>>2]|0;
  20177. $11 = (($10) + 1)|0;
  20178. HEAP32[$9>>2] = $11;
  20179. $12 = (($$07688) + 1)|0;
  20180. $exitcond91 = ($12|0)==($2|0);
  20181. if ($exitcond91) {
  20182. break;
  20183. } else {
  20184. $$07688 = $12;
  20185. }
  20186. }
  20187. }
  20188. HEAP32[$4>>2] = 0;
  20189. $16 = ((($4)) + 4|0);
  20190. $17 = HEAP32[$16>>2]|0;
  20191. $18 = ($17|0)>(2);
  20192. if (!($18)) {
  20193. $13 = ((($4)) + 8|0);
  20194. $14 = HEAP32[$13>>2]|0;
  20195. $15 = ($14|0)>(4);
  20196. if (!($15)) {
  20197. $69 = ((($4)) + 12|0);
  20198. $70 = HEAP32[$69>>2]|0;
  20199. $71 = ($70|0)>(8);
  20200. if (!($71)) {
  20201. $72 = ((($4)) + 16|0);
  20202. $73 = HEAP32[$72>>2]|0;
  20203. $74 = ($73|0)>(16);
  20204. if (!($74)) {
  20205. $75 = ((($4)) + 20|0);
  20206. $76 = HEAP32[$75>>2]|0;
  20207. $77 = ($76|0)>(32);
  20208. if (!($77)) {
  20209. $78 = ((($4)) + 24|0);
  20210. $79 = HEAP32[$78>>2]|0;
  20211. $80 = ($79|0)>(64);
  20212. if (!($80)) {
  20213. $81 = ((($4)) + 28|0);
  20214. $82 = HEAP32[$81>>2]|0;
  20215. $83 = ($82|0)>(128);
  20216. if (!($83)) {
  20217. $84 = ((($4)) + 32|0);
  20218. $85 = HEAP32[$84>>2]|0;
  20219. $86 = ($85|0)>(256);
  20220. if (!($86)) {
  20221. $87 = ((($4)) + 36|0);
  20222. $88 = HEAP32[$87>>2]|0;
  20223. $89 = ($88|0)>(512);
  20224. if (!($89)) {
  20225. $90 = ((($4)) + 40|0);
  20226. $91 = HEAP32[$90>>2]|0;
  20227. $92 = ($91|0)>(1024);
  20228. if (!($92)) {
  20229. $93 = ((($4)) + 44|0);
  20230. $94 = HEAP32[$93>>2]|0;
  20231. $95 = ($94|0)>(2048);
  20232. if (!($95)) {
  20233. $96 = ((($4)) + 48|0);
  20234. $97 = HEAP32[$96>>2]|0;
  20235. $98 = ($97|0)>(4096);
  20236. if (!($98)) {
  20237. $99 = ((($4)) + 52|0);
  20238. $100 = HEAP32[$99>>2]|0;
  20239. $101 = ($100|0)>(8192);
  20240. if (!($101)) {
  20241. $102 = ((($4)) + 56|0);
  20242. $103 = HEAP32[$102>>2]|0;
  20243. $104 = ($103|0)>(16384);
  20244. if (!($104)) {
  20245. $105 = ((($4)) + 60|0);
  20246. $106 = HEAP32[$105>>2]|0;
  20247. $107 = ($106|0)>(32768);
  20248. if (!($107)) {
  20249. $$07785 = 0;$$07884 = 0;$$286 = 1;
  20250. while(1) {
  20251. $19 = (($3) + ($$286<<2)|0);
  20252. HEAP32[$19>>2] = $$07884;
  20253. $20 = $$07884&65535;
  20254. $21 = (((($0)) + 1024|0) + ($$286<<1)|0);
  20255. HEAP16[$21>>1] = $20;
  20256. $22 = $$07785&65535;
  20257. $23 = (((($0)) + 1124|0) + ($$286<<1)|0);
  20258. HEAP16[$23>>1] = $22;
  20259. $24 = (($4) + ($$286<<2)|0);
  20260. $25 = HEAP32[$24>>2]|0;
  20261. $26 = (($25) + ($$07884))|0;
  20262. $27 = ($25|0)!=(0);
  20263. $28 = 1 << $$286;
  20264. $29 = ($26|0)>($28|0);
  20265. $or$cond = $27 & $29;
  20266. if ($or$cond) {
  20267. label = 7;
  20268. break;
  20269. }
  20270. $30 = (16 - ($$286))|0;
  20271. $31 = $26 << $30;
  20272. $32 = (((($0)) + 1056|0) + ($$286<<2)|0);
  20273. HEAP32[$32>>2] = $31;
  20274. $33 = $26 << 1;
  20275. $34 = (($25) + ($$07785))|0;
  20276. $35 = (($$286) + 1)|0;
  20277. $36 = ($35|0)<(16);
  20278. if ($36) {
  20279. $$07785 = $34;$$07884 = $33;$$286 = $35;
  20280. } else {
  20281. break;
  20282. }
  20283. }
  20284. if ((label|0) == 7) {
  20285. _stbi__err(11792);
  20286. $$075 = 0;
  20287. STACKTOP = sp;return ($$075|0);
  20288. }
  20289. $37 = ((($0)) + 1120|0);
  20290. HEAP32[$37>>2] = 65536;
  20291. $38 = ($2|0)>(0);
  20292. if ($38) {
  20293. $$382 = 0;
  20294. } else {
  20295. $$075 = 1;
  20296. STACKTOP = sp;return ($$075|0);
  20297. }
  20298. while(1) {
  20299. $39 = (($1) + ($$382)|0);
  20300. $40 = HEAP8[$39>>0]|0;
  20301. $41 = $40&255;
  20302. $42 = ($40<<24>>24)==(0);
  20303. if (!($42)) {
  20304. $43 = (($3) + ($41<<2)|0);
  20305. $44 = HEAP32[$43>>2]|0;
  20306. $45 = (((($0)) + 1024|0) + ($41<<1)|0);
  20307. $46 = HEAP16[$45>>1]|0;
  20308. $47 = $46&65535;
  20309. $48 = (($44) - ($47))|0;
  20310. $49 = (((($0)) + 1124|0) + ($41<<1)|0);
  20311. $50 = HEAP16[$49>>1]|0;
  20312. $51 = $50&65535;
  20313. $52 = (($48) + ($51))|0;
  20314. $53 = $41 << 9;
  20315. $54 = $53 | $$382;
  20316. $55 = $54&65535;
  20317. $56 = (((($0)) + 1156|0) + ($52)|0);
  20318. HEAP8[$56>>0] = $40;
  20319. $57 = $$382&65535;
  20320. $58 = (((($0)) + 1444|0) + ($52<<1)|0);
  20321. HEAP16[$58>>1] = $57;
  20322. $59 = ($40&255)<(10);
  20323. do {
  20324. if ($59) {
  20325. $60 = (_stbi__bit_reverse($44,$41)|0);
  20326. $61 = ($60|0)<(512);
  20327. if (!($61)) {
  20328. break;
  20329. }
  20330. $62 = 1 << $41;
  20331. $$081 = $60;
  20332. while(1) {
  20333. $63 = (($0) + ($$081<<1)|0);
  20334. HEAP16[$63>>1] = $55;
  20335. $64 = (($$081) + ($62))|0;
  20336. $65 = ($64|0)<(512);
  20337. if ($65) {
  20338. $$081 = $64;
  20339. } else {
  20340. break;
  20341. }
  20342. }
  20343. }
  20344. } while(0);
  20345. $66 = HEAP32[$43>>2]|0;
  20346. $67 = (($66) + 1)|0;
  20347. HEAP32[$43>>2] = $67;
  20348. }
  20349. $68 = (($$382) + 1)|0;
  20350. $exitcond = ($68|0)==($2|0);
  20351. if ($exitcond) {
  20352. $$075 = 1;
  20353. break;
  20354. } else {
  20355. $$382 = $68;
  20356. }
  20357. }
  20358. STACKTOP = sp;return ($$075|0);
  20359. }
  20360. }
  20361. }
  20362. }
  20363. }
  20364. }
  20365. }
  20366. }
  20367. }
  20368. }
  20369. }
  20370. }
  20371. }
  20372. }
  20373. }
  20374. _stbi__err(11844);
  20375. $$075 = 0;
  20376. STACKTOP = sp;return ($$075|0);
  20377. }
  20378. function _stbi__compute_huffman_codes($0) {
  20379. $0 = $0|0;
  20380. var $$ = 0, $$0 = 0, $$061 = 0, $$06579 = 0, $$066$be = 0, $$066$lcssa = 0, $$06678 = 0, $$4 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0;
  20381. var $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0;
  20382. var $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $not$ = 0, dest = 0;
  20383. var label = 0, sp = 0, stop = 0;
  20384. sp = STACKTOP;
  20385. STACKTOP = STACKTOP + 2496|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(2496|0);
  20386. $1 = sp;
  20387. $2 = sp + 2039|0;
  20388. $3 = sp + 2020|0;
  20389. $4 = (_stbi__zreceive($0,5)|0);
  20390. $5 = (($4) + 257)|0;
  20391. $6 = (_stbi__zreceive($0,5)|0);
  20392. $7 = (($6) + 1)|0;
  20393. $8 = (_stbi__zreceive($0,4)|0);
  20394. $9 = (($8) + 4)|0;
  20395. $10 = (($7) + ($5))|0;
  20396. dest=$3; stop=dest+19|0; do { HEAP8[dest>>0]=0|0; dest=dest+1|0; } while ((dest|0) < (stop|0));
  20397. $11 = ($9|0)>(0);
  20398. if ($11) {
  20399. $$06579 = 0;
  20400. while(1) {
  20401. $12 = (_stbi__zreceive($0,3)|0);
  20402. $13 = $12&255;
  20403. $14 = (15205 + ($$06579)|0);
  20404. $15 = HEAP8[$14>>0]|0;
  20405. $16 = $15&255;
  20406. $17 = (($3) + ($16)|0);
  20407. HEAP8[$17>>0] = $13;
  20408. $18 = (($$06579) + 1)|0;
  20409. $exitcond = ($18|0)==($9|0);
  20410. if ($exitcond) {
  20411. break;
  20412. } else {
  20413. $$06579 = $18;
  20414. }
  20415. }
  20416. }
  20417. $19 = (_stbi__zbuild_huffman($1,$3,19)|0);
  20418. $20 = ($19|0)==(0);
  20419. if ($20) {
  20420. $$4 = 0;
  20421. STACKTOP = sp;return ($$4|0);
  20422. }
  20423. $21 = ($10|0)>(0);
  20424. L8: do {
  20425. if ($21) {
  20426. $$06678 = 0;
  20427. L9: while(1) {
  20428. $22 = (_stbi__zhuffman_decode($0,$1)|0);
  20429. $23 = ($22>>>0)>(18);
  20430. if ($23) {
  20431. label = 6;
  20432. break;
  20433. }
  20434. $24 = ($22|0)<(16);
  20435. if ($24) {
  20436. $25 = $22&255;
  20437. $26 = (($$06678) + 1)|0;
  20438. $27 = (($2) + ($$06678)|0);
  20439. HEAP8[$27>>0] = $25;
  20440. $$066$be = $26;
  20441. } else {
  20442. switch ($22|0) {
  20443. case 16: {
  20444. $28 = (_stbi__zreceive($0,2)|0);
  20445. $29 = ($$06678|0)==(0);
  20446. if ($29) {
  20447. label = 11;
  20448. break L9;
  20449. }
  20450. $30 = (($28) + 3)|0;
  20451. $31 = (($$06678) + -1)|0;
  20452. $32 = (($2) + ($31)|0);
  20453. $33 = HEAP8[$32>>0]|0;
  20454. $$0 = $33;$$061 = $30;
  20455. break;
  20456. }
  20457. case 17: {
  20458. $34 = (_stbi__zreceive($0,3)|0);
  20459. $35 = (($34) + 3)|0;
  20460. $$0 = 0;$$061 = $35;
  20461. break;
  20462. }
  20463. case 18: {
  20464. $36 = (_stbi__zreceive($0,7)|0);
  20465. $37 = (($36) + 11)|0;
  20466. $$0 = 0;$$061 = $37;
  20467. break;
  20468. }
  20469. default: {
  20470. label = 14;
  20471. break L9;
  20472. }
  20473. }
  20474. $38 = (($10) - ($$06678))|0;
  20475. $39 = ($38|0)<($$061|0);
  20476. if ($39) {
  20477. label = 17;
  20478. break;
  20479. }
  20480. $40 = (($2) + ($$06678)|0);
  20481. _memset(($40|0),($$0|0),($$061|0))|0;
  20482. $41 = (($$061) + ($$06678))|0;
  20483. $$066$be = $41;
  20484. }
  20485. $42 = ($10|0)>($$066$be|0);
  20486. if ($42) {
  20487. $$06678 = $$066$be;
  20488. } else {
  20489. $$066$lcssa = $$066$be;
  20490. break L8;
  20491. }
  20492. }
  20493. if ((label|0) == 6) {
  20494. _stbi__err(11792);
  20495. $$4 = 0;
  20496. STACKTOP = sp;return ($$4|0);
  20497. }
  20498. else if ((label|0) == 11) {
  20499. _stbi__err(11792);
  20500. $$4 = 0;
  20501. STACKTOP = sp;return ($$4|0);
  20502. }
  20503. else if ((label|0) == 14) {
  20504. ___assert_fail((11808|0),(10568|0),4006,(11816|0));
  20505. // unreachable;
  20506. }
  20507. else if ((label|0) == 17) {
  20508. _stbi__err(11792);
  20509. $$4 = 0;
  20510. STACKTOP = sp;return ($$4|0);
  20511. }
  20512. } else {
  20513. $$066$lcssa = 0;
  20514. }
  20515. } while(0);
  20516. $43 = ($10|0)==($$066$lcssa|0);
  20517. if (!($43)) {
  20518. _stbi__err(11792);
  20519. $$4 = 0;
  20520. STACKTOP = sp;return ($$4|0);
  20521. }
  20522. $44 = ((($0)) + 32|0);
  20523. $45 = (_stbi__zbuild_huffman($44,$2,$5)|0);
  20524. $46 = ($45|0)==(0);
  20525. if ($46) {
  20526. $$4 = 0;
  20527. STACKTOP = sp;return ($$4|0);
  20528. }
  20529. $47 = ((($0)) + 2052|0);
  20530. $48 = (($2) + ($5)|0);
  20531. $49 = (_stbi__zbuild_huffman($47,$48,$7)|0);
  20532. $not$ = ($49|0)!=(0);
  20533. $$ = $not$&1;
  20534. $$4 = $$;
  20535. STACKTOP = sp;return ($$4|0);
  20536. }
  20537. function _stbi__parse_huffman_block($0) {
  20538. $0 = $0|0;
  20539. var $$063 = 0, $$064 = 0, $$067 = 0, $$070 = 0, $$171 = 0, $$266 = 0, $$272 = 0, $$3$ph = 0, $$5 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0;
  20540. var $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0;
  20541. var $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0;
  20542. var $56 = 0, $57 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $scevgep = 0, $scevgep92 = 0, label = 0, sp = 0;
  20543. sp = STACKTOP;
  20544. $1 = ((($0)) + 16|0);
  20545. $2 = HEAP32[$1>>2]|0;
  20546. $3 = ((($0)) + 32|0);
  20547. $4 = ((($0)) + 24|0);
  20548. $5 = ((($0)) + 2052|0);
  20549. $6 = ((($0)) + 20|0);
  20550. $7 = ((($0)) + 24|0);
  20551. $$070 = $2;
  20552. while(1) {
  20553. $10 = (_stbi__zhuffman_decode($0,$3)|0);
  20554. $11 = ($10|0)<(256);
  20555. if ($11) {
  20556. $12 = ($10|0)<(0);
  20557. if ($12) {
  20558. label = 6;
  20559. break;
  20560. }
  20561. $13 = HEAP32[$4>>2]|0;
  20562. $14 = ($$070>>>0)<($13>>>0);
  20563. if ($14) {
  20564. $$171 = $$070;
  20565. } else {
  20566. $15 = (_stbi__zexpand($0,$$070,1)|0);
  20567. $16 = ($15|0)==(0);
  20568. if ($16) {
  20569. $$3$ph = 0;
  20570. label = 28;
  20571. break;
  20572. }
  20573. $17 = HEAP32[$1>>2]|0;
  20574. $$171 = $17;
  20575. }
  20576. $18 = $10&255;
  20577. $19 = ((($$171)) + 1|0);
  20578. HEAP8[$$171>>0] = $18;
  20579. $$070 = $19;
  20580. continue;
  20581. }
  20582. $20 = ($10|0)==(256);
  20583. if ($20) {
  20584. label = 12;
  20585. break;
  20586. }
  20587. $21 = (($10) + -257)|0;
  20588. $22 = (4728 + ($21<<2)|0);
  20589. $23 = HEAP32[$22>>2]|0;
  20590. $24 = (($10) + -265)|0;
  20591. $25 = ($24>>>0)<(20);
  20592. if ($25) {
  20593. $26 = (4604 + ($21<<2)|0);
  20594. $27 = HEAP32[$26>>2]|0;
  20595. $28 = (_stbi__zreceive($0,$27)|0);
  20596. $29 = (($28) + ($23))|0;
  20597. $$064 = $29;
  20598. } else {
  20599. $$064 = $23;
  20600. }
  20601. $30 = (_stbi__zhuffman_decode($0,$5)|0);
  20602. $31 = ($30|0)<(0);
  20603. if ($31) {
  20604. label = 16;
  20605. break;
  20606. }
  20607. $32 = (4980 + ($30<<2)|0);
  20608. $33 = HEAP32[$32>>2]|0;
  20609. $34 = (($30) + -4)|0;
  20610. $35 = ($34>>>0)<(26);
  20611. if ($35) {
  20612. $36 = (4852 + ($30<<2)|0);
  20613. $37 = HEAP32[$36>>2]|0;
  20614. $38 = (_stbi__zreceive($0,$37)|0);
  20615. $39 = (($38) + ($33))|0;
  20616. $$063 = $39;
  20617. } else {
  20618. $$063 = $33;
  20619. }
  20620. $40 = HEAP32[$6>>2]|0;
  20621. $41 = $$070;
  20622. $42 = (($41) - ($40))|0;
  20623. $43 = ($42|0)<($$063|0);
  20624. if ($43) {
  20625. label = 20;
  20626. break;
  20627. }
  20628. $44 = (($$070) + ($$064)|0);
  20629. $45 = HEAP32[$7>>2]|0;
  20630. $46 = ($44>>>0)>($45>>>0);
  20631. if ($46) {
  20632. $47 = (_stbi__zexpand($0,$$070,$$064)|0);
  20633. $48 = ($47|0)==(0);
  20634. if ($48) {
  20635. $$3$ph = 0;
  20636. label = 28;
  20637. break;
  20638. }
  20639. $49 = HEAP32[$1>>2]|0;
  20640. $$272 = $49;
  20641. } else {
  20642. $$272 = $$070;
  20643. }
  20644. $50 = (0 - ($$063))|0;
  20645. $9 = (($$272) + ($50)|0);
  20646. $51 = ($$063|0)==(1);
  20647. $52 = ($$064|0)!=(0);
  20648. if ($51) {
  20649. if (!($52)) {
  20650. $$070 = $$272;
  20651. continue;
  20652. }
  20653. $8 = HEAP8[$9>>0]|0;
  20654. _memset(($$272|0),($8|0),($$064|0))|0;
  20655. $scevgep92 = (($$272) + ($$064)|0);
  20656. $$070 = $scevgep92;
  20657. continue;
  20658. }
  20659. if ($52) {
  20660. $$067 = $9;$$266 = $$064;$$5 = $$272;
  20661. } else {
  20662. $$070 = $$272;
  20663. continue;
  20664. }
  20665. while(1) {
  20666. $53 = ((($$067)) + 1|0);
  20667. $54 = HEAP8[$$067>>0]|0;
  20668. $55 = ((($$5)) + 1|0);
  20669. HEAP8[$$5>>0] = $54;
  20670. $56 = (($$266) + -1)|0;
  20671. $57 = ($56|0)==(0);
  20672. if ($57) {
  20673. break;
  20674. } else {
  20675. $$067 = $53;$$266 = $56;$$5 = $55;
  20676. }
  20677. }
  20678. $scevgep = (($$272) + ($$064)|0);
  20679. $$070 = $scevgep;
  20680. }
  20681. if ((label|0) == 6) {
  20682. _stbi__err(11617);
  20683. $$3$ph = 0;
  20684. return ($$3$ph|0);
  20685. }
  20686. else if ((label|0) == 12) {
  20687. HEAP32[$1>>2] = $$070;
  20688. $$3$ph = 1;
  20689. return ($$3$ph|0);
  20690. }
  20691. else if ((label|0) == 16) {
  20692. _stbi__err(11617);
  20693. $$3$ph = 0;
  20694. return ($$3$ph|0);
  20695. }
  20696. else if ((label|0) == 20) {
  20697. _stbi__err(11634);
  20698. $$3$ph = 0;
  20699. return ($$3$ph|0);
  20700. }
  20701. else if ((label|0) == 28) {
  20702. return ($$3$ph|0);
  20703. }
  20704. return (0)|0;
  20705. }
  20706. function _stbi__zhuffman_decode($0,$1) {
  20707. $0 = $0|0;
  20708. $1 = $1|0;
  20709. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  20710. sp = STACKTOP;
  20711. $2 = ((($0)) + 8|0);
  20712. $3 = HEAP32[$2>>2]|0;
  20713. $4 = ($3|0)<(16);
  20714. if ($4) {
  20715. _stbi__fill_bits($0);
  20716. }
  20717. $5 = ((($0)) + 12|0);
  20718. $6 = HEAP32[$5>>2]|0;
  20719. $7 = $6 & 511;
  20720. $8 = (($1) + ($7<<1)|0);
  20721. $9 = HEAP16[$8>>1]|0;
  20722. $10 = $9&65535;
  20723. $11 = ($9<<16>>16)==(0);
  20724. if ($11) {
  20725. $17 = (_stbi__zhuffman_decode_slowpath($0,$1)|0);
  20726. $$0 = $17;
  20727. return ($$0|0);
  20728. } else {
  20729. $12 = $10 >>> 9;
  20730. $13 = $6 >>> $12;
  20731. HEAP32[$5>>2] = $13;
  20732. $14 = HEAP32[$2>>2]|0;
  20733. $15 = (($14) - ($12))|0;
  20734. HEAP32[$2>>2] = $15;
  20735. $16 = $10 & 511;
  20736. $$0 = $16;
  20737. return ($$0|0);
  20738. }
  20739. return (0)|0;
  20740. }
  20741. function _stbi__zexpand($0,$1,$2) {
  20742. $0 = $0|0;
  20743. $1 = $1|0;
  20744. $2 = $2|0;
  20745. var $$0 = 0, $$029 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0;
  20746. var $9 = 0, label = 0, sp = 0;
  20747. sp = STACKTOP;
  20748. $3 = ((($0)) + 16|0);
  20749. HEAP32[$3>>2] = $1;
  20750. $4 = ((($0)) + 28|0);
  20751. $5 = HEAP32[$4>>2]|0;
  20752. $6 = ($5|0)==(0);
  20753. if ($6) {
  20754. _stbi__err(11643);
  20755. $$0 = 0;
  20756. return ($$0|0);
  20757. }
  20758. $7 = ((($0)) + 20|0);
  20759. $8 = HEAP32[$7>>2]|0;
  20760. $9 = $1;
  20761. $10 = $8;
  20762. $11 = (($9) - ($10))|0;
  20763. $12 = ((($0)) + 24|0);
  20764. $13 = HEAP32[$12>>2]|0;
  20765. $14 = (($13) - ($10))|0;
  20766. $15 = (($11) + ($2))|0;
  20767. $$029 = $14;
  20768. while(1) {
  20769. $16 = ($15|0)>($$029|0);
  20770. $17 = $$029 << 1;
  20771. if ($16) {
  20772. $$029 = $17;
  20773. } else {
  20774. break;
  20775. }
  20776. }
  20777. $18 = (_realloc($8,$$029)|0);
  20778. $19 = ($18|0)==(0|0);
  20779. if ($19) {
  20780. _stbi__err(10623);
  20781. $$0 = 0;
  20782. return ($$0|0);
  20783. } else {
  20784. HEAP32[$7>>2] = $18;
  20785. $20 = (($18) + ($11)|0);
  20786. HEAP32[$3>>2] = $20;
  20787. $21 = (($18) + ($$029)|0);
  20788. HEAP32[$12>>2] = $21;
  20789. $$0 = 1;
  20790. return ($$0|0);
  20791. }
  20792. return (0)|0;
  20793. }
  20794. function _stbi__fill_bits($0) {
  20795. $0 = $0|0;
  20796. var $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  20797. sp = STACKTOP;
  20798. $1 = ((($0)) + 12|0);
  20799. $2 = ((($0)) + 8|0);
  20800. while(1) {
  20801. $3 = HEAP32[$1>>2]|0;
  20802. $4 = HEAP32[$2>>2]|0;
  20803. $5 = 1 << $4;
  20804. $6 = ($3>>>0)<($5>>>0);
  20805. if (!($6)) {
  20806. label = 3;
  20807. break;
  20808. }
  20809. $7 = (_stbi__zget8($0)|0);
  20810. $8 = $7&255;
  20811. $9 = HEAP32[$2>>2]|0;
  20812. $10 = $8 << $9;
  20813. $11 = HEAP32[$1>>2]|0;
  20814. $12 = $11 | $10;
  20815. HEAP32[$1>>2] = $12;
  20816. $13 = (($9) + 8)|0;
  20817. HEAP32[$2>>2] = $13;
  20818. $14 = ($13|0)<(25);
  20819. if (!($14)) {
  20820. label = 5;
  20821. break;
  20822. }
  20823. }
  20824. if ((label|0) == 3) {
  20825. ___assert_fail((11739|0),(10568|0),3848,(11776|0));
  20826. // unreachable;
  20827. }
  20828. else if ((label|0) == 5) {
  20829. return;
  20830. }
  20831. }
  20832. function _stbi__zhuffman_decode_slowpath($0,$1) {
  20833. $0 = $0|0;
  20834. $1 = $1|0;
  20835. var $$0 = 0, $$025 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  20836. var $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  20837. sp = STACKTOP;
  20838. $2 = ((($0)) + 12|0);
  20839. $3 = HEAP32[$2>>2]|0;
  20840. $4 = (_stbi__bit_reverse($3,16)|0);
  20841. $$025 = 10;
  20842. while(1) {
  20843. $5 = (((($1)) + 1056|0) + ($$025<<2)|0);
  20844. $6 = HEAP32[$5>>2]|0;
  20845. $7 = ($4|0)<($6|0);
  20846. $8 = (($$025) + 1)|0;
  20847. if ($7) {
  20848. break;
  20849. } else {
  20850. $$025 = $8;
  20851. }
  20852. }
  20853. $9 = ($$025|0)==(16);
  20854. if ($9) {
  20855. $$0 = -1;
  20856. return ($$0|0);
  20857. }
  20858. $10 = (16 - ($$025))|0;
  20859. $11 = $4 >> $10;
  20860. $12 = (((($1)) + 1024|0) + ($$025<<1)|0);
  20861. $13 = HEAP16[$12>>1]|0;
  20862. $14 = $13&65535;
  20863. $15 = (($11) - ($14))|0;
  20864. $16 = (((($1)) + 1124|0) + ($$025<<1)|0);
  20865. $17 = HEAP16[$16>>1]|0;
  20866. $18 = $17&65535;
  20867. $19 = (($15) + ($18))|0;
  20868. $20 = (((($1)) + 1156|0) + ($19)|0);
  20869. $21 = HEAP8[$20>>0]|0;
  20870. $22 = $21&255;
  20871. $23 = ($22|0)==($$025|0);
  20872. if (!($23)) {
  20873. ___assert_fail((11663|0),(10568|0),3876,(11679|0));
  20874. // unreachable;
  20875. }
  20876. $24 = HEAP32[$2>>2]|0;
  20877. $25 = $24 >>> $$025;
  20878. HEAP32[$2>>2] = $25;
  20879. $26 = ((($0)) + 8|0);
  20880. $27 = HEAP32[$26>>2]|0;
  20881. $28 = (($27) - ($$025))|0;
  20882. HEAP32[$26>>2] = $28;
  20883. $29 = (((($1)) + 1444|0) + ($19<<1)|0);
  20884. $30 = HEAP16[$29>>1]|0;
  20885. $31 = $30&65535;
  20886. $$0 = $31;
  20887. return ($$0|0);
  20888. }
  20889. function _stbi__bit_reverse($0,$1) {
  20890. $0 = $0|0;
  20891. $1 = $1|0;
  20892. var $2 = 0, $3 = 0, $4 = 0, $5 = 0, label = 0, sp = 0;
  20893. sp = STACKTOP;
  20894. $2 = ($1|0)<(17);
  20895. if ($2) {
  20896. $3 = (_stbi__bitreverse16($0)|0);
  20897. $4 = (16 - ($1))|0;
  20898. $5 = $3 >> $4;
  20899. return ($5|0);
  20900. } else {
  20901. ___assert_fail((11710|0),(10568|0),3766,(11721|0));
  20902. // unreachable;
  20903. }
  20904. return (0)|0;
  20905. }
  20906. function _stbi__bitreverse16($0) {
  20907. $0 = $0|0;
  20908. var $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0;
  20909. var sp = 0;
  20910. sp = STACKTOP;
  20911. $1 = $0 >>> 1;
  20912. $2 = $1 & 21845;
  20913. $3 = $0 << 1;
  20914. $4 = $3 & 43690;
  20915. $5 = $2 | $4;
  20916. $6 = $5 >>> 2;
  20917. $7 = $6 & 13107;
  20918. $8 = $5 << 2;
  20919. $9 = $8 & 52428;
  20920. $10 = $7 | $9;
  20921. $11 = $10 >>> 4;
  20922. $12 = $11 & 3855;
  20923. $13 = $10 << 4;
  20924. $14 = $13 & 61680;
  20925. $15 = $12 | $14;
  20926. $16 = $15 >>> 8;
  20927. $17 = $15 << 8;
  20928. $18 = $17 & 65280;
  20929. $19 = $18 | $16;
  20930. return ($19|0);
  20931. }
  20932. function _stbi__zget8($0) {
  20933. $0 = $0|0;
  20934. var $$0 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  20935. sp = STACKTOP;
  20936. $1 = HEAP32[$0>>2]|0;
  20937. $2 = ((($0)) + 4|0);
  20938. $3 = HEAP32[$2>>2]|0;
  20939. $4 = ($1>>>0)<($3>>>0);
  20940. if (!($4)) {
  20941. $$0 = 0;
  20942. return ($$0|0);
  20943. }
  20944. $5 = ((($1)) + 1|0);
  20945. HEAP32[$0>>2] = $5;
  20946. $6 = HEAP8[$1>>0]|0;
  20947. $$0 = $6;
  20948. return ($$0|0);
  20949. }
  20950. function _stbi__refill_buffer($0) {
  20951. $0 = $0|0;
  20952. var $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  20953. sp = STACKTOP;
  20954. $1 = ((($0)) + 16|0);
  20955. $2 = HEAP32[$1>>2]|0;
  20956. $3 = ((($0)) + 28|0);
  20957. $4 = HEAP32[$3>>2]|0;
  20958. $5 = ((($0)) + 40|0);
  20959. $6 = ((($0)) + 36|0);
  20960. $7 = HEAP32[$6>>2]|0;
  20961. $8 = (FUNCTION_TABLE_iiii[$2 & 15]($4,$5,$7)|0);
  20962. $9 = ($8|0)==(0);
  20963. if ($9) {
  20964. $10 = ((($0)) + 32|0);
  20965. HEAP32[$10>>2] = 0;
  20966. $11 = ((($0)) + 168|0);
  20967. HEAP32[$11>>2] = $5;
  20968. $12 = ((($0)) + 41|0);
  20969. $13 = ((($0)) + 172|0);
  20970. HEAP32[$13>>2] = $12;
  20971. HEAP8[$5>>0] = 0;
  20972. return;
  20973. } else {
  20974. $14 = ((($0)) + 168|0);
  20975. HEAP32[$14>>2] = $5;
  20976. $15 = (((($0)) + 40|0) + ($8)|0);
  20977. $16 = ((($0)) + 172|0);
  20978. HEAP32[$16>>2] = $15;
  20979. return;
  20980. }
  20981. }
  20982. function _stbi__rewind($0) {
  20983. $0 = $0|0;
  20984. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  20985. sp = STACKTOP;
  20986. $1 = ((($0)) + 176|0);
  20987. $2 = HEAP32[$1>>2]|0;
  20988. $3 = ((($0)) + 168|0);
  20989. HEAP32[$3>>2] = $2;
  20990. $4 = ((($0)) + 180|0);
  20991. $5 = HEAP32[$4>>2]|0;
  20992. $6 = ((($0)) + 172|0);
  20993. HEAP32[$6>>2] = $5;
  20994. return;
  20995. }
  20996. function _stbi__start_callbacks($0,$1,$2) {
  20997. $0 = $0|0;
  20998. $1 = $1|0;
  20999. $2 = $2|0;
  21000. var $10 = 0, $11 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  21001. sp = STACKTOP;
  21002. $3 = ((($0)) + 16|0);
  21003. ;HEAP32[$3>>2]=HEAP32[$1>>2]|0;HEAP32[$3+4>>2]=HEAP32[$1+4>>2]|0;HEAP32[$3+8>>2]=HEAP32[$1+8>>2]|0;
  21004. $4 = ((($0)) + 28|0);
  21005. HEAP32[$4>>2] = $2;
  21006. $5 = ((($0)) + 36|0);
  21007. HEAP32[$5>>2] = 128;
  21008. $6 = ((($0)) + 32|0);
  21009. HEAP32[$6>>2] = 1;
  21010. $7 = ((($0)) + 40|0);
  21011. $8 = ((($0)) + 176|0);
  21012. HEAP32[$8>>2] = $7;
  21013. _stbi__refill_buffer($0);
  21014. $9 = ((($0)) + 172|0);
  21015. $10 = HEAP32[$9>>2]|0;
  21016. $11 = ((($0)) + 180|0);
  21017. HEAP32[$11>>2] = $10;
  21018. return;
  21019. }
  21020. function _stbi__stdio_read($0,$1,$2) {
  21021. $0 = $0|0;
  21022. $1 = $1|0;
  21023. $2 = $2|0;
  21024. var $3 = 0, label = 0, sp = 0;
  21025. sp = STACKTOP;
  21026. $3 = (_fread($1,1,$2,$0)|0);
  21027. return ($3|0);
  21028. }
  21029. function _stbi__stdio_skip($0,$1) {
  21030. $0 = $0|0;
  21031. $1 = $1|0;
  21032. var label = 0, sp = 0;
  21033. sp = STACKTOP;
  21034. (_fseek($0,$1,1)|0);
  21035. return;
  21036. }
  21037. function _stbi__stdio_eof($0) {
  21038. $0 = $0|0;
  21039. var $1 = 0, label = 0, sp = 0;
  21040. sp = STACKTOP;
  21041. $1 = (_feof($0)|0);
  21042. return ($1|0);
  21043. }
  21044. function _stbir_resize_uint8($0,$1,$2,$3,$4,$5,$6,$7,$8) {
  21045. $0 = $0|0;
  21046. $1 = $1|0;
  21047. $2 = $2|0;
  21048. $3 = $3|0;
  21049. $4 = $4|0;
  21050. $5 = $5|0;
  21051. $6 = $6|0;
  21052. $7 = $7|0;
  21053. $8 = $8|0;
  21054. var $9 = 0, label = 0, sp = 0;
  21055. sp = STACKTOP;
  21056. $9 = (_stbir__resize_arbitrary($0,$1,$2,$3,$4,$5,$6,$7,0.0,0.0,1.0,1.0,0,$8,-1,0,0,0,0,1,1,0)|0);
  21057. return ($9|0);
  21058. }
  21059. function _stbir__resize_arbitrary($0,$1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18,$19,$20,$21) {
  21060. $0 = $0|0;
  21061. $1 = $1|0;
  21062. $2 = $2|0;
  21063. $3 = $3|0;
  21064. $4 = $4|0;
  21065. $5 = $5|0;
  21066. $6 = $6|0;
  21067. $7 = $7|0;
  21068. $8 = +$8;
  21069. $9 = +$9;
  21070. $10 = +$10;
  21071. $11 = +$11;
  21072. $12 = $12|0;
  21073. $13 = $13|0;
  21074. $14 = $14|0;
  21075. $15 = $15|0;
  21076. $16 = $16|0;
  21077. $17 = $17|0;
  21078. $18 = $18|0;
  21079. $19 = $19|0;
  21080. $20 = $20|0;
  21081. $21 = $21|0;
  21082. var $$0 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, label = 0, sp = 0;
  21083. sp = STACKTOP;
  21084. STACKTOP = STACKTOP + 224|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(224|0);
  21085. $22 = sp;
  21086. _stbir__setup($22,$1,$2,$5,$6,$13);
  21087. _stbir__calculate_transform($22,$8,$9,$10,$11,$12);
  21088. _stbir__choose_filter($22,$17,$18);
  21089. $23 = (_stbir__calculate_memory($22)|0);
  21090. $24 = (_malloc($23)|0);
  21091. $25 = ($24|0)==(0|0);
  21092. if ($25) {
  21093. $$0 = 0;
  21094. STACKTOP = sp;return ($$0|0);
  21095. }
  21096. $26 = (_stbir__resize_allocated($22,$0,$3,$4,$7,$14,$15,$16,$19,$20,$21,$24,$23)|0);
  21097. _free($24);
  21098. $$0 = $26;
  21099. STACKTOP = sp;return ($$0|0);
  21100. }
  21101. function _stbir__setup($0,$1,$2,$3,$4,$5) {
  21102. $0 = $0|0;
  21103. $1 = $1|0;
  21104. $2 = $2|0;
  21105. $3 = $3|0;
  21106. $4 = $4|0;
  21107. $5 = $5|0;
  21108. var $10 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  21109. sp = STACKTOP;
  21110. $6 = ((($0)) + 4|0);
  21111. HEAP32[$6>>2] = $1;
  21112. $7 = ((($0)) + 8|0);
  21113. HEAP32[$7>>2] = $2;
  21114. $8 = ((($0)) + 20|0);
  21115. HEAP32[$8>>2] = $3;
  21116. $9 = ((($0)) + 24|0);
  21117. HEAP32[$9>>2] = $4;
  21118. $10 = ((($0)) + 64|0);
  21119. HEAP32[$10>>2] = $5;
  21120. return;
  21121. }
  21122. function _stbir__calculate_transform($0,$1,$2,$3,$4,$5) {
  21123. $0 = $0|0;
  21124. $1 = +$1;
  21125. $2 = +$2;
  21126. $3 = +$3;
  21127. $4 = +$4;
  21128. $5 = $5|0;
  21129. var $$sink = 0.0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0.0, $21 = 0, $22 = 0, $23 = 0.0, $24 = 0, $25 = 0, $26 = 0.0, $27 = 0.0, $28 = 0.0;
  21130. var $29 = 0.0, $30 = 0, $31 = 0, $32 = 0, $33 = 0.0, $34 = 0, $35 = 0, $36 = 0.0, $37 = 0.0, $38 = 0.0, $39 = 0.0, $40 = 0, $41 = 0.0, $42 = 0.0, $43 = 0, $44 = 0.0, $45 = 0.0, $46 = 0, $6 = 0, $7 = 0;
  21131. var $8 = 0, $9 = 0, label = 0, sp = 0;
  21132. sp = STACKTOP;
  21133. $6 = ((($0)) + 32|0);
  21134. HEAPF32[$6>>2] = $1;
  21135. $7 = ((($0)) + 36|0);
  21136. HEAPF32[$7>>2] = $2;
  21137. $8 = ((($0)) + 40|0);
  21138. HEAPF32[$8>>2] = $3;
  21139. $9 = ((($0)) + 44|0);
  21140. HEAPF32[$9>>2] = $4;
  21141. $10 = ($5|0)==(0|0);
  21142. if ($10) {
  21143. $21 = ((($0)) + 20|0);
  21144. $22 = HEAP32[$21>>2]|0;
  21145. $23 = (+($22|0));
  21146. $24 = ((($0)) + 4|0);
  21147. $25 = HEAP32[$24>>2]|0;
  21148. $26 = (+($25|0));
  21149. $27 = $23 / $26;
  21150. $28 = $3 - $1;
  21151. $29 = $27 / $28;
  21152. $30 = ((($0)) + 56|0);
  21153. HEAPF32[$30>>2] = $29;
  21154. $31 = ((($0)) + 24|0);
  21155. $32 = HEAP32[$31>>2]|0;
  21156. $33 = (+($32|0));
  21157. $34 = ((($0)) + 8|0);
  21158. $35 = HEAP32[$34>>2]|0;
  21159. $36 = (+($35|0));
  21160. $37 = $33 / $36;
  21161. $38 = $4 - $2;
  21162. $39 = $37 / $38;
  21163. $40 = ((($0)) + 60|0);
  21164. HEAPF32[$40>>2] = $39;
  21165. $41 = $23 * $1;
  21166. $42 = $41 / $28;
  21167. $43 = ((($0)) + 48|0);
  21168. HEAPF32[$43>>2] = $42;
  21169. $44 = $33 * $2;
  21170. $45 = $44 / $38;
  21171. $$sink = $45;
  21172. $46 = ((($0)) + 52|0);
  21173. HEAPF32[$46>>2] = $$sink;
  21174. return;
  21175. } else {
  21176. $11 = HEAP32[$5>>2]|0;
  21177. $12 = ((($0)) + 56|0);
  21178. HEAP32[$12>>2] = $11;
  21179. $13 = ((($5)) + 4|0);
  21180. $14 = HEAP32[$13>>2]|0;
  21181. $15 = ((($0)) + 60|0);
  21182. HEAP32[$15>>2] = $14;
  21183. $16 = ((($5)) + 8|0);
  21184. $17 = HEAP32[$16>>2]|0;
  21185. $18 = ((($0)) + 48|0);
  21186. HEAP32[$18>>2] = $17;
  21187. $19 = ((($5)) + 12|0);
  21188. $20 = +HEAPF32[$19>>2];
  21189. $$sink = $20;
  21190. $46 = ((($0)) + 52|0);
  21191. HEAPF32[$46>>2] = $$sink;
  21192. return;
  21193. }
  21194. }
  21195. function _stbir__choose_filter($0,$1,$2) {
  21196. $0 = $0|0;
  21197. $1 = $1|0;
  21198. $2 = $2|0;
  21199. var $$0 = 0, $$07 = 0, $10 = 0, $11 = 0.0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $3 = 0, $4 = 0, $5 = 0.0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  21200. sp = STACKTOP;
  21201. $3 = ($1|0)==(0);
  21202. if ($3) {
  21203. $4 = ((($0)) + 56|0);
  21204. $5 = +HEAPF32[$4>>2];
  21205. $6 = (_stbir__use_upsampling($5)|0);
  21206. $7 = ($6|0)!=(0);
  21207. $8 = $7 ? 4 : 5;
  21208. $$07 = $8;
  21209. } else {
  21210. $$07 = $1;
  21211. }
  21212. $9 = ($2|0)==(0);
  21213. if ($9) {
  21214. $10 = ((($0)) + 60|0);
  21215. $11 = +HEAPF32[$10>>2];
  21216. $12 = (_stbir__use_upsampling($11)|0);
  21217. $13 = ($12|0)!=(0);
  21218. $14 = $13 ? 4 : 5;
  21219. $$0 = $14;
  21220. } else {
  21221. $$0 = $2;
  21222. }
  21223. $15 = ((($0)) + 80|0);
  21224. HEAP32[$15>>2] = $$07;
  21225. $16 = ((($0)) + 84|0);
  21226. HEAP32[$16>>2] = $$0;
  21227. return;
  21228. }
  21229. function _stbir__calculate_memory($0) {
  21230. $0 = $0|0;
  21231. var $$sink = 0, $1 = 0, $10 = 0, $11 = 0.0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0.0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  21232. var $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0.0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  21233. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0;
  21234. var $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0;
  21235. var $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $9 = 0.0, label = 0, sp = 0;
  21236. sp = STACKTOP;
  21237. $1 = ((($0)) + 80|0);
  21238. $2 = HEAP32[$1>>2]|0;
  21239. $3 = ((($0)) + 56|0);
  21240. $4 = +HEAPF32[$3>>2];
  21241. $5 = (_stbir__get_filter_pixel_margin($2,$4)|0);
  21242. $6 = ((($0)) + 84|0);
  21243. $7 = HEAP32[$6>>2]|0;
  21244. $8 = ((($0)) + 60|0);
  21245. $9 = +HEAPF32[$8>>2];
  21246. $10 = (_stbir__get_filter_pixel_width($7,$9)|0);
  21247. $11 = +HEAPF32[$3>>2];
  21248. $12 = HEAP32[$1>>2]|0;
  21249. $13 = ((($0)) + 4|0);
  21250. $14 = HEAP32[$13>>2]|0;
  21251. $15 = ((($0)) + 20|0);
  21252. $16 = HEAP32[$15>>2]|0;
  21253. $17 = (_stbir__get_contributors($11,$12,$14,$16)|0);
  21254. $18 = ((($0)) + 152|0);
  21255. HEAP32[$18>>2] = $17;
  21256. $19 = +HEAPF32[$8>>2];
  21257. $20 = HEAP32[$6>>2]|0;
  21258. $21 = ((($0)) + 8|0);
  21259. $22 = HEAP32[$21>>2]|0;
  21260. $23 = ((($0)) + 24|0);
  21261. $24 = HEAP32[$23>>2]|0;
  21262. $25 = (_stbir__get_contributors($19,$20,$22,$24)|0);
  21263. $26 = ((($0)) + 156|0);
  21264. HEAP32[$26>>2] = $25;
  21265. $27 = (($10) + 1)|0;
  21266. $28 = ((($0)) + 164|0);
  21267. HEAP32[$28>>2] = $27;
  21268. $29 = HEAP32[$18>>2]|0;
  21269. $30 = $29 << 3;
  21270. $31 = ((($0)) + 188|0);
  21271. HEAP32[$31>>2] = $30;
  21272. $32 = (_stbir__get_total_horizontal_coefficients($0)|0);
  21273. $33 = $32 << 2;
  21274. $34 = ((($0)) + 192|0);
  21275. HEAP32[$34>>2] = $33;
  21276. $35 = HEAP32[$26>>2]|0;
  21277. $36 = $35 << 3;
  21278. $37 = ((($0)) + 196|0);
  21279. HEAP32[$37>>2] = $36;
  21280. $38 = (_stbir__get_total_vertical_coefficients($0)|0);
  21281. $39 = $38 << 2;
  21282. $40 = ((($0)) + 200|0);
  21283. HEAP32[$40>>2] = $39;
  21284. $41 = HEAP32[$13>>2]|0;
  21285. $42 = $5 << 1;
  21286. $43 = (($41) + ($42))|0;
  21287. $44 = ((($0)) + 64|0);
  21288. $45 = HEAP32[$44>>2]|0;
  21289. $46 = $45 << 2;
  21290. $47 = Math_imul($46, $43)|0;
  21291. $48 = ((($0)) + 204|0);
  21292. HEAP32[$48>>2] = $47;
  21293. $49 = HEAP32[$15>>2]|0;
  21294. $50 = $45 << 2;
  21295. $51 = Math_imul($50, $49)|0;
  21296. $52 = ((($0)) + 208|0);
  21297. HEAP32[$52>>2] = $51;
  21298. $53 = HEAP32[$44>>2]|0;
  21299. $54 = HEAP32[$28>>2]|0;
  21300. $55 = $49 << 2;
  21301. $56 = Math_imul($55, $53)|0;
  21302. $57 = Math_imul($56, $54)|0;
  21303. $58 = ((($0)) + 212|0);
  21304. HEAP32[$58>>2] = $57;
  21305. $59 = HEAP32[$15>>2]|0;
  21306. $60 = HEAP32[$44>>2]|0;
  21307. $61 = $59 << 2;
  21308. $62 = Math_imul($61, $60)|0;
  21309. $63 = ((($0)) + 216|0);
  21310. HEAP32[$63>>2] = $62;
  21311. $64 = HEAP32[$1>>2]|0;
  21312. $65 = ($64|0)==(0);
  21313. if ($65) {
  21314. ___assert_fail((14478|0),(12015|0),2260,(14507|0));
  21315. // unreachable;
  21316. }
  21317. $66 = ($64>>>0)<(6);
  21318. if (!($66)) {
  21319. ___assert_fail((12090|0),(12015|0),2261,(14507|0));
  21320. // unreachable;
  21321. }
  21322. $67 = HEAP32[$6>>2]|0;
  21323. $68 = ($67|0)==(0);
  21324. if ($68) {
  21325. ___assert_fail((14531|0),(12015|0),2262,(14507|0));
  21326. // unreachable;
  21327. }
  21328. $69 = ($67>>>0)<(6);
  21329. if ($69) {
  21330. $70 = (_stbir__use_height_upsampling($0)|0);
  21331. $71 = ($70|0)!=(0);
  21332. $$sink = $71 ? $52 : $63;
  21333. HEAP32[$$sink>>2] = 0;
  21334. $72 = HEAP32[$31>>2]|0;
  21335. $73 = HEAP32[$34>>2]|0;
  21336. $74 = (($73) + ($72))|0;
  21337. $75 = HEAP32[$37>>2]|0;
  21338. $76 = (($74) + ($75))|0;
  21339. $77 = HEAP32[$40>>2]|0;
  21340. $78 = (($76) + ($77))|0;
  21341. $79 = HEAP32[$48>>2]|0;
  21342. $80 = (($78) + ($79))|0;
  21343. $81 = HEAP32[$52>>2]|0;
  21344. $82 = (($80) + ($81))|0;
  21345. $83 = HEAP32[$58>>2]|0;
  21346. $84 = (($82) + ($83))|0;
  21347. $85 = HEAP32[$63>>2]|0;
  21348. $86 = (($84) + ($85))|0;
  21349. return ($86|0);
  21350. } else {
  21351. ___assert_fail((12191|0),(12015|0),2263,(14507|0));
  21352. // unreachable;
  21353. }
  21354. return (0)|0;
  21355. }
  21356. function _stbir__resize_allocated($0,$1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12) {
  21357. $0 = $0|0;
  21358. $1 = $1|0;
  21359. $2 = $2|0;
  21360. $3 = $3|0;
  21361. $4 = $4|0;
  21362. $5 = $5|0;
  21363. $6 = $6|0;
  21364. $7 = $7|0;
  21365. $8 = $8|0;
  21366. $9 = $9|0;
  21367. $10 = $10|0;
  21368. $11 = $11|0;
  21369. $12 = $12|0;
  21370. var $$ = 0, $$0 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0;
  21371. var $118 = 0, $119 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0;
  21372. var $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0.0, $153 = 0, $154 = 0.0;
  21373. var $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0.0, $161 = 0, $162 = 0.0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0;
  21374. var $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0;
  21375. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $60 = 0, $61 = 0;
  21376. var $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0.0, $68 = 0, $69 = 0, $70 = 0, $71 = 0, $72 = 0.0, $73 = 0, $74 = 0, $75 = 0, $76 = 0.0, $77 = 0, $78 = 0, $79 = 0, $80 = 0.0, $81 = 0;
  21377. var $82 = 0, $83 = 0, $84 = 0.0, $85 = 0, $86 = 0, $87 = 0, $88 = 0.0, $89 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $or$cond142 = 0, label = 0;
  21378. var sp = 0;
  21379. sp = STACKTOP;
  21380. $13 = (_stbir__calculate_memory($0)|0);
  21381. $14 = ($2|0)==(0);
  21382. if ($14) {
  21383. $15 = ((($0)) + 64|0);
  21384. $16 = HEAP32[$15>>2]|0;
  21385. $17 = ((($0)) + 4|0);
  21386. $18 = HEAP32[$17>>2]|0;
  21387. $19 = Math_imul($18, $16)|0;
  21388. $20 = (11991 + ($7)|0);
  21389. $21 = HEAP8[$20>>0]|0;
  21390. $22 = $21&255;
  21391. $23 = Math_imul($19, $22)|0;
  21392. $55 = $23;
  21393. } else {
  21394. $55 = $2;
  21395. }
  21396. $24 = ($4|0)==(0);
  21397. if ($24) {
  21398. $25 = ((($0)) + 64|0);
  21399. $26 = HEAP32[$25>>2]|0;
  21400. $27 = ((($0)) + 20|0);
  21401. $28 = HEAP32[$27>>2]|0;
  21402. $29 = Math_imul($28, $26)|0;
  21403. $30 = (11991 + ($7)|0);
  21404. $31 = HEAP8[$30>>0]|0;
  21405. $32 = $31&255;
  21406. $33 = Math_imul($29, $32)|0;
  21407. $58 = $33;
  21408. } else {
  21409. $58 = $4;
  21410. }
  21411. $34 = ((($0)) + 64|0);
  21412. $35 = HEAP32[$34>>2]|0;
  21413. $36 = ($35|0)>(-1);
  21414. if (!($36)) {
  21415. ___assert_fail((11995|0),(12015|0),2307,(12045|0));
  21416. // unreachable;
  21417. }
  21418. $37 = ($35|0)<(65);
  21419. if (!($37)) {
  21420. ___assert_fail((12069|0),(12015|0),2308,(12045|0));
  21421. // unreachable;
  21422. }
  21423. $38 = ((($0)) + 80|0);
  21424. $39 = HEAP32[$38>>2]|0;
  21425. $40 = ($39>>>0)<(6);
  21426. if (!($40)) {
  21427. ___assert_fail((12090|0),(12015|0),2313,(12045|0));
  21428. // unreachable;
  21429. }
  21430. $41 = ((($0)) + 84|0);
  21431. $42 = HEAP32[$41>>2]|0;
  21432. $43 = ($42>>>0)<(6);
  21433. if (!($43)) {
  21434. ___assert_fail((12191|0),(12015|0),2314,(12045|0));
  21435. // unreachable;
  21436. }
  21437. $44 = ($5|0)<(0);
  21438. $45 = $6 | 3;
  21439. $$ = $44 ? $45 : $6;
  21440. $46 = $$ & 3;
  21441. $47 = ($46|0)==(3);
  21442. if (!($47)) {
  21443. $48 = ($5|0)>(-1);
  21444. $49 = ($35|0)>($5|0);
  21445. $or$cond142 = $48 & $49;
  21446. if (!($or$cond142)) {
  21447. ___assert_fail((12290|0),(12015|0),2325,(12045|0));
  21448. // unreachable;
  21449. }
  21450. }
  21451. $50 = HEAP32[$34>>2]|0;
  21452. $51 = ($50|0)>($5|0);
  21453. if (!($51)) {
  21454. $$0 = 0;
  21455. return ($$0|0);
  21456. }
  21457. $52 = ($11|0)==(0|0);
  21458. if ($52) {
  21459. ___assert_fail((12343|0),(12015|0),2330,(12045|0));
  21460. // unreachable;
  21461. }
  21462. $53 = ($13>>>0)>($12>>>0);
  21463. if ($53) {
  21464. ___assert_fail((12351|0),(12015|0),2335,(12045|0));
  21465. // unreachable;
  21466. }
  21467. _memset(($11|0),0,($12|0))|0;
  21468. HEAP32[$0>>2] = $1;
  21469. $54 = ((($0)) + 12|0);
  21470. HEAP32[$54>>2] = $55;
  21471. $56 = ((($0)) + 16|0);
  21472. HEAP32[$56>>2] = $3;
  21473. $57 = ((($0)) + 28|0);
  21474. HEAP32[$57>>2] = $58;
  21475. $59 = ((($0)) + 68|0);
  21476. HEAP32[$59>>2] = $5;
  21477. $60 = ((($0)) + 72|0);
  21478. HEAP32[$60>>2] = $$;
  21479. $61 = ((($0)) + 76|0);
  21480. HEAP32[$61>>2] = $7;
  21481. $62 = ((($0)) + 88|0);
  21482. HEAP32[$62>>2] = $8;
  21483. $63 = ((($0)) + 92|0);
  21484. HEAP32[$63>>2] = $9;
  21485. $64 = ((($0)) + 96|0);
  21486. HEAP32[$64>>2] = $10;
  21487. $65 = HEAP32[$38>>2]|0;
  21488. $66 = ((($0)) + 56|0);
  21489. $67 = +HEAPF32[$66>>2];
  21490. $68 = (_stbir__get_coefficient_width($65,$67)|0);
  21491. $69 = ((($0)) + 128|0);
  21492. HEAP32[$69>>2] = $68;
  21493. $70 = HEAP32[$41>>2]|0;
  21494. $71 = ((($0)) + 60|0);
  21495. $72 = +HEAPF32[$71>>2];
  21496. $73 = (_stbir__get_coefficient_width($70,$72)|0);
  21497. $74 = ((($0)) + 132|0);
  21498. HEAP32[$74>>2] = $73;
  21499. $75 = HEAP32[$38>>2]|0;
  21500. $76 = +HEAPF32[$66>>2];
  21501. $77 = (_stbir__get_filter_pixel_width($75,$76)|0);
  21502. $78 = ((($0)) + 136|0);
  21503. HEAP32[$78>>2] = $77;
  21504. $79 = HEAP32[$41>>2]|0;
  21505. $80 = +HEAPF32[$71>>2];
  21506. $81 = (_stbir__get_filter_pixel_width($79,$80)|0);
  21507. $82 = ((($0)) + 140|0);
  21508. HEAP32[$82>>2] = $81;
  21509. $83 = HEAP32[$38>>2]|0;
  21510. $84 = +HEAPF32[$66>>2];
  21511. $85 = (_stbir__get_filter_pixel_margin($83,$84)|0);
  21512. $86 = ((($0)) + 144|0);
  21513. HEAP32[$86>>2] = $85;
  21514. $87 = HEAP32[$41>>2]|0;
  21515. $88 = +HEAPF32[$71>>2];
  21516. $89 = (_stbir__get_filter_pixel_margin($87,$88)|0);
  21517. $90 = ((($0)) + 148|0);
  21518. HEAP32[$90>>2] = $89;
  21519. $91 = ((($0)) + 20|0);
  21520. $92 = HEAP32[$91>>2]|0;
  21521. $93 = HEAP32[$34>>2]|0;
  21522. $94 = $92 << 2;
  21523. $95 = Math_imul($94, $93)|0;
  21524. $96 = ((($0)) + 160|0);
  21525. HEAP32[$96>>2] = $95;
  21526. $97 = ((($0)) + 4|0);
  21527. $98 = HEAP32[$97>>2]|0;
  21528. $99 = HEAP32[$86>>2]|0;
  21529. $100 = $99 << 1;
  21530. $101 = (($100) + ($98))|0;
  21531. $102 = ((($0)) + 116|0);
  21532. HEAP32[$102>>2] = $101;
  21533. $103 = ((($0)) + 100|0);
  21534. HEAP32[$103>>2] = $11;
  21535. $104 = ((($0)) + 188|0);
  21536. $105 = HEAP32[$104>>2]|0;
  21537. $106 = (($11) + ($105)|0);
  21538. $107 = ((($0)) + 104|0);
  21539. HEAP32[$107>>2] = $106;
  21540. $108 = ((($0)) + 192|0);
  21541. $109 = HEAP32[$108>>2]|0;
  21542. $110 = (($106) + ($109)|0);
  21543. $111 = ((($0)) + 108|0);
  21544. HEAP32[$111>>2] = $110;
  21545. $112 = ((($0)) + 196|0);
  21546. $113 = HEAP32[$112>>2]|0;
  21547. $114 = (($110) + ($113)|0);
  21548. $115 = ((($0)) + 112|0);
  21549. HEAP32[$115>>2] = $114;
  21550. $116 = ((($0)) + 200|0);
  21551. $117 = HEAP32[$116>>2]|0;
  21552. $118 = (($114) + ($117)|0);
  21553. $119 = ((($0)) + 120|0);
  21554. HEAP32[$119>>2] = $118;
  21555. $120 = (_stbir__use_height_upsampling($0)|0);
  21556. $121 = ($120|0)==(0);
  21557. $122 = $11;
  21558. $123 = ((($0)) + 204|0);
  21559. $124 = HEAP32[$123>>2]|0;
  21560. $125 = ((($0)) + 212|0);
  21561. $126 = HEAP32[$125>>2]|0;
  21562. $127 = (($122) + ($12))|0;
  21563. if ($121) {
  21564. $138 = (($118) + ($124)|0);
  21565. $139 = ((($0)) + 124|0);
  21566. HEAP32[$139>>2] = $138;
  21567. $140 = ((($0)) + 208|0);
  21568. $141 = HEAP32[$140>>2]|0;
  21569. $142 = (($138) + ($141)|0);
  21570. $143 = ((($0)) + 180|0);
  21571. HEAP32[$143>>2] = $142;
  21572. $144 = ((($0)) + 184|0);
  21573. HEAP32[$144>>2] = 0;
  21574. $145 = (($142) + ($126)|0);
  21575. $146 = $145;
  21576. $147 = ($146|0)==($127|0);
  21577. if (!($147)) {
  21578. ___assert_fail((12526|0),(12015|0),2387,(12045|0));
  21579. // unreachable;
  21580. }
  21581. } else {
  21582. $128 = ((($0)) + 124|0);
  21583. HEAP32[$128>>2] = 0;
  21584. $129 = (($118) + ($124)|0);
  21585. $130 = ((($0)) + 180|0);
  21586. HEAP32[$130>>2] = $129;
  21587. $131 = (($129) + ($126)|0);
  21588. $132 = ((($0)) + 184|0);
  21589. HEAP32[$132>>2] = $131;
  21590. $133 = ((($0)) + 216|0);
  21591. $134 = HEAP32[$133>>2]|0;
  21592. $135 = (($131) + ($134)|0);
  21593. $136 = $135;
  21594. $137 = ($136|0)==($127|0);
  21595. if (!($137)) {
  21596. ___assert_fail((12392|0),(12015|0),2379,(12045|0));
  21597. // unreachable;
  21598. }
  21599. }
  21600. $148 = ((($0)) + 176|0);
  21601. HEAP32[$148>>2] = -1;
  21602. $149 = HEAP32[$103>>2]|0;
  21603. $150 = HEAP32[$107>>2]|0;
  21604. $151 = HEAP32[$38>>2]|0;
  21605. $152 = +HEAPF32[$66>>2];
  21606. $153 = ((($0)) + 48|0);
  21607. $154 = +HEAPF32[$153>>2];
  21608. $155 = HEAP32[$97>>2]|0;
  21609. $156 = HEAP32[$91>>2]|0;
  21610. _stbir__calculate_filters($149,$150,$151,$152,$154,$155,$156);
  21611. $157 = HEAP32[$111>>2]|0;
  21612. $158 = HEAP32[$115>>2]|0;
  21613. $159 = HEAP32[$41>>2]|0;
  21614. $160 = +HEAPF32[$71>>2];
  21615. $161 = ((($0)) + 52|0);
  21616. $162 = +HEAPF32[$161>>2];
  21617. $163 = ((($0)) + 8|0);
  21618. $164 = HEAP32[$163>>2]|0;
  21619. $165 = ((($0)) + 24|0);
  21620. $166 = HEAP32[$165>>2]|0;
  21621. _stbir__calculate_filters($157,$158,$159,$160,$162,$164,$166);
  21622. $167 = (_stbir__use_height_upsampling($0)|0);
  21623. $168 = ($167|0)==(0);
  21624. if ($168) {
  21625. _stbir__buffer_loop_downsample($0);
  21626. $$0 = 1;
  21627. return ($$0|0);
  21628. } else {
  21629. _stbir__buffer_loop_upsample($0);
  21630. $$0 = 1;
  21631. return ($$0|0);
  21632. }
  21633. return (0)|0;
  21634. }
  21635. function _stbir__get_coefficient_width($0,$1) {
  21636. $0 = $0|0;
  21637. $1 = +$1;
  21638. var $$0 = 0, $$sink = 0.0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0.0, $7 = 0.0, $8 = 0.0, $ceilf = 0.0, label = 0, sp = 0;
  21639. sp = STACKTOP;
  21640. $2 = (_stbir__use_upsampling($1)|0);
  21641. $3 = ($2|0)==(0);
  21642. $4 = (((3104 + ($0<<3)|0)) + 4|0);
  21643. $5 = HEAP32[$4>>2]|0;
  21644. $6 = 1.0 / $1;
  21645. $$sink = $3 ? $1 : $6;
  21646. $7 = (+FUNCTION_TABLE_dd[$5 & 7]($$sink));
  21647. $8 = $7 * 2.0;
  21648. $ceilf = (+Math_ceil((+$8)));
  21649. $$0 = (~~(($ceilf)));
  21650. return ($$0|0);
  21651. }
  21652. function _stbir__get_filter_pixel_width($0,$1) {
  21653. $0 = $0|0;
  21654. $1 = +$1;
  21655. var $$0 = 0, $$sink = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0.0, $9 = 0.0, $ceilf = 0.0, label = 0, sp = 0;
  21656. sp = STACKTOP;
  21657. $2 = ($0|0)==(0);
  21658. if ($2) {
  21659. ___assert_fail((14352|0),(12015|0),879,(14364|0));
  21660. // unreachable;
  21661. }
  21662. $3 = ($0>>>0)<(6);
  21663. if (!($3)) {
  21664. ___assert_fail((14394|0),(12015|0),880,(14364|0));
  21665. // unreachable;
  21666. }
  21667. $4 = (_stbir__use_upsampling($1)|0);
  21668. $5 = ($4|0)==(0);
  21669. $6 = (((3104 + ($0<<3)|0)) + 4|0);
  21670. $7 = HEAP32[$6>>2]|0;
  21671. if ($5) {
  21672. $11 = (+FUNCTION_TABLE_dd[$7 & 7]($1));
  21673. $12 = $11 * 2.0;
  21674. $13 = $12 / $1;
  21675. $$sink = $13;
  21676. $ceilf = (+Math_ceil((+$$sink)));
  21677. $$0 = (~~(($ceilf)));
  21678. return ($$0|0);
  21679. } else {
  21680. $8 = 1.0 / $1;
  21681. $9 = (+FUNCTION_TABLE_dd[$7 & 7]($8));
  21682. $10 = $9 * 2.0;
  21683. $$sink = $10;
  21684. $ceilf = (+Math_ceil((+$$sink)));
  21685. $$0 = (~~(($ceilf)));
  21686. return ($$0|0);
  21687. }
  21688. return (0)|0;
  21689. }
  21690. function _stbir__get_filter_pixel_margin($0,$1) {
  21691. $0 = $0|0;
  21692. $1 = +$1;
  21693. var $2 = 0, $3 = 0, label = 0, sp = 0;
  21694. sp = STACKTOP;
  21695. $2 = (_stbir__get_filter_pixel_width($0,$1)|0);
  21696. $3 = (($2|0) / 2)&-1;
  21697. return ($3|0);
  21698. }
  21699. function _stbir__use_height_upsampling($0) {
  21700. $0 = $0|0;
  21701. var $1 = 0, $2 = 0.0, $3 = 0, label = 0, sp = 0;
  21702. sp = STACKTOP;
  21703. $1 = ((($0)) + 60|0);
  21704. $2 = +HEAPF32[$1>>2];
  21705. $3 = (_stbir__use_upsampling($2)|0);
  21706. return ($3|0);
  21707. }
  21708. function _stbir__calculate_filters($0,$1,$2,$3,$4,$5,$6) {
  21709. $0 = $0|0;
  21710. $1 = $1|0;
  21711. $2 = $2|0;
  21712. $3 = +$3;
  21713. $4 = +$4;
  21714. $5 = $5|0;
  21715. $6 = $6|0;
  21716. var $$059 = 0, $$158 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0.0, $16 = 0.0, $17 = 0.0, $18 = 0, $19 = 0, $20 = 0, $21 = 0.0, $22 = 0, $23 = 0, $24 = 0, $25 = 0.0, $26 = 0.0, $27 = 0;
  21717. var $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0.0, $33 = 0, $34 = 0, $35 = 0, $7 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond62 = 0, label = 0, sp = 0;
  21718. sp = STACKTOP;
  21719. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  21720. $7 = sp + 8|0;
  21721. $8 = sp + 4|0;
  21722. $9 = sp;
  21723. $10 = (_stbir__get_contributors($3,$2,$5,$6)|0);
  21724. $11 = (_stbir__use_upsampling($3)|0);
  21725. $12 = ($11|0)==(0);
  21726. $13 = (((3104 + ($2<<3)|0)) + 4|0);
  21727. $14 = HEAP32[$13>>2]|0;
  21728. if ($12) {
  21729. $25 = (+FUNCTION_TABLE_dd[$14 & 7]($3));
  21730. $26 = $25 / $3;
  21731. $27 = ($10|0)>(0);
  21732. if ($27) {
  21733. $$158 = 0;
  21734. while(1) {
  21735. $28 = (_stbir__get_filter_pixel_margin($2,$3)|0);
  21736. $29 = (($$158) - ($28))|0;
  21737. _stbir__calculate_sample_range_downsample($29,$26,$3,$4,$8,$9,$7);
  21738. $30 = HEAP32[$8>>2]|0;
  21739. $31 = HEAP32[$9>>2]|0;
  21740. $32 = +HEAPF32[$7>>2];
  21741. $33 = (_stbir__get_contributor($0,$$158)|0);
  21742. $34 = (_stbir__get_coefficient($1,$2,$3,$$158,0)|0);
  21743. _stbir__calculate_coefficients_downsample($2,$3,$30,$31,$32,$33,$34);
  21744. $35 = (($$158) + 1)|0;
  21745. $exitcond = ($35|0)==($10|0);
  21746. if ($exitcond) {
  21747. break;
  21748. } else {
  21749. $$158 = $35;
  21750. }
  21751. }
  21752. }
  21753. _stbir__normalize_downsample_coefficients($0,$1,$2,$3,$5,$6);
  21754. STACKTOP = sp;return;
  21755. } else {
  21756. $15 = 1.0 / $3;
  21757. $16 = (+FUNCTION_TABLE_dd[$14 & 7]($15));
  21758. $17 = $16 * $3;
  21759. $18 = ($10|0)>(0);
  21760. if (!($18)) {
  21761. STACKTOP = sp;return;
  21762. }
  21763. $$059 = 0;
  21764. while(1) {
  21765. _stbir__calculate_sample_range_upsample($$059,$17,$3,$4,$8,$9,$7);
  21766. $19 = HEAP32[$8>>2]|0;
  21767. $20 = HEAP32[$9>>2]|0;
  21768. $21 = +HEAPF32[$7>>2];
  21769. $22 = (_stbir__get_contributor($0,$$059)|0);
  21770. $23 = (_stbir__get_coefficient($1,$2,$3,$$059,0)|0);
  21771. _stbir__calculate_coefficients_upsample($2,$3,$19,$20,$21,$22,$23);
  21772. $24 = (($$059) + 1)|0;
  21773. $exitcond62 = ($24|0)==($10|0);
  21774. if ($exitcond62) {
  21775. break;
  21776. } else {
  21777. $$059 = $24;
  21778. }
  21779. }
  21780. STACKTOP = sp;return;
  21781. }
  21782. }
  21783. function _stbir__buffer_loop_upsample($0) {
  21784. $0 = $0|0;
  21785. var $$038 = 0, $$pr = 0, $$pr$pr = 0, $1 = 0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0.0;
  21786. var $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0;
  21787. var $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0.0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  21788. var label = 0, sp = 0;
  21789. sp = STACKTOP;
  21790. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  21791. $1 = sp + 8|0;
  21792. $2 = sp + 4|0;
  21793. $3 = sp;
  21794. $4 = ((($0)) + 60|0);
  21795. $5 = +HEAPF32[$4>>2];
  21796. $6 = ((($0)) + 84|0);
  21797. $7 = HEAP32[$6>>2]|0;
  21798. $8 = (((3104 + ($7<<3)|0)) + 4|0);
  21799. $9 = HEAP32[$8>>2]|0;
  21800. $10 = 1.0 / $5;
  21801. $11 = (+FUNCTION_TABLE_dd[$9 & 7]($10));
  21802. $12 = $5 * $11;
  21803. $13 = (_stbir__use_height_upsampling($0)|0);
  21804. $14 = ($13|0)==(0);
  21805. if ($14) {
  21806. ___assert_fail((13523|0),(12015|0),2064,(13564|0));
  21807. // unreachable;
  21808. }
  21809. $15 = ((($0)) + 24|0);
  21810. $16 = HEAP32[$15>>2]|0;
  21811. $17 = ($16|0)>(0);
  21812. if (!($17)) {
  21813. STACKTOP = sp;return;
  21814. }
  21815. $18 = ((($0)) + 52|0);
  21816. $19 = ((($0)) + 164|0);
  21817. $20 = ((($0)) + 176|0);
  21818. $21 = ((($0)) + 172|0);
  21819. $22 = ((($0)) + 168|0);
  21820. $23 = ((($0)) + 172|0);
  21821. $$038 = 0;
  21822. while(1) {
  21823. HEAPF32[$1>>2] = 0.0;
  21824. HEAP32[$2>>2] = 0;
  21825. HEAP32[$3>>2] = 0;
  21826. $24 = +HEAPF32[$18>>2];
  21827. _stbir__calculate_sample_range_upsample($$038,$12,$5,$24,$2,$3,$1);
  21828. $25 = HEAP32[$3>>2]|0;
  21829. $26 = HEAP32[$2>>2]|0;
  21830. $27 = (($25) - ($26))|0;
  21831. $28 = HEAP32[$19>>2]|0;
  21832. $29 = ($27|0)<($28|0);
  21833. if (!($29)) {
  21834. label = 6;
  21835. break;
  21836. }
  21837. $30 = HEAP32[$20>>2]|0;
  21838. $31 = ($30|0)>(-1);
  21839. if ($31) {
  21840. $32 = HEAP32[$2>>2]|0;
  21841. $33 = HEAP32[$22>>2]|0;
  21842. $34 = ($32|0)>($33|0);
  21843. L12: do {
  21844. if ($34) {
  21845. $35 = HEAP32[$23>>2]|0;
  21846. $36 = HEAP32[$2>>2]|0;
  21847. $38 = $33;
  21848. while(1) {
  21849. $37 = ($38|0)==($35|0);
  21850. if ($37) {
  21851. break;
  21852. }
  21853. $39 = (($38) + 1)|0;
  21854. HEAP32[$22>>2] = $39;
  21855. $40 = HEAP32[$20>>2]|0;
  21856. $41 = (($40) + 1)|0;
  21857. $42 = HEAP32[$19>>2]|0;
  21858. $43 = (($41|0) % ($42|0))&-1;
  21859. HEAP32[$20>>2] = $43;
  21860. $44 = ($36|0)>($39|0);
  21861. if ($44) {
  21862. $38 = $39;
  21863. } else {
  21864. $$pr = $43;
  21865. break L12;
  21866. }
  21867. }
  21868. HEAP32[$20>>2] = -1;
  21869. HEAP32[$22>>2] = 0;
  21870. HEAP32[$23>>2] = 0;
  21871. label = 13;
  21872. } else {
  21873. label = 13;
  21874. }
  21875. } while(0);
  21876. if ((label|0) == 13) {
  21877. label = 0;
  21878. $$pr$pr = HEAP32[$20>>2]|0;
  21879. $$pr = $$pr$pr;
  21880. }
  21881. $45 = ($$pr|0)<(0);
  21882. if ($45) {
  21883. label = 15;
  21884. }
  21885. } else {
  21886. label = 15;
  21887. }
  21888. if ((label|0) == 15) {
  21889. label = 0;
  21890. $46 = HEAP32[$2>>2]|0;
  21891. _stbir__decode_and_resample_upsample($0,$46);
  21892. }
  21893. $47 = HEAP32[$3>>2]|0;
  21894. $48 = HEAP32[$21>>2]|0;
  21895. $49 = ($47|0)>($48|0);
  21896. if ($49) {
  21897. $50 = HEAP32[$3>>2]|0;
  21898. $52 = $48;
  21899. while(1) {
  21900. $51 = (($52) + 1)|0;
  21901. _stbir__decode_and_resample_upsample($0,$51);
  21902. $53 = HEAP32[$21>>2]|0;
  21903. $54 = ($50|0)>($53|0);
  21904. if ($54) {
  21905. $52 = $53;
  21906. } else {
  21907. break;
  21908. }
  21909. }
  21910. }
  21911. _stbir__resample_vertical_upsample($0,$$038);
  21912. $55 = (($$038) + 1)|0;
  21913. $56 = HEAP32[$15>>2]|0;
  21914. $57 = ($55|0)<($56|0);
  21915. if ($57) {
  21916. $$038 = $55;
  21917. } else {
  21918. label = 20;
  21919. break;
  21920. }
  21921. }
  21922. if ((label|0) == 6) {
  21923. ___assert_fail((13592|0),(12015|0),2073,(13564|0));
  21924. // unreachable;
  21925. }
  21926. else if ((label|0) == 20) {
  21927. STACKTOP = sp;return;
  21928. }
  21929. }
  21930. function _stbir__buffer_loop_downsample($0) {
  21931. $0 = $0|0;
  21932. var $$04142 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0.0, $13 = 0.0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  21933. var $27 = 0.0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  21934. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $5 = 0.0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, label = 0, sp = 0;
  21935. sp = STACKTOP;
  21936. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  21937. $1 = sp + 8|0;
  21938. $2 = sp + 4|0;
  21939. $3 = sp;
  21940. $4 = ((($0)) + 60|0);
  21941. $5 = +HEAPF32[$4>>2];
  21942. $6 = ((($0)) + 24|0);
  21943. $7 = HEAP32[$6>>2]|0;
  21944. $8 = ((($0)) + 84|0);
  21945. $9 = HEAP32[$8>>2]|0;
  21946. $10 = (((3104 + ($9<<3)|0)) + 4|0);
  21947. $11 = HEAP32[$10>>2]|0;
  21948. $12 = (+FUNCTION_TABLE_dd[$11 & 7]($5));
  21949. $13 = $12 / $5;
  21950. $14 = ((($0)) + 148|0);
  21951. $15 = HEAP32[$14>>2]|0;
  21952. $16 = ((($0)) + 8|0);
  21953. $17 = HEAP32[$16>>2]|0;
  21954. $18 = (($17) + ($15))|0;
  21955. $19 = (_stbir__use_height_upsampling($0)|0);
  21956. $20 = ($19|0)==(0);
  21957. if (!($20)) {
  21958. ___assert_fail((12656|0),(12015|0),2165,(12698|0));
  21959. // unreachable;
  21960. }
  21961. $21 = (0 - ($15))|0;
  21962. $22 = ($18|0)>($21|0);
  21963. if (!($22)) {
  21964. $48 = HEAP32[$6>>2]|0;
  21965. _stbir__empty_ring_buffer($0,$48);
  21966. STACKTOP = sp;return;
  21967. }
  21968. $23 = ((($0)) + 52|0);
  21969. $24 = ((($0)) + 164|0);
  21970. $25 = ((($0)) + 176|0);
  21971. $26 = ((($0)) + 172|0);
  21972. $$04142 = $21;
  21973. while(1) {
  21974. $27 = +HEAPF32[$23>>2];
  21975. _stbir__calculate_sample_range_downsample($$04142,$13,$5,$27,$2,$3,$1);
  21976. $28 = HEAP32[$3>>2]|0;
  21977. $29 = HEAP32[$2>>2]|0;
  21978. $30 = (($28) - ($29))|0;
  21979. $31 = HEAP32[$24>>2]|0;
  21980. $32 = ($30|0)<($31|0);
  21981. if (!($32)) {
  21982. label = 6;
  21983. break;
  21984. }
  21985. $33 = ($28|0)>(-1);
  21986. $34 = ($29|0)<($7|0);
  21987. $or$cond = $33 & $34;
  21988. if ($or$cond) {
  21989. _stbir__empty_ring_buffer($0,$29);
  21990. _stbir__decode_and_resample_downsample($0,$$04142);
  21991. $35 = HEAP32[$25>>2]|0;
  21992. $36 = ($35|0)<(0);
  21993. if ($36) {
  21994. $37 = HEAP32[$2>>2]|0;
  21995. (_stbir__add_empty_ring_buffer_entry($0,$37)|0);
  21996. }
  21997. $38 = HEAP32[$3>>2]|0;
  21998. $39 = HEAP32[$26>>2]|0;
  21999. $40 = ($38|0)>($39|0);
  22000. if ($40) {
  22001. $41 = HEAP32[$3>>2]|0;
  22002. $43 = $39;
  22003. while(1) {
  22004. $42 = (($43) + 1)|0;
  22005. (_stbir__add_empty_ring_buffer_entry($0,$42)|0);
  22006. $44 = HEAP32[$26>>2]|0;
  22007. $45 = ($41|0)>($44|0);
  22008. if ($45) {
  22009. $43 = $44;
  22010. } else {
  22011. break;
  22012. }
  22013. }
  22014. }
  22015. _stbir__resample_vertical_downsample($0,$$04142);
  22016. }
  22017. $46 = (($$04142) + 1)|0;
  22018. $47 = ($46|0)<($18|0);
  22019. if ($47) {
  22020. $$04142 = $46;
  22021. } else {
  22022. label = 15;
  22023. break;
  22024. }
  22025. }
  22026. if ((label|0) == 6) {
  22027. ___assert_fail((12728|0),(12015|0),2174,(12698|0));
  22028. // unreachable;
  22029. }
  22030. else if ((label|0) == 15) {
  22031. $48 = HEAP32[$6>>2]|0;
  22032. _stbir__empty_ring_buffer($0,$48);
  22033. STACKTOP = sp;return;
  22034. }
  22035. }
  22036. function _stbir__calculate_sample_range_downsample($0,$1,$2,$3,$4,$5,$6) {
  22037. $0 = $0|0;
  22038. $1 = +$1;
  22039. $2 = +$2;
  22040. $3 = +$3;
  22041. $4 = $4|0;
  22042. $5 = $5|0;
  22043. $6 = $6|0;
  22044. var $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $14 = 0.0, $15 = 0.0, $16 = 0.0, $17 = 0.0, $18 = 0.0, $19 = 0.0, $20 = 0, $21 = 0.0, $22 = 0.0, $23 = 0.0, $24 = 0, $7 = 0.0, $8 = 0.0, $9 = 0.0, label = 0, sp = 0;
  22045. sp = STACKTOP;
  22046. $7 = (+($0|0));
  22047. $8 = $7 + 0.5;
  22048. $9 = $8 - $1;
  22049. $10 = $8 + $1;
  22050. $11 = $9 * $2;
  22051. $12 = $11 - $3;
  22052. $13 = $10 * $2;
  22053. $14 = $13 - $3;
  22054. $15 = $8 * $2;
  22055. $16 = $15 - $3;
  22056. HEAPF32[$6>>2] = $16;
  22057. $17 = $12;
  22058. $18 = $17 + 0.5;
  22059. $19 = (+Math_floor((+$18)));
  22060. $20 = (~~(($19)));
  22061. HEAP32[$4>>2] = $20;
  22062. $21 = $14;
  22063. $22 = $21 + -0.5;
  22064. $23 = (+Math_floor((+$22)));
  22065. $24 = (~~(($23)));
  22066. HEAP32[$5>>2] = $24;
  22067. return;
  22068. }
  22069. function _stbir__empty_ring_buffer($0,$1) {
  22070. $0 = $0|0;
  22071. $1 = $1|0;
  22072. var $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0;
  22073. var $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0;
  22074. var $47 = 0, $48 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  22075. sp = STACKTOP;
  22076. $2 = ((($0)) + 28|0);
  22077. $3 = HEAP32[$2>>2]|0;
  22078. $4 = ((($0)) + 64|0);
  22079. $5 = HEAP32[$4>>2]|0;
  22080. $6 = ((($0)) + 68|0);
  22081. $7 = HEAP32[$6>>2]|0;
  22082. $8 = ((($0)) + 76|0);
  22083. $9 = HEAP32[$8>>2]|0;
  22084. $10 = ((($0)) + 96|0);
  22085. $11 = HEAP32[$10>>2]|0;
  22086. $12 = ((($0)) + 20|0);
  22087. $13 = HEAP32[$12>>2]|0;
  22088. $14 = ((($0)) + 16|0);
  22089. $15 = HEAP32[$14>>2]|0;
  22090. $16 = $9 << 1;
  22091. $17 = (($16) + ($11))|0;
  22092. $18 = ((($0)) + 180|0);
  22093. $19 = HEAP32[$18>>2]|0;
  22094. $20 = ((($0)) + 160|0);
  22095. $21 = HEAP32[$20>>2]|0;
  22096. $22 = $21 >>> 2;
  22097. $23 = ((($0)) + 176|0);
  22098. $24 = HEAP32[$23>>2]|0;
  22099. $25 = ($24|0)>(-1);
  22100. if (!($25)) {
  22101. return;
  22102. }
  22103. $26 = ((($0)) + 168|0);
  22104. $27 = HEAP32[$26>>2]|0;
  22105. $28 = ($27|0)<($1|0);
  22106. if (!($28)) {
  22107. return;
  22108. }
  22109. $29 = ((($0)) + 24|0);
  22110. $30 = ((($0)) + 172|0);
  22111. $31 = ((($0)) + 164|0);
  22112. $33 = $27;
  22113. while(1) {
  22114. $32 = ($33|0)>(-1);
  22115. if ($32) {
  22116. $34 = HEAP32[$29>>2]|0;
  22117. $35 = ($33|0)<($34|0);
  22118. if ($35) {
  22119. $36 = Math_imul($33, $3)|0;
  22120. $37 = (($15) + ($36)|0);
  22121. $38 = HEAP32[$23>>2]|0;
  22122. $39 = (_stbir__get_ring_buffer_entry($19,$38,$22)|0);
  22123. _stbir__encode_scanline($0,$13,$37,$39,$5,$7,$17);
  22124. }
  22125. }
  22126. $40 = HEAP32[$26>>2]|0;
  22127. $41 = HEAP32[$30>>2]|0;
  22128. $42 = ($40|0)==($41|0);
  22129. if ($42) {
  22130. break;
  22131. }
  22132. $43 = (($40) + 1)|0;
  22133. HEAP32[$26>>2] = $43;
  22134. $44 = HEAP32[$23>>2]|0;
  22135. $45 = (($44) + 1)|0;
  22136. $46 = HEAP32[$31>>2]|0;
  22137. $47 = (($45|0) % ($46|0))&-1;
  22138. HEAP32[$23>>2] = $47;
  22139. $48 = ($43|0)<($1|0);
  22140. if ($48) {
  22141. $33 = $43;
  22142. } else {
  22143. label = 10;
  22144. break;
  22145. }
  22146. }
  22147. if ((label|0) == 10) {
  22148. return;
  22149. }
  22150. HEAP32[$23>>2] = -1;
  22151. HEAP32[$26>>2] = 0;
  22152. HEAP32[$30>>2] = 0;
  22153. return;
  22154. }
  22155. function _stbir__decode_and_resample_downsample($0,$1) {
  22156. $0 = $0|0;
  22157. $1 = $1|0;
  22158. var $10 = 0, $11 = 0, $12 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  22159. sp = STACKTOP;
  22160. _stbir__decode_scanline($0,$1);
  22161. $2 = ((($0)) + 124|0);
  22162. $3 = HEAP32[$2>>2]|0;
  22163. $4 = ((($0)) + 20|0);
  22164. $5 = HEAP32[$4>>2]|0;
  22165. $6 = ((($0)) + 64|0);
  22166. $7 = HEAP32[$6>>2]|0;
  22167. $8 = $5 << 2;
  22168. $9 = Math_imul($8, $7)|0;
  22169. _memset(($3|0),0,($9|0))|0;
  22170. $10 = (_stbir__use_width_upsampling($0)|0);
  22171. $11 = ($10|0)==(0);
  22172. $12 = HEAP32[$2>>2]|0;
  22173. if ($11) {
  22174. _stbir__resample_horizontal_downsample($0,$12);
  22175. return;
  22176. } else {
  22177. _stbir__resample_horizontal_upsample($0,$12);
  22178. return;
  22179. }
  22180. }
  22181. function _stbir__add_empty_ring_buffer_entry($0,$1) {
  22182. $0 = $0|0;
  22183. $1 = $1|0;
  22184. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  22185. var label = 0, sp = 0;
  22186. sp = STACKTOP;
  22187. $2 = ((($0)) + 172|0);
  22188. HEAP32[$2>>2] = $1;
  22189. $3 = ((($0)) + 176|0);
  22190. $4 = HEAP32[$3>>2]|0;
  22191. $5 = ($4|0)<(0);
  22192. if ($5) {
  22193. HEAP32[$3>>2] = 0;
  22194. $6 = ((($0)) + 168|0);
  22195. HEAP32[$6>>2] = $1;
  22196. $$0 = 0;
  22197. } else {
  22198. $7 = ((($0)) + 168|0);
  22199. $8 = HEAP32[$7>>2]|0;
  22200. $9 = (($4) + ($1))|0;
  22201. $10 = (($9) - ($8))|0;
  22202. $11 = ((($0)) + 164|0);
  22203. $12 = HEAP32[$11>>2]|0;
  22204. $13 = (($10|0) % ($12|0))&-1;
  22205. $14 = ($13|0)==($4|0);
  22206. if ($14) {
  22207. ___assert_fail((12846|0),(12015|0),1426,(12903|0));
  22208. // unreachable;
  22209. } else {
  22210. $$0 = $13;
  22211. }
  22212. }
  22213. $15 = ((($0)) + 180|0);
  22214. $16 = HEAP32[$15>>2]|0;
  22215. $17 = ((($0)) + 160|0);
  22216. $18 = HEAP32[$17>>2]|0;
  22217. $19 = $18 >>> 2;
  22218. $20 = (_stbir__get_ring_buffer_entry($16,$$0,$19)|0);
  22219. _memset(($20|0),0,($18|0))|0;
  22220. return ($20|0);
  22221. }
  22222. function _stbir__resample_vertical_downsample($0,$1) {
  22223. $0 = $0|0;
  22224. $1 = $1|0;
  22225. var $$0167183 = 0, $$0168189 = 0, $$0185 = 0, $$1181 = 0, $$2179 = 0, $$3178 = 0, $$4187 = 0, $10 = 0, $100 = 0.0, $101 = 0.0, $102 = 0, $103 = 0.0, $104 = 0.0, $105 = 0, $106 = 0, $107 = 0.0, $108 = 0.0, $109 = 0, $11 = 0, $110 = 0.0;
  22226. var $111 = 0.0, $112 = 0, $113 = 0, $114 = 0.0, $115 = 0.0, $116 = 0, $117 = 0.0, $118 = 0.0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0.0, $124 = 0.0, $125 = 0, $126 = 0.0, $127 = 0.0, $128 = 0, $129 = 0;
  22227. var $13 = 0, $130 = 0, $131 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0;
  22228. var $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0.0, $46 = 0, $47 = 0;
  22229. var $48 = 0.0, $49 = 0.0, $5 = 0, $50 = 0, $51 = 0.0, $52 = 0.0, $53 = 0, $54 = 0, $55 = 0, $56 = 0.0, $57 = 0.0, $58 = 0, $59 = 0.0, $6 = 0, $60 = 0.0, $61 = 0, $62 = 0, $63 = 0.0, $64 = 0.0, $65 = 0;
  22230. var $66 = 0.0, $67 = 0.0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0.0, $72 = 0.0, $73 = 0, $74 = 0.0, $75 = 0.0, $76 = 0, $77 = 0, $78 = 0.0, $79 = 0.0, $8 = 0, $80 = 0, $81 = 0.0, $82 = 0.0, $83 = 0;
  22231. var $84 = 0, $85 = 0.0, $86 = 0.0, $87 = 0, $88 = 0.0, $89 = 0.0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0.0, $94 = 0.0, $95 = 0, $96 = 0.0, $97 = 0.0, $98 = 0, $99 = 0, $exitcond = 0, $exitcond196 = 0, $exitcond197 = 0;
  22232. var $exitcond198 = 0, $exitcond199 = 0, $exitcond200 = 0, label = 0, sp = 0;
  22233. sp = STACKTOP;
  22234. $2 = ((($0)) + 20|0);
  22235. $3 = HEAP32[$2>>2]|0;
  22236. $4 = ((($0)) + 108|0);
  22237. $5 = HEAP32[$4>>2]|0;
  22238. $6 = ((($0)) + 112|0);
  22239. $7 = HEAP32[$6>>2]|0;
  22240. $8 = ((($0)) + 64|0);
  22241. $9 = HEAP32[$8>>2]|0;
  22242. $10 = ((($0)) + 164|0);
  22243. $11 = HEAP32[$10>>2]|0;
  22244. $12 = ((($0)) + 124|0);
  22245. $13 = HEAP32[$12>>2]|0;
  22246. $14 = ((($0)) + 132|0);
  22247. $15 = HEAP32[$14>>2]|0;
  22248. $16 = ((($0)) + 148|0);
  22249. $17 = HEAP32[$16>>2]|0;
  22250. $18 = (($17) + ($1))|0;
  22251. $19 = ((($0)) + 180|0);
  22252. $20 = HEAP32[$19>>2]|0;
  22253. $21 = ((($0)) + 176|0);
  22254. $22 = HEAP32[$21>>2]|0;
  22255. $23 = ((($0)) + 168|0);
  22256. $24 = HEAP32[$23>>2]|0;
  22257. $25 = ((($0)) + 160|0);
  22258. $26 = HEAP32[$25>>2]|0;
  22259. $27 = $26 >>> 2;
  22260. $28 = (($5) + ($18<<3)|0);
  22261. $29 = HEAP32[$28>>2]|0;
  22262. $30 = (((($5) + ($18<<3)|0)) + 4|0);
  22263. $31 = HEAP32[$30>>2]|0;
  22264. $32 = (_stbir__use_height_upsampling($0)|0);
  22265. $33 = ($32|0)==(0);
  22266. if (!($33)) {
  22267. ___assert_fail((12656|0),(12015|0),1999,(12810|0));
  22268. // unreachable;
  22269. }
  22270. $34 = ($29|0)>($31|0);
  22271. if ($34) {
  22272. return;
  22273. }
  22274. $35 = Math_imul($18, $15)|0;
  22275. $36 = (($35) - ($29))|0;
  22276. $37 = ($3|0)>(0);
  22277. $38 = ($9|0)>(0);
  22278. $39 = ($3|0)>(0);
  22279. $40 = ($3|0)>(0);
  22280. $41 = ($3|0)>(0);
  22281. $42 = ($3|0)>(0);
  22282. $$0168189 = $29;
  22283. while(1) {
  22284. $43 = (($36) + ($$0168189))|0;
  22285. $44 = (($7) + ($43<<2)|0);
  22286. $45 = +HEAPF32[$44>>2];
  22287. $46 = (_stbir__get_ring_buffer_scanline($$0168189,$20,$22,$24,$11,$27)|0);
  22288. switch ($9|0) {
  22289. case 1: {
  22290. if ($39) {
  22291. $$0167183 = 0;
  22292. while(1) {
  22293. $47 = (($13) + ($$0167183<<2)|0);
  22294. $48 = +HEAPF32[$47>>2];
  22295. $49 = $45 * $48;
  22296. $50 = (($46) + ($$0167183<<2)|0);
  22297. $51 = +HEAPF32[$50>>2];
  22298. $52 = $51 + $49;
  22299. HEAPF32[$50>>2] = $52;
  22300. $53 = (($$0167183) + 1)|0;
  22301. $exitcond198 = ($53|0)==($3|0);
  22302. if ($exitcond198) {
  22303. break;
  22304. } else {
  22305. $$0167183 = $53;
  22306. }
  22307. }
  22308. }
  22309. break;
  22310. }
  22311. case 2: {
  22312. if ($40) {
  22313. $$1181 = 0;
  22314. while(1) {
  22315. $54 = $$1181 << 1;
  22316. $55 = (($13) + ($54<<2)|0);
  22317. $56 = +HEAPF32[$55>>2];
  22318. $57 = $45 * $56;
  22319. $58 = (($46) + ($54<<2)|0);
  22320. $59 = +HEAPF32[$58>>2];
  22321. $60 = $59 + $57;
  22322. HEAPF32[$58>>2] = $60;
  22323. $61 = $54 | 1;
  22324. $62 = (($13) + ($61<<2)|0);
  22325. $63 = +HEAPF32[$62>>2];
  22326. $64 = $45 * $63;
  22327. $65 = (($46) + ($61<<2)|0);
  22328. $66 = +HEAPF32[$65>>2];
  22329. $67 = $66 + $64;
  22330. HEAPF32[$65>>2] = $67;
  22331. $68 = (($$1181) + 1)|0;
  22332. $exitcond197 = ($68|0)==($3|0);
  22333. if ($exitcond197) {
  22334. break;
  22335. } else {
  22336. $$1181 = $68;
  22337. }
  22338. }
  22339. }
  22340. break;
  22341. }
  22342. case 3: {
  22343. if ($41) {
  22344. $$2179 = 0;
  22345. while(1) {
  22346. $69 = ($$2179*3)|0;
  22347. $70 = (($13) + ($69<<2)|0);
  22348. $71 = +HEAPF32[$70>>2];
  22349. $72 = $45 * $71;
  22350. $73 = (($46) + ($69<<2)|0);
  22351. $74 = +HEAPF32[$73>>2];
  22352. $75 = $74 + $72;
  22353. HEAPF32[$73>>2] = $75;
  22354. $76 = (($69) + 1)|0;
  22355. $77 = (($13) + ($76<<2)|0);
  22356. $78 = +HEAPF32[$77>>2];
  22357. $79 = $45 * $78;
  22358. $80 = (($46) + ($76<<2)|0);
  22359. $81 = +HEAPF32[$80>>2];
  22360. $82 = $81 + $79;
  22361. HEAPF32[$80>>2] = $82;
  22362. $83 = (($69) + 2)|0;
  22363. $84 = (($13) + ($83<<2)|0);
  22364. $85 = +HEAPF32[$84>>2];
  22365. $86 = $45 * $85;
  22366. $87 = (($46) + ($83<<2)|0);
  22367. $88 = +HEAPF32[$87>>2];
  22368. $89 = $88 + $86;
  22369. HEAPF32[$87>>2] = $89;
  22370. $90 = (($$2179) + 1)|0;
  22371. $exitcond196 = ($90|0)==($3|0);
  22372. if ($exitcond196) {
  22373. break;
  22374. } else {
  22375. $$2179 = $90;
  22376. }
  22377. }
  22378. }
  22379. break;
  22380. }
  22381. case 4: {
  22382. if ($42) {
  22383. $$3178 = 0;
  22384. while(1) {
  22385. $91 = $$3178 << 2;
  22386. $92 = (($13) + ($91<<2)|0);
  22387. $93 = +HEAPF32[$92>>2];
  22388. $94 = $45 * $93;
  22389. $95 = (($46) + ($91<<2)|0);
  22390. $96 = +HEAPF32[$95>>2];
  22391. $97 = $96 + $94;
  22392. HEAPF32[$95>>2] = $97;
  22393. $98 = $91 | 1;
  22394. $99 = (($13) + ($98<<2)|0);
  22395. $100 = +HEAPF32[$99>>2];
  22396. $101 = $45 * $100;
  22397. $102 = (($46) + ($98<<2)|0);
  22398. $103 = +HEAPF32[$102>>2];
  22399. $104 = $103 + $101;
  22400. HEAPF32[$102>>2] = $104;
  22401. $105 = $91 | 2;
  22402. $106 = (($13) + ($105<<2)|0);
  22403. $107 = +HEAPF32[$106>>2];
  22404. $108 = $45 * $107;
  22405. $109 = (($46) + ($105<<2)|0);
  22406. $110 = +HEAPF32[$109>>2];
  22407. $111 = $110 + $108;
  22408. HEAPF32[$109>>2] = $111;
  22409. $112 = $91 | 3;
  22410. $113 = (($13) + ($112<<2)|0);
  22411. $114 = +HEAPF32[$113>>2];
  22412. $115 = $45 * $114;
  22413. $116 = (($46) + ($112<<2)|0);
  22414. $117 = +HEAPF32[$116>>2];
  22415. $118 = $117 + $115;
  22416. HEAPF32[$116>>2] = $118;
  22417. $119 = (($$3178) + 1)|0;
  22418. $exitcond = ($119|0)==($3|0);
  22419. if ($exitcond) {
  22420. break;
  22421. } else {
  22422. $$3178 = $119;
  22423. }
  22424. }
  22425. }
  22426. break;
  22427. }
  22428. default: {
  22429. if ($37) {
  22430. $$4187 = 0;
  22431. while(1) {
  22432. $120 = Math_imul($$4187, $9)|0;
  22433. if ($38) {
  22434. $$0185 = 0;
  22435. while(1) {
  22436. $121 = (($$0185) + ($120))|0;
  22437. $122 = (($13) + ($121<<2)|0);
  22438. $123 = +HEAPF32[$122>>2];
  22439. $124 = $45 * $123;
  22440. $125 = (($46) + ($121<<2)|0);
  22441. $126 = +HEAPF32[$125>>2];
  22442. $127 = $126 + $124;
  22443. HEAPF32[$125>>2] = $127;
  22444. $128 = (($$0185) + 1)|0;
  22445. $exitcond199 = ($128|0)==($9|0);
  22446. if ($exitcond199) {
  22447. break;
  22448. } else {
  22449. $$0185 = $128;
  22450. }
  22451. }
  22452. }
  22453. $129 = (($$4187) + 1)|0;
  22454. $exitcond200 = ($129|0)==($3|0);
  22455. if ($exitcond200) {
  22456. break;
  22457. } else {
  22458. $$4187 = $129;
  22459. }
  22460. }
  22461. }
  22462. }
  22463. }
  22464. $130 = (($$0168189) + 1)|0;
  22465. $131 = ($$0168189|0)<($31|0);
  22466. if ($131) {
  22467. $$0168189 = $130;
  22468. } else {
  22469. break;
  22470. }
  22471. }
  22472. return;
  22473. }
  22474. function _stbir__get_ring_buffer_scanline($0,$1,$2,$3,$4,$5) {
  22475. $0 = $0|0;
  22476. $1 = $1|0;
  22477. $2 = $2|0;
  22478. $3 = $3|0;
  22479. $4 = $4|0;
  22480. $5 = $5|0;
  22481. var $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  22482. sp = STACKTOP;
  22483. $6 = (($2) + ($0))|0;
  22484. $7 = (($6) - ($3))|0;
  22485. $8 = (($7|0) % ($4|0))&-1;
  22486. $9 = (_stbir__get_ring_buffer_entry($1,$8,$5)|0);
  22487. return ($9|0);
  22488. }
  22489. function _stbir__get_ring_buffer_entry($0,$1,$2) {
  22490. $0 = $0|0;
  22491. $1 = $1|0;
  22492. $2 = $2|0;
  22493. var $3 = 0, $4 = 0, label = 0, sp = 0;
  22494. sp = STACKTOP;
  22495. $3 = Math_imul($2, $1)|0;
  22496. $4 = (($0) + ($3<<2)|0);
  22497. return ($4|0);
  22498. }
  22499. function _stbir__decode_scanline($0,$1) {
  22500. $0 = $0|0;
  22501. $1 = $1|0;
  22502. var $$0 = 0.0, $$11330358 = 0, $$1320374 = 0, $$1370 = 0, $$2321380 = 0, $$2376 = 0, $$3322386 = 0, $$3382 = 0, $$4323392 = 0, $$4388 = 0, $$5324398 = 0, $$5394 = 0, $$6325404 = 0, $$6400 = 0, $$7326410 = 0, $$7406 = 0, $$8327416 = 0, $$8412 = 0, $$9328367 = 0, $$9363 = 0;
  22503. var $10 = 0, $100 = 0, $101 = 0, $102 = 0.0, $103 = 0.0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0.0, $112 = 0.0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0;
  22504. var $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0.0, $124 = 0.0, $125 = 0.0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0;
  22505. var $136 = 0, $137 = 0.0, $138 = 0.0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0.0, $147 = 0.0, $148 = 0.0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0;
  22506. var $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0.0, $16 = 0, $160 = 0.0, $161 = 0.0, $162 = 0.0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0;
  22507. var $172 = 0.0, $173 = 0.0, $174 = 0.0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0;
  22508. var $190 = 0, $191 = 0, $192 = 0, $193 = 0.0, $194 = 0.0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0, $2 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0;
  22509. var $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0, $22 = 0, $220 = 0.0, $221 = 0.0, $222 = 0, $223 = 0, $224 = 0, $225 = 0.0;
  22510. var $226 = 0.0, $227 = 0, $228 = 0, $229 = 0, $23 = 0, $230 = 0, $231 = 0, $232 = 0, $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0, $25 = 0;
  22511. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0;
  22512. var $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0;
  22513. var $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0.0, $77 = 0.0, $78 = 0, $79 = 0, $8 = 0;
  22514. var $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0;
  22515. var $99 = 0, $exitcond = 0, $exitcond437 = 0, $exitcond438 = 0, $exitcond439 = 0, $exitcond440 = 0, $exitcond441 = 0, $exitcond442 = 0, $exitcond443 = 0, $exitcond444 = 0, $exitcond445 = 0, $exitcond446 = 0, $exitcond447 = 0, $exitcond448 = 0, $exitcond449 = 0, $exitcond450 = 0, $exitcond451 = 0, $exitcond452 = 0, $exitcond457 = 0, $exitcond458 = 0;
  22516. var $exitcond459 = 0, $indvar = 0, $indvar$next = 0, $indvar$next429 = 0, $indvar$next434 = 0, $indvar428 = 0, $indvar433 = 0, $scevgep = 0, $scevgep430 = 0, $scevgep435 = 0, label = 0, sp = 0;
  22517. sp = STACKTOP;
  22518. $2 = ((($0)) + 64|0);
  22519. $3 = HEAP32[$2>>2]|0;
  22520. $4 = ((($0)) + 68|0);
  22521. $5 = HEAP32[$4>>2]|0;
  22522. $6 = ((($0)) + 76|0);
  22523. $7 = HEAP32[$6>>2]|0;
  22524. $8 = ((($0)) + 96|0);
  22525. $9 = HEAP32[$8>>2]|0;
  22526. $10 = ((($0)) + 4|0);
  22527. $11 = HEAP32[$10>>2]|0;
  22528. $12 = ((($0)) + 12|0);
  22529. $13 = HEAP32[$12>>2]|0;
  22530. $14 = (_stbir__get_decode_buffer($0)|0);
  22531. $15 = ((($0)) + 88|0);
  22532. $16 = HEAP32[$15>>2]|0;
  22533. $17 = ((($0)) + 92|0);
  22534. $18 = HEAP32[$17>>2]|0;
  22535. $19 = ((($0)) + 8|0);
  22536. $20 = HEAP32[$19>>2]|0;
  22537. $21 = (_stbir__edge_wrap($18,$1,$20)|0);
  22538. $22 = Math_imul($21, $13)|0;
  22539. $23 = HEAP32[$0>>2]|0;
  22540. $24 = (($23) + ($22)|0);
  22541. $25 = ((($0)) + 144|0);
  22542. $26 = HEAP32[$25>>2]|0;
  22543. $27 = (($26) + ($11))|0;
  22544. $28 = $7 << 1;
  22545. $29 = (($28) + ($9))|0;
  22546. $30 = (0 - ($26))|0;
  22547. $31 = ($18|0)==(4);
  22548. do {
  22549. if ($31) {
  22550. $32 = ($1|0)<(0);
  22551. if (!($32)) {
  22552. $33 = HEAP32[$19>>2]|0;
  22553. $34 = ($33|0)>($1|0);
  22554. if ($34) {
  22555. break;
  22556. }
  22557. }
  22558. $35 = ($27|0)>($30|0);
  22559. if (!($35)) {
  22560. return;
  22561. }
  22562. $36 = ($3|0)>(0);
  22563. $37 = $3 << 2;
  22564. $38 = $26 << 1;
  22565. $39 = (($11) + ($38))|0;
  22566. $indvar = 0;
  22567. while(1) {
  22568. if ($36) {
  22569. $40 = (($indvar) - ($26))|0;
  22570. $41 = Math_imul($3, $40)|0;
  22571. $scevgep = (($14) + ($41<<2)|0);
  22572. _memset(($scevgep|0),0,($37|0))|0;
  22573. }
  22574. $indvar$next = (($indvar) + 1)|0;
  22575. $exitcond = ($indvar$next|0)==($39|0);
  22576. if ($exitcond) {
  22577. break;
  22578. } else {
  22579. $indvar = $indvar$next;
  22580. }
  22581. }
  22582. return;
  22583. }
  22584. } while(0);
  22585. switch ($29|0) {
  22586. case 0: {
  22587. $67 = ($27|0)>($30|0);
  22588. if ($67) {
  22589. $68 = ($3|0)>(0);
  22590. $69 = (($11) + ($26))|0;
  22591. $$1320374 = $30;
  22592. while(1) {
  22593. $70 = Math_imul($$1320374, $3)|0;
  22594. $71 = (_stbir__edge_wrap($16,$$1320374,$11)|0);
  22595. $72 = Math_imul($71, $3)|0;
  22596. if ($68) {
  22597. $$1370 = 0;
  22598. while(1) {
  22599. $73 = (($$1370) + ($72))|0;
  22600. $74 = (($24) + ($73)|0);
  22601. $75 = HEAP8[$74>>0]|0;
  22602. $76 = (+($75&255));
  22603. $77 = $76 / 255.0;
  22604. $78 = (($$1370) + ($70))|0;
  22605. $79 = (($14) + ($78<<2)|0);
  22606. HEAPF32[$79>>2] = $77;
  22607. $80 = (($$1370) + 1)|0;
  22608. $exitcond440 = ($80|0)==($3|0);
  22609. if ($exitcond440) {
  22610. break;
  22611. } else {
  22612. $$1370 = $80;
  22613. }
  22614. }
  22615. }
  22616. $81 = (($$1320374) + 1)|0;
  22617. $exitcond441 = ($81|0)==($69|0);
  22618. if ($exitcond441) {
  22619. break;
  22620. } else {
  22621. $$1320374 = $81;
  22622. }
  22623. }
  22624. }
  22625. break;
  22626. }
  22627. case 1: {
  22628. $63 = ($27|0)>($30|0);
  22629. if ($63) {
  22630. $64 = ($3|0)>(0);
  22631. $65 = ((($0)) + 72|0);
  22632. $66 = (($11) + ($26))|0;
  22633. $$2321380 = $30;
  22634. while(1) {
  22635. $82 = Math_imul($$2321380, $3)|0;
  22636. $83 = (_stbir__edge_wrap($16,$$2321380,$11)|0);
  22637. $84 = Math_imul($83, $3)|0;
  22638. if ($64) {
  22639. $$2376 = 0;
  22640. while(1) {
  22641. $85 = (($$2376) + ($84))|0;
  22642. $86 = (($24) + ($85)|0);
  22643. $87 = HEAP8[$86>>0]|0;
  22644. $88 = $87&255;
  22645. $89 = (3152 + ($88<<2)|0);
  22646. $90 = HEAP32[$89>>2]|0;
  22647. $91 = (($$2376) + ($82))|0;
  22648. $92 = (($14) + ($91<<2)|0);
  22649. HEAP32[$92>>2] = $90;
  22650. $93 = (($$2376) + 1)|0;
  22651. $exitcond442 = ($93|0)==($3|0);
  22652. if ($exitcond442) {
  22653. break;
  22654. } else {
  22655. $$2376 = $93;
  22656. }
  22657. }
  22658. }
  22659. $94 = HEAP32[$65>>2]|0;
  22660. $95 = $94 & 2;
  22661. $96 = ($95|0)==(0);
  22662. if ($96) {
  22663. $97 = (($82) + ($5))|0;
  22664. $98 = (($14) + ($97<<2)|0);
  22665. $99 = (($84) + ($5))|0;
  22666. $100 = (($24) + ($99)|0);
  22667. $101 = HEAP8[$100>>0]|0;
  22668. $102 = (+($101&255));
  22669. $103 = $102 / 255.0;
  22670. HEAPF32[$98>>2] = $103;
  22671. }
  22672. $104 = (($$2321380) + 1)|0;
  22673. $exitcond443 = ($104|0)==($66|0);
  22674. if ($exitcond443) {
  22675. break;
  22676. } else {
  22677. $$2321380 = $104;
  22678. }
  22679. }
  22680. }
  22681. break;
  22682. }
  22683. case 2: {
  22684. $60 = ($27|0)>($30|0);
  22685. if ($60) {
  22686. $61 = ($3|0)>(0);
  22687. $62 = (($11) + ($26))|0;
  22688. $$3322386 = $30;
  22689. while(1) {
  22690. $105 = Math_imul($$3322386, $3)|0;
  22691. $106 = (_stbir__edge_wrap($16,$$3322386,$11)|0);
  22692. $107 = Math_imul($106, $3)|0;
  22693. if ($61) {
  22694. $$3382 = 0;
  22695. while(1) {
  22696. $108 = (($$3382) + ($107))|0;
  22697. $109 = (($24) + ($108<<1)|0);
  22698. $110 = HEAP16[$109>>1]|0;
  22699. $111 = (+($110&65535));
  22700. $112 = $111 / 65535.0;
  22701. $113 = (($$3382) + ($105))|0;
  22702. $114 = (($14) + ($113<<2)|0);
  22703. HEAPF32[$114>>2] = $112;
  22704. $115 = (($$3382) + 1)|0;
  22705. $exitcond444 = ($115|0)==($3|0);
  22706. if ($exitcond444) {
  22707. break;
  22708. } else {
  22709. $$3382 = $115;
  22710. }
  22711. }
  22712. }
  22713. $116 = (($$3322386) + 1)|0;
  22714. $exitcond445 = ($116|0)==($62|0);
  22715. if ($exitcond445) {
  22716. break;
  22717. } else {
  22718. $$3322386 = $116;
  22719. }
  22720. }
  22721. }
  22722. break;
  22723. }
  22724. case 3: {
  22725. $56 = ($27|0)>($30|0);
  22726. if ($56) {
  22727. $57 = ($3|0)>(0);
  22728. $58 = ((($0)) + 72|0);
  22729. $59 = (($11) + ($26))|0;
  22730. $$4323392 = $30;
  22731. while(1) {
  22732. $117 = Math_imul($$4323392, $3)|0;
  22733. $118 = (_stbir__edge_wrap($16,$$4323392,$11)|0);
  22734. $119 = Math_imul($118, $3)|0;
  22735. if ($57) {
  22736. $$4388 = 0;
  22737. while(1) {
  22738. $120 = (($$4388) + ($119))|0;
  22739. $121 = (($24) + ($120<<1)|0);
  22740. $122 = HEAP16[$121>>1]|0;
  22741. $123 = (+($122&65535));
  22742. $124 = $123 / 65535.0;
  22743. $125 = (+_stbir__srgb_to_linear($124));
  22744. $126 = (($$4388) + ($117))|0;
  22745. $127 = (($14) + ($126<<2)|0);
  22746. HEAPF32[$127>>2] = $125;
  22747. $128 = (($$4388) + 1)|0;
  22748. $exitcond446 = ($128|0)==($3|0);
  22749. if ($exitcond446) {
  22750. break;
  22751. } else {
  22752. $$4388 = $128;
  22753. }
  22754. }
  22755. }
  22756. $129 = HEAP32[$58>>2]|0;
  22757. $130 = $129 & 2;
  22758. $131 = ($130|0)==(0);
  22759. if ($131) {
  22760. $132 = (($117) + ($5))|0;
  22761. $133 = (($14) + ($132<<2)|0);
  22762. $134 = (($119) + ($5))|0;
  22763. $135 = (($24) + ($134<<1)|0);
  22764. $136 = HEAP16[$135>>1]|0;
  22765. $137 = (+($136&65535));
  22766. $138 = $137 / 65535.0;
  22767. HEAPF32[$133>>2] = $138;
  22768. }
  22769. $139 = (($$4323392) + 1)|0;
  22770. $exitcond447 = ($139|0)==($59|0);
  22771. if ($exitcond447) {
  22772. break;
  22773. } else {
  22774. $$4323392 = $139;
  22775. }
  22776. }
  22777. }
  22778. break;
  22779. }
  22780. case 4: {
  22781. $53 = ($27|0)>($30|0);
  22782. if ($53) {
  22783. $54 = ($3|0)>(0);
  22784. $55 = (($11) + ($26))|0;
  22785. $$5324398 = $30;
  22786. while(1) {
  22787. $140 = Math_imul($$5324398, $3)|0;
  22788. $141 = (_stbir__edge_wrap($16,$$5324398,$11)|0);
  22789. $142 = Math_imul($141, $3)|0;
  22790. if ($54) {
  22791. $$5394 = 0;
  22792. while(1) {
  22793. $143 = (($$5394) + ($142))|0;
  22794. $144 = (($24) + ($143<<2)|0);
  22795. $145 = HEAP32[$144>>2]|0;
  22796. $146 = (+($145>>>0));
  22797. $147 = $146 / 4294967295.0;
  22798. $148 = $147;
  22799. $149 = (($$5394) + ($140))|0;
  22800. $150 = (($14) + ($149<<2)|0);
  22801. HEAPF32[$150>>2] = $148;
  22802. $151 = (($$5394) + 1)|0;
  22803. $exitcond448 = ($151|0)==($3|0);
  22804. if ($exitcond448) {
  22805. break;
  22806. } else {
  22807. $$5394 = $151;
  22808. }
  22809. }
  22810. }
  22811. $152 = (($$5324398) + 1)|0;
  22812. $exitcond449 = ($152|0)==($55|0);
  22813. if ($exitcond449) {
  22814. break;
  22815. } else {
  22816. $$5324398 = $152;
  22817. }
  22818. }
  22819. }
  22820. break;
  22821. }
  22822. case 5: {
  22823. $49 = ($27|0)>($30|0);
  22824. if ($49) {
  22825. $50 = ($3|0)>(0);
  22826. $51 = ((($0)) + 72|0);
  22827. $52 = (($11) + ($26))|0;
  22828. $$6325404 = $30;
  22829. while(1) {
  22830. $153 = Math_imul($$6325404, $3)|0;
  22831. $154 = (_stbir__edge_wrap($16,$$6325404,$11)|0);
  22832. $155 = Math_imul($154, $3)|0;
  22833. if ($50) {
  22834. $$6400 = 0;
  22835. while(1) {
  22836. $156 = (($$6400) + ($155))|0;
  22837. $157 = (($24) + ($156<<2)|0);
  22838. $158 = HEAP32[$157>>2]|0;
  22839. $159 = (+($158>>>0));
  22840. $160 = $159 / 4294967295.0;
  22841. $161 = $160;
  22842. $162 = (+_stbir__srgb_to_linear($161));
  22843. $163 = (($$6400) + ($153))|0;
  22844. $164 = (($14) + ($163<<2)|0);
  22845. HEAPF32[$164>>2] = $162;
  22846. $165 = (($$6400) + 1)|0;
  22847. $exitcond450 = ($165|0)==($3|0);
  22848. if ($exitcond450) {
  22849. break;
  22850. } else {
  22851. $$6400 = $165;
  22852. }
  22853. }
  22854. }
  22855. $166 = HEAP32[$51>>2]|0;
  22856. $167 = $166 & 2;
  22857. $168 = ($167|0)==(0);
  22858. if ($168) {
  22859. $169 = (($155) + ($5))|0;
  22860. $170 = (($24) + ($169<<2)|0);
  22861. $171 = HEAP32[$170>>2]|0;
  22862. $172 = (+($171>>>0));
  22863. $173 = $172 / 4294967295.0;
  22864. $174 = $173;
  22865. $175 = (($153) + ($5))|0;
  22866. $176 = (($14) + ($175<<2)|0);
  22867. HEAPF32[$176>>2] = $174;
  22868. }
  22869. $177 = (($$6325404) + 1)|0;
  22870. $exitcond451 = ($177|0)==($52|0);
  22871. if ($exitcond451) {
  22872. break;
  22873. } else {
  22874. $$6325404 = $177;
  22875. }
  22876. }
  22877. }
  22878. break;
  22879. }
  22880. case 6: {
  22881. $46 = ($27|0)>($30|0);
  22882. if ($46) {
  22883. $47 = ($3|0)>(0);
  22884. $48 = (($11) + ($26))|0;
  22885. $$7326410 = $30;
  22886. while(1) {
  22887. $178 = Math_imul($$7326410, $3)|0;
  22888. $179 = (_stbir__edge_wrap($16,$$7326410,$11)|0);
  22889. $180 = Math_imul($179, $3)|0;
  22890. if ($47) {
  22891. $$7406 = 0;
  22892. while(1) {
  22893. $181 = (($$7406) + ($180))|0;
  22894. $182 = (($24) + ($181<<2)|0);
  22895. $183 = HEAP32[$182>>2]|0;
  22896. $184 = (($$7406) + ($178))|0;
  22897. $185 = (($14) + ($184<<2)|0);
  22898. HEAP32[$185>>2] = $183;
  22899. $186 = (($$7406) + 1)|0;
  22900. $exitcond452 = ($186|0)==($3|0);
  22901. if ($exitcond452) {
  22902. break;
  22903. } else {
  22904. $$7406 = $186;
  22905. }
  22906. }
  22907. }
  22908. $187 = (($$7326410) + 1)|0;
  22909. $exitcond457 = ($187|0)==($48|0);
  22910. if ($exitcond457) {
  22911. break;
  22912. } else {
  22913. $$7326410 = $187;
  22914. }
  22915. }
  22916. }
  22917. break;
  22918. }
  22919. case 7: {
  22920. $42 = ($27|0)>($30|0);
  22921. if ($42) {
  22922. $43 = ($3|0)>(0);
  22923. $44 = ((($0)) + 72|0);
  22924. $45 = (($11) + ($26))|0;
  22925. $$8327416 = $30;
  22926. while(1) {
  22927. $188 = Math_imul($$8327416, $3)|0;
  22928. $189 = (_stbir__edge_wrap($16,$$8327416,$11)|0);
  22929. $190 = Math_imul($189, $3)|0;
  22930. if ($43) {
  22931. $$8412 = 0;
  22932. while(1) {
  22933. $191 = (($$8412) + ($190))|0;
  22934. $192 = (($24) + ($191<<2)|0);
  22935. $193 = +HEAPF32[$192>>2];
  22936. $194 = (+_stbir__srgb_to_linear($193));
  22937. $195 = (($$8412) + ($188))|0;
  22938. $196 = (($14) + ($195<<2)|0);
  22939. HEAPF32[$196>>2] = $194;
  22940. $197 = (($$8412) + 1)|0;
  22941. $exitcond458 = ($197|0)==($3|0);
  22942. if ($exitcond458) {
  22943. break;
  22944. } else {
  22945. $$8412 = $197;
  22946. }
  22947. }
  22948. }
  22949. $198 = HEAP32[$44>>2]|0;
  22950. $199 = $198 & 2;
  22951. $200 = ($199|0)==(0);
  22952. if ($200) {
  22953. $201 = (($188) + ($5))|0;
  22954. $202 = (($14) + ($201<<2)|0);
  22955. $203 = (($190) + ($5))|0;
  22956. $204 = (($24) + ($203<<2)|0);
  22957. $205 = HEAP32[$204>>2]|0;
  22958. HEAP32[$202>>2] = $205;
  22959. }
  22960. $206 = (($$8327416) + 1)|0;
  22961. $exitcond459 = ($206|0)==($45|0);
  22962. if ($exitcond459) {
  22963. break;
  22964. } else {
  22965. $$8327416 = $206;
  22966. }
  22967. }
  22968. }
  22969. break;
  22970. }
  22971. default: {
  22972. ___assert_fail((13319|0),(12015|0),1363,(13368|0));
  22973. // unreachable;
  22974. }
  22975. }
  22976. $207 = ((($0)) + 72|0);
  22977. $208 = HEAP32[$207>>2]|0;
  22978. $209 = $208 & 1;
  22979. $210 = ($209|0)==(0);
  22980. if ($210) {
  22981. $211 = HEAP32[$25>>2]|0;
  22982. $212 = (0 - ($211))|0;
  22983. $213 = ($27|0)>($212|0);
  22984. if ($213) {
  22985. $214 = HEAP32[$6>>2]|0;
  22986. $215 = ($214|0)==(3);
  22987. $216 = ($3|0)>(0);
  22988. $$9328367 = $212;
  22989. while(1) {
  22990. $217 = Math_imul($$9328367, $3)|0;
  22991. $218 = (($217) + ($5))|0;
  22992. $219 = (($14) + ($218<<2)|0);
  22993. $220 = +HEAPF32[$219>>2];
  22994. $221 = $220 + 8.2718061255302767E-25;
  22995. if ($215) {
  22996. $$0 = $220;
  22997. } else {
  22998. HEAPF32[$219>>2] = $221;
  22999. $$0 = $221;
  23000. }
  23001. if ($216) {
  23002. $$9363 = 0;
  23003. while(1) {
  23004. $222 = ($$9363|0)==($5|0);
  23005. $223 = (($$9363) + ($217))|0;
  23006. $224 = (($14) + ($223<<2)|0);
  23007. if (!($222)) {
  23008. $225 = +HEAPF32[$224>>2];
  23009. $226 = $$0 * $225;
  23010. HEAPF32[$224>>2] = $226;
  23011. }
  23012. $227 = (($$9363) + 1)|0;
  23013. $exitcond438 = ($227|0)==($3|0);
  23014. if ($exitcond438) {
  23015. break;
  23016. } else {
  23017. $$9363 = $227;
  23018. }
  23019. }
  23020. }
  23021. $228 = (($$9328367) + 1)|0;
  23022. $exitcond439 = ($228|0)==($27|0);
  23023. if ($exitcond439) {
  23024. break;
  23025. } else {
  23026. $$9328367 = $228;
  23027. }
  23028. }
  23029. }
  23030. }
  23031. $229 = ($16|0)==(4);
  23032. if (!($229)) {
  23033. return;
  23034. }
  23035. $230 = HEAP32[$25>>2]|0;
  23036. $231 = ($230|0)>(0);
  23037. if ($231) {
  23038. $232 = ($3|0)>(0);
  23039. $233 = $3 << 2;
  23040. $indvar433 = 0;
  23041. while(1) {
  23042. if ($232) {
  23043. $237 = (($indvar433) - ($230))|0;
  23044. $238 = Math_imul($3, $237)|0;
  23045. $scevgep435 = (($14) + ($238<<2)|0);
  23046. _memset(($scevgep435|0),0,($233|0))|0;
  23047. }
  23048. $indvar$next434 = (($indvar433) + 1)|0;
  23049. $exitcond437 = ($indvar$next434|0)==($230|0);
  23050. if ($exitcond437) {
  23051. break;
  23052. } else {
  23053. $indvar433 = $indvar$next434;
  23054. }
  23055. }
  23056. }
  23057. $234 = ($26|0)>(0);
  23058. if (!($234)) {
  23059. return;
  23060. }
  23061. $235 = ($3|0)>(0);
  23062. $236 = $3 << 2;
  23063. $$11330358 = $11;$indvar428 = 0;
  23064. while(1) {
  23065. if ($235) {
  23066. $239 = (($11) + ($indvar428))|0;
  23067. $240 = Math_imul($239, $3)|0;
  23068. $scevgep430 = (($14) + ($240<<2)|0);
  23069. _memset(($scevgep430|0),0,($236|0))|0;
  23070. }
  23071. $241 = (($$11330358) + 1)|0;
  23072. $242 = ($241|0)<($27|0);
  23073. $indvar$next429 = (($indvar428) + 1)|0;
  23074. if ($242) {
  23075. $$11330358 = $241;$indvar428 = $indvar$next429;
  23076. } else {
  23077. break;
  23078. }
  23079. }
  23080. return;
  23081. }
  23082. function _stbir__use_width_upsampling($0) {
  23083. $0 = $0|0;
  23084. var $1 = 0, $2 = 0.0, $3 = 0, label = 0, sp = 0;
  23085. sp = STACKTOP;
  23086. $1 = ((($0)) + 56|0);
  23087. $2 = +HEAPF32[$1>>2];
  23088. $3 = (_stbir__use_upsampling($2)|0);
  23089. return ($3|0);
  23090. }
  23091. function _stbir__resample_horizontal_upsample($0,$1) {
  23092. $0 = $0|0;
  23093. $1 = $1|0;
  23094. var $$0182214 = 0, $$0183207 = 0, $$0184206 = 0, $$0209 = 0, $$1185203 = 0, $$1204 = 0, $$2186200 = 0, $$2201 = 0, $$3187198 = 0, $$3199 = 0, $$4188211 = 0, $$4212 = 0, $10 = 0, $100 = 0.0, $101 = 0, $102 = 0, $103 = 0.0, $104 = 0.0, $105 = 0.0, $106 = 0.0;
  23095. var $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0.0, $113 = 0, $114 = 0, $115 = 0, $116 = 0.0, $117 = 0.0, $118 = 0.0, $119 = 0.0, $12 = 0, $120 = 0, $121 = 0, $122 = 0.0, $123 = 0.0, $124 = 0.0;
  23096. var $125 = 0.0, $126 = 0, $127 = 0, $128 = 0.0, $129 = 0.0, $13 = 0, $130 = 0.0, $131 = 0.0, $132 = 0, $133 = 0, $134 = 0.0, $135 = 0.0, $136 = 0.0, $137 = 0.0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0;
  23097. var $143 = 0, $144 = 0.0, $145 = 0, $146 = 0, $147 = 0, $148 = 0.0, $149 = 0.0, $15 = 0, $150 = 0, $151 = 0, $152 = 0.0, $153 = 0.0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $16 = 0, $17 = 0, $18 = 0;
  23098. var $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0;
  23099. var $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0;
  23100. var $55 = 0.0, $56 = 0, $57 = 0, $58 = 0, $59 = 0.0, $6 = 0, $60 = 0.0, $61 = 0.0, $62 = 0.0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0.0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0.0;
  23101. var $73 = 0.0, $74 = 0.0, $75 = 0.0, $76 = 0, $77 = 0, $78 = 0.0, $79 = 0.0, $8 = 0, $80 = 0.0, $81 = 0.0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0.0, $88 = 0, $89 = 0, $9 = 0, $90 = 0;
  23102. var $91 = 0.0, $92 = 0.0, $93 = 0.0, $94 = 0.0, $95 = 0, $96 = 0, $97 = 0.0, $98 = 0.0, $99 = 0.0, $exitcond = 0, label = 0, sp = 0;
  23103. sp = STACKTOP;
  23104. $2 = ((($0)) + 20|0);
  23105. $3 = HEAP32[$2>>2]|0;
  23106. $4 = ((($0)) + 64|0);
  23107. $5 = HEAP32[$4>>2]|0;
  23108. $6 = (_stbir__get_decode_buffer($0)|0);
  23109. $7 = ((($0)) + 100|0);
  23110. $8 = HEAP32[$7>>2]|0;
  23111. $9 = ((($0)) + 104|0);
  23112. $10 = HEAP32[$9>>2]|0;
  23113. $11 = ((($0)) + 128|0);
  23114. $12 = HEAP32[$11>>2]|0;
  23115. $13 = ($3|0)>(0);
  23116. if (!($13)) {
  23117. return;
  23118. }
  23119. $14 = ((($0)) + 144|0);
  23120. $15 = ((($0)) + 4|0);
  23121. $16 = ($5|0)>(0);
  23122. $$0182214 = 0;
  23123. L4: while(1) {
  23124. $17 = (($8) + ($$0182214<<3)|0);
  23125. $18 = HEAP32[$17>>2]|0;
  23126. $19 = (((($8) + ($$0182214<<3)|0)) + 4|0);
  23127. $20 = HEAP32[$19>>2]|0;
  23128. $21 = Math_imul($$0182214, $5)|0;
  23129. $22 = Math_imul($$0182214, $12)|0;
  23130. $23 = ($20|0)<($18|0);
  23131. if ($23) {
  23132. label = 4;
  23133. break;
  23134. }
  23135. $24 = HEAP32[$14>>2]|0;
  23136. $25 = (0 - ($24))|0;
  23137. $26 = ($18|0)<($25|0);
  23138. if ($26) {
  23139. label = 6;
  23140. break;
  23141. }
  23142. $27 = ($20|0)<($25|0);
  23143. if ($27) {
  23144. label = 8;
  23145. break;
  23146. }
  23147. $28 = HEAP32[$15>>2]|0;
  23148. $29 = (($28) + ($24))|0;
  23149. $30 = ($18|0)<($29|0);
  23150. if (!($30)) {
  23151. label = 10;
  23152. break;
  23153. }
  23154. $31 = ($20|0)<($29|0);
  23155. if (!($31)) {
  23156. label = 12;
  23157. break;
  23158. }
  23159. switch ($5|0) {
  23160. case 1: {
  23161. $50 = ($18|0)>($20|0);
  23162. if (!($50)) {
  23163. $51 = (($1) + ($21<<2)|0);
  23164. $$0183207 = $18;$$0184206 = 0;
  23165. while(1) {
  23166. $53 = (($$0184206) + ($22))|0;
  23167. $54 = (($10) + ($53<<2)|0);
  23168. $55 = +HEAPF32[$54>>2];
  23169. $56 = $55 != 0.0;
  23170. if (!($56)) {
  23171. label = 24;
  23172. break L4;
  23173. }
  23174. $57 = (($$0184206) + 1)|0;
  23175. $58 = (($6) + ($$0183207<<2)|0);
  23176. $59 = +HEAPF32[$58>>2];
  23177. $60 = $55 * $59;
  23178. $61 = +HEAPF32[$51>>2];
  23179. $62 = $61 + $60;
  23180. HEAPF32[$51>>2] = $62;
  23181. $63 = (($$0183207) + 1)|0;
  23182. $64 = ($$0183207|0)<($20|0);
  23183. if ($64) {
  23184. $$0183207 = $63;$$0184206 = $57;
  23185. } else {
  23186. break;
  23187. }
  23188. }
  23189. }
  23190. break;
  23191. }
  23192. case 2: {
  23193. $46 = ($18|0)>($20|0);
  23194. if (!($46)) {
  23195. $47 = (($1) + ($21<<2)|0);
  23196. $48 = (($21) + 1)|0;
  23197. $49 = (($1) + ($48<<2)|0);
  23198. $$1185203 = 0;$$1204 = $18;
  23199. while(1) {
  23200. $65 = $$1204 << 1;
  23201. $66 = (($$1185203) + ($22))|0;
  23202. $67 = (($10) + ($66<<2)|0);
  23203. $68 = +HEAPF32[$67>>2];
  23204. $69 = $68 != 0.0;
  23205. if (!($69)) {
  23206. label = 27;
  23207. break L4;
  23208. }
  23209. $70 = (($$1185203) + 1)|0;
  23210. $71 = (($6) + ($65<<2)|0);
  23211. $72 = +HEAPF32[$71>>2];
  23212. $73 = $68 * $72;
  23213. $74 = +HEAPF32[$47>>2];
  23214. $75 = $74 + $73;
  23215. HEAPF32[$47>>2] = $75;
  23216. $76 = $65 | 1;
  23217. $77 = (($6) + ($76<<2)|0);
  23218. $78 = +HEAPF32[$77>>2];
  23219. $79 = $68 * $78;
  23220. $80 = +HEAPF32[$49>>2];
  23221. $81 = $80 + $79;
  23222. HEAPF32[$49>>2] = $81;
  23223. $82 = (($$1204) + 1)|0;
  23224. $83 = ($$1204|0)<($20|0);
  23225. if ($83) {
  23226. $$1185203 = $70;$$1204 = $82;
  23227. } else {
  23228. break;
  23229. }
  23230. }
  23231. }
  23232. break;
  23233. }
  23234. case 3: {
  23235. $40 = ($18|0)>($20|0);
  23236. if (!($40)) {
  23237. $41 = (($1) + ($21<<2)|0);
  23238. $42 = (($21) + 1)|0;
  23239. $43 = (($1) + ($42<<2)|0);
  23240. $44 = (($21) + 2)|0;
  23241. $45 = (($1) + ($44<<2)|0);
  23242. $$2186200 = 0;$$2201 = $18;
  23243. while(1) {
  23244. $84 = ($$2201*3)|0;
  23245. $85 = (($$2186200) + ($22))|0;
  23246. $86 = (($10) + ($85<<2)|0);
  23247. $87 = +HEAPF32[$86>>2];
  23248. $88 = $87 != 0.0;
  23249. if (!($88)) {
  23250. label = 30;
  23251. break L4;
  23252. }
  23253. $89 = (($$2186200) + 1)|0;
  23254. $90 = (($6) + ($84<<2)|0);
  23255. $91 = +HEAPF32[$90>>2];
  23256. $92 = $87 * $91;
  23257. $93 = +HEAPF32[$41>>2];
  23258. $94 = $93 + $92;
  23259. HEAPF32[$41>>2] = $94;
  23260. $95 = (($84) + 1)|0;
  23261. $96 = (($6) + ($95<<2)|0);
  23262. $97 = +HEAPF32[$96>>2];
  23263. $98 = $87 * $97;
  23264. $99 = +HEAPF32[$43>>2];
  23265. $100 = $99 + $98;
  23266. HEAPF32[$43>>2] = $100;
  23267. $101 = (($84) + 2)|0;
  23268. $102 = (($6) + ($101<<2)|0);
  23269. $103 = +HEAPF32[$102>>2];
  23270. $104 = $87 * $103;
  23271. $105 = +HEAPF32[$45>>2];
  23272. $106 = $105 + $104;
  23273. HEAPF32[$45>>2] = $106;
  23274. $107 = (($$2201) + 1)|0;
  23275. $108 = ($$2201|0)<($20|0);
  23276. if ($108) {
  23277. $$2186200 = $89;$$2201 = $107;
  23278. } else {
  23279. break;
  23280. }
  23281. }
  23282. }
  23283. break;
  23284. }
  23285. case 4: {
  23286. $32 = ($18|0)>($20|0);
  23287. if (!($32)) {
  23288. $33 = (($1) + ($21<<2)|0);
  23289. $34 = (($21) + 1)|0;
  23290. $35 = (($1) + ($34<<2)|0);
  23291. $36 = (($21) + 2)|0;
  23292. $37 = (($1) + ($36<<2)|0);
  23293. $38 = (($21) + 3)|0;
  23294. $39 = (($1) + ($38<<2)|0);
  23295. $$3187198 = 0;$$3199 = $18;
  23296. while(1) {
  23297. $109 = $$3199 << 2;
  23298. $110 = (($$3187198) + ($22))|0;
  23299. $111 = (($10) + ($110<<2)|0);
  23300. $112 = +HEAPF32[$111>>2];
  23301. $113 = $112 != 0.0;
  23302. if (!($113)) {
  23303. label = 33;
  23304. break L4;
  23305. }
  23306. $114 = (($$3187198) + 1)|0;
  23307. $115 = (($6) + ($109<<2)|0);
  23308. $116 = +HEAPF32[$115>>2];
  23309. $117 = $112 * $116;
  23310. $118 = +HEAPF32[$33>>2];
  23311. $119 = $118 + $117;
  23312. HEAPF32[$33>>2] = $119;
  23313. $120 = $109 | 1;
  23314. $121 = (($6) + ($120<<2)|0);
  23315. $122 = +HEAPF32[$121>>2];
  23316. $123 = $112 * $122;
  23317. $124 = +HEAPF32[$35>>2];
  23318. $125 = $124 + $123;
  23319. HEAPF32[$35>>2] = $125;
  23320. $126 = $109 | 2;
  23321. $127 = (($6) + ($126<<2)|0);
  23322. $128 = +HEAPF32[$127>>2];
  23323. $129 = $112 * $128;
  23324. $130 = +HEAPF32[$37>>2];
  23325. $131 = $130 + $129;
  23326. HEAPF32[$37>>2] = $131;
  23327. $132 = $109 | 3;
  23328. $133 = (($6) + ($132<<2)|0);
  23329. $134 = +HEAPF32[$133>>2];
  23330. $135 = $112 * $134;
  23331. $136 = +HEAPF32[$39>>2];
  23332. $137 = $136 + $135;
  23333. HEAPF32[$39>>2] = $137;
  23334. $138 = (($$3199) + 1)|0;
  23335. $139 = ($$3199|0)<($20|0);
  23336. if ($139) {
  23337. $$3187198 = $114;$$3199 = $138;
  23338. } else {
  23339. break;
  23340. }
  23341. }
  23342. }
  23343. break;
  23344. }
  23345. default: {
  23346. $52 = ($18|0)>($20|0);
  23347. if (!($52)) {
  23348. $$4188211 = 0;$$4212 = $18;
  23349. while(1) {
  23350. $140 = Math_imul($$4212, $5)|0;
  23351. $141 = (($$4188211) + 1)|0;
  23352. $142 = (($$4188211) + ($22))|0;
  23353. $143 = (($10) + ($142<<2)|0);
  23354. $144 = +HEAPF32[$143>>2];
  23355. $145 = $144 != 0.0;
  23356. if (!($145)) {
  23357. label = 37;
  23358. break L4;
  23359. }
  23360. if ($16) {
  23361. $$0209 = 0;
  23362. while(1) {
  23363. $146 = (($$0209) + ($140))|0;
  23364. $147 = (($6) + ($146<<2)|0);
  23365. $148 = +HEAPF32[$147>>2];
  23366. $149 = $144 * $148;
  23367. $150 = (($$0209) + ($21))|0;
  23368. $151 = (($1) + ($150<<2)|0);
  23369. $152 = +HEAPF32[$151>>2];
  23370. $153 = $152 + $149;
  23371. HEAPF32[$151>>2] = $153;
  23372. $154 = (($$0209) + 1)|0;
  23373. $exitcond = ($154|0)==($5|0);
  23374. if ($exitcond) {
  23375. break;
  23376. } else {
  23377. $$0209 = $154;
  23378. }
  23379. }
  23380. }
  23381. $155 = (($$4212) + 1)|0;
  23382. $156 = ($$4212|0)<($20|0);
  23383. if ($156) {
  23384. $$4188211 = $141;$$4212 = $155;
  23385. } else {
  23386. break;
  23387. }
  23388. }
  23389. }
  23390. }
  23391. }
  23392. $157 = (($$0182214) + 1)|0;
  23393. $158 = ($157|0)<($3|0);
  23394. if ($158) {
  23395. $$0182214 = $157;
  23396. } else {
  23397. label = 41;
  23398. break;
  23399. }
  23400. }
  23401. switch (label|0) {
  23402. case 4: {
  23403. ___assert_fail((13034|0),(12015|0),1455,(13043|0));
  23404. // unreachable;
  23405. break;
  23406. }
  23407. case 6: {
  23408. ___assert_fail((13079|0),(12015|0),1456,(13043|0));
  23409. // unreachable;
  23410. break;
  23411. }
  23412. case 8: {
  23413. ___assert_fail((13129|0),(12015|0),1457,(13043|0));
  23414. // unreachable;
  23415. break;
  23416. }
  23417. case 10: {
  23418. ___assert_fail((13179|0),(12015|0),1458,(13043|0));
  23419. // unreachable;
  23420. break;
  23421. }
  23422. case 12: {
  23423. ___assert_fail((13249|0),(12015|0),1459,(13043|0));
  23424. // unreachable;
  23425. break;
  23426. }
  23427. case 24: {
  23428. ___assert_fail((13017|0),(12015|0),1467,(13043|0));
  23429. // unreachable;
  23430. break;
  23431. }
  23432. case 27: {
  23433. ___assert_fail((13017|0),(12015|0),1476,(13043|0));
  23434. // unreachable;
  23435. break;
  23436. }
  23437. case 30: {
  23438. ___assert_fail((13017|0),(12015|0),1486,(13043|0));
  23439. // unreachable;
  23440. break;
  23441. }
  23442. case 33: {
  23443. ___assert_fail((13017|0),(12015|0),1497,(13043|0));
  23444. // unreachable;
  23445. break;
  23446. }
  23447. case 37: {
  23448. ___assert_fail((13017|0),(12015|0),1510,(13043|0));
  23449. // unreachable;
  23450. break;
  23451. }
  23452. case 41: {
  23453. return;
  23454. break;
  23455. }
  23456. }
  23457. }
  23458. function _stbir__resample_horizontal_downsample($0,$1) {
  23459. $0 = $0|0;
  23460. $1 = $1|0;
  23461. var $$0288314 = 0, $$0293307 = 0, $$0318 = 0, $$1289320 = 0, $$1324 = 0, $$2290326 = 0, $$2330 = 0, $$3291332 = 0, $$3336 = 0, $$4292308 = 0, $$4312 = 0, $10 = 0, $100 = 0, $101 = 0.0, $102 = 0.0, $103 = 0.0, $104 = 0.0, $105 = 0, $106 = 0, $107 = 0.0;
  23462. var $108 = 0.0, $109 = 0.0, $11 = 0, $110 = 0.0, $111 = 0, $112 = 0, $113 = 0.0, $114 = 0.0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0;
  23463. var $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0.0, $139 = 0, $14 = 0, $140 = 0.0, $141 = 0.0, $142 = 0, $143 = 0.0;
  23464. var $144 = 0.0, $145 = 0.0, $146 = 0.0, $147 = 0, $148 = 0, $149 = 0.0, $15 = 0, $150 = 0.0, $151 = 0.0, $152 = 0.0, $153 = 0, $154 = 0, $155 = 0.0, $156 = 0.0, $157 = 0.0, $158 = 0.0, $159 = 0, $16 = 0, $160 = 0, $161 = 0.0;
  23465. var $162 = 0.0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0.0, $18 = 0;
  23466. var $180 = 0, $181 = 0, $182 = 0, $183 = 0.0, $184 = 0.0, $185 = 0, $186 = 0, $187 = 0.0, $188 = 0.0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  23467. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0.0, $37 = 0, $38 = 0.0, $39 = 0.0, $4 = 0, $40 = 0, $41 = 0.0;
  23468. var $42 = 0.0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0;
  23469. var $60 = 0, $61 = 0, $62 = 0.0, $63 = 0, $64 = 0.0, $65 = 0.0, $66 = 0, $67 = 0.0, $68 = 0.0, $69 = 0.0, $7 = 0, $70 = 0.0, $71 = 0, $72 = 0, $73 = 0.0, $74 = 0.0, $75 = 0, $76 = 0, $77 = 0, $78 = 0;
  23470. var $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0.0;
  23471. var $97 = 0, $98 = 0.0, $99 = 0.0, $exitcond = 0, label = 0, sp = 0;
  23472. sp = STACKTOP;
  23473. $2 = ((($0)) + 4|0);
  23474. $3 = HEAP32[$2>>2]|0;
  23475. $4 = ((($0)) + 64|0);
  23476. $5 = HEAP32[$4>>2]|0;
  23477. $6 = (_stbir__get_decode_buffer($0)|0);
  23478. $7 = ((($0)) + 100|0);
  23479. $8 = HEAP32[$7>>2]|0;
  23480. $9 = ((($0)) + 104|0);
  23481. $10 = HEAP32[$9>>2]|0;
  23482. $11 = ((($0)) + 128|0);
  23483. $12 = HEAP32[$11>>2]|0;
  23484. $13 = ((($0)) + 144|0);
  23485. $14 = HEAP32[$13>>2]|0;
  23486. $15 = $14 << 1;
  23487. $16 = (($15) + ($3))|0;
  23488. $17 = (_stbir__use_width_upsampling($0)|0);
  23489. $18 = ($17|0)==(0);
  23490. if (!($18)) {
  23491. ___assert_fail((12938|0),(12015|0),1531,(12979|0));
  23492. // unreachable;
  23493. }
  23494. switch ($5|0) {
  23495. case 1: {
  23496. $22 = ($16|0)>(0);
  23497. if ($22) {
  23498. $$0318 = 0;
  23499. } else {
  23500. return;
  23501. }
  23502. L27: while(1) {
  23503. $25 = (($8) + ($$0318<<3)|0);
  23504. $26 = HEAP32[$25>>2]|0;
  23505. $27 = (((($8) + ($$0318<<3)|0)) + 4|0);
  23506. $28 = HEAP32[$27>>2]|0;
  23507. $29 = ($26|0)>($28|0);
  23508. if (!($29)) {
  23509. $30 = Math_imul($$0318, $12)|0;
  23510. $31 = (($$0318) - ($14))|0;
  23511. $32 = (($30) - ($26))|0;
  23512. $33 = (($6) + ($31<<2)|0);
  23513. $$0288314 = $26;
  23514. while(1) {
  23515. $34 = (($32) + ($$0288314))|0;
  23516. $35 = (($10) + ($34<<2)|0);
  23517. $36 = +HEAPF32[$35>>2];
  23518. $37 = $36 != 0.0;
  23519. if (!($37)) {
  23520. label = 13;
  23521. break L27;
  23522. }
  23523. $38 = +HEAPF32[$33>>2];
  23524. $39 = $36 * $38;
  23525. $40 = (($1) + ($$0288314<<2)|0);
  23526. $41 = +HEAPF32[$40>>2];
  23527. $42 = $41 + $39;
  23528. HEAPF32[$40>>2] = $42;
  23529. $43 = (($$0288314) + 1)|0;
  23530. $44 = ($$0288314|0)<($28|0);
  23531. if ($44) {
  23532. $$0288314 = $43;
  23533. } else {
  23534. break;
  23535. }
  23536. }
  23537. }
  23538. $45 = (($$0318) + 1)|0;
  23539. $46 = ($45|0)<($16|0);
  23540. if ($46) {
  23541. $$0318 = $45;
  23542. } else {
  23543. label = 42;
  23544. break;
  23545. }
  23546. }
  23547. if ((label|0) == 13) {
  23548. ___assert_fail((13017|0),(12015|0),1549,(12979|0));
  23549. // unreachable;
  23550. }
  23551. else if ((label|0) == 42) {
  23552. return;
  23553. }
  23554. break;
  23555. }
  23556. case 2: {
  23557. $21 = ($16|0)>(0);
  23558. if ($21) {
  23559. $$1324 = 0;
  23560. } else {
  23561. return;
  23562. }
  23563. L41: while(1) {
  23564. $47 = (($8) + ($$1324<<3)|0);
  23565. $48 = HEAP32[$47>>2]|0;
  23566. $49 = (((($8) + ($$1324<<3)|0)) + 4|0);
  23567. $50 = HEAP32[$49>>2]|0;
  23568. $51 = (($$1324) - ($14))|0;
  23569. $52 = $51 << 1;
  23570. $53 = ($48|0)>($50|0);
  23571. if (!($53)) {
  23572. $54 = Math_imul($$1324, $12)|0;
  23573. $55 = (($54) - ($48))|0;
  23574. $56 = (($6) + ($52<<2)|0);
  23575. $57 = $52 | 1;
  23576. $58 = (($6) + ($57<<2)|0);
  23577. $$1289320 = $48;
  23578. while(1) {
  23579. $59 = $$1289320 << 1;
  23580. $60 = (($55) + ($$1289320))|0;
  23581. $61 = (($10) + ($60<<2)|0);
  23582. $62 = +HEAPF32[$61>>2];
  23583. $63 = $62 != 0.0;
  23584. if (!($63)) {
  23585. label = 19;
  23586. break L41;
  23587. }
  23588. $64 = +HEAPF32[$56>>2];
  23589. $65 = $62 * $64;
  23590. $66 = (($1) + ($59<<2)|0);
  23591. $67 = +HEAPF32[$66>>2];
  23592. $68 = $67 + $65;
  23593. HEAPF32[$66>>2] = $68;
  23594. $69 = +HEAPF32[$58>>2];
  23595. $70 = $62 * $69;
  23596. $71 = $59 | 1;
  23597. $72 = (($1) + ($71<<2)|0);
  23598. $73 = +HEAPF32[$72>>2];
  23599. $74 = $73 + $70;
  23600. HEAPF32[$72>>2] = $74;
  23601. $75 = (($$1289320) + 1)|0;
  23602. $76 = ($$1289320|0)<($50|0);
  23603. if ($76) {
  23604. $$1289320 = $75;
  23605. } else {
  23606. break;
  23607. }
  23608. }
  23609. }
  23610. $77 = (($$1324) + 1)|0;
  23611. $78 = ($77|0)<($16|0);
  23612. if ($78) {
  23613. $$1324 = $77;
  23614. } else {
  23615. label = 42;
  23616. break;
  23617. }
  23618. }
  23619. if ((label|0) == 19) {
  23620. ___assert_fail((13017|0),(12015|0),1570,(12979|0));
  23621. // unreachable;
  23622. }
  23623. else if ((label|0) == 42) {
  23624. return;
  23625. }
  23626. break;
  23627. }
  23628. case 3: {
  23629. $20 = ($16|0)>(0);
  23630. if ($20) {
  23631. $$2330 = 0;
  23632. } else {
  23633. return;
  23634. }
  23635. L55: while(1) {
  23636. $79 = (($8) + ($$2330<<3)|0);
  23637. $80 = HEAP32[$79>>2]|0;
  23638. $81 = (((($8) + ($$2330<<3)|0)) + 4|0);
  23639. $82 = HEAP32[$81>>2]|0;
  23640. $83 = (($$2330) - ($14))|0;
  23641. $84 = ($83*3)|0;
  23642. $85 = ($80|0)>($82|0);
  23643. if (!($85)) {
  23644. $86 = Math_imul($$2330, $12)|0;
  23645. $87 = (($86) - ($80))|0;
  23646. $88 = (($6) + ($84<<2)|0);
  23647. $89 = (($84) + 1)|0;
  23648. $90 = (($6) + ($89<<2)|0);
  23649. $91 = (($84) + 2)|0;
  23650. $92 = (($6) + ($91<<2)|0);
  23651. $$2290326 = $80;
  23652. while(1) {
  23653. $93 = ($$2290326*3)|0;
  23654. $94 = (($87) + ($$2290326))|0;
  23655. $95 = (($10) + ($94<<2)|0);
  23656. $96 = +HEAPF32[$95>>2];
  23657. $97 = $96 != 0.0;
  23658. if (!($97)) {
  23659. label = 25;
  23660. break L55;
  23661. }
  23662. $98 = +HEAPF32[$88>>2];
  23663. $99 = $96 * $98;
  23664. $100 = (($1) + ($93<<2)|0);
  23665. $101 = +HEAPF32[$100>>2];
  23666. $102 = $101 + $99;
  23667. HEAPF32[$100>>2] = $102;
  23668. $103 = +HEAPF32[$90>>2];
  23669. $104 = $96 * $103;
  23670. $105 = (($93) + 1)|0;
  23671. $106 = (($1) + ($105<<2)|0);
  23672. $107 = +HEAPF32[$106>>2];
  23673. $108 = $107 + $104;
  23674. HEAPF32[$106>>2] = $108;
  23675. $109 = +HEAPF32[$92>>2];
  23676. $110 = $96 * $109;
  23677. $111 = (($93) + 2)|0;
  23678. $112 = (($1) + ($111<<2)|0);
  23679. $113 = +HEAPF32[$112>>2];
  23680. $114 = $113 + $110;
  23681. HEAPF32[$112>>2] = $114;
  23682. $115 = (($$2290326) + 1)|0;
  23683. $116 = ($$2290326|0)<($82|0);
  23684. if ($116) {
  23685. $$2290326 = $115;
  23686. } else {
  23687. break;
  23688. }
  23689. }
  23690. }
  23691. $117 = (($$2330) + 1)|0;
  23692. $118 = ($117|0)<($16|0);
  23693. if ($118) {
  23694. $$2330 = $117;
  23695. } else {
  23696. label = 42;
  23697. break;
  23698. }
  23699. }
  23700. if ((label|0) == 25) {
  23701. ___assert_fail((13017|0),(12015|0),1592,(12979|0));
  23702. // unreachable;
  23703. }
  23704. else if ((label|0) == 42) {
  23705. return;
  23706. }
  23707. break;
  23708. }
  23709. case 4: {
  23710. $19 = ($16|0)>(0);
  23711. if ($19) {
  23712. $$3336 = 0;
  23713. } else {
  23714. return;
  23715. }
  23716. L69: while(1) {
  23717. $119 = (($8) + ($$3336<<3)|0);
  23718. $120 = HEAP32[$119>>2]|0;
  23719. $121 = (((($8) + ($$3336<<3)|0)) + 4|0);
  23720. $122 = HEAP32[$121>>2]|0;
  23721. $123 = (($$3336) - ($14))|0;
  23722. $124 = $123 << 2;
  23723. $125 = ($120|0)>($122|0);
  23724. if (!($125)) {
  23725. $126 = Math_imul($$3336, $12)|0;
  23726. $127 = (($126) - ($120))|0;
  23727. $128 = (($6) + ($124<<2)|0);
  23728. $129 = $124 | 1;
  23729. $130 = (($6) + ($129<<2)|0);
  23730. $131 = $124 | 2;
  23731. $132 = (($6) + ($131<<2)|0);
  23732. $133 = $124 | 3;
  23733. $134 = (($6) + ($133<<2)|0);
  23734. $$3291332 = $120;
  23735. while(1) {
  23736. $135 = $$3291332 << 2;
  23737. $136 = (($127) + ($$3291332))|0;
  23738. $137 = (($10) + ($136<<2)|0);
  23739. $138 = +HEAPF32[$137>>2];
  23740. $139 = $138 != 0.0;
  23741. if (!($139)) {
  23742. label = 31;
  23743. break L69;
  23744. }
  23745. $140 = +HEAPF32[$128>>2];
  23746. $141 = $138 * $140;
  23747. $142 = (($1) + ($135<<2)|0);
  23748. $143 = +HEAPF32[$142>>2];
  23749. $144 = $143 + $141;
  23750. HEAPF32[$142>>2] = $144;
  23751. $145 = +HEAPF32[$130>>2];
  23752. $146 = $138 * $145;
  23753. $147 = $135 | 1;
  23754. $148 = (($1) + ($147<<2)|0);
  23755. $149 = +HEAPF32[$148>>2];
  23756. $150 = $149 + $146;
  23757. HEAPF32[$148>>2] = $150;
  23758. $151 = +HEAPF32[$132>>2];
  23759. $152 = $138 * $151;
  23760. $153 = $135 | 2;
  23761. $154 = (($1) + ($153<<2)|0);
  23762. $155 = +HEAPF32[$154>>2];
  23763. $156 = $155 + $152;
  23764. HEAPF32[$154>>2] = $156;
  23765. $157 = +HEAPF32[$134>>2];
  23766. $158 = $138 * $157;
  23767. $159 = $135 | 3;
  23768. $160 = (($1) + ($159<<2)|0);
  23769. $161 = +HEAPF32[$160>>2];
  23770. $162 = $161 + $158;
  23771. HEAPF32[$160>>2] = $162;
  23772. $163 = (($$3291332) + 1)|0;
  23773. $164 = ($$3291332|0)<($122|0);
  23774. if ($164) {
  23775. $$3291332 = $163;
  23776. } else {
  23777. break;
  23778. }
  23779. }
  23780. }
  23781. $165 = (($$3336) + 1)|0;
  23782. $166 = ($165|0)<($16|0);
  23783. if ($166) {
  23784. $$3336 = $165;
  23785. } else {
  23786. label = 42;
  23787. break;
  23788. }
  23789. }
  23790. if ((label|0) == 31) {
  23791. ___assert_fail((13017|0),(12015|0),1615,(12979|0));
  23792. // unreachable;
  23793. }
  23794. else if ((label|0) == 42) {
  23795. return;
  23796. }
  23797. break;
  23798. }
  23799. default: {
  23800. $23 = ($16|0)>(0);
  23801. if (!($23)) {
  23802. return;
  23803. }
  23804. $24 = ($5|0)>(0);
  23805. $$4312 = 0;
  23806. L9: while(1) {
  23807. $167 = (($8) + ($$4312<<3)|0);
  23808. $168 = HEAP32[$167>>2]|0;
  23809. $169 = (((($8) + ($$4312<<3)|0)) + 4|0);
  23810. $170 = HEAP32[$169>>2]|0;
  23811. $171 = (($$4312) - ($14))|0;
  23812. $172 = Math_imul($171, $5)|0;
  23813. $173 = ($168|0)>($170|0);
  23814. if (!($173)) {
  23815. $174 = Math_imul($$4312, $12)|0;
  23816. $175 = (($174) - ($168))|0;
  23817. $$4292308 = $168;
  23818. while(1) {
  23819. $176 = Math_imul($$4292308, $5)|0;
  23820. $177 = (($175) + ($$4292308))|0;
  23821. $178 = (($10) + ($177<<2)|0);
  23822. $179 = +HEAPF32[$178>>2];
  23823. $180 = $179 != 0.0;
  23824. if (!($180)) {
  23825. label = 38;
  23826. break L9;
  23827. }
  23828. if ($24) {
  23829. $$0293307 = 0;
  23830. while(1) {
  23831. $181 = (($$0293307) + ($172))|0;
  23832. $182 = (($6) + ($181<<2)|0);
  23833. $183 = +HEAPF32[$182>>2];
  23834. $184 = $179 * $183;
  23835. $185 = (($$0293307) + ($176))|0;
  23836. $186 = (($1) + ($185<<2)|0);
  23837. $187 = +HEAPF32[$186>>2];
  23838. $188 = $187 + $184;
  23839. HEAPF32[$186>>2] = $188;
  23840. $189 = (($$0293307) + 1)|0;
  23841. $exitcond = ($189|0)==($5|0);
  23842. if ($exitcond) {
  23843. break;
  23844. } else {
  23845. $$0293307 = $189;
  23846. }
  23847. }
  23848. }
  23849. $190 = (($$4292308) + 1)|0;
  23850. $191 = ($$4292308|0)<($170|0);
  23851. if ($191) {
  23852. $$4292308 = $190;
  23853. } else {
  23854. break;
  23855. }
  23856. }
  23857. }
  23858. $192 = (($$4312) + 1)|0;
  23859. $193 = ($192|0)<($16|0);
  23860. if ($193) {
  23861. $$4312 = $192;
  23862. } else {
  23863. label = 42;
  23864. break;
  23865. }
  23866. }
  23867. if ((label|0) == 38) {
  23868. ___assert_fail((13017|0),(12015|0),1640,(12979|0));
  23869. // unreachable;
  23870. }
  23871. else if ((label|0) == 42) {
  23872. return;
  23873. }
  23874. }
  23875. }
  23876. }
  23877. function _stbir__get_decode_buffer($0) {
  23878. $0 = $0|0;
  23879. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, label = 0, sp = 0;
  23880. sp = STACKTOP;
  23881. $1 = ((($0)) + 120|0);
  23882. $2 = HEAP32[$1>>2]|0;
  23883. $3 = ((($0)) + 144|0);
  23884. $4 = HEAP32[$3>>2]|0;
  23885. $5 = ((($0)) + 64|0);
  23886. $6 = HEAP32[$5>>2]|0;
  23887. $7 = Math_imul($6, $4)|0;
  23888. $8 = (($2) + ($7<<2)|0);
  23889. return ($8|0);
  23890. }
  23891. function _stbir__use_upsampling($0) {
  23892. $0 = +$0;
  23893. var $1 = 0, $2 = 0, label = 0, sp = 0;
  23894. sp = STACKTOP;
  23895. $1 = $0 > 1.0;
  23896. $2 = $1&1;
  23897. return ($2|0);
  23898. }
  23899. function _stbir__edge_wrap($0,$1,$2) {
  23900. $0 = $0|0;
  23901. $1 = $1|0;
  23902. $2 = $2|0;
  23903. var $$0 = 0, $3 = 0, $4 = 0, $5 = 0, $or$cond = 0, label = 0, sp = 0;
  23904. sp = STACKTOP;
  23905. $3 = ($1|0)>(-1);
  23906. $4 = ($1|0)<($2|0);
  23907. $or$cond = $3 & $4;
  23908. if ($or$cond) {
  23909. $$0 = $1;
  23910. return ($$0|0);
  23911. }
  23912. $5 = (_stbir__edge_wrap_slow($0,$1,$2)|0);
  23913. $$0 = $5;
  23914. return ($$0|0);
  23915. }
  23916. function _stbir__srgb_to_linear($0) {
  23917. $0 = +$0;
  23918. var $$0 = 0.0, $1 = 0, $2 = 0.0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0.0, label = 0, sp = 0;
  23919. sp = STACKTOP;
  23920. $1 = !($0 <= 0.040449999272823334);
  23921. if ($1) {
  23922. $3 = $0 + 0.054999999701976776;
  23923. $4 = $3 / 1.0549999475479126;
  23924. $5 = $4;
  23925. $6 = (+Math_pow((+$5),2.4000000953674316));
  23926. $7 = $6;
  23927. $$0 = $7;
  23928. return (+$$0);
  23929. } else {
  23930. $2 = $0 / 12.920000076293945;
  23931. $$0 = $2;
  23932. return (+$$0);
  23933. }
  23934. return +(0.0);
  23935. }
  23936. function _stbir__edge_wrap_slow($0,$1,$2) {
  23937. $0 = $0|0;
  23938. $1 = $1|0;
  23939. $2 = $2|0;
  23940. var $$ = 0, $$$030 = 0, $$030 = 0, $$1 = 0, $$31 = 0, $$32 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0;
  23941. var $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  23942. sp = STACKTOP;
  23943. $3 = (0 - ($1))|0;
  23944. switch ($0|0) {
  23945. case 1: {
  23946. $4 = ($1|0)<(0);
  23947. if ($4) {
  23948. $$1 = 0;
  23949. return ($$1|0);
  23950. } else {
  23951. $5 = ($1|0)<($2|0);
  23952. $6 = (($2) + -1)|0;
  23953. $$31 = $5 ? $1 : $6;
  23954. return ($$31|0);
  23955. }
  23956. break;
  23957. }
  23958. case 2: {
  23959. $7 = ($1|0)<(0);
  23960. $8 = ($1|0)<($2|0);
  23961. if ($7) {
  23962. $9 = (($2) + -1)|0;
  23963. $$32 = $8 ? $3 : $9;
  23964. return ($$32|0);
  23965. } else {
  23966. $10 = $2 << 1;
  23967. $11 = ($10|0)>($1|0);
  23968. $12 = $1 ^ -1;
  23969. $13 = (($10) + ($12))|0;
  23970. $$030 = $11 ? $13 : 0;
  23971. $$$030 = $8 ? $1 : $$030;
  23972. return ($$$030|0);
  23973. }
  23974. break;
  23975. }
  23976. case 3: {
  23977. $14 = ($1|0)>(-1);
  23978. if ($14) {
  23979. $15 = (($1|0) % ($2|0))&-1;
  23980. $$1 = $15;
  23981. return ($$1|0);
  23982. } else {
  23983. $16 = (0 - ($1))|0;
  23984. $17 = (($16|0) % ($2|0))&-1;
  23985. $18 = ($17|0)==(0);
  23986. $19 = (($2) - ($17))|0;
  23987. $$ = $18 ? 0 : $19;
  23988. $$1 = $$;
  23989. return ($$1|0);
  23990. }
  23991. break;
  23992. }
  23993. case 4: {
  23994. $$1 = 0;
  23995. return ($$1|0);
  23996. break;
  23997. }
  23998. default: {
  23999. ___assert_fail((13391|0),(12015|0),989,(13418|0));
  24000. // unreachable;
  24001. }
  24002. }
  24003. return (0)|0;
  24004. }
  24005. function _stbir__encode_scanline($0,$1,$2,$3,$4,$5,$6) {
  24006. $0 = $0|0;
  24007. $1 = $1|0;
  24008. $2 = $2|0;
  24009. $3 = $3|0;
  24010. $4 = $4|0;
  24011. $5 = $5|0;
  24012. $6 = $6|0;
  24013. var $$0211287 = 0, $$0220$lcssa = 0, $$0220283 = 0, $$0291 = 0, $$1212238 = 0, $$1221 = 0, $$1284 = 0, $$2213241 = 0, $$2239 = 0, $$3214247 = 0, $$3245 = 0, $$4215253 = 0, $$4251 = 0, $$5216259 = 0, $$5257 = 0, $$6217265 = 0, $$6263 = 0, $$7218271 = 0, $$7269 = 0, $$8219277 = 0;
  24014. var $$8275 = 0, $$9281 = 0, $10 = 0, $100 = 0.0, $101 = 0.0, $102 = 0.0, $103 = 0.0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0.0;
  24015. var $116 = 0.0, $117 = 0.0, $118 = 0.0, $119 = 0.0, $12 = 0, $120 = 0.0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0.0, $128 = 0.0, $129 = 0.0, $13 = 0, $130 = 0.0, $131 = 0.0, $132 = 0, $133 = 0;
  24016. var $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0.0, $14 = 0, $140 = 0.0, $141 = 0.0, $142 = 0.0, $143 = 0.0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0;
  24017. var $152 = 0, $153 = 0, $154 = 0.0, $155 = 0.0, $156 = 0.0, $157 = 0.0, $158 = 0.0, $159 = 0.0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0.0, $169 = 0.0, $17 = 0;
  24018. var $170 = 0.0, $171 = 0.0, $172 = 0.0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0.0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0;
  24019. var $189 = 0.0, $19 = 0, $190 = 0.0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $20 = 0.0, $21 = 0.0, $22 = 0, $23 = 0, $24 = 0, $25 = 0.0, $26 = 0.0, $27 = 0, $28 = 0, $29 = 0;
  24020. var $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0;
  24021. var $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $60 = 0, $61 = 0, $62 = 0.0, $63 = 0.0, $64 = 0.0, $65 = 0.0, $66 = 0.0, $67 = 0, $68 = 0, $69 = 0;
  24022. var $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0.0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0.0;
  24023. var $88 = 0.0, $89 = 0.0, $9 = 0, $90 = 0.0, $91 = 0.0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0.0, $exitcond = 0, $exitcond300 = 0, $exitcond301 = 0, $exitcond302 = 0, $exitcond303 = 0, $exitcond304 = 0, $exitcond305 = 0;
  24024. var $exitcond306 = 0, $exitcond307 = 0, $exitcond308 = 0, $exitcond309 = 0, $exitcond310 = 0, $exitcond311 = 0, $exitcond312 = 0, $exitcond313 = 0, $exitcond314 = 0, $exitcond315 = 0, $exitcond316 = 0, $exitcond317 = 0, $or$cond = 0, label = 0, sp = 0;
  24025. sp = STACKTOP;
  24026. STACKTOP = STACKTOP + 128|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(128|0);
  24027. $7 = sp;
  24028. $8 = ((($0)) + 72|0);
  24029. $9 = HEAP32[$8>>2]|0;
  24030. $10 = $9 & 1;
  24031. $11 = ($10|0)==(0);
  24032. $12 = ($1|0)>(0);
  24033. $or$cond = $11 & $12;
  24034. if ($or$cond) {
  24035. $13 = ($4|0)>(0);
  24036. $$0291 = 0;
  24037. while(1) {
  24038. $15 = Math_imul($$0291, $4)|0;
  24039. $16 = (($15) + ($5))|0;
  24040. $17 = (($3) + ($16<<2)|0);
  24041. $18 = +HEAPF32[$17>>2];
  24042. $19 = $18 != 0.0;
  24043. $20 = 1.0 / $18;
  24044. $21 = $19 ? $20 : 0.0;
  24045. if ($13) {
  24046. $$0211287 = 0;
  24047. while(1) {
  24048. $22 = ($$0211287|0)==($5|0);
  24049. $23 = (($$0211287) + ($15))|0;
  24050. $24 = (($3) + ($23<<2)|0);
  24051. if (!($22)) {
  24052. $25 = +HEAPF32[$24>>2];
  24053. $26 = $21 * $25;
  24054. HEAPF32[$24>>2] = $26;
  24055. }
  24056. $27 = (($$0211287) + 1)|0;
  24057. $exitcond316 = ($27|0)==($4|0);
  24058. if ($exitcond316) {
  24059. break;
  24060. } else {
  24061. $$0211287 = $27;
  24062. }
  24063. }
  24064. }
  24065. $28 = (($$0291) + 1)|0;
  24066. $exitcond317 = ($28|0)==($1|0);
  24067. if ($exitcond317) {
  24068. break;
  24069. } else {
  24070. $$0291 = $28;
  24071. }
  24072. }
  24073. }
  24074. $14 = ($4|0)>(0);
  24075. if ($14) {
  24076. $$0220283 = 0;$$1284 = 0;
  24077. while(1) {
  24078. $29 = ($$1284|0)==($5|0);
  24079. if ($29) {
  24080. $30 = HEAP32[$8>>2]|0;
  24081. $31 = $30 & 2;
  24082. $32 = ($31|0)==(0);
  24083. if ($32) {
  24084. $$1221 = $$0220283;
  24085. } else {
  24086. label = 11;
  24087. }
  24088. } else {
  24089. label = 11;
  24090. }
  24091. if ((label|0) == 11) {
  24092. label = 0;
  24093. $33 = $$1284&65535;
  24094. $34 = (($$0220283) + 1)|0;
  24095. $35 = (($7) + ($$0220283<<1)|0);
  24096. HEAP16[$35>>1] = $33;
  24097. $$1221 = $34;
  24098. }
  24099. $36 = (($$1284) + 1)|0;
  24100. $exitcond315 = ($36|0)==($4|0);
  24101. if ($exitcond315) {
  24102. $$0220$lcssa = $$1221;
  24103. break;
  24104. } else {
  24105. $$0220283 = $$1221;$$1284 = $36;
  24106. }
  24107. }
  24108. } else {
  24109. $$0220$lcssa = 0;
  24110. }
  24111. switch ($6|0) {
  24112. case 0: {
  24113. $57 = ($1|0)>(0);
  24114. if (!($57)) {
  24115. STACKTOP = sp;return;
  24116. }
  24117. $58 = ($4|0)>(0);
  24118. $$2239 = 0;
  24119. while(1) {
  24120. $59 = Math_imul($$2239, $4)|0;
  24121. if ($58) {
  24122. $$1212238 = 0;
  24123. while(1) {
  24124. $60 = (($$1212238) + ($59))|0;
  24125. $61 = (($3) + ($60<<2)|0);
  24126. $62 = +HEAPF32[$61>>2];
  24127. $63 = (+_stbir__saturate($62));
  24128. $64 = $63 * 255.0;
  24129. $65 = $64;
  24130. $66 = $65 + 0.5;
  24131. $67 = (~~(($66)));
  24132. $68 = $67&255;
  24133. $69 = (($2) + ($60)|0);
  24134. HEAP8[$69>>0] = $68;
  24135. $70 = (($$1212238) + 1)|0;
  24136. $exitcond = ($70|0)==($4|0);
  24137. if ($exitcond) {
  24138. break;
  24139. } else {
  24140. $$1212238 = $70;
  24141. }
  24142. }
  24143. }
  24144. $71 = (($$2239) + 1)|0;
  24145. $exitcond300 = ($71|0)==($1|0);
  24146. if ($exitcond300) {
  24147. break;
  24148. } else {
  24149. $$2239 = $71;
  24150. }
  24151. }
  24152. STACKTOP = sp;return;
  24153. break;
  24154. }
  24155. case 1: {
  24156. $55 = ($1|0)>(0);
  24157. if (!($55)) {
  24158. STACKTOP = sp;return;
  24159. }
  24160. $56 = ($$0220$lcssa|0)>(0);
  24161. $$3245 = 0;
  24162. while(1) {
  24163. $72 = Math_imul($$3245, $4)|0;
  24164. if ($56) {
  24165. $$2213241 = 0;
  24166. while(1) {
  24167. $73 = (($7) + ($$2213241<<1)|0);
  24168. $74 = HEAP16[$73>>1]|0;
  24169. $75 = $74&65535;
  24170. $76 = (($75) + ($72))|0;
  24171. $77 = (($3) + ($76<<2)|0);
  24172. $78 = +HEAPF32[$77>>2];
  24173. $79 = (_stbir__linear_to_srgb_uchar($78)|0);
  24174. $80 = (($2) + ($76)|0);
  24175. HEAP8[$80>>0] = $79;
  24176. $81 = (($$2213241) + 1)|0;
  24177. $exitcond301 = ($81|0)==($$0220$lcssa|0);
  24178. if ($exitcond301) {
  24179. break;
  24180. } else {
  24181. $$2213241 = $81;
  24182. }
  24183. }
  24184. }
  24185. $82 = HEAP32[$8>>2]|0;
  24186. $83 = $82 & 2;
  24187. $84 = ($83|0)==(0);
  24188. if ($84) {
  24189. $85 = (($72) + ($5))|0;
  24190. $86 = (($3) + ($85<<2)|0);
  24191. $87 = +HEAPF32[$86>>2];
  24192. $88 = (+_stbir__saturate($87));
  24193. $89 = $88 * 255.0;
  24194. $90 = $89;
  24195. $91 = $90 + 0.5;
  24196. $92 = (~~(($91)));
  24197. $93 = $92&255;
  24198. $94 = (($2) + ($85)|0);
  24199. HEAP8[$94>>0] = $93;
  24200. }
  24201. $95 = (($$3245) + 1)|0;
  24202. $exitcond302 = ($95|0)==($1|0);
  24203. if ($exitcond302) {
  24204. break;
  24205. } else {
  24206. $$3245 = $95;
  24207. }
  24208. }
  24209. STACKTOP = sp;return;
  24210. break;
  24211. }
  24212. case 2: {
  24213. $53 = ($1|0)>(0);
  24214. if (!($53)) {
  24215. STACKTOP = sp;return;
  24216. }
  24217. $54 = ($4|0)>(0);
  24218. $$4251 = 0;
  24219. while(1) {
  24220. $96 = Math_imul($$4251, $4)|0;
  24221. if ($54) {
  24222. $$3214247 = 0;
  24223. while(1) {
  24224. $97 = (($$3214247) + ($96))|0;
  24225. $98 = (($3) + ($97<<2)|0);
  24226. $99 = +HEAPF32[$98>>2];
  24227. $100 = (+_stbir__saturate($99));
  24228. $101 = $100 * 65535.0;
  24229. $102 = $101;
  24230. $103 = $102 + 0.5;
  24231. $104 = (~~(($103)));
  24232. $105 = $104&65535;
  24233. $106 = (($2) + ($97<<1)|0);
  24234. HEAP16[$106>>1] = $105;
  24235. $107 = (($$3214247) + 1)|0;
  24236. $exitcond303 = ($107|0)==($4|0);
  24237. if ($exitcond303) {
  24238. break;
  24239. } else {
  24240. $$3214247 = $107;
  24241. }
  24242. }
  24243. }
  24244. $108 = (($$4251) + 1)|0;
  24245. $exitcond304 = ($108|0)==($1|0);
  24246. if ($exitcond304) {
  24247. break;
  24248. } else {
  24249. $$4251 = $108;
  24250. }
  24251. }
  24252. STACKTOP = sp;return;
  24253. break;
  24254. }
  24255. case 3: {
  24256. $48 = ($1|0)>(0);
  24257. if (!($48)) {
  24258. STACKTOP = sp;return;
  24259. }
  24260. $49 = ($$0220$lcssa|0)>(0);
  24261. $50 = HEAP32[$8>>2]|0;
  24262. $51 = $50 & 2;
  24263. $52 = ($51|0)==(0);
  24264. $$5257 = 0;
  24265. while(1) {
  24266. $109 = Math_imul($$5257, $4)|0;
  24267. if ($49) {
  24268. $$4215253 = 0;
  24269. while(1) {
  24270. $110 = (($7) + ($$4215253<<1)|0);
  24271. $111 = HEAP16[$110>>1]|0;
  24272. $112 = $111&65535;
  24273. $113 = (($112) + ($109))|0;
  24274. $114 = (($3) + ($113<<2)|0);
  24275. $115 = +HEAPF32[$114>>2];
  24276. $116 = (+_stbir__saturate($115));
  24277. $117 = (+_stbir__linear_to_srgb($116));
  24278. $118 = $117 * 65535.0;
  24279. $119 = $118;
  24280. $120 = $119 + 0.5;
  24281. $121 = (~~(($120)));
  24282. $122 = $121&65535;
  24283. $123 = (($2) + ($113<<1)|0);
  24284. HEAP16[$123>>1] = $122;
  24285. $124 = (($$4215253) + 1)|0;
  24286. $exitcond305 = ($124|0)==($$0220$lcssa|0);
  24287. if ($exitcond305) {
  24288. break;
  24289. } else {
  24290. $$4215253 = $124;
  24291. }
  24292. }
  24293. }
  24294. if ($52) {
  24295. $125 = (($109) + ($5))|0;
  24296. $126 = (($3) + ($125<<2)|0);
  24297. $127 = +HEAPF32[$126>>2];
  24298. $128 = (+_stbir__saturate($127));
  24299. $129 = $128 * 65535.0;
  24300. $130 = $129;
  24301. $131 = $130 + 0.5;
  24302. $132 = (~~(($131)));
  24303. $133 = $132&65535;
  24304. $134 = (($2) + ($125<<1)|0);
  24305. HEAP16[$134>>1] = $133;
  24306. }
  24307. $135 = (($$5257) + 1)|0;
  24308. $exitcond306 = ($135|0)==($1|0);
  24309. if ($exitcond306) {
  24310. break;
  24311. } else {
  24312. $$5257 = $135;
  24313. }
  24314. }
  24315. STACKTOP = sp;return;
  24316. break;
  24317. }
  24318. case 4: {
  24319. $46 = ($1|0)>(0);
  24320. if (!($46)) {
  24321. STACKTOP = sp;return;
  24322. }
  24323. $47 = ($4|0)>(0);
  24324. $$6263 = 0;
  24325. while(1) {
  24326. $136 = Math_imul($$6263, $4)|0;
  24327. if ($47) {
  24328. $$5216259 = 0;
  24329. while(1) {
  24330. $137 = (($$5216259) + ($136))|0;
  24331. $138 = (($3) + ($137<<2)|0);
  24332. $139 = +HEAPF32[$138>>2];
  24333. $140 = (+_stbir__saturate($139));
  24334. $141 = $140;
  24335. $142 = $141 * 4294967295.0;
  24336. $143 = $142 + 0.5;
  24337. $144 = (~~(($143))>>>0);
  24338. $145 = (($2) + ($137<<2)|0);
  24339. HEAP32[$145>>2] = $144;
  24340. $146 = (($$5216259) + 1)|0;
  24341. $exitcond307 = ($146|0)==($4|0);
  24342. if ($exitcond307) {
  24343. break;
  24344. } else {
  24345. $$5216259 = $146;
  24346. }
  24347. }
  24348. }
  24349. $147 = (($$6263) + 1)|0;
  24350. $exitcond308 = ($147|0)==($1|0);
  24351. if ($exitcond308) {
  24352. break;
  24353. } else {
  24354. $$6263 = $147;
  24355. }
  24356. }
  24357. STACKTOP = sp;return;
  24358. break;
  24359. }
  24360. case 5: {
  24361. $44 = ($1|0)>(0);
  24362. if (!($44)) {
  24363. STACKTOP = sp;return;
  24364. }
  24365. $45 = ($$0220$lcssa|0)>(0);
  24366. $$7269 = 0;
  24367. while(1) {
  24368. $148 = Math_imul($$7269, $4)|0;
  24369. if ($45) {
  24370. $$6217265 = 0;
  24371. while(1) {
  24372. $149 = (($7) + ($$6217265<<1)|0);
  24373. $150 = HEAP16[$149>>1]|0;
  24374. $151 = $150&65535;
  24375. $152 = (($151) + ($148))|0;
  24376. $153 = (($3) + ($152<<2)|0);
  24377. $154 = +HEAPF32[$153>>2];
  24378. $155 = (+_stbir__saturate($154));
  24379. $156 = (+_stbir__linear_to_srgb($155));
  24380. $157 = $156;
  24381. $158 = $157 * 4294967295.0;
  24382. $159 = $158 + 0.5;
  24383. $160 = (~~(($159))>>>0);
  24384. $161 = (($2) + ($152<<2)|0);
  24385. HEAP32[$161>>2] = $160;
  24386. $162 = (($$6217265) + 1)|0;
  24387. $exitcond309 = ($162|0)==($$0220$lcssa|0);
  24388. if ($exitcond309) {
  24389. break;
  24390. } else {
  24391. $$6217265 = $162;
  24392. }
  24393. }
  24394. }
  24395. $163 = HEAP32[$8>>2]|0;
  24396. $164 = $163 & 2;
  24397. $165 = ($164|0)==(0);
  24398. if ($165) {
  24399. $166 = (($148) + ($5))|0;
  24400. $167 = (($3) + ($166<<2)|0);
  24401. $168 = +HEAPF32[$167>>2];
  24402. $169 = (+_stbir__saturate($168));
  24403. $170 = $169;
  24404. $171 = $170 * 4294967295.0;
  24405. $172 = $171 + 0.5;
  24406. $173 = (~~(($172)));
  24407. $174 = (($2) + ($166<<2)|0);
  24408. HEAP32[$174>>2] = $173;
  24409. }
  24410. $175 = (($$7269) + 1)|0;
  24411. $exitcond310 = ($175|0)==($1|0);
  24412. if ($exitcond310) {
  24413. break;
  24414. } else {
  24415. $$7269 = $175;
  24416. }
  24417. }
  24418. STACKTOP = sp;return;
  24419. break;
  24420. }
  24421. case 6: {
  24422. $42 = ($1|0)>(0);
  24423. if (!($42)) {
  24424. STACKTOP = sp;return;
  24425. }
  24426. $43 = ($4|0)>(0);
  24427. $$8275 = 0;
  24428. while(1) {
  24429. $176 = Math_imul($$8275, $4)|0;
  24430. if ($43) {
  24431. $$7218271 = 0;
  24432. while(1) {
  24433. $177 = (($$7218271) + ($176))|0;
  24434. $178 = (($3) + ($177<<2)|0);
  24435. $179 = HEAP32[$178>>2]|0;
  24436. $180 = (($2) + ($177<<2)|0);
  24437. HEAP32[$180>>2] = $179;
  24438. $181 = (($$7218271) + 1)|0;
  24439. $exitcond311 = ($181|0)==($4|0);
  24440. if ($exitcond311) {
  24441. break;
  24442. } else {
  24443. $$7218271 = $181;
  24444. }
  24445. }
  24446. }
  24447. $182 = (($$8275) + 1)|0;
  24448. $exitcond312 = ($182|0)==($1|0);
  24449. if ($exitcond312) {
  24450. break;
  24451. } else {
  24452. $$8275 = $182;
  24453. }
  24454. }
  24455. STACKTOP = sp;return;
  24456. break;
  24457. }
  24458. case 7: {
  24459. $37 = ($1|0)>(0);
  24460. if (!($37)) {
  24461. STACKTOP = sp;return;
  24462. }
  24463. $38 = ($$0220$lcssa|0)>(0);
  24464. $39 = HEAP32[$8>>2]|0;
  24465. $40 = $39 & 2;
  24466. $41 = ($40|0)==(0);
  24467. $$9281 = 0;
  24468. while(1) {
  24469. $183 = Math_imul($$9281, $4)|0;
  24470. if ($38) {
  24471. $$8219277 = 0;
  24472. while(1) {
  24473. $184 = (($7) + ($$8219277<<1)|0);
  24474. $185 = HEAP16[$184>>1]|0;
  24475. $186 = $185&65535;
  24476. $187 = (($186) + ($183))|0;
  24477. $188 = (($3) + ($187<<2)|0);
  24478. $189 = +HEAPF32[$188>>2];
  24479. $190 = (+_stbir__linear_to_srgb($189));
  24480. $191 = (($2) + ($187<<2)|0);
  24481. HEAPF32[$191>>2] = $190;
  24482. $192 = (($$8219277) + 1)|0;
  24483. $exitcond313 = ($192|0)==($$0220$lcssa|0);
  24484. if ($exitcond313) {
  24485. break;
  24486. } else {
  24487. $$8219277 = $192;
  24488. }
  24489. }
  24490. }
  24491. $193 = (($183) + ($5))|0;
  24492. if ($41) {
  24493. $194 = (($2) + ($193<<2)|0);
  24494. $195 = (($3) + ($193<<2)|0);
  24495. $196 = HEAP32[$195>>2]|0;
  24496. HEAP32[$194>>2] = $196;
  24497. }
  24498. $197 = (($$9281) + 1)|0;
  24499. $exitcond314 = ($197|0)==($1|0);
  24500. if ($exitcond314) {
  24501. break;
  24502. } else {
  24503. $$9281 = $197;
  24504. }
  24505. }
  24506. STACKTOP = sp;return;
  24507. break;
  24508. }
  24509. default: {
  24510. ___assert_fail((13319|0),(12015|0),1856,(13440|0));
  24511. // unreachable;
  24512. }
  24513. }
  24514. }
  24515. function _stbir__saturate($0) {
  24516. $0 = +$0;
  24517. var $$ = 0.0, $$0 = 0.0, $1 = 0, $2 = 0, label = 0, sp = 0;
  24518. sp = STACKTOP;
  24519. $1 = $0 < 0.0;
  24520. $2 = $0 > 1.0;
  24521. $$ = $2 ? 1.0 : $0;
  24522. $$0 = $1 ? 0.0 : $$;
  24523. return (+$$0);
  24524. }
  24525. function _stbir__linear_to_srgb_uchar($0) {
  24526. $0 = +$0;
  24527. var $$0 = 0.0, $$1 = 0.0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  24528. sp = STACKTOP;
  24529. $1 = $0 > 1.220703125E-4;
  24530. $$0 = $1 ? $0 : 1.220703125E-4;
  24531. $2 = $$0 > 0.99999994039535522;
  24532. $$1 = $2 ? 0.99999994039535522 : $$0;
  24533. $3 = (HEAPF32[tempDoublePtr>>2]=$$1,HEAP32[tempDoublePtr>>2]|0);
  24534. $4 = (($3) + -956301312)|0;
  24535. $5 = $4 >>> 20;
  24536. $6 = (4176 + ($5<<2)|0);
  24537. $7 = HEAP32[$6>>2]|0;
  24538. $8 = $7 >>> 16;
  24539. $9 = $8 << 9;
  24540. $10 = $7 & 65535;
  24541. $11 = $3 >>> 12;
  24542. $12 = $11 & 255;
  24543. $13 = Math_imul($10, $12)|0;
  24544. $14 = (($9) + ($13))|0;
  24545. $15 = $14 >>> 16;
  24546. $16 = $15&255;
  24547. return ($16|0);
  24548. }
  24549. function _stbir__linear_to_srgb($0) {
  24550. $0 = +$0;
  24551. var $$0 = 0.0, $1 = 0, $2 = 0.0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0.0, label = 0, sp = 0;
  24552. sp = STACKTOP;
  24553. $1 = !($0 <= 0.0031308000907301903);
  24554. if ($1) {
  24555. $3 = $0;
  24556. $4 = (+Math_pow((+$3),0.4166666567325592));
  24557. $5 = $4;
  24558. $6 = $5 * 1.0549999475479126;
  24559. $7 = $6 + -0.054999999701976776;
  24560. $$0 = $7;
  24561. return (+$$0);
  24562. } else {
  24563. $2 = $0 * 12.920000076293945;
  24564. $$0 = $2;
  24565. return (+$$0);
  24566. }
  24567. return +(0.0);
  24568. }
  24569. function _stbir__support_zero($0) {
  24570. $0 = +$0;
  24571. var label = 0, sp = 0;
  24572. sp = STACKTOP;
  24573. return +0;
  24574. }
  24575. function _stbir__filter_trapezoid($0,$1) {
  24576. $0 = +$0;
  24577. $1 = +$1;
  24578. var $$1 = 0.0, $2 = 0.0, $3 = 0.0, $4 = 0, $5 = 0, $6 = 0.0, $7 = 0, $8 = 0.0, $9 = 0.0, $fabsf = 0.0, label = 0, sp = 0;
  24579. sp = STACKTOP;
  24580. $2 = $1 * 0.5;
  24581. $3 = $2 + 0.5;
  24582. $4 = !($1 <= 1.0);
  24583. if ($4) {
  24584. ___assert_fail((13463|0),(12015|0),757,(13499|0));
  24585. // unreachable;
  24586. }
  24587. $fabsf = (+Math_abs((+$0)));
  24588. $5 = !($fabsf >= $3);
  24589. if (!($5)) {
  24590. $$1 = 0.0;
  24591. return (+$$1);
  24592. }
  24593. $6 = 0.5 - $2;
  24594. $7 = !($fabsf <= $6);
  24595. if (!($7)) {
  24596. $$1 = 1.0;
  24597. return (+$$1);
  24598. }
  24599. $8 = $3 - $fabsf;
  24600. $9 = $8 / $1;
  24601. $$1 = $9;
  24602. return (+$$1);
  24603. }
  24604. function _stbir__support_trapezoid($0) {
  24605. $0 = +$0;
  24606. var $1 = 0, $2 = 0.0, $3 = 0.0, label = 0, sp = 0;
  24607. sp = STACKTOP;
  24608. $1 = !($0 <= 1.0);
  24609. if ($1) {
  24610. ___assert_fail((13463|0),(12015|0),775,(13474|0));
  24611. // unreachable;
  24612. } else {
  24613. $2 = $0 * 0.5;
  24614. $3 = $2 + 0.5;
  24615. return (+$3);
  24616. }
  24617. return +(0.0);
  24618. }
  24619. function _stbir__filter_triangle($0,$1) {
  24620. $0 = +$0;
  24621. $1 = +$1;
  24622. var $$0 = 0.0, $2 = 0, $3 = 0.0, $fabsf = 0.0, label = 0, sp = 0;
  24623. sp = STACKTOP;
  24624. $fabsf = (+Math_abs((+$0)));
  24625. $2 = !($fabsf <= 1.0);
  24626. $3 = 1.0 - $fabsf;
  24627. $$0 = $2 ? 0.0 : $3;
  24628. return (+$$0);
  24629. }
  24630. function _stbir__support_one($0) {
  24631. $0 = +$0;
  24632. var label = 0, sp = 0;
  24633. sp = STACKTOP;
  24634. return +1;
  24635. }
  24636. function _stbir__filter_cubic($0,$1) {
  24637. $0 = +$0;
  24638. $1 = +$1;
  24639. var $$0 = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $14 = 0.0, $15 = 0.0, $2 = 0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0.0, $9 = 0, $fabsf = 0.0, label = 0, sp = 0;
  24640. sp = STACKTOP;
  24641. $fabsf = (+Math_abs((+$0)));
  24642. $2 = $fabsf < 1.0;
  24643. if ($2) {
  24644. $3 = $fabsf * $fabsf;
  24645. $4 = $fabsf * 3.0;
  24646. $5 = $4 + -6.0;
  24647. $6 = $3 * $5;
  24648. $7 = $6 + 4.0;
  24649. $8 = $7 / 6.0;
  24650. $$0 = $8;
  24651. return (+$$0);
  24652. }
  24653. $9 = $fabsf < 2.0;
  24654. if (!($9)) {
  24655. $$0 = 0.0;
  24656. return (+$$0);
  24657. }
  24658. $10 = 6.0 - $fabsf;
  24659. $11 = $fabsf * $10;
  24660. $12 = $11 + -12.0;
  24661. $13 = $fabsf * $12;
  24662. $14 = $13 + 8.0;
  24663. $15 = $14 / 6.0;
  24664. $$0 = $15;
  24665. return (+$$0);
  24666. }
  24667. function _stbir__support_two($0) {
  24668. $0 = +$0;
  24669. var label = 0, sp = 0;
  24670. sp = STACKTOP;
  24671. return +2;
  24672. }
  24673. function _stbir__filter_catmullrom($0,$1) {
  24674. $0 = +$0;
  24675. $1 = +$1;
  24676. var $$0 = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $14 = 0.0, $2 = 0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0, $9 = 0.0, $fabsf = 0.0, label = 0, sp = 0;
  24677. sp = STACKTOP;
  24678. $fabsf = (+Math_abs((+$0)));
  24679. $2 = $fabsf < 1.0;
  24680. if ($2) {
  24681. $3 = $fabsf * $fabsf;
  24682. $4 = $fabsf * 1.5;
  24683. $5 = 2.5 - $4;
  24684. $6 = $3 * $5;
  24685. $7 = 1.0 - $6;
  24686. $$0 = $7;
  24687. return (+$$0);
  24688. }
  24689. $8 = $fabsf < 2.0;
  24690. if (!($8)) {
  24691. $$0 = 0.0;
  24692. return (+$$0);
  24693. }
  24694. $9 = $fabsf * 0.5;
  24695. $10 = $9 + -2.5;
  24696. $11 = $fabsf * $10;
  24697. $12 = $11 + 4.0;
  24698. $13 = $fabsf * $12;
  24699. $14 = 2.0 - $13;
  24700. $$0 = $14;
  24701. return (+$$0);
  24702. }
  24703. function _stbir__filter_mitchell($0,$1) {
  24704. $0 = +$0;
  24705. $1 = +$1;
  24706. var $$0 = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $14 = 0.0, $15 = 0.0, $16 = 0.0, $2 = 0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0.0, $9 = 0, $fabsf = 0.0, label = 0, sp = 0;
  24707. sp = STACKTOP;
  24708. $fabsf = (+Math_abs((+$0)));
  24709. $2 = $fabsf < 1.0;
  24710. if ($2) {
  24711. $3 = $fabsf * $fabsf;
  24712. $4 = $fabsf * 21.0;
  24713. $5 = $4 + -36.0;
  24714. $6 = $3 * $5;
  24715. $7 = $6 + 16.0;
  24716. $8 = $7 / 18.0;
  24717. $$0 = $8;
  24718. return (+$$0);
  24719. }
  24720. $9 = $fabsf < 2.0;
  24721. if (!($9)) {
  24722. $$0 = 0.0;
  24723. return (+$$0);
  24724. }
  24725. $10 = $fabsf * 7.0;
  24726. $11 = 36.0 - $10;
  24727. $12 = $fabsf * $11;
  24728. $13 = $12 + -60.0;
  24729. $14 = $fabsf * $13;
  24730. $15 = $14 + 32.0;
  24731. $16 = $15 / 18.0;
  24732. $$0 = $16;
  24733. return (+$$0);
  24734. }
  24735. function _stbir__calculate_sample_range_upsample($0,$1,$2,$3,$4,$5,$6) {
  24736. $0 = $0|0;
  24737. $1 = +$1;
  24738. $2 = +$2;
  24739. $3 = +$3;
  24740. $4 = $4|0;
  24741. $5 = $5|0;
  24742. $6 = $6|0;
  24743. var $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0.0, $14 = 0.0, $15 = 0.0, $16 = 0.0, $17 = 0.0, $18 = 0.0, $19 = 0.0, $20 = 0, $21 = 0.0, $22 = 0.0, $23 = 0.0, $24 = 0, $7 = 0.0, $8 = 0.0, $9 = 0.0, label = 0, sp = 0;
  24744. sp = STACKTOP;
  24745. $7 = (+($0|0));
  24746. $8 = $7 + 0.5;
  24747. $9 = $8 - $1;
  24748. $10 = $8 + $1;
  24749. $11 = $9 + $3;
  24750. $12 = $11 / $2;
  24751. $13 = $10 + $3;
  24752. $14 = $13 / $2;
  24753. $15 = $8 + $3;
  24754. $16 = $15 / $2;
  24755. HEAPF32[$6>>2] = $16;
  24756. $17 = $12;
  24757. $18 = $17 + 0.5;
  24758. $19 = (+Math_floor((+$18)));
  24759. $20 = (~~(($19)));
  24760. HEAP32[$4>>2] = $20;
  24761. $21 = $14;
  24762. $22 = $21 + -0.5;
  24763. $23 = (+Math_floor((+$22)));
  24764. $24 = (~~(($23)));
  24765. HEAP32[$5>>2] = $24;
  24766. return;
  24767. }
  24768. function _stbir__decode_and_resample_upsample($0,$1) {
  24769. $0 = $0|0;
  24770. $1 = $1|0;
  24771. var $2 = 0, $3 = 0, $4 = 0, label = 0, sp = 0;
  24772. sp = STACKTOP;
  24773. _stbir__decode_scanline($0,$1);
  24774. $2 = (_stbir__use_width_upsampling($0)|0);
  24775. $3 = ($2|0)==(0);
  24776. $4 = (_stbir__add_empty_ring_buffer_entry($0,$1)|0);
  24777. if ($3) {
  24778. _stbir__resample_horizontal_downsample($0,$4);
  24779. return;
  24780. } else {
  24781. _stbir__resample_horizontal_upsample($0,$4);
  24782. return;
  24783. }
  24784. }
  24785. function _stbir__resample_vertical_upsample($0,$1) {
  24786. $0 = $0|0;
  24787. $1 = $1|0;
  24788. var $$0278305 = 0, $$0279310 = 0, $$0284309 = 0, $$0297 = 0, $$1280317 = 0, $$1285316 = 0, $$1312 = 0, $$2281324 = 0, $$2286323 = 0, $$2319 = 0, $$3282331 = 0, $$3287330 = 0, $$3326 = 0, $$4283303 = 0, $$4288302 = 0, $$4298 = 0, $10 = 0, $100 = 0, $101 = 0.0, $102 = 0.0;
  24789. var $103 = 0, $104 = 0.0, $105 = 0.0, $106 = 0, $107 = 0, $108 = 0.0, $109 = 0.0, $11 = 0, $110 = 0, $111 = 0.0, $112 = 0.0, $113 = 0, $114 = 0, $115 = 0.0, $116 = 0.0, $117 = 0, $118 = 0.0, $119 = 0.0, $12 = 0, $120 = 0;
  24790. var $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0.0, $128 = 0, $129 = 0, $13 = 0, $130 = 0.0, $131 = 0.0, $132 = 0, $133 = 0.0, $134 = 0.0, $135 = 0, $136 = 0, $137 = 0.0, $138 = 0.0, $139 = 0;
  24791. var $14 = 0, $140 = 0.0, $141 = 0.0, $142 = 0, $143 = 0, $144 = 0.0, $145 = 0.0, $146 = 0, $147 = 0.0, $148 = 0.0, $149 = 0, $15 = 0, $150 = 0, $151 = 0.0, $152 = 0.0, $153 = 0, $154 = 0.0, $155 = 0.0, $156 = 0, $157 = 0;
  24792. var $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0.0, $164 = 0, $165 = 0, $166 = 0, $167 = 0.0, $168 = 0.0, $169 = 0, $17 = 0, $170 = 0.0, $171 = 0.0, $172 = 0, $173 = 0, $174 = 0, $175 = 0;
  24793. var $176 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0;
  24794. var $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0;
  24795. var $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0.0, $63 = 0, $64 = 0.0, $65 = 0.0, $66 = 0, $67 = 0.0, $68 = 0.0, $69 = 0, $7 = 0, $70 = 0;
  24796. var $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0.0, $77 = 0, $78 = 0, $79 = 0.0, $8 = 0, $80 = 0.0, $81 = 0, $82 = 0.0, $83 = 0.0, $84 = 0, $85 = 0, $86 = 0.0, $87 = 0.0, $88 = 0, $89 = 0.0;
  24797. var $9 = 0, $90 = 0.0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0.0, $99 = 0, $exitcond = 0, $exitcond337 = 0, $exitcond338 = 0, $exitcond339 = 0, $exitcond340 = 0, $exitcond341 = 0, label = 0, sp = 0;
  24798. sp = STACKTOP;
  24799. $2 = ((($0)) + 20|0);
  24800. $3 = HEAP32[$2>>2]|0;
  24801. $4 = ((($0)) + 108|0);
  24802. $5 = HEAP32[$4>>2]|0;
  24803. $6 = ((($0)) + 112|0);
  24804. $7 = HEAP32[$6>>2]|0;
  24805. $8 = ((($0)) + 64|0);
  24806. $9 = HEAP32[$8>>2]|0;
  24807. $10 = ((($0)) + 68|0);
  24808. $11 = HEAP32[$10>>2]|0;
  24809. $12 = ((($0)) + 76|0);
  24810. $13 = HEAP32[$12>>2]|0;
  24811. $14 = ((($0)) + 96|0);
  24812. $15 = HEAP32[$14>>2]|0;
  24813. $16 = ((($0)) + 164|0);
  24814. $17 = HEAP32[$16>>2]|0;
  24815. $18 = ((($0)) + 16|0);
  24816. $19 = HEAP32[$18>>2]|0;
  24817. $20 = ((($0)) + 184|0);
  24818. $21 = HEAP32[$20>>2]|0;
  24819. $22 = $13 << 1;
  24820. $23 = (($22) + ($15))|0;
  24821. $24 = ((($0)) + 132|0);
  24822. $25 = HEAP32[$24>>2]|0;
  24823. $26 = ((($0)) + 180|0);
  24824. $27 = HEAP32[$26>>2]|0;
  24825. $28 = ((($0)) + 176|0);
  24826. $29 = HEAP32[$28>>2]|0;
  24827. $30 = ((($0)) + 168|0);
  24828. $31 = HEAP32[$30>>2]|0;
  24829. $32 = ((($0)) + 160|0);
  24830. $33 = HEAP32[$32>>2]|0;
  24831. $34 = $33 >>> 2;
  24832. $35 = Math_imul($25, $1)|0;
  24833. $36 = (($5) + ($1<<3)|0);
  24834. $37 = HEAP32[$36>>2]|0;
  24835. $38 = (((($5) + ($1<<3)|0)) + 4|0);
  24836. $39 = HEAP32[$38>>2]|0;
  24837. $40 = ((($0)) + 28|0);
  24838. $41 = HEAP32[$40>>2]|0;
  24839. $42 = Math_imul($41, $1)|0;
  24840. $43 = (_stbir__use_height_upsampling($0)|0);
  24841. $44 = ($43|0)==(0);
  24842. if ($44) {
  24843. ___assert_fail((13523|0),(12015|0),1892,(13672|0));
  24844. // unreachable;
  24845. }
  24846. $45 = $3 << 2;
  24847. $46 = Math_imul($45, $9)|0;
  24848. _memset(($21|0),0,($46|0))|0;
  24849. switch ($9|0) {
  24850. case 1: {
  24851. $53 = ($37|0)>($39|0);
  24852. if ($53) {
  24853. $176 = (($19) + ($42)|0);
  24854. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  24855. return;
  24856. }
  24857. $54 = ($3|0)>(0);
  24858. $$0279310 = $37;$$0284309 = 0;
  24859. while(1) {
  24860. $58 = (($$0284309) + 1)|0;
  24861. $59 = (_stbir__get_ring_buffer_scanline($$0279310,$27,$29,$31,$17,$34)|0);
  24862. $60 = (($$0284309) + ($35))|0;
  24863. $61 = (($7) + ($60<<2)|0);
  24864. $62 = +HEAPF32[$61>>2];
  24865. if ($54) {
  24866. $$0278305 = 0;
  24867. while(1) {
  24868. $63 = (($59) + ($$0278305<<2)|0);
  24869. $64 = +HEAPF32[$63>>2];
  24870. $65 = $62 * $64;
  24871. $66 = (($21) + ($$0278305<<2)|0);
  24872. $67 = +HEAPF32[$66>>2];
  24873. $68 = $67 + $65;
  24874. HEAPF32[$66>>2] = $68;
  24875. $69 = (($$0278305) + 1)|0;
  24876. $exitcond338 = ($69|0)==($3|0);
  24877. if ($exitcond338) {
  24878. break;
  24879. } else {
  24880. $$0278305 = $69;
  24881. }
  24882. }
  24883. }
  24884. $70 = (($$0279310) + 1)|0;
  24885. $71 = ($$0279310|0)<($39|0);
  24886. if ($71) {
  24887. $$0279310 = $70;$$0284309 = $58;
  24888. } else {
  24889. break;
  24890. }
  24891. }
  24892. $176 = (($19) + ($42)|0);
  24893. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  24894. return;
  24895. break;
  24896. }
  24897. case 2: {
  24898. $51 = ($37|0)>($39|0);
  24899. if ($51) {
  24900. $176 = (($19) + ($42)|0);
  24901. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  24902. return;
  24903. }
  24904. $52 = ($3|0)>(0);
  24905. $$1280317 = $37;$$1285316 = 0;
  24906. while(1) {
  24907. $72 = (($$1285316) + 1)|0;
  24908. $73 = (_stbir__get_ring_buffer_scanline($$1280317,$27,$29,$31,$17,$34)|0);
  24909. $74 = (($$1285316) + ($35))|0;
  24910. $75 = (($7) + ($74<<2)|0);
  24911. $76 = +HEAPF32[$75>>2];
  24912. if ($52) {
  24913. $$1312 = 0;
  24914. while(1) {
  24915. $77 = $$1312 << 1;
  24916. $78 = (($73) + ($77<<2)|0);
  24917. $79 = +HEAPF32[$78>>2];
  24918. $80 = $76 * $79;
  24919. $81 = (($21) + ($77<<2)|0);
  24920. $82 = +HEAPF32[$81>>2];
  24921. $83 = $82 + $80;
  24922. HEAPF32[$81>>2] = $83;
  24923. $84 = $77 | 1;
  24924. $85 = (($73) + ($84<<2)|0);
  24925. $86 = +HEAPF32[$85>>2];
  24926. $87 = $76 * $86;
  24927. $88 = (($21) + ($84<<2)|0);
  24928. $89 = +HEAPF32[$88>>2];
  24929. $90 = $89 + $87;
  24930. HEAPF32[$88>>2] = $90;
  24931. $91 = (($$1312) + 1)|0;
  24932. $exitcond339 = ($91|0)==($3|0);
  24933. if ($exitcond339) {
  24934. break;
  24935. } else {
  24936. $$1312 = $91;
  24937. }
  24938. }
  24939. }
  24940. $92 = (($$1280317) + 1)|0;
  24941. $93 = ($$1280317|0)<($39|0);
  24942. if ($93) {
  24943. $$1280317 = $92;$$1285316 = $72;
  24944. } else {
  24945. break;
  24946. }
  24947. }
  24948. $176 = (($19) + ($42)|0);
  24949. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  24950. return;
  24951. break;
  24952. }
  24953. case 3: {
  24954. $49 = ($37|0)>($39|0);
  24955. if ($49) {
  24956. $176 = (($19) + ($42)|0);
  24957. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  24958. return;
  24959. }
  24960. $50 = ($3|0)>(0);
  24961. $$2281324 = $37;$$2286323 = 0;
  24962. while(1) {
  24963. $94 = (($$2286323) + 1)|0;
  24964. $95 = (_stbir__get_ring_buffer_scanline($$2281324,$27,$29,$31,$17,$34)|0);
  24965. $96 = (($$2286323) + ($35))|0;
  24966. $97 = (($7) + ($96<<2)|0);
  24967. $98 = +HEAPF32[$97>>2];
  24968. if ($50) {
  24969. $$2319 = 0;
  24970. while(1) {
  24971. $99 = ($$2319*3)|0;
  24972. $100 = (($95) + ($99<<2)|0);
  24973. $101 = +HEAPF32[$100>>2];
  24974. $102 = $98 * $101;
  24975. $103 = (($21) + ($99<<2)|0);
  24976. $104 = +HEAPF32[$103>>2];
  24977. $105 = $104 + $102;
  24978. HEAPF32[$103>>2] = $105;
  24979. $106 = (($99) + 1)|0;
  24980. $107 = (($95) + ($106<<2)|0);
  24981. $108 = +HEAPF32[$107>>2];
  24982. $109 = $98 * $108;
  24983. $110 = (($21) + ($106<<2)|0);
  24984. $111 = +HEAPF32[$110>>2];
  24985. $112 = $111 + $109;
  24986. HEAPF32[$110>>2] = $112;
  24987. $113 = (($99) + 2)|0;
  24988. $114 = (($95) + ($113<<2)|0);
  24989. $115 = +HEAPF32[$114>>2];
  24990. $116 = $98 * $115;
  24991. $117 = (($21) + ($113<<2)|0);
  24992. $118 = +HEAPF32[$117>>2];
  24993. $119 = $118 + $116;
  24994. HEAPF32[$117>>2] = $119;
  24995. $120 = (($$2319) + 1)|0;
  24996. $exitcond340 = ($120|0)==($3|0);
  24997. if ($exitcond340) {
  24998. break;
  24999. } else {
  25000. $$2319 = $120;
  25001. }
  25002. }
  25003. }
  25004. $121 = (($$2281324) + 1)|0;
  25005. $122 = ($$2281324|0)<($39|0);
  25006. if ($122) {
  25007. $$2281324 = $121;$$2286323 = $94;
  25008. } else {
  25009. break;
  25010. }
  25011. }
  25012. $176 = (($19) + ($42)|0);
  25013. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  25014. return;
  25015. break;
  25016. }
  25017. case 4: {
  25018. $47 = ($37|0)>($39|0);
  25019. if ($47) {
  25020. $176 = (($19) + ($42)|0);
  25021. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  25022. return;
  25023. }
  25024. $48 = ($3|0)>(0);
  25025. $$3282331 = $37;$$3287330 = 0;
  25026. while(1) {
  25027. $123 = (($$3287330) + 1)|0;
  25028. $124 = (_stbir__get_ring_buffer_scanline($$3282331,$27,$29,$31,$17,$34)|0);
  25029. $125 = (($$3287330) + ($35))|0;
  25030. $126 = (($7) + ($125<<2)|0);
  25031. $127 = +HEAPF32[$126>>2];
  25032. if ($48) {
  25033. $$3326 = 0;
  25034. while(1) {
  25035. $128 = $$3326 << 2;
  25036. $129 = (($124) + ($128<<2)|0);
  25037. $130 = +HEAPF32[$129>>2];
  25038. $131 = $127 * $130;
  25039. $132 = (($21) + ($128<<2)|0);
  25040. $133 = +HEAPF32[$132>>2];
  25041. $134 = $133 + $131;
  25042. HEAPF32[$132>>2] = $134;
  25043. $135 = $128 | 1;
  25044. $136 = (($124) + ($135<<2)|0);
  25045. $137 = +HEAPF32[$136>>2];
  25046. $138 = $127 * $137;
  25047. $139 = (($21) + ($135<<2)|0);
  25048. $140 = +HEAPF32[$139>>2];
  25049. $141 = $140 + $138;
  25050. HEAPF32[$139>>2] = $141;
  25051. $142 = $128 | 2;
  25052. $143 = (($124) + ($142<<2)|0);
  25053. $144 = +HEAPF32[$143>>2];
  25054. $145 = $127 * $144;
  25055. $146 = (($21) + ($142<<2)|0);
  25056. $147 = +HEAPF32[$146>>2];
  25057. $148 = $147 + $145;
  25058. HEAPF32[$146>>2] = $148;
  25059. $149 = $128 | 3;
  25060. $150 = (($124) + ($149<<2)|0);
  25061. $151 = +HEAPF32[$150>>2];
  25062. $152 = $127 * $151;
  25063. $153 = (($21) + ($149<<2)|0);
  25064. $154 = +HEAPF32[$153>>2];
  25065. $155 = $154 + $152;
  25066. HEAPF32[$153>>2] = $155;
  25067. $156 = (($$3326) + 1)|0;
  25068. $exitcond341 = ($156|0)==($3|0);
  25069. if ($exitcond341) {
  25070. break;
  25071. } else {
  25072. $$3326 = $156;
  25073. }
  25074. }
  25075. }
  25076. $157 = (($$3282331) + 1)|0;
  25077. $158 = ($$3282331|0)<($39|0);
  25078. if ($158) {
  25079. $$3282331 = $157;$$3287330 = $123;
  25080. } else {
  25081. break;
  25082. }
  25083. }
  25084. $176 = (($19) + ($42)|0);
  25085. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  25086. return;
  25087. break;
  25088. }
  25089. default: {
  25090. $55 = ($37|0)>($39|0);
  25091. if ($55) {
  25092. $176 = (($19) + ($42)|0);
  25093. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  25094. return;
  25095. }
  25096. $56 = ($3|0)>(0);
  25097. $57 = ($9|0)>(0);
  25098. $$4283303 = $37;$$4288302 = 0;
  25099. while(1) {
  25100. $159 = (($$4288302) + 1)|0;
  25101. $160 = (_stbir__get_ring_buffer_scanline($$4283303,$27,$29,$31,$17,$34)|0);
  25102. $161 = (($$4288302) + ($35))|0;
  25103. $162 = (($7) + ($161<<2)|0);
  25104. $163 = +HEAPF32[$162>>2];
  25105. if ($56) {
  25106. $$4298 = 0;
  25107. while(1) {
  25108. $164 = Math_imul($$4298, $9)|0;
  25109. if ($57) {
  25110. $$0297 = 0;
  25111. while(1) {
  25112. $165 = (($$0297) + ($164))|0;
  25113. $166 = (($160) + ($165<<2)|0);
  25114. $167 = +HEAPF32[$166>>2];
  25115. $168 = $163 * $167;
  25116. $169 = (($21) + ($165<<2)|0);
  25117. $170 = +HEAPF32[$169>>2];
  25118. $171 = $170 + $168;
  25119. HEAPF32[$169>>2] = $171;
  25120. $172 = (($$0297) + 1)|0;
  25121. $exitcond = ($172|0)==($9|0);
  25122. if ($exitcond) {
  25123. break;
  25124. } else {
  25125. $$0297 = $172;
  25126. }
  25127. }
  25128. }
  25129. $173 = (($$4298) + 1)|0;
  25130. $exitcond337 = ($173|0)==($3|0);
  25131. if ($exitcond337) {
  25132. break;
  25133. } else {
  25134. $$4298 = $173;
  25135. }
  25136. }
  25137. }
  25138. $174 = (($$4283303) + 1)|0;
  25139. $175 = ($$4283303|0)<($39|0);
  25140. if ($175) {
  25141. $$4283303 = $174;$$4288302 = $159;
  25142. } else {
  25143. break;
  25144. }
  25145. }
  25146. $176 = (($19) + ($42)|0);
  25147. _stbir__encode_scanline($0,$3,$176,$21,$9,$11,$23);
  25148. return;
  25149. }
  25150. }
  25151. }
  25152. function _stbir__get_contributors($0,$1,$2,$3) {
  25153. $0 = +$0;
  25154. $1 = $1|0;
  25155. $2 = $2|0;
  25156. $3 = $3|0;
  25157. var $$0 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, label = 0, sp = 0;
  25158. sp = STACKTOP;
  25159. $4 = (_stbir__use_upsampling($0)|0);
  25160. $5 = ($4|0)==(0);
  25161. if (!($5)) {
  25162. $$0 = $3;
  25163. return ($$0|0);
  25164. }
  25165. $6 = (_stbir__get_filter_pixel_margin($1,$0)|0);
  25166. $7 = $6 << 1;
  25167. $8 = (($7) + ($2))|0;
  25168. $$0 = $8;
  25169. return ($$0|0);
  25170. }
  25171. function _stbir__get_contributor($0,$1) {
  25172. $0 = $0|0;
  25173. $1 = $1|0;
  25174. var $2 = 0, label = 0, sp = 0;
  25175. sp = STACKTOP;
  25176. $2 = (($0) + ($1<<3)|0);
  25177. return ($2|0);
  25178. }
  25179. function _stbir__get_coefficient($0,$1,$2,$3,$4) {
  25180. $0 = $0|0;
  25181. $1 = $1|0;
  25182. $2 = +$2;
  25183. $3 = $3|0;
  25184. $4 = $4|0;
  25185. var $5 = 0, $6 = 0, $7 = 0, $8 = 0, label = 0, sp = 0;
  25186. sp = STACKTOP;
  25187. $5 = (_stbir__get_coefficient_width($1,$2)|0);
  25188. $6 = Math_imul($5, $3)|0;
  25189. $7 = (($6) + ($4))|0;
  25190. $8 = (($0) + ($7<<2)|0);
  25191. return ($8|0);
  25192. }
  25193. function _stbir__calculate_coefficients_upsample($0,$1,$2,$3,$4,$5,$6) {
  25194. $0 = $0|0;
  25195. $1 = +$1;
  25196. $2 = $2|0;
  25197. $3 = $3|0;
  25198. $4 = +$4;
  25199. $5 = $5|0;
  25200. $6 = $6|0;
  25201. var $$06175 = 0, $$06274 = 0, $$064$lcssa = 0.0, $$06473 = 0.0, $$1 = 0, $$163 = 0, $$165 = 0.0, $$270 = 0, $$368 = 0, $$lcssa = 0, $$lcssa67 = 0, $10 = 0.0, $11 = 0.0, $12 = 0.0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0;
  25202. var $19 = 0, $20 = 0, $21 = 0, $22 = 0.0, $23 = 0.0, $24 = 0.0, $25 = 0, $26 = 0.0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0.0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0.0;
  25203. var $39 = 0.0, $40 = 0.0, $41 = 0.0, $42 = 0, $43 = 0.0, $44 = 0, $45 = 0, $46 = 0.0, $47 = 0, $48 = 0, $49 = 0, $50 = 0.0, $51 = 0.0, $52 = 0, $53 = 0, $54 = 0.0, $55 = 0, $56 = 0, $57 = 0, $58 = 0;
  25204. var $59 = 0, $60 = 0, $7 = 0, $8 = 0, $9 = 0, $ceilf = 0.0, $exitcond = 0, $or$cond = 0, label = 0, sp = 0;
  25205. sp = STACKTOP;
  25206. $7 = (($3) - ($2))|0;
  25207. $8 = (((3104 + ($0<<3)|0)) + 4|0);
  25208. $9 = HEAP32[$8>>2]|0;
  25209. $10 = 1.0 / $1;
  25210. $11 = (+FUNCTION_TABLE_dd[$9 & 7]($10));
  25211. $12 = $11 * 2.0;
  25212. $ceilf = (+Math_ceil((+$12)));
  25213. $13 = (~~(($ceilf)));
  25214. $14 = ($7|0)>($13|0);
  25215. if ($14) {
  25216. ___assert_fail((14067|0),(12015|0),1038,(14166|0));
  25217. // unreachable;
  25218. }
  25219. HEAP32[$5>>2] = $2;
  25220. $15 = ((($5)) + 4|0);
  25221. HEAP32[$15>>2] = $3;
  25222. $16 = ($3|0)<($2|0);
  25223. if ($16) {
  25224. ___assert_fail((13919|0),(12015|0),1043,(14166|0));
  25225. // unreachable;
  25226. }
  25227. $17 = (($3) - ($2))|0;
  25228. $18 = ($17|0)<(0);
  25229. $19 = (3104 + ($0<<3)|0);
  25230. $20 = HEAP32[$19>>2]|0;
  25231. if ($18) {
  25232. $$064$lcssa = 0.0;$$lcssa = $20;$$lcssa67 = $17;
  25233. } else {
  25234. $$06175 = $2;$$06274 = 0;$$06473 = 0.0;$25 = $20;
  25235. while(1) {
  25236. $21 = (($$06175) + ($$06274))|0;
  25237. $22 = (+($21|0));
  25238. $23 = $22 + 0.5;
  25239. $24 = $4 - $23;
  25240. $26 = (+FUNCTION_TABLE_ddd[$25 & 7]($24,$10));
  25241. $27 = (($6) + ($$06274<<2)|0);
  25242. HEAPF32[$27>>2] = $26;
  25243. $28 = ($$06274|0)!=(0);
  25244. $29 = $26 != 0.0;
  25245. $or$cond = $28 | $29;
  25246. if ($or$cond) {
  25247. $32 = $$06473 + $26;
  25248. $$1 = $$06175;$$163 = $$06274;$$165 = $32;
  25249. } else {
  25250. $30 = (($$06175) + 1)|0;
  25251. HEAP32[$5>>2] = $30;
  25252. $31 = (($$06274) + -1)|0;
  25253. $$1 = $30;$$163 = $31;$$165 = $$06473;
  25254. }
  25255. $33 = (($$163) + 1)|0;
  25256. $34 = (($3) - ($$1))|0;
  25257. $35 = ($$163|0)<($34|0);
  25258. $36 = HEAP32[$19>>2]|0;
  25259. if ($35) {
  25260. $$06175 = $$1;$$06274 = $33;$$06473 = $$165;$25 = $36;
  25261. } else {
  25262. $$064$lcssa = $$165;$$lcssa = $36;$$lcssa67 = $34;
  25263. break;
  25264. }
  25265. }
  25266. }
  25267. $37 = (($3) + 1)|0;
  25268. $38 = (+($37|0));
  25269. $39 = $38 + 0.5;
  25270. $40 = $39 - $4;
  25271. $41 = (+FUNCTION_TABLE_ddd[$$lcssa & 7]($40,$10));
  25272. $42 = $41 == 0.0;
  25273. if (!($42)) {
  25274. ___assert_fail((14205|0),(12015|0),1061,(14166|0));
  25275. // unreachable;
  25276. }
  25277. $43 = $$064$lcssa;
  25278. $44 = $43 > 0.90000000000000002;
  25279. if (!($44)) {
  25280. ___assert_fail((14313|0),(12015|0),1063,(14166|0));
  25281. // unreachable;
  25282. }
  25283. $45 = $$064$lcssa < 1.1000000238418579;
  25284. if (!($45)) {
  25285. ___assert_fail((14332|0),(12015|0),1064,(14166|0));
  25286. // unreachable;
  25287. }
  25288. $46 = 1.0 / $$064$lcssa;
  25289. $47 = ($$lcssa67|0)<(0);
  25290. if ($47) {
  25291. return;
  25292. } else {
  25293. $$270 = 0;
  25294. }
  25295. while(1) {
  25296. $49 = (($6) + ($$270<<2)|0);
  25297. $50 = +HEAPF32[$49>>2];
  25298. $51 = $46 * $50;
  25299. HEAPF32[$49>>2] = $51;
  25300. $52 = (($$270) + 1)|0;
  25301. $exitcond = ($$270|0)==($$lcssa67|0);
  25302. if ($exitcond) {
  25303. break;
  25304. } else {
  25305. $$270 = $52;
  25306. }
  25307. }
  25308. $48 = ($$lcssa67|0)>(-1);
  25309. if ($48) {
  25310. $$368 = $$lcssa67;
  25311. } else {
  25312. return;
  25313. }
  25314. while(1) {
  25315. $53 = (($6) + ($$368<<2)|0);
  25316. $54 = +HEAPF32[$53>>2];
  25317. $55 = $54 != 0.0;
  25318. if ($55) {
  25319. label = 21;
  25320. break;
  25321. }
  25322. $56 = HEAP32[$5>>2]|0;
  25323. $57 = (($$368) + -1)|0;
  25324. $58 = (($57) + ($56))|0;
  25325. HEAP32[$15>>2] = $58;
  25326. $59 = (($$368) + -1)|0;
  25327. $60 = ($$368|0)>(0);
  25328. if ($60) {
  25329. $$368 = $59;
  25330. } else {
  25331. label = 21;
  25332. break;
  25333. }
  25334. }
  25335. if ((label|0) == 21) {
  25336. return;
  25337. }
  25338. }
  25339. function _stbir__calculate_coefficients_downsample($0,$1,$2,$3,$4,$5,$6) {
  25340. $0 = $0|0;
  25341. $1 = +$1;
  25342. $2 = $2|0;
  25343. $3 = $3|0;
  25344. $4 = +$4;
  25345. $5 = $5|0;
  25346. $6 = $6|0;
  25347. var $$044 = 0, $$142 = 0, $$lcssa = 0, $10 = 0.0, $11 = 0.0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0.0, $23 = 0.0, $24 = 0.0, $25 = 0, $26 = 0.0;
  25348. var $27 = 0.0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0.0, $33 = 0.0, $34 = 0.0, $35 = 0.0, $36 = 0, $37 = 0, $38 = 0, $39 = 0.0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $7 = 0;
  25349. var $8 = 0, $9 = 0, $ceilf = 0.0, $exitcond = 0, label = 0, sp = 0;
  25350. sp = STACKTOP;
  25351. $7 = (($3) - ($2))|0;
  25352. $8 = (((3104 + ($0<<3)|0)) + 4|0);
  25353. $9 = HEAP32[$8>>2]|0;
  25354. $10 = (+FUNCTION_TABLE_dd[$9 & 7]($1));
  25355. $11 = $10 * 2.0;
  25356. $ceilf = (+Math_ceil((+$11)));
  25357. $12 = (~~(($ceilf)));
  25358. $13 = ($7|0)>($12|0);
  25359. if ($13) {
  25360. ___assert_fail((13773|0),(12015|0),1086,(13878|0));
  25361. // unreachable;
  25362. }
  25363. HEAP32[$5>>2] = $2;
  25364. $14 = ((($5)) + 4|0);
  25365. HEAP32[$14>>2] = $3;
  25366. $15 = ($3|0)<($2|0);
  25367. if ($15) {
  25368. ___assert_fail((13919|0),(12015|0),1091,(13878|0));
  25369. // unreachable;
  25370. }
  25371. $16 = ($7|0)<(0);
  25372. $17 = (3104 + ($0<<3)|0);
  25373. $18 = HEAP32[$17>>2]|0;
  25374. if ($16) {
  25375. $$lcssa = $18;
  25376. } else {
  25377. $19 = (($3) + 1)|0;
  25378. $20 = (($19) - ($2))|0;
  25379. $$044 = 0;$25 = $18;
  25380. while(1) {
  25381. $21 = (($$044) + ($2))|0;
  25382. $22 = (+($21|0));
  25383. $23 = $22 + 0.5;
  25384. $24 = $23 - $4;
  25385. $26 = (+FUNCTION_TABLE_ddd[$25 & 7]($24,$1));
  25386. $27 = $26 * $1;
  25387. $28 = (($6) + ($$044<<2)|0);
  25388. HEAPF32[$28>>2] = $27;
  25389. $29 = (($$044) + 1)|0;
  25390. $30 = HEAP32[$17>>2]|0;
  25391. $exitcond = ($29|0)==($20|0);
  25392. if ($exitcond) {
  25393. $$lcssa = $30;
  25394. break;
  25395. } else {
  25396. $$044 = $29;$25 = $30;
  25397. }
  25398. }
  25399. }
  25400. $31 = (($3) + 1)|0;
  25401. $32 = (+($31|0));
  25402. $33 = $32 + 0.5;
  25403. $34 = $33 - $4;
  25404. $35 = (+FUNCTION_TABLE_ddd[$$lcssa & 7]($34,$1));
  25405. $36 = $35 == 0.0;
  25406. if (!($36)) {
  25407. ___assert_fail((13954|0),(12015|0),1100,(13878|0));
  25408. // unreachable;
  25409. }
  25410. $37 = ($7|0)>(-1);
  25411. if ($37) {
  25412. $$142 = $7;
  25413. } else {
  25414. return;
  25415. }
  25416. while(1) {
  25417. $38 = (($6) + ($$142<<2)|0);
  25418. $39 = +HEAPF32[$38>>2];
  25419. $40 = $39 != 0.0;
  25420. if ($40) {
  25421. label = 13;
  25422. break;
  25423. }
  25424. $41 = HEAP32[$5>>2]|0;
  25425. $42 = (($$142) + -1)|0;
  25426. $43 = (($42) + ($41))|0;
  25427. HEAP32[$14>>2] = $43;
  25428. $44 = (($$142) + -1)|0;
  25429. $45 = ($$142|0)>(0);
  25430. if ($45) {
  25431. $$142 = $44;
  25432. } else {
  25433. label = 13;
  25434. break;
  25435. }
  25436. }
  25437. if ((label|0) == 13) {
  25438. return;
  25439. }
  25440. }
  25441. function _stbir__normalize_downsample_coefficients($0,$1,$2,$3,$4,$5) {
  25442. $0 = $0|0;
  25443. $1 = $1|0;
  25444. $2 = $2|0;
  25445. $3 = +$3;
  25446. $4 = $4|0;
  25447. $5 = $5|0;
  25448. var $$ = 0, $$$0123 = 0, $$0120148 = 0, $$0123 = 0, $$0125$lcssa = 0.0, $$0125147 = 0.0, $$0157 = 0, $$1121153 = 0, $$1126 = 0.0, $$1140 = 0, $$2122145 = 0, $$2133 = 0, $$op = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0;
  25449. var $17 = 0, $18 = 0, $19 = 0, $20 = 0.0, $21 = 0.0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0.0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0.0, $36 = 0.0;
  25450. var $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0.0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0;
  25451. var $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $8 = 0, $9 = 0, $exitcond = 0, $exitcond160 = 0;
  25452. var label = 0, sp = 0;
  25453. sp = STACKTOP;
  25454. $6 = (_stbir__get_contributors($3,$2,$4,$5)|0);
  25455. $7 = (_stbir__get_coefficient_width($2,$3)|0);
  25456. $8 = ($5|0)>(0);
  25457. L1: do {
  25458. if ($8) {
  25459. $9 = ($6|0)>(0);
  25460. $10 = ($6|0)>(0);
  25461. $$0157 = 0;
  25462. while(1) {
  25463. if ($9) {
  25464. $$0120148 = 0;$$0125147 = 0.0;
  25465. } else {
  25466. label = 10;
  25467. break;
  25468. }
  25469. while(1) {
  25470. $12 = (($0) + ($$0120148<<3)|0);
  25471. $13 = HEAP32[$12>>2]|0;
  25472. $14 = ($$0157|0)<($13|0);
  25473. if ($14) {
  25474. $$0125$lcssa = $$0125147;
  25475. break;
  25476. }
  25477. $15 = (((($0) + ($$0120148<<3)|0)) + 4|0);
  25478. $16 = HEAP32[$15>>2]|0;
  25479. $17 = ($$0157|0)>($16|0);
  25480. if ($17) {
  25481. $$1126 = $$0125147;
  25482. } else {
  25483. $18 = (($$0157) - ($13))|0;
  25484. $19 = (_stbir__get_coefficient($1,$2,$3,$$0120148,$18)|0);
  25485. $20 = +HEAPF32[$19>>2];
  25486. $21 = $$0125147 + $20;
  25487. $$1126 = $21;
  25488. }
  25489. $22 = (($$0120148) + 1)|0;
  25490. $23 = ($22|0)<($6|0);
  25491. if ($23) {
  25492. $$0120148 = $22;$$0125147 = $$1126;
  25493. } else {
  25494. $$0125$lcssa = $$1126;
  25495. break;
  25496. }
  25497. }
  25498. $24 = $$0125$lcssa > 0.89999997615814208;
  25499. if (!($24)) {
  25500. label = 10;
  25501. break;
  25502. }
  25503. $25 = $$0125$lcssa < 1.1000000238418579;
  25504. if (!($25)) {
  25505. label = 12;
  25506. break;
  25507. }
  25508. $26 = 1.0 / $$0125$lcssa;
  25509. L14: do {
  25510. if ($10) {
  25511. $$1121153 = 0;
  25512. while(1) {
  25513. $27 = (($0) + ($$1121153<<3)|0);
  25514. $28 = HEAP32[$27>>2]|0;
  25515. $29 = ($$0157|0)<($28|0);
  25516. if ($29) {
  25517. break L14;
  25518. }
  25519. $30 = (((($0) + ($$1121153<<3)|0)) + 4|0);
  25520. $31 = HEAP32[$30>>2]|0;
  25521. $32 = ($$0157|0)>($31|0);
  25522. if (!($32)) {
  25523. $33 = (($$0157) - ($28))|0;
  25524. $34 = (_stbir__get_coefficient($1,$2,$3,$$1121153,$33)|0);
  25525. $35 = +HEAPF32[$34>>2];
  25526. $36 = $26 * $35;
  25527. HEAPF32[$34>>2] = $36;
  25528. }
  25529. $37 = (($$1121153) + 1)|0;
  25530. $38 = ($37|0)<($6|0);
  25531. if ($38) {
  25532. $$1121153 = $37;
  25533. } else {
  25534. break;
  25535. }
  25536. }
  25537. }
  25538. } while(0);
  25539. $39 = (($$0157) + 1)|0;
  25540. $40 = ($39|0)<($5|0);
  25541. if ($40) {
  25542. $$0157 = $39;
  25543. } else {
  25544. break L1;
  25545. }
  25546. }
  25547. if ((label|0) == 10) {
  25548. ___assert_fail((13706|0),(12015|0),1135,(13719|0));
  25549. // unreachable;
  25550. }
  25551. else if ((label|0) == 12) {
  25552. ___assert_fail((13760|0),(12015|0),1136,(13719|0));
  25553. // unreachable;
  25554. }
  25555. }
  25556. } while(0);
  25557. $11 = ($6|0)>(0);
  25558. if ($11) {
  25559. $$2122145 = 0;
  25560. } else {
  25561. return;
  25562. }
  25563. while(1) {
  25564. $$0123 = 0;
  25565. while(1) {
  25566. $43 = (_stbir__get_coefficient($1,$2,$3,$$2122145,$$0123)|0);
  25567. $44 = +HEAPF32[$43>>2];
  25568. $45 = $44 == 0.0;
  25569. $46 = (($$0123) + 1)|0;
  25570. if ($45) {
  25571. $$0123 = $46;
  25572. } else {
  25573. break;
  25574. }
  25575. }
  25576. $47 = (($0) + ($$2122145<<3)|0);
  25577. $48 = HEAP32[$47>>2]|0;
  25578. $49 = (($48) + ($$0123))|0;
  25579. $50 = ($49|0)<(0);
  25580. $51 = (0 - ($48))|0;
  25581. $$ = $50 ? 0 : $49;
  25582. $$$0123 = $50 ? $51 : $$0123;
  25583. HEAP32[$47>>2] = $$;
  25584. $52 = (((($0) + ($$2122145<<3)|0)) + 4|0);
  25585. $53 = HEAP32[$52>>2]|0;
  25586. $$op = (1 - ($49))|0;
  25587. $54 = $50 ? 1 : $$op;
  25588. $55 = (($54) + ($53))|0;
  25589. $56 = (_stbir__min($7,$55)|0);
  25590. $57 = (_stbir__get_coefficient_width($2,$3)|0);
  25591. $58 = ($56|0)>(0);
  25592. L34: do {
  25593. if ($58) {
  25594. $$1140 = 0;
  25595. while(1) {
  25596. $59 = (($$1140) + ($$$0123))|0;
  25597. $60 = ($59|0)<($57|0);
  25598. if (!($60)) {
  25599. break L34;
  25600. }
  25601. $61 = (_stbir__get_coefficient($1,$2,$3,$$2122145,$59)|0);
  25602. $62 = HEAP32[$61>>2]|0;
  25603. $63 = (_stbir__get_coefficient($1,$2,$3,$$2122145,$$1140)|0);
  25604. HEAP32[$63>>2] = $62;
  25605. $64 = (($$1140) + 1)|0;
  25606. $65 = ($64|0)<($56|0);
  25607. if ($65) {
  25608. $$1140 = $64;
  25609. } else {
  25610. break;
  25611. }
  25612. }
  25613. }
  25614. } while(0);
  25615. $66 = (($$2122145) + 1)|0;
  25616. $exitcond160 = ($66|0)==($6|0);
  25617. if ($exitcond160) {
  25618. break;
  25619. } else {
  25620. $$2122145 = $66;
  25621. }
  25622. }
  25623. $41 = ($6|0)>(0);
  25624. if (!($41)) {
  25625. return;
  25626. }
  25627. $42 = (($5) + -1)|0;
  25628. $$2133 = 0;
  25629. while(1) {
  25630. $67 = (((($0) + ($$2133<<3)|0)) + 4|0);
  25631. $68 = HEAP32[$67>>2]|0;
  25632. $69 = (_stbir__min($68,$42)|0);
  25633. HEAP32[$67>>2] = $69;
  25634. $70 = (($$2133) + 1)|0;
  25635. $exitcond = ($70|0)==($6|0);
  25636. if ($exitcond) {
  25637. break;
  25638. } else {
  25639. $$2133 = $70;
  25640. }
  25641. }
  25642. return;
  25643. }
  25644. function _stbir__min($0,$1) {
  25645. $0 = $0|0;
  25646. $1 = $1|0;
  25647. var $2 = 0, $3 = 0, label = 0, sp = 0;
  25648. sp = STACKTOP;
  25649. $2 = ($0|0)<($1|0);
  25650. $3 = $2 ? $0 : $1;
  25651. return ($3|0);
  25652. }
  25653. function _stbir__get_total_horizontal_coefficients($0) {
  25654. $0 = $0|0;
  25655. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0.0, $7 = 0, $8 = 0, label = 0, sp = 0;
  25656. sp = STACKTOP;
  25657. $1 = ((($0)) + 152|0);
  25658. $2 = HEAP32[$1>>2]|0;
  25659. $3 = ((($0)) + 80|0);
  25660. $4 = HEAP32[$3>>2]|0;
  25661. $5 = ((($0)) + 56|0);
  25662. $6 = +HEAPF32[$5>>2];
  25663. $7 = (_stbir__get_coefficient_width($4,$6)|0);
  25664. $8 = Math_imul($7, $2)|0;
  25665. return ($8|0);
  25666. }
  25667. function _stbir__get_total_vertical_coefficients($0) {
  25668. $0 = $0|0;
  25669. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0.0, $7 = 0, $8 = 0, label = 0, sp = 0;
  25670. sp = STACKTOP;
  25671. $1 = ((($0)) + 156|0);
  25672. $2 = HEAP32[$1>>2]|0;
  25673. $3 = ((($0)) + 84|0);
  25674. $4 = HEAP32[$3>>2]|0;
  25675. $5 = ((($0)) + 60|0);
  25676. $6 = +HEAPF32[$5>>2];
  25677. $7 = (_stbir__get_coefficient_width($4,$6)|0);
  25678. $8 = Math_imul($7, $2)|0;
  25679. return ($8|0);
  25680. }
  25681. function _LoadImage($0,$1) {
  25682. $0 = $0|0;
  25683. $1 = $1|0;
  25684. var $$sink = 0, $$sroa$0$0 = 0, $$sroa$0$0$copyload = 0, $$sroa$0$1 = 0, $$sroa$0$144 = 0, $$sroa$10$0 = 0, $$sroa$10$0$$sroa_idx19 = 0, $$sroa$10$0$$sroa_idx20 = 0, $$sroa$10$0$copyload = 0, $$sroa$10$1 = 0, $$sroa$10$140 = 0, $$sroa$10$141 = 0, $$sroa$13$0 = 0, $$sroa$13$0$$sroa_idx23 = 0, $$sroa$13$0$$sroa_idx24 = 0, $$sroa$13$0$copyload = 0, $$sroa$13$1 = 0, $$sroa$13$146 = 0, $$sroa$13$147 = 0, $$sroa$15$0 = 0;
  25685. var $$sroa$15$0$$sroa_idx27 = 0, $$sroa$15$0$$sroa_idx28 = 0, $$sroa$15$0$copyload = 0, $$sroa$15$1 = 0, $$sroa$15$2 = 0, $$sroa$15$248 = 0, $$sroa$15$249 = 0, $$sroa$7$0 = 0, $$sroa$7$0$$sroa_idx15 = 0, $$sroa$7$0$$sroa_idx16 = 0, $$sroa$7$0$copyload = 0, $$sroa$7$1 = 0, $$sroa$7$142 = 0, $$sroa$7$143 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0;
  25686. var $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0;
  25687. var $vararg_buffer1 = 0, $vararg_buffer4 = 0, $vararg_buffer9 = 0, $vararg_ptr7 = 0, $vararg_ptr8 = 0, label = 0, sp = 0;
  25688. sp = STACKTOP;
  25689. STACKTOP = STACKTOP + 80|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(80|0);
  25690. $vararg_buffer9 = sp + 32|0;
  25691. $vararg_buffer4 = sp + 16|0;
  25692. $vararg_buffer1 = sp + 8|0;
  25693. $vararg_buffer = sp;
  25694. $2 = sp + 48|0;
  25695. $3 = sp + 44|0;
  25696. $4 = sp + 40|0;
  25697. $5 = sp + 36|0;
  25698. $6 = (_IsFileExtension($1,14558)|0);
  25699. $7 = ($6|0)==(0);
  25700. do {
  25701. if ($7) {
  25702. $19 = (_IsFileExtension($1,14611)|0);
  25703. $20 = ($19|0)==(0);
  25704. if ($20) {
  25705. HEAP32[$vararg_buffer1>>2] = $1;
  25706. _TraceLog(2,14616,$vararg_buffer1);
  25707. $$sroa$10$141 = 0;$$sroa$13$147 = 0;$$sroa$15$249 = 0;$$sroa$7$143 = 0;
  25708. break;
  25709. }
  25710. HEAP32[$3>>2] = 0;
  25711. HEAP32[$4>>2] = 0;
  25712. HEAP32[$5>>2] = 0;
  25713. $21 = (_fopen($1,14750)|0);
  25714. $22 = (_stbi_load_from_file($21,$3,$4,$5,0)|0);
  25715. (_fclose($21)|0);
  25716. $23 = HEAP32[$3>>2]|0;
  25717. $24 = HEAP32[$4>>2]|0;
  25718. $25 = HEAP32[$5>>2]|0;
  25719. switch ($25|0) {
  25720. case 1: {
  25721. $$sink = 1;
  25722. label = 11;
  25723. break;
  25724. }
  25725. case 2: {
  25726. $$sink = 2;
  25727. label = 11;
  25728. break;
  25729. }
  25730. case 3: {
  25731. $$sink = 4;
  25732. label = 11;
  25733. break;
  25734. }
  25735. case 4: {
  25736. $$sink = 7;
  25737. label = 11;
  25738. break;
  25739. }
  25740. default: {
  25741. $$sroa$15$1 = 0;
  25742. }
  25743. }
  25744. if ((label|0) == 11) {
  25745. $$sroa$15$1 = $$sink;
  25746. }
  25747. $$sroa$0$1 = $22;$$sroa$10$1 = $24;$$sroa$13$1 = 1;$$sroa$15$2 = $$sroa$15$1;$$sroa$7$1 = $23;
  25748. label = 14;
  25749. } else {
  25750. $8 = (_LoadResource($1,0)|0);
  25751. $9 = HEAP32[$8>>2]|0;
  25752. $10 = ($9|0)==(1);
  25753. if ($10) {
  25754. $11 = ((($8)) + 20|0);
  25755. $12 = HEAP32[$11>>2]|0;
  25756. $13 = ((($8)) + 4|0);
  25757. $14 = HEAP32[$13>>2]|0;
  25758. $15 = ((($8)) + 8|0);
  25759. $16 = HEAP32[$15>>2]|0;
  25760. $17 = ((($8)) + 12|0);
  25761. $18 = HEAP32[$17>>2]|0;
  25762. _LoadImagePro($2,$12,$14,$16,$18);
  25763. $$sroa$0$0$copyload = HEAP32[$2>>2]|0;
  25764. $$sroa$7$0$$sroa_idx15 = ((($2)) + 4|0);
  25765. $$sroa$7$0$copyload = HEAP32[$$sroa$7$0$$sroa_idx15>>2]|0;
  25766. $$sroa$10$0$$sroa_idx19 = ((($2)) + 8|0);
  25767. $$sroa$10$0$copyload = HEAP32[$$sroa$10$0$$sroa_idx19>>2]|0;
  25768. $$sroa$13$0$$sroa_idx23 = ((($2)) + 12|0);
  25769. $$sroa$13$0$copyload = HEAP32[$$sroa$13$0$$sroa_idx23>>2]|0;
  25770. $$sroa$15$0$$sroa_idx27 = ((($2)) + 16|0);
  25771. $$sroa$15$0$copyload = HEAP32[$$sroa$15$0$$sroa_idx27>>2]|0;
  25772. $$sroa$0$0 = $$sroa$0$0$copyload;$$sroa$10$0 = $$sroa$10$0$copyload;$$sroa$13$0 = $$sroa$13$0$copyload;$$sroa$15$0 = $$sroa$15$0$copyload;$$sroa$7$0 = $$sroa$7$0$copyload;
  25773. } else {
  25774. HEAP32[$vararg_buffer>>2] = $1;
  25775. _TraceLog(2,14564,$vararg_buffer);
  25776. $$sroa$0$0 = 0;$$sroa$10$0 = 0;$$sroa$13$0 = 0;$$sroa$15$0 = 0;$$sroa$7$0 = 0;
  25777. }
  25778. _UnloadResource($8);
  25779. $$sroa$0$1 = $$sroa$0$0;$$sroa$10$1 = $$sroa$10$0;$$sroa$13$1 = $$sroa$13$0;$$sroa$15$2 = $$sroa$15$0;$$sroa$7$1 = $$sroa$7$0;
  25780. label = 14;
  25781. }
  25782. } while(0);
  25783. if ((label|0) == 14) {
  25784. $26 = ($$sroa$0$1|0)==(0|0);
  25785. if ($26) {
  25786. $$sroa$10$141 = $$sroa$10$1;$$sroa$13$147 = $$sroa$13$1;$$sroa$15$249 = $$sroa$15$2;$$sroa$7$143 = $$sroa$7$1;
  25787. } else {
  25788. HEAP32[$vararg_buffer4>>2] = $1;
  25789. $vararg_ptr7 = ((($vararg_buffer4)) + 4|0);
  25790. HEAP32[$vararg_ptr7>>2] = $$sroa$7$1;
  25791. $vararg_ptr8 = ((($vararg_buffer4)) + 8|0);
  25792. HEAP32[$vararg_ptr8>>2] = $$sroa$10$1;
  25793. _TraceLog(0,14652,$vararg_buffer4);
  25794. $$sroa$0$144 = $$sroa$0$1;$$sroa$10$140 = $$sroa$10$1;$$sroa$13$146 = $$sroa$13$1;$$sroa$15$248 = $$sroa$15$2;$$sroa$7$142 = $$sroa$7$1;
  25795. HEAP32[$0>>2] = $$sroa$0$144;
  25796. $$sroa$7$0$$sroa_idx16 = ((($0)) + 4|0);
  25797. HEAP32[$$sroa$7$0$$sroa_idx16>>2] = $$sroa$7$142;
  25798. $$sroa$10$0$$sroa_idx20 = ((($0)) + 8|0);
  25799. HEAP32[$$sroa$10$0$$sroa_idx20>>2] = $$sroa$10$140;
  25800. $$sroa$13$0$$sroa_idx24 = ((($0)) + 12|0);
  25801. HEAP32[$$sroa$13$0$$sroa_idx24>>2] = $$sroa$13$146;
  25802. $$sroa$15$0$$sroa_idx28 = ((($0)) + 16|0);
  25803. HEAP32[$$sroa$15$0$$sroa_idx28>>2] = $$sroa$15$248;
  25804. STACKTOP = sp;return;
  25805. }
  25806. }
  25807. HEAP32[$vararg_buffer9>>2] = $1;
  25808. _TraceLog(2,14691,$vararg_buffer9);
  25809. $$sroa$0$144 = 0;$$sroa$10$140 = $$sroa$10$141;$$sroa$13$146 = $$sroa$13$147;$$sroa$15$248 = $$sroa$15$249;$$sroa$7$142 = $$sroa$7$143;
  25810. HEAP32[$0>>2] = $$sroa$0$144;
  25811. $$sroa$7$0$$sroa_idx16 = ((($0)) + 4|0);
  25812. HEAP32[$$sroa$7$0$$sroa_idx16>>2] = $$sroa$7$142;
  25813. $$sroa$10$0$$sroa_idx20 = ((($0)) + 8|0);
  25814. HEAP32[$$sroa$10$0$$sroa_idx20>>2] = $$sroa$10$140;
  25815. $$sroa$13$0$$sroa_idx24 = ((($0)) + 12|0);
  25816. HEAP32[$$sroa$13$0$$sroa_idx24>>2] = $$sroa$13$146;
  25817. $$sroa$15$0$$sroa_idx28 = ((($0)) + 16|0);
  25818. HEAP32[$$sroa$15$0$$sroa_idx28>>2] = $$sroa$15$248;
  25819. STACKTOP = sp;return;
  25820. }
  25821. function _LoadResource($0,$1) {
  25822. $0 = $0|0;
  25823. $1 = $1|0;
  25824. var $$0$lcssa = 0, $$05665 = 0, $$05764 = 0, $$1 = 0, $$2 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  25825. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  25826. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0;
  25827. var $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond60 = 0;
  25828. var $or$cond62 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer4 = 0, $vararg_buffer8 = 0, $vararg_ptr11 = 0, $vararg_ptr7 = 0, label = 0, sp = 0;
  25829. sp = STACKTOP;
  25830. STACKTOP = STACKTOP + 80|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(80|0);
  25831. $vararg_buffer8 = sp + 24|0;
  25832. $vararg_buffer4 = sp + 16|0;
  25833. $vararg_buffer1 = sp + 8|0;
  25834. $vararg_buffer = sp;
  25835. $2 = sp + 64|0;
  25836. $3 = sp + 32|0;
  25837. $4 = (_fopen($0,14750)|0);
  25838. $5 = ($4|0)==(0|0);
  25839. if ($5) {
  25840. HEAP32[$vararg_buffer>>2] = $0;
  25841. _TraceLog(2,14753,$vararg_buffer);
  25842. $$2 = 0;
  25843. STACKTOP = sp;return ($$2|0);
  25844. }
  25845. (_fread($2,1,1,$4)|0);
  25846. $6 = ((($2)) + 1|0);
  25847. (_fread($6,1,1,$4)|0);
  25848. $7 = ((($2)) + 2|0);
  25849. (_fread($7,1,1,$4)|0);
  25850. $8 = ((($2)) + 3|0);
  25851. (_fread($8,1,1,$4)|0);
  25852. $9 = ((($2)) + 4|0);
  25853. (_fread($9,2,1,$4)|0);
  25854. $10 = ((($2)) + 6|0);
  25855. (_fread($10,2,1,$4)|0);
  25856. $11 = HEAP8[$2>>0]|0;
  25857. $12 = ($11<<24>>24)==(114);
  25858. $13 = HEAP8[$6>>0]|0;
  25859. $14 = ($13<<24>>24)==(82);
  25860. $or$cond = $12 | $14;
  25861. $15 = HEAP8[$7>>0]|0;
  25862. $16 = ($15<<24>>24)==(69);
  25863. $or$cond60 = $or$cond | $16;
  25864. $17 = HEAP8[$8>>0]|0;
  25865. $18 = ($17<<24>>24)==(83);
  25866. $or$cond62 = $or$cond60 | $18;
  25867. if ($or$cond62) {
  25868. $19 = HEAP16[$10>>1]|0;
  25869. $20 = ($19<<16>>16)==(0);
  25870. if ($20) {
  25871. $$0$lcssa = 0;
  25872. } else {
  25873. $21 = ((($3)) + 7|0);
  25874. $22 = HEAP16[$10>>1]|0;
  25875. $23 = $22&65535;
  25876. $24 = ((($3)) + 8|0);
  25877. $25 = ((($3)) + 4|0);
  25878. $26 = ((($3)) + 16|0);
  25879. $27 = ((($3)) + 20|0);
  25880. $28 = ((($3)) + 24|0);
  25881. $29 = ((($3)) + 28|0);
  25882. $30 = ((($3)) + 8|0);
  25883. $31 = ((($3)) + 5|0);
  25884. $32 = ((($3)) + 12|0);
  25885. $$05665 = 0;
  25886. while(1) {
  25887. (_fread($3,32,1,$4)|0);
  25888. $36 = HEAP8[$21>>0]|0;
  25889. $37 = $36&255;
  25890. $38 = ($37*24)|0;
  25891. $39 = (_malloc($38)|0);
  25892. $40 = HEAP32[$3>>2]|0;
  25893. $41 = ($40|0)==($1|0);
  25894. if ($41) {
  25895. $42 = HEAP8[$21>>0]|0;
  25896. $43 = ($42<<24>>24)==(0);
  25897. if (!($43)) {
  25898. $$05764 = 0;
  25899. while(1) {
  25900. $44 = HEAP8[$25>>0]|0;
  25901. $45 = $44&255;
  25902. $46 = (($39) + (($$05764*24)|0)|0);
  25903. HEAP32[$46>>2] = $45;
  25904. $47 = HEAP32[$26>>2]|0;
  25905. $48 = (((($39) + (($$05764*24)|0)|0)) + 4|0);
  25906. HEAP32[$48>>2] = $47;
  25907. $49 = HEAP32[$27>>2]|0;
  25908. $50 = (((($39) + (($$05764*24)|0)|0)) + 8|0);
  25909. HEAP32[$50>>2] = $49;
  25910. $51 = HEAP32[$28>>2]|0;
  25911. $52 = (((($39) + (($$05764*24)|0)|0)) + 12|0);
  25912. HEAP32[$52>>2] = $51;
  25913. $53 = HEAP32[$29>>2]|0;
  25914. $54 = (((($39) + (($$05764*24)|0)|0)) + 16|0);
  25915. HEAP32[$54>>2] = $53;
  25916. $55 = HEAP32[$30>>2]|0;
  25917. $56 = (_malloc($55)|0);
  25918. (_fread($56,$55,1,$4)|0);
  25919. $57 = HEAP8[$31>>0]|0;
  25920. $58 = ($57<<24>>24)==(1);
  25921. if ($58) {
  25922. $59 = HEAP32[$30>>2]|0;
  25923. $60 = HEAP32[$32>>2]|0;
  25924. $61 = (_DecompressData($56,$59,$60)|0);
  25925. $62 = (((($39) + (($$05764*24)|0)|0)) + 20|0);
  25926. HEAP32[$62>>2] = $61;
  25927. _free($56);
  25928. } else {
  25929. $63 = (((($39) + (($$05764*24)|0)|0)) + 20|0);
  25930. HEAP32[$63>>2] = $56;
  25931. }
  25932. $64 = (((($39) + (($$05764*24)|0)|0)) + 20|0);
  25933. $65 = HEAP32[$64>>2]|0;
  25934. $66 = ($65|0)==(0|0);
  25935. if (!($66)) {
  25936. $67 = HEAP32[$3>>2]|0;
  25937. HEAP32[$vararg_buffer4>>2] = $0;
  25938. $vararg_ptr7 = ((($vararg_buffer4)) + 4|0);
  25939. HEAP32[$vararg_ptr7>>2] = $67;
  25940. _TraceLog(0,14850,$vararg_buffer4);
  25941. }
  25942. (_fread($3,32,1,$4)|0);
  25943. $68 = (($$05764) + 1)|0;
  25944. $69 = HEAP8[$21>>0]|0;
  25945. $70 = $69&255;
  25946. $71 = ($68|0)<($70|0);
  25947. if ($71) {
  25948. $$05764 = $68;
  25949. } else {
  25950. break;
  25951. }
  25952. }
  25953. }
  25954. } else {
  25955. $72 = HEAP32[$24>>2]|0;
  25956. (_fseek($4,$72,1)|0);
  25957. }
  25958. $73 = (($$05665) + 1)|0;
  25959. $74 = ($73|0)<($23|0);
  25960. if ($74) {
  25961. $$05665 = $73;
  25962. } else {
  25963. $$0$lcssa = $39;
  25964. break;
  25965. }
  25966. }
  25967. }
  25968. $33 = ((($$0$lcssa)) + 20|0);
  25969. $34 = HEAP32[$33>>2]|0;
  25970. $35 = ($34|0)==(0|0);
  25971. if ($35) {
  25972. HEAP32[$vararg_buffer8>>2] = $0;
  25973. $vararg_ptr11 = ((($vararg_buffer8)) + 4|0);
  25974. HEAP32[$vararg_ptr11>>2] = $1;
  25975. _TraceLog(2,14896,$vararg_buffer8);
  25976. $$1 = $$0$lcssa;
  25977. } else {
  25978. $$1 = $$0$lcssa;
  25979. }
  25980. } else {
  25981. HEAP32[$vararg_buffer1>>2] = $0;
  25982. _TraceLog(2,14804,$vararg_buffer1);
  25983. $$1 = 0;
  25984. }
  25985. (_fclose($4)|0);
  25986. $$2 = $$1;
  25987. STACKTOP = sp;return ($$2|0);
  25988. }
  25989. function _LoadImagePro($0,$1,$2,$3,$4) {
  25990. $0 = $0|0;
  25991. $1 = $1|0;
  25992. $2 = $2|0;
  25993. $3 = $3|0;
  25994. $4 = $4|0;
  25995. var $$byval_copy = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  25996. sp = STACKTOP;
  25997. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  25998. $$byval_copy = sp + 20|0;
  25999. $5 = sp;
  26000. HEAP32[$5>>2] = $1;
  26001. $6 = ((($5)) + 4|0);
  26002. HEAP32[$6>>2] = $2;
  26003. $7 = ((($5)) + 8|0);
  26004. HEAP32[$7>>2] = $3;
  26005. $8 = ((($5)) + 12|0);
  26006. HEAP32[$8>>2] = 1;
  26007. $9 = ((($5)) + 16|0);
  26008. HEAP32[$9>>2] = $4;
  26009. ;HEAP32[$$byval_copy>>2]=HEAP32[$5>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[$5+4>>2]|0;HEAP32[$$byval_copy+8>>2]=HEAP32[$5+8>>2]|0;HEAP32[$$byval_copy+12>>2]=HEAP32[$5+12>>2]|0;HEAP32[$$byval_copy+16>>2]=HEAP32[$5+16>>2]|0;
  26010. _ImageCopy($0,$$byval_copy);
  26011. STACKTOP = sp;return;
  26012. }
  26013. function _UnloadResource($0) {
  26014. $0 = $0|0;
  26015. var $1 = 0, $2 = 0, $3 = 0, label = 0, sp = 0;
  26016. sp = STACKTOP;
  26017. $1 = ((($0)) + 20|0);
  26018. $2 = HEAP32[$1>>2]|0;
  26019. $3 = ($2|0)==(0|0);
  26020. if ($3) {
  26021. return;
  26022. }
  26023. _free($2);
  26024. return;
  26025. }
  26026. function _ImageCopy($0,$1) {
  26027. $0 = $0|0;
  26028. $1 = $1|0;
  26029. var $$0 = 0, $$sroa$6$0 = 0, $$sroa$6$0$$sroa_idx10 = 0, $$sroa$7$0 = 0, $$sroa$7$0$$sroa_idx12 = 0, $$sroa$8$0 = 0, $$sroa$8$0$$sroa_idx14 = 0, $$sroa$9$0 = 0, $$sroa$9$0$$sroa_idx16 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0;
  26030. var $20 = 0, $21 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, label = 0, sp = 0;
  26031. sp = STACKTOP;
  26032. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  26033. $vararg_buffer = sp;
  26034. $2 = ((($1)) + 4|0);
  26035. $3 = HEAP32[$2>>2]|0;
  26036. $4 = ((($1)) + 8|0);
  26037. $5 = HEAP32[$4>>2]|0;
  26038. $6 = Math_imul($5, $3)|0;
  26039. $7 = ((($1)) + 16|0);
  26040. $8 = HEAP32[$7>>2]|0;
  26041. switch ($8|0) {
  26042. case 17: case 14: case 11: case 10: case 1: {
  26043. $$0 = $6;
  26044. break;
  26045. }
  26046. case 6: case 5: case 3: case 2: {
  26047. $9 = $6 << 1;
  26048. $$0 = $9;
  26049. break;
  26050. }
  26051. case 4: {
  26052. $10 = ($6*3)|0;
  26053. $$0 = $10;
  26054. break;
  26055. }
  26056. case 7: {
  26057. $11 = $6 << 2;
  26058. $$0 = $11;
  26059. break;
  26060. }
  26061. case 16: case 15: case 13: case 12: case 9: case 8: {
  26062. $12 = (($6|0) / 2)&-1;
  26063. $$0 = $12;
  26064. break;
  26065. }
  26066. case 18: {
  26067. $13 = (($6|0) / 4)&-1;
  26068. $$0 = $13;
  26069. break;
  26070. }
  26071. default: {
  26072. _TraceLog(2,14722,$vararg_buffer);
  26073. $$0 = $6;
  26074. }
  26075. }
  26076. $14 = (_malloc($$0)|0);
  26077. $15 = ($14|0)==(0|0);
  26078. if ($15) {
  26079. $$sroa$6$0 = 0;$$sroa$7$0 = 0;$$sroa$8$0 = 0;$$sroa$9$0 = 0;
  26080. } else {
  26081. $16 = HEAP32[$1>>2]|0;
  26082. _memcpy(($14|0),($16|0),($$0|0))|0;
  26083. $17 = HEAP32[$2>>2]|0;
  26084. $18 = HEAP32[$4>>2]|0;
  26085. $19 = ((($1)) + 12|0);
  26086. $20 = HEAP32[$19>>2]|0;
  26087. $21 = HEAP32[$7>>2]|0;
  26088. $$sroa$6$0 = $17;$$sroa$7$0 = $18;$$sroa$8$0 = $20;$$sroa$9$0 = $21;
  26089. }
  26090. HEAP32[$0>>2] = $14;
  26091. $$sroa$6$0$$sroa_idx10 = ((($0)) + 4|0);
  26092. HEAP32[$$sroa$6$0$$sroa_idx10>>2] = $$sroa$6$0;
  26093. $$sroa$7$0$$sroa_idx12 = ((($0)) + 8|0);
  26094. HEAP32[$$sroa$7$0$$sroa_idx12>>2] = $$sroa$7$0;
  26095. $$sroa$8$0$$sroa_idx14 = ((($0)) + 12|0);
  26096. HEAP32[$$sroa$8$0$$sroa_idx14>>2] = $$sroa$8$0;
  26097. $$sroa$9$0$$sroa_idx16 = ((($0)) + 16|0);
  26098. HEAP32[$$sroa$9$0$$sroa_idx16>>2] = $$sroa$9$0;
  26099. STACKTOP = sp;return;
  26100. }
  26101. function _DecompressData($0,$1,$2) {
  26102. $0 = $0|0;
  26103. $1 = $1|0;
  26104. $2 = $2|0;
  26105. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer10 = 0, $vararg_buffer3 = 0, $vararg_buffer5 = 0, $vararg_buffer7 = 0, $vararg_ptr13 = 0, label = 0, sp = 0;
  26106. sp = STACKTOP;
  26107. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  26108. $vararg_buffer10 = sp + 40|0;
  26109. $vararg_buffer7 = sp + 32|0;
  26110. $vararg_buffer5 = sp + 24|0;
  26111. $vararg_buffer3 = sp + 16|0;
  26112. $vararg_buffer1 = sp + 8|0;
  26113. $vararg_buffer = sp;
  26114. $3 = (_malloc($2)|0);
  26115. $4 = ($3|0)==(0|0);
  26116. if ($4) {
  26117. _TraceLog(2,14946,$vararg_buffer);
  26118. STACKTOP = sp;return ($3|0);
  26119. }
  26120. $5 = (_tinfl_decompress_mem_to_mem($3,$2,$0,$1,1)|0);
  26121. $6 = ($5|0)==(-1);
  26122. if ($6) {
  26123. _TraceLog(2,14985,$vararg_buffer1);
  26124. _free($3);
  26125. }
  26126. $7 = ($5|0)==($2|0);
  26127. if (!($7)) {
  26128. _TraceLog(2,15011,$vararg_buffer3);
  26129. HEAP32[$vararg_buffer5>>2] = $2;
  26130. _TraceLog(2,15074,$vararg_buffer5);
  26131. HEAP32[$vararg_buffer7>>2] = $5;
  26132. _TraceLog(2,15109,$vararg_buffer7);
  26133. }
  26134. HEAP32[$vararg_buffer10>>2] = $1;
  26135. $vararg_ptr13 = ((($vararg_buffer10)) + 4|0);
  26136. HEAP32[$vararg_ptr13>>2] = $5;
  26137. _TraceLog(0,15144,$vararg_buffer10);
  26138. STACKTOP = sp;return ($3|0);
  26139. }
  26140. function _tinfl_decompress_mem_to_mem($0,$1,$2,$3,$4) {
  26141. $0 = $0|0;
  26142. $1 = $1|0;
  26143. $2 = $2|0;
  26144. $3 = $3|0;
  26145. $4 = $4|0;
  26146. var $10 = 0, $11 = 0, $12 = 0, $13 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  26147. sp = STACKTOP;
  26148. STACKTOP = STACKTOP + 11008|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(11008|0);
  26149. $5 = sp + 11000|0;
  26150. $6 = sp;
  26151. $7 = sp + 8|0;
  26152. HEAP32[$5>>2] = $1;
  26153. HEAP32[$6>>2] = $3;
  26154. HEAP32[$7>>2] = 0;
  26155. $8 = $4 & -7;
  26156. $9 = $8 | 4;
  26157. $10 = (_tinfl_decompress($7,$2,$6,$0,$0,$5,$9)|0);
  26158. $11 = ($10|0)!=(0);
  26159. $12 = HEAP32[$5>>2]|0;
  26160. $13 = $11 ? -1 : $12;
  26161. STACKTOP = sp;return ($13|0);
  26162. }
  26163. function _tinfl_decompress($0,$1,$2,$3,$4,$5,$6) {
  26164. $0 = $0|0;
  26165. $1 = $1|0;
  26166. $2 = $2|0;
  26167. $3 = $3|0;
  26168. $4 = $4|0;
  26169. $5 = $5|0;
  26170. $6 = $6|0;
  26171. var $$ = 0, $$$301127 = 0, $$010861840 = 0, $$010871839 = 0, $$010881838 = 0, $$010911856 = 0, $$010941846 = 0, $$010951864 = 0, $$01097 = 0, $$01194 = 0, $$011971855 = 0, $$01202 = 0, $$01202$shrunk = 0, $$01203 = 0, $$01300 = 0, $$01300$shrunk = 0, $$01309 = 0, $$01410 = 0, $$01410$shrunk = 0, $$01411 = 0;
  26172. var $$01411$shrunk = 0, $$01412 = 0, $$01413 = 0, $$01413$shrunk = 0, $$01416 = 0, $$01507 = 0, $$01607 = 0, $$01834 = 0, $$0937$lcssa = 0, $$09371833 = 0, $$0938$lcssa = 0, $$09381832 = 0, $$0941$lcssa = 0, $$09411816 = 0, $$09431831 = 0, $$09441830 = 0, $$0947 = 0, $$0947$shrunk = 0, $$0948 = 0, $$0949 = 0;
  26173. var $$0950 = 0, $$0950$shrunk = 0, $$0951 = 0, $$0952 = 0, $$0952$shrunk = 0, $$0953 = 0, $$0956 = 0, $$0959 = 0, $$0959$shrunk = 0, $$0960 = 0, $$0963 = 0, $$0967 = 0, $$0971 = 0, $$0971$shrunk = 0, $$0972 = 0, $$0975 = 0, $$0978 = 0, $$0979 = 0, $$0979$shrunk = 0, $$0980 = 0;
  26174. var $$0980$shrunk = 0, $$0981 = 0, $$0984 = 0, $$0987 = 0, $$0991 = 0, $$1$lcssa = 0, $$100 = 0, $$1001409 = 0, $$101426 = 0, $$101617 = 0, $$110891852 = 0, $$11098 = 0, $$11098$ph = 0, $$111427 = 0, $$111518 = 0, $$111618 = 0, $$11198 = 0, $$11204 = 0, $$11204$ph = 0, $$11310 = 0;
  26175. var $$11310$ph = 0, $$11417 = 0, $$11508 = 0, $$11608 = 0, $$11818 = 0, $$121428 = 0, $$121428$ph = 0, $$121519 = 0, $$121619 = 0, $$121619$ph = 0, $$13 = 0, $$131004 = 0, $$131110 = 0, $$131216 = 0, $$131322 = 0, $$131429 = 0, $$131520 = 0, $$131620 = 0, $$14 = 0, $$141005 = 0;
  26176. var $$141111 = 0, $$141217 = 0, $$141323 = 0, $$141430 = 0, $$141521 = 0, $$141621 = 0, $$15 = 0, $$151006 = 0, $$151112 = 0, $$151218 = 0, $$151324 = 0, $$151431 = 0, $$151522 = 0, $$151622 = 0, $$16 = 0, $$161007 = 0, $$161113 = 0, $$161113$ph = 0, $$161219 = 0, $$161325 = 0;
  26177. var $$161432 = 0, $$161523 = 0, $$161623 = 0, $$17 = 0, $$17$ph = 0, $$171008 = 0, $$171008$ph = 0, $$171114 = 0, $$171220 = 0, $$171220$ph = 0, $$171326 = 0, $$171326$ph = 0, $$171433 = 0, $$171524 = 0, $$171624 = 0, $$1753 = 0, $$1754 = 0, $$18 = 0, $$181009 = 0, $$181115 = 0;
  26178. var $$181221 = 0, $$181327 = 0, $$181434 = 0, $$181525 = 0, $$181625 = 0, $$19 = 0, $$191010 = 0, $$191116 = 0, $$191222 = 0, $$191328 = 0, $$191435 = 0, $$191526 = 0, $$191626 = 0, $$1939$lcssa = 0, $$19391817 = 0, $$19421823 = 0, $$1945$lcssa = 0, $$19451815 = 0, $$1954 = 0, $$1957 = 0;
  26179. var $$1961 = 0, $$1961$ = 0, $$1964 = 0, $$1968 = 0, $$1973 = 0, $$1976 = 0, $$1982 = 0, $$1985 = 0, $$1988 = 0, $$1988$ph = 0, $$1992 = 0, $$1992$ph = 0, $$2$lcssa = 0, $$20 = 0, $$201011 = 0, $$201117 = 0, $$201223 = 0, $$201329 = 0, $$201436 = 0, $$201527 = 0;
  26180. var $$201627 = 0, $$21 = 0, $$21099 = 0, $$211012 = 0, $$211118 = 0, $$211224 = 0, $$211330 = 0, $$211437 = 0, $$211437$ph = 0, $$211528 = 0, $$211628 = 0, $$211628$ph = 0, $$21196 = 0, $$21199$lcssa = 0, $$211991845 = 0, $$21205 = 0, $$21311 = 0, $$21418 = 0, $$21509 = 0, $$21609 = 0;
  26181. var $$21825 = 0, $$22 = 0, $$221013 = 0, $$221119 = 0, $$221225 = 0, $$221331 = 0, $$221438 = 0, $$221529 = 0, $$221629 = 0, $$23 = 0, $$231014 = 0, $$231120 = 0, $$231226 = 0, $$231332 = 0, $$231439 = 0, $$231530 = 0, $$231630 = 0, $$24 = 0, $$241015 = 0, $$241121 = 0;
  26182. var $$241227 = 0, $$241333 = 0, $$241440 = 0, $$241531 = 0, $$241631 = 0, $$25 = 0, $$251016 = 0, $$251122 = 0, $$251122$ph = 0, $$251228 = 0, $$251334 = 0, $$251441 = 0, $$251532 = 0, $$251632 = 0, $$26 = 0, $$26$ph = 0, $$261017 = 0, $$261017$ph = 0, $$261123 = 0, $$261229 = 0;
  26183. var $$261229$ph = 0, $$261335 = 0, $$261335$ph = 0, $$261442 = 0, $$261533 = 0, $$261633 = 0, $$27 = 0, $$271018 = 0, $$271124 = 0, $$271230 = 0, $$271336 = 0, $$271443 = 0, $$271534 = 0, $$271634 = 0, $$28 = 0, $$281019 = 0, $$281125 = 0, $$281231 = 0, $$281337 = 0, $$281444 = 0;
  26184. var $$281535 = 0, $$281635 = 0, $$29 = 0, $$291020 = 0, $$291126 = 0, $$291232 = 0, $$291338 = 0, $$291445 = 0, $$291536 = 0, $$291636 = 0, $$2940$lcssa = 0, $$29401824 = 0, $$2946$lcssa = 0, $$29461822 = 0, $$2955 = 0, $$2958 = 0, $$2965 = 0, $$2969 = 0, $$2974 = 0, $$2977 = 0;
  26185. var $$2983 = 0, $$2986 = 0, $$2989 = 0, $$2993 = 0, $$30 = 0, $$301021 = 0, $$301127 = 0, $$301233 = 0, $$301339 = 0, $$301446 = 0, $$301537 = 0, $$301637 = 0, $$31 = 0, $$31100$v = 0, $$311022 = 0, $$311128 = 0, $$311234 = 0, $$311340 = 0, $$311447 = 0, $$311538 = 0;
  26186. var $$311638 = 0, $$31200 = 0, $$31206 = 0, $$31206$ph = 0, $$31312 = 0, $$31312$ph = 0, $$31419 = 0, $$31419$ph = 0, $$31610 = 0, $$31610$ph = 0, $$32 = 0, $$321023 = 0, $$321129 = 0, $$321235 = 0, $$321341 = 0, $$321448 = 0, $$321448$ph = 0, $$321539 = 0, $$321639 = 0, $$321639$ph = 0;
  26187. var $$33 = 0, $$331024 = 0, $$331130 = 0, $$331236 = 0, $$331342 = 0, $$331449 = 0, $$331540 = 0, $$331640 = 0, $$34 = 0, $$341025 = 0, $$341131 = 0, $$341237 = 0, $$341343 = 0, $$341450 = 0, $$341541 = 0, $$341641 = 0, $$35 = 0, $$351026 = 0, $$351132 = 0, $$351238 = 0;
  26188. var $$351344 = 0, $$351451 = 0, $$351542 = 0, $$351642 = 0, $$36 = 0, $$361027 = 0, $$361027$ph = 0, $$361133 = 0, $$361133$ph = 0, $$361239 = 0, $$361345 = 0, $$361452 = 0, $$361543 = 0, $$361643 = 0, $$37 = 0, $$37$ph = 0, $$371028 = 0, $$371134 = 0, $$371240 = 0, $$371240$ph = 0;
  26189. var $$371346 = 0, $$371346$ph = 0, $$371453 = 0, $$371453$ph = 0, $$371544 = 0, $$371644 = 0, $$371644$ph = 0, $$38 = 0, $$381029 = 0, $$381135 = 0, $$381241 = 0, $$381347 = 0, $$381454 = 0, $$381545 = 0, $$381645 = 0, $$39 = 0, $$391030 = 0, $$391136 = 0, $$391242 = 0, $$391348 = 0;
  26190. var $$391455 = 0, $$391546 = 0, $$391646 = 0, $$3966 = 0, $$3970 = 0, $$3990 = 0, $$3990$ph = 0, $$3994 = 0, $$3994$ph = 0, $$40 = 0, $$401031 = 0, $$401137 = 0, $$401243 = 0, $$401349 = 0, $$401456 = 0, $$401547 = 0, $$401647 = 0, $$41 = 0, $$411032 = 0, $$411032$ph = 0;
  26191. var $$411138 = 0, $$411138$ph = 0, $$411244 = 0, $$411350 = 0, $$411457 = 0, $$411548 = 0, $$411648 = 0, $$41201 = 0, $$41420 = 0, $$41511 = 0, $$41611 = 0, $$42 = 0, $$42$ph = 0, $$421033 = 0, $$421139 = 0, $$421245 = 0, $$421245$ph = 0, $$421351 = 0, $$421351$ph = 0, $$421458 = 0;
  26192. var $$421549 = 0, $$421649 = 0, $$43 = 0, $$431034 = 0, $$431140 = 0, $$431246 = 0, $$431352 = 0, $$431459 = 0, $$431550 = 0, $$431650 = 0, $$44 = 0, $$441035 = 0, $$441141 = 0, $$441247 = 0, $$441353 = 0, $$441460 = 0, $$441460$ph = 0, $$441551 = 0, $$441651 = 0, $$441651$ph = 0;
  26193. var $$45 = 0, $$451036 = 0, $$451142 = 0, $$451248 = 0, $$451354 = 0, $$451461 = 0, $$451552 = 0, $$451652 = 0, $$46 = 0, $$461037 = 0, $$461143 = 0, $$461249 = 0, $$461355 = 0, $$461462 = 0, $$461553 = 0, $$461653 = 0, $$47 = 0, $$471038 = 0, $$471144 = 0, $$471250 = 0;
  26194. var $$471356 = 0, $$471463 = 0, $$471554 = 0, $$471654 = 0, $$48 = 0, $$481039 = 0, $$481039$ph = 0, $$481145 = 0, $$481145$ph = 0, $$481251 = 0, $$481357 = 0, $$481464 = 0, $$481555 = 0, $$481655 = 0, $$49 = 0, $$49$ph = 0, $$491040 = 0, $$491146 = 0, $$491252 = 0, $$491252$ph = 0;
  26195. var $$491358 = 0, $$491358$ph = 0, $$491465 = 0, $$491465$ph = 0, $$491556 = 0, $$491656 = 0, $$491656$ph = 0, $$5 = 0, $$50 = 0, $$501041 = 0, $$501147 = 0, $$501253 = 0, $$501359 = 0, $$501466 = 0, $$501557 = 0, $$501657 = 0, $$51 = 0, $$51102 = 0, $$511042 = 0, $$511148 = 0;
  26196. var $$511254 = 0, $$511360 = 0, $$511467 = 0, $$511558 = 0, $$511658 = 0, $$51208 = 0, $$51314 = 0, $$51512 = 0, $$52 = 0, $$521043 = 0, $$521043$ph = 0, $$521149 = 0, $$521255 = 0, $$521361 = 0, $$521468 = 0, $$521559 = 0, $$521659 = 0, $$53 = 0, $$531044 = 0, $$531150 = 0;
  26197. var $$531150$ph = 0, $$531256 = 0, $$531362 = 0, $$531469 = 0, $$531560 = 0, $$531660 = 0, $$54 = 0, $$54$ph = 0, $$541045 = 0, $$541151 = 0, $$541257 = 0, $$541257$ph = 0, $$541363 = 0, $$541363$ph = 0, $$541470$ph = 0, $$541561 = 0, $$541661$lcssa = 0, $$541661$ph = 0, $$5416611868 = 0, $$55 = 0;
  26198. var $$551046 = 0, $$551152 = 0, $$551258 = 0, $$551364 = 0, $$551471 = 0, $$551562 = 0, $$551662 = 0, $$56 = 0, $$561047 = 0, $$561153 = 0, $$561259 = 0, $$561365 = 0, $$561472 = 0, $$561563 = 0, $$561663 = 0, $$57 = 0, $$571048$ph = 0, $$571154 = 0, $$571260 = 0, $$571366 = 0;
  26199. var $$571473 = 0, $$571473$ph = 0, $$571564 = 0, $$571664 = 0, $$571664$ph = 0, $$58 = 0, $$581049 = 0, $$581155$lcssa = 0, $$581155$ph = 0, $$5811551871 = 0, $$581261 = 0, $$581367 = 0, $$581474 = 0, $$581565$lcssa = 0, $$581565$ph = 0, $$5815651869 = 0, $$581665 = 0, $$59$lcssa = 0, $$59$ph = 0, $$591050 = 0;
  26200. var $$591156 = 0, $$591262$ph = 0, $$591368$lcssa = 0, $$591368$ph = 0, $$5913681870 = 0, $$591475 = 0, $$591566 = 0, $$591666 = 0, $$591872 = 0, $$5996 = 0, $$6 = 0, $$60 = 0, $$601051 = 0, $$601051$ph = 0, $$601157 = 0, $$601263 = 0, $$601369 = 0, $$601476 = 0, $$601567 = 0, $$61 = 0;
  26201. var $$61103 = 0, $$611052 = 0, $$611158 = 0, $$611158$ph = 0, $$611264 = 0, $$611370 = 0, $$611477 = 0, $$611568 = 0, $$611668 = 0, $$61209 = 0, $$61315 = 0, $$61513 = 0, $$62 = 0, $$62$ph = 0, $$621053 = 0, $$621159 = 0, $$621265 = 0, $$621265$ph = 0, $$621371 = 0, $$621371$ph = 0;
  26202. var $$621478 = 0, $$621569 = 0, $$621669 = 0, $$63 = 0, $$631054 = 0, $$631266 = 0, $$631372 = 0, $$631479 = 0, $$631479$ph = 0, $$631570 = 0, $$631670 = 0, $$64 = 0, $$641055 = 0, $$641161 = 0, $$641267 = 0, $$641373 = 0, $$641480 = 0, $$641571 = 0, $$641671 = 0, $$641671$ph = 0;
  26203. var $$65 = 0, $$651056 = 0, $$651162 = 0, $$651268 = 0, $$651374 = 0, $$651481 = 0, $$651572 = 0, $$651672 = 0, $$66 = 0, $$661057 = 0, $$661057$ph = 0, $$661163 = 0, $$661269 = 0, $$661375 = 0, $$661482 = 0, $$661673 = 0, $$671058 = 0, $$671164 = 0, $$671164$ph = 0, $$671270 = 0;
  26204. var $$671483 = 0, $$671574 = 0, $$671674 = 0, $$68 = 0, $$681059 = 0, $$681165 = 0, $$681271 = 0, $$681271$ph = 0, $$681377 = 0, $$681484 = 0, $$681484$ph = 0, $$681575 = 0, $$681675 = 0, $$69 = 0, $$691060 = 0, $$691166 = 0, $$691272 = 0, $$691378 = 0, $$691485 = 0, $$691576 = 0;
  26205. var $$691676 = 0, $$691676$ph = 0, $$6997 = 0, $$7 = 0, $$70 = 0, $$701061 = 0, $$701167 = 0, $$701273 = 0, $$701379 = 0, $$701486 = 0, $$701577 = 0, $$701677 = 0, $$71 = 0, $$71$ph = 0, $$71104 = 0, $$711062 = 0, $$711062$ph = 0, $$711168 = 0, $$711274 = 0, $$711380 = 0;
  26206. var $$711380$ph = 0, $$711487 = 0, $$711578 = 0, $$711678 = 0, $$71210 = 0, $$71316 = 0, $$71514 = 0, $$72 = 0, $$721063 = 0, $$721169 = 0, $$721169$ph = 0, $$721275 = 0, $$721381 = 0, $$721488 = 0, $$721488$ph = 0, $$721579 = 0, $$721679 = 0, $$73 = 0, $$731064 = 0, $$731170 = 0;
  26207. var $$731276 = 0, $$731276$ph = 0, $$731382 = 0, $$731489 = 0, $$731580 = 0, $$731680 = 0, $$731680$ph = 0, $$74 = 0, $$741065 = 0, $$741065$ph = 0, $$741171 = 0, $$741277 = 0, $$741383 = 0, $$741490 = 0, $$741581 = 0, $$741681 = 0, $$75 = 0, $$751066 = 0, $$751172 = 0, $$751278 = 0;
  26208. var $$751384 = 0, $$751491 = 0, $$751582 = 0, $$751682 = 0, $$76 = 0, $$76$ph = 0, $$761067 = 0, $$761173 = 0, $$761173$ph = 0, $$761279 = 0, $$761279$ph = 0, $$761385 = 0, $$761385$ph = 0, $$761492 = 0, $$761583 = 0, $$761683 = 0, $$77 = 0, $$771068 = 0, $$771174 = 0, $$771280 = 0;
  26209. var $$771386 = 0, $$771584 = 0, $$771684 = 0, $$78 = 0, $$781069 = 0, $$781175 = 0, $$781281 = 0, $$781387 = 0, $$781585 = 0, $$781685 = 0, $$79 = 0, $$791070 = 0, $$791176 = 0, $$791282 = 0, $$791388 = 0, $$791586 = 0, $$791686 = 0, $$7998 = 0, $$8 = 0, $$8$ph = 0;
  26210. var $$80 = 0, $$80$ph = 0, $$801071 = 0, $$801177 = 0, $$801283 = 0, $$801389 = 0, $$801389$ph = 0, $$801496 = 0, $$801587 = 0, $$801687 = 0, $$81 = 0, $$81105 = 0, $$81105$ph = 0, $$811178 = 0, $$811284 = 0, $$811390 = 0, $$811497 = 0, $$811588 = 0, $$81211 = 0, $$81211$ph = 0;
  26211. var $$81317 = 0, $$81317$ph = 0, $$81424 = 0, $$81515 = 0, $$81615 = 0, $$82 = 0, $$821179 = 0, $$821285 = 0, $$821391 = 0, $$821498 = 0, $$821589 = 0, $$83 = 0, $$831180 = 0, $$831392 = 0, $$831499 = 0, $$831590 = 0, $$84 = 0, $$841075 = 0, $$841393 = 0, $$841500 = 0;
  26212. var $$841500$ph = 0, $$841591 = 0, $$841691 = 0, $$85 = 0, $$851076 = 0, $$851394 = 0, $$851501 = 0, $$851592 = 0, $$851692 = 0, $$86 = 0, $$861077 = 0, $$861289 = 0, $$861395 = 0, $$861502 = 0, $$861693 = 0, $$871078 = 0, $$871184 = 0, $$871290 = 0, $$871503 = 0, $$871694 = 0;
  26213. var $$881079 = 0, $$881079$ph = 0, $$881185 = 0, $$881291 = 0, $$881504 = 0, $$881595 = 0, $$881695 = 0, $$881695$ph = 0, $$891080 = 0, $$891186 = 0, $$891292 = 0, $$891505 = 0, $$891596 = 0, $$891696 = 0, $$8999 = 0, $$8999$ph = 0, $$9 = 0, $$90 = 0, $$901081 = 0, $$901187 = 0;
  26214. var $$901187$ph = 0, $$901293 = 0, $$901293$ph = 0, $$901399 = 0, $$901506 = 0, $$901597 = 0, $$901697 = 0, $$91 = 0, $$91000 = 0, $$91106 = 0, $$911082 = 0, $$911188 = 0, $$911294 = 0, $$911400 = 0, $$911598 = 0, $$911698 = 0, $$91212 = 0, $$91318 = 0, $$91425 = 0, $$91616 = 0;
  26215. var $$92 = 0, $$921083 = 0, $$921189 = 0, $$921295 = 0, $$921401 = 0, $$921599 = 0, $$921699 = 0, $$93 = 0, $$931084 = 0, $$931190 = 0, $$931296 = 0, $$931402 = 0, $$931600 = 0, $$931700 = 0, $$94 = 0, $$94$ph = 0, $$941085 = 0, $$941191 = 0, $$941297 = 0, $$941403 = 0;
  26216. var $$941403$ph = 0, $$941601 = 0, $$941701 = 0, $$95 = 0, $$951192 = 0, $$951298 = 0, $$951404 = 0, $$951602 = 0, $$96 = 0, $$961193 = 0, $$961299 = 0, $$961405 = 0, $$961603 = 0, $$97 = 0, $$971406 = 0, $$971604 = 0, $$98 = 0, $$981407 = 0, $$981605 = 0, $$99 = 0;
  26217. var $$991408 = 0, $$991606 = 0, $$lcssa1778 = 0, $$lcssa1779 = 0, $$lcssa1799 = 0, $$lcssa1802 = 0, $$not = 0, $$not1747 = 0, $$sink12 = 0, $$sink13 = 0, $$sink16 = 0, $$sink17 = 0, $$sink1705 = 0, $$sink1710 = 0, $$sink1713 = 0, $$sink1716 = 0, $$sink1719 = 0, $$sink1722 = 0, $$sink1729 = 0, $$sink1732 = 0;
  26218. var $$sink1736 = 0, $$sink1739 = 0, $$sink1743 = 0, $$sink1746 = 0, $$sink1750 = 0, $$sink3 = 0, $$sink3$shrunk = 0, $$sink30 = 0, $$sink9 = 0, $$sink9$shrunk = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0;
  26219. var $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0;
  26220. var $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0;
  26221. var $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0;
  26222. var $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0;
  26223. var $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0;
  26224. var $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0;
  26225. var $218 = 0, $219 = 0, $22 = 0, $220 = 0, $221 = 0, $222 = 0, $223 = 0, $224 = 0, $225 = 0, $226 = 0, $227 = 0, $228 = 0, $229 = 0, $23 = 0, $230 = 0, $231 = 0, $232 = 0, $233 = 0, $234 = 0, $235 = 0;
  26226. var $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0, $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0, $249 = 0, $25 = 0, $250 = 0, $251 = 0, $252 = 0, $253 = 0;
  26227. var $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0, $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0, $267 = 0, $268 = 0, $269 = 0, $27 = 0, $270 = 0, $271 = 0;
  26228. var $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0, $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0, $285 = 0, $286 = 0, $287 = 0, $288 = 0, $289 = 0, $29 = 0;
  26229. var $290 = 0, $291 = 0, $292 = 0, $293 = 0, $294 = 0, $295 = 0, $296 = 0, $297 = 0, $298 = 0, $299 = 0, $30 = 0, $300 = 0, $301 = 0, $302 = 0, $303 = 0, $304 = 0, $305 = 0, $306 = 0, $307 = 0, $308 = 0;
  26230. var $309 = 0, $31 = 0, $310 = 0, $311 = 0, $312 = 0, $313 = 0, $314 = 0, $315 = 0, $316 = 0, $317 = 0, $318 = 0, $319 = 0, $32 = 0, $320 = 0, $321 = 0, $322 = 0, $323 = 0, $324 = 0, $325 = 0, $326 = 0;
  26231. var $327 = 0, $328 = 0, $329 = 0, $33 = 0, $330 = 0, $331 = 0, $332 = 0, $333 = 0, $334 = 0, $335 = 0, $336 = 0, $337 = 0, $338 = 0, $339 = 0, $34 = 0, $340 = 0, $341 = 0, $342 = 0, $343 = 0, $344 = 0;
  26232. var $345 = 0, $346 = 0, $347 = 0, $348 = 0, $349 = 0, $35 = 0, $350 = 0, $351 = 0, $352 = 0, $353 = 0, $354 = 0, $355 = 0, $356 = 0, $357 = 0, $358 = 0, $359 = 0, $36 = 0, $360 = 0, $361 = 0, $362 = 0;
  26233. var $363 = 0, $364 = 0, $365 = 0, $366 = 0, $367 = 0, $368 = 0, $369 = 0, $37 = 0, $370 = 0, $371 = 0, $372 = 0, $373 = 0, $374 = 0, $375 = 0, $376 = 0, $377 = 0, $378 = 0, $379 = 0, $38 = 0, $380 = 0;
  26234. var $381 = 0, $382 = 0, $383 = 0, $384 = 0, $385 = 0, $386 = 0, $387 = 0, $388 = 0, $389 = 0, $39 = 0, $390 = 0, $391 = 0, $392 = 0, $393 = 0, $394 = 0, $395 = 0, $396 = 0, $397 = 0, $398 = 0, $399 = 0;
  26235. var $40 = 0, $400 = 0, $401 = 0, $402 = 0, $403 = 0, $404 = 0, $405 = 0, $406 = 0, $407 = 0, $408 = 0, $409 = 0, $41 = 0, $410 = 0, $411 = 0, $412 = 0, $413 = 0, $414 = 0, $415 = 0, $416 = 0, $417 = 0;
  26236. var $418 = 0, $419 = 0, $42 = 0, $420 = 0, $421 = 0, $422 = 0, $423 = 0, $424 = 0, $425 = 0, $426 = 0, $427 = 0, $428 = 0, $429 = 0, $43 = 0, $430 = 0, $431 = 0, $432 = 0, $433 = 0, $434 = 0, $435 = 0;
  26237. var $436 = 0, $437 = 0, $438 = 0, $439 = 0, $44 = 0, $440 = 0, $441 = 0, $442 = 0, $443 = 0, $444 = 0, $445 = 0, $446 = 0, $447 = 0, $448 = 0, $449 = 0, $45 = 0, $450 = 0, $451 = 0, $452 = 0, $453 = 0;
  26238. var $454 = 0, $455 = 0, $456 = 0, $457 = 0, $458 = 0, $459 = 0, $46 = 0, $460 = 0, $461 = 0, $462 = 0, $463 = 0, $464 = 0, $465 = 0, $466 = 0, $467 = 0, $468 = 0, $469 = 0, $47 = 0, $470 = 0, $471 = 0;
  26239. var $472 = 0, $473 = 0, $474 = 0, $475 = 0, $476 = 0, $477 = 0, $478 = 0, $479 = 0, $48 = 0, $480 = 0, $481 = 0, $482 = 0, $483 = 0, $484 = 0, $485 = 0, $486 = 0, $487 = 0, $488 = 0, $489 = 0, $49 = 0;
  26240. var $490 = 0, $491 = 0, $492 = 0, $493 = 0, $494 = 0, $495 = 0, $496 = 0, $497 = 0, $498 = 0, $499 = 0, $50 = 0, $500 = 0, $501 = 0, $502 = 0, $503 = 0, $504 = 0, $505 = 0, $506 = 0, $507 = 0, $508 = 0;
  26241. var $509 = 0, $51 = 0, $510 = 0, $511 = 0, $512 = 0, $513 = 0, $514 = 0, $515 = 0, $516 = 0, $517 = 0, $518 = 0, $519 = 0, $52 = 0, $520 = 0, $521 = 0, $522 = 0, $523 = 0, $524 = 0, $525 = 0, $526 = 0;
  26242. var $527 = 0, $528 = 0, $529 = 0, $53 = 0, $530 = 0, $531 = 0, $532 = 0, $533 = 0, $534 = 0, $535 = 0, $536 = 0, $537 = 0, $538 = 0, $539 = 0, $54 = 0, $540 = 0, $541 = 0, $542 = 0, $543 = 0, $544 = 0;
  26243. var $545 = 0, $546 = 0, $547 = 0, $548 = 0, $549 = 0, $55 = 0, $550 = 0, $551 = 0, $552 = 0, $553 = 0, $554 = 0, $555 = 0, $556 = 0, $557 = 0, $558 = 0, $559 = 0, $56 = 0, $560 = 0, $561 = 0, $562 = 0;
  26244. var $563 = 0, $564 = 0, $565 = 0, $566 = 0, $567 = 0, $568 = 0, $569 = 0, $57 = 0, $570 = 0, $571 = 0, $572 = 0, $573 = 0, $574 = 0, $575 = 0, $576 = 0, $577 = 0, $578 = 0, $579 = 0, $58 = 0, $580 = 0;
  26245. var $581 = 0, $582 = 0, $583 = 0, $584 = 0, $585 = 0, $586 = 0, $587 = 0, $588 = 0, $589 = 0, $59 = 0, $590 = 0, $591 = 0, $592 = 0, $593 = 0, $594 = 0, $595 = 0, $596 = 0, $597 = 0, $598 = 0, $599 = 0;
  26246. var $60 = 0, $600 = 0, $601 = 0, $602 = 0, $603 = 0, $604 = 0, $605 = 0, $606 = 0, $607 = 0, $608 = 0, $609 = 0, $61 = 0, $610 = 0, $611 = 0, $612 = 0, $613 = 0, $614 = 0, $615 = 0, $616 = 0, $617 = 0;
  26247. var $618 = 0, $619 = 0, $62 = 0, $620 = 0, $621 = 0, $622 = 0, $623 = 0, $624 = 0, $625 = 0, $626 = 0, $627 = 0, $628 = 0, $629 = 0, $63 = 0, $630 = 0, $631 = 0, $632 = 0, $633 = 0, $634 = 0, $635 = 0;
  26248. var $636 = 0, $637 = 0, $638 = 0, $639 = 0, $64 = 0, $640 = 0, $641 = 0, $642 = 0, $643 = 0, $644 = 0, $645 = 0, $646 = 0, $647 = 0, $648 = 0, $649 = 0, $65 = 0, $650 = 0, $651 = 0, $652 = 0, $653 = 0;
  26249. var $654 = 0, $655 = 0, $656 = 0, $657 = 0, $658 = 0, $659 = 0, $66 = 0, $660 = 0, $661 = 0, $662 = 0, $663 = 0, $664 = 0, $665 = 0, $666 = 0, $667 = 0, $668 = 0, $669 = 0, $67 = 0, $670 = 0, $671 = 0;
  26250. var $672 = 0, $673 = 0, $674 = 0, $675 = 0, $676 = 0, $677 = 0, $678 = 0, $679 = 0, $68 = 0, $680 = 0, $681 = 0, $682 = 0, $683 = 0, $684 = 0, $685 = 0, $686 = 0, $687 = 0, $688 = 0, $689 = 0, $69 = 0;
  26251. var $690 = 0, $691 = 0, $692 = 0, $693 = 0, $694 = 0, $695 = 0, $696 = 0, $697 = 0, $698 = 0, $699 = 0, $7 = 0, $70 = 0, $700 = 0, $701 = 0, $702 = 0, $703 = 0, $704 = 0, $705 = 0, $706 = 0, $707 = 0;
  26252. var $708 = 0, $709 = 0, $71 = 0, $710 = 0, $711 = 0, $712 = 0, $713 = 0, $714 = 0, $715 = 0, $716 = 0, $717 = 0, $718 = 0, $719 = 0, $72 = 0, $720 = 0, $721 = 0, $722 = 0, $723 = 0, $724 = 0, $725 = 0;
  26253. var $726 = 0, $727 = 0, $728 = 0, $729 = 0, $73 = 0, $730 = 0, $731 = 0, $732 = 0, $733 = 0, $734 = 0, $735 = 0, $736 = 0, $737 = 0, $738 = 0, $739 = 0, $74 = 0, $740 = 0, $741 = 0, $742 = 0, $743 = 0;
  26254. var $744 = 0, $745 = 0, $746 = 0, $747 = 0, $748 = 0, $749 = 0, $75 = 0, $750 = 0, $751 = 0, $752 = 0, $753 = 0, $754 = 0, $755 = 0, $756 = 0, $757 = 0, $758 = 0, $759 = 0, $76 = 0, $760 = 0, $761 = 0;
  26255. var $762 = 0, $763 = 0, $764 = 0, $765 = 0, $766 = 0, $767 = 0, $768 = 0, $769 = 0, $77 = 0, $770 = 0, $771 = 0, $772 = 0, $773 = 0, $774 = 0, $775 = 0, $776 = 0, $777 = 0, $778 = 0, $779 = 0, $78 = 0;
  26256. var $780 = 0, $781 = 0, $782 = 0, $783 = 0, $784 = 0, $785 = 0, $786 = 0, $787 = 0, $788 = 0, $789 = 0, $79 = 0, $790 = 0, $791 = 0, $792 = 0, $793 = 0, $794 = 0, $795 = 0, $796 = 0, $797 = 0, $798 = 0;
  26257. var $799 = 0, $8 = 0, $80 = 0, $800 = 0, $801 = 0, $802 = 0, $803 = 0, $804 = 0, $805 = 0, $806 = 0, $807 = 0, $808 = 0, $809 = 0, $81 = 0, $810 = 0, $811 = 0, $812 = 0, $813 = 0, $814 = 0, $815 = 0;
  26258. var $816 = 0, $817 = 0, $818 = 0, $819 = 0, $82 = 0, $820 = 0, $821 = 0, $822 = 0, $823 = 0, $824 = 0, $825 = 0, $826 = 0, $827 = 0, $828 = 0, $829 = 0, $83 = 0, $830 = 0, $831 = 0, $832 = 0, $833 = 0;
  26259. var $834 = 0, $835 = 0, $836 = 0, $837 = 0, $838 = 0, $839 = 0, $84 = 0, $840 = 0, $841 = 0, $842 = 0, $843 = 0, $844 = 0, $845 = 0, $846 = 0, $847 = 0, $848 = 0, $849 = 0, $85 = 0, $850 = 0, $851 = 0;
  26260. var $852 = 0, $853 = 0, $854 = 0, $855 = 0, $856 = 0, $857 = 0, $858 = 0, $859 = 0, $86 = 0, $860 = 0, $861 = 0, $862 = 0, $863 = 0, $864 = 0, $865 = 0, $866 = 0, $867 = 0, $868 = 0, $869 = 0, $87 = 0;
  26261. var $870 = 0, $871 = 0, $872 = 0, $873 = 0, $874 = 0, $875 = 0, $876 = 0, $877 = 0, $878 = 0, $879 = 0, $88 = 0, $880 = 0, $881 = 0, $882 = 0, $883 = 0, $884 = 0, $885 = 0, $886 = 0, $887 = 0, $888 = 0;
  26262. var $889 = 0, $89 = 0, $890 = 0, $891 = 0, $892 = 0, $893 = 0, $894 = 0, $895 = 0, $896 = 0, $897 = 0, $898 = 0, $899 = 0, $9 = 0, $90 = 0, $900 = 0, $901 = 0, $902 = 0, $903 = 0, $904 = 0, $905 = 0;
  26263. var $906 = 0, $907 = 0, $908 = 0, $909 = 0, $91 = 0, $910 = 0, $911 = 0, $912 = 0, $913 = 0, $914 = 0, $915 = 0, $916 = 0, $917 = 0, $918 = 0, $919 = 0, $92 = 0, $920 = 0, $921 = 0, $922 = 0, $923 = 0;
  26264. var $924 = 0, $925 = 0, $926 = 0, $927 = 0, $928 = 0, $929 = 0, $93 = 0, $930 = 0, $931 = 0, $932 = 0, $933 = 0, $934 = 0, $935 = 0, $936 = 0, $937 = 0, $938 = 0, $939 = 0, $94 = 0, $940 = 0, $941 = 0;
  26265. var $942 = 0, $943 = 0, $944 = 0, $945 = 0, $946 = 0, $947 = 0, $948 = 0, $949 = 0, $95 = 0, $950 = 0, $951 = 0, $952 = 0, $953 = 0, $954 = 0, $955 = 0, $956 = 0, $957 = 0, $958 = 0, $959 = 0, $96 = 0;
  26266. var $960 = 0, $961 = 0, $962 = 0, $963 = 0, $964 = 0, $965 = 0, $966 = 0, $97 = 0, $98 = 0, $99 = 0, $brmerge = 0, $exitcond = 0, $not$ = 0, $not$1755 = 0, $or$cond = 0, $or$cond1702 = 0, $or$cond1752 = 0, $or$cond24 = 0, $or$cond29 = 0, $scevgep = 0;
  26267. var $scevgep1947 = 0, $scevgep1948 = 0, $scevgep1955 = 0, $scevgep1957 = 0, $scevgep1959 = 0, $scevgep19611962 = 0, $trunc = 0, $trunc$clear = 0, dest = 0, label = 0, sp = 0, stop = 0;
  26268. sp = STACKTOP;
  26269. STACKTOP = STACKTOP + 144|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(144|0);
  26270. $7 = sp + 64|0;
  26271. $8 = sp;
  26272. $9 = HEAP32[$2>>2]|0;
  26273. $10 = (($1) + ($9)|0);
  26274. $11 = HEAP32[$5>>2]|0;
  26275. $12 = (($4) + ($11)|0);
  26276. $13 = $6 & 4;
  26277. $14 = ($13|0)!=(0);
  26278. $15 = $4;
  26279. $16 = $3;
  26280. $17 = $16 ^ -1;
  26281. $18 = (($15) + ($17))|0;
  26282. $19 = (($18) + ($11))|0;
  26283. $$1753 = $14 ? -1 : $19;
  26284. $20 = (($$1753) + 1)|0;
  26285. $21 = $20 & $$1753;
  26286. $22 = ($21|0)!=(0);
  26287. $23 = ($4>>>0)<($3>>>0);
  26288. $or$cond1702 = $23 | $22;
  26289. if ($or$cond1702) {
  26290. HEAP32[$5>>2] = 0;
  26291. HEAP32[$2>>2] = 0;
  26292. $$0951 = -3;
  26293. STACKTOP = sp;return ($$0951|0);
  26294. }
  26295. $24 = ((($0)) + 4|0);
  26296. $25 = HEAP32[$24>>2]|0;
  26297. $26 = ((($0)) + 56|0);
  26298. $27 = HEAP32[$26>>2]|0;
  26299. $28 = ((($0)) + 32|0);
  26300. $29 = HEAP32[$28>>2]|0;
  26301. $30 = ((($0)) + 36|0);
  26302. $31 = HEAP32[$30>>2]|0;
  26303. $32 = ((($0)) + 40|0);
  26304. $33 = HEAP32[$32>>2]|0;
  26305. $34 = ((($0)) + 60|0);
  26306. $35 = HEAP32[$34>>2]|0;
  26307. $36 = HEAP32[$0>>2]|0;
  26308. L5: do {
  26309. switch ($36|0) {
  26310. case 0: {
  26311. $37 = ((($0)) + 12|0);
  26312. HEAP32[$37>>2] = 0;
  26313. $38 = ((($0)) + 8|0);
  26314. HEAP32[$38>>2] = 0;
  26315. $39 = ((($0)) + 28|0);
  26316. HEAP32[$39>>2] = 1;
  26317. $40 = ((($0)) + 16|0);
  26318. HEAP32[$40>>2] = 1;
  26319. $41 = $6 & 1;
  26320. $42 = ($41|0)==(0);
  26321. if ($42) {
  26322. $$01416 = $35;$$01607 = $4;$$41511 = $1;$$5 = 0;$$51102 = 0;$$51208 = 0;$$51314 = 0;$$5996 = 0;
  26323. label = 14;
  26324. } else {
  26325. $43 = ($9|0)<(1);
  26326. if ($43) {
  26327. $$01097 = 0;$$01203 = 0;$$01309 = 0;$$0987 = 0;$$0991 = 0;
  26328. label = 6;
  26329. } else {
  26330. $$11098$ph = 0;$$11204$ph = 0;$$11310$ph = 0;$$1988$ph = 0;$$1992$ph = 0;
  26331. label = 8;
  26332. }
  26333. }
  26334. break;
  26335. }
  26336. case 1: {
  26337. $46 = ($9|0)>(0);
  26338. if ($46) {
  26339. $$11098$ph = $31;$$11204$ph = $33;$$11310$ph = $27;$$1988$ph = $25;$$1992$ph = $29;
  26340. label = 8;
  26341. } else {
  26342. $$01097 = $31;$$01203 = $33;$$01309 = $27;$$0987 = $25;$$0991 = $29;
  26343. label = 6;
  26344. }
  26345. break;
  26346. }
  26347. case 2: {
  26348. $53 = ($9|0)>(0);
  26349. if ($53) {
  26350. $$31206$ph = $33;$$31312$ph = $27;$$3990$ph = $25;$$3994$ph = $29;$$sink1705 = $1;
  26351. label = 12;
  26352. } else {
  26353. $$11508 = $1;$$21099 = $31;$$21205 = $33;$$21311 = $27;$$2989 = $25;$$2993 = $29;
  26354. label = 10;
  26355. }
  26356. break;
  26357. }
  26358. case 36: {
  26359. $$0960 = -1;$$891505 = $35;$$931084 = $29;$$931700 = $4;$$951192 = $31;$$951298 = $33;$$981605 = $1;$$99 = $25;$$991408 = $27;$$sink30 = 36;
  26360. label = 243;
  26361. break;
  26362. }
  26363. case 3: {
  26364. $75 = ($9|0)>(0);
  26365. if ($75) {
  26366. $$31419$ph = $35;$$31610$ph = $4;$$8$ph = $25;$$81105$ph = $31;$$81211$ph = $33;$$81317$ph = $27;$$8999$ph = $29;$$sink1710 = $1;
  26367. label = 18;
  26368. } else {
  26369. $$21418 = $35;$$21609 = $4;$$61513 = $1;$$7 = $25;$$71104 = $31;$$71210 = $33;$$71316 = $27;$$7998 = $29;
  26370. label = 16;
  26371. }
  26372. break;
  26373. }
  26374. case 5: {
  26375. $90 = ($9|0)>(0);
  26376. if ($90) {
  26377. $91 = ((($1)) + 1|0);
  26378. $92 = HEAP8[$1>>0]|0;
  26379. $93 = $92&255;
  26380. $$01412 = $93;$$111518 = $91;
  26381. } else {
  26382. $88 = $6 & 2;
  26383. $89 = ($88|0)==(0);
  26384. if ($89) {
  26385. $$01412 = 0;$$111518 = $1;
  26386. } else {
  26387. $$0960 = 1;$$891505 = $35;$$931084 = $29;$$931700 = $4;$$951192 = $31;$$951298 = $33;$$981605 = $1;$$99 = $25;$$991408 = $27;$$sink30 = 5;
  26388. label = 243;
  26389. break L5;
  26390. }
  26391. }
  26392. $94 = $$01412 << $25;
  26393. $95 = $94 | $27;
  26394. $96 = (($25) + 8)|0;
  26395. $$121519 = $$111518;$$13 = $96;$$131004 = $29;$$131216 = $33;$$131322 = $95;$$81424 = $35;$$81615 = $4;
  26396. label = 25;
  26397. break;
  26398. }
  26399. case 6: {
  26400. $106 = ($9|0)>(0);
  26401. if ($106) {
  26402. $$121428$ph = $35;$$121619$ph = $4;$$161113$ph = $31;$$17$ph = $25;$$171008$ph = $29;$$171220$ph = $33;$$171326$ph = $27;$$sink1713 = $1;
  26403. label = 32;
  26404. } else {
  26405. $$111427 = $35;$$111618 = $4;$$151112 = $31;$$151522 = $1;$$16 = $25;$$161007 = $29;$$161219 = $33;$$161325 = $27;
  26406. label = 30;
  26407. }
  26408. break;
  26409. }
  26410. case 7: {
  26411. $120 = ($9|0)>(0);
  26412. if ($120) {
  26413. $121 = ((($1)) + 1|0);
  26414. $122 = HEAP8[$1>>0]|0;
  26415. $$151431 = $35;$$151622 = $4;$$191116 = $31;$$191526 = $121;$$20 = $25;$$201011 = $29;$$201223 = $33;$$201329 = $27;$$sink12 = $122;
  26416. label = 39;
  26417. } else {
  26418. $$141430 = $35;$$141621 = $4;$$181115 = $31;$$181525 = $1;$$19 = $25;$$191010 = $29;$$191222 = $33;$$191328 = $27;
  26419. label = 36;
  26420. }
  26421. break;
  26422. }
  26423. case 39: {
  26424. $$171433 = $35;$$171624 = $4;$$211118 = $31;$$211528 = $1;$$22 = $25;$$221013 = $29;$$221225 = $33;$$221331 = $27;
  26425. label = 43;
  26426. break;
  26427. }
  26428. case 51: {
  26429. $152 = ($9|0)>(0);
  26430. if ($152) {
  26431. $$211437$ph = $35;$$211628$ph = $4;$$251122$ph = $31;$$26$ph = $25;$$261017$ph = $29;$$261229$ph = $33;$$261335$ph = $27;$$sink1716 = $1;
  26432. label = 49;
  26433. } else {
  26434. $$201436 = $35;$$201627 = $4;$$241121 = $31;$$241531 = $1;$$25 = $25;$$251016 = $29;$$251228 = $33;$$251334 = $27;
  26435. label = 47;
  26436. }
  26437. break;
  26438. }
  26439. case 52: {
  26440. $$231439 = $35;$$231630 = $4;$$271018 = $29;$$271124 = $31;$$271534 = $1;$$28 = $25;$$281231 = $33;$$281337 = $27;
  26441. label = 52;
  26442. break;
  26443. }
  26444. case 9: {
  26445. $$251441 = $35;$$251632 = $4;$$291020 = $29;$$291126 = $31;$$291536 = $1;$$30 = $25;$$301233 = $33;$$301339 = $27;
  26446. label = 55;
  26447. break;
  26448. }
  26449. case 38: {
  26450. $$261442 = $35;$$261633 = $4;$$301021 = $29;$$301127 = $31;$$301537 = $1;$$31 = $25;$$311234 = $33;$$311340 = $27;
  26451. label = 56;
  26452. break;
  26453. }
  26454. case 40: {
  26455. $$271443 = $35;$$271634 = $4;$$311022 = $29;$$311128 = $31;$$311538 = $1;$$32 = $25;$$321235 = $33;$$321341 = $27;
  26456. label = 58;
  26457. break;
  26458. }
  26459. case 10: {
  26460. $$281444 = $35;$$281635 = $4;$$321023 = $29;$$321129 = $31;$$321539 = $1;$$33 = $25;$$331236 = $33;$$331342 = $27;
  26461. label = 60;
  26462. break;
  26463. }
  26464. case 11: {
  26465. $193 = ($9|0)>(0);
  26466. if ($193) {
  26467. $$321448$ph = $35;$$321639$ph = $4;$$361027$ph = $29;$$361133$ph = $31;$$37$ph = $25;$$371240$ph = $33;$$371346$ph = $27;$$sink1719 = $1;
  26468. label = 66;
  26469. } else {
  26470. $$311447 = $35;$$311638 = $4;$$351026 = $29;$$351132 = $31;$$351542 = $1;$$36 = $25;$$361239 = $33;$$361345 = $27;
  26471. label = 64;
  26472. }
  26473. break;
  26474. }
  26475. case 14: {
  26476. $224 = ($9|0)>(0);
  26477. if ($224) {
  26478. $$371453$ph = $35;$$371644$ph = $4;$$411032$ph = $29;$$411138$ph = $31;$$42$ph = $25;$$421245$ph = $33;$$421351$ph = $27;$$sink1722 = $1;
  26479. label = 75;
  26480. } else {
  26481. $$361452 = $35;$$361643 = $4;$$401031 = $29;$$401137 = $31;$$401547 = $1;$$41 = $25;$$411244 = $33;$$411350 = $27;
  26482. label = 73;
  26483. }
  26484. break;
  26485. }
  26486. case 35: {
  26487. $$401456 = $35;$$401647 = $4;$$441035 = $29;$$441141 = $31;$$441551 = $1;$$45 = $25;$$451248 = $33;$$451354 = $27;
  26488. label = 86;
  26489. break;
  26490. }
  26491. case 16: {
  26492. $452 = ($9|0)>(0);
  26493. if ($452) {
  26494. $$441460$ph = $35;$$441651$ph = $4;$$481039$ph = $29;$$481145$ph = $31;$$49$ph = $25;$$491252$ph = $33;$$491358$ph = $27;$$sink1729 = $1;
  26495. label = 116;
  26496. } else {
  26497. $$431459 = $35;$$431650 = $4;$$471038 = $29;$$471144 = $31;$$471554 = $1;$$48 = $25;$$481251 = $33;$$481357 = $27;
  26498. label = 114;
  26499. }
  26500. break;
  26501. }
  26502. case 17: {
  26503. $$461462 = $35;$$461653 = $4;$$491040 = $29;$$501147 = $31;$$501557 = $1;$$51 = $25;$$511254 = $33;$$511360 = $27;
  26504. label = 125;
  26505. break;
  26506. }
  26507. case 18: {
  26508. $503 = ($9|0)>(0);
  26509. if ($503) {
  26510. $$491465$ph = $35;$$491656$ph = $4;$$521043$ph = $29;$$531150$ph = $31;$$54$ph = $25;$$541257$ph = $33;$$541363$ph = $27;$$sink1732 = $1;
  26511. label = 130;
  26512. } else {
  26513. $$481464 = $35;$$481655 = $4;$$511042 = $29;$$521149 = $31;$$521559 = $1;$$53 = $25;$$531256 = $33;$$531362 = $27;
  26514. label = 128;
  26515. }
  26516. break;
  26517. }
  26518. case 21: {
  26519. $$511467 = $35;$$511658 = $4;$$541045 = $29;$$551152 = $31;$$551562 = $1;$$56 = $25;$$561259 = $33;$$561365 = $27;
  26520. label = 136;
  26521. break;
  26522. }
  26523. case 23: {
  26524. $572 = ($9|0)>(0);
  26525. if ($572) {
  26526. $$571473$ph = $35;$$571664$ph = $4;$$601051$ph = $29;$$611158$ph = $31;$$62$ph = $25;$$621265$ph = $33;$$621371$ph = $27;$$sink1736 = $1;
  26527. label = 153;
  26528. } else {
  26529. $$561472 = $35;$$561663 = $4;$$591050 = $29;$$601157 = $31;$$601567 = $1;$$61 = $25;$$611264 = $33;$$611370 = $27;
  26530. label = 151;
  26531. }
  26532. break;
  26533. }
  26534. case 24: {
  26535. $$591475 = $35;$$591666 = $4;$$621053 = $29;$$621159 = $31;$$631570 = $1;$$64 = $25;$$641267 = $33;$$641373 = $27;
  26536. label = 160;
  26537. break;
  26538. }
  26539. case 25: {
  26540. $696 = ($9|0)>(0);
  26541. if ($696) {
  26542. $$631479$ph = $35;$$641671$ph = $4;$$661057$ph = $29;$$671164$ph = $31;$$681271$ph = $33;$$71$ph = $25;$$711380$ph = $27;$$sink1739 = $1;
  26543. label = 182;
  26544. } else {
  26545. $$621478 = $35;$$631670 = $4;$$651056 = $29;$$661163 = $31;$$671270 = $33;$$691576 = $1;$$70 = $25;$$701379 = $27;
  26546. label = 180;
  26547. }
  26548. break;
  26549. }
  26550. case 26: {
  26551. $737 = ($9|0)>(0);
  26552. if ($737) {
  26553. $$681484$ph = $35;$$691676$ph = $4;$$711062$ph = $29;$$721169$ph = $31;$$731276$ph = $33;$$76$ph = $25;$$761385$ph = $27;$$sink1743 = $1;
  26554. label = 195;
  26555. } else {
  26556. $$671483 = $35;$$681675 = $4;$$701061 = $29;$$711168 = $31;$$721275 = $33;$$741581 = $1;$$75 = $25;$$751384 = $27;
  26557. label = 193;
  26558. }
  26559. break;
  26560. }
  26561. case 27: {
  26562. $784 = ($9|0)>(0);
  26563. if ($784) {
  26564. $$721488$ph = $35;$$731680$ph = $4;$$741065$ph = $29;$$761173$ph = $31;$$761279$ph = $33;$$80$ph = $25;$$801389$ph = $27;$$sink1746 = $1;
  26565. label = 206;
  26566. } else {
  26567. $$711487 = $35;$$721679 = $4;$$731064 = $29;$$751172 = $31;$$751278 = $33;$$781585 = $1;$$79 = $25;$$791388 = $27;
  26568. label = 204;
  26569. }
  26570. break;
  26571. }
  26572. case 37: {
  26573. $$731489 = $35;$$761683 = $4;$$771068 = $29;$$791176 = $31;$$791282 = $33;$$821589 = $1;$$83 = $25;$$831392 = $27;
  26574. label = 210;
  26575. break;
  26576. }
  26577. case 53: {
  26578. $$751491 = $35;$$781685 = $4;$$791070 = $29;$$811178 = $31;$$811284 = $33;$$841591 = $1;$$85 = $25;$$851394 = $27;
  26579. label = 213;
  26580. break;
  26581. }
  26582. case 32: {
  26583. $842 = ($9|0)>(0);
  26584. if ($842) {
  26585. $843 = ((($1)) + 1|0);
  26586. $844 = HEAP8[$1>>0]|0;
  26587. $845 = $844&255;
  26588. $$0949 = $845;$$881595 = $843;
  26589. } else {
  26590. $840 = $6 & 2;
  26591. $841 = ($840|0)==(0);
  26592. if ($841) {
  26593. $$0949 = 0;$$881595 = $1;
  26594. } else {
  26595. $$0960 = 1;$$891505 = $35;$$931084 = $29;$$931700 = $4;$$951192 = $31;$$951298 = $33;$$981605 = $1;$$99 = $25;$$991408 = $27;$$sink30 = 32;
  26596. label = 243;
  26597. break L5;
  26598. }
  26599. }
  26600. $846 = $$0949 << $25;
  26601. $847 = $846 | $27;
  26602. $848 = (($25) + 8)|0;
  26603. $$801496 = $35;$$841075 = $29;$$841691 = $4;$$861289 = $33;$$891596 = $$881595;$$90 = $848;$$901399 = $847;
  26604. label = 226;
  26605. break;
  26606. }
  26607. case 41: {
  26608. $858 = ($9|0)>(0);
  26609. if ($858) {
  26610. $$841500$ph = $35;$$881079$ph = $29;$$881695$ph = $4;$$901187$ph = $31;$$901293$ph = $33;$$94$ph = $25;$$941403$ph = $27;$$sink1750 = $1;
  26611. label = 233;
  26612. } else {
  26613. $$831499 = $35;$$871078 = $29;$$871694 = $4;$$891186 = $31;$$891292 = $33;$$921599 = $1;$$93 = $25;$$931402 = $27;
  26614. label = 231;
  26615. }
  26616. break;
  26617. }
  26618. case 42: {
  26619. $871 = ($9|0)>(0);
  26620. if ($871) {
  26621. $872 = ((($1)) + 1|0);
  26622. $873 = HEAP8[$1>>0]|0;
  26623. $874 = $873&255;
  26624. $$0948 = $874;$$871503 = $35;$$911082 = $29;$$911698 = $4;$$931190 = $31;$$931296 = $33;$$961603 = $872;$$97 = $25;$$971406 = $27;
  26625. label = 241;
  26626. } else {
  26627. $$861502 = $35;$$901081 = $29;$$901697 = $4;$$921189 = $31;$$921295 = $33;$$951602 = $1;$$96 = $25;$$961405 = $27;
  26628. label = 237;
  26629. }
  26630. break;
  26631. }
  26632. case 34: {
  26633. $$881504 = $35;$$921083 = $29;$$921699 = $4;$$941191 = $31;$$941297 = $33;$$971604 = $1;$$98 = $25;$$981407 = $27;
  26634. label = 242;
  26635. break;
  26636. }
  26637. default: {
  26638. $$100 = $25;$$1001409 = $27;$$1961 = -1;$$901506 = $35;$$941085 = $29;$$941701 = $4;$$961193 = $31;$$961299 = $33;$$991606 = $1;
  26639. label = 244;
  26640. }
  26641. }
  26642. } while(0);
  26643. if ((label|0) == 6) {
  26644. $44 = $6 & 2;
  26645. $45 = ($44|0)==(0);
  26646. if ($45) {
  26647. $$01507 = $1;$$11098 = $$01097;$$11204 = $$01203;$$11310 = $$01309;$$1988 = $$0987;$$1992 = $$0991;$$sink3$shrunk = 0;
  26648. label = 9;
  26649. } else {
  26650. $$0960 = 1;$$891505 = $35;$$931084 = $$0991;$$931700 = $4;$$951192 = $$01097;$$951298 = $$01203;$$981605 = $1;$$99 = $$0987;$$991408 = $$01309;$$sink30 = 1;
  26651. label = 243;
  26652. }
  26653. }
  26654. else if ((label|0) == 8) {
  26655. $47 = ((($1)) + 1|0);
  26656. $48 = HEAP8[$1>>0]|0;
  26657. $$01507 = $47;$$11098 = $$11098$ph;$$11204 = $$11204$ph;$$11310 = $$11310$ph;$$1988 = $$1988$ph;$$1992 = $$1992$ph;$$sink3$shrunk = $48;
  26658. label = 9;
  26659. }
  26660. if ((label|0) == 9) {
  26661. $$sink3 = $$sink3$shrunk&255;
  26662. $49 = ((($0)) + 8|0);
  26663. HEAP32[$49>>2] = $$sink3;
  26664. $50 = ($$01507>>>0)<($10>>>0);
  26665. if ($50) {
  26666. $$31206$ph = $$11204;$$31312$ph = $$11310;$$3990$ph = $$1988;$$3994$ph = $$1992;$$sink1705 = $$01507;
  26667. label = 12;
  26668. } else {
  26669. $$11508 = $$01507;$$21099 = $$11098;$$21205 = $$11204;$$21311 = $$11310;$$2989 = $$1988;$$2993 = $$1992;
  26670. label = 10;
  26671. }
  26672. }
  26673. if ((label|0) == 10) {
  26674. $51 = $6 & 2;
  26675. $52 = ($51|0)==(0);
  26676. if ($52) {
  26677. $$21509 = $$11508;$$31206 = $$21205;$$31312 = $$21311;$$3990 = $$2989;$$3994 = $$2993;$$sink9$shrunk = 0;
  26678. label = 13;
  26679. } else {
  26680. $$0960 = 1;$$891505 = $35;$$931084 = $$2993;$$931700 = $4;$$951192 = $$21099;$$951298 = $$21205;$$981605 = $$11508;$$99 = $$2989;$$991408 = $$21311;$$sink30 = 2;
  26681. label = 243;
  26682. }
  26683. }
  26684. else if ((label|0) == 12) {
  26685. $54 = ((($$sink1705)) + 1|0);
  26686. $55 = HEAP8[$$sink1705>>0]|0;
  26687. $$21509 = $54;$$31206 = $$31206$ph;$$31312 = $$31312$ph;$$3990 = $$3990$ph;$$3994 = $$3994$ph;$$sink9$shrunk = $55;
  26688. label = 13;
  26689. }
  26690. if ((label|0) == 13) {
  26691. $$sink9 = $$sink9$shrunk&255;
  26692. $56 = ((($0)) + 12|0);
  26693. HEAP32[$56>>2] = $$sink9;
  26694. $57 = ((($0)) + 8|0);
  26695. $58 = HEAP32[$57>>2]|0;
  26696. $59 = $58 << 8;
  26697. $60 = $59 | $$sink9;
  26698. $61 = (($60>>>0) % 31)&-1;
  26699. $62 = $$sink9 & 32;
  26700. $63 = $61 | $62;
  26701. $64 = $58 & 15;
  26702. $65 = ($64|0)!=(8);
  26703. $not$ = ($63|0)!=(0);
  26704. $$1754 = $65 | $not$;
  26705. $66 = $58 >>> 4;
  26706. $67 = 256 << $66;
  26707. $68 = ($67>>>0)>(32768);
  26708. $69 = ($20>>>0)<($67>>>0);
  26709. $$ = $68 | $69;
  26710. $not$1755 = $14 ^ 1;
  26711. $70 = $$ & $not$1755;
  26712. $$31100$v = $70 | $$1754;
  26713. if ($$31100$v) {
  26714. $$0960 = -1;$$891505 = $35;$$931084 = $$3994;$$931700 = $4;$$951192 = 1;$$951298 = $$31206;$$981605 = $$21509;$$99 = $$3990;$$991408 = $$31312;$$sink30 = 36;
  26715. label = 243;
  26716. } else {
  26717. $$01416 = $35;$$01607 = $4;$$41511 = $$21509;$$5 = $$3990;$$51102 = 0;$$51208 = $$31206;$$51314 = $$31312;$$5996 = $$3994;
  26718. label = 14;
  26719. }
  26720. }
  26721. L46: while(1) {
  26722. switch (label|0) {
  26723. case 14: {
  26724. label = 0;
  26725. $71 = ($$5>>>0)<(3);
  26726. if ($71) {
  26727. $$11417 = $$01416;$$11608 = $$01607;$$51512 = $$41511;$$6 = $$5;$$61103 = $$51102;$$61209 = $$51208;$$61315 = $$51314;$$6997 = $$5996;
  26728. label = 15;
  26729. } else {
  26730. $$41420 = $$01416;$$41611 = $$01607;$$81515 = $$41511;$$9 = $$5;$$91000 = $$5996;$$91106 = $$51102;$$91212 = $$51208;$$91318 = $$51314;
  26731. label = 20;
  26732. }
  26733. break;
  26734. }
  26735. case 16: {
  26736. label = 0;
  26737. $73 = $6 & 2;
  26738. $74 = ($73|0)==(0);
  26739. if ($74) {
  26740. $$01413$shrunk = 0;$$31419 = $$21418;$$31610 = $$21609;$$71514 = $$61513;$$8 = $$7;$$81105 = $$71104;$$81211 = $$71210;$$81317 = $$71316;$$8999 = $$7998;
  26741. label = 19;
  26742. } else {
  26743. $$0960 = 1;$$891505 = $$21418;$$931084 = $$7998;$$931700 = $$21609;$$951192 = $$71104;$$951298 = $$71210;$$981605 = $$61513;$$99 = $$7;$$991408 = $$71316;$$sink30 = 3;
  26744. label = 243;
  26745. continue L46;
  26746. }
  26747. break;
  26748. }
  26749. case 18: {
  26750. label = 0;
  26751. $76 = ((($$sink1710)) + 1|0);
  26752. $77 = HEAP8[$$sink1710>>0]|0;
  26753. $$01413$shrunk = $77;$$31419 = $$31419$ph;$$31610 = $$31610$ph;$$71514 = $76;$$8 = $$8$ph;$$81105 = $$81105$ph;$$81211 = $$81211$ph;$$81317 = $$81317$ph;$$8999 = $$8999$ph;
  26754. label = 19;
  26755. break;
  26756. }
  26757. case 25: {
  26758. label = 0;
  26759. $97 = $$13 & 7;
  26760. $98 = $$131322 >>> $97;
  26761. $99 = (($$13) - ($97))|0;
  26762. $$131110 = 0;$$131520 = $$121519;$$14 = $99;$$141005 = $$131004;$$141217 = $$131216;$$141323 = $98;$$91425 = $$81424;$$91616 = $$81615;
  26763. label = 26;
  26764. break;
  26765. }
  26766. case 30: {
  26767. label = 0;
  26768. $104 = $6 & 2;
  26769. $105 = ($104|0)==(0);
  26770. if ($105) {
  26771. $$01411$shrunk = 0;$$121428 = $$111427;$$121619 = $$111618;$$161113 = $$151112;$$161523 = $$151522;$$17 = $$16;$$171008 = $$161007;$$171220 = $$161219;$$171326 = $$161325;
  26772. label = 33;
  26773. } else {
  26774. $$0960 = 1;$$891505 = $$111427;$$931084 = $$161007;$$931700 = $$111618;$$951192 = $$151112;$$951298 = $$161219;$$981605 = $$151522;$$99 = $$16;$$991408 = $$161325;$$sink30 = 6;
  26775. label = 243;
  26776. continue L46;
  26777. }
  26778. break;
  26779. }
  26780. case 32: {
  26781. label = 0;
  26782. $107 = ((($$sink1713)) + 1|0);
  26783. $108 = HEAP8[$$sink1713>>0]|0;
  26784. $$01411$shrunk = $108;$$121428 = $$121428$ph;$$121619 = $$121619$ph;$$161113 = $$161113$ph;$$161523 = $107;$$17 = $$17$ph;$$171008 = $$171008$ph;$$171220 = $$171220$ph;$$171326 = $$171326$ph;
  26785. label = 33;
  26786. break;
  26787. }
  26788. case 36: {
  26789. label = 0;
  26790. $118 = $6 & 2;
  26791. $119 = ($118|0)==(0);
  26792. if ($119) {
  26793. $$151431 = $$141430;$$151622 = $$141621;$$191116 = $$181115;$$191526 = $$181525;$$20 = $$19;$$201011 = $$191010;$$201223 = $$191222;$$201329 = $$191328;$$sink12 = 0;
  26794. label = 39;
  26795. continue L46;
  26796. } else {
  26797. $$0960 = 1;$$891505 = $$141430;$$931084 = $$191010;$$931700 = $$141621;$$951192 = $$181115;$$951298 = $$191222;$$981605 = $$181525;$$99 = $$19;$$991408 = $$191328;$$sink30 = 7;
  26798. label = 243;
  26799. continue L46;
  26800. }
  26801. break;
  26802. }
  26803. case 39: {
  26804. label = 0;
  26805. $$sink13 = (((($0)) + 10528|0) + ($$191116)|0);
  26806. HEAP8[$$sink13>>0] = $$sink12;
  26807. $$161432 = $$151431;$$161623 = $$151622;$$201117 = $$191116;$$201527 = $$191526;$$21 = $$20;$$211012 = $$201011;$$211224 = $$201223;$$211330 = $$201329;
  26808. label = 41;
  26809. break;
  26810. }
  26811. case 43: {
  26812. label = 0;
  26813. $$0960 = -1;$$891505 = $$171433;$$931084 = $$221013;$$931700 = $$171624;$$951192 = $$211118;$$951298 = $$221225;$$981605 = $$211528;$$99 = $$22;$$991408 = $$221331;$$sink30 = 39;
  26814. label = 243;
  26815. continue L46;
  26816. break;
  26817. }
  26818. case 47: {
  26819. label = 0;
  26820. $150 = $6 & 2;
  26821. $151 = ($150|0)==(0);
  26822. if ($151) {
  26823. $$01410$shrunk = 0;$$211437 = $$201436;$$211628 = $$201627;$$251122 = $$241121;$$251532 = $$241531;$$26 = $$25;$$261017 = $$251016;$$261229 = $$251228;$$261335 = $$251334;
  26824. label = 50;
  26825. } else {
  26826. $$0960 = 1;$$891505 = $$201436;$$931084 = $$251016;$$931700 = $$201627;$$951192 = $$241121;$$951298 = $$251228;$$981605 = $$241531;$$99 = $$25;$$991408 = $$251334;$$sink30 = 51;
  26827. label = 243;
  26828. continue L46;
  26829. }
  26830. break;
  26831. }
  26832. case 49: {
  26833. label = 0;
  26834. $153 = ((($$sink1716)) + 1|0);
  26835. $154 = HEAP8[$$sink1716>>0]|0;
  26836. $$01410$shrunk = $154;$$211437 = $$211437$ph;$$211628 = $$211628$ph;$$251122 = $$251122$ph;$$251532 = $153;$$26 = $$26$ph;$$261017 = $$261017$ph;$$261229 = $$261229$ph;$$261335 = $$261335$ph;
  26837. label = 50;
  26838. break;
  26839. }
  26840. case 52: {
  26841. label = 0;
  26842. $162 = ($$231630>>>0)<($12>>>0);
  26843. if (!($162)) {
  26844. $$0960 = 2;$$891505 = $$231439;$$931084 = $$271018;$$931700 = $$231630;$$951192 = $$271124;$$951298 = $$281231;$$981605 = $$271534;$$99 = $$28;$$991408 = $$281337;$$sink30 = 52;
  26845. label = 243;
  26846. continue L46;
  26847. }
  26848. $163 = $$271018&255;
  26849. $164 = ((($$231630)) + 1|0);
  26850. HEAP8[$$231630>>0] = $163;
  26851. $165 = (($$271124) + -1)|0;
  26852. $$181434 = $$231439;$$181625 = $164;$$221119 = $165;$$221529 = $$271534;$$23 = $$28;$$231014 = $$271018;$$231226 = $$281231;$$231332 = $$281337;
  26853. label = 44;
  26854. break;
  26855. }
  26856. case 55: {
  26857. label = 0;
  26858. $167 = ($$251632>>>0)<($12>>>0);
  26859. if ($167) {
  26860. $$261442 = $$251441;$$261633 = $$251632;$$301021 = $$291020;$$301127 = $$291126;$$301537 = $$291536;$$31 = $$30;$$311234 = $$301233;$$311340 = $$301339;
  26861. label = 56;
  26862. continue L46;
  26863. } else {
  26864. $$0960 = 2;$$891505 = $$251441;$$931084 = $$291020;$$931700 = $$251632;$$951192 = $$291126;$$951298 = $$301233;$$981605 = $$291536;$$99 = $$30;$$991408 = $$301339;$$sink30 = 9;
  26865. label = 243;
  26866. continue L46;
  26867. }
  26868. break;
  26869. }
  26870. case 56: {
  26871. label = 0;
  26872. $168 = ($$301537>>>0)<($10>>>0);
  26873. if ($168) {
  26874. $171 = $12;
  26875. $172 = $$261633;
  26876. $173 = (($171) - ($172))|0;
  26877. $174 = $10;
  26878. $175 = $$301537;
  26879. $176 = (($174) - ($175))|0;
  26880. $177 = ($173>>>0)<($176>>>0);
  26881. $$sink17 = $177 ? $12 : $10;
  26882. $$sink16 = $177 ? $$261633 : $$301537;
  26883. $178 = $$sink17;
  26884. $179 = $$sink16;
  26885. $180 = (($178) - ($179))|0;
  26886. $181 = ($180>>>0)<($$301127>>>0);
  26887. $$$301127 = $181 ? $180 : $$301127;
  26888. _memcpy(($$261633|0),($$301537|0),($$$301127|0))|0;
  26889. $182 = (($$301537) + ($$$301127)|0);
  26890. $183 = (($$261633) + ($$$301127)|0);
  26891. $184 = (($$301127) - ($$$301127))|0;
  26892. $$241440 = $$261442;$$241631 = $183;$$281019 = $$301021;$$281125 = $184;$$281535 = $182;$$29 = $$31;$$291232 = $$311234;$$291338 = $$311340;
  26893. label = 54;
  26894. break;
  26895. } else {
  26896. $169 = $6 & 2;
  26897. $170 = ($169|0)==(0);
  26898. if ($170) {
  26899. $$271443 = $$261442;$$271634 = $$261633;$$311022 = $$301021;$$311128 = $$301127;$$311538 = $$301537;$$32 = $$31;$$321235 = $$311234;$$321341 = $$311340;
  26900. label = 58;
  26901. continue L46;
  26902. } else {
  26903. $$0960 = 1;$$891505 = $$261442;$$931084 = $$301021;$$931700 = $$261633;$$951192 = $$301127;$$951298 = $$311234;$$981605 = $$301537;$$99 = $$31;$$991408 = $$311340;$$sink30 = 38;
  26904. label = 243;
  26905. continue L46;
  26906. }
  26907. }
  26908. break;
  26909. }
  26910. case 58: {
  26911. label = 0;
  26912. $$0960 = -1;$$891505 = $$271443;$$931084 = $$311022;$$931700 = $$271634;$$951192 = $$311128;$$951298 = $$321235;$$981605 = $$311538;$$99 = $$32;$$991408 = $$321341;$$sink30 = 40;
  26913. label = 243;
  26914. continue L46;
  26915. break;
  26916. }
  26917. case 60: {
  26918. label = 0;
  26919. $$0960 = -1;$$891505 = $$281444;$$931084 = $$321023;$$931700 = $$281635;$$951192 = $$321129;$$951298 = $$331236;$$981605 = $$321539;$$99 = $$33;$$991408 = $$331342;$$sink30 = 10;
  26920. label = 243;
  26921. continue L46;
  26922. break;
  26923. }
  26924. case 64: {
  26925. label = 0;
  26926. $191 = $6 & 2;
  26927. $192 = ($191|0)==(0);
  26928. if ($192) {
  26929. $$01300$shrunk = 0;$$321448 = $$311447;$$321639 = $$311638;$$361027 = $$351026;$$361133 = $$351132;$$361543 = $$351542;$$37 = $$36;$$371240 = $$361239;$$371346 = $$361345;
  26930. label = 67;
  26931. } else {
  26932. $$0960 = 1;$$891505 = $$311447;$$931084 = $$351026;$$931700 = $$311638;$$951192 = $$351132;$$951298 = $$361239;$$981605 = $$351542;$$99 = $$36;$$991408 = $$361345;$$sink30 = 11;
  26933. label = 243;
  26934. continue L46;
  26935. }
  26936. break;
  26937. }
  26938. case 66: {
  26939. label = 0;
  26940. $194 = ((($$sink1719)) + 1|0);
  26941. $195 = HEAP8[$$sink1719>>0]|0;
  26942. $$01300$shrunk = $195;$$321448 = $$321448$ph;$$321639 = $$321639$ph;$$361027 = $$361027$ph;$$361133 = $$361133$ph;$$361543 = $194;$$37 = $$37$ph;$$371240 = $$371240$ph;$$371346 = $$371346$ph;
  26943. label = 67;
  26944. break;
  26945. }
  26946. case 73: {
  26947. label = 0;
  26948. $222 = $6 & 2;
  26949. $223 = ($222|0)==(0);
  26950. if ($223) {
  26951. $$01202$shrunk = 0;$$371453 = $$361452;$$371644 = $$361643;$$411032 = $$401031;$$411138 = $$401137;$$411548 = $$401547;$$42 = $$41;$$421245 = $$411244;$$421351 = $$411350;
  26952. label = 76;
  26953. } else {
  26954. $$0960 = 1;$$891505 = $$361452;$$931084 = $$401031;$$931700 = $$361643;$$951192 = $$401137;$$951298 = $$411244;$$981605 = $$401547;$$99 = $$41;$$991408 = $$411350;$$sink30 = 14;
  26955. label = 243;
  26956. continue L46;
  26957. }
  26958. break;
  26959. }
  26960. case 75: {
  26961. label = 0;
  26962. $225 = ((($$sink1722)) + 1|0);
  26963. $226 = HEAP8[$$sink1722>>0]|0;
  26964. $$01202$shrunk = $226;$$371453 = $$371453$ph;$$371644 = $$371644$ph;$$411032 = $$411032$ph;$$411138 = $$411138$ph;$$411548 = $225;$$42 = $$42$ph;$$421245 = $$421245$ph;$$421351 = $$421351$ph;
  26965. label = 76;
  26966. break;
  26967. }
  26968. case 86: {
  26969. label = 0;
  26970. $$0960 = -1;$$891505 = $$401456;$$931084 = $$441035;$$931700 = $$401647;$$951192 = $$441141;$$951298 = $$451248;$$981605 = $$441551;$$99 = $$45;$$991408 = $$451354;$$sink30 = 35;
  26971. label = 243;
  26972. continue L46;
  26973. break;
  26974. }
  26975. case 114: {
  26976. label = 0;
  26977. $450 = $6 & 2;
  26978. $451 = ($450|0)==(0);
  26979. if ($451) {
  26980. $$0980$shrunk = 0;$$441460 = $$431459;$$441651 = $$431650;$$481039 = $$471038;$$481145 = $$471144;$$481555 = $$471554;$$49 = $$48;$$491252 = $$481251;$$491358 = $$481357;
  26981. label = 117;
  26982. } else {
  26983. $$0960 = 1;$$891505 = $$431459;$$931084 = $$471038;$$931700 = $$431650;$$951192 = $$471144;$$951298 = $$481251;$$981605 = $$471554;$$99 = $$48;$$991408 = $$481357;$$sink30 = 16;
  26984. label = 243;
  26985. continue L46;
  26986. }
  26987. break;
  26988. }
  26989. case 116: {
  26990. label = 0;
  26991. $453 = ((($$sink1729)) + 1|0);
  26992. $454 = HEAP8[$$sink1729>>0]|0;
  26993. $$0980$shrunk = $454;$$441460 = $$441460$ph;$$441651 = $$441651$ph;$$481039 = $$481039$ph;$$481145 = $$481145$ph;$$481555 = $453;$$49 = $$49$ph;$$491252 = $$491252$ph;$$491358 = $$491358$ph;
  26994. label = 117;
  26995. break;
  26996. }
  26997. case 125: {
  26998. label = 0;
  26999. $$0960 = -1;$$891505 = $$461462;$$931084 = $$491040;$$931700 = $$461653;$$951192 = $$501147;$$951298 = $$511254;$$981605 = $$501557;$$99 = $$51;$$991408 = $$511360;$$sink30 = 17;
  27000. label = 243;
  27001. continue L46;
  27002. break;
  27003. }
  27004. case 128: {
  27005. label = 0;
  27006. $501 = $6 & 2;
  27007. $502 = ($501|0)==(0);
  27008. if ($502) {
  27009. $$0979$shrunk = 0;$$491465 = $$481464;$$491656 = $$481655;$$521043 = $$511042;$$531150 = $$521149;$$531560 = $$521559;$$54 = $$53;$$541257 = $$531256;$$541363 = $$531362;
  27010. label = 131;
  27011. } else {
  27012. $$0960 = 1;$$891505 = $$481464;$$931084 = $$511042;$$931700 = $$481655;$$951192 = $$521149;$$951298 = $$531256;$$981605 = $$521559;$$99 = $$53;$$991408 = $$531362;$$sink30 = 18;
  27013. label = 243;
  27014. continue L46;
  27015. }
  27016. break;
  27017. }
  27018. case 130: {
  27019. label = 0;
  27020. $504 = ((($$sink1732)) + 1|0);
  27021. $505 = HEAP8[$$sink1732>>0]|0;
  27022. $$0979$shrunk = $505;$$491465 = $$491465$ph;$$491656 = $$491656$ph;$$521043 = $$521043$ph;$$531150 = $$531150$ph;$$531560 = $504;$$54 = $$54$ph;$$541257 = $$541257$ph;$$541363 = $$541363$ph;
  27023. label = 131;
  27024. break;
  27025. }
  27026. case 136: {
  27027. label = 0;
  27028. $$0960 = -1;$$891505 = $$511467;$$931084 = $$541045;$$931700 = $$511658;$$951192 = $$551152;$$951298 = $$561259;$$981605 = $$551562;$$99 = $$56;$$991408 = $$561365;$$sink30 = 21;
  27029. label = 243;
  27030. continue L46;
  27031. break;
  27032. }
  27033. case 151: {
  27034. label = 0;
  27035. $570 = $6 & 2;
  27036. $571 = ($570|0)==(0);
  27037. if ($571) {
  27038. $$0971$shrunk = 0;$$571473 = $$561472;$$571664 = $$561663;$$601051 = $$591050;$$611158 = $$601157;$$611568 = $$601567;$$62 = $$61;$$621265 = $$611264;$$621371 = $$611370;
  27039. label = 154;
  27040. } else {
  27041. $$0960 = 1;$$891505 = $$561472;$$931084 = $$591050;$$931700 = $$561663;$$951192 = $$601157;$$951298 = $$611264;$$981605 = $$601567;$$99 = $$61;$$991408 = $$611370;$$sink30 = 23;
  27042. label = 243;
  27043. continue L46;
  27044. }
  27045. break;
  27046. }
  27047. case 153: {
  27048. label = 0;
  27049. $573 = ((($$sink1736)) + 1|0);
  27050. $574 = HEAP8[$$sink1736>>0]|0;
  27051. $$0971$shrunk = $574;$$571473 = $$571473$ph;$$571664 = $$571664$ph;$$601051 = $$601051$ph;$$611158 = $$611158$ph;$$611568 = $573;$$62 = $$62$ph;$$621265 = $$621265$ph;$$621371 = $$621371$ph;
  27052. label = 154;
  27053. break;
  27054. }
  27055. case 160: {
  27056. label = 0;
  27057. $610 = ($$591666>>>0)<($12>>>0);
  27058. if (!($610)) {
  27059. $$0960 = 2;$$891505 = $$591475;$$931084 = $$621053;$$931700 = $$591666;$$951192 = $$621159;$$951298 = $$641267;$$981605 = $$631570;$$99 = $$64;$$991408 = $$641373;$$sink30 = 24;
  27060. label = 243;
  27061. continue L46;
  27062. }
  27063. $611 = $$621159&255;
  27064. $612 = ((($$591666)) + 1|0);
  27065. HEAP8[$$591666>>0] = $611;
  27066. $$541470$ph = $$591475;$$541661$ph = $612;$$571048$ph = $$621053;$$581155$ph = $$621159;$$581565$ph = $$631570;$$59$ph = $$64;$$591262$ph = $$641267;$$591368$ph = $$641373;
  27067. label = 140;
  27068. break;
  27069. }
  27070. case 180: {
  27071. label = 0;
  27072. $694 = $6 & 2;
  27073. $695 = ($694|0)==(0);
  27074. if ($695) {
  27075. $$0959$shrunk = 0;$$631479 = $$621478;$$641671 = $$631670;$$661057 = $$651056;$$671164 = $$661163;$$681271 = $$671270;$$701577 = $$691576;$$71 = $$70;$$711380 = $$701379;
  27076. label = 183;
  27077. } else {
  27078. $$0960 = 1;$$891505 = $$621478;$$931084 = $$651056;$$931700 = $$631670;$$951192 = $$661163;$$951298 = $$671270;$$981605 = $$691576;$$99 = $$70;$$991408 = $$701379;$$sink30 = 25;
  27079. label = 243;
  27080. continue L46;
  27081. }
  27082. break;
  27083. }
  27084. case 182: {
  27085. label = 0;
  27086. $697 = ((($$sink1739)) + 1|0);
  27087. $698 = HEAP8[$$sink1739>>0]|0;
  27088. $$0959$shrunk = $698;$$631479 = $$631479$ph;$$641671 = $$641671$ph;$$661057 = $$661057$ph;$$671164 = $$671164$ph;$$681271 = $$681271$ph;$$701577 = $697;$$71 = $$71$ph;$$711380 = $$711380$ph;
  27089. label = 183;
  27090. break;
  27091. }
  27092. case 193: {
  27093. label = 0;
  27094. $735 = $6 & 2;
  27095. $736 = ($735|0)==(0);
  27096. if ($736) {
  27097. $$0952$shrunk = 0;$$681484 = $$671483;$$691676 = $$681675;$$711062 = $$701061;$$721169 = $$711168;$$731276 = $$721275;$$751582 = $$741581;$$76 = $$75;$$761385 = $$751384;
  27098. label = 196;
  27099. } else {
  27100. $$0960 = 1;$$891505 = $$671483;$$931084 = $$701061;$$931700 = $$681675;$$951192 = $$711168;$$951298 = $$721275;$$981605 = $$741581;$$99 = $$75;$$991408 = $$751384;$$sink30 = 26;
  27101. label = 243;
  27102. continue L46;
  27103. }
  27104. break;
  27105. }
  27106. case 195: {
  27107. label = 0;
  27108. $738 = ((($$sink1743)) + 1|0);
  27109. $739 = HEAP8[$$sink1743>>0]|0;
  27110. $$0952$shrunk = $739;$$681484 = $$681484$ph;$$691676 = $$691676$ph;$$711062 = $$711062$ph;$$721169 = $$721169$ph;$$731276 = $$731276$ph;$$751582 = $738;$$76 = $$76$ph;$$761385 = $$761385$ph;
  27111. label = 196;
  27112. break;
  27113. }
  27114. case 204: {
  27115. label = 0;
  27116. $782 = $6 & 2;
  27117. $783 = ($782|0)==(0);
  27118. if ($783) {
  27119. $$0950$shrunk = 0;$$721488 = $$711487;$$731680 = $$721679;$$741065 = $$731064;$$761173 = $$751172;$$761279 = $$751278;$$791586 = $$781585;$$80 = $$79;$$801389 = $$791388;
  27120. label = 207;
  27121. } else {
  27122. $$0960 = 1;$$891505 = $$711487;$$931084 = $$731064;$$931700 = $$721679;$$951192 = $$751172;$$951298 = $$751278;$$981605 = $$781585;$$99 = $$79;$$991408 = $$791388;$$sink30 = 27;
  27123. label = 243;
  27124. continue L46;
  27125. }
  27126. break;
  27127. }
  27128. case 206: {
  27129. label = 0;
  27130. $785 = ((($$sink1746)) + 1|0);
  27131. $786 = HEAP8[$$sink1746>>0]|0;
  27132. $$0950$shrunk = $786;$$721488 = $$721488$ph;$$731680 = $$731680$ph;$$741065 = $$741065$ph;$$761173 = $$761173$ph;$$761279 = $$761279$ph;$$791586 = $785;$$80 = $$80$ph;$$801389 = $$801389$ph;
  27133. label = 207;
  27134. break;
  27135. }
  27136. case 210: {
  27137. label = 0;
  27138. $$0960 = -1;$$891505 = $$731489;$$931084 = $$771068;$$931700 = $$761683;$$951192 = $$791176;$$951298 = $$791282;$$981605 = $$821589;$$99 = $$83;$$991408 = $$831392;$$sink30 = 37;
  27139. label = 243;
  27140. continue L46;
  27141. break;
  27142. }
  27143. case 213: {
  27144. label = 0;
  27145. $809 = ($$781685>>>0)<($12>>>0);
  27146. if (!($809)) {
  27147. $$0960 = 2;$$891505 = $$751491;$$931084 = $$791070;$$931700 = $$781685;$$951192 = $$811178;$$951298 = $$811284;$$981605 = $$841591;$$99 = $$85;$$991408 = $$851394;$$sink30 = 53;
  27148. label = 243;
  27149. continue L46;
  27150. }
  27151. $810 = (($$751491) + 1)|0;
  27152. $811 = (($$751491) - ($$791070))|0;
  27153. $812 = $811 & $$1753;
  27154. $813 = (($3) + ($812)|0);
  27155. $814 = HEAP8[$813>>0]|0;
  27156. $815 = ((($$781685)) + 1|0);
  27157. HEAP8[$$781685>>0] = $814;
  27158. $$741490 = $810;$$771684 = $815;$$781069 = $$791070;$$801177 = $$811178;$$801283 = $$811284;$$831590 = $$841591;$$84 = $$85;$$841393 = $$851394;
  27159. label = 212;
  27160. break;
  27161. }
  27162. case 226: {
  27163. label = 0;
  27164. $849 = $$90 & 7;
  27165. $850 = $$901399 >>> $849;
  27166. $851 = (($$90) - ($849))|0;
  27167. $$811497 = $$801496;$$851076 = $$841075;$$851692 = $$841691;$$871184 = 0;$$871290 = $$861289;$$901597 = $$891596;$$91 = $851;$$911400 = $850;
  27168. label = 227;
  27169. break;
  27170. }
  27171. case 231: {
  27172. label = 0;
  27173. $856 = $6 & 2;
  27174. $857 = ($856|0)==(0);
  27175. if ($857) {
  27176. $$0947$shrunk = 0;$$841500 = $$831499;$$881079 = $$871078;$$881695 = $$871694;$$901187 = $$891186;$$901293 = $$891292;$$931600 = $$921599;$$94 = $$93;$$941403 = $$931402;
  27177. label = 234;
  27178. } else {
  27179. $$0960 = 1;$$891505 = $$831499;$$931084 = $$871078;$$931700 = $$871694;$$951192 = $$891186;$$951298 = $$891292;$$981605 = $$921599;$$99 = $$93;$$991408 = $$931402;$$sink30 = 41;
  27180. label = 243;
  27181. continue L46;
  27182. }
  27183. break;
  27184. }
  27185. case 233: {
  27186. label = 0;
  27187. $859 = ((($$sink1750)) + 1|0);
  27188. $860 = HEAP8[$$sink1750>>0]|0;
  27189. $$0947$shrunk = $860;$$841500 = $$841500$ph;$$881079 = $$881079$ph;$$881695 = $$881695$ph;$$901187 = $$901187$ph;$$901293 = $$901293$ph;$$931600 = $859;$$94 = $$94$ph;$$941403 = $$941403$ph;
  27190. label = 234;
  27191. break;
  27192. }
  27193. case 237: {
  27194. label = 0;
  27195. $869 = $6 & 2;
  27196. $870 = ($869|0)==(0);
  27197. if ($870) {
  27198. $$0948 = 0;$$871503 = $$861502;$$911082 = $$901081;$$911698 = $$901697;$$931190 = $$921189;$$931296 = $$921295;$$961603 = $$951602;$$97 = $$96;$$971406 = $$961405;
  27199. label = 241;
  27200. continue L46;
  27201. } else {
  27202. $$0960 = 1;$$891505 = $$861502;$$931084 = $$901081;$$931700 = $$901697;$$951192 = $$921189;$$951298 = $$921295;$$981605 = $$951602;$$99 = $$96;$$991408 = $$961405;$$sink30 = 42;
  27203. label = 243;
  27204. continue L46;
  27205. }
  27206. break;
  27207. }
  27208. case 241: {
  27209. label = 0;
  27210. $878 = ((($0)) + 16|0);
  27211. $879 = HEAP32[$878>>2]|0;
  27212. $880 = $879 << 8;
  27213. $881 = $880 | $$0948;
  27214. HEAP32[$878>>2] = $881;
  27215. $882 = (($$931190) + 1)|0;
  27216. $$811497 = $$871503;$$851076 = $$911082;$$851692 = $$911698;$$871184 = $882;$$871290 = $$931296;$$901597 = $$961603;$$91 = $$97;$$911400 = $$971406;
  27217. label = 227;
  27218. break;
  27219. }
  27220. case 242: {
  27221. label = 0;
  27222. $$0960 = 0;$$891505 = $$881504;$$931084 = $$921083;$$931700 = $$921699;$$951192 = $$941191;$$951298 = $$941297;$$981605 = $$971604;$$99 = $$98;$$991408 = $$981407;$$sink30 = 34;
  27223. label = 243;
  27224. continue L46;
  27225. break;
  27226. }
  27227. case 243: {
  27228. label = 0;
  27229. HEAP32[$0>>2] = $$sink30;
  27230. $$100 = $$99;$$1001409 = $$991408;$$1961 = $$0960;$$901506 = $$891505;$$941085 = $$931084;$$941701 = $$931700;$$961193 = $$951192;$$961299 = $$951298;$$991606 = $$981605;
  27231. label = 244;
  27232. continue L46;
  27233. break;
  27234. }
  27235. case 244: {
  27236. label = 0;
  27237. HEAP32[$24>>2] = $$100;
  27238. HEAP32[$26>>2] = $$1001409;
  27239. HEAP32[$28>>2] = $$941085;
  27240. HEAP32[$30>>2] = $$961193;
  27241. HEAP32[$32>>2] = $$961299;
  27242. HEAP32[$34>>2] = $$901506;
  27243. $883 = $$991606;
  27244. $884 = $1;
  27245. $885 = (($883) - ($884))|0;
  27246. HEAP32[$2>>2] = $885;
  27247. $886 = $$941701;
  27248. $887 = $4;
  27249. $888 = (($886) - ($887))|0;
  27250. HEAP32[$5>>2] = $888;
  27251. $889 = $6 & 9;
  27252. $890 = ($889|0)!=(0);
  27253. $891 = ($$1961|0)>(-1);
  27254. $or$cond29 = $890 & $891;
  27255. if ($or$cond29) {
  27256. break L46;
  27257. } else {
  27258. $$0951 = $$1961;
  27259. label = 258;
  27260. break L46;
  27261. }
  27262. break;
  27263. }
  27264. }
  27265. switch (label|0) {
  27266. case 19: {
  27267. label = 0;
  27268. $$01413 = $$01413$shrunk&255;
  27269. $78 = $$01413 << $$8;
  27270. $79 = $78 | $$81317;
  27271. $80 = (($$8) + 8)|0;
  27272. $81 = ($80>>>0)<(3);
  27273. if ($81) {
  27274. $$11417 = $$31419;$$11608 = $$31610;$$51512 = $$71514;$$6 = $80;$$61103 = $$81105;$$61209 = $$81211;$$61315 = $79;$$6997 = $$8999;
  27275. label = 15;
  27276. } else {
  27277. $$41420 = $$31419;$$41611 = $$31610;$$81515 = $$71514;$$9 = $80;$$91000 = $$8999;$$91106 = $$81105;$$91212 = $$81211;$$91318 = $79;
  27278. label = 20;
  27279. }
  27280. break;
  27281. }
  27282. case 33: {
  27283. label = 0;
  27284. $$01411 = $$01411$shrunk&255;
  27285. $109 = $$01411 << $$17;
  27286. $110 = $109 | $$171326;
  27287. $111 = (($$17) + 8)|0;
  27288. $112 = ($$17>>>0)>(4294967287);
  27289. if ($112) {
  27290. $$101426 = $$121428;$$101617 = $$121619;$$141111 = $$161113;$$141521 = $$161523;$$15 = $111;$$151006 = $$171008;$$151218 = $$171220;$$151324 = $110;
  27291. label = 29;
  27292. } else {
  27293. $$131429 = $$121428;$$131620 = $$121619;$$171114 = $$161113;$$171524 = $$161523;$$18 = $111;$$181009 = $$171008;$$181221 = $$171220;$$181327 = $110;
  27294. label = 34;
  27295. }
  27296. break;
  27297. }
  27298. case 50: {
  27299. label = 0;
  27300. $$01410 = $$01410$shrunk&255;
  27301. $155 = $$01410 << $$26;
  27302. $156 = $155 | $$261335;
  27303. $157 = (($$26) + 8)|0;
  27304. $158 = ($$26>>>0)>(4294967287);
  27305. if ($158) {
  27306. $$191435 = $$211437;$$191626 = $$211628;$$231120 = $$251122;$$231530 = $$251532;$$24 = $157;$$241015 = $$261017;$$241227 = $$261229;$$241333 = $156;
  27307. label = 46;
  27308. } else {
  27309. $$221438 = $$211437;$$221629 = $$211628;$$261123 = $$251122;$$261533 = $$251532;$$27 = $157;$$271230 = $$261229;$$271336 = $156;
  27310. label = 51;
  27311. }
  27312. break;
  27313. }
  27314. case 67: {
  27315. label = 0;
  27316. $$01300 = $$01300$shrunk&255;
  27317. $196 = $$01300 << $$37;
  27318. $197 = $196 | $$371346;
  27319. $198 = (($$37) + 8)|0;
  27320. $199 = (15201 + ($$361133)|0);
  27321. $200 = HEAP8[$199>>0]|0;
  27322. $201 = $200 << 24 >> 24;
  27323. $202 = ($198>>>0)<($201>>>0);
  27324. if ($202) {
  27325. $$301446 = $$321448;$$301637 = $$321639;$$341025 = $$361027;$$341131 = $$361133;$$341541 = $$361543;$$35 = $198;$$351238 = $$371240;$$351344 = $197;
  27326. label = 63;
  27327. } else {
  27328. $$331449 = $$321448;$$331640 = $$321639;$$371028 = $$361027;$$371134 = $$361133;$$371544 = $$361543;$$38 = $198;$$381241 = $$371240;$$381347 = $197;
  27329. label = 68;
  27330. }
  27331. break;
  27332. }
  27333. case 76: {
  27334. label = 0;
  27335. $$01202 = $$01202$shrunk&255;
  27336. $227 = $$01202 << $$42;
  27337. $228 = $227 | $$421351;
  27338. $229 = (($$42) + 8)|0;
  27339. $230 = ($229>>>0)<(3);
  27340. if ($230) {
  27341. $$351451 = $$371453;$$351642 = $$371644;$$391030 = $$411032;$$391136 = $$411138;$$391546 = $$411548;$$40 = $229;$$401243 = $$421245;$$401349 = $228;
  27342. label = 72;
  27343. } else {
  27344. $$381454 = $$371453;$$381645 = $$371644;$$421033 = $$411032;$$421139 = $$411138;$$421549 = $$411548;$$43 = $229;$$431246 = $$421245;$$431352 = $228;
  27345. label = 77;
  27346. }
  27347. break;
  27348. }
  27349. case 117: {
  27350. label = 0;
  27351. $$0980 = $$0980$shrunk&255;
  27352. $455 = $$0980 << $$49;
  27353. $456 = $455 | $$491358;
  27354. $457 = (($$49) + 8)|0;
  27355. $458 = ($457>>>0)<(15);
  27356. if ($458) {
  27357. $$421458 = $$441460;$$421649 = $$441651;$$461037 = $$481039;$$461143 = $$481145;$$461553 = $$481555;$$47 = $457;$$471250 = $$491252;$$471356 = $456;
  27358. label = 108;
  27359. } else {
  27360. $$451461 = $$441460;$$451652 = $$441651;$$491146 = $$481145;$$491556 = $$481555;$$50 = $457;$$501253 = $$491252;$$501359 = $456;
  27361. label = 119;
  27362. }
  27363. break;
  27364. }
  27365. case 131: {
  27366. label = 0;
  27367. $$0979 = $$0979$shrunk&255;
  27368. $506 = $$0979 << $$54;
  27369. $507 = $506 | $$541363;
  27370. $508 = (($$54) + 8)|0;
  27371. $509 = ($508>>>0)<($$541257>>>0);
  27372. if ($509) {
  27373. $$471463 = $$491465;$$471654 = $$491656;$$501041 = $$521043;$$511148 = $$531150;$$511558 = $$531560;$$52 = $508;$$521255 = $$541257;$$521361 = $507;
  27374. label = 127;
  27375. } else {
  27376. $$501466 = $$491465;$$501657 = $$491656;$$531044 = $$521043;$$541151 = $$531150;$$541561 = $$531560;$$55 = $508;$$551258 = $$541257;$$551364 = $507;
  27377. label = 132;
  27378. }
  27379. break;
  27380. }
  27381. case 154: {
  27382. label = 0;
  27383. $$0971 = $$0971$shrunk&255;
  27384. $575 = $$0971 << $$62;
  27385. $576 = $575 | $$621371;
  27386. $577 = (($$62) + 8)|0;
  27387. $578 = ($577>>>0)<(15);
  27388. if ($578) {
  27389. $$551471 = $$571473;$$551662 = $$571664;$$581049 = $$601051;$$591156 = $$611158;$$591566 = $$611568;$$60 = $577;$$601263 = $$621265;$$601369 = $576;
  27390. label = 145;
  27391. } else {
  27392. $$581474 = $$571473;$$581665 = $$571664;$$611052 = $$601051;$$621569 = $$611568;$$63 = $577;$$631266 = $$621265;$$631372 = $576;
  27393. label = 156;
  27394. }
  27395. break;
  27396. }
  27397. case 183: {
  27398. label = 0;
  27399. $$0959 = $$0959$shrunk&255;
  27400. $699 = $$0959 << $$71;
  27401. $700 = $699 | $$711380;
  27402. $701 = (($$71) + 8)|0;
  27403. $702 = ($701>>>0)<($$681271>>>0);
  27404. if ($702) {
  27405. $$611477 = $$631479;$$621669 = $$641671;$$641055 = $$661057;$$651162 = $$671164;$$661269 = $$681271;$$681575 = $$701577;$$69 = $701;$$691378 = $700;
  27406. label = 179;
  27407. } else {
  27408. $$641480 = $$631479;$$651672 = $$641671;$$671058 = $$661057;$$681165 = $$671164;$$691272 = $$681271;$$711578 = $$701577;$$72 = $701;$$721381 = $700;
  27409. label = 184;
  27410. }
  27411. break;
  27412. }
  27413. case 196: {
  27414. label = 0;
  27415. $$0952 = $$0952$shrunk&255;
  27416. $740 = $$0952 << $$76;
  27417. $741 = $740 | $$761385;
  27418. $742 = (($$76) + 8)|0;
  27419. $743 = ($742>>>0)<(15);
  27420. if ($743) {
  27421. $$661482 = $$681484;$$671674 = $$691676;$$691060 = $$711062;$$701167 = $$721169;$$711274 = $$731276;$$731580 = $$751582;$$74 = $742;$$741383 = $741;
  27422. label = 187;
  27423. } else {
  27424. $$691485 = $$681484;$$701677 = $$691676;$$731170 = $$721169;$$761583 = $$751582;$$77 = $742;$$771386 = $741;
  27425. label = 198;
  27426. }
  27427. break;
  27428. }
  27429. case 207: {
  27430. label = 0;
  27431. $$0950 = $$0950$shrunk&255;
  27432. $787 = $$0950 << $$80;
  27433. $788 = $787 | $$801389;
  27434. $789 = (($$80) + 8)|0;
  27435. $790 = ($789>>>0)<($$761279>>>0);
  27436. if ($790) {
  27437. $$701486 = $$721488;$$711678 = $$731680;$$721063 = $$741065;$$741171 = $$761173;$$741277 = $$761279;$$771584 = $$791586;$$78 = $789;$$781387 = $788;
  27438. label = 203;
  27439. } else {
  27440. $$741681 = $$731680;$$751066 = $$741065;$$771174 = $$761173;$$771280 = $$761279;$$801587 = $$791586;$$81 = $789;$$811390 = $788;
  27441. label = 208;
  27442. }
  27443. break;
  27444. }
  27445. case 227: {
  27446. label = 0;
  27447. $852 = ($$871184>>>0)<(4);
  27448. if (!($852)) {
  27449. $$881504 = $$811497;$$921083 = $$851076;$$921699 = $$851692;$$941191 = $$871184;$$941297 = $$871290;$$971604 = $$901597;$$98 = $$91;$$981407 = $$911400;
  27450. label = 242;
  27451. continue L46;
  27452. }
  27453. $853 = ($$91|0)==(0);
  27454. if (!($853)) {
  27455. $854 = ($$91>>>0)<(8);
  27456. if ($854) {
  27457. $$821498 = $$811497;$$861077 = $$851076;$$861693 = $$851692;$$881185 = $$871184;$$881291 = $$871290;$$911598 = $$901597;$$92 = $$91;$$921401 = $$911400;
  27458. label = 230;
  27459. break;
  27460. } else {
  27461. $$851501 = $$811497;$$891080 = $$851076;$$891696 = $$851692;$$911188 = $$871184;$$911294 = $$871290;$$941601 = $$901597;$$95 = $$91;$$951404 = $$911400;
  27462. label = 235;
  27463. break;
  27464. }
  27465. }
  27466. $868 = ($$901597>>>0)<($10>>>0);
  27467. if (!($868)) {
  27468. $$861502 = $$811497;$$901081 = $$851076;$$901697 = $$851692;$$921189 = $$871184;$$921295 = $$871290;$$951602 = $$901597;$$96 = 0;$$961405 = $$911400;
  27469. label = 237;
  27470. continue L46;
  27471. }
  27472. $875 = ((($$901597)) + 1|0);
  27473. $876 = HEAP8[$$901597>>0]|0;
  27474. $877 = $876&255;
  27475. $$0948 = $877;$$871503 = $$811497;$$911082 = $$851076;$$911698 = $$851692;$$931190 = $$871184;$$931296 = $$871290;$$961603 = $875;$$97 = 0;$$971406 = $$911400;
  27476. label = 241;
  27477. continue L46;
  27478. break;
  27479. }
  27480. case 234: {
  27481. label = 0;
  27482. $$0947 = $$0947$shrunk&255;
  27483. $861 = $$0947 << $$94;
  27484. $862 = $861 | $$941403;
  27485. $863 = (($$94) + 8)|0;
  27486. $864 = ($$94>>>0)>(4294967287);
  27487. if ($864) {
  27488. $$821498 = $$841500;$$861077 = $$881079;$$861693 = $$881695;$$881185 = $$901187;$$881291 = $$901293;$$911598 = $$931600;$$92 = $863;$$921401 = $862;
  27489. label = 230;
  27490. } else {
  27491. $$851501 = $$841500;$$891080 = $$881079;$$891696 = $$881695;$$911188 = $$901187;$$911294 = $$901293;$$941601 = $$931600;$$95 = $863;$$951404 = $862;
  27492. label = 235;
  27493. }
  27494. break;
  27495. }
  27496. }
  27497. L119: do {
  27498. if ((label|0) == 15) {
  27499. label = 0;
  27500. $72 = ($$51512>>>0)<($10>>>0);
  27501. if ($72) {
  27502. $$31419$ph = $$11417;$$31610$ph = $$11608;$$8$ph = $$6;$$81105$ph = $$61103;$$81211$ph = $$61209;$$81317$ph = $$61315;$$8999$ph = $$6997;$$sink1710 = $$51512;
  27503. label = 18;
  27504. continue L46;
  27505. } else {
  27506. $$21418 = $$11417;$$21609 = $$11608;$$61513 = $$51512;$$7 = $$6;$$71104 = $$61103;$$71210 = $$61209;$$71316 = $$61315;$$7998 = $$6997;
  27507. label = 16;
  27508. continue L46;
  27509. }
  27510. }
  27511. else if ((label|0) == 20) {
  27512. label = 0;
  27513. $82 = $$91318 & 7;
  27514. $83 = ((($0)) + 20|0);
  27515. HEAP32[$83>>2] = $82;
  27516. $84 = $$91318 >>> 3;
  27517. $85 = (($$9) + -3)|0;
  27518. $86 = $82 >>> 1;
  27519. $87 = ((($0)) + 24|0);
  27520. HEAP32[$87>>2] = $86;
  27521. $trunc = $86&255;
  27522. $trunc$clear = $trunc & 3;
  27523. switch ($trunc$clear<<24>>24) {
  27524. case 0: {
  27525. $$121519 = $$81515;$$13 = $85;$$131004 = $$91000;$$131216 = $$91212;$$131322 = $84;$$81424 = $$41420;$$81615 = $$41611;
  27526. label = 25;
  27527. continue L46;
  27528. break;
  27529. }
  27530. case 3: {
  27531. $$281444 = $$41420;$$281635 = $$41611;$$321023 = $$91000;$$321129 = $$91106;$$321539 = $$81515;$$33 = $85;$$331236 = $$91212;$$331342 = $84;
  27532. label = 60;
  27533. continue L46;
  27534. break;
  27535. }
  27536. case 1: {
  27537. break;
  27538. }
  27539. default: {
  27540. $$291445 = $$41420;$$291636 = $$41611;$$331024 = $$91000;$$331130 = 0;$$331540 = $$81515;$$34 = $85;$$341237 = $$91212;$$341343 = $84;
  27541. label = 61;
  27542. break L119;
  27543. }
  27544. }
  27545. $240 = ((($0)) + 44|0);
  27546. HEAP32[$240>>2] = 288;
  27547. $241 = ((($0)) + 48|0);
  27548. HEAP32[$241>>2] = 32;
  27549. $242 = ((($0)) + 3552|0);
  27550. ;HEAP32[$242>>2]=84215045|0;HEAP32[$242+4>>2]=84215045|0;HEAP32[$242+8>>2]=84215045|0;HEAP32[$242+12>>2]=84215045|0;HEAP32[$242+16>>2]=84215045|0;HEAP32[$242+20>>2]=84215045|0;HEAP32[$242+24>>2]=84215045|0;HEAP32[$242+28>>2]=84215045|0;
  27551. $scevgep19611962 = ((($0)) + 64|0);
  27552. _memset(($scevgep19611962|0),8,144)|0;
  27553. $scevgep1959 = ((($0)) + 208|0);
  27554. dest=$scevgep1959; stop=dest+112|0; do { HEAP8[dest>>0]=9|0; dest=dest+1|0; } while ((dest|0) < (stop|0));
  27555. $scevgep1957 = ((($0)) + 320|0);
  27556. dest=$scevgep1957; stop=dest+24|0; do { HEAP8[dest>>0]=7|0; dest=dest+1|0; } while ((dest|0) < (stop|0));
  27557. $scevgep1955 = ((($0)) + 344|0);
  27558. $243 = $scevgep1955;
  27559. $244 = $243;
  27560. HEAP8[$244>>0]=134744072&255;HEAP8[$244+1>>0]=(134744072>>8)&255;HEAP8[$244+2>>0]=(134744072>>16)&255;HEAP8[$244+3>>0]=134744072>>24;
  27561. $245 = (($243) + 4)|0;
  27562. $246 = $245;
  27563. HEAP8[$246>>0]=134744072&255;HEAP8[$246+1>>0]=(134744072>>8)&255;HEAP8[$246+2>>0]=(134744072>>16)&255;HEAP8[$246+3>>0]=134744072>>24;
  27564. $$391455 = $$41420;$$391646 = $$41611;$$431034 = $$91000;$$431140 = $$91106;$$431550 = $$81515;$$44 = $85;$$441247 = $$91212;$$441353 = $84;
  27565. label = 80;
  27566. }
  27567. else if ((label|0) == 230) {
  27568. label = 0;
  27569. $855 = ($$911598>>>0)<($10>>>0);
  27570. if ($855) {
  27571. $$841500$ph = $$821498;$$881079$ph = $$861077;$$881695$ph = $$861693;$$901187$ph = $$881185;$$901293$ph = $$881291;$$94$ph = $$92;$$941403$ph = $$921401;$$sink1750 = $$911598;
  27572. label = 233;
  27573. continue L46;
  27574. } else {
  27575. $$831499 = $$821498;$$871078 = $$861077;$$871694 = $$861693;$$891186 = $$881185;$$891292 = $$881291;$$921599 = $$911598;$$93 = $$92;$$931402 = $$921401;
  27576. label = 231;
  27577. continue L46;
  27578. }
  27579. }
  27580. else if ((label|0) == 235) {
  27581. label = 0;
  27582. $865 = $$951404 & 255;
  27583. $866 = $$951404 >>> 8;
  27584. $867 = (($$95) + -8)|0;
  27585. $$0948 = $865;$$871503 = $$851501;$$911082 = $$891080;$$911698 = $$891696;$$931190 = $$911188;$$931296 = $$911294;$$961603 = $$941601;$$97 = $867;$$971406 = $866;
  27586. label = 241;
  27587. continue L46;
  27588. }
  27589. } while(0);
  27590. L125: while(1) {
  27591. L126: switch (label|0) {
  27592. case 26: {
  27593. label = 0;
  27594. $100 = ($$131110>>>0)<(4);
  27595. if (!($100)) {
  27596. $127 = ((($0)) + 10528|0);
  27597. $128 = HEAP8[$127>>0]|0;
  27598. $129 = $128&255;
  27599. $130 = ((($0)) + 10529|0);
  27600. $131 = HEAP8[$130>>0]|0;
  27601. $132 = $131&255;
  27602. $133 = $132 << 8;
  27603. $134 = $133 | $129;
  27604. $135 = ((($0)) + 10530|0);
  27605. $136 = HEAP8[$135>>0]|0;
  27606. $137 = $136&255;
  27607. $138 = ((($0)) + 10531|0);
  27608. $139 = HEAP8[$138>>0]|0;
  27609. $140 = $139&255;
  27610. $141 = $140 << 8;
  27611. $142 = $141 | $137;
  27612. $143 = $142 ^ 65535;
  27613. $144 = ($134|0)==($143|0);
  27614. if ($144) {
  27615. $$181434 = $$91425;$$181625 = $$91616;$$221119 = $134;$$221529 = $$131520;$$23 = $$14;$$231014 = $$141005;$$231226 = $$141217;$$231332 = $$141323;
  27616. label = 44;
  27617. continue L125;
  27618. } else {
  27619. $$171433 = $$91425;$$171624 = $$91616;$$211118 = $134;$$211528 = $$131520;$$22 = $$14;$$221013 = $$141005;$$221225 = $$141217;$$221331 = $$141323;
  27620. label = 43;
  27621. continue L46;
  27622. }
  27623. }
  27624. $101 = ($$14|0)==(0);
  27625. if (!($101)) {
  27626. $102 = ($$14>>>0)<(8);
  27627. if ($102) {
  27628. $$101426 = $$91425;$$101617 = $$91616;$$141111 = $$131110;$$141521 = $$131520;$$15 = $$14;$$151006 = $$141005;$$151218 = $$141217;$$151324 = $$141323;
  27629. label = 29;
  27630. continue L125;
  27631. } else {
  27632. $$131429 = $$91425;$$131620 = $$91616;$$171114 = $$131110;$$171524 = $$131520;$$18 = $$14;$$181009 = $$141005;$$181221 = $$141217;$$181327 = $$141323;
  27633. label = 34;
  27634. continue L125;
  27635. }
  27636. }
  27637. $117 = ($$131520>>>0)<($10>>>0);
  27638. if (!($117)) {
  27639. $$141430 = $$91425;$$141621 = $$91616;$$181115 = $$131110;$$181525 = $$131520;$$19 = 0;$$191010 = $$141005;$$191222 = $$141217;$$191328 = $$141323;
  27640. label = 36;
  27641. continue L46;
  27642. }
  27643. $123 = ((($$131520)) + 1|0);
  27644. $124 = HEAP8[$$131520>>0]|0;
  27645. $125 = (((($0)) + 10528|0) + ($$131110)|0);
  27646. HEAP8[$125>>0] = $124;
  27647. $$161432 = $$91425;$$161623 = $$91616;$$201117 = $$131110;$$201527 = $123;$$21 = 0;$$211012 = $$141005;$$211224 = $$141217;$$211330 = $$141323;
  27648. label = 41;
  27649. continue L125;
  27650. break;
  27651. }
  27652. case 29: {
  27653. label = 0;
  27654. $103 = ($$141521>>>0)<($10>>>0);
  27655. if ($103) {
  27656. $$121428$ph = $$101426;$$121619$ph = $$101617;$$161113$ph = $$141111;$$17$ph = $$15;$$171008$ph = $$151006;$$171220$ph = $$151218;$$171326$ph = $$151324;$$sink1713 = $$141521;
  27657. label = 32;
  27658. continue L46;
  27659. } else {
  27660. $$111427 = $$101426;$$111618 = $$101617;$$151112 = $$141111;$$151522 = $$141521;$$16 = $$15;$$161007 = $$151006;$$161219 = $$151218;$$161325 = $$151324;
  27661. label = 30;
  27662. continue L46;
  27663. }
  27664. break;
  27665. }
  27666. case 34: {
  27667. label = 0;
  27668. $113 = $$181327&255;
  27669. $114 = (((($0)) + 10528|0) + ($$171114)|0);
  27670. HEAP8[$114>>0] = $113;
  27671. $115 = $$181327 >>> 8;
  27672. $116 = (($$18) + -8)|0;
  27673. $$161432 = $$131429;$$161623 = $$131620;$$201117 = $$171114;$$201527 = $$171524;$$21 = $116;$$211012 = $$181009;$$211224 = $$181221;$$211330 = $115;
  27674. label = 41;
  27675. continue L125;
  27676. break;
  27677. }
  27678. case 41: {
  27679. label = 0;
  27680. $126 = (($$201117) + 1)|0;
  27681. $$131110 = $126;$$131520 = $$201527;$$14 = $$21;$$141005 = $$211012;$$141217 = $$211224;$$141323 = $$211330;$$91425 = $$161432;$$91616 = $$161623;
  27682. label = 26;
  27683. continue L125;
  27684. break;
  27685. }
  27686. case 44: {
  27687. label = 0;
  27688. $145 = ($$221119|0)!=(0);
  27689. $146 = ($$23|0)!=(0);
  27690. $147 = $145 & $146;
  27691. if (!($147)) {
  27692. $$241440 = $$181434;$$241631 = $$181625;$$281019 = $$231014;$$281125 = $$221119;$$281535 = $$221529;$$29 = $$23;$$291232 = $$231226;$$291338 = $$231332;
  27693. label = 54;
  27694. continue L125;
  27695. }
  27696. $148 = ($$23>>>0)<(8);
  27697. if ($148) {
  27698. $$191435 = $$181434;$$191626 = $$181625;$$231120 = $$221119;$$231530 = $$221529;$$24 = $$23;$$241015 = $$231014;$$241227 = $$231226;$$241333 = $$231332;
  27699. label = 46;
  27700. continue L125;
  27701. } else {
  27702. $$221438 = $$181434;$$221629 = $$181625;$$261123 = $$221119;$$261533 = $$221529;$$27 = $$23;$$271230 = $$231226;$$271336 = $$231332;
  27703. label = 51;
  27704. continue L125;
  27705. }
  27706. break;
  27707. }
  27708. case 46: {
  27709. label = 0;
  27710. $149 = ($$231530>>>0)<($10>>>0);
  27711. if ($149) {
  27712. $$211437$ph = $$191435;$$211628$ph = $$191626;$$251122$ph = $$231120;$$26$ph = $$24;$$261017$ph = $$241015;$$261229$ph = $$241227;$$261335$ph = $$241333;$$sink1716 = $$231530;
  27713. label = 49;
  27714. continue L46;
  27715. } else {
  27716. $$201436 = $$191435;$$201627 = $$191626;$$241121 = $$231120;$$241531 = $$231530;$$25 = $$24;$$251016 = $$241015;$$251228 = $$241227;$$251334 = $$241333;
  27717. label = 47;
  27718. continue L46;
  27719. }
  27720. break;
  27721. }
  27722. case 51: {
  27723. label = 0;
  27724. $159 = $$271336 & 255;
  27725. $160 = $$271336 >>> 8;
  27726. $161 = (($$27) + -8)|0;
  27727. $$231439 = $$221438;$$231630 = $$221629;$$271018 = $159;$$271124 = $$261123;$$271534 = $$261533;$$28 = $161;$$281231 = $$271230;$$281337 = $160;
  27728. label = 52;
  27729. continue L46;
  27730. break;
  27731. }
  27732. case 54: {
  27733. label = 0;
  27734. $166 = ($$281125|0)==(0);
  27735. if ($166) {
  27736. $$761492 = $$241440;$$801071 = $$281019;$$801687 = $$241631;$$821285 = $$291232;$$831180 = 0;$$851592 = $$281535;$$86 = $$29;$$861395 = $$291338;
  27737. label = 220;
  27738. break L125;
  27739. } else {
  27740. $$251441 = $$241440;$$251632 = $$241631;$$291020 = $$281019;$$291126 = $$281125;$$291536 = $$281535;$$30 = $$29;$$301233 = $$291232;$$301339 = $$291338;
  27741. label = 55;
  27742. continue L46;
  27743. }
  27744. break;
  27745. }
  27746. case 61: {
  27747. label = 0;
  27748. $185 = ($$331130>>>0)<(3);
  27749. if ($185) {
  27750. $186 = (15201 + ($$331130)|0);
  27751. $187 = HEAP8[$186>>0]|0;
  27752. $188 = $187 << 24 >> 24;
  27753. $189 = ($$34>>>0)<($188>>>0);
  27754. if ($189) {
  27755. $$301446 = $$291445;$$301637 = $$291636;$$341025 = $$331024;$$341131 = $$331130;$$341541 = $$331540;$$35 = $$34;$$351238 = $$341237;$$351344 = $$341343;
  27756. label = 63;
  27757. continue L125;
  27758. } else {
  27759. $$331449 = $$291445;$$331640 = $$291636;$$371028 = $$331024;$$371134 = $$331130;$$371544 = $$331540;$$38 = $$34;$$381241 = $$341237;$$381347 = $$341343;
  27760. label = 68;
  27761. continue L125;
  27762. }
  27763. } else {
  27764. $216 = ((($0)) + 7040|0);
  27765. _memset(($216|0),0,288)|0;
  27766. $$341450 = $$291445;$$341641 = $$291636;$$381029 = $$331024;$$381135 = 0;$$381545 = $$331540;$$39 = $$34;$$391242 = $$341237;$$391348 = $$341343;
  27767. label = 70;
  27768. break;
  27769. }
  27770. break;
  27771. }
  27772. case 63: {
  27773. label = 0;
  27774. $190 = ($$341541>>>0)<($10>>>0);
  27775. if ($190) {
  27776. $$321448$ph = $$301446;$$321639$ph = $$301637;$$361027$ph = $$341025;$$361133$ph = $$341131;$$37$ph = $$35;$$371240$ph = $$351238;$$371346$ph = $$351344;$$sink1719 = $$341541;
  27777. label = 66;
  27778. continue L46;
  27779. } else {
  27780. $$311447 = $$301446;$$311638 = $$301637;$$351026 = $$341025;$$351132 = $$341131;$$351542 = $$341541;$$36 = $$35;$$361239 = $$351238;$$361345 = $$351344;
  27781. label = 64;
  27782. continue L46;
  27783. }
  27784. break;
  27785. }
  27786. case 68: {
  27787. label = 0;
  27788. $203 = (15201 + ($$371134)|0);
  27789. $204 = HEAP8[$203>>0]|0;
  27790. $205 = $204 << 24 >> 24;
  27791. $206 = 1 << $205;
  27792. $207 = (($206) + -1)|0;
  27793. $208 = $207 & $$381347;
  27794. $209 = (((($0)) + 44|0) + ($$371134<<2)|0);
  27795. $210 = $$381347 >>> $205;
  27796. $211 = (($$38) - ($205))|0;
  27797. $212 = (4592 + ($$371134<<2)|0);
  27798. $213 = HEAP32[$212>>2]|0;
  27799. $214 = (($208) + ($213))|0;
  27800. HEAP32[$209>>2] = $214;
  27801. $215 = (($$371134) + 1)|0;
  27802. $$291445 = $$331449;$$291636 = $$331640;$$331024 = $$371028;$$331130 = $215;$$331540 = $$371544;$$34 = $211;$$341237 = $$381241;$$341343 = $210;
  27803. label = 61;
  27804. continue L125;
  27805. break;
  27806. }
  27807. case 72: {
  27808. label = 0;
  27809. $221 = ($$391546>>>0)<($10>>>0);
  27810. if ($221) {
  27811. $$371453$ph = $$351451;$$371644$ph = $$351642;$$411032$ph = $$391030;$$411138$ph = $$391136;$$42$ph = $$40;$$421245$ph = $$401243;$$421351$ph = $$401349;$$sink1722 = $$391546;
  27812. label = 75;
  27813. continue L46;
  27814. } else {
  27815. $$361452 = $$351451;$$361643 = $$351642;$$401031 = $$391030;$$401137 = $$391136;$$401547 = $$391546;$$41 = $$40;$$411244 = $$401243;$$411350 = $$401349;
  27816. label = 73;
  27817. continue L46;
  27818. }
  27819. break;
  27820. }
  27821. case 77: {
  27822. label = 0;
  27823. $231 = $$431352 & 7;
  27824. $232 = $$431352 >>> 3;
  27825. $233 = (($$43) + -3)|0;
  27826. $234 = $231&255;
  27827. $235 = (15205 + ($$421139)|0);
  27828. $236 = HEAP8[$235>>0]|0;
  27829. $237 = $236&255;
  27830. $238 = (((($0)) + 7040|0) + ($237)|0);
  27831. HEAP8[$238>>0] = $234;
  27832. $239 = (($$421139) + 1)|0;
  27833. $$341450 = $$381454;$$341641 = $$381645;$$381029 = $$421033;$$381135 = $239;$$381545 = $$421549;$$39 = $233;$$391242 = $$431246;$$391348 = $232;
  27834. label = 70;
  27835. break;
  27836. }
  27837. case 80: {
  27838. label = 0;
  27839. $247 = ((($0)) + 24|0);
  27840. $248 = HEAP32[$247>>2]|0;
  27841. $249 = ($248|0)>(-1);
  27842. if ($249) {
  27843. dest=$8; stop=dest+64|0; do { HEAP32[dest>>2]=0|0; dest=dest+4|0; } while ((dest|0) < (stop|0));
  27844. $250 = (((((($0)) + 64|0) + (($248*3488)|0)|0)) + 288|0);
  27845. _memset(($250|0),0,3200)|0;
  27846. $251 = HEAP32[$247>>2]|0;
  27847. $252 = (((($0)) + 44|0) + ($251<<2)|0);
  27848. $253 = HEAP32[$252>>2]|0;
  27849. $254 = ($253|0)==(0);
  27850. if (!($254)) {
  27851. $255 = HEAP32[$247>>2]|0;
  27852. $256 = (((($0)) + 44|0) + ($255<<2)|0);
  27853. $257 = HEAP32[$256>>2]|0;
  27854. $$010951864 = 0;
  27855. while(1) {
  27856. $258 = ((((($0)) + 64|0) + (($248*3488)|0)|0) + ($$010951864)|0);
  27857. $259 = HEAP8[$258>>0]|0;
  27858. $260 = $259&255;
  27859. $261 = (($8) + ($260<<2)|0);
  27860. $262 = HEAP32[$261>>2]|0;
  27861. $263 = (($262) + 1)|0;
  27862. HEAP32[$261>>2] = $263;
  27863. $264 = (($$010951864) + 1)|0;
  27864. $265 = ($264>>>0)<($257>>>0);
  27865. if ($265) {
  27866. $$010951864 = $264;
  27867. } else {
  27868. break;
  27869. }
  27870. }
  27871. }
  27872. $266 = ((($7)) + 4|0);
  27873. HEAP32[$266>>2] = 0;
  27874. HEAP32[$7>>2] = 0;
  27875. $267 = ((($8)) + 4|0);
  27876. $268 = HEAP32[$267>>2]|0;
  27877. $269 = $268 << 1;
  27878. $270 = ((($7)) + 8|0);
  27879. HEAP32[$270>>2] = $269;
  27880. $271 = ((($8)) + 8|0);
  27881. $272 = HEAP32[$271>>2]|0;
  27882. $273 = (($272) + ($268))|0;
  27883. $274 = (($272) + ($269))|0;
  27884. $275 = $274 << 1;
  27885. $276 = ((($7)) + 12|0);
  27886. HEAP32[$276>>2] = $275;
  27887. $277 = ((($8)) + 12|0);
  27888. $278 = HEAP32[$277>>2]|0;
  27889. $279 = (($278) + ($273))|0;
  27890. $280 = (($278) + ($275))|0;
  27891. $281 = $280 << 1;
  27892. $282 = ((($7)) + 16|0);
  27893. HEAP32[$282>>2] = $281;
  27894. $283 = ((($8)) + 16|0);
  27895. $284 = HEAP32[$283>>2]|0;
  27896. $285 = (($284) + ($279))|0;
  27897. $286 = (($284) + ($281))|0;
  27898. $287 = $286 << 1;
  27899. $288 = ((($7)) + 20|0);
  27900. HEAP32[$288>>2] = $287;
  27901. $289 = ((($8)) + 20|0);
  27902. $290 = HEAP32[$289>>2]|0;
  27903. $291 = (($290) + ($285))|0;
  27904. $292 = (($290) + ($287))|0;
  27905. $293 = $292 << 1;
  27906. $294 = ((($7)) + 24|0);
  27907. HEAP32[$294>>2] = $293;
  27908. $295 = ((($8)) + 24|0);
  27909. $296 = HEAP32[$295>>2]|0;
  27910. $297 = (($296) + ($291))|0;
  27911. $298 = (($296) + ($293))|0;
  27912. $299 = $298 << 1;
  27913. $300 = ((($7)) + 28|0);
  27914. HEAP32[$300>>2] = $299;
  27915. $301 = ((($8)) + 28|0);
  27916. $302 = HEAP32[$301>>2]|0;
  27917. $303 = (($302) + ($297))|0;
  27918. $304 = (($302) + ($299))|0;
  27919. $305 = $304 << 1;
  27920. $306 = ((($7)) + 32|0);
  27921. HEAP32[$306>>2] = $305;
  27922. $307 = ((($8)) + 32|0);
  27923. $308 = HEAP32[$307>>2]|0;
  27924. $309 = (($308) + ($303))|0;
  27925. $310 = (($308) + ($305))|0;
  27926. $311 = $310 << 1;
  27927. $312 = ((($7)) + 36|0);
  27928. HEAP32[$312>>2] = $311;
  27929. $313 = ((($8)) + 36|0);
  27930. $314 = HEAP32[$313>>2]|0;
  27931. $315 = (($314) + ($309))|0;
  27932. $316 = (($314) + ($311))|0;
  27933. $317 = $316 << 1;
  27934. $318 = ((($7)) + 40|0);
  27935. HEAP32[$318>>2] = $317;
  27936. $319 = ((($8)) + 40|0);
  27937. $320 = HEAP32[$319>>2]|0;
  27938. $321 = (($320) + ($315))|0;
  27939. $322 = (($320) + ($317))|0;
  27940. $323 = $322 << 1;
  27941. $324 = ((($7)) + 44|0);
  27942. HEAP32[$324>>2] = $323;
  27943. $325 = ((($8)) + 44|0);
  27944. $326 = HEAP32[$325>>2]|0;
  27945. $327 = (($326) + ($321))|0;
  27946. $328 = (($326) + ($323))|0;
  27947. $329 = $328 << 1;
  27948. $330 = ((($7)) + 48|0);
  27949. HEAP32[$330>>2] = $329;
  27950. $331 = ((($8)) + 48|0);
  27951. $332 = HEAP32[$331>>2]|0;
  27952. $333 = (($332) + ($327))|0;
  27953. $334 = (($332) + ($329))|0;
  27954. $335 = $334 << 1;
  27955. $336 = ((($7)) + 52|0);
  27956. HEAP32[$336>>2] = $335;
  27957. $337 = ((($8)) + 52|0);
  27958. $338 = HEAP32[$337>>2]|0;
  27959. $339 = (($338) + ($333))|0;
  27960. $340 = (($338) + ($335))|0;
  27961. $341 = $340 << 1;
  27962. $342 = ((($7)) + 56|0);
  27963. HEAP32[$342>>2] = $341;
  27964. $343 = ((($8)) + 56|0);
  27965. $344 = HEAP32[$343>>2]|0;
  27966. $345 = (($344) + ($339))|0;
  27967. $346 = (($344) + ($341))|0;
  27968. $347 = $346 << 1;
  27969. $348 = ((($7)) + 60|0);
  27970. HEAP32[$348>>2] = $347;
  27971. $349 = ((($8)) + 60|0);
  27972. $350 = HEAP32[$349>>2]|0;
  27973. $351 = (($350) + ($345))|0;
  27974. $352 = (($350) + ($347))|0;
  27975. $353 = $352 << 1;
  27976. $354 = ((($7)) + 64|0);
  27977. HEAP32[$354>>2] = $353;
  27978. $355 = ($353|0)!=(65536);
  27979. $356 = ($351>>>0)>(1);
  27980. $or$cond = $355 & $356;
  27981. if ($or$cond) {
  27982. $$401456 = $$391455;$$401647 = $$391646;$$441035 = $$431034;$$441141 = $$431140;$$441551 = $$431550;$$45 = $$44;$$451248 = $$441247;$$451354 = $$441353;
  27983. label = 86;
  27984. continue L46;
  27985. }
  27986. $357 = HEAP32[$247>>2]|0;
  27987. $358 = (((($0)) + 44|0) + ($357<<2)|0);
  27988. $359 = HEAP32[$358>>2]|0;
  27989. $360 = ($359|0)==(0);
  27990. if ($360) {
  27991. $$lcssa1779 = $357;
  27992. } else {
  27993. $$010911856 = 0;$$011971855 = -1;
  27994. while(1) {
  27995. $361 = ((((($0)) + 64|0) + (($248*3488)|0)|0) + ($$010911856)|0);
  27996. $362 = HEAP8[$361>>0]|0;
  27997. $363 = $362&255;
  27998. $364 = ($362<<24>>24)==(0);
  27999. L142: do {
  28000. if ($364) {
  28001. $$41201 = $$011971855;
  28002. } else {
  28003. $365 = (($7) + ($363<<2)|0);
  28004. $366 = HEAP32[$365>>2]|0;
  28005. $367 = (($366) + 1)|0;
  28006. HEAP32[$365>>2] = $367;
  28007. $$010861840 = $366;$$010871839 = $363;$$010881838 = 0;
  28008. while(1) {
  28009. $368 = $$010881838 << 1;
  28010. $369 = $$010861840 & 1;
  28011. $370 = $369 | $368;
  28012. $371 = (($$010871839) + -1)|0;
  28013. $372 = $$010861840 >>> 1;
  28014. $373 = ($371|0)==(0);
  28015. if ($373) {
  28016. break;
  28017. } else {
  28018. $$010861840 = $372;$$010871839 = $371;$$010881838 = $370;
  28019. }
  28020. }
  28021. $374 = ($362&255)<(11);
  28022. if ($374) {
  28023. $375 = $363 << 9;
  28024. $376 = $375 | $$010911856;
  28025. $377 = $376&65535;
  28026. $378 = ($370>>>0)<(1024);
  28027. if (!($378)) {
  28028. $$41201 = $$011971855;
  28029. break;
  28030. }
  28031. $379 = 1 << $363;
  28032. $$110891852 = $370;
  28033. while(1) {
  28034. $380 = ((((((($0)) + 64|0) + (($248*3488)|0)|0)) + 288|0) + ($$110891852<<1)|0);
  28035. HEAP16[$380>>1] = $377;
  28036. $381 = (($$110891852) + ($379))|0;
  28037. $382 = ($381>>>0)<(1024);
  28038. if ($382) {
  28039. $$110891852 = $381;
  28040. } else {
  28041. $$41201 = $$011971855;
  28042. break L142;
  28043. }
  28044. }
  28045. }
  28046. $383 = $370 & 1023;
  28047. $384 = ((((((($0)) + 64|0) + (($248*3488)|0)|0)) + 288|0) + ($383<<1)|0);
  28048. $385 = HEAP16[$384>>1]|0;
  28049. $386 = $385 << 16 >> 16;
  28050. $387 = ($385<<16>>16)==(0);
  28051. if ($387) {
  28052. $388 = (($$011971855) + -2)|0;
  28053. $389 = $$011971855&65535;
  28054. HEAP16[$384>>1] = $389;
  28055. $$01194 = $$011971855;$$11198 = $388;
  28056. } else {
  28057. $$01194 = $386;$$11198 = $$011971855;
  28058. }
  28059. $390 = $$010881838 >>> 9;
  28060. $391 = ($362&255)>(11);
  28061. $392 = $390 & 1;
  28062. $393 = (($392) - ($$01194))|0;
  28063. $394 = (($393) + -1)|0;
  28064. if ($391) {
  28065. $395 = $390 & 4194303;
  28066. $$010941846 = $363;$$211991845 = $$11198;$397 = $394;$406 = $395;
  28067. while(1) {
  28068. $396 = ((((((($0)) + 64|0) + (($248*3488)|0)|0)) + 2336|0) + ($397<<1)|0);
  28069. $398 = HEAP16[$396>>1]|0;
  28070. $399 = ($398<<16>>16)==(0);
  28071. if ($399) {
  28072. $400 = $$211991845&65535;
  28073. HEAP16[$396>>1] = $400;
  28074. $401 = (($$211991845) + -2)|0;
  28075. $$21196 = $$211991845;$$31200 = $401;
  28076. } else {
  28077. $402 = $398 << 16 >> 16;
  28078. $$21196 = $402;$$31200 = $$211991845;
  28079. }
  28080. $403 = (($$010941846) + -1)|0;
  28081. $404 = ($403>>>0)>(11);
  28082. $405 = $406 >>> 1;
  28083. $407 = $405 & 1;
  28084. $408 = (($407) - ($$21196))|0;
  28085. $409 = (($408) + -1)|0;
  28086. if ($404) {
  28087. $$010941846 = $403;$$211991845 = $$31200;$397 = $409;$406 = $405;
  28088. } else {
  28089. $$21199$lcssa = $$31200;$$lcssa1778 = $409;
  28090. break;
  28091. }
  28092. }
  28093. } else {
  28094. $$21199$lcssa = $$11198;$$lcssa1778 = $394;
  28095. }
  28096. $410 = $$010911856&65535;
  28097. $411 = ((((((($0)) + 64|0) + (($248*3488)|0)|0)) + 2336|0) + ($$lcssa1778<<1)|0);
  28098. HEAP16[$411>>1] = $410;
  28099. $$41201 = $$21199$lcssa;
  28100. }
  28101. } while(0);
  28102. $412 = (($$010911856) + 1)|0;
  28103. $413 = HEAP32[$247>>2]|0;
  28104. $414 = (((($0)) + 44|0) + ($413<<2)|0);
  28105. $415 = HEAP32[$414>>2]|0;
  28106. $416 = ($412>>>0)<($415>>>0);
  28107. if ($416) {
  28108. $$010911856 = $412;$$011971855 = $$41201;
  28109. } else {
  28110. $$lcssa1779 = $413;
  28111. break;
  28112. }
  28113. }
  28114. }
  28115. $417 = ($$lcssa1779|0)==(2);
  28116. if ($417) {
  28117. $$411457 = $$391455;$$411648 = $$391646;$$451036 = $$431034;$$451142 = 0;$$451552 = $$431550;$$46 = $$44;$$461249 = $$441247;$$461355 = $$441353;
  28118. label = 105;
  28119. } else {
  28120. $$521468 = $$391455;$$521659 = $$391646;$$551046 = $$431034;$$561153 = $$431140;$$561563 = $$431550;$$57 = $$44;$$571260 = $$441247;$$571366 = $$441353;
  28121. label = 138;
  28122. }
  28123. } else {
  28124. $$531469 = $$391455;$$531660 = $$391646;$$561047 = $$431034;$$571154 = $$431140;$$571564 = $$431550;$$58 = $$44;$$581261 = $$441247;$$581367 = $$441353;
  28125. label = 139;
  28126. }
  28127. break;
  28128. }
  28129. case 108: {
  28130. label = 0;
  28131. $429 = $$471356 & 1023;
  28132. $430 = (((($0)) + 7328|0) + ($429<<1)|0);
  28133. $431 = HEAP16[$430>>1]|0;
  28134. $432 = $431 << 16 >> 16;
  28135. $433 = ($431<<16>>16)>(-1);
  28136. if ($433) {
  28137. $434 = $432 >> 9;
  28138. $435 = (($434) + -1)|0;
  28139. $436 = ($435>>>0)<($$47>>>0);
  28140. if ($436) {
  28141. $$451461 = $$421458;$$451652 = $$421649;$$491146 = $$461143;$$491556 = $$461553;$$50 = $$47;$$501253 = $$471250;$$501359 = $$471356;
  28142. label = 119;
  28143. continue L125;
  28144. } else {
  28145. label = 113;
  28146. break L125;
  28147. }
  28148. }
  28149. $437 = ($$47>>>0)>(10);
  28150. if ($437) {
  28151. $$0981 = 10;$$0984 = $432;
  28152. } else {
  28153. label = 113;
  28154. break L125;
  28155. }
  28156. while(1) {
  28157. $438 = $$0984 ^ -1;
  28158. $439 = $$471356 >>> $$0981;
  28159. $440 = $439 & 1;
  28160. $441 = (($440) + ($438))|0;
  28161. $442 = (((($0)) + 9376|0) + ($441<<1)|0);
  28162. $443 = HEAP16[$442>>1]|0;
  28163. $444 = ($443<<16>>16)<(0);
  28164. if (!($444)) {
  28165. $$451461 = $$421458;$$451652 = $$421649;$$491146 = $$461143;$$491556 = $$461553;$$50 = $$47;$$501253 = $$471250;$$501359 = $$471356;
  28166. label = 119;
  28167. continue L125;
  28168. }
  28169. $445 = (($$0981) + 1)|0;
  28170. $446 = $443 << 16 >> 16;
  28171. $447 = (($$0981) + 2)|0;
  28172. $448 = ($$47>>>0)<($447>>>0);
  28173. if ($448) {
  28174. label = 113;
  28175. break L125;
  28176. } else {
  28177. $$0981 = $445;$$0984 = $446;
  28178. }
  28179. }
  28180. break;
  28181. }
  28182. case 119: {
  28183. label = 0;
  28184. $471 = $$501359 & 1023;
  28185. $472 = (((($0)) + 7328|0) + ($471<<1)|0);
  28186. $473 = HEAP16[$472>>1]|0;
  28187. $474 = $473 << 16 >> 16;
  28188. $475 = ($473<<16>>16)>(-1);
  28189. if ($475) {
  28190. $476 = $474 >> 9;
  28191. $477 = $474 & 511;
  28192. $$2983 = $476;$$2986 = $477;
  28193. } else {
  28194. $$1982 = 10;$$1985 = $474;
  28195. while(1) {
  28196. $478 = $$1985 ^ -1;
  28197. $479 = (($$1982) + 1)|0;
  28198. $480 = $$501359 >>> $$1982;
  28199. $481 = $480 & 1;
  28200. $482 = (($481) + ($478))|0;
  28201. $483 = (((($0)) + 9376|0) + ($482<<1)|0);
  28202. $484 = HEAP16[$483>>1]|0;
  28203. $485 = $484 << 16 >> 16;
  28204. $486 = ($484<<16>>16)<(0);
  28205. if ($486) {
  28206. $$1982 = $479;$$1985 = $485;
  28207. } else {
  28208. $$2983 = $479;$$2986 = $485;
  28209. break;
  28210. }
  28211. }
  28212. }
  28213. $487 = $$501359 >>> $$2983;
  28214. $488 = (($$50) - ($$2983))|0;
  28215. $489 = ($$2986>>>0)<(16);
  28216. if ($489) {
  28217. $490 = $$2986&255;
  28218. $491 = (($$491146) + 1)|0;
  28219. $492 = (((($0)) + 10532|0) + ($$491146)|0);
  28220. HEAP8[$492>>0] = $490;
  28221. $$411457 = $$451461;$$411648 = $$451652;$$451036 = $$2986;$$451142 = $491;$$451552 = $$491556;$$46 = $488;$$461249 = $$501253;$$461355 = $487;
  28222. label = 105;
  28223. break;
  28224. }
  28225. $493 = ($$2986|0)!=(16);
  28226. $494 = ($$491146|0)!=(0);
  28227. $or$cond24 = $494 | $493;
  28228. if (!($or$cond24)) {
  28229. $$461462 = $$451461;$$461653 = $$451652;$$491040 = $$2986;$$501147 = $$491146;$$501557 = $$491556;$$51 = $488;$$511254 = $$501253;$$511360 = $487;
  28230. label = 125;
  28231. continue L46;
  28232. }
  28233. $495 = (($$2986) + -16)|0;
  28234. $496 = (15224 + ($495)|0);
  28235. $497 = HEAP8[$496>>0]|0;
  28236. $498 = $497 << 24 >> 24;
  28237. $499 = ($488>>>0)<($498>>>0);
  28238. if ($499) {
  28239. $$471463 = $$451461;$$471654 = $$451652;$$501041 = $$2986;$$511148 = $$491146;$$511558 = $$491556;$$52 = $488;$$521255 = $498;$$521361 = $487;
  28240. label = 127;
  28241. continue L125;
  28242. } else {
  28243. $$501466 = $$451461;$$501657 = $$451652;$$531044 = $$2986;$$541151 = $$491146;$$541561 = $$491556;$$55 = $488;$$551258 = $498;$$551364 = $487;
  28244. label = 132;
  28245. continue L125;
  28246. }
  28247. break;
  28248. }
  28249. case 127: {
  28250. label = 0;
  28251. $500 = ($$511558>>>0)<($10>>>0);
  28252. if ($500) {
  28253. $$491465$ph = $$471463;$$491656$ph = $$471654;$$521043$ph = $$501041;$$531150$ph = $$511148;$$54$ph = $$52;$$541257$ph = $$521255;$$541363$ph = $$521361;$$sink1732 = $$511558;
  28254. label = 130;
  28255. continue L46;
  28256. } else {
  28257. $$481464 = $$471463;$$481655 = $$471654;$$511042 = $$501041;$$521149 = $$511148;$$521559 = $$511558;$$53 = $$52;$$531256 = $$521255;$$531362 = $$521361;
  28258. label = 128;
  28259. continue L46;
  28260. }
  28261. break;
  28262. }
  28263. case 132: {
  28264. label = 0;
  28265. $510 = 1 << $$551258;
  28266. $511 = (($510) + -1)|0;
  28267. $512 = $511 & $$551364;
  28268. $513 = $$551364 >>> $$551258;
  28269. $514 = (($$55) - ($$551258))|0;
  28270. $515 = (($$531044) + -16)|0;
  28271. $516 = (15228 + ($515)|0);
  28272. $517 = HEAP8[$516>>0]|0;
  28273. $518 = $517 << 24 >> 24;
  28274. $519 = (($518) + ($512))|0;
  28275. $520 = (((($0)) + 10532|0) + ($$541151)|0);
  28276. $521 = ($$531044|0)==(16);
  28277. if ($521) {
  28278. $522 = (($$541151) + -1)|0;
  28279. $523 = (((($0)) + 10532|0) + ($522)|0);
  28280. $524 = HEAP8[$523>>0]|0;
  28281. $525 = $524&255;
  28282. $527 = $525;
  28283. } else {
  28284. $527 = 0;
  28285. }
  28286. $526 = $527&255;
  28287. _memset(($520|0),($526|0),($519|0))|0;
  28288. $528 = (($519) + ($$541151))|0;
  28289. $$411457 = $$501466;$$411648 = $$501657;$$451036 = $$531044;$$451142 = $528;$$451552 = $$541561;$$46 = $514;$$461249 = $$551258;$$461355 = $513;
  28290. label = 105;
  28291. break;
  28292. }
  28293. case 140: {
  28294. label = 0;
  28295. $539 = $10;
  28296. $540 = $$581565$ph;
  28297. $541 = (($539) - ($540))|0;
  28298. $542 = ($541|0)<(4);
  28299. $543 = ($$59$ph>>>0)<(15);
  28300. L241: do {
  28301. if ($542) {
  28302. $$541661$lcssa = $$541661$ph;$$581155$lcssa = $$581155$ph;$$581565$lcssa = $$581565$ph;$$59$lcssa = $$59$ph;$$591368$lcssa = $$591368$ph;$$lcssa1799 = $543;$$lcssa1802 = $541;
  28303. } else {
  28304. $544 = $12;
  28305. $$5416611868 = $$541661$ph;$$5811551871 = $$581155$ph;$$5815651869 = $$581565$ph;$$5913681870 = $$591368$ph;$$591872 = $$59$ph;$965 = $543;$966 = $541;
  28306. while(1) {
  28307. $545 = $$5416611868;
  28308. $546 = (($544) - ($545))|0;
  28309. $547 = ($546|0)<(2);
  28310. if ($547) {
  28311. $$541661$lcssa = $$5416611868;$$581155$lcssa = $$5811551871;$$581565$lcssa = $$5815651869;$$59$lcssa = $$591872;$$591368$lcssa = $$5913681870;$$lcssa1799 = $965;$$lcssa1802 = $966;
  28312. break L241;
  28313. }
  28314. if ($965) {
  28315. $613 = HEAP8[$$5815651869>>0]|0;
  28316. $614 = $613&255;
  28317. $615 = ((($$5815651869)) + 1|0);
  28318. $616 = HEAP8[$615>>0]|0;
  28319. $617 = $616&255;
  28320. $618 = $617 << 8;
  28321. $619 = $618 | $614;
  28322. $620 = $619 << $$591872;
  28323. $621 = $620 | $$5913681870;
  28324. $622 = ((($$5815651869)) + 2|0);
  28325. $623 = (($$591872) + 16)|0;
  28326. $$641571 = $622;$$65 = $623;$$651374 = $621;
  28327. } else {
  28328. $$641571 = $$5815651869;$$65 = $$591872;$$651374 = $$5913681870;
  28329. }
  28330. $624 = $$651374 & 1023;
  28331. $625 = (((($0)) + 352|0) + ($624<<1)|0);
  28332. $626 = HEAP16[$625>>1]|0;
  28333. $627 = $626 << 16 >> 16;
  28334. $628 = ($626<<16>>16)>(-1);
  28335. if ($628) {
  28336. $629 = $627 >> 9;
  28337. $$1964 = $629;$$1968 = $627;
  28338. } else {
  28339. $$0963 = 10;$$0967 = $627;
  28340. while(1) {
  28341. $630 = $$0967 ^ -1;
  28342. $631 = (($$0963) + 1)|0;
  28343. $632 = $$651374 >>> $$0963;
  28344. $633 = $632 & 1;
  28345. $634 = (($633) + ($630))|0;
  28346. $635 = (((($0)) + 2400|0) + ($634<<1)|0);
  28347. $636 = HEAP16[$635>>1]|0;
  28348. $637 = $636 << 16 >> 16;
  28349. $638 = ($636<<16>>16)<(0);
  28350. if ($638) {
  28351. $$0963 = $631;$$0967 = $637;
  28352. } else {
  28353. $$1964 = $631;$$1968 = $637;
  28354. break;
  28355. }
  28356. }
  28357. }
  28358. $639 = $$651374 >>> $$1964;
  28359. $640 = (($$65) - ($$1964))|0;
  28360. $641 = $$1968 & 256;
  28361. $642 = ($641|0)==(0);
  28362. if (!($642)) {
  28363. $$601476 = $$541470$ph;$$611668 = $$5416611868;$$631054 = $$571048$ph;$$641161 = $$1968;$$651268 = $$591262$ph;$$671574 = $$641571;$$68 = $640;$$681377 = $639;
  28364. label = 176;
  28365. break L126;
  28366. }
  28367. $643 = ($640>>>0)<(15);
  28368. if ($643) {
  28369. $644 = HEAP8[$$641571>>0]|0;
  28370. $645 = $644&255;
  28371. $646 = ((($$641571)) + 1|0);
  28372. $647 = HEAP8[$646>>0]|0;
  28373. $648 = $647&255;
  28374. $649 = $648 << 8;
  28375. $650 = $649 | $645;
  28376. $651 = $650 << $640;
  28377. $652 = $651 | $639;
  28378. $653 = ((($$641571)) + 2|0);
  28379. $654 = (($640) + 16)|0;
  28380. $$651572 = $653;$$66 = $654;$$661375 = $652;
  28381. } else {
  28382. $$651572 = $$641571;$$66 = $640;$$661375 = $639;
  28383. }
  28384. $655 = $$661375 & 1023;
  28385. $656 = (((($0)) + 352|0) + ($655<<1)|0);
  28386. $657 = HEAP16[$656>>1]|0;
  28387. $658 = $657 << 16 >> 16;
  28388. $659 = ($657<<16>>16)>(-1);
  28389. if ($659) {
  28390. $660 = $658 >> 9;
  28391. $$3966 = $660;$$3970 = $658;
  28392. } else {
  28393. $$2965 = 10;$$2969 = $658;
  28394. while(1) {
  28395. $661 = $$2969 ^ -1;
  28396. $662 = (($$2965) + 1)|0;
  28397. $663 = $$661375 >>> $$2965;
  28398. $664 = $663 & 1;
  28399. $665 = (($664) + ($661))|0;
  28400. $666 = (((($0)) + 2400|0) + ($665<<1)|0);
  28401. $667 = HEAP16[$666>>1]|0;
  28402. $668 = $667 << 16 >> 16;
  28403. $669 = ($667<<16>>16)<(0);
  28404. if ($669) {
  28405. $$2965 = $662;$$2969 = $668;
  28406. } else {
  28407. $$3966 = $662;$$3970 = $668;
  28408. break;
  28409. }
  28410. }
  28411. }
  28412. $670 = $$661375 >>> $$3966;
  28413. $671 = (($$66) - ($$3966))|0;
  28414. $672 = $$1968&255;
  28415. HEAP8[$$5416611868>>0] = $672;
  28416. $673 = $$3970 & 256;
  28417. $674 = ($673|0)==(0);
  28418. if (!($674)) {
  28419. break;
  28420. }
  28421. $676 = $$3970&255;
  28422. $677 = ((($$5416611868)) + 1|0);
  28423. HEAP8[$677>>0] = $676;
  28424. $678 = ((($$5416611868)) + 2|0);
  28425. $679 = $$651572;
  28426. $680 = (($539) - ($679))|0;
  28427. $681 = ($680|0)<(4);
  28428. $682 = ($671>>>0)<(15);
  28429. if ($681) {
  28430. $$541661$lcssa = $678;$$581155$lcssa = $$1968;$$581565$lcssa = $$651572;$$59$lcssa = $671;$$591368$lcssa = $670;$$lcssa1799 = $682;$$lcssa1802 = $680;
  28431. break L241;
  28432. } else {
  28433. $$5416611868 = $678;$$5811551871 = $$1968;$$5815651869 = $$651572;$$5913681870 = $670;$$591872 = $671;$965 = $682;$966 = $680;
  28434. }
  28435. }
  28436. $675 = ((($$5416611868)) + 1|0);
  28437. $$601476 = $$541470$ph;$$611668 = $675;$$631054 = $$571048$ph;$$641161 = $$3970;$$651268 = $$591262$ph;$$671574 = $$651572;$$68 = $671;$$681377 = $670;
  28438. label = 176;
  28439. break L126;
  28440. }
  28441. } while(0);
  28442. if (!($$lcssa1799)) {
  28443. $$581474 = $$541470$ph;$$581665 = $$541661$lcssa;$$611052 = $$571048$ph;$$621569 = $$581565$lcssa;$$63 = $$59$lcssa;$$631266 = $$591262$ph;$$631372 = $$591368$lcssa;
  28444. label = 156;
  28445. continue L125;
  28446. }
  28447. $548 = ($$lcssa1802|0)<(2);
  28448. if ($548) {
  28449. $$551471 = $$541470$ph;$$551662 = $$541661$lcssa;$$581049 = $$571048$ph;$$591156 = $$581155$lcssa;$$591566 = $$581565$lcssa;$$60 = $$59$lcssa;$$601263 = $$591262$ph;$$601369 = $$591368$lcssa;
  28450. label = 145;
  28451. continue L125;
  28452. }
  28453. $579 = HEAP8[$$581565$lcssa>>0]|0;
  28454. $580 = $579&255;
  28455. $581 = $580 << $$59$lcssa;
  28456. $582 = ((($$581565$lcssa)) + 1|0);
  28457. $583 = HEAP8[$582>>0]|0;
  28458. $584 = $583&255;
  28459. $585 = (($$59$lcssa) + 8)|0;
  28460. $586 = $584 << $585;
  28461. $587 = $581 | $$591368$lcssa;
  28462. $588 = $587 | $586;
  28463. $589 = ((($$581565$lcssa)) + 2|0);
  28464. $590 = (($$59$lcssa) + 16)|0;
  28465. $$581474 = $$541470$ph;$$581665 = $$541661$lcssa;$$611052 = $$571048$ph;$$621569 = $589;$$63 = $590;$$631266 = $$591262$ph;$$631372 = $588;
  28466. label = 156;
  28467. continue L125;
  28468. break;
  28469. }
  28470. case 145: {
  28471. label = 0;
  28472. $549 = $$601369 & 1023;
  28473. $550 = (((($0)) + 352|0) + ($549<<1)|0);
  28474. $551 = HEAP16[$550>>1]|0;
  28475. $552 = $551 << 16 >> 16;
  28476. $553 = ($551<<16>>16)>(-1);
  28477. if ($553) {
  28478. $554 = $552 >> 9;
  28479. $555 = (($554) + -1)|0;
  28480. $556 = ($555>>>0)<($$60>>>0);
  28481. if ($556) {
  28482. $$581474 = $$551471;$$581665 = $$551662;$$611052 = $$581049;$$621569 = $$591566;$$63 = $$60;$$631266 = $$601263;$$631372 = $$601369;
  28483. label = 156;
  28484. continue L125;
  28485. } else {
  28486. label = 150;
  28487. break L125;
  28488. }
  28489. }
  28490. $557 = ($$60>>>0)>(10);
  28491. if ($557) {
  28492. $$0972 = 10;$$0975 = $552;
  28493. } else {
  28494. label = 150;
  28495. break L125;
  28496. }
  28497. while(1) {
  28498. $558 = $$0975 ^ -1;
  28499. $559 = $$601369 >>> $$0972;
  28500. $560 = $559 & 1;
  28501. $561 = (($560) + ($558))|0;
  28502. $562 = (((($0)) + 2400|0) + ($561<<1)|0);
  28503. $563 = HEAP16[$562>>1]|0;
  28504. $564 = ($563<<16>>16)<(0);
  28505. if (!($564)) {
  28506. $$581474 = $$551471;$$581665 = $$551662;$$611052 = $$581049;$$621569 = $$591566;$$63 = $$60;$$631266 = $$601263;$$631372 = $$601369;
  28507. label = 156;
  28508. continue L125;
  28509. }
  28510. $565 = (($$0972) + 1)|0;
  28511. $566 = $563 << 16 >> 16;
  28512. $567 = (($$0972) + 2)|0;
  28513. $568 = ($$60>>>0)<($567>>>0);
  28514. if ($568) {
  28515. label = 150;
  28516. break L125;
  28517. } else {
  28518. $$0972 = $565;$$0975 = $566;
  28519. }
  28520. }
  28521. break;
  28522. }
  28523. case 156: {
  28524. label = 0;
  28525. $591 = $$631372 & 1023;
  28526. $592 = (((($0)) + 352|0) + ($591<<1)|0);
  28527. $593 = HEAP16[$592>>1]|0;
  28528. $594 = $593 << 16 >> 16;
  28529. $595 = ($593<<16>>16)>(-1);
  28530. if ($595) {
  28531. $596 = $594 >> 9;
  28532. $597 = $594 & 511;
  28533. $$2974 = $596;$$2977 = $597;
  28534. } else {
  28535. $$1973 = 10;$$1976 = $594;
  28536. while(1) {
  28537. $598 = $$1976 ^ -1;
  28538. $599 = (($$1973) + 1)|0;
  28539. $600 = $$631372 >>> $$1973;
  28540. $601 = $600 & 1;
  28541. $602 = (($601) + ($598))|0;
  28542. $603 = (((($0)) + 2400|0) + ($602<<1)|0);
  28543. $604 = HEAP16[$603>>1]|0;
  28544. $605 = $604 << 16 >> 16;
  28545. $606 = ($604<<16>>16)<(0);
  28546. if ($606) {
  28547. $$1973 = $599;$$1976 = $605;
  28548. } else {
  28549. $$2974 = $599;$$2977 = $605;
  28550. break;
  28551. }
  28552. }
  28553. }
  28554. $607 = $$631372 >>> $$2974;
  28555. $608 = (($$63) - ($$2974))|0;
  28556. $609 = ($$2977>>>0)>(255);
  28557. if ($609) {
  28558. $$601476 = $$581474;$$611668 = $$581665;$$631054 = $$611052;$$641161 = $$2977;$$651268 = $$631266;$$671574 = $$621569;$$68 = $608;$$681377 = $607;
  28559. label = 176;
  28560. } else {
  28561. $$591475 = $$581474;$$591666 = $$581665;$$621053 = $$611052;$$621159 = $$2977;$$631570 = $$621569;$$64 = $608;$$641267 = $$631266;$$641373 = $607;
  28562. label = 160;
  28563. continue L46;
  28564. }
  28565. break;
  28566. }
  28567. case 179: {
  28568. label = 0;
  28569. $693 = ($$681575>>>0)<($10>>>0);
  28570. if ($693) {
  28571. $$631479$ph = $$611477;$$641671$ph = $$621669;$$661057$ph = $$641055;$$671164$ph = $$651162;$$681271$ph = $$661269;$$71$ph = $$69;$$711380$ph = $$691378;$$sink1739 = $$681575;
  28572. label = 182;
  28573. continue L46;
  28574. } else {
  28575. $$621478 = $$611477;$$631670 = $$621669;$$651056 = $$641055;$$661163 = $$651162;$$671270 = $$661269;$$691576 = $$681575;$$70 = $$69;$$701379 = $$691378;
  28576. label = 180;
  28577. continue L46;
  28578. }
  28579. break;
  28580. }
  28581. case 184: {
  28582. label = 0;
  28583. $703 = 1 << $$691272;
  28584. $704 = (($703) + -1)|0;
  28585. $705 = $704 & $$721381;
  28586. $706 = $$721381 >>> $$691272;
  28587. $707 = (($$72) - ($$691272))|0;
  28588. $708 = (($705) + ($$681165))|0;
  28589. $$651481 = $$641480;$$661673 = $$651672;$$681059 = $$671058;$$691166 = $708;$$701273 = $$691272;$$721579 = $$711578;$$73 = $707;$$731382 = $706;
  28590. label = 185;
  28591. break;
  28592. }
  28593. case 187: {
  28594. label = 0;
  28595. $714 = $$741383 & 1023;
  28596. $715 = (((($0)) + 3840|0) + ($714<<1)|0);
  28597. $716 = HEAP16[$715>>1]|0;
  28598. $717 = $716 << 16 >> 16;
  28599. $718 = ($716<<16>>16)>(-1);
  28600. if ($718) {
  28601. $719 = $717 >> 9;
  28602. $720 = (($719) + -1)|0;
  28603. $721 = ($720>>>0)<($$74>>>0);
  28604. if ($721) {
  28605. $$691485 = $$661482;$$701677 = $$671674;$$731170 = $$701167;$$761583 = $$731580;$$77 = $$74;$$771386 = $$741383;
  28606. label = 198;
  28607. continue L125;
  28608. } else {
  28609. label = 192;
  28610. break L125;
  28611. }
  28612. }
  28613. $722 = ($$74>>>0)>(10);
  28614. if ($722) {
  28615. $$0953 = 10;$$0956 = $717;
  28616. } else {
  28617. label = 192;
  28618. break L125;
  28619. }
  28620. while(1) {
  28621. $723 = $$0956 ^ -1;
  28622. $724 = $$741383 >>> $$0953;
  28623. $725 = $724 & 1;
  28624. $726 = (($725) + ($723))|0;
  28625. $727 = (((($0)) + 5888|0) + ($726<<1)|0);
  28626. $728 = HEAP16[$727>>1]|0;
  28627. $729 = ($728<<16>>16)<(0);
  28628. if (!($729)) {
  28629. $$691485 = $$661482;$$701677 = $$671674;$$731170 = $$701167;$$761583 = $$731580;$$77 = $$74;$$771386 = $$741383;
  28630. label = 198;
  28631. continue L125;
  28632. }
  28633. $730 = (($$0953) + 1)|0;
  28634. $731 = $728 << 16 >> 16;
  28635. $732 = (($$0953) + 2)|0;
  28636. $733 = ($$74>>>0)<($732>>>0);
  28637. if ($733) {
  28638. label = 192;
  28639. break L125;
  28640. } else {
  28641. $$0953 = $730;$$0956 = $731;
  28642. }
  28643. }
  28644. break;
  28645. }
  28646. case 198: {
  28647. label = 0;
  28648. $756 = $$771386 & 1023;
  28649. $757 = (((($0)) + 3840|0) + ($756<<1)|0);
  28650. $758 = HEAP16[$757>>1]|0;
  28651. $759 = $758 << 16 >> 16;
  28652. $760 = ($758<<16>>16)>(-1);
  28653. if ($760) {
  28654. $761 = $759 >> 9;
  28655. $762 = $759 & 511;
  28656. $$2955 = $761;$$2958 = $762;
  28657. } else {
  28658. $$1954 = 10;$$1957 = $759;
  28659. while(1) {
  28660. $763 = $$1957 ^ -1;
  28661. $764 = (($$1954) + 1)|0;
  28662. $765 = $$771386 >>> $$1954;
  28663. $766 = $765 & 1;
  28664. $767 = (($766) + ($763))|0;
  28665. $768 = (((($0)) + 5888|0) + ($767<<1)|0);
  28666. $769 = HEAP16[$768>>1]|0;
  28667. $770 = $769 << 16 >> 16;
  28668. $771 = ($769<<16>>16)<(0);
  28669. if ($771) {
  28670. $$1954 = $764;$$1957 = $770;
  28671. } else {
  28672. $$2955 = $764;$$2958 = $770;
  28673. break;
  28674. }
  28675. }
  28676. }
  28677. $772 = $$771386 >>> $$2955;
  28678. $773 = (($$77) - ($$2955))|0;
  28679. $774 = (4852 + ($$2958<<2)|0);
  28680. $775 = HEAP32[$774>>2]|0;
  28681. $776 = (4980 + ($$2958<<2)|0);
  28682. $777 = HEAP32[$776>>2]|0;
  28683. $778 = (($$2958) + -4)|0;
  28684. $779 = ($778>>>0)<(26);
  28685. if ($779) {
  28686. $780 = ($773>>>0)<($775>>>0);
  28687. if ($780) {
  28688. $$701486 = $$691485;$$711678 = $$701677;$$721063 = $777;$$741171 = $$731170;$$741277 = $775;$$771584 = $$761583;$$78 = $773;$$781387 = $772;
  28689. label = 203;
  28690. continue L125;
  28691. } else {
  28692. $$741681 = $$701677;$$751066 = $777;$$771174 = $$731170;$$771280 = $775;$$801587 = $$761583;$$81 = $773;$$811390 = $772;
  28693. label = 208;
  28694. continue L125;
  28695. }
  28696. } else {
  28697. $$751682 = $$701677;$$761067 = $777;$$781175 = $$731170;$$781281 = $775;$$811588 = $$761583;$$82 = $773;$$821391 = $772;
  28698. label = 209;
  28699. }
  28700. break;
  28701. }
  28702. case 203: {
  28703. label = 0;
  28704. $781 = ($$771584>>>0)<($10>>>0);
  28705. if ($781) {
  28706. $$721488$ph = $$701486;$$731680$ph = $$711678;$$741065$ph = $$721063;$$761173$ph = $$741171;$$761279$ph = $$741277;$$80$ph = $$78;$$801389$ph = $$781387;$$sink1746 = $$771584;
  28707. label = 206;
  28708. continue L46;
  28709. } else {
  28710. $$711487 = $$701486;$$721679 = $$711678;$$731064 = $$721063;$$751172 = $$741171;$$751278 = $$741277;$$781585 = $$771584;$$79 = $$78;$$791388 = $$781387;
  28711. label = 204;
  28712. continue L46;
  28713. }
  28714. break;
  28715. }
  28716. case 208: {
  28717. label = 0;
  28718. $791 = 1 << $$771280;
  28719. $792 = (($791) + -1)|0;
  28720. $793 = $792 & $$811390;
  28721. $794 = $$811390 >>> $$771280;
  28722. $795 = (($$81) - ($$771280))|0;
  28723. $796 = (($793) + ($$751066))|0;
  28724. $$751682 = $$741681;$$761067 = $796;$$781175 = $$771174;$$781281 = $$771280;$$811588 = $$801587;$$82 = $795;$$821391 = $794;
  28725. label = 209;
  28726. break;
  28727. }
  28728. case 212: {
  28729. label = 0;
  28730. $807 = (($$801177) + -1)|0;
  28731. $808 = ($$801177|0)==(0);
  28732. if ($808) {
  28733. $$531469 = $$741490;$$531660 = $$771684;$$561047 = $$781069;$$571154 = $807;$$571564 = $$831590;$$58 = $$84;$$581261 = $$801283;$$581367 = $$841393;
  28734. label = 139;
  28735. } else {
  28736. $$751491 = $$741490;$$781685 = $$771684;$$791070 = $$781069;$$811178 = $807;$$811284 = $$801283;$$841591 = $$831590;$$85 = $$84;$$851394 = $$841393;
  28737. label = 213;
  28738. continue L46;
  28739. }
  28740. break;
  28741. }
  28742. }
  28743. do {
  28744. if ((label|0) == 70) {
  28745. label = 0;
  28746. $217 = ((($0)) + 52|0);
  28747. $218 = HEAP32[$217>>2]|0;
  28748. $219 = ($$381135>>>0)<($218>>>0);
  28749. if ($219) {
  28750. $220 = ($$39>>>0)<(3);
  28751. if ($220) {
  28752. $$351451 = $$341450;$$351642 = $$341641;$$391030 = $$381029;$$391136 = $$381135;$$391546 = $$381545;$$40 = $$39;$$401243 = $$391242;$$401349 = $$391348;
  28753. label = 72;
  28754. continue L125;
  28755. } else {
  28756. $$381454 = $$341450;$$381645 = $$341641;$$421033 = $$381029;$$421139 = $$381135;$$421549 = $$381545;$$43 = $$39;$$431246 = $$391242;$$431352 = $$391348;
  28757. label = 77;
  28758. continue L125;
  28759. }
  28760. } else {
  28761. HEAP32[$217>>2] = 19;
  28762. $$391455 = $$341450;$$391646 = $$341641;$$431034 = $$381029;$$431140 = $$381135;$$431550 = $$381545;$$44 = $$39;$$441247 = $$391242;$$441353 = $$391348;
  28763. label = 80;
  28764. continue L125;
  28765. }
  28766. }
  28767. else if ((label|0) == 105) {
  28768. label = 0;
  28769. $418 = ((($0)) + 44|0);
  28770. $419 = HEAP32[$418>>2]|0;
  28771. $420 = ((($0)) + 48|0);
  28772. $421 = HEAP32[$420>>2]|0;
  28773. $422 = (($421) + ($419))|0;
  28774. $423 = ($$451142>>>0)<($422>>>0);
  28775. if (!($423)) {
  28776. $529 = ($422|0)==($$451142|0);
  28777. if (!($529)) {
  28778. $$511467 = $$411457;$$511658 = $$411648;$$541045 = $$451036;$$551152 = $$451142;$$551562 = $$451552;$$56 = $$46;$$561259 = $$461249;$$561365 = $$461355;
  28779. label = 136;
  28780. continue L46;
  28781. }
  28782. $530 = ((($0)) + 64|0);
  28783. $531 = ((($0)) + 10532|0);
  28784. _memcpy(($530|0),($531|0),($419|0))|0;
  28785. $532 = ((($0)) + 3552|0);
  28786. $533 = HEAP32[$418>>2]|0;
  28787. $534 = (((($0)) + 10532|0) + ($533)|0);
  28788. $535 = HEAP32[$420>>2]|0;
  28789. _memcpy(($532|0),($534|0),($535|0))|0;
  28790. $$521468 = $$411457;$$521659 = $$411648;$$551046 = $$451036;$$561153 = $$451142;$$561563 = $$451552;$$57 = $$46;$$571260 = $$461249;$$571366 = $$461355;
  28791. label = 138;
  28792. break;
  28793. }
  28794. $424 = ($$46>>>0)<(15);
  28795. if (!($424)) {
  28796. $$451461 = $$411457;$$451652 = $$411648;$$491146 = $$451142;$$491556 = $$451552;$$50 = $$46;$$501253 = $$461249;$$501359 = $$461355;
  28797. label = 119;
  28798. continue L125;
  28799. }
  28800. $425 = $10;
  28801. $426 = $$451552;
  28802. $427 = (($425) - ($426))|0;
  28803. $428 = ($427|0)<(2);
  28804. if ($428) {
  28805. $$421458 = $$411457;$$421649 = $$411648;$$461037 = $$451036;$$461143 = $$451142;$$461553 = $$451552;$$47 = $$46;$$471250 = $$461249;$$471356 = $$461355;
  28806. label = 108;
  28807. continue L125;
  28808. }
  28809. $459 = HEAP8[$$451552>>0]|0;
  28810. $460 = $459&255;
  28811. $461 = $460 << $$46;
  28812. $462 = ((($$451552)) + 1|0);
  28813. $463 = HEAP8[$462>>0]|0;
  28814. $464 = $463&255;
  28815. $465 = (($$46) + 8)|0;
  28816. $466 = $464 << $465;
  28817. $467 = $461 | $$461355;
  28818. $468 = $467 | $466;
  28819. $469 = ((($$451552)) + 2|0);
  28820. $470 = (($$46) + 16)|0;
  28821. $$451461 = $$411457;$$451652 = $$411648;$$491146 = $$451142;$$491556 = $469;$$50 = $470;$$501253 = $$461249;$$501359 = $468;
  28822. label = 119;
  28823. continue L125;
  28824. }
  28825. else if ((label|0) == 176) {
  28826. label = 0;
  28827. $683 = $$641161 & 511;
  28828. $684 = ($683|0)==(256);
  28829. if ($684) {
  28830. $$761492 = $$601476;$$801071 = $$631054;$$801687 = $$611668;$$821285 = $$651268;$$831180 = 256;$$851592 = $$671574;$$86 = $$68;$$861395 = $$681377;
  28831. label = 220;
  28832. break L125;
  28833. }
  28834. $685 = (($683) + -257)|0;
  28835. $686 = (4604 + ($685<<2)|0);
  28836. $687 = HEAP32[$686>>2]|0;
  28837. $688 = (4728 + ($685<<2)|0);
  28838. $689 = HEAP32[$688>>2]|0;
  28839. $690 = (($683) + -265)|0;
  28840. $691 = ($690>>>0)<(20);
  28841. if ($691) {
  28842. $692 = ($$68>>>0)<($687>>>0);
  28843. if ($692) {
  28844. $$611477 = $$601476;$$621669 = $$611668;$$641055 = $$631054;$$651162 = $689;$$661269 = $687;$$681575 = $$671574;$$69 = $$68;$$691378 = $$681377;
  28845. label = 179;
  28846. continue L125;
  28847. } else {
  28848. $$641480 = $$601476;$$651672 = $$611668;$$671058 = $$631054;$$681165 = $689;$$691272 = $687;$$711578 = $$671574;$$72 = $$68;$$721381 = $$681377;
  28849. label = 184;
  28850. continue L125;
  28851. }
  28852. } else {
  28853. $$651481 = $$601476;$$661673 = $$611668;$$681059 = $$631054;$$691166 = $689;$$701273 = $687;$$721579 = $$671574;$$73 = $$68;$$731382 = $$681377;
  28854. label = 185;
  28855. }
  28856. }
  28857. else if ((label|0) == 209) {
  28858. label = 0;
  28859. $797 = $$751682;
  28860. $798 = $3;
  28861. $799 = (($797) - ($798))|0;
  28862. $$not = ($799>>>0)>=($$761067>>>0);
  28863. $$not1747 = $14 ^ 1;
  28864. $brmerge = $$not | $$not1747;
  28865. if (!($brmerge)) {
  28866. $$731489 = $799;$$761683 = $$751682;$$771068 = $$761067;$$791176 = $$781175;$$791282 = $$781281;$$821589 = $$811588;$$83 = $$82;$$831392 = $$821391;
  28867. label = 210;
  28868. continue L46;
  28869. }
  28870. $800 = (($799) - ($$761067))|0;
  28871. $801 = $800 & $$1753;
  28872. $802 = (($3) + ($801)|0);
  28873. $803 = ($$751682>>>0)>($802>>>0);
  28874. $804 = $803 ? $$751682 : $802;
  28875. $805 = (($804) + ($$781175)|0);
  28876. $806 = ($805>>>0)>($12>>>0);
  28877. if ($806) {
  28878. $$741490 = $799;$$771684 = $$751682;$$781069 = $$761067;$$801177 = $$781175;$$801283 = $$781281;$$831590 = $$811588;$$84 = $$82;$$841393 = $$821391;
  28879. label = 212;
  28880. continue L125;
  28881. } else {
  28882. $$0978 = $802;$$791686 = $$751682;$$821179 = $$781175;
  28883. }
  28884. while(1) {
  28885. $816 = HEAP8[$$0978>>0]|0;
  28886. HEAP8[$$791686>>0] = $816;
  28887. $817 = ((($$0978)) + 1|0);
  28888. $818 = HEAP8[$817>>0]|0;
  28889. $819 = ((($$791686)) + 1|0);
  28890. HEAP8[$819>>0] = $818;
  28891. $820 = ((($$0978)) + 2|0);
  28892. $821 = HEAP8[$820>>0]|0;
  28893. $822 = ((($$791686)) + 2|0);
  28894. HEAP8[$822>>0] = $821;
  28895. $823 = ((($$791686)) + 3|0);
  28896. $824 = ((($$0978)) + 3|0);
  28897. $825 = (($$821179) + -3)|0;
  28898. $826 = ($825|0)>(2);
  28899. if ($826) {
  28900. $$0978 = $824;$$791686 = $823;$$821179 = $825;
  28901. } else {
  28902. break;
  28903. }
  28904. }
  28905. $827 = ($825|0)>(0);
  28906. if ($827) {
  28907. $828 = HEAP8[$824>>0]|0;
  28908. HEAP8[$823>>0] = $828;
  28909. $829 = ($825|0)==(1);
  28910. if (!($829)) {
  28911. $830 = ((($$0978)) + 4|0);
  28912. $831 = HEAP8[$830>>0]|0;
  28913. $832 = ((($$791686)) + 4|0);
  28914. HEAP8[$832>>0] = $831;
  28915. }
  28916. $833 = (($823) + ($825)|0);
  28917. $$531469 = $799;$$531660 = $833;$$561047 = $$761067;$$571154 = $825;$$571564 = $$811588;$$58 = $$82;$$581261 = $$781281;$$581367 = $$821391;
  28918. label = 139;
  28919. } else {
  28920. $$531469 = $799;$$531660 = $823;$$561047 = $$761067;$$571154 = $825;$$571564 = $$811588;$$58 = $$82;$$581261 = $$781281;$$581367 = $$821391;
  28921. label = 139;
  28922. }
  28923. }
  28924. } while(0);
  28925. if ((label|0) == 138) {
  28926. label = 0;
  28927. $536 = ((($0)) + 24|0);
  28928. $537 = HEAP32[$536>>2]|0;
  28929. $538 = (($537) + -1)|0;
  28930. HEAP32[$536>>2] = $538;
  28931. $$391455 = $$521468;$$391646 = $$521659;$$431034 = $$551046;$$431140 = $$561153;$$431550 = $$561563;$$44 = $$57;$$441247 = $$571260;$$441353 = $$571366;
  28932. label = 80;
  28933. continue;
  28934. }
  28935. else if ((label|0) == 139) {
  28936. label = 0;
  28937. $$541470$ph = $$531469;$$541661$ph = $$531660;$$571048$ph = $$561047;$$581155$ph = $$571154;$$581565$ph = $$571564;$$59$ph = $$58;$$591262$ph = $$581261;$$591368$ph = $$581367;
  28938. label = 140;
  28939. continue;
  28940. }
  28941. else if ((label|0) == 185) {
  28942. label = 0;
  28943. $709 = ($$73>>>0)<(15);
  28944. if (!($709)) {
  28945. $$691485 = $$651481;$$701677 = $$661673;$$731170 = $$691166;$$761583 = $$721579;$$77 = $$73;$$771386 = $$731382;
  28946. label = 198;
  28947. continue;
  28948. }
  28949. $710 = $10;
  28950. $711 = $$721579;
  28951. $712 = (($710) - ($711))|0;
  28952. $713 = ($712|0)<(2);
  28953. if ($713) {
  28954. $$661482 = $$651481;$$671674 = $$661673;$$691060 = $$681059;$$701167 = $$691166;$$711274 = $$701273;$$731580 = $$721579;$$74 = $$73;$$741383 = $$731382;
  28955. label = 187;
  28956. continue;
  28957. }
  28958. $744 = HEAP8[$$721579>>0]|0;
  28959. $745 = $744&255;
  28960. $746 = $745 << $$73;
  28961. $747 = ((($$721579)) + 1|0);
  28962. $748 = HEAP8[$747>>0]|0;
  28963. $749 = $748&255;
  28964. $750 = (($$73) + 8)|0;
  28965. $751 = $749 << $750;
  28966. $752 = $746 | $$731382;
  28967. $753 = $752 | $751;
  28968. $754 = ((($$721579)) + 2|0);
  28969. $755 = (($$73) + 16)|0;
  28970. $$691485 = $$651481;$$701677 = $$661673;$$731170 = $$691166;$$761583 = $754;$$77 = $755;$$771386 = $753;
  28971. label = 198;
  28972. continue;
  28973. }
  28974. }
  28975. if ((label|0) == 113) {
  28976. label = 0;
  28977. $449 = ($$461553>>>0)<($10>>>0);
  28978. if ($449) {
  28979. $$441460$ph = $$421458;$$441651$ph = $$421649;$$481039$ph = $$461037;$$481145$ph = $$461143;$$49$ph = $$47;$$491252$ph = $$471250;$$491358$ph = $$471356;$$sink1729 = $$461553;
  28980. label = 116;
  28981. continue;
  28982. } else {
  28983. $$431459 = $$421458;$$431650 = $$421649;$$471038 = $$461037;$$471144 = $$461143;$$471554 = $$461553;$$48 = $$47;$$481251 = $$471250;$$481357 = $$471356;
  28984. label = 114;
  28985. continue;
  28986. }
  28987. }
  28988. else if ((label|0) == 150) {
  28989. label = 0;
  28990. $569 = ($$591566>>>0)<($10>>>0);
  28991. if ($569) {
  28992. $$571473$ph = $$551471;$$571664$ph = $$551662;$$601051$ph = $$581049;$$611158$ph = $$591156;$$62$ph = $$60;$$621265$ph = $$601263;$$621371$ph = $$601369;$$sink1736 = $$591566;
  28993. label = 153;
  28994. continue;
  28995. } else {
  28996. $$561472 = $$551471;$$561663 = $$551662;$$591050 = $$581049;$$601157 = $$591156;$$601567 = $$591566;$$61 = $$60;$$611264 = $$601263;$$611370 = $$601369;
  28997. label = 151;
  28998. continue;
  28999. }
  29000. }
  29001. else if ((label|0) == 192) {
  29002. label = 0;
  29003. $734 = ($$731580>>>0)<($10>>>0);
  29004. if ($734) {
  29005. $$681484$ph = $$661482;$$691676$ph = $$671674;$$711062$ph = $$691060;$$721169$ph = $$701167;$$731276$ph = $$711274;$$76$ph = $$74;$$761385$ph = $$741383;$$sink1743 = $$731580;
  29006. label = 195;
  29007. continue;
  29008. } else {
  29009. $$671483 = $$661482;$$681675 = $$671674;$$701061 = $$691060;$$711168 = $$701167;$$721275 = $$711274;$$741581 = $$731580;$$75 = $$74;$$751384 = $$741383;
  29010. label = 193;
  29011. continue;
  29012. }
  29013. }
  29014. else if ((label|0) == 220) {
  29015. label = 0;
  29016. $834 = ((($0)) + 20|0);
  29017. $835 = HEAP32[$834>>2]|0;
  29018. $836 = $835 & 1;
  29019. $837 = ($836|0)==(0);
  29020. if ($837) {
  29021. $$01416 = $$761492;$$01607 = $$801687;$$41511 = $$851592;$$5 = $$86;$$51102 = $$831180;$$51208 = $$821285;$$51314 = $$861395;$$5996 = $$801071;
  29022. label = 14;
  29023. continue;
  29024. }
  29025. $838 = $6 & 1;
  29026. $839 = ($838|0)==(0);
  29027. if ($839) {
  29028. $$881504 = $$761492;$$921083 = $$801071;$$921699 = $$801687;$$941191 = $$831180;$$941297 = $$821285;$$971604 = $$851592;$$98 = $$86;$$981407 = $$861395;
  29029. label = 242;
  29030. continue;
  29031. } else {
  29032. $$801496 = $$761492;$$841075 = $$801071;$$841691 = $$801687;$$861289 = $$821285;$$891596 = $$851592;$$90 = $$86;$$901399 = $$861395;
  29033. label = 226;
  29034. continue;
  29035. }
  29036. }
  29037. }
  29038. if ((label|0) == 258) {
  29039. STACKTOP = sp;return ($$0951|0);
  29040. }
  29041. $892 = ((($0)) + 28|0);
  29042. $893 = HEAP32[$892>>2]|0;
  29043. $894 = $893 & 65535;
  29044. $895 = $893 >>> 16;
  29045. $896 = ($888|0)==(0);
  29046. if ($896) {
  29047. $$0937$lcssa = $895;$$0938$lcssa = $894;
  29048. } else {
  29049. $897 = (($888>>>0) % 5552)&-1;
  29050. $$01834 = $897;$$09371833 = $895;$$09381832 = $894;$$09431831 = $888;$$09441830 = $4;
  29051. while(1) {
  29052. $898 = ($$01834>>>0)>(7);
  29053. if ($898) {
  29054. $899 = (($$01834) + -8)|0;
  29055. $900 = $899 & -8;
  29056. $scevgep = ((($$09441830)) + 8|0);
  29057. $$09411816 = 0;$$11818 = $$09371833;$$19391817 = $$09381832;$$19451815 = $$09441830;
  29058. while(1) {
  29059. $904 = HEAP8[$$19451815>>0]|0;
  29060. $905 = $904&255;
  29061. $906 = (($905) + ($$19391817))|0;
  29062. $907 = (($906) + ($$11818))|0;
  29063. $908 = ((($$19451815)) + 1|0);
  29064. $909 = HEAP8[$908>>0]|0;
  29065. $910 = $909&255;
  29066. $911 = (($906) + ($910))|0;
  29067. $912 = (($907) + ($911))|0;
  29068. $913 = ((($$19451815)) + 2|0);
  29069. $914 = HEAP8[$913>>0]|0;
  29070. $915 = $914&255;
  29071. $916 = (($911) + ($915))|0;
  29072. $917 = (($912) + ($916))|0;
  29073. $918 = ((($$19451815)) + 3|0);
  29074. $919 = HEAP8[$918>>0]|0;
  29075. $920 = $919&255;
  29076. $921 = (($916) + ($920))|0;
  29077. $922 = (($917) + ($921))|0;
  29078. $923 = ((($$19451815)) + 4|0);
  29079. $924 = HEAP8[$923>>0]|0;
  29080. $925 = $924&255;
  29081. $926 = (($921) + ($925))|0;
  29082. $927 = (($922) + ($926))|0;
  29083. $928 = ((($$19451815)) + 5|0);
  29084. $929 = HEAP8[$928>>0]|0;
  29085. $930 = $929&255;
  29086. $931 = (($926) + ($930))|0;
  29087. $932 = (($927) + ($931))|0;
  29088. $933 = ((($$19451815)) + 6|0);
  29089. $934 = HEAP8[$933>>0]|0;
  29090. $935 = $934&255;
  29091. $936 = (($931) + ($935))|0;
  29092. $937 = (($932) + ($936))|0;
  29093. $938 = ((($$19451815)) + 7|0);
  29094. $939 = HEAP8[$938>>0]|0;
  29095. $940 = $939&255;
  29096. $941 = (($936) + ($940))|0;
  29097. $942 = (($937) + ($941))|0;
  29098. $943 = (($$09411816) + 8)|0;
  29099. $944 = ((($$19451815)) + 8|0);
  29100. $945 = $943 | 7;
  29101. $946 = ($945>>>0)<($$01834>>>0);
  29102. if ($946) {
  29103. $$09411816 = $943;$$11818 = $942;$$19391817 = $941;$$19451815 = $944;
  29104. } else {
  29105. break;
  29106. }
  29107. }
  29108. $901 = (($900) + 8)|0;
  29109. $scevgep1947 = (($scevgep) + ($900)|0);
  29110. $$0941$lcssa = $901;$$1$lcssa = $942;$$1939$lcssa = $941;$$1945$lcssa = $scevgep1947;
  29111. } else {
  29112. $$0941$lcssa = 0;$$1$lcssa = $$09371833;$$1939$lcssa = $$09381832;$$1945$lcssa = $$09441830;
  29113. }
  29114. $902 = ($$01834>>>0)>($$0941$lcssa>>>0);
  29115. if ($902) {
  29116. $903 = (($$01834) - ($$0941$lcssa))|0;
  29117. $$19421823 = $$0941$lcssa;$$21825 = $$1$lcssa;$$29401824 = $$1939$lcssa;$$29461822 = $$1945$lcssa;
  29118. while(1) {
  29119. $947 = ((($$29461822)) + 1|0);
  29120. $948 = HEAP8[$$29461822>>0]|0;
  29121. $949 = $948&255;
  29122. $950 = (($949) + ($$29401824))|0;
  29123. $951 = (($950) + ($$21825))|0;
  29124. $952 = (($$19421823) + 1)|0;
  29125. $exitcond = ($952|0)==($$01834|0);
  29126. if ($exitcond) {
  29127. break;
  29128. } else {
  29129. $$19421823 = $952;$$21825 = $951;$$29401824 = $950;$$29461822 = $947;
  29130. }
  29131. }
  29132. $scevgep1948 = (($$1945$lcssa) + ($903)|0);
  29133. $$2$lcssa = $951;$$2940$lcssa = $950;$$2946$lcssa = $scevgep1948;
  29134. } else {
  29135. $$2$lcssa = $$1$lcssa;$$2940$lcssa = $$1939$lcssa;$$2946$lcssa = $$1945$lcssa;
  29136. }
  29137. $953 = (($$2940$lcssa>>>0) % 65521)&-1;
  29138. $954 = (($$2$lcssa>>>0) % 65521)&-1;
  29139. $955 = (($$09431831) - ($$01834))|0;
  29140. $956 = ($955|0)==(0);
  29141. if ($956) {
  29142. $$0937$lcssa = $954;$$0938$lcssa = $953;
  29143. break;
  29144. } else {
  29145. $$01834 = 5552;$$09371833 = $954;$$09381832 = $953;$$09431831 = $955;$$09441830 = $$2946$lcssa;
  29146. }
  29147. }
  29148. }
  29149. $957 = $$0937$lcssa << 16;
  29150. $958 = $957 | $$0938$lcssa;
  29151. HEAP32[$892>>2] = $958;
  29152. $959 = ($$1961|0)!=(0);
  29153. $960 = $6 & 1;
  29154. $961 = ($960|0)==(0);
  29155. $or$cond1752 = $961 | $959;
  29156. if ($or$cond1752) {
  29157. $$0951 = $$1961;
  29158. STACKTOP = sp;return ($$0951|0);
  29159. } else {
  29160. $962 = ((($0)) + 16|0);
  29161. $963 = HEAP32[$962>>2]|0;
  29162. $964 = ($958|0)==($963|0);
  29163. $$1961$ = $964 ? $$1961 : -2;
  29164. STACKTOP = sp;return ($$1961$|0);
  29165. }
  29166. return (0)|0;
  29167. }
  29168. function _ImageCrop($0,$1) {
  29169. $0 = $0|0;
  29170. $1 = $1|0;
  29171. var $$03435 = 0, $$036 = 0, $$byval_copy6 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  29172. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0;
  29173. var $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $7 = 0, $8 = 0;
  29174. var $9 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer4 = 0, label = 0, sp = 0;
  29175. sp = STACKTOP;
  29176. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  29177. $$byval_copy6 = sp + 40|0;
  29178. $vararg_buffer4 = sp + 16|0;
  29179. $vararg_buffer1 = sp + 8|0;
  29180. $vararg_buffer = sp;
  29181. $2 = sp + 20|0;
  29182. $3 = HEAP32[$1>>2]|0;
  29183. $4 = ((($1)) + 8|0);
  29184. $5 = HEAP32[$4>>2]|0;
  29185. $6 = (($5) + ($3))|0;
  29186. $7 = ((($0)) + 4|0);
  29187. $8 = HEAP32[$7>>2]|0;
  29188. $9 = ($6|0)>($8|0);
  29189. $10 = (($8) - ($3))|0;
  29190. if ($9) {
  29191. HEAP32[$4>>2] = $10;
  29192. HEAP32[$vararg_buffer>>2] = $10;
  29193. _TraceLog(2,15232,$vararg_buffer);
  29194. }
  29195. $11 = ((($1)) + 4|0);
  29196. $12 = HEAP32[$11>>2]|0;
  29197. $13 = ((($1)) + 12|0);
  29198. $14 = HEAP32[$13>>2]|0;
  29199. $15 = (($14) + ($12))|0;
  29200. $16 = ((($0)) + 8|0);
  29201. $17 = HEAP32[$16>>2]|0;
  29202. $18 = ($15|0)>($17|0);
  29203. $19 = (($17) - ($12))|0;
  29204. if ($18) {
  29205. HEAP32[$13>>2] = $19;
  29206. HEAP32[$vararg_buffer1>>2] = $19;
  29207. _TraceLog(2,15292,$vararg_buffer1);
  29208. }
  29209. $20 = HEAP32[$7>>2]|0;
  29210. $21 = ($3|0)<($20|0);
  29211. if ($21) {
  29212. $22 = HEAP32[$16>>2]|0;
  29213. $23 = ($12|0)<($22|0);
  29214. if ($23) {
  29215. ;HEAP32[$$byval_copy6>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy6+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy6+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy6+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy6+16>>2]=HEAP32[$0+16>>2]|0;
  29216. $24 = (_GetImageData($$byval_copy6)|0);
  29217. $25 = HEAP32[$4>>2]|0;
  29218. $26 = HEAP32[$13>>2]|0;
  29219. $27 = $25 << 2;
  29220. $28 = Math_imul($27, $26)|0;
  29221. $29 = (_malloc($28)|0);
  29222. $30 = HEAP32[$11>>2]|0;
  29223. $31 = ($26|0)>(0);
  29224. if ($31) {
  29225. $32 = HEAP32[$1>>2]|0;
  29226. $33 = HEAP32[$4>>2]|0;
  29227. $34 = ($33|0)>(0);
  29228. $35 = HEAP32[$11>>2]|0;
  29229. $36 = HEAP32[$13>>2]|0;
  29230. $37 = (($36) + ($35))|0;
  29231. $$036 = $30;$43 = $30;
  29232. while(1) {
  29233. if ($34) {
  29234. $42 = (($$036) - ($43))|0;
  29235. $44 = HEAP32[$7>>2]|0;
  29236. $45 = Math_imul($44, $$036)|0;
  29237. $46 = HEAP32[$4>>2]|0;
  29238. $47 = (($46) + ($32))|0;
  29239. $$03435 = $32;$51 = $33;
  29240. while(1) {
  29241. $50 = Math_imul($51, $42)|0;
  29242. $52 = (($$03435) - ($32))|0;
  29243. $53 = (($52) + ($50))|0;
  29244. $54 = (($45) + ($$03435))|0;
  29245. $55 = (($29) + ($53<<2)|0);
  29246. $56 = (($24) + ($54<<2)|0);
  29247. $57 = HEAPU8[$56>>0]|(HEAPU8[$56+1>>0]<<8)|(HEAPU8[$56+2>>0]<<16)|(HEAPU8[$56+3>>0]<<24);
  29248. HEAP8[$55>>0]=$57&255;HEAP8[$55+1>>0]=($57>>8)&255;HEAP8[$55+2>>0]=($57>>16)&255;HEAP8[$55+3>>0]=$57>>24;
  29249. $58 = (($$03435) + 1)|0;
  29250. $59 = ($58|0)<($47|0);
  29251. if ($59) {
  29252. $$03435 = $58;$51 = $46;
  29253. } else {
  29254. break;
  29255. }
  29256. }
  29257. }
  29258. $48 = (($$036) + 1)|0;
  29259. $49 = ($48|0)<($37|0);
  29260. if ($49) {
  29261. $$036 = $48;$43 = $35;
  29262. } else {
  29263. break;
  29264. }
  29265. }
  29266. }
  29267. _free($24);
  29268. $38 = ((($0)) + 16|0);
  29269. $39 = HEAP32[$38>>2]|0;
  29270. ;HEAP32[$$byval_copy6>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy6+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy6+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy6+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy6+16>>2]=HEAP32[$0+16>>2]|0;
  29271. _UnloadImage($$byval_copy6);
  29272. $40 = HEAP32[$4>>2]|0;
  29273. $41 = HEAP32[$13>>2]|0;
  29274. _LoadImageEx($2,$29,$40,$41);
  29275. ;HEAP32[$0>>2]=HEAP32[$2>>2]|0;HEAP32[$0+4>>2]=HEAP32[$2+4>>2]|0;HEAP32[$0+8>>2]=HEAP32[$2+8>>2]|0;HEAP32[$0+12>>2]=HEAP32[$2+12>>2]|0;HEAP32[$0+16>>2]=HEAP32[$2+16>>2]|0;
  29276. _free($29);
  29277. _ImageFormat($0,$39);
  29278. STACKTOP = sp;return;
  29279. }
  29280. }
  29281. _TraceLog(2,15354,$vararg_buffer4);
  29282. STACKTOP = sp;return;
  29283. }
  29284. function _ImageResize($0,$1,$2) {
  29285. $0 = $0|0;
  29286. $1 = $1|0;
  29287. $2 = $2|0;
  29288. var $$byval_copy1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  29289. sp = STACKTOP;
  29290. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  29291. $$byval_copy1 = sp + 20|0;
  29292. $3 = sp;
  29293. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  29294. $4 = (_GetImageData($$byval_copy1)|0);
  29295. $5 = $1 << 2;
  29296. $6 = Math_imul($5, $2)|0;
  29297. $7 = (_malloc($6)|0);
  29298. $8 = ((($0)) + 4|0);
  29299. $9 = HEAP32[$8>>2]|0;
  29300. $10 = ((($0)) + 8|0);
  29301. $11 = HEAP32[$10>>2]|0;
  29302. (_stbir_resize_uint8($4,$9,$11,0,$7,$1,$2,0,4)|0);
  29303. $12 = ((($0)) + 16|0);
  29304. $13 = HEAP32[$12>>2]|0;
  29305. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  29306. _UnloadImage($$byval_copy1);
  29307. _LoadImageEx($3,$7,$1,$2);
  29308. ;HEAP32[$0>>2]=HEAP32[$3>>2]|0;HEAP32[$0+4>>2]=HEAP32[$3+4>>2]|0;HEAP32[$0+8>>2]=HEAP32[$3+8>>2]|0;HEAP32[$0+12>>2]=HEAP32[$3+12>>2]|0;HEAP32[$0+16>>2]=HEAP32[$3+16>>2]|0;
  29309. _ImageFormat($0,$13);
  29310. _free($7);
  29311. _free($4);
  29312. STACKTOP = sp;return;
  29313. }
  29314. function _ImageDraw($0,$1,$2,$3) {
  29315. $0 = $0|0;
  29316. $1 = $1|0;
  29317. $2 = $2|0;
  29318. $3 = $3|0;
  29319. var $$05255 = 0, $$053 = 0, $$054 = 0, $$1 = 0, $$byval_copy15 = 0, $$sroa$0$0$$sroa_idx = 0, $$sroa$0$0$copyload = 0, $$sroa$024$0$$sroa_idx = 0, $$sroa$024$0$copyload = 0, $$sroa$10$0$$sroa_idx = 0, $$sroa$10$0$copyload = 0, $$sroa$4$0$$sroa_idx = 0, $$sroa$4$0$copyload = 0, $$sroa$5$0$$sroa_idx = 0, $$sroa$5$0$copyload = 0, $$sroa$6$0$$sroa_idx = 0, $$sroa$6$0$copyload = 0, $$sroa$7$0$$sroa_idx = 0, $$sroa$7$0$copyload = 0, $10 = 0;
  29320. var $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0;
  29321. var $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0;
  29322. var $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0;
  29323. var $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0;
  29324. var $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0;
  29325. var $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $vararg_buffer = 0, $vararg_buffer1 = 0, $vararg_buffer4 = 0, $vararg_buffer7 = 0, label = 0, sp = 0;
  29326. sp = STACKTOP;
  29327. STACKTOP = STACKTOP + 112|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(112|0);
  29328. $$byval_copy15 = sp + 88|0;
  29329. $vararg_buffer7 = sp + 24|0;
  29330. $vararg_buffer4 = sp + 16|0;
  29331. $vararg_buffer1 = sp + 8|0;
  29332. $vararg_buffer = sp;
  29333. $4 = sp + 48|0;
  29334. $5 = sp + 32|0;
  29335. $6 = sp + 68|0;
  29336. $7 = HEAP32[$2>>2]|0;
  29337. $8 = ($7|0)<(0);
  29338. if ($8) {
  29339. HEAP32[$2>>2] = 0;
  29340. }
  29341. $9 = ((($2)) + 4|0);
  29342. $10 = HEAP32[$9>>2]|0;
  29343. $11 = ($10|0)<(0);
  29344. if ($11) {
  29345. HEAP32[$9>>2] = 0;
  29346. }
  29347. $12 = HEAP32[$2>>2]|0;
  29348. $13 = ((($2)) + 8|0);
  29349. $14 = HEAP32[$13>>2]|0;
  29350. $15 = (($14) + ($12))|0;
  29351. $16 = ((($1)) + 4|0);
  29352. $17 = HEAP32[$16>>2]|0;
  29353. $18 = ($15|0)>($17|0);
  29354. $19 = (($17) - ($12))|0;
  29355. if ($18) {
  29356. HEAP32[$13>>2] = $19;
  29357. HEAP32[$vararg_buffer>>2] = $19;
  29358. _TraceLog(2,15409,$vararg_buffer);
  29359. }
  29360. $20 = HEAP32[$9>>2]|0;
  29361. $21 = ((($2)) + 12|0);
  29362. $22 = HEAP32[$21>>2]|0;
  29363. $23 = (($22) + ($20))|0;
  29364. $24 = ((($1)) + 8|0);
  29365. $25 = HEAP32[$24>>2]|0;
  29366. $26 = ($23|0)>($25|0);
  29367. $27 = (($25) - ($20))|0;
  29368. if ($26) {
  29369. HEAP32[$21>>2] = $27;
  29370. HEAP32[$vararg_buffer1>>2] = $27;
  29371. _TraceLog(2,15466,$vararg_buffer1);
  29372. $$053 = 1;
  29373. } else {
  29374. $$053 = 0;
  29375. }
  29376. ;HEAP32[$$byval_copy15>>2]=HEAP32[$1>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$1+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$1+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$1+12>>2]|0;HEAP32[$$byval_copy15+16>>2]=HEAP32[$1+16>>2]|0;
  29377. _ImageCopy($4,$$byval_copy15);
  29378. ;HEAP32[$$byval_copy15>>2]=HEAP32[$2>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$2+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$2+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$2+12>>2]|0;
  29379. _ImageCrop($4,$$byval_copy15);
  29380. $28 = HEAP32[$3>>2]|0;
  29381. $29 = ($28|0)<(0);
  29382. if ($29) {
  29383. HEAP32[$3>>2] = 0;
  29384. }
  29385. $30 = ((($3)) + 4|0);
  29386. $31 = HEAP32[$30>>2]|0;
  29387. $32 = ($31|0)<(0);
  29388. if ($32) {
  29389. HEAP32[$30>>2] = 0;
  29390. }
  29391. $33 = ((($3)) + 8|0);
  29392. $34 = HEAP32[$33>>2]|0;
  29393. $35 = HEAP32[$13>>2]|0;
  29394. $36 = ($34|0)==($35|0);
  29395. if ($36) {
  29396. $37 = ((($3)) + 12|0);
  29397. $38 = HEAP32[$37>>2]|0;
  29398. $39 = HEAP32[$21>>2]|0;
  29399. $40 = ($38|0)==($39|0);
  29400. if (!($40)) {
  29401. label = 15;
  29402. }
  29403. } else {
  29404. label = 15;
  29405. }
  29406. if ((label|0) == 15) {
  29407. $41 = ((($3)) + 12|0);
  29408. $42 = HEAP32[$41>>2]|0;
  29409. _ImageResize($4,$34,$42);
  29410. }
  29411. $43 = HEAP32[$3>>2]|0;
  29412. $44 = (($43) + ($34))|0;
  29413. $45 = ((($0)) + 4|0);
  29414. $46 = HEAP32[$45>>2]|0;
  29415. $47 = ($44|0)>($46|0);
  29416. $48 = (($46) - ($43))|0;
  29417. if ($47) {
  29418. HEAP32[$33>>2] = $48;
  29419. HEAP32[$vararg_buffer4>>2] = $48;
  29420. _TraceLog(2,15525,$vararg_buffer4);
  29421. $$1 = 1;
  29422. } else {
  29423. $$1 = $$053;
  29424. }
  29425. $49 = HEAP32[$30>>2]|0;
  29426. $50 = ((($3)) + 12|0);
  29427. $51 = HEAP32[$50>>2]|0;
  29428. $52 = (($51) + ($49))|0;
  29429. $53 = ((($0)) + 8|0);
  29430. $54 = HEAP32[$53>>2]|0;
  29431. $55 = ($52|0)>($54|0);
  29432. $56 = (($54) - ($49))|0;
  29433. if ($55) {
  29434. HEAP32[$50>>2] = $56;
  29435. HEAP32[$vararg_buffer7>>2] = $56;
  29436. _TraceLog(2,15587,$vararg_buffer7);
  29437. label = 21;
  29438. } else {
  29439. $57 = ($$1|0)==(0);
  29440. if (!($57)) {
  29441. label = 21;
  29442. }
  29443. }
  29444. if ((label|0) == 21) {
  29445. HEAP32[$5>>2] = 0;
  29446. $58 = ((($5)) + 4|0);
  29447. HEAP32[$58>>2] = 0;
  29448. $59 = ((($5)) + 8|0);
  29449. $60 = HEAP32[$33>>2]|0;
  29450. HEAP32[$59>>2] = $60;
  29451. $61 = ((($5)) + 12|0);
  29452. $62 = HEAP32[$50>>2]|0;
  29453. HEAP32[$61>>2] = $62;
  29454. ;HEAP32[$$byval_copy15>>2]=HEAP32[$5>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$5+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$5+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$5+12>>2]|0;
  29455. _ImageCrop($4,$$byval_copy15);
  29456. }
  29457. ;HEAP32[$$byval_copy15>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy15+16>>2]=HEAP32[$0+16>>2]|0;
  29458. $63 = (_GetImageData($$byval_copy15)|0);
  29459. ;HEAP32[$$byval_copy15>>2]=HEAP32[$4>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$4+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$4+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$4+12>>2]|0;HEAP32[$$byval_copy15+16>>2]=HEAP32[$4+16>>2]|0;
  29460. $64 = (_GetImageData($$byval_copy15)|0);
  29461. ;HEAP32[$$byval_copy15>>2]=HEAP32[$4>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$4+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$4+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$4+12>>2]|0;HEAP32[$$byval_copy15+16>>2]=HEAP32[$4+16>>2]|0;
  29462. _UnloadImage($$byval_copy15);
  29463. $65 = HEAP32[$30>>2]|0;
  29464. $66 = HEAP32[$50>>2]|0;
  29465. $67 = ($66|0)>(0);
  29466. if (!($67)) {
  29467. ;HEAP32[$$byval_copy15>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy15+16>>2]=HEAP32[$0+16>>2]|0;
  29468. _UnloadImage($$byval_copy15);
  29469. $74 = HEAP32[$45>>2]|0;
  29470. $75 = HEAP32[$53>>2]|0;
  29471. _LoadImageEx($6,$63,$74,$75);
  29472. ;HEAP32[$0>>2]=HEAP32[$6>>2]|0;HEAP32[$0+4>>2]=HEAP32[$6+4>>2]|0;HEAP32[$0+8>>2]=HEAP32[$6+8>>2]|0;HEAP32[$0+12>>2]=HEAP32[$6+12>>2]|0;HEAP32[$0+16>>2]=HEAP32[$6+16>>2]|0;
  29473. $76 = ((($0)) + 16|0);
  29474. $77 = HEAP32[$76>>2]|0;
  29475. _ImageFormat($0,$77);
  29476. _free($64);
  29477. _free($63);
  29478. STACKTOP = sp;return;
  29479. }
  29480. $68 = HEAP32[$3>>2]|0;
  29481. $69 = HEAP32[$33>>2]|0;
  29482. $70 = ($69|0)>(0);
  29483. $71 = HEAP32[$30>>2]|0;
  29484. $72 = HEAP32[$50>>2]|0;
  29485. $73 = (($72) + ($71))|0;
  29486. $$05255 = $65;$79 = $65;
  29487. while(1) {
  29488. if ($70) {
  29489. $78 = (($$05255) - ($79))|0;
  29490. $80 = HEAP32[$33>>2]|0;
  29491. $81 = (($80) + ($68))|0;
  29492. $$054 = $68;$88 = $69;
  29493. while(1) {
  29494. $84 = HEAP32[$45>>2]|0;
  29495. $85 = Math_imul($84, $$05255)|0;
  29496. $86 = (($85) + ($$054))|0;
  29497. $$sroa$0$0$$sroa_idx = (($63) + ($86<<2)|0);
  29498. $$sroa$0$0$copyload = HEAP8[$$sroa$0$0$$sroa_idx>>0]|0;
  29499. $$sroa$7$0$$sroa_idx = (((($63) + ($86<<2)|0)) + 1|0);
  29500. $$sroa$7$0$copyload = HEAP8[$$sroa$7$0$$sroa_idx>>0]|0;
  29501. $$sroa$10$0$$sroa_idx = (((($63) + ($86<<2)|0)) + 2|0);
  29502. $$sroa$10$0$copyload = HEAP8[$$sroa$10$0$$sroa_idx>>0]|0;
  29503. $87 = Math_imul($88, $78)|0;
  29504. $89 = (($$054) - ($68))|0;
  29505. $90 = (($87) + ($89))|0;
  29506. $$sroa$024$0$$sroa_idx = (($64) + ($90<<2)|0);
  29507. $$sroa$024$0$copyload = HEAP8[$$sroa$024$0$$sroa_idx>>0]|0;
  29508. $$sroa$4$0$$sroa_idx = (((($64) + ($90<<2)|0)) + 1|0);
  29509. $$sroa$4$0$copyload = HEAP8[$$sroa$4$0$$sroa_idx>>0]|0;
  29510. $$sroa$5$0$$sroa_idx = (((($64) + ($90<<2)|0)) + 2|0);
  29511. $$sroa$5$0$copyload = HEAP8[$$sroa$5$0$$sroa_idx>>0]|0;
  29512. $$sroa$6$0$$sroa_idx = (((($64) + ($90<<2)|0)) + 3|0);
  29513. $$sroa$6$0$copyload = HEAP8[$$sroa$6$0$$sroa_idx>>0]|0;
  29514. $91 = $$sroa$6$0$copyload&255;
  29515. $92 = $$sroa$024$0$copyload&255;
  29516. $93 = $$sroa$0$0$copyload&255;
  29517. $94 = (($92) - ($93))|0;
  29518. $95 = Math_imul($91, $94)|0;
  29519. $96 = $95 >>> 8;
  29520. $97 = (($96) + ($93))|0;
  29521. $98 = $97&255;
  29522. $99 = $$sroa$4$0$copyload&255;
  29523. $100 = $$sroa$7$0$copyload&255;
  29524. $101 = (($99) - ($100))|0;
  29525. $102 = Math_imul($91, $101)|0;
  29526. $103 = $102 >>> 8;
  29527. $104 = (($103) + ($100))|0;
  29528. $105 = $104&255;
  29529. $106 = $$sroa$5$0$copyload&255;
  29530. $107 = $$sroa$10$0$copyload&255;
  29531. $108 = (($106) - ($107))|0;
  29532. $109 = Math_imul($91, $108)|0;
  29533. $110 = $109 >>> 8;
  29534. $111 = (($110) + ($107))|0;
  29535. $112 = $111&255;
  29536. HEAP8[$$sroa$0$0$$sroa_idx>>0] = $98;
  29537. HEAP8[$$sroa$7$0$$sroa_idx>>0] = $105;
  29538. HEAP8[$$sroa$10$0$$sroa_idx>>0] = $112;
  29539. $113 = (($$054) + 1)|0;
  29540. $114 = ($113|0)<($81|0);
  29541. if ($114) {
  29542. $$054 = $113;$88 = $80;
  29543. } else {
  29544. break;
  29545. }
  29546. }
  29547. }
  29548. $82 = (($$05255) + 1)|0;
  29549. $83 = ($82|0)<($73|0);
  29550. if ($83) {
  29551. $$05255 = $82;$79 = $71;
  29552. } else {
  29553. break;
  29554. }
  29555. }
  29556. ;HEAP32[$$byval_copy15>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy15+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy15+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy15+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy15+16>>2]=HEAP32[$0+16>>2]|0;
  29557. _UnloadImage($$byval_copy15);
  29558. $74 = HEAP32[$45>>2]|0;
  29559. $75 = HEAP32[$53>>2]|0;
  29560. _LoadImageEx($6,$63,$74,$75);
  29561. ;HEAP32[$0>>2]=HEAP32[$6>>2]|0;HEAP32[$0+4>>2]=HEAP32[$6+4>>2]|0;HEAP32[$0+8>>2]=HEAP32[$6+8>>2]|0;HEAP32[$0+12>>2]=HEAP32[$6+12>>2]|0;HEAP32[$0+16>>2]=HEAP32[$6+16>>2]|0;
  29562. $76 = ((($0)) + 16|0);
  29563. $77 = HEAP32[$76>>2]|0;
  29564. _ImageFormat($0,$77);
  29565. _free($64);
  29566. _free($63);
  29567. STACKTOP = sp;return;
  29568. }
  29569. function _GetDefaultFont($0) {
  29570. $0 = $0|0;
  29571. var label = 0, sp = 0;
  29572. sp = STACKTOP;
  29573. ;HEAP32[$0>>2]=HEAP32[21404>>2]|0;HEAP32[$0+4>>2]=HEAP32[21404+4>>2]|0;HEAP32[$0+8>>2]=HEAP32[21404+8>>2]|0;HEAP32[$0+12>>2]=HEAP32[21404+12>>2]|0;HEAP32[$0+16>>2]=HEAP32[21404+16>>2]|0;HEAP32[$0+20>>2]=HEAP32[21404+20>>2]|0;HEAP32[$0+24>>2]=HEAP32[21404+24>>2]|0;HEAP32[$0+28>>2]=HEAP32[21404+28>>2]|0;
  29574. return;
  29575. }
  29576. function _GetCharIndex($0,$1) {
  29577. $0 = $0|0;
  29578. $1 = $1|0;
  29579. var $$08 = 0, $$09 = 0, $10 = 0, $11 = 0, $12 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  29580. sp = STACKTOP;
  29581. $2 = ((($0)) + 24|0);
  29582. $3 = HEAP32[$2>>2]|0;
  29583. $4 = ($3|0)>(0);
  29584. if (!($4)) {
  29585. $$08 = 0;
  29586. return ($$08|0);
  29587. }
  29588. $5 = ((($0)) + 28|0);
  29589. $6 = HEAP32[$5>>2]|0;
  29590. $$09 = 0;
  29591. while(1) {
  29592. $7 = (($6) + ($$09<<5)|0);
  29593. $8 = HEAP32[$7>>2]|0;
  29594. $9 = ($8|0)==($1|0);
  29595. if ($9) {
  29596. $$08 = $$09;
  29597. label = 5;
  29598. break;
  29599. }
  29600. $10 = (($$09) + 1)|0;
  29601. $11 = HEAP32[$2>>2]|0;
  29602. $12 = ($10|0)<($11|0);
  29603. if ($12) {
  29604. $$09 = $10;
  29605. } else {
  29606. $$08 = 0;
  29607. label = 5;
  29608. break;
  29609. }
  29610. }
  29611. if ((label|0) == 5) {
  29612. return ($$08|0);
  29613. }
  29614. return (0)|0;
  29615. }
  29616. function _ImageFlipHorizontal($0) {
  29617. $0 = $0|0;
  29618. var $$03234 = 0, $$033 = 0, $$byval_copy1 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0;
  29619. var $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  29620. sp = STACKTOP;
  29621. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  29622. $$byval_copy1 = sp + 20|0;
  29623. $1 = sp;
  29624. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  29625. $2 = (_GetImageData($$byval_copy1)|0);
  29626. $3 = ((($0)) + 4|0);
  29627. $4 = HEAP32[$3>>2]|0;
  29628. $5 = $4 << 2;
  29629. $6 = ((($0)) + 8|0);
  29630. $7 = HEAP32[$6>>2]|0;
  29631. $8 = Math_imul($5, $7)|0;
  29632. $9 = (_malloc($8)|0);
  29633. $10 = ($7|0)>(0);
  29634. if ($10) {
  29635. $11 = HEAP32[$3>>2]|0;
  29636. $12 = ($11|0)>(0);
  29637. $13 = HEAP32[$6>>2]|0;
  29638. $$03234 = 0;
  29639. while(1) {
  29640. if ($12) {
  29641. $14 = HEAP32[$3>>2]|0;
  29642. $$033 = 0;$23 = $11;
  29643. while(1) {
  29644. $22 = Math_imul($23, $$03234)|0;
  29645. $24 = (($22) + ($$033))|0;
  29646. $25 = $$033 ^ -1;
  29647. $26 = (($23) + ($25))|0;
  29648. $27 = (($26) + ($22))|0;
  29649. $28 = (($9) + ($24<<2)|0);
  29650. $29 = (($2) + ($27<<2)|0);
  29651. $30 = HEAPU8[$29>>0]|(HEAPU8[$29+1>>0]<<8)|(HEAPU8[$29+2>>0]<<16)|(HEAPU8[$29+3>>0]<<24);
  29652. HEAP8[$28>>0]=$30&255;HEAP8[$28+1>>0]=($30>>8)&255;HEAP8[$28+2>>0]=($30>>16)&255;HEAP8[$28+3>>0]=$30>>24;
  29653. $31 = (($$033) + 1)|0;
  29654. $32 = ($31|0)<($14|0);
  29655. if ($32) {
  29656. $$033 = $31;$23 = $14;
  29657. } else {
  29658. break;
  29659. }
  29660. }
  29661. }
  29662. $20 = (($$03234) + 1)|0;
  29663. $21 = ($20|0)<($13|0);
  29664. if ($21) {
  29665. $$03234 = $20;
  29666. } else {
  29667. break;
  29668. }
  29669. }
  29670. }
  29671. $15 = HEAP32[$3>>2]|0;
  29672. $16 = HEAP32[$6>>2]|0;
  29673. _LoadImageEx($1,$9,$15,$16);
  29674. $17 = ((($0)) + 16|0);
  29675. $18 = HEAP32[$17>>2]|0;
  29676. _ImageFormat($1,$18);
  29677. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  29678. _UnloadImage($$byval_copy1);
  29679. _free($2);
  29680. _free($9);
  29681. $19 = HEAP32[$1>>2]|0;
  29682. HEAP32[$0>>2] = $19;
  29683. STACKTOP = sp;return;
  29684. }
  29685. function _DrawTexture($0,$1,$2,$3) {
  29686. $0 = $0|0;
  29687. $1 = $1|0;
  29688. $2 = $2|0;
  29689. $3 = $3|0;
  29690. var $$byval_copy = 0, $$byval_copy1 = 0, $$byval_copy2 = 0, $4 = 0, $5 = 0.0, $6 = 0, $7 = 0.0, label = 0, sp = 0;
  29691. sp = STACKTOP;
  29692. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  29693. $$byval_copy2 = sp + 40|0;
  29694. $$byval_copy1 = sp + 32|0;
  29695. $$byval_copy = sp + 8|0;
  29696. $4 = sp;
  29697. $5 = (+($1|0));
  29698. HEAPF32[$4>>2] = $5;
  29699. $6 = ((($4)) + 4|0);
  29700. $7 = (+($2|0));
  29701. HEAPF32[$6>>2] = $7;
  29702. ;HEAP32[$$byval_copy>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy+16>>2]=HEAP32[$0+16>>2]|0;
  29703. ;HEAP32[$$byval_copy1>>2]=HEAP32[$4>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$4+4>>2]|0;
  29704. ;HEAP8[$$byval_copy2>>0]=HEAP8[$3>>0]|0;HEAP8[$$byval_copy2+1>>0]=HEAP8[$3+1>>0]|0;HEAP8[$$byval_copy2+2>>0]=HEAP8[$3+2>>0]|0;HEAP8[$$byval_copy2+3>>0]=HEAP8[$3+3>>0]|0;
  29705. _DrawTextureEx($$byval_copy,$$byval_copy1,0.0,1.0,$$byval_copy2);
  29706. STACKTOP = sp;return;
  29707. }
  29708. function _DrawTextureEx($0,$1,$2,$3,$4) {
  29709. $0 = $0|0;
  29710. $1 = $1|0;
  29711. $2 = +$2;
  29712. $3 = +$3;
  29713. $4 = $4|0;
  29714. var $$byval_copy = 0, $$byval_copy1 = 0, $$byval_copy2 = 0, $$byval_copy3 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0.0, $16 = 0, $17 = 0, $18 = 0, $19 = 0.0, $20 = 0, $21 = 0, $22 = 0, $23 = 0.0, $24 = 0.0, $25 = 0;
  29715. var $26 = 0, $27 = 0, $28 = 0.0, $29 = 0.0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $tmpcast$byval_copy = 0, label = 0, sp = 0;
  29716. sp = STACKTOP;
  29717. STACKTOP = STACKTOP + 112|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(112|0);
  29718. $$byval_copy3 = sp + 104|0;
  29719. $tmpcast$byval_copy = sp + 96|0;
  29720. $$byval_copy2 = sp + 80|0;
  29721. $$byval_copy1 = sp + 64|0;
  29722. $$byval_copy = sp + 40|0;
  29723. $5 = sp + 24|0;
  29724. $6 = sp + 8|0;
  29725. $7 = sp;
  29726. HEAP32[$5>>2] = 0;
  29727. $8 = ((($5)) + 4|0);
  29728. HEAP32[$8>>2] = 0;
  29729. $9 = ((($5)) + 8|0);
  29730. $10 = ((($0)) + 4|0);
  29731. $11 = HEAP32[$10>>2]|0;
  29732. HEAP32[$9>>2] = $11;
  29733. $12 = ((($5)) + 12|0);
  29734. $13 = ((($0)) + 8|0);
  29735. $14 = HEAP32[$13>>2]|0;
  29736. HEAP32[$12>>2] = $14;
  29737. $15 = +HEAPF32[$1>>2];
  29738. $16 = (~~(($15)));
  29739. HEAP32[$6>>2] = $16;
  29740. $17 = ((($6)) + 4|0);
  29741. $18 = ((($1)) + 4|0);
  29742. $19 = +HEAPF32[$18>>2];
  29743. $20 = (~~(($19)));
  29744. HEAP32[$17>>2] = $20;
  29745. $21 = ((($6)) + 8|0);
  29746. $22 = HEAP32[$10>>2]|0;
  29747. $23 = (+($22|0));
  29748. $24 = $23 * $3;
  29749. $25 = (~~(($24)));
  29750. HEAP32[$21>>2] = $25;
  29751. $26 = ((($6)) + 12|0);
  29752. $27 = HEAP32[$13>>2]|0;
  29753. $28 = (+($27|0));
  29754. $29 = $28 * $3;
  29755. $30 = (~~(($29)));
  29756. HEAP32[$26>>2] = $30;
  29757. $31 = $7;
  29758. $32 = $31;
  29759. HEAP32[$32>>2] = 0;
  29760. $33 = (($31) + 4)|0;
  29761. $34 = $33;
  29762. HEAP32[$34>>2] = 0;
  29763. ;HEAP32[$$byval_copy>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy+16>>2]=HEAP32[$0+16>>2]|0;
  29764. ;HEAP32[$$byval_copy1>>2]=HEAP32[$5>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$5+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$5+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$5+12>>2]|0;
  29765. ;HEAP32[$$byval_copy2>>2]=HEAP32[$6>>2]|0;HEAP32[$$byval_copy2+4>>2]=HEAP32[$6+4>>2]|0;HEAP32[$$byval_copy2+8>>2]=HEAP32[$6+8>>2]|0;HEAP32[$$byval_copy2+12>>2]=HEAP32[$6+12>>2]|0;
  29766. ;HEAP32[$tmpcast$byval_copy>>2]=HEAP32[$7>>2]|0;HEAP32[$tmpcast$byval_copy+4>>2]=HEAP32[$7+4>>2]|0;
  29767. ;HEAP8[$$byval_copy3>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy3+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy3+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy3+3>>0]=HEAP8[$4+3>>0]|0;
  29768. _DrawTexturePro($$byval_copy,$$byval_copy1,$$byval_copy2,$tmpcast$byval_copy,$2,$$byval_copy3);
  29769. STACKTOP = sp;return;
  29770. }
  29771. function _DrawTexturePro($0,$1,$2,$3,$4,$5) {
  29772. $0 = $0|0;
  29773. $1 = $1|0;
  29774. $2 = $2|0;
  29775. $3 = $3|0;
  29776. $4 = +$4;
  29777. $5 = $5|0;
  29778. var $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0.0, $22 = 0, $23 = 0, $24 = 0.0, $25 = 0.0, $26 = 0.0, $27 = 0, $28 = 0.0, $29 = 0.0;
  29779. var $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0.0, $39 = 0, $40 = 0, $41 = 0.0, $42 = 0.0, $43 = 0, $44 = 0, $45 = 0.0, $46 = 0, $47 = 0, $48 = 0.0, $49 = 0.0;
  29780. var $50 = 0, $51 = 0.0, $52 = 0, $53 = 0.0, $54 = 0.0, $55 = 0, $56 = 0, $57 = 0, $58 = 0.0, $59 = 0, $6 = 0, $60 = 0.0, $61 = 0.0, $62 = 0, $63 = 0, $64 = 0.0, $65 = 0, $66 = 0, $67 = 0, $68 = 0.0;
  29781. var $69 = 0, $7 = 0, $70 = 0.0, $71 = 0.0, $72 = 0, $73 = 0, $74 = 0, $75 = 0.0, $76 = 0, $77 = 0.0, $78 = 0.0, $79 = 0, $8 = 0, $80 = 0, $81 = 0.0, $82 = 0, $83 = 0.0, $84 = 0, $85 = 0, $86 = 0;
  29782. var $87 = 0.0, $88 = 0, $89 = 0.0, $9 = 0, $90 = 0.0, $91 = 0, $92 = 0.0, $93 = 0, $94 = 0.0, $95 = 0.0, $96 = 0, $97 = 0.0, label = 0, sp = 0;
  29783. sp = STACKTOP;
  29784. $6 = HEAP32[$0>>2]|0;
  29785. $7 = ($6|0)==(0);
  29786. if ($7) {
  29787. return;
  29788. }
  29789. $8 = ((($1)) + 8|0);
  29790. $9 = HEAP32[$8>>2]|0;
  29791. $10 = ($9|0)<(0);
  29792. if ($10) {
  29793. $11 = HEAP32[$1>>2]|0;
  29794. $12 = (($11) - ($9))|0;
  29795. HEAP32[$1>>2] = $12;
  29796. }
  29797. $13 = ((($1)) + 12|0);
  29798. $14 = HEAP32[$13>>2]|0;
  29799. $15 = ($14|0)<(0);
  29800. if ($15) {
  29801. $16 = ((($1)) + 4|0);
  29802. $17 = HEAP32[$16>>2]|0;
  29803. $18 = (($17) - ($14))|0;
  29804. HEAP32[$16>>2] = $18;
  29805. }
  29806. $19 = HEAP32[$0>>2]|0;
  29807. _rlEnableTexture($19);
  29808. _rlPushMatrix();
  29809. $20 = HEAP32[$2>>2]|0;
  29810. $21 = (+($20|0));
  29811. $22 = ((($2)) + 4|0);
  29812. $23 = HEAP32[$22>>2]|0;
  29813. $24 = (+($23|0));
  29814. _rlTranslatef($21,$24,0.0);
  29815. _rlRotatef($4,0.0,0.0,1.0);
  29816. $25 = +HEAPF32[$3>>2];
  29817. $26 = -$25;
  29818. $27 = ((($3)) + 4|0);
  29819. $28 = +HEAPF32[$27>>2];
  29820. $29 = -$28;
  29821. _rlTranslatef($26,$29,0.0);
  29822. _rlBegin(7);
  29823. $30 = HEAP8[$5>>0]|0;
  29824. $31 = ((($5)) + 1|0);
  29825. $32 = HEAP8[$31>>0]|0;
  29826. $33 = ((($5)) + 2|0);
  29827. $34 = HEAP8[$33>>0]|0;
  29828. $35 = ((($5)) + 3|0);
  29829. $36 = HEAP8[$35>>0]|0;
  29830. _rlColor4ub($30,$32,$34,$36);
  29831. $37 = HEAP32[$1>>2]|0;
  29832. $38 = (+($37|0));
  29833. $39 = ((($0)) + 4|0);
  29834. $40 = HEAP32[$39>>2]|0;
  29835. $41 = (+($40|0));
  29836. $42 = $38 / $41;
  29837. $43 = ((($1)) + 4|0);
  29838. $44 = HEAP32[$43>>2]|0;
  29839. $45 = (+($44|0));
  29840. $46 = ((($0)) + 8|0);
  29841. $47 = HEAP32[$46>>2]|0;
  29842. $48 = (+($47|0));
  29843. $49 = $45 / $48;
  29844. _rlTexCoord2f($42,$49);
  29845. _rlVertex2f(0.0,0.0);
  29846. $50 = HEAP32[$1>>2]|0;
  29847. $51 = (+($50|0));
  29848. $52 = HEAP32[$39>>2]|0;
  29849. $53 = (+($52|0));
  29850. $54 = $51 / $53;
  29851. $55 = HEAP32[$43>>2]|0;
  29852. $56 = HEAP32[$13>>2]|0;
  29853. $57 = (($56) + ($55))|0;
  29854. $58 = (+($57|0));
  29855. $59 = HEAP32[$46>>2]|0;
  29856. $60 = (+($59|0));
  29857. $61 = $58 / $60;
  29858. _rlTexCoord2f($54,$61);
  29859. $62 = ((($2)) + 12|0);
  29860. $63 = HEAP32[$62>>2]|0;
  29861. $64 = (+($63|0));
  29862. _rlVertex2f(0.0,$64);
  29863. $65 = HEAP32[$1>>2]|0;
  29864. $66 = HEAP32[$8>>2]|0;
  29865. $67 = (($66) + ($65))|0;
  29866. $68 = (+($67|0));
  29867. $69 = HEAP32[$39>>2]|0;
  29868. $70 = (+($69|0));
  29869. $71 = $68 / $70;
  29870. $72 = HEAP32[$43>>2]|0;
  29871. $73 = HEAP32[$13>>2]|0;
  29872. $74 = (($73) + ($72))|0;
  29873. $75 = (+($74|0));
  29874. $76 = HEAP32[$46>>2]|0;
  29875. $77 = (+($76|0));
  29876. $78 = $75 / $77;
  29877. _rlTexCoord2f($71,$78);
  29878. $79 = ((($2)) + 8|0);
  29879. $80 = HEAP32[$79>>2]|0;
  29880. $81 = (+($80|0));
  29881. $82 = HEAP32[$62>>2]|0;
  29882. $83 = (+($82|0));
  29883. _rlVertex2f($81,$83);
  29884. $84 = HEAP32[$1>>2]|0;
  29885. $85 = HEAP32[$8>>2]|0;
  29886. $86 = (($85) + ($84))|0;
  29887. $87 = (+($86|0));
  29888. $88 = HEAP32[$39>>2]|0;
  29889. $89 = (+($88|0));
  29890. $90 = $87 / $89;
  29891. $91 = HEAP32[$43>>2]|0;
  29892. $92 = (+($91|0));
  29893. $93 = HEAP32[$46>>2]|0;
  29894. $94 = (+($93|0));
  29895. $95 = $92 / $94;
  29896. _rlTexCoord2f($90,$95);
  29897. $96 = HEAP32[$79>>2]|0;
  29898. $97 = (+($96|0));
  29899. _rlVertex2f($97,0.0);
  29900. _rlEnd();
  29901. _rlPopMatrix();
  29902. _rlDisableTexture();
  29903. return;
  29904. }
  29905. function _DrawText($0,$1,$2,$3,$4) {
  29906. $0 = $0|0;
  29907. $1 = $1|0;
  29908. $2 = $2|0;
  29909. $3 = $3|0;
  29910. $4 = $4|0;
  29911. var $$ = 0, $$byval_copy = 0, $$byval_copy1 = 0, $$byval_copy2 = 0, $10 = 0.0, $11 = 0, $12 = 0.0, $13 = 0, $14 = 0, $15 = 0.0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  29912. sp = STACKTOP;
  29913. STACKTOP = STACKTOP + 128|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(128|0);
  29914. $$byval_copy2 = sp + 112|0;
  29915. $$byval_copy1 = sp + 104|0;
  29916. $$byval_copy = sp + 72|0;
  29917. $5 = sp + 32|0;
  29918. $6 = sp + 64|0;
  29919. $7 = sp;
  29920. _GetDefaultFont($5);
  29921. $8 = HEAP32[$5>>2]|0;
  29922. $9 = ($8|0)==(0);
  29923. if ($9) {
  29924. STACKTOP = sp;return;
  29925. }
  29926. $10 = (+($1|0));
  29927. HEAPF32[$6>>2] = $10;
  29928. $11 = ((($6)) + 4|0);
  29929. $12 = (+($2|0));
  29930. HEAPF32[$11>>2] = $12;
  29931. $13 = ($3|0)>(10);
  29932. $$ = $13 ? $3 : 10;
  29933. $14 = (($$>>>0) / 10)&-1;
  29934. _GetDefaultFont($7);
  29935. $15 = (+($$|0));
  29936. ;HEAP32[$$byval_copy>>2]=HEAP32[$7>>2]|0;HEAP32[$$byval_copy+4>>2]=HEAP32[$7+4>>2]|0;HEAP32[$$byval_copy+8>>2]=HEAP32[$7+8>>2]|0;HEAP32[$$byval_copy+12>>2]=HEAP32[$7+12>>2]|0;HEAP32[$$byval_copy+16>>2]=HEAP32[$7+16>>2]|0;HEAP32[$$byval_copy+20>>2]=HEAP32[$7+20>>2]|0;HEAP32[$$byval_copy+24>>2]=HEAP32[$7+24>>2]|0;HEAP32[$$byval_copy+28>>2]=HEAP32[$7+28>>2]|0;
  29937. ;HEAP32[$$byval_copy1>>2]=HEAP32[$6>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$6+4>>2]|0;
  29938. ;HEAP8[$$byval_copy2>>0]=HEAP8[$4>>0]|0;HEAP8[$$byval_copy2+1>>0]=HEAP8[$4+1>>0]|0;HEAP8[$$byval_copy2+2>>0]=HEAP8[$4+2>>0]|0;HEAP8[$$byval_copy2+3>>0]=HEAP8[$4+3>>0]|0;
  29939. _DrawTextEx($$byval_copy,$0,$$byval_copy1,$15,$14,$$byval_copy2);
  29940. STACKTOP = sp;return;
  29941. }
  29942. function _DrawTextEx($0,$1,$2,$3,$4,$5) {
  29943. $0 = $0|0;
  29944. $1 = $1|0;
  29945. $2 = $2|0;
  29946. $3 = +$3;
  29947. $4 = $4|0;
  29948. $5 = $5|0;
  29949. var $$04954 = 0, $$05153 = 0, $$055 = 0, $$1 = 0, $$150 = 0, $$152 = 0, $$2 = 0, $$byval_copy1 = 0, $$byval_copy2 = 0, $$byval_copy3 = 0, $$byval_copy4 = 0, $$byval_copy5 = 0, $$sink = 0, $10 = 0, $11 = 0.0, $12 = 0.0, $13 = 0, $14 = 0, $15 = 0.0, $16 = 0;
  29950. var $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0.0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0.0, $28 = 0.0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0;
  29951. var $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0.0, $45 = 0.0, $46 = 0, $47 = 0, $48 = 0.0, $49 = 0.0, $50 = 0.0, $51 = 0, $52 = 0.0, $53 = 0.0, $54 = 0.0, $55 = 0, $56 = 0;
  29952. var $57 = 0.0, $58 = 0.0, $59 = 0.0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0.0, $64 = 0.0, $65 = 0, $66 = 0, $67 = 0, $68 = 0.0, $69 = 0.0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0;
  29953. var $75 = 0, $76 = 0, $77 = 0.0, $78 = 0.0, $79 = 0.0, $8 = 0, $80 = 0, $81 = 0, $82 = 0.0, $83 = 0.0, $84 = 0.0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $9 = 0, label = 0, sp = 0;
  29954. sp = STACKTOP;
  29955. STACKTOP = STACKTOP + 128|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(128|0);
  29956. $$byval_copy5 = sp + 88|0;
  29957. $$byval_copy4 = sp + 80|0;
  29958. $$byval_copy3 = sp + 64|0;
  29959. $$byval_copy2 = sp + 48|0;
  29960. $$byval_copy1 = sp + 24|0;
  29961. $6 = sp + 8|0;
  29962. $7 = sp;
  29963. $8 = (_strlen($1)|0);
  29964. $9 = ((($0)) + 20|0);
  29965. $10 = HEAP32[$9>>2]|0;
  29966. $11 = (+($10|0));
  29967. $12 = $3 / $11;
  29968. $13 = ($8|0)>(0);
  29969. if (!($13)) {
  29970. STACKTOP = sp;return;
  29971. }
  29972. $14 = ((($0)) + 28|0);
  29973. $15 = +HEAPF32[$2>>2];
  29974. $16 = ((($6)) + 4|0);
  29975. $17 = ((($2)) + 4|0);
  29976. $18 = ((($6)) + 8|0);
  29977. $19 = ((($6)) + 12|0);
  29978. $20 = ((($7)) + 4|0);
  29979. $21 = (+($4|0));
  29980. $$04954 = 0;$$05153 = 0;$$055 = 0;
  29981. while(1) {
  29982. $22 = (($1) + ($$055)|0);
  29983. $23 = HEAP8[$22>>0]|0;
  29984. switch ($23<<24>>24) {
  29985. case 10: {
  29986. $24 = HEAP32[$9>>2]|0;
  29987. $25 = (($24|0) / 2)&-1;
  29988. $26 = (($25) + ($24))|0;
  29989. $27 = (+($26|0));
  29990. $28 = $12 * $27;
  29991. $29 = (~~(($28)));
  29992. $30 = (($29) + ($$05153))|0;
  29993. $$150 = 0;$$152 = $30;$$2 = $$055;
  29994. break;
  29995. }
  29996. case -62: {
  29997. $31 = (($$055) + 1)|0;
  29998. $32 = (($1) + ($31)|0);
  29999. $33 = HEAP8[$32>>0]|0;
  30000. $34 = $33&255;
  30001. $$1 = $31;$$sink = $34;
  30002. label = 9;
  30003. break;
  30004. }
  30005. case -61: {
  30006. $35 = (($$055) + 1)|0;
  30007. $36 = (($1) + ($35)|0);
  30008. $37 = HEAP8[$36>>0]|0;
  30009. $38 = $37&255;
  30010. $39 = (($38) + 64)|0;
  30011. $$1 = $35;$$sink = $39;
  30012. label = 9;
  30013. break;
  30014. }
  30015. default: {
  30016. $40 = $23 << 24 >> 24;
  30017. $$1 = $$055;$$sink = $40;
  30018. label = 9;
  30019. }
  30020. }
  30021. do {
  30022. if ((label|0) == 9) {
  30023. label = 0;
  30024. ;HEAP32[$$byval_copy5>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy5+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy5+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy5+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy5+16>>2]=HEAP32[$0+16>>2]|0;HEAP32[$$byval_copy5+20>>2]=HEAP32[$0+20>>2]|0;HEAP32[$$byval_copy5+24>>2]=HEAP32[$0+24>>2]|0;HEAP32[$$byval_copy5+28>>2]=HEAP32[$0+28>>2]|0;
  30025. $41 = (_GetCharIndex($$byval_copy5,$$sink)|0);
  30026. $42 = HEAP32[$14>>2]|0;
  30027. $43 = (((($42) + ($41<<5)|0)) + 4|0);
  30028. $44 = (+($$04954|0));
  30029. $45 = $44 + $15;
  30030. $46 = (((($42) + ($41<<5)|0)) + 20|0);
  30031. $47 = HEAP32[$46>>2]|0;
  30032. $48 = (+($47|0));
  30033. $49 = $12 * $48;
  30034. $50 = $45 + $49;
  30035. $51 = (~~(($50)));
  30036. HEAP32[$6>>2] = $51;
  30037. $52 = +HEAPF32[$17>>2];
  30038. $53 = (+($$05153|0));
  30039. $54 = $53 + $52;
  30040. $55 = (((($42) + ($41<<5)|0)) + 24|0);
  30041. $56 = HEAP32[$55>>2]|0;
  30042. $57 = (+($56|0));
  30043. $58 = $12 * $57;
  30044. $59 = $54 + $58;
  30045. $60 = (~~(($59)));
  30046. HEAP32[$16>>2] = $60;
  30047. $61 = (((($42) + ($41<<5)|0)) + 12|0);
  30048. $62 = HEAP32[$61>>2]|0;
  30049. $63 = (+($62|0));
  30050. $64 = $12 * $63;
  30051. $65 = (~~(($64)));
  30052. HEAP32[$18>>2] = $65;
  30053. $66 = (((($42) + ($41<<5)|0)) + 16|0);
  30054. $67 = HEAP32[$66>>2]|0;
  30055. $68 = (+($67|0));
  30056. $69 = $12 * $68;
  30057. $70 = (~~(($69)));
  30058. HEAP32[$19>>2] = $70;
  30059. HEAPF32[$7>>2] = 0.0;
  30060. HEAPF32[$20>>2] = 0.0;
  30061. ;HEAP32[$$byval_copy1>>2]=HEAP32[$0>>2]|0;HEAP32[$$byval_copy1+4>>2]=HEAP32[$0+4>>2]|0;HEAP32[$$byval_copy1+8>>2]=HEAP32[$0+8>>2]|0;HEAP32[$$byval_copy1+12>>2]=HEAP32[$0+12>>2]|0;HEAP32[$$byval_copy1+16>>2]=HEAP32[$0+16>>2]|0;
  30062. ;HEAP32[$$byval_copy2>>2]=HEAP32[$43>>2]|0;HEAP32[$$byval_copy2+4>>2]=HEAP32[$43+4>>2]|0;HEAP32[$$byval_copy2+8>>2]=HEAP32[$43+8>>2]|0;HEAP32[$$byval_copy2+12>>2]=HEAP32[$43+12>>2]|0;
  30063. ;HEAP32[$$byval_copy3>>2]=HEAP32[$6>>2]|0;HEAP32[$$byval_copy3+4>>2]=HEAP32[$6+4>>2]|0;HEAP32[$$byval_copy3+8>>2]=HEAP32[$6+8>>2]|0;HEAP32[$$byval_copy3+12>>2]=HEAP32[$6+12>>2]|0;
  30064. ;HEAP32[$$byval_copy4>>2]=HEAP32[$7>>2]|0;HEAP32[$$byval_copy4+4>>2]=HEAP32[$7+4>>2]|0;
  30065. ;HEAP8[$$byval_copy5>>0]=HEAP8[$5>>0]|0;HEAP8[$$byval_copy5+1>>0]=HEAP8[$5+1>>0]|0;HEAP8[$$byval_copy5+2>>0]=HEAP8[$5+2>>0]|0;HEAP8[$$byval_copy5+3>>0]=HEAP8[$5+3>>0]|0;
  30066. _DrawTexturePro($$byval_copy1,$$byval_copy2,$$byval_copy3,$$byval_copy4,0.0,$$byval_copy5);
  30067. $71 = HEAP32[$14>>2]|0;
  30068. $72 = (((($71) + ($41<<5)|0)) + 28|0);
  30069. $73 = HEAP32[$72>>2]|0;
  30070. $74 = ($73|0)==(0);
  30071. if ($74) {
  30072. $75 = (((($71) + ($41<<5)|0)) + 12|0);
  30073. $76 = HEAP32[$75>>2]|0;
  30074. $77 = (+($76|0));
  30075. $78 = $12 * $77;
  30076. $79 = $21 + $78;
  30077. $80 = (~~(($79)));
  30078. $81 = (($80) + ($$04954))|0;
  30079. $$150 = $81;$$152 = $$05153;$$2 = $$1;
  30080. break;
  30081. } else {
  30082. $82 = (+($73|0));
  30083. $83 = $12 * $82;
  30084. $84 = $21 + $83;
  30085. $85 = (~~(($84)));
  30086. $86 = (($85) + ($$04954))|0;
  30087. $$150 = $86;$$152 = $$05153;$$2 = $$1;
  30088. break;
  30089. }
  30090. }
  30091. } while(0);
  30092. $87 = (($$2) + 1)|0;
  30093. $88 = ($87|0)<($8|0);
  30094. if ($88) {
  30095. $$04954 = $$150;$$05153 = $$152;$$055 = $87;
  30096. } else {
  30097. break;
  30098. }
  30099. }
  30100. STACKTOP = sp;return;
  30101. }
  30102. function _emscripten_GetProcAddress($0) {
  30103. $0 = $0|0;
  30104. var $1 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0;
  30105. var $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0;
  30106. var $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0;
  30107. var $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0;
  30108. var $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0;
  30109. var $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0, $2 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0;
  30110. var $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0, $22 = 0, $220 = 0, $221 = 0, $222 = 0, $223 = 0, $224 = 0;
  30111. var $225 = 0, $226 = 0, $227 = 0, $228 = 0, $229 = 0, $23 = 0, $230 = 0, $231 = 0, $232 = 0, $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0;
  30112. var $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0, $249 = 0, $25 = 0, $250 = 0, $251 = 0, $252 = 0, $253 = 0, $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0;
  30113. var $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0, $267 = 0, $268 = 0, $269 = 0, $27 = 0, $270 = 0, $271 = 0, $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0;
  30114. var $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0, $285 = 0, $286 = 0, $287 = 0, $288 = 0, $289 = 0, $29 = 0, $290 = 0, $291 = 0, $292 = 0, $293 = 0, $294 = 0, $295 = 0, $296 = 0, $297 = 0;
  30115. var $298 = 0, $299 = 0, $3 = 0, $30 = 0, $300 = 0, $301 = 0, $302 = 0, $303 = 0, $304 = 0, $305 = 0, $306 = 0, $307 = 0, $308 = 0, $309 = 0, $31 = 0, $310 = 0, $311 = 0, $312 = 0, $313 = 0, $314 = 0;
  30116. var $315 = 0, $316 = 0, $317 = 0, $318 = 0, $319 = 0, $32 = 0, $320 = 0, $321 = 0, $322 = 0, $323 = 0, $324 = 0, $325 = 0, $326 = 0, $327 = 0, $328 = 0, $329 = 0, $33 = 0, $330 = 0, $331 = 0, $332 = 0;
  30117. var $333 = 0, $334 = 0, $335 = 0, $336 = 0, $337 = 0, $338 = 0, $339 = 0, $34 = 0, $340 = 0, $341 = 0, $342 = 0, $343 = 0, $344 = 0, $345 = 0, $346 = 0, $347 = 0, $348 = 0, $349 = 0, $35 = 0, $350 = 0;
  30118. var $351 = 0, $352 = 0, $353 = 0, $354 = 0, $355 = 0, $356 = 0, $357 = 0, $358 = 0, $359 = 0, $36 = 0, $360 = 0, $361 = 0, $362 = 0, $363 = 0, $364 = 0, $365 = 0, $366 = 0, $367 = 0, $368 = 0, $369 = 0;
  30119. var $37 = 0, $370 = 0, $371 = 0, $372 = 0, $373 = 0, $374 = 0, $375 = 0, $376 = 0, $377 = 0, $378 = 0, $379 = 0, $38 = 0, $380 = 0, $381 = 0, $382 = 0, $383 = 0, $384 = 0, $385 = 0, $386 = 0, $387 = 0;
  30120. var $388 = 0, $389 = 0, $39 = 0, $390 = 0, $391 = 0, $392 = 0, $393 = 0, $394 = 0, $395 = 0, $396 = 0, $397 = 0, $398 = 0, $399 = 0, $4 = 0, $40 = 0, $400 = 0, $401 = 0, $402 = 0, $403 = 0, $404 = 0;
  30121. var $405 = 0, $406 = 0, $407 = 0, $408 = 0, $409 = 0, $41 = 0, $410 = 0, $411 = 0, $412 = 0, $413 = 0, $414 = 0, $415 = 0, $416 = 0, $417 = 0, $418 = 0, $419 = 0, $42 = 0, $420 = 0, $421 = 0, $422 = 0;
  30122. var $423 = 0, $424 = 0, $425 = 0, $426 = 0, $427 = 0, $428 = 0, $429 = 0, $43 = 0, $430 = 0, $431 = 0, $432 = 0, $433 = 0, $434 = 0, $435 = 0, $436 = 0, $437 = 0, $438 = 0, $439 = 0, $44 = 0, $440 = 0;
  30123. var $441 = 0, $442 = 0, $443 = 0, $444 = 0, $445 = 0, $446 = 0, $447 = 0, $448 = 0, $449 = 0, $45 = 0, $450 = 0, $451 = 0, $452 = 0, $453 = 0, $454 = 0, $455 = 0, $456 = 0, $457 = 0, $458 = 0, $459 = 0;
  30124. var $46 = 0, $460 = 0, $461 = 0, $462 = 0, $463 = 0, $464 = 0, $465 = 0, $466 = 0, $467 = 0, $468 = 0, $469 = 0, $47 = 0, $470 = 0, $471 = 0, $472 = 0, $473 = 0, $474 = 0, $475 = 0, $476 = 0, $477 = 0;
  30125. var $478 = 0, $479 = 0, $48 = 0, $480 = 0, $481 = 0, $482 = 0, $483 = 0, $484 = 0, $485 = 0, $486 = 0, $487 = 0, $488 = 0, $489 = 0, $49 = 0, $490 = 0, $491 = 0, $492 = 0, $493 = 0, $494 = 0, $495 = 0;
  30126. var $496 = 0, $497 = 0, $498 = 0, $499 = 0, $5 = 0, $50 = 0, $500 = 0, $501 = 0, $502 = 0, $503 = 0, $504 = 0, $505 = 0, $506 = 0, $507 = 0, $508 = 0, $509 = 0, $51 = 0, $510 = 0, $511 = 0, $512 = 0;
  30127. var $513 = 0, $514 = 0, $515 = 0, $516 = 0, $517 = 0, $518 = 0, $519 = 0, $52 = 0, $520 = 0, $521 = 0, $522 = 0, $523 = 0, $524 = 0, $525 = 0, $526 = 0, $527 = 0, $528 = 0, $529 = 0, $53 = 0, $530 = 0;
  30128. var $531 = 0, $532 = 0, $533 = 0, $534 = 0, $535 = 0, $536 = 0, $537 = 0, $538 = 0, $539 = 0, $54 = 0, $540 = 0, $541 = 0, $542 = 0, $543 = 0, $544 = 0, $545 = 0, $546 = 0, $547 = 0, $548 = 0, $549 = 0;
  30129. var $55 = 0, $550 = 0, $551 = 0, $552 = 0, $553 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0;
  30130. var $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0;
  30131. var $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, label = 0, sp = 0;
  30132. sp = STACKTOP;
  30133. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  30134. $1 = sp + 12|0;
  30135. $2 = sp + 8|0;
  30136. $3 = sp + 4|0;
  30137. $4 = sp;
  30138. HEAP32[$2>>2] = $0;
  30139. $5 = HEAP32[$2>>2]|0;
  30140. $6 = (_strlen($5)|0);
  30141. $7 = (($6) + 1)|0;
  30142. $8 = (_malloc($7)|0);
  30143. HEAP32[$3>>2] = $8;
  30144. $9 = HEAP32[$3>>2]|0;
  30145. $10 = HEAP32[$2>>2]|0;
  30146. (_strcpy($9,$10)|0);
  30147. $11 = HEAP32[$3>>2]|0;
  30148. $12 = (_strstr($11,15651)|0);
  30149. HEAP32[$4>>2] = $12;
  30150. $13 = HEAP32[$4>>2]|0;
  30151. $14 = ($13|0)!=(0|0);
  30152. if ($14) {
  30153. $15 = HEAP32[$4>>2]|0;
  30154. HEAP8[$15>>0] = 0;
  30155. }
  30156. $16 = HEAP32[$3>>2]|0;
  30157. $17 = (_strstr($16,15655)|0);
  30158. HEAP32[$4>>2] = $17;
  30159. $18 = HEAP32[$4>>2]|0;
  30160. $19 = ($18|0)!=(0|0);
  30161. if ($19) {
  30162. $20 = HEAP32[$4>>2]|0;
  30163. HEAP8[$20>>0] = 0;
  30164. }
  30165. $21 = HEAP32[$3>>2]|0;
  30166. $22 = (_strstr($21,15659)|0);
  30167. HEAP32[$4>>2] = $22;
  30168. $23 = HEAP32[$4>>2]|0;
  30169. $24 = ($23|0)!=(0|0);
  30170. if ($24) {
  30171. $25 = HEAP32[$4>>2]|0;
  30172. HEAP8[$25>>0] = 0;
  30173. }
  30174. $26 = HEAP32[$3>>2]|0;
  30175. $27 = (_strstr($26,15663)|0);
  30176. HEAP32[$4>>2] = $27;
  30177. $28 = HEAP32[$4>>2]|0;
  30178. $29 = ($28|0)!=(0|0);
  30179. if ($29) {
  30180. $30 = HEAP32[$4>>2]|0;
  30181. HEAP8[$30>>0] = 0;
  30182. }
  30183. $31 = HEAP32[$3>>2]|0;
  30184. $32 = (_strcmp($31,15669)|0);
  30185. $33 = ($32|0)!=(0);
  30186. do {
  30187. if ($33) {
  30188. $34 = HEAP32[$3>>2]|0;
  30189. $35 = (_strcmp($34,15707)|0);
  30190. $36 = ($35|0)!=(0);
  30191. if (!($36)) {
  30192. HEAP32[$3>>2] = 15726;
  30193. break;
  30194. }
  30195. $37 = HEAP32[$3>>2]|0;
  30196. $38 = (_strcmp($37,15739)|0);
  30197. $39 = ($38|0)!=(0);
  30198. if (!($39)) {
  30199. HEAP32[$3>>2] = 15760;
  30200. break;
  30201. }
  30202. $40 = HEAP32[$3>>2]|0;
  30203. $41 = (_strcmp($40,15775)|0);
  30204. $42 = ($41|0)!=(0);
  30205. if (!($42)) {
  30206. HEAP32[$3>>2] = 15790;
  30207. break;
  30208. }
  30209. $43 = HEAP32[$3>>2]|0;
  30210. $44 = (_strcmp($43,15805)|0);
  30211. $45 = ($44|0)!=(0);
  30212. if (!($45)) {
  30213. HEAP32[$3>>2] = 15820;
  30214. }
  30215. } else {
  30216. HEAP32[$3>>2] = 15691;
  30217. }
  30218. } while(0);
  30219. $46 = HEAP32[$3>>2]|0;
  30220. $47 = (_strcmp($46,15835)|0);
  30221. $48 = ($47|0)!=(0);
  30222. do {
  30223. if ($48) {
  30224. $49 = HEAP32[$3>>2]|0;
  30225. $50 = (_strcmp($49,15849)|0);
  30226. $51 = ($50|0)!=(0);
  30227. if (!($51)) {
  30228. HEAP32[$1>>2] = 3;
  30229. break;
  30230. }
  30231. $52 = HEAP32[$3>>2]|0;
  30232. $53 = (_strcmp($52,15861)|0);
  30233. $54 = ($53|0)!=(0);
  30234. if (!($54)) {
  30235. HEAP32[$1>>2] = 7;
  30236. break;
  30237. }
  30238. $55 = HEAP32[$3>>2]|0;
  30239. $56 = (_strcmp($55,15875)|0);
  30240. $57 = ($56|0)!=(0);
  30241. if (!($57)) {
  30242. HEAP32[$1>>2] = 8;
  30243. break;
  30244. }
  30245. $58 = HEAP32[$3>>2]|0;
  30246. $59 = (_strcmp($58,15887)|0);
  30247. $60 = ($59|0)!=(0);
  30248. if (!($60)) {
  30249. HEAP32[$1>>2] = 9;
  30250. break;
  30251. }
  30252. $61 = HEAP32[$3>>2]|0;
  30253. $62 = (_strcmp($61,15901)|0);
  30254. $63 = ($62|0)!=(0);
  30255. if (!($63)) {
  30256. HEAP32[$1>>2] = 10;
  30257. break;
  30258. }
  30259. $64 = HEAP32[$3>>2]|0;
  30260. $65 = (_strcmp($64,15915)|0);
  30261. $66 = ($65|0)!=(0);
  30262. if (!($66)) {
  30263. HEAP32[$1>>2] = 11;
  30264. break;
  30265. }
  30266. $67 = HEAP32[$3>>2]|0;
  30267. $68 = (_strcmp($67,15932)|0);
  30268. $69 = ($68|0)!=(0);
  30269. if (!($69)) {
  30270. HEAP32[$1>>2] = 1;
  30271. break;
  30272. }
  30273. $70 = HEAP32[$3>>2]|0;
  30274. $71 = (_strcmp($70,15955)|0);
  30275. $72 = ($71|0)!=(0);
  30276. if (!($72)) {
  30277. HEAP32[$1>>2] = 1;
  30278. break;
  30279. }
  30280. $73 = HEAP32[$3>>2]|0;
  30281. $74 = (_strcmp($73,15981)|0);
  30282. $75 = ($74|0)!=(0);
  30283. if (!($75)) {
  30284. HEAP32[$1>>2] = 2;
  30285. break;
  30286. }
  30287. $76 = HEAP32[$3>>2]|0;
  30288. $77 = (_strcmp($76,15994)|0);
  30289. $78 = ($77|0)!=(0);
  30290. if (!($78)) {
  30291. HEAP32[$1>>2] = 3;
  30292. break;
  30293. }
  30294. $79 = HEAP32[$3>>2]|0;
  30295. $80 = (_strcmp($79,16010)|0);
  30296. $81 = ($80|0)!=(0);
  30297. if (!($81)) {
  30298. HEAP32[$1>>2] = 1;
  30299. break;
  30300. }
  30301. $82 = HEAP32[$3>>2]|0;
  30302. $83 = (_strcmp($82,16023)|0);
  30303. $84 = ($83|0)!=(0);
  30304. if (!($84)) {
  30305. HEAP32[$1>>2] = 12;
  30306. break;
  30307. }
  30308. $85 = HEAP32[$3>>2]|0;
  30309. $86 = (_strcmp($85,16037)|0);
  30310. $87 = ($86|0)!=(0);
  30311. if (!($87)) {
  30312. HEAP32[$1>>2] = 2;
  30313. break;
  30314. }
  30315. $88 = HEAP32[$3>>2]|0;
  30316. $89 = (_strcmp($88,16057)|0);
  30317. $90 = ($89|0)!=(0);
  30318. if (!($90)) {
  30319. HEAP32[$1>>2] = 3;
  30320. break;
  30321. }
  30322. $91 = HEAP32[$3>>2]|0;
  30323. $92 = (_strcmp($91,16077)|0);
  30324. $93 = ($92|0)!=(0);
  30325. if (!($93)) {
  30326. HEAP32[$1>>2] = 4;
  30327. break;
  30328. }
  30329. $94 = HEAP32[$3>>2]|0;
  30330. $95 = (_strcmp($94,16094)|0);
  30331. $96 = ($95|0)!=(0);
  30332. if (!($96)) {
  30333. HEAP32[$1>>2] = 5;
  30334. break;
  30335. }
  30336. $97 = HEAP32[$3>>2]|0;
  30337. $98 = (_strcmp($97,16111)|0);
  30338. $99 = ($98|0)!=(0);
  30339. if (!($99)) {
  30340. HEAP32[$1>>2] = 4;
  30341. break;
  30342. }
  30343. $100 = HEAP32[$3>>2]|0;
  30344. $101 = (_strcmp($100,16123)|0);
  30345. $102 = ($101|0)!=(0);
  30346. if (!($102)) {
  30347. HEAP32[$1>>2] = 13;
  30348. break;
  30349. }
  30350. $103 = HEAP32[$3>>2]|0;
  30351. $104 = (_strcmp($103,16136)|0);
  30352. $105 = ($104|0)!=(0);
  30353. if (!($105)) {
  30354. HEAP32[$1>>2] = 14;
  30355. break;
  30356. }
  30357. $106 = HEAP32[$3>>2]|0;
  30358. $107 = (_strcmp($106,16152)|0);
  30359. $108 = ($107|0)!=(0);
  30360. if (!($108)) {
  30361. HEAP32[$1>>2] = 6;
  30362. break;
  30363. }
  30364. $109 = HEAP32[$3>>2]|0;
  30365. $110 = (_strcmp($109,16175)|0);
  30366. $111 = ($110|0)!=(0);
  30367. if (!($111)) {
  30368. HEAP32[$1>>2] = 2;
  30369. break;
  30370. }
  30371. $112 = HEAP32[$3>>2]|0;
  30372. $113 = (_strcmp($112,16188)|0);
  30373. $114 = ($113|0)!=(0);
  30374. if (!($114)) {
  30375. HEAP32[$1>>2] = 3;
  30376. break;
  30377. }
  30378. $115 = HEAP32[$3>>2]|0;
  30379. $116 = (_strcmp($115,16204)|0);
  30380. $117 = ($116|0)!=(0);
  30381. if (!($117)) {
  30382. HEAP32[$1>>2] = 5;
  30383. break;
  30384. }
  30385. $118 = HEAP32[$3>>2]|0;
  30386. $119 = (_strcmp($118,16215)|0);
  30387. $120 = ($119|0)!=(0);
  30388. if (!($120)) {
  30389. HEAP32[$1>>2] = 15;
  30390. break;
  30391. }
  30392. $121 = HEAP32[$3>>2]|0;
  30393. $122 = (_strcmp($121,16234)|0);
  30394. $123 = ($122|0)!=(0);
  30395. if (!($123)) {
  30396. HEAP32[$1>>2] = 16;
  30397. break;
  30398. }
  30399. $124 = HEAP32[$3>>2]|0;
  30400. $125 = (_strcmp($124,16256)|0);
  30401. $126 = ($125|0)!=(0);
  30402. if (!($126)) {
  30403. HEAP32[$1>>2] = 17;
  30404. break;
  30405. }
  30406. $127 = HEAP32[$3>>2]|0;
  30407. $128 = (_strcmp($127,16275)|0);
  30408. $129 = ($128|0)!=(0);
  30409. if (!($129)) {
  30410. HEAP32[$1>>2] = 7;
  30411. break;
  30412. }
  30413. $130 = HEAP32[$3>>2]|0;
  30414. $131 = (_strcmp($130,16304)|0);
  30415. $132 = ($131|0)!=(0);
  30416. if (!($132)) {
  30417. HEAP32[$1>>2] = 6;
  30418. break;
  30419. }
  30420. $133 = HEAP32[$3>>2]|0;
  30421. $134 = (_strcmp($133,16321)|0);
  30422. $135 = ($134|0)!=(0);
  30423. if (!($135)) {
  30424. HEAP32[$1>>2] = 8;
  30425. break;
  30426. }
  30427. $136 = HEAP32[$3>>2]|0;
  30428. $137 = (_strcmp($136,16336)|0);
  30429. $138 = ($137|0)!=(0);
  30430. if (!($138)) {
  30431. HEAP32[$1>>2] = 9;
  30432. break;
  30433. }
  30434. $139 = HEAP32[$3>>2]|0;
  30435. $140 = (_strcmp($139,16351)|0);
  30436. $141 = ($140|0)!=(0);
  30437. if (!($141)) {
  30438. HEAP32[$1>>2] = 1;
  30439. break;
  30440. }
  30441. $142 = HEAP32[$3>>2]|0;
  30442. $143 = (_strcmp($142,16372)|0);
  30443. $144 = ($143|0)!=(0);
  30444. if (!($144)) {
  30445. HEAP32[$1>>2] = 10;
  30446. break;
  30447. }
  30448. $145 = HEAP32[$3>>2]|0;
  30449. $146 = (_strcmp($145,16392)|0);
  30450. $147 = ($146|0)!=(0);
  30451. if (!($147)) {
  30452. HEAP32[$1>>2] = 11;
  30453. break;
  30454. }
  30455. $148 = HEAP32[$3>>2]|0;
  30456. $149 = (_strcmp($148,16412)|0);
  30457. $150 = ($149|0)!=(0);
  30458. if (!($150)) {
  30459. HEAP32[$1>>2] = 12;
  30460. break;
  30461. }
  30462. $151 = HEAP32[$3>>2]|0;
  30463. $152 = (_strcmp($151,16438)|0);
  30464. $153 = ($152|0)!=(0);
  30465. if (!($153)) {
  30466. HEAP32[$1>>2] = 2;
  30467. break;
  30468. }
  30469. $154 = HEAP32[$3>>2]|0;
  30470. $155 = (_strcmp($154,16457)|0);
  30471. $156 = ($155|0)!=(0);
  30472. if (!($156)) {
  30473. HEAP32[$1>>2] = 1;
  30474. break;
  30475. }
  30476. $157 = HEAP32[$3>>2]|0;
  30477. $158 = (_strcmp($157,16469)|0);
  30478. $159 = ($158|0)!=(0);
  30479. if (!($159)) {
  30480. HEAP32[$1>>2] = 3;
  30481. break;
  30482. }
  30483. $160 = HEAP32[$3>>2]|0;
  30484. $161 = (_strcmp($160,16481)|0);
  30485. $162 = ($161|0)!=(0);
  30486. if (!($162)) {
  30487. HEAP32[$1>>2] = 1;
  30488. break;
  30489. }
  30490. $163 = HEAP32[$3>>2]|0;
  30491. $164 = (_strcmp($163,16493)|0);
  30492. $165 = ($164|0)!=(0);
  30493. if (!($165)) {
  30494. HEAP32[$1>>2] = 1;
  30495. break;
  30496. }
  30497. $166 = HEAP32[$3>>2]|0;
  30498. $167 = (_strcmp($166,16505)|0);
  30499. $168 = ($167|0)!=(0);
  30500. if (!($168)) {
  30501. HEAP32[$1>>2] = 18;
  30502. break;
  30503. }
  30504. $169 = HEAP32[$3>>2]|0;
  30505. $170 = (_strcmp($169,16517)|0);
  30506. $171 = ($170|0)!=(0);
  30507. if (!($171)) {
  30508. HEAP32[$1>>2] = 13;
  30509. break;
  30510. }
  30511. $172 = HEAP32[$3>>2]|0;
  30512. $173 = (_strcmp($172,16529)|0);
  30513. $174 = ($173|0)!=(0);
  30514. if (!($174)) {
  30515. HEAP32[$1>>2] = 4;
  30516. break;
  30517. }
  30518. $175 = HEAP32[$3>>2]|0;
  30519. $176 = (_strcmp($175,16541)|0);
  30520. $177 = ($176|0)!=(0);
  30521. if (!($177)) {
  30522. HEAP32[$1>>2] = 2;
  30523. break;
  30524. }
  30525. $178 = HEAP32[$3>>2]|0;
  30526. $179 = (_strcmp($178,16553)|0);
  30527. $180 = ($179|0)!=(0);
  30528. if (!($180)) {
  30529. HEAP32[$1>>2] = 14;
  30530. break;
  30531. }
  30532. $181 = HEAP32[$3>>2]|0;
  30533. $182 = (_strcmp($181,16566)|0);
  30534. $183 = ($182|0)!=(0);
  30535. if (!($183)) {
  30536. HEAP32[$1>>2] = 15;
  30537. break;
  30538. }
  30539. $184 = HEAP32[$3>>2]|0;
  30540. $185 = (_strcmp($184,16579)|0);
  30541. $186 = ($185|0)!=(0);
  30542. if (!($186)) {
  30543. HEAP32[$1>>2] = 16;
  30544. break;
  30545. }
  30546. $187 = HEAP32[$3>>2]|0;
  30547. $188 = (_strcmp($187,16592)|0);
  30548. $189 = ($188|0)!=(0);
  30549. if (!($189)) {
  30550. HEAP32[$1>>2] = 17;
  30551. break;
  30552. }
  30553. $190 = HEAP32[$3>>2]|0;
  30554. $191 = (_strcmp($190,16605)|0);
  30555. $192 = ($191|0)!=(0);
  30556. if (!($192)) {
  30557. HEAP32[$1>>2] = 18;
  30558. break;
  30559. }
  30560. $193 = HEAP32[$3>>2]|0;
  30561. $194 = (_strcmp($193,16618)|0);
  30562. $195 = ($194|0)!=(0);
  30563. if (!($195)) {
  30564. HEAP32[$1>>2] = 19;
  30565. break;
  30566. }
  30567. $196 = HEAP32[$3>>2]|0;
  30568. $197 = (_strcmp($196,16631)|0);
  30569. $198 = ($197|0)!=(0);
  30570. if (!($198)) {
  30571. HEAP32[$1>>2] = 20;
  30572. break;
  30573. }
  30574. $199 = HEAP32[$3>>2]|0;
  30575. $200 = (_strcmp($199,16644)|0);
  30576. $201 = ($200|0)!=(0);
  30577. if (!($201)) {
  30578. HEAP32[$1>>2] = 21;
  30579. break;
  30580. }
  30581. $202 = HEAP32[$3>>2]|0;
  30582. $203 = (_strcmp($202,16657)|0);
  30583. $204 = ($203|0)!=(0);
  30584. if (!($204)) {
  30585. HEAP32[$1>>2] = 5;
  30586. break;
  30587. }
  30588. $205 = HEAP32[$3>>2]|0;
  30589. $206 = (_strcmp($205,16676)|0);
  30590. $207 = ($206|0)!=(0);
  30591. if (!($207)) {
  30592. HEAP32[$1>>2] = 6;
  30593. break;
  30594. }
  30595. $208 = HEAP32[$3>>2]|0;
  30596. $209 = (_strcmp($208,16695)|0);
  30597. $210 = ($209|0)!=(0);
  30598. if (!($210)) {
  30599. HEAP32[$1>>2] = 7;
  30600. break;
  30601. }
  30602. $211 = HEAP32[$3>>2]|0;
  30603. $212 = (_strcmp($211,16714)|0);
  30604. $213 = ($212|0)!=(0);
  30605. if (!($213)) {
  30606. HEAP32[$1>>2] = 19;
  30607. break;
  30608. }
  30609. $214 = HEAP32[$3>>2]|0;
  30610. $215 = (_strcmp($214,16727)|0);
  30611. $216 = ($215|0)!=(0);
  30612. if (!($216)) {
  30613. HEAP32[$1>>2] = 20;
  30614. break;
  30615. }
  30616. $217 = HEAP32[$3>>2]|0;
  30617. $218 = (_strcmp($217,16745)|0);
  30618. $219 = ($218|0)!=(0);
  30619. if (!($219)) {
  30620. HEAP32[$1>>2] = 21;
  30621. break;
  30622. }
  30623. $220 = HEAP32[$3>>2]|0;
  30624. $221 = (_strcmp($220,16763)|0);
  30625. $222 = ($221|0)!=(0);
  30626. if (!($222)) {
  30627. HEAP32[$1>>2] = 22;
  30628. break;
  30629. }
  30630. $223 = HEAP32[$3>>2]|0;
  30631. $224 = (_strcmp($223,16781)|0);
  30632. $225 = ($224|0)!=(0);
  30633. if (!($225)) {
  30634. HEAP32[$1>>2] = 23;
  30635. break;
  30636. }
  30637. $226 = HEAP32[$3>>2]|0;
  30638. $227 = (_strcmp($226,16799)|0);
  30639. $228 = ($227|0)!=(0);
  30640. if (!($228)) {
  30641. HEAP32[$1>>2] = 2;
  30642. break;
  30643. }
  30644. $229 = HEAP32[$3>>2]|0;
  30645. $230 = (_strcmp($229,16819)|0);
  30646. $231 = ($230|0)!=(0);
  30647. if (!($231)) {
  30648. HEAP32[$1>>2] = 3;
  30649. break;
  30650. }
  30651. $232 = HEAP32[$3>>2]|0;
  30652. $233 = (_strcmp($232,15760)|0);
  30653. $234 = ($233|0)!=(0);
  30654. if (!($234)) {
  30655. HEAP32[$1>>2] = 7;
  30656. break;
  30657. }
  30658. $235 = HEAP32[$3>>2]|0;
  30659. $236 = (_strcmp($235,16837)|0);
  30660. $237 = ($236|0)!=(0);
  30661. if (!($237)) {
  30662. HEAP32[$1>>2] = 1;
  30663. break;
  30664. }
  30665. $238 = HEAP32[$3>>2]|0;
  30666. $239 = (_strcmp($238,16852)|0);
  30667. $240 = ($239|0)!=(0);
  30668. if (!($240)) {
  30669. HEAP32[$1>>2] = 8;
  30670. break;
  30671. }
  30672. $241 = HEAP32[$3>>2]|0;
  30673. $242 = (_strcmp($241,16873)|0);
  30674. $243 = ($242|0)!=(0);
  30675. if (!($243)) {
  30676. HEAP32[$1>>2] = 9;
  30677. break;
  30678. }
  30679. $244 = HEAP32[$3>>2]|0;
  30680. $245 = (_strcmp($244,16888)|0);
  30681. $246 = ($245|0)!=(0);
  30682. if (!($246)) {
  30683. HEAP32[$1>>2] = 10;
  30684. break;
  30685. }
  30686. $247 = HEAP32[$3>>2]|0;
  30687. $248 = (_strcmp($247,16906)|0);
  30688. $249 = ($248|0)!=(0);
  30689. if (!($249)) {
  30690. HEAP32[$1>>2] = 2;
  30691. break;
  30692. }
  30693. $250 = HEAP32[$3>>2]|0;
  30694. $251 = (_strcmp($250,16922)|0);
  30695. $252 = ($251|0)!=(0);
  30696. if (!($252)) {
  30697. HEAP32[$1>>2] = 11;
  30698. break;
  30699. }
  30700. $253 = HEAP32[$3>>2]|0;
  30701. $254 = (_strcmp($253,16941)|0);
  30702. $255 = ($254|0)!=(0);
  30703. if (!($255)) {
  30704. HEAP32[$1>>2] = 22;
  30705. break;
  30706. }
  30707. $256 = HEAP32[$3>>2]|0;
  30708. $257 = (_strcmp($256,16955)|0);
  30709. $258 = ($257|0)!=(0);
  30710. if (!($258)) {
  30711. HEAP32[$1>>2] = 23;
  30712. break;
  30713. }
  30714. $259 = HEAP32[$3>>2]|0;
  30715. $260 = (_strcmp($259,16970)|0);
  30716. $261 = ($260|0)!=(0);
  30717. if (!($261)) {
  30718. HEAP32[$1>>2] = 8;
  30719. break;
  30720. }
  30721. $262 = HEAP32[$3>>2]|0;
  30722. $263 = (_strcmp($262,15691)|0);
  30723. $264 = ($263|0)!=(0);
  30724. if (!($264)) {
  30725. HEAP32[$1>>2] = 1;
  30726. break;
  30727. }
  30728. $265 = HEAP32[$3>>2]|0;
  30729. $266 = (_strcmp($265,16981)|0);
  30730. $267 = ($266|0)!=(0);
  30731. if (!($267)) {
  30732. HEAP32[$1>>2] = 3;
  30733. break;
  30734. }
  30735. $268 = HEAP32[$3>>2]|0;
  30736. $269 = (_strcmp($268,15790)|0);
  30737. $270 = ($269|0)!=(0);
  30738. if (!($270)) {
  30739. HEAP32[$1>>2] = 24;
  30740. break;
  30741. }
  30742. $271 = HEAP32[$3>>2]|0;
  30743. $272 = (_strcmp($271,15820)|0);
  30744. $273 = ($272|0)!=(0);
  30745. if (!($273)) {
  30746. HEAP32[$1>>2] = 25;
  30747. break;
  30748. }
  30749. $274 = HEAP32[$3>>2]|0;
  30750. $275 = (_strcmp($274,16997)|0);
  30751. $276 = ($275|0)!=(0);
  30752. if (!($276)) {
  30753. HEAP32[$1>>2] = 12;
  30754. break;
  30755. }
  30756. $277 = HEAP32[$3>>2]|0;
  30757. $278 = (_strcmp($277,17024)|0);
  30758. $279 = ($278|0)!=(0);
  30759. if (!($279)) {
  30760. HEAP32[$1>>2] = 4;
  30761. break;
  30762. }
  30763. $280 = HEAP32[$3>>2]|0;
  30764. $281 = (_strcmp($280,17038)|0);
  30765. $282 = ($281|0)!=(0);
  30766. if (!($282)) {
  30767. HEAP32[$1>>2] = 13;
  30768. break;
  30769. }
  30770. $283 = HEAP32[$3>>2]|0;
  30771. $284 = (_strcmp($283,15726)|0);
  30772. $285 = ($284|0)!=(0);
  30773. if (!($285)) {
  30774. HEAP32[$1>>2] = 5;
  30775. break;
  30776. }
  30777. $286 = HEAP32[$3>>2]|0;
  30778. $287 = (_strcmp($286,17058)|0);
  30779. $288 = ($287|0)!=(0);
  30780. if (!($288)) {
  30781. HEAP32[$1>>2] = 6;
  30782. break;
  30783. }
  30784. $289 = HEAP32[$3>>2]|0;
  30785. $290 = (_strcmp($289,17076)|0);
  30786. $291 = ($290|0)!=(0);
  30787. if (!($291)) {
  30788. HEAP32[$1>>2] = 9;
  30789. break;
  30790. }
  30791. $292 = HEAP32[$3>>2]|0;
  30792. $293 = (_strcmp($292,17088)|0);
  30793. $294 = ($293|0)!=(0);
  30794. if (!($294)) {
  30795. HEAP32[$1>>2] = 24;
  30796. break;
  30797. }
  30798. $295 = HEAP32[$3>>2]|0;
  30799. $296 = (_strcmp($295,17109)|0);
  30800. $297 = ($296|0)!=(0);
  30801. if (!($297)) {
  30802. HEAP32[$1>>2] = 26;
  30803. break;
  30804. }
  30805. $298 = HEAP32[$3>>2]|0;
  30806. $299 = (_strcmp($298,17127)|0);
  30807. $300 = ($299|0)!=(0);
  30808. if (!($300)) {
  30809. HEAP32[$1>>2] = 27;
  30810. break;
  30811. }
  30812. $301 = HEAP32[$3>>2]|0;
  30813. $302 = (_strcmp($301,17145)|0);
  30814. $303 = ($302|0)!=(0);
  30815. if (!($303)) {
  30816. HEAP32[$1>>2] = 28;
  30817. break;
  30818. }
  30819. $304 = HEAP32[$3>>2]|0;
  30820. $305 = (_strcmp($304,17166)|0);
  30821. $306 = ($305|0)!=(0);
  30822. if (!($306)) {
  30823. HEAP32[$1>>2] = 14;
  30824. break;
  30825. }
  30826. $307 = HEAP32[$3>>2]|0;
  30827. $308 = (_strcmp($307,17192)|0);
  30828. $309 = ($308|0)!=(0);
  30829. if (!($309)) {
  30830. HEAP32[$1>>2] = 3;
  30831. break;
  30832. }
  30833. $310 = HEAP32[$3>>2]|0;
  30834. $311 = (_strcmp($310,17215)|0);
  30835. $312 = ($311|0)!=(0);
  30836. if (!($312)) {
  30837. HEAP32[$1>>2] = 15;
  30838. break;
  30839. }
  30840. $313 = HEAP32[$3>>2]|0;
  30841. $314 = (_strcmp($313,17253)|0);
  30842. $315 = ($314|0)!=(0);
  30843. if (!($315)) {
  30844. HEAP32[$1>>2] = 10;
  30845. break;
  30846. }
  30847. $316 = HEAP32[$3>>2]|0;
  30848. $317 = (_strcmp($316,17269)|0);
  30849. $318 = ($317|0)!=(0);
  30850. if (!($318)) {
  30851. HEAP32[$1>>2] = 7;
  30852. break;
  30853. }
  30854. $319 = HEAP32[$3>>2]|0;
  30855. $320 = (_strcmp($319,17284)|0);
  30856. $321 = ($320|0)!=(0);
  30857. if (!($321)) {
  30858. HEAP32[$1>>2] = 25;
  30859. break;
  30860. }
  30861. $322 = HEAP32[$3>>2]|0;
  30862. $323 = (_strcmp($322,17307)|0);
  30863. $324 = ($323|0)!=(0);
  30864. if (!($324)) {
  30865. HEAP32[$1>>2] = 16;
  30866. break;
  30867. }
  30868. $325 = HEAP32[$3>>2]|0;
  30869. $326 = (_strcmp($325,17320)|0);
  30870. $327 = ($326|0)!=(0);
  30871. if (!($327)) {
  30872. HEAP32[$1>>2] = 29;
  30873. break;
  30874. }
  30875. $328 = HEAP32[$3>>2]|0;
  30876. $329 = (_strcmp($328,17334)|0);
  30877. $330 = ($329|0)!=(0);
  30878. if (!($330)) {
  30879. HEAP32[$1>>2] = 30;
  30880. break;
  30881. }
  30882. $331 = HEAP32[$3>>2]|0;
  30883. $332 = (_strcmp($331,17348)|0);
  30884. $333 = ($332|0)!=(0);
  30885. if (!($333)) {
  30886. HEAP32[$1>>2] = 1;
  30887. break;
  30888. }
  30889. $334 = HEAP32[$3>>2]|0;
  30890. $335 = (_strcmp($334,17368)|0);
  30891. $336 = ($335|0)!=(0);
  30892. if (!($336)) {
  30893. HEAP32[$1>>2] = 8;
  30894. break;
  30895. }
  30896. $337 = HEAP32[$3>>2]|0;
  30897. $338 = (_strcmp($337,17388)|0);
  30898. $339 = ($338|0)!=(0);
  30899. if (!($339)) {
  30900. HEAP32[$1>>2] = 17;
  30901. break;
  30902. }
  30903. $340 = HEAP32[$3>>2]|0;
  30904. $341 = (_strcmp($340,17404)|0);
  30905. $342 = ($341|0)!=(0);
  30906. if (!($342)) {
  30907. HEAP32[$1>>2] = 18;
  30908. break;
  30909. }
  30910. $343 = HEAP32[$3>>2]|0;
  30911. $344 = (_strcmp($343,17422)|0);
  30912. $345 = ($344|0)!=(0);
  30913. if (!($345)) {
  30914. HEAP32[$1>>2] = 26;
  30915. break;
  30916. }
  30917. $346 = HEAP32[$3>>2]|0;
  30918. $347 = (_strcmp($346,17438)|0);
  30919. $348 = ($347|0)!=(0);
  30920. if (!($348)) {
  30921. HEAP32[$1>>2] = 19;
  30922. break;
  30923. }
  30924. $349 = HEAP32[$3>>2]|0;
  30925. $350 = (_strcmp($349,17453)|0);
  30926. $351 = ($350|0)!=(0);
  30927. if (!($351)) {
  30928. HEAP32[$1>>2] = 9;
  30929. break;
  30930. }
  30931. $352 = HEAP32[$3>>2]|0;
  30932. $353 = (_strcmp($352,17475)|0);
  30933. $354 = ($353|0)!=(0);
  30934. if (!($354)) {
  30935. HEAP32[$1>>2] = 31;
  30936. break;
  30937. }
  30938. $355 = HEAP32[$3>>2]|0;
  30939. $356 = (_strcmp($355,17493)|0);
  30940. $357 = ($356|0)!=(0);
  30941. if (!($357)) {
  30942. HEAP32[$1>>2] = 32;
  30943. break;
  30944. }
  30945. $358 = HEAP32[$3>>2]|0;
  30946. $359 = (_strcmp($358,17514)|0);
  30947. $360 = ($359|0)!=(0);
  30948. if (!($360)) {
  30949. HEAP32[$1>>2] = 10;
  30950. break;
  30951. }
  30952. $361 = HEAP32[$3>>2]|0;
  30953. $362 = (_strcmp($361,17532)|0);
  30954. $363 = ($362|0)!=(0);
  30955. if (!($363)) {
  30956. HEAP32[$1>>2] = 11;
  30957. break;
  30958. }
  30959. $364 = HEAP32[$3>>2]|0;
  30960. $365 = (_strcmp($364,17545)|0);
  30961. $366 = ($365|0)!=(0);
  30962. if (!($366)) {
  30963. HEAP32[$1>>2] = 2;
  30964. break;
  30965. }
  30966. $367 = HEAP32[$3>>2]|0;
  30967. $368 = (_strcmp($367,17560)|0);
  30968. $369 = ($368|0)!=(0);
  30969. if (!($369)) {
  30970. HEAP32[$1>>2] = 12;
  30971. break;
  30972. }
  30973. $370 = HEAP32[$3>>2]|0;
  30974. $371 = (_strcmp($370,17574)|0);
  30975. $372 = ($371|0)!=(0);
  30976. if (!($372)) {
  30977. HEAP32[$1>>2] = 1;
  30978. break;
  30979. }
  30980. $373 = HEAP32[$3>>2]|0;
  30981. $374 = (_strcmp($373,17584)|0);
  30982. $375 = ($374|0)!=(0);
  30983. if (!($375)) {
  30984. HEAP32[$1>>2] = 1;
  30985. break;
  30986. }
  30987. $376 = HEAP32[$3>>2]|0;
  30988. $377 = (_strcmp($376,17594)|0);
  30989. $378 = ($377|0)!=(0);
  30990. if (!($378)) {
  30991. HEAP32[$1>>2] = 2;
  30992. break;
  30993. }
  30994. $379 = HEAP32[$3>>2]|0;
  30995. $380 = (_strcmp($379,17616)|0);
  30996. $381 = ($380|0)!=(0);
  30997. if (!($381)) {
  30998. HEAP32[$1>>2] = 13;
  30999. break;
  31000. }
  31001. $382 = HEAP32[$3>>2]|0;
  31002. $383 = (_strcmp($382,17642)|0);
  31003. $384 = ($383|0)!=(0);
  31004. if (!($384)) {
  31005. HEAP32[$1>>2] = 14;
  31006. break;
  31007. }
  31008. $385 = HEAP32[$3>>2]|0;
  31009. $386 = (_strcmp($385,17669)|0);
  31010. $387 = ($386|0)!=(0);
  31011. if (!($387)) {
  31012. HEAP32[$1>>2] = 27;
  31013. break;
  31014. }
  31015. $388 = HEAP32[$3>>2]|0;
  31016. $389 = (_strcmp($388,17682)|0);
  31017. $390 = ($389|0)!=(0);
  31018. if (!($390)) {
  31019. HEAP32[$1>>2] = 20;
  31020. break;
  31021. }
  31022. $391 = HEAP32[$3>>2]|0;
  31023. $392 = (_strcmp($391,17697)|0);
  31024. $393 = ($392|0)!=(0);
  31025. if (!($393)) {
  31026. HEAP32[$1>>2] = 4;
  31027. break;
  31028. }
  31029. $394 = HEAP32[$3>>2]|0;
  31030. $395 = (_strcmp($394,17712)|0);
  31031. $396 = ($395|0)!=(0);
  31032. if (!($396)) {
  31033. HEAP32[$1>>2] = 3;
  31034. break;
  31035. }
  31036. $397 = HEAP32[$3>>2]|0;
  31037. $398 = (_strcmp($397,17736)|0);
  31038. $399 = ($398|0)!=(0);
  31039. if (!($399)) {
  31040. HEAP32[$1>>2] = 2;
  31041. break;
  31042. }
  31043. $400 = HEAP32[$3>>2]|0;
  31044. $401 = (_strcmp($400,17747)|0);
  31045. $402 = ($401|0)!=(0);
  31046. if (!($402)) {
  31047. HEAP32[$1>>2] = 33;
  31048. break;
  31049. }
  31050. $403 = HEAP32[$3>>2]|0;
  31051. $404 = (_strcmp($403,17769)|0);
  31052. $405 = ($404|0)!=(0);
  31053. if (!($405)) {
  31054. HEAP32[$1>>2] = 21;
  31055. break;
  31056. }
  31057. $406 = HEAP32[$3>>2]|0;
  31058. $407 = (_strcmp($406,17791)|0);
  31059. $408 = ($407|0)!=(0);
  31060. if (!($408)) {
  31061. HEAP32[$1>>2] = 5;
  31062. break;
  31063. }
  31064. $409 = HEAP32[$3>>2]|0;
  31065. $410 = (_strcmp($409,17815)|0);
  31066. $411 = ($410|0)!=(0);
  31067. if (!($411)) {
  31068. HEAP32[$1>>2] = 4;
  31069. break;
  31070. }
  31071. $412 = HEAP32[$3>>2]|0;
  31072. $413 = (_strcmp($412,17824)|0);
  31073. $414 = ($413|0)!=(0);
  31074. if (!($414)) {
  31075. HEAP32[$1>>2] = 5;
  31076. break;
  31077. }
  31078. $415 = HEAP32[$3>>2]|0;
  31079. $416 = (_strcmp($415,17832)|0);
  31080. $417 = ($416|0)!=(0);
  31081. if (!($417)) {
  31082. HEAP32[$1>>2] = 1;
  31083. break;
  31084. }
  31085. $418 = HEAP32[$3>>2]|0;
  31086. $419 = (_strcmp($418,17845)|0);
  31087. $420 = ($419|0)!=(0);
  31088. if (!($420)) {
  31089. HEAP32[$1>>2] = 2;
  31090. break;
  31091. }
  31092. $421 = HEAP32[$3>>2]|0;
  31093. $422 = (_strcmp($421,17859)|0);
  31094. $423 = ($422|0)!=(0);
  31095. if (!($423)) {
  31096. HEAP32[$1>>2] = 15;
  31097. break;
  31098. }
  31099. $424 = HEAP32[$3>>2]|0;
  31100. $425 = (_strcmp($424,17871)|0);
  31101. $426 = ($425|0)!=(0);
  31102. if (!($426)) {
  31103. HEAP32[$1>>2] = 16;
  31104. break;
  31105. }
  31106. $427 = HEAP32[$3>>2]|0;
  31107. $428 = (_strcmp($427,17880)|0);
  31108. $429 = ($428|0)!=(0);
  31109. if (!($429)) {
  31110. HEAP32[$1>>2] = 17;
  31111. break;
  31112. }
  31113. $430 = HEAP32[$3>>2]|0;
  31114. $431 = (_strcmp($430,17890)|0);
  31115. $432 = ($431|0)!=(0);
  31116. if (!($432)) {
  31117. HEAP32[$1>>2] = 18;
  31118. break;
  31119. }
  31120. $433 = HEAP32[$3>>2]|0;
  31121. $434 = (_strcmp($433,17902)|0);
  31122. $435 = ($434|0)!=(0);
  31123. if (!($435)) {
  31124. HEAP32[$1>>2] = 19;
  31125. break;
  31126. }
  31127. $436 = HEAP32[$3>>2]|0;
  31128. $437 = (_strcmp($436,17913)|0);
  31129. $438 = ($437|0)!=(0);
  31130. if (!($438)) {
  31131. HEAP32[$1>>2] = 20;
  31132. break;
  31133. }
  31134. $439 = HEAP32[$3>>2]|0;
  31135. $440 = (_strcmp($439,17921)|0);
  31136. $441 = ($440|0)!=(0);
  31137. if (!($441)) {
  31138. HEAP32[$1>>2] = 3;
  31139. break;
  31140. }
  31141. $442 = HEAP32[$3>>2]|0;
  31142. $443 = (_strcmp($442,17933)|0);
  31143. $444 = ($443|0)!=(0);
  31144. if (!($444)) {
  31145. HEAP32[$1>>2] = 21;
  31146. break;
  31147. }
  31148. $445 = HEAP32[$3>>2]|0;
  31149. $446 = (_strcmp($445,17948)|0);
  31150. $447 = ($446|0)!=(0);
  31151. if (!($447)) {
  31152. HEAP32[$1>>2] = 22;
  31153. break;
  31154. }
  31155. $448 = HEAP32[$3>>2]|0;
  31156. $449 = (_strcmp($448,17960)|0);
  31157. $450 = ($449|0)!=(0);
  31158. if (!($450)) {
  31159. HEAP32[$1>>2] = 23;
  31160. break;
  31161. }
  31162. $451 = HEAP32[$3>>2]|0;
  31163. $452 = (_strcmp($451,17974)|0);
  31164. $453 = ($452|0)!=(0);
  31165. if (!($453)) {
  31166. HEAP32[$1>>2] = 11;
  31167. break;
  31168. }
  31169. $454 = HEAP32[$3>>2]|0;
  31170. $455 = (_strcmp($454,17999)|0);
  31171. $456 = ($455|0)!=(0);
  31172. if (!($456)) {
  31173. HEAP32[$1>>2] = 24;
  31174. break;
  31175. }
  31176. $457 = HEAP32[$3>>2]|0;
  31177. $458 = (_strcmp($457,18016)|0);
  31178. $459 = ($458|0)!=(0);
  31179. if (!($459)) {
  31180. HEAP32[$1>>2] = 25;
  31181. break;
  31182. }
  31183. $460 = HEAP32[$3>>2]|0;
  31184. $461 = (_strcmp($460,18032)|0);
  31185. $462 = ($461|0)!=(0);
  31186. if (!($462)) {
  31187. HEAP32[$1>>2] = 26;
  31188. break;
  31189. }
  31190. $463 = HEAP32[$3>>2]|0;
  31191. $464 = (_strcmp($463,18048)|0);
  31192. $465 = ($464|0)!=(0);
  31193. if (!($465)) {
  31194. HEAP32[$1>>2] = 12;
  31195. break;
  31196. }
  31197. $466 = HEAP32[$3>>2]|0;
  31198. $467 = (_strcmp($466,18060)|0);
  31199. $468 = ($467|0)!=(0);
  31200. if (!($468)) {
  31201. HEAP32[$1>>2] = 34;
  31202. break;
  31203. }
  31204. $469 = HEAP32[$3>>2]|0;
  31205. $470 = (_strcmp($469,18072)|0);
  31206. $471 = ($470|0)!=(0);
  31207. if (!($471)) {
  31208. HEAP32[$1>>2] = 35;
  31209. break;
  31210. }
  31211. $472 = HEAP32[$3>>2]|0;
  31212. $473 = (_strcmp($472,18096)|0);
  31213. $474 = ($473|0)!=(0);
  31214. if (!($474)) {
  31215. HEAP32[$1>>2] = 1;
  31216. break;
  31217. }
  31218. $475 = HEAP32[$3>>2]|0;
  31219. $476 = (_strcmp($475,18109)|0);
  31220. $477 = ($476|0)!=(0);
  31221. if (!($477)) {
  31222. HEAP32[$1>>2] = 2;
  31223. break;
  31224. }
  31225. $478 = HEAP32[$3>>2]|0;
  31226. $479 = (_strcmp($478,18123)|0);
  31227. $480 = ($479|0)!=(0);
  31228. if (!($480)) {
  31229. HEAP32[$1>>2] = 36;
  31230. break;
  31231. }
  31232. $481 = HEAP32[$3>>2]|0;
  31233. $482 = (_strcmp($481,18145)|0);
  31234. $483 = ($482|0)!=(0);
  31235. if (!($483)) {
  31236. HEAP32[$1>>2] = 37;
  31237. break;
  31238. }
  31239. $484 = HEAP32[$3>>2]|0;
  31240. $485 = (_strcmp($484,18152)|0);
  31241. $486 = ($485|0)!=(0);
  31242. if (!($486)) {
  31243. HEAP32[$1>>2] = 3;
  31244. break;
  31245. }
  31246. $487 = HEAP32[$3>>2]|0;
  31247. $488 = (_strcmp($487,18168)|0);
  31248. $489 = ($488|0)!=(0);
  31249. if (!($489)) {
  31250. HEAP32[$1>>2] = 2;
  31251. break;
  31252. }
  31253. $490 = HEAP32[$3>>2]|0;
  31254. $491 = (_strcmp($490,18185)|0);
  31255. $492 = ($491|0)!=(0);
  31256. if (!($492)) {
  31257. HEAP32[$1>>2] = 1;
  31258. break;
  31259. }
  31260. $493 = HEAP32[$3>>2]|0;
  31261. $494 = (_strcmp($493,18202)|0);
  31262. $495 = ($494|0)!=(0);
  31263. if (!($495)) {
  31264. HEAP32[$1>>2] = 28;
  31265. break;
  31266. }
  31267. $496 = HEAP32[$3>>2]|0;
  31268. $497 = (_strcmp($496,18218)|0);
  31269. $498 = ($497|0)!=(0);
  31270. if (!($498)) {
  31271. HEAP32[$1>>2] = 1;
  31272. break;
  31273. }
  31274. $499 = HEAP32[$3>>2]|0;
  31275. $500 = (_strcmp($499,18234)|0);
  31276. $501 = ($500|0)!=(0);
  31277. if (!($501)) {
  31278. HEAP32[$1>>2] = 4;
  31279. break;
  31280. }
  31281. $502 = HEAP32[$3>>2]|0;
  31282. $503 = (_strcmp($502,18251)|0);
  31283. $504 = ($503|0)!=(0);
  31284. if (!($504)) {
  31285. HEAP32[$1>>2] = 29;
  31286. break;
  31287. }
  31288. $505 = HEAP32[$3>>2]|0;
  31289. $506 = (_strcmp($505,18265)|0);
  31290. $507 = ($506|0)!=(0);
  31291. if (!($507)) {
  31292. HEAP32[$1>>2] = 30;
  31293. break;
  31294. }
  31295. $508 = HEAP32[$3>>2]|0;
  31296. $509 = (_strcmp($508,18277)|0);
  31297. $510 = ($509|0)!=(0);
  31298. if (!($510)) {
  31299. HEAP32[$1>>2] = 22;
  31300. break;
  31301. }
  31302. $511 = HEAP32[$3>>2]|0;
  31303. $512 = (_strcmp($511,18288)|0);
  31304. $513 = ($512|0)!=(0);
  31305. if (!($513)) {
  31306. HEAP32[$1>>2] = 2;
  31307. break;
  31308. }
  31309. $514 = HEAP32[$3>>2]|0;
  31310. $515 = (_strcmp($514,18301)|0);
  31311. $516 = ($515|0)!=(0);
  31312. if (!($516)) {
  31313. HEAP32[$1>>2] = 23;
  31314. break;
  31315. }
  31316. $517 = HEAP32[$3>>2]|0;
  31317. $518 = (_strcmp($517,18311)|0);
  31318. $519 = ($518|0)!=(0);
  31319. if (!($519)) {
  31320. HEAP32[$1>>2] = 2;
  31321. break;
  31322. }
  31323. $520 = HEAP32[$3>>2]|0;
  31324. $521 = (_strcmp($520,18328)|0);
  31325. $522 = ($521|0)!=(0);
  31326. if (!($522)) {
  31327. HEAP32[$1>>2] = 24;
  31328. break;
  31329. }
  31330. $523 = HEAP32[$3>>2]|0;
  31331. $524 = (_strcmp($523,18340)|0);
  31332. $525 = ($524|0)!=(0);
  31333. if (!($525)) {
  31334. HEAP32[$1>>2] = 25;
  31335. break;
  31336. }
  31337. $526 = HEAP32[$3>>2]|0;
  31338. $527 = (_strcmp($526,18362)|0);
  31339. $528 = ($527|0)!=(0);
  31340. if (!($528)) {
  31341. HEAP32[$1>>2] = 26;
  31342. break;
  31343. }
  31344. $529 = HEAP32[$3>>2]|0;
  31345. $530 = (_strcmp($529,18382)|0);
  31346. $531 = ($530|0)!=(0);
  31347. if (!($531)) {
  31348. HEAP32[$1>>2] = 3;
  31349. break;
  31350. }
  31351. $532 = HEAP32[$3>>2]|0;
  31352. $533 = (_strcmp($532,18395)|0);
  31353. $534 = ($533|0)!=(0);
  31354. if (!($534)) {
  31355. HEAP32[$1>>2] = 27;
  31356. break;
  31357. }
  31358. $535 = HEAP32[$3>>2]|0;
  31359. $536 = (_strcmp($535,18417)|0);
  31360. $537 = ($536|0)!=(0);
  31361. if (!($537)) {
  31362. HEAP32[$1>>2] = 28;
  31363. break;
  31364. }
  31365. $538 = HEAP32[$3>>2]|0;
  31366. $539 = (_strcmp($538,18437)|0);
  31367. $540 = ($539|0)!=(0);
  31368. if (!($540)) {
  31369. HEAP32[$1>>2] = 2;
  31370. break;
  31371. }
  31372. $541 = HEAP32[$3>>2]|0;
  31373. $542 = (_strcmp($541,18454)|0);
  31374. $543 = ($542|0)!=(0);
  31375. if (!($543)) {
  31376. HEAP32[$1>>2] = 2;
  31377. break;
  31378. }
  31379. $544 = HEAP32[$3>>2]|0;
  31380. $545 = (_strcmp($544,18471)|0);
  31381. $546 = ($545|0)!=(0);
  31382. if (!($546)) {
  31383. HEAP32[$1>>2] = 3;
  31384. break;
  31385. }
  31386. $547 = HEAP32[$3>>2]|0;
  31387. $548 = (_strcmp($547,18491)|0);
  31388. $549 = ($548|0)!=(0);
  31389. if ($549) {
  31390. $550 = HEAP32[$2>>2]|0;
  31391. $551 = HEAP32[$3>>2]|0;
  31392. $552 = _emscripten_asm_const_iii(0, ($550|0), ($551|0))|0;
  31393. HEAP32[$1>>2] = 0;
  31394. break;
  31395. } else {
  31396. HEAP32[$1>>2] = 38;
  31397. break;
  31398. }
  31399. } else {
  31400. HEAP32[$1>>2] = 6;
  31401. }
  31402. } while(0);
  31403. $553 = HEAP32[$1>>2]|0;
  31404. STACKTOP = sp;return ($553|0);
  31405. }
  31406. function _emscripten_get_global_libc() {
  31407. var label = 0, sp = 0;
  31408. sp = STACKTOP;
  31409. return (23616|0);
  31410. }
  31411. function ___stdio_close($0) {
  31412. $0 = $0|0;
  31413. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $vararg_buffer = 0, label = 0, sp = 0;
  31414. sp = STACKTOP;
  31415. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  31416. $vararg_buffer = sp;
  31417. $1 = ((($0)) + 60|0);
  31418. $2 = HEAP32[$1>>2]|0;
  31419. $3 = (_dummy_738($2)|0);
  31420. HEAP32[$vararg_buffer>>2] = $3;
  31421. $4 = (___syscall6(6,($vararg_buffer|0))|0);
  31422. $5 = (___syscall_ret($4)|0);
  31423. STACKTOP = sp;return ($5|0);
  31424. }
  31425. function ___stdio_write($0,$1,$2) {
  31426. $0 = $0|0;
  31427. $1 = $1|0;
  31428. $2 = $2|0;
  31429. var $$0 = 0, $$04756 = 0, $$04855 = 0, $$04954 = 0, $$051 = 0, $$1 = 0, $$150 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0;
  31430. var $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0;
  31431. var $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, $vararg_buffer3 = 0, $vararg_ptr1 = 0, $vararg_ptr2 = 0, $vararg_ptr6 = 0;
  31432. var $vararg_ptr7 = 0, label = 0, sp = 0;
  31433. sp = STACKTOP;
  31434. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  31435. $vararg_buffer3 = sp + 16|0;
  31436. $vararg_buffer = sp;
  31437. $3 = sp + 32|0;
  31438. $4 = ((($0)) + 28|0);
  31439. $5 = HEAP32[$4>>2]|0;
  31440. HEAP32[$3>>2] = $5;
  31441. $6 = ((($3)) + 4|0);
  31442. $7 = ((($0)) + 20|0);
  31443. $8 = HEAP32[$7>>2]|0;
  31444. $9 = (($8) - ($5))|0;
  31445. HEAP32[$6>>2] = $9;
  31446. $10 = ((($3)) + 8|0);
  31447. HEAP32[$10>>2] = $1;
  31448. $11 = ((($3)) + 12|0);
  31449. HEAP32[$11>>2] = $2;
  31450. $12 = (($9) + ($2))|0;
  31451. $13 = ((($0)) + 60|0);
  31452. $14 = HEAP32[$13>>2]|0;
  31453. $15 = $3;
  31454. HEAP32[$vararg_buffer>>2] = $14;
  31455. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  31456. HEAP32[$vararg_ptr1>>2] = $15;
  31457. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  31458. HEAP32[$vararg_ptr2>>2] = 2;
  31459. $16 = (___syscall146(146,($vararg_buffer|0))|0);
  31460. $17 = (___syscall_ret($16)|0);
  31461. $18 = ($12|0)==($17|0);
  31462. L1: do {
  31463. if ($18) {
  31464. label = 3;
  31465. } else {
  31466. $$04756 = 2;$$04855 = $12;$$04954 = $3;$26 = $17;
  31467. while(1) {
  31468. $25 = ($26|0)<(0);
  31469. if ($25) {
  31470. break;
  31471. }
  31472. $34 = (($$04855) - ($26))|0;
  31473. $35 = ((($$04954)) + 4|0);
  31474. $36 = HEAP32[$35>>2]|0;
  31475. $37 = ($26>>>0)>($36>>>0);
  31476. $38 = ((($$04954)) + 8|0);
  31477. $$150 = $37 ? $38 : $$04954;
  31478. $39 = $37 << 31 >> 31;
  31479. $$1 = (($39) + ($$04756))|0;
  31480. $40 = $37 ? $36 : 0;
  31481. $$0 = (($26) - ($40))|0;
  31482. $41 = HEAP32[$$150>>2]|0;
  31483. $42 = (($41) + ($$0)|0);
  31484. HEAP32[$$150>>2] = $42;
  31485. $43 = ((($$150)) + 4|0);
  31486. $44 = HEAP32[$43>>2]|0;
  31487. $45 = (($44) - ($$0))|0;
  31488. HEAP32[$43>>2] = $45;
  31489. $46 = HEAP32[$13>>2]|0;
  31490. $47 = $$150;
  31491. HEAP32[$vararg_buffer3>>2] = $46;
  31492. $vararg_ptr6 = ((($vararg_buffer3)) + 4|0);
  31493. HEAP32[$vararg_ptr6>>2] = $47;
  31494. $vararg_ptr7 = ((($vararg_buffer3)) + 8|0);
  31495. HEAP32[$vararg_ptr7>>2] = $$1;
  31496. $48 = (___syscall146(146,($vararg_buffer3|0))|0);
  31497. $49 = (___syscall_ret($48)|0);
  31498. $50 = ($34|0)==($49|0);
  31499. if ($50) {
  31500. label = 3;
  31501. break L1;
  31502. } else {
  31503. $$04756 = $$1;$$04855 = $34;$$04954 = $$150;$26 = $49;
  31504. }
  31505. }
  31506. $27 = ((($0)) + 16|0);
  31507. HEAP32[$27>>2] = 0;
  31508. HEAP32[$4>>2] = 0;
  31509. HEAP32[$7>>2] = 0;
  31510. $28 = HEAP32[$0>>2]|0;
  31511. $29 = $28 | 32;
  31512. HEAP32[$0>>2] = $29;
  31513. $30 = ($$04756|0)==(2);
  31514. if ($30) {
  31515. $$051 = 0;
  31516. } else {
  31517. $31 = ((($$04954)) + 4|0);
  31518. $32 = HEAP32[$31>>2]|0;
  31519. $33 = (($2) - ($32))|0;
  31520. $$051 = $33;
  31521. }
  31522. }
  31523. } while(0);
  31524. if ((label|0) == 3) {
  31525. $19 = ((($0)) + 44|0);
  31526. $20 = HEAP32[$19>>2]|0;
  31527. $21 = ((($0)) + 48|0);
  31528. $22 = HEAP32[$21>>2]|0;
  31529. $23 = (($20) + ($22)|0);
  31530. $24 = ((($0)) + 16|0);
  31531. HEAP32[$24>>2] = $23;
  31532. HEAP32[$4>>2] = $20;
  31533. HEAP32[$7>>2] = $20;
  31534. $$051 = $2;
  31535. }
  31536. STACKTOP = sp;return ($$051|0);
  31537. }
  31538. function ___stdio_seek($0,$1,$2) {
  31539. $0 = $0|0;
  31540. $1 = $1|0;
  31541. $2 = $2|0;
  31542. var $$pre = 0, $10 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, $vararg_ptr1 = 0, $vararg_ptr2 = 0, $vararg_ptr3 = 0, $vararg_ptr4 = 0, label = 0, sp = 0;
  31543. sp = STACKTOP;
  31544. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  31545. $vararg_buffer = sp;
  31546. $3 = sp + 20|0;
  31547. $4 = ((($0)) + 60|0);
  31548. $5 = HEAP32[$4>>2]|0;
  31549. $6 = $3;
  31550. HEAP32[$vararg_buffer>>2] = $5;
  31551. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  31552. HEAP32[$vararg_ptr1>>2] = 0;
  31553. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  31554. HEAP32[$vararg_ptr2>>2] = $1;
  31555. $vararg_ptr3 = ((($vararg_buffer)) + 12|0);
  31556. HEAP32[$vararg_ptr3>>2] = $6;
  31557. $vararg_ptr4 = ((($vararg_buffer)) + 16|0);
  31558. HEAP32[$vararg_ptr4>>2] = $2;
  31559. $7 = (___syscall140(140,($vararg_buffer|0))|0);
  31560. $8 = (___syscall_ret($7)|0);
  31561. $9 = ($8|0)<(0);
  31562. if ($9) {
  31563. HEAP32[$3>>2] = -1;
  31564. $10 = -1;
  31565. } else {
  31566. $$pre = HEAP32[$3>>2]|0;
  31567. $10 = $$pre;
  31568. }
  31569. STACKTOP = sp;return ($10|0);
  31570. }
  31571. function ___syscall_ret($0) {
  31572. $0 = $0|0;
  31573. var $$0 = 0, $1 = 0, $2 = 0, $3 = 0, label = 0, sp = 0;
  31574. sp = STACKTOP;
  31575. $1 = ($0>>>0)>(4294963200);
  31576. if ($1) {
  31577. $2 = (0 - ($0))|0;
  31578. $3 = (___errno_location()|0);
  31579. HEAP32[$3>>2] = $2;
  31580. $$0 = -1;
  31581. } else {
  31582. $$0 = $0;
  31583. }
  31584. return ($$0|0);
  31585. }
  31586. function ___errno_location() {
  31587. var $0 = 0, $1 = 0, label = 0, sp = 0;
  31588. sp = STACKTOP;
  31589. $0 = (___pthread_self_108()|0);
  31590. $1 = ((($0)) + 64|0);
  31591. return ($1|0);
  31592. }
  31593. function ___pthread_self_108() {
  31594. var $0 = 0, label = 0, sp = 0;
  31595. sp = STACKTOP;
  31596. $0 = (_pthread_self()|0);
  31597. return ($0|0);
  31598. }
  31599. function _pthread_self() {
  31600. var label = 0, sp = 0;
  31601. sp = STACKTOP;
  31602. return (5108|0);
  31603. }
  31604. function _dummy_738($0) {
  31605. $0 = $0|0;
  31606. var label = 0, sp = 0;
  31607. sp = STACKTOP;
  31608. return ($0|0);
  31609. }
  31610. function ___stdio_read($0,$1,$2) {
  31611. $0 = $0|0;
  31612. $1 = $1|0;
  31613. $2 = $2|0;
  31614. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0;
  31615. var $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, $vararg_ptr1 = 0, $vararg_ptr2 = 0, label = 0, sp = 0;
  31616. sp = STACKTOP;
  31617. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  31618. $vararg_buffer = sp;
  31619. $3 = sp + 16|0;
  31620. HEAP32[$3>>2] = $1;
  31621. $4 = ((($3)) + 4|0);
  31622. $5 = ((($0)) + 48|0);
  31623. $6 = HEAP32[$5>>2]|0;
  31624. $7 = ($6|0)!=(0);
  31625. $8 = $7&1;
  31626. $9 = (($2) - ($8))|0;
  31627. HEAP32[$4>>2] = $9;
  31628. $10 = ((($3)) + 8|0);
  31629. $11 = ((($0)) + 44|0);
  31630. $12 = HEAP32[$11>>2]|0;
  31631. HEAP32[$10>>2] = $12;
  31632. $13 = ((($3)) + 12|0);
  31633. HEAP32[$13>>2] = $6;
  31634. $14 = ((($0)) + 60|0);
  31635. $15 = HEAP32[$14>>2]|0;
  31636. $16 = $3;
  31637. HEAP32[$vararg_buffer>>2] = $15;
  31638. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  31639. HEAP32[$vararg_ptr1>>2] = $16;
  31640. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  31641. HEAP32[$vararg_ptr2>>2] = 2;
  31642. $17 = (___syscall145(145,($vararg_buffer|0))|0);
  31643. $18 = (___syscall_ret($17)|0);
  31644. $19 = ($18|0)<(1);
  31645. if ($19) {
  31646. $20 = $18 & 48;
  31647. $21 = $20 ^ 16;
  31648. $22 = HEAP32[$0>>2]|0;
  31649. $23 = $22 | $21;
  31650. HEAP32[$0>>2] = $23;
  31651. $$0 = $18;
  31652. } else {
  31653. $24 = HEAP32[$4>>2]|0;
  31654. $25 = ($18>>>0)>($24>>>0);
  31655. if ($25) {
  31656. $26 = (($18) - ($24))|0;
  31657. $27 = HEAP32[$11>>2]|0;
  31658. $28 = ((($0)) + 4|0);
  31659. HEAP32[$28>>2] = $27;
  31660. $29 = (($27) + ($26)|0);
  31661. $30 = ((($0)) + 8|0);
  31662. HEAP32[$30>>2] = $29;
  31663. $31 = HEAP32[$5>>2]|0;
  31664. $32 = ($31|0)==(0);
  31665. if ($32) {
  31666. $$0 = $2;
  31667. } else {
  31668. $33 = ((($27)) + 1|0);
  31669. HEAP32[$28>>2] = $33;
  31670. $34 = HEAP8[$27>>0]|0;
  31671. $35 = (($2) + -1)|0;
  31672. $36 = (($1) + ($35)|0);
  31673. HEAP8[$36>>0] = $34;
  31674. $$0 = $2;
  31675. }
  31676. } else {
  31677. $$0 = $18;
  31678. }
  31679. }
  31680. STACKTOP = sp;return ($$0|0);
  31681. }
  31682. function ___stdout_write($0,$1,$2) {
  31683. $0 = $0|0;
  31684. $1 = $1|0;
  31685. $2 = $2|0;
  31686. var $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $vararg_buffer = 0, $vararg_ptr1 = 0, $vararg_ptr2 = 0, label = 0, sp = 0;
  31687. sp = STACKTOP;
  31688. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  31689. $vararg_buffer = sp;
  31690. $3 = sp + 16|0;
  31691. $4 = ((($0)) + 36|0);
  31692. HEAP32[$4>>2] = 9;
  31693. $5 = HEAP32[$0>>2]|0;
  31694. $6 = $5 & 64;
  31695. $7 = ($6|0)==(0);
  31696. if ($7) {
  31697. $8 = ((($0)) + 60|0);
  31698. $9 = HEAP32[$8>>2]|0;
  31699. $10 = $3;
  31700. HEAP32[$vararg_buffer>>2] = $9;
  31701. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  31702. HEAP32[$vararg_ptr1>>2] = 21523;
  31703. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  31704. HEAP32[$vararg_ptr2>>2] = $10;
  31705. $11 = (___syscall54(54,($vararg_buffer|0))|0);
  31706. $12 = ($11|0)==(0);
  31707. if (!($12)) {
  31708. $13 = ((($0)) + 75|0);
  31709. HEAP8[$13>>0] = -1;
  31710. }
  31711. }
  31712. $14 = (___stdio_write($0,$1,$2)|0);
  31713. STACKTOP = sp;return ($14|0);
  31714. }
  31715. function ___toread($0) {
  31716. $0 = $0|0;
  31717. var $$0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  31718. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $sext = 0, label = 0, sp = 0;
  31719. sp = STACKTOP;
  31720. $1 = ((($0)) + 74|0);
  31721. $2 = HEAP8[$1>>0]|0;
  31722. $3 = $2 << 24 >> 24;
  31723. $4 = (($3) + 255)|0;
  31724. $5 = $4 | $3;
  31725. $6 = $5&255;
  31726. HEAP8[$1>>0] = $6;
  31727. $7 = ((($0)) + 20|0);
  31728. $8 = HEAP32[$7>>2]|0;
  31729. $9 = ((($0)) + 28|0);
  31730. $10 = HEAP32[$9>>2]|0;
  31731. $11 = ($8>>>0)>($10>>>0);
  31732. if ($11) {
  31733. $12 = ((($0)) + 36|0);
  31734. $13 = HEAP32[$12>>2]|0;
  31735. (FUNCTION_TABLE_iiii[$13 & 15]($0,0,0)|0);
  31736. }
  31737. $14 = ((($0)) + 16|0);
  31738. HEAP32[$14>>2] = 0;
  31739. HEAP32[$9>>2] = 0;
  31740. HEAP32[$7>>2] = 0;
  31741. $15 = HEAP32[$0>>2]|0;
  31742. $16 = $15 & 4;
  31743. $17 = ($16|0)==(0);
  31744. if ($17) {
  31745. $19 = ((($0)) + 44|0);
  31746. $20 = HEAP32[$19>>2]|0;
  31747. $21 = ((($0)) + 48|0);
  31748. $22 = HEAP32[$21>>2]|0;
  31749. $23 = (($20) + ($22)|0);
  31750. $24 = ((($0)) + 8|0);
  31751. HEAP32[$24>>2] = $23;
  31752. $25 = ((($0)) + 4|0);
  31753. HEAP32[$25>>2] = $23;
  31754. $26 = $15 << 27;
  31755. $sext = $26 >> 31;
  31756. $$0 = $sext;
  31757. } else {
  31758. $18 = $15 | 32;
  31759. HEAP32[$0>>2] = $18;
  31760. $$0 = -1;
  31761. }
  31762. return ($$0|0);
  31763. }
  31764. function _strcmp($0,$1) {
  31765. $0 = $0|0;
  31766. $1 = $1|0;
  31767. var $$011 = 0, $$0710 = 0, $$lcssa = 0, $$lcssa8 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond9 = 0, label = 0;
  31768. var sp = 0;
  31769. sp = STACKTOP;
  31770. $2 = HEAP8[$0>>0]|0;
  31771. $3 = HEAP8[$1>>0]|0;
  31772. $4 = ($2<<24>>24)!=($3<<24>>24);
  31773. $5 = ($2<<24>>24)==(0);
  31774. $or$cond9 = $5 | $4;
  31775. if ($or$cond9) {
  31776. $$lcssa = $3;$$lcssa8 = $2;
  31777. } else {
  31778. $$011 = $1;$$0710 = $0;
  31779. while(1) {
  31780. $6 = ((($$0710)) + 1|0);
  31781. $7 = ((($$011)) + 1|0);
  31782. $8 = HEAP8[$6>>0]|0;
  31783. $9 = HEAP8[$7>>0]|0;
  31784. $10 = ($8<<24>>24)!=($9<<24>>24);
  31785. $11 = ($8<<24>>24)==(0);
  31786. $or$cond = $11 | $10;
  31787. if ($or$cond) {
  31788. $$lcssa = $9;$$lcssa8 = $8;
  31789. break;
  31790. } else {
  31791. $$011 = $7;$$0710 = $6;
  31792. }
  31793. }
  31794. }
  31795. $12 = $$lcssa8&255;
  31796. $13 = $$lcssa&255;
  31797. $14 = (($12) - ($13))|0;
  31798. return ($14|0);
  31799. }
  31800. function _memcmp($0,$1,$2) {
  31801. $0 = $0|0;
  31802. $1 = $1|0;
  31803. $2 = $2|0;
  31804. var $$01318 = 0, $$01417 = 0, $$019 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  31805. sp = STACKTOP;
  31806. $3 = ($2|0)==(0);
  31807. L1: do {
  31808. if ($3) {
  31809. $14 = 0;
  31810. } else {
  31811. $$01318 = $0;$$01417 = $2;$$019 = $1;
  31812. while(1) {
  31813. $4 = HEAP8[$$01318>>0]|0;
  31814. $5 = HEAP8[$$019>>0]|0;
  31815. $6 = ($4<<24>>24)==($5<<24>>24);
  31816. if (!($6)) {
  31817. break;
  31818. }
  31819. $7 = (($$01417) + -1)|0;
  31820. $8 = ((($$01318)) + 1|0);
  31821. $9 = ((($$019)) + 1|0);
  31822. $10 = ($7|0)==(0);
  31823. if ($10) {
  31824. $14 = 0;
  31825. break L1;
  31826. } else {
  31827. $$01318 = $8;$$01417 = $7;$$019 = $9;
  31828. }
  31829. }
  31830. $11 = $4&255;
  31831. $12 = $5&255;
  31832. $13 = (($11) - ($12))|0;
  31833. $14 = $13;
  31834. }
  31835. } while(0);
  31836. return ($14|0);
  31837. }
  31838. function _vfprintf($0,$1,$2) {
  31839. $0 = $0|0;
  31840. $1 = $1|0;
  31841. $2 = $2|0;
  31842. var $$ = 0, $$0 = 0, $$1 = 0, $$1$ = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  31843. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $5 = 0, $6 = 0, $7 = 0;
  31844. var $8 = 0, $9 = 0, $vacopy_currentptr = 0, dest = 0, label = 0, sp = 0, stop = 0;
  31845. sp = STACKTOP;
  31846. STACKTOP = STACKTOP + 224|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(224|0);
  31847. $3 = sp + 120|0;
  31848. $4 = sp + 80|0;
  31849. $5 = sp;
  31850. $6 = sp + 136|0;
  31851. dest=$4; stop=dest+40|0; do { HEAP32[dest>>2]=0|0; dest=dest+4|0; } while ((dest|0) < (stop|0));
  31852. $vacopy_currentptr = HEAP32[$2>>2]|0;
  31853. HEAP32[$3>>2] = $vacopy_currentptr;
  31854. $7 = (_printf_core(0,$1,$3,$5,$4)|0);
  31855. $8 = ($7|0)<(0);
  31856. if ($8) {
  31857. $$0 = -1;
  31858. } else {
  31859. $9 = ((($0)) + 76|0);
  31860. $10 = HEAP32[$9>>2]|0;
  31861. $11 = ($10|0)>(-1);
  31862. if ($11) {
  31863. $12 = (___lockfile($0)|0);
  31864. $40 = $12;
  31865. } else {
  31866. $40 = 0;
  31867. }
  31868. $13 = HEAP32[$0>>2]|0;
  31869. $14 = $13 & 32;
  31870. $15 = ((($0)) + 74|0);
  31871. $16 = HEAP8[$15>>0]|0;
  31872. $17 = ($16<<24>>24)<(1);
  31873. if ($17) {
  31874. $18 = $13 & -33;
  31875. HEAP32[$0>>2] = $18;
  31876. }
  31877. $19 = ((($0)) + 48|0);
  31878. $20 = HEAP32[$19>>2]|0;
  31879. $21 = ($20|0)==(0);
  31880. if ($21) {
  31881. $23 = ((($0)) + 44|0);
  31882. $24 = HEAP32[$23>>2]|0;
  31883. HEAP32[$23>>2] = $6;
  31884. $25 = ((($0)) + 28|0);
  31885. HEAP32[$25>>2] = $6;
  31886. $26 = ((($0)) + 20|0);
  31887. HEAP32[$26>>2] = $6;
  31888. HEAP32[$19>>2] = 80;
  31889. $27 = ((($6)) + 80|0);
  31890. $28 = ((($0)) + 16|0);
  31891. HEAP32[$28>>2] = $27;
  31892. $29 = (_printf_core($0,$1,$3,$5,$4)|0);
  31893. $30 = ($24|0)==(0|0);
  31894. if ($30) {
  31895. $$1 = $29;
  31896. } else {
  31897. $31 = ((($0)) + 36|0);
  31898. $32 = HEAP32[$31>>2]|0;
  31899. (FUNCTION_TABLE_iiii[$32 & 15]($0,0,0)|0);
  31900. $33 = HEAP32[$26>>2]|0;
  31901. $34 = ($33|0)==(0|0);
  31902. $$ = $34 ? -1 : $29;
  31903. HEAP32[$23>>2] = $24;
  31904. HEAP32[$19>>2] = 0;
  31905. HEAP32[$28>>2] = 0;
  31906. HEAP32[$25>>2] = 0;
  31907. HEAP32[$26>>2] = 0;
  31908. $$1 = $$;
  31909. }
  31910. } else {
  31911. $22 = (_printf_core($0,$1,$3,$5,$4)|0);
  31912. $$1 = $22;
  31913. }
  31914. $35 = HEAP32[$0>>2]|0;
  31915. $36 = $35 & 32;
  31916. $37 = ($36|0)==(0);
  31917. $$1$ = $37 ? $$1 : -1;
  31918. $38 = $35 | $14;
  31919. HEAP32[$0>>2] = $38;
  31920. $39 = ($40|0)==(0);
  31921. if (!($39)) {
  31922. ___unlockfile($0);
  31923. }
  31924. $$0 = $$1$;
  31925. }
  31926. STACKTOP = sp;return ($$0|0);
  31927. }
  31928. function _printf_core($0,$1,$2,$3,$4) {
  31929. $0 = $0|0;
  31930. $1 = $1|0;
  31931. $2 = $2|0;
  31932. $3 = $3|0;
  31933. $4 = $4|0;
  31934. var $$ = 0, $$$ = 0, $$$0259 = 0, $$$0262 = 0, $$$0269 = 0, $$$4266 = 0, $$$5 = 0, $$0 = 0, $$0228 = 0, $$0228$ = 0, $$0229322 = 0, $$0232 = 0, $$0235 = 0, $$0237 = 0, $$0240$lcssa = 0, $$0240$lcssa357 = 0, $$0240321 = 0, $$0243 = 0, $$0247 = 0, $$0249$lcssa = 0;
  31935. var $$0249306 = 0, $$0252 = 0, $$0253 = 0, $$0254 = 0, $$0254$$0254$ = 0, $$0259 = 0, $$0262$lcssa = 0, $$0262311 = 0, $$0269 = 0, $$0269$phi = 0, $$1 = 0, $$1230333 = 0, $$1233 = 0, $$1236 = 0, $$1238 = 0, $$1241332 = 0, $$1244320 = 0, $$1248 = 0, $$1250 = 0, $$1255 = 0;
  31936. var $$1260 = 0, $$1263 = 0, $$1263$ = 0, $$1270 = 0, $$2 = 0, $$2234 = 0, $$2239 = 0, $$2242305 = 0, $$2245 = 0, $$2251 = 0, $$2256 = 0, $$2256$ = 0, $$2256$$$2256 = 0, $$2261 = 0, $$2271 = 0, $$284$ = 0, $$289 = 0, $$290 = 0, $$3257 = 0, $$3265 = 0;
  31937. var $$3272 = 0, $$3303 = 0, $$377 = 0, $$4258355 = 0, $$4266 = 0, $$5 = 0, $$6268 = 0, $$lcssa295 = 0, $$pre = 0, $$pre346 = 0, $$pre347 = 0, $$pre347$pre = 0, $$pre349 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0;
  31938. var $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0;
  31939. var $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0;
  31940. var $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0;
  31941. var $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0;
  31942. var $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0;
  31943. var $197 = 0, $198 = 0, $199 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0;
  31944. var $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0, $22 = 0, $220 = 0, $221 = 0, $222 = 0, $223 = 0, $224 = 0, $225 = 0, $226 = 0, $227 = 0, $228 = 0, $229 = 0, $23 = 0, $230 = 0, $231 = 0, $232 = 0;
  31945. var $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0, $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0, $249 = 0, $25 = 0, $250 = 0;
  31946. var $251 = 0, $252 = 0, $253 = 0, $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0, $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0, $267 = 0, $268 = 0, $269 = 0;
  31947. var $27 = 0, $270 = 0, $271 = 0, $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0, $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0, $285 = 0, $286 = 0, $287 = 0;
  31948. var $288 = 0, $289 = 0, $29 = 0, $290 = 0, $291 = 0, $292 = 0, $293 = 0, $294 = 0, $295 = 0, $296 = 0, $297 = 0, $298 = 0, $299 = 0, $30 = 0, $300 = 0, $301 = 0, $302 = 0, $303 = 0, $304 = 0, $305 = 0;
  31949. var $306 = 0.0, $307 = 0, $308 = 0, $309 = 0, $31 = 0, $310 = 0, $311 = 0, $312 = 0, $313 = 0, $314 = 0, $315 = 0, $316 = 0, $317 = 0, $318 = 0, $319 = 0, $32 = 0, $320 = 0, $321 = 0, $322 = 0, $323 = 0;
  31950. var $324 = 0, $325 = 0, $326 = 0, $327 = 0, $328 = 0, $329 = 0, $33 = 0, $330 = 0, $331 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  31951. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0;
  31952. var $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0;
  31953. var $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0;
  31954. var $arglist_current = 0, $arglist_current2 = 0, $arglist_next = 0, $arglist_next3 = 0, $expanded = 0, $expanded10 = 0, $expanded11 = 0, $expanded13 = 0, $expanded14 = 0, $expanded15 = 0, $expanded4 = 0, $expanded6 = 0, $expanded7 = 0, $expanded8 = 0, $isdigit = 0, $isdigit275 = 0, $isdigit277 = 0, $isdigittmp = 0, $isdigittmp$ = 0, $isdigittmp274 = 0;
  31955. var $isdigittmp276 = 0, $narrow = 0, $or$cond = 0, $or$cond281 = 0, $or$cond283 = 0, $or$cond286 = 0, $storemerge = 0, $storemerge273310 = 0, $storemerge278 = 0, $trunc = 0, label = 0, sp = 0;
  31956. sp = STACKTOP;
  31957. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  31958. $5 = sp + 16|0;
  31959. $6 = sp;
  31960. $7 = sp + 24|0;
  31961. $8 = sp + 8|0;
  31962. $9 = sp + 20|0;
  31963. HEAP32[$5>>2] = $1;
  31964. $10 = ($0|0)!=(0|0);
  31965. $11 = ((($7)) + 40|0);
  31966. $12 = $11;
  31967. $13 = ((($7)) + 39|0);
  31968. $14 = ((($8)) + 4|0);
  31969. $$0243 = 0;$$0247 = 0;$$0269 = 0;$21 = $1;
  31970. L1: while(1) {
  31971. $15 = ($$0247|0)>(-1);
  31972. do {
  31973. if ($15) {
  31974. $16 = (2147483647 - ($$0247))|0;
  31975. $17 = ($$0243|0)>($16|0);
  31976. if ($17) {
  31977. $18 = (___errno_location()|0);
  31978. HEAP32[$18>>2] = 75;
  31979. $$1248 = -1;
  31980. break;
  31981. } else {
  31982. $19 = (($$0243) + ($$0247))|0;
  31983. $$1248 = $19;
  31984. break;
  31985. }
  31986. } else {
  31987. $$1248 = $$0247;
  31988. }
  31989. } while(0);
  31990. $20 = HEAP8[$21>>0]|0;
  31991. $22 = ($20<<24>>24)==(0);
  31992. if ($22) {
  31993. label = 87;
  31994. break;
  31995. } else {
  31996. $23 = $20;$25 = $21;
  31997. }
  31998. L9: while(1) {
  31999. switch ($23<<24>>24) {
  32000. case 37: {
  32001. $$0249306 = $25;$27 = $25;
  32002. label = 9;
  32003. break L9;
  32004. break;
  32005. }
  32006. case 0: {
  32007. $$0249$lcssa = $25;$39 = $25;
  32008. break L9;
  32009. break;
  32010. }
  32011. default: {
  32012. }
  32013. }
  32014. $24 = ((($25)) + 1|0);
  32015. HEAP32[$5>>2] = $24;
  32016. $$pre = HEAP8[$24>>0]|0;
  32017. $23 = $$pre;$25 = $24;
  32018. }
  32019. L12: do {
  32020. if ((label|0) == 9) {
  32021. while(1) {
  32022. label = 0;
  32023. $26 = ((($27)) + 1|0);
  32024. $28 = HEAP8[$26>>0]|0;
  32025. $29 = ($28<<24>>24)==(37);
  32026. if (!($29)) {
  32027. $$0249$lcssa = $$0249306;$39 = $27;
  32028. break L12;
  32029. }
  32030. $30 = ((($$0249306)) + 1|0);
  32031. $31 = ((($27)) + 2|0);
  32032. HEAP32[$5>>2] = $31;
  32033. $32 = HEAP8[$31>>0]|0;
  32034. $33 = ($32<<24>>24)==(37);
  32035. if ($33) {
  32036. $$0249306 = $30;$27 = $31;
  32037. label = 9;
  32038. } else {
  32039. $$0249$lcssa = $30;$39 = $31;
  32040. break;
  32041. }
  32042. }
  32043. }
  32044. } while(0);
  32045. $34 = $$0249$lcssa;
  32046. $35 = $21;
  32047. $36 = (($34) - ($35))|0;
  32048. if ($10) {
  32049. _out($0,$21,$36);
  32050. }
  32051. $37 = ($36|0)==(0);
  32052. if (!($37)) {
  32053. $$0269$phi = $$0269;$$0243 = $36;$$0247 = $$1248;$21 = $39;$$0269 = $$0269$phi;
  32054. continue;
  32055. }
  32056. $38 = ((($39)) + 1|0);
  32057. $40 = HEAP8[$38>>0]|0;
  32058. $41 = $40 << 24 >> 24;
  32059. $isdigittmp = (($41) + -48)|0;
  32060. $isdigit = ($isdigittmp>>>0)<(10);
  32061. if ($isdigit) {
  32062. $42 = ((($39)) + 2|0);
  32063. $43 = HEAP8[$42>>0]|0;
  32064. $44 = ($43<<24>>24)==(36);
  32065. $45 = ((($39)) + 3|0);
  32066. $$377 = $44 ? $45 : $38;
  32067. $$$0269 = $44 ? 1 : $$0269;
  32068. $isdigittmp$ = $44 ? $isdigittmp : -1;
  32069. $$0253 = $isdigittmp$;$$1270 = $$$0269;$storemerge = $$377;
  32070. } else {
  32071. $$0253 = -1;$$1270 = $$0269;$storemerge = $38;
  32072. }
  32073. HEAP32[$5>>2] = $storemerge;
  32074. $46 = HEAP8[$storemerge>>0]|0;
  32075. $47 = $46 << 24 >> 24;
  32076. $48 = (($47) + -32)|0;
  32077. $49 = ($48>>>0)<(32);
  32078. L24: do {
  32079. if ($49) {
  32080. $$0262311 = 0;$329 = $46;$51 = $48;$storemerge273310 = $storemerge;
  32081. while(1) {
  32082. $50 = 1 << $51;
  32083. $52 = $50 & 75913;
  32084. $53 = ($52|0)==(0);
  32085. if ($53) {
  32086. $$0262$lcssa = $$0262311;$$lcssa295 = $329;$62 = $storemerge273310;
  32087. break L24;
  32088. }
  32089. $54 = $50 | $$0262311;
  32090. $55 = ((($storemerge273310)) + 1|0);
  32091. HEAP32[$5>>2] = $55;
  32092. $56 = HEAP8[$55>>0]|0;
  32093. $57 = $56 << 24 >> 24;
  32094. $58 = (($57) + -32)|0;
  32095. $59 = ($58>>>0)<(32);
  32096. if ($59) {
  32097. $$0262311 = $54;$329 = $56;$51 = $58;$storemerge273310 = $55;
  32098. } else {
  32099. $$0262$lcssa = $54;$$lcssa295 = $56;$62 = $55;
  32100. break;
  32101. }
  32102. }
  32103. } else {
  32104. $$0262$lcssa = 0;$$lcssa295 = $46;$62 = $storemerge;
  32105. }
  32106. } while(0);
  32107. $60 = ($$lcssa295<<24>>24)==(42);
  32108. if ($60) {
  32109. $61 = ((($62)) + 1|0);
  32110. $63 = HEAP8[$61>>0]|0;
  32111. $64 = $63 << 24 >> 24;
  32112. $isdigittmp276 = (($64) + -48)|0;
  32113. $isdigit277 = ($isdigittmp276>>>0)<(10);
  32114. if ($isdigit277) {
  32115. $65 = ((($62)) + 2|0);
  32116. $66 = HEAP8[$65>>0]|0;
  32117. $67 = ($66<<24>>24)==(36);
  32118. if ($67) {
  32119. $68 = (($4) + ($isdigittmp276<<2)|0);
  32120. HEAP32[$68>>2] = 10;
  32121. $69 = HEAP8[$61>>0]|0;
  32122. $70 = $69 << 24 >> 24;
  32123. $71 = (($70) + -48)|0;
  32124. $72 = (($3) + ($71<<3)|0);
  32125. $73 = $72;
  32126. $74 = $73;
  32127. $75 = HEAP32[$74>>2]|0;
  32128. $76 = (($73) + 4)|0;
  32129. $77 = $76;
  32130. $78 = HEAP32[$77>>2]|0;
  32131. $79 = ((($62)) + 3|0);
  32132. $$0259 = $75;$$2271 = 1;$storemerge278 = $79;
  32133. } else {
  32134. label = 23;
  32135. }
  32136. } else {
  32137. label = 23;
  32138. }
  32139. if ((label|0) == 23) {
  32140. label = 0;
  32141. $80 = ($$1270|0)==(0);
  32142. if (!($80)) {
  32143. $$0 = -1;
  32144. break;
  32145. }
  32146. if ($10) {
  32147. $arglist_current = HEAP32[$2>>2]|0;
  32148. $81 = $arglist_current;
  32149. $82 = ((0) + 4|0);
  32150. $expanded4 = $82;
  32151. $expanded = (($expanded4) - 1)|0;
  32152. $83 = (($81) + ($expanded))|0;
  32153. $84 = ((0) + 4|0);
  32154. $expanded8 = $84;
  32155. $expanded7 = (($expanded8) - 1)|0;
  32156. $expanded6 = $expanded7 ^ -1;
  32157. $85 = $83 & $expanded6;
  32158. $86 = $85;
  32159. $87 = HEAP32[$86>>2]|0;
  32160. $arglist_next = ((($86)) + 4|0);
  32161. HEAP32[$2>>2] = $arglist_next;
  32162. $$0259 = $87;$$2271 = 0;$storemerge278 = $61;
  32163. } else {
  32164. $$0259 = 0;$$2271 = 0;$storemerge278 = $61;
  32165. }
  32166. }
  32167. HEAP32[$5>>2] = $storemerge278;
  32168. $88 = ($$0259|0)<(0);
  32169. $89 = $$0262$lcssa | 8192;
  32170. $90 = (0 - ($$0259))|0;
  32171. $$$0262 = $88 ? $89 : $$0262$lcssa;
  32172. $$$0259 = $88 ? $90 : $$0259;
  32173. $$1260 = $$$0259;$$1263 = $$$0262;$$3272 = $$2271;$94 = $storemerge278;
  32174. } else {
  32175. $91 = (_getint($5)|0);
  32176. $92 = ($91|0)<(0);
  32177. if ($92) {
  32178. $$0 = -1;
  32179. break;
  32180. }
  32181. $$pre346 = HEAP32[$5>>2]|0;
  32182. $$1260 = $91;$$1263 = $$0262$lcssa;$$3272 = $$1270;$94 = $$pre346;
  32183. }
  32184. $93 = HEAP8[$94>>0]|0;
  32185. $95 = ($93<<24>>24)==(46);
  32186. do {
  32187. if ($95) {
  32188. $96 = ((($94)) + 1|0);
  32189. $97 = HEAP8[$96>>0]|0;
  32190. $98 = ($97<<24>>24)==(42);
  32191. if (!($98)) {
  32192. $125 = ((($94)) + 1|0);
  32193. HEAP32[$5>>2] = $125;
  32194. $126 = (_getint($5)|0);
  32195. $$pre347$pre = HEAP32[$5>>2]|0;
  32196. $$0254 = $126;$$pre347 = $$pre347$pre;
  32197. break;
  32198. }
  32199. $99 = ((($94)) + 2|0);
  32200. $100 = HEAP8[$99>>0]|0;
  32201. $101 = $100 << 24 >> 24;
  32202. $isdigittmp274 = (($101) + -48)|0;
  32203. $isdigit275 = ($isdigittmp274>>>0)<(10);
  32204. if ($isdigit275) {
  32205. $102 = ((($94)) + 3|0);
  32206. $103 = HEAP8[$102>>0]|0;
  32207. $104 = ($103<<24>>24)==(36);
  32208. if ($104) {
  32209. $105 = (($4) + ($isdigittmp274<<2)|0);
  32210. HEAP32[$105>>2] = 10;
  32211. $106 = HEAP8[$99>>0]|0;
  32212. $107 = $106 << 24 >> 24;
  32213. $108 = (($107) + -48)|0;
  32214. $109 = (($3) + ($108<<3)|0);
  32215. $110 = $109;
  32216. $111 = $110;
  32217. $112 = HEAP32[$111>>2]|0;
  32218. $113 = (($110) + 4)|0;
  32219. $114 = $113;
  32220. $115 = HEAP32[$114>>2]|0;
  32221. $116 = ((($94)) + 4|0);
  32222. HEAP32[$5>>2] = $116;
  32223. $$0254 = $112;$$pre347 = $116;
  32224. break;
  32225. }
  32226. }
  32227. $117 = ($$3272|0)==(0);
  32228. if (!($117)) {
  32229. $$0 = -1;
  32230. break L1;
  32231. }
  32232. if ($10) {
  32233. $arglist_current2 = HEAP32[$2>>2]|0;
  32234. $118 = $arglist_current2;
  32235. $119 = ((0) + 4|0);
  32236. $expanded11 = $119;
  32237. $expanded10 = (($expanded11) - 1)|0;
  32238. $120 = (($118) + ($expanded10))|0;
  32239. $121 = ((0) + 4|0);
  32240. $expanded15 = $121;
  32241. $expanded14 = (($expanded15) - 1)|0;
  32242. $expanded13 = $expanded14 ^ -1;
  32243. $122 = $120 & $expanded13;
  32244. $123 = $122;
  32245. $124 = HEAP32[$123>>2]|0;
  32246. $arglist_next3 = ((($123)) + 4|0);
  32247. HEAP32[$2>>2] = $arglist_next3;
  32248. $330 = $124;
  32249. } else {
  32250. $330 = 0;
  32251. }
  32252. HEAP32[$5>>2] = $99;
  32253. $$0254 = $330;$$pre347 = $99;
  32254. } else {
  32255. $$0254 = -1;$$pre347 = $94;
  32256. }
  32257. } while(0);
  32258. $$0252 = 0;$128 = $$pre347;
  32259. while(1) {
  32260. $127 = HEAP8[$128>>0]|0;
  32261. $129 = $127 << 24 >> 24;
  32262. $130 = (($129) + -65)|0;
  32263. $131 = ($130>>>0)>(57);
  32264. if ($131) {
  32265. $$0 = -1;
  32266. break L1;
  32267. }
  32268. $132 = ((($128)) + 1|0);
  32269. HEAP32[$5>>2] = $132;
  32270. $133 = HEAP8[$128>>0]|0;
  32271. $134 = $133 << 24 >> 24;
  32272. $135 = (($134) + -65)|0;
  32273. $136 = ((18607 + (($$0252*58)|0)|0) + ($135)|0);
  32274. $137 = HEAP8[$136>>0]|0;
  32275. $138 = $137&255;
  32276. $139 = (($138) + -1)|0;
  32277. $140 = ($139>>>0)<(8);
  32278. if ($140) {
  32279. $$0252 = $138;$128 = $132;
  32280. } else {
  32281. break;
  32282. }
  32283. }
  32284. $141 = ($137<<24>>24)==(0);
  32285. if ($141) {
  32286. $$0 = -1;
  32287. break;
  32288. }
  32289. $142 = ($137<<24>>24)==(19);
  32290. $143 = ($$0253|0)>(-1);
  32291. do {
  32292. if ($142) {
  32293. if ($143) {
  32294. $$0 = -1;
  32295. break L1;
  32296. } else {
  32297. label = 49;
  32298. }
  32299. } else {
  32300. if ($143) {
  32301. $144 = (($4) + ($$0253<<2)|0);
  32302. HEAP32[$144>>2] = $138;
  32303. $145 = (($3) + ($$0253<<3)|0);
  32304. $146 = $145;
  32305. $147 = $146;
  32306. $148 = HEAP32[$147>>2]|0;
  32307. $149 = (($146) + 4)|0;
  32308. $150 = $149;
  32309. $151 = HEAP32[$150>>2]|0;
  32310. $152 = $6;
  32311. $153 = $152;
  32312. HEAP32[$153>>2] = $148;
  32313. $154 = (($152) + 4)|0;
  32314. $155 = $154;
  32315. HEAP32[$155>>2] = $151;
  32316. label = 49;
  32317. break;
  32318. }
  32319. if (!($10)) {
  32320. $$0 = 0;
  32321. break L1;
  32322. }
  32323. _pop_arg($6,$138,$2);
  32324. }
  32325. } while(0);
  32326. if ((label|0) == 49) {
  32327. label = 0;
  32328. if (!($10)) {
  32329. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32330. continue;
  32331. }
  32332. }
  32333. $156 = HEAP8[$128>>0]|0;
  32334. $157 = $156 << 24 >> 24;
  32335. $158 = ($$0252|0)!=(0);
  32336. $159 = $157 & 15;
  32337. $160 = ($159|0)==(3);
  32338. $or$cond281 = $158 & $160;
  32339. $161 = $157 & -33;
  32340. $$0235 = $or$cond281 ? $161 : $157;
  32341. $162 = $$1263 & 8192;
  32342. $163 = ($162|0)==(0);
  32343. $164 = $$1263 & -65537;
  32344. $$1263$ = $163 ? $$1263 : $164;
  32345. L71: do {
  32346. switch ($$0235|0) {
  32347. case 110: {
  32348. $trunc = $$0252&255;
  32349. switch ($trunc<<24>>24) {
  32350. case 0: {
  32351. $171 = HEAP32[$6>>2]|0;
  32352. HEAP32[$171>>2] = $$1248;
  32353. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32354. continue L1;
  32355. break;
  32356. }
  32357. case 1: {
  32358. $172 = HEAP32[$6>>2]|0;
  32359. HEAP32[$172>>2] = $$1248;
  32360. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32361. continue L1;
  32362. break;
  32363. }
  32364. case 2: {
  32365. $173 = ($$1248|0)<(0);
  32366. $174 = $173 << 31 >> 31;
  32367. $175 = HEAP32[$6>>2]|0;
  32368. $176 = $175;
  32369. $177 = $176;
  32370. HEAP32[$177>>2] = $$1248;
  32371. $178 = (($176) + 4)|0;
  32372. $179 = $178;
  32373. HEAP32[$179>>2] = $174;
  32374. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32375. continue L1;
  32376. break;
  32377. }
  32378. case 3: {
  32379. $180 = $$1248&65535;
  32380. $181 = HEAP32[$6>>2]|0;
  32381. HEAP16[$181>>1] = $180;
  32382. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32383. continue L1;
  32384. break;
  32385. }
  32386. case 4: {
  32387. $182 = $$1248&255;
  32388. $183 = HEAP32[$6>>2]|0;
  32389. HEAP8[$183>>0] = $182;
  32390. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32391. continue L1;
  32392. break;
  32393. }
  32394. case 6: {
  32395. $184 = HEAP32[$6>>2]|0;
  32396. HEAP32[$184>>2] = $$1248;
  32397. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32398. continue L1;
  32399. break;
  32400. }
  32401. case 7: {
  32402. $185 = ($$1248|0)<(0);
  32403. $186 = $185 << 31 >> 31;
  32404. $187 = HEAP32[$6>>2]|0;
  32405. $188 = $187;
  32406. $189 = $188;
  32407. HEAP32[$189>>2] = $$1248;
  32408. $190 = (($188) + 4)|0;
  32409. $191 = $190;
  32410. HEAP32[$191>>2] = $186;
  32411. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32412. continue L1;
  32413. break;
  32414. }
  32415. default: {
  32416. $$0243 = 0;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32417. continue L1;
  32418. }
  32419. }
  32420. break;
  32421. }
  32422. case 112: {
  32423. $192 = ($$0254>>>0)>(8);
  32424. $193 = $192 ? $$0254 : 8;
  32425. $194 = $$1263$ | 8;
  32426. $$1236 = 120;$$1255 = $193;$$3265 = $194;
  32427. label = 61;
  32428. break;
  32429. }
  32430. case 88: case 120: {
  32431. $$1236 = $$0235;$$1255 = $$0254;$$3265 = $$1263$;
  32432. label = 61;
  32433. break;
  32434. }
  32435. case 111: {
  32436. $210 = $6;
  32437. $211 = $210;
  32438. $212 = HEAP32[$211>>2]|0;
  32439. $213 = (($210) + 4)|0;
  32440. $214 = $213;
  32441. $215 = HEAP32[$214>>2]|0;
  32442. $216 = (_fmt_o($212,$215,$11)|0);
  32443. $217 = $$1263$ & 8;
  32444. $218 = ($217|0)==(0);
  32445. $219 = $216;
  32446. $220 = (($12) - ($219))|0;
  32447. $221 = ($$0254|0)>($220|0);
  32448. $222 = (($220) + 1)|0;
  32449. $223 = $218 | $221;
  32450. $$0254$$0254$ = $223 ? $$0254 : $222;
  32451. $$0228 = $216;$$1233 = 0;$$1238 = 19071;$$2256 = $$0254$$0254$;$$4266 = $$1263$;$248 = $212;$250 = $215;
  32452. label = 67;
  32453. break;
  32454. }
  32455. case 105: case 100: {
  32456. $224 = $6;
  32457. $225 = $224;
  32458. $226 = HEAP32[$225>>2]|0;
  32459. $227 = (($224) + 4)|0;
  32460. $228 = $227;
  32461. $229 = HEAP32[$228>>2]|0;
  32462. $230 = ($229|0)<(0);
  32463. if ($230) {
  32464. $231 = (_i64Subtract(0,0,($226|0),($229|0))|0);
  32465. $232 = tempRet0;
  32466. $233 = $6;
  32467. $234 = $233;
  32468. HEAP32[$234>>2] = $231;
  32469. $235 = (($233) + 4)|0;
  32470. $236 = $235;
  32471. HEAP32[$236>>2] = $232;
  32472. $$0232 = 1;$$0237 = 19071;$242 = $231;$243 = $232;
  32473. label = 66;
  32474. break L71;
  32475. } else {
  32476. $237 = $$1263$ & 2048;
  32477. $238 = ($237|0)==(0);
  32478. $239 = $$1263$ & 1;
  32479. $240 = ($239|0)==(0);
  32480. $$ = $240 ? 19071 : (19073);
  32481. $$$ = $238 ? $$ : (19072);
  32482. $241 = $$1263$ & 2049;
  32483. $narrow = ($241|0)!=(0);
  32484. $$284$ = $narrow&1;
  32485. $$0232 = $$284$;$$0237 = $$$;$242 = $226;$243 = $229;
  32486. label = 66;
  32487. break L71;
  32488. }
  32489. break;
  32490. }
  32491. case 117: {
  32492. $165 = $6;
  32493. $166 = $165;
  32494. $167 = HEAP32[$166>>2]|0;
  32495. $168 = (($165) + 4)|0;
  32496. $169 = $168;
  32497. $170 = HEAP32[$169>>2]|0;
  32498. $$0232 = 0;$$0237 = 19071;$242 = $167;$243 = $170;
  32499. label = 66;
  32500. break;
  32501. }
  32502. case 99: {
  32503. $259 = $6;
  32504. $260 = $259;
  32505. $261 = HEAP32[$260>>2]|0;
  32506. $262 = (($259) + 4)|0;
  32507. $263 = $262;
  32508. $264 = HEAP32[$263>>2]|0;
  32509. $265 = $261&255;
  32510. HEAP8[$13>>0] = $265;
  32511. $$2 = $13;$$2234 = 0;$$2239 = 19071;$$2251 = $11;$$5 = 1;$$6268 = $164;
  32512. break;
  32513. }
  32514. case 109: {
  32515. $266 = (___errno_location()|0);
  32516. $267 = HEAP32[$266>>2]|0;
  32517. $268 = (_strerror($267)|0);
  32518. $$1 = $268;
  32519. label = 71;
  32520. break;
  32521. }
  32522. case 115: {
  32523. $269 = HEAP32[$6>>2]|0;
  32524. $270 = ($269|0)!=(0|0);
  32525. $271 = $270 ? $269 : 19081;
  32526. $$1 = $271;
  32527. label = 71;
  32528. break;
  32529. }
  32530. case 67: {
  32531. $278 = $6;
  32532. $279 = $278;
  32533. $280 = HEAP32[$279>>2]|0;
  32534. $281 = (($278) + 4)|0;
  32535. $282 = $281;
  32536. $283 = HEAP32[$282>>2]|0;
  32537. HEAP32[$8>>2] = $280;
  32538. HEAP32[$14>>2] = 0;
  32539. HEAP32[$6>>2] = $8;
  32540. $$4258355 = -1;$331 = $8;
  32541. label = 75;
  32542. break;
  32543. }
  32544. case 83: {
  32545. $$pre349 = HEAP32[$6>>2]|0;
  32546. $284 = ($$0254|0)==(0);
  32547. if ($284) {
  32548. _pad_674($0,32,$$1260,0,$$1263$);
  32549. $$0240$lcssa357 = 0;
  32550. label = 84;
  32551. } else {
  32552. $$4258355 = $$0254;$331 = $$pre349;
  32553. label = 75;
  32554. }
  32555. break;
  32556. }
  32557. case 65: case 71: case 70: case 69: case 97: case 103: case 102: case 101: {
  32558. $306 = +HEAPF64[$6>>3];
  32559. $307 = (_fmt_fp($0,$306,$$1260,$$0254,$$1263$,$$0235)|0);
  32560. $$0243 = $307;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32561. continue L1;
  32562. break;
  32563. }
  32564. default: {
  32565. $$2 = $21;$$2234 = 0;$$2239 = 19071;$$2251 = $11;$$5 = $$0254;$$6268 = $$1263$;
  32566. }
  32567. }
  32568. } while(0);
  32569. L95: do {
  32570. if ((label|0) == 61) {
  32571. label = 0;
  32572. $195 = $6;
  32573. $196 = $195;
  32574. $197 = HEAP32[$196>>2]|0;
  32575. $198 = (($195) + 4)|0;
  32576. $199 = $198;
  32577. $200 = HEAP32[$199>>2]|0;
  32578. $201 = $$1236 & 32;
  32579. $202 = (_fmt_x($197,$200,$11,$201)|0);
  32580. $203 = ($197|0)==(0);
  32581. $204 = ($200|0)==(0);
  32582. $205 = $203 & $204;
  32583. $206 = $$3265 & 8;
  32584. $207 = ($206|0)==(0);
  32585. $or$cond283 = $207 | $205;
  32586. $208 = $$1236 >> 4;
  32587. $209 = (19071 + ($208)|0);
  32588. $$289 = $or$cond283 ? 19071 : $209;
  32589. $$290 = $or$cond283 ? 0 : 2;
  32590. $$0228 = $202;$$1233 = $$290;$$1238 = $$289;$$2256 = $$1255;$$4266 = $$3265;$248 = $197;$250 = $200;
  32591. label = 67;
  32592. }
  32593. else if ((label|0) == 66) {
  32594. label = 0;
  32595. $244 = (_fmt_u($242,$243,$11)|0);
  32596. $$0228 = $244;$$1233 = $$0232;$$1238 = $$0237;$$2256 = $$0254;$$4266 = $$1263$;$248 = $242;$250 = $243;
  32597. label = 67;
  32598. }
  32599. else if ((label|0) == 71) {
  32600. label = 0;
  32601. $272 = (_memchr($$1,0,$$0254)|0);
  32602. $273 = ($272|0)==(0|0);
  32603. $274 = $272;
  32604. $275 = $$1;
  32605. $276 = (($274) - ($275))|0;
  32606. $277 = (($$1) + ($$0254)|0);
  32607. $$3257 = $273 ? $$0254 : $276;
  32608. $$1250 = $273 ? $277 : $272;
  32609. $$2 = $$1;$$2234 = 0;$$2239 = 19071;$$2251 = $$1250;$$5 = $$3257;$$6268 = $164;
  32610. }
  32611. else if ((label|0) == 75) {
  32612. label = 0;
  32613. $$0229322 = $331;$$0240321 = 0;$$1244320 = 0;
  32614. while(1) {
  32615. $285 = HEAP32[$$0229322>>2]|0;
  32616. $286 = ($285|0)==(0);
  32617. if ($286) {
  32618. $$0240$lcssa = $$0240321;$$2245 = $$1244320;
  32619. break;
  32620. }
  32621. $287 = (_wctomb($9,$285)|0);
  32622. $288 = ($287|0)<(0);
  32623. $289 = (($$4258355) - ($$0240321))|0;
  32624. $290 = ($287>>>0)>($289>>>0);
  32625. $or$cond286 = $288 | $290;
  32626. if ($or$cond286) {
  32627. $$0240$lcssa = $$0240321;$$2245 = $287;
  32628. break;
  32629. }
  32630. $291 = ((($$0229322)) + 4|0);
  32631. $292 = (($287) + ($$0240321))|0;
  32632. $293 = ($$4258355>>>0)>($292>>>0);
  32633. if ($293) {
  32634. $$0229322 = $291;$$0240321 = $292;$$1244320 = $287;
  32635. } else {
  32636. $$0240$lcssa = $292;$$2245 = $287;
  32637. break;
  32638. }
  32639. }
  32640. $294 = ($$2245|0)<(0);
  32641. if ($294) {
  32642. $$0 = -1;
  32643. break L1;
  32644. }
  32645. _pad_674($0,32,$$1260,$$0240$lcssa,$$1263$);
  32646. $295 = ($$0240$lcssa|0)==(0);
  32647. if ($295) {
  32648. $$0240$lcssa357 = 0;
  32649. label = 84;
  32650. } else {
  32651. $$1230333 = $331;$$1241332 = 0;
  32652. while(1) {
  32653. $296 = HEAP32[$$1230333>>2]|0;
  32654. $297 = ($296|0)==(0);
  32655. if ($297) {
  32656. $$0240$lcssa357 = $$0240$lcssa;
  32657. label = 84;
  32658. break L95;
  32659. }
  32660. $298 = (_wctomb($9,$296)|0);
  32661. $299 = (($298) + ($$1241332))|0;
  32662. $300 = ($299|0)>($$0240$lcssa|0);
  32663. if ($300) {
  32664. $$0240$lcssa357 = $$0240$lcssa;
  32665. label = 84;
  32666. break L95;
  32667. }
  32668. $301 = ((($$1230333)) + 4|0);
  32669. _out($0,$9,$298);
  32670. $302 = ($299>>>0)<($$0240$lcssa>>>0);
  32671. if ($302) {
  32672. $$1230333 = $301;$$1241332 = $299;
  32673. } else {
  32674. $$0240$lcssa357 = $$0240$lcssa;
  32675. label = 84;
  32676. break;
  32677. }
  32678. }
  32679. }
  32680. }
  32681. } while(0);
  32682. if ((label|0) == 67) {
  32683. label = 0;
  32684. $245 = ($$2256|0)>(-1);
  32685. $246 = $$4266 & -65537;
  32686. $$$4266 = $245 ? $246 : $$4266;
  32687. $247 = ($248|0)!=(0);
  32688. $249 = ($250|0)!=(0);
  32689. $251 = $247 | $249;
  32690. $252 = ($$2256|0)!=(0);
  32691. $or$cond = $252 | $251;
  32692. $253 = $$0228;
  32693. $254 = (($12) - ($253))|0;
  32694. $255 = $251 ^ 1;
  32695. $256 = $255&1;
  32696. $257 = (($256) + ($254))|0;
  32697. $258 = ($$2256|0)>($257|0);
  32698. $$2256$ = $258 ? $$2256 : $257;
  32699. $$2256$$$2256 = $or$cond ? $$2256$ : $$2256;
  32700. $$0228$ = $or$cond ? $$0228 : $11;
  32701. $$2 = $$0228$;$$2234 = $$1233;$$2239 = $$1238;$$2251 = $11;$$5 = $$2256$$$2256;$$6268 = $$$4266;
  32702. }
  32703. else if ((label|0) == 84) {
  32704. label = 0;
  32705. $303 = $$1263$ ^ 8192;
  32706. _pad_674($0,32,$$1260,$$0240$lcssa357,$303);
  32707. $304 = ($$1260|0)>($$0240$lcssa357|0);
  32708. $305 = $304 ? $$1260 : $$0240$lcssa357;
  32709. $$0243 = $305;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32710. continue;
  32711. }
  32712. $308 = $$2251;
  32713. $309 = $$2;
  32714. $310 = (($308) - ($309))|0;
  32715. $311 = ($$5|0)<($310|0);
  32716. $$$5 = $311 ? $310 : $$5;
  32717. $312 = (($$$5) + ($$2234))|0;
  32718. $313 = ($$1260|0)<($312|0);
  32719. $$2261 = $313 ? $312 : $$1260;
  32720. _pad_674($0,32,$$2261,$312,$$6268);
  32721. _out($0,$$2239,$$2234);
  32722. $314 = $$6268 ^ 65536;
  32723. _pad_674($0,48,$$2261,$312,$314);
  32724. _pad_674($0,48,$$$5,$310,0);
  32725. _out($0,$$2,$310);
  32726. $315 = $$6268 ^ 8192;
  32727. _pad_674($0,32,$$2261,$312,$315);
  32728. $$0243 = $$2261;$$0247 = $$1248;$$0269 = $$3272;$21 = $132;
  32729. }
  32730. L114: do {
  32731. if ((label|0) == 87) {
  32732. $316 = ($0|0)==(0|0);
  32733. if ($316) {
  32734. $317 = ($$0269|0)==(0);
  32735. if ($317) {
  32736. $$0 = 0;
  32737. } else {
  32738. $$2242305 = 1;
  32739. while(1) {
  32740. $318 = (($4) + ($$2242305<<2)|0);
  32741. $319 = HEAP32[$318>>2]|0;
  32742. $320 = ($319|0)==(0);
  32743. if ($320) {
  32744. $$3303 = $$2242305;
  32745. break;
  32746. }
  32747. $321 = (($3) + ($$2242305<<3)|0);
  32748. _pop_arg($321,$319,$2);
  32749. $322 = (($$2242305) + 1)|0;
  32750. $323 = ($322|0)<(10);
  32751. if ($323) {
  32752. $$2242305 = $322;
  32753. } else {
  32754. $$0 = 1;
  32755. break L114;
  32756. }
  32757. }
  32758. while(1) {
  32759. $326 = (($4) + ($$3303<<2)|0);
  32760. $327 = HEAP32[$326>>2]|0;
  32761. $328 = ($327|0)==(0);
  32762. $325 = (($$3303) + 1)|0;
  32763. if (!($328)) {
  32764. $$0 = -1;
  32765. break L114;
  32766. }
  32767. $324 = ($325|0)<(10);
  32768. if ($324) {
  32769. $$3303 = $325;
  32770. } else {
  32771. $$0 = 1;
  32772. break;
  32773. }
  32774. }
  32775. }
  32776. } else {
  32777. $$0 = $$1248;
  32778. }
  32779. }
  32780. } while(0);
  32781. STACKTOP = sp;return ($$0|0);
  32782. }
  32783. function ___lockfile($0) {
  32784. $0 = $0|0;
  32785. var label = 0, sp = 0;
  32786. sp = STACKTOP;
  32787. return 0;
  32788. }
  32789. function ___unlockfile($0) {
  32790. $0 = $0|0;
  32791. var label = 0, sp = 0;
  32792. sp = STACKTOP;
  32793. return;
  32794. }
  32795. function _out($0,$1,$2) {
  32796. $0 = $0|0;
  32797. $1 = $1|0;
  32798. $2 = $2|0;
  32799. var $3 = 0, $4 = 0, $5 = 0, label = 0, sp = 0;
  32800. sp = STACKTOP;
  32801. $3 = HEAP32[$0>>2]|0;
  32802. $4 = $3 & 32;
  32803. $5 = ($4|0)==(0);
  32804. if ($5) {
  32805. (___fwritex($1,$2,$0)|0);
  32806. }
  32807. return;
  32808. }
  32809. function _getint($0) {
  32810. $0 = $0|0;
  32811. var $$0$lcssa = 0, $$06 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $isdigit = 0, $isdigit5 = 0, $isdigittmp = 0, $isdigittmp4 = 0, $isdigittmp7 = 0, label = 0, sp = 0;
  32812. sp = STACKTOP;
  32813. $1 = HEAP32[$0>>2]|0;
  32814. $2 = HEAP8[$1>>0]|0;
  32815. $3 = $2 << 24 >> 24;
  32816. $isdigittmp4 = (($3) + -48)|0;
  32817. $isdigit5 = ($isdigittmp4>>>0)<(10);
  32818. if ($isdigit5) {
  32819. $$06 = 0;$7 = $1;$isdigittmp7 = $isdigittmp4;
  32820. while(1) {
  32821. $4 = ($$06*10)|0;
  32822. $5 = (($isdigittmp7) + ($4))|0;
  32823. $6 = ((($7)) + 1|0);
  32824. HEAP32[$0>>2] = $6;
  32825. $8 = HEAP8[$6>>0]|0;
  32826. $9 = $8 << 24 >> 24;
  32827. $isdigittmp = (($9) + -48)|0;
  32828. $isdigit = ($isdigittmp>>>0)<(10);
  32829. if ($isdigit) {
  32830. $$06 = $5;$7 = $6;$isdigittmp7 = $isdigittmp;
  32831. } else {
  32832. $$0$lcssa = $5;
  32833. break;
  32834. }
  32835. }
  32836. } else {
  32837. $$0$lcssa = 0;
  32838. }
  32839. return ($$0$lcssa|0);
  32840. }
  32841. function _pop_arg($0,$1,$2) {
  32842. $0 = $0|0;
  32843. $1 = $1|0;
  32844. $2 = $2|0;
  32845. var $$mask = 0, $$mask31 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0.0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0;
  32846. var $116 = 0.0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0;
  32847. var $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0;
  32848. var $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0;
  32849. var $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0;
  32850. var $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $arglist_current = 0, $arglist_current11 = 0, $arglist_current14 = 0, $arglist_current17 = 0;
  32851. var $arglist_current2 = 0, $arglist_current20 = 0, $arglist_current23 = 0, $arglist_current26 = 0, $arglist_current5 = 0, $arglist_current8 = 0, $arglist_next = 0, $arglist_next12 = 0, $arglist_next15 = 0, $arglist_next18 = 0, $arglist_next21 = 0, $arglist_next24 = 0, $arglist_next27 = 0, $arglist_next3 = 0, $arglist_next6 = 0, $arglist_next9 = 0, $expanded = 0, $expanded28 = 0, $expanded30 = 0, $expanded31 = 0;
  32852. var $expanded32 = 0, $expanded34 = 0, $expanded35 = 0, $expanded37 = 0, $expanded38 = 0, $expanded39 = 0, $expanded41 = 0, $expanded42 = 0, $expanded44 = 0, $expanded45 = 0, $expanded46 = 0, $expanded48 = 0, $expanded49 = 0, $expanded51 = 0, $expanded52 = 0, $expanded53 = 0, $expanded55 = 0, $expanded56 = 0, $expanded58 = 0, $expanded59 = 0;
  32853. var $expanded60 = 0, $expanded62 = 0, $expanded63 = 0, $expanded65 = 0, $expanded66 = 0, $expanded67 = 0, $expanded69 = 0, $expanded70 = 0, $expanded72 = 0, $expanded73 = 0, $expanded74 = 0, $expanded76 = 0, $expanded77 = 0, $expanded79 = 0, $expanded80 = 0, $expanded81 = 0, $expanded83 = 0, $expanded84 = 0, $expanded86 = 0, $expanded87 = 0;
  32854. var $expanded88 = 0, $expanded90 = 0, $expanded91 = 0, $expanded93 = 0, $expanded94 = 0, $expanded95 = 0, label = 0, sp = 0;
  32855. sp = STACKTOP;
  32856. $3 = ($1>>>0)>(20);
  32857. L1: do {
  32858. if (!($3)) {
  32859. do {
  32860. switch ($1|0) {
  32861. case 9: {
  32862. $arglist_current = HEAP32[$2>>2]|0;
  32863. $4 = $arglist_current;
  32864. $5 = ((0) + 4|0);
  32865. $expanded28 = $5;
  32866. $expanded = (($expanded28) - 1)|0;
  32867. $6 = (($4) + ($expanded))|0;
  32868. $7 = ((0) + 4|0);
  32869. $expanded32 = $7;
  32870. $expanded31 = (($expanded32) - 1)|0;
  32871. $expanded30 = $expanded31 ^ -1;
  32872. $8 = $6 & $expanded30;
  32873. $9 = $8;
  32874. $10 = HEAP32[$9>>2]|0;
  32875. $arglist_next = ((($9)) + 4|0);
  32876. HEAP32[$2>>2] = $arglist_next;
  32877. HEAP32[$0>>2] = $10;
  32878. break L1;
  32879. break;
  32880. }
  32881. case 10: {
  32882. $arglist_current2 = HEAP32[$2>>2]|0;
  32883. $11 = $arglist_current2;
  32884. $12 = ((0) + 4|0);
  32885. $expanded35 = $12;
  32886. $expanded34 = (($expanded35) - 1)|0;
  32887. $13 = (($11) + ($expanded34))|0;
  32888. $14 = ((0) + 4|0);
  32889. $expanded39 = $14;
  32890. $expanded38 = (($expanded39) - 1)|0;
  32891. $expanded37 = $expanded38 ^ -1;
  32892. $15 = $13 & $expanded37;
  32893. $16 = $15;
  32894. $17 = HEAP32[$16>>2]|0;
  32895. $arglist_next3 = ((($16)) + 4|0);
  32896. HEAP32[$2>>2] = $arglist_next3;
  32897. $18 = ($17|0)<(0);
  32898. $19 = $18 << 31 >> 31;
  32899. $20 = $0;
  32900. $21 = $20;
  32901. HEAP32[$21>>2] = $17;
  32902. $22 = (($20) + 4)|0;
  32903. $23 = $22;
  32904. HEAP32[$23>>2] = $19;
  32905. break L1;
  32906. break;
  32907. }
  32908. case 11: {
  32909. $arglist_current5 = HEAP32[$2>>2]|0;
  32910. $24 = $arglist_current5;
  32911. $25 = ((0) + 4|0);
  32912. $expanded42 = $25;
  32913. $expanded41 = (($expanded42) - 1)|0;
  32914. $26 = (($24) + ($expanded41))|0;
  32915. $27 = ((0) + 4|0);
  32916. $expanded46 = $27;
  32917. $expanded45 = (($expanded46) - 1)|0;
  32918. $expanded44 = $expanded45 ^ -1;
  32919. $28 = $26 & $expanded44;
  32920. $29 = $28;
  32921. $30 = HEAP32[$29>>2]|0;
  32922. $arglist_next6 = ((($29)) + 4|0);
  32923. HEAP32[$2>>2] = $arglist_next6;
  32924. $31 = $0;
  32925. $32 = $31;
  32926. HEAP32[$32>>2] = $30;
  32927. $33 = (($31) + 4)|0;
  32928. $34 = $33;
  32929. HEAP32[$34>>2] = 0;
  32930. break L1;
  32931. break;
  32932. }
  32933. case 12: {
  32934. $arglist_current8 = HEAP32[$2>>2]|0;
  32935. $35 = $arglist_current8;
  32936. $36 = ((0) + 8|0);
  32937. $expanded49 = $36;
  32938. $expanded48 = (($expanded49) - 1)|0;
  32939. $37 = (($35) + ($expanded48))|0;
  32940. $38 = ((0) + 8|0);
  32941. $expanded53 = $38;
  32942. $expanded52 = (($expanded53) - 1)|0;
  32943. $expanded51 = $expanded52 ^ -1;
  32944. $39 = $37 & $expanded51;
  32945. $40 = $39;
  32946. $41 = $40;
  32947. $42 = $41;
  32948. $43 = HEAP32[$42>>2]|0;
  32949. $44 = (($41) + 4)|0;
  32950. $45 = $44;
  32951. $46 = HEAP32[$45>>2]|0;
  32952. $arglist_next9 = ((($40)) + 8|0);
  32953. HEAP32[$2>>2] = $arglist_next9;
  32954. $47 = $0;
  32955. $48 = $47;
  32956. HEAP32[$48>>2] = $43;
  32957. $49 = (($47) + 4)|0;
  32958. $50 = $49;
  32959. HEAP32[$50>>2] = $46;
  32960. break L1;
  32961. break;
  32962. }
  32963. case 13: {
  32964. $arglist_current11 = HEAP32[$2>>2]|0;
  32965. $51 = $arglist_current11;
  32966. $52 = ((0) + 4|0);
  32967. $expanded56 = $52;
  32968. $expanded55 = (($expanded56) - 1)|0;
  32969. $53 = (($51) + ($expanded55))|0;
  32970. $54 = ((0) + 4|0);
  32971. $expanded60 = $54;
  32972. $expanded59 = (($expanded60) - 1)|0;
  32973. $expanded58 = $expanded59 ^ -1;
  32974. $55 = $53 & $expanded58;
  32975. $56 = $55;
  32976. $57 = HEAP32[$56>>2]|0;
  32977. $arglist_next12 = ((($56)) + 4|0);
  32978. HEAP32[$2>>2] = $arglist_next12;
  32979. $58 = $57&65535;
  32980. $59 = $58 << 16 >> 16;
  32981. $60 = ($59|0)<(0);
  32982. $61 = $60 << 31 >> 31;
  32983. $62 = $0;
  32984. $63 = $62;
  32985. HEAP32[$63>>2] = $59;
  32986. $64 = (($62) + 4)|0;
  32987. $65 = $64;
  32988. HEAP32[$65>>2] = $61;
  32989. break L1;
  32990. break;
  32991. }
  32992. case 14: {
  32993. $arglist_current14 = HEAP32[$2>>2]|0;
  32994. $66 = $arglist_current14;
  32995. $67 = ((0) + 4|0);
  32996. $expanded63 = $67;
  32997. $expanded62 = (($expanded63) - 1)|0;
  32998. $68 = (($66) + ($expanded62))|0;
  32999. $69 = ((0) + 4|0);
  33000. $expanded67 = $69;
  33001. $expanded66 = (($expanded67) - 1)|0;
  33002. $expanded65 = $expanded66 ^ -1;
  33003. $70 = $68 & $expanded65;
  33004. $71 = $70;
  33005. $72 = HEAP32[$71>>2]|0;
  33006. $arglist_next15 = ((($71)) + 4|0);
  33007. HEAP32[$2>>2] = $arglist_next15;
  33008. $$mask31 = $72 & 65535;
  33009. $73 = $0;
  33010. $74 = $73;
  33011. HEAP32[$74>>2] = $$mask31;
  33012. $75 = (($73) + 4)|0;
  33013. $76 = $75;
  33014. HEAP32[$76>>2] = 0;
  33015. break L1;
  33016. break;
  33017. }
  33018. case 15: {
  33019. $arglist_current17 = HEAP32[$2>>2]|0;
  33020. $77 = $arglist_current17;
  33021. $78 = ((0) + 4|0);
  33022. $expanded70 = $78;
  33023. $expanded69 = (($expanded70) - 1)|0;
  33024. $79 = (($77) + ($expanded69))|0;
  33025. $80 = ((0) + 4|0);
  33026. $expanded74 = $80;
  33027. $expanded73 = (($expanded74) - 1)|0;
  33028. $expanded72 = $expanded73 ^ -1;
  33029. $81 = $79 & $expanded72;
  33030. $82 = $81;
  33031. $83 = HEAP32[$82>>2]|0;
  33032. $arglist_next18 = ((($82)) + 4|0);
  33033. HEAP32[$2>>2] = $arglist_next18;
  33034. $84 = $83&255;
  33035. $85 = $84 << 24 >> 24;
  33036. $86 = ($85|0)<(0);
  33037. $87 = $86 << 31 >> 31;
  33038. $88 = $0;
  33039. $89 = $88;
  33040. HEAP32[$89>>2] = $85;
  33041. $90 = (($88) + 4)|0;
  33042. $91 = $90;
  33043. HEAP32[$91>>2] = $87;
  33044. break L1;
  33045. break;
  33046. }
  33047. case 16: {
  33048. $arglist_current20 = HEAP32[$2>>2]|0;
  33049. $92 = $arglist_current20;
  33050. $93 = ((0) + 4|0);
  33051. $expanded77 = $93;
  33052. $expanded76 = (($expanded77) - 1)|0;
  33053. $94 = (($92) + ($expanded76))|0;
  33054. $95 = ((0) + 4|0);
  33055. $expanded81 = $95;
  33056. $expanded80 = (($expanded81) - 1)|0;
  33057. $expanded79 = $expanded80 ^ -1;
  33058. $96 = $94 & $expanded79;
  33059. $97 = $96;
  33060. $98 = HEAP32[$97>>2]|0;
  33061. $arglist_next21 = ((($97)) + 4|0);
  33062. HEAP32[$2>>2] = $arglist_next21;
  33063. $$mask = $98 & 255;
  33064. $99 = $0;
  33065. $100 = $99;
  33066. HEAP32[$100>>2] = $$mask;
  33067. $101 = (($99) + 4)|0;
  33068. $102 = $101;
  33069. HEAP32[$102>>2] = 0;
  33070. break L1;
  33071. break;
  33072. }
  33073. case 17: {
  33074. $arglist_current23 = HEAP32[$2>>2]|0;
  33075. $103 = $arglist_current23;
  33076. $104 = ((0) + 8|0);
  33077. $expanded84 = $104;
  33078. $expanded83 = (($expanded84) - 1)|0;
  33079. $105 = (($103) + ($expanded83))|0;
  33080. $106 = ((0) + 8|0);
  33081. $expanded88 = $106;
  33082. $expanded87 = (($expanded88) - 1)|0;
  33083. $expanded86 = $expanded87 ^ -1;
  33084. $107 = $105 & $expanded86;
  33085. $108 = $107;
  33086. $109 = +HEAPF64[$108>>3];
  33087. $arglist_next24 = ((($108)) + 8|0);
  33088. HEAP32[$2>>2] = $arglist_next24;
  33089. HEAPF64[$0>>3] = $109;
  33090. break L1;
  33091. break;
  33092. }
  33093. case 18: {
  33094. $arglist_current26 = HEAP32[$2>>2]|0;
  33095. $110 = $arglist_current26;
  33096. $111 = ((0) + 8|0);
  33097. $expanded91 = $111;
  33098. $expanded90 = (($expanded91) - 1)|0;
  33099. $112 = (($110) + ($expanded90))|0;
  33100. $113 = ((0) + 8|0);
  33101. $expanded95 = $113;
  33102. $expanded94 = (($expanded95) - 1)|0;
  33103. $expanded93 = $expanded94 ^ -1;
  33104. $114 = $112 & $expanded93;
  33105. $115 = $114;
  33106. $116 = +HEAPF64[$115>>3];
  33107. $arglist_next27 = ((($115)) + 8|0);
  33108. HEAP32[$2>>2] = $arglist_next27;
  33109. HEAPF64[$0>>3] = $116;
  33110. break L1;
  33111. break;
  33112. }
  33113. default: {
  33114. break L1;
  33115. }
  33116. }
  33117. } while(0);
  33118. }
  33119. } while(0);
  33120. return;
  33121. }
  33122. function _fmt_x($0,$1,$2,$3) {
  33123. $0 = $0|0;
  33124. $1 = $1|0;
  33125. $2 = $2|0;
  33126. $3 = $3|0;
  33127. var $$05$lcssa = 0, $$056 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0;
  33128. var sp = 0;
  33129. sp = STACKTOP;
  33130. $4 = ($0|0)==(0);
  33131. $5 = ($1|0)==(0);
  33132. $6 = $4 & $5;
  33133. if ($6) {
  33134. $$05$lcssa = $2;
  33135. } else {
  33136. $$056 = $2;$15 = $1;$8 = $0;
  33137. while(1) {
  33138. $7 = $8 & 15;
  33139. $9 = (19123 + ($7)|0);
  33140. $10 = HEAP8[$9>>0]|0;
  33141. $11 = $10&255;
  33142. $12 = $11 | $3;
  33143. $13 = $12&255;
  33144. $14 = ((($$056)) + -1|0);
  33145. HEAP8[$14>>0] = $13;
  33146. $16 = (_bitshift64Lshr(($8|0),($15|0),4)|0);
  33147. $17 = tempRet0;
  33148. $18 = ($16|0)==(0);
  33149. $19 = ($17|0)==(0);
  33150. $20 = $18 & $19;
  33151. if ($20) {
  33152. $$05$lcssa = $14;
  33153. break;
  33154. } else {
  33155. $$056 = $14;$15 = $17;$8 = $16;
  33156. }
  33157. }
  33158. }
  33159. return ($$05$lcssa|0);
  33160. }
  33161. function _fmt_o($0,$1,$2) {
  33162. $0 = $0|0;
  33163. $1 = $1|0;
  33164. $2 = $2|0;
  33165. var $$0$lcssa = 0, $$06 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  33166. sp = STACKTOP;
  33167. $3 = ($0|0)==(0);
  33168. $4 = ($1|0)==(0);
  33169. $5 = $3 & $4;
  33170. if ($5) {
  33171. $$0$lcssa = $2;
  33172. } else {
  33173. $$06 = $2;$11 = $1;$7 = $0;
  33174. while(1) {
  33175. $6 = $7&255;
  33176. $8 = $6 & 7;
  33177. $9 = $8 | 48;
  33178. $10 = ((($$06)) + -1|0);
  33179. HEAP8[$10>>0] = $9;
  33180. $12 = (_bitshift64Lshr(($7|0),($11|0),3)|0);
  33181. $13 = tempRet0;
  33182. $14 = ($12|0)==(0);
  33183. $15 = ($13|0)==(0);
  33184. $16 = $14 & $15;
  33185. if ($16) {
  33186. $$0$lcssa = $10;
  33187. break;
  33188. } else {
  33189. $$06 = $10;$11 = $13;$7 = $12;
  33190. }
  33191. }
  33192. }
  33193. return ($$0$lcssa|0);
  33194. }
  33195. function _fmt_u($0,$1,$2) {
  33196. $0 = $0|0;
  33197. $1 = $1|0;
  33198. $2 = $2|0;
  33199. var $$010$lcssa$off0 = 0, $$012 = 0, $$09$lcssa = 0, $$0914 = 0, $$1$lcssa = 0, $$111 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  33200. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  33201. sp = STACKTOP;
  33202. $3 = ($1>>>0)>(0);
  33203. $4 = ($0>>>0)>(4294967295);
  33204. $5 = ($1|0)==(0);
  33205. $6 = $5 & $4;
  33206. $7 = $3 | $6;
  33207. if ($7) {
  33208. $$0914 = $2;$8 = $0;$9 = $1;
  33209. while(1) {
  33210. $10 = (___uremdi3(($8|0),($9|0),10,0)|0);
  33211. $11 = tempRet0;
  33212. $12 = $10&255;
  33213. $13 = $12 | 48;
  33214. $14 = ((($$0914)) + -1|0);
  33215. HEAP8[$14>>0] = $13;
  33216. $15 = (___udivdi3(($8|0),($9|0),10,0)|0);
  33217. $16 = tempRet0;
  33218. $17 = ($9>>>0)>(9);
  33219. $18 = ($8>>>0)>(4294967295);
  33220. $19 = ($9|0)==(9);
  33221. $20 = $19 & $18;
  33222. $21 = $17 | $20;
  33223. if ($21) {
  33224. $$0914 = $14;$8 = $15;$9 = $16;
  33225. } else {
  33226. break;
  33227. }
  33228. }
  33229. $$010$lcssa$off0 = $15;$$09$lcssa = $14;
  33230. } else {
  33231. $$010$lcssa$off0 = $0;$$09$lcssa = $2;
  33232. }
  33233. $22 = ($$010$lcssa$off0|0)==(0);
  33234. if ($22) {
  33235. $$1$lcssa = $$09$lcssa;
  33236. } else {
  33237. $$012 = $$010$lcssa$off0;$$111 = $$09$lcssa;
  33238. while(1) {
  33239. $23 = (($$012>>>0) % 10)&-1;
  33240. $24 = $23 | 48;
  33241. $25 = $24&255;
  33242. $26 = ((($$111)) + -1|0);
  33243. HEAP8[$26>>0] = $25;
  33244. $27 = (($$012>>>0) / 10)&-1;
  33245. $28 = ($$012>>>0)<(10);
  33246. if ($28) {
  33247. $$1$lcssa = $26;
  33248. break;
  33249. } else {
  33250. $$012 = $27;$$111 = $26;
  33251. }
  33252. }
  33253. }
  33254. return ($$1$lcssa|0);
  33255. }
  33256. function _strerror($0) {
  33257. $0 = $0|0;
  33258. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, label = 0, sp = 0;
  33259. sp = STACKTOP;
  33260. $1 = (___pthread_self_105()|0);
  33261. $2 = ((($1)) + 188|0);
  33262. $3 = HEAP32[$2>>2]|0;
  33263. $4 = (___strerror_l($0,$3)|0);
  33264. return ($4|0);
  33265. }
  33266. function _memchr($0,$1,$2) {
  33267. $0 = $0|0;
  33268. $1 = $1|0;
  33269. $2 = $2|0;
  33270. var $$0$lcssa = 0, $$035$lcssa = 0, $$035$lcssa65 = 0, $$03555 = 0, $$036$lcssa = 0, $$036$lcssa64 = 0, $$03654 = 0, $$046 = 0, $$137$lcssa = 0, $$13745 = 0, $$140 = 0, $$2 = 0, $$23839 = 0, $$3 = 0, $$lcssa = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0;
  33271. var $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0;
  33272. var $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond53 = 0, label = 0, sp = 0;
  33273. sp = STACKTOP;
  33274. $3 = $1 & 255;
  33275. $4 = $0;
  33276. $5 = $4 & 3;
  33277. $6 = ($5|0)!=(0);
  33278. $7 = ($2|0)!=(0);
  33279. $or$cond53 = $7 & $6;
  33280. L1: do {
  33281. if ($or$cond53) {
  33282. $8 = $1&255;
  33283. $$03555 = $0;$$03654 = $2;
  33284. while(1) {
  33285. $9 = HEAP8[$$03555>>0]|0;
  33286. $10 = ($9<<24>>24)==($8<<24>>24);
  33287. if ($10) {
  33288. $$035$lcssa65 = $$03555;$$036$lcssa64 = $$03654;
  33289. label = 6;
  33290. break L1;
  33291. }
  33292. $11 = ((($$03555)) + 1|0);
  33293. $12 = (($$03654) + -1)|0;
  33294. $13 = $11;
  33295. $14 = $13 & 3;
  33296. $15 = ($14|0)!=(0);
  33297. $16 = ($12|0)!=(0);
  33298. $or$cond = $16 & $15;
  33299. if ($or$cond) {
  33300. $$03555 = $11;$$03654 = $12;
  33301. } else {
  33302. $$035$lcssa = $11;$$036$lcssa = $12;$$lcssa = $16;
  33303. label = 5;
  33304. break;
  33305. }
  33306. }
  33307. } else {
  33308. $$035$lcssa = $0;$$036$lcssa = $2;$$lcssa = $7;
  33309. label = 5;
  33310. }
  33311. } while(0);
  33312. if ((label|0) == 5) {
  33313. if ($$lcssa) {
  33314. $$035$lcssa65 = $$035$lcssa;$$036$lcssa64 = $$036$lcssa;
  33315. label = 6;
  33316. } else {
  33317. $$2 = $$035$lcssa;$$3 = 0;
  33318. }
  33319. }
  33320. L8: do {
  33321. if ((label|0) == 6) {
  33322. $17 = HEAP8[$$035$lcssa65>>0]|0;
  33323. $18 = $1&255;
  33324. $19 = ($17<<24>>24)==($18<<24>>24);
  33325. if ($19) {
  33326. $$2 = $$035$lcssa65;$$3 = $$036$lcssa64;
  33327. } else {
  33328. $20 = Math_imul($3, 16843009)|0;
  33329. $21 = ($$036$lcssa64>>>0)>(3);
  33330. L11: do {
  33331. if ($21) {
  33332. $$046 = $$035$lcssa65;$$13745 = $$036$lcssa64;
  33333. while(1) {
  33334. $22 = HEAP32[$$046>>2]|0;
  33335. $23 = $22 ^ $20;
  33336. $24 = (($23) + -16843009)|0;
  33337. $25 = $23 & -2139062144;
  33338. $26 = $25 ^ -2139062144;
  33339. $27 = $26 & $24;
  33340. $28 = ($27|0)==(0);
  33341. if (!($28)) {
  33342. break;
  33343. }
  33344. $29 = ((($$046)) + 4|0);
  33345. $30 = (($$13745) + -4)|0;
  33346. $31 = ($30>>>0)>(3);
  33347. if ($31) {
  33348. $$046 = $29;$$13745 = $30;
  33349. } else {
  33350. $$0$lcssa = $29;$$137$lcssa = $30;
  33351. label = 11;
  33352. break L11;
  33353. }
  33354. }
  33355. $$140 = $$046;$$23839 = $$13745;
  33356. } else {
  33357. $$0$lcssa = $$035$lcssa65;$$137$lcssa = $$036$lcssa64;
  33358. label = 11;
  33359. }
  33360. } while(0);
  33361. if ((label|0) == 11) {
  33362. $32 = ($$137$lcssa|0)==(0);
  33363. if ($32) {
  33364. $$2 = $$0$lcssa;$$3 = 0;
  33365. break;
  33366. } else {
  33367. $$140 = $$0$lcssa;$$23839 = $$137$lcssa;
  33368. }
  33369. }
  33370. while(1) {
  33371. $33 = HEAP8[$$140>>0]|0;
  33372. $34 = ($33<<24>>24)==($18<<24>>24);
  33373. if ($34) {
  33374. $$2 = $$140;$$3 = $$23839;
  33375. break L8;
  33376. }
  33377. $35 = ((($$140)) + 1|0);
  33378. $36 = (($$23839) + -1)|0;
  33379. $37 = ($36|0)==(0);
  33380. if ($37) {
  33381. $$2 = $35;$$3 = 0;
  33382. break;
  33383. } else {
  33384. $$140 = $35;$$23839 = $36;
  33385. }
  33386. }
  33387. }
  33388. }
  33389. } while(0);
  33390. $38 = ($$3|0)!=(0);
  33391. $39 = $38 ? $$2 : 0;
  33392. return ($39|0);
  33393. }
  33394. function _pad_674($0,$1,$2,$3,$4) {
  33395. $0 = $0|0;
  33396. $1 = $1|0;
  33397. $2 = $2|0;
  33398. $3 = $3|0;
  33399. $4 = $4|0;
  33400. var $$0$lcssa = 0, $$011 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, label = 0, sp = 0;
  33401. sp = STACKTOP;
  33402. STACKTOP = STACKTOP + 256|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(256|0);
  33403. $5 = sp;
  33404. $6 = $4 & 73728;
  33405. $7 = ($6|0)==(0);
  33406. $8 = ($2|0)>($3|0);
  33407. $or$cond = $8 & $7;
  33408. if ($or$cond) {
  33409. $9 = (($2) - ($3))|0;
  33410. $10 = ($9>>>0)<(256);
  33411. $11 = $10 ? $9 : 256;
  33412. _memset(($5|0),($1|0),($11|0))|0;
  33413. $12 = ($9>>>0)>(255);
  33414. if ($12) {
  33415. $13 = (($2) - ($3))|0;
  33416. $$011 = $9;
  33417. while(1) {
  33418. _out($0,$5,256);
  33419. $14 = (($$011) + -256)|0;
  33420. $15 = ($14>>>0)>(255);
  33421. if ($15) {
  33422. $$011 = $14;
  33423. } else {
  33424. break;
  33425. }
  33426. }
  33427. $16 = $13 & 255;
  33428. $$0$lcssa = $16;
  33429. } else {
  33430. $$0$lcssa = $9;
  33431. }
  33432. _out($0,$5,$$0$lcssa);
  33433. }
  33434. STACKTOP = sp;return;
  33435. }
  33436. function _wctomb($0,$1) {
  33437. $0 = $0|0;
  33438. $1 = $1|0;
  33439. var $$0 = 0, $2 = 0, $3 = 0, label = 0, sp = 0;
  33440. sp = STACKTOP;
  33441. $2 = ($0|0)==(0|0);
  33442. if ($2) {
  33443. $$0 = 0;
  33444. } else {
  33445. $3 = (_wcrtomb($0,$1,0)|0);
  33446. $$0 = $3;
  33447. }
  33448. return ($$0|0);
  33449. }
  33450. function _fmt_fp($0,$1,$2,$3,$4,$5) {
  33451. $0 = $0|0;
  33452. $1 = +$1;
  33453. $2 = $2|0;
  33454. $3 = $3|0;
  33455. $4 = $4|0;
  33456. $5 = $5|0;
  33457. var $$ = 0, $$$ = 0, $$$$559 = 0.0, $$$3484 = 0, $$$3484691 = 0, $$$3484692 = 0, $$$3501 = 0, $$$4502 = 0, $$$542 = 0.0, $$$559 = 0.0, $$0 = 0, $$0463$lcssa = 0, $$0463584 = 0, $$0464594 = 0, $$0471 = 0.0, $$0479 = 0, $$0487642 = 0, $$0488 = 0, $$0488653 = 0, $$0488655 = 0;
  33458. var $$0496$$9 = 0, $$0497654 = 0, $$0498 = 0, $$0509582 = 0.0, $$0510 = 0, $$0511 = 0, $$0514637 = 0, $$0520 = 0, $$0521 = 0, $$0521$ = 0, $$0523 = 0, $$0525 = 0, $$0527 = 0, $$0527629 = 0, $$0527631 = 0, $$0530636 = 0, $$1465 = 0, $$1467 = 0.0, $$1469 = 0.0, $$1472 = 0.0;
  33459. var $$1480 = 0, $$1482$lcssa = 0, $$1482661 = 0, $$1489641 = 0, $$1499$lcssa = 0, $$1499660 = 0, $$1508583 = 0, $$1512$lcssa = 0, $$1512607 = 0, $$1515 = 0, $$1524 = 0, $$1526 = 0, $$1528614 = 0, $$1531$lcssa = 0, $$1531630 = 0, $$1598 = 0, $$2 = 0, $$2473 = 0.0, $$2476 = 0, $$2476$$547 = 0;
  33460. var $$2476$$549 = 0, $$2483$ph = 0, $$2500 = 0, $$2513 = 0, $$2516618 = 0, $$2529 = 0, $$2532617 = 0, $$3 = 0.0, $$3477 = 0, $$3484$lcssa = 0, $$3484648 = 0, $$3501$lcssa = 0, $$3501647 = 0, $$3533613 = 0, $$4 = 0.0, $$4478$lcssa = 0, $$4478590 = 0, $$4492 = 0, $$4502 = 0, $$4518 = 0;
  33461. var $$5$lcssa = 0, $$534$ = 0, $$539 = 0, $$539$ = 0, $$542 = 0.0, $$546 = 0, $$548 = 0, $$5486$lcssa = 0, $$5486623 = 0, $$5493597 = 0, $$5519$ph = 0, $$555 = 0, $$556 = 0, $$559 = 0.0, $$5602 = 0, $$6 = 0, $$6494589 = 0, $$7495601 = 0, $$7505 = 0, $$7505$ = 0;
  33462. var $$7505$ph = 0, $$8 = 0, $$9$ph = 0, $$lcssa673 = 0, $$neg = 0, $$neg567 = 0, $$pn = 0, $$pn566 = 0, $$pr = 0, $$pr564 = 0, $$pre = 0, $$pre$phi690Z2D = 0, $$pre689 = 0, $$sink545$lcssa = 0, $$sink545622 = 0, $$sink562 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0;
  33463. var $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0.0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0.0, $117 = 0.0, $118 = 0.0, $119 = 0, $12 = 0, $120 = 0;
  33464. var $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0;
  33465. var $14 = 0.0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0;
  33466. var $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0;
  33467. var $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0;
  33468. var $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0;
  33469. var $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0, $22 = 0, $220 = 0, $221 = 0, $222 = 0, $223 = 0, $224 = 0, $225 = 0, $226 = 0, $227 = 0, $228 = 0.0, $229 = 0.0, $23 = 0;
  33470. var $230 = 0, $231 = 0.0, $232 = 0, $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0, $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0;
  33471. var $249 = 0, $25 = 0, $250 = 0, $251 = 0, $252 = 0, $253 = 0, $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0, $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0;
  33472. var $267 = 0, $268 = 0, $269 = 0, $27 = 0, $270 = 0, $271 = 0, $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0, $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0;
  33473. var $285 = 0, $286 = 0, $287 = 0, $288 = 0, $289 = 0, $29 = 0, $290 = 0, $291 = 0, $292 = 0, $293 = 0, $294 = 0, $295 = 0, $296 = 0, $297 = 0, $298 = 0, $299 = 0, $30 = 0, $300 = 0, $301 = 0, $302 = 0;
  33474. var $303 = 0, $304 = 0, $305 = 0, $306 = 0, $307 = 0, $308 = 0, $309 = 0, $31 = 0, $310 = 0, $311 = 0, $312 = 0, $313 = 0, $314 = 0, $315 = 0, $316 = 0, $317 = 0, $318 = 0, $319 = 0, $32 = 0, $320 = 0;
  33475. var $321 = 0, $322 = 0, $323 = 0, $324 = 0, $325 = 0, $326 = 0, $327 = 0, $328 = 0, $329 = 0, $33 = 0, $330 = 0, $331 = 0, $332 = 0, $333 = 0, $334 = 0, $335 = 0, $336 = 0, $337 = 0, $338 = 0, $339 = 0;
  33476. var $34 = 0, $340 = 0, $341 = 0, $342 = 0, $343 = 0, $344 = 0, $345 = 0, $346 = 0, $347 = 0, $348 = 0, $349 = 0, $35 = 0.0, $350 = 0, $351 = 0, $352 = 0, $353 = 0, $354 = 0, $355 = 0, $356 = 0, $357 = 0;
  33477. var $358 = 0, $359 = 0, $36 = 0.0, $360 = 0, $361 = 0, $362 = 0, $363 = 0, $364 = 0, $365 = 0, $366 = 0, $367 = 0, $368 = 0, $369 = 0, $37 = 0, $370 = 0, $371 = 0, $372 = 0, $373 = 0, $374 = 0, $375 = 0;
  33478. var $376 = 0, $377 = 0, $378 = 0, $379 = 0, $38 = 0, $380 = 0, $381 = 0, $382 = 0, $383 = 0, $384 = 0, $385 = 0, $386 = 0, $387 = 0, $388 = 0, $39 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  33479. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $50 = 0, $51 = 0.0, $52 = 0, $53 = 0, $54 = 0, $55 = 0.0, $56 = 0.0, $57 = 0.0, $58 = 0.0, $59 = 0.0, $6 = 0, $60 = 0.0, $61 = 0, $62 = 0, $63 = 0;
  33480. var $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0;
  33481. var $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0.0, $88 = 0.0, $89 = 0.0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $exitcond = 0;
  33482. var $narrow = 0, $not$ = 0, $notlhs = 0, $notrhs = 0, $or$cond = 0, $or$cond3$not = 0, $or$cond537 = 0, $or$cond541 = 0, $or$cond544 = 0, $or$cond554 = 0, $or$cond6 = 0, $scevgep684 = 0, $scevgep684685 = 0, label = 0, sp = 0;
  33483. sp = STACKTOP;
  33484. STACKTOP = STACKTOP + 560|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(560|0);
  33485. $6 = sp + 8|0;
  33486. $7 = sp;
  33487. $8 = sp + 524|0;
  33488. $9 = $8;
  33489. $10 = sp + 512|0;
  33490. HEAP32[$7>>2] = 0;
  33491. $11 = ((($10)) + 12|0);
  33492. (___DOUBLE_BITS_675($1)|0);
  33493. $12 = tempRet0;
  33494. $13 = ($12|0)<(0);
  33495. if ($13) {
  33496. $14 = -$1;
  33497. $$0471 = $14;$$0520 = 1;$$0521 = 19088;
  33498. } else {
  33499. $15 = $4 & 2048;
  33500. $16 = ($15|0)==(0);
  33501. $17 = $4 & 1;
  33502. $18 = ($17|0)==(0);
  33503. $$ = $18 ? (19089) : (19094);
  33504. $$$ = $16 ? $$ : (19091);
  33505. $19 = $4 & 2049;
  33506. $narrow = ($19|0)!=(0);
  33507. $$534$ = $narrow&1;
  33508. $$0471 = $1;$$0520 = $$534$;$$0521 = $$$;
  33509. }
  33510. (___DOUBLE_BITS_675($$0471)|0);
  33511. $20 = tempRet0;
  33512. $21 = $20 & 2146435072;
  33513. $22 = ($21>>>0)<(2146435072);
  33514. $23 = (0)<(0);
  33515. $24 = ($21|0)==(2146435072);
  33516. $25 = $24 & $23;
  33517. $26 = $22 | $25;
  33518. do {
  33519. if ($26) {
  33520. $35 = (+_frexpl($$0471,$7));
  33521. $36 = $35 * 2.0;
  33522. $37 = $36 != 0.0;
  33523. if ($37) {
  33524. $38 = HEAP32[$7>>2]|0;
  33525. $39 = (($38) + -1)|0;
  33526. HEAP32[$7>>2] = $39;
  33527. }
  33528. $40 = $5 | 32;
  33529. $41 = ($40|0)==(97);
  33530. if ($41) {
  33531. $42 = $5 & 32;
  33532. $43 = ($42|0)==(0);
  33533. $44 = ((($$0521)) + 9|0);
  33534. $$0521$ = $43 ? $$0521 : $44;
  33535. $45 = $$0520 | 2;
  33536. $46 = ($3>>>0)>(11);
  33537. $47 = (12 - ($3))|0;
  33538. $48 = ($47|0)==(0);
  33539. $49 = $46 | $48;
  33540. do {
  33541. if ($49) {
  33542. $$1472 = $36;
  33543. } else {
  33544. $$0509582 = 8.0;$$1508583 = $47;
  33545. while(1) {
  33546. $50 = (($$1508583) + -1)|0;
  33547. $51 = $$0509582 * 16.0;
  33548. $52 = ($50|0)==(0);
  33549. if ($52) {
  33550. break;
  33551. } else {
  33552. $$0509582 = $51;$$1508583 = $50;
  33553. }
  33554. }
  33555. $53 = HEAP8[$$0521$>>0]|0;
  33556. $54 = ($53<<24>>24)==(45);
  33557. if ($54) {
  33558. $55 = -$36;
  33559. $56 = $55 - $51;
  33560. $57 = $51 + $56;
  33561. $58 = -$57;
  33562. $$1472 = $58;
  33563. break;
  33564. } else {
  33565. $59 = $36 + $51;
  33566. $60 = $59 - $51;
  33567. $$1472 = $60;
  33568. break;
  33569. }
  33570. }
  33571. } while(0);
  33572. $61 = HEAP32[$7>>2]|0;
  33573. $62 = ($61|0)<(0);
  33574. $63 = (0 - ($61))|0;
  33575. $64 = $62 ? $63 : $61;
  33576. $65 = ($64|0)<(0);
  33577. $66 = $65 << 31 >> 31;
  33578. $67 = (_fmt_u($64,$66,$11)|0);
  33579. $68 = ($67|0)==($11|0);
  33580. if ($68) {
  33581. $69 = ((($10)) + 11|0);
  33582. HEAP8[$69>>0] = 48;
  33583. $$0511 = $69;
  33584. } else {
  33585. $$0511 = $67;
  33586. }
  33587. $70 = $61 >> 31;
  33588. $71 = $70 & 2;
  33589. $72 = (($71) + 43)|0;
  33590. $73 = $72&255;
  33591. $74 = ((($$0511)) + -1|0);
  33592. HEAP8[$74>>0] = $73;
  33593. $75 = (($5) + 15)|0;
  33594. $76 = $75&255;
  33595. $77 = ((($$0511)) + -2|0);
  33596. HEAP8[$77>>0] = $76;
  33597. $notrhs = ($3|0)<(1);
  33598. $78 = $4 & 8;
  33599. $79 = ($78|0)==(0);
  33600. $$0523 = $8;$$2473 = $$1472;
  33601. while(1) {
  33602. $80 = (~~(($$2473)));
  33603. $81 = (19123 + ($80)|0);
  33604. $82 = HEAP8[$81>>0]|0;
  33605. $83 = $82&255;
  33606. $84 = $83 | $42;
  33607. $85 = $84&255;
  33608. $86 = ((($$0523)) + 1|0);
  33609. HEAP8[$$0523>>0] = $85;
  33610. $87 = (+($80|0));
  33611. $88 = $$2473 - $87;
  33612. $89 = $88 * 16.0;
  33613. $90 = $86;
  33614. $91 = (($90) - ($9))|0;
  33615. $92 = ($91|0)==(1);
  33616. if ($92) {
  33617. $notlhs = $89 == 0.0;
  33618. $or$cond3$not = $notrhs & $notlhs;
  33619. $or$cond = $79 & $or$cond3$not;
  33620. if ($or$cond) {
  33621. $$1524 = $86;
  33622. } else {
  33623. $93 = ((($$0523)) + 2|0);
  33624. HEAP8[$86>>0] = 46;
  33625. $$1524 = $93;
  33626. }
  33627. } else {
  33628. $$1524 = $86;
  33629. }
  33630. $94 = $89 != 0.0;
  33631. if ($94) {
  33632. $$0523 = $$1524;$$2473 = $89;
  33633. } else {
  33634. break;
  33635. }
  33636. }
  33637. $95 = ($3|0)!=(0);
  33638. $96 = $77;
  33639. $97 = $11;
  33640. $98 = $$1524;
  33641. $99 = (($98) - ($9))|0;
  33642. $100 = (($97) - ($96))|0;
  33643. $101 = (($99) + -2)|0;
  33644. $102 = ($101|0)<($3|0);
  33645. $or$cond537 = $95 & $102;
  33646. $103 = (($3) + 2)|0;
  33647. $$pn = $or$cond537 ? $103 : $99;
  33648. $$0525 = (($100) + ($45))|0;
  33649. $104 = (($$0525) + ($$pn))|0;
  33650. _pad_674($0,32,$2,$104,$4);
  33651. _out($0,$$0521$,$45);
  33652. $105 = $4 ^ 65536;
  33653. _pad_674($0,48,$2,$104,$105);
  33654. _out($0,$8,$99);
  33655. $106 = (($$pn) - ($99))|0;
  33656. _pad_674($0,48,$106,0,0);
  33657. _out($0,$77,$100);
  33658. $107 = $4 ^ 8192;
  33659. _pad_674($0,32,$2,$104,$107);
  33660. $$sink562 = $104;
  33661. break;
  33662. }
  33663. $108 = ($3|0)<(0);
  33664. $$539 = $108 ? 6 : $3;
  33665. if ($37) {
  33666. $109 = $36 * 268435456.0;
  33667. $110 = HEAP32[$7>>2]|0;
  33668. $111 = (($110) + -28)|0;
  33669. HEAP32[$7>>2] = $111;
  33670. $$3 = $109;$$pr = $111;
  33671. } else {
  33672. $$pre = HEAP32[$7>>2]|0;
  33673. $$3 = $36;$$pr = $$pre;
  33674. }
  33675. $112 = ($$pr|0)<(0);
  33676. $113 = ((($6)) + 288|0);
  33677. $$556 = $112 ? $6 : $113;
  33678. $$0498 = $$556;$$4 = $$3;
  33679. while(1) {
  33680. $114 = (~~(($$4))>>>0);
  33681. HEAP32[$$0498>>2] = $114;
  33682. $115 = ((($$0498)) + 4|0);
  33683. $116 = (+($114>>>0));
  33684. $117 = $$4 - $116;
  33685. $118 = $117 * 1.0E+9;
  33686. $119 = $118 != 0.0;
  33687. if ($119) {
  33688. $$0498 = $115;$$4 = $118;
  33689. } else {
  33690. break;
  33691. }
  33692. }
  33693. $120 = ($$pr|0)>(0);
  33694. if ($120) {
  33695. $$1482661 = $$556;$$1499660 = $115;$122 = $$pr;
  33696. while(1) {
  33697. $121 = ($122|0)<(29);
  33698. $123 = $121 ? $122 : 29;
  33699. $$0488653 = ((($$1499660)) + -4|0);
  33700. $124 = ($$0488653>>>0)<($$1482661>>>0);
  33701. if ($124) {
  33702. $$2483$ph = $$1482661;
  33703. } else {
  33704. $$0488655 = $$0488653;$$0497654 = 0;
  33705. while(1) {
  33706. $125 = HEAP32[$$0488655>>2]|0;
  33707. $126 = (_bitshift64Shl(($125|0),0,($123|0))|0);
  33708. $127 = tempRet0;
  33709. $128 = (_i64Add(($126|0),($127|0),($$0497654|0),0)|0);
  33710. $129 = tempRet0;
  33711. $130 = (___uremdi3(($128|0),($129|0),1000000000,0)|0);
  33712. $131 = tempRet0;
  33713. HEAP32[$$0488655>>2] = $130;
  33714. $132 = (___udivdi3(($128|0),($129|0),1000000000,0)|0);
  33715. $133 = tempRet0;
  33716. $$0488 = ((($$0488655)) + -4|0);
  33717. $134 = ($$0488>>>0)<($$1482661>>>0);
  33718. if ($134) {
  33719. break;
  33720. } else {
  33721. $$0488655 = $$0488;$$0497654 = $132;
  33722. }
  33723. }
  33724. $135 = ($132|0)==(0);
  33725. if ($135) {
  33726. $$2483$ph = $$1482661;
  33727. } else {
  33728. $136 = ((($$1482661)) + -4|0);
  33729. HEAP32[$136>>2] = $132;
  33730. $$2483$ph = $136;
  33731. }
  33732. }
  33733. $$2500 = $$1499660;
  33734. while(1) {
  33735. $137 = ($$2500>>>0)>($$2483$ph>>>0);
  33736. if (!($137)) {
  33737. break;
  33738. }
  33739. $138 = ((($$2500)) + -4|0);
  33740. $139 = HEAP32[$138>>2]|0;
  33741. $140 = ($139|0)==(0);
  33742. if ($140) {
  33743. $$2500 = $138;
  33744. } else {
  33745. break;
  33746. }
  33747. }
  33748. $141 = HEAP32[$7>>2]|0;
  33749. $142 = (($141) - ($123))|0;
  33750. HEAP32[$7>>2] = $142;
  33751. $143 = ($142|0)>(0);
  33752. if ($143) {
  33753. $$1482661 = $$2483$ph;$$1499660 = $$2500;$122 = $142;
  33754. } else {
  33755. $$1482$lcssa = $$2483$ph;$$1499$lcssa = $$2500;$$pr564 = $142;
  33756. break;
  33757. }
  33758. }
  33759. } else {
  33760. $$1482$lcssa = $$556;$$1499$lcssa = $115;$$pr564 = $$pr;
  33761. }
  33762. $144 = ($$pr564|0)<(0);
  33763. if ($144) {
  33764. $145 = (($$539) + 25)|0;
  33765. $146 = (($145|0) / 9)&-1;
  33766. $147 = (($146) + 1)|0;
  33767. $148 = ($40|0)==(102);
  33768. $$3484648 = $$1482$lcssa;$$3501647 = $$1499$lcssa;$150 = $$pr564;
  33769. while(1) {
  33770. $149 = (0 - ($150))|0;
  33771. $151 = ($149|0)<(9);
  33772. $152 = $151 ? $149 : 9;
  33773. $153 = ($$3484648>>>0)<($$3501647>>>0);
  33774. if ($153) {
  33775. $157 = 1 << $152;
  33776. $158 = (($157) + -1)|0;
  33777. $159 = 1000000000 >>> $152;
  33778. $$0487642 = 0;$$1489641 = $$3484648;
  33779. while(1) {
  33780. $160 = HEAP32[$$1489641>>2]|0;
  33781. $161 = $160 & $158;
  33782. $162 = $160 >>> $152;
  33783. $163 = (($162) + ($$0487642))|0;
  33784. HEAP32[$$1489641>>2] = $163;
  33785. $164 = Math_imul($161, $159)|0;
  33786. $165 = ((($$1489641)) + 4|0);
  33787. $166 = ($165>>>0)<($$3501647>>>0);
  33788. if ($166) {
  33789. $$0487642 = $164;$$1489641 = $165;
  33790. } else {
  33791. break;
  33792. }
  33793. }
  33794. $167 = HEAP32[$$3484648>>2]|0;
  33795. $168 = ($167|0)==(0);
  33796. $169 = ((($$3484648)) + 4|0);
  33797. $$$3484 = $168 ? $169 : $$3484648;
  33798. $170 = ($164|0)==(0);
  33799. if ($170) {
  33800. $$$3484692 = $$$3484;$$4502 = $$3501647;
  33801. } else {
  33802. $171 = ((($$3501647)) + 4|0);
  33803. HEAP32[$$3501647>>2] = $164;
  33804. $$$3484692 = $$$3484;$$4502 = $171;
  33805. }
  33806. } else {
  33807. $154 = HEAP32[$$3484648>>2]|0;
  33808. $155 = ($154|0)==(0);
  33809. $156 = ((($$3484648)) + 4|0);
  33810. $$$3484691 = $155 ? $156 : $$3484648;
  33811. $$$3484692 = $$$3484691;$$4502 = $$3501647;
  33812. }
  33813. $172 = $148 ? $$556 : $$$3484692;
  33814. $173 = $$4502;
  33815. $174 = $172;
  33816. $175 = (($173) - ($174))|0;
  33817. $176 = $175 >> 2;
  33818. $177 = ($176|0)>($147|0);
  33819. $178 = (($172) + ($147<<2)|0);
  33820. $$$4502 = $177 ? $178 : $$4502;
  33821. $179 = HEAP32[$7>>2]|0;
  33822. $180 = (($179) + ($152))|0;
  33823. HEAP32[$7>>2] = $180;
  33824. $181 = ($180|0)<(0);
  33825. if ($181) {
  33826. $$3484648 = $$$3484692;$$3501647 = $$$4502;$150 = $180;
  33827. } else {
  33828. $$3484$lcssa = $$$3484692;$$3501$lcssa = $$$4502;
  33829. break;
  33830. }
  33831. }
  33832. } else {
  33833. $$3484$lcssa = $$1482$lcssa;$$3501$lcssa = $$1499$lcssa;
  33834. }
  33835. $182 = ($$3484$lcssa>>>0)<($$3501$lcssa>>>0);
  33836. $183 = $$556;
  33837. if ($182) {
  33838. $184 = $$3484$lcssa;
  33839. $185 = (($183) - ($184))|0;
  33840. $186 = $185 >> 2;
  33841. $187 = ($186*9)|0;
  33842. $188 = HEAP32[$$3484$lcssa>>2]|0;
  33843. $189 = ($188>>>0)<(10);
  33844. if ($189) {
  33845. $$1515 = $187;
  33846. } else {
  33847. $$0514637 = $187;$$0530636 = 10;
  33848. while(1) {
  33849. $190 = ($$0530636*10)|0;
  33850. $191 = (($$0514637) + 1)|0;
  33851. $192 = ($188>>>0)<($190>>>0);
  33852. if ($192) {
  33853. $$1515 = $191;
  33854. break;
  33855. } else {
  33856. $$0514637 = $191;$$0530636 = $190;
  33857. }
  33858. }
  33859. }
  33860. } else {
  33861. $$1515 = 0;
  33862. }
  33863. $193 = ($40|0)!=(102);
  33864. $194 = $193 ? $$1515 : 0;
  33865. $195 = (($$539) - ($194))|0;
  33866. $196 = ($40|0)==(103);
  33867. $197 = ($$539|0)!=(0);
  33868. $198 = $197 & $196;
  33869. $$neg = $198 << 31 >> 31;
  33870. $199 = (($195) + ($$neg))|0;
  33871. $200 = $$3501$lcssa;
  33872. $201 = (($200) - ($183))|0;
  33873. $202 = $201 >> 2;
  33874. $203 = ($202*9)|0;
  33875. $204 = (($203) + -9)|0;
  33876. $205 = ($199|0)<($204|0);
  33877. if ($205) {
  33878. $206 = ((($$556)) + 4|0);
  33879. $207 = (($199) + 9216)|0;
  33880. $208 = (($207|0) / 9)&-1;
  33881. $209 = (($208) + -1024)|0;
  33882. $210 = (($206) + ($209<<2)|0);
  33883. $211 = (($207|0) % 9)&-1;
  33884. $$0527629 = (($211) + 1)|0;
  33885. $212 = ($$0527629|0)<(9);
  33886. if ($212) {
  33887. $$0527631 = $$0527629;$$1531630 = 10;
  33888. while(1) {
  33889. $213 = ($$1531630*10)|0;
  33890. $$0527 = (($$0527631) + 1)|0;
  33891. $exitcond = ($$0527|0)==(9);
  33892. if ($exitcond) {
  33893. $$1531$lcssa = $213;
  33894. break;
  33895. } else {
  33896. $$0527631 = $$0527;$$1531630 = $213;
  33897. }
  33898. }
  33899. } else {
  33900. $$1531$lcssa = 10;
  33901. }
  33902. $214 = HEAP32[$210>>2]|0;
  33903. $215 = (($214>>>0) % ($$1531$lcssa>>>0))&-1;
  33904. $216 = ($215|0)==(0);
  33905. $217 = ((($210)) + 4|0);
  33906. $218 = ($217|0)==($$3501$lcssa|0);
  33907. $or$cond541 = $218 & $216;
  33908. if ($or$cond541) {
  33909. $$4492 = $210;$$4518 = $$1515;$$8 = $$3484$lcssa;
  33910. } else {
  33911. $219 = (($214>>>0) / ($$1531$lcssa>>>0))&-1;
  33912. $220 = $219 & 1;
  33913. $221 = ($220|0)==(0);
  33914. $$542 = $221 ? 9007199254740992.0 : 9007199254740994.0;
  33915. $222 = (($$1531$lcssa|0) / 2)&-1;
  33916. $223 = ($215>>>0)<($222>>>0);
  33917. $224 = ($215|0)==($222|0);
  33918. $or$cond544 = $218 & $224;
  33919. $$559 = $or$cond544 ? 1.0 : 1.5;
  33920. $$$559 = $223 ? 0.5 : $$559;
  33921. $225 = ($$0520|0)==(0);
  33922. if ($225) {
  33923. $$1467 = $$$559;$$1469 = $$542;
  33924. } else {
  33925. $226 = HEAP8[$$0521>>0]|0;
  33926. $227 = ($226<<24>>24)==(45);
  33927. $228 = -$$542;
  33928. $229 = -$$$559;
  33929. $$$542 = $227 ? $228 : $$542;
  33930. $$$$559 = $227 ? $229 : $$$559;
  33931. $$1467 = $$$$559;$$1469 = $$$542;
  33932. }
  33933. $230 = (($214) - ($215))|0;
  33934. HEAP32[$210>>2] = $230;
  33935. $231 = $$1469 + $$1467;
  33936. $232 = $231 != $$1469;
  33937. if ($232) {
  33938. $233 = (($230) + ($$1531$lcssa))|0;
  33939. HEAP32[$210>>2] = $233;
  33940. $234 = ($233>>>0)>(999999999);
  33941. if ($234) {
  33942. $$5486623 = $$3484$lcssa;$$sink545622 = $210;
  33943. while(1) {
  33944. $235 = ((($$sink545622)) + -4|0);
  33945. HEAP32[$$sink545622>>2] = 0;
  33946. $236 = ($235>>>0)<($$5486623>>>0);
  33947. if ($236) {
  33948. $237 = ((($$5486623)) + -4|0);
  33949. HEAP32[$237>>2] = 0;
  33950. $$6 = $237;
  33951. } else {
  33952. $$6 = $$5486623;
  33953. }
  33954. $238 = HEAP32[$235>>2]|0;
  33955. $239 = (($238) + 1)|0;
  33956. HEAP32[$235>>2] = $239;
  33957. $240 = ($239>>>0)>(999999999);
  33958. if ($240) {
  33959. $$5486623 = $$6;$$sink545622 = $235;
  33960. } else {
  33961. $$5486$lcssa = $$6;$$sink545$lcssa = $235;
  33962. break;
  33963. }
  33964. }
  33965. } else {
  33966. $$5486$lcssa = $$3484$lcssa;$$sink545$lcssa = $210;
  33967. }
  33968. $241 = $$5486$lcssa;
  33969. $242 = (($183) - ($241))|0;
  33970. $243 = $242 >> 2;
  33971. $244 = ($243*9)|0;
  33972. $245 = HEAP32[$$5486$lcssa>>2]|0;
  33973. $246 = ($245>>>0)<(10);
  33974. if ($246) {
  33975. $$4492 = $$sink545$lcssa;$$4518 = $244;$$8 = $$5486$lcssa;
  33976. } else {
  33977. $$2516618 = $244;$$2532617 = 10;
  33978. while(1) {
  33979. $247 = ($$2532617*10)|0;
  33980. $248 = (($$2516618) + 1)|0;
  33981. $249 = ($245>>>0)<($247>>>0);
  33982. if ($249) {
  33983. $$4492 = $$sink545$lcssa;$$4518 = $248;$$8 = $$5486$lcssa;
  33984. break;
  33985. } else {
  33986. $$2516618 = $248;$$2532617 = $247;
  33987. }
  33988. }
  33989. }
  33990. } else {
  33991. $$4492 = $210;$$4518 = $$1515;$$8 = $$3484$lcssa;
  33992. }
  33993. }
  33994. $250 = ((($$4492)) + 4|0);
  33995. $251 = ($$3501$lcssa>>>0)>($250>>>0);
  33996. $$$3501 = $251 ? $250 : $$3501$lcssa;
  33997. $$5519$ph = $$4518;$$7505$ph = $$$3501;$$9$ph = $$8;
  33998. } else {
  33999. $$5519$ph = $$1515;$$7505$ph = $$3501$lcssa;$$9$ph = $$3484$lcssa;
  34000. }
  34001. $$7505 = $$7505$ph;
  34002. while(1) {
  34003. $252 = ($$7505>>>0)>($$9$ph>>>0);
  34004. if (!($252)) {
  34005. $$lcssa673 = 0;
  34006. break;
  34007. }
  34008. $253 = ((($$7505)) + -4|0);
  34009. $254 = HEAP32[$253>>2]|0;
  34010. $255 = ($254|0)==(0);
  34011. if ($255) {
  34012. $$7505 = $253;
  34013. } else {
  34014. $$lcssa673 = 1;
  34015. break;
  34016. }
  34017. }
  34018. $256 = (0 - ($$5519$ph))|0;
  34019. do {
  34020. if ($196) {
  34021. $not$ = $197 ^ 1;
  34022. $257 = $not$&1;
  34023. $$539$ = (($257) + ($$539))|0;
  34024. $258 = ($$539$|0)>($$5519$ph|0);
  34025. $259 = ($$5519$ph|0)>(-5);
  34026. $or$cond6 = $258 & $259;
  34027. if ($or$cond6) {
  34028. $260 = (($5) + -1)|0;
  34029. $$neg567 = (($$539$) + -1)|0;
  34030. $261 = (($$neg567) - ($$5519$ph))|0;
  34031. $$0479 = $260;$$2476 = $261;
  34032. } else {
  34033. $262 = (($5) + -2)|0;
  34034. $263 = (($$539$) + -1)|0;
  34035. $$0479 = $262;$$2476 = $263;
  34036. }
  34037. $264 = $4 & 8;
  34038. $265 = ($264|0)==(0);
  34039. if ($265) {
  34040. if ($$lcssa673) {
  34041. $266 = ((($$7505)) + -4|0);
  34042. $267 = HEAP32[$266>>2]|0;
  34043. $268 = ($267|0)==(0);
  34044. if ($268) {
  34045. $$2529 = 9;
  34046. } else {
  34047. $269 = (($267>>>0) % 10)&-1;
  34048. $270 = ($269|0)==(0);
  34049. if ($270) {
  34050. $$1528614 = 0;$$3533613 = 10;
  34051. while(1) {
  34052. $271 = ($$3533613*10)|0;
  34053. $272 = (($$1528614) + 1)|0;
  34054. $273 = (($267>>>0) % ($271>>>0))&-1;
  34055. $274 = ($273|0)==(0);
  34056. if ($274) {
  34057. $$1528614 = $272;$$3533613 = $271;
  34058. } else {
  34059. $$2529 = $272;
  34060. break;
  34061. }
  34062. }
  34063. } else {
  34064. $$2529 = 0;
  34065. }
  34066. }
  34067. } else {
  34068. $$2529 = 9;
  34069. }
  34070. $275 = $$0479 | 32;
  34071. $276 = ($275|0)==(102);
  34072. $277 = $$7505;
  34073. $278 = (($277) - ($183))|0;
  34074. $279 = $278 >> 2;
  34075. $280 = ($279*9)|0;
  34076. $281 = (($280) + -9)|0;
  34077. if ($276) {
  34078. $282 = (($281) - ($$2529))|0;
  34079. $283 = ($282|0)>(0);
  34080. $$546 = $283 ? $282 : 0;
  34081. $284 = ($$2476|0)<($$546|0);
  34082. $$2476$$547 = $284 ? $$2476 : $$546;
  34083. $$1480 = $$0479;$$3477 = $$2476$$547;$$pre$phi690Z2D = 0;
  34084. break;
  34085. } else {
  34086. $285 = (($281) + ($$5519$ph))|0;
  34087. $286 = (($285) - ($$2529))|0;
  34088. $287 = ($286|0)>(0);
  34089. $$548 = $287 ? $286 : 0;
  34090. $288 = ($$2476|0)<($$548|0);
  34091. $$2476$$549 = $288 ? $$2476 : $$548;
  34092. $$1480 = $$0479;$$3477 = $$2476$$549;$$pre$phi690Z2D = 0;
  34093. break;
  34094. }
  34095. } else {
  34096. $$1480 = $$0479;$$3477 = $$2476;$$pre$phi690Z2D = $264;
  34097. }
  34098. } else {
  34099. $$pre689 = $4 & 8;
  34100. $$1480 = $5;$$3477 = $$539;$$pre$phi690Z2D = $$pre689;
  34101. }
  34102. } while(0);
  34103. $289 = $$3477 | $$pre$phi690Z2D;
  34104. $290 = ($289|0)!=(0);
  34105. $291 = $290&1;
  34106. $292 = $$1480 | 32;
  34107. $293 = ($292|0)==(102);
  34108. if ($293) {
  34109. $294 = ($$5519$ph|0)>(0);
  34110. $295 = $294 ? $$5519$ph : 0;
  34111. $$2513 = 0;$$pn566 = $295;
  34112. } else {
  34113. $296 = ($$5519$ph|0)<(0);
  34114. $297 = $296 ? $256 : $$5519$ph;
  34115. $298 = ($297|0)<(0);
  34116. $299 = $298 << 31 >> 31;
  34117. $300 = (_fmt_u($297,$299,$11)|0);
  34118. $301 = $11;
  34119. $302 = $300;
  34120. $303 = (($301) - ($302))|0;
  34121. $304 = ($303|0)<(2);
  34122. if ($304) {
  34123. $$1512607 = $300;
  34124. while(1) {
  34125. $305 = ((($$1512607)) + -1|0);
  34126. HEAP8[$305>>0] = 48;
  34127. $306 = $305;
  34128. $307 = (($301) - ($306))|0;
  34129. $308 = ($307|0)<(2);
  34130. if ($308) {
  34131. $$1512607 = $305;
  34132. } else {
  34133. $$1512$lcssa = $305;
  34134. break;
  34135. }
  34136. }
  34137. } else {
  34138. $$1512$lcssa = $300;
  34139. }
  34140. $309 = $$5519$ph >> 31;
  34141. $310 = $309 & 2;
  34142. $311 = (($310) + 43)|0;
  34143. $312 = $311&255;
  34144. $313 = ((($$1512$lcssa)) + -1|0);
  34145. HEAP8[$313>>0] = $312;
  34146. $314 = $$1480&255;
  34147. $315 = ((($$1512$lcssa)) + -2|0);
  34148. HEAP8[$315>>0] = $314;
  34149. $316 = $315;
  34150. $317 = (($301) - ($316))|0;
  34151. $$2513 = $315;$$pn566 = $317;
  34152. }
  34153. $318 = (($$0520) + 1)|0;
  34154. $319 = (($318) + ($$3477))|0;
  34155. $$1526 = (($319) + ($291))|0;
  34156. $320 = (($$1526) + ($$pn566))|0;
  34157. _pad_674($0,32,$2,$320,$4);
  34158. _out($0,$$0521,$$0520);
  34159. $321 = $4 ^ 65536;
  34160. _pad_674($0,48,$2,$320,$321);
  34161. if ($293) {
  34162. $322 = ($$9$ph>>>0)>($$556>>>0);
  34163. $$0496$$9 = $322 ? $$556 : $$9$ph;
  34164. $323 = ((($8)) + 9|0);
  34165. $324 = $323;
  34166. $325 = ((($8)) + 8|0);
  34167. $$5493597 = $$0496$$9;
  34168. while(1) {
  34169. $326 = HEAP32[$$5493597>>2]|0;
  34170. $327 = (_fmt_u($326,0,$323)|0);
  34171. $328 = ($$5493597|0)==($$0496$$9|0);
  34172. if ($328) {
  34173. $334 = ($327|0)==($323|0);
  34174. if ($334) {
  34175. HEAP8[$325>>0] = 48;
  34176. $$1465 = $325;
  34177. } else {
  34178. $$1465 = $327;
  34179. }
  34180. } else {
  34181. $329 = ($327>>>0)>($8>>>0);
  34182. if ($329) {
  34183. $330 = $327;
  34184. $331 = (($330) - ($9))|0;
  34185. _memset(($8|0),48,($331|0))|0;
  34186. $$0464594 = $327;
  34187. while(1) {
  34188. $332 = ((($$0464594)) + -1|0);
  34189. $333 = ($332>>>0)>($8>>>0);
  34190. if ($333) {
  34191. $$0464594 = $332;
  34192. } else {
  34193. $$1465 = $332;
  34194. break;
  34195. }
  34196. }
  34197. } else {
  34198. $$1465 = $327;
  34199. }
  34200. }
  34201. $335 = $$1465;
  34202. $336 = (($324) - ($335))|0;
  34203. _out($0,$$1465,$336);
  34204. $337 = ((($$5493597)) + 4|0);
  34205. $338 = ($337>>>0)>($$556>>>0);
  34206. if ($338) {
  34207. break;
  34208. } else {
  34209. $$5493597 = $337;
  34210. }
  34211. }
  34212. $339 = ($289|0)==(0);
  34213. if (!($339)) {
  34214. _out($0,19139,1);
  34215. }
  34216. $340 = ($337>>>0)<($$7505>>>0);
  34217. $341 = ($$3477|0)>(0);
  34218. $342 = $340 & $341;
  34219. if ($342) {
  34220. $$4478590 = $$3477;$$6494589 = $337;
  34221. while(1) {
  34222. $343 = HEAP32[$$6494589>>2]|0;
  34223. $344 = (_fmt_u($343,0,$323)|0);
  34224. $345 = ($344>>>0)>($8>>>0);
  34225. if ($345) {
  34226. $346 = $344;
  34227. $347 = (($346) - ($9))|0;
  34228. _memset(($8|0),48,($347|0))|0;
  34229. $$0463584 = $344;
  34230. while(1) {
  34231. $348 = ((($$0463584)) + -1|0);
  34232. $349 = ($348>>>0)>($8>>>0);
  34233. if ($349) {
  34234. $$0463584 = $348;
  34235. } else {
  34236. $$0463$lcssa = $348;
  34237. break;
  34238. }
  34239. }
  34240. } else {
  34241. $$0463$lcssa = $344;
  34242. }
  34243. $350 = ($$4478590|0)<(9);
  34244. $351 = $350 ? $$4478590 : 9;
  34245. _out($0,$$0463$lcssa,$351);
  34246. $352 = ((($$6494589)) + 4|0);
  34247. $353 = (($$4478590) + -9)|0;
  34248. $354 = ($352>>>0)<($$7505>>>0);
  34249. $355 = ($$4478590|0)>(9);
  34250. $356 = $354 & $355;
  34251. if ($356) {
  34252. $$4478590 = $353;$$6494589 = $352;
  34253. } else {
  34254. $$4478$lcssa = $353;
  34255. break;
  34256. }
  34257. }
  34258. } else {
  34259. $$4478$lcssa = $$3477;
  34260. }
  34261. $357 = (($$4478$lcssa) + 9)|0;
  34262. _pad_674($0,48,$357,9,0);
  34263. } else {
  34264. $358 = ((($$9$ph)) + 4|0);
  34265. $$7505$ = $$lcssa673 ? $$7505 : $358;
  34266. $359 = ($$3477|0)>(-1);
  34267. if ($359) {
  34268. $360 = ((($8)) + 9|0);
  34269. $361 = ($$pre$phi690Z2D|0)==(0);
  34270. $362 = $360;
  34271. $363 = (0 - ($9))|0;
  34272. $364 = ((($8)) + 8|0);
  34273. $$5602 = $$3477;$$7495601 = $$9$ph;
  34274. while(1) {
  34275. $365 = HEAP32[$$7495601>>2]|0;
  34276. $366 = (_fmt_u($365,0,$360)|0);
  34277. $367 = ($366|0)==($360|0);
  34278. if ($367) {
  34279. HEAP8[$364>>0] = 48;
  34280. $$0 = $364;
  34281. } else {
  34282. $$0 = $366;
  34283. }
  34284. $368 = ($$7495601|0)==($$9$ph|0);
  34285. do {
  34286. if ($368) {
  34287. $372 = ((($$0)) + 1|0);
  34288. _out($0,$$0,1);
  34289. $373 = ($$5602|0)<(1);
  34290. $or$cond554 = $361 & $373;
  34291. if ($or$cond554) {
  34292. $$2 = $372;
  34293. break;
  34294. }
  34295. _out($0,19139,1);
  34296. $$2 = $372;
  34297. } else {
  34298. $369 = ($$0>>>0)>($8>>>0);
  34299. if (!($369)) {
  34300. $$2 = $$0;
  34301. break;
  34302. }
  34303. $scevgep684 = (($$0) + ($363)|0);
  34304. $scevgep684685 = $scevgep684;
  34305. _memset(($8|0),48,($scevgep684685|0))|0;
  34306. $$1598 = $$0;
  34307. while(1) {
  34308. $370 = ((($$1598)) + -1|0);
  34309. $371 = ($370>>>0)>($8>>>0);
  34310. if ($371) {
  34311. $$1598 = $370;
  34312. } else {
  34313. $$2 = $370;
  34314. break;
  34315. }
  34316. }
  34317. }
  34318. } while(0);
  34319. $374 = $$2;
  34320. $375 = (($362) - ($374))|0;
  34321. $376 = ($$5602|0)>($375|0);
  34322. $377 = $376 ? $375 : $$5602;
  34323. _out($0,$$2,$377);
  34324. $378 = (($$5602) - ($375))|0;
  34325. $379 = ((($$7495601)) + 4|0);
  34326. $380 = ($379>>>0)<($$7505$>>>0);
  34327. $381 = ($378|0)>(-1);
  34328. $382 = $380 & $381;
  34329. if ($382) {
  34330. $$5602 = $378;$$7495601 = $379;
  34331. } else {
  34332. $$5$lcssa = $378;
  34333. break;
  34334. }
  34335. }
  34336. } else {
  34337. $$5$lcssa = $$3477;
  34338. }
  34339. $383 = (($$5$lcssa) + 18)|0;
  34340. _pad_674($0,48,$383,18,0);
  34341. $384 = $11;
  34342. $385 = $$2513;
  34343. $386 = (($384) - ($385))|0;
  34344. _out($0,$$2513,$386);
  34345. }
  34346. $387 = $4 ^ 8192;
  34347. _pad_674($0,32,$2,$320,$387);
  34348. $$sink562 = $320;
  34349. } else {
  34350. $27 = $5 & 32;
  34351. $28 = ($27|0)!=(0);
  34352. $29 = $28 ? 19107 : 19111;
  34353. $30 = ($$0471 != $$0471) | (0.0 != 0.0);
  34354. $31 = $28 ? 19115 : 19119;
  34355. $$0510 = $30 ? $31 : $29;
  34356. $32 = (($$0520) + 3)|0;
  34357. $33 = $4 & -65537;
  34358. _pad_674($0,32,$2,$32,$33);
  34359. _out($0,$$0521,$$0520);
  34360. _out($0,$$0510,3);
  34361. $34 = $4 ^ 8192;
  34362. _pad_674($0,32,$2,$32,$34);
  34363. $$sink562 = $32;
  34364. }
  34365. } while(0);
  34366. $388 = ($$sink562|0)<($2|0);
  34367. $$555 = $388 ? $2 : $$sink562;
  34368. STACKTOP = sp;return ($$555|0);
  34369. }
  34370. function ___DOUBLE_BITS_675($0) {
  34371. $0 = +$0;
  34372. var $1 = 0, $2 = 0, label = 0, sp = 0;
  34373. sp = STACKTOP;
  34374. HEAPF64[tempDoublePtr>>3] = $0;$1 = HEAP32[tempDoublePtr>>2]|0;
  34375. $2 = HEAP32[tempDoublePtr+4>>2]|0;
  34376. tempRet0 = ($2);
  34377. return ($1|0);
  34378. }
  34379. function _frexpl($0,$1) {
  34380. $0 = +$0;
  34381. $1 = $1|0;
  34382. var $2 = 0.0, label = 0, sp = 0;
  34383. sp = STACKTOP;
  34384. $2 = (+_frexp($0,$1));
  34385. return (+$2);
  34386. }
  34387. function _frexp($0,$1) {
  34388. $0 = +$0;
  34389. $1 = $1|0;
  34390. var $$0 = 0.0, $$016 = 0.0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0.0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0.0, $9 = 0.0, $storemerge = 0, $trunc$clear = 0, label = 0;
  34391. var sp = 0;
  34392. sp = STACKTOP;
  34393. HEAPF64[tempDoublePtr>>3] = $0;$2 = HEAP32[tempDoublePtr>>2]|0;
  34394. $3 = HEAP32[tempDoublePtr+4>>2]|0;
  34395. $4 = (_bitshift64Lshr(($2|0),($3|0),52)|0);
  34396. $5 = tempRet0;
  34397. $6 = $4&65535;
  34398. $trunc$clear = $6 & 2047;
  34399. switch ($trunc$clear<<16>>16) {
  34400. case 0: {
  34401. $7 = $0 != 0.0;
  34402. if ($7) {
  34403. $8 = $0 * 1.8446744073709552E+19;
  34404. $9 = (+_frexp($8,$1));
  34405. $10 = HEAP32[$1>>2]|0;
  34406. $11 = (($10) + -64)|0;
  34407. $$016 = $9;$storemerge = $11;
  34408. } else {
  34409. $$016 = $0;$storemerge = 0;
  34410. }
  34411. HEAP32[$1>>2] = $storemerge;
  34412. $$0 = $$016;
  34413. break;
  34414. }
  34415. case 2047: {
  34416. $$0 = $0;
  34417. break;
  34418. }
  34419. default: {
  34420. $12 = $4 & 2047;
  34421. $13 = (($12) + -1022)|0;
  34422. HEAP32[$1>>2] = $13;
  34423. $14 = $3 & -2146435073;
  34424. $15 = $14 | 1071644672;
  34425. HEAP32[tempDoublePtr>>2] = $2;HEAP32[tempDoublePtr+4>>2] = $15;$16 = +HEAPF64[tempDoublePtr>>3];
  34426. $$0 = $16;
  34427. }
  34428. }
  34429. return (+$$0);
  34430. }
  34431. function _wcrtomb($0,$1,$2) {
  34432. $0 = $0|0;
  34433. $1 = $1|0;
  34434. $2 = $2|0;
  34435. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0;
  34436. var $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0;
  34437. var $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $not$ = 0, $or$cond = 0, label = 0, sp = 0;
  34438. sp = STACKTOP;
  34439. $3 = ($0|0)==(0|0);
  34440. do {
  34441. if ($3) {
  34442. $$0 = 1;
  34443. } else {
  34444. $4 = ($1>>>0)<(128);
  34445. if ($4) {
  34446. $5 = $1&255;
  34447. HEAP8[$0>>0] = $5;
  34448. $$0 = 1;
  34449. break;
  34450. }
  34451. $6 = (___pthread_self_448()|0);
  34452. $7 = ((($6)) + 188|0);
  34453. $8 = HEAP32[$7>>2]|0;
  34454. $9 = HEAP32[$8>>2]|0;
  34455. $not$ = ($9|0)==(0|0);
  34456. if ($not$) {
  34457. $10 = $1 & -128;
  34458. $11 = ($10|0)==(57216);
  34459. if ($11) {
  34460. $13 = $1&255;
  34461. HEAP8[$0>>0] = $13;
  34462. $$0 = 1;
  34463. break;
  34464. } else {
  34465. $12 = (___errno_location()|0);
  34466. HEAP32[$12>>2] = 84;
  34467. $$0 = -1;
  34468. break;
  34469. }
  34470. }
  34471. $14 = ($1>>>0)<(2048);
  34472. if ($14) {
  34473. $15 = $1 >>> 6;
  34474. $16 = $15 | 192;
  34475. $17 = $16&255;
  34476. $18 = ((($0)) + 1|0);
  34477. HEAP8[$0>>0] = $17;
  34478. $19 = $1 & 63;
  34479. $20 = $19 | 128;
  34480. $21 = $20&255;
  34481. HEAP8[$18>>0] = $21;
  34482. $$0 = 2;
  34483. break;
  34484. }
  34485. $22 = ($1>>>0)<(55296);
  34486. $23 = $1 & -8192;
  34487. $24 = ($23|0)==(57344);
  34488. $or$cond = $22 | $24;
  34489. if ($or$cond) {
  34490. $25 = $1 >>> 12;
  34491. $26 = $25 | 224;
  34492. $27 = $26&255;
  34493. $28 = ((($0)) + 1|0);
  34494. HEAP8[$0>>0] = $27;
  34495. $29 = $1 >>> 6;
  34496. $30 = $29 & 63;
  34497. $31 = $30 | 128;
  34498. $32 = $31&255;
  34499. $33 = ((($0)) + 2|0);
  34500. HEAP8[$28>>0] = $32;
  34501. $34 = $1 & 63;
  34502. $35 = $34 | 128;
  34503. $36 = $35&255;
  34504. HEAP8[$33>>0] = $36;
  34505. $$0 = 3;
  34506. break;
  34507. }
  34508. $37 = (($1) + -65536)|0;
  34509. $38 = ($37>>>0)<(1048576);
  34510. if ($38) {
  34511. $39 = $1 >>> 18;
  34512. $40 = $39 | 240;
  34513. $41 = $40&255;
  34514. $42 = ((($0)) + 1|0);
  34515. HEAP8[$0>>0] = $41;
  34516. $43 = $1 >>> 12;
  34517. $44 = $43 & 63;
  34518. $45 = $44 | 128;
  34519. $46 = $45&255;
  34520. $47 = ((($0)) + 2|0);
  34521. HEAP8[$42>>0] = $46;
  34522. $48 = $1 >>> 6;
  34523. $49 = $48 & 63;
  34524. $50 = $49 | 128;
  34525. $51 = $50&255;
  34526. $52 = ((($0)) + 3|0);
  34527. HEAP8[$47>>0] = $51;
  34528. $53 = $1 & 63;
  34529. $54 = $53 | 128;
  34530. $55 = $54&255;
  34531. HEAP8[$52>>0] = $55;
  34532. $$0 = 4;
  34533. break;
  34534. } else {
  34535. $56 = (___errno_location()|0);
  34536. HEAP32[$56>>2] = 84;
  34537. $$0 = -1;
  34538. break;
  34539. }
  34540. }
  34541. } while(0);
  34542. return ($$0|0);
  34543. }
  34544. function ___pthread_self_448() {
  34545. var $0 = 0, label = 0, sp = 0;
  34546. sp = STACKTOP;
  34547. $0 = (_pthread_self()|0);
  34548. return ($0|0);
  34549. }
  34550. function ___pthread_self_105() {
  34551. var $0 = 0, label = 0, sp = 0;
  34552. sp = STACKTOP;
  34553. $0 = (_pthread_self()|0);
  34554. return ($0|0);
  34555. }
  34556. function ___strerror_l($0,$1) {
  34557. $0 = $0|0;
  34558. $1 = $1|0;
  34559. var $$012$lcssa = 0, $$01214 = 0, $$016 = 0, $$113 = 0, $$115 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  34560. var label = 0, sp = 0;
  34561. sp = STACKTOP;
  34562. $$016 = 0;
  34563. while(1) {
  34564. $3 = (19141 + ($$016)|0);
  34565. $4 = HEAP8[$3>>0]|0;
  34566. $5 = $4&255;
  34567. $6 = ($5|0)==($0|0);
  34568. if ($6) {
  34569. label = 2;
  34570. break;
  34571. }
  34572. $7 = (($$016) + 1)|0;
  34573. $8 = ($7|0)==(87);
  34574. if ($8) {
  34575. $$01214 = 19229;$$115 = 87;
  34576. label = 5;
  34577. break;
  34578. } else {
  34579. $$016 = $7;
  34580. }
  34581. }
  34582. if ((label|0) == 2) {
  34583. $2 = ($$016|0)==(0);
  34584. if ($2) {
  34585. $$012$lcssa = 19229;
  34586. } else {
  34587. $$01214 = 19229;$$115 = $$016;
  34588. label = 5;
  34589. }
  34590. }
  34591. if ((label|0) == 5) {
  34592. while(1) {
  34593. label = 0;
  34594. $$113 = $$01214;
  34595. while(1) {
  34596. $9 = HEAP8[$$113>>0]|0;
  34597. $10 = ($9<<24>>24)==(0);
  34598. $11 = ((($$113)) + 1|0);
  34599. if ($10) {
  34600. break;
  34601. } else {
  34602. $$113 = $11;
  34603. }
  34604. }
  34605. $12 = (($$115) + -1)|0;
  34606. $13 = ($12|0)==(0);
  34607. if ($13) {
  34608. $$012$lcssa = $11;
  34609. break;
  34610. } else {
  34611. $$01214 = $11;$$115 = $12;
  34612. label = 5;
  34613. }
  34614. }
  34615. }
  34616. $14 = ((($1)) + 20|0);
  34617. $15 = HEAP32[$14>>2]|0;
  34618. $16 = (___lctrans($$012$lcssa,$15)|0);
  34619. return ($16|0);
  34620. }
  34621. function ___lctrans($0,$1) {
  34622. $0 = $0|0;
  34623. $1 = $1|0;
  34624. var $2 = 0, label = 0, sp = 0;
  34625. sp = STACKTOP;
  34626. $2 = (___lctrans_impl($0,$1)|0);
  34627. return ($2|0);
  34628. }
  34629. function ___lctrans_impl($0,$1) {
  34630. $0 = $0|0;
  34631. $1 = $1|0;
  34632. var $$0 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, label = 0, sp = 0;
  34633. sp = STACKTOP;
  34634. $2 = ($1|0)==(0|0);
  34635. if ($2) {
  34636. $$0 = 0;
  34637. } else {
  34638. $3 = HEAP32[$1>>2]|0;
  34639. $4 = ((($1)) + 4|0);
  34640. $5 = HEAP32[$4>>2]|0;
  34641. $6 = (___mo_lookup($3,$5,$0)|0);
  34642. $$0 = $6;
  34643. }
  34644. $7 = ($$0|0)!=(0|0);
  34645. $8 = $7 ? $$0 : $0;
  34646. return ($8|0);
  34647. }
  34648. function ___mo_lookup($0,$1,$2) {
  34649. $0 = $0|0;
  34650. $1 = $1|0;
  34651. $2 = $2|0;
  34652. var $$ = 0, $$090 = 0, $$094 = 0, $$191 = 0, $$195 = 0, $$4 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  34653. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  34654. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0;
  34655. var $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond102 = 0, $or$cond104 = 0, label = 0, sp = 0;
  34656. sp = STACKTOP;
  34657. $3 = HEAP32[$0>>2]|0;
  34658. $4 = (($3) + 1794895138)|0;
  34659. $5 = ((($0)) + 8|0);
  34660. $6 = HEAP32[$5>>2]|0;
  34661. $7 = (_swapc($6,$4)|0);
  34662. $8 = ((($0)) + 12|0);
  34663. $9 = HEAP32[$8>>2]|0;
  34664. $10 = (_swapc($9,$4)|0);
  34665. $11 = ((($0)) + 16|0);
  34666. $12 = HEAP32[$11>>2]|0;
  34667. $13 = (_swapc($12,$4)|0);
  34668. $14 = $1 >>> 2;
  34669. $15 = ($7>>>0)<($14>>>0);
  34670. L1: do {
  34671. if ($15) {
  34672. $16 = $7 << 2;
  34673. $17 = (($1) - ($16))|0;
  34674. $18 = ($10>>>0)<($17>>>0);
  34675. $19 = ($13>>>0)<($17>>>0);
  34676. $or$cond = $18 & $19;
  34677. if ($or$cond) {
  34678. $20 = $13 | $10;
  34679. $21 = $20 & 3;
  34680. $22 = ($21|0)==(0);
  34681. if ($22) {
  34682. $23 = $10 >>> 2;
  34683. $24 = $13 >>> 2;
  34684. $$090 = 0;$$094 = $7;
  34685. while(1) {
  34686. $25 = $$094 >>> 1;
  34687. $26 = (($$090) + ($25))|0;
  34688. $27 = $26 << 1;
  34689. $28 = (($27) + ($23))|0;
  34690. $29 = (($0) + ($28<<2)|0);
  34691. $30 = HEAP32[$29>>2]|0;
  34692. $31 = (_swapc($30,$4)|0);
  34693. $32 = (($28) + 1)|0;
  34694. $33 = (($0) + ($32<<2)|0);
  34695. $34 = HEAP32[$33>>2]|0;
  34696. $35 = (_swapc($34,$4)|0);
  34697. $36 = ($35>>>0)<($1>>>0);
  34698. $37 = (($1) - ($35))|0;
  34699. $38 = ($31>>>0)<($37>>>0);
  34700. $or$cond102 = $36 & $38;
  34701. if (!($or$cond102)) {
  34702. $$4 = 0;
  34703. break L1;
  34704. }
  34705. $39 = (($35) + ($31))|0;
  34706. $40 = (($0) + ($39)|0);
  34707. $41 = HEAP8[$40>>0]|0;
  34708. $42 = ($41<<24>>24)==(0);
  34709. if (!($42)) {
  34710. $$4 = 0;
  34711. break L1;
  34712. }
  34713. $43 = (($0) + ($35)|0);
  34714. $44 = (_strcmp($2,$43)|0);
  34715. $45 = ($44|0)==(0);
  34716. if ($45) {
  34717. break;
  34718. }
  34719. $62 = ($$094|0)==(1);
  34720. $63 = ($44|0)<(0);
  34721. $64 = (($$094) - ($25))|0;
  34722. $$195 = $63 ? $25 : $64;
  34723. $$191 = $63 ? $$090 : $26;
  34724. if ($62) {
  34725. $$4 = 0;
  34726. break L1;
  34727. } else {
  34728. $$090 = $$191;$$094 = $$195;
  34729. }
  34730. }
  34731. $46 = (($27) + ($24))|0;
  34732. $47 = (($0) + ($46<<2)|0);
  34733. $48 = HEAP32[$47>>2]|0;
  34734. $49 = (_swapc($48,$4)|0);
  34735. $50 = (($46) + 1)|0;
  34736. $51 = (($0) + ($50<<2)|0);
  34737. $52 = HEAP32[$51>>2]|0;
  34738. $53 = (_swapc($52,$4)|0);
  34739. $54 = ($53>>>0)<($1>>>0);
  34740. $55 = (($1) - ($53))|0;
  34741. $56 = ($49>>>0)<($55>>>0);
  34742. $or$cond104 = $54 & $56;
  34743. if ($or$cond104) {
  34744. $57 = (($0) + ($53)|0);
  34745. $58 = (($53) + ($49))|0;
  34746. $59 = (($0) + ($58)|0);
  34747. $60 = HEAP8[$59>>0]|0;
  34748. $61 = ($60<<24>>24)==(0);
  34749. $$ = $61 ? $57 : 0;
  34750. $$4 = $$;
  34751. } else {
  34752. $$4 = 0;
  34753. }
  34754. } else {
  34755. $$4 = 0;
  34756. }
  34757. } else {
  34758. $$4 = 0;
  34759. }
  34760. } else {
  34761. $$4 = 0;
  34762. }
  34763. } while(0);
  34764. return ($$4|0);
  34765. }
  34766. function _swapc($0,$1) {
  34767. $0 = $0|0;
  34768. $1 = $1|0;
  34769. var $$ = 0, $2 = 0, $3 = 0, label = 0, sp = 0;
  34770. sp = STACKTOP;
  34771. $2 = ($1|0)==(0);
  34772. $3 = (_llvm_bswap_i32(($0|0))|0);
  34773. $$ = $2 ? $0 : $3;
  34774. return ($$|0);
  34775. }
  34776. function ___fwritex($0,$1,$2) {
  34777. $0 = $0|0;
  34778. $1 = $1|0;
  34779. $2 = $2|0;
  34780. var $$038 = 0, $$042 = 0, $$1 = 0, $$139 = 0, $$141 = 0, $$143 = 0, $$pre = 0, $$pre47 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0;
  34781. var $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  34782. var label = 0, sp = 0;
  34783. sp = STACKTOP;
  34784. $3 = ((($2)) + 16|0);
  34785. $4 = HEAP32[$3>>2]|0;
  34786. $5 = ($4|0)==(0|0);
  34787. if ($5) {
  34788. $7 = (___towrite($2)|0);
  34789. $8 = ($7|0)==(0);
  34790. if ($8) {
  34791. $$pre = HEAP32[$3>>2]|0;
  34792. $12 = $$pre;
  34793. label = 5;
  34794. } else {
  34795. $$1 = 0;
  34796. }
  34797. } else {
  34798. $6 = $4;
  34799. $12 = $6;
  34800. label = 5;
  34801. }
  34802. L5: do {
  34803. if ((label|0) == 5) {
  34804. $9 = ((($2)) + 20|0);
  34805. $10 = HEAP32[$9>>2]|0;
  34806. $11 = (($12) - ($10))|0;
  34807. $13 = ($11>>>0)<($1>>>0);
  34808. $14 = $10;
  34809. if ($13) {
  34810. $15 = ((($2)) + 36|0);
  34811. $16 = HEAP32[$15>>2]|0;
  34812. $17 = (FUNCTION_TABLE_iiii[$16 & 15]($2,$0,$1)|0);
  34813. $$1 = $17;
  34814. break;
  34815. }
  34816. $18 = ((($2)) + 75|0);
  34817. $19 = HEAP8[$18>>0]|0;
  34818. $20 = ($19<<24>>24)>(-1);
  34819. L10: do {
  34820. if ($20) {
  34821. $$038 = $1;
  34822. while(1) {
  34823. $21 = ($$038|0)==(0);
  34824. if ($21) {
  34825. $$139 = 0;$$141 = $0;$$143 = $1;$31 = $14;
  34826. break L10;
  34827. }
  34828. $22 = (($$038) + -1)|0;
  34829. $23 = (($0) + ($22)|0);
  34830. $24 = HEAP8[$23>>0]|0;
  34831. $25 = ($24<<24>>24)==(10);
  34832. if ($25) {
  34833. break;
  34834. } else {
  34835. $$038 = $22;
  34836. }
  34837. }
  34838. $26 = ((($2)) + 36|0);
  34839. $27 = HEAP32[$26>>2]|0;
  34840. $28 = (FUNCTION_TABLE_iiii[$27 & 15]($2,$0,$$038)|0);
  34841. $29 = ($28>>>0)<($$038>>>0);
  34842. if ($29) {
  34843. $$1 = $28;
  34844. break L5;
  34845. }
  34846. $30 = (($0) + ($$038)|0);
  34847. $$042 = (($1) - ($$038))|0;
  34848. $$pre47 = HEAP32[$9>>2]|0;
  34849. $$139 = $$038;$$141 = $30;$$143 = $$042;$31 = $$pre47;
  34850. } else {
  34851. $$139 = 0;$$141 = $0;$$143 = $1;$31 = $14;
  34852. }
  34853. } while(0);
  34854. _memcpy(($31|0),($$141|0),($$143|0))|0;
  34855. $32 = HEAP32[$9>>2]|0;
  34856. $33 = (($32) + ($$143)|0);
  34857. HEAP32[$9>>2] = $33;
  34858. $34 = (($$139) + ($$143))|0;
  34859. $$1 = $34;
  34860. }
  34861. } while(0);
  34862. return ($$1|0);
  34863. }
  34864. function ___towrite($0) {
  34865. $0 = $0|0;
  34866. var $$0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0;
  34867. var $9 = 0, label = 0, sp = 0;
  34868. sp = STACKTOP;
  34869. $1 = ((($0)) + 74|0);
  34870. $2 = HEAP8[$1>>0]|0;
  34871. $3 = $2 << 24 >> 24;
  34872. $4 = (($3) + 255)|0;
  34873. $5 = $4 | $3;
  34874. $6 = $5&255;
  34875. HEAP8[$1>>0] = $6;
  34876. $7 = HEAP32[$0>>2]|0;
  34877. $8 = $7 & 8;
  34878. $9 = ($8|0)==(0);
  34879. if ($9) {
  34880. $11 = ((($0)) + 8|0);
  34881. HEAP32[$11>>2] = 0;
  34882. $12 = ((($0)) + 4|0);
  34883. HEAP32[$12>>2] = 0;
  34884. $13 = ((($0)) + 44|0);
  34885. $14 = HEAP32[$13>>2]|0;
  34886. $15 = ((($0)) + 28|0);
  34887. HEAP32[$15>>2] = $14;
  34888. $16 = ((($0)) + 20|0);
  34889. HEAP32[$16>>2] = $14;
  34890. $17 = ((($0)) + 48|0);
  34891. $18 = HEAP32[$17>>2]|0;
  34892. $19 = (($14) + ($18)|0);
  34893. $20 = ((($0)) + 16|0);
  34894. HEAP32[$20>>2] = $19;
  34895. $$0 = 0;
  34896. } else {
  34897. $10 = $7 | 32;
  34898. HEAP32[$0>>2] = $10;
  34899. $$0 = -1;
  34900. }
  34901. return ($$0|0);
  34902. }
  34903. function _strlen($0) {
  34904. $0 = $0|0;
  34905. var $$0 = 0, $$015$lcssa = 0, $$01519 = 0, $$1$lcssa = 0, $$pn = 0, $$pre = 0, $$sink = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0;
  34906. var $21 = 0, $22 = 0, $23 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  34907. sp = STACKTOP;
  34908. $1 = $0;
  34909. $2 = $1 & 3;
  34910. $3 = ($2|0)==(0);
  34911. L1: do {
  34912. if ($3) {
  34913. $$015$lcssa = $0;
  34914. label = 4;
  34915. } else {
  34916. $$01519 = $0;$23 = $1;
  34917. while(1) {
  34918. $4 = HEAP8[$$01519>>0]|0;
  34919. $5 = ($4<<24>>24)==(0);
  34920. if ($5) {
  34921. $$sink = $23;
  34922. break L1;
  34923. }
  34924. $6 = ((($$01519)) + 1|0);
  34925. $7 = $6;
  34926. $8 = $7 & 3;
  34927. $9 = ($8|0)==(0);
  34928. if ($9) {
  34929. $$015$lcssa = $6;
  34930. label = 4;
  34931. break;
  34932. } else {
  34933. $$01519 = $6;$23 = $7;
  34934. }
  34935. }
  34936. }
  34937. } while(0);
  34938. if ((label|0) == 4) {
  34939. $$0 = $$015$lcssa;
  34940. while(1) {
  34941. $10 = HEAP32[$$0>>2]|0;
  34942. $11 = (($10) + -16843009)|0;
  34943. $12 = $10 & -2139062144;
  34944. $13 = $12 ^ -2139062144;
  34945. $14 = $13 & $11;
  34946. $15 = ($14|0)==(0);
  34947. $16 = ((($$0)) + 4|0);
  34948. if ($15) {
  34949. $$0 = $16;
  34950. } else {
  34951. break;
  34952. }
  34953. }
  34954. $17 = $10&255;
  34955. $18 = ($17<<24>>24)==(0);
  34956. if ($18) {
  34957. $$1$lcssa = $$0;
  34958. } else {
  34959. $$pn = $$0;
  34960. while(1) {
  34961. $19 = ((($$pn)) + 1|0);
  34962. $$pre = HEAP8[$19>>0]|0;
  34963. $20 = ($$pre<<24>>24)==(0);
  34964. if ($20) {
  34965. $$1$lcssa = $19;
  34966. break;
  34967. } else {
  34968. $$pn = $19;
  34969. }
  34970. }
  34971. }
  34972. $21 = $$1$lcssa;
  34973. $$sink = $21;
  34974. }
  34975. $22 = (($$sink) - ($1))|0;
  34976. return ($22|0);
  34977. }
  34978. function _strchr($0,$1) {
  34979. $0 = $0|0;
  34980. $1 = $1|0;
  34981. var $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  34982. sp = STACKTOP;
  34983. $2 = (___strchrnul($0,$1)|0);
  34984. $3 = HEAP8[$2>>0]|0;
  34985. $4 = $1&255;
  34986. $5 = ($3<<24>>24)==($4<<24>>24);
  34987. $6 = $5 ? $2 : 0;
  34988. return ($6|0);
  34989. }
  34990. function ___strchrnul($0,$1) {
  34991. $0 = $0|0;
  34992. $1 = $1|0;
  34993. var $$0 = 0, $$029$lcssa = 0, $$02936 = 0, $$030$lcssa = 0, $$03039 = 0, $$1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0;
  34994. var $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0;
  34995. var $41 = 0, $42 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond33 = 0, label = 0, sp = 0;
  34996. sp = STACKTOP;
  34997. $2 = $1 & 255;
  34998. $3 = ($2|0)==(0);
  34999. L1: do {
  35000. if ($3) {
  35001. $8 = (_strlen($0)|0);
  35002. $9 = (($0) + ($8)|0);
  35003. $$0 = $9;
  35004. } else {
  35005. $4 = $0;
  35006. $5 = $4 & 3;
  35007. $6 = ($5|0)==(0);
  35008. if ($6) {
  35009. $$030$lcssa = $0;
  35010. } else {
  35011. $7 = $1&255;
  35012. $$03039 = $0;
  35013. while(1) {
  35014. $10 = HEAP8[$$03039>>0]|0;
  35015. $11 = ($10<<24>>24)==(0);
  35016. $12 = ($10<<24>>24)==($7<<24>>24);
  35017. $or$cond = $11 | $12;
  35018. if ($or$cond) {
  35019. $$0 = $$03039;
  35020. break L1;
  35021. }
  35022. $13 = ((($$03039)) + 1|0);
  35023. $14 = $13;
  35024. $15 = $14 & 3;
  35025. $16 = ($15|0)==(0);
  35026. if ($16) {
  35027. $$030$lcssa = $13;
  35028. break;
  35029. } else {
  35030. $$03039 = $13;
  35031. }
  35032. }
  35033. }
  35034. $17 = Math_imul($2, 16843009)|0;
  35035. $18 = HEAP32[$$030$lcssa>>2]|0;
  35036. $19 = (($18) + -16843009)|0;
  35037. $20 = $18 & -2139062144;
  35038. $21 = $20 ^ -2139062144;
  35039. $22 = $21 & $19;
  35040. $23 = ($22|0)==(0);
  35041. L10: do {
  35042. if ($23) {
  35043. $$02936 = $$030$lcssa;$25 = $18;
  35044. while(1) {
  35045. $24 = $25 ^ $17;
  35046. $26 = (($24) + -16843009)|0;
  35047. $27 = $24 & -2139062144;
  35048. $28 = $27 ^ -2139062144;
  35049. $29 = $28 & $26;
  35050. $30 = ($29|0)==(0);
  35051. if (!($30)) {
  35052. $$029$lcssa = $$02936;
  35053. break L10;
  35054. }
  35055. $31 = ((($$02936)) + 4|0);
  35056. $32 = HEAP32[$31>>2]|0;
  35057. $33 = (($32) + -16843009)|0;
  35058. $34 = $32 & -2139062144;
  35059. $35 = $34 ^ -2139062144;
  35060. $36 = $35 & $33;
  35061. $37 = ($36|0)==(0);
  35062. if ($37) {
  35063. $$02936 = $31;$25 = $32;
  35064. } else {
  35065. $$029$lcssa = $31;
  35066. break;
  35067. }
  35068. }
  35069. } else {
  35070. $$029$lcssa = $$030$lcssa;
  35071. }
  35072. } while(0);
  35073. $38 = $1&255;
  35074. $$1 = $$029$lcssa;
  35075. while(1) {
  35076. $39 = HEAP8[$$1>>0]|0;
  35077. $40 = ($39<<24>>24)==(0);
  35078. $41 = ($39<<24>>24)==($38<<24>>24);
  35079. $or$cond33 = $40 | $41;
  35080. $42 = ((($$1)) + 1|0);
  35081. if ($or$cond33) {
  35082. $$0 = $$1;
  35083. break;
  35084. } else {
  35085. $$1 = $42;
  35086. }
  35087. }
  35088. }
  35089. } while(0);
  35090. return ($$0|0);
  35091. }
  35092. function _strcpy($0,$1) {
  35093. $0 = $0|0;
  35094. $1 = $1|0;
  35095. var label = 0, sp = 0;
  35096. sp = STACKTOP;
  35097. (___stpcpy($0,$1)|0);
  35098. return ($0|0);
  35099. }
  35100. function ___stpcpy($0,$1) {
  35101. $0 = $0|0;
  35102. $1 = $1|0;
  35103. var $$0$lcssa = 0, $$025$lcssa = 0, $$02536 = 0, $$026$lcssa = 0, $$02642 = 0, $$027$lcssa = 0, $$02741 = 0, $$029 = 0, $$037 = 0, $$1$ph = 0, $$128$ph = 0, $$12834 = 0, $$135 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0;
  35104. var $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0;
  35105. var $35 = 0, $36 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  35106. sp = STACKTOP;
  35107. $2 = $1;
  35108. $3 = $0;
  35109. $4 = $2 ^ $3;
  35110. $5 = $4 & 3;
  35111. $6 = ($5|0)==(0);
  35112. L1: do {
  35113. if ($6) {
  35114. $7 = $2 & 3;
  35115. $8 = ($7|0)==(0);
  35116. if ($8) {
  35117. $$026$lcssa = $1;$$027$lcssa = $0;
  35118. } else {
  35119. $$02642 = $1;$$02741 = $0;
  35120. while(1) {
  35121. $9 = HEAP8[$$02642>>0]|0;
  35122. HEAP8[$$02741>>0] = $9;
  35123. $10 = ($9<<24>>24)==(0);
  35124. if ($10) {
  35125. $$029 = $$02741;
  35126. break L1;
  35127. }
  35128. $11 = ((($$02642)) + 1|0);
  35129. $12 = ((($$02741)) + 1|0);
  35130. $13 = $11;
  35131. $14 = $13 & 3;
  35132. $15 = ($14|0)==(0);
  35133. if ($15) {
  35134. $$026$lcssa = $11;$$027$lcssa = $12;
  35135. break;
  35136. } else {
  35137. $$02642 = $11;$$02741 = $12;
  35138. }
  35139. }
  35140. }
  35141. $16 = HEAP32[$$026$lcssa>>2]|0;
  35142. $17 = (($16) + -16843009)|0;
  35143. $18 = $16 & -2139062144;
  35144. $19 = $18 ^ -2139062144;
  35145. $20 = $19 & $17;
  35146. $21 = ($20|0)==(0);
  35147. if ($21) {
  35148. $$02536 = $$027$lcssa;$$037 = $$026$lcssa;$24 = $16;
  35149. while(1) {
  35150. $22 = ((($$037)) + 4|0);
  35151. $23 = ((($$02536)) + 4|0);
  35152. HEAP32[$$02536>>2] = $24;
  35153. $25 = HEAP32[$22>>2]|0;
  35154. $26 = (($25) + -16843009)|0;
  35155. $27 = $25 & -2139062144;
  35156. $28 = $27 ^ -2139062144;
  35157. $29 = $28 & $26;
  35158. $30 = ($29|0)==(0);
  35159. if ($30) {
  35160. $$02536 = $23;$$037 = $22;$24 = $25;
  35161. } else {
  35162. $$0$lcssa = $22;$$025$lcssa = $23;
  35163. break;
  35164. }
  35165. }
  35166. } else {
  35167. $$0$lcssa = $$026$lcssa;$$025$lcssa = $$027$lcssa;
  35168. }
  35169. $$1$ph = $$0$lcssa;$$128$ph = $$025$lcssa;
  35170. label = 8;
  35171. } else {
  35172. $$1$ph = $1;$$128$ph = $0;
  35173. label = 8;
  35174. }
  35175. } while(0);
  35176. if ((label|0) == 8) {
  35177. $31 = HEAP8[$$1$ph>>0]|0;
  35178. HEAP8[$$128$ph>>0] = $31;
  35179. $32 = ($31<<24>>24)==(0);
  35180. if ($32) {
  35181. $$029 = $$128$ph;
  35182. } else {
  35183. $$12834 = $$128$ph;$$135 = $$1$ph;
  35184. while(1) {
  35185. $33 = ((($$135)) + 1|0);
  35186. $34 = ((($$12834)) + 1|0);
  35187. $35 = HEAP8[$33>>0]|0;
  35188. HEAP8[$34>>0] = $35;
  35189. $36 = ($35<<24>>24)==(0);
  35190. if ($36) {
  35191. $$029 = $34;
  35192. break;
  35193. } else {
  35194. $$12834 = $34;$$135 = $33;
  35195. }
  35196. }
  35197. }
  35198. }
  35199. return ($$029|0);
  35200. }
  35201. function ___unlist_locked_file($0) {
  35202. $0 = $0|0;
  35203. var $$pre = 0, $$sink = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  35204. sp = STACKTOP;
  35205. $1 = ((($0)) + 68|0);
  35206. $2 = HEAP32[$1>>2]|0;
  35207. $3 = ($2|0)==(0);
  35208. if (!($3)) {
  35209. $4 = ((($0)) + 116|0);
  35210. $5 = HEAP32[$4>>2]|0;
  35211. $6 = ($5|0)==(0|0);
  35212. $$pre = ((($0)) + 112|0);
  35213. if (!($6)) {
  35214. $7 = HEAP32[$$pre>>2]|0;
  35215. $8 = ((($5)) + 112|0);
  35216. HEAP32[$8>>2] = $7;
  35217. }
  35218. $9 = HEAP32[$$pre>>2]|0;
  35219. $10 = ($9|0)==(0|0);
  35220. if ($10) {
  35221. $12 = (___pthread_self_607()|0);
  35222. $13 = ((($12)) + 232|0);
  35223. $$sink = $13;
  35224. } else {
  35225. $11 = ((($9)) + 116|0);
  35226. $$sink = $11;
  35227. }
  35228. HEAP32[$$sink>>2] = $5;
  35229. }
  35230. return;
  35231. }
  35232. function ___pthread_self_607() {
  35233. var $0 = 0, label = 0, sp = 0;
  35234. sp = STACKTOP;
  35235. $0 = (_pthread_self()|0);
  35236. return ($0|0);
  35237. }
  35238. function _fopen($0,$1) {
  35239. $0 = $0|0;
  35240. $1 = $1|0;
  35241. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $memchr = 0, $vararg_buffer = 0, $vararg_buffer3 = 0, $vararg_buffer8 = 0, $vararg_ptr1 = 0;
  35242. var $vararg_ptr2 = 0, $vararg_ptr6 = 0, $vararg_ptr7 = 0, label = 0, sp = 0;
  35243. sp = STACKTOP;
  35244. STACKTOP = STACKTOP + 48|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(48|0);
  35245. $vararg_buffer8 = sp + 32|0;
  35246. $vararg_buffer3 = sp + 16|0;
  35247. $vararg_buffer = sp;
  35248. $2 = HEAP8[$1>>0]|0;
  35249. $3 = $2 << 24 >> 24;
  35250. $memchr = (_memchr(21033,$3,4)|0);
  35251. $4 = ($memchr|0)==(0|0);
  35252. if ($4) {
  35253. $5 = (___errno_location()|0);
  35254. HEAP32[$5>>2] = 22;
  35255. $$0 = 0;
  35256. } else {
  35257. $6 = (___fmodeflags($1)|0);
  35258. $7 = $0;
  35259. $8 = $6 | 32768;
  35260. HEAP32[$vararg_buffer>>2] = $7;
  35261. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  35262. HEAP32[$vararg_ptr1>>2] = $8;
  35263. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  35264. HEAP32[$vararg_ptr2>>2] = 438;
  35265. $9 = (___syscall5(5,($vararg_buffer|0))|0);
  35266. $10 = (___syscall_ret($9)|0);
  35267. $11 = ($10|0)<(0);
  35268. if ($11) {
  35269. $$0 = 0;
  35270. } else {
  35271. $12 = $6 & 524288;
  35272. $13 = ($12|0)==(0);
  35273. if (!($13)) {
  35274. HEAP32[$vararg_buffer3>>2] = $10;
  35275. $vararg_ptr6 = ((($vararg_buffer3)) + 4|0);
  35276. HEAP32[$vararg_ptr6>>2] = 2;
  35277. $vararg_ptr7 = ((($vararg_buffer3)) + 8|0);
  35278. HEAP32[$vararg_ptr7>>2] = 1;
  35279. (___syscall221(221,($vararg_buffer3|0))|0);
  35280. }
  35281. $14 = (___fdopen($10,$1)|0);
  35282. $15 = ($14|0)==(0|0);
  35283. if ($15) {
  35284. HEAP32[$vararg_buffer8>>2] = $10;
  35285. (___syscall6(6,($vararg_buffer8|0))|0);
  35286. $$0 = 0;
  35287. } else {
  35288. $$0 = $14;
  35289. }
  35290. }
  35291. }
  35292. STACKTOP = sp;return ($$0|0);
  35293. }
  35294. function ___fmodeflags($0) {
  35295. $0 = $0|0;
  35296. var $$ = 0, $$$4 = 0, $$0 = 0, $$0$ = 0, $$2 = 0, $$2$ = 0, $$4 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0;
  35297. var $8 = 0, $9 = 0, $not$ = 0, label = 0, sp = 0;
  35298. sp = STACKTOP;
  35299. $1 = (_strchr($0,43)|0);
  35300. $2 = ($1|0)==(0|0);
  35301. $3 = HEAP8[$0>>0]|0;
  35302. $not$ = ($3<<24>>24)!=(114);
  35303. $$ = $not$&1;
  35304. $$0 = $2 ? $$ : 2;
  35305. $4 = (_strchr($0,120)|0);
  35306. $5 = ($4|0)==(0|0);
  35307. $6 = $$0 | 128;
  35308. $$0$ = $5 ? $$0 : $6;
  35309. $7 = (_strchr($0,101)|0);
  35310. $8 = ($7|0)==(0|0);
  35311. $9 = $$0$ | 524288;
  35312. $$2 = $8 ? $$0$ : $9;
  35313. $10 = ($3<<24>>24)==(114);
  35314. $11 = $$2 | 64;
  35315. $$2$ = $10 ? $$2 : $11;
  35316. $12 = ($3<<24>>24)==(119);
  35317. $13 = $$2$ | 512;
  35318. $$4 = $12 ? $13 : $$2$;
  35319. $14 = ($3<<24>>24)==(97);
  35320. $15 = $$4 | 1024;
  35321. $$$4 = $14 ? $15 : $$4;
  35322. return ($$$4|0);
  35323. }
  35324. function ___fdopen($0,$1) {
  35325. $0 = $0|0;
  35326. $1 = $1|0;
  35327. var $$0 = 0, $$pre = 0, $$pre31 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  35328. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $5 = 0, $6 = 0;
  35329. var $7 = 0, $8 = 0, $9 = 0, $memchr = 0, $vararg_buffer = 0, $vararg_buffer12 = 0, $vararg_buffer3 = 0, $vararg_buffer7 = 0, $vararg_ptr1 = 0, $vararg_ptr10 = 0, $vararg_ptr11 = 0, $vararg_ptr15 = 0, $vararg_ptr16 = 0, $vararg_ptr2 = 0, $vararg_ptr6 = 0, dest = 0, label = 0, sp = 0, stop = 0;
  35330. sp = STACKTOP;
  35331. STACKTOP = STACKTOP + 64|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(64|0);
  35332. $vararg_buffer12 = sp + 40|0;
  35333. $vararg_buffer7 = sp + 24|0;
  35334. $vararg_buffer3 = sp + 16|0;
  35335. $vararg_buffer = sp;
  35336. $2 = sp + 56|0;
  35337. $3 = HEAP8[$1>>0]|0;
  35338. $4 = $3 << 24 >> 24;
  35339. $memchr = (_memchr(21033,$4,4)|0);
  35340. $5 = ($memchr|0)==(0|0);
  35341. if ($5) {
  35342. $6 = (___errno_location()|0);
  35343. HEAP32[$6>>2] = 22;
  35344. $$0 = 0;
  35345. } else {
  35346. $7 = (_malloc(1156)|0);
  35347. $8 = ($7|0)==(0|0);
  35348. if ($8) {
  35349. $$0 = 0;
  35350. } else {
  35351. dest=$7; stop=dest+124|0; do { HEAP32[dest>>2]=0|0; dest=dest+4|0; } while ((dest|0) < (stop|0));
  35352. $9 = (_strchr($1,43)|0);
  35353. $10 = ($9|0)==(0|0);
  35354. if ($10) {
  35355. $11 = ($3<<24>>24)==(114);
  35356. $12 = $11 ? 8 : 4;
  35357. HEAP32[$7>>2] = $12;
  35358. }
  35359. $13 = (_strchr($1,101)|0);
  35360. $14 = ($13|0)==(0|0);
  35361. if ($14) {
  35362. $16 = $3;
  35363. } else {
  35364. HEAP32[$vararg_buffer>>2] = $0;
  35365. $vararg_ptr1 = ((($vararg_buffer)) + 4|0);
  35366. HEAP32[$vararg_ptr1>>2] = 2;
  35367. $vararg_ptr2 = ((($vararg_buffer)) + 8|0);
  35368. HEAP32[$vararg_ptr2>>2] = 1;
  35369. (___syscall221(221,($vararg_buffer|0))|0);
  35370. $$pre = HEAP8[$1>>0]|0;
  35371. $16 = $$pre;
  35372. }
  35373. $15 = ($16<<24>>24)==(97);
  35374. if ($15) {
  35375. HEAP32[$vararg_buffer3>>2] = $0;
  35376. $vararg_ptr6 = ((($vararg_buffer3)) + 4|0);
  35377. HEAP32[$vararg_ptr6>>2] = 3;
  35378. $17 = (___syscall221(221,($vararg_buffer3|0))|0);
  35379. $18 = $17 & 1024;
  35380. $19 = ($18|0)==(0);
  35381. if ($19) {
  35382. $20 = $17 | 1024;
  35383. HEAP32[$vararg_buffer7>>2] = $0;
  35384. $vararg_ptr10 = ((($vararg_buffer7)) + 4|0);
  35385. HEAP32[$vararg_ptr10>>2] = 4;
  35386. $vararg_ptr11 = ((($vararg_buffer7)) + 8|0);
  35387. HEAP32[$vararg_ptr11>>2] = $20;
  35388. (___syscall221(221,($vararg_buffer7|0))|0);
  35389. }
  35390. $21 = HEAP32[$7>>2]|0;
  35391. $22 = $21 | 128;
  35392. HEAP32[$7>>2] = $22;
  35393. $29 = $22;
  35394. } else {
  35395. $$pre31 = HEAP32[$7>>2]|0;
  35396. $29 = $$pre31;
  35397. }
  35398. $23 = ((($7)) + 60|0);
  35399. HEAP32[$23>>2] = $0;
  35400. $24 = ((($7)) + 132|0);
  35401. $25 = ((($7)) + 44|0);
  35402. HEAP32[$25>>2] = $24;
  35403. $26 = ((($7)) + 48|0);
  35404. HEAP32[$26>>2] = 1024;
  35405. $27 = ((($7)) + 75|0);
  35406. HEAP8[$27>>0] = -1;
  35407. $28 = $29 & 8;
  35408. $30 = ($28|0)==(0);
  35409. if ($30) {
  35410. $31 = $2;
  35411. HEAP32[$vararg_buffer12>>2] = $0;
  35412. $vararg_ptr15 = ((($vararg_buffer12)) + 4|0);
  35413. HEAP32[$vararg_ptr15>>2] = 21523;
  35414. $vararg_ptr16 = ((($vararg_buffer12)) + 8|0);
  35415. HEAP32[$vararg_ptr16>>2] = $31;
  35416. $32 = (___syscall54(54,($vararg_buffer12|0))|0);
  35417. $33 = ($32|0)==(0);
  35418. if ($33) {
  35419. HEAP8[$27>>0] = 10;
  35420. }
  35421. }
  35422. $34 = ((($7)) + 32|0);
  35423. HEAP32[$34>>2] = 10;
  35424. $35 = ((($7)) + 36|0);
  35425. HEAP32[$35>>2] = 9;
  35426. $36 = ((($7)) + 40|0);
  35427. HEAP32[$36>>2] = 3;
  35428. $37 = ((($7)) + 12|0);
  35429. HEAP32[$37>>2] = 2;
  35430. $38 = HEAP32[(23620)>>2]|0;
  35431. $39 = ($38|0)==(0);
  35432. if ($39) {
  35433. $40 = ((($7)) + 76|0);
  35434. HEAP32[$40>>2] = -1;
  35435. }
  35436. $41 = (___ofl_add($7)|0);
  35437. $$0 = $7;
  35438. }
  35439. }
  35440. STACKTOP = sp;return ($$0|0);
  35441. }
  35442. function ___ofl_add($0) {
  35443. $0 = $0|0;
  35444. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, label = 0, sp = 0;
  35445. sp = STACKTOP;
  35446. $1 = (___ofl_lock()|0);
  35447. $2 = HEAP32[$1>>2]|0;
  35448. $3 = ((($0)) + 56|0);
  35449. HEAP32[$3>>2] = $2;
  35450. $4 = HEAP32[$1>>2]|0;
  35451. $5 = ($4|0)==(0|0);
  35452. if (!($5)) {
  35453. $6 = ((($4)) + 52|0);
  35454. HEAP32[$6>>2] = $0;
  35455. }
  35456. HEAP32[$1>>2] = $0;
  35457. ___ofl_unlock();
  35458. return ($0|0);
  35459. }
  35460. function ___ofl_lock() {
  35461. var label = 0, sp = 0;
  35462. sp = STACKTOP;
  35463. ___lock((23680|0));
  35464. return (23688|0);
  35465. }
  35466. function ___ofl_unlock() {
  35467. var label = 0, sp = 0;
  35468. sp = STACKTOP;
  35469. ___unlock((23680|0));
  35470. return;
  35471. }
  35472. function _fclose($0) {
  35473. $0 = $0|0;
  35474. var $$pre = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  35475. var $27 = 0, $28 = 0, $29 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  35476. sp = STACKTOP;
  35477. $1 = ((($0)) + 76|0);
  35478. $2 = HEAP32[$1>>2]|0;
  35479. $3 = ($2|0)>(-1);
  35480. if ($3) {
  35481. $4 = (___lockfile($0)|0);
  35482. $29 = $4;
  35483. } else {
  35484. $29 = 0;
  35485. }
  35486. ___unlist_locked_file($0);
  35487. $5 = HEAP32[$0>>2]|0;
  35488. $6 = $5 & 1;
  35489. $7 = ($6|0)!=(0);
  35490. if (!($7)) {
  35491. $8 = (___ofl_lock()|0);
  35492. $9 = ((($0)) + 52|0);
  35493. $10 = HEAP32[$9>>2]|0;
  35494. $11 = ($10|0)==(0|0);
  35495. $12 = $10;
  35496. $$pre = ((($0)) + 56|0);
  35497. if (!($11)) {
  35498. $13 = HEAP32[$$pre>>2]|0;
  35499. $14 = ((($10)) + 56|0);
  35500. HEAP32[$14>>2] = $13;
  35501. }
  35502. $15 = HEAP32[$$pre>>2]|0;
  35503. $16 = ($15|0)==(0|0);
  35504. if (!($16)) {
  35505. $17 = ((($15)) + 52|0);
  35506. HEAP32[$17>>2] = $12;
  35507. }
  35508. $18 = HEAP32[$8>>2]|0;
  35509. $19 = ($18|0)==($0|0);
  35510. if ($19) {
  35511. HEAP32[$8>>2] = $15;
  35512. }
  35513. ___ofl_unlock();
  35514. }
  35515. $20 = (_fflush($0)|0);
  35516. $21 = ((($0)) + 12|0);
  35517. $22 = HEAP32[$21>>2]|0;
  35518. $23 = (FUNCTION_TABLE_ii[$22 & 15]($0)|0);
  35519. $24 = $23 | $20;
  35520. $25 = ((($0)) + 92|0);
  35521. $26 = HEAP32[$25>>2]|0;
  35522. $27 = ($26|0)==(0|0);
  35523. if (!($27)) {
  35524. _free($26);
  35525. }
  35526. if ($7) {
  35527. $28 = ($29|0)==(0);
  35528. if (!($28)) {
  35529. ___unlockfile($0);
  35530. }
  35531. } else {
  35532. _free($0);
  35533. }
  35534. return ($24|0);
  35535. }
  35536. function _fflush($0) {
  35537. $0 = $0|0;
  35538. var $$0 = 0, $$023 = 0, $$02325 = 0, $$02327 = 0, $$024$lcssa = 0, $$02426 = 0, $$1 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0;
  35539. var $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $phitmp = 0, label = 0, sp = 0;
  35540. sp = STACKTOP;
  35541. $1 = ($0|0)==(0|0);
  35542. do {
  35543. if ($1) {
  35544. $8 = HEAP32[1370]|0;
  35545. $9 = ($8|0)==(0|0);
  35546. if ($9) {
  35547. $29 = 0;
  35548. } else {
  35549. $10 = HEAP32[1370]|0;
  35550. $11 = (_fflush($10)|0);
  35551. $29 = $11;
  35552. }
  35553. $12 = (___ofl_lock()|0);
  35554. $$02325 = HEAP32[$12>>2]|0;
  35555. $13 = ($$02325|0)==(0|0);
  35556. if ($13) {
  35557. $$024$lcssa = $29;
  35558. } else {
  35559. $$02327 = $$02325;$$02426 = $29;
  35560. while(1) {
  35561. $14 = ((($$02327)) + 76|0);
  35562. $15 = HEAP32[$14>>2]|0;
  35563. $16 = ($15|0)>(-1);
  35564. if ($16) {
  35565. $17 = (___lockfile($$02327)|0);
  35566. $26 = $17;
  35567. } else {
  35568. $26 = 0;
  35569. }
  35570. $18 = ((($$02327)) + 20|0);
  35571. $19 = HEAP32[$18>>2]|0;
  35572. $20 = ((($$02327)) + 28|0);
  35573. $21 = HEAP32[$20>>2]|0;
  35574. $22 = ($19>>>0)>($21>>>0);
  35575. if ($22) {
  35576. $23 = (___fflush_unlocked($$02327)|0);
  35577. $24 = $23 | $$02426;
  35578. $$1 = $24;
  35579. } else {
  35580. $$1 = $$02426;
  35581. }
  35582. $25 = ($26|0)==(0);
  35583. if (!($25)) {
  35584. ___unlockfile($$02327);
  35585. }
  35586. $27 = ((($$02327)) + 56|0);
  35587. $$023 = HEAP32[$27>>2]|0;
  35588. $28 = ($$023|0)==(0|0);
  35589. if ($28) {
  35590. $$024$lcssa = $$1;
  35591. break;
  35592. } else {
  35593. $$02327 = $$023;$$02426 = $$1;
  35594. }
  35595. }
  35596. }
  35597. ___ofl_unlock();
  35598. $$0 = $$024$lcssa;
  35599. } else {
  35600. $2 = ((($0)) + 76|0);
  35601. $3 = HEAP32[$2>>2]|0;
  35602. $4 = ($3|0)>(-1);
  35603. if (!($4)) {
  35604. $5 = (___fflush_unlocked($0)|0);
  35605. $$0 = $5;
  35606. break;
  35607. }
  35608. $6 = (___lockfile($0)|0);
  35609. $phitmp = ($6|0)==(0);
  35610. $7 = (___fflush_unlocked($0)|0);
  35611. if ($phitmp) {
  35612. $$0 = $7;
  35613. } else {
  35614. ___unlockfile($0);
  35615. $$0 = $7;
  35616. }
  35617. }
  35618. } while(0);
  35619. return ($$0|0);
  35620. }
  35621. function ___fflush_unlocked($0) {
  35622. $0 = $0|0;
  35623. var $$0 = 0, $1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0;
  35624. var $9 = 0, label = 0, sp = 0;
  35625. sp = STACKTOP;
  35626. $1 = ((($0)) + 20|0);
  35627. $2 = HEAP32[$1>>2]|0;
  35628. $3 = ((($0)) + 28|0);
  35629. $4 = HEAP32[$3>>2]|0;
  35630. $5 = ($2>>>0)>($4>>>0);
  35631. if ($5) {
  35632. $6 = ((($0)) + 36|0);
  35633. $7 = HEAP32[$6>>2]|0;
  35634. (FUNCTION_TABLE_iiii[$7 & 15]($0,0,0)|0);
  35635. $8 = HEAP32[$1>>2]|0;
  35636. $9 = ($8|0)==(0|0);
  35637. if ($9) {
  35638. $$0 = -1;
  35639. } else {
  35640. label = 3;
  35641. }
  35642. } else {
  35643. label = 3;
  35644. }
  35645. if ((label|0) == 3) {
  35646. $10 = ((($0)) + 4|0);
  35647. $11 = HEAP32[$10>>2]|0;
  35648. $12 = ((($0)) + 8|0);
  35649. $13 = HEAP32[$12>>2]|0;
  35650. $14 = ($11>>>0)<($13>>>0);
  35651. if ($14) {
  35652. $15 = $11;
  35653. $16 = $13;
  35654. $17 = (($15) - ($16))|0;
  35655. $18 = ((($0)) + 40|0);
  35656. $19 = HEAP32[$18>>2]|0;
  35657. (FUNCTION_TABLE_iiii[$19 & 15]($0,$17,1)|0);
  35658. }
  35659. $20 = ((($0)) + 16|0);
  35660. HEAP32[$20>>2] = 0;
  35661. HEAP32[$3>>2] = 0;
  35662. HEAP32[$1>>2] = 0;
  35663. HEAP32[$12>>2] = 0;
  35664. HEAP32[$10>>2] = 0;
  35665. $$0 = 0;
  35666. }
  35667. return ($$0|0);
  35668. }
  35669. function _feof($0) {
  35670. $0 = $0|0;
  35671. var $$lobit = 0, $$lobit8 = 0, $$lobit9 = 0, $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $phitmp = 0, label = 0, sp = 0;
  35672. sp = STACKTOP;
  35673. $1 = ((($0)) + 76|0);
  35674. $2 = HEAP32[$1>>2]|0;
  35675. $3 = ($2|0)>(-1);
  35676. if ($3) {
  35677. $6 = (___lockfile($0)|0);
  35678. $phitmp = ($6|0)==(0);
  35679. $7 = HEAP32[$0>>2]|0;
  35680. $8 = $7 >>> 4;
  35681. $$lobit = $8 & 1;
  35682. if ($phitmp) {
  35683. $$lobit9 = $$lobit;
  35684. } else {
  35685. ___unlockfile($0);
  35686. $$lobit9 = $$lobit;
  35687. }
  35688. } else {
  35689. $4 = HEAP32[$0>>2]|0;
  35690. $5 = $4 >>> 4;
  35691. $$lobit8 = $5 & 1;
  35692. $$lobit9 = $$lobit8;
  35693. }
  35694. return ($$lobit9|0);
  35695. }
  35696. function _fseek($0,$1,$2) {
  35697. $0 = $0|0;
  35698. $1 = $1|0;
  35699. $2 = $2|0;
  35700. var $3 = 0, label = 0, sp = 0;
  35701. sp = STACKTOP;
  35702. $3 = (___fseeko($0,$1,$2)|0);
  35703. return ($3|0);
  35704. }
  35705. function ___fseeko($0,$1,$2) {
  35706. $0 = $0|0;
  35707. $1 = $1|0;
  35708. $2 = $2|0;
  35709. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $phitmp = 0, label = 0, sp = 0;
  35710. sp = STACKTOP;
  35711. $3 = ((($0)) + 76|0);
  35712. $4 = HEAP32[$3>>2]|0;
  35713. $5 = ($4|0)>(-1);
  35714. if ($5) {
  35715. $7 = (___lockfile($0)|0);
  35716. $phitmp = ($7|0)==(0);
  35717. $8 = (___fseeko_unlocked($0,$1,$2)|0);
  35718. if ($phitmp) {
  35719. $9 = $8;
  35720. } else {
  35721. ___unlockfile($0);
  35722. $9 = $8;
  35723. }
  35724. } else {
  35725. $6 = (___fseeko_unlocked($0,$1,$2)|0);
  35726. $9 = $6;
  35727. }
  35728. return ($9|0);
  35729. }
  35730. function ___fseeko_unlocked($0,$1,$2) {
  35731. $0 = $0|0;
  35732. $1 = $1|0;
  35733. $2 = $2|0;
  35734. var $$0 = 0, $$019 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0;
  35735. var $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  35736. sp = STACKTOP;
  35737. $3 = ($2|0)==(1);
  35738. if ($3) {
  35739. $4 = ((($0)) + 8|0);
  35740. $5 = HEAP32[$4>>2]|0;
  35741. $6 = ((($0)) + 4|0);
  35742. $7 = HEAP32[$6>>2]|0;
  35743. $8 = (($1) - ($5))|0;
  35744. $9 = (($8) + ($7))|0;
  35745. $$019 = $9;
  35746. } else {
  35747. $$019 = $1;
  35748. }
  35749. $10 = ((($0)) + 20|0);
  35750. $11 = HEAP32[$10>>2]|0;
  35751. $12 = ((($0)) + 28|0);
  35752. $13 = HEAP32[$12>>2]|0;
  35753. $14 = ($11>>>0)>($13>>>0);
  35754. if ($14) {
  35755. $15 = ((($0)) + 36|0);
  35756. $16 = HEAP32[$15>>2]|0;
  35757. (FUNCTION_TABLE_iiii[$16 & 15]($0,0,0)|0);
  35758. $17 = HEAP32[$10>>2]|0;
  35759. $18 = ($17|0)==(0|0);
  35760. if ($18) {
  35761. $$0 = -1;
  35762. } else {
  35763. label = 5;
  35764. }
  35765. } else {
  35766. label = 5;
  35767. }
  35768. if ((label|0) == 5) {
  35769. $19 = ((($0)) + 16|0);
  35770. HEAP32[$19>>2] = 0;
  35771. HEAP32[$12>>2] = 0;
  35772. HEAP32[$10>>2] = 0;
  35773. $20 = ((($0)) + 40|0);
  35774. $21 = HEAP32[$20>>2]|0;
  35775. $22 = (FUNCTION_TABLE_iiii[$21 & 15]($0,$$019,$2)|0);
  35776. $23 = ($22|0)<(0);
  35777. if ($23) {
  35778. $$0 = -1;
  35779. } else {
  35780. $24 = ((($0)) + 8|0);
  35781. HEAP32[$24>>2] = 0;
  35782. $25 = ((($0)) + 4|0);
  35783. HEAP32[$25>>2] = 0;
  35784. $26 = HEAP32[$0>>2]|0;
  35785. $27 = $26 & -17;
  35786. HEAP32[$0>>2] = $27;
  35787. $$0 = 0;
  35788. }
  35789. }
  35790. return ($$0|0);
  35791. }
  35792. function _strstr($0,$1) {
  35793. $0 = $0|0;
  35794. $1 = $1|0;
  35795. var $$0 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0;
  35796. var $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  35797. sp = STACKTOP;
  35798. $2 = HEAP8[$1>>0]|0;
  35799. $3 = ($2<<24>>24)==(0);
  35800. do {
  35801. if ($3) {
  35802. $$0 = $0;
  35803. } else {
  35804. $4 = $2 << 24 >> 24;
  35805. $5 = (_strchr($0,$4)|0);
  35806. $6 = ($5|0)==(0|0);
  35807. if ($6) {
  35808. $$0 = 0;
  35809. } else {
  35810. $7 = ((($1)) + 1|0);
  35811. $8 = HEAP8[$7>>0]|0;
  35812. $9 = ($8<<24>>24)==(0);
  35813. if ($9) {
  35814. $$0 = $5;
  35815. } else {
  35816. $10 = ((($5)) + 1|0);
  35817. $11 = HEAP8[$10>>0]|0;
  35818. $12 = ($11<<24>>24)==(0);
  35819. if ($12) {
  35820. $$0 = 0;
  35821. } else {
  35822. $13 = ((($1)) + 2|0);
  35823. $14 = HEAP8[$13>>0]|0;
  35824. $15 = ($14<<24>>24)==(0);
  35825. if ($15) {
  35826. $16 = (_twobyte_strstr($5,$1)|0);
  35827. $$0 = $16;
  35828. break;
  35829. }
  35830. $17 = ((($5)) + 2|0);
  35831. $18 = HEAP8[$17>>0]|0;
  35832. $19 = ($18<<24>>24)==(0);
  35833. if ($19) {
  35834. $$0 = 0;
  35835. } else {
  35836. $20 = ((($1)) + 3|0);
  35837. $21 = HEAP8[$20>>0]|0;
  35838. $22 = ($21<<24>>24)==(0);
  35839. if ($22) {
  35840. $23 = (_threebyte_strstr($5,$1)|0);
  35841. $$0 = $23;
  35842. break;
  35843. }
  35844. $24 = ((($5)) + 3|0);
  35845. $25 = HEAP8[$24>>0]|0;
  35846. $26 = ($25<<24>>24)==(0);
  35847. if ($26) {
  35848. $$0 = 0;
  35849. } else {
  35850. $27 = ((($1)) + 4|0);
  35851. $28 = HEAP8[$27>>0]|0;
  35852. $29 = ($28<<24>>24)==(0);
  35853. if ($29) {
  35854. $30 = (_fourbyte_strstr($5,$1)|0);
  35855. $$0 = $30;
  35856. break;
  35857. } else {
  35858. $31 = (_twoway_strstr($5,$1)|0);
  35859. $$0 = $31;
  35860. break;
  35861. }
  35862. }
  35863. }
  35864. }
  35865. }
  35866. }
  35867. }
  35868. } while(0);
  35869. return ($$0|0);
  35870. }
  35871. function _twobyte_strstr($0,$1) {
  35872. $0 = $0|0;
  35873. $1 = $1|0;
  35874. var $$lcssa = 0, $$sink = 0, $$sink$in = 0, $$sink$masked = 0, $$sink17$sink = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0;
  35875. var label = 0, sp = 0;
  35876. sp = STACKTOP;
  35877. $2 = HEAP8[$1>>0]|0;
  35878. $3 = $2&255;
  35879. $4 = $3 << 8;
  35880. $5 = ((($1)) + 1|0);
  35881. $6 = HEAP8[$5>>0]|0;
  35882. $7 = $6&255;
  35883. $8 = $4 | $7;
  35884. $9 = HEAP8[$0>>0]|0;
  35885. $10 = $9&255;
  35886. $$sink$in = $10;$$sink17$sink = $0;
  35887. while(1) {
  35888. $11 = ((($$sink17$sink)) + 1|0);
  35889. $12 = HEAP8[$11>>0]|0;
  35890. $13 = ($12<<24>>24)==(0);
  35891. if ($13) {
  35892. $$lcssa = 0;
  35893. break;
  35894. }
  35895. $$sink = $$sink$in << 8;
  35896. $14 = $12&255;
  35897. $$sink$masked = $$sink & 65280;
  35898. $15 = $14 | $$sink$masked;
  35899. $16 = ($15|0)==($8|0);
  35900. if ($16) {
  35901. $$lcssa = $$sink17$sink;
  35902. break;
  35903. } else {
  35904. $$sink$in = $15;$$sink17$sink = $11;
  35905. }
  35906. }
  35907. return ($$lcssa|0);
  35908. }
  35909. function _threebyte_strstr($0,$1) {
  35910. $0 = $0|0;
  35911. $1 = $1|0;
  35912. var $$016$lcssa = 0, $$01619 = 0, $$020 = 0, $$lcssa = 0, $$not = 0, $$not17 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0;
  35913. var $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $4 = 0, $5 = 0, $6 = 0;
  35914. var $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond18 = 0, label = 0, sp = 0;
  35915. sp = STACKTOP;
  35916. $2 = HEAP8[$1>>0]|0;
  35917. $3 = $2&255;
  35918. $4 = $3 << 24;
  35919. $5 = ((($1)) + 1|0);
  35920. $6 = HEAP8[$5>>0]|0;
  35921. $7 = $6&255;
  35922. $8 = $7 << 16;
  35923. $9 = $8 | $4;
  35924. $10 = ((($1)) + 2|0);
  35925. $11 = HEAP8[$10>>0]|0;
  35926. $12 = $11&255;
  35927. $13 = $12 << 8;
  35928. $14 = $9 | $13;
  35929. $15 = HEAP8[$0>>0]|0;
  35930. $16 = $15&255;
  35931. $17 = $16 << 24;
  35932. $18 = ((($0)) + 1|0);
  35933. $19 = HEAP8[$18>>0]|0;
  35934. $20 = $19&255;
  35935. $21 = $20 << 16;
  35936. $22 = $21 | $17;
  35937. $23 = ((($0)) + 2|0);
  35938. $24 = HEAP8[$23>>0]|0;
  35939. $25 = $24&255;
  35940. $26 = $25 << 8;
  35941. $27 = $22 | $26;
  35942. $28 = ($24<<24>>24)!=(0);
  35943. $$not17 = $28 ^ 1;
  35944. $29 = ($27|0)==($14|0);
  35945. $or$cond18 = $29 | $$not17;
  35946. if ($or$cond18) {
  35947. $$016$lcssa = $23;$$lcssa = $28;
  35948. } else {
  35949. $$01619 = $23;$$020 = $27;
  35950. while(1) {
  35951. $30 = ((($$01619)) + 1|0);
  35952. $31 = HEAP8[$30>>0]|0;
  35953. $32 = $31&255;
  35954. $33 = $32 | $$020;
  35955. $34 = $33 << 8;
  35956. $35 = ($31<<24>>24)!=(0);
  35957. $$not = $35 ^ 1;
  35958. $36 = ($34|0)==($14|0);
  35959. $or$cond = $36 | $$not;
  35960. if ($or$cond) {
  35961. $$016$lcssa = $30;$$lcssa = $35;
  35962. break;
  35963. } else {
  35964. $$01619 = $30;$$020 = $34;
  35965. }
  35966. }
  35967. }
  35968. $37 = ((($$016$lcssa)) + -2|0);
  35969. $38 = $$lcssa ? $37 : 0;
  35970. return ($38|0);
  35971. }
  35972. function _fourbyte_strstr($0,$1) {
  35973. $0 = $0|0;
  35974. $1 = $1|0;
  35975. var $$lcssa = 0, $$not = 0, $$not22 = 0, $$sink21$lcssa = 0, $$sink2124 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  35976. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  35977. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $or$cond = 0, $or$cond23 = 0, label = 0, sp = 0;
  35978. sp = STACKTOP;
  35979. $2 = HEAP8[$1>>0]|0;
  35980. $3 = $2&255;
  35981. $4 = $3 << 24;
  35982. $5 = ((($1)) + 1|0);
  35983. $6 = HEAP8[$5>>0]|0;
  35984. $7 = $6&255;
  35985. $8 = $7 << 16;
  35986. $9 = $8 | $4;
  35987. $10 = ((($1)) + 2|0);
  35988. $11 = HEAP8[$10>>0]|0;
  35989. $12 = $11&255;
  35990. $13 = $12 << 8;
  35991. $14 = $9 | $13;
  35992. $15 = ((($1)) + 3|0);
  35993. $16 = HEAP8[$15>>0]|0;
  35994. $17 = $16&255;
  35995. $18 = $14 | $17;
  35996. $19 = HEAP8[$0>>0]|0;
  35997. $20 = $19&255;
  35998. $21 = $20 << 24;
  35999. $22 = ((($0)) + 1|0);
  36000. $23 = HEAP8[$22>>0]|0;
  36001. $24 = $23&255;
  36002. $25 = $24 << 16;
  36003. $26 = $25 | $21;
  36004. $27 = ((($0)) + 2|0);
  36005. $28 = HEAP8[$27>>0]|0;
  36006. $29 = $28&255;
  36007. $30 = $29 << 8;
  36008. $31 = $26 | $30;
  36009. $32 = ((($0)) + 3|0);
  36010. $33 = HEAP8[$32>>0]|0;
  36011. $34 = $33&255;
  36012. $35 = $34 | $31;
  36013. $36 = ($33<<24>>24)!=(0);
  36014. $$not22 = $36 ^ 1;
  36015. $37 = ($35|0)==($18|0);
  36016. $or$cond23 = $37 | $$not22;
  36017. if ($or$cond23) {
  36018. $$lcssa = $36;$$sink21$lcssa = $32;
  36019. } else {
  36020. $$sink2124 = $32;$39 = $35;
  36021. while(1) {
  36022. $38 = $39 << 8;
  36023. $40 = ((($$sink2124)) + 1|0);
  36024. $41 = HEAP8[$40>>0]|0;
  36025. $42 = $41&255;
  36026. $43 = $42 | $38;
  36027. $44 = ($41<<24>>24)!=(0);
  36028. $$not = $44 ^ 1;
  36029. $45 = ($43|0)==($18|0);
  36030. $or$cond = $45 | $$not;
  36031. if ($or$cond) {
  36032. $$lcssa = $44;$$sink21$lcssa = $40;
  36033. break;
  36034. } else {
  36035. $$sink2124 = $40;$39 = $43;
  36036. }
  36037. }
  36038. }
  36039. $46 = ((($$sink21$lcssa)) + -3|0);
  36040. $47 = $$lcssa ? $46 : 0;
  36041. return ($47|0);
  36042. }
  36043. function _twoway_strstr($0,$1) {
  36044. $0 = $0|0;
  36045. $1 = $1|0;
  36046. var $$0166 = 0, $$0168 = 0, $$0169 = 0, $$0169$be = 0, $$0170 = 0, $$0175$ph$ph$lcssa220 = 0, $$0175$ph$ph$lcssa220323 = 0, $$0175$ph$ph256 = 0, $$0179244 = 0, $$0183$ph200$ph255 = 0, $$0183$ph200250 = 0, $$0183$ph262 = 0, $$0185$ph$lcssa = 0, $$0185$ph$lcssa322 = 0, $$0185$ph261 = 0, $$0187$lcssa320321 = 0, $$0187266 = 0, $$1176$$0175 = 0, $$1176$ph$ph$lcssa211 = 0, $$1176$ph$ph235 = 0;
  36047. var $$1180224 = 0, $$1184$ph196$ph234 = 0, $$1184$ph196229 = 0, $$1184$ph241 = 0, $$1186$$0185 = 0, $$1186$$0185$ = 0, $$1186$ph$lcssa = 0, $$1186$ph240 = 0, $$2181 = 0, $$2181$sink = 0, $$3 = 0, $$3173 = 0, $$3178 = 0, $$3182223 = 0, $$4 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0;
  36048. var $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0;
  36049. var $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0;
  36050. var $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0;
  36051. var $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0;
  36052. var $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0;
  36053. var $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0;
  36054. var $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0, $cond = 0, $cond191 = 0, $cond191222 = 0, $cond265 = 0, $div = 0, $div188 = 0, $or$cond = 0, $or$cond190 = 0, label = 0, sp = 0;
  36055. sp = STACKTOP;
  36056. STACKTOP = STACKTOP + 1056|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(1056|0);
  36057. $2 = sp + 1024|0;
  36058. $3 = sp;
  36059. ;HEAP32[$2>>2]=0|0;HEAP32[$2+4>>2]=0|0;HEAP32[$2+8>>2]=0|0;HEAP32[$2+12>>2]=0|0;HEAP32[$2+16>>2]=0|0;HEAP32[$2+20>>2]=0|0;HEAP32[$2+24>>2]=0|0;HEAP32[$2+28>>2]=0|0;
  36060. $4 = HEAP8[$1>>0]|0;
  36061. $cond265 = ($4<<24>>24)==(0);
  36062. L1: do {
  36063. if ($cond265) {
  36064. $$0175$ph$ph$lcssa220323 = 1;$$0185$ph$lcssa322 = -1;$$0187$lcssa320321 = 0;$$1176$ph$ph$lcssa211 = 1;$$1186$ph$lcssa = -1;
  36065. label = 27;
  36066. } else {
  36067. $5 = $4&255;
  36068. $$0187266 = 0;$12 = $4;$20 = $5;
  36069. while(1) {
  36070. $8 = (($0) + ($$0187266)|0);
  36071. $9 = HEAP8[$8>>0]|0;
  36072. $10 = ($9<<24>>24)==(0);
  36073. if ($10) {
  36074. $$3 = 0;
  36075. break L1;
  36076. }
  36077. $11 = $12 & 31;
  36078. $13 = $11&255;
  36079. $14 = 1 << $13;
  36080. $div188 = ($12&255) >>> 5;
  36081. $15 = $div188&255;
  36082. $16 = (($2) + ($15<<2)|0);
  36083. $17 = HEAP32[$16>>2]|0;
  36084. $18 = $17 | $14;
  36085. HEAP32[$16>>2] = $18;
  36086. $7 = (($$0187266) + 1)|0;
  36087. $19 = (($3) + ($20<<2)|0);
  36088. HEAP32[$19>>2] = $7;
  36089. $21 = (($1) + ($7)|0);
  36090. $22 = HEAP8[$21>>0]|0;
  36091. $23 = $22&255;
  36092. $cond = ($22<<24>>24)==(0);
  36093. if ($cond) {
  36094. break;
  36095. } else {
  36096. $$0187266 = $7;$12 = $22;$20 = $23;
  36097. }
  36098. }
  36099. $6 = ($7>>>0)>(1);
  36100. if ($6) {
  36101. $$0183$ph262 = 0;$$0185$ph261 = -1;$129 = 1;
  36102. L7: while(1) {
  36103. $$0175$ph$ph256 = 1;$$0183$ph200$ph255 = $$0183$ph262;$132 = $129;
  36104. while(1) {
  36105. $$0183$ph200250 = $$0183$ph200$ph255;$131 = $132;
  36106. L11: while(1) {
  36107. $$0179244 = 1;$31 = $131;
  36108. while(1) {
  36109. $27 = (($$0179244) + ($$0185$ph261))|0;
  36110. $28 = (($1) + ($27)|0);
  36111. $29 = HEAP8[$28>>0]|0;
  36112. $30 = (($1) + ($31)|0);
  36113. $32 = HEAP8[$30>>0]|0;
  36114. $33 = ($29<<24>>24)==($32<<24>>24);
  36115. if (!($33)) {
  36116. break L11;
  36117. }
  36118. $34 = ($$0179244|0)==($$0175$ph$ph256|0);
  36119. $25 = (($$0179244) + 1)|0;
  36120. if ($34) {
  36121. break;
  36122. }
  36123. $24 = (($25) + ($$0183$ph200250))|0;
  36124. $26 = ($24>>>0)<($7>>>0);
  36125. if ($26) {
  36126. $$0179244 = $25;$31 = $24;
  36127. } else {
  36128. $$0175$ph$ph$lcssa220 = $$0175$ph$ph256;$$0185$ph$lcssa = $$0185$ph261;
  36129. break L7;
  36130. }
  36131. }
  36132. $35 = (($$0175$ph$ph256) + ($$0183$ph200250))|0;
  36133. $36 = (($35) + 1)|0;
  36134. $37 = ($36>>>0)<($7>>>0);
  36135. if ($37) {
  36136. $$0183$ph200250 = $35;$131 = $36;
  36137. } else {
  36138. $$0175$ph$ph$lcssa220 = $$0175$ph$ph256;$$0185$ph$lcssa = $$0185$ph261;
  36139. break L7;
  36140. }
  36141. }
  36142. $38 = ($29&255)>($32&255);
  36143. $39 = (($31) - ($$0185$ph261))|0;
  36144. if (!($38)) {
  36145. break;
  36146. }
  36147. $43 = (($31) + 1)|0;
  36148. $44 = ($43>>>0)<($7>>>0);
  36149. if ($44) {
  36150. $$0175$ph$ph256 = $39;$$0183$ph200$ph255 = $31;$132 = $43;
  36151. } else {
  36152. $$0175$ph$ph$lcssa220 = $39;$$0185$ph$lcssa = $$0185$ph261;
  36153. break L7;
  36154. }
  36155. }
  36156. $40 = (($$0183$ph200250) + 1)|0;
  36157. $41 = (($$0183$ph200250) + 2)|0;
  36158. $42 = ($41>>>0)<($7>>>0);
  36159. if ($42) {
  36160. $$0183$ph262 = $40;$$0185$ph261 = $$0183$ph200250;$129 = $41;
  36161. } else {
  36162. $$0175$ph$ph$lcssa220 = 1;$$0185$ph$lcssa = $$0183$ph200250;
  36163. break;
  36164. }
  36165. }
  36166. if ($6) {
  36167. $$1184$ph241 = 0;$$1186$ph240 = -1;$130 = 1;
  36168. while(1) {
  36169. $$1176$ph$ph235 = 1;$$1184$ph196$ph234 = $$1184$ph241;$134 = $130;
  36170. while(1) {
  36171. $$1184$ph196229 = $$1184$ph196$ph234;$133 = $134;
  36172. L26: while(1) {
  36173. $$1180224 = 1;$52 = $133;
  36174. while(1) {
  36175. $48 = (($$1180224) + ($$1186$ph240))|0;
  36176. $49 = (($1) + ($48)|0);
  36177. $50 = HEAP8[$49>>0]|0;
  36178. $51 = (($1) + ($52)|0);
  36179. $53 = HEAP8[$51>>0]|0;
  36180. $54 = ($50<<24>>24)==($53<<24>>24);
  36181. if (!($54)) {
  36182. break L26;
  36183. }
  36184. $55 = ($$1180224|0)==($$1176$ph$ph235|0);
  36185. $46 = (($$1180224) + 1)|0;
  36186. if ($55) {
  36187. break;
  36188. }
  36189. $45 = (($46) + ($$1184$ph196229))|0;
  36190. $47 = ($45>>>0)<($7>>>0);
  36191. if ($47) {
  36192. $$1180224 = $46;$52 = $45;
  36193. } else {
  36194. $$0175$ph$ph$lcssa220323 = $$0175$ph$ph$lcssa220;$$0185$ph$lcssa322 = $$0185$ph$lcssa;$$0187$lcssa320321 = $7;$$1176$ph$ph$lcssa211 = $$1176$ph$ph235;$$1186$ph$lcssa = $$1186$ph240;
  36195. label = 27;
  36196. break L1;
  36197. }
  36198. }
  36199. $56 = (($$1176$ph$ph235) + ($$1184$ph196229))|0;
  36200. $57 = (($56) + 1)|0;
  36201. $58 = ($57>>>0)<($7>>>0);
  36202. if ($58) {
  36203. $$1184$ph196229 = $56;$133 = $57;
  36204. } else {
  36205. $$0175$ph$ph$lcssa220323 = $$0175$ph$ph$lcssa220;$$0185$ph$lcssa322 = $$0185$ph$lcssa;$$0187$lcssa320321 = $7;$$1176$ph$ph$lcssa211 = $$1176$ph$ph235;$$1186$ph$lcssa = $$1186$ph240;
  36206. label = 27;
  36207. break L1;
  36208. }
  36209. }
  36210. $59 = ($50&255)<($53&255);
  36211. $60 = (($52) - ($$1186$ph240))|0;
  36212. if (!($59)) {
  36213. break;
  36214. }
  36215. $64 = (($52) + 1)|0;
  36216. $65 = ($64>>>0)<($7>>>0);
  36217. if ($65) {
  36218. $$1176$ph$ph235 = $60;$$1184$ph196$ph234 = $52;$134 = $64;
  36219. } else {
  36220. $$0175$ph$ph$lcssa220323 = $$0175$ph$ph$lcssa220;$$0185$ph$lcssa322 = $$0185$ph$lcssa;$$0187$lcssa320321 = $7;$$1176$ph$ph$lcssa211 = $60;$$1186$ph$lcssa = $$1186$ph240;
  36221. label = 27;
  36222. break L1;
  36223. }
  36224. }
  36225. $61 = (($$1184$ph196229) + 1)|0;
  36226. $62 = (($$1184$ph196229) + 2)|0;
  36227. $63 = ($62>>>0)<($7>>>0);
  36228. if ($63) {
  36229. $$1184$ph241 = $61;$$1186$ph240 = $$1184$ph196229;$130 = $62;
  36230. } else {
  36231. $$0175$ph$ph$lcssa220323 = $$0175$ph$ph$lcssa220;$$0185$ph$lcssa322 = $$0185$ph$lcssa;$$0187$lcssa320321 = $7;$$1176$ph$ph$lcssa211 = 1;$$1186$ph$lcssa = $$1184$ph196229;
  36232. label = 27;
  36233. break;
  36234. }
  36235. }
  36236. } else {
  36237. $$0175$ph$ph$lcssa220323 = $$0175$ph$ph$lcssa220;$$0185$ph$lcssa322 = $$0185$ph$lcssa;$$0187$lcssa320321 = $7;$$1176$ph$ph$lcssa211 = 1;$$1186$ph$lcssa = -1;
  36238. label = 27;
  36239. }
  36240. } else {
  36241. $$0175$ph$ph$lcssa220323 = 1;$$0185$ph$lcssa322 = -1;$$0187$lcssa320321 = $7;$$1176$ph$ph$lcssa211 = 1;$$1186$ph$lcssa = -1;
  36242. label = 27;
  36243. }
  36244. }
  36245. } while(0);
  36246. L36: do {
  36247. if ((label|0) == 27) {
  36248. $66 = (($$1186$ph$lcssa) + 1)|0;
  36249. $67 = (($$0185$ph$lcssa322) + 1)|0;
  36250. $68 = ($66>>>0)>($67>>>0);
  36251. $$1176$$0175 = $68 ? $$1176$ph$ph$lcssa211 : $$0175$ph$ph$lcssa220323;
  36252. $$1186$$0185 = $68 ? $$1186$ph$lcssa : $$0185$ph$lcssa322;
  36253. $69 = (($1) + ($$1176$$0175)|0);
  36254. $70 = (($$1186$$0185) + 1)|0;
  36255. $71 = (_memcmp($1,$69,$70)|0);
  36256. $72 = ($71|0)==(0);
  36257. if ($72) {
  36258. $77 = (($$0187$lcssa320321) - ($$1176$$0175))|0;
  36259. $$0168 = $77;$$3178 = $$1176$$0175;
  36260. } else {
  36261. $73 = (($$0187$lcssa320321) - ($$1186$$0185))|0;
  36262. $74 = (($73) + -1)|0;
  36263. $75 = ($$1186$$0185>>>0)>($74>>>0);
  36264. $$1186$$0185$ = $75 ? $$1186$$0185 : $74;
  36265. $76 = (($$1186$$0185$) + 1)|0;
  36266. $$0168 = 0;$$3178 = $76;
  36267. }
  36268. $78 = $$0187$lcssa320321 | 63;
  36269. $79 = (($$0187$lcssa320321) + -1)|0;
  36270. $80 = ($$0168|0)!=(0);
  36271. $81 = (($$0187$lcssa320321) - ($$3178))|0;
  36272. $$0166 = $0;$$0169 = 0;$$0170 = $0;
  36273. while(1) {
  36274. $82 = $$0170;
  36275. $83 = $$0166;
  36276. $84 = (($82) - ($83))|0;
  36277. $85 = ($84>>>0)<($$0187$lcssa320321>>>0);
  36278. do {
  36279. if ($85) {
  36280. $86 = (_memchr($$0170,0,$78)|0);
  36281. $87 = ($86|0)==(0|0);
  36282. if ($87) {
  36283. $91 = (($$0170) + ($78)|0);
  36284. $$3173 = $91;
  36285. break;
  36286. } else {
  36287. $88 = $86;
  36288. $89 = (($88) - ($83))|0;
  36289. $90 = ($89>>>0)<($$0187$lcssa320321>>>0);
  36290. if ($90) {
  36291. $$3 = 0;
  36292. break L36;
  36293. } else {
  36294. $$3173 = $86;
  36295. break;
  36296. }
  36297. }
  36298. } else {
  36299. $$3173 = $$0170;
  36300. }
  36301. } while(0);
  36302. $92 = (($$0166) + ($79)|0);
  36303. $93 = HEAP8[$92>>0]|0;
  36304. $div = ($93&255) >>> 5;
  36305. $94 = $div&255;
  36306. $95 = (($2) + ($94<<2)|0);
  36307. $96 = HEAP32[$95>>2]|0;
  36308. $97 = $93 & 31;
  36309. $98 = $97&255;
  36310. $99 = 1 << $98;
  36311. $100 = $99 & $96;
  36312. $101 = ($100|0)==(0);
  36313. L50: do {
  36314. if ($101) {
  36315. $$0169$be = 0;$$2181$sink = $$0187$lcssa320321;
  36316. } else {
  36317. $102 = $93&255;
  36318. $103 = (($3) + ($102<<2)|0);
  36319. $104 = HEAP32[$103>>2]|0;
  36320. $105 = (($$0187$lcssa320321) - ($104))|0;
  36321. $106 = ($105|0)==(0);
  36322. if (!($106)) {
  36323. $107 = ($$0169|0)!=(0);
  36324. $or$cond = $80 & $107;
  36325. $108 = ($105>>>0)<($$3178>>>0);
  36326. $or$cond190 = $or$cond & $108;
  36327. $$2181 = $or$cond190 ? $81 : $105;
  36328. $$0169$be = 0;$$2181$sink = $$2181;
  36329. break;
  36330. }
  36331. $110 = ($70>>>0)>($$0169>>>0);
  36332. $111 = $110 ? $70 : $$0169;
  36333. $112 = (($1) + ($111)|0);
  36334. $113 = HEAP8[$112>>0]|0;
  36335. $cond191222 = ($113<<24>>24)==(0);
  36336. L55: do {
  36337. if ($cond191222) {
  36338. $$4 = $70;
  36339. } else {
  36340. $$3182223 = $111;$117 = $113;
  36341. while(1) {
  36342. $114 = (($$0166) + ($$3182223)|0);
  36343. $115 = HEAP8[$114>>0]|0;
  36344. $116 = ($117<<24>>24)==($115<<24>>24);
  36345. if (!($116)) {
  36346. break;
  36347. }
  36348. $118 = (($$3182223) + 1)|0;
  36349. $119 = (($1) + ($118)|0);
  36350. $120 = HEAP8[$119>>0]|0;
  36351. $cond191 = ($120<<24>>24)==(0);
  36352. if ($cond191) {
  36353. $$4 = $70;
  36354. break L55;
  36355. } else {
  36356. $$3182223 = $118;$117 = $120;
  36357. }
  36358. }
  36359. $121 = (($$3182223) - ($$1186$$0185))|0;
  36360. $$0169$be = 0;$$2181$sink = $121;
  36361. break L50;
  36362. }
  36363. } while(0);
  36364. while(1) {
  36365. $122 = ($$4>>>0)>($$0169>>>0);
  36366. if (!($122)) {
  36367. $$3 = $$0166;
  36368. break L36;
  36369. }
  36370. $123 = (($$4) + -1)|0;
  36371. $124 = (($1) + ($123)|0);
  36372. $125 = HEAP8[$124>>0]|0;
  36373. $126 = (($$0166) + ($123)|0);
  36374. $127 = HEAP8[$126>>0]|0;
  36375. $128 = ($125<<24>>24)==($127<<24>>24);
  36376. if ($128) {
  36377. $$4 = $123;
  36378. } else {
  36379. $$0169$be = $$0168;$$2181$sink = $$3178;
  36380. break;
  36381. }
  36382. }
  36383. }
  36384. } while(0);
  36385. $109 = (($$0166) + ($$2181$sink)|0);
  36386. $$0166 = $109;$$0169 = $$0169$be;$$0170 = $$3173;
  36387. }
  36388. }
  36389. } while(0);
  36390. STACKTOP = sp;return ($$3|0);
  36391. }
  36392. function _strrchr($0,$1) {
  36393. $0 = $0|0;
  36394. $1 = $1|0;
  36395. var $2 = 0, $3 = 0, $4 = 0, label = 0, sp = 0;
  36396. sp = STACKTOP;
  36397. $2 = (_strlen($0)|0);
  36398. $3 = (($2) + 1)|0;
  36399. $4 = (___memrchr($0,$1,$3)|0);
  36400. return ($4|0);
  36401. }
  36402. function ___memrchr($0,$1,$2) {
  36403. $0 = $0|0;
  36404. $1 = $1|0;
  36405. $2 = $2|0;
  36406. var $$0 = 0, $$09 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, label = 0, sp = 0;
  36407. sp = STACKTOP;
  36408. $3 = $1&255;
  36409. $$09 = $2;
  36410. while(1) {
  36411. $4 = (($$09) + -1)|0;
  36412. $5 = ($$09|0)==(0);
  36413. if ($5) {
  36414. $$0 = 0;
  36415. break;
  36416. }
  36417. $6 = (($0) + ($4)|0);
  36418. $7 = HEAP8[$6>>0]|0;
  36419. $8 = ($7<<24>>24)==($3<<24>>24);
  36420. if ($8) {
  36421. $$0 = $6;
  36422. break;
  36423. } else {
  36424. $$09 = $4;
  36425. }
  36426. }
  36427. return ($$0|0);
  36428. }
  36429. function _strspn($0,$1) {
  36430. $0 = $0|0;
  36431. $1 = $1|0;
  36432. var $$0 = 0, $$01925 = 0, $$020 = 0, $$1$lcssa = 0, $$123 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0;
  36433. var $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  36434. var $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $div = 0, $div21 = 0, label = 0, sp = 0;
  36435. sp = STACKTOP;
  36436. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  36437. $2 = sp;
  36438. ;HEAP32[$2>>2]=0|0;HEAP32[$2+4>>2]=0|0;HEAP32[$2+8>>2]=0|0;HEAP32[$2+12>>2]=0|0;HEAP32[$2+16>>2]=0|0;HEAP32[$2+20>>2]=0|0;HEAP32[$2+24>>2]=0|0;HEAP32[$2+28>>2]=0|0;
  36439. $3 = HEAP8[$1>>0]|0;
  36440. $4 = ($3<<24>>24)==(0);
  36441. do {
  36442. if ($4) {
  36443. $$0 = 0;
  36444. } else {
  36445. $5 = ((($1)) + 1|0);
  36446. $6 = HEAP8[$5>>0]|0;
  36447. $7 = ($6<<24>>24)==(0);
  36448. if ($7) {
  36449. $$020 = $0;
  36450. while(1) {
  36451. $8 = HEAP8[$$020>>0]|0;
  36452. $9 = ($8<<24>>24)==($3<<24>>24);
  36453. $10 = ((($$020)) + 1|0);
  36454. if ($9) {
  36455. $$020 = $10;
  36456. } else {
  36457. break;
  36458. }
  36459. }
  36460. $11 = $$020;
  36461. $12 = $0;
  36462. $13 = (($11) - ($12))|0;
  36463. $$0 = $13;
  36464. break;
  36465. } else {
  36466. $$01925 = $1;$17 = $3;
  36467. }
  36468. while(1) {
  36469. $16 = $17 & 31;
  36470. $18 = $16&255;
  36471. $19 = 1 << $18;
  36472. $div21 = ($17&255) >>> 5;
  36473. $20 = $div21&255;
  36474. $21 = (($2) + ($20<<2)|0);
  36475. $22 = HEAP32[$21>>2]|0;
  36476. $23 = $22 | $19;
  36477. HEAP32[$21>>2] = $23;
  36478. $24 = ((($$01925)) + 1|0);
  36479. $25 = HEAP8[$24>>0]|0;
  36480. $26 = ($25<<24>>24)==(0);
  36481. if ($26) {
  36482. break;
  36483. } else {
  36484. $$01925 = $24;$17 = $25;
  36485. }
  36486. }
  36487. $14 = HEAP8[$0>>0]|0;
  36488. $15 = ($14<<24>>24)==(0);
  36489. L10: do {
  36490. if ($15) {
  36491. $$1$lcssa = $0;
  36492. } else {
  36493. $$123 = $0;$27 = $14;
  36494. while(1) {
  36495. $div = ($27&255) >>> 5;
  36496. $28 = $div&255;
  36497. $29 = (($2) + ($28<<2)|0);
  36498. $30 = HEAP32[$29>>2]|0;
  36499. $31 = $27 & 31;
  36500. $32 = $31&255;
  36501. $33 = 1 << $32;
  36502. $34 = $30 & $33;
  36503. $35 = ($34|0)==(0);
  36504. if ($35) {
  36505. $$1$lcssa = $$123;
  36506. break L10;
  36507. }
  36508. $36 = ((($$123)) + 1|0);
  36509. $37 = HEAP8[$36>>0]|0;
  36510. $38 = ($37<<24>>24)==(0);
  36511. if ($38) {
  36512. $$1$lcssa = $36;
  36513. break;
  36514. } else {
  36515. $$123 = $36;$27 = $37;
  36516. }
  36517. }
  36518. }
  36519. } while(0);
  36520. $39 = $$1$lcssa;
  36521. $40 = $0;
  36522. $41 = (($39) - ($40))|0;
  36523. $$0 = $41;
  36524. }
  36525. } while(0);
  36526. STACKTOP = sp;return ($$0|0);
  36527. }
  36528. function _srand($0) {
  36529. $0 = $0|0;
  36530. var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, label = 0, sp = 0;
  36531. sp = STACKTOP;
  36532. $1 = (($0) + -1)|0;
  36533. $2 = 21304;
  36534. $3 = $2;
  36535. HEAP32[$3>>2] = $1;
  36536. $4 = (($2) + 4)|0;
  36537. $5 = $4;
  36538. HEAP32[$5>>2] = 0;
  36539. return;
  36540. }
  36541. function _fread($0,$1,$2,$3) {
  36542. $0 = $0|0;
  36543. $1 = $1|0;
  36544. $2 = $2|0;
  36545. $3 = $3|0;
  36546. var $$ = 0, $$0 = 0, $$054$ph = 0, $$05460 = 0, $$056$ph = 0, $$05659 = 0, $$57 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0;
  36547. var $23 = 0, $24 = 0, $25 = 0, $26 = 0, $27 = 0, $28 = 0, $29 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  36548. var $42 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  36549. sp = STACKTOP;
  36550. $4 = Math_imul($2, $1)|0;
  36551. $5 = ($1|0)==(0);
  36552. $$ = $5 ? 0 : $2;
  36553. $6 = ((($3)) + 76|0);
  36554. $7 = HEAP32[$6>>2]|0;
  36555. $8 = ($7|0)>(-1);
  36556. if ($8) {
  36557. $9 = (___lockfile($3)|0);
  36558. $36 = $9;
  36559. } else {
  36560. $36 = 0;
  36561. }
  36562. $10 = ((($3)) + 74|0);
  36563. $11 = HEAP8[$10>>0]|0;
  36564. $12 = $11 << 24 >> 24;
  36565. $13 = (($12) + 255)|0;
  36566. $14 = $13 | $12;
  36567. $15 = $14&255;
  36568. HEAP8[$10>>0] = $15;
  36569. $16 = ((($3)) + 8|0);
  36570. $17 = HEAP32[$16>>2]|0;
  36571. $18 = ((($3)) + 4|0);
  36572. $19 = HEAP32[$18>>2]|0;
  36573. $20 = $19;
  36574. $21 = (($17) - ($20))|0;
  36575. $22 = ($21|0)>(0);
  36576. $23 = ($21>>>0)<($4>>>0);
  36577. $$57 = $23 ? $21 : $4;
  36578. if ($22) {
  36579. $24 = (($4) - ($$57))|0;
  36580. $25 = (($0) + ($$57)|0);
  36581. _memcpy(($0|0),($19|0),($$57|0))|0;
  36582. $26 = (($19) + ($$57)|0);
  36583. HEAP32[$18>>2] = $26;
  36584. $$054$ph = $24;$$056$ph = $25;
  36585. } else {
  36586. $$054$ph = $4;$$056$ph = $0;
  36587. }
  36588. $27 = ($$054$ph|0)==(0);
  36589. L7: do {
  36590. if ($27) {
  36591. label = 13;
  36592. } else {
  36593. $28 = ((($3)) + 32|0);
  36594. $$05460 = $$054$ph;$$05659 = $$056$ph;
  36595. while(1) {
  36596. $29 = (___toread($3)|0);
  36597. $30 = ($29|0)==(0);
  36598. if (!($30)) {
  36599. break;
  36600. }
  36601. $31 = HEAP32[$28>>2]|0;
  36602. $32 = (FUNCTION_TABLE_iiii[$31 & 15]($3,$$05659,$$05460)|0);
  36603. $33 = (($32) + 1)|0;
  36604. $34 = ($33>>>0)<(2);
  36605. if ($34) {
  36606. break;
  36607. }
  36608. $39 = (($$05460) - ($32))|0;
  36609. $40 = (($$05659) + ($32)|0);
  36610. $41 = ($39|0)==(0);
  36611. if ($41) {
  36612. label = 13;
  36613. break L7;
  36614. } else {
  36615. $$05460 = $39;$$05659 = $40;
  36616. }
  36617. }
  36618. $35 = ($36|0)==(0);
  36619. if (!($35)) {
  36620. ___unlockfile($3);
  36621. }
  36622. $37 = (($4) - ($$05460))|0;
  36623. $38 = (($37>>>0) / ($1>>>0))&-1;
  36624. $$0 = $38;
  36625. }
  36626. } while(0);
  36627. if ((label|0) == 13) {
  36628. $42 = ($36|0)==(0);
  36629. if ($42) {
  36630. $$0 = $$;
  36631. } else {
  36632. ___unlockfile($3);
  36633. $$0 = $$;
  36634. }
  36635. }
  36636. return ($$0|0);
  36637. }
  36638. function _vprintf($0,$1) {
  36639. $0 = $0|0;
  36640. $1 = $1|0;
  36641. var $2 = 0, $3 = 0, label = 0, sp = 0;
  36642. sp = STACKTOP;
  36643. $2 = HEAP32[1338]|0;
  36644. $3 = (_vfprintf($2,$0,$1)|0);
  36645. return ($3|0);
  36646. }
  36647. function _strcspn($0,$1) {
  36648. $0 = $0|0;
  36649. $1 = $1|0;
  36650. var $$01824 = 0, $$019$sink = 0, $$01922 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0;
  36651. var $26 = 0, $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $div = 0;
  36652. var $div20 = 0, label = 0, sp = 0;
  36653. sp = STACKTOP;
  36654. STACKTOP = STACKTOP + 32|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(32|0);
  36655. $2 = sp;
  36656. $3 = HEAP8[$1>>0]|0;
  36657. $4 = ($3<<24>>24)==(0);
  36658. L1: do {
  36659. if ($4) {
  36660. label = 3;
  36661. } else {
  36662. $5 = ((($1)) + 1|0);
  36663. $6 = HEAP8[$5>>0]|0;
  36664. $7 = ($6<<24>>24)==(0);
  36665. if ($7) {
  36666. label = 3;
  36667. } else {
  36668. ;HEAP32[$2>>2]=0|0;HEAP32[$2+4>>2]=0|0;HEAP32[$2+8>>2]=0|0;HEAP32[$2+12>>2]=0|0;HEAP32[$2+16>>2]=0|0;HEAP32[$2+20>>2]=0|0;HEAP32[$2+24>>2]=0|0;HEAP32[$2+28>>2]=0|0;
  36669. $$01824 = $1;$13 = $3;
  36670. while(1) {
  36671. $12 = $13 & 31;
  36672. $14 = $12&255;
  36673. $15 = 1 << $14;
  36674. $div20 = ($13&255) >>> 5;
  36675. $16 = $div20&255;
  36676. $17 = (($2) + ($16<<2)|0);
  36677. $18 = HEAP32[$17>>2]|0;
  36678. $19 = $18 | $15;
  36679. HEAP32[$17>>2] = $19;
  36680. $20 = ((($$01824)) + 1|0);
  36681. $21 = HEAP8[$20>>0]|0;
  36682. $22 = ($21<<24>>24)==(0);
  36683. if ($22) {
  36684. break;
  36685. } else {
  36686. $$01824 = $20;$13 = $21;
  36687. }
  36688. }
  36689. $10 = HEAP8[$0>>0]|0;
  36690. $11 = ($10<<24>>24)==(0);
  36691. if ($11) {
  36692. $$019$sink = $0;
  36693. } else {
  36694. $$01922 = $0;$23 = $10;
  36695. while(1) {
  36696. $div = ($23&255) >>> 5;
  36697. $24 = $div&255;
  36698. $25 = (($2) + ($24<<2)|0);
  36699. $26 = HEAP32[$25>>2]|0;
  36700. $27 = $23 & 31;
  36701. $28 = $27&255;
  36702. $29 = 1 << $28;
  36703. $30 = $26 & $29;
  36704. $31 = ($30|0)==(0);
  36705. if (!($31)) {
  36706. $$019$sink = $$01922;
  36707. break L1;
  36708. }
  36709. $32 = ((($$01922)) + 1|0);
  36710. $33 = HEAP8[$32>>0]|0;
  36711. $34 = ($33<<24>>24)==(0);
  36712. if ($34) {
  36713. $$019$sink = $32;
  36714. break;
  36715. } else {
  36716. $$01922 = $32;$23 = $33;
  36717. }
  36718. }
  36719. }
  36720. }
  36721. }
  36722. } while(0);
  36723. if ((label|0) == 3) {
  36724. $8 = $3 << 24 >> 24;
  36725. $9 = (___strchrnul($0,$8)|0);
  36726. $$019$sink = $9;
  36727. }
  36728. $35 = $$019$sink;
  36729. $36 = $0;
  36730. $37 = (($35) - ($36))|0;
  36731. STACKTOP = sp;return ($37|0);
  36732. }
  36733. function _strcat($0,$1) {
  36734. $0 = $0|0;
  36735. $1 = $1|0;
  36736. var $2 = 0, $3 = 0, label = 0, sp = 0;
  36737. sp = STACKTOP;
  36738. $2 = (_strlen($0)|0);
  36739. $3 = (($0) + ($2)|0);
  36740. (_strcpy($3,$1)|0);
  36741. return ($0|0);
  36742. }
  36743. function _strtok($0,$1) {
  36744. $0 = $0|0;
  36745. $1 = $1|0;
  36746. var $$0 = 0, $$010 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  36747. sp = STACKTOP;
  36748. $2 = ($0|0)==(0|0);
  36749. if ($2) {
  36750. $3 = HEAP32[5923]|0;
  36751. $4 = ($3|0)==(0|0);
  36752. if ($4) {
  36753. $$0 = 0;
  36754. } else {
  36755. $$010 = $3;
  36756. label = 3;
  36757. }
  36758. } else {
  36759. $$010 = $0;
  36760. label = 3;
  36761. }
  36762. do {
  36763. if ((label|0) == 3) {
  36764. $5 = (_strspn($$010,$1)|0);
  36765. $6 = (($$010) + ($5)|0);
  36766. $7 = HEAP8[$6>>0]|0;
  36767. $8 = ($7<<24>>24)==(0);
  36768. if ($8) {
  36769. HEAP32[5923] = 0;
  36770. $$0 = 0;
  36771. break;
  36772. }
  36773. $9 = (_strcspn($6,$1)|0);
  36774. $10 = (($6) + ($9)|0);
  36775. HEAP32[5923] = $10;
  36776. $11 = HEAP8[$10>>0]|0;
  36777. $12 = ($11<<24>>24)==(0);
  36778. if ($12) {
  36779. HEAP32[5923] = 0;
  36780. $$0 = $6;
  36781. break;
  36782. } else {
  36783. $13 = ((($10)) + 1|0);
  36784. HEAP32[5923] = $13;
  36785. HEAP8[$10>>0] = 0;
  36786. $$0 = $6;
  36787. break;
  36788. }
  36789. }
  36790. } while(0);
  36791. return ($$0|0);
  36792. }
  36793. function _malloc($0) {
  36794. $0 = $0|0;
  36795. var $$$0192$i = 0, $$$0193$i = 0, $$$4236$i = 0, $$$4351$i = 0, $$$i = 0, $$0 = 0, $$0$i$i = 0, $$0$i$i$i = 0, $$0$i18$i = 0, $$01$i$i = 0, $$0189$i = 0, $$0192$lcssa$i = 0, $$01928$i = 0, $$0193$lcssa$i = 0, $$01937$i = 0, $$0197 = 0, $$0199 = 0, $$0206$i$i = 0, $$0207$i$i = 0, $$0211$i$i = 0;
  36796. var $$0212$i$i = 0, $$024371$i = 0, $$0287$i$i = 0, $$0288$i$i = 0, $$0289$i$i = 0, $$0295$i$i = 0, $$0296$i$i = 0, $$0342$i = 0, $$0344$i = 0, $$0345$i = 0, $$0347$i = 0, $$0353$i = 0, $$0358$i = 0, $$0359$$i = 0, $$0359$i = 0, $$0361$i = 0, $$0362$i = 0, $$0368$i = 0, $$1196$i = 0, $$1198$i = 0;
  36797. var $$124470$i = 0, $$1291$i$i = 0, $$1293$i$i = 0, $$1343$i = 0, $$1348$i = 0, $$1363$i = 0, $$1370$i = 0, $$1374$i = 0, $$2234253237$i = 0, $$2247$ph$i = 0, $$2253$ph$i = 0, $$2355$i = 0, $$3$i = 0, $$3$i$i = 0, $$3$i201 = 0, $$3350$i = 0, $$3372$i = 0, $$4$lcssa$i = 0, $$4$ph$i = 0, $$415$i = 0;
  36798. var $$4236$i = 0, $$4351$lcssa$i = 0, $$435114$i = 0, $$4357$$4$i = 0, $$4357$ph$i = 0, $$435713$i = 0, $$723948$i = 0, $$749$i = 0, $$pre = 0, $$pre$i = 0, $$pre$i$i = 0, $$pre$i19$i = 0, $$pre$i210 = 0, $$pre$i212 = 0, $$pre$phi$i$iZ2D = 0, $$pre$phi$i20$iZ2D = 0, $$pre$phi$i211Z2D = 0, $$pre$phi$iZ2D = 0, $$pre$phi11$i$iZ2D = 0, $$pre$phiZ2D = 0;
  36799. var $$pre10$i$i = 0, $$sink1$i = 0, $$sink1$i$i = 0, $$sink16$i = 0, $$sink2$i = 0, $$sink2$i204 = 0, $$sink3$i = 0, $1 = 0, $10 = 0, $100 = 0, $1000 = 0, $1001 = 0, $1002 = 0, $1003 = 0, $1004 = 0, $1005 = 0, $1006 = 0, $1007 = 0, $1008 = 0, $1009 = 0;
  36800. var $101 = 0, $1010 = 0, $1011 = 0, $1012 = 0, $1013 = 0, $1014 = 0, $1015 = 0, $1016 = 0, $1017 = 0, $1018 = 0, $1019 = 0, $102 = 0, $1020 = 0, $1021 = 0, $1022 = 0, $1023 = 0, $1024 = 0, $1025 = 0, $1026 = 0, $1027 = 0;
  36801. var $1028 = 0, $1029 = 0, $103 = 0, $1030 = 0, $1031 = 0, $1032 = 0, $1033 = 0, $1034 = 0, $1035 = 0, $1036 = 0, $1037 = 0, $1038 = 0, $1039 = 0, $104 = 0, $1040 = 0, $1041 = 0, $1042 = 0, $1043 = 0, $1044 = 0, $1045 = 0;
  36802. var $1046 = 0, $1047 = 0, $1048 = 0, $1049 = 0, $105 = 0, $1050 = 0, $1051 = 0, $1052 = 0, $1053 = 0, $1054 = 0, $1055 = 0, $1056 = 0, $1057 = 0, $1058 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0;
  36803. var $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0;
  36804. var $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0;
  36805. var $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0;
  36806. var $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0;
  36807. var $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0, $2 = 0, $20 = 0, $200 = 0;
  36808. var $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0;
  36809. var $22 = 0, $220 = 0, $221 = 0, $222 = 0, $223 = 0, $224 = 0, $225 = 0, $226 = 0, $227 = 0, $228 = 0, $229 = 0, $23 = 0, $230 = 0, $231 = 0, $232 = 0, $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0;
  36810. var $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0, $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0, $249 = 0, $25 = 0, $250 = 0, $251 = 0, $252 = 0, $253 = 0, $254 = 0, $255 = 0;
  36811. var $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0, $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0, $267 = 0, $268 = 0, $269 = 0, $27 = 0, $270 = 0, $271 = 0, $272 = 0, $273 = 0;
  36812. var $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0, $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0, $285 = 0, $286 = 0, $287 = 0, $288 = 0, $289 = 0, $29 = 0, $290 = 0, $291 = 0;
  36813. var $292 = 0, $293 = 0, $294 = 0, $295 = 0, $296 = 0, $297 = 0, $298 = 0, $299 = 0, $3 = 0, $30 = 0, $300 = 0, $301 = 0, $302 = 0, $303 = 0, $304 = 0, $305 = 0, $306 = 0, $307 = 0, $308 = 0, $309 = 0;
  36814. var $31 = 0, $310 = 0, $311 = 0, $312 = 0, $313 = 0, $314 = 0, $315 = 0, $316 = 0, $317 = 0, $318 = 0, $319 = 0, $32 = 0, $320 = 0, $321 = 0, $322 = 0, $323 = 0, $324 = 0, $325 = 0, $326 = 0, $327 = 0;
  36815. var $328 = 0, $329 = 0, $33 = 0, $330 = 0, $331 = 0, $332 = 0, $333 = 0, $334 = 0, $335 = 0, $336 = 0, $337 = 0, $338 = 0, $339 = 0, $34 = 0, $340 = 0, $341 = 0, $342 = 0, $343 = 0, $344 = 0, $345 = 0;
  36816. var $346 = 0, $347 = 0, $348 = 0, $349 = 0, $35 = 0, $350 = 0, $351 = 0, $352 = 0, $353 = 0, $354 = 0, $355 = 0, $356 = 0, $357 = 0, $358 = 0, $359 = 0, $36 = 0, $360 = 0, $361 = 0, $362 = 0, $363 = 0;
  36817. var $364 = 0, $365 = 0, $366 = 0, $367 = 0, $368 = 0, $369 = 0, $37 = 0, $370 = 0, $371 = 0, $372 = 0, $373 = 0, $374 = 0, $375 = 0, $376 = 0, $377 = 0, $378 = 0, $379 = 0, $38 = 0, $380 = 0, $381 = 0;
  36818. var $382 = 0, $383 = 0, $384 = 0, $385 = 0, $386 = 0, $387 = 0, $388 = 0, $389 = 0, $39 = 0, $390 = 0, $391 = 0, $392 = 0, $393 = 0, $394 = 0, $395 = 0, $396 = 0, $397 = 0, $398 = 0, $399 = 0, $4 = 0;
  36819. var $40 = 0, $400 = 0, $401 = 0, $402 = 0, $403 = 0, $404 = 0, $405 = 0, $406 = 0, $407 = 0, $408 = 0, $409 = 0, $41 = 0, $410 = 0, $411 = 0, $412 = 0, $413 = 0, $414 = 0, $415 = 0, $416 = 0, $417 = 0;
  36820. var $418 = 0, $419 = 0, $42 = 0, $420 = 0, $421 = 0, $422 = 0, $423 = 0, $424 = 0, $425 = 0, $426 = 0, $427 = 0, $428 = 0, $429 = 0, $43 = 0, $430 = 0, $431 = 0, $432 = 0, $433 = 0, $434 = 0, $435 = 0;
  36821. var $436 = 0, $437 = 0, $438 = 0, $439 = 0, $44 = 0, $440 = 0, $441 = 0, $442 = 0, $443 = 0, $444 = 0, $445 = 0, $446 = 0, $447 = 0, $448 = 0, $449 = 0, $45 = 0, $450 = 0, $451 = 0, $452 = 0, $453 = 0;
  36822. var $454 = 0, $455 = 0, $456 = 0, $457 = 0, $458 = 0, $459 = 0, $46 = 0, $460 = 0, $461 = 0, $462 = 0, $463 = 0, $464 = 0, $465 = 0, $466 = 0, $467 = 0, $468 = 0, $469 = 0, $47 = 0, $470 = 0, $471 = 0;
  36823. var $472 = 0, $473 = 0, $474 = 0, $475 = 0, $476 = 0, $477 = 0, $478 = 0, $479 = 0, $48 = 0, $480 = 0, $481 = 0, $482 = 0, $483 = 0, $484 = 0, $485 = 0, $486 = 0, $487 = 0, $488 = 0, $489 = 0, $49 = 0;
  36824. var $490 = 0, $491 = 0, $492 = 0, $493 = 0, $494 = 0, $495 = 0, $496 = 0, $497 = 0, $498 = 0, $499 = 0, $5 = 0, $50 = 0, $500 = 0, $501 = 0, $502 = 0, $503 = 0, $504 = 0, $505 = 0, $506 = 0, $507 = 0;
  36825. var $508 = 0, $509 = 0, $51 = 0, $510 = 0, $511 = 0, $512 = 0, $513 = 0, $514 = 0, $515 = 0, $516 = 0, $517 = 0, $518 = 0, $519 = 0, $52 = 0, $520 = 0, $521 = 0, $522 = 0, $523 = 0, $524 = 0, $525 = 0;
  36826. var $526 = 0, $527 = 0, $528 = 0, $529 = 0, $53 = 0, $530 = 0, $531 = 0, $532 = 0, $533 = 0, $534 = 0, $535 = 0, $536 = 0, $537 = 0, $538 = 0, $539 = 0, $54 = 0, $540 = 0, $541 = 0, $542 = 0, $543 = 0;
  36827. var $544 = 0, $545 = 0, $546 = 0, $547 = 0, $548 = 0, $549 = 0, $55 = 0, $550 = 0, $551 = 0, $552 = 0, $553 = 0, $554 = 0, $555 = 0, $556 = 0, $557 = 0, $558 = 0, $559 = 0, $56 = 0, $560 = 0, $561 = 0;
  36828. var $562 = 0, $563 = 0, $564 = 0, $565 = 0, $566 = 0, $567 = 0, $568 = 0, $569 = 0, $57 = 0, $570 = 0, $571 = 0, $572 = 0, $573 = 0, $574 = 0, $575 = 0, $576 = 0, $577 = 0, $578 = 0, $579 = 0, $58 = 0;
  36829. var $580 = 0, $581 = 0, $582 = 0, $583 = 0, $584 = 0, $585 = 0, $586 = 0, $587 = 0, $588 = 0, $589 = 0, $59 = 0, $590 = 0, $591 = 0, $592 = 0, $593 = 0, $594 = 0, $595 = 0, $596 = 0, $597 = 0, $598 = 0;
  36830. var $599 = 0, $6 = 0, $60 = 0, $600 = 0, $601 = 0, $602 = 0, $603 = 0, $604 = 0, $605 = 0, $606 = 0, $607 = 0, $608 = 0, $609 = 0, $61 = 0, $610 = 0, $611 = 0, $612 = 0, $613 = 0, $614 = 0, $615 = 0;
  36831. var $616 = 0, $617 = 0, $618 = 0, $619 = 0, $62 = 0, $620 = 0, $621 = 0, $622 = 0, $623 = 0, $624 = 0, $625 = 0, $626 = 0, $627 = 0, $628 = 0, $629 = 0, $63 = 0, $630 = 0, $631 = 0, $632 = 0, $633 = 0;
  36832. var $634 = 0, $635 = 0, $636 = 0, $637 = 0, $638 = 0, $639 = 0, $64 = 0, $640 = 0, $641 = 0, $642 = 0, $643 = 0, $644 = 0, $645 = 0, $646 = 0, $647 = 0, $648 = 0, $649 = 0, $65 = 0, $650 = 0, $651 = 0;
  36833. var $652 = 0, $653 = 0, $654 = 0, $655 = 0, $656 = 0, $657 = 0, $658 = 0, $659 = 0, $66 = 0, $660 = 0, $661 = 0, $662 = 0, $663 = 0, $664 = 0, $665 = 0, $666 = 0, $667 = 0, $668 = 0, $669 = 0, $67 = 0;
  36834. var $670 = 0, $671 = 0, $672 = 0, $673 = 0, $674 = 0, $675 = 0, $676 = 0, $677 = 0, $678 = 0, $679 = 0, $68 = 0, $680 = 0, $681 = 0, $682 = 0, $683 = 0, $684 = 0, $685 = 0, $686 = 0, $687 = 0, $688 = 0;
  36835. var $689 = 0, $69 = 0, $690 = 0, $691 = 0, $692 = 0, $693 = 0, $694 = 0, $695 = 0, $696 = 0, $697 = 0, $698 = 0, $699 = 0, $7 = 0, $70 = 0, $700 = 0, $701 = 0, $702 = 0, $703 = 0, $704 = 0, $705 = 0;
  36836. var $706 = 0, $707 = 0, $708 = 0, $709 = 0, $71 = 0, $710 = 0, $711 = 0, $712 = 0, $713 = 0, $714 = 0, $715 = 0, $716 = 0, $717 = 0, $718 = 0, $719 = 0, $72 = 0, $720 = 0, $721 = 0, $722 = 0, $723 = 0;
  36837. var $724 = 0, $725 = 0, $726 = 0, $727 = 0, $728 = 0, $729 = 0, $73 = 0, $730 = 0, $731 = 0, $732 = 0, $733 = 0, $734 = 0, $735 = 0, $736 = 0, $737 = 0, $738 = 0, $739 = 0, $74 = 0, $740 = 0, $741 = 0;
  36838. var $742 = 0, $743 = 0, $744 = 0, $745 = 0, $746 = 0, $747 = 0, $748 = 0, $749 = 0, $75 = 0, $750 = 0, $751 = 0, $752 = 0, $753 = 0, $754 = 0, $755 = 0, $756 = 0, $757 = 0, $758 = 0, $759 = 0, $76 = 0;
  36839. var $760 = 0, $761 = 0, $762 = 0, $763 = 0, $764 = 0, $765 = 0, $766 = 0, $767 = 0, $768 = 0, $769 = 0, $77 = 0, $770 = 0, $771 = 0, $772 = 0, $773 = 0, $774 = 0, $775 = 0, $776 = 0, $777 = 0, $778 = 0;
  36840. var $779 = 0, $78 = 0, $780 = 0, $781 = 0, $782 = 0, $783 = 0, $784 = 0, $785 = 0, $786 = 0, $787 = 0, $788 = 0, $789 = 0, $79 = 0, $790 = 0, $791 = 0, $792 = 0, $793 = 0, $794 = 0, $795 = 0, $796 = 0;
  36841. var $797 = 0, $798 = 0, $799 = 0, $8 = 0, $80 = 0, $800 = 0, $801 = 0, $802 = 0, $803 = 0, $804 = 0, $805 = 0, $806 = 0, $807 = 0, $808 = 0, $809 = 0, $81 = 0, $810 = 0, $811 = 0, $812 = 0, $813 = 0;
  36842. var $814 = 0, $815 = 0, $816 = 0, $817 = 0, $818 = 0, $819 = 0, $82 = 0, $820 = 0, $821 = 0, $822 = 0, $823 = 0, $824 = 0, $825 = 0, $826 = 0, $827 = 0, $828 = 0, $829 = 0, $83 = 0, $830 = 0, $831 = 0;
  36843. var $832 = 0, $833 = 0, $834 = 0, $835 = 0, $836 = 0, $837 = 0, $838 = 0, $839 = 0, $84 = 0, $840 = 0, $841 = 0, $842 = 0, $843 = 0, $844 = 0, $845 = 0, $846 = 0, $847 = 0, $848 = 0, $849 = 0, $85 = 0;
  36844. var $850 = 0, $851 = 0, $852 = 0, $853 = 0, $854 = 0, $855 = 0, $856 = 0, $857 = 0, $858 = 0, $859 = 0, $86 = 0, $860 = 0, $861 = 0, $862 = 0, $863 = 0, $864 = 0, $865 = 0, $866 = 0, $867 = 0, $868 = 0;
  36845. var $869 = 0, $87 = 0, $870 = 0, $871 = 0, $872 = 0, $873 = 0, $874 = 0, $875 = 0, $876 = 0, $877 = 0, $878 = 0, $879 = 0, $88 = 0, $880 = 0, $881 = 0, $882 = 0, $883 = 0, $884 = 0, $885 = 0, $886 = 0;
  36846. var $887 = 0, $888 = 0, $889 = 0, $89 = 0, $890 = 0, $891 = 0, $892 = 0, $893 = 0, $894 = 0, $895 = 0, $896 = 0, $897 = 0, $898 = 0, $899 = 0, $9 = 0, $90 = 0, $900 = 0, $901 = 0, $902 = 0, $903 = 0;
  36847. var $904 = 0, $905 = 0, $906 = 0, $907 = 0, $908 = 0, $909 = 0, $91 = 0, $910 = 0, $911 = 0, $912 = 0, $913 = 0, $914 = 0, $915 = 0, $916 = 0, $917 = 0, $918 = 0, $919 = 0, $92 = 0, $920 = 0, $921 = 0;
  36848. var $922 = 0, $923 = 0, $924 = 0, $925 = 0, $926 = 0, $927 = 0, $928 = 0, $929 = 0, $93 = 0, $930 = 0, $931 = 0, $932 = 0, $933 = 0, $934 = 0, $935 = 0, $936 = 0, $937 = 0, $938 = 0, $939 = 0, $94 = 0;
  36849. var $940 = 0, $941 = 0, $942 = 0, $943 = 0, $944 = 0, $945 = 0, $946 = 0, $947 = 0, $948 = 0, $949 = 0, $95 = 0, $950 = 0, $951 = 0, $952 = 0, $953 = 0, $954 = 0, $955 = 0, $956 = 0, $957 = 0, $958 = 0;
  36850. var $959 = 0, $96 = 0, $960 = 0, $961 = 0, $962 = 0, $963 = 0, $964 = 0, $965 = 0, $966 = 0, $967 = 0, $968 = 0, $969 = 0, $97 = 0, $970 = 0, $971 = 0, $972 = 0, $973 = 0, $974 = 0, $975 = 0, $976 = 0;
  36851. var $977 = 0, $978 = 0, $979 = 0, $98 = 0, $980 = 0, $981 = 0, $982 = 0, $983 = 0, $984 = 0, $985 = 0, $986 = 0, $987 = 0, $988 = 0, $989 = 0, $99 = 0, $990 = 0, $991 = 0, $992 = 0, $993 = 0, $994 = 0;
  36852. var $995 = 0, $996 = 0, $997 = 0, $998 = 0, $999 = 0, $cond$i = 0, $cond$i$i = 0, $cond$i208 = 0, $exitcond$i$i = 0, $not$$i = 0, $not$$i$i = 0, $not$$i17$i = 0, $not$$i209 = 0, $not$$i216 = 0, $not$1$i = 0, $not$1$i203 = 0, $not$5$i = 0, $not$7$i$i = 0, $not$8$i = 0, $not$9$i = 0;
  36853. var $or$cond$i = 0, $or$cond$i214 = 0, $or$cond1$i = 0, $or$cond10$i = 0, $or$cond11$i = 0, $or$cond11$not$i = 0, $or$cond12$i = 0, $or$cond2$i = 0, $or$cond2$i215 = 0, $or$cond5$i = 0, $or$cond50$i = 0, $or$cond51$i = 0, $or$cond7$i = 0, label = 0, sp = 0;
  36854. sp = STACKTOP;
  36855. STACKTOP = STACKTOP + 16|0; if ((STACKTOP|0) >= (STACK_MAX|0)) abortStackOverflow(16|0);
  36856. $1 = sp;
  36857. $2 = ($0>>>0)<(245);
  36858. do {
  36859. if ($2) {
  36860. $3 = ($0>>>0)<(11);
  36861. $4 = (($0) + 11)|0;
  36862. $5 = $4 & -8;
  36863. $6 = $3 ? 16 : $5;
  36864. $7 = $6 >>> 3;
  36865. $8 = HEAP32[5924]|0;
  36866. $9 = $8 >>> $7;
  36867. $10 = $9 & 3;
  36868. $11 = ($10|0)==(0);
  36869. if (!($11)) {
  36870. $12 = $9 & 1;
  36871. $13 = $12 ^ 1;
  36872. $14 = (($13) + ($7))|0;
  36873. $15 = $14 << 1;
  36874. $16 = (23736 + ($15<<2)|0);
  36875. $17 = ((($16)) + 8|0);
  36876. $18 = HEAP32[$17>>2]|0;
  36877. $19 = ((($18)) + 8|0);
  36878. $20 = HEAP32[$19>>2]|0;
  36879. $21 = ($16|0)==($20|0);
  36880. do {
  36881. if ($21) {
  36882. $22 = 1 << $14;
  36883. $23 = $22 ^ -1;
  36884. $24 = $8 & $23;
  36885. HEAP32[5924] = $24;
  36886. } else {
  36887. $25 = HEAP32[(23712)>>2]|0;
  36888. $26 = ($20>>>0)<($25>>>0);
  36889. if ($26) {
  36890. _abort();
  36891. // unreachable;
  36892. }
  36893. $27 = ((($20)) + 12|0);
  36894. $28 = HEAP32[$27>>2]|0;
  36895. $29 = ($28|0)==($18|0);
  36896. if ($29) {
  36897. HEAP32[$27>>2] = $16;
  36898. HEAP32[$17>>2] = $20;
  36899. break;
  36900. } else {
  36901. _abort();
  36902. // unreachable;
  36903. }
  36904. }
  36905. } while(0);
  36906. $30 = $14 << 3;
  36907. $31 = $30 | 3;
  36908. $32 = ((($18)) + 4|0);
  36909. HEAP32[$32>>2] = $31;
  36910. $33 = (($18) + ($30)|0);
  36911. $34 = ((($33)) + 4|0);
  36912. $35 = HEAP32[$34>>2]|0;
  36913. $36 = $35 | 1;
  36914. HEAP32[$34>>2] = $36;
  36915. $$0 = $19;
  36916. STACKTOP = sp;return ($$0|0);
  36917. }
  36918. $37 = HEAP32[(23704)>>2]|0;
  36919. $38 = ($6>>>0)>($37>>>0);
  36920. if ($38) {
  36921. $39 = ($9|0)==(0);
  36922. if (!($39)) {
  36923. $40 = $9 << $7;
  36924. $41 = 2 << $7;
  36925. $42 = (0 - ($41))|0;
  36926. $43 = $41 | $42;
  36927. $44 = $40 & $43;
  36928. $45 = (0 - ($44))|0;
  36929. $46 = $44 & $45;
  36930. $47 = (($46) + -1)|0;
  36931. $48 = $47 >>> 12;
  36932. $49 = $48 & 16;
  36933. $50 = $47 >>> $49;
  36934. $51 = $50 >>> 5;
  36935. $52 = $51 & 8;
  36936. $53 = $52 | $49;
  36937. $54 = $50 >>> $52;
  36938. $55 = $54 >>> 2;
  36939. $56 = $55 & 4;
  36940. $57 = $53 | $56;
  36941. $58 = $54 >>> $56;
  36942. $59 = $58 >>> 1;
  36943. $60 = $59 & 2;
  36944. $61 = $57 | $60;
  36945. $62 = $58 >>> $60;
  36946. $63 = $62 >>> 1;
  36947. $64 = $63 & 1;
  36948. $65 = $61 | $64;
  36949. $66 = $62 >>> $64;
  36950. $67 = (($65) + ($66))|0;
  36951. $68 = $67 << 1;
  36952. $69 = (23736 + ($68<<2)|0);
  36953. $70 = ((($69)) + 8|0);
  36954. $71 = HEAP32[$70>>2]|0;
  36955. $72 = ((($71)) + 8|0);
  36956. $73 = HEAP32[$72>>2]|0;
  36957. $74 = ($69|0)==($73|0);
  36958. do {
  36959. if ($74) {
  36960. $75 = 1 << $67;
  36961. $76 = $75 ^ -1;
  36962. $77 = $8 & $76;
  36963. HEAP32[5924] = $77;
  36964. $98 = $77;
  36965. } else {
  36966. $78 = HEAP32[(23712)>>2]|0;
  36967. $79 = ($73>>>0)<($78>>>0);
  36968. if ($79) {
  36969. _abort();
  36970. // unreachable;
  36971. }
  36972. $80 = ((($73)) + 12|0);
  36973. $81 = HEAP32[$80>>2]|0;
  36974. $82 = ($81|0)==($71|0);
  36975. if ($82) {
  36976. HEAP32[$80>>2] = $69;
  36977. HEAP32[$70>>2] = $73;
  36978. $98 = $8;
  36979. break;
  36980. } else {
  36981. _abort();
  36982. // unreachable;
  36983. }
  36984. }
  36985. } while(0);
  36986. $83 = $67 << 3;
  36987. $84 = (($83) - ($6))|0;
  36988. $85 = $6 | 3;
  36989. $86 = ((($71)) + 4|0);
  36990. HEAP32[$86>>2] = $85;
  36991. $87 = (($71) + ($6)|0);
  36992. $88 = $84 | 1;
  36993. $89 = ((($87)) + 4|0);
  36994. HEAP32[$89>>2] = $88;
  36995. $90 = (($87) + ($84)|0);
  36996. HEAP32[$90>>2] = $84;
  36997. $91 = ($37|0)==(0);
  36998. if (!($91)) {
  36999. $92 = HEAP32[(23716)>>2]|0;
  37000. $93 = $37 >>> 3;
  37001. $94 = $93 << 1;
  37002. $95 = (23736 + ($94<<2)|0);
  37003. $96 = 1 << $93;
  37004. $97 = $98 & $96;
  37005. $99 = ($97|0)==(0);
  37006. if ($99) {
  37007. $100 = $98 | $96;
  37008. HEAP32[5924] = $100;
  37009. $$pre = ((($95)) + 8|0);
  37010. $$0199 = $95;$$pre$phiZ2D = $$pre;
  37011. } else {
  37012. $101 = ((($95)) + 8|0);
  37013. $102 = HEAP32[$101>>2]|0;
  37014. $103 = HEAP32[(23712)>>2]|0;
  37015. $104 = ($102>>>0)<($103>>>0);
  37016. if ($104) {
  37017. _abort();
  37018. // unreachable;
  37019. } else {
  37020. $$0199 = $102;$$pre$phiZ2D = $101;
  37021. }
  37022. }
  37023. HEAP32[$$pre$phiZ2D>>2] = $92;
  37024. $105 = ((($$0199)) + 12|0);
  37025. HEAP32[$105>>2] = $92;
  37026. $106 = ((($92)) + 8|0);
  37027. HEAP32[$106>>2] = $$0199;
  37028. $107 = ((($92)) + 12|0);
  37029. HEAP32[$107>>2] = $95;
  37030. }
  37031. HEAP32[(23704)>>2] = $84;
  37032. HEAP32[(23716)>>2] = $87;
  37033. $$0 = $72;
  37034. STACKTOP = sp;return ($$0|0);
  37035. }
  37036. $108 = HEAP32[(23700)>>2]|0;
  37037. $109 = ($108|0)==(0);
  37038. if ($109) {
  37039. $$0197 = $6;
  37040. } else {
  37041. $110 = (0 - ($108))|0;
  37042. $111 = $108 & $110;
  37043. $112 = (($111) + -1)|0;
  37044. $113 = $112 >>> 12;
  37045. $114 = $113 & 16;
  37046. $115 = $112 >>> $114;
  37047. $116 = $115 >>> 5;
  37048. $117 = $116 & 8;
  37049. $118 = $117 | $114;
  37050. $119 = $115 >>> $117;
  37051. $120 = $119 >>> 2;
  37052. $121 = $120 & 4;
  37053. $122 = $118 | $121;
  37054. $123 = $119 >>> $121;
  37055. $124 = $123 >>> 1;
  37056. $125 = $124 & 2;
  37057. $126 = $122 | $125;
  37058. $127 = $123 >>> $125;
  37059. $128 = $127 >>> 1;
  37060. $129 = $128 & 1;
  37061. $130 = $126 | $129;
  37062. $131 = $127 >>> $129;
  37063. $132 = (($130) + ($131))|0;
  37064. $133 = (24000 + ($132<<2)|0);
  37065. $134 = HEAP32[$133>>2]|0;
  37066. $135 = ((($134)) + 4|0);
  37067. $136 = HEAP32[$135>>2]|0;
  37068. $137 = $136 & -8;
  37069. $138 = (($137) - ($6))|0;
  37070. $139 = ((($134)) + 16|0);
  37071. $140 = HEAP32[$139>>2]|0;
  37072. $not$5$i = ($140|0)==(0|0);
  37073. $$sink16$i = $not$5$i&1;
  37074. $141 = (((($134)) + 16|0) + ($$sink16$i<<2)|0);
  37075. $142 = HEAP32[$141>>2]|0;
  37076. $143 = ($142|0)==(0|0);
  37077. if ($143) {
  37078. $$0192$lcssa$i = $134;$$0193$lcssa$i = $138;
  37079. } else {
  37080. $$01928$i = $134;$$01937$i = $138;$145 = $142;
  37081. while(1) {
  37082. $144 = ((($145)) + 4|0);
  37083. $146 = HEAP32[$144>>2]|0;
  37084. $147 = $146 & -8;
  37085. $148 = (($147) - ($6))|0;
  37086. $149 = ($148>>>0)<($$01937$i>>>0);
  37087. $$$0193$i = $149 ? $148 : $$01937$i;
  37088. $$$0192$i = $149 ? $145 : $$01928$i;
  37089. $150 = ((($145)) + 16|0);
  37090. $151 = HEAP32[$150>>2]|0;
  37091. $not$$i = ($151|0)==(0|0);
  37092. $$sink1$i = $not$$i&1;
  37093. $152 = (((($145)) + 16|0) + ($$sink1$i<<2)|0);
  37094. $153 = HEAP32[$152>>2]|0;
  37095. $154 = ($153|0)==(0|0);
  37096. if ($154) {
  37097. $$0192$lcssa$i = $$$0192$i;$$0193$lcssa$i = $$$0193$i;
  37098. break;
  37099. } else {
  37100. $$01928$i = $$$0192$i;$$01937$i = $$$0193$i;$145 = $153;
  37101. }
  37102. }
  37103. }
  37104. $155 = HEAP32[(23712)>>2]|0;
  37105. $156 = ($$0192$lcssa$i>>>0)<($155>>>0);
  37106. if ($156) {
  37107. _abort();
  37108. // unreachable;
  37109. }
  37110. $157 = (($$0192$lcssa$i) + ($6)|0);
  37111. $158 = ($$0192$lcssa$i>>>0)<($157>>>0);
  37112. if (!($158)) {
  37113. _abort();
  37114. // unreachable;
  37115. }
  37116. $159 = ((($$0192$lcssa$i)) + 24|0);
  37117. $160 = HEAP32[$159>>2]|0;
  37118. $161 = ((($$0192$lcssa$i)) + 12|0);
  37119. $162 = HEAP32[$161>>2]|0;
  37120. $163 = ($162|0)==($$0192$lcssa$i|0);
  37121. do {
  37122. if ($163) {
  37123. $173 = ((($$0192$lcssa$i)) + 20|0);
  37124. $174 = HEAP32[$173>>2]|0;
  37125. $175 = ($174|0)==(0|0);
  37126. if ($175) {
  37127. $176 = ((($$0192$lcssa$i)) + 16|0);
  37128. $177 = HEAP32[$176>>2]|0;
  37129. $178 = ($177|0)==(0|0);
  37130. if ($178) {
  37131. $$3$i = 0;
  37132. break;
  37133. } else {
  37134. $$1196$i = $177;$$1198$i = $176;
  37135. }
  37136. } else {
  37137. $$1196$i = $174;$$1198$i = $173;
  37138. }
  37139. while(1) {
  37140. $179 = ((($$1196$i)) + 20|0);
  37141. $180 = HEAP32[$179>>2]|0;
  37142. $181 = ($180|0)==(0|0);
  37143. if (!($181)) {
  37144. $$1196$i = $180;$$1198$i = $179;
  37145. continue;
  37146. }
  37147. $182 = ((($$1196$i)) + 16|0);
  37148. $183 = HEAP32[$182>>2]|0;
  37149. $184 = ($183|0)==(0|0);
  37150. if ($184) {
  37151. break;
  37152. } else {
  37153. $$1196$i = $183;$$1198$i = $182;
  37154. }
  37155. }
  37156. $185 = ($$1198$i>>>0)<($155>>>0);
  37157. if ($185) {
  37158. _abort();
  37159. // unreachable;
  37160. } else {
  37161. HEAP32[$$1198$i>>2] = 0;
  37162. $$3$i = $$1196$i;
  37163. break;
  37164. }
  37165. } else {
  37166. $164 = ((($$0192$lcssa$i)) + 8|0);
  37167. $165 = HEAP32[$164>>2]|0;
  37168. $166 = ($165>>>0)<($155>>>0);
  37169. if ($166) {
  37170. _abort();
  37171. // unreachable;
  37172. }
  37173. $167 = ((($165)) + 12|0);
  37174. $168 = HEAP32[$167>>2]|0;
  37175. $169 = ($168|0)==($$0192$lcssa$i|0);
  37176. if (!($169)) {
  37177. _abort();
  37178. // unreachable;
  37179. }
  37180. $170 = ((($162)) + 8|0);
  37181. $171 = HEAP32[$170>>2]|0;
  37182. $172 = ($171|0)==($$0192$lcssa$i|0);
  37183. if ($172) {
  37184. HEAP32[$167>>2] = $162;
  37185. HEAP32[$170>>2] = $165;
  37186. $$3$i = $162;
  37187. break;
  37188. } else {
  37189. _abort();
  37190. // unreachable;
  37191. }
  37192. }
  37193. } while(0);
  37194. $186 = ($160|0)==(0|0);
  37195. L73: do {
  37196. if (!($186)) {
  37197. $187 = ((($$0192$lcssa$i)) + 28|0);
  37198. $188 = HEAP32[$187>>2]|0;
  37199. $189 = (24000 + ($188<<2)|0);
  37200. $190 = HEAP32[$189>>2]|0;
  37201. $191 = ($$0192$lcssa$i|0)==($190|0);
  37202. do {
  37203. if ($191) {
  37204. HEAP32[$189>>2] = $$3$i;
  37205. $cond$i = ($$3$i|0)==(0|0);
  37206. if ($cond$i) {
  37207. $192 = 1 << $188;
  37208. $193 = $192 ^ -1;
  37209. $194 = $108 & $193;
  37210. HEAP32[(23700)>>2] = $194;
  37211. break L73;
  37212. }
  37213. } else {
  37214. $195 = HEAP32[(23712)>>2]|0;
  37215. $196 = ($160>>>0)<($195>>>0);
  37216. if ($196) {
  37217. _abort();
  37218. // unreachable;
  37219. } else {
  37220. $197 = ((($160)) + 16|0);
  37221. $198 = HEAP32[$197>>2]|0;
  37222. $not$1$i = ($198|0)!=($$0192$lcssa$i|0);
  37223. $$sink2$i = $not$1$i&1;
  37224. $199 = (((($160)) + 16|0) + ($$sink2$i<<2)|0);
  37225. HEAP32[$199>>2] = $$3$i;
  37226. $200 = ($$3$i|0)==(0|0);
  37227. if ($200) {
  37228. break L73;
  37229. } else {
  37230. break;
  37231. }
  37232. }
  37233. }
  37234. } while(0);
  37235. $201 = HEAP32[(23712)>>2]|0;
  37236. $202 = ($$3$i>>>0)<($201>>>0);
  37237. if ($202) {
  37238. _abort();
  37239. // unreachable;
  37240. }
  37241. $203 = ((($$3$i)) + 24|0);
  37242. HEAP32[$203>>2] = $160;
  37243. $204 = ((($$0192$lcssa$i)) + 16|0);
  37244. $205 = HEAP32[$204>>2]|0;
  37245. $206 = ($205|0)==(0|0);
  37246. do {
  37247. if (!($206)) {
  37248. $207 = ($205>>>0)<($201>>>0);
  37249. if ($207) {
  37250. _abort();
  37251. // unreachable;
  37252. } else {
  37253. $208 = ((($$3$i)) + 16|0);
  37254. HEAP32[$208>>2] = $205;
  37255. $209 = ((($205)) + 24|0);
  37256. HEAP32[$209>>2] = $$3$i;
  37257. break;
  37258. }
  37259. }
  37260. } while(0);
  37261. $210 = ((($$0192$lcssa$i)) + 20|0);
  37262. $211 = HEAP32[$210>>2]|0;
  37263. $212 = ($211|0)==(0|0);
  37264. if (!($212)) {
  37265. $213 = HEAP32[(23712)>>2]|0;
  37266. $214 = ($211>>>0)<($213>>>0);
  37267. if ($214) {
  37268. _abort();
  37269. // unreachable;
  37270. } else {
  37271. $215 = ((($$3$i)) + 20|0);
  37272. HEAP32[$215>>2] = $211;
  37273. $216 = ((($211)) + 24|0);
  37274. HEAP32[$216>>2] = $$3$i;
  37275. break;
  37276. }
  37277. }
  37278. }
  37279. } while(0);
  37280. $217 = ($$0193$lcssa$i>>>0)<(16);
  37281. if ($217) {
  37282. $218 = (($$0193$lcssa$i) + ($6))|0;
  37283. $219 = $218 | 3;
  37284. $220 = ((($$0192$lcssa$i)) + 4|0);
  37285. HEAP32[$220>>2] = $219;
  37286. $221 = (($$0192$lcssa$i) + ($218)|0);
  37287. $222 = ((($221)) + 4|0);
  37288. $223 = HEAP32[$222>>2]|0;
  37289. $224 = $223 | 1;
  37290. HEAP32[$222>>2] = $224;
  37291. } else {
  37292. $225 = $6 | 3;
  37293. $226 = ((($$0192$lcssa$i)) + 4|0);
  37294. HEAP32[$226>>2] = $225;
  37295. $227 = $$0193$lcssa$i | 1;
  37296. $228 = ((($157)) + 4|0);
  37297. HEAP32[$228>>2] = $227;
  37298. $229 = (($157) + ($$0193$lcssa$i)|0);
  37299. HEAP32[$229>>2] = $$0193$lcssa$i;
  37300. $230 = ($37|0)==(0);
  37301. if (!($230)) {
  37302. $231 = HEAP32[(23716)>>2]|0;
  37303. $232 = $37 >>> 3;
  37304. $233 = $232 << 1;
  37305. $234 = (23736 + ($233<<2)|0);
  37306. $235 = 1 << $232;
  37307. $236 = $8 & $235;
  37308. $237 = ($236|0)==(0);
  37309. if ($237) {
  37310. $238 = $8 | $235;
  37311. HEAP32[5924] = $238;
  37312. $$pre$i = ((($234)) + 8|0);
  37313. $$0189$i = $234;$$pre$phi$iZ2D = $$pre$i;
  37314. } else {
  37315. $239 = ((($234)) + 8|0);
  37316. $240 = HEAP32[$239>>2]|0;
  37317. $241 = HEAP32[(23712)>>2]|0;
  37318. $242 = ($240>>>0)<($241>>>0);
  37319. if ($242) {
  37320. _abort();
  37321. // unreachable;
  37322. } else {
  37323. $$0189$i = $240;$$pre$phi$iZ2D = $239;
  37324. }
  37325. }
  37326. HEAP32[$$pre$phi$iZ2D>>2] = $231;
  37327. $243 = ((($$0189$i)) + 12|0);
  37328. HEAP32[$243>>2] = $231;
  37329. $244 = ((($231)) + 8|0);
  37330. HEAP32[$244>>2] = $$0189$i;
  37331. $245 = ((($231)) + 12|0);
  37332. HEAP32[$245>>2] = $234;
  37333. }
  37334. HEAP32[(23704)>>2] = $$0193$lcssa$i;
  37335. HEAP32[(23716)>>2] = $157;
  37336. }
  37337. $246 = ((($$0192$lcssa$i)) + 8|0);
  37338. $$0 = $246;
  37339. STACKTOP = sp;return ($$0|0);
  37340. }
  37341. } else {
  37342. $$0197 = $6;
  37343. }
  37344. } else {
  37345. $247 = ($0>>>0)>(4294967231);
  37346. if ($247) {
  37347. $$0197 = -1;
  37348. } else {
  37349. $248 = (($0) + 11)|0;
  37350. $249 = $248 & -8;
  37351. $250 = HEAP32[(23700)>>2]|0;
  37352. $251 = ($250|0)==(0);
  37353. if ($251) {
  37354. $$0197 = $249;
  37355. } else {
  37356. $252 = (0 - ($249))|0;
  37357. $253 = $248 >>> 8;
  37358. $254 = ($253|0)==(0);
  37359. if ($254) {
  37360. $$0358$i = 0;
  37361. } else {
  37362. $255 = ($249>>>0)>(16777215);
  37363. if ($255) {
  37364. $$0358$i = 31;
  37365. } else {
  37366. $256 = (($253) + 1048320)|0;
  37367. $257 = $256 >>> 16;
  37368. $258 = $257 & 8;
  37369. $259 = $253 << $258;
  37370. $260 = (($259) + 520192)|0;
  37371. $261 = $260 >>> 16;
  37372. $262 = $261 & 4;
  37373. $263 = $262 | $258;
  37374. $264 = $259 << $262;
  37375. $265 = (($264) + 245760)|0;
  37376. $266 = $265 >>> 16;
  37377. $267 = $266 & 2;
  37378. $268 = $263 | $267;
  37379. $269 = (14 - ($268))|0;
  37380. $270 = $264 << $267;
  37381. $271 = $270 >>> 15;
  37382. $272 = (($269) + ($271))|0;
  37383. $273 = $272 << 1;
  37384. $274 = (($272) + 7)|0;
  37385. $275 = $249 >>> $274;
  37386. $276 = $275 & 1;
  37387. $277 = $276 | $273;
  37388. $$0358$i = $277;
  37389. }
  37390. }
  37391. $278 = (24000 + ($$0358$i<<2)|0);
  37392. $279 = HEAP32[$278>>2]|0;
  37393. $280 = ($279|0)==(0|0);
  37394. L117: do {
  37395. if ($280) {
  37396. $$2355$i = 0;$$3$i201 = 0;$$3350$i = $252;
  37397. label = 81;
  37398. } else {
  37399. $281 = ($$0358$i|0)==(31);
  37400. $282 = $$0358$i >>> 1;
  37401. $283 = (25 - ($282))|0;
  37402. $284 = $281 ? 0 : $283;
  37403. $285 = $249 << $284;
  37404. $$0342$i = 0;$$0347$i = $252;$$0353$i = $279;$$0359$i = $285;$$0362$i = 0;
  37405. while(1) {
  37406. $286 = ((($$0353$i)) + 4|0);
  37407. $287 = HEAP32[$286>>2]|0;
  37408. $288 = $287 & -8;
  37409. $289 = (($288) - ($249))|0;
  37410. $290 = ($289>>>0)<($$0347$i>>>0);
  37411. if ($290) {
  37412. $291 = ($289|0)==(0);
  37413. if ($291) {
  37414. $$415$i = $$0353$i;$$435114$i = 0;$$435713$i = $$0353$i;
  37415. label = 85;
  37416. break L117;
  37417. } else {
  37418. $$1343$i = $$0353$i;$$1348$i = $289;
  37419. }
  37420. } else {
  37421. $$1343$i = $$0342$i;$$1348$i = $$0347$i;
  37422. }
  37423. $292 = ((($$0353$i)) + 20|0);
  37424. $293 = HEAP32[$292>>2]|0;
  37425. $294 = $$0359$i >>> 31;
  37426. $295 = (((($$0353$i)) + 16|0) + ($294<<2)|0);
  37427. $296 = HEAP32[$295>>2]|0;
  37428. $297 = ($293|0)==(0|0);
  37429. $298 = ($293|0)==($296|0);
  37430. $or$cond2$i = $297 | $298;
  37431. $$1363$i = $or$cond2$i ? $$0362$i : $293;
  37432. $299 = ($296|0)==(0|0);
  37433. $not$8$i = $299 ^ 1;
  37434. $300 = $not$8$i&1;
  37435. $$0359$$i = $$0359$i << $300;
  37436. if ($299) {
  37437. $$2355$i = $$1363$i;$$3$i201 = $$1343$i;$$3350$i = $$1348$i;
  37438. label = 81;
  37439. break;
  37440. } else {
  37441. $$0342$i = $$1343$i;$$0347$i = $$1348$i;$$0353$i = $296;$$0359$i = $$0359$$i;$$0362$i = $$1363$i;
  37442. }
  37443. }
  37444. }
  37445. } while(0);
  37446. if ((label|0) == 81) {
  37447. $301 = ($$2355$i|0)==(0|0);
  37448. $302 = ($$3$i201|0)==(0|0);
  37449. $or$cond$i = $301 & $302;
  37450. if ($or$cond$i) {
  37451. $303 = 2 << $$0358$i;
  37452. $304 = (0 - ($303))|0;
  37453. $305 = $303 | $304;
  37454. $306 = $250 & $305;
  37455. $307 = ($306|0)==(0);
  37456. if ($307) {
  37457. $$0197 = $249;
  37458. break;
  37459. }
  37460. $308 = (0 - ($306))|0;
  37461. $309 = $306 & $308;
  37462. $310 = (($309) + -1)|0;
  37463. $311 = $310 >>> 12;
  37464. $312 = $311 & 16;
  37465. $313 = $310 >>> $312;
  37466. $314 = $313 >>> 5;
  37467. $315 = $314 & 8;
  37468. $316 = $315 | $312;
  37469. $317 = $313 >>> $315;
  37470. $318 = $317 >>> 2;
  37471. $319 = $318 & 4;
  37472. $320 = $316 | $319;
  37473. $321 = $317 >>> $319;
  37474. $322 = $321 >>> 1;
  37475. $323 = $322 & 2;
  37476. $324 = $320 | $323;
  37477. $325 = $321 >>> $323;
  37478. $326 = $325 >>> 1;
  37479. $327 = $326 & 1;
  37480. $328 = $324 | $327;
  37481. $329 = $325 >>> $327;
  37482. $330 = (($328) + ($329))|0;
  37483. $331 = (24000 + ($330<<2)|0);
  37484. $332 = HEAP32[$331>>2]|0;
  37485. $$4$ph$i = 0;$$4357$ph$i = $332;
  37486. } else {
  37487. $$4$ph$i = $$3$i201;$$4357$ph$i = $$2355$i;
  37488. }
  37489. $333 = ($$4357$ph$i|0)==(0|0);
  37490. if ($333) {
  37491. $$4$lcssa$i = $$4$ph$i;$$4351$lcssa$i = $$3350$i;
  37492. } else {
  37493. $$415$i = $$4$ph$i;$$435114$i = $$3350$i;$$435713$i = $$4357$ph$i;
  37494. label = 85;
  37495. }
  37496. }
  37497. if ((label|0) == 85) {
  37498. while(1) {
  37499. label = 0;
  37500. $334 = ((($$435713$i)) + 4|0);
  37501. $335 = HEAP32[$334>>2]|0;
  37502. $336 = $335 & -8;
  37503. $337 = (($336) - ($249))|0;
  37504. $338 = ($337>>>0)<($$435114$i>>>0);
  37505. $$$4351$i = $338 ? $337 : $$435114$i;
  37506. $$4357$$4$i = $338 ? $$435713$i : $$415$i;
  37507. $339 = ((($$435713$i)) + 16|0);
  37508. $340 = HEAP32[$339>>2]|0;
  37509. $not$1$i203 = ($340|0)==(0|0);
  37510. $$sink2$i204 = $not$1$i203&1;
  37511. $341 = (((($$435713$i)) + 16|0) + ($$sink2$i204<<2)|0);
  37512. $342 = HEAP32[$341>>2]|0;
  37513. $343 = ($342|0)==(0|0);
  37514. if ($343) {
  37515. $$4$lcssa$i = $$4357$$4$i;$$4351$lcssa$i = $$$4351$i;
  37516. break;
  37517. } else {
  37518. $$415$i = $$4357$$4$i;$$435114$i = $$$4351$i;$$435713$i = $342;
  37519. label = 85;
  37520. }
  37521. }
  37522. }
  37523. $344 = ($$4$lcssa$i|0)==(0|0);
  37524. if ($344) {
  37525. $$0197 = $249;
  37526. } else {
  37527. $345 = HEAP32[(23704)>>2]|0;
  37528. $346 = (($345) - ($249))|0;
  37529. $347 = ($$4351$lcssa$i>>>0)<($346>>>0);
  37530. if ($347) {
  37531. $348 = HEAP32[(23712)>>2]|0;
  37532. $349 = ($$4$lcssa$i>>>0)<($348>>>0);
  37533. if ($349) {
  37534. _abort();
  37535. // unreachable;
  37536. }
  37537. $350 = (($$4$lcssa$i) + ($249)|0);
  37538. $351 = ($$4$lcssa$i>>>0)<($350>>>0);
  37539. if (!($351)) {
  37540. _abort();
  37541. // unreachable;
  37542. }
  37543. $352 = ((($$4$lcssa$i)) + 24|0);
  37544. $353 = HEAP32[$352>>2]|0;
  37545. $354 = ((($$4$lcssa$i)) + 12|0);
  37546. $355 = HEAP32[$354>>2]|0;
  37547. $356 = ($355|0)==($$4$lcssa$i|0);
  37548. do {
  37549. if ($356) {
  37550. $366 = ((($$4$lcssa$i)) + 20|0);
  37551. $367 = HEAP32[$366>>2]|0;
  37552. $368 = ($367|0)==(0|0);
  37553. if ($368) {
  37554. $369 = ((($$4$lcssa$i)) + 16|0);
  37555. $370 = HEAP32[$369>>2]|0;
  37556. $371 = ($370|0)==(0|0);
  37557. if ($371) {
  37558. $$3372$i = 0;
  37559. break;
  37560. } else {
  37561. $$1370$i = $370;$$1374$i = $369;
  37562. }
  37563. } else {
  37564. $$1370$i = $367;$$1374$i = $366;
  37565. }
  37566. while(1) {
  37567. $372 = ((($$1370$i)) + 20|0);
  37568. $373 = HEAP32[$372>>2]|0;
  37569. $374 = ($373|0)==(0|0);
  37570. if (!($374)) {
  37571. $$1370$i = $373;$$1374$i = $372;
  37572. continue;
  37573. }
  37574. $375 = ((($$1370$i)) + 16|0);
  37575. $376 = HEAP32[$375>>2]|0;
  37576. $377 = ($376|0)==(0|0);
  37577. if ($377) {
  37578. break;
  37579. } else {
  37580. $$1370$i = $376;$$1374$i = $375;
  37581. }
  37582. }
  37583. $378 = ($$1374$i>>>0)<($348>>>0);
  37584. if ($378) {
  37585. _abort();
  37586. // unreachable;
  37587. } else {
  37588. HEAP32[$$1374$i>>2] = 0;
  37589. $$3372$i = $$1370$i;
  37590. break;
  37591. }
  37592. } else {
  37593. $357 = ((($$4$lcssa$i)) + 8|0);
  37594. $358 = HEAP32[$357>>2]|0;
  37595. $359 = ($358>>>0)<($348>>>0);
  37596. if ($359) {
  37597. _abort();
  37598. // unreachable;
  37599. }
  37600. $360 = ((($358)) + 12|0);
  37601. $361 = HEAP32[$360>>2]|0;
  37602. $362 = ($361|0)==($$4$lcssa$i|0);
  37603. if (!($362)) {
  37604. _abort();
  37605. // unreachable;
  37606. }
  37607. $363 = ((($355)) + 8|0);
  37608. $364 = HEAP32[$363>>2]|0;
  37609. $365 = ($364|0)==($$4$lcssa$i|0);
  37610. if ($365) {
  37611. HEAP32[$360>>2] = $355;
  37612. HEAP32[$363>>2] = $358;
  37613. $$3372$i = $355;
  37614. break;
  37615. } else {
  37616. _abort();
  37617. // unreachable;
  37618. }
  37619. }
  37620. } while(0);
  37621. $379 = ($353|0)==(0|0);
  37622. L164: do {
  37623. if ($379) {
  37624. $470 = $250;
  37625. } else {
  37626. $380 = ((($$4$lcssa$i)) + 28|0);
  37627. $381 = HEAP32[$380>>2]|0;
  37628. $382 = (24000 + ($381<<2)|0);
  37629. $383 = HEAP32[$382>>2]|0;
  37630. $384 = ($$4$lcssa$i|0)==($383|0);
  37631. do {
  37632. if ($384) {
  37633. HEAP32[$382>>2] = $$3372$i;
  37634. $cond$i208 = ($$3372$i|0)==(0|0);
  37635. if ($cond$i208) {
  37636. $385 = 1 << $381;
  37637. $386 = $385 ^ -1;
  37638. $387 = $250 & $386;
  37639. HEAP32[(23700)>>2] = $387;
  37640. $470 = $387;
  37641. break L164;
  37642. }
  37643. } else {
  37644. $388 = HEAP32[(23712)>>2]|0;
  37645. $389 = ($353>>>0)<($388>>>0);
  37646. if ($389) {
  37647. _abort();
  37648. // unreachable;
  37649. } else {
  37650. $390 = ((($353)) + 16|0);
  37651. $391 = HEAP32[$390>>2]|0;
  37652. $not$$i209 = ($391|0)!=($$4$lcssa$i|0);
  37653. $$sink3$i = $not$$i209&1;
  37654. $392 = (((($353)) + 16|0) + ($$sink3$i<<2)|0);
  37655. HEAP32[$392>>2] = $$3372$i;
  37656. $393 = ($$3372$i|0)==(0|0);
  37657. if ($393) {
  37658. $470 = $250;
  37659. break L164;
  37660. } else {
  37661. break;
  37662. }
  37663. }
  37664. }
  37665. } while(0);
  37666. $394 = HEAP32[(23712)>>2]|0;
  37667. $395 = ($$3372$i>>>0)<($394>>>0);
  37668. if ($395) {
  37669. _abort();
  37670. // unreachable;
  37671. }
  37672. $396 = ((($$3372$i)) + 24|0);
  37673. HEAP32[$396>>2] = $353;
  37674. $397 = ((($$4$lcssa$i)) + 16|0);
  37675. $398 = HEAP32[$397>>2]|0;
  37676. $399 = ($398|0)==(0|0);
  37677. do {
  37678. if (!($399)) {
  37679. $400 = ($398>>>0)<($394>>>0);
  37680. if ($400) {
  37681. _abort();
  37682. // unreachable;
  37683. } else {
  37684. $401 = ((($$3372$i)) + 16|0);
  37685. HEAP32[$401>>2] = $398;
  37686. $402 = ((($398)) + 24|0);
  37687. HEAP32[$402>>2] = $$3372$i;
  37688. break;
  37689. }
  37690. }
  37691. } while(0);
  37692. $403 = ((($$4$lcssa$i)) + 20|0);
  37693. $404 = HEAP32[$403>>2]|0;
  37694. $405 = ($404|0)==(0|0);
  37695. if ($405) {
  37696. $470 = $250;
  37697. } else {
  37698. $406 = HEAP32[(23712)>>2]|0;
  37699. $407 = ($404>>>0)<($406>>>0);
  37700. if ($407) {
  37701. _abort();
  37702. // unreachable;
  37703. } else {
  37704. $408 = ((($$3372$i)) + 20|0);
  37705. HEAP32[$408>>2] = $404;
  37706. $409 = ((($404)) + 24|0);
  37707. HEAP32[$409>>2] = $$3372$i;
  37708. $470 = $250;
  37709. break;
  37710. }
  37711. }
  37712. }
  37713. } while(0);
  37714. $410 = ($$4351$lcssa$i>>>0)<(16);
  37715. do {
  37716. if ($410) {
  37717. $411 = (($$4351$lcssa$i) + ($249))|0;
  37718. $412 = $411 | 3;
  37719. $413 = ((($$4$lcssa$i)) + 4|0);
  37720. HEAP32[$413>>2] = $412;
  37721. $414 = (($$4$lcssa$i) + ($411)|0);
  37722. $415 = ((($414)) + 4|0);
  37723. $416 = HEAP32[$415>>2]|0;
  37724. $417 = $416 | 1;
  37725. HEAP32[$415>>2] = $417;
  37726. } else {
  37727. $418 = $249 | 3;
  37728. $419 = ((($$4$lcssa$i)) + 4|0);
  37729. HEAP32[$419>>2] = $418;
  37730. $420 = $$4351$lcssa$i | 1;
  37731. $421 = ((($350)) + 4|0);
  37732. HEAP32[$421>>2] = $420;
  37733. $422 = (($350) + ($$4351$lcssa$i)|0);
  37734. HEAP32[$422>>2] = $$4351$lcssa$i;
  37735. $423 = $$4351$lcssa$i >>> 3;
  37736. $424 = ($$4351$lcssa$i>>>0)<(256);
  37737. if ($424) {
  37738. $425 = $423 << 1;
  37739. $426 = (23736 + ($425<<2)|0);
  37740. $427 = HEAP32[5924]|0;
  37741. $428 = 1 << $423;
  37742. $429 = $427 & $428;
  37743. $430 = ($429|0)==(0);
  37744. if ($430) {
  37745. $431 = $427 | $428;
  37746. HEAP32[5924] = $431;
  37747. $$pre$i210 = ((($426)) + 8|0);
  37748. $$0368$i = $426;$$pre$phi$i211Z2D = $$pre$i210;
  37749. } else {
  37750. $432 = ((($426)) + 8|0);
  37751. $433 = HEAP32[$432>>2]|0;
  37752. $434 = HEAP32[(23712)>>2]|0;
  37753. $435 = ($433>>>0)<($434>>>0);
  37754. if ($435) {
  37755. _abort();
  37756. // unreachable;
  37757. } else {
  37758. $$0368$i = $433;$$pre$phi$i211Z2D = $432;
  37759. }
  37760. }
  37761. HEAP32[$$pre$phi$i211Z2D>>2] = $350;
  37762. $436 = ((($$0368$i)) + 12|0);
  37763. HEAP32[$436>>2] = $350;
  37764. $437 = ((($350)) + 8|0);
  37765. HEAP32[$437>>2] = $$0368$i;
  37766. $438 = ((($350)) + 12|0);
  37767. HEAP32[$438>>2] = $426;
  37768. break;
  37769. }
  37770. $439 = $$4351$lcssa$i >>> 8;
  37771. $440 = ($439|0)==(0);
  37772. if ($440) {
  37773. $$0361$i = 0;
  37774. } else {
  37775. $441 = ($$4351$lcssa$i>>>0)>(16777215);
  37776. if ($441) {
  37777. $$0361$i = 31;
  37778. } else {
  37779. $442 = (($439) + 1048320)|0;
  37780. $443 = $442 >>> 16;
  37781. $444 = $443 & 8;
  37782. $445 = $439 << $444;
  37783. $446 = (($445) + 520192)|0;
  37784. $447 = $446 >>> 16;
  37785. $448 = $447 & 4;
  37786. $449 = $448 | $444;
  37787. $450 = $445 << $448;
  37788. $451 = (($450) + 245760)|0;
  37789. $452 = $451 >>> 16;
  37790. $453 = $452 & 2;
  37791. $454 = $449 | $453;
  37792. $455 = (14 - ($454))|0;
  37793. $456 = $450 << $453;
  37794. $457 = $456 >>> 15;
  37795. $458 = (($455) + ($457))|0;
  37796. $459 = $458 << 1;
  37797. $460 = (($458) + 7)|0;
  37798. $461 = $$4351$lcssa$i >>> $460;
  37799. $462 = $461 & 1;
  37800. $463 = $462 | $459;
  37801. $$0361$i = $463;
  37802. }
  37803. }
  37804. $464 = (24000 + ($$0361$i<<2)|0);
  37805. $465 = ((($350)) + 28|0);
  37806. HEAP32[$465>>2] = $$0361$i;
  37807. $466 = ((($350)) + 16|0);
  37808. $467 = ((($466)) + 4|0);
  37809. HEAP32[$467>>2] = 0;
  37810. HEAP32[$466>>2] = 0;
  37811. $468 = 1 << $$0361$i;
  37812. $469 = $470 & $468;
  37813. $471 = ($469|0)==(0);
  37814. if ($471) {
  37815. $472 = $470 | $468;
  37816. HEAP32[(23700)>>2] = $472;
  37817. HEAP32[$464>>2] = $350;
  37818. $473 = ((($350)) + 24|0);
  37819. HEAP32[$473>>2] = $464;
  37820. $474 = ((($350)) + 12|0);
  37821. HEAP32[$474>>2] = $350;
  37822. $475 = ((($350)) + 8|0);
  37823. HEAP32[$475>>2] = $350;
  37824. break;
  37825. }
  37826. $476 = HEAP32[$464>>2]|0;
  37827. $477 = ($$0361$i|0)==(31);
  37828. $478 = $$0361$i >>> 1;
  37829. $479 = (25 - ($478))|0;
  37830. $480 = $477 ? 0 : $479;
  37831. $481 = $$4351$lcssa$i << $480;
  37832. $$0344$i = $481;$$0345$i = $476;
  37833. while(1) {
  37834. $482 = ((($$0345$i)) + 4|0);
  37835. $483 = HEAP32[$482>>2]|0;
  37836. $484 = $483 & -8;
  37837. $485 = ($484|0)==($$4351$lcssa$i|0);
  37838. if ($485) {
  37839. label = 139;
  37840. break;
  37841. }
  37842. $486 = $$0344$i >>> 31;
  37843. $487 = (((($$0345$i)) + 16|0) + ($486<<2)|0);
  37844. $488 = $$0344$i << 1;
  37845. $489 = HEAP32[$487>>2]|0;
  37846. $490 = ($489|0)==(0|0);
  37847. if ($490) {
  37848. label = 136;
  37849. break;
  37850. } else {
  37851. $$0344$i = $488;$$0345$i = $489;
  37852. }
  37853. }
  37854. if ((label|0) == 136) {
  37855. $491 = HEAP32[(23712)>>2]|0;
  37856. $492 = ($487>>>0)<($491>>>0);
  37857. if ($492) {
  37858. _abort();
  37859. // unreachable;
  37860. } else {
  37861. HEAP32[$487>>2] = $350;
  37862. $493 = ((($350)) + 24|0);
  37863. HEAP32[$493>>2] = $$0345$i;
  37864. $494 = ((($350)) + 12|0);
  37865. HEAP32[$494>>2] = $350;
  37866. $495 = ((($350)) + 8|0);
  37867. HEAP32[$495>>2] = $350;
  37868. break;
  37869. }
  37870. }
  37871. else if ((label|0) == 139) {
  37872. $496 = ((($$0345$i)) + 8|0);
  37873. $497 = HEAP32[$496>>2]|0;
  37874. $498 = HEAP32[(23712)>>2]|0;
  37875. $499 = ($497>>>0)>=($498>>>0);
  37876. $not$9$i = ($$0345$i>>>0)>=($498>>>0);
  37877. $500 = $499 & $not$9$i;
  37878. if ($500) {
  37879. $501 = ((($497)) + 12|0);
  37880. HEAP32[$501>>2] = $350;
  37881. HEAP32[$496>>2] = $350;
  37882. $502 = ((($350)) + 8|0);
  37883. HEAP32[$502>>2] = $497;
  37884. $503 = ((($350)) + 12|0);
  37885. HEAP32[$503>>2] = $$0345$i;
  37886. $504 = ((($350)) + 24|0);
  37887. HEAP32[$504>>2] = 0;
  37888. break;
  37889. } else {
  37890. _abort();
  37891. // unreachable;
  37892. }
  37893. }
  37894. }
  37895. } while(0);
  37896. $505 = ((($$4$lcssa$i)) + 8|0);
  37897. $$0 = $505;
  37898. STACKTOP = sp;return ($$0|0);
  37899. } else {
  37900. $$0197 = $249;
  37901. }
  37902. }
  37903. }
  37904. }
  37905. }
  37906. } while(0);
  37907. $506 = HEAP32[(23704)>>2]|0;
  37908. $507 = ($506>>>0)<($$0197>>>0);
  37909. if (!($507)) {
  37910. $508 = (($506) - ($$0197))|0;
  37911. $509 = HEAP32[(23716)>>2]|0;
  37912. $510 = ($508>>>0)>(15);
  37913. if ($510) {
  37914. $511 = (($509) + ($$0197)|0);
  37915. HEAP32[(23716)>>2] = $511;
  37916. HEAP32[(23704)>>2] = $508;
  37917. $512 = $508 | 1;
  37918. $513 = ((($511)) + 4|0);
  37919. HEAP32[$513>>2] = $512;
  37920. $514 = (($511) + ($508)|0);
  37921. HEAP32[$514>>2] = $508;
  37922. $515 = $$0197 | 3;
  37923. $516 = ((($509)) + 4|0);
  37924. HEAP32[$516>>2] = $515;
  37925. } else {
  37926. HEAP32[(23704)>>2] = 0;
  37927. HEAP32[(23716)>>2] = 0;
  37928. $517 = $506 | 3;
  37929. $518 = ((($509)) + 4|0);
  37930. HEAP32[$518>>2] = $517;
  37931. $519 = (($509) + ($506)|0);
  37932. $520 = ((($519)) + 4|0);
  37933. $521 = HEAP32[$520>>2]|0;
  37934. $522 = $521 | 1;
  37935. HEAP32[$520>>2] = $522;
  37936. }
  37937. $523 = ((($509)) + 8|0);
  37938. $$0 = $523;
  37939. STACKTOP = sp;return ($$0|0);
  37940. }
  37941. $524 = HEAP32[(23708)>>2]|0;
  37942. $525 = ($524>>>0)>($$0197>>>0);
  37943. if ($525) {
  37944. $526 = (($524) - ($$0197))|0;
  37945. HEAP32[(23708)>>2] = $526;
  37946. $527 = HEAP32[(23720)>>2]|0;
  37947. $528 = (($527) + ($$0197)|0);
  37948. HEAP32[(23720)>>2] = $528;
  37949. $529 = $526 | 1;
  37950. $530 = ((($528)) + 4|0);
  37951. HEAP32[$530>>2] = $529;
  37952. $531 = $$0197 | 3;
  37953. $532 = ((($527)) + 4|0);
  37954. HEAP32[$532>>2] = $531;
  37955. $533 = ((($527)) + 8|0);
  37956. $$0 = $533;
  37957. STACKTOP = sp;return ($$0|0);
  37958. }
  37959. $534 = HEAP32[6042]|0;
  37960. $535 = ($534|0)==(0);
  37961. if ($535) {
  37962. HEAP32[(24176)>>2] = 4096;
  37963. HEAP32[(24172)>>2] = 4096;
  37964. HEAP32[(24180)>>2] = -1;
  37965. HEAP32[(24184)>>2] = -1;
  37966. HEAP32[(24188)>>2] = 0;
  37967. HEAP32[(24140)>>2] = 0;
  37968. $536 = $1;
  37969. $537 = $536 & -16;
  37970. $538 = $537 ^ 1431655768;
  37971. HEAP32[$1>>2] = $538;
  37972. HEAP32[6042] = $538;
  37973. $542 = 4096;
  37974. } else {
  37975. $$pre$i212 = HEAP32[(24176)>>2]|0;
  37976. $542 = $$pre$i212;
  37977. }
  37978. $539 = (($$0197) + 48)|0;
  37979. $540 = (($$0197) + 47)|0;
  37980. $541 = (($542) + ($540))|0;
  37981. $543 = (0 - ($542))|0;
  37982. $544 = $541 & $543;
  37983. $545 = ($544>>>0)>($$0197>>>0);
  37984. if (!($545)) {
  37985. $$0 = 0;
  37986. STACKTOP = sp;return ($$0|0);
  37987. }
  37988. $546 = HEAP32[(24136)>>2]|0;
  37989. $547 = ($546|0)==(0);
  37990. if (!($547)) {
  37991. $548 = HEAP32[(24128)>>2]|0;
  37992. $549 = (($548) + ($544))|0;
  37993. $550 = ($549>>>0)<=($548>>>0);
  37994. $551 = ($549>>>0)>($546>>>0);
  37995. $or$cond1$i = $550 | $551;
  37996. if ($or$cond1$i) {
  37997. $$0 = 0;
  37998. STACKTOP = sp;return ($$0|0);
  37999. }
  38000. }
  38001. $552 = HEAP32[(24140)>>2]|0;
  38002. $553 = $552 & 4;
  38003. $554 = ($553|0)==(0);
  38004. L244: do {
  38005. if ($554) {
  38006. $555 = HEAP32[(23720)>>2]|0;
  38007. $556 = ($555|0)==(0|0);
  38008. L246: do {
  38009. if ($556) {
  38010. label = 163;
  38011. } else {
  38012. $$0$i$i = (24144);
  38013. while(1) {
  38014. $557 = HEAP32[$$0$i$i>>2]|0;
  38015. $558 = ($557>>>0)>($555>>>0);
  38016. if (!($558)) {
  38017. $559 = ((($$0$i$i)) + 4|0);
  38018. $560 = HEAP32[$559>>2]|0;
  38019. $561 = (($557) + ($560)|0);
  38020. $562 = ($561>>>0)>($555>>>0);
  38021. if ($562) {
  38022. break;
  38023. }
  38024. }
  38025. $563 = ((($$0$i$i)) + 8|0);
  38026. $564 = HEAP32[$563>>2]|0;
  38027. $565 = ($564|0)==(0|0);
  38028. if ($565) {
  38029. label = 163;
  38030. break L246;
  38031. } else {
  38032. $$0$i$i = $564;
  38033. }
  38034. }
  38035. $588 = (($541) - ($524))|0;
  38036. $589 = $588 & $543;
  38037. $590 = ($589>>>0)<(2147483647);
  38038. if ($590) {
  38039. $591 = (_sbrk(($589|0))|0);
  38040. $592 = HEAP32[$$0$i$i>>2]|0;
  38041. $593 = HEAP32[$559>>2]|0;
  38042. $594 = (($592) + ($593)|0);
  38043. $595 = ($591|0)==($594|0);
  38044. if ($595) {
  38045. $596 = ($591|0)==((-1)|0);
  38046. if ($596) {
  38047. $$2234253237$i = $589;
  38048. } else {
  38049. $$723948$i = $589;$$749$i = $591;
  38050. label = 180;
  38051. break L244;
  38052. }
  38053. } else {
  38054. $$2247$ph$i = $591;$$2253$ph$i = $589;
  38055. label = 171;
  38056. }
  38057. } else {
  38058. $$2234253237$i = 0;
  38059. }
  38060. }
  38061. } while(0);
  38062. do {
  38063. if ((label|0) == 163) {
  38064. $566 = (_sbrk(0)|0);
  38065. $567 = ($566|0)==((-1)|0);
  38066. if ($567) {
  38067. $$2234253237$i = 0;
  38068. } else {
  38069. $568 = $566;
  38070. $569 = HEAP32[(24172)>>2]|0;
  38071. $570 = (($569) + -1)|0;
  38072. $571 = $570 & $568;
  38073. $572 = ($571|0)==(0);
  38074. $573 = (($570) + ($568))|0;
  38075. $574 = (0 - ($569))|0;
  38076. $575 = $573 & $574;
  38077. $576 = (($575) - ($568))|0;
  38078. $577 = $572 ? 0 : $576;
  38079. $$$i = (($577) + ($544))|0;
  38080. $578 = HEAP32[(24128)>>2]|0;
  38081. $579 = (($$$i) + ($578))|0;
  38082. $580 = ($$$i>>>0)>($$0197>>>0);
  38083. $581 = ($$$i>>>0)<(2147483647);
  38084. $or$cond$i214 = $580 & $581;
  38085. if ($or$cond$i214) {
  38086. $582 = HEAP32[(24136)>>2]|0;
  38087. $583 = ($582|0)==(0);
  38088. if (!($583)) {
  38089. $584 = ($579>>>0)<=($578>>>0);
  38090. $585 = ($579>>>0)>($582>>>0);
  38091. $or$cond2$i215 = $584 | $585;
  38092. if ($or$cond2$i215) {
  38093. $$2234253237$i = 0;
  38094. break;
  38095. }
  38096. }
  38097. $586 = (_sbrk(($$$i|0))|0);
  38098. $587 = ($586|0)==($566|0);
  38099. if ($587) {
  38100. $$723948$i = $$$i;$$749$i = $566;
  38101. label = 180;
  38102. break L244;
  38103. } else {
  38104. $$2247$ph$i = $586;$$2253$ph$i = $$$i;
  38105. label = 171;
  38106. }
  38107. } else {
  38108. $$2234253237$i = 0;
  38109. }
  38110. }
  38111. }
  38112. } while(0);
  38113. do {
  38114. if ((label|0) == 171) {
  38115. $597 = (0 - ($$2253$ph$i))|0;
  38116. $598 = ($$2247$ph$i|0)!=((-1)|0);
  38117. $599 = ($$2253$ph$i>>>0)<(2147483647);
  38118. $or$cond7$i = $599 & $598;
  38119. $600 = ($539>>>0)>($$2253$ph$i>>>0);
  38120. $or$cond10$i = $600 & $or$cond7$i;
  38121. if (!($or$cond10$i)) {
  38122. $610 = ($$2247$ph$i|0)==((-1)|0);
  38123. if ($610) {
  38124. $$2234253237$i = 0;
  38125. break;
  38126. } else {
  38127. $$723948$i = $$2253$ph$i;$$749$i = $$2247$ph$i;
  38128. label = 180;
  38129. break L244;
  38130. }
  38131. }
  38132. $601 = HEAP32[(24176)>>2]|0;
  38133. $602 = (($540) - ($$2253$ph$i))|0;
  38134. $603 = (($602) + ($601))|0;
  38135. $604 = (0 - ($601))|0;
  38136. $605 = $603 & $604;
  38137. $606 = ($605>>>0)<(2147483647);
  38138. if (!($606)) {
  38139. $$723948$i = $$2253$ph$i;$$749$i = $$2247$ph$i;
  38140. label = 180;
  38141. break L244;
  38142. }
  38143. $607 = (_sbrk(($605|0))|0);
  38144. $608 = ($607|0)==((-1)|0);
  38145. if ($608) {
  38146. (_sbrk(($597|0))|0);
  38147. $$2234253237$i = 0;
  38148. break;
  38149. } else {
  38150. $609 = (($605) + ($$2253$ph$i))|0;
  38151. $$723948$i = $609;$$749$i = $$2247$ph$i;
  38152. label = 180;
  38153. break L244;
  38154. }
  38155. }
  38156. } while(0);
  38157. $611 = HEAP32[(24140)>>2]|0;
  38158. $612 = $611 | 4;
  38159. HEAP32[(24140)>>2] = $612;
  38160. $$4236$i = $$2234253237$i;
  38161. label = 178;
  38162. } else {
  38163. $$4236$i = 0;
  38164. label = 178;
  38165. }
  38166. } while(0);
  38167. if ((label|0) == 178) {
  38168. $613 = ($544>>>0)<(2147483647);
  38169. if ($613) {
  38170. $614 = (_sbrk(($544|0))|0);
  38171. $615 = (_sbrk(0)|0);
  38172. $616 = ($614|0)!=((-1)|0);
  38173. $617 = ($615|0)!=((-1)|0);
  38174. $or$cond5$i = $616 & $617;
  38175. $618 = ($614>>>0)<($615>>>0);
  38176. $or$cond11$i = $618 & $or$cond5$i;
  38177. $619 = $615;
  38178. $620 = $614;
  38179. $621 = (($619) - ($620))|0;
  38180. $622 = (($$0197) + 40)|0;
  38181. $623 = ($621>>>0)>($622>>>0);
  38182. $$$4236$i = $623 ? $621 : $$4236$i;
  38183. $or$cond11$not$i = $or$cond11$i ^ 1;
  38184. $624 = ($614|0)==((-1)|0);
  38185. $not$$i216 = $623 ^ 1;
  38186. $625 = $624 | $not$$i216;
  38187. $or$cond50$i = $625 | $or$cond11$not$i;
  38188. if (!($or$cond50$i)) {
  38189. $$723948$i = $$$4236$i;$$749$i = $614;
  38190. label = 180;
  38191. }
  38192. }
  38193. }
  38194. if ((label|0) == 180) {
  38195. $626 = HEAP32[(24128)>>2]|0;
  38196. $627 = (($626) + ($$723948$i))|0;
  38197. HEAP32[(24128)>>2] = $627;
  38198. $628 = HEAP32[(24132)>>2]|0;
  38199. $629 = ($627>>>0)>($628>>>0);
  38200. if ($629) {
  38201. HEAP32[(24132)>>2] = $627;
  38202. }
  38203. $630 = HEAP32[(23720)>>2]|0;
  38204. $631 = ($630|0)==(0|0);
  38205. do {
  38206. if ($631) {
  38207. $632 = HEAP32[(23712)>>2]|0;
  38208. $633 = ($632|0)==(0|0);
  38209. $634 = ($$749$i>>>0)<($632>>>0);
  38210. $or$cond12$i = $633 | $634;
  38211. if ($or$cond12$i) {
  38212. HEAP32[(23712)>>2] = $$749$i;
  38213. }
  38214. HEAP32[(24144)>>2] = $$749$i;
  38215. HEAP32[(24148)>>2] = $$723948$i;
  38216. HEAP32[(24156)>>2] = 0;
  38217. $635 = HEAP32[6042]|0;
  38218. HEAP32[(23732)>>2] = $635;
  38219. HEAP32[(23728)>>2] = -1;
  38220. $$01$i$i = 0;
  38221. while(1) {
  38222. $636 = $$01$i$i << 1;
  38223. $637 = (23736 + ($636<<2)|0);
  38224. $638 = ((($637)) + 12|0);
  38225. HEAP32[$638>>2] = $637;
  38226. $639 = ((($637)) + 8|0);
  38227. HEAP32[$639>>2] = $637;
  38228. $640 = (($$01$i$i) + 1)|0;
  38229. $exitcond$i$i = ($640|0)==(32);
  38230. if ($exitcond$i$i) {
  38231. break;
  38232. } else {
  38233. $$01$i$i = $640;
  38234. }
  38235. }
  38236. $641 = (($$723948$i) + -40)|0;
  38237. $642 = ((($$749$i)) + 8|0);
  38238. $643 = $642;
  38239. $644 = $643 & 7;
  38240. $645 = ($644|0)==(0);
  38241. $646 = (0 - ($643))|0;
  38242. $647 = $646 & 7;
  38243. $648 = $645 ? 0 : $647;
  38244. $649 = (($$749$i) + ($648)|0);
  38245. $650 = (($641) - ($648))|0;
  38246. HEAP32[(23720)>>2] = $649;
  38247. HEAP32[(23708)>>2] = $650;
  38248. $651 = $650 | 1;
  38249. $652 = ((($649)) + 4|0);
  38250. HEAP32[$652>>2] = $651;
  38251. $653 = (($649) + ($650)|0);
  38252. $654 = ((($653)) + 4|0);
  38253. HEAP32[$654>>2] = 40;
  38254. $655 = HEAP32[(24184)>>2]|0;
  38255. HEAP32[(23724)>>2] = $655;
  38256. } else {
  38257. $$024371$i = (24144);
  38258. while(1) {
  38259. $656 = HEAP32[$$024371$i>>2]|0;
  38260. $657 = ((($$024371$i)) + 4|0);
  38261. $658 = HEAP32[$657>>2]|0;
  38262. $659 = (($656) + ($658)|0);
  38263. $660 = ($$749$i|0)==($659|0);
  38264. if ($660) {
  38265. label = 190;
  38266. break;
  38267. }
  38268. $661 = ((($$024371$i)) + 8|0);
  38269. $662 = HEAP32[$661>>2]|0;
  38270. $663 = ($662|0)==(0|0);
  38271. if ($663) {
  38272. break;
  38273. } else {
  38274. $$024371$i = $662;
  38275. }
  38276. }
  38277. if ((label|0) == 190) {
  38278. $664 = ((($$024371$i)) + 12|0);
  38279. $665 = HEAP32[$664>>2]|0;
  38280. $666 = $665 & 8;
  38281. $667 = ($666|0)==(0);
  38282. if ($667) {
  38283. $668 = ($630>>>0)>=($656>>>0);
  38284. $669 = ($630>>>0)<($$749$i>>>0);
  38285. $or$cond51$i = $669 & $668;
  38286. if ($or$cond51$i) {
  38287. $670 = (($658) + ($$723948$i))|0;
  38288. HEAP32[$657>>2] = $670;
  38289. $671 = HEAP32[(23708)>>2]|0;
  38290. $672 = ((($630)) + 8|0);
  38291. $673 = $672;
  38292. $674 = $673 & 7;
  38293. $675 = ($674|0)==(0);
  38294. $676 = (0 - ($673))|0;
  38295. $677 = $676 & 7;
  38296. $678 = $675 ? 0 : $677;
  38297. $679 = (($630) + ($678)|0);
  38298. $680 = (($$723948$i) - ($678))|0;
  38299. $681 = (($671) + ($680))|0;
  38300. HEAP32[(23720)>>2] = $679;
  38301. HEAP32[(23708)>>2] = $681;
  38302. $682 = $681 | 1;
  38303. $683 = ((($679)) + 4|0);
  38304. HEAP32[$683>>2] = $682;
  38305. $684 = (($679) + ($681)|0);
  38306. $685 = ((($684)) + 4|0);
  38307. HEAP32[$685>>2] = 40;
  38308. $686 = HEAP32[(24184)>>2]|0;
  38309. HEAP32[(23724)>>2] = $686;
  38310. break;
  38311. }
  38312. }
  38313. }
  38314. $687 = HEAP32[(23712)>>2]|0;
  38315. $688 = ($$749$i>>>0)<($687>>>0);
  38316. if ($688) {
  38317. HEAP32[(23712)>>2] = $$749$i;
  38318. $752 = $$749$i;
  38319. } else {
  38320. $752 = $687;
  38321. }
  38322. $689 = (($$749$i) + ($$723948$i)|0);
  38323. $$124470$i = (24144);
  38324. while(1) {
  38325. $690 = HEAP32[$$124470$i>>2]|0;
  38326. $691 = ($690|0)==($689|0);
  38327. if ($691) {
  38328. label = 198;
  38329. break;
  38330. }
  38331. $692 = ((($$124470$i)) + 8|0);
  38332. $693 = HEAP32[$692>>2]|0;
  38333. $694 = ($693|0)==(0|0);
  38334. if ($694) {
  38335. break;
  38336. } else {
  38337. $$124470$i = $693;
  38338. }
  38339. }
  38340. if ((label|0) == 198) {
  38341. $695 = ((($$124470$i)) + 12|0);
  38342. $696 = HEAP32[$695>>2]|0;
  38343. $697 = $696 & 8;
  38344. $698 = ($697|0)==(0);
  38345. if ($698) {
  38346. HEAP32[$$124470$i>>2] = $$749$i;
  38347. $699 = ((($$124470$i)) + 4|0);
  38348. $700 = HEAP32[$699>>2]|0;
  38349. $701 = (($700) + ($$723948$i))|0;
  38350. HEAP32[$699>>2] = $701;
  38351. $702 = ((($$749$i)) + 8|0);
  38352. $703 = $702;
  38353. $704 = $703 & 7;
  38354. $705 = ($704|0)==(0);
  38355. $706 = (0 - ($703))|0;
  38356. $707 = $706 & 7;
  38357. $708 = $705 ? 0 : $707;
  38358. $709 = (($$749$i) + ($708)|0);
  38359. $710 = ((($689)) + 8|0);
  38360. $711 = $710;
  38361. $712 = $711 & 7;
  38362. $713 = ($712|0)==(0);
  38363. $714 = (0 - ($711))|0;
  38364. $715 = $714 & 7;
  38365. $716 = $713 ? 0 : $715;
  38366. $717 = (($689) + ($716)|0);
  38367. $718 = $717;
  38368. $719 = $709;
  38369. $720 = (($718) - ($719))|0;
  38370. $721 = (($709) + ($$0197)|0);
  38371. $722 = (($720) - ($$0197))|0;
  38372. $723 = $$0197 | 3;
  38373. $724 = ((($709)) + 4|0);
  38374. HEAP32[$724>>2] = $723;
  38375. $725 = ($717|0)==($630|0);
  38376. do {
  38377. if ($725) {
  38378. $726 = HEAP32[(23708)>>2]|0;
  38379. $727 = (($726) + ($722))|0;
  38380. HEAP32[(23708)>>2] = $727;
  38381. HEAP32[(23720)>>2] = $721;
  38382. $728 = $727 | 1;
  38383. $729 = ((($721)) + 4|0);
  38384. HEAP32[$729>>2] = $728;
  38385. } else {
  38386. $730 = HEAP32[(23716)>>2]|0;
  38387. $731 = ($717|0)==($730|0);
  38388. if ($731) {
  38389. $732 = HEAP32[(23704)>>2]|0;
  38390. $733 = (($732) + ($722))|0;
  38391. HEAP32[(23704)>>2] = $733;
  38392. HEAP32[(23716)>>2] = $721;
  38393. $734 = $733 | 1;
  38394. $735 = ((($721)) + 4|0);
  38395. HEAP32[$735>>2] = $734;
  38396. $736 = (($721) + ($733)|0);
  38397. HEAP32[$736>>2] = $733;
  38398. break;
  38399. }
  38400. $737 = ((($717)) + 4|0);
  38401. $738 = HEAP32[$737>>2]|0;
  38402. $739 = $738 & 3;
  38403. $740 = ($739|0)==(1);
  38404. if ($740) {
  38405. $741 = $738 & -8;
  38406. $742 = $738 >>> 3;
  38407. $743 = ($738>>>0)<(256);
  38408. L314: do {
  38409. if ($743) {
  38410. $744 = ((($717)) + 8|0);
  38411. $745 = HEAP32[$744>>2]|0;
  38412. $746 = ((($717)) + 12|0);
  38413. $747 = HEAP32[$746>>2]|0;
  38414. $748 = $742 << 1;
  38415. $749 = (23736 + ($748<<2)|0);
  38416. $750 = ($745|0)==($749|0);
  38417. do {
  38418. if (!($750)) {
  38419. $751 = ($745>>>0)<($752>>>0);
  38420. if ($751) {
  38421. _abort();
  38422. // unreachable;
  38423. }
  38424. $753 = ((($745)) + 12|0);
  38425. $754 = HEAP32[$753>>2]|0;
  38426. $755 = ($754|0)==($717|0);
  38427. if ($755) {
  38428. break;
  38429. }
  38430. _abort();
  38431. // unreachable;
  38432. }
  38433. } while(0);
  38434. $756 = ($747|0)==($745|0);
  38435. if ($756) {
  38436. $757 = 1 << $742;
  38437. $758 = $757 ^ -1;
  38438. $759 = HEAP32[5924]|0;
  38439. $760 = $759 & $758;
  38440. HEAP32[5924] = $760;
  38441. break;
  38442. }
  38443. $761 = ($747|0)==($749|0);
  38444. do {
  38445. if ($761) {
  38446. $$pre10$i$i = ((($747)) + 8|0);
  38447. $$pre$phi11$i$iZ2D = $$pre10$i$i;
  38448. } else {
  38449. $762 = ($747>>>0)<($752>>>0);
  38450. if ($762) {
  38451. _abort();
  38452. // unreachable;
  38453. }
  38454. $763 = ((($747)) + 8|0);
  38455. $764 = HEAP32[$763>>2]|0;
  38456. $765 = ($764|0)==($717|0);
  38457. if ($765) {
  38458. $$pre$phi11$i$iZ2D = $763;
  38459. break;
  38460. }
  38461. _abort();
  38462. // unreachable;
  38463. }
  38464. } while(0);
  38465. $766 = ((($745)) + 12|0);
  38466. HEAP32[$766>>2] = $747;
  38467. HEAP32[$$pre$phi11$i$iZ2D>>2] = $745;
  38468. } else {
  38469. $767 = ((($717)) + 24|0);
  38470. $768 = HEAP32[$767>>2]|0;
  38471. $769 = ((($717)) + 12|0);
  38472. $770 = HEAP32[$769>>2]|0;
  38473. $771 = ($770|0)==($717|0);
  38474. do {
  38475. if ($771) {
  38476. $781 = ((($717)) + 16|0);
  38477. $782 = ((($781)) + 4|0);
  38478. $783 = HEAP32[$782>>2]|0;
  38479. $784 = ($783|0)==(0|0);
  38480. if ($784) {
  38481. $785 = HEAP32[$781>>2]|0;
  38482. $786 = ($785|0)==(0|0);
  38483. if ($786) {
  38484. $$3$i$i = 0;
  38485. break;
  38486. } else {
  38487. $$1291$i$i = $785;$$1293$i$i = $781;
  38488. }
  38489. } else {
  38490. $$1291$i$i = $783;$$1293$i$i = $782;
  38491. }
  38492. while(1) {
  38493. $787 = ((($$1291$i$i)) + 20|0);
  38494. $788 = HEAP32[$787>>2]|0;
  38495. $789 = ($788|0)==(0|0);
  38496. if (!($789)) {
  38497. $$1291$i$i = $788;$$1293$i$i = $787;
  38498. continue;
  38499. }
  38500. $790 = ((($$1291$i$i)) + 16|0);
  38501. $791 = HEAP32[$790>>2]|0;
  38502. $792 = ($791|0)==(0|0);
  38503. if ($792) {
  38504. break;
  38505. } else {
  38506. $$1291$i$i = $791;$$1293$i$i = $790;
  38507. }
  38508. }
  38509. $793 = ($$1293$i$i>>>0)<($752>>>0);
  38510. if ($793) {
  38511. _abort();
  38512. // unreachable;
  38513. } else {
  38514. HEAP32[$$1293$i$i>>2] = 0;
  38515. $$3$i$i = $$1291$i$i;
  38516. break;
  38517. }
  38518. } else {
  38519. $772 = ((($717)) + 8|0);
  38520. $773 = HEAP32[$772>>2]|0;
  38521. $774 = ($773>>>0)<($752>>>0);
  38522. if ($774) {
  38523. _abort();
  38524. // unreachable;
  38525. }
  38526. $775 = ((($773)) + 12|0);
  38527. $776 = HEAP32[$775>>2]|0;
  38528. $777 = ($776|0)==($717|0);
  38529. if (!($777)) {
  38530. _abort();
  38531. // unreachable;
  38532. }
  38533. $778 = ((($770)) + 8|0);
  38534. $779 = HEAP32[$778>>2]|0;
  38535. $780 = ($779|0)==($717|0);
  38536. if ($780) {
  38537. HEAP32[$775>>2] = $770;
  38538. HEAP32[$778>>2] = $773;
  38539. $$3$i$i = $770;
  38540. break;
  38541. } else {
  38542. _abort();
  38543. // unreachable;
  38544. }
  38545. }
  38546. } while(0);
  38547. $794 = ($768|0)==(0|0);
  38548. if ($794) {
  38549. break;
  38550. }
  38551. $795 = ((($717)) + 28|0);
  38552. $796 = HEAP32[$795>>2]|0;
  38553. $797 = (24000 + ($796<<2)|0);
  38554. $798 = HEAP32[$797>>2]|0;
  38555. $799 = ($717|0)==($798|0);
  38556. do {
  38557. if ($799) {
  38558. HEAP32[$797>>2] = $$3$i$i;
  38559. $cond$i$i = ($$3$i$i|0)==(0|0);
  38560. if (!($cond$i$i)) {
  38561. break;
  38562. }
  38563. $800 = 1 << $796;
  38564. $801 = $800 ^ -1;
  38565. $802 = HEAP32[(23700)>>2]|0;
  38566. $803 = $802 & $801;
  38567. HEAP32[(23700)>>2] = $803;
  38568. break L314;
  38569. } else {
  38570. $804 = HEAP32[(23712)>>2]|0;
  38571. $805 = ($768>>>0)<($804>>>0);
  38572. if ($805) {
  38573. _abort();
  38574. // unreachable;
  38575. } else {
  38576. $806 = ((($768)) + 16|0);
  38577. $807 = HEAP32[$806>>2]|0;
  38578. $not$$i17$i = ($807|0)!=($717|0);
  38579. $$sink1$i$i = $not$$i17$i&1;
  38580. $808 = (((($768)) + 16|0) + ($$sink1$i$i<<2)|0);
  38581. HEAP32[$808>>2] = $$3$i$i;
  38582. $809 = ($$3$i$i|0)==(0|0);
  38583. if ($809) {
  38584. break L314;
  38585. } else {
  38586. break;
  38587. }
  38588. }
  38589. }
  38590. } while(0);
  38591. $810 = HEAP32[(23712)>>2]|0;
  38592. $811 = ($$3$i$i>>>0)<($810>>>0);
  38593. if ($811) {
  38594. _abort();
  38595. // unreachable;
  38596. }
  38597. $812 = ((($$3$i$i)) + 24|0);
  38598. HEAP32[$812>>2] = $768;
  38599. $813 = ((($717)) + 16|0);
  38600. $814 = HEAP32[$813>>2]|0;
  38601. $815 = ($814|0)==(0|0);
  38602. do {
  38603. if (!($815)) {
  38604. $816 = ($814>>>0)<($810>>>0);
  38605. if ($816) {
  38606. _abort();
  38607. // unreachable;
  38608. } else {
  38609. $817 = ((($$3$i$i)) + 16|0);
  38610. HEAP32[$817>>2] = $814;
  38611. $818 = ((($814)) + 24|0);
  38612. HEAP32[$818>>2] = $$3$i$i;
  38613. break;
  38614. }
  38615. }
  38616. } while(0);
  38617. $819 = ((($813)) + 4|0);
  38618. $820 = HEAP32[$819>>2]|0;
  38619. $821 = ($820|0)==(0|0);
  38620. if ($821) {
  38621. break;
  38622. }
  38623. $822 = HEAP32[(23712)>>2]|0;
  38624. $823 = ($820>>>0)<($822>>>0);
  38625. if ($823) {
  38626. _abort();
  38627. // unreachable;
  38628. } else {
  38629. $824 = ((($$3$i$i)) + 20|0);
  38630. HEAP32[$824>>2] = $820;
  38631. $825 = ((($820)) + 24|0);
  38632. HEAP32[$825>>2] = $$3$i$i;
  38633. break;
  38634. }
  38635. }
  38636. } while(0);
  38637. $826 = (($717) + ($741)|0);
  38638. $827 = (($741) + ($722))|0;
  38639. $$0$i18$i = $826;$$0287$i$i = $827;
  38640. } else {
  38641. $$0$i18$i = $717;$$0287$i$i = $722;
  38642. }
  38643. $828 = ((($$0$i18$i)) + 4|0);
  38644. $829 = HEAP32[$828>>2]|0;
  38645. $830 = $829 & -2;
  38646. HEAP32[$828>>2] = $830;
  38647. $831 = $$0287$i$i | 1;
  38648. $832 = ((($721)) + 4|0);
  38649. HEAP32[$832>>2] = $831;
  38650. $833 = (($721) + ($$0287$i$i)|0);
  38651. HEAP32[$833>>2] = $$0287$i$i;
  38652. $834 = $$0287$i$i >>> 3;
  38653. $835 = ($$0287$i$i>>>0)<(256);
  38654. if ($835) {
  38655. $836 = $834 << 1;
  38656. $837 = (23736 + ($836<<2)|0);
  38657. $838 = HEAP32[5924]|0;
  38658. $839 = 1 << $834;
  38659. $840 = $838 & $839;
  38660. $841 = ($840|0)==(0);
  38661. do {
  38662. if ($841) {
  38663. $842 = $838 | $839;
  38664. HEAP32[5924] = $842;
  38665. $$pre$i19$i = ((($837)) + 8|0);
  38666. $$0295$i$i = $837;$$pre$phi$i20$iZ2D = $$pre$i19$i;
  38667. } else {
  38668. $843 = ((($837)) + 8|0);
  38669. $844 = HEAP32[$843>>2]|0;
  38670. $845 = HEAP32[(23712)>>2]|0;
  38671. $846 = ($844>>>0)<($845>>>0);
  38672. if (!($846)) {
  38673. $$0295$i$i = $844;$$pre$phi$i20$iZ2D = $843;
  38674. break;
  38675. }
  38676. _abort();
  38677. // unreachable;
  38678. }
  38679. } while(0);
  38680. HEAP32[$$pre$phi$i20$iZ2D>>2] = $721;
  38681. $847 = ((($$0295$i$i)) + 12|0);
  38682. HEAP32[$847>>2] = $721;
  38683. $848 = ((($721)) + 8|0);
  38684. HEAP32[$848>>2] = $$0295$i$i;
  38685. $849 = ((($721)) + 12|0);
  38686. HEAP32[$849>>2] = $837;
  38687. break;
  38688. }
  38689. $850 = $$0287$i$i >>> 8;
  38690. $851 = ($850|0)==(0);
  38691. do {
  38692. if ($851) {
  38693. $$0296$i$i = 0;
  38694. } else {
  38695. $852 = ($$0287$i$i>>>0)>(16777215);
  38696. if ($852) {
  38697. $$0296$i$i = 31;
  38698. break;
  38699. }
  38700. $853 = (($850) + 1048320)|0;
  38701. $854 = $853 >>> 16;
  38702. $855 = $854 & 8;
  38703. $856 = $850 << $855;
  38704. $857 = (($856) + 520192)|0;
  38705. $858 = $857 >>> 16;
  38706. $859 = $858 & 4;
  38707. $860 = $859 | $855;
  38708. $861 = $856 << $859;
  38709. $862 = (($861) + 245760)|0;
  38710. $863 = $862 >>> 16;
  38711. $864 = $863 & 2;
  38712. $865 = $860 | $864;
  38713. $866 = (14 - ($865))|0;
  38714. $867 = $861 << $864;
  38715. $868 = $867 >>> 15;
  38716. $869 = (($866) + ($868))|0;
  38717. $870 = $869 << 1;
  38718. $871 = (($869) + 7)|0;
  38719. $872 = $$0287$i$i >>> $871;
  38720. $873 = $872 & 1;
  38721. $874 = $873 | $870;
  38722. $$0296$i$i = $874;
  38723. }
  38724. } while(0);
  38725. $875 = (24000 + ($$0296$i$i<<2)|0);
  38726. $876 = ((($721)) + 28|0);
  38727. HEAP32[$876>>2] = $$0296$i$i;
  38728. $877 = ((($721)) + 16|0);
  38729. $878 = ((($877)) + 4|0);
  38730. HEAP32[$878>>2] = 0;
  38731. HEAP32[$877>>2] = 0;
  38732. $879 = HEAP32[(23700)>>2]|0;
  38733. $880 = 1 << $$0296$i$i;
  38734. $881 = $879 & $880;
  38735. $882 = ($881|0)==(0);
  38736. if ($882) {
  38737. $883 = $879 | $880;
  38738. HEAP32[(23700)>>2] = $883;
  38739. HEAP32[$875>>2] = $721;
  38740. $884 = ((($721)) + 24|0);
  38741. HEAP32[$884>>2] = $875;
  38742. $885 = ((($721)) + 12|0);
  38743. HEAP32[$885>>2] = $721;
  38744. $886 = ((($721)) + 8|0);
  38745. HEAP32[$886>>2] = $721;
  38746. break;
  38747. }
  38748. $887 = HEAP32[$875>>2]|0;
  38749. $888 = ($$0296$i$i|0)==(31);
  38750. $889 = $$0296$i$i >>> 1;
  38751. $890 = (25 - ($889))|0;
  38752. $891 = $888 ? 0 : $890;
  38753. $892 = $$0287$i$i << $891;
  38754. $$0288$i$i = $892;$$0289$i$i = $887;
  38755. while(1) {
  38756. $893 = ((($$0289$i$i)) + 4|0);
  38757. $894 = HEAP32[$893>>2]|0;
  38758. $895 = $894 & -8;
  38759. $896 = ($895|0)==($$0287$i$i|0);
  38760. if ($896) {
  38761. label = 265;
  38762. break;
  38763. }
  38764. $897 = $$0288$i$i >>> 31;
  38765. $898 = (((($$0289$i$i)) + 16|0) + ($897<<2)|0);
  38766. $899 = $$0288$i$i << 1;
  38767. $900 = HEAP32[$898>>2]|0;
  38768. $901 = ($900|0)==(0|0);
  38769. if ($901) {
  38770. label = 262;
  38771. break;
  38772. } else {
  38773. $$0288$i$i = $899;$$0289$i$i = $900;
  38774. }
  38775. }
  38776. if ((label|0) == 262) {
  38777. $902 = HEAP32[(23712)>>2]|0;
  38778. $903 = ($898>>>0)<($902>>>0);
  38779. if ($903) {
  38780. _abort();
  38781. // unreachable;
  38782. } else {
  38783. HEAP32[$898>>2] = $721;
  38784. $904 = ((($721)) + 24|0);
  38785. HEAP32[$904>>2] = $$0289$i$i;
  38786. $905 = ((($721)) + 12|0);
  38787. HEAP32[$905>>2] = $721;
  38788. $906 = ((($721)) + 8|0);
  38789. HEAP32[$906>>2] = $721;
  38790. break;
  38791. }
  38792. }
  38793. else if ((label|0) == 265) {
  38794. $907 = ((($$0289$i$i)) + 8|0);
  38795. $908 = HEAP32[$907>>2]|0;
  38796. $909 = HEAP32[(23712)>>2]|0;
  38797. $910 = ($908>>>0)>=($909>>>0);
  38798. $not$7$i$i = ($$0289$i$i>>>0)>=($909>>>0);
  38799. $911 = $910 & $not$7$i$i;
  38800. if ($911) {
  38801. $912 = ((($908)) + 12|0);
  38802. HEAP32[$912>>2] = $721;
  38803. HEAP32[$907>>2] = $721;
  38804. $913 = ((($721)) + 8|0);
  38805. HEAP32[$913>>2] = $908;
  38806. $914 = ((($721)) + 12|0);
  38807. HEAP32[$914>>2] = $$0289$i$i;
  38808. $915 = ((($721)) + 24|0);
  38809. HEAP32[$915>>2] = 0;
  38810. break;
  38811. } else {
  38812. _abort();
  38813. // unreachable;
  38814. }
  38815. }
  38816. }
  38817. } while(0);
  38818. $1047 = ((($709)) + 8|0);
  38819. $$0 = $1047;
  38820. STACKTOP = sp;return ($$0|0);
  38821. }
  38822. }
  38823. $$0$i$i$i = (24144);
  38824. while(1) {
  38825. $916 = HEAP32[$$0$i$i$i>>2]|0;
  38826. $917 = ($916>>>0)>($630>>>0);
  38827. if (!($917)) {
  38828. $918 = ((($$0$i$i$i)) + 4|0);
  38829. $919 = HEAP32[$918>>2]|0;
  38830. $920 = (($916) + ($919)|0);
  38831. $921 = ($920>>>0)>($630>>>0);
  38832. if ($921) {
  38833. break;
  38834. }
  38835. }
  38836. $922 = ((($$0$i$i$i)) + 8|0);
  38837. $923 = HEAP32[$922>>2]|0;
  38838. $$0$i$i$i = $923;
  38839. }
  38840. $924 = ((($920)) + -47|0);
  38841. $925 = ((($924)) + 8|0);
  38842. $926 = $925;
  38843. $927 = $926 & 7;
  38844. $928 = ($927|0)==(0);
  38845. $929 = (0 - ($926))|0;
  38846. $930 = $929 & 7;
  38847. $931 = $928 ? 0 : $930;
  38848. $932 = (($924) + ($931)|0);
  38849. $933 = ((($630)) + 16|0);
  38850. $934 = ($932>>>0)<($933>>>0);
  38851. $935 = $934 ? $630 : $932;
  38852. $936 = ((($935)) + 8|0);
  38853. $937 = ((($935)) + 24|0);
  38854. $938 = (($$723948$i) + -40)|0;
  38855. $939 = ((($$749$i)) + 8|0);
  38856. $940 = $939;
  38857. $941 = $940 & 7;
  38858. $942 = ($941|0)==(0);
  38859. $943 = (0 - ($940))|0;
  38860. $944 = $943 & 7;
  38861. $945 = $942 ? 0 : $944;
  38862. $946 = (($$749$i) + ($945)|0);
  38863. $947 = (($938) - ($945))|0;
  38864. HEAP32[(23720)>>2] = $946;
  38865. HEAP32[(23708)>>2] = $947;
  38866. $948 = $947 | 1;
  38867. $949 = ((($946)) + 4|0);
  38868. HEAP32[$949>>2] = $948;
  38869. $950 = (($946) + ($947)|0);
  38870. $951 = ((($950)) + 4|0);
  38871. HEAP32[$951>>2] = 40;
  38872. $952 = HEAP32[(24184)>>2]|0;
  38873. HEAP32[(23724)>>2] = $952;
  38874. $953 = ((($935)) + 4|0);
  38875. HEAP32[$953>>2] = 27;
  38876. ;HEAP32[$936>>2]=HEAP32[(24144)>>2]|0;HEAP32[$936+4>>2]=HEAP32[(24144)+4>>2]|0;HEAP32[$936+8>>2]=HEAP32[(24144)+8>>2]|0;HEAP32[$936+12>>2]=HEAP32[(24144)+12>>2]|0;
  38877. HEAP32[(24144)>>2] = $$749$i;
  38878. HEAP32[(24148)>>2] = $$723948$i;
  38879. HEAP32[(24156)>>2] = 0;
  38880. HEAP32[(24152)>>2] = $936;
  38881. $955 = $937;
  38882. while(1) {
  38883. $954 = ((($955)) + 4|0);
  38884. HEAP32[$954>>2] = 7;
  38885. $956 = ((($955)) + 8|0);
  38886. $957 = ($956>>>0)<($920>>>0);
  38887. if ($957) {
  38888. $955 = $954;
  38889. } else {
  38890. break;
  38891. }
  38892. }
  38893. $958 = ($935|0)==($630|0);
  38894. if (!($958)) {
  38895. $959 = $935;
  38896. $960 = $630;
  38897. $961 = (($959) - ($960))|0;
  38898. $962 = HEAP32[$953>>2]|0;
  38899. $963 = $962 & -2;
  38900. HEAP32[$953>>2] = $963;
  38901. $964 = $961 | 1;
  38902. $965 = ((($630)) + 4|0);
  38903. HEAP32[$965>>2] = $964;
  38904. HEAP32[$935>>2] = $961;
  38905. $966 = $961 >>> 3;
  38906. $967 = ($961>>>0)<(256);
  38907. if ($967) {
  38908. $968 = $966 << 1;
  38909. $969 = (23736 + ($968<<2)|0);
  38910. $970 = HEAP32[5924]|0;
  38911. $971 = 1 << $966;
  38912. $972 = $970 & $971;
  38913. $973 = ($972|0)==(0);
  38914. if ($973) {
  38915. $974 = $970 | $971;
  38916. HEAP32[5924] = $974;
  38917. $$pre$i$i = ((($969)) + 8|0);
  38918. $$0211$i$i = $969;$$pre$phi$i$iZ2D = $$pre$i$i;
  38919. } else {
  38920. $975 = ((($969)) + 8|0);
  38921. $976 = HEAP32[$975>>2]|0;
  38922. $977 = HEAP32[(23712)>>2]|0;
  38923. $978 = ($976>>>0)<($977>>>0);
  38924. if ($978) {
  38925. _abort();
  38926. // unreachable;
  38927. } else {
  38928. $$0211$i$i = $976;$$pre$phi$i$iZ2D = $975;
  38929. }
  38930. }
  38931. HEAP32[$$pre$phi$i$iZ2D>>2] = $630;
  38932. $979 = ((($$0211$i$i)) + 12|0);
  38933. HEAP32[$979>>2] = $630;
  38934. $980 = ((($630)) + 8|0);
  38935. HEAP32[$980>>2] = $$0211$i$i;
  38936. $981 = ((($630)) + 12|0);
  38937. HEAP32[$981>>2] = $969;
  38938. break;
  38939. }
  38940. $982 = $961 >>> 8;
  38941. $983 = ($982|0)==(0);
  38942. if ($983) {
  38943. $$0212$i$i = 0;
  38944. } else {
  38945. $984 = ($961>>>0)>(16777215);
  38946. if ($984) {
  38947. $$0212$i$i = 31;
  38948. } else {
  38949. $985 = (($982) + 1048320)|0;
  38950. $986 = $985 >>> 16;
  38951. $987 = $986 & 8;
  38952. $988 = $982 << $987;
  38953. $989 = (($988) + 520192)|0;
  38954. $990 = $989 >>> 16;
  38955. $991 = $990 & 4;
  38956. $992 = $991 | $987;
  38957. $993 = $988 << $991;
  38958. $994 = (($993) + 245760)|0;
  38959. $995 = $994 >>> 16;
  38960. $996 = $995 & 2;
  38961. $997 = $992 | $996;
  38962. $998 = (14 - ($997))|0;
  38963. $999 = $993 << $996;
  38964. $1000 = $999 >>> 15;
  38965. $1001 = (($998) + ($1000))|0;
  38966. $1002 = $1001 << 1;
  38967. $1003 = (($1001) + 7)|0;
  38968. $1004 = $961 >>> $1003;
  38969. $1005 = $1004 & 1;
  38970. $1006 = $1005 | $1002;
  38971. $$0212$i$i = $1006;
  38972. }
  38973. }
  38974. $1007 = (24000 + ($$0212$i$i<<2)|0);
  38975. $1008 = ((($630)) + 28|0);
  38976. HEAP32[$1008>>2] = $$0212$i$i;
  38977. $1009 = ((($630)) + 20|0);
  38978. HEAP32[$1009>>2] = 0;
  38979. HEAP32[$933>>2] = 0;
  38980. $1010 = HEAP32[(23700)>>2]|0;
  38981. $1011 = 1 << $$0212$i$i;
  38982. $1012 = $1010 & $1011;
  38983. $1013 = ($1012|0)==(0);
  38984. if ($1013) {
  38985. $1014 = $1010 | $1011;
  38986. HEAP32[(23700)>>2] = $1014;
  38987. HEAP32[$1007>>2] = $630;
  38988. $1015 = ((($630)) + 24|0);
  38989. HEAP32[$1015>>2] = $1007;
  38990. $1016 = ((($630)) + 12|0);
  38991. HEAP32[$1016>>2] = $630;
  38992. $1017 = ((($630)) + 8|0);
  38993. HEAP32[$1017>>2] = $630;
  38994. break;
  38995. }
  38996. $1018 = HEAP32[$1007>>2]|0;
  38997. $1019 = ($$0212$i$i|0)==(31);
  38998. $1020 = $$0212$i$i >>> 1;
  38999. $1021 = (25 - ($1020))|0;
  39000. $1022 = $1019 ? 0 : $1021;
  39001. $1023 = $961 << $1022;
  39002. $$0206$i$i = $1023;$$0207$i$i = $1018;
  39003. while(1) {
  39004. $1024 = ((($$0207$i$i)) + 4|0);
  39005. $1025 = HEAP32[$1024>>2]|0;
  39006. $1026 = $1025 & -8;
  39007. $1027 = ($1026|0)==($961|0);
  39008. if ($1027) {
  39009. label = 292;
  39010. break;
  39011. }
  39012. $1028 = $$0206$i$i >>> 31;
  39013. $1029 = (((($$0207$i$i)) + 16|0) + ($1028<<2)|0);
  39014. $1030 = $$0206$i$i << 1;
  39015. $1031 = HEAP32[$1029>>2]|0;
  39016. $1032 = ($1031|0)==(0|0);
  39017. if ($1032) {
  39018. label = 289;
  39019. break;
  39020. } else {
  39021. $$0206$i$i = $1030;$$0207$i$i = $1031;
  39022. }
  39023. }
  39024. if ((label|0) == 289) {
  39025. $1033 = HEAP32[(23712)>>2]|0;
  39026. $1034 = ($1029>>>0)<($1033>>>0);
  39027. if ($1034) {
  39028. _abort();
  39029. // unreachable;
  39030. } else {
  39031. HEAP32[$1029>>2] = $630;
  39032. $1035 = ((($630)) + 24|0);
  39033. HEAP32[$1035>>2] = $$0207$i$i;
  39034. $1036 = ((($630)) + 12|0);
  39035. HEAP32[$1036>>2] = $630;
  39036. $1037 = ((($630)) + 8|0);
  39037. HEAP32[$1037>>2] = $630;
  39038. break;
  39039. }
  39040. }
  39041. else if ((label|0) == 292) {
  39042. $1038 = ((($$0207$i$i)) + 8|0);
  39043. $1039 = HEAP32[$1038>>2]|0;
  39044. $1040 = HEAP32[(23712)>>2]|0;
  39045. $1041 = ($1039>>>0)>=($1040>>>0);
  39046. $not$$i$i = ($$0207$i$i>>>0)>=($1040>>>0);
  39047. $1042 = $1041 & $not$$i$i;
  39048. if ($1042) {
  39049. $1043 = ((($1039)) + 12|0);
  39050. HEAP32[$1043>>2] = $630;
  39051. HEAP32[$1038>>2] = $630;
  39052. $1044 = ((($630)) + 8|0);
  39053. HEAP32[$1044>>2] = $1039;
  39054. $1045 = ((($630)) + 12|0);
  39055. HEAP32[$1045>>2] = $$0207$i$i;
  39056. $1046 = ((($630)) + 24|0);
  39057. HEAP32[$1046>>2] = 0;
  39058. break;
  39059. } else {
  39060. _abort();
  39061. // unreachable;
  39062. }
  39063. }
  39064. }
  39065. }
  39066. } while(0);
  39067. $1048 = HEAP32[(23708)>>2]|0;
  39068. $1049 = ($1048>>>0)>($$0197>>>0);
  39069. if ($1049) {
  39070. $1050 = (($1048) - ($$0197))|0;
  39071. HEAP32[(23708)>>2] = $1050;
  39072. $1051 = HEAP32[(23720)>>2]|0;
  39073. $1052 = (($1051) + ($$0197)|0);
  39074. HEAP32[(23720)>>2] = $1052;
  39075. $1053 = $1050 | 1;
  39076. $1054 = ((($1052)) + 4|0);
  39077. HEAP32[$1054>>2] = $1053;
  39078. $1055 = $$0197 | 3;
  39079. $1056 = ((($1051)) + 4|0);
  39080. HEAP32[$1056>>2] = $1055;
  39081. $1057 = ((($1051)) + 8|0);
  39082. $$0 = $1057;
  39083. STACKTOP = sp;return ($$0|0);
  39084. }
  39085. }
  39086. $1058 = (___errno_location()|0);
  39087. HEAP32[$1058>>2] = 12;
  39088. $$0 = 0;
  39089. STACKTOP = sp;return ($$0|0);
  39090. }
  39091. function _free($0) {
  39092. $0 = $0|0;
  39093. var $$0212$i = 0, $$0212$in$i = 0, $$0383 = 0, $$0384 = 0, $$0396 = 0, $$0403 = 0, $$1 = 0, $$1382 = 0, $$1387 = 0, $$1390 = 0, $$1398 = 0, $$1402 = 0, $$2 = 0, $$3 = 0, $$3400 = 0, $$pre = 0, $$pre$phi443Z2D = 0, $$pre$phi445Z2D = 0, $$pre$phiZ2D = 0, $$pre442 = 0;
  39094. var $$pre444 = 0, $$sink3 = 0, $$sink5 = 0, $1 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0;
  39095. var $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0;
  39096. var $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0;
  39097. var $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0;
  39098. var $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0;
  39099. var $187 = 0, $188 = 0, $189 = 0, $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0, $2 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0;
  39100. var $204 = 0, $205 = 0, $206 = 0, $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0, $22 = 0, $220 = 0, $221 = 0;
  39101. var $222 = 0, $223 = 0, $224 = 0, $225 = 0, $226 = 0, $227 = 0, $228 = 0, $229 = 0, $23 = 0, $230 = 0, $231 = 0, $232 = 0, $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0;
  39102. var $240 = 0, $241 = 0, $242 = 0, $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0, $249 = 0, $25 = 0, $250 = 0, $251 = 0, $252 = 0, $253 = 0, $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0;
  39103. var $259 = 0, $26 = 0, $260 = 0, $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0, $267 = 0, $268 = 0, $269 = 0, $27 = 0, $270 = 0, $271 = 0, $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0;
  39104. var $277 = 0, $278 = 0, $279 = 0, $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0, $285 = 0, $286 = 0, $287 = 0, $288 = 0, $289 = 0, $29 = 0, $290 = 0, $291 = 0, $292 = 0, $293 = 0, $294 = 0;
  39105. var $295 = 0, $296 = 0, $297 = 0, $298 = 0, $299 = 0, $3 = 0, $30 = 0, $300 = 0, $301 = 0, $302 = 0, $303 = 0, $304 = 0, $305 = 0, $306 = 0, $307 = 0, $308 = 0, $309 = 0, $31 = 0, $310 = 0, $311 = 0;
  39106. var $312 = 0, $313 = 0, $314 = 0, $315 = 0, $316 = 0, $317 = 0, $318 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0;
  39107. var $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0;
  39108. var $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0;
  39109. var $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0;
  39110. var $99 = 0, $cond421 = 0, $cond422 = 0, $not$ = 0, $not$405 = 0, $not$437 = 0, label = 0, sp = 0;
  39111. sp = STACKTOP;
  39112. $1 = ($0|0)==(0|0);
  39113. if ($1) {
  39114. return;
  39115. }
  39116. $2 = ((($0)) + -8|0);
  39117. $3 = HEAP32[(23712)>>2]|0;
  39118. $4 = ($2>>>0)<($3>>>0);
  39119. if ($4) {
  39120. _abort();
  39121. // unreachable;
  39122. }
  39123. $5 = ((($0)) + -4|0);
  39124. $6 = HEAP32[$5>>2]|0;
  39125. $7 = $6 & 3;
  39126. $8 = ($7|0)==(1);
  39127. if ($8) {
  39128. _abort();
  39129. // unreachable;
  39130. }
  39131. $9 = $6 & -8;
  39132. $10 = (($2) + ($9)|0);
  39133. $11 = $6 & 1;
  39134. $12 = ($11|0)==(0);
  39135. L10: do {
  39136. if ($12) {
  39137. $13 = HEAP32[$2>>2]|0;
  39138. $14 = ($7|0)==(0);
  39139. if ($14) {
  39140. return;
  39141. }
  39142. $15 = (0 - ($13))|0;
  39143. $16 = (($2) + ($15)|0);
  39144. $17 = (($13) + ($9))|0;
  39145. $18 = ($16>>>0)<($3>>>0);
  39146. if ($18) {
  39147. _abort();
  39148. // unreachable;
  39149. }
  39150. $19 = HEAP32[(23716)>>2]|0;
  39151. $20 = ($16|0)==($19|0);
  39152. if ($20) {
  39153. $104 = ((($10)) + 4|0);
  39154. $105 = HEAP32[$104>>2]|0;
  39155. $106 = $105 & 3;
  39156. $107 = ($106|0)==(3);
  39157. if (!($107)) {
  39158. $$1 = $16;$$1382 = $17;$113 = $16;
  39159. break;
  39160. }
  39161. $108 = (($16) + ($17)|0);
  39162. $109 = ((($16)) + 4|0);
  39163. $110 = $17 | 1;
  39164. $111 = $105 & -2;
  39165. HEAP32[(23704)>>2] = $17;
  39166. HEAP32[$104>>2] = $111;
  39167. HEAP32[$109>>2] = $110;
  39168. HEAP32[$108>>2] = $17;
  39169. return;
  39170. }
  39171. $21 = $13 >>> 3;
  39172. $22 = ($13>>>0)<(256);
  39173. if ($22) {
  39174. $23 = ((($16)) + 8|0);
  39175. $24 = HEAP32[$23>>2]|0;
  39176. $25 = ((($16)) + 12|0);
  39177. $26 = HEAP32[$25>>2]|0;
  39178. $27 = $21 << 1;
  39179. $28 = (23736 + ($27<<2)|0);
  39180. $29 = ($24|0)==($28|0);
  39181. if (!($29)) {
  39182. $30 = ($24>>>0)<($3>>>0);
  39183. if ($30) {
  39184. _abort();
  39185. // unreachable;
  39186. }
  39187. $31 = ((($24)) + 12|0);
  39188. $32 = HEAP32[$31>>2]|0;
  39189. $33 = ($32|0)==($16|0);
  39190. if (!($33)) {
  39191. _abort();
  39192. // unreachable;
  39193. }
  39194. }
  39195. $34 = ($26|0)==($24|0);
  39196. if ($34) {
  39197. $35 = 1 << $21;
  39198. $36 = $35 ^ -1;
  39199. $37 = HEAP32[5924]|0;
  39200. $38 = $37 & $36;
  39201. HEAP32[5924] = $38;
  39202. $$1 = $16;$$1382 = $17;$113 = $16;
  39203. break;
  39204. }
  39205. $39 = ($26|0)==($28|0);
  39206. if ($39) {
  39207. $$pre444 = ((($26)) + 8|0);
  39208. $$pre$phi445Z2D = $$pre444;
  39209. } else {
  39210. $40 = ($26>>>0)<($3>>>0);
  39211. if ($40) {
  39212. _abort();
  39213. // unreachable;
  39214. }
  39215. $41 = ((($26)) + 8|0);
  39216. $42 = HEAP32[$41>>2]|0;
  39217. $43 = ($42|0)==($16|0);
  39218. if ($43) {
  39219. $$pre$phi445Z2D = $41;
  39220. } else {
  39221. _abort();
  39222. // unreachable;
  39223. }
  39224. }
  39225. $44 = ((($24)) + 12|0);
  39226. HEAP32[$44>>2] = $26;
  39227. HEAP32[$$pre$phi445Z2D>>2] = $24;
  39228. $$1 = $16;$$1382 = $17;$113 = $16;
  39229. break;
  39230. }
  39231. $45 = ((($16)) + 24|0);
  39232. $46 = HEAP32[$45>>2]|0;
  39233. $47 = ((($16)) + 12|0);
  39234. $48 = HEAP32[$47>>2]|0;
  39235. $49 = ($48|0)==($16|0);
  39236. do {
  39237. if ($49) {
  39238. $59 = ((($16)) + 16|0);
  39239. $60 = ((($59)) + 4|0);
  39240. $61 = HEAP32[$60>>2]|0;
  39241. $62 = ($61|0)==(0|0);
  39242. if ($62) {
  39243. $63 = HEAP32[$59>>2]|0;
  39244. $64 = ($63|0)==(0|0);
  39245. if ($64) {
  39246. $$3 = 0;
  39247. break;
  39248. } else {
  39249. $$1387 = $63;$$1390 = $59;
  39250. }
  39251. } else {
  39252. $$1387 = $61;$$1390 = $60;
  39253. }
  39254. while(1) {
  39255. $65 = ((($$1387)) + 20|0);
  39256. $66 = HEAP32[$65>>2]|0;
  39257. $67 = ($66|0)==(0|0);
  39258. if (!($67)) {
  39259. $$1387 = $66;$$1390 = $65;
  39260. continue;
  39261. }
  39262. $68 = ((($$1387)) + 16|0);
  39263. $69 = HEAP32[$68>>2]|0;
  39264. $70 = ($69|0)==(0|0);
  39265. if ($70) {
  39266. break;
  39267. } else {
  39268. $$1387 = $69;$$1390 = $68;
  39269. }
  39270. }
  39271. $71 = ($$1390>>>0)<($3>>>0);
  39272. if ($71) {
  39273. _abort();
  39274. // unreachable;
  39275. } else {
  39276. HEAP32[$$1390>>2] = 0;
  39277. $$3 = $$1387;
  39278. break;
  39279. }
  39280. } else {
  39281. $50 = ((($16)) + 8|0);
  39282. $51 = HEAP32[$50>>2]|0;
  39283. $52 = ($51>>>0)<($3>>>0);
  39284. if ($52) {
  39285. _abort();
  39286. // unreachable;
  39287. }
  39288. $53 = ((($51)) + 12|0);
  39289. $54 = HEAP32[$53>>2]|0;
  39290. $55 = ($54|0)==($16|0);
  39291. if (!($55)) {
  39292. _abort();
  39293. // unreachable;
  39294. }
  39295. $56 = ((($48)) + 8|0);
  39296. $57 = HEAP32[$56>>2]|0;
  39297. $58 = ($57|0)==($16|0);
  39298. if ($58) {
  39299. HEAP32[$53>>2] = $48;
  39300. HEAP32[$56>>2] = $51;
  39301. $$3 = $48;
  39302. break;
  39303. } else {
  39304. _abort();
  39305. // unreachable;
  39306. }
  39307. }
  39308. } while(0);
  39309. $72 = ($46|0)==(0|0);
  39310. if ($72) {
  39311. $$1 = $16;$$1382 = $17;$113 = $16;
  39312. } else {
  39313. $73 = ((($16)) + 28|0);
  39314. $74 = HEAP32[$73>>2]|0;
  39315. $75 = (24000 + ($74<<2)|0);
  39316. $76 = HEAP32[$75>>2]|0;
  39317. $77 = ($16|0)==($76|0);
  39318. do {
  39319. if ($77) {
  39320. HEAP32[$75>>2] = $$3;
  39321. $cond421 = ($$3|0)==(0|0);
  39322. if ($cond421) {
  39323. $78 = 1 << $74;
  39324. $79 = $78 ^ -1;
  39325. $80 = HEAP32[(23700)>>2]|0;
  39326. $81 = $80 & $79;
  39327. HEAP32[(23700)>>2] = $81;
  39328. $$1 = $16;$$1382 = $17;$113 = $16;
  39329. break L10;
  39330. }
  39331. } else {
  39332. $82 = HEAP32[(23712)>>2]|0;
  39333. $83 = ($46>>>0)<($82>>>0);
  39334. if ($83) {
  39335. _abort();
  39336. // unreachable;
  39337. } else {
  39338. $84 = ((($46)) + 16|0);
  39339. $85 = HEAP32[$84>>2]|0;
  39340. $not$405 = ($85|0)!=($16|0);
  39341. $$sink3 = $not$405&1;
  39342. $86 = (((($46)) + 16|0) + ($$sink3<<2)|0);
  39343. HEAP32[$86>>2] = $$3;
  39344. $87 = ($$3|0)==(0|0);
  39345. if ($87) {
  39346. $$1 = $16;$$1382 = $17;$113 = $16;
  39347. break L10;
  39348. } else {
  39349. break;
  39350. }
  39351. }
  39352. }
  39353. } while(0);
  39354. $88 = HEAP32[(23712)>>2]|0;
  39355. $89 = ($$3>>>0)<($88>>>0);
  39356. if ($89) {
  39357. _abort();
  39358. // unreachable;
  39359. }
  39360. $90 = ((($$3)) + 24|0);
  39361. HEAP32[$90>>2] = $46;
  39362. $91 = ((($16)) + 16|0);
  39363. $92 = HEAP32[$91>>2]|0;
  39364. $93 = ($92|0)==(0|0);
  39365. do {
  39366. if (!($93)) {
  39367. $94 = ($92>>>0)<($88>>>0);
  39368. if ($94) {
  39369. _abort();
  39370. // unreachable;
  39371. } else {
  39372. $95 = ((($$3)) + 16|0);
  39373. HEAP32[$95>>2] = $92;
  39374. $96 = ((($92)) + 24|0);
  39375. HEAP32[$96>>2] = $$3;
  39376. break;
  39377. }
  39378. }
  39379. } while(0);
  39380. $97 = ((($91)) + 4|0);
  39381. $98 = HEAP32[$97>>2]|0;
  39382. $99 = ($98|0)==(0|0);
  39383. if ($99) {
  39384. $$1 = $16;$$1382 = $17;$113 = $16;
  39385. } else {
  39386. $100 = HEAP32[(23712)>>2]|0;
  39387. $101 = ($98>>>0)<($100>>>0);
  39388. if ($101) {
  39389. _abort();
  39390. // unreachable;
  39391. } else {
  39392. $102 = ((($$3)) + 20|0);
  39393. HEAP32[$102>>2] = $98;
  39394. $103 = ((($98)) + 24|0);
  39395. HEAP32[$103>>2] = $$3;
  39396. $$1 = $16;$$1382 = $17;$113 = $16;
  39397. break;
  39398. }
  39399. }
  39400. }
  39401. } else {
  39402. $$1 = $2;$$1382 = $9;$113 = $2;
  39403. }
  39404. } while(0);
  39405. $112 = ($113>>>0)<($10>>>0);
  39406. if (!($112)) {
  39407. _abort();
  39408. // unreachable;
  39409. }
  39410. $114 = ((($10)) + 4|0);
  39411. $115 = HEAP32[$114>>2]|0;
  39412. $116 = $115 & 1;
  39413. $117 = ($116|0)==(0);
  39414. if ($117) {
  39415. _abort();
  39416. // unreachable;
  39417. }
  39418. $118 = $115 & 2;
  39419. $119 = ($118|0)==(0);
  39420. if ($119) {
  39421. $120 = HEAP32[(23720)>>2]|0;
  39422. $121 = ($10|0)==($120|0);
  39423. $122 = HEAP32[(23716)>>2]|0;
  39424. if ($121) {
  39425. $123 = HEAP32[(23708)>>2]|0;
  39426. $124 = (($123) + ($$1382))|0;
  39427. HEAP32[(23708)>>2] = $124;
  39428. HEAP32[(23720)>>2] = $$1;
  39429. $125 = $124 | 1;
  39430. $126 = ((($$1)) + 4|0);
  39431. HEAP32[$126>>2] = $125;
  39432. $127 = ($$1|0)==($122|0);
  39433. if (!($127)) {
  39434. return;
  39435. }
  39436. HEAP32[(23716)>>2] = 0;
  39437. HEAP32[(23704)>>2] = 0;
  39438. return;
  39439. }
  39440. $128 = ($10|0)==($122|0);
  39441. if ($128) {
  39442. $129 = HEAP32[(23704)>>2]|0;
  39443. $130 = (($129) + ($$1382))|0;
  39444. HEAP32[(23704)>>2] = $130;
  39445. HEAP32[(23716)>>2] = $113;
  39446. $131 = $130 | 1;
  39447. $132 = ((($$1)) + 4|0);
  39448. HEAP32[$132>>2] = $131;
  39449. $133 = (($113) + ($130)|0);
  39450. HEAP32[$133>>2] = $130;
  39451. return;
  39452. }
  39453. $134 = $115 & -8;
  39454. $135 = (($134) + ($$1382))|0;
  39455. $136 = $115 >>> 3;
  39456. $137 = ($115>>>0)<(256);
  39457. L108: do {
  39458. if ($137) {
  39459. $138 = ((($10)) + 8|0);
  39460. $139 = HEAP32[$138>>2]|0;
  39461. $140 = ((($10)) + 12|0);
  39462. $141 = HEAP32[$140>>2]|0;
  39463. $142 = $136 << 1;
  39464. $143 = (23736 + ($142<<2)|0);
  39465. $144 = ($139|0)==($143|0);
  39466. if (!($144)) {
  39467. $145 = HEAP32[(23712)>>2]|0;
  39468. $146 = ($139>>>0)<($145>>>0);
  39469. if ($146) {
  39470. _abort();
  39471. // unreachable;
  39472. }
  39473. $147 = ((($139)) + 12|0);
  39474. $148 = HEAP32[$147>>2]|0;
  39475. $149 = ($148|0)==($10|0);
  39476. if (!($149)) {
  39477. _abort();
  39478. // unreachable;
  39479. }
  39480. }
  39481. $150 = ($141|0)==($139|0);
  39482. if ($150) {
  39483. $151 = 1 << $136;
  39484. $152 = $151 ^ -1;
  39485. $153 = HEAP32[5924]|0;
  39486. $154 = $153 & $152;
  39487. HEAP32[5924] = $154;
  39488. break;
  39489. }
  39490. $155 = ($141|0)==($143|0);
  39491. if ($155) {
  39492. $$pre442 = ((($141)) + 8|0);
  39493. $$pre$phi443Z2D = $$pre442;
  39494. } else {
  39495. $156 = HEAP32[(23712)>>2]|0;
  39496. $157 = ($141>>>0)<($156>>>0);
  39497. if ($157) {
  39498. _abort();
  39499. // unreachable;
  39500. }
  39501. $158 = ((($141)) + 8|0);
  39502. $159 = HEAP32[$158>>2]|0;
  39503. $160 = ($159|0)==($10|0);
  39504. if ($160) {
  39505. $$pre$phi443Z2D = $158;
  39506. } else {
  39507. _abort();
  39508. // unreachable;
  39509. }
  39510. }
  39511. $161 = ((($139)) + 12|0);
  39512. HEAP32[$161>>2] = $141;
  39513. HEAP32[$$pre$phi443Z2D>>2] = $139;
  39514. } else {
  39515. $162 = ((($10)) + 24|0);
  39516. $163 = HEAP32[$162>>2]|0;
  39517. $164 = ((($10)) + 12|0);
  39518. $165 = HEAP32[$164>>2]|0;
  39519. $166 = ($165|0)==($10|0);
  39520. do {
  39521. if ($166) {
  39522. $177 = ((($10)) + 16|0);
  39523. $178 = ((($177)) + 4|0);
  39524. $179 = HEAP32[$178>>2]|0;
  39525. $180 = ($179|0)==(0|0);
  39526. if ($180) {
  39527. $181 = HEAP32[$177>>2]|0;
  39528. $182 = ($181|0)==(0|0);
  39529. if ($182) {
  39530. $$3400 = 0;
  39531. break;
  39532. } else {
  39533. $$1398 = $181;$$1402 = $177;
  39534. }
  39535. } else {
  39536. $$1398 = $179;$$1402 = $178;
  39537. }
  39538. while(1) {
  39539. $183 = ((($$1398)) + 20|0);
  39540. $184 = HEAP32[$183>>2]|0;
  39541. $185 = ($184|0)==(0|0);
  39542. if (!($185)) {
  39543. $$1398 = $184;$$1402 = $183;
  39544. continue;
  39545. }
  39546. $186 = ((($$1398)) + 16|0);
  39547. $187 = HEAP32[$186>>2]|0;
  39548. $188 = ($187|0)==(0|0);
  39549. if ($188) {
  39550. break;
  39551. } else {
  39552. $$1398 = $187;$$1402 = $186;
  39553. }
  39554. }
  39555. $189 = HEAP32[(23712)>>2]|0;
  39556. $190 = ($$1402>>>0)<($189>>>0);
  39557. if ($190) {
  39558. _abort();
  39559. // unreachable;
  39560. } else {
  39561. HEAP32[$$1402>>2] = 0;
  39562. $$3400 = $$1398;
  39563. break;
  39564. }
  39565. } else {
  39566. $167 = ((($10)) + 8|0);
  39567. $168 = HEAP32[$167>>2]|0;
  39568. $169 = HEAP32[(23712)>>2]|0;
  39569. $170 = ($168>>>0)<($169>>>0);
  39570. if ($170) {
  39571. _abort();
  39572. // unreachable;
  39573. }
  39574. $171 = ((($168)) + 12|0);
  39575. $172 = HEAP32[$171>>2]|0;
  39576. $173 = ($172|0)==($10|0);
  39577. if (!($173)) {
  39578. _abort();
  39579. // unreachable;
  39580. }
  39581. $174 = ((($165)) + 8|0);
  39582. $175 = HEAP32[$174>>2]|0;
  39583. $176 = ($175|0)==($10|0);
  39584. if ($176) {
  39585. HEAP32[$171>>2] = $165;
  39586. HEAP32[$174>>2] = $168;
  39587. $$3400 = $165;
  39588. break;
  39589. } else {
  39590. _abort();
  39591. // unreachable;
  39592. }
  39593. }
  39594. } while(0);
  39595. $191 = ($163|0)==(0|0);
  39596. if (!($191)) {
  39597. $192 = ((($10)) + 28|0);
  39598. $193 = HEAP32[$192>>2]|0;
  39599. $194 = (24000 + ($193<<2)|0);
  39600. $195 = HEAP32[$194>>2]|0;
  39601. $196 = ($10|0)==($195|0);
  39602. do {
  39603. if ($196) {
  39604. HEAP32[$194>>2] = $$3400;
  39605. $cond422 = ($$3400|0)==(0|0);
  39606. if ($cond422) {
  39607. $197 = 1 << $193;
  39608. $198 = $197 ^ -1;
  39609. $199 = HEAP32[(23700)>>2]|0;
  39610. $200 = $199 & $198;
  39611. HEAP32[(23700)>>2] = $200;
  39612. break L108;
  39613. }
  39614. } else {
  39615. $201 = HEAP32[(23712)>>2]|0;
  39616. $202 = ($163>>>0)<($201>>>0);
  39617. if ($202) {
  39618. _abort();
  39619. // unreachable;
  39620. } else {
  39621. $203 = ((($163)) + 16|0);
  39622. $204 = HEAP32[$203>>2]|0;
  39623. $not$ = ($204|0)!=($10|0);
  39624. $$sink5 = $not$&1;
  39625. $205 = (((($163)) + 16|0) + ($$sink5<<2)|0);
  39626. HEAP32[$205>>2] = $$3400;
  39627. $206 = ($$3400|0)==(0|0);
  39628. if ($206) {
  39629. break L108;
  39630. } else {
  39631. break;
  39632. }
  39633. }
  39634. }
  39635. } while(0);
  39636. $207 = HEAP32[(23712)>>2]|0;
  39637. $208 = ($$3400>>>0)<($207>>>0);
  39638. if ($208) {
  39639. _abort();
  39640. // unreachable;
  39641. }
  39642. $209 = ((($$3400)) + 24|0);
  39643. HEAP32[$209>>2] = $163;
  39644. $210 = ((($10)) + 16|0);
  39645. $211 = HEAP32[$210>>2]|0;
  39646. $212 = ($211|0)==(0|0);
  39647. do {
  39648. if (!($212)) {
  39649. $213 = ($211>>>0)<($207>>>0);
  39650. if ($213) {
  39651. _abort();
  39652. // unreachable;
  39653. } else {
  39654. $214 = ((($$3400)) + 16|0);
  39655. HEAP32[$214>>2] = $211;
  39656. $215 = ((($211)) + 24|0);
  39657. HEAP32[$215>>2] = $$3400;
  39658. break;
  39659. }
  39660. }
  39661. } while(0);
  39662. $216 = ((($210)) + 4|0);
  39663. $217 = HEAP32[$216>>2]|0;
  39664. $218 = ($217|0)==(0|0);
  39665. if (!($218)) {
  39666. $219 = HEAP32[(23712)>>2]|0;
  39667. $220 = ($217>>>0)<($219>>>0);
  39668. if ($220) {
  39669. _abort();
  39670. // unreachable;
  39671. } else {
  39672. $221 = ((($$3400)) + 20|0);
  39673. HEAP32[$221>>2] = $217;
  39674. $222 = ((($217)) + 24|0);
  39675. HEAP32[$222>>2] = $$3400;
  39676. break;
  39677. }
  39678. }
  39679. }
  39680. }
  39681. } while(0);
  39682. $223 = $135 | 1;
  39683. $224 = ((($$1)) + 4|0);
  39684. HEAP32[$224>>2] = $223;
  39685. $225 = (($113) + ($135)|0);
  39686. HEAP32[$225>>2] = $135;
  39687. $226 = HEAP32[(23716)>>2]|0;
  39688. $227 = ($$1|0)==($226|0);
  39689. if ($227) {
  39690. HEAP32[(23704)>>2] = $135;
  39691. return;
  39692. } else {
  39693. $$2 = $135;
  39694. }
  39695. } else {
  39696. $228 = $115 & -2;
  39697. HEAP32[$114>>2] = $228;
  39698. $229 = $$1382 | 1;
  39699. $230 = ((($$1)) + 4|0);
  39700. HEAP32[$230>>2] = $229;
  39701. $231 = (($113) + ($$1382)|0);
  39702. HEAP32[$231>>2] = $$1382;
  39703. $$2 = $$1382;
  39704. }
  39705. $232 = $$2 >>> 3;
  39706. $233 = ($$2>>>0)<(256);
  39707. if ($233) {
  39708. $234 = $232 << 1;
  39709. $235 = (23736 + ($234<<2)|0);
  39710. $236 = HEAP32[5924]|0;
  39711. $237 = 1 << $232;
  39712. $238 = $236 & $237;
  39713. $239 = ($238|0)==(0);
  39714. if ($239) {
  39715. $240 = $236 | $237;
  39716. HEAP32[5924] = $240;
  39717. $$pre = ((($235)) + 8|0);
  39718. $$0403 = $235;$$pre$phiZ2D = $$pre;
  39719. } else {
  39720. $241 = ((($235)) + 8|0);
  39721. $242 = HEAP32[$241>>2]|0;
  39722. $243 = HEAP32[(23712)>>2]|0;
  39723. $244 = ($242>>>0)<($243>>>0);
  39724. if ($244) {
  39725. _abort();
  39726. // unreachable;
  39727. } else {
  39728. $$0403 = $242;$$pre$phiZ2D = $241;
  39729. }
  39730. }
  39731. HEAP32[$$pre$phiZ2D>>2] = $$1;
  39732. $245 = ((($$0403)) + 12|0);
  39733. HEAP32[$245>>2] = $$1;
  39734. $246 = ((($$1)) + 8|0);
  39735. HEAP32[$246>>2] = $$0403;
  39736. $247 = ((($$1)) + 12|0);
  39737. HEAP32[$247>>2] = $235;
  39738. return;
  39739. }
  39740. $248 = $$2 >>> 8;
  39741. $249 = ($248|0)==(0);
  39742. if ($249) {
  39743. $$0396 = 0;
  39744. } else {
  39745. $250 = ($$2>>>0)>(16777215);
  39746. if ($250) {
  39747. $$0396 = 31;
  39748. } else {
  39749. $251 = (($248) + 1048320)|0;
  39750. $252 = $251 >>> 16;
  39751. $253 = $252 & 8;
  39752. $254 = $248 << $253;
  39753. $255 = (($254) + 520192)|0;
  39754. $256 = $255 >>> 16;
  39755. $257 = $256 & 4;
  39756. $258 = $257 | $253;
  39757. $259 = $254 << $257;
  39758. $260 = (($259) + 245760)|0;
  39759. $261 = $260 >>> 16;
  39760. $262 = $261 & 2;
  39761. $263 = $258 | $262;
  39762. $264 = (14 - ($263))|0;
  39763. $265 = $259 << $262;
  39764. $266 = $265 >>> 15;
  39765. $267 = (($264) + ($266))|0;
  39766. $268 = $267 << 1;
  39767. $269 = (($267) + 7)|0;
  39768. $270 = $$2 >>> $269;
  39769. $271 = $270 & 1;
  39770. $272 = $271 | $268;
  39771. $$0396 = $272;
  39772. }
  39773. }
  39774. $273 = (24000 + ($$0396<<2)|0);
  39775. $274 = ((($$1)) + 28|0);
  39776. HEAP32[$274>>2] = $$0396;
  39777. $275 = ((($$1)) + 16|0);
  39778. $276 = ((($$1)) + 20|0);
  39779. HEAP32[$276>>2] = 0;
  39780. HEAP32[$275>>2] = 0;
  39781. $277 = HEAP32[(23700)>>2]|0;
  39782. $278 = 1 << $$0396;
  39783. $279 = $277 & $278;
  39784. $280 = ($279|0)==(0);
  39785. do {
  39786. if ($280) {
  39787. $281 = $277 | $278;
  39788. HEAP32[(23700)>>2] = $281;
  39789. HEAP32[$273>>2] = $$1;
  39790. $282 = ((($$1)) + 24|0);
  39791. HEAP32[$282>>2] = $273;
  39792. $283 = ((($$1)) + 12|0);
  39793. HEAP32[$283>>2] = $$1;
  39794. $284 = ((($$1)) + 8|0);
  39795. HEAP32[$284>>2] = $$1;
  39796. } else {
  39797. $285 = HEAP32[$273>>2]|0;
  39798. $286 = ($$0396|0)==(31);
  39799. $287 = $$0396 >>> 1;
  39800. $288 = (25 - ($287))|0;
  39801. $289 = $286 ? 0 : $288;
  39802. $290 = $$2 << $289;
  39803. $$0383 = $290;$$0384 = $285;
  39804. while(1) {
  39805. $291 = ((($$0384)) + 4|0);
  39806. $292 = HEAP32[$291>>2]|0;
  39807. $293 = $292 & -8;
  39808. $294 = ($293|0)==($$2|0);
  39809. if ($294) {
  39810. label = 124;
  39811. break;
  39812. }
  39813. $295 = $$0383 >>> 31;
  39814. $296 = (((($$0384)) + 16|0) + ($295<<2)|0);
  39815. $297 = $$0383 << 1;
  39816. $298 = HEAP32[$296>>2]|0;
  39817. $299 = ($298|0)==(0|0);
  39818. if ($299) {
  39819. label = 121;
  39820. break;
  39821. } else {
  39822. $$0383 = $297;$$0384 = $298;
  39823. }
  39824. }
  39825. if ((label|0) == 121) {
  39826. $300 = HEAP32[(23712)>>2]|0;
  39827. $301 = ($296>>>0)<($300>>>0);
  39828. if ($301) {
  39829. _abort();
  39830. // unreachable;
  39831. } else {
  39832. HEAP32[$296>>2] = $$1;
  39833. $302 = ((($$1)) + 24|0);
  39834. HEAP32[$302>>2] = $$0384;
  39835. $303 = ((($$1)) + 12|0);
  39836. HEAP32[$303>>2] = $$1;
  39837. $304 = ((($$1)) + 8|0);
  39838. HEAP32[$304>>2] = $$1;
  39839. break;
  39840. }
  39841. }
  39842. else if ((label|0) == 124) {
  39843. $305 = ((($$0384)) + 8|0);
  39844. $306 = HEAP32[$305>>2]|0;
  39845. $307 = HEAP32[(23712)>>2]|0;
  39846. $308 = ($306>>>0)>=($307>>>0);
  39847. $not$437 = ($$0384>>>0)>=($307>>>0);
  39848. $309 = $308 & $not$437;
  39849. if ($309) {
  39850. $310 = ((($306)) + 12|0);
  39851. HEAP32[$310>>2] = $$1;
  39852. HEAP32[$305>>2] = $$1;
  39853. $311 = ((($$1)) + 8|0);
  39854. HEAP32[$311>>2] = $306;
  39855. $312 = ((($$1)) + 12|0);
  39856. HEAP32[$312>>2] = $$0384;
  39857. $313 = ((($$1)) + 24|0);
  39858. HEAP32[$313>>2] = 0;
  39859. break;
  39860. } else {
  39861. _abort();
  39862. // unreachable;
  39863. }
  39864. }
  39865. }
  39866. } while(0);
  39867. $314 = HEAP32[(23728)>>2]|0;
  39868. $315 = (($314) + -1)|0;
  39869. HEAP32[(23728)>>2] = $315;
  39870. $316 = ($315|0)==(0);
  39871. if ($316) {
  39872. $$0212$in$i = (24152);
  39873. } else {
  39874. return;
  39875. }
  39876. while(1) {
  39877. $$0212$i = HEAP32[$$0212$in$i>>2]|0;
  39878. $317 = ($$0212$i|0)==(0|0);
  39879. $318 = ((($$0212$i)) + 8|0);
  39880. if ($317) {
  39881. break;
  39882. } else {
  39883. $$0212$in$i = $318;
  39884. }
  39885. }
  39886. HEAP32[(23728)>>2] = -1;
  39887. return;
  39888. }
  39889. function _realloc($0,$1) {
  39890. $0 = $0|0;
  39891. $1 = $1|0;
  39892. var $$1 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $3 = 0, $4 = 0, $5 = 0;
  39893. var $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
  39894. sp = STACKTOP;
  39895. $2 = ($0|0)==(0|0);
  39896. if ($2) {
  39897. $3 = (_malloc($1)|0);
  39898. $$1 = $3;
  39899. return ($$1|0);
  39900. }
  39901. $4 = ($1>>>0)>(4294967231);
  39902. if ($4) {
  39903. $5 = (___errno_location()|0);
  39904. HEAP32[$5>>2] = 12;
  39905. $$1 = 0;
  39906. return ($$1|0);
  39907. }
  39908. $6 = ($1>>>0)<(11);
  39909. $7 = (($1) + 11)|0;
  39910. $8 = $7 & -8;
  39911. $9 = $6 ? 16 : $8;
  39912. $10 = ((($0)) + -8|0);
  39913. $11 = (_try_realloc_chunk($10,$9)|0);
  39914. $12 = ($11|0)==(0|0);
  39915. if (!($12)) {
  39916. $13 = ((($11)) + 8|0);
  39917. $$1 = $13;
  39918. return ($$1|0);
  39919. }
  39920. $14 = (_malloc($1)|0);
  39921. $15 = ($14|0)==(0|0);
  39922. if ($15) {
  39923. $$1 = 0;
  39924. return ($$1|0);
  39925. }
  39926. $16 = ((($0)) + -4|0);
  39927. $17 = HEAP32[$16>>2]|0;
  39928. $18 = $17 & -8;
  39929. $19 = $17 & 3;
  39930. $20 = ($19|0)==(0);
  39931. $21 = $20 ? 8 : 4;
  39932. $22 = (($18) - ($21))|0;
  39933. $23 = ($22>>>0)<($1>>>0);
  39934. $24 = $23 ? $22 : $1;
  39935. _memcpy(($14|0),($0|0),($24|0))|0;
  39936. _free($0);
  39937. $$1 = $14;
  39938. return ($$1|0);
  39939. }
  39940. function _try_realloc_chunk($0,$1) {
  39941. $0 = $0|0;
  39942. $1 = $1|0;
  39943. var $$1272 = 0, $$1275 = 0, $$2 = 0, $$3 = 0, $$pre = 0, $$pre$phiZ2D = 0, $$sink1 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0;
  39944. var $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0, $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0;
  39945. var $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0, $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0;
  39946. var $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0, $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0;
  39947. var $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0, $171 = 0, $172 = 0, $173 = 0, $174 = 0, $18 = 0, $19 = 0, $2 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
  39948. var $27 = 0, $28 = 0, $29 = 0, $3 = 0, $30 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0, $42 = 0, $43 = 0, $44 = 0;
  39949. var $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0, $60 = 0, $61 = 0, $62 = 0;
  39950. var $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0, $79 = 0, $8 = 0, $80 = 0;
  39951. var $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0, $97 = 0, $98 = 0, $99 = 0;
  39952. var $cond = 0, $not$ = 0, $notlhs = 0, $notrhs = 0, $or$cond$not = 0, $or$cond3 = 0, $storemerge = 0, $storemerge1 = 0, label = 0, sp = 0;
  39953. sp = STACKTOP;
  39954. $2 = ((($0)) + 4|0);
  39955. $3 = HEAP32[$2>>2]|0;
  39956. $4 = $3 & -8;
  39957. $5 = (($0) + ($4)|0);
  39958. $6 = HEAP32[(23712)>>2]|0;
  39959. $7 = $3 & 3;
  39960. $notlhs = ($0>>>0)>=($6>>>0);
  39961. $notrhs = ($7|0)!=(1);
  39962. $or$cond$not = $notrhs & $notlhs;
  39963. $8 = ($0>>>0)<($5>>>0);
  39964. $or$cond3 = $or$cond$not & $8;
  39965. if (!($or$cond3)) {
  39966. _abort();
  39967. // unreachable;
  39968. }
  39969. $9 = ((($5)) + 4|0);
  39970. $10 = HEAP32[$9>>2]|0;
  39971. $11 = $10 & 1;
  39972. $12 = ($11|0)==(0);
  39973. if ($12) {
  39974. _abort();
  39975. // unreachable;
  39976. }
  39977. $13 = ($7|0)==(0);
  39978. if ($13) {
  39979. $14 = ($1>>>0)<(256);
  39980. if ($14) {
  39981. $$2 = 0;
  39982. return ($$2|0);
  39983. }
  39984. $15 = (($1) + 4)|0;
  39985. $16 = ($4>>>0)<($15>>>0);
  39986. if (!($16)) {
  39987. $17 = (($4) - ($1))|0;
  39988. $18 = HEAP32[(24176)>>2]|0;
  39989. $19 = $18 << 1;
  39990. $20 = ($17>>>0)>($19>>>0);
  39991. if (!($20)) {
  39992. $$2 = $0;
  39993. return ($$2|0);
  39994. }
  39995. }
  39996. $$2 = 0;
  39997. return ($$2|0);
  39998. }
  39999. $21 = ($4>>>0)<($1>>>0);
  40000. if (!($21)) {
  40001. $22 = (($4) - ($1))|0;
  40002. $23 = ($22>>>0)>(15);
  40003. if (!($23)) {
  40004. $$2 = $0;
  40005. return ($$2|0);
  40006. }
  40007. $24 = (($0) + ($1)|0);
  40008. $25 = $3 & 1;
  40009. $26 = $25 | $1;
  40010. $27 = $26 | 2;
  40011. HEAP32[$2>>2] = $27;
  40012. $28 = ((($24)) + 4|0);
  40013. $29 = $22 | 3;
  40014. HEAP32[$28>>2] = $29;
  40015. $30 = (($24) + ($22)|0);
  40016. $31 = ((($30)) + 4|0);
  40017. $32 = HEAP32[$31>>2]|0;
  40018. $33 = $32 | 1;
  40019. HEAP32[$31>>2] = $33;
  40020. _dispose_chunk($24,$22);
  40021. $$2 = $0;
  40022. return ($$2|0);
  40023. }
  40024. $34 = HEAP32[(23720)>>2]|0;
  40025. $35 = ($5|0)==($34|0);
  40026. if ($35) {
  40027. $36 = HEAP32[(23708)>>2]|0;
  40028. $37 = (($36) + ($4))|0;
  40029. $38 = ($37>>>0)>($1>>>0);
  40030. $39 = (($37) - ($1))|0;
  40031. $40 = (($0) + ($1)|0);
  40032. if (!($38)) {
  40033. $$2 = 0;
  40034. return ($$2|0);
  40035. }
  40036. $41 = $39 | 1;
  40037. $42 = ((($40)) + 4|0);
  40038. $43 = $3 & 1;
  40039. $44 = $43 | $1;
  40040. $45 = $44 | 2;
  40041. HEAP32[$2>>2] = $45;
  40042. HEAP32[$42>>2] = $41;
  40043. HEAP32[(23720)>>2] = $40;
  40044. HEAP32[(23708)>>2] = $39;
  40045. $$2 = $0;
  40046. return ($$2|0);
  40047. }
  40048. $46 = HEAP32[(23716)>>2]|0;
  40049. $47 = ($5|0)==($46|0);
  40050. if ($47) {
  40051. $48 = HEAP32[(23704)>>2]|0;
  40052. $49 = (($48) + ($4))|0;
  40053. $50 = ($49>>>0)<($1>>>0);
  40054. if ($50) {
  40055. $$2 = 0;
  40056. return ($$2|0);
  40057. }
  40058. $51 = (($49) - ($1))|0;
  40059. $52 = ($51>>>0)>(15);
  40060. $53 = $3 & 1;
  40061. if ($52) {
  40062. $54 = (($0) + ($1)|0);
  40063. $55 = (($54) + ($51)|0);
  40064. $56 = $53 | $1;
  40065. $57 = $56 | 2;
  40066. HEAP32[$2>>2] = $57;
  40067. $58 = ((($54)) + 4|0);
  40068. $59 = $51 | 1;
  40069. HEAP32[$58>>2] = $59;
  40070. HEAP32[$55>>2] = $51;
  40071. $60 = ((($55)) + 4|0);
  40072. $61 = HEAP32[$60>>2]|0;
  40073. $62 = $61 & -2;
  40074. HEAP32[$60>>2] = $62;
  40075. $storemerge = $54;$storemerge1 = $51;
  40076. } else {
  40077. $63 = $53 | $49;
  40078. $64 = $63 | 2;
  40079. HEAP32[$2>>2] = $64;
  40080. $65 = (($0) + ($49)|0);
  40081. $66 = ((($65)) + 4|0);
  40082. $67 = HEAP32[$66>>2]|0;
  40083. $68 = $67 | 1;
  40084. HEAP32[$66>>2] = $68;
  40085. $storemerge = 0;$storemerge1 = 0;
  40086. }
  40087. HEAP32[(23704)>>2] = $storemerge1;
  40088. HEAP32[(23716)>>2] = $storemerge;
  40089. $$2 = $0;
  40090. return ($$2|0);
  40091. }
  40092. $69 = $10 & 2;
  40093. $70 = ($69|0)==(0);
  40094. if (!($70)) {
  40095. $$2 = 0;
  40096. return ($$2|0);
  40097. }
  40098. $71 = $10 & -8;
  40099. $72 = (($71) + ($4))|0;
  40100. $73 = ($72>>>0)<($1>>>0);
  40101. if ($73) {
  40102. $$2 = 0;
  40103. return ($$2|0);
  40104. }
  40105. $74 = (($72) - ($1))|0;
  40106. $75 = $10 >>> 3;
  40107. $76 = ($10>>>0)<(256);
  40108. L49: do {
  40109. if ($76) {
  40110. $77 = ((($5)) + 8|0);
  40111. $78 = HEAP32[$77>>2]|0;
  40112. $79 = ((($5)) + 12|0);
  40113. $80 = HEAP32[$79>>2]|0;
  40114. $81 = $75 << 1;
  40115. $82 = (23736 + ($81<<2)|0);
  40116. $83 = ($78|0)==($82|0);
  40117. if (!($83)) {
  40118. $84 = ($78>>>0)<($6>>>0);
  40119. if ($84) {
  40120. _abort();
  40121. // unreachable;
  40122. }
  40123. $85 = ((($78)) + 12|0);
  40124. $86 = HEAP32[$85>>2]|0;
  40125. $87 = ($86|0)==($5|0);
  40126. if (!($87)) {
  40127. _abort();
  40128. // unreachable;
  40129. }
  40130. }
  40131. $88 = ($80|0)==($78|0);
  40132. if ($88) {
  40133. $89 = 1 << $75;
  40134. $90 = $89 ^ -1;
  40135. $91 = HEAP32[5924]|0;
  40136. $92 = $91 & $90;
  40137. HEAP32[5924] = $92;
  40138. break;
  40139. }
  40140. $93 = ($80|0)==($82|0);
  40141. if ($93) {
  40142. $$pre = ((($80)) + 8|0);
  40143. $$pre$phiZ2D = $$pre;
  40144. } else {
  40145. $94 = ($80>>>0)<($6>>>0);
  40146. if ($94) {
  40147. _abort();
  40148. // unreachable;
  40149. }
  40150. $95 = ((($80)) + 8|0);
  40151. $96 = HEAP32[$95>>2]|0;
  40152. $97 = ($96|0)==($5|0);
  40153. if ($97) {
  40154. $$pre$phiZ2D = $95;
  40155. } else {
  40156. _abort();
  40157. // unreachable;
  40158. }
  40159. }
  40160. $98 = ((($78)) + 12|0);
  40161. HEAP32[$98>>2] = $80;
  40162. HEAP32[$$pre$phiZ2D>>2] = $78;
  40163. } else {
  40164. $99 = ((($5)) + 24|0);
  40165. $100 = HEAP32[$99>>2]|0;
  40166. $101 = ((($5)) + 12|0);
  40167. $102 = HEAP32[$101>>2]|0;
  40168. $103 = ($102|0)==($5|0);
  40169. do {
  40170. if ($103) {
  40171. $113 = ((($5)) + 16|0);
  40172. $114 = ((($113)) + 4|0);
  40173. $115 = HEAP32[$114>>2]|0;
  40174. $116 = ($115|0)==(0|0);
  40175. if ($116) {
  40176. $117 = HEAP32[$113>>2]|0;
  40177. $118 = ($117|0)==(0|0);
  40178. if ($118) {
  40179. $$3 = 0;
  40180. break;
  40181. } else {
  40182. $$1272 = $117;$$1275 = $113;
  40183. }
  40184. } else {
  40185. $$1272 = $115;$$1275 = $114;
  40186. }
  40187. while(1) {
  40188. $119 = ((($$1272)) + 20|0);
  40189. $120 = HEAP32[$119>>2]|0;
  40190. $121 = ($120|0)==(0|0);
  40191. if (!($121)) {
  40192. $$1272 = $120;$$1275 = $119;
  40193. continue;
  40194. }
  40195. $122 = ((($$1272)) + 16|0);
  40196. $123 = HEAP32[$122>>2]|0;
  40197. $124 = ($123|0)==(0|0);
  40198. if ($124) {
  40199. break;
  40200. } else {
  40201. $$1272 = $123;$$1275 = $122;
  40202. }
  40203. }
  40204. $125 = ($$1275>>>0)<($6>>>0);
  40205. if ($125) {
  40206. _abort();
  40207. // unreachable;
  40208. } else {
  40209. HEAP32[$$1275>>2] = 0;
  40210. $$3 = $$1272;
  40211. break;
  40212. }
  40213. } else {
  40214. $104 = ((($5)) + 8|0);
  40215. $105 = HEAP32[$104>>2]|0;
  40216. $106 = ($105>>>0)<($6>>>0);
  40217. if ($106) {
  40218. _abort();
  40219. // unreachable;
  40220. }
  40221. $107 = ((($105)) + 12|0);
  40222. $108 = HEAP32[$107>>2]|0;
  40223. $109 = ($108|0)==($5|0);
  40224. if (!($109)) {
  40225. _abort();
  40226. // unreachable;
  40227. }
  40228. $110 = ((($102)) + 8|0);
  40229. $111 = HEAP32[$110>>2]|0;
  40230. $112 = ($111|0)==($5|0);
  40231. if ($112) {
  40232. HEAP32[$107>>2] = $102;
  40233. HEAP32[$110>>2] = $105;
  40234. $$3 = $102;
  40235. break;
  40236. } else {
  40237. _abort();
  40238. // unreachable;
  40239. }
  40240. }
  40241. } while(0);
  40242. $126 = ($100|0)==(0|0);
  40243. if (!($126)) {
  40244. $127 = ((($5)) + 28|0);
  40245. $128 = HEAP32[$127>>2]|0;
  40246. $129 = (24000 + ($128<<2)|0);
  40247. $130 = HEAP32[$129>>2]|0;
  40248. $131 = ($5|0)==($130|0);
  40249. do {
  40250. if ($131) {
  40251. HEAP32[$129>>2] = $$3;
  40252. $cond = ($$3|0)==(0|0);
  40253. if ($cond) {
  40254. $132 = 1 << $128;
  40255. $133 = $132 ^ -1;
  40256. $134 = HEAP32[(23700)>>2]|0;
  40257. $135 = $134 & $133;
  40258. HEAP32[(23700)>>2] = $135;
  40259. break L49;
  40260. }
  40261. } else {
  40262. $136 = HEAP32[(23712)>>2]|0;
  40263. $137 = ($100>>>0)<($136>>>0);
  40264. if ($137) {
  40265. _abort();
  40266. // unreachable;
  40267. } else {
  40268. $138 = ((($100)) + 16|0);
  40269. $139 = HEAP32[$138>>2]|0;
  40270. $not$ = ($139|0)!=($5|0);
  40271. $$sink1 = $not$&1;
  40272. $140 = (((($100)) + 16|0) + ($$sink1<<2)|0);
  40273. HEAP32[$140>>2] = $$3;
  40274. $141 = ($$3|0)==(0|0);
  40275. if ($141) {
  40276. break L49;
  40277. } else {
  40278. break;
  40279. }
  40280. }
  40281. }
  40282. } while(0);
  40283. $142 = HEAP32[(23712)>>2]|0;
  40284. $143 = ($$3>>>0)<($142>>>0);
  40285. if ($143) {
  40286. _abort();
  40287. // unreachable;
  40288. }
  40289. $144 = ((($$3)) + 24|0);
  40290. HEAP32[$144>>2] = $100;
  40291. $145 = ((($5)) + 16|0);
  40292. $146 = HEAP32[$145>>2]|0;
  40293. $147 = ($146|0)==(0|0);
  40294. do {
  40295. if (!($147)) {
  40296. $148 = ($146>>>0)<($142>>>0);
  40297. if ($148) {
  40298. _abort();
  40299. // unreachable;
  40300. } else {
  40301. $149 = ((($$3)) + 16|0);
  40302. HEAP32[$149>>2] = $146;
  40303. $150 = ((($146)) + 24|0);
  40304. HEAP32[$150>>2] = $$3;
  40305. break;
  40306. }
  40307. }
  40308. } while(0);
  40309. $151 = ((($145)) + 4|0);
  40310. $152 = HEAP32[$151>>2]|0;
  40311. $153 = ($152|0)==(0|0);
  40312. if (!($153)) {
  40313. $154 = HEAP32[(23712)>>2]|0;
  40314. $155 = ($152>>>0)<($154>>>0);
  40315. if ($155) {
  40316. _abort();
  40317. // unreachable;
  40318. } else {
  40319. $156 = ((($$3)) + 20|0);
  40320. HEAP32[$156>>2] = $152;
  40321. $157 = ((($152)) + 24|0);
  40322. HEAP32[$157>>2] = $$3;
  40323. break;
  40324. }
  40325. }
  40326. }
  40327. }
  40328. } while(0);
  40329. $158 = ($74>>>0)<(16);
  40330. $159 = $3 & 1;
  40331. if ($158) {
  40332. $160 = $72 | $159;
  40333. $161 = $160 | 2;
  40334. HEAP32[$2>>2] = $161;
  40335. $162 = (($0) + ($72)|0);
  40336. $163 = ((($162)) + 4|0);
  40337. $164 = HEAP32[$163>>2]|0;
  40338. $165 = $164 | 1;
  40339. HEAP32[$163>>2] = $165;
  40340. $$2 = $0;
  40341. return ($$2|0);
  40342. } else {
  40343. $166 = (($0) + ($1)|0);
  40344. $167 = $159 | $1;
  40345. $168 = $167 | 2;
  40346. HEAP32[$2>>2] = $168;
  40347. $169 = ((($166)) + 4|0);
  40348. $170 = $74 | 3;
  40349. HEAP32[$169>>2] = $170;
  40350. $171 = (($166) + ($74)|0);
  40351. $172 = ((($171)) + 4|0);
  40352. $173 = HEAP32[$172>>2]|0;
  40353. $174 = $173 | 1;
  40354. HEAP32[$172>>2] = $174;
  40355. _dispose_chunk($166,$74);
  40356. $$2 = $0;
  40357. return ($$2|0);
  40358. }
  40359. return (0)|0;
  40360. }
  40361. function _dispose_chunk($0,$1) {
  40362. $0 = $0|0;
  40363. $1 = $1|0;
  40364. var $$0419 = 0, $$0420 = 0, $$0431 = 0, $$0438 = 0, $$1 = 0, $$1418 = 0, $$1426 = 0, $$1429 = 0, $$1433 = 0, $$1437 = 0, $$2 = 0, $$3 = 0, $$3435 = 0, $$pre = 0, $$pre$phi24Z2D = 0, $$pre$phi26Z2D = 0, $$pre$phiZ2D = 0, $$pre23 = 0, $$pre25 = 0, $$sink2 = 0;
  40365. var $$sink4 = 0, $10 = 0, $100 = 0, $101 = 0, $102 = 0, $103 = 0, $104 = 0, $105 = 0, $106 = 0, $107 = 0, $108 = 0, $109 = 0, $11 = 0, $110 = 0, $111 = 0, $112 = 0, $113 = 0, $114 = 0, $115 = 0, $116 = 0;
  40366. var $117 = 0, $118 = 0, $119 = 0, $12 = 0, $120 = 0, $121 = 0, $122 = 0, $123 = 0, $124 = 0, $125 = 0, $126 = 0, $127 = 0, $128 = 0, $129 = 0, $13 = 0, $130 = 0, $131 = 0, $132 = 0, $133 = 0, $134 = 0;
  40367. var $135 = 0, $136 = 0, $137 = 0, $138 = 0, $139 = 0, $14 = 0, $140 = 0, $141 = 0, $142 = 0, $143 = 0, $144 = 0, $145 = 0, $146 = 0, $147 = 0, $148 = 0, $149 = 0, $15 = 0, $150 = 0, $151 = 0, $152 = 0;
  40368. var $153 = 0, $154 = 0, $155 = 0, $156 = 0, $157 = 0, $158 = 0, $159 = 0, $16 = 0, $160 = 0, $161 = 0, $162 = 0, $163 = 0, $164 = 0, $165 = 0, $166 = 0, $167 = 0, $168 = 0, $169 = 0, $17 = 0, $170 = 0;
  40369. var $171 = 0, $172 = 0, $173 = 0, $174 = 0, $175 = 0, $176 = 0, $177 = 0, $178 = 0, $179 = 0, $18 = 0, $180 = 0, $181 = 0, $182 = 0, $183 = 0, $184 = 0, $185 = 0, $186 = 0, $187 = 0, $188 = 0, $189 = 0;
  40370. var $19 = 0, $190 = 0, $191 = 0, $192 = 0, $193 = 0, $194 = 0, $195 = 0, $196 = 0, $197 = 0, $198 = 0, $199 = 0, $2 = 0, $20 = 0, $200 = 0, $201 = 0, $202 = 0, $203 = 0, $204 = 0, $205 = 0, $206 = 0;
  40371. var $207 = 0, $208 = 0, $209 = 0, $21 = 0, $210 = 0, $211 = 0, $212 = 0, $213 = 0, $214 = 0, $215 = 0, $216 = 0, $217 = 0, $218 = 0, $219 = 0, $22 = 0, $220 = 0, $221 = 0, $222 = 0, $223 = 0, $224 = 0;
  40372. var $225 = 0, $226 = 0, $227 = 0, $228 = 0, $229 = 0, $23 = 0, $230 = 0, $231 = 0, $232 = 0, $233 = 0, $234 = 0, $235 = 0, $236 = 0, $237 = 0, $238 = 0, $239 = 0, $24 = 0, $240 = 0, $241 = 0, $242 = 0;
  40373. var $243 = 0, $244 = 0, $245 = 0, $246 = 0, $247 = 0, $248 = 0, $249 = 0, $25 = 0, $250 = 0, $251 = 0, $252 = 0, $253 = 0, $254 = 0, $255 = 0, $256 = 0, $257 = 0, $258 = 0, $259 = 0, $26 = 0, $260 = 0;
  40374. var $261 = 0, $262 = 0, $263 = 0, $264 = 0, $265 = 0, $266 = 0, $267 = 0, $268 = 0, $269 = 0, $27 = 0, $270 = 0, $271 = 0, $272 = 0, $273 = 0, $274 = 0, $275 = 0, $276 = 0, $277 = 0, $278 = 0, $279 = 0;
  40375. var $28 = 0, $280 = 0, $281 = 0, $282 = 0, $283 = 0, $284 = 0, $285 = 0, $286 = 0, $287 = 0, $288 = 0, $289 = 0, $29 = 0, $290 = 0, $291 = 0, $292 = 0, $293 = 0, $294 = 0, $295 = 0, $296 = 0, $297 = 0;
  40376. var $298 = 0, $299 = 0, $3 = 0, $30 = 0, $300 = 0, $301 = 0, $302 = 0, $303 = 0, $31 = 0, $32 = 0, $33 = 0, $34 = 0, $35 = 0, $36 = 0, $37 = 0, $38 = 0, $39 = 0, $4 = 0, $40 = 0, $41 = 0;
  40377. var $42 = 0, $43 = 0, $44 = 0, $45 = 0, $46 = 0, $47 = 0, $48 = 0, $49 = 0, $5 = 0, $50 = 0, $51 = 0, $52 = 0, $53 = 0, $54 = 0, $55 = 0, $56 = 0, $57 = 0, $58 = 0, $59 = 0, $6 = 0;
  40378. var $60 = 0, $61 = 0, $62 = 0, $63 = 0, $64 = 0, $65 = 0, $66 = 0, $67 = 0, $68 = 0, $69 = 0, $7 = 0, $70 = 0, $71 = 0, $72 = 0, $73 = 0, $74 = 0, $75 = 0, $76 = 0, $77 = 0, $78 = 0;
  40379. var $79 = 0, $8 = 0, $80 = 0, $81 = 0, $82 = 0, $83 = 0, $84 = 0, $85 = 0, $86 = 0, $87 = 0, $88 = 0, $89 = 0, $9 = 0, $90 = 0, $91 = 0, $92 = 0, $93 = 0, $94 = 0, $95 = 0, $96 = 0;
  40380. var $97 = 0, $98 = 0, $99 = 0, $cond = 0, $cond17 = 0, $not$ = 0, $not$1 = 0, $not$19 = 0, label = 0, sp = 0;
  40381. sp = STACKTOP;
  40382. $2 = (($0) + ($1)|0);
  40383. $3 = ((($0)) + 4|0);
  40384. $4 = HEAP32[$3>>2]|0;
  40385. $5 = $4 & 1;
  40386. $6 = ($5|0)==(0);
  40387. L1: do {
  40388. if ($6) {
  40389. $7 = HEAP32[$0>>2]|0;
  40390. $8 = $4 & 3;
  40391. $9 = ($8|0)==(0);
  40392. if ($9) {
  40393. return;
  40394. }
  40395. $10 = (0 - ($7))|0;
  40396. $11 = (($0) + ($10)|0);
  40397. $12 = (($7) + ($1))|0;
  40398. $13 = HEAP32[(23712)>>2]|0;
  40399. $14 = ($11>>>0)<($13>>>0);
  40400. if ($14) {
  40401. _abort();
  40402. // unreachable;
  40403. }
  40404. $15 = HEAP32[(23716)>>2]|0;
  40405. $16 = ($11|0)==($15|0);
  40406. if ($16) {
  40407. $100 = ((($2)) + 4|0);
  40408. $101 = HEAP32[$100>>2]|0;
  40409. $102 = $101 & 3;
  40410. $103 = ($102|0)==(3);
  40411. if (!($103)) {
  40412. $$1 = $11;$$1418 = $12;
  40413. break;
  40414. }
  40415. $104 = (($11) + ($12)|0);
  40416. $105 = ((($11)) + 4|0);
  40417. $106 = $12 | 1;
  40418. $107 = $101 & -2;
  40419. HEAP32[(23704)>>2] = $12;
  40420. HEAP32[$100>>2] = $107;
  40421. HEAP32[$105>>2] = $106;
  40422. HEAP32[$104>>2] = $12;
  40423. return;
  40424. }
  40425. $17 = $7 >>> 3;
  40426. $18 = ($7>>>0)<(256);
  40427. if ($18) {
  40428. $19 = ((($11)) + 8|0);
  40429. $20 = HEAP32[$19>>2]|0;
  40430. $21 = ((($11)) + 12|0);
  40431. $22 = HEAP32[$21>>2]|0;
  40432. $23 = $17 << 1;
  40433. $24 = (23736 + ($23<<2)|0);
  40434. $25 = ($20|0)==($24|0);
  40435. if (!($25)) {
  40436. $26 = ($20>>>0)<($13>>>0);
  40437. if ($26) {
  40438. _abort();
  40439. // unreachable;
  40440. }
  40441. $27 = ((($20)) + 12|0);
  40442. $28 = HEAP32[$27>>2]|0;
  40443. $29 = ($28|0)==($11|0);
  40444. if (!($29)) {
  40445. _abort();
  40446. // unreachable;
  40447. }
  40448. }
  40449. $30 = ($22|0)==($20|0);
  40450. if ($30) {
  40451. $31 = 1 << $17;
  40452. $32 = $31 ^ -1;
  40453. $33 = HEAP32[5924]|0;
  40454. $34 = $33 & $32;
  40455. HEAP32[5924] = $34;
  40456. $$1 = $11;$$1418 = $12;
  40457. break;
  40458. }
  40459. $35 = ($22|0)==($24|0);
  40460. if ($35) {
  40461. $$pre25 = ((($22)) + 8|0);
  40462. $$pre$phi26Z2D = $$pre25;
  40463. } else {
  40464. $36 = ($22>>>0)<($13>>>0);
  40465. if ($36) {
  40466. _abort();
  40467. // unreachable;
  40468. }
  40469. $37 = ((($22)) + 8|0);
  40470. $38 = HEAP32[$37>>2]|0;
  40471. $39 = ($38|0)==($11|0);
  40472. if ($39) {
  40473. $$pre$phi26Z2D = $37;
  40474. } else {
  40475. _abort();
  40476. // unreachable;
  40477. }
  40478. }
  40479. $40 = ((($20)) + 12|0);
  40480. HEAP32[$40>>2] = $22;
  40481. HEAP32[$$pre$phi26Z2D>>2] = $20;
  40482. $$1 = $11;$$1418 = $12;
  40483. break;
  40484. }
  40485. $41 = ((($11)) + 24|0);
  40486. $42 = HEAP32[$41>>2]|0;
  40487. $43 = ((($11)) + 12|0);
  40488. $44 = HEAP32[$43>>2]|0;
  40489. $45 = ($44|0)==($11|0);
  40490. do {
  40491. if ($45) {
  40492. $55 = ((($11)) + 16|0);
  40493. $56 = ((($55)) + 4|0);
  40494. $57 = HEAP32[$56>>2]|0;
  40495. $58 = ($57|0)==(0|0);
  40496. if ($58) {
  40497. $59 = HEAP32[$55>>2]|0;
  40498. $60 = ($59|0)==(0|0);
  40499. if ($60) {
  40500. $$3 = 0;
  40501. break;
  40502. } else {
  40503. $$1426 = $59;$$1429 = $55;
  40504. }
  40505. } else {
  40506. $$1426 = $57;$$1429 = $56;
  40507. }
  40508. while(1) {
  40509. $61 = ((($$1426)) + 20|0);
  40510. $62 = HEAP32[$61>>2]|0;
  40511. $63 = ($62|0)==(0|0);
  40512. if (!($63)) {
  40513. $$1426 = $62;$$1429 = $61;
  40514. continue;
  40515. }
  40516. $64 = ((($$1426)) + 16|0);
  40517. $65 = HEAP32[$64>>2]|0;
  40518. $66 = ($65|0)==(0|0);
  40519. if ($66) {
  40520. break;
  40521. } else {
  40522. $$1426 = $65;$$1429 = $64;
  40523. }
  40524. }
  40525. $67 = ($$1429>>>0)<($13>>>0);
  40526. if ($67) {
  40527. _abort();
  40528. // unreachable;
  40529. } else {
  40530. HEAP32[$$1429>>2] = 0;
  40531. $$3 = $$1426;
  40532. break;
  40533. }
  40534. } else {
  40535. $46 = ((($11)) + 8|0);
  40536. $47 = HEAP32[$46>>2]|0;
  40537. $48 = ($47>>>0)<($13>>>0);
  40538. if ($48) {
  40539. _abort();
  40540. // unreachable;
  40541. }
  40542. $49 = ((($47)) + 12|0);
  40543. $50 = HEAP32[$49>>2]|0;
  40544. $51 = ($50|0)==($11|0);
  40545. if (!($51)) {
  40546. _abort();
  40547. // unreachable;
  40548. }
  40549. $52 = ((($44)) + 8|0);
  40550. $53 = HEAP32[$52>>2]|0;
  40551. $54 = ($53|0)==($11|0);
  40552. if ($54) {
  40553. HEAP32[$49>>2] = $44;
  40554. HEAP32[$52>>2] = $47;
  40555. $$3 = $44;
  40556. break;
  40557. } else {
  40558. _abort();
  40559. // unreachable;
  40560. }
  40561. }
  40562. } while(0);
  40563. $68 = ($42|0)==(0|0);
  40564. if ($68) {
  40565. $$1 = $11;$$1418 = $12;
  40566. } else {
  40567. $69 = ((($11)) + 28|0);
  40568. $70 = HEAP32[$69>>2]|0;
  40569. $71 = (24000 + ($70<<2)|0);
  40570. $72 = HEAP32[$71>>2]|0;
  40571. $73 = ($11|0)==($72|0);
  40572. do {
  40573. if ($73) {
  40574. HEAP32[$71>>2] = $$3;
  40575. $cond = ($$3|0)==(0|0);
  40576. if ($cond) {
  40577. $74 = 1 << $70;
  40578. $75 = $74 ^ -1;
  40579. $76 = HEAP32[(23700)>>2]|0;
  40580. $77 = $76 & $75;
  40581. HEAP32[(23700)>>2] = $77;
  40582. $$1 = $11;$$1418 = $12;
  40583. break L1;
  40584. }
  40585. } else {
  40586. $78 = HEAP32[(23712)>>2]|0;
  40587. $79 = ($42>>>0)<($78>>>0);
  40588. if ($79) {
  40589. _abort();
  40590. // unreachable;
  40591. } else {
  40592. $80 = ((($42)) + 16|0);
  40593. $81 = HEAP32[$80>>2]|0;
  40594. $not$1 = ($81|0)!=($11|0);
  40595. $$sink2 = $not$1&1;
  40596. $82 = (((($42)) + 16|0) + ($$sink2<<2)|0);
  40597. HEAP32[$82>>2] = $$3;
  40598. $83 = ($$3|0)==(0|0);
  40599. if ($83) {
  40600. $$1 = $11;$$1418 = $12;
  40601. break L1;
  40602. } else {
  40603. break;
  40604. }
  40605. }
  40606. }
  40607. } while(0);
  40608. $84 = HEAP32[(23712)>>2]|0;
  40609. $85 = ($$3>>>0)<($84>>>0);
  40610. if ($85) {
  40611. _abort();
  40612. // unreachable;
  40613. }
  40614. $86 = ((($$3)) + 24|0);
  40615. HEAP32[$86>>2] = $42;
  40616. $87 = ((($11)) + 16|0);
  40617. $88 = HEAP32[$87>>2]|0;
  40618. $89 = ($88|0)==(0|0);
  40619. do {
  40620. if (!($89)) {
  40621. $90 = ($88>>>0)<($84>>>0);
  40622. if ($90) {
  40623. _abort();
  40624. // unreachable;
  40625. } else {
  40626. $91 = ((($$3)) + 16|0);
  40627. HEAP32[$91>>2] = $88;
  40628. $92 = ((($88)) + 24|0);
  40629. HEAP32[$92>>2] = $$3;
  40630. break;
  40631. }
  40632. }
  40633. } while(0);
  40634. $93 = ((($87)) + 4|0);
  40635. $94 = HEAP32[$93>>2]|0;
  40636. $95 = ($94|0)==(0|0);
  40637. if ($95) {
  40638. $$1 = $11;$$1418 = $12;
  40639. } else {
  40640. $96 = HEAP32[(23712)>>2]|0;
  40641. $97 = ($94>>>0)<($96>>>0);
  40642. if ($97) {
  40643. _abort();
  40644. // unreachable;
  40645. } else {
  40646. $98 = ((($$3)) + 20|0);
  40647. HEAP32[$98>>2] = $94;
  40648. $99 = ((($94)) + 24|0);
  40649. HEAP32[$99>>2] = $$3;
  40650. $$1 = $11;$$1418 = $12;
  40651. break;
  40652. }
  40653. }
  40654. }
  40655. } else {
  40656. $$1 = $0;$$1418 = $1;
  40657. }
  40658. } while(0);
  40659. $108 = HEAP32[(23712)>>2]|0;
  40660. $109 = ($2>>>0)<($108>>>0);
  40661. if ($109) {
  40662. _abort();
  40663. // unreachable;
  40664. }
  40665. $110 = ((($2)) + 4|0);
  40666. $111 = HEAP32[$110>>2]|0;
  40667. $112 = $111 & 2;
  40668. $113 = ($112|0)==(0);
  40669. if ($113) {
  40670. $114 = HEAP32[(23720)>>2]|0;
  40671. $115 = ($2|0)==($114|0);
  40672. $116 = HEAP32[(23716)>>2]|0;
  40673. if ($115) {
  40674. $117 = HEAP32[(23708)>>2]|0;
  40675. $118 = (($117) + ($$1418))|0;
  40676. HEAP32[(23708)>>2] = $118;
  40677. HEAP32[(23720)>>2] = $$1;
  40678. $119 = $118 | 1;
  40679. $120 = ((($$1)) + 4|0);
  40680. HEAP32[$120>>2] = $119;
  40681. $121 = ($$1|0)==($116|0);
  40682. if (!($121)) {
  40683. return;
  40684. }
  40685. HEAP32[(23716)>>2] = 0;
  40686. HEAP32[(23704)>>2] = 0;
  40687. return;
  40688. }
  40689. $122 = ($2|0)==($116|0);
  40690. if ($122) {
  40691. $123 = HEAP32[(23704)>>2]|0;
  40692. $124 = (($123) + ($$1418))|0;
  40693. HEAP32[(23704)>>2] = $124;
  40694. HEAP32[(23716)>>2] = $$1;
  40695. $125 = $124 | 1;
  40696. $126 = ((($$1)) + 4|0);
  40697. HEAP32[$126>>2] = $125;
  40698. $127 = (($$1) + ($124)|0);
  40699. HEAP32[$127>>2] = $124;
  40700. return;
  40701. }
  40702. $128 = $111 & -8;
  40703. $129 = (($128) + ($$1418))|0;
  40704. $130 = $111 >>> 3;
  40705. $131 = ($111>>>0)<(256);
  40706. L96: do {
  40707. if ($131) {
  40708. $132 = ((($2)) + 8|0);
  40709. $133 = HEAP32[$132>>2]|0;
  40710. $134 = ((($2)) + 12|0);
  40711. $135 = HEAP32[$134>>2]|0;
  40712. $136 = $130 << 1;
  40713. $137 = (23736 + ($136<<2)|0);
  40714. $138 = ($133|0)==($137|0);
  40715. if (!($138)) {
  40716. $139 = ($133>>>0)<($108>>>0);
  40717. if ($139) {
  40718. _abort();
  40719. // unreachable;
  40720. }
  40721. $140 = ((($133)) + 12|0);
  40722. $141 = HEAP32[$140>>2]|0;
  40723. $142 = ($141|0)==($2|0);
  40724. if (!($142)) {
  40725. _abort();
  40726. // unreachable;
  40727. }
  40728. }
  40729. $143 = ($135|0)==($133|0);
  40730. if ($143) {
  40731. $144 = 1 << $130;
  40732. $145 = $144 ^ -1;
  40733. $146 = HEAP32[5924]|0;
  40734. $147 = $146 & $145;
  40735. HEAP32[5924] = $147;
  40736. break;
  40737. }
  40738. $148 = ($135|0)==($137|0);
  40739. if ($148) {
  40740. $$pre23 = ((($135)) + 8|0);
  40741. $$pre$phi24Z2D = $$pre23;
  40742. } else {
  40743. $149 = ($135>>>0)<($108>>>0);
  40744. if ($149) {
  40745. _abort();
  40746. // unreachable;
  40747. }
  40748. $150 = ((($135)) + 8|0);
  40749. $151 = HEAP32[$150>>2]|0;
  40750. $152 = ($151|0)==($2|0);
  40751. if ($152) {
  40752. $$pre$phi24Z2D = $150;
  40753. } else {
  40754. _abort();
  40755. // unreachable;
  40756. }
  40757. }
  40758. $153 = ((($133)) + 12|0);
  40759. HEAP32[$153>>2] = $135;
  40760. HEAP32[$$pre$phi24Z2D>>2] = $133;
  40761. } else {
  40762. $154 = ((($2)) + 24|0);
  40763. $155 = HEAP32[$154>>2]|0;
  40764. $156 = ((($2)) + 12|0);
  40765. $157 = HEAP32[$156>>2]|0;
  40766. $158 = ($157|0)==($2|0);
  40767. do {
  40768. if ($158) {
  40769. $168 = ((($2)) + 16|0);
  40770. $169 = ((($168)) + 4|0);
  40771. $170 = HEAP32[$169>>2]|0;
  40772. $171 = ($170|0)==(0|0);
  40773. if ($171) {
  40774. $172 = HEAP32[$168>>2]|0;
  40775. $173 = ($172|0)==(0|0);
  40776. if ($173) {
  40777. $$3435 = 0;
  40778. break;
  40779. } else {
  40780. $$1433 = $172;$$1437 = $168;
  40781. }
  40782. } else {
  40783. $$1433 = $170;$$1437 = $169;
  40784. }
  40785. while(1) {
  40786. $174 = ((($$1433)) + 20|0);
  40787. $175 = HEAP32[$174>>2]|0;
  40788. $176 = ($175|0)==(0|0);
  40789. if (!($176)) {
  40790. $$1433 = $175;$$1437 = $174;
  40791. continue;
  40792. }
  40793. $177 = ((($$1433)) + 16|0);
  40794. $178 = HEAP32[$177>>2]|0;
  40795. $179 = ($178|0)==(0|0);
  40796. if ($179) {
  40797. break;
  40798. } else {
  40799. $$1433 = $178;$$1437 = $177;
  40800. }
  40801. }
  40802. $180 = ($$1437>>>0)<($108>>>0);
  40803. if ($180) {
  40804. _abort();
  40805. // unreachable;
  40806. } else {
  40807. HEAP32[$$1437>>2] = 0;
  40808. $$3435 = $$1433;
  40809. break;
  40810. }
  40811. } else {
  40812. $159 = ((($2)) + 8|0);
  40813. $160 = HEAP32[$159>>2]|0;
  40814. $161 = ($160>>>0)<($108>>>0);
  40815. if ($161) {
  40816. _abort();
  40817. // unreachable;
  40818. }
  40819. $162 = ((($160)) + 12|0);
  40820. $163 = HEAP32[$162>>2]|0;
  40821. $164 = ($163|0)==($2|0);
  40822. if (!($164)) {
  40823. _abort();
  40824. // unreachable;
  40825. }
  40826. $165 = ((($157)) + 8|0);
  40827. $166 = HEAP32[$165>>2]|0;
  40828. $167 = ($166|0)==($2|0);
  40829. if ($167) {
  40830. HEAP32[$162>>2] = $157;
  40831. HEAP32[$165>>2] = $160;
  40832. $$3435 = $157;
  40833. break;
  40834. } else {
  40835. _abort();
  40836. // unreachable;
  40837. }
  40838. }
  40839. } while(0);
  40840. $181 = ($155|0)==(0|0);
  40841. if (!($181)) {
  40842. $182 = ((($2)) + 28|0);
  40843. $183 = HEAP32[$182>>2]|0;
  40844. $184 = (24000 + ($183<<2)|0);
  40845. $185 = HEAP32[$184>>2]|0;
  40846. $186 = ($2|0)==($185|0);
  40847. do {
  40848. if ($186) {
  40849. HEAP32[$184>>2] = $$3435;
  40850. $cond17 = ($$3435|0)==(0|0);
  40851. if ($cond17) {
  40852. $187 = 1 << $183;
  40853. $188 = $187 ^ -1;
  40854. $189 = HEAP32[(23700)>>2]|0;
  40855. $190 = $189 & $188;
  40856. HEAP32[(23700)>>2] = $190;
  40857. break L96;
  40858. }
  40859. } else {
  40860. $191 = HEAP32[(23712)>>2]|0;
  40861. $192 = ($155>>>0)<($191>>>0);
  40862. if ($192) {
  40863. _abort();
  40864. // unreachable;
  40865. } else {
  40866. $193 = ((($155)) + 16|0);
  40867. $194 = HEAP32[$193>>2]|0;
  40868. $not$ = ($194|0)!=($2|0);
  40869. $$sink4 = $not$&1;
  40870. $195 = (((($155)) + 16|0) + ($$sink4<<2)|0);
  40871. HEAP32[$195>>2] = $$3435;
  40872. $196 = ($$3435|0)==(0|0);
  40873. if ($196) {
  40874. break L96;
  40875. } else {
  40876. break;
  40877. }
  40878. }
  40879. }
  40880. } while(0);
  40881. $197 = HEAP32[(23712)>>2]|0;
  40882. $198 = ($$3435>>>0)<($197>>>0);
  40883. if ($198) {
  40884. _abort();
  40885. // unreachable;
  40886. }
  40887. $199 = ((($$3435)) + 24|0);
  40888. HEAP32[$199>>2] = $155;
  40889. $200 = ((($2)) + 16|0);
  40890. $201 = HEAP32[$200>>2]|0;
  40891. $202 = ($201|0)==(0|0);
  40892. do {
  40893. if (!($202)) {
  40894. $203 = ($201>>>0)<($197>>>0);
  40895. if ($203) {
  40896. _abort();
  40897. // unreachable;
  40898. } else {
  40899. $204 = ((($$3435)) + 16|0);
  40900. HEAP32[$204>>2] = $201;
  40901. $205 = ((($201)) + 24|0);
  40902. HEAP32[$205>>2] = $$3435;
  40903. break;
  40904. }
  40905. }
  40906. } while(0);
  40907. $206 = ((($200)) + 4|0);
  40908. $207 = HEAP32[$206>>2]|0;
  40909. $208 = ($207|0)==(0|0);
  40910. if (!($208)) {
  40911. $209 = HEAP32[(23712)>>2]|0;
  40912. $210 = ($207>>>0)<($209>>>0);
  40913. if ($210) {
  40914. _abort();
  40915. // unreachable;
  40916. } else {
  40917. $211 = ((($$3435)) + 20|0);
  40918. HEAP32[$211>>2] = $207;
  40919. $212 = ((($207)) + 24|0);
  40920. HEAP32[$212>>2] = $$3435;
  40921. break;
  40922. }
  40923. }
  40924. }
  40925. }
  40926. } while(0);
  40927. $213 = $129 | 1;
  40928. $214 = ((($$1)) + 4|0);
  40929. HEAP32[$214>>2] = $213;
  40930. $215 = (($$1) + ($129)|0);
  40931. HEAP32[$215>>2] = $129;
  40932. $216 = HEAP32[(23716)>>2]|0;
  40933. $217 = ($$1|0)==($216|0);
  40934. if ($217) {
  40935. HEAP32[(23704)>>2] = $129;
  40936. return;
  40937. } else {
  40938. $$2 = $129;
  40939. }
  40940. } else {
  40941. $218 = $111 & -2;
  40942. HEAP32[$110>>2] = $218;
  40943. $219 = $$1418 | 1;
  40944. $220 = ((($$1)) + 4|0);
  40945. HEAP32[$220>>2] = $219;
  40946. $221 = (($$1) + ($$1418)|0);
  40947. HEAP32[$221>>2] = $$1418;
  40948. $$2 = $$1418;
  40949. }
  40950. $222 = $$2 >>> 3;
  40951. $223 = ($$2>>>0)<(256);
  40952. if ($223) {
  40953. $224 = $222 << 1;
  40954. $225 = (23736 + ($224<<2)|0);
  40955. $226 = HEAP32[5924]|0;
  40956. $227 = 1 << $222;
  40957. $228 = $226 & $227;
  40958. $229 = ($228|0)==(0);
  40959. if ($229) {
  40960. $230 = $226 | $227;
  40961. HEAP32[5924] = $230;
  40962. $$pre = ((($225)) + 8|0);
  40963. $$0438 = $225;$$pre$phiZ2D = $$pre;
  40964. } else {
  40965. $231 = ((($225)) + 8|0);
  40966. $232 = HEAP32[$231>>2]|0;
  40967. $233 = HEAP32[(23712)>>2]|0;
  40968. $234 = ($232>>>0)<($233>>>0);
  40969. if ($234) {
  40970. _abort();
  40971. // unreachable;
  40972. } else {
  40973. $$0438 = $232;$$pre$phiZ2D = $231;
  40974. }
  40975. }
  40976. HEAP32[$$pre$phiZ2D>>2] = $$1;
  40977. $235 = ((($$0438)) + 12|0);
  40978. HEAP32[$235>>2] = $$1;
  40979. $236 = ((($$1)) + 8|0);
  40980. HEAP32[$236>>2] = $$0438;
  40981. $237 = ((($$1)) + 12|0);
  40982. HEAP32[$237>>2] = $225;
  40983. return;
  40984. }
  40985. $238 = $$2 >>> 8;
  40986. $239 = ($238|0)==(0);
  40987. if ($239) {
  40988. $$0431 = 0;
  40989. } else {
  40990. $240 = ($$2>>>0)>(16777215);
  40991. if ($240) {
  40992. $$0431 = 31;
  40993. } else {
  40994. $241 = (($238) + 1048320)|0;
  40995. $242 = $241 >>> 16;
  40996. $243 = $242 & 8;
  40997. $244 = $238 << $243;
  40998. $245 = (($244) + 520192)|0;
  40999. $246 = $245 >>> 16;
  41000. $247 = $246 & 4;
  41001. $248 = $247 | $243;
  41002. $249 = $244 << $247;
  41003. $250 = (($249) + 245760)|0;
  41004. $251 = $250 >>> 16;
  41005. $252 = $251 & 2;
  41006. $253 = $248 | $252;
  41007. $254 = (14 - ($253))|0;
  41008. $255 = $249 << $252;
  41009. $256 = $255 >>> 15;
  41010. $257 = (($254) + ($256))|0;
  41011. $258 = $257 << 1;
  41012. $259 = (($257) + 7)|0;
  41013. $260 = $$2 >>> $259;
  41014. $261 = $260 & 1;
  41015. $262 = $261 | $258;
  41016. $$0431 = $262;
  41017. }
  41018. }
  41019. $263 = (24000 + ($$0431<<2)|0);
  41020. $264 = ((($$1)) + 28|0);
  41021. HEAP32[$264>>2] = $$0431;
  41022. $265 = ((($$1)) + 16|0);
  41023. $266 = ((($$1)) + 20|0);
  41024. HEAP32[$266>>2] = 0;
  41025. HEAP32[$265>>2] = 0;
  41026. $267 = HEAP32[(23700)>>2]|0;
  41027. $268 = 1 << $$0431;
  41028. $269 = $267 & $268;
  41029. $270 = ($269|0)==(0);
  41030. if ($270) {
  41031. $271 = $267 | $268;
  41032. HEAP32[(23700)>>2] = $271;
  41033. HEAP32[$263>>2] = $$1;
  41034. $272 = ((($$1)) + 24|0);
  41035. HEAP32[$272>>2] = $263;
  41036. $273 = ((($$1)) + 12|0);
  41037. HEAP32[$273>>2] = $$1;
  41038. $274 = ((($$1)) + 8|0);
  41039. HEAP32[$274>>2] = $$1;
  41040. return;
  41041. }
  41042. $275 = HEAP32[$263>>2]|0;
  41043. $276 = ($$0431|0)==(31);
  41044. $277 = $$0431 >>> 1;
  41045. $278 = (25 - ($277))|0;
  41046. $279 = $276 ? 0 : $278;
  41047. $280 = $$2 << $279;
  41048. $$0419 = $280;$$0420 = $275;
  41049. while(1) {
  41050. $281 = ((($$0420)) + 4|0);
  41051. $282 = HEAP32[$281>>2]|0;
  41052. $283 = $282 & -8;
  41053. $284 = ($283|0)==($$2|0);
  41054. if ($284) {
  41055. label = 121;
  41056. break;
  41057. }
  41058. $285 = $$0419 >>> 31;
  41059. $286 = (((($$0420)) + 16|0) + ($285<<2)|0);
  41060. $287 = $$0419 << 1;
  41061. $288 = HEAP32[$286>>2]|0;
  41062. $289 = ($288|0)==(0|0);
  41063. if ($289) {
  41064. label = 118;
  41065. break;
  41066. } else {
  41067. $$0419 = $287;$$0420 = $288;
  41068. }
  41069. }
  41070. if ((label|0) == 118) {
  41071. $290 = HEAP32[(23712)>>2]|0;
  41072. $291 = ($286>>>0)<($290>>>0);
  41073. if ($291) {
  41074. _abort();
  41075. // unreachable;
  41076. }
  41077. HEAP32[$286>>2] = $$1;
  41078. $292 = ((($$1)) + 24|0);
  41079. HEAP32[$292>>2] = $$0420;
  41080. $293 = ((($$1)) + 12|0);
  41081. HEAP32[$293>>2] = $$1;
  41082. $294 = ((($$1)) + 8|0);
  41083. HEAP32[$294>>2] = $$1;
  41084. return;
  41085. }
  41086. else if ((label|0) == 121) {
  41087. $295 = ((($$0420)) + 8|0);
  41088. $296 = HEAP32[$295>>2]|0;
  41089. $297 = HEAP32[(23712)>>2]|0;
  41090. $298 = ($296>>>0)>=($297>>>0);
  41091. $not$19 = ($$0420>>>0)>=($297>>>0);
  41092. $299 = $298 & $not$19;
  41093. if (!($299)) {
  41094. _abort();
  41095. // unreachable;
  41096. }
  41097. $300 = ((($296)) + 12|0);
  41098. HEAP32[$300>>2] = $$1;
  41099. HEAP32[$295>>2] = $$1;
  41100. $301 = ((($$1)) + 8|0);
  41101. HEAP32[$301>>2] = $296;
  41102. $302 = ((($$1)) + 12|0);
  41103. HEAP32[$302>>2] = $$0420;
  41104. $303 = ((($$1)) + 24|0);
  41105. HEAP32[$303>>2] = 0;
  41106. return;
  41107. }
  41108. }
  41109. function runPostSets() {
  41110. }
  41111. function _memset(ptr, value, num) {
  41112. ptr = ptr|0; value = value|0; num = num|0;
  41113. var end = 0, aligned_end = 0, block_aligned_end = 0, value4 = 0;
  41114. end = (ptr + num)|0;
  41115. value = value & 0xff;
  41116. if ((num|0) >= 67 /* 64 bytes for an unrolled loop + 3 bytes for unaligned head*/) {
  41117. while ((ptr&3) != 0) {
  41118. HEAP8[((ptr)>>0)]=value;
  41119. ptr = (ptr+1)|0;
  41120. }
  41121. aligned_end = (end & -4)|0;
  41122. block_aligned_end = (aligned_end - 64)|0;
  41123. value4 = value | (value << 8) | (value << 16) | (value << 24);
  41124. while((ptr|0) <= (block_aligned_end|0)) {
  41125. HEAP32[((ptr)>>2)]=value4;
  41126. HEAP32[(((ptr)+(4))>>2)]=value4;
  41127. HEAP32[(((ptr)+(8))>>2)]=value4;
  41128. HEAP32[(((ptr)+(12))>>2)]=value4;
  41129. HEAP32[(((ptr)+(16))>>2)]=value4;
  41130. HEAP32[(((ptr)+(20))>>2)]=value4;
  41131. HEAP32[(((ptr)+(24))>>2)]=value4;
  41132. HEAP32[(((ptr)+(28))>>2)]=value4;
  41133. HEAP32[(((ptr)+(32))>>2)]=value4;
  41134. HEAP32[(((ptr)+(36))>>2)]=value4;
  41135. HEAP32[(((ptr)+(40))>>2)]=value4;
  41136. HEAP32[(((ptr)+(44))>>2)]=value4;
  41137. HEAP32[(((ptr)+(48))>>2)]=value4;
  41138. HEAP32[(((ptr)+(52))>>2)]=value4;
  41139. HEAP32[(((ptr)+(56))>>2)]=value4;
  41140. HEAP32[(((ptr)+(60))>>2)]=value4;
  41141. ptr = (ptr + 64)|0;
  41142. }
  41143. while ((ptr|0) < (aligned_end|0) ) {
  41144. HEAP32[((ptr)>>2)]=value4;
  41145. ptr = (ptr+4)|0;
  41146. }
  41147. }
  41148. // The remaining bytes.
  41149. while ((ptr|0) < (end|0)) {
  41150. HEAP8[((ptr)>>0)]=value;
  41151. ptr = (ptr+1)|0;
  41152. }
  41153. return (end-num)|0;
  41154. }
  41155. function _i64Subtract(a, b, c, d) {
  41156. a = a|0; b = b|0; c = c|0; d = d|0;
  41157. var l = 0, h = 0;
  41158. l = (a - c)>>>0;
  41159. h = (b - d)>>>0;
  41160. h = (b - d - (((c>>>0) > (a>>>0))|0))>>>0; // Borrow one from high word to low word on underflow.
  41161. return ((tempRet0 = h,l|0)|0);
  41162. }
  41163. function _i64Add(a, b, c, d) {
  41164. /*
  41165. x = a + b*2^32
  41166. y = c + d*2^32
  41167. result = l + h*2^32
  41168. */
  41169. a = a|0; b = b|0; c = c|0; d = d|0;
  41170. var l = 0, h = 0;
  41171. l = (a + c)>>>0;
  41172. h = (b + d + (((l>>>0) < (a>>>0))|0))>>>0; // Add carry from low word to high word on overflow.
  41173. return ((tempRet0 = h,l|0)|0);
  41174. }
  41175. function _memcpy(dest, src, num) {
  41176. dest = dest|0; src = src|0; num = num|0;
  41177. var ret = 0;
  41178. var aligned_dest_end = 0;
  41179. var block_aligned_dest_end = 0;
  41180. var dest_end = 0;
  41181. // Test against a benchmarked cutoff limit for when HEAPU8.set() becomes faster to use.
  41182. if ((num|0) >=
  41183. 8192
  41184. ) {
  41185. return _emscripten_memcpy_big(dest|0, src|0, num|0)|0;
  41186. }
  41187. ret = dest|0;
  41188. dest_end = (dest + num)|0;
  41189. if ((dest&3) == (src&3)) {
  41190. // The initial unaligned < 4-byte front.
  41191. while (dest & 3) {
  41192. if ((num|0) == 0) return ret|0;
  41193. HEAP8[((dest)>>0)]=((HEAP8[((src)>>0)])|0);
  41194. dest = (dest+1)|0;
  41195. src = (src+1)|0;
  41196. num = (num-1)|0;
  41197. }
  41198. aligned_dest_end = (dest_end & -4)|0;
  41199. block_aligned_dest_end = (aligned_dest_end - 64)|0;
  41200. while ((dest|0) <= (block_aligned_dest_end|0) ) {
  41201. HEAP32[((dest)>>2)]=((HEAP32[((src)>>2)])|0);
  41202. HEAP32[(((dest)+(4))>>2)]=((HEAP32[(((src)+(4))>>2)])|0);
  41203. HEAP32[(((dest)+(8))>>2)]=((HEAP32[(((src)+(8))>>2)])|0);
  41204. HEAP32[(((dest)+(12))>>2)]=((HEAP32[(((src)+(12))>>2)])|0);
  41205. HEAP32[(((dest)+(16))>>2)]=((HEAP32[(((src)+(16))>>2)])|0);
  41206. HEAP32[(((dest)+(20))>>2)]=((HEAP32[(((src)+(20))>>2)])|0);
  41207. HEAP32[(((dest)+(24))>>2)]=((HEAP32[(((src)+(24))>>2)])|0);
  41208. HEAP32[(((dest)+(28))>>2)]=((HEAP32[(((src)+(28))>>2)])|0);
  41209. HEAP32[(((dest)+(32))>>2)]=((HEAP32[(((src)+(32))>>2)])|0);
  41210. HEAP32[(((dest)+(36))>>2)]=((HEAP32[(((src)+(36))>>2)])|0);
  41211. HEAP32[(((dest)+(40))>>2)]=((HEAP32[(((src)+(40))>>2)])|0);
  41212. HEAP32[(((dest)+(44))>>2)]=((HEAP32[(((src)+(44))>>2)])|0);
  41213. HEAP32[(((dest)+(48))>>2)]=((HEAP32[(((src)+(48))>>2)])|0);
  41214. HEAP32[(((dest)+(52))>>2)]=((HEAP32[(((src)+(52))>>2)])|0);
  41215. HEAP32[(((dest)+(56))>>2)]=((HEAP32[(((src)+(56))>>2)])|0);
  41216. HEAP32[(((dest)+(60))>>2)]=((HEAP32[(((src)+(60))>>2)])|0);
  41217. dest = (dest+64)|0;
  41218. src = (src+64)|0;
  41219. }
  41220. while ((dest|0) < (aligned_dest_end|0) ) {
  41221. HEAP32[((dest)>>2)]=((HEAP32[((src)>>2)])|0);
  41222. dest = (dest+4)|0;
  41223. src = (src+4)|0;
  41224. }
  41225. } else {
  41226. // In the unaligned copy case, unroll a bit as well.
  41227. aligned_dest_end = (dest_end - 4)|0;
  41228. while ((dest|0) < (aligned_dest_end|0) ) {
  41229. HEAP8[((dest)>>0)]=((HEAP8[((src)>>0)])|0);
  41230. HEAP8[(((dest)+(1))>>0)]=((HEAP8[(((src)+(1))>>0)])|0);
  41231. HEAP8[(((dest)+(2))>>0)]=((HEAP8[(((src)+(2))>>0)])|0);
  41232. HEAP8[(((dest)+(3))>>0)]=((HEAP8[(((src)+(3))>>0)])|0);
  41233. dest = (dest+4)|0;
  41234. src = (src+4)|0;
  41235. }
  41236. }
  41237. // The remaining unaligned < 4 byte tail.
  41238. while ((dest|0) < (dest_end|0)) {
  41239. HEAP8[((dest)>>0)]=((HEAP8[((src)>>0)])|0);
  41240. dest = (dest+1)|0;
  41241. src = (src+1)|0;
  41242. }
  41243. return ret|0;
  41244. }
  41245. function _memmove(dest, src, num) {
  41246. dest = dest|0; src = src|0; num = num|0;
  41247. var ret = 0;
  41248. if (((src|0) < (dest|0)) & ((dest|0) < ((src + num)|0))) {
  41249. // Unlikely case: Copy backwards in a safe manner
  41250. ret = dest;
  41251. src = (src + num)|0;
  41252. dest = (dest + num)|0;
  41253. while ((num|0) > 0) {
  41254. dest = (dest - 1)|0;
  41255. src = (src - 1)|0;
  41256. num = (num - 1)|0;
  41257. HEAP8[((dest)>>0)]=((HEAP8[((src)>>0)])|0);
  41258. }
  41259. dest = ret;
  41260. } else {
  41261. _memcpy(dest, src, num) | 0;
  41262. }
  41263. return dest | 0;
  41264. }
  41265. function _llvm_cttz_i32(x) {
  41266. x = x|0;
  41267. var ret = 0;
  41268. ret = ((HEAP8[(((cttz_i8)+(x & 0xff))>>0)])|0);
  41269. if ((ret|0) < 8) return ret|0;
  41270. ret = ((HEAP8[(((cttz_i8)+((x >> 8)&0xff))>>0)])|0);
  41271. if ((ret|0) < 8) return (ret + 8)|0;
  41272. ret = ((HEAP8[(((cttz_i8)+((x >> 16)&0xff))>>0)])|0);
  41273. if ((ret|0) < 8) return (ret + 16)|0;
  41274. return (((HEAP8[(((cttz_i8)+(x >>> 24))>>0)])|0) + 24)|0;
  41275. }
  41276. function ___udivmoddi4($a$0, $a$1, $b$0, $b$1, $rem) {
  41277. $a$0 = $a$0 | 0;
  41278. $a$1 = $a$1 | 0;
  41279. $b$0 = $b$0 | 0;
  41280. $b$1 = $b$1 | 0;
  41281. $rem = $rem | 0;
  41282. var $n_sroa_0_0_extract_trunc = 0, $n_sroa_1_4_extract_shift$0 = 0, $n_sroa_1_4_extract_trunc = 0, $d_sroa_0_0_extract_trunc = 0, $d_sroa_1_4_extract_shift$0 = 0, $d_sroa_1_4_extract_trunc = 0, $4 = 0, $17 = 0, $37 = 0, $49 = 0, $51 = 0, $57 = 0, $58 = 0, $66 = 0, $78 = 0, $86 = 0, $88 = 0, $89 = 0, $91 = 0, $92 = 0, $95 = 0, $105 = 0, $117 = 0, $119 = 0, $125 = 0, $126 = 0, $130 = 0, $q_sroa_1_1_ph = 0, $q_sroa_0_1_ph = 0, $r_sroa_1_1_ph = 0, $r_sroa_0_1_ph = 0, $sr_1_ph = 0, $d_sroa_0_0_insert_insert99$0 = 0, $d_sroa_0_0_insert_insert99$1 = 0, $137$0 = 0, $137$1 = 0, $carry_0203 = 0, $sr_1202 = 0, $r_sroa_0_1201 = 0, $r_sroa_1_1200 = 0, $q_sroa_0_1199 = 0, $q_sroa_1_1198 = 0, $147 = 0, $149 = 0, $r_sroa_0_0_insert_insert42$0 = 0, $r_sroa_0_0_insert_insert42$1 = 0, $150$1 = 0, $151$0 = 0, $152 = 0, $154$0 = 0, $r_sroa_0_0_extract_trunc = 0, $r_sroa_1_4_extract_trunc = 0, $155 = 0, $carry_0_lcssa$0 = 0, $carry_0_lcssa$1 = 0, $r_sroa_0_1_lcssa = 0, $r_sroa_1_1_lcssa = 0, $q_sroa_0_1_lcssa = 0, $q_sroa_1_1_lcssa = 0, $q_sroa_0_0_insert_ext75$0 = 0, $q_sroa_0_0_insert_ext75$1 = 0, $q_sroa_0_0_insert_insert77$1 = 0, $_0$0 = 0, $_0$1 = 0;
  41283. $n_sroa_0_0_extract_trunc = $a$0;
  41284. $n_sroa_1_4_extract_shift$0 = $a$1;
  41285. $n_sroa_1_4_extract_trunc = $n_sroa_1_4_extract_shift$0;
  41286. $d_sroa_0_0_extract_trunc = $b$0;
  41287. $d_sroa_1_4_extract_shift$0 = $b$1;
  41288. $d_sroa_1_4_extract_trunc = $d_sroa_1_4_extract_shift$0;
  41289. if (($n_sroa_1_4_extract_trunc | 0) == 0) {
  41290. $4 = ($rem | 0) != 0;
  41291. if (($d_sroa_1_4_extract_trunc | 0) == 0) {
  41292. if ($4) {
  41293. HEAP32[$rem >> 2] = ($n_sroa_0_0_extract_trunc >>> 0) % ($d_sroa_0_0_extract_trunc >>> 0);
  41294. HEAP32[$rem + 4 >> 2] = 0;
  41295. }
  41296. $_0$1 = 0;
  41297. $_0$0 = ($n_sroa_0_0_extract_trunc >>> 0) / ($d_sroa_0_0_extract_trunc >>> 0) >>> 0;
  41298. return (tempRet0 = $_0$1, $_0$0) | 0;
  41299. } else {
  41300. if (!$4) {
  41301. $_0$1 = 0;
  41302. $_0$0 = 0;
  41303. return (tempRet0 = $_0$1, $_0$0) | 0;
  41304. }
  41305. HEAP32[$rem >> 2] = $a$0 & -1;
  41306. HEAP32[$rem + 4 >> 2] = $a$1 & 0;
  41307. $_0$1 = 0;
  41308. $_0$0 = 0;
  41309. return (tempRet0 = $_0$1, $_0$0) | 0;
  41310. }
  41311. }
  41312. $17 = ($d_sroa_1_4_extract_trunc | 0) == 0;
  41313. do {
  41314. if (($d_sroa_0_0_extract_trunc | 0) == 0) {
  41315. if ($17) {
  41316. if (($rem | 0) != 0) {
  41317. HEAP32[$rem >> 2] = ($n_sroa_1_4_extract_trunc >>> 0) % ($d_sroa_0_0_extract_trunc >>> 0);
  41318. HEAP32[$rem + 4 >> 2] = 0;
  41319. }
  41320. $_0$1 = 0;
  41321. $_0$0 = ($n_sroa_1_4_extract_trunc >>> 0) / ($d_sroa_0_0_extract_trunc >>> 0) >>> 0;
  41322. return (tempRet0 = $_0$1, $_0$0) | 0;
  41323. }
  41324. if (($n_sroa_0_0_extract_trunc | 0) == 0) {
  41325. if (($rem | 0) != 0) {
  41326. HEAP32[$rem >> 2] = 0;
  41327. HEAP32[$rem + 4 >> 2] = ($n_sroa_1_4_extract_trunc >>> 0) % ($d_sroa_1_4_extract_trunc >>> 0);
  41328. }
  41329. $_0$1 = 0;
  41330. $_0$0 = ($n_sroa_1_4_extract_trunc >>> 0) / ($d_sroa_1_4_extract_trunc >>> 0) >>> 0;
  41331. return (tempRet0 = $_0$1, $_0$0) | 0;
  41332. }
  41333. $37 = $d_sroa_1_4_extract_trunc - 1 | 0;
  41334. if (($37 & $d_sroa_1_4_extract_trunc | 0) == 0) {
  41335. if (($rem | 0) != 0) {
  41336. HEAP32[$rem >> 2] = 0 | $a$0 & -1;
  41337. HEAP32[$rem + 4 >> 2] = $37 & $n_sroa_1_4_extract_trunc | $a$1 & 0;
  41338. }
  41339. $_0$1 = 0;
  41340. $_0$0 = $n_sroa_1_4_extract_trunc >>> ((_llvm_cttz_i32($d_sroa_1_4_extract_trunc | 0) | 0) >>> 0);
  41341. return (tempRet0 = $_0$1, $_0$0) | 0;
  41342. }
  41343. $49 = Math_clz32($d_sroa_1_4_extract_trunc | 0) | 0;
  41344. $51 = $49 - (Math_clz32($n_sroa_1_4_extract_trunc | 0) | 0) | 0;
  41345. if ($51 >>> 0 <= 30) {
  41346. $57 = $51 + 1 | 0;
  41347. $58 = 31 - $51 | 0;
  41348. $sr_1_ph = $57;
  41349. $r_sroa_0_1_ph = $n_sroa_1_4_extract_trunc << $58 | $n_sroa_0_0_extract_trunc >>> ($57 >>> 0);
  41350. $r_sroa_1_1_ph = $n_sroa_1_4_extract_trunc >>> ($57 >>> 0);
  41351. $q_sroa_0_1_ph = 0;
  41352. $q_sroa_1_1_ph = $n_sroa_0_0_extract_trunc << $58;
  41353. break;
  41354. }
  41355. if (($rem | 0) == 0) {
  41356. $_0$1 = 0;
  41357. $_0$0 = 0;
  41358. return (tempRet0 = $_0$1, $_0$0) | 0;
  41359. }
  41360. HEAP32[$rem >> 2] = 0 | $a$0 & -1;
  41361. HEAP32[$rem + 4 >> 2] = $n_sroa_1_4_extract_shift$0 | $a$1 & 0;
  41362. $_0$1 = 0;
  41363. $_0$0 = 0;
  41364. return (tempRet0 = $_0$1, $_0$0) | 0;
  41365. } else {
  41366. if (!$17) {
  41367. $117 = Math_clz32($d_sroa_1_4_extract_trunc | 0) | 0;
  41368. $119 = $117 - (Math_clz32($n_sroa_1_4_extract_trunc | 0) | 0) | 0;
  41369. if ($119 >>> 0 <= 31) {
  41370. $125 = $119 + 1 | 0;
  41371. $126 = 31 - $119 | 0;
  41372. $130 = $119 - 31 >> 31;
  41373. $sr_1_ph = $125;
  41374. $r_sroa_0_1_ph = $n_sroa_0_0_extract_trunc >>> ($125 >>> 0) & $130 | $n_sroa_1_4_extract_trunc << $126;
  41375. $r_sroa_1_1_ph = $n_sroa_1_4_extract_trunc >>> ($125 >>> 0) & $130;
  41376. $q_sroa_0_1_ph = 0;
  41377. $q_sroa_1_1_ph = $n_sroa_0_0_extract_trunc << $126;
  41378. break;
  41379. }
  41380. if (($rem | 0) == 0) {
  41381. $_0$1 = 0;
  41382. $_0$0 = 0;
  41383. return (tempRet0 = $_0$1, $_0$0) | 0;
  41384. }
  41385. HEAP32[$rem >> 2] = 0 | $a$0 & -1;
  41386. HEAP32[$rem + 4 >> 2] = $n_sroa_1_4_extract_shift$0 | $a$1 & 0;
  41387. $_0$1 = 0;
  41388. $_0$0 = 0;
  41389. return (tempRet0 = $_0$1, $_0$0) | 0;
  41390. }
  41391. $66 = $d_sroa_0_0_extract_trunc - 1 | 0;
  41392. if (($66 & $d_sroa_0_0_extract_trunc | 0) != 0) {
  41393. $86 = (Math_clz32($d_sroa_0_0_extract_trunc | 0) | 0) + 33 | 0;
  41394. $88 = $86 - (Math_clz32($n_sroa_1_4_extract_trunc | 0) | 0) | 0;
  41395. $89 = 64 - $88 | 0;
  41396. $91 = 32 - $88 | 0;
  41397. $92 = $91 >> 31;
  41398. $95 = $88 - 32 | 0;
  41399. $105 = $95 >> 31;
  41400. $sr_1_ph = $88;
  41401. $r_sroa_0_1_ph = $91 - 1 >> 31 & $n_sroa_1_4_extract_trunc >>> ($95 >>> 0) | ($n_sroa_1_4_extract_trunc << $91 | $n_sroa_0_0_extract_trunc >>> ($88 >>> 0)) & $105;
  41402. $r_sroa_1_1_ph = $105 & $n_sroa_1_4_extract_trunc >>> ($88 >>> 0);
  41403. $q_sroa_0_1_ph = $n_sroa_0_0_extract_trunc << $89 & $92;
  41404. $q_sroa_1_1_ph = ($n_sroa_1_4_extract_trunc << $89 | $n_sroa_0_0_extract_trunc >>> ($95 >>> 0)) & $92 | $n_sroa_0_0_extract_trunc << $91 & $88 - 33 >> 31;
  41405. break;
  41406. }
  41407. if (($rem | 0) != 0) {
  41408. HEAP32[$rem >> 2] = $66 & $n_sroa_0_0_extract_trunc;
  41409. HEAP32[$rem + 4 >> 2] = 0;
  41410. }
  41411. if (($d_sroa_0_0_extract_trunc | 0) == 1) {
  41412. $_0$1 = $n_sroa_1_4_extract_shift$0 | $a$1 & 0;
  41413. $_0$0 = 0 | $a$0 & -1;
  41414. return (tempRet0 = $_0$1, $_0$0) | 0;
  41415. } else {
  41416. $78 = _llvm_cttz_i32($d_sroa_0_0_extract_trunc | 0) | 0;
  41417. $_0$1 = 0 | $n_sroa_1_4_extract_trunc >>> ($78 >>> 0);
  41418. $_0$0 = $n_sroa_1_4_extract_trunc << 32 - $78 | $n_sroa_0_0_extract_trunc >>> ($78 >>> 0) | 0;
  41419. return (tempRet0 = $_0$1, $_0$0) | 0;
  41420. }
  41421. }
  41422. } while (0);
  41423. if (($sr_1_ph | 0) == 0) {
  41424. $q_sroa_1_1_lcssa = $q_sroa_1_1_ph;
  41425. $q_sroa_0_1_lcssa = $q_sroa_0_1_ph;
  41426. $r_sroa_1_1_lcssa = $r_sroa_1_1_ph;
  41427. $r_sroa_0_1_lcssa = $r_sroa_0_1_ph;
  41428. $carry_0_lcssa$1 = 0;
  41429. $carry_0_lcssa$0 = 0;
  41430. } else {
  41431. $d_sroa_0_0_insert_insert99$0 = 0 | $b$0 & -1;
  41432. $d_sroa_0_0_insert_insert99$1 = $d_sroa_1_4_extract_shift$0 | $b$1 & 0;
  41433. $137$0 = _i64Add($d_sroa_0_0_insert_insert99$0 | 0, $d_sroa_0_0_insert_insert99$1 | 0, -1, -1) | 0;
  41434. $137$1 = tempRet0;
  41435. $q_sroa_1_1198 = $q_sroa_1_1_ph;
  41436. $q_sroa_0_1199 = $q_sroa_0_1_ph;
  41437. $r_sroa_1_1200 = $r_sroa_1_1_ph;
  41438. $r_sroa_0_1201 = $r_sroa_0_1_ph;
  41439. $sr_1202 = $sr_1_ph;
  41440. $carry_0203 = 0;
  41441. while (1) {
  41442. $147 = $q_sroa_0_1199 >>> 31 | $q_sroa_1_1198 << 1;
  41443. $149 = $carry_0203 | $q_sroa_0_1199 << 1;
  41444. $r_sroa_0_0_insert_insert42$0 = 0 | ($r_sroa_0_1201 << 1 | $q_sroa_1_1198 >>> 31);
  41445. $r_sroa_0_0_insert_insert42$1 = $r_sroa_0_1201 >>> 31 | $r_sroa_1_1200 << 1 | 0;
  41446. _i64Subtract($137$0 | 0, $137$1 | 0, $r_sroa_0_0_insert_insert42$0 | 0, $r_sroa_0_0_insert_insert42$1 | 0) | 0;
  41447. $150$1 = tempRet0;
  41448. $151$0 = $150$1 >> 31 | (($150$1 | 0) < 0 ? -1 : 0) << 1;
  41449. $152 = $151$0 & 1;
  41450. $154$0 = _i64Subtract($r_sroa_0_0_insert_insert42$0 | 0, $r_sroa_0_0_insert_insert42$1 | 0, $151$0 & $d_sroa_0_0_insert_insert99$0 | 0, ((($150$1 | 0) < 0 ? -1 : 0) >> 31 | (($150$1 | 0) < 0 ? -1 : 0) << 1) & $d_sroa_0_0_insert_insert99$1 | 0) | 0;
  41451. $r_sroa_0_0_extract_trunc = $154$0;
  41452. $r_sroa_1_4_extract_trunc = tempRet0;
  41453. $155 = $sr_1202 - 1 | 0;
  41454. if (($155 | 0) == 0) {
  41455. break;
  41456. } else {
  41457. $q_sroa_1_1198 = $147;
  41458. $q_sroa_0_1199 = $149;
  41459. $r_sroa_1_1200 = $r_sroa_1_4_extract_trunc;
  41460. $r_sroa_0_1201 = $r_sroa_0_0_extract_trunc;
  41461. $sr_1202 = $155;
  41462. $carry_0203 = $152;
  41463. }
  41464. }
  41465. $q_sroa_1_1_lcssa = $147;
  41466. $q_sroa_0_1_lcssa = $149;
  41467. $r_sroa_1_1_lcssa = $r_sroa_1_4_extract_trunc;
  41468. $r_sroa_0_1_lcssa = $r_sroa_0_0_extract_trunc;
  41469. $carry_0_lcssa$1 = 0;
  41470. $carry_0_lcssa$0 = $152;
  41471. }
  41472. $q_sroa_0_0_insert_ext75$0 = $q_sroa_0_1_lcssa;
  41473. $q_sroa_0_0_insert_ext75$1 = 0;
  41474. $q_sroa_0_0_insert_insert77$1 = $q_sroa_1_1_lcssa | $q_sroa_0_0_insert_ext75$1;
  41475. if (($rem | 0) != 0) {
  41476. HEAP32[$rem >> 2] = 0 | $r_sroa_0_1_lcssa;
  41477. HEAP32[$rem + 4 >> 2] = $r_sroa_1_1_lcssa | 0;
  41478. }
  41479. $_0$1 = (0 | $q_sroa_0_0_insert_ext75$0) >>> 31 | $q_sroa_0_0_insert_insert77$1 << 1 | ($q_sroa_0_0_insert_ext75$1 << 1 | $q_sroa_0_0_insert_ext75$0 >>> 31) & 0 | $carry_0_lcssa$1;
  41480. $_0$0 = ($q_sroa_0_0_insert_ext75$0 << 1 | 0 >>> 31) & -2 | $carry_0_lcssa$0;
  41481. return (tempRet0 = $_0$1, $_0$0) | 0;
  41482. }
  41483. function ___uremdi3($a$0, $a$1, $b$0, $b$1) {
  41484. $a$0 = $a$0 | 0;
  41485. $a$1 = $a$1 | 0;
  41486. $b$0 = $b$0 | 0;
  41487. $b$1 = $b$1 | 0;
  41488. var $rem = 0, __stackBase__ = 0;
  41489. __stackBase__ = STACKTOP;
  41490. STACKTOP = STACKTOP + 16 | 0;
  41491. $rem = __stackBase__ | 0;
  41492. ___udivmoddi4($a$0, $a$1, $b$0, $b$1, $rem) | 0;
  41493. STACKTOP = __stackBase__;
  41494. return (tempRet0 = HEAP32[$rem + 4 >> 2] | 0, HEAP32[$rem >> 2] | 0) | 0;
  41495. }
  41496. function ___udivdi3($a$0, $a$1, $b$0, $b$1) {
  41497. $a$0 = $a$0 | 0;
  41498. $a$1 = $a$1 | 0;
  41499. $b$0 = $b$0 | 0;
  41500. $b$1 = $b$1 | 0;
  41501. var $1$0 = 0;
  41502. $1$0 = ___udivmoddi4($a$0, $a$1, $b$0, $b$1, 0) | 0;
  41503. return $1$0 | 0;
  41504. }
  41505. function _roundf(f) {
  41506. f = +f;
  41507. return f >= +0 ? +Math_floor(f + +0.5) : +Math_ceil(f - +0.5); // TODO: use fround?
  41508. }
  41509. function _bitshift64Lshr(low, high, bits) {
  41510. low = low|0; high = high|0; bits = bits|0;
  41511. var ander = 0;
  41512. if ((bits|0) < 32) {
  41513. ander = ((1 << bits) - 1)|0;
  41514. tempRet0 = high >>> bits;
  41515. return (low >>> bits) | ((high&ander) << (32 - bits));
  41516. }
  41517. tempRet0 = 0;
  41518. return (high >>> (bits - 32))|0;
  41519. }
  41520. function _sbrk(increment) {
  41521. increment = increment|0;
  41522. var oldDynamicTop = 0;
  41523. var oldDynamicTopOnChange = 0;
  41524. var newDynamicTop = 0;
  41525. var totalMemory = 0;
  41526. increment = ((increment + 15) & -16)|0;
  41527. oldDynamicTop = HEAP32[DYNAMICTOP_PTR>>2]|0;
  41528. newDynamicTop = oldDynamicTop + increment | 0;
  41529. if (((increment|0) > 0 & (newDynamicTop|0) < (oldDynamicTop|0)) // Detect and fail if we would wrap around signed 32-bit int.
  41530. | (newDynamicTop|0) < 0) { // Also underflow, sbrk() should be able to be used to subtract.
  41531. abortOnCannotGrowMemory()|0;
  41532. ___setErrNo(12);
  41533. return -1;
  41534. }
  41535. HEAP32[DYNAMICTOP_PTR>>2] = newDynamicTop;
  41536. totalMemory = getTotalMemory()|0;
  41537. if ((newDynamicTop|0) > (totalMemory|0)) {
  41538. if ((enlargeMemory()|0) == 0) {
  41539. ___setErrNo(12);
  41540. HEAP32[DYNAMICTOP_PTR>>2] = oldDynamicTop;
  41541. return -1;
  41542. }
  41543. }
  41544. return oldDynamicTop|0;
  41545. }
  41546. function _bitshift64Shl(low, high, bits) {
  41547. low = low|0; high = high|0; bits = bits|0;
  41548. var ander = 0;
  41549. if ((bits|0) < 32) {
  41550. ander = ((1 << bits) - 1)|0;
  41551. tempRet0 = (high << bits) | ((low&(ander << (32 - bits))) >>> (32 - bits));
  41552. return low << bits;
  41553. }
  41554. tempRet0 = low << (bits - 32);
  41555. return 0;
  41556. }
  41557. function _llvm_bswap_i32(x) {
  41558. x = x|0;
  41559. return (((x&0xff)<<24) | (((x>>8)&0xff)<<16) | (((x>>16)&0xff)<<8) | (x>>>24))|0;
  41560. }
  41561. function dynCall_viiiii(index,a1,a2,a3,a4,a5) {
  41562. index = index|0;
  41563. a1=a1|0; a2=a2|0; a3=a3|0; a4=a4|0; a5=a5|0;
  41564. FUNCTION_TABLE_viiiii[index&7](a1|0,a2|0,a3|0,a4|0,a5|0);
  41565. }
  41566. function dynCall_vd(index,a1) {
  41567. index = index|0;
  41568. a1=+a1;
  41569. FUNCTION_TABLE_vd[index&3](+a1);
  41570. }
  41571. function dynCall_vid(index,a1,a2) {
  41572. index = index|0;
  41573. a1=a1|0; a2=+a2;
  41574. FUNCTION_TABLE_vid[index&3](a1|0,+a2);
  41575. }
  41576. function dynCall_vi(index,a1) {
  41577. index = index|0;
  41578. a1=a1|0;
  41579. FUNCTION_TABLE_vi[index&31](a1|0);
  41580. }
  41581. function dynCall_vii(index,a1,a2) {
  41582. index = index|0;
  41583. a1=a1|0; a2=a2|0;
  41584. FUNCTION_TABLE_vii[index&63](a1|0,a2|0);
  41585. }
  41586. function dynCall_ii(index,a1) {
  41587. index = index|0;
  41588. a1=a1|0;
  41589. return FUNCTION_TABLE_ii[index&15](a1|0)|0;
  41590. }
  41591. function dynCall_viddd(index,a1,a2,a3,a4) {
  41592. index = index|0;
  41593. a1=a1|0; a2=+a2; a3=+a3; a4=+a4;
  41594. FUNCTION_TABLE_viddd[index&3](a1|0,+a2,+a3,+a4);
  41595. }
  41596. function dynCall_vidd(index,a1,a2,a3) {
  41597. index = index|0;
  41598. a1=a1|0; a2=+a2; a3=+a3;
  41599. FUNCTION_TABLE_vidd[index&7](a1|0,+a2,+a3);
  41600. }
  41601. function dynCall_iiii(index,a1,a2,a3) {
  41602. index = index|0;
  41603. a1=a1|0; a2=a2|0; a3=a3|0;
  41604. return FUNCTION_TABLE_iiii[index&15](a1|0,a2|0,a3|0)|0;
  41605. }
  41606. function dynCall_viiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8) {
  41607. index = index|0;
  41608. a1=a1|0; a2=a2|0; a3=a3|0; a4=a4|0; a5=a5|0; a6=a6|0; a7=a7|0; a8=a8|0;
  41609. FUNCTION_TABLE_viiiiiiii[index&3](a1|0,a2|0,a3|0,a4|0,a5|0,a6|0,a7|0,a8|0);
  41610. }
  41611. function dynCall_viiiiii(index,a1,a2,a3,a4,a5,a6) {
  41612. index = index|0;
  41613. a1=a1|0; a2=a2|0; a3=a3|0; a4=a4|0; a5=a5|0; a6=a6|0;
  41614. FUNCTION_TABLE_viiiiii[index&3](a1|0,a2|0,a3|0,a4|0,a5|0,a6|0);
  41615. }
  41616. function dynCall_vdd(index,a1,a2) {
  41617. index = index|0;
  41618. a1=+a1; a2=+a2;
  41619. FUNCTION_TABLE_vdd[index&3](+a1,+a2);
  41620. }
  41621. function dynCall_dd(index,a1) {
  41622. index = index|0;
  41623. a1=+a1;
  41624. return +FUNCTION_TABLE_dd[index&7](+a1);
  41625. }
  41626. function dynCall_vidddd(index,a1,a2,a3,a4,a5) {
  41627. index = index|0;
  41628. a1=a1|0; a2=+a2; a3=+a3; a4=+a4; a5=+a5;
  41629. FUNCTION_TABLE_vidddd[index&3](a1|0,+a2,+a3,+a4,+a5);
  41630. }
  41631. function dynCall_vdi(index,a1,a2) {
  41632. index = index|0;
  41633. a1=+a1; a2=a2|0;
  41634. FUNCTION_TABLE_vdi[index&1](+a1,a2|0);
  41635. }
  41636. function dynCall_viiiiiii(index,a1,a2,a3,a4,a5,a6,a7) {
  41637. index = index|0;
  41638. a1=a1|0; a2=a2|0; a3=a3|0; a4=a4|0; a5=a5|0; a6=a6|0; a7=a7|0;
  41639. FUNCTION_TABLE_viiiiiii[index&3](a1|0,a2|0,a3|0,a4|0,a5|0,a6|0,a7|0);
  41640. }
  41641. function dynCall_viiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9) {
  41642. index = index|0;
  41643. a1=a1|0; a2=a2|0; a3=a3|0; a4=a4|0; a5=a5|0; a6=a6|0; a7=a7|0; a8=a8|0; a9=a9|0;
  41644. FUNCTION_TABLE_viiiiiiiii[index&3](a1|0,a2|0,a3|0,a4|0,a5|0,a6|0,a7|0,a8|0,a9|0);
  41645. }
  41646. function dynCall_iii(index,a1,a2) {
  41647. index = index|0;
  41648. a1=a1|0; a2=a2|0;
  41649. return FUNCTION_TABLE_iii[index&3](a1|0,a2|0)|0;
  41650. }
  41651. function dynCall_i(index) {
  41652. index = index|0;
  41653. return FUNCTION_TABLE_i[index&3]()|0;
  41654. }
  41655. function dynCall_vdddddd(index,a1,a2,a3,a4,a5,a6) {
  41656. index = index|0;
  41657. a1=+a1; a2=+a2; a3=+a3; a4=+a4; a5=+a5; a6=+a6;
  41658. FUNCTION_TABLE_vdddddd[index&1](+a1,+a2,+a3,+a4,+a5,+a6);
  41659. }
  41660. function dynCall_vdddd(index,a1,a2,a3,a4) {
  41661. index = index|0;
  41662. a1=+a1; a2=+a2; a3=+a3; a4=+a4;
  41663. FUNCTION_TABLE_vdddd[index&3](+a1,+a2,+a3,+a4);
  41664. }
  41665. function dynCall_viii(index,a1,a2,a3) {
  41666. index = index|0;
  41667. a1=a1|0; a2=a2|0; a3=a3|0;
  41668. FUNCTION_TABLE_viii[index&31](a1|0,a2|0,a3|0);
  41669. }
  41670. function dynCall_v(index) {
  41671. index = index|0;
  41672. FUNCTION_TABLE_v[index&7]();
  41673. }
  41674. function dynCall_viid(index,a1,a2,a3) {
  41675. index = index|0;
  41676. a1=a1|0; a2=a2|0; a3=+a3;
  41677. FUNCTION_TABLE_viid[index&1](a1|0,a2|0,+a3);
  41678. }
  41679. function dynCall_ddd(index,a1,a2) {
  41680. index = index|0;
  41681. a1=+a1; a2=+a2;
  41682. return +FUNCTION_TABLE_ddd[index&7](+a1,+a2);
  41683. }
  41684. function dynCall_viiii(index,a1,a2,a3,a4) {
  41685. index = index|0;
  41686. a1=a1|0; a2=a2|0; a3=a3|0; a4=a4|0;
  41687. FUNCTION_TABLE_viiii[index&31](a1|0,a2|0,a3|0,a4|0);
  41688. }
  41689. function b0(p0,p1,p2,p3,p4) {
  41690. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0; nullFunc_viiiii(0);
  41691. }
  41692. function _emscripten_glUniform4i__wrapper(p0,p1,p2,p3,p4) {
  41693. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0; _emscripten_glUniform4i(p0|0,p1|0,p2|0,p3|0,p4|0);
  41694. }
  41695. function _emscripten_glFramebufferTexture2D__wrapper(p0,p1,p2,p3,p4) {
  41696. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0; _emscripten_glFramebufferTexture2D(p0|0,p1|0,p2|0,p3|0,p4|0);
  41697. }
  41698. function _emscripten_glShaderBinary__wrapper(p0,p1,p2,p3,p4) {
  41699. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0; _emscripten_glShaderBinary(p0|0,p1|0,p2|0,p3|0,p4|0);
  41700. }
  41701. function _emscripten_glDrawElementsInstanced__wrapper(p0,p1,p2,p3,p4) {
  41702. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0; _emscripten_glDrawElementsInstanced(p0|0,p1|0,p2|0,p3|0,p4|0);
  41703. }
  41704. function b1(p0) {
  41705. p0 = +p0; nullFunc_vd(1);
  41706. }
  41707. function _emscripten_glClearDepth__wrapper(p0) {
  41708. p0 = +p0; _emscripten_glClearDepth(+p0);
  41709. }
  41710. function _emscripten_glClearDepthf__wrapper(p0) {
  41711. p0 = +p0; _emscripten_glClearDepthf(+p0);
  41712. }
  41713. function _emscripten_glLineWidth__wrapper(p0) {
  41714. p0 = +p0; _emscripten_glLineWidth(+p0);
  41715. }
  41716. function b2(p0,p1) {
  41717. p0 = p0|0;p1 = +p1; nullFunc_vid(2);
  41718. }
  41719. function _emscripten_glUniform1f__wrapper(p0,p1) {
  41720. p0 = p0|0;p1 = +p1; _emscripten_glUniform1f(p0|0,+p1);
  41721. }
  41722. function _emscripten_glVertexAttrib1f__wrapper(p0,p1) {
  41723. p0 = p0|0;p1 = +p1; _emscripten_glVertexAttrib1f(p0|0,+p1);
  41724. }
  41725. function b3(p0) {
  41726. p0 = p0|0; nullFunc_vi(3);
  41727. }
  41728. function _emscripten_glDeleteShader__wrapper(p0) {
  41729. p0 = p0|0; _emscripten_glDeleteShader(p0|0);
  41730. }
  41731. function _emscripten_glCompileShader__wrapper(p0) {
  41732. p0 = p0|0; _emscripten_glCompileShader(p0|0);
  41733. }
  41734. function _emscripten_glDeleteProgram__wrapper(p0) {
  41735. p0 = p0|0; _emscripten_glDeleteProgram(p0|0);
  41736. }
  41737. function _emscripten_glLinkProgram__wrapper(p0) {
  41738. p0 = p0|0; _emscripten_glLinkProgram(p0|0);
  41739. }
  41740. function _emscripten_glUseProgram__wrapper(p0) {
  41741. p0 = p0|0; _emscripten_glUseProgram(p0|0);
  41742. }
  41743. function _emscripten_glValidateProgram__wrapper(p0) {
  41744. p0 = p0|0; _emscripten_glValidateProgram(p0|0);
  41745. }
  41746. function _emscripten_glDeleteObjectARB__wrapper(p0) {
  41747. p0 = p0|0; _emscripten_glDeleteObjectARB(p0|0);
  41748. }
  41749. function _emscripten_glEnableClientState__wrapper(p0) {
  41750. p0 = p0|0; _emscripten_glEnableClientState(p0|0);
  41751. }
  41752. function _emscripten_glClientActiveTexture__wrapper(p0) {
  41753. p0 = p0|0; _emscripten_glClientActiveTexture(p0|0);
  41754. }
  41755. function _emscripten_glBindVertexArray__wrapper(p0) {
  41756. p0 = p0|0; _emscripten_glBindVertexArray(p0|0);
  41757. }
  41758. function _emscripten_glMatrixMode__wrapper(p0) {
  41759. p0 = p0|0; _emscripten_glMatrixMode(p0|0);
  41760. }
  41761. function _emscripten_glLoadMatrixf__wrapper(p0) {
  41762. p0 = p0|0; _emscripten_glLoadMatrixf(p0|0);
  41763. }
  41764. function _emscripten_glEnableVertexAttribArray__wrapper(p0) {
  41765. p0 = p0|0; _emscripten_glEnableVertexAttribArray(p0|0);
  41766. }
  41767. function _emscripten_glDisableVertexAttribArray__wrapper(p0) {
  41768. p0 = p0|0; _emscripten_glDisableVertexAttribArray(p0|0);
  41769. }
  41770. function _emscripten_glDepthFunc__wrapper(p0) {
  41771. p0 = p0|0; _emscripten_glDepthFunc(p0|0);
  41772. }
  41773. function _emscripten_glEnable__wrapper(p0) {
  41774. p0 = p0|0; _emscripten_glEnable(p0|0);
  41775. }
  41776. function _emscripten_glDisable__wrapper(p0) {
  41777. p0 = p0|0; _emscripten_glDisable(p0|0);
  41778. }
  41779. function _emscripten_glFrontFace__wrapper(p0) {
  41780. p0 = p0|0; _emscripten_glFrontFace(p0|0);
  41781. }
  41782. function _emscripten_glCullFace__wrapper(p0) {
  41783. p0 = p0|0; _emscripten_glCullFace(p0|0);
  41784. }
  41785. function _emscripten_glClear__wrapper(p0) {
  41786. p0 = p0|0; _emscripten_glClear(p0|0);
  41787. }
  41788. function _emscripten_glClearStencil__wrapper(p0) {
  41789. p0 = p0|0; _emscripten_glClearStencil(p0|0);
  41790. }
  41791. function _emscripten_glDepthMask__wrapper(p0) {
  41792. p0 = p0|0; _emscripten_glDepthMask(p0|0);
  41793. }
  41794. function _emscripten_glStencilMask__wrapper(p0) {
  41795. p0 = p0|0; _emscripten_glStencilMask(p0|0);
  41796. }
  41797. function _emscripten_glGenerateMipmap__wrapper(p0) {
  41798. p0 = p0|0; _emscripten_glGenerateMipmap(p0|0);
  41799. }
  41800. function _emscripten_glActiveTexture__wrapper(p0) {
  41801. p0 = p0|0; _emscripten_glActiveTexture(p0|0);
  41802. }
  41803. function _emscripten_glBlendEquation__wrapper(p0) {
  41804. p0 = p0|0; _emscripten_glBlendEquation(p0|0);
  41805. }
  41806. function b4(p0,p1) {
  41807. p0 = p0|0;p1 = p1|0; nullFunc_vii(4);
  41808. }
  41809. function _emscripten_glPixelStorei__wrapper(p0,p1) {
  41810. p0 = p0|0;p1 = p1|0; _emscripten_glPixelStorei(p0|0,p1|0);
  41811. }
  41812. function _emscripten_glGetIntegerv__wrapper(p0,p1) {
  41813. p0 = p0|0;p1 = p1|0; _emscripten_glGetIntegerv(p0|0,p1|0);
  41814. }
  41815. function _emscripten_glGetFloatv__wrapper(p0,p1) {
  41816. p0 = p0|0;p1 = p1|0; _emscripten_glGetFloatv(p0|0,p1|0);
  41817. }
  41818. function _emscripten_glGetBooleanv__wrapper(p0,p1) {
  41819. p0 = p0|0;p1 = p1|0; _emscripten_glGetBooleanv(p0|0,p1|0);
  41820. }
  41821. function _emscripten_glGenTextures__wrapper(p0,p1) {
  41822. p0 = p0|0;p1 = p1|0; _emscripten_glGenTextures(p0|0,p1|0);
  41823. }
  41824. function _emscripten_glDeleteTextures__wrapper(p0,p1) {
  41825. p0 = p0|0;p1 = p1|0; _emscripten_glDeleteTextures(p0|0,p1|0);
  41826. }
  41827. function _emscripten_glBindTexture__wrapper(p0,p1) {
  41828. p0 = p0|0;p1 = p1|0; _emscripten_glBindTexture(p0|0,p1|0);
  41829. }
  41830. function _emscripten_glGenBuffers__wrapper(p0,p1) {
  41831. p0 = p0|0;p1 = p1|0; _emscripten_glGenBuffers(p0|0,p1|0);
  41832. }
  41833. function _emscripten_glDeleteBuffers__wrapper(p0,p1) {
  41834. p0 = p0|0;p1 = p1|0; _emscripten_glDeleteBuffers(p0|0,p1|0);
  41835. }
  41836. function _emscripten_glGenRenderbuffers__wrapper(p0,p1) {
  41837. p0 = p0|0;p1 = p1|0; _emscripten_glGenRenderbuffers(p0|0,p1|0);
  41838. }
  41839. function _emscripten_glDeleteRenderbuffers__wrapper(p0,p1) {
  41840. p0 = p0|0;p1 = p1|0; _emscripten_glDeleteRenderbuffers(p0|0,p1|0);
  41841. }
  41842. function _emscripten_glBindRenderbuffer__wrapper(p0,p1) {
  41843. p0 = p0|0;p1 = p1|0; _emscripten_glBindRenderbuffer(p0|0,p1|0);
  41844. }
  41845. function _emscripten_glUniform1i__wrapper(p0,p1) {
  41846. p0 = p0|0;p1 = p1|0; _emscripten_glUniform1i(p0|0,p1|0);
  41847. }
  41848. function _emscripten_glBindBuffer__wrapper(p0,p1) {
  41849. p0 = p0|0;p1 = p1|0; _emscripten_glBindBuffer(p0|0,p1|0);
  41850. }
  41851. function _emscripten_glVertexAttrib1fv__wrapper(p0,p1) {
  41852. p0 = p0|0;p1 = p1|0; _emscripten_glVertexAttrib1fv(p0|0,p1|0);
  41853. }
  41854. function _emscripten_glVertexAttrib2fv__wrapper(p0,p1) {
  41855. p0 = p0|0;p1 = p1|0; _emscripten_glVertexAttrib2fv(p0|0,p1|0);
  41856. }
  41857. function _emscripten_glVertexAttrib3fv__wrapper(p0,p1) {
  41858. p0 = p0|0;p1 = p1|0; _emscripten_glVertexAttrib3fv(p0|0,p1|0);
  41859. }
  41860. function _emscripten_glVertexAttrib4fv__wrapper(p0,p1) {
  41861. p0 = p0|0;p1 = p1|0; _emscripten_glVertexAttrib4fv(p0|0,p1|0);
  41862. }
  41863. function _emscripten_glAttachShader__wrapper(p0,p1) {
  41864. p0 = p0|0;p1 = p1|0; _emscripten_glAttachShader(p0|0,p1|0);
  41865. }
  41866. function _emscripten_glDetachShader__wrapper(p0,p1) {
  41867. p0 = p0|0;p1 = p1|0; _emscripten_glDetachShader(p0|0,p1|0);
  41868. }
  41869. function _emscripten_glBindFramebuffer__wrapper(p0,p1) {
  41870. p0 = p0|0;p1 = p1|0; _emscripten_glBindFramebuffer(p0|0,p1|0);
  41871. }
  41872. function _emscripten_glGenFramebuffers__wrapper(p0,p1) {
  41873. p0 = p0|0;p1 = p1|0; _emscripten_glGenFramebuffers(p0|0,p1|0);
  41874. }
  41875. function _emscripten_glDeleteFramebuffers__wrapper(p0,p1) {
  41876. p0 = p0|0;p1 = p1|0; _emscripten_glDeleteFramebuffers(p0|0,p1|0);
  41877. }
  41878. function _emscripten_glBindProgramARB__wrapper(p0,p1) {
  41879. p0 = p0|0;p1 = p1|0; _emscripten_glBindProgramARB(p0|0,p1|0);
  41880. }
  41881. function _emscripten_glGetPointerv__wrapper(p0,p1) {
  41882. p0 = p0|0;p1 = p1|0; _emscripten_glGetPointerv(p0|0,p1|0);
  41883. }
  41884. function _emscripten_glGenVertexArrays__wrapper(p0,p1) {
  41885. p0 = p0|0;p1 = p1|0; _emscripten_glGenVertexArrays(p0|0,p1|0);
  41886. }
  41887. function _emscripten_glDeleteVertexArrays__wrapper(p0,p1) {
  41888. p0 = p0|0;p1 = p1|0; _emscripten_glDeleteVertexArrays(p0|0,p1|0);
  41889. }
  41890. function _emscripten_glVertexAttribDivisor__wrapper(p0,p1) {
  41891. p0 = p0|0;p1 = p1|0; _emscripten_glVertexAttribDivisor(p0|0,p1|0);
  41892. }
  41893. function _emscripten_glBlendFunc__wrapper(p0,p1) {
  41894. p0 = p0|0;p1 = p1|0; _emscripten_glBlendFunc(p0|0,p1|0);
  41895. }
  41896. function _emscripten_glBlendEquationSeparate__wrapper(p0,p1) {
  41897. p0 = p0|0;p1 = p1|0; _emscripten_glBlendEquationSeparate(p0|0,p1|0);
  41898. }
  41899. function _emscripten_glStencilMaskSeparate__wrapper(p0,p1) {
  41900. p0 = p0|0;p1 = p1|0; _emscripten_glStencilMaskSeparate(p0|0,p1|0);
  41901. }
  41902. function _emscripten_glHint__wrapper(p0,p1) {
  41903. p0 = p0|0;p1 = p1|0; _emscripten_glHint(p0|0,p1|0);
  41904. }
  41905. function _emscripten_glDrawBuffers__wrapper(p0,p1) {
  41906. p0 = p0|0;p1 = p1|0; _emscripten_glDrawBuffers(p0|0,p1|0);
  41907. }
  41908. function b5(p0) {
  41909. p0 = p0|0; nullFunc_ii(5);return 0;
  41910. }
  41911. function _emscripten_glGetString__wrapper(p0) {
  41912. p0 = p0|0; return _emscripten_glGetString(p0|0)|0;
  41913. }
  41914. function _emscripten_glIsTexture__wrapper(p0) {
  41915. p0 = p0|0; return _emscripten_glIsTexture(p0|0)|0;
  41916. }
  41917. function _emscripten_glIsBuffer__wrapper(p0) {
  41918. p0 = p0|0; return _emscripten_glIsBuffer(p0|0)|0;
  41919. }
  41920. function _emscripten_glIsRenderbuffer__wrapper(p0) {
  41921. p0 = p0|0; return _emscripten_glIsRenderbuffer(p0|0)|0;
  41922. }
  41923. function _emscripten_glCreateShader__wrapper(p0) {
  41924. p0 = p0|0; return _emscripten_glCreateShader(p0|0)|0;
  41925. }
  41926. function _emscripten_glIsShader__wrapper(p0) {
  41927. p0 = p0|0; return _emscripten_glIsShader(p0|0)|0;
  41928. }
  41929. function _emscripten_glIsProgram__wrapper(p0) {
  41930. p0 = p0|0; return _emscripten_glIsProgram(p0|0)|0;
  41931. }
  41932. function _emscripten_glIsFramebuffer__wrapper(p0) {
  41933. p0 = p0|0; return _emscripten_glIsFramebuffer(p0|0)|0;
  41934. }
  41935. function _emscripten_glCheckFramebufferStatus__wrapper(p0) {
  41936. p0 = p0|0; return _emscripten_glCheckFramebufferStatus(p0|0)|0;
  41937. }
  41938. function _emscripten_glIsEnabled__wrapper(p0) {
  41939. p0 = p0|0; return _emscripten_glIsEnabled(p0|0)|0;
  41940. }
  41941. function b6(p0,p1,p2,p3) {
  41942. p0 = p0|0;p1 = +p1;p2 = +p2;p3 = +p3; nullFunc_viddd(6);
  41943. }
  41944. function _emscripten_glUniform3f__wrapper(p0,p1,p2,p3) {
  41945. p0 = p0|0;p1 = +p1;p2 = +p2;p3 = +p3; _emscripten_glUniform3f(p0|0,+p1,+p2,+p3);
  41946. }
  41947. function _emscripten_glVertexAttrib3f__wrapper(p0,p1,p2,p3) {
  41948. p0 = p0|0;p1 = +p1;p2 = +p2;p3 = +p3; _emscripten_glVertexAttrib3f(p0|0,+p1,+p2,+p3);
  41949. }
  41950. function b7(p0,p1,p2) {
  41951. p0 = p0|0;p1 = +p1;p2 = +p2; nullFunc_vidd(7);
  41952. }
  41953. function _emscripten_glUniform2f__wrapper(p0,p1,p2) {
  41954. p0 = p0|0;p1 = +p1;p2 = +p2; _emscripten_glUniform2f(p0|0,+p1,+p2);
  41955. }
  41956. function _emscripten_glVertexAttrib2f__wrapper(p0,p1,p2) {
  41957. p0 = p0|0;p1 = +p1;p2 = +p2; _emscripten_glVertexAttrib2f(p0|0,+p1,+p2);
  41958. }
  41959. function b8(p0,p1,p2) {
  41960. p0 = p0|0;p1 = p1|0;p2 = p2|0; nullFunc_iiii(8);return 0;
  41961. }
  41962. function b9(p0,p1,p2,p3,p4,p5,p6,p7) {
  41963. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0; nullFunc_viiiiiiii(9);
  41964. }
  41965. function _emscripten_glCompressedTexImage2D__wrapper(p0,p1,p2,p3,p4,p5,p6,p7) {
  41966. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0; _emscripten_glCompressedTexImage2D(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0,p7|0);
  41967. }
  41968. function _emscripten_glCopyTexImage2D__wrapper(p0,p1,p2,p3,p4,p5,p6,p7) {
  41969. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0; _emscripten_glCopyTexImage2D(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0,p7|0);
  41970. }
  41971. function _emscripten_glCopyTexSubImage2D__wrapper(p0,p1,p2,p3,p4,p5,p6,p7) {
  41972. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0; _emscripten_glCopyTexSubImage2D(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0,p7|0);
  41973. }
  41974. function b10(p0,p1,p2,p3,p4,p5) {
  41975. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0; nullFunc_viiiiii(10);
  41976. }
  41977. function _emscripten_glDrawRangeElements__wrapper(p0,p1,p2,p3,p4,p5) {
  41978. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0; _emscripten_glDrawRangeElements(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0);
  41979. }
  41980. function _emscripten_glVertexAttribPointer__wrapper(p0,p1,p2,p3,p4,p5) {
  41981. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0; _emscripten_glVertexAttribPointer(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0);
  41982. }
  41983. function b11(p0,p1) {
  41984. p0 = +p0;p1 = +p1; nullFunc_vdd(11);
  41985. }
  41986. function _emscripten_glDepthRange__wrapper(p0,p1) {
  41987. p0 = +p0;p1 = +p1; _emscripten_glDepthRange(+p0,+p1);
  41988. }
  41989. function _emscripten_glDepthRangef__wrapper(p0,p1) {
  41990. p0 = +p0;p1 = +p1; _emscripten_glDepthRangef(+p0,+p1);
  41991. }
  41992. function _emscripten_glPolygonOffset__wrapper(p0,p1) {
  41993. p0 = +p0;p1 = +p1; _emscripten_glPolygonOffset(+p0,+p1);
  41994. }
  41995. function b12(p0) {
  41996. p0 = +p0; nullFunc_dd(12);return +0;
  41997. }
  41998. function b13(p0,p1,p2,p3,p4) {
  41999. p0 = p0|0;p1 = +p1;p2 = +p2;p3 = +p3;p4 = +p4; nullFunc_vidddd(13);
  42000. }
  42001. function _emscripten_glUniform4f__wrapper(p0,p1,p2,p3,p4) {
  42002. p0 = p0|0;p1 = +p1;p2 = +p2;p3 = +p3;p4 = +p4; _emscripten_glUniform4f(p0|0,+p1,+p2,+p3,+p4);
  42003. }
  42004. function _emscripten_glVertexAttrib4f__wrapper(p0,p1,p2,p3,p4) {
  42005. p0 = p0|0;p1 = +p1;p2 = +p2;p3 = +p3;p4 = +p4; _emscripten_glVertexAttrib4f(p0|0,+p1,+p2,+p3,+p4);
  42006. }
  42007. function b14(p0,p1) {
  42008. p0 = +p0;p1 = p1|0; nullFunc_vdi(14);
  42009. }
  42010. function _emscripten_glSampleCoverage__wrapper(p0,p1) {
  42011. p0 = +p0;p1 = p1|0; _emscripten_glSampleCoverage(+p0,p1|0);
  42012. }
  42013. function b15(p0,p1,p2,p3,p4,p5,p6) {
  42014. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0; nullFunc_viiiiiii(15);
  42015. }
  42016. function _emscripten_glReadPixels__wrapper(p0,p1,p2,p3,p4,p5,p6) {
  42017. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0; _emscripten_glReadPixels(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0);
  42018. }
  42019. function _emscripten_glGetActiveUniform__wrapper(p0,p1,p2,p3,p4,p5,p6) {
  42020. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0; _emscripten_glGetActiveUniform(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0);
  42021. }
  42022. function _emscripten_glGetActiveAttrib__wrapper(p0,p1,p2,p3,p4,p5,p6) {
  42023. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0; _emscripten_glGetActiveAttrib(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0);
  42024. }
  42025. function b16(p0,p1,p2,p3,p4,p5,p6,p7,p8) {
  42026. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0;p8 = p8|0; nullFunc_viiiiiiiii(16);
  42027. }
  42028. function _emscripten_glCompressedTexSubImage2D__wrapper(p0,p1,p2,p3,p4,p5,p6,p7,p8) {
  42029. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0;p8 = p8|0; _emscripten_glCompressedTexSubImage2D(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0,p7|0,p8|0);
  42030. }
  42031. function _emscripten_glTexImage2D__wrapper(p0,p1,p2,p3,p4,p5,p6,p7,p8) {
  42032. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0;p8 = p8|0; _emscripten_glTexImage2D(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0,p7|0,p8|0);
  42033. }
  42034. function _emscripten_glTexSubImage2D__wrapper(p0,p1,p2,p3,p4,p5,p6,p7,p8) {
  42035. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0;p4 = p4|0;p5 = p5|0;p6 = p6|0;p7 = p7|0;p8 = p8|0; _emscripten_glTexSubImage2D(p0|0,p1|0,p2|0,p3|0,p4|0,p5|0,p6|0,p7|0,p8|0);
  42036. }
  42037. function b17(p0,p1) {
  42038. p0 = p0|0;p1 = p1|0; nullFunc_iii(17);return 0;
  42039. }
  42040. function _emscripten_glGetUniformLocation__wrapper(p0,p1) {
  42041. p0 = p0|0;p1 = p1|0; return _emscripten_glGetUniformLocation(p0|0,p1|0)|0;
  42042. }
  42043. function _emscripten_glGetAttribLocation__wrapper(p0,p1) {
  42044. p0 = p0|0;p1 = p1|0; return _emscripten_glGetAttribLocation(p0|0,p1|0)|0;
  42045. }
  42046. function b18() {
  42047. ; nullFunc_i(18);return 0;
  42048. }
  42049. function _emscripten_glCreateProgram__wrapper() {
  42050. ; return _emscripten_glCreateProgram()|0;
  42051. }
  42052. function _emscripten_glGetError__wrapper() {
  42053. ; return _emscripten_glGetError()|0;
  42054. }
  42055. function b19(p0,p1,p2,p3,p4,p5) {
  42056. p0 = +p0;p1 = +p1;p2 = +p2;p3 = +p3;p4 = +p4;p5 = +p5; nullFunc_vdddddd(19);
  42057. }
  42058. function _emscripten_glFrustum__wrapper(p0,p1,p2,p3,p4,p5) {
  42059. p0 = +p0;p1 = +p1;p2 = +p2;p3 = +p3;p4 = +p4;p5 = +p5; _emscripten_glFrustum(+p0,+p1,+p2,+p3,+p4,+p5);
  42060. }
  42061. function b20(p0,p1,p2,p3) {
  42062. p0 = +p0;p1 = +p1;p2 = +p2;p3 = +p3; nullFunc_vdddd(20);
  42063. }
  42064. function _emscripten_glRotatef__wrapper(p0,p1,p2,p3) {
  42065. p0 = +p0;p1 = +p1;p2 = +p2;p3 = +p3; _emscripten_glRotatef(+p0,+p1,+p2,+p3);
  42066. }
  42067. function _emscripten_glClearColor__wrapper(p0,p1,p2,p3) {
  42068. p0 = +p0;p1 = +p1;p2 = +p2;p3 = +p3; _emscripten_glClearColor(+p0,+p1,+p2,+p3);
  42069. }
  42070. function _emscripten_glBlendColor__wrapper(p0,p1,p2,p3) {
  42071. p0 = +p0;p1 = +p1;p2 = +p2;p3 = +p3; _emscripten_glBlendColor(+p0,+p1,+p2,+p3);
  42072. }
  42073. function b21(p0,p1,p2) {
  42074. p0 = p0|0;p1 = p1|0;p2 = p2|0; nullFunc_viii(21);
  42075. }
  42076. function _emscripten_glGetTexParameterfv__wrapper(p0,p1,p2) {
  42077. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetTexParameterfv(p0|0,p1|0,p2|0);
  42078. }
  42079. function _emscripten_glGetTexParameteriv__wrapper(p0,p1,p2) {
  42080. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetTexParameteriv(p0|0,p1|0,p2|0);
  42081. }
  42082. function _emscripten_glTexParameterfv__wrapper(p0,p1,p2) {
  42083. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glTexParameterfv(p0|0,p1|0,p2|0);
  42084. }
  42085. function _emscripten_glTexParameteriv__wrapper(p0,p1,p2) {
  42086. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glTexParameteriv(p0|0,p1|0,p2|0);
  42087. }
  42088. function _emscripten_glGetBufferParameteriv__wrapper(p0,p1,p2) {
  42089. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetBufferParameteriv(p0|0,p1|0,p2|0);
  42090. }
  42091. function _emscripten_glGetRenderbufferParameteriv__wrapper(p0,p1,p2) {
  42092. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetRenderbufferParameteriv(p0|0,p1|0,p2|0);
  42093. }
  42094. function _emscripten_glGetUniformfv__wrapper(p0,p1,p2) {
  42095. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetUniformfv(p0|0,p1|0,p2|0);
  42096. }
  42097. function _emscripten_glGetUniformiv__wrapper(p0,p1,p2) {
  42098. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetUniformiv(p0|0,p1|0,p2|0);
  42099. }
  42100. function _emscripten_glGetVertexAttribfv__wrapper(p0,p1,p2) {
  42101. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetVertexAttribfv(p0|0,p1|0,p2|0);
  42102. }
  42103. function _emscripten_glGetVertexAttribiv__wrapper(p0,p1,p2) {
  42104. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetVertexAttribiv(p0|0,p1|0,p2|0);
  42105. }
  42106. function _emscripten_glGetVertexAttribPointerv__wrapper(p0,p1,p2) {
  42107. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetVertexAttribPointerv(p0|0,p1|0,p2|0);
  42108. }
  42109. function _emscripten_glUniform2i__wrapper(p0,p1,p2) {
  42110. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform2i(p0|0,p1|0,p2|0);
  42111. }
  42112. function _emscripten_glUniform1iv__wrapper(p0,p1,p2) {
  42113. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform1iv(p0|0,p1|0,p2|0);
  42114. }
  42115. function _emscripten_glUniform2iv__wrapper(p0,p1,p2) {
  42116. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform2iv(p0|0,p1|0,p2|0);
  42117. }
  42118. function _emscripten_glUniform3iv__wrapper(p0,p1,p2) {
  42119. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform3iv(p0|0,p1|0,p2|0);
  42120. }
  42121. function _emscripten_glUniform4iv__wrapper(p0,p1,p2) {
  42122. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform4iv(p0|0,p1|0,p2|0);
  42123. }
  42124. function _emscripten_glUniform1fv__wrapper(p0,p1,p2) {
  42125. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform1fv(p0|0,p1|0,p2|0);
  42126. }
  42127. function _emscripten_glUniform2fv__wrapper(p0,p1,p2) {
  42128. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform2fv(p0|0,p1|0,p2|0);
  42129. }
  42130. function _emscripten_glUniform3fv__wrapper(p0,p1,p2) {
  42131. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform3fv(p0|0,p1|0,p2|0);
  42132. }
  42133. function _emscripten_glUniform4fv__wrapper(p0,p1,p2) {
  42134. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glUniform4fv(p0|0,p1|0,p2|0);
  42135. }
  42136. function _emscripten_glGetShaderiv__wrapper(p0,p1,p2) {
  42137. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetShaderiv(p0|0,p1|0,p2|0);
  42138. }
  42139. function _emscripten_glGetProgramiv__wrapper(p0,p1,p2) {
  42140. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetProgramiv(p0|0,p1|0,p2|0);
  42141. }
  42142. function _emscripten_glBindAttribLocation__wrapper(p0,p1,p2) {
  42143. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glBindAttribLocation(p0|0,p1|0,p2|0);
  42144. }
  42145. function _emscripten_glGetObjectParameterivARB__wrapper(p0,p1,p2) {
  42146. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glGetObjectParameterivARB(p0|0,p1|0,p2|0);
  42147. }
  42148. function _emscripten_glNormalPointer__wrapper(p0,p1,p2) {
  42149. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glNormalPointer(p0|0,p1|0,p2|0);
  42150. }
  42151. function _emscripten_glDrawArrays__wrapper(p0,p1,p2) {
  42152. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glDrawArrays(p0|0,p1|0,p2|0);
  42153. }
  42154. function _emscripten_glTexParameteri__wrapper(p0,p1,p2) {
  42155. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glTexParameteri(p0|0,p1|0,p2|0);
  42156. }
  42157. function _emscripten_glStencilFunc__wrapper(p0,p1,p2) {
  42158. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glStencilFunc(p0|0,p1|0,p2|0);
  42159. }
  42160. function _emscripten_glStencilOp__wrapper(p0,p1,p2) {
  42161. p0 = p0|0;p1 = p1|0;p2 = p2|0; _emscripten_glStencilOp(p0|0,p1|0,p2|0);
  42162. }
  42163. function b22() {
  42164. ; nullFunc_v(22);
  42165. }
  42166. function _emscripten_glLoadIdentity__wrapper() {
  42167. ; _emscripten_glLoadIdentity();
  42168. }
  42169. function _emscripten_glReleaseShaderCompiler__wrapper() {
  42170. ; _emscripten_glReleaseShaderCompiler();
  42171. }
  42172. function _emscripten_glFinish__wrapper() {
  42173. ; _emscripten_glFinish();
  42174. }
  42175. function _emscripten_glFlush__wrapper() {
  42176. ; _emscripten_glFlush();
  42177. }
  42178. function b23(p0,p1,p2) {
  42179. p0 = p0|0;p1 = p1|0;p2 = +p2; nullFunc_viid(23);
  42180. }
  42181. function _emscripten_glTexParameterf__wrapper(p0,p1,p2) {
  42182. p0 = p0|0;p1 = p1|0;p2 = +p2; _emscripten_glTexParameterf(p0|0,p1|0,+p2);
  42183. }
  42184. function b24(p0,p1) {
  42185. p0 = +p0;p1 = +p1; nullFunc_ddd(24);return +0;
  42186. }
  42187. function b25(p0,p1,p2,p3) {
  42188. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; nullFunc_viiii(25);
  42189. }
  42190. function _emscripten_glBufferData__wrapper(p0,p1,p2,p3) {
  42191. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glBufferData(p0|0,p1|0,p2|0,p3|0);
  42192. }
  42193. function _emscripten_glBufferSubData__wrapper(p0,p1,p2,p3) {
  42194. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glBufferSubData(p0|0,p1|0,p2|0,p3|0);
  42195. }
  42196. function _emscripten_glUniform3i__wrapper(p0,p1,p2,p3) {
  42197. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glUniform3i(p0|0,p1|0,p2|0,p3|0);
  42198. }
  42199. function _emscripten_glUniformMatrix2fv__wrapper(p0,p1,p2,p3) {
  42200. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glUniformMatrix2fv(p0|0,p1|0,p2|0,p3|0);
  42201. }
  42202. function _emscripten_glUniformMatrix3fv__wrapper(p0,p1,p2,p3) {
  42203. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glUniformMatrix3fv(p0|0,p1|0,p2|0,p3|0);
  42204. }
  42205. function _emscripten_glUniformMatrix4fv__wrapper(p0,p1,p2,p3) {
  42206. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glUniformMatrix4fv(p0|0,p1|0,p2|0,p3|0);
  42207. }
  42208. function _emscripten_glGetAttachedShaders__wrapper(p0,p1,p2,p3) {
  42209. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glGetAttachedShaders(p0|0,p1|0,p2|0,p3|0);
  42210. }
  42211. function _emscripten_glShaderSource__wrapper(p0,p1,p2,p3) {
  42212. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glShaderSource(p0|0,p1|0,p2|0,p3|0);
  42213. }
  42214. function _emscripten_glGetShaderSource__wrapper(p0,p1,p2,p3) {
  42215. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glGetShaderSource(p0|0,p1|0,p2|0,p3|0);
  42216. }
  42217. function _emscripten_glGetShaderInfoLog__wrapper(p0,p1,p2,p3) {
  42218. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glGetShaderInfoLog(p0|0,p1|0,p2|0,p3|0);
  42219. }
  42220. function _emscripten_glGetShaderPrecisionFormat__wrapper(p0,p1,p2,p3) {
  42221. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glGetShaderPrecisionFormat(p0|0,p1|0,p2|0,p3|0);
  42222. }
  42223. function _emscripten_glGetProgramInfoLog__wrapper(p0,p1,p2,p3) {
  42224. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glGetProgramInfoLog(p0|0,p1|0,p2|0,p3|0);
  42225. }
  42226. function _emscripten_glFramebufferRenderbuffer__wrapper(p0,p1,p2,p3) {
  42227. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glFramebufferRenderbuffer(p0|0,p1|0,p2|0,p3|0);
  42228. }
  42229. function _emscripten_glGetFramebufferAttachmentParameteriv__wrapper(p0,p1,p2,p3) {
  42230. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glGetFramebufferAttachmentParameteriv(p0|0,p1|0,p2|0,p3|0);
  42231. }
  42232. function _emscripten_glGetInfoLogARB__wrapper(p0,p1,p2,p3) {
  42233. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glGetInfoLogARB(p0|0,p1|0,p2|0,p3|0);
  42234. }
  42235. function _emscripten_glVertexPointer__wrapper(p0,p1,p2,p3) {
  42236. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glVertexPointer(p0|0,p1|0,p2|0,p3|0);
  42237. }
  42238. function _emscripten_glTexCoordPointer__wrapper(p0,p1,p2,p3) {
  42239. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glTexCoordPointer(p0|0,p1|0,p2|0,p3|0);
  42240. }
  42241. function _emscripten_glColorPointer__wrapper(p0,p1,p2,p3) {
  42242. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glColorPointer(p0|0,p1|0,p2|0,p3|0);
  42243. }
  42244. function _emscripten_glDrawElements__wrapper(p0,p1,p2,p3) {
  42245. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glDrawElements(p0|0,p1|0,p2|0,p3|0);
  42246. }
  42247. function _emscripten_glDrawArraysInstanced__wrapper(p0,p1,p2,p3) {
  42248. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glDrawArraysInstanced(p0|0,p1|0,p2|0,p3|0);
  42249. }
  42250. function _emscripten_glViewport__wrapper(p0,p1,p2,p3) {
  42251. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glViewport(p0|0,p1|0,p2|0,p3|0);
  42252. }
  42253. function _emscripten_glScissor__wrapper(p0,p1,p2,p3) {
  42254. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glScissor(p0|0,p1|0,p2|0,p3|0);
  42255. }
  42256. function _emscripten_glColorMask__wrapper(p0,p1,p2,p3) {
  42257. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glColorMask(p0|0,p1|0,p2|0,p3|0);
  42258. }
  42259. function _emscripten_glRenderbufferStorage__wrapper(p0,p1,p2,p3) {
  42260. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glRenderbufferStorage(p0|0,p1|0,p2|0,p3|0);
  42261. }
  42262. function _emscripten_glBlendFuncSeparate__wrapper(p0,p1,p2,p3) {
  42263. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glBlendFuncSeparate(p0|0,p1|0,p2|0,p3|0);
  42264. }
  42265. function _emscripten_glStencilFuncSeparate__wrapper(p0,p1,p2,p3) {
  42266. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glStencilFuncSeparate(p0|0,p1|0,p2|0,p3|0);
  42267. }
  42268. function _emscripten_glStencilOpSeparate__wrapper(p0,p1,p2,p3) {
  42269. p0 = p0|0;p1 = p1|0;p2 = p2|0;p3 = p3|0; _emscripten_glStencilOpSeparate(p0|0,p1|0,p2|0,p3|0);
  42270. }
  42271. // EMSCRIPTEN_END_FUNCS
  42272. var FUNCTION_TABLE_viiiii = [b0,_KeyCallback,_emscripten_glUniform4i__wrapper,_emscripten_glFramebufferTexture2D__wrapper,_emscripten_glShaderBinary__wrapper,_emscripten_glDrawElementsInstanced__wrapper,b0,b0];
  42273. var FUNCTION_TABLE_vd = [b1,_emscripten_glClearDepth__wrapper,_emscripten_glClearDepthf__wrapper,_emscripten_glLineWidth__wrapper];
  42274. var FUNCTION_TABLE_vid = [b2,_emscripten_glUniform1f__wrapper,_emscripten_glVertexAttrib1f__wrapper,b2];
  42275. var FUNCTION_TABLE_vi = [b3,_emscripten_glDeleteShader__wrapper,_emscripten_glCompileShader__wrapper,_emscripten_glDeleteProgram__wrapper,_emscripten_glLinkProgram__wrapper,_emscripten_glUseProgram__wrapper,_emscripten_glValidateProgram__wrapper,_emscripten_glDeleteObjectARB__wrapper,_emscripten_glEnableClientState__wrapper,_emscripten_glClientActiveTexture__wrapper,_emscripten_glBindVertexArray__wrapper,_emscripten_glMatrixMode__wrapper,_emscripten_glLoadMatrixf__wrapper,_emscripten_glEnableVertexAttribArray__wrapper,_emscripten_glDisableVertexAttribArray__wrapper,_emscripten_glDepthFunc__wrapper,_emscripten_glEnable__wrapper,_emscripten_glDisable__wrapper,_emscripten_glFrontFace__wrapper,_emscripten_glCullFace__wrapper,_emscripten_glClear__wrapper,_emscripten_glClearStencil__wrapper,_emscripten_glDepthMask__wrapper,_emscripten_glStencilMask__wrapper,_emscripten_glGenerateMipmap__wrapper,_emscripten_glActiveTexture__wrapper,_emscripten_glBlendEquation__wrapper,b3,b3
  42276. ,b3,b3,b3];
  42277. var FUNCTION_TABLE_vii = [b4,_stbi__stdio_skip,_ErrorCallback,_CursorEnterCallback,_CharCallback,_WindowIconifyCallback,_emscripten_glPixelStorei__wrapper,_emscripten_glGetIntegerv__wrapper,_emscripten_glGetFloatv__wrapper,_emscripten_glGetBooleanv__wrapper,_emscripten_glGenTextures__wrapper,_emscripten_glDeleteTextures__wrapper,_emscripten_glBindTexture__wrapper,_emscripten_glGenBuffers__wrapper,_emscripten_glDeleteBuffers__wrapper,_emscripten_glGenRenderbuffers__wrapper,_emscripten_glDeleteRenderbuffers__wrapper,_emscripten_glBindRenderbuffer__wrapper,_emscripten_glUniform1i__wrapper,_emscripten_glBindBuffer__wrapper,_emscripten_glVertexAttrib1fv__wrapper,_emscripten_glVertexAttrib2fv__wrapper,_emscripten_glVertexAttrib3fv__wrapper,_emscripten_glVertexAttrib4fv__wrapper,_emscripten_glAttachShader__wrapper,_emscripten_glDetachShader__wrapper,_emscripten_glBindFramebuffer__wrapper,_emscripten_glGenFramebuffers__wrapper,_emscripten_glDeleteFramebuffers__wrapper,_emscripten_glBindProgramARB__wrapper,_emscripten_glGetPointerv__wrapper,_emscripten_glGenVertexArrays__wrapper,_emscripten_glDeleteVertexArrays__wrapper,_emscripten_glVertexAttribDivisor__wrapper,_emscripten_glBlendFunc__wrapper,_emscripten_glBlendEquationSeparate__wrapper,_emscripten_glStencilMaskSeparate__wrapper,_emscripten_glHint__wrapper,_emscripten_glDrawBuffers__wrapper,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4
  42278. ,b4,b4,b4,b4,b4];
  42279. var FUNCTION_TABLE_ii = [b5,_stbi__stdio_eof,___stdio_close,_emscripten_glGetString__wrapper,_emscripten_glIsTexture__wrapper,_emscripten_glIsBuffer__wrapper,_emscripten_glIsRenderbuffer__wrapper,_emscripten_glCreateShader__wrapper,_emscripten_glIsShader__wrapper,_emscripten_glIsProgram__wrapper,_emscripten_glIsFramebuffer__wrapper,_emscripten_glCheckFramebufferStatus__wrapper,_emscripten_glIsEnabled__wrapper,b5,b5,b5];
  42280. var FUNCTION_TABLE_viddd = [b6,_emscripten_glUniform3f__wrapper,_emscripten_glVertexAttrib3f__wrapper,b6];
  42281. var FUNCTION_TABLE_vidd = [b7,_MouseCursorPosCallback,_ScrollCallback,_emscripten_glUniform2f__wrapper,_emscripten_glVertexAttrib2f__wrapper,b7,b7,b7];
  42282. var FUNCTION_TABLE_iiii = [b8,_stbi__stdio_read,___stdout_write,___stdio_seek,_EmscriptenFullscreenChangeCallback,_EmscriptenKeyboardCallback,_EmscriptenMouseCallback,_EmscriptenTouchCallback,_EmscriptenGamepadCallback,___stdio_write,___stdio_read,b8,b8,b8,b8,b8];
  42283. var FUNCTION_TABLE_viiiiiiii = [b9,_emscripten_glCompressedTexImage2D__wrapper,_emscripten_glCopyTexImage2D__wrapper,_emscripten_glCopyTexSubImage2D__wrapper];
  42284. var FUNCTION_TABLE_viiiiii = [b10,_emscripten_glDrawRangeElements__wrapper,_emscripten_glVertexAttribPointer__wrapper,b10];
  42285. var FUNCTION_TABLE_vdd = [b11,_emscripten_glDepthRange__wrapper,_emscripten_glDepthRangef__wrapper,_emscripten_glPolygonOffset__wrapper];
  42286. var FUNCTION_TABLE_dd = [b12,_stbir__support_zero,_stbir__support_trapezoid,_stbir__support_one,_stbir__support_two,b12,b12,b12];
  42287. var FUNCTION_TABLE_vidddd = [b13,_emscripten_glUniform4f__wrapper,_emscripten_glVertexAttrib4f__wrapper,b13];
  42288. var FUNCTION_TABLE_vdi = [b14,_emscripten_glSampleCoverage__wrapper];
  42289. var FUNCTION_TABLE_viiiiiii = [b15,_emscripten_glReadPixels__wrapper,_emscripten_glGetActiveUniform__wrapper,_emscripten_glGetActiveAttrib__wrapper];
  42290. var FUNCTION_TABLE_viiiiiiiii = [b16,_emscripten_glCompressedTexSubImage2D__wrapper,_emscripten_glTexImage2D__wrapper,_emscripten_glTexSubImage2D__wrapper];
  42291. var FUNCTION_TABLE_iii = [b17,_emscripten_glGetUniformLocation__wrapper,_emscripten_glGetAttribLocation__wrapper,b17];
  42292. var FUNCTION_TABLE_i = [b18,_emscripten_glCreateProgram__wrapper,_emscripten_glGetError__wrapper,b18];
  42293. var FUNCTION_TABLE_vdddddd = [b19,_emscripten_glFrustum__wrapper];
  42294. var FUNCTION_TABLE_vdddd = [b20,_emscripten_glRotatef__wrapper,_emscripten_glClearColor__wrapper,_emscripten_glBlendColor__wrapper];
  42295. var FUNCTION_TABLE_viii = [b21,_WindowSizeCallback,_emscripten_glGetTexParameterfv__wrapper,_emscripten_glGetTexParameteriv__wrapper,_emscripten_glTexParameterfv__wrapper,_emscripten_glTexParameteriv__wrapper,_emscripten_glGetBufferParameteriv__wrapper,_emscripten_glGetRenderbufferParameteriv__wrapper,_emscripten_glGetUniformfv__wrapper,_emscripten_glGetUniformiv__wrapper,_emscripten_glGetVertexAttribfv__wrapper,_emscripten_glGetVertexAttribiv__wrapper,_emscripten_glGetVertexAttribPointerv__wrapper,_emscripten_glUniform2i__wrapper,_emscripten_glUniform1iv__wrapper,_emscripten_glUniform2iv__wrapper,_emscripten_glUniform3iv__wrapper,_emscripten_glUniform4iv__wrapper,_emscripten_glUniform1fv__wrapper,_emscripten_glUniform2fv__wrapper,_emscripten_glUniform3fv__wrapper,_emscripten_glUniform4fv__wrapper,_emscripten_glGetShaderiv__wrapper,_emscripten_glGetProgramiv__wrapper,_emscripten_glBindAttribLocation__wrapper,_emscripten_glGetObjectParameterivARB__wrapper,_emscripten_glNormalPointer__wrapper,_emscripten_glDrawArrays__wrapper,_emscripten_glTexParameteri__wrapper,_emscripten_glStencilFunc__wrapper,_emscripten_glStencilOp__wrapper,b21];
  42296. var FUNCTION_TABLE_v = [b22,_UpdateDrawFrame,_emscripten_glLoadIdentity__wrapper,_emscripten_glReleaseShaderCompiler__wrapper,_emscripten_glFinish__wrapper,_emscripten_glFlush__wrapper,b22,b22];
  42297. var FUNCTION_TABLE_viid = [b23,_emscripten_glTexParameterf__wrapper];
  42298. var FUNCTION_TABLE_ddd = [b24,_stbir__filter_trapezoid,_stbir__filter_triangle,_stbir__filter_cubic,_stbir__filter_catmullrom,_stbir__filter_mitchell,b24,b24];
  42299. var FUNCTION_TABLE_viiii = [b25,_MouseButtonCallback,_emscripten_glBufferData__wrapper,_emscripten_glBufferSubData__wrapper,_emscripten_glUniform3i__wrapper,_emscripten_glUniformMatrix2fv__wrapper,_emscripten_glUniformMatrix3fv__wrapper,_emscripten_glUniformMatrix4fv__wrapper,_emscripten_glGetAttachedShaders__wrapper,_emscripten_glShaderSource__wrapper,_emscripten_glGetShaderSource__wrapper,_emscripten_glGetShaderInfoLog__wrapper,_emscripten_glGetShaderPrecisionFormat__wrapper,_emscripten_glGetProgramInfoLog__wrapper,_emscripten_glFramebufferRenderbuffer__wrapper,_emscripten_glGetFramebufferAttachmentParameteriv__wrapper,_emscripten_glGetInfoLogARB__wrapper,_emscripten_glVertexPointer__wrapper,_emscripten_glTexCoordPointer__wrapper,_emscripten_glColorPointer__wrapper,_emscripten_glDrawElements__wrapper,_emscripten_glDrawArraysInstanced__wrapper,_emscripten_glViewport__wrapper,_emscripten_glScissor__wrapper,_emscripten_glColorMask__wrapper,_emscripten_glRenderbufferStorage__wrapper,_emscripten_glBlendFuncSeparate__wrapper,_emscripten_glStencilFuncSeparate__wrapper,_emscripten_glStencilOpSeparate__wrapper,b25,b25,b25];
  42300. return { _roundf: _roundf, _main: _main, _llvm_cttz_i32: _llvm_cttz_i32, _bitshift64Lshr: _bitshift64Lshr, _bitshift64Shl: _bitshift64Shl, _fflush: _fflush, _memset: _memset, _sbrk: _sbrk, _memcpy: _memcpy, ___errno_location: ___errno_location, ___uremdi3: ___uremdi3, _i64Subtract: _i64Subtract, ___udivmoddi4: ___udivmoddi4, _i64Add: _i64Add, _emscripten_get_global_libc: _emscripten_get_global_libc, _emscripten_GetProcAddress: _emscripten_GetProcAddress, ___udivdi3: ___udivdi3, _llvm_bswap_i32: _llvm_bswap_i32, _free: _free, _memmove: _memmove, _strstr: _strstr, _malloc: _malloc, runPostSets: runPostSets, stackAlloc: stackAlloc, stackSave: stackSave, stackRestore: stackRestore, establishStackSpace: establishStackSpace, setTempRet0: setTempRet0, getTempRet0: getTempRet0, setThrew: setThrew, stackAlloc: stackAlloc, stackSave: stackSave, stackRestore: stackRestore, establishStackSpace: establishStackSpace, setThrew: setThrew, setTempRet0: setTempRet0, getTempRet0: getTempRet0, dynCall_viiiii: dynCall_viiiii, dynCall_vd: dynCall_vd, dynCall_vid: dynCall_vid, dynCall_vi: dynCall_vi, dynCall_vii: dynCall_vii, dynCall_ii: dynCall_ii, dynCall_viddd: dynCall_viddd, dynCall_vidd: dynCall_vidd, dynCall_iiii: dynCall_iiii, dynCall_viiiiiiii: dynCall_viiiiiiii, dynCall_viiiiii: dynCall_viiiiii, dynCall_vdd: dynCall_vdd, dynCall_dd: dynCall_dd, dynCall_vidddd: dynCall_vidddd, dynCall_vdi: dynCall_vdi, dynCall_viiiiiii: dynCall_viiiiiii, dynCall_viiiiiiiii: dynCall_viiiiiiiii, dynCall_iii: dynCall_iii, dynCall_i: dynCall_i, dynCall_vdddddd: dynCall_vdddddd, dynCall_vdddd: dynCall_vdddd, dynCall_viii: dynCall_viii, dynCall_v: dynCall_v, dynCall_viid: dynCall_viid, dynCall_ddd: dynCall_ddd, dynCall_viiii: dynCall_viiii };
  42301. })
  42302. // EMSCRIPTEN_END_ASM
  42303. (Module.asmGlobalArg, Module.asmLibraryArg, buffer);
  42304. var real__roundf = asm["_roundf"]; asm["_roundf"] = function() {
  42305. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42306. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42307. return real__roundf.apply(null, arguments);
  42308. };
  42309. var real__main = asm["_main"]; asm["_main"] = function() {
  42310. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42311. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42312. return real__main.apply(null, arguments);
  42313. };
  42314. var real_stackSave = asm["stackSave"]; asm["stackSave"] = function() {
  42315. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42316. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42317. return real_stackSave.apply(null, arguments);
  42318. };
  42319. var real_getTempRet0 = asm["getTempRet0"]; asm["getTempRet0"] = function() {
  42320. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42321. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42322. return real_getTempRet0.apply(null, arguments);
  42323. };
  42324. var real_setThrew = asm["setThrew"]; asm["setThrew"] = function() {
  42325. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42326. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42327. return real_setThrew.apply(null, arguments);
  42328. };
  42329. var real__bitshift64Lshr = asm["_bitshift64Lshr"]; asm["_bitshift64Lshr"] = function() {
  42330. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42331. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42332. return real__bitshift64Lshr.apply(null, arguments);
  42333. };
  42334. var real__bitshift64Shl = asm["_bitshift64Shl"]; asm["_bitshift64Shl"] = function() {
  42335. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42336. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42337. return real__bitshift64Shl.apply(null, arguments);
  42338. };
  42339. var real__fflush = asm["_fflush"]; asm["_fflush"] = function() {
  42340. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42341. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42342. return real__fflush.apply(null, arguments);
  42343. };
  42344. var real__llvm_cttz_i32 = asm["_llvm_cttz_i32"]; asm["_llvm_cttz_i32"] = function() {
  42345. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42346. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42347. return real__llvm_cttz_i32.apply(null, arguments);
  42348. };
  42349. var real__sbrk = asm["_sbrk"]; asm["_sbrk"] = function() {
  42350. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42351. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42352. return real__sbrk.apply(null, arguments);
  42353. };
  42354. var real____errno_location = asm["___errno_location"]; asm["___errno_location"] = function() {
  42355. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42356. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42357. return real____errno_location.apply(null, arguments);
  42358. };
  42359. var real____uremdi3 = asm["___uremdi3"]; asm["___uremdi3"] = function() {
  42360. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42361. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42362. return real____uremdi3.apply(null, arguments);
  42363. };
  42364. var real_stackAlloc = asm["stackAlloc"]; asm["stackAlloc"] = function() {
  42365. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42366. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42367. return real_stackAlloc.apply(null, arguments);
  42368. };
  42369. var real__i64Subtract = asm["_i64Subtract"]; asm["_i64Subtract"] = function() {
  42370. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42371. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42372. return real__i64Subtract.apply(null, arguments);
  42373. };
  42374. var real____udivmoddi4 = asm["___udivmoddi4"]; asm["___udivmoddi4"] = function() {
  42375. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42376. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42377. return real____udivmoddi4.apply(null, arguments);
  42378. };
  42379. var real_setTempRet0 = asm["setTempRet0"]; asm["setTempRet0"] = function() {
  42380. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42381. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42382. return real_setTempRet0.apply(null, arguments);
  42383. };
  42384. var real__i64Add = asm["_i64Add"]; asm["_i64Add"] = function() {
  42385. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42386. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42387. return real__i64Add.apply(null, arguments);
  42388. };
  42389. var real__emscripten_get_global_libc = asm["_emscripten_get_global_libc"]; asm["_emscripten_get_global_libc"] = function() {
  42390. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42391. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42392. return real__emscripten_get_global_libc.apply(null, arguments);
  42393. };
  42394. var real__emscripten_GetProcAddress = asm["_emscripten_GetProcAddress"]; asm["_emscripten_GetProcAddress"] = function() {
  42395. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42396. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42397. return real__emscripten_GetProcAddress.apply(null, arguments);
  42398. };
  42399. var real____udivdi3 = asm["___udivdi3"]; asm["___udivdi3"] = function() {
  42400. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42401. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42402. return real____udivdi3.apply(null, arguments);
  42403. };
  42404. var real__llvm_bswap_i32 = asm["_llvm_bswap_i32"]; asm["_llvm_bswap_i32"] = function() {
  42405. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42406. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42407. return real__llvm_bswap_i32.apply(null, arguments);
  42408. };
  42409. var real__free = asm["_free"]; asm["_free"] = function() {
  42410. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42411. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42412. return real__free.apply(null, arguments);
  42413. };
  42414. var real_establishStackSpace = asm["establishStackSpace"]; asm["establishStackSpace"] = function() {
  42415. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42416. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42417. return real_establishStackSpace.apply(null, arguments);
  42418. };
  42419. var real__memmove = asm["_memmove"]; asm["_memmove"] = function() {
  42420. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42421. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42422. return real__memmove.apply(null, arguments);
  42423. };
  42424. var real__strstr = asm["_strstr"]; asm["_strstr"] = function() {
  42425. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42426. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42427. return real__strstr.apply(null, arguments);
  42428. };
  42429. var real_stackRestore = asm["stackRestore"]; asm["stackRestore"] = function() {
  42430. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42431. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42432. return real_stackRestore.apply(null, arguments);
  42433. };
  42434. var real__malloc = asm["_malloc"]; asm["_malloc"] = function() {
  42435. assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)');
  42436. assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)');
  42437. return real__malloc.apply(null, arguments);
  42438. };
  42439. var _roundf = Module["_roundf"] = asm["_roundf"];
  42440. var _main = Module["_main"] = asm["_main"];
  42441. var stackSave = Module["stackSave"] = asm["stackSave"];
  42442. var getTempRet0 = Module["getTempRet0"] = asm["getTempRet0"];
  42443. var _memset = Module["_memset"] = asm["_memset"];
  42444. var setThrew = Module["setThrew"] = asm["setThrew"];
  42445. var _bitshift64Lshr = Module["_bitshift64Lshr"] = asm["_bitshift64Lshr"];
  42446. var _bitshift64Shl = Module["_bitshift64Shl"] = asm["_bitshift64Shl"];
  42447. var _fflush = Module["_fflush"] = asm["_fflush"];
  42448. var _llvm_cttz_i32 = Module["_llvm_cttz_i32"] = asm["_llvm_cttz_i32"];
  42449. var _sbrk = Module["_sbrk"] = asm["_sbrk"];
  42450. var _memcpy = Module["_memcpy"] = asm["_memcpy"];
  42451. var ___errno_location = Module["___errno_location"] = asm["___errno_location"];
  42452. var ___uremdi3 = Module["___uremdi3"] = asm["___uremdi3"];
  42453. var stackAlloc = Module["stackAlloc"] = asm["stackAlloc"];
  42454. var _i64Subtract = Module["_i64Subtract"] = asm["_i64Subtract"];
  42455. var ___udivmoddi4 = Module["___udivmoddi4"] = asm["___udivmoddi4"];
  42456. var setTempRet0 = Module["setTempRet0"] = asm["setTempRet0"];
  42457. var _i64Add = Module["_i64Add"] = asm["_i64Add"];
  42458. var _emscripten_get_global_libc = Module["_emscripten_get_global_libc"] = asm["_emscripten_get_global_libc"];
  42459. var _emscripten_GetProcAddress = Module["_emscripten_GetProcAddress"] = asm["_emscripten_GetProcAddress"];
  42460. var ___udivdi3 = Module["___udivdi3"] = asm["___udivdi3"];
  42461. var _llvm_bswap_i32 = Module["_llvm_bswap_i32"] = asm["_llvm_bswap_i32"];
  42462. var _free = Module["_free"] = asm["_free"];
  42463. var runPostSets = Module["runPostSets"] = asm["runPostSets"];
  42464. var establishStackSpace = Module["establishStackSpace"] = asm["establishStackSpace"];
  42465. var _memmove = Module["_memmove"] = asm["_memmove"];
  42466. var _strstr = Module["_strstr"] = asm["_strstr"];
  42467. var stackRestore = Module["stackRestore"] = asm["stackRestore"];
  42468. var _malloc = Module["_malloc"] = asm["_malloc"];
  42469. var dynCall_viiiii = Module["dynCall_viiiii"] = asm["dynCall_viiiii"];
  42470. var dynCall_vd = Module["dynCall_vd"] = asm["dynCall_vd"];
  42471. var dynCall_vid = Module["dynCall_vid"] = asm["dynCall_vid"];
  42472. var dynCall_vi = Module["dynCall_vi"] = asm["dynCall_vi"];
  42473. var dynCall_vii = Module["dynCall_vii"] = asm["dynCall_vii"];
  42474. var dynCall_ii = Module["dynCall_ii"] = asm["dynCall_ii"];
  42475. var dynCall_viddd = Module["dynCall_viddd"] = asm["dynCall_viddd"];
  42476. var dynCall_vidd = Module["dynCall_vidd"] = asm["dynCall_vidd"];
  42477. var dynCall_iiii = Module["dynCall_iiii"] = asm["dynCall_iiii"];
  42478. var dynCall_viiiiiiii = Module["dynCall_viiiiiiii"] = asm["dynCall_viiiiiiii"];
  42479. var dynCall_viiiiii = Module["dynCall_viiiiii"] = asm["dynCall_viiiiii"];
  42480. var dynCall_vdd = Module["dynCall_vdd"] = asm["dynCall_vdd"];
  42481. var dynCall_dd = Module["dynCall_dd"] = asm["dynCall_dd"];
  42482. var dynCall_vidddd = Module["dynCall_vidddd"] = asm["dynCall_vidddd"];
  42483. var dynCall_vdi = Module["dynCall_vdi"] = asm["dynCall_vdi"];
  42484. var dynCall_viiiiiii = Module["dynCall_viiiiiii"] = asm["dynCall_viiiiiii"];
  42485. var dynCall_viiiiiiiii = Module["dynCall_viiiiiiiii"] = asm["dynCall_viiiiiiiii"];
  42486. var dynCall_iii = Module["dynCall_iii"] = asm["dynCall_iii"];
  42487. var dynCall_i = Module["dynCall_i"] = asm["dynCall_i"];
  42488. var dynCall_vdddddd = Module["dynCall_vdddddd"] = asm["dynCall_vdddddd"];
  42489. var dynCall_vdddd = Module["dynCall_vdddd"] = asm["dynCall_vdddd"];
  42490. var dynCall_viii = Module["dynCall_viii"] = asm["dynCall_viii"];
  42491. var dynCall_v = Module["dynCall_v"] = asm["dynCall_v"];
  42492. var dynCall_viid = Module["dynCall_viid"] = asm["dynCall_viid"];
  42493. var dynCall_ddd = Module["dynCall_ddd"] = asm["dynCall_ddd"];
  42494. var dynCall_viiii = Module["dynCall_viiii"] = asm["dynCall_viiii"];
  42495. ;
  42496. Runtime.stackAlloc = Module['stackAlloc'];
  42497. Runtime.stackSave = Module['stackSave'];
  42498. Runtime.stackRestore = Module['stackRestore'];
  42499. Runtime.establishStackSpace = Module['establishStackSpace'];
  42500. Runtime.setTempRet0 = Module['setTempRet0'];
  42501. Runtime.getTempRet0 = Module['getTempRet0'];
  42502. // === Auto-generated postamble setup entry stuff ===
  42503. Module['asm'] = asm;
  42504. function ExitStatus(status) {
  42505. this.name = "ExitStatus";
  42506. this.message = "Program terminated with exit(" + status + ")";
  42507. this.status = status;
  42508. };
  42509. ExitStatus.prototype = new Error();
  42510. ExitStatus.prototype.constructor = ExitStatus;
  42511. var initialStackTop;
  42512. var preloadStartTime = null;
  42513. var calledMain = false;
  42514. dependenciesFulfilled = function runCaller() {
  42515. // If run has never been called, and we should call run (INVOKE_RUN is true, and Module.noInitialRun is not false)
  42516. if (!Module['calledRun']) run();
  42517. if (!Module['calledRun']) dependenciesFulfilled = runCaller; // try this again later, after new deps are fulfilled
  42518. }
  42519. Module['callMain'] = Module.callMain = function callMain(args) {
  42520. assert(runDependencies == 0, 'cannot call main when async dependencies remain! (listen on __ATMAIN__)');
  42521. assert(__ATPRERUN__.length == 0, 'cannot call main when preRun functions remain to be called');
  42522. args = args || [];
  42523. ensureInitRuntime();
  42524. var argc = args.length+1;
  42525. function pad() {
  42526. for (var i = 0; i < 4-1; i++) {
  42527. argv.push(0);
  42528. }
  42529. }
  42530. var argv = [allocate(intArrayFromString(Module['thisProgram']), 'i8', ALLOC_NORMAL) ];
  42531. pad();
  42532. for (var i = 0; i < argc-1; i = i + 1) {
  42533. argv.push(allocate(intArrayFromString(args[i]), 'i8', ALLOC_NORMAL));
  42534. pad();
  42535. }
  42536. argv.push(0);
  42537. argv = allocate(argv, 'i32', ALLOC_NORMAL);
  42538. try {
  42539. var ret = Module['_main'](argc, argv, 0);
  42540. // if we're not running an evented main loop, it's time to exit
  42541. exit(ret, /* implicit = */ true);
  42542. }
  42543. catch(e) {
  42544. if (e instanceof ExitStatus) {
  42545. // exit() throws this once it's done to make sure execution
  42546. // has been stopped completely
  42547. return;
  42548. } else if (e == 'SimulateInfiniteLoop') {
  42549. // running an evented main loop, don't immediately exit
  42550. Module['noExitRuntime'] = true;
  42551. return;
  42552. } else {
  42553. var toLog = e;
  42554. if (e && typeof e === 'object' && e.stack) {
  42555. toLog = [e, e.stack];
  42556. }
  42557. Module.printErr('exception thrown: ' + toLog);
  42558. Module['quit'](1, e);
  42559. }
  42560. } finally {
  42561. calledMain = true;
  42562. }
  42563. }
  42564. function run(args) {
  42565. args = args || Module['arguments'];
  42566. if (preloadStartTime === null) preloadStartTime = Date.now();
  42567. if (runDependencies > 0) {
  42568. Module.printErr('run() called, but dependencies remain, so not running');
  42569. return;
  42570. }
  42571. writeStackCookie();
  42572. preRun();
  42573. if (runDependencies > 0) return; // a preRun added a dependency, run will be called later
  42574. if (Module['calledRun']) return; // run may have just been called through dependencies being fulfilled just in this very frame
  42575. function doRun() {
  42576. if (Module['calledRun']) return; // run may have just been called while the async setStatus time below was happening
  42577. Module['calledRun'] = true;
  42578. if (ABORT) return;
  42579. ensureInitRuntime();
  42580. preMain();
  42581. if (ENVIRONMENT_IS_WEB && preloadStartTime !== null) {
  42582. Module.printErr('pre-main prep time: ' + (Date.now() - preloadStartTime) + ' ms');
  42583. }
  42584. if (Module['onRuntimeInitialized']) Module['onRuntimeInitialized']();
  42585. if (Module['_main'] && shouldRunNow) Module['callMain'](args);
  42586. postRun();
  42587. }
  42588. if (Module['setStatus']) {
  42589. Module['setStatus']('Running...');
  42590. setTimeout(function() {
  42591. setTimeout(function() {
  42592. Module['setStatus']('');
  42593. }, 1);
  42594. doRun();
  42595. }, 1);
  42596. } else {
  42597. doRun();
  42598. }
  42599. checkStackCookie();
  42600. }
  42601. Module['run'] = Module.run = run;
  42602. function exit(status, implicit) {
  42603. if (implicit && Module['noExitRuntime']) {
  42604. Module.printErr('exit(' + status + ') implicitly called by end of main(), but noExitRuntime, so not exiting the runtime (you can use emscripten_force_exit, if you want to force a true shutdown)');
  42605. return;
  42606. }
  42607. if (Module['noExitRuntime']) {
  42608. Module.printErr('exit(' + status + ') called, but noExitRuntime, so halting execution but not exiting the runtime or preventing further async execution (you can use emscripten_force_exit, if you want to force a true shutdown)');
  42609. } else {
  42610. ABORT = true;
  42611. EXITSTATUS = status;
  42612. STACKTOP = initialStackTop;
  42613. exitRuntime();
  42614. if (Module['onExit']) Module['onExit'](status);
  42615. }
  42616. if (ENVIRONMENT_IS_NODE) {
  42617. process['exit'](status);
  42618. }
  42619. Module['quit'](status, new ExitStatus(status));
  42620. }
  42621. Module['exit'] = Module.exit = exit;
  42622. var abortDecorators = [];
  42623. function abort(what) {
  42624. if (what !== undefined) {
  42625. Module.print(what);
  42626. Module.printErr(what);
  42627. what = JSON.stringify(what)
  42628. } else {
  42629. what = '';
  42630. }
  42631. ABORT = true;
  42632. EXITSTATUS = 1;
  42633. var extra = '';
  42634. var output = 'abort(' + what + ') at ' + stackTrace() + extra;
  42635. if (abortDecorators) {
  42636. abortDecorators.forEach(function(decorator) {
  42637. output = decorator(output, what);
  42638. });
  42639. }
  42640. throw output;
  42641. }
  42642. Module['abort'] = Module.abort = abort;
  42643. // {{PRE_RUN_ADDITIONS}}
  42644. if (Module['preInit']) {
  42645. if (typeof Module['preInit'] == 'function') Module['preInit'] = [Module['preInit']];
  42646. while (Module['preInit'].length > 0) {
  42647. Module['preInit'].pop()();
  42648. }
  42649. }
  42650. // shouldRunNow refers to calling main(), not run().
  42651. var shouldRunNow = true;
  42652. if (Module['noInitialRun']) {
  42653. shouldRunNow = false;
  42654. }
  42655. run();
  42656. // {{POST_RUN_ADDITIONS}}
  42657. // {{MODULE_ADDITIONS}}