ref: 404bf6018e1385a8bc06844cc00605a4b136416b
parent: 5bc1c54d5f46c44d7cc3ad581ab06b6adae40bf3
author: Sam Leitch <sam.leitch@calgaryscientific.com>
date: Mon Mar 31 07:55:17 EDT 2014
JS H264Canvas now works with cropping params.
--- a/js/h264bsd.min.js
+++ b/js/h264bsd.min.js
@@ -1,11 +1,11 @@
function globalEval(x){eval.call(null,x)}function assert(condition,text){condition||abort("Assertion failed: "+text)}function ccall(ident,returnType,argTypes,args){return ccallFunc(getCFunc(ident),returnType,argTypes,args)}function getCFunc(ident){try{var func=Module["_"+ident];func||(func=eval("_"+ident))}catch(e){}return assert(func,"Cannot call unknown function "+ident+" (perhaps LLVM optimizations or closure removed it?)"),func}function ccallFunc(func,returnType,argTypes,args){function toC(value,type){if("string"==type){if(null===value||void 0===value||0===value)return 0;value=intArrayFromString(value),type="array"}if("array"==type){stack||(stack=Runtime.stackSave());var ret=Runtime.stackAlloc(value.length);return writeArrayToMemory(value,ret),ret}return value}function fromC(value,type){return"string"==type?Pointer_stringify(value):(assert("array"!=type),value)}var stack=0,i=0,cArgs=args?args.map(function(arg){return toC(arg,argTypes[i++])}):[],ret=fromC(func.apply(null,cArgs),returnType);return stack&&Runtime.stackRestore(stack),ret}function cwrap(ident,returnType,argTypes){var func=getCFunc(ident);return function(){return ccallFunc(func,returnType,argTypes,Array.prototype.slice.call(arguments))}}function setValue(ptr,value,type){switch(type=type||"i8","*"===type.charAt(type.length-1)&&(type="i32"),type){case"i1":HEAP8[ptr]=value;break;case"i8":HEAP8[ptr]=value;break;case"i16":HEAP16[ptr>>1]=value;break;case"i32":HEAP32[ptr>>2]=value;break;case"i64":tempI64=[value>>>0,(tempDouble=value,+Math_abs(tempDouble)>=1?tempDouble>0?(0|Math_min(+Math_floor(tempDouble/4294967296),4294967295))>>>0:~~+Math_ceil((tempDouble-+(~~tempDouble>>>0))/4294967296)>>>0:0)],HEAP32[ptr>>2]=tempI64[0],HEAP32[ptr+4>>2]=tempI64[1];break;case"float":HEAPF32[ptr>>2]=value;break;case"double":HEAPF64[ptr>>3]=value;break;default:abort("invalid type for setValue: "+type)}}function getValue(ptr,type){switch(type=type||"i8","*"===type.charAt(type.length-1)&&(type="i32"),type){case"i1":return HEAP8[ptr];case"i8":return HEAP8[ptr];case"i16":return HEAP16[ptr>>1];case"i32":return HEAP32[ptr>>2];case"i64":return HEAP32[ptr>>2];case"float":return HEAPF32[ptr>>2];case"double":return HEAPF64[ptr>>3];default:abort("invalid type for setValue: "+type)}return null}function allocate(slab,types,allocator,ptr){var zeroinit,size;"number"==typeof slab?(zeroinit=!0,size=slab):(zeroinit=!1,size=slab.length);var ret,singleType="string"==typeof types?types:null;if(ret=allocator==ALLOC_NONE?ptr:[_malloc,Runtime.stackAlloc,Runtime.staticAlloc,Runtime.dynamicAlloc][void 0===allocator?ALLOC_STATIC:allocator](Math.max(size,singleType?1:types.length)),zeroinit){var stop,ptr=ret;for(assert(0==(3&ret)),stop=ret+(-4&size);stop>ptr;ptr+=4)HEAP32[ptr>>2]=0;for(stop=ret+size;stop>ptr;)HEAP8[0|ptr++]=0;return ret}if("i8"===singleType)return slab.subarray||slab.slice?HEAPU8.set(slab,ret):HEAPU8.set(new Uint8Array(slab),ret),ret;for(var type,typeSize,previousType,i=0;size>i;){var curr=slab[i];"function"==typeof curr&&(curr=Runtime.getFunctionIndex(curr)),type=singleType||types[i],0!==type?("i64"==type&&(type="i32"),setValue(ret+i,curr,type),previousType!==type&&(typeSize=Runtime.getNativeTypeSize(type),previousType=type),i+=typeSize):i++}return ret}function Pointer_stringify(ptr,length){for(var t,hasUtf=!1,i=0;;){if(t=HEAPU8[ptr+i|0],t>=128)hasUtf=!0;else if(0==t&&!length)break;if(i++,length&&i==length)break}length||(length=i);var ret="";if(!hasUtf){for(var curr,MAX_CHUNK=1024;length>0;)curr=String.fromCharCode.apply(String,HEAPU8.subarray(ptr,ptr+Math.min(length,MAX_CHUNK))),ret=ret?ret+curr:curr,ptr+=MAX_CHUNK,length-=MAX_CHUNK;return ret}var utf8=new Runtime.UTF8Processor;for(i=0;length>i;i++)t=HEAPU8[ptr+i|0],ret+=utf8.processCChar(t);return ret}function UTF16ToString(ptr){for(var i=0,str="";;){var codeUnit=HEAP16[ptr+2*i>>1];if(0==codeUnit)return str;++i,str+=String.fromCharCode(codeUnit)}}function stringToUTF16(str,outPtr){for(var i=0;i<str.length;++i){var codeUnit=str.charCodeAt(i);HEAP16[outPtr+2*i>>1]=codeUnit}HEAP16[outPtr+2*str.length>>1]=0}function UTF32ToString(ptr){for(v
\ No newline at end of file
var __THREW__=0,ABORT=!1,EXITSTATUS=0,undef=0,tempValue,tempInt,tempBigInt,tempInt2,tempBigInt2,tempPair,tempBigIntI,tempBigIntR,tempBigIntS,tempBigIntP,tempBigIntD,tempDouble,tempFloat,tempI64,tempI64b,tempRet0,tempRet1,tempRet2,tempRet3,tempRet4,tempRet5,tempRet6,tempRet7,tempRet8,tempRet9,globalScope=this;Module.ccall=ccall,Module.cwrap=cwrap,Module.setValue=setValue,Module.getValue=getValue;var ALLOC_NORMAL=0,ALLOC_STACK=1,ALLOC_STATIC=2,ALLOC_DYNAMIC=3,ALLOC_NONE=4;Module.ALLOC_NORMAL=ALLOC_NORMAL,Module.ALLOC_STACK=ALLOC_STACK,Module.ALLOC_STATIC=ALLOC_STATIC,Module.ALLOC_DYNAMIC=ALLOC_DYNAMIC,Module.ALLOC_NONE=ALLOC_NONE,Module.allocate=allocate,Module.Pointer_stringify=Pointer_stringify,Module.UTF16ToString=UTF16ToString,Module.stringToUTF16=stringToUTF16,Module.UTF32ToString=UTF32ToString,Module.stringToUTF32=stringToUTF32;for(var PAGE_SIZE=4096,HEAP,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64,STATIC_BASE=0,STATICTOP=0,staticSealed=!1,STACK_BASE=0,STACKTOP=0,STACK_MAX=0,DYNAMIC_BASE=0,DYNAMICTOP=0,TOTAL_STACK=Module.TOTAL_STACK||5242880,TOTAL_MEMORY=Module.TOTAL_MEMORY||268435456,FAST_MEMORY=Module.FAST_MEMORY||2097152,totalMemory=4096;TOTAL_MEMORY>totalMemory||2*TOTAL_STACK>totalMemory;)16777216>totalMemory?totalMemory*=2:totalMemory+=16777216;totalMemory!==TOTAL_MEMORY&&(Module.printErr("increasing TOTAL_MEMORY to "+totalMemory+" to be more reasonable"),TOTAL_MEMORY=totalMemory),assert("undefined"!=typeof Int32Array&&"undefined"!=typeof Float64Array&&!!new Int32Array(1).subarray&&!!new Int32Array(1).set,"JS engine does not provide full typed array support");var buffer=new ArrayBuffer(TOTAL_MEMORY);HEAP8=new Int8Array(buffer),HEAP16=new Int16Array(buffer),HEAP32=new Int32Array(buffer),HEAPU8=new Uint8Array(buffer),HEAPU16=new Uint16Array(buffer),HEAPU32=new Uint32Array(buffer),HEAPF32=new Float32Array(buffer),HEAPF64=new Float64Array(buffer),HEAP32[0]=255,assert(255===HEAPU8[0]&&0===HEAPU8[3],"Typed arrays 2 must be run on a little-endian system"),Module.HEAP=HEAP,Module.HEAP8=HEAP8,Module.HEAP16=HEAP16,Module.HEAP32=HEAP32,Module.HEAPU8=HEAPU8,Module.HEAPU16=HEAPU16,Module.HEAPU32=HEAPU32,Module.HEAPF32=HEAPF32,Module.HEAPF64=HEAPF64;var __ATPRERUN__=[],__ATINIT__=[],__ATMAIN__=[],__ATEXIT__=[],__ATPOSTRUN__=[],runtimeInitialized=!1;Module.addOnPreRun=Module.addOnPreRun=addOnPreRun,Module.addOnInit=Module.addOnInit=addOnInit,Module.addOnPreMain=Module.addOnPreMain=addOnPreMain,Module.addOnExit=Module.addOnExit=addOnExit,Module.addOnPostRun=Module.addOnPostRun=addOnPostRun,Module.intArrayFromString=intArrayFromString,Module.intArrayToString=intArrayToString,Module.writeStringToMemory=writeStringToMemory,Module.writeArrayToMemory=writeArrayToMemory,Module.writeAsciiToMemory=writeAsciiToMemory,Math.imul&&-5===Math.imul(4294967295,5)||(Math.imul=function(a,b){var ah=a>>>16,al=65535&a,bh=b>>>16,bl=65535&b;return al*bl+(ah*bl+al*bh<<16)|0}),Math.imul=Math.imul;var Math_abs=Math.abs,Math_cos=Math.cos,Math_sin=Math.sin,Math_tan=Math.tan,Math_acos=Math.acos,Math_asin=Math.asin,Math_atan=Math.atan,Math_atan2=Math.atan2,Math_exp=Math.exp,Math_log=Math.log,Math_sqrt=Math.sqrt,Math_ceil=Math.ceil,Math_floor=Math.floor,Math_pow=Math.pow,Math_imul=Math.imul,Math_fround=Math.fround,Math_min=Math.min,runDependencies=0,runDependencyWatcher=null,dependenciesFulfilled=null;Module.addRunDependency=addRunDependency,Module.removeRunDependency=removeRunDependency,Module.preloadedImages={},Module.preloadedAudios={};var memoryInitializer=null;STATIC_BASE=8,STATICTOP=STATIC_BASE+Runtime.alignMemory(9235),__ATINIT__.push(),allocate([17,1,0,0,0,0,0,0,34,18,1,1,0,0,0,0,50,34,18,2,0,0,0,0,67,51,34,34,18,18,2,2,83,67,51,35,18,18,2,2,19,35,67,51,99,83,2,2,0,0,101,85,68,68,52,52,35,35,35,35,19,19,19,19,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,249,233,217,200,200,184,184,167,167,167,167,151,151,151,151,134,134,134,134,134,134,134,134,118,118,118,118,118,118,118,118,230,214,198,182,165,165,149,149,132,132,132,132,116,116,116,116,100,100,100,100,84,84,84,84,67,67,67,67,67,67,67,67,51,51,51,51,51,51,51,51,35,35,35,35,35,35,35,35,19,19,19,
\ No newline at end of file
return splitPathRe.exec(filename).slice(1)},normalizeArray:function(parts,allowAboveRoot){for(var up=0,i=parts.length-1;i>=0;i--){var last=parts[i];"."===last?parts.splice(i,1):".."===last?(parts.splice(i,1),up++):up&&(parts.splice(i,1),up--)}if(allowAboveRoot)for(;up--;up)parts.unshift("..");return parts},normalize:function(path){var isAbsolute="/"===path.charAt(0),trailingSlash="/"===path.substr(-1);return path=PATH.normalizeArray(path.split("/").filter(function(p){return!!p}),!isAbsolute).join("/"),path||isAbsolute||(path="."),path&&trailingSlash&&(path+="/"),(isAbsolute?"/":"")+path},dirname:function(path){var result=PATH.splitPath(path),root=result[0],dir=result[1];return root||dir?(dir&&(dir=dir.substr(0,dir.length-1)),root+dir):"."},basename:function(path){if("/"===path)return"/";var lastSlash=path.lastIndexOf("/");return-1===lastSlash?path:path.substr(lastSlash+1)},extname:function(path){return PATH.splitPath(path)[3]},join:function(){var paths=Array.prototype.slice.call(arguments,0);return PATH.normalize(paths.join("/"))},join2:function(l,r){return PATH.normalize(l+"/"+r)},resolve:function(){for(var resolvedPath="",resolvedAbsolute=!1,i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path=i>=0?arguments[i]:FS.cwd();if("string"!=typeof path)throw new TypeError("Arguments to path.resolve must be strings");path&&(resolvedPath=path+"/"+resolvedPath,resolvedAbsolute="/"===path.charAt(0))}return resolvedPath=PATH.normalizeArray(resolvedPath.split("/").filter(function(p){return!!p}),!resolvedAbsolute).join("/"),(resolvedAbsolute?"/":"")+resolvedPath||"."},relative:function(from,to){function trim(arr){for(var start=0;start<arr.length&&""===arr[start];start++);for(var end=arr.length-1;end>=0&&""===arr[end];end--);return start>end?[]:arr.slice(start,end-start+1)}from=PATH.resolve(from).substr(1),to=PATH.resolve(to).substr(1);for(var fromParts=trim(from.split("/")),toParts=trim(to.split("/")),length=Math.min(fromParts.length,toParts.length),samePartsLength=length,i=0;length>i;i++)if(fromParts[i]!==toParts[i]){samePartsLength=i;break}for(var outputParts=[],i=samePartsLength;i<fromParts.length;i++)outputParts.push("..");return outputParts=outputParts.concat(toParts.slice(samePartsLength)),outputParts.join("/")}},TTY={ttys:[],init:function(){},shutdown:function(){},register:function(dev,ops){TTY.ttys[dev]={input:[],output:[],ops:ops},FS.registerDevice(dev,TTY.stream_ops)},stream_ops:{open:function(stream){var tty=TTY.ttys[stream.node.rdev];if(!tty)throw new FS.ErrnoError(ERRNO_CODES.ENODEV);stream.tty=tty,stream.seekable=!1},close:function(stream){stream.tty.output.length&&stream.tty.ops.put_char(stream.tty,10)},read:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.get_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var bytesRead=0,i=0;length>i;i++){var result;try{result=stream.tty.ops.get_char(stream.tty)}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}if(void 0===result&&0===bytesRead)throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);if(null===result||void 0===result)break;bytesRead++,buffer[offset+i]=result}return bytesRead&&(stream.node.timestamp=Date.now()),bytesRead},write:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.put_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var i=0;length>i;i++)try{stream.tty.ops.put_char(stream.tty,buffer[offset+i])}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}return length&&(stream.node.timestamp=Date.now()),i}},default_tty_ops:{get_char:function(tty){if(!tty.input.length){var result=null;if(ENVIRONMENT_IS_NODE){if(result=process.stdin.read(),!result)return process.stdin._readableState&&process.stdin._readableState.ended?null:void 0}else"undefined"!=typeof window&&"function"==typeof window.prompt?(result=window.prompt("Input: "),null!==result&&(result+="\n")):"function"==typeof readline&&(result=readline(),null!==result&&(result+="\n"));if(!result)return null;tty.input=intArrayFromString(result,!0)}return tty.input.shift()},put_char:function(tty,val){null===val||10===val?(Module.print(tty.output.join("")),tty.output=[]):tty.output
\ No newline at end of file
-d,buf,len):(___setErrNo(ERRNO_CODES.EBADF),-1)}function _pwrite(fildes,buf,nbyte,offset){var stream=FS.getStream(fildes);if(!stream)return ___setErrNo(ERRNO_CODES.EBADF),-1;try{var slab=HEAP8;return FS.write(stream,slab,buf,nbyte,offset)}catch(e){return FS.handleFSError(e),-1}}function _write(fildes,buf,nbyte){var stream=FS.getStream(fildes);if(!stream)return ___setErrNo(ERRNO_CODES.EBADF),-1;try{var slab=HEAP8;return FS.write(stream,slab,buf,nbyte)}catch(e){return FS.handleFSError(e),-1}}function _fileno(stream){return stream=FS.getStreamFromPtr(stream),stream?stream.fd:-1}function _fwrite(ptr,size,nitems,stream){var bytesToWrite=nitems*size;if(0==bytesToWrite)return 0;var fd=_fileno(stream),bytesWritten=_write(fd,ptr,bytesToWrite);if(-1==bytesWritten){var streamObj=FS.getStreamFromPtr(stream);return streamObj&&(streamObj.error=!0),0}return Math.floor(bytesWritten/size)}function __reallyNegative(x){return 0>x||0===x&&1/x===-1/0}function __formatString(format,varargs){function getNextArg(type){var ret;return"double"===type?(HEAP32[tempDoublePtr>>2]=HEAP32[varargs+argIndex>>2],HEAP32[tempDoublePtr+4>>2]=HEAP32[varargs+(argIndex+4)>>2],ret=+HEAPF64[tempDoublePtr>>3]):"i64"==type?ret=[HEAP32[varargs+argIndex>>2],HEAP32[varargs+(argIndex+4)>>2]]:(type="i32",ret=HEAP32[varargs+argIndex>>2]),argIndex+=Runtime.getNativeFieldSize(type),ret}for(var curr,next,currArg,textIndex=format,argIndex=0,ret=[];;){var startTextIndex=textIndex;if(curr=HEAP8[textIndex],0===curr)break;if(next=HEAP8[textIndex+1|0],37==curr){var flagAlwaysSigned=!1,flagLeftAlign=!1,flagAlternative=!1,flagZeroPad=!1,flagPadSign=!1;flagsLoop:for(;;){switch(next){case 43:flagAlwaysSigned=!0;break;case 45:flagLeftAlign=!0;break;case 35:flagAlternative=!0;break;case 48:if(flagZeroPad)break flagsLoop;flagZeroPad=!0;break;case 32:flagPadSign=!0;break;default:break flagsLoop}textIndex++,next=HEAP8[textIndex+1|0]}var width=0;if(42==next)width=getNextArg("i32"),textIndex++,next=HEAP8[textIndex+1|0];else for(;next>=48&&57>=next;)width=10*width+(next-48),textIndex++,next=HEAP8[textIndex+1|0];var precisionSet=!1,precision=-1;if(46==next){if(precision=0,precisionSet=!0,textIndex++,next=HEAP8[textIndex+1|0],42==next)precision=getNextArg("i32"),textIndex++;else for(;;){var precisionChr=HEAP8[textIndex+1|0];if(48>precisionChr||precisionChr>57)break;precision=10*precision+(precisionChr-48),textIndex++}next=HEAP8[textIndex+1|0]}0>precision&&(precision=6,precisionSet=!1);var argSize;switch(String.fromCharCode(next)){case"h":var nextNext=HEAP8[textIndex+2|0];104==nextNext?(textIndex++,argSize=1):argSize=2;break;case"l":var nextNext=HEAP8[textIndex+2|0];108==nextNext?(textIndex++,argSize=8):argSize=4;break;case"L":case"q":case"j":argSize=8;break;case"z":case"t":case"I":argSize=4;break;default:argSize=null}switch(argSize&&textIndex++,next=HEAP8[textIndex+1|0],String.fromCharCode(next)){case"d":case"i":case"u":case"o":case"x":case"X":case"p":var signed=100==next||105==next;argSize=argSize||4;var argText,currArg=getNextArg("i"+8*argSize),origArg=currArg;if(8==argSize&&(currArg=Runtime.makeBigInt(currArg[0],currArg[1],117==next)),4>=argSize){var limit=Math.pow(256,argSize)-1;currArg=(signed?reSign:unSign)(currArg&limit,8*argSize)}var currAbsArg=Math.abs(currArg),prefix="";if(100==next||105==next)argText=8==argSize&&i64Math?i64Math.stringify(origArg[0],origArg[1],null):reSign(currArg,8*argSize,1).toString(10);else if(117==next)argText=8==argSize&&i64Math?i64Math.stringify(origArg[0],origArg[1],!0):unSign(currArg,8*argSize,1).toString(10),currArg=Math.abs(currArg);else if(111==next)argText=(flagAlternative?"0":"")+currAbsArg.toString(8);else if(120==next||88==next){if(prefix=flagAlternative&&0!=currArg?"0x":"",8==argSize&&i64Math)if(origArg[1]){argText=(origArg[1]>>>0).toString(16);for(var lower=(origArg[0]>>>0).toString(16);lower.length<8;)lower="0"+lower;argText+=lower}else argText=(origArg[0]>>>0).toString(16);else if(0>currArg){currArg=-currArg,argText=(currAbsArg-1).toString(16);for(var buffer=[],i=0;i<argText.length;i++)buffer.push((15-parseInt(argText[i],16)).toString(16));for(argT
\ No newline at end of file
-var __THREW__=0,ABORT=!1,EXITSTATUS=0,undef=0,tempValue,tempInt,tempBigInt,tempInt2,tempBigInt2,tempPair,tempBigIntI,tempBigIntR,tempBigIntS,tempBigIntP,tempBigIntD,tempDouble,tempFloat,tempI64,tempI64b,tempRet0,tempRet1,tempRet2,tempRet3,tempRet4,tempRet5,tempRet6,tempRet7,tempRet8,tempRet9,globalScope=this;Module.ccall=ccall,Module.cwrap=cwrap,Module.setValue=setValue,Module.getValue=getValue;var ALLOC_NORMAL=0,ALLOC_STACK=1,ALLOC_STATIC=2,ALLOC_DYNAMIC=3,ALLOC_NONE=4;Module.ALLOC_NORMAL=ALLOC_NORMAL,Module.ALLOC_STACK=ALLOC_STACK,Module.ALLOC_STATIC=ALLOC_STATIC,Module.ALLOC_DYNAMIC=ALLOC_DYNAMIC,Module.ALLOC_NONE=ALLOC_NONE,Module.allocate=allocate,Module.Pointer_stringify=Pointer_stringify,Module.UTF16ToString=UTF16ToString,Module.stringToUTF16=stringToUTF16,Module.UTF32ToString=UTF32ToString,Module.stringToUTF32=stringToUTF32;for(var PAGE_SIZE=4096,HEAP,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64,STATIC_BASE=0,STATICTOP=0,staticSealed=!1,STACK_BASE=0,STACKTOP=0,STACK_MAX=0,DYNAMIC_BASE=0,DYNAMICTOP=0,TOTAL_STACK=Module.TOTAL_STACK||5242880,TOTAL_MEMORY=Module.TOTAL_MEMORY||268435456,FAST_MEMORY=Module.FAST_MEMORY||2097152,totalMemory=4096;TOTAL_MEMORY>totalMemory||2*TOTAL_STACK>totalMemory;)16777216>totalMemory?totalMemory*=2:totalMemory+=16777216;totalMemory!==TOTAL_MEMORY&&(Module.printErr("increasing TOTAL_MEMORY to "+totalMemory+" to be more reasonable"),TOTAL_MEMORY=totalMemory),assert("undefined"!=typeof Int32Array&&"undefined"!=typeof Float64Array&&!!new Int32Array(1).subarray&&!!new Int32Array(1).set,"JS engine does not provide full typed array support");var buffer=new ArrayBuffer(TOTAL_MEMORY);HEAP8=new Int8Array(buffer),HEAP16=new Int16Array(buffer),HEAP32=new Int32Array(buffer),HEAPU8=new Uint8Array(buffer),HEAPU16=new Uint16Array(buffer),HEAPU32=new Uint32Array(buffer),HEAPF32=new Float32Array(buffer),HEAPF64=new Float64Array(buffer),HEAP32[0]=255,assert(255===HEAPU8[0]&&0===HEAPU8[3],"Typed arrays 2 must be run on a little-endian system"),Module.HEAP=HEAP,Module.HEAP8=HEAP8,Module.HEAP16=HEAP16,Module.HEAP32=HEAP32,Module.HEAPU8=HEAPU8,Module.HEAPU16=HEAPU16,Module.HEAPU32=HEAPU32,Module.HEAPF32=HEAPF32,Module.HEAPF64=HEAPF64;var __ATPRERUN__=[],__ATINIT__=[],__ATMAIN__=[],__ATEXIT__=[],__ATPOSTRUN__=[],runtimeInitialized=!1;Module.addOnPreRun=Module.addOnPreRun=addOnPreRun,Module.addOnInit=Module.addOnInit=addOnInit,Module.addOnPreMain=Module.addOnPreMain=addOnPreMain,Module.addOnExit=Module.addOnExit=addOnExit,Module.addOnPostRun=Module.addOnPostRun=addOnPostRun,Module.intArrayFromString=intArrayFromString,Module.intArrayToString=intArrayToString,Module.writeStringToMemory=writeStringToMemory,Module.writeArrayToMemory=writeArrayToMemory,Module.writeAsciiToMemory=writeAsciiToMemory,Math.imul&&-5===Math.imul(4294967295,5)||(Math.imul=function(a,b){var ah=a>>>16,al=65535&a,bh=b>>>16,bl=65535&b;return al*bl+(ah*bl+al*bh<<16)|0}),Math.imul=Math.imul;var Math_abs=Math.abs,Math_cos=Math.cos,Math_sin=Math.sin,Math_tan=Math.tan,Math_acos=Math.acos,Math_asin=Math.asin,Math_atan=Math.atan,Math_atan2=Math.atan2,Math_exp=Math.exp,Math_log=Math.log,Math_sqrt=Math.sqrt,Math_ceil=Math.ceil,Math_floor=Math.floor,Math_pow=Math.pow,Math_imul=Math.imul,Math_fround=Math.fround,Math_min=Math.min,runDependencies=0,runDependencyWatcher=null,dependenciesFulfilled=null;Module.addRunDependency=addRunDependency,Module.removeRunDependency=removeRunDependency,Module.preloadedImages={},Module.preloadedAudios={};var memoryInitializer=null;STATIC_BASE=8,STATICTOP=STATIC_BASE+Runtime.alignMemory(9235),__ATINIT__.push(),allocate([17,1,0,0,0,0,0,0,34,18,1,1,0,0,0,0,50,34,18,2,0,0,0,0,67,51,34,34,18,18,2,2,83,67,51,35,18,18,2,2,19,35,67,51,99,83,2,2,0,0,101,85,68,68,52,52,35,35,35,35,19,19,19,19,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,249,233,217,200,200,184,184,167,167,167,167,151,151,151,151,134,134,134,134,134,134,134,134,118,118,118,118,118,118,118,118,230,214,198,182,165,165,149,149,132,132,132,132,116,116,116,116,100,100,100,100,84,84,84,84,67,67,67,67,67,67,67,67,51,51,51,51,51,51,51,51,35,35,35,35,35,35,35,35,19,19,19,
\ No newline at end of file
-return splitPathRe.exec(filename).slice(1)},normalizeArray:function(parts,allowAboveRoot){for(var up=0,i=parts.length-1;i>=0;i--){var last=parts[i];"."===last?parts.splice(i,1):".."===last?(parts.splice(i,1),up++):up&&(parts.splice(i,1),up--)}if(allowAboveRoot)for(;up--;up)parts.unshift("..");return parts},normalize:function(path){var isAbsolute="/"===path.charAt(0),trailingSlash="/"===path.substr(-1);return path=PATH.normalizeArray(path.split("/").filter(function(p){return!!p}),!isAbsolute).join("/"),path||isAbsolute||(path="."),path&&trailingSlash&&(path+="/"),(isAbsolute?"/":"")+path},dirname:function(path){var result=PATH.splitPath(path),root=result[0],dir=result[1];return root||dir?(dir&&(dir=dir.substr(0,dir.length-1)),root+dir):"."},basename:function(path){if("/"===path)return"/";var lastSlash=path.lastIndexOf("/");return-1===lastSlash?path:path.substr(lastSlash+1)},extname:function(path){return PATH.splitPath(path)[3]},join:function(){var paths=Array.prototype.slice.call(arguments,0);return PATH.normalize(paths.join("/"))},join2:function(l,r){return PATH.normalize(l+"/"+r)},resolve:function(){for(var resolvedPath="",resolvedAbsolute=!1,i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path=i>=0?arguments[i]:FS.cwd();if("string"!=typeof path)throw new TypeError("Arguments to path.resolve must be strings");path&&(resolvedPath=path+"/"+resolvedPath,resolvedAbsolute="/"===path.charAt(0))}return resolvedPath=PATH.normalizeArray(resolvedPath.split("/").filter(function(p){return!!p}),!resolvedAbsolute).join("/"),(resolvedAbsolute?"/":"")+resolvedPath||"."},relative:function(from,to){function trim(arr){for(var start=0;start<arr.length&&""===arr[start];start++);for(var end=arr.length-1;end>=0&&""===arr[end];end--);return start>end?[]:arr.slice(start,end-start+1)}from=PATH.resolve(from).substr(1),to=PATH.resolve(to).substr(1);for(var fromParts=trim(from.split("/")),toParts=trim(to.split("/")),length=Math.min(fromParts.length,toParts.length),samePartsLength=length,i=0;length>i;i++)if(fromParts[i]!==toParts[i]){samePartsLength=i;break}for(var outputParts=[],i=samePartsLength;i<fromParts.length;i++)outputParts.push("..");return outputParts=outputParts.concat(toParts.slice(samePartsLength)),outputParts.join("/")}},TTY={ttys:[],init:function(){},shutdown:function(){},register:function(dev,ops){TTY.ttys[dev]={input:[],output:[],ops:ops},FS.registerDevice(dev,TTY.stream_ops)},stream_ops:{open:function(stream){var tty=TTY.ttys[stream.node.rdev];if(!tty)throw new FS.ErrnoError(ERRNO_CODES.ENODEV);stream.tty=tty,stream.seekable=!1},close:function(stream){stream.tty.output.length&&stream.tty.ops.put_char(stream.tty,10)},read:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.get_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var bytesRead=0,i=0;length>i;i++){var result;try{result=stream.tty.ops.get_char(stream.tty)}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}if(void 0===result&&0===bytesRead)throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);if(null===result||void 0===result)break;bytesRead++,buffer[offset+i]=result}return bytesRead&&(stream.node.timestamp=Date.now()),bytesRead},write:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.put_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var i=0;length>i;i++)try{stream.tty.ops.put_char(stream.tty,buffer[offset+i])}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}return length&&(stream.node.timestamp=Date.now()),i}},default_tty_ops:{get_char:function(tty){if(!tty.input.length){var result=null;if(ENVIRONMENT_IS_NODE){if(result=process.stdin.read(),!result)return process.stdin._readableState&&process.stdin._readableState.ended?null:void 0}else"undefined"!=typeof window&&"function"==typeof window.prompt?(result=window.prompt("Input: "),null!==result&&(result+="\n")):"function"==typeof readline&&(result=readline(),null!==result&&(result+="\n"));if(!result)return null;tty.input=intArrayFromString(result,!0)}return tty.input.shift()},put_char:function(tty,val){null===val||10===val?(Module.print(tty.output.join("")),tty.output=[]):tty.output
\ No newline at end of file
-parent.node_ops.unlink(parent,name),FS.destroyNode(node)},readlink:function(path){var lookup=FS.lookupPath(path),link=lookup.node;if(!link.node_ops.readlink)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);return link.node_ops.readlink(link)},stat:function(path,dontFollow){var lookup=FS.lookupPath(path,{follow:!dontFollow}),node=lookup.node;if(!node.node_ops.getattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);return node.node_ops.getattr(node)},lstat:function(path){return FS.stat(path,!0)},chmod:function(path,mode,dontFollow){var node;if("string"==typeof path){var lookup=FS.lookupPath(path,{follow:!dontFollow});node=lookup.node}else node=path;if(!node.node_ops.setattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);node.node_ops.setattr(node,{mode:4095&mode|-4096&node.mode,timestamp:Date.now()})},lchmod:function(path,mode){FS.chmod(path,mode,!0)},fchmod:function(fd,mode){var stream=FS.getStream(fd);if(!stream)throw new FS.ErrnoError(ERRNO_CODES.EBADF);FS.chmod(stream.node,mode)},chown:function(path,uid,gid,dontFollow){var node;if("string"==typeof path){var lookup=FS.lookupPath(path,{follow:!dontFollow});node=lookup.node}else node=path;if(!node.node_ops.setattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);node.node_ops.setattr(node,{timestamp:Date.now()})},lchown:function(path,uid,gid){FS.chown(path,uid,gid,!0)},fchown:function(fd,uid,gid){var stream=FS.getStream(fd);if(!stream)throw new FS.ErrnoError(ERRNO_CODES.EBADF);FS.chown(stream.node,uid,gid)},truncate:function(path,len){if(0>len)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);var node;if("string"==typeof path){var lookup=FS.lookupPath(path,{follow:!0});node=lookup.node}else node=path;if(!node.node_ops.setattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);if(FS.isDir(node.mode))throw new FS.ErrnoError(ERRNO_CODES.EISDIR);if(!FS.isFile(node.mode))throw new FS.ErrnoError(ERRNO_CODES.EINVAL);var err=FS.nodePermissions(node,"w");if(err)throw new FS.ErrnoError(err);node.node_ops.setattr(node,{size:len,timestamp:Date.now()})},ftruncate:function(fd,len){var stream=FS.getStream(fd);if(!stream)throw new FS.ErrnoError(ERRNO_CODES.EBADF);if(0===(2097155&stream.flags))throw new FS.ErrnoError(ERRNO_CODES.EINVAL);FS.truncate(stream.node,len)},utime:function(path,atime,mtime){var lookup=FS.lookupPath(path,{follow:!0}),node=lookup.node;node.node_ops.setattr(node,{timestamp:Math.max(atime,mtime)})},open:function(path,flags,mode,fd_start,fd_end){flags="string"==typeof flags?FS.modeStringToFlags(flags):flags,mode="undefined"==typeof mode?438:mode,mode=64&flags?4095&mode|32768:0;var node;if("object"==typeof path)node=path;else{path=PATH.normalize(path);try{var lookup=FS.lookupPath(path,{follow:!(131072&flags)});node=lookup.node}catch(e){}}if(64&flags)if(node){if(128&flags)throw new FS.ErrnoError(ERRNO_CODES.EEXIST)}else node=FS.mknod(path,mode,0);if(!node)throw new FS.ErrnoError(ERRNO_CODES.ENOENT);FS.isChrdev(node.mode)&&(flags&=-513);var err=FS.mayOpen(node,flags);if(err)throw new FS.ErrnoError(err);512&flags&&FS.truncate(node,0),flags&=-641;var stream=FS.createStream({node:node,path:FS.getPath(node),flags:flags,seekable:!0,position:0,stream_ops:node.stream_ops,ungotten:[],error:!1},fd_start,fd_end);return stream.stream_ops.open&&stream.stream_ops.open(stream),!Module.logReadFiles||1&flags||(FS.readFiles||(FS.readFiles={}),path in FS.readFiles||(FS.readFiles[path]=1,Module.printErr("read file: "+path))),stream},close:function(stream){try{stream.stream_ops.close&&stream.stream_ops.close(stream)}catch(e){throw e}finally{FS.closeStream(stream.fd)}},llseek:function(stream,offset,whence){if(!stream.seekable||!stream.stream_ops.llseek)throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);return stream.stream_ops.llseek(stream,offset,whence)},read:function(stream,buffer,offset,length,position){if(0>length||0>position)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);if(1===(2097155&stream.flags))throw new FS.ErrnoError(ERRNO_CODES.EBADF);if(FS.isDir(stream.node.mode))throw new FS.ErrnoError(ERRNO_CODES.EISDIR);if(!stream.stream_ops.read)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);var seeking=!0;if("undefined"==typeof positi
\ No newline at end of file
-}catch(e){return fail()}var url=Browser.URLObject.createObjectURL(b),audio=new Audio;audio.addEventListener("canplaythrough",function(){finish(audio)},!1),audio.onerror=function(){function encode64(data){for(var BASE="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",PAD="=",ret="",leftchar=0,leftbits=0,i=0;i<data.length;i++)for(leftchar=leftchar<<8|data[i],leftbits+=8;leftbits>=6;){var curr=leftchar>>leftbits-6&63;leftbits-=6,ret+=BASE[curr]}return 2==leftbits?(ret+=BASE[(3&leftchar)<<4],ret+=PAD+PAD):4==leftbits&&(ret+=BASE[(15&leftchar)<<2],ret+=PAD),ret}done||(console.log("warning: browser could not fully decode audio "+name+", trying slower base64 approach"),audio.src="data:audio/x-"+name.substr(-3)+";base64,"+encode64(byteArray),finish(audio))},audio.src=url,Browser.safeSetTimeout(function(){finish(audio)},1e4)},Module.preloadPlugins.push(audioPlugin);var canvas=Module.canvas;canvas.requestPointerLock=canvas.requestPointerLock||canvas.mozRequestPointerLock||canvas.webkitRequestPointerLock||canvas.msRequestPointerLock||function(){},canvas.exitPointerLock=document.exitPointerLock||document.mozExitPointerLock||document.webkitExitPointerLock||document.msExitPointerLock||function(){},canvas.exitPointerLock=canvas.exitPointerLock.bind(document),document.addEventListener("pointerlockchange",pointerLockChange,!1),document.addEventListener("mozpointerlockchange",pointerLockChange,!1),document.addEventListener("webkitpointerlockchange",pointerLockChange,!1),document.addEventListener("mspointerlockchange",pointerLockChange,!1),Module.elementPointerLock&&canvas.addEventListener("click",function(ev){!Browser.pointerLock&&canvas.requestPointerLock&&(canvas.requestPointerLock(),ev.preventDefault())},!1)}},createContext:function(canvas,useWebGL,setInModule,webGLContextAttributes){function onContextCreationError(event){errorInfo=event.statusMessage||errorInfo}var ctx,errorInfo="?";try{if(useWebGL){var contextAttributes={antialias:!1,alpha:!1};if(webGLContextAttributes)for(var attribute in webGLContextAttributes)contextAttributes[attribute]=webGLContextAttributes[attribute];canvas.addEventListener("webglcontextcreationerror",onContextCreationError,!1);try{["experimental-webgl","webgl"].some(function(webglId){return ctx=canvas.getContext(webglId,contextAttributes)})}finally{canvas.removeEventListener("webglcontextcreationerror",onContextCreationError,!1)}}else ctx=canvas.getContext("2d");if(!ctx)throw":("}catch(e){return Module.print("Could not create canvas: "+[errorInfo,e]),null}return useWebGL&&(canvas.style.backgroundColor="black",canvas.addEventListener("webglcontextlost",function(){alert("WebGL context lost. You will need to reload the page.")},!1)),setInModule&&(GLctx=Module.ctx=ctx,Module.useWebGL=useWebGL,Browser.moduleContextCreatedCallbacks.forEach(function(callback){callback()}),Browser.init()),ctx},destroyContext:function(){},fullScreenHandlersInstalled:!1,lockPointer:void 0,resizeCanvas:void 0,requestFullScreen:function(lockPointer,resizeCanvas){function fullScreenChange(){if(Browser.isFullScreen=!1,(document.webkitFullScreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.mozFullscreenElement||document.fullScreenElement||document.fullscreenElement||document.msFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement)===canvasContainer)canvas.cancelFullScreen=document.cancelFullScreen||document.mozCancelFullScreen||document.webkitCancelFullScreen||document.msExitFullscreen||document.exitFullscreen||function(){},canvas.cancelFullScreen=canvas.cancelFullScreen.bind(document),Browser.lockPointer&&canvas.requestPointerLock(),Browser.isFullScreen=!0,Browser.resizeCanvas&&Browser.setFullScreenCanvasSize();else{var canvasContainer=canvas.parentNode;canvasContainer.parentNode.insertBefore(canvas,canvasContainer),canvasContainer.parentNode.removeChild(canvasContainer),Browser.resizeCanvas&&Browser.setWindowedCanvasSize()}Module.onFullScreen&&Module.onFullScreen(Browser.isFullScreen),Browser.updateCanvasDimensions(canvas)}Browser.lockPointer=lockPoi
\ No newline at end of file
+d,buf,len):(___setErrNo(ERRNO_CODES.EBADF),-1)}function _pwrite(fildes,buf,nbyte,offset){var stream=FS.getStream(fildes);if(!stream)return ___setErrNo(ERRNO_CODES.EBADF),-1;try{var slab=HEAP8;return FS.write(stream,slab,buf,nbyte,offset)}catch(e){return FS.handleFSError(e),-1}}function _write(fildes,buf,nbyte){var stream=FS.getStream(fildes);if(!stream)return ___setErrNo(ERRNO_CODES.EBADF),-1;try{var slab=HEAP8;return FS.write(stream,slab,buf,nbyte)}catch(e){return FS.handleFSError(e),-1}}function _fileno(stream){return stream=FS.getStreamFromPtr(stream),stream?stream.fd:-1}function _fwrite(ptr,size,nitems,stream){var bytesToWrite=nitems*size;if(0==bytesToWrite)return 0;var fd=_fileno(stream),bytesWritten=_write(fd,ptr,bytesToWrite);if(-1==bytesWritten){var streamObj=FS.getStreamFromPtr(stream);return streamObj&&(streamObj.error=!0),0}return Math.floor(bytesWritten/size)}function __reallyNegative(x){return 0>x||0===x&&1/x===-1/0}function __formatString(format,varargs){function getNextArg(type){var ret;return"double"===type?(HEAP32[tempDoublePtr>>2]=HEAP32[varargs+argIndex>>2],HEAP32[tempDoublePtr+4>>2]=HEAP32[varargs+(argIndex+4)>>2],ret=+HEAPF64[tempDoublePtr>>3]):"i64"==type?ret=[HEAP32[varargs+argIndex>>2],HEAP32[varargs+(argIndex+4)>>2]]:(type="i32",ret=HEAP32[varargs+argIndex>>2]),argIndex+=Runtime.getNativeFieldSize(type),ret}for(var curr,next,currArg,textIndex=format,argIndex=0,ret=[];;){var startTextIndex=textIndex;if(curr=HEAP8[textIndex],0===curr)break;if(next=HEAP8[textIndex+1|0],37==curr){var flagAlwaysSigned=!1,flagLeftAlign=!1,flagAlternative=!1,flagZeroPad=!1,flagPadSign=!1;flagsLoop:for(;;){switch(next){case 43:flagAlwaysSigned=!0;break;case 45:flagLeftAlign=!0;break;case 35:flagAlternative=!0;break;case 48:if(flagZeroPad)break flagsLoop;flagZeroPad=!0;break;case 32:flagPadSign=!0;break;default:break flagsLoop}textIndex++,next=HEAP8[textIndex+1|0]}var width=0;if(42==next)width=getNextArg("i32"),textIndex++,next=HEAP8[textIndex+1|0];else for(;next>=48&&57>=next;)width=10*width+(next-48),textIndex++,next=HEAP8[textIndex+1|0];var precisionSet=!1,precision=-1;if(46==next){if(precision=0,precisionSet=!0,textIndex++,next=HEAP8[textIndex+1|0],42==next)precision=getNextArg("i32"),textIndex++;else for(;;){var precisionChr=HEAP8[textIndex+1|0];if(48>precisionChr||precisionChr>57)break;precision=10*precision+(precisionChr-48),textIndex++}next=HEAP8[textIndex+1|0]}0>precision&&(precision=6,precisionSet=!1);var argSize;switch(String.fromCharCode(next)){case"h":var nextNext=HEAP8[textIndex+2|0];104==nextNext?(textIndex++,argSize=1):argSize=2;break;case"l":var nextNext=HEAP8[textIndex+2|0];108==nextNext?(textIndex++,argSize=8):argSize=4;break;case"L":case"q":case"j":argSize=8;break;case"z":case"t":case"I":argSize=4;break;default:argSize=null}switch(argSize&&textIndex++,next=HEAP8[textIndex+1|0],String.fromCharCode(next)){case"d":case"i":case"u":case"o":case"x":case"X":case"p":var signed=100==next||105==next;argSize=argSize||4;var argText,currArg=getNextArg("i"+8*argSize),origArg=currArg;if(8==argSize&&(currArg=Runtime.makeBigInt(currArg[0],currArg[1],117==next)),4>=argSize){var limit=Math.pow(256,argSize)-1;currArg=(signed?reSign:unSign)(currArg&limit,8*argSize)}var currAbsArg=Math.abs(currArg),prefix="";if(100==next||105==next)argText=8==argSize&&i64Math?i64Math.stringify(origArg[0],origArg[1],null):reSign(currArg,8*argSize,1).toString(10);else if(117==next)argText=8==argSize&&i64Math?i64Math.stringify(origArg[0],origArg[1],!0):unSign(currArg,8*argSize,1).toString(10),currArg=Math.abs(currArg);else if(111==next)argText=(flagAlternative?"0":"")+currAbsArg.toString(8);else if(120==next||88==next){if(prefix=flagAlternative&&0!=currArg?"0x":"",8==argSize&&i64Math)if(origArg[1]){argText=(origArg[1]>>>0).toString(16);for(var lower=(origArg[0]>>>0).toString(16);lower.length<8;)lower="0"+lower;argText+=lower}else argText=(origArg[0]>>>0).toString(16);else if(0>currArg){currArg=-currArg,argText=(currAbsArg-1).toString(16);for(var buffer=[],i=0;i<argText.length;i++)buffer.push((15-parseInt(argText[i],16)).toString(16));for(argT
\ No newline at end of file
+var __THREW__=0,ABORT=!1,EXITSTATUS=0,undef=0,tempValue,tempInt,tempBigInt,tempInt2,tempBigInt2,tempPair,tempBigIntI,tempBigIntR,tempBigIntS,tempBigIntP,tempBigIntD,tempDouble,tempFloat,tempI64,tempI64b,tempRet0,tempRet1,tempRet2,tempRet3,tempRet4,tempRet5,tempRet6,tempRet7,tempRet8,tempRet9,globalScope=this;Module.ccall=ccall,Module.cwrap=cwrap,Module.setValue=setValue,Module.getValue=getValue;var ALLOC_NORMAL=0,ALLOC_STACK=1,ALLOC_STATIC=2,ALLOC_DYNAMIC=3,ALLOC_NONE=4;Module.ALLOC_NORMAL=ALLOC_NORMAL,Module.ALLOC_STACK=ALLOC_STACK,Module.ALLOC_STATIC=ALLOC_STATIC,Module.ALLOC_DYNAMIC=ALLOC_DYNAMIC,Module.ALLOC_NONE=ALLOC_NONE,Module.allocate=allocate,Module.Pointer_stringify=Pointer_stringify,Module.UTF16ToString=UTF16ToString,Module.stringToUTF16=stringToUTF16,Module.UTF32ToString=UTF32ToString,Module.stringToUTF32=stringToUTF32;for(var PAGE_SIZE=4096,HEAP,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64,STATIC_BASE=0,STATICTOP=0,staticSealed=!1,STACK_BASE=0,STACKTOP=0,STACK_MAX=0,DYNAMIC_BASE=0,DYNAMICTOP=0,TOTAL_STACK=Module.TOTAL_STACK||5242880,TOTAL_MEMORY=Module.TOTAL_MEMORY||268435456,FAST_MEMORY=Module.FAST_MEMORY||2097152,totalMemory=4096;TOTAL_MEMORY>totalMemory||2*TOTAL_STACK>totalMemory;)16777216>totalMemory?totalMemory*=2:totalMemory+=16777216;totalMemory!==TOTAL_MEMORY&&(Module.printErr("increasing TOTAL_MEMORY to "+totalMemory+" to be more reasonable"),TOTAL_MEMORY=totalMemory),assert("undefined"!=typeof Int32Array&&"undefined"!=typeof Float64Array&&!!new Int32Array(1).subarray&&!!new Int32Array(1).set,"JS engine does not provide full typed array support");var buffer=new ArrayBuffer(TOTAL_MEMORY);HEAP8=new Int8Array(buffer),HEAP16=new Int16Array(buffer),HEAP32=new Int32Array(buffer),HEAPU8=new Uint8Array(buffer),HEAPU16=new Uint16Array(buffer),HEAPU32=new Uint32Array(buffer),HEAPF32=new Float32Array(buffer),HEAPF64=new Float64Array(buffer),HEAP32[0]=255,assert(255===HEAPU8[0]&&0===HEAPU8[3],"Typed arrays 2 must be run on a little-endian system"),Module.HEAP=HEAP,Module.HEAP8=HEAP8,Module.HEAP16=HEAP16,Module.HEAP32=HEAP32,Module.HEAPU8=HEAPU8,Module.HEAPU16=HEAPU16,Module.HEAPU32=HEAPU32,Module.HEAPF32=HEAPF32,Module.HEAPF64=HEAPF64;var __ATPRERUN__=[],__ATINIT__=[],__ATMAIN__=[],__ATEXIT__=[],__ATPOSTRUN__=[],runtimeInitialized=!1;Module.addOnPreRun=Module.addOnPreRun=addOnPreRun,Module.addOnInit=Module.addOnInit=addOnInit,Module.addOnPreMain=Module.addOnPreMain=addOnPreMain,Module.addOnExit=Module.addOnExit=addOnExit,Module.addOnPostRun=Module.addOnPostRun=addOnPostRun,Module.intArrayFromString=intArrayFromString,Module.intArrayToString=intArrayToString,Module.writeStringToMemory=writeStringToMemory,Module.writeArrayToMemory=writeArrayToMemory,Module.writeAsciiToMemory=writeAsciiToMemory,Math.imul&&-5===Math.imul(4294967295,5)||(Math.imul=function(a,b){var ah=a>>>16,al=65535&a,bh=b>>>16,bl=65535&b;return al*bl+(ah*bl+al*bh<<16)|0}),Math.imul=Math.imul;var Math_abs=Math.abs,Math_cos=Math.cos,Math_sin=Math.sin,Math_tan=Math.tan,Math_acos=Math.acos,Math_asin=Math.asin,Math_atan=Math.atan,Math_atan2=Math.atan2,Math_exp=Math.exp,Math_log=Math.log,Math_sqrt=Math.sqrt,Math_ceil=Math.ceil,Math_floor=Math.floor,Math_pow=Math.pow,Math_imul=Math.imul,Math_fround=Math.fround,Math_min=Math.min,runDependencies=0,runDependencyWatcher=null,dependenciesFulfilled=null;Module.addRunDependency=addRunDependency,Module.removeRunDependency=removeRunDependency,Module.preloadedImages={},Module.preloadedAudios={};var memoryInitializer=null;STATIC_BASE=8,STATICTOP=STATIC_BASE+Runtime.alignMemory(9235),__ATINIT__.push(),allocate([17,1,0,0,0,0,0,0,34,18,1,1,0,0,0,0,50,34,18,2,0,0,0,0,67,51,34,34,18,18,2,2,83,67,51,35,18,18,2,2,19,35,67,51,99,83,2,2,0,0,101,85,68,68,52,52,35,35,35,35,19,19,19,19,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,249,233,217,200,200,184,184,167,167,167,167,151,151,151,151,134,134,134,134,134,134,134,134,118,118,118,118,118,118,118,118,230,214,198,182,165,165,149,149,132,132,132,132,116,116,116,116,100,100,100,100,84,84,84,84,67,67,67,67,67,67,67,67,51,51,51,51,51,51,51,51,35,35,35,35,35,35,35,35,19,19,19,
\ No newline at end of file
+return splitPathRe.exec(filename).slice(1)},normalizeArray:function(parts,allowAboveRoot){for(var up=0,i=parts.length-1;i>=0;i--){var last=parts[i];"."===last?parts.splice(i,1):".."===last?(parts.splice(i,1),up++):up&&(parts.splice(i,1),up--)}if(allowAboveRoot)for(;up--;up)parts.unshift("..");return parts},normalize:function(path){var isAbsolute="/"===path.charAt(0),trailingSlash="/"===path.substr(-1);return path=PATH.normalizeArray(path.split("/").filter(function(p){return!!p}),!isAbsolute).join("/"),path||isAbsolute||(path="."),path&&trailingSlash&&(path+="/"),(isAbsolute?"/":"")+path},dirname:function(path){var result=PATH.splitPath(path),root=result[0],dir=result[1];return root||dir?(dir&&(dir=dir.substr(0,dir.length-1)),root+dir):"."},basename:function(path){if("/"===path)return"/";var lastSlash=path.lastIndexOf("/");return-1===lastSlash?path:path.substr(lastSlash+1)},extname:function(path){return PATH.splitPath(path)[3]},join:function(){var paths=Array.prototype.slice.call(arguments,0);return PATH.normalize(paths.join("/"))},join2:function(l,r){return PATH.normalize(l+"/"+r)},resolve:function(){for(var resolvedPath="",resolvedAbsolute=!1,i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path=i>=0?arguments[i]:FS.cwd();if("string"!=typeof path)throw new TypeError("Arguments to path.resolve must be strings");path&&(resolvedPath=path+"/"+resolvedPath,resolvedAbsolute="/"===path.charAt(0))}return resolvedPath=PATH.normalizeArray(resolvedPath.split("/").filter(function(p){return!!p}),!resolvedAbsolute).join("/"),(resolvedAbsolute?"/":"")+resolvedPath||"."},relative:function(from,to){function trim(arr){for(var start=0;start<arr.length&&""===arr[start];start++);for(var end=arr.length-1;end>=0&&""===arr[end];end--);return start>end?[]:arr.slice(start,end-start+1)}from=PATH.resolve(from).substr(1),to=PATH.resolve(to).substr(1);for(var fromParts=trim(from.split("/")),toParts=trim(to.split("/")),length=Math.min(fromParts.length,toParts.length),samePartsLength=length,i=0;length>i;i++)if(fromParts[i]!==toParts[i]){samePartsLength=i;break}for(var outputParts=[],i=samePartsLength;i<fromParts.length;i++)outputParts.push("..");return outputParts=outputParts.concat(toParts.slice(samePartsLength)),outputParts.join("/")}},TTY={ttys:[],init:function(){},shutdown:function(){},register:function(dev,ops){TTY.ttys[dev]={input:[],output:[],ops:ops},FS.registerDevice(dev,TTY.stream_ops)},stream_ops:{open:function(stream){var tty=TTY.ttys[stream.node.rdev];if(!tty)throw new FS.ErrnoError(ERRNO_CODES.ENODEV);stream.tty=tty,stream.seekable=!1},close:function(stream){stream.tty.output.length&&stream.tty.ops.put_char(stream.tty,10)},read:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.get_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var bytesRead=0,i=0;length>i;i++){var result;try{result=stream.tty.ops.get_char(stream.tty)}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}if(void 0===result&&0===bytesRead)throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);if(null===result||void 0===result)break;bytesRead++,buffer[offset+i]=result}return bytesRead&&(stream.node.timestamp=Date.now()),bytesRead},write:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.put_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var i=0;length>i;i++)try{stream.tty.ops.put_char(stream.tty,buffer[offset+i])}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}return length&&(stream.node.timestamp=Date.now()),i}},default_tty_ops:{get_char:function(tty){if(!tty.input.length){var result=null;if(ENVIRONMENT_IS_NODE){if(result=process.stdin.read(),!result)return process.stdin._readableState&&process.stdin._readableState.ended?null:void 0}else"undefined"!=typeof window&&"function"==typeof window.prompt?(result=window.prompt("Input: "),null!==result&&(result+="\n")):"function"==typeof readline&&(result=readline(),null!==result&&(result+="\n"));if(!result)return null;tty.input=intArrayFromString(result,!0)}return tty.input.shift()},put_char:function(tty,val){null===val||10===val?(Module.print(tty.output.join("")),tty.output=[]):tty.output
\ No newline at end of file
+},readlink:function(path){var lookup=FS.lookupPath(path),link=lookup.node;if(!link.node_ops.readlink)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);return link.node_ops.readlink(link)},stat:function(path,dontFollow){var lookup=FS.lookupPath(path,{follow:!dontFollow}),node=lookup.node;if(!node.node_ops.getattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);return node.node_ops.getattr(node)},lstat:function(path){return FS.stat(path,!0)},chmod:function(path,mode,dontFollow){var node;if("string"==typeof path){var lookup=FS.lookupPath(path,{follow:!dontFollow});node=lookup.node}else node=path;if(!node.node_ops.setattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);node.node_ops.setattr(node,{mode:4095&mode|-4096&node.mode,timestamp:Date.now()})},lchmod:function(path,mode){FS.chmod(path,mode,!0)},fchmod:function(fd,mode){var stream=FS.getStream(fd);if(!stream)throw new FS.ErrnoError(ERRNO_CODES.EBADF);FS.chmod(stream.node,mode)},chown:function(path,uid,gid,dontFollow){var node;if("string"==typeof path){var lookup=FS.lookupPath(path,{follow:!dontFollow});node=lookup.node}else node=path;if(!node.node_ops.setattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);node.node_ops.setattr(node,{timestamp:Date.now()})},lchown:function(path,uid,gid){FS.chown(path,uid,gid,!0)},fchown:function(fd,uid,gid){var stream=FS.getStream(fd);if(!stream)throw new FS.ErrnoError(ERRNO_CODES.EBADF);FS.chown(stream.node,uid,gid)},truncate:function(path,len){if(0>len)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);var node;if("string"==typeof path){var lookup=FS.lookupPath(path,{follow:!0});node=lookup.node}else node=path;if(!node.node_ops.setattr)throw new FS.ErrnoError(ERRNO_CODES.EPERM);if(FS.isDir(node.mode))throw new FS.ErrnoError(ERRNO_CODES.EISDIR);if(!FS.isFile(node.mode))throw new FS.ErrnoError(ERRNO_CODES.EINVAL);var err=FS.nodePermissions(node,"w");if(err)throw new FS.ErrnoError(err);node.node_ops.setattr(node,{size:len,timestamp:Date.now()})},ftruncate:function(fd,len){var stream=FS.getStream(fd);if(!stream)throw new FS.ErrnoError(ERRNO_CODES.EBADF);if(0===(2097155&stream.flags))throw new FS.ErrnoError(ERRNO_CODES.EINVAL);FS.truncate(stream.node,len)},utime:function(path,atime,mtime){var lookup=FS.lookupPath(path,{follow:!0}),node=lookup.node;node.node_ops.setattr(node,{timestamp:Math.max(atime,mtime)})},open:function(path,flags,mode,fd_start,fd_end){flags="string"==typeof flags?FS.modeStringToFlags(flags):flags,mode="undefined"==typeof mode?438:mode,mode=64&flags?4095&mode|32768:0;var node;if("object"==typeof path)node=path;else{path=PATH.normalize(path);try{var lookup=FS.lookupPath(path,{follow:!(131072&flags)});node=lookup.node}catch(e){}}if(64&flags)if(node){if(128&flags)throw new FS.ErrnoError(ERRNO_CODES.EEXIST)}else node=FS.mknod(path,mode,0);if(!node)throw new FS.ErrnoError(ERRNO_CODES.ENOENT);FS.isChrdev(node.mode)&&(flags&=-513);var err=FS.mayOpen(node,flags);if(err)throw new FS.ErrnoError(err);512&flags&&FS.truncate(node,0),flags&=-641;var stream=FS.createStream({node:node,path:FS.getPath(node),flags:flags,seekable:!0,position:0,stream_ops:node.stream_ops,ungotten:[],error:!1},fd_start,fd_end);return stream.stream_ops.open&&stream.stream_ops.open(stream),!Module.logReadFiles||1&flags||(FS.readFiles||(FS.readFiles={}),path in FS.readFiles||(FS.readFiles[path]=1,Module.printErr("read file: "+path))),stream},close:function(stream){try{stream.stream_ops.close&&stream.stream_ops.close(stream)}catch(e){throw e}finally{FS.closeStream(stream.fd)}},llseek:function(stream,offset,whence){if(!stream.seekable||!stream.stream_ops.llseek)throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);return stream.stream_ops.llseek(stream,offset,whence)},read:function(stream,buffer,offset,length,position){if(0>length||0>position)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);if(1===(2097155&stream.flags))throw new FS.ErrnoError(ERRNO_CODES.EBADF);if(FS.isDir(stream.node.mode))throw new FS.ErrnoError(ERRNO_CODES.EISDIR);if(!stream.stream_ops.read)throw new FS.ErrnoError(ERRNO_CODES.EINVAL);var seeking=!0;if("undefined"==typeof position)position=stream.position,seeking=!1;else if(!stream.s
\ No newline at end of file
+audio.addEventListener("canplaythrough",function(){finish(audio)},!1),audio.onerror=function(){function encode64(data){for(var BASE="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",PAD="=",ret="",leftchar=0,leftbits=0,i=0;i<data.length;i++)for(leftchar=leftchar<<8|data[i],leftbits+=8;leftbits>=6;){var curr=leftchar>>leftbits-6&63;leftbits-=6,ret+=BASE[curr]}return 2==leftbits?(ret+=BASE[(3&leftchar)<<4],ret+=PAD+PAD):4==leftbits&&(ret+=BASE[(15&leftchar)<<2],ret+=PAD),ret}done||(console.log("warning: browser could not fully decode audio "+name+", trying slower base64 approach"),audio.src="data:audio/x-"+name.substr(-3)+";base64,"+encode64(byteArray),finish(audio))},audio.src=url,Browser.safeSetTimeout(function(){finish(audio)},1e4)},Module.preloadPlugins.push(audioPlugin);var canvas=Module.canvas;canvas.requestPointerLock=canvas.requestPointerLock||canvas.mozRequestPointerLock||canvas.webkitRequestPointerLock||canvas.msRequestPointerLock||function(){},canvas.exitPointerLock=document.exitPointerLock||document.mozExitPointerLock||document.webkitExitPointerLock||document.msExitPointerLock||function(){},canvas.exitPointerLock=canvas.exitPointerLock.bind(document),document.addEventListener("pointerlockchange",pointerLockChange,!1),document.addEventListener("mozpointerlockchange",pointerLockChange,!1),document.addEventListener("webkitpointerlockchange",pointerLockChange,!1),document.addEventListener("mspointerlockchange",pointerLockChange,!1),Module.elementPointerLock&&canvas.addEventListener("click",function(ev){!Browser.pointerLock&&canvas.requestPointerLock&&(canvas.requestPointerLock(),ev.preventDefault())},!1)}},createContext:function(canvas,useWebGL,setInModule,webGLContextAttributes){function onContextCreationError(event){errorInfo=event.statusMessage||errorInfo}var ctx,errorInfo="?";try{if(useWebGL){var contextAttributes={antialias:!1,alpha:!1};if(webGLContextAttributes)for(var attribute in webGLContextAttributes)contextAttributes[attribute]=webGLContextAttributes[attribute];canvas.addEventListener("webglcontextcreationerror",onContextCreationError,!1);try{["experimental-webgl","webgl"].some(function(webglId){return ctx=canvas.getContext(webglId,contextAttributes)})}finally{canvas.removeEventListener("webglcontextcreationerror",onContextCreationError,!1)}}else ctx=canvas.getContext("2d");if(!ctx)throw":("}catch(e){return Module.print("Could not create canvas: "+[errorInfo,e]),null}return useWebGL&&(canvas.style.backgroundColor="black",canvas.addEventListener("webglcontextlost",function(){alert("WebGL context lost. You will need to reload the page.")},!1)),setInModule&&(GLctx=Module.ctx=ctx,Module.useWebGL=useWebGL,Browser.moduleContextCreatedCallbacks.forEach(function(callback){callback()}),Browser.init()),ctx},destroyContext:function(){},fullScreenHandlersInstalled:!1,lockPointer:void 0,resizeCanvas:void 0,requestFullScreen:function(lockPointer,resizeCanvas){function fullScreenChange(){if(Browser.isFullScreen=!1,(document.webkitFullScreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.mozFullscreenElement||document.fullScreenElement||document.fullscreenElement||document.msFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement)===canvasContainer)canvas.cancelFullScreen=document.cancelFullScreen||document.mozCancelFullScreen||document.webkitCancelFullScreen||document.msExitFullscreen||document.exitFullscreen||function(){},canvas.cancelFullScreen=canvas.cancelFullScreen.bind(document),Browser.lockPointer&&canvas.requestPointerLock(),Browser.isFullScreen=!0,Browser.resizeCanvas&&Browser.setFullScreenCanvasSize();else{var canvasContainer=canvas.parentNode;canvasContainer.parentNode.insertBefore(canvas,canvasContainer),canvasContainer.parentNode.removeChild(canvasContainer),Browser.resizeCanvas&&Browser.setWindowedCanvasSize()}Module.onFullScreen&&Module.onFullScreen(Browser.isFullScreen),Browser.updateCanvasDimensions(canvas)}Browser.lockPointer=lockPointer,Browser.resizeCanvas=resizeCanvas,"undefined"==typeof Browser.lockPointer&&(Brow
\ No newline at end of file
Module.stringToUTF16=stringToUTF16,Module.UTF32ToString=UTF32ToString,Module.stringToUTF32=stringToUTF32;for(var PAGE_SIZE=4096,HEAP,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64,STATIC_BASE=0,STATICTOP=0,staticSealed=!1,STACK_BASE=0,STACKTOP=0,STACK_MAX=0,DYNAMIC_BASE=0,DYNAMICTOP=0,TOTAL_STACK=Module.TOTAL_STACK||5242880,TOTAL_MEMORY=Module.TOTAL_MEMORY||268435456,FAST_MEMORY=Module.FAST_MEMORY||2097152,totalMemory=4096;TOTAL_MEMORY>totalMemory||2*TOTAL_STACK>totalMemory;)16777216>totalMemory?totalMemory*=2:totalMemory+=16777216;totalMemory!==TOTAL_MEMORY&&(Module.printErr("increasing TOTAL_MEMORY to "+totalMemory+" to be more reasonable"),TOTAL_MEMORY=totalMemory),assert("undefined"!=typeof Int32Array&&"undefined"!=typeof Float64Array&&!!new Int32Array(1).subarray&&!!new Int32Array(1).set,"JS engine does not provide full typed array support");var buffer=new ArrayBuffer(TOTAL_MEMORY);HEAP8=new Int8Array(buffer),HEAP16=new Int16Array(buffer),HEAP32=new Int32Array(buffer),HEAPU8=new Uint8Array(buffer),HEAPU16=new Uint16Array(buffer),HEAPU32=new Uint32Array(buffer),HEAPF32=new Float32Array(buffer),HEAPF64=new Float64Array(buffer),HEAP32[0]=255,assert(255===HEAPU8[0]&&0===HEAPU8[3],"Typed arrays 2 must be run on a little-endian system"),Module.HEAP=HEAP,Module.HEAP8=HEAP8,Module.HEAP16=HEAP16,Module.HEAP32=HEAP32,Module.HEAPU8=HEAPU8,Module.HEAPU16=HEAPU16,Module.HEAPU32=HEAPU32,Module.HEAPF32=HEAPF32,Module.HEAPF64=HEAPF64;var __ATPRERUN__=[],__ATINIT__=[],__ATMAIN__=[],__ATEXIT__=[],__ATPOSTRUN__=[],runtimeInitialized=!1;Module.addOnPreRun=Module.addOnPreRun=addOnPreRun,Module.addOnInit=Module.addOnInit=addOnInit,Module.addOnPreMain=Module.addOnPreMain=addOnPreMain,Module.addOnExit=Module.addOnExit=addOnExit,Module.addOnPostRun=Module.addOnPostRun=addOnPostRun,Module.intArrayFromString=intArrayFromString,Module.intArrayToString=intArrayToString,Module.writeStringToMemory=writeStringToMemory,Module.writeArrayToMemory=writeArrayToMemory,Module.writeAsciiToMemory=writeAsciiToMemory,Math.imul&&-5===Math.imul(4294967295,5)||(Math.imul=function(a,b){var ah=a>>>16,al=65535&a,bh=b>>>16,bl=65535&b;return al*bl+(ah*bl+al*bh<<16)|0}),Math.imul=Math.imul;var Math_abs=Math.abs,Math_cos=Math.cos,Math_sin=Math.sin,Math_tan=Math.tan,Math_acos=Math.acos,Math_asin=Math.asin,Math_atan=Math.atan,Math_atan2=Math.atan2,Math_exp=Math.exp,Math_log=Math.log,Math_sqrt=Math.sqrt,Math_ceil=Math.ceil,Math_floor=Math.floor,Math_pow=Math.pow,Math_imul=Math.imul,Math_fround=Math.fround,Math_min=Math.min,runDependencies=0,runDependencyWatcher=null,dependenciesFulfilled=null;Module.addRunDependency=addRunDependency,Module.removeRunDependency=removeRunDependency,Module.preloadedImages={},Module.preloadedAudios={};var memoryInitializer=null;STATIC_BASE=8,STATICTOP=STATIC_BASE+Runtime.alignMemory(9235),__ATINIT__.push(),allocate([17,1,0,0,0,0,0,0,34,18,1,1,0,0,0,0,50,34,18,2,0,0,0,0,67,51,34,34,18,18,2,2,83,67,51,35,18,18,2,2,19,35,67,51,99,83,2,2,0,0,101,85,68,68,52,52,35,35,35,35,19,19,19,19,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,249,233,217,200,200,184,184,167,167,167,167,151,151,151,151,134,134,134,134,134,134,134,134,118,118,118,118,118,118,118,118,230,214,198,182,165,165,149,149,132,132,132,132,116,116,116,116,100,100,100,100,84,84,84,84,67,67,67,67,67,67,67,67,51,51,51,51,51,51,51,51,35,35,35,35,35,35,35,35,19,19,19,19,19,19,19,19,3,3,3,3,3,3,3,3,214,182,197,197,165,165,149,149,132,132,132,132,84,84,84,84,68,68,68,68,4,4,4,4,115,115,115,115,115,115,115,115,99,99,99,99,99,99,99,99,51,51,51,51,51,51,51,51,35,35,35,35,35,35,35,35,19,19,19,19,19,19,19,19,197,181,165,5,148,148,116,116,52,52,36,36,131,131,131,131,99,99,99,99,83,83,83,83,67,67,67,67,19,19,19,19,181,149,164,164,132,132,36,36,20,20,4,4,115,115,115,115,99,99,99,99,83,83,83,83,67,67,67,67,51,51,51,51,166,6,21,21,132,132,132,132,147,147,147,147,147,147,147,147,115,115,115,115,115,115,115,115,99,99,99,99,99,99,99,99,83,83,83,83,83,83,83,83,67,67,67,67,67,67,67,67,51,51,51,51,51,51,51,51,35,35,35,35,35,35,35,35,150,6,21,21,116,116,116,116,131,131,131,131,131,131,131,131,99,99,99,99,99,99,
\ No newline at end of file
return splitPathRe.exec(filename).slice(1)},normalizeArray:function(parts,allowAboveRoot){for(var up=0,i=parts.length-1;i>=0;i--){var last=parts[i];"."===last?parts.splice(i,1):".."===last?(parts.splice(i,1),up++):up&&(parts.splice(i,1),up--)}if(allowAboveRoot)for(;up--;up)parts.unshift("..");return parts},normalize:function(path){var isAbsolute="/"===path.charAt(0),trailingSlash="/"===path.substr(-1);return path=PATH.normalizeArray(path.split("/").filter(function(p){return!!p}),!isAbsolute).join("/"),path||isAbsolute||(path="."),path&&trailingSlash&&(path+="/"),(isAbsolute?"/":"")+path},dirname:function(path){var result=PATH.splitPath(path),root=result[0],dir=result[1];return root||dir?(dir&&(dir=dir.substr(0,dir.length-1)),root+dir):"."},basename:function(path){if("/"===path)return"/";var lastSlash=path.lastIndexOf("/");return-1===lastSlash?path:path.substr(lastSlash+1)},extname:function(path){return PATH.splitPath(path)[3]},join:function(){var paths=Array.prototype.slice.call(arguments,0);return PATH.normalize(paths.join("/"))},join2:function(l,r){return PATH.normalize(l+"/"+r)},resolve:function(){for(var resolvedPath="",resolvedAbsolute=!1,i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path=i>=0?arguments[i]:FS.cwd();if("string"!=typeof path)throw new TypeError("Arguments to path.resolve must be strings");path&&(resolvedPath=path+"/"+resolvedPath,resolvedAbsolute="/"===path.charAt(0))}return resolvedPath=PATH.normalizeArray(resolvedPath.split("/").filter(function(p){return!!p}),!resolvedAbsolute).join("/"),(resolvedAbsolute?"/":"")+resolvedPath||"."},relative:function(from,to){function trim(arr){for(var start=0;start<arr.length&&""===arr[start];start++);for(var end=arr.length-1;end>=0&&""===arr[end];end--);return start>end?[]:arr.slice(start,end-start+1)}from=PATH.resolve(from).substr(1),to=PATH.resolve(to).substr(1);for(var fromParts=trim(from.split("/")),toParts=trim(to.split("/")),length=Math.min(fromParts.length,toParts.length),samePartsLength=length,i=0;length>i;i++)if(fromParts[i]!==toParts[i]){samePartsLength=i;break}for(var outputParts=[],i=samePartsLength;i<fromParts.length;i++)outputParts.push("..");return outputParts=outputParts.concat(toParts.slice(samePartsLength)),outputParts.join("/")}},TTY={ttys:[],init:function(){},shutdown:function(){},register:function(dev,ops){TTY.ttys[dev]={input:[],output:[],ops:ops},FS.registerDevice(dev,TTY.stream_ops)},stream_ops:{open:function(stream){var tty=TTY.ttys[stream.node.rdev];if(!tty)throw new FS.ErrnoError(ERRNO_CODES.ENODEV);stream.tty=tty,stream.seekable=!1},close:function(stream){stream.tty.output.length&&stream.tty.ops.put_char(stream.tty,10)},read:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.get_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var bytesRead=0,i=0;length>i;i++){var result;try{result=stream.tty.ops.get_char(stream.tty)}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}if(void 0===result&&0===bytesRead)throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);if(null===result||void 0===result)break;bytesRead++,buffer[offset+i]=result}return bytesRead&&(stream.node.timestamp=Date.now()),bytesRead},write:function(stream,buffer,offset,length){if(!stream.tty||!stream.tty.ops.put_char)throw new FS.ErrnoError(ERRNO_CODES.ENXIO);for(var i=0;length>i;i++)try{stream.tty.ops.put_char(stream.tty,buffer[offset+i])}catch(e){throw new FS.ErrnoError(ERRNO_CODES.EIO)}return length&&(stream.node.timestamp=Date.now()),i}},default_tty_ops:{get_char:function(tty){if(!tty.input.length){var result=null;if(ENVIRONMENT_IS_NODE){if(result=process.stdin.read(),!result)return process.stdin._readableState&&process.stdin._readableState.ended?null:void 0}else"undefined"!=typeof window&&"function"==typeof window.prompt?(result=window.prompt("Input: "),null!==result&&(result+="\n")):"function"==typeof readline&&(result=readline(),null!==result&&(result+="\n"));if(!result)return null;tty.input=intArrayFromString(result,!0)}return tty.input.shift()},put_char:function(tty,val){null===val||10===val?(Module.print(tty.output.join("")),tty.output=[]):tty.output
\ No newline at end of file
-2,6,8,38,8,0,0,6,0,6,16,38,16,70,16,0,0,6,24,38,24,70,24,102,24,6,32,38,32,70,32,102,32,6,40,38,40,70,40,102,40,6,48,38,48,70,48,102,48,6,56,38,56,70,56,102,56,6,64,38,64,70,64,102,64,6,72,38,72,70,72,102,72,6,80,38,80,70,80,102,80,6,88,38,88,70,88,102,88,6,96,38,96,70,96,102,96,6,104,38,104,70,104,102,104,6,112,38,112,70,112,102,112,6,120,38,120,70,120,102,120,6,128,38,128,70,128,102,128,0,0,67,16,2,0,2,0,33,8,33,8,33,8,33,8,103,32,103,32,72,32,40,32,71,24,71,24,39,24,39,24,6,32,6,32,6,32,6,32,6,24,6,24,6,24,6,24,6,16,6,16,6,16,6,16,102,24,102,24,102,24,102,24,38,16,38,16,38,16,38,16,6,8,6,8,6,8,6,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,5,6,7,8,9,10,12,13,15,17,20,22,25,28,32,36,40,45,50,56,63,71,80,90,101,113,127,144,162,182,203,226,255,255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,3,3,3,3,4,4,4,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,14,14,15,15,16,16,17,17,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,0,0,0,0,0,0,0,0,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,1,0,0,1,0,0,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,1,1,2,1,1,2,1,1,2,1,2,3,1,2,3,2,2,3,2,2,4,2,3,4,2,3,4,3,3,5,3,4,6,3,4,6,4,5,7,4,5,8,4,6,9,5,7,10,6,8,11,6,8,13,7,10,14,8,11,16,9,12,18,10,13,20,11,15,23,13,17,25,0,0,0,0,69,82,82,79,82,58,32,37,115,10,0,0,0,0,0,0,66,89,84,69,95,83,84,82,69,65,77,0,0,0,0,0,78,65,76,95,85,78,73,84,0,0,0,0,0,0,0,0,65,67,67,69,83,83,32,85,78,73,84,32,66,79,85,78,68,65,82,89,32,67,72,69,67,75,0,0,0,0,0,0,80,101,110,100,105,110,103,32,97,99,116,105,118,97,116,105,111,110,32,110,111,116,32,99,111,109,112,108,101,116,101,100,0,0,0,0,0,0,0,0,83,69,81,95,80,65,82,65,77,95,83,69,84,0,0,0,80,73,67,95,80,65,82,65,77,95,83,69,84,0,0,0,80,97,114,97,109,32,115,101,116,32,97,99,116,105,118,97,116,105,111,110,0,0,0,0,83,76,73,67,69,95,72,69,65,68,69,82,0,0,0,0,71,97,112,115,32,105,110,32,102,114,97,109,101,32,110,117,109,0,0,0,0,0,0,0,82,101,111,114,100,101,114,105,110,103,0,0,0,0,0,0,83,76,73,67,69,95,68,65,84,65,0,0,0,0,0,0,69,82,82,79,82,58,32,37,115,10,0,0,0,0,0,0,84,82,89,73,78,71,32,84,79,32,77,65,82,75,32,78,79,78,45,65,76,76,79,67,65,84,69,68,32,73,77,65,71,69,0,0,0,0,0,0,3,0,0,0,15,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,3,0,0,0,15,0,0,0,0,0,0,0,5,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,3,0,0,0,15,0,0,0,1,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,3,0,0,0,15,0,0,0,1,0,0,0,10,0,0,0,0,0,0,0,5,0,0,0,4,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,4,0,0,0,1,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,4,0,0,0,1,0,0,0,4,0,0,0,4,0,0,0,0,0,0,0,7,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,0,0,0,0,13,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,4,0,0,0,2,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,4,0,0,0,2,0,0,0,0,0,0,0,13,0,0,0,4,0,0,0,8,0,0,0,4,0,0,0,3,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,9,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,4,0,0,0,9,0,0,0,4,0,0,0,12,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,4,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,4,0,0,0,1,0,0,0,255,0,0,0,4,0,0,0,2,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,2,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,15,0,0,0,2,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,15,0,0,0,2,0,0,0,10,0,0,0,4,0,0,0,5,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,12,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,4,0,0,0,9,0,0,0,255,0,0,0,12,0,0,0,255,0,0,0,2,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0
\ No newline at end of file
+2,6,8,38,8,0,0,6,0,6,16,38,16,70,16,0,0,6,24,38,24,70,24,102,24,6,32,38,32,70,32,102,32,6,40,38,40,70,40,102,40,6,48,38,48,70,48,102,48,6,56,38,56,70,56,102,56,6,64,38,64,70,64,102,64,6,72,38,72,70,72,102,72,6,80,38,80,70,80,102,80,6,88,38,88,70,88,102,88,6,96,38,96,70,96,102,96,6,104,38,104,70,104,102,104,6,112,38,112,70,112,102,112,6,120,38,120,70,120,102,120,6,128,38,128,70,128,102,128,0,0,67,16,2,0,2,0,33,8,33,8,33,8,33,8,103,32,103,32,72,32,40,32,71,24,71,24,39,24,39,24,6,32,6,32,6,32,6,32,6,24,6,24,6,24,6,24,6,16,6,16,6,16,6,16,102,24,102,24,102,24,102,24,38,16,38,16,38,16,38,16,6,8,6,8,6,8,6,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,5,6,7,8,9,10,12,13,15,17,20,22,25,28,32,36,40,45,50,56,63,71,80,90,101,113,127,144,162,182,203,226,255,255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,3,3,3,3,4,4,4,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,14,14,15,15,16,16,17,17,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,0,0,0,0,0,0,0,0,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,1,0,0,1,0,0,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,1,1,2,1,1,2,1,1,2,1,2,3,1,2,3,2,2,3,2,2,4,2,3,4,2,3,4,3,3,5,3,4,6,3,4,6,4,5,7,4,5,8,4,6,9,5,7,10,6,8,11,6,8,13,7,10,14,8,11,16,9,12,18,10,13,20,11,15,23,13,17,25,0,0,0,0,69,82,82,79,82,58,32,37,115,10,0,0,0,0,0,0,66,89,84,69,95,83,84,82,69,65,77,0,0,0,0,0,78,65,76,95,85,78,73,84,0,0,0,0,0,0,0,0,65,67,67,69,83,83,32,85,78,73,84,32,66,79,85,78,68,65,82,89,32,67,72,69,67,75,0,0,0,0,0,0,80,101,110,100,105,110,103,32,97,99,116,105,118,97,116,105,111,110,32,110,111,116,32,99,111,109,112,108,101,116,101,100,0,0,0,0,0,0,0,0,83,69,81,95,80,65,82,65,77,95,83,69,84,0,0,0,80,73,67,95,80,65,82,65,77,95,83,69,84,0,0,0,80,97,114,97,109,32,115,101,116,32,97,99,116,105,118,97,116,105,111,110,0,0,0,0,83,76,73,67,69,95,72,69,65,68,69,82,0,0,0,0,71,97,112,115,32,105,110,32,102,114,97,109,101,32,110,117,109,0,0,0,0,0,0,0,82,101,111,114,100,101,114,105,110,103,0,0,0,0,0,0,83,76,73,67,69,95,68,65,84,65,0,0,0,0,0,0,69,82,82,79,82,58,32,37,115,10,0,0,0,0,0,0,84,82,89,73,78,71,32,84,79,32,77,65,82,75,32,78,79,78,45,65,76,76,79,67,65,84,69,68,32,73,77,65,71,69,0,0,0,0,0,0,3,0,0,0,15,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,3,0,0,0,15,0,0,0,0,0,0,0,5,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,3,0,0,0,15,0,0,0,1,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,3,0,0,0,15,0,0,0,1,0,0,0,10,0,0,0,0,0,0,0,5,0,0,0,4,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,4,0,0,0,1,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,4,0,0,0,1,0,0,0,4,0,0,0,4,0,0,0,0,0,0,0,7,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,0,0,0,0,13,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,4,0,0,0,2,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,0,0,0,0,7,0,0,0,4,0,0,0,2,0,0,0,0,0,0,0,13,0,0,0,4,0,0,0,8,0,0,0,4,0,0,0,3,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,9,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,4,0,0,0,9,0,0,0,4,0,0,0,12,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,4,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,11,0,0,0,1,0,0,0,14,0,0,0,4,0,0,0,1,0,0,0,255,0,0,0,4,0,0,0,2,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,2,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,15,0,0,0,2,0,0,0,10,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,1,0,0,0,15,0,0,0,2,0,0,0,10,0,0,0,4,0,0,0,5,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,12,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,4,0,0,0,3,0,0,0,4,0,0,0,6,0,0,0,4,0,0,0,9,0,0,0,255,0,0,0,12,0,0,0,255,0,0,0,2,0,0,0,255,0,0,0,0,0,0,0,255,0,0,0
\ No newline at end of file
--- a/js/h264bsd_asm.js
+++ b/js/h264bsd_asm.js
@@ -5572,7 +5572,7 @@
rr];
}
}
-itPointerLock = document['exitPointerLock'] ||
+itPointerLock = document['exitPointerLock'] ||
t'] ||
document['fullScreenElement'] || document['fullscreenElement'] ||
document['msFullScreenElement'] || document['msFullscreenElement'] ||
--- a/js/h264bsd_canvas.js
+++ b/js/h264bsd_canvas.js
@@ -155,6 +155,8 @@
var texturePosRef = gl.getAttribLocation(program, 'texturePos');
gl.enableVertexAttribArray(texturePosRef);
gl.vertexAttribPointer(texturePosRef, 2, gl.FLOAT, false, 0, 0);
+
+ this.texturePosBuffer = texturePosBuffer;
}
/**
@@ -215,6 +217,7 @@
*/
H264bsdCanvas.prototype.drawNextOuptutPictureGL = function(decoder) {
var gl = this.contextGL;
+ var texturePosBuffer = this.texturePosBuffer;
var yTextureRef = this.yTextureRef;
var uTextureRef = this.uTextureRef;
var vTextureRef = this.vTextureRef;
@@ -221,8 +224,22 @@
var width = decoder.outputPictureWidth();
var height = decoder.outputPictureHeight();
+ var croppingParams = decoder.croppingParams();
- gl.viewport(0, 0, width, height);
+ if(croppingParams === null) {
+ gl.viewport(0, 0, width, height);
+ } else {
+ gl.viewport(0, 0, croppingParams.width, croppingParams.height);
+
+ var tTop = croppingParams.top / height;
+ var tLeft = croppingParams.left / width;
+ var tBottom = croppingParams.height / height;
+ var tRight = croppingParams.width / width;
+ var texturePosValues = new Float32Array([tRight, tTop, tLeft, tTop, tRight, tBottom, tLeft, tBottom]);
+
+ gl.bindBuffer(gl.ARRAY_BUFFER, texturePosBuffer);
+ gl.bufferData(gl.ARRAY_BUFFER, texturePosValues, gl.DYNAMIC_DRAW);
+ }
var i420Data = decoder.nextOutputPicture();
--- a/js/test.html
+++ b/js/test.html
@@ -37,8 +37,15 @@
// Render for each picture
d.onHeadersReady = function () {
- canvas.width = d.outputPictureWidth();
- canvas.height = d.outputPictureHeight();
+ var croppingParams = d.croppingParams();
+
+ if(croppingParams === null) {
+ canvas.width = d.outputPictureWidth();
+ canvas.height = d.outputPictureHeight();
+ } else {
+ canvas.width = croppingParams.width;
+ canvas.height = croppingParams.height;
+ }
}
// Loop with setTimeout delay to allow UI to update.