js/src/jit-test/lib/bullet.js

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

michael@0 1 // Note: For maximum-speed code, see "Optimizing Code" on the Emscripten wiki, https://github.com/kripken/emscripten/wiki/Optimizing-Code
michael@0 2 // Note: Some Emscripten settings may limit the speed of the generated code.
michael@0 3 // The Module object: Our interface to the outside world. We import
michael@0 4 // and export values on it, and do the work to get that through
michael@0 5 // closure compiler if necessary. There are various ways Module can be used:
michael@0 6 // 1. Not defined. We create it here
michael@0 7 // 2. A function parameter, function(Module) { ..generated code.. }
michael@0 8 // 3. pre-run appended it, var Module = {}; ..generated code..
michael@0 9 // 4. External script tag defines var Module.
michael@0 10 // We need to do an eval in order to handle the closure compiler
michael@0 11 // case, where this code here is minified but Module was defined
michael@0 12 // elsewhere (e.g. case 4 above). We also need to check if Module
michael@0 13 // already exists (e.g. case 3 above).
michael@0 14 // Note that if you want to run closure, and also to use Module
michael@0 15 // after the generated code, you will need to define var Module = {};
michael@0 16 // before the code. Then that object will be used in the code, and you
michael@0 17 // can continue to use Module afterwards as well.
michael@0 18 var Module;
michael@0 19 if (!Module) Module = eval('(function() { try { return Module || {} } catch(e) { return {} } })()');
michael@0 20 // Sometimes an existing Module object exists with properties
michael@0 21 // meant to overwrite the default module functionality. Here
michael@0 22 // we collect those properties and reapply _after_ we configure
michael@0 23 // the current environment's defaults to avoid having to be so
michael@0 24 // defensive during initialization.
michael@0 25 var moduleOverrides = {};
michael@0 26 for (var key in Module) {
michael@0 27 if (Module.hasOwnProperty(key)) {
michael@0 28 moduleOverrides[key] = Module[key];
michael@0 29 }
michael@0 30 }
michael@0 31 // The environment setup code below is customized to use Module.
michael@0 32 // *** Environment setup code ***
michael@0 33 var printedOutput = "";
michael@0 34 Module['print'] = function f(str) {
michael@0 35 printedOutput += str;
michael@0 36 }
michael@0 37 if (typeof printErr != 'undefined') Module['printErr'] = printErr; // not present in v8 or older sm
michael@0 38 if (typeof read != 'undefined') {
michael@0 39 Module['read'] = read;
michael@0 40 } else {
michael@0 41 Module['read'] = function() { throw 'no read() available (jsc?)' };
michael@0 42 }
michael@0 43 Module['readBinary'] = function(f) {
michael@0 44 return read(f, 'binary');
michael@0 45 };
michael@0 46 if (typeof scriptArgs != 'undefined') {
michael@0 47 Module['arguments'] = scriptArgs;
michael@0 48 } else if (typeof arguments != 'undefined') {
michael@0 49 Module['arguments'] = arguments;
michael@0 50 }
michael@0 51 this['Module'] = Module;
michael@0 52 function globalEval(x) {
michael@0 53 eval.call(null, x);
michael@0 54 }
michael@0 55 if (!Module['load'] == 'undefined' && Module['read']) {
michael@0 56 Module['load'] = function(f) {
michael@0 57 globalEval(Module['read'](f));
michael@0 58 };
michael@0 59 }
michael@0 60 if (!Module['printErr']) {
michael@0 61 Module['printErr'] = Module['print'];
michael@0 62 }
michael@0 63 // *** Environment setup code ***
michael@0 64 // Closure helpers
michael@0 65 Module.print = Module['print'];
michael@0 66 Module.printErr = Module['printErr'];
michael@0 67 // Callbacks
michael@0 68 Module['preRun'] = [];
michael@0 69 Module['postRun'] = [];
michael@0 70 // Merge back in the overrides
michael@0 71 for (var key in moduleOverrides) {
michael@0 72 if (moduleOverrides.hasOwnProperty(key)) {
michael@0 73 Module[key] = moduleOverrides[key];
michael@0 74 }
michael@0 75 }
michael@0 76 // === Auto-generated preamble library stuff ===
michael@0 77 //========================================
michael@0 78 // Runtime code shared with compiler
michael@0 79 //========================================
michael@0 80 var Runtime = {
michael@0 81 stackSave: function () {
michael@0 82 return STACKTOP;
michael@0 83 },
michael@0 84 stackRestore: function (stackTop) {
michael@0 85 STACKTOP = stackTop;
michael@0 86 },
michael@0 87 forceAlign: function (target, quantum) {
michael@0 88 quantum = quantum || 4;
michael@0 89 if (quantum == 1) return target;
michael@0 90 if (isNumber(target) && isNumber(quantum)) {
michael@0 91 return Math.ceil(target/quantum)*quantum;
michael@0 92 } else if (isNumber(quantum) && isPowerOfTwo(quantum)) {
michael@0 93 var logg = log2(quantum);
michael@0 94 return '((((' +target + ')+' + (quantum-1) + ')>>' + logg + ')<<' + logg + ')';
michael@0 95 }
michael@0 96 return 'Math.ceil((' + target + ')/' + quantum + ')*' + quantum;
michael@0 97 },
michael@0 98 isNumberType: function (type) {
michael@0 99 return type in Runtime.INT_TYPES || type in Runtime.FLOAT_TYPES;
michael@0 100 },
michael@0 101 isPointerType: function isPointerType(type) {
michael@0 102 return type[type.length-1] == '*';
michael@0 103 },
michael@0 104 isStructType: function isStructType(type) {
michael@0 105 if (isPointerType(type)) return false;
michael@0 106 if (isArrayType(type)) return true;
michael@0 107 if (/<?{ ?[^}]* ?}>?/.test(type)) return true; // { i32, i8 } etc. - anonymous struct types
michael@0 108 // See comment in isStructPointerType()
michael@0 109 return type[0] == '%';
michael@0 110 },
michael@0 111 INT_TYPES: {"i1":0,"i8":0,"i16":0,"i32":0,"i64":0},
michael@0 112 FLOAT_TYPES: {"float":0,"double":0},
michael@0 113 or64: function (x, y) {
michael@0 114 var l = (x | 0) | (y | 0);
michael@0 115 var h = (Math.round(x / 4294967296) | Math.round(y / 4294967296)) * 4294967296;
michael@0 116 return l + h;
michael@0 117 },
michael@0 118 and64: function (x, y) {
michael@0 119 var l = (x | 0) & (y | 0);
michael@0 120 var h = (Math.round(x / 4294967296) & Math.round(y / 4294967296)) * 4294967296;
michael@0 121 return l + h;
michael@0 122 },
michael@0 123 xor64: function (x, y) {
michael@0 124 var l = (x | 0) ^ (y | 0);
michael@0 125 var h = (Math.round(x / 4294967296) ^ Math.round(y / 4294967296)) * 4294967296;
michael@0 126 return l + h;
michael@0 127 },
michael@0 128 getNativeTypeSize: function (type, quantumSize) {
michael@0 129 if (Runtime.QUANTUM_SIZE == 1) return 1;
michael@0 130 var size = {
michael@0 131 '%i1': 1,
michael@0 132 '%i8': 1,
michael@0 133 '%i16': 2,
michael@0 134 '%i32': 4,
michael@0 135 '%i64': 8,
michael@0 136 "%float": 4,
michael@0 137 "%double": 8
michael@0 138 }['%'+type]; // add '%' since float and double confuse Closure compiler as keys, and also spidermonkey as a compiler will remove 's from '_i8' etc
michael@0 139 if (!size) {
michael@0 140 if (type.charAt(type.length-1) == '*') {
michael@0 141 size = Runtime.QUANTUM_SIZE; // A pointer
michael@0 142 } else if (type[0] == 'i') {
michael@0 143 var bits = parseInt(type.substr(1));
michael@0 144 assert(bits % 8 == 0);
michael@0 145 size = bits/8;
michael@0 146 }
michael@0 147 }
michael@0 148 return size;
michael@0 149 },
michael@0 150 getNativeFieldSize: function (type) {
michael@0 151 return Math.max(Runtime.getNativeTypeSize(type), Runtime.QUANTUM_SIZE);
michael@0 152 },
michael@0 153 dedup: function dedup(items, ident) {
michael@0 154 var seen = {};
michael@0 155 if (ident) {
michael@0 156 return items.filter(function(item) {
michael@0 157 if (seen[item[ident]]) return false;
michael@0 158 seen[item[ident]] = true;
michael@0 159 return true;
michael@0 160 });
michael@0 161 } else {
michael@0 162 return items.filter(function(item) {
michael@0 163 if (seen[item]) return false;
michael@0 164 seen[item] = true;
michael@0 165 return true;
michael@0 166 });
michael@0 167 }
michael@0 168 },
michael@0 169 set: function set() {
michael@0 170 var args = typeof arguments[0] === 'object' ? arguments[0] : arguments;
michael@0 171 var ret = {};
michael@0 172 for (var i = 0; i < args.length; i++) {
michael@0 173 ret[args[i]] = 0;
michael@0 174 }
michael@0 175 return ret;
michael@0 176 },
michael@0 177 STACK_ALIGN: 8,
michael@0 178 getAlignSize: function (type, size, vararg) {
michael@0 179 // we align i64s and doubles on 64-bit boundaries, unlike x86
michael@0 180 if (type == 'i64' || type == 'double' || vararg) return 8;
michael@0 181 if (!type) return Math.min(size, 8); // align structures internally to 64 bits
michael@0 182 return Math.min(size || (type ? Runtime.getNativeFieldSize(type) : 0), Runtime.QUANTUM_SIZE);
michael@0 183 },
michael@0 184 calculateStructAlignment: function calculateStructAlignment(type) {
michael@0 185 type.flatSize = 0;
michael@0 186 type.alignSize = 0;
michael@0 187 var diffs = [];
michael@0 188 var prev = -1;
michael@0 189 var index = 0;
michael@0 190 type.flatIndexes = type.fields.map(function(field) {
michael@0 191 index++;
michael@0 192 var size, alignSize;
michael@0 193 if (Runtime.isNumberType(field) || Runtime.isPointerType(field)) {
michael@0 194 size = Runtime.getNativeTypeSize(field); // pack char; char; in structs, also char[X]s.
michael@0 195 alignSize = Runtime.getAlignSize(field, size);
michael@0 196 } else if (Runtime.isStructType(field)) {
michael@0 197 if (field[1] === '0') {
michael@0 198 // this is [0 x something]. When inside another structure like here, it must be at the end,
michael@0 199 // and it adds no size
michael@0 200 // XXX this happens in java-nbody for example... assert(index === type.fields.length, 'zero-length in the middle!');
michael@0 201 size = 0;
michael@0 202 if (Types.types[field]) {
michael@0 203 alignSize = Runtime.getAlignSize(null, Types.types[field].alignSize);
michael@0 204 } else {
michael@0 205 alignSize = type.alignSize || QUANTUM_SIZE;
michael@0 206 }
michael@0 207 } else {
michael@0 208 size = Types.types[field].flatSize;
michael@0 209 alignSize = Runtime.getAlignSize(null, Types.types[field].alignSize);
michael@0 210 }
michael@0 211 } else if (field[0] == 'b') {
michael@0 212 // bN, large number field, like a [N x i8]
michael@0 213 size = field.substr(1)|0;
michael@0 214 alignSize = 1;
michael@0 215 } else {
michael@0 216 throw 'Unclear type in struct: ' + field + ', in ' + type.name_ + ' :: ' + dump(Types.types[type.name_]);
michael@0 217 }
michael@0 218 if (type.packed) alignSize = 1;
michael@0 219 type.alignSize = Math.max(type.alignSize, alignSize);
michael@0 220 var curr = Runtime.alignMemory(type.flatSize, alignSize); // if necessary, place this on aligned memory
michael@0 221 type.flatSize = curr + size;
michael@0 222 if (prev >= 0) {
michael@0 223 diffs.push(curr-prev);
michael@0 224 }
michael@0 225 prev = curr;
michael@0 226 return curr;
michael@0 227 });
michael@0 228 type.flatSize = Runtime.alignMemory(type.flatSize, type.alignSize);
michael@0 229 if (diffs.length == 0) {
michael@0 230 type.flatFactor = type.flatSize;
michael@0 231 } else if (Runtime.dedup(diffs).length == 1) {
michael@0 232 type.flatFactor = diffs[0];
michael@0 233 }
michael@0 234 type.needsFlattening = (type.flatFactor != 1);
michael@0 235 return type.flatIndexes;
michael@0 236 },
michael@0 237 generateStructInfo: function (struct, typeName, offset) {
michael@0 238 var type, alignment;
michael@0 239 if (typeName) {
michael@0 240 offset = offset || 0;
michael@0 241 type = (typeof Types === 'undefined' ? Runtime.typeInfo : Types.types)[typeName];
michael@0 242 if (!type) return null;
michael@0 243 if (type.fields.length != struct.length) {
michael@0 244 printErr('Number of named fields must match the type for ' + typeName + ': possibly duplicate struct names. Cannot return structInfo');
michael@0 245 return null;
michael@0 246 }
michael@0 247 alignment = type.flatIndexes;
michael@0 248 } else {
michael@0 249 var type = { fields: struct.map(function(item) { return item[0] }) };
michael@0 250 alignment = Runtime.calculateStructAlignment(type);
michael@0 251 }
michael@0 252 var ret = {
michael@0 253 __size__: type.flatSize
michael@0 254 };
michael@0 255 if (typeName) {
michael@0 256 struct.forEach(function(item, i) {
michael@0 257 if (typeof item === 'string') {
michael@0 258 ret[item] = alignment[i] + offset;
michael@0 259 } else {
michael@0 260 // embedded struct
michael@0 261 var key;
michael@0 262 for (var k in item) key = k;
michael@0 263 ret[key] = Runtime.generateStructInfo(item[key], type.fields[i], alignment[i]);
michael@0 264 }
michael@0 265 });
michael@0 266 } else {
michael@0 267 struct.forEach(function(item, i) {
michael@0 268 ret[item[1]] = alignment[i];
michael@0 269 });
michael@0 270 }
michael@0 271 return ret;
michael@0 272 },
michael@0 273 dynCall: function (sig, ptr, args) {
michael@0 274 if (args && args.length) {
michael@0 275 if (!args.splice) args = Array.prototype.slice.call(args);
michael@0 276 args.splice(0, 0, ptr);
michael@0 277 return Module['dynCall_' + sig].apply(null, args);
michael@0 278 } else {
michael@0 279 return Module['dynCall_' + sig].call(null, ptr);
michael@0 280 }
michael@0 281 },
michael@0 282 functionPointers: [],
michael@0 283 addFunction: function (func) {
michael@0 284 for (var i = 0; i < Runtime.functionPointers.length; i++) {
michael@0 285 if (!Runtime.functionPointers[i]) {
michael@0 286 Runtime.functionPointers[i] = func;
michael@0 287 return 2 + 2*i;
michael@0 288 }
michael@0 289 }
michael@0 290 throw 'Finished up all reserved function pointers. Use a higher value for RESERVED_FUNCTION_POINTERS.';
michael@0 291 },
michael@0 292 removeFunction: function (index) {
michael@0 293 Runtime.functionPointers[(index-2)/2] = null;
michael@0 294 },
michael@0 295 warnOnce: function (text) {
michael@0 296 if (!Runtime.warnOnce.shown) Runtime.warnOnce.shown = {};
michael@0 297 if (!Runtime.warnOnce.shown[text]) {
michael@0 298 Runtime.warnOnce.shown[text] = 1;
michael@0 299 Module.printErr(text);
michael@0 300 }
michael@0 301 },
michael@0 302 funcWrappers: {},
michael@0 303 getFuncWrapper: function (func, sig) {
michael@0 304 assert(sig);
michael@0 305 if (!Runtime.funcWrappers[func]) {
michael@0 306 Runtime.funcWrappers[func] = function() {
michael@0 307 return Runtime.dynCall(sig, func, arguments);
michael@0 308 };
michael@0 309 }
michael@0 310 return Runtime.funcWrappers[func];
michael@0 311 },
michael@0 312 UTF8Processor: function () {
michael@0 313 var buffer = [];
michael@0 314 var needed = 0;
michael@0 315 this.processCChar = function (code) {
michael@0 316 code = code & 0xFF;
michael@0 317 if (buffer.length == 0) {
michael@0 318 if ((code & 0x80) == 0x00) { // 0xxxxxxx
michael@0 319 return String.fromCharCode(code);
michael@0 320 }
michael@0 321 buffer.push(code);
michael@0 322 if ((code & 0xE0) == 0xC0) { // 110xxxxx
michael@0 323 needed = 1;
michael@0 324 } else if ((code & 0xF0) == 0xE0) { // 1110xxxx
michael@0 325 needed = 2;
michael@0 326 } else { // 11110xxx
michael@0 327 needed = 3;
michael@0 328 }
michael@0 329 return '';
michael@0 330 }
michael@0 331 if (needed) {
michael@0 332 buffer.push(code);
michael@0 333 needed--;
michael@0 334 if (needed > 0) return '';
michael@0 335 }
michael@0 336 var c1 = buffer[0];
michael@0 337 var c2 = buffer[1];
michael@0 338 var c3 = buffer[2];
michael@0 339 var c4 = buffer[3];
michael@0 340 var ret;
michael@0 341 if (buffer.length == 2) {
michael@0 342 ret = String.fromCharCode(((c1 & 0x1F) << 6) | (c2 & 0x3F));
michael@0 343 } else if (buffer.length == 3) {
michael@0 344 ret = String.fromCharCode(((c1 & 0x0F) << 12) | ((c2 & 0x3F) << 6) | (c3 & 0x3F));
michael@0 345 } else {
michael@0 346 // http://mathiasbynens.be/notes/javascript-encoding#surrogate-formulae
michael@0 347 var codePoint = ((c1 & 0x07) << 18) | ((c2 & 0x3F) << 12) |
michael@0 348 ((c3 & 0x3F) << 6) | (c4 & 0x3F);
michael@0 349 ret = String.fromCharCode(
michael@0 350 Math.floor((codePoint - 0x10000) / 0x400) + 0xD800,
michael@0 351 (codePoint - 0x10000) % 0x400 + 0xDC00);
michael@0 352 }
michael@0 353 buffer.length = 0;
michael@0 354 return ret;
michael@0 355 }
michael@0 356 this.processJSString = function(string) {
michael@0 357 string = unescape(encodeURIComponent(string));
michael@0 358 var ret = [];
michael@0 359 for (var i = 0; i < string.length; i++) {
michael@0 360 ret.push(string.charCodeAt(i));
michael@0 361 }
michael@0 362 return ret;
michael@0 363 }
michael@0 364 },
michael@0 365 stackAlloc: function (size) { var ret = STACKTOP;STACKTOP = (STACKTOP + size)|0;STACKTOP = ((((STACKTOP)+7)>>3)<<3); return ret; },
michael@0 366 staticAlloc: function (size) { var ret = STATICTOP;STATICTOP = (STATICTOP + size)|0;STATICTOP = ((((STATICTOP)+7)>>3)<<3); return ret; },
michael@0 367 dynamicAlloc: function (size) { var ret = DYNAMICTOP;DYNAMICTOP = (DYNAMICTOP + size)|0;DYNAMICTOP = ((((DYNAMICTOP)+7)>>3)<<3); if (DYNAMICTOP >= TOTAL_MEMORY) enlargeMemory();; return ret; },
michael@0 368 alignMemory: function (size,quantum) { var ret = size = Math.ceil((size)/(quantum ? quantum : 8))*(quantum ? quantum : 8); return ret; },
michael@0 369 makeBigInt: function (low,high,unsigned) { var ret = (unsigned ? ((+(((low)>>>(0))))+((+(((high)>>>(0))))*(+(4294967296)))) : ((+(((low)>>>(0))))+((+(((high)|(0))))*(+(4294967296))))); return ret; },
michael@0 370 GLOBAL_BASE: 8,
michael@0 371 QUANTUM_SIZE: 4,
michael@0 372 __dummy__: 0
michael@0 373 }
michael@0 374 //========================================
michael@0 375 // Runtime essentials
michael@0 376 //========================================
michael@0 377 var __THREW__ = 0; // Used in checking for thrown exceptions.
michael@0 378 var ABORT = false; // whether we are quitting the application. no code should run after this. set in exit() and abort()
michael@0 379 var EXITSTATUS = 0;
michael@0 380 var undef = 0;
michael@0 381 // tempInt is used for 32-bit signed values or smaller. tempBigInt is used
michael@0 382 // for 32-bit unsigned values or more than 32 bits. TODO: audit all uses of tempInt
michael@0 383 var tempValue, tempInt, tempBigInt, tempInt2, tempBigInt2, tempPair, tempBigIntI, tempBigIntR, tempBigIntS, tempBigIntP, tempBigIntD;
michael@0 384 var tempI64, tempI64b;
michael@0 385 var tempRet0, tempRet1, tempRet2, tempRet3, tempRet4, tempRet5, tempRet6, tempRet7, tempRet8, tempRet9;
michael@0 386 function assert(condition, text) {
michael@0 387 if (!condition) {
michael@0 388 abort('Assertion failed: ' + text);
michael@0 389 }
michael@0 390 }
michael@0 391 var globalScope = this;
michael@0 392 // C calling interface. A convenient way to call C functions (in C files, or
michael@0 393 // defined with extern "C").
michael@0 394 //
michael@0 395 // Note: LLVM optimizations can inline and remove functions, after which you will not be
michael@0 396 // able to call them. Closure can also do so. To avoid that, add your function to
michael@0 397 // the exports using something like
michael@0 398 //
michael@0 399 // -s EXPORTED_FUNCTIONS='["_main", "_myfunc"]'
michael@0 400 //
michael@0 401 // @param ident The name of the C function (note that C++ functions will be name-mangled - use extern "C")
michael@0 402 // @param returnType The return type of the function, one of the JS types 'number', 'string' or 'array' (use 'number' for any C pointer, and
michael@0 403 // 'array' for JavaScript arrays and typed arrays; note that arrays are 8-bit).
michael@0 404 // @param argTypes An array of the types of arguments for the function (if there are no arguments, this can be ommitted). Types are as in returnType,
michael@0 405 // except that 'array' is not possible (there is no way for us to know the length of the array)
michael@0 406 // @param args An array of the arguments to the function, as native JS values (as in returnType)
michael@0 407 // Note that string arguments will be stored on the stack (the JS string will become a C string on the stack).
michael@0 408 // @return The return value, as a native JS value (as in returnType)
michael@0 409 function ccall(ident, returnType, argTypes, args) {
michael@0 410 return ccallFunc(getCFunc(ident), returnType, argTypes, args);
michael@0 411 }
michael@0 412 Module["ccall"] = ccall;
michael@0 413 // Returns the C function with a specified identifier (for C++, you need to do manual name mangling)
michael@0 414 function getCFunc(ident) {
michael@0 415 try {
michael@0 416 var func = Module['_' + ident]; // closure exported function
michael@0 417 if (!func) func = eval('_' + ident); // explicit lookup
michael@0 418 } catch(e) {
michael@0 419 }
michael@0 420 assert(func, 'Cannot call unknown function ' + ident + ' (perhaps LLVM optimizations or closure removed it?)');
michael@0 421 return func;
michael@0 422 }
michael@0 423 // Internal function that does a C call using a function, not an identifier
michael@0 424 function ccallFunc(func, returnType, argTypes, args) {
michael@0 425 var stack = 0;
michael@0 426 function toC(value, type) {
michael@0 427 if (type == 'string') {
michael@0 428 if (value === null || value === undefined || value === 0) return 0; // null string
michael@0 429 if (!stack) stack = Runtime.stackSave();
michael@0 430 var ret = Runtime.stackAlloc(value.length+1);
michael@0 431 writeStringToMemory(value, ret);
michael@0 432 return ret;
michael@0 433 } else if (type == 'array') {
michael@0 434 if (!stack) stack = Runtime.stackSave();
michael@0 435 var ret = Runtime.stackAlloc(value.length);
michael@0 436 writeArrayToMemory(value, ret);
michael@0 437 return ret;
michael@0 438 }
michael@0 439 return value;
michael@0 440 }
michael@0 441 function fromC(value, type) {
michael@0 442 if (type == 'string') {
michael@0 443 return Pointer_stringify(value);
michael@0 444 }
michael@0 445 assert(type != 'array');
michael@0 446 return value;
michael@0 447 }
michael@0 448 var i = 0;
michael@0 449 var cArgs = args ? args.map(function(arg) {
michael@0 450 return toC(arg, argTypes[i++]);
michael@0 451 }) : [];
michael@0 452 var ret = fromC(func.apply(null, cArgs), returnType);
michael@0 453 if (stack) Runtime.stackRestore(stack);
michael@0 454 return ret;
michael@0 455 }
michael@0 456 // Returns a native JS wrapper for a C function. This is similar to ccall, but
michael@0 457 // returns a function you can call repeatedly in a normal way. For example:
michael@0 458 //
michael@0 459 // var my_function = cwrap('my_c_function', 'number', ['number', 'number']);
michael@0 460 // alert(my_function(5, 22));
michael@0 461 // alert(my_function(99, 12));
michael@0 462 //
michael@0 463 function cwrap(ident, returnType, argTypes) {
michael@0 464 var func = getCFunc(ident);
michael@0 465 return function() {
michael@0 466 return ccallFunc(func, returnType, argTypes, Array.prototype.slice.call(arguments));
michael@0 467 }
michael@0 468 }
michael@0 469 Module["cwrap"] = cwrap;
michael@0 470 // Sets a value in memory in a dynamic way at run-time. Uses the
michael@0 471 // type data. This is the same as makeSetValue, except that
michael@0 472 // makeSetValue is done at compile-time and generates the needed
michael@0 473 // code then, whereas this function picks the right code at
michael@0 474 // run-time.
michael@0 475 // Note that setValue and getValue only do *aligned* writes and reads!
michael@0 476 // Note that ccall uses JS types as for defining types, while setValue and
michael@0 477 // getValue need LLVM types ('i8', 'i32') - this is a lower-level operation
michael@0 478 function setValue(ptr, value, type, noSafe) {
michael@0 479 type = type || 'i8';
michael@0 480 if (type.charAt(type.length-1) === '*') type = 'i32'; // pointers are 32-bit
michael@0 481 switch(type) {
michael@0 482 case 'i1': HEAP8[(ptr)]=value; break;
michael@0 483 case 'i8': HEAP8[(ptr)]=value; break;
michael@0 484 case 'i16': HEAP16[((ptr)>>1)]=value; break;
michael@0 485 case 'i32': HEAP32[((ptr)>>2)]=value; break;
michael@0 486 case 'i64': (tempI64 = [value>>>0,(tempDouble=value,(+(Math.abs(tempDouble))) >= (+(1)) ? (tempDouble > (+(0)) ? ((Math.min((+(Math.floor((tempDouble)/(+(4294967296))))), (+(4294967295))))|0)>>>0 : (~~((+(Math.ceil((tempDouble - +(((~~(tempDouble)))>>>0))/(+(4294967296)))))))>>>0) : 0)],HEAP32[((ptr)>>2)]=tempI64[0],HEAP32[(((ptr)+(4))>>2)]=tempI64[1]); break;
michael@0 487 case 'float': HEAPF32[((ptr)>>2)]=value; break;
michael@0 488 case 'double': HEAPF64[((ptr)>>3)]=value; break;
michael@0 489 default: abort('invalid type for setValue: ' + type);
michael@0 490 }
michael@0 491 }
michael@0 492 Module['setValue'] = setValue;
michael@0 493 // Parallel to setValue.
michael@0 494 function getValue(ptr, type, noSafe) {
michael@0 495 type = type || 'i8';
michael@0 496 if (type.charAt(type.length-1) === '*') type = 'i32'; // pointers are 32-bit
michael@0 497 switch(type) {
michael@0 498 case 'i1': return HEAP8[(ptr)];
michael@0 499 case 'i8': return HEAP8[(ptr)];
michael@0 500 case 'i16': return HEAP16[((ptr)>>1)];
michael@0 501 case 'i32': return HEAP32[((ptr)>>2)];
michael@0 502 case 'i64': return HEAP32[((ptr)>>2)];
michael@0 503 case 'float': return HEAPF32[((ptr)>>2)];
michael@0 504 case 'double': return HEAPF64[((ptr)>>3)];
michael@0 505 default: abort('invalid type for setValue: ' + type);
michael@0 506 }
michael@0 507 return null;
michael@0 508 }
michael@0 509 Module['getValue'] = getValue;
michael@0 510 var ALLOC_NORMAL = 0; // Tries to use _malloc()
michael@0 511 var ALLOC_STACK = 1; // Lives for the duration of the current function call
michael@0 512 var ALLOC_STATIC = 2; // Cannot be freed
michael@0 513 var ALLOC_DYNAMIC = 3; // Cannot be freed except through sbrk
michael@0 514 var ALLOC_NONE = 4; // Do not allocate
michael@0 515 Module['ALLOC_NORMAL'] = ALLOC_NORMAL;
michael@0 516 Module['ALLOC_STACK'] = ALLOC_STACK;
michael@0 517 Module['ALLOC_STATIC'] = ALLOC_STATIC;
michael@0 518 Module['ALLOC_DYNAMIC'] = ALLOC_DYNAMIC;
michael@0 519 Module['ALLOC_NONE'] = ALLOC_NONE;
michael@0 520 // allocate(): This is for internal use. You can use it yourself as well, but the interface
michael@0 521 // is a little tricky (see docs right below). The reason is that it is optimized
michael@0 522 // for multiple syntaxes to save space in generated code. So you should
michael@0 523 // normally not use allocate(), and instead allocate memory using _malloc(),
michael@0 524 // initialize it with setValue(), and so forth.
michael@0 525 // @slab: An array of data, or a number. If a number, then the size of the block to allocate,
michael@0 526 // in *bytes* (note that this is sometimes confusing: the next parameter does not
michael@0 527 // affect this!)
michael@0 528 // @types: Either an array of types, one for each byte (or 0 if no type at that position),
michael@0 529 // or a single type which is used for the entire block. This only matters if there
michael@0 530 // is initial data - if @slab is a number, then this does not matter at all and is
michael@0 531 // ignored.
michael@0 532 // @allocator: How to allocate memory, see ALLOC_*
michael@0 533 function allocate(slab, types, allocator, ptr) {
michael@0 534 var zeroinit, size;
michael@0 535 if (typeof slab === 'number') {
michael@0 536 zeroinit = true;
michael@0 537 size = slab;
michael@0 538 } else {
michael@0 539 zeroinit = false;
michael@0 540 size = slab.length;
michael@0 541 }
michael@0 542 var singleType = typeof types === 'string' ? types : null;
michael@0 543 var ret;
michael@0 544 if (allocator == ALLOC_NONE) {
michael@0 545 ret = ptr;
michael@0 546 } else {
michael@0 547 ret = [_malloc, Runtime.stackAlloc, Runtime.staticAlloc, Runtime.dynamicAlloc][allocator === undefined ? ALLOC_STATIC : allocator](Math.max(size, singleType ? 1 : types.length));
michael@0 548 }
michael@0 549 if (zeroinit) {
michael@0 550 var ptr = ret, stop;
michael@0 551 assert((ret & 3) == 0);
michael@0 552 stop = ret + (size & ~3);
michael@0 553 for (; ptr < stop; ptr += 4) {
michael@0 554 HEAP32[((ptr)>>2)]=0;
michael@0 555 }
michael@0 556 stop = ret + size;
michael@0 557 while (ptr < stop) {
michael@0 558 HEAP8[((ptr++)|0)]=0;
michael@0 559 }
michael@0 560 return ret;
michael@0 561 }
michael@0 562 if (singleType === 'i8') {
michael@0 563 if (slab.subarray || slab.slice) {
michael@0 564 HEAPU8.set(slab, ret);
michael@0 565 } else {
michael@0 566 HEAPU8.set(new Uint8Array(slab), ret);
michael@0 567 }
michael@0 568 return ret;
michael@0 569 }
michael@0 570 var i = 0, type, typeSize, previousType;
michael@0 571 while (i < size) {
michael@0 572 var curr = slab[i];
michael@0 573 if (typeof curr === 'function') {
michael@0 574 curr = Runtime.getFunctionIndex(curr);
michael@0 575 }
michael@0 576 type = singleType || types[i];
michael@0 577 if (type === 0) {
michael@0 578 i++;
michael@0 579 continue;
michael@0 580 }
michael@0 581 if (type == 'i64') type = 'i32'; // special case: we have one i32 here, and one i32 later
michael@0 582 setValue(ret+i, curr, type);
michael@0 583 // no need to look up size unless type changes, so cache it
michael@0 584 if (previousType !== type) {
michael@0 585 typeSize = Runtime.getNativeTypeSize(type);
michael@0 586 previousType = type;
michael@0 587 }
michael@0 588 i += typeSize;
michael@0 589 }
michael@0 590 return ret;
michael@0 591 }
michael@0 592 Module['allocate'] = allocate;
michael@0 593 function Pointer_stringify(ptr, /* optional */ length) {
michael@0 594 // TODO: use TextDecoder
michael@0 595 // Find the length, and check for UTF while doing so
michael@0 596 var hasUtf = false;
michael@0 597 var t;
michael@0 598 var i = 0;
michael@0 599 while (1) {
michael@0 600 t = HEAPU8[(((ptr)+(i))|0)];
michael@0 601 if (t >= 128) hasUtf = true;
michael@0 602 else if (t == 0 && !length) break;
michael@0 603 i++;
michael@0 604 if (length && i == length) break;
michael@0 605 }
michael@0 606 if (!length) length = i;
michael@0 607 var ret = '';
michael@0 608 if (!hasUtf) {
michael@0 609 var MAX_CHUNK = 1024; // split up into chunks, because .apply on a huge string can overflow the stack
michael@0 610 var curr;
michael@0 611 while (length > 0) {
michael@0 612 curr = String.fromCharCode.apply(String, HEAPU8.subarray(ptr, ptr + Math.min(length, MAX_CHUNK)));
michael@0 613 ret = ret ? ret + curr : curr;
michael@0 614 ptr += MAX_CHUNK;
michael@0 615 length -= MAX_CHUNK;
michael@0 616 }
michael@0 617 return ret;
michael@0 618 }
michael@0 619 var utf8 = new Runtime.UTF8Processor();
michael@0 620 for (i = 0; i < length; i++) {
michael@0 621 t = HEAPU8[(((ptr)+(i))|0)];
michael@0 622 ret += utf8.processCChar(t);
michael@0 623 }
michael@0 624 return ret;
michael@0 625 }
michael@0 626 Module['Pointer_stringify'] = Pointer_stringify;
michael@0 627 // Given a pointer 'ptr' to a null-terminated UTF16LE-encoded string in the emscripten HEAP, returns
michael@0 628 // a copy of that string as a Javascript String object.
michael@0 629 function UTF16ToString(ptr) {
michael@0 630 var i = 0;
michael@0 631 var str = '';
michael@0 632 while (1) {
michael@0 633 var codeUnit = HEAP16[(((ptr)+(i*2))>>1)];
michael@0 634 if (codeUnit == 0)
michael@0 635 return str;
michael@0 636 ++i;
michael@0 637 // fromCharCode constructs a character from a UTF-16 code unit, so we can pass the UTF16 string right through.
michael@0 638 str += String.fromCharCode(codeUnit);
michael@0 639 }
michael@0 640 }
michael@0 641 Module['UTF16ToString'] = UTF16ToString;
michael@0 642 // Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr',
michael@0 643 // null-terminated and encoded in UTF16LE form. The copy will require at most (str.length*2+1)*2 bytes of space in the HEAP.
michael@0 644 function stringToUTF16(str, outPtr) {
michael@0 645 for(var i = 0; i < str.length; ++i) {
michael@0 646 // charCodeAt returns a UTF-16 encoded code unit, so it can be directly written to the HEAP.
michael@0 647 var codeUnit = str.charCodeAt(i); // possibly a lead surrogate
michael@0 648 HEAP16[(((outPtr)+(i*2))>>1)]=codeUnit
michael@0 649 }
michael@0 650 // Null-terminate the pointer to the HEAP.
michael@0 651 HEAP16[(((outPtr)+(str.length*2))>>1)]=0
michael@0 652 }
michael@0 653 Module['stringToUTF16'] = stringToUTF16;
michael@0 654 // Given a pointer 'ptr' to a null-terminated UTF32LE-encoded string in the emscripten HEAP, returns
michael@0 655 // a copy of that string as a Javascript String object.
michael@0 656 function UTF32ToString(ptr) {
michael@0 657 var i = 0;
michael@0 658 var str = '';
michael@0 659 while (1) {
michael@0 660 var utf32 = HEAP32[(((ptr)+(i*4))>>2)];
michael@0 661 if (utf32 == 0)
michael@0 662 return str;
michael@0 663 ++i;
michael@0 664 // 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.
michael@0 665 if (utf32 >= 0x10000) {
michael@0 666 var ch = utf32 - 0x10000;
michael@0 667 str += String.fromCharCode(0xD800 | (ch >> 10), 0xDC00 | (ch & 0x3FF));
michael@0 668 } else {
michael@0 669 str += String.fromCharCode(utf32);
michael@0 670 }
michael@0 671 }
michael@0 672 }
michael@0 673 Module['UTF32ToString'] = UTF32ToString;
michael@0 674 // Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr',
michael@0 675 // null-terminated and encoded in UTF32LE form. The copy will require at most (str.length+1)*4 bytes of space in the HEAP,
michael@0 676 // but can use less, since str.length does not return the number of characters in the string, but the number of UTF-16 code units in the string.
michael@0 677 function stringToUTF32(str, outPtr) {
michael@0 678 var iChar = 0;
michael@0 679 for(var iCodeUnit = 0; iCodeUnit < str.length; ++iCodeUnit) {
michael@0 680 // 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.
michael@0 681 var codeUnit = str.charCodeAt(iCodeUnit); // possibly a lead surrogate
michael@0 682 if (codeUnit >= 0xD800 && codeUnit <= 0xDFFF) {
michael@0 683 var trailSurrogate = str.charCodeAt(++iCodeUnit);
michael@0 684 codeUnit = 0x10000 + ((codeUnit & 0x3FF) << 10) | (trailSurrogate & 0x3FF);
michael@0 685 }
michael@0 686 HEAP32[(((outPtr)+(iChar*4))>>2)]=codeUnit
michael@0 687 ++iChar;
michael@0 688 }
michael@0 689 // Null-terminate the pointer to the HEAP.
michael@0 690 HEAP32[(((outPtr)+(iChar*4))>>2)]=0
michael@0 691 }
michael@0 692 Module['stringToUTF32'] = stringToUTF32;
michael@0 693 // Memory management
michael@0 694 var PAGE_SIZE = 4096;
michael@0 695 function alignMemoryPage(x) {
michael@0 696 return ((x+4095)>>12)<<12;
michael@0 697 }
michael@0 698 var HEAP;
michael@0 699 var HEAP8, HEAPU8, HEAP16, HEAPU16, HEAP32, HEAPU32, HEAPF32, HEAPF64;
michael@0 700 var STATIC_BASE = 0, STATICTOP = 0, staticSealed = false; // static area
michael@0 701 var STACK_BASE = 0, STACKTOP = 0, STACK_MAX = 0; // stack area
michael@0 702 var DYNAMIC_BASE = 0, DYNAMICTOP = 0; // dynamic area handled by sbrk
michael@0 703 function enlargeMemory() {
michael@0 704 abort('Cannot enlarge memory arrays in asm.js. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value ' + TOTAL_MEMORY + ', or (2) set Module.TOTAL_MEMORY before the program runs.');
michael@0 705 }
michael@0 706 var TOTAL_STACK = Module['TOTAL_STACK'] || 5242880;
michael@0 707 var TOTAL_MEMORY = Module['TOTAL_MEMORY'] || 16777216;
michael@0 708 var FAST_MEMORY = Module['FAST_MEMORY'] || 2097152;
michael@0 709 // Initialize the runtime's memory
michael@0 710 // check for full engine support (use string 'subarray' to avoid closure compiler confusion)
michael@0 711 assert(!!Int32Array && !!Float64Array && !!(new Int32Array(1)['subarray']) && !!(new Int32Array(1)['set']),
michael@0 712 'Cannot fallback to non-typed array case: Code is too specialized');
michael@0 713 var buffer = new ArrayBuffer(TOTAL_MEMORY);
michael@0 714 HEAP8 = new Int8Array(buffer);
michael@0 715 HEAP16 = new Int16Array(buffer);
michael@0 716 HEAP32 = new Int32Array(buffer);
michael@0 717 HEAPU8 = new Uint8Array(buffer);
michael@0 718 HEAPU16 = new Uint16Array(buffer);
michael@0 719 HEAPU32 = new Uint32Array(buffer);
michael@0 720 HEAPF32 = new Float32Array(buffer);
michael@0 721 HEAPF64 = new Float64Array(buffer);
michael@0 722 // Endianness check (note: assumes compiler arch was little-endian)
michael@0 723 HEAP32[0] = 255;
michael@0 724 assert(HEAPU8[0] === 255 && HEAPU8[3] === 0, 'Typed arrays 2 must be run on a little-endian system');
michael@0 725 Module['HEAP'] = HEAP;
michael@0 726 Module['HEAP8'] = HEAP8;
michael@0 727 Module['HEAP16'] = HEAP16;
michael@0 728 Module['HEAP32'] = HEAP32;
michael@0 729 Module['HEAPU8'] = HEAPU8;
michael@0 730 Module['HEAPU16'] = HEAPU16;
michael@0 731 Module['HEAPU32'] = HEAPU32;
michael@0 732 Module['HEAPF32'] = HEAPF32;
michael@0 733 Module['HEAPF64'] = HEAPF64;
michael@0 734 function callRuntimeCallbacks(callbacks) {
michael@0 735 while(callbacks.length > 0) {
michael@0 736 var callback = callbacks.shift();
michael@0 737 if (typeof callback == 'function') {
michael@0 738 callback();
michael@0 739 continue;
michael@0 740 }
michael@0 741 var func = callback.func;
michael@0 742 if (typeof func === 'number') {
michael@0 743 if (callback.arg === undefined) {
michael@0 744 Runtime.dynCall('v', func);
michael@0 745 } else {
michael@0 746 Runtime.dynCall('vi', func, [callback.arg]);
michael@0 747 }
michael@0 748 } else {
michael@0 749 func(callback.arg === undefined ? null : callback.arg);
michael@0 750 }
michael@0 751 }
michael@0 752 }
michael@0 753 var __ATPRERUN__ = []; // functions called before the runtime is initialized
michael@0 754 var __ATINIT__ = []; // functions called during startup
michael@0 755 var __ATMAIN__ = []; // functions called when main() is to be run
michael@0 756 var __ATEXIT__ = []; // functions called during shutdown
michael@0 757 var __ATPOSTRUN__ = []; // functions called after the runtime has exited
michael@0 758 var runtimeInitialized = false;
michael@0 759 function preRun() {
michael@0 760 // compatibility - merge in anything from Module['preRun'] at this time
michael@0 761 if (Module['preRun']) {
michael@0 762 if (typeof Module['preRun'] == 'function') Module['preRun'] = [Module['preRun']];
michael@0 763 while (Module['preRun'].length) {
michael@0 764 addOnPreRun(Module['preRun'].shift());
michael@0 765 }
michael@0 766 }
michael@0 767 callRuntimeCallbacks(__ATPRERUN__);
michael@0 768 }
michael@0 769 function ensureInitRuntime() {
michael@0 770 if (runtimeInitialized) return;
michael@0 771 runtimeInitialized = true;
michael@0 772 callRuntimeCallbacks(__ATINIT__);
michael@0 773 }
michael@0 774 function preMain() {
michael@0 775 callRuntimeCallbacks(__ATMAIN__);
michael@0 776 }
michael@0 777 function exitRuntime() {
michael@0 778 callRuntimeCallbacks(__ATEXIT__);
michael@0 779 }
michael@0 780 function postRun() {
michael@0 781 // compatibility - merge in anything from Module['postRun'] at this time
michael@0 782 if (Module['postRun']) {
michael@0 783 if (typeof Module['postRun'] == 'function') Module['postRun'] = [Module['postRun']];
michael@0 784 while (Module['postRun'].length) {
michael@0 785 addOnPostRun(Module['postRun'].shift());
michael@0 786 }
michael@0 787 }
michael@0 788 callRuntimeCallbacks(__ATPOSTRUN__);
michael@0 789 }
michael@0 790 function addOnPreRun(cb) {
michael@0 791 __ATPRERUN__.unshift(cb);
michael@0 792 }
michael@0 793 Module['addOnPreRun'] = Module.addOnPreRun = addOnPreRun;
michael@0 794 function addOnInit(cb) {
michael@0 795 __ATINIT__.unshift(cb);
michael@0 796 }
michael@0 797 Module['addOnInit'] = Module.addOnInit = addOnInit;
michael@0 798 function addOnPreMain(cb) {
michael@0 799 __ATMAIN__.unshift(cb);
michael@0 800 }
michael@0 801 Module['addOnPreMain'] = Module.addOnPreMain = addOnPreMain;
michael@0 802 function addOnExit(cb) {
michael@0 803 __ATEXIT__.unshift(cb);
michael@0 804 }
michael@0 805 Module['addOnExit'] = Module.addOnExit = addOnExit;
michael@0 806 function addOnPostRun(cb) {
michael@0 807 __ATPOSTRUN__.unshift(cb);
michael@0 808 }
michael@0 809 Module['addOnPostRun'] = Module.addOnPostRun = addOnPostRun;
michael@0 810 // Tools
michael@0 811 // This processes a JS string into a C-line array of numbers, 0-terminated.
michael@0 812 // For LLVM-originating strings, see parser.js:parseLLVMString function
michael@0 813 function intArrayFromString(stringy, dontAddNull, length /* optional */) {
michael@0 814 var ret = (new Runtime.UTF8Processor()).processJSString(stringy);
michael@0 815 if (length) {
michael@0 816 ret.length = length;
michael@0 817 }
michael@0 818 if (!dontAddNull) {
michael@0 819 ret.push(0);
michael@0 820 }
michael@0 821 return ret;
michael@0 822 }
michael@0 823 Module['intArrayFromString'] = intArrayFromString;
michael@0 824 function intArrayToString(array) {
michael@0 825 var ret = [];
michael@0 826 for (var i = 0; i < array.length; i++) {
michael@0 827 var chr = array[i];
michael@0 828 if (chr > 0xFF) {
michael@0 829 chr &= 0xFF;
michael@0 830 }
michael@0 831 ret.push(String.fromCharCode(chr));
michael@0 832 }
michael@0 833 return ret.join('');
michael@0 834 }
michael@0 835 Module['intArrayToString'] = intArrayToString;
michael@0 836 // Write a Javascript array to somewhere in the heap
michael@0 837 function writeStringToMemory(string, buffer, dontAddNull) {
michael@0 838 var array = intArrayFromString(string, dontAddNull);
michael@0 839 var i = 0;
michael@0 840 while (i < array.length) {
michael@0 841 var chr = array[i];
michael@0 842 HEAP8[(((buffer)+(i))|0)]=chr
michael@0 843 i = i + 1;
michael@0 844 }
michael@0 845 }
michael@0 846 Module['writeStringToMemory'] = writeStringToMemory;
michael@0 847 function writeArrayToMemory(array, buffer) {
michael@0 848 for (var i = 0; i < array.length; i++) {
michael@0 849 HEAP8[(((buffer)+(i))|0)]=array[i];
michael@0 850 }
michael@0 851 }
michael@0 852 Module['writeArrayToMemory'] = writeArrayToMemory;
michael@0 853 function unSign(value, bits, ignore, sig) {
michael@0 854 if (value >= 0) {
michael@0 855 return value;
michael@0 856 }
michael@0 857 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
michael@0 858 : Math.pow(2, bits) + value;
michael@0 859 }
michael@0 860 function reSign(value, bits, ignore, sig) {
michael@0 861 if (value <= 0) {
michael@0 862 return value;
michael@0 863 }
michael@0 864 var half = bits <= 32 ? Math.abs(1 << (bits-1)) // abs is needed if bits == 32
michael@0 865 : Math.pow(2, bits-1);
michael@0 866 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
michael@0 867 // but, in general there is no perfect solution here. With 64-bit ints, we get rounding and errors
michael@0 868 // TODO: In i64 mode 1, resign the two parts separately and safely
michael@0 869 value = -2*half + value; // Cannot bitshift half, as it may be at the limit of the bits JS uses in bitshifts
michael@0 870 }
michael@0 871 return value;
michael@0 872 }
michael@0 873 if (!Math['imul']) Math['imul'] = function(a, b) {
michael@0 874 var ah = a >>> 16;
michael@0 875 var al = a & 0xffff;
michael@0 876 var bh = b >>> 16;
michael@0 877 var bl = b & 0xffff;
michael@0 878 return (al*bl + ((ah*bl + al*bh) << 16))|0;
michael@0 879 };
michael@0 880 Math.imul = Math['imul'];
michael@0 881 // A counter of dependencies for calling run(). If we need to
michael@0 882 // do asynchronous work before running, increment this and
michael@0 883 // decrement it. Incrementing must happen in a place like
michael@0 884 // PRE_RUN_ADDITIONS (used by emcc to add file preloading).
michael@0 885 // Note that you can add dependencies in preRun, even though
michael@0 886 // it happens right before run - run will be postponed until
michael@0 887 // the dependencies are met.
michael@0 888 var runDependencies = 0;
michael@0 889 var runDependencyTracking = {};
michael@0 890 var calledInit = false, calledRun = false;
michael@0 891 var runDependencyWatcher = null;
michael@0 892 function addRunDependency(id) {
michael@0 893 runDependencies++;
michael@0 894 if (Module['monitorRunDependencies']) {
michael@0 895 Module['monitorRunDependencies'](runDependencies);
michael@0 896 }
michael@0 897 if (id) {
michael@0 898 assert(!runDependencyTracking[id]);
michael@0 899 runDependencyTracking[id] = 1;
michael@0 900 } else {
michael@0 901 Module.printErr('warning: run dependency added without ID');
michael@0 902 }
michael@0 903 }
michael@0 904 Module['addRunDependency'] = addRunDependency;
michael@0 905 function removeRunDependency(id) {
michael@0 906 runDependencies--;
michael@0 907 if (Module['monitorRunDependencies']) {
michael@0 908 Module['monitorRunDependencies'](runDependencies);
michael@0 909 }
michael@0 910 if (id) {
michael@0 911 assert(runDependencyTracking[id]);
michael@0 912 delete runDependencyTracking[id];
michael@0 913 } else {
michael@0 914 Module.printErr('warning: run dependency removed without ID');
michael@0 915 }
michael@0 916 if (runDependencies == 0) {
michael@0 917 if (runDependencyWatcher !== null) {
michael@0 918 clearInterval(runDependencyWatcher);
michael@0 919 runDependencyWatcher = null;
michael@0 920 }
michael@0 921 // If run has never been called, and we should call run (INVOKE_RUN is true, and Module.noInitialRun is not false)
michael@0 922 if (!calledRun) run();
michael@0 923 }
michael@0 924 }
michael@0 925 Module['removeRunDependency'] = removeRunDependency;
michael@0 926 Module["preloadedImages"] = {}; // maps url to image data
michael@0 927 Module["preloadedAudios"] = {}; // maps url to audio data
michael@0 928 function loadMemoryInitializer(filename) {
michael@0 929 function applyData(data) {
michael@0 930 HEAPU8.set(data, STATIC_BASE);
michael@0 931 }
michael@0 932 // always do this asynchronously, to keep shell and web as similar as possible
michael@0 933 addOnPreRun(function() {
michael@0 934 if (ENVIRONMENT_IS_NODE || ENVIRONMENT_IS_SHELL) {
michael@0 935 applyData(Module['readBinary'](filename));
michael@0 936 } else {
michael@0 937 Browser.asyncLoad(filename, function(data) {
michael@0 938 applyData(data);
michael@0 939 }, function(data) {
michael@0 940 throw 'could not load memory initializer ' + filename;
michael@0 941 });
michael@0 942 }
michael@0 943 });
michael@0 944 }
michael@0 945 // === Body ===
michael@0 946 STATIC_BASE = 8;
michael@0 947 STATICTOP = STATIC_BASE + 14352;
michael@0 948 /* global initializers */ __ATINIT__.push({ func: function() { runPostSets() } },{ func: function() { __GLOBAL__I_a() } });
michael@0 949 var ___dso_handle;
michael@0 950 var __ZTVN10__cxxabiv120__si_class_type_infoE;
michael@0 951 var __ZTVN10__cxxabiv117__class_type_infoE;
michael@0 952 var __ZN23btDiscreteDynamicsWorldC1EP12btDispatcherP21btBroadphaseInterfaceP18btConstraintSolverP24btCollisionConfiguration;
michael@0 953 var __ZN11btRigidBodyC1ERKNS_27btRigidBodyConstructionInfoE;
michael@0 954 var __ZN11btRigidBodyC1EfP13btMotionStateP16btCollisionShapeRK9btVector3;
michael@0 955 var __ZN35btSequentialImpulseConstraintSolverC1Ev;
michael@0 956 var __ZN21btCollisionDispatcherC1EP24btCollisionConfiguration;
michael@0 957 var __ZN27btContinuousConvexCollisionC1EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver;
michael@0 958 var __ZN27btContinuousConvexCollisionC1EPK13btConvexShapePK18btStaticPlaneShape;
michael@0 959 var __ZN16btDbvtBroadphaseC1EP22btOverlappingPairCache;
michael@0 960 var __ZN31btDefaultCollisionConfigurationC1ERK34btDefaultCollisionConstructionInfo;
michael@0 961 var __ZN16btEmptyAlgorithmC1ERK36btCollisionAlgorithmConstructionInfo;
michael@0 962 var __ZN17btGjkPairDetectorC1EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver;
michael@0 963 var __ZN17btGjkPairDetectorC1EPK13btConvexShapeS2_iiffP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver;
michael@0 964 var __ZN16btManifoldResultC1EP17btCollisionObjectS1_;
michael@0 965 var __ZN28btHashedOverlappingPairCacheC1Ev;
michael@0 966 var __ZN25btSimulationIslandManagerC1Ev;
michael@0 967 var __ZN32btSphereSphereCollisionAlgorithmC1EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_;
michael@0 968 var __ZN34btSphereTriangleCollisionAlgorithmC1EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_b;
michael@0 969 var __ZN22btSubsimplexConvexCastC1EPK13btConvexShapeS2_P22btVoronoiSimplexSolver;
michael@0 970 var __ZN11btUnionFindD1Ev;
michael@0 971 var __ZN11btUnionFindC1Ev;
michael@0 972 var __ZN22SphereTriangleDetectorC1EP13btSphereShapeP15btTriangleShapef;
michael@0 973 var __ZN26btBoxBoxCollisionAlgorithmC1EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_;
michael@0 974 var __ZN16btBoxBoxDetectorC1EP10btBoxShapeS1_;
michael@0 975 var __ZN28btCompoundCollisionAlgorithmC1ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b;
michael@0 976 var __ZN33btConvexConcaveCollisionAlgorithmC1ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b;
michael@0 977 var __ZN23btConvexConvexAlgorithm10CreateFuncC1EP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver;
michael@0 978 var __ZN31btConvexPlaneCollisionAlgorithmC1EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_bii;
michael@0 979 var __ZN18btConvexPolyhedronC1Ev;
michael@0 980 var __ZN6btDbvtC1Ev;
michael@0 981 var __ZN6btDbvtD1Ev;
michael@0 982 var __ZN15btGjkConvexCastC1EPK13btConvexShapeS2_P22btVoronoiSimplexSolver;
michael@0 983 __ZTVN10__cxxabiv120__si_class_type_infoE=allocate([0,0,0,0,96,42,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], "i8", ALLOC_STATIC);
michael@0 984 __ZTVN10__cxxabiv117__class_type_infoE=allocate([0,0,0,0,112,42,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], "i8", ALLOC_STATIC);
michael@0 985 /* memory initializer */ allocate([0,0,0,64,0,0,0,0,10,215,163,60,0,0,0,0,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,70,108,111,97,116,68,97,116,97,0,0,0,0,0,0,99,111,110,118,101,120,83,119,101,101,112,84,101,115,116,0,67,67,68,32,109,111,116,105,111,110,32,99,108,97,109,112,105,110,103,0,0,0,0,0,99,111,110,118,101,120,83,119,101,101,112,67,111,109,112,111,117,110,100,0,0,0,0,0,105,110,116,101,103,114,97,116,101,84,114,97,110,115,102,111,114,109,115,0,0,0,0,0,100,105,115,112,97,116,99,104,65,108,108,67,111,108,108,105,115,105,111,110,80,97,105,114,115,0,0,0,0,0,0,0,99,97,108,99,117,108,97,116,101,83,105,109,117,108,97,116,105,111,110,73,115,108,97,110,100,115,0,0,0,0,0,0,99,97,108,99,117,108,97,116,101,79,118,101,114,108,97,112,112,105,110,103,80,97,105,114,115,0,0,0,0,0,0,0,115,111,108,118,101,67,111,110,115,116,114,97,105,110,116,115,0,0,0,0,0,0,0,0,82,111,111,116,0,0,0,0,112,101,114,102,111,114,109,68,105,115,99,114,101,116,101,67,111,108,108,105,115,105,111,110,68,101,116,101,99,116,105,111,110,0,0,0,0,0,0,0,117,112,100,97,116,101,65,99,116,105,118,97,116,105,111,110,83,116,97,116,101,0,0,0,66,117,108,108,101,116,67,111,108,108,105,115,105,111,110,47,78,97,114,114,111,119,80,104,97,115,101,67,111,108,108,105,115,105,111,110,47,98,116,80,111,108,121,104,101,100,114,97,108,67,111,110,116,97,99,116,67,108,105,112,112,105,110,103,46,99,112,112,0,0,0,0,115,111,108,118,101,71,114,111,117,112,67,97,99,104,101,70,114,105,101,110,100,108,121,83,101,116,117,112,0,0,0,0,117,112,100,97,116,101,65,97,98,98,115,0,0,0,0,0,117,112,100,97,116,101,65,99,116,105,111,110,115,0,0,0,115,116,100,58,58,98,97,100,95,97,108,108,111,99,0,0,84,104,97,110,107,115,46,10,0,0,0,0,0,0,0,0,105,115,108,97,110,100,85,110,105,111,110,70,105,110,100,65,110,100,81,117,105,99,107,83,111,114,116,0,0,0,0,0,105,110,116,101,114,110,97,108,83,105,110,103,108,101,83,116,101,112,83,105,109,117,108,97,116,105,111,110,0,0,0,0,100,49,62,61,48,46,48,102,0,0,0,0,0,0,0,0,115,111,108,118,101,71,114,111,117,112,0,0,0,0,0,0,98,116,82,105,103,105,100,66,111,100,121,70,108,111,97,116,68,97,116,97,0,0,0,0,80,108,101,97,115,101,32,105,110,99,108,117,100,101,32,97,98,111,118,101,32,105,110,102,111,114,109,97,116,105,111,110,44,32,121,111,117,114,32,80,108,97,116,102,111,114,109,44,32,118,101,114,115,105,111,110,32,111,102,32,79,83,46,10,0,0,0,0,0,0,0,0,115,116,101,112,83,105,109,117,108,97,116,105,111,110,0,0,66,111,120,0,0,0,0,0,100,48,62,61,48,46,48,102,0,0,0,0,0,0,0,0,115,111,108,118,101,71,114,111,117,112,67,97,99,104,101,70,114,105,101,110,100,108,121,73,116,101,114,97,116,105,111,110,115,0,0,0,0,0,0,0,83,80,72,69,82,69,0,0,112,114,111,99,101,115,115,73,115,108,97,110,100,115,0,0,98,116,67,111,110,118,101,120,73,110,116,101,114,110,97,108,83,104,97,112,101,68,97,116,97,0,0,0,0,0,0,0,84,114,105,97,110,103,108,101,0,0,0,0,0,0,0,0,112,114,101,100,105,99,116,85,110,99,111,110,115,116,114,97,105,110,116,77,111,116,105,111,110,0,0,0,0,0,0,0,79,118,101,114,102,108,111,119,32,105,110,32,65,65,66,66,44,32,111,98,106,101,99,116,32,114,101,109,111,118,101,100,32,102,114,111,109,32,115,105,109,117,108,97,116,105,111,110,0,0,0,0,0,0,0,0,115,121,110,99,104,114,111,110,105,122,101,77,111,116,105,111,110,83,116,97,116,101,115,0,73,102,32,121,111,117,32,99,97,110,32,114,101,112,114,111,100,117,99,101,32,116,104,105,115,44,32,112,108,101,97,115,101,32,101,109,97,105,108,32,98,117,103,115,64,99,111,110,116,105,110,117,111,117,115,112,104,121,115,105,99,115,46,99,111,109,10,0,0,0,0,0,115,101,97,114,99,104,32,115,112,101,99,117,108,97,116,105,118,101,32,99,111,110,116,97,99,116,115,0,0,0,0,0,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,68,97,116,97,0,0,0,0,97,100,100,83,112,101,99,117,108,97,116,105,118,101,67,111,110,116,97,99,116,115,0,0,100,101,98,117,103,68,114,97,119,87,111,114,108,100,0,0,119,111,114,108,100,32,112,111,115,32,61,32,37,46,50,102,44,37,46,50,102,44,37,46,50,102,10,0,0,0,0,0,98,111,111,108,32,84,101,115,116,83,101,112,65,120,105,115,40,99,111,110,115,116,32,98,116,67,111,110,118,101,120,80,111,108,121,104,101,100,114,111,110,32,38,44,32,99,111,110,115,116,32,98,116,67,111,110,118,101,120,80,111,108,121,104,101,100,114,111,110,32,38,44,32,99,111,110,115,116,32,98,116,84,114,97,110,115,102,111,114,109,32,38,44,32,99,111,110,115,116,32,98,116,84,114,97,110,115,102,111,114,109,32,38,44,32,99,111,110,115,116,32,98,116,86,101,99,116,111,114,51,32,38,44,32,102,108,111,97,116,32,38,41,0,0,0,0,0,0,0,0,0,0,1,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,1,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,40,0,0,20,1,0,0,44,0,0,0,86,0,0,0,4,0,0,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,112,40,0,0,84,0,0,0,42,0,0,0,36,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,40,0,0,90,0,0,0,204,0,0,0,18,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,144,40,0,0,116,1,0,0,90,1,0,0,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,40,0,0,196,0,0,0,104,0,0,0,12,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,176,40,0,0,98,1,0,0,50,1,0,0,26,0,0,0,16,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,40,0,0,8,1,0,0,40,0,0,0,74,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,208,40,0,0,198,0,0,0,56,1,0,0,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,224,40,0,0,4,0,0,0,14,0,0,0,26,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,240,40,0,0,122,0,0,0,30,0,0,0,26,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,41,0,0,236,0,0,0,98,0,0,0,38,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,41,0,0,114,0,0,0,158,0,0,0,10,0,0,0,76,0,0,0,2,0,0,0,32,0,0,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,41,0,0,124,0,0,0,168,0,0,0,40,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,41,0,0,22,0,0,0,184,0,0,0,40,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,41,0,0,64,1,0,0,190,0,0,0,22,0,0,0,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,41,0,0,32,0,0,0,180,0,0,0,66,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,41,0,0,94,1,0,0,240,0,0,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,144,41,0,0,28,0,0,0,20,0,0,0,12,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,41,0,0,228,0,0,0,248,0,0,0,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,176,41,0,0,72,0,0,0,60,0,0,0,14,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,41,0,0,82,1,0,0,92,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,208,41,0,0,112,0,0,0,142,0,0,0,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,224,41,0,0,150,0,0,0,100,1,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,240,41,0,0,48,1,0,0,202,0,0,0,18,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,42,0,0,102,1,0,0,220,0,0,0,24,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,42,0,0,88,1,0,0,30,1,0,0,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,40,42,0,0,34,0,0,0,200,0,0,0,30,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,72,42,0,0,20,0,0,0,34,0,0,0,80,0,0,0,100,0,0,0,126,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,80,42,0,0,6,0,0,0,14,1,0,0,74,0,0,0,214,0,0,0,4,0,0,0,2,0,0,0,32,0,0,0,24,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,152,42,0,0,112,1,0,0,38,0,0,0,56,0,0,0,2,0,0,0,30,0,0,0,162,0,0,0,2,0,0,0,6,0,0,0,2,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,168,42,0,0,156,0,0,0,2,0,0,0,2,0,0,0,16,0,0,0,62,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,184,42,0,0,54,1,0,0,70,1,0,0,24,0,0,0,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,200,42,0,0,52,0,0,0,182,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,216,42,0,0,146,0,0,0,62,1,0,0,26,0,0,0,8,0,0,0,98,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,232,42,0,0,118,1,0,0,6,1,0,0,14,0,0,0,2,0,0,0,110,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,43,0,0,88,0,0,0,224,0,0,0,32,0,0,0,36,0,0,0,40,0,0,0,20,0,0,0,74,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,43,0,0,120,1,0,0,218,0,0,0,20,0,0,0,6,0,0,0,108,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,43,0,0,32,1,0,0,178,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,43,0,0,106,0,0,0,250,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,80,43,0,0,96,1,0,0,174,0,0,0,26,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,43,0,0,144,0,0,0,38,1,0,0,10,0,0,0,22,0,0,0,48,0,0,0,6,0,0,0,24,0,0,0,60,0,0,0,14,0,0,0,14,0,0,0,24,0,0,0,68,0,0,0,62,0,0,0,12,0,0,0,58,0,0,0,36,0,0,0,82,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,112,43,0,0,102,0,0,0,68,1,0,0,4,0,0,0,10,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,43,0,0,10,1,0,0,22,1,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,144,43,0,0,8,0,0,0,252,0,0,0,28,0,0,0,4,0,0,0,60,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,43,0,0,58,1,0,0,26,0,0,0,40,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,176,43,0,0,52,1,0,0,104,1,0,0,22,0,0,0,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,43,0,0,84,1,0,0,238,0,0,0,52,0,0,0,70,0,0,0,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,208,43,0,0,40,1,0,0,74,1,0,0,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,240,43,0,0,80,0,0,0,26,1,0,0,58,0,0,0,60,0,0,0,4,0,0,0,2,0,0,0,2,0,0,0,56,0,0,0,4,0,0,0,2,0,0,0,4,0,0,0,6,0,0,0,34,0,0,0,6,0,0,0,86,0,0,0,38,0,0,0,42,0,0,0,28,0,0,0,38,0,0,0,12,0,0,0,78,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,44,0,0,242,0,0,0,132,0,0,0,96,0,0,0,22,0,0,0,30,0,0,0,86,1,0,0,14,0,0,0,60,0,0,0,70,0,0,0,78,0,0,0,176,0,0,0,50,0,0,0,2,0,0,0,68,0,0,0,40,0,0,0,106,0,0,0,10,0,0,0,38,0,0,0,44,0,0,0,154,0,0,0,42,0,0,0,56,0,0,0,104,0,0,0,70,0,0,0,64,0,0,0,8,0,0,0,34,0,0,0,36,0,0,0,54,0,0,0,210,0,0,0,74,0,0,0,8,0,0,0,26,0,0,0,46,0,0,0,14,0,0,0,10,0,0,0,8,0,0,0,94,0,0,0,94,0,0,0,16,0,0,0,18,0,0,0,62,0,0,0,66,0,0,0,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,44,0,0,66,1,0,0,82,0,0,0,16,0,0,0,12,0,0,0,14,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,44,0,0,48,0,0,0,232,0,0,0,26,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,44,0,0,18,0,0,0,18,1,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,44,0,0,42,1,0,0,110,0,0,0,10,0,0,0,52,0,0,0,2,0,0,0,32,0,0,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,112,44,0,0,4,1,0,0,172,0,0,0,18,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,44,0,0,254,0,0,0,16,1,0,0,28,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,152,44,0,0,186,0,0,0,208,0,0,0,58,0,0,0,60,0,0,0,4,0,0,0,2,0,0,0,2,0,0,0,56,0,0,0,2,0,0,0,2,0,0,0,4,0,0,0,6,0,0,0,34,0,0,0,6,0,0,0,86,0,0,0,38,0,0,0,2,0,0,0,2,0,0,0,38,0,0,0,12,0,0,0,78,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,168,44,0,0,46,1,0,0,36,0,0,0,8,0,0,0,2,0,0,0,12,0,0,0,100,0,0,0,8,0,0,0,16,0,0,0,44,0,0,0,44,0,0,0,16,0,0,0,48,0,0,0,26,0,0,0,70,0,0,0,12,0,0,0,58,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,44,0,0,216,0,0,0,114,1,0,0,20,0,0,0,96,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,208,44,0,0,24,0,0,0,140,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,216,44,0,0,138,0,0,0,2,1,0,0,10,0,0,0,6,0,0,0,2,0,0,0,32,0,0,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,232,44,0,0,136,0,0,0,170,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,248,44,0,0,230,0,0,0,108,1,0,0,10,0,0,0,80,0,0,0,2,0,0,0,32,0,0,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16,45,0,0,54,0,0,0,0,1,0,0,2,0,0,0,92,0,0,0,2,0,0,0,32,0,0,0,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,45,0,0,70,0,0,0,212,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,56,45,0,0,28,1,0,0,60,1,0,0,22,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,72,45,0,0,20,0,0,0,118,0,0,0,24,1,0,0,30,0,0,0,76,0,0,0,22,0,0,0,54,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,80,45,0,0,194,0,0,0,134,0,0,0,68,0,0,0,16,0,0,0,252,255,255,255,80,45,0,0,130,0,0,0,108,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,112,45,0,0,16,0,0,0,222,0,0,0,34,0,0,0,50,0,0,0,12,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,45,0,0,12,0,0,0,110,1,0,0,52,0,0,0,70,0,0,0,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,144,45,0,0,116,0,0,0,160,0,0,0,38,0,0,0,14,0,0,0,88,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,45,0,0,66,0,0,0,188,0,0,0,2,0,0,0,58,0,0,0,12,0,0,0,54,0,0,0,8,0,0,0,12,0,0,0,56,0,0,0,62,0,0,0,68,0,0,0,84,0,0,0,48,0,0,0,76,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,176,45,0,0,128,0,0,0,106,1,0,0,96,0,0,0,22,0,0,0,30,0,0,0,78,0,0,0,14,0,0,0,60,0,0,0,8,0,0,0,24,0,0,0,176,0,0,0,18,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,45,0,0,226,0,0,0,72,1,0,0,36,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,208,45,0,0,166,0,0,0,50,0,0,0,66,0,0,0,60,0,0,0,4,0,0,0,2,0,0,0,2,0,0,0,56,0,0,0,2,0,0,0,18,0,0,0,4,0,0,0,6,0,0,0,34,0,0,0,6,0,0,0,86,0,0,0,38,0,0,0,6,0,0,0,50,0,0,0,38,0,0,0,42,0,0,0,12,0,0,0,2,0,0,0,50,0,0,0,4,0,0,0,20,0,0,0,30,0,0,0,28,0,0,0,6,0,0,0,2,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,224,45,0,0,120,0,0,0,10,0,0,0,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,46,0,0,46,0,0,0,76,1,0,0,10,0,0,0,60,0,0,0,4,0,0,0,2,0,0,0,2,0,0,0,56,0,0,0,6,0,0,0,16,0,0,0,12,0,0,0,2,0,0,0,34,0,0,0,6,0,0,0,86,0,0,0,46,0,0,0,18,0,0,0,34,0,0,0,38,0,0,0,12,0,0,0,78,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,46,0,0,206,0,0,0,78,1,0,0,2,0,0,0,60,0,0,0,4,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,10,0,0,0,14,0,0,0,86,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,56,46,0,0,6,0,0,0,12,1,0,0,34,1,0,0,30,0,0,0,20,0,0,0,18,0,0,0,28,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,72,46,0,0,148,0,0,0,86,0,0,0,48,0,0,0,60,0,0,0,4,0,0,0,2,0,0,0,64,0,0,0,56,0,0,0,8,0,0,0,72,0,0,0,2,0,0,0,6,0,0,0,34,0,0,0,6,0,0,0,86,0,0,0,72,0,0,0,64,0,0,0,46,0,0,0,38,0,0,0,46,0,0,0,8,0,0,0,2,0,0,0,22,0,0,0,38,0,0,0,18,0,0,0,54,0,0,0,52,0,0,0,62,0,0,0,4,0,0,0,28,0,0,0,0,0,0,0,0,0,0,0,90,78,51,51,98,116,77,105,110,107,111,119,115,107,105,80,101,110,101,116,114,97,116,105,111,110,68,101,112,116,104,83,111,108,118,101,114,49,50,99,97,108,99,80,101,110,68,101,112,116,104,69,82,50,50,98,116,86,111,114,111,110,111,105,83,105,109,112,108,101,120,83,111,108,118,101,114,80,75,49,51,98,116,67,111,110,118,101,120,83,104,97,112,101,83,52,95,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,55,95,82,57,98,116,86,101,99,116,111,114,51,83,57,95,83,57,95,80,49,50,98,116,73,68,101,98,117,103,68,114,97,119,80,49,50,98,116,83,116,97,99,107,65,108,108,111,99,69,50,48,98,116,73,110,116,101,114,109,101,100,105,97,116,101,82,101,115,117,108,116,0,0,0,0,0,0,0,90,78,51,51,98,116,67,111,110,118,101,120,67,111,110,99,97,118,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,50,49,99,97,108,99,117,108,97,116,101,84,105,109,101,79,102,73,109,112,97,99,116,69,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,83,49,95,82,75,49,54,98,116,68,105,115,112,97,116,99,104,101,114,73,110,102,111,80,49,54,98,116,77,97,110,105,102,111,108,100,82,101,115,117,108,116,69,51,49,76,111,99,97,108,84,114,105,97,110,103,108,101,83,112,104,101,114,101,67,97,115,116,67,97,108,108,98,97,99,107,0,0,0,90,78,50,56,98,116,72,97,115,104,101,100,79,118,101,114,108,97,112,112,105,110,103,80,97,105,114,67,97,99,104,101,51,55,114,101,109,111,118,101,79,118,101,114,108,97,112,112,105,110,103,80,97,105,114,115,67,111,110,116,97,105,110,105,110,103,80,114,111,120,121,69,80,49,55,98,116,66,114,111,97,100,112,104,97,115,101,80,114,111,120,121,80,49,50,98,116,68,105,115,112,97,116,99,104,101,114,69,49,56,82,101,109,111,118,101,80,97,105,114,67,97,108,108,98,97,99,107,0,0,0,0,0,0,0,0,90,78,50,56,98,116,72,97,115,104,101,100,79,118,101,114,108,97,112,112,105,110,103,80,97,105,114,67,97,99,104,101,49,57,99,108,101,97,110,80,114,111,120,121,70,114,111,109,80,97,105,114,115,69,80,49,55,98,116,66,114,111,97,100,112,104,97,115,101,80,114,111,120,121,80,49,50,98,116,68,105,115,112,97,116,99,104,101,114,69,49,55,67,108,101,97,110,80,97,105,114,67,97,108,108,98,97,99,107,0,0,0,90,78,50,51,98,116,68,105,115,99,114,101,116,101,68,121,110,97,109,105,99,115,87,111,114,108,100,49,54,115,111,108,118,101,67,111,110,115,116,114,97,105,110,116,115,69,82,49,57,98,116,67,111,110,116,97,99,116,83,111,108,118,101,114,73,110,102,111,69,50,55,73,110,112,108,97,99,101,83,111,108,118,101,114,73,115,108,97,110,100,67,97,108,108,98,97,99,107,0,0,0,0,0,0,90,78,50,51,98,116,67,111,110,118,101,120,67,111,110,118,101,120,65,108,103,111,114,105,116,104,109,49,54,112,114,111,99,101,115,115,67,111,108,108,105,115,105,111,110,69,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,83,49,95,82,75,49,54,98,116,68,105,115,112,97,116,99,104,101,114,73,110,102,111,80,49,54,98,116,77,97,110,105,102,111,108,100,82,101,115,117,108,116,69,49,51,98,116,68,117,109,109,121,82,101,115,117,108,116,0,0,0,0,90,78,50,50,98,116,66,118,104,84,114,105,97,110,103,108,101,77,101,115,104,83,104,97,112,101,49,55,112,101,114,102,111,114,109,67,111,110,118,101,120,99,97,115,116,69,80,49,56,98,116,84,114,105,97,110,103,108,101,67,97,108,108,98,97,99,107,82,75,57,98,116,86,101,99,116,111,114,51,83,52,95,83,52,95,83,52,95,69,50,49,77,121,78,111,100,101,79,118,101,114,108,97,112,67,97,108,108,98,97,99,107,0,0,0,0,0,0,0,0,90,78,50,50,98,116,66,118,104,84,114,105,97,110,103,108,101,77,101,115,104,83,104,97,112,101,49,52,112,101,114,102,111,114,109,82,97,121,99,97,115,116,69,80,49,56,98,116,84,114,105,97,110,103,108,101,67,97,108,108,98,97,99,107,82,75,57,98,116,86,101,99,116,111,114,51,83,52,95,69,50,49,77,121,78,111,100,101,79,118,101,114,108,97,112,67,97,108,108,98,97,99,107,0,90,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,55,111,98,106,101,99,116,81,117,101,114,121,83,105,110,103,108,101,69,80,75,49,51,98,116,67,111,110,118,101,120,83,104,97,112,101,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,53,95,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,80,75,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,83,53,95,82,78,83,95,50,48,67,111,110,118,101,120,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,102,69,51,50,66,114,105,100,103,101,84,114,105,97,110,103,108,101,67,111,110,118,101,120,99,97,115,116,67,97,108,108,98,97,99,107,95,48,0,90,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,55,111,98,106,101,99,116,81,117,101,114,121,83,105,110,103,108,101,69,80,75,49,51,98,116,67,111,110,118,101,120,83,104,97,112,101,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,53,95,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,80,75,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,83,53,95,82,78,83,95,50,48,67,111,110,118,101,120,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,102,69,51,50,66,114,105,100,103,101,84,114,105,97,110,103,108,101,67,111,110,118,101,120,99,97,115,116,67,97,108,108,98,97,99,107,0,0,0,90,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,55,111,98,106,101,99,116,81,117,101,114,121,83,105,110,103,108,101,69,80,75,49,51,98,116,67,111,110,118,101,120,83,104,97,112,101,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,53,95,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,80,75,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,83,53,95,82,78,83,95,50,48,67,111,110,118,101,120,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,102,69,49,52,76,111,99,97,108,73,110,102,111,65,100,100,101,114,95,49,0,0,0,90,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,51,114,97,121,84,101,115,116,83,105,110,103,108,101,69,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,50,95,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,80,75,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,83,50,95,82,78,83,95,49,55,82,97,121,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,69,57,82,97,121,84,101,115,116,101,114,95,49,0,0,90,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,51,114,97,121,84,101,115,116,83,105,110,103,108,101,69,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,50,95,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,80,75,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,83,50,95,82,78,83,95,49,55,82,97,121,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,69,50,57,66,114,105,100,103,101,84,114,105,97,110,103,108,101,82,97,121,99,97,115,116,67,97,108,108,98,97,99,107,95,48,0,0,0,0,0,90,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,51,114,97,121,84,101,115,116,83,105,110,103,108,101,69,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,50,95,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,80,75,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,83,50,95,82,78,83,95,49,55,82,97,121,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,69,50,57,66,114,105,100,103,101,84,114,105,97,110,103,108,101,82,97,121,99,97,115,116,67,97,108,108,98,97,99,107,0,0,0,0,0,0,0,90,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,51,114,97,121,84,101,115,116,83,105,110,103,108,101,69,82,75,49,49,98,116,84,114,97,110,115,102,111,114,109,83,50,95,80,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,80,75,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,83,50,95,82,78,83,95,49,55,82,97,121,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,69,49,53,76,111,99,97,108,73,110,102,111,65,100,100,101,114,50,0,0,0,0,0,83,116,57,116,121,112,101,95,105,110,102,111,0,0,0,0,83,116,57,101,120,99,101,112,116,105,111,110,0,0,0,0,83,116,57,98,97,100,95,97,108,108,111,99,0,0,0,0,78,54,98,116,68,98,118,116,56,73,67,111,108,108,105,100,101,69,0,0,0,0,0,0,78,51,54,98,116,68,105,115,99,114,101,116,101,67,111,108,108,105,115,105,111,110,68,101,116,101,99,116,111,114,73,110,116,101,114,102,97,99,101,54,82,101,115,117,108,116,69,0,78,51,52,98,116,83,112,104,101,114,101,84,114,105,97,110,103,108,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,0,0,78,51,51,98,116,67,111,110,118,101,120,67,111,110,99,97,118,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,55,83,119,97,112,112,101,100,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,0,0,0,0,78,51,51,98,116,67,111,110,118,101,120,67,111,110,99,97,118,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,0,0,0,78,51,50,98,116,83,112,104,101,114,101,83,112,104,101,114,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,0,0,0,0,78,51,49,98,116,67,111,110,118,101,120,80,108,97,110,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,78,50,56,98,116,67,111,109,112,111,117,110,100,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,55,83,119,97,112,112,101,100,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,0,78,50,56,98,116,67,111,109,112,111,117,110,100,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,78,50,54,98,116,66,111,120,66,111,120,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,0,0,78,50,53,98,116,83,105,109,117,108,97,116,105,111,110,73,115,108,97,110,100,77,97,110,97,103,101,114,49,52,73,115,108,97,110,100,67,97,108,108,98,97,99,107,69,0,0,0,78,50,51,98,116,67,111,110,118,101,120,67,111,110,118,101,120,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,78,49,54,98,116,69,109,112,116,121,65,108,103,111,114,105,116,104,109,49,48,67,114,101,97,116,101,70,117,110,99,69,0,0,0,0,0,0,0,0,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,50,55,67,108,111,115,101,115,116,67,111,110,118,101,120,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,0,0,0,0,0,0,0,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,50,48,67,111,110,118,101,120,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,0,0,0,0,0,0,78,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,49,55,82,97,121,82,101,115,117,108,116,67,97,108,108,98,97,99,107,69,0,78,49,50,98,116,67,111,110,118,101,120,67,97,115,116,49,48,67,97,115,116,82,101,115,117,108,116,69,0,0,0,0,78,49,48,95,95,99,120,120,97,98,105,118,49,50,49,95,95,118,109,105,95,99,108,97,115,115,95,116,121,112,101,95,105,110,102,111,69,0,0,0,78,49,48,95,95,99,120,120,97,98,105,118,49,50,48,95,95,115,105,95,99,108,97,115,115,95,116,121,112,101,95,105,110,102,111,69,0,0,0,0,78,49,48,95,95,99,120,120,97,98,105,118,49,49,55,95,95,99,108,97,115,115,95,116,121,112,101,95,105,110,102,111,69,0,0,0,0,0,0,0,78,49,48,95,95,99,120,120,97,98,105,118,49,49,54,95,95,115,104,105,109,95,116,121,112,101,95,105,110,102,111,69,0,0,0,0,0,0,0,0,51,54,98,116,68,105,115,99,114,101,116,101,67,111,108,108,105,115,105,111,110,68,101,116,101,99,116,111,114,73,110,116,101,114,102,97,99,101,0,0,51,53,98,116,83,101,113,117,101,110,116,105,97,108,73,109,112,117,108,115,101,67,111,110,115,116,114,97,105,110,116,83,111,108,118,101,114,0,0,0,51,52,98,116,83,112,104,101,114,101,84,114,105,97,110,103,108,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,0,0,51,52,98,116,67,108,111,115,101,115,116,78,111,116,77,101,67,111,110,118,101,120,82,101,115,117,108,116,67,97,108,108,98,97,99,107,0,0,0,0,51,51,98,116,77,105,110,107,111,119,115,107,105,80,101,110,101,116,114,97,116,105,111,110,68,101,112,116,104,83,111,108,118,101,114,0,0,0,0,0,51,51,98,116,67,111,110,118,101,120,67,111,110,99,97,118,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,0,0,0,51,50,98,116,83,112,104,101,114,101,83,112,104,101,114,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,0,0,0,0,51,49,98,116,73,110,116,101,114,110,97,108,84,114,105,97,110,103,108,101,73,110,100,101,120,67,97,108,108,98,97,99,107,0,0,0,0,0,0,0,51,49,98,116,68,101,102,97,117,108,116,67,111,108,108,105,115,105,111,110,67,111,110,102,105,103,117,114,97,116,105,111,110,0,0,0,0,0,0,0,51,49,98,116,67,111,110,118,101,120,80,108,97,110,101,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,0,0,0,0,0,51,48,98,116,71,106,107,69,112,97,80,101,110,101,116,114,97,116,105,111,110,68,101,112,116,104,83,111,108,118,101,114,0,0,0,0,0,0,0,0,51,48,98,116,67,111,110,118,101,120,80,101,110,101,116,114,97,116,105,111,110,68,101,112,116,104,83,111,108,118,101,114,0,0,0,0,0,0,0,0,51,48,98,116,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,67,114,101,97,116,101,70,117,110,99,0,0,0,0,0,0,0,0,51,48,98,116,65,99,116,105,118,97,116,105,110,103,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,0,0,0,0,0,0,50,56,98,116,84,114,105,97,110,103,108,101,67,111,110,118,101,120,99,97,115,116,67,97,108,108,98,97,99,107,0,0,50,56,98,116,72,97,115,104,101,100,79,118,101,114,108,97,112,112,105,110,103,80,97,105,114,67,97,99,104,101,0,0,50,56,98,116,67,111,109,112,111,117,110,100,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,50,55,98,116,67,111,110,116,105,110,117,111,117,115,67,111,110,118,101,120,67,111,108,108,105,115,105,111,110,0,0,0,50,54,98,116,66,111,120,66,111,120,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,0,0,50,53,98,116,84,114,105,97,110,103,108,101,82,97,121,99,97,115,116,67,97,108,108,98,97,99,107,0,0,0,0,0,50,53,98,116,83,105,109,117,108,97,116,105,111,110,73,115,108,97,110,100,77,97,110,97,103,101,114,0,0,0,0,0,50,53,98,116,79,118,101,114,108,97,112,112,105,110,103,80,97,105,114,67,97,108,108,98,97,99,107,0,0,0,0,0,50,52,98,116,80,101,114,116,117,114,98,101,100,67,111,110,116,97,99,116,82,101,115,117,108,116,0,0,0,0,0,0,50,52,98,116,67,111,110,118,101,120,84,114,105,97,110,103,108,101,67,97,108,108,98,97,99,107,0,0,0,0,0,0,50,52,98,116,67,111,108,108,105,115,105,111,110,67,111,110,102,105,103,117,114,97,116,105,111,110,0,0,0,0,0,0,50,52,98,116,66,114,111,97,100,112,104,97,115,101,65,97,98,98,67,97,108,108,98,97,99,107,0,0,0,0,0,0,50,51,98,116,80,111,108,121,104,101,100,114,97,108,67,111,110,118,101,120,83,104,97,112,101,0,0,0,0,0,0,0,50,51,98,116,68,105,115,99,114,101,116,101,68,121,110,97,109,105,99,115,87,111,114,108,100,0,0,0,0,0,0,0,50,51,98,116,67,111,110,118,101,120,67,111,110,118,101,120,65,108,103,111,114,105,116,104,109,0,0,0,0,0,0,0,50,51,98,116,67,111,108,108,105,115,105,111,110,80,97,105,114,67,97,108,108,98,97,99,107,0,0,0,0,0,0,0,50,51,98,116,66,114,111,97,100,112,104,97,115,101,82,97,121,67,97,108,108,98,97,99,107,0,0,0,0,0,0,0,50,50,98,116,83,117,98,115,105,109,112,108,101,120,67,111,110,118,101,120,67,97,115,116,0,0,0,0,0,0,0,0,50,50,98,116,79,118,101,114,108,97,112,112,105,110,103,80,97,105,114,67,97,99,104,101,0,0,0,0,0,0,0,0,50,50,98,116,67,111,109,112,111,117,110,100,76,101,97,102,67,97,108,108,98,97,99,107,0,0,0,0,0,0,0,0,50,50,83,112,104,101,114,101,84,114,105,97,110,103,108,101,68,101,116,101,99,116,111,114,0,0,0,0,0,0,0,0,50,49,98,116,83,105,110,103,108,101,83,119,101,101,112,67,97,108,108,98,97,99,107,0,50,49,98,116,78,111,100,101,79,118,101,114,108,97,112,67,97,108,108,98,97,99,107,0,50,49,98,116,67,111,110,118,101,120,73,110,116,101,114,110,97,108,83,104,97,112,101,0,50,49,98,116,67,111,108,108,105,115,105,111,110,68,105,115,112,97,116,99,104,101,114,0,50,49,98,116,66,114,111,97,100,112,104,97,115,101,73,110,116,101,114,102,97,99,101,0,50,48,98,116,68,101,102,97,117,108,116,77,111,116,105,111,110,83,116,97,116,101,0,0,50,48,98,116,67,111,108,108,105,115,105,111,110,65,108,103,111,114,105,116,104,109,0,0,50,48,66,114,111,97,100,112,104,97,115,101,65,97,98,98,84,101,115,116,101,114,0,0,49,57,98,116,83,105,110,103,108,101,82,97,121,67,97,108,108,98,97,99,107,0,0,0,49,57,66,114,111,97,100,112,104,97,115,101,82,97,121,84,101,115,116,101,114,0,0,0,49,56,98,116,84,114,105,97,110,103,108,101,67,97,108,108,98,97,99,107,0,0,0,0,49,56,98,116,68,98,118,116,84,114,101,101,67,111,108,108,105,100,101,114,0,0,0,0,49,56,98,116,67,111,110,118,101,120,80,111,108,121,104,101,100,114,111,110,0,0,0,0,49,56,98,116,67,111,110,115,116,114,97,105,110,116,83,111,108,118,101,114,0,0,0,0,49,55,98,116,79,118,101,114,108,97,112,67,97,108,108,98,97,99,107,0,0,0,0,0,49,55,98,116,71,106,107,80,97,105,114,68,101,116,101,99,116,111,114,0,0,0,0,0,49,55,98,116,67,111,108,108,105,115,105,111,110,79,98,106,101,99,116,0,0,0,0,0,49,55,68,101,98,117,103,68,114,97,119,99,97,108,108,98,97,99,107,0,0,0,0,0,49,54,98,116,80,111,105,110,116,67,111,108,108,101,99,116,111,114,0,0,0,0,0,0,49,54,98,116,77,97,110,105,102,111,108,100,82,101,115,117,108,116,0,0,0,0,0,0,49,54,98,116,69,109,112,116,121,65,108,103,111,114,105,116,104,109,0,0,0,0,0,0,49,54,98,116,68,98,118,116,66,114,111,97,100,112,104,97,115,101,0,0,0,0,0,0,49,54,98,116,67,111,108,108,105,115,105,111,110,87,111,114,108,100,0,0,0,0,0,0,49,54,98,116,67,111,108,108,105,115,105,111,110,83,104,97,112,101,0,0,0,0,0,0,49,54,98,116,66,111,120,66,111,120,68,101,116,101,99,116,111,114,0,0,0,0,0,0,49,53,98,116,84,114,105,97,110,103,108,101,83,104,97,112,101,0,0,0,0,0,0,0,49,53,98,116,71,106,107,67,111,110,118,101,120,67,97,115,116,0,0,0,0,0,0,0,49,53,98,116,68,121,110,97,109,105,99,115,87,111,114,108,100,0,0,0,0,0,0,0,49,51,98,116,83,112,104,101,114,101,83,104,97,112,101,0,49,51,98,116,77,111,116,105].concat([111,110,83,116,97,116,101,0,49,51,98,116,67,111,110,118,101,120,83,104,97,112,101,0,49,50,98,116,68,105,115,112,97,116,99,104,101,114,0,0,49,50,98,116,67,111,110,118,101,120,67,97,115,116,0,0,49,49,98,116,82,105,103,105,100,66,111,100,121,0,0,0,49,48,98,116,66,111,120,83,104,97,112,101,0,0,0,0,0,0,0,0,248,19,0,0,120,41,0,0,0,0,0,0,0,0,0,0,184,20,0,0,8,45,0,0,0,0,0,0,0,0,0,0,88,21,0,0,48,45,0,0,0,0,0,0,0,0,0,0,224,21,0,0,48,45,0,0,0,0,0,0,0,0,0,0,80,22,0,0,0,42,0,0,0,0,0,0,0,0,0,0,184,22,0,0,120,41,0,0,0,0,0,0,0,0,0,0,56,23,0,0,144,44,0,0,0,0,0,0,0,0,0,0,176,23,0,0,144,44,0,0,0,0,0,0,0,0,0,0,24,24,0,0,80,43,0,0,0,0,0,0,0,0,0,0,208,24,0,0,80,43,0,0,0,0,0,0,0,0,0,0,136,25,0,0,56,42,0,0,0,0,0,0,0,0,0,0,48,26,0,0,112,41,0,0,0,0,0,0,0,0,0,0,184,26,0,0,160,43,0,0,0,0,0,0,0,0,0,0,88,27,0,0,160,43,0,0,0,0,0,0,0,0,0,0,248,27,0,0,64,42,0,0,0,0,0,0,0,0,0,0,136,28,0,0,0,0,0,0,152,28,0,0,0,0,0,0,168,28,0,0,88,41,0,0,0,0,0,0,0,0,0,0,184,28,0,0,0,0,0,0,208,28,0,0,0,0,0,0,0,29,0,0,56,43,0,0,0,0,0,0,0,0,0,0,56,29,0,0,56,43,0,0,0,0,0,0,0,0,0,0,120,29,0,0,56,43,0,0,0,0,0,0,0,0,0,0,176,29,0,0,56,43,0,0,0,0,0,0,0,0,0,0,232,29,0,0,56,43,0,0,0,0,0,0,0,0,0,0,24,30,0,0,56,43,0,0,0,0,0,0,0,0,0,0,80,30,0,0,56,43,0,0,0,0,0,0,0,0,0,0,128,30,0,0,56,43,0,0,0,0,0,0,0,0,0,0,176,30,0,0,0,0,0,0,224,30,0,0,56,43,0,0,0,0,0,0,0,0,0,0,8,31,0,0,56,43,0,0,0,0,0,0,0,0,0,0,48,31,0,0,56,42,0,0,0,0,0,0,0,0,0,0,104,31,0,0,0,0,0,0,152,31,0,0,0,0,0,0,192,31,0,0,0,0,0,0,224,31,0,0,112,42,0,0,0,0,0,0,0,0,0,0,8,32,0,0,112,42,0,0,0,0,0,0,0,0,0,0,48,32,0,0,128,42,0,0,0,0,0,0,0,0,0,0,88,32,0,0,80,41,0,0,0,0,0,0,0,0,0,0,128,32,0,0,0,0,0,0,168,32,0,0,40,45,0,0,0,0,0,0,0,0,0,0,208,32,0,0,64,43,0,0,0,0,0,0,0,0,0,0,248,32,0,0,40,42,0,0,0,0,0,0,0,0,0,0,32,33,0,0,48,43,0,0,0,0,0,0,0,0,0,0,72,33,0,0,64,43,0,0,0,0,0,0,0,0,0,0,112,33,0,0,64,43,0,0,0,0,0,0,0,0,0,0,152,33,0,0,0,0,0,0,192,33,0,0,224,43,0,0,0,0,0,0,0,0,0,0,232,33,0,0,208,44,0,0,0,0,0,0,0,0,0,0,16,34,0,0,48,43,0,0,0,0,0,0,0,0,0,0,56,34,0,0,0,0,0,0,96,34,0,0,0,0,0,0,136,34,0,0,208,44,0,0,0,0,0,0,0,0,0,0,176,34,0,0,8,45,0,0,0,0,0,0,0,0,0,0,208,34,0,0,80,44,0,0,0,0,0,0,0,0,0,0,240,34,0,0,64,43,0,0,0,0,0,0,0,0,0,0,16,35,0,0,48,46,0,0,0,0,0,0,0,0,0,0,48,35,0,0,64,43,0,0,0,0,0,0,0,0,0,0,80,35,0,0,8,45,0,0,0,0,0,0,0,0,0,0,112,35,0,0,0,0,0,0,144,35,0,0,0,0,0,0,176,35,0,0,128,45,0,0,0,0,0,0,0,0,0,0,208,35,0,0,8,45,0,0,0,0,0,0,0,0,0,0,240,35,0,0,0,0,0,0,16,36,0,0,0,0,0,0,48,36,0,0,152,44,0,0,0,0,0,0,0,0,0,0,80,36,0,0,240,45,0,0,0,0,0,0,0,0,0,0,112,36,0,0,64,43,0,0,0,0,0,0,0,0,0,0,144,36,0,0,48,45,0,0,0,0,0,0,0,0,0,0,176,36,0,0,232,43,0,0,0,0,0,0,0,0,0,0,208,36,0,0,48,46,0,0,0,0,0,0,0,0,0,0,240,36,0,0,184,43,0,0,0,0,0,0,0,0,0,0,16,37,0,0,112,41,0,0,0,0,0,0,0,0,0,0,48,37,0,0,144,42,0,0,0,0,0,0,0,0,0,0,80,37,0,0,48,44,0,0,0,0,0,0,0,0,0,0,104,37,0,0,0,0,0,0,128,37,0,0,24,46,0,0,0,0,0,0,0,0,0,0,152,37,0,0,40,46,0,0,0,0,0,0,0,0,0,0,176,37,0,0,0,0,0,0,200,37,0,0,16,46,0,0,0,0,0,0,0,0,0,0,224,37,0,0,0,0,0,0,248,37,0,0,112,41,0,0,0,0,0,0,0,0,0,0,16,38,0,0,48,44,0,0,0,0,0,0,0,0,0,0,40,38,0,0,112,41,0,0,0,0,0,0,0,0,0,0,64,38,0,0,0,0,0,0,88,38,0,0,112,41,0,0,0,0,0,0,0,0,0,0,112,38,0,0,0,0,0,0,136,38,0,0,0,0,0,0,160,38,0,0,0,0,0,0,184,38,0,0,144,42,0,0,0,0,0,0,0,0,0,0,208,38,0,0,16,9,0,0,232,38,0,0,0,0,0,0,2,0,0,0,8,45,0,0,2,0,0,0,248,42,0,0,2,4,0,0,0,0,0,0,0,39,0,0,120,41,0,0,0,0,0,0,0,0,0,0,24,39,0,0,120,41,0,0,0,0,0,0,0,0,0,0,48,39,0,0,208,44,0,0,0,0,0,0,0,0,0,0,72,39,0,0,184,44,0,0,0,0,0,0,0,0,0,0,96,39,0,0,0,0,0,0,120,39,0,0,0,0,0,0,144,39,0,0,144,42,0,0,0,0,0,0,0,0,0,0,168,39,0,0,240,43,0,0,0,0,0,0,0,0,0,0,192,39,0,0,48,46,0,0,0,0,0,0,0,0,0,0,216,39,0,0,176,45,0,0,0,0,0,0,0,0,0,0,240,39,0,0,152,44,0,0,0,0,0,0,0,0,0,0,0,40,0,0,0,0,0,0,16,40,0,0,184,45,0,0,0,0,0,0,0,0,0,0,32,40,0,0,0,0,0,0,48,40,0,0,0,0,0,0,64,40,0,0,72,45,0,0,0,0,0,0,0,0,0,0,80,40,0,0,240,43,0,0,0,0,0,0,176,55,0,0,0,0,0,0,44,1,0,0,0,0,0,0,4,0,0,0,0,0,0,0,164,0,0,0,0,0,0,0,78,0,0,0,0,0,0,0])
michael@0 986 , "i8", ALLOC_NONE, Runtime.GLOBAL_BASE)
michael@0 987 var tempDoublePtr = Runtime.alignMemory(allocate(12, "i8", ALLOC_STATIC), 8);
michael@0 988 assert(tempDoublePtr % 8 == 0);
michael@0 989 function copyTempFloat(ptr) { // functions, because inlining this code increases code size too much
michael@0 990 HEAP8[tempDoublePtr] = HEAP8[ptr];
michael@0 991 HEAP8[tempDoublePtr+1] = HEAP8[ptr+1];
michael@0 992 HEAP8[tempDoublePtr+2] = HEAP8[ptr+2];
michael@0 993 HEAP8[tempDoublePtr+3] = HEAP8[ptr+3];
michael@0 994 }
michael@0 995 function copyTempDouble(ptr) {
michael@0 996 HEAP8[tempDoublePtr] = HEAP8[ptr];
michael@0 997 HEAP8[tempDoublePtr+1] = HEAP8[ptr+1];
michael@0 998 HEAP8[tempDoublePtr+2] = HEAP8[ptr+2];
michael@0 999 HEAP8[tempDoublePtr+3] = HEAP8[ptr+3];
michael@0 1000 HEAP8[tempDoublePtr+4] = HEAP8[ptr+4];
michael@0 1001 HEAP8[tempDoublePtr+5] = HEAP8[ptr+5];
michael@0 1002 HEAP8[tempDoublePtr+6] = HEAP8[ptr+6];
michael@0 1003 HEAP8[tempDoublePtr+7] = HEAP8[ptr+7];
michael@0 1004 }
michael@0 1005 function ___gxx_personality_v0() {
michael@0 1006 }
michael@0 1007 function __exit(status) {
michael@0 1008 // void _exit(int status);
michael@0 1009 // http://pubs.opengroup.org/onlinepubs/000095399/functions/exit.html
michael@0 1010 Module.print('exit(' + status + ') called');
michael@0 1011 Module['exit'](status);
michael@0 1012 }function _exit(status) {
michael@0 1013 __exit(status);
michael@0 1014 }function __ZSt9terminatev() {
michael@0 1015 _exit(-1234);
michael@0 1016 }
michael@0 1017 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:35,EIDRM:36,ECHRNG:37,EL2NSYNC:38,EL3HLT:39,EL3RST:40,ELNRNG:41,EUNATCH:42,ENOCSI:43,EL2HLT:44,EDEADLK:45,ENOLCK:46,EBADE:50,EBADR:51,EXFULL:52,ENOANO:53,EBADRQC:54,EBADSLT:55,EDEADLOCK:56,EBFONT:57,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:74,EDOTDOT:76,EBADMSG:77,ENOTUNIQ:80,EBADFD:81,EREMCHG:82,ELIBACC:83,ELIBBAD:84,ELIBSCN:85,ELIBMAX:86,ELIBEXEC:87,ENOSYS:88,ENOTEMPTY:90,ENAMETOOLONG:91,ELOOP:92,EOPNOTSUPP:95,EPFNOSUPPORT:96,ECONNRESET:104,ENOBUFS:105,EAFNOSUPPORT:106,EPROTOTYPE:107,ENOTSOCK:108,ENOPROTOOPT:109,ESHUTDOWN:110,ECONNREFUSED:111,EADDRINUSE:112,ECONNABORTED:113,ENETUNREACH:114,ENETDOWN:115,ETIMEDOUT:116,EHOSTDOWN:117,EHOSTUNREACH:118,EINPROGRESS:119,EALREADY:120,EDESTADDRREQ:121,EMSGSIZE:122,EPROTONOSUPPORT:123,ESOCKTNOSUPPORT:124,EADDRNOTAVAIL:125,ENETRESET:126,EISCONN:127,ENOTCONN:128,ETOOMANYREFS:129,EUSERS:131,EDQUOT:132,ESTALE:133,ENOTSUP:134,ENOMEDIUM:135,EILSEQ:138,EOVERFLOW:139,ECANCELED:140,ENOTRECOVERABLE:141,EOWNERDEAD:142,ESTRPIPE:143};
michael@0 1018 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:"No message of desired type",36:"Identifier removed",37:"Channel number out of range",38:"Level 2 not synchronized",39:"Level 3 halted",40:"Level 3 reset",41:"Link number out of range",42:"Protocol driver not attached",43:"No CSI structure available",44:"Level 2 halted",45:"Deadlock condition",46:"No record locks available",50:"Invalid exchange",51:"Invalid request descriptor",52:"Exchange full",53:"No anode",54:"Invalid request code",55:"Invalid slot",56:"File locking deadlock error",57:"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",74:"Multihop attempted",76:"Cross mount point (not really error)",77:"Trying to read unreadable message",80:"Given log. name not unique",81:"f.d. invalid for this operation",82:"Remote address changed",83:"Can access a needed shared lib",84:"Accessing a corrupted shared lib",85:".lib section in a.out corrupted",86:"Attempting to link in too many libs",87:"Attempting to exec a shared library",88:"Function not implemented",90:"Directory not empty",91:"File or path name too long",92:"Too many symbolic links",95:"Operation not supported on transport endpoint",96:"Protocol family not supported",104:"Connection reset by peer",105:"No buffer space available",106:"Address family not supported by protocol family",107:"Protocol wrong type for socket",108:"Socket operation on non-socket",109:"Protocol not available",110:"Can't send after socket shutdown",111:"Connection refused",112:"Address already in use",113:"Connection aborted",114:"Network is unreachable",115:"Network interface is not configured",116:"Connection timed out",117:"Host is down",118:"Host is unreachable",119:"Connection already in progress",120:"Socket already connected",121:"Destination address required",122:"Message too long",123:"Unknown protocol",124:"Socket type not supported",125:"Address not available",126:"Connection reset by network",127:"Socket is already connected",128:"Socket is not connected",129:"Too many references",131:"Too many users",132:"Quota exceeded",133:"Stale file handle",134:"Not supported",135:"No medium (in tape drive)",138:"Illegal byte sequence",139:"Value too large for defined data type",140:"Operation canceled",141:"State not recoverable",142:"Previous owner died",143:"Streams pipe error"};
michael@0 1019 var ___errno_state=0;function ___setErrNo(value) {
michael@0 1020 // For convenient setting and returning of errno.
michael@0 1021 HEAP32[((___errno_state)>>2)]=value
michael@0 1022 return value;
michael@0 1023 }
michael@0 1024 var VFS=undefined;
michael@0 1025 var PATH={splitPath:function (filename) {
michael@0 1026 var splitPathRe = /^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;
michael@0 1027 return splitPathRe.exec(filename).slice(1);
michael@0 1028 },normalizeArray:function (parts, allowAboveRoot) {
michael@0 1029 // if the path tries to go above the root, `up` ends up > 0
michael@0 1030 var up = 0;
michael@0 1031 for (var i = parts.length - 1; i >= 0; i--) {
michael@0 1032 var last = parts[i];
michael@0 1033 if (last === '.') {
michael@0 1034 parts.splice(i, 1);
michael@0 1035 } else if (last === '..') {
michael@0 1036 parts.splice(i, 1);
michael@0 1037 up++;
michael@0 1038 } else if (up) {
michael@0 1039 parts.splice(i, 1);
michael@0 1040 up--;
michael@0 1041 }
michael@0 1042 }
michael@0 1043 // if the path is allowed to go above the root, restore leading ..s
michael@0 1044 if (allowAboveRoot) {
michael@0 1045 for (; up--; up) {
michael@0 1046 parts.unshift('..');
michael@0 1047 }
michael@0 1048 }
michael@0 1049 return parts;
michael@0 1050 },normalize:function (path) {
michael@0 1051 var isAbsolute = path.charAt(0) === '/',
michael@0 1052 trailingSlash = path.substr(-1) === '/';
michael@0 1053 // Normalize the path
michael@0 1054 path = PATH.normalizeArray(path.split('/').filter(function(p) {
michael@0 1055 return !!p;
michael@0 1056 }), !isAbsolute).join('/');
michael@0 1057 if (!path && !isAbsolute) {
michael@0 1058 path = '.';
michael@0 1059 }
michael@0 1060 if (path && trailingSlash) {
michael@0 1061 path += '/';
michael@0 1062 }
michael@0 1063 return (isAbsolute ? '/' : '') + path;
michael@0 1064 },dirname:function (path) {
michael@0 1065 var result = PATH.splitPath(path),
michael@0 1066 root = result[0],
michael@0 1067 dir = result[1];
michael@0 1068 if (!root && !dir) {
michael@0 1069 // No dirname whatsoever
michael@0 1070 return '.';
michael@0 1071 }
michael@0 1072 if (dir) {
michael@0 1073 // It has a dirname, strip trailing slash
michael@0 1074 dir = dir.substr(0, dir.length - 1);
michael@0 1075 }
michael@0 1076 return root + dir;
michael@0 1077 },basename:function (path, ext) {
michael@0 1078 // EMSCRIPTEN return '/'' for '/', not an empty string
michael@0 1079 if (path === '/') return '/';
michael@0 1080 var f = PATH.splitPath(path)[2];
michael@0 1081 if (ext && f.substr(-1 * ext.length) === ext) {
michael@0 1082 f = f.substr(0, f.length - ext.length);
michael@0 1083 }
michael@0 1084 return f;
michael@0 1085 },extname:function (path) {
michael@0 1086 return PATH.splitPath(path)[3];
michael@0 1087 },join:function () {
michael@0 1088 var paths = Array.prototype.slice.call(arguments, 0);
michael@0 1089 return PATH.normalize(paths.filter(function(p, index) {
michael@0 1090 if (typeof p !== 'string') {
michael@0 1091 throw new TypeError('Arguments to path.join must be strings');
michael@0 1092 }
michael@0 1093 return p;
michael@0 1094 }).join('/'));
michael@0 1095 },resolve:function () {
michael@0 1096 var resolvedPath = '',
michael@0 1097 resolvedAbsolute = false;
michael@0 1098 for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
michael@0 1099 var path = (i >= 0) ? arguments[i] : FS.cwd();
michael@0 1100 // Skip empty and invalid entries
michael@0 1101 if (typeof path !== 'string') {
michael@0 1102 throw new TypeError('Arguments to path.resolve must be strings');
michael@0 1103 } else if (!path) {
michael@0 1104 continue;
michael@0 1105 }
michael@0 1106 resolvedPath = path + '/' + resolvedPath;
michael@0 1107 resolvedAbsolute = path.charAt(0) === '/';
michael@0 1108 }
michael@0 1109 // At this point the path should be resolved to a full absolute path, but
michael@0 1110 // handle relative paths to be safe (might happen when process.cwd() fails)
michael@0 1111 resolvedPath = PATH.normalizeArray(resolvedPath.split('/').filter(function(p) {
michael@0 1112 return !!p;
michael@0 1113 }), !resolvedAbsolute).join('/');
michael@0 1114 return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.';
michael@0 1115 },relative:function (from, to) {
michael@0 1116 from = PATH.resolve(from).substr(1);
michael@0 1117 to = PATH.resolve(to).substr(1);
michael@0 1118 function trim(arr) {
michael@0 1119 var start = 0;
michael@0 1120 for (; start < arr.length; start++) {
michael@0 1121 if (arr[start] !== '') break;
michael@0 1122 }
michael@0 1123 var end = arr.length - 1;
michael@0 1124 for (; end >= 0; end--) {
michael@0 1125 if (arr[end] !== '') break;
michael@0 1126 }
michael@0 1127 if (start > end) return [];
michael@0 1128 return arr.slice(start, end - start + 1);
michael@0 1129 }
michael@0 1130 var fromParts = trim(from.split('/'));
michael@0 1131 var toParts = trim(to.split('/'));
michael@0 1132 var length = Math.min(fromParts.length, toParts.length);
michael@0 1133 var samePartsLength = length;
michael@0 1134 for (var i = 0; i < length; i++) {
michael@0 1135 if (fromParts[i] !== toParts[i]) {
michael@0 1136 samePartsLength = i;
michael@0 1137 break;
michael@0 1138 }
michael@0 1139 }
michael@0 1140 var outputParts = [];
michael@0 1141 for (var i = samePartsLength; i < fromParts.length; i++) {
michael@0 1142 outputParts.push('..');
michael@0 1143 }
michael@0 1144 outputParts = outputParts.concat(toParts.slice(samePartsLength));
michael@0 1145 return outputParts.join('/');
michael@0 1146 }};
michael@0 1147 var TTY={ttys:[],init:function () {
michael@0 1148 // https://github.com/kripken/emscripten/pull/1555
michael@0 1149 // if (ENVIRONMENT_IS_NODE) {
michael@0 1150 // // currently, FS.init does not distinguish if process.stdin is a file or TTY
michael@0 1151 // // device, it always assumes it's a TTY device. because of this, we're forcing
michael@0 1152 // // process.stdin to UTF8 encoding to at least make stdin reading compatible
michael@0 1153 // // with text files until FS.init can be refactored.
michael@0 1154 // process['stdin']['setEncoding']('utf8');
michael@0 1155 // }
michael@0 1156 },shutdown:function () {
michael@0 1157 // https://github.com/kripken/emscripten/pull/1555
michael@0 1158 // if (ENVIRONMENT_IS_NODE) {
michael@0 1159 // // inolen: any idea as to why node -e 'process.stdin.read()' wouldn't exit immediately (with process.stdin being a tty)?
michael@0 1160 // // 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
michael@0 1161 // // inolen: I thought read() in that case was a synchronous operation that just grabbed some amount of buffered data if it exists?
michael@0 1162 // // isaacs: it is. but it also triggers a _read() call, which calls readStart() on the handle
michael@0 1163 // // isaacs: do process.stdin.pause() and i'd think it'd probably close the pending call
michael@0 1164 // process['stdin']['pause']();
michael@0 1165 // }
michael@0 1166 },register:function (dev, ops) {
michael@0 1167 TTY.ttys[dev] = { input: [], output: [], ops: ops };
michael@0 1168 FS.registerDevice(dev, TTY.stream_ops);
michael@0 1169 },stream_ops:{open:function (stream) {
michael@0 1170 var tty = TTY.ttys[stream.node.rdev];
michael@0 1171 if (!tty) {
michael@0 1172 throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
michael@0 1173 }
michael@0 1174 stream.tty = tty;
michael@0 1175 stream.seekable = false;
michael@0 1176 },close:function (stream) {
michael@0 1177 // flush any pending line data
michael@0 1178 if (stream.tty.output.length) {
michael@0 1179 stream.tty.ops.put_char(stream.tty, 10);
michael@0 1180 }
michael@0 1181 },read:function (stream, buffer, offset, length, pos /* ignored */) {
michael@0 1182 if (!stream.tty || !stream.tty.ops.get_char) {
michael@0 1183 throw new FS.ErrnoError(ERRNO_CODES.ENXIO);
michael@0 1184 }
michael@0 1185 var bytesRead = 0;
michael@0 1186 for (var i = 0; i < length; i++) {
michael@0 1187 var result;
michael@0 1188 try {
michael@0 1189 result = stream.tty.ops.get_char(stream.tty);
michael@0 1190 } catch (e) {
michael@0 1191 throw new FS.ErrnoError(ERRNO_CODES.EIO);
michael@0 1192 }
michael@0 1193 if (result === undefined && bytesRead === 0) {
michael@0 1194 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
michael@0 1195 }
michael@0 1196 if (result === null || result === undefined) break;
michael@0 1197 bytesRead++;
michael@0 1198 buffer[offset+i] = result;
michael@0 1199 }
michael@0 1200 if (bytesRead) {
michael@0 1201 stream.node.timestamp = Date.now();
michael@0 1202 }
michael@0 1203 return bytesRead;
michael@0 1204 },write:function (stream, buffer, offset, length, pos) {
michael@0 1205 if (!stream.tty || !stream.tty.ops.put_char) {
michael@0 1206 throw new FS.ErrnoError(ERRNO_CODES.ENXIO);
michael@0 1207 }
michael@0 1208 for (var i = 0; i < length; i++) {
michael@0 1209 try {
michael@0 1210 stream.tty.ops.put_char(stream.tty, buffer[offset+i]);
michael@0 1211 } catch (e) {
michael@0 1212 throw new FS.ErrnoError(ERRNO_CODES.EIO);
michael@0 1213 }
michael@0 1214 }
michael@0 1215 if (length) {
michael@0 1216 stream.node.timestamp = Date.now();
michael@0 1217 }
michael@0 1218 return i;
michael@0 1219 }},default_tty_ops:{get_char:function (tty) {
michael@0 1220 if (!tty.input.length) {
michael@0 1221 var result = null;
michael@0 1222 if (ENVIRONMENT_IS_NODE) {
michael@0 1223 result = process['stdin']['read']();
michael@0 1224 if (!result) {
michael@0 1225 if (process['stdin']['_readableState'] && process['stdin']['_readableState']['ended']) {
michael@0 1226 return null; // EOF
michael@0 1227 }
michael@0 1228 return undefined; // no data available
michael@0 1229 }
michael@0 1230 } else if (typeof window != 'undefined' &&
michael@0 1231 typeof window.prompt == 'function') {
michael@0 1232 // Browser.
michael@0 1233 result = window.prompt('Input: '); // returns null on cancel
michael@0 1234 if (result !== null) {
michael@0 1235 result += '\n';
michael@0 1236 }
michael@0 1237 } else if (typeof readline == 'function') {
michael@0 1238 // Command line.
michael@0 1239 result = readline();
michael@0 1240 if (result !== null) {
michael@0 1241 result += '\n';
michael@0 1242 }
michael@0 1243 }
michael@0 1244 if (!result) {
michael@0 1245 return null;
michael@0 1246 }
michael@0 1247 tty.input = intArrayFromString(result, true);
michael@0 1248 }
michael@0 1249 return tty.input.shift();
michael@0 1250 },put_char:function (tty, val) {
michael@0 1251 if (val === null || val === 10) {
michael@0 1252 Module['print'](tty.output.join(''));
michael@0 1253 tty.output = [];
michael@0 1254 } else {
michael@0 1255 tty.output.push(TTY.utf8.processCChar(val));
michael@0 1256 }
michael@0 1257 }},default_tty1_ops:{put_char:function (tty, val) {
michael@0 1258 if (val === null || val === 10) {
michael@0 1259 Module['printErr'](tty.output.join(''));
michael@0 1260 tty.output = [];
michael@0 1261 } else {
michael@0 1262 tty.output.push(TTY.utf8.processCChar(val));
michael@0 1263 }
michael@0 1264 }}};
michael@0 1265 var MEMFS={CONTENT_OWNING:1,CONTENT_FLEXIBLE:2,CONTENT_FIXED:3,ensureFlexible:function (node) {
michael@0 1266 if (node.contentMode !== MEMFS.CONTENT_FLEXIBLE) {
michael@0 1267 var contents = node.contents;
michael@0 1268 node.contents = Array.prototype.slice.call(contents);
michael@0 1269 node.contentMode = MEMFS.CONTENT_FLEXIBLE;
michael@0 1270 }
michael@0 1271 },mount:function (mount) {
michael@0 1272 return MEMFS.create_node(null, '/', 0040000 | 0777, 0);
michael@0 1273 },create_node:function (parent, name, mode, dev) {
michael@0 1274 if (FS.isBlkdev(mode) || FS.isFIFO(mode)) {
michael@0 1275 // no supported
michael@0 1276 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 1277 }
michael@0 1278 var node = FS.createNode(parent, name, mode, dev);
michael@0 1279 if (FS.isDir(node.mode)) {
michael@0 1280 node.node_ops = {
michael@0 1281 getattr: MEMFS.node_ops.getattr,
michael@0 1282 setattr: MEMFS.node_ops.setattr,
michael@0 1283 lookup: MEMFS.node_ops.lookup,
michael@0 1284 mknod: MEMFS.node_ops.mknod,
michael@0 1285 mknod: MEMFS.node_ops.mknod,
michael@0 1286 rename: MEMFS.node_ops.rename,
michael@0 1287 unlink: MEMFS.node_ops.unlink,
michael@0 1288 rmdir: MEMFS.node_ops.rmdir,
michael@0 1289 readdir: MEMFS.node_ops.readdir,
michael@0 1290 symlink: MEMFS.node_ops.symlink
michael@0 1291 };
michael@0 1292 node.stream_ops = {
michael@0 1293 llseek: MEMFS.stream_ops.llseek
michael@0 1294 };
michael@0 1295 node.contents = {};
michael@0 1296 } else if (FS.isFile(node.mode)) {
michael@0 1297 node.node_ops = {
michael@0 1298 getattr: MEMFS.node_ops.getattr,
michael@0 1299 setattr: MEMFS.node_ops.setattr
michael@0 1300 };
michael@0 1301 node.stream_ops = {
michael@0 1302 llseek: MEMFS.stream_ops.llseek,
michael@0 1303 read: MEMFS.stream_ops.read,
michael@0 1304 write: MEMFS.stream_ops.write,
michael@0 1305 allocate: MEMFS.stream_ops.allocate,
michael@0 1306 mmap: MEMFS.stream_ops.mmap
michael@0 1307 };
michael@0 1308 node.contents = [];
michael@0 1309 node.contentMode = MEMFS.CONTENT_FLEXIBLE;
michael@0 1310 } else if (FS.isLink(node.mode)) {
michael@0 1311 node.node_ops = {
michael@0 1312 getattr: MEMFS.node_ops.getattr,
michael@0 1313 setattr: MEMFS.node_ops.setattr,
michael@0 1314 readlink: MEMFS.node_ops.readlink
michael@0 1315 };
michael@0 1316 node.stream_ops = {};
michael@0 1317 } else if (FS.isChrdev(node.mode)) {
michael@0 1318 node.node_ops = {
michael@0 1319 getattr: MEMFS.node_ops.getattr,
michael@0 1320 setattr: MEMFS.node_ops.setattr
michael@0 1321 };
michael@0 1322 node.stream_ops = FS.chrdev_stream_ops;
michael@0 1323 }
michael@0 1324 node.timestamp = Date.now();
michael@0 1325 // add the new node to the parent
michael@0 1326 if (parent) {
michael@0 1327 parent.contents[name] = node;
michael@0 1328 }
michael@0 1329 return node;
michael@0 1330 },node_ops:{getattr:function (node) {
michael@0 1331 var attr = {};
michael@0 1332 // device numbers reuse inode numbers.
michael@0 1333 attr.dev = FS.isChrdev(node.mode) ? node.id : 1;
michael@0 1334 attr.ino = node.id;
michael@0 1335 attr.mode = node.mode;
michael@0 1336 attr.nlink = 1;
michael@0 1337 attr.uid = 0;
michael@0 1338 attr.gid = 0;
michael@0 1339 attr.rdev = node.rdev;
michael@0 1340 if (FS.isDir(node.mode)) {
michael@0 1341 attr.size = 4096;
michael@0 1342 } else if (FS.isFile(node.mode)) {
michael@0 1343 attr.size = node.contents.length;
michael@0 1344 } else if (FS.isLink(node.mode)) {
michael@0 1345 attr.size = node.link.length;
michael@0 1346 } else {
michael@0 1347 attr.size = 0;
michael@0 1348 }
michael@0 1349 attr.atime = new Date(node.timestamp);
michael@0 1350 attr.mtime = new Date(node.timestamp);
michael@0 1351 attr.ctime = new Date(node.timestamp);
michael@0 1352 // NOTE: In our implementation, st_blocks = Math.ceil(st_size/st_blksize),
michael@0 1353 // but this is not required by the standard.
michael@0 1354 attr.blksize = 4096;
michael@0 1355 attr.blocks = Math.ceil(attr.size / attr.blksize);
michael@0 1356 return attr;
michael@0 1357 },setattr:function (node, attr) {
michael@0 1358 if (attr.mode !== undefined) {
michael@0 1359 node.mode = attr.mode;
michael@0 1360 }
michael@0 1361 if (attr.timestamp !== undefined) {
michael@0 1362 node.timestamp = attr.timestamp;
michael@0 1363 }
michael@0 1364 if (attr.size !== undefined) {
michael@0 1365 MEMFS.ensureFlexible(node);
michael@0 1366 var contents = node.contents;
michael@0 1367 if (attr.size < contents.length) contents.length = attr.size;
michael@0 1368 else while (attr.size > contents.length) contents.push(0);
michael@0 1369 }
michael@0 1370 },lookup:function (parent, name) {
michael@0 1371 throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
michael@0 1372 },mknod:function (parent, name, mode, dev) {
michael@0 1373 return MEMFS.create_node(parent, name, mode, dev);
michael@0 1374 },rename:function (old_node, new_dir, new_name) {
michael@0 1375 // if we're overwriting a directory at new_name, make sure it's empty.
michael@0 1376 if (FS.isDir(old_node.mode)) {
michael@0 1377 var new_node;
michael@0 1378 try {
michael@0 1379 new_node = FS.lookupNode(new_dir, new_name);
michael@0 1380 } catch (e) {
michael@0 1381 }
michael@0 1382 if (new_node) {
michael@0 1383 for (var i in new_node.contents) {
michael@0 1384 throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
michael@0 1385 }
michael@0 1386 }
michael@0 1387 }
michael@0 1388 // do the internal rewiring
michael@0 1389 delete old_node.parent.contents[old_node.name];
michael@0 1390 old_node.name = new_name;
michael@0 1391 new_dir.contents[new_name] = old_node;
michael@0 1392 },unlink:function (parent, name) {
michael@0 1393 delete parent.contents[name];
michael@0 1394 },rmdir:function (parent, name) {
michael@0 1395 var node = FS.lookupNode(parent, name);
michael@0 1396 for (var i in node.contents) {
michael@0 1397 throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
michael@0 1398 }
michael@0 1399 delete parent.contents[name];
michael@0 1400 },readdir:function (node) {
michael@0 1401 var entries = ['.', '..']
michael@0 1402 for (var key in node.contents) {
michael@0 1403 if (!node.contents.hasOwnProperty(key)) {
michael@0 1404 continue;
michael@0 1405 }
michael@0 1406 entries.push(key);
michael@0 1407 }
michael@0 1408 return entries;
michael@0 1409 },symlink:function (parent, newname, oldpath) {
michael@0 1410 var node = MEMFS.create_node(parent, newname, 0777 | 0120000, 0);
michael@0 1411 node.link = oldpath;
michael@0 1412 return node;
michael@0 1413 },readlink:function (node) {
michael@0 1414 if (!FS.isLink(node.mode)) {
michael@0 1415 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 1416 }
michael@0 1417 return node.link;
michael@0 1418 }},stream_ops:{read:function (stream, buffer, offset, length, position) {
michael@0 1419 var contents = stream.node.contents;
michael@0 1420 var size = Math.min(contents.length - position, length);
michael@0 1421 if (size > 8 && contents.subarray) { // non-trivial, and typed array
michael@0 1422 buffer.set(contents.subarray(position, position + size), offset);
michael@0 1423 } else
michael@0 1424 {
michael@0 1425 for (var i = 0; i < size; i++) {
michael@0 1426 buffer[offset + i] = contents[position + i];
michael@0 1427 }
michael@0 1428 }
michael@0 1429 return size;
michael@0 1430 },write:function (stream, buffer, offset, length, position, canOwn) {
michael@0 1431 var node = stream.node;
michael@0 1432 node.timestamp = Date.now();
michael@0 1433 var contents = node.contents;
michael@0 1434 if (length && contents.length === 0 && position === 0 && buffer.subarray) {
michael@0 1435 // just replace it with the new data
michael@0 1436 assert(buffer.length);
michael@0 1437 if (canOwn && buffer.buffer === HEAP8.buffer && offset === 0) {
michael@0 1438 node.contents = buffer; // this is a subarray of the heap, and we can own it
michael@0 1439 node.contentMode = MEMFS.CONTENT_OWNING;
michael@0 1440 } else {
michael@0 1441 node.contents = new Uint8Array(buffer.subarray(offset, offset+length));
michael@0 1442 node.contentMode = MEMFS.CONTENT_FIXED;
michael@0 1443 }
michael@0 1444 return length;
michael@0 1445 }
michael@0 1446 MEMFS.ensureFlexible(node);
michael@0 1447 var contents = node.contents;
michael@0 1448 while (contents.length < position) contents.push(0);
michael@0 1449 for (var i = 0; i < length; i++) {
michael@0 1450 contents[position + i] = buffer[offset + i];
michael@0 1451 }
michael@0 1452 return length;
michael@0 1453 },llseek:function (stream, offset, whence) {
michael@0 1454 var position = offset;
michael@0 1455 if (whence === 1) { // SEEK_CUR.
michael@0 1456 position += stream.position;
michael@0 1457 } else if (whence === 2) { // SEEK_END.
michael@0 1458 if (FS.isFile(stream.node.mode)) {
michael@0 1459 position += stream.node.contents.length;
michael@0 1460 }
michael@0 1461 }
michael@0 1462 if (position < 0) {
michael@0 1463 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 1464 }
michael@0 1465 stream.ungotten = [];
michael@0 1466 stream.position = position;
michael@0 1467 return position;
michael@0 1468 },allocate:function (stream, offset, length) {
michael@0 1469 MEMFS.ensureFlexible(stream.node);
michael@0 1470 var contents = stream.node.contents;
michael@0 1471 var limit = offset + length;
michael@0 1472 while (limit > contents.length) contents.push(0);
michael@0 1473 },mmap:function (stream, buffer, offset, length, position, prot, flags) {
michael@0 1474 if (!FS.isFile(stream.node.mode)) {
michael@0 1475 throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
michael@0 1476 }
michael@0 1477 var ptr;
michael@0 1478 var allocated;
michael@0 1479 var contents = stream.node.contents;
michael@0 1480 // Only make a new copy when MAP_PRIVATE is specified.
michael@0 1481 if ( !(flags & 0x02) &&
michael@0 1482 (contents.buffer === buffer || contents.buffer === buffer.buffer) ) {
michael@0 1483 // We can't emulate MAP_SHARED when the file is not backed by the buffer
michael@0 1484 // we're mapping to (e.g. the HEAP buffer).
michael@0 1485 allocated = false;
michael@0 1486 ptr = contents.byteOffset;
michael@0 1487 } else {
michael@0 1488 // Try to avoid unnecessary slices.
michael@0 1489 if (position > 0 || position + length < contents.length) {
michael@0 1490 if (contents.subarray) {
michael@0 1491 contents = contents.subarray(position, position + length);
michael@0 1492 } else {
michael@0 1493 contents = Array.prototype.slice.call(contents, position, position + length);
michael@0 1494 }
michael@0 1495 }
michael@0 1496 allocated = true;
michael@0 1497 ptr = _malloc(length);
michael@0 1498 if (!ptr) {
michael@0 1499 throw new FS.ErrnoError(ERRNO_CODES.ENOMEM);
michael@0 1500 }
michael@0 1501 buffer.set(contents, ptr);
michael@0 1502 }
michael@0 1503 return { ptr: ptr, allocated: allocated };
michael@0 1504 }}};
michael@0 1505 var _stdin=allocate(1, "i32*", ALLOC_STATIC);
michael@0 1506 var _stdout=allocate(1, "i32*", ALLOC_STATIC);
michael@0 1507 var _stderr=allocate(1, "i32*", ALLOC_STATIC);
michael@0 1508 function _fflush(stream) {
michael@0 1509 // int fflush(FILE *stream);
michael@0 1510 // http://pubs.opengroup.org/onlinepubs/000095399/functions/fflush.html
michael@0 1511 // we don't currently perform any user-space buffering of data
michael@0 1512 }var FS={root:null,devices:[null],streams:[null],nextInode:1,nameTable:null,currentPath:"/",initialized:false,ignorePermissions:true,ErrnoError:function ErrnoError(errno) {
michael@0 1513 this.errno = errno;
michael@0 1514 for (var key in ERRNO_CODES) {
michael@0 1515 if (ERRNO_CODES[key] === errno) {
michael@0 1516 this.code = key;
michael@0 1517 break;
michael@0 1518 }
michael@0 1519 }
michael@0 1520 this.message = ERRNO_MESSAGES[errno];
michael@0 1521 },handleFSError:function (e) {
michael@0 1522 if (!(e instanceof FS.ErrnoError)) throw e + ' : ' + new Error().stack;
michael@0 1523 return ___setErrNo(e.errno);
michael@0 1524 },cwd:function () {
michael@0 1525 return FS.currentPath;
michael@0 1526 },lookupPath:function (path, opts) {
michael@0 1527 path = PATH.resolve(FS.currentPath, path);
michael@0 1528 opts = opts || { recurse_count: 0 };
michael@0 1529 if (opts.recurse_count > 8) { // max recursive lookup of 8
michael@0 1530 throw new FS.ErrnoError(ERRNO_CODES.ELOOP);
michael@0 1531 }
michael@0 1532 // split the path
michael@0 1533 var parts = PATH.normalizeArray(path.split('/').filter(function(p) {
michael@0 1534 return !!p;
michael@0 1535 }), false);
michael@0 1536 // start at the root
michael@0 1537 var current = FS.root;
michael@0 1538 var current_path = '/';
michael@0 1539 for (var i = 0; i < parts.length; i++) {
michael@0 1540 var islast = (i === parts.length-1);
michael@0 1541 if (islast && opts.parent) {
michael@0 1542 // stop resolving
michael@0 1543 break;
michael@0 1544 }
michael@0 1545 current = FS.lookupNode(current, parts[i]);
michael@0 1546 current_path = PATH.join(current_path, parts[i]);
michael@0 1547 // jump to the mount's root node if this is a mountpoint
michael@0 1548 if (FS.isMountpoint(current)) {
michael@0 1549 current = current.mount.root;
michael@0 1550 }
michael@0 1551 // follow symlinks
michael@0 1552 // by default, lookupPath will not follow a symlink if it is the final path component.
michael@0 1553 // setting opts.follow = true will override this behavior.
michael@0 1554 if (!islast || opts.follow) {
michael@0 1555 var count = 0;
michael@0 1556 while (FS.isLink(current.mode)) {
michael@0 1557 var link = FS.readlink(current_path);
michael@0 1558 current_path = PATH.resolve(PATH.dirname(current_path), link);
michael@0 1559 var lookup = FS.lookupPath(current_path, { recurse_count: opts.recurse_count });
michael@0 1560 current = lookup.node;
michael@0 1561 if (count++ > 40) { // limit max consecutive symlinks to 40 (SYMLOOP_MAX).
michael@0 1562 throw new FS.ErrnoError(ERRNO_CODES.ELOOP);
michael@0 1563 }
michael@0 1564 }
michael@0 1565 }
michael@0 1566 }
michael@0 1567 return { path: current_path, node: current };
michael@0 1568 },getPath:function (node) {
michael@0 1569 var path;
michael@0 1570 while (true) {
michael@0 1571 if (FS.isRoot(node)) {
michael@0 1572 return path ? PATH.join(node.mount.mountpoint, path) : node.mount.mountpoint;
michael@0 1573 }
michael@0 1574 path = path ? PATH.join(node.name, path) : node.name;
michael@0 1575 node = node.parent;
michael@0 1576 }
michael@0 1577 },hashName:function (parentid, name) {
michael@0 1578 var hash = 0;
michael@0 1579 for (var i = 0; i < name.length; i++) {
michael@0 1580 hash = ((hash << 5) - hash + name.charCodeAt(i)) | 0;
michael@0 1581 }
michael@0 1582 return ((parentid + hash) >>> 0) % FS.nameTable.length;
michael@0 1583 },hashAddNode:function (node) {
michael@0 1584 var hash = FS.hashName(node.parent.id, node.name);
michael@0 1585 node.name_next = FS.nameTable[hash];
michael@0 1586 FS.nameTable[hash] = node;
michael@0 1587 },hashRemoveNode:function (node) {
michael@0 1588 var hash = FS.hashName(node.parent.id, node.name);
michael@0 1589 if (FS.nameTable[hash] === node) {
michael@0 1590 FS.nameTable[hash] = node.name_next;
michael@0 1591 } else {
michael@0 1592 var current = FS.nameTable[hash];
michael@0 1593 while (current) {
michael@0 1594 if (current.name_next === node) {
michael@0 1595 current.name_next = node.name_next;
michael@0 1596 break;
michael@0 1597 }
michael@0 1598 current = current.name_next;
michael@0 1599 }
michael@0 1600 }
michael@0 1601 },lookupNode:function (parent, name) {
michael@0 1602 var err = FS.mayLookup(parent);
michael@0 1603 if (err) {
michael@0 1604 throw new FS.ErrnoError(err);
michael@0 1605 }
michael@0 1606 var hash = FS.hashName(parent.id, name);
michael@0 1607 for (var node = FS.nameTable[hash]; node; node = node.name_next) {
michael@0 1608 if (node.parent.id === parent.id && node.name === name) {
michael@0 1609 return node;
michael@0 1610 }
michael@0 1611 }
michael@0 1612 // if we failed to find it in the cache, call into the VFS
michael@0 1613 return FS.lookup(parent, name);
michael@0 1614 },createNode:function (parent, name, mode, rdev) {
michael@0 1615 var node = {
michael@0 1616 id: FS.nextInode++,
michael@0 1617 name: name,
michael@0 1618 mode: mode,
michael@0 1619 node_ops: {},
michael@0 1620 stream_ops: {},
michael@0 1621 rdev: rdev,
michael@0 1622 parent: null,
michael@0 1623 mount: null
michael@0 1624 };
michael@0 1625 if (!parent) {
michael@0 1626 parent = node; // root node sets parent to itself
michael@0 1627 }
michael@0 1628 node.parent = parent;
michael@0 1629 node.mount = parent.mount;
michael@0 1630 // compatibility
michael@0 1631 var readMode = 292 | 73;
michael@0 1632 var writeMode = 146;
michael@0 1633 // NOTE we must use Object.defineProperties instead of individual calls to
michael@0 1634 // Object.defineProperty in order to make closure compiler happy
michael@0 1635 Object.defineProperties(node, {
michael@0 1636 read: {
michael@0 1637 get: function() { return (node.mode & readMode) === readMode; },
michael@0 1638 set: function(val) { val ? node.mode |= readMode : node.mode &= ~readMode; }
michael@0 1639 },
michael@0 1640 write: {
michael@0 1641 get: function() { return (node.mode & writeMode) === writeMode; },
michael@0 1642 set: function(val) { val ? node.mode |= writeMode : node.mode &= ~writeMode; }
michael@0 1643 },
michael@0 1644 isFolder: {
michael@0 1645 get: function() { return FS.isDir(node.mode); },
michael@0 1646 },
michael@0 1647 isDevice: {
michael@0 1648 get: function() { return FS.isChrdev(node.mode); },
michael@0 1649 },
michael@0 1650 });
michael@0 1651 FS.hashAddNode(node);
michael@0 1652 return node;
michael@0 1653 },destroyNode:function (node) {
michael@0 1654 FS.hashRemoveNode(node);
michael@0 1655 },isRoot:function (node) {
michael@0 1656 return node === node.parent;
michael@0 1657 },isMountpoint:function (node) {
michael@0 1658 return node.mounted;
michael@0 1659 },isFile:function (mode) {
michael@0 1660 return (mode & 0170000) === 0100000;
michael@0 1661 },isDir:function (mode) {
michael@0 1662 return (mode & 0170000) === 0040000;
michael@0 1663 },isLink:function (mode) {
michael@0 1664 return (mode & 0170000) === 0120000;
michael@0 1665 },isChrdev:function (mode) {
michael@0 1666 return (mode & 0170000) === 0020000;
michael@0 1667 },isBlkdev:function (mode) {
michael@0 1668 return (mode & 0170000) === 0060000;
michael@0 1669 },isFIFO:function (mode) {
michael@0 1670 return (mode & 0170000) === 0010000;
michael@0 1671 },isSocket:function (mode) {
michael@0 1672 return (mode & 0140000) === 0140000;
michael@0 1673 },flagModes:{"r":0,"rs":8192,"r+":2,"w":1537,"wx":3585,"xw":3585,"w+":1538,"wx+":3586,"xw+":3586,"a":521,"ax":2569,"xa":2569,"a+":522,"ax+":2570,"xa+":2570},modeStringToFlags:function (str) {
michael@0 1674 var flags = FS.flagModes[str];
michael@0 1675 if (typeof flags === 'undefined') {
michael@0 1676 throw new Error('Unknown file open mode: ' + str);
michael@0 1677 }
michael@0 1678 return flags;
michael@0 1679 },flagsToPermissionString:function (flag) {
michael@0 1680 var accmode = flag & 3;
michael@0 1681 var perms = ['r', 'w', 'rw'][accmode];
michael@0 1682 if ((flag & 1024)) {
michael@0 1683 perms += 'w';
michael@0 1684 }
michael@0 1685 return perms;
michael@0 1686 },nodePermissions:function (node, perms) {
michael@0 1687 if (FS.ignorePermissions) {
michael@0 1688 return 0;
michael@0 1689 }
michael@0 1690 // return 0 if any user, group or owner bits are set.
michael@0 1691 if (perms.indexOf('r') !== -1 && !(node.mode & 292)) {
michael@0 1692 return ERRNO_CODES.EACCES;
michael@0 1693 } else if (perms.indexOf('w') !== -1 && !(node.mode & 146)) {
michael@0 1694 return ERRNO_CODES.EACCES;
michael@0 1695 } else if (perms.indexOf('x') !== -1 && !(node.mode & 73)) {
michael@0 1696 return ERRNO_CODES.EACCES;
michael@0 1697 }
michael@0 1698 return 0;
michael@0 1699 },mayLookup:function (dir) {
michael@0 1700 return FS.nodePermissions(dir, 'x');
michael@0 1701 },mayCreate:function (dir, name) {
michael@0 1702 try {
michael@0 1703 var node = FS.lookupNode(dir, name);
michael@0 1704 return ERRNO_CODES.EEXIST;
michael@0 1705 } catch (e) {
michael@0 1706 }
michael@0 1707 return FS.nodePermissions(dir, 'wx');
michael@0 1708 },mayDelete:function (dir, name, isdir) {
michael@0 1709 var node;
michael@0 1710 try {
michael@0 1711 node = FS.lookupNode(dir, name);
michael@0 1712 } catch (e) {
michael@0 1713 return e.errno;
michael@0 1714 }
michael@0 1715 var err = FS.nodePermissions(dir, 'wx');
michael@0 1716 if (err) {
michael@0 1717 return err;
michael@0 1718 }
michael@0 1719 if (isdir) {
michael@0 1720 if (!FS.isDir(node.mode)) {
michael@0 1721 return ERRNO_CODES.ENOTDIR;
michael@0 1722 }
michael@0 1723 if (FS.isRoot(node) || FS.getPath(node) === FS.currentPath) {
michael@0 1724 return ERRNO_CODES.EBUSY;
michael@0 1725 }
michael@0 1726 } else {
michael@0 1727 if (FS.isDir(node.mode)) {
michael@0 1728 return ERRNO_CODES.EISDIR;
michael@0 1729 }
michael@0 1730 }
michael@0 1731 return 0;
michael@0 1732 },mayOpen:function (node, flags) {
michael@0 1733 if (!node) {
michael@0 1734 return ERRNO_CODES.ENOENT;
michael@0 1735 }
michael@0 1736 if (FS.isLink(node.mode)) {
michael@0 1737 return ERRNO_CODES.ELOOP;
michael@0 1738 } else if (FS.isDir(node.mode)) {
michael@0 1739 if ((flags & 3) !== 0 || // opening for write
michael@0 1740 (flags & 1024)) {
michael@0 1741 return ERRNO_CODES.EISDIR;
michael@0 1742 }
michael@0 1743 }
michael@0 1744 return FS.nodePermissions(node, FS.flagsToPermissionString(flags));
michael@0 1745 },MAX_OPEN_FDS:4096,nextfd:function (fd_start, fd_end) {
michael@0 1746 fd_start = fd_start || 1;
michael@0 1747 fd_end = fd_end || FS.MAX_OPEN_FDS;
michael@0 1748 for (var fd = fd_start; fd <= fd_end; fd++) {
michael@0 1749 if (!FS.streams[fd]) {
michael@0 1750 return fd;
michael@0 1751 }
michael@0 1752 }
michael@0 1753 throw new FS.ErrnoError(ERRNO_CODES.EMFILE);
michael@0 1754 },getStream:function (fd) {
michael@0 1755 return FS.streams[fd];
michael@0 1756 },createStream:function (stream, fd_start, fd_end) {
michael@0 1757 var fd = FS.nextfd(fd_start, fd_end);
michael@0 1758 stream.fd = fd;
michael@0 1759 // compatibility
michael@0 1760 Object.defineProperties(stream, {
michael@0 1761 object: {
michael@0 1762 get: function() { return stream.node; },
michael@0 1763 set: function(val) { stream.node = val; }
michael@0 1764 },
michael@0 1765 isRead: {
michael@0 1766 get: function() { return (stream.flags & 3) !== 1; }
michael@0 1767 },
michael@0 1768 isWrite: {
michael@0 1769 get: function() { return (stream.flags & 3) !== 0; }
michael@0 1770 },
michael@0 1771 isAppend: {
michael@0 1772 get: function() { return (stream.flags & 8); }
michael@0 1773 }
michael@0 1774 });
michael@0 1775 FS.streams[fd] = stream;
michael@0 1776 return stream;
michael@0 1777 },closeStream:function (fd) {
michael@0 1778 FS.streams[fd] = null;
michael@0 1779 },chrdev_stream_ops:{open:function (stream) {
michael@0 1780 var device = FS.getDevice(stream.node.rdev);
michael@0 1781 // override node's stream ops with the device's
michael@0 1782 stream.stream_ops = device.stream_ops;
michael@0 1783 // forward the open call
michael@0 1784 if (stream.stream_ops.open) {
michael@0 1785 stream.stream_ops.open(stream);
michael@0 1786 }
michael@0 1787 },llseek:function () {
michael@0 1788 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
michael@0 1789 }},major:function (dev) {
michael@0 1790 return ((dev) >> 8);
michael@0 1791 },minor:function (dev) {
michael@0 1792 return ((dev) & 0xff);
michael@0 1793 },makedev:function (ma, mi) {
michael@0 1794 return ((ma) << 8 | (mi));
michael@0 1795 },registerDevice:function (dev, ops) {
michael@0 1796 FS.devices[dev] = { stream_ops: ops };
michael@0 1797 },getDevice:function (dev) {
michael@0 1798 return FS.devices[dev];
michael@0 1799 },mount:function (type, opts, mountpoint) {
michael@0 1800 var mount = {
michael@0 1801 type: type,
michael@0 1802 opts: opts,
michael@0 1803 mountpoint: mountpoint,
michael@0 1804 root: null
michael@0 1805 };
michael@0 1806 var lookup;
michael@0 1807 if (mountpoint) {
michael@0 1808 lookup = FS.lookupPath(mountpoint, { follow: false });
michael@0 1809 }
michael@0 1810 // create a root node for the fs
michael@0 1811 var root = type.mount(mount);
michael@0 1812 root.mount = mount;
michael@0 1813 mount.root = root;
michael@0 1814 // assign the mount info to the mountpoint's node
michael@0 1815 if (lookup) {
michael@0 1816 lookup.node.mount = mount;
michael@0 1817 lookup.node.mounted = true;
michael@0 1818 // compatibility update FS.root if we mount to /
michael@0 1819 if (mountpoint === '/') {
michael@0 1820 FS.root = mount.root;
michael@0 1821 }
michael@0 1822 }
michael@0 1823 return root;
michael@0 1824 },lookup:function (parent, name) {
michael@0 1825 return parent.node_ops.lookup(parent, name);
michael@0 1826 },mknod:function (path, mode, dev) {
michael@0 1827 var lookup = FS.lookupPath(path, { parent: true });
michael@0 1828 var parent = lookup.node;
michael@0 1829 var name = PATH.basename(path);
michael@0 1830 var err = FS.mayCreate(parent, name);
michael@0 1831 if (err) {
michael@0 1832 throw new FS.ErrnoError(err);
michael@0 1833 }
michael@0 1834 if (!parent.node_ops.mknod) {
michael@0 1835 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 1836 }
michael@0 1837 return parent.node_ops.mknod(parent, name, mode, dev);
michael@0 1838 },create:function (path, mode) {
michael@0 1839 mode = mode !== undefined ? mode : 0666;
michael@0 1840 mode &= 4095;
michael@0 1841 mode |= 0100000;
michael@0 1842 return FS.mknod(path, mode, 0);
michael@0 1843 },mkdir:function (path, mode) {
michael@0 1844 mode = mode !== undefined ? mode : 0777;
michael@0 1845 mode &= 511 | 0001000;
michael@0 1846 mode |= 0040000;
michael@0 1847 return FS.mknod(path, mode, 0);
michael@0 1848 },mkdev:function (path, mode, dev) {
michael@0 1849 if (typeof(dev) === 'undefined') {
michael@0 1850 dev = mode;
michael@0 1851 mode = 0666;
michael@0 1852 }
michael@0 1853 mode |= 0020000;
michael@0 1854 return FS.mknod(path, mode, dev);
michael@0 1855 },symlink:function (oldpath, newpath) {
michael@0 1856 var lookup = FS.lookupPath(newpath, { parent: true });
michael@0 1857 var parent = lookup.node;
michael@0 1858 var newname = PATH.basename(newpath);
michael@0 1859 var err = FS.mayCreate(parent, newname);
michael@0 1860 if (err) {
michael@0 1861 throw new FS.ErrnoError(err);
michael@0 1862 }
michael@0 1863 if (!parent.node_ops.symlink) {
michael@0 1864 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 1865 }
michael@0 1866 return parent.node_ops.symlink(parent, newname, oldpath);
michael@0 1867 },rename:function (old_path, new_path) {
michael@0 1868 var old_dirname = PATH.dirname(old_path);
michael@0 1869 var new_dirname = PATH.dirname(new_path);
michael@0 1870 var old_name = PATH.basename(old_path);
michael@0 1871 var new_name = PATH.basename(new_path);
michael@0 1872 // parents must exist
michael@0 1873 var lookup, old_dir, new_dir;
michael@0 1874 try {
michael@0 1875 lookup = FS.lookupPath(old_path, { parent: true });
michael@0 1876 old_dir = lookup.node;
michael@0 1877 lookup = FS.lookupPath(new_path, { parent: true });
michael@0 1878 new_dir = lookup.node;
michael@0 1879 } catch (e) {
michael@0 1880 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
michael@0 1881 }
michael@0 1882 // need to be part of the same mount
michael@0 1883 if (old_dir.mount !== new_dir.mount) {
michael@0 1884 throw new FS.ErrnoError(ERRNO_CODES.EXDEV);
michael@0 1885 }
michael@0 1886 // source must exist
michael@0 1887 var old_node = FS.lookupNode(old_dir, old_name);
michael@0 1888 // old path should not be an ancestor of the new path
michael@0 1889 var relative = PATH.relative(old_path, new_dirname);
michael@0 1890 if (relative.charAt(0) !== '.') {
michael@0 1891 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 1892 }
michael@0 1893 // new path should not be an ancestor of the old path
michael@0 1894 relative = PATH.relative(new_path, old_dirname);
michael@0 1895 if (relative.charAt(0) !== '.') {
michael@0 1896 throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
michael@0 1897 }
michael@0 1898 // see if the new path already exists
michael@0 1899 var new_node;
michael@0 1900 try {
michael@0 1901 new_node = FS.lookupNode(new_dir, new_name);
michael@0 1902 } catch (e) {
michael@0 1903 // not fatal
michael@0 1904 }
michael@0 1905 // early out if nothing needs to change
michael@0 1906 if (old_node === new_node) {
michael@0 1907 return;
michael@0 1908 }
michael@0 1909 // we'll need to delete the old entry
michael@0 1910 var isdir = FS.isDir(old_node.mode);
michael@0 1911 var err = FS.mayDelete(old_dir, old_name, isdir);
michael@0 1912 if (err) {
michael@0 1913 throw new FS.ErrnoError(err);
michael@0 1914 }
michael@0 1915 // need delete permissions if we'll be overwriting.
michael@0 1916 // need create permissions if new doesn't already exist.
michael@0 1917 err = new_node ?
michael@0 1918 FS.mayDelete(new_dir, new_name, isdir) :
michael@0 1919 FS.mayCreate(new_dir, new_name);
michael@0 1920 if (err) {
michael@0 1921 throw new FS.ErrnoError(err);
michael@0 1922 }
michael@0 1923 if (!old_dir.node_ops.rename) {
michael@0 1924 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 1925 }
michael@0 1926 if (FS.isMountpoint(old_node) || (new_node && FS.isMountpoint(new_node))) {
michael@0 1927 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
michael@0 1928 }
michael@0 1929 // if we are going to change the parent, check write permissions
michael@0 1930 if (new_dir !== old_dir) {
michael@0 1931 err = FS.nodePermissions(old_dir, 'w');
michael@0 1932 if (err) {
michael@0 1933 throw new FS.ErrnoError(err);
michael@0 1934 }
michael@0 1935 }
michael@0 1936 // remove the node from the lookup hash
michael@0 1937 FS.hashRemoveNode(old_node);
michael@0 1938 // do the underlying fs rename
michael@0 1939 try {
michael@0 1940 old_dir.node_ops.rename(old_node, new_dir, new_name);
michael@0 1941 } catch (e) {
michael@0 1942 throw e;
michael@0 1943 } finally {
michael@0 1944 // add the node back to the hash (in case node_ops.rename
michael@0 1945 // changed its name)
michael@0 1946 FS.hashAddNode(old_node);
michael@0 1947 }
michael@0 1948 },rmdir:function (path) {
michael@0 1949 var lookup = FS.lookupPath(path, { parent: true });
michael@0 1950 var parent = lookup.node;
michael@0 1951 var name = PATH.basename(path);
michael@0 1952 var node = FS.lookupNode(parent, name);
michael@0 1953 var err = FS.mayDelete(parent, name, true);
michael@0 1954 if (err) {
michael@0 1955 throw new FS.ErrnoError(err);
michael@0 1956 }
michael@0 1957 if (!parent.node_ops.rmdir) {
michael@0 1958 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 1959 }
michael@0 1960 if (FS.isMountpoint(node)) {
michael@0 1961 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
michael@0 1962 }
michael@0 1963 parent.node_ops.rmdir(parent, name);
michael@0 1964 FS.destroyNode(node);
michael@0 1965 },readdir:function (path) {
michael@0 1966 var lookup = FS.lookupPath(path, { follow: true });
michael@0 1967 var node = lookup.node;
michael@0 1968 if (!node.node_ops.readdir) {
michael@0 1969 throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
michael@0 1970 }
michael@0 1971 return node.node_ops.readdir(node);
michael@0 1972 },unlink:function (path) {
michael@0 1973 var lookup = FS.lookupPath(path, { parent: true });
michael@0 1974 var parent = lookup.node;
michael@0 1975 var name = PATH.basename(path);
michael@0 1976 var node = FS.lookupNode(parent, name);
michael@0 1977 var err = FS.mayDelete(parent, name, false);
michael@0 1978 if (err) {
michael@0 1979 // POSIX says unlink should set EPERM, not EISDIR
michael@0 1980 if (err === ERRNO_CODES.EISDIR) err = ERRNO_CODES.EPERM;
michael@0 1981 throw new FS.ErrnoError(err);
michael@0 1982 }
michael@0 1983 if (!parent.node_ops.unlink) {
michael@0 1984 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 1985 }
michael@0 1986 if (FS.isMountpoint(node)) {
michael@0 1987 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
michael@0 1988 }
michael@0 1989 parent.node_ops.unlink(parent, name);
michael@0 1990 FS.destroyNode(node);
michael@0 1991 },readlink:function (path) {
michael@0 1992 var lookup = FS.lookupPath(path, { follow: false });
michael@0 1993 var link = lookup.node;
michael@0 1994 if (!link.node_ops.readlink) {
michael@0 1995 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 1996 }
michael@0 1997 return link.node_ops.readlink(link);
michael@0 1998 },stat:function (path, dontFollow) {
michael@0 1999 var lookup = FS.lookupPath(path, { follow: !dontFollow });
michael@0 2000 var node = lookup.node;
michael@0 2001 if (!node.node_ops.getattr) {
michael@0 2002 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 2003 }
michael@0 2004 return node.node_ops.getattr(node);
michael@0 2005 },lstat:function (path) {
michael@0 2006 return FS.stat(path, true);
michael@0 2007 },chmod:function (path, mode, dontFollow) {
michael@0 2008 var node;
michael@0 2009 if (typeof path === 'string') {
michael@0 2010 var lookup = FS.lookupPath(path, { follow: !dontFollow });
michael@0 2011 node = lookup.node;
michael@0 2012 } else {
michael@0 2013 node = path;
michael@0 2014 }
michael@0 2015 if (!node.node_ops.setattr) {
michael@0 2016 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 2017 }
michael@0 2018 node.node_ops.setattr(node, {
michael@0 2019 mode: (mode & 4095) | (node.mode & ~4095),
michael@0 2020 timestamp: Date.now()
michael@0 2021 });
michael@0 2022 },lchmod:function (path, mode) {
michael@0 2023 FS.chmod(path, mode, true);
michael@0 2024 },fchmod:function (fd, mode) {
michael@0 2025 var stream = FS.getStream(fd);
michael@0 2026 if (!stream) {
michael@0 2027 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
michael@0 2028 }
michael@0 2029 FS.chmod(stream.node, mode);
michael@0 2030 },chown:function (path, uid, gid, dontFollow) {
michael@0 2031 var node;
michael@0 2032 if (typeof path === 'string') {
michael@0 2033 var lookup = FS.lookupPath(path, { follow: !dontFollow });
michael@0 2034 node = lookup.node;
michael@0 2035 } else {
michael@0 2036 node = path;
michael@0 2037 }
michael@0 2038 if (!node.node_ops.setattr) {
michael@0 2039 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 2040 }
michael@0 2041 node.node_ops.setattr(node, {
michael@0 2042 timestamp: Date.now()
michael@0 2043 // we ignore the uid / gid for now
michael@0 2044 });
michael@0 2045 },lchown:function (path, uid, gid) {
michael@0 2046 FS.chown(path, uid, gid, true);
michael@0 2047 },fchown:function (fd, uid, gid) {
michael@0 2048 var stream = FS.getStream(fd);
michael@0 2049 if (!stream) {
michael@0 2050 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
michael@0 2051 }
michael@0 2052 FS.chown(stream.node, uid, gid);
michael@0 2053 },truncate:function (path, len) {
michael@0 2054 if (len < 0) {
michael@0 2055 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2056 }
michael@0 2057 var node;
michael@0 2058 if (typeof path === 'string') {
michael@0 2059 var lookup = FS.lookupPath(path, { follow: true });
michael@0 2060 node = lookup.node;
michael@0 2061 } else {
michael@0 2062 node = path;
michael@0 2063 }
michael@0 2064 if (!node.node_ops.setattr) {
michael@0 2065 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
michael@0 2066 }
michael@0 2067 if (FS.isDir(node.mode)) {
michael@0 2068 throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
michael@0 2069 }
michael@0 2070 if (!FS.isFile(node.mode)) {
michael@0 2071 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2072 }
michael@0 2073 var err = FS.nodePermissions(node, 'w');
michael@0 2074 if (err) {
michael@0 2075 throw new FS.ErrnoError(err);
michael@0 2076 }
michael@0 2077 node.node_ops.setattr(node, {
michael@0 2078 size: len,
michael@0 2079 timestamp: Date.now()
michael@0 2080 });
michael@0 2081 },ftruncate:function (fd, len) {
michael@0 2082 var stream = FS.getStream(fd);
michael@0 2083 if (!stream) {
michael@0 2084 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
michael@0 2085 }
michael@0 2086 if ((stream.flags & 3) === 0) {
michael@0 2087 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2088 }
michael@0 2089 FS.truncate(stream.node, len);
michael@0 2090 },utime:function (path, atime, mtime) {
michael@0 2091 var lookup = FS.lookupPath(path, { follow: true });
michael@0 2092 var node = lookup.node;
michael@0 2093 node.node_ops.setattr(node, {
michael@0 2094 timestamp: Math.max(atime, mtime)
michael@0 2095 });
michael@0 2096 },open:function (path, flags, mode, fd_start, fd_end) {
michael@0 2097 path = PATH.normalize(path);
michael@0 2098 flags = typeof flags === 'string' ? FS.modeStringToFlags(flags) : flags;
michael@0 2099 mode = typeof mode === 'undefined' ? 0666 : mode;
michael@0 2100 if ((flags & 512)) {
michael@0 2101 mode = (mode & 4095) | 0100000;
michael@0 2102 } else {
michael@0 2103 mode = 0;
michael@0 2104 }
michael@0 2105 var node;
michael@0 2106 try {
michael@0 2107 var lookup = FS.lookupPath(path, {
michael@0 2108 follow: !(flags & 0200000)
michael@0 2109 });
michael@0 2110 node = lookup.node;
michael@0 2111 path = lookup.path;
michael@0 2112 } catch (e) {
michael@0 2113 // ignore
michael@0 2114 }
michael@0 2115 // perhaps we need to create the node
michael@0 2116 if ((flags & 512)) {
michael@0 2117 if (node) {
michael@0 2118 // if O_CREAT and O_EXCL are set, error out if the node already exists
michael@0 2119 if ((flags & 2048)) {
michael@0 2120 throw new FS.ErrnoError(ERRNO_CODES.EEXIST);
michael@0 2121 }
michael@0 2122 } else {
michael@0 2123 // node doesn't exist, try to create it
michael@0 2124 node = FS.mknod(path, mode, 0);
michael@0 2125 }
michael@0 2126 }
michael@0 2127 if (!node) {
michael@0 2128 throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
michael@0 2129 }
michael@0 2130 // can't truncate a device
michael@0 2131 if (FS.isChrdev(node.mode)) {
michael@0 2132 flags &= ~1024;
michael@0 2133 }
michael@0 2134 // check permissions
michael@0 2135 var err = FS.mayOpen(node, flags);
michael@0 2136 if (err) {
michael@0 2137 throw new FS.ErrnoError(err);
michael@0 2138 }
michael@0 2139 // do truncation if necessary
michael@0 2140 if ((flags & 1024)) {
michael@0 2141 FS.truncate(node, 0);
michael@0 2142 }
michael@0 2143 // register the stream with the filesystem
michael@0 2144 var stream = FS.createStream({
michael@0 2145 path: path,
michael@0 2146 node: node,
michael@0 2147 flags: flags,
michael@0 2148 seekable: true,
michael@0 2149 position: 0,
michael@0 2150 stream_ops: node.stream_ops,
michael@0 2151 // used by the file family libc calls (fopen, fwrite, ferror, etc.)
michael@0 2152 ungotten: [],
michael@0 2153 error: false
michael@0 2154 }, fd_start, fd_end);
michael@0 2155 // call the new stream's open function
michael@0 2156 if (stream.stream_ops.open) {
michael@0 2157 stream.stream_ops.open(stream);
michael@0 2158 }
michael@0 2159 return stream;
michael@0 2160 },close:function (stream) {
michael@0 2161 try {
michael@0 2162 if (stream.stream_ops.close) {
michael@0 2163 stream.stream_ops.close(stream);
michael@0 2164 }
michael@0 2165 } catch (e) {
michael@0 2166 throw e;
michael@0 2167 } finally {
michael@0 2168 FS.closeStream(stream.fd);
michael@0 2169 }
michael@0 2170 },llseek:function (stream, offset, whence) {
michael@0 2171 if (!stream.seekable || !stream.stream_ops.llseek) {
michael@0 2172 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
michael@0 2173 }
michael@0 2174 return stream.stream_ops.llseek(stream, offset, whence);
michael@0 2175 },read:function (stream, buffer, offset, length, position) {
michael@0 2176 if (length < 0 || position < 0) {
michael@0 2177 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2178 }
michael@0 2179 if ((stream.flags & 3) === 1) {
michael@0 2180 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
michael@0 2181 }
michael@0 2182 if (FS.isDir(stream.node.mode)) {
michael@0 2183 throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
michael@0 2184 }
michael@0 2185 if (!stream.stream_ops.read) {
michael@0 2186 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2187 }
michael@0 2188 var seeking = true;
michael@0 2189 if (typeof position === 'undefined') {
michael@0 2190 position = stream.position;
michael@0 2191 seeking = false;
michael@0 2192 } else if (!stream.seekable) {
michael@0 2193 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
michael@0 2194 }
michael@0 2195 var bytesRead = stream.stream_ops.read(stream, buffer, offset, length, position);
michael@0 2196 if (!seeking) stream.position += bytesRead;
michael@0 2197 return bytesRead;
michael@0 2198 },write:function (stream, buffer, offset, length, position, canOwn) {
michael@0 2199 if (length < 0 || position < 0) {
michael@0 2200 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2201 }
michael@0 2202 if ((stream.flags & 3) === 0) {
michael@0 2203 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
michael@0 2204 }
michael@0 2205 if (FS.isDir(stream.node.mode)) {
michael@0 2206 throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
michael@0 2207 }
michael@0 2208 if (!stream.stream_ops.write) {
michael@0 2209 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2210 }
michael@0 2211 var seeking = true;
michael@0 2212 if (typeof position === 'undefined') {
michael@0 2213 position = stream.position;
michael@0 2214 seeking = false;
michael@0 2215 } else if (!stream.seekable) {
michael@0 2216 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
michael@0 2217 }
michael@0 2218 if (stream.flags & 8) {
michael@0 2219 // seek to the end before writing in append mode
michael@0 2220 FS.llseek(stream, 0, 2);
michael@0 2221 }
michael@0 2222 var bytesWritten = stream.stream_ops.write(stream, buffer, offset, length, position, canOwn);
michael@0 2223 if (!seeking) stream.position += bytesWritten;
michael@0 2224 return bytesWritten;
michael@0 2225 },allocate:function (stream, offset, length) {
michael@0 2226 if (offset < 0 || length <= 0) {
michael@0 2227 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 2228 }
michael@0 2229 if ((stream.flags & 3) === 0) {
michael@0 2230 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
michael@0 2231 }
michael@0 2232 if (!FS.isFile(stream.node.mode) && !FS.isDir(node.mode)) {
michael@0 2233 throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
michael@0 2234 }
michael@0 2235 if (!stream.stream_ops.allocate) {
michael@0 2236 throw new FS.ErrnoError(ERRNO_CODES.EOPNOTSUPP);
michael@0 2237 }
michael@0 2238 stream.stream_ops.allocate(stream, offset, length);
michael@0 2239 },mmap:function (stream, buffer, offset, length, position, prot, flags) {
michael@0 2240 // TODO if PROT is PROT_WRITE, make sure we have write access
michael@0 2241 if ((stream.flags & 3) === 1) {
michael@0 2242 throw new FS.ErrnoError(ERRNO_CODES.EACCES);
michael@0 2243 }
michael@0 2244 if (!stream.stream_ops.mmap) {
michael@0 2245 throw new FS.errnoError(ERRNO_CODES.ENODEV);
michael@0 2246 }
michael@0 2247 return stream.stream_ops.mmap(stream, buffer, offset, length, position, prot, flags);
michael@0 2248 },ioctl:function (stream, cmd, arg) {
michael@0 2249 if (!stream.stream_ops.ioctl) {
michael@0 2250 throw new FS.ErrnoError(ERRNO_CODES.ENOTTY);
michael@0 2251 }
michael@0 2252 return stream.stream_ops.ioctl(stream, cmd, arg);
michael@0 2253 },readFile:function (path, opts) {
michael@0 2254 opts = opts || {};
michael@0 2255 opts.flags = opts.flags || 'r';
michael@0 2256 opts.encoding = opts.encoding || 'binary';
michael@0 2257 var ret;
michael@0 2258 var stream = FS.open(path, opts.flags);
michael@0 2259 var stat = FS.stat(path);
michael@0 2260 var length = stat.size;
michael@0 2261 var buf = new Uint8Array(length);
michael@0 2262 FS.read(stream, buf, 0, length, 0);
michael@0 2263 if (opts.encoding === 'utf8') {
michael@0 2264 ret = '';
michael@0 2265 var utf8 = new Runtime.UTF8Processor();
michael@0 2266 for (var i = 0; i < length; i++) {
michael@0 2267 ret += utf8.processCChar(buf[i]);
michael@0 2268 }
michael@0 2269 } else if (opts.encoding === 'binary') {
michael@0 2270 ret = buf;
michael@0 2271 } else {
michael@0 2272 throw new Error('Invalid encoding type "' + opts.encoding + '"');
michael@0 2273 }
michael@0 2274 FS.close(stream);
michael@0 2275 return ret;
michael@0 2276 },writeFile:function (path, data, opts) {
michael@0 2277 opts = opts || {};
michael@0 2278 opts.flags = opts.flags || 'w';
michael@0 2279 opts.encoding = opts.encoding || 'utf8';
michael@0 2280 var stream = FS.open(path, opts.flags, opts.mode);
michael@0 2281 if (opts.encoding === 'utf8') {
michael@0 2282 var utf8 = new Runtime.UTF8Processor();
michael@0 2283 var buf = new Uint8Array(utf8.processJSString(data));
michael@0 2284 FS.write(stream, buf, 0, buf.length, 0);
michael@0 2285 } else if (opts.encoding === 'binary') {
michael@0 2286 FS.write(stream, data, 0, data.length, 0);
michael@0 2287 } else {
michael@0 2288 throw new Error('Invalid encoding type "' + opts.encoding + '"');
michael@0 2289 }
michael@0 2290 FS.close(stream);
michael@0 2291 },createDefaultDirectories:function () {
michael@0 2292 FS.mkdir('/tmp');
michael@0 2293 },createDefaultDevices:function () {
michael@0 2294 // create /dev
michael@0 2295 FS.mkdir('/dev');
michael@0 2296 // setup /dev/null
michael@0 2297 FS.registerDevice(FS.makedev(1, 3), {
michael@0 2298 read: function() { return 0; },
michael@0 2299 write: function() { return 0; }
michael@0 2300 });
michael@0 2301 FS.mkdev('/dev/null', FS.makedev(1, 3));
michael@0 2302 // setup /dev/tty and /dev/tty1
michael@0 2303 // stderr needs to print output using Module['printErr']
michael@0 2304 // so we register a second tty just for it.
michael@0 2305 TTY.register(FS.makedev(5, 0), TTY.default_tty_ops);
michael@0 2306 TTY.register(FS.makedev(6, 0), TTY.default_tty1_ops);
michael@0 2307 FS.mkdev('/dev/tty', FS.makedev(5, 0));
michael@0 2308 FS.mkdev('/dev/tty1', FS.makedev(6, 0));
michael@0 2309 // we're not going to emulate the actual shm device,
michael@0 2310 // just create the tmp dirs that reside in it commonly
michael@0 2311 FS.mkdir('/dev/shm');
michael@0 2312 FS.mkdir('/dev/shm/tmp');
michael@0 2313 },createStandardStreams:function () {
michael@0 2314 // TODO deprecate the old functionality of a single
michael@0 2315 // input / output callback and that utilizes FS.createDevice
michael@0 2316 // and instead require a unique set of stream ops
michael@0 2317 // by default, we symlink the standard streams to the
michael@0 2318 // default tty devices. however, if the standard streams
michael@0 2319 // have been overwritten we create a unique device for
michael@0 2320 // them instead.
michael@0 2321 if (Module['stdin']) {
michael@0 2322 FS.createDevice('/dev', 'stdin', Module['stdin']);
michael@0 2323 } else {
michael@0 2324 FS.symlink('/dev/tty', '/dev/stdin');
michael@0 2325 }
michael@0 2326 if (Module['stdout']) {
michael@0 2327 FS.createDevice('/dev', 'stdout', null, Module['stdout']);
michael@0 2328 } else {
michael@0 2329 FS.symlink('/dev/tty', '/dev/stdout');
michael@0 2330 }
michael@0 2331 if (Module['stderr']) {
michael@0 2332 FS.createDevice('/dev', 'stderr', null, Module['stderr']);
michael@0 2333 } else {
michael@0 2334 FS.symlink('/dev/tty1', '/dev/stderr');
michael@0 2335 }
michael@0 2336 // open default streams for the stdin, stdout and stderr devices
michael@0 2337 var stdin = FS.open('/dev/stdin', 'r');
michael@0 2338 HEAP32[((_stdin)>>2)]=stdin.fd;
michael@0 2339 assert(stdin.fd === 1, 'invalid handle for stdin (' + stdin.fd + ')');
michael@0 2340 var stdout = FS.open('/dev/stdout', 'w');
michael@0 2341 HEAP32[((_stdout)>>2)]=stdout.fd;
michael@0 2342 assert(stdout.fd === 2, 'invalid handle for stdout (' + stdout.fd + ')');
michael@0 2343 var stderr = FS.open('/dev/stderr', 'w');
michael@0 2344 HEAP32[((_stderr)>>2)]=stderr.fd;
michael@0 2345 assert(stderr.fd === 3, 'invalid handle for stderr (' + stderr.fd + ')');
michael@0 2346 },staticInit:function () {
michael@0 2347 FS.nameTable = new Array(4096);
michael@0 2348 FS.root = FS.createNode(null, '/', 0040000 | 0777, 0);
michael@0 2349 FS.mount(MEMFS, {}, '/');
michael@0 2350 FS.createDefaultDirectories();
michael@0 2351 FS.createDefaultDevices();
michael@0 2352 },init:function (input, output, error) {
michael@0 2353 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)');
michael@0 2354 FS.init.initialized = true;
michael@0 2355 // Allow Module.stdin etc. to provide defaults, if none explicitly passed to us here
michael@0 2356 Module['stdin'] = input || Module['stdin'];
michael@0 2357 Module['stdout'] = output || Module['stdout'];
michael@0 2358 Module['stderr'] = error || Module['stderr'];
michael@0 2359 FS.createStandardStreams();
michael@0 2360 },quit:function () {
michael@0 2361 FS.init.initialized = false;
michael@0 2362 for (var i = 0; i < FS.streams.length; i++) {
michael@0 2363 var stream = FS.streams[i];
michael@0 2364 if (!stream) {
michael@0 2365 continue;
michael@0 2366 }
michael@0 2367 FS.close(stream);
michael@0 2368 }
michael@0 2369 },getMode:function (canRead, canWrite) {
michael@0 2370 var mode = 0;
michael@0 2371 if (canRead) mode |= 292 | 73;
michael@0 2372 if (canWrite) mode |= 146;
michael@0 2373 return mode;
michael@0 2374 },joinPath:function (parts, forceRelative) {
michael@0 2375 var path = PATH.join.apply(null, parts);
michael@0 2376 if (forceRelative && path[0] == '/') path = path.substr(1);
michael@0 2377 return path;
michael@0 2378 },absolutePath:function (relative, base) {
michael@0 2379 return PATH.resolve(base, relative);
michael@0 2380 },standardizePath:function (path) {
michael@0 2381 return PATH.normalize(path);
michael@0 2382 },findObject:function (path, dontResolveLastLink) {
michael@0 2383 var ret = FS.analyzePath(path, dontResolveLastLink);
michael@0 2384 if (ret.exists) {
michael@0 2385 return ret.object;
michael@0 2386 } else {
michael@0 2387 ___setErrNo(ret.error);
michael@0 2388 return null;
michael@0 2389 }
michael@0 2390 },analyzePath:function (path, dontResolveLastLink) {
michael@0 2391 // operate from within the context of the symlink's target
michael@0 2392 try {
michael@0 2393 var lookup = FS.lookupPath(path, { follow: !dontResolveLastLink });
michael@0 2394 path = lookup.path;
michael@0 2395 } catch (e) {
michael@0 2396 }
michael@0 2397 var ret = {
michael@0 2398 isRoot: false, exists: false, error: 0, name: null, path: null, object: null,
michael@0 2399 parentExists: false, parentPath: null, parentObject: null
michael@0 2400 };
michael@0 2401 try {
michael@0 2402 var lookup = FS.lookupPath(path, { parent: true });
michael@0 2403 ret.parentExists = true;
michael@0 2404 ret.parentPath = lookup.path;
michael@0 2405 ret.parentObject = lookup.node;
michael@0 2406 ret.name = PATH.basename(path);
michael@0 2407 lookup = FS.lookupPath(path, { follow: !dontResolveLastLink });
michael@0 2408 ret.exists = true;
michael@0 2409 ret.path = lookup.path;
michael@0 2410 ret.object = lookup.node;
michael@0 2411 ret.name = lookup.node.name;
michael@0 2412 ret.isRoot = lookup.path === '/';
michael@0 2413 } catch (e) {
michael@0 2414 ret.error = e.errno;
michael@0 2415 };
michael@0 2416 return ret;
michael@0 2417 },createFolder:function (parent, name, canRead, canWrite) {
michael@0 2418 var path = PATH.join(typeof parent === 'string' ? parent : FS.getPath(parent), name);
michael@0 2419 var mode = FS.getMode(canRead, canWrite);
michael@0 2420 return FS.mkdir(path, mode);
michael@0 2421 },createPath:function (parent, path, canRead, canWrite) {
michael@0 2422 parent = typeof parent === 'string' ? parent : FS.getPath(parent);
michael@0 2423 var parts = path.split('/').reverse();
michael@0 2424 while (parts.length) {
michael@0 2425 var part = parts.pop();
michael@0 2426 if (!part) continue;
michael@0 2427 var current = PATH.join(parent, part);
michael@0 2428 try {
michael@0 2429 FS.mkdir(current);
michael@0 2430 } catch (e) {
michael@0 2431 // ignore EEXIST
michael@0 2432 }
michael@0 2433 parent = current;
michael@0 2434 }
michael@0 2435 return current;
michael@0 2436 },createFile:function (parent, name, properties, canRead, canWrite) {
michael@0 2437 var path = PATH.join(typeof parent === 'string' ? parent : FS.getPath(parent), name);
michael@0 2438 var mode = FS.getMode(canRead, canWrite);
michael@0 2439 return FS.create(path, mode);
michael@0 2440 },createDataFile:function (parent, name, data, canRead, canWrite, canOwn) {
michael@0 2441 var path = name ? PATH.join(typeof parent === 'string' ? parent : FS.getPath(parent), name) : parent;
michael@0 2442 var mode = FS.getMode(canRead, canWrite);
michael@0 2443 var node = FS.create(path, mode);
michael@0 2444 if (data) {
michael@0 2445 if (typeof data === 'string') {
michael@0 2446 var arr = new Array(data.length);
michael@0 2447 for (var i = 0, len = data.length; i < len; ++i) arr[i] = data.charCodeAt(i);
michael@0 2448 data = arr;
michael@0 2449 }
michael@0 2450 // make sure we can write to the file
michael@0 2451 FS.chmod(path, mode | 146);
michael@0 2452 var stream = FS.open(path, 'w');
michael@0 2453 FS.write(stream, data, 0, data.length, 0, canOwn);
michael@0 2454 FS.close(stream);
michael@0 2455 FS.chmod(path, mode);
michael@0 2456 }
michael@0 2457 return node;
michael@0 2458 },createDevice:function (parent, name, input, output) {
michael@0 2459 var path = PATH.join(typeof parent === 'string' ? parent : FS.getPath(parent), name);
michael@0 2460 var mode = FS.getMode(!!input, !!output);
michael@0 2461 if (!FS.createDevice.major) FS.createDevice.major = 64;
michael@0 2462 var dev = FS.makedev(FS.createDevice.major++, 0);
michael@0 2463 // Create a fake device that a set of stream ops to emulate
michael@0 2464 // the old behavior.
michael@0 2465 FS.registerDevice(dev, {
michael@0 2466 open: function(stream) {
michael@0 2467 stream.seekable = false;
michael@0 2468 },
michael@0 2469 close: function(stream) {
michael@0 2470 // flush any pending line data
michael@0 2471 if (output && output.buffer && output.buffer.length) {
michael@0 2472 output(10);
michael@0 2473 }
michael@0 2474 },
michael@0 2475 read: function(stream, buffer, offset, length, pos /* ignored */) {
michael@0 2476 var bytesRead = 0;
michael@0 2477 for (var i = 0; i < length; i++) {
michael@0 2478 var result;
michael@0 2479 try {
michael@0 2480 result = input();
michael@0 2481 } catch (e) {
michael@0 2482 throw new FS.ErrnoError(ERRNO_CODES.EIO);
michael@0 2483 }
michael@0 2484 if (result === undefined && bytesRead === 0) {
michael@0 2485 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
michael@0 2486 }
michael@0 2487 if (result === null || result === undefined) break;
michael@0 2488 bytesRead++;
michael@0 2489 buffer[offset+i] = result;
michael@0 2490 }
michael@0 2491 if (bytesRead) {
michael@0 2492 stream.node.timestamp = Date.now();
michael@0 2493 }
michael@0 2494 return bytesRead;
michael@0 2495 },
michael@0 2496 write: function(stream, buffer, offset, length, pos) {
michael@0 2497 for (var i = 0; i < length; i++) {
michael@0 2498 try {
michael@0 2499 output(buffer[offset+i]);
michael@0 2500 } catch (e) {
michael@0 2501 throw new FS.ErrnoError(ERRNO_CODES.EIO);
michael@0 2502 }
michael@0 2503 }
michael@0 2504 if (length) {
michael@0 2505 stream.node.timestamp = Date.now();
michael@0 2506 }
michael@0 2507 return i;
michael@0 2508 }
michael@0 2509 });
michael@0 2510 return FS.mkdev(path, mode, dev);
michael@0 2511 },createLink:function (parent, name, target, canRead, canWrite) {
michael@0 2512 var path = PATH.join(typeof parent === 'string' ? parent : FS.getPath(parent), name);
michael@0 2513 return FS.symlink(target, path);
michael@0 2514 },forceLoadFile:function (obj) {
michael@0 2515 if (obj.isDevice || obj.isFolder || obj.link || obj.contents) return true;
michael@0 2516 var success = true;
michael@0 2517 if (typeof XMLHttpRequest !== 'undefined') {
michael@0 2518 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.");
michael@0 2519 } else if (Module['read']) {
michael@0 2520 // Command-line.
michael@0 2521 try {
michael@0 2522 // WARNING: Can't read binary files in V8's d8 or tracemonkey's js, as
michael@0 2523 // read() will try to parse UTF8.
michael@0 2524 obj.contents = intArrayFromString(Module['read'](obj.url), true);
michael@0 2525 } catch (e) {
michael@0 2526 success = false;
michael@0 2527 }
michael@0 2528 } else {
michael@0 2529 throw new Error('Cannot load without read() or XMLHttpRequest.');
michael@0 2530 }
michael@0 2531 if (!success) ___setErrNo(ERRNO_CODES.EIO);
michael@0 2532 return success;
michael@0 2533 },createLazyFile:function (parent, name, url, canRead, canWrite) {
michael@0 2534 if (typeof XMLHttpRequest !== 'undefined') {
michael@0 2535 if (!ENVIRONMENT_IS_WORKER) throw 'Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc';
michael@0 2536 // Lazy chunked Uint8Array (implements get and length from Uint8Array). Actual getting is abstracted away for eventual reuse.
michael@0 2537 var LazyUint8Array = function() {
michael@0 2538 this.lengthKnown = false;
michael@0 2539 this.chunks = []; // Loaded chunks. Index is the chunk number
michael@0 2540 }
michael@0 2541 LazyUint8Array.prototype.get = function(idx) {
michael@0 2542 if (idx > this.length-1 || idx < 0) {
michael@0 2543 return undefined;
michael@0 2544 }
michael@0 2545 var chunkOffset = idx % this.chunkSize;
michael@0 2546 var chunkNum = Math.floor(idx / this.chunkSize);
michael@0 2547 return this.getter(chunkNum)[chunkOffset];
michael@0 2548 }
michael@0 2549 LazyUint8Array.prototype.setDataGetter = function(getter) {
michael@0 2550 this.getter = getter;
michael@0 2551 }
michael@0 2552 LazyUint8Array.prototype.cacheLength = function() {
michael@0 2553 // Find length
michael@0 2554 var xhr = new XMLHttpRequest();
michael@0 2555 xhr.open('HEAD', url, false);
michael@0 2556 xhr.send(null);
michael@0 2557 if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status);
michael@0 2558 var datalength = Number(xhr.getResponseHeader("Content-length"));
michael@0 2559 var header;
michael@0 2560 var hasByteServing = (header = xhr.getResponseHeader("Accept-Ranges")) && header === "bytes";
michael@0 2561 var chunkSize = 1024*1024; // Chunk size in bytes
michael@0 2562 if (!hasByteServing) chunkSize = datalength;
michael@0 2563 // Function to get a range from the remote URL.
michael@0 2564 var doXHR = (function(from, to) {
michael@0 2565 if (from > to) throw new Error("invalid range (" + from + ", " + to + ") or no bytes requested!");
michael@0 2566 if (to > datalength-1) throw new Error("only " + datalength + " bytes available! programmer error!");
michael@0 2567 // TODO: Use mozResponseArrayBuffer, responseStream, etc. if available.
michael@0 2568 var xhr = new XMLHttpRequest();
michael@0 2569 xhr.open('GET', url, false);
michael@0 2570 if (datalength !== chunkSize) xhr.setRequestHeader("Range", "bytes=" + from + "-" + to);
michael@0 2571 // Some hints to the browser that we want binary data.
michael@0 2572 if (typeof Uint8Array != 'undefined') xhr.responseType = 'arraybuffer';
michael@0 2573 if (xhr.overrideMimeType) {
michael@0 2574 xhr.overrideMimeType('text/plain; charset=x-user-defined');
michael@0 2575 }
michael@0 2576 xhr.send(null);
michael@0 2577 if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status);
michael@0 2578 if (xhr.response !== undefined) {
michael@0 2579 return new Uint8Array(xhr.response || []);
michael@0 2580 } else {
michael@0 2581 return intArrayFromString(xhr.responseText || '', true);
michael@0 2582 }
michael@0 2583 });
michael@0 2584 var lazyArray = this;
michael@0 2585 lazyArray.setDataGetter(function(chunkNum) {
michael@0 2586 var start = chunkNum * chunkSize;
michael@0 2587 var end = (chunkNum+1) * chunkSize - 1; // including this byte
michael@0 2588 end = Math.min(end, datalength-1); // if datalength-1 is selected, this is the last block
michael@0 2589 if (typeof(lazyArray.chunks[chunkNum]) === "undefined") {
michael@0 2590 lazyArray.chunks[chunkNum] = doXHR(start, end);
michael@0 2591 }
michael@0 2592 if (typeof(lazyArray.chunks[chunkNum]) === "undefined") throw new Error("doXHR failed!");
michael@0 2593 return lazyArray.chunks[chunkNum];
michael@0 2594 });
michael@0 2595 this._length = datalength;
michael@0 2596 this._chunkSize = chunkSize;
michael@0 2597 this.lengthKnown = true;
michael@0 2598 }
michael@0 2599 var lazyArray = new LazyUint8Array();
michael@0 2600 Object.defineProperty(lazyArray, "length", {
michael@0 2601 get: function() {
michael@0 2602 if(!this.lengthKnown) {
michael@0 2603 this.cacheLength();
michael@0 2604 }
michael@0 2605 return this._length;
michael@0 2606 }
michael@0 2607 });
michael@0 2608 Object.defineProperty(lazyArray, "chunkSize", {
michael@0 2609 get: function() {
michael@0 2610 if(!this.lengthKnown) {
michael@0 2611 this.cacheLength();
michael@0 2612 }
michael@0 2613 return this._chunkSize;
michael@0 2614 }
michael@0 2615 });
michael@0 2616 var properties = { isDevice: false, contents: lazyArray };
michael@0 2617 } else {
michael@0 2618 var properties = { isDevice: false, url: url };
michael@0 2619 }
michael@0 2620 var node = FS.createFile(parent, name, properties, canRead, canWrite);
michael@0 2621 // This is a total hack, but I want to get this lazy file code out of the
michael@0 2622 // core of MEMFS. If we want to keep this lazy file concept I feel it should
michael@0 2623 // be its own thin LAZYFS proxying calls to MEMFS.
michael@0 2624 if (properties.contents) {
michael@0 2625 node.contents = properties.contents;
michael@0 2626 } else if (properties.url) {
michael@0 2627 node.contents = null;
michael@0 2628 node.url = properties.url;
michael@0 2629 }
michael@0 2630 // override each stream op with one that tries to force load the lazy file first
michael@0 2631 var stream_ops = {};
michael@0 2632 var keys = Object.keys(node.stream_ops);
michael@0 2633 keys.forEach(function(key) {
michael@0 2634 var fn = node.stream_ops[key];
michael@0 2635 stream_ops[key] = function() {
michael@0 2636 if (!FS.forceLoadFile(node)) {
michael@0 2637 throw new FS.ErrnoError(ERRNO_CODES.EIO);
michael@0 2638 }
michael@0 2639 return fn.apply(null, arguments);
michael@0 2640 };
michael@0 2641 });
michael@0 2642 // use a custom read function
michael@0 2643 stream_ops.read = function(stream, buffer, offset, length, position) {
michael@0 2644 if (!FS.forceLoadFile(node)) {
michael@0 2645 throw new FS.ErrnoError(ERRNO_CODES.EIO);
michael@0 2646 }
michael@0 2647 var contents = stream.node.contents;
michael@0 2648 var size = Math.min(contents.length - position, length);
michael@0 2649 if (contents.slice) { // normal array
michael@0 2650 for (var i = 0; i < size; i++) {
michael@0 2651 buffer[offset + i] = contents[position + i];
michael@0 2652 }
michael@0 2653 } else {
michael@0 2654 for (var i = 0; i < size; i++) { // LazyUint8Array from sync binary XHR
michael@0 2655 buffer[offset + i] = contents.get(position + i);
michael@0 2656 }
michael@0 2657 }
michael@0 2658 return size;
michael@0 2659 };
michael@0 2660 node.stream_ops = stream_ops;
michael@0 2661 return node;
michael@0 2662 },createPreloadedFile:function (parent, name, url, canRead, canWrite, onload, onerror, dontCreateFile, canOwn) {
michael@0 2663 Browser.init();
michael@0 2664 // TODO we should allow people to just pass in a complete filename instead
michael@0 2665 // of parent and name being that we just join them anyways
michael@0 2666 var fullname = name ? PATH.resolve(PATH.join(parent, name)) : parent;
michael@0 2667 function processData(byteArray) {
michael@0 2668 function finish(byteArray) {
michael@0 2669 if (!dontCreateFile) {
michael@0 2670 FS.createDataFile(parent, name, byteArray, canRead, canWrite, canOwn);
michael@0 2671 }
michael@0 2672 if (onload) onload();
michael@0 2673 removeRunDependency('cp ' + fullname);
michael@0 2674 }
michael@0 2675 var handled = false;
michael@0 2676 Module['preloadPlugins'].forEach(function(plugin) {
michael@0 2677 if (handled) return;
michael@0 2678 if (plugin['canHandle'](fullname)) {
michael@0 2679 plugin['handle'](byteArray, fullname, finish, function() {
michael@0 2680 if (onerror) onerror();
michael@0 2681 removeRunDependency('cp ' + fullname);
michael@0 2682 });
michael@0 2683 handled = true;
michael@0 2684 }
michael@0 2685 });
michael@0 2686 if (!handled) finish(byteArray);
michael@0 2687 }
michael@0 2688 addRunDependency('cp ' + fullname);
michael@0 2689 if (typeof url == 'string') {
michael@0 2690 Browser.asyncLoad(url, function(byteArray) {
michael@0 2691 processData(byteArray);
michael@0 2692 }, onerror);
michael@0 2693 } else {
michael@0 2694 processData(url);
michael@0 2695 }
michael@0 2696 },indexedDB:function () {
michael@0 2697 return window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB;
michael@0 2698 },DB_NAME:function () {
michael@0 2699 return 'EM_FS_' + window.location.pathname;
michael@0 2700 },DB_VERSION:20,DB_STORE_NAME:"FILE_DATA",saveFilesToDB:function (paths, onload, onerror) {
michael@0 2701 onload = onload || function(){};
michael@0 2702 onerror = onerror || function(){};
michael@0 2703 var indexedDB = FS.indexedDB();
michael@0 2704 try {
michael@0 2705 var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION);
michael@0 2706 } catch (e) {
michael@0 2707 return onerror(e);
michael@0 2708 }
michael@0 2709 openRequest.onupgradeneeded = function() {
michael@0 2710 console.log('creating db');
michael@0 2711 var db = openRequest.result;
michael@0 2712 db.createObjectStore(FS.DB_STORE_NAME);
michael@0 2713 };
michael@0 2714 openRequest.onsuccess = function() {
michael@0 2715 var db = openRequest.result;
michael@0 2716 var transaction = db.transaction([FS.DB_STORE_NAME], 'readwrite');
michael@0 2717 var files = transaction.objectStore(FS.DB_STORE_NAME);
michael@0 2718 var ok = 0, fail = 0, total = paths.length;
michael@0 2719 function finish() {
michael@0 2720 if (fail == 0) onload(); else onerror();
michael@0 2721 }
michael@0 2722 paths.forEach(function(path) {
michael@0 2723 var putRequest = files.put(FS.analyzePath(path).object.contents, path);
michael@0 2724 putRequest.onsuccess = function() { ok++; if (ok + fail == total) finish() };
michael@0 2725 putRequest.onerror = function() { fail++; if (ok + fail == total) finish() };
michael@0 2726 });
michael@0 2727 transaction.onerror = onerror;
michael@0 2728 };
michael@0 2729 openRequest.onerror = onerror;
michael@0 2730 },loadFilesFromDB:function (paths, onload, onerror) {
michael@0 2731 onload = onload || function(){};
michael@0 2732 onerror = onerror || function(){};
michael@0 2733 var indexedDB = FS.indexedDB();
michael@0 2734 try {
michael@0 2735 var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION);
michael@0 2736 } catch (e) {
michael@0 2737 return onerror(e);
michael@0 2738 }
michael@0 2739 openRequest.onupgradeneeded = onerror; // no database to load from
michael@0 2740 openRequest.onsuccess = function() {
michael@0 2741 var db = openRequest.result;
michael@0 2742 try {
michael@0 2743 var transaction = db.transaction([FS.DB_STORE_NAME], 'readonly');
michael@0 2744 } catch(e) {
michael@0 2745 onerror(e);
michael@0 2746 return;
michael@0 2747 }
michael@0 2748 var files = transaction.objectStore(FS.DB_STORE_NAME);
michael@0 2749 var ok = 0, fail = 0, total = paths.length;
michael@0 2750 function finish() {
michael@0 2751 if (fail == 0) onload(); else onerror();
michael@0 2752 }
michael@0 2753 paths.forEach(function(path) {
michael@0 2754 var getRequest = files.get(path);
michael@0 2755 getRequest.onsuccess = function() {
michael@0 2756 if (FS.analyzePath(path).exists) {
michael@0 2757 FS.unlink(path);
michael@0 2758 }
michael@0 2759 FS.createDataFile(PATH.dirname(path), PATH.basename(path), getRequest.result, true, true, true);
michael@0 2760 ok++;
michael@0 2761 if (ok + fail == total) finish();
michael@0 2762 };
michael@0 2763 getRequest.onerror = function() { fail++; if (ok + fail == total) finish() };
michael@0 2764 });
michael@0 2765 transaction.onerror = onerror;
michael@0 2766 };
michael@0 2767 openRequest.onerror = onerror;
michael@0 2768 }};
michael@0 2769 var SOCKFS={mount:function (mount) {
michael@0 2770 return FS.createNode(null, '/', 0040000 | 0777, 0);
michael@0 2771 },nextname:function () {
michael@0 2772 if (!SOCKFS.nextname.current) {
michael@0 2773 SOCKFS.nextname.current = 0;
michael@0 2774 }
michael@0 2775 return 'socket[' + (SOCKFS.nextname.current++) + ']';
michael@0 2776 },createSocket:function (family, type, protocol) {
michael@0 2777 var streaming = type == 1;
michael@0 2778 if (protocol) {
michael@0 2779 assert(streaming == (protocol == 6)); // if SOCK_STREAM, must be tcp
michael@0 2780 }
michael@0 2781 // create our internal socket structure
michael@0 2782 var sock = {
michael@0 2783 family: family,
michael@0 2784 type: type,
michael@0 2785 protocol: protocol,
michael@0 2786 server: null,
michael@0 2787 peers: {},
michael@0 2788 pending: [],
michael@0 2789 recv_queue: [],
michael@0 2790 sock_ops: SOCKFS.websocket_sock_ops
michael@0 2791 };
michael@0 2792 // create the filesystem node to store the socket structure
michael@0 2793 var name = SOCKFS.nextname();
michael@0 2794 var node = FS.createNode(SOCKFS.root, name, 0140000, 0);
michael@0 2795 node.sock = sock;
michael@0 2796 // and the wrapping stream that enables library functions such
michael@0 2797 // as read and write to indirectly interact with the socket
michael@0 2798 var stream = FS.createStream({
michael@0 2799 path: name,
michael@0 2800 node: node,
michael@0 2801 flags: FS.modeStringToFlags('r+'),
michael@0 2802 seekable: false,
michael@0 2803 stream_ops: SOCKFS.stream_ops
michael@0 2804 });
michael@0 2805 // map the new stream to the socket structure (sockets have a 1:1
michael@0 2806 // relationship with a stream)
michael@0 2807 sock.stream = stream;
michael@0 2808 return sock;
michael@0 2809 },getSocket:function (fd) {
michael@0 2810 var stream = FS.getStream(fd);
michael@0 2811 if (!stream || !FS.isSocket(stream.node.mode)) {
michael@0 2812 return null;
michael@0 2813 }
michael@0 2814 return stream.node.sock;
michael@0 2815 },stream_ops:{poll:function (stream) {
michael@0 2816 var sock = stream.node.sock;
michael@0 2817 return sock.sock_ops.poll(sock);
michael@0 2818 },ioctl:function (stream, request, varargs) {
michael@0 2819 var sock = stream.node.sock;
michael@0 2820 return sock.sock_ops.ioctl(sock, request, varargs);
michael@0 2821 },read:function (stream, buffer, offset, length, position /* ignored */) {
michael@0 2822 var sock = stream.node.sock;
michael@0 2823 var msg = sock.sock_ops.recvmsg(sock, length);
michael@0 2824 if (!msg) {
michael@0 2825 // socket is closed
michael@0 2826 return 0;
michael@0 2827 }
michael@0 2828 buffer.set(msg.buffer, offset);
michael@0 2829 return msg.buffer.length;
michael@0 2830 },write:function (stream, buffer, offset, length, position /* ignored */) {
michael@0 2831 var sock = stream.node.sock;
michael@0 2832 return sock.sock_ops.sendmsg(sock, buffer, offset, length);
michael@0 2833 },close:function (stream) {
michael@0 2834 var sock = stream.node.sock;
michael@0 2835 sock.sock_ops.close(sock);
michael@0 2836 }},websocket_sock_ops:{createPeer:function (sock, addr, port) {
michael@0 2837 var ws;
michael@0 2838 if (typeof addr === 'object') {
michael@0 2839 ws = addr;
michael@0 2840 addr = null;
michael@0 2841 port = null;
michael@0 2842 }
michael@0 2843 if (ws) {
michael@0 2844 // for sockets that've already connected (e.g. we're the server)
michael@0 2845 // we can inspect the _socket property for the address
michael@0 2846 if (ws._socket) {
michael@0 2847 addr = ws._socket.remoteAddress;
michael@0 2848 port = ws._socket.remotePort;
michael@0 2849 }
michael@0 2850 // if we're just now initializing a connection to the remote,
michael@0 2851 // inspect the url property
michael@0 2852 else {
michael@0 2853 var result = /ws[s]?:\/\/([^:]+):(\d+)/.exec(ws.url);
michael@0 2854 if (!result) {
michael@0 2855 throw new Error('WebSocket URL must be in the format ws(s)://address:port');
michael@0 2856 }
michael@0 2857 addr = result[1];
michael@0 2858 port = parseInt(result[2], 10);
michael@0 2859 }
michael@0 2860 } else {
michael@0 2861 // create the actual websocket object and connect
michael@0 2862 try {
michael@0 2863 var url = 'ws://' + addr + ':' + port;
michael@0 2864 // the node ws library API is slightly different than the browser's
michael@0 2865 var opts = ENVIRONMENT_IS_NODE ? {} : ['binary'];
michael@0 2866 ws = new WebSocket(url, opts);
michael@0 2867 ws.binaryType = 'arraybuffer';
michael@0 2868 } catch (e) {
michael@0 2869 throw new FS.ErrnoError(ERRNO_CODES.EHOSTUNREACH);
michael@0 2870 }
michael@0 2871 }
michael@0 2872 var peer = {
michael@0 2873 addr: addr,
michael@0 2874 port: port,
michael@0 2875 socket: ws,
michael@0 2876 dgram_send_queue: []
michael@0 2877 };
michael@0 2878 SOCKFS.websocket_sock_ops.addPeer(sock, peer);
michael@0 2879 SOCKFS.websocket_sock_ops.handlePeerEvents(sock, peer);
michael@0 2880 // if this is a bound dgram socket, send the port number first to allow
michael@0 2881 // us to override the ephemeral port reported to us by remotePort on the
michael@0 2882 // remote end.
michael@0 2883 if (sock.type === 2 && typeof sock.sport !== 'undefined') {
michael@0 2884 peer.dgram_send_queue.push(new Uint8Array([
michael@0 2885 255, 255, 255, 255,
michael@0 2886 'p'.charCodeAt(0), 'o'.charCodeAt(0), 'r'.charCodeAt(0), 't'.charCodeAt(0),
michael@0 2887 ((sock.sport & 0xff00) >> 8) , (sock.sport & 0xff)
michael@0 2888 ]));
michael@0 2889 }
michael@0 2890 return peer;
michael@0 2891 },getPeer:function (sock, addr, port) {
michael@0 2892 return sock.peers[addr + ':' + port];
michael@0 2893 },addPeer:function (sock, peer) {
michael@0 2894 sock.peers[peer.addr + ':' + peer.port] = peer;
michael@0 2895 },removePeer:function (sock, peer) {
michael@0 2896 delete sock.peers[peer.addr + ':' + peer.port];
michael@0 2897 },handlePeerEvents:function (sock, peer) {
michael@0 2898 var first = true;
michael@0 2899 var handleOpen = function () {
michael@0 2900 try {
michael@0 2901 var queued = peer.dgram_send_queue.shift();
michael@0 2902 while (queued) {
michael@0 2903 peer.socket.send(queued);
michael@0 2904 queued = peer.dgram_send_queue.shift();
michael@0 2905 }
michael@0 2906 } catch (e) {
michael@0 2907 // not much we can do here in the way of proper error handling as we've already
michael@0 2908 // lied and said this data was sent. shut it down.
michael@0 2909 peer.socket.close();
michael@0 2910 }
michael@0 2911 };
michael@0 2912 var handleMessage = function(data) {
michael@0 2913 assert(typeof data !== 'string' && data.byteLength !== undefined); // must receive an ArrayBuffer
michael@0 2914 data = new Uint8Array(data); // make a typed array view on the array buffer
michael@0 2915 // if this is the port message, override the peer's port with it
michael@0 2916 var wasfirst = first;
michael@0 2917 first = false;
michael@0 2918 if (wasfirst &&
michael@0 2919 data.length === 10 &&
michael@0 2920 data[0] === 255 && data[1] === 255 && data[2] === 255 && data[3] === 255 &&
michael@0 2921 data[4] === 'p'.charCodeAt(0) && data[5] === 'o'.charCodeAt(0) && data[6] === 'r'.charCodeAt(0) && data[7] === 't'.charCodeAt(0)) {
michael@0 2922 // update the peer's port and it's key in the peer map
michael@0 2923 var newport = ((data[8] << 8) | data[9]);
michael@0 2924 SOCKFS.websocket_sock_ops.removePeer(sock, peer);
michael@0 2925 peer.port = newport;
michael@0 2926 SOCKFS.websocket_sock_ops.addPeer(sock, peer);
michael@0 2927 return;
michael@0 2928 }
michael@0 2929 sock.recv_queue.push({ addr: peer.addr, port: peer.port, data: data });
michael@0 2930 };
michael@0 2931 if (ENVIRONMENT_IS_NODE) {
michael@0 2932 peer.socket.on('open', handleOpen);
michael@0 2933 peer.socket.on('message', function(data, flags) {
michael@0 2934 if (!flags.binary) {
michael@0 2935 return;
michael@0 2936 }
michael@0 2937 handleMessage((new Uint8Array(data)).buffer); // copy from node Buffer -> ArrayBuffer
michael@0 2938 });
michael@0 2939 peer.socket.on('error', function() {
michael@0 2940 // don't throw
michael@0 2941 });
michael@0 2942 } else {
michael@0 2943 peer.socket.onopen = handleOpen;
michael@0 2944 peer.socket.onmessage = function(event) {
michael@0 2945 handleMessage(event.data);
michael@0 2946 };
michael@0 2947 }
michael@0 2948 },poll:function (sock) {
michael@0 2949 if (sock.type === 1 && sock.server) {
michael@0 2950 // listen sockets should only say they're available for reading
michael@0 2951 // if there are pending clients.
michael@0 2952 return sock.pending.length ? (0 /* XXX missing C define POLLRDNORM */ | 1) : 0;
michael@0 2953 }
michael@0 2954 var mask = 0;
michael@0 2955 var dest = sock.type === 1 ? // we only care about the socket state for connection-based sockets
michael@0 2956 SOCKFS.websocket_sock_ops.getPeer(sock, sock.daddr, sock.dport) :
michael@0 2957 null;
michael@0 2958 if (sock.recv_queue.length ||
michael@0 2959 !dest || // connection-less sockets are always ready to read
michael@0 2960 (dest && dest.socket.readyState === dest.socket.CLOSING) ||
michael@0 2961 (dest && dest.socket.readyState === dest.socket.CLOSED)) { // let recv return 0 once closed
michael@0 2962 mask |= (0 /* XXX missing C define POLLRDNORM */ | 1);
michael@0 2963 }
michael@0 2964 if (!dest || // connection-less sockets are always ready to write
michael@0 2965 (dest && dest.socket.readyState === dest.socket.OPEN)) {
michael@0 2966 mask |= 2;
michael@0 2967 }
michael@0 2968 if ((dest && dest.socket.readyState === dest.socket.CLOSING) ||
michael@0 2969 (dest && dest.socket.readyState === dest.socket.CLOSED)) {
michael@0 2970 mask |= 16;
michael@0 2971 }
michael@0 2972 return mask;
michael@0 2973 },ioctl:function (sock, request, arg) {
michael@0 2974 switch (request) {
michael@0 2975 case 1:
michael@0 2976 var bytes = 0;
michael@0 2977 if (sock.recv_queue.length) {
michael@0 2978 bytes = sock.recv_queue[0].data.length;
michael@0 2979 }
michael@0 2980 HEAP32[((arg)>>2)]=bytes;
michael@0 2981 return 0;
michael@0 2982 default:
michael@0 2983 return ERRNO_CODES.EINVAL;
michael@0 2984 }
michael@0 2985 },close:function (sock) {
michael@0 2986 // if we've spawned a listen server, close it
michael@0 2987 if (sock.server) {
michael@0 2988 try {
michael@0 2989 sock.server.close();
michael@0 2990 } catch (e) {
michael@0 2991 }
michael@0 2992 sock.server = null;
michael@0 2993 }
michael@0 2994 // close any peer connections
michael@0 2995 var peers = Object.keys(sock.peers);
michael@0 2996 for (var i = 0; i < peers.length; i++) {
michael@0 2997 var peer = sock.peers[peers[i]];
michael@0 2998 try {
michael@0 2999 peer.socket.close();
michael@0 3000 } catch (e) {
michael@0 3001 }
michael@0 3002 SOCKFS.websocket_sock_ops.removePeer(sock, peer);
michael@0 3003 }
michael@0 3004 return 0;
michael@0 3005 },bind:function (sock, addr, port) {
michael@0 3006 if (typeof sock.saddr !== 'undefined' || typeof sock.sport !== 'undefined') {
michael@0 3007 throw new FS.ErrnoError(ERRNO_CODES.EINVAL); // already bound
michael@0 3008 }
michael@0 3009 sock.saddr = addr;
michael@0 3010 sock.sport = port || _mkport();
michael@0 3011 // in order to emulate dgram sockets, we need to launch a listen server when
michael@0 3012 // binding on a connection-less socket
michael@0 3013 // note: this is only required on the server side
michael@0 3014 if (sock.type === 2) {
michael@0 3015 // close the existing server if it exists
michael@0 3016 if (sock.server) {
michael@0 3017 sock.server.close();
michael@0 3018 sock.server = null;
michael@0 3019 }
michael@0 3020 // swallow error operation not supported error that occurs when binding in the
michael@0 3021 // browser where this isn't supported
michael@0 3022 try {
michael@0 3023 sock.sock_ops.listen(sock, 0);
michael@0 3024 } catch (e) {
michael@0 3025 if (!(e instanceof FS.ErrnoError)) throw e;
michael@0 3026 if (e.errno !== ERRNO_CODES.EOPNOTSUPP) throw e;
michael@0 3027 }
michael@0 3028 }
michael@0 3029 },connect:function (sock, addr, port) {
michael@0 3030 if (sock.server) {
michael@0 3031 throw new FS.ErrnoError(ERRNO_CODS.EOPNOTSUPP);
michael@0 3032 }
michael@0 3033 // TODO autobind
michael@0 3034 // if (!sock.addr && sock.type == 2) {
michael@0 3035 // }
michael@0 3036 // early out if we're already connected / in the middle of connecting
michael@0 3037 if (typeof sock.daddr !== 'undefined' && typeof sock.dport !== 'undefined') {
michael@0 3038 var dest = SOCKFS.websocket_sock_ops.getPeer(sock, sock.daddr, sock.dport);
michael@0 3039 if (dest) {
michael@0 3040 if (dest.socket.readyState === dest.socket.CONNECTING) {
michael@0 3041 throw new FS.ErrnoError(ERRNO_CODES.EALREADY);
michael@0 3042 } else {
michael@0 3043 throw new FS.ErrnoError(ERRNO_CODES.EISCONN);
michael@0 3044 }
michael@0 3045 }
michael@0 3046 }
michael@0 3047 // add the socket to our peer list and set our
michael@0 3048 // destination address / port to match
michael@0 3049 var peer = SOCKFS.websocket_sock_ops.createPeer(sock, addr, port);
michael@0 3050 sock.daddr = peer.addr;
michael@0 3051 sock.dport = peer.port;
michael@0 3052 // always "fail" in non-blocking mode
michael@0 3053 throw new FS.ErrnoError(ERRNO_CODES.EINPROGRESS);
michael@0 3054 },listen:function (sock, backlog) {
michael@0 3055 if (!ENVIRONMENT_IS_NODE) {
michael@0 3056 throw new FS.ErrnoError(ERRNO_CODES.EOPNOTSUPP);
michael@0 3057 }
michael@0 3058 if (sock.server) {
michael@0 3059 throw new FS.ErrnoError(ERRNO_CODES.EINVAL); // already listening
michael@0 3060 }
michael@0 3061 var WebSocketServer = require('ws').Server;
michael@0 3062 var host = sock.saddr;
michael@0 3063 sock.server = new WebSocketServer({
michael@0 3064 host: host,
michael@0 3065 port: sock.sport
michael@0 3066 // TODO support backlog
michael@0 3067 });
michael@0 3068 sock.server.on('connection', function(ws) {
michael@0 3069 if (sock.type === 1) {
michael@0 3070 var newsock = SOCKFS.createSocket(sock.family, sock.type, sock.protocol);
michael@0 3071 // create a peer on the new socket
michael@0 3072 var peer = SOCKFS.websocket_sock_ops.createPeer(newsock, ws);
michael@0 3073 newsock.daddr = peer.addr;
michael@0 3074 newsock.dport = peer.port;
michael@0 3075 // push to queue for accept to pick up
michael@0 3076 sock.pending.push(newsock);
michael@0 3077 } else {
michael@0 3078 // create a peer on the listen socket so calling sendto
michael@0 3079 // with the listen socket and an address will resolve
michael@0 3080 // to the correct client
michael@0 3081 SOCKFS.websocket_sock_ops.createPeer(sock, ws);
michael@0 3082 }
michael@0 3083 });
michael@0 3084 sock.server.on('closed', function() {
michael@0 3085 sock.server = null;
michael@0 3086 });
michael@0 3087 sock.server.on('error', function() {
michael@0 3088 // don't throw
michael@0 3089 });
michael@0 3090 },accept:function (listensock) {
michael@0 3091 if (!listensock.server) {
michael@0 3092 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 3093 }
michael@0 3094 var newsock = listensock.pending.shift();
michael@0 3095 newsock.stream.flags = listensock.stream.flags;
michael@0 3096 return newsock;
michael@0 3097 },getname:function (sock, peer) {
michael@0 3098 var addr, port;
michael@0 3099 if (peer) {
michael@0 3100 if (sock.daddr === undefined || sock.dport === undefined) {
michael@0 3101 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
michael@0 3102 }
michael@0 3103 addr = sock.daddr;
michael@0 3104 port = sock.dport;
michael@0 3105 } else {
michael@0 3106 // TODO saddr and sport will be set for bind()'d UDP sockets, but what
michael@0 3107 // should we be returning for TCP sockets that've been connect()'d?
michael@0 3108 addr = sock.saddr || 0;
michael@0 3109 port = sock.sport || 0;
michael@0 3110 }
michael@0 3111 return { addr: addr, port: port };
michael@0 3112 },sendmsg:function (sock, buffer, offset, length, addr, port) {
michael@0 3113 if (sock.type === 2) {
michael@0 3114 // connection-less sockets will honor the message address,
michael@0 3115 // and otherwise fall back to the bound destination address
michael@0 3116 if (addr === undefined || port === undefined) {
michael@0 3117 addr = sock.daddr;
michael@0 3118 port = sock.dport;
michael@0 3119 }
michael@0 3120 // if there was no address to fall back to, error out
michael@0 3121 if (addr === undefined || port === undefined) {
michael@0 3122 throw new FS.ErrnoError(ERRNO_CODES.EDESTADDRREQ);
michael@0 3123 }
michael@0 3124 } else {
michael@0 3125 // connection-based sockets will only use the bound
michael@0 3126 addr = sock.daddr;
michael@0 3127 port = sock.dport;
michael@0 3128 }
michael@0 3129 // find the peer for the destination address
michael@0 3130 var dest = SOCKFS.websocket_sock_ops.getPeer(sock, addr, port);
michael@0 3131 // early out if not connected with a connection-based socket
michael@0 3132 if (sock.type === 1) {
michael@0 3133 if (!dest || dest.socket.readyState === dest.socket.CLOSING || dest.socket.readyState === dest.socket.CLOSED) {
michael@0 3134 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
michael@0 3135 } else if (dest.socket.readyState === dest.socket.CONNECTING) {
michael@0 3136 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
michael@0 3137 }
michael@0 3138 }
michael@0 3139 // create a copy of the incoming data to send, as the WebSocket API
michael@0 3140 // doesn't work entirely with an ArrayBufferView, it'll just send
michael@0 3141 // the entire underlying buffer
michael@0 3142 var data;
michael@0 3143 if (buffer instanceof Array || buffer instanceof ArrayBuffer) {
michael@0 3144 data = buffer.slice(offset, offset + length);
michael@0 3145 } else { // ArrayBufferView
michael@0 3146 data = buffer.buffer.slice(buffer.byteOffset + offset, buffer.byteOffset + offset + length);
michael@0 3147 }
michael@0 3148 // if we're emulating a connection-less dgram socket and don't have
michael@0 3149 // a cached connection, queue the buffer to send upon connect and
michael@0 3150 // lie, saying the data was sent now.
michael@0 3151 if (sock.type === 2) {
michael@0 3152 if (!dest || dest.socket.readyState !== dest.socket.OPEN) {
michael@0 3153 // if we're not connected, open a new connection
michael@0 3154 if (!dest || dest.socket.readyState === dest.socket.CLOSING || dest.socket.readyState === dest.socket.CLOSED) {
michael@0 3155 dest = SOCKFS.websocket_sock_ops.createPeer(sock, addr, port);
michael@0 3156 }
michael@0 3157 dest.dgram_send_queue.push(data);
michael@0 3158 return length;
michael@0 3159 }
michael@0 3160 }
michael@0 3161 try {
michael@0 3162 // send the actual data
michael@0 3163 dest.socket.send(data);
michael@0 3164 return length;
michael@0 3165 } catch (e) {
michael@0 3166 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
michael@0 3167 }
michael@0 3168 },recvmsg:function (sock, length) {
michael@0 3169 // http://pubs.opengroup.org/onlinepubs/7908799/xns/recvmsg.html
michael@0 3170 if (sock.type === 1 && sock.server) {
michael@0 3171 // tcp servers should not be recv()'ing on the listen socket
michael@0 3172 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
michael@0 3173 }
michael@0 3174 var queued = sock.recv_queue.shift();
michael@0 3175 if (!queued) {
michael@0 3176 if (sock.type === 1) {
michael@0 3177 var dest = SOCKFS.websocket_sock_ops.getPeer(sock, sock.daddr, sock.dport);
michael@0 3178 if (!dest) {
michael@0 3179 // if we have a destination address but are not connected, error out
michael@0 3180 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
michael@0 3181 }
michael@0 3182 else if (dest.socket.readyState === dest.socket.CLOSING || dest.socket.readyState === dest.socket.CLOSED) {
michael@0 3183 // return null if the socket has closed
michael@0 3184 return null;
michael@0 3185 }
michael@0 3186 else {
michael@0 3187 // else, our socket is in a valid state but truly has nothing available
michael@0 3188 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
michael@0 3189 }
michael@0 3190 } else {
michael@0 3191 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
michael@0 3192 }
michael@0 3193 }
michael@0 3194 // queued.data will be an ArrayBuffer if it's unadulterated, but if it's
michael@0 3195 // requeued TCP data it'll be an ArrayBufferView
michael@0 3196 var queuedLength = queued.data.byteLength || queued.data.length;
michael@0 3197 var queuedOffset = queued.data.byteOffset || 0;
michael@0 3198 var queuedBuffer = queued.data.buffer || queued.data;
michael@0 3199 var bytesRead = Math.min(length, queuedLength);
michael@0 3200 var res = {
michael@0 3201 buffer: new Uint8Array(queuedBuffer, queuedOffset, bytesRead),
michael@0 3202 addr: queued.addr,
michael@0 3203 port: queued.port
michael@0 3204 };
michael@0 3205 // push back any unread data for TCP connections
michael@0 3206 if (sock.type === 1 && bytesRead < queuedLength) {
michael@0 3207 var bytesRemaining = queuedLength - bytesRead;
michael@0 3208 queued.data = new Uint8Array(queuedBuffer, queuedOffset + bytesRead, bytesRemaining);
michael@0 3209 sock.recv_queue.unshift(queued);
michael@0 3210 }
michael@0 3211 return res;
michael@0 3212 }}};function _send(fd, buf, len, flags) {
michael@0 3213 var sock = SOCKFS.getSocket(fd);
michael@0 3214 if (!sock) {
michael@0 3215 ___setErrNo(ERRNO_CODES.EBADF);
michael@0 3216 return -1;
michael@0 3217 }
michael@0 3218 // TODO honor flags
michael@0 3219 return _write(fd, buf, len);
michael@0 3220 }
michael@0 3221 function _pwrite(fildes, buf, nbyte, offset) {
michael@0 3222 // ssize_t pwrite(int fildes, const void *buf, size_t nbyte, off_t offset);
michael@0 3223 // http://pubs.opengroup.org/onlinepubs/000095399/functions/write.html
michael@0 3224 var stream = FS.getStream(fildes);
michael@0 3225 if (!stream) {
michael@0 3226 ___setErrNo(ERRNO_CODES.EBADF);
michael@0 3227 return -1;
michael@0 3228 }
michael@0 3229 try {
michael@0 3230 var slab = HEAP8;
michael@0 3231 return FS.write(stream, slab, buf, nbyte, offset);
michael@0 3232 } catch (e) {
michael@0 3233 FS.handleFSError(e);
michael@0 3234 return -1;
michael@0 3235 }
michael@0 3236 }function _write(fildes, buf, nbyte) {
michael@0 3237 // ssize_t write(int fildes, const void *buf, size_t nbyte);
michael@0 3238 // http://pubs.opengroup.org/onlinepubs/000095399/functions/write.html
michael@0 3239 var stream = FS.getStream(fildes);
michael@0 3240 if (!stream) {
michael@0 3241 ___setErrNo(ERRNO_CODES.EBADF);
michael@0 3242 return -1;
michael@0 3243 }
michael@0 3244 try {
michael@0 3245 var slab = HEAP8;
michael@0 3246 return FS.write(stream, slab, buf, nbyte);
michael@0 3247 } catch (e) {
michael@0 3248 FS.handleFSError(e);
michael@0 3249 return -1;
michael@0 3250 }
michael@0 3251 }function _fwrite(ptr, size, nitems, stream) {
michael@0 3252 // size_t fwrite(const void *restrict ptr, size_t size, size_t nitems, FILE *restrict stream);
michael@0 3253 // http://pubs.opengroup.org/onlinepubs/000095399/functions/fwrite.html
michael@0 3254 var bytesToWrite = nitems * size;
michael@0 3255 if (bytesToWrite == 0) return 0;
michael@0 3256 var bytesWritten = _write(stream, ptr, bytesToWrite);
michael@0 3257 if (bytesWritten == -1) {
michael@0 3258 var streamObj = FS.getStream(stream);
michael@0 3259 if (streamObj) streamObj.error = true;
michael@0 3260 return 0;
michael@0 3261 } else {
michael@0 3262 return Math.floor(bytesWritten / size);
michael@0 3263 }
michael@0 3264 }
michael@0 3265 Module["_strlen"] = _strlen;
michael@0 3266 function __reallyNegative(x) {
michael@0 3267 return x < 0 || (x === 0 && (1/x) === -Infinity);
michael@0 3268 }function __formatString(format, varargs) {
michael@0 3269 var textIndex = format;
michael@0 3270 var argIndex = 0;
michael@0 3271 function getNextArg(type) {
michael@0 3272 // NOTE: Explicitly ignoring type safety. Otherwise this fails:
michael@0 3273 // int x = 4; printf("%c\n", (char)x);
michael@0 3274 var ret;
michael@0 3275 if (type === 'double') {
michael@0 3276 ret = HEAPF64[(((varargs)+(argIndex))>>3)];
michael@0 3277 } else if (type == 'i64') {
michael@0 3278 ret = [HEAP32[(((varargs)+(argIndex))>>2)],
michael@0 3279 HEAP32[(((varargs)+(argIndex+8))>>2)]];
michael@0 3280 argIndex += 8; // each 32-bit chunk is in a 64-bit block
michael@0 3281 } else {
michael@0 3282 type = 'i32'; // varargs are always i32, i64, or double
michael@0 3283 ret = HEAP32[(((varargs)+(argIndex))>>2)];
michael@0 3284 }
michael@0 3285 argIndex += Math.max(Runtime.getNativeFieldSize(type), Runtime.getAlignSize(type, null, true));
michael@0 3286 return ret;
michael@0 3287 }
michael@0 3288 var ret = [];
michael@0 3289 var curr, next, currArg;
michael@0 3290 while(1) {
michael@0 3291 var startTextIndex = textIndex;
michael@0 3292 curr = HEAP8[(textIndex)];
michael@0 3293 if (curr === 0) break;
michael@0 3294 next = HEAP8[((textIndex+1)|0)];
michael@0 3295 if (curr == 37) {
michael@0 3296 // Handle flags.
michael@0 3297 var flagAlwaysSigned = false;
michael@0 3298 var flagLeftAlign = false;
michael@0 3299 var flagAlternative = false;
michael@0 3300 var flagZeroPad = false;
michael@0 3301 flagsLoop: while (1) {
michael@0 3302 switch (next) {
michael@0 3303 case 43:
michael@0 3304 flagAlwaysSigned = true;
michael@0 3305 break;
michael@0 3306 case 45:
michael@0 3307 flagLeftAlign = true;
michael@0 3308 break;
michael@0 3309 case 35:
michael@0 3310 flagAlternative = true;
michael@0 3311 break;
michael@0 3312 case 48:
michael@0 3313 if (flagZeroPad) {
michael@0 3314 break flagsLoop;
michael@0 3315 } else {
michael@0 3316 flagZeroPad = true;
michael@0 3317 break;
michael@0 3318 }
michael@0 3319 default:
michael@0 3320 break flagsLoop;
michael@0 3321 }
michael@0 3322 textIndex++;
michael@0 3323 next = HEAP8[((textIndex+1)|0)];
michael@0 3324 }
michael@0 3325 // Handle width.
michael@0 3326 var width = 0;
michael@0 3327 if (next == 42) {
michael@0 3328 width = getNextArg('i32');
michael@0 3329 textIndex++;
michael@0 3330 next = HEAP8[((textIndex+1)|0)];
michael@0 3331 } else {
michael@0 3332 while (next >= 48 && next <= 57) {
michael@0 3333 width = width * 10 + (next - 48);
michael@0 3334 textIndex++;
michael@0 3335 next = HEAP8[((textIndex+1)|0)];
michael@0 3336 }
michael@0 3337 }
michael@0 3338 // Handle precision.
michael@0 3339 var precisionSet = false;
michael@0 3340 if (next == 46) {
michael@0 3341 var precision = 0;
michael@0 3342 precisionSet = true;
michael@0 3343 textIndex++;
michael@0 3344 next = HEAP8[((textIndex+1)|0)];
michael@0 3345 if (next == 42) {
michael@0 3346 precision = getNextArg('i32');
michael@0 3347 textIndex++;
michael@0 3348 } else {
michael@0 3349 while(1) {
michael@0 3350 var precisionChr = HEAP8[((textIndex+1)|0)];
michael@0 3351 if (precisionChr < 48 ||
michael@0 3352 precisionChr > 57) break;
michael@0 3353 precision = precision * 10 + (precisionChr - 48);
michael@0 3354 textIndex++;
michael@0 3355 }
michael@0 3356 }
michael@0 3357 next = HEAP8[((textIndex+1)|0)];
michael@0 3358 } else {
michael@0 3359 var precision = 6; // Standard default.
michael@0 3360 }
michael@0 3361 // Handle integer sizes. WARNING: These assume a 32-bit architecture!
michael@0 3362 var argSize;
michael@0 3363 switch (String.fromCharCode(next)) {
michael@0 3364 case 'h':
michael@0 3365 var nextNext = HEAP8[((textIndex+2)|0)];
michael@0 3366 if (nextNext == 104) {
michael@0 3367 textIndex++;
michael@0 3368 argSize = 1; // char (actually i32 in varargs)
michael@0 3369 } else {
michael@0 3370 argSize = 2; // short (actually i32 in varargs)
michael@0 3371 }
michael@0 3372 break;
michael@0 3373 case 'l':
michael@0 3374 var nextNext = HEAP8[((textIndex+2)|0)];
michael@0 3375 if (nextNext == 108) {
michael@0 3376 textIndex++;
michael@0 3377 argSize = 8; // long long
michael@0 3378 } else {
michael@0 3379 argSize = 4; // long
michael@0 3380 }
michael@0 3381 break;
michael@0 3382 case 'L': // long long
michael@0 3383 case 'q': // int64_t
michael@0 3384 case 'j': // intmax_t
michael@0 3385 argSize = 8;
michael@0 3386 break;
michael@0 3387 case 'z': // size_t
michael@0 3388 case 't': // ptrdiff_t
michael@0 3389 case 'I': // signed ptrdiff_t or unsigned size_t
michael@0 3390 argSize = 4;
michael@0 3391 break;
michael@0 3392 default:
michael@0 3393 argSize = null;
michael@0 3394 }
michael@0 3395 if (argSize) textIndex++;
michael@0 3396 next = HEAP8[((textIndex+1)|0)];
michael@0 3397 // Handle type specifier.
michael@0 3398 switch (String.fromCharCode(next)) {
michael@0 3399 case 'd': case 'i': case 'u': case 'o': case 'x': case 'X': case 'p': {
michael@0 3400 // Integer.
michael@0 3401 var signed = next == 100 || next == 105;
michael@0 3402 argSize = argSize || 4;
michael@0 3403 var currArg = getNextArg('i' + (argSize * 8));
michael@0 3404 var origArg = currArg;
michael@0 3405 var argText;
michael@0 3406 // Flatten i64-1 [low, high] into a (slightly rounded) double
michael@0 3407 if (argSize == 8) {
michael@0 3408 currArg = Runtime.makeBigInt(currArg[0], currArg[1], next == 117);
michael@0 3409 }
michael@0 3410 // Truncate to requested size.
michael@0 3411 if (argSize <= 4) {
michael@0 3412 var limit = Math.pow(256, argSize) - 1;
michael@0 3413 currArg = (signed ? reSign : unSign)(currArg & limit, argSize * 8);
michael@0 3414 }
michael@0 3415 // Format the number.
michael@0 3416 var currAbsArg = Math.abs(currArg);
michael@0 3417 var prefix = '';
michael@0 3418 if (next == 100 || next == 105) {
michael@0 3419 if (argSize == 8 && i64Math) argText = i64Math.stringify(origArg[0], origArg[1], null); else
michael@0 3420 argText = reSign(currArg, 8 * argSize, 1).toString(10);
michael@0 3421 } else if (next == 117) {
michael@0 3422 if (argSize == 8 && i64Math) argText = i64Math.stringify(origArg[0], origArg[1], true); else
michael@0 3423 argText = unSign(currArg, 8 * argSize, 1).toString(10);
michael@0 3424 currArg = Math.abs(currArg);
michael@0 3425 } else if (next == 111) {
michael@0 3426 argText = (flagAlternative ? '0' : '') + currAbsArg.toString(8);
michael@0 3427 } else if (next == 120 || next == 88) {
michael@0 3428 prefix = (flagAlternative && currArg != 0) ? '0x' : '';
michael@0 3429 if (argSize == 8 && i64Math) {
michael@0 3430 if (origArg[1]) {
michael@0 3431 argText = (origArg[1]>>>0).toString(16);
michael@0 3432 var lower = (origArg[0]>>>0).toString(16);
michael@0 3433 while (lower.length < 8) lower = '0' + lower;
michael@0 3434 argText += lower;
michael@0 3435 } else {
michael@0 3436 argText = (origArg[0]>>>0).toString(16);
michael@0 3437 }
michael@0 3438 } else
michael@0 3439 if (currArg < 0) {
michael@0 3440 // Represent negative numbers in hex as 2's complement.
michael@0 3441 currArg = -currArg;
michael@0 3442 argText = (currAbsArg - 1).toString(16);
michael@0 3443 var buffer = [];
michael@0 3444 for (var i = 0; i < argText.length; i++) {
michael@0 3445 buffer.push((0xF - parseInt(argText[i], 16)).toString(16));
michael@0 3446 }
michael@0 3447 argText = buffer.join('');
michael@0 3448 while (argText.length < argSize * 2) argText = 'f' + argText;
michael@0 3449 } else {
michael@0 3450 argText = currAbsArg.toString(16);
michael@0 3451 }
michael@0 3452 if (next == 88) {
michael@0 3453 prefix = prefix.toUpperCase();
michael@0 3454 argText = argText.toUpperCase();
michael@0 3455 }
michael@0 3456 } else if (next == 112) {
michael@0 3457 if (currAbsArg === 0) {
michael@0 3458 argText = '(nil)';
michael@0 3459 } else {
michael@0 3460 prefix = '0x';
michael@0 3461 argText = currAbsArg.toString(16);
michael@0 3462 }
michael@0 3463 }
michael@0 3464 if (precisionSet) {
michael@0 3465 while (argText.length < precision) {
michael@0 3466 argText = '0' + argText;
michael@0 3467 }
michael@0 3468 }
michael@0 3469 // Add sign if needed
michael@0 3470 if (flagAlwaysSigned) {
michael@0 3471 if (currArg < 0) {
michael@0 3472 prefix = '-' + prefix;
michael@0 3473 } else {
michael@0 3474 prefix = '+' + prefix;
michael@0 3475 }
michael@0 3476 }
michael@0 3477 // Add padding.
michael@0 3478 while (prefix.length + argText.length < width) {
michael@0 3479 if (flagLeftAlign) {
michael@0 3480 argText += ' ';
michael@0 3481 } else {
michael@0 3482 if (flagZeroPad) {
michael@0 3483 argText = '0' + argText;
michael@0 3484 } else {
michael@0 3485 prefix = ' ' + prefix;
michael@0 3486 }
michael@0 3487 }
michael@0 3488 }
michael@0 3489 // Insert the result into the buffer.
michael@0 3490 argText = prefix + argText;
michael@0 3491 argText.split('').forEach(function(chr) {
michael@0 3492 ret.push(chr.charCodeAt(0));
michael@0 3493 });
michael@0 3494 break;
michael@0 3495 }
michael@0 3496 case 'f': case 'F': case 'e': case 'E': case 'g': case 'G': {
michael@0 3497 // Float.
michael@0 3498 var currArg = getNextArg('double');
michael@0 3499 var argText;
michael@0 3500 if (isNaN(currArg)) {
michael@0 3501 argText = 'nan';
michael@0 3502 flagZeroPad = false;
michael@0 3503 } else if (!isFinite(currArg)) {
michael@0 3504 argText = (currArg < 0 ? '-' : '') + 'inf';
michael@0 3505 flagZeroPad = false;
michael@0 3506 } else {
michael@0 3507 var isGeneral = false;
michael@0 3508 var effectivePrecision = Math.min(precision, 20);
michael@0 3509 // Convert g/G to f/F or e/E, as per:
michael@0 3510 // http://pubs.opengroup.org/onlinepubs/9699919799/functions/printf.html
michael@0 3511 if (next == 103 || next == 71) {
michael@0 3512 isGeneral = true;
michael@0 3513 precision = precision || 1;
michael@0 3514 var exponent = parseInt(currArg.toExponential(effectivePrecision).split('e')[1], 10);
michael@0 3515 if (precision > exponent && exponent >= -4) {
michael@0 3516 next = ((next == 103) ? 'f' : 'F').charCodeAt(0);
michael@0 3517 precision -= exponent + 1;
michael@0 3518 } else {
michael@0 3519 next = ((next == 103) ? 'e' : 'E').charCodeAt(0);
michael@0 3520 precision--;
michael@0 3521 }
michael@0 3522 effectivePrecision = Math.min(precision, 20);
michael@0 3523 }
michael@0 3524 if (next == 101 || next == 69) {
michael@0 3525 argText = currArg.toExponential(effectivePrecision);
michael@0 3526 // Make sure the exponent has at least 2 digits.
michael@0 3527 if (/[eE][-+]\d$/.test(argText)) {
michael@0 3528 argText = argText.slice(0, -1) + '0' + argText.slice(-1);
michael@0 3529 }
michael@0 3530 } else if (next == 102 || next == 70) {
michael@0 3531 argText = currArg.toFixed(effectivePrecision);
michael@0 3532 if (currArg === 0 && __reallyNegative(currArg)) {
michael@0 3533 argText = '-' + argText;
michael@0 3534 }
michael@0 3535 }
michael@0 3536 var parts = argText.split('e');
michael@0 3537 if (isGeneral && !flagAlternative) {
michael@0 3538 // Discard trailing zeros and periods.
michael@0 3539 while (parts[0].length > 1 && parts[0].indexOf('.') != -1 &&
michael@0 3540 (parts[0].slice(-1) == '0' || parts[0].slice(-1) == '.')) {
michael@0 3541 parts[0] = parts[0].slice(0, -1);
michael@0 3542 }
michael@0 3543 } else {
michael@0 3544 // Make sure we have a period in alternative mode.
michael@0 3545 if (flagAlternative && argText.indexOf('.') == -1) parts[0] += '.';
michael@0 3546 // Zero pad until required precision.
michael@0 3547 while (precision > effectivePrecision++) parts[0] += '0';
michael@0 3548 }
michael@0 3549 argText = parts[0] + (parts.length > 1 ? 'e' + parts[1] : '');
michael@0 3550 // Capitalize 'E' if needed.
michael@0 3551 if (next == 69) argText = argText.toUpperCase();
michael@0 3552 // Add sign.
michael@0 3553 if (flagAlwaysSigned && currArg >= 0) {
michael@0 3554 argText = '+' + argText;
michael@0 3555 }
michael@0 3556 }
michael@0 3557 // Add padding.
michael@0 3558 while (argText.length < width) {
michael@0 3559 if (flagLeftAlign) {
michael@0 3560 argText += ' ';
michael@0 3561 } else {
michael@0 3562 if (flagZeroPad && (argText[0] == '-' || argText[0] == '+')) {
michael@0 3563 argText = argText[0] + '0' + argText.slice(1);
michael@0 3564 } else {
michael@0 3565 argText = (flagZeroPad ? '0' : ' ') + argText;
michael@0 3566 }
michael@0 3567 }
michael@0 3568 }
michael@0 3569 // Adjust case.
michael@0 3570 if (next < 97) argText = argText.toUpperCase();
michael@0 3571 // Insert the result into the buffer.
michael@0 3572 argText.split('').forEach(function(chr) {
michael@0 3573 ret.push(chr.charCodeAt(0));
michael@0 3574 });
michael@0 3575 break;
michael@0 3576 }
michael@0 3577 case 's': {
michael@0 3578 // String.
michael@0 3579 var arg = getNextArg('i8*');
michael@0 3580 var argLength = arg ? _strlen(arg) : '(null)'.length;
michael@0 3581 if (precisionSet) argLength = Math.min(argLength, precision);
michael@0 3582 if (!flagLeftAlign) {
michael@0 3583 while (argLength < width--) {
michael@0 3584 ret.push(32);
michael@0 3585 }
michael@0 3586 }
michael@0 3587 if (arg) {
michael@0 3588 for (var i = 0; i < argLength; i++) {
michael@0 3589 ret.push(HEAPU8[((arg++)|0)]);
michael@0 3590 }
michael@0 3591 } else {
michael@0 3592 ret = ret.concat(intArrayFromString('(null)'.substr(0, argLength), true));
michael@0 3593 }
michael@0 3594 if (flagLeftAlign) {
michael@0 3595 while (argLength < width--) {
michael@0 3596 ret.push(32);
michael@0 3597 }
michael@0 3598 }
michael@0 3599 break;
michael@0 3600 }
michael@0 3601 case 'c': {
michael@0 3602 // Character.
michael@0 3603 if (flagLeftAlign) ret.push(getNextArg('i8'));
michael@0 3604 while (--width > 0) {
michael@0 3605 ret.push(32);
michael@0 3606 }
michael@0 3607 if (!flagLeftAlign) ret.push(getNextArg('i8'));
michael@0 3608 break;
michael@0 3609 }
michael@0 3610 case 'n': {
michael@0 3611 // Write the length written so far to the next parameter.
michael@0 3612 var ptr = getNextArg('i32*');
michael@0 3613 HEAP32[((ptr)>>2)]=ret.length
michael@0 3614 break;
michael@0 3615 }
michael@0 3616 case '%': {
michael@0 3617 // Literal percent sign.
michael@0 3618 ret.push(curr);
michael@0 3619 break;
michael@0 3620 }
michael@0 3621 default: {
michael@0 3622 // Unknown specifiers remain untouched.
michael@0 3623 for (var i = startTextIndex; i < textIndex + 2; i++) {
michael@0 3624 ret.push(HEAP8[(i)]);
michael@0 3625 }
michael@0 3626 }
michael@0 3627 }
michael@0 3628 textIndex += 2;
michael@0 3629 // TODO: Support a/A (hex float) and m (last error) specifiers.
michael@0 3630 // TODO: Support %1${specifier} for arg selection.
michael@0 3631 } else {
michael@0 3632 ret.push(curr);
michael@0 3633 textIndex += 1;
michael@0 3634 }
michael@0 3635 }
michael@0 3636 return ret;
michael@0 3637 }function _fprintf(stream, format, varargs) {
michael@0 3638 // int fprintf(FILE *restrict stream, const char *restrict format, ...);
michael@0 3639 // http://pubs.opengroup.org/onlinepubs/000095399/functions/printf.html
michael@0 3640 var result = __formatString(format, varargs);
michael@0 3641 var stack = Runtime.stackSave();
michael@0 3642 var ret = _fwrite(allocate(result, 'i8', ALLOC_STACK), 1, result.length, stream);
michael@0 3643 Runtime.stackRestore(stack);
michael@0 3644 return ret;
michael@0 3645 }function _printf(format, varargs) {
michael@0 3646 // int printf(const char *restrict format, ...);
michael@0 3647 // http://pubs.opengroup.org/onlinepubs/000095399/functions/printf.html
michael@0 3648 var stdout = HEAP32[((_stdout)>>2)];
michael@0 3649 return _fprintf(stdout, format, varargs);
michael@0 3650 }
michael@0 3651 Module["_memcpy"] = _memcpy;var _llvm_memcpy_p0i8_p0i8_i32=_memcpy;
michael@0 3652 function ___cxa_guard_acquire(variable) {
michael@0 3653 if (!HEAP8[(variable)]) { // ignore SAFE_HEAP stuff because llvm mixes i64 and i8 here
michael@0 3654 HEAP8[(variable)]=1;
michael@0 3655 return 1;
michael@0 3656 }
michael@0 3657 return 0;
michael@0 3658 }
michael@0 3659 function ___cxa_guard_release() {}
michael@0 3660 Module["_memset"] = _memset;var _llvm_memset_p0i8_i64=_memset;
michael@0 3661 var _sinf=Math.sin;
michael@0 3662 var _cosf=Math.cos;
michael@0 3663 var _sqrtf=Math.sqrt;
michael@0 3664 var _fabsf=Math.abs;
michael@0 3665 function _llvm_lifetime_start() {}
michael@0 3666 function _llvm_lifetime_end() {}
michael@0 3667 function _fmod(x, y) {
michael@0 3668 return x % y;
michael@0 3669 }var _fmodf=_fmod;
michael@0 3670 var _atan2f=Math.atan2;
michael@0 3671 var _llvm_pow_f32=Math.pow;
michael@0 3672 var _acosf=Math.acos;
michael@0 3673 var _llvm_memset_p0i8_i32=_memset;
michael@0 3674 function _atexit(func, arg) {
michael@0 3675 __ATEXIT__.unshift({ func: func, arg: arg });
michael@0 3676 }var ___cxa_atexit=_atexit;
michael@0 3677 function ___cxa_guard_abort() {}
michael@0 3678 function ___cxa_pure_virtual() {
michael@0 3679 ABORT = true;
michael@0 3680 throw 'Pure virtual function called!';
michael@0 3681 }
michael@0 3682 function ___assert_func(filename, line, func, condition) {
michael@0 3683 throw 'Assertion failed: ' + (condition ? Pointer_stringify(condition) : 'unknown condition') + ', at: ' + [filename ? Pointer_stringify(filename) : 'unknown filename', line, func ? Pointer_stringify(func) : 'unknown function'] + ' at ' + new Error().stack;
michael@0 3684 }
michael@0 3685 Module["_llvm_uadd_with_overflow_i64"] = _llvm_uadd_with_overflow_i64;
michael@0 3686 function _gettimeofday(ptr) {
michael@0 3687 // %struct.timeval = type { i32, i32 }
michael@0 3688 var now = Date.now();
michael@0 3689 HEAP32[((ptr)>>2)]=Math.floor(now/1000); // seconds
michael@0 3690 HEAP32[(((ptr)+(4))>>2)]=Math.floor((now-1000*Math.floor(now/1000))*1000); // microseconds
michael@0 3691 return 0;
michael@0 3692 }
michael@0 3693 function _abort() {
michael@0 3694 Module['abort']();
michael@0 3695 }
michael@0 3696 function ___errno_location() {
michael@0 3697 return ___errno_state;
michael@0 3698 }var ___errno=___errno_location;
michael@0 3699 function _sbrk(bytes) {
michael@0 3700 // Implement a Linux-like 'memory area' for our 'process'.
michael@0 3701 // Changes the size of the memory area by |bytes|; returns the
michael@0 3702 // address of the previous top ('break') of the memory area
michael@0 3703 // We control the "dynamic" memory - DYNAMIC_BASE to DYNAMICTOP
michael@0 3704 var self = _sbrk;
michael@0 3705 if (!self.called) {
michael@0 3706 DYNAMICTOP = alignMemoryPage(DYNAMICTOP); // make sure we start out aligned
michael@0 3707 self.called = true;
michael@0 3708 assert(Runtime.dynamicAlloc);
michael@0 3709 self.alloc = Runtime.dynamicAlloc;
michael@0 3710 Runtime.dynamicAlloc = function() { abort('cannot dynamically allocate, sbrk now has control') };
michael@0 3711 }
michael@0 3712 var ret = DYNAMICTOP;
michael@0 3713 if (bytes != 0) self.alloc(bytes);
michael@0 3714 return ret; // Previous break location.
michael@0 3715 }
michael@0 3716 function _sysconf(name) {
michael@0 3717 // long sysconf(int name);
michael@0 3718 // http://pubs.opengroup.org/onlinepubs/009695399/functions/sysconf.html
michael@0 3719 switch(name) {
michael@0 3720 case 8: return PAGE_SIZE;
michael@0 3721 case 54:
michael@0 3722 case 56:
michael@0 3723 case 21:
michael@0 3724 case 61:
michael@0 3725 case 63:
michael@0 3726 case 22:
michael@0 3727 case 67:
michael@0 3728 case 23:
michael@0 3729 case 24:
michael@0 3730 case 25:
michael@0 3731 case 26:
michael@0 3732 case 27:
michael@0 3733 case 69:
michael@0 3734 case 28:
michael@0 3735 case 101:
michael@0 3736 case 70:
michael@0 3737 case 71:
michael@0 3738 case 29:
michael@0 3739 case 30:
michael@0 3740 case 199:
michael@0 3741 case 75:
michael@0 3742 case 76:
michael@0 3743 case 32:
michael@0 3744 case 43:
michael@0 3745 case 44:
michael@0 3746 case 80:
michael@0 3747 case 46:
michael@0 3748 case 47:
michael@0 3749 case 45:
michael@0 3750 case 48:
michael@0 3751 case 49:
michael@0 3752 case 42:
michael@0 3753 case 82:
michael@0 3754 case 33:
michael@0 3755 case 7:
michael@0 3756 case 108:
michael@0 3757 case 109:
michael@0 3758 case 107:
michael@0 3759 case 112:
michael@0 3760 case 119:
michael@0 3761 case 121:
michael@0 3762 return 200809;
michael@0 3763 case 13:
michael@0 3764 case 104:
michael@0 3765 case 94:
michael@0 3766 case 95:
michael@0 3767 case 34:
michael@0 3768 case 35:
michael@0 3769 case 77:
michael@0 3770 case 81:
michael@0 3771 case 83:
michael@0 3772 case 84:
michael@0 3773 case 85:
michael@0 3774 case 86:
michael@0 3775 case 87:
michael@0 3776 case 88:
michael@0 3777 case 89:
michael@0 3778 case 90:
michael@0 3779 case 91:
michael@0 3780 case 94:
michael@0 3781 case 95:
michael@0 3782 case 110:
michael@0 3783 case 111:
michael@0 3784 case 113:
michael@0 3785 case 114:
michael@0 3786 case 115:
michael@0 3787 case 116:
michael@0 3788 case 117:
michael@0 3789 case 118:
michael@0 3790 case 120:
michael@0 3791 case 40:
michael@0 3792 case 16:
michael@0 3793 case 79:
michael@0 3794 case 19:
michael@0 3795 return -1;
michael@0 3796 case 92:
michael@0 3797 case 93:
michael@0 3798 case 5:
michael@0 3799 case 72:
michael@0 3800 case 6:
michael@0 3801 case 74:
michael@0 3802 case 92:
michael@0 3803 case 93:
michael@0 3804 case 96:
michael@0 3805 case 97:
michael@0 3806 case 98:
michael@0 3807 case 99:
michael@0 3808 case 102:
michael@0 3809 case 103:
michael@0 3810 case 105:
michael@0 3811 return 1;
michael@0 3812 case 38:
michael@0 3813 case 66:
michael@0 3814 case 50:
michael@0 3815 case 51:
michael@0 3816 case 4:
michael@0 3817 return 1024;
michael@0 3818 case 15:
michael@0 3819 case 64:
michael@0 3820 case 41:
michael@0 3821 return 32;
michael@0 3822 case 55:
michael@0 3823 case 37:
michael@0 3824 case 17:
michael@0 3825 return 2147483647;
michael@0 3826 case 18:
michael@0 3827 case 1:
michael@0 3828 return 47839;
michael@0 3829 case 59:
michael@0 3830 case 57:
michael@0 3831 return 99;
michael@0 3832 case 68:
michael@0 3833 case 58:
michael@0 3834 return 2048;
michael@0 3835 case 0: return 2097152;
michael@0 3836 case 3: return 65536;
michael@0 3837 case 14: return 32768;
michael@0 3838 case 73: return 32767;
michael@0 3839 case 39: return 16384;
michael@0 3840 case 60: return 1000;
michael@0 3841 case 106: return 700;
michael@0 3842 case 52: return 256;
michael@0 3843 case 62: return 255;
michael@0 3844 case 2: return 100;
michael@0 3845 case 65: return 64;
michael@0 3846 case 36: return 20;
michael@0 3847 case 100: return 16;
michael@0 3848 case 20: return 6;
michael@0 3849 case 53: return 4;
michael@0 3850 case 10: return 1;
michael@0 3851 }
michael@0 3852 ___setErrNo(ERRNO_CODES.EINVAL);
michael@0 3853 return -1;
michael@0 3854 }
michael@0 3855 function _time(ptr) {
michael@0 3856 var ret = Math.floor(Date.now()/1000);
michael@0 3857 if (ptr) {
michael@0 3858 HEAP32[((ptr)>>2)]=ret
michael@0 3859 }
michael@0 3860 return ret;
michael@0 3861 }
michael@0 3862 function ___cxa_allocate_exception(size) {
michael@0 3863 return _malloc(size);
michael@0 3864 }
michael@0 3865 function _llvm_eh_exception() {
michael@0 3866 return HEAP32[((_llvm_eh_exception.buf)>>2)];
michael@0 3867 }
michael@0 3868 function __ZSt18uncaught_exceptionv() { // std::uncaught_exception()
michael@0 3869 return !!__ZSt18uncaught_exceptionv.uncaught_exception;
michael@0 3870 }
michael@0 3871 function ___cxa_is_number_type(type) {
michael@0 3872 var isNumber = false;
michael@0 3873 try { if (type == __ZTIi) isNumber = true } catch(e){}
michael@0 3874 try { if (type == __ZTIj) isNumber = true } catch(e){}
michael@0 3875 try { if (type == __ZTIl) isNumber = true } catch(e){}
michael@0 3876 try { if (type == __ZTIm) isNumber = true } catch(e){}
michael@0 3877 try { if (type == __ZTIx) isNumber = true } catch(e){}
michael@0 3878 try { if (type == __ZTIy) isNumber = true } catch(e){}
michael@0 3879 try { if (type == __ZTIf) isNumber = true } catch(e){}
michael@0 3880 try { if (type == __ZTId) isNumber = true } catch(e){}
michael@0 3881 try { if (type == __ZTIe) isNumber = true } catch(e){}
michael@0 3882 try { if (type == __ZTIc) isNumber = true } catch(e){}
michael@0 3883 try { if (type == __ZTIa) isNumber = true } catch(e){}
michael@0 3884 try { if (type == __ZTIh) isNumber = true } catch(e){}
michael@0 3885 try { if (type == __ZTIs) isNumber = true } catch(e){}
michael@0 3886 try { if (type == __ZTIt) isNumber = true } catch(e){}
michael@0 3887 return isNumber;
michael@0 3888 }function ___cxa_does_inherit(definiteType, possibilityType, possibility) {
michael@0 3889 if (possibility == 0) return false;
michael@0 3890 if (possibilityType == 0 || possibilityType == definiteType)
michael@0 3891 return true;
michael@0 3892 var possibility_type_info;
michael@0 3893 if (___cxa_is_number_type(possibilityType)) {
michael@0 3894 possibility_type_info = possibilityType;
michael@0 3895 } else {
michael@0 3896 var possibility_type_infoAddr = HEAP32[((possibilityType)>>2)] - 8;
michael@0 3897 possibility_type_info = HEAP32[((possibility_type_infoAddr)>>2)];
michael@0 3898 }
michael@0 3899 switch (possibility_type_info) {
michael@0 3900 case 0: // possibility is a pointer
michael@0 3901 // See if definite type is a pointer
michael@0 3902 var definite_type_infoAddr = HEAP32[((definiteType)>>2)] - 8;
michael@0 3903 var definite_type_info = HEAP32[((definite_type_infoAddr)>>2)];
michael@0 3904 if (definite_type_info == 0) {
michael@0 3905 // Also a pointer; compare base types of pointers
michael@0 3906 var defPointerBaseAddr = definiteType+8;
michael@0 3907 var defPointerBaseType = HEAP32[((defPointerBaseAddr)>>2)];
michael@0 3908 var possPointerBaseAddr = possibilityType+8;
michael@0 3909 var possPointerBaseType = HEAP32[((possPointerBaseAddr)>>2)];
michael@0 3910 return ___cxa_does_inherit(defPointerBaseType, possPointerBaseType, possibility);
michael@0 3911 } else
michael@0 3912 return false; // one pointer and one non-pointer
michael@0 3913 case 1: // class with no base class
michael@0 3914 return false;
michael@0 3915 case 2: // class with base class
michael@0 3916 var parentTypeAddr = possibilityType + 8;
michael@0 3917 var parentType = HEAP32[((parentTypeAddr)>>2)];
michael@0 3918 return ___cxa_does_inherit(definiteType, parentType, possibility);
michael@0 3919 default:
michael@0 3920 return false; // some unencountered type
michael@0 3921 }
michael@0 3922 }
michael@0 3923 function ___resumeException(ptr) {
michael@0 3924 if (HEAP32[((_llvm_eh_exception.buf)>>2)] == 0) HEAP32[((_llvm_eh_exception.buf)>>2)]=ptr;
michael@0 3925 throw ptr + " - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch.";;
michael@0 3926 }function ___cxa_find_matching_catch(thrown, throwntype) {
michael@0 3927 if (thrown == -1) thrown = HEAP32[((_llvm_eh_exception.buf)>>2)];
michael@0 3928 if (throwntype == -1) throwntype = HEAP32[(((_llvm_eh_exception.buf)+(4))>>2)];
michael@0 3929 var typeArray = Array.prototype.slice.call(arguments, 2);
michael@0 3930 // If throwntype is a pointer, this means a pointer has been
michael@0 3931 // thrown. When a pointer is thrown, actually what's thrown
michael@0 3932 // is a pointer to the pointer. We'll dereference it.
michael@0 3933 if (throwntype != 0 && !___cxa_is_number_type(throwntype)) {
michael@0 3934 var throwntypeInfoAddr= HEAP32[((throwntype)>>2)] - 8;
michael@0 3935 var throwntypeInfo= HEAP32[((throwntypeInfoAddr)>>2)];
michael@0 3936 if (throwntypeInfo == 0)
michael@0 3937 thrown = HEAP32[((thrown)>>2)];
michael@0 3938 }
michael@0 3939 // The different catch blocks are denoted by different types.
michael@0 3940 // Due to inheritance, those types may not precisely match the
michael@0 3941 // type of the thrown object. Find one which matches, and
michael@0 3942 // return the type of the catch block which should be called.
michael@0 3943 for (var i = 0; i < typeArray.length; i++) {
michael@0 3944 if (___cxa_does_inherit(typeArray[i], throwntype, thrown))
michael@0 3945 return ((asm["setTempRet0"](typeArray[i]),thrown)|0);
michael@0 3946 }
michael@0 3947 // Shouldn't happen unless we have bogus data in typeArray
michael@0 3948 // or encounter a type for which emscripten doesn't have suitable
michael@0 3949 // typeinfo defined. Best-efforts match just in case.
michael@0 3950 return ((asm["setTempRet0"](throwntype),thrown)|0);
michael@0 3951 }function ___cxa_throw(ptr, type, destructor) {
michael@0 3952 if (!___cxa_throw.initialized) {
michael@0 3953 try {
michael@0 3954 HEAP32[((__ZTVN10__cxxabiv119__pointer_type_infoE)>>2)]=0; // Workaround for libcxxabi integration bug
michael@0 3955 } catch(e){}
michael@0 3956 try {
michael@0 3957 HEAP32[((__ZTVN10__cxxabiv117__class_type_infoE)>>2)]=1; // Workaround for libcxxabi integration bug
michael@0 3958 } catch(e){}
michael@0 3959 try {
michael@0 3960 HEAP32[((__ZTVN10__cxxabiv120__si_class_type_infoE)>>2)]=2; // Workaround for libcxxabi integration bug
michael@0 3961 } catch(e){}
michael@0 3962 ___cxa_throw.initialized = true;
michael@0 3963 }
michael@0 3964 HEAP32[((_llvm_eh_exception.buf)>>2)]=ptr
michael@0 3965 HEAP32[(((_llvm_eh_exception.buf)+(4))>>2)]=type
michael@0 3966 HEAP32[(((_llvm_eh_exception.buf)+(8))>>2)]=destructor
michael@0 3967 if (!("uncaught_exception" in __ZSt18uncaught_exceptionv)) {
michael@0 3968 __ZSt18uncaught_exceptionv.uncaught_exception = 1;
michael@0 3969 } else {
michael@0 3970 __ZSt18uncaught_exceptionv.uncaught_exception++;
michael@0 3971 }
michael@0 3972 throw ptr + " - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch.";;
michael@0 3973 }
michael@0 3974 function ___cxa_call_unexpected(exception) {
michael@0 3975 Module.printErr('Unexpected exception thrown, this is not properly supported - aborting');
michael@0 3976 ABORT = true;
michael@0 3977 throw exception;
michael@0 3978 }
michael@0 3979 var Browser={mainLoop:{scheduler:null,shouldPause:false,paused:false,queue:[],pause:function () {
michael@0 3980 Browser.mainLoop.shouldPause = true;
michael@0 3981 },resume:function () {
michael@0 3982 if (Browser.mainLoop.paused) {
michael@0 3983 Browser.mainLoop.paused = false;
michael@0 3984 Browser.mainLoop.scheduler();
michael@0 3985 }
michael@0 3986 Browser.mainLoop.shouldPause = false;
michael@0 3987 },updateStatus:function () {
michael@0 3988 if (Module['setStatus']) {
michael@0 3989 var message = Module['statusMessage'] || 'Please wait...';
michael@0 3990 var remaining = Browser.mainLoop.remainingBlockers;
michael@0 3991 var expected = Browser.mainLoop.expectedBlockers;
michael@0 3992 if (remaining) {
michael@0 3993 if (remaining < expected) {
michael@0 3994 Module['setStatus'](message + ' (' + (expected - remaining) + '/' + expected + ')');
michael@0 3995 } else {
michael@0 3996 Module['setStatus'](message);
michael@0 3997 }
michael@0 3998 } else {
michael@0 3999 Module['setStatus']('');
michael@0 4000 }
michael@0 4001 }
michael@0 4002 }},isFullScreen:false,pointerLock:false,moduleContextCreatedCallbacks:[],workers:[],init:function () {
michael@0 4003 if (!Module["preloadPlugins"]) Module["preloadPlugins"] = []; // needs to exist even in workers
michael@0 4004 if (Browser.initted || ENVIRONMENT_IS_WORKER) return;
michael@0 4005 Browser.initted = true;
michael@0 4006 try {
michael@0 4007 new Blob();
michael@0 4008 Browser.hasBlobConstructor = true;
michael@0 4009 } catch(e) {
michael@0 4010 Browser.hasBlobConstructor = false;
michael@0 4011 console.log("warning: no blob constructor, cannot create blobs with mimetypes");
michael@0 4012 }
michael@0 4013 Browser.BlobBuilder = typeof MozBlobBuilder != "undefined" ? MozBlobBuilder : (typeof WebKitBlobBuilder != "undefined" ? WebKitBlobBuilder : (!Browser.hasBlobConstructor ? console.log("warning: no BlobBuilder") : null));
michael@0 4014 Browser.URLObject = typeof window != "undefined" ? (window.URL ? window.URL : window.webkitURL) : undefined;
michael@0 4015 if (!Module.noImageDecoding && typeof Browser.URLObject === 'undefined') {
michael@0 4016 console.log("warning: Browser does not support creating object URLs. Built-in browser image decoding will not be available.");
michael@0 4017 Module.noImageDecoding = true;
michael@0 4018 }
michael@0 4019 // Support for plugins that can process preloaded files. You can add more of these to
michael@0 4020 // your app by creating and appending to Module.preloadPlugins.
michael@0 4021 //
michael@0 4022 // Each plugin is asked if it can handle a file based on the file's name. If it can,
michael@0 4023 // it is given the file's raw data. When it is done, it calls a callback with the file's
michael@0 4024 // (possibly modified) data. For example, a plugin might decompress a file, or it
michael@0 4025 // might create some side data structure for use later (like an Image element, etc.).
michael@0 4026 var imagePlugin = {};
michael@0 4027 imagePlugin['canHandle'] = function(name) {
michael@0 4028 return !Module.noImageDecoding && /\.(jpg|jpeg|png|bmp)$/i.test(name);
michael@0 4029 };
michael@0 4030 imagePlugin['handle'] = function(byteArray, name, onload, onerror) {
michael@0 4031 var b = null;
michael@0 4032 if (Browser.hasBlobConstructor) {
michael@0 4033 try {
michael@0 4034 b = new Blob([byteArray], { type: Browser.getMimetype(name) });
michael@0 4035 if (b.size !== byteArray.length) { // Safari bug #118630
michael@0 4036 // Safari's Blob can only take an ArrayBuffer
michael@0 4037 b = new Blob([(new Uint8Array(byteArray)).buffer], { type: Browser.getMimetype(name) });
michael@0 4038 }
michael@0 4039 } catch(e) {
michael@0 4040 Runtime.warnOnce('Blob constructor present but fails: ' + e + '; falling back to blob builder');
michael@0 4041 }
michael@0 4042 }
michael@0 4043 if (!b) {
michael@0 4044 var bb = new Browser.BlobBuilder();
michael@0 4045 bb.append((new Uint8Array(byteArray)).buffer); // we need to pass a buffer, and must copy the array to get the right data range
michael@0 4046 b = bb.getBlob();
michael@0 4047 }
michael@0 4048 var url = Browser.URLObject.createObjectURL(b);
michael@0 4049 var img = new Image();
michael@0 4050 img.onload = function() {
michael@0 4051 assert(img.complete, 'Image ' + name + ' could not be decoded');
michael@0 4052 var canvas = document.createElement('canvas');
michael@0 4053 canvas.width = img.width;
michael@0 4054 canvas.height = img.height;
michael@0 4055 var ctx = canvas.getContext('2d');
michael@0 4056 ctx.drawImage(img, 0, 0);
michael@0 4057 Module["preloadedImages"][name] = canvas;
michael@0 4058 Browser.URLObject.revokeObjectURL(url);
michael@0 4059 if (onload) onload(byteArray);
michael@0 4060 };
michael@0 4061 img.onerror = function(event) {
michael@0 4062 console.log('Image ' + url + ' could not be decoded');
michael@0 4063 if (onerror) onerror();
michael@0 4064 };
michael@0 4065 img.src = url;
michael@0 4066 };
michael@0 4067 Module['preloadPlugins'].push(imagePlugin);
michael@0 4068 var audioPlugin = {};
michael@0 4069 audioPlugin['canHandle'] = function(name) {
michael@0 4070 return !Module.noAudioDecoding && name.substr(-4) in { '.ogg': 1, '.wav': 1, '.mp3': 1 };
michael@0 4071 };
michael@0 4072 audioPlugin['handle'] = function(byteArray, name, onload, onerror) {
michael@0 4073 var done = false;
michael@0 4074 function finish(audio) {
michael@0 4075 if (done) return;
michael@0 4076 done = true;
michael@0 4077 Module["preloadedAudios"][name] = audio;
michael@0 4078 if (onload) onload(byteArray);
michael@0 4079 }
michael@0 4080 function fail() {
michael@0 4081 if (done) return;
michael@0 4082 done = true;
michael@0 4083 Module["preloadedAudios"][name] = new Audio(); // empty shim
michael@0 4084 if (onerror) onerror();
michael@0 4085 }
michael@0 4086 if (Browser.hasBlobConstructor) {
michael@0 4087 try {
michael@0 4088 var b = new Blob([byteArray], { type: Browser.getMimetype(name) });
michael@0 4089 } catch(e) {
michael@0 4090 return fail();
michael@0 4091 }
michael@0 4092 var url = Browser.URLObject.createObjectURL(b); // XXX we never revoke this!
michael@0 4093 var audio = new Audio();
michael@0 4094 audio.addEventListener('canplaythrough', function() { finish(audio) }, false); // use addEventListener due to chromium bug 124926
michael@0 4095 audio.onerror = function(event) {
michael@0 4096 if (done) return;
michael@0 4097 console.log('warning: browser could not fully decode audio ' + name + ', trying slower base64 approach');
michael@0 4098 function encode64(data) {
michael@0 4099 var BASE = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
michael@0 4100 var PAD = '=';
michael@0 4101 var ret = '';
michael@0 4102 var leftchar = 0;
michael@0 4103 var leftbits = 0;
michael@0 4104 for (var i = 0; i < data.length; i++) {
michael@0 4105 leftchar = (leftchar << 8) | data[i];
michael@0 4106 leftbits += 8;
michael@0 4107 while (leftbits >= 6) {
michael@0 4108 var curr = (leftchar >> (leftbits-6)) & 0x3f;
michael@0 4109 leftbits -= 6;
michael@0 4110 ret += BASE[curr];
michael@0 4111 }
michael@0 4112 }
michael@0 4113 if (leftbits == 2) {
michael@0 4114 ret += BASE[(leftchar&3) << 4];
michael@0 4115 ret += PAD + PAD;
michael@0 4116 } else if (leftbits == 4) {
michael@0 4117 ret += BASE[(leftchar&0xf) << 2];
michael@0 4118 ret += PAD;
michael@0 4119 }
michael@0 4120 return ret;
michael@0 4121 }
michael@0 4122 audio.src = 'data:audio/x-' + name.substr(-3) + ';base64,' + encode64(byteArray);
michael@0 4123 finish(audio); // we don't wait for confirmation this worked - but it's worth trying
michael@0 4124 };
michael@0 4125 audio.src = url;
michael@0 4126 // workaround for chrome bug 124926 - we do not always get oncanplaythrough or onerror
michael@0 4127 Browser.safeSetTimeout(function() {
michael@0 4128 finish(audio); // try to use it even though it is not necessarily ready to play
michael@0 4129 }, 10000);
michael@0 4130 } else {
michael@0 4131 return fail();
michael@0 4132 }
michael@0 4133 };
michael@0 4134 Module['preloadPlugins'].push(audioPlugin);
michael@0 4135 // Canvas event setup
michael@0 4136 var canvas = Module['canvas'];
michael@0 4137 canvas.requestPointerLock = canvas['requestPointerLock'] ||
michael@0 4138 canvas['mozRequestPointerLock'] ||
michael@0 4139 canvas['webkitRequestPointerLock'];
michael@0 4140 canvas.exitPointerLock = document['exitPointerLock'] ||
michael@0 4141 document['mozExitPointerLock'] ||
michael@0 4142 document['webkitExitPointerLock'] ||
michael@0 4143 function(){}; // no-op if function does not exist
michael@0 4144 canvas.exitPointerLock = canvas.exitPointerLock.bind(document);
michael@0 4145 function pointerLockChange() {
michael@0 4146 Browser.pointerLock = document['pointerLockElement'] === canvas ||
michael@0 4147 document['mozPointerLockElement'] === canvas ||
michael@0 4148 document['webkitPointerLockElement'] === canvas;
michael@0 4149 }
michael@0 4150 document.addEventListener('pointerlockchange', pointerLockChange, false);
michael@0 4151 document.addEventListener('mozpointerlockchange', pointerLockChange, false);
michael@0 4152 document.addEventListener('webkitpointerlockchange', pointerLockChange, false);
michael@0 4153 if (Module['elementPointerLock']) {
michael@0 4154 canvas.addEventListener("click", function(ev) {
michael@0 4155 if (!Browser.pointerLock && canvas.requestPointerLock) {
michael@0 4156 canvas.requestPointerLock();
michael@0 4157 ev.preventDefault();
michael@0 4158 }
michael@0 4159 }, false);
michael@0 4160 }
michael@0 4161 },createContext:function (canvas, useWebGL, setInModule) {
michael@0 4162 var ctx;
michael@0 4163 try {
michael@0 4164 if (useWebGL) {
michael@0 4165 ctx = canvas.getContext('experimental-webgl', {
michael@0 4166 alpha: false
michael@0 4167 });
michael@0 4168 } else {
michael@0 4169 ctx = canvas.getContext('2d');
michael@0 4170 }
michael@0 4171 if (!ctx) throw ':(';
michael@0 4172 } catch (e) {
michael@0 4173 Module.print('Could not create canvas - ' + e);
michael@0 4174 return null;
michael@0 4175 }
michael@0 4176 if (useWebGL) {
michael@0 4177 // Set the background of the WebGL canvas to black
michael@0 4178 canvas.style.backgroundColor = "black";
michael@0 4179 // Warn on context loss
michael@0 4180 canvas.addEventListener('webglcontextlost', function(event) {
michael@0 4181 alert('WebGL context lost. You will need to reload the page.');
michael@0 4182 }, false);
michael@0 4183 }
michael@0 4184 if (setInModule) {
michael@0 4185 Module.ctx = ctx;
michael@0 4186 Module.useWebGL = useWebGL;
michael@0 4187 Browser.moduleContextCreatedCallbacks.forEach(function(callback) { callback() });
michael@0 4188 Browser.init();
michael@0 4189 }
michael@0 4190 return ctx;
michael@0 4191 },destroyContext:function (canvas, useWebGL, setInModule) {},fullScreenHandlersInstalled:false,lockPointer:undefined,resizeCanvas:undefined,requestFullScreen:function (lockPointer, resizeCanvas) {
michael@0 4192 Browser.lockPointer = lockPointer;
michael@0 4193 Browser.resizeCanvas = resizeCanvas;
michael@0 4194 if (typeof Browser.lockPointer === 'undefined') Browser.lockPointer = true;
michael@0 4195 if (typeof Browser.resizeCanvas === 'undefined') Browser.resizeCanvas = false;
michael@0 4196 var canvas = Module['canvas'];
michael@0 4197 function fullScreenChange() {
michael@0 4198 Browser.isFullScreen = false;
michael@0 4199 if ((document['webkitFullScreenElement'] || document['webkitFullscreenElement'] ||
michael@0 4200 document['mozFullScreenElement'] || document['mozFullscreenElement'] ||
michael@0 4201 document['fullScreenElement'] || document['fullscreenElement']) === canvas) {
michael@0 4202 canvas.cancelFullScreen = document['cancelFullScreen'] ||
michael@0 4203 document['mozCancelFullScreen'] ||
michael@0 4204 document['webkitCancelFullScreen'];
michael@0 4205 canvas.cancelFullScreen = canvas.cancelFullScreen.bind(document);
michael@0 4206 if (Browser.lockPointer) canvas.requestPointerLock();
michael@0 4207 Browser.isFullScreen = true;
michael@0 4208 if (Browser.resizeCanvas) Browser.setFullScreenCanvasSize();
michael@0 4209 } else if (Browser.resizeCanvas){
michael@0 4210 Browser.setWindowedCanvasSize();
michael@0 4211 }
michael@0 4212 if (Module['onFullScreen']) Module['onFullScreen'](Browser.isFullScreen);
michael@0 4213 }
michael@0 4214 if (!Browser.fullScreenHandlersInstalled) {
michael@0 4215 Browser.fullScreenHandlersInstalled = true;
michael@0 4216 document.addEventListener('fullscreenchange', fullScreenChange, false);
michael@0 4217 document.addEventListener('mozfullscreenchange', fullScreenChange, false);
michael@0 4218 document.addEventListener('webkitfullscreenchange', fullScreenChange, false);
michael@0 4219 }
michael@0 4220 canvas.requestFullScreen = canvas['requestFullScreen'] ||
michael@0 4221 canvas['mozRequestFullScreen'] ||
michael@0 4222 (canvas['webkitRequestFullScreen'] ? function() { canvas['webkitRequestFullScreen'](Element['ALLOW_KEYBOARD_INPUT']) } : null);
michael@0 4223 canvas.requestFullScreen();
michael@0 4224 },requestAnimationFrame:function (func) {
michael@0 4225 if (!window.requestAnimationFrame) {
michael@0 4226 window.requestAnimationFrame = window['requestAnimationFrame'] ||
michael@0 4227 window['mozRequestAnimationFrame'] ||
michael@0 4228 window['webkitRequestAnimationFrame'] ||
michael@0 4229 window['msRequestAnimationFrame'] ||
michael@0 4230 window['oRequestAnimationFrame'] ||
michael@0 4231 window['setTimeout'];
michael@0 4232 }
michael@0 4233 window.requestAnimationFrame(func);
michael@0 4234 },safeCallback:function (func) {
michael@0 4235 return function() {
michael@0 4236 if (!ABORT) return func.apply(null, arguments);
michael@0 4237 };
michael@0 4238 },safeRequestAnimationFrame:function (func) {
michael@0 4239 return Browser.requestAnimationFrame(function() {
michael@0 4240 if (!ABORT) func();
michael@0 4241 });
michael@0 4242 },safeSetTimeout:function (func, timeout) {
michael@0 4243 return setTimeout(function() {
michael@0 4244 if (!ABORT) func();
michael@0 4245 }, timeout);
michael@0 4246 },safeSetInterval:function (func, timeout) {
michael@0 4247 return setInterval(function() {
michael@0 4248 if (!ABORT) func();
michael@0 4249 }, timeout);
michael@0 4250 },getMimetype:function (name) {
michael@0 4251 return {
michael@0 4252 'jpg': 'image/jpeg',
michael@0 4253 'jpeg': 'image/jpeg',
michael@0 4254 'png': 'image/png',
michael@0 4255 'bmp': 'image/bmp',
michael@0 4256 'ogg': 'audio/ogg',
michael@0 4257 'wav': 'audio/wav',
michael@0 4258 'mp3': 'audio/mpeg'
michael@0 4259 }[name.substr(name.lastIndexOf('.')+1)];
michael@0 4260 },getUserMedia:function (func) {
michael@0 4261 if(!window.getUserMedia) {
michael@0 4262 window.getUserMedia = navigator['getUserMedia'] ||
michael@0 4263 navigator['mozGetUserMedia'];
michael@0 4264 }
michael@0 4265 window.getUserMedia(func);
michael@0 4266 },getMovementX:function (event) {
michael@0 4267 return event['movementX'] ||
michael@0 4268 event['mozMovementX'] ||
michael@0 4269 event['webkitMovementX'] ||
michael@0 4270 0;
michael@0 4271 },getMovementY:function (event) {
michael@0 4272 return event['movementY'] ||
michael@0 4273 event['mozMovementY'] ||
michael@0 4274 event['webkitMovementY'] ||
michael@0 4275 0;
michael@0 4276 },mouseX:0,mouseY:0,mouseMovementX:0,mouseMovementY:0,calculateMouseEvent:function (event) { // event should be mousemove, mousedown or mouseup
michael@0 4277 if (Browser.pointerLock) {
michael@0 4278 // When the pointer is locked, calculate the coordinates
michael@0 4279 // based on the movement of the mouse.
michael@0 4280 // Workaround for Firefox bug 764498
michael@0 4281 if (event.type != 'mousemove' &&
michael@0 4282 ('mozMovementX' in event)) {
michael@0 4283 Browser.mouseMovementX = Browser.mouseMovementY = 0;
michael@0 4284 } else {
michael@0 4285 Browser.mouseMovementX = Browser.getMovementX(event);
michael@0 4286 Browser.mouseMovementY = Browser.getMovementY(event);
michael@0 4287 }
michael@0 4288 // check if SDL is available
michael@0 4289 if (typeof SDL != "undefined") {
michael@0 4290 Browser.mouseX = SDL.mouseX + Browser.mouseMovementX;
michael@0 4291 Browser.mouseY = SDL.mouseY + Browser.mouseMovementY;
michael@0 4292 } else {
michael@0 4293 // just add the mouse delta to the current absolut mouse position
michael@0 4294 // FIXME: ideally this should be clamped against the canvas size and zero
michael@0 4295 Browser.mouseX += Browser.mouseMovementX;
michael@0 4296 Browser.mouseY += Browser.mouseMovementY;
michael@0 4297 }
michael@0 4298 } else {
michael@0 4299 // Otherwise, calculate the movement based on the changes
michael@0 4300 // in the coordinates.
michael@0 4301 var rect = Module["canvas"].getBoundingClientRect();
michael@0 4302 var x, y;
michael@0 4303 if (event.type == 'touchstart' ||
michael@0 4304 event.type == 'touchend' ||
michael@0 4305 event.type == 'touchmove') {
michael@0 4306 var t = event.touches.item(0);
michael@0 4307 if (t) {
michael@0 4308 x = t.pageX - (window.scrollX + rect.left);
michael@0 4309 y = t.pageY - (window.scrollY + rect.top);
michael@0 4310 } else {
michael@0 4311 return;
michael@0 4312 }
michael@0 4313 } else {
michael@0 4314 x = event.pageX - (window.scrollX + rect.left);
michael@0 4315 y = event.pageY - (window.scrollY + rect.top);
michael@0 4316 }
michael@0 4317 // the canvas might be CSS-scaled compared to its backbuffer;
michael@0 4318 // SDL-using content will want mouse coordinates in terms
michael@0 4319 // of backbuffer units.
michael@0 4320 var cw = Module["canvas"].width;
michael@0 4321 var ch = Module["canvas"].height;
michael@0 4322 x = x * (cw / rect.width);
michael@0 4323 y = y * (ch / rect.height);
michael@0 4324 Browser.mouseMovementX = x - Browser.mouseX;
michael@0 4325 Browser.mouseMovementY = y - Browser.mouseY;
michael@0 4326 Browser.mouseX = x;
michael@0 4327 Browser.mouseY = y;
michael@0 4328 }
michael@0 4329 },xhrLoad:function (url, onload, onerror) {
michael@0 4330 var xhr = new XMLHttpRequest();
michael@0 4331 xhr.open('GET', url, true);
michael@0 4332 xhr.responseType = 'arraybuffer';
michael@0 4333 xhr.onload = function() {
michael@0 4334 if (xhr.status == 200 || (xhr.status == 0 && xhr.response)) { // file URLs can return 0
michael@0 4335 onload(xhr.response);
michael@0 4336 } else {
michael@0 4337 onerror();
michael@0 4338 }
michael@0 4339 };
michael@0 4340 xhr.onerror = onerror;
michael@0 4341 xhr.send(null);
michael@0 4342 },asyncLoad:function (url, onload, onerror, noRunDep) {
michael@0 4343 Browser.xhrLoad(url, function(arrayBuffer) {
michael@0 4344 assert(arrayBuffer, 'Loading data file "' + url + '" failed (no arrayBuffer).');
michael@0 4345 onload(new Uint8Array(arrayBuffer));
michael@0 4346 if (!noRunDep) removeRunDependency('al ' + url);
michael@0 4347 }, function(event) {
michael@0 4348 if (onerror) {
michael@0 4349 onerror();
michael@0 4350 } else {
michael@0 4351 throw 'Loading data file "' + url + '" failed.';
michael@0 4352 }
michael@0 4353 });
michael@0 4354 if (!noRunDep) addRunDependency('al ' + url);
michael@0 4355 },resizeListeners:[],updateResizeListeners:function () {
michael@0 4356 var canvas = Module['canvas'];
michael@0 4357 Browser.resizeListeners.forEach(function(listener) {
michael@0 4358 listener(canvas.width, canvas.height);
michael@0 4359 });
michael@0 4360 },setCanvasSize:function (width, height, noUpdates) {
michael@0 4361 var canvas = Module['canvas'];
michael@0 4362 canvas.width = width;
michael@0 4363 canvas.height = height;
michael@0 4364 if (!noUpdates) Browser.updateResizeListeners();
michael@0 4365 },windowedWidth:0,windowedHeight:0,setFullScreenCanvasSize:function () {
michael@0 4366 var canvas = Module['canvas'];
michael@0 4367 this.windowedWidth = canvas.width;
michael@0 4368 this.windowedHeight = canvas.height;
michael@0 4369 canvas.width = screen.width;
michael@0 4370 canvas.height = screen.height;
michael@0 4371 // check if SDL is available
michael@0 4372 if (typeof SDL != "undefined") {
michael@0 4373 var flags = HEAPU32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)];
michael@0 4374 flags = flags | 0x00800000; // set SDL_FULLSCREEN flag
michael@0 4375 HEAP32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)]=flags
michael@0 4376 }
michael@0 4377 Browser.updateResizeListeners();
michael@0 4378 },setWindowedCanvasSize:function () {
michael@0 4379 var canvas = Module['canvas'];
michael@0 4380 canvas.width = this.windowedWidth;
michael@0 4381 canvas.height = this.windowedHeight;
michael@0 4382 // check if SDL is available
michael@0 4383 if (typeof SDL != "undefined") {
michael@0 4384 var flags = HEAPU32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)];
michael@0 4385 flags = flags & ~0x00800000; // clear SDL_FULLSCREEN flag
michael@0 4386 HEAP32[((SDL.screen+Runtime.QUANTUM_SIZE*0)>>2)]=flags
michael@0 4387 }
michael@0 4388 Browser.updateResizeListeners();
michael@0 4389 }};
michael@0 4390 FS.staticInit();__ATINIT__.unshift({ func: function() { if (!Module["noFSInit"] && !FS.init.initialized) FS.init() } });__ATMAIN__.push({ func: function() { FS.ignorePermissions = false } });__ATEXIT__.push({ func: 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;
michael@0 4391 ___errno_state = Runtime.staticAlloc(4); HEAP32[((___errno_state)>>2)]=0;
michael@0 4392 __ATINIT__.unshift({ func: function() { TTY.init() } });__ATEXIT__.push({ func: function() { TTY.shutdown() } });TTY.utf8 = new Runtime.UTF8Processor();
michael@0 4393 __ATINIT__.push({ func: function() { SOCKFS.root = FS.mount(SOCKFS, {}, null); } });
michael@0 4394 _llvm_eh_exception.buf = allocate(12, "void*", ALLOC_STATIC);
michael@0 4395 Module["requestFullScreen"] = function(lockPointer, resizeCanvas) { Browser.requestFullScreen(lockPointer, resizeCanvas) };
michael@0 4396 Module["requestAnimationFrame"] = function(func) { Browser.requestAnimationFrame(func) };
michael@0 4397 Module["setCanvasSize"] = function(width, height, noUpdates) { Browser.setCanvasSize(width, height, noUpdates) };
michael@0 4398 Module["pauseMainLoop"] = function() { Browser.mainLoop.pause() };
michael@0 4399 Module["resumeMainLoop"] = function() { Browser.mainLoop.resume() };
michael@0 4400 Module["getUserMedia"] = function() { Browser.getUserMedia() }
michael@0 4401 STACK_BASE = STACKTOP = Runtime.alignMemory(STATICTOP);
michael@0 4402 staticSealed = true; // seal the static portion of memory
michael@0 4403 STACK_MAX = STACK_BASE + 5242880;
michael@0 4404 DYNAMIC_BASE = DYNAMICTOP = Runtime.alignMemory(STACK_MAX);
michael@0 4405 assert(DYNAMIC_BASE < TOTAL_MEMORY); // Stack must fit in TOTAL_MEMORY; allocations from here on may enlarge TOTAL_MEMORY
michael@0 4406 var ctlz_i8 = allocate([8,7,6,6,5,5,5,5,4,4,4,4,4,4,4,4,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,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,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], "i8", ALLOC_DYNAMIC);
michael@0 4407 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_DYNAMIC);
michael@0 4408 var Math_min = Math.min;
michael@0 4409 function invoke_iiiiiiii(index,a1,a2,a3,a4,a5,a6,a7) {
michael@0 4410 try {
michael@0 4411 return Module["dynCall_iiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7);
michael@0 4412 } catch(e) {
michael@0 4413 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4414 asm["setThrew"](1, 0);
michael@0 4415 }
michael@0 4416 }
michael@0 4417 function invoke_vif(index,a1,a2) {
michael@0 4418 try {
michael@0 4419 Module["dynCall_vif"](index,a1,a2);
michael@0 4420 } catch(e) {
michael@0 4421 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4422 asm["setThrew"](1, 0);
michael@0 4423 }
michael@0 4424 }
michael@0 4425 function invoke_viifii(index,a1,a2,a3,a4,a5) {
michael@0 4426 try {
michael@0 4427 Module["dynCall_viifii"](index,a1,a2,a3,a4,a5);
michael@0 4428 } catch(e) {
michael@0 4429 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4430 asm["setThrew"](1, 0);
michael@0 4431 }
michael@0 4432 }
michael@0 4433 function invoke_viiiii(index,a1,a2,a3,a4,a5) {
michael@0 4434 try {
michael@0 4435 Module["dynCall_viiiii"](index,a1,a2,a3,a4,a5);
michael@0 4436 } catch(e) {
michael@0 4437 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4438 asm["setThrew"](1, 0);
michael@0 4439 }
michael@0 4440 }
michael@0 4441 function invoke_vi(index,a1) {
michael@0 4442 try {
michael@0 4443 Module["dynCall_vi"](index,a1);
michael@0 4444 } catch(e) {
michael@0 4445 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4446 asm["setThrew"](1, 0);
michael@0 4447 }
michael@0 4448 }
michael@0 4449 function invoke_vii(index,a1,a2) {
michael@0 4450 try {
michael@0 4451 Module["dynCall_vii"](index,a1,a2);
michael@0 4452 } catch(e) {
michael@0 4453 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4454 asm["setThrew"](1, 0);
michael@0 4455 }
michael@0 4456 }
michael@0 4457 function invoke_viiifii(index,a1,a2,a3,a4,a5,a6) {
michael@0 4458 try {
michael@0 4459 Module["dynCall_viiifii"](index,a1,a2,a3,a4,a5,a6);
michael@0 4460 } catch(e) {
michael@0 4461 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4462 asm["setThrew"](1, 0);
michael@0 4463 }
michael@0 4464 }
michael@0 4465 function invoke_vifiii(index,a1,a2,a3,a4,a5) {
michael@0 4466 try {
michael@0 4467 Module["dynCall_vifiii"](index,a1,a2,a3,a4,a5);
michael@0 4468 } catch(e) {
michael@0 4469 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4470 asm["setThrew"](1, 0);
michael@0 4471 }
michael@0 4472 }
michael@0 4473 function invoke_ii(index,a1) {
michael@0 4474 try {
michael@0 4475 return Module["dynCall_ii"](index,a1);
michael@0 4476 } catch(e) {
michael@0 4477 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4478 asm["setThrew"](1, 0);
michael@0 4479 }
michael@0 4480 }
michael@0 4481 function invoke_viiiiffffiif(index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11) {
michael@0 4482 try {
michael@0 4483 Module["dynCall_viiiiffffiif"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11);
michael@0 4484 } catch(e) {
michael@0 4485 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4486 asm["setThrew"](1, 0);
michael@0 4487 }
michael@0 4488 }
michael@0 4489 function invoke_fiii(index,a1,a2,a3) {
michael@0 4490 try {
michael@0 4491 return Module["dynCall_fiii"](index,a1,a2,a3);
michael@0 4492 } catch(e) {
michael@0 4493 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4494 asm["setThrew"](1, 0);
michael@0 4495 }
michael@0 4496 }
michael@0 4497 function invoke_viiif(index,a1,a2,a3,a4) {
michael@0 4498 try {
michael@0 4499 Module["dynCall_viiif"](index,a1,a2,a3,a4);
michael@0 4500 } catch(e) {
michael@0 4501 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4502 asm["setThrew"](1, 0);
michael@0 4503 }
michael@0 4504 }
michael@0 4505 function invoke_fiiiiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11) {
michael@0 4506 try {
michael@0 4507 return Module["dynCall_fiiiiiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11);
michael@0 4508 } catch(e) {
michael@0 4509 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4510 asm["setThrew"](1, 0);
michael@0 4511 }
michael@0 4512 }
michael@0 4513 function invoke_fiifii(index,a1,a2,a3,a4,a5) {
michael@0 4514 try {
michael@0 4515 return Module["dynCall_fiifii"](index,a1,a2,a3,a4,a5);
michael@0 4516 } catch(e) {
michael@0 4517 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4518 asm["setThrew"](1, 0);
michael@0 4519 }
michael@0 4520 }
michael@0 4521 function invoke_iii(index,a1,a2) {
michael@0 4522 try {
michael@0 4523 return Module["dynCall_iii"](index,a1,a2);
michael@0 4524 } catch(e) {
michael@0 4525 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4526 asm["setThrew"](1, 0);
michael@0 4527 }
michael@0 4528 }
michael@0 4529 function invoke_iiii(index,a1,a2,a3) {
michael@0 4530 try {
michael@0 4531 return Module["dynCall_iiii"](index,a1,a2,a3);
michael@0 4532 } catch(e) {
michael@0 4533 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4534 asm["setThrew"](1, 0);
michael@0 4535 }
michael@0 4536 }
michael@0 4537 function invoke_fif(index,a1,a2) {
michael@0 4538 try {
michael@0 4539 return Module["dynCall_fif"](index,a1,a2);
michael@0 4540 } catch(e) {
michael@0 4541 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4542 asm["setThrew"](1, 0);
michael@0 4543 }
michael@0 4544 }
michael@0 4545 function invoke_viiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8) {
michael@0 4546 try {
michael@0 4547 Module["dynCall_viiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8);
michael@0 4548 } catch(e) {
michael@0 4549 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4550 asm["setThrew"](1, 0);
michael@0 4551 }
michael@0 4552 }
michael@0 4553 function invoke_vifi(index,a1,a2,a3) {
michael@0 4554 try {
michael@0 4555 Module["dynCall_vifi"](index,a1,a2,a3);
michael@0 4556 } catch(e) {
michael@0 4557 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4558 asm["setThrew"](1, 0);
michael@0 4559 }
michael@0 4560 }
michael@0 4561 function invoke_viiiiii(index,a1,a2,a3,a4,a5,a6) {
michael@0 4562 try {
michael@0 4563 Module["dynCall_viiiiii"](index,a1,a2,a3,a4,a5,a6);
michael@0 4564 } catch(e) {
michael@0 4565 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4566 asm["setThrew"](1, 0);
michael@0 4567 }
michael@0 4568 }
michael@0 4569 function invoke_iiiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9) {
michael@0 4570 try {
michael@0 4571 return Module["dynCall_iiiiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9);
michael@0 4572 } catch(e) {
michael@0 4573 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4574 asm["setThrew"](1, 0);
michael@0 4575 }
michael@0 4576 }
michael@0 4577 function invoke_viffiii(index,a1,a2,a3,a4,a5,a6) {
michael@0 4578 try {
michael@0 4579 Module["dynCall_viffiii"](index,a1,a2,a3,a4,a5,a6);
michael@0 4580 } catch(e) {
michael@0 4581 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4582 asm["setThrew"](1, 0);
michael@0 4583 }
michael@0 4584 }
michael@0 4585 function invoke_iiiiiii(index,a1,a2,a3,a4,a5,a6) {
michael@0 4586 try {
michael@0 4587 return Module["dynCall_iiiiiii"](index,a1,a2,a3,a4,a5,a6);
michael@0 4588 } catch(e) {
michael@0 4589 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4590 asm["setThrew"](1, 0);
michael@0 4591 }
michael@0 4592 }
michael@0 4593 function invoke_fiiiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10) {
michael@0 4594 try {
michael@0 4595 return Module["dynCall_fiiiiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10);
michael@0 4596 } catch(e) {
michael@0 4597 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4598 asm["setThrew"](1, 0);
michael@0 4599 }
michael@0 4600 }
michael@0 4601 function invoke_fiiiii(index,a1,a2,a3,a4,a5) {
michael@0 4602 try {
michael@0 4603 return Module["dynCall_fiiiii"](index,a1,a2,a3,a4,a5);
michael@0 4604 } catch(e) {
michael@0 4605 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4606 asm["setThrew"](1, 0);
michael@0 4607 }
michael@0 4608 }
michael@0 4609 function invoke_iiiiiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11) {
michael@0 4610 try {
michael@0 4611 return Module["dynCall_iiiiiiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11);
michael@0 4612 } catch(e) {
michael@0 4613 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4614 asm["setThrew"](1, 0);
michael@0 4615 }
michael@0 4616 }
michael@0 4617 function invoke_vifii(index,a1,a2,a3,a4) {
michael@0 4618 try {
michael@0 4619 Module["dynCall_vifii"](index,a1,a2,a3,a4);
michael@0 4620 } catch(e) {
michael@0 4621 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4622 asm["setThrew"](1, 0);
michael@0 4623 }
michael@0 4624 }
michael@0 4625 function invoke_fi(index,a1) {
michael@0 4626 try {
michael@0 4627 return Module["dynCall_fi"](index,a1);
michael@0 4628 } catch(e) {
michael@0 4629 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4630 asm["setThrew"](1, 0);
michael@0 4631 }
michael@0 4632 }
michael@0 4633 function invoke_viiiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10) {
michael@0 4634 try {
michael@0 4635 Module["dynCall_viiiiiiiiii"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10);
michael@0 4636 } catch(e) {
michael@0 4637 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4638 asm["setThrew"](1, 0);
michael@0 4639 }
michael@0 4640 }
michael@0 4641 function invoke_viiiifffffif(index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11) {
michael@0 4642 try {
michael@0 4643 Module["dynCall_viiiifffffif"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11);
michael@0 4644 } catch(e) {
michael@0 4645 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4646 asm["setThrew"](1, 0);
michael@0 4647 }
michael@0 4648 }
michael@0 4649 function invoke_viiiiiffii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9) {
michael@0 4650 try {
michael@0 4651 Module["dynCall_viiiiiffii"](index,a1,a2,a3,a4,a5,a6,a7,a8,a9);
michael@0 4652 } catch(e) {
michael@0 4653 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4654 asm["setThrew"](1, 0);
michael@0 4655 }
michael@0 4656 }
michael@0 4657 function invoke_iifif(index,a1,a2,a3,a4) {
michael@0 4658 try {
michael@0 4659 return Module["dynCall_iifif"](index,a1,a2,a3,a4);
michael@0 4660 } catch(e) {
michael@0 4661 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4662 asm["setThrew"](1, 0);
michael@0 4663 }
michael@0 4664 }
michael@0 4665 function invoke_iiiii(index,a1,a2,a3,a4) {
michael@0 4666 try {
michael@0 4667 return Module["dynCall_iiiii"](index,a1,a2,a3,a4);
michael@0 4668 } catch(e) {
michael@0 4669 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4670 asm["setThrew"](1, 0);
michael@0 4671 }
michael@0 4672 }
michael@0 4673 function invoke_viii(index,a1,a2,a3) {
michael@0 4674 try {
michael@0 4675 Module["dynCall_viii"](index,a1,a2,a3);
michael@0 4676 } catch(e) {
michael@0 4677 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4678 asm["setThrew"](1, 0);
michael@0 4679 }
michael@0 4680 }
michael@0 4681 function invoke_viifi(index,a1,a2,a3,a4) {
michael@0 4682 try {
michael@0 4683 Module["dynCall_viifi"](index,a1,a2,a3,a4);
michael@0 4684 } catch(e) {
michael@0 4685 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4686 asm["setThrew"](1, 0);
michael@0 4687 }
michael@0 4688 }
michael@0 4689 function invoke_v(index) {
michael@0 4690 try {
michael@0 4691 Module["dynCall_v"](index);
michael@0 4692 } catch(e) {
michael@0 4693 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4694 asm["setThrew"](1, 0);
michael@0 4695 }
michael@0 4696 }
michael@0 4697 function invoke_viif(index,a1,a2,a3) {
michael@0 4698 try {
michael@0 4699 Module["dynCall_viif"](index,a1,a2,a3);
michael@0 4700 } catch(e) {
michael@0 4701 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4702 asm["setThrew"](1, 0);
michael@0 4703 }
michael@0 4704 }
michael@0 4705 function invoke_iiif(index,a1,a2,a3) {
michael@0 4706 try {
michael@0 4707 return Module["dynCall_iiif"](index,a1,a2,a3);
michael@0 4708 } catch(e) {
michael@0 4709 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4710 asm["setThrew"](1, 0);
michael@0 4711 }
michael@0 4712 }
michael@0 4713 function invoke_fiiifii(index,a1,a2,a3,a4,a5,a6) {
michael@0 4714 try {
michael@0 4715 return Module["dynCall_fiiifii"](index,a1,a2,a3,a4,a5,a6);
michael@0 4716 } catch(e) {
michael@0 4717 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4718 asm["setThrew"](1, 0);
michael@0 4719 }
michael@0 4720 }
michael@0 4721 function invoke_viiii(index,a1,a2,a3,a4) {
michael@0 4722 try {
michael@0 4723 Module["dynCall_viiii"](index,a1,a2,a3,a4);
michael@0 4724 } catch(e) {
michael@0 4725 if (typeof e !== 'number' && e !== 'longjmp') throw e;
michael@0 4726 asm["setThrew"](1, 0);
michael@0 4727 }
michael@0 4728 }
michael@0 4729 function asmPrintInt(x, y) {
michael@0 4730 Module.print('int ' + x + ',' + y);// + ' ' + new Error().stack);
michael@0 4731 }
michael@0 4732 function asmPrintFloat(x, y) {
michael@0 4733 Module.print('float ' + x + ',' + y);// + ' ' + new Error().stack);
michael@0 4734 }
michael@0 4735 // EMSCRIPTEN_START_ASM
michael@0 4736 var asmModule = function(global, env, buffer) {
michael@0 4737 'use asm';
michael@0 4738 var HEAP8 = new global.Int8Array(buffer);
michael@0 4739 var HEAP16 = new global.Int16Array(buffer);
michael@0 4740 var HEAP32 = new global.Int32Array(buffer);
michael@0 4741 var HEAPU8 = new global.Uint8Array(buffer);
michael@0 4742 var HEAPU16 = new global.Uint16Array(buffer);
michael@0 4743 var HEAPU32 = new global.Uint32Array(buffer);
michael@0 4744 var HEAPF32 = new global.Float32Array(buffer);
michael@0 4745 var HEAPF64 = new global.Float64Array(buffer);
michael@0 4746 var STACKTOP=env.STACKTOP|0;
michael@0 4747 var STACK_MAX=env.STACK_MAX|0;
michael@0 4748 var tempDoublePtr=env.tempDoublePtr|0;
michael@0 4749 var ABORT=env.ABORT|0;
michael@0 4750 var cttz_i8=env.cttz_i8|0;
michael@0 4751 var ctlz_i8=env.ctlz_i8|0;
michael@0 4752 var __ZTVN10__cxxabiv117__class_type_infoE=env.__ZTVN10__cxxabiv117__class_type_infoE|0;
michael@0 4753 var __ZTVN10__cxxabiv120__si_class_type_infoE=env.__ZTVN10__cxxabiv120__si_class_type_infoE|0;
michael@0 4754 var ___dso_handle=env.___dso_handle|0;
michael@0 4755 var NaN=+env.NaN;
michael@0 4756 var Infinity=+env.Infinity;
michael@0 4757 var __THREW__ = 0;
michael@0 4758 var threwValue = 0;
michael@0 4759 var setjmpId = 0;
michael@0 4760 var undef = 0;
michael@0 4761 var tempInt = 0, tempBigInt = 0, tempBigIntP = 0, tempBigIntS = 0, tempBigIntR = 0.0, tempBigIntI = 0, tempBigIntD = 0, tempValue = 0, tempDouble = 0.0;
michael@0 4762 var tempRet0 = 0;
michael@0 4763 var tempRet1 = 0;
michael@0 4764 var tempRet2 = 0;
michael@0 4765 var tempRet3 = 0;
michael@0 4766 var tempRet4 = 0;
michael@0 4767 var tempRet5 = 0;
michael@0 4768 var tempRet6 = 0;
michael@0 4769 var tempRet7 = 0;
michael@0 4770 var tempRet8 = 0;
michael@0 4771 var tempRet9 = 0;
michael@0 4772 var Math_floor=global.Math.floor;
michael@0 4773 var Math_abs=global.Math.abs;
michael@0 4774 var Math_sqrt=global.Math.sqrt;
michael@0 4775 var Math_pow=global.Math.pow;
michael@0 4776 var Math_cos=global.Math.cos;
michael@0 4777 var Math_sin=global.Math.sin;
michael@0 4778 var Math_tan=global.Math.tan;
michael@0 4779 var Math_acos=global.Math.acos;
michael@0 4780 var Math_asin=global.Math.asin;
michael@0 4781 var Math_atan=global.Math.atan;
michael@0 4782 var Math_atan2=global.Math.atan2;
michael@0 4783 var Math_exp=global.Math.exp;
michael@0 4784 var Math_log=global.Math.log;
michael@0 4785 var Math_ceil=global.Math.ceil;
michael@0 4786 var Math_imul=global.Math.imul;
michael@0 4787 var abort=env.abort;
michael@0 4788 var assert=env.assert;
michael@0 4789 var asmPrintInt=env.asmPrintInt;
michael@0 4790 var asmPrintFloat=env.asmPrintFloat;
michael@0 4791 var Math_min=env.min;
michael@0 4792 var invoke_iiiiiiii=env.invoke_iiiiiiii;
michael@0 4793 var invoke_vif=env.invoke_vif;
michael@0 4794 var invoke_viifii=env.invoke_viifii;
michael@0 4795 var invoke_viiiii=env.invoke_viiiii;
michael@0 4796 var invoke_vi=env.invoke_vi;
michael@0 4797 var invoke_vii=env.invoke_vii;
michael@0 4798 var invoke_viiifii=env.invoke_viiifii;
michael@0 4799 var invoke_vifiii=env.invoke_vifiii;
michael@0 4800 var invoke_ii=env.invoke_ii;
michael@0 4801 var invoke_viiiiffffiif=env.invoke_viiiiffffiif;
michael@0 4802 var invoke_fiii=env.invoke_fiii;
michael@0 4803 var invoke_viiif=env.invoke_viiif;
michael@0 4804 var invoke_fiiiiiiiiiii=env.invoke_fiiiiiiiiiii;
michael@0 4805 var invoke_fiifii=env.invoke_fiifii;
michael@0 4806 var invoke_iii=env.invoke_iii;
michael@0 4807 var invoke_iiii=env.invoke_iiii;
michael@0 4808 var invoke_fif=env.invoke_fif;
michael@0 4809 var invoke_viiiiiiii=env.invoke_viiiiiiii;
michael@0 4810 var invoke_vifi=env.invoke_vifi;
michael@0 4811 var invoke_viiiiii=env.invoke_viiiiii;
michael@0 4812 var invoke_iiiiiiiiii=env.invoke_iiiiiiiiii;
michael@0 4813 var invoke_viffiii=env.invoke_viffiii;
michael@0 4814 var invoke_iiiiiii=env.invoke_iiiiiii;
michael@0 4815 var invoke_fiiiiiiiiii=env.invoke_fiiiiiiiiii;
michael@0 4816 var invoke_fiiiii=env.invoke_fiiiii;
michael@0 4817 var invoke_iiiiiiiiiiii=env.invoke_iiiiiiiiiiii;
michael@0 4818 var invoke_vifii=env.invoke_vifii;
michael@0 4819 var invoke_fi=env.invoke_fi;
michael@0 4820 var invoke_viiiiiiiiii=env.invoke_viiiiiiiiii;
michael@0 4821 var invoke_viiiifffffif=env.invoke_viiiifffffif;
michael@0 4822 var invoke_viiiiiffii=env.invoke_viiiiiffii;
michael@0 4823 var invoke_iifif=env.invoke_iifif;
michael@0 4824 var invoke_iiiii=env.invoke_iiiii;
michael@0 4825 var invoke_viii=env.invoke_viii;
michael@0 4826 var invoke_viifi=env.invoke_viifi;
michael@0 4827 var invoke_v=env.invoke_v;
michael@0 4828 var invoke_viif=env.invoke_viif;
michael@0 4829 var invoke_iiif=env.invoke_iiif;
michael@0 4830 var invoke_fiiifii=env.invoke_fiiifii;
michael@0 4831 var invoke_viiii=env.invoke_viiii;
michael@0 4832 var _llvm_lifetime_end=env._llvm_lifetime_end;
michael@0 4833 var _cosf=env._cosf;
michael@0 4834 var _fabsf=env._fabsf;
michael@0 4835 var _sysconf=env._sysconf;
michael@0 4836 var ___cxa_throw=env.___cxa_throw;
michael@0 4837 var _atexit=env._atexit;
michael@0 4838 var _abort=env._abort;
michael@0 4839 var _fprintf=env._fprintf;
michael@0 4840 var _llvm_eh_exception=env._llvm_eh_exception;
michael@0 4841 var _printf=env._printf;
michael@0 4842 var _acosf=env._acosf;
michael@0 4843 var _fflush=env._fflush;
michael@0 4844 var __reallyNegative=env.__reallyNegative;
michael@0 4845 var _sqrtf=env._sqrtf;
michael@0 4846 var _llvm_pow_f32=env._llvm_pow_f32;
michael@0 4847 var ___setErrNo=env.___setErrNo;
michael@0 4848 var _fwrite=env._fwrite;
michael@0 4849 var _send=env._send;
michael@0 4850 var _write=env._write;
michael@0 4851 var _exit=env._exit;
michael@0 4852 var _atan2f=env._atan2f;
michael@0 4853 var ___cxa_pure_virtual=env.___cxa_pure_virtual;
michael@0 4854 var ___cxa_is_number_type=env.___cxa_is_number_type;
michael@0 4855 var _time=env._time;
michael@0 4856 var __formatString=env.__formatString;
michael@0 4857 var ___cxa_does_inherit=env.___cxa_does_inherit;
michael@0 4858 var ___cxa_guard_acquire=env.___cxa_guard_acquire;
michael@0 4859 var __ZSt9terminatev=env.__ZSt9terminatev;
michael@0 4860 var _gettimeofday=env._gettimeofday;
michael@0 4861 var ___cxa_find_matching_catch=env.___cxa_find_matching_catch;
michael@0 4862 var _sinf=env._sinf;
michael@0 4863 var ___assert_func=env.___assert_func;
michael@0 4864 var __ZSt18uncaught_exceptionv=env.__ZSt18uncaught_exceptionv;
michael@0 4865 var _pwrite=env._pwrite;
michael@0 4866 var ___cxa_call_unexpected=env.___cxa_call_unexpected;
michael@0 4867 var _sbrk=env._sbrk;
michael@0 4868 var ___cxa_guard_abort=env.___cxa_guard_abort;
michael@0 4869 var ___cxa_allocate_exception=env.___cxa_allocate_exception;
michael@0 4870 var ___errno_location=env.___errno_location;
michael@0 4871 var ___gxx_personality_v0=env.___gxx_personality_v0;
michael@0 4872 var _llvm_lifetime_start=env._llvm_lifetime_start;
michael@0 4873 var _fmod=env._fmod;
michael@0 4874 var ___cxa_guard_release=env.___cxa_guard_release;
michael@0 4875 var __exit=env.__exit;
michael@0 4876 var ___resumeException=env.___resumeException;
michael@0 4877 // EMSCRIPTEN_START_FUNCS
michael@0 4878 function __ZN20btConvexHullInternal9shiftFaceEPNS_4FaceEf20btAlignedObjectArrayIPNS_6VertexEE(i1, i2, d3, i4) {
michael@0 4879 i1 = i1 | 0;
michael@0 4880 i2 = i2 | 0;
michael@0 4881 d3 = +d3;
michael@0 4882 i4 = i4 | 0;
michael@0 4883 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0, i88 = 0, i89 = 0, i90 = 0, i91 = 0, i92 = 0, i93 = 0, i94 = 0, i95 = 0, i96 = 0, i97 = 0, i98 = 0, i99 = 0, i100 = 0, i101 = 0, i102 = 0, i103 = 0, i104 = 0, i105 = 0, i106 = 0, i107 = 0, i108 = 0, i109 = 0, i110 = 0, i111 = 0, i112 = 0, i113 = 0, i114 = 0, i115 = 0, i116 = 0, i117 = 0, i118 = 0, i119 = 0, i120 = 0, i121 = 0, i122 = 0, i123 = 0, i124 = 0, i125 = 0, i126 = 0, i127 = 0, i128 = 0, i129 = 0, i130 = 0, i131 = 0, i132 = 0, i133 = 0, i134 = 0, i135 = 0, i136 = 0, i137 = 0, i138 = 0, i139 = 0, i140 = 0, i141 = 0, i142 = 0, i143 = 0, i144 = 0, i145 = 0, i146 = 0, i147 = 0, i148 = 0, i149 = 0, i150 = 0, i151 = 0, i152 = 0, i153 = 0, i154 = 0, i155 = 0, i156 = 0, i157 = 0, i158 = 0, i159 = 0, i160 = 0, i161 = 0, i162 = 0, i163 = 0, i164 = 0, i165 = 0, i166 = 0, i167 = 0, i168 = 0, i169 = 0, i170 = 0, i171 = 0, i172 = 0, i173 = 0, i174 = 0, i175 = 0, i176 = 0, i177 = 0, i178 = 0, i179 = 0, i180 = 0, i181 = 0, i182 = 0, i183 = 0, i184 = 0, i185 = 0, i186 = 0, i187 = 0, i188 = 0, i189 = 0, i190 = 0, i191 = 0, i192 = 0, i193 = 0, i194 = 0, i195 = 0, i196 = 0, i197 = 0, i198 = 0, i199 = 0, i200 = 0, i201 = 0, i202 = 0, i203 = 0, i204 = 0, i205 = 0, i206 = 0, i207 = 0, i208 = 0, i209 = 0, i210 = 0, i211 = 0, i212 = 0, i213 = 0, i214 = 0, i215 = 0, i216 = 0, i217 = 0, i218 = 0, i219 = 0, i220 = 0, i221 = 0, i222 = 0, i223 = 0, i224 = 0, i225 = 0, i226 = 0, i227 = 0, i228 = 0, i229 = 0, i230 = 0, i231 = 0, i232 = 0, i233 = 0, i234 = 0, i235 = 0, i236 = 0, i237 = 0, i238 = 0, i239 = 0, i240 = 0, i241 = 0, i242 = 0, i243 = 0, i244 = 0, i245 = 0, i246 = 0, i247 = 0, i248 = 0, i249 = 0, i250 = 0, i251 = 0, i252 = 0, i253 = 0, i254 = 0, i255 = 0, i256 = 0, i257 = 0, i258 = 0, i259 = 0, i260 = 0, i261 = 0, i262 = 0, i263 = 0, i264 = 0, i265 = 0, i266 = 0, i267 = 0, i268 = 0, i269 = 0, i270 = 0, i271 = 0, i272 = 0, i273 = 0, i274 = 0, i275 = 0, i276 = 0, i277 = 0, i278 = 0, i279 = 0, i280 = 0, i281 = 0, i282 = 0, i283 = 0, i284 = 0, i285 = 0, i286 = 0, i287 = 0, i288 = 0, i289 = 0, i290 = 0, i291 = 0, i292 = 0, i293 = 0, i294 = 0, i295 = 0, i296 = 0, i297 = 0, i298 = 0, i299 = 0, i300 = 0, i301 = 0, i302 = 0;
michael@0 4884 i5 = STACKTOP;
michael@0 4885 STACKTOP = STACKTOP + 296 | 0;
michael@0 4886 i6 = i5 | 0;
michael@0 4887 i7 = i5 + 16 | 0;
michael@0 4888 i8 = i5 + 32 | 0;
michael@0 4889 i9 = i5 + 56 | 0;
michael@0 4890 i10 = i5 + 96 | 0;
michael@0 4891 i11 = i5 + 136 | 0;
michael@0 4892 i12 = i5 + 176 | 0;
michael@0 4893 i13 = i5 + 216 | 0;
michael@0 4894 i14 = i5 + 256 | 0;
michael@0 4895 __ZN20btConvexHullInternal11getBtNormalEPNS_4FaceE(i7, i1, i2);
michael@0 4896 d15 = -0.0 - d3;
michael@0 4897 d3 = +HEAPF32[i7 >> 2] * d15;
michael@0 4898 d16 = +HEAPF32[i7 + 4 >> 2] * d15;
michael@0 4899 d17 = +HEAPF32[i7 + 8 >> 2] * d15;
michael@0 4900 i7 = i6 | 0;
michael@0 4901 HEAPF32[i7 >> 2] = d3;
michael@0 4902 i18 = i6 + 4 | 0;
michael@0 4903 HEAPF32[i18 >> 2] = d16;
michael@0 4904 i19 = i6 + 8 | 0;
michael@0 4905 HEAPF32[i19 >> 2] = d17;
michael@0 4906 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 4907 d15 = +HEAPF32[i1 >> 2];
michael@0 4908 if (d15 > 0.0) {
michael@0 4909 HEAPF32[i7 >> 2] = d3 / d15;
michael@0 4910 }
michael@0 4911 d15 = +HEAPF32[i1 + 4 >> 2];
michael@0 4912 if (d15 > 0.0) {
michael@0 4913 HEAPF32[i18 >> 2] = d16 / d15;
michael@0 4914 }
michael@0 4915 d15 = +HEAPF32[i1 + 8 >> 2];
michael@0 4916 if (d15 > 0.0) {
michael@0 4917 HEAPF32[i19 >> 2] = d17 / d15;
michael@0 4918 }
michael@0 4919 i19 = ~~+HEAPF32[i6 + (HEAP32[i1 + 108 >> 2] << 2) >> 2];
michael@0 4920 i18 = ~~+HEAPF32[i6 + (HEAP32[i1 + 112 >> 2] << 2) >> 2];
michael@0 4921 i7 = ~~+HEAPF32[i6 + (HEAP32[i1 + 104 >> 2] << 2) >> 2];
michael@0 4922 if ((i18 | i19 | i7 | 0) == 0) {
michael@0 4923 i20 = 1;
michael@0 4924 STACKTOP = i5;
michael@0 4925 return i20 | 0;
michael@0 4926 }
michael@0 4927 i6 = i2 + 32 | 0;
michael@0 4928 i21 = HEAP32[i6 >> 2] | 0;
michael@0 4929 i22 = i2 + 52 | 0;
michael@0 4930 i23 = HEAP32[i22 >> 2] | 0;
michael@0 4931 i24 = Math_imul(i23, i21) | 0;
michael@0 4932 i25 = i2 + 36 | 0;
michael@0 4933 i26 = HEAP32[i25 >> 2] | 0;
michael@0 4934 i27 = i2 + 48 | 0;
michael@0 4935 i28 = HEAP32[i27 >> 2] | 0;
michael@0 4936 i29 = i24 - (Math_imul(i28, i26) | 0) | 0;
michael@0 4937 i24 = i29;
michael@0 4938 i30 = (i29 | 0) < 0 ? -1 : 0;
michael@0 4939 i29 = i2 + 44 | 0;
michael@0 4940 i31 = HEAP32[i29 >> 2] | 0;
michael@0 4941 i32 = Math_imul(i31, i26) | 0;
michael@0 4942 i26 = i2 + 28 | 0;
michael@0 4943 i33 = HEAP32[i26 >> 2] | 0;
michael@0 4944 i34 = i32 - (Math_imul(i33, i23) | 0) | 0;
michael@0 4945 i23 = i34;
michael@0 4946 i32 = (i34 | 0) < 0 ? -1 : 0;
michael@0 4947 i34 = Math_imul(i33, i28) | 0;
michael@0 4948 i28 = i34 - (Math_imul(i31, i21) | 0) | 0;
michael@0 4949 i21 = i28;
michael@0 4950 i31 = (i28 | 0) < 0 ? -1 : 0;
michael@0 4951 i28 = i8 | 0;
michael@0 4952 HEAP32[i28 >> 2] = i24;
michael@0 4953 HEAP32[i28 + 4 >> 2] = i30;
michael@0 4954 i28 = i8 + 8 | 0;
michael@0 4955 HEAP32[i28 >> 2] = i23;
michael@0 4956 HEAP32[i28 + 4 >> 2] = i32;
michael@0 4957 i28 = i8 + 16 | 0;
michael@0 4958 HEAP32[i28 >> 2] = i21;
michael@0 4959 HEAP32[i28 + 4 >> 2] = i31;
michael@0 4960 i28 = i2 + 12 | 0;
michael@0 4961 i34 = HEAP32[i28 >> 2] | 0;
michael@0 4962 i33 = ___muldi3(i34, (i34 | 0) < 0 ? -1 : 0, i24, i30) | 0;
michael@0 4963 i35 = tempRet0;
michael@0 4964 i36 = i2 + 16 | 0;
michael@0 4965 i37 = HEAP32[i36 >> 2] | 0;
michael@0 4966 i38 = ___muldi3(i37, (i37 | 0) < 0 ? -1 : 0, i23, i32) | 0;
michael@0 4967 i39 = _i64Add(i38, tempRet0, i33, i35) | 0;
michael@0 4968 i35 = tempRet0;
michael@0 4969 i33 = i2 + 20 | 0;
michael@0 4970 i38 = HEAP32[i33 >> 2] | 0;
michael@0 4971 i40 = ___muldi3(i38, (i38 | 0) < 0 ? -1 : 0, i21, i31) | 0;
michael@0 4972 i41 = _i64Add(i39, i35, i40, tempRet0) | 0;
michael@0 4973 i40 = tempRet0;
michael@0 4974 i35 = i34 + i19 | 0;
michael@0 4975 i19 = i37 + i18 | 0;
michael@0 4976 i18 = i38 + i7 | 0;
michael@0 4977 i7 = i35;
michael@0 4978 i38 = (i35 | 0) < 0 ? -1 : 0;
michael@0 4979 i37 = ___muldi3(i7, i38, i24, i30) | 0;
michael@0 4980 i30 = tempRet0;
michael@0 4981 i24 = i19;
michael@0 4982 i34 = (i19 | 0) < 0 ? -1 : 0;
michael@0 4983 i39 = ___muldi3(i24, i34, i23, i32) | 0;
michael@0 4984 i32 = _i64Add(i39, tempRet0, i37, i30) | 0;
michael@0 4985 i30 = tempRet0;
michael@0 4986 i37 = i18;
michael@0 4987 i39 = (i18 | 0) < 0 ? -1 : 0;
michael@0 4988 i23 = ___muldi3(i37, i39, i21, i31) | 0;
michael@0 4989 i31 = _i64Add(i32, i30, i23, tempRet0) | 0;
michael@0 4990 i23 = tempRet0;
michael@0 4991 if (!((i23 | 0) < (i40 | 0) | (i23 | 0) == (i40 | 0) & i31 >>> 0 < i41 >>> 0)) {
michael@0 4992 i20 = 0;
michael@0 4993 STACKTOP = i5;
michael@0 4994 return i20 | 0;
michael@0 4995 }
michael@0 4996 i41 = HEAP32[i2 + 4 >> 2] | 0;
michael@0 4997 i40 = HEAP32[i41 + 8 >> 2] | 0;
michael@0 4998 __ZNK20btConvexHullInternal6Vertex3dotERKNS_7Point64E(i9, i41, i8);
michael@0 4999 i41 = __ZNK20btConvexHullInternal11Rational1287compareEx(i9, i31, i23) | 0;
michael@0 5000 i30 = i9;
michael@0 5001 do {
michael@0 5002 if ((i41 | 0) > -1) {
michael@0 5003 i32 = i10;
michael@0 5004 i21 = i40;
michael@0 5005 i42 = i41;
michael@0 5006 i43 = i40;
michael@0 5007 while (1) {
michael@0 5008 __ZNK20btConvexHullInternal6Vertex3dotERKNS_7Point64E(i10, HEAP32[i43 + 12 >> 2] | 0, i8);
michael@0 5009 if ((__ZNK20btConvexHullInternal11Rational1287compareERKS0_(i10, i9) | 0) < 0) {
michael@0 5010 i44 = __ZNK20btConvexHullInternal11Rational1287compareEx(i10, i31, i23) | 0;
michael@0 5011 HEAP32[i30 >> 2] = HEAP32[i32 >> 2];
michael@0 5012 HEAP32[i30 + 4 >> 2] = HEAP32[i32 + 4 >> 2];
michael@0 5013 HEAP32[i30 + 8 >> 2] = HEAP32[i32 + 8 >> 2];
michael@0 5014 HEAP32[i30 + 12 >> 2] = HEAP32[i32 + 12 >> 2];
michael@0 5015 HEAP32[i30 + 16 >> 2] = HEAP32[i32 + 16 >> 2];
michael@0 5016 HEAP32[i30 + 20 >> 2] = HEAP32[i32 + 20 >> 2];
michael@0 5017 HEAP32[i30 + 24 >> 2] = HEAP32[i32 + 24 >> 2];
michael@0 5018 HEAP32[i30 + 28 >> 2] = HEAP32[i32 + 28 >> 2];
michael@0 5019 HEAP32[i30 + 32 >> 2] = HEAP32[i32 + 32 >> 2];
michael@0 5020 HEAP8[i30 + 36 | 0] = HEAP8[i32 + 36 | 0] | 0;
michael@0 5021 i45 = HEAP32[i43 + 8 >> 2] | 0;
michael@0 5022 if ((i44 | 0) < 0) {
michael@0 5023 break;
michael@0 5024 } else {
michael@0 5025 i46 = i45;
michael@0 5026 i47 = i44;
michael@0 5027 i48 = i45;
michael@0 5028 }
michael@0 5029 } else {
michael@0 5030 i46 = i21;
michael@0 5031 i47 = i42;
michael@0 5032 i48 = i43;
michael@0 5033 }
michael@0 5034 i44 = HEAP32[i48 + 4 >> 2] | 0;
michael@0 5035 if ((i44 | 0) == (i46 | 0)) {
michael@0 5036 i20 = 0;
michael@0 5037 i49 = 1612;
michael@0 5038 break;
michael@0 5039 } else {
michael@0 5040 i21 = i46;
michael@0 5041 i42 = i47;
michael@0 5042 i43 = i44;
michael@0 5043 }
michael@0 5044 }
michael@0 5045 if ((i49 | 0) == 1612) {
michael@0 5046 STACKTOP = i5;
michael@0 5047 return i20 | 0;
michael@0 5048 }
michael@0 5049 if ((i45 | 0) == 0) {
michael@0 5050 i20 = 0;
michael@0 5051 } else {
michael@0 5052 i50 = i45;
michael@0 5053 i51 = i42;
michael@0 5054 break;
michael@0 5055 }
michael@0 5056 STACKTOP = i5;
michael@0 5057 return i20 | 0;
michael@0 5058 } else {
michael@0 5059 i43 = i11;
michael@0 5060 i21 = i40;
michael@0 5061 i32 = i40;
michael@0 5062 while (1) {
michael@0 5063 __ZNK20btConvexHullInternal6Vertex3dotERKNS_7Point64E(i11, HEAP32[i32 + 12 >> 2] | 0, i8);
michael@0 5064 if ((__ZNK20btConvexHullInternal11Rational1287compareERKS0_(i11, i9) | 0) > 0) {
michael@0 5065 i52 = __ZNK20btConvexHullInternal11Rational1287compareEx(i11, i31, i23) | 0;
michael@0 5066 if ((i52 | 0) > -1) {
michael@0 5067 break;
michael@0 5068 }
michael@0 5069 HEAP32[i30 >> 2] = HEAP32[i43 >> 2];
michael@0 5070 HEAP32[i30 + 4 >> 2] = HEAP32[i43 + 4 >> 2];
michael@0 5071 HEAP32[i30 + 8 >> 2] = HEAP32[i43 + 8 >> 2];
michael@0 5072 HEAP32[i30 + 12 >> 2] = HEAP32[i43 + 12 >> 2];
michael@0 5073 HEAP32[i30 + 16 >> 2] = HEAP32[i43 + 16 >> 2];
michael@0 5074 HEAP32[i30 + 20 >> 2] = HEAP32[i43 + 20 >> 2];
michael@0 5075 HEAP32[i30 + 24 >> 2] = HEAP32[i43 + 24 >> 2];
michael@0 5076 HEAP32[i30 + 28 >> 2] = HEAP32[i43 + 28 >> 2];
michael@0 5077 HEAP32[i30 + 32 >> 2] = HEAP32[i43 + 32 >> 2];
michael@0 5078 HEAP8[i30 + 36 | 0] = HEAP8[i43 + 36 | 0] | 0;
michael@0 5079 i44 = HEAP32[i32 + 8 >> 2] | 0;
michael@0 5080 i53 = i44;
michael@0 5081 i54 = i44;
michael@0 5082 } else {
michael@0 5083 i53 = i21;
michael@0 5084 i54 = i32;
michael@0 5085 }
michael@0 5086 i44 = HEAP32[i54 + 4 >> 2] | 0;
michael@0 5087 if ((i44 | 0) == (i53 | 0)) {
michael@0 5088 i20 = 1;
michael@0 5089 i49 = 1615;
michael@0 5090 break;
michael@0 5091 } else {
michael@0 5092 i21 = i53;
michael@0 5093 i32 = i44;
michael@0 5094 }
michael@0 5095 }
michael@0 5096 if ((i49 | 0) == 1615) {
michael@0 5097 STACKTOP = i5;
michael@0 5098 return i20 | 0;
michael@0 5099 }
michael@0 5100 if ((i32 | 0) == 0) {
michael@0 5101 i20 = 1;
michael@0 5102 } else {
michael@0 5103 i50 = i32;
michael@0 5104 i51 = i52;
michael@0 5105 break;
michael@0 5106 }
michael@0 5107 STACKTOP = i5;
michael@0 5108 return i20 | 0;
michael@0 5109 }
michael@0 5110 } while (0);
michael@0 5111 L1672 : do {
michael@0 5112 if ((i51 | 0) == 0) {
michael@0 5113 i52 = i50 + 8 | 0;
michael@0 5114 i53 = HEAP32[HEAP32[i52 >> 2] >> 2] | 0;
michael@0 5115 while (1) {
michael@0 5116 __ZNK20btConvexHullInternal6Vertex3dotERKNS_7Point64E(i12, HEAP32[i53 + 12 >> 2] | 0, i8);
michael@0 5117 if ((__ZNK20btConvexHullInternal11Rational1287compareEx(i12, i31, i23) | 0) >= 1) {
michael@0 5118 break L1672;
michael@0 5119 }
michael@0 5120 i54 = HEAP32[i53 >> 2] | 0;
michael@0 5121 if ((i54 | 0) == (HEAP32[i52 >> 2] | 0)) {
michael@0 5122 i20 = 1;
michael@0 5123 break;
michael@0 5124 } else {
michael@0 5125 i53 = i54;
michael@0 5126 }
michael@0 5127 }
michael@0 5128 STACKTOP = i5;
michael@0 5129 return i20 | 0;
michael@0 5130 }
michael@0 5131 } while (0);
michael@0 5132 i12 = i1 + 32 | 0;
michael@0 5133 i53 = i4 + 4 | 0;
michael@0 5134 i52 = i4 + 8 | 0;
michael@0 5135 i32 = i4 + 12 | 0;
michael@0 5136 i54 = i4 + 16 | 0;
michael@0 5137 i4 = i1 + 56 | 0;
michael@0 5138 i30 = i1 + 116 | 0;
michael@0 5139 i11 = i1 + 48 | 0;
michael@0 5140 i9 = i1 + 100 | 0;
michael@0 5141 i40 = i1 + 120 | 0;
michael@0 5142 i45 = (i35 | 0) < 0;
michael@0 5143 i47 = _i64Subtract(0, 0, i7, i38) | 0;
michael@0 5144 i46 = tempRet0;
michael@0 5145 i48 = (i19 | 0) < 0;
michael@0 5146 i10 = _i64Subtract(0, 0, i24, i34) | 0;
michael@0 5147 i41 = tempRet0;
michael@0 5148 i21 = (i18 | 0) < 0;
michael@0 5149 i43 = _i64Subtract(0, 0, i37, i39) | 0;
michael@0 5150 i42 = tempRet0;
michael@0 5151 i44 = i50;
michael@0 5152 i50 = i51;
michael@0 5153 i51 = 0;
michael@0 5154 i55 = 0;
michael@0 5155 i56 = 0;
michael@0 5156 L1679 : while (1) {
michael@0 5157 i57 = (i50 | 0) == 0;
michael@0 5158 L1681 : do {
michael@0 5159 if (i57) {
michael@0 5160 i58 = HEAP32[HEAP32[i44 + 8 >> 2] >> 2] | 0;
michael@0 5161 i59 = i44;
michael@0 5162 i60 = i58;
michael@0 5163 while (1) {
michael@0 5164 __ZNK20btConvexHullInternal6Vertex3dotERKNS_7Point64E(i13, HEAP32[i60 + 12 >> 2] | 0, i8);
michael@0 5165 if ((__ZNK20btConvexHullInternal11Rational1287compareEx(i13, i31, i23) | 0) > -1) {
michael@0 5166 i61 = i59;
michael@0 5167 break L1681;
michael@0 5168 }
michael@0 5169 i62 = HEAP32[i60 >> 2] | 0;
michael@0 5170 if ((i62 | 0) == (i58 | 0)) {
michael@0 5171 i20 = 1;
michael@0 5172 i49 = 1618;
michael@0 5173 break L1679;
michael@0 5174 } else {
michael@0 5175 i59 = HEAP32[i60 + 8 >> 2] | 0;
michael@0 5176 i60 = i62;
michael@0 5177 }
michael@0 5178 }
michael@0 5179 } else {
michael@0 5180 i61 = i44;
michael@0 5181 }
michael@0 5182 } while (0);
michael@0 5183 if ((i51 | 0) == 0) {
michael@0 5184 i63 = i61;
michael@0 5185 } else {
michael@0 5186 if ((i61 | 0) == (i51 | 0)) {
michael@0 5187 break;
michael@0 5188 } else {
michael@0 5189 i63 = i51;
michael@0 5190 }
michael@0 5191 }
michael@0 5192 i60 = i61 + 8 | 0;
michael@0 5193 i59 = HEAP32[i60 >> 2] | 0;
michael@0 5194 do {
michael@0 5195 i59 = HEAP32[(HEAP32[i59 + 8 >> 2] | 0) + 4 >> 2] | 0;
michael@0 5196 i64 = i59 + 12 | 0;
michael@0 5197 __ZNK20btConvexHullInternal6Vertex3dotERKNS_7Point64E(i14, HEAP32[i64 >> 2] | 0, i8);
michael@0 5198 i65 = __ZNK20btConvexHullInternal11Rational1287compareEx(i14, i31, i23) | 0;
michael@0 5199 } while ((i65 | 0) <= -1);
michael@0 5200 if ((i65 | 0) > 0) {
michael@0 5201 i58 = HEAP32[i64 >> 2] | 0;
michael@0 5202 i62 = i59 + 8 | 0;
michael@0 5203 i66 = HEAP32[i62 >> 2] | 0;
michael@0 5204 i67 = i66 + 4 | 0;
michael@0 5205 i68 = HEAP32[i67 >> 2] | 0;
michael@0 5206 i69 = i58 + 8 | 0;
michael@0 5207 if ((i68 | 0) == (i66 | 0)) {
michael@0 5208 HEAP32[i69 >> 2] = 0;
michael@0 5209 } else {
michael@0 5210 HEAP32[i69 >> 2] = i68;
michael@0 5211 i68 = HEAP32[i67 >> 2] | 0;
michael@0 5212 i69 = i66 | 0;
michael@0 5213 i70 = HEAP32[i69 >> 2] | 0;
michael@0 5214 HEAP32[i68 >> 2] = i70;
michael@0 5215 HEAP32[i70 + 4 >> 2] = i68;
michael@0 5216 HEAP32[i69 >> 2] = i66;
michael@0 5217 HEAP32[i67 >> 2] = i66;
michael@0 5218 }
michael@0 5219 i67 = HEAP32[i59 + 16 >> 2] | 0;
michael@0 5220 i69 = HEAP32[i67 + 32 >> 2] | 0;
michael@0 5221 i68 = HEAP32[i67 + 52 >> 2] | 0;
michael@0 5222 i70 = Math_imul(i68, i69) | 0;
michael@0 5223 i71 = HEAP32[i67 + 36 >> 2] | 0;
michael@0 5224 i72 = HEAP32[i67 + 48 >> 2] | 0;
michael@0 5225 i73 = i70 - (Math_imul(i72, i71) | 0) | 0;
michael@0 5226 i70 = i73;
michael@0 5227 i74 = (i73 | 0) < 0 ? -1 : 0;
michael@0 5228 i73 = HEAP32[i67 + 44 >> 2] | 0;
michael@0 5229 i75 = Math_imul(i73, i71) | 0;
michael@0 5230 i71 = HEAP32[i67 + 28 >> 2] | 0;
michael@0 5231 i76 = i75 - (Math_imul(i71, i68) | 0) | 0;
michael@0 5232 i68 = i76;
michael@0 5233 i75 = (i76 | 0) < 0 ? -1 : 0;
michael@0 5234 i76 = Math_imul(i71, i72) | 0;
michael@0 5235 i72 = i76 - (Math_imul(i73, i69) | 0) | 0;
michael@0 5236 i69 = i72;
michael@0 5237 i73 = (i72 | 0) < 0 ? -1 : 0;
michael@0 5238 i72 = HEAP32[(HEAP32[i62 >> 2] | 0) + 16 >> 2] | 0;
michael@0 5239 i62 = HEAP32[i72 + 32 >> 2] | 0;
michael@0 5240 i76 = HEAP32[i72 + 52 >> 2] | 0;
michael@0 5241 i71 = Math_imul(i76, i62) | 0;
michael@0 5242 i77 = HEAP32[i72 + 36 >> 2] | 0;
michael@0 5243 i78 = HEAP32[i72 + 48 >> 2] | 0;
michael@0 5244 i79 = i71 - (Math_imul(i78, i77) | 0) | 0;
michael@0 5245 i71 = i79;
michael@0 5246 i80 = (i79 | 0) < 0 ? -1 : 0;
michael@0 5247 i79 = HEAP32[i72 + 44 >> 2] | 0;
michael@0 5248 i81 = Math_imul(i79, i77) | 0;
michael@0 5249 i77 = HEAP32[i72 + 28 >> 2] | 0;
michael@0 5250 i82 = i81 - (Math_imul(i77, i76) | 0) | 0;
michael@0 5251 i76 = i82;
michael@0 5252 i81 = (i82 | 0) < 0 ? -1 : 0;
michael@0 5253 i82 = Math_imul(i77, i78) | 0;
michael@0 5254 i78 = i82 - (Math_imul(i79, i62) | 0) | 0;
michael@0 5255 i62 = i78;
michael@0 5256 i79 = (i78 | 0) < 0 ? -1 : 0;
michael@0 5257 i78 = HEAP32[i26 >> 2] | 0;
michael@0 5258 i82 = i78;
michael@0 5259 i77 = (i78 | 0) < 0 ? -1 : 0;
michael@0 5260 i78 = ___muldi3(i82, i77, i70, i74) | 0;
michael@0 5261 i83 = tempRet0;
michael@0 5262 i84 = HEAP32[i6 >> 2] | 0;
michael@0 5263 i85 = i84;
michael@0 5264 i86 = (i84 | 0) < 0 ? -1 : 0;
michael@0 5265 i84 = ___muldi3(i85, i86, i68, i75) | 0;
michael@0 5266 i87 = _i64Add(i84, tempRet0, i78, i83) | 0;
michael@0 5267 i83 = tempRet0;
michael@0 5268 i78 = HEAP32[i25 >> 2] | 0;
michael@0 5269 i84 = i78;
michael@0 5270 i88 = (i78 | 0) < 0 ? -1 : 0;
michael@0 5271 i78 = ___muldi3(i84, i88, i69, i73) | 0;
michael@0 5272 i89 = _i64Add(i87, i83, i78, tempRet0) | 0;
michael@0 5273 i78 = tempRet0;
michael@0 5274 i83 = HEAP32[i29 >> 2] | 0;
michael@0 5275 i87 = i83;
michael@0 5276 i90 = (i83 | 0) < 0 ? -1 : 0;
michael@0 5277 i83 = ___muldi3(i87, i90, i70, i74) | 0;
michael@0 5278 i91 = tempRet0;
michael@0 5279 i92 = HEAP32[i27 >> 2] | 0;
michael@0 5280 i93 = i92;
michael@0 5281 i94 = (i92 | 0) < 0 ? -1 : 0;
michael@0 5282 i92 = ___muldi3(i93, i94, i68, i75) | 0;
michael@0 5283 i95 = _i64Add(i92, tempRet0, i83, i91) | 0;
michael@0 5284 i91 = tempRet0;
michael@0 5285 i83 = HEAP32[i22 >> 2] | 0;
michael@0 5286 i92 = i83;
michael@0 5287 i96 = (i83 | 0) < 0 ? -1 : 0;
michael@0 5288 i83 = ___muldi3(i92, i96, i69, i73) | 0;
michael@0 5289 i97 = _i64Add(i95, i91, i83, tempRet0) | 0;
michael@0 5290 i83 = tempRet0;
michael@0 5291 i91 = ___muldi3(i82, i77, i71, i80) | 0;
michael@0 5292 i77 = tempRet0;
michael@0 5293 i82 = ___muldi3(i85, i86, i76, i81) | 0;
michael@0 5294 i86 = _i64Add(i82, tempRet0, i91, i77) | 0;
michael@0 5295 i77 = tempRet0;
michael@0 5296 i91 = ___muldi3(i84, i88, i62, i79) | 0;
michael@0 5297 i88 = _i64Add(i86, i77, i91, tempRet0) | 0;
michael@0 5298 i91 = tempRet0;
michael@0 5299 i77 = ___muldi3(i87, i90, i71, i80) | 0;
michael@0 5300 i90 = tempRet0;
michael@0 5301 i87 = ___muldi3(i93, i94, i76, i81) | 0;
michael@0 5302 i94 = _i64Add(i87, tempRet0, i77, i90) | 0;
michael@0 5303 i90 = tempRet0;
michael@0 5304 i77 = ___muldi3(i92, i96, i62, i79) | 0;
michael@0 5305 i96 = _i64Add(i94, i90, i77, tempRet0) | 0;
michael@0 5306 i77 = tempRet0;
michael@0 5307 i90 = (HEAP32[i67 + 12 >> 2] | 0) - i35 | 0;
michael@0 5308 i94 = (HEAP32[i67 + 16 >> 2] | 0) - i19 | 0;
michael@0 5309 i92 = (HEAP32[i67 + 20 >> 2] | 0) - i18 | 0;
michael@0 5310 i67 = ___muldi3(i90, (i90 | 0) < 0 ? -1 : 0, i70, i74) | 0;
michael@0 5311 i74 = tempRet0;
michael@0 5312 i70 = ___muldi3(i94, (i94 | 0) < 0 ? -1 : 0, i68, i75) | 0;
michael@0 5313 i75 = _i64Add(i70, tempRet0, i67, i74) | 0;
michael@0 5314 i74 = tempRet0;
michael@0 5315 i67 = ___muldi3(i92, (i92 | 0) < 0 ? -1 : 0, i69, i73) | 0;
michael@0 5316 i73 = _i64Add(i75, i74, i67, tempRet0) | 0;
michael@0 5317 i67 = tempRet0;
michael@0 5318 i74 = (HEAP32[i72 + 12 >> 2] | 0) - i35 | 0;
michael@0 5319 i75 = (HEAP32[i72 + 16 >> 2] | 0) - i19 | 0;
michael@0 5320 i69 = (HEAP32[i72 + 20 >> 2] | 0) - i18 | 0;
michael@0 5321 i72 = ___muldi3(i74, (i74 | 0) < 0 ? -1 : 0, i71, i80) | 0;
michael@0 5322 i80 = tempRet0;
michael@0 5323 i71 = ___muldi3(i75, (i75 | 0) < 0 ? -1 : 0, i76, i81) | 0;
michael@0 5324 i81 = _i64Add(i71, tempRet0, i72, i80) | 0;
michael@0 5325 i80 = tempRet0;
michael@0 5326 i72 = ___muldi3(i69, (i69 | 0) < 0 ? -1 : 0, i62, i79) | 0;
michael@0 5327 i79 = _i64Add(i81, i80, i72, tempRet0) | 0;
michael@0 5328 i72 = tempRet0;
michael@0 5329 i80 = 0;
michael@0 5330 i81 = (i78 | 0) < (i80 | 0) | (i78 | 0) == (i80 | 0) & i89 >>> 0 < 0 >>> 0;
michael@0 5331 i80 = _i64Subtract(0, 0, i89, i78) | 0;
michael@0 5332 i62 = i81 ? tempRet0 : i78;
michael@0 5333 i78 = 0;
michael@0 5334 i69 = (i77 | 0) < (i78 | 0) | (i77 | 0) == (i78 | 0) & i96 >>> 0 < 0 >>> 0;
michael@0 5335 if (i69) {
michael@0 5336 i78 = _i64Subtract(0, 0, i96, i77) | 0;
michael@0 5337 i98 = i81 ^ 1;
michael@0 5338 i99 = tempRet0;
michael@0 5339 i100 = i78;
michael@0 5340 } else {
michael@0 5341 i98 = i81;
michael@0 5342 i99 = i77;
michael@0 5343 i100 = i96;
michael@0 5344 }
michael@0 5345 i78 = (i81 ? i80 : i89) | 0;
michael@0 5346 i89 = i62 & 0;
michael@0 5347 i80 = i100 | 0;
michael@0 5348 i71 = i99 & 0;
michael@0 5349 i76 = ___muldi3(i80, i71, i78, i89) | 0;
michael@0 5350 i75 = tempRet0;
michael@0 5351 i74 = i99;
michael@0 5352 i92 = 0;
michael@0 5353 i70 = ___muldi3(i74, i92, i78, i89) | 0;
michael@0 5354 i68 = tempRet0;
michael@0 5355 i94 = i62;
michael@0 5356 i62 = 0;
michael@0 5357 i90 = ___muldi3(i80, i71, i94, i62) | 0;
michael@0 5358 i71 = tempRet0;
michael@0 5359 i80 = ___muldi3(i74, i92, i94, i62) | 0;
michael@0 5360 i92 = tempRet0;
michael@0 5361 i74 = _i64Add(i70 | 0, i68 & 0, i90 | 0, i71 & 0) | 0;
michael@0 5362 i90 = tempRet0;
michael@0 5363 i70 = _i64Add(i68, 0, i80, i92) | 0;
michael@0 5364 i92 = _i64Add(i70, tempRet0, i71, 0) | 0;
michael@0 5365 i71 = tempRet0;
michael@0 5366 i70 = _llvm_uadd_with_overflow_i64(i76 | 0, i75 | 0, 0, i74 | 0) | 0;
michael@0 5367 i74 = i70;
michael@0 5368 i70 = tempRet0;
michael@0 5369 i75 = _i64Add(i92, i71, tempRet1 & 1, 0) | 0;
michael@0 5370 i71 = _i64Add(i75, tempRet0, i90, 0) | 0;
michael@0 5371 i90 = tempRet0;
michael@0 5372 if (i98) {
michael@0 5373 i75 = _i64Subtract(0, 0, i74, i70) | 0;
michael@0 5374 i92 = tempRet0;
michael@0 5375 i76 = _i64Add((i74 | 0) == 0 & (i70 | 0) == 0 & 1, 0, ~i71, ~i90) | 0;
michael@0 5376 i101 = i92;
michael@0 5377 i102 = i75;
michael@0 5378 i103 = tempRet0;
michael@0 5379 i104 = i76;
michael@0 5380 } else {
michael@0 5381 i101 = i70;
michael@0 5382 i102 = i74;
michael@0 5383 i103 = i90;
michael@0 5384 i104 = i71;
michael@0 5385 }
michael@0 5386 i71 = 0;
michael@0 5387 i90 = (i83 | 0) < (i71 | 0) | (i83 | 0) == (i71 | 0) & i97 >>> 0 < 0 >>> 0;
michael@0 5388 i71 = _i64Subtract(0, 0, i97, i83) | 0;
michael@0 5389 i74 = i90 ? tempRet0 : i83;
michael@0 5390 i83 = 0;
michael@0 5391 i70 = (i91 | 0) < (i83 | 0) | (i91 | 0) == (i83 | 0) & i88 >>> 0 < 0 >>> 0;
michael@0 5392 if (i70) {
michael@0 5393 i83 = _i64Subtract(0, 0, i88, i91) | 0;
michael@0 5394 i105 = i90 ^ 1;
michael@0 5395 i106 = tempRet0;
michael@0 5396 i107 = i83;
michael@0 5397 } else {
michael@0 5398 i105 = i90;
michael@0 5399 i106 = i91;
michael@0 5400 i107 = i88;
michael@0 5401 }
michael@0 5402 i83 = (i90 ? i71 : i97) | 0;
michael@0 5403 i97 = i74 & 0;
michael@0 5404 i71 = i107 | 0;
michael@0 5405 i76 = i106 & 0;
michael@0 5406 i75 = ___muldi3(i71, i76, i83, i97) | 0;
michael@0 5407 i92 = tempRet0;
michael@0 5408 i80 = i106;
michael@0 5409 i68 = 0;
michael@0 5410 i87 = ___muldi3(i80, i68, i83, i97) | 0;
michael@0 5411 i93 = tempRet0;
michael@0 5412 i86 = i74;
michael@0 5413 i74 = 0;
michael@0 5414 i84 = ___muldi3(i71, i76, i86, i74) | 0;
michael@0 5415 i76 = tempRet0;
michael@0 5416 i71 = ___muldi3(i80, i68, i86, i74) | 0;
michael@0 5417 i68 = tempRet0;
michael@0 5418 i80 = _i64Add(i87 | 0, i93 & 0, i84 | 0, i76 & 0) | 0;
michael@0 5419 i84 = tempRet0;
michael@0 5420 i87 = _i64Add(i93, 0, i71, i68) | 0;
michael@0 5421 i68 = _i64Add(i87, tempRet0, i76, 0) | 0;
michael@0 5422 i76 = tempRet0;
michael@0 5423 i87 = _llvm_uadd_with_overflow_i64(i75 | 0, i92 | 0, 0, i80 | 0) | 0;
michael@0 5424 i80 = i87;
michael@0 5425 i87 = tempRet0;
michael@0 5426 i92 = _i64Add(i68, i76, tempRet1 & 1, 0) | 0;
michael@0 5427 i76 = _i64Add(i92, tempRet0, i84, 0) | 0;
michael@0 5428 i84 = tempRet0;
michael@0 5429 if (i105) {
michael@0 5430 i92 = _i64Subtract(0, 0, i80, i87) | 0;
michael@0 5431 i68 = tempRet0;
michael@0 5432 i75 = _i64Add((i80 | 0) == 0 & (i87 | 0) == 0 & 1, 0, ~i76, ~i84) | 0;
michael@0 5433 i108 = i68;
michael@0 5434 i109 = i92;
michael@0 5435 i110 = tempRet0;
michael@0 5436 i111 = i75;
michael@0 5437 } else {
michael@0 5438 i108 = i87;
michael@0 5439 i109 = i80;
michael@0 5440 i110 = i84;
michael@0 5441 i111 = i76;
michael@0 5442 }
michael@0 5443 i76 = _i64Subtract(0, 0, i109, i108) | 0;
michael@0 5444 i84 = _llvm_uadd_with_overflow_i64(i102 | 0, i101 | 0, i76 | 0, tempRet0 | 0) | 0;
michael@0 5445 i76 = i84;
michael@0 5446 i84 = tempRet0;
michael@0 5447 i80 = tempRet1 & 1;
michael@0 5448 i87 = _i64Add(i104, i103, ~i111, ~i110) | 0;
michael@0 5449 i75 = _i64Add(i87, tempRet0, (i109 | 0) == 0 & (i108 | 0) == 0 & 1, 0) | 0;
michael@0 5450 i87 = _i64Add(i75, tempRet0, i80, 0) | 0;
michael@0 5451 i80 = tempRet0;
michael@0 5452 i75 = __ZN20btConvexHullInternal4PoolINS_6VertexEE9newObjectEv(i12) | 0;
michael@0 5453 HEAP32[i75 + 100 >> 2] = -1;
michael@0 5454 HEAP32[i75 + 104 >> 2] = -1;
michael@0 5455 i92 = HEAP32[i26 >> 2] | 0;
michael@0 5456 i68 = i92;
michael@0 5457 i71 = (i92 | 0) < 0 ? -1 : 0;
michael@0 5458 i92 = ___muldi3(i68, i71, i73, i67) | 0;
michael@0 5459 i93 = tempRet0;
michael@0 5460 i82 = 0;
michael@0 5461 i85 = (i93 | 0) < (i82 | 0) | (i93 | 0) == (i82 | 0) & i92 >>> 0 < 0 >>> 0;
michael@0 5462 i82 = _i64Subtract(0, 0, i92, i93) | 0;
michael@0 5463 i95 = i85 ? tempRet0 : i93;
michael@0 5464 if (i69) {
michael@0 5465 i93 = _i64Subtract(0, 0, i96, i77) | 0;
michael@0 5466 i112 = i85 ^ 1;
michael@0 5467 i113 = tempRet0;
michael@0 5468 i114 = i93;
michael@0 5469 } else {
michael@0 5470 i112 = i85;
michael@0 5471 i113 = i77;
michael@0 5472 i114 = i96;
michael@0 5473 }
michael@0 5474 i93 = (i85 ? i82 : i92) | 0;
michael@0 5475 i92 = i95 & 0;
michael@0 5476 i82 = i114 | 0;
michael@0 5477 i85 = i113 & 0;
michael@0 5478 i115 = ___muldi3(i82, i85, i93, i92) | 0;
michael@0 5479 i116 = tempRet0;
michael@0 5480 i117 = i113;
michael@0 5481 i118 = 0;
michael@0 5482 i119 = ___muldi3(i117, i118, i93, i92) | 0;
michael@0 5483 i92 = tempRet0;
michael@0 5484 i93 = i95;
michael@0 5485 i95 = 0;
michael@0 5486 i120 = ___muldi3(i82, i85, i93, i95) | 0;
michael@0 5487 i85 = tempRet0;
michael@0 5488 i82 = ___muldi3(i117, i118, i93, i95) | 0;
michael@0 5489 i95 = tempRet0;
michael@0 5490 i93 = _i64Add(i119 | 0, i92 & 0, i120 | 0, i85 & 0) | 0;
michael@0 5491 i120 = tempRet0;
michael@0 5492 i119 = _i64Add(i92, 0, i82, i95) | 0;
michael@0 5493 i95 = _i64Add(i119, tempRet0, i85, 0) | 0;
michael@0 5494 i85 = tempRet0;
michael@0 5495 i119 = _llvm_uadd_with_overflow_i64(i115 | 0, i116 | 0, 0, i93 | 0) | 0;
michael@0 5496 i93 = i119;
michael@0 5497 i119 = tempRet0;
michael@0 5498 i116 = _i64Add(i95, i85, tempRet1 & 1, 0) | 0;
michael@0 5499 i85 = _i64Add(i116, tempRet0, i120, 0) | 0;
michael@0 5500 i120 = tempRet0;
michael@0 5501 if (i112) {
michael@0 5502 i116 = _i64Subtract(0, 0, i93, i119) | 0;
michael@0 5503 i95 = tempRet0;
michael@0 5504 i115 = _i64Add((i93 | 0) == 0 & (i119 | 0) == 0 & 1, 0, ~i85, ~i120) | 0;
michael@0 5505 i121 = i95;
michael@0 5506 i122 = i116;
michael@0 5507 i123 = tempRet0;
michael@0 5508 i124 = i115;
michael@0 5509 } else {
michael@0 5510 i121 = i119;
michael@0 5511 i122 = i93;
michael@0 5512 i123 = i120;
michael@0 5513 i124 = i85;
michael@0 5514 }
michael@0 5515 i85 = ___muldi3(i68, i71, i79, i72) | 0;
michael@0 5516 i71 = tempRet0;
michael@0 5517 i68 = 0;
michael@0 5518 i120 = (i71 | 0) < (i68 | 0) | (i71 | 0) == (i68 | 0) & i85 >>> 0 < 0 >>> 0;
michael@0 5519 i68 = _i64Subtract(0, 0, i85, i71) | 0;
michael@0 5520 i93 = i120 ? tempRet0 : i71;
michael@0 5521 i71 = (i120 ? i68 : i85) | 0;
michael@0 5522 i85 = i93 & 0;
michael@0 5523 i68 = ___muldi3(i71, i85, i83, i97) | 0;
michael@0 5524 i119 = tempRet0;
michael@0 5525 i115 = ___muldi3(i71, i85, i86, i74) | 0;
michael@0 5526 i85 = tempRet0;
michael@0 5527 i71 = i93;
michael@0 5528 i93 = 0;
michael@0 5529 i116 = ___muldi3(i71, i93, i83, i97) | 0;
michael@0 5530 i95 = tempRet0;
michael@0 5531 i82 = ___muldi3(i71, i93, i86, i74) | 0;
michael@0 5532 i93 = tempRet0;
michael@0 5533 i71 = _i64Add(i115 | 0, i85 & 0, i116 | 0, i95 & 0) | 0;
michael@0 5534 i116 = tempRet0;
michael@0 5535 i115 = _llvm_uadd_with_overflow_i64(i68 | 0, i119 | 0, 0, i71 | 0) | 0;
michael@0 5536 i71 = i115;
michael@0 5537 i115 = tempRet0;
michael@0 5538 i119 = tempRet1 & 1;
michael@0 5539 i68 = _i64Add(i85, 0, i82, i93) | 0;
michael@0 5540 i93 = _i64Add(i68, tempRet0, i95, 0) | 0;
michael@0 5541 i95 = _i64Add(i93, tempRet0, i116, 0) | 0;
michael@0 5542 i116 = _i64Add(i95, tempRet0, i119, 0) | 0;
michael@0 5543 i119 = tempRet0;
michael@0 5544 if (i120 ^ i90) {
michael@0 5545 i120 = _i64Subtract(0, 0, i71, i115) | 0;
michael@0 5546 i95 = tempRet0;
michael@0 5547 i93 = _i64Add((i71 | 0) == 0 & (i115 | 0) == 0 & 1, 0, ~i116, ~i119) | 0;
michael@0 5548 i125 = i95;
michael@0 5549 i126 = i120;
michael@0 5550 i127 = tempRet0;
michael@0 5551 i128 = i93;
michael@0 5552 } else {
michael@0 5553 i125 = i115;
michael@0 5554 i126 = i71;
michael@0 5555 i127 = i119;
michael@0 5556 i128 = i116;
michael@0 5557 }
michael@0 5558 i116 = _i64Subtract(0, 0, i126, i125) | 0;
michael@0 5559 i119 = _llvm_uadd_with_overflow_i64(i122 | 0, i121 | 0, i116 | 0, tempRet0 | 0) | 0;
michael@0 5560 i116 = tempRet0;
michael@0 5561 i71 = tempRet1 & 1;
michael@0 5562 i115 = HEAP32[i29 >> 2] | 0;
michael@0 5563 i93 = i115;
michael@0 5564 i120 = (i115 | 0) < 0 ? -1 : 0;
michael@0 5565 i115 = ___muldi3(i93, i120, i79, i72) | 0;
michael@0 5566 i95 = tempRet0;
michael@0 5567 i68 = 0;
michael@0 5568 i82 = (i95 | 0) < (i68 | 0) | (i95 | 0) == (i68 | 0) & i115 >>> 0 < 0 >>> 0;
michael@0 5569 i68 = _i64Subtract(0, 0, i115, i95) | 0;
michael@0 5570 i85 = i82 ? tempRet0 : i95;
michael@0 5571 i95 = (i82 ? i68 : i115) | 0;
michael@0 5572 i115 = i85 & 0;
michael@0 5573 i68 = ___muldi3(i95, i115, i78, i89) | 0;
michael@0 5574 i92 = tempRet0;
michael@0 5575 i118 = ___muldi3(i95, i115, i94, i62) | 0;
michael@0 5576 i115 = tempRet0;
michael@0 5577 i95 = i85;
michael@0 5578 i85 = 0;
michael@0 5579 i117 = ___muldi3(i95, i85, i78, i89) | 0;
michael@0 5580 i129 = tempRet0;
michael@0 5581 i130 = ___muldi3(i95, i85, i94, i62) | 0;
michael@0 5582 i85 = tempRet0;
michael@0 5583 i95 = _i64Add(i118 | 0, i115 & 0, i117 | 0, i129 & 0) | 0;
michael@0 5584 i117 = tempRet0;
michael@0 5585 i118 = _llvm_uadd_with_overflow_i64(i68 | 0, i92 | 0, 0, i95 | 0) | 0;
michael@0 5586 i95 = i118;
michael@0 5587 i118 = tempRet0;
michael@0 5588 i92 = _i64Add(i130, i85, tempRet1 & 1, 0) | 0;
michael@0 5589 i85 = _i64Add(i92, tempRet0, i115, 0) | 0;
michael@0 5590 i115 = _i64Add(i85, tempRet0, i129, 0) | 0;
michael@0 5591 i129 = _i64Add(i115, tempRet0, i117, 0) | 0;
michael@0 5592 i117 = tempRet0;
michael@0 5593 if (i82 ^ i81) {
michael@0 5594 i82 = _i64Subtract(0, 0, i95, i118) | 0;
michael@0 5595 i115 = tempRet0;
michael@0 5596 i85 = _i64Add((i95 | 0) == 0 & (i118 | 0) == 0 & 1, 0, ~i129, ~i117) | 0;
michael@0 5597 i131 = i115;
michael@0 5598 i132 = i82;
michael@0 5599 i133 = tempRet0;
michael@0 5600 i134 = i85;
michael@0 5601 } else {
michael@0 5602 i131 = i118;
michael@0 5603 i132 = i95;
michael@0 5604 i133 = i117;
michael@0 5605 i134 = i129;
michael@0 5606 }
michael@0 5607 i129 = _llvm_uadd_with_overflow_i64(i119 | 0, i116 | 0, i132 | 0, i131 | 0) | 0;
michael@0 5608 i116 = tempRet0;
michael@0 5609 i119 = tempRet1 & 1;
michael@0 5610 i117 = ___muldi3(i93, i120, i73, i67) | 0;
michael@0 5611 i120 = tempRet0;
michael@0 5612 i93 = 0;
michael@0 5613 i95 = (i120 | 0) < (i93 | 0) | (i120 | 0) == (i93 | 0) & i117 >>> 0 < 0 >>> 0;
michael@0 5614 i93 = _i64Subtract(0, 0, i117, i120) | 0;
michael@0 5615 i118 = i95 ? tempRet0 : i120;
michael@0 5616 if (i70) {
michael@0 5617 i120 = _i64Subtract(0, 0, i88, i91) | 0;
michael@0 5618 i135 = i95 ^ 1;
michael@0 5619 i136 = tempRet0;
michael@0 5620 i137 = i120;
michael@0 5621 } else {
michael@0 5622 i135 = i95;
michael@0 5623 i136 = i91;
michael@0 5624 i137 = i88;
michael@0 5625 }
michael@0 5626 i120 = (i95 ? i93 : i117) | 0;
michael@0 5627 i117 = i118 & 0;
michael@0 5628 i93 = i137 | 0;
michael@0 5629 i95 = i136 & 0;
michael@0 5630 i85 = ___muldi3(i93, i95, i120, i117) | 0;
michael@0 5631 i82 = tempRet0;
michael@0 5632 i115 = i136;
michael@0 5633 i92 = 0;
michael@0 5634 i130 = ___muldi3(i115, i92, i120, i117) | 0;
michael@0 5635 i117 = tempRet0;
michael@0 5636 i120 = i118;
michael@0 5637 i118 = 0;
michael@0 5638 i68 = ___muldi3(i93, i95, i120, i118) | 0;
michael@0 5639 i95 = tempRet0;
michael@0 5640 i93 = ___muldi3(i115, i92, i120, i118) | 0;
michael@0 5641 i118 = tempRet0;
michael@0 5642 i120 = _i64Add(i130 | 0, i117 & 0, i68 | 0, i95 & 0) | 0;
michael@0 5643 i68 = tempRet0;
michael@0 5644 i130 = _i64Add(i117, 0, i93, i118) | 0;
michael@0 5645 i118 = _i64Add(i130, tempRet0, i95, 0) | 0;
michael@0 5646 i95 = tempRet0;
michael@0 5647 i130 = _llvm_uadd_with_overflow_i64(i85 | 0, i82 | 0, 0, i120 | 0) | 0;
michael@0 5648 i120 = i130;
michael@0 5649 i130 = tempRet0;
michael@0 5650 i82 = _i64Add(i118, i95, tempRet1 & 1, 0) | 0;
michael@0 5651 i95 = _i64Add(i82, tempRet0, i68, 0) | 0;
michael@0 5652 i68 = tempRet0;
michael@0 5653 if (i135) {
michael@0 5654 i82 = _i64Subtract(0, 0, i120, i130) | 0;
michael@0 5655 i118 = tempRet0;
michael@0 5656 i85 = _i64Add((i120 | 0) == 0 & (i130 | 0) == 0 & 1, 0, ~i95, ~i68) | 0;
michael@0 5657 i138 = i118;
michael@0 5658 i139 = i82;
michael@0 5659 i140 = tempRet0;
michael@0 5660 i141 = i85;
michael@0 5661 } else {
michael@0 5662 i138 = i130;
michael@0 5663 i139 = i120;
michael@0 5664 i140 = i68;
michael@0 5665 i141 = i95;
michael@0 5666 }
michael@0 5667 i95 = _i64Subtract(0, 0, i139, i138) | 0;
michael@0 5668 i68 = _llvm_uadd_with_overflow_i64(i129 | 0, i116 | 0, i95 | 0, tempRet0 | 0) | 0;
michael@0 5669 i95 = tempRet0;
michael@0 5670 i116 = tempRet1 & 1;
michael@0 5671 i129 = 0;
michael@0 5672 i120 = (i80 | 0) < (i129 | 0) | (i80 | 0) == (i129 | 0) & i87 >>> 0 < 0 >>> 0;
michael@0 5673 if (i120) {
michael@0 5674 i129 = _i64Subtract(0, 0, i76, i84) | 0;
michael@0 5675 i130 = tempRet0;
michael@0 5676 i85 = _i64Add((i76 | 0) == 0 & (i84 | 0) == 0 & 1, 0, ~i87, ~i80) | 0;
michael@0 5677 i142 = i130;
michael@0 5678 i143 = i129;
michael@0 5679 i144 = tempRet0;
michael@0 5680 i145 = i85;
michael@0 5681 } else {
michael@0 5682 i142 = i84;
michael@0 5683 i143 = i76;
michael@0 5684 i144 = i80;
michael@0 5685 i145 = i87;
michael@0 5686 }
michael@0 5687 i85 = i45 ? i47 : i7;
michael@0 5688 i129 = i45 ? i46 : i38;
michael@0 5689 i130 = i143 | 0;
michael@0 5690 i82 = i142 & 0;
michael@0 5691 i118 = i85 | 0;
michael@0 5692 i93 = i129 & 0;
michael@0 5693 i117 = ___muldi3(i118, i93, i130, i82) | 0;
michael@0 5694 i92 = tempRet0;
michael@0 5695 i115 = i129;
michael@0 5696 i146 = 0;
michael@0 5697 i147 = ___muldi3(i115, i146, i130, i82) | 0;
michael@0 5698 i82 = tempRet0;
michael@0 5699 i130 = i142;
michael@0 5700 i148 = 0;
michael@0 5701 i149 = ___muldi3(i118, i93, i130, i148) | 0;
michael@0 5702 i93 = tempRet0;
michael@0 5703 i118 = ___muldi3(i115, i146, i130, i148) | 0;
michael@0 5704 i148 = tempRet0;
michael@0 5705 i130 = _i64Add(i147 | 0, i82 & 0, i149 | 0, i93 & 0) | 0;
michael@0 5706 i149 = tempRet0;
michael@0 5707 i147 = _llvm_uadd_with_overflow_i64(i117 | 0, i92 | 0, 0, i130 | 0) | 0;
michael@0 5708 i130 = i147;
michael@0 5709 i147 = tempRet0;
michael@0 5710 i92 = tempRet1 & 1;
michael@0 5711 i117 = ___muldi3(i85, i129, i145, i144) | 0;
michael@0 5712 i129 = _i64Add(i118, i148, i117, tempRet0) | 0;
michael@0 5713 i117 = _i64Add(i129, tempRet0, i82, 0) | 0;
michael@0 5714 i82 = _i64Add(i117, tempRet0, i93, 0) | 0;
michael@0 5715 i93 = _i64Add(i82, tempRet0, i92, 0) | 0;
michael@0 5716 i92 = _i64Add(i93, tempRet0, i149, 0) | 0;
michael@0 5717 i149 = tempRet0;
michael@0 5718 if (i120 ^ i45) {
michael@0 5719 i93 = _i64Subtract(0, 0, i130, i147) | 0;
michael@0 5720 i82 = tempRet0;
michael@0 5721 i117 = _i64Add((i130 | 0) == 0 & (i147 | 0) == 0 & 1, 0, ~i92, ~i149) | 0;
michael@0 5722 i150 = i82;
michael@0 5723 i151 = i93;
michael@0 5724 i152 = tempRet0;
michael@0 5725 i153 = i117;
michael@0 5726 } else {
michael@0 5727 i150 = i147;
michael@0 5728 i151 = i130;
michael@0 5729 i152 = i149;
michael@0 5730 i153 = i92;
michael@0 5731 }
michael@0 5732 i92 = _llvm_uadd_with_overflow_i64(i68 | 0, i95 | 0, i151 | 0, i150 | 0) | 0;
michael@0 5733 i95 = tempRet0;
michael@0 5734 i68 = tempRet1 & 1;
michael@0 5735 i149 = _i64Add(i124, i123, ~i128, ~i127) | 0;
michael@0 5736 i130 = _i64Add(i149, tempRet0, (i126 | 0) == 0 & (i125 | 0) == 0 & 1, 0) | 0;
michael@0 5737 i149 = _i64Add(i130, tempRet0, i71, 0) | 0;
michael@0 5738 i71 = _i64Add(i149, tempRet0, i134, i133) | 0;
michael@0 5739 i149 = _i64Add(i71, tempRet0, i119, 0) | 0;
michael@0 5740 i119 = _i64Add(i149, tempRet0, ~i141, ~i140) | 0;
michael@0 5741 i149 = _i64Add(i119, tempRet0, (i139 | 0) == 0 & (i138 | 0) == 0 & 1, 0) | 0;
michael@0 5742 i119 = _i64Add(i149, tempRet0, i116, 0) | 0;
michael@0 5743 i116 = _i64Add(i119, tempRet0, i153, i152) | 0;
michael@0 5744 i119 = _i64Add(i116, tempRet0, i68, 0) | 0;
michael@0 5745 i68 = tempRet0;
michael@0 5746 i116 = HEAP32[i6 >> 2] | 0;
michael@0 5747 i149 = i116;
michael@0 5748 i71 = (i116 | 0) < 0 ? -1 : 0;
michael@0 5749 i116 = ___muldi3(i149, i71, i73, i67) | 0;
michael@0 5750 i130 = tempRet0;
michael@0 5751 i147 = 0;
michael@0 5752 i117 = (i130 | 0) < (i147 | 0) | (i130 | 0) == (i147 | 0) & i116 >>> 0 < 0 >>> 0;
michael@0 5753 i147 = _i64Subtract(0, 0, i116, i130) | 0;
michael@0 5754 i93 = i117 ? tempRet0 : i130;
michael@0 5755 if (i69) {
michael@0 5756 i130 = _i64Subtract(0, 0, i96, i77) | 0;
michael@0 5757 i154 = i117 ^ 1;
michael@0 5758 i155 = tempRet0;
michael@0 5759 i156 = i130;
michael@0 5760 } else {
michael@0 5761 i154 = i117;
michael@0 5762 i155 = i77;
michael@0 5763 i156 = i96;
michael@0 5764 }
michael@0 5765 i130 = (i117 ? i147 : i116) | 0;
michael@0 5766 i116 = i93 & 0;
michael@0 5767 i147 = i156 | 0;
michael@0 5768 i117 = i155 & 0;
michael@0 5769 i82 = ___muldi3(i147, i117, i130, i116) | 0;
michael@0 5770 i129 = tempRet0;
michael@0 5771 i148 = i155;
michael@0 5772 i118 = 0;
michael@0 5773 i85 = ___muldi3(i148, i118, i130, i116) | 0;
michael@0 5774 i116 = tempRet0;
michael@0 5775 i130 = i93;
michael@0 5776 i93 = 0;
michael@0 5777 i146 = ___muldi3(i147, i117, i130, i93) | 0;
michael@0 5778 i117 = tempRet0;
michael@0 5779 i147 = ___muldi3(i148, i118, i130, i93) | 0;
michael@0 5780 i93 = tempRet0;
michael@0 5781 i130 = _i64Add(i85 | 0, i116 & 0, i146 | 0, i117 & 0) | 0;
michael@0 5782 i146 = tempRet0;
michael@0 5783 i85 = _i64Add(i116, 0, i147, i93) | 0;
michael@0 5784 i93 = _i64Add(i85, tempRet0, i117, 0) | 0;
michael@0 5785 i117 = tempRet0;
michael@0 5786 i85 = _llvm_uadd_with_overflow_i64(i82 | 0, i129 | 0, 0, i130 | 0) | 0;
michael@0 5787 i130 = i85;
michael@0 5788 i85 = tempRet0;
michael@0 5789 i129 = _i64Add(i93, i117, tempRet1 & 1, 0) | 0;
michael@0 5790 i117 = _i64Add(i129, tempRet0, i146, 0) | 0;
michael@0 5791 i146 = tempRet0;
michael@0 5792 if (i154) {
michael@0 5793 i129 = _i64Subtract(0, 0, i130, i85) | 0;
michael@0 5794 i93 = tempRet0;
michael@0 5795 i82 = _i64Add((i130 | 0) == 0 & (i85 | 0) == 0 & 1, 0, ~i117, ~i146) | 0;
michael@0 5796 i157 = i93;
michael@0 5797 i158 = i129;
michael@0 5798 i159 = tempRet0;
michael@0 5799 i160 = i82;
michael@0 5800 } else {
michael@0 5801 i157 = i85;
michael@0 5802 i158 = i130;
michael@0 5803 i159 = i146;
michael@0 5804 i160 = i117;
michael@0 5805 }
michael@0 5806 i117 = ___muldi3(i149, i71, i79, i72) | 0;
michael@0 5807 i71 = tempRet0;
michael@0 5808 i149 = 0;
michael@0 5809 i146 = (i71 | 0) < (i149 | 0) | (i71 | 0) == (i149 | 0) & i117 >>> 0 < 0 >>> 0;
michael@0 5810 i149 = _i64Subtract(0, 0, i117, i71) | 0;
michael@0 5811 i130 = i146 ? tempRet0 : i71;
michael@0 5812 i71 = (i146 ? i149 : i117) | 0;
michael@0 5813 i117 = i130 & 0;
michael@0 5814 i149 = ___muldi3(i71, i117, i83, i97) | 0;
michael@0 5815 i85 = tempRet0;
michael@0 5816 i82 = ___muldi3(i71, i117, i86, i74) | 0;
michael@0 5817 i117 = tempRet0;
michael@0 5818 i71 = i130;
michael@0 5819 i130 = 0;
michael@0 5820 i129 = ___muldi3(i71, i130, i83, i97) | 0;
michael@0 5821 i93 = tempRet0;
michael@0 5822 i147 = ___muldi3(i71, i130, i86, i74) | 0;
michael@0 5823 i130 = tempRet0;
michael@0 5824 i71 = _i64Add(i82 | 0, i117 & 0, i129 | 0, i93 & 0) | 0;
michael@0 5825 i129 = tempRet0;
michael@0 5826 i82 = _llvm_uadd_with_overflow_i64(i149 | 0, i85 | 0, 0, i71 | 0) | 0;
michael@0 5827 i71 = i82;
michael@0 5828 i82 = tempRet0;
michael@0 5829 i85 = tempRet1 & 1;
michael@0 5830 i149 = _i64Add(i117, 0, i147, i130) | 0;
michael@0 5831 i130 = _i64Add(i149, tempRet0, i93, 0) | 0;
michael@0 5832 i93 = _i64Add(i130, tempRet0, i129, 0) | 0;
michael@0 5833 i129 = _i64Add(i93, tempRet0, i85, 0) | 0;
michael@0 5834 i85 = tempRet0;
michael@0 5835 if (i146 ^ i90) {
michael@0 5836 i146 = _i64Subtract(0, 0, i71, i82) | 0;
michael@0 5837 i93 = tempRet0;
michael@0 5838 i130 = _i64Add((i71 | 0) == 0 & (i82 | 0) == 0 & 1, 0, ~i129, ~i85) | 0;
michael@0 5839 i161 = i93;
michael@0 5840 i162 = i146;
michael@0 5841 i163 = tempRet0;
michael@0 5842 i164 = i130;
michael@0 5843 } else {
michael@0 5844 i161 = i82;
michael@0 5845 i162 = i71;
michael@0 5846 i163 = i85;
michael@0 5847 i164 = i129;
michael@0 5848 }
michael@0 5849 i129 = _i64Subtract(0, 0, i162, i161) | 0;
michael@0 5850 i85 = _llvm_uadd_with_overflow_i64(i158 | 0, i157 | 0, i129 | 0, tempRet0 | 0) | 0;
michael@0 5851 i129 = tempRet0;
michael@0 5852 i71 = tempRet1 & 1;
michael@0 5853 i82 = HEAP32[i27 >> 2] | 0;
michael@0 5854 i130 = i82;
michael@0 5855 i146 = (i82 | 0) < 0 ? -1 : 0;
michael@0 5856 i82 = ___muldi3(i130, i146, i79, i72) | 0;
michael@0 5857 i93 = tempRet0;
michael@0 5858 i149 = 0;
michael@0 5859 i147 = (i93 | 0) < (i149 | 0) | (i93 | 0) == (i149 | 0) & i82 >>> 0 < 0 >>> 0;
michael@0 5860 i149 = _i64Subtract(0, 0, i82, i93) | 0;
michael@0 5861 i117 = i147 ? tempRet0 : i93;
michael@0 5862 i93 = (i147 ? i149 : i82) | 0;
michael@0 5863 i82 = i117 & 0;
michael@0 5864 i149 = ___muldi3(i93, i82, i78, i89) | 0;
michael@0 5865 i116 = tempRet0;
michael@0 5866 i118 = ___muldi3(i93, i82, i94, i62) | 0;
michael@0 5867 i82 = tempRet0;
michael@0 5868 i93 = i117;
michael@0 5869 i117 = 0;
michael@0 5870 i148 = ___muldi3(i93, i117, i78, i89) | 0;
michael@0 5871 i115 = tempRet0;
michael@0 5872 i165 = ___muldi3(i93, i117, i94, i62) | 0;
michael@0 5873 i117 = tempRet0;
michael@0 5874 i93 = _i64Add(i118 | 0, i82 & 0, i148 | 0, i115 & 0) | 0;
michael@0 5875 i148 = tempRet0;
michael@0 5876 i118 = _llvm_uadd_with_overflow_i64(i149 | 0, i116 | 0, 0, i93 | 0) | 0;
michael@0 5877 i93 = i118;
michael@0 5878 i118 = tempRet0;
michael@0 5879 i116 = _i64Add(i165, i117, tempRet1 & 1, 0) | 0;
michael@0 5880 i117 = _i64Add(i116, tempRet0, i82, 0) | 0;
michael@0 5881 i82 = _i64Add(i117, tempRet0, i115, 0) | 0;
michael@0 5882 i115 = _i64Add(i82, tempRet0, i148, 0) | 0;
michael@0 5883 i148 = tempRet0;
michael@0 5884 if (i147 ^ i81) {
michael@0 5885 i147 = _i64Subtract(0, 0, i93, i118) | 0;
michael@0 5886 i82 = tempRet0;
michael@0 5887 i117 = _i64Add((i93 | 0) == 0 & (i118 | 0) == 0 & 1, 0, ~i115, ~i148) | 0;
michael@0 5888 i166 = i82;
michael@0 5889 i167 = i147;
michael@0 5890 i168 = tempRet0;
michael@0 5891 i169 = i117;
michael@0 5892 } else {
michael@0 5893 i166 = i118;
michael@0 5894 i167 = i93;
michael@0 5895 i168 = i148;
michael@0 5896 i169 = i115;
michael@0 5897 }
michael@0 5898 i115 = _llvm_uadd_with_overflow_i64(i85 | 0, i129 | 0, i167 | 0, i166 | 0) | 0;
michael@0 5899 i129 = tempRet0;
michael@0 5900 i85 = tempRet1 & 1;
michael@0 5901 i148 = ___muldi3(i130, i146, i73, i67) | 0;
michael@0 5902 i146 = tempRet0;
michael@0 5903 i130 = 0;
michael@0 5904 i93 = (i146 | 0) < (i130 | 0) | (i146 | 0) == (i130 | 0) & i148 >>> 0 < 0 >>> 0;
michael@0 5905 i130 = _i64Subtract(0, 0, i148, i146) | 0;
michael@0 5906 i118 = i93 ? tempRet0 : i146;
michael@0 5907 if (i70) {
michael@0 5908 i146 = _i64Subtract(0, 0, i88, i91) | 0;
michael@0 5909 i170 = i93 ^ 1;
michael@0 5910 i171 = tempRet0;
michael@0 5911 i172 = i146;
michael@0 5912 } else {
michael@0 5913 i170 = i93;
michael@0 5914 i171 = i91;
michael@0 5915 i172 = i88;
michael@0 5916 }
michael@0 5917 i146 = (i93 ? i130 : i148) | 0;
michael@0 5918 i148 = i118 & 0;
michael@0 5919 i130 = i172 | 0;
michael@0 5920 i93 = i171 & 0;
michael@0 5921 i117 = ___muldi3(i130, i93, i146, i148) | 0;
michael@0 5922 i147 = tempRet0;
michael@0 5923 i82 = i171;
michael@0 5924 i116 = 0;
michael@0 5925 i165 = ___muldi3(i82, i116, i146, i148) | 0;
michael@0 5926 i148 = tempRet0;
michael@0 5927 i146 = i118;
michael@0 5928 i118 = 0;
michael@0 5929 i149 = ___muldi3(i130, i93, i146, i118) | 0;
michael@0 5930 i93 = tempRet0;
michael@0 5931 i130 = ___muldi3(i82, i116, i146, i118) | 0;
michael@0 5932 i118 = tempRet0;
michael@0 5933 i146 = _i64Add(i165 | 0, i148 & 0, i149 | 0, i93 & 0) | 0;
michael@0 5934 i149 = tempRet0;
michael@0 5935 i165 = _i64Add(i148, 0, i130, i118) | 0;
michael@0 5936 i118 = _i64Add(i165, tempRet0, i93, 0) | 0;
michael@0 5937 i93 = tempRet0;
michael@0 5938 i165 = _llvm_uadd_with_overflow_i64(i117 | 0, i147 | 0, 0, i146 | 0) | 0;
michael@0 5939 i146 = i165;
michael@0 5940 i165 = tempRet0;
michael@0 5941 i147 = _i64Add(i118, i93, tempRet1 & 1, 0) | 0;
michael@0 5942 i93 = _i64Add(i147, tempRet0, i149, 0) | 0;
michael@0 5943 i149 = tempRet0;
michael@0 5944 if (i170) {
michael@0 5945 i147 = _i64Subtract(0, 0, i146, i165) | 0;
michael@0 5946 i118 = tempRet0;
michael@0 5947 i117 = _i64Add((i146 | 0) == 0 & (i165 | 0) == 0 & 1, 0, ~i93, ~i149) | 0;
michael@0 5948 i173 = i118;
michael@0 5949 i174 = i147;
michael@0 5950 i175 = tempRet0;
michael@0 5951 i176 = i117;
michael@0 5952 } else {
michael@0 5953 i173 = i165;
michael@0 5954 i174 = i146;
michael@0 5955 i175 = i149;
michael@0 5956 i176 = i93;
michael@0 5957 }
michael@0 5958 i93 = _i64Subtract(0, 0, i174, i173) | 0;
michael@0 5959 i149 = _llvm_uadd_with_overflow_i64(i115 | 0, i129 | 0, i93 | 0, tempRet0 | 0) | 0;
michael@0 5960 i93 = tempRet0;
michael@0 5961 i129 = tempRet1 & 1;
michael@0 5962 if (i120) {
michael@0 5963 i115 = _i64Subtract(0, 0, i76, i84) | 0;
michael@0 5964 i146 = tempRet0;
michael@0 5965 i165 = _i64Add((i76 | 0) == 0 & (i84 | 0) == 0 & 1, 0, ~i87, ~i80) | 0;
michael@0 5966 i177 = i146;
michael@0 5967 i178 = i115;
michael@0 5968 i179 = tempRet0;
michael@0 5969 i180 = i165;
michael@0 5970 } else {
michael@0 5971 i177 = i84;
michael@0 5972 i178 = i76;
michael@0 5973 i179 = i80;
michael@0 5974 i180 = i87;
michael@0 5975 }
michael@0 5976 i165 = i48 ? i10 : i24;
michael@0 5977 i115 = i48 ? i41 : i34;
michael@0 5978 i146 = i178 | 0;
michael@0 5979 i117 = i177 & 0;
michael@0 5980 i147 = i165 | 0;
michael@0 5981 i118 = i115 & 0;
michael@0 5982 i130 = ___muldi3(i147, i118, i146, i117) | 0;
michael@0 5983 i148 = tempRet0;
michael@0 5984 i116 = i115;
michael@0 5985 i82 = 0;
michael@0 5986 i181 = ___muldi3(i116, i82, i146, i117) | 0;
michael@0 5987 i117 = tempRet0;
michael@0 5988 i146 = i177;
michael@0 5989 i182 = 0;
michael@0 5990 i183 = ___muldi3(i147, i118, i146, i182) | 0;
michael@0 5991 i118 = tempRet0;
michael@0 5992 i147 = ___muldi3(i116, i82, i146, i182) | 0;
michael@0 5993 i182 = tempRet0;
michael@0 5994 i146 = _i64Add(i181 | 0, i117 & 0, i183 | 0, i118 & 0) | 0;
michael@0 5995 i183 = tempRet0;
michael@0 5996 i181 = _llvm_uadd_with_overflow_i64(i130 | 0, i148 | 0, 0, i146 | 0) | 0;
michael@0 5997 i146 = i181;
michael@0 5998 i181 = tempRet0;
michael@0 5999 i148 = tempRet1 & 1;
michael@0 6000 i130 = ___muldi3(i165, i115, i180, i179) | 0;
michael@0 6001 i115 = _i64Add(i147, i182, i130, tempRet0) | 0;
michael@0 6002 i130 = _i64Add(i115, tempRet0, i117, 0) | 0;
michael@0 6003 i117 = _i64Add(i130, tempRet0, i118, 0) | 0;
michael@0 6004 i118 = _i64Add(i117, tempRet0, i148, 0) | 0;
michael@0 6005 i148 = _i64Add(i118, tempRet0, i183, 0) | 0;
michael@0 6006 i183 = tempRet0;
michael@0 6007 if (i120 ^ i48) {
michael@0 6008 i118 = _i64Subtract(0, 0, i146, i181) | 0;
michael@0 6009 i117 = tempRet0;
michael@0 6010 i130 = _i64Add((i146 | 0) == 0 & (i181 | 0) == 0 & 1, 0, ~i148, ~i183) | 0;
michael@0 6011 i184 = i117;
michael@0 6012 i185 = i118;
michael@0 6013 i186 = tempRet0;
michael@0 6014 i187 = i130;
michael@0 6015 } else {
michael@0 6016 i184 = i181;
michael@0 6017 i185 = i146;
michael@0 6018 i186 = i183;
michael@0 6019 i187 = i148;
michael@0 6020 }
michael@0 6021 i148 = _llvm_uadd_with_overflow_i64(i149 | 0, i93 | 0, i185 | 0, i184 | 0) | 0;
michael@0 6022 i93 = tempRet0;
michael@0 6023 i149 = tempRet1 & 1;
michael@0 6024 i183 = _i64Add(i160, i159, ~i164, ~i163) | 0;
michael@0 6025 i146 = _i64Add(i183, tempRet0, (i162 | 0) == 0 & (i161 | 0) == 0 & 1, 0) | 0;
michael@0 6026 i183 = _i64Add(i146, tempRet0, i71, 0) | 0;
michael@0 6027 i71 = _i64Add(i183, tempRet0, i169, i168) | 0;
michael@0 6028 i183 = _i64Add(i71, tempRet0, i85, 0) | 0;
michael@0 6029 i85 = _i64Add(i183, tempRet0, ~i176, ~i175) | 0;
michael@0 6030 i183 = _i64Add(i85, tempRet0, (i174 | 0) == 0 & (i173 | 0) == 0 & 1, 0) | 0;
michael@0 6031 i85 = _i64Add(i183, tempRet0, i129, 0) | 0;
michael@0 6032 i129 = _i64Add(i85, tempRet0, i187, i186) | 0;
michael@0 6033 i85 = _i64Add(i129, tempRet0, i149, 0) | 0;
michael@0 6034 i149 = tempRet0;
michael@0 6035 i129 = HEAP32[i25 >> 2] | 0;
michael@0 6036 i183 = i129;
michael@0 6037 i71 = (i129 | 0) < 0 ? -1 : 0;
michael@0 6038 i129 = ___muldi3(i183, i71, i73, i67) | 0;
michael@0 6039 i146 = tempRet0;
michael@0 6040 i181 = 0;
michael@0 6041 i130 = (i146 | 0) < (i181 | 0) | (i146 | 0) == (i181 | 0) & i129 >>> 0 < 0 >>> 0;
michael@0 6042 i181 = _i64Subtract(0, 0, i129, i146) | 0;
michael@0 6043 i118 = i130 ? tempRet0 : i146;
michael@0 6044 if (i69) {
michael@0 6045 i69 = _i64Subtract(0, 0, i96, i77) | 0;
michael@0 6046 i188 = i130 ^ 1;
michael@0 6047 i189 = tempRet0;
michael@0 6048 i190 = i69;
michael@0 6049 } else {
michael@0 6050 i188 = i130;
michael@0 6051 i189 = i77;
michael@0 6052 i190 = i96;
michael@0 6053 }
michael@0 6054 i96 = (i130 ? i181 : i129) | 0;
michael@0 6055 i129 = i118 & 0;
michael@0 6056 i181 = i190 | 0;
michael@0 6057 i130 = i189 & 0;
michael@0 6058 i77 = ___muldi3(i181, i130, i96, i129) | 0;
michael@0 6059 i69 = tempRet0;
michael@0 6060 i146 = i189;
michael@0 6061 i117 = 0;
michael@0 6062 i115 = ___muldi3(i146, i117, i96, i129) | 0;
michael@0 6063 i129 = tempRet0;
michael@0 6064 i96 = i118;
michael@0 6065 i118 = 0;
michael@0 6066 i182 = ___muldi3(i181, i130, i96, i118) | 0;
michael@0 6067 i130 = tempRet0;
michael@0 6068 i181 = ___muldi3(i146, i117, i96, i118) | 0;
michael@0 6069 i118 = tempRet0;
michael@0 6070 i96 = _i64Add(i115 | 0, i129 & 0, i182 | 0, i130 & 0) | 0;
michael@0 6071 i182 = tempRet0;
michael@0 6072 i115 = _i64Add(i129, 0, i181, i118) | 0;
michael@0 6073 i118 = _i64Add(i115, tempRet0, i130, 0) | 0;
michael@0 6074 i130 = tempRet0;
michael@0 6075 i115 = _llvm_uadd_with_overflow_i64(i77 | 0, i69 | 0, 0, i96 | 0) | 0;
michael@0 6076 i96 = i115;
michael@0 6077 i115 = tempRet0;
michael@0 6078 i69 = _i64Add(i118, i130, tempRet1 & 1, 0) | 0;
michael@0 6079 i130 = _i64Add(i69, tempRet0, i182, 0) | 0;
michael@0 6080 i182 = tempRet0;
michael@0 6081 if (i188) {
michael@0 6082 i69 = _i64Subtract(0, 0, i96, i115) | 0;
michael@0 6083 i118 = tempRet0;
michael@0 6084 i77 = _i64Add((i96 | 0) == 0 & (i115 | 0) == 0 & 1, 0, ~i130, ~i182) | 0;
michael@0 6085 i191 = i118;
michael@0 6086 i192 = i69;
michael@0 6087 i193 = tempRet0;
michael@0 6088 i194 = i77;
michael@0 6089 } else {
michael@0 6090 i191 = i115;
michael@0 6091 i192 = i96;
michael@0 6092 i193 = i182;
michael@0 6093 i194 = i130;
michael@0 6094 }
michael@0 6095 i130 = ___muldi3(i183, i71, i79, i72) | 0;
michael@0 6096 i71 = tempRet0;
michael@0 6097 i183 = 0;
michael@0 6098 i182 = (i71 | 0) < (i183 | 0) | (i71 | 0) == (i183 | 0) & i130 >>> 0 < 0 >>> 0;
michael@0 6099 i183 = _i64Subtract(0, 0, i130, i71) | 0;
michael@0 6100 i96 = i182 ? tempRet0 : i71;
michael@0 6101 i71 = (i182 ? i183 : i130) | 0;
michael@0 6102 i130 = i96 & 0;
michael@0 6103 i183 = ___muldi3(i71, i130, i83, i97) | 0;
michael@0 6104 i115 = tempRet0;
michael@0 6105 i77 = ___muldi3(i71, i130, i86, i74) | 0;
michael@0 6106 i130 = tempRet0;
michael@0 6107 i71 = i96;
michael@0 6108 i96 = 0;
michael@0 6109 i69 = ___muldi3(i71, i96, i83, i97) | 0;
michael@0 6110 i97 = tempRet0;
michael@0 6111 i83 = ___muldi3(i71, i96, i86, i74) | 0;
michael@0 6112 i74 = tempRet0;
michael@0 6113 i86 = _i64Add(i77 | 0, i130 & 0, i69 | 0, i97 & 0) | 0;
michael@0 6114 i69 = tempRet0;
michael@0 6115 i77 = _llvm_uadd_with_overflow_i64(i183 | 0, i115 | 0, 0, i86 | 0) | 0;
michael@0 6116 i86 = i77;
michael@0 6117 i77 = tempRet0;
michael@0 6118 i115 = tempRet1 & 1;
michael@0 6119 i183 = _i64Add(i130, 0, i83, i74) | 0;
michael@0 6120 i74 = _i64Add(i183, tempRet0, i97, 0) | 0;
michael@0 6121 i97 = _i64Add(i74, tempRet0, i69, 0) | 0;
michael@0 6122 i69 = _i64Add(i97, tempRet0, i115, 0) | 0;
michael@0 6123 i115 = tempRet0;
michael@0 6124 if (i182 ^ i90) {
michael@0 6125 i90 = _i64Subtract(0, 0, i86, i77) | 0;
michael@0 6126 i182 = tempRet0;
michael@0 6127 i97 = _i64Add((i86 | 0) == 0 & (i77 | 0) == 0 & 1, 0, ~i69, ~i115) | 0;
michael@0 6128 i195 = i182;
michael@0 6129 i196 = i90;
michael@0 6130 i197 = tempRet0;
michael@0 6131 i198 = i97;
michael@0 6132 } else {
michael@0 6133 i195 = i77;
michael@0 6134 i196 = i86;
michael@0 6135 i197 = i115;
michael@0 6136 i198 = i69;
michael@0 6137 }
michael@0 6138 i69 = _i64Subtract(0, 0, i196, i195) | 0;
michael@0 6139 i115 = _llvm_uadd_with_overflow_i64(i192 | 0, i191 | 0, i69 | 0, tempRet0 | 0) | 0;
michael@0 6140 i69 = tempRet0;
michael@0 6141 i86 = tempRet1 & 1;
michael@0 6142 i77 = HEAP32[i22 >> 2] | 0;
michael@0 6143 i97 = i77;
michael@0 6144 i90 = (i77 | 0) < 0 ? -1 : 0;
michael@0 6145 i77 = ___muldi3(i97, i90, i79, i72) | 0;
michael@0 6146 i72 = tempRet0;
michael@0 6147 i79 = 0;
michael@0 6148 i182 = (i72 | 0) < (i79 | 0) | (i72 | 0) == (i79 | 0) & i77 >>> 0 < 0 >>> 0;
michael@0 6149 i79 = _i64Subtract(0, 0, i77, i72) | 0;
michael@0 6150 i74 = i182 ? tempRet0 : i72;
michael@0 6151 i72 = (i182 ? i79 : i77) | 0;
michael@0 6152 i77 = i74 & 0;
michael@0 6153 i79 = ___muldi3(i72, i77, i78, i89) | 0;
michael@0 6154 i183 = tempRet0;
michael@0 6155 i83 = ___muldi3(i72, i77, i94, i62) | 0;
michael@0 6156 i77 = tempRet0;
michael@0 6157 i72 = i74;
michael@0 6158 i74 = 0;
michael@0 6159 i130 = ___muldi3(i72, i74, i78, i89) | 0;
michael@0 6160 i89 = tempRet0;
michael@0 6161 i78 = ___muldi3(i72, i74, i94, i62) | 0;
michael@0 6162 i62 = tempRet0;
michael@0 6163 i94 = _i64Add(i83 | 0, i77 & 0, i130 | 0, i89 & 0) | 0;
michael@0 6164 i130 = tempRet0;
michael@0 6165 i83 = _llvm_uadd_with_overflow_i64(i79 | 0, i183 | 0, 0, i94 | 0) | 0;
michael@0 6166 i94 = i83;
michael@0 6167 i83 = tempRet0;
michael@0 6168 i183 = _i64Add(i78, i62, tempRet1 & 1, 0) | 0;
michael@0 6169 i62 = _i64Add(i183, tempRet0, i77, 0) | 0;
michael@0 6170 i77 = _i64Add(i62, tempRet0, i89, 0) | 0;
michael@0 6171 i89 = _i64Add(i77, tempRet0, i130, 0) | 0;
michael@0 6172 i130 = tempRet0;
michael@0 6173 if (i182 ^ i81) {
michael@0 6174 i81 = _i64Subtract(0, 0, i94, i83) | 0;
michael@0 6175 i182 = tempRet0;
michael@0 6176 i77 = _i64Add((i94 | 0) == 0 & (i83 | 0) == 0 & 1, 0, ~i89, ~i130) | 0;
michael@0 6177 i199 = i182;
michael@0 6178 i200 = i81;
michael@0 6179 i201 = tempRet0;
michael@0 6180 i202 = i77;
michael@0 6181 } else {
michael@0 6182 i199 = i83;
michael@0 6183 i200 = i94;
michael@0 6184 i201 = i130;
michael@0 6185 i202 = i89;
michael@0 6186 }
michael@0 6187 i89 = _llvm_uadd_with_overflow_i64(i115 | 0, i69 | 0, i200 | 0, i199 | 0) | 0;
michael@0 6188 i69 = tempRet0;
michael@0 6189 i115 = tempRet1 & 1;
michael@0 6190 i130 = ___muldi3(i97, i90, i73, i67) | 0;
michael@0 6191 i67 = tempRet0;
michael@0 6192 i73 = 0;
michael@0 6193 i90 = (i67 | 0) < (i73 | 0) | (i67 | 0) == (i73 | 0) & i130 >>> 0 < 0 >>> 0;
michael@0 6194 i73 = _i64Subtract(0, 0, i130, i67) | 0;
michael@0 6195 i97 = i90 ? tempRet0 : i67;
michael@0 6196 if (i70) {
michael@0 6197 i70 = _i64Subtract(0, 0, i88, i91) | 0;
michael@0 6198 i203 = i90 ^ 1;
michael@0 6199 i204 = tempRet0;
michael@0 6200 i205 = i70;
michael@0 6201 } else {
michael@0 6202 i203 = i90;
michael@0 6203 i204 = i91;
michael@0 6204 i205 = i88;
michael@0 6205 }
michael@0 6206 i88 = (i90 ? i73 : i130) | 0;
michael@0 6207 i130 = i97 & 0;
michael@0 6208 i73 = i205 | 0;
michael@0 6209 i90 = i204 & 0;
michael@0 6210 i91 = ___muldi3(i73, i90, i88, i130) | 0;
michael@0 6211 i70 = tempRet0;
michael@0 6212 i67 = i204;
michael@0 6213 i94 = 0;
michael@0 6214 i83 = ___muldi3(i67, i94, i88, i130) | 0;
michael@0 6215 i130 = tempRet0;
michael@0 6216 i88 = i97;
michael@0 6217 i97 = 0;
michael@0 6218 i77 = ___muldi3(i73, i90, i88, i97) | 0;
michael@0 6219 i90 = tempRet0;
michael@0 6220 i73 = ___muldi3(i67, i94, i88, i97) | 0;
michael@0 6221 i97 = tempRet0;
michael@0 6222 i88 = _i64Add(i83 | 0, i130 & 0, i77 | 0, i90 & 0) | 0;
michael@0 6223 i77 = tempRet0;
michael@0 6224 i83 = _i64Add(i130, 0, i73, i97) | 0;
michael@0 6225 i97 = _i64Add(i83, tempRet0, i90, 0) | 0;
michael@0 6226 i90 = tempRet0;
michael@0 6227 i83 = _llvm_uadd_with_overflow_i64(i91 | 0, i70 | 0, 0, i88 | 0) | 0;
michael@0 6228 i88 = i83;
michael@0 6229 i83 = tempRet0;
michael@0 6230 i70 = _i64Add(i97, i90, tempRet1 & 1, 0) | 0;
michael@0 6231 i90 = _i64Add(i70, tempRet0, i77, 0) | 0;
michael@0 6232 i77 = tempRet0;
michael@0 6233 if (i203) {
michael@0 6234 i70 = _i64Subtract(0, 0, i88, i83) | 0;
michael@0 6235 i97 = tempRet0;
michael@0 6236 i91 = _i64Add((i88 | 0) == 0 & (i83 | 0) == 0 & 1, 0, ~i90, ~i77) | 0;
michael@0 6237 i206 = i97;
michael@0 6238 i207 = i70;
michael@0 6239 i208 = tempRet0;
michael@0 6240 i209 = i91;
michael@0 6241 } else {
michael@0 6242 i206 = i83;
michael@0 6243 i207 = i88;
michael@0 6244 i208 = i77;
michael@0 6245 i209 = i90;
michael@0 6246 }
michael@0 6247 i90 = _i64Subtract(0, 0, i207, i206) | 0;
michael@0 6248 i77 = _llvm_uadd_with_overflow_i64(i89 | 0, i69 | 0, i90 | 0, tempRet0 | 0) | 0;
michael@0 6249 i90 = tempRet0;
michael@0 6250 i69 = tempRet1 & 1;
michael@0 6251 if (i120) {
michael@0 6252 i89 = _i64Subtract(0, 0, i76, i84) | 0;
michael@0 6253 i88 = tempRet0;
michael@0 6254 i83 = _i64Add((i76 | 0) == 0 & (i84 | 0) == 0 & 1, 0, ~i87, ~i80) | 0;
michael@0 6255 i210 = i88;
michael@0 6256 i211 = i89;
michael@0 6257 i212 = tempRet0;
michael@0 6258 i213 = i83;
michael@0 6259 } else {
michael@0 6260 i210 = i84;
michael@0 6261 i211 = i76;
michael@0 6262 i212 = i80;
michael@0 6263 i213 = i87;
michael@0 6264 }
michael@0 6265 i83 = i21 ? i43 : i37;
michael@0 6266 i89 = i21 ? i42 : i39;
michael@0 6267 i88 = i211 | 0;
michael@0 6268 i91 = i210 & 0;
michael@0 6269 i70 = i83 | 0;
michael@0 6270 i97 = i89 & 0;
michael@0 6271 i73 = ___muldi3(i70, i97, i88, i91) | 0;
michael@0 6272 i130 = tempRet0;
michael@0 6273 i94 = i89;
michael@0 6274 i67 = 0;
michael@0 6275 i81 = ___muldi3(i94, i67, i88, i91) | 0;
michael@0 6276 i91 = tempRet0;
michael@0 6277 i88 = i210;
michael@0 6278 i182 = 0;
michael@0 6279 i62 = ___muldi3(i70, i97, i88, i182) | 0;
michael@0 6280 i97 = tempRet0;
michael@0 6281 i70 = ___muldi3(i94, i67, i88, i182) | 0;
michael@0 6282 i182 = tempRet0;
michael@0 6283 i88 = _i64Add(i81 | 0, i91 & 0, i62 | 0, i97 & 0) | 0;
michael@0 6284 i62 = tempRet0;
michael@0 6285 i81 = _llvm_uadd_with_overflow_i64(i73 | 0, i130 | 0, 0, i88 | 0) | 0;
michael@0 6286 i88 = i81;
michael@0 6287 i81 = tempRet0;
michael@0 6288 i130 = tempRet1 & 1;
michael@0 6289 i73 = ___muldi3(i83, i89, i213, i212) | 0;
michael@0 6290 i89 = _i64Add(i70, i182, i73, tempRet0) | 0;
michael@0 6291 i73 = _i64Add(i89, tempRet0, i91, 0) | 0;
michael@0 6292 i91 = _i64Add(i73, tempRet0, i97, 0) | 0;
michael@0 6293 i97 = _i64Add(i91, tempRet0, i130, 0) | 0;
michael@0 6294 i130 = _i64Add(i97, tempRet0, i62, 0) | 0;
michael@0 6295 i62 = tempRet0;
michael@0 6296 if (i120 ^ i21) {
michael@0 6297 i120 = _i64Subtract(0, 0, i88, i81) | 0;
michael@0 6298 i97 = tempRet0;
michael@0 6299 i91 = _i64Add((i88 | 0) == 0 & (i81 | 0) == 0 & 1, 0, ~i130, ~i62) | 0;
michael@0 6300 i214 = i97;
michael@0 6301 i215 = i120;
michael@0 6302 i216 = tempRet0;
michael@0 6303 i217 = i91;
michael@0 6304 } else {
michael@0 6305 i214 = i81;
michael@0 6306 i215 = i88;
michael@0 6307 i216 = i62;
michael@0 6308 i217 = i130;
michael@0 6309 }
michael@0 6310 i130 = _llvm_uadd_with_overflow_i64(i77 | 0, i90 | 0, i215 | 0, i214 | 0) | 0;
michael@0 6311 i90 = tempRet0;
michael@0 6312 i77 = tempRet1 & 1;
michael@0 6313 i62 = _i64Add(i194, i193, ~i198, ~i197) | 0;
michael@0 6314 i88 = _i64Add(i62, tempRet0, (i196 | 0) == 0 & (i195 | 0) == 0 & 1, 0) | 0;
michael@0 6315 i62 = _i64Add(i88, tempRet0, i86, 0) | 0;
michael@0 6316 i86 = _i64Add(i62, tempRet0, i202, i201) | 0;
michael@0 6317 i62 = _i64Add(i86, tempRet0, i115, 0) | 0;
michael@0 6318 i115 = _i64Add(i62, tempRet0, ~i209, ~i208) | 0;
michael@0 6319 i62 = _i64Add(i115, tempRet0, (i207 | 0) == 0 & (i206 | 0) == 0 & 1, 0) | 0;
michael@0 6320 i115 = _i64Add(i62, tempRet0, i69, 0) | 0;
michael@0 6321 i69 = _i64Add(i115, tempRet0, i217, i216) | 0;
michael@0 6322 i115 = _i64Add(i69, tempRet0, i77, 0) | 0;
michael@0 6323 i77 = i75 + 24 | 0;
michael@0 6324 HEAP32[i77 >> 2] = i92;
michael@0 6325 HEAP32[i77 + 4 >> 2] = i95;
michael@0 6326 i95 = i75 + 32 | 0;
michael@0 6327 HEAP32[i95 >> 2] = i119;
michael@0 6328 HEAP32[i95 + 4 >> 2] = i68;
michael@0 6329 i68 = i75 + 40 | 0;
michael@0 6330 HEAP32[i68 >> 2] = i148;
michael@0 6331 HEAP32[i68 + 4 >> 2] = i93;
michael@0 6332 i93 = i75 + 48 | 0;
michael@0 6333 HEAP32[i93 >> 2] = i85;
michael@0 6334 HEAP32[i93 + 4 >> 2] = i149;
michael@0 6335 i149 = i75 + 56 | 0;
michael@0 6336 HEAP32[i149 >> 2] = i130;
michael@0 6337 HEAP32[i149 + 4 >> 2] = i90;
michael@0 6338 i90 = i75 + 64 | 0;
michael@0 6339 HEAP32[i90 >> 2] = i115;
michael@0 6340 HEAP32[i90 + 4 >> 2] = tempRet0;
michael@0 6341 i90 = i75 + 72 | 0;
michael@0 6342 i115 = i75 + 72 | 0;
michael@0 6343 HEAP32[i115 >> 2] = i76;
michael@0 6344 HEAP32[i115 + 4 >> 2] = i84;
michael@0 6345 i84 = i75 + 80 | 0;
michael@0 6346 HEAP32[i84 >> 2] = i87;
michael@0 6347 HEAP32[i84 + 4 >> 2] = i80;
michael@0 6348 d15 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i75 + 24 | 0);
michael@0 6349 HEAP32[i75 + 88 >> 2] = ~~(d15 / +__ZNK20btConvexHullInternal6Int1288toScalarEv(i90));
michael@0 6350 d15 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i75 + 40 | 0);
michael@0 6351 HEAP32[i75 + 92 >> 2] = ~~(d15 / +__ZNK20btConvexHullInternal6Int1288toScalarEv(i90));
michael@0 6352 d15 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i75 + 56 | 0);
michael@0 6353 HEAP32[i75 + 96 >> 2] = ~~(d15 / +__ZNK20btConvexHullInternal6Int1288toScalarEv(i90));
michael@0 6354 HEAP32[i64 >> 2] = i75;
michael@0 6355 HEAP32[i75 + 8 >> 2] = i66;
michael@0 6356 i66 = HEAP32[i53 >> 2] | 0;
michael@0 6357 i90 = HEAP32[i52 >> 2] | 0;
michael@0 6358 do {
michael@0 6359 if ((i66 | 0) == (i90 | 0)) {
michael@0 6360 i80 = (i66 | 0) == 0 ? 1 : i66 << 1;
michael@0 6361 if ((i66 | 0) >= (i80 | 0)) {
michael@0 6362 i218 = i66;
michael@0 6363 i219 = i66;
michael@0 6364 break;
michael@0 6365 }
michael@0 6366 if ((i80 | 0) == 0) {
michael@0 6367 i220 = 0;
michael@0 6368 i221 = i66;
michael@0 6369 } else {
michael@0 6370 i84 = __Z22btAlignedAllocInternalji(i80 << 2, 16) | 0;
michael@0 6371 i220 = i84;
michael@0 6372 i221 = HEAP32[i53 >> 2] | 0;
michael@0 6373 }
michael@0 6374 if ((i221 | 0) > 0) {
michael@0 6375 i84 = 0;
michael@0 6376 do {
michael@0 6377 i87 = i220 + (i84 << 2) | 0;
michael@0 6378 if ((i87 | 0) != 0) {
michael@0 6379 HEAP32[i87 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i84 << 2) >> 2];
michael@0 6380 }
michael@0 6381 i84 = i84 + 1 | 0;
michael@0 6382 } while ((i84 | 0) < (i221 | 0));
michael@0 6383 }
michael@0 6384 i84 = HEAP32[i32 >> 2] | 0;
michael@0 6385 if ((i84 | 0) == 0) {
michael@0 6386 i222 = i221;
michael@0 6387 } else {
michael@0 6388 if ((HEAP8[i54] | 0) == 0) {
michael@0 6389 i223 = i221;
michael@0 6390 } else {
michael@0 6391 __Z21btAlignedFreeInternalPv(i84);
michael@0 6392 i223 = HEAP32[i53 >> 2] | 0;
michael@0 6393 }
michael@0 6394 HEAP32[i32 >> 2] = 0;
michael@0 6395 i222 = i223;
michael@0 6396 }
michael@0 6397 HEAP8[i54] = 1;
michael@0 6398 HEAP32[i32 >> 2] = i220;
michael@0 6399 HEAP32[i52 >> 2] = i80;
michael@0 6400 i218 = i222;
michael@0 6401 i219 = i80;
michael@0 6402 } else {
michael@0 6403 i218 = i66;
michael@0 6404 i219 = i90;
michael@0 6405 }
michael@0 6406 } while (0);
michael@0 6407 i90 = (HEAP32[i32 >> 2] | 0) + (i218 << 2) | 0;
michael@0 6408 if ((i90 | 0) != 0) {
michael@0 6409 HEAP32[i90 >> 2] = i75;
michael@0 6410 }
michael@0 6411 i90 = i218 + 1 | 0;
michael@0 6412 HEAP32[i53 >> 2] = i90;
michael@0 6413 do {
michael@0 6414 if ((i90 | 0) == (i219 | 0)) {
michael@0 6415 i66 = (i219 | 0) == 0 ? 1 : i219 << 1;
michael@0 6416 if ((i219 | 0) >= (i66 | 0)) {
michael@0 6417 i224 = i219;
michael@0 6418 i225 = i219;
michael@0 6419 break;
michael@0 6420 }
michael@0 6421 if ((i66 | 0) == 0) {
michael@0 6422 i226 = 0;
michael@0 6423 i227 = i219;
michael@0 6424 } else {
michael@0 6425 i84 = __Z22btAlignedAllocInternalji(i66 << 2, 16) | 0;
michael@0 6426 i226 = i84;
michael@0 6427 i227 = HEAP32[i53 >> 2] | 0;
michael@0 6428 }
michael@0 6429 if ((i227 | 0) > 0) {
michael@0 6430 i84 = 0;
michael@0 6431 do {
michael@0 6432 i87 = i226 + (i84 << 2) | 0;
michael@0 6433 if ((i87 | 0) != 0) {
michael@0 6434 HEAP32[i87 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i84 << 2) >> 2];
michael@0 6435 }
michael@0 6436 i84 = i84 + 1 | 0;
michael@0 6437 } while ((i84 | 0) < (i227 | 0));
michael@0 6438 }
michael@0 6439 i84 = HEAP32[i32 >> 2] | 0;
michael@0 6440 if ((i84 | 0) == 0) {
michael@0 6441 i228 = i227;
michael@0 6442 } else {
michael@0 6443 if ((HEAP8[i54] | 0) == 0) {
michael@0 6444 i229 = i227;
michael@0 6445 } else {
michael@0 6446 __Z21btAlignedFreeInternalPv(i84);
michael@0 6447 i229 = HEAP32[i53 >> 2] | 0;
michael@0 6448 }
michael@0 6449 HEAP32[i32 >> 2] = 0;
michael@0 6450 i228 = i229;
michael@0 6451 }
michael@0 6452 HEAP8[i54] = 1;
michael@0 6453 HEAP32[i32 >> 2] = i226;
michael@0 6454 HEAP32[i52 >> 2] = i66;
michael@0 6455 i224 = i228;
michael@0 6456 i225 = i66;
michael@0 6457 } else {
michael@0 6458 i224 = i90;
michael@0 6459 i225 = i219;
michael@0 6460 }
michael@0 6461 } while (0);
michael@0 6462 i90 = (HEAP32[i32 >> 2] | 0) + (i224 << 2) | 0;
michael@0 6463 if ((i90 | 0) != 0) {
michael@0 6464 HEAP32[i90 >> 2] = i58;
michael@0 6465 }
michael@0 6466 i90 = i224 + 1 | 0;
michael@0 6467 HEAP32[i53 >> 2] = i90;
michael@0 6468 do {
michael@0 6469 if ((i90 | 0) == (i225 | 0)) {
michael@0 6470 i75 = (i225 | 0) == 0 ? 1 : i225 << 1;
michael@0 6471 if ((i225 | 0) >= (i75 | 0)) {
michael@0 6472 i230 = i225;
michael@0 6473 break;
michael@0 6474 }
michael@0 6475 if ((i75 | 0) == 0) {
michael@0 6476 i231 = 0;
michael@0 6477 i232 = i225;
michael@0 6478 } else {
michael@0 6479 i84 = __Z22btAlignedAllocInternalji(i75 << 2, 16) | 0;
michael@0 6480 i231 = i84;
michael@0 6481 i232 = HEAP32[i53 >> 2] | 0;
michael@0 6482 }
michael@0 6483 if ((i232 | 0) > 0) {
michael@0 6484 i84 = 0;
michael@0 6485 do {
michael@0 6486 i80 = i231 + (i84 << 2) | 0;
michael@0 6487 if ((i80 | 0) != 0) {
michael@0 6488 HEAP32[i80 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i84 << 2) >> 2];
michael@0 6489 }
michael@0 6490 i84 = i84 + 1 | 0;
michael@0 6491 } while ((i84 | 0) < (i232 | 0));
michael@0 6492 }
michael@0 6493 i84 = HEAP32[i32 >> 2] | 0;
michael@0 6494 if ((i84 | 0) == 0) {
michael@0 6495 i233 = i232;
michael@0 6496 } else {
michael@0 6497 if ((HEAP8[i54] | 0) == 0) {
michael@0 6498 i234 = i232;
michael@0 6499 } else {
michael@0 6500 __Z21btAlignedFreeInternalPv(i84);
michael@0 6501 i234 = HEAP32[i53 >> 2] | 0;
michael@0 6502 }
michael@0 6503 HEAP32[i32 >> 2] = 0;
michael@0 6504 i233 = i234;
michael@0 6505 }
michael@0 6506 HEAP8[i54] = 1;
michael@0 6507 HEAP32[i32 >> 2] = i231;
michael@0 6508 HEAP32[i52 >> 2] = i75;
michael@0 6509 i230 = i233;
michael@0 6510 } else {
michael@0 6511 i230 = i90;
michael@0 6512 }
michael@0 6513 } while (0);
michael@0 6514 i90 = (HEAP32[i32 >> 2] | 0) + (i230 << 2) | 0;
michael@0 6515 if ((i90 | 0) != 0) {
michael@0 6516 HEAP32[i90 >> 2] = 0;
michael@0 6517 }
michael@0 6518 HEAP32[i53 >> 2] = i230 + 1;
michael@0 6519 }
michael@0 6520 i90 = (i65 | 0) == 0;
michael@0 6521 if ((i65 | i50 | 0) == 0) {
michael@0 6522 i58 = HEAP32[HEAP32[i60 >> 2] >> 2] | 0;
michael@0 6523 i84 = HEAP32[i64 >> 2] | 0;
michael@0 6524 if ((HEAP32[i58 + 12 >> 2] | 0) == (i84 | 0)) {
michael@0 6525 i235 = i58;
michael@0 6526 } else {
michael@0 6527 i236 = i84;
michael@0 6528 i49 = 1401;
michael@0 6529 }
michael@0 6530 } else {
michael@0 6531 i236 = HEAP32[i64 >> 2] | 0;
michael@0 6532 i49 = 1401;
michael@0 6533 }
michael@0 6534 if ((i49 | 0) == 1401) {
michael@0 6535 i49 = 0;
michael@0 6536 i84 = HEAP32[i61 + 12 >> 2] | 0;
michael@0 6537 i58 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i11) | 0;
michael@0 6538 i66 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i11) | 0;
michael@0 6539 i80 = i58 + 8 | 0;
michael@0 6540 HEAP32[i80 >> 2] = i66;
michael@0 6541 HEAP32[i66 + 8 >> 2] = i58;
michael@0 6542 HEAP32[i58 + 20 >> 2] = HEAP32[i9 >> 2];
michael@0 6543 HEAP32[i66 + 20 >> 2] = HEAP32[i9 >> 2];
michael@0 6544 HEAP32[i58 + 12 >> 2] = i236;
michael@0 6545 HEAP32[i66 + 12 >> 2] = i84;
michael@0 6546 HEAP32[i58 + 16 >> 2] = 0;
michael@0 6547 HEAP32[i66 + 16 >> 2] = 0;
michael@0 6548 i66 = (HEAP32[i30 >> 2] | 0) + 1 | 0;
michael@0 6549 HEAP32[i30 >> 2] = i66;
michael@0 6550 if ((i66 | 0) > (HEAP32[i40 >> 2] | 0)) {
michael@0 6551 HEAP32[i40 >> 2] = i66;
michael@0 6552 }
michael@0 6553 if (i57) {
michael@0 6554 i66 = HEAP32[HEAP32[i60 >> 2] >> 2] | 0;
michael@0 6555 HEAP32[i58 >> 2] = i66;
michael@0 6556 HEAP32[i66 + 4 >> 2] = i58;
michael@0 6557 i49 = 1406;
michael@0 6558 } else {
michael@0 6559 if ((i55 | 0) != 0) {
michael@0 6560 i49 = 1406;
michael@0 6561 }
michael@0 6562 }
michael@0 6563 if ((i49 | 0) == 1406) {
michael@0 6564 i49 = 0;
michael@0 6565 i66 = HEAP32[i60 >> 2] | 0;
michael@0 6566 HEAP32[i66 >> 2] = i58;
michael@0 6567 HEAP32[i58 + 4 >> 2] = i66;
michael@0 6568 }
michael@0 6569 i66 = i59 + 8 | 0;
michael@0 6570 if (i90) {
michael@0 6571 i90 = HEAP32[(HEAP32[i66 >> 2] | 0) + 4 >> 2] | 0;
michael@0 6572 i84 = HEAP32[i80 >> 2] | 0;
michael@0 6573 HEAP32[i90 >> 2] = i84;
michael@0 6574 HEAP32[i84 + 4 >> 2] = i90;
michael@0 6575 }
michael@0 6576 i90 = HEAP32[i80 >> 2] | 0;
michael@0 6577 i80 = HEAP32[i66 >> 2] | 0;
michael@0 6578 HEAP32[i90 >> 2] = i80;
michael@0 6579 HEAP32[i80 + 4 >> 2] = i90;
michael@0 6580 i235 = i58;
michael@0 6581 }
michael@0 6582 do {
michael@0 6583 if ((i55 | 0) != 0) {
michael@0 6584 i58 = i55 + 8 | 0;
michael@0 6585 i90 = HEAP32[i58 >> 2] | 0;
michael@0 6586 if ((i50 | 0) > 0) {
michael@0 6587 HEAP32[i235 >> 2] = i90;
michael@0 6588 HEAP32[i90 + 4 >> 2] = i235;
michael@0 6589 break;
michael@0 6590 }
michael@0 6591 if ((i235 | 0) == (i90 | 0)) {
michael@0 6592 break;
michael@0 6593 }
michael@0 6594 i90 = i55 + 12 | 0;
michael@0 6595 i80 = HEAP32[i53 >> 2] | 0;
michael@0 6596 i66 = HEAP32[i52 >> 2] | 0;
michael@0 6597 do {
michael@0 6598 if ((i80 | 0) == (i66 | 0)) {
michael@0 6599 i84 = (i80 | 0) == 0 ? 1 : i80 << 1;
michael@0 6600 if ((i80 | 0) >= (i84 | 0)) {
michael@0 6601 i237 = i80;
michael@0 6602 i238 = i80;
michael@0 6603 break;
michael@0 6604 }
michael@0 6605 if ((i84 | 0) == 0) {
michael@0 6606 i239 = 0;
michael@0 6607 i240 = i80;
michael@0 6608 } else {
michael@0 6609 i87 = __Z22btAlignedAllocInternalji(i84 << 2, 16) | 0;
michael@0 6610 i239 = i87;
michael@0 6611 i240 = HEAP32[i53 >> 2] | 0;
michael@0 6612 }
michael@0 6613 if ((i240 | 0) > 0) {
michael@0 6614 i87 = 0;
michael@0 6615 do {
michael@0 6616 i115 = i239 + (i87 << 2) | 0;
michael@0 6617 if ((i115 | 0) != 0) {
michael@0 6618 HEAP32[i115 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i87 << 2) >> 2];
michael@0 6619 }
michael@0 6620 i87 = i87 + 1 | 0;
michael@0 6621 } while ((i87 | 0) < (i240 | 0));
michael@0 6622 }
michael@0 6623 i87 = HEAP32[i32 >> 2] | 0;
michael@0 6624 if ((i87 | 0) == 0) {
michael@0 6625 i241 = i240;
michael@0 6626 } else {
michael@0 6627 if ((HEAP8[i54] | 0) == 0) {
michael@0 6628 i242 = i240;
michael@0 6629 } else {
michael@0 6630 __Z21btAlignedFreeInternalPv(i87);
michael@0 6631 i242 = HEAP32[i53 >> 2] | 0;
michael@0 6632 }
michael@0 6633 HEAP32[i32 >> 2] = 0;
michael@0 6634 i241 = i242;
michael@0 6635 }
michael@0 6636 HEAP8[i54] = 1;
michael@0 6637 HEAP32[i32 >> 2] = i239;
michael@0 6638 HEAP32[i52 >> 2] = i84;
michael@0 6639 i237 = i241;
michael@0 6640 i238 = i84;
michael@0 6641 } else {
michael@0 6642 i237 = i80;
michael@0 6643 i238 = i66;
michael@0 6644 }
michael@0 6645 } while (0);
michael@0 6646 i66 = (HEAP32[i32 >> 2] | 0) + (i237 << 2) | 0;
michael@0 6647 if ((i66 | 0) != 0) {
michael@0 6648 HEAP32[i66 >> 2] = HEAP32[i90 >> 2];
michael@0 6649 }
michael@0 6650 i66 = i237 + 1 | 0;
michael@0 6651 HEAP32[i53 >> 2] = i66;
michael@0 6652 i80 = i235 | 0;
michael@0 6653 i75 = HEAP32[i80 >> 2] | 0;
michael@0 6654 if ((i75 | 0) == (HEAP32[i58 >> 2] | 0)) {
michael@0 6655 i243 = i66;
michael@0 6656 i244 = i238;
michael@0 6657 } else {
michael@0 6658 i66 = i75;
michael@0 6659 while (1) {
michael@0 6660 i75 = i66 + 12 | 0;
michael@0 6661 i87 = HEAP32[i75 >> 2] | 0;
michael@0 6662 i115 = i66 | 0;
michael@0 6663 i76 = HEAP32[i115 >> 2] | 0;
michael@0 6664 i149 = HEAP32[i66 + 8 >> 2] | 0;
michael@0 6665 if ((i76 | 0) == (i66 | 0)) {
michael@0 6666 HEAP32[(HEAP32[i149 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 6667 } else {
michael@0 6668 i130 = i66 + 4 | 0;
michael@0 6669 HEAP32[i76 + 4 >> 2] = HEAP32[i130 >> 2];
michael@0 6670 HEAP32[HEAP32[i130 >> 2] >> 2] = i76;
michael@0 6671 HEAP32[(HEAP32[i149 + 12 >> 2] | 0) + 8 >> 2] = i76;
michael@0 6672 }
michael@0 6673 i76 = i149 | 0;
michael@0 6674 i130 = HEAP32[i76 >> 2] | 0;
michael@0 6675 if ((i130 | 0) == (i149 | 0)) {
michael@0 6676 HEAP32[(HEAP32[i75 >> 2] | 0) + 8 >> 2] = 0;
michael@0 6677 } else {
michael@0 6678 i93 = i149 + 4 | 0;
michael@0 6679 HEAP32[i130 + 4 >> 2] = HEAP32[i93 >> 2];
michael@0 6680 HEAP32[HEAP32[i93 >> 2] >> 2] = i130;
michael@0 6681 HEAP32[(HEAP32[i75 >> 2] | 0) + 8 >> 2] = i130;
michael@0 6682 }
michael@0 6683 _memset(i66 | 0, 0, 20);
michael@0 6684 HEAP32[i115 >> 2] = HEAP32[i4 >> 2];
michael@0 6685 HEAP32[i4 >> 2] = i66;
michael@0 6686 _memset(i149 | 0, 0, 20);
michael@0 6687 HEAP32[i76 >> 2] = HEAP32[i4 >> 2];
michael@0 6688 HEAP32[i4 >> 2] = i149;
michael@0 6689 HEAP32[i30 >> 2] = (HEAP32[i30 >> 2] | 0) - 1;
michael@0 6690 i149 = HEAP32[i53 >> 2] | 0;
michael@0 6691 i76 = HEAP32[i52 >> 2] | 0;
michael@0 6692 do {
michael@0 6693 if ((i149 | 0) == (i76 | 0)) {
michael@0 6694 i115 = (i149 | 0) == 0 ? 1 : i149 << 1;
michael@0 6695 if ((i149 | 0) >= (i115 | 0)) {
michael@0 6696 i245 = i149;
michael@0 6697 i246 = i149;
michael@0 6698 break;
michael@0 6699 }
michael@0 6700 if ((i115 | 0) == 0) {
michael@0 6701 i247 = 0;
michael@0 6702 i248 = i149;
michael@0 6703 } else {
michael@0 6704 i130 = __Z22btAlignedAllocInternalji(i115 << 2, 16) | 0;
michael@0 6705 i247 = i130;
michael@0 6706 i248 = HEAP32[i53 >> 2] | 0;
michael@0 6707 }
michael@0 6708 if ((i248 | 0) > 0) {
michael@0 6709 i130 = 0;
michael@0 6710 do {
michael@0 6711 i75 = i247 + (i130 << 2) | 0;
michael@0 6712 if ((i75 | 0) != 0) {
michael@0 6713 HEAP32[i75 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i130 << 2) >> 2];
michael@0 6714 }
michael@0 6715 i130 = i130 + 1 | 0;
michael@0 6716 } while ((i130 | 0) < (i248 | 0));
michael@0 6717 }
michael@0 6718 i130 = HEAP32[i32 >> 2] | 0;
michael@0 6719 if ((i130 | 0) == 0) {
michael@0 6720 i249 = i248;
michael@0 6721 } else {
michael@0 6722 if ((HEAP8[i54] | 0) == 0) {
michael@0 6723 i250 = i248;
michael@0 6724 } else {
michael@0 6725 __Z21btAlignedFreeInternalPv(i130);
michael@0 6726 i250 = HEAP32[i53 >> 2] | 0;
michael@0 6727 }
michael@0 6728 HEAP32[i32 >> 2] = 0;
michael@0 6729 i249 = i250;
michael@0 6730 }
michael@0 6731 HEAP8[i54] = 1;
michael@0 6732 HEAP32[i32 >> 2] = i247;
michael@0 6733 HEAP32[i52 >> 2] = i115;
michael@0 6734 i245 = i249;
michael@0 6735 i246 = i115;
michael@0 6736 } else {
michael@0 6737 i245 = i149;
michael@0 6738 i246 = i76;
michael@0 6739 }
michael@0 6740 } while (0);
michael@0 6741 i76 = (HEAP32[i32 >> 2] | 0) + (i245 << 2) | 0;
michael@0 6742 if ((i76 | 0) != 0) {
michael@0 6743 HEAP32[i76 >> 2] = i87;
michael@0 6744 }
michael@0 6745 i76 = i245 + 1 | 0;
michael@0 6746 HEAP32[i53 >> 2] = i76;
michael@0 6747 i149 = HEAP32[i80 >> 2] | 0;
michael@0 6748 if ((i149 | 0) == (HEAP32[i58 >> 2] | 0)) {
michael@0 6749 i243 = i76;
michael@0 6750 i244 = i246;
michael@0 6751 break;
michael@0 6752 } else {
michael@0 6753 i66 = i149;
michael@0 6754 }
michael@0 6755 }
michael@0 6756 }
michael@0 6757 do {
michael@0 6758 if ((i243 | 0) == (i244 | 0)) {
michael@0 6759 i66 = (i244 | 0) == 0 ? 1 : i244 << 1;
michael@0 6760 if ((i244 | 0) >= (i66 | 0)) {
michael@0 6761 i251 = i244;
michael@0 6762 break;
michael@0 6763 }
michael@0 6764 if ((i66 | 0) == 0) {
michael@0 6765 i252 = 0;
michael@0 6766 i253 = i244;
michael@0 6767 } else {
michael@0 6768 i58 = __Z22btAlignedAllocInternalji(i66 << 2, 16) | 0;
michael@0 6769 i252 = i58;
michael@0 6770 i253 = HEAP32[i53 >> 2] | 0;
michael@0 6771 }
michael@0 6772 if ((i253 | 0) > 0) {
michael@0 6773 i58 = 0;
michael@0 6774 do {
michael@0 6775 i80 = i252 + (i58 << 2) | 0;
michael@0 6776 if ((i80 | 0) != 0) {
michael@0 6777 HEAP32[i80 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i58 << 2) >> 2];
michael@0 6778 }
michael@0 6779 i58 = i58 + 1 | 0;
michael@0 6780 } while ((i58 | 0) < (i253 | 0));
michael@0 6781 }
michael@0 6782 i58 = HEAP32[i32 >> 2] | 0;
michael@0 6783 if ((i58 | 0) == 0) {
michael@0 6784 i254 = i253;
michael@0 6785 } else {
michael@0 6786 if ((HEAP8[i54] | 0) == 0) {
michael@0 6787 i255 = i253;
michael@0 6788 } else {
michael@0 6789 __Z21btAlignedFreeInternalPv(i58);
michael@0 6790 i255 = HEAP32[i53 >> 2] | 0;
michael@0 6791 }
michael@0 6792 HEAP32[i32 >> 2] = 0;
michael@0 6793 i254 = i255;
michael@0 6794 }
michael@0 6795 HEAP8[i54] = 1;
michael@0 6796 HEAP32[i32 >> 2] = i252;
michael@0 6797 HEAP32[i52 >> 2] = i66;
michael@0 6798 i251 = i254;
michael@0 6799 } else {
michael@0 6800 i251 = i243;
michael@0 6801 }
michael@0 6802 } while (0);
michael@0 6803 i58 = (HEAP32[i32 >> 2] | 0) + (i251 << 2) | 0;
michael@0 6804 if ((i58 | 0) != 0) {
michael@0 6805 HEAP32[i58 >> 2] = 0;
michael@0 6806 }
michael@0 6807 HEAP32[i53 >> 2] = i251 + 1;
michael@0 6808 }
michael@0 6809 } while (0);
michael@0 6810 HEAP32[i235 + 16 >> 2] = i2;
michael@0 6811 HEAP32[(HEAP32[i235 + 8 >> 2] | 0) + 16 >> 2] = HEAP32[i59 + 16 >> 2];
michael@0 6812 i44 = i59;
michael@0 6813 i50 = i65;
michael@0 6814 i51 = i63;
michael@0 6815 i55 = i235;
michael@0 6816 i56 = (i56 | 0) == 0 ? i235 : i56;
michael@0 6817 }
michael@0 6818 if ((i49 | 0) == 1618) {
michael@0 6819 STACKTOP = i5;
michael@0 6820 return i20 | 0;
michael@0 6821 }
michael@0 6822 do {
michael@0 6823 if ((i50 | 0) > 0) {
michael@0 6824 HEAP32[(HEAP32[i56 + 8 >> 2] | 0) + 12 >> 2] = HEAP32[i55 + 12 >> 2];
michael@0 6825 i235 = HEAP32[i51 + 8 >> 2] | 0;
michael@0 6826 HEAP32[i235 >> 2] = i56;
michael@0 6827 HEAP32[i56 + 4 >> 2] = i235;
michael@0 6828 i235 = HEAP32[i55 + 8 >> 2] | 0;
michael@0 6829 HEAP32[i56 >> 2] = i235;
michael@0 6830 HEAP32[i235 + 4 >> 2] = i56;
michael@0 6831 } else {
michael@0 6832 i235 = i55 + 8 | 0;
michael@0 6833 if ((i56 | 0) == (HEAP32[i235 >> 2] | 0)) {
michael@0 6834 break;
michael@0 6835 }
michael@0 6836 i63 = i55 + 12 | 0;
michael@0 6837 i65 = HEAP32[i53 >> 2] | 0;
michael@0 6838 i44 = HEAP32[i52 >> 2] | 0;
michael@0 6839 do {
michael@0 6840 if ((i65 | 0) == (i44 | 0)) {
michael@0 6841 i251 = (i65 | 0) == 0 ? 1 : i65 << 1;
michael@0 6842 if ((i65 | 0) >= (i251 | 0)) {
michael@0 6843 i256 = i65;
michael@0 6844 i257 = i65;
michael@0 6845 break;
michael@0 6846 }
michael@0 6847 if ((i251 | 0) == 0) {
michael@0 6848 i258 = 0;
michael@0 6849 i259 = i65;
michael@0 6850 } else {
michael@0 6851 i243 = __Z22btAlignedAllocInternalji(i251 << 2, 16) | 0;
michael@0 6852 i258 = i243;
michael@0 6853 i259 = HEAP32[i53 >> 2] | 0;
michael@0 6854 }
michael@0 6855 if ((i259 | 0) > 0) {
michael@0 6856 i243 = 0;
michael@0 6857 do {
michael@0 6858 i254 = i258 + (i243 << 2) | 0;
michael@0 6859 if ((i254 | 0) != 0) {
michael@0 6860 HEAP32[i254 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i243 << 2) >> 2];
michael@0 6861 }
michael@0 6862 i243 = i243 + 1 | 0;
michael@0 6863 } while ((i243 | 0) < (i259 | 0));
michael@0 6864 }
michael@0 6865 i243 = HEAP32[i32 >> 2] | 0;
michael@0 6866 if ((i243 | 0) == 0) {
michael@0 6867 i260 = i259;
michael@0 6868 } else {
michael@0 6869 if ((HEAP8[i54] | 0) == 0) {
michael@0 6870 i261 = i259;
michael@0 6871 } else {
michael@0 6872 __Z21btAlignedFreeInternalPv(i243);
michael@0 6873 i261 = HEAP32[i53 >> 2] | 0;
michael@0 6874 }
michael@0 6875 HEAP32[i32 >> 2] = 0;
michael@0 6876 i260 = i261;
michael@0 6877 }
michael@0 6878 HEAP8[i54] = 1;
michael@0 6879 HEAP32[i32 >> 2] = i258;
michael@0 6880 HEAP32[i52 >> 2] = i251;
michael@0 6881 i256 = i260;
michael@0 6882 i257 = i251;
michael@0 6883 } else {
michael@0 6884 i256 = i65;
michael@0 6885 i257 = i44;
michael@0 6886 }
michael@0 6887 } while (0);
michael@0 6888 i44 = (HEAP32[i32 >> 2] | 0) + (i256 << 2) | 0;
michael@0 6889 if ((i44 | 0) != 0) {
michael@0 6890 HEAP32[i44 >> 2] = HEAP32[i63 >> 2];
michael@0 6891 }
michael@0 6892 i44 = i256 + 1 | 0;
michael@0 6893 HEAP32[i53 >> 2] = i44;
michael@0 6894 i65 = i56 | 0;
michael@0 6895 i59 = HEAP32[i65 >> 2] | 0;
michael@0 6896 if ((i59 | 0) == (HEAP32[i235 >> 2] | 0)) {
michael@0 6897 i262 = i44;
michael@0 6898 i263 = i257;
michael@0 6899 } else {
michael@0 6900 i44 = i59;
michael@0 6901 while (1) {
michael@0 6902 i59 = i44 + 12 | 0;
michael@0 6903 i243 = HEAP32[i59 >> 2] | 0;
michael@0 6904 i254 = i44 | 0;
michael@0 6905 i252 = HEAP32[i254 >> 2] | 0;
michael@0 6906 i255 = HEAP32[i44 + 8 >> 2] | 0;
michael@0 6907 if ((i252 | 0) == (i44 | 0)) {
michael@0 6908 HEAP32[(HEAP32[i255 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 6909 } else {
michael@0 6910 i253 = i44 + 4 | 0;
michael@0 6911 HEAP32[i252 + 4 >> 2] = HEAP32[i253 >> 2];
michael@0 6912 HEAP32[HEAP32[i253 >> 2] >> 2] = i252;
michael@0 6913 HEAP32[(HEAP32[i255 + 12 >> 2] | 0) + 8 >> 2] = i252;
michael@0 6914 }
michael@0 6915 i252 = i255 | 0;
michael@0 6916 i253 = HEAP32[i252 >> 2] | 0;
michael@0 6917 if ((i253 | 0) == (i255 | 0)) {
michael@0 6918 HEAP32[(HEAP32[i59 >> 2] | 0) + 8 >> 2] = 0;
michael@0 6919 } else {
michael@0 6920 i244 = i255 + 4 | 0;
michael@0 6921 HEAP32[i253 + 4 >> 2] = HEAP32[i244 >> 2];
michael@0 6922 HEAP32[HEAP32[i244 >> 2] >> 2] = i253;
michael@0 6923 HEAP32[(HEAP32[i59 >> 2] | 0) + 8 >> 2] = i253;
michael@0 6924 }
michael@0 6925 _memset(i44 | 0, 0, 20);
michael@0 6926 HEAP32[i254 >> 2] = HEAP32[i4 >> 2];
michael@0 6927 HEAP32[i4 >> 2] = i44;
michael@0 6928 _memset(i255 | 0, 0, 20);
michael@0 6929 HEAP32[i252 >> 2] = HEAP32[i4 >> 2];
michael@0 6930 HEAP32[i4 >> 2] = i255;
michael@0 6931 HEAP32[i30 >> 2] = (HEAP32[i30 >> 2] | 0) - 1;
michael@0 6932 i255 = HEAP32[i53 >> 2] | 0;
michael@0 6933 i252 = HEAP32[i52 >> 2] | 0;
michael@0 6934 do {
michael@0 6935 if ((i255 | 0) == (i252 | 0)) {
michael@0 6936 i254 = (i255 | 0) == 0 ? 1 : i255 << 1;
michael@0 6937 if ((i255 | 0) >= (i254 | 0)) {
michael@0 6938 i264 = i255;
michael@0 6939 i265 = i255;
michael@0 6940 break;
michael@0 6941 }
michael@0 6942 if ((i254 | 0) == 0) {
michael@0 6943 i266 = 0;
michael@0 6944 i267 = i255;
michael@0 6945 } else {
michael@0 6946 i253 = __Z22btAlignedAllocInternalji(i254 << 2, 16) | 0;
michael@0 6947 i266 = i253;
michael@0 6948 i267 = HEAP32[i53 >> 2] | 0;
michael@0 6949 }
michael@0 6950 if ((i267 | 0) > 0) {
michael@0 6951 i253 = 0;
michael@0 6952 do {
michael@0 6953 i59 = i266 + (i253 << 2) | 0;
michael@0 6954 if ((i59 | 0) != 0) {
michael@0 6955 HEAP32[i59 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i253 << 2) >> 2];
michael@0 6956 }
michael@0 6957 i253 = i253 + 1 | 0;
michael@0 6958 } while ((i253 | 0) < (i267 | 0));
michael@0 6959 }
michael@0 6960 i253 = HEAP32[i32 >> 2] | 0;
michael@0 6961 if ((i253 | 0) == 0) {
michael@0 6962 i268 = i267;
michael@0 6963 } else {
michael@0 6964 if ((HEAP8[i54] | 0) == 0) {
michael@0 6965 i269 = i267;
michael@0 6966 } else {
michael@0 6967 __Z21btAlignedFreeInternalPv(i253);
michael@0 6968 i269 = HEAP32[i53 >> 2] | 0;
michael@0 6969 }
michael@0 6970 HEAP32[i32 >> 2] = 0;
michael@0 6971 i268 = i269;
michael@0 6972 }
michael@0 6973 HEAP8[i54] = 1;
michael@0 6974 HEAP32[i32 >> 2] = i266;
michael@0 6975 HEAP32[i52 >> 2] = i254;
michael@0 6976 i264 = i268;
michael@0 6977 i265 = i254;
michael@0 6978 } else {
michael@0 6979 i264 = i255;
michael@0 6980 i265 = i252;
michael@0 6981 }
michael@0 6982 } while (0);
michael@0 6983 i252 = (HEAP32[i32 >> 2] | 0) + (i264 << 2) | 0;
michael@0 6984 if ((i252 | 0) != 0) {
michael@0 6985 HEAP32[i252 >> 2] = i243;
michael@0 6986 }
michael@0 6987 i252 = i264 + 1 | 0;
michael@0 6988 HEAP32[i53 >> 2] = i252;
michael@0 6989 i255 = HEAP32[i65 >> 2] | 0;
michael@0 6990 if ((i255 | 0) == (HEAP32[i235 >> 2] | 0)) {
michael@0 6991 i262 = i252;
michael@0 6992 i263 = i265;
michael@0 6993 break;
michael@0 6994 } else {
michael@0 6995 i44 = i255;
michael@0 6996 }
michael@0 6997 }
michael@0 6998 }
michael@0 6999 do {
michael@0 7000 if ((i262 | 0) == (i263 | 0)) {
michael@0 7001 i44 = (i263 | 0) == 0 ? 1 : i263 << 1;
michael@0 7002 if ((i263 | 0) >= (i44 | 0)) {
michael@0 7003 i270 = i263;
michael@0 7004 break;
michael@0 7005 }
michael@0 7006 if ((i44 | 0) == 0) {
michael@0 7007 i271 = 0;
michael@0 7008 i272 = i263;
michael@0 7009 } else {
michael@0 7010 i235 = __Z22btAlignedAllocInternalji(i44 << 2, 16) | 0;
michael@0 7011 i271 = i235;
michael@0 7012 i272 = HEAP32[i53 >> 2] | 0;
michael@0 7013 }
michael@0 7014 if ((i272 | 0) > 0) {
michael@0 7015 i235 = 0;
michael@0 7016 do {
michael@0 7017 i65 = i271 + (i235 << 2) | 0;
michael@0 7018 if ((i65 | 0) != 0) {
michael@0 7019 HEAP32[i65 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i235 << 2) >> 2];
michael@0 7020 }
michael@0 7021 i235 = i235 + 1 | 0;
michael@0 7022 } while ((i235 | 0) < (i272 | 0));
michael@0 7023 }
michael@0 7024 i235 = HEAP32[i32 >> 2] | 0;
michael@0 7025 if ((i235 | 0) == 0) {
michael@0 7026 i273 = i272;
michael@0 7027 } else {
michael@0 7028 if ((HEAP8[i54] | 0) == 0) {
michael@0 7029 i274 = i272;
michael@0 7030 } else {
michael@0 7031 __Z21btAlignedFreeInternalPv(i235);
michael@0 7032 i274 = HEAP32[i53 >> 2] | 0;
michael@0 7033 }
michael@0 7034 HEAP32[i32 >> 2] = 0;
michael@0 7035 i273 = i274;
michael@0 7036 }
michael@0 7037 HEAP8[i54] = 1;
michael@0 7038 HEAP32[i32 >> 2] = i271;
michael@0 7039 HEAP32[i52 >> 2] = i44;
michael@0 7040 i270 = i273;
michael@0 7041 } else {
michael@0 7042 i270 = i262;
michael@0 7043 }
michael@0 7044 } while (0);
michael@0 7045 i235 = (HEAP32[i32 >> 2] | 0) + (i270 << 2) | 0;
michael@0 7046 if ((i235 | 0) != 0) {
michael@0 7047 HEAP32[i235 >> 2] = 0;
michael@0 7048 }
michael@0 7049 HEAP32[i53 >> 2] = i270 + 1;
michael@0 7050 }
michael@0 7051 } while (0);
michael@0 7052 HEAP32[i1 + 124 >> 2] = HEAP32[HEAP32[i32 >> 2] >> 2];
michael@0 7053 i1 = HEAP32[i53 >> 2] | 0;
michael@0 7054 if ((i1 | 0) > 0) {
michael@0 7055 i270 = 0;
michael@0 7056 i262 = i1;
michael@0 7057 while (1) {
michael@0 7058 if ((i270 | 0) < (i262 | 0)) {
michael@0 7059 i273 = i270;
michael@0 7060 while (1) {
michael@0 7061 i271 = HEAP32[i32 >> 2] | 0;
michael@0 7062 i274 = HEAP32[i271 + (i273 << 2) >> 2] | 0;
michael@0 7063 i272 = i273 + 2 | 0;
michael@0 7064 i263 = HEAP32[i271 + (i273 + 1 << 2) >> 2] | 0;
michael@0 7065 do {
michael@0 7066 if ((i263 | 0) == 0) {
michael@0 7067 i275 = i272;
michael@0 7068 } else {
michael@0 7069 i271 = i274 + 16 | 0;
michael@0 7070 i265 = i274 + 12 | 0;
michael@0 7071 i264 = 0;
michael@0 7072 i268 = i272;
michael@0 7073 i266 = i263;
michael@0 7074 while (1) {
michael@0 7075 i269 = HEAP32[i271 >> 2] | 0;
michael@0 7076 i267 = i266 + 12 | 0;
michael@0 7077 i257 = HEAP32[i267 >> 2] | 0;
michael@0 7078 if ((i269 | 0) == 0) {
michael@0 7079 HEAP32[i265 >> 2] = i257;
michael@0 7080 } else {
michael@0 7081 HEAP32[i269 + 8 >> 2] = i257;
michael@0 7082 }
michael@0 7083 i257 = i266 + 16 | 0;
michael@0 7084 i269 = HEAP32[i257 >> 2] | 0;
michael@0 7085 if ((i269 | 0) != 0) {
michael@0 7086 HEAP32[i271 >> 2] = i269;
michael@0 7087 }
michael@0 7088 i269 = HEAP32[i267 >> 2] | 0;
michael@0 7089 if ((i269 | 0) != 0) {
michael@0 7090 i56 = i269;
michael@0 7091 do {
michael@0 7092 HEAP32[i56 + 4 >> 2] = i274;
michael@0 7093 i56 = HEAP32[i56 + 8 >> 2] | 0;
michael@0 7094 } while ((i56 | 0) != 0);
michael@0 7095 }
michael@0 7096 HEAP32[i267 >> 2] = 0;
michael@0 7097 HEAP32[i257 >> 2] = 0;
michael@0 7098 i56 = i266 + 8 | 0;
michael@0 7099 i115 = HEAP32[i56 >> 2] | 0;
michael@0 7100 if ((i115 | 0) == 0) {
michael@0 7101 i276 = i264;
michael@0 7102 } else {
michael@0 7103 i269 = i264;
michael@0 7104 i256 = i115;
michael@0 7105 while (1) {
michael@0 7106 i115 = HEAP32[i53 >> 2] | 0;
michael@0 7107 i260 = HEAP32[i52 >> 2] | 0;
michael@0 7108 if (i269) {
michael@0 7109 i277 = i256;
michael@0 7110 i278 = i115;
michael@0 7111 i279 = i260;
michael@0 7112 } else {
michael@0 7113 do {
michael@0 7114 if ((i115 | 0) == (i260 | 0)) {
michael@0 7115 i258 = (i115 | 0) == 0 ? 1 : i115 << 1;
michael@0 7116 if ((i115 | 0) >= (i258 | 0)) {
michael@0 7117 i280 = i115;
michael@0 7118 i281 = i115;
michael@0 7119 break;
michael@0 7120 }
michael@0 7121 if ((i258 | 0) == 0) {
michael@0 7122 i282 = 0;
michael@0 7123 i283 = i115;
michael@0 7124 } else {
michael@0 7125 i261 = __Z22btAlignedAllocInternalji(i258 << 2, 16) | 0;
michael@0 7126 i282 = i261;
michael@0 7127 i283 = HEAP32[i53 >> 2] | 0;
michael@0 7128 }
michael@0 7129 if ((i283 | 0) > 0) {
michael@0 7130 i261 = 0;
michael@0 7131 do {
michael@0 7132 i259 = i282 + (i261 << 2) | 0;
michael@0 7133 if ((i259 | 0) != 0) {
michael@0 7134 HEAP32[i259 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i261 << 2) >> 2];
michael@0 7135 }
michael@0 7136 i261 = i261 + 1 | 0;
michael@0 7137 } while ((i261 | 0) < (i283 | 0));
michael@0 7138 }
michael@0 7139 i261 = HEAP32[i32 >> 2] | 0;
michael@0 7140 if ((i261 | 0) == 0) {
michael@0 7141 i284 = i283;
michael@0 7142 } else {
michael@0 7143 if ((HEAP8[i54] | 0) == 0) {
michael@0 7144 i285 = i283;
michael@0 7145 } else {
michael@0 7146 __Z21btAlignedFreeInternalPv(i261);
michael@0 7147 i285 = HEAP32[i53 >> 2] | 0;
michael@0 7148 }
michael@0 7149 HEAP32[i32 >> 2] = 0;
michael@0 7150 i284 = i285;
michael@0 7151 }
michael@0 7152 HEAP8[i54] = 1;
michael@0 7153 HEAP32[i32 >> 2] = i282;
michael@0 7154 HEAP32[i52 >> 2] = i258;
michael@0 7155 i280 = i284;
michael@0 7156 i281 = i258;
michael@0 7157 } else {
michael@0 7158 i280 = i115;
michael@0 7159 i281 = i260;
michael@0 7160 }
michael@0 7161 } while (0);
michael@0 7162 i260 = (HEAP32[i32 >> 2] | 0) + (i280 << 2) | 0;
michael@0 7163 if ((i260 | 0) != 0) {
michael@0 7164 HEAP32[i260 >> 2] = i274;
michael@0 7165 }
michael@0 7166 i260 = i280 + 1 | 0;
michael@0 7167 HEAP32[i53 >> 2] = i260;
michael@0 7168 i277 = HEAP32[i56 >> 2] | 0;
michael@0 7169 i278 = i260;
michael@0 7170 i279 = i281;
michael@0 7171 }
michael@0 7172 i260 = i277 + 12 | 0;
michael@0 7173 do {
michael@0 7174 if ((i278 | 0) == (i279 | 0)) {
michael@0 7175 i115 = (i279 | 0) == 0 ? 1 : i279 << 1;
michael@0 7176 if ((i279 | 0) >= (i115 | 0)) {
michael@0 7177 i286 = i279;
michael@0 7178 break;
michael@0 7179 }
michael@0 7180 if ((i115 | 0) == 0) {
michael@0 7181 i287 = 0;
michael@0 7182 i288 = i279;
michael@0 7183 } else {
michael@0 7184 i261 = __Z22btAlignedAllocInternalji(i115 << 2, 16) | 0;
michael@0 7185 i287 = i261;
michael@0 7186 i288 = HEAP32[i53 >> 2] | 0;
michael@0 7187 }
michael@0 7188 if ((i288 | 0) > 0) {
michael@0 7189 i261 = 0;
michael@0 7190 do {
michael@0 7191 i259 = i287 + (i261 << 2) | 0;
michael@0 7192 if ((i259 | 0) != 0) {
michael@0 7193 HEAP32[i259 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i261 << 2) >> 2];
michael@0 7194 }
michael@0 7195 i261 = i261 + 1 | 0;
michael@0 7196 } while ((i261 | 0) < (i288 | 0));
michael@0 7197 }
michael@0 7198 i261 = HEAP32[i32 >> 2] | 0;
michael@0 7199 if ((i261 | 0) == 0) {
michael@0 7200 i289 = i288;
michael@0 7201 } else {
michael@0 7202 if ((HEAP8[i54] | 0) == 0) {
michael@0 7203 i290 = i288;
michael@0 7204 } else {
michael@0 7205 __Z21btAlignedFreeInternalPv(i261);
michael@0 7206 i290 = HEAP32[i53 >> 2] | 0;
michael@0 7207 }
michael@0 7208 HEAP32[i32 >> 2] = 0;
michael@0 7209 i289 = i290;
michael@0 7210 }
michael@0 7211 HEAP8[i54] = 1;
michael@0 7212 HEAP32[i32 >> 2] = i287;
michael@0 7213 HEAP32[i52 >> 2] = i115;
michael@0 7214 i286 = i289;
michael@0 7215 } else {
michael@0 7216 i286 = i278;
michael@0 7217 }
michael@0 7218 } while (0);
michael@0 7219 i261 = (HEAP32[i32 >> 2] | 0) + (i286 << 2) | 0;
michael@0 7220 if ((i261 | 0) != 0) {
michael@0 7221 HEAP32[i261 >> 2] = HEAP32[i260 >> 2];
michael@0 7222 }
michael@0 7223 HEAP32[i53 >> 2] = i286 + 1;
michael@0 7224 i261 = HEAP32[i56 >> 2] | 0;
michael@0 7225 i258 = i261 | 0;
michael@0 7226 i259 = HEAP32[i258 >> 2] | 0;
michael@0 7227 i55 = HEAP32[i261 + 8 >> 2] | 0;
michael@0 7228 if ((i259 | 0) == (i261 | 0)) {
michael@0 7229 HEAP32[(HEAP32[i55 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 7230 } else {
michael@0 7231 i51 = i261 + 4 | 0;
michael@0 7232 HEAP32[i259 + 4 >> 2] = HEAP32[i51 >> 2];
michael@0 7233 HEAP32[HEAP32[i51 >> 2] >> 2] = i259;
michael@0 7234 HEAP32[(HEAP32[i55 + 12 >> 2] | 0) + 8 >> 2] = i259;
michael@0 7235 }
michael@0 7236 i259 = i55 | 0;
michael@0 7237 i51 = HEAP32[i259 >> 2] | 0;
michael@0 7238 if ((i51 | 0) == (i55 | 0)) {
michael@0 7239 HEAP32[(HEAP32[i261 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 7240 } else {
michael@0 7241 i50 = i55 + 4 | 0;
michael@0 7242 HEAP32[i51 + 4 >> 2] = HEAP32[i50 >> 2];
michael@0 7243 HEAP32[HEAP32[i50 >> 2] >> 2] = i51;
michael@0 7244 HEAP32[(HEAP32[i261 + 12 >> 2] | 0) + 8 >> 2] = i51;
michael@0 7245 }
michael@0 7246 _memset(i261 | 0, 0, 20);
michael@0 7247 HEAP32[i258 >> 2] = HEAP32[i4 >> 2];
michael@0 7248 HEAP32[i4 >> 2] = i261;
michael@0 7249 _memset(i55 | 0, 0, 20);
michael@0 7250 HEAP32[i259 >> 2] = HEAP32[i4 >> 2];
michael@0 7251 HEAP32[i4 >> 2] = i55;
michael@0 7252 HEAP32[i30 >> 2] = (HEAP32[i30 >> 2] | 0) - 1;
michael@0 7253 i55 = HEAP32[i56 >> 2] | 0;
michael@0 7254 if ((i55 | 0) == 0) {
michael@0 7255 i276 = 1;
michael@0 7256 break;
michael@0 7257 } else {
michael@0 7258 i269 = 1;
michael@0 7259 i256 = i55;
michael@0 7260 }
michael@0 7261 }
michael@0 7262 }
michael@0 7263 i291 = i268 + 1 | 0;
michael@0 7264 i292 = HEAP32[i32 >> 2] | 0;
michael@0 7265 i256 = HEAP32[i292 + (i268 << 2) >> 2] | 0;
michael@0 7266 if ((i256 | 0) == 0) {
michael@0 7267 break;
michael@0 7268 } else {
michael@0 7269 i264 = i276;
michael@0 7270 i268 = i291;
michael@0 7271 i266 = i256;
michael@0 7272 }
michael@0 7273 }
michael@0 7274 if (!i276) {
michael@0 7275 i275 = i291;
michael@0 7276 break;
michael@0 7277 }
michael@0 7278 i266 = HEAP32[i53 >> 2] | 0;
michael@0 7279 do {
michael@0 7280 if ((i266 | 0) == (HEAP32[i52 >> 2] | 0)) {
michael@0 7281 i268 = (i266 | 0) == 0 ? 1 : i266 << 1;
michael@0 7282 if ((i266 | 0) >= (i268 | 0)) {
michael@0 7283 i293 = i266;
michael@0 7284 i294 = i292;
michael@0 7285 break;
michael@0 7286 }
michael@0 7287 if ((i268 | 0) == 0) {
michael@0 7288 i295 = 0;
michael@0 7289 i296 = i266;
michael@0 7290 } else {
michael@0 7291 i264 = __Z22btAlignedAllocInternalji(i268 << 2, 16) | 0;
michael@0 7292 i295 = i264;
michael@0 7293 i296 = HEAP32[i53 >> 2] | 0;
michael@0 7294 }
michael@0 7295 if ((i296 | 0) > 0) {
michael@0 7296 i264 = 0;
michael@0 7297 do {
michael@0 7298 i271 = i295 + (i264 << 2) | 0;
michael@0 7299 if ((i271 | 0) != 0) {
michael@0 7300 HEAP32[i271 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i264 << 2) >> 2];
michael@0 7301 }
michael@0 7302 i264 = i264 + 1 | 0;
michael@0 7303 } while ((i264 | 0) < (i296 | 0));
michael@0 7304 }
michael@0 7305 i264 = HEAP32[i32 >> 2] | 0;
michael@0 7306 if ((i264 | 0) == 0) {
michael@0 7307 i297 = i296;
michael@0 7308 } else {
michael@0 7309 if ((HEAP8[i54] | 0) == 0) {
michael@0 7310 i298 = i296;
michael@0 7311 } else {
michael@0 7312 __Z21btAlignedFreeInternalPv(i264);
michael@0 7313 i298 = HEAP32[i53 >> 2] | 0;
michael@0 7314 }
michael@0 7315 HEAP32[i32 >> 2] = 0;
michael@0 7316 i297 = i298;
michael@0 7317 }
michael@0 7318 HEAP8[i54] = 1;
michael@0 7319 HEAP32[i32 >> 2] = i295;
michael@0 7320 HEAP32[i52 >> 2] = i268;
michael@0 7321 i293 = i297;
michael@0 7322 i294 = i295;
michael@0 7323 } else {
michael@0 7324 i293 = i266;
michael@0 7325 i294 = i292;
michael@0 7326 }
michael@0 7327 } while (0);
michael@0 7328 i266 = i294 + (i293 << 2) | 0;
michael@0 7329 if ((i266 | 0) != 0) {
michael@0 7330 HEAP32[i266 >> 2] = 0;
michael@0 7331 }
michael@0 7332 HEAP32[i53 >> 2] = i293 + 1;
michael@0 7333 i275 = i291;
michael@0 7334 }
michael@0 7335 } while (0);
michael@0 7336 if ((i275 | 0) < (i262 | 0)) {
michael@0 7337 i273 = i275;
michael@0 7338 } else {
michael@0 7339 break;
michael@0 7340 }
michael@0 7341 }
michael@0 7342 i299 = i275;
michael@0 7343 i300 = HEAP32[i53 >> 2] | 0;
michael@0 7344 } else {
michael@0 7345 i299 = i270;
michael@0 7346 i300 = i262;
michael@0 7347 }
michael@0 7348 if ((i299 | 0) < (i300 | 0)) {
michael@0 7349 i270 = i299;
michael@0 7350 i262 = i300;
michael@0 7351 } else {
michael@0 7352 break;
michael@0 7353 }
michael@0 7354 }
michael@0 7355 if ((i300 | 0) <= 0) {
michael@0 7356 i301 = i300;
michael@0 7357 i49 = 1599;
michael@0 7358 }
michael@0 7359 } else {
michael@0 7360 i301 = i1;
michael@0 7361 i49 = 1599;
michael@0 7362 }
michael@0 7363 do {
michael@0 7364 if ((i49 | 0) == 1599) {
michael@0 7365 if ((i301 | 0) >= 0) {
michael@0 7366 break;
michael@0 7367 }
michael@0 7368 if ((HEAP32[i52 >> 2] | 0) < 0) {
michael@0 7369 i1 = HEAP32[i32 >> 2] | 0;
michael@0 7370 if ((i1 | 0) != 0) {
michael@0 7371 if ((HEAP8[i54] | 0) != 0) {
michael@0 7372 __Z21btAlignedFreeInternalPv(i1);
michael@0 7373 }
michael@0 7374 HEAP32[i32 >> 2] = 0;
michael@0 7375 }
michael@0 7376 HEAP8[i54] = 1;
michael@0 7377 HEAP32[i32 >> 2] = 0;
michael@0 7378 HEAP32[i52 >> 2] = 0;
michael@0 7379 i302 = i301;
michael@0 7380 } else {
michael@0 7381 i302 = i301;
michael@0 7382 }
michael@0 7383 do {
michael@0 7384 i1 = (HEAP32[i32 >> 2] | 0) + (i302 << 2) | 0;
michael@0 7385 if ((i1 | 0) != 0) {
michael@0 7386 HEAP32[i1 >> 2] = 0;
michael@0 7387 }
michael@0 7388 i302 = i302 + 1 | 0;
michael@0 7389 } while ((i302 | 0) < 0);
michael@0 7390 }
michael@0 7391 } while (0);
michael@0 7392 HEAP32[i53 >> 2] = 0;
michael@0 7393 HEAP32[i28 >> 2] = i35;
michael@0 7394 HEAP32[i36 >> 2] = i19;
michael@0 7395 HEAP32[i33 >> 2] = i18;
michael@0 7396 HEAP32[i2 + 24 >> 2] = -1;
michael@0 7397 i20 = 1;
michael@0 7398 STACKTOP = i5;
michael@0 7399 return i20 | 0;
michael@0 7400 }
michael@0 7401 function _malloc(i1) {
michael@0 7402 i1 = i1 | 0;
michael@0 7403 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0;
michael@0 7404 do {
michael@0 7405 if (i1 >>> 0 < 245) {
michael@0 7406 if (i1 >>> 0 < 11) {
michael@0 7407 i2 = 16;
michael@0 7408 } else {
michael@0 7409 i2 = i1 + 11 & -8;
michael@0 7410 }
michael@0 7411 i3 = i2 >>> 3;
michael@0 7412 i4 = HEAP32[3016] | 0;
michael@0 7413 i5 = i4 >>> (i3 >>> 0);
michael@0 7414 if ((i5 & 3 | 0) != 0) {
michael@0 7415 i6 = (i5 & 1 ^ 1) + i3 | 0;
michael@0 7416 i7 = i6 << 1;
michael@0 7417 i8 = 12104 + (i7 << 2) | 0;
michael@0 7418 i9 = 12104 + (i7 + 2 << 2) | 0;
michael@0 7419 i7 = HEAP32[i9 >> 2] | 0;
michael@0 7420 i10 = i7 + 8 | 0;
michael@0 7421 i11 = HEAP32[i10 >> 2] | 0;
michael@0 7422 do {
michael@0 7423 if ((i8 | 0) == (i11 | 0)) {
michael@0 7424 HEAP32[3016] = i4 & ~(1 << i6);
michael@0 7425 } else {
michael@0 7426 if (i11 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 7427 _abort();
michael@0 7428 return 0;
michael@0 7429 }
michael@0 7430 i12 = i11 + 12 | 0;
michael@0 7431 if ((HEAP32[i12 >> 2] | 0) == (i7 | 0)) {
michael@0 7432 HEAP32[i12 >> 2] = i8;
michael@0 7433 HEAP32[i9 >> 2] = i11;
michael@0 7434 break;
michael@0 7435 } else {
michael@0 7436 _abort();
michael@0 7437 return 0;
michael@0 7438 }
michael@0 7439 }
michael@0 7440 } while (0);
michael@0 7441 i11 = i6 << 3;
michael@0 7442 HEAP32[i7 + 4 >> 2] = i11 | 3;
michael@0 7443 i9 = i7 + (i11 | 4) | 0;
michael@0 7444 HEAP32[i9 >> 2] = HEAP32[i9 >> 2] | 1;
michael@0 7445 i13 = i10;
michael@0 7446 return i13 | 0;
michael@0 7447 }
michael@0 7448 if (i2 >>> 0 <= (HEAP32[3018] | 0) >>> 0) {
michael@0 7449 i14 = i2;
michael@0 7450 break;
michael@0 7451 }
michael@0 7452 if ((i5 | 0) != 0) {
michael@0 7453 i9 = 2 << i3;
michael@0 7454 i11 = i5 << i3 & (i9 | -i9);
michael@0 7455 i9 = (i11 & -i11) - 1 | 0;
michael@0 7456 i11 = i9 >>> 12 & 16;
michael@0 7457 i8 = i9 >>> (i11 >>> 0);
michael@0 7458 i9 = i8 >>> 5 & 8;
michael@0 7459 i12 = i8 >>> (i9 >>> 0);
michael@0 7460 i8 = i12 >>> 2 & 4;
michael@0 7461 i15 = i12 >>> (i8 >>> 0);
michael@0 7462 i12 = i15 >>> 1 & 2;
michael@0 7463 i16 = i15 >>> (i12 >>> 0);
michael@0 7464 i15 = i16 >>> 1 & 1;
michael@0 7465 i17 = (i9 | i11 | i8 | i12 | i15) + (i16 >>> (i15 >>> 0)) | 0;
michael@0 7466 i15 = i17 << 1;
michael@0 7467 i16 = 12104 + (i15 << 2) | 0;
michael@0 7468 i12 = 12104 + (i15 + 2 << 2) | 0;
michael@0 7469 i15 = HEAP32[i12 >> 2] | 0;
michael@0 7470 i8 = i15 + 8 | 0;
michael@0 7471 i11 = HEAP32[i8 >> 2] | 0;
michael@0 7472 do {
michael@0 7473 if ((i16 | 0) == (i11 | 0)) {
michael@0 7474 HEAP32[3016] = i4 & ~(1 << i17);
michael@0 7475 } else {
michael@0 7476 if (i11 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 7477 _abort();
michael@0 7478 return 0;
michael@0 7479 }
michael@0 7480 i9 = i11 + 12 | 0;
michael@0 7481 if ((HEAP32[i9 >> 2] | 0) == (i15 | 0)) {
michael@0 7482 HEAP32[i9 >> 2] = i16;
michael@0 7483 HEAP32[i12 >> 2] = i11;
michael@0 7484 break;
michael@0 7485 } else {
michael@0 7486 _abort();
michael@0 7487 return 0;
michael@0 7488 }
michael@0 7489 }
michael@0 7490 } while (0);
michael@0 7491 i11 = i17 << 3;
michael@0 7492 i12 = i11 - i2 | 0;
michael@0 7493 HEAP32[i15 + 4 >> 2] = i2 | 3;
michael@0 7494 i16 = i15;
michael@0 7495 i4 = i16 + i2 | 0;
michael@0 7496 HEAP32[i16 + (i2 | 4) >> 2] = i12 | 1;
michael@0 7497 HEAP32[i16 + i11 >> 2] = i12;
michael@0 7498 i11 = HEAP32[3018] | 0;
michael@0 7499 if ((i11 | 0) != 0) {
michael@0 7500 i16 = HEAP32[3021] | 0;
michael@0 7501 i3 = i11 >>> 3;
michael@0 7502 i11 = i3 << 1;
michael@0 7503 i5 = 12104 + (i11 << 2) | 0;
michael@0 7504 i10 = HEAP32[3016] | 0;
michael@0 7505 i7 = 1 << i3;
michael@0 7506 do {
michael@0 7507 if ((i10 & i7 | 0) == 0) {
michael@0 7508 HEAP32[3016] = i10 | i7;
michael@0 7509 i18 = i5;
michael@0 7510 i19 = 12104 + (i11 + 2 << 2) | 0;
michael@0 7511 } else {
michael@0 7512 i3 = 12104 + (i11 + 2 << 2) | 0;
michael@0 7513 i6 = HEAP32[i3 >> 2] | 0;
michael@0 7514 if (i6 >>> 0 >= (HEAP32[3020] | 0) >>> 0) {
michael@0 7515 i18 = i6;
michael@0 7516 i19 = i3;
michael@0 7517 break;
michael@0 7518 }
michael@0 7519 _abort();
michael@0 7520 return 0;
michael@0 7521 }
michael@0 7522 } while (0);
michael@0 7523 HEAP32[i19 >> 2] = i16;
michael@0 7524 HEAP32[i18 + 12 >> 2] = i16;
michael@0 7525 HEAP32[i16 + 8 >> 2] = i18;
michael@0 7526 HEAP32[i16 + 12 >> 2] = i5;
michael@0 7527 }
michael@0 7528 HEAP32[3018] = i12;
michael@0 7529 HEAP32[3021] = i4;
michael@0 7530 i13 = i8;
michael@0 7531 return i13 | 0;
michael@0 7532 }
michael@0 7533 i11 = HEAP32[3017] | 0;
michael@0 7534 if ((i11 | 0) == 0) {
michael@0 7535 i14 = i2;
michael@0 7536 break;
michael@0 7537 }
michael@0 7538 i7 = (i11 & -i11) - 1 | 0;
michael@0 7539 i11 = i7 >>> 12 & 16;
michael@0 7540 i10 = i7 >>> (i11 >>> 0);
michael@0 7541 i7 = i10 >>> 5 & 8;
michael@0 7542 i15 = i10 >>> (i7 >>> 0);
michael@0 7543 i10 = i15 >>> 2 & 4;
michael@0 7544 i17 = i15 >>> (i10 >>> 0);
michael@0 7545 i15 = i17 >>> 1 & 2;
michael@0 7546 i3 = i17 >>> (i15 >>> 0);
michael@0 7547 i17 = i3 >>> 1 & 1;
michael@0 7548 i6 = HEAP32[12368 + ((i7 | i11 | i10 | i15 | i17) + (i3 >>> (i17 >>> 0)) << 2) >> 2] | 0;
michael@0 7549 i17 = i6;
michael@0 7550 i3 = i6;
michael@0 7551 i15 = (HEAP32[i6 + 4 >> 2] & -8) - i2 | 0;
michael@0 7552 while (1) {
michael@0 7553 i6 = HEAP32[i17 + 16 >> 2] | 0;
michael@0 7554 if ((i6 | 0) == 0) {
michael@0 7555 i10 = HEAP32[i17 + 20 >> 2] | 0;
michael@0 7556 if ((i10 | 0) == 0) {
michael@0 7557 break;
michael@0 7558 } else {
michael@0 7559 i20 = i10;
michael@0 7560 }
michael@0 7561 } else {
michael@0 7562 i20 = i6;
michael@0 7563 }
michael@0 7564 i6 = (HEAP32[i20 + 4 >> 2] & -8) - i2 | 0;
michael@0 7565 i10 = i6 >>> 0 < i15 >>> 0;
michael@0 7566 i17 = i20;
michael@0 7567 i3 = i10 ? i20 : i3;
michael@0 7568 i15 = i10 ? i6 : i15;
michael@0 7569 }
michael@0 7570 i17 = i3;
michael@0 7571 i8 = HEAP32[3020] | 0;
michael@0 7572 if (i17 >>> 0 < i8 >>> 0) {
michael@0 7573 _abort();
michael@0 7574 return 0;
michael@0 7575 }
michael@0 7576 i4 = i17 + i2 | 0;
michael@0 7577 i12 = i4;
michael@0 7578 if (i17 >>> 0 >= i4 >>> 0) {
michael@0 7579 _abort();
michael@0 7580 return 0;
michael@0 7581 }
michael@0 7582 i4 = HEAP32[i3 + 24 >> 2] | 0;
michael@0 7583 i5 = HEAP32[i3 + 12 >> 2] | 0;
michael@0 7584 do {
michael@0 7585 if ((i5 | 0) == (i3 | 0)) {
michael@0 7586 i16 = i3 + 20 | 0;
michael@0 7587 i6 = HEAP32[i16 >> 2] | 0;
michael@0 7588 if ((i6 | 0) == 0) {
michael@0 7589 i10 = i3 + 16 | 0;
michael@0 7590 i11 = HEAP32[i10 >> 2] | 0;
michael@0 7591 if ((i11 | 0) == 0) {
michael@0 7592 i21 = 0;
michael@0 7593 break;
michael@0 7594 } else {
michael@0 7595 i22 = i11;
michael@0 7596 i23 = i10;
michael@0 7597 }
michael@0 7598 } else {
michael@0 7599 i22 = i6;
michael@0 7600 i23 = i16;
michael@0 7601 }
michael@0 7602 while (1) {
michael@0 7603 i16 = i22 + 20 | 0;
michael@0 7604 i6 = HEAP32[i16 >> 2] | 0;
michael@0 7605 if ((i6 | 0) != 0) {
michael@0 7606 i22 = i6;
michael@0 7607 i23 = i16;
michael@0 7608 continue;
michael@0 7609 }
michael@0 7610 i16 = i22 + 16 | 0;
michael@0 7611 i6 = HEAP32[i16 >> 2] | 0;
michael@0 7612 if ((i6 | 0) == 0) {
michael@0 7613 break;
michael@0 7614 } else {
michael@0 7615 i22 = i6;
michael@0 7616 i23 = i16;
michael@0 7617 }
michael@0 7618 }
michael@0 7619 if (i23 >>> 0 < i8 >>> 0) {
michael@0 7620 _abort();
michael@0 7621 return 0;
michael@0 7622 } else {
michael@0 7623 HEAP32[i23 >> 2] = 0;
michael@0 7624 i21 = i22;
michael@0 7625 break;
michael@0 7626 }
michael@0 7627 } else {
michael@0 7628 i16 = HEAP32[i3 + 8 >> 2] | 0;
michael@0 7629 if (i16 >>> 0 < i8 >>> 0) {
michael@0 7630 _abort();
michael@0 7631 return 0;
michael@0 7632 }
michael@0 7633 i6 = i16 + 12 | 0;
michael@0 7634 if ((HEAP32[i6 >> 2] | 0) != (i3 | 0)) {
michael@0 7635 _abort();
michael@0 7636 return 0;
michael@0 7637 }
michael@0 7638 i10 = i5 + 8 | 0;
michael@0 7639 if ((HEAP32[i10 >> 2] | 0) == (i3 | 0)) {
michael@0 7640 HEAP32[i6 >> 2] = i5;
michael@0 7641 HEAP32[i10 >> 2] = i16;
michael@0 7642 i21 = i5;
michael@0 7643 break;
michael@0 7644 } else {
michael@0 7645 _abort();
michael@0 7646 return 0;
michael@0 7647 }
michael@0 7648 }
michael@0 7649 } while (0);
michael@0 7650 L78 : do {
michael@0 7651 if ((i4 | 0) != 0) {
michael@0 7652 i5 = i3 + 28 | 0;
michael@0 7653 i8 = 12368 + (HEAP32[i5 >> 2] << 2) | 0;
michael@0 7654 do {
michael@0 7655 if ((i3 | 0) == (HEAP32[i8 >> 2] | 0)) {
michael@0 7656 HEAP32[i8 >> 2] = i21;
michael@0 7657 if ((i21 | 0) != 0) {
michael@0 7658 break;
michael@0 7659 }
michael@0 7660 HEAP32[3017] = HEAP32[3017] & ~(1 << HEAP32[i5 >> 2]);
michael@0 7661 break L78;
michael@0 7662 } else {
michael@0 7663 if (i4 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 7664 _abort();
michael@0 7665 return 0;
michael@0 7666 }
michael@0 7667 i16 = i4 + 16 | 0;
michael@0 7668 if ((HEAP32[i16 >> 2] | 0) == (i3 | 0)) {
michael@0 7669 HEAP32[i16 >> 2] = i21;
michael@0 7670 } else {
michael@0 7671 HEAP32[i4 + 20 >> 2] = i21;
michael@0 7672 }
michael@0 7673 if ((i21 | 0) == 0) {
michael@0 7674 break L78;
michael@0 7675 }
michael@0 7676 }
michael@0 7677 } while (0);
michael@0 7678 if (i21 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 7679 _abort();
michael@0 7680 return 0;
michael@0 7681 }
michael@0 7682 HEAP32[i21 + 24 >> 2] = i4;
michael@0 7683 i5 = HEAP32[i3 + 16 >> 2] | 0;
michael@0 7684 do {
michael@0 7685 if ((i5 | 0) != 0) {
michael@0 7686 if (i5 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 7687 _abort();
michael@0 7688 return 0;
michael@0 7689 } else {
michael@0 7690 HEAP32[i21 + 16 >> 2] = i5;
michael@0 7691 HEAP32[i5 + 24 >> 2] = i21;
michael@0 7692 break;
michael@0 7693 }
michael@0 7694 }
michael@0 7695 } while (0);
michael@0 7696 i5 = HEAP32[i3 + 20 >> 2] | 0;
michael@0 7697 if ((i5 | 0) == 0) {
michael@0 7698 break;
michael@0 7699 }
michael@0 7700 if (i5 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 7701 _abort();
michael@0 7702 return 0;
michael@0 7703 } else {
michael@0 7704 HEAP32[i21 + 20 >> 2] = i5;
michael@0 7705 HEAP32[i5 + 24 >> 2] = i21;
michael@0 7706 break;
michael@0 7707 }
michael@0 7708 }
michael@0 7709 } while (0);
michael@0 7710 if (i15 >>> 0 < 16) {
michael@0 7711 i4 = i15 + i2 | 0;
michael@0 7712 HEAP32[i3 + 4 >> 2] = i4 | 3;
michael@0 7713 i5 = i17 + (i4 + 4) | 0;
michael@0 7714 HEAP32[i5 >> 2] = HEAP32[i5 >> 2] | 1;
michael@0 7715 } else {
michael@0 7716 HEAP32[i3 + 4 >> 2] = i2 | 3;
michael@0 7717 HEAP32[i17 + (i2 | 4) >> 2] = i15 | 1;
michael@0 7718 HEAP32[i17 + (i15 + i2) >> 2] = i15;
michael@0 7719 i5 = HEAP32[3018] | 0;
michael@0 7720 if ((i5 | 0) != 0) {
michael@0 7721 i4 = HEAP32[3021] | 0;
michael@0 7722 i8 = i5 >>> 3;
michael@0 7723 i5 = i8 << 1;
michael@0 7724 i16 = 12104 + (i5 << 2) | 0;
michael@0 7725 i10 = HEAP32[3016] | 0;
michael@0 7726 i6 = 1 << i8;
michael@0 7727 do {
michael@0 7728 if ((i10 & i6 | 0) == 0) {
michael@0 7729 HEAP32[3016] = i10 | i6;
michael@0 7730 i24 = i16;
michael@0 7731 i25 = 12104 + (i5 + 2 << 2) | 0;
michael@0 7732 } else {
michael@0 7733 i8 = 12104 + (i5 + 2 << 2) | 0;
michael@0 7734 i11 = HEAP32[i8 >> 2] | 0;
michael@0 7735 if (i11 >>> 0 >= (HEAP32[3020] | 0) >>> 0) {
michael@0 7736 i24 = i11;
michael@0 7737 i25 = i8;
michael@0 7738 break;
michael@0 7739 }
michael@0 7740 _abort();
michael@0 7741 return 0;
michael@0 7742 }
michael@0 7743 } while (0);
michael@0 7744 HEAP32[i25 >> 2] = i4;
michael@0 7745 HEAP32[i24 + 12 >> 2] = i4;
michael@0 7746 HEAP32[i4 + 8 >> 2] = i24;
michael@0 7747 HEAP32[i4 + 12 >> 2] = i16;
michael@0 7748 }
michael@0 7749 HEAP32[3018] = i15;
michael@0 7750 HEAP32[3021] = i12;
michael@0 7751 }
michael@0 7752 i5 = i3 + 8 | 0;
michael@0 7753 if ((i5 | 0) == 0) {
michael@0 7754 i14 = i2;
michael@0 7755 break;
michael@0 7756 } else {
michael@0 7757 i13 = i5;
michael@0 7758 }
michael@0 7759 return i13 | 0;
michael@0 7760 } else {
michael@0 7761 if (i1 >>> 0 > 4294967231) {
michael@0 7762 i14 = -1;
michael@0 7763 break;
michael@0 7764 }
michael@0 7765 i5 = i1 + 11 | 0;
michael@0 7766 i6 = i5 & -8;
michael@0 7767 i10 = HEAP32[3017] | 0;
michael@0 7768 if ((i10 | 0) == 0) {
michael@0 7769 i14 = i6;
michael@0 7770 break;
michael@0 7771 }
michael@0 7772 i17 = -i6 | 0;
michael@0 7773 i8 = i5 >>> 8;
michael@0 7774 do {
michael@0 7775 if ((i8 | 0) == 0) {
michael@0 7776 i26 = 0;
michael@0 7777 } else {
michael@0 7778 if (i6 >>> 0 > 16777215) {
michael@0 7779 i26 = 31;
michael@0 7780 break;
michael@0 7781 }
michael@0 7782 i5 = (i8 + 1048320 | 0) >>> 16 & 8;
michael@0 7783 i11 = i8 << i5;
michael@0 7784 i7 = (i11 + 520192 | 0) >>> 16 & 4;
michael@0 7785 i9 = i11 << i7;
michael@0 7786 i11 = (i9 + 245760 | 0) >>> 16 & 2;
michael@0 7787 i27 = 14 - (i7 | i5 | i11) + (i9 << i11 >>> 15) | 0;
michael@0 7788 i26 = i6 >>> ((i27 + 7 | 0) >>> 0) & 1 | i27 << 1;
michael@0 7789 }
michael@0 7790 } while (0);
michael@0 7791 i8 = HEAP32[12368 + (i26 << 2) >> 2] | 0;
michael@0 7792 L126 : do {
michael@0 7793 if ((i8 | 0) == 0) {
michael@0 7794 i28 = 0;
michael@0 7795 i29 = i17;
michael@0 7796 i30 = 0;
michael@0 7797 } else {
michael@0 7798 if ((i26 | 0) == 31) {
michael@0 7799 i31 = 0;
michael@0 7800 } else {
michael@0 7801 i31 = 25 - (i26 >>> 1) | 0;
michael@0 7802 }
michael@0 7803 i3 = 0;
michael@0 7804 i12 = i17;
michael@0 7805 i15 = i8;
michael@0 7806 i16 = i6 << i31;
michael@0 7807 i4 = 0;
michael@0 7808 while (1) {
michael@0 7809 i27 = HEAP32[i15 + 4 >> 2] & -8;
michael@0 7810 i11 = i27 - i6 | 0;
michael@0 7811 if (i11 >>> 0 < i12 >>> 0) {
michael@0 7812 if ((i27 | 0) == (i6 | 0)) {
michael@0 7813 i28 = i15;
michael@0 7814 i29 = i11;
michael@0 7815 i30 = i15;
michael@0 7816 break L126;
michael@0 7817 } else {
michael@0 7818 i32 = i15;
michael@0 7819 i33 = i11;
michael@0 7820 }
michael@0 7821 } else {
michael@0 7822 i32 = i3;
michael@0 7823 i33 = i12;
michael@0 7824 }
michael@0 7825 i11 = HEAP32[i15 + 20 >> 2] | 0;
michael@0 7826 i27 = HEAP32[i15 + 16 + (i16 >>> 31 << 2) >> 2] | 0;
michael@0 7827 i9 = (i11 | 0) == 0 | (i11 | 0) == (i27 | 0) ? i4 : i11;
michael@0 7828 if ((i27 | 0) == 0) {
michael@0 7829 i28 = i32;
michael@0 7830 i29 = i33;
michael@0 7831 i30 = i9;
michael@0 7832 break;
michael@0 7833 } else {
michael@0 7834 i3 = i32;
michael@0 7835 i12 = i33;
michael@0 7836 i15 = i27;
michael@0 7837 i16 = i16 << 1;
michael@0 7838 i4 = i9;
michael@0 7839 }
michael@0 7840 }
michael@0 7841 }
michael@0 7842 } while (0);
michael@0 7843 if ((i30 | 0) == 0 & (i28 | 0) == 0) {
michael@0 7844 i8 = 2 << i26;
michael@0 7845 i17 = i10 & (i8 | -i8);
michael@0 7846 if ((i17 | 0) == 0) {
michael@0 7847 i14 = i6;
michael@0 7848 break;
michael@0 7849 }
michael@0 7850 i8 = (i17 & -i17) - 1 | 0;
michael@0 7851 i17 = i8 >>> 12 & 16;
michael@0 7852 i4 = i8 >>> (i17 >>> 0);
michael@0 7853 i8 = i4 >>> 5 & 8;
michael@0 7854 i16 = i4 >>> (i8 >>> 0);
michael@0 7855 i4 = i16 >>> 2 & 4;
michael@0 7856 i15 = i16 >>> (i4 >>> 0);
michael@0 7857 i16 = i15 >>> 1 & 2;
michael@0 7858 i12 = i15 >>> (i16 >>> 0);
michael@0 7859 i15 = i12 >>> 1 & 1;
michael@0 7860 i34 = HEAP32[12368 + ((i8 | i17 | i4 | i16 | i15) + (i12 >>> (i15 >>> 0)) << 2) >> 2] | 0;
michael@0 7861 } else {
michael@0 7862 i34 = i30;
michael@0 7863 }
michael@0 7864 if ((i34 | 0) == 0) {
michael@0 7865 i35 = i29;
michael@0 7866 i36 = i28;
michael@0 7867 } else {
michael@0 7868 i15 = i34;
michael@0 7869 i12 = i29;
michael@0 7870 i16 = i28;
michael@0 7871 while (1) {
michael@0 7872 i4 = (HEAP32[i15 + 4 >> 2] & -8) - i6 | 0;
michael@0 7873 i17 = i4 >>> 0 < i12 >>> 0;
michael@0 7874 i8 = i17 ? i4 : i12;
michael@0 7875 i4 = i17 ? i15 : i16;
michael@0 7876 i17 = HEAP32[i15 + 16 >> 2] | 0;
michael@0 7877 if ((i17 | 0) != 0) {
michael@0 7878 i15 = i17;
michael@0 7879 i12 = i8;
michael@0 7880 i16 = i4;
michael@0 7881 continue;
michael@0 7882 }
michael@0 7883 i17 = HEAP32[i15 + 20 >> 2] | 0;
michael@0 7884 if ((i17 | 0) == 0) {
michael@0 7885 i35 = i8;
michael@0 7886 i36 = i4;
michael@0 7887 break;
michael@0 7888 } else {
michael@0 7889 i15 = i17;
michael@0 7890 i12 = i8;
michael@0 7891 i16 = i4;
michael@0 7892 }
michael@0 7893 }
michael@0 7894 }
michael@0 7895 if ((i36 | 0) == 0) {
michael@0 7896 i14 = i6;
michael@0 7897 break;
michael@0 7898 }
michael@0 7899 if (i35 >>> 0 >= ((HEAP32[3018] | 0) - i6 | 0) >>> 0) {
michael@0 7900 i14 = i6;
michael@0 7901 break;
michael@0 7902 }
michael@0 7903 i16 = i36;
michael@0 7904 i12 = HEAP32[3020] | 0;
michael@0 7905 if (i16 >>> 0 < i12 >>> 0) {
michael@0 7906 _abort();
michael@0 7907 return 0;
michael@0 7908 }
michael@0 7909 i15 = i16 + i6 | 0;
michael@0 7910 i10 = i15;
michael@0 7911 if (i16 >>> 0 >= i15 >>> 0) {
michael@0 7912 _abort();
michael@0 7913 return 0;
michael@0 7914 }
michael@0 7915 i4 = HEAP32[i36 + 24 >> 2] | 0;
michael@0 7916 i8 = HEAP32[i36 + 12 >> 2] | 0;
michael@0 7917 do {
michael@0 7918 if ((i8 | 0) == (i36 | 0)) {
michael@0 7919 i17 = i36 + 20 | 0;
michael@0 7920 i3 = HEAP32[i17 >> 2] | 0;
michael@0 7921 if ((i3 | 0) == 0) {
michael@0 7922 i9 = i36 + 16 | 0;
michael@0 7923 i27 = HEAP32[i9 >> 2] | 0;
michael@0 7924 if ((i27 | 0) == 0) {
michael@0 7925 i37 = 0;
michael@0 7926 break;
michael@0 7927 } else {
michael@0 7928 i38 = i27;
michael@0 7929 i39 = i9;
michael@0 7930 }
michael@0 7931 } else {
michael@0 7932 i38 = i3;
michael@0 7933 i39 = i17;
michael@0 7934 }
michael@0 7935 while (1) {
michael@0 7936 i17 = i38 + 20 | 0;
michael@0 7937 i3 = HEAP32[i17 >> 2] | 0;
michael@0 7938 if ((i3 | 0) != 0) {
michael@0 7939 i38 = i3;
michael@0 7940 i39 = i17;
michael@0 7941 continue;
michael@0 7942 }
michael@0 7943 i17 = i38 + 16 | 0;
michael@0 7944 i3 = HEAP32[i17 >> 2] | 0;
michael@0 7945 if ((i3 | 0) == 0) {
michael@0 7946 break;
michael@0 7947 } else {
michael@0 7948 i38 = i3;
michael@0 7949 i39 = i17;
michael@0 7950 }
michael@0 7951 }
michael@0 7952 if (i39 >>> 0 < i12 >>> 0) {
michael@0 7953 _abort();
michael@0 7954 return 0;
michael@0 7955 } else {
michael@0 7956 HEAP32[i39 >> 2] = 0;
michael@0 7957 i37 = i38;
michael@0 7958 break;
michael@0 7959 }
michael@0 7960 } else {
michael@0 7961 i17 = HEAP32[i36 + 8 >> 2] | 0;
michael@0 7962 if (i17 >>> 0 < i12 >>> 0) {
michael@0 7963 _abort();
michael@0 7964 return 0;
michael@0 7965 }
michael@0 7966 i3 = i17 + 12 | 0;
michael@0 7967 if ((HEAP32[i3 >> 2] | 0) != (i36 | 0)) {
michael@0 7968 _abort();
michael@0 7969 return 0;
michael@0 7970 }
michael@0 7971 i9 = i8 + 8 | 0;
michael@0 7972 if ((HEAP32[i9 >> 2] | 0) == (i36 | 0)) {
michael@0 7973 HEAP32[i3 >> 2] = i8;
michael@0 7974 HEAP32[i9 >> 2] = i17;
michael@0 7975 i37 = i8;
michael@0 7976 break;
michael@0 7977 } else {
michael@0 7978 _abort();
michael@0 7979 return 0;
michael@0 7980 }
michael@0 7981 }
michael@0 7982 } while (0);
michael@0 7983 L176 : do {
michael@0 7984 if ((i4 | 0) != 0) {
michael@0 7985 i8 = i36 + 28 | 0;
michael@0 7986 i12 = 12368 + (HEAP32[i8 >> 2] << 2) | 0;
michael@0 7987 do {
michael@0 7988 if ((i36 | 0) == (HEAP32[i12 >> 2] | 0)) {
michael@0 7989 HEAP32[i12 >> 2] = i37;
michael@0 7990 if ((i37 | 0) != 0) {
michael@0 7991 break;
michael@0 7992 }
michael@0 7993 HEAP32[3017] = HEAP32[3017] & ~(1 << HEAP32[i8 >> 2]);
michael@0 7994 break L176;
michael@0 7995 } else {
michael@0 7996 if (i4 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 7997 _abort();
michael@0 7998 return 0;
michael@0 7999 }
michael@0 8000 i17 = i4 + 16 | 0;
michael@0 8001 if ((HEAP32[i17 >> 2] | 0) == (i36 | 0)) {
michael@0 8002 HEAP32[i17 >> 2] = i37;
michael@0 8003 } else {
michael@0 8004 HEAP32[i4 + 20 >> 2] = i37;
michael@0 8005 }
michael@0 8006 if ((i37 | 0) == 0) {
michael@0 8007 break L176;
michael@0 8008 }
michael@0 8009 }
michael@0 8010 } while (0);
michael@0 8011 if (i37 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8012 _abort();
michael@0 8013 return 0;
michael@0 8014 }
michael@0 8015 HEAP32[i37 + 24 >> 2] = i4;
michael@0 8016 i8 = HEAP32[i36 + 16 >> 2] | 0;
michael@0 8017 do {
michael@0 8018 if ((i8 | 0) != 0) {
michael@0 8019 if (i8 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8020 _abort();
michael@0 8021 return 0;
michael@0 8022 } else {
michael@0 8023 HEAP32[i37 + 16 >> 2] = i8;
michael@0 8024 HEAP32[i8 + 24 >> 2] = i37;
michael@0 8025 break;
michael@0 8026 }
michael@0 8027 }
michael@0 8028 } while (0);
michael@0 8029 i8 = HEAP32[i36 + 20 >> 2] | 0;
michael@0 8030 if ((i8 | 0) == 0) {
michael@0 8031 break;
michael@0 8032 }
michael@0 8033 if (i8 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8034 _abort();
michael@0 8035 return 0;
michael@0 8036 } else {
michael@0 8037 HEAP32[i37 + 20 >> 2] = i8;
michael@0 8038 HEAP32[i8 + 24 >> 2] = i37;
michael@0 8039 break;
michael@0 8040 }
michael@0 8041 }
michael@0 8042 } while (0);
michael@0 8043 do {
michael@0 8044 if (i35 >>> 0 < 16) {
michael@0 8045 i4 = i35 + i6 | 0;
michael@0 8046 HEAP32[i36 + 4 >> 2] = i4 | 3;
michael@0 8047 i8 = i16 + (i4 + 4) | 0;
michael@0 8048 HEAP32[i8 >> 2] = HEAP32[i8 >> 2] | 1;
michael@0 8049 } else {
michael@0 8050 HEAP32[i36 + 4 >> 2] = i6 | 3;
michael@0 8051 HEAP32[i16 + (i6 | 4) >> 2] = i35 | 1;
michael@0 8052 HEAP32[i16 + (i35 + i6) >> 2] = i35;
michael@0 8053 i8 = i35 >>> 3;
michael@0 8054 if (i35 >>> 0 < 256) {
michael@0 8055 i4 = i8 << 1;
michael@0 8056 i12 = 12104 + (i4 << 2) | 0;
michael@0 8057 i17 = HEAP32[3016] | 0;
michael@0 8058 i9 = 1 << i8;
michael@0 8059 do {
michael@0 8060 if ((i17 & i9 | 0) == 0) {
michael@0 8061 HEAP32[3016] = i17 | i9;
michael@0 8062 i40 = i12;
michael@0 8063 i41 = 12104 + (i4 + 2 << 2) | 0;
michael@0 8064 } else {
michael@0 8065 i8 = 12104 + (i4 + 2 << 2) | 0;
michael@0 8066 i3 = HEAP32[i8 >> 2] | 0;
michael@0 8067 if (i3 >>> 0 >= (HEAP32[3020] | 0) >>> 0) {
michael@0 8068 i40 = i3;
michael@0 8069 i41 = i8;
michael@0 8070 break;
michael@0 8071 }
michael@0 8072 _abort();
michael@0 8073 return 0;
michael@0 8074 }
michael@0 8075 } while (0);
michael@0 8076 HEAP32[i41 >> 2] = i10;
michael@0 8077 HEAP32[i40 + 12 >> 2] = i10;
michael@0 8078 HEAP32[i16 + (i6 + 8) >> 2] = i40;
michael@0 8079 HEAP32[i16 + (i6 + 12) >> 2] = i12;
michael@0 8080 break;
michael@0 8081 }
michael@0 8082 i4 = i15;
michael@0 8083 i9 = i35 >>> 8;
michael@0 8084 do {
michael@0 8085 if ((i9 | 0) == 0) {
michael@0 8086 i42 = 0;
michael@0 8087 } else {
michael@0 8088 if (i35 >>> 0 > 16777215) {
michael@0 8089 i42 = 31;
michael@0 8090 break;
michael@0 8091 }
michael@0 8092 i17 = (i9 + 1048320 | 0) >>> 16 & 8;
michael@0 8093 i8 = i9 << i17;
michael@0 8094 i3 = (i8 + 520192 | 0) >>> 16 & 4;
michael@0 8095 i27 = i8 << i3;
michael@0 8096 i8 = (i27 + 245760 | 0) >>> 16 & 2;
michael@0 8097 i11 = 14 - (i3 | i17 | i8) + (i27 << i8 >>> 15) | 0;
michael@0 8098 i42 = i35 >>> ((i11 + 7 | 0) >>> 0) & 1 | i11 << 1;
michael@0 8099 }
michael@0 8100 } while (0);
michael@0 8101 i9 = 12368 + (i42 << 2) | 0;
michael@0 8102 HEAP32[i16 + (i6 + 28) >> 2] = i42;
michael@0 8103 HEAP32[i16 + (i6 + 20) >> 2] = 0;
michael@0 8104 HEAP32[i16 + (i6 + 16) >> 2] = 0;
michael@0 8105 i12 = HEAP32[3017] | 0;
michael@0 8106 i11 = 1 << i42;
michael@0 8107 if ((i12 & i11 | 0) == 0) {
michael@0 8108 HEAP32[3017] = i12 | i11;
michael@0 8109 HEAP32[i9 >> 2] = i4;
michael@0 8110 HEAP32[i16 + (i6 + 24) >> 2] = i9;
michael@0 8111 HEAP32[i16 + (i6 + 12) >> 2] = i4;
michael@0 8112 HEAP32[i16 + (i6 + 8) >> 2] = i4;
michael@0 8113 break;
michael@0 8114 }
michael@0 8115 if ((i42 | 0) == 31) {
michael@0 8116 i43 = 0;
michael@0 8117 } else {
michael@0 8118 i43 = 25 - (i42 >>> 1) | 0;
michael@0 8119 }
michael@0 8120 i11 = i35 << i43;
michael@0 8121 i12 = HEAP32[i9 >> 2] | 0;
michael@0 8122 while (1) {
michael@0 8123 if ((HEAP32[i12 + 4 >> 2] & -8 | 0) == (i35 | 0)) {
michael@0 8124 break;
michael@0 8125 }
michael@0 8126 i44 = i12 + 16 + (i11 >>> 31 << 2) | 0;
michael@0 8127 i9 = HEAP32[i44 >> 2] | 0;
michael@0 8128 if ((i9 | 0) == 0) {
michael@0 8129 i45 = 151;
michael@0 8130 break;
michael@0 8131 } else {
michael@0 8132 i11 = i11 << 1;
michael@0 8133 i12 = i9;
michael@0 8134 }
michael@0 8135 }
michael@0 8136 if ((i45 | 0) == 151) {
michael@0 8137 if (i44 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8138 _abort();
michael@0 8139 return 0;
michael@0 8140 } else {
michael@0 8141 HEAP32[i44 >> 2] = i4;
michael@0 8142 HEAP32[i16 + (i6 + 24) >> 2] = i12;
michael@0 8143 HEAP32[i16 + (i6 + 12) >> 2] = i4;
michael@0 8144 HEAP32[i16 + (i6 + 8) >> 2] = i4;
michael@0 8145 break;
michael@0 8146 }
michael@0 8147 }
michael@0 8148 i11 = i12 + 8 | 0;
michael@0 8149 i9 = HEAP32[i11 >> 2] | 0;
michael@0 8150 i8 = HEAP32[3020] | 0;
michael@0 8151 if (i12 >>> 0 < i8 >>> 0) {
michael@0 8152 _abort();
michael@0 8153 return 0;
michael@0 8154 }
michael@0 8155 if (i9 >>> 0 < i8 >>> 0) {
michael@0 8156 _abort();
michael@0 8157 return 0;
michael@0 8158 } else {
michael@0 8159 HEAP32[i9 + 12 >> 2] = i4;
michael@0 8160 HEAP32[i11 >> 2] = i4;
michael@0 8161 HEAP32[i16 + (i6 + 8) >> 2] = i9;
michael@0 8162 HEAP32[i16 + (i6 + 12) >> 2] = i12;
michael@0 8163 HEAP32[i16 + (i6 + 24) >> 2] = 0;
michael@0 8164 break;
michael@0 8165 }
michael@0 8166 }
michael@0 8167 } while (0);
michael@0 8168 i16 = i36 + 8 | 0;
michael@0 8169 if ((i16 | 0) == 0) {
michael@0 8170 i14 = i6;
michael@0 8171 break;
michael@0 8172 } else {
michael@0 8173 i13 = i16;
michael@0 8174 }
michael@0 8175 return i13 | 0;
michael@0 8176 }
michael@0 8177 } while (0);
michael@0 8178 i36 = HEAP32[3018] | 0;
michael@0 8179 if (i14 >>> 0 <= i36 >>> 0) {
michael@0 8180 i44 = i36 - i14 | 0;
michael@0 8181 i35 = HEAP32[3021] | 0;
michael@0 8182 if (i44 >>> 0 > 15) {
michael@0 8183 i43 = i35;
michael@0 8184 HEAP32[3021] = i43 + i14;
michael@0 8185 HEAP32[3018] = i44;
michael@0 8186 HEAP32[i43 + (i14 + 4) >> 2] = i44 | 1;
michael@0 8187 HEAP32[i43 + i36 >> 2] = i44;
michael@0 8188 HEAP32[i35 + 4 >> 2] = i14 | 3;
michael@0 8189 } else {
michael@0 8190 HEAP32[3018] = 0;
michael@0 8191 HEAP32[3021] = 0;
michael@0 8192 HEAP32[i35 + 4 >> 2] = i36 | 3;
michael@0 8193 i44 = i35 + (i36 + 4) | 0;
michael@0 8194 HEAP32[i44 >> 2] = HEAP32[i44 >> 2] | 1;
michael@0 8195 }
michael@0 8196 i13 = i35 + 8 | 0;
michael@0 8197 return i13 | 0;
michael@0 8198 }
michael@0 8199 i35 = HEAP32[3019] | 0;
michael@0 8200 if (i14 >>> 0 < i35 >>> 0) {
michael@0 8201 i44 = i35 - i14 | 0;
michael@0 8202 HEAP32[3019] = i44;
michael@0 8203 i35 = HEAP32[3022] | 0;
michael@0 8204 i36 = i35;
michael@0 8205 HEAP32[3022] = i36 + i14;
michael@0 8206 HEAP32[i36 + (i14 + 4) >> 2] = i44 | 1;
michael@0 8207 HEAP32[i35 + 4 >> 2] = i14 | 3;
michael@0 8208 i13 = i35 + 8 | 0;
michael@0 8209 return i13 | 0;
michael@0 8210 }
michael@0 8211 do {
michael@0 8212 if ((HEAP32[2976] | 0) == 0) {
michael@0 8213 i35 = _sysconf(8) | 0;
michael@0 8214 if ((i35 - 1 & i35 | 0) == 0) {
michael@0 8215 HEAP32[2978] = i35;
michael@0 8216 HEAP32[2977] = i35;
michael@0 8217 HEAP32[2979] = -1;
michael@0 8218 HEAP32[2980] = -1;
michael@0 8219 HEAP32[2981] = 0;
michael@0 8220 HEAP32[3127] = 0;
michael@0 8221 HEAP32[2976] = (_time(0) | 0) & -16 ^ 1431655768;
michael@0 8222 break;
michael@0 8223 } else {
michael@0 8224 _abort();
michael@0 8225 return 0;
michael@0 8226 }
michael@0 8227 }
michael@0 8228 } while (0);
michael@0 8229 i35 = i14 + 48 | 0;
michael@0 8230 i44 = HEAP32[2978] | 0;
michael@0 8231 i36 = i14 + 47 | 0;
michael@0 8232 i43 = i44 + i36 | 0;
michael@0 8233 i42 = -i44 | 0;
michael@0 8234 i44 = i43 & i42;
michael@0 8235 if (i44 >>> 0 <= i14 >>> 0) {
michael@0 8236 i13 = 0;
michael@0 8237 return i13 | 0;
michael@0 8238 }
michael@0 8239 i40 = HEAP32[3126] | 0;
michael@0 8240 do {
michael@0 8241 if ((i40 | 0) != 0) {
michael@0 8242 i41 = HEAP32[3124] | 0;
michael@0 8243 i37 = i41 + i44 | 0;
michael@0 8244 if (i37 >>> 0 <= i41 >>> 0 | i37 >>> 0 > i40 >>> 0) {
michael@0 8245 i13 = 0;
michael@0 8246 } else {
michael@0 8247 break;
michael@0 8248 }
michael@0 8249 return i13 | 0;
michael@0 8250 }
michael@0 8251 } while (0);
michael@0 8252 L268 : do {
michael@0 8253 if ((HEAP32[3127] & 4 | 0) == 0) {
michael@0 8254 i40 = HEAP32[3022] | 0;
michael@0 8255 L270 : do {
michael@0 8256 if ((i40 | 0) == 0) {
michael@0 8257 i45 = 181;
michael@0 8258 } else {
michael@0 8259 i37 = i40;
michael@0 8260 i41 = 12512;
michael@0 8261 while (1) {
michael@0 8262 i46 = i41 | 0;
michael@0 8263 i38 = HEAP32[i46 >> 2] | 0;
michael@0 8264 if (i38 >>> 0 <= i37 >>> 0) {
michael@0 8265 i47 = i41 + 4 | 0;
michael@0 8266 if ((i38 + (HEAP32[i47 >> 2] | 0) | 0) >>> 0 > i37 >>> 0) {
michael@0 8267 break;
michael@0 8268 }
michael@0 8269 }
michael@0 8270 i38 = HEAP32[i41 + 8 >> 2] | 0;
michael@0 8271 if ((i38 | 0) == 0) {
michael@0 8272 i45 = 181;
michael@0 8273 break L270;
michael@0 8274 } else {
michael@0 8275 i41 = i38;
michael@0 8276 }
michael@0 8277 }
michael@0 8278 if ((i41 | 0) == 0) {
michael@0 8279 i45 = 181;
michael@0 8280 break;
michael@0 8281 }
michael@0 8282 i37 = i43 - (HEAP32[3019] | 0) & i42;
michael@0 8283 if (i37 >>> 0 >= 2147483647) {
michael@0 8284 i48 = 0;
michael@0 8285 break;
michael@0 8286 }
michael@0 8287 i12 = _sbrk(i37 | 0) | 0;
michael@0 8288 i4 = (i12 | 0) == ((HEAP32[i46 >> 2] | 0) + (HEAP32[i47 >> 2] | 0) | 0);
michael@0 8289 i49 = i4 ? i12 : -1;
michael@0 8290 i50 = i4 ? i37 : 0;
michael@0 8291 i51 = i12;
michael@0 8292 i52 = i37;
michael@0 8293 i45 = 190;
michael@0 8294 }
michael@0 8295 } while (0);
michael@0 8296 do {
michael@0 8297 if ((i45 | 0) == 181) {
michael@0 8298 i40 = _sbrk(0) | 0;
michael@0 8299 if ((i40 | 0) == -1) {
michael@0 8300 i48 = 0;
michael@0 8301 break;
michael@0 8302 }
michael@0 8303 i6 = i40;
michael@0 8304 i37 = HEAP32[2977] | 0;
michael@0 8305 i12 = i37 - 1 | 0;
michael@0 8306 if ((i12 & i6 | 0) == 0) {
michael@0 8307 i53 = i44;
michael@0 8308 } else {
michael@0 8309 i53 = i44 - i6 + (i12 + i6 & -i37) | 0;
michael@0 8310 }
michael@0 8311 i37 = HEAP32[3124] | 0;
michael@0 8312 i6 = i37 + i53 | 0;
michael@0 8313 if (!(i53 >>> 0 > i14 >>> 0 & i53 >>> 0 < 2147483647)) {
michael@0 8314 i48 = 0;
michael@0 8315 break;
michael@0 8316 }
michael@0 8317 i12 = HEAP32[3126] | 0;
michael@0 8318 if ((i12 | 0) != 0) {
michael@0 8319 if (i6 >>> 0 <= i37 >>> 0 | i6 >>> 0 > i12 >>> 0) {
michael@0 8320 i48 = 0;
michael@0 8321 break;
michael@0 8322 }
michael@0 8323 }
michael@0 8324 i12 = _sbrk(i53 | 0) | 0;
michael@0 8325 i6 = (i12 | 0) == (i40 | 0);
michael@0 8326 i49 = i6 ? i40 : -1;
michael@0 8327 i50 = i6 ? i53 : 0;
michael@0 8328 i51 = i12;
michael@0 8329 i52 = i53;
michael@0 8330 i45 = 190;
michael@0 8331 }
michael@0 8332 } while (0);
michael@0 8333 L290 : do {
michael@0 8334 if ((i45 | 0) == 190) {
michael@0 8335 i12 = -i52 | 0;
michael@0 8336 if ((i49 | 0) != -1) {
michael@0 8337 i54 = i50;
michael@0 8338 i55 = i49;
michael@0 8339 i45 = 201;
michael@0 8340 break L268;
michael@0 8341 }
michael@0 8342 do {
michael@0 8343 if ((i51 | 0) != -1 & i52 >>> 0 < 2147483647 & i52 >>> 0 < i35 >>> 0) {
michael@0 8344 i6 = HEAP32[2978] | 0;
michael@0 8345 i40 = i36 - i52 + i6 & -i6;
michael@0 8346 if (i40 >>> 0 >= 2147483647) {
michael@0 8347 i56 = i52;
michael@0 8348 break;
michael@0 8349 }
michael@0 8350 if ((_sbrk(i40 | 0) | 0) == -1) {
michael@0 8351 _sbrk(i12 | 0) | 0;
michael@0 8352 i48 = i50;
michael@0 8353 break L290;
michael@0 8354 } else {
michael@0 8355 i56 = i40 + i52 | 0;
michael@0 8356 break;
michael@0 8357 }
michael@0 8358 } else {
michael@0 8359 i56 = i52;
michael@0 8360 }
michael@0 8361 } while (0);
michael@0 8362 if ((i51 | 0) == -1) {
michael@0 8363 i48 = i50;
michael@0 8364 } else {
michael@0 8365 i54 = i56;
michael@0 8366 i55 = i51;
michael@0 8367 i45 = 201;
michael@0 8368 break L268;
michael@0 8369 }
michael@0 8370 }
michael@0 8371 } while (0);
michael@0 8372 HEAP32[3127] = HEAP32[3127] | 4;
michael@0 8373 i57 = i48;
michael@0 8374 i45 = 198;
michael@0 8375 } else {
michael@0 8376 i57 = 0;
michael@0 8377 i45 = 198;
michael@0 8378 }
michael@0 8379 } while (0);
michael@0 8380 do {
michael@0 8381 if ((i45 | 0) == 198) {
michael@0 8382 if (i44 >>> 0 >= 2147483647) {
michael@0 8383 break;
michael@0 8384 }
michael@0 8385 i48 = _sbrk(i44 | 0) | 0;
michael@0 8386 i51 = _sbrk(0) | 0;
michael@0 8387 if (!((i51 | 0) != -1 & (i48 | 0) != -1 & i48 >>> 0 < i51 >>> 0)) {
michael@0 8388 break;
michael@0 8389 }
michael@0 8390 i56 = i51 - i48 | 0;
michael@0 8391 i51 = i56 >>> 0 > (i14 + 40 | 0) >>> 0;
michael@0 8392 i50 = i51 ? i48 : -1;
michael@0 8393 if ((i50 | 0) != -1) {
michael@0 8394 i54 = i51 ? i56 : i57;
michael@0 8395 i55 = i50;
michael@0 8396 i45 = 201;
michael@0 8397 }
michael@0 8398 }
michael@0 8399 } while (0);
michael@0 8400 do {
michael@0 8401 if ((i45 | 0) == 201) {
michael@0 8402 i57 = (HEAP32[3124] | 0) + i54 | 0;
michael@0 8403 HEAP32[3124] = i57;
michael@0 8404 if (i57 >>> 0 > (HEAP32[3125] | 0) >>> 0) {
michael@0 8405 HEAP32[3125] = i57;
michael@0 8406 }
michael@0 8407 i57 = HEAP32[3022] | 0;
michael@0 8408 L310 : do {
michael@0 8409 if ((i57 | 0) == 0) {
michael@0 8410 i44 = HEAP32[3020] | 0;
michael@0 8411 if ((i44 | 0) == 0 | i55 >>> 0 < i44 >>> 0) {
michael@0 8412 HEAP32[3020] = i55;
michael@0 8413 }
michael@0 8414 HEAP32[3128] = i55;
michael@0 8415 HEAP32[3129] = i54;
michael@0 8416 HEAP32[3131] = 0;
michael@0 8417 HEAP32[3025] = HEAP32[2976];
michael@0 8418 HEAP32[3024] = -1;
michael@0 8419 i44 = 0;
michael@0 8420 do {
michael@0 8421 i50 = i44 << 1;
michael@0 8422 i56 = 12104 + (i50 << 2) | 0;
michael@0 8423 HEAP32[12104 + (i50 + 3 << 2) >> 2] = i56;
michael@0 8424 HEAP32[12104 + (i50 + 2 << 2) >> 2] = i56;
michael@0 8425 i44 = i44 + 1 | 0;
michael@0 8426 } while (i44 >>> 0 < 32);
michael@0 8427 i44 = i55 + 8 | 0;
michael@0 8428 if ((i44 & 7 | 0) == 0) {
michael@0 8429 i58 = 0;
michael@0 8430 } else {
michael@0 8431 i58 = -i44 & 7;
michael@0 8432 }
michael@0 8433 i44 = i54 - 40 - i58 | 0;
michael@0 8434 HEAP32[3022] = i55 + i58;
michael@0 8435 HEAP32[3019] = i44;
michael@0 8436 HEAP32[i55 + (i58 + 4) >> 2] = i44 | 1;
michael@0 8437 HEAP32[i55 + (i54 - 36) >> 2] = 40;
michael@0 8438 HEAP32[3023] = HEAP32[2980];
michael@0 8439 } else {
michael@0 8440 i44 = 12512;
michael@0 8441 while (1) {
michael@0 8442 i59 = HEAP32[i44 >> 2] | 0;
michael@0 8443 i60 = i44 + 4 | 0;
michael@0 8444 i61 = HEAP32[i60 >> 2] | 0;
michael@0 8445 if ((i55 | 0) == (i59 + i61 | 0)) {
michael@0 8446 i45 = 213;
michael@0 8447 break;
michael@0 8448 }
michael@0 8449 i56 = HEAP32[i44 + 8 >> 2] | 0;
michael@0 8450 if ((i56 | 0) == 0) {
michael@0 8451 break;
michael@0 8452 } else {
michael@0 8453 i44 = i56;
michael@0 8454 }
michael@0 8455 }
michael@0 8456 do {
michael@0 8457 if ((i45 | 0) == 213) {
michael@0 8458 if ((HEAP32[i44 + 12 >> 2] & 8 | 0) != 0) {
michael@0 8459 break;
michael@0 8460 }
michael@0 8461 i56 = i57;
michael@0 8462 if (!(i56 >>> 0 >= i59 >>> 0 & i56 >>> 0 < i55 >>> 0)) {
michael@0 8463 break;
michael@0 8464 }
michael@0 8465 HEAP32[i60 >> 2] = i61 + i54;
michael@0 8466 i56 = HEAP32[3022] | 0;
michael@0 8467 i50 = (HEAP32[3019] | 0) + i54 | 0;
michael@0 8468 i51 = i56;
michael@0 8469 i48 = i56 + 8 | 0;
michael@0 8470 if ((i48 & 7 | 0) == 0) {
michael@0 8471 i62 = 0;
michael@0 8472 } else {
michael@0 8473 i62 = -i48 & 7;
michael@0 8474 }
michael@0 8475 i48 = i50 - i62 | 0;
michael@0 8476 HEAP32[3022] = i51 + i62;
michael@0 8477 HEAP32[3019] = i48;
michael@0 8478 HEAP32[i51 + (i62 + 4) >> 2] = i48 | 1;
michael@0 8479 HEAP32[i51 + (i50 + 4) >> 2] = 40;
michael@0 8480 HEAP32[3023] = HEAP32[2980];
michael@0 8481 break L310;
michael@0 8482 }
michael@0 8483 } while (0);
michael@0 8484 if (i55 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8485 HEAP32[3020] = i55;
michael@0 8486 }
michael@0 8487 i44 = i55 + i54 | 0;
michael@0 8488 i50 = 12512;
michael@0 8489 while (1) {
michael@0 8490 i63 = i50 | 0;
michael@0 8491 if ((HEAP32[i63 >> 2] | 0) == (i44 | 0)) {
michael@0 8492 i45 = 223;
michael@0 8493 break;
michael@0 8494 }
michael@0 8495 i51 = HEAP32[i50 + 8 >> 2] | 0;
michael@0 8496 if ((i51 | 0) == 0) {
michael@0 8497 break;
michael@0 8498 } else {
michael@0 8499 i50 = i51;
michael@0 8500 }
michael@0 8501 }
michael@0 8502 do {
michael@0 8503 if ((i45 | 0) == 223) {
michael@0 8504 if ((HEAP32[i50 + 12 >> 2] & 8 | 0) != 0) {
michael@0 8505 break;
michael@0 8506 }
michael@0 8507 HEAP32[i63 >> 2] = i55;
michael@0 8508 i44 = i50 + 4 | 0;
michael@0 8509 HEAP32[i44 >> 2] = (HEAP32[i44 >> 2] | 0) + i54;
michael@0 8510 i44 = i55 + 8 | 0;
michael@0 8511 if ((i44 & 7 | 0) == 0) {
michael@0 8512 i64 = 0;
michael@0 8513 } else {
michael@0 8514 i64 = -i44 & 7;
michael@0 8515 }
michael@0 8516 i44 = i55 + (i54 + 8) | 0;
michael@0 8517 if ((i44 & 7 | 0) == 0) {
michael@0 8518 i65 = 0;
michael@0 8519 } else {
michael@0 8520 i65 = -i44 & 7;
michael@0 8521 }
michael@0 8522 i44 = i55 + (i65 + i54) | 0;
michael@0 8523 i51 = i44;
michael@0 8524 i48 = i64 + i14 | 0;
michael@0 8525 i56 = i55 + i48 | 0;
michael@0 8526 i52 = i56;
michael@0 8527 i36 = i44 - (i55 + i64) - i14 | 0;
michael@0 8528 HEAP32[i55 + (i64 + 4) >> 2] = i14 | 3;
michael@0 8529 do {
michael@0 8530 if ((i51 | 0) == (HEAP32[3022] | 0)) {
michael@0 8531 i35 = (HEAP32[3019] | 0) + i36 | 0;
michael@0 8532 HEAP32[3019] = i35;
michael@0 8533 HEAP32[3022] = i52;
michael@0 8534 HEAP32[i55 + (i48 + 4) >> 2] = i35 | 1;
michael@0 8535 } else {
michael@0 8536 if ((i51 | 0) == (HEAP32[3021] | 0)) {
michael@0 8537 i35 = (HEAP32[3018] | 0) + i36 | 0;
michael@0 8538 HEAP32[3018] = i35;
michael@0 8539 HEAP32[3021] = i52;
michael@0 8540 HEAP32[i55 + (i48 + 4) >> 2] = i35 | 1;
michael@0 8541 HEAP32[i55 + (i35 + i48) >> 2] = i35;
michael@0 8542 break;
michael@0 8543 }
michael@0 8544 i35 = i54 + 4 | 0;
michael@0 8545 i49 = HEAP32[i55 + (i35 + i65) >> 2] | 0;
michael@0 8546 if ((i49 & 3 | 0) == 1) {
michael@0 8547 i53 = i49 & -8;
michael@0 8548 i47 = i49 >>> 3;
michael@0 8549 L355 : do {
michael@0 8550 if (i49 >>> 0 < 256) {
michael@0 8551 i46 = HEAP32[i55 + ((i65 | 8) + i54) >> 2] | 0;
michael@0 8552 i42 = HEAP32[i55 + (i54 + 12 + i65) >> 2] | 0;
michael@0 8553 i43 = 12104 + (i47 << 1 << 2) | 0;
michael@0 8554 do {
michael@0 8555 if ((i46 | 0) != (i43 | 0)) {
michael@0 8556 if (i46 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8557 _abort();
michael@0 8558 return 0;
michael@0 8559 }
michael@0 8560 if ((HEAP32[i46 + 12 >> 2] | 0) == (i51 | 0)) {
michael@0 8561 break;
michael@0 8562 }
michael@0 8563 _abort();
michael@0 8564 return 0;
michael@0 8565 }
michael@0 8566 } while (0);
michael@0 8567 if ((i42 | 0) == (i46 | 0)) {
michael@0 8568 HEAP32[3016] = HEAP32[3016] & ~(1 << i47);
michael@0 8569 break;
michael@0 8570 }
michael@0 8571 do {
michael@0 8572 if ((i42 | 0) == (i43 | 0)) {
michael@0 8573 i66 = i42 + 8 | 0;
michael@0 8574 } else {
michael@0 8575 if (i42 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8576 _abort();
michael@0 8577 return 0;
michael@0 8578 }
michael@0 8579 i12 = i42 + 8 | 0;
michael@0 8580 if ((HEAP32[i12 >> 2] | 0) == (i51 | 0)) {
michael@0 8581 i66 = i12;
michael@0 8582 break;
michael@0 8583 }
michael@0 8584 _abort();
michael@0 8585 return 0;
michael@0 8586 }
michael@0 8587 } while (0);
michael@0 8588 HEAP32[i46 + 12 >> 2] = i42;
michael@0 8589 HEAP32[i66 >> 2] = i46;
michael@0 8590 } else {
michael@0 8591 i43 = i44;
michael@0 8592 i12 = HEAP32[i55 + ((i65 | 24) + i54) >> 2] | 0;
michael@0 8593 i41 = HEAP32[i55 + (i54 + 12 + i65) >> 2] | 0;
michael@0 8594 do {
michael@0 8595 if ((i41 | 0) == (i43 | 0)) {
michael@0 8596 i40 = i65 | 16;
michael@0 8597 i6 = i55 + (i35 + i40) | 0;
michael@0 8598 i37 = HEAP32[i6 >> 2] | 0;
michael@0 8599 if ((i37 | 0) == 0) {
michael@0 8600 i4 = i55 + (i40 + i54) | 0;
michael@0 8601 i40 = HEAP32[i4 >> 2] | 0;
michael@0 8602 if ((i40 | 0) == 0) {
michael@0 8603 i67 = 0;
michael@0 8604 break;
michael@0 8605 } else {
michael@0 8606 i68 = i40;
michael@0 8607 i69 = i4;
michael@0 8608 }
michael@0 8609 } else {
michael@0 8610 i68 = i37;
michael@0 8611 i69 = i6;
michael@0 8612 }
michael@0 8613 while (1) {
michael@0 8614 i6 = i68 + 20 | 0;
michael@0 8615 i37 = HEAP32[i6 >> 2] | 0;
michael@0 8616 if ((i37 | 0) != 0) {
michael@0 8617 i68 = i37;
michael@0 8618 i69 = i6;
michael@0 8619 continue;
michael@0 8620 }
michael@0 8621 i6 = i68 + 16 | 0;
michael@0 8622 i37 = HEAP32[i6 >> 2] | 0;
michael@0 8623 if ((i37 | 0) == 0) {
michael@0 8624 break;
michael@0 8625 } else {
michael@0 8626 i68 = i37;
michael@0 8627 i69 = i6;
michael@0 8628 }
michael@0 8629 }
michael@0 8630 if (i69 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8631 _abort();
michael@0 8632 return 0;
michael@0 8633 } else {
michael@0 8634 HEAP32[i69 >> 2] = 0;
michael@0 8635 i67 = i68;
michael@0 8636 break;
michael@0 8637 }
michael@0 8638 } else {
michael@0 8639 i6 = HEAP32[i55 + ((i65 | 8) + i54) >> 2] | 0;
michael@0 8640 if (i6 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8641 _abort();
michael@0 8642 return 0;
michael@0 8643 }
michael@0 8644 i37 = i6 + 12 | 0;
michael@0 8645 if ((HEAP32[i37 >> 2] | 0) != (i43 | 0)) {
michael@0 8646 _abort();
michael@0 8647 return 0;
michael@0 8648 }
michael@0 8649 i4 = i41 + 8 | 0;
michael@0 8650 if ((HEAP32[i4 >> 2] | 0) == (i43 | 0)) {
michael@0 8651 HEAP32[i37 >> 2] = i41;
michael@0 8652 HEAP32[i4 >> 2] = i6;
michael@0 8653 i67 = i41;
michael@0 8654 break;
michael@0 8655 } else {
michael@0 8656 _abort();
michael@0 8657 return 0;
michael@0 8658 }
michael@0 8659 }
michael@0 8660 } while (0);
michael@0 8661 if ((i12 | 0) == 0) {
michael@0 8662 break;
michael@0 8663 }
michael@0 8664 i41 = i55 + (i54 + 28 + i65) | 0;
michael@0 8665 i46 = 12368 + (HEAP32[i41 >> 2] << 2) | 0;
michael@0 8666 do {
michael@0 8667 if ((i43 | 0) == (HEAP32[i46 >> 2] | 0)) {
michael@0 8668 HEAP32[i46 >> 2] = i67;
michael@0 8669 if ((i67 | 0) != 0) {
michael@0 8670 break;
michael@0 8671 }
michael@0 8672 HEAP32[3017] = HEAP32[3017] & ~(1 << HEAP32[i41 >> 2]);
michael@0 8673 break L355;
michael@0 8674 } else {
michael@0 8675 if (i12 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8676 _abort();
michael@0 8677 return 0;
michael@0 8678 }
michael@0 8679 i42 = i12 + 16 | 0;
michael@0 8680 if ((HEAP32[i42 >> 2] | 0) == (i43 | 0)) {
michael@0 8681 HEAP32[i42 >> 2] = i67;
michael@0 8682 } else {
michael@0 8683 HEAP32[i12 + 20 >> 2] = i67;
michael@0 8684 }
michael@0 8685 if ((i67 | 0) == 0) {
michael@0 8686 break L355;
michael@0 8687 }
michael@0 8688 }
michael@0 8689 } while (0);
michael@0 8690 if (i67 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8691 _abort();
michael@0 8692 return 0;
michael@0 8693 }
michael@0 8694 HEAP32[i67 + 24 >> 2] = i12;
michael@0 8695 i43 = i65 | 16;
michael@0 8696 i41 = HEAP32[i55 + (i43 + i54) >> 2] | 0;
michael@0 8697 do {
michael@0 8698 if ((i41 | 0) != 0) {
michael@0 8699 if (i41 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8700 _abort();
michael@0 8701 return 0;
michael@0 8702 } else {
michael@0 8703 HEAP32[i67 + 16 >> 2] = i41;
michael@0 8704 HEAP32[i41 + 24 >> 2] = i67;
michael@0 8705 break;
michael@0 8706 }
michael@0 8707 }
michael@0 8708 } while (0);
michael@0 8709 i41 = HEAP32[i55 + (i35 + i43) >> 2] | 0;
michael@0 8710 if ((i41 | 0) == 0) {
michael@0 8711 break;
michael@0 8712 }
michael@0 8713 if (i41 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8714 _abort();
michael@0 8715 return 0;
michael@0 8716 } else {
michael@0 8717 HEAP32[i67 + 20 >> 2] = i41;
michael@0 8718 HEAP32[i41 + 24 >> 2] = i67;
michael@0 8719 break;
michael@0 8720 }
michael@0 8721 }
michael@0 8722 } while (0);
michael@0 8723 i70 = i55 + ((i53 | i65) + i54) | 0;
michael@0 8724 i71 = i53 + i36 | 0;
michael@0 8725 } else {
michael@0 8726 i70 = i51;
michael@0 8727 i71 = i36;
michael@0 8728 }
michael@0 8729 i35 = i70 + 4 | 0;
michael@0 8730 HEAP32[i35 >> 2] = HEAP32[i35 >> 2] & -2;
michael@0 8731 HEAP32[i55 + (i48 + 4) >> 2] = i71 | 1;
michael@0 8732 HEAP32[i55 + (i71 + i48) >> 2] = i71;
michael@0 8733 i35 = i71 >>> 3;
michael@0 8734 if (i71 >>> 0 < 256) {
michael@0 8735 i47 = i35 << 1;
michael@0 8736 i49 = 12104 + (i47 << 2) | 0;
michael@0 8737 i41 = HEAP32[3016] | 0;
michael@0 8738 i12 = 1 << i35;
michael@0 8739 do {
michael@0 8740 if ((i41 & i12 | 0) == 0) {
michael@0 8741 HEAP32[3016] = i41 | i12;
michael@0 8742 i72 = i49;
michael@0 8743 i73 = 12104 + (i47 + 2 << 2) | 0;
michael@0 8744 } else {
michael@0 8745 i35 = 12104 + (i47 + 2 << 2) | 0;
michael@0 8746 i46 = HEAP32[i35 >> 2] | 0;
michael@0 8747 if (i46 >>> 0 >= (HEAP32[3020] | 0) >>> 0) {
michael@0 8748 i72 = i46;
michael@0 8749 i73 = i35;
michael@0 8750 break;
michael@0 8751 }
michael@0 8752 _abort();
michael@0 8753 return 0;
michael@0 8754 }
michael@0 8755 } while (0);
michael@0 8756 HEAP32[i73 >> 2] = i52;
michael@0 8757 HEAP32[i72 + 12 >> 2] = i52;
michael@0 8758 HEAP32[i55 + (i48 + 8) >> 2] = i72;
michael@0 8759 HEAP32[i55 + (i48 + 12) >> 2] = i49;
michael@0 8760 break;
michael@0 8761 }
michael@0 8762 i47 = i56;
michael@0 8763 i12 = i71 >>> 8;
michael@0 8764 do {
michael@0 8765 if ((i12 | 0) == 0) {
michael@0 8766 i74 = 0;
michael@0 8767 } else {
michael@0 8768 if (i71 >>> 0 > 16777215) {
michael@0 8769 i74 = 31;
michael@0 8770 break;
michael@0 8771 }
michael@0 8772 i41 = (i12 + 1048320 | 0) >>> 16 & 8;
michael@0 8773 i53 = i12 << i41;
michael@0 8774 i35 = (i53 + 520192 | 0) >>> 16 & 4;
michael@0 8775 i46 = i53 << i35;
michael@0 8776 i53 = (i46 + 245760 | 0) >>> 16 & 2;
michael@0 8777 i42 = 14 - (i35 | i41 | i53) + (i46 << i53 >>> 15) | 0;
michael@0 8778 i74 = i71 >>> ((i42 + 7 | 0) >>> 0) & 1 | i42 << 1;
michael@0 8779 }
michael@0 8780 } while (0);
michael@0 8781 i12 = 12368 + (i74 << 2) | 0;
michael@0 8782 HEAP32[i55 + (i48 + 28) >> 2] = i74;
michael@0 8783 HEAP32[i55 + (i48 + 20) >> 2] = 0;
michael@0 8784 HEAP32[i55 + (i48 + 16) >> 2] = 0;
michael@0 8785 i49 = HEAP32[3017] | 0;
michael@0 8786 i42 = 1 << i74;
michael@0 8787 if ((i49 & i42 | 0) == 0) {
michael@0 8788 HEAP32[3017] = i49 | i42;
michael@0 8789 HEAP32[i12 >> 2] = i47;
michael@0 8790 HEAP32[i55 + (i48 + 24) >> 2] = i12;
michael@0 8791 HEAP32[i55 + (i48 + 12) >> 2] = i47;
michael@0 8792 HEAP32[i55 + (i48 + 8) >> 2] = i47;
michael@0 8793 break;
michael@0 8794 }
michael@0 8795 if ((i74 | 0) == 31) {
michael@0 8796 i75 = 0;
michael@0 8797 } else {
michael@0 8798 i75 = 25 - (i74 >>> 1) | 0;
michael@0 8799 }
michael@0 8800 i42 = i71 << i75;
michael@0 8801 i49 = HEAP32[i12 >> 2] | 0;
michael@0 8802 while (1) {
michael@0 8803 if ((HEAP32[i49 + 4 >> 2] & -8 | 0) == (i71 | 0)) {
michael@0 8804 break;
michael@0 8805 }
michael@0 8806 i76 = i49 + 16 + (i42 >>> 31 << 2) | 0;
michael@0 8807 i12 = HEAP32[i76 >> 2] | 0;
michael@0 8808 if ((i12 | 0) == 0) {
michael@0 8809 i45 = 296;
michael@0 8810 break;
michael@0 8811 } else {
michael@0 8812 i42 = i42 << 1;
michael@0 8813 i49 = i12;
michael@0 8814 }
michael@0 8815 }
michael@0 8816 if ((i45 | 0) == 296) {
michael@0 8817 if (i76 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 8818 _abort();
michael@0 8819 return 0;
michael@0 8820 } else {
michael@0 8821 HEAP32[i76 >> 2] = i47;
michael@0 8822 HEAP32[i55 + (i48 + 24) >> 2] = i49;
michael@0 8823 HEAP32[i55 + (i48 + 12) >> 2] = i47;
michael@0 8824 HEAP32[i55 + (i48 + 8) >> 2] = i47;
michael@0 8825 break;
michael@0 8826 }
michael@0 8827 }
michael@0 8828 i42 = i49 + 8 | 0;
michael@0 8829 i12 = HEAP32[i42 >> 2] | 0;
michael@0 8830 i53 = HEAP32[3020] | 0;
michael@0 8831 if (i49 >>> 0 < i53 >>> 0) {
michael@0 8832 _abort();
michael@0 8833 return 0;
michael@0 8834 }
michael@0 8835 if (i12 >>> 0 < i53 >>> 0) {
michael@0 8836 _abort();
michael@0 8837 return 0;
michael@0 8838 } else {
michael@0 8839 HEAP32[i12 + 12 >> 2] = i47;
michael@0 8840 HEAP32[i42 >> 2] = i47;
michael@0 8841 HEAP32[i55 + (i48 + 8) >> 2] = i12;
michael@0 8842 HEAP32[i55 + (i48 + 12) >> 2] = i49;
michael@0 8843 HEAP32[i55 + (i48 + 24) >> 2] = 0;
michael@0 8844 break;
michael@0 8845 }
michael@0 8846 }
michael@0 8847 } while (0);
michael@0 8848 i13 = i55 + (i64 | 8) | 0;
michael@0 8849 return i13 | 0;
michael@0 8850 }
michael@0 8851 } while (0);
michael@0 8852 i50 = i57;
michael@0 8853 i48 = 12512;
michael@0 8854 while (1) {
michael@0 8855 i77 = HEAP32[i48 >> 2] | 0;
michael@0 8856 if (i77 >>> 0 <= i50 >>> 0) {
michael@0 8857 i78 = HEAP32[i48 + 4 >> 2] | 0;
michael@0 8858 i79 = i77 + i78 | 0;
michael@0 8859 if (i79 >>> 0 > i50 >>> 0) {
michael@0 8860 break;
michael@0 8861 }
michael@0 8862 }
michael@0 8863 i48 = HEAP32[i48 + 8 >> 2] | 0;
michael@0 8864 }
michael@0 8865 i48 = i77 + (i78 - 39) | 0;
michael@0 8866 if ((i48 & 7 | 0) == 0) {
michael@0 8867 i80 = 0;
michael@0 8868 } else {
michael@0 8869 i80 = -i48 & 7;
michael@0 8870 }
michael@0 8871 i48 = i77 + (i78 - 47 + i80) | 0;
michael@0 8872 i56 = i48 >>> 0 < (i57 + 16 | 0) >>> 0 ? i50 : i48;
michael@0 8873 i48 = i56 + 8 | 0;
michael@0 8874 i52 = i55 + 8 | 0;
michael@0 8875 if ((i52 & 7 | 0) == 0) {
michael@0 8876 i81 = 0;
michael@0 8877 } else {
michael@0 8878 i81 = -i52 & 7;
michael@0 8879 }
michael@0 8880 i52 = i54 - 40 - i81 | 0;
michael@0 8881 HEAP32[3022] = i55 + i81;
michael@0 8882 HEAP32[3019] = i52;
michael@0 8883 HEAP32[i55 + (i81 + 4) >> 2] = i52 | 1;
michael@0 8884 HEAP32[i55 + (i54 - 36) >> 2] = 40;
michael@0 8885 HEAP32[3023] = HEAP32[2980];
michael@0 8886 HEAP32[i56 + 4 >> 2] = 27;
michael@0 8887 HEAP32[i48 >> 2] = HEAP32[3128];
michael@0 8888 HEAP32[i48 + 4 >> 2] = HEAP32[12516 >> 2];
michael@0 8889 HEAP32[i48 + 8 >> 2] = HEAP32[12520 >> 2];
michael@0 8890 HEAP32[i48 + 12 >> 2] = HEAP32[12524 >> 2];
michael@0 8891 HEAP32[3128] = i55;
michael@0 8892 HEAP32[3129] = i54;
michael@0 8893 HEAP32[3131] = 0;
michael@0 8894 HEAP32[3130] = i48;
michael@0 8895 i48 = i56 + 28 | 0;
michael@0 8896 HEAP32[i48 >> 2] = 7;
michael@0 8897 if ((i56 + 32 | 0) >>> 0 < i79 >>> 0) {
michael@0 8898 i52 = i48;
michael@0 8899 while (1) {
michael@0 8900 i48 = i52 + 4 | 0;
michael@0 8901 HEAP32[i48 >> 2] = 7;
michael@0 8902 if ((i52 + 8 | 0) >>> 0 < i79 >>> 0) {
michael@0 8903 i52 = i48;
michael@0 8904 } else {
michael@0 8905 break;
michael@0 8906 }
michael@0 8907 }
michael@0 8908 }
michael@0 8909 if ((i56 | 0) == (i50 | 0)) {
michael@0 8910 break;
michael@0 8911 }
michael@0 8912 i52 = i56 - i57 | 0;
michael@0 8913 i48 = i50 + (i52 + 4) | 0;
michael@0 8914 HEAP32[i48 >> 2] = HEAP32[i48 >> 2] & -2;
michael@0 8915 HEAP32[i57 + 4 >> 2] = i52 | 1;
michael@0 8916 HEAP32[i50 + i52 >> 2] = i52;
michael@0 8917 i48 = i52 >>> 3;
michael@0 8918 if (i52 >>> 0 < 256) {
michael@0 8919 i36 = i48 << 1;
michael@0 8920 i51 = 12104 + (i36 << 2) | 0;
michael@0 8921 i44 = HEAP32[3016] | 0;
michael@0 8922 i12 = 1 << i48;
michael@0 8923 do {
michael@0 8924 if ((i44 & i12 | 0) == 0) {
michael@0 8925 HEAP32[3016] = i44 | i12;
michael@0 8926 i82 = i51;
michael@0 8927 i83 = 12104 + (i36 + 2 << 2) | 0;
michael@0 8928 } else {
michael@0 8929 i48 = 12104 + (i36 + 2 << 2) | 0;
michael@0 8930 i42 = HEAP32[i48 >> 2] | 0;
michael@0 8931 if (i42 >>> 0 >= (HEAP32[3020] | 0) >>> 0) {
michael@0 8932 i82 = i42;
michael@0 8933 i83 = i48;
michael@0 8934 break;
michael@0 8935 }
michael@0 8936 _abort();
michael@0 8937 return 0;
michael@0 8938 }
michael@0 8939 } while (0);
michael@0 8940 HEAP32[i83 >> 2] = i57;
michael@0 8941 HEAP32[i82 + 12 >> 2] = i57;
michael@0 8942 HEAP32[i57 + 8 >> 2] = i82;
michael@0 8943 HEAP32[i57 + 12 >> 2] = i51;
michael@0 8944 break;
michael@0 8945 }
michael@0 8946 i36 = i57;
michael@0 8947 i12 = i52 >>> 8;
michael@0 8948 do {
michael@0 8949 if ((i12 | 0) == 0) {
michael@0 8950 i84 = 0;
michael@0 8951 } else {
michael@0 8952 if (i52 >>> 0 > 16777215) {
michael@0 8953 i84 = 31;
michael@0 8954 break;
michael@0 8955 }
michael@0 8956 i44 = (i12 + 1048320 | 0) >>> 16 & 8;
michael@0 8957 i50 = i12 << i44;
michael@0 8958 i56 = (i50 + 520192 | 0) >>> 16 & 4;
michael@0 8959 i48 = i50 << i56;
michael@0 8960 i50 = (i48 + 245760 | 0) >>> 16 & 2;
michael@0 8961 i42 = 14 - (i56 | i44 | i50) + (i48 << i50 >>> 15) | 0;
michael@0 8962 i84 = i52 >>> ((i42 + 7 | 0) >>> 0) & 1 | i42 << 1;
michael@0 8963 }
michael@0 8964 } while (0);
michael@0 8965 i12 = 12368 + (i84 << 2) | 0;
michael@0 8966 HEAP32[i57 + 28 >> 2] = i84;
michael@0 8967 HEAP32[i57 + 20 >> 2] = 0;
michael@0 8968 HEAP32[i57 + 16 >> 2] = 0;
michael@0 8969 i51 = HEAP32[3017] | 0;
michael@0 8970 i42 = 1 << i84;
michael@0 8971 if ((i51 & i42 | 0) == 0) {
michael@0 8972 HEAP32[3017] = i51 | i42;
michael@0 8973 HEAP32[i12 >> 2] = i36;
michael@0 8974 HEAP32[i57 + 24 >> 2] = i12;
michael@0 8975 HEAP32[i57 + 12 >> 2] = i57;
michael@0 8976 HEAP32[i57 + 8 >> 2] = i57;
michael@0 8977 break;
michael@0 8978 }
michael@0 8979 if ((i84 | 0) == 31) {
michael@0 8980 i85 = 0;
michael@0 8981 } else {
michael@0 8982 i85 = 25 - (i84 >>> 1) | 0;
michael@0 8983 }
michael@0 8984 i42 = i52 << i85;
michael@0 8985 i51 = HEAP32[i12 >> 2] | 0;
michael@0 8986 while (1) {
michael@0 8987 if ((HEAP32[i51 + 4 >> 2] & -8 | 0) == (i52 | 0)) {
michael@0 8988 break;
michael@0 8989 }
michael@0 8990 i86 = i51 + 16 + (i42 >>> 31 << 2) | 0;
michael@0 8991 i12 = HEAP32[i86 >> 2] | 0;
michael@0 8992 if ((i12 | 0) == 0) {
michael@0 8993 i45 = 331;
michael@0 8994 break;
michael@0 8995 } else {
michael@0 8996 i42 = i42 << 1;
michael@0 8997 i51 = i12;
michael@0 8998 }
michael@0 8999 }
michael@0 9000 if ((i45 | 0) == 331) {
michael@0 9001 if (i86 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 9002 _abort();
michael@0 9003 return 0;
michael@0 9004 } else {
michael@0 9005 HEAP32[i86 >> 2] = i36;
michael@0 9006 HEAP32[i57 + 24 >> 2] = i51;
michael@0 9007 HEAP32[i57 + 12 >> 2] = i57;
michael@0 9008 HEAP32[i57 + 8 >> 2] = i57;
michael@0 9009 break;
michael@0 9010 }
michael@0 9011 }
michael@0 9012 i42 = i51 + 8 | 0;
michael@0 9013 i52 = HEAP32[i42 >> 2] | 0;
michael@0 9014 i12 = HEAP32[3020] | 0;
michael@0 9015 if (i51 >>> 0 < i12 >>> 0) {
michael@0 9016 _abort();
michael@0 9017 return 0;
michael@0 9018 }
michael@0 9019 if (i52 >>> 0 < i12 >>> 0) {
michael@0 9020 _abort();
michael@0 9021 return 0;
michael@0 9022 } else {
michael@0 9023 HEAP32[i52 + 12 >> 2] = i36;
michael@0 9024 HEAP32[i42 >> 2] = i36;
michael@0 9025 HEAP32[i57 + 8 >> 2] = i52;
michael@0 9026 HEAP32[i57 + 12 >> 2] = i51;
michael@0 9027 HEAP32[i57 + 24 >> 2] = 0;
michael@0 9028 break;
michael@0 9029 }
michael@0 9030 }
michael@0 9031 } while (0);
michael@0 9032 i57 = HEAP32[3019] | 0;
michael@0 9033 if (i57 >>> 0 <= i14 >>> 0) {
michael@0 9034 break;
michael@0 9035 }
michael@0 9036 i52 = i57 - i14 | 0;
michael@0 9037 HEAP32[3019] = i52;
michael@0 9038 i57 = HEAP32[3022] | 0;
michael@0 9039 i42 = i57;
michael@0 9040 HEAP32[3022] = i42 + i14;
michael@0 9041 HEAP32[i42 + (i14 + 4) >> 2] = i52 | 1;
michael@0 9042 HEAP32[i57 + 4 >> 2] = i14 | 3;
michael@0 9043 i13 = i57 + 8 | 0;
michael@0 9044 return i13 | 0;
michael@0 9045 }
michael@0 9046 } while (0);
michael@0 9047 HEAP32[(___errno_location() | 0) >> 2] = 12;
michael@0 9048 i13 = 0;
michael@0 9049 return i13 | 0;
michael@0 9050 }
michael@0 9051 function __Z8dBoxBox2RK9btVector3PKfS1_S1_S3_S1_RS_PfPiiP12dContactGeomiRN36btDiscreteCollisionDetectorInterface6ResultE(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12, i13) {
michael@0 9052 i1 = i1 | 0;
michael@0 9053 i2 = i2 | 0;
michael@0 9054 i3 = i3 | 0;
michael@0 9055 i4 = i4 | 0;
michael@0 9056 i5 = i5 | 0;
michael@0 9057 i6 = i6 | 0;
michael@0 9058 i7 = i7 | 0;
michael@0 9059 i8 = i8 | 0;
michael@0 9060 i9 = i9 | 0;
michael@0 9061 i10 = i10 | 0;
michael@0 9062 i11 = i11 | 0;
michael@0 9063 i12 = i12 | 0;
michael@0 9064 i13 = i13 | 0;
michael@0 9065 var i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, d37 = 0.0, i38 = 0, d39 = 0.0, i40 = 0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, i46 = 0, d47 = 0.0, i48 = 0, d49 = 0.0, i50 = 0, d51 = 0.0, d52 = 0.0, i53 = 0, d54 = 0.0, i55 = 0, d56 = 0.0, i57 = 0, d58 = 0.0, d59 = 0.0, d60 = 0.0, i61 = 0, d62 = 0.0, d63 = 0.0, d64 = 0.0, d65 = 0.0, d66 = 0.0, d67 = 0.0, d68 = 0.0, d69 = 0.0, d70 = 0.0, d71 = 0.0, i72 = 0, d73 = 0.0, i74 = 0, d75 = 0.0, d76 = 0.0, i77 = 0, d78 = 0.0, i79 = 0, d80 = 0.0, i81 = 0, d82 = 0.0, d83 = 0.0, d84 = 0.0, d85 = 0.0, d86 = 0.0, d87 = 0.0, d88 = 0.0, d89 = 0.0, d90 = 0.0, d91 = 0.0, d92 = 0.0, d93 = 0.0, i94 = 0, i95 = 0, i96 = 0, i97 = 0, d98 = 0.0, i99 = 0, i100 = 0, i101 = 0, d102 = 0.0, i103 = 0, i104 = 0, i105 = 0, d106 = 0.0, i107 = 0, i108 = 0, i109 = 0, d110 = 0.0, i111 = 0, i112 = 0, i113 = 0, d114 = 0.0, i115 = 0, i116 = 0, i117 = 0, d118 = 0.0, i119 = 0, i120 = 0, i121 = 0, d122 = 0.0, d123 = 0.0, d124 = 0.0, d125 = 0.0, i126 = 0, i127 = 0, i128 = 0, d129 = 0.0, d130 = 0.0, d131 = 0.0, d132 = 0.0, i133 = 0, i134 = 0, i135 = 0, d136 = 0.0, d137 = 0.0, d138 = 0.0, d139 = 0.0, i140 = 0, i141 = 0, i142 = 0, d143 = 0.0, d144 = 0.0, d145 = 0.0, d146 = 0.0, i147 = 0, i148 = 0, i149 = 0, d150 = 0.0, d151 = 0.0, d152 = 0.0, d153 = 0.0, i154 = 0, i155 = 0, i156 = 0, d157 = 0.0, d158 = 0.0, d159 = 0.0, d160 = 0.0, i161 = 0, i162 = 0, i163 = 0, d164 = 0.0, d165 = 0.0, d166 = 0.0, d167 = 0.0, i168 = 0, i169 = 0, i170 = 0, d171 = 0.0, d172 = 0.0, d173 = 0.0, d174 = 0.0, i175 = 0, i176 = 0, i177 = 0, d178 = 0.0, d179 = 0.0, d180 = 0.0, d181 = 0.0, i182 = 0, i183 = 0, d184 = 0.0, d185 = 0.0, d186 = 0.0, d187 = 0.0, d188 = 0.0, d189 = 0.0, d190 = 0.0, d191 = 0.0, i192 = 0, i193 = 0, i194 = 0, i195 = 0, i196 = 0, i197 = 0, i198 = 0, i199 = 0, i200 = 0, d201 = 0.0, d202 = 0.0, d203 = 0.0, i204 = 0, i205 = 0, i206 = 0, i207 = 0, i208 = 0, i209 = 0, d210 = 0.0, d211 = 0.0, i212 = 0, i213 = 0, i214 = 0, i215 = 0, i216 = 0, i217 = 0, i218 = 0, i219 = 0, i220 = 0, i221 = 0, d222 = 0.0, d223 = 0.0, i224 = 0, i225 = 0, i226 = 0, i227 = 0, i228 = 0;
michael@0 9066 i12 = STACKTOP;
michael@0 9067 i11 = i4;
michael@0 9068 i14 = STACKTOP;
michael@0 9069 STACKTOP = STACKTOP + 64 | 0;
michael@0 9070 i15 = STACKTOP;
michael@0 9071 STACKTOP = STACKTOP + 12 | 0;
michael@0 9072 STACKTOP = STACKTOP + 7 >> 3 << 3;
michael@0 9073 i16 = STACKTOP;
michael@0 9074 STACKTOP = STACKTOP + 12 | 0;
michael@0 9075 STACKTOP = STACKTOP + 7 >> 3 << 3;
michael@0 9076 i17 = STACKTOP;
michael@0 9077 STACKTOP = STACKTOP + 16 | 0;
michael@0 9078 i18 = i17;
michael@0 9079 i19 = STACKTOP;
michael@0 9080 STACKTOP = STACKTOP + 16 | 0;
michael@0 9081 i20 = STACKTOP;
michael@0 9082 STACKTOP = STACKTOP + 16 | 0;
michael@0 9083 i21 = STACKTOP;
michael@0 9084 STACKTOP = STACKTOP + 32 | 0;
michael@0 9085 i22 = STACKTOP;
michael@0 9086 STACKTOP = STACKTOP + 8 | 0;
michael@0 9087 i23 = STACKTOP;
michael@0 9088 STACKTOP = STACKTOP + 64 | 0;
michael@0 9089 i24 = STACKTOP;
michael@0 9090 STACKTOP = STACKTOP + 96 | 0;
michael@0 9091 i25 = STACKTOP;
michael@0 9092 STACKTOP = STACKTOP + 32 | 0;
michael@0 9093 i26 = STACKTOP;
michael@0 9094 STACKTOP = STACKTOP + 16 | 0;
michael@0 9095 i27 = STACKTOP;
michael@0 9096 STACKTOP = STACKTOP + 16 | 0;
michael@0 9097 i28 = STACKTOP;
michael@0 9098 STACKTOP = STACKTOP + 16 | 0;
michael@0 9099 i29 = STACKTOP;
michael@0 9100 STACKTOP = STACKTOP + 16 | 0;
michael@0 9101 i30 = STACKTOP;
michael@0 9102 STACKTOP = STACKTOP + 32 | 0;
michael@0 9103 i31 = STACKTOP;
michael@0 9104 STACKTOP = STACKTOP + 16 | 0;
michael@0 9105 i32 = STACKTOP;
michael@0 9106 STACKTOP = STACKTOP + 16 | 0;
michael@0 9107 i33 = STACKTOP;
michael@0 9108 STACKTOP = STACKTOP + 16 | 0;
michael@0 9109 i34 = STACKTOP;
michael@0 9110 STACKTOP = STACKTOP + 16 | 0;
michael@0 9111 i35 = i4 | 0;
michael@0 9112 i36 = i1 | 0;
michael@0 9113 d37 = +HEAPF32[i35 >> 2] - +HEAPF32[i36 >> 2];
michael@0 9114 i38 = i1 + 4 | 0;
michael@0 9115 d39 = +HEAPF32[i4 + 4 >> 2] - +HEAPF32[i38 >> 2];
michael@0 9116 i40 = i1 + 8 | 0;
michael@0 9117 d41 = +HEAPF32[i4 + 8 >> 2] - +HEAPF32[i40 >> 2];
michael@0 9118 d42 = +HEAPF32[i2 >> 2];
michael@0 9119 i4 = i2 + 16 | 0;
michael@0 9120 d43 = +HEAPF32[i4 >> 2];
michael@0 9121 i1 = i2 + 32 | 0;
michael@0 9122 d44 = +HEAPF32[i1 >> 2];
michael@0 9123 d45 = d37 * d42 + d39 * d43 + d41 * d44;
michael@0 9124 i46 = i2 + 4 | 0;
michael@0 9125 d47 = +HEAPF32[i46 >> 2];
michael@0 9126 i48 = i2 + 20 | 0;
michael@0 9127 d49 = +HEAPF32[i48 >> 2];
michael@0 9128 i50 = i2 + 36 | 0;
michael@0 9129 d51 = +HEAPF32[i50 >> 2];
michael@0 9130 d52 = d37 * d47 + d39 * d49 + d41 * d51;
michael@0 9131 i53 = i2 + 8 | 0;
michael@0 9132 d54 = +HEAPF32[i53 >> 2];
michael@0 9133 i55 = i2 + 24 | 0;
michael@0 9134 d56 = +HEAPF32[i55 >> 2];
michael@0 9135 i57 = i2 + 40 | 0;
michael@0 9136 d58 = +HEAPF32[i57 >> 2];
michael@0 9137 d59 = d37 * d54 + d39 * d56 + d41 * d58;
michael@0 9138 d60 = +HEAPF32[i3 >> 2] * .5;
michael@0 9139 i61 = i15 | 0;
michael@0 9140 HEAPF32[i61 >> 2] = d60;
michael@0 9141 d62 = +HEAPF32[i3 + 4 >> 2] * .5;
michael@0 9142 HEAPF32[i15 + 4 >> 2] = d62;
michael@0 9143 d63 = +HEAPF32[i3 + 8 >> 2] * .5;
michael@0 9144 HEAPF32[i15 + 8 >> 2] = d63;
michael@0 9145 d64 = +HEAPF32[i6 >> 2] * .5;
michael@0 9146 i15 = i16 | 0;
michael@0 9147 HEAPF32[i15 >> 2] = d64;
michael@0 9148 d65 = +HEAPF32[i6 + 4 >> 2] * .5;
michael@0 9149 HEAPF32[i16 + 4 >> 2] = d65;
michael@0 9150 d66 = +HEAPF32[i6 + 8 >> 2] * .5;
michael@0 9151 HEAPF32[i16 + 8 >> 2] = d66;
michael@0 9152 d67 = +HEAPF32[i5 >> 2];
michael@0 9153 i16 = i5 + 16 | 0;
michael@0 9154 d68 = +HEAPF32[i16 >> 2];
michael@0 9155 i6 = i5 + 32 | 0;
michael@0 9156 d69 = +HEAPF32[i6 >> 2];
michael@0 9157 d70 = d42 * d67 + d43 * d68 + d44 * d69;
michael@0 9158 i3 = i5 + 4 | 0;
michael@0 9159 d71 = +HEAPF32[i3 >> 2];
michael@0 9160 i72 = i5 + 20 | 0;
michael@0 9161 d73 = +HEAPF32[i72 >> 2];
michael@0 9162 i74 = i5 + 36 | 0;
michael@0 9163 d75 = +HEAPF32[i74 >> 2];
michael@0 9164 d76 = d42 * d71 + d43 * d73 + d44 * d75;
michael@0 9165 i77 = i5 + 8 | 0;
michael@0 9166 d78 = +HEAPF32[i77 >> 2];
michael@0 9167 i79 = i5 + 24 | 0;
michael@0 9168 d80 = +HEAPF32[i79 >> 2];
michael@0 9169 i81 = i5 + 40 | 0;
michael@0 9170 d82 = +HEAPF32[i81 >> 2];
michael@0 9171 d83 = d42 * d78 + d43 * d80 + d44 * d82;
michael@0 9172 d44 = d47 * d67 + d49 * d68 + d51 * d69;
michael@0 9173 d43 = d47 * d71 + d49 * d73 + d51 * d75;
michael@0 9174 d84 = d47 * d78 + d49 * d80 + d51 * d82;
michael@0 9175 d51 = d54 * d67 + d56 * d68 + d58 * d69;
michael@0 9176 d49 = d54 * d71 + d56 * d73 + d58 * d75;
michael@0 9177 d85 = d54 * d78 + d56 * d80 + d58 * d82;
michael@0 9178 d58 = +Math_abs(+d70);
michael@0 9179 d56 = +Math_abs(+d76);
michael@0 9180 d86 = +Math_abs(+d83);
michael@0 9181 d87 = +Math_abs(+d44);
michael@0 9182 d88 = +Math_abs(+d43);
michael@0 9183 d89 = +Math_abs(+d84);
michael@0 9184 d90 = +Math_abs(+d51);
michael@0 9185 d91 = +Math_abs(+d49);
michael@0 9186 d92 = +Math_abs(+d85);
michael@0 9187 d93 = +Math_abs(+d45) - (d66 * d86 + (d60 + d64 * d58 + d65 * d56));
michael@0 9188 if (d93 > 0.0) {
michael@0 9189 i94 = 0;
michael@0 9190 STACKTOP = i12;
michael@0 9191 return i94 | 0;
michael@0 9192 }
michael@0 9193 if (d93 > -3.4028234663852886e+38) {
michael@0 9194 i95 = i2;
michael@0 9195 i96 = 1;
michael@0 9196 i97 = d45 < 0.0 | 0;
michael@0 9197 d98 = d93;
michael@0 9198 } else {
michael@0 9199 i95 = 0;
michael@0 9200 i96 = 0;
michael@0 9201 i97 = 0;
michael@0 9202 d98 = -3.4028234663852886e+38;
michael@0 9203 }
michael@0 9204 d93 = +Math_abs(+d52) - (d62 + d64 * d87 + d65 * d88 + d66 * d89);
michael@0 9205 if (d93 > 0.0) {
michael@0 9206 i94 = 0;
michael@0 9207 STACKTOP = i12;
michael@0 9208 return i94 | 0;
michael@0 9209 }
michael@0 9210 if (d93 > d98) {
michael@0 9211 i99 = i46;
michael@0 9212 i100 = 2;
michael@0 9213 i101 = d52 < 0.0 | 0;
michael@0 9214 d102 = d93;
michael@0 9215 } else {
michael@0 9216 i99 = i95;
michael@0 9217 i100 = i96;
michael@0 9218 i101 = i97;
michael@0 9219 d102 = d98;
michael@0 9220 }
michael@0 9221 d98 = +Math_abs(+d59) - (d63 + d64 * d90 + d65 * d91 + d66 * d92);
michael@0 9222 if (d98 > 0.0) {
michael@0 9223 i94 = 0;
michael@0 9224 STACKTOP = i12;
michael@0 9225 return i94 | 0;
michael@0 9226 }
michael@0 9227 if (d98 > d102) {
michael@0 9228 i103 = i53;
michael@0 9229 i104 = 3;
michael@0 9230 i105 = d59 < 0.0 | 0;
michael@0 9231 d106 = d98;
michael@0 9232 } else {
michael@0 9233 i103 = i99;
michael@0 9234 i104 = i100;
michael@0 9235 i105 = i101;
michael@0 9236 d106 = d102;
michael@0 9237 }
michael@0 9238 d102 = d37 * d67 + d39 * d68 + d41 * d69;
michael@0 9239 d69 = +Math_abs(+d102) - (d64 + (d60 * d58 + d62 * d87 + d63 * d90));
michael@0 9240 if (d69 > 0.0) {
michael@0 9241 i94 = 0;
michael@0 9242 STACKTOP = i12;
michael@0 9243 return i94 | 0;
michael@0 9244 }
michael@0 9245 if (d69 > d106) {
michael@0 9246 i107 = i5;
michael@0 9247 i108 = 4;
michael@0 9248 i109 = d102 < 0.0 | 0;
michael@0 9249 d110 = d69;
michael@0 9250 } else {
michael@0 9251 i107 = i103;
michael@0 9252 i108 = i104;
michael@0 9253 i109 = i105;
michael@0 9254 d110 = d106;
michael@0 9255 }
michael@0 9256 d106 = d37 * d71 + d39 * d73 + d41 * d75;
michael@0 9257 d75 = +Math_abs(+d106) - (d65 + (d60 * d56 + d62 * d88 + d63 * d91));
michael@0 9258 if (d75 > 0.0) {
michael@0 9259 i94 = 0;
michael@0 9260 STACKTOP = i12;
michael@0 9261 return i94 | 0;
michael@0 9262 }
michael@0 9263 if (d75 > d110) {
michael@0 9264 i111 = i3;
michael@0 9265 i112 = 5;
michael@0 9266 i113 = d106 < 0.0 | 0;
michael@0 9267 d114 = d75;
michael@0 9268 } else {
michael@0 9269 i111 = i107;
michael@0 9270 i112 = i108;
michael@0 9271 i113 = i109;
michael@0 9272 d114 = d110;
michael@0 9273 }
michael@0 9274 d110 = d37 * d78 + d39 * d80 + d41 * d82;
michael@0 9275 d82 = +Math_abs(+d110) - (d66 + (d60 * d86 + d62 * d89 + d63 * d92));
michael@0 9276 if (d82 > 0.0) {
michael@0 9277 i94 = 0;
michael@0 9278 STACKTOP = i12;
michael@0 9279 return i94 | 0;
michael@0 9280 }
michael@0 9281 if (d82 > d114) {
michael@0 9282 i115 = i77;
michael@0 9283 i116 = 6;
michael@0 9284 i117 = d110 < 0.0 | 0;
michael@0 9285 d118 = d82;
michael@0 9286 } else {
michael@0 9287 i115 = i111;
michael@0 9288 i116 = i112;
michael@0 9289 i117 = i113;
michael@0 9290 d118 = d114;
michael@0 9291 }
michael@0 9292 d114 = d58 + 9999999747378752.0e-21;
michael@0 9293 d58 = d56 + 9999999747378752.0e-21;
michael@0 9294 d56 = d86 + 9999999747378752.0e-21;
michael@0 9295 d86 = d87 + 9999999747378752.0e-21;
michael@0 9296 d87 = d88 + 9999999747378752.0e-21;
michael@0 9297 d88 = d89 + 9999999747378752.0e-21;
michael@0 9298 d89 = d90 + 9999999747378752.0e-21;
michael@0 9299 d90 = d91 + 9999999747378752.0e-21;
michael@0 9300 d91 = d92 + 9999999747378752.0e-21;
michael@0 9301 d92 = d59 * d44 - d52 * d51;
michael@0 9302 d82 = +Math_abs(+d92) - (d66 * d58 + (d65 * d56 + (d63 * d86 + d62 * d89)));
michael@0 9303 if (d82 > 1.1920928955078125e-7) {
michael@0 9304 i94 = 0;
michael@0 9305 STACKTOP = i12;
michael@0 9306 return i94 | 0;
michael@0 9307 }
michael@0 9308 d110 = -0.0 - d51;
michael@0 9309 d41 = d51 * d51 + 0.0;
michael@0 9310 d80 = d44 * d44;
michael@0 9311 d39 = +Math_sqrt(+(d80 + d41));
michael@0 9312 do {
michael@0 9313 if (d39 > 1.1920928955078125e-7) {
michael@0 9314 d78 = d82 / d39;
michael@0 9315 if (d78 * 1.0499999523162842 <= d118) {
michael@0 9316 i119 = i115;
michael@0 9317 i120 = i116;
michael@0 9318 i121 = i117;
michael@0 9319 d122 = d118;
michael@0 9320 d123 = 0.0;
michael@0 9321 d124 = 0.0;
michael@0 9322 d125 = 0.0;
michael@0 9323 break;
michael@0 9324 }
michael@0 9325 i119 = 0;
michael@0 9326 i120 = 7;
michael@0 9327 i121 = d92 < 0.0 | 0;
michael@0 9328 d122 = d78;
michael@0 9329 d123 = 0.0 / d39;
michael@0 9330 d124 = d110 / d39;
michael@0 9331 d125 = d44 / d39;
michael@0 9332 } else {
michael@0 9333 i119 = i115;
michael@0 9334 i120 = i116;
michael@0 9335 i121 = i117;
michael@0 9336 d122 = d118;
michael@0 9337 d123 = 0.0;
michael@0 9338 d124 = 0.0;
michael@0 9339 d125 = 0.0;
michael@0 9340 }
michael@0 9341 } while (0);
michael@0 9342 d118 = d59 * d43 - d52 * d49;
michael@0 9343 d39 = +Math_abs(+d118) - (d66 * d114 + (d64 * d56 + (d63 * d87 + d62 * d90)));
michael@0 9344 if (d39 > 1.1920928955078125e-7) {
michael@0 9345 i94 = 0;
michael@0 9346 STACKTOP = i12;
michael@0 9347 return i94 | 0;
michael@0 9348 }
michael@0 9349 d110 = -0.0 - d49;
michael@0 9350 d92 = d49 * d49 + 0.0;
michael@0 9351 d82 = d43 * d43;
michael@0 9352 d78 = +Math_sqrt(+(d82 + d92));
michael@0 9353 do {
michael@0 9354 if (d78 > 1.1920928955078125e-7) {
michael@0 9355 d37 = d39 / d78;
michael@0 9356 if (d37 * 1.0499999523162842 <= d122) {
michael@0 9357 i126 = i119;
michael@0 9358 i127 = i120;
michael@0 9359 i128 = i121;
michael@0 9360 d129 = d122;
michael@0 9361 d130 = d123;
michael@0 9362 d131 = d124;
michael@0 9363 d132 = d125;
michael@0 9364 break;
michael@0 9365 }
michael@0 9366 i126 = 0;
michael@0 9367 i127 = 8;
michael@0 9368 i128 = d118 < 0.0 | 0;
michael@0 9369 d129 = d37;
michael@0 9370 d130 = 0.0 / d78;
michael@0 9371 d131 = d110 / d78;
michael@0 9372 d132 = d43 / d78;
michael@0 9373 } else {
michael@0 9374 i126 = i119;
michael@0 9375 i127 = i120;
michael@0 9376 i128 = i121;
michael@0 9377 d129 = d122;
michael@0 9378 d130 = d123;
michael@0 9379 d131 = d124;
michael@0 9380 d132 = d125;
michael@0 9381 }
michael@0 9382 } while (0);
michael@0 9383 d125 = d59 * d84 - d52 * d85;
michael@0 9384 d124 = +Math_abs(+d125) - (d65 * d114 + (d64 * d58 + (d63 * d88 + d62 * d91)));
michael@0 9385 if (d124 > 1.1920928955078125e-7) {
michael@0 9386 i94 = 0;
michael@0 9387 STACKTOP = i12;
michael@0 9388 return i94 | 0;
michael@0 9389 }
michael@0 9390 d123 = -0.0 - d85;
michael@0 9391 d122 = d85 * d85 + 0.0;
michael@0 9392 d78 = d84 * d84;
michael@0 9393 d110 = +Math_sqrt(+(d78 + d122));
michael@0 9394 do {
michael@0 9395 if (d110 > 1.1920928955078125e-7) {
michael@0 9396 d118 = d124 / d110;
michael@0 9397 if (d118 * 1.0499999523162842 <= d129) {
michael@0 9398 i133 = i126;
michael@0 9399 i134 = i127;
michael@0 9400 i135 = i128;
michael@0 9401 d136 = d129;
michael@0 9402 d137 = d130;
michael@0 9403 d138 = d131;
michael@0 9404 d139 = d132;
michael@0 9405 break;
michael@0 9406 }
michael@0 9407 i133 = 0;
michael@0 9408 i134 = 9;
michael@0 9409 i135 = d125 < 0.0 | 0;
michael@0 9410 d136 = d118;
michael@0 9411 d137 = 0.0 / d110;
michael@0 9412 d138 = d123 / d110;
michael@0 9413 d139 = d84 / d110;
michael@0 9414 } else {
michael@0 9415 i133 = i126;
michael@0 9416 i134 = i127;
michael@0 9417 i135 = i128;
michael@0 9418 d136 = d129;
michael@0 9419 d137 = d130;
michael@0 9420 d138 = d131;
michael@0 9421 d139 = d132;
michael@0 9422 }
michael@0 9423 } while (0);
michael@0 9424 d132 = d45 * d51 - d59 * d70;
michael@0 9425 d131 = +Math_abs(+d132) - (d66 * d87 + (d65 * d88 + (d63 * d114 + d60 * d89)));
michael@0 9426 if (d131 > 1.1920928955078125e-7) {
michael@0 9427 i94 = 0;
michael@0 9428 STACKTOP = i12;
michael@0 9429 return i94 | 0;
michael@0 9430 }
michael@0 9431 d130 = -0.0 - d70;
michael@0 9432 d129 = d70 * d70;
michael@0 9433 d110 = +Math_sqrt(+(d129 + d41));
michael@0 9434 do {
michael@0 9435 if (d110 > 1.1920928955078125e-7) {
michael@0 9436 d41 = d131 / d110;
michael@0 9437 if (d41 * 1.0499999523162842 <= d136) {
michael@0 9438 i140 = i133;
michael@0 9439 i141 = i134;
michael@0 9440 i142 = i135;
michael@0 9441 d143 = d136;
michael@0 9442 d144 = d137;
michael@0 9443 d145 = d138;
michael@0 9444 d146 = d139;
michael@0 9445 break;
michael@0 9446 }
michael@0 9447 i140 = 0;
michael@0 9448 i141 = 10;
michael@0 9449 i142 = d132 < 0.0 | 0;
michael@0 9450 d143 = d41;
michael@0 9451 d144 = d51 / d110;
michael@0 9452 d145 = 0.0 / d110;
michael@0 9453 d146 = d130 / d110;
michael@0 9454 } else {
michael@0 9455 i140 = i133;
michael@0 9456 i141 = i134;
michael@0 9457 i142 = i135;
michael@0 9458 d143 = d136;
michael@0 9459 d144 = d137;
michael@0 9460 d145 = d138;
michael@0 9461 d146 = d139;
michael@0 9462 }
michael@0 9463 } while (0);
michael@0 9464 d139 = d45 * d49 - d59 * d76;
michael@0 9465 d138 = +Math_abs(+d139) - (d66 * d86 + (d64 * d88 + (d63 * d58 + d60 * d90)));
michael@0 9466 if (d138 > 1.1920928955078125e-7) {
michael@0 9467 i94 = 0;
michael@0 9468 STACKTOP = i12;
michael@0 9469 return i94 | 0;
michael@0 9470 }
michael@0 9471 d137 = -0.0 - d76;
michael@0 9472 d136 = d76 * d76;
michael@0 9473 d110 = +Math_sqrt(+(d136 + d92));
michael@0 9474 do {
michael@0 9475 if (d110 > 1.1920928955078125e-7) {
michael@0 9476 d92 = d138 / d110;
michael@0 9477 if (d92 * 1.0499999523162842 <= d143) {
michael@0 9478 i147 = i140;
michael@0 9479 i148 = i141;
michael@0 9480 i149 = i142;
michael@0 9481 d150 = d143;
michael@0 9482 d151 = d144;
michael@0 9483 d152 = d145;
michael@0 9484 d153 = d146;
michael@0 9485 break;
michael@0 9486 }
michael@0 9487 i147 = 0;
michael@0 9488 i148 = 11;
michael@0 9489 i149 = d139 < 0.0 | 0;
michael@0 9490 d150 = d92;
michael@0 9491 d151 = d49 / d110;
michael@0 9492 d152 = 0.0 / d110;
michael@0 9493 d153 = d137 / d110;
michael@0 9494 } else {
michael@0 9495 i147 = i140;
michael@0 9496 i148 = i141;
michael@0 9497 i149 = i142;
michael@0 9498 d150 = d143;
michael@0 9499 d151 = d144;
michael@0 9500 d152 = d145;
michael@0 9501 d153 = d146;
michael@0 9502 }
michael@0 9503 } while (0);
michael@0 9504 d146 = d45 * d85 - d59 * d83;
michael@0 9505 d59 = +Math_abs(+d146) - (d65 * d86 + (d64 * d87 + (d63 * d56 + d60 * d91)));
michael@0 9506 if (d59 > 1.1920928955078125e-7) {
michael@0 9507 i94 = 0;
michael@0 9508 STACKTOP = i12;
michael@0 9509 return i94 | 0;
michael@0 9510 }
michael@0 9511 d145 = -0.0 - d83;
michael@0 9512 d144 = d83 * d83;
michael@0 9513 d143 = +Math_sqrt(+(d144 + d122));
michael@0 9514 do {
michael@0 9515 if (d143 > 1.1920928955078125e-7) {
michael@0 9516 d122 = d59 / d143;
michael@0 9517 if (d122 * 1.0499999523162842 <= d150) {
michael@0 9518 i154 = i147;
michael@0 9519 i155 = i148;
michael@0 9520 i156 = i149;
michael@0 9521 d157 = d150;
michael@0 9522 d158 = d151;
michael@0 9523 d159 = d152;
michael@0 9524 d160 = d153;
michael@0 9525 break;
michael@0 9526 }
michael@0 9527 i154 = 0;
michael@0 9528 i155 = 12;
michael@0 9529 i156 = d146 < 0.0 | 0;
michael@0 9530 d157 = d122;
michael@0 9531 d158 = d85 / d143;
michael@0 9532 d159 = 0.0 / d143;
michael@0 9533 d160 = d145 / d143;
michael@0 9534 } else {
michael@0 9535 i154 = i147;
michael@0 9536 i155 = i148;
michael@0 9537 i156 = i149;
michael@0 9538 d157 = d150;
michael@0 9539 d158 = d151;
michael@0 9540 d159 = d152;
michael@0 9541 d160 = d153;
michael@0 9542 }
michael@0 9543 } while (0);
michael@0 9544 d153 = d52 * d70 - d45 * d44;
michael@0 9545 d152 = +Math_abs(+d153) - (d66 * d90 + (d62 * d114 + d60 * d86 + d65 * d91));
michael@0 9546 if (d152 > 1.1920928955078125e-7) {
michael@0 9547 i94 = 0;
michael@0 9548 STACKTOP = i12;
michael@0 9549 return i94 | 0;
michael@0 9550 }
michael@0 9551 d86 = -0.0 - d44;
michael@0 9552 d44 = +Math_sqrt(+(d129 + d80 + 0.0));
michael@0 9553 do {
michael@0 9554 if (d44 > 1.1920928955078125e-7) {
michael@0 9555 d80 = d152 / d44;
michael@0 9556 if (d80 * 1.0499999523162842 <= d157) {
michael@0 9557 i161 = i154;
michael@0 9558 i162 = i155;
michael@0 9559 i163 = i156;
michael@0 9560 d164 = d157;
michael@0 9561 d165 = d158;
michael@0 9562 d166 = d159;
michael@0 9563 d167 = d160;
michael@0 9564 break;
michael@0 9565 }
michael@0 9566 i161 = 0;
michael@0 9567 i162 = 13;
michael@0 9568 i163 = d153 < 0.0 | 0;
michael@0 9569 d164 = d80;
michael@0 9570 d165 = d86 / d44;
michael@0 9571 d166 = d70 / d44;
michael@0 9572 d167 = 0.0 / d44;
michael@0 9573 } else {
michael@0 9574 i161 = i154;
michael@0 9575 i162 = i155;
michael@0 9576 i163 = i156;
michael@0 9577 d164 = d157;
michael@0 9578 d165 = d158;
michael@0 9579 d166 = d159;
michael@0 9580 d167 = d160;
michael@0 9581 }
michael@0 9582 } while (0);
michael@0 9583 d160 = d52 * d76 - d45 * d43;
michael@0 9584 d159 = +Math_abs(+d160) - (d66 * d89 + (d62 * d58 + d60 * d87 + d64 * d91));
michael@0 9585 if (d159 > 1.1920928955078125e-7) {
michael@0 9586 i94 = 0;
michael@0 9587 STACKTOP = i12;
michael@0 9588 return i94 | 0;
michael@0 9589 }
michael@0 9590 d91 = -0.0 - d43;
michael@0 9591 d43 = +Math_sqrt(+(d136 + d82 + 0.0));
michael@0 9592 do {
michael@0 9593 if (d43 > 1.1920928955078125e-7) {
michael@0 9594 d82 = d159 / d43;
michael@0 9595 if (d82 * 1.0499999523162842 <= d164) {
michael@0 9596 i168 = i161;
michael@0 9597 i169 = i162;
michael@0 9598 i170 = i163;
michael@0 9599 d171 = d164;
michael@0 9600 d172 = d165;
michael@0 9601 d173 = d166;
michael@0 9602 d174 = d167;
michael@0 9603 break;
michael@0 9604 }
michael@0 9605 i168 = 0;
michael@0 9606 i169 = 14;
michael@0 9607 i170 = d160 < 0.0 | 0;
michael@0 9608 d171 = d82;
michael@0 9609 d172 = d91 / d43;
michael@0 9610 d173 = d76 / d43;
michael@0 9611 d174 = 0.0 / d43;
michael@0 9612 } else {
michael@0 9613 i168 = i161;
michael@0 9614 i169 = i162;
michael@0 9615 i170 = i163;
michael@0 9616 d171 = d164;
michael@0 9617 d172 = d165;
michael@0 9618 d173 = d166;
michael@0 9619 d174 = d167;
michael@0 9620 }
michael@0 9621 } while (0);
michael@0 9622 d167 = d52 * d83 - d45 * d84;
michael@0 9623 d45 = +Math_abs(+d167) - (d65 * d89 + (d62 * d56 + d60 * d88 + d64 * d90));
michael@0 9624 if (d45 > 1.1920928955078125e-7) {
michael@0 9625 i94 = 0;
michael@0 9626 STACKTOP = i12;
michael@0 9627 return i94 | 0;
michael@0 9628 }
michael@0 9629 d90 = -0.0 - d84;
michael@0 9630 d84 = +Math_sqrt(+(d144 + d78 + 0.0));
michael@0 9631 do {
michael@0 9632 if (d84 > 1.1920928955078125e-7) {
michael@0 9633 d78 = d45 / d84;
michael@0 9634 if (d78 * 1.0499999523162842 <= d171) {
michael@0 9635 i175 = 899;
michael@0 9636 break;
michael@0 9637 }
michael@0 9638 i176 = 15;
michael@0 9639 i177 = d167 < 0.0 | 0;
michael@0 9640 d178 = d78;
michael@0 9641 d179 = d90 / d84;
michael@0 9642 d180 = d83 / d84;
michael@0 9643 d181 = 0.0 / d84;
michael@0 9644 i175 = 902;
michael@0 9645 } else {
michael@0 9646 i175 = 899;
michael@0 9647 }
michael@0 9648 } while (0);
michael@0 9649 do {
michael@0 9650 if ((i175 | 0) == 899) {
michael@0 9651 if ((i169 | 0) == 0) {
michael@0 9652 i94 = 0;
michael@0 9653 STACKTOP = i12;
michael@0 9654 return i94 | 0;
michael@0 9655 }
michael@0 9656 if ((i168 | 0) == 0) {
michael@0 9657 i176 = i169;
michael@0 9658 i177 = i170;
michael@0 9659 d178 = d171;
michael@0 9660 d179 = d172;
michael@0 9661 d180 = d173;
michael@0 9662 d181 = d174;
michael@0 9663 i175 = 902;
michael@0 9664 break;
michael@0 9665 }
michael@0 9666 d84 = +HEAPF32[i168 >> 2];
michael@0 9667 HEAPF32[i7 >> 2] = d84;
michael@0 9668 d83 = +HEAPF32[i168 + 16 >> 2];
michael@0 9669 HEAPF32[i7 + 4 >> 2] = d83;
michael@0 9670 d90 = +HEAPF32[i168 + 32 >> 2];
michael@0 9671 HEAPF32[i7 + 8 >> 2] = d90;
michael@0 9672 i182 = i169;
michael@0 9673 i183 = i170;
michael@0 9674 d184 = d171;
michael@0 9675 d185 = d84;
michael@0 9676 d186 = d83;
michael@0 9677 d187 = d90;
michael@0 9678 }
michael@0 9679 } while (0);
michael@0 9680 if ((i175 | 0) == 902) {
michael@0 9681 d171 = d54 * d181 + (d47 * d180 + d42 * d179);
michael@0 9682 HEAPF32[i7 >> 2] = d171;
michael@0 9683 d42 = d179 * +HEAPF32[i4 >> 2] + d180 * +HEAPF32[i48 >> 2] + d181 * +HEAPF32[i55 >> 2];
michael@0 9684 HEAPF32[i7 + 4 >> 2] = d42;
michael@0 9685 d47 = d179 * +HEAPF32[i1 >> 2] + d180 * +HEAPF32[i50 >> 2] + d181 * +HEAPF32[i57 >> 2];
michael@0 9686 HEAPF32[i7 + 8 >> 2] = d47;
michael@0 9687 i182 = i176;
michael@0 9688 i183 = i177;
michael@0 9689 d184 = d178;
michael@0 9690 d185 = d171;
michael@0 9691 d186 = d42;
michael@0 9692 d187 = d47;
michael@0 9693 }
michael@0 9694 if ((i183 | 0) != 0) {
michael@0 9695 HEAPF32[i7 >> 2] = -0.0 - d185;
michael@0 9696 HEAPF32[i7 + 4 >> 2] = -0.0 - d186;
michael@0 9697 HEAPF32[i7 + 8 >> 2] = -0.0 - d187;
michael@0 9698 }
michael@0 9699 HEAPF32[i8 >> 2] = -0.0 - d184;
michael@0 9700 if ((i182 | 0) > 6) {
michael@0 9701 d187 = +HEAPF32[i7 >> 2];
michael@0 9702 d186 = +HEAPF32[i7 + 4 >> 2];
michael@0 9703 d185 = +HEAPF32[i7 + 8 >> 2];
michael@0 9704 d47 = +HEAPF32[i2 >> 2];
michael@0 9705 d42 = +HEAPF32[i4 >> 2];
michael@0 9706 d171 = +HEAPF32[i1 >> 2];
michael@0 9707 d178 = d60 * (d187 * d47 + d186 * d42 + d185 * d171 > 0.0 ? 1.0 : -1.0);
michael@0 9708 d60 = +HEAPF32[i46 >> 2];
michael@0 9709 d181 = +HEAPF32[i48 >> 2];
michael@0 9710 d180 = +HEAPF32[i50 >> 2];
michael@0 9711 d179 = d62 * (d187 * d60 + d186 * d181 + d185 * d180 > 0.0 ? 1.0 : -1.0);
michael@0 9712 d62 = +HEAPF32[i53 >> 2];
michael@0 9713 d54 = +HEAPF32[i55 >> 2];
michael@0 9714 d174 = +HEAPF32[i57 >> 2];
michael@0 9715 d173 = d63 * (d187 * d62 + d186 * d54 + d185 * d174 > 0.0 ? 1.0 : -1.0);
michael@0 9716 d63 = +HEAPF32[i36 >> 2] + d47 * d178 + d60 * d179 + d62 * d173;
michael@0 9717 d62 = +HEAPF32[i38 >> 2] + d42 * d178 + d181 * d179 + d54 * d173;
michael@0 9718 d54 = +HEAPF32[i40 >> 2] + d171 * d178 + d180 * d179 + d174 * d173;
michael@0 9719 HEAP32[i18 >> 2] = HEAP32[i11 >> 2];
michael@0 9720 HEAP32[i18 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 9721 HEAP32[i18 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 9722 d173 = +HEAPF32[i5 >> 2];
michael@0 9723 d174 = +HEAPF32[i16 >> 2];
michael@0 9724 d179 = +HEAPF32[i6 >> 2];
michael@0 9725 d180 = d64 * (d187 * d173 + d186 * d174 + d185 * d179 > 0.0 ? -1.0 : 1.0);
michael@0 9726 i6 = i17 | 0;
michael@0 9727 i16 = i17 + 4 | 0;
michael@0 9728 i11 = i17 + 8 | 0;
michael@0 9729 d64 = +HEAPF32[i3 >> 2];
michael@0 9730 d178 = +HEAPF32[i72 >> 2];
michael@0 9731 d171 = +HEAPF32[i74 >> 2];
michael@0 9732 d181 = d65 * (d187 * d64 + d186 * d178 + d185 * d171 > 0.0 ? -1.0 : 1.0);
michael@0 9733 d65 = +HEAPF32[i16 >> 2] + d174 * d180 + d178 * d181;
michael@0 9734 d178 = +HEAPF32[i11 >> 2] + d179 * d180 + d171 * d181;
michael@0 9735 d171 = +HEAPF32[i77 >> 2];
michael@0 9736 d179 = +HEAPF32[i79 >> 2];
michael@0 9737 d174 = +HEAPF32[i81 >> 2];
michael@0 9738 d42 = d66 * (d187 * d171 + d186 * d179 + d185 * d174 > 0.0 ? -1.0 : 1.0);
michael@0 9739 d66 = +HEAPF32[i6 >> 2] + d173 * d180 + d64 * d181 + d171 * d42;
michael@0 9740 HEAPF32[i6 >> 2] = d66;
michael@0 9741 d171 = d65 + d179 * d42;
michael@0 9742 HEAPF32[i16 >> 2] = d171;
michael@0 9743 d179 = d178 + d174 * d42;
michael@0 9744 HEAPF32[i11 >> 2] = d179;
michael@0 9745 i81 = i182 - 7 | 0;
michael@0 9746 i79 = (i81 | 0) / 3 | 0;
michael@0 9747 d42 = +HEAPF32[i2 + (i79 << 2) >> 2];
michael@0 9748 d174 = +HEAPF32[i2 + (i79 + 4 << 2) >> 2];
michael@0 9749 d178 = +HEAPF32[i2 + (i79 + 8 << 2) >> 2];
michael@0 9750 i79 = (i81 | 0) % 3 | 0;
michael@0 9751 d65 = +HEAPF32[i5 + (i79 << 2) >> 2];
michael@0 9752 d181 = +HEAPF32[i5 + (i79 + 4 << 2) >> 2];
michael@0 9753 d64 = +HEAPF32[i5 + (i79 + 8 << 2) >> 2];
michael@0 9754 d180 = d66 - d63;
michael@0 9755 d63 = d171 - d62;
michael@0 9756 d62 = d179 - d54;
michael@0 9757 d54 = d42 * d65 + d174 * d181 + d178 * d64;
michael@0 9758 d173 = 1.0 - d54 * d54;
michael@0 9759 if (d173 > 9999999747378752.0e-20) {
michael@0 9760 d188 = (d54 * (d178 * d62 + (d42 * d180 + d174 * d63)) - (d62 * d64 + (d65 * d180 + d181 * d63))) * (1.0 / d173);
michael@0 9761 } else {
michael@0 9762 d188 = 0.0;
michael@0 9763 }
michael@0 9764 HEAPF32[i6 >> 2] = d66 + d65 * d188;
michael@0 9765 HEAPF32[i16 >> 2] = d171 + d181 * d188;
michael@0 9766 HEAPF32[i11 >> 2] = d179 + d64 * d188;
michael@0 9767 i11 = HEAP32[(HEAP32[i13 >> 2] | 0) + 16 >> 2] | 0;
michael@0 9768 HEAPF32[i19 >> 2] = -0.0 - d187;
michael@0 9769 HEAPF32[i19 + 4 >> 2] = -0.0 - d186;
michael@0 9770 HEAPF32[i19 + 8 >> 2] = -0.0 - d185;
michael@0 9771 HEAPF32[i19 + 12 >> 2] = 0.0;
michael@0 9772 FUNCTION_TABLE_viiif[i11 & 15](i13, i19, i17, d184);
michael@0 9773 HEAP32[i9 >> 2] = i182;
michael@0 9774 i94 = 1;
michael@0 9775 STACKTOP = i12;
michael@0 9776 return i94 | 0;
michael@0 9777 }
michael@0 9778 i17 = (i182 | 0) < 4;
michael@0 9779 i19 = i7 | 0;
michael@0 9780 d184 = +HEAPF32[i19 >> 2];
michael@0 9781 if (i17) {
michael@0 9782 d189 = d184;
michael@0 9783 d190 = +HEAPF32[i7 + 4 >> 2];
michael@0 9784 d191 = +HEAPF32[i7 + 8 >> 2];
michael@0 9785 i192 = i2;
michael@0 9786 i193 = i5;
michael@0 9787 i194 = i36;
michael@0 9788 i195 = i35;
michael@0 9789 i196 = i61;
michael@0 9790 i197 = i15;
michael@0 9791 } else {
michael@0 9792 d189 = -0.0 - d184;
michael@0 9793 d190 = -0.0 - +HEAPF32[i7 + 4 >> 2];
michael@0 9794 d191 = -0.0 - +HEAPF32[i7 + 8 >> 2];
michael@0 9795 i192 = i5;
michael@0 9796 i193 = i2;
michael@0 9797 i194 = i35;
michael@0 9798 i195 = i36;
michael@0 9799 i196 = i15;
michael@0 9800 i197 = i61;
michael@0 9801 }
michael@0 9802 d184 = d189 * +HEAPF32[i193 >> 2] + d190 * +HEAPF32[i193 + 16 >> 2] + d191 * +HEAPF32[i193 + 32 >> 2];
michael@0 9803 HEAPF32[i20 >> 2] = d184;
michael@0 9804 d185 = d189 * +HEAPF32[i193 + 4 >> 2] + d190 * +HEAPF32[i193 + 20 >> 2] + d191 * +HEAPF32[i193 + 36 >> 2];
michael@0 9805 HEAPF32[i20 + 4 >> 2] = d185;
michael@0 9806 d186 = d189 * +HEAPF32[i193 + 8 >> 2] + d190 * +HEAPF32[i193 + 24 >> 2] + d191 * +HEAPF32[i193 + 40 >> 2];
michael@0 9807 HEAPF32[i20 + 8 >> 2] = d186;
michael@0 9808 d187 = +Math_abs(+d184);
michael@0 9809 d184 = +Math_abs(+d185);
michael@0 9810 d185 = +Math_abs(+d186);
michael@0 9811 if (d184 > d187) {
michael@0 9812 i61 = d184 > d185;
michael@0 9813 i198 = 0;
michael@0 9814 i199 = i61 ? 1 : 2;
michael@0 9815 i200 = i61;
michael@0 9816 } else {
michael@0 9817 i61 = d187 > d185;
michael@0 9818 i198 = i61 & 1;
michael@0 9819 i199 = i61 ? 0 : 2;
michael@0 9820 i200 = i61;
michael@0 9821 }
michael@0 9822 i61 = i200 ? 2 : 1;
michael@0 9823 d185 = +HEAPF32[i197 + (i199 << 2) >> 2];
michael@0 9824 d187 = +HEAPF32[i195 >> 2] - +HEAPF32[i194 >> 2];
michael@0 9825 d184 = d185 * +HEAPF32[i193 + (i199 << 2) >> 2];
michael@0 9826 if (+HEAPF32[i20 + (i199 << 2) >> 2] < 0.0) {
michael@0 9827 d201 = d187 + d184;
michael@0 9828 d202 = +HEAPF32[i195 + 4 >> 2] - +HEAPF32[i194 + 4 >> 2] + d185 * +HEAPF32[i193 + ((i199 | 4) << 2) >> 2];
michael@0 9829 d203 = +HEAPF32[i195 + 8 >> 2] - +HEAPF32[i194 + 8 >> 2] + d185 * +HEAPF32[i193 + ((i199 | 8) << 2) >> 2];
michael@0 9830 } else {
michael@0 9831 d201 = d187 - d184;
michael@0 9832 d202 = +HEAPF32[i195 + 4 >> 2] - +HEAPF32[i194 + 4 >> 2] - d185 * +HEAPF32[i193 + ((i199 | 4) << 2) >> 2];
michael@0 9833 d203 = +HEAPF32[i195 + 8 >> 2] - +HEAPF32[i194 + 8 >> 2] - d185 * +HEAPF32[i193 + ((i199 | 8) << 2) >> 2];
michael@0 9834 }
michael@0 9835 i199 = (i17 ? -1 : -4) + i182 | 0;
michael@0 9836 if ((i199 | 0) == 1) {
michael@0 9837 i204 = 2;
michael@0 9838 i205 = 0;
michael@0 9839 } else if ((i199 | 0) == 0) {
michael@0 9840 i204 = 2;
michael@0 9841 i205 = 1;
michael@0 9842 } else {
michael@0 9843 i204 = 1;
michael@0 9844 i205 = 0;
michael@0 9845 }
michael@0 9846 d185 = +HEAPF32[i192 + (i205 << 2) >> 2];
michael@0 9847 d184 = +HEAPF32[i192 + ((i205 | 4) << 2) >> 2];
michael@0 9848 d187 = +HEAPF32[i192 + ((i205 | 8) << 2) >> 2];
michael@0 9849 d186 = d201 * d185 + d202 * d184 + d203 * d187;
michael@0 9850 d188 = +HEAPF32[i192 + (i204 << 2) >> 2];
michael@0 9851 d64 = +HEAPF32[i192 + ((i204 | 4) << 2) >> 2];
michael@0 9852 d179 = +HEAPF32[i192 + ((i204 | 8) << 2) >> 2];
michael@0 9853 d181 = d201 * d188 + d202 * d64 + d203 * d179;
michael@0 9854 i192 = i193 + (i198 << 2) | 0;
michael@0 9855 d171 = +HEAPF32[i192 >> 2];
michael@0 9856 i195 = i193 + ((i198 | 4) << 2) | 0;
michael@0 9857 d65 = +HEAPF32[i195 >> 2];
michael@0 9858 i20 = i193 + ((i198 | 8) << 2) | 0;
michael@0 9859 d66 = +HEAPF32[i20 >> 2];
michael@0 9860 d173 = d185 * d171 + d184 * d65 + d187 * d66;
michael@0 9861 i200 = i193 + (i61 << 2) | 0;
michael@0 9862 d63 = +HEAPF32[i200 >> 2];
michael@0 9863 i15 = i193 + ((i61 | 4) << 2) | 0;
michael@0 9864 d180 = +HEAPF32[i15 >> 2];
michael@0 9865 i36 = i193 + ((i61 | 8) << 2) | 0;
michael@0 9866 d62 = +HEAPF32[i36 >> 2];
michael@0 9867 d174 = d185 * d63 + d184 * d180 + d187 * d62;
michael@0 9868 d187 = d188 * d171 + d64 * d65 + d179 * d66;
michael@0 9869 d66 = d188 * d63 + d64 * d180 + d179 * d62;
michael@0 9870 d62 = +HEAPF32[i197 + (i198 << 2) >> 2];
michael@0 9871 d179 = d173 * d62;
michael@0 9872 d180 = d187 * d62;
michael@0 9873 d62 = +HEAPF32[i197 + (i61 << 2) >> 2];
michael@0 9874 d64 = d174 * d62;
michael@0 9875 d63 = d66 * d62;
michael@0 9876 d62 = d186 - d179;
michael@0 9877 i61 = i21 | 0;
michael@0 9878 HEAPF32[i61 >> 2] = d62 - d64;
michael@0 9879 d188 = d181 - d180;
michael@0 9880 HEAPF32[i21 + 4 >> 2] = d188 - d63;
michael@0 9881 HEAPF32[i21 + 8 >> 2] = d62 + d64;
michael@0 9882 HEAPF32[i21 + 12 >> 2] = d188 + d63;
michael@0 9883 d188 = d186 + d179;
michael@0 9884 HEAPF32[i21 + 16 >> 2] = d188 + d64;
michael@0 9885 d179 = d181 + d180;
michael@0 9886 HEAPF32[i21 + 20 >> 2] = d179 + d63;
michael@0 9887 HEAPF32[i21 + 24 >> 2] = d188 - d64;
michael@0 9888 HEAPF32[i21 + 28 >> 2] = d179 - d63;
michael@0 9889 HEAPF32[i22 >> 2] = +HEAPF32[i196 + (i205 << 2) >> 2];
michael@0 9890 HEAPF32[i22 + 4 >> 2] = +HEAPF32[i196 + (i204 << 2) >> 2];
michael@0 9891 i204 = i23 | 0;
michael@0 9892 i205 = i14 | 0;
michael@0 9893 i14 = i61;
michael@0 9894 i61 = i204;
michael@0 9895 i21 = 0;
michael@0 9896 i197 = 4;
michael@0 9897 L1130 : while (1) {
michael@0 9898 i198 = i22 + (i21 << 2) | 0;
michael@0 9899 i193 = 1 - i21 | 0;
michael@0 9900 do {
michael@0 9901 if ((i197 | 0) > 0) {
michael@0 9902 i35 = 0;
michael@0 9903 i2 = i14;
michael@0 9904 i5 = i61;
michael@0 9905 i11 = i197;
michael@0 9906 while (1) {
michael@0 9907 i16 = i2 + (i21 << 2) | 0;
michael@0 9908 d63 = +HEAPF32[i16 >> 2];
michael@0 9909 d179 = +HEAPF32[i198 >> 2];
michael@0 9910 if (d63 * -1.0 < d179) {
michael@0 9911 HEAPF32[i5 >> 2] = +HEAPF32[i2 >> 2];
michael@0 9912 HEAPF32[i5 + 4 >> 2] = +HEAPF32[i2 + 4 >> 2];
michael@0 9913 i6 = i35 + 1 | 0;
michael@0 9914 if ((i6 & 8 | 0) != 0) {
michael@0 9915 i206 = i6;
michael@0 9916 i207 = i61;
michael@0 9917 break L1130;
michael@0 9918 }
michael@0 9919 i208 = i5 + 8 | 0;
michael@0 9920 i209 = i6;
michael@0 9921 d210 = +HEAPF32[i16 >> 2];
michael@0 9922 d211 = +HEAPF32[i198 >> 2];
michael@0 9923 } else {
michael@0 9924 i208 = i5;
michael@0 9925 i209 = i35;
michael@0 9926 d210 = d63;
michael@0 9927 d211 = d179;
michael@0 9928 }
michael@0 9929 i16 = i2 + 8 | 0;
michael@0 9930 i6 = (i11 | 0) > 1 ? i16 : i14;
michael@0 9931 d179 = +HEAPF32[i6 + (i21 << 2) >> 2];
michael@0 9932 if (d210 * -1.0 < d211 ^ d179 * -1.0 < d211) {
michael@0 9933 d63 = +HEAPF32[i2 + (i193 << 2) >> 2];
michael@0 9934 HEAPF32[i208 + (i193 << 2) >> 2] = d63 + (d211 * -1.0 - d210) * ((+HEAPF32[i6 + (i193 << 2) >> 2] - d63) / (d179 - d210));
michael@0 9935 HEAPF32[i208 + (i21 << 2) >> 2] = +HEAPF32[i198 >> 2] * -1.0;
michael@0 9936 i6 = i209 + 1 | 0;
michael@0 9937 if ((i6 & 8 | 0) == 0) {
michael@0 9938 i212 = i208 + 8 | 0;
michael@0 9939 i213 = i6;
michael@0 9940 } else {
michael@0 9941 i206 = i6;
michael@0 9942 i207 = i61;
michael@0 9943 break L1130;
michael@0 9944 }
michael@0 9945 } else {
michael@0 9946 i212 = i208;
michael@0 9947 i213 = i209;
michael@0 9948 }
michael@0 9949 i6 = i11 - 1 | 0;
michael@0 9950 if ((i6 | 0) > 0) {
michael@0 9951 i35 = i213;
michael@0 9952 i2 = i16;
michael@0 9953 i5 = i212;
michael@0 9954 i11 = i6;
michael@0 9955 } else {
michael@0 9956 break;
michael@0 9957 }
michael@0 9958 }
michael@0 9959 i11 = (i61 | 0) == (i204 | 0) ? i205 : i204;
michael@0 9960 if ((i213 | 0) > 0) {
michael@0 9961 i214 = 0;
michael@0 9962 i215 = i61;
michael@0 9963 i216 = i11;
michael@0 9964 i217 = i213;
michael@0 9965 } else {
michael@0 9966 i218 = 0;
michael@0 9967 i219 = i11;
michael@0 9968 break;
michael@0 9969 }
michael@0 9970 while (1) {
michael@0 9971 i5 = i215 + (i21 << 2) | 0;
michael@0 9972 d179 = +HEAPF32[i5 >> 2];
michael@0 9973 d63 = +HEAPF32[i198 >> 2];
michael@0 9974 if (d179 < d63) {
michael@0 9975 HEAPF32[i216 >> 2] = +HEAPF32[i215 >> 2];
michael@0 9976 HEAPF32[i216 + 4 >> 2] = +HEAPF32[i215 + 4 >> 2];
michael@0 9977 i2 = i214 + 1 | 0;
michael@0 9978 if ((i2 & 8 | 0) != 0) {
michael@0 9979 i206 = i2;
michael@0 9980 i207 = i11;
michael@0 9981 break L1130;
michael@0 9982 }
michael@0 9983 i220 = i216 + 8 | 0;
michael@0 9984 i221 = i2;
michael@0 9985 d222 = +HEAPF32[i5 >> 2];
michael@0 9986 d223 = +HEAPF32[i198 >> 2];
michael@0 9987 } else {
michael@0 9988 i220 = i216;
michael@0 9989 i221 = i214;
michael@0 9990 d222 = d179;
michael@0 9991 d223 = d63;
michael@0 9992 }
michael@0 9993 i5 = i215 + 8 | 0;
michael@0 9994 i2 = (i217 | 0) > 1 ? i5 : i61;
michael@0 9995 d63 = +HEAPF32[i2 + (i21 << 2) >> 2];
michael@0 9996 if (d222 < d223 ^ d63 < d223) {
michael@0 9997 d179 = +HEAPF32[i215 + (i193 << 2) >> 2];
michael@0 9998 HEAPF32[i220 + (i193 << 2) >> 2] = d179 + (d223 - d222) * ((+HEAPF32[i2 + (i193 << 2) >> 2] - d179) / (d63 - d222));
michael@0 9999 HEAPF32[i220 + (i21 << 2) >> 2] = +HEAPF32[i198 >> 2];
michael@0 10000 i2 = i221 + 1 | 0;
michael@0 10001 if ((i2 & 8 | 0) == 0) {
michael@0 10002 i224 = i220 + 8 | 0;
michael@0 10003 i225 = i2;
michael@0 10004 } else {
michael@0 10005 i206 = i2;
michael@0 10006 i207 = i11;
michael@0 10007 break L1130;
michael@0 10008 }
michael@0 10009 } else {
michael@0 10010 i224 = i220;
michael@0 10011 i225 = i221;
michael@0 10012 }
michael@0 10013 i2 = i217 - 1 | 0;
michael@0 10014 if ((i2 | 0) > 0) {
michael@0 10015 i214 = i225;
michael@0 10016 i215 = i5;
michael@0 10017 i216 = i224;
michael@0 10018 i217 = i2;
michael@0 10019 } else {
michael@0 10020 i218 = i225;
michael@0 10021 i219 = i11;
michael@0 10022 break;
michael@0 10023 }
michael@0 10024 }
michael@0 10025 } else {
michael@0 10026 i218 = 0;
michael@0 10027 i219 = (i61 | 0) == (i204 | 0) ? i205 : i204;
michael@0 10028 }
michael@0 10029 } while (0);
michael@0 10030 i198 = i21 + 1 | 0;
michael@0 10031 if ((i198 | 0) < 2) {
michael@0 10032 i14 = i219;
michael@0 10033 i61 = (i219 | 0) == (i204 | 0) ? i205 : i204;
michael@0 10034 i21 = i198;
michael@0 10035 i197 = i218;
michael@0 10036 } else {
michael@0 10037 i206 = i218;
michael@0 10038 i207 = i219;
michael@0 10039 break;
michael@0 10040 }
michael@0 10041 }
michael@0 10042 if ((i207 | 0) != (i204 | 0)) {
michael@0 10043 i219 = i23;
michael@0 10044 i218 = i207;
michael@0 10045 i207 = i206 << 3;
michael@0 10046 _memcpy(i219 | 0, i218 | 0, i207) | 0;
michael@0 10047 }
michael@0 10048 if ((i206 | 0) < 1) {
michael@0 10049 i94 = 0;
michael@0 10050 STACKTOP = i12;
michael@0 10051 return i94 | 0;
michael@0 10052 }
michael@0 10053 d222 = 1.0 / (d173 * d66 - d187 * d174);
michael@0 10054 d223 = d173 * d222;
michael@0 10055 d173 = d174 * d222;
michael@0 10056 d174 = d66 * d222;
michael@0 10057 d66 = -0.0 - d187 * d222;
michael@0 10058 d222 = +HEAPF32[i196 + (i199 << 2) >> 2];
michael@0 10059 d187 = +HEAPF32[i192 >> 2];
michael@0 10060 d210 = +HEAPF32[i200 >> 2];
michael@0 10061 d211 = +HEAPF32[i195 >> 2];
michael@0 10062 d63 = +HEAPF32[i15 >> 2];
michael@0 10063 d179 = +HEAPF32[i20 >> 2];
michael@0 10064 d64 = +HEAPF32[i36 >> 2];
michael@0 10065 i36 = 0;
michael@0 10066 i20 = 0;
michael@0 10067 while (1) {
michael@0 10068 i15 = i36 << 1;
michael@0 10069 d188 = +HEAPF32[i23 + (i15 << 2) >> 2];
michael@0 10070 d180 = d188 - d186;
michael@0 10071 d62 = +HEAPF32[i23 + ((i15 | 1) << 2) >> 2];
michael@0 10072 d65 = d62 - d181;
michael@0 10073 d171 = d174 * d180 - d173 * d65;
michael@0 10074 d184 = d180 * d66 + d223 * d65;
michael@0 10075 i15 = i20 * 3 | 0;
michael@0 10076 d65 = d210 * d184 + (d201 + d187 * d171);
michael@0 10077 HEAPF32[i24 + (i15 << 2) >> 2] = d65;
michael@0 10078 d180 = d63 * d184 + (d202 + d211 * d171);
michael@0 10079 HEAPF32[i24 + (i15 + 1 << 2) >> 2] = d180;
michael@0 10080 d185 = d64 * d184 + (d203 + d179 * d171);
michael@0 10081 HEAPF32[i24 + (i15 + 2 << 2) >> 2] = d185;
michael@0 10082 d171 = d222 - (d189 * d65 + d190 * d180 + d191 * d185);
michael@0 10083 HEAPF32[i25 + (i20 << 2) >> 2] = d171;
michael@0 10084 if (d171 < 0.0) {
michael@0 10085 i226 = i20;
michael@0 10086 } else {
michael@0 10087 i15 = i20 << 1;
michael@0 10088 HEAPF32[i23 + (i15 << 2) >> 2] = d188;
michael@0 10089 HEAPF32[i23 + ((i15 | 1) << 2) >> 2] = d62;
michael@0 10090 i226 = i20 + 1 | 0;
michael@0 10091 }
michael@0 10092 i15 = i36 + 1 | 0;
michael@0 10093 if ((i15 | 0) < (i206 | 0)) {
michael@0 10094 i36 = i15;
michael@0 10095 i20 = i226;
michael@0 10096 } else {
michael@0 10097 break;
michael@0 10098 }
michael@0 10099 }
michael@0 10100 if ((i226 | 0) < 1) {
michael@0 10101 i94 = 0;
michael@0 10102 STACKTOP = i12;
michael@0 10103 return i94 | 0;
michael@0 10104 }
michael@0 10105 i20 = (i226 | 0) < (i10 | 0) ? i226 : i10;
michael@0 10106 i10 = (i20 | 0) < 1 ? 1 : i20;
michael@0 10107 do {
michael@0 10108 if ((i226 | 0) > (i10 | 0)) {
michael@0 10109 if ((i226 | 0) > 1) {
michael@0 10110 i20 = 1;
michael@0 10111 i36 = 0;
michael@0 10112 d191 = +HEAPF32[i25 >> 2];
michael@0 10113 while (1) {
michael@0 10114 d190 = +HEAPF32[i25 + (i20 << 2) >> 2];
michael@0 10115 i206 = d190 > d191;
michael@0 10116 i23 = i206 ? i20 : i36;
michael@0 10117 i15 = i20 + 1 | 0;
michael@0 10118 if ((i15 | 0) < (i226 | 0)) {
michael@0 10119 i20 = i15;
michael@0 10120 i36 = i23;
michael@0 10121 d191 = i206 ? d190 : d191;
michael@0 10122 } else {
michael@0 10123 i227 = i23;
michael@0 10124 break;
michael@0 10125 }
michael@0 10126 }
michael@0 10127 } else {
michael@0 10128 i227 = 0;
michael@0 10129 }
michael@0 10130 __Z11cullPoints2iPfiiPi(i226, i204, i10, i227, i30 | 0);
michael@0 10131 if ((i10 | 0) <= 0) {
michael@0 10132 i228 = i10;
michael@0 10133 break;
michael@0 10134 }
michael@0 10135 i36 = i13;
michael@0 10136 i20 = i7 + 4 | 0;
michael@0 10137 i23 = i7 + 8 | 0;
michael@0 10138 i206 = i32 | 0;
michael@0 10139 i15 = i32 + 4 | 0;
michael@0 10140 i195 = i32 + 8 | 0;
michael@0 10141 i200 = i32 + 12 | 0;
michael@0 10142 i192 = i33 | 0;
michael@0 10143 i199 = i33 + 4 | 0;
michael@0 10144 i196 = i33 + 8 | 0;
michael@0 10145 i207 = i33 + 12 | 0;
michael@0 10146 i218 = i31 | 0;
michael@0 10147 i219 = i31 + 4 | 0;
michael@0 10148 i197 = i31 + 8 | 0;
michael@0 10149 i21 = i34 | 0;
michael@0 10150 i205 = i34 + 4 | 0;
michael@0 10151 i61 = i34 + 8 | 0;
michael@0 10152 i14 = i34 + 12 | 0;
michael@0 10153 i225 = i194 + 4 | 0;
michael@0 10154 i217 = i194 + 8 | 0;
michael@0 10155 if (i17) {
michael@0 10156 i224 = 0;
michael@0 10157 while (1) {
michael@0 10158 i216 = HEAP32[i30 + (i224 << 2) >> 2] | 0;
michael@0 10159 i215 = i216 * 3 | 0;
michael@0 10160 HEAPF32[i218 >> 2] = +HEAPF32[i24 + (i215 << 2) >> 2] + +HEAPF32[i194 >> 2];
michael@0 10161 HEAPF32[i219 >> 2] = +HEAPF32[i24 + (i215 + 1 << 2) >> 2] + +HEAPF32[i225 >> 2];
michael@0 10162 HEAPF32[i197 >> 2] = +HEAPF32[i24 + (i215 + 2 << 2) >> 2] + +HEAPF32[i217 >> 2];
michael@0 10163 d191 = -0.0 - +HEAPF32[i23 >> 2];
michael@0 10164 d190 = -0.0 - +HEAPF32[i20 >> 2];
michael@0 10165 i215 = HEAP32[(HEAP32[i36 >> 2] | 0) + 16 >> 2] | 0;
michael@0 10166 HEAPF32[i206 >> 2] = -0.0 - +HEAPF32[i19 >> 2];
michael@0 10167 HEAPF32[i15 >> 2] = d190;
michael@0 10168 HEAPF32[i195 >> 2] = d191;
michael@0 10169 HEAPF32[i200 >> 2] = 0.0;
michael@0 10170 FUNCTION_TABLE_viiif[i215 & 15](i13, i32, i31, -0.0 - +HEAPF32[i25 + (i216 << 2) >> 2]);
michael@0 10171 i216 = i224 + 1 | 0;
michael@0 10172 if ((i216 | 0) < (i10 | 0)) {
michael@0 10173 i224 = i216;
michael@0 10174 } else {
michael@0 10175 i228 = i10;
michael@0 10176 break;
michael@0 10177 }
michael@0 10178 }
michael@0 10179 } else {
michael@0 10180 i224 = 0;
michael@0 10181 while (1) {
michael@0 10182 i200 = HEAP32[i30 + (i224 << 2) >> 2] | 0;
michael@0 10183 i195 = i200 * 3 | 0;
michael@0 10184 d191 = +HEAPF32[i24 + (i195 << 2) >> 2] + +HEAPF32[i194 >> 2];
michael@0 10185 HEAPF32[i218 >> 2] = d191;
michael@0 10186 d190 = +HEAPF32[i24 + (i195 + 1 << 2) >> 2] + +HEAPF32[i225 >> 2];
michael@0 10187 HEAPF32[i219 >> 2] = d190;
michael@0 10188 d189 = +HEAPF32[i24 + (i195 + 2 << 2) >> 2] + +HEAPF32[i217 >> 2];
michael@0 10189 HEAPF32[i197 >> 2] = d189;
michael@0 10190 d222 = +HEAPF32[i19 >> 2];
michael@0 10191 d179 = +HEAPF32[i20 >> 2];
michael@0 10192 d203 = +HEAPF32[i23 >> 2];
michael@0 10193 i195 = HEAP32[(HEAP32[i36 >> 2] | 0) + 16 >> 2] | 0;
michael@0 10194 HEAPF32[i192 >> 2] = -0.0 - d222;
michael@0 10195 HEAPF32[i199 >> 2] = -0.0 - d179;
michael@0 10196 HEAPF32[i196 >> 2] = -0.0 - d203;
michael@0 10197 HEAPF32[i207 >> 2] = 0.0;
michael@0 10198 d64 = +HEAPF32[i25 + (i200 << 2) >> 2];
michael@0 10199 HEAPF32[i21 >> 2] = d191 - d222 * d64;
michael@0 10200 HEAPF32[i205 >> 2] = d190 - d179 * d64;
michael@0 10201 HEAPF32[i61 >> 2] = d189 - d203 * d64;
michael@0 10202 HEAPF32[i14 >> 2] = 0.0;
michael@0 10203 FUNCTION_TABLE_viiif[i195 & 15](i13, i33, i34, -0.0 - d64);
michael@0 10204 i195 = i224 + 1 | 0;
michael@0 10205 if ((i195 | 0) < (i10 | 0)) {
michael@0 10206 i224 = i195;
michael@0 10207 } else {
michael@0 10208 i228 = i10;
michael@0 10209 break;
michael@0 10210 }
michael@0 10211 }
michael@0 10212 }
michael@0 10213 } else {
michael@0 10214 i224 = (i226 | 0) > 0;
michael@0 10215 if (i17) {
michael@0 10216 if (!i224) {
michael@0 10217 i228 = i226;
michael@0 10218 break;
michael@0 10219 }
michael@0 10220 i14 = i13;
michael@0 10221 i61 = i7 + 4 | 0;
michael@0 10222 i205 = i7 + 8 | 0;
michael@0 10223 i21 = i27 | 0;
michael@0 10224 i207 = i27 + 4 | 0;
michael@0 10225 i196 = i27 + 8 | 0;
michael@0 10226 i199 = i27 + 12 | 0;
michael@0 10227 i192 = i26 | 0;
michael@0 10228 i36 = i194 + 4 | 0;
michael@0 10229 i23 = i26 + 4 | 0;
michael@0 10230 i20 = i194 + 8 | 0;
michael@0 10231 i197 = i26 + 8 | 0;
michael@0 10232 i217 = 0;
michael@0 10233 while (1) {
michael@0 10234 i219 = i217 * 3 | 0;
michael@0 10235 HEAPF32[i192 >> 2] = +HEAPF32[i24 + (i219 << 2) >> 2] + +HEAPF32[i194 >> 2];
michael@0 10236 HEAPF32[i23 >> 2] = +HEAPF32[i24 + (i219 + 1 << 2) >> 2] + +HEAPF32[i36 >> 2];
michael@0 10237 HEAPF32[i197 >> 2] = +HEAPF32[i24 + (i219 + 2 << 2) >> 2] + +HEAPF32[i20 >> 2];
michael@0 10238 i219 = HEAP32[(HEAP32[i14 >> 2] | 0) + 16 >> 2] | 0;
michael@0 10239 d64 = -0.0 - +HEAPF32[i61 >> 2];
michael@0 10240 d203 = -0.0 - +HEAPF32[i205 >> 2];
michael@0 10241 HEAPF32[i21 >> 2] = -0.0 - +HEAPF32[i19 >> 2];
michael@0 10242 HEAPF32[i207 >> 2] = d64;
michael@0 10243 HEAPF32[i196 >> 2] = d203;
michael@0 10244 HEAPF32[i199 >> 2] = 0.0;
michael@0 10245 FUNCTION_TABLE_viiif[i219 & 15](i13, i27, i26, -0.0 - +HEAPF32[i25 + (i217 << 2) >> 2]);
michael@0 10246 i219 = i217 + 1 | 0;
michael@0 10247 if ((i219 | 0) < (i226 | 0)) {
michael@0 10248 i217 = i219;
michael@0 10249 } else {
michael@0 10250 i228 = i226;
michael@0 10251 break;
michael@0 10252 }
michael@0 10253 }
michael@0 10254 } else {
michael@0 10255 if (!i224) {
michael@0 10256 i228 = i226;
michael@0 10257 break;
michael@0 10258 }
michael@0 10259 i217 = i13;
michael@0 10260 i199 = i7 + 4 | 0;
michael@0 10261 i196 = i7 + 8 | 0;
michael@0 10262 i207 = i29 | 0;
michael@0 10263 i21 = i29 + 4 | 0;
michael@0 10264 i205 = i29 + 8 | 0;
michael@0 10265 i61 = i29 + 12 | 0;
michael@0 10266 i14 = i28 | 0;
michael@0 10267 i20 = i194 + 4 | 0;
michael@0 10268 i197 = i28 + 4 | 0;
michael@0 10269 i36 = i194 + 8 | 0;
michael@0 10270 i23 = i28 + 8 | 0;
michael@0 10271 i192 = 0;
michael@0 10272 while (1) {
michael@0 10273 i219 = i192 * 3 | 0;
michael@0 10274 d203 = +HEAPF32[i25 + (i192 << 2) >> 2];
michael@0 10275 d64 = +HEAPF32[i19 >> 2];
michael@0 10276 HEAPF32[i14 >> 2] = +HEAPF32[i24 + (i219 << 2) >> 2] + +HEAPF32[i194 >> 2] - d203 * d64;
michael@0 10277 d189 = +HEAPF32[i199 >> 2];
michael@0 10278 HEAPF32[i197 >> 2] = +HEAPF32[i24 + (i219 + 1 << 2) >> 2] + +HEAPF32[i20 >> 2] - d203 * d189;
michael@0 10279 d179 = +HEAPF32[i196 >> 2];
michael@0 10280 HEAPF32[i23 >> 2] = +HEAPF32[i24 + (i219 + 2 << 2) >> 2] + +HEAPF32[i36 >> 2] - d203 * d179;
michael@0 10281 i219 = HEAP32[(HEAP32[i217 >> 2] | 0) + 16 >> 2] | 0;
michael@0 10282 HEAPF32[i207 >> 2] = -0.0 - d64;
michael@0 10283 HEAPF32[i21 >> 2] = -0.0 - d189;
michael@0 10284 HEAPF32[i205 >> 2] = -0.0 - d179;
michael@0 10285 HEAPF32[i61 >> 2] = 0.0;
michael@0 10286 FUNCTION_TABLE_viiif[i219 & 15](i13, i29, i28, -0.0 - d203);
michael@0 10287 i219 = i192 + 1 | 0;
michael@0 10288 if ((i219 | 0) < (i226 | 0)) {
michael@0 10289 i192 = i219;
michael@0 10290 } else {
michael@0 10291 i228 = i226;
michael@0 10292 break;
michael@0 10293 }
michael@0 10294 }
michael@0 10295 }
michael@0 10296 }
michael@0 10297 } while (0);
michael@0 10298 HEAP32[i9 >> 2] = i182;
michael@0 10299 i94 = i228;
michael@0 10300 STACKTOP = i12;
michael@0 10301 return i94 | 0;
michael@0 10302 }
michael@0 10303 function __ZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 10304 i1 = i1 | 0;
michael@0 10305 i2 = i2 | 0;
michael@0 10306 i3 = i3 | 0;
michael@0 10307 i4 = i4 | 0;
michael@0 10308 i5 = i5 | 0;
michael@0 10309 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, d61 = 0.0, d62 = 0.0, d63 = 0.0, d64 = 0.0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, d78 = 0.0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0, i88 = 0, i89 = 0, i90 = 0, i91 = 0, i92 = 0, i93 = 0, i94 = 0, i95 = 0, i96 = 0, i97 = 0, i98 = 0, i99 = 0, i100 = 0, i101 = 0, i102 = 0, i103 = 0, i104 = 0, i105 = 0, i106 = 0, i107 = 0, i108 = 0, i109 = 0, i110 = 0, i111 = 0, i112 = 0, d113 = 0.0, d114 = 0.0, d115 = 0.0, i116 = 0, i117 = 0, i118 = 0, i119 = 0, i120 = 0, i121 = 0, i122 = 0, i123 = 0, i124 = 0, i125 = 0, i126 = 0, i127 = 0, i128 = 0, i129 = 0, i130 = 0, i131 = 0, i132 = 0, i133 = 0, i134 = 0, i135 = 0, i136 = 0, i137 = 0, i138 = 0, i139 = 0, i140 = 0, i141 = 0, i142 = 0, i143 = 0, i144 = 0, i145 = 0, i146 = 0, i147 = 0, i148 = 0;
michael@0 10310 i6 = STACKTOP;
michael@0 10311 STACKTOP = STACKTOP + 744 | 0;
michael@0 10312 i7 = i6 | 0;
michael@0 10313 i8 = i6 + 16 | 0;
michael@0 10314 i9 = i6 + 32 | 0;
michael@0 10315 i10 = i6 + 168 | 0;
michael@0 10316 i11 = i6 + 248 | 0;
michael@0 10317 i12 = i6 + 256 | 0;
michael@0 10318 i13 = i6 + 272 | 0;
michael@0 10319 i14 = i6 + 288 | 0;
michael@0 10320 i15 = i6 + 312 | 0;
michael@0 10321 i16 = i6 + 328 | 0;
michael@0 10322 i17 = i6 + 344 | 0;
michael@0 10323 i18 = i6 + 360 | 0;
michael@0 10324 i19 = i6 + 376 | 0;
michael@0 10325 i20 = i1 + 20 | 0;
michael@0 10326 i21 = HEAP32[i20 >> 2] | 0;
michael@0 10327 if ((i21 | 0) == 0) {
michael@0 10328 i22 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 10329 i23 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i22 >> 2] | 0) + 12 >> 2] & 31](i22, i2, i3) | 0;
michael@0 10330 HEAP32[i20 >> 2] = i23;
michael@0 10331 HEAP8[i1 + 16 | 0] = 1;
michael@0 10332 i24 = i23;
michael@0 10333 } else {
michael@0 10334 i24 = i21;
michael@0 10335 }
michael@0 10336 i21 = i5 + 4 | 0;
michael@0 10337 HEAP32[i21 >> 2] = i24;
michael@0 10338 i24 = HEAP32[i2 + 192 >> 2] | 0;
michael@0 10339 i23 = i24;
michael@0 10340 i22 = HEAP32[i3 + 192 >> 2] | 0;
michael@0 10341 i25 = i22;
michael@0 10342 i26 = i24 + 4 | 0;
michael@0 10343 do {
michael@0 10344 if ((HEAP32[i26 >> 2] | 0) == 10) {
michael@0 10345 if ((HEAP32[i22 + 4 >> 2] | 0) != 10) {
michael@0 10346 break;
michael@0 10347 }
michael@0 10348 i27 = i24;
michael@0 10349 i28 = i22;
michael@0 10350 i29 = i24;
michael@0 10351 i30 = HEAP32[(HEAP32[i24 >> 2] | 0) + 28 >> 2] | 0;
michael@0 10352 FUNCTION_TABLE_ii[i30 & 127](i29) | 0;
michael@0 10353 i29 = i22;
michael@0 10354 i30 = HEAP32[(HEAP32[i22 >> 2] | 0) + 28 >> 2] | 0;
michael@0 10355 FUNCTION_TABLE_ii[i30 & 127](i29) | 0;
michael@0 10356 d31 = +__ZNK20btPersistentManifold27getContactBreakingThresholdEv(HEAP32[i20 >> 2] | 0);
michael@0 10357 i29 = HEAP32[i24 + 52 >> 2] | 0;
michael@0 10358 d32 = +HEAPF32[i27 + 28 + (i29 << 2) >> 2];
michael@0 10359 d33 = +HEAPF32[i27 + 28 + (((i29 + 2 | 0) % 3 | 0) << 2) >> 2];
michael@0 10360 i27 = HEAP32[i22 + 52 >> 2] | 0;
michael@0 10361 d34 = +HEAPF32[i28 + 28 + (i27 << 2) >> 2];
michael@0 10362 d35 = +HEAPF32[i28 + 28 + (((i27 + 2 | 0) % 3 | 0) << 2) >> 2];
michael@0 10363 d36 = +HEAPF32[i2 + 4 + (i29 << 2) >> 2];
michael@0 10364 d37 = +HEAPF32[i2 + 20 + (i29 << 2) >> 2];
michael@0 10365 d38 = +HEAPF32[i2 + 36 + (i29 << 2) >> 2];
michael@0 10366 d39 = +HEAPF32[i3 + 4 + (i27 << 2) >> 2];
michael@0 10367 d40 = +HEAPF32[i3 + 20 + (i27 << 2) >> 2];
michael@0 10368 d41 = +HEAPF32[i3 + 36 + (i27 << 2) >> 2];
michael@0 10369 d42 = +HEAPF32[i3 + 52 >> 2];
michael@0 10370 d43 = +HEAPF32[i3 + 56 >> 2];
michael@0 10371 d44 = +HEAPF32[i3 + 60 >> 2];
michael@0 10372 d45 = d42 - +HEAPF32[i2 + 52 >> 2];
michael@0 10373 d46 = d43 - +HEAPF32[i2 + 56 >> 2];
michael@0 10374 d47 = d44 - +HEAPF32[i2 + 60 >> 2];
michael@0 10375 d48 = d36 * d39 + d37 * d40 + d38 * d41;
michael@0 10376 d49 = d36 * d45 + d37 * d46 + d38 * d47;
michael@0 10377 d50 = d39 * d45 + d40 * d46 + d41 * d47;
michael@0 10378 d51 = 1.0 - d48 * d48;
michael@0 10379 do {
michael@0 10380 if (d51 == 0.0) {
michael@0 10381 d52 = 0.0;
michael@0 10382 } else {
michael@0 10383 d53 = (d49 - d48 * d50) / d51;
michael@0 10384 d54 = -0.0 - d32;
michael@0 10385 if (d53 < d54) {
michael@0 10386 d52 = d54;
michael@0 10387 break;
michael@0 10388 }
michael@0 10389 if (d53 <= d32) {
michael@0 10390 d52 = d53;
michael@0 10391 break;
michael@0 10392 }
michael@0 10393 d52 = d32;
michael@0 10394 }
michael@0 10395 } while (0);
michael@0 10396 d51 = d48 * d52 - d50;
michael@0 10397 d53 = -0.0 - d34;
michael@0 10398 do {
michael@0 10399 if (d51 < d53) {
michael@0 10400 d54 = d48 * d53 + d49;
michael@0 10401 d55 = -0.0 - d32;
michael@0 10402 if (d54 < d55) {
michael@0 10403 d56 = d55;
michael@0 10404 d57 = d53;
michael@0 10405 break;
michael@0 10406 }
michael@0 10407 if (d54 <= d32) {
michael@0 10408 d56 = d54;
michael@0 10409 d57 = d53;
michael@0 10410 break;
michael@0 10411 }
michael@0 10412 d56 = d32;
michael@0 10413 d57 = d53;
michael@0 10414 } else {
michael@0 10415 if (d51 <= d34) {
michael@0 10416 d56 = d52;
michael@0 10417 d57 = d51;
michael@0 10418 break;
michael@0 10419 }
michael@0 10420 d54 = d34 * d48 + d49;
michael@0 10421 d55 = -0.0 - d32;
michael@0 10422 if (d54 < d55) {
michael@0 10423 d56 = d55;
michael@0 10424 d57 = d34;
michael@0 10425 break;
michael@0 10426 }
michael@0 10427 if (d54 <= d32) {
michael@0 10428 d56 = d54;
michael@0 10429 d57 = d34;
michael@0 10430 break;
michael@0 10431 }
michael@0 10432 d56 = d32;
michael@0 10433 d57 = d34;
michael@0 10434 }
michael@0 10435 } while (0);
michael@0 10436 d34 = d39 * d57;
michael@0 10437 d32 = d40 * d57;
michael@0 10438 d49 = d41 * d57;
michael@0 10439 d48 = d34 + (d45 - d36 * d56);
michael@0 10440 d51 = d32 + (d46 - d37 * d56);
michael@0 10441 d53 = d49 + (d47 - d38 * d56);
michael@0 10442 d50 = d53 * d53 + (d48 * d48 + d51 * d51);
michael@0 10443 d54 = +Math_sqrt(+d50);
michael@0 10444 d55 = d54 - d33 - d35;
michael@0 10445 if (d55 <= d31) {
michael@0 10446 do {
michael@0 10447 if (d50 > 1.4210854715202004e-14) {
michael@0 10448 d58 = -0.0 - 1.0 / d54;
michael@0 10449 d59 = d48 * d58;
michael@0 10450 d60 = d51 * d58;
michael@0 10451 d61 = d53 * d58;
michael@0 10452 HEAPF32[i7 >> 2] = d59;
michael@0 10453 HEAPF32[i7 + 4 >> 2] = d60;
michael@0 10454 HEAPF32[i7 + 8 >> 2] = d61;
michael@0 10455 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 10456 d62 = d59;
michael@0 10457 d63 = d60;
michael@0 10458 d64 = d61;
michael@0 10459 } else {
michael@0 10460 if (+Math_abs(+d38) > .7071067690849304) {
michael@0 10461 d61 = 1.0 / +Math_sqrt(+(d37 * d37 + d38 * d38));
michael@0 10462 HEAPF32[i7 >> 2] = 0.0;
michael@0 10463 d60 = d61 * (-0.0 - d38);
michael@0 10464 HEAPF32[i7 + 4 >> 2] = d60;
michael@0 10465 d59 = d37 * d61;
michael@0 10466 HEAPF32[i7 + 8 >> 2] = d59;
michael@0 10467 d62 = 0.0;
michael@0 10468 d63 = d60;
michael@0 10469 d64 = d59;
michael@0 10470 break;
michael@0 10471 } else {
michael@0 10472 d59 = 1.0 / +Math_sqrt(+(d36 * d36 + d37 * d37));
michael@0 10473 d60 = d59 * (-0.0 - d37);
michael@0 10474 HEAPF32[i7 >> 2] = d60;
michael@0 10475 d61 = d36 * d59;
michael@0 10476 HEAPF32[i7 + 4 >> 2] = d61;
michael@0 10477 HEAPF32[i7 + 8 >> 2] = 0.0;
michael@0 10478 d62 = d60;
michael@0 10479 d63 = d61;
michael@0 10480 d64 = 0.0;
michael@0 10481 break;
michael@0 10482 }
michael@0 10483 }
michael@0 10484 } while (0);
michael@0 10485 HEAPF32[i8 >> 2] = d42 + d34 + d35 * d62;
michael@0 10486 HEAPF32[i8 + 4 >> 2] = d43 + d32 + d35 * d63;
michael@0 10487 HEAPF32[i8 + 8 >> 2] = d44 + d49 + d35 * d64;
michael@0 10488 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 10489 }
michael@0 10490 if (d55 < d31) {
michael@0 10491 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i5 >> 2] | 0) + 16 >> 2] & 15](i5, i7, i8, d55);
michael@0 10492 }
michael@0 10493 i27 = HEAP32[i21 >> 2] | 0;
michael@0 10494 if ((HEAP32[i27 + 1116 >> 2] | 0) == 0) {
michael@0 10495 STACKTOP = i6;
michael@0 10496 return;
michael@0 10497 }
michael@0 10498 if ((HEAP32[i27 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 10499 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i27, i5 + 8 | 0, i5 + 72 | 0);
michael@0 10500 STACKTOP = i6;
michael@0 10501 return;
michael@0 10502 } else {
michael@0 10503 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i27, i5 + 72 | 0, i5 + 8 | 0);
michael@0 10504 STACKTOP = i6;
michael@0 10505 return;
michael@0 10506 }
michael@0 10507 }
michael@0 10508 } while (0);
michael@0 10509 i8 = i9 + 128 | 0;
michael@0 10510 HEAPF32[i8 >> 2] = 999999984306749400.0;
michael@0 10511 i7 = i9 + 132 | 0;
michael@0 10512 HEAP32[i7 >> 2] = 0;
michael@0 10513 __ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i10, i23, i25, HEAP32[i1 + 8 >> 2] | 0, HEAP32[i1 + 12 >> 2] | 0);
michael@0 10514 HEAP32[i10 + 28 >> 2] = i23;
michael@0 10515 HEAP32[i10 + 32 >> 2] = i25;
michael@0 10516 d64 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i24 >> 2] | 0) + 44 >> 2] & 7](i23);
michael@0 10517 d63 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i22 >> 2] | 0) + 44 >> 2] & 7](i25);
michael@0 10518 d62 = d64 + d63 + +__ZNK20btPersistentManifold27getContactBreakingThresholdEv(HEAP32[i20 >> 2] | 0);
michael@0 10519 HEAPF32[i8 >> 2] = d62 * d62;
michael@0 10520 HEAP32[i7 >> 2] = HEAP32[i4 + 40 >> 2];
michael@0 10521 i7 = i2 + 4 | 0;
michael@0 10522 i8 = i9;
michael@0 10523 i25 = i7;
michael@0 10524 HEAP32[i8 >> 2] = HEAP32[i25 >> 2];
michael@0 10525 HEAP32[i8 + 4 >> 2] = HEAP32[i25 + 4 >> 2];
michael@0 10526 HEAP32[i8 + 8 >> 2] = HEAP32[i25 + 8 >> 2];
michael@0 10527 HEAP32[i8 + 12 >> 2] = HEAP32[i25 + 12 >> 2];
michael@0 10528 i23 = i9 + 16 | 0;
michael@0 10529 i27 = i2 + 20 | 0;
michael@0 10530 HEAP32[i23 >> 2] = HEAP32[i27 >> 2];
michael@0 10531 HEAP32[i23 + 4 >> 2] = HEAP32[i27 + 4 >> 2];
michael@0 10532 HEAP32[i23 + 8 >> 2] = HEAP32[i27 + 8 >> 2];
michael@0 10533 HEAP32[i23 + 12 >> 2] = HEAP32[i27 + 12 >> 2];
michael@0 10534 i29 = i9 + 32 | 0;
michael@0 10535 i28 = i2 + 36 | 0;
michael@0 10536 HEAP32[i29 >> 2] = HEAP32[i28 >> 2];
michael@0 10537 HEAP32[i29 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 10538 HEAP32[i29 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 10539 HEAP32[i29 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 10540 i30 = i9 + 48 | 0;
michael@0 10541 i65 = i2 + 52 | 0;
michael@0 10542 HEAP32[i30 >> 2] = HEAP32[i65 >> 2];
michael@0 10543 HEAP32[i30 + 4 >> 2] = HEAP32[i65 + 4 >> 2];
michael@0 10544 HEAP32[i30 + 8 >> 2] = HEAP32[i65 + 8 >> 2];
michael@0 10545 HEAP32[i30 + 12 >> 2] = HEAP32[i65 + 12 >> 2];
michael@0 10546 i66 = i3 + 4 | 0;
michael@0 10547 i67 = i9 + 64 | 0;
michael@0 10548 i68 = i66;
michael@0 10549 HEAP32[i67 >> 2] = HEAP32[i68 >> 2];
michael@0 10550 HEAP32[i67 + 4 >> 2] = HEAP32[i68 + 4 >> 2];
michael@0 10551 HEAP32[i67 + 8 >> 2] = HEAP32[i68 + 8 >> 2];
michael@0 10552 HEAP32[i67 + 12 >> 2] = HEAP32[i68 + 12 >> 2];
michael@0 10553 i69 = i9 + 80 | 0;
michael@0 10554 i70 = i3 + 20 | 0;
michael@0 10555 HEAP32[i69 >> 2] = HEAP32[i70 >> 2];
michael@0 10556 HEAP32[i69 + 4 >> 2] = HEAP32[i70 + 4 >> 2];
michael@0 10557 HEAP32[i69 + 8 >> 2] = HEAP32[i70 + 8 >> 2];
michael@0 10558 HEAP32[i69 + 12 >> 2] = HEAP32[i70 + 12 >> 2];
michael@0 10559 i71 = i9 + 96 | 0;
michael@0 10560 i72 = i3 + 36 | 0;
michael@0 10561 HEAP32[i71 >> 2] = HEAP32[i72 >> 2];
michael@0 10562 HEAP32[i71 + 4 >> 2] = HEAP32[i72 + 4 >> 2];
michael@0 10563 HEAP32[i71 + 8 >> 2] = HEAP32[i72 + 8 >> 2];
michael@0 10564 HEAP32[i71 + 12 >> 2] = HEAP32[i72 + 12 >> 2];
michael@0 10565 i73 = i9 + 112 | 0;
michael@0 10566 i74 = i3 + 52 | 0;
michael@0 10567 HEAP32[i73 >> 2] = HEAP32[i74 >> 2];
michael@0 10568 HEAP32[i73 + 4 >> 2] = HEAP32[i74 + 4 >> 2];
michael@0 10569 HEAP32[i73 + 8 >> 2] = HEAP32[i74 + 8 >> 2];
michael@0 10570 HEAP32[i73 + 12 >> 2] = HEAP32[i74 + 12 >> 2];
michael@0 10571 do {
michael@0 10572 if ((HEAP32[i26 >> 2] | 0) < 7) {
michael@0 10573 i75 = HEAP32[i22 + 4 >> 2] | 0;
michael@0 10574 if ((i75 | 0) >= 7) {
michael@0 10575 break;
michael@0 10576 }
michael@0 10577 HEAP32[i11 >> 2] = 1552;
michael@0 10578 i76 = i24 + 52 | 0;
michael@0 10579 if ((HEAP32[i76 >> 2] | 0) == 0) {
michael@0 10580 break;
michael@0 10581 }
michael@0 10582 i77 = i22 + 52 | 0;
michael@0 10583 if ((HEAP32[i77 >> 2] | 0) != 0) {
michael@0 10584 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i10, i9, i11 | 0, HEAP32[i4 + 20 >> 2] | 0, 0);
michael@0 10585 d62 = +__ZNK20btPersistentManifold27getContactBreakingThresholdEv(HEAP32[i20 >> 2] | 0);
michael@0 10586 if ((HEAP8[i4 + 24 | 0] | 0) == 0) {
michael@0 10587 d63 = +HEAPF32[i10 + 4 >> 2];
michael@0 10588 d64 = +HEAPF32[i10 + 8 >> 2];
michael@0 10589 d56 = +HEAPF32[i10 + 12 >> 2];
michael@0 10590 d57 = 1.0 / +Math_sqrt(+(d63 * d63 + d64 * d64 + d56 * d56));
michael@0 10591 HEAPF32[i12 >> 2] = d63 * d57;
michael@0 10592 HEAPF32[i12 + 4 >> 2] = d64 * d57;
michael@0 10593 HEAPF32[i12 + 8 >> 2] = d56 * d57;
michael@0 10594 HEAPF32[i12 + 12 >> 2] = 0.0;
michael@0 10595 d78 = +HEAPF32[i10 + 56 >> 2];
michael@0 10596 i79 = 1404;
michael@0 10597 } else {
michael@0 10598 if (__ZN27btPolyhedralContactClipping18findSeparatingAxisERK18btConvexPolyhedronS2_RK11btTransformS5_R9btVector3(HEAP32[i76 >> 2] | 0, HEAP32[i77 >> 2] | 0, i7, i66, i12) | 0) {
michael@0 10599 d78 = 0.0;
michael@0 10600 i79 = 1404;
michael@0 10601 }
michael@0 10602 }
michael@0 10603 if ((i79 | 0) == 1404) {
michael@0 10604 __ZN27btPolyhedralContactClipping19clipHullAgainstHullERK9btVector3RK18btConvexPolyhedronS5_RK11btTransformS8_ffRN36btDiscreteCollisionDetectorInterface6ResultE(i12, HEAP32[i76 >> 2] | 0, HEAP32[i77 >> 2] | 0, i7, i66, d78 - d62, d62, i5 | 0);
michael@0 10605 }
michael@0 10606 if ((HEAP8[i1 + 16 | 0] | 0) == 0) {
michael@0 10607 STACKTOP = i6;
michael@0 10608 return;
michael@0 10609 }
michael@0 10610 i77 = HEAP32[i21 >> 2] | 0;
michael@0 10611 if ((HEAP32[i77 + 1116 >> 2] | 0) == 0) {
michael@0 10612 STACKTOP = i6;
michael@0 10613 return;
michael@0 10614 }
michael@0 10615 if ((HEAP32[i77 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 10616 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i77, i5 + 8 | 0, i5 + 72 | 0);
michael@0 10617 STACKTOP = i6;
michael@0 10618 return;
michael@0 10619 } else {
michael@0 10620 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i77, i5 + 72 | 0, i5 + 8 | 0);
michael@0 10621 STACKTOP = i6;
michael@0 10622 return;
michael@0 10623 }
michael@0 10624 }
michael@0 10625 if ((i75 | 0) != 1) {
michael@0 10626 break;
michael@0 10627 }
michael@0 10628 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i10, i9, i11 | 0, HEAP32[i4 + 20 >> 2] | 0, 0);
michael@0 10629 d62 = +HEAPF32[i10 + 4 >> 2];
michael@0 10630 d57 = +HEAPF32[i10 + 8 >> 2];
michael@0 10631 d56 = +HEAPF32[i10 + 12 >> 2];
michael@0 10632 d64 = 1.0 / +Math_sqrt(+(d62 * d62 + d57 * d57 + d56 * d56));
michael@0 10633 HEAPF32[i13 >> 2] = d62 * d64;
michael@0 10634 HEAPF32[i13 + 4 >> 2] = d57 * d64;
michael@0 10635 HEAPF32[i13 + 8 >> 2] = d56 * d64;
michael@0 10636 HEAPF32[i13 + 12 >> 2] = 0.0;
michael@0 10637 i75 = i14 + 16 | 0;
michael@0 10638 HEAP8[i75] = 1;
michael@0 10639 i77 = i14 + 12 | 0;
michael@0 10640 HEAP32[i77 >> 2] = 0;
michael@0 10641 i80 = i14 + 4 | 0;
michael@0 10642 HEAP32[i80 >> 2] = 0;
michael@0 10643 i81 = i14 + 8 | 0;
michael@0 10644 HEAP32[i81 >> 2] = 0;
michael@0 10645 i82 = i22 + 56 | 0;
michael@0 10646 i83 = i66 | 0;
michael@0 10647 d64 = +HEAPF32[i82 >> 2];
michael@0 10648 i84 = i3 + 8 | 0;
michael@0 10649 d56 = +HEAPF32[i82 + 4 >> 2];
michael@0 10650 i85 = i3 + 12 | 0;
michael@0 10651 d57 = +HEAPF32[i82 + 8 >> 2];
michael@0 10652 i86 = i3 + 52 | 0;
michael@0 10653 d62 = +HEAPF32[i86 >> 2] + (+HEAPF32[i83 >> 2] * d64 + +HEAPF32[i84 >> 2] * d56 + +HEAPF32[i85 >> 2] * d57);
michael@0 10654 i87 = i3 + 20 | 0;
michael@0 10655 i88 = i3 + 24 | 0;
michael@0 10656 i89 = i3 + 28 | 0;
michael@0 10657 i90 = i3 + 56 | 0;
michael@0 10658 d63 = +HEAPF32[i90 >> 2] + (d64 * +HEAPF32[i87 >> 2] + d56 * +HEAPF32[i88 >> 2] + d57 * +HEAPF32[i89 >> 2]);
michael@0 10659 i91 = i3 + 36 | 0;
michael@0 10660 i92 = i3 + 40 | 0;
michael@0 10661 i93 = i3 + 44 | 0;
michael@0 10662 i94 = i3 + 60 | 0;
michael@0 10663 d52 = +HEAPF32[i94 >> 2] + (d64 * +HEAPF32[i91 >> 2] + d56 * +HEAPF32[i92 >> 2] + d57 * +HEAPF32[i93 >> 2]);
michael@0 10664 i95 = __Z22btAlignedAllocInternalji(16, 16) | 0;
michael@0 10665 HEAP8[i75] = 1;
michael@0 10666 HEAP32[i77 >> 2] = i95;
michael@0 10667 HEAP32[i81 >> 2] = 1;
michael@0 10668 i96 = HEAP32[i80 >> 2] | 0;
michael@0 10669 i97 = i95 + (i96 << 4) | 0;
michael@0 10670 if ((i97 | 0) == 0) {
michael@0 10671 i98 = i96;
michael@0 10672 i99 = 1;
michael@0 10673 } else {
michael@0 10674 HEAPF32[i97 >> 2] = d62;
michael@0 10675 HEAPF32[i95 + (i96 << 4) + 4 >> 2] = d63;
michael@0 10676 HEAPF32[i95 + (i96 << 4) + 8 >> 2] = d52;
michael@0 10677 HEAPF32[i95 + (i96 << 4) + 12 >> 2] = 0.0;
michael@0 10678 i98 = HEAP32[i80 >> 2] | 0;
michael@0 10679 i99 = HEAP32[i81 >> 2] | 0;
michael@0 10680 }
michael@0 10681 i96 = i98 + 1 | 0;
michael@0 10682 HEAP32[i80 >> 2] = i96;
michael@0 10683 d52 = +HEAPF32[i82 + 16 >> 2];
michael@0 10684 d63 = +HEAPF32[i82 + 20 >> 2];
michael@0 10685 d62 = +HEAPF32[i82 + 24 >> 2];
michael@0 10686 d57 = +HEAPF32[i86 >> 2] + (+HEAPF32[i83 >> 2] * d52 + +HEAPF32[i84 >> 2] * d63 + +HEAPF32[i85 >> 2] * d62);
michael@0 10687 d56 = +HEAPF32[i90 >> 2] + (d52 * +HEAPF32[i87 >> 2] + d63 * +HEAPF32[i88 >> 2] + d62 * +HEAPF32[i89 >> 2]);
michael@0 10688 d64 = +HEAPF32[i94 >> 2] + (d52 * +HEAPF32[i91 >> 2] + d63 * +HEAPF32[i92 >> 2] + d62 * +HEAPF32[i93 >> 2]);
michael@0 10689 do {
michael@0 10690 if ((i96 | 0) == (i99 | 0)) {
michael@0 10691 i95 = (i99 | 0) == 0 ? 1 : i99 << 1;
michael@0 10692 if ((i99 | 0) >= (i95 | 0)) {
michael@0 10693 i100 = i99;
michael@0 10694 i101 = i99;
michael@0 10695 break;
michael@0 10696 }
michael@0 10697 if ((i95 | 0) == 0) {
michael@0 10698 i102 = 0;
michael@0 10699 i103 = i99;
michael@0 10700 } else {
michael@0 10701 i97 = __Z22btAlignedAllocInternalji(i95 << 4, 16) | 0;
michael@0 10702 i102 = i97;
michael@0 10703 i103 = HEAP32[i80 >> 2] | 0;
michael@0 10704 }
michael@0 10705 if ((i103 | 0) > 0) {
michael@0 10706 i97 = 0;
michael@0 10707 do {
michael@0 10708 i104 = i102 + (i97 << 4) | 0;
michael@0 10709 if ((i104 | 0) != 0) {
michael@0 10710 i105 = i104;
michael@0 10711 i104 = (HEAP32[i77 >> 2] | 0) + (i97 << 4) | 0;
michael@0 10712 HEAP32[i105 >> 2] = HEAP32[i104 >> 2];
michael@0 10713 HEAP32[i105 + 4 >> 2] = HEAP32[i104 + 4 >> 2];
michael@0 10714 HEAP32[i105 + 8 >> 2] = HEAP32[i104 + 8 >> 2];
michael@0 10715 HEAP32[i105 + 12 >> 2] = HEAP32[i104 + 12 >> 2];
michael@0 10716 }
michael@0 10717 i97 = i97 + 1 | 0;
michael@0 10718 } while ((i97 | 0) < (i103 | 0));
michael@0 10719 }
michael@0 10720 i97 = HEAP32[i77 >> 2] | 0;
michael@0 10721 if ((i97 | 0) != 0) {
michael@0 10722 if ((HEAP8[i75] | 0) != 0) {
michael@0 10723 __Z21btAlignedFreeInternalPv(i97);
michael@0 10724 }
michael@0 10725 HEAP32[i77 >> 2] = 0;
michael@0 10726 }
michael@0 10727 HEAP8[i75] = 1;
michael@0 10728 HEAP32[i77 >> 2] = i102;
michael@0 10729 HEAP32[i81 >> 2] = i95;
michael@0 10730 i100 = HEAP32[i80 >> 2] | 0;
michael@0 10731 i101 = i95;
michael@0 10732 } else {
michael@0 10733 i100 = i96;
michael@0 10734 i101 = i99;
michael@0 10735 }
michael@0 10736 } while (0);
michael@0 10737 i96 = HEAP32[i77 >> 2] | 0;
michael@0 10738 i97 = i96 + (i100 << 4) | 0;
michael@0 10739 if ((i97 | 0) == 0) {
michael@0 10740 i106 = i100;
michael@0 10741 i107 = i101;
michael@0 10742 } else {
michael@0 10743 HEAPF32[i97 >> 2] = d57;
michael@0 10744 HEAPF32[i96 + (i100 << 4) + 4 >> 2] = d56;
michael@0 10745 HEAPF32[i96 + (i100 << 4) + 8 >> 2] = d64;
michael@0 10746 HEAPF32[i96 + (i100 << 4) + 12 >> 2] = 0.0;
michael@0 10747 i106 = HEAP32[i80 >> 2] | 0;
michael@0 10748 i107 = HEAP32[i81 >> 2] | 0;
michael@0 10749 }
michael@0 10750 i96 = i106 + 1 | 0;
michael@0 10751 HEAP32[i80 >> 2] = i96;
michael@0 10752 d55 = +HEAPF32[i82 + 32 >> 2];
michael@0 10753 d31 = +HEAPF32[i82 + 36 >> 2];
michael@0 10754 d35 = +HEAPF32[i82 + 40 >> 2];
michael@0 10755 d49 = +HEAPF32[i86 >> 2] + (+HEAPF32[i83 >> 2] * d55 + +HEAPF32[i84 >> 2] * d31 + +HEAPF32[i85 >> 2] * d35);
michael@0 10756 d44 = +HEAPF32[i90 >> 2] + (d55 * +HEAPF32[i87 >> 2] + d31 * +HEAPF32[i88 >> 2] + d35 * +HEAPF32[i89 >> 2]);
michael@0 10757 d32 = +HEAPF32[i94 >> 2] + (d55 * +HEAPF32[i91 >> 2] + d31 * +HEAPF32[i92 >> 2] + d35 * +HEAPF32[i93 >> 2]);
michael@0 10758 do {
michael@0 10759 if ((i96 | 0) == (i107 | 0)) {
michael@0 10760 i97 = (i107 | 0) == 0 ? 1 : i107 << 1;
michael@0 10761 if ((i107 | 0) >= (i97 | 0)) {
michael@0 10762 i108 = i107;
michael@0 10763 break;
michael@0 10764 }
michael@0 10765 if ((i97 | 0) == 0) {
michael@0 10766 i109 = 0;
michael@0 10767 i110 = i107;
michael@0 10768 } else {
michael@0 10769 i104 = __Z22btAlignedAllocInternalji(i97 << 4, 16) | 0;
michael@0 10770 i109 = i104;
michael@0 10771 i110 = HEAP32[i80 >> 2] | 0;
michael@0 10772 }
michael@0 10773 if ((i110 | 0) > 0) {
michael@0 10774 i104 = 0;
michael@0 10775 do {
michael@0 10776 i105 = i109 + (i104 << 4) | 0;
michael@0 10777 if ((i105 | 0) != 0) {
michael@0 10778 i111 = i105;
michael@0 10779 i105 = (HEAP32[i77 >> 2] | 0) + (i104 << 4) | 0;
michael@0 10780 HEAP32[i111 >> 2] = HEAP32[i105 >> 2];
michael@0 10781 HEAP32[i111 + 4 >> 2] = HEAP32[i105 + 4 >> 2];
michael@0 10782 HEAP32[i111 + 8 >> 2] = HEAP32[i105 + 8 >> 2];
michael@0 10783 HEAP32[i111 + 12 >> 2] = HEAP32[i105 + 12 >> 2];
michael@0 10784 }
michael@0 10785 i104 = i104 + 1 | 0;
michael@0 10786 } while ((i104 | 0) < (i110 | 0));
michael@0 10787 }
michael@0 10788 i104 = HEAP32[i77 >> 2] | 0;
michael@0 10789 if ((i104 | 0) != 0) {
michael@0 10790 if ((HEAP8[i75] | 0) != 0) {
michael@0 10791 __Z21btAlignedFreeInternalPv(i104);
michael@0 10792 }
michael@0 10793 HEAP32[i77 >> 2] = 0;
michael@0 10794 }
michael@0 10795 HEAP8[i75] = 1;
michael@0 10796 HEAP32[i77 >> 2] = i109;
michael@0 10797 HEAP32[i81 >> 2] = i97;
michael@0 10798 i108 = HEAP32[i80 >> 2] | 0;
michael@0 10799 } else {
michael@0 10800 i108 = i96;
michael@0 10801 }
michael@0 10802 } while (0);
michael@0 10803 i96 = HEAP32[i77 >> 2] | 0;
michael@0 10804 i93 = i96 + (i108 << 4) | 0;
michael@0 10805 if ((i93 | 0) == 0) {
michael@0 10806 i112 = i108;
michael@0 10807 } else {
michael@0 10808 HEAPF32[i93 >> 2] = d49;
michael@0 10809 HEAPF32[i96 + (i108 << 4) + 4 >> 2] = d44;
michael@0 10810 HEAPF32[i96 + (i108 << 4) + 8 >> 2] = d32;
michael@0 10811 HEAPF32[i96 + (i108 << 4) + 12 >> 2] = 0.0;
michael@0 10812 i112 = HEAP32[i80 >> 2] | 0;
michael@0 10813 }
michael@0 10814 HEAP32[i80 >> 2] = i112 + 1;
michael@0 10815 d64 = +__ZNK20btPersistentManifold27getContactBreakingThresholdEv(HEAP32[i20 >> 2] | 0);
michael@0 10816 __ZN27btPolyhedralContactClipping19clipFaceAgainstHullERK9btVector3RK18btConvexPolyhedronRK11btTransformR20btAlignedObjectArrayIS0_EffRN36btDiscreteCollisionDetectorInterface6ResultE(i13, HEAP32[i76 >> 2] | 0, i7, i14, +HEAPF32[i10 + 56 >> 2] - d64, d64, i5 | 0);
michael@0 10817 do {
michael@0 10818 if ((HEAP8[i1 + 16 | 0] | 0) != 0) {
michael@0 10819 i96 = HEAP32[i21 >> 2] | 0;
michael@0 10820 if ((HEAP32[i96 + 1116 >> 2] | 0) == 0) {
michael@0 10821 break;
michael@0 10822 }
michael@0 10823 if ((HEAP32[i96 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 10824 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i96, i5 + 8 | 0, i5 + 72 | 0);
michael@0 10825 break;
michael@0 10826 } else {
michael@0 10827 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i96, i5 + 72 | 0, i5 + 8 | 0);
michael@0 10828 break;
michael@0 10829 }
michael@0 10830 }
michael@0 10831 } while (0);
michael@0 10832 i76 = HEAP32[i77 >> 2] | 0;
michael@0 10833 if ((i76 | 0) != 0) {
michael@0 10834 if ((HEAP8[i75] | 0) != 0) {
michael@0 10835 __Z21btAlignedFreeInternalPv(i76);
michael@0 10836 }
michael@0 10837 HEAP32[i77 >> 2] = 0;
michael@0 10838 }
michael@0 10839 HEAP8[i75] = 1;
michael@0 10840 HEAP32[i77 >> 2] = 0;
michael@0 10841 HEAP32[i80 >> 2] = 0;
michael@0 10842 HEAP32[i81 >> 2] = 0;
michael@0 10843 STACKTOP = i6;
michael@0 10844 return;
michael@0 10845 }
michael@0 10846 } while (0);
michael@0 10847 i14 = i4 + 20 | 0;
michael@0 10848 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i10, i9, i5 | 0, HEAP32[i14 >> 2] | 0, 0);
michael@0 10849 i4 = i1 + 28 | 0;
michael@0 10850 L1724 : do {
michael@0 10851 if ((HEAP32[i4 >> 2] | 0) != 0) {
michael@0 10852 if ((HEAP32[(HEAP32[i21 >> 2] | 0) + 1116 >> 2] | 0) >= (HEAP32[i1 + 32 >> 2] | 0)) {
michael@0 10853 break;
michael@0 10854 }
michael@0 10855 d78 = +HEAPF32[i10 + 4 >> 2];
michael@0 10856 d32 = +HEAPF32[i10 + 8 >> 2];
michael@0 10857 d44 = +HEAPF32[i10 + 12 >> 2];
michael@0 10858 d49 = 1.0 / +Math_sqrt(+(d78 * d78 + d32 * d32 + d44 * d44));
michael@0 10859 d64 = d78 * d49;
michael@0 10860 d78 = d32 * d49;
michael@0 10861 d32 = d44 * d49;
michael@0 10862 if (+Math_abs(+d32) > .7071067690849304) {
michael@0 10863 d49 = 1.0 / +Math_sqrt(+(d32 * d32 + d78 * d78));
michael@0 10864 d113 = 0.0;
michael@0 10865 d114 = d49 * (-0.0 - d32);
michael@0 10866 d115 = d78 * d49;
michael@0 10867 } else {
michael@0 10868 d49 = 1.0 / +Math_sqrt(+(d64 * d64 + d78 * d78));
michael@0 10869 d113 = d49 * (-0.0 - d78);
michael@0 10870 d114 = d64 * d49;
michael@0 10871 d115 = 0.0;
michael@0 10872 }
michael@0 10873 d49 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i24 >> 2] | 0) + 16 >> 2] & 7](i24);
michael@0 10874 d44 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i22 >> 2] | 0) + 16 >> 2] & 7](i22);
michael@0 10875 i13 = d49 < d44;
michael@0 10876 d56 = +HEAPF32[4] / (i13 ? d49 : d44);
michael@0 10877 i20 = i15;
michael@0 10878 if (i13) {
michael@0 10879 HEAP32[i20 >> 2] = HEAP32[i8 >> 2];
michael@0 10880 HEAP32[i20 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 10881 HEAP32[i20 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 10882 HEAP32[i20 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 10883 i112 = i16;
michael@0 10884 HEAP32[i112 >> 2] = HEAP32[i23 >> 2];
michael@0 10885 HEAP32[i112 + 4 >> 2] = HEAP32[i23 + 4 >> 2];
michael@0 10886 HEAP32[i112 + 8 >> 2] = HEAP32[i23 + 8 >> 2];
michael@0 10887 HEAP32[i112 + 12 >> 2] = HEAP32[i23 + 12 >> 2];
michael@0 10888 i112 = i17;
michael@0 10889 HEAP32[i112 >> 2] = HEAP32[i29 >> 2];
michael@0 10890 HEAP32[i112 + 4 >> 2] = HEAP32[i29 + 4 >> 2];
michael@0 10891 HEAP32[i112 + 8 >> 2] = HEAP32[i29 + 8 >> 2];
michael@0 10892 HEAP32[i112 + 12 >> 2] = HEAP32[i29 + 12 >> 2];
michael@0 10893 i112 = i18;
michael@0 10894 HEAP32[i112 >> 2] = HEAP32[i30 >> 2];
michael@0 10895 HEAP32[i112 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 10896 HEAP32[i112 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 10897 HEAP32[i112 + 12 >> 2] = HEAP32[i30 + 12 >> 2];
michael@0 10898 } else {
michael@0 10899 HEAP32[i20 >> 2] = HEAP32[i67 >> 2];
michael@0 10900 HEAP32[i20 + 4 >> 2] = HEAP32[i67 + 4 >> 2];
michael@0 10901 HEAP32[i20 + 8 >> 2] = HEAP32[i67 + 8 >> 2];
michael@0 10902 HEAP32[i20 + 12 >> 2] = HEAP32[i67 + 12 >> 2];
michael@0 10903 i112 = i16;
michael@0 10904 HEAP32[i112 >> 2] = HEAP32[i69 >> 2];
michael@0 10905 HEAP32[i112 + 4 >> 2] = HEAP32[i69 + 4 >> 2];
michael@0 10906 HEAP32[i112 + 8 >> 2] = HEAP32[i69 + 8 >> 2];
michael@0 10907 HEAP32[i112 + 12 >> 2] = HEAP32[i69 + 12 >> 2];
michael@0 10908 i112 = i17;
michael@0 10909 HEAP32[i112 >> 2] = HEAP32[i71 >> 2];
michael@0 10910 HEAP32[i112 + 4 >> 2] = HEAP32[i71 + 4 >> 2];
michael@0 10911 HEAP32[i112 + 8 >> 2] = HEAP32[i71 + 8 >> 2];
michael@0 10912 HEAP32[i112 + 12 >> 2] = HEAP32[i71 + 12 >> 2];
michael@0 10913 i112 = i18;
michael@0 10914 HEAP32[i112 >> 2] = HEAP32[i73 >> 2];
michael@0 10915 HEAP32[i112 + 4 >> 2] = HEAP32[i73 + 4 >> 2];
michael@0 10916 HEAP32[i112 + 8 >> 2] = HEAP32[i73 + 8 >> 2];
michael@0 10917 HEAP32[i112 + 12 >> 2] = HEAP32[i73 + 12 >> 2];
michael@0 10918 }
michael@0 10919 i112 = HEAP32[i4 >> 2] | 0;
michael@0 10920 if ((i112 | 0) <= 0) {
michael@0 10921 break;
michael@0 10922 }
michael@0 10923 d44 = d115 * d115 + (d114 * d114 + d113 * d113);
michael@0 10924 d49 = d56 > .39269909262657166 ? .19634954631328583 : d56 * .5;
michael@0 10925 d56 = d32 * d32 + (d64 * d64 + d78 * d78);
michael@0 10926 i108 = i7 | 0;
michael@0 10927 i109 = i2 + 20 | 0;
michael@0 10928 i110 = i2 + 36 | 0;
michael@0 10929 i107 = i2 + 8 | 0;
michael@0 10930 i106 = i2 + 24 | 0;
michael@0 10931 i100 = i2 + 40 | 0;
michael@0 10932 i101 = i2 + 12 | 0;
michael@0 10933 i99 = i2 + 28 | 0;
michael@0 10934 i102 = i2 + 44 | 0;
michael@0 10935 i103 = i9 | 0;
michael@0 10936 i98 = i9 + 4 | 0;
michael@0 10937 i11 = i9 + 8 | 0;
michael@0 10938 i12 = i9 + 12 | 0;
michael@0 10939 i79 = i9 + 16 | 0;
michael@0 10940 i26 = i9 + 20 | 0;
michael@0 10941 i76 = i9 + 24 | 0;
michael@0 10942 i96 = i9 + 28 | 0;
michael@0 10943 i93 = i9 + 32 | 0;
michael@0 10944 i92 = i9 + 36 | 0;
michael@0 10945 i91 = i9 + 40 | 0;
michael@0 10946 i94 = i9 + 44 | 0;
michael@0 10947 i89 = i19 | 0;
michael@0 10948 i88 = i19 + 144 | 0;
michael@0 10949 i87 = i19 + 160 | 0;
michael@0 10950 i90 = i19 + 164 | 0;
michael@0 10951 i85 = i19 + 180 | 0;
michael@0 10952 i84 = i19 + 196 | 0;
michael@0 10953 i83 = i19 + 212 | 0;
michael@0 10954 i86 = i19 + 228 | 0;
michael@0 10955 i82 = i19 + 244 | 0;
michael@0 10956 i104 = i19 + 260 | 0;
michael@0 10957 i95 = i19 + 276 | 0;
michael@0 10958 i105 = i19 + 292 | 0;
michael@0 10959 i111 = i19 + 308 | 0;
michael@0 10960 i116 = i16;
michael@0 10961 i117 = i19 + 324 | 0;
michael@0 10962 i118 = i17;
michael@0 10963 i119 = i19 + 340 | 0;
michael@0 10964 i120 = i18;
michael@0 10965 i121 = i19 + 356 | 0;
michael@0 10966 i122 = i13 & 1;
michael@0 10967 i123 = i19 + 360 | 0;
michael@0 10968 i124 = i19 | 0;
michael@0 10969 i125 = i66 | 0;
michael@0 10970 i126 = i3 + 20 | 0;
michael@0 10971 i127 = i3 + 36 | 0;
michael@0 10972 i128 = i3 + 8 | 0;
michael@0 10973 i129 = i3 + 24 | 0;
michael@0 10974 i130 = i3 + 40 | 0;
michael@0 10975 i131 = i3 + 12 | 0;
michael@0 10976 i132 = i3 + 28 | 0;
michael@0 10977 i133 = i3 + 44 | 0;
michael@0 10978 i134 = i9 + 64 | 0;
michael@0 10979 i135 = i9 + 68 | 0;
michael@0 10980 i136 = i9 + 72 | 0;
michael@0 10981 i137 = i9 + 76 | 0;
michael@0 10982 i138 = i9 + 80 | 0;
michael@0 10983 i139 = i9 + 84 | 0;
michael@0 10984 i140 = i9 + 88 | 0;
michael@0 10985 i141 = i9 + 92 | 0;
michael@0 10986 i142 = i9 + 96 | 0;
michael@0 10987 i143 = i9 + 100 | 0;
michael@0 10988 i144 = i9 + 104 | 0;
michael@0 10989 i145 = i9 + 108 | 0;
michael@0 10990 if (d44 > 1.1920928955078125e-7) {
michael@0 10991 i146 = 0;
michael@0 10992 i147 = i112;
michael@0 10993 } else {
michael@0 10994 if (i13) {
michael@0 10995 i148 = 0;
michael@0 10996 while (1) {
michael@0 10997 i148 = i148 + 1 | 0;
michael@0 10998 if ((i148 | 0) >= (i112 | 0)) {
michael@0 10999 break L1724;
michael@0 11000 }
michael@0 11001 }
michael@0 11002 } else {
michael@0 11003 i148 = 0;
michael@0 11004 while (1) {
michael@0 11005 i148 = i148 + 1 | 0;
michael@0 11006 if ((i148 | 0) >= (i112 | 0)) {
michael@0 11007 break L1724;
michael@0 11008 }
michael@0 11009 }
michael@0 11010 }
michael@0 11011 }
michael@0 11012 do {
michael@0 11013 d57 = +Math_sqrt(+d44);
michael@0 11014 d35 = +Math_sin(+d49) / d57;
michael@0 11015 d57 = d113 * d35;
michael@0 11016 d31 = d114 * d35;
michael@0 11017 d55 = d115 * d35;
michael@0 11018 d35 = +Math_cos(+d49);
michael@0 11019 d43 = +Math_sqrt(+d56);
michael@0 11020 d34 = +(i146 | 0) * (6.2831854820251465 / +(i147 | 0)) * .5;
michael@0 11021 d42 = +Math_sin(+d34) / d43;
michael@0 11022 d43 = d64 * d42;
michael@0 11023 d62 = d78 * d42;
michael@0 11024 d63 = d32 * d42;
michael@0 11025 d42 = +Math_cos(+d34);
michael@0 11026 if (i13) {
michael@0 11027 d34 = -0.0 - d43;
michael@0 11028 d52 = -0.0 - d62;
michael@0 11029 d36 = -0.0 - d63;
michael@0 11030 d37 = d55 * d52 + (d57 * d42 + d35 * d34) - d31 * d36;
michael@0 11031 d38 = d57 * d36 + (d31 * d42 + d35 * d52) - d55 * d34;
michael@0 11032 d53 = d31 * d34 + (d55 * d42 + d35 * d36) - d57 * d52;
michael@0 11033 d51 = d35 * d42 - d57 * d34 - d31 * d52 - d55 * d36;
michael@0 11034 d36 = d63 * d38 + (d43 * d51 + d42 * d37) - d62 * d53;
michael@0 11035 d52 = d43 * d53 + (d42 * d38 + d62 * d51) - d63 * d37;
michael@0 11036 d34 = d62 * d37 + (d63 * d51 + d42 * d53) - d43 * d38;
michael@0 11037 d48 = d42 * d51 - d43 * d37 - d62 * d38 - d63 * d53;
michael@0 11038 d53 = 2.0 / (d48 * d48 + (d34 * d34 + (d36 * d36 + d52 * d52)));
michael@0 11039 d38 = d36 * d53;
michael@0 11040 d37 = d52 * d53;
michael@0 11041 d51 = d34 * d53;
michael@0 11042 d53 = d48 * d38;
michael@0 11043 d54 = d48 * d37;
michael@0 11044 d50 = d48 * d51;
michael@0 11045 d48 = d36 * d38;
michael@0 11046 d38 = d36 * d37;
michael@0 11047 d33 = d36 * d51;
michael@0 11048 d36 = d52 * d37;
michael@0 11049 d37 = d52 * d51;
michael@0 11050 d52 = d34 * d51;
michael@0 11051 d51 = 1.0 - (d36 + d52);
michael@0 11052 d34 = d38 - d50;
michael@0 11053 d47 = d33 + d54;
michael@0 11054 d46 = d38 + d50;
michael@0 11055 d50 = 1.0 - (d48 + d52);
michael@0 11056 d52 = d37 - d53;
michael@0 11057 d38 = d33 - d54;
michael@0 11058 d54 = d37 + d53;
michael@0 11059 d53 = 1.0 - (d48 + d36);
michael@0 11060 d36 = +HEAPF32[i108 >> 2];
michael@0 11061 d48 = +HEAPF32[i109 >> 2];
michael@0 11062 d37 = +HEAPF32[i110 >> 2];
michael@0 11063 d33 = +HEAPF32[i107 >> 2];
michael@0 11064 d45 = +HEAPF32[i106 >> 2];
michael@0 11065 d41 = +HEAPF32[i100 >> 2];
michael@0 11066 d40 = +HEAPF32[i101 >> 2];
michael@0 11067 d39 = +HEAPF32[i99 >> 2];
michael@0 11068 d61 = +HEAPF32[i102 >> 2];
michael@0 11069 HEAPF32[i103 >> 2] = d37 * d47 + (d48 * d34 + d36 * d51);
michael@0 11070 HEAPF32[i98 >> 2] = d51 * d33 + d34 * d45 + d47 * d41;
michael@0 11071 HEAPF32[i11 >> 2] = d51 * d40 + d34 * d39 + d47 * d61;
michael@0 11072 HEAPF32[i12 >> 2] = 0.0;
michael@0 11073 HEAPF32[i79 >> 2] = d37 * d52 + (d36 * d46 + d48 * d50);
michael@0 11074 HEAPF32[i26 >> 2] = d46 * d33 + d50 * d45 + d52 * d41;
michael@0 11075 HEAPF32[i76 >> 2] = d46 * d40 + d50 * d39 + d52 * d61;
michael@0 11076 HEAPF32[i96 >> 2] = 0.0;
michael@0 11077 HEAPF32[i93 >> 2] = d36 * d38 + d48 * d54 + d37 * d53;
michael@0 11078 HEAPF32[i92 >> 2] = d38 * d33 + d54 * d45 + d53 * d41;
michael@0 11079 HEAPF32[i91 >> 2] = d38 * d40 + d54 * d39 + d53 * d61;
michael@0 11080 HEAPF32[i94 >> 2] = 0.0;
michael@0 11081 HEAP32[i67 >> 2] = HEAP32[i68 >> 2];
michael@0 11082 HEAP32[i67 + 4 >> 2] = HEAP32[i68 + 4 >> 2];
michael@0 11083 HEAP32[i67 + 8 >> 2] = HEAP32[i68 + 8 >> 2];
michael@0 11084 HEAP32[i67 + 12 >> 2] = HEAP32[i68 + 12 >> 2];
michael@0 11085 HEAP32[i69 >> 2] = HEAP32[i70 >> 2];
michael@0 11086 HEAP32[i69 + 4 >> 2] = HEAP32[i70 + 4 >> 2];
michael@0 11087 HEAP32[i69 + 8 >> 2] = HEAP32[i70 + 8 >> 2];
michael@0 11088 HEAP32[i69 + 12 >> 2] = HEAP32[i70 + 12 >> 2];
michael@0 11089 HEAP32[i71 >> 2] = HEAP32[i72 >> 2];
michael@0 11090 HEAP32[i71 + 4 >> 2] = HEAP32[i72 + 4 >> 2];
michael@0 11091 HEAP32[i71 + 8 >> 2] = HEAP32[i72 + 8 >> 2];
michael@0 11092 HEAP32[i71 + 12 >> 2] = HEAP32[i72 + 12 >> 2];
michael@0 11093 HEAP32[i73 >> 2] = HEAP32[i74 >> 2];
michael@0 11094 HEAP32[i73 + 4 >> 2] = HEAP32[i74 + 4 >> 2];
michael@0 11095 HEAP32[i73 + 8 >> 2] = HEAP32[i74 + 8 >> 2];
michael@0 11096 HEAP32[i73 + 12 >> 2] = HEAP32[i74 + 12 >> 2];
michael@0 11097 } else {
michael@0 11098 HEAP32[i8 >> 2] = HEAP32[i25 >> 2];
michael@0 11099 HEAP32[i8 + 4 >> 2] = HEAP32[i25 + 4 >> 2];
michael@0 11100 HEAP32[i8 + 8 >> 2] = HEAP32[i25 + 8 >> 2];
michael@0 11101 HEAP32[i8 + 12 >> 2] = HEAP32[i25 + 12 >> 2];
michael@0 11102 HEAP32[i23 >> 2] = HEAP32[i27 >> 2];
michael@0 11103 HEAP32[i23 + 4 >> 2] = HEAP32[i27 + 4 >> 2];
michael@0 11104 HEAP32[i23 + 8 >> 2] = HEAP32[i27 + 8 >> 2];
michael@0 11105 HEAP32[i23 + 12 >> 2] = HEAP32[i27 + 12 >> 2];
michael@0 11106 HEAP32[i29 >> 2] = HEAP32[i28 >> 2];
michael@0 11107 HEAP32[i29 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 11108 HEAP32[i29 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 11109 HEAP32[i29 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 11110 HEAP32[i30 >> 2] = HEAP32[i65 >> 2];
michael@0 11111 HEAP32[i30 + 4 >> 2] = HEAP32[i65 + 4 >> 2];
michael@0 11112 HEAP32[i30 + 8 >> 2] = HEAP32[i65 + 8 >> 2];
michael@0 11113 HEAP32[i30 + 12 >> 2] = HEAP32[i65 + 12 >> 2];
michael@0 11114 d61 = -0.0 - d43;
michael@0 11115 d53 = -0.0 - d62;
michael@0 11116 d39 = -0.0 - d63;
michael@0 11117 d54 = d55 * d53 + (d57 * d42 + d35 * d61) - d31 * d39;
michael@0 11118 d40 = d57 * d39 + (d31 * d42 + d35 * d53) - d55 * d61;
michael@0 11119 d38 = d31 * d61 + (d55 * d42 + d35 * d39) - d57 * d53;
michael@0 11120 d41 = d35 * d42 - d57 * d61 - d31 * d53 - d55 * d39;
michael@0 11121 d39 = d63 * d40 + (d43 * d41 + d42 * d54) - d62 * d38;
michael@0 11122 d55 = d43 * d38 + (d42 * d40 + d62 * d41) - d63 * d54;
michael@0 11123 d53 = d62 * d54 + (d63 * d41 + d42 * d38) - d43 * d40;
michael@0 11124 d31 = d42 * d41 - d43 * d54 - d62 * d40 - d63 * d38;
michael@0 11125 d38 = 2.0 / (d31 * d31 + (d53 * d53 + (d39 * d39 + d55 * d55)));
michael@0 11126 d63 = d39 * d38;
michael@0 11127 d40 = d55 * d38;
michael@0 11128 d62 = d53 * d38;
michael@0 11129 d38 = d31 * d63;
michael@0 11130 d54 = d31 * d40;
michael@0 11131 d43 = d31 * d62;
michael@0 11132 d31 = d39 * d63;
michael@0 11133 d63 = d39 * d40;
michael@0 11134 d41 = d39 * d62;
michael@0 11135 d39 = d55 * d40;
michael@0 11136 d40 = d55 * d62;
michael@0 11137 d55 = d53 * d62;
michael@0 11138 d62 = 1.0 - (d39 + d55);
michael@0 11139 d53 = d63 - d43;
michael@0 11140 d42 = d41 + d54;
michael@0 11141 d61 = d63 + d43;
michael@0 11142 d43 = 1.0 - (d31 + d55);
michael@0 11143 d55 = d40 - d38;
michael@0 11144 d63 = d41 - d54;
michael@0 11145 d54 = d40 + d38;
michael@0 11146 d38 = 1.0 - (d31 + d39);
michael@0 11147 d39 = +HEAPF32[i125 >> 2];
michael@0 11148 d31 = +HEAPF32[i126 >> 2];
michael@0 11149 d40 = +HEAPF32[i127 >> 2];
michael@0 11150 d41 = +HEAPF32[i128 >> 2];
michael@0 11151 d57 = +HEAPF32[i129 >> 2];
michael@0 11152 d35 = +HEAPF32[i130 >> 2];
michael@0 11153 d45 = +HEAPF32[i131 >> 2];
michael@0 11154 d33 = +HEAPF32[i132 >> 2];
michael@0 11155 d37 = +HEAPF32[i133 >> 2];
michael@0 11156 HEAPF32[i134 >> 2] = d40 * d42 + (d31 * d53 + d39 * d62);
michael@0 11157 HEAPF32[i135 >> 2] = d62 * d41 + d53 * d57 + d42 * d35;
michael@0 11158 HEAPF32[i136 >> 2] = d62 * d45 + d53 * d33 + d42 * d37;
michael@0 11159 HEAPF32[i137 >> 2] = 0.0;
michael@0 11160 HEAPF32[i138 >> 2] = d40 * d55 + (d39 * d61 + d31 * d43);
michael@0 11161 HEAPF32[i139 >> 2] = d61 * d41 + d43 * d57 + d55 * d35;
michael@0 11162 HEAPF32[i140 >> 2] = d61 * d45 + d43 * d33 + d55 * d37;
michael@0 11163 HEAPF32[i141 >> 2] = 0.0;
michael@0 11164 HEAPF32[i142 >> 2] = d39 * d63 + d31 * d54 + d40 * d38;
michael@0 11165 HEAPF32[i143 >> 2] = d63 * d41 + d54 * d57 + d38 * d35;
michael@0 11166 HEAPF32[i144 >> 2] = d63 * d45 + d54 * d33 + d38 * d37;
michael@0 11167 HEAPF32[i145 >> 2] = 0.0;
michael@0 11168 }
michael@0 11169 i112 = HEAP32[i14 >> 2] | 0;
michael@0 11170 _memset(i88 | 0, -1 | 0, 16);
michael@0 11171 HEAP32[i89 >> 2] = 3064;
michael@0 11172 HEAP32[i87 >> 2] = i5;
michael@0 11173 HEAP32[i90 >> 2] = HEAP32[i8 >> 2];
michael@0 11174 HEAP32[i90 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 11175 HEAP32[i90 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 11176 HEAP32[i90 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 11177 HEAP32[i85 >> 2] = HEAP32[i23 >> 2];
michael@0 11178 HEAP32[i85 + 4 >> 2] = HEAP32[i23 + 4 >> 2];
michael@0 11179 HEAP32[i85 + 8 >> 2] = HEAP32[i23 + 8 >> 2];
michael@0 11180 HEAP32[i85 + 12 >> 2] = HEAP32[i23 + 12 >> 2];
michael@0 11181 HEAP32[i84 >> 2] = HEAP32[i29 >> 2];
michael@0 11182 HEAP32[i84 + 4 >> 2] = HEAP32[i29 + 4 >> 2];
michael@0 11183 HEAP32[i84 + 8 >> 2] = HEAP32[i29 + 8 >> 2];
michael@0 11184 HEAP32[i84 + 12 >> 2] = HEAP32[i29 + 12 >> 2];
michael@0 11185 HEAP32[i83 >> 2] = HEAP32[i30 >> 2];
michael@0 11186 HEAP32[i83 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 11187 HEAP32[i83 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 11188 HEAP32[i83 + 12 >> 2] = HEAP32[i30 + 12 >> 2];
michael@0 11189 HEAP32[i86 >> 2] = HEAP32[i67 >> 2];
michael@0 11190 HEAP32[i86 + 4 >> 2] = HEAP32[i67 + 4 >> 2];
michael@0 11191 HEAP32[i86 + 8 >> 2] = HEAP32[i67 + 8 >> 2];
michael@0 11192 HEAP32[i86 + 12 >> 2] = HEAP32[i67 + 12 >> 2];
michael@0 11193 HEAP32[i82 >> 2] = HEAP32[i69 >> 2];
michael@0 11194 HEAP32[i82 + 4 >> 2] = HEAP32[i69 + 4 >> 2];
michael@0 11195 HEAP32[i82 + 8 >> 2] = HEAP32[i69 + 8 >> 2];
michael@0 11196 HEAP32[i82 + 12 >> 2] = HEAP32[i69 + 12 >> 2];
michael@0 11197 HEAP32[i104 >> 2] = HEAP32[i71 >> 2];
michael@0 11198 HEAP32[i104 + 4 >> 2] = HEAP32[i71 + 4 >> 2];
michael@0 11199 HEAP32[i104 + 8 >> 2] = HEAP32[i71 + 8 >> 2];
michael@0 11200 HEAP32[i104 + 12 >> 2] = HEAP32[i71 + 12 >> 2];
michael@0 11201 HEAP32[i95 >> 2] = HEAP32[i73 >> 2];
michael@0 11202 HEAP32[i95 + 4 >> 2] = HEAP32[i73 + 4 >> 2];
michael@0 11203 HEAP32[i95 + 8 >> 2] = HEAP32[i73 + 8 >> 2];
michael@0 11204 HEAP32[i95 + 12 >> 2] = HEAP32[i73 + 12 >> 2];
michael@0 11205 HEAP32[i105 >> 2] = HEAP32[i20 >> 2];
michael@0 11206 HEAP32[i105 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 11207 HEAP32[i105 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 11208 HEAP32[i105 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 11209 HEAP32[i111 >> 2] = HEAP32[i116 >> 2];
michael@0 11210 HEAP32[i111 + 4 >> 2] = HEAP32[i116 + 4 >> 2];
michael@0 11211 HEAP32[i111 + 8 >> 2] = HEAP32[i116 + 8 >> 2];
michael@0 11212 HEAP32[i111 + 12 >> 2] = HEAP32[i116 + 12 >> 2];
michael@0 11213 HEAP32[i117 >> 2] = HEAP32[i118 >> 2];
michael@0 11214 HEAP32[i117 + 4 >> 2] = HEAP32[i118 + 4 >> 2];
michael@0 11215 HEAP32[i117 + 8 >> 2] = HEAP32[i118 + 8 >> 2];
michael@0 11216 HEAP32[i117 + 12 >> 2] = HEAP32[i118 + 12 >> 2];
michael@0 11217 HEAP32[i119 >> 2] = HEAP32[i120 >> 2];
michael@0 11218 HEAP32[i119 + 4 >> 2] = HEAP32[i120 + 4 >> 2];
michael@0 11219 HEAP32[i119 + 8 >> 2] = HEAP32[i120 + 8 >> 2];
michael@0 11220 HEAP32[i119 + 12 >> 2] = HEAP32[i120 + 12 >> 2];
michael@0 11221 HEAP8[i121] = i122;
michael@0 11222 HEAP32[i123 >> 2] = i112;
michael@0 11223 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i10, i9, i124, i112, 0);
michael@0 11224 i147 = HEAP32[i4 >> 2] | 0;
michael@0 11225 i146 = i146 + 1 | 0;
michael@0 11226 } while ((i146 | 0) < (i147 | 0));
michael@0 11227 }
michael@0 11228 } while (0);
michael@0 11229 if ((HEAP8[i1 + 16 | 0] | 0) == 0) {
michael@0 11230 STACKTOP = i6;
michael@0 11231 return;
michael@0 11232 }
michael@0 11233 i1 = HEAP32[i21 >> 2] | 0;
michael@0 11234 if ((HEAP32[i1 + 1116 >> 2] | 0) == 0) {
michael@0 11235 STACKTOP = i6;
michael@0 11236 return;
michael@0 11237 }
michael@0 11238 if ((HEAP32[i1 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 11239 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 8 | 0, i5 + 72 | 0);
michael@0 11240 STACKTOP = i6;
michael@0 11241 return;
michael@0 11242 } else {
michael@0 11243 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 72 | 0, i5 + 8 | 0);
michael@0 11244 STACKTOP = i6;
michael@0 11245 return;
michael@0 11246 }
michael@0 11247 }
michael@0 11248 function __ZN20btConvexHullInternal24findEdgeForCoplanarFacesEPNS_6VertexES1_RPNS_4EdgeES4_S1_S1_(i1, i2, i3, i4, i5, i6, i7) {
michael@0 11249 i1 = i1 | 0;
michael@0 11250 i2 = i2 | 0;
michael@0 11251 i3 = i3 | 0;
michael@0 11252 i4 = i4 | 0;
michael@0 11253 i5 = i5 | 0;
michael@0 11254 i6 = i6 | 0;
michael@0 11255 i7 = i7 | 0;
michael@0 11256 var i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0, i88 = 0, i89 = 0, i90 = 0, i91 = 0, i92 = 0, i93 = 0, i94 = 0, i95 = 0, i96 = 0, i97 = 0, i98 = 0, i99 = 0, i100 = 0, i101 = 0, i102 = 0, i103 = 0, i104 = 0, i105 = 0, i106 = 0, i107 = 0, i108 = 0, i109 = 0, i110 = 0, i111 = 0, i112 = 0, i113 = 0, i114 = 0, i115 = 0, i116 = 0, i117 = 0, i118 = 0;
michael@0 11257 i8 = STACKTOP;
michael@0 11258 STACKTOP = STACKTOP + 192 | 0;
michael@0 11259 i9 = i8 | 0;
michael@0 11260 i10 = i8 + 24 | 0;
michael@0 11261 i11 = i8 + 48 | 0;
michael@0 11262 i12 = i8 + 72 | 0;
michael@0 11263 i13 = i8 + 96 | 0;
michael@0 11264 i14 = i8 + 120 | 0;
michael@0 11265 i15 = i8 + 144 | 0;
michael@0 11266 i16 = i8 + 168 | 0;
michael@0 11267 i17 = HEAP32[i4 >> 2] | 0;
michael@0 11268 i18 = HEAP32[i5 >> 2] | 0;
michael@0 11269 i19 = (i17 | 0) != 0;
michael@0 11270 if (i19) {
michael@0 11271 i20 = HEAP32[i17 + 12 >> 2] | 0;
michael@0 11272 } else {
michael@0 11273 i20 = i2;
michael@0 11274 }
michael@0 11275 i21 = HEAP32[i20 + 88 >> 2] | 0;
michael@0 11276 i22 = HEAP32[i20 + 92 >> 2] | 0;
michael@0 11277 i23 = HEAP32[i20 + 96 >> 2] | 0;
michael@0 11278 if ((i18 | 0) == 0) {
michael@0 11279 i24 = i3;
michael@0 11280 } else {
michael@0 11281 i24 = HEAP32[i18 + 12 >> 2] | 0;
michael@0 11282 }
michael@0 11283 i20 = HEAP32[i24 + 88 >> 2] | 0;
michael@0 11284 i25 = HEAP32[i24 + 92 >> 2] | 0;
michael@0 11285 i26 = HEAP32[i24 + 96 >> 2] | 0;
michael@0 11286 i24 = HEAP32[i2 + 88 >> 2] | 0;
michael@0 11287 i27 = (HEAP32[i3 + 88 >> 2] | 0) - i24 | 0;
michael@0 11288 i28 = HEAP32[i2 + 92 >> 2] | 0;
michael@0 11289 i29 = (HEAP32[i3 + 92 >> 2] | 0) - i28 | 0;
michael@0 11290 i30 = HEAP32[i2 + 96 >> 2] | 0;
michael@0 11291 i2 = (HEAP32[i3 + 96 >> 2] | 0) - i30 | 0;
michael@0 11292 i3 = HEAP32[(i19 ? i17 : i18) + 12 >> 2] | 0;
michael@0 11293 i19 = (HEAP32[i3 + 88 >> 2] | 0) - i24 | 0;
michael@0 11294 i31 = (HEAP32[i3 + 92 >> 2] | 0) - i28 | 0;
michael@0 11295 i32 = (HEAP32[i3 + 96 >> 2] | 0) - i30 | 0;
michael@0 11296 i3 = Math_imul(i31, i2) | 0;
michael@0 11297 i33 = i3 - (Math_imul(i32, i29) | 0) | 0;
michael@0 11298 i3 = i33;
michael@0 11299 i34 = (i33 | 0) < 0 ? -1 : 0;
michael@0 11300 i33 = Math_imul(i32, i27) | 0;
michael@0 11301 i32 = i33 - (Math_imul(i19, i2) | 0) | 0;
michael@0 11302 i33 = i32;
michael@0 11303 i35 = (i32 | 0) < 0 ? -1 : 0;
michael@0 11304 i32 = Math_imul(i19, i29) | 0;
michael@0 11305 i19 = i32 - (Math_imul(i31, i27) | 0) | 0;
michael@0 11306 i31 = i19;
michael@0 11307 i32 = (i19 | 0) < 0 ? -1 : 0;
michael@0 11308 i19 = ___muldi3(i3, i34, i24, (i24 | 0) < 0 ? -1 : 0) | 0;
michael@0 11309 i24 = tempRet0;
michael@0 11310 i36 = ___muldi3(i33, i35, i28, (i28 | 0) < 0 ? -1 : 0) | 0;
michael@0 11311 i28 = tempRet0;
michael@0 11312 i37 = ___muldi3(i31, i32, i30, (i30 | 0) < 0 ? -1 : 0) | 0;
michael@0 11313 i30 = _i64Add(i19, i24, i37, tempRet0) | 0;
michael@0 11314 i37 = _i64Add(i30, tempRet0, i36, i28) | 0;
michael@0 11315 i28 = tempRet0;
michael@0 11316 i36 = i29;
michael@0 11317 i30 = (i29 | 0) < 0 ? -1 : 0;
michael@0 11318 i24 = ___muldi3(i31, i32, i36, i30) | 0;
michael@0 11319 i19 = tempRet0;
michael@0 11320 i38 = i2;
michael@0 11321 i39 = (i2 | 0) < 0 ? -1 : 0;
michael@0 11322 i40 = ___muldi3(i33, i35, i38, i39) | 0;
michael@0 11323 i41 = _i64Subtract(i24, i19, i40, tempRet0) | 0;
michael@0 11324 i40 = tempRet0;
michael@0 11325 i19 = ___muldi3(i3, i34, i38, i39) | 0;
michael@0 11326 i39 = tempRet0;
michael@0 11327 i38 = i27;
michael@0 11328 i24 = (i27 | 0) < 0 ? -1 : 0;
michael@0 11329 i42 = ___muldi3(i31, i32, i38, i24) | 0;
michael@0 11330 i43 = _i64Subtract(i19, i39, i42, tempRet0) | 0;
michael@0 11331 i42 = tempRet0;
michael@0 11332 i39 = ___muldi3(i33, i35, i38, i24) | 0;
michael@0 11333 i24 = tempRet0;
michael@0 11334 i38 = ___muldi3(i3, i34, i36, i30) | 0;
michael@0 11335 i30 = _i64Subtract(i39, i24, i38, tempRet0) | 0;
michael@0 11336 i38 = tempRet0;
michael@0 11337 i24 = ___muldi3(i41, i40, i21, (i21 | 0) < 0 ? -1 : 0) | 0;
michael@0 11338 i39 = tempRet0;
michael@0 11339 i36 = ___muldi3(i43, i42, i22, (i22 | 0) < 0 ? -1 : 0) | 0;
michael@0 11340 i19 = _i64Add(i36, tempRet0, i24, i39) | 0;
michael@0 11341 i39 = tempRet0;
michael@0 11342 i24 = ___muldi3(i30, i38, i23, (i23 | 0) < 0 ? -1 : 0) | 0;
michael@0 11343 i36 = _i64Add(i19, i39, i24, tempRet0) | 0;
michael@0 11344 i24 = tempRet0;
michael@0 11345 do {
michael@0 11346 if ((i17 | 0) == 0) {
michael@0 11347 i44 = i24;
michael@0 11348 i45 = i36;
michael@0 11349 i46 = i21;
michael@0 11350 i47 = i22;
michael@0 11351 i48 = i23;
michael@0 11352 i49 = i18;
michael@0 11353 } else {
michael@0 11354 if ((HEAP32[i17 + 12 >> 2] | 0) == (i6 | 0)) {
michael@0 11355 i44 = i24;
michael@0 11356 i45 = i36;
michael@0 11357 i46 = i21;
michael@0 11358 i47 = i22;
michael@0 11359 i48 = i23;
michael@0 11360 i49 = i18;
michael@0 11361 break;
michael@0 11362 }
michael@0 11363 i39 = i1 + 100 | 0;
michael@0 11364 i19 = i23;
michael@0 11365 i50 = i22;
michael@0 11366 i51 = i21;
michael@0 11367 i52 = i24;
michael@0 11368 i53 = i36;
michael@0 11369 i54 = i17;
michael@0 11370 while (1) {
michael@0 11371 i55 = HEAP32[(HEAP32[i54 + 8 >> 2] | 0) + 4 >> 2] | 0;
michael@0 11372 i56 = i55 + 12 | 0;
michael@0 11373 i57 = HEAP32[i56 >> 2] | 0;
michael@0 11374 i58 = HEAP32[i57 + 88 >> 2] | 0;
michael@0 11375 i59 = i58;
michael@0 11376 i60 = (i58 | 0) < 0 ? -1 : 0;
michael@0 11377 i58 = ___muldi3(i59, i60, i3, i34) | 0;
michael@0 11378 i61 = tempRet0;
michael@0 11379 i62 = HEAP32[i57 + 92 >> 2] | 0;
michael@0 11380 i63 = i62;
michael@0 11381 i64 = (i62 | 0) < 0 ? -1 : 0;
michael@0 11382 i62 = ___muldi3(i63, i64, i33, i35) | 0;
michael@0 11383 i65 = _i64Add(i62, tempRet0, i58, i61) | 0;
michael@0 11384 i61 = tempRet0;
michael@0 11385 i58 = HEAP32[i57 + 96 >> 2] | 0;
michael@0 11386 i57 = i58;
michael@0 11387 i62 = (i58 | 0) < 0 ? -1 : 0;
michael@0 11388 i58 = ___muldi3(i57, i62, i31, i32) | 0;
michael@0 11389 i66 = _i64Add(i65, i61, i58, tempRet0) | 0;
michael@0 11390 i58 = tempRet0;
michael@0 11391 if ((i58 | 0) < (i28 | 0) | (i58 | 0) == (i28 | 0) & i66 >>> 0 < i37 >>> 0) {
michael@0 11392 i67 = i19;
michael@0 11393 i68 = i50;
michael@0 11394 i69 = i51;
michael@0 11395 i70 = i52;
michael@0 11396 i71 = i53;
michael@0 11397 break;
michael@0 11398 }
michael@0 11399 if ((HEAP32[i55 + 20 >> 2] | 0) == (HEAP32[i39 >> 2] | 0)) {
michael@0 11400 i67 = i19;
michael@0 11401 i68 = i50;
michael@0 11402 i69 = i51;
michael@0 11403 i70 = i52;
michael@0 11404 i71 = i53;
michael@0 11405 break;
michael@0 11406 }
michael@0 11407 i66 = ___muldi3(i59, i60, i41, i40) | 0;
michael@0 11408 i60 = tempRet0;
michael@0 11409 i59 = ___muldi3(i63, i64, i43, i42) | 0;
michael@0 11410 i64 = _i64Add(i59, tempRet0, i66, i60) | 0;
michael@0 11411 i60 = tempRet0;
michael@0 11412 i66 = ___muldi3(i57, i62, i30, i38) | 0;
michael@0 11413 i62 = _i64Add(i64, i60, i66, tempRet0) | 0;
michael@0 11414 i66 = tempRet0;
michael@0 11415 if (!((i66 | 0) > (i52 | 0) | (i66 | 0) == (i52 | 0) & i62 >>> 0 > i53 >>> 0)) {
michael@0 11416 i67 = i19;
michael@0 11417 i68 = i50;
michael@0 11418 i69 = i51;
michael@0 11419 i70 = i52;
michael@0 11420 i71 = i53;
michael@0 11421 break;
michael@0 11422 }
michael@0 11423 HEAP32[i4 >> 2] = i55;
michael@0 11424 i60 = HEAP32[i56 >> 2] | 0;
michael@0 11425 i56 = HEAP32[i60 + 88 >> 2] | 0;
michael@0 11426 i64 = HEAP32[i60 + 92 >> 2] | 0;
michael@0 11427 i57 = HEAP32[i60 + 96 >> 2] | 0;
michael@0 11428 if ((i60 | 0) == (i6 | 0)) {
michael@0 11429 i67 = i57;
michael@0 11430 i68 = i64;
michael@0 11431 i69 = i56;
michael@0 11432 i70 = i66;
michael@0 11433 i71 = i62;
michael@0 11434 break;
michael@0 11435 } else {
michael@0 11436 i19 = i57;
michael@0 11437 i50 = i64;
michael@0 11438 i51 = i56;
michael@0 11439 i52 = i66;
michael@0 11440 i53 = i62;
michael@0 11441 i54 = i55;
michael@0 11442 }
michael@0 11443 }
michael@0 11444 i44 = i70;
michael@0 11445 i45 = i71;
michael@0 11446 i46 = i69;
michael@0 11447 i47 = i68;
michael@0 11448 i48 = i67;
michael@0 11449 i49 = HEAP32[i5 >> 2] | 0;
michael@0 11450 }
michael@0 11451 } while (0);
michael@0 11452 i67 = ___muldi3(i41, i40, i20, (i20 | 0) < 0 ? -1 : 0) | 0;
michael@0 11453 i68 = tempRet0;
michael@0 11454 i69 = ___muldi3(i43, i42, i25, (i25 | 0) < 0 ? -1 : 0) | 0;
michael@0 11455 i71 = _i64Add(i69, tempRet0, i67, i68) | 0;
michael@0 11456 i68 = tempRet0;
michael@0 11457 i67 = ___muldi3(i30, i38, i26, (i26 | 0) < 0 ? -1 : 0) | 0;
michael@0 11458 i69 = _i64Add(i71, i68, i67, tempRet0) | 0;
michael@0 11459 i67 = tempRet0;
michael@0 11460 L1159 : do {
michael@0 11461 if ((i49 | 0) == 0) {
michael@0 11462 i72 = i67;
michael@0 11463 i73 = i69;
michael@0 11464 i74 = i20;
michael@0 11465 i75 = i25;
michael@0 11466 i76 = i26;
michael@0 11467 i77 = 0;
michael@0 11468 } else {
michael@0 11469 if ((HEAP32[i49 + 12 >> 2] | 0) == (i7 | 0)) {
michael@0 11470 i72 = i67;
michael@0 11471 i73 = i69;
michael@0 11472 i74 = i20;
michael@0 11473 i75 = i25;
michael@0 11474 i76 = i26;
michael@0 11475 i77 = i49;
michael@0 11476 break;
michael@0 11477 }
michael@0 11478 i68 = i1 + 100 | 0;
michael@0 11479 i71 = i26;
michael@0 11480 i70 = i25;
michael@0 11481 i36 = i20;
michael@0 11482 i24 = i67;
michael@0 11483 i21 = i69;
michael@0 11484 i22 = i49;
michael@0 11485 while (1) {
michael@0 11486 i23 = HEAP32[HEAP32[i22 + 8 >> 2] >> 2] | 0;
michael@0 11487 i54 = i23 + 12 | 0;
michael@0 11488 i53 = HEAP32[i54 >> 2] | 0;
michael@0 11489 i52 = HEAP32[i53 + 88 >> 2] | 0;
michael@0 11490 i51 = i52;
michael@0 11491 i50 = (i52 | 0) < 0 ? -1 : 0;
michael@0 11492 i52 = ___muldi3(i51, i50, i3, i34) | 0;
michael@0 11493 i19 = tempRet0;
michael@0 11494 i39 = HEAP32[i53 + 92 >> 2] | 0;
michael@0 11495 i55 = i39;
michael@0 11496 i62 = (i39 | 0) < 0 ? -1 : 0;
michael@0 11497 i39 = ___muldi3(i55, i62, i33, i35) | 0;
michael@0 11498 i66 = _i64Add(i39, tempRet0, i52, i19) | 0;
michael@0 11499 i19 = tempRet0;
michael@0 11500 i52 = HEAP32[i53 + 96 >> 2] | 0;
michael@0 11501 i53 = i52;
michael@0 11502 i39 = (i52 | 0) < 0 ? -1 : 0;
michael@0 11503 i52 = ___muldi3(i53, i39, i31, i32) | 0;
michael@0 11504 i56 = _i64Add(i66, i19, i52, tempRet0) | 0;
michael@0 11505 i52 = tempRet0;
michael@0 11506 if ((i52 | 0) < (i28 | 0) | (i52 | 0) == (i28 | 0) & i56 >>> 0 < i37 >>> 0) {
michael@0 11507 i72 = i24;
michael@0 11508 i73 = i21;
michael@0 11509 i74 = i36;
michael@0 11510 i75 = i70;
michael@0 11511 i76 = i71;
michael@0 11512 i77 = i22;
michael@0 11513 break L1159;
michael@0 11514 }
michael@0 11515 if ((HEAP32[i23 + 20 >> 2] | 0) == (HEAP32[i68 >> 2] | 0)) {
michael@0 11516 i72 = i24;
michael@0 11517 i73 = i21;
michael@0 11518 i74 = i36;
michael@0 11519 i75 = i70;
michael@0 11520 i76 = i71;
michael@0 11521 i77 = i22;
michael@0 11522 break L1159;
michael@0 11523 }
michael@0 11524 i56 = ___muldi3(i51, i50, i41, i40) | 0;
michael@0 11525 i50 = tempRet0;
michael@0 11526 i51 = ___muldi3(i55, i62, i43, i42) | 0;
michael@0 11527 i62 = _i64Add(i51, tempRet0, i56, i50) | 0;
michael@0 11528 i50 = tempRet0;
michael@0 11529 i56 = ___muldi3(i53, i39, i30, i38) | 0;
michael@0 11530 i39 = _i64Add(i62, i50, i56, tempRet0) | 0;
michael@0 11531 i56 = tempRet0;
michael@0 11532 if (!((i56 | 0) > (i24 | 0) | (i56 | 0) == (i24 | 0) & i39 >>> 0 > i21 >>> 0)) {
michael@0 11533 i72 = i24;
michael@0 11534 i73 = i21;
michael@0 11535 i74 = i36;
michael@0 11536 i75 = i70;
michael@0 11537 i76 = i71;
michael@0 11538 i77 = i22;
michael@0 11539 break L1159;
michael@0 11540 }
michael@0 11541 HEAP32[i5 >> 2] = i23;
michael@0 11542 i50 = HEAP32[i54 >> 2] | 0;
michael@0 11543 i54 = HEAP32[i50 + 88 >> 2] | 0;
michael@0 11544 i62 = HEAP32[i50 + 92 >> 2] | 0;
michael@0 11545 i53 = HEAP32[i50 + 96 >> 2] | 0;
michael@0 11546 if ((i50 | 0) == (i7 | 0)) {
michael@0 11547 i72 = i56;
michael@0 11548 i73 = i39;
michael@0 11549 i74 = i54;
michael@0 11550 i75 = i62;
michael@0 11551 i76 = i53;
michael@0 11552 i77 = i23;
michael@0 11553 break;
michael@0 11554 } else {
michael@0 11555 i71 = i53;
michael@0 11556 i70 = i62;
michael@0 11557 i36 = i54;
michael@0 11558 i24 = i56;
michael@0 11559 i21 = i39;
michael@0 11560 i22 = i23;
michael@0 11561 }
michael@0 11562 }
michael@0 11563 }
michael@0 11564 } while (0);
michael@0 11565 i37 = _i64Subtract(i73, i72, i45, i44) | 0;
michael@0 11566 i44 = tempRet0;
michael@0 11567 i45 = 0;
michael@0 11568 if ((i44 | 0) > (i45 | 0) | (i44 | 0) == (i45 | 0) & i37 >>> 0 > 0 >>> 0) {
michael@0 11569 i45 = i1 + 100 | 0;
michael@0 11570 i72 = _i64Subtract(0, 0, i31, i32) | 0;
michael@0 11571 i73 = tempRet0;
michael@0 11572 i28 = i11 + 16 | 0;
michael@0 11573 i49 = i11 | 0;
michael@0 11574 i69 = i11 + 8 | 0;
michael@0 11575 i67 = i12 + 16 | 0;
michael@0 11576 i20 = i12 | 0;
michael@0 11577 i25 = i12 + 8 | 0;
michael@0 11578 i26 = i9 + 16 | 0;
michael@0 11579 i22 = i9 | 0;
michael@0 11580 i21 = i9 + 8 | 0;
michael@0 11581 i24 = i10 + 16 | 0;
michael@0 11582 i36 = i10 | 0;
michael@0 11583 i70 = i10 + 8 | 0;
michael@0 11584 i71 = i44;
michael@0 11585 i68 = i37;
michael@0 11586 i23 = i74;
michael@0 11587 i39 = i75;
michael@0 11588 i56 = i76;
michael@0 11589 i54 = i46;
michael@0 11590 i62 = i47;
michael@0 11591 i53 = i48;
michael@0 11592 L1170 : while (1) {
michael@0 11593 i50 = i71;
michael@0 11594 i51 = i68;
michael@0 11595 i55 = i23;
michael@0 11596 i52 = i39;
michael@0 11597 i19 = i56;
michael@0 11598 L1172 : while (1) {
michael@0 11599 i66 = Math_imul(i55 - i54 | 0, i27) | 0;
michael@0 11600 i64 = Math_imul(i52 - i62 | 0, i29) | 0;
michael@0 11601 i57 = i64 + (Math_imul(i19 - i53 | 0, i2) | 0) + i66 | 0;
michael@0 11602 i66 = i57;
michael@0 11603 i64 = (i57 | 0) < 0 ? -1 : 0;
michael@0 11604 i78 = HEAP32[i4 >> 2] | 0;
michael@0 11605 do {
michael@0 11606 if ((i78 | 0) != 0) {
michael@0 11607 if ((HEAP32[i78 + 12 >> 2] | 0) == (i6 | 0)) {
michael@0 11608 break;
michael@0 11609 }
michael@0 11610 i79 = HEAP32[(HEAP32[i78 >> 2] | 0) + 8 >> 2] | 0;
michael@0 11611 if ((HEAP32[i79 + 20 >> 2] | 0) <= (HEAP32[i45 >> 2] | 0)) {
michael@0 11612 break;
michael@0 11613 }
michael@0 11614 i60 = HEAP32[i79 + 12 >> 2] | 0;
michael@0 11615 i80 = HEAP32[i60 + 88 >> 2] | 0;
michael@0 11616 i59 = i80 - i54 | 0;
michael@0 11617 i81 = HEAP32[i60 + 92 >> 2] | 0;
michael@0 11618 i63 = i81 - i62 | 0;
michael@0 11619 i82 = HEAP32[i60 + 96 >> 2] | 0;
michael@0 11620 i60 = i82 - i53 | 0;
michael@0 11621 i58 = ___muldi3(i59, (i59 | 0) < 0 ? -1 : 0, i41, i40) | 0;
michael@0 11622 i61 = tempRet0;
michael@0 11623 i65 = ___muldi3(i63, (i63 | 0) < 0 ? -1 : 0, i43, i42) | 0;
michael@0 11624 i83 = _i64Add(i65, tempRet0, i58, i61) | 0;
michael@0 11625 i61 = tempRet0;
michael@0 11626 i58 = ___muldi3(i60, (i60 | 0) < 0 ? -1 : 0, i30, i38) | 0;
michael@0 11627 i65 = _i64Add(i83, i61, i58, tempRet0) | 0;
michael@0 11628 i58 = tempRet0;
michael@0 11629 i61 = Math_imul(i59, i27) | 0;
michael@0 11630 i59 = (Math_imul(i63, i29) | 0) + i61 | 0;
michael@0 11631 i61 = i59 + (Math_imul(i60, i2) | 0) | 0;
michael@0 11632 i60 = i61;
michael@0 11633 i59 = (i61 | 0) < 0 ? -1 : 0;
michael@0 11634 if ((i65 | 0) == 0 & (i58 | 0) == 0) {
michael@0 11635 if ((i61 | 0) < 0) {
michael@0 11636 break L1172;
michael@0 11637 } else {
michael@0 11638 break;
michael@0 11639 }
michael@0 11640 }
michael@0 11641 i63 = 0;
michael@0 11642 if (!((i58 | 0) < (i63 | 0) | (i58 | 0) == (i63 | 0) & i65 >>> 0 < 0 >>> 0)) {
michael@0 11643 break;
michael@0 11644 }
michael@0 11645 do {
michael@0 11646 if ((i61 | 0) > 0) {
michael@0 11647 HEAP32[i26 >> 2] = 1;
michael@0 11648 HEAP32[i22 >> 2] = i60;
michael@0 11649 HEAP32[i22 + 4 >> 2] = i59;
michael@0 11650 i84 = 1;
michael@0 11651 } else {
michael@0 11652 if ((i61 | 0) < 0) {
michael@0 11653 HEAP32[i26 >> 2] = -1;
michael@0 11654 i63 = _i64Subtract(0, 0, i60, i59) | 0;
michael@0 11655 HEAP32[i22 >> 2] = i63;
michael@0 11656 HEAP32[i22 + 4 >> 2] = tempRet0;
michael@0 11657 i84 = -1;
michael@0 11658 break;
michael@0 11659 } else {
michael@0 11660 HEAP32[i26 >> 2] = 0;
michael@0 11661 HEAP32[i22 >> 2] = 0;
michael@0 11662 HEAP32[i22 + 4 >> 2] = 0;
michael@0 11663 i84 = 0;
michael@0 11664 break;
michael@0 11665 }
michael@0 11666 }
michael@0 11667 } while (0);
michael@0 11668 i59 = 0;
michael@0 11669 if ((i58 | 0) > (i59 | 0) | (i58 | 0) == (i59 | 0) & i65 >>> 0 > 0 >>> 0) {
michael@0 11670 i85 = i58;
michael@0 11671 i86 = i65;
michael@0 11672 } else {
michael@0 11673 HEAP32[i26 >> 2] = -i84;
michael@0 11674 i59 = _i64Subtract(0, 0, i65, i58) | 0;
michael@0 11675 i85 = tempRet0;
michael@0 11676 i86 = i59;
michael@0 11677 }
michael@0 11678 HEAP32[i21 >> 2] = i86;
michael@0 11679 HEAP32[i21 + 4 >> 2] = i85;
michael@0 11680 do {
michael@0 11681 if ((i57 | 0) > 0) {
michael@0 11682 HEAP32[i24 >> 2] = 1;
michael@0 11683 HEAP32[i36 >> 2] = i66;
michael@0 11684 HEAP32[i36 + 4 >> 2] = i64;
michael@0 11685 i87 = 1;
michael@0 11686 } else {
michael@0 11687 if ((i57 | 0) < 0) {
michael@0 11688 HEAP32[i24 >> 2] = -1;
michael@0 11689 i59 = _i64Subtract(0, 0, i66, i64) | 0;
michael@0 11690 HEAP32[i36 >> 2] = i59;
michael@0 11691 HEAP32[i36 + 4 >> 2] = tempRet0;
michael@0 11692 i87 = -1;
michael@0 11693 break;
michael@0 11694 } else {
michael@0 11695 HEAP32[i24 >> 2] = 0;
michael@0 11696 HEAP32[i36 >> 2] = 0;
michael@0 11697 HEAP32[i36 + 4 >> 2] = 0;
michael@0 11698 i87 = 0;
michael@0 11699 break;
michael@0 11700 }
michael@0 11701 }
michael@0 11702 } while (0);
michael@0 11703 i58 = 0;
michael@0 11704 do {
michael@0 11705 if ((i50 | 0) > (i58 | 0) | (i50 | 0) == (i58 | 0) & i51 >>> 0 > 0 >>> 0) {
michael@0 11706 HEAP32[i70 >> 2] = i51;
michael@0 11707 HEAP32[i70 + 4 >> 2] = i50;
michael@0 11708 } else {
michael@0 11709 i65 = 0;
michael@0 11710 if ((i50 | 0) < (i65 | 0) | (i50 | 0) == (i65 | 0) & i51 >>> 0 < 0 >>> 0) {
michael@0 11711 HEAP32[i24 >> 2] = -i87;
michael@0 11712 i65 = _i64Subtract(0, 0, i51, i50) | 0;
michael@0 11713 HEAP32[i70 >> 2] = i65;
michael@0 11714 HEAP32[i70 + 4 >> 2] = tempRet0;
michael@0 11715 break;
michael@0 11716 } else {
michael@0 11717 HEAP32[i70 >> 2] = 0;
michael@0 11718 HEAP32[i70 + 4 >> 2] = 0;
michael@0 11719 break;
michael@0 11720 }
michael@0 11721 }
michael@0 11722 } while (0);
michael@0 11723 if ((__ZNK20btConvexHullInternal10Rational647compareERKS0_(i9, i10) | 0) > -1) {
michael@0 11724 break L1172;
michael@0 11725 }
michael@0 11726 }
michael@0 11727 } while (0);
michael@0 11728 i58 = HEAP32[i5 >> 2] | 0;
michael@0 11729 if ((i58 | 0) == 0) {
michael@0 11730 i88 = 1019;
michael@0 11731 break L1170;
michael@0 11732 }
michael@0 11733 if ((HEAP32[i58 + 12 >> 2] | 0) == (i7 | 0)) {
michael@0 11734 i88 = 1008;
michael@0 11735 break L1170;
michael@0 11736 }
michael@0 11737 i65 = HEAP32[HEAP32[i58 + 8 >> 2] >> 2] | 0;
michael@0 11738 if ((HEAP32[i65 + 20 >> 2] | 0) <= (HEAP32[i45 >> 2] | 0)) {
michael@0 11739 i88 = 1010;
michael@0 11740 break L1170;
michael@0 11741 }
michael@0 11742 i58 = i65 + 12 | 0;
michael@0 11743 i59 = HEAP32[i58 >> 2] | 0;
michael@0 11744 i60 = HEAP32[i59 + 88 >> 2] | 0;
michael@0 11745 i61 = i60 - i55 | 0;
michael@0 11746 i63 = HEAP32[i59 + 92 >> 2] | 0;
michael@0 11747 i83 = i63 - i52 | 0;
michael@0 11748 i89 = HEAP32[i59 + 96 >> 2] | 0;
michael@0 11749 i59 = i89 - i19 | 0;
michael@0 11750 i90 = i61;
michael@0 11751 i91 = (i61 | 0) < 0 ? -1 : 0;
michael@0 11752 i92 = ___muldi3(i90, i91, i3, i34) | 0;
michael@0 11753 i93 = tempRet0;
michael@0 11754 i94 = i83;
michael@0 11755 i95 = (i83 | 0) < 0 ? -1 : 0;
michael@0 11756 i96 = ___muldi3(i94, i95, i33, i35) | 0;
michael@0 11757 i97 = _i64Add(i96, tempRet0, i92, i93) | 0;
michael@0 11758 i93 = tempRet0;
michael@0 11759 i92 = i59;
michael@0 11760 i96 = (i59 | 0) < 0 ? -1 : 0;
michael@0 11761 i98 = ___muldi3(i92, i96, i72, i73) | 0;
michael@0 11762 if (!((i97 | 0) == (i98 | 0) & (i93 | 0) == (tempRet0 | 0))) {
michael@0 11763 i88 = 1004;
michael@0 11764 break L1170;
michael@0 11765 }
michael@0 11766 i93 = ___muldi3(i90, i91, i41, i40) | 0;
michael@0 11767 i91 = tempRet0;
michael@0 11768 i90 = ___muldi3(i94, i95, i43, i42) | 0;
michael@0 11769 i95 = _i64Add(i90, tempRet0, i93, i91) | 0;
michael@0 11770 i91 = tempRet0;
michael@0 11771 i93 = ___muldi3(i92, i96, i30, i38) | 0;
michael@0 11772 i96 = _i64Add(i95, i91, i93, tempRet0) | 0;
michael@0 11773 i93 = tempRet0;
michael@0 11774 i91 = Math_imul(i61, i27) | 0;
michael@0 11775 i61 = (Math_imul(i83, i29) | 0) + i91 | 0;
michael@0 11776 i91 = i61 + (Math_imul(i59, i2) | 0) | 0;
michael@0 11777 i59 = i91;
michael@0 11778 i61 = (i91 | 0) < 0 ? -1 : 0;
michael@0 11779 i83 = i60 - i54 | 0;
michael@0 11780 i60 = i63 - i62 | 0;
michael@0 11781 i63 = i89 - i53 | 0;
michael@0 11782 i89 = ___muldi3(i83, (i83 | 0) < 0 ? -1 : 0, i41, i40) | 0;
michael@0 11783 i83 = tempRet0;
michael@0 11784 i95 = ___muldi3(i60, (i60 | 0) < 0 ? -1 : 0, i43, i42) | 0;
michael@0 11785 i60 = _i64Add(i95, tempRet0, i89, i83) | 0;
michael@0 11786 i83 = tempRet0;
michael@0 11787 i89 = ___muldi3(i63, (i63 | 0) < 0 ? -1 : 0, i30, i38) | 0;
michael@0 11788 i63 = _i64Add(i60, i83, i89, tempRet0) | 0;
michael@0 11789 i89 = tempRet0;
michael@0 11790 i83 = 0;
michael@0 11791 if (!((i89 | 0) > (i83 | 0) | (i89 | 0) == (i83 | 0) & i63 >>> 0 > 0 >>> 0)) {
michael@0 11792 i88 = 1005;
michael@0 11793 break L1170;
michael@0 11794 }
michael@0 11795 if ((i96 | 0) == 0 & (i93 | 0) == 0) {
michael@0 11796 if ((i91 | 0) >= 0) {
michael@0 11797 i88 = 1011;
michael@0 11798 break L1170;
michael@0 11799 }
michael@0 11800 } else {
michael@0 11801 i83 = 0;
michael@0 11802 if (!((i93 | 0) < (i83 | 0) | (i93 | 0) == (i83 | 0) & i96 >>> 0 < 0 >>> 0)) {
michael@0 11803 i88 = 1009;
michael@0 11804 break L1170;
michael@0 11805 }
michael@0 11806 do {
michael@0 11807 if ((i91 | 0) > 0) {
michael@0 11808 HEAP32[i28 >> 2] = 1;
michael@0 11809 HEAP32[i49 >> 2] = i59;
michael@0 11810 HEAP32[i49 + 4 >> 2] = i61;
michael@0 11811 i99 = 1;
michael@0 11812 } else {
michael@0 11813 if ((i91 | 0) < 0) {
michael@0 11814 HEAP32[i28 >> 2] = -1;
michael@0 11815 i83 = _i64Subtract(0, 0, i59, i61) | 0;
michael@0 11816 HEAP32[i49 >> 2] = i83;
michael@0 11817 HEAP32[i49 + 4 >> 2] = tempRet0;
michael@0 11818 i99 = -1;
michael@0 11819 break;
michael@0 11820 } else {
michael@0 11821 HEAP32[i28 >> 2] = 0;
michael@0 11822 HEAP32[i49 >> 2] = 0;
michael@0 11823 HEAP32[i49 + 4 >> 2] = 0;
michael@0 11824 i99 = 0;
michael@0 11825 break;
michael@0 11826 }
michael@0 11827 }
michael@0 11828 } while (0);
michael@0 11829 i61 = 0;
michael@0 11830 if ((i93 | 0) > (i61 | 0) | (i93 | 0) == (i61 | 0) & i96 >>> 0 > 0 >>> 0) {
michael@0 11831 i100 = i93;
michael@0 11832 i101 = i96;
michael@0 11833 } else {
michael@0 11834 HEAP32[i28 >> 2] = -i99;
michael@0 11835 i61 = _i64Subtract(0, 0, i96, i93) | 0;
michael@0 11836 i100 = tempRet0;
michael@0 11837 i101 = i61;
michael@0 11838 }
michael@0 11839 HEAP32[i69 >> 2] = i101;
michael@0 11840 HEAP32[i69 + 4 >> 2] = i100;
michael@0 11841 do {
michael@0 11842 if ((i57 | 0) > 0) {
michael@0 11843 HEAP32[i67 >> 2] = 1;
michael@0 11844 HEAP32[i20 >> 2] = i66;
michael@0 11845 HEAP32[i20 + 4 >> 2] = i64;
michael@0 11846 i102 = 1;
michael@0 11847 } else {
michael@0 11848 if ((i57 | 0) < 0) {
michael@0 11849 HEAP32[i67 >> 2] = -1;
michael@0 11850 i61 = _i64Subtract(0, 0, i66, i64) | 0;
michael@0 11851 HEAP32[i20 >> 2] = i61;
michael@0 11852 HEAP32[i20 + 4 >> 2] = tempRet0;
michael@0 11853 i102 = -1;
michael@0 11854 break;
michael@0 11855 } else {
michael@0 11856 HEAP32[i67 >> 2] = 0;
michael@0 11857 HEAP32[i20 >> 2] = 0;
michael@0 11858 HEAP32[i20 + 4 >> 2] = 0;
michael@0 11859 i102 = 0;
michael@0 11860 break;
michael@0 11861 }
michael@0 11862 }
michael@0 11863 } while (0);
michael@0 11864 i64 = 0;
michael@0 11865 do {
michael@0 11866 if ((i50 | 0) > (i64 | 0) | (i50 | 0) == (i64 | 0) & i51 >>> 0 > 0 >>> 0) {
michael@0 11867 HEAP32[i25 >> 2] = i51;
michael@0 11868 HEAP32[i25 + 4 >> 2] = i50;
michael@0 11869 } else {
michael@0 11870 i66 = 0;
michael@0 11871 if ((i50 | 0) < (i66 | 0) | (i50 | 0) == (i66 | 0) & i51 >>> 0 < 0 >>> 0) {
michael@0 11872 HEAP32[i67 >> 2] = -i102;
michael@0 11873 i66 = _i64Subtract(0, 0, i51, i50) | 0;
michael@0 11874 HEAP32[i25 >> 2] = i66;
michael@0 11875 HEAP32[i25 + 4 >> 2] = tempRet0;
michael@0 11876 break;
michael@0 11877 } else {
michael@0 11878 HEAP32[i25 >> 2] = 0;
michael@0 11879 HEAP32[i25 + 4 >> 2] = 0;
michael@0 11880 break;
michael@0 11881 }
michael@0 11882 }
michael@0 11883 } while (0);
michael@0 11884 if ((__ZNK20btConvexHullInternal10Rational647compareERKS0_(i11, i12) | 0) <= 0) {
michael@0 11885 i88 = 1006;
michael@0 11886 break L1170;
michael@0 11887 }
michael@0 11888 }
michael@0 11889 HEAP32[i5 >> 2] = i65;
michael@0 11890 i64 = HEAP32[i58 >> 2] | 0;
michael@0 11891 i50 = i89;
michael@0 11892 i51 = i63;
michael@0 11893 i55 = HEAP32[i64 + 88 >> 2] | 0;
michael@0 11894 i52 = HEAP32[i64 + 92 >> 2] | 0;
michael@0 11895 i19 = HEAP32[i64 + 96 >> 2] | 0;
michael@0 11896 }
michael@0 11897 i51 = i55 - i80 | 0;
michael@0 11898 i50 = i52 - i81 | 0;
michael@0 11899 i64 = i19 - i82 | 0;
michael@0 11900 i66 = ___muldi3(i51, (i51 | 0) < 0 ? -1 : 0, i41, i40) | 0;
michael@0 11901 i51 = tempRet0;
michael@0 11902 i57 = ___muldi3(i50, (i50 | 0) < 0 ? -1 : 0, i43, i42) | 0;
michael@0 11903 i50 = _i64Add(i57, tempRet0, i66, i51) | 0;
michael@0 11904 i51 = tempRet0;
michael@0 11905 i66 = ___muldi3(i64, (i64 | 0) < 0 ? -1 : 0, i30, i38) | 0;
michael@0 11906 i64 = _i64Add(i50, i51, i66, tempRet0) | 0;
michael@0 11907 HEAP32[i4 >> 2] = (i78 | 0) == (i17 | 0) ? 0 : i79;
michael@0 11908 i71 = tempRet0;
michael@0 11909 i68 = i64;
michael@0 11910 i23 = i55;
michael@0 11911 i39 = i52;
michael@0 11912 i56 = i19;
michael@0 11913 i54 = i80;
michael@0 11914 i62 = i81;
michael@0 11915 i53 = i82;
michael@0 11916 }
michael@0 11917 if ((i88 | 0) == 1004) {
michael@0 11918 STACKTOP = i8;
michael@0 11919 return;
michael@0 11920 } else if ((i88 | 0) == 1005) {
michael@0 11921 STACKTOP = i8;
michael@0 11922 return;
michael@0 11923 } else if ((i88 | 0) == 1006) {
michael@0 11924 STACKTOP = i8;
michael@0 11925 return;
michael@0 11926 } else if ((i88 | 0) == 1008) {
michael@0 11927 STACKTOP = i8;
michael@0 11928 return;
michael@0 11929 } else if ((i88 | 0) == 1009) {
michael@0 11930 STACKTOP = i8;
michael@0 11931 return;
michael@0 11932 } else if ((i88 | 0) == 1010) {
michael@0 11933 STACKTOP = i8;
michael@0 11934 return;
michael@0 11935 } else if ((i88 | 0) == 1011) {
michael@0 11936 STACKTOP = i8;
michael@0 11937 return;
michael@0 11938 } else if ((i88 | 0) == 1019) {
michael@0 11939 STACKTOP = i8;
michael@0 11940 return;
michael@0 11941 }
michael@0 11942 }
michael@0 11943 i82 = 0;
michael@0 11944 if (!((i44 | 0) < (i82 | 0) | (i44 | 0) == (i82 | 0) & i37 >>> 0 < 0 >>> 0)) {
michael@0 11945 STACKTOP = i8;
michael@0 11946 return;
michael@0 11947 }
michael@0 11948 i82 = i1 + 100 | 0;
michael@0 11949 i1 = _i64Subtract(0, 0, i31, i32) | 0;
michael@0 11950 i32 = tempRet0;
michael@0 11951 i31 = i15 + 16 | 0;
michael@0 11952 i53 = i15 | 0;
michael@0 11953 i81 = i15 + 8 | 0;
michael@0 11954 i62 = i16 + 16 | 0;
michael@0 11955 i80 = i16 | 0;
michael@0 11956 i54 = i16 + 8 | 0;
michael@0 11957 i56 = i13 + 16 | 0;
michael@0 11958 i39 = i13 | 0;
michael@0 11959 i23 = i13 + 8 | 0;
michael@0 11960 i68 = i14 + 16 | 0;
michael@0 11961 i71 = i14 | 0;
michael@0 11962 i79 = i14 + 8 | 0;
michael@0 11963 i17 = i44;
michael@0 11964 i44 = i37;
michael@0 11965 i37 = i74;
michael@0 11966 i74 = i75;
michael@0 11967 i75 = i76;
michael@0 11968 i76 = i46;
michael@0 11969 i46 = i47;
michael@0 11970 i47 = i48;
michael@0 11971 i48 = i77;
michael@0 11972 while (1) {
michael@0 11973 i77 = Math_imul(i37 - i76 | 0, i27) | 0;
michael@0 11974 i78 = Math_imul(i74 - i46 | 0, i29) | 0;
michael@0 11975 i12 = i78 + (Math_imul(i75 - i47 | 0, i2) | 0) + i77 | 0;
michael@0 11976 i77 = i12;
michael@0 11977 i78 = (i12 | 0) < 0 ? -1 : 0;
michael@0 11978 L1257 : do {
michael@0 11979 if ((i48 | 0) == 0) {
michael@0 11980 i103 = i75;
michael@0 11981 i104 = i74;
michael@0 11982 i105 = i37;
michael@0 11983 i106 = i17;
michael@0 11984 i107 = i44;
michael@0 11985 i108 = i12;
michael@0 11986 i109 = i78;
michael@0 11987 i110 = i77;
michael@0 11988 } else {
michael@0 11989 i11 = i75;
michael@0 11990 i25 = i74;
michael@0 11991 i102 = i37;
michael@0 11992 i67 = i17;
michael@0 11993 i20 = i44;
michael@0 11994 i100 = i12;
michael@0 11995 i69 = i78;
michael@0 11996 i101 = i77;
michael@0 11997 i99 = i48;
michael@0 11998 while (1) {
michael@0 11999 if ((HEAP32[i99 + 12 >> 2] | 0) == (i7 | 0)) {
michael@0 12000 i103 = i11;
michael@0 12001 i104 = i25;
michael@0 12002 i105 = i102;
michael@0 12003 i106 = i67;
michael@0 12004 i107 = i20;
michael@0 12005 i108 = i100;
michael@0 12006 i109 = i69;
michael@0 12007 i110 = i101;
michael@0 12008 break L1257;
michael@0 12009 }
michael@0 12010 i28 = HEAP32[(HEAP32[i99 + 4 >> 2] | 0) + 8 >> 2] | 0;
michael@0 12011 if ((HEAP32[i28 + 20 >> 2] | 0) <= (HEAP32[i82 >> 2] | 0)) {
michael@0 12012 i103 = i11;
michael@0 12013 i104 = i25;
michael@0 12014 i105 = i102;
michael@0 12015 i106 = i67;
michael@0 12016 i107 = i20;
michael@0 12017 i108 = i100;
michael@0 12018 i109 = i69;
michael@0 12019 i110 = i101;
michael@0 12020 break L1257;
michael@0 12021 }
michael@0 12022 i49 = HEAP32[i28 + 12 >> 2] | 0;
michael@0 12023 i73 = HEAP32[i49 + 88 >> 2] | 0;
michael@0 12024 i72 = i73 - i102 | 0;
michael@0 12025 i45 = HEAP32[i49 + 92 >> 2] | 0;
michael@0 12026 i10 = i45 - i25 | 0;
michael@0 12027 i9 = HEAP32[i49 + 96 >> 2] | 0;
michael@0 12028 i49 = i9 - i11 | 0;
michael@0 12029 i70 = ___muldi3(i72, (i72 | 0) < 0 ? -1 : 0, i41, i40) | 0;
michael@0 12030 i87 = tempRet0;
michael@0 12031 i24 = ___muldi3(i10, (i10 | 0) < 0 ? -1 : 0, i43, i42) | 0;
michael@0 12032 i36 = _i64Add(i24, tempRet0, i70, i87) | 0;
michael@0 12033 i87 = tempRet0;
michael@0 12034 i70 = ___muldi3(i49, (i49 | 0) < 0 ? -1 : 0, i30, i38) | 0;
michael@0 12035 i24 = _i64Add(i36, i87, i70, tempRet0) | 0;
michael@0 12036 i70 = tempRet0;
michael@0 12037 i87 = Math_imul(i72, i27) | 0;
michael@0 12038 i72 = (Math_imul(i10, i29) | 0) + i87 | 0;
michael@0 12039 i87 = i72 + (Math_imul(i49, i2) | 0) | 0;
michael@0 12040 i49 = i87;
michael@0 12041 i72 = (i87 | 0) < 0 ? -1 : 0;
michael@0 12042 if ((i24 | 0) == 0 & (i70 | 0) == 0) {
michael@0 12043 if ((i87 | 0) <= 0) {
michael@0 12044 i103 = i11;
michael@0 12045 i104 = i25;
michael@0 12046 i105 = i102;
michael@0 12047 i106 = i67;
michael@0 12048 i107 = i20;
michael@0 12049 i108 = i100;
michael@0 12050 i109 = i69;
michael@0 12051 i110 = i101;
michael@0 12052 break L1257;
michael@0 12053 }
michael@0 12054 } else {
michael@0 12055 i10 = 0;
michael@0 12056 if (!((i70 | 0) < (i10 | 0) | (i70 | 0) == (i10 | 0) & i24 >>> 0 < 0 >>> 0)) {
michael@0 12057 i103 = i11;
michael@0 12058 i104 = i25;
michael@0 12059 i105 = i102;
michael@0 12060 i106 = i67;
michael@0 12061 i107 = i20;
michael@0 12062 i108 = i100;
michael@0 12063 i109 = i69;
michael@0 12064 i110 = i101;
michael@0 12065 break L1257;
michael@0 12066 }
michael@0 12067 do {
michael@0 12068 if ((i87 | 0) > 0) {
michael@0 12069 HEAP32[i56 >> 2] = 1;
michael@0 12070 HEAP32[i39 >> 2] = i49;
michael@0 12071 HEAP32[i39 + 4 >> 2] = i72;
michael@0 12072 i111 = 1;
michael@0 12073 } else {
michael@0 12074 if ((i87 | 0) < 0) {
michael@0 12075 HEAP32[i56 >> 2] = -1;
michael@0 12076 i10 = _i64Subtract(0, 0, i49, i72) | 0;
michael@0 12077 HEAP32[i39 >> 2] = i10;
michael@0 12078 HEAP32[i39 + 4 >> 2] = tempRet0;
michael@0 12079 i111 = -1;
michael@0 12080 break;
michael@0 12081 } else {
michael@0 12082 HEAP32[i56 >> 2] = 0;
michael@0 12083 HEAP32[i39 >> 2] = 0;
michael@0 12084 HEAP32[i39 + 4 >> 2] = 0;
michael@0 12085 i111 = 0;
michael@0 12086 break;
michael@0 12087 }
michael@0 12088 }
michael@0 12089 } while (0);
michael@0 12090 i72 = 0;
michael@0 12091 if ((i70 | 0) > (i72 | 0) | (i70 | 0) == (i72 | 0) & i24 >>> 0 > 0 >>> 0) {
michael@0 12092 i112 = i70;
michael@0 12093 i113 = i24;
michael@0 12094 } else {
michael@0 12095 HEAP32[i56 >> 2] = -i111;
michael@0 12096 i72 = _i64Subtract(0, 0, i24, i70) | 0;
michael@0 12097 i112 = tempRet0;
michael@0 12098 i113 = i72;
michael@0 12099 }
michael@0 12100 HEAP32[i23 >> 2] = i113;
michael@0 12101 HEAP32[i23 + 4 >> 2] = i112;
michael@0 12102 do {
michael@0 12103 if ((i100 | 0) > 0) {
michael@0 12104 HEAP32[i68 >> 2] = 1;
michael@0 12105 HEAP32[i71 >> 2] = i101;
michael@0 12106 HEAP32[i71 + 4 >> 2] = i69;
michael@0 12107 i114 = 1;
michael@0 12108 } else {
michael@0 12109 if ((i100 | 0) < 0) {
michael@0 12110 HEAP32[i68 >> 2] = -1;
michael@0 12111 i72 = _i64Subtract(0, 0, i101, i69) | 0;
michael@0 12112 HEAP32[i71 >> 2] = i72;
michael@0 12113 HEAP32[i71 + 4 >> 2] = tempRet0;
michael@0 12114 i114 = -1;
michael@0 12115 break;
michael@0 12116 } else {
michael@0 12117 HEAP32[i68 >> 2] = 0;
michael@0 12118 HEAP32[i71 >> 2] = 0;
michael@0 12119 HEAP32[i71 + 4 >> 2] = 0;
michael@0 12120 i114 = 0;
michael@0 12121 break;
michael@0 12122 }
michael@0 12123 }
michael@0 12124 } while (0);
michael@0 12125 i70 = 0;
michael@0 12126 do {
michael@0 12127 if ((i67 | 0) > (i70 | 0) | (i67 | 0) == (i70 | 0) & i20 >>> 0 > 0 >>> 0) {
michael@0 12128 HEAP32[i79 >> 2] = i20;
michael@0 12129 HEAP32[i79 + 4 >> 2] = i67;
michael@0 12130 } else {
michael@0 12131 i24 = 0;
michael@0 12132 if ((i67 | 0) < (i24 | 0) | (i67 | 0) == (i24 | 0) & i20 >>> 0 < 0 >>> 0) {
michael@0 12133 HEAP32[i68 >> 2] = -i114;
michael@0 12134 i24 = _i64Subtract(0, 0, i20, i67) | 0;
michael@0 12135 HEAP32[i79 >> 2] = i24;
michael@0 12136 HEAP32[i79 + 4 >> 2] = tempRet0;
michael@0 12137 break;
michael@0 12138 } else {
michael@0 12139 HEAP32[i79 >> 2] = 0;
michael@0 12140 HEAP32[i79 + 4 >> 2] = 0;
michael@0 12141 break;
michael@0 12142 }
michael@0 12143 }
michael@0 12144 } while (0);
michael@0 12145 if ((__ZNK20btConvexHullInternal10Rational647compareERKS0_(i13, i14) | 0) >= 1) {
michael@0 12146 i103 = i11;
michael@0 12147 i104 = i25;
michael@0 12148 i105 = i102;
michael@0 12149 i106 = i67;
michael@0 12150 i107 = i20;
michael@0 12151 i108 = i100;
michael@0 12152 i109 = i69;
michael@0 12153 i110 = i101;
michael@0 12154 break L1257;
michael@0 12155 }
michael@0 12156 }
michael@0 12157 i70 = i73 - i76 | 0;
michael@0 12158 i24 = i45 - i46 | 0;
michael@0 12159 i72 = i9 - i47 | 0;
michael@0 12160 i49 = ___muldi3(i70, (i70 | 0) < 0 ? -1 : 0, i41, i40) | 0;
michael@0 12161 i87 = tempRet0;
michael@0 12162 i10 = ___muldi3(i24, (i24 | 0) < 0 ? -1 : 0, i43, i42) | 0;
michael@0 12163 i36 = _i64Add(i10, tempRet0, i49, i87) | 0;
michael@0 12164 i87 = tempRet0;
michael@0 12165 i49 = ___muldi3(i72, (i72 | 0) < 0 ? -1 : 0, i30, i38) | 0;
michael@0 12166 i10 = _i64Add(i36, i87, i49, tempRet0) | 0;
michael@0 12167 i49 = tempRet0;
michael@0 12168 i87 = (i99 | 0) == (i18 | 0) ? 0 : i28;
michael@0 12169 HEAP32[i5 >> 2] = i87;
michael@0 12170 i36 = Math_imul(i70, i27) | 0;
michael@0 12171 i70 = Math_imul(i24, i29) | 0;
michael@0 12172 i24 = i70 + i36 + (Math_imul(i72, i2) | 0) | 0;
michael@0 12173 i72 = i24;
michael@0 12174 i36 = (i24 | 0) < 0 ? -1 : 0;
michael@0 12175 if ((i87 | 0) == 0) {
michael@0 12176 i103 = i9;
michael@0 12177 i104 = i45;
michael@0 12178 i105 = i73;
michael@0 12179 i106 = i49;
michael@0 12180 i107 = i10;
michael@0 12181 i108 = i24;
michael@0 12182 i109 = i36;
michael@0 12183 i110 = i72;
michael@0 12184 break;
michael@0 12185 } else {
michael@0 12186 i11 = i9;
michael@0 12187 i25 = i45;
michael@0 12188 i102 = i73;
michael@0 12189 i67 = i49;
michael@0 12190 i20 = i10;
michael@0 12191 i100 = i24;
michael@0 12192 i69 = i36;
michael@0 12193 i101 = i72;
michael@0 12194 i99 = i87;
michael@0 12195 }
michael@0 12196 }
michael@0 12197 }
michael@0 12198 } while (0);
michael@0 12199 i77 = HEAP32[i4 >> 2] | 0;
michael@0 12200 if ((i77 | 0) == 0) {
michael@0 12201 i88 = 1012;
michael@0 12202 break;
michael@0 12203 }
michael@0 12204 if ((HEAP32[i77 + 12 >> 2] | 0) == (i6 | 0)) {
michael@0 12205 i88 = 1013;
michael@0 12206 break;
michael@0 12207 }
michael@0 12208 i78 = HEAP32[(HEAP32[i77 + 8 >> 2] | 0) + 4 >> 2] | 0;
michael@0 12209 if ((HEAP32[i78 + 20 >> 2] | 0) <= (HEAP32[i82 >> 2] | 0)) {
michael@0 12210 i88 = 1014;
michael@0 12211 break;
michael@0 12212 }
michael@0 12213 i77 = i78 + 12 | 0;
michael@0 12214 i12 = HEAP32[i77 >> 2] | 0;
michael@0 12215 i19 = HEAP32[i12 + 88 >> 2] | 0;
michael@0 12216 i52 = i19 - i76 | 0;
michael@0 12217 i55 = HEAP32[i12 + 92 >> 2] | 0;
michael@0 12218 i99 = i55 - i46 | 0;
michael@0 12219 i101 = HEAP32[i12 + 96 >> 2] | 0;
michael@0 12220 i12 = i101 - i47 | 0;
michael@0 12221 i69 = i52;
michael@0 12222 i100 = (i52 | 0) < 0 ? -1 : 0;
michael@0 12223 i20 = ___muldi3(i69, i100, i3, i34) | 0;
michael@0 12224 i67 = tempRet0;
michael@0 12225 i102 = i99;
michael@0 12226 i25 = (i99 | 0) < 0 ? -1 : 0;
michael@0 12227 i11 = ___muldi3(i102, i25, i33, i35) | 0;
michael@0 12228 i63 = _i64Add(i11, tempRet0, i20, i67) | 0;
michael@0 12229 i67 = tempRet0;
michael@0 12230 i20 = i12;
michael@0 12231 i11 = (i12 | 0) < 0 ? -1 : 0;
michael@0 12232 i89 = ___muldi3(i20, i11, i1, i32) | 0;
michael@0 12233 if (!((i63 | 0) == (i89 | 0) & (i67 | 0) == (tempRet0 | 0))) {
michael@0 12234 i88 = 1015;
michael@0 12235 break;
michael@0 12236 }
michael@0 12237 i67 = ___muldi3(i69, i100, i41, i40) | 0;
michael@0 12238 i100 = tempRet0;
michael@0 12239 i69 = ___muldi3(i102, i25, i43, i42) | 0;
michael@0 12240 i25 = _i64Add(i69, tempRet0, i67, i100) | 0;
michael@0 12241 i100 = tempRet0;
michael@0 12242 i67 = ___muldi3(i20, i11, i30, i38) | 0;
michael@0 12243 i11 = _i64Add(i25, i100, i67, tempRet0) | 0;
michael@0 12244 i67 = tempRet0;
michael@0 12245 i100 = Math_imul(i52, i27) | 0;
michael@0 12246 i52 = (Math_imul(i99, i29) | 0) + i100 | 0;
michael@0 12247 i100 = i52 + (Math_imul(i12, i2) | 0) | 0;
michael@0 12248 i12 = i100;
michael@0 12249 i52 = (i100 | 0) < 0 ? -1 : 0;
michael@0 12250 i99 = i105 - i19 | 0;
michael@0 12251 i19 = i104 - i55 | 0;
michael@0 12252 i55 = i103 - i101 | 0;
michael@0 12253 i101 = ___muldi3(i99, (i99 | 0) < 0 ? -1 : 0, i41, i40) | 0;
michael@0 12254 i99 = tempRet0;
michael@0 12255 i25 = ___muldi3(i19, (i19 | 0) < 0 ? -1 : 0, i43, i42) | 0;
michael@0 12256 i19 = _i64Add(i25, tempRet0, i101, i99) | 0;
michael@0 12257 i99 = tempRet0;
michael@0 12258 i101 = ___muldi3(i55, (i55 | 0) < 0 ? -1 : 0, i30, i38) | 0;
michael@0 12259 i55 = _i64Add(i19, i99, i101, tempRet0) | 0;
michael@0 12260 i101 = tempRet0;
michael@0 12261 i99 = 0;
michael@0 12262 if (!((i101 | 0) < (i99 | 0) | (i101 | 0) == (i99 | 0) & i55 >>> 0 < 0 >>> 0)) {
michael@0 12263 i88 = 1016;
michael@0 12264 break;
michael@0 12265 }
michael@0 12266 if ((i11 | 0) == 0 & (i67 | 0) == 0) {
michael@0 12267 if ((i100 | 0) <= 0) {
michael@0 12268 i88 = 1017;
michael@0 12269 break;
michael@0 12270 }
michael@0 12271 } else {
michael@0 12272 i99 = 0;
michael@0 12273 if (!((i67 | 0) < (i99 | 0) | (i67 | 0) == (i99 | 0) & i11 >>> 0 < 0 >>> 0)) {
michael@0 12274 i88 = 1018;
michael@0 12275 break;
michael@0 12276 }
michael@0 12277 do {
michael@0 12278 if ((i100 | 0) > 0) {
michael@0 12279 HEAP32[i31 >> 2] = 1;
michael@0 12280 HEAP32[i53 >> 2] = i12;
michael@0 12281 HEAP32[i53 + 4 >> 2] = i52;
michael@0 12282 i115 = 1;
michael@0 12283 } else {
michael@0 12284 if ((i100 | 0) < 0) {
michael@0 12285 HEAP32[i31 >> 2] = -1;
michael@0 12286 i99 = _i64Subtract(0, 0, i12, i52) | 0;
michael@0 12287 HEAP32[i53 >> 2] = i99;
michael@0 12288 HEAP32[i53 + 4 >> 2] = tempRet0;
michael@0 12289 i115 = -1;
michael@0 12290 break;
michael@0 12291 } else {
michael@0 12292 HEAP32[i31 >> 2] = 0;
michael@0 12293 HEAP32[i53 >> 2] = 0;
michael@0 12294 HEAP32[i53 + 4 >> 2] = 0;
michael@0 12295 i115 = 0;
michael@0 12296 break;
michael@0 12297 }
michael@0 12298 }
michael@0 12299 } while (0);
michael@0 12300 i52 = 0;
michael@0 12301 if ((i67 | 0) > (i52 | 0) | (i67 | 0) == (i52 | 0) & i11 >>> 0 > 0 >>> 0) {
michael@0 12302 i116 = i67;
michael@0 12303 i117 = i11;
michael@0 12304 } else {
michael@0 12305 HEAP32[i31 >> 2] = -i115;
michael@0 12306 i52 = _i64Subtract(0, 0, i11, i67) | 0;
michael@0 12307 i116 = tempRet0;
michael@0 12308 i117 = i52;
michael@0 12309 }
michael@0 12310 HEAP32[i81 >> 2] = i117;
michael@0 12311 HEAP32[i81 + 4 >> 2] = i116;
michael@0 12312 do {
michael@0 12313 if ((i108 | 0) > 0) {
michael@0 12314 HEAP32[i62 >> 2] = 1;
michael@0 12315 HEAP32[i80 >> 2] = i110;
michael@0 12316 HEAP32[i80 + 4 >> 2] = i109;
michael@0 12317 i118 = 1;
michael@0 12318 } else {
michael@0 12319 if ((i108 | 0) < 0) {
michael@0 12320 HEAP32[i62 >> 2] = -1;
michael@0 12321 i52 = _i64Subtract(0, 0, i110, i109) | 0;
michael@0 12322 HEAP32[i80 >> 2] = i52;
michael@0 12323 HEAP32[i80 + 4 >> 2] = tempRet0;
michael@0 12324 i118 = -1;
michael@0 12325 break;
michael@0 12326 } else {
michael@0 12327 HEAP32[i62 >> 2] = 0;
michael@0 12328 HEAP32[i80 >> 2] = 0;
michael@0 12329 HEAP32[i80 + 4 >> 2] = 0;
michael@0 12330 i118 = 0;
michael@0 12331 break;
michael@0 12332 }
michael@0 12333 }
michael@0 12334 } while (0);
michael@0 12335 i67 = 0;
michael@0 12336 do {
michael@0 12337 if ((i106 | 0) > (i67 | 0) | (i106 | 0) == (i67 | 0) & i107 >>> 0 > 0 >>> 0) {
michael@0 12338 HEAP32[i54 >> 2] = i107;
michael@0 12339 HEAP32[i54 + 4 >> 2] = i106;
michael@0 12340 } else {
michael@0 12341 i11 = 0;
michael@0 12342 if ((i106 | 0) < (i11 | 0) | (i106 | 0) == (i11 | 0) & i107 >>> 0 < 0 >>> 0) {
michael@0 12343 HEAP32[i62 >> 2] = -i118;
michael@0 12344 i11 = _i64Subtract(0, 0, i107, i106) | 0;
michael@0 12345 HEAP32[i54 >> 2] = i11;
michael@0 12346 HEAP32[i54 + 4 >> 2] = tempRet0;
michael@0 12347 break;
michael@0 12348 } else {
michael@0 12349 HEAP32[i54 >> 2] = 0;
michael@0 12350 HEAP32[i54 + 4 >> 2] = 0;
michael@0 12351 break;
michael@0 12352 }
michael@0 12353 }
michael@0 12354 } while (0);
michael@0 12355 if ((__ZNK20btConvexHullInternal10Rational647compareERKS0_(i15, i16) | 0) >= 0) {
michael@0 12356 i88 = 1020;
michael@0 12357 break;
michael@0 12358 }
michael@0 12359 }
michael@0 12360 HEAP32[i4 >> 2] = i78;
michael@0 12361 i67 = HEAP32[i77 >> 2] | 0;
michael@0 12362 i17 = i101;
michael@0 12363 i44 = i55;
michael@0 12364 i37 = i105;
michael@0 12365 i74 = i104;
michael@0 12366 i75 = i103;
michael@0 12367 i76 = HEAP32[i67 + 88 >> 2] | 0;
michael@0 12368 i46 = HEAP32[i67 + 92 >> 2] | 0;
michael@0 12369 i47 = HEAP32[i67 + 96 >> 2] | 0;
michael@0 12370 i48 = HEAP32[i5 >> 2] | 0;
michael@0 12371 }
michael@0 12372 if ((i88 | 0) == 1012) {
michael@0 12373 STACKTOP = i8;
michael@0 12374 return;
michael@0 12375 } else if ((i88 | 0) == 1013) {
michael@0 12376 STACKTOP = i8;
michael@0 12377 return;
michael@0 12378 } else if ((i88 | 0) == 1014) {
michael@0 12379 STACKTOP = i8;
michael@0 12380 return;
michael@0 12381 } else if ((i88 | 0) == 1015) {
michael@0 12382 STACKTOP = i8;
michael@0 12383 return;
michael@0 12384 } else if ((i88 | 0) == 1016) {
michael@0 12385 STACKTOP = i8;
michael@0 12386 return;
michael@0 12387 } else if ((i88 | 0) == 1017) {
michael@0 12388 STACKTOP = i8;
michael@0 12389 return;
michael@0 12390 } else if ((i88 | 0) == 1018) {
michael@0 12391 STACKTOP = i8;
michael@0 12392 return;
michael@0 12393 } else if ((i88 | 0) == 1020) {
michael@0 12394 STACKTOP = i8;
michael@0 12395 return;
michael@0 12396 }
michael@0 12397 }
michael@0 12398 function __ZN23btDiscreteDynamicsWorld19debugDrawConstraintEP17btTypedConstraint(i1, i2) {
michael@0 12399 i1 = i1 | 0;
michael@0 12400 i2 = i2 | 0;
michael@0 12401 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, d69 = 0.0, d70 = 0.0, d71 = 0.0, d72 = 0.0, d73 = 0.0, d74 = 0.0, d75 = 0.0, d76 = 0.0, d77 = 0.0, d78 = 0.0, d79 = 0.0;
michael@0 12402 i3 = STACKTOP;
michael@0 12403 STACKTOP = STACKTOP + 1008 | 0;
michael@0 12404 i4 = i3 | 0;
michael@0 12405 i5 = i3 + 64 | 0;
michael@0 12406 i6 = i3 + 128 | 0;
michael@0 12407 i7 = i3 + 192 | 0;
michael@0 12408 i8 = i3 + 208 | 0;
michael@0 12409 i9 = i3 + 224 | 0;
michael@0 12410 i10 = i3 + 240 | 0;
michael@0 12411 i11 = i3 + 304 | 0;
michael@0 12412 i12 = i3 + 368 | 0;
michael@0 12413 i13 = i3 + 384 | 0;
michael@0 12414 i14 = i3 + 400 | 0;
michael@0 12415 i15 = i3 + 416 | 0;
michael@0 12416 i16 = i3 + 432 | 0;
michael@0 12417 i17 = i3 + 496 | 0;
michael@0 12418 i18 = i3 + 560 | 0;
michael@0 12419 i19 = i3 + 576 | 0;
michael@0 12420 i20 = i3 + 592 | 0;
michael@0 12421 i21 = i3 + 608 | 0;
michael@0 12422 i22 = i3 + 624 | 0;
michael@0 12423 i23 = i3 + 688 | 0;
michael@0 12424 i24 = i3 + 704 | 0;
michael@0 12425 i25 = i3 + 720 | 0;
michael@0 12426 i26 = i3 + 736 | 0;
michael@0 12427 i27 = i3 + 752 | 0;
michael@0 12428 i28 = i3 + 768 | 0;
michael@0 12429 i29 = i3 + 784 | 0;
michael@0 12430 i30 = i3 + 800 | 0;
michael@0 12431 i31 = i3 + 816 | 0;
michael@0 12432 i32 = i3 + 832 | 0;
michael@0 12433 i33 = i3 + 848 | 0;
michael@0 12434 i34 = i3 + 912 | 0;
michael@0 12435 i35 = i3 + 928 | 0;
michael@0 12436 i36 = i3 + 944 | 0;
michael@0 12437 i37 = i3 + 960 | 0;
michael@0 12438 i38 = i3 + 976 | 0;
michael@0 12439 i39 = i3 + 992 | 0;
michael@0 12440 i40 = i1 | 0;
michael@0 12441 i41 = i1;
michael@0 12442 i1 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12443 i42 = (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 48 >> 2] & 127](i1) | 0) >>> 11;
michael@0 12444 i1 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12445 i43 = (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 48 >> 2] & 127](i1) | 0) >>> 12;
michael@0 12446 d44 = +HEAPF32[i2 + 36 >> 2];
michael@0 12447 if (d44 <= 0.0) {
michael@0 12448 STACKTOP = i3;
michael@0 12449 return;
michael@0 12450 }
michael@0 12451 switch (HEAP32[i2 + 4 >> 2] | 0) {
michael@0 12452 case 3:
michael@0 12453 {
michael@0 12454 HEAPF32[i4 >> 2] = 1.0;
michael@0 12455 _memset(i4 + 4 | 0, 0, 16);
michael@0 12456 HEAPF32[i4 + 20 >> 2] = 1.0;
michael@0 12457 _memset(i4 + 24 | 0, 0, 16);
michael@0 12458 HEAPF32[i4 + 40 >> 2] = 1.0;
michael@0 12459 _memset(i4 + 44 | 0, 0, 20);
michael@0 12460 d45 = +HEAPF32[i2 + 292 >> 2];
michael@0 12461 d46 = +HEAPF32[i2 + 296 >> 2];
michael@0 12462 d47 = +HEAPF32[i2 + 300 >> 2];
michael@0 12463 i1 = HEAP32[i2 + 24 >> 2] | 0;
michael@0 12464 d48 = +HEAPF32[i1 + 56 >> 2] + (d45 * +HEAPF32[i1 + 20 >> 2] + d46 * +HEAPF32[i1 + 24 >> 2] + d47 * +HEAPF32[i1 + 28 >> 2]);
michael@0 12465 d49 = +HEAPF32[i1 + 60 >> 2] + (d45 * +HEAPF32[i1 + 36 >> 2] + d46 * +HEAPF32[i1 + 40 >> 2] + d47 * +HEAPF32[i1 + 44 >> 2]);
michael@0 12466 i50 = i4 + 48 | 0;
michael@0 12467 HEAPF32[i50 >> 2] = +HEAPF32[i1 + 52 >> 2] + (d45 * +HEAPF32[i1 + 4 >> 2] + d46 * +HEAPF32[i1 + 8 >> 2] + d47 * +HEAPF32[i1 + 12 >> 2]);
michael@0 12468 i1 = i4 + 52 | 0;
michael@0 12469 HEAPF32[i1 >> 2] = d48;
michael@0 12470 i51 = i4 + 56 | 0;
michael@0 12471 HEAPF32[i51 >> 2] = d49;
michael@0 12472 i52 = i4 + 60 | 0;
michael@0 12473 HEAPF32[i52 >> 2] = 0.0;
michael@0 12474 i53 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12475 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i53 >> 2] | 0) + 56 >> 2] & 3](i53, i4, d44);
michael@0 12476 d49 = +HEAPF32[i2 + 308 >> 2];
michael@0 12477 d48 = +HEAPF32[i2 + 312 >> 2];
michael@0 12478 d47 = +HEAPF32[i2 + 316 >> 2];
michael@0 12479 i53 = HEAP32[i2 + 28 >> 2] | 0;
michael@0 12480 d46 = +HEAPF32[i53 + 56 >> 2] + (d49 * +HEAPF32[i53 + 20 >> 2] + d48 * +HEAPF32[i53 + 24 >> 2] + d47 * +HEAPF32[i53 + 28 >> 2]);
michael@0 12481 d45 = +HEAPF32[i53 + 60 >> 2] + (d49 * +HEAPF32[i53 + 36 >> 2] + d48 * +HEAPF32[i53 + 40 >> 2] + d47 * +HEAPF32[i53 + 44 >> 2]);
michael@0 12482 HEAPF32[i50 >> 2] = +HEAPF32[i53 + 52 >> 2] + (d49 * +HEAPF32[i53 + 4 >> 2] + d48 * +HEAPF32[i53 + 8 >> 2] + d47 * +HEAPF32[i53 + 12 >> 2]);
michael@0 12483 HEAPF32[i1 >> 2] = d46;
michael@0 12484 HEAPF32[i51 >> 2] = d45;
michael@0 12485 HEAPF32[i52 >> 2] = 0.0;
michael@0 12486 if ((i42 & 1 | 0) == 0) {
michael@0 12487 STACKTOP = i3;
michael@0 12488 return;
michael@0 12489 }
michael@0 12490 i52 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12491 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i52 >> 2] | 0) + 56 >> 2] & 3](i52, i4, d44);
michael@0 12492 STACKTOP = i3;
michael@0 12493 return;
michael@0 12494 }
michael@0 12495 case 4:
michael@0 12496 {
michael@0 12497 __ZNK11btTransformmlERKS_(i5, (HEAP32[i2 + 24 >> 2] | 0) + 4 | 0, i2 + 544 | 0);
michael@0 12498 if ((i42 & 1 | 0) == 0) {
michael@0 12499 __ZNK11btTransformmlERKS_(i6, (HEAP32[i2 + 28 >> 2] | 0) + 4 | 0, i2 + 608 | 0);
michael@0 12500 i4 = i5;
michael@0 12501 i52 = i6;
michael@0 12502 HEAP32[i4 >> 2] = HEAP32[i52 >> 2];
michael@0 12503 HEAP32[i4 + 4 >> 2] = HEAP32[i52 + 4 >> 2];
michael@0 12504 HEAP32[i4 + 8 >> 2] = HEAP32[i52 + 8 >> 2];
michael@0 12505 HEAP32[i4 + 12 >> 2] = HEAP32[i52 + 12 >> 2];
michael@0 12506 i52 = i5 + 16 | 0;
michael@0 12507 i4 = i6 + 16 | 0;
michael@0 12508 HEAP32[i52 >> 2] = HEAP32[i4 >> 2];
michael@0 12509 HEAP32[i52 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 12510 HEAP32[i52 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 12511 HEAP32[i52 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 12512 i4 = i5 + 32 | 0;
michael@0 12513 i52 = i6 + 32 | 0;
michael@0 12514 HEAP32[i4 >> 2] = HEAP32[i52 >> 2];
michael@0 12515 HEAP32[i4 + 4 >> 2] = HEAP32[i52 + 4 >> 2];
michael@0 12516 HEAP32[i4 + 8 >> 2] = HEAP32[i52 + 8 >> 2];
michael@0 12517 HEAP32[i4 + 12 >> 2] = HEAP32[i52 + 12 >> 2];
michael@0 12518 i52 = i5 + 48 | 0;
michael@0 12519 i4 = i6 + 48 | 0;
michael@0 12520 HEAP32[i52 >> 2] = HEAP32[i4 >> 2];
michael@0 12521 HEAP32[i52 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 12522 HEAP32[i52 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 12523 HEAP32[i52 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 12524 } else {
michael@0 12525 i4 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12526 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i4 >> 2] | 0) + 56 >> 2] & 3](i4, i5, d44);
michael@0 12527 __ZNK11btTransformmlERKS_(i6, (HEAP32[i2 + 28 >> 2] | 0) + 4 | 0, i2 + 608 | 0);
michael@0 12528 i4 = i5;
michael@0 12529 i52 = i6;
michael@0 12530 HEAP32[i4 >> 2] = HEAP32[i52 >> 2];
michael@0 12531 HEAP32[i4 + 4 >> 2] = HEAP32[i52 + 4 >> 2];
michael@0 12532 HEAP32[i4 + 8 >> 2] = HEAP32[i52 + 8 >> 2];
michael@0 12533 HEAP32[i4 + 12 >> 2] = HEAP32[i52 + 12 >> 2];
michael@0 12534 i52 = i5 + 16 | 0;
michael@0 12535 i4 = i6 + 16 | 0;
michael@0 12536 HEAP32[i52 >> 2] = HEAP32[i4 >> 2];
michael@0 12537 HEAP32[i52 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 12538 HEAP32[i52 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 12539 HEAP32[i52 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 12540 i4 = i5 + 32 | 0;
michael@0 12541 i52 = i6 + 32 | 0;
michael@0 12542 HEAP32[i4 >> 2] = HEAP32[i52 >> 2];
michael@0 12543 HEAP32[i4 + 4 >> 2] = HEAP32[i52 + 4 >> 2];
michael@0 12544 HEAP32[i4 + 8 >> 2] = HEAP32[i52 + 8 >> 2];
michael@0 12545 HEAP32[i4 + 12 >> 2] = HEAP32[i52 + 12 >> 2];
michael@0 12546 i52 = i5 + 48 | 0;
michael@0 12547 i4 = i6 + 48 | 0;
michael@0 12548 HEAP32[i52 >> 2] = HEAP32[i4 >> 2];
michael@0 12549 HEAP32[i52 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 12550 HEAP32[i52 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 12551 HEAP32[i52 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 12552 i4 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12553 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i4 >> 2] | 0) + 56 >> 2] & 3](i4, i5, d44);
michael@0 12554 }
michael@0 12555 i4 = i2 + 680 | 0;
michael@0 12556 d45 = +__ZNK14btAngularLimit6getLowEv(i4);
michael@0 12557 d46 = +__ZNK14btAngularLimit7getHighEv(i4);
michael@0 12558 if (d45 == d46) {
michael@0 12559 STACKTOP = i3;
michael@0 12560 return;
michael@0 12561 }
michael@0 12562 i4 = d45 > d46;
michael@0 12563 if ((i43 & 1 | 0) == 0) {
michael@0 12564 STACKTOP = i3;
michael@0 12565 return;
michael@0 12566 }
michael@0 12567 HEAPF32[i7 >> 2] = +HEAPF32[i5 + 8 >> 2];
michael@0 12568 HEAPF32[i7 + 4 >> 2] = +HEAPF32[i5 + 24 >> 2];
michael@0 12569 HEAPF32[i7 + 8 >> 2] = +HEAPF32[i5 + 40 >> 2];
michael@0 12570 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 12571 HEAPF32[i8 >> 2] = +HEAPF32[i5 >> 2];
michael@0 12572 HEAPF32[i8 + 4 >> 2] = +HEAPF32[i5 + 16 >> 2];
michael@0 12573 HEAPF32[i8 + 8 >> 2] = +HEAPF32[i5 + 32 >> 2];
michael@0 12574 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 12575 i52 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12576 i6 = HEAP32[(HEAP32[i52 >> 2] | 0) + 60 >> 2] | 0;
michael@0 12577 _memset(i9 | 0, 0, 16);
michael@0 12578 FUNCTION_TABLE_viiiiffffiif[i6 & 1](i52, i5 + 48 | 0, i7, i8, d44, d44, i4 ? 0.0 : d45, i4 ? 6.2831854820251465 : d46, i9, i4 ^ 1, 10.0);
michael@0 12579 STACKTOP = i3;
michael@0 12580 return;
michael@0 12581 }
michael@0 12582 case 5:
michael@0 12583 {
michael@0 12584 i4 = i2;
michael@0 12585 i9 = i2 + 24 | 0;
michael@0 12586 i8 = i2 + 292 | 0;
michael@0 12587 __ZNK11btTransformmlERKS_(i10, (HEAP32[i9 >> 2] | 0) + 4 | 0, i8);
michael@0 12588 if ((i42 & 1 | 0) == 0) {
michael@0 12589 __ZNK11btTransformmlERKS_(i11, (HEAP32[i2 + 28 >> 2] | 0) + 4 | 0, i2 + 356 | 0);
michael@0 12590 i7 = i10;
michael@0 12591 i5 = i11;
michael@0 12592 HEAP32[i7 >> 2] = HEAP32[i5 >> 2];
michael@0 12593 HEAP32[i7 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 12594 HEAP32[i7 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 12595 HEAP32[i7 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 12596 i5 = i10 + 16 | 0;
michael@0 12597 i7 = i11 + 16 | 0;
michael@0 12598 HEAP32[i5 >> 2] = HEAP32[i7 >> 2];
michael@0 12599 HEAP32[i5 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 12600 HEAP32[i5 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 12601 HEAP32[i5 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 12602 i7 = i10 + 32 | 0;
michael@0 12603 i5 = i11 + 32 | 0;
michael@0 12604 HEAP32[i7 >> 2] = HEAP32[i5 >> 2];
michael@0 12605 HEAP32[i7 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 12606 HEAP32[i7 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 12607 HEAP32[i7 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 12608 i5 = i10 + 48 | 0;
michael@0 12609 i7 = i11 + 48 | 0;
michael@0 12610 HEAP32[i5 >> 2] = HEAP32[i7 >> 2];
michael@0 12611 HEAP32[i5 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 12612 HEAP32[i5 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 12613 HEAP32[i5 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 12614 } else {
michael@0 12615 i7 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12616 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i7 >> 2] | 0) + 56 >> 2] & 3](i7, i10, d44);
michael@0 12617 __ZNK11btTransformmlERKS_(i11, (HEAP32[i2 + 28 >> 2] | 0) + 4 | 0, i2 + 356 | 0);
michael@0 12618 i7 = i10;
michael@0 12619 i5 = i11;
michael@0 12620 HEAP32[i7 >> 2] = HEAP32[i5 >> 2];
michael@0 12621 HEAP32[i7 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 12622 HEAP32[i7 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 12623 HEAP32[i7 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 12624 i5 = i10 + 16 | 0;
michael@0 12625 i7 = i11 + 16 | 0;
michael@0 12626 HEAP32[i5 >> 2] = HEAP32[i7 >> 2];
michael@0 12627 HEAP32[i5 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 12628 HEAP32[i5 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 12629 HEAP32[i5 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 12630 i7 = i10 + 32 | 0;
michael@0 12631 i5 = i11 + 32 | 0;
michael@0 12632 HEAP32[i7 >> 2] = HEAP32[i5 >> 2];
michael@0 12633 HEAP32[i7 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 12634 HEAP32[i7 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 12635 HEAP32[i7 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 12636 i5 = i10 + 48 | 0;
michael@0 12637 i7 = i11 + 48 | 0;
michael@0 12638 HEAP32[i5 >> 2] = HEAP32[i7 >> 2];
michael@0 12639 HEAP32[i5 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 12640 HEAP32[i5 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 12641 HEAP32[i5 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 12642 i7 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12643 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i7 >> 2] | 0) + 56 >> 2] & 3](i7, i10, d44);
michael@0 12644 }
michael@0 12645 if ((i43 & 1 | 0) == 0) {
michael@0 12646 STACKTOP = i3;
michael@0 12647 return;
michael@0 12648 }
michael@0 12649 __ZNK21btConeTwistConstraint16GetPointForAngleEff(i12, i4, 6.0868353843688965, d44);
michael@0 12650 i7 = i10 | 0;
michael@0 12651 i5 = i12 | 0;
michael@0 12652 d46 = +HEAPF32[i5 >> 2];
michael@0 12653 i11 = i10 + 4 | 0;
michael@0 12654 i52 = i12 + 4 | 0;
michael@0 12655 d45 = +HEAPF32[i52 >> 2];
michael@0 12656 i6 = i10 + 8 | 0;
michael@0 12657 i51 = i12 + 8 | 0;
michael@0 12658 d47 = +HEAPF32[i51 >> 2];
michael@0 12659 i1 = i10 + 48 | 0;
michael@0 12660 i53 = i10 + 16 | 0;
michael@0 12661 i50 = i10 + 20 | 0;
michael@0 12662 i54 = i10 + 24 | 0;
michael@0 12663 i55 = i10 + 52 | 0;
michael@0 12664 d48 = +HEAPF32[i55 >> 2] + (d46 * +HEAPF32[i53 >> 2] + d45 * +HEAPF32[i50 >> 2] + d47 * +HEAPF32[i54 >> 2]);
michael@0 12665 i56 = i10 + 32 | 0;
michael@0 12666 i57 = i10 + 36 | 0;
michael@0 12667 i58 = i10 + 40 | 0;
michael@0 12668 i59 = i10 + 56 | 0;
michael@0 12669 d49 = +HEAPF32[i59 >> 2] + (d46 * +HEAPF32[i56 >> 2] + d45 * +HEAPF32[i57 >> 2] + d47 * +HEAPF32[i58 >> 2]);
michael@0 12670 i60 = i12;
michael@0 12671 HEAPF32[i5 >> 2] = +HEAPF32[i1 >> 2] + (+HEAPF32[i7 >> 2] * d46 + +HEAPF32[i11 >> 2] * d45 + +HEAPF32[i6 >> 2] * d47);
michael@0 12672 HEAPF32[i52 >> 2] = d48;
michael@0 12673 HEAPF32[i51 >> 2] = d49;
michael@0 12674 HEAPF32[i12 + 12 >> 2] = 0.0;
michael@0 12675 i51 = i13 | 0;
michael@0 12676 i52 = i13 + 4 | 0;
michael@0 12677 i5 = i13 + 8 | 0;
michael@0 12678 i61 = i13;
michael@0 12679 i62 = i13 + 12 | 0;
michael@0 12680 i63 = i10 + 48 | 0;
michael@0 12681 i64 = i14;
michael@0 12682 i65 = i15;
michael@0 12683 i66 = 0;
michael@0 12684 do {
michael@0 12685 __ZNK21btConeTwistConstraint16GetPointForAngleEff(i13, i4, +(i66 | 0) * 6.283185005187988 * .03125, d44);
michael@0 12686 d49 = +HEAPF32[i51 >> 2];
michael@0 12687 d48 = +HEAPF32[i52 >> 2];
michael@0 12688 d47 = +HEAPF32[i5 >> 2];
michael@0 12689 d45 = +HEAPF32[i55 >> 2] + (d49 * +HEAPF32[i53 >> 2] + d48 * +HEAPF32[i50 >> 2] + d47 * +HEAPF32[i54 >> 2]);
michael@0 12690 d46 = +HEAPF32[i59 >> 2] + (d49 * +HEAPF32[i56 >> 2] + d48 * +HEAPF32[i57 >> 2] + d47 * +HEAPF32[i58 >> 2]);
michael@0 12691 HEAPF32[i51 >> 2] = +HEAPF32[i1 >> 2] + (+HEAPF32[i7 >> 2] * d49 + +HEAPF32[i11 >> 2] * d48 + +HEAPF32[i6 >> 2] * d47);
michael@0 12692 HEAPF32[i52 >> 2] = d45;
michael@0 12693 HEAPF32[i5 >> 2] = d46;
michael@0 12694 HEAPF32[i62 >> 2] = 0.0;
michael@0 12695 i67 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12696 i68 = HEAP32[(HEAP32[i67 >> 2] | 0) + 8 >> 2] | 0;
michael@0 12697 _memset(i64 | 0, 0, 16);
michael@0 12698 FUNCTION_TABLE_viiii[i68 & 127](i67, i12, i13, i14);
michael@0 12699 if ((i66 & 3 | 0) == 0) {
michael@0 12700 i67 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12701 i68 = HEAP32[(HEAP32[i67 >> 2] | 0) + 8 >> 2] | 0;
michael@0 12702 _memset(i65 | 0, 0, 16);
michael@0 12703 FUNCTION_TABLE_viiii[i68 & 127](i67, i63, i13, i15);
michael@0 12704 }
michael@0 12705 HEAP32[i60 >> 2] = HEAP32[i61 >> 2];
michael@0 12706 HEAP32[i60 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 12707 HEAP32[i60 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 12708 HEAP32[i60 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 12709 i66 = i66 + 1 | 0;
michael@0 12710 } while ((i66 | 0) < 32);
michael@0 12711 d46 = +HEAPF32[i2 + 444 >> 2];
michael@0 12712 d45 = +HEAPF32[i2 + 504 >> 2];
michael@0 12713 i66 = HEAP32[i2 + 28 >> 2] | 0;
michael@0 12714 if (+HEAPF32[i66 + 336 >> 2] > 0.0) {
michael@0 12715 __ZNK11btTransformmlERKS_(i16, i66 + 4 | 0, i2 + 356 | 0);
michael@0 12716 i66 = i10;
michael@0 12717 i61 = i16;
michael@0 12718 HEAP32[i66 >> 2] = HEAP32[i61 >> 2];
michael@0 12719 HEAP32[i66 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 12720 HEAP32[i66 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 12721 HEAP32[i66 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 12722 i61 = i10 + 16 | 0;
michael@0 12723 i66 = i16 + 16 | 0;
michael@0 12724 HEAP32[i61 >> 2] = HEAP32[i66 >> 2];
michael@0 12725 HEAP32[i61 + 4 >> 2] = HEAP32[i66 + 4 >> 2];
michael@0 12726 HEAP32[i61 + 8 >> 2] = HEAP32[i66 + 8 >> 2];
michael@0 12727 HEAP32[i61 + 12 >> 2] = HEAP32[i66 + 12 >> 2];
michael@0 12728 i66 = i10 + 32 | 0;
michael@0 12729 i61 = i16 + 32 | 0;
michael@0 12730 HEAP32[i66 >> 2] = HEAP32[i61 >> 2];
michael@0 12731 HEAP32[i66 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 12732 HEAP32[i66 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 12733 HEAP32[i66 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 12734 i61 = i63;
michael@0 12735 i66 = i16 + 48 | 0;
michael@0 12736 HEAP32[i61 >> 2] = HEAP32[i66 >> 2];
michael@0 12737 HEAP32[i61 + 4 >> 2] = HEAP32[i66 + 4 >> 2];
michael@0 12738 HEAP32[i61 + 8 >> 2] = HEAP32[i66 + 8 >> 2];
michael@0 12739 HEAP32[i61 + 12 >> 2] = HEAP32[i66 + 12 >> 2];
michael@0 12740 } else {
michael@0 12741 __ZNK11btTransformmlERKS_(i17, (HEAP32[i9 >> 2] | 0) + 4 | 0, i8);
michael@0 12742 i8 = i10;
michael@0 12743 i9 = i17;
michael@0 12744 HEAP32[i8 >> 2] = HEAP32[i9 >> 2];
michael@0 12745 HEAP32[i8 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 12746 HEAP32[i8 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 12747 HEAP32[i8 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 12748 i9 = i10 + 16 | 0;
michael@0 12749 i8 = i17 + 16 | 0;
michael@0 12750 HEAP32[i9 >> 2] = HEAP32[i8 >> 2];
michael@0 12751 HEAP32[i9 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 12752 HEAP32[i9 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 12753 HEAP32[i9 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 12754 i8 = i10 + 32 | 0;
michael@0 12755 i10 = i17 + 32 | 0;
michael@0 12756 HEAP32[i8 >> 2] = HEAP32[i10 >> 2];
michael@0 12757 HEAP32[i8 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 12758 HEAP32[i8 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 12759 HEAP32[i8 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 12760 i10 = i63;
michael@0 12761 i8 = i17 + 48 | 0;
michael@0 12762 HEAP32[i10 >> 2] = HEAP32[i8 >> 2];
michael@0 12763 HEAP32[i10 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 12764 HEAP32[i10 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 12765 HEAP32[i10 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 12766 }
michael@0 12767 i8 = i18;
michael@0 12768 i10 = i63;
michael@0 12769 HEAP32[i8 >> 2] = HEAP32[i10 >> 2];
michael@0 12770 HEAP32[i8 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 12771 HEAP32[i8 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 12772 HEAP32[i8 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 12773 HEAPF32[i19 >> 2] = +HEAPF32[i7 >> 2];
michael@0 12774 HEAPF32[i19 + 4 >> 2] = +HEAPF32[i53 >> 2];
michael@0 12775 HEAPF32[i19 + 8 >> 2] = +HEAPF32[i56 >> 2];
michael@0 12776 HEAPF32[i19 + 12 >> 2] = 0.0;
michael@0 12777 HEAPF32[i20 >> 2] = +HEAPF32[i11 >> 2];
michael@0 12778 HEAPF32[i20 + 4 >> 2] = +HEAPF32[i50 >> 2];
michael@0 12779 HEAPF32[i20 + 8 >> 2] = +HEAPF32[i57 >> 2];
michael@0 12780 HEAPF32[i20 + 12 >> 2] = 0.0;
michael@0 12781 i57 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12782 i50 = HEAP32[(HEAP32[i57 >> 2] | 0) + 60 >> 2] | 0;
michael@0 12783 _memset(i21 | 0, 0, 16);
michael@0 12784 FUNCTION_TABLE_viiiiffffiif[i50 & 1](i57, i18, i19, i20, d44, d44, -0.0 - d45 - d46, d46 - d45, i21, 1, 10.0);
michael@0 12785 STACKTOP = i3;
michael@0 12786 return;
michael@0 12787 }
michael@0 12788 case 9:
michael@0 12789 case 6:
michael@0 12790 {
michael@0 12791 i21 = i2;
michael@0 12792 i20 = i2 + 1056 | 0;
michael@0 12793 i19 = i22;
michael@0 12794 i18 = i20;
michael@0 12795 HEAP32[i19 >> 2] = HEAP32[i18 >> 2];
michael@0 12796 HEAP32[i19 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 12797 HEAP32[i19 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 12798 HEAP32[i19 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 12799 i57 = i22 + 16 | 0;
michael@0 12800 i50 = i20 + 16 | 0;
michael@0 12801 HEAP32[i57 >> 2] = HEAP32[i50 >> 2];
michael@0 12802 HEAP32[i57 + 4 >> 2] = HEAP32[i50 + 4 >> 2];
michael@0 12803 HEAP32[i57 + 8 >> 2] = HEAP32[i50 + 8 >> 2];
michael@0 12804 HEAP32[i57 + 12 >> 2] = HEAP32[i50 + 12 >> 2];
michael@0 12805 i11 = i22 + 32 | 0;
michael@0 12806 i56 = i20 + 32 | 0;
michael@0 12807 HEAP32[i11 >> 2] = HEAP32[i56 >> 2];
michael@0 12808 HEAP32[i11 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 12809 HEAP32[i11 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 12810 HEAP32[i11 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 12811 i53 = i22 + 48 | 0;
michael@0 12812 i7 = i20 + 48 | 0;
michael@0 12813 HEAP32[i53 >> 2] = HEAP32[i7 >> 2];
michael@0 12814 HEAP32[i53 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 12815 HEAP32[i53 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 12816 HEAP32[i53 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 12817 if ((i42 & 1 | 0) == 0) {
michael@0 12818 i20 = i2 + 1120 | 0;
michael@0 12819 HEAP32[i19 >> 2] = HEAP32[i20 >> 2];
michael@0 12820 HEAP32[i19 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12821 HEAP32[i19 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12822 HEAP32[i19 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12823 i20 = i2 + 1136 | 0;
michael@0 12824 HEAP32[i57 >> 2] = HEAP32[i20 >> 2];
michael@0 12825 HEAP32[i57 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12826 HEAP32[i57 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12827 HEAP32[i57 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12828 i20 = i2 + 1152 | 0;
michael@0 12829 HEAP32[i11 >> 2] = HEAP32[i20 >> 2];
michael@0 12830 HEAP32[i11 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12831 HEAP32[i11 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12832 HEAP32[i11 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12833 i20 = i2 + 1168 | 0;
michael@0 12834 HEAP32[i53 >> 2] = HEAP32[i20 >> 2];
michael@0 12835 HEAP32[i53 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12836 HEAP32[i53 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12837 HEAP32[i53 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12838 } else {
michael@0 12839 i20 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12840 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i20 >> 2] | 0) + 56 >> 2] & 3](i20, i22, d44);
michael@0 12841 i20 = i2 + 1120 | 0;
michael@0 12842 HEAP32[i19 >> 2] = HEAP32[i20 >> 2];
michael@0 12843 HEAP32[i19 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12844 HEAP32[i19 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12845 HEAP32[i19 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12846 i20 = i2 + 1136 | 0;
michael@0 12847 HEAP32[i57 >> 2] = HEAP32[i20 >> 2];
michael@0 12848 HEAP32[i57 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12849 HEAP32[i57 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12850 HEAP32[i57 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12851 i20 = i2 + 1152 | 0;
michael@0 12852 HEAP32[i11 >> 2] = HEAP32[i20 >> 2];
michael@0 12853 HEAP32[i11 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12854 HEAP32[i11 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12855 HEAP32[i11 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12856 i20 = i2 + 1168 | 0;
michael@0 12857 HEAP32[i53 >> 2] = HEAP32[i20 >> 2];
michael@0 12858 HEAP32[i53 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 12859 HEAP32[i53 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 12860 HEAP32[i53 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 12861 i20 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12862 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i20 >> 2] | 0) + 56 >> 2] & 3](i20, i22, d44);
michael@0 12863 }
michael@0 12864 if ((i43 & 1 | 0) == 0) {
michael@0 12865 STACKTOP = i3;
michael@0 12866 return;
michael@0 12867 }
michael@0 12868 HEAP32[i19 >> 2] = HEAP32[i18 >> 2];
michael@0 12869 HEAP32[i19 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 12870 HEAP32[i19 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 12871 HEAP32[i19 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 12872 HEAP32[i57 >> 2] = HEAP32[i50 >> 2];
michael@0 12873 HEAP32[i57 + 4 >> 2] = HEAP32[i50 + 4 >> 2];
michael@0 12874 HEAP32[i57 + 8 >> 2] = HEAP32[i50 + 8 >> 2];
michael@0 12875 HEAP32[i57 + 12 >> 2] = HEAP32[i50 + 12 >> 2];
michael@0 12876 HEAP32[i11 >> 2] = HEAP32[i56 >> 2];
michael@0 12877 HEAP32[i11 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 12878 HEAP32[i11 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 12879 HEAP32[i11 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 12880 HEAP32[i53 >> 2] = HEAP32[i7 >> 2];
michael@0 12881 HEAP32[i53 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 12882 HEAP32[i53 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 12883 HEAP32[i53 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 12884 i20 = i2 + 1168 | 0;
michael@0 12885 i10 = i20;
michael@0 12886 HEAPF32[i23 >> 2] = +HEAPF32[i22 + 8 >> 2];
michael@0 12887 HEAPF32[i23 + 4 >> 2] = +HEAPF32[i22 + 24 >> 2];
michael@0 12888 HEAPF32[i23 + 8 >> 2] = +HEAPF32[i22 + 40 >> 2];
michael@0 12889 HEAPF32[i23 + 12 >> 2] = 0.0;
michael@0 12890 i8 = i22 | 0;
michael@0 12891 i63 = i22 + 16 | 0;
michael@0 12892 i17 = i22 + 32 | 0;
michael@0 12893 i9 = i24 | 0;
michael@0 12894 HEAPF32[i9 >> 2] = +HEAPF32[i8 >> 2];
michael@0 12895 i66 = i24 + 4 | 0;
michael@0 12896 HEAPF32[i66 >> 2] = +HEAPF32[i63 >> 2];
michael@0 12897 i61 = i24 + 8 | 0;
michael@0 12898 HEAPF32[i61 >> 2] = +HEAPF32[i17 >> 2];
michael@0 12899 i16 = i24 + 12 | 0;
michael@0 12900 HEAPF32[i16 >> 2] = 0.0;
michael@0 12901 i60 = i2 + 924 | 0;
michael@0 12902 d45 = +HEAPF32[i60 >> 2];
michael@0 12903 d46 = +HEAPF32[i60 + 4 >> 2];
michael@0 12904 i60 = i2 + 988 | 0;
michael@0 12905 d47 = +HEAPF32[i60 >> 2];
michael@0 12906 d48 = +HEAPF32[i60 + 4 >> 2];
michael@0 12907 i60 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12908 i15 = HEAP32[(HEAP32[i60 >> 2] | 0) + 64 >> 2] | 0;
michael@0 12909 _memset(i25 | 0, 0, 16);
michael@0 12910 FUNCTION_TABLE_viiiifffffif[i15 & 1](i60, i10, i23, i24, d44 * .8999999761581421, d45, d46, d47, d48, i25, 10.0);
michael@0 12911 d48 = +HEAPF32[i22 + 20 >> 2];
michael@0 12912 d47 = +HEAPF32[i22 + 36 >> 2];
michael@0 12913 HEAPF32[i9 >> 2] = +HEAPF32[i22 + 4 >> 2];
michael@0 12914 HEAPF32[i66 >> 2] = d48;
michael@0 12915 HEAPF32[i61 >> 2] = d47;
michael@0 12916 HEAPF32[i16 >> 2] = 0.0;
michael@0 12917 d47 = +__ZNK23btGeneric6DofConstraint8getAngleEi(i21, 1);
michael@0 12918 d48 = +__ZNK23btGeneric6DofConstraint8getAngleEi(i21, 2);
michael@0 12919 d46 = +Math_cos(+d47);
michael@0 12920 d45 = +Math_sin(+d47);
michael@0 12921 d47 = +Math_cos(+d48);
michael@0 12922 d49 = +Math_sin(+d48);
michael@0 12923 d48 = +HEAPF32[i9 >> 2];
michael@0 12924 d69 = +HEAPF32[i66 >> 2];
michael@0 12925 d70 = +HEAPF32[i61 >> 2];
michael@0 12926 HEAPF32[i26 >> 2] = d46 * d47 * d48 + d46 * d49 * d69 - d45 * d70;
michael@0 12927 HEAPF32[i26 + 4 >> 2] = d48 * (-0.0 - d49) + d47 * d69;
michael@0 12928 HEAPF32[i26 + 8 >> 2] = d45 * d47 * d48 + d45 * d49 * d69 + d46 * d70;
michael@0 12929 i61 = i2 + 1120 | 0;
michael@0 12930 HEAP32[i19 >> 2] = HEAP32[i61 >> 2];
michael@0 12931 HEAP32[i19 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 12932 HEAP32[i19 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 12933 HEAP32[i19 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 12934 i61 = i2 + 1136 | 0;
michael@0 12935 HEAP32[i57 >> 2] = HEAP32[i61 >> 2];
michael@0 12936 HEAP32[i57 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 12937 HEAP32[i57 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 12938 HEAP32[i57 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 12939 i61 = i2 + 1152 | 0;
michael@0 12940 HEAP32[i11 >> 2] = HEAP32[i61 >> 2];
michael@0 12941 HEAP32[i11 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 12942 HEAP32[i11 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 12943 HEAP32[i11 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 12944 i61 = i20;
michael@0 12945 HEAP32[i53 >> 2] = HEAP32[i61 >> 2];
michael@0 12946 HEAP32[i53 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 12947 HEAP32[i53 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 12948 HEAP32[i53 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 12949 d70 = -0.0 - +HEAPF32[i63 >> 2];
michael@0 12950 d46 = -0.0 - +HEAPF32[i17 >> 2];
michael@0 12951 HEAPF32[i27 >> 2] = -0.0 - +HEAPF32[i8 >> 2];
michael@0 12952 HEAPF32[i27 + 4 >> 2] = d70;
michael@0 12953 HEAPF32[i27 + 8 >> 2] = d46;
michael@0 12954 HEAPF32[i27 + 12 >> 2] = 0.0;
michael@0 12955 i8 = i2 + 860 | 0;
michael@0 12956 d46 = +HEAPF32[i8 >> 2];
michael@0 12957 d70 = +HEAPF32[i8 + 4 >> 2];
michael@0 12958 do {
michael@0 12959 if (d46 > d70) {
michael@0 12960 i8 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12961 i17 = HEAP32[(HEAP32[i8 >> 2] | 0) + 60 >> 2] | 0;
michael@0 12962 _memset(i28 | 0, 0, 16);
michael@0 12963 FUNCTION_TABLE_viiiiffffiif[i17 & 1](i8, i10, i27, i26, d44, d44, -3.1415927410125732, 3.1415927410125732, i28, 0, 10.0);
michael@0 12964 } else {
michael@0 12965 if (d46 >= d70) {
michael@0 12966 break;
michael@0 12967 }
michael@0 12968 i8 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 12969 i17 = HEAP32[(HEAP32[i8 >> 2] | 0) + 60 >> 2] | 0;
michael@0 12970 _memset(i29 | 0, 0, 16);
michael@0 12971 FUNCTION_TABLE_viiiiffffiif[i17 & 1](i8, i10, i27, i26, d44, d44, d46, d70, i29, 1, 10.0);
michael@0 12972 }
michael@0 12973 } while (0);
michael@0 12974 HEAP32[i19 >> 2] = HEAP32[i18 >> 2];
michael@0 12975 HEAP32[i19 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 12976 HEAP32[i19 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 12977 HEAP32[i19 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 12978 HEAP32[i57 >> 2] = HEAP32[i50 >> 2];
michael@0 12979 HEAP32[i57 + 4 >> 2] = HEAP32[i50 + 4 >> 2];
michael@0 12980 HEAP32[i57 + 8 >> 2] = HEAP32[i50 + 8 >> 2];
michael@0 12981 HEAP32[i57 + 12 >> 2] = HEAP32[i50 + 12 >> 2];
michael@0 12982 HEAP32[i11 >> 2] = HEAP32[i56 >> 2];
michael@0 12983 HEAP32[i11 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 12984 HEAP32[i11 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 12985 HEAP32[i11 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 12986 HEAP32[i53 >> 2] = HEAP32[i7 >> 2];
michael@0 12987 HEAP32[i53 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 12988 HEAP32[i53 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 12989 HEAP32[i53 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 12990 i7 = i2 + 672 | 0;
michael@0 12991 i53 = i30;
michael@0 12992 i56 = i7;
michael@0 12993 HEAP32[i53 >> 2] = HEAP32[i56 >> 2];
michael@0 12994 HEAP32[i53 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 12995 HEAP32[i53 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 12996 HEAP32[i53 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 12997 i56 = i31;
michael@0 12998 i53 = i7 + 16 | 0;
michael@0 12999 HEAP32[i56 >> 2] = HEAP32[i53 >> 2];
michael@0 13000 HEAP32[i56 + 4 >> 2] = HEAP32[i53 + 4 >> 2];
michael@0 13001 HEAP32[i56 + 8 >> 2] = HEAP32[i53 + 8 >> 2];
michael@0 13002 HEAP32[i56 + 12 >> 2] = HEAP32[i53 + 12 >> 2];
michael@0 13003 i53 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 13004 i56 = HEAP32[(HEAP32[i53 >> 2] | 0) + 72 >> 2] | 0;
michael@0 13005 _memset(i32 | 0, 0, 16);
michael@0 13006 FUNCTION_TABLE_viiiii[i56 & 63](i53, i30, i31, i22, i32);
michael@0 13007 STACKTOP = i3;
michael@0 13008 return;
michael@0 13009 }
michael@0 13010 case 7:
michael@0 13011 {
michael@0 13012 i32 = i2 + 816 | 0;
michael@0 13013 i22 = i33;
michael@0 13014 i31 = i32;
michael@0 13015 HEAP32[i22 >> 2] = HEAP32[i31 >> 2];
michael@0 13016 HEAP32[i22 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 13017 HEAP32[i22 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 13018 HEAP32[i22 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 13019 i31 = i33 + 16 | 0;
michael@0 13020 i30 = i32 + 16 | 0;
michael@0 13021 HEAP32[i31 >> 2] = HEAP32[i30 >> 2];
michael@0 13022 HEAP32[i31 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 13023 HEAP32[i31 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 13024 HEAP32[i31 + 12 >> 2] = HEAP32[i30 + 12 >> 2];
michael@0 13025 i30 = i33 + 32 | 0;
michael@0 13026 i53 = i32 + 32 | 0;
michael@0 13027 HEAP32[i30 >> 2] = HEAP32[i53 >> 2];
michael@0 13028 HEAP32[i30 + 4 >> 2] = HEAP32[i53 + 4 >> 2];
michael@0 13029 HEAP32[i30 + 8 >> 2] = HEAP32[i53 + 8 >> 2];
michael@0 13030 HEAP32[i30 + 12 >> 2] = HEAP32[i53 + 12 >> 2];
michael@0 13031 i53 = i33 + 48 | 0;
michael@0 13032 i56 = i32 + 48 | 0;
michael@0 13033 HEAP32[i53 >> 2] = HEAP32[i56 >> 2];
michael@0 13034 HEAP32[i53 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 13035 HEAP32[i53 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 13036 HEAP32[i53 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 13037 if ((i42 & 1 | 0) == 0) {
michael@0 13038 i42 = i2 + 880 | 0;
michael@0 13039 HEAP32[i22 >> 2] = HEAP32[i42 >> 2];
michael@0 13040 HEAP32[i22 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13041 HEAP32[i22 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13042 HEAP32[i22 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13043 i42 = i2 + 896 | 0;
michael@0 13044 HEAP32[i31 >> 2] = HEAP32[i42 >> 2];
michael@0 13045 HEAP32[i31 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13046 HEAP32[i31 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13047 HEAP32[i31 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13048 i42 = i2 + 912 | 0;
michael@0 13049 HEAP32[i30 >> 2] = HEAP32[i42 >> 2];
michael@0 13050 HEAP32[i30 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13051 HEAP32[i30 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13052 HEAP32[i30 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13053 i42 = i2 + 928 | 0;
michael@0 13054 HEAP32[i53 >> 2] = HEAP32[i42 >> 2];
michael@0 13055 HEAP32[i53 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13056 HEAP32[i53 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13057 HEAP32[i53 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13058 } else {
michael@0 13059 i42 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 13060 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i42 >> 2] | 0) + 56 >> 2] & 3](i42, i33, d44);
michael@0 13061 i42 = i2 + 880 | 0;
michael@0 13062 HEAP32[i22 >> 2] = HEAP32[i42 >> 2];
michael@0 13063 HEAP32[i22 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13064 HEAP32[i22 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13065 HEAP32[i22 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13066 i42 = i2 + 896 | 0;
michael@0 13067 HEAP32[i31 >> 2] = HEAP32[i42 >> 2];
michael@0 13068 HEAP32[i31 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13069 HEAP32[i31 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13070 HEAP32[i31 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13071 i42 = i2 + 912 | 0;
michael@0 13072 HEAP32[i30 >> 2] = HEAP32[i42 >> 2];
michael@0 13073 HEAP32[i30 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13074 HEAP32[i30 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13075 HEAP32[i30 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13076 i42 = i2 + 928 | 0;
michael@0 13077 HEAP32[i53 >> 2] = HEAP32[i42 >> 2];
michael@0 13078 HEAP32[i53 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 13079 HEAP32[i53 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 13080 HEAP32[i53 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 13081 i42 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 13082 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i42 >> 2] | 0) + 56 >> 2] & 3](i42, i33, d44);
michael@0 13083 }
michael@0 13084 if ((i43 & 1 | 0) == 0) {
michael@0 13085 STACKTOP = i3;
michael@0 13086 return;
michael@0 13087 }
michael@0 13088 i43 = (HEAP8[i2 + 172 | 0] | 0) != 0 ? i32 : i2 + 880 | 0;
michael@0 13089 d70 = +HEAPF32[i43 >> 2];
michael@0 13090 d46 = +HEAPF32[i43 + 4 >> 2];
michael@0 13091 d69 = +HEAPF32[i43 + 16 >> 2];
michael@0 13092 d49 = +HEAPF32[i43 + 20 >> 2];
michael@0 13093 d45 = +HEAPF32[i43 + 32 >> 2];
michael@0 13094 d48 = +HEAPF32[i43 + 36 >> 2];
michael@0 13095 d47 = +HEAPF32[i43 + 48 >> 2];
michael@0 13096 d71 = +HEAPF32[i43 + 52 >> 2];
michael@0 13097 d72 = +HEAPF32[i43 + 56 >> 2];
michael@0 13098 d73 = +HEAPF32[i2 + 176 >> 2];
michael@0 13099 d74 = d46 * 0.0;
michael@0 13100 d75 = +HEAPF32[i43 + 8 >> 2] * 0.0;
michael@0 13101 d76 = d49 * 0.0;
michael@0 13102 d77 = +HEAPF32[i43 + 24 >> 2] * 0.0;
michael@0 13103 d78 = d48 * 0.0;
michael@0 13104 d79 = +HEAPF32[i43 + 40 >> 2] * 0.0;
michael@0 13105 HEAPF32[i34 >> 2] = d47 + (d75 + (d74 + d70 * d73));
michael@0 13106 HEAPF32[i34 + 4 >> 2] = d71 + (d77 + (d76 + d69 * d73));
michael@0 13107 HEAPF32[i34 + 8 >> 2] = d72 + (d79 + (d78 + d45 * d73));
michael@0 13108 HEAPF32[i34 + 12 >> 2] = 0.0;
michael@0 13109 d73 = +HEAPF32[i2 + 180 >> 2];
michael@0 13110 HEAPF32[i35 >> 2] = d47 + (d75 + (d74 + d70 * d73));
michael@0 13111 HEAPF32[i35 + 4 >> 2] = d71 + (d77 + (d76 + d69 * d73));
michael@0 13112 HEAPF32[i35 + 8 >> 2] = d72 + (d79 + (d78 + d45 * d73));
michael@0 13113 HEAPF32[i35 + 12 >> 2] = 0.0;
michael@0 13114 i43 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 13115 i32 = HEAP32[(HEAP32[i43 >> 2] | 0) + 8 >> 2] | 0;
michael@0 13116 _memset(i36 | 0, 0, 16);
michael@0 13117 FUNCTION_TABLE_viiii[i32 & 127](i43, i34, i35, i36);
michael@0 13118 HEAPF32[i37 >> 2] = d70;
michael@0 13119 HEAPF32[i37 + 4 >> 2] = d69;
michael@0 13120 HEAPF32[i37 + 8 >> 2] = d45;
michael@0 13121 HEAPF32[i37 + 12 >> 2] = 0.0;
michael@0 13122 HEAPF32[i38 >> 2] = d46;
michael@0 13123 HEAPF32[i38 + 4 >> 2] = d49;
michael@0 13124 HEAPF32[i38 + 8 >> 2] = d48;
michael@0 13125 HEAPF32[i38 + 12 >> 2] = 0.0;
michael@0 13126 d48 = +HEAPF32[i2 + 184 >> 2];
michael@0 13127 d49 = +HEAPF32[i2 + 188 >> 2];
michael@0 13128 i36 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i41 >> 2] | 0) + 16 >> 2] & 127](i40) | 0;
michael@0 13129 i40 = HEAP32[(HEAP32[i36 >> 2] | 0) + 60 >> 2] | 0;
michael@0 13130 _memset(i39 | 0, 0, 16);
michael@0 13131 FUNCTION_TABLE_viiiiffffiif[i40 & 1](i36, i2 + 928 | 0, i37, i38, d44, d44, d48, d49, i39, 1, 10.0);
michael@0 13132 STACKTOP = i3;
michael@0 13133 return;
michael@0 13134 }
michael@0 13135 default:
michael@0 13136 {
michael@0 13137 STACKTOP = i3;
michael@0 13138 return;
michael@0 13139 }
michael@0 13140 }
michael@0 13141 }
michael@0 13142 function __ZN20btConvexHullInternal5mergeERNS_16IntermediateHullES1_(i1, i2, i3) {
michael@0 13143 i1 = i1 | 0;
michael@0 13144 i2 = i2 | 0;
michael@0 13145 i3 = i3 | 0;
michael@0 13146 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0, i88 = 0, i89 = 0, i90 = 0, i91 = 0, i92 = 0, i93 = 0, i94 = 0, i95 = 0, i96 = 0, i97 = 0, i98 = 0, i99 = 0, i100 = 0, i101 = 0, i102 = 0, i103 = 0, i104 = 0, i105 = 0, i106 = 0, i107 = 0, i108 = 0, i109 = 0, i110 = 0, i111 = 0, i112 = 0, i113 = 0, i114 = 0, i115 = 0, i116 = 0, i117 = 0, i118 = 0;
michael@0 13147 i4 = STACKTOP;
michael@0 13148 STACKTOP = STACKTOP + 160 | 0;
michael@0 13149 i5 = i4 | 0;
michael@0 13150 i6 = i4 + 8 | 0;
michael@0 13151 i7 = i4 + 16 | 0;
michael@0 13152 i8 = i4 + 24 | 0;
michael@0 13153 i9 = i4 + 32 | 0;
michael@0 13154 i10 = i4 + 48 | 0;
michael@0 13155 i11 = i4 + 72 | 0;
michael@0 13156 i12 = i4 + 96 | 0;
michael@0 13157 i13 = i4 + 120 | 0;
michael@0 13158 i14 = i4 + 144 | 0;
michael@0 13159 i15 = i4 + 152 | 0;
michael@0 13160 if ((HEAP32[i3 + 4 >> 2] | 0) == 0) {
michael@0 13161 STACKTOP = i4;
michael@0 13162 return;
michael@0 13163 }
michael@0 13164 if ((HEAP32[i2 + 4 >> 2] | 0) == 0) {
michael@0 13165 i16 = i2;
michael@0 13166 i17 = i3;
michael@0 13167 HEAP32[i16 >> 2] = HEAP32[i17 >> 2];
michael@0 13168 HEAP32[i16 + 4 >> 2] = HEAP32[i17 + 4 >> 2];
michael@0 13169 HEAP32[i16 + 8 >> 2] = HEAP32[i17 + 8 >> 2];
michael@0 13170 HEAP32[i16 + 12 >> 2] = HEAP32[i17 + 12 >> 2];
michael@0 13171 STACKTOP = i4;
michael@0 13172 return;
michael@0 13173 }
michael@0 13174 i17 = i1 + 100 | 0;
michael@0 13175 HEAP32[i17 >> 2] = (HEAP32[i17 >> 2] | 0) - 1;
michael@0 13176 HEAP32[i5 >> 2] = 0;
michael@0 13177 HEAP32[i6 >> 2] = 0;
michael@0 13178 i16 = __ZN20btConvexHullInternal15mergeProjectionERNS_16IntermediateHullES1_RPNS_6VertexES4_(0, i2, i3, i5, i6) | 0;
michael@0 13179 i3 = HEAP32[i6 >> 2] | 0;
michael@0 13180 if (i16) {
michael@0 13181 i16 = HEAP32[i5 >> 2] | 0;
michael@0 13182 i2 = HEAP32[i3 + 88 >> 2] | 0;
michael@0 13183 i18 = HEAP32[i16 + 88 >> 2] | 0;
michael@0 13184 i19 = i2 - i18 | 0;
michael@0 13185 i20 = HEAP32[i3 + 92 >> 2] | 0;
michael@0 13186 i21 = HEAP32[i16 + 92 >> 2] | 0;
michael@0 13187 i22 = i20 - i21 | 0;
michael@0 13188 i23 = HEAP32[i3 + 96 >> 2] | 0;
michael@0 13189 i24 = HEAP32[i16 + 96 >> 2] | 0;
michael@0 13190 i25 = i23 - i24 | 0;
michael@0 13191 i26 = i22;
michael@0 13192 i27 = (i22 | 0) < 0 ? -1 : 0;
michael@0 13193 i22 = -i19 | 0;
michael@0 13194 i28 = i22;
michael@0 13195 i29 = (i22 | 0) < 0 ? -1 : 0;
michael@0 13196 i22 = i25;
michael@0 13197 i30 = (i25 | 0) < 0 ? -1 : 0;
michael@0 13198 i25 = _i64Subtract(0, 0, i28, i29) | 0;
michael@0 13199 i31 = ___muldi3(i22, i30, i25, tempRet0) | 0;
michael@0 13200 i25 = tempRet0;
michael@0 13201 i32 = ___muldi3(i22, i30, i26, i27) | 0;
michael@0 13202 i30 = tempRet0;
michael@0 13203 i22 = ___muldi3(i19, (i19 | 0) < 0 ? -1 : 0, i28, i29) | 0;
michael@0 13204 i19 = tempRet0;
michael@0 13205 i33 = ___muldi3(i26, i27, i26, i27) | 0;
michael@0 13206 i34 = _i64Subtract(i22, i19, i33, tempRet0) | 0;
michael@0 13207 i33 = tempRet0;
michael@0 13208 i19 = HEAP32[i16 + 8 >> 2] | 0;
michael@0 13209 HEAP32[i7 >> 2] = 0;
michael@0 13210 if ((i19 | 0) == 0) {
michael@0 13211 i35 = 0;
michael@0 13212 } else {
michael@0 13213 i22 = _i64Subtract(0, 0, i26, i27) | 0;
michael@0 13214 i36 = tempRet0;
michael@0 13215 i37 = i19;
michael@0 13216 i38 = 0;
michael@0 13217 while (1) {
michael@0 13218 i39 = HEAP32[i37 + 12 >> 2] | 0;
michael@0 13219 i40 = HEAP32[i39 + 88 >> 2] | 0;
michael@0 13220 i41 = i40 - i18 | 0;
michael@0 13221 i42 = HEAP32[i39 + 92 >> 2] | 0;
michael@0 13222 i43 = i42 - i21 | 0;
michael@0 13223 i44 = i41;
michael@0 13224 i45 = (i41 | 0) < 0 ? -1 : 0;
michael@0 13225 i41 = i43;
michael@0 13226 i46 = (i43 | 0) < 0 ? -1 : 0;
michael@0 13227 i43 = ___muldi3(i41, i46, i28, i29) | 0;
michael@0 13228 i47 = tempRet0;
michael@0 13229 i48 = ___muldi3(i44, i45, i22, i36) | 0;
michael@0 13230 do {
michael@0 13231 if ((i43 | 0) == (i48 | 0) & (i47 | 0) == (tempRet0 | 0)) {
michael@0 13232 i49 = HEAP32[i39 + 96 >> 2] | 0;
michael@0 13233 i50 = i49 - i24 | 0;
michael@0 13234 i51 = ___muldi3(i44, i45, i31, i25) | 0;
michael@0 13235 i52 = tempRet0;
michael@0 13236 i53 = ___muldi3(i41, i46, i32, i30) | 0;
michael@0 13237 i54 = _i64Add(i53, tempRet0, i51, i52) | 0;
michael@0 13238 i52 = tempRet0;
michael@0 13239 i51 = ___muldi3(i50, (i50 | 0) < 0 ? -1 : 0, i34, i33) | 0;
michael@0 13240 i50 = _i64Add(i54, i52, i51, tempRet0) | 0;
michael@0 13241 i51 = tempRet0;
michael@0 13242 i52 = 0;
michael@0 13243 if (!((i51 | 0) > (i52 | 0) | (i51 | 0) == (i52 | 0) & i50 >>> 0 > 0 >>> 0)) {
michael@0 13244 i55 = i38;
michael@0 13245 break;
michael@0 13246 }
michael@0 13247 if ((i38 | 0) != 0) {
michael@0 13248 i50 = (HEAP32[i38 + 4 >> 2] | 0) == (i37 | 0);
michael@0 13249 if ((HEAP32[i38 >> 2] | 0) == (i37 | 0)) {
michael@0 13250 if (!i50) {
michael@0 13251 i55 = i38;
michael@0 13252 break;
michael@0 13253 }
michael@0 13254 i52 = HEAP32[i38 + 12 >> 2] | 0;
michael@0 13255 i51 = HEAP32[(HEAP32[i37 + 8 >> 2] | 0) + 12 >> 2] | 0;
michael@0 13256 i54 = HEAP32[i51 + 88 >> 2] | 0;
michael@0 13257 i53 = (HEAP32[i52 + 88 >> 2] | 0) - i54 | 0;
michael@0 13258 i56 = HEAP32[i51 + 92 >> 2] | 0;
michael@0 13259 i57 = HEAP32[i51 + 96 >> 2] | 0;
michael@0 13260 i51 = (HEAP32[i52 + 96 >> 2] | 0) - i57 | 0;
michael@0 13261 i58 = i49 - i57 | 0;
michael@0 13262 i57 = Math_imul(i58, (HEAP32[i52 + 92 >> 2] | 0) - i56 | 0) | 0;
michael@0 13263 i52 = i57 - (Math_imul(i51, i42 - i56 | 0) | 0) | 0;
michael@0 13264 i56 = Math_imul(i51, i40 - i54 | 0) | 0;
michael@0 13265 i54 = i56 - (Math_imul(i58, i53) | 0) | 0;
michael@0 13266 i53 = ___muldi3(i52, (i52 | 0) < 0 ? -1 : 0, i26, i27) | 0;
michael@0 13267 i52 = tempRet0;
michael@0 13268 i58 = ___muldi3(i54, (i54 | 0) < 0 ? -1 : 0, i28, i29) | 0;
michael@0 13269 i54 = _i64Add(i53, i52, i58, tempRet0) | 0;
michael@0 13270 i58 = tempRet0;
michael@0 13271 i52 = 0;
michael@0 13272 i59 = (i58 | 0) > (i52 | 0) | (i58 | 0) == (i52 | 0) & i54 >>> 0 > 0 >>> 0 ? 2 : 1;
michael@0 13273 } else {
michael@0 13274 i59 = i50 & 1;
michael@0 13275 }
michael@0 13276 if ((i59 | 0) != 1) {
michael@0 13277 i55 = i38;
michael@0 13278 break;
michael@0 13279 }
michael@0 13280 }
michael@0 13281 HEAP32[i7 >> 2] = i37;
michael@0 13282 i55 = i37;
michael@0 13283 } else {
michael@0 13284 i55 = i38;
michael@0 13285 }
michael@0 13286 } while (0);
michael@0 13287 i40 = HEAP32[i37 >> 2] | 0;
michael@0 13288 if ((i40 | 0) == (i19 | 0)) {
michael@0 13289 i35 = i55;
michael@0 13290 break;
michael@0 13291 } else {
michael@0 13292 i37 = i40;
michael@0 13293 i38 = i55;
michael@0 13294 }
michael@0 13295 }
michael@0 13296 }
michael@0 13297 i55 = HEAP32[i3 + 8 >> 2] | 0;
michael@0 13298 HEAP32[i8 >> 2] = 0;
michael@0 13299 if ((i55 | 0) == 0) {
michael@0 13300 i60 = 0;
michael@0 13301 } else {
michael@0 13302 i38 = _i64Subtract(0, 0, i26, i27) | 0;
michael@0 13303 i37 = tempRet0;
michael@0 13304 i19 = i55;
michael@0 13305 i59 = 0;
michael@0 13306 while (1) {
michael@0 13307 i24 = HEAP32[i19 + 12 >> 2] | 0;
michael@0 13308 i36 = HEAP32[i24 + 88 >> 2] | 0;
michael@0 13309 i22 = i36 - i2 | 0;
michael@0 13310 i21 = HEAP32[i24 + 92 >> 2] | 0;
michael@0 13311 i18 = i21 - i20 | 0;
michael@0 13312 i40 = i22;
michael@0 13313 i42 = (i22 | 0) < 0 ? -1 : 0;
michael@0 13314 i22 = i18;
michael@0 13315 i46 = (i18 | 0) < 0 ? -1 : 0;
michael@0 13316 i18 = ___muldi3(i22, i46, i28, i29) | 0;
michael@0 13317 i41 = tempRet0;
michael@0 13318 i45 = ___muldi3(i40, i42, i38, i37) | 0;
michael@0 13319 L958 : do {
michael@0 13320 if ((i18 | 0) == (i45 | 0) & (i41 | 0) == (tempRet0 | 0)) {
michael@0 13321 i44 = HEAP32[i24 + 96 >> 2] | 0;
michael@0 13322 i39 = i44 - i23 | 0;
michael@0 13323 i47 = ___muldi3(i40, i42, i31, i25) | 0;
michael@0 13324 i48 = tempRet0;
michael@0 13325 i43 = ___muldi3(i22, i46, i32, i30) | 0;
michael@0 13326 i50 = _i64Add(i43, tempRet0, i47, i48) | 0;
michael@0 13327 i48 = tempRet0;
michael@0 13328 i47 = ___muldi3(i39, (i39 | 0) < 0 ? -1 : 0, i34, i33) | 0;
michael@0 13329 i39 = _i64Add(i50, i48, i47, tempRet0) | 0;
michael@0 13330 i47 = tempRet0;
michael@0 13331 i48 = 0;
michael@0 13332 if (!((i47 | 0) > (i48 | 0) | (i47 | 0) == (i48 | 0) & i39 >>> 0 > 0 >>> 0)) {
michael@0 13333 i61 = i59;
michael@0 13334 break;
michael@0 13335 }
michael@0 13336 do {
michael@0 13337 if ((i59 | 0) != 0) {
michael@0 13338 if ((HEAP32[i59 >> 2] | 0) != (i19 | 0)) {
michael@0 13339 i61 = i59;
michael@0 13340 break L958;
michael@0 13341 }
michael@0 13342 if ((HEAP32[i59 + 4 >> 2] | 0) != (i19 | 0)) {
michael@0 13343 break;
michael@0 13344 }
michael@0 13345 i39 = HEAP32[i59 + 12 >> 2] | 0;
michael@0 13346 i48 = HEAP32[(HEAP32[i19 + 8 >> 2] | 0) + 12 >> 2] | 0;
michael@0 13347 i47 = HEAP32[i48 + 88 >> 2] | 0;
michael@0 13348 i50 = (HEAP32[i39 + 88 >> 2] | 0) - i47 | 0;
michael@0 13349 i43 = HEAP32[i48 + 92 >> 2] | 0;
michael@0 13350 i54 = HEAP32[i48 + 96 >> 2] | 0;
michael@0 13351 i48 = (HEAP32[i39 + 96 >> 2] | 0) - i54 | 0;
michael@0 13352 i52 = i44 - i54 | 0;
michael@0 13353 i54 = Math_imul(i52, (HEAP32[i39 + 92 >> 2] | 0) - i43 | 0) | 0;
michael@0 13354 i39 = i54 - (Math_imul(i48, i21 - i43 | 0) | 0) | 0;
michael@0 13355 i43 = Math_imul(i48, i36 - i47 | 0) | 0;
michael@0 13356 i47 = i43 - (Math_imul(i52, i50) | 0) | 0;
michael@0 13357 i50 = ___muldi3(i39, (i39 | 0) < 0 ? -1 : 0, i26, i27) | 0;
michael@0 13358 i39 = tempRet0;
michael@0 13359 i52 = ___muldi3(i47, (i47 | 0) < 0 ? -1 : 0, i28, i29) | 0;
michael@0 13360 i47 = _i64Add(i50, i39, i52, tempRet0) | 0;
michael@0 13361 i52 = tempRet0;
michael@0 13362 i39 = 0;
michael@0 13363 if (!((i52 | 0) > (i39 | 0) | (i52 | 0) == (i39 | 0) & i47 >>> 0 > 0 >>> 0)) {
michael@0 13364 i61 = i59;
michael@0 13365 break L958;
michael@0 13366 }
michael@0 13367 }
michael@0 13368 } while (0);
michael@0 13369 HEAP32[i8 >> 2] = i19;
michael@0 13370 i61 = i19;
michael@0 13371 } else {
michael@0 13372 i61 = i59;
michael@0 13373 }
michael@0 13374 } while (0);
michael@0 13375 i36 = HEAP32[i19 >> 2] | 0;
michael@0 13376 if ((i36 | 0) == (i55 | 0)) {
michael@0 13377 i60 = i61;
michael@0 13378 break;
michael@0 13379 } else {
michael@0 13380 i19 = i36;
michael@0 13381 i59 = i61;
michael@0 13382 }
michael@0 13383 }
michael@0 13384 }
michael@0 13385 do {
michael@0 13386 if ((i35 | 0) == 0 & (i60 | 0) == 0) {
michael@0 13387 i62 = i16;
michael@0 13388 i63 = i3;
michael@0 13389 } else {
michael@0 13390 __ZN20btConvexHullInternal24findEdgeForCoplanarFacesEPNS_6VertexES1_RPNS_4EdgeES4_S1_S1_(i1, i16, i3, i7, i8, 0, 0);
michael@0 13391 i61 = HEAP32[i7 >> 2] | 0;
michael@0 13392 if ((i61 | 0) == 0) {
michael@0 13393 i64 = i16;
michael@0 13394 } else {
michael@0 13395 i59 = HEAP32[i61 + 12 >> 2] | 0;
michael@0 13396 HEAP32[i5 >> 2] = i59;
michael@0 13397 i64 = i59;
michael@0 13398 }
michael@0 13399 i59 = HEAP32[i8 >> 2] | 0;
michael@0 13400 if ((i59 | 0) == 0) {
michael@0 13401 i62 = i64;
michael@0 13402 i63 = i3;
michael@0 13403 break;
michael@0 13404 }
michael@0 13405 i61 = HEAP32[i59 + 12 >> 2] | 0;
michael@0 13406 HEAP32[i6 >> 2] = i61;
michael@0 13407 i62 = i64;
michael@0 13408 i63 = i61;
michael@0 13409 }
michael@0 13410 } while (0);
michael@0 13411 i65 = HEAP32[i63 + 88 >> 2] | 0;
michael@0 13412 i66 = (HEAP32[i63 + 96 >> 2] | 0) + 1 | 0;
michael@0 13413 i67 = i62;
michael@0 13414 i68 = i63;
michael@0 13415 } else {
michael@0 13416 i65 = (HEAP32[i3 + 88 >> 2] | 0) + 1 | 0;
michael@0 13417 i66 = HEAP32[i3 + 96 >> 2] | 0;
michael@0 13418 i67 = HEAP32[i5 >> 2] | 0;
michael@0 13419 i68 = i3;
michael@0 13420 }
michael@0 13421 i3 = HEAP32[i68 + 92 >> 2] | 0;
michael@0 13422 i63 = i9 | 0;
michael@0 13423 i62 = i9 + 4 | 0;
michael@0 13424 i64 = i9 + 8 | 0;
michael@0 13425 i8 = i9 + 12 | 0;
michael@0 13426 i16 = i10 | 0;
michael@0 13427 i7 = i10 + 8 | 0;
michael@0 13428 i60 = i10 + 16 | 0;
michael@0 13429 i35 = i11 | 0;
michael@0 13430 i61 = i11 + 8 | 0;
michael@0 13431 i59 = i11 + 16 | 0;
michael@0 13432 i19 = i12 + 16 | 0;
michael@0 13433 i55 = i12 + 8 | 0;
michael@0 13434 i29 = i13 + 16 | 0;
michael@0 13435 i28 = i13 + 8 | 0;
michael@0 13436 i27 = i1 + 48 | 0;
michael@0 13437 i26 = i1 + 116 | 0;
michael@0 13438 i33 = i1 + 120 | 0;
michael@0 13439 i34 = i1 + 56 | 0;
michael@0 13440 i30 = i12;
michael@0 13441 i32 = i13;
michael@0 13442 i25 = 0;
michael@0 13443 i31 = 0;
michael@0 13444 i23 = 0;
michael@0 13445 i37 = 0;
michael@0 13446 i38 = 1;
michael@0 13447 i20 = 0;
michael@0 13448 i2 = 0;
michael@0 13449 i36 = 0;
michael@0 13450 i21 = 0;
michael@0 13451 i46 = i65;
michael@0 13452 i65 = i3;
michael@0 13453 i22 = i66;
michael@0 13454 i66 = i68;
michael@0 13455 i42 = i67;
michael@0 13456 i40 = i3;
michael@0 13457 while (1) {
michael@0 13458 i3 = i42 + 88 | 0;
michael@0 13459 i24 = (HEAP32[i66 + 88 >> 2] | 0) - (HEAP32[i3 >> 2] | 0) | 0;
michael@0 13460 i41 = i42 + 92 | 0;
michael@0 13461 i45 = i40 - (HEAP32[i41 >> 2] | 0) | 0;
michael@0 13462 i18 = i42 + 96 | 0;
michael@0 13463 i44 = (HEAP32[i66 + 96 >> 2] | 0) - (HEAP32[i18 >> 2] | 0) | 0;
michael@0 13464 HEAP32[i63 >> 2] = i24;
michael@0 13465 HEAP32[i62 >> 2] = i45;
michael@0 13466 HEAP32[i64 >> 2] = i44;
michael@0 13467 HEAP32[i8 >> 2] = -1;
michael@0 13468 i47 = i46 - (HEAP32[i3 >> 2] | 0) | 0;
michael@0 13469 i3 = i65 - (HEAP32[i41 >> 2] | 0) | 0;
michael@0 13470 i41 = i22 - (HEAP32[i18 >> 2] | 0) | 0;
michael@0 13471 i18 = Math_imul(i3, i44) | 0;
michael@0 13472 i39 = i18 - (Math_imul(i41, i45) | 0) | 0;
michael@0 13473 i18 = i39;
michael@0 13474 i52 = (i39 | 0) < 0 ? -1 : 0;
michael@0 13475 i39 = Math_imul(i41, i24) | 0;
michael@0 13476 i41 = i39 - (Math_imul(i47, i44) | 0) | 0;
michael@0 13477 i39 = i41;
michael@0 13478 i50 = (i41 | 0) < 0 ? -1 : 0;
michael@0 13479 i41 = Math_imul(i47, i45) | 0;
michael@0 13480 i47 = i41 - (Math_imul(i3, i24) | 0) | 0;
michael@0 13481 i3 = i47;
michael@0 13482 i41 = (i47 | 0) < 0 ? -1 : 0;
michael@0 13483 HEAP32[i16 >> 2] = i18;
michael@0 13484 HEAP32[i16 + 4 >> 2] = i52;
michael@0 13485 HEAP32[i7 >> 2] = i39;
michael@0 13486 HEAP32[i7 + 4 >> 2] = i50;
michael@0 13487 HEAP32[i60 >> 2] = i3;
michael@0 13488 HEAP32[i60 + 4 >> 2] = i41;
michael@0 13489 i47 = i45;
michael@0 13490 i43 = (i45 | 0) < 0 ? -1 : 0;
michael@0 13491 i45 = ___muldi3(i3, i41, i47, i43) | 0;
michael@0 13492 i48 = tempRet0;
michael@0 13493 i54 = i44;
michael@0 13494 i58 = (i44 | 0) < 0 ? -1 : 0;
michael@0 13495 i44 = ___muldi3(i39, i50, i54, i58) | 0;
michael@0 13496 i53 = _i64Subtract(i45, i48, i44, tempRet0) | 0;
michael@0 13497 i44 = tempRet0;
michael@0 13498 i48 = ___muldi3(i18, i52, i54, i58) | 0;
michael@0 13499 i58 = tempRet0;
michael@0 13500 i54 = i24;
michael@0 13501 i45 = (i24 | 0) < 0 ? -1 : 0;
michael@0 13502 i24 = ___muldi3(i3, i41, i54, i45) | 0;
michael@0 13503 i41 = _i64Subtract(i48, i58, i24, tempRet0) | 0;
michael@0 13504 i24 = tempRet0;
michael@0 13505 i58 = ___muldi3(i39, i50, i54, i45) | 0;
michael@0 13506 i45 = tempRet0;
michael@0 13507 i54 = ___muldi3(i18, i52, i47, i43) | 0;
michael@0 13508 i43 = _i64Subtract(i58, i45, i54, tempRet0) | 0;
michael@0 13509 HEAP32[i35 >> 2] = i53;
michael@0 13510 HEAP32[i35 + 4 >> 2] = i44;
michael@0 13511 HEAP32[i61 >> 2] = i41;
michael@0 13512 HEAP32[i61 + 4 >> 2] = i24;
michael@0 13513 HEAP32[i59 >> 2] = i43;
michael@0 13514 HEAP32[i59 + 4 >> 2] = tempRet0;
michael@0 13515 _memset(i30 | 0, 0, 20);
michael@0 13516 i43 = __ZN20btConvexHullInternal12findMaxAngleEbPKNS_6VertexERKNS_7Point32ERKNS_7Point64ES8_RNS_10Rational64E(i1, 0, i42, i9, i10, i11, i12) | 0;
michael@0 13517 _memset(i32 | 0, 0, 20);
michael@0 13518 i69 = HEAP32[i6 >> 2] | 0;
michael@0 13519 i24 = __ZN20btConvexHullInternal12findMaxAngleEbPKNS_6VertexERKNS_7Point32ERKNS_7Point64ES8_RNS_10Rational64E(i1, 1, i69, i9, i10, i11, i13) | 0;
michael@0 13520 i41 = (i43 | 0) != 0;
michael@0 13521 i44 = i41 ^ 1;
michael@0 13522 i53 = (i24 | 0) == 0;
michael@0 13523 if (i53 & i44) {
michael@0 13524 i70 = 753;
michael@0 13525 break;
michael@0 13526 }
michael@0 13527 if (i53 | i44) {
michael@0 13528 i71 = i41 ? -1 : 1;
michael@0 13529 } else {
michael@0 13530 i71 = __ZNK20btConvexHullInternal10Rational647compareERKS0_(i12, i13) | 0;
michael@0 13531 }
michael@0 13532 do {
michael@0 13533 if (i38) {
michael@0 13534 i70 = 765;
michael@0 13535 } else {
michael@0 13536 if ((i71 | 0) > -1) {
michael@0 13537 if ((HEAP32[i29 >> 2] | 0) >= 0) {
michael@0 13538 i70 = 765;
michael@0 13539 break;
michael@0 13540 }
michael@0 13541 if ((HEAP32[i28 >> 2] | 0) == 0 & (HEAP32[i28 + 4 >> 2] | 0) == 0) {
michael@0 13542 i72 = i23;
michael@0 13543 i73 = i37;
michael@0 13544 i74 = i36;
michael@0 13545 i75 = i21;
michael@0 13546 i70 = 772;
michael@0 13547 break;
michael@0 13548 } else {
michael@0 13549 i70 = 765;
michael@0 13550 break;
michael@0 13551 }
michael@0 13552 }
michael@0 13553 if ((HEAP32[i19 >> 2] | 0) >= 0) {
michael@0 13554 i70 = 765;
michael@0 13555 break;
michael@0 13556 }
michael@0 13557 if (!((HEAP32[i55 >> 2] | 0) == 0 & (HEAP32[i55 + 4 >> 2] | 0) == 0)) {
michael@0 13558 i70 = 765;
michael@0 13559 break;
michael@0 13560 }
michael@0 13561 HEAP32[i14 >> 2] = i43;
michael@0 13562 HEAP32[i15 >> 2] = i24;
michael@0 13563 i76 = i22;
michael@0 13564 i77 = i65;
michael@0 13565 i78 = i46;
michael@0 13566 i79 = i21;
michael@0 13567 i80 = i36;
michael@0 13568 i81 = i2;
michael@0 13569 i82 = i20;
michael@0 13570 i83 = i43;
michael@0 13571 i84 = i37;
michael@0 13572 i85 = i23;
michael@0 13573 i70 = 794;
michael@0 13574 }
michael@0 13575 } while (0);
michael@0 13576 if ((i70 | 0) == 765) {
michael@0 13577 i70 = 0;
michael@0 13578 i41 = HEAP32[i5 >> 2] | 0;
michael@0 13579 i44 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i27) | 0;
michael@0 13580 i53 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i27) | 0;
michael@0 13581 i54 = i44 + 8 | 0;
michael@0 13582 HEAP32[i54 >> 2] = i53;
michael@0 13583 HEAP32[i53 + 8 >> 2] = i44;
michael@0 13584 HEAP32[i44 + 20 >> 2] = HEAP32[i17 >> 2];
michael@0 13585 HEAP32[i53 + 20 >> 2] = HEAP32[i17 >> 2];
michael@0 13586 HEAP32[i44 + 12 >> 2] = i69;
michael@0 13587 HEAP32[i53 + 12 >> 2] = i41;
michael@0 13588 HEAP32[i44 + 16 >> 2] = 0;
michael@0 13589 HEAP32[i53 + 16 >> 2] = 0;
michael@0 13590 i53 = (HEAP32[i26 >> 2] | 0) + 1 | 0;
michael@0 13591 HEAP32[i26 >> 2] = i53;
michael@0 13592 if ((i53 | 0) > (HEAP32[i33 >> 2] | 0)) {
michael@0 13593 HEAP32[i33 >> 2] = i53;
michael@0 13594 }
michael@0 13595 if ((i37 | 0) == 0) {
michael@0 13596 i86 = i44;
michael@0 13597 } else {
michael@0 13598 HEAP32[i37 + 4 >> 2] = i44;
michael@0 13599 i86 = i23;
michael@0 13600 }
michael@0 13601 HEAP32[i44 >> 2] = i37;
michael@0 13602 i53 = HEAP32[i54 >> 2] | 0;
michael@0 13603 if ((i21 | 0) == 0) {
michael@0 13604 i87 = i53;
michael@0 13605 } else {
michael@0 13606 HEAP32[i21 >> 2] = i53;
michael@0 13607 i87 = i36;
michael@0 13608 }
michael@0 13609 HEAP32[i53 + 4 >> 2] = i21;
michael@0 13610 i72 = i86;
michael@0 13611 i73 = i44;
michael@0 13612 i74 = i87;
michael@0 13613 i75 = i53;
michael@0 13614 i70 = 772;
michael@0 13615 }
michael@0 13616 do {
michael@0 13617 if ((i70 | 0) == 772) {
michael@0 13618 i70 = 0;
michael@0 13619 HEAP32[i14 >> 2] = i43;
michael@0 13620 HEAP32[i15 >> 2] = i24;
michael@0 13621 if ((i71 | 0) == 0) {
michael@0 13622 __ZN20btConvexHullInternal24findEdgeForCoplanarFacesEPNS_6VertexES1_RPNS_4EdgeES4_S1_S1_(i1, HEAP32[i5 >> 2] | 0, HEAP32[i6 >> 2] | 0, i14, i15, 0, 0);
michael@0 13623 i88 = HEAP32[i15 >> 2] | 0;
michael@0 13624 } else {
michael@0 13625 if ((i71 | 0) > -1) {
michael@0 13626 i88 = i24;
michael@0 13627 } else {
michael@0 13628 i76 = i22;
michael@0 13629 i77 = i65;
michael@0 13630 i78 = i46;
michael@0 13631 i79 = i75;
michael@0 13632 i80 = i74;
michael@0 13633 i81 = i2;
michael@0 13634 i82 = i20;
michael@0 13635 i83 = i43;
michael@0 13636 i84 = i73;
michael@0 13637 i85 = i72;
michael@0 13638 i70 = 794;
michael@0 13639 break;
michael@0 13640 }
michael@0 13641 }
michael@0 13642 if ((i88 | 0) == 0) {
michael@0 13643 i89 = i20;
michael@0 13644 i90 = i2;
michael@0 13645 i91 = i74;
michael@0 13646 i92 = i75;
michael@0 13647 i93 = i46;
michael@0 13648 i94 = i65;
michael@0 13649 i95 = i22;
michael@0 13650 } else {
michael@0 13651 i53 = (i20 | 0) != 0;
michael@0 13652 do {
michael@0 13653 if (i53) {
michael@0 13654 i44 = HEAP32[i20 >> 2] | 0;
michael@0 13655 if ((i44 | 0) == (i24 | 0)) {
michael@0 13656 break;
michael@0 13657 } else {
michael@0 13658 i96 = i44;
michael@0 13659 }
michael@0 13660 while (1) {
michael@0 13661 i44 = i96 | 0;
michael@0 13662 i54 = HEAP32[i44 >> 2] | 0;
michael@0 13663 i41 = HEAP32[i96 + 8 >> 2] | 0;
michael@0 13664 if ((i54 | 0) == (i96 | 0)) {
michael@0 13665 HEAP32[(HEAP32[i41 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13666 } else {
michael@0 13667 i45 = i96 + 4 | 0;
michael@0 13668 HEAP32[i54 + 4 >> 2] = HEAP32[i45 >> 2];
michael@0 13669 HEAP32[HEAP32[i45 >> 2] >> 2] = i54;
michael@0 13670 HEAP32[(HEAP32[i41 + 12 >> 2] | 0) + 8 >> 2] = i54;
michael@0 13671 }
michael@0 13672 i45 = i41 | 0;
michael@0 13673 i58 = HEAP32[i45 >> 2] | 0;
michael@0 13674 if ((i58 | 0) == (i41 | 0)) {
michael@0 13675 HEAP32[(HEAP32[i96 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13676 } else {
michael@0 13677 i47 = i41 + 4 | 0;
michael@0 13678 HEAP32[i58 + 4 >> 2] = HEAP32[i47 >> 2];
michael@0 13679 HEAP32[HEAP32[i47 >> 2] >> 2] = i58;
michael@0 13680 HEAP32[(HEAP32[i96 + 12 >> 2] | 0) + 8 >> 2] = i58;
michael@0 13681 }
michael@0 13682 _memset(i96 | 0, 0, 20);
michael@0 13683 HEAP32[i44 >> 2] = HEAP32[i34 >> 2];
michael@0 13684 HEAP32[i34 >> 2] = i96;
michael@0 13685 _memset(i41 | 0, 0, 20);
michael@0 13686 HEAP32[i45 >> 2] = HEAP32[i34 >> 2];
michael@0 13687 HEAP32[i34 >> 2] = i41;
michael@0 13688 HEAP32[i26 >> 2] = (HEAP32[i26 >> 2] | 0) - 1;
michael@0 13689 if ((i54 | 0) == (i24 | 0)) {
michael@0 13690 break;
michael@0 13691 } else {
michael@0 13692 i96 = i54;
michael@0 13693 }
michael@0 13694 }
michael@0 13695 }
michael@0 13696 } while (0);
michael@0 13697 if ((i75 | 0) == 0) {
michael@0 13698 i97 = i53 ? i2 : i24;
michael@0 13699 i98 = i74;
michael@0 13700 i99 = i88;
michael@0 13701 } else {
michael@0 13702 if (i53) {
michael@0 13703 HEAP32[i20 >> 2] = i74;
michael@0 13704 HEAP32[i74 + 4 >> 2] = i20;
michael@0 13705 i100 = i2;
michael@0 13706 i101 = i24 + 4 | 0;
michael@0 13707 } else {
michael@0 13708 i54 = i24 + 4 | 0;
michael@0 13709 i41 = HEAP32[i54 >> 2] | 0;
michael@0 13710 HEAP32[i41 >> 2] = i74;
michael@0 13711 HEAP32[i74 + 4 >> 2] = i41;
michael@0 13712 i100 = i74;
michael@0 13713 i101 = i54;
michael@0 13714 }
michael@0 13715 HEAP32[i75 >> 2] = i24;
michael@0 13716 HEAP32[i101 >> 2] = i75;
michael@0 13717 i97 = i100;
michael@0 13718 i98 = 0;
michael@0 13719 i99 = HEAP32[i15 >> 2] | 0;
michael@0 13720 }
michael@0 13721 i54 = HEAP32[i6 >> 2] | 0;
michael@0 13722 i41 = HEAP32[i54 + 88 >> 2] | 0;
michael@0 13723 i45 = HEAP32[i54 + 92 >> 2] | 0;
michael@0 13724 i44 = HEAP32[i54 + 96 >> 2] | 0;
michael@0 13725 HEAP32[i6 >> 2] = HEAP32[i99 + 12 >> 2];
michael@0 13726 i89 = HEAP32[i99 + 8 >> 2] | 0;
michael@0 13727 i90 = i97;
michael@0 13728 i91 = i98;
michael@0 13729 i92 = 0;
michael@0 13730 i93 = i41;
michael@0 13731 i94 = i45;
michael@0 13732 i95 = i44;
michael@0 13733 }
michael@0 13734 if ((i71 | 0) >= 1) {
michael@0 13735 i102 = i25;
michael@0 13736 i103 = i31;
michael@0 13737 i104 = i72;
michael@0 13738 i105 = i73;
michael@0 13739 i106 = i93;
michael@0 13740 i107 = i94;
michael@0 13741 i108 = i95;
michael@0 13742 i109 = i92;
michael@0 13743 i110 = i91;
michael@0 13744 i111 = i90;
michael@0 13745 i112 = i89;
michael@0 13746 break;
michael@0 13747 }
michael@0 13748 i76 = i95;
michael@0 13749 i77 = i94;
michael@0 13750 i78 = i93;
michael@0 13751 i79 = i92;
michael@0 13752 i80 = i91;
michael@0 13753 i81 = i90;
michael@0 13754 i82 = i89;
michael@0 13755 i83 = HEAP32[i14 >> 2] | 0;
michael@0 13756 i84 = i73;
michael@0 13757 i85 = i72;
michael@0 13758 i70 = 794;
michael@0 13759 }
michael@0 13760 } while (0);
michael@0 13761 do {
michael@0 13762 if ((i70 | 0) == 794) {
michael@0 13763 i70 = 0;
michael@0 13764 if ((i83 | 0) == 0) {
michael@0 13765 i102 = i25;
michael@0 13766 i103 = i31;
michael@0 13767 i104 = i85;
michael@0 13768 i105 = i84;
michael@0 13769 i106 = i78;
michael@0 13770 i107 = i77;
michael@0 13771 i108 = i76;
michael@0 13772 i109 = i79;
michael@0 13773 i110 = i80;
michael@0 13774 i111 = i81;
michael@0 13775 i112 = i82;
michael@0 13776 break;
michael@0 13777 }
michael@0 13778 i24 = (i25 | 0) != 0;
michael@0 13779 do {
michael@0 13780 if (i24) {
michael@0 13781 i44 = HEAP32[i25 + 4 >> 2] | 0;
michael@0 13782 if ((i44 | 0) == (i43 | 0)) {
michael@0 13783 break;
michael@0 13784 } else {
michael@0 13785 i113 = i44;
michael@0 13786 }
michael@0 13787 while (1) {
michael@0 13788 i44 = i113 + 4 | 0;
michael@0 13789 i45 = HEAP32[i44 >> 2] | 0;
michael@0 13790 i41 = i113 | 0;
michael@0 13791 i54 = HEAP32[i41 >> 2] | 0;
michael@0 13792 i58 = HEAP32[i113 + 8 >> 2] | 0;
michael@0 13793 if ((i54 | 0) == (i113 | 0)) {
michael@0 13794 HEAP32[(HEAP32[i58 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13795 } else {
michael@0 13796 HEAP32[i54 + 4 >> 2] = i45;
michael@0 13797 HEAP32[HEAP32[i44 >> 2] >> 2] = i54;
michael@0 13798 HEAP32[(HEAP32[i58 + 12 >> 2] | 0) + 8 >> 2] = i54;
michael@0 13799 }
michael@0 13800 i54 = i58 | 0;
michael@0 13801 i44 = HEAP32[i54 >> 2] | 0;
michael@0 13802 if ((i44 | 0) == (i58 | 0)) {
michael@0 13803 HEAP32[(HEAP32[i113 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13804 } else {
michael@0 13805 i47 = i58 + 4 | 0;
michael@0 13806 HEAP32[i44 + 4 >> 2] = HEAP32[i47 >> 2];
michael@0 13807 HEAP32[HEAP32[i47 >> 2] >> 2] = i44;
michael@0 13808 HEAP32[(HEAP32[i113 + 12 >> 2] | 0) + 8 >> 2] = i44;
michael@0 13809 }
michael@0 13810 _memset(i113 | 0, 0, 20);
michael@0 13811 HEAP32[i41 >> 2] = HEAP32[i34 >> 2];
michael@0 13812 HEAP32[i34 >> 2] = i113;
michael@0 13813 _memset(i58 | 0, 0, 20);
michael@0 13814 HEAP32[i54 >> 2] = HEAP32[i34 >> 2];
michael@0 13815 HEAP32[i34 >> 2] = i58;
michael@0 13816 HEAP32[i26 >> 2] = (HEAP32[i26 >> 2] | 0) - 1;
michael@0 13817 if ((i45 | 0) == (i43 | 0)) {
michael@0 13818 break;
michael@0 13819 } else {
michael@0 13820 i113 = i45;
michael@0 13821 }
michael@0 13822 }
michael@0 13823 }
michael@0 13824 } while (0);
michael@0 13825 if ((i84 | 0) == 0) {
michael@0 13826 i114 = i24 ? i31 : i43;
michael@0 13827 i115 = i85;
michael@0 13828 i116 = i83;
michael@0 13829 } else {
michael@0 13830 if (i24) {
michael@0 13831 HEAP32[i85 >> 2] = i25;
michael@0 13832 HEAP32[i25 + 4 >> 2] = i85;
michael@0 13833 i117 = i31;
michael@0 13834 i118 = i43 | 0;
michael@0 13835 } else {
michael@0 13836 i53 = i43 | 0;
michael@0 13837 i45 = HEAP32[i53 >> 2] | 0;
michael@0 13838 HEAP32[i85 >> 2] = i45;
michael@0 13839 HEAP32[i45 + 4 >> 2] = i85;
michael@0 13840 i117 = i85;
michael@0 13841 i118 = i53;
michael@0 13842 }
michael@0 13843 HEAP32[i118 >> 2] = i84;
michael@0 13844 HEAP32[i84 + 4 >> 2] = i43;
michael@0 13845 i114 = i117;
michael@0 13846 i115 = 0;
michael@0 13847 i116 = HEAP32[i14 >> 2] | 0;
michael@0 13848 }
michael@0 13849 i53 = HEAP32[i5 >> 2] | 0;
michael@0 13850 i45 = HEAP32[i53 + 88 >> 2] | 0;
michael@0 13851 i58 = HEAP32[i53 + 92 >> 2] | 0;
michael@0 13852 i54 = HEAP32[i53 + 96 >> 2] | 0;
michael@0 13853 HEAP32[i5 >> 2] = HEAP32[i116 + 12 >> 2];
michael@0 13854 i102 = HEAP32[i116 + 8 >> 2] | 0;
michael@0 13855 i103 = i114;
michael@0 13856 i104 = i115;
michael@0 13857 i105 = 0;
michael@0 13858 i106 = i45;
michael@0 13859 i107 = i58;
michael@0 13860 i108 = i54;
michael@0 13861 i109 = i79;
michael@0 13862 i110 = i80;
michael@0 13863 i111 = i81;
michael@0 13864 i112 = i82;
michael@0 13865 }
michael@0 13866 } while (0);
michael@0 13867 i43 = HEAP32[i5 >> 2] | 0;
michael@0 13868 i54 = HEAP32[i6 >> 2] | 0;
michael@0 13869 if ((i43 | 0) == (i67 | 0) & (i54 | 0) == (i68 | 0)) {
michael@0 13870 break;
michael@0 13871 }
michael@0 13872 i25 = i102;
michael@0 13873 i31 = i103;
michael@0 13874 i23 = i104;
michael@0 13875 i37 = i105;
michael@0 13876 i38 = 0;
michael@0 13877 i20 = i112;
michael@0 13878 i2 = i111;
michael@0 13879 i36 = i110;
michael@0 13880 i21 = i109;
michael@0 13881 i46 = i106;
michael@0 13882 i65 = i107;
michael@0 13883 i22 = i108;
michael@0 13884 i66 = i54;
michael@0 13885 i42 = i43;
michael@0 13886 i40 = HEAP32[i54 + 92 >> 2] | 0;
michael@0 13887 }
michael@0 13888 if ((i70 | 0) == 753) {
michael@0 13889 i70 = HEAP32[i5 >> 2] | 0;
michael@0 13890 i40 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i27) | 0;
michael@0 13891 i42 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i27) | 0;
michael@0 13892 i27 = i40 + 8 | 0;
michael@0 13893 HEAP32[i27 >> 2] = i42;
michael@0 13894 HEAP32[i42 + 8 >> 2] = i40;
michael@0 13895 HEAP32[i40 + 20 >> 2] = HEAP32[i17 >> 2];
michael@0 13896 HEAP32[i42 + 20 >> 2] = HEAP32[i17 >> 2];
michael@0 13897 HEAP32[i40 + 12 >> 2] = i69;
michael@0 13898 HEAP32[i42 + 12 >> 2] = i70;
michael@0 13899 HEAP32[i40 + 16 >> 2] = 0;
michael@0 13900 HEAP32[i42 + 16 >> 2] = 0;
michael@0 13901 i42 = (HEAP32[i26 >> 2] | 0) + 1 | 0;
michael@0 13902 HEAP32[i26 >> 2] = i42;
michael@0 13903 if ((i42 | 0) > (HEAP32[i33 >> 2] | 0)) {
michael@0 13904 HEAP32[i33 >> 2] = i42;
michael@0 13905 }
michael@0 13906 HEAP32[i40 >> 2] = i40;
michael@0 13907 HEAP32[i40 + 4 >> 2] = i40;
michael@0 13908 HEAP32[i70 + 8 >> 2] = i40;
michael@0 13909 i40 = HEAP32[i27 >> 2] | 0;
michael@0 13910 HEAP32[i40 >> 2] = i40;
michael@0 13911 HEAP32[i40 + 4 >> 2] = i40;
michael@0 13912 HEAP32[i69 + 8 >> 2] = i40;
michael@0 13913 STACKTOP = i4;
michael@0 13914 return;
michael@0 13915 }
michael@0 13916 do {
michael@0 13917 if ((i102 | 0) == 0) {
michael@0 13918 HEAP32[i104 >> 2] = i105;
michael@0 13919 HEAP32[i105 + 4 >> 2] = i104;
michael@0 13920 HEAP32[(HEAP32[i5 >> 2] | 0) + 8 >> 2] = i105;
michael@0 13921 } else {
michael@0 13922 i40 = i102 + 4 | 0;
michael@0 13923 i69 = HEAP32[i40 >> 2] | 0;
michael@0 13924 if ((i69 | 0) != (i103 | 0)) {
michael@0 13925 i27 = i69;
michael@0 13926 while (1) {
michael@0 13927 i69 = i27 + 4 | 0;
michael@0 13928 i70 = HEAP32[i69 >> 2] | 0;
michael@0 13929 i42 = i27 | 0;
michael@0 13930 i33 = HEAP32[i42 >> 2] | 0;
michael@0 13931 i17 = HEAP32[i27 + 8 >> 2] | 0;
michael@0 13932 if ((i33 | 0) == (i27 | 0)) {
michael@0 13933 HEAP32[(HEAP32[i17 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13934 } else {
michael@0 13935 HEAP32[i33 + 4 >> 2] = i70;
michael@0 13936 HEAP32[HEAP32[i69 >> 2] >> 2] = i33;
michael@0 13937 HEAP32[(HEAP32[i17 + 12 >> 2] | 0) + 8 >> 2] = i33;
michael@0 13938 }
michael@0 13939 i33 = i17 | 0;
michael@0 13940 i69 = HEAP32[i33 >> 2] | 0;
michael@0 13941 if ((i69 | 0) == (i17 | 0)) {
michael@0 13942 HEAP32[(HEAP32[i27 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13943 } else {
michael@0 13944 i66 = i17 + 4 | 0;
michael@0 13945 HEAP32[i69 + 4 >> 2] = HEAP32[i66 >> 2];
michael@0 13946 HEAP32[HEAP32[i66 >> 2] >> 2] = i69;
michael@0 13947 HEAP32[(HEAP32[i27 + 12 >> 2] | 0) + 8 >> 2] = i69;
michael@0 13948 }
michael@0 13949 _memset(i27 | 0, 0, 20);
michael@0 13950 HEAP32[i42 >> 2] = HEAP32[i34 >> 2];
michael@0 13951 HEAP32[i34 >> 2] = i27;
michael@0 13952 _memset(i17 | 0, 0, 20);
michael@0 13953 HEAP32[i33 >> 2] = HEAP32[i34 >> 2];
michael@0 13954 HEAP32[i34 >> 2] = i17;
michael@0 13955 HEAP32[i26 >> 2] = (HEAP32[i26 >> 2] | 0) - 1;
michael@0 13956 if ((i70 | 0) == (i103 | 0)) {
michael@0 13957 break;
michael@0 13958 } else {
michael@0 13959 i27 = i70;
michael@0 13960 }
michael@0 13961 }
michael@0 13962 }
michael@0 13963 if ((i105 | 0) == 0) {
michael@0 13964 break;
michael@0 13965 }
michael@0 13966 HEAP32[i104 >> 2] = i102;
michael@0 13967 HEAP32[i40 >> 2] = i104;
michael@0 13968 HEAP32[i103 >> 2] = i105;
michael@0 13969 HEAP32[i105 + 4 >> 2] = i103;
michael@0 13970 }
michael@0 13971 } while (0);
michael@0 13972 if ((i112 | 0) == 0) {
michael@0 13973 HEAP32[i109 >> 2] = i110;
michael@0 13974 HEAP32[i110 + 4 >> 2] = i109;
michael@0 13975 HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] = i109;
michael@0 13976 STACKTOP = i4;
michael@0 13977 return;
michael@0 13978 }
michael@0 13979 i6 = i112 | 0;
michael@0 13980 i103 = HEAP32[i6 >> 2] | 0;
michael@0 13981 if ((i103 | 0) != (i111 | 0)) {
michael@0 13982 i105 = i103;
michael@0 13983 while (1) {
michael@0 13984 i103 = i105 | 0;
michael@0 13985 i104 = HEAP32[i103 >> 2] | 0;
michael@0 13986 i102 = HEAP32[i105 + 8 >> 2] | 0;
michael@0 13987 if ((i104 | 0) == (i105 | 0)) {
michael@0 13988 HEAP32[(HEAP32[i102 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13989 } else {
michael@0 13990 i5 = i105 + 4 | 0;
michael@0 13991 HEAP32[i104 + 4 >> 2] = HEAP32[i5 >> 2];
michael@0 13992 HEAP32[HEAP32[i5 >> 2] >> 2] = i104;
michael@0 13993 HEAP32[(HEAP32[i102 + 12 >> 2] | 0) + 8 >> 2] = i104;
michael@0 13994 }
michael@0 13995 i5 = i102 | 0;
michael@0 13996 i27 = HEAP32[i5 >> 2] | 0;
michael@0 13997 if ((i27 | 0) == (i102 | 0)) {
michael@0 13998 HEAP32[(HEAP32[i105 + 12 >> 2] | 0) + 8 >> 2] = 0;
michael@0 13999 } else {
michael@0 14000 i70 = i102 + 4 | 0;
michael@0 14001 HEAP32[i27 + 4 >> 2] = HEAP32[i70 >> 2];
michael@0 14002 HEAP32[HEAP32[i70 >> 2] >> 2] = i27;
michael@0 14003 HEAP32[(HEAP32[i105 + 12 >> 2] | 0) + 8 >> 2] = i27;
michael@0 14004 }
michael@0 14005 _memset(i105 | 0, 0, 20);
michael@0 14006 HEAP32[i103 >> 2] = HEAP32[i34 >> 2];
michael@0 14007 HEAP32[i34 >> 2] = i105;
michael@0 14008 _memset(i102 | 0, 0, 20);
michael@0 14009 HEAP32[i5 >> 2] = HEAP32[i34 >> 2];
michael@0 14010 HEAP32[i34 >> 2] = i102;
michael@0 14011 HEAP32[i26 >> 2] = (HEAP32[i26 >> 2] | 0) - 1;
michael@0 14012 if ((i104 | 0) == (i111 | 0)) {
michael@0 14013 break;
michael@0 14014 } else {
michael@0 14015 i105 = i104;
michael@0 14016 }
michael@0 14017 }
michael@0 14018 }
michael@0 14019 if ((i109 | 0) == 0) {
michael@0 14020 STACKTOP = i4;
michael@0 14021 return;
michael@0 14022 }
michael@0 14023 HEAP32[i6 >> 2] = i110;
michael@0 14024 HEAP32[i110 + 4 >> 2] = i112;
michael@0 14025 HEAP32[i109 >> 2] = i111;
michael@0 14026 HEAP32[i111 + 4 >> 2] = i109;
michael@0 14027 STACKTOP = i4;
michael@0 14028 return;
michael@0 14029 }
michael@0 14030 function __ZN17btGjkPairDetector26getClosestPointsNonVirtualERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDraw(i1, i2, i3, i4) {
michael@0 14031 i1 = i1 | 0;
michael@0 14032 i2 = i2 | 0;
michael@0 14033 i3 = i3 | 0;
michael@0 14034 i4 = i4 | 0;
michael@0 14035 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, i37 = 0, d38 = 0.0, i39 = 0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, i45 = 0, d46 = 0.0, i47 = 0, d48 = 0.0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0, i88 = 0, i89 = 0, i90 = 0, i91 = 0, i92 = 0, i93 = 0, i94 = 0, i95 = 0, i96 = 0, i97 = 0, i98 = 0, i99 = 0, i100 = 0, i101 = 0, i102 = 0, i103 = 0, i104 = 0, i105 = 0, i106 = 0, i107 = 0, i108 = 0, i109 = 0, i110 = 0, i111 = 0, i112 = 0, i113 = 0, i114 = 0, i115 = 0, i116 = 0, i117 = 0, i118 = 0, i119 = 0, i120 = 0, i121 = 0, i122 = 0, i123 = 0, i124 = 0, i125 = 0, d126 = 0.0, d127 = 0.0, d128 = 0.0, d129 = 0.0, d130 = 0.0, d131 = 0.0, d132 = 0.0, d133 = 0.0, d134 = 0.0, d135 = 0.0, d136 = 0.0, d137 = 0.0, d138 = 0.0, d139 = 0.0, i140 = 0, d141 = 0.0, d142 = 0.0, d143 = 0.0, d144 = 0.0, d145 = 0.0, d146 = 0.0, i147 = 0, d148 = 0.0, i149 = 0, d150 = 0.0, d151 = 0.0, d152 = 0.0, d153 = 0.0, i154 = 0, d155 = 0.0, d156 = 0.0, d157 = 0.0, d158 = 0.0, d159 = 0.0, d160 = 0.0;
michael@0 14036 i5 = STACKTOP;
michael@0 14037 STACKTOP = STACKTOP + 352 | 0;
michael@0 14038 i6 = i5 | 0;
michael@0 14039 i7 = i5 + 16 | 0;
michael@0 14040 i8 = i5 + 32 | 0;
michael@0 14041 i9 = i5 + 48 | 0;
michael@0 14042 i10 = i5 + 112 | 0;
michael@0 14043 i11 = i5 + 176 | 0;
michael@0 14044 i12 = i5 + 192 | 0;
michael@0 14045 i13 = i5 + 208 | 0;
michael@0 14046 i14 = i5 + 224 | 0;
michael@0 14047 i15 = i5 + 240 | 0;
michael@0 14048 i16 = i5 + 256 | 0;
michael@0 14049 i17 = i5 + 272 | 0;
michael@0 14050 i18 = i5 + 288 | 0;
michael@0 14051 i19 = i5 + 304 | 0;
michael@0 14052 i20 = i5 + 320 | 0;
michael@0 14053 i21 = i5 + 336 | 0;
michael@0 14054 i22 = i1 + 56 | 0;
michael@0 14055 HEAPF32[i22 >> 2] = 0.0;
michael@0 14056 i23 = i6 | 0;
michael@0 14057 i24 = i6 + 4 | 0;
michael@0 14058 i25 = i6 + 8 | 0;
michael@0 14059 i26 = i6 + 12 | 0;
michael@0 14060 i27 = i9;
michael@0 14061 i28 = i2;
michael@0 14062 i29 = i6;
michael@0 14063 _memset(i29 | 0, 0, 16);
michael@0 14064 HEAP32[i27 >> 2] = HEAP32[i28 >> 2];
michael@0 14065 HEAP32[i27 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 14066 HEAP32[i27 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 14067 HEAP32[i27 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 14068 i28 = i9 + 16 | 0;
michael@0 14069 i27 = i2 + 16 | 0;
michael@0 14070 HEAP32[i28 >> 2] = HEAP32[i27 >> 2];
michael@0 14071 HEAP32[i28 + 4 >> 2] = HEAP32[i27 + 4 >> 2];
michael@0 14072 HEAP32[i28 + 8 >> 2] = HEAP32[i27 + 8 >> 2];
michael@0 14073 HEAP32[i28 + 12 >> 2] = HEAP32[i27 + 12 >> 2];
michael@0 14074 i27 = i9 + 32 | 0;
michael@0 14075 i28 = i2 + 32 | 0;
michael@0 14076 HEAP32[i27 >> 2] = HEAP32[i28 >> 2];
michael@0 14077 HEAP32[i27 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 14078 HEAP32[i27 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 14079 HEAP32[i27 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 14080 i28 = i9 + 48 | 0;
michael@0 14081 i27 = i28;
michael@0 14082 i30 = i2 + 48 | 0;
michael@0 14083 HEAP32[i27 >> 2] = HEAP32[i30 >> 2];
michael@0 14084 HEAP32[i27 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 14085 HEAP32[i27 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 14086 HEAP32[i27 + 12 >> 2] = HEAP32[i30 + 12 >> 2];
michael@0 14087 i30 = i2 + 64 | 0;
michael@0 14088 i27 = i10;
michael@0 14089 i31 = i30;
michael@0 14090 HEAP32[i27 >> 2] = HEAP32[i31 >> 2];
michael@0 14091 HEAP32[i27 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 14092 HEAP32[i27 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 14093 HEAP32[i27 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 14094 i31 = i10 + 16 | 0;
michael@0 14095 i27 = i2 + 80 | 0;
michael@0 14096 HEAP32[i31 >> 2] = HEAP32[i27 >> 2];
michael@0 14097 HEAP32[i31 + 4 >> 2] = HEAP32[i27 + 4 >> 2];
michael@0 14098 HEAP32[i31 + 8 >> 2] = HEAP32[i27 + 8 >> 2];
michael@0 14099 HEAP32[i31 + 12 >> 2] = HEAP32[i27 + 12 >> 2];
michael@0 14100 i27 = i10 + 32 | 0;
michael@0 14101 i31 = i2 + 96 | 0;
michael@0 14102 HEAP32[i27 >> 2] = HEAP32[i31 >> 2];
michael@0 14103 HEAP32[i27 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 14104 HEAP32[i27 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 14105 HEAP32[i27 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 14106 i31 = i10 + 48 | 0;
michael@0 14107 i27 = i31;
michael@0 14108 i32 = i2 + 112 | 0;
michael@0 14109 HEAP32[i27 >> 2] = HEAP32[i32 >> 2];
michael@0 14110 HEAP32[i27 + 4 >> 2] = HEAP32[i32 + 4 >> 2];
michael@0 14111 HEAP32[i27 + 8 >> 2] = HEAP32[i32 + 8 >> 2];
michael@0 14112 HEAP32[i27 + 12 >> 2] = HEAP32[i32 + 12 >> 2];
michael@0 14113 i32 = i28 | 0;
michael@0 14114 d33 = +HEAPF32[i32 >> 2];
michael@0 14115 i28 = i31 | 0;
michael@0 14116 d34 = +HEAPF32[i28 >> 2];
michael@0 14117 i31 = i9 + 52 | 0;
michael@0 14118 d35 = +HEAPF32[i31 >> 2];
michael@0 14119 i27 = i10 + 52 | 0;
michael@0 14120 d36 = +HEAPF32[i27 >> 2];
michael@0 14121 i37 = i9 + 56 | 0;
michael@0 14122 d38 = +HEAPF32[i37 >> 2];
michael@0 14123 i39 = i10 + 56 | 0;
michael@0 14124 d40 = +HEAPF32[i39 >> 2];
michael@0 14125 d41 = (d33 + d34) * .5;
michael@0 14126 d42 = (d35 + d36) * .5;
michael@0 14127 d43 = (d38 + d40) * .5;
michael@0 14128 d44 = d33 - d41;
michael@0 14129 HEAPF32[i32 >> 2] = d44;
michael@0 14130 d33 = d35 - d42;
michael@0 14131 HEAPF32[i31 >> 2] = d33;
michael@0 14132 d35 = d38 - d43;
michael@0 14133 HEAPF32[i37 >> 2] = d35;
michael@0 14134 d38 = d34 - d41;
michael@0 14135 HEAPF32[i28 >> 2] = d38;
michael@0 14136 d34 = d36 - d42;
michael@0 14137 HEAPF32[i27 >> 2] = d34;
michael@0 14138 d36 = d40 - d43;
michael@0 14139 HEAPF32[i39 >> 2] = d36;
michael@0 14140 i28 = i1 + 28 | 0;
michael@0 14141 i32 = i1 + 32 | 0;
michael@0 14142 if (((HEAP32[(HEAP32[i28 >> 2] | 0) + 4 >> 2] | 0) - 17 | 0) >>> 0 < 2) {
michael@0 14143 i45 = ((HEAP32[(HEAP32[i32 >> 2] | 0) + 4 >> 2] | 0) - 17 | 0) >>> 0 < 2;
michael@0 14144 } else {
michael@0 14145 i45 = 0;
michael@0 14146 }
michael@0 14147 d40 = +HEAPF32[i1 + 44 >> 2];
michael@0 14148 d46 = +HEAPF32[i1 + 48 >> 2];
michael@0 14149 HEAP32[2992] = (HEAP32[2992] | 0) + 1;
michael@0 14150 i47 = (HEAP8[i1 + 52 | 0] | 0) == 0;
michael@0 14151 d48 = i47 ? d40 : 0.0;
michael@0 14152 d40 = i47 ? d46 : 0.0;
michael@0 14153 i47 = i1 + 64 | 0;
michael@0 14154 HEAP32[i47 >> 2] = 0;
michael@0 14155 i49 = i1 + 4 | 0;
michael@0 14156 i50 = i49 | 0;
michael@0 14157 HEAPF32[i50 >> 2] = 0.0;
michael@0 14158 i51 = i1 + 8 | 0;
michael@0 14159 HEAPF32[i51 >> 2] = 1.0;
michael@0 14160 i52 = i1 + 12 | 0;
michael@0 14161 HEAPF32[i52 >> 2] = 0.0;
michael@0 14162 i53 = i1 + 16 | 0;
michael@0 14163 HEAPF32[i53 >> 2] = 0.0;
michael@0 14164 i54 = i1 + 68 | 0;
michael@0 14165 HEAP32[i54 >> 2] = 0;
michael@0 14166 i55 = i1 + 60 | 0;
michael@0 14167 HEAP32[i55 >> 2] = -1;
michael@0 14168 d46 = d48 + d40;
michael@0 14169 i56 = i1 + 24 | 0;
michael@0 14170 __ZN22btVoronoiSimplexSolver5resetEv(HEAP32[i56 >> 2] | 0);
michael@0 14171 i57 = i2 | 0;
michael@0 14172 i58 = i2 + 16 | 0;
michael@0 14173 i59 = i2 + 32 | 0;
michael@0 14174 i60 = i2 + 4 | 0;
michael@0 14175 i61 = i2 + 20 | 0;
michael@0 14176 i62 = i2 + 36 | 0;
michael@0 14177 i63 = i2 + 8 | 0;
michael@0 14178 i64 = i2 + 24 | 0;
michael@0 14179 i65 = i2 + 40 | 0;
michael@0 14180 i66 = i11 | 0;
michael@0 14181 i67 = i11 + 4 | 0;
michael@0 14182 i68 = i11 + 8 | 0;
michael@0 14183 i69 = i11 + 12 | 0;
michael@0 14184 i70 = i30 | 0;
michael@0 14185 i30 = i2 + 80 | 0;
michael@0 14186 i71 = i2 + 96 | 0;
michael@0 14187 i72 = i2 + 68 | 0;
michael@0 14188 i73 = i2 + 84 | 0;
michael@0 14189 i74 = i2 + 100 | 0;
michael@0 14190 i75 = i2 + 72 | 0;
michael@0 14191 i76 = i2 + 88 | 0;
michael@0 14192 i77 = i2 + 104 | 0;
michael@0 14193 i78 = i12 | 0;
michael@0 14194 i79 = i12 + 4 | 0;
michael@0 14195 i80 = i12 + 8 | 0;
michael@0 14196 i81 = i12 + 12 | 0;
michael@0 14197 i82 = i9 | 0;
michael@0 14198 i83 = i13 | 0;
michael@0 14199 i84 = i9 + 4 | 0;
michael@0 14200 i85 = i13 + 4 | 0;
michael@0 14201 i86 = i9 + 8 | 0;
michael@0 14202 i87 = i13 + 8 | 0;
michael@0 14203 i88 = i9 + 48 | 0;
michael@0 14204 i89 = i9 + 16 | 0;
michael@0 14205 i90 = i9 + 20 | 0;
michael@0 14206 i91 = i9 + 24 | 0;
michael@0 14207 i92 = i9 + 32 | 0;
michael@0 14208 i93 = i9 + 36 | 0;
michael@0 14209 i94 = i9 + 40 | 0;
michael@0 14210 i95 = i15 | 0;
michael@0 14211 i96 = i15 + 4 | 0;
michael@0 14212 i97 = i15 + 8 | 0;
michael@0 14213 i98 = i15 + 12 | 0;
michael@0 14214 i99 = i10 | 0;
michael@0 14215 i100 = i14 | 0;
michael@0 14216 i101 = i10 + 4 | 0;
michael@0 14217 i102 = i14 + 4 | 0;
michael@0 14218 i103 = i10 + 8 | 0;
michael@0 14219 i104 = i14 + 8 | 0;
michael@0 14220 i105 = i10 + 48 | 0;
michael@0 14221 i106 = i10 + 16 | 0;
michael@0 14222 i107 = i10 + 20 | 0;
michael@0 14223 i108 = i10 + 24 | 0;
michael@0 14224 i109 = i10 + 32 | 0;
michael@0 14225 i110 = i10 + 36 | 0;
michael@0 14226 i111 = i10 + 40 | 0;
michael@0 14227 i112 = i16 | 0;
michael@0 14228 i113 = i16 + 4 | 0;
michael@0 14229 i114 = i16 + 8 | 0;
michael@0 14230 i115 = i16 + 12 | 0;
michael@0 14231 i116 = i17 | 0;
michael@0 14232 i117 = i17 + 4 | 0;
michael@0 14233 i118 = i17 + 8 | 0;
michael@0 14234 i119 = i17 + 12 | 0;
michael@0 14235 i120 = i2 + 128 | 0;
michael@0 14236 i121 = i18 | 0;
michael@0 14237 i122 = i18 + 4 | 0;
michael@0 14238 i123 = i18 + 8 | 0;
michael@0 14239 i124 = i49;
michael@0 14240 i125 = i18;
michael@0 14241 L1498 : do {
michael@0 14242 if (i45) {
michael@0 14243 d126 = 999999984306749400.0;
michael@0 14244 d127 = d44;
michael@0 14245 d128 = d33;
michael@0 14246 d129 = d38;
michael@0 14247 d130 = d34;
michael@0 14248 while (1) {
michael@0 14249 d131 = +HEAPF32[i50 >> 2];
michael@0 14250 d132 = -0.0 - d131;
michael@0 14251 d133 = +HEAPF32[i51 >> 2];
michael@0 14252 d134 = -0.0 - d133;
michael@0 14253 d135 = +HEAPF32[i52 >> 2];
michael@0 14254 d136 = -0.0 - d135;
michael@0 14255 d137 = +HEAPF32[i60 >> 2] * d132 + +HEAPF32[i61 >> 2] * d134 + +HEAPF32[i62 >> 2] * d136;
michael@0 14256 d138 = +HEAPF32[i63 >> 2] * d132 + +HEAPF32[i64 >> 2] * d134 + +HEAPF32[i65 >> 2] * d136;
michael@0 14257 HEAPF32[i66 >> 2] = +HEAPF32[i57 >> 2] * d132 + +HEAPF32[i58 >> 2] * d134 + +HEAPF32[i59 >> 2] * d136;
michael@0 14258 HEAPF32[i67 >> 2] = d137;
michael@0 14259 HEAPF32[i68 >> 2] = d138;
michael@0 14260 HEAPF32[i69 >> 2] = 0.0;
michael@0 14261 d138 = d131 * +HEAPF32[i72 >> 2] + d133 * +HEAPF32[i73 >> 2] + d135 * +HEAPF32[i74 >> 2];
michael@0 14262 d137 = d131 * +HEAPF32[i75 >> 2] + d133 * +HEAPF32[i76 >> 2] + d135 * +HEAPF32[i77 >> 2];
michael@0 14263 HEAPF32[i78 >> 2] = d131 * +HEAPF32[i70 >> 2] + d133 * +HEAPF32[i30 >> 2] + d135 * +HEAPF32[i71 >> 2];
michael@0 14264 HEAPF32[i79 >> 2] = d138;
michael@0 14265 HEAPF32[i80 >> 2] = d137;
michael@0 14266 HEAPF32[i81 >> 2] = 0.0;
michael@0 14267 __ZNK13btConvexShape44localGetSupportVertexWithoutMarginNonVirtualERK9btVector3(i13, HEAP32[i28 >> 2] | 0, i11);
michael@0 14268 __ZNK13btConvexShape44localGetSupportVertexWithoutMarginNonVirtualERK9btVector3(i14, HEAP32[i32 >> 2] | 0, i12);
michael@0 14269 d137 = +HEAPF32[i83 >> 2];
michael@0 14270 d138 = +HEAPF32[i85 >> 2];
michael@0 14271 d135 = +HEAPF32[i87 >> 2];
michael@0 14272 d133 = d127 + (+HEAPF32[i82 >> 2] * d137 + +HEAPF32[i84 >> 2] * d138 + +HEAPF32[i86 >> 2] * d135);
michael@0 14273 d131 = d128 + (d137 * +HEAPF32[i89 >> 2] + d138 * +HEAPF32[i90 >> 2] + d135 * +HEAPF32[i91 >> 2]);
michael@0 14274 HEAPF32[i95 >> 2] = d133;
michael@0 14275 HEAPF32[i96 >> 2] = d131;
michael@0 14276 HEAPF32[i98 >> 2] = 0.0;
michael@0 14277 d135 = +HEAPF32[i100 >> 2];
michael@0 14278 d138 = +HEAPF32[i102 >> 2];
michael@0 14279 d137 = +HEAPF32[i104 >> 2];
michael@0 14280 d136 = d129 + (+HEAPF32[i99 >> 2] * d135 + +HEAPF32[i101 >> 2] * d138 + +HEAPF32[i103 >> 2] * d137);
michael@0 14281 d134 = d130 + (d135 * +HEAPF32[i106 >> 2] + d138 * +HEAPF32[i107 >> 2] + d137 * +HEAPF32[i108 >> 2]);
michael@0 14282 HEAPF32[i112 >> 2] = d136;
michael@0 14283 HEAPF32[i113 >> 2] = d134;
michael@0 14284 HEAPF32[i115 >> 2] = 0.0;
michael@0 14285 HEAPF32[i97 >> 2] = 0.0;
michael@0 14286 HEAPF32[i114 >> 2] = 0.0;
michael@0 14287 d137 = d133 - d136;
michael@0 14288 d136 = d131 - d134;
michael@0 14289 HEAPF32[i116 >> 2] = d137;
michael@0 14290 HEAPF32[i117 >> 2] = d136;
michael@0 14291 HEAPF32[i118 >> 2] = 0.0;
michael@0 14292 HEAPF32[i119 >> 2] = 0.0;
michael@0 14293 d134 = d137 * +HEAPF32[i50 >> 2] + d136 * +HEAPF32[i51 >> 2] + +HEAPF32[i52 >> 2] * 0.0;
michael@0 14294 if (d134 > 0.0) {
michael@0 14295 if (d134 * d134 > d126 * +HEAPF32[i120 >> 2]) {
michael@0 14296 d139 = d126;
michael@0 14297 i140 = 1318;
michael@0 14298 break L1498;
michael@0 14299 }
michael@0 14300 }
michael@0 14301 if (__ZN22btVoronoiSimplexSolver9inSimplexERK9btVector3(HEAP32[i56 >> 2] | 0, i17) | 0) {
michael@0 14302 d141 = d126;
michael@0 14303 i140 = 1320;
michael@0 14304 break L1498;
michael@0 14305 }
michael@0 14306 d136 = d126 - d134;
michael@0 14307 if (d136 <= d126 * 9.999999974752427e-7) {
michael@0 14308 d142 = d126;
michael@0 14309 d143 = d136;
michael@0 14310 i140 = 1322;
michael@0 14311 break L1498;
michael@0 14312 }
michael@0 14313 __ZN22btVoronoiSimplexSolver9addVertexERK9btVector3S2_S2_(HEAP32[i56 >> 2] | 0, i17, i15, i16);
michael@0 14314 if (!(__ZN22btVoronoiSimplexSolver7closestER9btVector3(HEAP32[i56 >> 2] | 0, i18) | 0)) {
michael@0 14315 d144 = d126;
michael@0 14316 i140 = 1324;
michael@0 14317 break L1498;
michael@0 14318 }
michael@0 14319 d136 = +HEAPF32[i121 >> 2];
michael@0 14320 d134 = +HEAPF32[i122 >> 2];
michael@0 14321 d137 = +HEAPF32[i123 >> 2];
michael@0 14322 d131 = d136 * d136 + d134 * d134 + d137 * d137;
michael@0 14323 if (d131 < 9.999999974752427e-7) {
michael@0 14324 d145 = d126;
michael@0 14325 i140 = 1326;
michael@0 14326 break L1498;
michael@0 14327 }
michael@0 14328 if (d126 - d131 <= d126 * 1.1920928955078125e-7) {
michael@0 14329 d146 = d131;
michael@0 14330 i140 = 1328;
michael@0 14331 break L1498;
michael@0 14332 }
michael@0 14333 HEAP32[i124 >> 2] = HEAP32[i125 >> 2];
michael@0 14334 HEAP32[i124 + 4 >> 2] = HEAP32[i125 + 4 >> 2];
michael@0 14335 HEAP32[i124 + 8 >> 2] = HEAP32[i125 + 8 >> 2];
michael@0 14336 HEAP32[i124 + 12 >> 2] = HEAP32[i125 + 12 >> 2];
michael@0 14337 i147 = HEAP32[i47 >> 2] | 0;
michael@0 14338 HEAP32[i47 >> 2] = i147 + 1;
michael@0 14339 if ((i147 | 0) > 1e3) {
michael@0 14340 d148 = 0.0;
michael@0 14341 i149 = 0;
michael@0 14342 break L1498;
michael@0 14343 }
michael@0 14344 if ((HEAP32[HEAP32[i56 >> 2] >> 2] | 0) == 4) {
michael@0 14345 i140 = 1332;
michael@0 14346 break L1498;
michael@0 14347 }
michael@0 14348 d126 = d131;
michael@0 14349 d127 = +HEAPF32[i88 >> 2];
michael@0 14350 d128 = +HEAPF32[i31 >> 2];
michael@0 14351 d129 = +HEAPF32[i105 >> 2];
michael@0 14352 d130 = +HEAPF32[i27 >> 2];
michael@0 14353 }
michael@0 14354 } else {
michael@0 14355 d130 = 999999984306749400.0;
michael@0 14356 d129 = d44;
michael@0 14357 d128 = d33;
michael@0 14358 d127 = d35;
michael@0 14359 d126 = d38;
michael@0 14360 d131 = d34;
michael@0 14361 d137 = d36;
michael@0 14362 while (1) {
michael@0 14363 d134 = +HEAPF32[i50 >> 2];
michael@0 14364 d136 = -0.0 - d134;
michael@0 14365 d133 = +HEAPF32[i51 >> 2];
michael@0 14366 d138 = -0.0 - d133;
michael@0 14367 d135 = +HEAPF32[i52 >> 2];
michael@0 14368 d132 = -0.0 - d135;
michael@0 14369 d150 = +HEAPF32[i60 >> 2] * d136 + +HEAPF32[i61 >> 2] * d138 + +HEAPF32[i62 >> 2] * d132;
michael@0 14370 d151 = +HEAPF32[i63 >> 2] * d136 + +HEAPF32[i64 >> 2] * d138 + +HEAPF32[i65 >> 2] * d132;
michael@0 14371 HEAPF32[i66 >> 2] = +HEAPF32[i57 >> 2] * d136 + +HEAPF32[i58 >> 2] * d138 + +HEAPF32[i59 >> 2] * d132;
michael@0 14372 HEAPF32[i67 >> 2] = d150;
michael@0 14373 HEAPF32[i68 >> 2] = d151;
michael@0 14374 HEAPF32[i69 >> 2] = 0.0;
michael@0 14375 d151 = d134 * +HEAPF32[i72 >> 2] + d133 * +HEAPF32[i73 >> 2] + d135 * +HEAPF32[i74 >> 2];
michael@0 14376 d150 = d134 * +HEAPF32[i75 >> 2] + d133 * +HEAPF32[i76 >> 2] + d135 * +HEAPF32[i77 >> 2];
michael@0 14377 HEAPF32[i78 >> 2] = d134 * +HEAPF32[i70 >> 2] + d133 * +HEAPF32[i30 >> 2] + d135 * +HEAPF32[i71 >> 2];
michael@0 14378 HEAPF32[i79 >> 2] = d151;
michael@0 14379 HEAPF32[i80 >> 2] = d150;
michael@0 14380 HEAPF32[i81 >> 2] = 0.0;
michael@0 14381 __ZNK13btConvexShape44localGetSupportVertexWithoutMarginNonVirtualERK9btVector3(i13, HEAP32[i28 >> 2] | 0, i11);
michael@0 14382 __ZNK13btConvexShape44localGetSupportVertexWithoutMarginNonVirtualERK9btVector3(i14, HEAP32[i32 >> 2] | 0, i12);
michael@0 14383 d150 = +HEAPF32[i83 >> 2];
michael@0 14384 d151 = +HEAPF32[i85 >> 2];
michael@0 14385 d135 = +HEAPF32[i87 >> 2];
michael@0 14386 d133 = d129 + (+HEAPF32[i82 >> 2] * d150 + +HEAPF32[i84 >> 2] * d151 + +HEAPF32[i86 >> 2] * d135);
michael@0 14387 d134 = d128 + (d150 * +HEAPF32[i89 >> 2] + d151 * +HEAPF32[i90 >> 2] + d135 * +HEAPF32[i91 >> 2]);
michael@0 14388 d132 = d127 + (d150 * +HEAPF32[i92 >> 2] + d151 * +HEAPF32[i93 >> 2] + d135 * +HEAPF32[i94 >> 2]);
michael@0 14389 HEAPF32[i95 >> 2] = d133;
michael@0 14390 HEAPF32[i96 >> 2] = d134;
michael@0 14391 HEAPF32[i97 >> 2] = d132;
michael@0 14392 HEAPF32[i98 >> 2] = 0.0;
michael@0 14393 d135 = +HEAPF32[i100 >> 2];
michael@0 14394 d151 = +HEAPF32[i102 >> 2];
michael@0 14395 d150 = +HEAPF32[i104 >> 2];
michael@0 14396 d138 = d126 + (+HEAPF32[i99 >> 2] * d135 + +HEAPF32[i101 >> 2] * d151 + +HEAPF32[i103 >> 2] * d150);
michael@0 14397 d136 = d131 + (d135 * +HEAPF32[i106 >> 2] + d151 * +HEAPF32[i107 >> 2] + d150 * +HEAPF32[i108 >> 2]);
michael@0 14398 d152 = d137 + (d135 * +HEAPF32[i109 >> 2] + d151 * +HEAPF32[i110 >> 2] + d150 * +HEAPF32[i111 >> 2]);
michael@0 14399 HEAPF32[i112 >> 2] = d138;
michael@0 14400 HEAPF32[i113 >> 2] = d136;
michael@0 14401 HEAPF32[i114 >> 2] = d152;
michael@0 14402 HEAPF32[i115 >> 2] = 0.0;
michael@0 14403 d150 = d133 - d138;
michael@0 14404 d138 = d134 - d136;
michael@0 14405 d136 = d132 - d152;
michael@0 14406 HEAPF32[i116 >> 2] = d150;
michael@0 14407 HEAPF32[i117 >> 2] = d138;
michael@0 14408 HEAPF32[i118 >> 2] = d136;
michael@0 14409 HEAPF32[i119 >> 2] = 0.0;
michael@0 14410 d152 = d150 * +HEAPF32[i50 >> 2] + d138 * +HEAPF32[i51 >> 2] + d136 * +HEAPF32[i52 >> 2];
michael@0 14411 if (d152 > 0.0) {
michael@0 14412 if (d152 * d152 > d130 * +HEAPF32[i120 >> 2]) {
michael@0 14413 d139 = d130;
michael@0 14414 i140 = 1318;
michael@0 14415 break L1498;
michael@0 14416 }
michael@0 14417 }
michael@0 14418 if (__ZN22btVoronoiSimplexSolver9inSimplexERK9btVector3(HEAP32[i56 >> 2] | 0, i17) | 0) {
michael@0 14419 d141 = d130;
michael@0 14420 i140 = 1320;
michael@0 14421 break L1498;
michael@0 14422 }
michael@0 14423 d136 = d130 - d152;
michael@0 14424 if (d136 <= d130 * 9.999999974752427e-7) {
michael@0 14425 d142 = d130;
michael@0 14426 d143 = d136;
michael@0 14427 i140 = 1322;
michael@0 14428 break L1498;
michael@0 14429 }
michael@0 14430 __ZN22btVoronoiSimplexSolver9addVertexERK9btVector3S2_S2_(HEAP32[i56 >> 2] | 0, i17, i15, i16);
michael@0 14431 if (!(__ZN22btVoronoiSimplexSolver7closestER9btVector3(HEAP32[i56 >> 2] | 0, i18) | 0)) {
michael@0 14432 d144 = d130;
michael@0 14433 i140 = 1324;
michael@0 14434 break L1498;
michael@0 14435 }
michael@0 14436 d136 = +HEAPF32[i121 >> 2];
michael@0 14437 d152 = +HEAPF32[i122 >> 2];
michael@0 14438 d138 = +HEAPF32[i123 >> 2];
michael@0 14439 d150 = d136 * d136 + d152 * d152 + d138 * d138;
michael@0 14440 if (d150 < 9.999999974752427e-7) {
michael@0 14441 d145 = d130;
michael@0 14442 i140 = 1326;
michael@0 14443 break L1498;
michael@0 14444 }
michael@0 14445 if (d130 - d150 <= d130 * 1.1920928955078125e-7) {
michael@0 14446 d146 = d150;
michael@0 14447 i140 = 1328;
michael@0 14448 break L1498;
michael@0 14449 }
michael@0 14450 HEAP32[i124 >> 2] = HEAP32[i125 >> 2];
michael@0 14451 HEAP32[i124 + 4 >> 2] = HEAP32[i125 + 4 >> 2];
michael@0 14452 HEAP32[i124 + 8 >> 2] = HEAP32[i125 + 8 >> 2];
michael@0 14453 HEAP32[i124 + 12 >> 2] = HEAP32[i125 + 12 >> 2];
michael@0 14454 i147 = HEAP32[i47 >> 2] | 0;
michael@0 14455 HEAP32[i47 >> 2] = i147 + 1;
michael@0 14456 if ((i147 | 0) > 1e3) {
michael@0 14457 d148 = 0.0;
michael@0 14458 i149 = 0;
michael@0 14459 break L1498;
michael@0 14460 }
michael@0 14461 if ((HEAP32[HEAP32[i56 >> 2] >> 2] | 0) == 4) {
michael@0 14462 i140 = 1332;
michael@0 14463 break L1498;
michael@0 14464 }
michael@0 14465 d130 = d150;
michael@0 14466 d129 = +HEAPF32[i88 >> 2];
michael@0 14467 d128 = +HEAPF32[i31 >> 2];
michael@0 14468 d127 = +HEAPF32[i37 >> 2];
michael@0 14469 d126 = +HEAPF32[i105 >> 2];
michael@0 14470 d131 = +HEAPF32[i27 >> 2];
michael@0 14471 d137 = +HEAPF32[i39 >> 2];
michael@0 14472 }
michael@0 14473 }
michael@0 14474 } while (0);
michael@0 14475 if ((i140 | 0) == 1326) {
michael@0 14476 HEAP32[i124 >> 2] = HEAP32[i125 >> 2];
michael@0 14477 HEAP32[i124 + 4 >> 2] = HEAP32[i125 + 4 >> 2];
michael@0 14478 HEAP32[i124 + 8 >> 2] = HEAP32[i125 + 8 >> 2];
michael@0 14479 HEAP32[i124 + 12 >> 2] = HEAP32[i125 + 12 >> 2];
michael@0 14480 HEAP32[i54 >> 2] = 6;
michael@0 14481 d153 = d145;
michael@0 14482 i140 = 1333;
michael@0 14483 } else if ((i140 | 0) == 1328) {
michael@0 14484 HEAP32[i54 >> 2] = 12;
michael@0 14485 d153 = d146;
michael@0 14486 i140 = 1333;
michael@0 14487 } else if ((i140 | 0) == 1322) {
michael@0 14488 HEAP32[i54 >> 2] = d143 > 0.0 ? 11 : 2;
michael@0 14489 d153 = d142;
michael@0 14490 i140 = 1333;
michael@0 14491 } else if ((i140 | 0) == 1318) {
michael@0 14492 HEAP32[i54 >> 2] = 10;
michael@0 14493 d153 = d139;
michael@0 14494 i140 = 1333;
michael@0 14495 } else if ((i140 | 0) == 1320) {
michael@0 14496 HEAP32[i54 >> 2] = 1;
michael@0 14497 d153 = d141;
michael@0 14498 i140 = 1333;
michael@0 14499 } else if ((i140 | 0) == 1324) {
michael@0 14500 HEAP32[i54 >> 2] = 3;
michael@0 14501 d153 = d144;
michael@0 14502 i140 = 1333;
michael@0 14503 } else if ((i140 | 0) == 1332) {
michael@0 14504 HEAP32[i54 >> 2] = 13;
michael@0 14505 d148 = 0.0;
michael@0 14506 i149 = 0;
michael@0 14507 }
michael@0 14508 do {
michael@0 14509 if ((i140 | 0) == 1333) {
michael@0 14510 __ZN22btVoronoiSimplexSolver14compute_pointsER9btVector3S1_(HEAP32[i56 >> 2] | 0, i7, i8);
michael@0 14511 HEAP32[i29 >> 2] = HEAP32[i124 >> 2];
michael@0 14512 HEAP32[i29 + 4 >> 2] = HEAP32[i124 + 4 >> 2];
michael@0 14513 HEAP32[i29 + 8 >> 2] = HEAP32[i124 + 8 >> 2];
michael@0 14514 HEAP32[i29 + 12 >> 2] = HEAP32[i124 + 12 >> 2];
michael@0 14515 d144 = +HEAPF32[i50 >> 2];
michael@0 14516 d141 = +HEAPF32[i51 >> 2];
michael@0 14517 d139 = +HEAPF32[i52 >> 2];
michael@0 14518 d142 = d144 * d144 + d141 * d141 + d139 * d139;
michael@0 14519 if (d142 < 1.0e-4) {
michael@0 14520 HEAP32[i54 >> 2] = 5;
michael@0 14521 }
michael@0 14522 if (d142 > 1.4210854715202004e-14) {
michael@0 14523 d143 = 1.0 / +Math_sqrt(+d142);
michael@0 14524 HEAPF32[i23 >> 2] = d143 * +HEAPF32[i23 >> 2];
michael@0 14525 HEAPF32[i24 >> 2] = d143 * +HEAPF32[i24 >> 2];
michael@0 14526 HEAPF32[i25 >> 2] = d143 * +HEAPF32[i25 >> 2];
michael@0 14527 d142 = +Math_sqrt(+d153);
michael@0 14528 d146 = d48 / d142;
michael@0 14529 i125 = i7 | 0;
michael@0 14530 HEAPF32[i125 >> 2] = +HEAPF32[i125 >> 2] - d144 * d146;
michael@0 14531 i125 = i7 + 4 | 0;
michael@0 14532 HEAPF32[i125 >> 2] = +HEAPF32[i125 >> 2] - d141 * d146;
michael@0 14533 i125 = i7 + 8 | 0;
michael@0 14534 HEAPF32[i125 >> 2] = +HEAPF32[i125 >> 2] - d139 * d146;
michael@0 14535 d146 = d40 / d142;
michael@0 14536 i125 = i8 | 0;
michael@0 14537 HEAPF32[i125 >> 2] = d144 * d146 + +HEAPF32[i125 >> 2];
michael@0 14538 i125 = i8 + 4 | 0;
michael@0 14539 HEAPF32[i125 >> 2] = d141 * d146 + +HEAPF32[i125 >> 2];
michael@0 14540 i125 = i8 + 8 | 0;
michael@0 14541 HEAPF32[i125 >> 2] = d139 * d146 + +HEAPF32[i125 >> 2];
michael@0 14542 HEAP32[i55 >> 2] = 1;
michael@0 14543 d148 = 1.0 / d143 - d46;
michael@0 14544 i149 = 1;
michael@0 14545 break;
michael@0 14546 } else {
michael@0 14547 HEAP32[i55 >> 2] = 2;
michael@0 14548 d148 = 0.0;
michael@0 14549 i149 = 0;
michael@0 14550 break;
michael@0 14551 }
michael@0 14552 }
michael@0 14553 } while (0);
michael@0 14554 do {
michael@0 14555 if ((HEAP32[i1 + 72 >> 2] | 0) == 0) {
michael@0 14556 i154 = 0;
michael@0 14557 } else {
michael@0 14558 if ((HEAP32[i1 + 20 >> 2] | 0) == 0) {
michael@0 14559 i154 = 0;
michael@0 14560 break;
michael@0 14561 }
michael@0 14562 if ((HEAP32[i54 >> 2] | 0) == 0) {
michael@0 14563 i154 = 0;
michael@0 14564 break;
michael@0 14565 }
michael@0 14566 i154 = d46 + d148 < .01;
michael@0 14567 }
michael@0 14568 } while (0);
michael@0 14569 i54 = i149 ^ 1;
michael@0 14570 do {
michael@0 14571 if (i154 | i54) {
michael@0 14572 i125 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 14573 if ((i125 | 0) == 0) {
michael@0 14574 i140 = 1356;
michael@0 14575 break;
michael@0 14576 }
michael@0 14577 HEAP32[2994] = (HEAP32[2994] | 0) + 1;
michael@0 14578 _memset(i124 | 0, 0, 16);
michael@0 14579 if (!(FUNCTION_TABLE_iiiiiiiiiiii[HEAP32[(HEAP32[i125 >> 2] | 0) + 8 >> 2] & 7](i125, HEAP32[i56 >> 2] | 0, HEAP32[i28 >> 2] | 0, HEAP32[i32 >> 2] | 0, i9, i10, i49, i19, i20, i4, HEAP32[i2 + 132 >> 2] | 0) | 0)) {
michael@0 14580 d153 = +HEAPF32[i50 >> 2];
michael@0 14581 d143 = +HEAPF32[i51 >> 2];
michael@0 14582 d146 = +HEAPF32[i52 >> 2];
michael@0 14583 if (d153 * d153 + d143 * d143 + d146 * d146 <= 0.0) {
michael@0 14584 i140 = 1356;
michael@0 14585 break;
michael@0 14586 }
michael@0 14587 d139 = +HEAPF32[i19 >> 2] - +HEAPF32[i20 >> 2];
michael@0 14588 d141 = +HEAPF32[i19 + 4 >> 2] - +HEAPF32[i20 + 4 >> 2];
michael@0 14589 d144 = +HEAPF32[i19 + 8 >> 2] - +HEAPF32[i20 + 8 >> 2];
michael@0 14590 d142 = +Math_sqrt(+(d139 * d139 + d141 * d141 + d144 * d144)) - d46;
michael@0 14591 if (d142 < d148 | i54) {
michael@0 14592 i125 = i7;
michael@0 14593 i39 = i19;
michael@0 14594 HEAP32[i125 >> 2] = HEAP32[i39 >> 2];
michael@0 14595 HEAP32[i125 + 4 >> 2] = HEAP32[i39 + 4 >> 2];
michael@0 14596 HEAP32[i125 + 8 >> 2] = HEAP32[i39 + 8 >> 2];
michael@0 14597 HEAP32[i125 + 12 >> 2] = HEAP32[i39 + 12 >> 2];
michael@0 14598 i39 = i8;
michael@0 14599 i125 = i20;
michael@0 14600 HEAP32[i39 >> 2] = HEAP32[i125 >> 2];
michael@0 14601 HEAP32[i39 + 4 >> 2] = HEAP32[i125 + 4 >> 2];
michael@0 14602 HEAP32[i39 + 8 >> 2] = HEAP32[i125 + 8 >> 2];
michael@0 14603 HEAP32[i39 + 12 >> 2] = HEAP32[i125 + 12 >> 2];
michael@0 14604 i125 = i7 | 0;
michael@0 14605 HEAPF32[i125 >> 2] = +HEAPF32[i125 >> 2] - d48 * d153;
michael@0 14606 i125 = i7 + 4 | 0;
michael@0 14607 HEAPF32[i125 >> 2] = +HEAPF32[i125 >> 2] - d48 * d143;
michael@0 14608 i125 = i7 + 8 | 0;
michael@0 14609 HEAPF32[i125 >> 2] = +HEAPF32[i125 >> 2] - d48 * d146;
michael@0 14610 i125 = i8 | 0;
michael@0 14611 HEAPF32[i125 >> 2] = d40 * d153 + +HEAPF32[i125 >> 2];
michael@0 14612 i125 = i8 + 4 | 0;
michael@0 14613 HEAPF32[i125 >> 2] = d40 * d143 + +HEAPF32[i125 >> 2];
michael@0 14614 i125 = i8 + 8 | 0;
michael@0 14615 HEAPF32[i125 >> 2] = d40 * d146 + +HEAPF32[i125 >> 2];
michael@0 14616 HEAP32[i29 >> 2] = HEAP32[i124 >> 2];
michael@0 14617 HEAP32[i29 + 4 >> 2] = HEAP32[i124 + 4 >> 2];
michael@0 14618 HEAP32[i29 + 8 >> 2] = HEAP32[i124 + 8 >> 2];
michael@0 14619 HEAP32[i29 + 12 >> 2] = HEAP32[i124 + 12 >> 2];
michael@0 14620 d146 = +HEAPF32[i23 >> 2];
michael@0 14621 d143 = +HEAPF32[i24 >> 2];
michael@0 14622 d153 = +HEAPF32[i25 >> 2];
michael@0 14623 d144 = 1.0 / +Math_sqrt(+(d146 * d146 + d143 * d143 + d153 * d153));
michael@0 14624 HEAPF32[i23 >> 2] = d146 * d144;
michael@0 14625 HEAPF32[i24 >> 2] = d143 * d144;
michael@0 14626 HEAPF32[i25 >> 2] = d153 * d144;
michael@0 14627 HEAP32[i55 >> 2] = 6;
michael@0 14628 d155 = d142;
michael@0 14629 break;
michael@0 14630 }
michael@0 14631 HEAP32[i55 >> 2] = 5;
michael@0 14632 if (i149) {
michael@0 14633 d155 = d148;
michael@0 14634 break;
michael@0 14635 }
michael@0 14636 STACKTOP = i5;
michael@0 14637 return;
michael@0 14638 }
michael@0 14639 d142 = +HEAPF32[i20 >> 2];
michael@0 14640 d144 = +HEAPF32[i19 >> 2];
michael@0 14641 d153 = d142 - d144;
michael@0 14642 d143 = +HEAPF32[i20 + 4 >> 2];
michael@0 14643 d146 = +HEAPF32[i19 + 4 >> 2];
michael@0 14644 d141 = d143 - d146;
michael@0 14645 d139 = +HEAPF32[i20 + 8 >> 2];
michael@0 14646 d145 = +HEAPF32[i19 + 8 >> 2];
michael@0 14647 d36 = d139 - d145;
michael@0 14648 d34 = d153 * d153 + d141 * d141 + d36 * d36;
michael@0 14649 if (d34 > 1.4210854715202004e-14) {
michael@0 14650 d156 = d34;
michael@0 14651 d157 = d153;
michael@0 14652 d158 = d141;
michael@0 14653 d159 = d36;
michael@0 14654 d160 = 0.0;
michael@0 14655 } else {
michael@0 14656 d36 = +HEAPF32[i1 + 4 >> 2];
michael@0 14657 d141 = +HEAPF32[i51 >> 2];
michael@0 14658 d153 = +HEAPF32[i52 >> 2];
michael@0 14659 d156 = d36 * d36 + d141 * d141 + d153 * d153;
michael@0 14660 d157 = d36;
michael@0 14661 d158 = d141;
michael@0 14662 d159 = d153;
michael@0 14663 d160 = +HEAPF32[i53 >> 2];
michael@0 14664 }
michael@0 14665 if (d156 <= 1.4210854715202004e-14) {
michael@0 14666 HEAP32[i55 >> 2] = 9;
michael@0 14667 if (i149) {
michael@0 14668 d155 = d148;
michael@0 14669 break;
michael@0 14670 }
michael@0 14671 STACKTOP = i5;
michael@0 14672 return;
michael@0 14673 }
michael@0 14674 d153 = 1.0 / +Math_sqrt(+d156);
michael@0 14675 d141 = d144 - d142;
michael@0 14676 d142 = d146 - d143;
michael@0 14677 d143 = d145 - d139;
michael@0 14678 d139 = -0.0 - +Math_sqrt(+(d141 * d141 + d142 * d142 + d143 * d143));
michael@0 14679 if (d148 > d139 | i54) {
michael@0 14680 i125 = i7;
michael@0 14681 i39 = i19;
michael@0 14682 HEAP32[i125 >> 2] = HEAP32[i39 >> 2];
michael@0 14683 HEAP32[i125 + 4 >> 2] = HEAP32[i39 + 4 >> 2];
michael@0 14684 HEAP32[i125 + 8 >> 2] = HEAP32[i39 + 8 >> 2];
michael@0 14685 HEAP32[i125 + 12 >> 2] = HEAP32[i39 + 12 >> 2];
michael@0 14686 i39 = i8;
michael@0 14687 i125 = i20;
michael@0 14688 HEAP32[i39 >> 2] = HEAP32[i125 >> 2];
michael@0 14689 HEAP32[i39 + 4 >> 2] = HEAP32[i125 + 4 >> 2];
michael@0 14690 HEAP32[i39 + 8 >> 2] = HEAP32[i125 + 8 >> 2];
michael@0 14691 HEAP32[i39 + 12 >> 2] = HEAP32[i125 + 12 >> 2];
michael@0 14692 HEAPF32[i23 >> 2] = d157 * d153;
michael@0 14693 HEAPF32[i24 >> 2] = d158 * d153;
michael@0 14694 HEAPF32[i25 >> 2] = d159 * d153;
michael@0 14695 HEAPF32[i26 >> 2] = d160;
michael@0 14696 HEAP32[i55 >> 2] = 3;
michael@0 14697 d155 = d139;
michael@0 14698 break;
michael@0 14699 }
michael@0 14700 HEAP32[i55 >> 2] = 8;
michael@0 14701 if (i149) {
michael@0 14702 d155 = d148;
michael@0 14703 break;
michael@0 14704 }
michael@0 14705 STACKTOP = i5;
michael@0 14706 return;
michael@0 14707 } else {
michael@0 14708 i140 = 1356;
michael@0 14709 }
michael@0 14710 } while (0);
michael@0 14711 do {
michael@0 14712 if ((i140 | 0) == 1356) {
michael@0 14713 if (i149) {
michael@0 14714 d155 = d148;
michael@0 14715 break;
michael@0 14716 }
michael@0 14717 STACKTOP = i5;
michael@0 14718 return;
michael@0 14719 }
michael@0 14720 } while (0);
michael@0 14721 do {
michael@0 14722 if (d155 >= 0.0) {
michael@0 14723 if (d155 * d155 < +HEAPF32[i120 >> 2]) {
michael@0 14724 break;
michael@0 14725 }
michael@0 14726 STACKTOP = i5;
michael@0 14727 return;
michael@0 14728 }
michael@0 14729 } while (0);
michael@0 14730 HEAP32[i124 >> 2] = HEAP32[i29 >> 2];
michael@0 14731 HEAP32[i124 + 4 >> 2] = HEAP32[i29 + 4 >> 2];
michael@0 14732 HEAP32[i124 + 8 >> 2] = HEAP32[i29 + 8 >> 2];
michael@0 14733 HEAP32[i124 + 12 >> 2] = HEAP32[i29 + 12 >> 2];
michael@0 14734 HEAPF32[i22 >> 2] = d155;
michael@0 14735 i22 = HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] | 0;
michael@0 14736 d148 = d42 + +HEAPF32[i8 + 4 >> 2];
michael@0 14737 d42 = d43 + +HEAPF32[i8 + 8 >> 2];
michael@0 14738 HEAPF32[i21 >> 2] = d41 + +HEAPF32[i8 >> 2];
michael@0 14739 HEAPF32[i21 + 4 >> 2] = d148;
michael@0 14740 HEAPF32[i21 + 8 >> 2] = d42;
michael@0 14741 HEAPF32[i21 + 12 >> 2] = 0.0;
michael@0 14742 FUNCTION_TABLE_viiif[i22 & 15](i3, i6, i21, d155);
michael@0 14743 STACKTOP = i5;
michael@0 14744 return;
michael@0 14745 }
michael@0 14746 function __ZN16btCollisionWorld15debugDrawObjectERK11btTransformPK16btCollisionShapeRK9btVector3(i1, i2, i3, i4) {
michael@0 14747 i1 = i1 | 0;
michael@0 14748 i2 = i2 | 0;
michael@0 14749 i3 = i3 | 0;
michael@0 14750 i4 = i4 | 0;
michael@0 14751 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, d61 = 0.0, d62 = 0.0, d63 = 0.0, d64 = 0.0, d65 = 0.0, d66 = 0.0, d67 = 0.0, d68 = 0.0, d69 = 0.0, d70 = 0.0, d71 = 0.0, d72 = 0.0, i73 = 0, d74 = 0.0, d75 = 0.0, d76 = 0.0, d77 = 0.0, d78 = 0.0, d79 = 0.0, d80 = 0.0, d81 = 0.0, d82 = 0.0, d83 = 0.0, d84 = 0.0, d85 = 0.0, d86 = 0.0, i87 = 0, i88 = 0, d89 = 0.0, d90 = 0.0, d91 = 0.0, i92 = 0;
michael@0 14752 i5 = STACKTOP;
michael@0 14753 STACKTOP = STACKTOP + 576 | 0;
michael@0 14754 i6 = i5 | 0;
michael@0 14755 i7 = i5 + 64 | 0;
michael@0 14756 i8 = i5 + 80 | 0;
michael@0 14757 i9 = i5 + 96 | 0;
michael@0 14758 i10 = i5 + 160 | 0;
michael@0 14759 i11 = i5 + 176 | 0;
michael@0 14760 i12 = i5 + 192 | 0;
michael@0 14761 i13 = i5 + 208 | 0;
michael@0 14762 i14 = i5 + 304 | 0;
michael@0 14763 i15 = i5 + 320 | 0;
michael@0 14764 i16 = i5 + 336 | 0;
michael@0 14765 i17 = i5 + 432 | 0;
michael@0 14766 i18 = i5 + 448 | 0;
michael@0 14767 i19 = i5 + 464 | 0;
michael@0 14768 i20 = i5 + 480 | 0;
michael@0 14769 i21 = i5 + 496 | 0;
michael@0 14770 i22 = i5 + 512 | 0;
michael@0 14771 i23 = i5 + 528 | 0;
michael@0 14772 i24 = i5 + 544 | 0;
michael@0 14773 i25 = i5 + 560 | 0;
michael@0 14774 i26 = i1;
michael@0 14775 i27 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 14776 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i27 >> 2] | 0) + 56 >> 2] & 3](i27, i2, 1.0);
michael@0 14777 i27 = i3 + 4 | 0;
michael@0 14778 i28 = HEAP32[i27 >> 2] | 0;
michael@0 14779 switch (i28 | 0) {
michael@0 14780 case 31:
michael@0 14781 {
michael@0 14782 i29 = HEAP32[i3 + 16 >> 2] | 0;
michael@0 14783 if ((i29 | 0) <= 0) {
michael@0 14784 STACKTOP = i5;
michael@0 14785 return;
michael@0 14786 }
michael@0 14787 i30 = i3 + 24 | 0;
michael@0 14788 i31 = i1;
michael@0 14789 i32 = i2 | 0;
michael@0 14790 i33 = i2 + 4 | 0;
michael@0 14791 i34 = i2 + 8 | 0;
michael@0 14792 i35 = i2 + 16 | 0;
michael@0 14793 i36 = i2 + 20 | 0;
michael@0 14794 i37 = i2 + 24 | 0;
michael@0 14795 i38 = i2 + 32 | 0;
michael@0 14796 i39 = i2 + 36 | 0;
michael@0 14797 i40 = i2 + 40 | 0;
michael@0 14798 i41 = i2 + 48 | 0;
michael@0 14799 i42 = i2 + 52 | 0;
michael@0 14800 i43 = i2 + 56 | 0;
michael@0 14801 i44 = i6 | 0;
michael@0 14802 i45 = i6 + 4 | 0;
michael@0 14803 i46 = i6 + 8 | 0;
michael@0 14804 i47 = i6 + 12 | 0;
michael@0 14805 i48 = i6 + 16 | 0;
michael@0 14806 i49 = i6 + 20 | 0;
michael@0 14807 i50 = i6 + 24 | 0;
michael@0 14808 i51 = i6 + 28 | 0;
michael@0 14809 i52 = i6 + 32 | 0;
michael@0 14810 i53 = i6 + 36 | 0;
michael@0 14811 i54 = i6 + 40 | 0;
michael@0 14812 i55 = i6 + 44 | 0;
michael@0 14813 i56 = i6 + 48 | 0;
michael@0 14814 i57 = i6 + 52 | 0;
michael@0 14815 i58 = i6 + 56 | 0;
michael@0 14816 i59 = i6 + 60 | 0;
michael@0 14817 i60 = i29;
michael@0 14818 do {
michael@0 14819 i60 = i60 - 1 | 0;
michael@0 14820 i29 = HEAP32[i30 >> 2] | 0;
michael@0 14821 d61 = +HEAPF32[i29 + (i60 * 80 | 0) >> 2];
michael@0 14822 d62 = +HEAPF32[i29 + (i60 * 80 | 0) + 4 >> 2];
michael@0 14823 d63 = +HEAPF32[i29 + (i60 * 80 | 0) + 8 >> 2];
michael@0 14824 d64 = +HEAPF32[i29 + (i60 * 80 | 0) + 16 >> 2];
michael@0 14825 d65 = +HEAPF32[i29 + (i60 * 80 | 0) + 20 >> 2];
michael@0 14826 d66 = +HEAPF32[i29 + (i60 * 80 | 0) + 24 >> 2];
michael@0 14827 d67 = +HEAPF32[i29 + (i60 * 80 | 0) + 32 >> 2];
michael@0 14828 d68 = +HEAPF32[i29 + (i60 * 80 | 0) + 36 >> 2];
michael@0 14829 d69 = +HEAPF32[i29 + (i60 * 80 | 0) + 40 >> 2];
michael@0 14830 d70 = +HEAPF32[i29 + (i60 * 80 | 0) + 48 >> 2];
michael@0 14831 d71 = +HEAPF32[i29 + (i60 * 80 | 0) + 52 >> 2];
michael@0 14832 d72 = +HEAPF32[i29 + (i60 * 80 | 0) + 56 >> 2];
michael@0 14833 i73 = HEAP32[i29 + (i60 * 80 | 0) + 64 >> 2] | 0;
michael@0 14834 i29 = HEAP32[(HEAP32[i31 >> 2] | 0) + 24 >> 2] | 0;
michael@0 14835 d74 = +HEAPF32[i32 >> 2];
michael@0 14836 d75 = +HEAPF32[i33 >> 2];
michael@0 14837 d76 = +HEAPF32[i34 >> 2];
michael@0 14838 d77 = +HEAPF32[i35 >> 2];
michael@0 14839 d78 = +HEAPF32[i36 >> 2];
michael@0 14840 d79 = +HEAPF32[i37 >> 2];
michael@0 14841 d80 = +HEAPF32[i38 >> 2];
michael@0 14842 d81 = +HEAPF32[i39 >> 2];
michael@0 14843 d82 = +HEAPF32[i40 >> 2];
michael@0 14844 d83 = d70 * d74 + d71 * d75 + d72 * d76 + +HEAPF32[i41 >> 2];
michael@0 14845 d84 = d70 * d77 + d71 * d78 + d72 * d79 + +HEAPF32[i42 >> 2];
michael@0 14846 d85 = d70 * d80 + d71 * d81 + d72 * d82 + +HEAPF32[i43 >> 2];
michael@0 14847 HEAPF32[i44 >> 2] = d61 * d74 + d64 * d75 + d67 * d76;
michael@0 14848 HEAPF32[i45 >> 2] = d62 * d74 + d65 * d75 + d68 * d76;
michael@0 14849 HEAPF32[i46 >> 2] = d63 * d74 + d66 * d75 + d69 * d76;
michael@0 14850 HEAPF32[i47 >> 2] = 0.0;
michael@0 14851 HEAPF32[i48 >> 2] = d61 * d77 + d64 * d78 + d67 * d79;
michael@0 14852 HEAPF32[i49 >> 2] = d62 * d77 + d65 * d78 + d68 * d79;
michael@0 14853 HEAPF32[i50 >> 2] = d63 * d77 + d66 * d78 + d69 * d79;
michael@0 14854 HEAPF32[i51 >> 2] = 0.0;
michael@0 14855 HEAPF32[i52 >> 2] = d61 * d80 + d64 * d81 + d67 * d82;
michael@0 14856 HEAPF32[i53 >> 2] = d62 * d80 + d65 * d81 + d68 * d82;
michael@0 14857 HEAPF32[i54 >> 2] = d63 * d80 + d66 * d81 + d69 * d82;
michael@0 14858 HEAPF32[i55 >> 2] = 0.0;
michael@0 14859 HEAPF32[i56 >> 2] = d83;
michael@0 14860 HEAPF32[i57 >> 2] = d84;
michael@0 14861 HEAPF32[i58 >> 2] = d85;
michael@0 14862 HEAPF32[i59 >> 2] = 0.0;
michael@0 14863 FUNCTION_TABLE_viiii[i29 & 127](i1, i6, i73, i4);
michael@0 14864 } while ((i60 | 0) > 0);
michael@0 14865 STACKTOP = i5;
michael@0 14866 return;
michael@0 14867 }
michael@0 14868 case 0:
michael@0 14869 {
michael@0 14870 i60 = i7;
michael@0 14871 i6 = i3 + 28 | 0;
michael@0 14872 HEAP32[i60 >> 2] = HEAP32[i6 >> 2];
michael@0 14873 HEAP32[i60 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 14874 HEAP32[i60 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 14875 HEAP32[i60 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 14876 i6 = i3;
michael@0 14877 i60 = i3;
michael@0 14878 d85 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i60 >> 2] | 0) + 44 >> 2] & 7](i6);
michael@0 14879 d84 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i60 >> 2] | 0) + 44 >> 2] & 7](i6);
michael@0 14880 d83 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i60 >> 2] | 0) + 44 >> 2] & 7](i6);
michael@0 14881 i6 = i7 | 0;
michael@0 14882 d82 = d85 + +HEAPF32[i6 >> 2];
michael@0 14883 HEAPF32[i6 >> 2] = d82;
michael@0 14884 i6 = i7 + 4 | 0;
michael@0 14885 d85 = d84 + +HEAPF32[i6 >> 2];
michael@0 14886 HEAPF32[i6 >> 2] = d85;
michael@0 14887 i6 = i7 + 8 | 0;
michael@0 14888 d84 = d83 + +HEAPF32[i6 >> 2];
michael@0 14889 HEAPF32[i6 >> 2] = d84;
michael@0 14890 i6 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 14891 i60 = HEAP32[(HEAP32[i6 >> 2] | 0) + 72 >> 2] | 0;
michael@0 14892 HEAPF32[i8 >> 2] = -0.0 - d82;
michael@0 14893 HEAPF32[i8 + 4 >> 2] = -0.0 - d85;
michael@0 14894 HEAPF32[i8 + 8 >> 2] = -0.0 - d84;
michael@0 14895 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 14896 FUNCTION_TABLE_viiiii[i60 & 63](i6, i8, i7, i2, i4);
michael@0 14897 STACKTOP = i5;
michael@0 14898 return;
michael@0 14899 }
michael@0 14900 case 8:
michael@0 14901 {
michael@0 14902 d84 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i3 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 14903 i7 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 14904 FUNCTION_TABLE_vifii[HEAP32[(HEAP32[i7 >> 2] | 0) + 16 >> 2] & 1](i7, d84, i2, i4);
michael@0 14905 STACKTOP = i5;
michael@0 14906 return;
michael@0 14907 }
michael@0 14908 case 9:
michael@0 14909 {
michael@0 14910 i7 = HEAP32[i3 + 92 >> 2] | 0;
michael@0 14911 if ((i7 | 0) <= 0) {
michael@0 14912 STACKTOP = i5;
michael@0 14913 return;
michael@0 14914 }
michael@0 14915 i8 = i3 + 100 | 0;
michael@0 14916 i6 = i3 + 120 | 0;
michael@0 14917 i60 = i2 | 0;
michael@0 14918 i59 = i2 + 4 | 0;
michael@0 14919 i58 = i2 + 8 | 0;
michael@0 14920 i57 = i2 + 16 | 0;
michael@0 14921 i56 = i2 + 20 | 0;
michael@0 14922 i55 = i2 + 24 | 0;
michael@0 14923 i54 = i2 + 32 | 0;
michael@0 14924 i53 = i2 + 36 | 0;
michael@0 14925 i52 = i2 + 40 | 0;
michael@0 14926 i51 = i2 + 48 | 0;
michael@0 14927 i50 = i2 + 52 | 0;
michael@0 14928 i49 = i2 + 56 | 0;
michael@0 14929 i48 = i9 | 0;
michael@0 14930 i47 = i9 + 4 | 0;
michael@0 14931 i46 = i9 + 8 | 0;
michael@0 14932 i45 = i9 + 12 | 0;
michael@0 14933 i44 = i9 + 16 | 0;
michael@0 14934 i43 = i9 + 20 | 0;
michael@0 14935 i42 = i9 + 24 | 0;
michael@0 14936 i41 = i9 + 28 | 0;
michael@0 14937 i40 = i9 + 32 | 0;
michael@0 14938 i39 = i9 + 36 | 0;
michael@0 14939 i38 = i9 + 40 | 0;
michael@0 14940 i37 = i9 + 44 | 0;
michael@0 14941 i36 = i9 + 48 | 0;
michael@0 14942 i35 = i9 + 52 | 0;
michael@0 14943 i34 = i9 + 56 | 0;
michael@0 14944 i33 = i9 + 60 | 0;
michael@0 14945 i32 = i7;
michael@0 14946 do {
michael@0 14947 i32 = i32 - 1 | 0;
michael@0 14948 i7 = HEAP32[i8 >> 2] | 0;
michael@0 14949 d84 = +HEAPF32[i7 + (i32 << 4) >> 2];
michael@0 14950 d85 = +HEAPF32[i7 + (i32 << 4) + 4 >> 2];
michael@0 14951 d82 = +HEAPF32[i7 + (i32 << 4) + 8 >> 2];
michael@0 14952 i7 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 14953 i31 = HEAP32[(HEAP32[i7 >> 2] | 0) + 16 >> 2] | 0;
michael@0 14954 d83 = +HEAPF32[(HEAP32[i6 >> 2] | 0) + (i32 << 2) >> 2];
michael@0 14955 d69 = +HEAPF32[i60 >> 2];
michael@0 14956 d81 = +HEAPF32[i59 >> 2];
michael@0 14957 d66 = d81 * 0.0;
michael@0 14958 d80 = +HEAPF32[i58 >> 2];
michael@0 14959 d63 = d80 * 0.0;
michael@0 14960 d68 = d69 * 0.0;
michael@0 14961 d65 = +HEAPF32[i57 >> 2];
michael@0 14962 d62 = +HEAPF32[i56 >> 2];
michael@0 14963 d67 = d62 * 0.0;
michael@0 14964 d64 = +HEAPF32[i55 >> 2];
michael@0 14965 d61 = d64 * 0.0;
michael@0 14966 d79 = d65 * 0.0;
michael@0 14967 d78 = +HEAPF32[i54 >> 2];
michael@0 14968 d77 = +HEAPF32[i53 >> 2];
michael@0 14969 d76 = d77 * 0.0;
michael@0 14970 d75 = +HEAPF32[i52 >> 2];
michael@0 14971 d74 = d75 * 0.0;
michael@0 14972 d72 = d78 * 0.0;
michael@0 14973 d71 = d84 * d69 + d85 * d81 + d82 * d80 + +HEAPF32[i51 >> 2];
michael@0 14974 d70 = d84 * d65 + d85 * d62 + d82 * d64 + +HEAPF32[i50 >> 2];
michael@0 14975 d86 = d84 * d78 + d85 * d77 + d82 * d75 + +HEAPF32[i49 >> 2];
michael@0 14976 HEAPF32[i48 >> 2] = d69 + d66 + d63;
michael@0 14977 HEAPF32[i47 >> 2] = d68 + d81 + d63;
michael@0 14978 HEAPF32[i46 >> 2] = d80 + (d68 + d66);
michael@0 14979 HEAPF32[i45 >> 2] = 0.0;
michael@0 14980 HEAPF32[i44 >> 2] = d65 + d67 + d61;
michael@0 14981 HEAPF32[i43 >> 2] = d79 + d62 + d61;
michael@0 14982 HEAPF32[i42 >> 2] = d64 + (d79 + d67);
michael@0 14983 HEAPF32[i41 >> 2] = 0.0;
michael@0 14984 HEAPF32[i40 >> 2] = d78 + d76 + d74;
michael@0 14985 HEAPF32[i39 >> 2] = d72 + d77 + d74;
michael@0 14986 HEAPF32[i38 >> 2] = d75 + (d72 + d76);
michael@0 14987 HEAPF32[i37 >> 2] = 0.0;
michael@0 14988 HEAPF32[i36 >> 2] = d71;
michael@0 14989 HEAPF32[i35 >> 2] = d70;
michael@0 14990 HEAPF32[i34 >> 2] = d86;
michael@0 14991 HEAPF32[i33 >> 2] = 0.0;
michael@0 14992 FUNCTION_TABLE_vifii[i31 & 1](i7, d83, i9, i4);
michael@0 14993 } while ((i32 | 0) > 0);
michael@0 14994 STACKTOP = i5;
michael@0 14995 return;
michael@0 14996 }
michael@0 14997 case 11:
michael@0 14998 {
michael@0 14999 d83 = +HEAPF32[i3 + 56 >> 2];
michael@0 15000 d86 = +HEAPF32[i3 + 60 >> 2];
michael@0 15001 i32 = HEAP32[i3 + 68 >> 2] | 0;
michael@0 15002 i9 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15003 FUNCTION_TABLE_viffiii[HEAP32[(HEAP32[i9 >> 2] | 0) + 84 >> 2] & 1](i9, d83, d86, i32, i2, i4);
michael@0 15004 STACKTOP = i5;
michael@0 15005 return;
michael@0 15006 }
michael@0 15007 case 10:
michael@0 15008 {
michael@0 15009 i32 = i3;
michael@0 15010 i9 = HEAP32[i3 + 52 >> 2] | 0;
michael@0 15011 d86 = +HEAPF32[i32 + 28 + (((i9 + 2 | 0) % 3 | 0) << 2) >> 2];
michael@0 15012 d83 = +HEAPF32[i32 + 28 + (i9 << 2) >> 2];
michael@0 15013 i32 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15014 FUNCTION_TABLE_viffiii[HEAP32[(HEAP32[i32 >> 2] | 0) + 76 >> 2] & 1](i32, d86, d83, i9, i2, i4);
michael@0 15015 STACKTOP = i5;
michael@0 15016 return;
michael@0 15017 }
michael@0 15018 case 13:
michael@0 15019 {
michael@0 15020 i9 = HEAP32[i3 + 52 >> 2] | 0;
michael@0 15021 d83 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i3 >> 2] | 0) + 84 >> 2] & 7](i3);
michael@0 15022 i32 = i10;
michael@0 15023 i33 = i3 + 28 | 0;
michael@0 15024 HEAP32[i32 >> 2] = HEAP32[i33 >> 2];
michael@0 15025 HEAP32[i32 + 4 >> 2] = HEAP32[i33 + 4 >> 2];
michael@0 15026 HEAP32[i32 + 8 >> 2] = HEAP32[i33 + 8 >> 2];
michael@0 15027 HEAP32[i32 + 12 >> 2] = HEAP32[i33 + 12 >> 2];
michael@0 15028 i33 = i3;
michael@0 15029 i32 = i3;
michael@0 15030 d86 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i32 >> 2] | 0) + 44 >> 2] & 7](i33);
michael@0 15031 d70 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i32 >> 2] | 0) + 44 >> 2] & 7](i33);
michael@0 15032 d71 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i32 >> 2] | 0) + 44 >> 2] & 7](i33);
michael@0 15033 i33 = i10 | 0;
michael@0 15034 HEAPF32[i33 >> 2] = d86 + +HEAPF32[i33 >> 2];
michael@0 15035 i33 = i10 + 4 | 0;
michael@0 15036 HEAPF32[i33 >> 2] = d70 + +HEAPF32[i33 >> 2];
michael@0 15037 i33 = i10 + 8 | 0;
michael@0 15038 HEAPF32[i33 >> 2] = d71 + +HEAPF32[i33 >> 2];
michael@0 15039 d71 = +HEAPF32[i10 + (i9 << 2) >> 2];
michael@0 15040 i10 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15041 FUNCTION_TABLE_viffiii[HEAP32[(HEAP32[i10 >> 2] | 0) + 80 >> 2] & 1](i10, d83, d71, i9, i2, i4);
michael@0 15042 STACKTOP = i5;
michael@0 15043 return;
michael@0 15044 }
michael@0 15045 case 28:
michael@0 15046 {
michael@0 15047 d71 = +HEAPF32[i3 + 64 >> 2];
michael@0 15048 i9 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15049 FUNCTION_TABLE_viifii[HEAP32[(HEAP32[i9 >> 2] | 0) + 88 >> 2] & 1](i9, i3 + 48 | 0, d71, i2, i4);
michael@0 15050 STACKTOP = i5;
michael@0 15051 return;
michael@0 15052 }
michael@0 15053 default:
michael@0 15054 {
michael@0 15055 if ((i28 - 21 | 0) >>> 0 < 9) {
michael@0 15056 HEAPF32[i11 >> 2] = 999999984306749400.0;
michael@0 15057 HEAPF32[i11 + 4 >> 2] = 999999984306749400.0;
michael@0 15058 HEAPF32[i11 + 8 >> 2] = 999999984306749400.0;
michael@0 15059 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 15060 HEAPF32[i12 >> 2] = -999999984306749400.0;
michael@0 15061 HEAPF32[i12 + 4 >> 2] = -999999984306749400.0;
michael@0 15062 HEAPF32[i12 + 8 >> 2] = -999999984306749400.0;
michael@0 15063 HEAPF32[i12 + 12 >> 2] = 0.0;
michael@0 15064 i9 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15065 HEAP32[i13 >> 2] = 4216;
michael@0 15066 HEAP32[i13 + 4 >> 2] = 4240;
michael@0 15067 HEAP32[i13 + 8 >> 2] = i9;
michael@0 15068 i9 = i13 + 12 | 0;
michael@0 15069 i10 = i4;
michael@0 15070 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 15071 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 15072 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 15073 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 15074 i10 = i13 + 28 | 0;
michael@0 15075 i9 = i2;
michael@0 15076 HEAP32[i10 >> 2] = HEAP32[i9 >> 2];
michael@0 15077 HEAP32[i10 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 15078 HEAP32[i10 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 15079 HEAP32[i10 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 15080 i9 = i13 + 44 | 0;
michael@0 15081 i10 = i2 + 16 | 0;
michael@0 15082 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 15083 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 15084 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 15085 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 15086 i10 = i13 + 60 | 0;
michael@0 15087 i9 = i2 + 32 | 0;
michael@0 15088 HEAP32[i10 >> 2] = HEAP32[i9 >> 2];
michael@0 15089 HEAP32[i10 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 15090 HEAP32[i10 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 15091 HEAP32[i10 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 15092 i9 = i13 + 76 | 0;
michael@0 15093 i10 = i2 + 48 | 0;
michael@0 15094 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 15095 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 15096 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 15097 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 15098 i10 = i13 | 0;
michael@0 15099 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i3 >> 2] | 0) + 60 >> 2] & 127](i3, i10, i12, i11);
michael@0 15100 __ZN31btInternalTriangleIndexCallbackD2Ev(i13 + 4 | 0);
michael@0 15101 __ZN18btTriangleCallbackD2Ev(i10);
michael@0 15102 i87 = HEAP32[i27 >> 2] | 0;
michael@0 15103 } else {
michael@0 15104 i87 = i28;
michael@0 15105 }
michael@0 15106 if ((i87 | 0) == 3) {
michael@0 15107 HEAPF32[i14 >> 2] = 999999984306749400.0;
michael@0 15108 HEAPF32[i14 + 4 >> 2] = 999999984306749400.0;
michael@0 15109 HEAPF32[i14 + 8 >> 2] = 999999984306749400.0;
michael@0 15110 HEAPF32[i14 + 12 >> 2] = 0.0;
michael@0 15111 HEAPF32[i15 >> 2] = -999999984306749400.0;
michael@0 15112 HEAPF32[i15 + 4 >> 2] = -999999984306749400.0;
michael@0 15113 HEAPF32[i15 + 8 >> 2] = -999999984306749400.0;
michael@0 15114 HEAPF32[i15 + 12 >> 2] = 0.0;
michael@0 15115 i28 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15116 HEAP32[i16 >> 2] = 4216;
michael@0 15117 HEAP32[i16 + 4 >> 2] = 4240;
michael@0 15118 HEAP32[i16 + 8 >> 2] = i28;
michael@0 15119 i28 = i16 + 12 | 0;
michael@0 15120 i10 = i4;
michael@0 15121 HEAP32[i28 >> 2] = HEAP32[i10 >> 2];
michael@0 15122 HEAP32[i28 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 15123 HEAP32[i28 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 15124 HEAP32[i28 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 15125 i10 = i16 + 28 | 0;
michael@0 15126 i28 = i2;
michael@0 15127 HEAP32[i10 >> 2] = HEAP32[i28 >> 2];
michael@0 15128 HEAP32[i10 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 15129 HEAP32[i10 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 15130 HEAP32[i10 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 15131 i28 = i16 + 44 | 0;
michael@0 15132 i10 = i2 + 16 | 0;
michael@0 15133 HEAP32[i28 >> 2] = HEAP32[i10 >> 2];
michael@0 15134 HEAP32[i28 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 15135 HEAP32[i28 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 15136 HEAP32[i28 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 15137 i10 = i16 + 60 | 0;
michael@0 15138 i28 = i2 + 32 | 0;
michael@0 15139 HEAP32[i10 >> 2] = HEAP32[i28 >> 2];
michael@0 15140 HEAP32[i10 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 15141 HEAP32[i10 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 15142 HEAP32[i10 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 15143 i28 = i16 + 76 | 0;
michael@0 15144 i10 = i2 + 48 | 0;
michael@0 15145 HEAP32[i28 >> 2] = HEAP32[i10 >> 2];
michael@0 15146 HEAP32[i28 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 15147 HEAP32[i28 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 15148 HEAP32[i28 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 15149 i10 = HEAP32[i3 + 92 >> 2] | 0;
michael@0 15150 i28 = i16 + 4 | 0;
michael@0 15151 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i10 >> 2] | 0) + 8 >> 2] & 127](i10, i28, i15, i14);
michael@0 15152 __ZN31btInternalTriangleIndexCallbackD2Ev(i28);
michael@0 15153 __ZN18btTriangleCallbackD2Ev(i16 | 0);
michael@0 15154 i88 = HEAP32[i27 >> 2] | 0;
michael@0 15155 } else {
michael@0 15156 i88 = i87;
michael@0 15157 }
michael@0 15158 if ((i88 | 0) >= 7) {
michael@0 15159 STACKTOP = i5;
michael@0 15160 return;
michael@0 15161 }
michael@0 15162 i88 = i3;
michael@0 15163 i87 = HEAP32[i3 + 52 >> 2] | 0;
michael@0 15164 if ((i87 | 0) == 0) {
michael@0 15165 i27 = i3;
michael@0 15166 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i27 >> 2] | 0) + 92 >> 2] & 127](i88) | 0) <= 0) {
michael@0 15167 STACKTOP = i5;
michael@0 15168 return;
michael@0 15169 }
michael@0 15170 i16 = i3;
michael@0 15171 i3 = i2 | 0;
michael@0 15172 i28 = i22 | 0;
michael@0 15173 i14 = i2 + 4 | 0;
michael@0 15174 i15 = i22 + 4 | 0;
michael@0 15175 i10 = i2 + 8 | 0;
michael@0 15176 i13 = i22 + 8 | 0;
michael@0 15177 i11 = i2 + 48 | 0;
michael@0 15178 i12 = i2 + 16 | 0;
michael@0 15179 i9 = i2 + 20 | 0;
michael@0 15180 i33 = i2 + 24 | 0;
michael@0 15181 i32 = i2 + 52 | 0;
michael@0 15182 i34 = i2 + 32 | 0;
michael@0 15183 i35 = i2 + 36 | 0;
michael@0 15184 i36 = i2 + 40 | 0;
michael@0 15185 i37 = i2 + 56 | 0;
michael@0 15186 i38 = i24 | 0;
michael@0 15187 i39 = i24 + 4 | 0;
michael@0 15188 i40 = i24 + 8 | 0;
michael@0 15189 i41 = i24 + 12 | 0;
michael@0 15190 i42 = i23 | 0;
michael@0 15191 i43 = i23 + 4 | 0;
michael@0 15192 i44 = i23 + 8 | 0;
michael@0 15193 i45 = i25 | 0;
michael@0 15194 i46 = i25 + 4 | 0;
michael@0 15195 i47 = i25 + 8 | 0;
michael@0 15196 i48 = i25 + 12 | 0;
michael@0 15197 i49 = 0;
michael@0 15198 do {
michael@0 15199 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i16 >> 2] | 0) + 96 >> 2] & 127](i88, i49, i22, i23);
michael@0 15200 d71 = +HEAPF32[i3 >> 2];
michael@0 15201 d83 = +HEAPF32[i28 >> 2];
michael@0 15202 d70 = +HEAPF32[i14 >> 2];
michael@0 15203 d86 = +HEAPF32[i15 >> 2];
michael@0 15204 d76 = +HEAPF32[i10 >> 2];
michael@0 15205 d72 = +HEAPF32[i13 >> 2];
michael@0 15206 d75 = +HEAPF32[i11 >> 2];
michael@0 15207 d74 = +HEAPF32[i12 >> 2];
michael@0 15208 d77 = +HEAPF32[i9 >> 2];
michael@0 15209 d78 = +HEAPF32[i33 >> 2];
michael@0 15210 d67 = +HEAPF32[i32 >> 2];
michael@0 15211 d79 = +HEAPF32[i34 >> 2];
michael@0 15212 d64 = +HEAPF32[i35 >> 2];
michael@0 15213 d61 = +HEAPF32[i36 >> 2];
michael@0 15214 d62 = +HEAPF32[i37 >> 2];
michael@0 15215 HEAPF32[i38 >> 2] = d75 + (d71 * d83 + d70 * d86 + d76 * d72);
michael@0 15216 HEAPF32[i39 >> 2] = d67 + (d83 * d74 + d86 * d77 + d72 * d78);
michael@0 15217 HEAPF32[i40 >> 2] = d62 + (d83 * d79 + d86 * d64 + d72 * d61);
michael@0 15218 HEAPF32[i41 >> 2] = 0.0;
michael@0 15219 d72 = +HEAPF32[i42 >> 2];
michael@0 15220 d86 = +HEAPF32[i43 >> 2];
michael@0 15221 d83 = +HEAPF32[i44 >> 2];
michael@0 15222 HEAPF32[i45 >> 2] = d75 + (d71 * d72 + d70 * d86 + d76 * d83);
michael@0 15223 HEAPF32[i46 >> 2] = d67 + (d74 * d72 + d77 * d86 + d78 * d83);
michael@0 15224 HEAPF32[i47 >> 2] = d62 + (d79 * d72 + d64 * d86 + d61 * d83);
michael@0 15225 HEAPF32[i48 >> 2] = 0.0;
michael@0 15226 i50 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15227 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i50 >> 2] | 0) + 8 >> 2] & 127](i50, i24, i25, i4);
michael@0 15228 i49 = i49 + 1 | 0;
michael@0 15229 } while ((i49 | 0) < (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i27 >> 2] | 0) + 92 >> 2] & 127](i88) | 0));
michael@0 15230 STACKTOP = i5;
michael@0 15231 return;
michael@0 15232 }
michael@0 15233 i88 = i87 + 28 | 0;
michael@0 15234 if ((HEAP32[i88 >> 2] | 0) <= 0) {
michael@0 15235 STACKTOP = i5;
michael@0 15236 return;
michael@0 15237 }
michael@0 15238 i27 = i87 + 36 | 0;
michael@0 15239 i49 = i19 | 0;
michael@0 15240 i25 = i19 + 4 | 0;
michael@0 15241 i24 = i19 + 8 | 0;
michael@0 15242 i48 = i19 + 12 | 0;
michael@0 15243 i47 = i2 | 0;
michael@0 15244 i46 = i2 + 4 | 0;
michael@0 15245 i45 = i2 + 8 | 0;
michael@0 15246 i44 = i2 + 48 | 0;
michael@0 15247 i43 = i2 + 16 | 0;
michael@0 15248 i42 = i2 + 20 | 0;
michael@0 15249 i41 = i2 + 24 | 0;
michael@0 15250 i40 = i2 + 52 | 0;
michael@0 15251 i39 = i2 + 32 | 0;
michael@0 15252 i38 = i2 + 36 | 0;
michael@0 15253 i37 = i2 + 40 | 0;
michael@0 15254 i36 = i2 + 56 | 0;
michael@0 15255 i2 = i20 | 0;
michael@0 15256 i35 = i20 + 4 | 0;
michael@0 15257 i34 = i20 + 8 | 0;
michael@0 15258 i32 = i20 + 12 | 0;
michael@0 15259 i33 = i21 | 0;
michael@0 15260 i9 = i21 + 4 | 0;
michael@0 15261 i12 = i21 + 8 | 0;
michael@0 15262 i11 = i21 + 12 | 0;
michael@0 15263 i13 = i87 + 16 | 0;
michael@0 15264 i87 = i17 | 0;
michael@0 15265 i10 = i17 + 4 | 0;
michael@0 15266 i15 = i17 + 8 | 0;
michael@0 15267 i14 = i17 + 12 | 0;
michael@0 15268 i28 = i18 | 0;
michael@0 15269 i3 = i18 + 4 | 0;
michael@0 15270 i23 = i18 + 8 | 0;
michael@0 15271 i22 = i18 + 12 | 0;
michael@0 15272 i16 = 0;
michael@0 15273 do {
michael@0 15274 i50 = HEAP32[i27 >> 2] | 0;
michael@0 15275 i51 = HEAP32[i50 + (i16 * 56 | 0) + 4 >> 2] | 0;
michael@0 15276 L252 : do {
michael@0 15277 if ((i51 | 0) > 0) {
michael@0 15278 i52 = HEAP32[i50 + (i16 * 56 | 0) + 12 >> 2] | 0;
michael@0 15279 d83 = 0.0;
michael@0 15280 d61 = 0.0;
michael@0 15281 d86 = 0.0;
michael@0 15282 i53 = HEAP32[i52 + (i51 - 1 << 2) >> 2] | 0;
michael@0 15283 i54 = 0;
michael@0 15284 i55 = i52;
michael@0 15285 while (1) {
michael@0 15286 i52 = HEAP32[i55 + (i54 << 2) >> 2] | 0;
michael@0 15287 i56 = HEAP32[i13 >> 2] | 0;
michael@0 15288 d64 = d86 + +HEAPF32[i56 + (i52 << 4) >> 2];
michael@0 15289 d72 = d61 + +HEAPF32[i56 + (i52 << 4) + 4 >> 2];
michael@0 15290 d79 = d83 + +HEAPF32[i56 + (i52 << 4) + 8 >> 2];
michael@0 15291 i56 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15292 i57 = HEAP32[(HEAP32[i56 >> 2] | 0) + 8 >> 2] | 0;
michael@0 15293 i58 = HEAP32[i13 >> 2] | 0;
michael@0 15294 d62 = +HEAPF32[i47 >> 2];
michael@0 15295 d78 = +HEAPF32[i58 + (i53 << 4) >> 2];
michael@0 15296 d77 = +HEAPF32[i46 >> 2];
michael@0 15297 d74 = +HEAPF32[i58 + (i53 << 4) + 4 >> 2];
michael@0 15298 d67 = +HEAPF32[i45 >> 2];
michael@0 15299 d76 = +HEAPF32[i58 + (i53 << 4) + 8 >> 2];
michael@0 15300 d70 = +HEAPF32[i44 >> 2];
michael@0 15301 d71 = +HEAPF32[i43 >> 2];
michael@0 15302 d75 = +HEAPF32[i42 >> 2];
michael@0 15303 d65 = +HEAPF32[i41 >> 2];
michael@0 15304 d66 = +HEAPF32[i40 >> 2];
michael@0 15305 d68 = +HEAPF32[i39 >> 2];
michael@0 15306 d80 = +HEAPF32[i38 >> 2];
michael@0 15307 d63 = +HEAPF32[i37 >> 2];
michael@0 15308 d81 = +HEAPF32[i36 >> 2];
michael@0 15309 HEAPF32[i87 >> 2] = d70 + (d62 * d78 + d77 * d74 + d67 * d76);
michael@0 15310 HEAPF32[i10 >> 2] = d66 + (d78 * d71 + d74 * d75 + d76 * d65);
michael@0 15311 HEAPF32[i15 >> 2] = d81 + (d78 * d68 + d74 * d80 + d76 * d63);
michael@0 15312 HEAPF32[i14 >> 2] = 0.0;
michael@0 15313 d76 = +HEAPF32[i58 + (i52 << 4) >> 2];
michael@0 15314 d74 = +HEAPF32[i58 + (i52 << 4) + 4 >> 2];
michael@0 15315 d78 = +HEAPF32[i58 + (i52 << 4) + 8 >> 2];
michael@0 15316 HEAPF32[i28 >> 2] = d70 + (d62 * d76 + d77 * d74 + d67 * d78);
michael@0 15317 HEAPF32[i3 >> 2] = d66 + (d71 * d76 + d75 * d74 + d65 * d78);
michael@0 15318 HEAPF32[i23 >> 2] = d81 + (d68 * d76 + d80 * d74 + d63 * d78);
michael@0 15319 HEAPF32[i22 >> 2] = 0.0;
michael@0 15320 FUNCTION_TABLE_viiii[i57 & 127](i56, i17, i18, i4);
michael@0 15321 i56 = i54 + 1 | 0;
michael@0 15322 i57 = HEAP32[i27 >> 2] | 0;
michael@0 15323 if ((i56 | 0) >= (HEAP32[i57 + (i16 * 56 | 0) + 4 >> 2] | 0)) {
michael@0 15324 d89 = d64;
michael@0 15325 d90 = d72;
michael@0 15326 d91 = d79;
michael@0 15327 i92 = i57;
michael@0 15328 break L252;
michael@0 15329 }
michael@0 15330 d83 = d79;
michael@0 15331 d61 = d72;
michael@0 15332 d86 = d64;
michael@0 15333 i53 = i52;
michael@0 15334 i54 = i56;
michael@0 15335 i55 = HEAP32[i57 + (i16 * 56 | 0) + 12 >> 2] | 0;
michael@0 15336 }
michael@0 15337 } else {
michael@0 15338 d89 = 0.0;
michael@0 15339 d90 = 0.0;
michael@0 15340 d91 = 0.0;
michael@0 15341 i92 = i50;
michael@0 15342 }
michael@0 15343 } while (0);
michael@0 15344 d86 = 1.0 / +(i51 | 0);
michael@0 15345 d61 = d89 * d86;
michael@0 15346 d83 = d90 * d86;
michael@0 15347 d64 = d91 * d86;
michael@0 15348 HEAPF32[i49 >> 2] = 1.0;
michael@0 15349 HEAPF32[i25 >> 2] = 1.0;
michael@0 15350 HEAPF32[i24 >> 2] = 0.0;
michael@0 15351 HEAPF32[i48 >> 2] = 0.0;
michael@0 15352 d86 = +HEAPF32[i92 + (i16 * 56 | 0) + 40 >> 2];
michael@0 15353 d72 = +HEAPF32[i92 + (i16 * 56 | 0) + 44 >> 2];
michael@0 15354 d79 = +HEAPF32[i92 + (i16 * 56 | 0) + 48 >> 2];
michael@0 15355 i50 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i26 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 15356 i55 = HEAP32[(HEAP32[i50 >> 2] | 0) + 8 >> 2] | 0;
michael@0 15357 d78 = +HEAPF32[i47 >> 2];
michael@0 15358 d63 = +HEAPF32[i46 >> 2];
michael@0 15359 d74 = +HEAPF32[i45 >> 2];
michael@0 15360 d80 = +HEAPF32[i44 >> 2];
michael@0 15361 d76 = +HEAPF32[i43 >> 2];
michael@0 15362 d68 = +HEAPF32[i42 >> 2];
michael@0 15363 d81 = +HEAPF32[i41 >> 2];
michael@0 15364 d65 = +HEAPF32[i40 >> 2];
michael@0 15365 d75 = +HEAPF32[i39 >> 2];
michael@0 15366 d71 = +HEAPF32[i38 >> 2];
michael@0 15367 d66 = +HEAPF32[i37 >> 2];
michael@0 15368 d67 = +HEAPF32[i36 >> 2];
michael@0 15369 HEAPF32[i2 >> 2] = d80 + (d61 * d78 + d83 * d63 + d64 * d74);
michael@0 15370 HEAPF32[i35 >> 2] = d65 + (d61 * d76 + d83 * d68 + d64 * d81);
michael@0 15371 HEAPF32[i34 >> 2] = d67 + (d61 * d75 + d83 * d71 + d64 * d66);
michael@0 15372 HEAPF32[i32 >> 2] = 0.0;
michael@0 15373 d77 = d61 + d86;
michael@0 15374 d86 = d83 + d72;
michael@0 15375 d72 = d64 + d79;
michael@0 15376 HEAPF32[i33 >> 2] = d80 + (d77 * d78 + d86 * d63 + d72 * d74);
michael@0 15377 HEAPF32[i9 >> 2] = d65 + (d77 * d76 + d86 * d68 + d72 * d81);
michael@0 15378 HEAPF32[i12 >> 2] = d67 + (d77 * d75 + d86 * d71 + d72 * d66);
michael@0 15379 HEAPF32[i11 >> 2] = 0.0;
michael@0 15380 FUNCTION_TABLE_viiii[i55 & 127](i50, i20, i21, i19);
michael@0 15381 i16 = i16 + 1 | 0;
michael@0 15382 } while ((i16 | 0) < (HEAP32[i88 >> 2] | 0));
michael@0 15383 STACKTOP = i5;
michael@0 15384 return;
michael@0 15385 }
michael@0 15386 }
michael@0 15387 }
michael@0 15388 function __ZN20btConvexHullInternal6shrinkEff(i1, d2, d3) {
michael@0 15389 i1 = i1 | 0;
michael@0 15390 d2 = +d2;
michael@0 15391 d3 = +d3;
michael@0 15392 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, d15 = 0.0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0, i88 = 0, i89 = 0, i90 = 0, i91 = 0, i92 = 0, i93 = 0, i94 = 0, i95 = 0, i96 = 0, i97 = 0, i98 = 0, i99 = 0, i100 = 0, i101 = 0, i102 = 0, i103 = 0, i104 = 0, i105 = 0, i106 = 0, i107 = 0, i108 = 0, i109 = 0, i110 = 0, i111 = 0, i112 = 0, i113 = 0, i114 = 0, i115 = 0, i116 = 0, i117 = 0, i118 = 0, i119 = 0, i120 = 0, i121 = 0, i122 = 0, i123 = 0, i124 = 0, i125 = 0, i126 = 0, i127 = 0, i128 = 0, i129 = 0, i130 = 0, i131 = 0, i132 = 0, i133 = 0, i134 = 0, i135 = 0, i136 = 0, i137 = 0, i138 = 0, i139 = 0, i140 = 0, i141 = 0, i142 = 0, i143 = 0, i144 = 0, i145 = 0, i146 = 0, i147 = 0, i148 = 0, i149 = 0, i150 = 0, i151 = 0, i152 = 0, i153 = 0, i154 = 0, i155 = 0, i156 = 0, i157 = 0, i158 = 0, i159 = 0, i160 = 0, i161 = 0, i162 = 0, i163 = 0, i164 = 0, i165 = 0, i166 = 0, i167 = 0, i168 = 0, i169 = 0, i170 = 0, i171 = 0, i172 = 0, d173 = 0.0, d174 = 0.0, d175 = 0.0, d176 = 0.0, d177 = 0.0, d178 = 0.0, d179 = 0.0, d180 = 0.0;
michael@0 15393 i4 = STACKTOP;
michael@0 15394 STACKTOP = STACKTOP + 136 | 0;
michael@0 15395 i5 = i4 | 0;
michael@0 15396 i6 = i4 + 16 | 0;
michael@0 15397 i7 = i4 + 32 | 0;
michael@0 15398 i8 = i4 + 48 | 0;
michael@0 15399 i9 = i4 + 64 | 0;
michael@0 15400 i10 = i4 + 80 | 0;
michael@0 15401 i11 = i4 + 96 | 0;
michael@0 15402 i12 = i4 + 112 | 0;
michael@0 15403 i13 = i1 + 124 | 0;
michael@0 15404 i14 = HEAP32[i13 >> 2] | 0;
michael@0 15405 if ((i14 | 0) == 0) {
michael@0 15406 d15 = 0.0;
michael@0 15407 STACKTOP = i4;
michael@0 15408 return +d15;
michael@0 15409 }
michael@0 15410 i16 = i1 + 100 | 0;
michael@0 15411 i17 = (HEAP32[i16 >> 2] | 0) - 1 | 0;
michael@0 15412 HEAP32[i16 >> 2] = i17;
michael@0 15413 HEAP32[i14 + 104 >> 2] = i17;
michael@0 15414 i14 = __Z22btAlignedAllocInternalji(4, 16) | 0;
michael@0 15415 i16 = i14;
michael@0 15416 if ((i14 | 0) != 0) {
michael@0 15417 HEAP32[i16 >> 2] = HEAP32[i13 >> 2];
michael@0 15418 }
michael@0 15419 i14 = HEAP32[i13 >> 2] | 0;
michael@0 15420 i13 = HEAP32[i14 + 88 >> 2] | 0;
michael@0 15421 i18 = HEAP32[i14 + 92 >> 2] | 0;
michael@0 15422 i19 = HEAP32[i14 + 96 >> 2] | 0;
michael@0 15423 i14 = i6 | 0;
michael@0 15424 i20 = i6 + 8 | 0;
michael@0 15425 i21 = i7 | 0;
michael@0 15426 _memset(i6 | 0, 0, 16);
michael@0 15427 i22 = i7 + 8 | 0;
michael@0 15428 i23 = i8 | 0;
michael@0 15429 _memset(i7 | 0, 0, 16);
michael@0 15430 i24 = i8 + 8 | 0;
michael@0 15431 i25 = i9 | 0;
michael@0 15432 _memset(i8 | 0, 0, 16);
michael@0 15433 i26 = i9 + 8 | 0;
michael@0 15434 i27 = i1 + 64 | 0;
michael@0 15435 _memset(i9 | 0, 0, 16);
michael@0 15436 i28 = 0;
michael@0 15437 i29 = 0;
michael@0 15438 i30 = 0;
michael@0 15439 i31 = 1;
michael@0 15440 i32 = 1;
michael@0 15441 i33 = i16;
michael@0 15442 i16 = 0;
michael@0 15443 i34 = 0;
michael@0 15444 i35 = 0;
michael@0 15445 i36 = 0;
michael@0 15446 i37 = 0;
michael@0 15447 i38 = 0;
michael@0 15448 i39 = 0;
michael@0 15449 i40 = 0;
michael@0 15450 i41 = 0;
michael@0 15451 i42 = 0;
michael@0 15452 i43 = 0;
michael@0 15453 i44 = 0;
michael@0 15454 i45 = 0;
michael@0 15455 i46 = 0;
michael@0 15456 i47 = 0;
michael@0 15457 i48 = 0;
michael@0 15458 L1498 : while (1) {
michael@0 15459 i49 = i31;
michael@0 15460 while (1) {
michael@0 15461 if ((i49 | 0) <= 0) {
michael@0 15462 break L1498;
michael@0 15463 }
michael@0 15464 i50 = i49 - 1 | 0;
michael@0 15465 i51 = HEAP32[i33 + (i50 << 2) >> 2] | 0;
michael@0 15466 i52 = i51 + 8 | 0;
michael@0 15467 i53 = HEAP32[i52 >> 2] | 0;
michael@0 15468 if ((i53 | 0) == 0) {
michael@0 15469 i49 = i50;
michael@0 15470 } else {
michael@0 15471 break;
michael@0 15472 }
michael@0 15473 }
michael@0 15474 i54 = i51 + 88 | 0;
michael@0 15475 i55 = i51 + 92 | 0;
michael@0 15476 i56 = i51 + 96 | 0;
michael@0 15477 i57 = i53;
michael@0 15478 i58 = i28;
michael@0 15479 i59 = i29;
michael@0 15480 i60 = i30;
michael@0 15481 i61 = i50;
michael@0 15482 i62 = i32;
michael@0 15483 i63 = i33;
michael@0 15484 i64 = i16;
michael@0 15485 i65 = i34;
michael@0 15486 i66 = i35;
michael@0 15487 i67 = i36;
michael@0 15488 i68 = i37;
michael@0 15489 i69 = i38;
michael@0 15490 i70 = i39;
michael@0 15491 i71 = i40;
michael@0 15492 i72 = i41;
michael@0 15493 i73 = i42;
michael@0 15494 i74 = i43;
michael@0 15495 i75 = i44;
michael@0 15496 i76 = i45;
michael@0 15497 i77 = i46;
michael@0 15498 i78 = i47;
michael@0 15499 i79 = i48;
michael@0 15500 while (1) {
michael@0 15501 i80 = i57 + 12 | 0;
michael@0 15502 i81 = (HEAP32[i80 >> 2] | 0) + 104 | 0;
michael@0 15503 if ((HEAP32[i81 >> 2] | 0) == (i17 | 0)) {
michael@0 15504 i82 = i61;
michael@0 15505 i83 = i62;
michael@0 15506 i84 = i63;
michael@0 15507 } else {
michael@0 15508 HEAP32[i81 >> 2] = i17;
michael@0 15509 do {
michael@0 15510 if ((i61 | 0) == (i62 | 0)) {
michael@0 15511 i81 = (i62 | 0) == 0 ? 1 : i62 << 1;
michael@0 15512 if ((i62 | 0) >= (i81 | 0)) {
michael@0 15513 i85 = i62;
michael@0 15514 i86 = i63;
michael@0 15515 break;
michael@0 15516 }
michael@0 15517 if ((i81 | 0) == 0) {
michael@0 15518 i87 = 0;
michael@0 15519 } else {
michael@0 15520 i87 = __Z22btAlignedAllocInternalji(i81 << 2, 16) | 0;
michael@0 15521 }
michael@0 15522 if ((i62 | 0) > 0) {
michael@0 15523 i88 = 0;
michael@0 15524 do {
michael@0 15525 i89 = i87 + (i88 << 2) | 0;
michael@0 15526 if ((i89 | 0) != 0) {
michael@0 15527 HEAP32[i89 >> 2] = HEAP32[i63 + (i88 << 2) >> 2];
michael@0 15528 }
michael@0 15529 i88 = i88 + 1 | 0;
michael@0 15530 } while ((i88 | 0) < (i62 | 0));
michael@0 15531 }
michael@0 15532 if ((i63 | 0) == 0) {
michael@0 15533 i85 = i81;
michael@0 15534 i86 = i87;
michael@0 15535 break;
michael@0 15536 }
michael@0 15537 __Z21btAlignedFreeInternalPv(i63);
michael@0 15538 i85 = i81;
michael@0 15539 i86 = i87;
michael@0 15540 } else {
michael@0 15541 i85 = i62;
michael@0 15542 i86 = i63;
michael@0 15543 }
michael@0 15544 } while (0);
michael@0 15545 i88 = i86 + (i61 << 2) | 0;
michael@0 15546 if ((i88 | 0) != 0) {
michael@0 15547 HEAP32[i88 >> 2] = HEAP32[i80 >> 2];
michael@0 15548 }
michael@0 15549 i82 = i61 + 1 | 0;
michael@0 15550 i83 = i85;
michael@0 15551 i84 = i86;
michael@0 15552 }
michael@0 15553 if ((HEAP32[i57 + 20 >> 2] | 0) == (i17 | 0)) {
michael@0 15554 i90 = i58;
michael@0 15555 i91 = i59;
michael@0 15556 i92 = i60;
michael@0 15557 i93 = i64;
michael@0 15558 i94 = i65;
michael@0 15559 i95 = i66;
michael@0 15560 i96 = i67;
michael@0 15561 i97 = i68;
michael@0 15562 i98 = i69;
michael@0 15563 i99 = i70;
michael@0 15564 i100 = i71;
michael@0 15565 i101 = i72;
michael@0 15566 i102 = i73;
michael@0 15567 i103 = i74;
michael@0 15568 i104 = i75;
michael@0 15569 i105 = i76;
michael@0 15570 i106 = i77;
michael@0 15571 i107 = i78;
michael@0 15572 i108 = i79;
michael@0 15573 } else {
michael@0 15574 i88 = __ZN20btConvexHullInternal4PoolINS_4FaceEE9newObjectEv(i27) | 0;
michael@0 15575 i89 = HEAP32[i80 >> 2] | 0;
michael@0 15576 i109 = HEAP32[(HEAP32[(HEAP32[i57 + 8 >> 2] | 0) + 4 >> 2] | 0) + 12 >> 2] | 0;
michael@0 15577 HEAP32[i88 + 4 >> 2] = i89;
michael@0 15578 i110 = i88 + 12 | 0;
michael@0 15579 i111 = i89 + 88 | 0;
michael@0 15580 HEAP32[i110 >> 2] = HEAP32[i111 >> 2];
michael@0 15581 HEAP32[i110 + 4 >> 2] = HEAP32[i111 + 4 >> 2];
michael@0 15582 HEAP32[i110 + 8 >> 2] = HEAP32[i111 + 8 >> 2];
michael@0 15583 HEAP32[i110 + 12 >> 2] = HEAP32[i111 + 12 >> 2];
michael@0 15584 i111 = i89 + 88 | 0;
michael@0 15585 i110 = i89 + 92 | 0;
michael@0 15586 i112 = (HEAP32[i109 + 92 >> 2] | 0) - (HEAP32[i110 >> 2] | 0) | 0;
michael@0 15587 i113 = i89 + 96 | 0;
michael@0 15588 i114 = (HEAP32[i109 + 96 >> 2] | 0) - (HEAP32[i113 >> 2] | 0) | 0;
michael@0 15589 HEAP32[i88 + 28 >> 2] = (HEAP32[i109 + 88 >> 2] | 0) - (HEAP32[i111 >> 2] | 0);
michael@0 15590 HEAP32[i88 + 32 >> 2] = i112;
michael@0 15591 HEAP32[i88 + 36 >> 2] = i114;
michael@0 15592 HEAP32[i88 + 40 >> 2] = -1;
michael@0 15593 i114 = (HEAP32[i55 >> 2] | 0) - (HEAP32[i110 >> 2] | 0) | 0;
michael@0 15594 i110 = (HEAP32[i56 >> 2] | 0) - (HEAP32[i113 >> 2] | 0) | 0;
michael@0 15595 HEAP32[i88 + 44 >> 2] = (HEAP32[i54 >> 2] | 0) - (HEAP32[i111 >> 2] | 0);
michael@0 15596 HEAP32[i88 + 48 >> 2] = i114;
michael@0 15597 HEAP32[i88 + 52 >> 2] = i110;
michael@0 15598 HEAP32[i88 + 56 >> 2] = -1;
michael@0 15599 i110 = i89 + 16 | 0;
michael@0 15600 i114 = HEAP32[i110 >> 2] | 0;
michael@0 15601 if ((i114 | 0) == 0) {
michael@0 15602 HEAP32[i89 + 12 >> 2] = i88;
michael@0 15603 } else {
michael@0 15604 HEAP32[i114 + 8 >> 2] = i88;
michael@0 15605 }
michael@0 15606 HEAP32[i110 >> 2] = i88;
michael@0 15607 do {
michael@0 15608 if ((i58 | 0) == (i59 | 0)) {
michael@0 15609 i110 = (i59 | 0) == 0 ? 1 : i59 << 1;
michael@0 15610 if ((i59 | 0) >= (i110 | 0)) {
michael@0 15611 i115 = i59;
michael@0 15612 i116 = i60;
michael@0 15613 break;
michael@0 15614 }
michael@0 15615 if ((i110 | 0) == 0) {
michael@0 15616 i117 = 0;
michael@0 15617 } else {
michael@0 15618 i117 = __Z22btAlignedAllocInternalji(i110 << 2, 16) | 0;
michael@0 15619 }
michael@0 15620 if ((i59 | 0) > 0) {
michael@0 15621 i114 = 0;
michael@0 15622 do {
michael@0 15623 i89 = i117 + (i114 << 2) | 0;
michael@0 15624 if ((i89 | 0) != 0) {
michael@0 15625 HEAP32[i89 >> 2] = HEAP32[i60 + (i114 << 2) >> 2];
michael@0 15626 }
michael@0 15627 i114 = i114 + 1 | 0;
michael@0 15628 } while ((i114 | 0) < (i59 | 0));
michael@0 15629 }
michael@0 15630 if ((i60 | 0) == 0) {
michael@0 15631 i115 = i110;
michael@0 15632 i116 = i117;
michael@0 15633 break;
michael@0 15634 }
michael@0 15635 __Z21btAlignedFreeInternalPv(i60);
michael@0 15636 i115 = i110;
michael@0 15637 i116 = i117;
michael@0 15638 } else {
michael@0 15639 i115 = i59;
michael@0 15640 i116 = i60;
michael@0 15641 }
michael@0 15642 } while (0);
michael@0 15643 i80 = i116 + (i58 << 2) | 0;
michael@0 15644 if ((i80 | 0) == 0) {
michael@0 15645 i118 = 0;
michael@0 15646 i119 = 0;
michael@0 15647 i120 = i57;
michael@0 15648 i121 = i64;
michael@0 15649 i122 = i65;
michael@0 15650 i123 = i66;
michael@0 15651 i124 = i67;
michael@0 15652 i125 = i68;
michael@0 15653 i126 = i69;
michael@0 15654 i127 = i70;
michael@0 15655 i128 = i71;
michael@0 15656 i129 = i72;
michael@0 15657 i130 = i73;
michael@0 15658 i131 = i74;
michael@0 15659 i132 = i75;
michael@0 15660 i133 = i76;
michael@0 15661 i134 = i77;
michael@0 15662 i135 = i78;
michael@0 15663 i136 = i79;
michael@0 15664 } else {
michael@0 15665 HEAP32[i80 >> 2] = i88;
michael@0 15666 i118 = 0;
michael@0 15667 i119 = 0;
michael@0 15668 i120 = i57;
michael@0 15669 i121 = i64;
michael@0 15670 i122 = i65;
michael@0 15671 i123 = i66;
michael@0 15672 i124 = i67;
michael@0 15673 i125 = i68;
michael@0 15674 i126 = i69;
michael@0 15675 i127 = i70;
michael@0 15676 i128 = i71;
michael@0 15677 i129 = i72;
michael@0 15678 i130 = i73;
michael@0 15679 i131 = i74;
michael@0 15680 i132 = i75;
michael@0 15681 i133 = i76;
michael@0 15682 i134 = i77;
michael@0 15683 i135 = i78;
michael@0 15684 i136 = i79;
michael@0 15685 }
michael@0 15686 while (1) {
michael@0 15687 if ((i119 | 0) == 0 | (i118 | 0) == 0) {
michael@0 15688 i137 = i121;
michael@0 15689 i138 = i122;
michael@0 15690 i139 = i123;
michael@0 15691 i140 = i124;
michael@0 15692 i141 = i125;
michael@0 15693 i142 = i126;
michael@0 15694 i143 = i127;
michael@0 15695 i144 = i128;
michael@0 15696 i145 = i129;
michael@0 15697 i146 = i130;
michael@0 15698 i147 = i131;
michael@0 15699 i148 = i132;
michael@0 15700 i149 = i133;
michael@0 15701 i150 = i134;
michael@0 15702 i151 = i135;
michael@0 15703 i152 = i136;
michael@0 15704 } else {
michael@0 15705 i80 = HEAP32[i54 >> 2] | 0;
michael@0 15706 i114 = i80 - i13 | 0;
michael@0 15707 i81 = HEAP32[i55 >> 2] | 0;
michael@0 15708 i89 = i81 - i18 | 0;
michael@0 15709 i111 = HEAP32[i56 >> 2] | 0;
michael@0 15710 i113 = i111 - i19 | 0;
michael@0 15711 i112 = HEAP32[i119 + 88 >> 2] | 0;
michael@0 15712 i109 = i112 - i13 | 0;
michael@0 15713 i153 = HEAP32[i119 + 92 >> 2] | 0;
michael@0 15714 i154 = i153 - i18 | 0;
michael@0 15715 i155 = HEAP32[i119 + 96 >> 2] | 0;
michael@0 15716 i156 = i155 - i19 | 0;
michael@0 15717 i157 = HEAP32[i118 + 88 >> 2] | 0;
michael@0 15718 i158 = i157 - i13 | 0;
michael@0 15719 i159 = HEAP32[i118 + 92 >> 2] | 0;
michael@0 15720 i160 = i159 - i18 | 0;
michael@0 15721 i161 = HEAP32[i118 + 96 >> 2] | 0;
michael@0 15722 i162 = i161 - i19 | 0;
michael@0 15723 i163 = Math_imul(i162, i154) | 0;
michael@0 15724 i164 = i163 - (Math_imul(i160, i156) | 0) | 0;
michael@0 15725 i163 = Math_imul(i158, i156) | 0;
michael@0 15726 i156 = i163 - (Math_imul(i162, i109) | 0) | 0;
michael@0 15727 i162 = Math_imul(i160, i109) | 0;
michael@0 15728 i109 = i162 - (Math_imul(i158, i154) | 0) | 0;
michael@0 15729 i154 = ___muldi3(i164, (i164 | 0) < 0 ? -1 : 0, i114, (i114 | 0) < 0 ? -1 : 0) | 0;
michael@0 15730 i114 = tempRet0;
michael@0 15731 i164 = ___muldi3(i156, (i156 | 0) < 0 ? -1 : 0, i89, (i89 | 0) < 0 ? -1 : 0) | 0;
michael@0 15732 i89 = tempRet0;
michael@0 15733 i156 = ___muldi3(i109, (i109 | 0) < 0 ? -1 : 0, i113, (i113 | 0) < 0 ? -1 : 0) | 0;
michael@0 15734 i113 = _i64Add(i154, i114, i156, tempRet0) | 0;
michael@0 15735 i156 = _i64Add(i113, tempRet0, i164, i89) | 0;
michael@0 15736 i89 = tempRet0;
michael@0 15737 i164 = i80 + i13 + i112 + i157 | 0;
michael@0 15738 i157 = i81 + i18 + i153 + i159 | 0;
michael@0 15739 i159 = i111 + i19 + i155 + i161 | 0;
michael@0 15740 i161 = ___muldi3(i156, i89, i164, (i164 | 0) < 0 ? -1 : 0) | 0;
michael@0 15741 i164 = tempRet0;
michael@0 15742 i155 = _llvm_uadd_with_overflow_i64(i122 | 0, i121 | 0, i161 | 0, i164 | 0) | 0;
michael@0 15743 i161 = i155;
michael@0 15744 i155 = tempRet0;
michael@0 15745 if (tempRet1) {
michael@0 15746 i111 = _i64Add(i124, i123, 1, 0) | 0;
michael@0 15747 i153 = tempRet0;
michael@0 15748 HEAP32[i20 >> 2] = i111;
michael@0 15749 HEAP32[i20 + 4 >> 2] = i153;
michael@0 15750 i165 = i153;
michael@0 15751 i166 = i111;
michael@0 15752 } else {
michael@0 15753 i165 = i123;
michael@0 15754 i166 = i124;
michael@0 15755 }
michael@0 15756 HEAP32[i14 >> 2] = i161;
michael@0 15757 HEAP32[i14 + 4 >> 2] = i155;
michael@0 15758 i111 = _i64Add(i166, i165, i164 >> 31 | ((i164 | 0) < 0 ? -1 : 0) << 1, ((i164 | 0) < 0 ? -1 : 0) >> 31 | ((i164 | 0) < 0 ? -1 : 0) << 1) | 0;
michael@0 15759 i164 = tempRet0;
michael@0 15760 HEAP32[i20 >> 2] = i111;
michael@0 15761 HEAP32[i20 + 4 >> 2] = i164;
michael@0 15762 i153 = ___muldi3(i156, i89, i157, (i157 | 0) < 0 ? -1 : 0) | 0;
michael@0 15763 i157 = tempRet0;
michael@0 15764 i81 = _llvm_uadd_with_overflow_i64(i126 | 0, i125 | 0, i153 | 0, i157 | 0) | 0;
michael@0 15765 i153 = i81;
michael@0 15766 i81 = tempRet0;
michael@0 15767 if (tempRet1) {
michael@0 15768 i112 = _i64Add(i128, i127, 1, 0) | 0;
michael@0 15769 i80 = tempRet0;
michael@0 15770 HEAP32[i22 >> 2] = i112;
michael@0 15771 HEAP32[i22 + 4 >> 2] = i80;
michael@0 15772 i167 = i80;
michael@0 15773 i168 = i112;
michael@0 15774 } else {
michael@0 15775 i167 = i127;
michael@0 15776 i168 = i128;
michael@0 15777 }
michael@0 15778 HEAP32[i21 >> 2] = i153;
michael@0 15779 HEAP32[i21 + 4 >> 2] = i81;
michael@0 15780 i112 = _i64Add(i168, i167, i157 >> 31 | ((i157 | 0) < 0 ? -1 : 0) << 1, ((i157 | 0) < 0 ? -1 : 0) >> 31 | ((i157 | 0) < 0 ? -1 : 0) << 1) | 0;
michael@0 15781 i157 = tempRet0;
michael@0 15782 HEAP32[i22 >> 2] = i112;
michael@0 15783 HEAP32[i22 + 4 >> 2] = i157;
michael@0 15784 i80 = ___muldi3(i156, i89, i159, (i159 | 0) < 0 ? -1 : 0) | 0;
michael@0 15785 i159 = tempRet0;
michael@0 15786 i113 = _llvm_uadd_with_overflow_i64(i130 | 0, i129 | 0, i80 | 0, i159 | 0) | 0;
michael@0 15787 i80 = i113;
michael@0 15788 i113 = tempRet0;
michael@0 15789 if (tempRet1) {
michael@0 15790 i114 = _i64Add(i132, i131, 1, 0) | 0;
michael@0 15791 i154 = tempRet0;
michael@0 15792 HEAP32[i24 >> 2] = i114;
michael@0 15793 HEAP32[i24 + 4 >> 2] = i154;
michael@0 15794 i169 = i154;
michael@0 15795 i170 = i114;
michael@0 15796 } else {
michael@0 15797 i169 = i131;
michael@0 15798 i170 = i132;
michael@0 15799 }
michael@0 15800 HEAP32[i23 >> 2] = i80;
michael@0 15801 HEAP32[i23 + 4 >> 2] = i113;
michael@0 15802 i114 = _i64Add(i170, i169, i159 >> 31 | ((i159 | 0) < 0 ? -1 : 0) << 1, ((i159 | 0) < 0 ? -1 : 0) >> 31 | ((i159 | 0) < 0 ? -1 : 0) << 1) | 0;
michael@0 15803 i159 = tempRet0;
michael@0 15804 HEAP32[i24 >> 2] = i114;
michael@0 15805 HEAP32[i24 + 4 >> 2] = i159;
michael@0 15806 i154 = _llvm_uadd_with_overflow_i64(i134 | 0, i133 | 0, i156 | 0, i89 | 0) | 0;
michael@0 15807 i156 = i154;
michael@0 15808 i154 = tempRet0;
michael@0 15809 if (tempRet1) {
michael@0 15810 i109 = _i64Add(i136, i135, 1, 0) | 0;
michael@0 15811 i158 = tempRet0;
michael@0 15812 HEAP32[i26 >> 2] = i109;
michael@0 15813 HEAP32[i26 + 4 >> 2] = i158;
michael@0 15814 i171 = i158;
michael@0 15815 i172 = i109;
michael@0 15816 } else {
michael@0 15817 i171 = i135;
michael@0 15818 i172 = i136;
michael@0 15819 }
michael@0 15820 HEAP32[i25 >> 2] = i156;
michael@0 15821 HEAP32[i25 + 4 >> 2] = i154;
michael@0 15822 i109 = _i64Add(i172, i171, i89 >> 31 | ((i89 | 0) < 0 ? -1 : 0) << 1, ((i89 | 0) < 0 ? -1 : 0) >> 31 | ((i89 | 0) < 0 ? -1 : 0) << 1) | 0;
michael@0 15823 i89 = tempRet0;
michael@0 15824 HEAP32[i26 >> 2] = i109;
michael@0 15825 HEAP32[i26 + 4 >> 2] = i89;
michael@0 15826 i137 = i155;
michael@0 15827 i138 = i161;
michael@0 15828 i139 = i164;
michael@0 15829 i140 = i111;
michael@0 15830 i141 = i81;
michael@0 15831 i142 = i153;
michael@0 15832 i143 = i157;
michael@0 15833 i144 = i112;
michael@0 15834 i145 = i113;
michael@0 15835 i146 = i80;
michael@0 15836 i147 = i159;
michael@0 15837 i148 = i114;
michael@0 15838 i149 = i154;
michael@0 15839 i150 = i156;
michael@0 15840 i151 = i89;
michael@0 15841 i152 = i109;
michael@0 15842 }
michael@0 15843 HEAP32[i120 + 20 >> 2] = i17;
michael@0 15844 HEAP32[i120 + 16 >> 2] = i88;
michael@0 15845 i109 = HEAP32[(HEAP32[i120 + 8 >> 2] | 0) + 4 >> 2] | 0;
michael@0 15846 if ((i109 | 0) == (i57 | 0)) {
michael@0 15847 break;
michael@0 15848 } else {
michael@0 15849 i119 = i118;
michael@0 15850 i118 = HEAP32[i120 + 12 >> 2] | 0;
michael@0 15851 i120 = i109;
michael@0 15852 i121 = i137;
michael@0 15853 i122 = i138;
michael@0 15854 i123 = i139;
michael@0 15855 i124 = i140;
michael@0 15856 i125 = i141;
michael@0 15857 i126 = i142;
michael@0 15858 i127 = i143;
michael@0 15859 i128 = i144;
michael@0 15860 i129 = i145;
michael@0 15861 i130 = i146;
michael@0 15862 i131 = i147;
michael@0 15863 i132 = i148;
michael@0 15864 i133 = i149;
michael@0 15865 i134 = i150;
michael@0 15866 i135 = i151;
michael@0 15867 i136 = i152;
michael@0 15868 }
michael@0 15869 }
michael@0 15870 i90 = i58 + 1 | 0;
michael@0 15871 i91 = i115;
michael@0 15872 i92 = i116;
michael@0 15873 i93 = i137;
michael@0 15874 i94 = i138;
michael@0 15875 i95 = i139;
michael@0 15876 i96 = i140;
michael@0 15877 i97 = i141;
michael@0 15878 i98 = i142;
michael@0 15879 i99 = i143;
michael@0 15880 i100 = i144;
michael@0 15881 i101 = i145;
michael@0 15882 i102 = i146;
michael@0 15883 i103 = i147;
michael@0 15884 i104 = i148;
michael@0 15885 i105 = i149;
michael@0 15886 i106 = i150;
michael@0 15887 i107 = i151;
michael@0 15888 i108 = i152;
michael@0 15889 }
michael@0 15890 i88 = HEAP32[i57 >> 2] | 0;
michael@0 15891 if ((i88 | 0) == (HEAP32[i52 >> 2] | 0)) {
michael@0 15892 i28 = i90;
michael@0 15893 i29 = i91;
michael@0 15894 i30 = i92;
michael@0 15895 i31 = i82;
michael@0 15896 i32 = i83;
michael@0 15897 i33 = i84;
michael@0 15898 i16 = i93;
michael@0 15899 i34 = i94;
michael@0 15900 i35 = i95;
michael@0 15901 i36 = i96;
michael@0 15902 i37 = i97;
michael@0 15903 i38 = i98;
michael@0 15904 i39 = i99;
michael@0 15905 i40 = i100;
michael@0 15906 i41 = i101;
michael@0 15907 i42 = i102;
michael@0 15908 i43 = i103;
michael@0 15909 i44 = i104;
michael@0 15910 i45 = i105;
michael@0 15911 i46 = i106;
michael@0 15912 i47 = i107;
michael@0 15913 i48 = i108;
michael@0 15914 continue L1498;
michael@0 15915 } else {
michael@0 15916 i57 = i88;
michael@0 15917 i58 = i90;
michael@0 15918 i59 = i91;
michael@0 15919 i60 = i92;
michael@0 15920 i61 = i82;
michael@0 15921 i62 = i83;
michael@0 15922 i63 = i84;
michael@0 15923 i64 = i93;
michael@0 15924 i65 = i94;
michael@0 15925 i66 = i95;
michael@0 15926 i67 = i96;
michael@0 15927 i68 = i97;
michael@0 15928 i69 = i98;
michael@0 15929 i70 = i99;
michael@0 15930 i71 = i100;
michael@0 15931 i72 = i101;
michael@0 15932 i73 = i102;
michael@0 15933 i74 = i103;
michael@0 15934 i75 = i104;
michael@0 15935 i76 = i105;
michael@0 15936 i77 = i106;
michael@0 15937 i78 = i107;
michael@0 15938 i79 = i108;
michael@0 15939 }
michael@0 15940 }
michael@0 15941 }
michael@0 15942 i108 = 0;
michael@0 15943 L1573 : do {
michael@0 15944 if ((i47 | 0) < (i108 | 0) | (i47 | 0) == (i108 | 0) & i48 >>> 0 < 0 >>> 0) {
michael@0 15945 d173 = 0.0;
michael@0 15946 } else {
michael@0 15947 if ((i46 | i48 | 0) == 0 & (i45 | i47 | 0) == 0) {
michael@0 15948 d173 = 0.0;
michael@0 15949 break;
michael@0 15950 }
michael@0 15951 d174 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i6);
michael@0 15952 i107 = i1 + 108 | 0;
michael@0 15953 i106 = i10 | 0;
michael@0 15954 HEAPF32[i10 + (HEAP32[i107 >> 2] << 2) >> 2] = d174;
michael@0 15955 d174 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i7);
michael@0 15956 i105 = i1 + 112 | 0;
michael@0 15957 HEAPF32[i10 + (HEAP32[i105 >> 2] << 2) >> 2] = d174;
michael@0 15958 d174 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i8);
michael@0 15959 i104 = i1 + 104 | 0;
michael@0 15960 HEAPF32[i10 + (HEAP32[i104 >> 2] << 2) >> 2] = d174;
michael@0 15961 d174 = 1.0 / (+__ZNK20btConvexHullInternal6Int1288toScalarEv(i9) * 4.0);
michael@0 15962 i103 = i10 + 4 | 0;
michael@0 15963 d175 = d174 * +HEAPF32[i103 >> 2];
michael@0 15964 i102 = i10 + 8 | 0;
michael@0 15965 d176 = d174 * +HEAPF32[i102 >> 2];
michael@0 15966 i101 = i1 | 0;
michael@0 15967 d177 = d174 * +HEAPF32[i106 >> 2] * +HEAPF32[i101 >> 2];
michael@0 15968 HEAPF32[i106 >> 2] = d177;
michael@0 15969 i106 = i1 + 4 | 0;
michael@0 15970 d174 = d175 * +HEAPF32[i106 >> 2];
michael@0 15971 HEAPF32[i103 >> 2] = d174;
michael@0 15972 i103 = i1 + 8 | 0;
michael@0 15973 d175 = d176 * +HEAPF32[i103 >> 2];
michael@0 15974 HEAPF32[i102 >> 2] = d175;
michael@0 15975 if (d3 > 0.0) {
michael@0 15976 if ((i28 | 0) > 0) {
michael@0 15977 i102 = i5 | 0;
michael@0 15978 i100 = i5 + 4 | 0;
michael@0 15979 i99 = i5 + 8 | 0;
michael@0 15980 i98 = i11 | 0;
michael@0 15981 i97 = i11 + 4 | 0;
michael@0 15982 i96 = i11 + 8 | 0;
michael@0 15983 d176 = 3.4028234663852886e+38;
michael@0 15984 i95 = 0;
michael@0 15985 do {
michael@0 15986 i94 = i30 + (i95 << 2) | 0;
michael@0 15987 __ZN20btConvexHullInternal11getBtNormalEPNS_4FaceE(i11, i1, HEAP32[i94 >> 2] | 0);
michael@0 15988 i93 = HEAP32[i94 >> 2] | 0;
michael@0 15989 HEAPF32[i5 + (HEAP32[i107 >> 2] << 2) >> 2] = +(HEAP32[i93 + 12 >> 2] | 0);
michael@0 15990 HEAPF32[i5 + (HEAP32[i105 >> 2] << 2) >> 2] = +(HEAP32[i93 + 16 >> 2] | 0);
michael@0 15991 HEAPF32[i5 + (HEAP32[i104 >> 2] << 2) >> 2] = +(HEAP32[i93 + 20 >> 2] | 0);
michael@0 15992 d178 = (+HEAPF32[i102 >> 2] * +HEAPF32[i101 >> 2] - d177) * +HEAPF32[i98 >> 2] + (+HEAPF32[i100 >> 2] * +HEAPF32[i106 >> 2] - d174) * +HEAPF32[i97 >> 2] + (+HEAPF32[i99 >> 2] * +HEAPF32[i103 >> 2] - d175) * +HEAPF32[i96 >> 2];
michael@0 15993 d176 = d178 < d176 ? d178 : d176;
michael@0 15994 i95 = i95 + 1 | 0;
michael@0 15995 } while ((i95 | 0) < (i28 | 0));
michael@0 15996 if (d176 > 0.0) {
michael@0 15997 d179 = d176;
michael@0 15998 } else {
michael@0 15999 d173 = 0.0;
michael@0 16000 break;
michael@0 16001 }
michael@0 16002 } else {
michael@0 16003 d179 = 3.4028234663852886e+38;
michael@0 16004 }
michael@0 16005 d175 = d179 * d3;
michael@0 16006 d180 = d175 > d2 ? d2 : d175;
michael@0 16007 } else {
michael@0 16008 d180 = d2;
michael@0 16009 }
michael@0 16010 if ((i28 | 0) > 0) {
michael@0 16011 i95 = 243703;
michael@0 16012 i96 = 0;
michael@0 16013 do {
michael@0 16014 i103 = i30 + (i96 << 2) | 0;
michael@0 16015 i99 = i30 + (((i95 >>> 0) % (i28 >>> 0) | 0) << 2) | 0;
michael@0 16016 i97 = HEAP32[i103 >> 2] | 0;
michael@0 16017 HEAP32[i103 >> 2] = HEAP32[i99 >> 2];
michael@0 16018 HEAP32[i99 >> 2] = i97;
michael@0 16019 i96 = i96 + 1 | 0;
michael@0 16020 i95 = (Math_imul(i95, 1664525) | 0) + 1013904223 | 0;
michael@0 16021 } while ((i96 | 0) < (i28 | 0));
michael@0 16022 }
michael@0 16023 i96 = i12 + 16 | 0;
michael@0 16024 i95 = i12 + 12 | 0;
michael@0 16025 i97 = i12 + 4 | 0;
michael@0 16026 i99 = i12 + 8 | 0;
michael@0 16027 i103 = 0;
michael@0 16028 while (1) {
michael@0 16029 if ((i103 | 0) >= (i28 | 0)) {
michael@0 16030 d173 = d180;
michael@0 16031 break L1573;
michael@0 16032 }
michael@0 16033 i106 = HEAP32[i30 + (i103 << 2) >> 2] | 0;
michael@0 16034 HEAP8[i96] = 1;
michael@0 16035 HEAP32[i95 >> 2] = 0;
michael@0 16036 HEAP32[i99 >> 2] = 0;
michael@0 16037 HEAP32[i97 >> 2] = i49;
michael@0 16038 i100 = __ZN20btConvexHullInternal9shiftFaceEPNS_4FaceEf20btAlignedObjectArrayIPNS_6VertexEE(i1, i106, d180, i12) | 0;
michael@0 16039 i106 = HEAP32[i95 >> 2] | 0;
michael@0 16040 if ((i106 | 0) != 0) {
michael@0 16041 if ((HEAP8[i96] | 0) != 0) {
michael@0 16042 __Z21btAlignedFreeInternalPv(i106);
michael@0 16043 }
michael@0 16044 HEAP32[i95 >> 2] = 0;
michael@0 16045 }
michael@0 16046 HEAP8[i96] = 1;
michael@0 16047 HEAP32[i95 >> 2] = 0;
michael@0 16048 HEAP32[i97 >> 2] = 0;
michael@0 16049 HEAP32[i99 >> 2] = 0;
michael@0 16050 if (i100) {
michael@0 16051 i103 = i103 + 1 | 0;
michael@0 16052 } else {
michael@0 16053 break;
michael@0 16054 }
michael@0 16055 }
michael@0 16056 d173 = -0.0 - d180;
michael@0 16057 }
michael@0 16058 } while (0);
michael@0 16059 if ((i30 | 0) != 0) {
michael@0 16060 __Z21btAlignedFreeInternalPv(i30);
michael@0 16061 }
michael@0 16062 if ((i33 | 0) == 0) {
michael@0 16063 d15 = d173;
michael@0 16064 STACKTOP = i4;
michael@0 16065 return +d15;
michael@0 16066 }
michael@0 16067 __Z21btAlignedFreeInternalPv(i33);
michael@0 16068 d15 = d173;
michael@0 16069 STACKTOP = i4;
michael@0 16070 return +d15;
michael@0 16071 }
michael@0 16072 function __ZN20btConvexHullComputer7computeEPKvbiiff(i1, i2, i3, i4, i5, d6, d7) {
michael@0 16073 i1 = i1 | 0;
michael@0 16074 i2 = i2 | 0;
michael@0 16075 i3 = i3 | 0;
michael@0 16076 i4 = i4 | 0;
michael@0 16077 i5 = i5 | 0;
michael@0 16078 d6 = +d6;
michael@0 16079 d7 = +d7;
michael@0 16080 var i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, d19 = 0.0, d20 = 0.0, d21 = 0.0, i22 = 0, d23 = 0.0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0;
michael@0 16081 i8 = STACKTOP;
michael@0 16082 STACKTOP = STACKTOP + 208 | 0;
michael@0 16083 i9 = i8 | 0;
michael@0 16084 i10 = i8 + 128 | 0;
michael@0 16085 i11 = i8 + 144 | 0;
michael@0 16086 i12 = i8 + 160 | 0;
michael@0 16087 i13 = i8 + 176 | 0;
michael@0 16088 i14 = i8 + 192 | 0;
michael@0 16089 if ((i5 | 0) < 1) {
michael@0 16090 i15 = i1 + 4 | 0;
michael@0 16091 i16 = i1 + 12 | 0;
michael@0 16092 i17 = HEAP32[i16 >> 2] | 0;
michael@0 16093 i18 = i1 + 16 | 0;
michael@0 16094 if ((i17 | 0) != 0) {
michael@0 16095 if ((HEAP8[i18] | 0) != 0) {
michael@0 16096 __Z21btAlignedFreeInternalPv(i17);
michael@0 16097 }
michael@0 16098 HEAP32[i16 >> 2] = 0;
michael@0 16099 }
michael@0 16100 HEAP8[i18] = 1;
michael@0 16101 HEAP32[i16 >> 2] = 0;
michael@0 16102 HEAP32[i15 >> 2] = 0;
michael@0 16103 HEAP32[i1 + 8 >> 2] = 0;
michael@0 16104 i15 = i1 + 24 | 0;
michael@0 16105 i16 = i1 + 32 | 0;
michael@0 16106 i18 = HEAP32[i16 >> 2] | 0;
michael@0 16107 i17 = i1 + 36 | 0;
michael@0 16108 if ((i18 | 0) != 0) {
michael@0 16109 if ((HEAP8[i17] | 0) != 0) {
michael@0 16110 __Z21btAlignedFreeInternalPv(i18);
michael@0 16111 }
michael@0 16112 HEAP32[i16 >> 2] = 0;
michael@0 16113 }
michael@0 16114 HEAP8[i17] = 1;
michael@0 16115 HEAP32[i16 >> 2] = 0;
michael@0 16116 HEAP32[i15 >> 2] = 0;
michael@0 16117 HEAP32[i1 + 28 >> 2] = 0;
michael@0 16118 i15 = i1 + 44 | 0;
michael@0 16119 i16 = i1 + 52 | 0;
michael@0 16120 i17 = HEAP32[i16 >> 2] | 0;
michael@0 16121 i18 = i1 + 56 | 0;
michael@0 16122 if ((i17 | 0) != 0) {
michael@0 16123 if ((HEAP8[i18] | 0) != 0) {
michael@0 16124 __Z21btAlignedFreeInternalPv(i17);
michael@0 16125 }
michael@0 16126 HEAP32[i16 >> 2] = 0;
michael@0 16127 }
michael@0 16128 HEAP8[i18] = 1;
michael@0 16129 HEAP32[i16 >> 2] = 0;
michael@0 16130 HEAP32[i15 >> 2] = 0;
michael@0 16131 HEAP32[i1 + 48 >> 2] = 0;
michael@0 16132 d19 = 0.0;
michael@0 16133 STACKTOP = i8;
michael@0 16134 return +d19;
michael@0 16135 }
michael@0 16136 HEAP32[i9 + 32 >> 2] = 0;
michael@0 16137 HEAP32[i9 + 36 >> 2] = 0;
michael@0 16138 HEAP32[i9 + 40 >> 2] = 0;
michael@0 16139 HEAP32[i9 + 44 >> 2] = 256;
michael@0 16140 HEAP32[i9 + 48 >> 2] = 0;
michael@0 16141 HEAP32[i9 + 52 >> 2] = 0;
michael@0 16142 HEAP32[i9 + 56 >> 2] = 0;
michael@0 16143 HEAP32[i9 + 60 >> 2] = 256;
michael@0 16144 HEAP32[i9 + 64 >> 2] = 0;
michael@0 16145 HEAP32[i9 + 68 >> 2] = 0;
michael@0 16146 HEAP32[i9 + 72 >> 2] = 0;
michael@0 16147 HEAP32[i9 + 76 >> 2] = 256;
michael@0 16148 HEAP8[i9 + 96 | 0] = 1;
michael@0 16149 HEAP32[i9 + 92 >> 2] = 0;
michael@0 16150 HEAP32[i9 + 84 >> 2] = 0;
michael@0 16151 HEAP32[i9 + 88 >> 2] = 0;
michael@0 16152 __ZN20btConvexHullInternal7computeEPKvbii(i9, i2, i3, i4, i5);
michael@0 16153 do {
michael@0 16154 if (d6 > 0.0) {
michael@0 16155 d20 = +__ZN20btConvexHullInternal6shrinkEff(i9, d6, d7);
michael@0 16156 if (d20 >= 0.0) {
michael@0 16157 d21 = d20;
michael@0 16158 i22 = 1689;
michael@0 16159 break;
michael@0 16160 }
michael@0 16161 i5 = i1 + 4 | 0;
michael@0 16162 i4 = i1 + 12 | 0;
michael@0 16163 i3 = HEAP32[i4 >> 2] | 0;
michael@0 16164 i2 = i1 + 16 | 0;
michael@0 16165 if ((i3 | 0) != 0) {
michael@0 16166 if ((HEAP8[i2] | 0) != 0) {
michael@0 16167 __Z21btAlignedFreeInternalPv(i3);
michael@0 16168 }
michael@0 16169 HEAP32[i4 >> 2] = 0;
michael@0 16170 }
michael@0 16171 HEAP8[i2] = 1;
michael@0 16172 HEAP32[i4 >> 2] = 0;
michael@0 16173 HEAP32[i5 >> 2] = 0;
michael@0 16174 HEAP32[i1 + 8 >> 2] = 0;
michael@0 16175 i5 = i1 + 24 | 0;
michael@0 16176 i4 = i1 + 32 | 0;
michael@0 16177 i2 = HEAP32[i4 >> 2] | 0;
michael@0 16178 i3 = i1 + 36 | 0;
michael@0 16179 if ((i2 | 0) != 0) {
michael@0 16180 if ((HEAP8[i3] | 0) != 0) {
michael@0 16181 __Z21btAlignedFreeInternalPv(i2);
michael@0 16182 }
michael@0 16183 HEAP32[i4 >> 2] = 0;
michael@0 16184 }
michael@0 16185 HEAP8[i3] = 1;
michael@0 16186 HEAP32[i4 >> 2] = 0;
michael@0 16187 HEAP32[i5 >> 2] = 0;
michael@0 16188 HEAP32[i1 + 28 >> 2] = 0;
michael@0 16189 i5 = i1 + 44 | 0;
michael@0 16190 i4 = i1 + 52 | 0;
michael@0 16191 i3 = HEAP32[i4 >> 2] | 0;
michael@0 16192 i2 = i1 + 56 | 0;
michael@0 16193 if ((i3 | 0) != 0) {
michael@0 16194 if ((HEAP8[i2] | 0) != 0) {
michael@0 16195 __Z21btAlignedFreeInternalPv(i3);
michael@0 16196 }
michael@0 16197 HEAP32[i4 >> 2] = 0;
michael@0 16198 }
michael@0 16199 HEAP8[i2] = 1;
michael@0 16200 HEAP32[i4 >> 2] = 0;
michael@0 16201 HEAP32[i5 >> 2] = 0;
michael@0 16202 HEAP32[i1 + 48 >> 2] = 0;
michael@0 16203 d23 = d20;
michael@0 16204 } else {
michael@0 16205 d21 = 0.0;
michael@0 16206 i22 = 1689;
michael@0 16207 }
michael@0 16208 } while (0);
michael@0 16209 do {
michael@0 16210 if ((i22 | 0) == 1689) {
michael@0 16211 i5 = i1 + 4 | 0;
michael@0 16212 i4 = HEAP32[i5 >> 2] | 0;
michael@0 16213 if ((i4 | 0) < 0) {
michael@0 16214 i2 = i1 + 8 | 0;
michael@0 16215 i3 = i1 + 12 | 0;
michael@0 16216 if ((HEAP32[i2 >> 2] | 0) < 0) {
michael@0 16217 i15 = HEAP32[i3 >> 2] | 0;
michael@0 16218 i16 = i1 + 16 | 0;
michael@0 16219 if ((i15 | 0) != 0) {
michael@0 16220 if ((HEAP8[i16] | 0) != 0) {
michael@0 16221 __Z21btAlignedFreeInternalPv(i15);
michael@0 16222 }
michael@0 16223 HEAP32[i3 >> 2] = 0;
michael@0 16224 }
michael@0 16225 HEAP8[i16] = 1;
michael@0 16226 HEAP32[i3 >> 2] = 0;
michael@0 16227 HEAP32[i2 >> 2] = 0;
michael@0 16228 }
michael@0 16229 i2 = i10;
michael@0 16230 i16 = i4;
michael@0 16231 do {
michael@0 16232 i4 = (HEAP32[i3 >> 2] | 0) + (i16 << 4) | 0;
michael@0 16233 if ((i4 | 0) != 0) {
michael@0 16234 i15 = i4;
michael@0 16235 HEAP32[i15 >> 2] = HEAP32[i2 >> 2];
michael@0 16236 HEAP32[i15 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 16237 HEAP32[i15 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 16238 HEAP32[i15 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 16239 }
michael@0 16240 i16 = i16 + 1 | 0;
michael@0 16241 } while ((i16 | 0) < 0);
michael@0 16242 }
michael@0 16243 HEAP32[i5 >> 2] = 0;
michael@0 16244 i16 = i11;
michael@0 16245 _memset(i16 | 0, 0, 12);
michael@0 16246 i2 = i1 + 24 | 0;
michael@0 16247 i3 = HEAP32[i2 >> 2] | 0;
michael@0 16248 if ((i3 | 0) < 0) {
michael@0 16249 i15 = i1 + 28 | 0;
michael@0 16250 i4 = i1 + 32 | 0;
michael@0 16251 if ((HEAP32[i15 >> 2] | 0) < 0) {
michael@0 16252 i18 = HEAP32[i4 >> 2] | 0;
michael@0 16253 i17 = i1 + 36 | 0;
michael@0 16254 if ((i18 | 0) != 0) {
michael@0 16255 if ((HEAP8[i17] | 0) != 0) {
michael@0 16256 __Z21btAlignedFreeInternalPv(i18);
michael@0 16257 }
michael@0 16258 HEAP32[i4 >> 2] = 0;
michael@0 16259 }
michael@0 16260 HEAP8[i17] = 1;
michael@0 16261 HEAP32[i4 >> 2] = 0;
michael@0 16262 HEAP32[i15 >> 2] = 0;
michael@0 16263 i24 = i3;
michael@0 16264 } else {
michael@0 16265 i24 = i3;
michael@0 16266 }
michael@0 16267 do {
michael@0 16268 i3 = (HEAP32[i4 >> 2] | 0) + (i24 * 12 | 0) | 0;
michael@0 16269 if ((i3 | 0) != 0) {
michael@0 16270 i15 = i3;
michael@0 16271 HEAP32[i15 >> 2] = HEAP32[i16 >> 2];
michael@0 16272 HEAP32[i15 + 4 >> 2] = HEAP32[i16 + 4 >> 2];
michael@0 16273 HEAP32[i15 + 8 >> 2] = HEAP32[i16 + 8 >> 2];
michael@0 16274 }
michael@0 16275 i24 = i24 + 1 | 0;
michael@0 16276 } while ((i24 | 0) < 0);
michael@0 16277 }
michael@0 16278 HEAP32[i2 >> 2] = 0;
michael@0 16279 i16 = i1 + 44 | 0;
michael@0 16280 i4 = HEAP32[i16 >> 2] | 0;
michael@0 16281 if ((i4 | 0) < 0) {
michael@0 16282 i15 = i1 + 48 | 0;
michael@0 16283 i3 = i1 + 52 | 0;
michael@0 16284 i17 = HEAP32[i3 >> 2] | 0;
michael@0 16285 if ((HEAP32[i15 >> 2] | 0) < 0) {
michael@0 16286 i18 = i1 + 56 | 0;
michael@0 16287 if ((i17 | 0) != 0) {
michael@0 16288 if ((HEAP8[i18] | 0) != 0) {
michael@0 16289 __Z21btAlignedFreeInternalPv(i17);
michael@0 16290 }
michael@0 16291 HEAP32[i3 >> 2] = 0;
michael@0 16292 }
michael@0 16293 HEAP8[i18] = 1;
michael@0 16294 HEAP32[i3 >> 2] = 0;
michael@0 16295 HEAP32[i15 >> 2] = 0;
michael@0 16296 i25 = 0;
michael@0 16297 } else {
michael@0 16298 i25 = i17;
michael@0 16299 }
michael@0 16300 i17 = i4;
michael@0 16301 do {
michael@0 16302 i4 = i25 + (i17 << 2) | 0;
michael@0 16303 if ((i4 | 0) != 0) {
michael@0 16304 HEAP32[i4 >> 2] = 0;
michael@0 16305 }
michael@0 16306 i17 = i17 + 1 | 0;
michael@0 16307 } while ((i17 | 0) < 0);
michael@0 16308 }
michael@0 16309 HEAP32[i16 >> 2] = 0;
michael@0 16310 i17 = HEAP32[i9 + 124 >> 2] | 0;
michael@0 16311 i4 = i17 + 104 | 0;
michael@0 16312 if ((HEAP32[i4 >> 2] | 0) >= 0) {
michael@0 16313 d23 = d21;
michael@0 16314 break;
michael@0 16315 }
michael@0 16316 HEAP32[i4 >> 2] = 0;
michael@0 16317 i4 = __Z22btAlignedAllocInternalji(4, 16) | 0;
michael@0 16318 i15 = i4;
michael@0 16319 if ((i4 | 0) != 0) {
michael@0 16320 HEAP32[i15 >> 2] = i17;
michael@0 16321 }
michael@0 16322 i17 = i1 + 8 | 0;
michael@0 16323 i4 = i1 + 12 | 0;
michael@0 16324 i3 = i1 + 16 | 0;
michael@0 16325 i18 = i13;
michael@0 16326 i26 = i1 + 28 | 0;
michael@0 16327 i27 = i1 + 32 | 0;
michael@0 16328 i28 = i1 + 36 | 0;
michael@0 16329 i29 = i14;
michael@0 16330 i30 = i12;
michael@0 16331 i31 = i15;
michael@0 16332 i15 = 1;
michael@0 16333 i32 = 1;
michael@0 16334 i33 = 0;
michael@0 16335 while (1) {
michael@0 16336 i34 = HEAP32[i31 + (i33 << 2) >> 2] | 0;
michael@0 16337 __ZN20btConvexHullInternal14getCoordinatesEPKNS_6VertexE(i12, i9, i34);
michael@0 16338 i35 = HEAP32[i5 >> 2] | 0;
michael@0 16339 do {
michael@0 16340 if ((i35 | 0) == (HEAP32[i17 >> 2] | 0)) {
michael@0 16341 i36 = (i35 | 0) == 0 ? 1 : i35 << 1;
michael@0 16342 if ((i35 | 0) >= (i36 | 0)) {
michael@0 16343 i37 = i35;
michael@0 16344 break;
michael@0 16345 }
michael@0 16346 if ((i36 | 0) == 0) {
michael@0 16347 i38 = 0;
michael@0 16348 i39 = i35;
michael@0 16349 } else {
michael@0 16350 i40 = __Z22btAlignedAllocInternalji(i36 << 4, 16) | 0;
michael@0 16351 i38 = i40;
michael@0 16352 i39 = HEAP32[i5 >> 2] | 0;
michael@0 16353 }
michael@0 16354 if ((i39 | 0) > 0) {
michael@0 16355 i40 = 0;
michael@0 16356 do {
michael@0 16357 i41 = i38 + (i40 << 4) | 0;
michael@0 16358 if ((i41 | 0) != 0) {
michael@0 16359 i42 = i41;
michael@0 16360 i41 = (HEAP32[i4 >> 2] | 0) + (i40 << 4) | 0;
michael@0 16361 HEAP32[i42 >> 2] = HEAP32[i41 >> 2];
michael@0 16362 HEAP32[i42 + 4 >> 2] = HEAP32[i41 + 4 >> 2];
michael@0 16363 HEAP32[i42 + 8 >> 2] = HEAP32[i41 + 8 >> 2];
michael@0 16364 HEAP32[i42 + 12 >> 2] = HEAP32[i41 + 12 >> 2];
michael@0 16365 }
michael@0 16366 i40 = i40 + 1 | 0;
michael@0 16367 } while ((i40 | 0) < (i39 | 0));
michael@0 16368 }
michael@0 16369 i40 = HEAP32[i4 >> 2] | 0;
michael@0 16370 if ((i40 | 0) != 0) {
michael@0 16371 if ((HEAP8[i3] | 0) != 0) {
michael@0 16372 __Z21btAlignedFreeInternalPv(i40);
michael@0 16373 }
michael@0 16374 HEAP32[i4 >> 2] = 0;
michael@0 16375 }
michael@0 16376 HEAP8[i3] = 1;
michael@0 16377 HEAP32[i4 >> 2] = i38;
michael@0 16378 HEAP32[i17 >> 2] = i36;
michael@0 16379 i37 = HEAP32[i5 >> 2] | 0;
michael@0 16380 } else {
michael@0 16381 i37 = i35;
michael@0 16382 }
michael@0 16383 } while (0);
michael@0 16384 i35 = (HEAP32[i4 >> 2] | 0) + (i37 << 4) | 0;
michael@0 16385 if ((i35 | 0) == 0) {
michael@0 16386 i43 = i37;
michael@0 16387 } else {
michael@0 16388 i40 = i35;
michael@0 16389 HEAP32[i40 >> 2] = HEAP32[i30 >> 2];
michael@0 16390 HEAP32[i40 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 16391 HEAP32[i40 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 16392 HEAP32[i40 + 12 >> 2] = HEAP32[i30 + 12 >> 2];
michael@0 16393 i43 = HEAP32[i5 >> 2] | 0;
michael@0 16394 }
michael@0 16395 HEAP32[i5 >> 2] = i43 + 1;
michael@0 16396 i40 = HEAP32[i34 + 8 >> 2] | 0;
michael@0 16397 if ((i40 | 0) == 0) {
michael@0 16398 i44 = i32;
michael@0 16399 i45 = i15;
michael@0 16400 i46 = i31;
michael@0 16401 } else {
michael@0 16402 i35 = i40;
michael@0 16403 i41 = -1;
michael@0 16404 i42 = -1;
michael@0 16405 i47 = i32;
michael@0 16406 i48 = i15;
michael@0 16407 i49 = i31;
michael@0 16408 while (1) {
michael@0 16409 i50 = i35 + 20 | 0;
michael@0 16410 i51 = HEAP32[i50 >> 2] | 0;
michael@0 16411 if ((i51 | 0) < 0) {
michael@0 16412 i52 = HEAP32[i2 >> 2] | 0;
michael@0 16413 _memset(i18 | 0, 0, 12);
michael@0 16414 i53 = HEAP32[i26 >> 2] | 0;
michael@0 16415 do {
michael@0 16416 if ((i52 | 0) == (i53 | 0)) {
michael@0 16417 i54 = (i52 | 0) == 0 ? 1 : i52 << 1;
michael@0 16418 if ((i52 | 0) >= (i54 | 0)) {
michael@0 16419 i55 = i52;
michael@0 16420 i56 = i52;
michael@0 16421 break;
michael@0 16422 }
michael@0 16423 if ((i54 | 0) == 0) {
michael@0 16424 i57 = 0;
michael@0 16425 i58 = i52;
michael@0 16426 } else {
michael@0 16427 i59 = __Z22btAlignedAllocInternalji(i54 * 12 | 0, 16) | 0;
michael@0 16428 i57 = i59;
michael@0 16429 i58 = HEAP32[i2 >> 2] | 0;
michael@0 16430 }
michael@0 16431 if ((i58 | 0) > 0) {
michael@0 16432 i59 = 0;
michael@0 16433 do {
michael@0 16434 i60 = i57 + (i59 * 12 | 0) | 0;
michael@0 16435 if ((i60 | 0) != 0) {
michael@0 16436 i61 = i60;
michael@0 16437 i60 = (HEAP32[i27 >> 2] | 0) + (i59 * 12 | 0) | 0;
michael@0 16438 HEAP32[i61 >> 2] = HEAP32[i60 >> 2];
michael@0 16439 HEAP32[i61 + 4 >> 2] = HEAP32[i60 + 4 >> 2];
michael@0 16440 HEAP32[i61 + 8 >> 2] = HEAP32[i60 + 8 >> 2];
michael@0 16441 }
michael@0 16442 i59 = i59 + 1 | 0;
michael@0 16443 } while ((i59 | 0) < (i58 | 0));
michael@0 16444 }
michael@0 16445 i59 = HEAP32[i27 >> 2] | 0;
michael@0 16446 if ((i59 | 0) != 0) {
michael@0 16447 if ((HEAP8[i28] | 0) != 0) {
michael@0 16448 __Z21btAlignedFreeInternalPv(i59);
michael@0 16449 }
michael@0 16450 HEAP32[i27 >> 2] = 0;
michael@0 16451 }
michael@0 16452 HEAP8[i28] = 1;
michael@0 16453 HEAP32[i27 >> 2] = i57;
michael@0 16454 HEAP32[i26 >> 2] = i54;
michael@0 16455 i55 = HEAP32[i2 >> 2] | 0;
michael@0 16456 i56 = i54;
michael@0 16457 } else {
michael@0 16458 i55 = i52;
michael@0 16459 i56 = i53;
michael@0 16460 }
michael@0 16461 } while (0);
michael@0 16462 i53 = (HEAP32[i27 >> 2] | 0) + (i55 * 12 | 0) | 0;
michael@0 16463 if ((i53 | 0) == 0) {
michael@0 16464 i62 = i55;
michael@0 16465 i63 = i56;
michael@0 16466 } else {
michael@0 16467 i36 = i53;
michael@0 16468 HEAP32[i36 >> 2] = HEAP32[i18 >> 2];
michael@0 16469 HEAP32[i36 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 16470 HEAP32[i36 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 16471 i62 = HEAP32[i2 >> 2] | 0;
michael@0 16472 i63 = HEAP32[i26 >> 2] | 0;
michael@0 16473 }
michael@0 16474 i36 = i62 + 1 | 0;
michael@0 16475 HEAP32[i2 >> 2] = i36;
michael@0 16476 _memset(i29 | 0, 0, 12);
michael@0 16477 do {
michael@0 16478 if ((i36 | 0) == (i63 | 0)) {
michael@0 16479 i53 = (i63 | 0) == 0 ? 1 : i63 << 1;
michael@0 16480 if ((i63 | 0) >= (i53 | 0)) {
michael@0 16481 i64 = i63;
michael@0 16482 break;
michael@0 16483 }
michael@0 16484 if ((i53 | 0) == 0) {
michael@0 16485 i65 = 0;
michael@0 16486 i66 = i63;
michael@0 16487 } else {
michael@0 16488 i59 = __Z22btAlignedAllocInternalji(i53 * 12 | 0, 16) | 0;
michael@0 16489 i65 = i59;
michael@0 16490 i66 = HEAP32[i2 >> 2] | 0;
michael@0 16491 }
michael@0 16492 if ((i66 | 0) > 0) {
michael@0 16493 i59 = 0;
michael@0 16494 do {
michael@0 16495 i60 = i65 + (i59 * 12 | 0) | 0;
michael@0 16496 if ((i60 | 0) != 0) {
michael@0 16497 i61 = i60;
michael@0 16498 i60 = (HEAP32[i27 >> 2] | 0) + (i59 * 12 | 0) | 0;
michael@0 16499 HEAP32[i61 >> 2] = HEAP32[i60 >> 2];
michael@0 16500 HEAP32[i61 + 4 >> 2] = HEAP32[i60 + 4 >> 2];
michael@0 16501 HEAP32[i61 + 8 >> 2] = HEAP32[i60 + 8 >> 2];
michael@0 16502 }
michael@0 16503 i59 = i59 + 1 | 0;
michael@0 16504 } while ((i59 | 0) < (i66 | 0));
michael@0 16505 }
michael@0 16506 i59 = HEAP32[i27 >> 2] | 0;
michael@0 16507 if ((i59 | 0) != 0) {
michael@0 16508 if ((HEAP8[i28] | 0) != 0) {
michael@0 16509 __Z21btAlignedFreeInternalPv(i59);
michael@0 16510 }
michael@0 16511 HEAP32[i27 >> 2] = 0;
michael@0 16512 }
michael@0 16513 HEAP8[i28] = 1;
michael@0 16514 HEAP32[i27 >> 2] = i65;
michael@0 16515 HEAP32[i26 >> 2] = i53;
michael@0 16516 i64 = HEAP32[i2 >> 2] | 0;
michael@0 16517 } else {
michael@0 16518 i64 = i36;
michael@0 16519 }
michael@0 16520 } while (0);
michael@0 16521 i36 = HEAP32[i27 >> 2] | 0;
michael@0 16522 i59 = i36 + (i64 * 12 | 0) | 0;
michael@0 16523 if ((i59 | 0) == 0) {
michael@0 16524 i67 = i64;
michael@0 16525 i68 = i36;
michael@0 16526 } else {
michael@0 16527 i36 = i59;
michael@0 16528 HEAP32[i36 >> 2] = HEAP32[i29 >> 2];
michael@0 16529 HEAP32[i36 + 4 >> 2] = HEAP32[i29 + 4 >> 2];
michael@0 16530 HEAP32[i36 + 8 >> 2] = HEAP32[i29 + 8 >> 2];
michael@0 16531 i67 = HEAP32[i2 >> 2] | 0;
michael@0 16532 i68 = HEAP32[i27 >> 2] | 0;
michael@0 16533 }
michael@0 16534 HEAP32[i2 >> 2] = i67 + 1;
michael@0 16535 i36 = i52 + 1 | 0;
michael@0 16536 HEAP32[i50 >> 2] = i52;
michael@0 16537 HEAP32[(HEAP32[i35 + 8 >> 2] | 0) + 20 >> 2] = i36;
michael@0 16538 HEAP32[i68 + (i52 * 12 | 0) + 4 >> 2] = 1;
michael@0 16539 HEAP32[i68 + (i36 * 12 | 0) + 4 >> 2] = -1;
michael@0 16540 i59 = HEAP32[i35 + 12 >> 2] | 0;
michael@0 16541 i54 = i59 + 104 | 0;
michael@0 16542 i60 = HEAP32[i54 >> 2] | 0;
michael@0 16543 if ((i60 | 0) < 0) {
michael@0 16544 HEAP32[i54 >> 2] = i47;
michael@0 16545 do {
michael@0 16546 if ((i47 | 0) == (i48 | 0)) {
michael@0 16547 i54 = (i48 | 0) == 0 ? 1 : i48 << 1;
michael@0 16548 if ((i48 | 0) >= (i54 | 0)) {
michael@0 16549 i69 = i48;
michael@0 16550 i70 = i49;
michael@0 16551 break;
michael@0 16552 }
michael@0 16553 if ((i54 | 0) == 0) {
michael@0 16554 i71 = 0;
michael@0 16555 } else {
michael@0 16556 i71 = __Z22btAlignedAllocInternalji(i54 << 2, 16) | 0;
michael@0 16557 }
michael@0 16558 if ((i48 | 0) > 0) {
michael@0 16559 i61 = 0;
michael@0 16560 do {
michael@0 16561 i72 = i71 + (i61 << 2) | 0;
michael@0 16562 if ((i72 | 0) != 0) {
michael@0 16563 HEAP32[i72 >> 2] = HEAP32[i49 + (i61 << 2) >> 2];
michael@0 16564 }
michael@0 16565 i61 = i61 + 1 | 0;
michael@0 16566 } while ((i61 | 0) < (i48 | 0));
michael@0 16567 }
michael@0 16568 if ((i49 | 0) == 0) {
michael@0 16569 i69 = i54;
michael@0 16570 i70 = i71;
michael@0 16571 break;
michael@0 16572 }
michael@0 16573 __Z21btAlignedFreeInternalPv(i49);
michael@0 16574 i69 = i54;
michael@0 16575 i70 = i71;
michael@0 16576 } else {
michael@0 16577 i69 = i48;
michael@0 16578 i70 = i49;
michael@0 16579 }
michael@0 16580 } while (0);
michael@0 16581 i61 = i70 + (i47 << 2) | 0;
michael@0 16582 if ((i61 | 0) != 0) {
michael@0 16583 HEAP32[i61 >> 2] = i59;
michael@0 16584 }
michael@0 16585 i73 = i47;
michael@0 16586 i74 = i47 + 1 | 0;
michael@0 16587 i75 = i69;
michael@0 16588 i76 = i70;
michael@0 16589 } else {
michael@0 16590 i73 = i60;
michael@0 16591 i74 = i47;
michael@0 16592 i75 = i48;
michael@0 16593 i76 = i49;
michael@0 16594 }
michael@0 16595 HEAP32[i68 + (i52 * 12 | 0) + 8 >> 2] = i73;
michael@0 16596 HEAP32[i68 + (i36 * 12 | 0) + 8 >> 2] = i33;
michael@0 16597 i77 = i74;
michael@0 16598 i78 = i75;
michael@0 16599 i79 = i76;
michael@0 16600 i80 = HEAP32[i50 >> 2] | 0;
michael@0 16601 } else {
michael@0 16602 i77 = i47;
michael@0 16603 i78 = i48;
michael@0 16604 i79 = i49;
michael@0 16605 i80 = i51;
michael@0 16606 }
michael@0 16607 if ((i41 | 0) > -1) {
michael@0 16608 HEAP32[(HEAP32[i27 >> 2] | 0) + (i80 * 12 | 0) >> 2] = i41 - i80;
michael@0 16609 i81 = i42;
michael@0 16610 i82 = HEAP32[i50 >> 2] | 0;
michael@0 16611 } else {
michael@0 16612 i81 = i80;
michael@0 16613 i82 = i80;
michael@0 16614 }
michael@0 16615 i61 = HEAP32[i35 >> 2] | 0;
michael@0 16616 if ((i61 | 0) == (i40 | 0)) {
michael@0 16617 break;
michael@0 16618 } else {
michael@0 16619 i35 = i61;
michael@0 16620 i41 = i82;
michael@0 16621 i42 = i81;
michael@0 16622 i47 = i77;
michael@0 16623 i48 = i78;
michael@0 16624 i49 = i79;
michael@0 16625 }
michael@0 16626 }
michael@0 16627 HEAP32[(HEAP32[i27 >> 2] | 0) + (i81 * 12 | 0) >> 2] = i82 - i81;
michael@0 16628 i44 = i77;
michael@0 16629 i45 = i78;
michael@0 16630 i46 = i79;
michael@0 16631 }
michael@0 16632 i83 = i33 + 1 | 0;
michael@0 16633 if ((i83 | 0) < (i44 | 0)) {
michael@0 16634 i31 = i46;
michael@0 16635 i15 = i45;
michael@0 16636 i32 = i44;
michael@0 16637 i33 = i83;
michael@0 16638 } else {
michael@0 16639 break;
michael@0 16640 }
michael@0 16641 }
michael@0 16642 if ((i83 | 0) > 0) {
michael@0 16643 i33 = i1 + 48 | 0;
michael@0 16644 i32 = i1 + 52 | 0;
michael@0 16645 i15 = i1 + 56 | 0;
michael@0 16646 i31 = 0;
michael@0 16647 do {
michael@0 16648 i27 = HEAP32[(HEAP32[i46 + (i31 << 2) >> 2] | 0) + 8 >> 2] | 0;
michael@0 16649 if ((i27 | 0) != 0) {
michael@0 16650 i2 = i27;
michael@0 16651 do {
michael@0 16652 i29 = i2 + 20 | 0;
michael@0 16653 if ((HEAP32[i29 >> 2] | 0) > -1) {
michael@0 16654 i26 = HEAP32[i16 >> 2] | 0;
michael@0 16655 do {
michael@0 16656 if ((i26 | 0) == (HEAP32[i33 >> 2] | 0)) {
michael@0 16657 i28 = (i26 | 0) == 0 ? 1 : i26 << 1;
michael@0 16658 if ((i26 | 0) >= (i28 | 0)) {
michael@0 16659 i84 = i26;
michael@0 16660 break;
michael@0 16661 }
michael@0 16662 if ((i28 | 0) == 0) {
michael@0 16663 i85 = 0;
michael@0 16664 i86 = i26;
michael@0 16665 } else {
michael@0 16666 i18 = __Z22btAlignedAllocInternalji(i28 << 2, 16) | 0;
michael@0 16667 i85 = i18;
michael@0 16668 i86 = HEAP32[i16 >> 2] | 0;
michael@0 16669 }
michael@0 16670 if ((i86 | 0) > 0) {
michael@0 16671 i18 = 0;
michael@0 16672 do {
michael@0 16673 i5 = i85 + (i18 << 2) | 0;
michael@0 16674 if ((i5 | 0) != 0) {
michael@0 16675 HEAP32[i5 >> 2] = HEAP32[(HEAP32[i32 >> 2] | 0) + (i18 << 2) >> 2];
michael@0 16676 }
michael@0 16677 i18 = i18 + 1 | 0;
michael@0 16678 } while ((i18 | 0) < (i86 | 0));
michael@0 16679 }
michael@0 16680 i18 = HEAP32[i32 >> 2] | 0;
michael@0 16681 if ((i18 | 0) != 0) {
michael@0 16682 if ((HEAP8[i15] | 0) != 0) {
michael@0 16683 __Z21btAlignedFreeInternalPv(i18);
michael@0 16684 }
michael@0 16685 HEAP32[i32 >> 2] = 0;
michael@0 16686 }
michael@0 16687 HEAP8[i15] = 1;
michael@0 16688 HEAP32[i32 >> 2] = i85;
michael@0 16689 HEAP32[i33 >> 2] = i28;
michael@0 16690 i84 = HEAP32[i16 >> 2] | 0;
michael@0 16691 } else {
michael@0 16692 i84 = i26;
michael@0 16693 }
michael@0 16694 } while (0);
michael@0 16695 i26 = (HEAP32[i32 >> 2] | 0) + (i84 << 2) | 0;
michael@0 16696 if ((i26 | 0) == 0) {
michael@0 16697 i87 = i84;
michael@0 16698 } else {
michael@0 16699 HEAP32[i26 >> 2] = HEAP32[i29 >> 2];
michael@0 16700 i87 = HEAP32[i16 >> 2] | 0;
michael@0 16701 }
michael@0 16702 HEAP32[i16 >> 2] = i87 + 1;
michael@0 16703 i26 = i2;
michael@0 16704 do {
michael@0 16705 HEAP32[i26 + 20 >> 2] = -1;
michael@0 16706 i26 = HEAP32[(HEAP32[i26 + 8 >> 2] | 0) + 4 >> 2] | 0;
michael@0 16707 } while ((i26 | 0) != (i2 | 0));
michael@0 16708 }
michael@0 16709 i2 = HEAP32[i2 >> 2] | 0;
michael@0 16710 } while ((i2 | 0) != (i27 | 0));
michael@0 16711 }
michael@0 16712 i31 = i31 + 1 | 0;
michael@0 16713 } while ((i31 | 0) < (i83 | 0));
michael@0 16714 }
michael@0 16715 if ((i46 | 0) == 0) {
michael@0 16716 d23 = d21;
michael@0 16717 break;
michael@0 16718 }
michael@0 16719 __Z21btAlignedFreeInternalPv(i46);
michael@0 16720 d23 = d21;
michael@0 16721 }
michael@0 16722 } while (0);
michael@0 16723 __ZN20btConvexHullInternalD2Ev(i9);
michael@0 16724 d19 = d23;
michael@0 16725 STACKTOP = i8;
michael@0 16726 return +d19;
michael@0 16727 }
michael@0 16728 function __ZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEf(i1, i2, i3, i4, i5, i6, i7, d8) {
michael@0 16729 i1 = i1 | 0;
michael@0 16730 i2 = i2 | 0;
michael@0 16731 i3 = i3 | 0;
michael@0 16732 i4 = i4 | 0;
michael@0 16733 i5 = i5 | 0;
michael@0 16734 i6 = i6 | 0;
michael@0 16735 i7 = i7 | 0;
michael@0 16736 d8 = +d8;
michael@0 16737 var i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, d36 = 0.0, i37 = 0, d38 = 0.0, i39 = 0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, d75 = 0.0, d76 = 0.0, d77 = 0.0, d78 = 0.0, d79 = 0.0, d80 = 0.0, i81 = 0, d82 = 0.0, d83 = 0.0, d84 = 0.0, d85 = 0.0, d86 = 0.0, d87 = 0.0, d88 = 0.0, d89 = 0.0, d90 = 0.0, d91 = 0.0, d92 = 0.0, d93 = 0.0, d94 = 0.0, d95 = 0.0, d96 = 0.0, d97 = 0.0, d98 = 0.0, d99 = 0.0;
michael@0 16738 i9 = STACKTOP;
michael@0 16739 STACKTOP = STACKTOP + 1656 | 0;
michael@0 16740 i10 = i9 | 0;
michael@0 16741 i11 = i9 + 176 | 0;
michael@0 16742 i12 = i9 + 536 | 0;
michael@0 16743 i13 = i9 + 544 | 0;
michael@0 16744 i14 = i9 + 568 | 0;
michael@0 16745 i15 = i9 + 616 | 0;
michael@0 16746 i16 = i9 + 632 | 0;
michael@0 16747 i17 = i9 + 648 | 0;
michael@0 16748 i18 = i9 + 712 | 0;
michael@0 16749 i19 = i9 + 936 | 0;
michael@0 16750 i20 = i9 + 952 | 0;
michael@0 16751 i21 = i9 + 968 | 0;
michael@0 16752 i22 = i9 + 1144 | 0;
michael@0 16753 i23 = i9 + 1168 | 0;
michael@0 16754 i24 = i9 + 1216 | 0;
michael@0 16755 i25 = i9 + 1280 | 0;
michael@0 16756 i26 = i9 + 1504 | 0;
michael@0 16757 i27 = i9 + 1520 | 0;
michael@0 16758 i28 = i9 + 1536 | 0;
michael@0 16759 i29 = i9 + 1552 | 0;
michael@0 16760 i30 = i9 + 1568 | 0;
michael@0 16761 i31 = i9 + 1632 | 0;
michael@0 16762 i32 = HEAP32[i5 + 4 >> 2] | 0;
michael@0 16763 if ((i32 | 0) < 20) {
michael@0 16764 HEAP32[i10 >> 2] = 2280;
michael@0 16765 i33 = i10 + 164 | 0;
michael@0 16766 HEAP32[i10 + 168 >> 2] = 0;
michael@0 16767 HEAPF32[i10 + 172 >> 2] = d8;
michael@0 16768 i34 = i7 + 4 | 0;
michael@0 16769 HEAPF32[i33 >> 2] = +HEAPF32[i34 >> 2];
michael@0 16770 HEAPF32[i11 + 308 >> 2] = 9999999747378752.0e-20;
michael@0 16771 HEAP16[i11 + 332 >> 1] = 0;
michael@0 16772 HEAP32[i12 >> 2] = 2696;
michael@0 16773 __ZN27btContinuousConvexCollisionC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i13, i1, i5, i11, i12 | 0);
michael@0 16774 i12 = i13 | 0;
michael@0 16775 do {
michael@0 16776 if (FUNCTION_TABLE_iiiiiii[HEAP32[(HEAP32[i13 >> 2] | 0) + 8 >> 2] & 7](i12, i2, i3, i6, i6, i10) | 0) {
michael@0 16777 i11 = i10 + 132 | 0;
michael@0 16778 i35 = i11 | 0;
michael@0 16779 d36 = +HEAPF32[i35 >> 2];
michael@0 16780 i37 = i10 + 136 | 0;
michael@0 16781 d38 = +HEAPF32[i37 >> 2];
michael@0 16782 i39 = i10 + 140 | 0;
michael@0 16783 d40 = +HEAPF32[i39 >> 2];
michael@0 16784 d41 = d36 * d36 + d38 * d38 + d40 * d40;
michael@0 16785 if (d41 <= 9999999747378752.0e-20) {
michael@0 16786 break;
michael@0 16787 }
michael@0 16788 d42 = +HEAPF32[i33 >> 2];
michael@0 16789 if (d42 >= +HEAPF32[i34 >> 2]) {
michael@0 16790 break;
michael@0 16791 }
michael@0 16792 d43 = 1.0 / +Math_sqrt(+d41);
michael@0 16793 HEAPF32[i35 >> 2] = d36 * d43;
michael@0 16794 HEAPF32[i37 >> 2] = d38 * d43;
michael@0 16795 HEAPF32[i39 >> 2] = d40 * d43;
michael@0 16796 HEAP32[i14 >> 2] = i4;
michael@0 16797 HEAP32[i14 + 4 >> 2] = 0;
michael@0 16798 i39 = i14 + 8 | 0;
michael@0 16799 i37 = i11;
michael@0 16800 HEAP32[i39 >> 2] = HEAP32[i37 >> 2];
michael@0 16801 HEAP32[i39 + 4 >> 2] = HEAP32[i37 + 4 >> 2];
michael@0 16802 HEAP32[i39 + 8 >> 2] = HEAP32[i37 + 8 >> 2];
michael@0 16803 HEAP32[i39 + 12 >> 2] = HEAP32[i37 + 12 >> 2];
michael@0 16804 i37 = i14 + 24 | 0;
michael@0 16805 i39 = i10 + 148 | 0;
michael@0 16806 HEAP32[i37 >> 2] = HEAP32[i39 >> 2];
michael@0 16807 HEAP32[i37 + 4 >> 2] = HEAP32[i39 + 4 >> 2];
michael@0 16808 HEAP32[i37 + 8 >> 2] = HEAP32[i39 + 8 >> 2];
michael@0 16809 HEAP32[i37 + 12 >> 2] = HEAP32[i39 + 12 >> 2];
michael@0 16810 HEAPF32[i14 + 40 >> 2] = d42;
michael@0 16811 i39 = HEAP32[(HEAP32[i7 >> 2] | 0) + 12 >> 2] | 0;
michael@0 16812 +FUNCTION_TABLE_fiii[i39 & 15](i7, i14, 1);
michael@0 16813 }
michael@0 16814 } while (0);
michael@0 16815 __ZN12btConvexCastD2Ev(i12);
michael@0 16816 STACKTOP = i9;
michael@0 16817 return;
michael@0 16818 }
michael@0 16819 if ((i32 - 21 | 0) >>> 0 >= 9) {
michael@0 16820 if ((i32 | 0) != 31) {
michael@0 16821 STACKTOP = i9;
michael@0 16822 return;
michael@0 16823 }
michael@0 16824 __ZN15CProfileManager13Start_ProfileEPKc(96);
michael@0 16825 i12 = i5 + 16 | 0;
michael@0 16826 if ((HEAP32[i12 >> 2] | 0) > 0) {
michael@0 16827 i14 = i5 + 24 | 0;
michael@0 16828 i10 = i6 | 0;
michael@0 16829 i34 = i6 + 4 | 0;
michael@0 16830 i33 = i6 + 8 | 0;
michael@0 16831 i13 = i6 + 16 | 0;
michael@0 16832 i39 = i6 + 20 | 0;
michael@0 16833 i37 = i6 + 24 | 0;
michael@0 16834 i11 = i6 + 32 | 0;
michael@0 16835 i35 = i6 + 36 | 0;
michael@0 16836 i44 = i6 + 40 | 0;
michael@0 16837 i45 = i6 + 48 | 0;
michael@0 16838 i46 = i6 + 52 | 0;
michael@0 16839 i47 = i6 + 56 | 0;
michael@0 16840 i48 = i30 | 0;
michael@0 16841 i49 = i30 + 4 | 0;
michael@0 16842 i50 = i30 + 8 | 0;
michael@0 16843 i51 = i30 + 12 | 0;
michael@0 16844 i52 = i30 + 16 | 0;
michael@0 16845 i53 = i30 + 20 | 0;
michael@0 16846 i54 = i30 + 24 | 0;
michael@0 16847 i55 = i30 + 28 | 0;
michael@0 16848 i56 = i30 + 32 | 0;
michael@0 16849 i57 = i30 + 36 | 0;
michael@0 16850 i58 = i30 + 40 | 0;
michael@0 16851 i59 = i30 + 44 | 0;
michael@0 16852 i60 = i30 + 48 | 0;
michael@0 16853 i61 = i30 + 52 | 0;
michael@0 16854 i62 = i30 + 56 | 0;
michael@0 16855 i63 = i30 + 60 | 0;
michael@0 16856 i64 = i4 + 192 | 0;
michael@0 16857 i65 = i31 | 0;
michael@0 16858 i66 = i31 + 4 | 0;
michael@0 16859 i67 = i31 + 8 | 0;
michael@0 16860 i68 = i31 + 10 | 0;
michael@0 16861 i69 = i31 + 12 | 0;
michael@0 16862 i70 = i31 + 16 | 0;
michael@0 16863 i71 = i7 + 4 | 0;
michael@0 16864 i72 = i31 | 0;
michael@0 16865 i31 = HEAP32[i64 >> 2] | 0;
michael@0 16866 i73 = 0;
michael@0 16867 do {
michael@0 16868 i74 = HEAP32[i14 >> 2] | 0;
michael@0 16869 d42 = +HEAPF32[i74 + (i73 * 80 | 0) >> 2];
michael@0 16870 d43 = +HEAPF32[i74 + (i73 * 80 | 0) + 4 >> 2];
michael@0 16871 d40 = +HEAPF32[i74 + (i73 * 80 | 0) + 8 >> 2];
michael@0 16872 d38 = +HEAPF32[i74 + (i73 * 80 | 0) + 16 >> 2];
michael@0 16873 d36 = +HEAPF32[i74 + (i73 * 80 | 0) + 20 >> 2];
michael@0 16874 d41 = +HEAPF32[i74 + (i73 * 80 | 0) + 24 >> 2];
michael@0 16875 d75 = +HEAPF32[i74 + (i73 * 80 | 0) + 32 >> 2];
michael@0 16876 d76 = +HEAPF32[i74 + (i73 * 80 | 0) + 36 >> 2];
michael@0 16877 d77 = +HEAPF32[i74 + (i73 * 80 | 0) + 40 >> 2];
michael@0 16878 d78 = +HEAPF32[i74 + (i73 * 80 | 0) + 48 >> 2];
michael@0 16879 d79 = +HEAPF32[i74 + (i73 * 80 | 0) + 52 >> 2];
michael@0 16880 d80 = +HEAPF32[i74 + (i73 * 80 | 0) + 56 >> 2];
michael@0 16881 i81 = HEAP32[i74 + (i73 * 80 | 0) + 64 >> 2] | 0;
michael@0 16882 d82 = +HEAPF32[i10 >> 2];
michael@0 16883 d83 = +HEAPF32[i34 >> 2];
michael@0 16884 d84 = +HEAPF32[i33 >> 2];
michael@0 16885 d85 = +HEAPF32[i13 >> 2];
michael@0 16886 d86 = +HEAPF32[i39 >> 2];
michael@0 16887 d87 = +HEAPF32[i37 >> 2];
michael@0 16888 d88 = +HEAPF32[i11 >> 2];
michael@0 16889 d89 = +HEAPF32[i35 >> 2];
michael@0 16890 d90 = +HEAPF32[i44 >> 2];
michael@0 16891 d91 = d78 * d82 + d79 * d83 + d80 * d84 + +HEAPF32[i45 >> 2];
michael@0 16892 d92 = d78 * d85 + d79 * d86 + d80 * d87 + +HEAPF32[i46 >> 2];
michael@0 16893 d93 = d78 * d88 + d79 * d89 + d80 * d90 + +HEAPF32[i47 >> 2];
michael@0 16894 HEAPF32[i48 >> 2] = d42 * d82 + d38 * d83 + d75 * d84;
michael@0 16895 HEAPF32[i49 >> 2] = d43 * d82 + d36 * d83 + d76 * d84;
michael@0 16896 HEAPF32[i50 >> 2] = d40 * d82 + d41 * d83 + d77 * d84;
michael@0 16897 HEAPF32[i51 >> 2] = 0.0;
michael@0 16898 HEAPF32[i52 >> 2] = d42 * d85 + d38 * d86 + d75 * d87;
michael@0 16899 HEAPF32[i53 >> 2] = d43 * d85 + d36 * d86 + d76 * d87;
michael@0 16900 HEAPF32[i54 >> 2] = d40 * d85 + d41 * d86 + d77 * d87;
michael@0 16901 HEAPF32[i55 >> 2] = 0.0;
michael@0 16902 HEAPF32[i56 >> 2] = d42 * d88 + d38 * d89 + d75 * d90;
michael@0 16903 HEAPF32[i57 >> 2] = d43 * d88 + d36 * d89 + d76 * d90;
michael@0 16904 HEAPF32[i58 >> 2] = d40 * d88 + d41 * d89 + d77 * d90;
michael@0 16905 HEAPF32[i59 >> 2] = 0.0;
michael@0 16906 HEAPF32[i60 >> 2] = d91;
michael@0 16907 HEAPF32[i61 >> 2] = d92;
michael@0 16908 HEAPF32[i62 >> 2] = d93;
michael@0 16909 HEAPF32[i63 >> 2] = 0.0;
michael@0 16910 HEAP32[i64 >> 2] = i81;
michael@0 16911 HEAP16[i67 >> 1] = 1;
michael@0 16912 HEAP16[i68 >> 1] = -1;
michael@0 16913 HEAP32[i65 >> 2] = 1720;
michael@0 16914 HEAP32[i69 >> 2] = i7;
michael@0 16915 HEAP32[i70 >> 2] = i73;
michael@0 16916 HEAPF32[i66 >> 2] = +HEAPF32[i71 >> 2];
michael@0 16917 __ZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEf(i1, i2, i3, i4, i81, i30, i72, d8);
michael@0 16918 HEAP32[i64 >> 2] = i31;
michael@0 16919 i73 = i73 + 1 | 0;
michael@0 16920 } while ((i73 | 0) < (HEAP32[i12 >> 2] | 0));
michael@0 16921 }
michael@0 16922 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 16923 STACKTOP = i9;
michael@0 16924 return;
michael@0 16925 }
michael@0 16926 if ((i32 | 0) == 21) {
michael@0 16927 d93 = +HEAPF32[i6 >> 2];
michael@0 16928 d92 = +HEAPF32[i6 + 16 >> 2];
michael@0 16929 d91 = +HEAPF32[i6 + 32 >> 2];
michael@0 16930 d90 = +HEAPF32[i6 + 4 >> 2];
michael@0 16931 d77 = +HEAPF32[i6 + 20 >> 2];
michael@0 16932 d89 = +HEAPF32[i6 + 36 >> 2];
michael@0 16933 d41 = +HEAPF32[i6 + 8 >> 2];
michael@0 16934 d88 = +HEAPF32[i6 + 24 >> 2];
michael@0 16935 d40 = +HEAPF32[i6 + 40 >> 2];
michael@0 16936 d76 = -0.0 - +HEAPF32[i6 + 48 >> 2];
michael@0 16937 d36 = -0.0 - +HEAPF32[i6 + 52 >> 2];
michael@0 16938 d43 = -0.0 - +HEAPF32[i6 + 56 >> 2];
michael@0 16939 d75 = d93 * d76 + d92 * d36 + d91 * d43;
michael@0 16940 d38 = d90 * d76 + d77 * d36 + d89 * d43;
michael@0 16941 d42 = d41 * d76 + d88 * d36 + d40 * d43;
michael@0 16942 d43 = +HEAPF32[i2 + 48 >> 2];
michael@0 16943 d36 = +HEAPF32[i2 + 52 >> 2];
michael@0 16944 d76 = +HEAPF32[i2 + 56 >> 2];
michael@0 16945 HEAPF32[i15 >> 2] = d75 + (d93 * d43 + d92 * d36 + d91 * d76);
michael@0 16946 HEAPF32[i15 + 4 >> 2] = d38 + (d90 * d43 + d77 * d36 + d89 * d76);
michael@0 16947 HEAPF32[i15 + 8 >> 2] = d42 + (d41 * d43 + d88 * d36 + d40 * d76);
michael@0 16948 HEAPF32[i15 + 12 >> 2] = 0.0;
michael@0 16949 d76 = +HEAPF32[i3 + 48 >> 2];
michael@0 16950 d36 = +HEAPF32[i3 + 52 >> 2];
michael@0 16951 d43 = +HEAPF32[i3 + 56 >> 2];
michael@0 16952 HEAPF32[i16 >> 2] = d75 + (d93 * d76 + d92 * d36 + d91 * d43);
michael@0 16953 HEAPF32[i16 + 4 >> 2] = d38 + (d90 * d76 + d77 * d36 + d89 * d43);
michael@0 16954 HEAPF32[i16 + 8 >> 2] = d42 + (d41 * d76 + d88 * d36 + d40 * d43);
michael@0 16955 HEAPF32[i16 + 12 >> 2] = 0.0;
michael@0 16956 d43 = +HEAPF32[i3 >> 2];
michael@0 16957 d36 = +HEAPF32[i3 + 16 >> 2];
michael@0 16958 d76 = +HEAPF32[i3 + 32 >> 2];
michael@0 16959 d42 = +HEAPF32[i3 + 4 >> 2];
michael@0 16960 d38 = +HEAPF32[i3 + 20 >> 2];
michael@0 16961 d75 = +HEAPF32[i3 + 36 >> 2];
michael@0 16962 d87 = +HEAPF32[i3 + 8 >> 2];
michael@0 16963 d86 = +HEAPF32[i3 + 24 >> 2];
michael@0 16964 d85 = +HEAPF32[i3 + 40 >> 2];
michael@0 16965 HEAPF32[i17 >> 2] = d93 * d43 + d92 * d36 + d91 * d76;
michael@0 16966 HEAPF32[i17 + 4 >> 2] = d93 * d42 + d92 * d38 + d91 * d75;
michael@0 16967 HEAPF32[i17 + 8 >> 2] = d93 * d87 + d92 * d86 + d91 * d85;
michael@0 16968 HEAPF32[i17 + 12 >> 2] = 0.0;
michael@0 16969 HEAPF32[i17 + 16 >> 2] = d90 * d43 + d77 * d36 + d89 * d76;
michael@0 16970 HEAPF32[i17 + 20 >> 2] = d90 * d42 + d77 * d38 + d89 * d75;
michael@0 16971 HEAPF32[i17 + 24 >> 2] = d90 * d87 + d77 * d86 + d89 * d85;
michael@0 16972 HEAPF32[i17 + 28 >> 2] = 0.0;
michael@0 16973 HEAPF32[i17 + 32 >> 2] = d41 * d43 + d88 * d36 + d40 * d76;
michael@0 16974 HEAPF32[i17 + 36 >> 2] = d41 * d42 + d88 * d38 + d40 * d75;
michael@0 16975 HEAPF32[i17 + 40 >> 2] = d41 * d87 + d88 * d86 + d40 * d85;
michael@0 16976 _memset(i17 + 44 | 0, 0, 20);
michael@0 16977 __ZN28btTriangleConvexcastCallbackC2EPK13btConvexShapeRK11btTransformS5_S5_f(i18 | 0, i1, i2, i3, i6, +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i5 >> 2] | 0) + 44 >> 2] & 7](i5));
michael@0 16978 HEAP32[i18 >> 2] = 1688;
michael@0 16979 HEAP32[i18 + 212 >> 2] = i7;
michael@0 16980 HEAP32[i18 + 216 >> 2] = i4;
michael@0 16981 HEAP32[i18 + 220 >> 2] = i5;
michael@0 16982 HEAPF32[i18 + 200 >> 2] = +HEAPF32[i7 + 4 >> 2];
michael@0 16983 HEAPF32[i18 + 208 >> 2] = d8;
michael@0 16984 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i1, i17, i19, i20);
michael@0 16985 i17 = i18 | 0;
michael@0 16986 __ZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_(i5, i17, i15, i16, i19, i20);
michael@0 16987 __ZN18btTriangleCallbackD2Ev(i17);
michael@0 16988 STACKTOP = i9;
michael@0 16989 return;
michael@0 16990 } else if ((i32 | 0) == 28) {
michael@0 16991 HEAP32[i21 >> 2] = 2280;
michael@0 16992 i32 = i21 + 164 | 0;
michael@0 16993 HEAP32[i21 + 168 >> 2] = 0;
michael@0 16994 HEAPF32[i21 + 172 >> 2] = d8;
michael@0 16995 i17 = i7 + 4 | 0;
michael@0 16996 HEAPF32[i32 >> 2] = +HEAPF32[i17 >> 2];
michael@0 16997 __ZN27btContinuousConvexCollisionC2EPK13btConvexShapePK18btStaticPlaneShape(i22, i1, i5);
michael@0 16998 i20 = i22 | 0;
michael@0 16999 do {
michael@0 17000 if (FUNCTION_TABLE_iiiiiii[HEAP32[(HEAP32[i22 >> 2] | 0) + 8 >> 2] & 7](i20, i2, i3, i6, i6, i21) | 0) {
michael@0 17001 i19 = i21 + 132 | 0;
michael@0 17002 i16 = i19 | 0;
michael@0 17003 d85 = +HEAPF32[i16 >> 2];
michael@0 17004 i15 = i21 + 136 | 0;
michael@0 17005 d40 = +HEAPF32[i15 >> 2];
michael@0 17006 i18 = i21 + 140 | 0;
michael@0 17007 d86 = +HEAPF32[i18 >> 2];
michael@0 17008 d88 = d85 * d85 + d40 * d40 + d86 * d86;
michael@0 17009 if (d88 <= 9999999747378752.0e-20) {
michael@0 17010 break;
michael@0 17011 }
michael@0 17012 d87 = +HEAPF32[i32 >> 2];
michael@0 17013 if (d87 >= +HEAPF32[i17 >> 2]) {
michael@0 17014 break;
michael@0 17015 }
michael@0 17016 d41 = 1.0 / +Math_sqrt(+d88);
michael@0 17017 HEAPF32[i16 >> 2] = d85 * d41;
michael@0 17018 HEAPF32[i15 >> 2] = d40 * d41;
michael@0 17019 HEAPF32[i18 >> 2] = d86 * d41;
michael@0 17020 HEAP32[i23 >> 2] = i4;
michael@0 17021 HEAP32[i23 + 4 >> 2] = 0;
michael@0 17022 i18 = i23 + 8 | 0;
michael@0 17023 i15 = i19;
michael@0 17024 HEAP32[i18 >> 2] = HEAP32[i15 >> 2];
michael@0 17025 HEAP32[i18 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 17026 HEAP32[i18 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 17027 HEAP32[i18 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 17028 i15 = i23 + 24 | 0;
michael@0 17029 i18 = i21 + 148 | 0;
michael@0 17030 HEAP32[i15 >> 2] = HEAP32[i18 >> 2];
michael@0 17031 HEAP32[i15 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 17032 HEAP32[i15 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 17033 HEAP32[i15 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 17034 HEAPF32[i23 + 40 >> 2] = d87;
michael@0 17035 i18 = HEAP32[(HEAP32[i7 >> 2] | 0) + 12 >> 2] | 0;
michael@0 17036 +FUNCTION_TABLE_fiii[i18 & 15](i7, i23, 1);
michael@0 17037 }
michael@0 17038 } while (0);
michael@0 17039 __ZN12btConvexCastD2Ev(i20);
michael@0 17040 STACKTOP = i9;
michael@0 17041 return;
michael@0 17042 } else {
michael@0 17043 i20 = i5;
michael@0 17044 d87 = +HEAPF32[i6 >> 2];
michael@0 17045 d41 = +HEAPF32[i6 + 16 >> 2];
michael@0 17046 d86 = +HEAPF32[i6 + 32 >> 2];
michael@0 17047 d40 = +HEAPF32[i6 + 4 >> 2];
michael@0 17048 d85 = +HEAPF32[i6 + 20 >> 2];
michael@0 17049 d88 = +HEAPF32[i6 + 36 >> 2];
michael@0 17050 d75 = +HEAPF32[i6 + 8 >> 2];
michael@0 17051 d38 = +HEAPF32[i6 + 24 >> 2];
michael@0 17052 d42 = +HEAPF32[i6 + 40 >> 2];
michael@0 17053 d76 = -0.0 - +HEAPF32[i6 + 48 >> 2];
michael@0 17054 d36 = -0.0 - +HEAPF32[i6 + 52 >> 2];
michael@0 17055 d43 = -0.0 - +HEAPF32[i6 + 56 >> 2];
michael@0 17056 d89 = d87 * d76 + d41 * d36 + d86 * d43;
michael@0 17057 d77 = d40 * d76 + d85 * d36 + d88 * d43;
michael@0 17058 d90 = d75 * d76 + d38 * d36 + d42 * d43;
michael@0 17059 d43 = +HEAPF32[i2 + 48 >> 2];
michael@0 17060 d36 = +HEAPF32[i2 + 52 >> 2];
michael@0 17061 d76 = +HEAPF32[i2 + 56 >> 2];
michael@0 17062 d91 = d89 + (d87 * d43 + d41 * d36 + d86 * d76);
michael@0 17063 d92 = d77 + (d40 * d43 + d85 * d36 + d88 * d76);
michael@0 17064 d93 = d90 + (d75 * d43 + d38 * d36 + d42 * d76);
michael@0 17065 d76 = +HEAPF32[i3 + 48 >> 2];
michael@0 17066 d36 = +HEAPF32[i3 + 52 >> 2];
michael@0 17067 d43 = +HEAPF32[i3 + 56 >> 2];
michael@0 17068 d84 = d89 + (d87 * d76 + d41 * d36 + d86 * d43);
michael@0 17069 d89 = d77 + (d40 * d76 + d85 * d36 + d88 * d43);
michael@0 17070 d77 = d90 + (d75 * d76 + d38 * d36 + d42 * d43);
michael@0 17071 d43 = +HEAPF32[i3 >> 2];
michael@0 17072 d36 = +HEAPF32[i3 + 16 >> 2];
michael@0 17073 d76 = +HEAPF32[i3 + 32 >> 2];
michael@0 17074 d90 = +HEAPF32[i3 + 4 >> 2];
michael@0 17075 d83 = +HEAPF32[i3 + 20 >> 2];
michael@0 17076 d82 = +HEAPF32[i3 + 36 >> 2];
michael@0 17077 d80 = +HEAPF32[i3 + 8 >> 2];
michael@0 17078 d79 = +HEAPF32[i3 + 24 >> 2];
michael@0 17079 d78 = +HEAPF32[i3 + 40 >> 2];
michael@0 17080 HEAPF32[i24 >> 2] = d87 * d43 + d41 * d36 + d86 * d76;
michael@0 17081 HEAPF32[i24 + 4 >> 2] = d87 * d90 + d41 * d83 + d86 * d82;
michael@0 17082 HEAPF32[i24 + 8 >> 2] = d87 * d80 + d41 * d79 + d86 * d78;
michael@0 17083 HEAPF32[i24 + 12 >> 2] = 0.0;
michael@0 17084 HEAPF32[i24 + 16 >> 2] = d40 * d43 + d85 * d36 + d88 * d76;
michael@0 17085 HEAPF32[i24 + 20 >> 2] = d40 * d90 + d85 * d83 + d88 * d82;
michael@0 17086 HEAPF32[i24 + 24 >> 2] = d40 * d80 + d85 * d79 + d88 * d78;
michael@0 17087 HEAPF32[i24 + 28 >> 2] = 0.0;
michael@0 17088 HEAPF32[i24 + 32 >> 2] = d75 * d43 + d38 * d36 + d42 * d76;
michael@0 17089 HEAPF32[i24 + 36 >> 2] = d75 * d90 + d38 * d83 + d42 * d82;
michael@0 17090 HEAPF32[i24 + 40 >> 2] = d75 * d80 + d38 * d79 + d42 * d78;
michael@0 17091 _memset(i24 + 44 | 0, 0, 20);
michael@0 17092 __ZN28btTriangleConvexcastCallbackC2EPK13btConvexShapeRK11btTransformS5_S5_f(i25 | 0, i1, i2, i3, i6, +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i5 >> 2] | 0) + 44 >> 2] & 7](i20));
michael@0 17093 HEAP32[i25 >> 2] = 1656;
michael@0 17094 HEAP32[i25 + 212 >> 2] = i7;
michael@0 17095 HEAP32[i25 + 216 >> 2] = i4;
michael@0 17096 HEAP32[i25 + 220 >> 2] = i20;
michael@0 17097 HEAPF32[i25 + 200 >> 2] = +HEAPF32[i7 + 4 >> 2];
michael@0 17098 HEAPF32[i25 + 208 >> 2] = d8;
michael@0 17099 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i1, i24, i26, i27);
michael@0 17100 i24 = i28 | 0;
michael@0 17101 HEAPF32[i24 >> 2] = d91;
michael@0 17102 i1 = i28 + 4 | 0;
michael@0 17103 HEAPF32[i1 >> 2] = d92;
michael@0 17104 i7 = i28 + 8 | 0;
michael@0 17105 HEAPF32[i7 >> 2] = d93;
michael@0 17106 HEAPF32[i28 + 12 >> 2] = 0.0;
michael@0 17107 if (d84 < d91) {
michael@0 17108 HEAPF32[i24 >> 2] = d84;
michael@0 17109 d94 = d84;
michael@0 17110 } else {
michael@0 17111 d94 = d91;
michael@0 17112 }
michael@0 17113 if (d89 < d92) {
michael@0 17114 HEAPF32[i1 >> 2] = d89;
michael@0 17115 d95 = d89;
michael@0 17116 } else {
michael@0 17117 d95 = d92;
michael@0 17118 }
michael@0 17119 if (d77 < d93) {
michael@0 17120 HEAPF32[i7 >> 2] = d77;
michael@0 17121 d96 = d77;
michael@0 17122 } else {
michael@0 17123 d96 = d93;
michael@0 17124 }
michael@0 17125 i4 = i29 | 0;
michael@0 17126 HEAPF32[i4 >> 2] = d91;
michael@0 17127 i6 = i29 + 4 | 0;
michael@0 17128 HEAPF32[i6 >> 2] = d92;
michael@0 17129 i3 = i29 + 8 | 0;
michael@0 17130 HEAPF32[i3 >> 2] = d93;
michael@0 17131 HEAPF32[i29 + 12 >> 2] = 0.0;
michael@0 17132 if (d91 < d84) {
michael@0 17133 HEAPF32[i4 >> 2] = d84;
michael@0 17134 d97 = d84;
michael@0 17135 } else {
michael@0 17136 d97 = d91;
michael@0 17137 }
michael@0 17138 if (d92 < d89) {
michael@0 17139 HEAPF32[i6 >> 2] = d89;
michael@0 17140 d98 = d89;
michael@0 17141 } else {
michael@0 17142 d98 = d92;
michael@0 17143 }
michael@0 17144 if (d93 < d77) {
michael@0 17145 HEAPF32[i3 >> 2] = d77;
michael@0 17146 d99 = d77;
michael@0 17147 } else {
michael@0 17148 d99 = d93;
michael@0 17149 }
michael@0 17150 HEAPF32[i24 >> 2] = d94 + +HEAPF32[i26 >> 2];
michael@0 17151 HEAPF32[i1 >> 2] = d95 + +HEAPF32[i26 + 4 >> 2];
michael@0 17152 HEAPF32[i7 >> 2] = d96 + +HEAPF32[i26 + 8 >> 2];
michael@0 17153 HEAPF32[i4 >> 2] = d97 + +HEAPF32[i27 >> 2];
michael@0 17154 HEAPF32[i6 >> 2] = d98 + +HEAPF32[i27 + 4 >> 2];
michael@0 17155 HEAPF32[i3 >> 2] = d99 + +HEAPF32[i27 + 8 >> 2];
michael@0 17156 i27 = i25 | 0;
michael@0 17157 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i5 >> 2] | 0) + 60 >> 2] & 127](i20, i27, i28, i29);
michael@0 17158 __ZN18btTriangleCallbackD2Ev(i27);
michael@0 17159 STACKTOP = i9;
michael@0 17160 return;
michael@0 17161 }
michael@0 17162 }
michael@0 17163 function __ZN35btSequentialImpulseConstraintSolver28solveGroupCacheFriendlySetupEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
michael@0 17164 i1 = i1 | 0;
michael@0 17165 i2 = i2 | 0;
michael@0 17166 i3 = i3 | 0;
michael@0 17167 i4 = i4 | 0;
michael@0 17168 i5 = i5 | 0;
michael@0 17169 i6 = i6 | 0;
michael@0 17170 i7 = i7 | 0;
michael@0 17171 i8 = i8 | 0;
michael@0 17172 i9 = i9 | 0;
michael@0 17173 i10 = i10 | 0;
michael@0 17174 var i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, d46 = 0.0, d47 = 0.0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, d81 = 0.0, d82 = 0.0, d83 = 0.0, d84 = 0.0, d85 = 0.0, d86 = 0.0, d87 = 0.0, d88 = 0.0, d89 = 0.0, d90 = 0.0, d91 = 0.0, i92 = 0, i93 = 0, i94 = 0, i95 = 0, i96 = 0, i97 = 0;
michael@0 17175 i10 = STACKTOP;
michael@0 17176 STACKTOP = STACKTOP + 192 | 0;
michael@0 17177 i9 = i10 | 0;
michael@0 17178 i11 = i10 + 136 | 0;
michael@0 17179 __ZN15CProfileManager13Start_ProfileEPKc(408);
michael@0 17180 if ((i7 | 0) == (-i5 | 0)) {
michael@0 17181 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 17182 STACKTOP = i10;
michael@0 17183 return +0.0;
michael@0 17184 }
michael@0 17185 i12 = (i3 | 0) > 0;
michael@0 17186 do {
michael@0 17187 if ((HEAP32[i8 + 44 >> 2] | 0) == 0) {
michael@0 17188 if (i12) {
michael@0 17189 i13 = 0;
michael@0 17190 } else {
michael@0 17191 break;
michael@0 17192 }
michael@0 17193 do {
michael@0 17194 i14 = HEAP32[i2 + (i13 << 2) >> 2] | 0;
michael@0 17195 if (!((HEAP32[i14 + 232 >> 2] & 2 | 0) == 0 | (i14 | 0) == 0)) {
michael@0 17196 _memset(i14 + 504 | 0, 0, 32);
michael@0 17197 }
michael@0 17198 i13 = i13 + 1 | 0;
michael@0 17199 } while ((i13 | 0) < (i3 | 0));
michael@0 17200 } else {
michael@0 17201 if (i12) {
michael@0 17202 i15 = 0;
michael@0 17203 } else {
michael@0 17204 break;
michael@0 17205 }
michael@0 17206 do {
michael@0 17207 i14 = HEAP32[i2 + (i15 << 2) >> 2] | 0;
michael@0 17208 if (!((HEAP32[i14 + 232 >> 2] & 2 | 0) == 0 | (i14 | 0) == 0)) {
michael@0 17209 _memset(i14 + 504 | 0, 0, 32);
michael@0 17210 _memset(i14 + 568 | 0, 0, 32);
michael@0 17211 }
michael@0 17212 i15 = i15 + 1 | 0;
michael@0 17213 } while ((i15 | 0) < (i3 | 0));
michael@0 17214 }
michael@0 17215 } while (0);
michael@0 17216 i3 = (i7 | 0) > 0;
michael@0 17217 if (i3) {
michael@0 17218 i15 = 0;
michael@0 17219 do {
michael@0 17220 i2 = HEAP32[i6 + (i15 << 2) >> 2] | 0;
michael@0 17221 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i2 >> 2] | 0) + 8 >> 2] & 511](i2);
michael@0 17222 HEAPF32[i2 + 32 >> 2] = 0.0;
michael@0 17223 i15 = i15 + 1 | 0;
michael@0 17224 } while ((i15 | 0) < (i7 | 0));
michael@0 17225 }
michael@0 17226 i15 = i1 + 108 | 0;
michael@0 17227 i2 = HEAP32[i15 >> 2] | 0;
michael@0 17228 if ((i2 | 0) < (i7 | 0)) {
michael@0 17229 i12 = i1 + 112 | 0;
michael@0 17230 if ((HEAP32[i12 >> 2] | 0) < (i7 | 0)) {
michael@0 17231 if ((i7 | 0) == 0) {
michael@0 17232 i16 = 0;
michael@0 17233 i17 = i2;
michael@0 17234 } else {
michael@0 17235 i13 = __Z22btAlignedAllocInternalji(i7 << 3, 16) | 0;
michael@0 17236 i16 = i13;
michael@0 17237 i17 = HEAP32[i15 >> 2] | 0;
michael@0 17238 }
michael@0 17239 i13 = i1 + 116 | 0;
michael@0 17240 if ((i17 | 0) > 0) {
michael@0 17241 i14 = 0;
michael@0 17242 do {
michael@0 17243 i18 = i16 + (i14 << 3) | 0;
michael@0 17244 if ((i18 | 0) != 0) {
michael@0 17245 i19 = (HEAP32[i13 >> 2] | 0) + (i14 << 3) | 0;
michael@0 17246 i20 = i18;
michael@0 17247 i18 = HEAP32[i19 + 4 >> 2] | 0;
michael@0 17248 HEAP32[i20 >> 2] = HEAP32[i19 >> 2];
michael@0 17249 HEAP32[i20 + 4 >> 2] = i18;
michael@0 17250 }
michael@0 17251 i14 = i14 + 1 | 0;
michael@0 17252 } while ((i14 | 0) < (i17 | 0));
michael@0 17253 }
michael@0 17254 i17 = HEAP32[i13 >> 2] | 0;
michael@0 17255 i14 = i1 + 120 | 0;
michael@0 17256 if ((i17 | 0) != 0) {
michael@0 17257 if ((HEAP8[i14] | 0) != 0) {
michael@0 17258 __Z21btAlignedFreeInternalPv(i17);
michael@0 17259 }
michael@0 17260 HEAP32[i13 >> 2] = 0;
michael@0 17261 }
michael@0 17262 HEAP8[i14] = 1;
michael@0 17263 HEAP32[i13 >> 2] = i16;
michael@0 17264 HEAP32[i12 >> 2] = i7;
michael@0 17265 i21 = i13;
michael@0 17266 } else {
michael@0 17267 i21 = i1 + 116 | 0;
michael@0 17268 }
michael@0 17269 i13 = i2;
michael@0 17270 do {
michael@0 17271 i2 = (HEAP32[i21 >> 2] | 0) + (i13 << 3) | 0;
michael@0 17272 if ((i2 | 0) != 0) {
michael@0 17273 i12 = i2;
michael@0 17274 HEAP32[i12 >> 2] = 0;
michael@0 17275 HEAP32[i12 + 4 >> 2] = 0;
michael@0 17276 }
michael@0 17277 i13 = i13 + 1 | 0;
michael@0 17278 } while ((i13 | 0) < (i7 | 0));
michael@0 17279 }
michael@0 17280 HEAP32[i15 >> 2] = i7;
michael@0 17281 if (i3) {
michael@0 17282 i15 = i1 + 116 | 0;
michael@0 17283 i13 = 0;
michael@0 17284 i21 = 0;
michael@0 17285 while (1) {
michael@0 17286 i12 = HEAP32[i15 >> 2] | 0;
michael@0 17287 i2 = i12 + (i13 << 3) | 0;
michael@0 17288 i16 = HEAP32[i6 + (i13 << 2) >> 2] | 0;
michael@0 17289 if ((HEAP8[i16 + 20 | 0] | 0) == 0) {
michael@0 17290 HEAP32[i2 >> 2] = 0;
michael@0 17291 HEAP32[i12 + (i13 << 3) + 4 >> 2] = 0;
michael@0 17292 i22 = 0;
michael@0 17293 } else {
michael@0 17294 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i16 >> 2] | 0) + 16 >> 2] & 127](i16, i2);
michael@0 17295 i22 = HEAP32[i2 >> 2] | 0;
michael@0 17296 }
michael@0 17297 i2 = i22 + i21 | 0;
michael@0 17298 i16 = i13 + 1 | 0;
michael@0 17299 if ((i16 | 0) < (i7 | 0)) {
michael@0 17300 i13 = i16;
michael@0 17301 i21 = i2;
michael@0 17302 } else {
michael@0 17303 i23 = i2;
michael@0 17304 break;
michael@0 17305 }
michael@0 17306 }
michael@0 17307 } else {
michael@0 17308 i23 = 0;
michael@0 17309 }
michael@0 17310 i21 = i9;
michael@0 17311 _memset(i21 | 0, 0, 136);
michael@0 17312 i9 = i1 + 28 | 0;
michael@0 17313 i13 = HEAP32[i9 >> 2] | 0;
michael@0 17314 if ((i13 | 0) < (i23 | 0)) {
michael@0 17315 i22 = i1 + 32 | 0;
michael@0 17316 if ((HEAP32[i22 >> 2] | 0) < (i23 | 0)) {
michael@0 17317 if ((i23 | 0) == 0) {
michael@0 17318 i24 = 0;
michael@0 17319 i25 = i13;
michael@0 17320 } else {
michael@0 17321 i15 = __Z22btAlignedAllocInternalji(i23 * 136 | 0, 16) | 0;
michael@0 17322 i24 = i15;
michael@0 17323 i25 = HEAP32[i9 >> 2] | 0;
michael@0 17324 }
michael@0 17325 i15 = i1 + 36 | 0;
michael@0 17326 if ((i25 | 0) > 0) {
michael@0 17327 i2 = 0;
michael@0 17328 do {
michael@0 17329 i16 = i24 + (i2 * 136 | 0) | 0;
michael@0 17330 i12 = (HEAP32[i15 >> 2] | 0) + (i2 * 136 | 0) | 0;
michael@0 17331 _memcpy(i16 | 0, i12 | 0, 136) | 0;
michael@0 17332 i2 = i2 + 1 | 0;
michael@0 17333 } while ((i2 | 0) < (i25 | 0));
michael@0 17334 }
michael@0 17335 i25 = HEAP32[i15 >> 2] | 0;
michael@0 17336 i2 = i1 + 40 | 0;
michael@0 17337 if ((i25 | 0) != 0) {
michael@0 17338 if ((HEAP8[i2] | 0) != 0) {
michael@0 17339 __Z21btAlignedFreeInternalPv(i25);
michael@0 17340 }
michael@0 17341 HEAP32[i15 >> 2] = 0;
michael@0 17342 }
michael@0 17343 HEAP8[i2] = 1;
michael@0 17344 HEAP32[i15 >> 2] = i24;
michael@0 17345 HEAP32[i22 >> 2] = i23;
michael@0 17346 i26 = i15;
michael@0 17347 } else {
michael@0 17348 i26 = i1 + 36 | 0;
michael@0 17349 }
michael@0 17350 i15 = i13;
michael@0 17351 do {
michael@0 17352 i13 = (HEAP32[i26 >> 2] | 0) + (i15 * 136 | 0) | 0;
michael@0 17353 _memcpy(i13 | 0, i21 | 0, 136) | 0;
michael@0 17354 i15 = i15 + 1 | 0;
michael@0 17355 } while ((i15 | 0) < (i23 | 0));
michael@0 17356 }
michael@0 17357 HEAP32[i9 >> 2] = i23;
michael@0 17358 if (i3) {
michael@0 17359 i3 = i1 + 116 | 0;
michael@0 17360 i23 = i1 + 36 | 0;
michael@0 17361 i9 = i8 + 12 | 0;
michael@0 17362 i15 = i11 | 0;
michael@0 17363 i21 = i8 + 32 | 0;
michael@0 17364 i26 = i11 + 4 | 0;
michael@0 17365 i13 = i11 + 8 | 0;
michael@0 17366 i22 = i11 + 12 | 0;
michael@0 17367 i24 = i11 + 16 | 0;
michael@0 17368 i2 = i11 + 20 | 0;
michael@0 17369 i25 = i11 + 24 | 0;
michael@0 17370 i12 = i11 + 28 | 0;
michael@0 17371 i16 = i8 + 40 | 0;
michael@0 17372 i14 = i8 + 4 | 0;
michael@0 17373 i17 = i11 + 52 | 0;
michael@0 17374 i18 = i11 + 32 | 0;
michael@0 17375 i20 = i11 + 36 | 0;
michael@0 17376 i19 = i11 + 40 | 0;
michael@0 17377 i27 = i8 + 20 | 0;
michael@0 17378 i28 = i11 + 48 | 0;
michael@0 17379 i29 = 0;
michael@0 17380 i30 = 0;
michael@0 17381 i31 = HEAP32[i3 >> 2] | 0;
michael@0 17382 while (1) {
michael@0 17383 i32 = i31 + (i30 << 3) | 0;
michael@0 17384 i33 = HEAP32[i32 >> 2] | 0;
michael@0 17385 if ((i33 | 0) == 0) {
michael@0 17386 i34 = i31;
michael@0 17387 i35 = 0;
michael@0 17388 } else {
michael@0 17389 i36 = HEAP32[i23 >> 2] | 0;
michael@0 17390 i37 = i6 + (i30 << 2) | 0;
michael@0 17391 i38 = HEAP32[i37 >> 2] | 0;
michael@0 17392 i39 = i38 + 24 | 0;
michael@0 17393 i40 = HEAP32[i39 >> 2] | 0;
michael@0 17394 i41 = i38 + 28 | 0;
michael@0 17395 i42 = HEAP32[i41 >> 2] | 0;
michael@0 17396 if ((i33 | 0) > 0) {
michael@0 17397 i33 = 0;
michael@0 17398 do {
michael@0 17399 i43 = i33 + i29 | 0;
michael@0 17400 _memset(i36 + (i43 * 136 | 0) | 0, 0, 136);
michael@0 17401 HEAPF32[i36 + (i43 * 136 | 0) + 124 >> 2] = -3.4028234663852886e+38;
michael@0 17402 HEAPF32[i36 + (i43 * 136 | 0) + 128 >> 2] = 3.4028234663852886e+38;
michael@0 17403 HEAPF32[i36 + (i43 * 136 | 0) + 84 >> 2] = 0.0;
michael@0 17404 HEAPF32[i36 + (i43 * 136 | 0) + 80 >> 2] = 0.0;
michael@0 17405 HEAP32[i36 + (i43 * 136 | 0) + 104 >> 2] = i40;
michael@0 17406 HEAP32[i36 + (i43 * 136 | 0) + 108 >> 2] = i42;
michael@0 17407 i33 = i33 + 1 | 0;
michael@0 17408 } while ((i33 | 0) < (HEAP32[i32 >> 2] | 0));
michael@0 17409 i44 = HEAP32[i37 >> 2] | 0;
michael@0 17410 } else {
michael@0 17411 i44 = i38;
michael@0 17412 }
michael@0 17413 _memset(i40 + 504 | 0, 0, 32);
michael@0 17414 _memset(i42 + 504 | 0, 0, 32);
michael@0 17415 HEAPF32[i15 >> 2] = 1.0 / +HEAPF32[i9 >> 2];
michael@0 17416 HEAPF32[i26 >> 2] = +HEAPF32[i21 >> 2];
michael@0 17417 HEAP32[i13 >> 2] = i36 + (i29 * 136 | 0) + 16;
michael@0 17418 HEAP32[i22 >> 2] = i36 + (i29 * 136 | 0);
michael@0 17419 HEAP32[i24 >> 2] = 0;
michael@0 17420 HEAP32[i2 >> 2] = i36 + (i29 * 136 | 0) + 32;
michael@0 17421 HEAP32[i25 >> 2] = 34;
michael@0 17422 HEAP32[i12 >> 2] = i36 + (i29 * 136 | 0) + 116;
michael@0 17423 i33 = i36 + (i29 * 136 | 0) + 120 | 0;
michael@0 17424 HEAPF32[i33 >> 2] = +HEAPF32[i16 >> 2];
michael@0 17425 HEAPF32[i17 >> 2] = +HEAPF32[i14 >> 2];
michael@0 17426 HEAP32[i18 >> 2] = i33;
michael@0 17427 i33 = i36 + (i29 * 136 | 0) + 124 | 0;
michael@0 17428 HEAP32[i20 >> 2] = i33;
michael@0 17429 i43 = i36 + (i29 * 136 | 0) + 128 | 0;
michael@0 17430 HEAP32[i19 >> 2] = i43;
michael@0 17431 HEAP32[i28 >> 2] = HEAP32[i27 >> 2];
michael@0 17432 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i44 >> 2] | 0) + 20 >> 2] & 127](i44, i11);
michael@0 17433 i45 = (HEAP32[i37 >> 2] | 0) + 16 | 0;
michael@0 17434 d46 = +HEAPF32[i45 >> 2];
michael@0 17435 if (+HEAPF32[i43 >> 2] > d46) {
michael@0 17436 HEAPF32[i43 >> 2] = d46;
michael@0 17437 d47 = +HEAPF32[i45 >> 2];
michael@0 17438 } else {
michael@0 17439 d47 = d46;
michael@0 17440 }
michael@0 17441 d46 = -0.0 - d47;
michael@0 17442 if (+HEAPF32[i33 >> 2] < d46) {
michael@0 17443 HEAPF32[i33 >> 2] = d46;
michael@0 17444 }
michael@0 17445 if ((HEAP32[i32 >> 2] | 0) > 0) {
michael@0 17446 i33 = i38;
michael@0 17447 i45 = i40 + 336 | 0;
michael@0 17448 i43 = i40 + 256 | 0;
michael@0 17449 i48 = i40 + 260 | 0;
michael@0 17450 i49 = i40 + 264 | 0;
michael@0 17451 i50 = i40 + 272 | 0;
michael@0 17452 i51 = i40 + 276 | 0;
michael@0 17453 i52 = i40 + 280 | 0;
michael@0 17454 i53 = i40 + 288 | 0;
michael@0 17455 i54 = i40 + 292 | 0;
michael@0 17456 i55 = i40 + 296 | 0;
michael@0 17457 i56 = i42 + 336 | 0;
michael@0 17458 i57 = i42 + 256 | 0;
michael@0 17459 i58 = i42 + 260 | 0;
michael@0 17460 i59 = i42 + 264 | 0;
michael@0 17461 i60 = i42 + 272 | 0;
michael@0 17462 i61 = i42 + 276 | 0;
michael@0 17463 i62 = i42 + 280 | 0;
michael@0 17464 i63 = i42 + 288 | 0;
michael@0 17465 i64 = i42 + 292 | 0;
michael@0 17466 i65 = i42 + 296 | 0;
michael@0 17467 i66 = i40 + 304 | 0;
michael@0 17468 i67 = i40 + 308 | 0;
michael@0 17469 i68 = i40 + 312 | 0;
michael@0 17470 i69 = i40 + 320 | 0;
michael@0 17471 i70 = i40 + 324 | 0;
michael@0 17472 i71 = i40 + 328 | 0;
michael@0 17473 i72 = i42 + 304 | 0;
michael@0 17474 i73 = i42 + 308 | 0;
michael@0 17475 i74 = i42 + 312 | 0;
michael@0 17476 i75 = i42 + 320 | 0;
michael@0 17477 i76 = i42 + 324 | 0;
michael@0 17478 i77 = i42 + 328 | 0;
michael@0 17479 i78 = 0;
michael@0 17480 do {
michael@0 17481 i79 = i78 + i29 | 0;
michael@0 17482 HEAP32[i36 + (i79 * 136 | 0) + 112 >> 2] = i33;
michael@0 17483 i80 = HEAP32[i39 >> 2] | 0;
michael@0 17484 d46 = +HEAPF32[i36 + (i79 * 136 | 0) >> 2];
michael@0 17485 d81 = +HEAPF32[i36 + (i79 * 136 | 0) + 4 >> 2];
michael@0 17486 d82 = +HEAPF32[i36 + (i79 * 136 | 0) + 8 >> 2];
michael@0 17487 d83 = (d46 * +HEAPF32[i80 + 272 >> 2] + d81 * +HEAPF32[i80 + 276 >> 2] + d82 * +HEAPF32[i80 + 280 >> 2]) * +HEAPF32[i80 + 540 >> 2];
michael@0 17488 d84 = (d46 * +HEAPF32[i80 + 288 >> 2] + d81 * +HEAPF32[i80 + 292 >> 2] + d82 * +HEAPF32[i80 + 296 >> 2]) * +HEAPF32[i80 + 544 >> 2];
michael@0 17489 HEAPF32[i36 + (i79 * 136 | 0) + 48 >> 2] = (+HEAPF32[i80 + 256 >> 2] * d46 + +HEAPF32[i80 + 260 >> 2] * d81 + +HEAPF32[i80 + 264 >> 2] * d82) * +HEAPF32[i80 + 536 >> 2];
michael@0 17490 HEAPF32[i36 + (i79 * 136 | 0) + 52 >> 2] = d83;
michael@0 17491 HEAPF32[i36 + (i79 * 136 | 0) + 56 >> 2] = d84;
michael@0 17492 HEAPF32[i36 + (i79 * 136 | 0) + 60 >> 2] = 0.0;
michael@0 17493 i80 = HEAP32[i41 >> 2] | 0;
michael@0 17494 d84 = +HEAPF32[i36 + (i79 * 136 | 0) + 32 >> 2];
michael@0 17495 d83 = +HEAPF32[i36 + (i79 * 136 | 0) + 36 >> 2];
michael@0 17496 d85 = +HEAPF32[i36 + (i79 * 136 | 0) + 40 >> 2];
michael@0 17497 d86 = (d84 * +HEAPF32[i80 + 272 >> 2] + d83 * +HEAPF32[i80 + 276 >> 2] + d85 * +HEAPF32[i80 + 280 >> 2]) * +HEAPF32[i80 + 540 >> 2];
michael@0 17498 d87 = (d84 * +HEAPF32[i80 + 288 >> 2] + d83 * +HEAPF32[i80 + 292 >> 2] + d85 * +HEAPF32[i80 + 296 >> 2]) * +HEAPF32[i80 + 544 >> 2];
michael@0 17499 HEAPF32[i36 + (i79 * 136 | 0) + 64 >> 2] = (+HEAPF32[i80 + 256 >> 2] * d84 + +HEAPF32[i80 + 260 >> 2] * d83 + +HEAPF32[i80 + 264 >> 2] * d85) * +HEAPF32[i80 + 536 >> 2];
michael@0 17500 HEAPF32[i36 + (i79 * 136 | 0) + 68 >> 2] = d86;
michael@0 17501 HEAPF32[i36 + (i79 * 136 | 0) + 72 >> 2] = d87;
michael@0 17502 HEAPF32[i36 + (i79 * 136 | 0) + 76 >> 2] = 0.0;
michael@0 17503 d87 = +HEAPF32[i45 >> 2];
michael@0 17504 d86 = +HEAPF32[i36 + (i79 * 136 | 0) + 16 >> 2];
michael@0 17505 d88 = +HEAPF32[i36 + (i79 * 136 | 0) + 20 >> 2];
michael@0 17506 d89 = +HEAPF32[i36 + (i79 * 136 | 0) + 24 >> 2];
michael@0 17507 d90 = +HEAPF32[i56 >> 2];
michael@0 17508 d91 = 1.0 / (d86 * d87 * d86 + d88 * d87 * d88 + d89 * d87 * d89 + (d46 * (d46 * +HEAPF32[i43 >> 2] + d81 * +HEAPF32[i48 >> 2] + d82 * +HEAPF32[i49 >> 2]) + d81 * (d46 * +HEAPF32[i50 >> 2] + d81 * +HEAPF32[i51 >> 2] + d82 * +HEAPF32[i52 >> 2]) + d82 * (d46 * +HEAPF32[i53 >> 2] + d81 * +HEAPF32[i54 >> 2] + d82 * +HEAPF32[i55 >> 2])) + (d89 * d89 * d90 + (d86 * d86 * d90 + d88 * d88 * d90)) + (d84 * (d84 * +HEAPF32[i57 >> 2] + d83 * +HEAPF32[i58 >> 2] + d85 * +HEAPF32[i59 >> 2]) + d83 * (d84 * +HEAPF32[i60 >> 2] + d83 * +HEAPF32[i61 >> 2] + d85 * +HEAPF32[i62 >> 2]) + d85 * (d84 * +HEAPF32[i63 >> 2] + d83 * +HEAPF32[i64 >> 2] + d85 * +HEAPF32[i65 >> 2])));
michael@0 17509 HEAPF32[i36 + (i79 * 136 | 0) + 92 >> 2] = d91;
michael@0 17510 i80 = i36 + (i79 * 136 | 0) + 116 | 0;
michael@0 17511 HEAPF32[i80 >> 2] = d91 * +HEAPF32[i80 >> 2] + d91 * (0.0 - +HEAPF32[i17 >> 2] * (d86 * +HEAPF32[i66 >> 2] + d88 * +HEAPF32[i67 >> 2] + d89 * +HEAPF32[i68 >> 2] + (d46 * +HEAPF32[i69 >> 2] + d81 * +HEAPF32[i70 >> 2] + d82 * +HEAPF32[i71 >> 2]) + (d84 * +HEAPF32[i75 >> 2] + d83 * +HEAPF32[i76 >> 2] + d85 * +HEAPF32[i77 >> 2] - (d86 * +HEAPF32[i72 >> 2] + d88 * +HEAPF32[i73 >> 2] + d89 * +HEAPF32[i74 >> 2]))));
michael@0 17512 HEAPF32[i36 + (i79 * 136 | 0) + 84 >> 2] = 0.0;
michael@0 17513 i78 = i78 + 1 | 0;
michael@0 17514 } while ((i78 | 0) < (HEAP32[i32 >> 2] | 0));
michael@0 17515 }
michael@0 17516 i32 = HEAP32[i3 >> 2] | 0;
michael@0 17517 i34 = i32;
michael@0 17518 i35 = HEAP32[i32 + (i30 << 3) >> 2] | 0;
michael@0 17519 }
michael@0 17520 i32 = i30 + 1 | 0;
michael@0 17521 if ((i32 | 0) < (i7 | 0)) {
michael@0 17522 i29 = i35 + i29 | 0;
michael@0 17523 i30 = i32;
michael@0 17524 i31 = i34;
michael@0 17525 } else {
michael@0 17526 break;
michael@0 17527 }
michael@0 17528 }
michael@0 17529 }
michael@0 17530 if ((i5 | 0) > 0) {
michael@0 17531 i34 = 0;
michael@0 17532 do {
michael@0 17533 __ZN35btSequentialImpulseConstraintSolver14convertContactEP20btPersistentManifoldRK19btContactSolverInfo(i1, HEAP32[i4 + (i34 << 2) >> 2] | 0, i8);
michael@0 17534 i34 = i34 + 1 | 0;
michael@0 17535 } while ((i34 | 0) < (i5 | 0));
michael@0 17536 }
michael@0 17537 i5 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 17538 i34 = HEAP32[i1 + 48 >> 2] | 0;
michael@0 17539 i8 = i1 + 68 | 0;
michael@0 17540 i4 = HEAP32[i8 >> 2] | 0;
michael@0 17541 if ((i4 | 0) < (i5 | 0)) {
michael@0 17542 i31 = i1 + 72 | 0;
michael@0 17543 if ((HEAP32[i31 >> 2] | 0) < (i5 | 0)) {
michael@0 17544 if ((i5 | 0) == 0) {
michael@0 17545 i92 = 0;
michael@0 17546 i93 = i4;
michael@0 17547 } else {
michael@0 17548 i30 = __Z22btAlignedAllocInternalji(i5 << 2, 16) | 0;
michael@0 17549 i92 = i30;
michael@0 17550 i93 = HEAP32[i8 >> 2] | 0;
michael@0 17551 }
michael@0 17552 i30 = i1 + 76 | 0;
michael@0 17553 if ((i93 | 0) > 0) {
michael@0 17554 i29 = 0;
michael@0 17555 do {
michael@0 17556 i35 = i92 + (i29 << 2) | 0;
michael@0 17557 if ((i35 | 0) != 0) {
michael@0 17558 HEAP32[i35 >> 2] = HEAP32[(HEAP32[i30 >> 2] | 0) + (i29 << 2) >> 2];
michael@0 17559 }
michael@0 17560 i29 = i29 + 1 | 0;
michael@0 17561 } while ((i29 | 0) < (i93 | 0));
michael@0 17562 }
michael@0 17563 i93 = HEAP32[i30 >> 2] | 0;
michael@0 17564 i29 = i1 + 80 | 0;
michael@0 17565 if ((i93 | 0) != 0) {
michael@0 17566 if ((HEAP8[i29] | 0) != 0) {
michael@0 17567 __Z21btAlignedFreeInternalPv(i93);
michael@0 17568 }
michael@0 17569 HEAP32[i30 >> 2] = 0;
michael@0 17570 }
michael@0 17571 HEAP8[i29] = 1;
michael@0 17572 HEAP32[i30 >> 2] = i92;
michael@0 17573 HEAP32[i31 >> 2] = i5;
michael@0 17574 i94 = i92;
michael@0 17575 } else {
michael@0 17576 i94 = HEAP32[i1 + 76 >> 2] | 0;
michael@0 17577 }
michael@0 17578 i92 = i4;
michael@0 17579 do {
michael@0 17580 i4 = i94 + (i92 << 2) | 0;
michael@0 17581 if ((i4 | 0) != 0) {
michael@0 17582 HEAP32[i4 >> 2] = 0;
michael@0 17583 }
michael@0 17584 i92 = i92 + 1 | 0;
michael@0 17585 } while ((i92 | 0) < (i5 | 0));
michael@0 17586 }
michael@0 17587 HEAP32[i8 >> 2] = i5;
michael@0 17588 i8 = i1 + 88 | 0;
michael@0 17589 i92 = HEAP32[i8 >> 2] | 0;
michael@0 17590 if ((i92 | 0) < (i34 | 0)) {
michael@0 17591 i94 = i1 + 92 | 0;
michael@0 17592 if ((HEAP32[i94 >> 2] | 0) < (i34 | 0)) {
michael@0 17593 if ((i34 | 0) == 0) {
michael@0 17594 i95 = 0;
michael@0 17595 i96 = i92;
michael@0 17596 } else {
michael@0 17597 i4 = __Z22btAlignedAllocInternalji(i34 << 2, 16) | 0;
michael@0 17598 i95 = i4;
michael@0 17599 i96 = HEAP32[i8 >> 2] | 0;
michael@0 17600 }
michael@0 17601 i4 = i1 + 96 | 0;
michael@0 17602 if ((i96 | 0) > 0) {
michael@0 17603 i31 = 0;
michael@0 17604 do {
michael@0 17605 i30 = i95 + (i31 << 2) | 0;
michael@0 17606 if ((i30 | 0) != 0) {
michael@0 17607 HEAP32[i30 >> 2] = HEAP32[(HEAP32[i4 >> 2] | 0) + (i31 << 2) >> 2];
michael@0 17608 }
michael@0 17609 i31 = i31 + 1 | 0;
michael@0 17610 } while ((i31 | 0) < (i96 | 0));
michael@0 17611 }
michael@0 17612 i96 = HEAP32[i4 >> 2] | 0;
michael@0 17613 i31 = i1 + 100 | 0;
michael@0 17614 if ((i96 | 0) != 0) {
michael@0 17615 if ((HEAP8[i31] | 0) != 0) {
michael@0 17616 __Z21btAlignedFreeInternalPv(i96);
michael@0 17617 }
michael@0 17618 HEAP32[i4 >> 2] = 0;
michael@0 17619 }
michael@0 17620 HEAP8[i31] = 1;
michael@0 17621 HEAP32[i4 >> 2] = i95;
michael@0 17622 HEAP32[i94 >> 2] = i34;
michael@0 17623 i97 = i95;
michael@0 17624 } else {
michael@0 17625 i97 = HEAP32[i1 + 96 >> 2] | 0;
michael@0 17626 }
michael@0 17627 i95 = i92;
michael@0 17628 do {
michael@0 17629 i92 = i97 + (i95 << 2) | 0;
michael@0 17630 if ((i92 | 0) != 0) {
michael@0 17631 HEAP32[i92 >> 2] = 0;
michael@0 17632 }
michael@0 17633 i95 = i95 + 1 | 0;
michael@0 17634 } while ((i95 | 0) < (i34 | 0));
michael@0 17635 }
michael@0 17636 HEAP32[i8 >> 2] = i34;
michael@0 17637 if ((i5 | 0) > 0) {
michael@0 17638 i8 = HEAP32[i1 + 76 >> 2] | 0;
michael@0 17639 i95 = 0;
michael@0 17640 do {
michael@0 17641 HEAP32[i8 + (i95 << 2) >> 2] = i95;
michael@0 17642 i95 = i95 + 1 | 0;
michael@0 17643 } while ((i95 | 0) < (i5 | 0));
michael@0 17644 }
michael@0 17645 if ((i34 | 0) <= 0) {
michael@0 17646 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 17647 STACKTOP = i10;
michael@0 17648 return +0.0;
michael@0 17649 }
michael@0 17650 i5 = HEAP32[i1 + 96 >> 2] | 0;
michael@0 17651 i1 = 0;
michael@0 17652 do {
michael@0 17653 HEAP32[i5 + (i1 << 2) >> 2] = i1;
michael@0 17654 i1 = i1 + 1 | 0;
michael@0 17655 } while ((i1 | 0) < (i34 | 0));
michael@0 17656 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 17657 STACKTOP = i10;
michael@0 17658 return +0.0;
michael@0 17659 }
michael@0 17660 function __ZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 17661 i1 = i1 | 0;
michael@0 17662 i2 = i2 | 0;
michael@0 17663 i3 = i3 | 0;
michael@0 17664 i4 = i4 | 0;
michael@0 17665 i5 = i5 | 0;
michael@0 17666 i6 = i6 | 0;
michael@0 17667 i7 = i7 | 0;
michael@0 17668 i8 = i8 | 0;
michael@0 17669 i9 = i9 | 0;
michael@0 17670 i10 = i10 | 0;
michael@0 17671 i11 = i11 | 0;
michael@0 17672 var i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, d63 = 0.0, d64 = 0.0, d65 = 0.0, d66 = 0.0, d67 = 0.0, d68 = 0.0, d69 = 0.0, d70 = 0.0, d71 = 0.0, d72 = 0.0, d73 = 0.0, d74 = 0.0, d75 = 0.0, d76 = 0.0, d77 = 0.0, d78 = 0.0, d79 = 0.0, d80 = 0.0, d81 = 0.0, d82 = 0.0, i83 = 0;
michael@0 17673 i11 = STACKTOP;
michael@0 17674 STACKTOP = STACKTOP + 4264 | 0;
michael@0 17675 i1 = i11 | 0;
michael@0 17676 i12 = i11 + 992 | 0;
michael@0 17677 i13 = i11 + 1984 | 0;
michael@0 17678 i14 = i11 + 2976 | 0;
michael@0 17679 i15 = i11 + 3968 | 0;
michael@0 17680 i16 = i11 + 3984 | 0;
michael@0 17681 i17 = i11 + 4e3 | 0;
michael@0 17682 i18 = i11 + 4080 | 0;
michael@0 17683 i19 = i11 + 4216 | 0;
michael@0 17684 if (((HEAP32[i3 + 4 >> 2] | 0) - 17 | 0) >>> 0 < 2) {
michael@0 17685 i20 = ((HEAP32[i4 + 4 >> 2] | 0) - 17 | 0) >>> 0 < 2;
michael@0 17686 } else {
michael@0 17687 i20 = 0;
michael@0 17688 }
michael@0 17689 i21 = i1 | 0;
michael@0 17690 i22 = i13 | 0;
michael@0 17691 i23 = i5 | 0;
michael@0 17692 i24 = i5 + 16 | 0;
michael@0 17693 i25 = i5 + 32 | 0;
michael@0 17694 i26 = i5 + 4 | 0;
michael@0 17695 i27 = i5 + 20 | 0;
michael@0 17696 i28 = i5 + 36 | 0;
michael@0 17697 i29 = i5 + 8 | 0;
michael@0 17698 i30 = i5 + 24 | 0;
michael@0 17699 i31 = i5 + 40 | 0;
michael@0 17700 i32 = i6 | 0;
michael@0 17701 i33 = i6 + 16 | 0;
michael@0 17702 i34 = i6 + 32 | 0;
michael@0 17703 i35 = i6 + 4 | 0;
michael@0 17704 i36 = i6 + 20 | 0;
michael@0 17705 i37 = i6 + 36 | 0;
michael@0 17706 i38 = i6 + 8 | 0;
michael@0 17707 i39 = i6 + 24 | 0;
michael@0 17708 i40 = i6 + 40 | 0;
michael@0 17709 i41 = 0;
michael@0 17710 do {
michael@0 17711 __ZN33btMinkowskiPenetrationDepthSolver24getPenetrationDirectionsEv() | 0;
michael@0 17712 d42 = +HEAPF32[13144 + (i41 << 4) >> 2];
michael@0 17713 d43 = +HEAPF32[13148 + (i41 << 4) >> 2];
michael@0 17714 d44 = +HEAPF32[13152 + (i41 << 4) >> 2];
michael@0 17715 d45 = -0.0 - d42;
michael@0 17716 d46 = -0.0 - d43;
michael@0 17717 d47 = -0.0 - d44;
michael@0 17718 d48 = +HEAPF32[i26 >> 2] * d45 + +HEAPF32[i27 >> 2] * d46 + +HEAPF32[i28 >> 2] * d47;
michael@0 17719 d49 = +HEAPF32[i29 >> 2] * d45 + +HEAPF32[i30 >> 2] * d46 + +HEAPF32[i31 >> 2] * d47;
michael@0 17720 HEAPF32[i13 + (i41 << 4) >> 2] = +HEAPF32[i23 >> 2] * d45 + +HEAPF32[i24 >> 2] * d46 + +HEAPF32[i25 >> 2] * d47;
michael@0 17721 HEAPF32[i13 + (i41 << 4) + 4 >> 2] = d48;
michael@0 17722 HEAPF32[i13 + (i41 << 4) + 8 >> 2] = d49;
michael@0 17723 HEAPF32[i13 + (i41 << 4) + 12 >> 2] = 0.0;
michael@0 17724 d49 = d42 * +HEAPF32[i35 >> 2] + d43 * +HEAPF32[i36 >> 2] + d44 * +HEAPF32[i37 >> 2];
michael@0 17725 d48 = d42 * +HEAPF32[i38 >> 2] + d43 * +HEAPF32[i39 >> 2] + d44 * +HEAPF32[i40 >> 2];
michael@0 17726 HEAPF32[i14 + (i41 << 4) >> 2] = d42 * +HEAPF32[i32 >> 2] + d43 * +HEAPF32[i33 >> 2] + d44 * +HEAPF32[i34 >> 2];
michael@0 17727 HEAPF32[i14 + (i41 << 4) + 4 >> 2] = d49;
michael@0 17728 HEAPF32[i14 + (i41 << 4) + 8 >> 2] = d48;
michael@0 17729 HEAPF32[i14 + (i41 << 4) + 12 >> 2] = 0.0;
michael@0 17730 i41 = i41 + 1 | 0;
michael@0 17731 } while ((i41 | 0) < 42);
michael@0 17732 i41 = i12 | 0;
michael@0 17733 i50 = i14 | 0;
michael@0 17734 i51 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 76 >> 2] & 127](i3) | 0;
michael@0 17735 if ((i51 | 0) > 0) {
michael@0 17736 i52 = i3;
michael@0 17737 i53 = i15 | 0;
michael@0 17738 i54 = i15 + 4 | 0;
michael@0 17739 i55 = i15 + 8 | 0;
michael@0 17740 i56 = i15;
michael@0 17741 i57 = i15 + 12 | 0;
michael@0 17742 i58 = 0;
michael@0 17743 i59 = 42;
michael@0 17744 while (1) {
michael@0 17745 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i52 >> 2] | 0) + 80 >> 2] & 127](i3, i58, i15);
michael@0 17746 d48 = +HEAPF32[i53 >> 2];
michael@0 17747 d49 = +HEAPF32[i54 >> 2];
michael@0 17748 d44 = +HEAPF32[i55 >> 2];
michael@0 17749 d43 = d48 * +HEAPF32[i24 >> 2] + d49 * +HEAPF32[i27 >> 2] + d44 * +HEAPF32[i30 >> 2];
michael@0 17750 d42 = d48 * +HEAPF32[i25 >> 2] + d49 * +HEAPF32[i28 >> 2] + d44 * +HEAPF32[i31 >> 2];
michael@0 17751 HEAPF32[i53 >> 2] = +HEAPF32[i23 >> 2] * d48 + +HEAPF32[i26 >> 2] * d49 + +HEAPF32[i29 >> 2] * d44;
michael@0 17752 HEAPF32[i54 >> 2] = d43;
michael@0 17753 HEAPF32[i55 >> 2] = d42;
michael@0 17754 HEAPF32[i57 >> 2] = 0.0;
michael@0 17755 __ZN33btMinkowskiPenetrationDepthSolver24getPenetrationDirectionsEv() | 0;
michael@0 17756 i60 = 13144 + (i59 << 4) | 0;
michael@0 17757 HEAP32[i60 >> 2] = HEAP32[i56 >> 2];
michael@0 17758 HEAP32[i60 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 17759 HEAP32[i60 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 17760 HEAP32[i60 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 17761 d42 = +HEAPF32[i53 >> 2];
michael@0 17762 d43 = -0.0 - d42;
michael@0 17763 d44 = +HEAPF32[i54 >> 2];
michael@0 17764 d49 = -0.0 - d44;
michael@0 17765 d48 = +HEAPF32[i55 >> 2];
michael@0 17766 d47 = -0.0 - d48;
michael@0 17767 d46 = +HEAPF32[i26 >> 2] * d43 + +HEAPF32[i27 >> 2] * d49 + +HEAPF32[i28 >> 2] * d47;
michael@0 17768 d45 = +HEAPF32[i29 >> 2] * d43 + +HEAPF32[i30 >> 2] * d49 + +HEAPF32[i31 >> 2] * d47;
michael@0 17769 HEAPF32[i13 + (i59 << 4) >> 2] = +HEAPF32[i23 >> 2] * d43 + +HEAPF32[i24 >> 2] * d49 + +HEAPF32[i25 >> 2] * d47;
michael@0 17770 HEAPF32[i13 + (i59 << 4) + 4 >> 2] = d46;
michael@0 17771 HEAPF32[i13 + (i59 << 4) + 8 >> 2] = d45;
michael@0 17772 HEAPF32[i13 + (i59 << 4) + 12 >> 2] = 0.0;
michael@0 17773 d45 = d42 * +HEAPF32[i35 >> 2] + d44 * +HEAPF32[i36 >> 2] + d48 * +HEAPF32[i37 >> 2];
michael@0 17774 d46 = d42 * +HEAPF32[i38 >> 2] + d44 * +HEAPF32[i39 >> 2] + d48 * +HEAPF32[i40 >> 2];
michael@0 17775 HEAPF32[i14 + (i59 << 4) >> 2] = d42 * +HEAPF32[i32 >> 2] + d44 * +HEAPF32[i33 >> 2] + d48 * +HEAPF32[i34 >> 2];
michael@0 17776 HEAPF32[i14 + (i59 << 4) + 4 >> 2] = d45;
michael@0 17777 HEAPF32[i14 + (i59 << 4) + 8 >> 2] = d46;
michael@0 17778 HEAPF32[i14 + (i59 << 4) + 12 >> 2] = 0.0;
michael@0 17779 i60 = i58 + 1 | 0;
michael@0 17780 if ((i60 | 0) < (i51 | 0)) {
michael@0 17781 i58 = i60;
michael@0 17782 i59 = i59 + 1 | 0;
michael@0 17783 } else {
michael@0 17784 break;
michael@0 17785 }
michael@0 17786 }
michael@0 17787 i61 = i51 + 42 | 0;
michael@0 17788 } else {
michael@0 17789 i61 = 42;
michael@0 17790 }
michael@0 17791 i51 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i4 >> 2] | 0) + 76 >> 2] & 127](i4) | 0;
michael@0 17792 if ((i51 | 0) > 0) {
michael@0 17793 i59 = i4;
michael@0 17794 i58 = i16 | 0;
michael@0 17795 i55 = i16 + 4 | 0;
michael@0 17796 i54 = i16 + 8 | 0;
michael@0 17797 i53 = i16;
michael@0 17798 i56 = i16 + 12 | 0;
michael@0 17799 i57 = i61;
michael@0 17800 i15 = 0;
michael@0 17801 while (1) {
michael@0 17802 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i59 >> 2] | 0) + 80 >> 2] & 127](i4, i15, i16);
michael@0 17803 d46 = +HEAPF32[i58 >> 2];
michael@0 17804 d45 = +HEAPF32[i55 >> 2];
michael@0 17805 d48 = +HEAPF32[i54 >> 2];
michael@0 17806 d44 = d46 * +HEAPF32[i33 >> 2] + d45 * +HEAPF32[i36 >> 2] + d48 * +HEAPF32[i39 >> 2];
michael@0 17807 d42 = d46 * +HEAPF32[i34 >> 2] + d45 * +HEAPF32[i37 >> 2] + d48 * +HEAPF32[i40 >> 2];
michael@0 17808 HEAPF32[i58 >> 2] = +HEAPF32[i32 >> 2] * d46 + +HEAPF32[i35 >> 2] * d45 + +HEAPF32[i38 >> 2] * d48;
michael@0 17809 HEAPF32[i55 >> 2] = d44;
michael@0 17810 HEAPF32[i54 >> 2] = d42;
michael@0 17811 HEAPF32[i56 >> 2] = 0.0;
michael@0 17812 __ZN33btMinkowskiPenetrationDepthSolver24getPenetrationDirectionsEv() | 0;
michael@0 17813 i52 = 13144 + (i57 << 4) | 0;
michael@0 17814 HEAP32[i52 >> 2] = HEAP32[i53 >> 2];
michael@0 17815 HEAP32[i52 + 4 >> 2] = HEAP32[i53 + 4 >> 2];
michael@0 17816 HEAP32[i52 + 8 >> 2] = HEAP32[i53 + 8 >> 2];
michael@0 17817 HEAP32[i52 + 12 >> 2] = HEAP32[i53 + 12 >> 2];
michael@0 17818 d42 = +HEAPF32[i58 >> 2];
michael@0 17819 d44 = -0.0 - d42;
michael@0 17820 d48 = +HEAPF32[i55 >> 2];
michael@0 17821 d45 = -0.0 - d48;
michael@0 17822 d46 = +HEAPF32[i54 >> 2];
michael@0 17823 d47 = -0.0 - d46;
michael@0 17824 d49 = +HEAPF32[i26 >> 2] * d44 + +HEAPF32[i27 >> 2] * d45 + +HEAPF32[i28 >> 2] * d47;
michael@0 17825 d43 = +HEAPF32[i29 >> 2] * d44 + +HEAPF32[i30 >> 2] * d45 + +HEAPF32[i31 >> 2] * d47;
michael@0 17826 HEAPF32[i13 + (i57 << 4) >> 2] = +HEAPF32[i23 >> 2] * d44 + +HEAPF32[i24 >> 2] * d45 + +HEAPF32[i25 >> 2] * d47;
michael@0 17827 HEAPF32[i13 + (i57 << 4) + 4 >> 2] = d49;
michael@0 17828 HEAPF32[i13 + (i57 << 4) + 8 >> 2] = d43;
michael@0 17829 HEAPF32[i13 + (i57 << 4) + 12 >> 2] = 0.0;
michael@0 17830 d43 = d42 * +HEAPF32[i35 >> 2] + d48 * +HEAPF32[i36 >> 2] + d46 * +HEAPF32[i37 >> 2];
michael@0 17831 d49 = d42 * +HEAPF32[i38 >> 2] + d48 * +HEAPF32[i39 >> 2] + d46 * +HEAPF32[i40 >> 2];
michael@0 17832 HEAPF32[i14 + (i57 << 4) >> 2] = d42 * +HEAPF32[i32 >> 2] + d48 * +HEAPF32[i33 >> 2] + d46 * +HEAPF32[i34 >> 2];
michael@0 17833 HEAPF32[i14 + (i57 << 4) + 4 >> 2] = d43;
michael@0 17834 HEAPF32[i14 + (i57 << 4) + 8 >> 2] = d49;
michael@0 17835 HEAPF32[i14 + (i57 << 4) + 12 >> 2] = 0.0;
michael@0 17836 i52 = i15 + 1 | 0;
michael@0 17837 if ((i52 | 0) < (i51 | 0)) {
michael@0 17838 i57 = i57 + 1 | 0;
michael@0 17839 i15 = i52;
michael@0 17840 } else {
michael@0 17841 break;
michael@0 17842 }
michael@0 17843 }
michael@0 17844 i62 = i51 + i61 | 0;
michael@0 17845 } else {
michael@0 17846 i62 = i61;
michael@0 17847 }
michael@0 17848 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i3 >> 2] | 0) + 68 >> 2] & 127](i3, i22, i21, i62);
michael@0 17849 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i4 >> 2] | 0) + 68 >> 2] & 127](i4, i50, i41, i62);
michael@0 17850 if ((i62 | 0) > 0) {
michael@0 17851 i41 = i5 + 48 | 0;
michael@0 17852 i50 = i5 + 52 | 0;
michael@0 17853 i21 = i5 + 56 | 0;
michael@0 17854 i22 = i6 + 48 | 0;
michael@0 17855 i61 = i6 + 52 | 0;
michael@0 17856 i51 = i6 + 56 | 0;
michael@0 17857 if (i20) {
michael@0 17858 d49 = 0.0;
michael@0 17859 d43 = 0.0;
michael@0 17860 d46 = 0.0;
michael@0 17861 i20 = 0;
michael@0 17862 d48 = 999999984306749400.0;
michael@0 17863 while (1) {
michael@0 17864 __ZN33btMinkowskiPenetrationDepthSolver24getPenetrationDirectionsEv() | 0;
michael@0 17865 d42 = +HEAPF32[13144 + (i20 << 4) >> 2];
michael@0 17866 d47 = +HEAPF32[13148 + (i20 << 4) >> 2];
michael@0 17867 d45 = +HEAPF32[13156 + (i20 << 4) >> 2];
michael@0 17868 do {
michael@0 17869 if (d42 * d42 + d47 * d47 + 0.0 > .01) {
michael@0 17870 d44 = +HEAPF32[i1 + (i20 << 4) >> 2];
michael@0 17871 d63 = +HEAPF32[i1 + (i20 << 4) + 4 >> 2];
michael@0 17872 d64 = +HEAPF32[i1 + (i20 << 4) + 8 >> 2];
michael@0 17873 d65 = +HEAPF32[i12 + (i20 << 4) >> 2];
michael@0 17874 d66 = +HEAPF32[i12 + (i20 << 4) + 4 >> 2];
michael@0 17875 d67 = +HEAPF32[i12 + (i20 << 4) + 8 >> 2];
michael@0 17876 d68 = d42 * (+HEAPF32[i22 >> 2] + (d65 * +HEAPF32[i32 >> 2] + d66 * +HEAPF32[i35 >> 2] + d67 * +HEAPF32[i38 >> 2]) - (+HEAPF32[i41 >> 2] + (d44 * +HEAPF32[i23 >> 2] + d63 * +HEAPF32[i26 >> 2] + d64 * +HEAPF32[i29 >> 2]))) + d47 * (+HEAPF32[i61 >> 2] + (d65 * +HEAPF32[i33 >> 2] + d66 * +HEAPF32[i36 >> 2] + d67 * +HEAPF32[i39 >> 2]) - (+HEAPF32[i50 >> 2] + (d44 * +HEAPF32[i24 >> 2] + d63 * +HEAPF32[i27 >> 2] + d64 * +HEAPF32[i30 >> 2]))) + 0.0;
michael@0 17877 if (d68 >= d48) {
michael@0 17878 d69 = d48;
michael@0 17879 d70 = d46;
michael@0 17880 d71 = d43;
michael@0 17881 d72 = d49;
michael@0 17882 break;
michael@0 17883 }
michael@0 17884 d69 = d68;
michael@0 17885 d70 = d42;
michael@0 17886 d71 = d47;
michael@0 17887 d72 = d45;
michael@0 17888 } else {
michael@0 17889 d69 = d48;
michael@0 17890 d70 = d46;
michael@0 17891 d71 = d43;
michael@0 17892 d72 = d49;
michael@0 17893 }
michael@0 17894 } while (0);
michael@0 17895 i15 = i20 + 1 | 0;
michael@0 17896 if ((i15 | 0) < (i62 | 0)) {
michael@0 17897 d49 = d72;
michael@0 17898 d43 = d71;
michael@0 17899 d46 = d70;
michael@0 17900 i20 = i15;
michael@0 17901 d48 = d69;
michael@0 17902 } else {
michael@0 17903 d73 = d72;
michael@0 17904 d74 = 0.0;
michael@0 17905 d75 = d71;
michael@0 17906 d76 = d70;
michael@0 17907 d77 = d69;
michael@0 17908 break;
michael@0 17909 }
michael@0 17910 }
michael@0 17911 } else {
michael@0 17912 d69 = 0.0;
michael@0 17913 d70 = 0.0;
michael@0 17914 d71 = 0.0;
michael@0 17915 d72 = 0.0;
michael@0 17916 i20 = 0;
michael@0 17917 d48 = 999999984306749400.0;
michael@0 17918 while (1) {
michael@0 17919 __ZN33btMinkowskiPenetrationDepthSolver24getPenetrationDirectionsEv() | 0;
michael@0 17920 d46 = +HEAPF32[13144 + (i20 << 4) >> 2];
michael@0 17921 d43 = +HEAPF32[13148 + (i20 << 4) >> 2];
michael@0 17922 d49 = +HEAPF32[13152 + (i20 << 4) >> 2];
michael@0 17923 d45 = +HEAPF32[13156 + (i20 << 4) >> 2];
michael@0 17924 do {
michael@0 17925 if (d46 * d46 + d43 * d43 + d49 * d49 > .01) {
michael@0 17926 d47 = +HEAPF32[i1 + (i20 << 4) >> 2];
michael@0 17927 d42 = +HEAPF32[i1 + (i20 << 4) + 4 >> 2];
michael@0 17928 d68 = +HEAPF32[i1 + (i20 << 4) + 8 >> 2];
michael@0 17929 d64 = +HEAPF32[i12 + (i20 << 4) >> 2];
michael@0 17930 d63 = +HEAPF32[i12 + (i20 << 4) + 4 >> 2];
michael@0 17931 d44 = +HEAPF32[i12 + (i20 << 4) + 8 >> 2];
michael@0 17932 d67 = d46 * (+HEAPF32[i22 >> 2] + (d64 * +HEAPF32[i32 >> 2] + d63 * +HEAPF32[i35 >> 2] + d44 * +HEAPF32[i38 >> 2]) - (+HEAPF32[i41 >> 2] + (d47 * +HEAPF32[i23 >> 2] + d42 * +HEAPF32[i26 >> 2] + d68 * +HEAPF32[i29 >> 2]))) + d43 * (+HEAPF32[i61 >> 2] + (d64 * +HEAPF32[i33 >> 2] + d63 * +HEAPF32[i36 >> 2] + d44 * +HEAPF32[i39 >> 2]) - (+HEAPF32[i50 >> 2] + (d47 * +HEAPF32[i24 >> 2] + d42 * +HEAPF32[i27 >> 2] + d68 * +HEAPF32[i30 >> 2]))) + d49 * (+HEAPF32[i51 >> 2] + (d64 * +HEAPF32[i34 >> 2] + d63 * +HEAPF32[i37 >> 2] + d44 * +HEAPF32[i40 >> 2]) - (+HEAPF32[i21 >> 2] + (d47 * +HEAPF32[i25 >> 2] + d42 * +HEAPF32[i28 >> 2] + d68 * +HEAPF32[i31 >> 2])));
michael@0 17933 if (d67 >= d48) {
michael@0 17934 d78 = d48;
michael@0 17935 d79 = d72;
michael@0 17936 d80 = d71;
michael@0 17937 d81 = d70;
michael@0 17938 d82 = d69;
michael@0 17939 break;
michael@0 17940 }
michael@0 17941 d78 = d67;
michael@0 17942 d79 = d46;
michael@0 17943 d80 = d43;
michael@0 17944 d81 = d49;
michael@0 17945 d82 = d45;
michael@0 17946 } else {
michael@0 17947 d78 = d48;
michael@0 17948 d79 = d72;
michael@0 17949 d80 = d71;
michael@0 17950 d81 = d70;
michael@0 17951 d82 = d69;
michael@0 17952 }
michael@0 17953 } while (0);
michael@0 17954 i15 = i20 + 1 | 0;
michael@0 17955 if ((i15 | 0) < (i62 | 0)) {
michael@0 17956 d69 = d82;
michael@0 17957 d70 = d81;
michael@0 17958 d71 = d80;
michael@0 17959 d72 = d79;
michael@0 17960 i20 = i15;
michael@0 17961 d48 = d78;
michael@0 17962 } else {
michael@0 17963 d73 = d82;
michael@0 17964 d74 = d81;
michael@0 17965 d75 = d80;
michael@0 17966 d76 = d79;
michael@0 17967 d77 = d78;
michael@0 17968 break;
michael@0 17969 }
michael@0 17970 }
michael@0 17971 }
michael@0 17972 } else {
michael@0 17973 d73 = 0.0;
michael@0 17974 d74 = 0.0;
michael@0 17975 d75 = 0.0;
michael@0 17976 d76 = 0.0;
michael@0 17977 d77 = 999999984306749400.0;
michael@0 17978 }
michael@0 17979 +__ZNK13btConvexShape19getMarginNonVirtualEv(i3);
michael@0 17980 +__ZNK13btConvexShape19getMarginNonVirtualEv(i4);
michael@0 17981 if (d77 < 0.0) {
michael@0 17982 i83 = 0;
michael@0 17983 STACKTOP = i11;
michael@0 17984 return i83 | 0;
michael@0 17985 }
michael@0 17986 d78 = +__ZNK13btConvexShape19getMarginNonVirtualEv(i3);
michael@0 17987 d79 = d77 + (d78 + +__ZNK13btConvexShape19getMarginNonVirtualEv(i4) + .5);
michael@0 17988 __ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i17, i3, i4, i2, 0);
michael@0 17989 HEAP32[i18 + 132 >> 2] = 0;
michael@0 17990 d78 = +HEAPF32[i5 + 48 >> 2] + d76 * d79;
michael@0 17991 d77 = +HEAPF32[i5 + 52 >> 2] + d75 * d79;
michael@0 17992 d80 = +HEAPF32[i5 + 56 >> 2] + d74 * d79;
michael@0 17993 i2 = i5;
michael@0 17994 i4 = i18;
michael@0 17995 HEAP32[i4 >> 2] = HEAP32[i2 >> 2];
michael@0 17996 HEAP32[i4 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 17997 HEAP32[i4 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 17998 HEAP32[i4 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 17999 i2 = i5 + 16 | 0;
michael@0 18000 i4 = i5 + 32 | 0;
michael@0 18001 i5 = i18 + 16 | 0;
michael@0 18002 HEAP32[i5 >> 2] = HEAP32[i2 >> 2];
michael@0 18003 HEAP32[i5 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 18004 HEAP32[i5 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 18005 HEAP32[i5 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 18006 i2 = i18 + 32 | 0;
michael@0 18007 HEAP32[i2 >> 2] = HEAP32[i4 >> 2];
michael@0 18008 HEAP32[i2 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 18009 HEAP32[i2 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 18010 HEAP32[i2 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 18011 HEAPF32[i18 + 48 >> 2] = d78;
michael@0 18012 HEAPF32[i18 + 52 >> 2] = d77;
michael@0 18013 HEAPF32[i18 + 56 >> 2] = d80;
michael@0 18014 HEAPF32[i18 + 60 >> 2] = 0.0;
michael@0 18015 i4 = i18 + 64 | 0;
michael@0 18016 i2 = i6;
michael@0 18017 HEAP32[i4 >> 2] = HEAP32[i2 >> 2];
michael@0 18018 HEAP32[i4 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 18019 HEAP32[i4 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 18020 HEAP32[i4 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 18021 i2 = i18 + 80 | 0;
michael@0 18022 i4 = i6 + 16 | 0;
michael@0 18023 HEAP32[i2 >> 2] = HEAP32[i4 >> 2];
michael@0 18024 HEAP32[i2 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 18025 HEAP32[i2 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 18026 HEAP32[i2 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 18027 i4 = i18 + 96 | 0;
michael@0 18028 i2 = i6 + 32 | 0;
michael@0 18029 HEAP32[i4 >> 2] = HEAP32[i2 >> 2];
michael@0 18030 HEAP32[i4 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 18031 HEAP32[i4 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 18032 HEAP32[i4 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 18033 i2 = i18 + 112 | 0;
michael@0 18034 i4 = i6 + 48 | 0;
michael@0 18035 HEAP32[i2 >> 2] = HEAP32[i4 >> 2];
michael@0 18036 HEAP32[i2 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 18037 HEAP32[i2 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 18038 HEAP32[i2 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 18039 HEAPF32[i18 + 128 >> 2] = 999999984306749400.0;
michael@0 18040 HEAP32[i19 >> 2] = 1384;
michael@0 18041 i4 = i19 + 40 | 0;
michael@0 18042 HEAP8[i4] = 0;
michael@0 18043 HEAPF32[i17 + 4 >> 2] = -0.0 - d76;
michael@0 18044 HEAPF32[i17 + 8 >> 2] = -0.0 - d75;
michael@0 18045 HEAPF32[i17 + 12 >> 2] = -0.0 - d74;
michael@0 18046 HEAPF32[i17 + 16 >> 2] = 0.0;
michael@0 18047 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i17, i18, i19 | 0, i10, 0);
michael@0 18048 d80 = d79 - +HEAPF32[i19 + 36 >> 2];
michael@0 18049 i10 = HEAP8[i4] | 0;
michael@0 18050 if (i10 << 24 >> 24 != 0) {
michael@0 18051 i4 = i19 + 20 | 0;
michael@0 18052 d79 = +HEAPF32[i19 + 24 >> 2] - d75 * d80;
michael@0 18053 d77 = +HEAPF32[i19 + 28 >> 2] - d74 * d80;
michael@0 18054 HEAPF32[i8 >> 2] = +HEAPF32[i4 >> 2] - d76 * d80;
michael@0 18055 HEAPF32[i8 + 4 >> 2] = d79;
michael@0 18056 HEAPF32[i8 + 8 >> 2] = d77;
michael@0 18057 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 18058 i8 = i9;
michael@0 18059 i9 = i4;
michael@0 18060 HEAP32[i8 >> 2] = HEAP32[i9 >> 2];
michael@0 18061 HEAP32[i8 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 18062 HEAP32[i8 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 18063 HEAP32[i8 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 18064 HEAPF32[i7 >> 2] = d76;
michael@0 18065 HEAPF32[i7 + 4 >> 2] = d75;
michael@0 18066 HEAPF32[i7 + 8 >> 2] = d74;
michael@0 18067 HEAPF32[i7 + 12 >> 2] = d73;
michael@0 18068 }
michael@0 18069 i83 = i10 << 24 >> 24 != 0;
michael@0 18070 STACKTOP = i11;
michael@0 18071 return i83 | 0;
michael@0 18072 }
michael@0 18073 function _main(i1, i2) {
michael@0 18074 i1 = i1 | 0;
michael@0 18075 i2 = i2 | 0;
michael@0 18076 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0;
michael@0 18077 i2 = STACKTOP;
michael@0 18078 STACKTOP = STACKTOP + 80 | 0;
michael@0 18079 i1 = i2 | 0;
michael@0 18080 i3 = i2 + 32 | 0;
michael@0 18081 i4 = i2 + 48 | 0;
michael@0 18082 i5 = i2 + 64 | 0;
michael@0 18083 i6 = i5 | 0;
michael@0 18084 i7 = STACKTOP;
michael@0 18085 STACKTOP = STACKTOP + 136 | 0;
michael@0 18086 i8 = STACKTOP;
michael@0 18087 STACKTOP = STACKTOP + 16 | 0;
michael@0 18088 i9 = STACKTOP;
michael@0 18089 STACKTOP = STACKTOP + 16 | 0;
michael@0 18090 i10 = i9 | 0;
michael@0 18091 i11 = STACKTOP;
michael@0 18092 STACKTOP = STACKTOP + 16 | 0;
michael@0 18093 i12 = STACKTOP;
michael@0 18094 STACKTOP = STACKTOP + 136 | 0;
michael@0 18095 i13 = STACKTOP;
michael@0 18096 STACKTOP = STACKTOP + 64 | 0;
michael@0 18097 i14 = __Znwj(88) | 0;
michael@0 18098 i15 = i14;
michael@0 18099 HEAP32[i1 >> 2] = 0;
michael@0 18100 HEAP32[i1 + 4 >> 2] = 0;
michael@0 18101 HEAP32[i1 + 8 >> 2] = 0;
michael@0 18102 HEAP32[i1 + 12 >> 2] = 4096;
michael@0 18103 HEAP32[i1 + 16 >> 2] = 4096;
michael@0 18104 HEAP32[i1 + 20 >> 2] = 0;
michael@0 18105 HEAP32[i1 + 24 >> 2] = 0;
michael@0 18106 HEAP32[i1 + 28 >> 2] = 1;
michael@0 18107 __ZN31btDefaultCollisionConfigurationC2ERK34btDefaultCollisionConstructionInfo(i15, i1);
michael@0 18108 i1 = __Znwj(5388) | 0;
michael@0 18109 i16 = i1;
michael@0 18110 i17 = i14;
michael@0 18111 __ZN21btCollisionDispatcherC2EP24btCollisionConfiguration(i16, i17);
michael@0 18112 i18 = __Znwj(156) | 0;
michael@0 18113 __ZN16btDbvtBroadphaseC2EP22btOverlappingPairCache(i18, 0);
michael@0 18114 i19 = i18;
michael@0 18115 i20 = __Znwj(128) | 0;
michael@0 18116 i21 = i20;
michael@0 18117 __ZN35btSequentialImpulseConstraintSolverC2Ev(i21);
michael@0 18118 i22 = __Znwj(268) | 0;
michael@0 18119 i23 = i22;
michael@0 18120 __ZN23btDiscreteDynamicsWorldC2EP12btDispatcherP21btBroadphaseInterfaceP18btConstraintSolverP24btCollisionConfiguration(i23, i1, i19, i20, i17);
michael@0 18121 i17 = HEAP32[(HEAP32[i22 >> 2] | 0) + 68 >> 2] | 0;
michael@0 18122 HEAPF32[i3 >> 2] = 0.0;
michael@0 18123 HEAPF32[i3 + 4 >> 2] = -10.0;
michael@0 18124 HEAPF32[i3 + 8 >> 2] = 0.0;
michael@0 18125 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 18126 FUNCTION_TABLE_vii[i17 & 127](i23, i3);
michael@0 18127 i3 = __Z22btAlignedAllocInternalji(56, 16) | 0;
michael@0 18128 __ZN23btPolyhedralConvexShapeC2Ev(i3);
michael@0 18129 HEAP32[i3 >> 2] = 4984;
michael@0 18130 HEAP32[i3 + 4 >> 2] = 0;
michael@0 18131 i17 = i3;
michael@0 18132 i24 = i3;
michael@0 18133 d25 = +FUNCTION_TABLE_fi[HEAP32[1257] & 7](i17);
michael@0 18134 d26 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i24 >> 2] | 0) + 44 >> 2] & 7](i17);
michael@0 18135 d27 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i24 >> 2] | 0) + 44 >> 2] & 7](i17);
michael@0 18136 d28 = +HEAPF32[i3 + 16 >> 2] * 50.0 - d26;
michael@0 18137 d26 = +HEAPF32[i3 + 20 >> 2] * 50.0 - d27;
michael@0 18138 HEAPF32[i3 + 28 >> 2] = +HEAPF32[i3 + 12 >> 2] * 50.0 - d25;
michael@0 18139 HEAPF32[i3 + 32 >> 2] = d28;
michael@0 18140 HEAPF32[i3 + 36 >> 2] = d26;
michael@0 18141 HEAPF32[i3 + 40 >> 2] = 0.0;
michael@0 18142 i17 = i3;
michael@0 18143 i3 = __Z22btAlignedAllocInternalji(4, 16) | 0;
michael@0 18144 i24 = i3;
michael@0 18145 i29 = (i3 | 0) == 0;
michael@0 18146 if (!i29) {
michael@0 18147 HEAP32[i24 >> 2] = i17;
michael@0 18148 }
michael@0 18149 i30 = i4 | 0;
michael@0 18150 _memset(i30 | 0, 0, 16);
michael@0 18151 _memset(i5 | 0, 0, 16);
michael@0 18152 i31 = __Znwj(200) | 0;
michael@0 18153 do {
michael@0 18154 if ((HEAP8[14344] | 0) == 0) {
michael@0 18155 if ((___cxa_guard_acquire(14344) | 0) == 0) {
michael@0 18156 break;
michael@0 18157 }
michael@0 18158 do {
michael@0 18159 if ((HEAP8[14352] | 0) == 0) {
michael@0 18160 if ((___cxa_guard_acquire(14352) | 0) == 0) {
michael@0 18161 break;
michael@0 18162 }
michael@0 18163 HEAPF32[3550] = 1.0;
michael@0 18164 _memset(14204, 0, 16);
michael@0 18165 HEAPF32[3555] = 1.0;
michael@0 18166 _memset(14224, 0, 16);
michael@0 18167 HEAPF32[3560] = 1.0;
michael@0 18168 HEAPF32[3561] = 0.0;
michael@0 18169 }
michael@0 18170 } while (0);
michael@0 18171 HEAP32[3534] = HEAP32[3550];
michael@0 18172 HEAP32[3535] = HEAP32[3551];
michael@0 18173 HEAP32[3536] = HEAP32[3552];
michael@0 18174 HEAP32[3537] = HEAP32[3553];
michael@0 18175 HEAP32[3538] = HEAP32[3554];
michael@0 18176 HEAP32[14156 >> 2] = HEAP32[14220 >> 2];
michael@0 18177 HEAP32[14160 >> 2] = HEAP32[14224 >> 2];
michael@0 18178 HEAP32[14164 >> 2] = HEAP32[14228 >> 2];
michael@0 18179 HEAP32[3542] = HEAP32[3558];
michael@0 18180 HEAP32[14172 >> 2] = HEAP32[14236 >> 2];
michael@0 18181 HEAP32[14176 >> 2] = HEAP32[14240 >> 2];
michael@0 18182 HEAP32[14180 >> 2] = HEAP32[14244 >> 2];
michael@0 18183 _memset(14184, 0, 16);
michael@0 18184 }
michael@0 18185 } while (0);
michael@0 18186 HEAP32[i31 >> 2] = 3864;
michael@0 18187 HEAPF32[i31 + 4 >> 2] = 1.0;
michael@0 18188 i32 = i31 + 8 | 0;
michael@0 18189 HEAP32[i32 >> 2] = HEAP32[i30 >> 2];
michael@0 18190 HEAP32[i32 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 18191 HEAP32[i32 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 18192 i32 = HEAP32[i4 + 12 >> 2] | 0;
michael@0 18193 HEAP32[i31 + 20 >> 2] = i32;
michael@0 18194 HEAPF32[i31 + 24 >> 2] = 1.0;
michael@0 18195 i4 = i31 + 28 | 0;
michael@0 18196 i33 = HEAP32[i6 >> 2] | 0;
michael@0 18197 i34 = HEAP32[i6 + 4 >> 2] | 0;
michael@0 18198 HEAP32[i4 >> 2] = i33;
michael@0 18199 HEAP32[i4 + 4 >> 2] = i34;
michael@0 18200 i4 = i5 + 8 | 0;
michael@0 18201 i5 = i31 + 36 | 0;
michael@0 18202 i6 = HEAP32[i4 >> 2] | 0;
michael@0 18203 i35 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 18204 HEAP32[i5 >> 2] = i6;
michael@0 18205 HEAP32[i5 + 4 >> 2] = i35;
michael@0 18206 HEAPF32[i31 + 44 >> 2] = 1.0;
michael@0 18207 HEAPF32[i31 + 48 >> 2] = 0.0;
michael@0 18208 HEAPF32[i31 + 52 >> 2] = 0.0;
michael@0 18209 HEAPF32[i31 + 56 >> 2] = -56.0;
michael@0 18210 HEAPF32[i31 + 60 >> 2] = 0.0;
michael@0 18211 HEAPF32[i31 + 64 >> 2] = 0.0;
michael@0 18212 i5 = i31 + 68 | 0;
michael@0 18213 HEAP32[i5 >> 2] = HEAP32[3534];
michael@0 18214 HEAP32[i5 + 4 >> 2] = HEAP32[3535];
michael@0 18215 HEAP32[i5 + 8 >> 2] = HEAP32[3536];
michael@0 18216 HEAP32[i5 + 12 >> 2] = HEAP32[3537];
michael@0 18217 i5 = i31 + 84 | 0;
michael@0 18218 HEAP32[i5 >> 2] = HEAP32[3538];
michael@0 18219 HEAP32[i5 + 4 >> 2] = HEAP32[14156 >> 2];
michael@0 18220 HEAP32[i5 + 8 >> 2] = HEAP32[14160 >> 2];
michael@0 18221 HEAP32[i5 + 12 >> 2] = HEAP32[14164 >> 2];
michael@0 18222 i5 = i31 + 100 | 0;
michael@0 18223 HEAP32[i5 >> 2] = HEAP32[3542];
michael@0 18224 HEAP32[i5 + 4 >> 2] = HEAP32[14172 >> 2];
michael@0 18225 HEAP32[i5 + 8 >> 2] = HEAP32[14176 >> 2];
michael@0 18226 HEAP32[i5 + 12 >> 2] = HEAP32[14180 >> 2];
michael@0 18227 i5 = i31 + 116 | 0;
michael@0 18228 HEAP32[i5 >> 2] = HEAP32[3546];
michael@0 18229 HEAP32[i5 + 4 >> 2] = HEAP32[14188 >> 2];
michael@0 18230 HEAP32[i5 + 8 >> 2] = HEAP32[14192 >> 2];
michael@0 18231 HEAP32[i5 + 12 >> 2] = HEAP32[14196 >> 2];
michael@0 18232 HEAPF32[i31 + 132 >> 2] = 1.0;
michael@0 18233 i5 = i31 + 136 | 0;
michael@0 18234 HEAP32[i5 >> 2] = HEAP32[i30 >> 2];
michael@0 18235 HEAP32[i5 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 18236 HEAP32[i5 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 18237 HEAP32[i31 + 148 >> 2] = i32;
michael@0 18238 HEAPF32[i31 + 152 >> 2] = 1.0;
michael@0 18239 i32 = i31 + 156 | 0;
michael@0 18240 HEAP32[i32 >> 2] = i33;
michael@0 18241 HEAP32[i32 + 4 >> 2] = i34;
michael@0 18242 i34 = i31 + 164 | 0;
michael@0 18243 HEAP32[i34 >> 2] = i6;
michael@0 18244 HEAP32[i34 + 4 >> 2] = i35;
michael@0 18245 HEAPF32[i31 + 172 >> 2] = 1.0;
michael@0 18246 HEAPF32[i31 + 176 >> 2] = 0.0;
michael@0 18247 HEAPF32[i31 + 180 >> 2] = 0.0;
michael@0 18248 HEAPF32[i31 + 184 >> 2] = -56.0;
michael@0 18249 HEAPF32[i31 + 188 >> 2] = 0.0;
michael@0 18250 HEAPF32[i31 + 192 >> 2] = 0.0;
michael@0 18251 HEAP32[i31 + 196 >> 2] = 0;
michael@0 18252 HEAPF32[i7 >> 2] = 0.0;
michael@0 18253 HEAP32[i7 + 4 >> 2] = i31;
michael@0 18254 HEAP32[i7 + 72 >> 2] = i17;
michael@0 18255 _memset(i7 + 76 | 0, 0, 24);
michael@0 18256 HEAPF32[i7 + 100 >> 2] = .5;
michael@0 18257 HEAPF32[i7 + 104 >> 2] = 0.0;
michael@0 18258 HEAPF32[i7 + 108 >> 2] = .800000011920929;
michael@0 18259 HEAPF32[i7 + 112 >> 2] = 1.0;
michael@0 18260 HEAP8[i7 + 116 | 0] = 0;
michael@0 18261 HEAPF32[i7 + 120 >> 2] = .004999999888241291;
michael@0 18262 HEAPF32[i7 + 124 >> 2] = .009999999776482582;
michael@0 18263 HEAPF32[i7 + 128 >> 2] = .009999999776482582;
michael@0 18264 HEAPF32[i7 + 132 >> 2] = .009999999776482582;
michael@0 18265 HEAPF32[i7 + 8 >> 2] = 1.0;
michael@0 18266 _memset(i7 + 12 | 0, 0, 16);
michael@0 18267 HEAPF32[i7 + 28 >> 2] = 1.0;
michael@0 18268 _memset(i7 + 32 | 0, 0, 16);
michael@0 18269 HEAPF32[i7 + 48 >> 2] = 1.0;
michael@0 18270 _memset(i7 + 52 | 0, 0, 20);
michael@0 18271 i17 = __Z22btAlignedAllocInternalji(608, 16) | 0;
michael@0 18272 __ZN11btRigidBodyC2ERKNS_27btRigidBodyConstructionInfoE(i17, i7);
michael@0 18273 i7 = i22;
michael@0 18274 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i7 >> 2] | 0) + 80 >> 2] & 127](i23, i17);
michael@0 18275 i17 = __Z22btAlignedAllocInternalji(52, 16) | 0;
michael@0 18276 __ZN21btConvexInternalShapeC2Ev(i17);
michael@0 18277 HEAP32[i17 >> 2] = 4728;
michael@0 18278 HEAP32[i17 + 4 >> 2] = 8;
michael@0 18279 HEAPF32[i17 + 28 >> 2] = 1.0;
michael@0 18280 HEAPF32[i17 + 44 >> 2] = 1.0;
michael@0 18281 i31 = i17;
michael@0 18282 i35 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 18283 i34 = i35;
michael@0 18284 if ((i35 | 0) != 0) {
michael@0 18285 HEAP32[i34 >> 2] = HEAP32[i24 >> 2];
michael@0 18286 }
michael@0 18287 if (!i29) {
michael@0 18288 __Z21btAlignedFreeInternalPv(i3);
michael@0 18289 }
michael@0 18290 i3 = i35 + 4 | 0;
michael@0 18291 if ((i3 | 0) != 0) {
michael@0 18292 HEAP32[i3 >> 2] = i31;
michael@0 18293 }
michael@0 18294 i3 = i8 | 0;
michael@0 18295 _memset(i3 | 0, 0, 16);
michael@0 18296 _memset(i9 | 0, 0, 16);
michael@0 18297 _memset(i11 | 0, 0, 16);
michael@0 18298 FUNCTION_TABLE_vifi[HEAP32[(HEAP32[i17 >> 2] | 0) + 32 >> 2] & 15](i31, 1.0, i11);
michael@0 18299 i17 = __Znwj(200) | 0;
michael@0 18300 do {
michael@0 18301 if ((HEAP8[14344] | 0) == 0) {
michael@0 18302 if ((___cxa_guard_acquire(14344) | 0) == 0) {
michael@0 18303 break;
michael@0 18304 }
michael@0 18305 do {
michael@0 18306 if ((HEAP8[14352] | 0) == 0) {
michael@0 18307 if ((___cxa_guard_acquire(14352) | 0) == 0) {
michael@0 18308 break;
michael@0 18309 }
michael@0 18310 HEAPF32[3550] = 1.0;
michael@0 18311 _memset(14204, 0, 16);
michael@0 18312 HEAPF32[3555] = 1.0;
michael@0 18313 _memset(14224, 0, 16);
michael@0 18314 HEAPF32[3560] = 1.0;
michael@0 18315 HEAPF32[3561] = 0.0;
michael@0 18316 }
michael@0 18317 } while (0);
michael@0 18318 HEAP32[3534] = HEAP32[3550];
michael@0 18319 HEAP32[3535] = HEAP32[3551];
michael@0 18320 HEAP32[3536] = HEAP32[3552];
michael@0 18321 HEAP32[3537] = HEAP32[3553];
michael@0 18322 HEAP32[3538] = HEAP32[3554];
michael@0 18323 HEAP32[14156 >> 2] = HEAP32[14220 >> 2];
michael@0 18324 HEAP32[14160 >> 2] = HEAP32[14224 >> 2];
michael@0 18325 HEAP32[14164 >> 2] = HEAP32[14228 >> 2];
michael@0 18326 HEAP32[3542] = HEAP32[3558];
michael@0 18327 HEAP32[14172 >> 2] = HEAP32[14236 >> 2];
michael@0 18328 HEAP32[14176 >> 2] = HEAP32[14240 >> 2];
michael@0 18329 HEAP32[14180 >> 2] = HEAP32[14244 >> 2];
michael@0 18330 _memset(14184, 0, 16);
michael@0 18331 }
michael@0 18332 } while (0);
michael@0 18333 HEAP32[i17 >> 2] = 3864;
michael@0 18334 HEAPF32[i17 + 4 >> 2] = 1.0;
michael@0 18335 i29 = i17 + 8 | 0;
michael@0 18336 HEAP32[i29 >> 2] = HEAP32[i3 >> 2];
michael@0 18337 HEAP32[i29 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 18338 HEAP32[i29 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 18339 i29 = HEAP32[i8 + 12 >> 2] | 0;
michael@0 18340 HEAP32[i17 + 20 >> 2] = i29;
michael@0 18341 HEAPF32[i17 + 24 >> 2] = 1.0;
michael@0 18342 i8 = i17 + 28 | 0;
michael@0 18343 i24 = HEAP32[i10 >> 2] | 0;
michael@0 18344 i6 = HEAP32[i10 + 4 >> 2] | 0;
michael@0 18345 HEAP32[i8 >> 2] = i24;
michael@0 18346 HEAP32[i8 + 4 >> 2] = i6;
michael@0 18347 i8 = i9 + 8 | 0;
michael@0 18348 i9 = i17 + 36 | 0;
michael@0 18349 i10 = HEAP32[i8 >> 2] | 0;
michael@0 18350 i32 = HEAP32[i8 + 4 >> 2] | 0;
michael@0 18351 HEAP32[i9 >> 2] = i10;
michael@0 18352 HEAP32[i9 + 4 >> 2] = i32;
michael@0 18353 HEAPF32[i17 + 44 >> 2] = 1.0;
michael@0 18354 HEAPF32[i17 + 48 >> 2] = 0.0;
michael@0 18355 HEAPF32[i17 + 52 >> 2] = 2.0;
michael@0 18356 HEAPF32[i17 + 56 >> 2] = 10.0;
michael@0 18357 HEAPF32[i17 + 60 >> 2] = 0.0;
michael@0 18358 HEAPF32[i17 + 64 >> 2] = 0.0;
michael@0 18359 i9 = i17 + 68 | 0;
michael@0 18360 HEAP32[i9 >> 2] = HEAP32[3534];
michael@0 18361 HEAP32[i9 + 4 >> 2] = HEAP32[3535];
michael@0 18362 HEAP32[i9 + 8 >> 2] = HEAP32[3536];
michael@0 18363 HEAP32[i9 + 12 >> 2] = HEAP32[3537];
michael@0 18364 i9 = i17 + 84 | 0;
michael@0 18365 HEAP32[i9 >> 2] = HEAP32[3538];
michael@0 18366 HEAP32[i9 + 4 >> 2] = HEAP32[14156 >> 2];
michael@0 18367 HEAP32[i9 + 8 >> 2] = HEAP32[14160 >> 2];
michael@0 18368 HEAP32[i9 + 12 >> 2] = HEAP32[14164 >> 2];
michael@0 18369 i9 = i17 + 100 | 0;
michael@0 18370 HEAP32[i9 >> 2] = HEAP32[3542];
michael@0 18371 HEAP32[i9 + 4 >> 2] = HEAP32[14172 >> 2];
michael@0 18372 HEAP32[i9 + 8 >> 2] = HEAP32[14176 >> 2];
michael@0 18373 HEAP32[i9 + 12 >> 2] = HEAP32[14180 >> 2];
michael@0 18374 i9 = i17 + 116 | 0;
michael@0 18375 HEAP32[i9 >> 2] = HEAP32[3546];
michael@0 18376 HEAP32[i9 + 4 >> 2] = HEAP32[14188 >> 2];
michael@0 18377 HEAP32[i9 + 8 >> 2] = HEAP32[14192 >> 2];
michael@0 18378 HEAP32[i9 + 12 >> 2] = HEAP32[14196 >> 2];
michael@0 18379 HEAPF32[i17 + 132 >> 2] = 1.0;
michael@0 18380 i9 = i17 + 136 | 0;
michael@0 18381 HEAP32[i9 >> 2] = HEAP32[i3 >> 2];
michael@0 18382 HEAP32[i9 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 18383 HEAP32[i9 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 18384 HEAP32[i17 + 148 >> 2] = i29;
michael@0 18385 HEAPF32[i17 + 152 >> 2] = 1.0;
michael@0 18386 i29 = i17 + 156 | 0;
michael@0 18387 HEAP32[i29 >> 2] = i24;
michael@0 18388 HEAP32[i29 + 4 >> 2] = i6;
michael@0 18389 i6 = i17 + 164 | 0;
michael@0 18390 HEAP32[i6 >> 2] = i10;
michael@0 18391 HEAP32[i6 + 4 >> 2] = i32;
michael@0 18392 HEAPF32[i17 + 172 >> 2] = 1.0;
michael@0 18393 HEAPF32[i17 + 176 >> 2] = 0.0;
michael@0 18394 HEAPF32[i17 + 180 >> 2] = 2.0;
michael@0 18395 HEAPF32[i17 + 184 >> 2] = 10.0;
michael@0 18396 HEAPF32[i17 + 188 >> 2] = 0.0;
michael@0 18397 HEAPF32[i17 + 192 >> 2] = 0.0;
michael@0 18398 HEAP32[i17 + 196 >> 2] = 0;
michael@0 18399 HEAPF32[i12 >> 2] = 1.0;
michael@0 18400 HEAP32[i12 + 4 >> 2] = i17;
michael@0 18401 HEAP32[i12 + 72 >> 2] = i31;
michael@0 18402 i31 = i12 + 76 | 0;
michael@0 18403 i17 = i11;
michael@0 18404 HEAP32[i31 >> 2] = HEAP32[i17 >> 2];
michael@0 18405 HEAP32[i31 + 4 >> 2] = HEAP32[i17 + 4 >> 2];
michael@0 18406 HEAP32[i31 + 8 >> 2] = HEAP32[i17 + 8 >> 2];
michael@0 18407 HEAP32[i31 + 12 >> 2] = HEAP32[i17 + 12 >> 2];
michael@0 18408 HEAPF32[i12 + 92 >> 2] = 0.0;
michael@0 18409 HEAPF32[i12 + 96 >> 2] = 0.0;
michael@0 18410 HEAPF32[i12 + 100 >> 2] = .5;
michael@0 18411 HEAPF32[i12 + 104 >> 2] = 0.0;
michael@0 18412 HEAPF32[i12 + 108 >> 2] = .800000011920929;
michael@0 18413 HEAPF32[i12 + 112 >> 2] = 1.0;
michael@0 18414 HEAP8[i12 + 116 | 0] = 0;
michael@0 18415 HEAPF32[i12 + 120 >> 2] = .004999999888241291;
michael@0 18416 HEAPF32[i12 + 124 >> 2] = .009999999776482582;
michael@0 18417 HEAPF32[i12 + 128 >> 2] = .009999999776482582;
michael@0 18418 HEAPF32[i12 + 132 >> 2] = .009999999776482582;
michael@0 18419 HEAPF32[i12 + 8 >> 2] = 1.0;
michael@0 18420 _memset(i12 + 12 | 0, 0, 16);
michael@0 18421 HEAPF32[i12 + 28 >> 2] = 1.0;
michael@0 18422 _memset(i12 + 32 | 0, 0, 16);
michael@0 18423 HEAPF32[i12 + 48 >> 2] = 1.0;
michael@0 18424 _memset(i12 + 52 | 0, 0, 20);
michael@0 18425 i17 = __Z22btAlignedAllocInternalji(608, 16) | 0;
michael@0 18426 __ZN11btRigidBodyC2ERKNS_27btRigidBodyConstructionInfoE(i17, i12);
michael@0 18427 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i7 >> 2] | 0) + 80 >> 2] & 127](i23, i17);
michael@0 18428 i17 = i22;
michael@0 18429 i7 = i22 + 8 | 0;
michael@0 18430 i12 = i22 + 16 | 0;
michael@0 18431 i31 = i13 + 48 | 0;
michael@0 18432 i11 = i13 + 52 | 0;
michael@0 18433 i32 = i13 + 56 | 0;
michael@0 18434 i6 = 0;
michael@0 18435 do {
michael@0 18436 FUNCTION_TABLE_iifif[HEAP32[(HEAP32[i17 >> 2] | 0) + 48 >> 2] & 3](i23, .01666666753590107, 10, .01666666753590107) | 0;
michael@0 18437 i10 = HEAP32[i7 >> 2] | 0;
michael@0 18438 if ((i10 | 0) > 0) {
michael@0 18439 i29 = i10;
michael@0 18440 do {
michael@0 18441 i29 = i29 - 1 | 0;
michael@0 18442 i10 = HEAP32[(HEAP32[i12 >> 2] | 0) + (i29 << 2) >> 2] | 0;
michael@0 18443 do {
michael@0 18444 if (!((HEAP32[i10 + 232 >> 2] & 2 | 0) == 0 | (i10 | 0) == 0)) {
michael@0 18445 i24 = HEAP32[i10 + 472 >> 2] | 0;
michael@0 18446 if ((i24 | 0) == 0) {
michael@0 18447 break;
michael@0 18448 }
michael@0 18449 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i24 >> 2] | 0) + 8 >> 2] & 127](i24, i13);
michael@0 18450 d26 = +HEAPF32[i31 >> 2];
michael@0 18451 d28 = +HEAPF32[i11 >> 2];
michael@0 18452 d25 = +HEAPF32[i32 >> 2];
michael@0 18453 _printf(1128, (i24 = STACKTOP, STACKTOP = STACKTOP + 24 | 0, HEAPF64[i24 >> 3] = d26, HEAPF64[i24 + 8 >> 3] = d28, HEAPF64[i24 + 16 >> 3] = d25, i24) | 0) | 0;
michael@0 18454 STACKTOP = i24;
michael@0 18455 }
michael@0 18456 } while (0);
michael@0 18457 } while ((i29 | 0) > 0);
michael@0 18458 }
michael@0 18459 i6 = i6 + 1 | 0;
michael@0 18460 } while ((i6 | 0) < 135);
michael@0 18461 i6 = HEAP32[i7 >> 2] | 0;
michael@0 18462 if ((i6 | 0) > 0) {
michael@0 18463 i7 = i22;
michael@0 18464 i32 = i6;
michael@0 18465 do {
michael@0 18466 i32 = i32 - 1 | 0;
michael@0 18467 i6 = HEAP32[(HEAP32[i12 >> 2] | 0) + (i32 << 2) >> 2] | 0;
michael@0 18468 i11 = (i6 | 0) == 0;
michael@0 18469 do {
michael@0 18470 if (!((HEAP32[i6 + 232 >> 2] & 2 | 0) == 0 | i11)) {
michael@0 18471 i31 = HEAP32[i6 + 472 >> 2] | 0;
michael@0 18472 if ((i31 | 0) == 0) {
michael@0 18473 break;
michael@0 18474 }
michael@0 18475 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i31 >> 2] | 0) + 4 >> 2] & 511](i31);
michael@0 18476 }
michael@0 18477 } while (0);
michael@0 18478 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i7 >> 2] | 0) + 36 >> 2] & 127](i23, i6);
michael@0 18479 if (!i11) {
michael@0 18480 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 511](i6);
michael@0 18481 }
michael@0 18482 } while ((i32 | 0) > 0);
michael@0 18483 }
michael@0 18484 i32 = HEAP32[i34 >> 2] | 0;
michael@0 18485 HEAP32[i34 >> 2] = 0;
michael@0 18486 if ((i32 | 0) != 0) {
michael@0 18487 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i32 >> 2] | 0) + 4 >> 2] & 511](i32);
michael@0 18488 }
michael@0 18489 i32 = i35 + 4 | 0;
michael@0 18490 i34 = HEAP32[i32 >> 2] | 0;
michael@0 18491 HEAP32[i32 >> 2] = 0;
michael@0 18492 if ((i34 | 0) != 0) {
michael@0 18493 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i34 >> 2] | 0) + 4 >> 2] & 511](i34);
michael@0 18494 }
michael@0 18495 if ((i22 | 0) != 0) {
michael@0 18496 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i22 >> 2] | 0) + 4 >> 2] & 511](i23);
michael@0 18497 }
michael@0 18498 if ((i20 | 0) != 0) {
michael@0 18499 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i20 >> 2] | 0) + 4 >> 2] & 511](i21);
michael@0 18500 }
michael@0 18501 if ((i18 | 0) != 0) {
michael@0 18502 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i18 >> 2] | 0) + 4 >> 2] & 511](i19);
michael@0 18503 }
michael@0 18504 if ((i1 | 0) != 0) {
michael@0 18505 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i1 >> 2] | 0) + 4 >> 2] & 511](i16);
michael@0 18506 }
michael@0 18507 if ((i14 | 0) != 0) {
michael@0 18508 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i14 >> 2] | 0) + 4 >> 2] & 511](i15);
michael@0 18509 }
michael@0 18510 if ((i35 | 0) == 0) {
michael@0 18511 STACKTOP = i2;
michael@0 18512 return 0;
michael@0 18513 }
michael@0 18514 __Z21btAlignedFreeInternalPv(i35);
michael@0 18515 STACKTOP = i2;
michael@0 18516 return 0;
michael@0 18517 }
michael@0 18518 function __ZN23btPolyhedralConvexShape28initializePolyhedralFeaturesEv(i1) {
michael@0 18519 i1 = i1 | 0;
michael@0 18520 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, i45 = 0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, i50 = 0, i51 = 0, d52 = 0.0, i53 = 0, i54 = 0;
michael@0 18521 i2 = STACKTOP;
michael@0 18522 STACKTOP = STACKTOP + 248 | 0;
michael@0 18523 i3 = i2 + 16 | 0;
michael@0 18524 i4 = i2 + 80 | 0;
michael@0 18525 i5 = i2 + 96 | 0;
michael@0 18526 i6 = i2 + 152 | 0;
michael@0 18527 i7 = i2 + 168 | 0;
michael@0 18528 i8 = i2 + 216 | 0;
michael@0 18529 i9 = i2 + 232 | 0;
michael@0 18530 i10 = i1 + 52 | 0;
michael@0 18531 i11 = HEAP32[i10 >> 2] | 0;
michael@0 18532 if ((i11 | 0) != 0) {
michael@0 18533 __Z21btAlignedFreeInternalPv(i11);
michael@0 18534 }
michael@0 18535 i11 = __Z22btAlignedAllocInternalji(80, 16) | 0;
michael@0 18536 if ((i11 | 0) == 0) {
michael@0 18537 i12 = 0;
michael@0 18538 } else {
michael@0 18539 i13 = i11;
michael@0 18540 __ZN18btConvexPolyhedronC2Ev(i13);
michael@0 18541 i12 = i13;
michael@0 18542 }
michael@0 18543 HEAP32[i10 >> 2] = i12;
michael@0 18544 i12 = i1;
michael@0 18545 i13 = i1;
michael@0 18546 i11 = i2 | 0;
michael@0 18547 i14 = 0;
michael@0 18548 i15 = 0;
michael@0 18549 i16 = 0;
michael@0 18550 while (1) {
michael@0 18551 if ((i14 | 0) >= (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i12 >> 2] | 0) + 88 >> 2] & 127](i1) | 0)) {
michael@0 18552 break;
michael@0 18553 }
michael@0 18554 do {
michael@0 18555 if ((i14 | 0) == (i15 | 0)) {
michael@0 18556 i17 = (i15 | 0) == 0 ? 1 : i15 << 1;
michael@0 18557 if ((i15 | 0) >= (i17 | 0)) {
michael@0 18558 i18 = i15;
michael@0 18559 i19 = i16;
michael@0 18560 break;
michael@0 18561 }
michael@0 18562 if ((i17 | 0) == 0) {
michael@0 18563 i20 = 0;
michael@0 18564 } else {
michael@0 18565 i20 = __Z22btAlignedAllocInternalji(i17 << 4, 16) | 0;
michael@0 18566 }
michael@0 18567 if ((i15 | 0) > 0) {
michael@0 18568 i21 = 0;
michael@0 18569 do {
michael@0 18570 i22 = i20 + (i21 << 4) | 0;
michael@0 18571 if ((i22 | 0) != 0) {
michael@0 18572 i23 = i22;
michael@0 18573 i22 = i16 + (i21 << 4) | 0;
michael@0 18574 HEAP32[i23 >> 2] = HEAP32[i22 >> 2];
michael@0 18575 HEAP32[i23 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 18576 HEAP32[i23 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 18577 HEAP32[i23 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 18578 }
michael@0 18579 i21 = i21 + 1 | 0;
michael@0 18580 } while ((i21 | 0) < (i15 | 0));
michael@0 18581 }
michael@0 18582 if ((i16 | 0) == 0) {
michael@0 18583 i18 = i17;
michael@0 18584 i19 = i20;
michael@0 18585 break;
michael@0 18586 }
michael@0 18587 __Z21btAlignedFreeInternalPv(i16);
michael@0 18588 i18 = i17;
michael@0 18589 i19 = i20;
michael@0 18590 } else {
michael@0 18591 i18 = i15;
michael@0 18592 i19 = i16;
michael@0 18593 }
michael@0 18594 } while (0);
michael@0 18595 i21 = i19 + (i14 << 4) | 0;
michael@0 18596 if ((i21 | 0) != 0) {
michael@0 18597 i22 = i21;
michael@0 18598 HEAP32[i22 >> 2] = HEAP32[i11 >> 2];
michael@0 18599 HEAP32[i22 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 18600 HEAP32[i22 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 18601 HEAP32[i22 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 18602 }
michael@0 18603 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i13 >> 2] | 0) + 100 >> 2] & 127](i1, i14, i21);
michael@0 18604 i14 = i14 + 1 | 0;
michael@0 18605 i15 = i18;
michael@0 18606 i16 = i19;
michael@0 18607 }
michael@0 18608 HEAP8[i3 + 16 | 0] = 1;
michael@0 18609 i19 = i3 + 12 | 0;
michael@0 18610 HEAP32[i19 >> 2] = 0;
michael@0 18611 i18 = i3 + 4 | 0;
michael@0 18612 HEAP32[i18 >> 2] = 0;
michael@0 18613 HEAP32[i3 + 8 >> 2] = 0;
michael@0 18614 HEAP8[i3 + 36 | 0] = 1;
michael@0 18615 i15 = i3 + 32 | 0;
michael@0 18616 HEAP32[i15 >> 2] = 0;
michael@0 18617 HEAP32[i3 + 24 >> 2] = 0;
michael@0 18618 HEAP32[i3 + 28 >> 2] = 0;
michael@0 18619 HEAP8[i3 + 56 | 0] = 1;
michael@0 18620 i13 = i3 + 52 | 0;
michael@0 18621 HEAP32[i13 >> 2] = 0;
michael@0 18622 i11 = i3 + 44 | 0;
michael@0 18623 HEAP32[i11 >> 2] = 0;
michael@0 18624 HEAP32[i3 + 48 >> 2] = 0;
michael@0 18625 i20 = i16;
michael@0 18626 +__ZN20btConvexHullComputer7computeEPKvbiiff(i3, i20, 0, 16, i14, 0.0, 0.0);
michael@0 18627 i14 = HEAP32[i11 >> 2] | 0;
michael@0 18628 i11 = (i14 | 0) > 0;
michael@0 18629 if (i11) {
michael@0 18630 i12 = __Z22btAlignedAllocInternalji(i14 << 4, 16) | 0;
michael@0 18631 i21 = i4;
michael@0 18632 i4 = 0;
michael@0 18633 while (1) {
michael@0 18634 i22 = i12 + (i4 << 4) | 0;
michael@0 18635 if ((i22 | 0) != 0) {
michael@0 18636 i23 = i22;
michael@0 18637 HEAP32[i23 >> 2] = HEAP32[i21 >> 2];
michael@0 18638 HEAP32[i23 + 4 >> 2] = HEAP32[i21 + 4 >> 2];
michael@0 18639 HEAP32[i23 + 8 >> 2] = HEAP32[i21 + 8 >> 2];
michael@0 18640 HEAP32[i23 + 12 >> 2] = HEAP32[i21 + 12 >> 2];
michael@0 18641 }
michael@0 18642 i23 = i4 + 1 | 0;
michael@0 18643 if ((i23 | 0) < (i14 | 0)) {
michael@0 18644 i4 = i23;
michael@0 18645 } else {
michael@0 18646 i24 = i12;
michael@0 18647 break;
michael@0 18648 }
michael@0 18649 }
michael@0 18650 } else {
michael@0 18651 i24 = 0;
michael@0 18652 }
michael@0 18653 i12 = HEAP32[i10 >> 2] | 0;
michael@0 18654 _memset(i5 | 0, 0, 56);
michael@0 18655 i4 = i5 + 16 | 0;
michael@0 18656 HEAP8[i4] = 1;
michael@0 18657 i21 = i5 + 12 | 0;
michael@0 18658 HEAP32[i21 >> 2] = 0;
michael@0 18659 i23 = i5 + 4 | 0;
michael@0 18660 HEAP32[i23 >> 2] = 0;
michael@0 18661 i22 = i5 + 8 | 0;
michael@0 18662 HEAP32[i22 >> 2] = 0;
michael@0 18663 i25 = i5 + 36 | 0;
michael@0 18664 HEAP8[i25] = 1;
michael@0 18665 i26 = i5 + 32 | 0;
michael@0 18666 HEAP32[i26 >> 2] = 0;
michael@0 18667 i27 = i5 + 24 | 0;
michael@0 18668 HEAP32[i27 >> 2] = 0;
michael@0 18669 i28 = i5 + 28 | 0;
michael@0 18670 HEAP32[i28 >> 2] = 0;
michael@0 18671 __ZN20btAlignedObjectArrayI6btFaceE6resizeEiRKS0_(i12 + 24 | 0, i14, i5);
michael@0 18672 i5 = HEAP32[i26 >> 2] | 0;
michael@0 18673 if ((i5 | 0) != 0) {
michael@0 18674 if ((HEAP8[i25] | 0) != 0) {
michael@0 18675 __Z21btAlignedFreeInternalPv(i5);
michael@0 18676 }
michael@0 18677 HEAP32[i26 >> 2] = 0;
michael@0 18678 }
michael@0 18679 HEAP8[i25] = 1;
michael@0 18680 HEAP32[i26 >> 2] = 0;
michael@0 18681 HEAP32[i27 >> 2] = 0;
michael@0 18682 HEAP32[i28 >> 2] = 0;
michael@0 18683 i28 = HEAP32[i21 >> 2] | 0;
michael@0 18684 if ((i28 | 0) != 0) {
michael@0 18685 if ((HEAP8[i4] | 0) != 0) {
michael@0 18686 __Z21btAlignedFreeInternalPv(i28);
michael@0 18687 }
michael@0 18688 HEAP32[i21 >> 2] = 0;
michael@0 18689 }
michael@0 18690 HEAP8[i4] = 1;
michael@0 18691 HEAP32[i21 >> 2] = 0;
michael@0 18692 HEAP32[i23 >> 2] = 0;
michael@0 18693 HEAP32[i22 >> 2] = 0;
michael@0 18694 i22 = HEAP32[i18 >> 2] | 0;
michael@0 18695 i23 = HEAP32[i10 >> 2] | 0;
michael@0 18696 i21 = i23 + 8 | 0;
michael@0 18697 i4 = HEAP32[i21 >> 2] | 0;
michael@0 18698 if ((i4 | 0) < (i22 | 0)) {
michael@0 18699 i28 = i23 + 12 | 0;
michael@0 18700 if ((HEAP32[i28 >> 2] | 0) < (i22 | 0)) {
michael@0 18701 if ((i22 | 0) == 0) {
michael@0 18702 i29 = 0;
michael@0 18703 i30 = i4;
michael@0 18704 } else {
michael@0 18705 i27 = __Z22btAlignedAllocInternalji(i22 << 4, 16) | 0;
michael@0 18706 i29 = i27;
michael@0 18707 i30 = HEAP32[i21 >> 2] | 0;
michael@0 18708 }
michael@0 18709 i27 = i23 + 16 | 0;
michael@0 18710 if ((i30 | 0) > 0) {
michael@0 18711 i26 = 0;
michael@0 18712 do {
michael@0 18713 i25 = i29 + (i26 << 4) | 0;
michael@0 18714 if ((i25 | 0) != 0) {
michael@0 18715 i5 = i25;
michael@0 18716 i25 = (HEAP32[i27 >> 2] | 0) + (i26 << 4) | 0;
michael@0 18717 HEAP32[i5 >> 2] = HEAP32[i25 >> 2];
michael@0 18718 HEAP32[i5 + 4 >> 2] = HEAP32[i25 + 4 >> 2];
michael@0 18719 HEAP32[i5 + 8 >> 2] = HEAP32[i25 + 8 >> 2];
michael@0 18720 HEAP32[i5 + 12 >> 2] = HEAP32[i25 + 12 >> 2];
michael@0 18721 }
michael@0 18722 i26 = i26 + 1 | 0;
michael@0 18723 } while ((i26 | 0) < (i30 | 0));
michael@0 18724 }
michael@0 18725 i30 = HEAP32[i27 >> 2] | 0;
michael@0 18726 i26 = i23 + 20 | 0;
michael@0 18727 if ((i30 | 0) != 0) {
michael@0 18728 if ((HEAP8[i26] | 0) != 0) {
michael@0 18729 __Z21btAlignedFreeInternalPv(i30);
michael@0 18730 }
michael@0 18731 HEAP32[i27 >> 2] = 0;
michael@0 18732 }
michael@0 18733 HEAP8[i26] = 1;
michael@0 18734 HEAP32[i27 >> 2] = i29;
michael@0 18735 HEAP32[i28 >> 2] = i22;
michael@0 18736 i31 = i27;
michael@0 18737 } else {
michael@0 18738 i31 = i23 + 16 | 0;
michael@0 18739 }
michael@0 18740 i23 = i6;
michael@0 18741 i6 = i4;
michael@0 18742 do {
michael@0 18743 i4 = (HEAP32[i31 >> 2] | 0) + (i6 << 4) | 0;
michael@0 18744 if ((i4 | 0) != 0) {
michael@0 18745 i27 = i4;
michael@0 18746 HEAP32[i27 >> 2] = HEAP32[i23 >> 2];
michael@0 18747 HEAP32[i27 + 4 >> 2] = HEAP32[i23 + 4 >> 2];
michael@0 18748 HEAP32[i27 + 8 >> 2] = HEAP32[i23 + 8 >> 2];
michael@0 18749 HEAP32[i27 + 12 >> 2] = HEAP32[i23 + 12 >> 2];
michael@0 18750 }
michael@0 18751 i6 = i6 + 1 | 0;
michael@0 18752 } while ((i6 | 0) < (i22 | 0));
michael@0 18753 }
michael@0 18754 HEAP32[i21 >> 2] = i22;
michael@0 18755 if ((i22 | 0) > 0) {
michael@0 18756 i21 = 0;
michael@0 18757 do {
michael@0 18758 i6 = (HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] | 0) + (i21 << 4) | 0;
michael@0 18759 i23 = (HEAP32[i19 >> 2] | 0) + (i21 << 4) | 0;
michael@0 18760 HEAP32[i6 >> 2] = HEAP32[i23 >> 2];
michael@0 18761 HEAP32[i6 + 4 >> 2] = HEAP32[i23 + 4 >> 2];
michael@0 18762 HEAP32[i6 + 8 >> 2] = HEAP32[i23 + 8 >> 2];
michael@0 18763 HEAP32[i6 + 12 >> 2] = HEAP32[i23 + 12 >> 2];
michael@0 18764 i21 = i21 + 1 | 0;
michael@0 18765 } while ((i21 | 0) < (i22 | 0));
michael@0 18766 }
michael@0 18767 if (i11) {
michael@0 18768 i11 = i7 + 4 | 0;
michael@0 18769 i22 = i7 + 24 | 0;
michael@0 18770 i21 = i7 + 8 | 0;
michael@0 18771 i23 = i7 + 20 | 0;
michael@0 18772 i6 = i7 + 16 | 0;
michael@0 18773 i31 = i7 | 0;
michael@0 18774 i27 = 0;
michael@0 18775 while (1) {
michael@0 18776 i4 = (HEAP32[i15 >> 2] | 0) + ((HEAP32[(HEAP32[i13 >> 2] | 0) + (i27 << 2) >> 2] | 0) * 12 | 0) | 0;
michael@0 18777 i28 = i4;
michael@0 18778 i29 = 0;
michael@0 18779 while (1) {
michael@0 18780 i26 = i28 + 4 | 0;
michael@0 18781 i30 = HEAP32[i28 + ((HEAP32[i26 >> 2] | 0) * 12 | 0) + 8 >> 2] | 0;
michael@0 18782 i25 = HEAP32[(HEAP32[i10 >> 2] | 0) + 36 >> 2] | 0;
michael@0 18783 i5 = i25 + (i27 * 56 | 0) + 4 | 0;
michael@0 18784 i12 = HEAP32[i5 >> 2] | 0;
michael@0 18785 i32 = i25 + (i27 * 56 | 0) + 8 | 0;
michael@0 18786 do {
michael@0 18787 if ((i12 | 0) == (HEAP32[i32 >> 2] | 0)) {
michael@0 18788 i33 = (i12 | 0) == 0 ? 1 : i12 << 1;
michael@0 18789 if ((i12 | 0) >= (i33 | 0)) {
michael@0 18790 i34 = i12;
michael@0 18791 break;
michael@0 18792 }
michael@0 18793 if ((i33 | 0) == 0) {
michael@0 18794 i35 = 0;
michael@0 18795 i36 = i12;
michael@0 18796 } else {
michael@0 18797 i37 = __Z22btAlignedAllocInternalji(i33 << 2, 16) | 0;
michael@0 18798 i35 = i37;
michael@0 18799 i36 = HEAP32[i5 >> 2] | 0;
michael@0 18800 }
michael@0 18801 i37 = i25 + (i27 * 56 | 0) + 12 | 0;
michael@0 18802 if ((i36 | 0) > 0) {
michael@0 18803 i38 = 0;
michael@0 18804 do {
michael@0 18805 i39 = i35 + (i38 << 2) | 0;
michael@0 18806 if ((i39 | 0) != 0) {
michael@0 18807 HEAP32[i39 >> 2] = HEAP32[(HEAP32[i37 >> 2] | 0) + (i38 << 2) >> 2];
michael@0 18808 }
michael@0 18809 i38 = i38 + 1 | 0;
michael@0 18810 } while ((i38 | 0) < (i36 | 0));
michael@0 18811 }
michael@0 18812 i38 = HEAP32[i37 >> 2] | 0;
michael@0 18813 i39 = i25 + (i27 * 56 | 0) + 16 | 0;
michael@0 18814 if ((i38 | 0) != 0) {
michael@0 18815 if ((HEAP8[i39] | 0) != 0) {
michael@0 18816 __Z21btAlignedFreeInternalPv(i38);
michael@0 18817 }
michael@0 18818 HEAP32[i37 >> 2] = 0;
michael@0 18819 }
michael@0 18820 HEAP8[i39] = 1;
michael@0 18821 HEAP32[i37 >> 2] = i35;
michael@0 18822 HEAP32[i32 >> 2] = i33;
michael@0 18823 i34 = HEAP32[i5 >> 2] | 0;
michael@0 18824 } else {
michael@0 18825 i34 = i12;
michael@0 18826 }
michael@0 18827 } while (0);
michael@0 18828 i12 = (HEAP32[i25 + (i27 * 56 | 0) + 12 >> 2] | 0) + (i34 << 2) | 0;
michael@0 18829 if ((i12 | 0) == 0) {
michael@0 18830 i40 = i34;
michael@0 18831 } else {
michael@0 18832 HEAP32[i12 >> 2] = i30;
michael@0 18833 i40 = HEAP32[i5 >> 2] | 0;
michael@0 18834 }
michael@0 18835 HEAP32[i5 >> 2] = i40 + 1;
michael@0 18836 i12 = HEAP32[i28 + 8 >> 2] | 0;
michael@0 18837 i32 = HEAP32[i19 >> 2] | 0;
michael@0 18838 d41 = +HEAPF32[i32 + (i12 << 4) >> 2] - +HEAPF32[i32 + (i30 << 4) >> 2];
michael@0 18839 d42 = +HEAPF32[i32 + (i12 << 4) + 4 >> 2] - +HEAPF32[i32 + (i30 << 4) + 4 >> 2];
michael@0 18840 d43 = +HEAPF32[i32 + (i12 << 4) + 8 >> 2] - +HEAPF32[i32 + (i30 << 4) + 8 >> 2];
michael@0 18841 d44 = 1.0 / +Math_sqrt(+(d41 * d41 + d42 * d42 + d43 * d43));
michael@0 18842 if ((i29 | 0) < 2) {
michael@0 18843 HEAPF32[i7 + (i29 << 4) >> 2] = d41 * d44;
michael@0 18844 HEAPF32[i7 + (i29 << 4) + 4 >> 2] = d42 * d44;
michael@0 18845 HEAPF32[i7 + (i29 << 4) + 8 >> 2] = d43 * d44;
michael@0 18846 HEAPF32[i7 + (i29 << 4) + 12 >> 2] = 0.0;
michael@0 18847 i45 = i29 + 1 | 0;
michael@0 18848 } else {
michael@0 18849 i45 = i29;
michael@0 18850 }
michael@0 18851 i32 = HEAP32[i26 >> 2] | 0;
michael@0 18852 i12 = i28 + (((HEAP32[i28 + (i32 * 12 | 0) >> 2] | 0) + i32 | 0) * 12 | 0) | 0;
michael@0 18853 if ((i12 | 0) == (i4 | 0)) {
michael@0 18854 break;
michael@0 18855 } else {
michael@0 18856 i28 = i12;
michael@0 18857 i29 = i45;
michael@0 18858 }
michael@0 18859 }
michael@0 18860 i29 = i24 + (i27 << 4) | 0;
michael@0 18861 if ((i45 | 0) == 2) {
michael@0 18862 d44 = +HEAPF32[i11 >> 2];
michael@0 18863 d43 = +HEAPF32[i22 >> 2];
michael@0 18864 d42 = +HEAPF32[i21 >> 2];
michael@0 18865 d41 = +HEAPF32[i23 >> 2];
michael@0 18866 d46 = d44 * d43 - d42 * d41;
michael@0 18867 d47 = +HEAPF32[i6 >> 2];
michael@0 18868 d48 = +HEAPF32[i31 >> 2];
michael@0 18869 d49 = d42 * d47 - d43 * d48;
michael@0 18870 d43 = d41 * d48 - d44 * d47;
michael@0 18871 i28 = i24 + (i27 << 4) + 4 | 0;
michael@0 18872 i4 = i24 + (i27 << 4) + 8 | 0;
michael@0 18873 HEAPF32[i24 + (i27 << 4) + 12 >> 2] = 0.0;
michael@0 18874 d47 = 1.0 / +Math_sqrt(+(d43 * d43 + (d46 * d46 + d49 * d49)));
michael@0 18875 d44 = d46 * d47;
michael@0 18876 HEAPF32[i29 >> 2] = d44;
michael@0 18877 HEAPF32[i28 >> 2] = d49 * d47;
michael@0 18878 HEAPF32[i4 >> 2] = d43 * d47;
michael@0 18879 i12 = HEAP32[i10 >> 2] | 0;
michael@0 18880 i32 = HEAP32[i12 + 36 >> 2] | 0;
michael@0 18881 HEAPF32[i32 + (i27 * 56 | 0) + 40 >> 2] = -0.0 - d44;
michael@0 18882 HEAPF32[i32 + (i27 * 56 | 0) + 44 >> 2] = -0.0 - +HEAPF32[i28 >> 2];
michael@0 18883 HEAPF32[i32 + (i27 * 56 | 0) + 48 >> 2] = -0.0 - +HEAPF32[i4 >> 2];
michael@0 18884 HEAPF32[i32 + (i27 * 56 | 0) + 52 >> 2] = 1.0000000150474662e+30;
michael@0 18885 i50 = i12;
michael@0 18886 i51 = i32;
michael@0 18887 } else {
michael@0 18888 _memset(i29 | 0, 0, 16);
michael@0 18889 i32 = HEAP32[i10 >> 2] | 0;
michael@0 18890 i50 = i32;
michael@0 18891 i51 = HEAP32[i32 + 36 >> 2] | 0;
michael@0 18892 }
michael@0 18893 i32 = HEAP32[i51 + (i27 * 56 | 0) + 4 >> 2] | 0;
michael@0 18894 if ((i32 | 0) > 0) {
michael@0 18895 d44 = +HEAPF32[i29 >> 2];
michael@0 18896 d47 = +HEAPF32[i24 + (i27 << 4) + 4 >> 2];
michael@0 18897 d43 = +HEAPF32[i24 + (i27 << 4) + 8 >> 2];
michael@0 18898 i29 = HEAP32[i51 + (i27 * 56 | 0) + 12 >> 2] | 0;
michael@0 18899 i12 = HEAP32[i50 + 16 >> 2] | 0;
michael@0 18900 d49 = 1.0000000150474662e+30;
michael@0 18901 i4 = 0;
michael@0 18902 while (1) {
michael@0 18903 i28 = HEAP32[i29 + (i4 << 2) >> 2] | 0;
michael@0 18904 d46 = d44 * +HEAPF32[i12 + (i28 << 4) >> 2] + d47 * +HEAPF32[i12 + (i28 << 4) + 4 >> 2] + d43 * +HEAPF32[i12 + (i28 << 4) + 8 >> 2];
michael@0 18905 d48 = d49 > d46 ? d46 : d49;
michael@0 18906 i28 = i4 + 1 | 0;
michael@0 18907 if ((i28 | 0) < (i32 | 0)) {
michael@0 18908 d49 = d48;
michael@0 18909 i4 = i28;
michael@0 18910 } else {
michael@0 18911 d52 = d48;
michael@0 18912 break;
michael@0 18913 }
michael@0 18914 }
michael@0 18915 } else {
michael@0 18916 d52 = 1.0000000150474662e+30;
michael@0 18917 }
michael@0 18918 HEAPF32[i51 + (i27 * 56 | 0) + 52 >> 2] = d52;
michael@0 18919 i4 = i27 + 1 | 0;
michael@0 18920 if ((i4 | 0) < (i14 | 0)) {
michael@0 18921 i27 = i4;
michael@0 18922 } else {
michael@0 18923 i53 = i50;
michael@0 18924 break;
michael@0 18925 }
michael@0 18926 }
michael@0 18927 } else {
michael@0 18928 i53 = HEAP32[i10 >> 2] | 0;
michael@0 18929 }
michael@0 18930 i50 = HEAP32[i53 + 28 >> 2] | 0;
michael@0 18931 do {
michael@0 18932 if ((i50 | 0) == 0) {
michael@0 18933 i54 = i53;
michael@0 18934 } else {
michael@0 18935 if (!((HEAP32[i18 >> 2] | 0) != 0 & (i50 | 0) > 0)) {
michael@0 18936 i54 = i53;
michael@0 18937 break;
michael@0 18938 }
michael@0 18939 i27 = i1;
michael@0 18940 i14 = i9 | 0;
michael@0 18941 i51 = i9 + 4 | 0;
michael@0 18942 i31 = i9 + 8 | 0;
michael@0 18943 i6 = i9 + 12 | 0;
michael@0 18944 i23 = i1 | 0;
michael@0 18945 i21 = i8 | 0;
michael@0 18946 i22 = i8 + 4 | 0;
michael@0 18947 i11 = i8 + 8 | 0;
michael@0 18948 i45 = 0;
michael@0 18949 i7 = i53;
michael@0 18950 while (1) {
michael@0 18951 i19 = HEAP32[i7 + 36 >> 2] | 0;
michael@0 18952 d52 = +HEAPF32[i19 + (i45 * 56 | 0) + 40 >> 2];
michael@0 18953 d49 = +HEAPF32[i19 + (i45 * 56 | 0) + 44 >> 2];
michael@0 18954 d43 = +HEAPF32[i19 + (i45 * 56 | 0) + 48 >> 2];
michael@0 18955 d47 = +HEAPF32[i19 + (i45 * 56 | 0) + 52 >> 2];
michael@0 18956 i19 = HEAP32[(HEAP32[i27 >> 2] | 0) + 60 >> 2] | 0;
michael@0 18957 HEAPF32[i14 >> 2] = -0.0 - d52;
michael@0 18958 HEAPF32[i51 >> 2] = -0.0 - d49;
michael@0 18959 HEAPF32[i31 >> 2] = -0.0 - d43;
michael@0 18960 HEAPF32[i6 >> 2] = 0.0;
michael@0 18961 FUNCTION_TABLE_viii[i19 & 127](i8, i23, i9);
michael@0 18962 i19 = HEAP32[i10 >> 2] | 0;
michael@0 18963 do {
michael@0 18964 if (d52 * +HEAPF32[i21 >> 2] + d49 * +HEAPF32[i22 >> 2] + d43 * +HEAPF32[i11 >> 2] < d47) {
michael@0 18965 i40 = HEAP32[i19 + 36 >> 2] | 0;
michael@0 18966 i34 = i40 + (i45 * 56 | 0) + 40 | 0;
michael@0 18967 HEAPF32[i34 >> 2] = +HEAPF32[i34 >> 2] * -1.0;
michael@0 18968 i34 = i40 + (i45 * 56 | 0) + 44 | 0;
michael@0 18969 HEAPF32[i34 >> 2] = +HEAPF32[i34 >> 2] * -1.0;
michael@0 18970 i34 = i40 + (i45 * 56 | 0) + 48 | 0;
michael@0 18971 HEAPF32[i34 >> 2] = +HEAPF32[i34 >> 2] * -1.0;
michael@0 18972 i34 = i40 + (i45 * 56 | 0) + 52 | 0;
michael@0 18973 HEAPF32[i34 >> 2] = +HEAPF32[i34 >> 2] * -1.0;
michael@0 18974 i34 = HEAP32[i40 + (i45 * 56 | 0) + 4 >> 2] | 0;
michael@0 18975 i35 = (i34 | 0) / 2 | 0;
michael@0 18976 if ((i34 | 0) <= 1) {
michael@0 18977 break;
michael@0 18978 }
michael@0 18979 i36 = HEAP32[i40 + (i45 * 56 | 0) + 12 >> 2] | 0;
michael@0 18980 i40 = i34 - 1 | 0;
michael@0 18981 i34 = 0;
michael@0 18982 do {
michael@0 18983 i13 = i36 + (i34 << 2) | 0;
michael@0 18984 i15 = i36 + (i40 - i34 << 2) | 0;
michael@0 18985 i4 = HEAP32[i13 >> 2] | 0;
michael@0 18986 HEAP32[i13 >> 2] = HEAP32[i15 >> 2];
michael@0 18987 HEAP32[i15 >> 2] = i4;
michael@0 18988 i34 = i34 + 1 | 0;
michael@0 18989 } while ((i34 | 0) < (i35 | 0));
michael@0 18990 }
michael@0 18991 } while (0);
michael@0 18992 i26 = i45 + 1 | 0;
michael@0 18993 if ((i26 | 0) < (HEAP32[i19 + 28 >> 2] | 0)) {
michael@0 18994 i45 = i26;
michael@0 18995 i7 = i19;
michael@0 18996 } else {
michael@0 18997 i54 = i19;
michael@0 18998 break;
michael@0 18999 }
michael@0 19000 }
michael@0 19001 }
michael@0 19002 } while (0);
michael@0 19003 __ZN18btConvexPolyhedron10initializeEv(i54);
michael@0 19004 if ((i24 | 0) != 0) {
michael@0 19005 __Z21btAlignedFreeInternalPv(i24);
michael@0 19006 }
michael@0 19007 __ZN20btConvexHullComputerD2Ev(i3);
michael@0 19008 if ((i16 | 0) == 0) {
michael@0 19009 STACKTOP = i2;
michael@0 19010 return 1;
michael@0 19011 }
michael@0 19012 __Z21btAlignedFreeInternalPv(i20);
michael@0 19013 STACKTOP = i2;
michael@0 19014 return 1;
michael@0 19015 }
michael@0 19016 function __ZN18btConvexPolyhedron10initializeEv(i1) {
michael@0 19017 i1 = i1 | 0;
michael@0 19018 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, d68 = 0.0, d69 = 0.0, d70 = 0.0, d71 = 0.0, d72 = 0.0, d73 = 0.0, d74 = 0.0, d75 = 0.0, d76 = 0.0, d77 = 0.0, d78 = 0.0, d79 = 0.0, d80 = 0.0, d81 = 0.0, d82 = 0.0, d83 = 0.0, d84 = 0.0;
michael@0 19019 i2 = STACKTOP;
michael@0 19020 STACKTOP = STACKTOP + 96 | 0;
michael@0 19021 i3 = i2 | 0;
michael@0 19022 i4 = i2 + 80 | 0;
michael@0 19023 i5 = i2 + 88 | 0;
michael@0 19024 HEAP8[i3 + 16 | 0] = 1;
michael@0 19025 i6 = i3 + 12 | 0;
michael@0 19026 HEAP32[i6 >> 2] = 0;
michael@0 19027 i7 = i3 + 4 | 0;
michael@0 19028 HEAP32[i7 >> 2] = 0;
michael@0 19029 HEAP32[i3 + 8 >> 2] = 0;
michael@0 19030 HEAP8[i3 + 36 | 0] = 1;
michael@0 19031 i8 = i3 + 32 | 0;
michael@0 19032 HEAP32[i8 >> 2] = 0;
michael@0 19033 HEAP32[i3 + 24 >> 2] = 0;
michael@0 19034 HEAP32[i3 + 28 >> 2] = 0;
michael@0 19035 HEAP8[i3 + 56 | 0] = 1;
michael@0 19036 i9 = i3 + 52 | 0;
michael@0 19037 HEAP32[i9 >> 2] = 0;
michael@0 19038 HEAP32[i3 + 44 >> 2] = 0;
michael@0 19039 i10 = i3 + 48 | 0;
michael@0 19040 HEAP32[i10 >> 2] = 0;
michael@0 19041 HEAP8[i3 + 76 | 0] = 1;
michael@0 19042 i11 = i3 + 72 | 0;
michael@0 19043 HEAP32[i11 >> 2] = 0;
michael@0 19044 HEAP32[i3 + 64 >> 2] = 0;
michael@0 19045 HEAP32[i3 + 68 >> 2] = 0;
michael@0 19046 i12 = i1 + 64 | 0;
michael@0 19047 i13 = i1 + 68 | 0;
michael@0 19048 i14 = i1 + 72 | 0;
michael@0 19049 i15 = i1 + 28 | 0;
michael@0 19050 _memset(i12 | 0, 0, 16);
michael@0 19051 i16 = HEAP32[i15 >> 2] | 0;
michael@0 19052 if ((i16 | 0) <= 0) {
michael@0 19053 d17 = 0.0;
michael@0 19054 d18 = 1.0 / d17;
michael@0 19055 d19 = +HEAPF32[i12 >> 2];
michael@0 19056 d20 = d18 * d19;
michael@0 19057 HEAPF32[i12 >> 2] = d20;
michael@0 19058 d21 = +HEAPF32[i13 >> 2];
michael@0 19059 d22 = d18 * d21;
michael@0 19060 HEAPF32[i13 >> 2] = d22;
michael@0 19061 d23 = +HEAPF32[i14 >> 2];
michael@0 19062 d24 = d18 * d23;
michael@0 19063 HEAPF32[i14 >> 2] = d24;
michael@0 19064 __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeED2Ev(i3);
michael@0 19065 STACKTOP = i2;
michael@0 19066 return;
michael@0 19067 }
michael@0 19068 i25 = i1 + 36 | 0;
michael@0 19069 i26 = i4 | 0;
michael@0 19070 i27 = i4 + 2 | 0;
michael@0 19071 i28 = i1 + 16 | 0;
michael@0 19072 i29 = i1 + 48 | 0;
michael@0 19073 i30 = i5 | 0;
michael@0 19074 i31 = i5 + 2 | 0;
michael@0 19075 i32 = i1 + 52 | 0;
michael@0 19076 i33 = i1 + 56 | 0;
michael@0 19077 i34 = i1 + 60 | 0;
michael@0 19078 i1 = 0;
michael@0 19079 i35 = i16;
michael@0 19080 while (1) {
michael@0 19081 i16 = HEAP32[i25 >> 2] | 0;
michael@0 19082 i36 = HEAP32[i16 + (i1 * 56 | 0) + 4 >> 2] | 0;
michael@0 19083 if ((i36 | 0) > 0) {
michael@0 19084 i37 = i1 & 65535;
michael@0 19085 i38 = 0;
michael@0 19086 i39 = i16;
michael@0 19087 while (1) {
michael@0 19088 i16 = i38 + 1 | 0;
michael@0 19089 i40 = HEAP32[i39 + (i1 * 56 | 0) + 12 >> 2] | 0;
michael@0 19090 i41 = HEAP32[i40 + (i38 << 2) >> 2] & 65535;
michael@0 19091 i42 = HEAP32[i40 + (((i16 | 0) == (i36 | 0) ? 0 : i16) << 2) >> 2] & 65535;
michael@0 19092 HEAP16[i26 >> 1] = i41;
michael@0 19093 HEAP16[i27 >> 1] = i42;
michael@0 19094 if (i41 << 16 >> 16 < i42 << 16 >> 16) {
michael@0 19095 HEAP16[i26 >> 1] = i42;
michael@0 19096 HEAP16[i27 >> 1] = i41;
michael@0 19097 i43 = i42;
michael@0 19098 i44 = i41;
michael@0 19099 } else {
michael@0 19100 i43 = i41;
michael@0 19101 i44 = i42;
michael@0 19102 }
michael@0 19103 i42 = i43 << 16 >> 16;
michael@0 19104 i41 = ((i44 & 65535) << 16) + i42 & (HEAP32[i10 >> 2] | 0) - 1;
michael@0 19105 L1973 : do {
michael@0 19106 if (i41 >>> 0 < (HEAP32[i7 >> 2] | 0) >>> 0) {
michael@0 19107 i40 = HEAP32[(HEAP32[i6 >> 2] | 0) + (i41 << 2) >> 2] | 0;
michael@0 19108 if ((i40 | 0) == -1) {
michael@0 19109 i45 = 0;
michael@0 19110 break;
michael@0 19111 }
michael@0 19112 i46 = HEAP32[i11 >> 2] | 0;
michael@0 19113 i47 = HEAP32[i8 >> 2] | 0;
michael@0 19114 i48 = i40;
michael@0 19115 while (1) {
michael@0 19116 if (i43 << 16 >> 16 == (HEAP16[i46 + (i48 << 2) >> 1] | 0)) {
michael@0 19117 if (i44 << 16 >> 16 == (HEAP16[i46 + (i48 << 2) + 2 >> 1] | 0)) {
michael@0 19118 break;
michael@0 19119 }
michael@0 19120 }
michael@0 19121 i40 = HEAP32[i47 + (i48 << 2) >> 2] | 0;
michael@0 19122 if ((i40 | 0) == -1) {
michael@0 19123 i45 = 0;
michael@0 19124 break L1973;
michael@0 19125 } else {
michael@0 19126 i48 = i40;
michael@0 19127 }
michael@0 19128 }
michael@0 19129 if ((i48 | 0) == -1) {
michael@0 19130 i45 = 0;
michael@0 19131 break;
michael@0 19132 }
michael@0 19133 i45 = (HEAP32[i9 >> 2] | 0) + (i48 << 2) | 0;
michael@0 19134 } else {
michael@0 19135 i45 = 0;
michael@0 19136 }
michael@0 19137 } while (0);
michael@0 19138 i41 = i44 << 16 >> 16;
michael@0 19139 i47 = HEAP32[i28 >> 2] | 0;
michael@0 19140 d49 = +HEAPF32[i47 + (i41 << 4) >> 2] - +HEAPF32[i47 + (i42 << 4) >> 2];
michael@0 19141 d50 = +HEAPF32[i47 + (i41 << 4) + 4 >> 2] - +HEAPF32[i47 + (i42 << 4) + 4 >> 2];
michael@0 19142 d51 = +HEAPF32[i47 + (i41 << 4) + 8 >> 2] - +HEAPF32[i47 + (i42 << 4) + 8 >> 2];
michael@0 19143 d52 = 1.0 / +Math_sqrt(+(d49 * d49 + d50 * d50 + d51 * d51));
michael@0 19144 d53 = d49 * d52;
michael@0 19145 d49 = d50 * d52;
michael@0 19146 d50 = d51 * d52;
michael@0 19147 i47 = HEAP32[i29 >> 2] | 0;
michael@0 19148 L1984 : do {
michael@0 19149 if ((i47 | 0) > 0) {
michael@0 19150 i41 = HEAP32[i33 >> 2] | 0;
michael@0 19151 i46 = 0;
michael@0 19152 while (1) {
michael@0 19153 d52 = +HEAPF32[i41 + (i46 << 4) >> 2];
michael@0 19154 d51 = +HEAPF32[i41 + (i46 << 4) + 8 >> 2];
michael@0 19155 d54 = d51 - d50;
michael@0 19156 do {
michael@0 19157 if (+Math_abs(+(d52 - d53)) <= 1.0e-6) {
michael@0 19158 if (+Math_abs(+(+HEAPF32[i41 + (i46 << 4) + 4 >> 2] - d49)) > 1.0e-6) {
michael@0 19159 break;
michael@0 19160 }
michael@0 19161 if (+Math_abs(+d54) <= 1.0e-6) {
michael@0 19162 break L1984;
michael@0 19163 }
michael@0 19164 }
michael@0 19165 } while (0);
michael@0 19166 d54 = d50 + d51;
michael@0 19167 do {
michael@0 19168 if (+Math_abs(+(d53 + d52)) <= 1.0e-6) {
michael@0 19169 if (+Math_abs(+(d49 + +HEAPF32[i41 + (i46 << 4) + 4 >> 2])) > 1.0e-6) {
michael@0 19170 break;
michael@0 19171 }
michael@0 19172 if (+Math_abs(+d54) <= 1.0e-6) {
michael@0 19173 break L1984;
michael@0 19174 }
michael@0 19175 }
michael@0 19176 } while (0);
michael@0 19177 i40 = i46 + 1 | 0;
michael@0 19178 if ((i40 | 0) < (i47 | 0)) {
michael@0 19179 i46 = i40;
michael@0 19180 } else {
michael@0 19181 i55 = 1714;
michael@0 19182 break;
michael@0 19183 }
michael@0 19184 }
michael@0 19185 } else {
michael@0 19186 i55 = 1714;
michael@0 19187 }
michael@0 19188 } while (0);
michael@0 19189 if ((i55 | 0) == 1714) {
michael@0 19190 i55 = 0;
michael@0 19191 do {
michael@0 19192 if ((i47 | 0) == (HEAP32[i32 >> 2] | 0)) {
michael@0 19193 i42 = (i47 | 0) == 0 ? 1 : i47 << 1;
michael@0 19194 if ((i47 | 0) >= (i42 | 0)) {
michael@0 19195 i56 = i47;
michael@0 19196 break;
michael@0 19197 }
michael@0 19198 if ((i42 | 0) == 0) {
michael@0 19199 i57 = 0;
michael@0 19200 i58 = i47;
michael@0 19201 } else {
michael@0 19202 i46 = __Z22btAlignedAllocInternalji(i42 << 4, 16) | 0;
michael@0 19203 i57 = i46;
michael@0 19204 i58 = HEAP32[i29 >> 2] | 0;
michael@0 19205 }
michael@0 19206 if ((i58 | 0) > 0) {
michael@0 19207 i46 = 0;
michael@0 19208 do {
michael@0 19209 i41 = i57 + (i46 << 4) | 0;
michael@0 19210 if ((i41 | 0) != 0) {
michael@0 19211 i48 = i41;
michael@0 19212 i41 = (HEAP32[i33 >> 2] | 0) + (i46 << 4) | 0;
michael@0 19213 HEAP32[i48 >> 2] = HEAP32[i41 >> 2];
michael@0 19214 HEAP32[i48 + 4 >> 2] = HEAP32[i41 + 4 >> 2];
michael@0 19215 HEAP32[i48 + 8 >> 2] = HEAP32[i41 + 8 >> 2];
michael@0 19216 HEAP32[i48 + 12 >> 2] = HEAP32[i41 + 12 >> 2];
michael@0 19217 }
michael@0 19218 i46 = i46 + 1 | 0;
michael@0 19219 } while ((i46 | 0) < (i58 | 0));
michael@0 19220 }
michael@0 19221 i46 = HEAP32[i33 >> 2] | 0;
michael@0 19222 if ((i46 | 0) != 0) {
michael@0 19223 if ((HEAP8[i34] | 0) != 0) {
michael@0 19224 __Z21btAlignedFreeInternalPv(i46);
michael@0 19225 }
michael@0 19226 HEAP32[i33 >> 2] = 0;
michael@0 19227 }
michael@0 19228 HEAP8[i34] = 1;
michael@0 19229 HEAP32[i33 >> 2] = i57;
michael@0 19230 HEAP32[i32 >> 2] = i42;
michael@0 19231 i56 = HEAP32[i29 >> 2] | 0;
michael@0 19232 } else {
michael@0 19233 i56 = i47;
michael@0 19234 }
michael@0 19235 } while (0);
michael@0 19236 i47 = HEAP32[i33 >> 2] | 0;
michael@0 19237 i46 = i47 + (i56 << 4) | 0;
michael@0 19238 if ((i46 | 0) == 0) {
michael@0 19239 i59 = i56;
michael@0 19240 } else {
michael@0 19241 HEAPF32[i46 >> 2] = d53;
michael@0 19242 HEAPF32[i47 + (i56 << 4) + 4 >> 2] = d49;
michael@0 19243 HEAPF32[i47 + (i56 << 4) + 8 >> 2] = d50;
michael@0 19244 HEAPF32[i47 + (i56 << 4) + 12 >> 2] = 0.0;
michael@0 19245 i59 = HEAP32[i29 >> 2] | 0;
michael@0 19246 }
michael@0 19247 HEAP32[i29 >> 2] = i59 + 1;
michael@0 19248 }
michael@0 19249 if ((i45 | 0) == 0) {
michael@0 19250 HEAP16[i31 >> 1] = -1;
michael@0 19251 HEAP16[i30 >> 1] = i37;
michael@0 19252 __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeE6insertERKS0_RKS1_(i3, i4, i5);
michael@0 19253 } else {
michael@0 19254 HEAP16[i45 + 2 >> 1] = i37;
michael@0 19255 }
michael@0 19256 if ((i16 | 0) >= (i36 | 0)) {
michael@0 19257 break;
michael@0 19258 }
michael@0 19259 i38 = i16;
michael@0 19260 i39 = HEAP32[i25 >> 2] | 0;
michael@0 19261 }
michael@0 19262 i60 = HEAP32[i15 >> 2] | 0;
michael@0 19263 } else {
michael@0 19264 i60 = i35;
michael@0 19265 }
michael@0 19266 i39 = i1 + 1 | 0;
michael@0 19267 if ((i39 | 0) < (i60 | 0)) {
michael@0 19268 i1 = i39;
michael@0 19269 i35 = i60;
michael@0 19270 } else {
michael@0 19271 break;
michael@0 19272 }
michael@0 19273 }
michael@0 19274 if ((i60 | 0) <= 0) {
michael@0 19275 d17 = 0.0;
michael@0 19276 d18 = 1.0 / d17;
michael@0 19277 d19 = +HEAPF32[i12 >> 2];
michael@0 19278 d20 = d18 * d19;
michael@0 19279 HEAPF32[i12 >> 2] = d20;
michael@0 19280 d21 = +HEAPF32[i13 >> 2];
michael@0 19281 d22 = d18 * d21;
michael@0 19282 HEAPF32[i13 >> 2] = d22;
michael@0 19283 d23 = +HEAPF32[i14 >> 2];
michael@0 19284 d24 = d18 * d23;
michael@0 19285 HEAPF32[i14 >> 2] = d24;
michael@0 19286 __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeED2Ev(i3);
michael@0 19287 STACKTOP = i2;
michael@0 19288 return;
michael@0 19289 }
michael@0 19290 i60 = (HEAP32[i10 >> 2] | 0) - 1 | 0;
michael@0 19291 i10 = HEAP32[i7 >> 2] | 0;
michael@0 19292 i7 = HEAP32[i6 >> 2] | 0;
michael@0 19293 i6 = HEAP32[i11 >> 2] | 0;
michael@0 19294 i11 = HEAP32[i8 >> 2] | 0;
michael@0 19295 i8 = HEAP32[i9 >> 2] | 0;
michael@0 19296 i9 = 0;
michael@0 19297 do {
michael@0 19298 i35 = HEAP32[i25 >> 2] | 0;
michael@0 19299 i1 = HEAP32[i35 + (i9 * 56 | 0) + 4 >> 2] | 0;
michael@0 19300 i45 = i35 + (i9 * 56 | 0) + 24 | 0;
michael@0 19301 i5 = HEAP32[i45 >> 2] | 0;
michael@0 19302 if ((i5 | 0) < (i1 | 0)) {
michael@0 19303 i4 = i35 + (i9 * 56 | 0) + 28 | 0;
michael@0 19304 if ((HEAP32[i4 >> 2] | 0) < (i1 | 0)) {
michael@0 19305 if ((i1 | 0) == 0) {
michael@0 19306 i61 = 0;
michael@0 19307 i62 = i5;
michael@0 19308 } else {
michael@0 19309 i30 = __Z22btAlignedAllocInternalji(i1 << 2, 16) | 0;
michael@0 19310 i61 = i30;
michael@0 19311 i62 = HEAP32[i45 >> 2] | 0;
michael@0 19312 }
michael@0 19313 i30 = i35 + (i9 * 56 | 0) + 32 | 0;
michael@0 19314 if ((i62 | 0) > 0) {
michael@0 19315 i31 = 0;
michael@0 19316 do {
michael@0 19317 i59 = i61 + (i31 << 2) | 0;
michael@0 19318 if ((i59 | 0) != 0) {
michael@0 19319 HEAP32[i59 >> 2] = HEAP32[(HEAP32[i30 >> 2] | 0) + (i31 << 2) >> 2];
michael@0 19320 }
michael@0 19321 i31 = i31 + 1 | 0;
michael@0 19322 } while ((i31 | 0) < (i62 | 0));
michael@0 19323 }
michael@0 19324 i31 = HEAP32[i30 >> 2] | 0;
michael@0 19325 i59 = i35 + (i9 * 56 | 0) + 36 | 0;
michael@0 19326 if ((i31 | 0) != 0) {
michael@0 19327 if ((HEAP8[i59] | 0) != 0) {
michael@0 19328 __Z21btAlignedFreeInternalPv(i31);
michael@0 19329 }
michael@0 19330 HEAP32[i30 >> 2] = 0;
michael@0 19331 }
michael@0 19332 HEAP8[i59] = 1;
michael@0 19333 HEAP32[i30 >> 2] = i61;
michael@0 19334 HEAP32[i4 >> 2] = i1;
michael@0 19335 i63 = i61;
michael@0 19336 } else {
michael@0 19337 i63 = HEAP32[i35 + (i9 * 56 | 0) + 32 >> 2] | 0;
michael@0 19338 }
michael@0 19339 i59 = i5;
michael@0 19340 do {
michael@0 19341 i31 = i63 + (i59 << 2) | 0;
michael@0 19342 if ((i31 | 0) != 0) {
michael@0 19343 HEAP32[i31 >> 2] = 0;
michael@0 19344 }
michael@0 19345 i59 = i59 + 1 | 0;
michael@0 19346 } while ((i59 | 0) < (i1 | 0));
michael@0 19347 }
michael@0 19348 HEAP32[i45 >> 2] = i1;
michael@0 19349 if ((i1 | 0) > 0) {
michael@0 19350 i59 = HEAP32[i25 >> 2] | 0;
michael@0 19351 i5 = HEAP32[i59 + (i9 * 56 | 0) + 12 >> 2] | 0;
michael@0 19352 i35 = i59 + (i9 * 56 | 0) + 32 | 0;
michael@0 19353 i59 = 0;
michael@0 19354 while (1) {
michael@0 19355 i4 = i59 + 1 | 0;
michael@0 19356 i30 = HEAP32[i5 + (i59 << 2) >> 2] & 65535;
michael@0 19357 i31 = HEAP32[i5 + (((i4 | 0) == (i1 | 0) ? 0 : i4) << 2) >> 2] & 65535;
michael@0 19358 i29 = i30 << 16 >> 16 < i31 << 16 >> 16;
michael@0 19359 i56 = i29 ? i30 : i31;
michael@0 19360 i33 = i29 ? i31 : i30;
michael@0 19361 i30 = ((i56 & 65535) << 16) + (i33 << 16 >> 16) & i60;
michael@0 19362 L2069 : do {
michael@0 19363 if (i30 >>> 0 < i10 >>> 0) {
michael@0 19364 i31 = HEAP32[i7 + (i30 << 2) >> 2] | 0;
michael@0 19365 if ((i31 | 0) == -1) {
michael@0 19366 i64 = 0;
michael@0 19367 break;
michael@0 19368 } else {
michael@0 19369 i65 = i31;
michael@0 19370 }
michael@0 19371 while (1) {
michael@0 19372 if (i33 << 16 >> 16 == (HEAP16[i6 + (i65 << 2) >> 1] | 0)) {
michael@0 19373 if (i56 << 16 >> 16 == (HEAP16[i6 + (i65 << 2) + 2 >> 1] | 0)) {
michael@0 19374 break;
michael@0 19375 }
michael@0 19376 }
michael@0 19377 i31 = HEAP32[i11 + (i65 << 2) >> 2] | 0;
michael@0 19378 if ((i31 | 0) == -1) {
michael@0 19379 i64 = 0;
michael@0 19380 break L2069;
michael@0 19381 } else {
michael@0 19382 i65 = i31;
michael@0 19383 }
michael@0 19384 }
michael@0 19385 if ((i65 | 0) == -1) {
michael@0 19386 i64 = 0;
michael@0 19387 break;
michael@0 19388 }
michael@0 19389 i64 = i8 + (i65 << 2) | 0;
michael@0 19390 } else {
michael@0 19391 i64 = 0;
michael@0 19392 }
michael@0 19393 } while (0);
michael@0 19394 i56 = HEAP16[i64 >> 1] | 0;
michael@0 19395 if ((i56 << 16 >> 16 | 0) == (i9 | 0)) {
michael@0 19396 i66 = HEAP16[i64 + 2 >> 1] | 0;
michael@0 19397 } else {
michael@0 19398 i66 = i56;
michael@0 19399 }
michael@0 19400 HEAP32[(HEAP32[i35 >> 2] | 0) + (i59 << 2) >> 2] = i66 << 16 >> 16;
michael@0 19401 if ((i4 | 0) < (i1 | 0)) {
michael@0 19402 i59 = i4;
michael@0 19403 } else {
michael@0 19404 break;
michael@0 19405 }
michael@0 19406 }
michael@0 19407 }
michael@0 19408 i9 = i9 + 1 | 0;
michael@0 19409 i67 = HEAP32[i15 >> 2] | 0;
michael@0 19410 } while ((i9 | 0) < (i67 | 0));
michael@0 19411 if ((i67 | 0) <= 0) {
michael@0 19412 d17 = 0.0;
michael@0 19413 d18 = 1.0 / d17;
michael@0 19414 d19 = +HEAPF32[i12 >> 2];
michael@0 19415 d20 = d18 * d19;
michael@0 19416 HEAPF32[i12 >> 2] = d20;
michael@0 19417 d21 = +HEAPF32[i13 >> 2];
michael@0 19418 d22 = d18 * d21;
michael@0 19419 HEAPF32[i13 >> 2] = d22;
michael@0 19420 d23 = +HEAPF32[i14 >> 2];
michael@0 19421 d24 = d18 * d23;
michael@0 19422 HEAPF32[i14 >> 2] = d24;
michael@0 19423 __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeED2Ev(i3);
michael@0 19424 STACKTOP = i2;
michael@0 19425 return;
michael@0 19426 }
michael@0 19427 i9 = HEAP32[i25 >> 2] | 0;
michael@0 19428 i25 = HEAP32[i28 >> 2] | 0;
michael@0 19429 d50 = 0.0;
michael@0 19430 i28 = 0;
michael@0 19431 while (1) {
michael@0 19432 i15 = HEAP32[i9 + (i28 * 56 | 0) + 4 >> 2] | 0;
michael@0 19433 i66 = i15 - 2 | 0;
michael@0 19434 i64 = HEAP32[i9 + (i28 * 56 | 0) + 12 >> 2] | 0;
michael@0 19435 i65 = HEAP32[i64 >> 2] | 0;
michael@0 19436 if ((i66 | 0) < 1) {
michael@0 19437 d68 = d50;
michael@0 19438 } else {
michael@0 19439 i8 = i25 + (i65 << 4) | 0;
michael@0 19440 i11 = i25 + (i65 << 4) + 4 | 0;
michael@0 19441 i6 = i25 + (i65 << 4) + 8 | 0;
michael@0 19442 d49 = d50;
michael@0 19443 i65 = 1;
michael@0 19444 d53 = +HEAPF32[i12 >> 2];
michael@0 19445 d54 = +HEAPF32[i13 >> 2];
michael@0 19446 d52 = +HEAPF32[i14 >> 2];
michael@0 19447 while (1) {
michael@0 19448 i7 = i65 + 1 | 0;
michael@0 19449 i10 = HEAP32[i64 + (i65 << 2) >> 2] | 0;
michael@0 19450 i60 = HEAP32[i64 + (((i7 | 0) % (i15 | 0) | 0) << 2) >> 2] | 0;
michael@0 19451 d51 = +HEAPF32[i8 >> 2];
michael@0 19452 d69 = +HEAPF32[i25 + (i10 << 4) >> 2];
michael@0 19453 d70 = d51 - d69;
michael@0 19454 d71 = +HEAPF32[i11 >> 2];
michael@0 19455 d72 = +HEAPF32[i25 + (i10 << 4) + 4 >> 2];
michael@0 19456 d73 = d71 - d72;
michael@0 19457 d74 = +HEAPF32[i6 >> 2];
michael@0 19458 d75 = +HEAPF32[i25 + (i10 << 4) + 8 >> 2];
michael@0 19459 d76 = d74 - d75;
michael@0 19460 d77 = +HEAPF32[i25 + (i60 << 4) >> 2];
michael@0 19461 d78 = d51 - d77;
michael@0 19462 d79 = +HEAPF32[i25 + (i60 << 4) + 4 >> 2];
michael@0 19463 d80 = d71 - d79;
michael@0 19464 d81 = +HEAPF32[i25 + (i60 << 4) + 8 >> 2];
michael@0 19465 d82 = d74 - d81;
michael@0 19466 d83 = d73 * d82 - d76 * d80;
michael@0 19467 d84 = d76 * d78 - d70 * d82;
michael@0 19468 d82 = d70 * d80 - d73 * d78;
michael@0 19469 d78 = +Math_sqrt(+(d82 * d82 + (d83 * d83 + d84 * d84))) * .5;
michael@0 19470 d84 = d53 + (d51 + d69 + d77) * .3333333432674408 * d78;
michael@0 19471 HEAPF32[i12 >> 2] = d84;
michael@0 19472 d77 = d54 + (d71 + d72 + d79) * .3333333432674408 * d78;
michael@0 19473 HEAPF32[i13 >> 2] = d77;
michael@0 19474 d79 = d52 + d78 * (d74 + d75 + d81) * .3333333432674408;
michael@0 19475 HEAPF32[i14 >> 2] = d79;
michael@0 19476 d81 = d49 + d78;
michael@0 19477 if ((i7 | 0) > (i66 | 0)) {
michael@0 19478 d68 = d81;
michael@0 19479 break;
michael@0 19480 } else {
michael@0 19481 d49 = d81;
michael@0 19482 i65 = i7;
michael@0 19483 d53 = d84;
michael@0 19484 d54 = d77;
michael@0 19485 d52 = d79;
michael@0 19486 }
michael@0 19487 }
michael@0 19488 }
michael@0 19489 i65 = i28 + 1 | 0;
michael@0 19490 if ((i65 | 0) < (i67 | 0)) {
michael@0 19491 d50 = d68;
michael@0 19492 i28 = i65;
michael@0 19493 } else {
michael@0 19494 d17 = d68;
michael@0 19495 break;
michael@0 19496 }
michael@0 19497 }
michael@0 19498 d18 = 1.0 / d17;
michael@0 19499 d19 = +HEAPF32[i12 >> 2];
michael@0 19500 d20 = d18 * d19;
michael@0 19501 HEAPF32[i12 >> 2] = d20;
michael@0 19502 d21 = +HEAPF32[i13 >> 2];
michael@0 19503 d22 = d18 * d21;
michael@0 19504 HEAPF32[i13 >> 2] = d22;
michael@0 19505 d23 = +HEAPF32[i14 >> 2];
michael@0 19506 d24 = d18 * d23;
michael@0 19507 HEAPF32[i14 >> 2] = d24;
michael@0 19508 __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeED2Ev(i3);
michael@0 19509 STACKTOP = i2;
michael@0 19510 return;
michael@0 19511 }
michael@0 19512 function __ZN12gjkepa2_impl3EPA8EvaluateERNS_3GJKERK9btVector3(i1, i2, i3) {
michael@0 19513 i1 = i1 | 0;
michael@0 19514 i2 = i2 | 0;
michael@0 19515 i3 = i3 | 0;
michael@0 19516 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, i24 = 0, d25 = 0.0, d26 = 0.0, d27 = 0.0, i28 = 0, i29 = 0, d30 = 0.0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, d36 = 0.0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, d62 = 0.0, d63 = 0.0, d64 = 0.0, d65 = 0.0, d66 = 0.0, i67 = 0, d68 = 0.0, d69 = 0.0, d70 = 0.0, d71 = 0.0, d72 = 0.0, d73 = 0.0, d74 = 0.0, i75 = 0, d76 = 0.0, d77 = 0.0, d78 = 0.0;
michael@0 19517 i4 = STACKTOP;
michael@0 19518 STACKTOP = STACKTOP + 16 | 0;
michael@0 19519 i5 = i4 | 0;
michael@0 19520 i6 = HEAP32[i2 + 372 >> 2] | 0;
michael@0 19521 do {
michael@0 19522 if ((HEAP32[i6 + 32 >> 2] | 0) >>> 0 > 1) {
michael@0 19523 if (!(__ZN12gjkepa2_impl3GJK13EncloseOriginEv(i2) | 0)) {
michael@0 19524 break;
michael@0 19525 }
michael@0 19526 i7 = i1 + 9792 | 0;
michael@0 19527 i8 = HEAP32[i7 >> 2] | 0;
michael@0 19528 if ((i8 | 0) != 0) {
michael@0 19529 i9 = i1 + 9796 | 0;
michael@0 19530 i10 = i1 + 9800 | 0;
michael@0 19531 i11 = i1 + 9804 | 0;
michael@0 19532 i12 = i8;
michael@0 19533 i8 = HEAP32[i9 >> 2] | 0;
michael@0 19534 i13 = HEAP32[i11 >> 2] | 0;
michael@0 19535 do {
michael@0 19536 i14 = i12 + 52 | 0;
michael@0 19537 i15 = HEAP32[i14 >> 2] | 0;
michael@0 19538 i16 = i12 + 48 | 0;
michael@0 19539 if ((i15 | 0) != 0) {
michael@0 19540 HEAP32[i15 + 48 >> 2] = HEAP32[i16 >> 2];
michael@0 19541 }
michael@0 19542 i15 = HEAP32[i16 >> 2] | 0;
michael@0 19543 if ((i15 | 0) != 0) {
michael@0 19544 HEAP32[i15 + 52 >> 2] = HEAP32[i14 >> 2];
michael@0 19545 }
michael@0 19546 if ((HEAP32[i7 >> 2] | 0) == (i12 | 0)) {
michael@0 19547 HEAP32[i7 >> 2] = HEAP32[i14 >> 2];
michael@0 19548 }
michael@0 19549 i8 = i8 - 1 | 0;
michael@0 19550 HEAP32[i16 >> 2] = 0;
michael@0 19551 HEAP32[i14 >> 2] = HEAP32[i10 >> 2];
michael@0 19552 i14 = HEAP32[i10 >> 2] | 0;
michael@0 19553 if ((i14 | 0) != 0) {
michael@0 19554 HEAP32[i14 + 48 >> 2] = i12;
michael@0 19555 }
michael@0 19556 HEAP32[i10 >> 2] = i12;
michael@0 19557 i13 = i13 + 1 | 0;
michael@0 19558 i12 = HEAP32[i7 >> 2] | 0;
michael@0 19559 } while ((i12 | 0) != 0);
michael@0 19560 HEAP32[i9 >> 2] = i8;
michael@0 19561 HEAP32[i11 >> 2] = i13;
michael@0 19562 }
michael@0 19563 i12 = i1 | 0;
michael@0 19564 HEAP32[i12 >> 2] = 0;
michael@0 19565 i10 = i1 + 9788 | 0;
michael@0 19566 HEAP32[i10 >> 2] = 0;
michael@0 19567 i14 = i6 | 0;
michael@0 19568 i16 = HEAP32[i14 >> 2] | 0;
michael@0 19569 i15 = i6 + 12 | 0;
michael@0 19570 i17 = HEAP32[i15 >> 2] | 0;
michael@0 19571 d18 = +HEAPF32[i17 + 16 >> 2];
michael@0 19572 d19 = +HEAPF32[i16 + 16 >> 2] - d18;
michael@0 19573 d20 = +HEAPF32[i17 + 20 >> 2];
michael@0 19574 d21 = +HEAPF32[i16 + 20 >> 2] - d20;
michael@0 19575 d22 = +HEAPF32[i17 + 24 >> 2];
michael@0 19576 d23 = +HEAPF32[i16 + 24 >> 2] - d22;
michael@0 19577 i17 = i6 + 4 | 0;
michael@0 19578 i24 = HEAP32[i17 >> 2] | 0;
michael@0 19579 d25 = +HEAPF32[i24 + 16 >> 2] - d18;
michael@0 19580 d26 = +HEAPF32[i24 + 20 >> 2] - d20;
michael@0 19581 d27 = +HEAPF32[i24 + 24 >> 2] - d22;
michael@0 19582 i28 = i6 + 8 | 0;
michael@0 19583 i29 = HEAP32[i28 >> 2] | 0;
michael@0 19584 d30 = +HEAPF32[i29 + 16 >> 2] - d18;
michael@0 19585 d18 = +HEAPF32[i29 + 20 >> 2] - d20;
michael@0 19586 d20 = +HEAPF32[i29 + 24 >> 2] - d22;
michael@0 19587 if (d19 * d26 * d20 + (d21 * d27 * d30 + d23 * d25 * d18 - d19 * d27 * d18 - d21 * d25 * d20) - d23 * d26 * d30 < 0.0) {
michael@0 19588 HEAP32[i14 >> 2] = i24;
michael@0 19589 HEAP32[i17 >> 2] = i16;
michael@0 19590 i31 = i6 + 16 | 0;
michael@0 19591 i32 = i6 + 20 | 0;
michael@0 19592 d30 = +HEAPF32[i31 >> 2];
michael@0 19593 HEAPF32[i31 >> 2] = +HEAPF32[i32 >> 2];
michael@0 19594 HEAPF32[i32 >> 2] = d30;
michael@0 19595 i33 = i24;
michael@0 19596 i34 = i16;
michael@0 19597 } else {
michael@0 19598 i33 = i16;
michael@0 19599 i34 = i24;
michael@0 19600 }
michael@0 19601 i24 = __ZN12gjkepa2_impl3EPA7newfaceEPNS_3GJK3sSVES3_S3_b(i1, i33, i34, i29, 1) | 0;
michael@0 19602 i29 = __ZN12gjkepa2_impl3EPA7newfaceEPNS_3GJK3sSVES3_S3_b(i1, HEAP32[i17 >> 2] | 0, HEAP32[i14 >> 2] | 0, HEAP32[i15 >> 2] | 0, 1) | 0;
michael@0 19603 i16 = __ZN12gjkepa2_impl3EPA7newfaceEPNS_3GJK3sSVES3_S3_b(i1, HEAP32[i28 >> 2] | 0, HEAP32[i17 >> 2] | 0, HEAP32[i15 >> 2] | 0, 1) | 0;
michael@0 19604 i17 = __ZN12gjkepa2_impl3EPA7newfaceEPNS_3GJK3sSVES3_S3_b(i1, HEAP32[i14 >> 2] | 0, HEAP32[i28 >> 2] | 0, HEAP32[i15 >> 2] | 0, 1) | 0;
michael@0 19605 i15 = i1 + 9796 | 0;
michael@0 19606 if ((HEAP32[i15 >> 2] | 0) != 4) {
michael@0 19607 break;
michael@0 19608 }
michael@0 19609 i28 = HEAP32[i7 >> 2] | 0;
michael@0 19610 d30 = +HEAPF32[i28 + 16 >> 2];
michael@0 19611 i14 = HEAP32[i28 + 52 >> 2] | 0;
michael@0 19612 if ((i14 | 0) == 0) {
michael@0 19613 i35 = i28;
michael@0 19614 d36 = d30;
michael@0 19615 } else {
michael@0 19616 d26 = d30 * d30;
michael@0 19617 d30 = +HEAPF32[i28 + 20 >> 2];
michael@0 19618 i32 = i28;
michael@0 19619 i28 = i14;
michael@0 19620 while (1) {
michael@0 19621 d23 = +HEAPF32[i28 + 16 >> 2];
michael@0 19622 d20 = d23 * d23;
michael@0 19623 d23 = +HEAPF32[i28 + 20 >> 2];
michael@0 19624 i14 = d23 >= d30 & d20 < d26;
michael@0 19625 i37 = i14 ? i28 : i32;
michael@0 19626 i31 = HEAP32[i28 + 52 >> 2] | 0;
michael@0 19627 if ((i31 | 0) == 0) {
michael@0 19628 break;
michael@0 19629 } else {
michael@0 19630 d26 = i14 ? d20 : d26;
michael@0 19631 d30 = i14 ? d23 : d30;
michael@0 19632 i32 = i37;
michael@0 19633 i28 = i31;
michael@0 19634 }
michael@0 19635 }
michael@0 19636 i35 = i37;
michael@0 19637 d36 = +HEAPF32[i37 + 16 >> 2];
michael@0 19638 }
michael@0 19639 d30 = +HEAPF32[i35 >> 2];
michael@0 19640 d26 = +HEAPF32[i35 + 4 >> 2];
michael@0 19641 d23 = +HEAPF32[i35 + 8 >> 2];
michael@0 19642 d20 = +HEAPF32[i35 + 12 >> 2];
michael@0 19643 d25 = +HEAPF32[i35 + 20 >> 2];
michael@0 19644 i28 = HEAP32[i35 + 24 >> 2] | 0;
michael@0 19645 i32 = HEAP32[i35 + 28 >> 2] | 0;
michael@0 19646 i13 = HEAP32[i35 + 32 >> 2] | 0;
michael@0 19647 HEAP8[i24 + 56 | 0] = 0;
michael@0 19648 HEAP32[i24 + 36 >> 2] = i29;
michael@0 19649 HEAP8[i29 + 56 | 0] = 0;
michael@0 19650 HEAP32[i29 + 36 >> 2] = i24;
michael@0 19651 HEAP8[i24 + 57 | 0] = 0;
michael@0 19652 HEAP32[i24 + 40 >> 2] = i16;
michael@0 19653 HEAP8[i16 + 56 | 0] = 1;
michael@0 19654 HEAP32[i16 + 36 >> 2] = i24;
michael@0 19655 HEAP8[i24 + 58 | 0] = 0;
michael@0 19656 HEAP32[i24 + 44 >> 2] = i17;
michael@0 19657 HEAP8[i17 + 56 | 0] = 2;
michael@0 19658 HEAP32[i17 + 36 >> 2] = i24;
michael@0 19659 HEAP8[i29 + 57 | 0] = 2;
michael@0 19660 HEAP32[i29 + 40 >> 2] = i17;
michael@0 19661 HEAP8[i17 + 58 | 0] = 1;
michael@0 19662 HEAP32[i17 + 44 >> 2] = i29;
michael@0 19663 HEAP8[i29 + 58 | 0] = 1;
michael@0 19664 HEAP32[i29 + 44 >> 2] = i16;
michael@0 19665 HEAP8[i16 + 57 | 0] = 2;
michael@0 19666 HEAP32[i16 + 40 >> 2] = i29;
michael@0 19667 HEAP8[i16 + 58 | 0] = 1;
michael@0 19668 HEAP32[i16 + 44 >> 2] = i17;
michael@0 19669 HEAP8[i17 + 57 | 0] = 2;
michael@0 19670 HEAP32[i17 + 40 >> 2] = i16;
michael@0 19671 HEAP32[i12 >> 2] = 0;
michael@0 19672 i11 = i5 | 0;
michael@0 19673 i8 = i5 + 4 | 0;
michael@0 19674 i9 = i5 + 8 | 0;
michael@0 19675 i31 = i1 + 9800 | 0;
michael@0 19676 i14 = i1 + 9804 | 0;
michael@0 19677 i38 = i13;
michael@0 19678 i13 = i32;
michael@0 19679 i32 = i28;
michael@0 19680 d21 = d25;
michael@0 19681 d25 = d36;
michael@0 19682 d18 = d20;
michael@0 19683 d20 = d23;
michael@0 19684 d23 = d26;
michael@0 19685 d26 = d30;
michael@0 19686 i28 = 0;
michael@0 19687 i39 = 1;
michael@0 19688 i40 = i35;
michael@0 19689 while (1) {
michael@0 19690 i41 = HEAP32[i10 >> 2] | 0;
michael@0 19691 if (i41 >>> 0 >= 64) {
michael@0 19692 i42 = 114;
michael@0 19693 break;
michael@0 19694 }
michael@0 19695 HEAP32[i11 >> 2] = 0;
michael@0 19696 HEAP32[i8 >> 2] = 0;
michael@0 19697 HEAP32[i9 >> 2] = 0;
michael@0 19698 HEAP32[i10 >> 2] = i41 + 1;
michael@0 19699 i43 = i1 + 60 + (i41 << 5) | 0;
michael@0 19700 HEAP8[i40 + 59 | 0] = i39 & 255;
michael@0 19701 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i2, i40 | 0, i43);
michael@0 19702 if (+HEAPF32[i40 >> 2] * +HEAPF32[i1 + 60 + (i41 << 5) + 16 >> 2] + +HEAPF32[i40 + 4 >> 2] * +HEAPF32[i1 + 60 + (i41 << 5) + 20 >> 2] + +HEAPF32[i40 + 8 >> 2] * +HEAPF32[i1 + 60 + (i41 << 5) + 24 >> 2] - +HEAPF32[i40 + 16 >> 2] > 9999999747378752.0e-20) {
michael@0 19703 i44 = 1;
michael@0 19704 i45 = 0;
michael@0 19705 } else {
michael@0 19706 i42 = 113;
michael@0 19707 break;
michael@0 19708 }
michael@0 19709 do {
michael@0 19710 i44 = i44 & (__ZN12gjkepa2_impl3EPA6expandEjPNS_3GJK3sSVEPNS0_5sFaceEjRNS0_8sHorizonE(i1, i39, i43, HEAP32[i40 + 36 + (i45 << 2) >> 2] | 0, HEAPU8[i40 + 56 + i45 | 0] | 0, i5) | 0);
michael@0 19711 i45 = i45 + 1 | 0;
michael@0 19712 } while (!(i45 >>> 0 > 2 | i44 ^ 1));
michael@0 19713 if (!i44) {
michael@0 19714 i42 = 112;
michael@0 19715 break;
michael@0 19716 }
michael@0 19717 if ((HEAP32[i9 >> 2] | 0) >>> 0 <= 2) {
michael@0 19718 i42 = 112;
michael@0 19719 break;
michael@0 19720 }
michael@0 19721 i43 = HEAP32[i11 >> 2] | 0;
michael@0 19722 i41 = HEAP32[i8 >> 2] | 0;
michael@0 19723 HEAP8[i43 + 57 | 0] = 2;
michael@0 19724 HEAP32[i43 + 40 >> 2] = i41;
michael@0 19725 HEAP8[i41 + 58 | 0] = 1;
michael@0 19726 HEAP32[i41 + 44 >> 2] = i43;
michael@0 19727 i43 = i40 + 52 | 0;
michael@0 19728 i41 = HEAP32[i43 >> 2] | 0;
michael@0 19729 i46 = i40 + 48 | 0;
michael@0 19730 if ((i41 | 0) != 0) {
michael@0 19731 HEAP32[i41 + 48 >> 2] = HEAP32[i46 >> 2];
michael@0 19732 }
michael@0 19733 i41 = HEAP32[i46 >> 2] | 0;
michael@0 19734 if ((i41 | 0) != 0) {
michael@0 19735 HEAP32[i41 + 52 >> 2] = HEAP32[i43 >> 2];
michael@0 19736 }
michael@0 19737 if ((HEAP32[i7 >> 2] | 0) == (i40 | 0)) {
michael@0 19738 HEAP32[i7 >> 2] = HEAP32[i43 >> 2];
michael@0 19739 }
michael@0 19740 HEAP32[i15 >> 2] = (HEAP32[i15 >> 2] | 0) - 1;
michael@0 19741 HEAP32[i46 >> 2] = 0;
michael@0 19742 HEAP32[i43 >> 2] = HEAP32[i31 >> 2];
michael@0 19743 i43 = HEAP32[i31 >> 2] | 0;
michael@0 19744 if ((i43 | 0) != 0) {
michael@0 19745 HEAP32[i43 + 48 >> 2] = i40;
michael@0 19746 }
michael@0 19747 HEAP32[i31 >> 2] = i40;
michael@0 19748 HEAP32[i14 >> 2] = (HEAP32[i14 >> 2] | 0) + 1;
michael@0 19749 i43 = HEAP32[i7 >> 2] | 0;
michael@0 19750 d30 = +HEAPF32[i43 + 16 >> 2];
michael@0 19751 i46 = HEAP32[i43 + 52 >> 2] | 0;
michael@0 19752 if ((i46 | 0) == 0) {
michael@0 19753 i47 = i43;
michael@0 19754 } else {
michael@0 19755 d27 = d30 * d30;
michael@0 19756 d30 = +HEAPF32[i43 + 20 >> 2];
michael@0 19757 i41 = i43;
michael@0 19758 i43 = i46;
michael@0 19759 while (1) {
michael@0 19760 d19 = +HEAPF32[i43 + 16 >> 2];
michael@0 19761 d22 = d19 * d19;
michael@0 19762 d19 = +HEAPF32[i43 + 20 >> 2];
michael@0 19763 i46 = d19 >= d30 & d22 < d27;
michael@0 19764 i48 = i46 ? i43 : i41;
michael@0 19765 i49 = HEAP32[i43 + 52 >> 2] | 0;
michael@0 19766 if ((i49 | 0) == 0) {
michael@0 19767 i47 = i48;
michael@0 19768 break;
michael@0 19769 } else {
michael@0 19770 d27 = i46 ? d22 : d27;
michael@0 19771 d30 = i46 ? d19 : d30;
michael@0 19772 i41 = i48;
michael@0 19773 i43 = i49;
michael@0 19774 }
michael@0 19775 }
michael@0 19776 }
michael@0 19777 d30 = +HEAPF32[i47 + 20 >> 2];
michael@0 19778 if (d30 < d21) {
michael@0 19779 d50 = d26;
michael@0 19780 d51 = d23;
michael@0 19781 d52 = d20;
michael@0 19782 d53 = d18;
michael@0 19783 d54 = d25;
michael@0 19784 d55 = d21;
michael@0 19785 i56 = i32;
michael@0 19786 i57 = i13;
michael@0 19787 i58 = i38;
michael@0 19788 } else {
michael@0 19789 d50 = +HEAPF32[i47 >> 2];
michael@0 19790 d51 = +HEAPF32[i47 + 4 >> 2];
michael@0 19791 d52 = +HEAPF32[i47 + 8 >> 2];
michael@0 19792 d53 = +HEAPF32[i47 + 12 >> 2];
michael@0 19793 d54 = +HEAPF32[i47 + 16 >> 2];
michael@0 19794 d55 = d30;
michael@0 19795 i56 = HEAP32[i47 + 24 >> 2] | 0;
michael@0 19796 i57 = HEAP32[i47 + 28 >> 2] | 0;
michael@0 19797 i58 = HEAP32[i47 + 32 >> 2] | 0;
michael@0 19798 }
michael@0 19799 i43 = i28 + 1 | 0;
michael@0 19800 if (i43 >>> 0 < 255) {
michael@0 19801 i38 = i58;
michael@0 19802 i13 = i57;
michael@0 19803 i32 = i56;
michael@0 19804 d21 = d55;
michael@0 19805 d25 = d54;
michael@0 19806 d18 = d53;
michael@0 19807 d20 = d52;
michael@0 19808 d23 = d51;
michael@0 19809 d26 = d50;
michael@0 19810 i28 = i43;
michael@0 19811 i39 = i39 + 1 | 0;
michael@0 19812 i40 = i47;
michael@0 19813 } else {
michael@0 19814 i42 = 116;
michael@0 19815 break;
michael@0 19816 }
michael@0 19817 }
michael@0 19818 if ((i42 | 0) == 112) {
michael@0 19819 HEAP32[i12 >> 2] = 4;
michael@0 19820 i59 = i38;
michael@0 19821 i60 = i13;
michael@0 19822 i61 = i32;
michael@0 19823 d62 = d25;
michael@0 19824 d63 = d18;
michael@0 19825 d64 = d20;
michael@0 19826 d65 = d23;
michael@0 19827 d66 = d26;
michael@0 19828 i67 = 4;
michael@0 19829 } else if ((i42 | 0) == 113) {
michael@0 19830 HEAP32[i12 >> 2] = 7;
michael@0 19831 i59 = i38;
michael@0 19832 i60 = i13;
michael@0 19833 i61 = i32;
michael@0 19834 d62 = d25;
michael@0 19835 d63 = d18;
michael@0 19836 d64 = d20;
michael@0 19837 d65 = d23;
michael@0 19838 d66 = d26;
michael@0 19839 i67 = 7;
michael@0 19840 } else if ((i42 | 0) == 114) {
michael@0 19841 HEAP32[i12 >> 2] = 6;
michael@0 19842 i59 = i38;
michael@0 19843 i60 = i13;
michael@0 19844 i61 = i32;
michael@0 19845 d62 = d25;
michael@0 19846 d63 = d18;
michael@0 19847 d64 = d20;
michael@0 19848 d65 = d23;
michael@0 19849 d66 = d26;
michael@0 19850 i67 = 6;
michael@0 19851 } else if ((i42 | 0) == 116) {
michael@0 19852 i59 = i58;
michael@0 19853 i60 = i57;
michael@0 19854 i61 = i56;
michael@0 19855 d62 = d54;
michael@0 19856 d63 = d53;
michael@0 19857 d64 = d52;
michael@0 19858 d65 = d51;
michael@0 19859 d66 = d50;
michael@0 19860 i67 = HEAP32[i12 >> 2] | 0;
michael@0 19861 }
michael@0 19862 d21 = d66 * d62;
michael@0 19863 d30 = d65 * d62;
michael@0 19864 d27 = d64 * d62;
michael@0 19865 HEAPF32[i1 + 40 >> 2] = d66;
michael@0 19866 HEAPF32[i1 + 44 >> 2] = d65;
michael@0 19867 HEAPF32[i1 + 48 >> 2] = d64;
michael@0 19868 HEAPF32[i1 + 52 >> 2] = d63;
michael@0 19869 HEAPF32[i1 + 56 >> 2] = d62;
michael@0 19870 HEAP32[i1 + 36 >> 2] = 3;
michael@0 19871 HEAP32[i1 + 4 >> 2] = i61;
michael@0 19872 HEAP32[i1 + 8 >> 2] = i60;
michael@0 19873 HEAP32[i1 + 12 >> 2] = i59;
michael@0 19874 i40 = i60 + 16 | 0;
michael@0 19875 d19 = +HEAPF32[i40 >> 2] - d21;
michael@0 19876 i39 = i60 + 20 | 0;
michael@0 19877 d22 = +HEAPF32[i39 >> 2] - d30;
michael@0 19878 i28 = i60 + 24 | 0;
michael@0 19879 d68 = +HEAPF32[i28 >> 2] - d27;
michael@0 19880 i7 = i59 + 16 | 0;
michael@0 19881 d69 = +HEAPF32[i7 >> 2] - d21;
michael@0 19882 i14 = i59 + 20 | 0;
michael@0 19883 d70 = +HEAPF32[i14 >> 2] - d30;
michael@0 19884 i31 = i59 + 24 | 0;
michael@0 19885 d71 = +HEAPF32[i31 >> 2] - d27;
michael@0 19886 d72 = d22 * d71 - d68 * d70;
michael@0 19887 d73 = d68 * d69 - d19 * d71;
michael@0 19888 d71 = d19 * d70 - d22 * d69;
michael@0 19889 d69 = +Math_sqrt(+(d71 * d71 + (d72 * d72 + d73 * d73)));
michael@0 19890 i15 = i1 + 20 | 0;
michael@0 19891 HEAPF32[i15 >> 2] = d69;
michael@0 19892 d73 = +HEAPF32[i7 >> 2] - d21;
michael@0 19893 d72 = +HEAPF32[i14 >> 2] - d30;
michael@0 19894 d71 = +HEAPF32[i31 >> 2] - d27;
michael@0 19895 i31 = i61 + 16 | 0;
michael@0 19896 d22 = +HEAPF32[i31 >> 2] - d21;
michael@0 19897 i14 = i61 + 20 | 0;
michael@0 19898 d70 = +HEAPF32[i14 >> 2] - d30;
michael@0 19899 i7 = i61 + 24 | 0;
michael@0 19900 d19 = +HEAPF32[i7 >> 2] - d27;
michael@0 19901 d68 = d72 * d19 - d71 * d70;
michael@0 19902 d74 = d71 * d22 - d73 * d19;
michael@0 19903 d19 = d73 * d70 - d72 * d22;
michael@0 19904 d22 = +Math_sqrt(+(d19 * d19 + (d68 * d68 + d74 * d74)));
michael@0 19905 i8 = i1 + 24 | 0;
michael@0 19906 HEAPF32[i8 >> 2] = d22;
michael@0 19907 d74 = +HEAPF32[i31 >> 2] - d21;
michael@0 19908 d68 = +HEAPF32[i14 >> 2] - d30;
michael@0 19909 d19 = +HEAPF32[i7 >> 2] - d27;
michael@0 19910 d72 = +HEAPF32[i40 >> 2] - d21;
michael@0 19911 d21 = +HEAPF32[i39 >> 2] - d30;
michael@0 19912 d30 = +HEAPF32[i28 >> 2] - d27;
michael@0 19913 d27 = d68 * d30 - d19 * d21;
michael@0 19914 d70 = d19 * d72 - d74 * d30;
michael@0 19915 d30 = d74 * d21 - d68 * d72;
michael@0 19916 d72 = +Math_sqrt(+(d30 * d30 + (d27 * d27 + d70 * d70)));
michael@0 19917 d70 = d69 + d22 + d72;
michael@0 19918 HEAPF32[i15 >> 2] = d69 / d70;
michael@0 19919 HEAPF32[i8 >> 2] = d22 / d70;
michael@0 19920 HEAPF32[i1 + 28 >> 2] = d72 / d70;
michael@0 19921 i75 = i67;
michael@0 19922 STACKTOP = i4;
michael@0 19923 return i75 | 0;
michael@0 19924 }
michael@0 19925 } while (0);
michael@0 19926 HEAP32[i1 >> 2] = 8;
michael@0 19927 d62 = +HEAPF32[i3 >> 2];
michael@0 19928 d63 = -0.0 - d62;
michael@0 19929 d64 = +HEAPF32[i3 + 4 >> 2];
michael@0 19930 d65 = -0.0 - d64;
michael@0 19931 d66 = +HEAPF32[i3 + 8 >> 2];
michael@0 19932 d50 = -0.0 - d66;
michael@0 19933 i3 = i1 + 40 | 0;
michael@0 19934 HEAPF32[i3 >> 2] = d63;
michael@0 19935 i67 = i1 + 44 | 0;
michael@0 19936 HEAPF32[i67 >> 2] = d65;
michael@0 19937 i61 = i1 + 48 | 0;
michael@0 19938 HEAPF32[i61 >> 2] = d50;
michael@0 19939 i59 = i1 + 52 | 0;
michael@0 19940 HEAPF32[i59 >> 2] = 0.0;
michael@0 19941 d51 = +Math_sqrt(+(d62 * d62 + d64 * d64 + d66 * d66));
michael@0 19942 if (d51 > 0.0) {
michael@0 19943 d66 = 1.0 / d51;
michael@0 19944 d76 = d66 * d50;
michael@0 19945 d77 = d66 * d65;
michael@0 19946 d78 = d66 * d63;
michael@0 19947 } else {
michael@0 19948 d76 = 0.0;
michael@0 19949 d77 = 0.0;
michael@0 19950 d78 = 1.0;
michael@0 19951 }
michael@0 19952 HEAPF32[i3 >> 2] = d78;
michael@0 19953 HEAPF32[i67 >> 2] = d77;
michael@0 19954 HEAPF32[i61 >> 2] = d76;
michael@0 19955 HEAPF32[i59 >> 2] = 0.0;
michael@0 19956 HEAPF32[i1 + 56 >> 2] = 0.0;
michael@0 19957 HEAP32[i1 + 36 >> 2] = 1;
michael@0 19958 HEAP32[i1 + 4 >> 2] = HEAP32[i6 >> 2];
michael@0 19959 HEAPF32[i1 + 20 >> 2] = 1.0;
michael@0 19960 i75 = 8;
michael@0 19961 STACKTOP = i4;
michael@0 19962 return i75 | 0;
michael@0 19963 }
michael@0 19964 function _free(i1) {
michael@0 19965 i1 = i1 | 0;
michael@0 19966 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0;
michael@0 19967 if ((i1 | 0) == 0) {
michael@0 19968 return;
michael@0 19969 }
michael@0 19970 i2 = i1 - 8 | 0;
michael@0 19971 i3 = i2;
michael@0 19972 i4 = HEAP32[3020] | 0;
michael@0 19973 if (i2 >>> 0 < i4 >>> 0) {
michael@0 19974 _abort();
michael@0 19975 }
michael@0 19976 i5 = HEAP32[i1 - 4 >> 2] | 0;
michael@0 19977 i6 = i5 & 3;
michael@0 19978 if ((i6 | 0) == 1) {
michael@0 19979 _abort();
michael@0 19980 }
michael@0 19981 i7 = i5 & -8;
michael@0 19982 i8 = i1 + (i7 - 8) | 0;
michael@0 19983 i9 = i8;
michael@0 19984 L527 : do {
michael@0 19985 if ((i5 & 1 | 0) == 0) {
michael@0 19986 i10 = HEAP32[i2 >> 2] | 0;
michael@0 19987 if ((i6 | 0) == 0) {
michael@0 19988 return;
michael@0 19989 }
michael@0 19990 i11 = -8 - i10 | 0;
michael@0 19991 i12 = i1 + i11 | 0;
michael@0 19992 i13 = i12;
michael@0 19993 i14 = i10 + i7 | 0;
michael@0 19994 if (i12 >>> 0 < i4 >>> 0) {
michael@0 19995 _abort();
michael@0 19996 }
michael@0 19997 if ((i13 | 0) == (HEAP32[3021] | 0)) {
michael@0 19998 i15 = i1 + (i7 - 4) | 0;
michael@0 19999 if ((HEAP32[i15 >> 2] & 3 | 0) != 3) {
michael@0 20000 i16 = i13;
michael@0 20001 i17 = i14;
michael@0 20002 break;
michael@0 20003 }
michael@0 20004 HEAP32[3018] = i14;
michael@0 20005 HEAP32[i15 >> 2] = HEAP32[i15 >> 2] & -2;
michael@0 20006 HEAP32[i1 + (i11 + 4) >> 2] = i14 | 1;
michael@0 20007 HEAP32[i8 >> 2] = i14;
michael@0 20008 return;
michael@0 20009 }
michael@0 20010 i15 = i10 >>> 3;
michael@0 20011 if (i10 >>> 0 < 256) {
michael@0 20012 i10 = HEAP32[i1 + (i11 + 8) >> 2] | 0;
michael@0 20013 i18 = HEAP32[i1 + (i11 + 12) >> 2] | 0;
michael@0 20014 i19 = 12104 + (i15 << 1 << 2) | 0;
michael@0 20015 do {
michael@0 20016 if ((i10 | 0) != (i19 | 0)) {
michael@0 20017 if (i10 >>> 0 < i4 >>> 0) {
michael@0 20018 _abort();
michael@0 20019 }
michael@0 20020 if ((HEAP32[i10 + 12 >> 2] | 0) == (i13 | 0)) {
michael@0 20021 break;
michael@0 20022 }
michael@0 20023 _abort();
michael@0 20024 }
michael@0 20025 } while (0);
michael@0 20026 if ((i18 | 0) == (i10 | 0)) {
michael@0 20027 HEAP32[3016] = HEAP32[3016] & ~(1 << i15);
michael@0 20028 i16 = i13;
michael@0 20029 i17 = i14;
michael@0 20030 break;
michael@0 20031 }
michael@0 20032 do {
michael@0 20033 if ((i18 | 0) == (i19 | 0)) {
michael@0 20034 i20 = i18 + 8 | 0;
michael@0 20035 } else {
michael@0 20036 if (i18 >>> 0 < i4 >>> 0) {
michael@0 20037 _abort();
michael@0 20038 }
michael@0 20039 i21 = i18 + 8 | 0;
michael@0 20040 if ((HEAP32[i21 >> 2] | 0) == (i13 | 0)) {
michael@0 20041 i20 = i21;
michael@0 20042 break;
michael@0 20043 }
michael@0 20044 _abort();
michael@0 20045 }
michael@0 20046 } while (0);
michael@0 20047 HEAP32[i10 + 12 >> 2] = i18;
michael@0 20048 HEAP32[i20 >> 2] = i10;
michael@0 20049 i16 = i13;
michael@0 20050 i17 = i14;
michael@0 20051 break;
michael@0 20052 }
michael@0 20053 i19 = i12;
michael@0 20054 i15 = HEAP32[i1 + (i11 + 24) >> 2] | 0;
michael@0 20055 i21 = HEAP32[i1 + (i11 + 12) >> 2] | 0;
michael@0 20056 do {
michael@0 20057 if ((i21 | 0) == (i19 | 0)) {
michael@0 20058 i22 = i1 + (i11 + 20) | 0;
michael@0 20059 i23 = HEAP32[i22 >> 2] | 0;
michael@0 20060 if ((i23 | 0) == 0) {
michael@0 20061 i24 = i1 + (i11 + 16) | 0;
michael@0 20062 i25 = HEAP32[i24 >> 2] | 0;
michael@0 20063 if ((i25 | 0) == 0) {
michael@0 20064 i26 = 0;
michael@0 20065 break;
michael@0 20066 } else {
michael@0 20067 i27 = i25;
michael@0 20068 i28 = i24;
michael@0 20069 }
michael@0 20070 } else {
michael@0 20071 i27 = i23;
michael@0 20072 i28 = i22;
michael@0 20073 }
michael@0 20074 while (1) {
michael@0 20075 i22 = i27 + 20 | 0;
michael@0 20076 i23 = HEAP32[i22 >> 2] | 0;
michael@0 20077 if ((i23 | 0) != 0) {
michael@0 20078 i27 = i23;
michael@0 20079 i28 = i22;
michael@0 20080 continue;
michael@0 20081 }
michael@0 20082 i22 = i27 + 16 | 0;
michael@0 20083 i23 = HEAP32[i22 >> 2] | 0;
michael@0 20084 if ((i23 | 0) == 0) {
michael@0 20085 break;
michael@0 20086 } else {
michael@0 20087 i27 = i23;
michael@0 20088 i28 = i22;
michael@0 20089 }
michael@0 20090 }
michael@0 20091 if (i28 >>> 0 < i4 >>> 0) {
michael@0 20092 _abort();
michael@0 20093 } else {
michael@0 20094 HEAP32[i28 >> 2] = 0;
michael@0 20095 i26 = i27;
michael@0 20096 break;
michael@0 20097 }
michael@0 20098 } else {
michael@0 20099 i22 = HEAP32[i1 + (i11 + 8) >> 2] | 0;
michael@0 20100 if (i22 >>> 0 < i4 >>> 0) {
michael@0 20101 _abort();
michael@0 20102 }
michael@0 20103 i23 = i22 + 12 | 0;
michael@0 20104 if ((HEAP32[i23 >> 2] | 0) != (i19 | 0)) {
michael@0 20105 _abort();
michael@0 20106 }
michael@0 20107 i24 = i21 + 8 | 0;
michael@0 20108 if ((HEAP32[i24 >> 2] | 0) == (i19 | 0)) {
michael@0 20109 HEAP32[i23 >> 2] = i21;
michael@0 20110 HEAP32[i24 >> 2] = i22;
michael@0 20111 i26 = i21;
michael@0 20112 break;
michael@0 20113 } else {
michael@0 20114 _abort();
michael@0 20115 }
michael@0 20116 }
michael@0 20117 } while (0);
michael@0 20118 if ((i15 | 0) == 0) {
michael@0 20119 i16 = i13;
michael@0 20120 i17 = i14;
michael@0 20121 break;
michael@0 20122 }
michael@0 20123 i21 = i1 + (i11 + 28) | 0;
michael@0 20124 i12 = 12368 + (HEAP32[i21 >> 2] << 2) | 0;
michael@0 20125 do {
michael@0 20126 if ((i19 | 0) == (HEAP32[i12 >> 2] | 0)) {
michael@0 20127 HEAP32[i12 >> 2] = i26;
michael@0 20128 if ((i26 | 0) != 0) {
michael@0 20129 break;
michael@0 20130 }
michael@0 20131 HEAP32[3017] = HEAP32[3017] & ~(1 << HEAP32[i21 >> 2]);
michael@0 20132 i16 = i13;
michael@0 20133 i17 = i14;
michael@0 20134 break L527;
michael@0 20135 } else {
michael@0 20136 if (i15 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20137 _abort();
michael@0 20138 }
michael@0 20139 i10 = i15 + 16 | 0;
michael@0 20140 if ((HEAP32[i10 >> 2] | 0) == (i19 | 0)) {
michael@0 20141 HEAP32[i10 >> 2] = i26;
michael@0 20142 } else {
michael@0 20143 HEAP32[i15 + 20 >> 2] = i26;
michael@0 20144 }
michael@0 20145 if ((i26 | 0) == 0) {
michael@0 20146 i16 = i13;
michael@0 20147 i17 = i14;
michael@0 20148 break L527;
michael@0 20149 }
michael@0 20150 }
michael@0 20151 } while (0);
michael@0 20152 if (i26 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20153 _abort();
michael@0 20154 }
michael@0 20155 HEAP32[i26 + 24 >> 2] = i15;
michael@0 20156 i19 = HEAP32[i1 + (i11 + 16) >> 2] | 0;
michael@0 20157 do {
michael@0 20158 if ((i19 | 0) != 0) {
michael@0 20159 if (i19 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20160 _abort();
michael@0 20161 } else {
michael@0 20162 HEAP32[i26 + 16 >> 2] = i19;
michael@0 20163 HEAP32[i19 + 24 >> 2] = i26;
michael@0 20164 break;
michael@0 20165 }
michael@0 20166 }
michael@0 20167 } while (0);
michael@0 20168 i19 = HEAP32[i1 + (i11 + 20) >> 2] | 0;
michael@0 20169 if ((i19 | 0) == 0) {
michael@0 20170 i16 = i13;
michael@0 20171 i17 = i14;
michael@0 20172 break;
michael@0 20173 }
michael@0 20174 if (i19 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20175 _abort();
michael@0 20176 } else {
michael@0 20177 HEAP32[i26 + 20 >> 2] = i19;
michael@0 20178 HEAP32[i19 + 24 >> 2] = i26;
michael@0 20179 i16 = i13;
michael@0 20180 i17 = i14;
michael@0 20181 break;
michael@0 20182 }
michael@0 20183 } else {
michael@0 20184 i16 = i3;
michael@0 20185 i17 = i7;
michael@0 20186 }
michael@0 20187 } while (0);
michael@0 20188 i3 = i16;
michael@0 20189 if (i3 >>> 0 >= i8 >>> 0) {
michael@0 20190 _abort();
michael@0 20191 }
michael@0 20192 i26 = i1 + (i7 - 4) | 0;
michael@0 20193 i4 = HEAP32[i26 >> 2] | 0;
michael@0 20194 if ((i4 & 1 | 0) == 0) {
michael@0 20195 _abort();
michael@0 20196 }
michael@0 20197 do {
michael@0 20198 if ((i4 & 2 | 0) == 0) {
michael@0 20199 if ((i9 | 0) == (HEAP32[3022] | 0)) {
michael@0 20200 i27 = (HEAP32[3019] | 0) + i17 | 0;
michael@0 20201 HEAP32[3019] = i27;
michael@0 20202 HEAP32[3022] = i16;
michael@0 20203 HEAP32[i16 + 4 >> 2] = i27 | 1;
michael@0 20204 if ((i16 | 0) != (HEAP32[3021] | 0)) {
michael@0 20205 return;
michael@0 20206 }
michael@0 20207 HEAP32[3021] = 0;
michael@0 20208 HEAP32[3018] = 0;
michael@0 20209 return;
michael@0 20210 }
michael@0 20211 if ((i9 | 0) == (HEAP32[3021] | 0)) {
michael@0 20212 i27 = (HEAP32[3018] | 0) + i17 | 0;
michael@0 20213 HEAP32[3018] = i27;
michael@0 20214 HEAP32[3021] = i16;
michael@0 20215 HEAP32[i16 + 4 >> 2] = i27 | 1;
michael@0 20216 HEAP32[i3 + i27 >> 2] = i27;
michael@0 20217 return;
michael@0 20218 }
michael@0 20219 i27 = (i4 & -8) + i17 | 0;
michael@0 20220 i28 = i4 >>> 3;
michael@0 20221 L630 : do {
michael@0 20222 if (i4 >>> 0 < 256) {
michael@0 20223 i20 = HEAP32[i1 + i7 >> 2] | 0;
michael@0 20224 i6 = HEAP32[i1 + (i7 | 4) >> 2] | 0;
michael@0 20225 i2 = 12104 + (i28 << 1 << 2) | 0;
michael@0 20226 do {
michael@0 20227 if ((i20 | 0) != (i2 | 0)) {
michael@0 20228 if (i20 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20229 _abort();
michael@0 20230 }
michael@0 20231 if ((HEAP32[i20 + 12 >> 2] | 0) == (i9 | 0)) {
michael@0 20232 break;
michael@0 20233 }
michael@0 20234 _abort();
michael@0 20235 }
michael@0 20236 } while (0);
michael@0 20237 if ((i6 | 0) == (i20 | 0)) {
michael@0 20238 HEAP32[3016] = HEAP32[3016] & ~(1 << i28);
michael@0 20239 break;
michael@0 20240 }
michael@0 20241 do {
michael@0 20242 if ((i6 | 0) == (i2 | 0)) {
michael@0 20243 i29 = i6 + 8 | 0;
michael@0 20244 } else {
michael@0 20245 if (i6 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20246 _abort();
michael@0 20247 }
michael@0 20248 i5 = i6 + 8 | 0;
michael@0 20249 if ((HEAP32[i5 >> 2] | 0) == (i9 | 0)) {
michael@0 20250 i29 = i5;
michael@0 20251 break;
michael@0 20252 }
michael@0 20253 _abort();
michael@0 20254 }
michael@0 20255 } while (0);
michael@0 20256 HEAP32[i20 + 12 >> 2] = i6;
michael@0 20257 HEAP32[i29 >> 2] = i20;
michael@0 20258 } else {
michael@0 20259 i2 = i8;
michael@0 20260 i5 = HEAP32[i1 + (i7 + 16) >> 2] | 0;
michael@0 20261 i19 = HEAP32[i1 + (i7 | 4) >> 2] | 0;
michael@0 20262 do {
michael@0 20263 if ((i19 | 0) == (i2 | 0)) {
michael@0 20264 i15 = i1 + (i7 + 12) | 0;
michael@0 20265 i21 = HEAP32[i15 >> 2] | 0;
michael@0 20266 if ((i21 | 0) == 0) {
michael@0 20267 i12 = i1 + (i7 + 8) | 0;
michael@0 20268 i10 = HEAP32[i12 >> 2] | 0;
michael@0 20269 if ((i10 | 0) == 0) {
michael@0 20270 i30 = 0;
michael@0 20271 break;
michael@0 20272 } else {
michael@0 20273 i31 = i10;
michael@0 20274 i32 = i12;
michael@0 20275 }
michael@0 20276 } else {
michael@0 20277 i31 = i21;
michael@0 20278 i32 = i15;
michael@0 20279 }
michael@0 20280 while (1) {
michael@0 20281 i15 = i31 + 20 | 0;
michael@0 20282 i21 = HEAP32[i15 >> 2] | 0;
michael@0 20283 if ((i21 | 0) != 0) {
michael@0 20284 i31 = i21;
michael@0 20285 i32 = i15;
michael@0 20286 continue;
michael@0 20287 }
michael@0 20288 i15 = i31 + 16 | 0;
michael@0 20289 i21 = HEAP32[i15 >> 2] | 0;
michael@0 20290 if ((i21 | 0) == 0) {
michael@0 20291 break;
michael@0 20292 } else {
michael@0 20293 i31 = i21;
michael@0 20294 i32 = i15;
michael@0 20295 }
michael@0 20296 }
michael@0 20297 if (i32 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20298 _abort();
michael@0 20299 } else {
michael@0 20300 HEAP32[i32 >> 2] = 0;
michael@0 20301 i30 = i31;
michael@0 20302 break;
michael@0 20303 }
michael@0 20304 } else {
michael@0 20305 i15 = HEAP32[i1 + i7 >> 2] | 0;
michael@0 20306 if (i15 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20307 _abort();
michael@0 20308 }
michael@0 20309 i21 = i15 + 12 | 0;
michael@0 20310 if ((HEAP32[i21 >> 2] | 0) != (i2 | 0)) {
michael@0 20311 _abort();
michael@0 20312 }
michael@0 20313 i12 = i19 + 8 | 0;
michael@0 20314 if ((HEAP32[i12 >> 2] | 0) == (i2 | 0)) {
michael@0 20315 HEAP32[i21 >> 2] = i19;
michael@0 20316 HEAP32[i12 >> 2] = i15;
michael@0 20317 i30 = i19;
michael@0 20318 break;
michael@0 20319 } else {
michael@0 20320 _abort();
michael@0 20321 }
michael@0 20322 }
michael@0 20323 } while (0);
michael@0 20324 if ((i5 | 0) == 0) {
michael@0 20325 break;
michael@0 20326 }
michael@0 20327 i19 = i1 + (i7 + 20) | 0;
michael@0 20328 i20 = 12368 + (HEAP32[i19 >> 2] << 2) | 0;
michael@0 20329 do {
michael@0 20330 if ((i2 | 0) == (HEAP32[i20 >> 2] | 0)) {
michael@0 20331 HEAP32[i20 >> 2] = i30;
michael@0 20332 if ((i30 | 0) != 0) {
michael@0 20333 break;
michael@0 20334 }
michael@0 20335 HEAP32[3017] = HEAP32[3017] & ~(1 << HEAP32[i19 >> 2]);
michael@0 20336 break L630;
michael@0 20337 } else {
michael@0 20338 if (i5 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20339 _abort();
michael@0 20340 }
michael@0 20341 i6 = i5 + 16 | 0;
michael@0 20342 if ((HEAP32[i6 >> 2] | 0) == (i2 | 0)) {
michael@0 20343 HEAP32[i6 >> 2] = i30;
michael@0 20344 } else {
michael@0 20345 HEAP32[i5 + 20 >> 2] = i30;
michael@0 20346 }
michael@0 20347 if ((i30 | 0) == 0) {
michael@0 20348 break L630;
michael@0 20349 }
michael@0 20350 }
michael@0 20351 } while (0);
michael@0 20352 if (i30 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20353 _abort();
michael@0 20354 }
michael@0 20355 HEAP32[i30 + 24 >> 2] = i5;
michael@0 20356 i2 = HEAP32[i1 + (i7 + 8) >> 2] | 0;
michael@0 20357 do {
michael@0 20358 if ((i2 | 0) != 0) {
michael@0 20359 if (i2 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20360 _abort();
michael@0 20361 } else {
michael@0 20362 HEAP32[i30 + 16 >> 2] = i2;
michael@0 20363 HEAP32[i2 + 24 >> 2] = i30;
michael@0 20364 break;
michael@0 20365 }
michael@0 20366 }
michael@0 20367 } while (0);
michael@0 20368 i2 = HEAP32[i1 + (i7 + 12) >> 2] | 0;
michael@0 20369 if ((i2 | 0) == 0) {
michael@0 20370 break;
michael@0 20371 }
michael@0 20372 if (i2 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20373 _abort();
michael@0 20374 } else {
michael@0 20375 HEAP32[i30 + 20 >> 2] = i2;
michael@0 20376 HEAP32[i2 + 24 >> 2] = i30;
michael@0 20377 break;
michael@0 20378 }
michael@0 20379 }
michael@0 20380 } while (0);
michael@0 20381 HEAP32[i16 + 4 >> 2] = i27 | 1;
michael@0 20382 HEAP32[i3 + i27 >> 2] = i27;
michael@0 20383 if ((i16 | 0) != (HEAP32[3021] | 0)) {
michael@0 20384 i33 = i27;
michael@0 20385 break;
michael@0 20386 }
michael@0 20387 HEAP32[3018] = i27;
michael@0 20388 return;
michael@0 20389 } else {
michael@0 20390 HEAP32[i26 >> 2] = i4 & -2;
michael@0 20391 HEAP32[i16 + 4 >> 2] = i17 | 1;
michael@0 20392 HEAP32[i3 + i17 >> 2] = i17;
michael@0 20393 i33 = i17;
michael@0 20394 }
michael@0 20395 } while (0);
michael@0 20396 i17 = i33 >>> 3;
michael@0 20397 if (i33 >>> 0 < 256) {
michael@0 20398 i3 = i17 << 1;
michael@0 20399 i4 = 12104 + (i3 << 2) | 0;
michael@0 20400 i26 = HEAP32[3016] | 0;
michael@0 20401 i30 = 1 << i17;
michael@0 20402 do {
michael@0 20403 if ((i26 & i30 | 0) == 0) {
michael@0 20404 HEAP32[3016] = i26 | i30;
michael@0 20405 i34 = i4;
michael@0 20406 i35 = 12104 + (i3 + 2 << 2) | 0;
michael@0 20407 } else {
michael@0 20408 i17 = 12104 + (i3 + 2 << 2) | 0;
michael@0 20409 i7 = HEAP32[i17 >> 2] | 0;
michael@0 20410 if (i7 >>> 0 >= (HEAP32[3020] | 0) >>> 0) {
michael@0 20411 i34 = i7;
michael@0 20412 i35 = i17;
michael@0 20413 break;
michael@0 20414 }
michael@0 20415 _abort();
michael@0 20416 }
michael@0 20417 } while (0);
michael@0 20418 HEAP32[i35 >> 2] = i16;
michael@0 20419 HEAP32[i34 + 12 >> 2] = i16;
michael@0 20420 HEAP32[i16 + 8 >> 2] = i34;
michael@0 20421 HEAP32[i16 + 12 >> 2] = i4;
michael@0 20422 return;
michael@0 20423 }
michael@0 20424 i4 = i16;
michael@0 20425 i34 = i33 >>> 8;
michael@0 20426 do {
michael@0 20427 if ((i34 | 0) == 0) {
michael@0 20428 i36 = 0;
michael@0 20429 } else {
michael@0 20430 if (i33 >>> 0 > 16777215) {
michael@0 20431 i36 = 31;
michael@0 20432 break;
michael@0 20433 }
michael@0 20434 i35 = (i34 + 1048320 | 0) >>> 16 & 8;
michael@0 20435 i3 = i34 << i35;
michael@0 20436 i30 = (i3 + 520192 | 0) >>> 16 & 4;
michael@0 20437 i26 = i3 << i30;
michael@0 20438 i3 = (i26 + 245760 | 0) >>> 16 & 2;
michael@0 20439 i17 = 14 - (i30 | i35 | i3) + (i26 << i3 >>> 15) | 0;
michael@0 20440 i36 = i33 >>> ((i17 + 7 | 0) >>> 0) & 1 | i17 << 1;
michael@0 20441 }
michael@0 20442 } while (0);
michael@0 20443 i34 = 12368 + (i36 << 2) | 0;
michael@0 20444 HEAP32[i16 + 28 >> 2] = i36;
michael@0 20445 HEAP32[i16 + 20 >> 2] = 0;
michael@0 20446 HEAP32[i16 + 16 >> 2] = 0;
michael@0 20447 i17 = HEAP32[3017] | 0;
michael@0 20448 i3 = 1 << i36;
michael@0 20449 do {
michael@0 20450 if ((i17 & i3 | 0) == 0) {
michael@0 20451 HEAP32[3017] = i17 | i3;
michael@0 20452 HEAP32[i34 >> 2] = i4;
michael@0 20453 HEAP32[i16 + 24 >> 2] = i34;
michael@0 20454 HEAP32[i16 + 12 >> 2] = i16;
michael@0 20455 HEAP32[i16 + 8 >> 2] = i16;
michael@0 20456 } else {
michael@0 20457 if ((i36 | 0) == 31) {
michael@0 20458 i37 = 0;
michael@0 20459 } else {
michael@0 20460 i37 = 25 - (i36 >>> 1) | 0;
michael@0 20461 }
michael@0 20462 i26 = i33 << i37;
michael@0 20463 i35 = HEAP32[i34 >> 2] | 0;
michael@0 20464 while (1) {
michael@0 20465 if ((HEAP32[i35 + 4 >> 2] & -8 | 0) == (i33 | 0)) {
michael@0 20466 break;
michael@0 20467 }
michael@0 20468 i38 = i35 + 16 + (i26 >>> 31 << 2) | 0;
michael@0 20469 i30 = HEAP32[i38 >> 2] | 0;
michael@0 20470 if ((i30 | 0) == 0) {
michael@0 20471 i39 = 508;
michael@0 20472 break;
michael@0 20473 } else {
michael@0 20474 i26 = i26 << 1;
michael@0 20475 i35 = i30;
michael@0 20476 }
michael@0 20477 }
michael@0 20478 if ((i39 | 0) == 508) {
michael@0 20479 if (i38 >>> 0 < (HEAP32[3020] | 0) >>> 0) {
michael@0 20480 _abort();
michael@0 20481 } else {
michael@0 20482 HEAP32[i38 >> 2] = i4;
michael@0 20483 HEAP32[i16 + 24 >> 2] = i35;
michael@0 20484 HEAP32[i16 + 12 >> 2] = i16;
michael@0 20485 HEAP32[i16 + 8 >> 2] = i16;
michael@0 20486 break;
michael@0 20487 }
michael@0 20488 }
michael@0 20489 i26 = i35 + 8 | 0;
michael@0 20490 i27 = HEAP32[i26 >> 2] | 0;
michael@0 20491 i30 = HEAP32[3020] | 0;
michael@0 20492 if (i35 >>> 0 < i30 >>> 0) {
michael@0 20493 _abort();
michael@0 20494 }
michael@0 20495 if (i27 >>> 0 < i30 >>> 0) {
michael@0 20496 _abort();
michael@0 20497 } else {
michael@0 20498 HEAP32[i27 + 12 >> 2] = i4;
michael@0 20499 HEAP32[i26 >> 2] = i4;
michael@0 20500 HEAP32[i16 + 8 >> 2] = i27;
michael@0 20501 HEAP32[i16 + 12 >> 2] = i35;
michael@0 20502 HEAP32[i16 + 24 >> 2] = 0;
michael@0 20503 break;
michael@0 20504 }
michael@0 20505 }
michael@0 20506 } while (0);
michael@0 20507 i16 = (HEAP32[3024] | 0) - 1 | 0;
michael@0 20508 HEAP32[3024] = i16;
michael@0 20509 if ((i16 | 0) == 0) {
michael@0 20510 i40 = 12520;
michael@0 20511 } else {
michael@0 20512 return;
michael@0 20513 }
michael@0 20514 while (1) {
michael@0 20515 i16 = HEAP32[i40 >> 2] | 0;
michael@0 20516 if ((i16 | 0) == 0) {
michael@0 20517 break;
michael@0 20518 } else {
michael@0 20519 i40 = i16 + 8 | 0;
michael@0 20520 }
michael@0 20521 }
michael@0 20522 HEAP32[3024] = -1;
michael@0 20523 return;
michael@0 20524 }
michael@0 20525 function __ZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackE(i1, i2, i3, i4, i5, i6) {
michael@0 20526 i1 = i1 | 0;
michael@0 20527 i2 = i2 | 0;
michael@0 20528 i3 = i3 | 0;
michael@0 20529 i4 = i4 | 0;
michael@0 20530 i5 = i5 | 0;
michael@0 20531 i6 = i6 | 0;
michael@0 20532 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, d32 = 0.0, i33 = 0, d34 = 0.0, i35 = 0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0;
michael@0 20533 i7 = STACKTOP;
michael@0 20534 STACKTOP = STACKTOP + 1264 | 0;
michael@0 20535 i8 = i7 | 0;
michael@0 20536 i9 = i7 + 64 | 0;
michael@0 20537 i10 = i7 + 96 | 0;
michael@0 20538 i11 = i7 + 152 | 0;
michael@0 20539 i12 = i7 + 328 | 0;
michael@0 20540 i13 = i7 + 688 | 0;
michael@0 20541 i14 = i7 + 704 | 0;
michael@0 20542 i15 = i7 + 736 | 0;
michael@0 20543 i16 = i7 + 752 | 0;
michael@0 20544 i17 = i7 + 768 | 0;
michael@0 20545 i18 = i7 + 888 | 0;
michael@0 20546 i19 = i7 + 904 | 0;
michael@0 20547 i20 = i7 + 920 | 0;
michael@0 20548 i21 = i7 + 1040 | 0;
michael@0 20549 i22 = i7 + 1056 | 0;
michael@0 20550 i23 = i7 + 1072 | 0;
michael@0 20551 i24 = i7 + 1104 | 0;
michael@0 20552 i25 = i7 + 1120 | 0;
michael@0 20553 i26 = i7 + 1184 | 0;
michael@0 20554 i27 = i7 + 1200 | 0;
michael@0 20555 __ZN21btConvexInternalShapeC2Ev(i10 | 0);
michael@0 20556 HEAP32[i10 >> 2] = 4728;
michael@0 20557 HEAP32[i10 + 4 >> 2] = 8;
michael@0 20558 HEAPF32[i10 + 28 >> 2] = 0.0;
michael@0 20559 HEAPF32[i10 + 44 >> 2] = 0.0;
michael@0 20560 i28 = i10 | 0;
michael@0 20561 i10 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 20562 if ((i10 | 0) < 20) {
michael@0 20563 HEAP32[i11 >> 2] = 2280;
michael@0 20564 i29 = i11 + 164 | 0;
michael@0 20565 HEAP32[i11 + 168 >> 2] = 0;
michael@0 20566 HEAPF32[i11 + 172 >> 2] = 0.0;
michael@0 20567 i30 = i6 + 4 | 0;
michael@0 20568 HEAPF32[i29 >> 2] = +HEAPF32[i30 >> 2];
michael@0 20569 HEAPF32[i12 + 308 >> 2] = 9999999747378752.0e-20;
michael@0 20570 HEAP16[i12 + 332 >> 1] = 0;
michael@0 20571 __ZN22btSubsimplexConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver(i13, i28, i4, i12);
michael@0 20572 do {
michael@0 20573 if (__ZN22btSubsimplexConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i13, i1, i2, i5, i5, i11) | 0) {
michael@0 20574 i12 = i11 + 132 | 0;
michael@0 20575 i31 = i12 | 0;
michael@0 20576 d32 = +HEAPF32[i31 >> 2];
michael@0 20577 i33 = i11 + 136 | 0;
michael@0 20578 d34 = +HEAPF32[i33 >> 2];
michael@0 20579 i35 = i11 + 140 | 0;
michael@0 20580 d36 = +HEAPF32[i35 >> 2];
michael@0 20581 if (d32 * d32 + d34 * d34 + d36 * d36 <= 9999999747378752.0e-20) {
michael@0 20582 break;
michael@0 20583 }
michael@0 20584 d37 = +HEAPF32[i29 >> 2];
michael@0 20585 if (d37 >= +HEAPF32[i30 >> 2]) {
michael@0 20586 break;
michael@0 20587 }
michael@0 20588 d38 = d32 * +HEAPF32[i1 >> 2] + d34 * +HEAPF32[i1 + 4 >> 2] + d36 * +HEAPF32[i1 + 8 >> 2];
michael@0 20589 d39 = d32 * +HEAPF32[i1 + 16 >> 2] + d34 * +HEAPF32[i1 + 20 >> 2] + d36 * +HEAPF32[i1 + 24 >> 2];
michael@0 20590 d40 = d32 * +HEAPF32[i1 + 32 >> 2] + d34 * +HEAPF32[i1 + 36 >> 2] + d36 * +HEAPF32[i1 + 40 >> 2];
michael@0 20591 HEAPF32[i11 + 144 >> 2] = 0.0;
michael@0 20592 d36 = 1.0 / +Math_sqrt(+(d38 * d38 + d39 * d39 + d40 * d40));
michael@0 20593 HEAPF32[i31 >> 2] = d38 * d36;
michael@0 20594 HEAPF32[i33 >> 2] = d39 * d36;
michael@0 20595 HEAPF32[i35 >> 2] = d40 * d36;
michael@0 20596 HEAP32[i14 >> 2] = i3;
michael@0 20597 HEAP32[i14 + 4 >> 2] = 0;
michael@0 20598 i35 = i14 + 8 | 0;
michael@0 20599 i33 = i12;
michael@0 20600 HEAP32[i35 >> 2] = HEAP32[i33 >> 2];
michael@0 20601 HEAP32[i35 + 4 >> 2] = HEAP32[i33 + 4 >> 2];
michael@0 20602 HEAP32[i35 + 8 >> 2] = HEAP32[i33 + 8 >> 2];
michael@0 20603 HEAP32[i35 + 12 >> 2] = HEAP32[i33 + 12 >> 2];
michael@0 20604 HEAPF32[i14 + 24 >> 2] = d37;
michael@0 20605 i33 = HEAP32[(HEAP32[i6 >> 2] | 0) + 12 >> 2] | 0;
michael@0 20606 +FUNCTION_TABLE_fiii[i33 & 15](i6, i14, 1);
michael@0 20607 }
michael@0 20608 } while (0);
michael@0 20609 __ZN12btConvexCastD2Ev(i13 | 0);
michael@0 20610 __ZN13btConvexShapeD2Ev(i28);
michael@0 20611 STACKTOP = i7;
michael@0 20612 return;
michael@0 20613 }
michael@0 20614 if ((i10 - 21 | 0) >>> 0 >= 9) {
michael@0 20615 if ((i10 | 0) != 31) {
michael@0 20616 __ZN13btConvexShapeD2Ev(i28);
michael@0 20617 STACKTOP = i7;
michael@0 20618 return;
michael@0 20619 }
michael@0 20620 i13 = i4;
michael@0 20621 i14 = HEAP32[i4 + 64 >> 2] | 0;
michael@0 20622 HEAP32[i23 >> 2] = 1752;
michael@0 20623 i11 = i23 + 4 | 0;
michael@0 20624 HEAP32[i11 >> 2] = i3;
michael@0 20625 i30 = i23 + 8 | 0;
michael@0 20626 HEAP32[i30 >> 2] = i13;
michael@0 20627 i29 = i23 + 12 | 0;
michael@0 20628 HEAP32[i29 >> 2] = i5;
michael@0 20629 i33 = i23 + 16 | 0;
michael@0 20630 HEAP32[i33 >> 2] = i1;
michael@0 20631 i35 = i23 + 20 | 0;
michael@0 20632 HEAP32[i35 >> 2] = i2;
michael@0 20633 i12 = i23 + 24 | 0;
michael@0 20634 HEAP32[i12 >> 2] = i6;
michael@0 20635 if ((i14 | 0) != 0) {
michael@0 20636 __ZNK11btTransform12inverseTimesERKS_(i25, i5, i1);
michael@0 20637 i31 = i24;
michael@0 20638 i41 = i25 + 48 | 0;
michael@0 20639 HEAP32[i31 >> 2] = HEAP32[i41 >> 2];
michael@0 20640 HEAP32[i31 + 4 >> 2] = HEAP32[i41 + 4 >> 2];
michael@0 20641 HEAP32[i31 + 8 >> 2] = HEAP32[i41 + 8 >> 2];
michael@0 20642 HEAP32[i31 + 12 >> 2] = HEAP32[i41 + 12 >> 2];
michael@0 20643 __ZNK11btTransform12inverseTimesERKS_(i27, i5, i2);
michael@0 20644 i41 = i26;
michael@0 20645 i31 = i27 + 48 | 0;
michael@0 20646 HEAP32[i41 >> 2] = HEAP32[i31 >> 2];
michael@0 20647 HEAP32[i41 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 20648 HEAP32[i41 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 20649 HEAP32[i41 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 20650 __ZN6btDbvt7rayTestEPK10btDbvtNodeRK9btVector3S5_RNS_8ICollideE(HEAP32[i14 >> 2] | 0, i24, i26, i23 | 0);
michael@0 20651 __ZN13btConvexShapeD2Ev(i28);
michael@0 20652 STACKTOP = i7;
michael@0 20653 return;
michael@0 20654 }
michael@0 20655 i23 = HEAP32[i4 + 16 >> 2] | 0;
michael@0 20656 if ((i23 | 0) <= 0) {
michael@0 20657 __ZN13btConvexShapeD2Ev(i28);
michael@0 20658 STACKTOP = i7;
michael@0 20659 return;
michael@0 20660 }
michael@0 20661 i26 = i9 | 0;
michael@0 20662 i24 = i9 + 4 | 0;
michael@0 20663 i14 = i9 + 8 | 0;
michael@0 20664 i31 = i9 + 12 | 0;
michael@0 20665 i41 = i9 + 14 | 0;
michael@0 20666 i27 = i9 + 16 | 0;
michael@0 20667 i25 = i9 + 20 | 0;
michael@0 20668 i42 = i9 + 24 | 0;
michael@0 20669 i43 = i9 | 0;
michael@0 20670 i9 = 0;
michael@0 20671 i44 = i13;
michael@0 20672 i13 = i5;
michael@0 20673 while (1) {
michael@0 20674 i45 = HEAP32[i44 + 24 >> 2] | 0;
michael@0 20675 i46 = HEAP32[i45 + (i9 * 80 | 0) + 64 >> 2] | 0;
michael@0 20676 __ZNK11btTransformmlERKS_(i8, i13, i45 + (i9 * 80 | 0) | 0);
michael@0 20677 i45 = (HEAP32[i11 >> 2] | 0) + 192 | 0;
michael@0 20678 i47 = HEAP32[i45 >> 2] | 0;
michael@0 20679 HEAP32[i45 >> 2] = i46;
michael@0 20680 i45 = HEAP32[i12 >> 2] | 0;
michael@0 20681 HEAPF32[i24 >> 2] = 1.0;
michael@0 20682 HEAP32[i14 >> 2] = 0;
michael@0 20683 HEAP16[i31 >> 1] = 1;
michael@0 20684 HEAP16[i41 >> 1] = -1;
michael@0 20685 HEAP32[i27 >> 2] = 0;
michael@0 20686 HEAP32[i26 >> 2] = 1864;
michael@0 20687 HEAP32[i25 >> 2] = i45;
michael@0 20688 HEAP32[i42 >> 2] = i9;
michael@0 20689 HEAPF32[i24 >> 2] = +HEAPF32[i45 + 4 >> 2];
michael@0 20690 __ZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackE(HEAP32[i33 >> 2] | 0, HEAP32[i35 >> 2] | 0, HEAP32[i11 >> 2] | 0, i46, i8, i43);
michael@0 20691 HEAP32[(HEAP32[i11 >> 2] | 0) + 192 >> 2] = i47;
michael@0 20692 i47 = i9 + 1 | 0;
michael@0 20693 if ((i47 | 0) >= (i23 | 0)) {
michael@0 20694 break;
michael@0 20695 }
michael@0 20696 i9 = i47;
michael@0 20697 i44 = HEAP32[i30 >> 2] | 0;
michael@0 20698 i13 = HEAP32[i29 >> 2] | 0;
michael@0 20699 }
michael@0 20700 __ZN13btConvexShapeD2Ev(i28);
michael@0 20701 STACKTOP = i7;
michael@0 20702 return;
michael@0 20703 }
michael@0 20704 if ((i10 | 0) == 21) {
michael@0 20705 d37 = +HEAPF32[i5 >> 2];
michael@0 20706 d36 = +HEAPF32[i5 + 16 >> 2];
michael@0 20707 d40 = +HEAPF32[i5 + 32 >> 2];
michael@0 20708 d39 = +HEAPF32[i5 + 4 >> 2];
michael@0 20709 d38 = +HEAPF32[i5 + 20 >> 2];
michael@0 20710 d34 = +HEAPF32[i5 + 36 >> 2];
michael@0 20711 d32 = +HEAPF32[i5 + 8 >> 2];
michael@0 20712 d48 = +HEAPF32[i5 + 24 >> 2];
michael@0 20713 d49 = +HEAPF32[i5 + 40 >> 2];
michael@0 20714 d50 = -0.0 - +HEAPF32[i5 + 48 >> 2];
michael@0 20715 d51 = -0.0 - +HEAPF32[i5 + 52 >> 2];
michael@0 20716 d52 = -0.0 - +HEAPF32[i5 + 56 >> 2];
michael@0 20717 d53 = d37 * d50 + d36 * d51 + d40 * d52;
michael@0 20718 d54 = d39 * d50 + d38 * d51 + d34 * d52;
michael@0 20719 d55 = d32 * d50 + d48 * d51 + d49 * d52;
michael@0 20720 d52 = +HEAPF32[i1 + 48 >> 2];
michael@0 20721 d51 = +HEAPF32[i1 + 52 >> 2];
michael@0 20722 d50 = +HEAPF32[i1 + 56 >> 2];
michael@0 20723 HEAPF32[i15 >> 2] = d53 + (d37 * d52 + d36 * d51 + d40 * d50);
michael@0 20724 HEAPF32[i15 + 4 >> 2] = d54 + (d39 * d52 + d38 * d51 + d34 * d50);
michael@0 20725 HEAPF32[i15 + 8 >> 2] = d55 + (d32 * d52 + d48 * d51 + d49 * d50);
michael@0 20726 HEAPF32[i15 + 12 >> 2] = 0.0;
michael@0 20727 d50 = +HEAPF32[i2 + 48 >> 2];
michael@0 20728 d51 = +HEAPF32[i2 + 52 >> 2];
michael@0 20729 d52 = +HEAPF32[i2 + 56 >> 2];
michael@0 20730 HEAPF32[i16 >> 2] = d53 + (d37 * d50 + d36 * d51 + d40 * d52);
michael@0 20731 HEAPF32[i16 + 4 >> 2] = d54 + (d39 * d50 + d38 * d51 + d34 * d52);
michael@0 20732 HEAPF32[i16 + 8 >> 2] = d55 + (d32 * d50 + d48 * d51 + d49 * d52);
michael@0 20733 HEAPF32[i16 + 12 >> 2] = 0.0;
michael@0 20734 __ZN25btTriangleRaycastCallbackC2ERK9btVector3S2_j(i17 | 0, i15, i16, HEAP32[i6 + 16 >> 2] | 0);
michael@0 20735 HEAP32[i17 >> 2] = 1832;
michael@0 20736 HEAP32[i17 + 44 >> 2] = i6;
michael@0 20737 HEAP32[i17 + 48 >> 2] = i3;
michael@0 20738 HEAP32[i17 + 52 >> 2] = i4;
michael@0 20739 i10 = i17 + 56 | 0;
michael@0 20740 i29 = i5;
michael@0 20741 HEAP32[i10 >> 2] = HEAP32[i29 >> 2];
michael@0 20742 HEAP32[i10 + 4 >> 2] = HEAP32[i29 + 4 >> 2];
michael@0 20743 HEAP32[i10 + 8 >> 2] = HEAP32[i29 + 8 >> 2];
michael@0 20744 HEAP32[i10 + 12 >> 2] = HEAP32[i29 + 12 >> 2];
michael@0 20745 i29 = i17 + 72 | 0;
michael@0 20746 i10 = i5 + 16 | 0;
michael@0 20747 HEAP32[i29 >> 2] = HEAP32[i10 >> 2];
michael@0 20748 HEAP32[i29 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 20749 HEAP32[i29 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 20750 HEAP32[i29 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 20751 i10 = i17 + 88 | 0;
michael@0 20752 i29 = i5 + 32 | 0;
michael@0 20753 HEAP32[i10 >> 2] = HEAP32[i29 >> 2];
michael@0 20754 HEAP32[i10 + 4 >> 2] = HEAP32[i29 + 4 >> 2];
michael@0 20755 HEAP32[i10 + 8 >> 2] = HEAP32[i29 + 8 >> 2];
michael@0 20756 HEAP32[i10 + 12 >> 2] = HEAP32[i29 + 12 >> 2];
michael@0 20757 i29 = i17 + 104 | 0;
michael@0 20758 i10 = i5 + 48 | 0;
michael@0 20759 HEAP32[i29 >> 2] = HEAP32[i10 >> 2];
michael@0 20760 HEAP32[i29 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 20761 HEAP32[i29 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 20762 HEAP32[i29 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 20763 HEAPF32[i17 + 40 >> 2] = +HEAPF32[i6 + 4 >> 2];
michael@0 20764 i10 = i17 | 0;
michael@0 20765 __ZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_(i4, i10, i15, i16);
michael@0 20766 __ZN18btTriangleCallbackD2Ev(i10);
michael@0 20767 __ZN13btConvexShapeD2Ev(i28);
michael@0 20768 STACKTOP = i7;
michael@0 20769 return;
michael@0 20770 }
michael@0 20771 i10 = i4;
michael@0 20772 d52 = +HEAPF32[i5 >> 2];
michael@0 20773 d49 = +HEAPF32[i5 + 16 >> 2];
michael@0 20774 d51 = +HEAPF32[i5 + 32 >> 2];
michael@0 20775 d48 = +HEAPF32[i5 + 4 >> 2];
michael@0 20776 d50 = +HEAPF32[i5 + 20 >> 2];
michael@0 20777 d32 = +HEAPF32[i5 + 36 >> 2];
michael@0 20778 d55 = +HEAPF32[i5 + 8 >> 2];
michael@0 20779 d34 = +HEAPF32[i5 + 24 >> 2];
michael@0 20780 d38 = +HEAPF32[i5 + 40 >> 2];
michael@0 20781 d39 = -0.0 - +HEAPF32[i5 + 48 >> 2];
michael@0 20782 d54 = -0.0 - +HEAPF32[i5 + 52 >> 2];
michael@0 20783 d40 = -0.0 - +HEAPF32[i5 + 56 >> 2];
michael@0 20784 d36 = d52 * d39 + d49 * d54 + d51 * d40;
michael@0 20785 d37 = d48 * d39 + d50 * d54 + d32 * d40;
michael@0 20786 d53 = d55 * d39 + d34 * d54 + d38 * d40;
michael@0 20787 d40 = +HEAPF32[i1 + 48 >> 2];
michael@0 20788 d54 = +HEAPF32[i1 + 52 >> 2];
michael@0 20789 d39 = +HEAPF32[i1 + 56 >> 2];
michael@0 20790 HEAPF32[i18 >> 2] = d36 + (d52 * d40 + d49 * d54 + d51 * d39);
michael@0 20791 HEAPF32[i18 + 4 >> 2] = d37 + (d48 * d40 + d50 * d54 + d32 * d39);
michael@0 20792 HEAPF32[i18 + 8 >> 2] = d53 + (d55 * d40 + d34 * d54 + d38 * d39);
michael@0 20793 HEAPF32[i18 + 12 >> 2] = 0.0;
michael@0 20794 d39 = +HEAPF32[i2 + 48 >> 2];
michael@0 20795 d54 = +HEAPF32[i2 + 52 >> 2];
michael@0 20796 d40 = +HEAPF32[i2 + 56 >> 2];
michael@0 20797 i2 = i19 | 0;
michael@0 20798 HEAPF32[i2 >> 2] = d36 + (d52 * d39 + d49 * d54 + d51 * d40);
michael@0 20799 i1 = i19 + 4 | 0;
michael@0 20800 HEAPF32[i1 >> 2] = d37 + (d48 * d39 + d50 * d54 + d32 * d40);
michael@0 20801 i16 = i19 + 8 | 0;
michael@0 20802 HEAPF32[i16 >> 2] = d53 + (d55 * d39 + d34 * d54 + d38 * d40);
michael@0 20803 i15 = i19 + 12 | 0;
michael@0 20804 HEAPF32[i15 >> 2] = 0.0;
michael@0 20805 __ZN25btTriangleRaycastCallbackC2ERK9btVector3S2_j(i20 | 0, i18, i19, HEAP32[i6 + 16 >> 2] | 0);
michael@0 20806 HEAP32[i20 >> 2] = 1800;
michael@0 20807 HEAP32[i20 + 44 >> 2] = i6;
michael@0 20808 HEAP32[i20 + 48 >> 2] = i3;
michael@0 20809 HEAP32[i20 + 52 >> 2] = i10;
michael@0 20810 i3 = i20 + 56 | 0;
michael@0 20811 i19 = i5;
michael@0 20812 HEAP32[i3 >> 2] = HEAP32[i19 >> 2];
michael@0 20813 HEAP32[i3 + 4 >> 2] = HEAP32[i19 + 4 >> 2];
michael@0 20814 HEAP32[i3 + 8 >> 2] = HEAP32[i19 + 8 >> 2];
michael@0 20815 HEAP32[i3 + 12 >> 2] = HEAP32[i19 + 12 >> 2];
michael@0 20816 i19 = i20 + 72 | 0;
michael@0 20817 i3 = i5 + 16 | 0;
michael@0 20818 HEAP32[i19 >> 2] = HEAP32[i3 >> 2];
michael@0 20819 HEAP32[i19 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 20820 HEAP32[i19 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 20821 HEAP32[i19 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 20822 i3 = i20 + 88 | 0;
michael@0 20823 i19 = i5 + 32 | 0;
michael@0 20824 HEAP32[i3 >> 2] = HEAP32[i19 >> 2];
michael@0 20825 HEAP32[i3 + 4 >> 2] = HEAP32[i19 + 4 >> 2];
michael@0 20826 HEAP32[i3 + 8 >> 2] = HEAP32[i19 + 8 >> 2];
michael@0 20827 HEAP32[i3 + 12 >> 2] = HEAP32[i19 + 12 >> 2];
michael@0 20828 i19 = i20 + 104 | 0;
michael@0 20829 i3 = i5 + 48 | 0;
michael@0 20830 HEAP32[i19 >> 2] = HEAP32[i3 >> 2];
michael@0 20831 HEAP32[i19 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 20832 HEAP32[i19 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 20833 HEAP32[i19 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 20834 HEAPF32[i20 + 40 >> 2] = +HEAPF32[i6 + 4 >> 2];
michael@0 20835 i6 = i21;
michael@0 20836 i3 = i18;
michael@0 20837 HEAP32[i6 >> 2] = HEAP32[i3 >> 2];
michael@0 20838 HEAP32[i6 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 20839 HEAP32[i6 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 20840 HEAP32[i6 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 20841 i6 = i21 | 0;
michael@0 20842 d40 = +HEAPF32[i2 >> 2];
michael@0 20843 if (d40 < +HEAPF32[i6 >> 2]) {
michael@0 20844 HEAPF32[i6 >> 2] = d40;
michael@0 20845 }
michael@0 20846 i6 = i21 + 4 | 0;
michael@0 20847 d38 = +HEAPF32[i1 >> 2];
michael@0 20848 if (d38 < +HEAPF32[i6 >> 2]) {
michael@0 20849 HEAPF32[i6 >> 2] = d38;
michael@0 20850 }
michael@0 20851 i6 = i21 + 8 | 0;
michael@0 20852 d54 = +HEAPF32[i16 >> 2];
michael@0 20853 if (d54 < +HEAPF32[i6 >> 2]) {
michael@0 20854 HEAPF32[i6 >> 2] = d54;
michael@0 20855 }
michael@0 20856 i6 = i21 + 12 | 0;
michael@0 20857 d34 = +HEAPF32[i15 >> 2];
michael@0 20858 if (d34 < +HEAPF32[i6 >> 2]) {
michael@0 20859 HEAPF32[i6 >> 2] = d34;
michael@0 20860 }
michael@0 20861 i6 = i22;
michael@0 20862 HEAP32[i6 >> 2] = HEAP32[i3 >> 2];
michael@0 20863 HEAP32[i6 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 20864 HEAP32[i6 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 20865 HEAP32[i6 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 20866 i3 = i22 | 0;
michael@0 20867 if (+HEAPF32[i3 >> 2] < d40) {
michael@0 20868 HEAPF32[i3 >> 2] = d40;
michael@0 20869 }
michael@0 20870 i3 = i22 + 4 | 0;
michael@0 20871 if (+HEAPF32[i3 >> 2] < d38) {
michael@0 20872 HEAPF32[i3 >> 2] = d38;
michael@0 20873 }
michael@0 20874 i3 = i22 + 8 | 0;
michael@0 20875 if (+HEAPF32[i3 >> 2] < d54) {
michael@0 20876 HEAPF32[i3 >> 2] = d54;
michael@0 20877 }
michael@0 20878 i3 = i22 + 12 | 0;
michael@0 20879 if (+HEAPF32[i3 >> 2] < d34) {
michael@0 20880 HEAPF32[i3 >> 2] = d34;
michael@0 20881 }
michael@0 20882 i3 = i20 | 0;
michael@0 20883 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i4 >> 2] | 0) + 60 >> 2] & 127](i10, i3, i21, i22);
michael@0 20884 __ZN18btTriangleCallbackD2Ev(i3);
michael@0 20885 __ZN13btConvexShapeD2Ev(i28);
michael@0 20886 STACKTOP = i7;
michael@0 20887 return;
michael@0 20888 }
michael@0 20889 function __ZN28btCompoundCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 20890 i1 = i1 | 0;
michael@0 20891 i2 = i2 | 0;
michael@0 20892 i3 = i3 | 0;
michael@0 20893 i4 = i4 | 0;
michael@0 20894 i5 = i5 | 0;
michael@0 20895 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, d61 = 0.0, d62 = 0.0, d63 = 0.0, d64 = 0.0, d65 = 0.0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0;
michael@0 20896 i6 = STACKTOP;
michael@0 20897 STACKTOP = STACKTOP + 312 | 0;
michael@0 20898 i7 = i6 | 0;
michael@0 20899 i8 = i6 + 32 | 0;
michael@0 20900 i9 = i6 + 56 | 0;
michael@0 20901 i10 = i6 + 72 | 0;
michael@0 20902 i11 = i6 + 88 | 0;
michael@0 20903 i12 = i6 + 152 | 0;
michael@0 20904 i13 = i6 + 184 | 0;
michael@0 20905 i14 = i6 + 248 | 0;
michael@0 20906 i15 = i6 + 264 | 0;
michael@0 20907 i16 = i6 + 280 | 0;
michael@0 20908 i17 = i6 + 296 | 0;
michael@0 20909 i18 = (HEAP8[i1 + 28 | 0] | 0) != 0;
michael@0 20910 i19 = i18 ? i3 : i2;
michael@0 20911 i20 = i18 ? i2 : i3;
michael@0 20912 i18 = HEAP32[i19 + 192 >> 2] | 0;
michael@0 20913 i21 = i1 + 12 | 0;
michael@0 20914 if ((HEAP32[i18 + 68 >> 2] | 0) != (HEAP32[i1 + 40 >> 2] | 0)) {
michael@0 20915 i22 = HEAP32[i21 >> 2] | 0;
michael@0 20916 if ((i22 | 0) > 0) {
michael@0 20917 i23 = i1 + 20 | 0;
michael@0 20918 i24 = i1 + 4 | 0;
michael@0 20919 i25 = 0;
michael@0 20920 do {
michael@0 20921 i26 = HEAP32[(HEAP32[i23 >> 2] | 0) + (i25 << 2) >> 2] | 0;
michael@0 20922 if ((i26 | 0) != 0) {
michael@0 20923 FUNCTION_TABLE_vi[HEAP32[HEAP32[i26 >> 2] >> 2] & 511](i26);
michael@0 20924 i26 = HEAP32[i24 >> 2] | 0;
michael@0 20925 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i26 >> 2] | 0) + 60 >> 2] & 127](i26, HEAP32[(HEAP32[i23 >> 2] | 0) + (i25 << 2) >> 2] | 0);
michael@0 20926 }
michael@0 20927 i25 = i25 + 1 | 0;
michael@0 20928 } while ((i25 | 0) < (i22 | 0));
michael@0 20929 }
michael@0 20930 __ZN28btCompoundCollisionAlgorithm26preallocateChildAlgorithmsEP17btCollisionObjectS1_(i1, i2, i3);
michael@0 20931 }
michael@0 20932 i3 = HEAP32[i18 + 64 >> 2] | 0;
michael@0 20933 i2 = i1 + 4 | 0;
michael@0 20934 i22 = HEAP32[i2 >> 2] | 0;
michael@0 20935 i25 = i1 + 20 | 0;
michael@0 20936 i23 = HEAP32[i25 >> 2] | 0;
michael@0 20937 i24 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 20938 HEAP32[i7 >> 2] = 3568;
michael@0 20939 HEAP32[i7 + 4 >> 2] = i19;
michael@0 20940 HEAP32[i7 + 8 >> 2] = i20;
michael@0 20941 HEAP32[i7 + 12 >> 2] = i22;
michael@0 20942 HEAP32[i7 + 16 >> 2] = i4;
michael@0 20943 HEAP32[i7 + 20 >> 2] = i5;
michael@0 20944 HEAP32[i7 + 24 >> 2] = i23;
michael@0 20945 HEAP32[i7 + 28 >> 2] = i24;
michael@0 20946 i24 = i8 + 16 | 0;
michael@0 20947 HEAP8[i24] = 1;
michael@0 20948 i4 = i8 + 12 | 0;
michael@0 20949 HEAP32[i4 >> 2] = 0;
michael@0 20950 i22 = i8 + 4 | 0;
michael@0 20951 HEAP32[i22 >> 2] = 0;
michael@0 20952 i1 = i8 + 8 | 0;
michael@0 20953 HEAP32[i1 >> 2] = 0;
michael@0 20954 i26 = HEAP32[i21 >> 2] | 0;
michael@0 20955 do {
michael@0 20956 if ((i26 | 0) > 0) {
michael@0 20957 i27 = i5 + 4 | 0;
michael@0 20958 i28 = i5 + 136 | 0;
michael@0 20959 i29 = i5 + 8 | 0;
michael@0 20960 i30 = i5 + 72 | 0;
michael@0 20961 i31 = 0;
michael@0 20962 i32 = i26;
michael@0 20963 i33 = i23;
michael@0 20964 while (1) {
michael@0 20965 i34 = HEAP32[i33 + (i31 << 2) >> 2] | 0;
michael@0 20966 if ((i34 | 0) == 0) {
michael@0 20967 i35 = i32;
michael@0 20968 } else {
michael@0 20969 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i34 >> 2] | 0) + 16 >> 2] & 127](i34, i8);
michael@0 20970 i34 = HEAP32[i22 >> 2] | 0;
michael@0 20971 if ((i34 | 0) > 0) {
michael@0 20972 i36 = 0;
michael@0 20973 i37 = i34;
michael@0 20974 while (1) {
michael@0 20975 i38 = HEAP32[(HEAP32[i4 >> 2] | 0) + (i36 << 2) >> 2] | 0;
michael@0 20976 if ((HEAP32[i38 + 1116 >> 2] | 0) == 0) {
michael@0 20977 i39 = i37;
michael@0 20978 } else {
michael@0 20979 HEAP32[i27 >> 2] = i38;
michael@0 20980 if ((HEAP32[i38 + 1108 >> 2] | 0) == (HEAP32[i28 >> 2] | 0)) {
michael@0 20981 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i38, i29, i30);
michael@0 20982 } else {
michael@0 20983 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i38, i30, i29);
michael@0 20984 }
michael@0 20985 HEAP32[i27 >> 2] = 0;
michael@0 20986 i39 = HEAP32[i22 >> 2] | 0;
michael@0 20987 }
michael@0 20988 i38 = i36 + 1 | 0;
michael@0 20989 if ((i38 | 0) < (i39 | 0)) {
michael@0 20990 i36 = i38;
michael@0 20991 i37 = i39;
michael@0 20992 } else {
michael@0 20993 i40 = i39;
michael@0 20994 break;
michael@0 20995 }
michael@0 20996 }
michael@0 20997 } else {
michael@0 20998 i40 = i34;
michael@0 20999 }
michael@0 21000 if ((i40 | 0) < 0) {
michael@0 21001 if ((HEAP32[i1 >> 2] | 0) < 0) {
michael@0 21002 i37 = HEAP32[i4 >> 2] | 0;
michael@0 21003 if ((i40 | 0) > 0) {
michael@0 21004 i36 = 0;
michael@0 21005 do {
michael@0 21006 if ((i36 | 0) != 0) {
michael@0 21007 HEAP32[i36 << 2 >> 2] = HEAP32[i37 + (i36 << 2) >> 2];
michael@0 21008 }
michael@0 21009 i36 = i36 + 1 | 0;
michael@0 21010 } while ((i36 | 0) < (i40 | 0));
michael@0 21011 }
michael@0 21012 if ((i37 | 0) != 0) {
michael@0 21013 if ((HEAP8[i24] | 0) != 0) {
michael@0 21014 __Z21btAlignedFreeInternalPv(i37);
michael@0 21015 }
michael@0 21016 HEAP32[i4 >> 2] = 0;
michael@0 21017 }
michael@0 21018 HEAP8[i24] = 1;
michael@0 21019 HEAP32[i4 >> 2] = 0;
michael@0 21020 HEAP32[i1 >> 2] = 0;
michael@0 21021 i41 = i40;
michael@0 21022 } else {
michael@0 21023 i41 = i40;
michael@0 21024 }
michael@0 21025 do {
michael@0 21026 i36 = (HEAP32[i4 >> 2] | 0) + (i41 << 2) | 0;
michael@0 21027 if ((i36 | 0) != 0) {
michael@0 21028 HEAP32[i36 >> 2] = 0;
michael@0 21029 }
michael@0 21030 i41 = i41 + 1 | 0;
michael@0 21031 } while ((i41 | 0) < 0);
michael@0 21032 }
michael@0 21033 HEAP32[i22 >> 2] = 0;
michael@0 21034 i35 = HEAP32[i21 >> 2] | 0;
michael@0 21035 }
michael@0 21036 i37 = i31 + 1 | 0;
michael@0 21037 if ((i37 | 0) >= (i35 | 0)) {
michael@0 21038 break;
michael@0 21039 }
michael@0 21040 i31 = i37;
michael@0 21041 i32 = i35;
michael@0 21042 i33 = HEAP32[i25 >> 2] | 0;
michael@0 21043 }
michael@0 21044 i33 = HEAP32[i4 >> 2] | 0;
michael@0 21045 if ((i33 | 0) == 0) {
michael@0 21046 break;
michael@0 21047 }
michael@0 21048 if ((HEAP8[i24] | 0) != 0) {
michael@0 21049 __Z21btAlignedFreeInternalPv(i33);
michael@0 21050 }
michael@0 21051 HEAP32[i4 >> 2] = 0;
michael@0 21052 }
michael@0 21053 } while (0);
michael@0 21054 HEAP8[i24] = 1;
michael@0 21055 HEAP32[i4 >> 2] = 0;
michael@0 21056 HEAP32[i22 >> 2] = 0;
michael@0 21057 HEAP32[i1 >> 2] = 0;
michael@0 21058 if ((i3 | 0) == 0) {
michael@0 21059 i1 = HEAP32[i21 >> 2] | 0;
michael@0 21060 if ((i1 | 0) <= 0) {
michael@0 21061 STACKTOP = i6;
michael@0 21062 return;
michael@0 21063 }
michael@0 21064 i22 = i18 + 24 | 0;
michael@0 21065 i4 = 0;
michael@0 21066 do {
michael@0 21067 __ZN22btCompoundLeafCallback17ProcessChildShapeEP16btCollisionShapei(i7, HEAP32[(HEAP32[i22 >> 2] | 0) + (i4 * 80 | 0) + 64 >> 2] | 0, i4);
michael@0 21068 i4 = i4 + 1 | 0;
michael@0 21069 } while ((i4 | 0) < (i1 | 0));
michael@0 21070 } else {
michael@0 21071 d42 = +HEAPF32[i19 + 4 >> 2];
michael@0 21072 d43 = +HEAPF32[i19 + 20 >> 2];
michael@0 21073 d44 = +HEAPF32[i19 + 36 >> 2];
michael@0 21074 d45 = +HEAPF32[i19 + 8 >> 2];
michael@0 21075 d46 = +HEAPF32[i19 + 24 >> 2];
michael@0 21076 d47 = +HEAPF32[i19 + 40 >> 2];
michael@0 21077 d48 = +HEAPF32[i19 + 12 >> 2];
michael@0 21078 d49 = +HEAPF32[i19 + 28 >> 2];
michael@0 21079 d50 = +HEAPF32[i19 + 44 >> 2];
michael@0 21080 d51 = -0.0 - +HEAPF32[i19 + 52 >> 2];
michael@0 21081 d52 = -0.0 - +HEAPF32[i19 + 56 >> 2];
michael@0 21082 d53 = -0.0 - +HEAPF32[i19 + 60 >> 2];
michael@0 21083 d54 = +HEAPF32[i20 + 4 >> 2];
michael@0 21084 d55 = +HEAPF32[i20 + 20 >> 2];
michael@0 21085 d56 = +HEAPF32[i20 + 36 >> 2];
michael@0 21086 d57 = +HEAPF32[i20 + 8 >> 2];
michael@0 21087 d58 = +HEAPF32[i20 + 24 >> 2];
michael@0 21088 d59 = +HEAPF32[i20 + 40 >> 2];
michael@0 21089 d60 = +HEAPF32[i20 + 12 >> 2];
michael@0 21090 d61 = +HEAPF32[i20 + 28 >> 2];
michael@0 21091 d62 = +HEAPF32[i20 + 44 >> 2];
michael@0 21092 d63 = +HEAPF32[i20 + 52 >> 2];
michael@0 21093 d64 = +HEAPF32[i20 + 56 >> 2];
michael@0 21094 d65 = +HEAPF32[i20 + 60 >> 2];
michael@0 21095 HEAPF32[i11 >> 2] = d42 * d54 + d43 * d55 + d44 * d56;
michael@0 21096 HEAPF32[i11 + 4 >> 2] = d42 * d57 + d43 * d58 + d44 * d59;
michael@0 21097 HEAPF32[i11 + 8 >> 2] = d42 * d60 + d43 * d61 + d44 * d62;
michael@0 21098 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 21099 HEAPF32[i11 + 16 >> 2] = d45 * d54 + d46 * d55 + d47 * d56;
michael@0 21100 HEAPF32[i11 + 20 >> 2] = d45 * d57 + d46 * d58 + d47 * d59;
michael@0 21101 HEAPF32[i11 + 24 >> 2] = d45 * d60 + d46 * d61 + d47 * d62;
michael@0 21102 HEAPF32[i11 + 28 >> 2] = 0.0;
michael@0 21103 HEAPF32[i11 + 32 >> 2] = d48 * d54 + d49 * d55 + d50 * d56;
michael@0 21104 HEAPF32[i11 + 36 >> 2] = d48 * d57 + d49 * d58 + d50 * d59;
michael@0 21105 HEAPF32[i11 + 40 >> 2] = d48 * d60 + d49 * d61 + d50 * d62;
michael@0 21106 HEAPF32[i11 + 44 >> 2] = 0.0;
michael@0 21107 HEAPF32[i11 + 48 >> 2] = d42 * d51 + d43 * d52 + d44 * d53 + (d42 * d63 + d43 * d64 + d44 * d65);
michael@0 21108 HEAPF32[i11 + 52 >> 2] = d45 * d51 + d46 * d52 + d47 * d53 + (d45 * d63 + d46 * d64 + d47 * d65);
michael@0 21109 HEAPF32[i11 + 56 >> 2] = d48 * d51 + d49 * d52 + d50 * d53 + (d48 * d63 + d49 * d64 + d50 * d65);
michael@0 21110 HEAPF32[i11 + 60 >> 2] = 0.0;
michael@0 21111 i1 = HEAP32[i20 + 192 >> 2] | 0;
michael@0 21112 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i1, i11, i9, i10);
michael@0 21113 i11 = i12;
michael@0 21114 i1 = i9;
michael@0 21115 HEAP32[i11 >> 2] = HEAP32[i1 >> 2];
michael@0 21116 HEAP32[i11 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 21117 HEAP32[i11 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 21118 HEAP32[i11 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 21119 i1 = i12 + 16 | 0;
michael@0 21120 i11 = i10;
michael@0 21121 HEAP32[i1 >> 2] = HEAP32[i11 >> 2];
michael@0 21122 HEAP32[i1 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 21123 HEAP32[i1 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 21124 HEAP32[i1 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 21125 __ZN6btDbvt9collideTVEPK10btDbvtNodeRK12btDbvtAabbMmRNS_8ICollideE(0, HEAP32[i3 >> 2] | 0, i12, i7 | 0);
michael@0 21126 }
michael@0 21127 i7 = HEAP32[i21 >> 2] | 0;
michael@0 21128 if ((i7 | 0) <= 0) {
michael@0 21129 STACKTOP = i6;
michael@0 21130 return;
michael@0 21131 }
michael@0 21132 i21 = i18 + 24 | 0;
michael@0 21133 i18 = i19 + 4 | 0;
michael@0 21134 i12 = i19 + 8 | 0;
michael@0 21135 i3 = i19 + 12 | 0;
michael@0 21136 i11 = i19 + 20 | 0;
michael@0 21137 i1 = i19 + 24 | 0;
michael@0 21138 i10 = i19 + 28 | 0;
michael@0 21139 i9 = i19 + 36 | 0;
michael@0 21140 i4 = i19 + 40 | 0;
michael@0 21141 i22 = i19 + 44 | 0;
michael@0 21142 i24 = i19 + 52 | 0;
michael@0 21143 i35 = i19 + 56 | 0;
michael@0 21144 i41 = i19 + 60 | 0;
michael@0 21145 i19 = i13 | 0;
michael@0 21146 i40 = i13 + 4 | 0;
michael@0 21147 i39 = i13 + 8 | 0;
michael@0 21148 i8 = i13 + 12 | 0;
michael@0 21149 i23 = i13 + 16 | 0;
michael@0 21150 i26 = i13 + 20 | 0;
michael@0 21151 i5 = i13 + 24 | 0;
michael@0 21152 i33 = i13 + 28 | 0;
michael@0 21153 i32 = i13 + 32 | 0;
michael@0 21154 i31 = i13 + 36 | 0;
michael@0 21155 i27 = i13 + 40 | 0;
michael@0 21156 i29 = i13 + 44 | 0;
michael@0 21157 i30 = i13 + 48 | 0;
michael@0 21158 i28 = i13 + 52 | 0;
michael@0 21159 i37 = i13 + 56 | 0;
michael@0 21160 i36 = i13 + 60 | 0;
michael@0 21161 i34 = i20 + 192 | 0;
michael@0 21162 i38 = i20 + 4 | 0;
michael@0 21163 i20 = i14 | 0;
michael@0 21164 i66 = i17 | 0;
michael@0 21165 i67 = i14 + 8 | 0;
michael@0 21166 i68 = i17 + 8 | 0;
michael@0 21167 i69 = i14 + 4 | 0;
michael@0 21168 i70 = i17 + 4 | 0;
michael@0 21169 i71 = i15 + 4 | 0;
michael@0 21170 i72 = i16 + 4 | 0;
michael@0 21171 i73 = i15 + 8 | 0;
michael@0 21172 i74 = i16 + 8 | 0;
michael@0 21173 i75 = i15 | 0;
michael@0 21174 i76 = i16 | 0;
michael@0 21175 i77 = 0;
michael@0 21176 do {
michael@0 21177 do {
michael@0 21178 if ((HEAP32[(HEAP32[i25 >> 2] | 0) + (i77 << 2) >> 2] | 0) != 0) {
michael@0 21179 i78 = HEAP32[i21 >> 2] | 0;
michael@0 21180 i79 = HEAP32[i78 + (i77 * 80 | 0) + 64 >> 2] | 0;
michael@0 21181 d65 = +HEAPF32[i18 >> 2];
michael@0 21182 d50 = +HEAPF32[i12 >> 2];
michael@0 21183 d64 = +HEAPF32[i3 >> 2];
michael@0 21184 d49 = +HEAPF32[i11 >> 2];
michael@0 21185 d63 = +HEAPF32[i1 >> 2];
michael@0 21186 d48 = +HEAPF32[i10 >> 2];
michael@0 21187 d53 = +HEAPF32[i9 >> 2];
michael@0 21188 d52 = +HEAPF32[i4 >> 2];
michael@0 21189 d51 = +HEAPF32[i22 >> 2];
michael@0 21190 d47 = +HEAPF32[i78 + (i77 * 80 | 0) >> 2];
michael@0 21191 d46 = +HEAPF32[i78 + (i77 * 80 | 0) + 16 >> 2];
michael@0 21192 d45 = +HEAPF32[i78 + (i77 * 80 | 0) + 32 >> 2];
michael@0 21193 d44 = +HEAPF32[i78 + (i77 * 80 | 0) + 4 >> 2];
michael@0 21194 d43 = +HEAPF32[i78 + (i77 * 80 | 0) + 20 >> 2];
michael@0 21195 d42 = +HEAPF32[i78 + (i77 * 80 | 0) + 36 >> 2];
michael@0 21196 d62 = +HEAPF32[i78 + (i77 * 80 | 0) + 8 >> 2];
michael@0 21197 d61 = +HEAPF32[i78 + (i77 * 80 | 0) + 24 >> 2];
michael@0 21198 d60 = +HEAPF32[i78 + (i77 * 80 | 0) + 40 >> 2];
michael@0 21199 d59 = +HEAPF32[i78 + (i77 * 80 | 0) + 48 >> 2];
michael@0 21200 d58 = +HEAPF32[i78 + (i77 * 80 | 0) + 52 >> 2];
michael@0 21201 d57 = +HEAPF32[i78 + (i77 * 80 | 0) + 56 >> 2];
michael@0 21202 d56 = +HEAPF32[i24 >> 2] + (d65 * d59 + d50 * d58 + d64 * d57);
michael@0 21203 d55 = +HEAPF32[i35 >> 2] + (d49 * d59 + d63 * d58 + d48 * d57);
michael@0 21204 d54 = +HEAPF32[i41 >> 2] + (d53 * d59 + d52 * d58 + d51 * d57);
michael@0 21205 HEAPF32[i19 >> 2] = d65 * d47 + d50 * d46 + d64 * d45;
michael@0 21206 HEAPF32[i40 >> 2] = d65 * d44 + d50 * d43 + d64 * d42;
michael@0 21207 HEAPF32[i39 >> 2] = d65 * d62 + d50 * d61 + d64 * d60;
michael@0 21208 HEAPF32[i8 >> 2] = 0.0;
michael@0 21209 HEAPF32[i23 >> 2] = d49 * d47 + d63 * d46 + d48 * d45;
michael@0 21210 HEAPF32[i26 >> 2] = d49 * d44 + d63 * d43 + d48 * d42;
michael@0 21211 HEAPF32[i5 >> 2] = d49 * d62 + d63 * d61 + d48 * d60;
michael@0 21212 HEAPF32[i33 >> 2] = 0.0;
michael@0 21213 HEAPF32[i32 >> 2] = d53 * d47 + d52 * d46 + d51 * d45;
michael@0 21214 HEAPF32[i31 >> 2] = d53 * d44 + d52 * d43 + d51 * d42;
michael@0 21215 HEAPF32[i27 >> 2] = d53 * d62 + d52 * d61 + d51 * d60;
michael@0 21216 HEAPF32[i29 >> 2] = 0.0;
michael@0 21217 HEAPF32[i30 >> 2] = d56;
michael@0 21218 HEAPF32[i28 >> 2] = d55;
michael@0 21219 HEAPF32[i37 >> 2] = d54;
michael@0 21220 HEAPF32[i36 >> 2] = 0.0;
michael@0 21221 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i79 >> 2] | 0) + 8 >> 2] & 127](i79, i13, i14, i15);
michael@0 21222 i79 = HEAP32[i34 >> 2] | 0;
michael@0 21223 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i79 >> 2] | 0) + 8 >> 2] & 127](i79, i38, i16, i17);
michael@0 21224 do {
michael@0 21225 if (+HEAPF32[i20 >> 2] > +HEAPF32[i66 >> 2]) {
michael@0 21226 i80 = 0;
michael@0 21227 } else {
michael@0 21228 if (+HEAPF32[i75 >> 2] < +HEAPF32[i76 >> 2]) {
michael@0 21229 i80 = 0;
michael@0 21230 break;
michael@0 21231 }
michael@0 21232 i80 = 1;
michael@0 21233 }
michael@0 21234 } while (0);
michael@0 21235 do {
michael@0 21236 if (+HEAPF32[i67 >> 2] > +HEAPF32[i68 >> 2]) {
michael@0 21237 i81 = 0;
michael@0 21238 } else {
michael@0 21239 if (+HEAPF32[i73 >> 2] < +HEAPF32[i74 >> 2]) {
michael@0 21240 i81 = 0;
michael@0 21241 break;
michael@0 21242 }
michael@0 21243 i81 = i80;
michael@0 21244 }
michael@0 21245 } while (0);
michael@0 21246 if (+HEAPF32[i69 >> 2] <= +HEAPF32[i70 >> 2]) {
michael@0 21247 if (!(+HEAPF32[i71 >> 2] < +HEAPF32[i72 >> 2] | i81 ^ 1)) {
michael@0 21248 break;
michael@0 21249 }
michael@0 21250 }
michael@0 21251 i79 = HEAP32[(HEAP32[i25 >> 2] | 0) + (i77 << 2) >> 2] | 0;
michael@0 21252 FUNCTION_TABLE_vi[HEAP32[HEAP32[i79 >> 2] >> 2] & 511](i79);
michael@0 21253 i79 = HEAP32[i2 >> 2] | 0;
michael@0 21254 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i79 >> 2] | 0) + 60 >> 2] & 127](i79, HEAP32[(HEAP32[i25 >> 2] | 0) + (i77 << 2) >> 2] | 0);
michael@0 21255 HEAP32[(HEAP32[i25 >> 2] | 0) + (i77 << 2) >> 2] = 0;
michael@0 21256 }
michael@0 21257 } while (0);
michael@0 21258 i77 = i77 + 1 | 0;
michael@0 21259 } while ((i77 | 0) < (i7 | 0));
michael@0 21260 STACKTOP = i6;
michael@0 21261 return;
michael@0 21262 }
michael@0 21263 function __ZN22btSubsimplexConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i1, i2, i3, i4, i5, i6) {
michael@0 21264 i1 = i1 | 0;
michael@0 21265 i2 = i2 | 0;
michael@0 21266 i3 = i3 | 0;
michael@0 21267 i4 = i4 | 0;
michael@0 21268 i5 = i5 | 0;
michael@0 21269 i6 = i6 | 0;
michael@0 21270 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, d25 = 0.0, i26 = 0, i27 = 0, d28 = 0.0, i29 = 0, d30 = 0.0, i31 = 0, i32 = 0, d33 = 0.0, i34 = 0, i35 = 0, d36 = 0.0, i37 = 0, d38 = 0.0, i39 = 0, d40 = 0.0, i41 = 0, d42 = 0.0, i43 = 0, d44 = 0.0, i45 = 0, d46 = 0.0, i47 = 0, d48 = 0.0, i49 = 0, d50 = 0.0, i51 = 0, d52 = 0.0, i53 = 0, d54 = 0.0, i55 = 0, d56 = 0.0, d57 = 0.0, i58 = 0, d59 = 0.0, i60 = 0, d61 = 0.0, i62 = 0, d63 = 0.0, i64 = 0, d65 = 0.0, i66 = 0, d67 = 0.0, i68 = 0, d69 = 0.0, i70 = 0, d71 = 0.0, i72 = 0, d73 = 0.0, d74 = 0.0, d75 = 0.0, d76 = 0.0, i77 = 0, i78 = 0, d79 = 0.0, d80 = 0.0, d81 = 0.0, d82 = 0.0, d83 = 0.0, d84 = 0.0, d85 = 0.0, d86 = 0.0, d87 = 0.0, i88 = 0, i89 = 0, i90 = 0, i91 = 0, i92 = 0, d93 = 0.0, d94 = 0.0, d95 = 0.0, i96 = 0, d97 = 0.0, d98 = 0.0, d99 = 0.0, d100 = 0.0, i101 = 0, d102 = 0.0, d103 = 0.0, d104 = 0.0, d105 = 0.0, i106 = 0, i107 = 0, d108 = 0.0, d109 = 0.0, d110 = 0.0, d111 = 0.0, d112 = 0.0, d113 = 0.0, d114 = 0.0, d115 = 0.0, d116 = 0.0, i117 = 0, i118 = 0, d119 = 0.0, d120 = 0.0, d121 = 0.0, d122 = 0.0, d123 = 0.0, d124 = 0.0, d125 = 0.0, d126 = 0.0, d127 = 0.0, d128 = 0.0, d129 = 0.0, d130 = 0.0, d131 = 0.0, d132 = 0.0, d133 = 0.0;
michael@0 21271 i7 = STACKTOP;
michael@0 21272 STACKTOP = STACKTOP + 224 | 0;
michael@0 21273 i8 = i7 | 0;
michael@0 21274 i9 = i7 + 16 | 0;
michael@0 21275 i10 = i7 + 32 | 0;
michael@0 21276 i11 = i7 + 48 | 0;
michael@0 21277 i12 = i7 + 64 | 0;
michael@0 21278 i13 = i7 + 80 | 0;
michael@0 21279 i14 = i7 + 96 | 0;
michael@0 21280 i15 = i7 + 112 | 0;
michael@0 21281 i16 = i7 + 128 | 0;
michael@0 21282 i17 = i7 + 144 | 0;
michael@0 21283 i18 = i7 + 160 | 0;
michael@0 21284 i19 = i7 + 176 | 0;
michael@0 21285 i20 = i7 + 192 | 0;
michael@0 21286 i21 = i7 + 208 | 0;
michael@0 21287 i22 = i1 + 4 | 0;
michael@0 21288 __ZN22btVoronoiSimplexSolver5resetEv(HEAP32[i22 >> 2] | 0);
michael@0 21289 i23 = i3 + 48 | 0;
michael@0 21290 i24 = i2 + 48 | 0;
michael@0 21291 d25 = +HEAPF32[i24 >> 2];
michael@0 21292 i26 = i3 + 52 | 0;
michael@0 21293 i27 = i2 + 52 | 0;
michael@0 21294 d28 = +HEAPF32[i27 >> 2];
michael@0 21295 i29 = i3 + 56 | 0;
michael@0 21296 i3 = i2 + 56 | 0;
michael@0 21297 d30 = +HEAPF32[i3 >> 2];
michael@0 21298 i31 = i5 + 48 | 0;
michael@0 21299 i32 = i4 + 48 | 0;
michael@0 21300 d33 = +HEAPF32[i32 >> 2];
michael@0 21301 i34 = i5 + 52 | 0;
michael@0 21302 i35 = i4 + 52 | 0;
michael@0 21303 d36 = +HEAPF32[i35 >> 2];
michael@0 21304 i37 = i5 + 56 | 0;
michael@0 21305 i5 = i4 + 56 | 0;
michael@0 21306 d38 = +HEAPF32[i5 >> 2];
michael@0 21307 i39 = i2 | 0;
michael@0 21308 d40 = +HEAPF32[i39 >> 2];
michael@0 21309 i41 = i2 + 4 | 0;
michael@0 21310 d42 = +HEAPF32[i41 >> 2];
michael@0 21311 i43 = i2 + 8 | 0;
michael@0 21312 d44 = +HEAPF32[i43 >> 2];
michael@0 21313 i45 = i2 + 16 | 0;
michael@0 21314 d46 = +HEAPF32[i45 >> 2];
michael@0 21315 i47 = i2 + 20 | 0;
michael@0 21316 d48 = +HEAPF32[i47 >> 2];
michael@0 21317 i49 = i2 + 24 | 0;
michael@0 21318 d50 = +HEAPF32[i49 >> 2];
michael@0 21319 i51 = i2 + 32 | 0;
michael@0 21320 d52 = +HEAPF32[i51 >> 2];
michael@0 21321 i53 = i2 + 36 | 0;
michael@0 21322 d54 = +HEAPF32[i53 >> 2];
michael@0 21323 i55 = i2 + 40 | 0;
michael@0 21324 d56 = +HEAPF32[i55 >> 2];
michael@0 21325 i2 = i4 | 0;
michael@0 21326 d57 = +HEAPF32[i2 >> 2];
michael@0 21327 i58 = i4 + 4 | 0;
michael@0 21328 d59 = +HEAPF32[i58 >> 2];
michael@0 21329 i60 = i4 + 8 | 0;
michael@0 21330 d61 = +HEAPF32[i60 >> 2];
michael@0 21331 i62 = i4 + 16 | 0;
michael@0 21332 d63 = +HEAPF32[i62 >> 2];
michael@0 21333 i64 = i4 + 20 | 0;
michael@0 21334 d65 = +HEAPF32[i64 >> 2];
michael@0 21335 i66 = i4 + 24 | 0;
michael@0 21336 d67 = +HEAPF32[i66 >> 2];
michael@0 21337 i68 = i4 + 32 | 0;
michael@0 21338 d69 = +HEAPF32[i68 >> 2];
michael@0 21339 i70 = i4 + 36 | 0;
michael@0 21340 d71 = +HEAPF32[i70 >> 2];
michael@0 21341 i72 = i4 + 40 | 0;
michael@0 21342 d73 = +HEAPF32[i72 >> 2];
michael@0 21343 d74 = +HEAPF32[i23 >> 2] - d25 - (+HEAPF32[i31 >> 2] - d33);
michael@0 21344 d75 = +HEAPF32[i26 >> 2] - d28 - (+HEAPF32[i34 >> 2] - d36);
michael@0 21345 d76 = +HEAPF32[i29 >> 2] - d30 - (+HEAPF32[i37 >> 2] - d38);
michael@0 21346 i4 = i1 + 8 | 0;
michael@0 21347 i77 = HEAP32[i4 >> 2] | 0;
michael@0 21348 i78 = HEAP32[(HEAP32[i77 >> 2] | 0) + 60 >> 2] | 0;
michael@0 21349 d79 = -0.0 - d74;
michael@0 21350 d80 = -0.0 - d75;
michael@0 21351 d81 = -0.0 - d76;
michael@0 21352 HEAPF32[i11 >> 2] = d40 * d79 + d46 * d80 + d52 * d81;
michael@0 21353 HEAPF32[i11 + 4 >> 2] = d42 * d79 + d48 * d80 + d54 * d81;
michael@0 21354 HEAPF32[i11 + 8 >> 2] = d44 * d79 + d50 * d80 + d56 * d81;
michael@0 21355 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 21356 FUNCTION_TABLE_viii[i78 & 127](i10, i77, i11);
michael@0 21357 d81 = +HEAPF32[i10 >> 2];
michael@0 21358 d80 = +HEAPF32[i10 + 4 >> 2];
michael@0 21359 d79 = +HEAPF32[i10 + 8 >> 2];
michael@0 21360 d82 = +HEAPF32[i24 >> 2] + (+HEAPF32[i39 >> 2] * d81 + +HEAPF32[i41 >> 2] * d80 + +HEAPF32[i43 >> 2] * d79);
michael@0 21361 d83 = +HEAPF32[i27 >> 2] + (d81 * +HEAPF32[i45 >> 2] + d80 * +HEAPF32[i47 >> 2] + d79 * +HEAPF32[i49 >> 2]);
michael@0 21362 d84 = +HEAPF32[i3 >> 2] + (d81 * +HEAPF32[i51 >> 2] + d80 * +HEAPF32[i53 >> 2] + d79 * +HEAPF32[i55 >> 2]);
michael@0 21363 i55 = i9 | 0;
michael@0 21364 HEAPF32[i55 >> 2] = d82;
michael@0 21365 i53 = i9 + 4 | 0;
michael@0 21366 HEAPF32[i53 >> 2] = d83;
michael@0 21367 i51 = i9 + 8 | 0;
michael@0 21368 HEAPF32[i51 >> 2] = d84;
michael@0 21369 i49 = i9 + 12 | 0;
michael@0 21370 HEAPF32[i49 >> 2] = 0.0;
michael@0 21371 i47 = i1 + 12 | 0;
michael@0 21372 i1 = HEAP32[i47 >> 2] | 0;
michael@0 21373 i45 = HEAP32[(HEAP32[i1 >> 2] | 0) + 60 >> 2] | 0;
michael@0 21374 d79 = d74 * +HEAPF32[i58 >> 2] + d75 * +HEAPF32[i64 >> 2] + d76 * +HEAPF32[i70 >> 2];
michael@0 21375 d80 = d74 * +HEAPF32[i60 >> 2] + d75 * +HEAPF32[i66 >> 2] + d76 * +HEAPF32[i72 >> 2];
michael@0 21376 HEAPF32[i14 >> 2] = d74 * +HEAPF32[i2 >> 2] + d75 * +HEAPF32[i62 >> 2] + d76 * +HEAPF32[i68 >> 2];
michael@0 21377 HEAPF32[i14 + 4 >> 2] = d79;
michael@0 21378 HEAPF32[i14 + 8 >> 2] = d80;
michael@0 21379 HEAPF32[i14 + 12 >> 2] = 0.0;
michael@0 21380 FUNCTION_TABLE_viii[i45 & 127](i13, i1, i14);
michael@0 21381 d80 = +HEAPF32[i13 >> 2];
michael@0 21382 d79 = +HEAPF32[i13 + 4 >> 2];
michael@0 21383 d81 = +HEAPF32[i13 + 8 >> 2];
michael@0 21384 d85 = +HEAPF32[i32 >> 2] + (+HEAPF32[i2 >> 2] * d80 + +HEAPF32[i58 >> 2] * d79 + +HEAPF32[i60 >> 2] * d81);
michael@0 21385 d86 = +HEAPF32[i35 >> 2] + (d80 * +HEAPF32[i62 >> 2] + d79 * +HEAPF32[i64 >> 2] + d81 * +HEAPF32[i66 >> 2]);
michael@0 21386 d87 = +HEAPF32[i5 >> 2] + (d80 * +HEAPF32[i68 >> 2] + d79 * +HEAPF32[i70 >> 2] + d81 * +HEAPF32[i72 >> 2]);
michael@0 21387 i72 = i12 | 0;
michael@0 21388 HEAPF32[i72 >> 2] = d85;
michael@0 21389 i70 = i12 + 4 | 0;
michael@0 21390 HEAPF32[i70 >> 2] = d86;
michael@0 21391 i68 = i12 + 8 | 0;
michael@0 21392 HEAPF32[i68 >> 2] = d87;
michael@0 21393 i66 = i12 + 12 | 0;
michael@0 21394 HEAPF32[i66 >> 2] = 0.0;
michael@0 21395 d81 = d82 - d85;
michael@0 21396 d85 = d83 - d86;
michael@0 21397 d86 = d84 - d87;
michael@0 21398 i64 = i8 | 0;
michael@0 21399 HEAPF32[i64 >> 2] = d81;
michael@0 21400 i62 = i8 + 4 | 0;
michael@0 21401 HEAPF32[i62 >> 2] = d85;
michael@0 21402 i60 = i8 + 8 | 0;
michael@0 21403 HEAPF32[i60 >> 2] = d86;
michael@0 21404 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 21405 L561 : do {
michael@0 21406 if (d81 * d81 + d85 * d85 + d86 * d86 > 9999999747378752.0e-20) {
michael@0 21407 i58 = i17 | 0;
michael@0 21408 i2 = i17 + 4 | 0;
michael@0 21409 i13 = i17 + 8 | 0;
michael@0 21410 i14 = i17 + 12 | 0;
michael@0 21411 i1 = i16 | 0;
michael@0 21412 i45 = i16 + 4 | 0;
michael@0 21413 i43 = i16 + 8 | 0;
michael@0 21414 i41 = i19 | 0;
michael@0 21415 i39 = i19 + 4 | 0;
michael@0 21416 i10 = i19 + 8 | 0;
michael@0 21417 i11 = i19 + 12 | 0;
michael@0 21418 i77 = i18 | 0;
michael@0 21419 i78 = i18 + 4 | 0;
michael@0 21420 i88 = i18 + 8 | 0;
michael@0 21421 i89 = i15 | 0;
michael@0 21422 i90 = i15 + 4 | 0;
michael@0 21423 i91 = i15 + 8 | 0;
michael@0 21424 i92 = i15 + 12 | 0;
michael@0 21425 d87 = d30;
michael@0 21426 d84 = d28;
michael@0 21427 d83 = d25;
michael@0 21428 d82 = d38;
michael@0 21429 d79 = d36;
michael@0 21430 d80 = d33;
michael@0 21431 d93 = 0.0;
michael@0 21432 d94 = 0.0;
michael@0 21433 d95 = 0.0;
michael@0 21434 i96 = 32;
michael@0 21435 d97 = 0.0;
michael@0 21436 d98 = d81;
michael@0 21437 d99 = d85;
michael@0 21438 d100 = d86;
michael@0 21439 while (1) {
michael@0 21440 i101 = i96 - 1 | 0;
michael@0 21441 if ((i96 | 0) == 0) {
michael@0 21442 d102 = d93;
michael@0 21443 d103 = d94;
michael@0 21444 d104 = d95;
michael@0 21445 d105 = d97;
michael@0 21446 break L561;
michael@0 21447 }
michael@0 21448 i106 = HEAP32[i4 >> 2] | 0;
michael@0 21449 i107 = HEAP32[(HEAP32[i106 >> 2] | 0) + 60 >> 2] | 0;
michael@0 21450 d108 = -0.0 - d98;
michael@0 21451 d109 = -0.0 - d99;
michael@0 21452 d110 = -0.0 - d100;
michael@0 21453 HEAPF32[i58 >> 2] = d40 * d108 + d46 * d109 + d52 * d110;
michael@0 21454 HEAPF32[i2 >> 2] = d42 * d108 + d48 * d109 + d54 * d110;
michael@0 21455 HEAPF32[i13 >> 2] = d44 * d108 + d50 * d109 + d56 * d110;
michael@0 21456 HEAPF32[i14 >> 2] = 0.0;
michael@0 21457 FUNCTION_TABLE_viii[i107 & 127](i16, i106, i17);
michael@0 21458 d110 = +HEAPF32[i1 >> 2];
michael@0 21459 d109 = +HEAPF32[i45 >> 2];
michael@0 21460 d108 = +HEAPF32[i43 >> 2];
michael@0 21461 d111 = d83 + (d40 * d110 + d42 * d109 + d44 * d108);
michael@0 21462 d112 = d84 + (d46 * d110 + d48 * d109 + d50 * d108);
michael@0 21463 d113 = d87 + (d52 * d110 + d54 * d109 + d56 * d108);
michael@0 21464 HEAPF32[i55 >> 2] = d111;
michael@0 21465 HEAPF32[i53 >> 2] = d112;
michael@0 21466 HEAPF32[i51 >> 2] = d113;
michael@0 21467 HEAPF32[i49 >> 2] = 0.0;
michael@0 21468 i106 = HEAP32[i47 >> 2] | 0;
michael@0 21469 i107 = HEAP32[(HEAP32[i106 >> 2] | 0) + 60 >> 2] | 0;
michael@0 21470 HEAPF32[i41 >> 2] = d57 * d98 + d63 * d99 + d69 * d100;
michael@0 21471 HEAPF32[i39 >> 2] = d59 * d98 + d65 * d99 + d71 * d100;
michael@0 21472 HEAPF32[i10 >> 2] = d61 * d98 + d67 * d99 + d73 * d100;
michael@0 21473 HEAPF32[i11 >> 2] = 0.0;
michael@0 21474 FUNCTION_TABLE_viii[i107 & 127](i18, i106, i19);
michael@0 21475 d108 = +HEAPF32[i77 >> 2];
michael@0 21476 d109 = +HEAPF32[i78 >> 2];
michael@0 21477 d110 = +HEAPF32[i88 >> 2];
michael@0 21478 d114 = d80 + (d57 * d108 + d59 * d109 + d61 * d110);
michael@0 21479 d115 = d79 + (d63 * d108 + d65 * d109 + d67 * d110);
michael@0 21480 d116 = d82 + (d69 * d108 + d71 * d109 + d73 * d110);
michael@0 21481 HEAPF32[i72 >> 2] = d114;
michael@0 21482 HEAPF32[i70 >> 2] = d115;
michael@0 21483 HEAPF32[i68 >> 2] = d116;
michael@0 21484 HEAPF32[i66 >> 2] = 0.0;
michael@0 21485 d110 = d111 - d114;
michael@0 21486 d114 = d112 - d115;
michael@0 21487 d115 = d113 - d116;
michael@0 21488 HEAPF32[i89 >> 2] = d110;
michael@0 21489 HEAPF32[i90 >> 2] = d114;
michael@0 21490 HEAPF32[i91 >> 2] = d115;
michael@0 21491 HEAPF32[i92 >> 2] = 0.0;
michael@0 21492 d116 = d100 * d115 + (d98 * d110 + d99 * d114);
michael@0 21493 if (d97 > 1.0) {
michael@0 21494 i117 = 0;
michael@0 21495 i118 = 511;
michael@0 21496 break;
michael@0 21497 }
michael@0 21498 if (d116 > 0.0) {
michael@0 21499 d113 = d74 * d98 + d75 * d99 + d76 * d100;
michael@0 21500 if (d113 >= -1.4210854715202004e-14) {
michael@0 21501 i117 = 0;
michael@0 21502 i118 = 513;
michael@0 21503 break;
michael@0 21504 }
michael@0 21505 d112 = d97 - d116 / d113;
michael@0 21506 d113 = 1.0 - d112;
michael@0 21507 d116 = +HEAPF32[i24 >> 2] * d113 + d112 * +HEAPF32[i23 >> 2];
michael@0 21508 d111 = d113 * +HEAPF32[i27 >> 2] + d112 * +HEAPF32[i26 >> 2];
michael@0 21509 d109 = d113 * +HEAPF32[i3 >> 2] + d112 * +HEAPF32[i29 >> 2];
michael@0 21510 d108 = d113 * +HEAPF32[i32 >> 2] + d112 * +HEAPF32[i31 >> 2];
michael@0 21511 d119 = d113 * +HEAPF32[i35 >> 2] + d112 * +HEAPF32[i34 >> 2];
michael@0 21512 d120 = d113 * +HEAPF32[i5 >> 2] + d112 * +HEAPF32[i37 >> 2];
michael@0 21513 HEAPF32[i89 >> 2] = d110;
michael@0 21514 HEAPF32[i90 >> 2] = d114;
michael@0 21515 HEAPF32[i91 >> 2] = d115;
michael@0 21516 HEAPF32[i92 >> 2] = 0.0;
michael@0 21517 d121 = d112;
michael@0 21518 d122 = d98;
michael@0 21519 d123 = d99;
michael@0 21520 d124 = d100;
michael@0 21521 d125 = d108;
michael@0 21522 d126 = d119;
michael@0 21523 d127 = d120;
michael@0 21524 d128 = d116;
michael@0 21525 d129 = d111;
michael@0 21526 d130 = d109;
michael@0 21527 } else {
michael@0 21528 d121 = d97;
michael@0 21529 d122 = d95;
michael@0 21530 d123 = d94;
michael@0 21531 d124 = d93;
michael@0 21532 d125 = d80;
michael@0 21533 d126 = d79;
michael@0 21534 d127 = d82;
michael@0 21535 d128 = d83;
michael@0 21536 d129 = d84;
michael@0 21537 d130 = d87;
michael@0 21538 }
michael@0 21539 if (!(__ZN22btVoronoiSimplexSolver9inSimplexERK9btVector3(HEAP32[i22 >> 2] | 0, i15) | 0)) {
michael@0 21540 __ZN22btVoronoiSimplexSolver9addVertexERK9btVector3S2_S2_(HEAP32[i22 >> 2] | 0, i15, i9, i12);
michael@0 21541 }
michael@0 21542 if (!(__ZN22btVoronoiSimplexSolver7closestER9btVector3(HEAP32[i22 >> 2] | 0, i8) | 0)) {
michael@0 21543 d102 = d124;
michael@0 21544 d103 = d123;
michael@0 21545 d104 = d122;
michael@0 21546 d105 = d121;
michael@0 21547 break L561;
michael@0 21548 }
michael@0 21549 d109 = +HEAPF32[i64 >> 2];
michael@0 21550 d111 = +HEAPF32[i62 >> 2];
michael@0 21551 d116 = +HEAPF32[i60 >> 2];
michael@0 21552 if (d109 * d109 + d111 * d111 + d116 * d116 > 9999999747378752.0e-20) {
michael@0 21553 d87 = d130;
michael@0 21554 d84 = d129;
michael@0 21555 d83 = d128;
michael@0 21556 d82 = d127;
michael@0 21557 d79 = d126;
michael@0 21558 d80 = d125;
michael@0 21559 d93 = d124;
michael@0 21560 d94 = d123;
michael@0 21561 d95 = d122;
michael@0 21562 i96 = i101;
michael@0 21563 d97 = d121;
michael@0 21564 d98 = d109;
michael@0 21565 d99 = d111;
michael@0 21566 d100 = d116;
michael@0 21567 } else {
michael@0 21568 d102 = d124;
michael@0 21569 d103 = d123;
michael@0 21570 d104 = d122;
michael@0 21571 d105 = d121;
michael@0 21572 break L561;
michael@0 21573 }
michael@0 21574 }
michael@0 21575 if ((i118 | 0) == 511) {
michael@0 21576 STACKTOP = i7;
michael@0 21577 return i117 | 0;
michael@0 21578 } else if ((i118 | 0) == 513) {
michael@0 21579 STACKTOP = i7;
michael@0 21580 return i117 | 0;
michael@0 21581 }
michael@0 21582 } else {
michael@0 21583 d102 = 0.0;
michael@0 21584 d103 = 0.0;
michael@0 21585 d104 = 0.0;
michael@0 21586 d105 = 0.0;
michael@0 21587 }
michael@0 21588 } while (0);
michael@0 21589 HEAPF32[i6 + 164 >> 2] = d105;
michael@0 21590 d105 = d102 * d102 + (d104 * d104 + d103 * d103);
michael@0 21591 if (d105 < 1.4210854715202004e-14) {
michael@0 21592 _memset(i6 + 132 | 0, 0, 16);
michael@0 21593 d131 = 0.0;
michael@0 21594 d132 = 0.0;
michael@0 21595 d133 = 0.0;
michael@0 21596 } else {
michael@0 21597 d121 = 1.0 / +Math_sqrt(+d105);
michael@0 21598 d105 = d104 * d121;
michael@0 21599 d104 = d103 * d121;
michael@0 21600 d103 = d102 * d121;
michael@0 21601 HEAPF32[i6 + 132 >> 2] = d105;
michael@0 21602 HEAPF32[i6 + 136 >> 2] = d104;
michael@0 21603 HEAPF32[i6 + 140 >> 2] = d103;
michael@0 21604 HEAPF32[i6 + 144 >> 2] = 0.0;
michael@0 21605 d131 = d105;
michael@0 21606 d132 = d104;
michael@0 21607 d133 = d103;
michael@0 21608 }
michael@0 21609 if (d76 * d133 + (d75 * d132 + d74 * d131) >= -0.0 - +HEAPF32[i6 + 172 >> 2]) {
michael@0 21610 i117 = 0;
michael@0 21611 STACKTOP = i7;
michael@0 21612 return i117 | 0;
michael@0 21613 }
michael@0 21614 __ZN22btVoronoiSimplexSolver14compute_pointsER9btVector3S1_(HEAP32[i22 >> 2] | 0, i20, i21);
michael@0 21615 i20 = i6 + 148 | 0;
michael@0 21616 i6 = i21;
michael@0 21617 HEAP32[i20 >> 2] = HEAP32[i6 >> 2];
michael@0 21618 HEAP32[i20 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 21619 HEAP32[i20 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 21620 HEAP32[i20 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 21621 i117 = 1;
michael@0 21622 STACKTOP = i7;
michael@0 21623 return i117 | 0;
michael@0 21624 }
michael@0 21625 function __ZN12gjkepa2_impl3GJK8EvaluateERKNS_13MinkowskiDiffERK9btVector3(i1, i2, i3) {
michael@0 21626 i1 = i1 | 0;
michael@0 21627 i2 = i2 | 0;
michael@0 21628 i3 = i3 | 0;
michael@0 21629 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, i22 = 0, i23 = 0, d24 = 0.0, i25 = 0, d26 = 0.0, i27 = 0, d28 = 0.0, i29 = 0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, d44 = 0.0, d45 = 0.0, d46 = 0.0, i47 = 0, d48 = 0.0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, d54 = 0.0, d55 = 0.0;
michael@0 21630 i4 = STACKTOP;
michael@0 21631 STACKTOP = STACKTOP + 120 | 0;
michael@0 21632 i5 = i4 | 0;
michael@0 21633 i6 = i4 + 64 | 0;
michael@0 21634 i7 = i4 + 80 | 0;
michael@0 21635 i8 = i4 + 96 | 0;
michael@0 21636 i9 = i4 + 112 | 0;
michael@0 21637 HEAP32[i1 + 348 >> 2] = i1 + 220;
michael@0 21638 HEAP32[i1 + 352 >> 2] = i1 + 252;
michael@0 21639 HEAP32[i1 + 356 >> 2] = i1 + 284;
michael@0 21640 i10 = i1 + 316 | 0;
michael@0 21641 HEAP32[i1 + 360 >> 2] = i10;
michael@0 21642 i11 = i1 + 364 | 0;
michael@0 21643 HEAP32[i11 >> 2] = 4;
michael@0 21644 i12 = i1 + 368 | 0;
michael@0 21645 HEAP32[i12 >> 2] = 0;
michael@0 21646 i13 = i1 + 376 | 0;
michael@0 21647 HEAP32[i13 >> 2] = 0;
michael@0 21648 i14 = i2;
michael@0 21649 i15 = i1;
michael@0 21650 i16 = HEAP32[i14 + 4 >> 2] | 0;
michael@0 21651 HEAP32[i15 >> 2] = HEAP32[i14 >> 2];
michael@0 21652 HEAP32[i15 + 4 >> 2] = i16;
michael@0 21653 i16 = i1 + 8 | 0;
michael@0 21654 i15 = i2 + 8 | 0;
michael@0 21655 HEAP32[i16 >> 2] = HEAP32[i15 >> 2];
michael@0 21656 HEAP32[i16 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 21657 HEAP32[i16 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 21658 HEAP32[i16 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 21659 i15 = i1 + 24 | 0;
michael@0 21660 i16 = i2 + 24 | 0;
michael@0 21661 HEAP32[i15 >> 2] = HEAP32[i16 >> 2];
michael@0 21662 HEAP32[i15 + 4 >> 2] = HEAP32[i16 + 4 >> 2];
michael@0 21663 HEAP32[i15 + 8 >> 2] = HEAP32[i16 + 8 >> 2];
michael@0 21664 HEAP32[i15 + 12 >> 2] = HEAP32[i16 + 12 >> 2];
michael@0 21665 i16 = i1 + 40 | 0;
michael@0 21666 i15 = i2 + 40 | 0;
michael@0 21667 HEAP32[i16 >> 2] = HEAP32[i15 >> 2];
michael@0 21668 HEAP32[i16 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 21669 HEAP32[i16 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 21670 HEAP32[i16 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 21671 i15 = i1 + 56 | 0;
michael@0 21672 i16 = i2 + 56 | 0;
michael@0 21673 HEAP32[i15 >> 2] = HEAP32[i16 >> 2];
michael@0 21674 HEAP32[i15 + 4 >> 2] = HEAP32[i16 + 4 >> 2];
michael@0 21675 HEAP32[i15 + 8 >> 2] = HEAP32[i16 + 8 >> 2];
michael@0 21676 HEAP32[i15 + 12 >> 2] = HEAP32[i16 + 12 >> 2];
michael@0 21677 i16 = i1 + 72 | 0;
michael@0 21678 i15 = i2 + 72 | 0;
michael@0 21679 HEAP32[i16 >> 2] = HEAP32[i15 >> 2];
michael@0 21680 HEAP32[i16 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 21681 HEAP32[i16 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 21682 HEAP32[i16 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 21683 i15 = i1 + 88 | 0;
michael@0 21684 i16 = i2 + 88 | 0;
michael@0 21685 HEAP32[i15 >> 2] = HEAP32[i16 >> 2];
michael@0 21686 HEAP32[i15 + 4 >> 2] = HEAP32[i16 + 4 >> 2];
michael@0 21687 HEAP32[i15 + 8 >> 2] = HEAP32[i16 + 8 >> 2];
michael@0 21688 HEAP32[i15 + 12 >> 2] = HEAP32[i16 + 12 >> 2];
michael@0 21689 i16 = i1 + 104 | 0;
michael@0 21690 i15 = i2 + 104 | 0;
michael@0 21691 HEAP32[i16 >> 2] = HEAP32[i15 >> 2];
michael@0 21692 HEAP32[i16 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 21693 HEAP32[i16 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 21694 HEAP32[i16 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 21695 i15 = i2 + 120 | 0;
michael@0 21696 i2 = HEAP32[i15 + 4 >> 2] | 0;
michael@0 21697 i16 = i1 + 120 | 0;
michael@0 21698 HEAP32[i16 >> 2] = HEAP32[i15 >> 2];
michael@0 21699 HEAP32[i16 + 4 >> 2] = i2;
michael@0 21700 i2 = i1 + 144 | 0;
michael@0 21701 HEAPF32[i2 >> 2] = 0.0;
michael@0 21702 i16 = i1 + 180 | 0;
michael@0 21703 HEAP32[i16 >> 2] = 0;
michael@0 21704 i15 = i1 + 128 | 0;
michael@0 21705 i14 = i15;
michael@0 21706 i17 = i3;
michael@0 21707 HEAP32[i14 >> 2] = HEAP32[i17 >> 2];
michael@0 21708 HEAP32[i14 + 4 >> 2] = HEAP32[i17 + 4 >> 2];
michael@0 21709 HEAP32[i14 + 8 >> 2] = HEAP32[i17 + 8 >> 2];
michael@0 21710 HEAP32[i14 + 12 >> 2] = HEAP32[i17 + 12 >> 2];
michael@0 21711 i17 = i15 | 0;
michael@0 21712 d18 = +HEAPF32[i17 >> 2];
michael@0 21713 i15 = i1 + 132 | 0;
michael@0 21714 d19 = +HEAPF32[i15 >> 2];
michael@0 21715 i3 = i1 + 136 | 0;
michael@0 21716 d20 = +HEAPF32[i3 >> 2];
michael@0 21717 d21 = d18 * d18 + d19 * d19 + d20 * d20;
michael@0 21718 if (d21 > 0.0) {
michael@0 21719 HEAPF32[i6 >> 2] = -0.0 - d18;
michael@0 21720 HEAPF32[i6 + 4 >> 2] = -0.0 - d19;
michael@0 21721 HEAPF32[i6 + 8 >> 2] = -0.0 - d20;
michael@0 21722 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 21723 } else {
michael@0 21724 HEAPF32[i6 >> 2] = 1.0;
michael@0 21725 HEAPF32[i6 + 4 >> 2] = 0.0;
michael@0 21726 HEAPF32[i6 + 8 >> 2] = 0.0;
michael@0 21727 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 21728 }
michael@0 21729 i22 = i1 + 164 | 0;
michael@0 21730 HEAPF32[i22 >> 2] = 0.0;
michael@0 21731 HEAP32[i11 >> 2] = 3;
michael@0 21732 i23 = i1 + 148 | 0;
michael@0 21733 HEAP32[i23 >> 2] = i10;
michael@0 21734 HEAP32[i16 >> 2] = 1;
michael@0 21735 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i6, i10);
michael@0 21736 HEAPF32[i22 >> 2] = 1.0;
michael@0 21737 i22 = (HEAP32[i23 >> 2] | 0) + 16 | 0;
michael@0 21738 HEAP32[i14 >> 2] = HEAP32[i22 >> 2];
michael@0 21739 HEAP32[i14 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 21740 HEAP32[i14 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 21741 HEAP32[i14 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 21742 i14 = i5 + 48 | 0;
michael@0 21743 HEAP32[i14 >> 2] = HEAP32[i22 >> 2];
michael@0 21744 HEAP32[i14 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 21745 HEAP32[i14 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 21746 HEAP32[i14 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 21747 i14 = i5 + 32 | 0;
michael@0 21748 HEAP32[i14 >> 2] = HEAP32[i22 >> 2];
michael@0 21749 HEAP32[i14 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 21750 HEAP32[i14 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 21751 HEAP32[i14 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 21752 i14 = i5 + 16 | 0;
michael@0 21753 HEAP32[i14 >> 2] = HEAP32[i22 >> 2];
michael@0 21754 HEAP32[i14 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 21755 HEAP32[i14 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 21756 HEAP32[i14 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 21757 i14 = i5;
michael@0 21758 HEAP32[i14 >> 2] = HEAP32[i22 >> 2];
michael@0 21759 HEAP32[i14 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 21760 HEAP32[i14 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 21761 HEAP32[i14 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 21762 i22 = i7 | 0;
michael@0 21763 i14 = i7 + 4 | 0;
michael@0 21764 i23 = i7 + 8 | 0;
michael@0 21765 i10 = i7 + 12 | 0;
michael@0 21766 i6 = i8 | 0;
michael@0 21767 d20 = +HEAPF32[i17 >> 2];
michael@0 21768 d19 = +HEAPF32[i15 >> 2];
michael@0 21769 d18 = +HEAPF32[i3 >> 2];
michael@0 21770 d24 = +Math_sqrt(+(d20 * d20 + d19 * d19 + d18 * d18));
michael@0 21771 L24 : do {
michael@0 21772 if (d24 < 9999999747378752.0e-20) {
michael@0 21773 i25 = 21;
michael@0 21774 } else {
michael@0 21775 i16 = i1 + 128 | 0;
michael@0 21776 d26 = 0.0;
michael@0 21777 i27 = 1;
michael@0 21778 d28 = d21;
michael@0 21779 i29 = 1;
michael@0 21780 d30 = d20;
michael@0 21781 d31 = d19;
michael@0 21782 d32 = d18;
michael@0 21783 d33 = d24;
michael@0 21784 L26 : while (1) {
michael@0 21785 i34 = HEAP32[i12 >> 2] | 0;
michael@0 21786 i35 = 1 - i34 | 0;
michael@0 21787 i36 = i1 + 148 + (i34 * 36 | 0) | 0;
michael@0 21788 HEAPF32[i22 >> 2] = -0.0 - d30;
michael@0 21789 HEAPF32[i14 >> 2] = -0.0 - d31;
michael@0 21790 HEAPF32[i23 >> 2] = -0.0 - d32;
michael@0 21791 HEAPF32[i10 >> 2] = 0.0;
michael@0 21792 i37 = i1 + 148 + (i34 * 36 | 0) + 32 | 0;
michael@0 21793 HEAPF32[i1 + 148 + (i34 * 36 | 0) + 16 + (HEAP32[i37 >> 2] << 2) >> 2] = 0.0;
michael@0 21794 i38 = (HEAP32[i11 >> 2] | 0) - 1 | 0;
michael@0 21795 HEAP32[i11 >> 2] = i38;
michael@0 21796 HEAP32[i1 + 148 + (i34 * 36 | 0) + (HEAP32[i37 >> 2] << 2) >> 2] = HEAP32[i1 + 348 + (i38 << 2) >> 2];
michael@0 21797 i38 = HEAP32[i37 >> 2] | 0;
michael@0 21798 HEAP32[i37 >> 2] = i38 + 1;
michael@0 21799 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i7, HEAP32[i1 + 148 + (i34 * 36 | 0) + (i38 << 2) >> 2] | 0);
michael@0 21800 i38 = HEAP32[i37 >> 2] | 0;
michael@0 21801 i39 = HEAP32[i1 + 148 + (i34 * 36 | 0) + (i38 - 1 << 2) >> 2] | 0;
michael@0 21802 i40 = i39 + 16 | 0;
michael@0 21803 i41 = i40 | 0;
michael@0 21804 i42 = i39 + 20 | 0;
michael@0 21805 i43 = i39 + 24 | 0;
michael@0 21806 i39 = 0;
michael@0 21807 while (1) {
michael@0 21808 if (i39 >>> 0 >= 4) {
michael@0 21809 break;
michael@0 21810 }
michael@0 21811 d44 = +HEAPF32[i41 >> 2] - +HEAPF32[i5 + (i39 << 4) >> 2];
michael@0 21812 d45 = +HEAPF32[i42 >> 2] - +HEAPF32[i5 + (i39 << 4) + 4 >> 2];
michael@0 21813 d46 = +HEAPF32[i43 >> 2] - +HEAPF32[i5 + (i39 << 4) + 8 >> 2];
michael@0 21814 if (d44 * d44 + d45 * d45 + d46 * d46 < 9999999747378752.0e-20) {
michael@0 21815 i25 = 25;
michael@0 21816 break L26;
michael@0 21817 } else {
michael@0 21818 i39 = i39 + 1 | 0;
michael@0 21819 }
michael@0 21820 }
michael@0 21821 i39 = i5 + (i27 << 4) | 0;
michael@0 21822 i47 = i40;
michael@0 21823 HEAP32[i39 >> 2] = HEAP32[i47 >> 2];
michael@0 21824 HEAP32[i39 + 4 >> 2] = HEAP32[i47 + 4 >> 2];
michael@0 21825 HEAP32[i39 + 8 >> 2] = HEAP32[i47 + 8 >> 2];
michael@0 21826 HEAP32[i39 + 12 >> 2] = HEAP32[i47 + 12 >> 2];
michael@0 21827 d46 = (+HEAPF32[i17 >> 2] * +HEAPF32[i41 >> 2] + +HEAPF32[i15 >> 2] * +HEAPF32[i42 >> 2] + +HEAPF32[i3 >> 2] * +HEAPF32[i43 >> 2]) / d33;
michael@0 21828 d45 = d46 > d26 ? d46 : d26;
michael@0 21829 if (d33 - d45 - d33 * 9999999747378752.0e-20 <= 0.0) {
michael@0 21830 i25 = 27;
michael@0 21831 break;
michael@0 21832 }
michael@0 21833 HEAP32[i9 >> 2] = 0;
michael@0 21834 if ((i38 | 0) == 2) {
michael@0 21835 d48 = +__ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_PfRj((HEAP32[i36 >> 2] | 0) + 16 | 0, (HEAP32[i1 + 148 + (i34 * 36 | 0) + 4 >> 2] | 0) + 16 | 0, i6, i9);
michael@0 21836 } else if ((i38 | 0) == 3) {
michael@0 21837 d48 = +__ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_S3_PfRj((HEAP32[i36 >> 2] | 0) + 16 | 0, (HEAP32[i1 + 148 + (i34 * 36 | 0) + 4 >> 2] | 0) + 16 | 0, (HEAP32[i1 + 148 + (i34 * 36 | 0) + 8 >> 2] | 0) + 16 | 0, i6, i9);
michael@0 21838 } else if ((i38 | 0) == 4) {
michael@0 21839 d48 = +__ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_S3_S3_PfRj((HEAP32[i36 >> 2] | 0) + 16 | 0, (HEAP32[i1 + 148 + (i34 * 36 | 0) + 4 >> 2] | 0) + 16 | 0, (HEAP32[i1 + 148 + (i34 * 36 | 0) + 8 >> 2] | 0) + 16 | 0, (HEAP32[i1 + 148 + (i34 * 36 | 0) + 12 >> 2] | 0) + 16 | 0, i6, i9);
michael@0 21840 } else {
michael@0 21841 d48 = d28;
michael@0 21842 }
michael@0 21843 if (d48 < 0.0) {
michael@0 21844 i25 = 40;
michael@0 21845 break;
michael@0 21846 }
michael@0 21847 i47 = i1 + 148 + (i35 * 36 | 0) + 32 | 0;
michael@0 21848 HEAP32[i47 >> 2] = 0;
michael@0 21849 _memset(i16 | 0, 0, 16);
michael@0 21850 HEAP32[i12 >> 2] = i35;
michael@0 21851 i39 = HEAP32[i37 >> 2] | 0;
michael@0 21852 i49 = HEAP32[i9 >> 2] | 0;
michael@0 21853 if ((i39 | 0) != 0) {
michael@0 21854 i50 = 0;
michael@0 21855 do {
michael@0 21856 i51 = i1 + 148 + (i34 * 36 | 0) + (i50 << 2) | 0;
michael@0 21857 i52 = HEAP32[i51 >> 2] | 0;
michael@0 21858 if ((1 << i50 & i49 | 0) == 0) {
michael@0 21859 i53 = HEAP32[i11 >> 2] | 0;
michael@0 21860 HEAP32[i11 >> 2] = i53 + 1;
michael@0 21861 HEAP32[i1 + 348 + (i53 << 2) >> 2] = i52;
michael@0 21862 } else {
michael@0 21863 HEAP32[i1 + 148 + (i35 * 36 | 0) + (HEAP32[i47 >> 2] << 2) >> 2] = i52;
michael@0 21864 d46 = +HEAPF32[i8 + (i50 << 2) >> 2];
michael@0 21865 i52 = HEAP32[i47 >> 2] | 0;
michael@0 21866 HEAP32[i47 >> 2] = i52 + 1;
michael@0 21867 HEAPF32[i1 + 148 + (i35 * 36 | 0) + 16 + (i52 << 2) >> 2] = d46;
michael@0 21868 i52 = HEAP32[i51 >> 2] | 0;
michael@0 21869 d44 = d46 * +HEAPF32[i52 + 20 >> 2];
michael@0 21870 d54 = d46 * +HEAPF32[i52 + 24 >> 2];
michael@0 21871 HEAPF32[i17 >> 2] = d46 * +HEAPF32[i52 + 16 >> 2] + +HEAPF32[i17 >> 2];
michael@0 21872 HEAPF32[i15 >> 2] = d44 + +HEAPF32[i15 >> 2];
michael@0 21873 HEAPF32[i3 >> 2] = d54 + +HEAPF32[i3 >> 2];
michael@0 21874 }
michael@0 21875 i50 = i50 + 1 | 0;
michael@0 21876 } while (i50 >>> 0 < i39 >>> 0);
michael@0 21877 }
michael@0 21878 if ((i49 | 0) == 15) {
michael@0 21879 HEAP32[i13 >> 2] = 1;
michael@0 21880 }
michael@0 21881 if (i29 >>> 0 >= 128) {
michael@0 21882 i25 = 42;
michael@0 21883 break;
michael@0 21884 }
michael@0 21885 if ((HEAP32[i13 >> 2] | 0) != 0) {
michael@0 21886 break L24;
michael@0 21887 }
michael@0 21888 d54 = +HEAPF32[i17 >> 2];
michael@0 21889 d44 = +HEAPF32[i15 >> 2];
michael@0 21890 d46 = +HEAPF32[i3 >> 2];
michael@0 21891 d55 = +Math_sqrt(+(d54 * d54 + d44 * d44 + d46 * d46));
michael@0 21892 if (d55 < 9999999747378752.0e-20) {
michael@0 21893 i25 = 21;
michael@0 21894 break L24;
michael@0 21895 } else {
michael@0 21896 d26 = d45;
michael@0 21897 i27 = i27 + 1 & 3;
michael@0 21898 d28 = d48;
michael@0 21899 i29 = i29 + 1 | 0;
michael@0 21900 d30 = d54;
michael@0 21901 d31 = d44;
michael@0 21902 d32 = d46;
michael@0 21903 d33 = d55;
michael@0 21904 }
michael@0 21905 }
michael@0 21906 if ((i25 | 0) == 25) {
michael@0 21907 i29 = HEAP32[i12 >> 2] | 0;
michael@0 21908 i27 = i1 + 148 + (i29 * 36 | 0) + 32 | 0;
michael@0 21909 i16 = (HEAP32[i27 >> 2] | 0) - 1 | 0;
michael@0 21910 HEAP32[i27 >> 2] = i16;
michael@0 21911 i27 = HEAP32[i1 + 148 + (i29 * 36 | 0) + (i16 << 2) >> 2] | 0;
michael@0 21912 i16 = HEAP32[i11 >> 2] | 0;
michael@0 21913 HEAP32[i11 >> 2] = i16 + 1;
michael@0 21914 HEAP32[i1 + 348 + (i16 << 2) >> 2] = i27;
michael@0 21915 break;
michael@0 21916 } else if ((i25 | 0) == 27) {
michael@0 21917 i27 = HEAP32[i12 >> 2] | 0;
michael@0 21918 i16 = i1 + 148 + (i27 * 36 | 0) + 32 | 0;
michael@0 21919 i29 = (HEAP32[i16 >> 2] | 0) - 1 | 0;
michael@0 21920 HEAP32[i16 >> 2] = i29;
michael@0 21921 i16 = HEAP32[i1 + 148 + (i27 * 36 | 0) + (i29 << 2) >> 2] | 0;
michael@0 21922 i29 = HEAP32[i11 >> 2] | 0;
michael@0 21923 HEAP32[i11 >> 2] = i29 + 1;
michael@0 21924 HEAP32[i1 + 348 + (i29 << 2) >> 2] = i16;
michael@0 21925 break;
michael@0 21926 } else if ((i25 | 0) == 40) {
michael@0 21927 i16 = HEAP32[i12 >> 2] | 0;
michael@0 21928 i29 = i1 + 148 + (i16 * 36 | 0) + 32 | 0;
michael@0 21929 i27 = (HEAP32[i29 >> 2] | 0) - 1 | 0;
michael@0 21930 HEAP32[i29 >> 2] = i27;
michael@0 21931 i29 = HEAP32[i1 + 148 + (i16 * 36 | 0) + (i27 << 2) >> 2] | 0;
michael@0 21932 i27 = HEAP32[i11 >> 2] | 0;
michael@0 21933 HEAP32[i11 >> 2] = i27 + 1;
michael@0 21934 HEAP32[i1 + 348 + (i27 << 2) >> 2] = i29;
michael@0 21935 break;
michael@0 21936 } else if ((i25 | 0) == 42) {
michael@0 21937 HEAP32[i13 >> 2] = 2;
michael@0 21938 break;
michael@0 21939 }
michael@0 21940 }
michael@0 21941 } while (0);
michael@0 21942 if ((i25 | 0) == 21) {
michael@0 21943 HEAP32[i13 >> 2] = 1;
michael@0 21944 }
michael@0 21945 HEAP32[i1 + 372 >> 2] = i1 + 148 + ((HEAP32[i12 >> 2] | 0) * 36 | 0);
michael@0 21946 i12 = HEAP32[i13 >> 2] | 0;
michael@0 21947 if ((i12 | 0) == 0) {
michael@0 21948 d48 = +HEAPF32[i17 >> 2];
michael@0 21949 d24 = +HEAPF32[i15 >> 2];
michael@0 21950 d18 = +HEAPF32[i3 >> 2];
michael@0 21951 HEAPF32[i2 >> 2] = +Math_sqrt(+(d48 * d48 + d24 * d24 + d18 * d18));
michael@0 21952 STACKTOP = i4;
michael@0 21953 return i12 | 0;
michael@0 21954 } else if ((i12 | 0) == 1) {
michael@0 21955 HEAPF32[i2 >> 2] = 0.0;
michael@0 21956 STACKTOP = i4;
michael@0 21957 return i12 | 0;
michael@0 21958 } else {
michael@0 21959 STACKTOP = i4;
michael@0 21960 return i12 | 0;
michael@0 21961 }
michael@0 21962 return 0;
michael@0 21963 }
michael@0 21964 function __ZN35btSequentialImpulseConstraintSolver22setupContactConstraintER18btSolverConstraintP17btCollisionObjectS3_R15btManifoldPointRK19btContactSolverInfoR9btVector3RfSB_SA_SA_(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 21965 i1 = i1 | 0;
michael@0 21966 i2 = i2 | 0;
michael@0 21967 i3 = i3 | 0;
michael@0 21968 i4 = i4 | 0;
michael@0 21969 i5 = i5 | 0;
michael@0 21970 i6 = i6 | 0;
michael@0 21971 i7 = i7 | 0;
michael@0 21972 i8 = i8 | 0;
michael@0 21973 i9 = i9 | 0;
michael@0 21974 i10 = i10 | 0;
michael@0 21975 i11 = i11 | 0;
michael@0 21976 var i12 = 0, i13 = 0, d14 = 0.0, d15 = 0.0, i16 = 0, i17 = 0, i18 = 0, d19 = 0.0, i20 = 0, d21 = 0.0, d22 = 0.0, i23 = 0, d24 = 0.0, d25 = 0.0, d26 = 0.0, i27 = 0, d28 = 0.0, d29 = 0.0, d30 = 0.0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, d35 = 0.0, d36 = 0.0, d37 = 0.0, i38 = 0, i39 = 0, i40 = 0, d41 = 0.0, d42 = 0.0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, d61 = 0.0, d62 = 0.0, d63 = 0.0, d64 = 0.0, d65 = 0.0, d66 = 0.0, d67 = 0.0, i68 = 0, i69 = 0, i70 = 0;
michael@0 21977 if ((HEAP32[i3 + 232 >> 2] & 2 | 0) == 0) {
michael@0 21978 i12 = 0;
michael@0 21979 } else {
michael@0 21980 i12 = i3;
michael@0 21981 }
michael@0 21982 if ((HEAP32[i4 + 232 >> 2] & 2 | 0) == 0) {
michael@0 21983 i13 = 0;
michael@0 21984 } else {
michael@0 21985 i13 = i4;
michael@0 21986 }
michael@0 21987 d14 = +HEAPF32[i5 + 52 >> 2] - +HEAPF32[i3 + 56 >> 2];
michael@0 21988 d15 = +HEAPF32[i5 + 56 >> 2] - +HEAPF32[i3 + 60 >> 2];
michael@0 21989 i1 = i10 | 0;
michael@0 21990 HEAPF32[i1 >> 2] = +HEAPF32[i5 + 48 >> 2] - +HEAPF32[i3 + 52 >> 2];
michael@0 21991 i3 = i10 + 4 | 0;
michael@0 21992 HEAPF32[i3 >> 2] = d14;
michael@0 21993 i16 = i10 + 8 | 0;
michael@0 21994 HEAPF32[i16 >> 2] = d15;
michael@0 21995 HEAPF32[i10 + 12 >> 2] = 0.0;
michael@0 21996 d15 = +HEAPF32[i5 + 36 >> 2] - +HEAPF32[i4 + 56 >> 2];
michael@0 21997 d14 = +HEAPF32[i5 + 40 >> 2] - +HEAPF32[i4 + 60 >> 2];
michael@0 21998 i10 = i11 | 0;
michael@0 21999 HEAPF32[i10 >> 2] = +HEAPF32[i5 + 32 >> 2] - +HEAPF32[i4 + 52 >> 2];
michael@0 22000 i4 = i11 + 4 | 0;
michael@0 22001 HEAPF32[i4 >> 2] = d15;
michael@0 22002 i17 = i11 + 8 | 0;
michael@0 22003 HEAPF32[i17 >> 2] = d14;
michael@0 22004 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 22005 HEAPF32[i9 >> 2] = 1.0;
michael@0 22006 i11 = i5 + 64 | 0;
michael@0 22007 d14 = +HEAPF32[i3 >> 2];
michael@0 22008 i18 = i5 + 72 | 0;
michael@0 22009 d15 = +HEAPF32[i18 >> 2];
michael@0 22010 d19 = +HEAPF32[i16 >> 2];
michael@0 22011 i20 = i5 + 68 | 0;
michael@0 22012 d21 = +HEAPF32[i20 >> 2];
michael@0 22013 d22 = d14 * d15 - d19 * d21;
michael@0 22014 i23 = i11 | 0;
michael@0 22015 d24 = +HEAPF32[i23 >> 2];
michael@0 22016 d25 = +HEAPF32[i1 >> 2];
michael@0 22017 d26 = d19 * d24 - d15 * d25;
michael@0 22018 d15 = d21 * d25 - d14 * d24;
michael@0 22019 i27 = (i12 | 0) != 0;
michael@0 22020 if (i27) {
michael@0 22021 d28 = (d22 * +HEAPF32[i12 + 256 >> 2] + d26 * +HEAPF32[i12 + 260 >> 2] + d15 * +HEAPF32[i12 + 264 >> 2]) * +HEAPF32[i12 + 536 >> 2];
michael@0 22022 d29 = (d22 * +HEAPF32[i12 + 272 >> 2] + d26 * +HEAPF32[i12 + 276 >> 2] + d15 * +HEAPF32[i12 + 280 >> 2]) * +HEAPF32[i12 + 540 >> 2];
michael@0 22023 d30 = (d22 * +HEAPF32[i12 + 288 >> 2] + d26 * +HEAPF32[i12 + 292 >> 2] + d15 * +HEAPF32[i12 + 296 >> 2]) * +HEAPF32[i12 + 544 >> 2];
michael@0 22024 } else {
michael@0 22025 d28 = 0.0;
michael@0 22026 d29 = 0.0;
michael@0 22027 d30 = 0.0;
michael@0 22028 }
michael@0 22029 i31 = i2 + 48 | 0;
michael@0 22030 HEAPF32[i31 >> 2] = d28;
michael@0 22031 i32 = i2 + 52 | 0;
michael@0 22032 HEAPF32[i32 >> 2] = d29;
michael@0 22033 i33 = i2 + 56 | 0;
michael@0 22034 HEAPF32[i33 >> 2] = d30;
michael@0 22035 HEAPF32[i2 + 60 >> 2] = 0.0;
michael@0 22036 d15 = +HEAPF32[i4 >> 2];
michael@0 22037 d26 = +HEAPF32[i18 >> 2];
michael@0 22038 d22 = +HEAPF32[i17 >> 2];
michael@0 22039 d24 = +HEAPF32[i20 >> 2];
michael@0 22040 d14 = +HEAPF32[i23 >> 2];
michael@0 22041 d25 = +HEAPF32[i10 >> 2];
michael@0 22042 i34 = (i13 | 0) != 0;
michael@0 22043 if (i34) {
michael@0 22044 d21 = -0.0 - (d15 * d26 - d22 * d24);
michael@0 22045 d19 = -0.0 - (d22 * d14 - d26 * d25);
michael@0 22046 d26 = -0.0 - (d24 * d25 - d15 * d14);
michael@0 22047 d35 = (+HEAPF32[i13 + 256 >> 2] * d21 + +HEAPF32[i13 + 260 >> 2] * d19 + +HEAPF32[i13 + 264 >> 2] * d26) * +HEAPF32[i13 + 536 >> 2];
michael@0 22048 d36 = (+HEAPF32[i13 + 272 >> 2] * d21 + +HEAPF32[i13 + 276 >> 2] * d19 + +HEAPF32[i13 + 280 >> 2] * d26) * +HEAPF32[i13 + 540 >> 2];
michael@0 22049 d37 = (+HEAPF32[i13 + 288 >> 2] * d21 + +HEAPF32[i13 + 292 >> 2] * d19 + +HEAPF32[i13 + 296 >> 2] * d26) * +HEAPF32[i13 + 544 >> 2];
michael@0 22050 } else {
michael@0 22051 d35 = 0.0;
michael@0 22052 d36 = 0.0;
michael@0 22053 d37 = 0.0;
michael@0 22054 }
michael@0 22055 i38 = i2 + 64 | 0;
michael@0 22056 HEAPF32[i38 >> 2] = d35;
michael@0 22057 i39 = i2 + 68 | 0;
michael@0 22058 HEAPF32[i39 >> 2] = d36;
michael@0 22059 i40 = i2 + 72 | 0;
michael@0 22060 HEAPF32[i40 >> 2] = d37;
michael@0 22061 HEAPF32[i2 + 76 >> 2] = 0.0;
michael@0 22062 if (i27) {
michael@0 22063 d26 = +HEAPF32[i16 >> 2];
michael@0 22064 d19 = +HEAPF32[i3 >> 2];
michael@0 22065 d21 = +HEAPF32[i1 >> 2];
michael@0 22066 d41 = +HEAPF32[i12 + 336 >> 2] + ((d29 * d26 - d30 * d19) * +HEAPF32[i23 >> 2] + (d30 * d21 - d28 * d26) * +HEAPF32[i20 >> 2] + (d28 * d19 - d29 * d21) * +HEAPF32[i18 >> 2]);
michael@0 22067 } else {
michael@0 22068 d41 = 0.0;
michael@0 22069 }
michael@0 22070 if (i34) {
michael@0 22071 d21 = -0.0 - d35;
michael@0 22072 d35 = -0.0 - d36;
michael@0 22073 d36 = -0.0 - d37;
michael@0 22074 d37 = +HEAPF32[i17 >> 2];
michael@0 22075 d29 = +HEAPF32[i4 >> 2];
michael@0 22076 d19 = +HEAPF32[i10 >> 2];
michael@0 22077 d42 = +HEAPF32[i13 + 336 >> 2] + ((d37 * d35 - d29 * d36) * +HEAPF32[i23 >> 2] + (d19 * d36 - d37 * d21) * +HEAPF32[i20 >> 2] + (d29 * d21 - d19 * d35) * +HEAPF32[i18 >> 2]);
michael@0 22078 } else {
michael@0 22079 d42 = 0.0;
michael@0 22080 }
michael@0 22081 i43 = i2 + 92 | 0;
michael@0 22082 HEAPF32[i43 >> 2] = +HEAPF32[i9 >> 2] / (d41 + d42);
michael@0 22083 i9 = i2 + 16 | 0;
michael@0 22084 i44 = i9;
michael@0 22085 i45 = i11;
michael@0 22086 HEAP32[i44 >> 2] = HEAP32[i45 >> 2];
michael@0 22087 HEAP32[i44 + 4 >> 2] = HEAP32[i45 + 4 >> 2];
michael@0 22088 HEAP32[i44 + 8 >> 2] = HEAP32[i45 + 8 >> 2];
michael@0 22089 HEAP32[i44 + 12 >> 2] = HEAP32[i45 + 12 >> 2];
michael@0 22090 d42 = +HEAPF32[i3 >> 2];
michael@0 22091 d41 = +HEAPF32[i18 >> 2];
michael@0 22092 d35 = +HEAPF32[i16 >> 2];
michael@0 22093 d19 = +HEAPF32[i20 >> 2];
michael@0 22094 d21 = +HEAPF32[i23 >> 2];
michael@0 22095 d29 = +HEAPF32[i1 >> 2];
michael@0 22096 i45 = i2 | 0;
michael@0 22097 HEAPF32[i45 >> 2] = d42 * d41 - d35 * d19;
michael@0 22098 i44 = i2 + 4 | 0;
michael@0 22099 HEAPF32[i44 >> 2] = d35 * d21 - d41 * d29;
michael@0 22100 i11 = i2 + 8 | 0;
michael@0 22101 HEAPF32[i11 >> 2] = d19 * d29 - d42 * d21;
michael@0 22102 HEAPF32[i2 + 12 >> 2] = 0.0;
michael@0 22103 d21 = -0.0 - +HEAPF32[i23 >> 2];
michael@0 22104 d42 = -0.0 - +HEAPF32[i20 >> 2];
michael@0 22105 d29 = -0.0 - +HEAPF32[i18 >> 2];
michael@0 22106 d19 = +HEAPF32[i4 >> 2];
michael@0 22107 d41 = +HEAPF32[i17 >> 2];
michael@0 22108 d35 = +HEAPF32[i10 >> 2];
michael@0 22109 i46 = i2 + 32 | 0;
michael@0 22110 HEAPF32[i46 >> 2] = d19 * d29 - d41 * d42;
michael@0 22111 i47 = i2 + 36 | 0;
michael@0 22112 HEAPF32[i47 >> 2] = d41 * d21 - d35 * d29;
michael@0 22113 i48 = i2 + 40 | 0;
michael@0 22114 HEAPF32[i48 >> 2] = d35 * d42 - d19 * d21;
michael@0 22115 HEAPF32[i2 + 44 >> 2] = 0.0;
michael@0 22116 if (i27) {
michael@0 22117 d21 = +HEAPF32[i12 + 324 >> 2];
michael@0 22118 d19 = +HEAPF32[i16 >> 2];
michael@0 22119 d42 = +HEAPF32[i12 + 328 >> 2];
michael@0 22120 d35 = +HEAPF32[i3 >> 2];
michael@0 22121 d29 = +HEAPF32[i1 >> 2];
michael@0 22122 d41 = +HEAPF32[i12 + 320 >> 2];
michael@0 22123 d49 = d21 * d19 - d42 * d35 + +HEAPF32[i12 + 304 >> 2];
michael@0 22124 d50 = +HEAPF32[i12 + 308 >> 2] + (d42 * d29 - d19 * d41);
michael@0 22125 d51 = d35 * d41 - d21 * d29 + +HEAPF32[i12 + 312 >> 2];
michael@0 22126 } else {
michael@0 22127 d49 = 0.0;
michael@0 22128 d50 = 0.0;
michael@0 22129 d51 = 0.0;
michael@0 22130 }
michael@0 22131 if (i34) {
michael@0 22132 d29 = +HEAPF32[i13 + 324 >> 2];
michael@0 22133 d21 = +HEAPF32[i17 >> 2];
michael@0 22134 d41 = +HEAPF32[i13 + 328 >> 2];
michael@0 22135 d35 = +HEAPF32[i4 >> 2];
michael@0 22136 d19 = +HEAPF32[i10 >> 2];
michael@0 22137 d42 = +HEAPF32[i13 + 320 >> 2];
michael@0 22138 d52 = d29 * d21 - d41 * d35 + +HEAPF32[i13 + 304 >> 2];
michael@0 22139 d53 = +HEAPF32[i13 + 308 >> 2] + (d41 * d19 - d21 * d42);
michael@0 22140 d54 = d35 * d42 - d29 * d19 + +HEAPF32[i13 + 312 >> 2];
michael@0 22141 } else {
michael@0 22142 d52 = 0.0;
michael@0 22143 d53 = 0.0;
michael@0 22144 d54 = 0.0;
michael@0 22145 }
michael@0 22146 d19 = d49 - d52;
michael@0 22147 d52 = d50 - d53;
michael@0 22148 d53 = d51 - d54;
michael@0 22149 HEAPF32[i7 >> 2] = d19;
michael@0 22150 HEAPF32[i7 + 4 >> 2] = d52;
michael@0 22151 HEAPF32[i7 + 8 >> 2] = d53;
michael@0 22152 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 22153 HEAPF32[i8 >> 2] = +HEAPF32[i23 >> 2] * d19 + d52 * +HEAPF32[i20 >> 2] + d53 * +HEAPF32[i18 >> 2];
michael@0 22154 d53 = +HEAPF32[i5 + 80 >> 2] + +HEAPF32[i6 + 52 >> 2];
michael@0 22155 HEAPF32[i2 + 88 >> 2] = +HEAPF32[i5 + 84 >> 2];
michael@0 22156 do {
michael@0 22157 if ((HEAP32[i5 + 144 >> 2] | 0) > (HEAP32[i6 + 64 >> 2] | 0)) {
michael@0 22158 d55 = 0.0;
michael@0 22159 } else {
michael@0 22160 d52 = +HEAPF32[i5 + 88 >> 2] * (-0.0 - +HEAPF32[i8 >> 2]);
michael@0 22161 if (d52 > 0.0) {
michael@0 22162 d55 = d52;
michael@0 22163 break;
michael@0 22164 }
michael@0 22165 d55 = 0.0;
michael@0 22166 }
michael@0 22167 } while (0);
michael@0 22168 do {
michael@0 22169 if ((HEAP32[i6 + 60 >> 2] & 4 | 0) == 0) {
michael@0 22170 HEAPF32[i2 + 84 >> 2] = 0.0;
michael@0 22171 } else {
michael@0 22172 d52 = +HEAPF32[i5 + 112 >> 2] * +HEAPF32[i6 + 56 >> 2];
michael@0 22173 i8 = i2 + 84 | 0;
michael@0 22174 HEAPF32[i8 >> 2] = d52;
michael@0 22175 do {
michael@0 22176 if (i27) {
michael@0 22177 d19 = +HEAPF32[i12 + 336 >> 2];
michael@0 22178 if (d19 == 0.0) {
michael@0 22179 break;
michael@0 22180 }
michael@0 22181 d54 = d52 * d19 * +HEAPF32[i2 + 20 >> 2] * +HEAPF32[i12 + 344 >> 2];
michael@0 22182 d51 = d52 * d19 * +HEAPF32[i2 + 24 >> 2] * +HEAPF32[i12 + 348 >> 2];
michael@0 22183 i18 = i12 + 504 | 0;
michael@0 22184 HEAPF32[i18 >> 2] = +HEAPF32[i18 >> 2] + d52 * d19 * +HEAPF32[i9 >> 2] * +HEAPF32[i12 + 340 >> 2];
michael@0 22185 i18 = i12 + 508 | 0;
michael@0 22186 HEAPF32[i18 >> 2] = d54 + +HEAPF32[i18 >> 2];
michael@0 22187 i18 = i12 + 512 | 0;
michael@0 22188 HEAPF32[i18 >> 2] = d51 + +HEAPF32[i18 >> 2];
michael@0 22189 d51 = d52 * +HEAPF32[i12 + 540 >> 2] * +HEAPF32[i32 >> 2];
michael@0 22190 d54 = d52 * +HEAPF32[i12 + 544 >> 2] * +HEAPF32[i33 >> 2];
michael@0 22191 i18 = i12 + 520 | 0;
michael@0 22192 HEAPF32[i18 >> 2] = d52 * +HEAPF32[i12 + 536 >> 2] * +HEAPF32[i31 >> 2] + +HEAPF32[i18 >> 2];
michael@0 22193 i18 = i12 + 524 | 0;
michael@0 22194 HEAPF32[i18 >> 2] = d51 + +HEAPF32[i18 >> 2];
michael@0 22195 i18 = i12 + 528 | 0;
michael@0 22196 HEAPF32[i18 >> 2] = d54 + +HEAPF32[i18 >> 2];
michael@0 22197 }
michael@0 22198 } while (0);
michael@0 22199 if (!i34) {
michael@0 22200 break;
michael@0 22201 }
michael@0 22202 d52 = +HEAPF32[i13 + 336 >> 2];
michael@0 22203 d54 = -0.0 - +HEAPF32[i8 >> 2];
michael@0 22204 if (d52 == 0.0) {
michael@0 22205 break;
michael@0 22206 }
michael@0 22207 d51 = -0.0 - +HEAPF32[i40 >> 2];
michael@0 22208 d19 = -0.0 - +HEAPF32[i39 >> 2];
michael@0 22209 d50 = -0.0 - +HEAPF32[i38 >> 2];
michael@0 22210 d49 = d52 * +HEAPF32[i2 + 20 >> 2] * +HEAPF32[i13 + 344 >> 2] * d54;
michael@0 22211 d29 = d52 * +HEAPF32[i2 + 24 >> 2] * +HEAPF32[i13 + 348 >> 2] * d54;
michael@0 22212 i18 = i13 + 504 | 0;
michael@0 22213 HEAPF32[i18 >> 2] = +HEAPF32[i18 >> 2] + d52 * +HEAPF32[i9 >> 2] * +HEAPF32[i13 + 340 >> 2] * d54;
michael@0 22214 i18 = i13 + 508 | 0;
michael@0 22215 HEAPF32[i18 >> 2] = d49 + +HEAPF32[i18 >> 2];
michael@0 22216 i18 = i13 + 512 | 0;
michael@0 22217 HEAPF32[i18 >> 2] = d29 + +HEAPF32[i18 >> 2];
michael@0 22218 d29 = +HEAPF32[i13 + 540 >> 2] * d54 * d19;
michael@0 22219 d19 = +HEAPF32[i13 + 544 >> 2] * d54 * d51;
michael@0 22220 i18 = i13 + 520 | 0;
michael@0 22221 HEAPF32[i18 >> 2] = +HEAPF32[i13 + 536 >> 2] * d54 * d50 + +HEAPF32[i18 >> 2];
michael@0 22222 i18 = i13 + 524 | 0;
michael@0 22223 HEAPF32[i18 >> 2] = d29 + +HEAPF32[i18 >> 2];
michael@0 22224 i18 = i13 + 528 | 0;
michael@0 22225 HEAPF32[i18 >> 2] = d19 + +HEAPF32[i18 >> 2];
michael@0 22226 }
michael@0 22227 } while (0);
michael@0 22228 HEAPF32[i2 + 80 >> 2] = 0.0;
michael@0 22229 if (i27) {
michael@0 22230 d56 = +HEAPF32[i12 + 304 >> 2];
michael@0 22231 d57 = +HEAPF32[i12 + 308 >> 2];
michael@0 22232 d58 = +HEAPF32[i12 + 312 >> 2];
michael@0 22233 } else {
michael@0 22234 d56 = 0.0;
michael@0 22235 d57 = 0.0;
michael@0 22236 d58 = 0.0;
michael@0 22237 }
michael@0 22238 d19 = +HEAPF32[i9 >> 2];
michael@0 22239 d29 = +HEAPF32[i2 + 20 >> 2];
michael@0 22240 d50 = +HEAPF32[i2 + 24 >> 2];
michael@0 22241 if (i27) {
michael@0 22242 d59 = +HEAPF32[i12 + 320 >> 2];
michael@0 22243 d60 = +HEAPF32[i12 + 324 >> 2];
michael@0 22244 d61 = +HEAPF32[i12 + 328 >> 2];
michael@0 22245 } else {
michael@0 22246 d59 = 0.0;
michael@0 22247 d60 = 0.0;
michael@0 22248 d61 = 0.0;
michael@0 22249 }
michael@0 22250 if (i34) {
michael@0 22251 d62 = +HEAPF32[i13 + 320 >> 2];
michael@0 22252 d63 = +HEAPF32[i13 + 324 >> 2];
michael@0 22253 d64 = +HEAPF32[i13 + 328 >> 2];
michael@0 22254 d65 = d19 * +HEAPF32[i13 + 304 >> 2] + d29 * +HEAPF32[i13 + 308 >> 2] + d50 * +HEAPF32[i13 + 312 >> 2];
michael@0 22255 } else {
michael@0 22256 d62 = 0.0;
michael@0 22257 d63 = 0.0;
michael@0 22258 d64 = 0.0;
michael@0 22259 d65 = d19 * 0.0 + d29 * 0.0 + d50 * 0.0;
michael@0 22260 }
michael@0 22261 d54 = d55 - (d56 * d19 + d57 * d29 + d58 * d50 + (d59 * +HEAPF32[i45 >> 2] + d60 * +HEAPF32[i44 >> 2] + d61 * +HEAPF32[i11 >> 2]) + (d62 * +HEAPF32[i46 >> 2] + d63 * +HEAPF32[i47 >> 2] + d64 * +HEAPF32[i48 >> 2] - d65));
michael@0 22262 if (d53 > 0.0) {
michael@0 22263 d66 = d54 - d53 / +HEAPF32[i6 + 12 >> 2];
michael@0 22264 d67 = 0.0;
michael@0 22265 } else {
michael@0 22266 d66 = d54;
michael@0 22267 d67 = +HEAPF32[i6 + 32 >> 2] * (-0.0 - d53) / +HEAPF32[i6 + 12 >> 2];
michael@0 22268 }
michael@0 22269 d54 = +HEAPF32[i43 >> 2];
michael@0 22270 d65 = d67 * d54;
michael@0 22271 d67 = d66 * d54;
michael@0 22272 do {
michael@0 22273 if ((HEAP32[i6 + 44 >> 2] | 0) != 0) {
michael@0 22274 if (d53 > +HEAPF32[i6 + 48 >> 2]) {
michael@0 22275 break;
michael@0 22276 }
michael@0 22277 HEAPF32[i2 + 116 >> 2] = d67;
michael@0 22278 HEAPF32[i2 + 132 >> 2] = d65;
michael@0 22279 i68 = i2 + 120 | 0;
michael@0 22280 HEAPF32[i68 >> 2] = 0.0;
michael@0 22281 i69 = i2 + 124 | 0;
michael@0 22282 HEAPF32[i69 >> 2] = 0.0;
michael@0 22283 i70 = i2 + 128 | 0;
michael@0 22284 HEAPF32[i70 >> 2] = 1.0e10;
michael@0 22285 return;
michael@0 22286 }
michael@0 22287 } while (0);
michael@0 22288 HEAPF32[i2 + 116 >> 2] = d65 + d67;
michael@0 22289 HEAPF32[i2 + 132 >> 2] = 0.0;
michael@0 22290 i68 = i2 + 120 | 0;
michael@0 22291 HEAPF32[i68 >> 2] = 0.0;
michael@0 22292 i69 = i2 + 124 | 0;
michael@0 22293 HEAPF32[i69 >> 2] = 0.0;
michael@0 22294 i70 = i2 + 128 | 0;
michael@0 22295 HEAPF32[i70 >> 2] = 1.0e10;
michael@0 22296 return;
michael@0 22297 }
michael@0 22298 function __ZN20btConvexHullInternal15mergeProjectionERNS_16IntermediateHullES1_RPNS_6VertexES4_(i1, i2, i3, i4, i5) {
michael@0 22299 i1 = i1 | 0;
michael@0 22300 i2 = i2 | 0;
michael@0 22301 i3 = i3 | 0;
michael@0 22302 i4 = i4 | 0;
michael@0 22303 i5 = i5 | 0;
michael@0 22304 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0;
michael@0 22305 i1 = i2 + 12 | 0;
michael@0 22306 i6 = HEAP32[i1 >> 2] | 0;
michael@0 22307 i7 = HEAP32[i3 + 8 >> 2] | 0;
michael@0 22308 L791 : do {
michael@0 22309 if ((HEAP32[i6 + 88 >> 2] | 0) == (HEAP32[i7 + 88 >> 2] | 0)) {
michael@0 22310 if ((HEAP32[i6 + 92 >> 2] | 0) != (HEAP32[i7 + 92 >> 2] | 0)) {
michael@0 22311 break;
michael@0 22312 }
michael@0 22313 i8 = HEAP32[i7 + 4 >> 2] | 0;
michael@0 22314 if ((i8 | 0) == (i7 | 0)) {
michael@0 22315 HEAP32[i4 >> 2] = i6;
michael@0 22316 i9 = HEAP32[i7 + 8 >> 2] | 0;
michael@0 22317 if ((i9 | 0) == 0) {
michael@0 22318 i10 = 0;
michael@0 22319 i11 = i7;
michael@0 22320 HEAP32[i5 >> 2] = i11;
michael@0 22321 return i10 | 0;
michael@0 22322 }
michael@0 22323 i10 = 0;
michael@0 22324 i11 = HEAP32[i9 + 12 >> 2] | 0;
michael@0 22325 HEAP32[i5 >> 2] = i11;
michael@0 22326 return i10 | 0;
michael@0 22327 }
michael@0 22328 i9 = HEAP32[i7 >> 2] | 0;
michael@0 22329 HEAP32[i8 >> 2] = i9;
michael@0 22330 HEAP32[i9 + 4 >> 2] = i8;
michael@0 22331 i12 = i3 | 0;
michael@0 22332 L801 : do {
michael@0 22333 if ((i7 | 0) == (HEAP32[i12 >> 2] | 0)) {
michael@0 22334 i13 = HEAP32[i9 + 88 >> 2] | 0;
michael@0 22335 i14 = HEAP32[i8 + 88 >> 2] | 0;
michael@0 22336 do {
michael@0 22337 if ((i13 | 0) >= (i14 | 0)) {
michael@0 22338 if ((i13 | 0) == (i14 | 0)) {
michael@0 22339 if ((HEAP32[i9 + 92 >> 2] | 0) < (HEAP32[i8 + 92 >> 2] | 0)) {
michael@0 22340 break;
michael@0 22341 }
michael@0 22342 }
michael@0 22343 HEAP32[i12 >> 2] = i8;
michael@0 22344 break L801;
michael@0 22345 }
michael@0 22346 } while (0);
michael@0 22347 HEAP32[i12 >> 2] = i9;
michael@0 22348 }
michael@0 22349 } while (0);
michael@0 22350 i12 = i3 + 4 | 0;
michael@0 22351 if ((i7 | 0) != (HEAP32[i12 >> 2] | 0)) {
michael@0 22352 break;
michael@0 22353 }
michael@0 22354 i14 = HEAP32[i9 + 88 >> 2] | 0;
michael@0 22355 i13 = HEAP32[i8 + 88 >> 2] | 0;
michael@0 22356 do {
michael@0 22357 if ((i14 | 0) <= (i13 | 0)) {
michael@0 22358 if ((i14 | 0) == (i13 | 0)) {
michael@0 22359 if ((HEAP32[i9 + 92 >> 2] | 0) > (HEAP32[i8 + 92 >> 2] | 0)) {
michael@0 22360 break;
michael@0 22361 }
michael@0 22362 }
michael@0 22363 HEAP32[i12 >> 2] = i8;
michael@0 22364 break L791;
michael@0 22365 }
michael@0 22366 } while (0);
michael@0 22367 HEAP32[i12 >> 2] = i9;
michael@0 22368 }
michael@0 22369 } while (0);
michael@0 22370 i7 = i2 + 4 | 0;
michael@0 22371 i6 = i3 + 4 | 0;
michael@0 22372 i8 = i2 | 0;
michael@0 22373 i2 = i3 | 0;
michael@0 22374 i13 = 0;
michael@0 22375 i14 = 1;
michael@0 22376 i15 = 0;
michael@0 22377 i16 = 0;
michael@0 22378 i17 = i6;
michael@0 22379 i18 = i7;
michael@0 22380 L818 : while (1) {
michael@0 22381 i19 = i13;
michael@0 22382 i20 = HEAP32[i17 >> 2] | 0;
michael@0 22383 i21 = HEAP32[i18 >> 2] | 0;
michael@0 22384 while (1) {
michael@0 22385 i22 = HEAP32[i21 + 88 >> 2] | 0;
michael@0 22386 i23 = Math_imul((HEAP32[i20 + 88 >> 2] | 0) - i22 | 0, i14) | 0;
michael@0 22387 L822 : do {
michael@0 22388 if ((i23 | 0) > 0) {
michael@0 22389 i24 = (i19 | 0) != 0;
michael@0 22390 i25 = i21;
michael@0 22391 i26 = i20;
michael@0 22392 i27 = i23;
michael@0 22393 i28 = HEAP32[i20 + 92 >> 2] | 0;
michael@0 22394 while (1) {
michael@0 22395 i29 = i26 + 88 | 0;
michael@0 22396 i30 = i25 + 88 | 0;
michael@0 22397 i31 = HEAP32[i25 + 92 >> 2] | 0;
michael@0 22398 i32 = i28 - i31 | 0;
michael@0 22399 i33 = HEAP32[(i24 ? i25 | 0 : i25 + 4 | 0) >> 2] | 0;
michael@0 22400 L864 : do {
michael@0 22401 if ((i33 | 0) == (i25 | 0)) {
michael@0 22402 i34 = i27;
michael@0 22403 i35 = i25;
michael@0 22404 i36 = i30;
michael@0 22405 i37 = i32;
michael@0 22406 } else {
michael@0 22407 i38 = i29 | 0;
michael@0 22408 i39 = i27;
michael@0 22409 i40 = i25;
michael@0 22410 i41 = i30;
michael@0 22411 i42 = i31;
michael@0 22412 i43 = i32;
michael@0 22413 i44 = i33;
michael@0 22414 while (1) {
michael@0 22415 i45 = HEAP32[i44 + 88 >> 2] | 0;
michael@0 22416 i46 = Math_imul(i45 - (HEAP32[i41 >> 2] | 0) | 0, i14) | 0;
michael@0 22417 i47 = HEAP32[i44 + 92 >> 2] | 0;
michael@0 22418 i48 = i47 - i42 | 0;
michael@0 22419 if ((i48 | 0) >= 1) {
michael@0 22420 i34 = i39;
michael@0 22421 i35 = i40;
michael@0 22422 i36 = i41;
michael@0 22423 i37 = i43;
michael@0 22424 break L864;
michael@0 22425 }
michael@0 22426 if ((i46 | 0) != 0) {
michael@0 22427 if ((i46 | 0) >= 0) {
michael@0 22428 i34 = i39;
michael@0 22429 i35 = i40;
michael@0 22430 i36 = i41;
michael@0 22431 i37 = i43;
michael@0 22432 break L864;
michael@0 22433 }
michael@0 22434 i49 = Math_imul(i48, i39) | 0;
michael@0 22435 if ((i49 | 0) > (Math_imul(i46, i43) | 0)) {
michael@0 22436 i34 = i39;
michael@0 22437 i35 = i40;
michael@0 22438 i36 = i41;
michael@0 22439 i37 = i43;
michael@0 22440 break L864;
michael@0 22441 }
michael@0 22442 }
michael@0 22443 i46 = Math_imul((HEAP32[i38 >> 2] | 0) - i45 | 0, i14) | 0;
michael@0 22444 i45 = i44 + 88 | 0;
michael@0 22445 i49 = i28 - i47 | 0;
michael@0 22446 i48 = HEAP32[(i24 ? i44 | 0 : i44 + 4 | 0) >> 2] | 0;
michael@0 22447 if ((i48 | 0) == (i44 | 0)) {
michael@0 22448 i34 = i46;
michael@0 22449 i35 = i44;
michael@0 22450 i36 = i45;
michael@0 22451 i37 = i49;
michael@0 22452 break;
michael@0 22453 } else {
michael@0 22454 i39 = i46;
michael@0 22455 i40 = i44;
michael@0 22456 i41 = i45;
michael@0 22457 i42 = i47;
michael@0 22458 i43 = i49;
michael@0 22459 i44 = i48;
michael@0 22460 }
michael@0 22461 }
michael@0 22462 }
michael@0 22463 } while (0);
michael@0 22464 i33 = HEAP32[(i24 ? i26 | 0 : i26 + 4 | 0) >> 2] | 0;
michael@0 22465 if ((i33 | 0) == (i26 | 0)) {
michael@0 22466 i50 = i35;
michael@0 22467 i51 = i26;
michael@0 22468 break L822;
michael@0 22469 }
michael@0 22470 i32 = HEAP32[i33 + 88 >> 2] | 0;
michael@0 22471 i31 = Math_imul(i32 - (HEAP32[i29 >> 2] | 0) | 0, i14) | 0;
michael@0 22472 i30 = HEAP32[i33 + 92 >> 2] | 0;
michael@0 22473 i44 = i30 - i28 | 0;
michael@0 22474 i43 = Math_imul(i32 - (HEAP32[i36 >> 2] | 0) | 0, i14) | 0;
michael@0 22475 if (!((i43 | 0) > 0 & (i44 | 0) < 0)) {
michael@0 22476 i50 = i35;
michael@0 22477 i51 = i26;
michael@0 22478 break L822;
michael@0 22479 }
michael@0 22480 if ((i31 | 0) == 0) {
michael@0 22481 i25 = i35;
michael@0 22482 i26 = i33;
michael@0 22483 i27 = i43;
michael@0 22484 i28 = i30;
michael@0 22485 continue;
michael@0 22486 }
michael@0 22487 if ((i31 | 0) >= 0) {
michael@0 22488 i50 = i35;
michael@0 22489 i51 = i26;
michael@0 22490 break L822;
michael@0 22491 }
michael@0 22492 i32 = Math_imul(i44, i34) | 0;
michael@0 22493 if ((i32 | 0) < (Math_imul(i31, i37) | 0)) {
michael@0 22494 i25 = i35;
michael@0 22495 i26 = i33;
michael@0 22496 i27 = i43;
michael@0 22497 i28 = i30;
michael@0 22498 } else {
michael@0 22499 i50 = i35;
michael@0 22500 i51 = i26;
michael@0 22501 break;
michael@0 22502 }
michael@0 22503 }
michael@0 22504 } else {
michael@0 22505 if ((i23 | 0) < 0) {
michael@0 22506 i26 = (i19 | 0) != 0;
michael@0 22507 i28 = i21;
michael@0 22508 i27 = i20;
michael@0 22509 i25 = i23;
michael@0 22510 i24 = HEAP32[i20 + 92 >> 2] | 0;
michael@0 22511 i30 = HEAP32[i21 + 92 >> 2] | 0;
michael@0 22512 while (1) {
michael@0 22513 i43 = HEAP32[(i26 ? i27 + 4 | 0 : i27 | 0) >> 2] | 0;
michael@0 22514 i33 = (i43 | 0) == (i27 | 0);
michael@0 22515 i31 = i27 + 88 | 0;
michael@0 22516 i32 = i43 + 88 | 0;
michael@0 22517 i44 = i43 + 92 | 0;
michael@0 22518 i42 = i28;
michael@0 22519 i41 = i25;
michael@0 22520 i40 = i30;
michael@0 22521 L828 : while (1) {
michael@0 22522 i52 = i42 + 88 | 0;
michael@0 22523 i39 = i24 - i40 | 0;
michael@0 22524 do {
michael@0 22525 if (!i33) {
michael@0 22526 i53 = HEAP32[i32 >> 2] | 0;
michael@0 22527 i38 = Math_imul(i53 - (HEAP32[i31 >> 2] | 0) | 0, i14) | 0;
michael@0 22528 i54 = HEAP32[i44 >> 2] | 0;
michael@0 22529 i48 = i54 - i24 | 0;
michael@0 22530 if ((i48 | 0) <= -1) {
michael@0 22531 break;
michael@0 22532 }
michael@0 22533 if ((i38 | 0) == 0) {
michael@0 22534 break L828;
michael@0 22535 }
michael@0 22536 if ((i38 | 0) >= 0) {
michael@0 22537 break;
michael@0 22538 }
michael@0 22539 i49 = Math_imul(i48, i41) | 0;
michael@0 22540 if ((i49 | 0) <= (Math_imul(i38, i39) | 0)) {
michael@0 22541 break L828;
michael@0 22542 }
michael@0 22543 }
michael@0 22544 } while (0);
michael@0 22545 i38 = HEAP32[(i26 ? i42 + 4 | 0 : i42 | 0) >> 2] | 0;
michael@0 22546 if ((i38 | 0) == (i42 | 0)) {
michael@0 22547 i50 = i42;
michael@0 22548 i51 = i27;
michael@0 22549 break L822;
michael@0 22550 }
michael@0 22551 i49 = HEAP32[i38 + 88 >> 2] | 0;
michael@0 22552 i48 = Math_imul(i49 - (HEAP32[i52 >> 2] | 0) | 0, i14) | 0;
michael@0 22553 i47 = HEAP32[i38 + 92 >> 2] | 0;
michael@0 22554 i45 = i47 - i40 | 0;
michael@0 22555 i46 = Math_imul((HEAP32[i31 >> 2] | 0) - i49 | 0, i14) | 0;
michael@0 22556 if (!((i46 | 0) < 0 & (i45 | 0) > 0)) {
michael@0 22557 i50 = i42;
michael@0 22558 i51 = i27;
michael@0 22559 break L822;
michael@0 22560 }
michael@0 22561 if ((i48 | 0) == 0) {
michael@0 22562 i42 = i38;
michael@0 22563 i41 = i46;
michael@0 22564 i40 = i47;
michael@0 22565 continue;
michael@0 22566 }
michael@0 22567 if ((i48 | 0) >= 0) {
michael@0 22568 i50 = i42;
michael@0 22569 i51 = i27;
michael@0 22570 break L822;
michael@0 22571 }
michael@0 22572 i49 = Math_imul(i45, i41) | 0;
michael@0 22573 if ((i49 | 0) < (Math_imul(i48, i39) | 0)) {
michael@0 22574 i42 = i38;
michael@0 22575 i41 = i46;
michael@0 22576 i40 = i47;
michael@0 22577 } else {
michael@0 22578 i50 = i42;
michael@0 22579 i51 = i27;
michael@0 22580 break L822;
michael@0 22581 }
michael@0 22582 }
michael@0 22583 i28 = i42;
michael@0 22584 i27 = i43;
michael@0 22585 i25 = Math_imul(i53 - (HEAP32[i52 >> 2] | 0) | 0, i14) | 0;
michael@0 22586 i24 = i54;
michael@0 22587 i30 = i40;
michael@0 22588 }
michael@0 22589 }
michael@0 22590 i30 = HEAP32[i21 + 92 >> 2] | 0;
michael@0 22591 i24 = (i19 | 0) != 0;
michael@0 22592 L842 : do {
michael@0 22593 if (i24) {
michael@0 22594 i25 = i21;
michael@0 22595 i27 = i30;
michael@0 22596 while (1) {
michael@0 22597 i28 = HEAP32[i25 >> 2] | 0;
michael@0 22598 if ((i28 | 0) == (i21 | 0)) {
michael@0 22599 i55 = i25;
michael@0 22600 break L842;
michael@0 22601 }
michael@0 22602 if ((HEAP32[i28 + 88 >> 2] | 0) != (i22 | 0)) {
michael@0 22603 i55 = i25;
michael@0 22604 break L842;
michael@0 22605 }
michael@0 22606 i26 = HEAP32[i28 + 92 >> 2] | 0;
michael@0 22607 if ((i26 | 0) > (i27 | 0)) {
michael@0 22608 i55 = i25;
michael@0 22609 break;
michael@0 22610 } else {
michael@0 22611 i25 = i28;
michael@0 22612 i27 = i26;
michael@0 22613 }
michael@0 22614 }
michael@0 22615 } else {
michael@0 22616 i27 = i21;
michael@0 22617 i25 = i30;
michael@0 22618 while (1) {
michael@0 22619 i40 = HEAP32[i27 + 4 >> 2] | 0;
michael@0 22620 if ((i40 | 0) == (i21 | 0)) {
michael@0 22621 i55 = i27;
michael@0 22622 break L842;
michael@0 22623 }
michael@0 22624 if ((HEAP32[i40 + 88 >> 2] | 0) != (i22 | 0)) {
michael@0 22625 i55 = i27;
michael@0 22626 break L842;
michael@0 22627 }
michael@0 22628 i43 = HEAP32[i40 + 92 >> 2] | 0;
michael@0 22629 if ((i43 | 0) > (i25 | 0)) {
michael@0 22630 i55 = i27;
michael@0 22631 break;
michael@0 22632 } else {
michael@0 22633 i27 = i40;
michael@0 22634 i25 = i43;
michael@0 22635 }
michael@0 22636 }
michael@0 22637 }
michael@0 22638 } while (0);
michael@0 22639 i30 = HEAP32[i20 + 92 >> 2] | 0;
michael@0 22640 if (i24) {
michael@0 22641 i25 = i20;
michael@0 22642 i27 = i30;
michael@0 22643 while (1) {
michael@0 22644 i43 = HEAP32[i25 + 4 >> 2] | 0;
michael@0 22645 if ((i43 | 0) == (i20 | 0)) {
michael@0 22646 i50 = i55;
michael@0 22647 i51 = i25;
michael@0 22648 break L822;
michael@0 22649 }
michael@0 22650 if ((HEAP32[i43 + 88 >> 2] | 0) != (i22 | 0)) {
michael@0 22651 i50 = i55;
michael@0 22652 i51 = i25;
michael@0 22653 break L822;
michael@0 22654 }
michael@0 22655 i40 = HEAP32[i43 + 92 >> 2] | 0;
michael@0 22656 if ((i40 | 0) < (i27 | 0)) {
michael@0 22657 i50 = i55;
michael@0 22658 i51 = i25;
michael@0 22659 break;
michael@0 22660 } else {
michael@0 22661 i25 = i43;
michael@0 22662 i27 = i40;
michael@0 22663 }
michael@0 22664 }
michael@0 22665 } else {
michael@0 22666 i27 = i20;
michael@0 22667 i25 = i30;
michael@0 22668 while (1) {
michael@0 22669 i24 = HEAP32[i27 >> 2] | 0;
michael@0 22670 if ((i24 | 0) == (i20 | 0)) {
michael@0 22671 i50 = i55;
michael@0 22672 i51 = i27;
michael@0 22673 break L822;
michael@0 22674 }
michael@0 22675 if ((HEAP32[i24 + 88 >> 2] | 0) != (i22 | 0)) {
michael@0 22676 i50 = i55;
michael@0 22677 i51 = i27;
michael@0 22678 break L822;
michael@0 22679 }
michael@0 22680 i40 = HEAP32[i24 + 92 >> 2] | 0;
michael@0 22681 if ((i40 | 0) < (i25 | 0)) {
michael@0 22682 i50 = i55;
michael@0 22683 i51 = i27;
michael@0 22684 break;
michael@0 22685 } else {
michael@0 22686 i27 = i24;
michael@0 22687 i25 = i40;
michael@0 22688 }
michael@0 22689 }
michael@0 22690 }
michael@0 22691 }
michael@0 22692 } while (0);
michael@0 22693 if ((i19 | 0) == 0) {
michael@0 22694 i13 = 1;
michael@0 22695 i14 = -1;
michael@0 22696 i15 = i51;
michael@0 22697 i16 = i50;
michael@0 22698 i17 = i2;
michael@0 22699 i18 = i8;
michael@0 22700 continue L818;
michael@0 22701 }
michael@0 22702 i22 = i19 + 1 | 0;
michael@0 22703 if ((i22 | 0) < 2) {
michael@0 22704 i19 = i22;
michael@0 22705 i20 = i51;
michael@0 22706 i21 = i50;
michael@0 22707 } else {
michael@0 22708 break L818;
michael@0 22709 }
michael@0 22710 }
michael@0 22711 }
michael@0 22712 HEAP32[i50 + 4 >> 2] = i51;
michael@0 22713 HEAP32[i51 >> 2] = i50;
michael@0 22714 HEAP32[i16 >> 2] = i15;
michael@0 22715 HEAP32[i15 + 4 >> 2] = i16;
michael@0 22716 i50 = HEAP32[i2 >> 2] | 0;
michael@0 22717 if ((HEAP32[i50 + 88 >> 2] | 0) < (HEAP32[(HEAP32[i8 >> 2] | 0) + 88 >> 2] | 0)) {
michael@0 22718 HEAP32[i8 >> 2] = i50;
michael@0 22719 }
michael@0 22720 i50 = HEAP32[i6 >> 2] | 0;
michael@0 22721 if ((HEAP32[i50 + 88 >> 2] | 0) >= (HEAP32[(HEAP32[i7 >> 2] | 0) + 88 >> 2] | 0)) {
michael@0 22722 HEAP32[i7 >> 2] = i50;
michael@0 22723 }
michael@0 22724 HEAP32[i1 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 22725 HEAP32[i4 >> 2] = i16;
michael@0 22726 i10 = 1;
michael@0 22727 i11 = i15;
michael@0 22728 HEAP32[i5 >> 2] = i11;
michael@0 22729 return i10 | 0;
michael@0 22730 }
michael@0 22731 function __ZN20btConvexHullInternal7computeEPKvbii(i1, i2, i3, i4, i5) {
michael@0 22732 i1 = i1 | 0;
michael@0 22733 i2 = i2 | 0;
michael@0 22734 i3 = i3 | 0;
michael@0 22735 i4 = i4 | 0;
michael@0 22736 i5 = i5 | 0;
michael@0 22737 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, i19 = 0, i20 = 0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, i34 = 0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, d47 = 0.0, d48 = 0.0, d49 = 0.0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0;
michael@0 22738 i6 = STACKTOP;
michael@0 22739 STACKTOP = STACKTOP + 88 | 0;
michael@0 22740 i7 = i6 | 0;
michael@0 22741 i8 = i6 + 24 | 0;
michael@0 22742 i9 = i6 + 40 | 0;
michael@0 22743 i10 = i6 + 56 | 0;
michael@0 22744 i11 = i6 + 72 | 0;
michael@0 22745 i12 = (i5 | 0) > 0;
michael@0 22746 do {
michael@0 22747 if (i3) {
michael@0 22748 if (i12) {
michael@0 22749 d13 = 1.0000000150474662e+30;
michael@0 22750 d14 = 1.0000000150474662e+30;
michael@0 22751 d15 = 1.0000000150474662e+30;
michael@0 22752 d16 = -1.0000000150474662e+30;
michael@0 22753 d17 = -1.0000000150474662e+30;
michael@0 22754 d18 = -1.0000000150474662e+30;
michael@0 22755 i19 = 0;
michael@0 22756 i20 = i2;
michael@0 22757 } else {
michael@0 22758 d21 = -1.0000000150474662e+30;
michael@0 22759 d22 = -1.0000000150474662e+30;
michael@0 22760 d23 = -1.0000000150474662e+30;
michael@0 22761 d24 = 1.0000000150474662e+30;
michael@0 22762 d25 = 1.0000000150474662e+30;
michael@0 22763 d26 = 1.0000000150474662e+30;
michael@0 22764 break;
michael@0 22765 }
michael@0 22766 while (1) {
michael@0 22767 d27 = +HEAPF64[i20 >> 3];
michael@0 22768 d28 = +HEAPF64[i20 + 8 >> 3];
michael@0 22769 d29 = +HEAPF64[i20 + 16 >> 3];
michael@0 22770 d30 = d27 < d15 ? d27 : d15;
michael@0 22771 d31 = d28 < d14 ? d28 : d14;
michael@0 22772 d32 = d29 < d13 ? d29 : d13;
michael@0 22773 d33 = d18 < d27 ? d27 : d18;
michael@0 22774 d27 = d17 < d28 ? d28 : d17;
michael@0 22775 d28 = d16 < d29 ? d29 : d16;
michael@0 22776 i34 = i19 + 1 | 0;
michael@0 22777 if ((i34 | 0) < (i5 | 0)) {
michael@0 22778 d13 = d32;
michael@0 22779 d14 = d31;
michael@0 22780 d15 = d30;
michael@0 22781 d16 = d28;
michael@0 22782 d17 = d27;
michael@0 22783 d18 = d33;
michael@0 22784 i19 = i34;
michael@0 22785 i20 = i20 + i4 | 0;
michael@0 22786 } else {
michael@0 22787 d21 = d33;
michael@0 22788 d22 = d27;
michael@0 22789 d23 = d28;
michael@0 22790 d24 = d30;
michael@0 22791 d25 = d31;
michael@0 22792 d26 = d32;
michael@0 22793 break;
michael@0 22794 }
michael@0 22795 }
michael@0 22796 } else {
michael@0 22797 if (i12) {
michael@0 22798 d35 = 1.0000000150474662e+30;
michael@0 22799 d36 = 1.0000000150474662e+30;
michael@0 22800 d37 = 1.0000000150474662e+30;
michael@0 22801 d38 = -1.0000000150474662e+30;
michael@0 22802 d39 = -1.0000000150474662e+30;
michael@0 22803 d40 = -1.0000000150474662e+30;
michael@0 22804 i41 = 0;
michael@0 22805 i42 = i2;
michael@0 22806 } else {
michael@0 22807 d21 = -1.0000000150474662e+30;
michael@0 22808 d22 = -1.0000000150474662e+30;
michael@0 22809 d23 = -1.0000000150474662e+30;
michael@0 22810 d24 = 1.0000000150474662e+30;
michael@0 22811 d25 = 1.0000000150474662e+30;
michael@0 22812 d26 = 1.0000000150474662e+30;
michael@0 22813 break;
michael@0 22814 }
michael@0 22815 while (1) {
michael@0 22816 d32 = +HEAPF32[i42 >> 2];
michael@0 22817 d31 = +HEAPF32[i42 + 4 >> 2];
michael@0 22818 d30 = +HEAPF32[i42 + 8 >> 2];
michael@0 22819 d28 = d32 < d37 ? d32 : d37;
michael@0 22820 d27 = d31 < d36 ? d31 : d36;
michael@0 22821 d33 = d30 < d35 ? d30 : d35;
michael@0 22822 d29 = d40 < d32 ? d32 : d40;
michael@0 22823 d32 = d39 < d31 ? d31 : d39;
michael@0 22824 d31 = d38 < d30 ? d30 : d38;
michael@0 22825 i34 = i41 + 1 | 0;
michael@0 22826 if ((i34 | 0) < (i5 | 0)) {
michael@0 22827 d35 = d33;
michael@0 22828 d36 = d27;
michael@0 22829 d37 = d28;
michael@0 22830 d38 = d31;
michael@0 22831 d39 = d32;
michael@0 22832 d40 = d29;
michael@0 22833 i41 = i34;
michael@0 22834 i42 = i42 + i4 | 0;
michael@0 22835 } else {
michael@0 22836 d21 = d29;
michael@0 22837 d22 = d32;
michael@0 22838 d23 = d31;
michael@0 22839 d24 = d28;
michael@0 22840 d25 = d27;
michael@0 22841 d26 = d33;
michael@0 22842 break;
michael@0 22843 }
michael@0 22844 }
michael@0 22845 }
michael@0 22846 } while (0);
michael@0 22847 d40 = d21 - d24;
michael@0 22848 d39 = d22 - d25;
michael@0 22849 d38 = d23 - d26;
michael@0 22850 if (d40 < d39) {
michael@0 22851 i42 = i1 + 112 | 0;
michael@0 22852 HEAP32[i42 >> 2] = d39 < d38 ? 2 : 1;
michael@0 22853 i43 = d40 < d38 ? 0 : 2;
michael@0 22854 i44 = i42;
michael@0 22855 } else {
michael@0 22856 i42 = i1 + 112 | 0;
michael@0 22857 HEAP32[i42 >> 2] = d40 < d38 ? 2 : 0;
michael@0 22858 i43 = d39 < d38 ? 1 : 2;
michael@0 22859 i44 = i42;
michael@0 22860 }
michael@0 22861 i42 = i1 + 104 | 0;
michael@0 22862 HEAP32[i42 >> 2] = i43;
michael@0 22863 i41 = HEAP32[i44 >> 2] | 0;
michael@0 22864 if ((i43 | 0) == (i41 | 0)) {
michael@0 22865 i20 = ((i43 + 1 | 0) >>> 0) % 3 | 0;
michael@0 22866 HEAP32[i42 >> 2] = i20;
michael@0 22867 i45 = HEAP32[i44 >> 2] | 0;
michael@0 22868 i46 = i20;
michael@0 22869 } else {
michael@0 22870 i45 = i41;
michael@0 22871 i46 = i43;
michael@0 22872 }
michael@0 22873 i43 = i1 + 108 | 0;
michael@0 22874 HEAP32[i43 >> 2] = 3 - i46 - i45;
michael@0 22875 d37 = d40 * 9788566967472434.0e-20;
michael@0 22876 d40 = d39 * 9788566967472434.0e-20;
michael@0 22877 d39 = d38 * 9788566967472434.0e-20;
michael@0 22878 HEAPF32[i1 >> 2] = d37;
michael@0 22879 HEAPF32[i1 + 4 >> 2] = d40;
michael@0 22880 HEAPF32[i1 + 8 >> 2] = d39;
michael@0 22881 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 22882 if (d37 > 0.0) {
michael@0 22883 d47 = 1.0 / d37;
michael@0 22884 } else {
michael@0 22885 d47 = d37;
michael@0 22886 }
michael@0 22887 if (d40 > 0.0) {
michael@0 22888 d48 = 1.0 / d40;
michael@0 22889 } else {
michael@0 22890 d48 = d40;
michael@0 22891 }
michael@0 22892 if (d39 > 0.0) {
michael@0 22893 d49 = 1.0 / d39;
michael@0 22894 } else {
michael@0 22895 d49 = d39;
michael@0 22896 }
michael@0 22897 i45 = i1 + 16 | 0;
michael@0 22898 HEAPF32[i1 + 16 >> 2] = (d24 + d21) * .5;
michael@0 22899 i46 = i1 + 20 | 0;
michael@0 22900 HEAPF32[i46 >> 2] = (d25 + d22) * .5;
michael@0 22901 i41 = i1 + 24 | 0;
michael@0 22902 HEAPF32[i41 >> 2] = (d26 + d23) * .5;
michael@0 22903 HEAPF32[i1 + 28 >> 2] = 0.0;
michael@0 22904 i20 = i7 + 16 | 0;
michael@0 22905 HEAP8[i20] = 1;
michael@0 22906 i19 = i7 + 12 | 0;
michael@0 22907 HEAP32[i19 >> 2] = 0;
michael@0 22908 i34 = i7 + 4 | 0;
michael@0 22909 HEAP32[i34 >> 2] = 0;
michael@0 22910 i50 = i7 + 8 | 0;
michael@0 22911 HEAP32[i50 >> 2] = 0;
michael@0 22912 L1398 : do {
michael@0 22913 if (i12) {
michael@0 22914 i51 = __Z22btAlignedAllocInternalji(i5 << 4, 16) | 0;
michael@0 22915 i52 = HEAP32[i34 >> 2] | 0;
michael@0 22916 if ((i52 | 0) > 0) {
michael@0 22917 i53 = 0;
michael@0 22918 do {
michael@0 22919 i54 = i51 + (i53 << 4) | 0;
michael@0 22920 if ((i54 | 0) != 0) {
michael@0 22921 i55 = i54;
michael@0 22922 i54 = (HEAP32[i19 >> 2] | 0) + (i53 << 4) | 0;
michael@0 22923 HEAP32[i55 >> 2] = HEAP32[i54 >> 2];
michael@0 22924 HEAP32[i55 + 4 >> 2] = HEAP32[i54 + 4 >> 2];
michael@0 22925 HEAP32[i55 + 8 >> 2] = HEAP32[i54 + 8 >> 2];
michael@0 22926 HEAP32[i55 + 12 >> 2] = HEAP32[i54 + 12 >> 2];
michael@0 22927 }
michael@0 22928 i53 = i53 + 1 | 0;
michael@0 22929 } while ((i53 | 0) < (i52 | 0));
michael@0 22930 }
michael@0 22931 i52 = HEAP32[i19 >> 2] | 0;
michael@0 22932 if ((i52 | 0) != 0) {
michael@0 22933 if ((HEAP8[i20] | 0) != 0) {
michael@0 22934 __Z21btAlignedFreeInternalPv(i52);
michael@0 22935 }
michael@0 22936 HEAP32[i19 >> 2] = 0;
michael@0 22937 }
michael@0 22938 HEAP8[i20] = 1;
michael@0 22939 HEAP32[i19 >> 2] = i51;
michael@0 22940 HEAP32[i50 >> 2] = i5;
michael@0 22941 i52 = i8;
michael@0 22942 i53 = 0;
michael@0 22943 i54 = i51;
michael@0 22944 while (1) {
michael@0 22945 i55 = i54 + (i53 << 4) | 0;
michael@0 22946 if ((i55 | 0) != 0) {
michael@0 22947 i56 = i55;
michael@0 22948 HEAP32[i56 >> 2] = HEAP32[i52 >> 2];
michael@0 22949 HEAP32[i56 + 4 >> 2] = HEAP32[i52 + 4 >> 2];
michael@0 22950 HEAP32[i56 + 8 >> 2] = HEAP32[i52 + 8 >> 2];
michael@0 22951 HEAP32[i56 + 12 >> 2] = HEAP32[i52 + 12 >> 2];
michael@0 22952 }
michael@0 22953 i56 = i53 + 1 | 0;
michael@0 22954 if ((i56 | 0) >= (i5 | 0)) {
michael@0 22955 break L1398;
michael@0 22956 }
michael@0 22957 i53 = i56;
michael@0 22958 i54 = HEAP32[i19 >> 2] | 0;
michael@0 22959 }
michael@0 22960 }
michael@0 22961 } while (0);
michael@0 22962 HEAP32[i34 >> 2] = i5;
michael@0 22963 L1421 : do {
michael@0 22964 if (i3) {
michael@0 22965 if (!i12) {
michael@0 22966 break;
michael@0 22967 }
michael@0 22968 i8 = i9 | 0;
michael@0 22969 i54 = i9 + 4 | 0;
michael@0 22970 i53 = i9 + 8 | 0;
michael@0 22971 i52 = i9 + 12 | 0;
michael@0 22972 i51 = HEAP32[i19 >> 2] | 0;
michael@0 22973 d23 = +HEAPF32[i45 >> 2];
michael@0 22974 d26 = +HEAPF32[i46 >> 2];
michael@0 22975 d22 = +HEAPF32[i41 >> 2];
michael@0 22976 i56 = 0;
michael@0 22977 i55 = i2;
michael@0 22978 while (1) {
michael@0 22979 d25 = d48 * (+HEAPF64[i55 + 8 >> 3] - d26);
michael@0 22980 d21 = d49 * (+HEAPF64[i55 + 16 >> 3] - d22);
michael@0 22981 HEAPF32[i8 >> 2] = d47 * (+HEAPF64[i55 >> 3] - d23);
michael@0 22982 HEAPF32[i54 >> 2] = d25;
michael@0 22983 HEAPF32[i53 >> 2] = d21;
michael@0 22984 HEAPF32[i52 >> 2] = 0.0;
michael@0 22985 HEAP32[i51 + (i56 << 4) >> 2] = ~~+HEAPF32[i9 + (HEAP32[i43 >> 2] << 2) >> 2];
michael@0 22986 HEAP32[i51 + (i56 << 4) + 4 >> 2] = ~~+HEAPF32[i9 + (HEAP32[i44 >> 2] << 2) >> 2];
michael@0 22987 HEAP32[i51 + (i56 << 4) + 8 >> 2] = ~~+HEAPF32[i9 + (HEAP32[i42 >> 2] << 2) >> 2];
michael@0 22988 HEAP32[i51 + (i56 << 4) + 12 >> 2] = i56;
michael@0 22989 i57 = i56 + 1 | 0;
michael@0 22990 if ((i57 | 0) >= (i5 | 0)) {
michael@0 22991 break L1421;
michael@0 22992 }
michael@0 22993 i56 = i57;
michael@0 22994 i55 = i55 + i4 | 0;
michael@0 22995 }
michael@0 22996 } else {
michael@0 22997 if (!i12) {
michael@0 22998 break;
michael@0 22999 }
michael@0 23000 i55 = i10 | 0;
michael@0 23001 i56 = i10 + 4 | 0;
michael@0 23002 i51 = i10 + 8 | 0;
michael@0 23003 i52 = i10 + 12 | 0;
michael@0 23004 i53 = HEAP32[i19 >> 2] | 0;
michael@0 23005 d23 = +HEAPF32[i45 >> 2];
michael@0 23006 d22 = +HEAPF32[i46 >> 2];
michael@0 23007 d26 = +HEAPF32[i41 >> 2];
michael@0 23008 i54 = 0;
michael@0 23009 i8 = i2;
michael@0 23010 while (1) {
michael@0 23011 d21 = +HEAPF32[i8 >> 2];
michael@0 23012 HEAPF32[i55 >> 2] = d21;
michael@0 23013 d25 = +HEAPF32[i8 + 4 >> 2];
michael@0 23014 HEAPF32[i56 >> 2] = d25;
michael@0 23015 d24 = d49 * (+HEAPF32[i8 + 8 >> 2] - d26);
michael@0 23016 HEAPF32[i55 >> 2] = d47 * (d21 - d23);
michael@0 23017 HEAPF32[i56 >> 2] = d48 * (d25 - d22);
michael@0 23018 HEAPF32[i51 >> 2] = d24;
michael@0 23019 HEAPF32[i52 >> 2] = 0.0;
michael@0 23020 HEAP32[i53 + (i54 << 4) >> 2] = ~~+HEAPF32[i10 + (HEAP32[i43 >> 2] << 2) >> 2];
michael@0 23021 HEAP32[i53 + (i54 << 4) + 4 >> 2] = ~~+HEAPF32[i10 + (HEAP32[i44 >> 2] << 2) >> 2];
michael@0 23022 HEAP32[i53 + (i54 << 4) + 8 >> 2] = ~~+HEAPF32[i10 + (HEAP32[i42 >> 2] << 2) >> 2];
michael@0 23023 HEAP32[i53 + (i54 << 4) + 12 >> 2] = i54;
michael@0 23024 i57 = i54 + 1 | 0;
michael@0 23025 if ((i57 | 0) >= (i5 | 0)) {
michael@0 23026 break L1421;
michael@0 23027 }
michael@0 23028 i54 = i57;
michael@0 23029 i8 = i8 + i4 | 0;
michael@0 23030 }
michael@0 23031 }
michael@0 23032 } while (0);
michael@0 23033 i4 = HEAP32[i34 >> 2] | 0;
michael@0 23034 if ((i4 | 0) > 1) {
michael@0 23035 __ZN20btAlignedObjectArrayIN20btConvexHullInternal7Point32EE17quickSortInternalIPFbRKS1_S5_EEEvT_ii(i7, 14, 0, i4 - 1 | 0);
michael@0 23036 }
michael@0 23037 i4 = i1 + 32 | 0;
michael@0 23038 HEAP32[i1 + 36 >> 2] = HEAP32[i4 >> 2];
michael@0 23039 HEAP32[i1 + 40 >> 2] = 0;
michael@0 23040 HEAP32[i1 + 44 >> 2] = i5;
michael@0 23041 i7 = i1 + 84 | 0;
michael@0 23042 i42 = HEAP32[i7 >> 2] | 0;
michael@0 23043 if ((i42 | 0) < (i5 | 0)) {
michael@0 23044 i10 = i1 + 88 | 0;
michael@0 23045 if ((HEAP32[i10 >> 2] | 0) < (i5 | 0)) {
michael@0 23046 if ((i5 | 0) == 0) {
michael@0 23047 i58 = 0;
michael@0 23048 i59 = i42;
michael@0 23049 } else {
michael@0 23050 i44 = __Z22btAlignedAllocInternalji(i5 << 2, 16) | 0;
michael@0 23051 i58 = i44;
michael@0 23052 i59 = HEAP32[i7 >> 2] | 0;
michael@0 23053 }
michael@0 23054 i44 = i1 + 92 | 0;
michael@0 23055 if ((i59 | 0) > 0) {
michael@0 23056 i43 = 0;
michael@0 23057 do {
michael@0 23058 i2 = i58 + (i43 << 2) | 0;
michael@0 23059 if ((i2 | 0) != 0) {
michael@0 23060 HEAP32[i2 >> 2] = HEAP32[(HEAP32[i44 >> 2] | 0) + (i43 << 2) >> 2];
michael@0 23061 }
michael@0 23062 i43 = i43 + 1 | 0;
michael@0 23063 } while ((i43 | 0) < (i59 | 0));
michael@0 23064 }
michael@0 23065 i59 = HEAP32[i44 >> 2] | 0;
michael@0 23066 i43 = i1 + 96 | 0;
michael@0 23067 if ((i59 | 0) != 0) {
michael@0 23068 if ((HEAP8[i43] | 0) != 0) {
michael@0 23069 __Z21btAlignedFreeInternalPv(i59);
michael@0 23070 }
michael@0 23071 HEAP32[i44 >> 2] = 0;
michael@0 23072 }
michael@0 23073 HEAP8[i43] = 1;
michael@0 23074 HEAP32[i44 >> 2] = i58;
michael@0 23075 HEAP32[i10 >> 2] = i5;
michael@0 23076 i60 = i44;
michael@0 23077 } else {
michael@0 23078 i60 = i1 + 92 | 0;
michael@0 23079 }
michael@0 23080 i44 = i42;
michael@0 23081 do {
michael@0 23082 i42 = (HEAP32[i60 >> 2] | 0) + (i44 << 2) | 0;
michael@0 23083 if ((i42 | 0) != 0) {
michael@0 23084 HEAP32[i42 >> 2] = 0;
michael@0 23085 }
michael@0 23086 i44 = i44 + 1 | 0;
michael@0 23087 } while ((i44 | 0) < (i5 | 0));
michael@0 23088 }
michael@0 23089 HEAP32[i7 >> 2] = i5;
michael@0 23090 if (i12) {
michael@0 23091 i12 = i1 + 92 | 0;
michael@0 23092 i7 = 0;
michael@0 23093 do {
michael@0 23094 i44 = __ZN20btConvexHullInternal4PoolINS_6VertexEE9newObjectEv(i4) | 0;
michael@0 23095 HEAP32[i44 + 8 >> 2] = 0;
michael@0 23096 i60 = i44 + 88 | 0;
michael@0 23097 i42 = (HEAP32[i19 >> 2] | 0) + (i7 << 4) | 0;
michael@0 23098 HEAP32[i60 >> 2] = HEAP32[i42 >> 2];
michael@0 23099 HEAP32[i60 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 23100 HEAP32[i60 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 23101 HEAP32[i60 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 23102 HEAP32[i44 + 104 >> 2] = -1;
michael@0 23103 HEAP32[(HEAP32[i12 >> 2] | 0) + (i7 << 2) >> 2] = i44;
michael@0 23104 i7 = i7 + 1 | 0;
michael@0 23105 } while ((i7 | 0) < (i5 | 0));
michael@0 23106 }
michael@0 23107 i7 = HEAP32[i19 >> 2] | 0;
michael@0 23108 if ((i7 | 0) != 0) {
michael@0 23109 if ((HEAP8[i20] | 0) != 0) {
michael@0 23110 __Z21btAlignedFreeInternalPv(i7);
michael@0 23111 }
michael@0 23112 HEAP32[i19 >> 2] = 0;
michael@0 23113 }
michael@0 23114 HEAP8[i20] = 1;
michael@0 23115 HEAP32[i19 >> 2] = 0;
michael@0 23116 HEAP32[i34 >> 2] = 0;
michael@0 23117 HEAP32[i50 >> 2] = 0;
michael@0 23118 HEAP32[i1 + 52 >> 2] = HEAP32[i1 + 48 >> 2];
michael@0 23119 HEAP32[i1 + 56 >> 2] = 0;
michael@0 23120 HEAP32[i1 + 60 >> 2] = i5 * 6 | 0;
michael@0 23121 HEAP32[i1 + 116 >> 2] = 0;
michael@0 23122 HEAP32[i1 + 120 >> 2] = 0;
michael@0 23123 HEAP32[i1 + 100 >> 2] = -3;
michael@0 23124 _memset(i11 | 0, 0, 16);
michael@0 23125 __ZN20btConvexHullInternal15computeInternalEiiRNS_16IntermediateHullE(i1, 0, i5, i11);
michael@0 23126 HEAP32[i1 + 124 >> 2] = HEAP32[i11 >> 2];
michael@0 23127 i11 = HEAP32[i19 >> 2] | 0;
michael@0 23128 if ((i11 | 0) == 0) {
michael@0 23129 STACKTOP = i6;
michael@0 23130 return;
michael@0 23131 }
michael@0 23132 if ((HEAP8[i20] | 0) != 0) {
michael@0 23133 __Z21btAlignedFreeInternalPv(i11);
michael@0 23134 }
michael@0 23135 HEAP32[i19 >> 2] = 0;
michael@0 23136 STACKTOP = i6;
michael@0 23137 return;
michael@0 23138 }
michael@0 23139 function __ZN35btSequentialImpulseConstraintSolver14convertContactEP20btPersistentManifoldRK19btContactSolverInfo(i1, i2, i3) {
michael@0 23140 i1 = i1 | 0;
michael@0 23141 i2 = i2 | 0;
michael@0 23142 i3 = i3 | 0;
michael@0 23143 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, i59 = 0, i60 = 0, i61 = 0, d62 = 0.0, d63 = 0.0, i64 = 0, d65 = 0.0;
michael@0 23144 i4 = STACKTOP;
michael@0 23145 STACKTOP = STACKTOP + 128 | 0;
michael@0 23146 i5 = i4 | 0;
michael@0 23147 i6 = i4 + 16 | 0;
michael@0 23148 i7 = i4 + 32 | 0;
michael@0 23149 i8 = i4 + 48 | 0;
michael@0 23150 i9 = i4 + 64 | 0;
michael@0 23151 i10 = i4 + 80 | 0;
michael@0 23152 i11 = i4 + 96 | 0;
michael@0 23153 i12 = i4 + 104 | 0;
michael@0 23154 i13 = i4 + 112 | 0;
michael@0 23155 i14 = HEAP32[i2 + 1108 >> 2] | 0;
michael@0 23156 i15 = i14;
michael@0 23157 i16 = HEAP32[i2 + 1112 >> 2] | 0;
michael@0 23158 i17 = i16;
michael@0 23159 i18 = i14 + 232 | 0;
michael@0 23160 if ((HEAP32[i18 >> 2] & 2 | 0) == 0) {
michael@0 23161 i19 = 0;
michael@0 23162 } else {
michael@0 23163 i19 = i14;
michael@0 23164 }
michael@0 23165 i20 = i16 + 232 | 0;
michael@0 23166 if ((HEAP32[i20 >> 2] & 2 | 0) == 0) {
michael@0 23167 i21 = 0;
michael@0 23168 } else {
michael@0 23169 i21 = i16;
michael@0 23170 }
michael@0 23171 if ((i19 | 0) == 0) {
michael@0 23172 i22 = 1360;
michael@0 23173 } else {
michael@0 23174 if (+HEAPF32[i19 + 336 >> 2] == 0.0) {
michael@0 23175 i22 = 1360;
michael@0 23176 }
michael@0 23177 }
michael@0 23178 do {
michael@0 23179 if ((i22 | 0) == 1360) {
michael@0 23180 if ((i21 | 0) == 0) {
michael@0 23181 STACKTOP = i4;
michael@0 23182 return;
michael@0 23183 }
michael@0 23184 if (+HEAPF32[i21 + 336 >> 2] != 0.0) {
michael@0 23185 break;
michael@0 23186 }
michael@0 23187 STACKTOP = i4;
michael@0 23188 return;
michael@0 23189 }
michael@0 23190 } while (0);
michael@0 23191 i21 = i2 + 1116 | 0;
michael@0 23192 i19 = HEAP32[i21 >> 2] | 0;
michael@0 23193 if ((i19 | 0) <= 0) {
michael@0 23194 STACKTOP = i4;
michael@0 23195 return;
michael@0 23196 }
michael@0 23197 i23 = i2 + 1124 | 0;
michael@0 23198 i24 = i1 + 8 | 0;
michael@0 23199 i25 = i1 + 12 | 0;
michael@0 23200 i26 = i1 + 16 | 0;
michael@0 23201 i27 = i1 + 20 | 0;
michael@0 23202 i28 = i1 + 48 | 0;
michael@0 23203 i29 = i3 + 60 | 0;
michael@0 23204 i30 = i13 | 0;
michael@0 23205 i31 = i13 + 4 | 0;
michael@0 23206 i32 = i13 + 8 | 0;
michael@0 23207 i33 = i16;
michael@0 23208 i16 = i14;
michael@0 23209 i14 = i7;
michael@0 23210 i34 = i8;
michael@0 23211 i35 = i5;
michael@0 23212 i36 = i6;
michael@0 23213 i37 = 0;
michael@0 23214 i38 = i19;
michael@0 23215 while (1) {
michael@0 23216 i19 = i2 + 4 + (i37 * 276 | 0) | 0;
michael@0 23217 if (+HEAPF32[i2 + 4 + (i37 * 276 | 0) + 80 >> 2] > +HEAPF32[i23 >> 2]) {
michael@0 23218 i39 = i38;
michael@0 23219 } else {
michael@0 23220 i40 = HEAP32[i24 >> 2] | 0;
michael@0 23221 do {
michael@0 23222 if ((i40 | 0) == (HEAP32[i25 >> 2] | 0)) {
michael@0 23223 i41 = (i40 | 0) == 0 ? 1 : i40 << 1;
michael@0 23224 if ((i40 | 0) >= (i41 | 0)) {
michael@0 23225 i42 = i40;
michael@0 23226 break;
michael@0 23227 }
michael@0 23228 if ((i41 | 0) == 0) {
michael@0 23229 i43 = 0;
michael@0 23230 i44 = i40;
michael@0 23231 } else {
michael@0 23232 i45 = __Z22btAlignedAllocInternalji(i41 * 136 | 0, 16) | 0;
michael@0 23233 i43 = i45;
michael@0 23234 i44 = HEAP32[i24 >> 2] | 0;
michael@0 23235 }
michael@0 23236 if ((i44 | 0) > 0) {
michael@0 23237 i45 = 0;
michael@0 23238 do {
michael@0 23239 i46 = i43 + (i45 * 136 | 0) | 0;
michael@0 23240 i47 = (HEAP32[i26 >> 2] | 0) + (i45 * 136 | 0) | 0;
michael@0 23241 _memcpy(i46 | 0, i47 | 0, 136) | 0;
michael@0 23242 i45 = i45 + 1 | 0;
michael@0 23243 } while ((i45 | 0) < (i44 | 0));
michael@0 23244 }
michael@0 23245 i45 = HEAP32[i26 >> 2] | 0;
michael@0 23246 if ((i45 | 0) != 0) {
michael@0 23247 if ((HEAP8[i27] | 0) != 0) {
michael@0 23248 __Z21btAlignedFreeInternalPv(i45);
michael@0 23249 }
michael@0 23250 HEAP32[i26 >> 2] = 0;
michael@0 23251 }
michael@0 23252 HEAP8[i27] = 1;
michael@0 23253 HEAP32[i26 >> 2] = i43;
michael@0 23254 HEAP32[i25 >> 2] = i41;
michael@0 23255 i42 = HEAP32[i24 >> 2] | 0;
michael@0 23256 } else {
michael@0 23257 i42 = i40;
michael@0 23258 }
michael@0 23259 } while (0);
michael@0 23260 HEAP32[i24 >> 2] = i42 + 1;
michael@0 23261 i45 = HEAP32[i26 >> 2] | 0;
michael@0 23262 i47 = i45 + (i40 * 136 | 0) | 0;
michael@0 23263 i46 = (HEAP32[i18 >> 2] & 2 | 0) == 0 ? 0 : i16;
michael@0 23264 i48 = (HEAP32[i20 >> 2] & 2 | 0) == 0 ? 0 : i33;
michael@0 23265 if ((i46 | 0) == 0) {
michael@0 23266 do {
michael@0 23267 if ((HEAP8[14328] | 0) == 0) {
michael@0 23268 if ((___cxa_guard_acquire(14328) | 0) == 0) {
michael@0 23269 break;
michael@0 23270 }
michael@0 23271 _memset(i14 | 0, 0, 16);
michael@0 23272 __ZN11btRigidBodyC2EfP13btMotionStateP16btCollisionShapeRK9btVector3(12536, 0.0, 0, 0, i7);
michael@0 23273 _atexit(268, 12536, ___dso_handle | 0) | 0;
michael@0 23274 }
michael@0 23275 } while (0);
michael@0 23276 _memset(i34 | 0, 0, 16);
michael@0 23277 __ZN11btRigidBody12setMassPropsEfRK9btVector3(12536, 0.0, i8);
michael@0 23278 i49 = 12536;
michael@0 23279 } else {
michael@0 23280 i49 = i46;
michael@0 23281 }
michael@0 23282 HEAP32[i45 + (i40 * 136 | 0) + 104 >> 2] = i49;
michael@0 23283 if ((i48 | 0) == 0) {
michael@0 23284 do {
michael@0 23285 if ((HEAP8[14328] | 0) == 0) {
michael@0 23286 if ((___cxa_guard_acquire(14328) | 0) == 0) {
michael@0 23287 break;
michael@0 23288 }
michael@0 23289 _memset(i35 | 0, 0, 16);
michael@0 23290 __ZN11btRigidBodyC2EfP13btMotionStateP16btCollisionShapeRK9btVector3(12536, 0.0, 0, 0, i5);
michael@0 23291 _atexit(268, 12536, ___dso_handle | 0) | 0;
michael@0 23292 }
michael@0 23293 } while (0);
michael@0 23294 _memset(i36 | 0, 0, 16);
michael@0 23295 __ZN11btRigidBody12setMassPropsEfRK9btVector3(12536, 0.0, i6);
michael@0 23296 i50 = 12536;
michael@0 23297 } else {
michael@0 23298 i50 = i48;
michael@0 23299 }
michael@0 23300 HEAP32[i45 + (i40 * 136 | 0) + 108 >> 2] = i50;
michael@0 23301 HEAP32[i45 + (i40 * 136 | 0) + 112 >> 2] = i19;
michael@0 23302 __ZN35btSequentialImpulseConstraintSolver22setupContactConstraintER18btSolverConstraintP17btCollisionObjectS3_R15btManifoldPointRK19btContactSolverInfoR9btVector3RfSB_SA_SA_(0, i47, i15, i17, i19, i3, i13, i12, i11, i9, i10);
michael@0 23303 HEAP32[i45 + (i40 * 136 | 0) + 100 >> 2] = HEAP32[i28 >> 2];
michael@0 23304 do {
michael@0 23305 if ((HEAP32[i29 >> 2] & 32 | 0) == 0) {
michael@0 23306 i22 = 1392;
michael@0 23307 } else {
michael@0 23308 if ((HEAP8[i2 + 4 + (i37 * 276 | 0) + 116 | 0] | 0) == 0) {
michael@0 23309 i22 = 1392;
michael@0 23310 break;
michael@0 23311 }
michael@0 23312 i51 = i2 + 4 + (i37 * 276 | 0) + 148 | 0;
michael@0 23313 d52 = +HEAPF32[i11 >> 2];
michael@0 23314 d53 = +HEAPF32[i2 + 4 + (i37 * 276 | 0) + 128 >> 2];
michael@0 23315 d54 = +HEAPF32[i2 + 4 + (i37 * 276 | 0) + 136 >> 2];
michael@0 23316 __ZN35btSequentialImpulseConstraintSolver21addFrictionConstraintERK9btVector3P11btRigidBodyS4_iR15btManifoldPointS2_S2_P17btCollisionObjectS8_fff(i1, i51, 0, 0, i40, i19, i9, i10, i15, i17, d52, d53, d54) | 0;
michael@0 23317 if ((HEAP32[i29 >> 2] & 16 | 0) == 0) {
michael@0 23318 break;
michael@0 23319 }
michael@0 23320 i51 = i2 + 4 + (i37 * 276 | 0) + 164 | 0;
michael@0 23321 d54 = +HEAPF32[i2 + 4 + (i37 * 276 | 0) + 132 >> 2];
michael@0 23322 d53 = +HEAPF32[i2 + 4 + (i37 * 276 | 0) + 140 >> 2];
michael@0 23323 __ZN35btSequentialImpulseConstraintSolver21addFrictionConstraintERK9btVector3P11btRigidBodyS4_iR15btManifoldPointS2_S2_P17btCollisionObjectS8_fff(i1, i51, 0, 0, i40, i19, i9, i10, i15, i17, d52, d54, d53) | 0;
michael@0 23324 }
michael@0 23325 } while (0);
michael@0 23326 do {
michael@0 23327 if ((i22 | 0) == 1392) {
michael@0 23328 i22 = 0;
michael@0 23329 i45 = i2 + 4 + (i37 * 276 | 0) + 148 | 0;
michael@0 23330 d53 = +HEAPF32[i2 + 4 + (i37 * 276 | 0) + 64 >> 2];
michael@0 23331 d54 = +HEAPF32[i12 >> 2];
michael@0 23332 d52 = +HEAPF32[i2 + 4 + (i37 * 276 | 0) + 68 >> 2];
michael@0 23333 d55 = +HEAPF32[i2 + 4 + (i37 * 276 | 0) + 72 >> 2];
michael@0 23334 d56 = +HEAPF32[i30 >> 2] - d53 * d54;
michael@0 23335 d57 = +HEAPF32[i31 >> 2] - d54 * d52;
michael@0 23336 d58 = +HEAPF32[i32 >> 2] - d54 * d55;
michael@0 23337 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 148 >> 2] = d56;
michael@0 23338 i51 = i2 + 4 + (i37 * 276 | 0) + 152 | 0;
michael@0 23339 HEAPF32[i51 >> 2] = d57;
michael@0 23340 i59 = i2 + 4 + (i37 * 276 | 0) + 156 | 0;
michael@0 23341 HEAPF32[i59 >> 2] = d58;
michael@0 23342 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 160 >> 2] = 0.0;
michael@0 23343 i60 = i45 | 0;
michael@0 23344 d54 = d56 * d56 + d57 * d57 + d58 * d58;
michael@0 23345 i61 = HEAP32[i29 >> 2] | 0;
michael@0 23346 if ((i61 & 64 | 0) == 0 & d54 > 1.1920928955078125e-7) {
michael@0 23347 d62 = 1.0 / +Math_sqrt(+d54);
michael@0 23348 d54 = d56 * d62;
michael@0 23349 HEAPF32[i60 >> 2] = d54;
michael@0 23350 d56 = d57 * d62;
michael@0 23351 HEAPF32[i51 >> 2] = d56;
michael@0 23352 d57 = d58 * d62;
michael@0 23353 HEAPF32[i59 >> 2] = d57;
michael@0 23354 if ((i61 & 16 | 0) == 0) {
michael@0 23355 d63 = +HEAPF32[i11 >> 2];
michael@0 23356 } else {
michael@0 23357 i64 = i2 + 4 + (i37 * 276 | 0) + 164 | 0;
michael@0 23358 d62 = d55 * d56 - d52 * d57;
michael@0 23359 d58 = d53 * d57 - d55 * d54;
michael@0 23360 d57 = d52 * d54 - d53 * d56;
michael@0 23361 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 164 >> 2] = d62;
michael@0 23362 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 176 >> 2] = 0.0;
michael@0 23363 d56 = 1.0 / +Math_sqrt(+(d57 * d57 + (d62 * d62 + d58 * d58)));
michael@0 23364 HEAPF32[i64 >> 2] = d62 * d56;
michael@0 23365 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 168 >> 2] = d58 * d56;
michael@0 23366 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 172 >> 2] = d57 * d56;
michael@0 23367 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i15, i64);
michael@0 23368 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i17, i64);
michael@0 23369 d56 = +HEAPF32[i11 >> 2];
michael@0 23370 __ZN35btSequentialImpulseConstraintSolver21addFrictionConstraintERK9btVector3P11btRigidBodyS4_iR15btManifoldPointS2_S2_P17btCollisionObjectS8_fff(i1, i64, 0, 0, i40, i19, i9, i10, i15, i17, d56, 0.0, 0.0) | 0;
michael@0 23371 d63 = d56;
michael@0 23372 }
michael@0 23373 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i15, i45);
michael@0 23374 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i17, i45);
michael@0 23375 __ZN35btSequentialImpulseConstraintSolver21addFrictionConstraintERK9btVector3P11btRigidBodyS4_iR15btManifoldPointS2_S2_P17btCollisionObjectS8_fff(i1, i45, 0, 0, i40, i19, i9, i10, i15, i17, d63, 0.0, 0.0) | 0;
michael@0 23376 HEAP8[i2 + 4 + (i37 * 276 | 0) + 116 | 0] = 1;
michael@0 23377 break;
michael@0 23378 }
michael@0 23379 i64 = i2 + 4 + (i37 * 276 | 0) + 164 | 0;
michael@0 23380 if (+Math_abs(+d55) > .7071067690849304) {
michael@0 23381 d56 = d52 * d52 + d55 * d55;
michael@0 23382 d57 = 1.0 / +Math_sqrt(+d56);
michael@0 23383 HEAPF32[i60 >> 2] = 0.0;
michael@0 23384 d58 = d57 * (-0.0 - d55);
michael@0 23385 HEAPF32[i51 >> 2] = d58;
michael@0 23386 d62 = d52 * d57;
michael@0 23387 HEAPF32[i59 >> 2] = d62;
michael@0 23388 HEAPF32[i64 >> 2] = d56 * d57;
michael@0 23389 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 168 >> 2] = d62 * (-0.0 - d53);
michael@0 23390 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 172 >> 2] = d53 * d58;
michael@0 23391 } else {
michael@0 23392 d58 = d53 * d53 + d52 * d52;
michael@0 23393 d62 = 1.0 / +Math_sqrt(+d58);
michael@0 23394 d57 = d62 * (-0.0 - d52);
michael@0 23395 HEAPF32[i60 >> 2] = d57;
michael@0 23396 d52 = d53 * d62;
michael@0 23397 HEAPF32[i51 >> 2] = d52;
michael@0 23398 HEAPF32[i59 >> 2] = 0.0;
michael@0 23399 HEAPF32[i64 >> 2] = d52 * (-0.0 - d55);
michael@0 23400 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 168 >> 2] = d55 * d57;
michael@0 23401 HEAPF32[i2 + 4 + (i37 * 276 | 0) + 172 >> 2] = d58 * d62;
michael@0 23402 }
michael@0 23403 if ((i61 & 16 | 0) == 0) {
michael@0 23404 d65 = +HEAPF32[i11 >> 2];
michael@0 23405 } else {
michael@0 23406 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i15, i64);
michael@0 23407 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i17, i64);
michael@0 23408 d62 = +HEAPF32[i11 >> 2];
michael@0 23409 __ZN35btSequentialImpulseConstraintSolver21addFrictionConstraintERK9btVector3P11btRigidBodyS4_iR15btManifoldPointS2_S2_P17btCollisionObjectS8_fff(i1, i64, 0, 0, i40, i19, i9, i10, i15, i17, d62, 0.0, 0.0) | 0;
michael@0 23410 d65 = d62;
michael@0 23411 }
michael@0 23412 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i15, i45);
michael@0 23413 __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i17, i45);
michael@0 23414 __ZN35btSequentialImpulseConstraintSolver21addFrictionConstraintERK9btVector3P11btRigidBodyS4_iR15btManifoldPointS2_S2_P17btCollisionObjectS8_fff(i1, i45, 0, 0, i40, i19, i9, i10, i15, i17, d65, 0.0, 0.0) | 0;
michael@0 23415 HEAP8[i2 + 4 + (i37 * 276 | 0) + 116 | 0] = 1;
michael@0 23416 }
michael@0 23417 } while (0);
michael@0 23418 __ZN35btSequentialImpulseConstraintSolver28setFrictionConstraintImpulseER18btSolverConstraintP11btRigidBodyS3_R15btManifoldPointRK19btContactSolverInfo(i1, i47, i46, i48, i19, i3);
michael@0 23419 i39 = HEAP32[i21 >> 2] | 0;
michael@0 23420 }
michael@0 23421 i40 = i37 + 1 | 0;
michael@0 23422 if ((i40 | 0) < (i39 | 0)) {
michael@0 23423 i37 = i40;
michael@0 23424 i38 = i39;
michael@0 23425 } else {
michael@0 23426 break;
michael@0 23427 }
michael@0 23428 }
michael@0 23429 STACKTOP = i4;
michael@0 23430 return;
michael@0 23431 }
michael@0 23432 function __ZNK20btConvexHullInternal6Vertex3dotERKNS_7Point64E(i1, i2, i3) {
michael@0 23433 i1 = i1 | 0;
michael@0 23434 i2 = i2 | 0;
michael@0 23435 i3 = i3 | 0;
michael@0 23436 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0;
michael@0 23437 if ((HEAP32[i2 + 100 >> 2] | 0) > -1) {
michael@0 23438 i4 = HEAP32[i2 + 88 >> 2] | 0;
michael@0 23439 i5 = i3 | 0;
michael@0 23440 i6 = ___muldi3(i4, (i4 | 0) < 0 ? -1 : 0, HEAP32[i5 >> 2] | 0, HEAP32[i5 + 4 >> 2] | 0) | 0;
michael@0 23441 i5 = tempRet0;
michael@0 23442 i4 = HEAP32[i2 + 92 >> 2] | 0;
michael@0 23443 i7 = i3 + 8 | 0;
michael@0 23444 i8 = ___muldi3(i4, (i4 | 0) < 0 ? -1 : 0, HEAP32[i7 >> 2] | 0, HEAP32[i7 + 4 >> 2] | 0) | 0;
michael@0 23445 i7 = _i64Add(i8, tempRet0, i6, i5) | 0;
michael@0 23446 i5 = tempRet0;
michael@0 23447 i6 = HEAP32[i2 + 96 >> 2] | 0;
michael@0 23448 i8 = i3 + 16 | 0;
michael@0 23449 i4 = ___muldi3(i6, (i6 | 0) < 0 ? -1 : 0, HEAP32[i8 >> 2] | 0, HEAP32[i8 + 4 >> 2] | 0) | 0;
michael@0 23450 i8 = _i64Add(i7, i5, i4, tempRet0) | 0;
michael@0 23451 i4 = tempRet0;
michael@0 23452 i5 = 0;
michael@0 23453 do {
michael@0 23454 if ((i4 | 0) > (i5 | 0) | (i4 | 0) == (i5 | 0) & i8 >>> 0 > 0 >>> 0) {
michael@0 23455 HEAP32[i1 + 32 >> 2] = 1;
michael@0 23456 i7 = i1 | 0;
michael@0 23457 HEAP32[i7 >> 2] = i8;
michael@0 23458 HEAP32[i7 + 4 >> 2] = i4;
michael@0 23459 i7 = i1 + 8 | 0;
michael@0 23460 HEAP32[i7 >> 2] = i4 >> 31 | ((i4 | 0) < 0 ? -1 : 0) << 1;
michael@0 23461 HEAP32[i7 + 4 >> 2] = ((i4 | 0) < 0 ? -1 : 0) >> 31 | ((i4 | 0) < 0 ? -1 : 0) << 1;
michael@0 23462 } else {
michael@0 23463 i7 = 0;
michael@0 23464 i6 = i1 + 32 | 0;
michael@0 23465 if ((i4 | 0) < (i7 | 0) | (i4 | 0) == (i7 | 0) & i8 >>> 0 < 0 >>> 0) {
michael@0 23466 HEAP32[i6 >> 2] = -1;
michael@0 23467 i7 = _i64Subtract(0, 0, i8, i4) | 0;
michael@0 23468 i9 = tempRet0;
michael@0 23469 i10 = i1 | 0;
michael@0 23470 HEAP32[i10 >> 2] = i7;
michael@0 23471 HEAP32[i10 + 4 >> 2] = i9;
michael@0 23472 i10 = i1 + 8 | 0;
michael@0 23473 HEAP32[i10 >> 2] = i9 >> 31 | ((i9 | 0) < 0 ? -1 : 0) << 1;
michael@0 23474 HEAP32[i10 + 4 >> 2] = ((i9 | 0) < 0 ? -1 : 0) >> 31 | ((i9 | 0) < 0 ? -1 : 0) << 1;
michael@0 23475 break;
michael@0 23476 } else {
michael@0 23477 HEAP32[i6 >> 2] = 0;
michael@0 23478 _memset(i1 | 0, 0, 16);
michael@0 23479 break;
michael@0 23480 }
michael@0 23481 }
michael@0 23482 } while (0);
michael@0 23483 i4 = i1 + 16 | 0;
michael@0 23484 HEAP32[i4 >> 2] = 1;
michael@0 23485 HEAP32[i4 + 4 >> 2] = 0;
michael@0 23486 i4 = i1 + 24 | 0;
michael@0 23487 HEAP32[i4 >> 2] = 0;
michael@0 23488 HEAP32[i4 + 4 >> 2] = 0;
michael@0 23489 HEAP8[i1 + 36 | 0] = 1;
michael@0 23490 return;
michael@0 23491 }
michael@0 23492 i4 = i3 | 0;
michael@0 23493 i8 = HEAP32[i4 >> 2] | 0;
michael@0 23494 i5 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 23495 i4 = i2 + 32 | 0;
michael@0 23496 i6 = HEAP32[i4 >> 2] | 0;
michael@0 23497 i9 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 23498 i4 = 0;
michael@0 23499 i10 = (i9 | 0) < (i4 | 0) | (i9 | 0) == (i4 | 0) & i6 >>> 0 < 0 >>> 0;
michael@0 23500 i4 = i2 + 24 | 0;
michael@0 23501 i7 = HEAP32[i4 >> 2] | 0;
michael@0 23502 i11 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 23503 if (i10) {
michael@0 23504 i4 = _i64Subtract(0, 0, i7, i11) | 0;
michael@0 23505 i12 = tempRet0;
michael@0 23506 i13 = _i64Add((i7 | 0) == 0 & (i11 | 0) == 0 & 1, 0, ~i6, ~i9) | 0;
michael@0 23507 i14 = i12;
michael@0 23508 i15 = i4;
michael@0 23509 i16 = tempRet0;
michael@0 23510 i17 = i13;
michael@0 23511 } else {
michael@0 23512 i14 = i11;
michael@0 23513 i15 = i7;
michael@0 23514 i16 = i9;
michael@0 23515 i17 = i6;
michael@0 23516 }
michael@0 23517 i6 = 0;
michael@0 23518 if ((i5 | 0) < (i6 | 0) | (i5 | 0) == (i6 | 0) & i8 >>> 0 < 0 >>> 0) {
michael@0 23519 i6 = _i64Subtract(0, 0, i8, i5) | 0;
michael@0 23520 i18 = i10 ^ 1;
michael@0 23521 i19 = tempRet0;
michael@0 23522 i20 = i6;
michael@0 23523 } else {
michael@0 23524 i18 = i10;
michael@0 23525 i19 = i5;
michael@0 23526 i20 = i8;
michael@0 23527 }
michael@0 23528 i8 = i15 | 0;
michael@0 23529 i15 = i14 & 0;
michael@0 23530 i5 = i20 | 0;
michael@0 23531 i10 = i19 & 0;
michael@0 23532 i6 = ___muldi3(i5, i10, i8, i15) | 0;
michael@0 23533 i9 = tempRet0;
michael@0 23534 i7 = i19;
michael@0 23535 i11 = 0;
michael@0 23536 i13 = ___muldi3(i7, i11, i8, i15) | 0;
michael@0 23537 i15 = tempRet0;
michael@0 23538 i8 = i14;
michael@0 23539 i14 = 0;
michael@0 23540 i4 = ___muldi3(i5, i10, i8, i14) | 0;
michael@0 23541 i10 = tempRet0;
michael@0 23542 i5 = ___muldi3(i7, i11, i8, i14) | 0;
michael@0 23543 i14 = tempRet0;
michael@0 23544 i8 = _i64Add(i13 | 0, i15 & 0, i4 | 0, i10 & 0) | 0;
michael@0 23545 i4 = tempRet0;
michael@0 23546 i13 = _llvm_uadd_with_overflow_i64(i6 | 0, i9 | 0, 0, i8 | 0) | 0;
michael@0 23547 i8 = i13;
michael@0 23548 i13 = tempRet0;
michael@0 23549 i9 = tempRet1 & 1;
michael@0 23550 i6 = ___muldi3(i20, i19, i17, i16) | 0;
michael@0 23551 i16 = _i64Add(i5, i14, i6, tempRet0) | 0;
michael@0 23552 i6 = _i64Add(i16, tempRet0, i15, 0) | 0;
michael@0 23553 i15 = _i64Add(i6, tempRet0, i10, 0) | 0;
michael@0 23554 i10 = _i64Add(i15, tempRet0, i9, 0) | 0;
michael@0 23555 i9 = _i64Add(i10, tempRet0, i4, 0) | 0;
michael@0 23556 i4 = tempRet0;
michael@0 23557 if (i18) {
michael@0 23558 i18 = _i64Subtract(0, 0, i8, i13) | 0;
michael@0 23559 i10 = tempRet0;
michael@0 23560 i15 = _i64Add((i8 | 0) == 0 & (i13 | 0) == 0 & 1, 0, ~i9, ~i4) | 0;
michael@0 23561 i21 = i10;
michael@0 23562 i22 = i18;
michael@0 23563 i23 = tempRet0;
michael@0 23564 i24 = i15;
michael@0 23565 } else {
michael@0 23566 i21 = i13;
michael@0 23567 i22 = i8;
michael@0 23568 i23 = i4;
michael@0 23569 i24 = i9;
michael@0 23570 }
michael@0 23571 i9 = i3 + 8 | 0;
michael@0 23572 i4 = HEAP32[i9 >> 2] | 0;
michael@0 23573 i8 = HEAP32[i9 + 4 >> 2] | 0;
michael@0 23574 i9 = i2 + 48 | 0;
michael@0 23575 i13 = HEAP32[i9 >> 2] | 0;
michael@0 23576 i15 = HEAP32[i9 + 4 >> 2] | 0;
michael@0 23577 i9 = 0;
michael@0 23578 i18 = (i15 | 0) < (i9 | 0) | (i15 | 0) == (i9 | 0) & i13 >>> 0 < 0 >>> 0;
michael@0 23579 i9 = i2 + 40 | 0;
michael@0 23580 i10 = HEAP32[i9 >> 2] | 0;
michael@0 23581 i6 = HEAP32[i9 + 4 >> 2] | 0;
michael@0 23582 if (i18) {
michael@0 23583 i9 = _i64Subtract(0, 0, i10, i6) | 0;
michael@0 23584 i16 = tempRet0;
michael@0 23585 i14 = _i64Add((i10 | 0) == 0 & (i6 | 0) == 0 & 1, 0, ~i13, ~i15) | 0;
michael@0 23586 i25 = i16;
michael@0 23587 i26 = i9;
michael@0 23588 i27 = tempRet0;
michael@0 23589 i28 = i14;
michael@0 23590 } else {
michael@0 23591 i25 = i6;
michael@0 23592 i26 = i10;
michael@0 23593 i27 = i15;
michael@0 23594 i28 = i13;
michael@0 23595 }
michael@0 23596 i13 = 0;
michael@0 23597 if ((i8 | 0) < (i13 | 0) | (i8 | 0) == (i13 | 0) & i4 >>> 0 < 0 >>> 0) {
michael@0 23598 i13 = _i64Subtract(0, 0, i4, i8) | 0;
michael@0 23599 i29 = i18 ^ 1;
michael@0 23600 i30 = tempRet0;
michael@0 23601 i31 = i13;
michael@0 23602 } else {
michael@0 23603 i29 = i18;
michael@0 23604 i30 = i8;
michael@0 23605 i31 = i4;
michael@0 23606 }
michael@0 23607 i4 = i26 | 0;
michael@0 23608 i26 = i25 & 0;
michael@0 23609 i8 = i31 | 0;
michael@0 23610 i18 = i30 & 0;
michael@0 23611 i13 = ___muldi3(i8, i18, i4, i26) | 0;
michael@0 23612 i15 = tempRet0;
michael@0 23613 i10 = i30;
michael@0 23614 i6 = 0;
michael@0 23615 i14 = ___muldi3(i10, i6, i4, i26) | 0;
michael@0 23616 i26 = tempRet0;
michael@0 23617 i4 = i25;
michael@0 23618 i25 = 0;
michael@0 23619 i9 = ___muldi3(i8, i18, i4, i25) | 0;
michael@0 23620 i18 = tempRet0;
michael@0 23621 i8 = ___muldi3(i10, i6, i4, i25) | 0;
michael@0 23622 i25 = tempRet0;
michael@0 23623 i4 = _i64Add(i14 | 0, i26 & 0, i9 | 0, i18 & 0) | 0;
michael@0 23624 i9 = tempRet0;
michael@0 23625 i14 = _llvm_uadd_with_overflow_i64(i13 | 0, i15 | 0, 0, i4 | 0) | 0;
michael@0 23626 i4 = i14;
michael@0 23627 i14 = tempRet0;
michael@0 23628 i15 = tempRet1 & 1;
michael@0 23629 i13 = ___muldi3(i31, i30, i28, i27) | 0;
michael@0 23630 i27 = _i64Add(i8, i25, i13, tempRet0) | 0;
michael@0 23631 i13 = _i64Add(i27, tempRet0, i26, 0) | 0;
michael@0 23632 i26 = _i64Add(i13, tempRet0, i18, 0) | 0;
michael@0 23633 i18 = _i64Add(i26, tempRet0, i15, 0) | 0;
michael@0 23634 i15 = _i64Add(i18, tempRet0, i9, 0) | 0;
michael@0 23635 i9 = tempRet0;
michael@0 23636 if (i29) {
michael@0 23637 i29 = _i64Subtract(0, 0, i4, i14) | 0;
michael@0 23638 i18 = tempRet0;
michael@0 23639 i26 = _i64Add((i4 | 0) == 0 & (i14 | 0) == 0 & 1, 0, ~i15, ~i9) | 0;
michael@0 23640 i32 = i18;
michael@0 23641 i33 = i29;
michael@0 23642 i34 = tempRet0;
michael@0 23643 i35 = i26;
michael@0 23644 } else {
michael@0 23645 i32 = i14;
michael@0 23646 i33 = i4;
michael@0 23647 i34 = i9;
michael@0 23648 i35 = i15;
michael@0 23649 }
michael@0 23650 i15 = _llvm_uadd_with_overflow_i64(i22 | 0, i21 | 0, i33 | 0, i32 | 0) | 0;
michael@0 23651 i32 = tempRet1;
michael@0 23652 i33 = tempRet0;
michael@0 23653 i21 = _i64Add(i35, i34, i24, i23) | 0;
michael@0 23654 i23 = _i64Add(i21, tempRet0, i32 & 1, 0) | 0;
michael@0 23655 i32 = tempRet0;
michael@0 23656 i21 = i3 + 16 | 0;
michael@0 23657 i3 = HEAP32[i21 >> 2] | 0;
michael@0 23658 i24 = HEAP32[i21 + 4 >> 2] | 0;
michael@0 23659 i21 = i2 + 64 | 0;
michael@0 23660 i34 = HEAP32[i21 >> 2] | 0;
michael@0 23661 i35 = HEAP32[i21 + 4 >> 2] | 0;
michael@0 23662 i21 = 0;
michael@0 23663 i22 = (i35 | 0) < (i21 | 0) | (i35 | 0) == (i21 | 0) & i34 >>> 0 < 0 >>> 0;
michael@0 23664 i21 = i2 + 56 | 0;
michael@0 23665 i9 = HEAP32[i21 >> 2] | 0;
michael@0 23666 i4 = HEAP32[i21 + 4 >> 2] | 0;
michael@0 23667 if (i22) {
michael@0 23668 i21 = _i64Subtract(0, 0, i9, i4) | 0;
michael@0 23669 i14 = tempRet0;
michael@0 23670 i26 = _i64Add((i9 | 0) == 0 & (i4 | 0) == 0 & 1, 0, ~i34, ~i35) | 0;
michael@0 23671 i36 = i14;
michael@0 23672 i37 = i21;
michael@0 23673 i38 = tempRet0;
michael@0 23674 i39 = i26;
michael@0 23675 } else {
michael@0 23676 i36 = i4;
michael@0 23677 i37 = i9;
michael@0 23678 i38 = i35;
michael@0 23679 i39 = i34;
michael@0 23680 }
michael@0 23681 i34 = 0;
michael@0 23682 if ((i24 | 0) < (i34 | 0) | (i24 | 0) == (i34 | 0) & i3 >>> 0 < 0 >>> 0) {
michael@0 23683 i34 = _i64Subtract(0, 0, i3, i24) | 0;
michael@0 23684 i40 = i22 ^ 1;
michael@0 23685 i41 = tempRet0;
michael@0 23686 i42 = i34;
michael@0 23687 } else {
michael@0 23688 i40 = i22;
michael@0 23689 i41 = i24;
michael@0 23690 i42 = i3;
michael@0 23691 }
michael@0 23692 i3 = i37 | 0;
michael@0 23693 i37 = i36 & 0;
michael@0 23694 i24 = i42 | 0;
michael@0 23695 i22 = i41 & 0;
michael@0 23696 i34 = ___muldi3(i24, i22, i3, i37) | 0;
michael@0 23697 i35 = tempRet0;
michael@0 23698 i9 = i41;
michael@0 23699 i4 = 0;
michael@0 23700 i26 = ___muldi3(i9, i4, i3, i37) | 0;
michael@0 23701 i37 = tempRet0;
michael@0 23702 i3 = i36;
michael@0 23703 i36 = 0;
michael@0 23704 i21 = ___muldi3(i24, i22, i3, i36) | 0;
michael@0 23705 i22 = tempRet0;
michael@0 23706 i24 = ___muldi3(i9, i4, i3, i36) | 0;
michael@0 23707 i36 = tempRet0;
michael@0 23708 i3 = _i64Add(i26 | 0, i37 & 0, i21 | 0, i22 & 0) | 0;
michael@0 23709 i21 = tempRet0;
michael@0 23710 i26 = _llvm_uadd_with_overflow_i64(i34 | 0, i35 | 0, 0, i3 | 0) | 0;
michael@0 23711 i3 = i26;
michael@0 23712 i26 = tempRet0;
michael@0 23713 i35 = tempRet1 & 1;
michael@0 23714 i34 = ___muldi3(i42, i41, i39, i38) | 0;
michael@0 23715 i38 = _i64Add(i24, i36, i34, tempRet0) | 0;
michael@0 23716 i34 = _i64Add(i38, tempRet0, i37, 0) | 0;
michael@0 23717 i37 = _i64Add(i34, tempRet0, i22, 0) | 0;
michael@0 23718 i22 = _i64Add(i37, tempRet0, i35, 0) | 0;
michael@0 23719 i35 = _i64Add(i22, tempRet0, i21, 0) | 0;
michael@0 23720 i21 = tempRet0;
michael@0 23721 if (i40) {
michael@0 23722 i40 = _i64Subtract(0, 0, i3, i26) | 0;
michael@0 23723 i22 = tempRet0;
michael@0 23724 i37 = _i64Add((i3 | 0) == 0 & (i26 | 0) == 0 & 1, 0, ~i35, ~i21) | 0;
michael@0 23725 i43 = i22;
michael@0 23726 i44 = i40;
michael@0 23727 i45 = tempRet0;
michael@0 23728 i46 = i37;
michael@0 23729 } else {
michael@0 23730 i43 = i26;
michael@0 23731 i44 = i3;
michael@0 23732 i45 = i21;
michael@0 23733 i46 = i35;
michael@0 23734 }
michael@0 23735 i35 = _llvm_uadd_with_overflow_i64(i15 | 0, i33 | 0, i44 | 0, i43 | 0) | 0;
michael@0 23736 i43 = tempRet1;
michael@0 23737 i44 = i35;
michael@0 23738 i35 = tempRet0;
michael@0 23739 i33 = _i64Add(i23, i32, i46, i45) | 0;
michael@0 23740 i45 = _i64Add(i33, tempRet0, i43 & 1, 0) | 0;
michael@0 23741 i43 = tempRet0;
michael@0 23742 i33 = i2 + 72 | 0;
michael@0 23743 i46 = i1 + 16 | 0;
michael@0 23744 i32 = 0;
michael@0 23745 if ((i43 | 0) < (i32 | 0) | (i43 | 0) == (i32 | 0) & i45 >>> 0 < 0 >>> 0) {
michael@0 23746 i32 = i1 + 32 | 0;
michael@0 23747 HEAP32[i32 >> 2] = -1;
michael@0 23748 i23 = _i64Subtract(0, 0, i44, i35) | 0;
michael@0 23749 i15 = tempRet0;
michael@0 23750 i21 = _i64Add((i44 | 0) == 0 & (i35 | 0) == 0 & 1, 0, ~i45, ~i43) | 0;
michael@0 23751 i3 = i1 | 0;
michael@0 23752 HEAP32[i3 >> 2] = i23;
michael@0 23753 HEAP32[i3 + 4 >> 2] = i15;
michael@0 23754 i15 = i1 + 8 | 0;
michael@0 23755 HEAP32[i15 >> 2] = i21;
michael@0 23756 HEAP32[i15 + 4 >> 2] = tempRet0;
michael@0 23757 i47 = i32;
michael@0 23758 i48 = -1;
michael@0 23759 } else {
michael@0 23760 if ((i45 | 0) == 0 & (i43 | 0) == 0) {
michael@0 23761 i49 = ((i44 | 0) != 0 | (i35 | 0) != 0) & 1;
michael@0 23762 } else {
michael@0 23763 i49 = 1;
michael@0 23764 }
michael@0 23765 i32 = i1 + 32 | 0;
michael@0 23766 HEAP32[i32 >> 2] = i49;
michael@0 23767 i15 = i1 | 0;
michael@0 23768 HEAP32[i15 >> 2] = i44;
michael@0 23769 HEAP32[i15 + 4 >> 2] = i35;
michael@0 23770 i35 = i1 + 8 | 0;
michael@0 23771 HEAP32[i35 >> 2] = i45;
michael@0 23772 HEAP32[i35 + 4 >> 2] = i43;
michael@0 23773 i47 = i32;
michael@0 23774 i48 = i49;
michael@0 23775 }
michael@0 23776 i49 = i2 + 80 | 0;
michael@0 23777 i2 = HEAP32[i49 >> 2] | 0;
michael@0 23778 i32 = HEAP32[i49 + 4 >> 2] | 0;
michael@0 23779 i49 = 0;
michael@0 23780 if ((i32 | 0) < (i49 | 0) | (i32 | 0) == (i49 | 0) & i2 >>> 0 < 0 >>> 0) {
michael@0 23781 HEAP32[i47 >> 2] = -i48;
michael@0 23782 i48 = i33 | 0;
michael@0 23783 i47 = HEAP32[i48 >> 2] | 0;
michael@0 23784 i49 = HEAP32[i48 + 4 >> 2] | 0;
michael@0 23785 i48 = _i64Subtract(0, 0, i47, i49) | 0;
michael@0 23786 i43 = tempRet0;
michael@0 23787 i35 = _i64Add((i47 | 0) == 0 & (i49 | 0) == 0 & 1, 0, ~i2, ~i32) | 0;
michael@0 23788 i32 = i1 + 16 | 0;
michael@0 23789 HEAP32[i32 >> 2] = i48;
michael@0 23790 HEAP32[i32 + 4 >> 2] = i43;
michael@0 23791 i43 = i1 + 24 | 0;
michael@0 23792 HEAP32[i43 >> 2] = i35;
michael@0 23793 HEAP32[i43 + 4 >> 2] = tempRet0;
michael@0 23794 } else {
michael@0 23795 i43 = i46;
michael@0 23796 i46 = i33;
michael@0 23797 HEAP32[i43 >> 2] = HEAP32[i46 >> 2];
michael@0 23798 HEAP32[i43 + 4 >> 2] = HEAP32[i46 + 4 >> 2];
michael@0 23799 HEAP32[i43 + 8 >> 2] = HEAP32[i46 + 8 >> 2];
michael@0 23800 HEAP32[i43 + 12 >> 2] = HEAP32[i46 + 12 >> 2];
michael@0 23801 }
michael@0 23802 HEAP8[i1 + 36 | 0] = 0;
michael@0 23803 return;
michael@0 23804 }
michael@0 23805 function __ZN12gjkepa2_impl3GJK13EncloseOriginEv(i1) {
michael@0 23806 i1 = i1 | 0;
michael@0 23807 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, d16 = 0.0, d17 = 0.0, d18 = 0.0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, d41 = 0.0, d42 = 0.0;
michael@0 23808 i2 = STACKTOP;
michael@0 23809 STACKTOP = STACKTOP + 112 | 0;
michael@0 23810 i3 = i2 | 0;
michael@0 23811 i4 = i2 + 16 | 0;
michael@0 23812 i5 = i2 + 32 | 0;
michael@0 23813 i6 = i2 + 48 | 0;
michael@0 23814 i7 = i2 + 64 | 0;
michael@0 23815 i8 = i2 + 80 | 0;
michael@0 23816 i9 = i2 + 96 | 0;
michael@0 23817 i10 = i1 + 372 | 0;
michael@0 23818 i11 = HEAP32[i10 >> 2] | 0;
michael@0 23819 i12 = i11 + 32 | 0;
michael@0 23820 i13 = HEAP32[i12 >> 2] | 0;
michael@0 23821 L165 : do {
michael@0 23822 if ((i13 | 0) == 2) {
michael@0 23823 i14 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 23824 i15 = HEAP32[i11 >> 2] | 0;
michael@0 23825 d16 = +HEAPF32[i14 + 16 >> 2] - +HEAPF32[i15 + 16 >> 2];
michael@0 23826 d17 = +HEAPF32[i14 + 20 >> 2] - +HEAPF32[i15 + 20 >> 2];
michael@0 23827 d18 = +HEAPF32[i14 + 24 >> 2] - +HEAPF32[i15 + 24 >> 2];
michael@0 23828 i15 = i5 | 0;
michael@0 23829 i14 = i5 + 4 | 0;
michael@0 23830 i19 = i5 + 8 | 0;
michael@0 23831 i20 = i6 | 0;
michael@0 23832 i21 = i6 + 4 | 0;
michael@0 23833 i22 = i6 + 8 | 0;
michael@0 23834 i23 = i6 + 12 | 0;
michael@0 23835 i24 = i1 + 364 | 0;
michael@0 23836 i25 = i7 | 0;
michael@0 23837 i26 = i7 + 4 | 0;
michael@0 23838 i27 = i7 + 8 | 0;
michael@0 23839 i28 = i7 + 12 | 0;
michael@0 23840 i29 = i5;
michael@0 23841 i30 = 0;
michael@0 23842 while (1) {
michael@0 23843 _memset(i29 | 0, 0, 16);
michael@0 23844 HEAPF32[i5 + (i30 << 2) >> 2] = 1.0;
michael@0 23845 d31 = +HEAPF32[i19 >> 2];
michael@0 23846 d32 = +HEAPF32[i14 >> 2];
michael@0 23847 d33 = d17 * d31 - d18 * d32;
michael@0 23848 d34 = +HEAPF32[i15 >> 2];
michael@0 23849 d35 = d18 * d34 - d16 * d31;
michael@0 23850 d31 = d16 * d32 - d17 * d34;
michael@0 23851 HEAPF32[i20 >> 2] = d33;
michael@0 23852 HEAPF32[i21 >> 2] = d35;
michael@0 23853 HEAPF32[i22 >> 2] = d31;
michael@0 23854 HEAPF32[i23 >> 2] = 0.0;
michael@0 23855 if (d31 * d31 + (d33 * d33 + d35 * d35) > 0.0) {
michael@0 23856 i36 = HEAP32[i10 >> 2] | 0;
michael@0 23857 i37 = i36 + 32 | 0;
michael@0 23858 HEAPF32[i36 + 16 + (HEAP32[i37 >> 2] << 2) >> 2] = 0.0;
michael@0 23859 i38 = (HEAP32[i24 >> 2] | 0) - 1 | 0;
michael@0 23860 HEAP32[i24 >> 2] = i38;
michael@0 23861 HEAP32[i36 + (HEAP32[i37 >> 2] << 2) >> 2] = HEAP32[i1 + 348 + (i38 << 2) >> 2];
michael@0 23862 i38 = HEAP32[i37 >> 2] | 0;
michael@0 23863 HEAP32[i37 >> 2] = i38 + 1;
michael@0 23864 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i6, HEAP32[i36 + (i38 << 2) >> 2] | 0);
michael@0 23865 if (__ZN12gjkepa2_impl3GJK13EncloseOriginEv(i1) | 0) {
michael@0 23866 i39 = 1;
michael@0 23867 i40 = 143;
michael@0 23868 break;
michael@0 23869 }
michael@0 23870 i38 = HEAP32[i10 >> 2] | 0;
michael@0 23871 i36 = i38 + 32 | 0;
michael@0 23872 i37 = (HEAP32[i36 >> 2] | 0) - 1 | 0;
michael@0 23873 HEAP32[i36 >> 2] = i37;
michael@0 23874 i36 = HEAP32[i38 + (i37 << 2) >> 2] | 0;
michael@0 23875 i37 = HEAP32[i24 >> 2] | 0;
michael@0 23876 HEAP32[i24 >> 2] = i37 + 1;
michael@0 23877 HEAP32[i1 + 348 + (i37 << 2) >> 2] = i36;
michael@0 23878 i36 = HEAP32[i10 >> 2] | 0;
michael@0 23879 d35 = -0.0 - +HEAPF32[i21 >> 2];
michael@0 23880 d33 = -0.0 - +HEAPF32[i22 >> 2];
michael@0 23881 HEAPF32[i25 >> 2] = -0.0 - +HEAPF32[i20 >> 2];
michael@0 23882 HEAPF32[i26 >> 2] = d35;
michael@0 23883 HEAPF32[i27 >> 2] = d33;
michael@0 23884 HEAPF32[i28 >> 2] = 0.0;
michael@0 23885 i37 = i36 + 32 | 0;
michael@0 23886 HEAPF32[i36 + 16 + (HEAP32[i37 >> 2] << 2) >> 2] = 0.0;
michael@0 23887 i38 = (HEAP32[i24 >> 2] | 0) - 1 | 0;
michael@0 23888 HEAP32[i24 >> 2] = i38;
michael@0 23889 HEAP32[i36 + (HEAP32[i37 >> 2] << 2) >> 2] = HEAP32[i1 + 348 + (i38 << 2) >> 2];
michael@0 23890 i38 = HEAP32[i37 >> 2] | 0;
michael@0 23891 HEAP32[i37 >> 2] = i38 + 1;
michael@0 23892 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i7, HEAP32[i36 + (i38 << 2) >> 2] | 0);
michael@0 23893 if (__ZN12gjkepa2_impl3GJK13EncloseOriginEv(i1) | 0) {
michael@0 23894 i39 = 1;
michael@0 23895 i40 = 144;
michael@0 23896 break;
michael@0 23897 }
michael@0 23898 i38 = HEAP32[i10 >> 2] | 0;
michael@0 23899 i36 = i38 + 32 | 0;
michael@0 23900 i37 = (HEAP32[i36 >> 2] | 0) - 1 | 0;
michael@0 23901 HEAP32[i36 >> 2] = i37;
michael@0 23902 i36 = HEAP32[i38 + (i37 << 2) >> 2] | 0;
michael@0 23903 i37 = HEAP32[i24 >> 2] | 0;
michael@0 23904 HEAP32[i24 >> 2] = i37 + 1;
michael@0 23905 HEAP32[i1 + 348 + (i37 << 2) >> 2] = i36;
michael@0 23906 }
michael@0 23907 i30 = i30 + 1 | 0;
michael@0 23908 if (i30 >>> 0 >= 3) {
michael@0 23909 break L165;
michael@0 23910 }
michael@0 23911 }
michael@0 23912 if ((i40 | 0) == 143) {
michael@0 23913 STACKTOP = i2;
michael@0 23914 return i39 | 0;
michael@0 23915 } else if ((i40 | 0) == 144) {
michael@0 23916 STACKTOP = i2;
michael@0 23917 return i39 | 0;
michael@0 23918 }
michael@0 23919 } else if ((i13 | 0) == 3) {
michael@0 23920 i30 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 23921 i24 = HEAP32[i11 >> 2] | 0;
michael@0 23922 d17 = +HEAPF32[i24 + 16 >> 2];
michael@0 23923 d16 = +HEAPF32[i30 + 16 >> 2] - d17;
michael@0 23924 d18 = +HEAPF32[i24 + 20 >> 2];
michael@0 23925 d33 = +HEAPF32[i30 + 20 >> 2] - d18;
michael@0 23926 d35 = +HEAPF32[i24 + 24 >> 2];
michael@0 23927 d31 = +HEAPF32[i30 + 24 >> 2] - d35;
michael@0 23928 i30 = HEAP32[i11 + 8 >> 2] | 0;
michael@0 23929 d34 = +HEAPF32[i30 + 16 >> 2] - d17;
michael@0 23930 d17 = +HEAPF32[i30 + 20 >> 2] - d18;
michael@0 23931 d18 = +HEAPF32[i30 + 24 >> 2] - d35;
michael@0 23932 d35 = d33 * d18 - d31 * d17;
michael@0 23933 d32 = d31 * d34 - d16 * d18;
michael@0 23934 d18 = d16 * d17 - d33 * d34;
michael@0 23935 i30 = i8 | 0;
michael@0 23936 HEAPF32[i30 >> 2] = d35;
michael@0 23937 i24 = i8 + 4 | 0;
michael@0 23938 HEAPF32[i24 >> 2] = d32;
michael@0 23939 i28 = i8 + 8 | 0;
michael@0 23940 HEAPF32[i28 >> 2] = d18;
michael@0 23941 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 23942 if (d18 * d18 + (d35 * d35 + d32 * d32) <= 0.0) {
michael@0 23943 break;
michael@0 23944 }
michael@0 23945 HEAPF32[i11 + 28 >> 2] = 0.0;
michael@0 23946 i27 = i1 + 364 | 0;
michael@0 23947 i26 = (HEAP32[i27 >> 2] | 0) - 1 | 0;
michael@0 23948 HEAP32[i27 >> 2] = i26;
michael@0 23949 HEAP32[i11 + (HEAP32[i12 >> 2] << 2) >> 2] = HEAP32[i1 + 348 + (i26 << 2) >> 2];
michael@0 23950 i26 = HEAP32[i12 >> 2] | 0;
michael@0 23951 HEAP32[i12 >> 2] = i26 + 1;
michael@0 23952 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i8, HEAP32[i11 + (i26 << 2) >> 2] | 0);
michael@0 23953 if (__ZN12gjkepa2_impl3GJK13EncloseOriginEv(i1) | 0) {
michael@0 23954 i39 = 1;
michael@0 23955 STACKTOP = i2;
michael@0 23956 return i39 | 0;
michael@0 23957 }
michael@0 23958 i26 = HEAP32[i10 >> 2] | 0;
michael@0 23959 i20 = i26 + 32 | 0;
michael@0 23960 i25 = (HEAP32[i20 >> 2] | 0) - 1 | 0;
michael@0 23961 HEAP32[i20 >> 2] = i25;
michael@0 23962 i20 = HEAP32[i26 + (i25 << 2) >> 2] | 0;
michael@0 23963 i25 = HEAP32[i27 >> 2] | 0;
michael@0 23964 HEAP32[i27 >> 2] = i25 + 1;
michael@0 23965 HEAP32[i1 + 348 + (i25 << 2) >> 2] = i20;
michael@0 23966 i20 = HEAP32[i10 >> 2] | 0;
michael@0 23967 d32 = -0.0 - +HEAPF32[i24 >> 2];
michael@0 23968 d35 = -0.0 - +HEAPF32[i28 >> 2];
michael@0 23969 HEAPF32[i9 >> 2] = -0.0 - +HEAPF32[i30 >> 2];
michael@0 23970 HEAPF32[i9 + 4 >> 2] = d32;
michael@0 23971 HEAPF32[i9 + 8 >> 2] = d35;
michael@0 23972 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 23973 i30 = i20 + 32 | 0;
michael@0 23974 HEAPF32[i20 + 16 + (HEAP32[i30 >> 2] << 2) >> 2] = 0.0;
michael@0 23975 i28 = (HEAP32[i27 >> 2] | 0) - 1 | 0;
michael@0 23976 HEAP32[i27 >> 2] = i28;
michael@0 23977 HEAP32[i20 + (HEAP32[i30 >> 2] << 2) >> 2] = HEAP32[i1 + 348 + (i28 << 2) >> 2];
michael@0 23978 i28 = HEAP32[i30 >> 2] | 0;
michael@0 23979 HEAP32[i30 >> 2] = i28 + 1;
michael@0 23980 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i9, HEAP32[i20 + (i28 << 2) >> 2] | 0);
michael@0 23981 if (__ZN12gjkepa2_impl3GJK13EncloseOriginEv(i1) | 0) {
michael@0 23982 i39 = 1;
michael@0 23983 STACKTOP = i2;
michael@0 23984 return i39 | 0;
michael@0 23985 } else {
michael@0 23986 i28 = HEAP32[i10 >> 2] | 0;
michael@0 23987 i20 = i28 + 32 | 0;
michael@0 23988 i30 = (HEAP32[i20 >> 2] | 0) - 1 | 0;
michael@0 23989 HEAP32[i20 >> 2] = i30;
michael@0 23990 i20 = HEAP32[i28 + (i30 << 2) >> 2] | 0;
michael@0 23991 i30 = HEAP32[i27 >> 2] | 0;
michael@0 23992 HEAP32[i27 >> 2] = i30 + 1;
michael@0 23993 HEAP32[i1 + 348 + (i30 << 2) >> 2] = i20;
michael@0 23994 break;
michael@0 23995 }
michael@0 23996 } else if ((i13 | 0) == 4) {
michael@0 23997 i20 = HEAP32[i11 >> 2] | 0;
michael@0 23998 i30 = HEAP32[i11 + 12 >> 2] | 0;
michael@0 23999 d35 = +HEAPF32[i30 + 16 >> 2];
michael@0 24000 d32 = +HEAPF32[i20 + 16 >> 2] - d35;
michael@0 24001 d18 = +HEAPF32[i30 + 20 >> 2];
michael@0 24002 d34 = +HEAPF32[i20 + 20 >> 2] - d18;
michael@0 24003 d33 = +HEAPF32[i30 + 24 >> 2];
michael@0 24004 d17 = +HEAPF32[i20 + 24 >> 2] - d33;
michael@0 24005 i20 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 24006 d16 = +HEAPF32[i20 + 16 >> 2] - d35;
michael@0 24007 d31 = +HEAPF32[i20 + 20 >> 2] - d18;
michael@0 24008 d41 = +HEAPF32[i20 + 24 >> 2] - d33;
michael@0 24009 i20 = HEAP32[i11 + 8 >> 2] | 0;
michael@0 24010 d42 = +HEAPF32[i20 + 16 >> 2] - d35;
michael@0 24011 d35 = +HEAPF32[i20 + 20 >> 2] - d18;
michael@0 24012 d18 = +HEAPF32[i20 + 24 >> 2] - d33;
michael@0 24013 if (d32 * d31 * d18 + (d34 * d41 * d42 + d17 * d16 * d35 - d32 * d41 * d35 - d34 * d16 * d18) - d17 * d31 * d42 == 0.0) {
michael@0 24014 break;
michael@0 24015 } else {
michael@0 24016 i39 = 1;
michael@0 24017 }
michael@0 24018 STACKTOP = i2;
michael@0 24019 return i39 | 0;
michael@0 24020 } else if ((i13 | 0) == 1) {
michael@0 24021 i20 = i3 | 0;
michael@0 24022 i30 = i3 + 4 | 0;
michael@0 24023 i27 = i3 + 8 | 0;
michael@0 24024 i28 = i1 + 364 | 0;
michael@0 24025 i24 = i4 | 0;
michael@0 24026 i25 = i4 + 4 | 0;
michael@0 24027 i26 = i4 + 8 | 0;
michael@0 24028 i22 = i4 + 12 | 0;
michael@0 24029 i21 = i3;
michael@0 24030 i23 = 0;
michael@0 24031 i15 = i11;
michael@0 24032 i14 = 1;
michael@0 24033 while (1) {
michael@0 24034 _memset(i21 | 0, 0, 16);
michael@0 24035 HEAPF32[i3 + (i23 << 2) >> 2] = 1.0;
michael@0 24036 i19 = i15 + 32 | 0;
michael@0 24037 HEAPF32[i15 + 16 + (i14 << 2) >> 2] = 0.0;
michael@0 24038 i29 = (HEAP32[i28 >> 2] | 0) - 1 | 0;
michael@0 24039 HEAP32[i28 >> 2] = i29;
michael@0 24040 HEAP32[i15 + (HEAP32[i19 >> 2] << 2) >> 2] = HEAP32[i1 + 348 + (i29 << 2) >> 2];
michael@0 24041 i29 = HEAP32[i19 >> 2] | 0;
michael@0 24042 HEAP32[i19 >> 2] = i29 + 1;
michael@0 24043 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i3, HEAP32[i15 + (i29 << 2) >> 2] | 0);
michael@0 24044 if (__ZN12gjkepa2_impl3GJK13EncloseOriginEv(i1) | 0) {
michael@0 24045 i39 = 1;
michael@0 24046 i40 = 149;
michael@0 24047 break;
michael@0 24048 }
michael@0 24049 i29 = HEAP32[i10 >> 2] | 0;
michael@0 24050 i19 = i29 + 32 | 0;
michael@0 24051 i36 = (HEAP32[i19 >> 2] | 0) - 1 | 0;
michael@0 24052 HEAP32[i19 >> 2] = i36;
michael@0 24053 i19 = HEAP32[i29 + (i36 << 2) >> 2] | 0;
michael@0 24054 i36 = HEAP32[i28 >> 2] | 0;
michael@0 24055 HEAP32[i28 >> 2] = i36 + 1;
michael@0 24056 HEAP32[i1 + 348 + (i36 << 2) >> 2] = i19;
michael@0 24057 i19 = HEAP32[i10 >> 2] | 0;
michael@0 24058 d42 = -0.0 - +HEAPF32[i30 >> 2];
michael@0 24059 d31 = -0.0 - +HEAPF32[i27 >> 2];
michael@0 24060 HEAPF32[i24 >> 2] = -0.0 - +HEAPF32[i20 >> 2];
michael@0 24061 HEAPF32[i25 >> 2] = d42;
michael@0 24062 HEAPF32[i26 >> 2] = d31;
michael@0 24063 HEAPF32[i22 >> 2] = 0.0;
michael@0 24064 i36 = i19 + 32 | 0;
michael@0 24065 HEAPF32[i19 + 16 + (HEAP32[i36 >> 2] << 2) >> 2] = 0.0;
michael@0 24066 i29 = (HEAP32[i28 >> 2] | 0) - 1 | 0;
michael@0 24067 HEAP32[i28 >> 2] = i29;
michael@0 24068 HEAP32[i19 + (HEAP32[i36 >> 2] << 2) >> 2] = HEAP32[i1 + 348 + (i29 << 2) >> 2];
michael@0 24069 i29 = HEAP32[i36 >> 2] | 0;
michael@0 24070 HEAP32[i36 >> 2] = i29 + 1;
michael@0 24071 __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i4, HEAP32[i19 + (i29 << 2) >> 2] | 0);
michael@0 24072 if (__ZN12gjkepa2_impl3GJK13EncloseOriginEv(i1) | 0) {
michael@0 24073 i39 = 1;
michael@0 24074 i40 = 150;
michael@0 24075 break;
michael@0 24076 }
michael@0 24077 i29 = HEAP32[i10 >> 2] | 0;
michael@0 24078 i19 = i29 + 32 | 0;
michael@0 24079 i36 = (HEAP32[i19 >> 2] | 0) - 1 | 0;
michael@0 24080 HEAP32[i19 >> 2] = i36;
michael@0 24081 i19 = HEAP32[i29 + (i36 << 2) >> 2] | 0;
michael@0 24082 i36 = HEAP32[i28 >> 2] | 0;
michael@0 24083 HEAP32[i28 >> 2] = i36 + 1;
michael@0 24084 HEAP32[i1 + 348 + (i36 << 2) >> 2] = i19;
michael@0 24085 i19 = i23 + 1 | 0;
michael@0 24086 if (i19 >>> 0 >= 3) {
michael@0 24087 break L165;
michael@0 24088 }
michael@0 24089 i36 = HEAP32[i10 >> 2] | 0;
michael@0 24090 i23 = i19;
michael@0 24091 i15 = i36;
michael@0 24092 i14 = HEAP32[i36 + 32 >> 2] | 0;
michael@0 24093 }
michael@0 24094 if ((i40 | 0) == 149) {
michael@0 24095 STACKTOP = i2;
michael@0 24096 return i39 | 0;
michael@0 24097 } else if ((i40 | 0) == 150) {
michael@0 24098 STACKTOP = i2;
michael@0 24099 return i39 | 0;
michael@0 24100 }
michael@0 24101 }
michael@0 24102 } while (0);
michael@0 24103 i39 = 0;
michael@0 24104 STACKTOP = i2;
michael@0 24105 return i39 | 0;
michael@0 24106 }
michael@0 24107 function __ZN22btCompoundLeafCallback17ProcessChildShapeEP16btCollisionShapei(i1, i2, i3) {
michael@0 24108 i1 = i1 | 0;
michael@0 24109 i2 = i2 | 0;
michael@0 24110 i3 = i3 | 0;
michael@0 24111 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, i47 = 0, i48 = 0, i49 = 0, i50 = 0;
michael@0 24112 i4 = STACKTOP;
michael@0 24113 STACKTOP = STACKTOP + 224 | 0;
michael@0 24114 i5 = i4 + 64 | 0;
michael@0 24115 i6 = i4 + 128 | 0;
michael@0 24116 i7 = i4 + 144 | 0;
michael@0 24117 i8 = i4 + 160 | 0;
michael@0 24118 i9 = i4 + 176 | 0;
michael@0 24119 i10 = i4 + 192 | 0;
michael@0 24120 i11 = i4 + 208 | 0;
michael@0 24121 i12 = i1 + 4 | 0;
michael@0 24122 i13 = HEAP32[i12 >> 2] | 0;
michael@0 24123 i14 = HEAP32[i13 + 192 >> 2] | 0;
michael@0 24124 d15 = +HEAPF32[i13 + 4 >> 2];
michael@0 24125 d16 = +HEAPF32[i13 + 8 >> 2];
michael@0 24126 d17 = +HEAPF32[i13 + 12 >> 2];
michael@0 24127 d18 = +HEAPF32[i13 + 16 >> 2];
michael@0 24128 d19 = +HEAPF32[i13 + 20 >> 2];
michael@0 24129 d20 = +HEAPF32[i13 + 24 >> 2];
michael@0 24130 d21 = +HEAPF32[i13 + 28 >> 2];
michael@0 24131 d22 = +HEAPF32[i13 + 32 >> 2];
michael@0 24132 d23 = +HEAPF32[i13 + 36 >> 2];
michael@0 24133 d24 = +HEAPF32[i13 + 40 >> 2];
michael@0 24134 d25 = +HEAPF32[i13 + 44 >> 2];
michael@0 24135 d26 = +HEAPF32[i13 + 48 >> 2];
michael@0 24136 d27 = +HEAPF32[i13 + 52 >> 2];
michael@0 24137 d28 = +HEAPF32[i13 + 56 >> 2];
michael@0 24138 d29 = +HEAPF32[i13 + 60 >> 2];
michael@0 24139 d30 = +HEAPF32[i13 + 64 >> 2];
michael@0 24140 i31 = i13 + 68 | 0;
michael@0 24141 i32 = i4 | 0;
michael@0 24142 HEAP32[i32 >> 2] = HEAP32[i31 >> 2];
michael@0 24143 HEAP32[i32 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 24144 HEAP32[i32 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 24145 HEAP32[i32 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 24146 i31 = i13 + 84 | 0;
michael@0 24147 i33 = i4 + 16 | 0;
michael@0 24148 HEAP32[i33 >> 2] = HEAP32[i31 >> 2];
michael@0 24149 HEAP32[i33 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 24150 HEAP32[i33 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 24151 HEAP32[i33 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 24152 i31 = i13 + 100 | 0;
michael@0 24153 i34 = i4 + 32 | 0;
michael@0 24154 HEAP32[i34 >> 2] = HEAP32[i31 >> 2];
michael@0 24155 HEAP32[i34 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 24156 HEAP32[i34 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 24157 HEAP32[i34 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 24158 i31 = i13 + 116 | 0;
michael@0 24159 i13 = i4 + 48 | 0;
michael@0 24160 HEAP32[i13 >> 2] = HEAP32[i31 >> 2];
michael@0 24161 HEAP32[i13 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 24162 HEAP32[i13 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 24163 HEAP32[i13 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 24164 i31 = HEAP32[i14 + 24 >> 2] | 0;
michael@0 24165 d35 = +HEAPF32[i31 + (i3 * 80 | 0) >> 2];
michael@0 24166 d36 = +HEAPF32[i31 + (i3 * 80 | 0) + 16 >> 2];
michael@0 24167 d37 = +HEAPF32[i31 + (i3 * 80 | 0) + 32 >> 2];
michael@0 24168 d38 = +HEAPF32[i31 + (i3 * 80 | 0) + 4 >> 2];
michael@0 24169 d39 = +HEAPF32[i31 + (i3 * 80 | 0) + 20 >> 2];
michael@0 24170 d40 = +HEAPF32[i31 + (i3 * 80 | 0) + 36 >> 2];
michael@0 24171 d41 = +HEAPF32[i31 + (i3 * 80 | 0) + 8 >> 2];
michael@0 24172 d42 = +HEAPF32[i31 + (i3 * 80 | 0) + 24 >> 2];
michael@0 24173 d43 = +HEAPF32[i31 + (i3 * 80 | 0) + 40 >> 2];
michael@0 24174 d44 = +HEAPF32[i31 + (i3 * 80 | 0) + 48 >> 2];
michael@0 24175 d45 = +HEAPF32[i31 + (i3 * 80 | 0) + 52 >> 2];
michael@0 24176 d46 = +HEAPF32[i31 + (i3 * 80 | 0) + 56 >> 2];
michael@0 24177 HEAPF32[i5 >> 2] = d15 * d35 + d16 * d36 + d17 * d37;
michael@0 24178 HEAPF32[i5 + 4 >> 2] = d15 * d38 + d16 * d39 + d17 * d40;
michael@0 24179 HEAPF32[i5 + 8 >> 2] = d15 * d41 + d16 * d42 + d17 * d43;
michael@0 24180 HEAPF32[i5 + 12 >> 2] = 0.0;
michael@0 24181 HEAPF32[i5 + 16 >> 2] = d19 * d35 + d20 * d36 + d21 * d37;
michael@0 24182 HEAPF32[i5 + 20 >> 2] = d19 * d38 + d20 * d39 + d21 * d40;
michael@0 24183 HEAPF32[i5 + 24 >> 2] = d19 * d41 + d20 * d42 + d21 * d43;
michael@0 24184 HEAPF32[i5 + 28 >> 2] = 0.0;
michael@0 24185 HEAPF32[i5 + 32 >> 2] = d23 * d35 + d24 * d36 + d25 * d37;
michael@0 24186 HEAPF32[i5 + 36 >> 2] = d23 * d38 + d24 * d39 + d25 * d40;
michael@0 24187 HEAPF32[i5 + 40 >> 2] = d23 * d41 + d24 * d42 + d25 * d43;
michael@0 24188 HEAPF32[i5 + 44 >> 2] = 0.0;
michael@0 24189 HEAPF32[i5 + 48 >> 2] = d27 + (d15 * d44 + d16 * d45 + d17 * d46);
michael@0 24190 HEAPF32[i5 + 52 >> 2] = d28 + (d19 * d44 + d20 * d45 + d21 * d46);
michael@0 24191 HEAPF32[i5 + 56 >> 2] = d29 + (d23 * d44 + d24 * d45 + d25 * d46);
michael@0 24192 HEAPF32[i5 + 60 >> 2] = 0.0;
michael@0 24193 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 8 >> 2] & 127](i2, i5, i6, i7);
michael@0 24194 i31 = i1 + 8 | 0;
michael@0 24195 i14 = HEAP32[i31 >> 2] | 0;
michael@0 24196 i47 = HEAP32[i14 + 192 >> 2] | 0;
michael@0 24197 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i47 >> 2] | 0) + 8 >> 2] & 127](i47, i14 + 4 | 0, i8, i9);
michael@0 24198 do {
michael@0 24199 if (+HEAPF32[i6 >> 2] > +HEAPF32[i9 >> 2]) {
michael@0 24200 i48 = 0;
michael@0 24201 } else {
michael@0 24202 if (+HEAPF32[i7 >> 2] < +HEAPF32[i8 >> 2]) {
michael@0 24203 i48 = 0;
michael@0 24204 break;
michael@0 24205 }
michael@0 24206 i48 = 1;
michael@0 24207 }
michael@0 24208 } while (0);
michael@0 24209 do {
michael@0 24210 if (+HEAPF32[i6 + 8 >> 2] > +HEAPF32[i9 + 8 >> 2]) {
michael@0 24211 i49 = 0;
michael@0 24212 } else {
michael@0 24213 if (+HEAPF32[i7 + 8 >> 2] < +HEAPF32[i8 + 8 >> 2]) {
michael@0 24214 i49 = 0;
michael@0 24215 break;
michael@0 24216 }
michael@0 24217 i49 = i48;
michael@0 24218 }
michael@0 24219 } while (0);
michael@0 24220 if (+HEAPF32[i6 + 4 >> 2] > +HEAPF32[i9 + 4 >> 2]) {
michael@0 24221 STACKTOP = i4;
michael@0 24222 return;
michael@0 24223 }
michael@0 24224 if (+HEAPF32[i7 + 4 >> 2] < +HEAPF32[i8 + 4 >> 2] | i49 ^ 1) {
michael@0 24225 STACKTOP = i4;
michael@0 24226 return;
michael@0 24227 }
michael@0 24228 i49 = HEAP32[i12 >> 2] | 0;
michael@0 24229 i48 = i49 + 4 | 0;
michael@0 24230 i14 = i5;
michael@0 24231 HEAP32[i48 >> 2] = HEAP32[i14 >> 2];
michael@0 24232 HEAP32[i48 + 4 >> 2] = HEAP32[i14 + 4 >> 2];
michael@0 24233 HEAP32[i48 + 8 >> 2] = HEAP32[i14 + 8 >> 2];
michael@0 24234 HEAP32[i48 + 12 >> 2] = HEAP32[i14 + 12 >> 2];
michael@0 24235 i48 = i49 + 20 | 0;
michael@0 24236 i47 = i5 + 16 | 0;
michael@0 24237 HEAP32[i48 >> 2] = HEAP32[i47 >> 2];
michael@0 24238 HEAP32[i48 + 4 >> 2] = HEAP32[i47 + 4 >> 2];
michael@0 24239 HEAP32[i48 + 8 >> 2] = HEAP32[i47 + 8 >> 2];
michael@0 24240 HEAP32[i48 + 12 >> 2] = HEAP32[i47 + 12 >> 2];
michael@0 24241 i48 = i49 + 36 | 0;
michael@0 24242 i50 = i5 + 32 | 0;
michael@0 24243 HEAP32[i48 >> 2] = HEAP32[i50 >> 2];
michael@0 24244 HEAP32[i48 + 4 >> 2] = HEAP32[i50 + 4 >> 2];
michael@0 24245 HEAP32[i48 + 8 >> 2] = HEAP32[i50 + 8 >> 2];
michael@0 24246 HEAP32[i48 + 12 >> 2] = HEAP32[i50 + 12 >> 2];
michael@0 24247 i48 = i49 + 52 | 0;
michael@0 24248 i49 = i5 + 48 | 0;
michael@0 24249 HEAP32[i48 >> 2] = HEAP32[i49 >> 2];
michael@0 24250 HEAP32[i48 + 4 >> 2] = HEAP32[i49 + 4 >> 2];
michael@0 24251 HEAP32[i48 + 8 >> 2] = HEAP32[i49 + 8 >> 2];
michael@0 24252 HEAP32[i48 + 12 >> 2] = HEAP32[i49 + 12 >> 2];
michael@0 24253 i48 = HEAP32[i12 >> 2] | 0;
michael@0 24254 i5 = i48 + 68 | 0;
michael@0 24255 HEAP32[i5 >> 2] = HEAP32[i14 >> 2];
michael@0 24256 HEAP32[i5 + 4 >> 2] = HEAP32[i14 + 4 >> 2];
michael@0 24257 HEAP32[i5 + 8 >> 2] = HEAP32[i14 + 8 >> 2];
michael@0 24258 HEAP32[i5 + 12 >> 2] = HEAP32[i14 + 12 >> 2];
michael@0 24259 i14 = i48 + 84 | 0;
michael@0 24260 HEAP32[i14 >> 2] = HEAP32[i47 >> 2];
michael@0 24261 HEAP32[i14 + 4 >> 2] = HEAP32[i47 + 4 >> 2];
michael@0 24262 HEAP32[i14 + 8 >> 2] = HEAP32[i47 + 8 >> 2];
michael@0 24263 HEAP32[i14 + 12 >> 2] = HEAP32[i47 + 12 >> 2];
michael@0 24264 i47 = i48 + 100 | 0;
michael@0 24265 HEAP32[i47 >> 2] = HEAP32[i50 >> 2];
michael@0 24266 HEAP32[i47 + 4 >> 2] = HEAP32[i50 + 4 >> 2];
michael@0 24267 HEAP32[i47 + 8 >> 2] = HEAP32[i50 + 8 >> 2];
michael@0 24268 HEAP32[i47 + 12 >> 2] = HEAP32[i50 + 12 >> 2];
michael@0 24269 i50 = i48 + 116 | 0;
michael@0 24270 HEAP32[i50 >> 2] = HEAP32[i49 >> 2];
michael@0 24271 HEAP32[i50 + 4 >> 2] = HEAP32[i49 + 4 >> 2];
michael@0 24272 HEAP32[i50 + 8 >> 2] = HEAP32[i49 + 8 >> 2];
michael@0 24273 HEAP32[i50 + 12 >> 2] = HEAP32[i49 + 12 >> 2];
michael@0 24274 i49 = (HEAP32[i12 >> 2] | 0) + 192 | 0;
michael@0 24275 i50 = HEAP32[i49 >> 2] | 0;
michael@0 24276 HEAP32[i49 >> 2] = i2;
michael@0 24277 i2 = i1 + 24 | 0;
michael@0 24278 if ((HEAP32[(HEAP32[i2 >> 2] | 0) + (i3 << 2) >> 2] | 0) == 0) {
michael@0 24279 i49 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 24280 i48 = FUNCTION_TABLE_iiiii[HEAP32[(HEAP32[i49 >> 2] | 0) + 8 >> 2] & 31](i49, HEAP32[i12 >> 2] | 0, HEAP32[i31 >> 2] | 0, HEAP32[i1 + 28 >> 2] | 0) | 0;
michael@0 24281 HEAP32[(HEAP32[i2 >> 2] | 0) + (i3 << 2) >> 2] = i48;
michael@0 24282 }
michael@0 24283 i48 = i1 + 20 | 0;
michael@0 24284 i49 = HEAP32[i48 >> 2] | 0;
michael@0 24285 i47 = HEAP32[i49 >> 2] | 0;
michael@0 24286 if ((HEAP32[i49 + 136 >> 2] | 0) == (HEAP32[i12 >> 2] | 0)) {
michael@0 24287 FUNCTION_TABLE_viii[HEAP32[i47 + 8 >> 2] & 127](i49, -1, i3);
michael@0 24288 } else {
michael@0 24289 FUNCTION_TABLE_viii[HEAP32[i47 + 12 >> 2] & 127](i49, -1, i3);
michael@0 24290 }
michael@0 24291 i49 = HEAP32[(HEAP32[i2 >> 2] | 0) + (i3 << 2) >> 2] | 0;
michael@0 24292 i3 = i1 + 16 | 0;
michael@0 24293 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i49 >> 2] | 0) + 8 >> 2] & 63](i49, HEAP32[i12 >> 2] | 0, HEAP32[i31 >> 2] | 0, HEAP32[i3 >> 2] | 0, HEAP32[i48 >> 2] | 0);
michael@0 24294 i48 = HEAP32[(HEAP32[i3 >> 2] | 0) + 20 >> 2] | 0;
michael@0 24295 do {
michael@0 24296 if ((i48 | 0) != 0) {
michael@0 24297 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i48 >> 2] | 0) + 48 >> 2] & 127](i48) | 0) & 2 | 0) == 0) {
michael@0 24298 break;
michael@0 24299 }
michael@0 24300 i31 = HEAP32[(HEAP32[i3 >> 2] | 0) + 20 >> 2] | 0;
michael@0 24301 i49 = HEAP32[(HEAP32[i31 >> 2] | 0) + 52 >> 2] | 0;
michael@0 24302 HEAPF32[i10 >> 2] = 1.0;
michael@0 24303 HEAPF32[i10 + 4 >> 2] = 1.0;
michael@0 24304 HEAPF32[i10 + 8 >> 2] = 1.0;
michael@0 24305 HEAPF32[i10 + 12 >> 2] = 0.0;
michael@0 24306 FUNCTION_TABLE_viiii[i49 & 127](i31, i6, i7, i10);
michael@0 24307 i31 = HEAP32[(HEAP32[i3 >> 2] | 0) + 20 >> 2] | 0;
michael@0 24308 i49 = HEAP32[(HEAP32[i31 >> 2] | 0) + 52 >> 2] | 0;
michael@0 24309 HEAPF32[i11 >> 2] = 1.0;
michael@0 24310 HEAPF32[i11 + 4 >> 2] = 1.0;
michael@0 24311 HEAPF32[i11 + 8 >> 2] = 1.0;
michael@0 24312 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 24313 FUNCTION_TABLE_viiii[i49 & 127](i31, i8, i9, i11);
michael@0 24314 }
michael@0 24315 } while (0);
michael@0 24316 HEAP32[(HEAP32[i12 >> 2] | 0) + 192 >> 2] = i50;
michael@0 24317 i50 = HEAP32[i12 >> 2] | 0;
michael@0 24318 HEAPF32[i50 + 4 >> 2] = d15;
michael@0 24319 HEAPF32[i50 + 8 >> 2] = d16;
michael@0 24320 HEAPF32[i50 + 12 >> 2] = d17;
michael@0 24321 HEAPF32[i50 + 16 >> 2] = d18;
michael@0 24322 HEAPF32[i50 + 20 >> 2] = d19;
michael@0 24323 HEAPF32[i50 + 24 >> 2] = d20;
michael@0 24324 HEAPF32[i50 + 28 >> 2] = d21;
michael@0 24325 HEAPF32[i50 + 32 >> 2] = d22;
michael@0 24326 HEAPF32[i50 + 36 >> 2] = d23;
michael@0 24327 HEAPF32[i50 + 40 >> 2] = d24;
michael@0 24328 HEAPF32[i50 + 44 >> 2] = d25;
michael@0 24329 HEAPF32[i50 + 48 >> 2] = d26;
michael@0 24330 HEAPF32[i50 + 52 >> 2] = d27;
michael@0 24331 HEAPF32[i50 + 56 >> 2] = d28;
michael@0 24332 HEAPF32[i50 + 60 >> 2] = d29;
michael@0 24333 HEAPF32[i50 + 64 >> 2] = d30;
michael@0 24334 i50 = HEAP32[i12 >> 2] | 0;
michael@0 24335 i12 = i50 + 68 | 0;
michael@0 24336 HEAP32[i12 >> 2] = HEAP32[i32 >> 2];
michael@0 24337 HEAP32[i12 + 4 >> 2] = HEAP32[i32 + 4 >> 2];
michael@0 24338 HEAP32[i12 + 8 >> 2] = HEAP32[i32 + 8 >> 2];
michael@0 24339 HEAP32[i12 + 12 >> 2] = HEAP32[i32 + 12 >> 2];
michael@0 24340 i32 = i50 + 84 | 0;
michael@0 24341 HEAP32[i32 >> 2] = HEAP32[i33 >> 2];
michael@0 24342 HEAP32[i32 + 4 >> 2] = HEAP32[i33 + 4 >> 2];
michael@0 24343 HEAP32[i32 + 8 >> 2] = HEAP32[i33 + 8 >> 2];
michael@0 24344 HEAP32[i32 + 12 >> 2] = HEAP32[i33 + 12 >> 2];
michael@0 24345 i33 = i50 + 100 | 0;
michael@0 24346 HEAP32[i33 >> 2] = HEAP32[i34 >> 2];
michael@0 24347 HEAP32[i33 + 4 >> 2] = HEAP32[i34 + 4 >> 2];
michael@0 24348 HEAP32[i33 + 8 >> 2] = HEAP32[i34 + 8 >> 2];
michael@0 24349 HEAP32[i33 + 12 >> 2] = HEAP32[i34 + 12 >> 2];
michael@0 24350 i34 = i50 + 116 | 0;
michael@0 24351 HEAP32[i34 >> 2] = HEAP32[i13 >> 2];
michael@0 24352 HEAP32[i34 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 24353 HEAP32[i34 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 24354 HEAP32[i34 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 24355 STACKTOP = i4;
michael@0 24356 return;
michael@0 24357 }
michael@0 24358 function __ZN27btPolyhedralContactClipping8clipFaceERK20btAlignedObjectArrayI9btVector3ERS2_RKS1_f(i1, i2, i3, d4) {
michael@0 24359 i1 = i1 | 0;
michael@0 24360 i2 = i2 | 0;
michael@0 24361 i3 = i3 | 0;
michael@0 24362 d4 = +d4;
michael@0 24363 var i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, i11 = 0, i12 = 0, d13 = 0.0, d14 = 0.0, d15 = 0.0, i16 = 0, i17 = 0, i18 = 0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, i23 = 0, d24 = 0.0, d25 = 0.0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, d44 = 0.0, d45 = 0.0, d46 = 0.0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0;
michael@0 24364 i5 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 24365 if ((i5 | 0) < 2) {
michael@0 24366 return;
michael@0 24367 }
michael@0 24368 i6 = i5 - 1 | 0;
michael@0 24369 i7 = i1 + 12 | 0;
michael@0 24370 i1 = HEAP32[i7 >> 2] | 0;
michael@0 24371 d8 = +HEAPF32[i1 + (i6 << 4) >> 2];
michael@0 24372 d9 = +HEAPF32[i1 + (i6 << 4) + 4 >> 2];
michael@0 24373 d10 = +HEAPF32[i1 + (i6 << 4) + 8 >> 2];
michael@0 24374 i6 = i3 | 0;
michael@0 24375 i11 = i3 + 4 | 0;
michael@0 24376 i12 = i3 + 8 | 0;
michael@0 24377 d13 = +HEAPF32[i11 >> 2];
michael@0 24378 d14 = +HEAPF32[i6 >> 2];
michael@0 24379 d15 = +HEAPF32[i12 >> 2];
michael@0 24380 i3 = i2 + 4 | 0;
michael@0 24381 i16 = i2 + 8 | 0;
michael@0 24382 i17 = i2 + 12 | 0;
michael@0 24383 i18 = i2 + 16 | 0;
michael@0 24384 d19 = d10;
michael@0 24385 d20 = d9;
michael@0 24386 d21 = d8;
michael@0 24387 d22 = d9 * d13 + d8 * d14 + d10 * d15 + d4;
michael@0 24388 i2 = 0;
michael@0 24389 i23 = i1;
michael@0 24390 d10 = d14;
michael@0 24391 d14 = d13;
michael@0 24392 d13 = d15;
michael@0 24393 while (1) {
michael@0 24394 d15 = +HEAPF32[i23 + (i2 << 4) >> 2];
michael@0 24395 d8 = +HEAPF32[i23 + (i2 << 4) + 4 >> 2];
michael@0 24396 d9 = +HEAPF32[i23 + (i2 << 4) + 8 >> 2];
michael@0 24397 d24 = +HEAPF32[i23 + (i2 << 4) + 12 >> 2];
michael@0 24398 d25 = d10 * d15 + d14 * d8 + d13 * d9 + d4;
michael@0 24399 i1 = d25 < 0.0;
michael@0 24400 do {
michael@0 24401 if (d22 < 0.0) {
michael@0 24402 if (i1) {
michael@0 24403 i26 = HEAP32[i3 >> 2] | 0;
michael@0 24404 do {
michael@0 24405 if ((i26 | 0) == (HEAP32[i16 >> 2] | 0)) {
michael@0 24406 i27 = (i26 | 0) == 0 ? 1 : i26 << 1;
michael@0 24407 if ((i26 | 0) >= (i27 | 0)) {
michael@0 24408 i28 = i26;
michael@0 24409 break;
michael@0 24410 }
michael@0 24411 if ((i27 | 0) == 0) {
michael@0 24412 i29 = 0;
michael@0 24413 i30 = i26;
michael@0 24414 } else {
michael@0 24415 i31 = __Z22btAlignedAllocInternalji(i27 << 4, 16) | 0;
michael@0 24416 i29 = i31;
michael@0 24417 i30 = HEAP32[i3 >> 2] | 0;
michael@0 24418 }
michael@0 24419 if ((i30 | 0) > 0) {
michael@0 24420 i31 = 0;
michael@0 24421 do {
michael@0 24422 i32 = i29 + (i31 << 4) | 0;
michael@0 24423 if ((i32 | 0) != 0) {
michael@0 24424 i33 = i32;
michael@0 24425 i32 = (HEAP32[i17 >> 2] | 0) + (i31 << 4) | 0;
michael@0 24426 HEAP32[i33 >> 2] = HEAP32[i32 >> 2];
michael@0 24427 HEAP32[i33 + 4 >> 2] = HEAP32[i32 + 4 >> 2];
michael@0 24428 HEAP32[i33 + 8 >> 2] = HEAP32[i32 + 8 >> 2];
michael@0 24429 HEAP32[i33 + 12 >> 2] = HEAP32[i32 + 12 >> 2];
michael@0 24430 }
michael@0 24431 i31 = i31 + 1 | 0;
michael@0 24432 } while ((i31 | 0) < (i30 | 0));
michael@0 24433 }
michael@0 24434 i31 = HEAP32[i17 >> 2] | 0;
michael@0 24435 if ((i31 | 0) != 0) {
michael@0 24436 if ((HEAP8[i18] | 0) != 0) {
michael@0 24437 __Z21btAlignedFreeInternalPv(i31);
michael@0 24438 }
michael@0 24439 HEAP32[i17 >> 2] = 0;
michael@0 24440 }
michael@0 24441 HEAP8[i18] = 1;
michael@0 24442 HEAP32[i17 >> 2] = i29;
michael@0 24443 HEAP32[i16 >> 2] = i27;
michael@0 24444 i28 = HEAP32[i3 >> 2] | 0;
michael@0 24445 } else {
michael@0 24446 i28 = i26;
michael@0 24447 }
michael@0 24448 } while (0);
michael@0 24449 i26 = HEAP32[i17 >> 2] | 0;
michael@0 24450 i31 = i26 + (i28 << 4) | 0;
michael@0 24451 if ((i31 | 0) == 0) {
michael@0 24452 i34 = i28;
michael@0 24453 } else {
michael@0 24454 HEAPF32[i31 >> 2] = d15;
michael@0 24455 HEAPF32[i26 + (i28 << 4) + 4 >> 2] = d8;
michael@0 24456 HEAPF32[i26 + (i28 << 4) + 8 >> 2] = d9;
michael@0 24457 HEAPF32[i26 + (i28 << 4) + 12 >> 2] = d24;
michael@0 24458 i34 = HEAP32[i3 >> 2] | 0;
michael@0 24459 }
michael@0 24460 HEAP32[i3 >> 2] = i34 + 1;
michael@0 24461 break;
michael@0 24462 } else {
michael@0 24463 d35 = d22 / (d22 - d25);
michael@0 24464 d36 = d21 + (d15 - d21) * d35;
michael@0 24465 d37 = d20 + (d8 - d20) * d35;
michael@0 24466 d38 = d19 + (d9 - d19) * d35;
michael@0 24467 i26 = HEAP32[i3 >> 2] | 0;
michael@0 24468 do {
michael@0 24469 if ((i26 | 0) == (HEAP32[i16 >> 2] | 0)) {
michael@0 24470 i31 = (i26 | 0) == 0 ? 1 : i26 << 1;
michael@0 24471 if ((i26 | 0) >= (i31 | 0)) {
michael@0 24472 i39 = i26;
michael@0 24473 break;
michael@0 24474 }
michael@0 24475 if ((i31 | 0) == 0) {
michael@0 24476 i40 = 0;
michael@0 24477 i41 = i26;
michael@0 24478 } else {
michael@0 24479 i32 = __Z22btAlignedAllocInternalji(i31 << 4, 16) | 0;
michael@0 24480 i40 = i32;
michael@0 24481 i41 = HEAP32[i3 >> 2] | 0;
michael@0 24482 }
michael@0 24483 if ((i41 | 0) > 0) {
michael@0 24484 i32 = 0;
michael@0 24485 do {
michael@0 24486 i33 = i40 + (i32 << 4) | 0;
michael@0 24487 if ((i33 | 0) != 0) {
michael@0 24488 i42 = i33;
michael@0 24489 i33 = (HEAP32[i17 >> 2] | 0) + (i32 << 4) | 0;
michael@0 24490 HEAP32[i42 >> 2] = HEAP32[i33 >> 2];
michael@0 24491 HEAP32[i42 + 4 >> 2] = HEAP32[i33 + 4 >> 2];
michael@0 24492 HEAP32[i42 + 8 >> 2] = HEAP32[i33 + 8 >> 2];
michael@0 24493 HEAP32[i42 + 12 >> 2] = HEAP32[i33 + 12 >> 2];
michael@0 24494 }
michael@0 24495 i32 = i32 + 1 | 0;
michael@0 24496 } while ((i32 | 0) < (i41 | 0));
michael@0 24497 }
michael@0 24498 i32 = HEAP32[i17 >> 2] | 0;
michael@0 24499 if ((i32 | 0) != 0) {
michael@0 24500 if ((HEAP8[i18] | 0) != 0) {
michael@0 24501 __Z21btAlignedFreeInternalPv(i32);
michael@0 24502 }
michael@0 24503 HEAP32[i17 >> 2] = 0;
michael@0 24504 }
michael@0 24505 HEAP8[i18] = 1;
michael@0 24506 HEAP32[i17 >> 2] = i40;
michael@0 24507 HEAP32[i16 >> 2] = i31;
michael@0 24508 i39 = HEAP32[i3 >> 2] | 0;
michael@0 24509 } else {
michael@0 24510 i39 = i26;
michael@0 24511 }
michael@0 24512 } while (0);
michael@0 24513 i26 = HEAP32[i17 >> 2] | 0;
michael@0 24514 i32 = i26 + (i39 << 4) | 0;
michael@0 24515 if ((i32 | 0) == 0) {
michael@0 24516 i43 = i39;
michael@0 24517 } else {
michael@0 24518 HEAPF32[i32 >> 2] = d36;
michael@0 24519 HEAPF32[i26 + (i39 << 4) + 4 >> 2] = d37;
michael@0 24520 HEAPF32[i26 + (i39 << 4) + 8 >> 2] = d38;
michael@0 24521 HEAPF32[i26 + (i39 << 4) + 12 >> 2] = 0.0;
michael@0 24522 i43 = HEAP32[i3 >> 2] | 0;
michael@0 24523 }
michael@0 24524 HEAP32[i3 >> 2] = i43 + 1;
michael@0 24525 break;
michael@0 24526 }
michael@0 24527 } else {
michael@0 24528 if (!i1) {
michael@0 24529 break;
michael@0 24530 }
michael@0 24531 d35 = d22 / (d22 - d25);
michael@0 24532 d44 = d21 + (d15 - d21) * d35;
michael@0 24533 d45 = d20 + (d8 - d20) * d35;
michael@0 24534 d46 = d19 + (d9 - d19) * d35;
michael@0 24535 i26 = HEAP32[i3 >> 2] | 0;
michael@0 24536 i32 = HEAP32[i16 >> 2] | 0;
michael@0 24537 do {
michael@0 24538 if ((i26 | 0) == (i32 | 0)) {
michael@0 24539 i27 = (i26 | 0) == 0 ? 1 : i26 << 1;
michael@0 24540 if ((i26 | 0) >= (i27 | 0)) {
michael@0 24541 i47 = i26;
michael@0 24542 i48 = i26;
michael@0 24543 break;
michael@0 24544 }
michael@0 24545 if ((i27 | 0) == 0) {
michael@0 24546 i49 = 0;
michael@0 24547 i50 = i26;
michael@0 24548 } else {
michael@0 24549 i33 = __Z22btAlignedAllocInternalji(i27 << 4, 16) | 0;
michael@0 24550 i49 = i33;
michael@0 24551 i50 = HEAP32[i3 >> 2] | 0;
michael@0 24552 }
michael@0 24553 if ((i50 | 0) > 0) {
michael@0 24554 i33 = 0;
michael@0 24555 do {
michael@0 24556 i42 = i49 + (i33 << 4) | 0;
michael@0 24557 if ((i42 | 0) != 0) {
michael@0 24558 i51 = i42;
michael@0 24559 i42 = (HEAP32[i17 >> 2] | 0) + (i33 << 4) | 0;
michael@0 24560 HEAP32[i51 >> 2] = HEAP32[i42 >> 2];
michael@0 24561 HEAP32[i51 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 24562 HEAP32[i51 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 24563 HEAP32[i51 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 24564 }
michael@0 24565 i33 = i33 + 1 | 0;
michael@0 24566 } while ((i33 | 0) < (i50 | 0));
michael@0 24567 }
michael@0 24568 i33 = HEAP32[i17 >> 2] | 0;
michael@0 24569 if ((i33 | 0) != 0) {
michael@0 24570 if ((HEAP8[i18] | 0) != 0) {
michael@0 24571 __Z21btAlignedFreeInternalPv(i33);
michael@0 24572 }
michael@0 24573 HEAP32[i17 >> 2] = 0;
michael@0 24574 }
michael@0 24575 HEAP8[i18] = 1;
michael@0 24576 HEAP32[i17 >> 2] = i49;
michael@0 24577 HEAP32[i16 >> 2] = i27;
michael@0 24578 i47 = HEAP32[i3 >> 2] | 0;
michael@0 24579 i48 = i27;
michael@0 24580 } else {
michael@0 24581 i47 = i26;
michael@0 24582 i48 = i32;
michael@0 24583 }
michael@0 24584 } while (0);
michael@0 24585 i32 = HEAP32[i17 >> 2] | 0;
michael@0 24586 i26 = i32 + (i47 << 4) | 0;
michael@0 24587 if ((i26 | 0) == 0) {
michael@0 24588 i52 = i47;
michael@0 24589 i53 = i48;
michael@0 24590 } else {
michael@0 24591 HEAPF32[i26 >> 2] = d44;
michael@0 24592 HEAPF32[i32 + (i47 << 4) + 4 >> 2] = d45;
michael@0 24593 HEAPF32[i32 + (i47 << 4) + 8 >> 2] = d46;
michael@0 24594 HEAPF32[i32 + (i47 << 4) + 12 >> 2] = 0.0;
michael@0 24595 i52 = HEAP32[i3 >> 2] | 0;
michael@0 24596 i53 = HEAP32[i16 >> 2] | 0;
michael@0 24597 }
michael@0 24598 i32 = i52 + 1 | 0;
michael@0 24599 HEAP32[i3 >> 2] = i32;
michael@0 24600 do {
michael@0 24601 if ((i32 | 0) == (i53 | 0)) {
michael@0 24602 i26 = (i53 | 0) == 0 ? 1 : i53 << 1;
michael@0 24603 if ((i53 | 0) >= (i26 | 0)) {
michael@0 24604 i54 = i53;
michael@0 24605 break;
michael@0 24606 }
michael@0 24607 if ((i26 | 0) == 0) {
michael@0 24608 i55 = 0;
michael@0 24609 i56 = i53;
michael@0 24610 } else {
michael@0 24611 i33 = __Z22btAlignedAllocInternalji(i26 << 4, 16) | 0;
michael@0 24612 i55 = i33;
michael@0 24613 i56 = HEAP32[i3 >> 2] | 0;
michael@0 24614 }
michael@0 24615 if ((i56 | 0) > 0) {
michael@0 24616 i33 = 0;
michael@0 24617 do {
michael@0 24618 i31 = i55 + (i33 << 4) | 0;
michael@0 24619 if ((i31 | 0) != 0) {
michael@0 24620 i42 = i31;
michael@0 24621 i31 = (HEAP32[i17 >> 2] | 0) + (i33 << 4) | 0;
michael@0 24622 HEAP32[i42 >> 2] = HEAP32[i31 >> 2];
michael@0 24623 HEAP32[i42 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 24624 HEAP32[i42 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 24625 HEAP32[i42 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 24626 }
michael@0 24627 i33 = i33 + 1 | 0;
michael@0 24628 } while ((i33 | 0) < (i56 | 0));
michael@0 24629 }
michael@0 24630 i33 = HEAP32[i17 >> 2] | 0;
michael@0 24631 if ((i33 | 0) != 0) {
michael@0 24632 if ((HEAP8[i18] | 0) != 0) {
michael@0 24633 __Z21btAlignedFreeInternalPv(i33);
michael@0 24634 }
michael@0 24635 HEAP32[i17 >> 2] = 0;
michael@0 24636 }
michael@0 24637 HEAP8[i18] = 1;
michael@0 24638 HEAP32[i17 >> 2] = i55;
michael@0 24639 HEAP32[i16 >> 2] = i26;
michael@0 24640 i54 = HEAP32[i3 >> 2] | 0;
michael@0 24641 } else {
michael@0 24642 i54 = i32;
michael@0 24643 }
michael@0 24644 } while (0);
michael@0 24645 i32 = HEAP32[i17 >> 2] | 0;
michael@0 24646 i33 = i32 + (i54 << 4) | 0;
michael@0 24647 if ((i33 | 0) == 0) {
michael@0 24648 i57 = i54;
michael@0 24649 } else {
michael@0 24650 HEAPF32[i33 >> 2] = d15;
michael@0 24651 HEAPF32[i32 + (i54 << 4) + 4 >> 2] = d8;
michael@0 24652 HEAPF32[i32 + (i54 << 4) + 8 >> 2] = d9;
michael@0 24653 HEAPF32[i32 + (i54 << 4) + 12 >> 2] = d24;
michael@0 24654 i57 = HEAP32[i3 >> 2] | 0;
michael@0 24655 }
michael@0 24656 HEAP32[i3 >> 2] = i57 + 1;
michael@0 24657 }
michael@0 24658 } while (0);
michael@0 24659 i1 = i2 + 1 | 0;
michael@0 24660 if ((i1 | 0) >= (i5 | 0)) {
michael@0 24661 break;
michael@0 24662 }
michael@0 24663 d19 = d9;
michael@0 24664 d20 = d8;
michael@0 24665 d21 = d15;
michael@0 24666 d22 = d25;
michael@0 24667 i2 = i1;
michael@0 24668 i23 = HEAP32[i7 >> 2] | 0;
michael@0 24669 d10 = +HEAPF32[i6 >> 2];
michael@0 24670 d14 = +HEAPF32[i11 >> 2];
michael@0 24671 d13 = +HEAPF32[i12 >> 2];
michael@0 24672 }
michael@0 24673 return;
michael@0 24674 }
michael@0 24675 function __ZN23btDiscreteDynamicsWorld22addSpeculativeContactsEf(i1, d2) {
michael@0 24676 i1 = i1 | 0;
michael@0 24677 d2 = +d2;
michael@0 24678 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, d71 = 0.0, i72 = 0, d73 = 0.0, i74 = 0, d75 = 0.0, d76 = 0.0, d77 = 0.0, i78 = 0, i79 = 0, i80 = 0, d81 = 0.0;
michael@0 24679 i3 = STACKTOP;
michael@0 24680 STACKTOP = STACKTOP + 496 | 0;
michael@0 24681 i4 = i3 | 0;
michael@0 24682 i5 = i3 + 64 | 0;
michael@0 24683 i6 = i3 + 160 | 0;
michael@0 24684 i7 = i3 + 216 | 0;
michael@0 24685 i8 = i3 + 280 | 0;
michael@0 24686 i9 = i3 + 304 | 0;
michael@0 24687 i10 = i3 + 464 | 0;
michael@0 24688 i11 = i3 + 480 | 0;
michael@0 24689 __ZN15CProfileManager13Start_ProfileEPKc(1088);
michael@0 24690 i12 = i1 + 204 | 0;
michael@0 24691 if ((HEAP32[i12 >> 2] | 0) <= 0) {
michael@0 24692 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 24693 STACKTOP = i3;
michael@0 24694 return;
michael@0 24695 }
michael@0 24696 i13 = i1 + 212 | 0;
michael@0 24697 i14 = i4 + 48 | 0;
michael@0 24698 i15 = i14 | 0;
michael@0 24699 i16 = i4 + 52 | 0;
michael@0 24700 i17 = i4 + 56 | 0;
michael@0 24701 i18 = i1 | 0;
michael@0 24702 i19 = i1 + 76 | 0;
michael@0 24703 i20 = i1 + 24 | 0;
michael@0 24704 i1 = i5 | 0;
michael@0 24705 i21 = i5 + 4 | 0;
michael@0 24706 i22 = i5 + 8 | 0;
michael@0 24707 i23 = i5 + 10 | 0;
michael@0 24708 i24 = i5 + 12 | 0;
michael@0 24709 i25 = i5 + 28 | 0;
michael@0 24710 i26 = i14;
michael@0 24711 i14 = i5 + 76 | 0;
michael@0 24712 i27 = i5 + 80 | 0;
michael@0 24713 i28 = i5 + 84 | 0;
michael@0 24714 i29 = i5 + 88 | 0;
michael@0 24715 i30 = i5 + 92 | 0;
michael@0 24716 i31 = i6 | 0;
michael@0 24717 i32 = i6 | 0;
michael@0 24718 i33 = i6 + 4 | 0;
michael@0 24719 i34 = i6 + 28 | 0;
michael@0 24720 i35 = i6 + 44 | 0;
michael@0 24721 i36 = i5 | 0;
michael@0 24722 i37 = i7;
michael@0 24723 i38 = i4;
michael@0 24724 i39 = i7 + 16 | 0;
michael@0 24725 i40 = i4 + 16 | 0;
michael@0 24726 i41 = i7 + 32 | 0;
michael@0 24727 i42 = i4 + 32 | 0;
michael@0 24728 i43 = i7 + 48 | 0;
michael@0 24729 i44 = i43;
michael@0 24730 i45 = i6 | 0;
michael@0 24731 i6 = i8 + 16 | 0;
michael@0 24732 i46 = i8 + 12 | 0;
michael@0 24733 i47 = i8 + 4 | 0;
michael@0 24734 i48 = i8 + 8 | 0;
michael@0 24735 i49 = i9 + 4 | 0;
michael@0 24736 i50 = i43 | 0;
michael@0 24737 i43 = i7 + 52 | 0;
michael@0 24738 i51 = i7 + 56 | 0;
michael@0 24739 i52 = i10;
michael@0 24740 i53 = i5 + 60 | 0;
michael@0 24741 i54 = i10 | 0;
michael@0 24742 i55 = i10 + 4 | 0;
michael@0 24743 i56 = i10 + 8 | 0;
michael@0 24744 i57 = i5 + 44 | 0;
michael@0 24745 i58 = i57 | 0;
michael@0 24746 i59 = i5 + 48 | 0;
michael@0 24747 i60 = i5 + 52 | 0;
michael@0 24748 i5 = i11 | 0;
michael@0 24749 i61 = i11 + 4 | 0;
michael@0 24750 i62 = i11 + 8 | 0;
michael@0 24751 i63 = i11 + 12 | 0;
michael@0 24752 i64 = 0;
michael@0 24753 do {
michael@0 24754 i65 = HEAP32[(HEAP32[i13 >> 2] | 0) + (i64 << 2) >> 2] | 0;
michael@0 24755 i66 = i65 | 0;
michael@0 24756 HEAPF32[i65 + 240 >> 2] = 1.0;
michael@0 24757 i67 = HEAP32[i65 + 216 >> 2] | 0;
michael@0 24758 do {
michael@0 24759 if (!((i67 | 0) == 5 | (i67 | 0) == 2)) {
michael@0 24760 if ((HEAP32[i65 + 204 >> 2] & 3 | 0) != 0) {
michael@0 24761 break;
michael@0 24762 }
michael@0 24763 __ZN11btRigidBody26predictIntegratedTransformEfR11btTransform(i65, d2, i4);
michael@0 24764 i68 = i65 + 4 | 0;
michael@0 24765 i69 = i65 + 52 | 0;
michael@0 24766 i70 = i69 | 0;
michael@0 24767 d71 = +HEAPF32[i15 >> 2] - +HEAPF32[i70 >> 2];
michael@0 24768 i72 = i65 + 56 | 0;
michael@0 24769 d73 = +HEAPF32[i16 >> 2] - +HEAPF32[i72 >> 2];
michael@0 24770 i74 = i65 + 60 | 0;
michael@0 24771 d75 = +HEAPF32[i17 >> 2] - +HEAPF32[i74 >> 2];
michael@0 24772 d76 = +HEAPF32[i65 + 248 >> 2];
michael@0 24773 d77 = d76 * d76;
michael@0 24774 if (!(d77 != 0.0 & d77 < d71 * d71 + d73 * d73 + d75 * d75)) {
michael@0 24775 break;
michael@0 24776 }
michael@0 24777 __ZN15CProfileManager13Start_ProfileEPKc(1032);
michael@0 24778 if ((HEAP32[(HEAP32[i65 + 192 >> 2] | 0) + 4 >> 2] | 0) < 20) {
michael@0 24779 HEAP32[2996] = (HEAP32[2996] | 0) + 1;
michael@0 24780 i78 = HEAP32[i19 >> 2] | 0;
michael@0 24781 i79 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i78 >> 2] | 0) + 36 >> 2] & 127](i78) | 0;
michael@0 24782 i78 = HEAP32[i20 >> 2] | 0;
michael@0 24783 HEAPF32[i21 >> 2] = 1.0;
michael@0 24784 HEAP16[i22 >> 1] = 1;
michael@0 24785 HEAP16[i23 >> 1] = -1;
michael@0 24786 HEAP32[i1 >> 2] = 2248;
michael@0 24787 i80 = i69;
michael@0 24788 HEAP32[i24 >> 2] = HEAP32[i80 >> 2];
michael@0 24789 HEAP32[i24 + 4 >> 2] = HEAP32[i80 + 4 >> 2];
michael@0 24790 HEAP32[i24 + 8 >> 2] = HEAP32[i80 + 8 >> 2];
michael@0 24791 HEAP32[i24 + 12 >> 2] = HEAP32[i80 + 12 >> 2];
michael@0 24792 HEAP32[i25 >> 2] = HEAP32[i26 >> 2];
michael@0 24793 HEAP32[i25 + 4 >> 2] = HEAP32[i26 + 4 >> 2];
michael@0 24794 HEAP32[i25 + 8 >> 2] = HEAP32[i26 + 8 >> 2];
michael@0 24795 HEAP32[i25 + 12 >> 2] = HEAP32[i26 + 12 >> 2];
michael@0 24796 HEAP32[i14 >> 2] = 0;
michael@0 24797 HEAP32[i1 >> 2] = 2464;
michael@0 24798 HEAP32[i27 >> 2] = i66;
michael@0 24799 HEAPF32[i28 >> 2] = 0.0;
michael@0 24800 HEAP32[i29 >> 2] = i79;
michael@0 24801 HEAP32[i30 >> 2] = i78;
michael@0 24802 d75 = +HEAPF32[i65 + 244 >> 2];
michael@0 24803 __ZN21btConvexInternalShapeC2Ev(i31);
michael@0 24804 HEAP32[i32 >> 2] = 4728;
michael@0 24805 HEAP32[i33 >> 2] = 8;
michael@0 24806 HEAPF32[i34 >> 2] = d75;
michael@0 24807 HEAPF32[i35 >> 2] = d75;
michael@0 24808 i78 = i65 + 188 | 0;
michael@0 24809 i79 = HEAP32[i78 >> 2] | 0;
michael@0 24810 HEAP16[i22 >> 1] = HEAP16[i79 + 4 >> 1] | 0;
michael@0 24811 HEAP16[i23 >> 1] = HEAP16[i79 + 6 >> 1] | 0;
michael@0 24812 HEAP32[i37 >> 2] = HEAP32[i38 >> 2];
michael@0 24813 HEAP32[i37 + 4 >> 2] = HEAP32[i38 + 4 >> 2];
michael@0 24814 HEAP32[i37 + 8 >> 2] = HEAP32[i38 + 8 >> 2];
michael@0 24815 HEAP32[i37 + 12 >> 2] = HEAP32[i38 + 12 >> 2];
michael@0 24816 HEAP32[i39 >> 2] = HEAP32[i40 >> 2];
michael@0 24817 HEAP32[i39 + 4 >> 2] = HEAP32[i40 + 4 >> 2];
michael@0 24818 HEAP32[i39 + 8 >> 2] = HEAP32[i40 + 8 >> 2];
michael@0 24819 HEAP32[i39 + 12 >> 2] = HEAP32[i40 + 12 >> 2];
michael@0 24820 HEAP32[i41 >> 2] = HEAP32[i42 >> 2];
michael@0 24821 HEAP32[i41 + 4 >> 2] = HEAP32[i42 + 4 >> 2];
michael@0 24822 HEAP32[i41 + 8 >> 2] = HEAP32[i42 + 8 >> 2];
michael@0 24823 HEAP32[i41 + 12 >> 2] = HEAP32[i42 + 12 >> 2];
michael@0 24824 HEAP32[i44 >> 2] = HEAP32[i26 >> 2];
michael@0 24825 HEAP32[i44 + 4 >> 2] = HEAP32[i26 + 4 >> 2];
michael@0 24826 HEAP32[i44 + 8 >> 2] = HEAP32[i26 + 8 >> 2];
michael@0 24827 HEAP32[i44 + 12 >> 2] = HEAP32[i26 + 12 >> 2];
michael@0 24828 i79 = i68;
michael@0 24829 HEAP32[i37 >> 2] = HEAP32[i79 >> 2];
michael@0 24830 HEAP32[i37 + 4 >> 2] = HEAP32[i79 + 4 >> 2];
michael@0 24831 HEAP32[i37 + 8 >> 2] = HEAP32[i79 + 8 >> 2];
michael@0 24832 HEAP32[i37 + 12 >> 2] = HEAP32[i79 + 12 >> 2];
michael@0 24833 i79 = i65 + 20 | 0;
michael@0 24834 HEAP32[i39 >> 2] = HEAP32[i79 >> 2];
michael@0 24835 HEAP32[i39 + 4 >> 2] = HEAP32[i79 + 4 >> 2];
michael@0 24836 HEAP32[i39 + 8 >> 2] = HEAP32[i79 + 8 >> 2];
michael@0 24837 HEAP32[i39 + 12 >> 2] = HEAP32[i79 + 12 >> 2];
michael@0 24838 i79 = i65 + 36 | 0;
michael@0 24839 HEAP32[i41 >> 2] = HEAP32[i79 >> 2];
michael@0 24840 HEAP32[i41 + 4 >> 2] = HEAP32[i79 + 4 >> 2];
michael@0 24841 HEAP32[i41 + 8 >> 2] = HEAP32[i79 + 8 >> 2];
michael@0 24842 HEAP32[i41 + 12 >> 2] = HEAP32[i79 + 12 >> 2];
michael@0 24843 __ZNK16btCollisionWorld15convexSweepTestEPK13btConvexShapeRK11btTransformS5_RNS_20ConvexResultCallbackEf(i18, i45, i68, i7, i36, 0.0);
michael@0 24844 do {
michael@0 24845 if (+HEAPF32[i21 >> 2] < 1.0) {
michael@0 24846 i68 = HEAP32[i29 >> 2] | 0;
michael@0 24847 i79 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i68 >> 2] | 0) + 52 >> 2] & 31](i68, HEAP32[i78 >> 2] | 0, HEAP32[(HEAP32[i14 >> 2] | 0) + 188 >> 2] | 0) | 0;
michael@0 24848 if ((i79 | 0) == 0) {
michael@0 24849 break;
michael@0 24850 }
michael@0 24851 i68 = i79 + 8 | 0;
michael@0 24852 if ((HEAP32[i68 >> 2] | 0) == 0) {
michael@0 24853 break;
michael@0 24854 }
michael@0 24855 HEAP8[i6] = 1;
michael@0 24856 HEAP32[i46 >> 2] = 0;
michael@0 24857 HEAP32[i47 >> 2] = 0;
michael@0 24858 HEAP32[i48 >> 2] = 0;
michael@0 24859 i79 = HEAP32[i68 >> 2] | 0;
michael@0 24860 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i79 >> 2] | 0) + 16 >> 2] & 127](i79, i8);
michael@0 24861 do {
michael@0 24862 if ((HEAP32[i47 >> 2] | 0) != 0) {
michael@0 24863 __ZN16btManifoldResultC2EP17btCollisionObjectS1_(i9, i66, HEAP32[i14 >> 2] | 0);
michael@0 24864 i79 = HEAP32[i46 >> 2] | 0;
michael@0 24865 HEAP32[i49 >> 2] = HEAP32[i79 >> 2];
michael@0 24866 d75 = +HEAPF32[i21 >> 2];
michael@0 24867 d73 = (+HEAPF32[i50 >> 2] - +HEAPF32[i70 >> 2]) * d75;
michael@0 24868 d71 = (+HEAPF32[i43 >> 2] - +HEAPF32[i72 >> 2]) * d75;
michael@0 24869 d77 = d75 * (+HEAPF32[i51 >> 2] - +HEAPF32[i74 >> 2]);
michael@0 24870 d75 = d77 * d77 + (d73 * d73 + d71 * d71);
michael@0 24871 HEAP32[i52 >> 2] = HEAP32[i53 >> 2];
michael@0 24872 HEAP32[i52 + 4 >> 2] = HEAP32[i53 + 4 >> 2];
michael@0 24873 HEAP32[i52 + 8 >> 2] = HEAP32[i53 + 8 >> 2];
michael@0 24874 HEAP32[i52 + 12 >> 2] = HEAP32[i53 + 12 >> 2];
michael@0 24875 if (d75 > 1.1920928955078125e-7) {
michael@0 24876 d76 = +Math_sqrt(+d75);
michael@0 24877 HEAPF32[i54 >> 2] = +HEAPF32[i54 >> 2] - d73;
michael@0 24878 HEAPF32[i55 >> 2] = +HEAPF32[i55 >> 2] - d71;
michael@0 24879 HEAPF32[i56 >> 2] = +HEAPF32[i56 >> 2] - d77;
michael@0 24880 d81 = d76;
michael@0 24881 } else {
michael@0 24882 d81 = 0.0;
michael@0 24883 }
michael@0 24884 if ((HEAP32[(HEAP32[i79 >> 2] | 0) + 1108 >> 2] | 0) == (i65 | 0)) {
michael@0 24885 __ZN16btManifoldResult15addContactPointERK9btVector3S2_f(i9, i57, i10, d81);
michael@0 24886 break;
michael@0 24887 } else {
michael@0 24888 d76 = -0.0 - +HEAPF32[i59 >> 2];
michael@0 24889 d77 = -0.0 - +HEAPF32[i60 >> 2];
michael@0 24890 HEAPF32[i5 >> 2] = -0.0 - +HEAPF32[i58 >> 2];
michael@0 24891 HEAPF32[i61 >> 2] = d76;
michael@0 24892 HEAPF32[i62 >> 2] = d77;
michael@0 24893 HEAPF32[i63 >> 2] = 0.0;
michael@0 24894 __ZN16btManifoldResult15addContactPointERK9btVector3S2_f(i9, i11, i10, d81);
michael@0 24895 break;
michael@0 24896 }
michael@0 24897 }
michael@0 24898 } while (0);
michael@0 24899 i79 = HEAP32[i46 >> 2] | 0;
michael@0 24900 if ((i79 | 0) != 0) {
michael@0 24901 if ((HEAP8[i6] | 0) != 0) {
michael@0 24902 __Z21btAlignedFreeInternalPv(i79);
michael@0 24903 }
michael@0 24904 HEAP32[i46 >> 2] = 0;
michael@0 24905 }
michael@0 24906 HEAP8[i6] = 1;
michael@0 24907 HEAP32[i46 >> 2] = 0;
michael@0 24908 HEAP32[i47 >> 2] = 0;
michael@0 24909 HEAP32[i48 >> 2] = 0;
michael@0 24910 }
michael@0 24911 } while (0);
michael@0 24912 __ZN13btConvexShapeD2Ev(i45);
michael@0 24913 }
michael@0 24914 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 24915 }
michael@0 24916 } while (0);
michael@0 24917 i64 = i64 + 1 | 0;
michael@0 24918 } while ((i64 | 0) < (HEAP32[i12 >> 2] | 0));
michael@0 24919 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 24920 STACKTOP = i3;
michael@0 24921 return;
michael@0 24922 }
michael@0 24923 function __ZN22btVoronoiSimplexSolver28updateClosestVectorAndPointsEv(i1) {
michael@0 24924 i1 = i1 | 0;
michael@0 24925 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, i25 = 0, d26 = 0.0, i27 = 0, i28 = 0;
michael@0 24926 i2 = STACKTOP;
michael@0 24927 STACKTOP = STACKTOP + 32 | 0;
michael@0 24928 i3 = i2 | 0;
michael@0 24929 i4 = i2 + 16 | 0;
michael@0 24930 i5 = i1 + 356 | 0;
michael@0 24931 if ((HEAP8[i5] | 0) == 0) {
michael@0 24932 i6 = HEAP8[i1 + 312 | 0] | 0;
michael@0 24933 i7 = i6 << 24 >> 24 != 0;
michael@0 24934 STACKTOP = i2;
michael@0 24935 return i7 | 0;
michael@0 24936 }
michael@0 24937 i8 = i1 + 316 | 0;
michael@0 24938 i9 = i1 + 336 | 0;
michael@0 24939 i10 = i1 + 332 | 0;
michael@0 24940 i11 = i10;
michael@0 24941 i12 = i9;
michael@0 24942 _memset(i12 | 0, 0, 17);
michael@0 24943 i13 = HEAP16[i11 >> 1] & -16;
michael@0 24944 HEAP16[i11 >> 1] = i13;
michael@0 24945 HEAP8[i5] = 0;
michael@0 24946 switch (HEAP32[i1 >> 2] | 0) {
michael@0 24947 case 4:
michael@0 24948 {
michael@0 24949 _memset(i4 | 0, 0, 16);
michael@0 24950 if (!(__ZN22btVoronoiSimplexSolver25closestPtPointTetrahedronERK9btVector3S2_S2_S2_S2_R25btSubSimplexClosestResult(0, i4, i1 + 4 | 0, i1 + 20 | 0, i1 + 36 | 0, i1 + 52 | 0, i8) | 0)) {
michael@0 24951 i4 = i1 + 312 | 0;
michael@0 24952 if ((HEAP8[i1 + 352 | 0] | 0) == 0) {
michael@0 24953 HEAP8[i4] = 1;
michael@0 24954 _memset(i1 + 276 | 0, 0, 16);
michael@0 24955 i6 = 1;
michael@0 24956 i7 = i6 << 24 >> 24 != 0;
michael@0 24957 STACKTOP = i2;
michael@0 24958 return i7 | 0;
michael@0 24959 } else {
michael@0 24960 HEAP8[i4] = 0;
michael@0 24961 i6 = 0;
michael@0 24962 i7 = i6 << 24 >> 24 != 0;
michael@0 24963 STACKTOP = i2;
michael@0 24964 return i7 | 0;
michael@0 24965 }
michael@0 24966 }
michael@0 24967 d14 = +HEAPF32[i9 >> 2];
michael@0 24968 i4 = i1 + 340 | 0;
michael@0 24969 d15 = +HEAPF32[i4 >> 2];
michael@0 24970 i5 = i1 + 344 | 0;
michael@0 24971 d16 = +HEAPF32[i5 >> 2];
michael@0 24972 i17 = i1 + 348 | 0;
michael@0 24973 d18 = +HEAPF32[i17 >> 2];
michael@0 24974 d19 = +HEAPF32[i1 + 84 >> 2] * d14 + +HEAPF32[i1 + 100 >> 2] * d15 + +HEAPF32[i1 + 116 >> 2] * d16 + +HEAPF32[i1 + 132 >> 2] * d18;
michael@0 24975 d20 = d14 * +HEAPF32[i1 + 88 >> 2] + d15 * +HEAPF32[i1 + 104 >> 2] + d16 * +HEAPF32[i1 + 120 >> 2] + d18 * +HEAPF32[i1 + 136 >> 2];
michael@0 24976 d21 = d14 * +HEAPF32[i1 + 92 >> 2] + d15 * +HEAPF32[i1 + 108 >> 2] + d16 * +HEAPF32[i1 + 124 >> 2] + d18 * +HEAPF32[i1 + 140 >> 2];
michael@0 24977 HEAPF32[i1 + 244 >> 2] = d19;
michael@0 24978 HEAPF32[i1 + 248 >> 2] = d20;
michael@0 24979 HEAPF32[i1 + 252 >> 2] = d21;
michael@0 24980 HEAPF32[i1 + 256 >> 2] = 0.0;
michael@0 24981 d22 = d14 * +HEAPF32[i1 + 164 >> 2] + d15 * +HEAPF32[i1 + 180 >> 2] + d16 * +HEAPF32[i1 + 196 >> 2] + d18 * +HEAPF32[i1 + 212 >> 2];
michael@0 24982 d23 = d14 * +HEAPF32[i1 + 168 >> 2] + d15 * +HEAPF32[i1 + 184 >> 2] + d16 * +HEAPF32[i1 + 200 >> 2] + d18 * +HEAPF32[i1 + 216 >> 2];
michael@0 24983 d24 = d14 * +HEAPF32[i1 + 172 >> 2] + d15 * +HEAPF32[i1 + 188 >> 2] + d16 * +HEAPF32[i1 + 204 >> 2] + d18 * +HEAPF32[i1 + 220 >> 2];
michael@0 24984 HEAPF32[i1 + 260 >> 2] = d22;
michael@0 24985 HEAPF32[i1 + 264 >> 2] = d23;
michael@0 24986 HEAPF32[i1 + 268 >> 2] = d24;
michael@0 24987 HEAPF32[i1 + 272 >> 2] = 0.0;
michael@0 24988 HEAPF32[i1 + 276 >> 2] = d19 - d22;
michael@0 24989 HEAPF32[i1 + 280 >> 2] = d20 - d23;
michael@0 24990 HEAPF32[i1 + 284 >> 2] = d21 - d24;
michael@0 24991 HEAPF32[i1 + 288 >> 2] = 0.0;
michael@0 24992 __ZN22btVoronoiSimplexSolver14reduceVerticesERK15btUsageBitfield(i1, i10);
michael@0 24993 do {
michael@0 24994 if (+HEAPF32[i9 >> 2] < 0.0) {
michael@0 24995 i25 = 0;
michael@0 24996 } else {
michael@0 24997 if (+HEAPF32[i4 >> 2] < 0.0) {
michael@0 24998 i25 = 0;
michael@0 24999 break;
michael@0 25000 }
michael@0 25001 if (+HEAPF32[i5 >> 2] < 0.0) {
michael@0 25002 i25 = 0;
michael@0 25003 break;
michael@0 25004 }
michael@0 25005 i25 = +HEAPF32[i17 >> 2] >= 0.0 | 0;
michael@0 25006 }
michael@0 25007 } while (0);
michael@0 25008 HEAP8[i1 + 312 | 0] = i25;
michael@0 25009 i6 = i25;
michael@0 25010 i7 = i6 << 24 >> 24 != 0;
michael@0 25011 STACKTOP = i2;
michael@0 25012 return i7 | 0;
michael@0 25013 }
michael@0 25014 case 0:
michael@0 25015 {
michael@0 25016 HEAP8[i1 + 312 | 0] = 0;
michael@0 25017 i6 = 0;
michael@0 25018 i7 = i6 << 24 >> 24 != 0;
michael@0 25019 STACKTOP = i2;
michael@0 25020 return i7 | 0;
michael@0 25021 }
michael@0 25022 case 1:
michael@0 25023 {
michael@0 25024 i25 = i1 + 244 | 0;
michael@0 25025 i17 = i25;
michael@0 25026 i5 = i1 + 84 | 0;
michael@0 25027 HEAP32[i17 >> 2] = HEAP32[i5 >> 2];
michael@0 25028 HEAP32[i17 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 25029 HEAP32[i17 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 25030 HEAP32[i17 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 25031 i5 = i1 + 260 | 0;
michael@0 25032 i17 = i5;
michael@0 25033 i4 = i1 + 164 | 0;
michael@0 25034 HEAP32[i17 >> 2] = HEAP32[i4 >> 2];
michael@0 25035 HEAP32[i17 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 25036 HEAP32[i17 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 25037 HEAP32[i17 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 25038 d24 = +HEAPF32[i1 + 248 >> 2] - +HEAPF32[i1 + 264 >> 2];
michael@0 25039 d21 = +HEAPF32[i1 + 252 >> 2] - +HEAPF32[i1 + 268 >> 2];
michael@0 25040 HEAPF32[i1 + 276 >> 2] = +HEAPF32[i25 >> 2] - +HEAPF32[i5 >> 2];
michael@0 25041 HEAPF32[i1 + 280 >> 2] = d24;
michael@0 25042 HEAPF32[i1 + 284 >> 2] = d21;
michael@0 25043 HEAPF32[i1 + 288 >> 2] = 0.0;
michael@0 25044 _memset(i12 | 0, 0, 17);
michael@0 25045 HEAP16[i11 >> 1] = i13;
michael@0 25046 HEAPF32[i9 >> 2] = 1.0;
michael@0 25047 HEAPF32[i1 + 340 >> 2] = 0.0;
michael@0 25048 HEAPF32[i1 + 344 >> 2] = 0.0;
michael@0 25049 HEAPF32[i1 + 348 >> 2] = 0.0;
michael@0 25050 HEAP8[i1 + 312 | 0] = 1;
michael@0 25051 i6 = 1;
michael@0 25052 i7 = i6 << 24 >> 24 != 0;
michael@0 25053 STACKTOP = i2;
michael@0 25054 return i7 | 0;
michael@0 25055 }
michael@0 25056 case 2:
michael@0 25057 {
michael@0 25058 d21 = +HEAPF32[i1 + 4 >> 2];
michael@0 25059 d24 = +HEAPF32[i1 + 8 >> 2];
michael@0 25060 d23 = +HEAPF32[i1 + 12 >> 2];
michael@0 25061 d20 = +HEAPF32[i1 + 20 >> 2] - d21;
michael@0 25062 d22 = +HEAPF32[i1 + 24 >> 2] - d24;
michael@0 25063 d19 = +HEAPF32[i1 + 28 >> 2] - d23;
michael@0 25064 d18 = (0.0 - d21) * d20 + (0.0 - d24) * d22 + (0.0 - d23) * d19;
michael@0 25065 do {
michael@0 25066 if (d18 > 0.0) {
michael@0 25067 d23 = d20 * d20 + d22 * d22 + d19 * d19;
michael@0 25068 if (d18 < d23) {
michael@0 25069 HEAP16[i11 >> 1] = i13 | 3;
michael@0 25070 d26 = d18 / d23;
michael@0 25071 break;
michael@0 25072 } else {
michael@0 25073 HEAP16[i11 >> 1] = i13 | 2;
michael@0 25074 d26 = 1.0;
michael@0 25075 break;
michael@0 25076 }
michael@0 25077 } else {
michael@0 25078 HEAP16[i11 >> 1] = i13 | 1;
michael@0 25079 d26 = 0.0;
michael@0 25080 }
michael@0 25081 } while (0);
michael@0 25082 HEAPF32[i9 >> 2] = 1.0 - d26;
michael@0 25083 i13 = i1 + 340 | 0;
michael@0 25084 HEAPF32[i13 >> 2] = d26;
michael@0 25085 i11 = i1 + 344 | 0;
michael@0 25086 HEAPF32[i11 >> 2] = 0.0;
michael@0 25087 i12 = i1 + 348 | 0;
michael@0 25088 HEAPF32[i12 >> 2] = 0.0;
michael@0 25089 d18 = +HEAPF32[i1 + 84 >> 2];
michael@0 25090 d19 = +HEAPF32[i1 + 88 >> 2];
michael@0 25091 d22 = +HEAPF32[i1 + 92 >> 2];
michael@0 25092 d20 = d18 + d26 * (+HEAPF32[i1 + 100 >> 2] - d18);
michael@0 25093 d18 = d19 + d26 * (+HEAPF32[i1 + 104 >> 2] - d19);
michael@0 25094 d19 = d22 + d26 * (+HEAPF32[i1 + 108 >> 2] - d22);
michael@0 25095 HEAPF32[i1 + 244 >> 2] = d20;
michael@0 25096 HEAPF32[i1 + 248 >> 2] = d18;
michael@0 25097 HEAPF32[i1 + 252 >> 2] = d19;
michael@0 25098 HEAPF32[i1 + 256 >> 2] = 0.0;
michael@0 25099 d22 = +HEAPF32[i1 + 164 >> 2];
michael@0 25100 d23 = +HEAPF32[i1 + 168 >> 2];
michael@0 25101 d24 = +HEAPF32[i1 + 172 >> 2];
michael@0 25102 d21 = d22 + d26 * (+HEAPF32[i1 + 180 >> 2] - d22);
michael@0 25103 d22 = d23 + d26 * (+HEAPF32[i1 + 184 >> 2] - d23);
michael@0 25104 d23 = d24 + d26 * (+HEAPF32[i1 + 188 >> 2] - d24);
michael@0 25105 HEAPF32[i1 + 260 >> 2] = d21;
michael@0 25106 HEAPF32[i1 + 264 >> 2] = d22;
michael@0 25107 HEAPF32[i1 + 268 >> 2] = d23;
michael@0 25108 HEAPF32[i1 + 272 >> 2] = 0.0;
michael@0 25109 HEAPF32[i1 + 276 >> 2] = d20 - d21;
michael@0 25110 HEAPF32[i1 + 280 >> 2] = d18 - d22;
michael@0 25111 HEAPF32[i1 + 284 >> 2] = d19 - d23;
michael@0 25112 HEAPF32[i1 + 288 >> 2] = 0.0;
michael@0 25113 __ZN22btVoronoiSimplexSolver14reduceVerticesERK15btUsageBitfield(i1, i10);
michael@0 25114 do {
michael@0 25115 if (+HEAPF32[i9 >> 2] < 0.0) {
michael@0 25116 i27 = 0;
michael@0 25117 } else {
michael@0 25118 if (+HEAPF32[i13 >> 2] < 0.0) {
michael@0 25119 i27 = 0;
michael@0 25120 break;
michael@0 25121 }
michael@0 25122 if (+HEAPF32[i11 >> 2] < 0.0) {
michael@0 25123 i27 = 0;
michael@0 25124 break;
michael@0 25125 }
michael@0 25126 i27 = +HEAPF32[i12 >> 2] >= 0.0 | 0;
michael@0 25127 }
michael@0 25128 } while (0);
michael@0 25129 HEAP8[i1 + 312 | 0] = i27;
michael@0 25130 i6 = i27;
michael@0 25131 i7 = i6 << 24 >> 24 != 0;
michael@0 25132 STACKTOP = i2;
michael@0 25133 return i7 | 0;
michael@0 25134 }
michael@0 25135 case 3:
michael@0 25136 {
michael@0 25137 _memset(i3 | 0, 0, 16);
michael@0 25138 __ZN22btVoronoiSimplexSolver22closestPtPointTriangleERK9btVector3S2_S2_S2_R25btSubSimplexClosestResult(0, i3, i1 + 4 | 0, i1 + 20 | 0, i1 + 36 | 0, i8) | 0;
michael@0 25139 d23 = +HEAPF32[i9 >> 2];
michael@0 25140 i8 = i1 + 340 | 0;
michael@0 25141 d19 = +HEAPF32[i8 >> 2];
michael@0 25142 i3 = i1 + 344 | 0;
michael@0 25143 d22 = +HEAPF32[i3 >> 2];
michael@0 25144 d18 = +HEAPF32[i1 + 84 >> 2] * d23 + +HEAPF32[i1 + 100 >> 2] * d19 + +HEAPF32[i1 + 116 >> 2] * d22;
michael@0 25145 d21 = d23 * +HEAPF32[i1 + 88 >> 2] + d19 * +HEAPF32[i1 + 104 >> 2] + d22 * +HEAPF32[i1 + 120 >> 2];
michael@0 25146 d20 = d23 * +HEAPF32[i1 + 92 >> 2] + d19 * +HEAPF32[i1 + 108 >> 2] + d22 * +HEAPF32[i1 + 124 >> 2];
michael@0 25147 HEAPF32[i1 + 244 >> 2] = d18;
michael@0 25148 HEAPF32[i1 + 248 >> 2] = d21;
michael@0 25149 HEAPF32[i1 + 252 >> 2] = d20;
michael@0 25150 HEAPF32[i1 + 256 >> 2] = 0.0;
michael@0 25151 d24 = d23 * +HEAPF32[i1 + 164 >> 2] + d19 * +HEAPF32[i1 + 180 >> 2] + d22 * +HEAPF32[i1 + 196 >> 2];
michael@0 25152 d26 = d23 * +HEAPF32[i1 + 168 >> 2] + d19 * +HEAPF32[i1 + 184 >> 2] + d22 * +HEAPF32[i1 + 200 >> 2];
michael@0 25153 d16 = d23 * +HEAPF32[i1 + 172 >> 2] + d19 * +HEAPF32[i1 + 188 >> 2] + d22 * +HEAPF32[i1 + 204 >> 2];
michael@0 25154 HEAPF32[i1 + 260 >> 2] = d24;
michael@0 25155 HEAPF32[i1 + 264 >> 2] = d26;
michael@0 25156 HEAPF32[i1 + 268 >> 2] = d16;
michael@0 25157 HEAPF32[i1 + 272 >> 2] = 0.0;
michael@0 25158 HEAPF32[i1 + 276 >> 2] = d18 - d24;
michael@0 25159 HEAPF32[i1 + 280 >> 2] = d21 - d26;
michael@0 25160 HEAPF32[i1 + 284 >> 2] = d20 - d16;
michael@0 25161 HEAPF32[i1 + 288 >> 2] = 0.0;
michael@0 25162 __ZN22btVoronoiSimplexSolver14reduceVerticesERK15btUsageBitfield(i1, i10);
michael@0 25163 do {
michael@0 25164 if (+HEAPF32[i9 >> 2] < 0.0) {
michael@0 25165 i28 = 0;
michael@0 25166 } else {
michael@0 25167 if (+HEAPF32[i8 >> 2] < 0.0) {
michael@0 25168 i28 = 0;
michael@0 25169 break;
michael@0 25170 }
michael@0 25171 if (+HEAPF32[i3 >> 2] < 0.0) {
michael@0 25172 i28 = 0;
michael@0 25173 break;
michael@0 25174 }
michael@0 25175 i28 = +HEAPF32[i1 + 348 >> 2] >= 0.0 | 0;
michael@0 25176 }
michael@0 25177 } while (0);
michael@0 25178 HEAP8[i1 + 312 | 0] = i28;
michael@0 25179 i6 = i28;
michael@0 25180 i7 = i6 << 24 >> 24 != 0;
michael@0 25181 STACKTOP = i2;
michael@0 25182 return i7 | 0;
michael@0 25183 }
michael@0 25184 default:
michael@0 25185 {
michael@0 25186 HEAP8[i1 + 312 | 0] = 0;
michael@0 25187 i6 = 0;
michael@0 25188 i7 = i6 << 24 >> 24 != 0;
michael@0 25189 STACKTOP = i2;
michael@0 25190 return i7 | 0;
michael@0 25191 }
michael@0 25192 }
michael@0 25193 return 0;
michael@0 25194 }
michael@0 25195 function __ZN15btGjkEpaSolver28DistanceEPK13btConvexShapeRK11btTransformS2_S5_RK9btVector3RNS_8sResultsE(i1, i2, i3, i4, i5, i6) {
michael@0 25196 i1 = i1 | 0;
michael@0 25197 i2 = i2 | 0;
michael@0 25198 i3 = i3 | 0;
michael@0 25199 i4 = i4 | 0;
michael@0 25200 i5 = i5 | 0;
michael@0 25201 i6 = i6 | 0;
michael@0 25202 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, d16 = 0.0, d17 = 0.0, d18 = 0.0, i19 = 0, d20 = 0.0, d21 = 0.0, i22 = 0, d23 = 0.0, d24 = 0.0, i25 = 0, d26 = 0.0, i27 = 0, d28 = 0.0, i29 = 0, d30 = 0.0, d31 = 0.0, i32 = 0, d33 = 0.0, i34 = 0, d35 = 0.0, i36 = 0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, d71 = 0.0, d72 = 0.0, d73 = 0.0, d74 = 0.0, d75 = 0.0, d76 = 0.0, i77 = 0, i78 = 0, i79 = 0, i80 = 0, i81 = 0, i82 = 0, i83 = 0, i84 = 0, i85 = 0, i86 = 0, i87 = 0, i88 = 0;
michael@0 25203 i7 = STACKTOP;
michael@0 25204 STACKTOP = STACKTOP + 560 | 0;
michael@0 25205 i8 = i7 | 0;
michael@0 25206 i9 = i7 + 16 | 0;
michael@0 25207 i10 = i7 + 32 | 0;
michael@0 25208 i11 = i7 + 160 | 0;
michael@0 25209 i12 = i7 + 544 | 0;
michael@0 25210 i13 = i6 + 20 | 0;
michael@0 25211 i14 = i6 + 20 | 0;
michael@0 25212 i15 = i6 + 4 | 0;
michael@0 25213 _memset(i14 | 0, 0, 16);
michael@0 25214 HEAP32[i15 >> 2] = HEAP32[i13 >> 2];
michael@0 25215 HEAP32[i15 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 25216 HEAP32[i15 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 25217 HEAP32[i15 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 25218 i13 = i6 | 0;
michael@0 25219 HEAP32[i13 >> 2] = 0;
michael@0 25220 i15 = i10 | 0;
michael@0 25221 HEAP32[i15 >> 2] = i1;
michael@0 25222 i1 = i10 + 4 | 0;
michael@0 25223 HEAP32[i1 >> 2] = i3;
michael@0 25224 d16 = +HEAPF32[i4 >> 2];
michael@0 25225 i3 = i2 | 0;
michael@0 25226 d17 = +HEAPF32[i3 >> 2];
michael@0 25227 d18 = +HEAPF32[i4 + 16 >> 2];
michael@0 25228 i19 = i2 + 16 | 0;
michael@0 25229 d20 = +HEAPF32[i19 >> 2];
michael@0 25230 d21 = +HEAPF32[i4 + 32 >> 2];
michael@0 25231 i22 = i2 + 32 | 0;
michael@0 25232 d23 = +HEAPF32[i22 >> 2];
michael@0 25233 d24 = d16 * d17 + d18 * d20 + d21 * d23;
michael@0 25234 i25 = i2 + 4 | 0;
michael@0 25235 d26 = +HEAPF32[i25 >> 2];
michael@0 25236 i27 = i2 + 20 | 0;
michael@0 25237 d28 = +HEAPF32[i27 >> 2];
michael@0 25238 i29 = i2 + 36 | 0;
michael@0 25239 d30 = +HEAPF32[i29 >> 2];
michael@0 25240 d31 = d16 * d26 + d18 * d28 + d21 * d30;
michael@0 25241 i32 = i2 + 8 | 0;
michael@0 25242 d33 = +HEAPF32[i32 >> 2];
michael@0 25243 i34 = i2 + 24 | 0;
michael@0 25244 d35 = +HEAPF32[i34 >> 2];
michael@0 25245 i36 = i2 + 40 | 0;
michael@0 25246 d37 = +HEAPF32[i36 >> 2];
michael@0 25247 d38 = d16 * d33 + d18 * d35 + d21 * d37;
michael@0 25248 d21 = +HEAPF32[i4 + 4 >> 2];
michael@0 25249 d18 = +HEAPF32[i4 + 20 >> 2];
michael@0 25250 d16 = +HEAPF32[i4 + 36 >> 2];
michael@0 25251 d39 = d17 * d21 + d20 * d18 + d23 * d16;
michael@0 25252 d40 = d26 * d21 + d28 * d18 + d30 * d16;
michael@0 25253 d41 = d33 * d21 + d35 * d18 + d37 * d16;
michael@0 25254 d16 = +HEAPF32[i4 + 8 >> 2];
michael@0 25255 d18 = +HEAPF32[i4 + 24 >> 2];
michael@0 25256 d21 = +HEAPF32[i4 + 40 >> 2];
michael@0 25257 d42 = d17 * d16 + d20 * d18 + d23 * d21;
michael@0 25258 d43 = d26 * d16 + d28 * d18 + d30 * d21;
michael@0 25259 d44 = d33 * d16 + d35 * d18 + d37 * d21;
michael@0 25260 i45 = i10 + 8 | 0;
michael@0 25261 HEAPF32[i45 >> 2] = d24;
michael@0 25262 i46 = i10 + 12 | 0;
michael@0 25263 HEAPF32[i46 >> 2] = d31;
michael@0 25264 i47 = i10 + 16 | 0;
michael@0 25265 HEAPF32[i47 >> 2] = d38;
michael@0 25266 HEAPF32[i10 + 20 >> 2] = 0.0;
michael@0 25267 i48 = i10 + 24 | 0;
michael@0 25268 HEAPF32[i48 >> 2] = d39;
michael@0 25269 i49 = i10 + 28 | 0;
michael@0 25270 HEAPF32[i49 >> 2] = d40;
michael@0 25271 i50 = i10 + 32 | 0;
michael@0 25272 HEAPF32[i50 >> 2] = d41;
michael@0 25273 HEAPF32[i10 + 36 >> 2] = 0.0;
michael@0 25274 i51 = i10 + 40 | 0;
michael@0 25275 HEAPF32[i51 >> 2] = d42;
michael@0 25276 i52 = i10 + 44 | 0;
michael@0 25277 HEAPF32[i52 >> 2] = d43;
michael@0 25278 i53 = i10 + 48 | 0;
michael@0 25279 HEAPF32[i53 >> 2] = d44;
michael@0 25280 HEAPF32[i10 + 52 >> 2] = 0.0;
michael@0 25281 i54 = i2 + 48 | 0;
michael@0 25282 d21 = +HEAPF32[i4 + 48 >> 2] - +HEAPF32[i54 >> 2];
michael@0 25283 i55 = i2 + 52 | 0;
michael@0 25284 d18 = +HEAPF32[i4 + 52 >> 2] - +HEAPF32[i55 >> 2];
michael@0 25285 i56 = i2 + 56 | 0;
michael@0 25286 d16 = +HEAPF32[i4 + 56 >> 2] - +HEAPF32[i56 >> 2];
michael@0 25287 i4 = i10 + 56 | 0;
michael@0 25288 HEAPF32[i4 >> 2] = d24;
michael@0 25289 i2 = i10 + 60 | 0;
michael@0 25290 HEAPF32[i2 >> 2] = d39;
michael@0 25291 i57 = i10 + 64 | 0;
michael@0 25292 HEAPF32[i57 >> 2] = d42;
michael@0 25293 HEAPF32[i10 + 68 >> 2] = 0.0;
michael@0 25294 i58 = i10 + 72 | 0;
michael@0 25295 HEAPF32[i58 >> 2] = d31;
michael@0 25296 i59 = i10 + 76 | 0;
michael@0 25297 HEAPF32[i59 >> 2] = d40;
michael@0 25298 i60 = i10 + 80 | 0;
michael@0 25299 HEAPF32[i60 >> 2] = d43;
michael@0 25300 HEAPF32[i10 + 84 >> 2] = 0.0;
michael@0 25301 i61 = i10 + 88 | 0;
michael@0 25302 HEAPF32[i61 >> 2] = d38;
michael@0 25303 i62 = i10 + 92 | 0;
michael@0 25304 HEAPF32[i62 >> 2] = d41;
michael@0 25305 i63 = i10 + 96 | 0;
michael@0 25306 HEAPF32[i63 >> 2] = d44;
michael@0 25307 HEAPF32[i10 + 100 >> 2] = 0.0;
michael@0 25308 i64 = i10 + 104 | 0;
michael@0 25309 HEAPF32[i64 >> 2] = d17 * d21 + d20 * d18 + d23 * d16;
michael@0 25310 i65 = i10 + 108 | 0;
michael@0 25311 HEAPF32[i65 >> 2] = d26 * d21 + d28 * d18 + d30 * d16;
michael@0 25312 i66 = i10 + 112 | 0;
michael@0 25313 HEAPF32[i66 >> 2] = d33 * d21 + d35 * d18 + d37 * d16;
michael@0 25314 HEAPF32[i10 + 116 >> 2] = 0.0;
michael@0 25315 i67 = i10 + 120 | 0;
michael@0 25316 HEAP32[i67 >> 2] = 82;
michael@0 25317 i68 = i10 + 124 | 0;
michael@0 25318 HEAP32[i68 >> 2] = 0;
michael@0 25319 HEAP32[i11 + 364 >> 2] = 0;
michael@0 25320 _memset(i11 + 128 | 0, 0, 16);
michael@0 25321 HEAP32[i11 + 376 >> 2] = 2;
michael@0 25322 HEAP32[i11 + 368 >> 2] = 0;
michael@0 25323 HEAPF32[i11 + 144 >> 2] = 0.0;
michael@0 25324 i69 = __ZN12gjkepa2_impl3GJK8EvaluateERKNS_13MinkowskiDiffERK9btVector3(i11, i10, i5) | 0;
michael@0 25325 if ((i69 | 0) != 0) {
michael@0 25326 HEAP32[i13 >> 2] = (i69 | 0) == 1 ? 1 : 2;
michael@0 25327 i70 = 0;
michael@0 25328 STACKTOP = i7;
michael@0 25329 return i70 | 0;
michael@0 25330 }
michael@0 25331 i69 = i11 + 372 | 0;
michael@0 25332 i11 = HEAP32[i69 >> 2] | 0;
michael@0 25333 if ((HEAP32[i11 + 32 >> 2] | 0) == 0) {
michael@0 25334 d71 = 0.0;
michael@0 25335 d72 = 0.0;
michael@0 25336 d73 = 0.0;
michael@0 25337 d74 = 0.0;
michael@0 25338 d75 = 0.0;
michael@0 25339 d76 = 0.0;
michael@0 25340 } else {
michael@0 25341 i13 = i12 | 0;
michael@0 25342 i5 = i12 + 4 | 0;
michael@0 25343 i10 = i12 + 8 | 0;
michael@0 25344 i77 = i9 | 0;
michael@0 25345 i78 = i9 + 4 | 0;
michael@0 25346 i79 = i9 + 8 | 0;
michael@0 25347 i80 = i9 + 12 | 0;
michael@0 25348 i81 = i8 | 0;
michael@0 25349 i82 = i8 + 4 | 0;
michael@0 25350 i83 = i8 + 8 | 0;
michael@0 25351 d16 = 0.0;
michael@0 25352 d37 = 0.0;
michael@0 25353 d18 = 0.0;
michael@0 25354 d35 = 0.0;
michael@0 25355 d21 = 0.0;
michael@0 25356 d33 = 0.0;
michael@0 25357 i84 = 0;
michael@0 25358 i85 = i11;
michael@0 25359 while (1) {
michael@0 25360 d30 = +HEAPF32[i85 + 16 + (i84 << 2) >> 2];
michael@0 25361 i11 = HEAP32[i67 >> 2] | 0;
michael@0 25362 i86 = (HEAP32[i15 >> 2] | 0) + (HEAP32[i68 >> 2] | 0) | 0;
michael@0 25363 if ((i11 & 1 | 0) == 0) {
michael@0 25364 i87 = i11;
michael@0 25365 } else {
michael@0 25366 i87 = HEAP32[(HEAP32[i86 >> 2] | 0) + (i11 - 1) >> 2] | 0;
michael@0 25367 }
michael@0 25368 FUNCTION_TABLE_viii[i87 & 127](i12, i86, HEAP32[i85 + (i84 << 2) >> 2] | 0);
michael@0 25369 d28 = d18 + d30 * +HEAPF32[i13 >> 2];
michael@0 25370 d26 = d37 + d30 * +HEAPF32[i5 >> 2];
michael@0 25371 d23 = d16 + d30 * +HEAPF32[i10 >> 2];
michael@0 25372 i86 = HEAP32[(HEAP32[i69 >> 2] | 0) + (i84 << 2) >> 2] | 0;
michael@0 25373 d20 = -0.0 - +HEAPF32[i86 >> 2];
michael@0 25374 d17 = -0.0 - +HEAPF32[i86 + 4 >> 2];
michael@0 25375 d44 = -0.0 - +HEAPF32[i86 + 8 >> 2];
michael@0 25376 i86 = HEAP32[i67 >> 2] | 0;
michael@0 25377 i11 = (HEAP32[i1 >> 2] | 0) + (HEAP32[i68 >> 2] | 0) | 0;
michael@0 25378 if ((i86 & 1 | 0) == 0) {
michael@0 25379 i88 = i86;
michael@0 25380 } else {
michael@0 25381 i88 = HEAP32[(HEAP32[i11 >> 2] | 0) + (i86 - 1) >> 2] | 0;
michael@0 25382 }
michael@0 25383 d41 = +HEAPF32[i48 >> 2] * d20 + +HEAPF32[i49 >> 2] * d17 + +HEAPF32[i50 >> 2] * d44;
michael@0 25384 d38 = +HEAPF32[i51 >> 2] * d20 + +HEAPF32[i52 >> 2] * d17 + +HEAPF32[i53 >> 2] * d44;
michael@0 25385 HEAPF32[i77 >> 2] = +HEAPF32[i45 >> 2] * d20 + +HEAPF32[i46 >> 2] * d17 + +HEAPF32[i47 >> 2] * d44;
michael@0 25386 HEAPF32[i78 >> 2] = d41;
michael@0 25387 HEAPF32[i79 >> 2] = d38;
michael@0 25388 HEAPF32[i80 >> 2] = 0.0;
michael@0 25389 FUNCTION_TABLE_viii[i88 & 127](i8, i11, i9);
michael@0 25390 d38 = +HEAPF32[i81 >> 2];
michael@0 25391 d41 = +HEAPF32[i82 >> 2];
michael@0 25392 d44 = +HEAPF32[i83 >> 2];
michael@0 25393 d17 = d33 + d30 * (+HEAPF32[i64 >> 2] + (+HEAPF32[i4 >> 2] * d38 + +HEAPF32[i2 >> 2] * d41 + +HEAPF32[i57 >> 2] * d44));
michael@0 25394 d20 = d21 + d30 * (+HEAPF32[i65 >> 2] + (d38 * +HEAPF32[i58 >> 2] + d41 * +HEAPF32[i59 >> 2] + d44 * +HEAPF32[i60 >> 2]));
michael@0 25395 d43 = d35 + d30 * (+HEAPF32[i66 >> 2] + (d38 * +HEAPF32[i61 >> 2] + d41 * +HEAPF32[i62 >> 2] + d44 * +HEAPF32[i63 >> 2]));
michael@0 25396 i11 = i84 + 1 | 0;
michael@0 25397 i86 = HEAP32[i69 >> 2] | 0;
michael@0 25398 if (i11 >>> 0 < (HEAP32[i86 + 32 >> 2] | 0) >>> 0) {
michael@0 25399 d16 = d23;
michael@0 25400 d37 = d26;
michael@0 25401 d18 = d28;
michael@0 25402 d35 = d43;
michael@0 25403 d21 = d20;
michael@0 25404 d33 = d17;
michael@0 25405 i84 = i11;
michael@0 25406 i85 = i86;
michael@0 25407 } else {
michael@0 25408 d71 = d23;
michael@0 25409 d72 = d26;
michael@0 25410 d73 = d28;
michael@0 25411 d74 = d43;
michael@0 25412 d75 = d20;
michael@0 25413 d76 = d17;
michael@0 25414 break;
michael@0 25415 }
michael@0 25416 }
michael@0 25417 }
michael@0 25418 d33 = +HEAPF32[i55 >> 2] + (d73 * +HEAPF32[i19 >> 2] + d72 * +HEAPF32[i27 >> 2] + d71 * +HEAPF32[i34 >> 2]);
michael@0 25419 d21 = +HEAPF32[i56 >> 2] + (d73 * +HEAPF32[i22 >> 2] + d72 * +HEAPF32[i29 >> 2] + d71 * +HEAPF32[i36 >> 2]);
michael@0 25420 HEAPF32[i6 + 4 >> 2] = +HEAPF32[i54 >> 2] + (d73 * +HEAPF32[i3 >> 2] + d72 * +HEAPF32[i25 >> 2] + d71 * +HEAPF32[i32 >> 2]);
michael@0 25421 HEAPF32[i6 + 8 >> 2] = d33;
michael@0 25422 HEAPF32[i6 + 12 >> 2] = d21;
michael@0 25423 HEAPF32[i6 + 16 >> 2] = 0.0;
michael@0 25424 d21 = +HEAPF32[i55 >> 2] + (d76 * +HEAPF32[i19 >> 2] + d75 * +HEAPF32[i27 >> 2] + d74 * +HEAPF32[i34 >> 2]);
michael@0 25425 d33 = +HEAPF32[i56 >> 2] + (d76 * +HEAPF32[i22 >> 2] + d75 * +HEAPF32[i29 >> 2] + d74 * +HEAPF32[i36 >> 2]);
michael@0 25426 HEAPF32[i14 >> 2] = +HEAPF32[i54 >> 2] + (d76 * +HEAPF32[i3 >> 2] + d75 * +HEAPF32[i25 >> 2] + d74 * +HEAPF32[i32 >> 2]);
michael@0 25427 HEAPF32[i6 + 24 >> 2] = d21;
michael@0 25428 HEAPF32[i6 + 28 >> 2] = d33;
michael@0 25429 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 25430 d33 = d73 - d76;
michael@0 25431 d76 = d72 - d75;
michael@0 25432 d75 = d71 - d74;
michael@0 25433 HEAPF32[i6 + 48 >> 2] = 0.0;
michael@0 25434 d74 = +Math_sqrt(+(d33 * d33 + d76 * d76 + d75 * d75));
michael@0 25435 HEAPF32[i6 + 52 >> 2] = d74;
michael@0 25436 d71 = 1.0 / (d74 > 9999999747378752.0e-20 ? d74 : 1.0);
michael@0 25437 HEAPF32[i6 + 36 >> 2] = d33 * d71;
michael@0 25438 HEAPF32[i6 + 40 >> 2] = d76 * d71;
michael@0 25439 HEAPF32[i6 + 44 >> 2] = d75 * d71;
michael@0 25440 i70 = 1;
michael@0 25441 STACKTOP = i7;
michael@0 25442 return i70 | 0;
michael@0 25443 }
michael@0 25444 function __ZN27btPolyhedralContactClipping18findSeparatingAxisERK18btConvexPolyhedronS2_RK11btTransformS5_R9btVector3(i1, i2, i3, i4, i5) {
michael@0 25445 i1 = i1 | 0;
michael@0 25446 i2 = i2 | 0;
michael@0 25447 i3 = i3 | 0;
michael@0 25448 i4 = i4 | 0;
michael@0 25449 i5 = i5 | 0;
michael@0 25450 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, d30 = 0.0, i31 = 0, i32 = 0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, i38 = 0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, d54 = 0.0, d55 = 0.0, i56 = 0, d57 = 0.0, i58 = 0, d59 = 0.0, i60 = 0, i61 = 0;
michael@0 25451 i6 = STACKTOP;
michael@0 25452 STACKTOP = STACKTOP + 72 | 0;
michael@0 25453 i7 = i6 | 0;
michael@0 25454 i8 = i6 + 16 | 0;
michael@0 25455 i9 = i6 + 24 | 0;
michael@0 25456 i10 = i6 + 40 | 0;
michael@0 25457 i11 = i6 + 48 | 0;
michael@0 25458 i12 = i6 + 64 | 0;
michael@0 25459 HEAP32[3576] = (HEAP32[3576] | 0) + 1;
michael@0 25460 i13 = HEAP32[i1 + 28 >> 2] | 0;
michael@0 25461 L433 : do {
michael@0 25462 if ((i13 | 0) > 0) {
michael@0 25463 i14 = i1 + 36 | 0;
michael@0 25464 i15 = i3 | 0;
michael@0 25465 i16 = i3 + 4 | 0;
michael@0 25466 i17 = i3 + 8 | 0;
michael@0 25467 i18 = i3 + 16 | 0;
michael@0 25468 i19 = i3 + 20 | 0;
michael@0 25469 i20 = i3 + 24 | 0;
michael@0 25470 i21 = i3 + 32 | 0;
michael@0 25471 i22 = i3 + 36 | 0;
michael@0 25472 i23 = i3 + 40 | 0;
michael@0 25473 i24 = i7 | 0;
michael@0 25474 i25 = i7 + 4 | 0;
michael@0 25475 i26 = i7 + 8 | 0;
michael@0 25476 i27 = i7 + 12 | 0;
michael@0 25477 i28 = i5;
michael@0 25478 i29 = i7;
michael@0 25479 d30 = 3.4028234663852886e+38;
michael@0 25480 i31 = 0;
michael@0 25481 while (1) {
michael@0 25482 i32 = HEAP32[i14 >> 2] | 0;
michael@0 25483 d33 = +HEAPF32[i32 + (i31 * 56 | 0) + 40 >> 2];
michael@0 25484 d34 = +HEAPF32[i32 + (i31 * 56 | 0) + 44 >> 2];
michael@0 25485 d35 = +HEAPF32[i32 + (i31 * 56 | 0) + 48 >> 2];
michael@0 25486 d36 = d33 * +HEAPF32[i18 >> 2] + d34 * +HEAPF32[i19 >> 2] + d35 * +HEAPF32[i20 >> 2];
michael@0 25487 d37 = d33 * +HEAPF32[i21 >> 2] + d34 * +HEAPF32[i22 >> 2] + d35 * +HEAPF32[i23 >> 2];
michael@0 25488 HEAPF32[i24 >> 2] = d33 * +HEAPF32[i15 >> 2] + d34 * +HEAPF32[i16 >> 2] + d35 * +HEAPF32[i17 >> 2];
michael@0 25489 HEAPF32[i25 >> 2] = d36;
michael@0 25490 HEAPF32[i26 >> 2] = d37;
michael@0 25491 HEAPF32[i27 >> 2] = 0.0;
michael@0 25492 if (!(__ZL11TestSepAxisRK18btConvexPolyhedronS1_RK11btTransformS4_RK9btVector3Rf(i1, i2, i3, i4, i7, i8) | 0)) {
michael@0 25493 i38 = 0;
michael@0 25494 break;
michael@0 25495 }
michael@0 25496 d37 = +HEAPF32[i8 >> 2];
michael@0 25497 if (d37 < d30) {
michael@0 25498 HEAP32[i28 >> 2] = HEAP32[i29 >> 2];
michael@0 25499 HEAP32[i28 + 4 >> 2] = HEAP32[i29 + 4 >> 2];
michael@0 25500 HEAP32[i28 + 8 >> 2] = HEAP32[i29 + 8 >> 2];
michael@0 25501 HEAP32[i28 + 12 >> 2] = HEAP32[i29 + 12 >> 2];
michael@0 25502 d39 = d37;
michael@0 25503 } else {
michael@0 25504 d39 = d30;
michael@0 25505 }
michael@0 25506 i32 = i31 + 1 | 0;
michael@0 25507 if ((i32 | 0) < (i13 | 0)) {
michael@0 25508 d30 = d39;
michael@0 25509 i31 = i32;
michael@0 25510 } else {
michael@0 25511 d40 = d39;
michael@0 25512 break L433;
michael@0 25513 }
michael@0 25514 }
michael@0 25515 STACKTOP = i6;
michael@0 25516 return i38 | 0;
michael@0 25517 } else {
michael@0 25518 d40 = 3.4028234663852886e+38;
michael@0 25519 }
michael@0 25520 } while (0);
michael@0 25521 i13 = HEAP32[i2 + 28 >> 2] | 0;
michael@0 25522 L443 : do {
michael@0 25523 if ((i13 | 0) > 0) {
michael@0 25524 i8 = i2 + 36 | 0;
michael@0 25525 i7 = i4 | 0;
michael@0 25526 i31 = i4 + 4 | 0;
michael@0 25527 i29 = i4 + 8 | 0;
michael@0 25528 i28 = i4 + 16 | 0;
michael@0 25529 i27 = i4 + 20 | 0;
michael@0 25530 i26 = i4 + 24 | 0;
michael@0 25531 i25 = i4 + 32 | 0;
michael@0 25532 i17 = i4 + 36 | 0;
michael@0 25533 i16 = i4 + 40 | 0;
michael@0 25534 i15 = i9 | 0;
michael@0 25535 i24 = i9 + 4 | 0;
michael@0 25536 i23 = i9 + 8 | 0;
michael@0 25537 i22 = i9 + 12 | 0;
michael@0 25538 i21 = i5;
michael@0 25539 i20 = i9;
michael@0 25540 d39 = d40;
michael@0 25541 i19 = 0;
michael@0 25542 while (1) {
michael@0 25543 i18 = HEAP32[i8 >> 2] | 0;
michael@0 25544 d30 = +HEAPF32[i18 + (i19 * 56 | 0) + 40 >> 2];
michael@0 25545 d37 = +HEAPF32[i18 + (i19 * 56 | 0) + 44 >> 2];
michael@0 25546 d36 = +HEAPF32[i18 + (i19 * 56 | 0) + 48 >> 2];
michael@0 25547 d35 = d30 * +HEAPF32[i28 >> 2] + d37 * +HEAPF32[i27 >> 2] + d36 * +HEAPF32[i26 >> 2];
michael@0 25548 d34 = d30 * +HEAPF32[i25 >> 2] + d37 * +HEAPF32[i17 >> 2] + d36 * +HEAPF32[i16 >> 2];
michael@0 25549 HEAPF32[i15 >> 2] = d30 * +HEAPF32[i7 >> 2] + d37 * +HEAPF32[i31 >> 2] + d36 * +HEAPF32[i29 >> 2];
michael@0 25550 HEAPF32[i24 >> 2] = d35;
michael@0 25551 HEAPF32[i23 >> 2] = d34;
michael@0 25552 HEAPF32[i22 >> 2] = 0.0;
michael@0 25553 if (!(__ZL11TestSepAxisRK18btConvexPolyhedronS1_RK11btTransformS4_RK9btVector3Rf(i1, i2, i3, i4, i9, i10) | 0)) {
michael@0 25554 i38 = 0;
michael@0 25555 break;
michael@0 25556 }
michael@0 25557 d34 = +HEAPF32[i10 >> 2];
michael@0 25558 if (d34 < d39) {
michael@0 25559 HEAP32[i21 >> 2] = HEAP32[i20 >> 2];
michael@0 25560 HEAP32[i21 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 25561 HEAP32[i21 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 25562 HEAP32[i21 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 25563 d41 = d34;
michael@0 25564 } else {
michael@0 25565 d41 = d39;
michael@0 25566 }
michael@0 25567 i18 = i19 + 1 | 0;
michael@0 25568 if ((i18 | 0) < (i13 | 0)) {
michael@0 25569 d39 = d41;
michael@0 25570 i19 = i18;
michael@0 25571 } else {
michael@0 25572 d42 = d41;
michael@0 25573 break L443;
michael@0 25574 }
michael@0 25575 }
michael@0 25576 STACKTOP = i6;
michael@0 25577 return i38 | 0;
michael@0 25578 } else {
michael@0 25579 d42 = d40;
michael@0 25580 }
michael@0 25581 } while (0);
michael@0 25582 i13 = i1 + 48 | 0;
michael@0 25583 i10 = HEAP32[i13 >> 2] | 0;
michael@0 25584 L453 : do {
michael@0 25585 if ((i10 | 0) > 0) {
michael@0 25586 i9 = i1 + 56 | 0;
michael@0 25587 i19 = i3 | 0;
michael@0 25588 i20 = i3 + 4 | 0;
michael@0 25589 i21 = i3 + 8 | 0;
michael@0 25590 i22 = i3 + 16 | 0;
michael@0 25591 i23 = i3 + 20 | 0;
michael@0 25592 i24 = i3 + 24 | 0;
michael@0 25593 i29 = i3 + 32 | 0;
michael@0 25594 i31 = i3 + 36 | 0;
michael@0 25595 i7 = i3 + 40 | 0;
michael@0 25596 i15 = i2 + 48 | 0;
michael@0 25597 i16 = i2 + 56 | 0;
michael@0 25598 i17 = i4 | 0;
michael@0 25599 i25 = i4 + 4 | 0;
michael@0 25600 i26 = i4 + 8 | 0;
michael@0 25601 i27 = i4 + 16 | 0;
michael@0 25602 i28 = i4 + 20 | 0;
michael@0 25603 i8 = i4 + 24 | 0;
michael@0 25604 i18 = i4 + 32 | 0;
michael@0 25605 i14 = i4 + 36 | 0;
michael@0 25606 i32 = i4 + 40 | 0;
michael@0 25607 i43 = i11 | 0;
michael@0 25608 i44 = i11 + 4 | 0;
michael@0 25609 i45 = i11 + 8 | 0;
michael@0 25610 i46 = i11 + 12 | 0;
michael@0 25611 i47 = i11;
michael@0 25612 i48 = i5;
michael@0 25613 d40 = d42;
michael@0 25614 i49 = 0;
michael@0 25615 i50 = HEAP32[i15 >> 2] | 0;
michael@0 25616 i51 = i10;
michael@0 25617 L455 : while (1) {
michael@0 25618 i52 = HEAP32[i9 >> 2] | 0;
michael@0 25619 d41 = +HEAPF32[i52 + (i49 << 4) >> 2];
michael@0 25620 d39 = +HEAPF32[i52 + (i49 << 4) + 4 >> 2];
michael@0 25621 d34 = +HEAPF32[i52 + (i49 << 4) + 8 >> 2];
michael@0 25622 d35 = d41 * +HEAPF32[i19 >> 2] + d39 * +HEAPF32[i20 >> 2] + d34 * +HEAPF32[i21 >> 2];
michael@0 25623 d36 = d41 * +HEAPF32[i22 >> 2] + d39 * +HEAPF32[i23 >> 2] + d34 * +HEAPF32[i24 >> 2];
michael@0 25624 d37 = d41 * +HEAPF32[i29 >> 2] + d39 * +HEAPF32[i31 >> 2] + d34 * +HEAPF32[i7 >> 2];
michael@0 25625 if ((i50 | 0) > 0) {
michael@0 25626 d34 = d40;
michael@0 25627 i52 = 0;
michael@0 25628 while (1) {
michael@0 25629 i53 = HEAP32[i16 >> 2] | 0;
michael@0 25630 d39 = +HEAPF32[i53 + (i52 << 4) >> 2];
michael@0 25631 d41 = +HEAPF32[i53 + (i52 << 4) + 4 >> 2];
michael@0 25632 d30 = +HEAPF32[i53 + (i52 << 4) + 8 >> 2];
michael@0 25633 d33 = d39 * +HEAPF32[i17 >> 2] + d41 * +HEAPF32[i25 >> 2] + d30 * +HEAPF32[i26 >> 2];
michael@0 25634 d54 = d39 * +HEAPF32[i27 >> 2] + d41 * +HEAPF32[i28 >> 2] + d30 * +HEAPF32[i8 >> 2];
michael@0 25635 d55 = d39 * +HEAPF32[i18 >> 2] + d41 * +HEAPF32[i14 >> 2] + d30 * +HEAPF32[i32 >> 2];
michael@0 25636 d30 = d36 * d55 - d37 * d54;
michael@0 25637 d41 = d37 * d33 - d35 * d55;
michael@0 25638 d55 = d35 * d54 - d36 * d33;
michael@0 25639 HEAPF32[i43 >> 2] = d30;
michael@0 25640 HEAPF32[i44 >> 2] = d41;
michael@0 25641 HEAPF32[i45 >> 2] = d55;
michael@0 25642 HEAPF32[i46 >> 2] = 0.0;
michael@0 25643 do {
michael@0 25644 if (+Math_abs(+d30) > 1.0e-6) {
michael@0 25645 i56 = 339;
michael@0 25646 } else {
michael@0 25647 if (+Math_abs(+d41) > 1.0e-6) {
michael@0 25648 i56 = 339;
michael@0 25649 break;
michael@0 25650 }
michael@0 25651 if (+Math_abs(+d55) > 1.0e-6) {
michael@0 25652 i56 = 339;
michael@0 25653 } else {
michael@0 25654 d57 = d34;
michael@0 25655 }
michael@0 25656 }
michael@0 25657 } while (0);
michael@0 25658 do {
michael@0 25659 if ((i56 | 0) == 339) {
michael@0 25660 i56 = 0;
michael@0 25661 d33 = 1.0 / +Math_sqrt(+(d55 * d55 + (d30 * d30 + d41 * d41)));
michael@0 25662 HEAPF32[i43 >> 2] = d30 * d33;
michael@0 25663 HEAPF32[i44 >> 2] = d41 * d33;
michael@0 25664 HEAPF32[i45 >> 2] = d55 * d33;
michael@0 25665 if (!(__ZL11TestSepAxisRK18btConvexPolyhedronS1_RK11btTransformS4_RK9btVector3Rf(i1, i2, i3, i4, i11, i12) | 0)) {
michael@0 25666 i38 = 0;
michael@0 25667 break L455;
michael@0 25668 }
michael@0 25669 d33 = +HEAPF32[i12 >> 2];
michael@0 25670 if (d33 >= d34) {
michael@0 25671 d57 = d34;
michael@0 25672 break;
michael@0 25673 }
michael@0 25674 HEAP32[i48 >> 2] = HEAP32[i47 >> 2];
michael@0 25675 HEAP32[i48 + 4 >> 2] = HEAP32[i47 + 4 >> 2];
michael@0 25676 HEAP32[i48 + 8 >> 2] = HEAP32[i47 + 8 >> 2];
michael@0 25677 HEAP32[i48 + 12 >> 2] = HEAP32[i47 + 12 >> 2];
michael@0 25678 d57 = d33;
michael@0 25679 }
michael@0 25680 } while (0);
michael@0 25681 i53 = i52 + 1 | 0;
michael@0 25682 i58 = HEAP32[i15 >> 2] | 0;
michael@0 25683 if ((i53 | 0) < (i58 | 0)) {
michael@0 25684 d34 = d57;
michael@0 25685 i52 = i53;
michael@0 25686 } else {
michael@0 25687 break;
michael@0 25688 }
michael@0 25689 }
michael@0 25690 d59 = d57;
michael@0 25691 i60 = i58;
michael@0 25692 i61 = HEAP32[i13 >> 2] | 0;
michael@0 25693 } else {
michael@0 25694 d59 = d40;
michael@0 25695 i60 = i50;
michael@0 25696 i61 = i51;
michael@0 25697 }
michael@0 25698 i52 = i49 + 1 | 0;
michael@0 25699 if ((i52 | 0) < (i61 | 0)) {
michael@0 25700 d40 = d59;
michael@0 25701 i49 = i52;
michael@0 25702 i50 = i60;
michael@0 25703 i51 = i61;
michael@0 25704 } else {
michael@0 25705 break L453;
michael@0 25706 }
michael@0 25707 }
michael@0 25708 STACKTOP = i6;
michael@0 25709 return i38 | 0;
michael@0 25710 }
michael@0 25711 } while (0);
michael@0 25712 i61 = i5 | 0;
michael@0 25713 d59 = +HEAPF32[i61 >> 2];
michael@0 25714 i60 = i5 + 4 | 0;
michael@0 25715 d57 = +HEAPF32[i60 >> 2];
michael@0 25716 i13 = i5 + 8 | 0;
michael@0 25717 d42 = +HEAPF32[i13 >> 2];
michael@0 25718 if ((+HEAPF32[i4 + 48 >> 2] - +HEAPF32[i3 + 48 >> 2]) * d59 + (+HEAPF32[i4 + 52 >> 2] - +HEAPF32[i3 + 52 >> 2]) * d57 + (+HEAPF32[i4 + 56 >> 2] - +HEAPF32[i3 + 56 >> 2]) * d42 <= 0.0) {
michael@0 25719 i38 = 1;
michael@0 25720 STACKTOP = i6;
michael@0 25721 return i38 | 0;
michael@0 25722 }
michael@0 25723 HEAPF32[i61 >> 2] = -0.0 - d59;
michael@0 25724 HEAPF32[i60 >> 2] = -0.0 - d57;
michael@0 25725 HEAPF32[i13 >> 2] = -0.0 - d42;
michael@0 25726 HEAPF32[i5 + 12 >> 2] = 0.0;
michael@0 25727 i38 = 1;
michael@0 25728 STACKTOP = i6;
michael@0 25729 return i38 | 0;
michael@0 25730 }
michael@0 25731 function runPostSets() {
michael@0 25732 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 8 >> 2] = 6;
michael@0 25733 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 12 >> 2] = 192;
michael@0 25734 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 16 >> 2] = 74;
michael@0 25735 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 20 >> 2] = 214;
michael@0 25736 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 24 >> 2] = 4;
michael@0 25737 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 28 >> 2] = 4;
michael@0 25738 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 32 >> 2] = 10;
michael@0 25739 HEAP32[__ZTVN10__cxxabiv120__si_class_type_infoE + 36 >> 2] = 22;
michael@0 25740 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 8 >> 2] = 6;
michael@0 25741 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 12 >> 2] = 348;
michael@0 25742 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 16 >> 2] = 74;
michael@0 25743 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 20 >> 2] = 214;
michael@0 25744 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 24 >> 2] = 4;
michael@0 25745 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 28 >> 2] = 10;
michael@0 25746 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 32 >> 2] = 8;
michael@0 25747 HEAP32[__ZTVN10__cxxabiv117__class_type_infoE + 36 >> 2] = 42;
michael@0 25748 HEAP32[2584] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25749 HEAP32[2588] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25750 HEAP32[2592] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25751 HEAP32[2596] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25752 HEAP32[2600] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25753 HEAP32[2604] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25754 HEAP32[2608] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25755 HEAP32[2612] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25756 HEAP32[2616] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25757 HEAP32[2620] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25758 HEAP32[2624] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25759 HEAP32[2628] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25760 HEAP32[2632] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25761 HEAP32[2636] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25762 HEAP32[2640] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25763 HEAP32[2644] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25764 HEAP32[2646] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25765 HEAP32[2648] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25766 HEAP32[2652] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25767 HEAP32[2654] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25768 HEAP32[2656] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25769 HEAP32[2660] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25770 HEAP32[2664] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25771 HEAP32[2668] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25772 HEAP32[2672] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25773 HEAP32[2676] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25774 HEAP32[2680] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25775 HEAP32[2684] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25776 HEAP32[2688] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25777 HEAP32[2690] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25778 HEAP32[2694] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25779 HEAP32[2698] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25780 HEAP32[2702] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25781 HEAP32[2704] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25782 HEAP32[2706] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25783 HEAP32[2708] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25784 HEAP32[2712] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25785 HEAP32[2716] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25786 HEAP32[2720] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25787 HEAP32[2724] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25788 HEAP32[2726] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25789 HEAP32[2730] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25790 HEAP32[2734] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25791 HEAP32[2738] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25792 HEAP32[2742] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25793 HEAP32[2746] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25794 HEAP32[2750] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25795 HEAP32[2752] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25796 HEAP32[2756] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25797 HEAP32[2760] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25798 HEAP32[2764] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25799 HEAP32[2766] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25800 HEAP32[2768] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25801 HEAP32[2772] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25802 HEAP32[2776] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25803 HEAP32[2780] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25804 HEAP32[2784] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25805 HEAP32[2788] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25806 HEAP32[2792] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25807 HEAP32[2796] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25808 HEAP32[2798] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25809 HEAP32[2800] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25810 HEAP32[2804] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25811 HEAP32[2808] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25812 HEAP32[2810] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25813 HEAP32[2812] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25814 HEAP32[2816] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25815 HEAP32[2820] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25816 HEAP32[2824] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25817 HEAP32[2828] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25818 HEAP32[2832] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25819 HEAP32[2836] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25820 HEAP32[2840] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25821 HEAP32[2844] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25822 HEAP32[2848] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25823 HEAP32[2852] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25824 HEAP32[2854] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25825 HEAP32[2858] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25826 HEAP32[2862] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25827 HEAP32[2864] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25828 HEAP32[2868] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25829 HEAP32[2870] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25830 HEAP32[2874] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25831 HEAP32[2878] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25832 HEAP32[2882] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25833 HEAP32[2884] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25834 HEAP32[2888] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25835 HEAP32[2890] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25836 HEAP32[2892] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25837 HEAP32[2894] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25838 HEAP32[2898] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25839 HEAP32[2908] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25840 HEAP32[2912] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25841 HEAP32[2916] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25842 HEAP32[2920] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25843 HEAP32[2924] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25844 HEAP32[2926] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25845 HEAP32[2928] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25846 HEAP32[2932] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25847 HEAP32[2936] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25848 HEAP32[2940] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25849 HEAP32[2944] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25850 HEAP32[2948] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25851 HEAP32[2950] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25852 HEAP32[2954] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25853 HEAP32[2956] = __ZTVN10__cxxabiv117__class_type_infoE + 8;
michael@0 25854 HEAP32[2958] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25855 HEAP32[2962] = __ZTVN10__cxxabiv120__si_class_type_infoE + 8;
michael@0 25856 }
michael@0 25857 function __ZN27btPolyhedralContactClipping19clipFaceAgainstHullERK9btVector3RK18btConvexPolyhedronRK11btTransformR20btAlignedObjectArrayIS0_EffRN36btDiscreteCollisionDetectorInterface6ResultE(i1, i2, i3, i4, d5, d6, i7) {
michael@0 25858 i1 = i1 | 0;
michael@0 25859 i2 = i2 | 0;
michael@0 25860 i3 = i3 | 0;
michael@0 25861 i4 = i4 | 0;
michael@0 25862 d5 = +d5;
michael@0 25863 d6 = +d6;
michael@0 25864 i7 = i7 | 0;
michael@0 25865 var i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, d20 = 0.0, i21 = 0, d22 = 0.0, i23 = 0, d24 = 0.0, i25 = 0, d26 = 0.0, i27 = 0, d28 = 0.0, i29 = 0, d30 = 0.0, i31 = 0, d32 = 0.0, i33 = 0, d34 = 0.0, i35 = 0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, i40 = 0, d41 = 0.0, i42 = 0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, d61 = 0.0, i62 = 0, d63 = 0.0, d64 = 0.0, d65 = 0.0, d66 = 0.0, d67 = 0.0, d68 = 0.0, d69 = 0.0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0, i79 = 0, d80 = 0.0, d81 = 0.0, d82 = 0.0, d83 = 0.0, d84 = 0.0, d85 = 0.0, d86 = 0.0, d87 = 0.0, d88 = 0.0, i89 = 0;
michael@0 25866 i8 = STACKTOP;
michael@0 25867 STACKTOP = STACKTOP + 72 | 0;
michael@0 25868 i9 = i8 | 0;
michael@0 25869 i10 = i8 + 24 | 0;
michael@0 25870 i11 = i8 + 40 | 0;
michael@0 25871 i12 = i8 + 56 | 0;
michael@0 25872 i13 = i9 + 16 | 0;
michael@0 25873 HEAP8[i13] = 1;
michael@0 25874 i14 = i9 + 12 | 0;
michael@0 25875 HEAP32[i14 >> 2] = 0;
michael@0 25876 HEAP32[i9 + 4 >> 2] = 0;
michael@0 25877 i15 = i9 + 8 | 0;
michael@0 25878 HEAP32[i15 >> 2] = 0;
michael@0 25879 i16 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 25880 if ((i16 | 0) > 0) {
michael@0 25881 i17 = __Z22btAlignedAllocInternalji(i16 << 4, 16) | 0;
michael@0 25882 HEAP8[i13] = 1;
michael@0 25883 HEAP32[i14 >> 2] = i17;
michael@0 25884 HEAP32[i15 >> 2] = i16;
michael@0 25885 i18 = i17;
michael@0 25886 } else {
michael@0 25887 i18 = 0;
michael@0 25888 }
michael@0 25889 i17 = HEAP32[i2 + 28 >> 2] | 0;
michael@0 25890 do {
michael@0 25891 if ((i17 | 0) > 0) {
michael@0 25892 i16 = i2 + 36 | 0;
michael@0 25893 i15 = HEAP32[i16 >> 2] | 0;
michael@0 25894 i19 = i3 | 0;
michael@0 25895 d20 = +HEAPF32[i19 >> 2];
michael@0 25896 i21 = i3 + 4 | 0;
michael@0 25897 d22 = +HEAPF32[i21 >> 2];
michael@0 25898 i23 = i3 + 8 | 0;
michael@0 25899 d24 = +HEAPF32[i23 >> 2];
michael@0 25900 i25 = i3 + 16 | 0;
michael@0 25901 d26 = +HEAPF32[i25 >> 2];
michael@0 25902 i27 = i3 + 20 | 0;
michael@0 25903 d28 = +HEAPF32[i27 >> 2];
michael@0 25904 i29 = i3 + 24 | 0;
michael@0 25905 d30 = +HEAPF32[i29 >> 2];
michael@0 25906 i31 = i3 + 32 | 0;
michael@0 25907 d32 = +HEAPF32[i31 >> 2];
michael@0 25908 i33 = i3 + 36 | 0;
michael@0 25909 d34 = +HEAPF32[i33 >> 2];
michael@0 25910 i35 = i3 + 40 | 0;
michael@0 25911 d36 = +HEAPF32[i35 >> 2];
michael@0 25912 d37 = +HEAPF32[i1 >> 2];
michael@0 25913 d38 = +HEAPF32[i1 + 4 >> 2];
michael@0 25914 d39 = +HEAPF32[i1 + 8 >> 2];
michael@0 25915 i40 = 0;
michael@0 25916 d41 = 3.4028234663852886e+38;
michael@0 25917 i42 = -1;
michael@0 25918 while (1) {
michael@0 25919 d43 = +HEAPF32[i15 + (i40 * 56 | 0) + 40 >> 2];
michael@0 25920 d44 = +HEAPF32[i15 + (i40 * 56 | 0) + 44 >> 2];
michael@0 25921 d45 = +HEAPF32[i15 + (i40 * 56 | 0) + 48 >> 2];
michael@0 25922 d46 = d39 * (d32 * d43 + d34 * d44 + d36 * d45) + (d37 * (d20 * d43 + d22 * d44 + d24 * d45) + d38 * (d26 * d43 + d28 * d44 + d30 * d45));
michael@0 25923 i47 = d46 < d41;
michael@0 25924 i48 = i47 ? i40 : i42;
michael@0 25925 i49 = i40 + 1 | 0;
michael@0 25926 if ((i49 | 0) < (i17 | 0)) {
michael@0 25927 i40 = i49;
michael@0 25928 d41 = i47 ? d46 : d41;
michael@0 25929 i42 = i48;
michael@0 25930 } else {
michael@0 25931 break;
michael@0 25932 }
michael@0 25933 }
michael@0 25934 if ((i48 | 0) < 0) {
michael@0 25935 i50 = i18;
michael@0 25936 break;
michael@0 25937 }
michael@0 25938 i42 = HEAP32[i15 + (i48 * 56 | 0) + 4 >> 2] | 0;
michael@0 25939 if ((i42 | 0) > 0) {
michael@0 25940 i40 = i15 + (i48 * 56 | 0) + 32 | 0;
michael@0 25941 i47 = i10 | 0;
michael@0 25942 i49 = i10 + 4 | 0;
michael@0 25943 i51 = i10 + 8 | 0;
michael@0 25944 i52 = i10 + 12 | 0;
michael@0 25945 i53 = i3 + 48 | 0;
michael@0 25946 i54 = i3 + 52 | 0;
michael@0 25947 i55 = i3 + 56 | 0;
michael@0 25948 i56 = i11;
michael@0 25949 i57 = i4;
michael@0 25950 i58 = i9;
michael@0 25951 i59 = 0;
michael@0 25952 i60 = i15;
michael@0 25953 d41 = d20;
michael@0 25954 d38 = d22;
michael@0 25955 d37 = d24;
michael@0 25956 d39 = d26;
michael@0 25957 d46 = d28;
michael@0 25958 d45 = d30;
michael@0 25959 d44 = d32;
michael@0 25960 d43 = d34;
michael@0 25961 d61 = d36;
michael@0 25962 while (1) {
michael@0 25963 i62 = HEAP32[(HEAP32[i40 >> 2] | 0) + (i59 << 2) >> 2] | 0;
michael@0 25964 d63 = +HEAPF32[i60 + (i62 * 56 | 0) + 40 >> 2];
michael@0 25965 d64 = +HEAPF32[i60 + (i62 * 56 | 0) + 44 >> 2];
michael@0 25966 d65 = +HEAPF32[i60 + (i62 * 56 | 0) + 48 >> 2];
michael@0 25967 d66 = +HEAPF32[i60 + (i62 * 56 | 0) + 52 >> 2];
michael@0 25968 d67 = d63 * d41 + d64 * d38 + d65 * d37;
michael@0 25969 d68 = d63 * d39 + d64 * d46 + d65 * d45;
michael@0 25970 d69 = d63 * d44 + d64 * d43 + d65 * d61;
michael@0 25971 HEAPF32[i47 >> 2] = d67;
michael@0 25972 HEAPF32[i49 >> 2] = d68;
michael@0 25973 HEAPF32[i51 >> 2] = d69;
michael@0 25974 HEAPF32[i52 >> 2] = 0.0;
michael@0 25975 __ZN27btPolyhedralContactClipping8clipFaceERK20btAlignedObjectArrayI9btVector3ERS2_RKS1_f(i57, i58, i10, d66 - (d67 * +HEAPF32[i53 >> 2] + d68 * +HEAPF32[i54 >> 2] + d69 * +HEAPF32[i55 >> 2]));
michael@0 25976 i62 = i57 + 4 | 0;
michael@0 25977 i70 = HEAP32[i62 >> 2] | 0;
michael@0 25978 if ((i70 | 0) < 0) {
michael@0 25979 i71 = i57 + 8 | 0;
michael@0 25980 i72 = i57 + 12 | 0;
michael@0 25981 if ((HEAP32[i71 >> 2] | 0) < 0) {
michael@0 25982 i73 = HEAP32[i72 >> 2] | 0;
michael@0 25983 i74 = i57 + 16 | 0;
michael@0 25984 if ((i73 | 0) != 0) {
michael@0 25985 if ((HEAP8[i74] | 0) != 0) {
michael@0 25986 __Z21btAlignedFreeInternalPv(i73);
michael@0 25987 }
michael@0 25988 HEAP32[i72 >> 2] = 0;
michael@0 25989 }
michael@0 25990 HEAP8[i74] = 1;
michael@0 25991 HEAP32[i72 >> 2] = 0;
michael@0 25992 HEAP32[i71 >> 2] = 0;
michael@0 25993 i75 = i70;
michael@0 25994 } else {
michael@0 25995 i75 = i70;
michael@0 25996 }
michael@0 25997 do {
michael@0 25998 i70 = (HEAP32[i72 >> 2] | 0) + (i75 << 4) | 0;
michael@0 25999 if ((i70 | 0) != 0) {
michael@0 26000 i71 = i70;
michael@0 26001 HEAP32[i71 >> 2] = HEAP32[i56 >> 2];
michael@0 26002 HEAP32[i71 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 26003 HEAP32[i71 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 26004 HEAP32[i71 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 26005 }
michael@0 26006 i75 = i75 + 1 | 0;
michael@0 26007 } while ((i75 | 0) < 0);
michael@0 26008 }
michael@0 26009 HEAP32[i62 >> 2] = 0;
michael@0 26010 i72 = i59 + 1 | 0;
michael@0 26011 if ((i72 | 0) >= (i42 | 0)) {
michael@0 26012 break;
michael@0 26013 }
michael@0 26014 i71 = i57;
michael@0 26015 i57 = i58;
michael@0 26016 i59 = i72;
michael@0 26017 i60 = HEAP32[i16 >> 2] | 0;
michael@0 26018 d41 = +HEAPF32[i19 >> 2];
michael@0 26019 d38 = +HEAPF32[i21 >> 2];
michael@0 26020 d37 = +HEAPF32[i23 >> 2];
michael@0 26021 d39 = +HEAPF32[i25 >> 2];
michael@0 26022 d46 = +HEAPF32[i27 >> 2];
michael@0 26023 d45 = +HEAPF32[i29 >> 2];
michael@0 26024 d44 = +HEAPF32[i31 >> 2];
michael@0 26025 d43 = +HEAPF32[i33 >> 2];
michael@0 26026 d61 = +HEAPF32[i35 >> 2];
michael@0 26027 i58 = i71;
michael@0 26028 }
michael@0 26029 i76 = i58;
michael@0 26030 i77 = i53;
michael@0 26031 i78 = i54;
michael@0 26032 i79 = i55;
michael@0 26033 d80 = +HEAPF32[i19 >> 2];
michael@0 26034 d81 = +HEAPF32[i21 >> 2];
michael@0 26035 d82 = +HEAPF32[i23 >> 2];
michael@0 26036 d83 = +HEAPF32[i25 >> 2];
michael@0 26037 d84 = +HEAPF32[i27 >> 2];
michael@0 26038 d85 = +HEAPF32[i29 >> 2];
michael@0 26039 d86 = +HEAPF32[i31 >> 2];
michael@0 26040 d87 = +HEAPF32[i33 >> 2];
michael@0 26041 d88 = +HEAPF32[i35 >> 2];
michael@0 26042 } else {
michael@0 26043 i76 = i4;
michael@0 26044 i77 = i3 + 48 | 0;
michael@0 26045 i78 = i3 + 52 | 0;
michael@0 26046 i79 = i3 + 56 | 0;
michael@0 26047 d80 = d20;
michael@0 26048 d81 = d22;
michael@0 26049 d82 = d24;
michael@0 26050 d83 = d26;
michael@0 26051 d84 = d28;
michael@0 26052 d85 = d30;
michael@0 26053 d86 = d32;
michael@0 26054 d87 = d34;
michael@0 26055 d88 = d36;
michael@0 26056 }
michael@0 26057 d61 = +HEAPF32[i15 + (i48 * 56 | 0) + 40 >> 2];
michael@0 26058 d43 = +HEAPF32[i15 + (i48 * 56 | 0) + 44 >> 2];
michael@0 26059 d44 = +HEAPF32[i15 + (i48 * 56 | 0) + 48 >> 2];
michael@0 26060 d45 = d61 * d80 + d43 * d81 + d44 * d82;
michael@0 26061 d46 = d61 * d83 + d43 * d84 + d44 * d85;
michael@0 26062 d39 = d61 * d86 + d43 * d87 + d44 * d88;
michael@0 26063 d44 = +HEAPF32[i15 + (i48 * 56 | 0) + 52 >> 2] - (d45 * +HEAPF32[i77 >> 2] + d46 * +HEAPF32[i78 >> 2] + d39 * +HEAPF32[i79 >> 2]);
michael@0 26064 i16 = i76 + 4 | 0;
michael@0 26065 i60 = HEAP32[i16 >> 2] | 0;
michael@0 26066 if ((i60 | 0) > 0) {
michael@0 26067 i59 = i76 + 12 | 0;
michael@0 26068 i57 = i12;
michael@0 26069 i42 = i7;
michael@0 26070 i56 = 0;
michael@0 26071 i52 = i60;
michael@0 26072 while (1) {
michael@0 26073 i60 = HEAP32[i59 >> 2] | 0;
michael@0 26074 i51 = i60 + (i56 << 4) | 0;
michael@0 26075 d43 = d44 + (d45 * +HEAPF32[i51 >> 2] + d46 * +HEAPF32[i60 + (i56 << 4) + 4 >> 2] + d39 * +HEAPF32[i60 + (i56 << 4) + 8 >> 2]);
michael@0 26076 if (d43 > d6 | d43 < d5) {
michael@0 26077 i89 = i52;
michael@0 26078 } else {
michael@0 26079 i60 = i51;
michael@0 26080 HEAP32[i57 >> 2] = HEAP32[i60 >> 2];
michael@0 26081 HEAP32[i57 + 4 >> 2] = HEAP32[i60 + 4 >> 2];
michael@0 26082 HEAP32[i57 + 8 >> 2] = HEAP32[i60 + 8 >> 2];
michael@0 26083 HEAP32[i57 + 12 >> 2] = HEAP32[i60 + 12 >> 2];
michael@0 26084 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i42 >> 2] | 0) + 16 >> 2] & 15](i7, i1, i12, d43);
michael@0 26085 i89 = HEAP32[i16 >> 2] | 0;
michael@0 26086 }
michael@0 26087 i60 = i56 + 1 | 0;
michael@0 26088 if ((i60 | 0) < (i89 | 0)) {
michael@0 26089 i56 = i60;
michael@0 26090 i52 = i89;
michael@0 26091 } else {
michael@0 26092 break;
michael@0 26093 }
michael@0 26094 }
michael@0 26095 }
michael@0 26096 i50 = HEAP32[i14 >> 2] | 0;
michael@0 26097 } else {
michael@0 26098 i50 = i18;
michael@0 26099 }
michael@0 26100 } while (0);
michael@0 26101 if ((i50 | 0) == 0) {
michael@0 26102 STACKTOP = i8;
michael@0 26103 return;
michael@0 26104 }
michael@0 26105 if ((HEAP8[i13] | 0) != 0) {
michael@0 26106 __Z21btAlignedFreeInternalPv(i50);
michael@0 26107 }
michael@0 26108 HEAP32[i14 >> 2] = 0;
michael@0 26109 STACKTOP = i8;
michael@0 26110 return;
michael@0 26111 }
michael@0 26112 function __ZNK13btConvexShape44localGetSupportVertexWithoutMarginNonVirtualERK9btVector3(i1, i2, i3) {
michael@0 26113 i1 = i1 | 0;
michael@0 26114 i2 = i2 | 0;
michael@0 26115 i3 = i3 | 0;
michael@0 26116 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, i15 = 0, d16 = 0.0, d17 = 0.0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, d22 = 0.0, d23 = 0.0, d24 = 0.0, i25 = 0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, i35 = 0;
michael@0 26117 i4 = STACKTOP;
michael@0 26118 STACKTOP = STACKTOP + 80 | 0;
michael@0 26119 i5 = i4 | 0;
michael@0 26120 i6 = i4 + 16 | 0;
michael@0 26121 i7 = i4 + 32 | 0;
michael@0 26122 i8 = i4 + 48 | 0;
michael@0 26123 i9 = i4 + 64 | 0;
michael@0 26124 switch (HEAP32[i2 + 4 >> 2] | 0) {
michael@0 26125 case 8:
michael@0 26126 {
michael@0 26127 _memset(i1 | 0, 0, 16);
michael@0 26128 STACKTOP = i4;
michael@0 26129 return;
michael@0 26130 }
michael@0 26131 case 0:
michael@0 26132 {
michael@0 26133 i10 = i2 + 28 | 0;
michael@0 26134 d11 = +HEAPF32[i10 >> 2];
michael@0 26135 d12 = +HEAPF32[i10 + 4 >> 2];
michael@0 26136 d13 = +HEAPF32[i3 + 4 >> 2] >= 0.0 ? d12 : -0.0 - d12;
michael@0 26137 d12 = +HEAPF32[i10 + 8 >> 2];
michael@0 26138 d14 = +HEAPF32[i3 + 8 >> 2] >= 0.0 ? d12 : -0.0 - d12;
michael@0 26139 HEAPF32[i1 >> 2] = +HEAPF32[i3 >> 2] >= 0.0 ? d11 : -0.0 - d11;
michael@0 26140 HEAPF32[i1 + 4 >> 2] = d13;
michael@0 26141 HEAPF32[i1 + 8 >> 2] = d14;
michael@0 26142 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 26143 STACKTOP = i4;
michael@0 26144 return;
michael@0 26145 }
michael@0 26146 case 1:
michael@0 26147 {
michael@0 26148 d14 = +HEAPF32[i3 >> 2];
michael@0 26149 d13 = +HEAPF32[i3 + 4 >> 2];
michael@0 26150 d11 = +HEAPF32[i3 + 8 >> 2];
michael@0 26151 i10 = i2 + 56 | 0;
michael@0 26152 i15 = i10;
michael@0 26153 d12 = d14 * +HEAPF32[i10 >> 2] + d13 * +HEAPF32[i10 + 4 >> 2] + d11 * +HEAPF32[i10 + 8 >> 2];
michael@0 26154 d16 = d14 * +HEAPF32[i10 + 16 >> 2] + d13 * +HEAPF32[i10 + 20 >> 2] + d11 * +HEAPF32[i10 + 24 >> 2];
michael@0 26155 d17 = d14 * +HEAPF32[i10 + 32 >> 2] + d13 * +HEAPF32[i10 + 36 >> 2] + d11 * +HEAPF32[i10 + 40 >> 2];
michael@0 26156 if (d12 < d16) {
michael@0 26157 i18 = d16 < d17 ? 2 : 1;
michael@0 26158 } else {
michael@0 26159 i18 = d12 < d17 ? 2 : 0;
michael@0 26160 }
michael@0 26161 d17 = +HEAPF32[i15 + (i18 << 4) + 4 >> 2];
michael@0 26162 d12 = +HEAPF32[i15 + (i18 << 4) + 8 >> 2];
michael@0 26163 HEAPF32[i1 >> 2] = +HEAPF32[i15 + (i18 << 4) >> 2];
michael@0 26164 HEAPF32[i1 + 4 >> 2] = d17;
michael@0 26165 HEAPF32[i1 + 8 >> 2] = d12;
michael@0 26166 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 26167 STACKTOP = i4;
michael@0 26168 return;
michael@0 26169 }
michael@0 26170 case 13:
michael@0 26171 {
michael@0 26172 i18 = i5;
michael@0 26173 i15 = i2 + 28 | 0;
michael@0 26174 HEAP32[i18 >> 2] = HEAP32[i15 >> 2];
michael@0 26175 HEAP32[i18 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 26176 HEAP32[i18 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 26177 HEAP32[i18 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 26178 HEAPF32[i6 >> 2] = +HEAPF32[i3 >> 2];
michael@0 26179 d12 = +HEAPF32[i3 + 4 >> 2];
michael@0 26180 HEAPF32[i6 + 4 >> 2] = d12;
michael@0 26181 d17 = +HEAPF32[i3 + 8 >> 2];
michael@0 26182 HEAPF32[i6 + 8 >> 2] = d17;
michael@0 26183 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 26184 i15 = HEAP32[i2 + 52 >> 2] | 0;
michael@0 26185 if ((i15 | 0) == 1) {
michael@0 26186 i19 = 0;
michael@0 26187 i20 = i15;
michael@0 26188 i21 = 2;
michael@0 26189 d22 = d17;
michael@0 26190 } else if ((i15 | 0) == 2) {
michael@0 26191 i19 = 0;
michael@0 26192 i20 = i15;
michael@0 26193 i21 = 1;
michael@0 26194 d22 = d12;
michael@0 26195 } else {
michael@0 26196 i19 = 1;
michael@0 26197 i20 = 0;
michael@0 26198 i21 = 2;
michael@0 26199 d22 = d17;
michael@0 26200 }
michael@0 26201 d17 = +HEAPF32[i5 + (i19 << 2) >> 2];
michael@0 26202 d12 = +HEAPF32[i5 + (i15 << 2) >> 2];
michael@0 26203 d16 = +HEAPF32[i6 + (i19 << 2) >> 2];
michael@0 26204 d11 = +Math_sqrt(+(d22 * d22 + d16 * d16));
michael@0 26205 if (d11 != 0.0) {
michael@0 26206 d13 = d17 / d11;
michael@0 26207 HEAPF32[i7 + (i19 << 2) >> 2] = d16 * d13;
michael@0 26208 if (+HEAPF32[i6 + (i20 << 2) >> 2] < 0.0) {
michael@0 26209 d23 = -0.0 - d12;
michael@0 26210 } else {
michael@0 26211 d23 = d12;
michael@0 26212 }
michael@0 26213 HEAPF32[i7 + (i20 << 2) >> 2] = d23;
michael@0 26214 HEAPF32[i7 + (i21 << 2) >> 2] = d22 * d13;
michael@0 26215 HEAPF32[i1 >> 2] = +HEAPF32[i7 >> 2];
michael@0 26216 HEAPF32[i1 + 4 >> 2] = +HEAPF32[i7 + 4 >> 2];
michael@0 26217 HEAPF32[i1 + 8 >> 2] = +HEAPF32[i7 + 8 >> 2];
michael@0 26218 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 26219 STACKTOP = i4;
michael@0 26220 return;
michael@0 26221 } else {
michael@0 26222 HEAPF32[i7 + (i19 << 2) >> 2] = d17;
michael@0 26223 if (+HEAPF32[i6 + (i20 << 2) >> 2] < 0.0) {
michael@0 26224 d24 = -0.0 - d12;
michael@0 26225 } else {
michael@0 26226 d24 = d12;
michael@0 26227 }
michael@0 26228 HEAPF32[i7 + (i20 << 2) >> 2] = d24;
michael@0 26229 HEAPF32[i7 + (i21 << 2) >> 2] = 0.0;
michael@0 26230 HEAPF32[i1 >> 2] = +HEAPF32[i7 >> 2];
michael@0 26231 HEAPF32[i1 + 4 >> 2] = +HEAPF32[i7 + 4 >> 2];
michael@0 26232 HEAPF32[i1 + 8 >> 2] = +HEAPF32[i7 + 8 >> 2];
michael@0 26233 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 26234 STACKTOP = i4;
michael@0 26235 return;
michael@0 26236 }
michael@0 26237 break;
michael@0 26238 }
michael@0 26239 case 5:
michael@0 26240 {
michael@0 26241 i7 = HEAP32[i2 + 92 >> 2] | 0;
michael@0 26242 i21 = HEAP32[i2 + 96 >> 2] | 0;
michael@0 26243 d24 = +HEAPF32[i2 + 12 >> 2];
michael@0 26244 d12 = +HEAPF32[i3 >> 2] * d24;
michael@0 26245 d17 = +HEAPF32[i2 + 16 >> 2];
michael@0 26246 d13 = +HEAPF32[i3 + 4 >> 2] * d17;
michael@0 26247 d22 = +HEAPF32[i2 + 20 >> 2];
michael@0 26248 d23 = +HEAPF32[i3 + 8 >> 2] * d22;
michael@0 26249 if ((i21 | 0) > 0) {
michael@0 26250 d16 = -999999984306749400.0;
michael@0 26251 i20 = -1;
michael@0 26252 i6 = 0;
michael@0 26253 while (1) {
michael@0 26254 d11 = d12 * +HEAPF32[i7 + (i6 << 4) >> 2] + d13 * +HEAPF32[i7 + (i6 << 4) + 4 >> 2] + d23 * +HEAPF32[i7 + (i6 << 4) + 8 >> 2];
michael@0 26255 i19 = d11 > d16;
michael@0 26256 i15 = i19 ? i6 : i20;
michael@0 26257 i5 = i6 + 1 | 0;
michael@0 26258 if ((i5 | 0) < (i21 | 0)) {
michael@0 26259 d16 = i19 ? d11 : d16;
michael@0 26260 i20 = i15;
michael@0 26261 i6 = i5;
michael@0 26262 } else {
michael@0 26263 i25 = i15;
michael@0 26264 break;
michael@0 26265 }
michael@0 26266 }
michael@0 26267 } else {
michael@0 26268 i25 = -1;
michael@0 26269 }
michael@0 26270 d16 = d17 * +HEAPF32[i7 + (i25 << 4) + 4 >> 2];
michael@0 26271 d17 = d22 * +HEAPF32[i7 + (i25 << 4) + 8 >> 2];
michael@0 26272 HEAPF32[i1 >> 2] = d24 * +HEAPF32[i7 + (i25 << 4) >> 2];
michael@0 26273 HEAPF32[i1 + 4 >> 2] = d16;
michael@0 26274 HEAPF32[i1 + 8 >> 2] = d17;
michael@0 26275 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 26276 STACKTOP = i4;
michael@0 26277 return;
michael@0 26278 }
michael@0 26279 case 10:
michael@0 26280 {
michael@0 26281 d17 = +HEAPF32[i3 >> 2];
michael@0 26282 d16 = +HEAPF32[i3 + 4 >> 2];
michael@0 26283 d24 = +HEAPF32[i3 + 8 >> 2];
michael@0 26284 i25 = i2;
michael@0 26285 i7 = HEAP32[i2 + 52 >> 2] | 0;
michael@0 26286 d22 = +HEAPF32[i25 + 28 + (i7 << 2) >> 2];
michael@0 26287 d23 = +HEAPF32[i25 + 28 + (((i7 + 2 | 0) % 3 | 0) << 2) >> 2];
michael@0 26288 d13 = d17 * d17 + d16 * d16 + d24 * d24;
michael@0 26289 if (d13 < 9999999747378752.0e-20) {
michael@0 26290 d26 = 1.0;
michael@0 26291 d27 = 0.0;
michael@0 26292 d28 = 0.0;
michael@0 26293 } else {
michael@0 26294 d12 = 1.0 / +Math_sqrt(+d13);
michael@0 26295 d26 = d17 * d12;
michael@0 26296 d27 = d16 * d12;
michael@0 26297 d28 = d24 * d12;
michael@0 26298 }
michael@0 26299 _memset(i8 | 0, 0, 16);
michael@0 26300 HEAPF32[i8 + (i7 << 2) >> 2] = d22;
michael@0 26301 d12 = d23 * d26 * +HEAPF32[i2 + 12 >> 2];
michael@0 26302 d24 = d23 * d27 * +HEAPF32[i2 + 16 >> 2];
michael@0 26303 d16 = d23 * d28 * +HEAPF32[i2 + 20 >> 2];
michael@0 26304 d23 = +HEAPF32[i2 + 44 >> 2];
michael@0 26305 d17 = d26 * d23;
michael@0 26306 d13 = d27 * d23;
michael@0 26307 d11 = d28 * d23;
michael@0 26308 d23 = d12 + +HEAPF32[i8 >> 2] - d17;
michael@0 26309 d14 = d24 + +HEAPF32[i8 + 4 >> 2] - d13;
michael@0 26310 d29 = d16 + +HEAPF32[i8 + 8 >> 2] - d11;
michael@0 26311 d30 = d28 * d29 + (d26 * d23 + d27 * d14);
michael@0 26312 if (d30 > -999999984306749400.0) {
michael@0 26313 d31 = d30;
michael@0 26314 d32 = d23;
michael@0 26315 d33 = d14;
michael@0 26316 d34 = d29;
michael@0 26317 } else {
michael@0 26318 d31 = -999999984306749400.0;
michael@0 26319 d32 = 0.0;
michael@0 26320 d33 = 0.0;
michael@0 26321 d34 = 0.0;
michael@0 26322 }
michael@0 26323 _memset(i9 | 0, 0, 16);
michael@0 26324 HEAPF32[i9 + (i7 << 2) >> 2] = -0.0 - d22;
michael@0 26325 d22 = d12 + +HEAPF32[i9 >> 2] - d17;
michael@0 26326 d17 = d24 + +HEAPF32[i9 + 4 >> 2] - d13;
michael@0 26327 d13 = d16 + +HEAPF32[i9 + 8 >> 2] - d11;
michael@0 26328 i9 = d28 * d13 + (d26 * d22 + d27 * d17) > d31;
michael@0 26329 HEAPF32[i1 >> 2] = i9 ? d22 : d32;
michael@0 26330 HEAPF32[i1 + 4 >> 2] = i9 ? d17 : d33;
michael@0 26331 HEAPF32[i1 + 8 >> 2] = i9 ? d13 : d34;
michael@0 26332 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 26333 STACKTOP = i4;
michael@0 26334 return;
michael@0 26335 }
michael@0 26336 case 4:
michael@0 26337 {
michael@0 26338 i9 = HEAP32[i2 + 104 >> 2] | 0;
michael@0 26339 i7 = HEAP32[i2 + 96 >> 2] | 0;
michael@0 26340 d34 = +HEAPF32[i2 + 12 >> 2];
michael@0 26341 d13 = +HEAPF32[i3 >> 2] * d34;
michael@0 26342 d33 = +HEAPF32[i2 + 16 >> 2];
michael@0 26343 d17 = +HEAPF32[i3 + 4 >> 2] * d33;
michael@0 26344 d32 = +HEAPF32[i2 + 20 >> 2];
michael@0 26345 d22 = +HEAPF32[i3 + 8 >> 2] * d32;
michael@0 26346 if ((i7 | 0) > 0) {
michael@0 26347 d31 = -999999984306749400.0;
michael@0 26348 i8 = -1;
michael@0 26349 i25 = 0;
michael@0 26350 while (1) {
michael@0 26351 d27 = d13 * +HEAPF32[i9 + (i25 << 4) >> 2] + d17 * +HEAPF32[i9 + (i25 << 4) + 4 >> 2] + d22 * +HEAPF32[i9 + (i25 << 4) + 8 >> 2];
michael@0 26352 i6 = d27 > d31;
michael@0 26353 i20 = i6 ? i25 : i8;
michael@0 26354 i21 = i25 + 1 | 0;
michael@0 26355 if ((i21 | 0) < (i7 | 0)) {
michael@0 26356 d31 = i6 ? d27 : d31;
michael@0 26357 i8 = i20;
michael@0 26358 i25 = i21;
michael@0 26359 } else {
michael@0 26360 i35 = i20;
michael@0 26361 break;
michael@0 26362 }
michael@0 26363 }
michael@0 26364 } else {
michael@0 26365 i35 = -1;
michael@0 26366 }
michael@0 26367 d31 = d33 * +HEAPF32[i9 + (i35 << 4) + 4 >> 2];
michael@0 26368 d33 = d32 * +HEAPF32[i9 + (i35 << 4) + 8 >> 2];
michael@0 26369 HEAPF32[i1 >> 2] = d34 * +HEAPF32[i9 + (i35 << 4) >> 2];
michael@0 26370 HEAPF32[i1 + 4 >> 2] = d31;
michael@0 26371 HEAPF32[i1 + 8 >> 2] = d33;
michael@0 26372 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 26373 STACKTOP = i4;
michael@0 26374 return;
michael@0 26375 }
michael@0 26376 default:
michael@0 26377 {
michael@0 26378 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i2 >> 2] | 0) + 64 >> 2] & 127](i1, i2, i3);
michael@0 26379 STACKTOP = i4;
michael@0 26380 return;
michael@0 26381 }
michael@0 26382 }
michael@0 26383 }
michael@0 26384 function __ZN15btGjkConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i1, i2, i3, i4, i5, i6) {
michael@0 26385 i1 = i1 | 0;
michael@0 26386 i2 = i2 | 0;
michael@0 26387 i3 = i3 | 0;
michael@0 26388 i4 = i4 | 0;
michael@0 26389 i5 = i5 | 0;
michael@0 26390 i6 = i6 | 0;
michael@0 26391 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, d24 = 0.0, d25 = 0.0, d26 = 0.0, i27 = 0, i28 = 0, i29 = 0, d30 = 0.0, d31 = 0.0, i32 = 0, d33 = 0.0, i34 = 0, d35 = 0.0, i36 = 0, d37 = 0.0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, i48 = 0, d49 = 0.0, i50 = 0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0;
michael@0 26392 i7 = STACKTOP;
michael@0 26393 STACKTOP = STACKTOP + 280 | 0;
michael@0 26394 i8 = i7 + 16 | 0;
michael@0 26395 i9 = i7 + 64 | 0;
michael@0 26396 i10 = i7 + 144 | 0;
michael@0 26397 i11 = i1 + 4 | 0;
michael@0 26398 __ZN22btVoronoiSimplexSolver5resetEv(HEAP32[i11 >> 2] | 0);
michael@0 26399 i12 = i2 + 48 | 0;
michael@0 26400 i13 = i3 + 48 | 0;
michael@0 26401 i14 = i12 | 0;
michael@0 26402 i15 = i3 + 52 | 0;
michael@0 26403 i16 = i2 + 52 | 0;
michael@0 26404 i17 = i3 + 56 | 0;
michael@0 26405 i3 = i2 + 56 | 0;
michael@0 26406 i18 = i4 + 48 | 0;
michael@0 26407 i19 = i5 + 48 | 0;
michael@0 26408 i20 = i18 | 0;
michael@0 26409 i21 = i5 + 52 | 0;
michael@0 26410 i22 = i4 + 52 | 0;
michael@0 26411 i23 = i5 + 56 | 0;
michael@0 26412 i5 = i4 + 56 | 0;
michael@0 26413 d24 = +HEAPF32[i13 >> 2] - +HEAPF32[i14 >> 2] - (+HEAPF32[i19 >> 2] - +HEAPF32[i20 >> 2]);
michael@0 26414 d25 = +HEAPF32[i15 >> 2] - +HEAPF32[i16 >> 2] - (+HEAPF32[i21 >> 2] - +HEAPF32[i22 >> 2]);
michael@0 26415 d26 = +HEAPF32[i17 >> 2] - +HEAPF32[i3 >> 2] - (+HEAPF32[i23 >> 2] - +HEAPF32[i5 >> 2]);
michael@0 26416 HEAP32[i8 >> 2] = 4272;
michael@0 26417 i27 = i8 + 36 | 0;
michael@0 26418 HEAPF32[i27 >> 2] = 999999984306749400.0;
michael@0 26419 i28 = i8 + 40 | 0;
michael@0 26420 HEAP8[i28] = 0;
michael@0 26421 __ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i9, HEAP32[i1 + 8 >> 2] | 0, HEAP32[i1 + 12 >> 2] | 0, HEAP32[i11 >> 2] | 0, 0);
michael@0 26422 HEAPF32[i10 + 128 >> 2] = 999999984306749400.0;
michael@0 26423 HEAP32[i10 + 132 >> 2] = 0;
michael@0 26424 i11 = i10;
michael@0 26425 i1 = i2;
michael@0 26426 HEAP32[i11 >> 2] = HEAP32[i1 >> 2];
michael@0 26427 HEAP32[i11 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 26428 HEAP32[i11 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 26429 HEAP32[i11 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 26430 i1 = i10 + 16 | 0;
michael@0 26431 i11 = i2 + 16 | 0;
michael@0 26432 HEAP32[i1 >> 2] = HEAP32[i11 >> 2];
michael@0 26433 HEAP32[i1 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 26434 HEAP32[i1 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 26435 HEAP32[i1 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 26436 i11 = i10 + 32 | 0;
michael@0 26437 i1 = i2 + 32 | 0;
michael@0 26438 HEAP32[i11 >> 2] = HEAP32[i1 >> 2];
michael@0 26439 HEAP32[i11 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 26440 HEAP32[i11 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 26441 HEAP32[i11 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 26442 i1 = i10 + 48 | 0;
michael@0 26443 i11 = i1;
michael@0 26444 i2 = i12;
michael@0 26445 HEAP32[i11 >> 2] = HEAP32[i2 >> 2];
michael@0 26446 HEAP32[i11 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 26447 HEAP32[i11 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 26448 HEAP32[i11 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 26449 i2 = i10 + 64 | 0;
michael@0 26450 i11 = i4;
michael@0 26451 HEAP32[i2 >> 2] = HEAP32[i11 >> 2];
michael@0 26452 HEAP32[i2 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 26453 HEAP32[i2 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 26454 HEAP32[i2 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 26455 i11 = i10 + 80 | 0;
michael@0 26456 i2 = i4 + 16 | 0;
michael@0 26457 HEAP32[i11 >> 2] = HEAP32[i2 >> 2];
michael@0 26458 HEAP32[i11 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 26459 HEAP32[i11 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 26460 HEAP32[i11 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 26461 i2 = i10 + 96 | 0;
michael@0 26462 i11 = i4 + 32 | 0;
michael@0 26463 HEAP32[i2 >> 2] = HEAP32[i11 >> 2];
michael@0 26464 HEAP32[i2 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 26465 HEAP32[i2 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 26466 HEAP32[i2 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 26467 i11 = i10 + 112 | 0;
michael@0 26468 i2 = i11;
michael@0 26469 i4 = i18;
michael@0 26470 HEAP32[i2 >> 2] = HEAP32[i4 >> 2];
michael@0 26471 HEAP32[i2 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 26472 HEAP32[i2 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 26473 HEAP32[i2 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 26474 i4 = i8 | 0;
michael@0 26475 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i9, i10, i4, 0, 0);
michael@0 26476 i2 = (HEAP8[i28] | 0) == 0;
michael@0 26477 i18 = i8 + 20 | 0;
michael@0 26478 i12 = i7 | 0;
michael@0 26479 HEAP32[i12 >> 2] = HEAP32[i18 >> 2];
michael@0 26480 HEAP32[i12 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 26481 HEAP32[i12 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 26482 HEAP32[i12 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 26483 if (i2) {
michael@0 26484 i29 = 0;
michael@0 26485 STACKTOP = i7;
michael@0 26486 return i29 | 0;
michael@0 26487 }
michael@0 26488 d30 = +HEAPF32[i27 >> 2];
michael@0 26489 i2 = i8 + 4 | 0;
michael@0 26490 d31 = +HEAPF32[i2 >> 2];
michael@0 26491 i32 = i8 + 8 | 0;
michael@0 26492 d33 = +HEAPF32[i32 >> 2];
michael@0 26493 i34 = i8 + 12 | 0;
michael@0 26494 d35 = +HEAPF32[i34 >> 2];
michael@0 26495 i36 = i8 + 16 | 0;
michael@0 26496 d37 = +HEAPF32[i36 >> 2];
michael@0 26497 do {
michael@0 26498 if (d30 > .0010000000474974513) {
michael@0 26499 i8 = i6;
michael@0 26500 i38 = i1 | 0;
michael@0 26501 i39 = i10 + 52 | 0;
michael@0 26502 i40 = i10 + 56 | 0;
michael@0 26503 i41 = i11 | 0;
michael@0 26504 i42 = i10 + 116 | 0;
michael@0 26505 i43 = i10 + 120 | 0;
michael@0 26506 d44 = d35;
michael@0 26507 d45 = d33;
michael@0 26508 d46 = d31;
michael@0 26509 d47 = 0.0;
michael@0 26510 i48 = 1;
michael@0 26511 d49 = d30;
michael@0 26512 while (1) {
michael@0 26513 if ((i48 | 0) > 32) {
michael@0 26514 i29 = 0;
michael@0 26515 i50 = 2068;
michael@0 26516 break;
michael@0 26517 }
michael@0 26518 d51 = d47 - d49 / (d26 * d44 + (d24 * d46 + d25 * d45));
michael@0 26519 if (!(d51 >= 0.0 & d51 <= 1.0 & d51 > d47)) {
michael@0 26520 i29 = 0;
michael@0 26521 i50 = 2067;
michael@0 26522 break;
michael@0 26523 }
michael@0 26524 FUNCTION_TABLE_vif[HEAP32[HEAP32[i8 >> 2] >> 2] & 31](i6, d51);
michael@0 26525 d52 = 1.0 - d51;
michael@0 26526 HEAPF32[i38 >> 2] = d52 * +HEAPF32[i14 >> 2] + d51 * +HEAPF32[i13 >> 2];
michael@0 26527 HEAPF32[i39 >> 2] = d52 * +HEAPF32[i16 >> 2] + d51 * +HEAPF32[i15 >> 2];
michael@0 26528 HEAPF32[i40 >> 2] = d52 * +HEAPF32[i3 >> 2] + d51 * +HEAPF32[i17 >> 2];
michael@0 26529 HEAPF32[i41 >> 2] = d52 * +HEAPF32[i20 >> 2] + d51 * +HEAPF32[i19 >> 2];
michael@0 26530 HEAPF32[i42 >> 2] = d52 * +HEAPF32[i22 >> 2] + d51 * +HEAPF32[i21 >> 2];
michael@0 26531 HEAPF32[i43 >> 2] = d52 * +HEAPF32[i5 >> 2] + d51 * +HEAPF32[i23 >> 2];
michael@0 26532 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i9, i10, i4, 0, 0);
michael@0 26533 if ((HEAP8[i28] | 0) == 0) {
michael@0 26534 i29 = 0;
michael@0 26535 i50 = 2070;
michael@0 26536 break;
michael@0 26537 }
michael@0 26538 d52 = +HEAPF32[i27 >> 2];
michael@0 26539 if (d52 < 0.0) {
michael@0 26540 i50 = 2059;
michael@0 26541 break;
michael@0 26542 }
michael@0 26543 HEAP32[i12 >> 2] = HEAP32[i18 >> 2];
michael@0 26544 HEAP32[i12 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 26545 HEAP32[i12 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 26546 HEAP32[i12 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 26547 d53 = +HEAPF32[i2 >> 2];
michael@0 26548 d54 = +HEAPF32[i32 >> 2];
michael@0 26549 d55 = +HEAPF32[i34 >> 2];
michael@0 26550 if (d52 > .0010000000474974513) {
michael@0 26551 d44 = d55;
michael@0 26552 d45 = d54;
michael@0 26553 d46 = d53;
michael@0 26554 d47 = d51;
michael@0 26555 i48 = i48 + 1 | 0;
michael@0 26556 d49 = d52;
michael@0 26557 } else {
michael@0 26558 i50 = 2061;
michael@0 26559 break;
michael@0 26560 }
michael@0 26561 }
michael@0 26562 if ((i50 | 0) == 2059) {
michael@0 26563 HEAPF32[i6 + 164 >> 2] = d51;
michael@0 26564 d49 = +HEAPF32[i32 >> 2];
michael@0 26565 d47 = +HEAPF32[i34 >> 2];
michael@0 26566 d46 = +HEAPF32[i36 >> 2];
michael@0 26567 HEAPF32[i6 + 132 >> 2] = +HEAPF32[i2 >> 2];
michael@0 26568 HEAPF32[i6 + 136 >> 2] = d49;
michael@0 26569 HEAPF32[i6 + 140 >> 2] = d47;
michael@0 26570 HEAPF32[i6 + 144 >> 2] = d46;
michael@0 26571 i48 = i6 + 148 | 0;
michael@0 26572 HEAP32[i48 >> 2] = HEAP32[i18 >> 2];
michael@0 26573 HEAP32[i48 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 26574 HEAP32[i48 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 26575 HEAP32[i48 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 26576 i29 = 1;
michael@0 26577 STACKTOP = i7;
michael@0 26578 return i29 | 0;
michael@0 26579 } else if ((i50 | 0) == 2068) {
michael@0 26580 STACKTOP = i7;
michael@0 26581 return i29 | 0;
michael@0 26582 } else if ((i50 | 0) == 2061) {
michael@0 26583 d56 = +HEAPF32[i36 >> 2];
michael@0 26584 d57 = d55;
michael@0 26585 d58 = d54;
michael@0 26586 d59 = d53;
michael@0 26587 d60 = d51;
michael@0 26588 break;
michael@0 26589 } else if ((i50 | 0) == 2067) {
michael@0 26590 STACKTOP = i7;
michael@0 26591 return i29 | 0;
michael@0 26592 } else if ((i50 | 0) == 2070) {
michael@0 26593 STACKTOP = i7;
michael@0 26594 return i29 | 0;
michael@0 26595 }
michael@0 26596 } else {
michael@0 26597 d56 = d37;
michael@0 26598 d57 = d35;
michael@0 26599 d58 = d33;
michael@0 26600 d59 = d31;
michael@0 26601 d60 = 0.0;
michael@0 26602 }
michael@0 26603 } while (0);
michael@0 26604 if (d26 * d57 + (d24 * d59 + d25 * d58) >= -0.0 - +HEAPF32[i6 + 172 >> 2]) {
michael@0 26605 i29 = 0;
michael@0 26606 STACKTOP = i7;
michael@0 26607 return i29 | 0;
michael@0 26608 }
michael@0 26609 HEAPF32[i6 + 164 >> 2] = d60;
michael@0 26610 HEAPF32[i6 + 132 >> 2] = d59;
michael@0 26611 HEAPF32[i6 + 136 >> 2] = d58;
michael@0 26612 HEAPF32[i6 + 140 >> 2] = d57;
michael@0 26613 HEAPF32[i6 + 144 >> 2] = d56;
michael@0 26614 i50 = i6 + 148 | 0;
michael@0 26615 HEAP32[i50 >> 2] = HEAP32[i12 >> 2];
michael@0 26616 HEAP32[i50 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 26617 HEAP32[i50 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 26618 HEAP32[i50 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 26619 i29 = 1;
michael@0 26620 STACKTOP = i7;
michael@0 26621 return i29 | 0;
michael@0 26622 }
michael@0 26623 function __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallback13ProcessIslandEPP17btCollisionObjectiPP20btPersistentManifoldii(i1, i2, i3, i4, i5, i6) {
michael@0 26624 i1 = i1 | 0;
michael@0 26625 i2 = i2 | 0;
michael@0 26626 i3 = i3 | 0;
michael@0 26627 i4 = i4 | 0;
michael@0 26628 i5 = i5 | 0;
michael@0 26629 i6 = i6 | 0;
michael@0 26630 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0;
michael@0 26631 i7 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 26632 if ((i6 | 0) < 0) {
michael@0 26633 if ((i7 | 0) == (-i5 | 0)) {
michael@0 26634 return;
michael@0 26635 }
michael@0 26636 i8 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 26637 i9 = HEAP32[(HEAP32[i8 >> 2] | 0) + 12 >> 2] | 0;
michael@0 26638 i10 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 26639 i11 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 26640 i12 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 26641 i13 = HEAP32[i1 + 24 >> 2] | 0;
michael@0 26642 i14 = HEAP32[i1 + 28 >> 2] | 0;
michael@0 26643 +FUNCTION_TABLE_fiiiiiiiiiii[i9 & 3](i8, i2, i3, i4, i5, i10, i7, i11, i12, i13, i14);
michael@0 26644 return;
michael@0 26645 }
michael@0 26646 i14 = i1 + 12 | 0;
michael@0 26647 i13 = 0;
michael@0 26648 while (1) {
michael@0 26649 if ((i13 | 0) >= (i7 | 0)) {
michael@0 26650 i15 = 0;
michael@0 26651 i16 = 0;
michael@0 26652 break;
michael@0 26653 }
michael@0 26654 i17 = HEAP32[i14 >> 2] | 0;
michael@0 26655 i18 = i17 + (i13 << 2) | 0;
michael@0 26656 i12 = HEAP32[i18 >> 2] | 0;
michael@0 26657 i11 = HEAP32[(HEAP32[i12 + 24 >> 2] | 0) + 208 >> 2] | 0;
michael@0 26658 if ((i11 | 0) > -1) {
michael@0 26659 i19 = i11;
michael@0 26660 } else {
michael@0 26661 i19 = HEAP32[(HEAP32[i12 + 28 >> 2] | 0) + 208 >> 2] | 0;
michael@0 26662 }
michael@0 26663 if ((i19 | 0) == (i6 | 0)) {
michael@0 26664 i20 = 0;
michael@0 26665 i21 = i13;
michael@0 26666 i22 = 889;
michael@0 26667 break;
michael@0 26668 } else {
michael@0 26669 i13 = i13 + 1 | 0;
michael@0 26670 }
michael@0 26671 }
michael@0 26672 if ((i22 | 0) == 889) {
michael@0 26673 while (1) {
michael@0 26674 i22 = 0;
michael@0 26675 i13 = HEAP32[i17 + (i21 << 2) >> 2] | 0;
michael@0 26676 i19 = HEAP32[(HEAP32[i13 + 24 >> 2] | 0) + 208 >> 2] | 0;
michael@0 26677 if ((i19 | 0) > -1) {
michael@0 26678 i23 = i19;
michael@0 26679 } else {
michael@0 26680 i23 = HEAP32[(HEAP32[i13 + 28 >> 2] | 0) + 208 >> 2] | 0;
michael@0 26681 }
michael@0 26682 i13 = ((i23 | 0) == (i6 | 0)) + i20 | 0;
michael@0 26683 i19 = i21 + 1 | 0;
michael@0 26684 if ((i19 | 0) < (i7 | 0)) {
michael@0 26685 i20 = i13;
michael@0 26686 i21 = i19;
michael@0 26687 i22 = 889;
michael@0 26688 } else {
michael@0 26689 i15 = i13;
michael@0 26690 i16 = i18;
michael@0 26691 break;
michael@0 26692 }
michael@0 26693 }
michael@0 26694 }
michael@0 26695 i18 = i1 + 4 | 0;
michael@0 26696 i22 = HEAP32[i18 >> 2] | 0;
michael@0 26697 if ((HEAP32[i22 + 68 >> 2] | 0) < 2) {
michael@0 26698 if ((i15 | 0) == (-i5 | 0)) {
michael@0 26699 return;
michael@0 26700 }
michael@0 26701 i21 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 26702 i20 = HEAP32[(HEAP32[i21 >> 2] | 0) + 12 >> 2] | 0;
michael@0 26703 i7 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 26704 i6 = HEAP32[i1 + 24 >> 2] | 0;
michael@0 26705 i23 = HEAP32[i1 + 28 >> 2] | 0;
michael@0 26706 +FUNCTION_TABLE_fiiiiiiiiiii[i20 & 3](i21, i2, i3, i4, i5, i16, i15, i22, i7, i6, i23);
michael@0 26707 return;
michael@0 26708 }
michael@0 26709 if ((i3 | 0) > 0) {
michael@0 26710 i23 = i1 + 36 | 0;
michael@0 26711 i6 = i1 + 40 | 0;
michael@0 26712 i7 = i1 + 44 | 0;
michael@0 26713 i22 = i1 + 48 | 0;
michael@0 26714 i21 = 0;
michael@0 26715 i20 = HEAP32[i23 >> 2] | 0;
michael@0 26716 i17 = HEAP32[i6 >> 2] | 0;
michael@0 26717 while (1) {
michael@0 26718 i13 = i2 + (i21 << 2) | 0;
michael@0 26719 do {
michael@0 26720 if ((i20 | 0) == (i17 | 0)) {
michael@0 26721 i19 = (i17 | 0) == 0 ? 1 : i17 << 1;
michael@0 26722 if ((i17 | 0) >= (i19 | 0)) {
michael@0 26723 i24 = i17;
michael@0 26724 i25 = i17;
michael@0 26725 break;
michael@0 26726 }
michael@0 26727 if ((i19 | 0) == 0) {
michael@0 26728 i26 = 0;
michael@0 26729 i27 = i17;
michael@0 26730 } else {
michael@0 26731 i14 = __Z22btAlignedAllocInternalji(i19 << 2, 16) | 0;
michael@0 26732 i26 = i14;
michael@0 26733 i27 = HEAP32[i23 >> 2] | 0;
michael@0 26734 }
michael@0 26735 if ((i27 | 0) > 0) {
michael@0 26736 i14 = 0;
michael@0 26737 do {
michael@0 26738 i12 = i26 + (i14 << 2) | 0;
michael@0 26739 if ((i12 | 0) != 0) {
michael@0 26740 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i7 >> 2] | 0) + (i14 << 2) >> 2];
michael@0 26741 }
michael@0 26742 i14 = i14 + 1 | 0;
michael@0 26743 } while ((i14 | 0) < (i27 | 0));
michael@0 26744 }
michael@0 26745 i14 = HEAP32[i7 >> 2] | 0;
michael@0 26746 if ((i14 | 0) == 0) {
michael@0 26747 i28 = i27;
michael@0 26748 } else {
michael@0 26749 if ((HEAP8[i22] | 0) == 0) {
michael@0 26750 i29 = i27;
michael@0 26751 } else {
michael@0 26752 __Z21btAlignedFreeInternalPv(i14);
michael@0 26753 i29 = HEAP32[i23 >> 2] | 0;
michael@0 26754 }
michael@0 26755 HEAP32[i7 >> 2] = 0;
michael@0 26756 i28 = i29;
michael@0 26757 }
michael@0 26758 HEAP8[i22] = 1;
michael@0 26759 HEAP32[i7 >> 2] = i26;
michael@0 26760 HEAP32[i6 >> 2] = i19;
michael@0 26761 i24 = i28;
michael@0 26762 i25 = i19;
michael@0 26763 } else {
michael@0 26764 i24 = i20;
michael@0 26765 i25 = i17;
michael@0 26766 }
michael@0 26767 } while (0);
michael@0 26768 i14 = (HEAP32[i7 >> 2] | 0) + (i24 << 2) | 0;
michael@0 26769 if ((i14 | 0) != 0) {
michael@0 26770 HEAP32[i14 >> 2] = HEAP32[i13 >> 2];
michael@0 26771 }
michael@0 26772 i14 = i24 + 1 | 0;
michael@0 26773 HEAP32[i23 >> 2] = i14;
michael@0 26774 i12 = i21 + 1 | 0;
michael@0 26775 if ((i12 | 0) < (i3 | 0)) {
michael@0 26776 i21 = i12;
michael@0 26777 i20 = i14;
michael@0 26778 i17 = i25;
michael@0 26779 } else {
michael@0 26780 break;
michael@0 26781 }
michael@0 26782 }
michael@0 26783 }
michael@0 26784 if ((i5 | 0) > 0) {
michael@0 26785 i25 = i1 + 56 | 0;
michael@0 26786 i17 = i1 + 60 | 0;
michael@0 26787 i20 = i1 + 64 | 0;
michael@0 26788 i21 = i1 + 68 | 0;
michael@0 26789 i3 = 0;
michael@0 26790 i23 = HEAP32[i25 >> 2] | 0;
michael@0 26791 i24 = HEAP32[i17 >> 2] | 0;
michael@0 26792 while (1) {
michael@0 26793 i7 = i4 + (i3 << 2) | 0;
michael@0 26794 do {
michael@0 26795 if ((i23 | 0) == (i24 | 0)) {
michael@0 26796 i28 = (i24 | 0) == 0 ? 1 : i24 << 1;
michael@0 26797 if ((i24 | 0) >= (i28 | 0)) {
michael@0 26798 i30 = i24;
michael@0 26799 i31 = i24;
michael@0 26800 break;
michael@0 26801 }
michael@0 26802 if ((i28 | 0) == 0) {
michael@0 26803 i32 = 0;
michael@0 26804 i33 = i24;
michael@0 26805 } else {
michael@0 26806 i6 = __Z22btAlignedAllocInternalji(i28 << 2, 16) | 0;
michael@0 26807 i32 = i6;
michael@0 26808 i33 = HEAP32[i25 >> 2] | 0;
michael@0 26809 }
michael@0 26810 if ((i33 | 0) > 0) {
michael@0 26811 i6 = 0;
michael@0 26812 do {
michael@0 26813 i26 = i32 + (i6 << 2) | 0;
michael@0 26814 if ((i26 | 0) != 0) {
michael@0 26815 HEAP32[i26 >> 2] = HEAP32[(HEAP32[i20 >> 2] | 0) + (i6 << 2) >> 2];
michael@0 26816 }
michael@0 26817 i6 = i6 + 1 | 0;
michael@0 26818 } while ((i6 | 0) < (i33 | 0));
michael@0 26819 }
michael@0 26820 i6 = HEAP32[i20 >> 2] | 0;
michael@0 26821 if ((i6 | 0) == 0) {
michael@0 26822 i34 = i33;
michael@0 26823 } else {
michael@0 26824 if ((HEAP8[i21] | 0) == 0) {
michael@0 26825 i35 = i33;
michael@0 26826 } else {
michael@0 26827 __Z21btAlignedFreeInternalPv(i6);
michael@0 26828 i35 = HEAP32[i25 >> 2] | 0;
michael@0 26829 }
michael@0 26830 HEAP32[i20 >> 2] = 0;
michael@0 26831 i34 = i35;
michael@0 26832 }
michael@0 26833 HEAP8[i21] = 1;
michael@0 26834 HEAP32[i20 >> 2] = i32;
michael@0 26835 HEAP32[i17 >> 2] = i28;
michael@0 26836 i30 = i34;
michael@0 26837 i31 = i28;
michael@0 26838 } else {
michael@0 26839 i30 = i23;
michael@0 26840 i31 = i24;
michael@0 26841 }
michael@0 26842 } while (0);
michael@0 26843 i13 = (HEAP32[i20 >> 2] | 0) + (i30 << 2) | 0;
michael@0 26844 if ((i13 | 0) != 0) {
michael@0 26845 HEAP32[i13 >> 2] = HEAP32[i7 >> 2];
michael@0 26846 }
michael@0 26847 i13 = i30 + 1 | 0;
michael@0 26848 HEAP32[i25 >> 2] = i13;
michael@0 26849 i6 = i3 + 1 | 0;
michael@0 26850 if ((i6 | 0) < (i5 | 0)) {
michael@0 26851 i3 = i6;
michael@0 26852 i23 = i13;
michael@0 26853 i24 = i31;
michael@0 26854 } else {
michael@0 26855 break;
michael@0 26856 }
michael@0 26857 }
michael@0 26858 }
michael@0 26859 i31 = i1 + 76 | 0;
michael@0 26860 if ((i15 | 0) > 0) {
michael@0 26861 i24 = i1 + 80 | 0;
michael@0 26862 i23 = i1 + 84 | 0;
michael@0 26863 i3 = i1 + 88 | 0;
michael@0 26864 i5 = 0;
michael@0 26865 i25 = HEAP32[i31 >> 2] | 0;
michael@0 26866 i30 = HEAP32[i24 >> 2] | 0;
michael@0 26867 while (1) {
michael@0 26868 i20 = i16 + (i5 << 2) | 0;
michael@0 26869 do {
michael@0 26870 if ((i25 | 0) == (i30 | 0)) {
michael@0 26871 i34 = (i30 | 0) == 0 ? 1 : i30 << 1;
michael@0 26872 if ((i30 | 0) >= (i34 | 0)) {
michael@0 26873 i36 = i30;
michael@0 26874 i37 = i30;
michael@0 26875 break;
michael@0 26876 }
michael@0 26877 if ((i34 | 0) == 0) {
michael@0 26878 i38 = 0;
michael@0 26879 i39 = i30;
michael@0 26880 } else {
michael@0 26881 i17 = __Z22btAlignedAllocInternalji(i34 << 2, 16) | 0;
michael@0 26882 i38 = i17;
michael@0 26883 i39 = HEAP32[i31 >> 2] | 0;
michael@0 26884 }
michael@0 26885 if ((i39 | 0) > 0) {
michael@0 26886 i17 = 0;
michael@0 26887 do {
michael@0 26888 i32 = i38 + (i17 << 2) | 0;
michael@0 26889 if ((i32 | 0) != 0) {
michael@0 26890 HEAP32[i32 >> 2] = HEAP32[(HEAP32[i23 >> 2] | 0) + (i17 << 2) >> 2];
michael@0 26891 }
michael@0 26892 i17 = i17 + 1 | 0;
michael@0 26893 } while ((i17 | 0) < (i39 | 0));
michael@0 26894 }
michael@0 26895 i17 = HEAP32[i23 >> 2] | 0;
michael@0 26896 if ((i17 | 0) == 0) {
michael@0 26897 i40 = i39;
michael@0 26898 } else {
michael@0 26899 if ((HEAP8[i3] | 0) == 0) {
michael@0 26900 i41 = i39;
michael@0 26901 } else {
michael@0 26902 __Z21btAlignedFreeInternalPv(i17);
michael@0 26903 i41 = HEAP32[i31 >> 2] | 0;
michael@0 26904 }
michael@0 26905 HEAP32[i23 >> 2] = 0;
michael@0 26906 i40 = i41;
michael@0 26907 }
michael@0 26908 HEAP8[i3] = 1;
michael@0 26909 HEAP32[i23 >> 2] = i38;
michael@0 26910 HEAP32[i24 >> 2] = i34;
michael@0 26911 i36 = i40;
michael@0 26912 i37 = i34;
michael@0 26913 } else {
michael@0 26914 i36 = i25;
michael@0 26915 i37 = i30;
michael@0 26916 }
michael@0 26917 } while (0);
michael@0 26918 i7 = (HEAP32[i23 >> 2] | 0) + (i36 << 2) | 0;
michael@0 26919 if ((i7 | 0) != 0) {
michael@0 26920 HEAP32[i7 >> 2] = HEAP32[i20 >> 2];
michael@0 26921 }
michael@0 26922 i7 = i36 + 1 | 0;
michael@0 26923 HEAP32[i31 >> 2] = i7;
michael@0 26924 i17 = i5 + 1 | 0;
michael@0 26925 if ((i17 | 0) < (i15 | 0)) {
michael@0 26926 i5 = i17;
michael@0 26927 i25 = i7;
michael@0 26928 i30 = i37;
michael@0 26929 } else {
michael@0 26930 i42 = i7;
michael@0 26931 break;
michael@0 26932 }
michael@0 26933 }
michael@0 26934 } else {
michael@0 26935 i42 = HEAP32[i31 >> 2] | 0;
michael@0 26936 }
michael@0 26937 if (((HEAP32[i1 + 56 >> 2] | 0) + i42 | 0) <= (HEAP32[(HEAP32[i18 >> 2] | 0) + 68 >> 2] | 0)) {
michael@0 26938 return;
michael@0 26939 }
michael@0 26940 __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallback18processConstraintsEv(i1);
michael@0 26941 return;
michael@0 26942 }
michael@0 26943 function __ZN15btGjkEpaSolver211PenetrationEPK13btConvexShapeRK11btTransformS2_S5_RK9btVector3RNS_8sResultsEb(i1, i2, i3, i4, i5, i6, i7) {
michael@0 26944 i1 = i1 | 0;
michael@0 26945 i2 = i2 | 0;
michael@0 26946 i3 = i3 | 0;
michael@0 26947 i4 = i4 | 0;
michael@0 26948 i5 = i5 | 0;
michael@0 26949 i6 = i6 | 0;
michael@0 26950 i7 = i7 | 0;
michael@0 26951 var i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, i23 = 0, d24 = 0.0, d25 = 0.0, i26 = 0, d27 = 0.0, i28 = 0, d29 = 0.0, i30 = 0, d31 = 0.0, d32 = 0.0, i33 = 0, d34 = 0.0, i35 = 0, d36 = 0.0, i37 = 0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, d55 = 0.0, d56 = 0.0, d57 = 0.0, i58 = 0;
michael@0 26952 i8 = STACKTOP;
michael@0 26953 STACKTOP = STACKTOP + 10368 | 0;
michael@0 26954 i9 = i8 | 0;
michael@0 26955 i10 = i8 + 128 | 0;
michael@0 26956 i11 = i8 + 512 | 0;
michael@0 26957 i12 = i8 + 528 | 0;
michael@0 26958 i13 = i8 + 10336 | 0;
michael@0 26959 i14 = i8 + 10352 | 0;
michael@0 26960 i15 = i6 + 20 | 0;
michael@0 26961 i16 = i6 + 20 | 0;
michael@0 26962 i17 = i6 + 4 | 0;
michael@0 26963 _memset(i16 | 0, 0, 16);
michael@0 26964 HEAP32[i17 >> 2] = HEAP32[i15 >> 2];
michael@0 26965 HEAP32[i17 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 26966 HEAP32[i17 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 26967 HEAP32[i17 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 26968 i15 = i6 | 0;
michael@0 26969 HEAP32[i15 >> 2] = 0;
michael@0 26970 i17 = i9 | 0;
michael@0 26971 HEAP32[i17 >> 2] = i1;
michael@0 26972 HEAP32[i9 + 4 >> 2] = i3;
michael@0 26973 d18 = +HEAPF32[i4 >> 2];
michael@0 26974 i3 = i2 | 0;
michael@0 26975 d19 = +HEAPF32[i3 >> 2];
michael@0 26976 d20 = +HEAPF32[i4 + 16 >> 2];
michael@0 26977 i1 = i2 + 16 | 0;
michael@0 26978 d21 = +HEAPF32[i1 >> 2];
michael@0 26979 d22 = +HEAPF32[i4 + 32 >> 2];
michael@0 26980 i23 = i2 + 32 | 0;
michael@0 26981 d24 = +HEAPF32[i23 >> 2];
michael@0 26982 d25 = d18 * d19 + d20 * d21 + d22 * d24;
michael@0 26983 i26 = i2 + 4 | 0;
michael@0 26984 d27 = +HEAPF32[i26 >> 2];
michael@0 26985 i28 = i2 + 20 | 0;
michael@0 26986 d29 = +HEAPF32[i28 >> 2];
michael@0 26987 i30 = i2 + 36 | 0;
michael@0 26988 d31 = +HEAPF32[i30 >> 2];
michael@0 26989 d32 = d18 * d27 + d20 * d29 + d22 * d31;
michael@0 26990 i33 = i2 + 8 | 0;
michael@0 26991 d34 = +HEAPF32[i33 >> 2];
michael@0 26992 i35 = i2 + 24 | 0;
michael@0 26993 d36 = +HEAPF32[i35 >> 2];
michael@0 26994 i37 = i2 + 40 | 0;
michael@0 26995 d38 = +HEAPF32[i37 >> 2];
michael@0 26996 d39 = d18 * d34 + d20 * d36 + d22 * d38;
michael@0 26997 d22 = +HEAPF32[i4 + 4 >> 2];
michael@0 26998 d20 = +HEAPF32[i4 + 20 >> 2];
michael@0 26999 d18 = +HEAPF32[i4 + 36 >> 2];
michael@0 27000 d40 = d19 * d22 + d21 * d20 + d24 * d18;
michael@0 27001 d41 = d27 * d22 + d29 * d20 + d31 * d18;
michael@0 27002 d42 = d34 * d22 + d36 * d20 + d38 * d18;
michael@0 27003 d18 = +HEAPF32[i4 + 8 >> 2];
michael@0 27004 d20 = +HEAPF32[i4 + 24 >> 2];
michael@0 27005 d22 = +HEAPF32[i4 + 40 >> 2];
michael@0 27006 d43 = d19 * d18 + d21 * d20 + d24 * d22;
michael@0 27007 d44 = d27 * d18 + d29 * d20 + d31 * d22;
michael@0 27008 d45 = d34 * d18 + d36 * d20 + d38 * d22;
michael@0 27009 HEAPF32[i9 + 8 >> 2] = d25;
michael@0 27010 HEAPF32[i9 + 12 >> 2] = d32;
michael@0 27011 HEAPF32[i9 + 16 >> 2] = d39;
michael@0 27012 HEAPF32[i9 + 20 >> 2] = 0.0;
michael@0 27013 HEAPF32[i9 + 24 >> 2] = d40;
michael@0 27014 HEAPF32[i9 + 28 >> 2] = d41;
michael@0 27015 HEAPF32[i9 + 32 >> 2] = d42;
michael@0 27016 HEAPF32[i9 + 36 >> 2] = 0.0;
michael@0 27017 HEAPF32[i9 + 40 >> 2] = d43;
michael@0 27018 HEAPF32[i9 + 44 >> 2] = d44;
michael@0 27019 HEAPF32[i9 + 48 >> 2] = d45;
michael@0 27020 HEAPF32[i9 + 52 >> 2] = 0.0;
michael@0 27021 i46 = i2 + 48 | 0;
michael@0 27022 d22 = +HEAPF32[i4 + 48 >> 2] - +HEAPF32[i46 >> 2];
michael@0 27023 i47 = i2 + 52 | 0;
michael@0 27024 d20 = +HEAPF32[i4 + 52 >> 2] - +HEAPF32[i47 >> 2];
michael@0 27025 i48 = i2 + 56 | 0;
michael@0 27026 d18 = +HEAPF32[i4 + 56 >> 2] - +HEAPF32[i48 >> 2];
michael@0 27027 HEAPF32[i9 + 56 >> 2] = d25;
michael@0 27028 HEAPF32[i9 + 60 >> 2] = d40;
michael@0 27029 HEAPF32[i9 + 64 >> 2] = d43;
michael@0 27030 HEAPF32[i9 + 68 >> 2] = 0.0;
michael@0 27031 HEAPF32[i9 + 72 >> 2] = d32;
michael@0 27032 HEAPF32[i9 + 76 >> 2] = d41;
michael@0 27033 HEAPF32[i9 + 80 >> 2] = d44;
michael@0 27034 HEAPF32[i9 + 84 >> 2] = 0.0;
michael@0 27035 HEAPF32[i9 + 88 >> 2] = d39;
michael@0 27036 HEAPF32[i9 + 92 >> 2] = d42;
michael@0 27037 HEAPF32[i9 + 96 >> 2] = d45;
michael@0 27038 HEAPF32[i9 + 100 >> 2] = 0.0;
michael@0 27039 HEAPF32[i9 + 104 >> 2] = d19 * d22 + d21 * d20 + d24 * d18;
michael@0 27040 HEAPF32[i9 + 108 >> 2] = d27 * d22 + d29 * d20 + d31 * d18;
michael@0 27041 HEAPF32[i9 + 112 >> 2] = d34 * d22 + d36 * d20 + d38 * d18;
michael@0 27042 HEAPF32[i9 + 116 >> 2] = 0.0;
michael@0 27043 i4 = i9 + 120 | 0;
michael@0 27044 HEAP32[i4 >> 2] = i7 ? 36 : 82;
michael@0 27045 i2 = i9 + 124 | 0;
michael@0 27046 HEAP32[i2 >> 2] = i7 ? 0 : 0;
michael@0 27047 HEAP32[i10 + 364 >> 2] = 0;
michael@0 27048 _memset(i10 + 128 | 0, 0, 16);
michael@0 27049 HEAP32[i10 + 376 >> 2] = 2;
michael@0 27050 HEAP32[i10 + 368 >> 2] = 0;
michael@0 27051 HEAPF32[i10 + 144 >> 2] = 0.0;
michael@0 27052 i7 = i5 | 0;
michael@0 27053 i49 = i5 + 4 | 0;
michael@0 27054 d18 = -0.0 - +HEAPF32[i49 >> 2];
michael@0 27055 i50 = i5 + 8 | 0;
michael@0 27056 d38 = -0.0 - +HEAPF32[i50 >> 2];
michael@0 27057 HEAPF32[i11 >> 2] = -0.0 - +HEAPF32[i7 >> 2];
michael@0 27058 HEAPF32[i11 + 4 >> 2] = d18;
michael@0 27059 HEAPF32[i11 + 8 >> 2] = d38;
michael@0 27060 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 27061 i5 = __ZN12gjkepa2_impl3GJK8EvaluateERKNS_13MinkowskiDiffERK9btVector3(i10, i9, i11) | 0;
michael@0 27062 if ((i5 | 0) == 2) {
michael@0 27063 HEAP32[i15 >> 2] = 2;
michael@0 27064 i51 = 0;
michael@0 27065 STACKTOP = i8;
michael@0 27066 return i51 | 0;
michael@0 27067 } else if ((i5 | 0) == 1) {
michael@0 27068 i5 = i12 + 9800 | 0;
michael@0 27069 i11 = i12 + 9804 | 0;
michael@0 27070 _memset(i12 + 9792 | 0, 0, 16);
michael@0 27071 HEAP32[i12 >> 2] = 9;
michael@0 27072 i9 = i12 + 40 | 0;
michael@0 27073 HEAP32[i12 + 9788 >> 2] = 0;
michael@0 27074 _memset(i9 | 0, 0, 20);
michael@0 27075 i52 = 0;
michael@0 27076 do {
michael@0 27077 i53 = 128 - i52 - 1 | 0;
michael@0 27078 i54 = i12 + 2108 + (i53 * 60 | 0) | 0;
michael@0 27079 HEAP32[i12 + 2108 + (i53 * 60 | 0) + 48 >> 2] = 0;
michael@0 27080 HEAP32[i12 + 2108 + (i53 * 60 | 0) + 52 >> 2] = HEAP32[i5 >> 2];
michael@0 27081 i53 = HEAP32[i5 >> 2] | 0;
michael@0 27082 if ((i53 | 0) != 0) {
michael@0 27083 HEAP32[i53 + 48 >> 2] = i54;
michael@0 27084 }
michael@0 27085 HEAP32[i5 >> 2] = i54;
michael@0 27086 HEAP32[i11 >> 2] = (HEAP32[i11 >> 2] | 0) + 1;
michael@0 27087 i52 = i52 + 1 | 0;
michael@0 27088 } while (i52 >>> 0 < 128);
michael@0 27089 d38 = -0.0 - +HEAPF32[i49 >> 2];
michael@0 27090 d18 = -0.0 - +HEAPF32[i50 >> 2];
michael@0 27091 HEAPF32[i13 >> 2] = -0.0 - +HEAPF32[i7 >> 2];
michael@0 27092 HEAPF32[i13 + 4 >> 2] = d38;
michael@0 27093 HEAPF32[i13 + 8 >> 2] = d18;
michael@0 27094 HEAPF32[i13 + 12 >> 2] = 0.0;
michael@0 27095 if ((__ZN12gjkepa2_impl3EPA8EvaluateERNS_3GJKERK9btVector3(i12, i10, i13) | 0) == 9) {
michael@0 27096 HEAP32[i15 >> 2] = 3;
michael@0 27097 i51 = 0;
michael@0 27098 STACKTOP = i8;
michael@0 27099 return i51 | 0;
michael@0 27100 }
michael@0 27101 i13 = i12 + 36 | 0;
michael@0 27102 if ((HEAP32[i13 >> 2] | 0) == 0) {
michael@0 27103 d55 = 0.0;
michael@0 27104 d56 = 0.0;
michael@0 27105 d57 = 0.0;
michael@0 27106 } else {
michael@0 27107 i10 = i14 | 0;
michael@0 27108 i7 = i14 + 4 | 0;
michael@0 27109 i50 = i14 + 8 | 0;
michael@0 27110 d18 = 0.0;
michael@0 27111 d38 = 0.0;
michael@0 27112 d20 = 0.0;
michael@0 27113 i49 = 0;
michael@0 27114 while (1) {
michael@0 27115 i52 = HEAP32[i4 >> 2] | 0;
michael@0 27116 i11 = (HEAP32[i17 >> 2] | 0) + (HEAP32[i2 >> 2] | 0) | 0;
michael@0 27117 if ((i52 & 1 | 0) == 0) {
michael@0 27118 i58 = i52;
michael@0 27119 } else {
michael@0 27120 i58 = HEAP32[(HEAP32[i11 >> 2] | 0) + (i52 - 1) >> 2] | 0;
michael@0 27121 }
michael@0 27122 FUNCTION_TABLE_viii[i58 & 127](i14, i11, HEAP32[i12 + 4 + (i49 << 2) >> 2] | 0);
michael@0 27123 d36 = +HEAPF32[i12 + 20 + (i49 << 2) >> 2];
michael@0 27124 d22 = d20 + +HEAPF32[i10 >> 2] * d36;
michael@0 27125 d34 = d38 + d36 * +HEAPF32[i7 >> 2];
michael@0 27126 d31 = d18 + d36 * +HEAPF32[i50 >> 2];
michael@0 27127 i11 = i49 + 1 | 0;
michael@0 27128 if (i11 >>> 0 < (HEAP32[i13 >> 2] | 0) >>> 0) {
michael@0 27129 d18 = d31;
michael@0 27130 d38 = d34;
michael@0 27131 d20 = d22;
michael@0 27132 i49 = i11;
michael@0 27133 } else {
michael@0 27134 d55 = d31;
michael@0 27135 d56 = d34;
michael@0 27136 d57 = d22;
michael@0 27137 break;
michael@0 27138 }
michael@0 27139 }
michael@0 27140 }
michael@0 27141 HEAP32[i15 >> 2] = 1;
michael@0 27142 d20 = +HEAPF32[i47 >> 2] + (d57 * +HEAPF32[i1 >> 2] + d56 * +HEAPF32[i28 >> 2] + d55 * +HEAPF32[i35 >> 2]);
michael@0 27143 d38 = +HEAPF32[i48 >> 2] + (d57 * +HEAPF32[i23 >> 2] + d56 * +HEAPF32[i30 >> 2] + d55 * +HEAPF32[i37 >> 2]);
michael@0 27144 HEAPF32[i6 + 4 >> 2] = +HEAPF32[i46 >> 2] + (d57 * +HEAPF32[i3 >> 2] + d56 * +HEAPF32[i26 >> 2] + d55 * +HEAPF32[i33 >> 2]);
michael@0 27145 HEAPF32[i6 + 8 >> 2] = d20;
michael@0 27146 HEAPF32[i6 + 12 >> 2] = d38;
michael@0 27147 HEAPF32[i6 + 16 >> 2] = 0.0;
michael@0 27148 d38 = +HEAPF32[i9 >> 2];
michael@0 27149 d20 = +HEAPF32[i12 + 56 >> 2];
michael@0 27150 d18 = +HEAPF32[i12 + 44 >> 2];
michael@0 27151 d22 = +HEAPF32[i12 + 48 >> 2];
michael@0 27152 d34 = d57 - d38 * d20;
michael@0 27153 d57 = d56 - d20 * d18;
michael@0 27154 d56 = d55 - d20 * d22;
michael@0 27155 d55 = +HEAPF32[i47 >> 2] + (d34 * +HEAPF32[i1 >> 2] + d57 * +HEAPF32[i28 >> 2] + d56 * +HEAPF32[i35 >> 2]);
michael@0 27156 d31 = +HEAPF32[i48 >> 2] + (d34 * +HEAPF32[i23 >> 2] + d57 * +HEAPF32[i30 >> 2] + d56 * +HEAPF32[i37 >> 2]);
michael@0 27157 HEAPF32[i16 >> 2] = +HEAPF32[i46 >> 2] + (d34 * +HEAPF32[i3 >> 2] + d57 * +HEAPF32[i26 >> 2] + d56 * +HEAPF32[i33 >> 2]);
michael@0 27158 HEAPF32[i6 + 24 >> 2] = d55;
michael@0 27159 HEAPF32[i6 + 28 >> 2] = d31;
michael@0 27160 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 27161 HEAPF32[i6 + 36 >> 2] = -0.0 - d38;
michael@0 27162 HEAPF32[i6 + 40 >> 2] = -0.0 - d18;
michael@0 27163 HEAPF32[i6 + 44 >> 2] = -0.0 - d22;
michael@0 27164 HEAPF32[i6 + 48 >> 2] = 0.0;
michael@0 27165 HEAPF32[i6 + 52 >> 2] = -0.0 - d20;
michael@0 27166 i51 = 1;
michael@0 27167 STACKTOP = i8;
michael@0 27168 return i51 | 0;
michael@0 27169 } else {
michael@0 27170 i51 = 0;
michael@0 27171 STACKTOP = i8;
michael@0 27172 return i51 | 0;
michael@0 27173 }
michael@0 27174 return 0;
michael@0 27175 }
michael@0 27176 function __ZN22btVoronoiSimplexSolver25closestPtPointTetrahedronERK9btVector3S2_S2_S2_S2_R25btSubSimplexClosestResult(i1, i2, i3, i4, i5, i6, i7) {
michael@0 27177 i1 = i1 | 0;
michael@0 27178 i2 = i2 | 0;
michael@0 27179 i3 = i3 | 0;
michael@0 27180 i4 = i4 | 0;
michael@0 27181 i5 = i5 | 0;
michael@0 27182 i6 = i6 | 0;
michael@0 27183 i7 = i7 | 0;
michael@0 27184 var i8 = 0, i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, d42 = 0.0, d43 = 0.0, d44 = 0.0;
michael@0 27185 i1 = STACKTOP;
michael@0 27186 STACKTOP = STACKTOP + 40 | 0;
michael@0 27187 i8 = i1 | 0;
michael@0 27188 i9 = i8 + 16 | 0;
michael@0 27189 HEAP16[i9 >> 1] = 0;
michael@0 27190 i10 = i7;
michael@0 27191 i11 = i2;
michael@0 27192 HEAP32[i10 >> 2] = HEAP32[i11 >> 2];
michael@0 27193 HEAP32[i10 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 27194 HEAP32[i10 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 27195 HEAP32[i10 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 27196 i11 = i7 + 16 | 0;
michael@0 27197 HEAP16[i11 >> 1] = HEAP16[i11 >> 1] | 15;
michael@0 27198 d12 = +HEAPF32[i4 >> 2];
michael@0 27199 d13 = +HEAPF32[i3 >> 2];
michael@0 27200 d14 = d12 - d13;
michael@0 27201 d15 = +HEAPF32[i4 + 4 >> 2];
michael@0 27202 d16 = +HEAPF32[i3 + 4 >> 2];
michael@0 27203 d17 = d15 - d16;
michael@0 27204 d18 = +HEAPF32[i4 + 8 >> 2];
michael@0 27205 d19 = +HEAPF32[i3 + 8 >> 2];
michael@0 27206 d20 = d18 - d19;
michael@0 27207 d21 = +HEAPF32[i5 >> 2];
michael@0 27208 d22 = d21 - d13;
michael@0 27209 d23 = +HEAPF32[i5 + 4 >> 2];
michael@0 27210 d24 = d23 - d16;
michael@0 27211 d25 = +HEAPF32[i5 + 8 >> 2];
michael@0 27212 d26 = d25 - d19;
michael@0 27213 d27 = d17 * d26 - d20 * d24;
michael@0 27214 d28 = d20 * d22 - d14 * d26;
michael@0 27215 d29 = d14 * d24 - d17 * d22;
michael@0 27216 d30 = +HEAPF32[i6 >> 2];
michael@0 27217 d31 = d30 - d13;
michael@0 27218 d32 = +HEAPF32[i6 + 4 >> 2];
michael@0 27219 d33 = d32 - d16;
michael@0 27220 d34 = +HEAPF32[i6 + 8 >> 2];
michael@0 27221 d35 = d34 - d19;
michael@0 27222 d36 = d31 * d27 + d33 * d28 + d29 * d35;
michael@0 27223 if (d36 * d36 < 9.99999905104687e-9) {
michael@0 27224 i37 = -1;
michael@0 27225 } else {
michael@0 27226 i37 = d36 * (d28 * (+HEAPF32[i2 + 4 >> 2] - d16) + d27 * (+HEAPF32[i2 >> 2] - d13) + d29 * (+HEAPF32[i2 + 8 >> 2] - d19)) < 0.0 | 0;
michael@0 27227 }
michael@0 27228 d29 = d24 * d35 - d26 * d33;
michael@0 27229 d27 = d26 * d31 - d22 * d35;
michael@0 27230 d28 = d22 * d33 - d24 * d31;
michael@0 27231 d36 = d14 * d29 + d17 * d27 + d28 * d20;
michael@0 27232 if (d36 * d36 < 9.99999905104687e-9) {
michael@0 27233 i38 = -1;
michael@0 27234 } else {
michael@0 27235 i38 = d36 * (d27 * (+HEAPF32[i2 + 4 >> 2] - d16) + d29 * (+HEAPF32[i2 >> 2] - d13) + d28 * (+HEAPF32[i2 + 8 >> 2] - d19)) < 0.0 | 0;
michael@0 27236 }
michael@0 27237 d28 = d33 * d20 - d35 * d17;
michael@0 27238 d29 = d35 * d14 - d31 * d20;
michael@0 27239 d20 = d31 * d17 - d33 * d14;
michael@0 27240 d14 = d22 * d28 + d24 * d29 + d20 * d26;
michael@0 27241 if (d14 * d14 < 9.99999905104687e-9) {
michael@0 27242 i39 = -1;
michael@0 27243 } else {
michael@0 27244 i39 = d14 * (d29 * (+HEAPF32[i2 + 4 >> 2] - d16) + d28 * (+HEAPF32[i2 >> 2] - d13) + d20 * (+HEAPF32[i2 + 8 >> 2] - d19)) < 0.0 | 0;
michael@0 27245 }
michael@0 27246 d20 = d30 - d12;
michael@0 27247 d30 = d32 - d15;
michael@0 27248 d32 = d34 - d18;
michael@0 27249 d34 = d21 - d12;
michael@0 27250 d21 = d23 - d15;
michael@0 27251 d23 = d25 - d18;
michael@0 27252 d25 = d30 * d23 - d32 * d21;
michael@0 27253 d28 = d32 * d34 - d20 * d23;
michael@0 27254 d23 = d20 * d21 - d30 * d34;
michael@0 27255 d34 = (d13 - d12) * d25 + (d16 - d15) * d28 + d23 * (d19 - d18);
michael@0 27256 if (d34 * d34 < 9.99999905104687e-9) {
michael@0 27257 i40 = -1;
michael@0 27258 } else {
michael@0 27259 i40 = d34 * (d28 * (+HEAPF32[i2 + 4 >> 2] - d15) + d25 * (+HEAPF32[i2 >> 2] - d12) + d23 * (+HEAPF32[i2 + 8 >> 2] - d18)) < 0.0 | 0;
michael@0 27260 }
michael@0 27261 if ((i38 | i37 | i39 | i40 | 0) < 0) {
michael@0 27262 HEAP8[i7 + 36 | 0] = 1;
michael@0 27263 i41 = 0;
michael@0 27264 STACKTOP = i1;
michael@0 27265 return i41 | 0;
michael@0 27266 }
michael@0 27267 i10 = (i37 | 0) != 0;
michael@0 27268 i37 = (i38 | 0) == 0;
michael@0 27269 i38 = (i39 | 0) == 0;
michael@0 27270 i39 = (i40 | 0) == 0;
michael@0 27271 if (i37 & (i10 ^ 1) & i38 & i39) {
michael@0 27272 i41 = 0;
michael@0 27273 STACKTOP = i1;
michael@0 27274 return i41 | 0;
michael@0 27275 }
michael@0 27276 do {
michael@0 27277 if (i10) {
michael@0 27278 __ZN22btVoronoiSimplexSolver22closestPtPointTriangleERK9btVector3S2_S2_S2_R25btSubSimplexClosestResult(0, i2, i3, i4, i5, i8) | 0;
michael@0 27279 d18 = +HEAPF32[i8 >> 2];
michael@0 27280 d23 = +HEAPF32[i8 + 4 >> 2];
michael@0 27281 d12 = +HEAPF32[i8 + 8 >> 2];
michael@0 27282 d25 = d18 - +HEAPF32[i2 >> 2];
michael@0 27283 d15 = d23 - +HEAPF32[i2 + 4 >> 2];
michael@0 27284 d28 = d12 - +HEAPF32[i2 + 8 >> 2];
michael@0 27285 d34 = d25 * d25 + d15 * d15 + d28 * d28;
michael@0 27286 if (d34 >= 3.4028234663852886e+38) {
michael@0 27287 d42 = 3.4028234663852886e+38;
michael@0 27288 break;
michael@0 27289 }
michael@0 27290 d28 = +HEAPF32[i8 + 12 >> 2];
michael@0 27291 HEAPF32[i7 >> 2] = d18;
michael@0 27292 HEAPF32[i7 + 4 >> 2] = d23;
michael@0 27293 HEAPF32[i7 + 8 >> 2] = d12;
michael@0 27294 HEAPF32[i7 + 12 >> 2] = d28;
michael@0 27295 i40 = HEAP16[i9 >> 1] | 0;
michael@0 27296 HEAP16[i11 >> 1] = i40 & 1 | HEAP16[i11 >> 1] & -16 | i40 & 2 | i40 & 4;
michael@0 27297 d28 = +HEAPF32[i8 + 24 >> 2];
michael@0 27298 d12 = +HEAPF32[i8 + 28 >> 2];
michael@0 27299 HEAPF32[i7 + 20 >> 2] = +HEAPF32[i8 + 20 >> 2];
michael@0 27300 HEAPF32[i7 + 24 >> 2] = d28;
michael@0 27301 HEAPF32[i7 + 28 >> 2] = d12;
michael@0 27302 HEAPF32[i7 + 32 >> 2] = 0.0;
michael@0 27303 d42 = d34;
michael@0 27304 } else {
michael@0 27305 d42 = 3.4028234663852886e+38;
michael@0 27306 }
michael@0 27307 } while (0);
michael@0 27308 do {
michael@0 27309 if (i37) {
michael@0 27310 d43 = d42;
michael@0 27311 } else {
michael@0 27312 __ZN22btVoronoiSimplexSolver22closestPtPointTriangleERK9btVector3S2_S2_S2_R25btSubSimplexClosestResult(0, i2, i3, i5, i6, i8) | 0;
michael@0 27313 d34 = +HEAPF32[i8 >> 2];
michael@0 27314 d12 = +HEAPF32[i8 + 4 >> 2];
michael@0 27315 d28 = +HEAPF32[i8 + 8 >> 2];
michael@0 27316 d23 = d34 - +HEAPF32[i2 >> 2];
michael@0 27317 d18 = d12 - +HEAPF32[i2 + 4 >> 2];
michael@0 27318 d15 = d28 - +HEAPF32[i2 + 8 >> 2];
michael@0 27319 d25 = d23 * d23 + d18 * d18 + d15 * d15;
michael@0 27320 if (d25 >= d42) {
michael@0 27321 d43 = d42;
michael@0 27322 break;
michael@0 27323 }
michael@0 27324 d15 = +HEAPF32[i8 + 12 >> 2];
michael@0 27325 HEAPF32[i7 >> 2] = d34;
michael@0 27326 HEAPF32[i7 + 4 >> 2] = d12;
michael@0 27327 HEAPF32[i7 + 8 >> 2] = d28;
michael@0 27328 HEAPF32[i7 + 12 >> 2] = d15;
michael@0 27329 i10 = HEAP16[i9 >> 1] | 0;
michael@0 27330 HEAP16[i11 >> 1] = i10 & 1 | HEAP16[i11 >> 1] & -16 | (i10 & 65535) >>> 1 << 2 & 4 | (i10 & 65535) >>> 2 << 3 & 8;
michael@0 27331 d15 = +HEAPF32[i8 + 24 >> 2];
michael@0 27332 d28 = +HEAPF32[i8 + 28 >> 2];
michael@0 27333 HEAPF32[i7 + 20 >> 2] = +HEAPF32[i8 + 20 >> 2];
michael@0 27334 HEAPF32[i7 + 24 >> 2] = 0.0;
michael@0 27335 HEAPF32[i7 + 28 >> 2] = d15;
michael@0 27336 HEAPF32[i7 + 32 >> 2] = d28;
michael@0 27337 d43 = d25;
michael@0 27338 }
michael@0 27339 } while (0);
michael@0 27340 do {
michael@0 27341 if (i38) {
michael@0 27342 d44 = d43;
michael@0 27343 } else {
michael@0 27344 __ZN22btVoronoiSimplexSolver22closestPtPointTriangleERK9btVector3S2_S2_S2_R25btSubSimplexClosestResult(0, i2, i3, i6, i4, i8) | 0;
michael@0 27345 d42 = +HEAPF32[i8 >> 2];
michael@0 27346 d25 = +HEAPF32[i8 + 4 >> 2];
michael@0 27347 d28 = +HEAPF32[i8 + 8 >> 2];
michael@0 27348 d15 = d42 - +HEAPF32[i2 >> 2];
michael@0 27349 d12 = d25 - +HEAPF32[i2 + 4 >> 2];
michael@0 27350 d34 = d28 - +HEAPF32[i2 + 8 >> 2];
michael@0 27351 d18 = d15 * d15 + d12 * d12 + d34 * d34;
michael@0 27352 if (d18 >= d43) {
michael@0 27353 d44 = d43;
michael@0 27354 break;
michael@0 27355 }
michael@0 27356 d34 = +HEAPF32[i8 + 12 >> 2];
michael@0 27357 HEAPF32[i7 >> 2] = d42;
michael@0 27358 HEAPF32[i7 + 4 >> 2] = d25;
michael@0 27359 HEAPF32[i7 + 8 >> 2] = d28;
michael@0 27360 HEAPF32[i7 + 12 >> 2] = d34;
michael@0 27361 i37 = HEAP16[i9 >> 1] | 0;
michael@0 27362 HEAP16[i11 >> 1] = i37 & 1 | HEAP16[i11 >> 1] & -16 | (i37 & 65535) >>> 2 << 1 & 2 | (i37 & 65535) >>> 1 << 3 & 8;
michael@0 27363 d34 = +HEAPF32[i8 + 28 >> 2];
michael@0 27364 d28 = +HEAPF32[i8 + 24 >> 2];
michael@0 27365 HEAPF32[i7 + 20 >> 2] = +HEAPF32[i8 + 20 >> 2];
michael@0 27366 HEAPF32[i7 + 24 >> 2] = d34;
michael@0 27367 HEAPF32[i7 + 28 >> 2] = 0.0;
michael@0 27368 HEAPF32[i7 + 32 >> 2] = d28;
michael@0 27369 d44 = d18;
michael@0 27370 }
michael@0 27371 } while (0);
michael@0 27372 if (i39) {
michael@0 27373 i41 = 1;
michael@0 27374 STACKTOP = i1;
michael@0 27375 return i41 | 0;
michael@0 27376 }
michael@0 27377 __ZN22btVoronoiSimplexSolver22closestPtPointTriangleERK9btVector3S2_S2_S2_R25btSubSimplexClosestResult(0, i2, i4, i6, i5, i8) | 0;
michael@0 27378 d43 = +HEAPF32[i8 >> 2];
michael@0 27379 d18 = +HEAPF32[i8 + 4 >> 2];
michael@0 27380 d28 = +HEAPF32[i8 + 8 >> 2];
michael@0 27381 d34 = d43 - +HEAPF32[i2 >> 2];
michael@0 27382 d25 = d18 - +HEAPF32[i2 + 4 >> 2];
michael@0 27383 d42 = d28 - +HEAPF32[i2 + 8 >> 2];
michael@0 27384 if (d34 * d34 + d25 * d25 + d42 * d42 >= d44) {
michael@0 27385 i41 = 1;
michael@0 27386 STACKTOP = i1;
michael@0 27387 return i41 | 0;
michael@0 27388 }
michael@0 27389 d44 = +HEAPF32[i8 + 12 >> 2];
michael@0 27390 HEAPF32[i7 >> 2] = d43;
michael@0 27391 HEAPF32[i7 + 4 >> 2] = d18;
michael@0 27392 HEAPF32[i7 + 8 >> 2] = d28;
michael@0 27393 HEAPF32[i7 + 12 >> 2] = d44;
michael@0 27394 i2 = HEAP16[i9 >> 1] | 0;
michael@0 27395 HEAP16[i11 >> 1] = i2 & 4 | HEAP16[i11 >> 1] & -16 | i2 << 1 & 2 | (i2 & 65535) >>> 1 << 3 & 8;
michael@0 27396 d44 = +HEAPF32[i8 + 20 >> 2];
michael@0 27397 d28 = +HEAPF32[i8 + 28 >> 2];
michael@0 27398 d18 = +HEAPF32[i8 + 24 >> 2];
michael@0 27399 HEAPF32[i7 + 20 >> 2] = 0.0;
michael@0 27400 HEAPF32[i7 + 24 >> 2] = d44;
michael@0 27401 HEAPF32[i7 + 28 >> 2] = d28;
michael@0 27402 HEAPF32[i7 + 32 >> 2] = d18;
michael@0 27403 i41 = 1;
michael@0 27404 STACKTOP = i1;
michael@0 27405 return i41 | 0;
michael@0 27406 }
michael@0 27407 function __ZN35btSequentialImpulseConstraintSolver20solveSingleIterationEiPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 27408 i1 = i1 | 0;
michael@0 27409 i2 = i2 | 0;
michael@0 27410 i3 = i3 | 0;
michael@0 27411 i4 = i4 | 0;
michael@0 27412 i5 = i5 | 0;
michael@0 27413 i6 = i6 | 0;
michael@0 27414 i7 = i7 | 0;
michael@0 27415 i8 = i8 | 0;
michael@0 27416 i9 = i9 | 0;
michael@0 27417 i10 = i10 | 0;
michael@0 27418 i11 = i11 | 0;
michael@0 27419 var i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, d27 = 0.0, d28 = 0.0;
michael@0 27420 i11 = i1 + 8 | 0;
michael@0 27421 i10 = HEAP32[i11 >> 2] | 0;
michael@0 27422 i6 = i1 + 48 | 0;
michael@0 27423 i5 = HEAP32[i6 >> 2] | 0;
michael@0 27424 i4 = i9 + 60 | 0;
michael@0 27425 i3 = HEAP32[i4 >> 2] | 0;
michael@0 27426 do {
michael@0 27427 if ((i3 & 1 | 0) == 0) {
michael@0 27428 i12 = i3;
michael@0 27429 } else {
michael@0 27430 if ((i2 & 7 | 0) != 0) {
michael@0 27431 i12 = i3;
michael@0 27432 break;
michael@0 27433 }
michael@0 27434 if ((i10 | 0) > 0) {
michael@0 27435 i13 = HEAP32[i1 + 76 >> 2] | 0;
michael@0 27436 i14 = i1 + 124 | 0;
michael@0 27437 i15 = 0;
michael@0 27438 i16 = HEAP32[i14 >> 2] | 0;
michael@0 27439 do {
michael@0 27440 i17 = i13 + (i15 << 2) | 0;
michael@0 27441 i18 = HEAP32[i17 >> 2] | 0;
michael@0 27442 i15 = i15 + 1 | 0;
michael@0 27443 i16 = (Math_imul(i16, 1664525) | 0) + 1013904223 | 0;
michael@0 27444 do {
michael@0 27445 if (i15 >>> 0 < 65537) {
michael@0 27446 i19 = i16 >>> 16 ^ i16;
michael@0 27447 if (i15 >>> 0 >= 257) {
michael@0 27448 i20 = i19;
michael@0 27449 break;
michael@0 27450 }
michael@0 27451 i21 = i19 >>> 8 ^ i19;
michael@0 27452 if (i15 >>> 0 >= 17) {
michael@0 27453 i20 = i21;
michael@0 27454 break;
michael@0 27455 }
michael@0 27456 i19 = i21 >>> 4 ^ i21;
michael@0 27457 if (i15 >>> 0 >= 5) {
michael@0 27458 i20 = i19;
michael@0 27459 break;
michael@0 27460 }
michael@0 27461 i21 = i19 >>> 2 ^ i19;
michael@0 27462 if (i15 >>> 0 >= 3) {
michael@0 27463 i20 = i21;
michael@0 27464 break;
michael@0 27465 }
michael@0 27466 i20 = i21 >>> 1 ^ i21;
michael@0 27467 } else {
michael@0 27468 i20 = i16;
michael@0 27469 }
michael@0 27470 } while (0);
michael@0 27471 i21 = i13 + (((i20 >>> 0) % (i15 >>> 0) | 0) << 2) | 0;
michael@0 27472 HEAP32[i17 >> 2] = HEAP32[i21 >> 2];
michael@0 27473 HEAP32[i21 >> 2] = i18;
michael@0 27474 } while ((i15 | 0) < (i10 | 0));
michael@0 27475 HEAP32[i14 >> 2] = i16;
michael@0 27476 }
michael@0 27477 if ((i5 | 0) > 0) {
michael@0 27478 i15 = HEAP32[i1 + 96 >> 2] | 0;
michael@0 27479 i13 = i1 + 124 | 0;
michael@0 27480 i21 = 0;
michael@0 27481 i19 = HEAP32[i13 >> 2] | 0;
michael@0 27482 do {
michael@0 27483 i22 = i15 + (i21 << 2) | 0;
michael@0 27484 i23 = HEAP32[i22 >> 2] | 0;
michael@0 27485 i21 = i21 + 1 | 0;
michael@0 27486 i19 = (Math_imul(i19, 1664525) | 0) + 1013904223 | 0;
michael@0 27487 do {
michael@0 27488 if (i21 >>> 0 < 65537) {
michael@0 27489 i24 = i19 >>> 16 ^ i19;
michael@0 27490 if (i21 >>> 0 >= 257) {
michael@0 27491 i25 = i24;
michael@0 27492 break;
michael@0 27493 }
michael@0 27494 i26 = i24 >>> 8 ^ i24;
michael@0 27495 if (i21 >>> 0 >= 17) {
michael@0 27496 i25 = i26;
michael@0 27497 break;
michael@0 27498 }
michael@0 27499 i24 = i26 >>> 4 ^ i26;
michael@0 27500 if (i21 >>> 0 >= 5) {
michael@0 27501 i25 = i24;
michael@0 27502 break;
michael@0 27503 }
michael@0 27504 i26 = i24 >>> 2 ^ i24;
michael@0 27505 if (i21 >>> 0 >= 3) {
michael@0 27506 i25 = i26;
michael@0 27507 break;
michael@0 27508 }
michael@0 27509 i25 = i26 >>> 1 ^ i26;
michael@0 27510 } else {
michael@0 27511 i25 = i19;
michael@0 27512 }
michael@0 27513 } while (0);
michael@0 27514 i18 = i15 + (((i25 >>> 0) % (i21 >>> 0) | 0) << 2) | 0;
michael@0 27515 HEAP32[i22 >> 2] = HEAP32[i18 >> 2];
michael@0 27516 HEAP32[i18 >> 2] = i23;
michael@0 27517 } while ((i21 | 0) < (i5 | 0));
michael@0 27518 HEAP32[i13 >> 2] = i19;
michael@0 27519 }
michael@0 27520 i12 = HEAP32[i4 >> 2] | 0;
michael@0 27521 }
michael@0 27522 } while (0);
michael@0 27523 i4 = i1 + 28 | 0;
michael@0 27524 i5 = (HEAP32[i4 >> 2] | 0) > 0;
michael@0 27525 if ((i12 & 256 | 0) == 0) {
michael@0 27526 if (i5) {
michael@0 27527 i12 = i1 + 36 | 0;
michael@0 27528 i25 = 0;
michael@0 27529 do {
michael@0 27530 i10 = HEAP32[i12 >> 2] | 0;
michael@0 27531 __ZN35btSequentialImpulseConstraintSolver33resolveSingleConstraintRowGenericER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i10 + (i25 * 136 | 0) + 104 >> 2] | 0, HEAP32[i10 + (i25 * 136 | 0) + 108 >> 2] | 0, i10 + (i25 * 136 | 0) | 0);
michael@0 27532 i25 = i25 + 1 | 0;
michael@0 27533 } while ((i25 | 0) < (HEAP32[i4 >> 2] | 0));
michael@0 27534 }
michael@0 27535 if ((i8 | 0) > 0) {
michael@0 27536 i25 = i9 + 12 | 0;
michael@0 27537 i12 = 0;
michael@0 27538 do {
michael@0 27539 i10 = HEAP32[i7 + (i12 << 2) >> 2] | 0;
michael@0 27540 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i10 >> 2] | 0) + 24 >> 2] & 15](i10, HEAP32[i10 + 24 >> 2] | 0, HEAP32[i10 + 28 >> 2] | 0, +HEAPF32[i25 >> 2]);
michael@0 27541 i12 = i12 + 1 | 0;
michael@0 27542 } while ((i12 | 0) < (i8 | 0));
michael@0 27543 }
michael@0 27544 i12 = HEAP32[i11 >> 2] | 0;
michael@0 27545 if ((i12 | 0) > 0) {
michael@0 27546 i25 = i1 + 76 | 0;
michael@0 27547 i10 = i1 + 16 | 0;
michael@0 27548 i20 = 0;
michael@0 27549 do {
michael@0 27550 i3 = HEAP32[(HEAP32[i25 >> 2] | 0) + (i20 << 2) >> 2] | 0;
michael@0 27551 i2 = HEAP32[i10 >> 2] | 0;
michael@0 27552 __ZN35btSequentialImpulseConstraintSolver36resolveSingleConstraintRowLowerLimitER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i2 + (i3 * 136 | 0) + 104 >> 2] | 0, HEAP32[i2 + (i3 * 136 | 0) + 108 >> 2] | 0, i2 + (i3 * 136 | 0) | 0);
michael@0 27553 i20 = i20 + 1 | 0;
michael@0 27554 } while ((i20 | 0) < (i12 | 0));
michael@0 27555 }
michael@0 27556 i12 = HEAP32[i6 >> 2] | 0;
michael@0 27557 if ((i12 | 0) <= 0) {
michael@0 27558 return +0.0;
michael@0 27559 }
michael@0 27560 i20 = i1 + 96 | 0;
michael@0 27561 i10 = i1 + 56 | 0;
michael@0 27562 i25 = i1 + 16 | 0;
michael@0 27563 i3 = 0;
michael@0 27564 do {
michael@0 27565 i2 = HEAP32[(HEAP32[i20 >> 2] | 0) + (i3 << 2) >> 2] | 0;
michael@0 27566 i21 = HEAP32[i10 >> 2] | 0;
michael@0 27567 d27 = +HEAPF32[(HEAP32[i25 >> 2] | 0) + ((HEAP32[i21 + (i2 * 136 | 0) + 100 >> 2] | 0) * 136 | 0) + 84 >> 2];
michael@0 27568 if (d27 > 0.0) {
michael@0 27569 d28 = d27 * +HEAPF32[i21 + (i2 * 136 | 0) + 88 >> 2];
michael@0 27570 HEAPF32[i21 + (i2 * 136 | 0) + 124 >> 2] = -0.0 - d28;
michael@0 27571 HEAPF32[i21 + (i2 * 136 | 0) + 128 >> 2] = d28;
michael@0 27572 __ZN35btSequentialImpulseConstraintSolver33resolveSingleConstraintRowGenericER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i21 + (i2 * 136 | 0) + 104 >> 2] | 0, HEAP32[i21 + (i2 * 136 | 0) + 108 >> 2] | 0, i21 + (i2 * 136 | 0) | 0);
michael@0 27573 }
michael@0 27574 i3 = i3 + 1 | 0;
michael@0 27575 } while ((i3 | 0) < (i12 | 0));
michael@0 27576 return +0.0;
michael@0 27577 } else {
michael@0 27578 if (i5) {
michael@0 27579 i5 = i1 + 36 | 0;
michael@0 27580 i12 = 0;
michael@0 27581 do {
michael@0 27582 i3 = HEAP32[i5 >> 2] | 0;
michael@0 27583 __ZN35btSequentialImpulseConstraintSolver33resolveSingleConstraintRowGenericER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i3 + (i12 * 136 | 0) + 104 >> 2] | 0, HEAP32[i3 + (i12 * 136 | 0) + 108 >> 2] | 0, i3 + (i12 * 136 | 0) | 0);
michael@0 27584 i12 = i12 + 1 | 0;
michael@0 27585 } while ((i12 | 0) < (HEAP32[i4 >> 2] | 0));
michael@0 27586 }
michael@0 27587 if ((i8 | 0) > 0) {
michael@0 27588 i4 = i9 + 12 | 0;
michael@0 27589 i9 = 0;
michael@0 27590 do {
michael@0 27591 i12 = HEAP32[i7 + (i9 << 2) >> 2] | 0;
michael@0 27592 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i12 >> 2] | 0) + 24 >> 2] & 15](i12, HEAP32[i12 + 24 >> 2] | 0, HEAP32[i12 + 28 >> 2] | 0, +HEAPF32[i4 >> 2]);
michael@0 27593 i9 = i9 + 1 | 0;
michael@0 27594 } while ((i9 | 0) < (i8 | 0));
michael@0 27595 }
michael@0 27596 i8 = HEAP32[i11 >> 2] | 0;
michael@0 27597 if ((i8 | 0) > 0) {
michael@0 27598 i11 = i1 + 76 | 0;
michael@0 27599 i9 = i1 + 16 | 0;
michael@0 27600 i4 = 0;
michael@0 27601 do {
michael@0 27602 i7 = HEAP32[(HEAP32[i11 >> 2] | 0) + (i4 << 2) >> 2] | 0;
michael@0 27603 i12 = HEAP32[i9 >> 2] | 0;
michael@0 27604 __ZN35btSequentialImpulseConstraintSolver36resolveSingleConstraintRowLowerLimitER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i12 + (i7 * 136 | 0) + 104 >> 2] | 0, HEAP32[i12 + (i7 * 136 | 0) + 108 >> 2] | 0, i12 + (i7 * 136 | 0) | 0);
michael@0 27605 i4 = i4 + 1 | 0;
michael@0 27606 } while ((i4 | 0) < (i8 | 0));
michael@0 27607 }
michael@0 27608 i8 = HEAP32[i6 >> 2] | 0;
michael@0 27609 if ((i8 | 0) <= 0) {
michael@0 27610 return +0.0;
michael@0 27611 }
michael@0 27612 i6 = i1 + 96 | 0;
michael@0 27613 i4 = i1 + 56 | 0;
michael@0 27614 i9 = i1 + 16 | 0;
michael@0 27615 i1 = 0;
michael@0 27616 do {
michael@0 27617 i11 = HEAP32[(HEAP32[i6 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 27618 i7 = HEAP32[i4 >> 2] | 0;
michael@0 27619 d28 = +HEAPF32[(HEAP32[i9 >> 2] | 0) + ((HEAP32[i7 + (i11 * 136 | 0) + 100 >> 2] | 0) * 136 | 0) + 84 >> 2];
michael@0 27620 if (d28 > 0.0) {
michael@0 27621 d27 = d28 * +HEAPF32[i7 + (i11 * 136 | 0) + 88 >> 2];
michael@0 27622 HEAPF32[i7 + (i11 * 136 | 0) + 124 >> 2] = -0.0 - d27;
michael@0 27623 HEAPF32[i7 + (i11 * 136 | 0) + 128 >> 2] = d27;
michael@0 27624 __ZN35btSequentialImpulseConstraintSolver33resolveSingleConstraintRowGenericER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i7 + (i11 * 136 | 0) + 104 >> 2] | 0, HEAP32[i7 + (i11 * 136 | 0) + 108 >> 2] | 0, i7 + (i11 * 136 | 0) | 0);
michael@0 27625 }
michael@0 27626 i1 = i1 + 1 | 0;
michael@0 27627 } while ((i1 | 0) < (i8 | 0));
michael@0 27628 return +0.0;
michael@0 27629 }
michael@0 27630 return 0.0;
michael@0 27631 }
michael@0 27632 function __ZN27btContinuousConvexCollision20computeClosestPointsERK11btTransformS2_R16btPointCollector(i1, i2, i3, i4) {
michael@0 27633 i1 = i1 | 0;
michael@0 27634 i2 = i2 | 0;
michael@0 27635 i3 = i3 | 0;
michael@0 27636 i4 = i4 | 0;
michael@0 27637 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, i45 = 0, d46 = 0.0, i47 = 0, d48 = 0.0, i49 = 0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, i58 = 0, i59 = 0, i60 = 0, i61 = 0;
michael@0 27638 i5 = STACKTOP;
michael@0 27639 STACKTOP = STACKTOP + 280 | 0;
michael@0 27640 i6 = i5 | 0;
michael@0 27641 i7 = i5 + 80 | 0;
michael@0 27642 i8 = i5 + 216 | 0;
michael@0 27643 i9 = i5 + 232 | 0;
michael@0 27644 i10 = i5 + 248 | 0;
michael@0 27645 i11 = i5 + 264 | 0;
michael@0 27646 i12 = i1 + 16 | 0;
michael@0 27647 if ((HEAP32[i12 >> 2] | 0) == 0) {
michael@0 27648 i13 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 27649 i14 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 27650 d15 = +HEAPF32[i2 >> 2];
michael@0 27651 d16 = +HEAPF32[i2 + 4 >> 2];
michael@0 27652 d17 = +HEAPF32[i2 + 8 >> 2];
michael@0 27653 d18 = +HEAPF32[i2 + 16 >> 2];
michael@0 27654 d19 = +HEAPF32[i2 + 20 >> 2];
michael@0 27655 d20 = +HEAPF32[i2 + 24 >> 2];
michael@0 27656 d21 = +HEAPF32[i2 + 32 >> 2];
michael@0 27657 d22 = +HEAPF32[i2 + 36 >> 2];
michael@0 27658 d23 = +HEAPF32[i2 + 40 >> 2];
michael@0 27659 d24 = +HEAPF32[i2 + 48 >> 2];
michael@0 27660 d25 = +HEAPF32[i2 + 52 >> 2];
michael@0 27661 d26 = +HEAPF32[i2 + 56 >> 2];
michael@0 27662 i27 = i3 | 0;
michael@0 27663 i28 = i3 + 16 | 0;
michael@0 27664 i29 = i3 + 32 | 0;
michael@0 27665 i30 = i3 + 4 | 0;
michael@0 27666 i31 = i3 + 20 | 0;
michael@0 27667 i32 = i3 + 36 | 0;
michael@0 27668 i33 = i3 + 8 | 0;
michael@0 27669 i34 = i3 + 24 | 0;
michael@0 27670 i35 = i3 + 40 | 0;
michael@0 27671 d36 = +HEAPF32[i27 >> 2];
michael@0 27672 d37 = +HEAPF32[i28 >> 2];
michael@0 27673 d38 = +HEAPF32[i29 >> 2];
michael@0 27674 d39 = +HEAPF32[i30 >> 2];
michael@0 27675 d40 = +HEAPF32[i31 >> 2];
michael@0 27676 d41 = +HEAPF32[i32 >> 2];
michael@0 27677 d42 = +HEAPF32[i33 >> 2];
michael@0 27678 d43 = +HEAPF32[i34 >> 2];
michael@0 27679 d44 = +HEAPF32[i35 >> 2];
michael@0 27680 i45 = i3 + 48 | 0;
michael@0 27681 d46 = -0.0 - +HEAPF32[i45 >> 2];
michael@0 27682 i47 = i3 + 52 | 0;
michael@0 27683 d48 = -0.0 - +HEAPF32[i47 >> 2];
michael@0 27684 i49 = i3 + 56 | 0;
michael@0 27685 d50 = -0.0 - +HEAPF32[i49 >> 2];
michael@0 27686 d51 = d15 * d36 + d18 * d37 + d21 * d38;
michael@0 27687 d52 = d16 * d36 + d19 * d37 + d22 * d38;
michael@0 27688 d53 = d17 * d36 + d20 * d37 + d23 * d38;
michael@0 27689 d54 = d15 * d39 + d18 * d40 + d21 * d41;
michael@0 27690 d55 = d16 * d39 + d19 * d40 + d22 * d41;
michael@0 27691 d56 = d17 * d39 + d20 * d40 + d23 * d41;
michael@0 27692 d57 = d15 * d42 + d18 * d43 + d21 * d44;
michael@0 27693 d21 = d16 * d42 + d19 * d43 + d22 * d44;
michael@0 27694 d22 = d17 * d42 + d20 * d43 + d23 * d44;
michael@0 27695 i58 = HEAP32[(HEAP32[i13 >> 2] | 0) + 60 >> 2] | 0;
michael@0 27696 i59 = i14 + 48 | 0;
michael@0 27697 d23 = -0.0 - +HEAPF32[i59 >> 2];
michael@0 27698 i60 = i14 + 52 | 0;
michael@0 27699 d20 = -0.0 - +HEAPF32[i60 >> 2];
michael@0 27700 i61 = i14 + 56 | 0;
michael@0 27701 d17 = -0.0 - +HEAPF32[i61 >> 2];
michael@0 27702 HEAPF32[i9 >> 2] = d51 * d23 + d54 * d20 + d57 * d17;
michael@0 27703 HEAPF32[i9 + 4 >> 2] = d52 * d23 + d55 * d20 + d21 * d17;
michael@0 27704 HEAPF32[i9 + 8 >> 2] = d53 * d23 + d56 * d20 + d22 * d17;
michael@0 27705 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 27706 FUNCTION_TABLE_viii[i58 & 127](i8, i13, i9);
michael@0 27707 d17 = +HEAPF32[i8 >> 2];
michael@0 27708 d20 = +HEAPF32[i8 + 4 >> 2];
michael@0 27709 d23 = +HEAPF32[i8 + 8 >> 2];
michael@0 27710 d19 = d24 * d36 + d25 * d37 + d26 * d38 + (d36 * d46 + d37 * d48 + d38 * d50) + (d51 * d17 + d52 * d20 + d53 * d23);
michael@0 27711 d53 = d24 * d39 + d25 * d40 + d26 * d41 + (d39 * d46 + d40 * d48 + d41 * d50) + (d54 * d17 + d55 * d20 + d56 * d23);
michael@0 27712 d56 = d24 * d42 + d25 * d43 + d26 * d44 + (d42 * d46 + d43 * d48 + d44 * d50) + (d57 * d17 + d21 * d20 + d22 * d23);
michael@0 27713 d23 = +HEAPF32[i59 >> 2];
michael@0 27714 d22 = +HEAPF32[i60 >> 2];
michael@0 27715 d20 = +HEAPF32[i61 >> 2];
michael@0 27716 d21 = d20 * d56 + (d23 * d19 + d22 * d53) - +HEAPF32[i14 + 64 >> 2];
michael@0 27717 d17 = d19 - d23 * d21;
michael@0 27718 d23 = d53 - d22 * d21;
michael@0 27719 d22 = d56 - d20 * d21;
michael@0 27720 d20 = +HEAPF32[i27 >> 2];
michael@0 27721 d56 = +HEAPF32[i30 >> 2];
michael@0 27722 d53 = +HEAPF32[i33 >> 2];
michael@0 27723 d19 = +HEAPF32[i28 >> 2];
michael@0 27724 d57 = +HEAPF32[i31 >> 2];
michael@0 27725 d50 = +HEAPF32[i34 >> 2];
michael@0 27726 d44 = +HEAPF32[i47 >> 2] + (d17 * d19 + d23 * d57 + d22 * d50);
michael@0 27727 d48 = +HEAPF32[i29 >> 2];
michael@0 27728 d43 = +HEAPF32[i32 >> 2];
michael@0 27729 d46 = +HEAPF32[i35 >> 2];
michael@0 27730 d42 = +HEAPF32[i49 >> 2] + (d17 * d48 + d23 * d43 + d22 * d46);
michael@0 27731 HEAPF32[i10 >> 2] = +HEAPF32[i45 >> 2] + (d53 * d22 + (d20 * d17 + d56 * d23));
michael@0 27732 HEAPF32[i10 + 4 >> 2] = d44;
michael@0 27733 HEAPF32[i10 + 8 >> 2] = d42;
michael@0 27734 HEAPF32[i10 + 12 >> 2] = 0.0;
michael@0 27735 d42 = +HEAPF32[i59 >> 2];
michael@0 27736 d44 = +HEAPF32[i60 >> 2];
michael@0 27737 d23 = +HEAPF32[i61 >> 2];
michael@0 27738 HEAPF32[i11 >> 2] = d20 * d42 + d56 * d44 + d53 * d23;
michael@0 27739 HEAPF32[i11 + 4 >> 2] = d19 * d42 + d57 * d44 + d50 * d23;
michael@0 27740 HEAPF32[i11 + 8 >> 2] = d48 * d42 + d43 * d44 + d46 * d23;
michael@0 27741 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 27742 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i4 >> 2] | 0) + 16 >> 2] & 15](i4, i11, i10, d21);
michael@0 27743 STACKTOP = i5;
michael@0 27744 return;
michael@0 27745 } else {
michael@0 27746 i10 = i1 + 4 | 0;
michael@0 27747 __ZN22btVoronoiSimplexSolver5resetEv(HEAP32[i10 >> 2] | 0);
michael@0 27748 i11 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 27749 i61 = HEAP32[i12 >> 2] | 0;
michael@0 27750 i60 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 27751 i59 = HEAP32[i61 + 4 >> 2] | 0;
michael@0 27752 d21 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i11 >> 2] | 0) + 44 >> 2] & 7](i11);
michael@0 27753 i45 = HEAP32[i12 >> 2] | 0;
michael@0 27754 d23 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i45 >> 2] | 0) + 44 >> 2] & 7](i45);
michael@0 27755 __ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_iiffP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i6, i11, i61, i60, i59, d21, d23, HEAP32[i10 >> 2] | 0, HEAP32[i1 + 8 >> 2] | 0);
michael@0 27756 HEAPF32[i7 + 128 >> 2] = 999999984306749400.0;
michael@0 27757 HEAP32[i7 + 132 >> 2] = 0;
michael@0 27758 i1 = i7;
michael@0 27759 i10 = i2;
michael@0 27760 HEAP32[i1 >> 2] = HEAP32[i10 >> 2];
michael@0 27761 HEAP32[i1 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 27762 HEAP32[i1 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 27763 HEAP32[i1 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 27764 i10 = i7 + 16 | 0;
michael@0 27765 i1 = i2 + 16 | 0;
michael@0 27766 HEAP32[i10 >> 2] = HEAP32[i1 >> 2];
michael@0 27767 HEAP32[i10 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 27768 HEAP32[i10 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 27769 HEAP32[i10 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 27770 i1 = i7 + 32 | 0;
michael@0 27771 i10 = i2 + 32 | 0;
michael@0 27772 HEAP32[i1 >> 2] = HEAP32[i10 >> 2];
michael@0 27773 HEAP32[i1 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 27774 HEAP32[i1 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 27775 HEAP32[i1 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 27776 i10 = i7 + 48 | 0;
michael@0 27777 i1 = i2 + 48 | 0;
michael@0 27778 HEAP32[i10 >> 2] = HEAP32[i1 >> 2];
michael@0 27779 HEAP32[i10 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 27780 HEAP32[i10 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 27781 HEAP32[i10 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 27782 i1 = i7 + 64 | 0;
michael@0 27783 i10 = i3;
michael@0 27784 HEAP32[i1 >> 2] = HEAP32[i10 >> 2];
michael@0 27785 HEAP32[i1 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 27786 HEAP32[i1 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 27787 HEAP32[i1 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 27788 i10 = i7 + 80 | 0;
michael@0 27789 i1 = i3 + 16 | 0;
michael@0 27790 HEAP32[i10 >> 2] = HEAP32[i1 >> 2];
michael@0 27791 HEAP32[i10 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 27792 HEAP32[i10 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 27793 HEAP32[i10 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 27794 i1 = i7 + 96 | 0;
michael@0 27795 i10 = i3 + 32 | 0;
michael@0 27796 HEAP32[i1 >> 2] = HEAP32[i10 >> 2];
michael@0 27797 HEAP32[i1 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 27798 HEAP32[i1 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 27799 HEAP32[i1 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 27800 i10 = i7 + 112 | 0;
michael@0 27801 i1 = i3 + 48 | 0;
michael@0 27802 HEAP32[i10 >> 2] = HEAP32[i1 >> 2];
michael@0 27803 HEAP32[i10 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 27804 HEAP32[i10 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 27805 HEAP32[i10 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 27806 __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i6, i7, i4 | 0, 0, 0);
michael@0 27807 STACKTOP = i5;
michael@0 27808 return;
michael@0 27809 }
michael@0 27810 }
michael@0 27811 function __ZN16btCollisionWorld14debugDrawWorldEv(i1) {
michael@0 27812 i1 = i1 | 0;
michael@0 27813 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0;
michael@0 27814 i2 = STACKTOP;
michael@0 27815 STACKTOP = STACKTOP + 112 | 0;
michael@0 27816 i3 = i2 | 0;
michael@0 27817 i4 = i2 + 16 | 0;
michael@0 27818 i5 = i2 + 32 | 0;
michael@0 27819 i6 = i2 + 48 | 0;
michael@0 27820 i7 = i2 + 64 | 0;
michael@0 27821 i8 = i2 + 80 | 0;
michael@0 27822 i9 = i2 + 96 | 0;
michael@0 27823 i10 = i1;
michael@0 27824 do {
michael@0 27825 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 127](i1) | 0) != 0) {
michael@0 27826 i11 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 27827 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i11 >> 2] | 0) + 48 >> 2] & 127](i11) | 0) & 8 | 0) == 0) {
michael@0 27828 break;
michael@0 27829 }
michael@0 27830 i11 = i1 + 24 | 0;
michael@0 27831 i12 = HEAP32[i11 >> 2] | 0;
michael@0 27832 i13 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i12 >> 2] | 0) + 36 >> 2] & 127](i12) | 0;
michael@0 27833 _memset(i3 | 0, 0, 16);
michael@0 27834 if ((i13 | 0) > 0) {
michael@0 27835 i14 = 0;
michael@0 27836 } else {
michael@0 27837 break;
michael@0 27838 }
michael@0 27839 do {
michael@0 27840 i12 = HEAP32[i11 >> 2] | 0;
michael@0 27841 i15 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i12 >> 2] | 0) + 40 >> 2] & 63](i12, i14) | 0;
michael@0 27842 i12 = HEAP32[i15 + 1116 >> 2] | 0;
michael@0 27843 if ((i12 | 0) > 0) {
michael@0 27844 i16 = 0;
michael@0 27845 do {
michael@0 27846 i17 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 27847 FUNCTION_TABLE_viiifii[HEAP32[(HEAP32[i17 >> 2] | 0) + 32 >> 2] & 1](i17, i15 + 4 + (i16 * 276 | 0) + 32 | 0, i15 + 4 + (i16 * 276 | 0) + 64 | 0, +HEAPF32[i15 + 4 + (i16 * 276 | 0) + 80 >> 2], HEAP32[i15 + 4 + (i16 * 276 | 0) + 144 >> 2] | 0, i3);
michael@0 27848 i16 = i16 + 1 | 0;
michael@0 27849 } while ((i16 | 0) < (i12 | 0));
michael@0 27850 }
michael@0 27851 i14 = i14 + 1 | 0;
michael@0 27852 } while ((i14 | 0) < (i13 | 0));
michael@0 27853 }
michael@0 27854 } while (0);
michael@0 27855 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 127](i1) | 0) == 0) {
michael@0 27856 STACKTOP = i2;
michael@0 27857 return;
michael@0 27858 }
michael@0 27859 i14 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 27860 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i14 >> 2] | 0) + 48 >> 2] & 127](i14) | 0) & 3 | 0) == 0) {
michael@0 27861 STACKTOP = i2;
michael@0 27862 return;
michael@0 27863 }
michael@0 27864 i14 = i1 + 8 | 0;
michael@0 27865 if ((HEAP32[i14 >> 2] | 0) <= 0) {
michael@0 27866 STACKTOP = i2;
michael@0 27867 return;
michael@0 27868 }
michael@0 27869 i3 = i1 + 16 | 0;
michael@0 27870 i13 = i1 + 80 | 0;
michael@0 27871 i11 = i7 | 0;
michael@0 27872 i12 = i7 + 4 | 0;
michael@0 27873 i16 = i7 + 8 | 0;
michael@0 27874 i15 = i7 + 12 | 0;
michael@0 27875 i17 = i5 | 0;
michael@0 27876 i18 = i5 + 4 | 0;
michael@0 27877 i19 = i5 + 8 | 0;
michael@0 27878 i20 = i6 | 0;
michael@0 27879 i21 = i6 + 4 | 0;
michael@0 27880 i22 = i6 + 8 | 0;
michael@0 27881 i23 = i8 | 0;
michael@0 27882 i24 = i8 + 4 | 0;
michael@0 27883 i25 = i8 + 8 | 0;
michael@0 27884 i26 = i9 | 0;
michael@0 27885 i27 = i9 + 4 | 0;
michael@0 27886 i28 = i9 + 8 | 0;
michael@0 27887 i29 = i5 + 12 | 0;
michael@0 27888 i30 = i8 + 12 | 0;
michael@0 27889 i31 = i6 + 12 | 0;
michael@0 27890 i32 = i9 + 12 | 0;
michael@0 27891 i33 = i4 | 0;
michael@0 27892 i34 = i4 + 4 | 0;
michael@0 27893 i35 = i4 + 8 | 0;
michael@0 27894 i36 = i4 + 12 | 0;
michael@0 27895 i37 = i1;
michael@0 27896 i38 = 0;
michael@0 27897 do {
michael@0 27898 i39 = HEAP32[(HEAP32[i3 >> 2] | 0) + (i38 << 2) >> 2] | 0;
michael@0 27899 do {
michael@0 27900 if ((HEAP32[i39 + 204 >> 2] & 32 | 0) == 0) {
michael@0 27901 do {
michael@0 27902 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 127](i1) | 0) != 0) {
michael@0 27903 i40 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 27904 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i40 >> 2] | 0) + 48 >> 2] & 127](i40) | 0) & 1 | 0) == 0) {
michael@0 27905 break;
michael@0 27906 }
michael@0 27907 HEAPF32[i33 >> 2] = 1.0;
michael@0 27908 HEAPF32[i34 >> 2] = 1.0;
michael@0 27909 HEAPF32[i35 >> 2] = 1.0;
michael@0 27910 HEAPF32[i36 >> 2] = 0.0;
michael@0 27911 switch (HEAP32[i39 + 216 >> 2] | 0) {
michael@0 27912 case 5:
michael@0 27913 {
michael@0 27914 HEAPF32[i33 >> 2] = 1.0;
michael@0 27915 HEAPF32[i34 >> 2] = 1.0;
michael@0 27916 HEAPF32[i35 >> 2] = 0.0;
michael@0 27917 HEAPF32[i36 >> 2] = 0.0;
michael@0 27918 break;
michael@0 27919 }
michael@0 27920 case 1:
michael@0 27921 {
michael@0 27922 HEAPF32[i33 >> 2] = 1.0;
michael@0 27923 HEAPF32[i34 >> 2] = 1.0;
michael@0 27924 HEAPF32[i35 >> 2] = 1.0;
michael@0 27925 HEAPF32[i36 >> 2] = 0.0;
michael@0 27926 break;
michael@0 27927 }
michael@0 27928 case 2:
michael@0 27929 {
michael@0 27930 HEAPF32[i33 >> 2] = 0.0;
michael@0 27931 HEAPF32[i34 >> 2] = 1.0;
michael@0 27932 HEAPF32[i35 >> 2] = 0.0;
michael@0 27933 HEAPF32[i36 >> 2] = 0.0;
michael@0 27934 break;
michael@0 27935 }
michael@0 27936 case 3:
michael@0 27937 {
michael@0 27938 HEAPF32[i33 >> 2] = 0.0;
michael@0 27939 HEAPF32[i34 >> 2] = 1.0;
michael@0 27940 HEAPF32[i35 >> 2] = 1.0;
michael@0 27941 HEAPF32[i36 >> 2] = 0.0;
michael@0 27942 break;
michael@0 27943 }
michael@0 27944 case 4:
michael@0 27945 {
michael@0 27946 HEAPF32[i33 >> 2] = 1.0;
michael@0 27947 HEAPF32[i34 >> 2] = 0.0;
michael@0 27948 HEAPF32[i35 >> 2] = 0.0;
michael@0 27949 HEAPF32[i36 >> 2] = 0.0;
michael@0 27950 break;
michael@0 27951 }
michael@0 27952 default:
michael@0 27953 {
michael@0 27954 HEAPF32[i33 >> 2] = 1.0;
michael@0 27955 HEAPF32[i34 >> 2] = 0.0;
michael@0 27956 HEAPF32[i35 >> 2] = 0.0;
michael@0 27957 HEAPF32[i36 >> 2] = 0.0;
michael@0 27958 }
michael@0 27959 }
michael@0 27960 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i37 >> 2] | 0) + 24 >> 2] & 127](i1, i39 + 4 | 0, HEAP32[i39 + 192 >> 2] | 0, i4);
michael@0 27961 }
michael@0 27962 } while (0);
michael@0 27963 i40 = HEAP32[i13 >> 2] | 0;
michael@0 27964 if ((i40 | 0) == 0) {
michael@0 27965 break;
michael@0 27966 }
michael@0 27967 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i40 >> 2] | 0) + 48 >> 2] & 127](i40) | 0) & 2 | 0) == 0) {
michael@0 27968 break;
michael@0 27969 }
michael@0 27970 HEAPF32[i11 >> 2] = 1.0;
michael@0 27971 HEAPF32[i12 >> 2] = 0.0;
michael@0 27972 HEAPF32[i16 >> 2] = 0.0;
michael@0 27973 HEAPF32[i15 >> 2] = 0.0;
michael@0 27974 i40 = i39 + 192 | 0;
michael@0 27975 i41 = HEAP32[i40 >> 2] | 0;
michael@0 27976 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i41 >> 2] | 0) + 8 >> 2] & 127](i41, i39 + 4 | 0, i5, i6);
michael@0 27977 d42 = +HEAPF32[4];
michael@0 27978 HEAPF32[i17 >> 2] = +HEAPF32[i17 >> 2] - d42;
michael@0 27979 HEAPF32[i18 >> 2] = +HEAPF32[i18 >> 2] - d42;
michael@0 27980 HEAPF32[i19 >> 2] = +HEAPF32[i19 >> 2] - d42;
michael@0 27981 HEAPF32[i20 >> 2] = d42 + +HEAPF32[i20 >> 2];
michael@0 27982 HEAPF32[i21 >> 2] = d42 + +HEAPF32[i21 >> 2];
michael@0 27983 HEAPF32[i22 >> 2] = d42 + +HEAPF32[i22 >> 2];
michael@0 27984 do {
michael@0 27985 if ((HEAP32[i39 + 232 >> 2] | 0) == 2) {
michael@0 27986 i41 = HEAP32[i40 >> 2] | 0;
michael@0 27987 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i41 >> 2] | 0) + 8 >> 2] & 127](i41, i39 + 68 | 0, i8, i9);
michael@0 27988 d43 = +HEAPF32[i23 >> 2] - d42;
michael@0 27989 HEAPF32[i23 >> 2] = d43;
michael@0 27990 d44 = +HEAPF32[i24 >> 2] - d42;
michael@0 27991 HEAPF32[i24 >> 2] = d44;
michael@0 27992 d45 = +HEAPF32[i25 >> 2] - d42;
michael@0 27993 HEAPF32[i25 >> 2] = d45;
michael@0 27994 d46 = d42 + +HEAPF32[i26 >> 2];
michael@0 27995 HEAPF32[i26 >> 2] = d46;
michael@0 27996 d47 = d42 + +HEAPF32[i27 >> 2];
michael@0 27997 HEAPF32[i27 >> 2] = d47;
michael@0 27998 d48 = d42 + +HEAPF32[i28 >> 2];
michael@0 27999 HEAPF32[i28 >> 2] = d48;
michael@0 28000 if (d43 < +HEAPF32[i17 >> 2]) {
michael@0 28001 HEAPF32[i17 >> 2] = d43;
michael@0 28002 }
michael@0 28003 if (d44 < +HEAPF32[i18 >> 2]) {
michael@0 28004 HEAPF32[i18 >> 2] = d44;
michael@0 28005 }
michael@0 28006 if (d45 < +HEAPF32[i19 >> 2]) {
michael@0 28007 HEAPF32[i19 >> 2] = d45;
michael@0 28008 }
michael@0 28009 d45 = +HEAPF32[i30 >> 2];
michael@0 28010 if (d45 < +HEAPF32[i29 >> 2]) {
michael@0 28011 HEAPF32[i29 >> 2] = d45;
michael@0 28012 }
michael@0 28013 if (+HEAPF32[i20 >> 2] < d46) {
michael@0 28014 HEAPF32[i20 >> 2] = d46;
michael@0 28015 }
michael@0 28016 if (+HEAPF32[i21 >> 2] < d47) {
michael@0 28017 HEAPF32[i21 >> 2] = d47;
michael@0 28018 }
michael@0 28019 if (+HEAPF32[i22 >> 2] < d48) {
michael@0 28020 HEAPF32[i22 >> 2] = d48;
michael@0 28021 }
michael@0 28022 d48 = +HEAPF32[i32 >> 2];
michael@0 28023 if (+HEAPF32[i31 >> 2] >= d48) {
michael@0 28024 break;
michael@0 28025 }
michael@0 28026 HEAPF32[i31 >> 2] = d48;
michael@0 28027 }
michael@0 28028 } while (0);
michael@0 28029 i40 = HEAP32[i13 >> 2] | 0;
michael@0 28030 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i40 >> 2] | 0) + 52 >> 2] & 127](i40, i5, i6, i7);
michael@0 28031 }
michael@0 28032 } while (0);
michael@0 28033 i38 = i38 + 1 | 0;
michael@0 28034 } while ((i38 | 0) < (HEAP32[i14 >> 2] | 0));
michael@0 28035 STACKTOP = i2;
michael@0 28036 return;
michael@0 28037 }
michael@0 28038 function __ZN27btContinuousConvexCollision16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i1, i2, i3, i4, i5, i6) {
michael@0 28039 i1 = i1 | 0;
michael@0 28040 i2 = i2 | 0;
michael@0 28041 i3 = i3 | 0;
michael@0 28042 i4 = i4 | 0;
michael@0 28043 i5 = i5 | 0;
michael@0 28044 i6 = i6 | 0;
michael@0 28045 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0;
michael@0 28046 i7 = STACKTOP;
michael@0 28047 STACKTOP = STACKTOP + 384 | 0;
michael@0 28048 i8 = i7 | 0;
michael@0 28049 i9 = i7 + 16 | 0;
michael@0 28050 i10 = i7 + 24 | 0;
michael@0 28051 i11 = i7 + 40 | 0;
michael@0 28052 i12 = i7 + 48 | 0;
michael@0 28053 i13 = i7 + 64 | 0;
michael@0 28054 i14 = i7 + 80 | 0;
michael@0 28055 i15 = i7 + 96 | 0;
michael@0 28056 i16 = i7 + 112 | 0;
michael@0 28057 i17 = i7 + 128 | 0;
michael@0 28058 i18 = i7 + 176 | 0;
michael@0 28059 i19 = i7 + 192 | 0;
michael@0 28060 i20 = i7 + 256 | 0;
michael@0 28061 i21 = i7 + 320 | 0;
michael@0 28062 i22 = i7 + 336 | 0;
michael@0 28063 d23 = +HEAPF32[i3 + 48 >> 2] - +HEAPF32[i2 + 48 >> 2];
michael@0 28064 d24 = +HEAPF32[i3 + 52 >> 2] - +HEAPF32[i2 + 52 >> 2];
michael@0 28065 d25 = +HEAPF32[i3 + 56 >> 2] - +HEAPF32[i2 + 56 >> 2];
michael@0 28066 HEAPF32[i12 >> 2] = d23;
michael@0 28067 HEAPF32[i12 + 4 >> 2] = d24;
michael@0 28068 HEAPF32[i12 + 8 >> 2] = d25;
michael@0 28069 HEAPF32[i12 + 12 >> 2] = 0.0;
michael@0 28070 __ZN15btTransformUtil22calculateDiffAxisAngleERK11btTransformS2_R9btVector3Rf(i2, i3, i10, i11);
michael@0 28071 d26 = +HEAPF32[i11 >> 2];
michael@0 28072 d27 = +HEAPF32[i10 >> 2] * d26;
michael@0 28073 d28 = d26 * +HEAPF32[i10 + 4 >> 2];
michael@0 28074 d29 = d26 * +HEAPF32[i10 + 8 >> 2];
michael@0 28075 HEAPF32[i13 >> 2] = d27;
michael@0 28076 HEAPF32[i13 + 4 >> 2] = d28;
michael@0 28077 HEAPF32[i13 + 8 >> 2] = d29;
michael@0 28078 HEAPF32[i13 + 12 >> 2] = 0.0;
michael@0 28079 d26 = +HEAPF32[i5 + 48 >> 2] - +HEAPF32[i4 + 48 >> 2];
michael@0 28080 d30 = +HEAPF32[i5 + 52 >> 2] - +HEAPF32[i4 + 52 >> 2];
michael@0 28081 d31 = +HEAPF32[i5 + 56 >> 2] - +HEAPF32[i4 + 56 >> 2];
michael@0 28082 HEAPF32[i14 >> 2] = d26;
michael@0 28083 HEAPF32[i14 + 4 >> 2] = d30;
michael@0 28084 HEAPF32[i14 + 8 >> 2] = d31;
michael@0 28085 HEAPF32[i14 + 12 >> 2] = 0.0;
michael@0 28086 __ZN15btTransformUtil22calculateDiffAxisAngleERK11btTransformS2_R9btVector3Rf(i4, i5, i8, i9);
michael@0 28087 d32 = +HEAPF32[i9 >> 2];
michael@0 28088 d33 = +HEAPF32[i8 >> 2] * d32;
michael@0 28089 d34 = d32 * +HEAPF32[i8 + 4 >> 2];
michael@0 28090 d35 = d32 * +HEAPF32[i8 + 8 >> 2];
michael@0 28091 HEAPF32[i15 >> 2] = d33;
michael@0 28092 HEAPF32[i15 + 4 >> 2] = d34;
michael@0 28093 HEAPF32[i15 + 8 >> 2] = d35;
michael@0 28094 HEAPF32[i15 + 12 >> 2] = 0.0;
michael@0 28095 i8 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 28096 d32 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 16 >> 2] & 7](i8 | 0);
michael@0 28097 i8 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 28098 if ((i8 | 0) == 0) {
michael@0 28099 d36 = 0.0;
michael@0 28100 } else {
michael@0 28101 d36 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 16 >> 2] & 7](i8 | 0);
michael@0 28102 }
michael@0 28103 d37 = d32 * +Math_sqrt(+(d27 * d27 + d28 * d28 + d29 * d29));
michael@0 28104 d29 = d37 + d36 * +Math_sqrt(+(d33 * d33 + d34 * d34 + d35 * d35));
michael@0 28105 d35 = d26 - d23;
michael@0 28106 d23 = d30 - d24;
michael@0 28107 d24 = d31 - d25;
michael@0 28108 if (+Math_sqrt(+(d35 * d35 + d23 * d23 + d24 * d24)) + d29 == 0.0) {
michael@0 28109 i38 = 0;
michael@0 28110 STACKTOP = i7;
michael@0 28111 return i38 | 0;
michael@0 28112 }
michael@0 28113 HEAP32[i17 >> 2] = 4272;
michael@0 28114 i8 = i17 + 36 | 0;
michael@0 28115 HEAPF32[i8 >> 2] = 999999984306749400.0;
michael@0 28116 i9 = i17 + 40 | 0;
michael@0 28117 HEAP8[i9] = 0;
michael@0 28118 __ZN27btContinuousConvexCollision20computeClosestPointsERK11btTransformS2_R16btPointCollector(i1, i2, i4, i17);
michael@0 28119 i5 = (HEAP8[i9] | 0) == 0;
michael@0 28120 i9 = i16;
michael@0 28121 i10 = i17 + 20 | 0;
michael@0 28122 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 28123 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 28124 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 28125 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 28126 if (i5) {
michael@0 28127 i38 = 0;
michael@0 28128 STACKTOP = i7;
michael@0 28129 return i38 | 0;
michael@0 28130 }
michael@0 28131 i5 = i6 + 172 | 0;
michael@0 28132 d25 = +HEAPF32[i17 + 4 >> 2];
michael@0 28133 d31 = +HEAPF32[i17 + 8 >> 2];
michael@0 28134 d30 = +HEAPF32[i17 + 12 >> 2];
michael@0 28135 if (d29 + (d35 * d25 + d23 * d31 + d24 * d30) <= 1.1920928955078125e-7) {
michael@0 28136 i38 = 0;
michael@0 28137 STACKTOP = i7;
michael@0 28138 return i38 | 0;
michael@0 28139 }
michael@0 28140 i10 = i6 + 168 | 0;
michael@0 28141 i11 = i6;
michael@0 28142 i3 = i22 | 0;
michael@0 28143 i39 = i22 + 36 | 0;
michael@0 28144 i40 = i22 + 40 | 0;
michael@0 28145 i41 = i22 + 20 | 0;
michael@0 28146 i42 = i22 + 4 | 0;
michael@0 28147 i43 = i22 + 8 | 0;
michael@0 28148 i44 = i22 + 12 | 0;
michael@0 28149 i45 = i22 + 16 | 0;
michael@0 28150 i46 = i19 + 48 | 0;
michael@0 28151 i47 = i21 | 0;
michael@0 28152 i48 = i21 + 4 | 0;
michael@0 28153 i49 = i21 + 8 | 0;
michael@0 28154 i50 = i21 + 12 | 0;
michael@0 28155 i51 = i18 | 0;
michael@0 28156 i52 = i18 + 4 | 0;
michael@0 28157 i53 = i18 + 8 | 0;
michael@0 28158 i54 = i18 + 12 | 0;
michael@0 28159 d26 = +HEAPF32[i5 >> 2] + +HEAPF32[i8 >> 2];
michael@0 28160 i8 = 0;
michael@0 28161 d34 = 0.0;
michael@0 28162 d33 = d25;
michael@0 28163 d25 = d31;
michael@0 28164 d31 = d30;
michael@0 28165 d30 = +HEAPF32[i17 + 16 >> 2];
michael@0 28166 while (1) {
michael@0 28167 if (d26 <= .0010000000474974513) {
michael@0 28168 i55 = 593;
michael@0 28169 break;
michael@0 28170 }
michael@0 28171 i17 = HEAP32[i10 >> 2] | 0;
michael@0 28172 if ((i17 | 0) != 0) {
michael@0 28173 i56 = HEAP32[(HEAP32[i17 >> 2] | 0) + 20 >> 2] | 0;
michael@0 28174 HEAPF32[i51 >> 2] = 1.0;
michael@0 28175 HEAPF32[i52 >> 2] = 1.0;
michael@0 28176 HEAPF32[i53 >> 2] = 1.0;
michael@0 28177 HEAPF32[i54 >> 2] = 0.0;
michael@0 28178 FUNCTION_TABLE_viifi[i56 & 1](i17, i16, .20000000298023224, i18);
michael@0 28179 }
michael@0 28180 d36 = d29 + (d24 * d31 + (d23 * d25 + d35 * d33));
michael@0 28181 if (d36 <= 1.1920928955078125e-7) {
michael@0 28182 i38 = 0;
michael@0 28183 i55 = 598;
michael@0 28184 break;
michael@0 28185 }
michael@0 28186 d37 = d34 + d26 / d36;
michael@0 28187 if (!(d37 >= 0.0 & d37 <= 1.0 & d37 > d34)) {
michael@0 28188 i38 = 0;
michael@0 28189 i55 = 599;
michael@0 28190 break;
michael@0 28191 }
michael@0 28192 __ZN15btTransformUtil18integrateTransformERK11btTransformRK9btVector3S5_fRS0_(i2, i12, i13, d37, i19);
michael@0 28193 __ZN15btTransformUtil18integrateTransformERK11btTransformRK9btVector3S5_fRS0_(i4, i14, i15, d37, i20);
michael@0 28194 i17 = HEAP32[i10 >> 2] | 0;
michael@0 28195 if ((i17 | 0) != 0) {
michael@0 28196 i56 = HEAP32[(HEAP32[i17 >> 2] | 0) + 20 >> 2] | 0;
michael@0 28197 HEAPF32[i47 >> 2] = 1.0;
michael@0 28198 HEAPF32[i48 >> 2] = 0.0;
michael@0 28199 HEAPF32[i49 >> 2] = 0.0;
michael@0 28200 HEAPF32[i50 >> 2] = 0.0;
michael@0 28201 FUNCTION_TABLE_viifi[i56 & 1](i17, i46, .20000000298023224, i21);
michael@0 28202 }
michael@0 28203 FUNCTION_TABLE_vif[HEAP32[HEAP32[i11 >> 2] >> 2] & 31](i6, d37);
michael@0 28204 HEAP32[i3 >> 2] = 4272;
michael@0 28205 HEAPF32[i39 >> 2] = 999999984306749400.0;
michael@0 28206 HEAP8[i40] = 0;
michael@0 28207 __ZN27btContinuousConvexCollision20computeClosestPointsERK11btTransformS2_R16btPointCollector(i1, i19, i20, i22);
michael@0 28208 if ((HEAP8[i40] | 0) == 0) {
michael@0 28209 i55 = 591;
michael@0 28210 break;
michael@0 28211 }
michael@0 28212 d36 = +HEAPF32[i39 >> 2] + +HEAPF32[i5 >> 2];
michael@0 28213 HEAP32[i9 >> 2] = HEAP32[i41 >> 2];
michael@0 28214 HEAP32[i9 + 4 >> 2] = HEAP32[i41 + 4 >> 2];
michael@0 28215 HEAP32[i9 + 8 >> 2] = HEAP32[i41 + 8 >> 2];
michael@0 28216 HEAP32[i9 + 12 >> 2] = HEAP32[i41 + 12 >> 2];
michael@0 28217 i57 = i8 + 1 | 0;
michael@0 28218 if ((i57 | 0) > 64) {
michael@0 28219 i55 = 592;
michael@0 28220 break;
michael@0 28221 } else {
michael@0 28222 d26 = d36;
michael@0 28223 i8 = i57;
michael@0 28224 d34 = d37;
michael@0 28225 d33 = +HEAPF32[i42 >> 2];
michael@0 28226 d25 = +HEAPF32[i43 >> 2];
michael@0 28227 d31 = +HEAPF32[i44 >> 2];
michael@0 28228 d30 = +HEAPF32[i45 >> 2];
michael@0 28229 }
michael@0 28230 }
michael@0 28231 if ((i55 | 0) == 598) {
michael@0 28232 STACKTOP = i7;
michael@0 28233 return i38 | 0;
michael@0 28234 } else if ((i55 | 0) == 599) {
michael@0 28235 STACKTOP = i7;
michael@0 28236 return i38 | 0;
michael@0 28237 } else if ((i55 | 0) == 591) {
michael@0 28238 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 127](i6, -1, i8);
michael@0 28239 i38 = 0;
michael@0 28240 STACKTOP = i7;
michael@0 28241 return i38 | 0;
michael@0 28242 } else if ((i55 | 0) == 592) {
michael@0 28243 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 127](i6, -2, i57);
michael@0 28244 i38 = 0;
michael@0 28245 STACKTOP = i7;
michael@0 28246 return i38 | 0;
michael@0 28247 } else if ((i55 | 0) == 593) {
michael@0 28248 HEAPF32[i6 + 164 >> 2] = d34;
michael@0 28249 HEAPF32[i6 + 132 >> 2] = d33;
michael@0 28250 HEAPF32[i6 + 136 >> 2] = d25;
michael@0 28251 HEAPF32[i6 + 140 >> 2] = d31;
michael@0 28252 HEAPF32[i6 + 144 >> 2] = d30;
michael@0 28253 i55 = i6 + 148 | 0;
michael@0 28254 HEAP32[i55 >> 2] = HEAP32[i9 >> 2];
michael@0 28255 HEAP32[i55 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 28256 HEAP32[i55 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 28257 HEAP32[i55 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 28258 i38 = 1;
michael@0 28259 STACKTOP = i7;
michael@0 28260 return i38 | 0;
michael@0 28261 }
michael@0 28262 return 0;
michael@0 28263 }
michael@0 28264 function __ZNK16btCollisionWorld15convexSweepTestEPK13btConvexShapeRK11btTransformS5_RNS_20ConvexResultCallbackEf(i1, i2, i3, i4, i5, d6) {
michael@0 28265 i1 = i1 | 0;
michael@0 28266 i2 = i2 | 0;
michael@0 28267 i3 = i3 | 0;
michael@0 28268 i4 = i4 | 0;
michael@0 28269 i5 = i5 | 0;
michael@0 28270 d6 = +d6;
michael@0 28271 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0;
michael@0 28272 i7 = STACKTOP;
michael@0 28273 STACKTOP = STACKTOP + 496 | 0;
michael@0 28274 i8 = i7 | 0;
michael@0 28275 i9 = i7 + 16 | 0;
michael@0 28276 i10 = i7 + 24 | 0;
michael@0 28277 i11 = i7 + 88 | 0;
michael@0 28278 i12 = i7 + 152 | 0;
michael@0 28279 i13 = i7 + 168 | 0;
michael@0 28280 i14 = i7 + 184 | 0;
michael@0 28281 i15 = i7 + 200 | 0;
michael@0 28282 i16 = i7 + 216 | 0;
michael@0 28283 i17 = i7 + 280 | 0;
michael@0 28284 i18 = i7 + 296 | 0;
michael@0 28285 __ZN15CProfileManager13Start_ProfileEPKc(56);
michael@0 28286 i19 = i10;
michael@0 28287 i20 = i3;
michael@0 28288 HEAP32[i19 >> 2] = HEAP32[i20 >> 2];
michael@0 28289 HEAP32[i19 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 28290 HEAP32[i19 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 28291 HEAP32[i19 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 28292 i19 = i10 + 16 | 0;
michael@0 28293 i21 = i3 + 16 | 0;
michael@0 28294 HEAP32[i19 >> 2] = HEAP32[i21 >> 2];
michael@0 28295 HEAP32[i19 + 4 >> 2] = HEAP32[i21 + 4 >> 2];
michael@0 28296 HEAP32[i19 + 8 >> 2] = HEAP32[i21 + 8 >> 2];
michael@0 28297 HEAP32[i19 + 12 >> 2] = HEAP32[i21 + 12 >> 2];
michael@0 28298 i19 = i10 + 32 | 0;
michael@0 28299 i22 = i3 + 32 | 0;
michael@0 28300 HEAP32[i19 >> 2] = HEAP32[i22 >> 2];
michael@0 28301 HEAP32[i19 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 28302 HEAP32[i19 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 28303 HEAP32[i19 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 28304 i19 = i10 + 48 | 0;
michael@0 28305 i23 = i19;
michael@0 28306 i24 = i3 + 48 | 0;
michael@0 28307 HEAP32[i23 >> 2] = HEAP32[i24 >> 2];
michael@0 28308 HEAP32[i23 + 4 >> 2] = HEAP32[i24 + 4 >> 2];
michael@0 28309 HEAP32[i23 + 8 >> 2] = HEAP32[i24 + 8 >> 2];
michael@0 28310 HEAP32[i23 + 12 >> 2] = HEAP32[i24 + 12 >> 2];
michael@0 28311 i23 = i11;
michael@0 28312 i3 = i4;
michael@0 28313 HEAP32[i23 >> 2] = HEAP32[i3 >> 2];
michael@0 28314 HEAP32[i23 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 28315 HEAP32[i23 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 28316 HEAP32[i23 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 28317 i23 = i11 + 16 | 0;
michael@0 28318 i25 = i4 + 16 | 0;
michael@0 28319 HEAP32[i23 >> 2] = HEAP32[i25 >> 2];
michael@0 28320 HEAP32[i23 + 4 >> 2] = HEAP32[i25 + 4 >> 2];
michael@0 28321 HEAP32[i23 + 8 >> 2] = HEAP32[i25 + 8 >> 2];
michael@0 28322 HEAP32[i23 + 12 >> 2] = HEAP32[i25 + 12 >> 2];
michael@0 28323 i23 = i11 + 32 | 0;
michael@0 28324 i26 = i4 + 32 | 0;
michael@0 28325 HEAP32[i23 >> 2] = HEAP32[i26 >> 2];
michael@0 28326 HEAP32[i23 + 4 >> 2] = HEAP32[i26 + 4 >> 2];
michael@0 28327 HEAP32[i23 + 8 >> 2] = HEAP32[i26 + 8 >> 2];
michael@0 28328 HEAP32[i23 + 12 >> 2] = HEAP32[i26 + 12 >> 2];
michael@0 28329 i23 = i11 + 48 | 0;
michael@0 28330 i27 = i23;
michael@0 28331 i28 = i4 + 48 | 0;
michael@0 28332 HEAP32[i27 >> 2] = HEAP32[i28 >> 2];
michael@0 28333 HEAP32[i27 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 28334 HEAP32[i27 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 28335 HEAP32[i27 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 28336 __ZN15btTransformUtil22calculateDiffAxisAngleERK11btTransformS2_R9btVector3Rf(i10, i11, i8, i9);
michael@0 28337 d29 = +HEAPF32[i9 >> 2];
michael@0 28338 d30 = d29 * +HEAPF32[i8 + 4 >> 2];
michael@0 28339 d31 = d29 * +HEAPF32[i8 + 8 >> 2];
michael@0 28340 HEAPF32[i14 >> 2] = +HEAPF32[i8 >> 2] * d29;
michael@0 28341 HEAPF32[i14 + 4 >> 2] = d30;
michael@0 28342 HEAPF32[i14 + 8 >> 2] = d31;
michael@0 28343 HEAPF32[i14 + 12 >> 2] = 0.0;
michael@0 28344 _memset(i15 | 0, 0, 16);
michael@0 28345 i8 = i16 + 4 | 0;
michael@0 28346 i9 = i8;
michael@0 28347 HEAP32[i9 >> 2] = 0;
michael@0 28348 HEAP32[i9 + 4 >> 2] = 0;
michael@0 28349 i9 = i16 + 24 | 0;
michael@0 28350 i11 = i9;
michael@0 28351 HEAP32[i11 >> 2] = 0;
michael@0 28352 HEAP32[i11 + 4 >> 2] = 0;
michael@0 28353 i11 = i16 + 44 | 0;
michael@0 28354 _memset(i11 | 0, 0, 20);
michael@0 28355 __ZNK11btMatrix3x311getRotationER12btQuaternion(i10 | 0, i17);
michael@0 28356 d31 = +HEAPF32[i17 >> 2];
michael@0 28357 d30 = +HEAPF32[i17 + 4 >> 2];
michael@0 28358 d29 = +HEAPF32[i17 + 8 >> 2];
michael@0 28359 d32 = +HEAPF32[i17 + 12 >> 2];
michael@0 28360 d33 = 2.0 / (d31 * d31 + d30 * d30 + d29 * d29 + d32 * d32);
michael@0 28361 d34 = d31 * d33;
michael@0 28362 d35 = d30 * d33;
michael@0 28363 d36 = d29 * d33;
michael@0 28364 d33 = d32 * d34;
michael@0 28365 d37 = d32 * d35;
michael@0 28366 d38 = d32 * d36;
michael@0 28367 d32 = d31 * d34;
michael@0 28368 d34 = d31 * d35;
michael@0 28369 d39 = d31 * d36;
michael@0 28370 d31 = d30 * d35;
michael@0 28371 d35 = d30 * d36;
michael@0 28372 d30 = d29 * d36;
michael@0 28373 HEAPF32[i16 >> 2] = 1.0 - (d31 + d30);
michael@0 28374 HEAPF32[i8 >> 2] = d34 - d38;
michael@0 28375 HEAPF32[i16 + 8 >> 2] = d39 + d37;
michael@0 28376 HEAPF32[i16 + 12 >> 2] = 0.0;
michael@0 28377 HEAPF32[i16 + 16 >> 2] = d34 + d38;
michael@0 28378 HEAPF32[i16 + 20 >> 2] = 1.0 - (d32 + d30);
michael@0 28379 HEAPF32[i9 >> 2] = d35 - d33;
michael@0 28380 HEAPF32[i16 + 28 >> 2] = 0.0;
michael@0 28381 HEAPF32[i16 + 32 >> 2] = d39 - d37;
michael@0 28382 HEAPF32[i16 + 36 >> 2] = d35 + d33;
michael@0 28383 HEAPF32[i16 + 40 >> 2] = 1.0 - (d32 + d31);
michael@0 28384 HEAPF32[i11 >> 2] = 0.0;
michael@0 28385 __ZNK16btCollisionShape21calculateTemporalAabbERK11btTransformRK9btVector3S5_fRS3_S6_(i2 | 0, i16, i15, i14, 1.0, i12, i13);
michael@0 28386 HEAP32[i18 >> 2] = 3648;
michael@0 28387 i14 = i18 + 36 | 0;
michael@0 28388 HEAP32[i14 >> 2] = HEAP32[i20 >> 2];
michael@0 28389 HEAP32[i14 + 4 >> 2] = HEAP32[i20 + 4 >> 2];
michael@0 28390 HEAP32[i14 + 8 >> 2] = HEAP32[i20 + 8 >> 2];
michael@0 28391 HEAP32[i14 + 12 >> 2] = HEAP32[i20 + 12 >> 2];
michael@0 28392 i20 = i18 + 52 | 0;
michael@0 28393 HEAP32[i20 >> 2] = HEAP32[i21 >> 2];
michael@0 28394 HEAP32[i20 + 4 >> 2] = HEAP32[i21 + 4 >> 2];
michael@0 28395 HEAP32[i20 + 8 >> 2] = HEAP32[i21 + 8 >> 2];
michael@0 28396 HEAP32[i20 + 12 >> 2] = HEAP32[i21 + 12 >> 2];
michael@0 28397 i21 = i18 + 68 | 0;
michael@0 28398 HEAP32[i21 >> 2] = HEAP32[i22 >> 2];
michael@0 28399 HEAP32[i21 + 4 >> 2] = HEAP32[i22 + 4 >> 2];
michael@0 28400 HEAP32[i21 + 8 >> 2] = HEAP32[i22 + 8 >> 2];
michael@0 28401 HEAP32[i21 + 12 >> 2] = HEAP32[i22 + 12 >> 2];
michael@0 28402 i22 = i18 + 84 | 0;
michael@0 28403 i21 = i22;
michael@0 28404 HEAP32[i21 >> 2] = HEAP32[i24 >> 2];
michael@0 28405 HEAP32[i21 + 4 >> 2] = HEAP32[i24 + 4 >> 2];
michael@0 28406 HEAP32[i21 + 8 >> 2] = HEAP32[i24 + 8 >> 2];
michael@0 28407 HEAP32[i21 + 12 >> 2] = HEAP32[i24 + 12 >> 2];
michael@0 28408 i24 = i18 + 100 | 0;
michael@0 28409 HEAP32[i24 >> 2] = HEAP32[i3 >> 2];
michael@0 28410 HEAP32[i24 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 28411 HEAP32[i24 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 28412 HEAP32[i24 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 28413 i3 = i18 + 116 | 0;
michael@0 28414 HEAP32[i3 >> 2] = HEAP32[i25 >> 2];
michael@0 28415 HEAP32[i3 + 4 >> 2] = HEAP32[i25 + 4 >> 2];
michael@0 28416 HEAP32[i3 + 8 >> 2] = HEAP32[i25 + 8 >> 2];
michael@0 28417 HEAP32[i3 + 12 >> 2] = HEAP32[i25 + 12 >> 2];
michael@0 28418 i25 = i18 + 132 | 0;
michael@0 28419 HEAP32[i25 >> 2] = HEAP32[i26 >> 2];
michael@0 28420 HEAP32[i25 + 4 >> 2] = HEAP32[i26 + 4 >> 2];
michael@0 28421 HEAP32[i25 + 8 >> 2] = HEAP32[i26 + 8 >> 2];
michael@0 28422 HEAP32[i25 + 12 >> 2] = HEAP32[i26 + 12 >> 2];
michael@0 28423 i26 = i18 + 148 | 0;
michael@0 28424 i25 = i26;
michael@0 28425 HEAP32[i25 >> 2] = HEAP32[i28 >> 2];
michael@0 28426 HEAP32[i25 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 28427 HEAP32[i25 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 28428 HEAP32[i25 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 28429 HEAP32[i18 + 180 >> 2] = i1;
michael@0 28430 HEAP32[i18 + 184 >> 2] = i5;
michael@0 28431 HEAPF32[i18 + 188 >> 2] = d6;
michael@0 28432 HEAP32[i18 + 192 >> 2] = i2;
michael@0 28433 d6 = +HEAPF32[i26 >> 2] - +HEAPF32[i22 >> 2];
michael@0 28434 d31 = +HEAPF32[i18 + 152 >> 2] - +HEAPF32[i18 + 88 >> 2];
michael@0 28435 d32 = +HEAPF32[i18 + 156 >> 2] - +HEAPF32[i18 + 92 >> 2];
michael@0 28436 d33 = 1.0 / +Math_sqrt(+(d6 * d6 + d31 * d31 + d32 * d32));
michael@0 28437 d35 = d6 * d33;
michael@0 28438 d37 = d31 * d33;
michael@0 28439 d39 = d32 * d33;
michael@0 28440 if (d35 == 0.0) {
michael@0 28441 d40 = 999999984306749400.0;
michael@0 28442 } else {
michael@0 28443 d40 = 1.0 / d35;
michael@0 28444 }
michael@0 28445 HEAPF32[i18 + 4 >> 2] = d40;
michael@0 28446 if (d37 == 0.0) {
michael@0 28447 d41 = 999999984306749400.0;
michael@0 28448 } else {
michael@0 28449 d41 = 1.0 / d37;
michael@0 28450 }
michael@0 28451 HEAPF32[i18 + 8 >> 2] = d41;
michael@0 28452 if (d39 == 0.0) {
michael@0 28453 d42 = 999999984306749400.0;
michael@0 28454 } else {
michael@0 28455 d42 = 1.0 / d39;
michael@0 28456 }
michael@0 28457 HEAPF32[i18 + 12 >> 2] = d42;
michael@0 28458 HEAP32[i18 + 20 >> 2] = d40 < 0.0;
michael@0 28459 HEAP32[i18 + 24 >> 2] = d41 < 0.0;
michael@0 28460 HEAP32[i18 + 28 >> 2] = d42 < 0.0;
michael@0 28461 HEAPF32[i18 + 32 >> 2] = d32 * d39 + (d6 * d35 + d31 * d37);
michael@0 28462 i22 = HEAP32[i1 + 76 >> 2] | 0;
michael@0 28463 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i22 >> 2] | 0) + 24 >> 2] & 15](i22, i19, i23, i18 | 0, i12, i13);
michael@0 28464 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 28465 STACKTOP = i7;
michael@0 28466 return;
michael@0 28467 }
michael@0 28468 function __ZN35btSequentialImpulseConstraintSolver23setupFrictionConstraintER18btSolverConstraintRK9btVector3P11btRigidBodyS6_R15btManifoldPointS4_S4_P17btCollisionObjectSA_fff(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, d11, d12, d13) {
michael@0 28469 i1 = i1 | 0;
michael@0 28470 i2 = i2 | 0;
michael@0 28471 i3 = i3 | 0;
michael@0 28472 i4 = i4 | 0;
michael@0 28473 i5 = i5 | 0;
michael@0 28474 i6 = i6 | 0;
michael@0 28475 i7 = i7 | 0;
michael@0 28476 i8 = i8 | 0;
michael@0 28477 i9 = i9 | 0;
michael@0 28478 i10 = i10 | 0;
michael@0 28479 d11 = +d11;
michael@0 28480 d12 = +d12;
michael@0 28481 d13 = +d13;
michael@0 28482 var i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, i61 = 0, i62 = 0, i63 = 0, i64 = 0;
michael@0 28483 i5 = STACKTOP;
michael@0 28484 STACKTOP = STACKTOP + 64 | 0;
michael@0 28485 i4 = i5 | 0;
michael@0 28486 i1 = i5 + 16 | 0;
michael@0 28487 i14 = i5 + 32 | 0;
michael@0 28488 i15 = i5 + 48 | 0;
michael@0 28489 if ((HEAP32[i9 + 232 >> 2] & 2 | 0) == 0) {
michael@0 28490 i16 = 0;
michael@0 28491 } else {
michael@0 28492 i16 = i9;
michael@0 28493 }
michael@0 28494 if ((HEAP32[i10 + 232 >> 2] & 2 | 0) == 0) {
michael@0 28495 i17 = 0;
michael@0 28496 } else {
michael@0 28497 i17 = i10;
michael@0 28498 }
michael@0 28499 i10 = i2 + 16 | 0;
michael@0 28500 i9 = i10;
michael@0 28501 i18 = i3;
michael@0 28502 HEAP32[i9 >> 2] = HEAP32[i18 >> 2];
michael@0 28503 HEAP32[i9 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 28504 HEAP32[i9 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 28505 HEAP32[i9 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 28506 i18 = (i16 | 0) != 0;
michael@0 28507 if (i18) {
michael@0 28508 i19 = i16;
michael@0 28509 } else {
michael@0 28510 i9 = i14;
michael@0 28511 i20 = i15;
michael@0 28512 do {
michael@0 28513 if ((HEAP8[14328] | 0) == 0) {
michael@0 28514 if ((___cxa_guard_acquire(14328) | 0) == 0) {
michael@0 28515 break;
michael@0 28516 }
michael@0 28517 _memset(i9 | 0, 0, 16);
michael@0 28518 __ZN11btRigidBodyC2EfP13btMotionStateP16btCollisionShapeRK9btVector3(12536, 0.0, 0, 0, i14);
michael@0 28519 _atexit(268, 12536, ___dso_handle | 0) | 0;
michael@0 28520 }
michael@0 28521 } while (0);
michael@0 28522 _memset(i20 | 0, 0, 16);
michael@0 28523 __ZN11btRigidBody12setMassPropsEfRK9btVector3(12536, 0.0, i15);
michael@0 28524 i19 = 12536;
michael@0 28525 }
michael@0 28526 HEAP32[i2 + 104 >> 2] = i19;
michael@0 28527 i19 = (i17 | 0) != 0;
michael@0 28528 if (i19) {
michael@0 28529 i21 = i17;
michael@0 28530 } else {
michael@0 28531 i15 = i4;
michael@0 28532 i20 = i1;
michael@0 28533 do {
michael@0 28534 if ((HEAP8[14328] | 0) == 0) {
michael@0 28535 if ((___cxa_guard_acquire(14328) | 0) == 0) {
michael@0 28536 break;
michael@0 28537 }
michael@0 28538 _memset(i15 | 0, 0, 16);
michael@0 28539 __ZN11btRigidBodyC2EfP13btMotionStateP16btCollisionShapeRK9btVector3(12536, 0.0, 0, 0, i4);
michael@0 28540 _atexit(268, 12536, ___dso_handle | 0) | 0;
michael@0 28541 }
michael@0 28542 } while (0);
michael@0 28543 _memset(i20 | 0, 0, 16);
michael@0 28544 __ZN11btRigidBody12setMassPropsEfRK9btVector3(12536, 0.0, i1);
michael@0 28545 i21 = 12536;
michael@0 28546 }
michael@0 28547 HEAP32[i2 + 108 >> 2] = i21;
michael@0 28548 HEAPF32[i2 + 88 >> 2] = +HEAPF32[i6 + 84 >> 2];
michael@0 28549 HEAP32[i2 + 112 >> 2] = 0;
michael@0 28550 HEAPF32[i2 + 84 >> 2] = 0.0;
michael@0 28551 HEAPF32[i2 + 80 >> 2] = 0.0;
michael@0 28552 i6 = i7 + 4 | 0;
michael@0 28553 d22 = +HEAPF32[i6 >> 2];
michael@0 28554 d23 = +HEAPF32[i2 + 24 >> 2];
michael@0 28555 i21 = i7 + 8 | 0;
michael@0 28556 d24 = +HEAPF32[i21 >> 2];
michael@0 28557 d25 = +HEAPF32[i2 + 20 >> 2];
michael@0 28558 d26 = d22 * d23 - d24 * d25;
michael@0 28559 d27 = +HEAPF32[i10 >> 2];
michael@0 28560 i10 = i7 | 0;
michael@0 28561 d28 = +HEAPF32[i10 >> 2];
michael@0 28562 d29 = d24 * d27 - d23 * d28;
michael@0 28563 d24 = d25 * d28 - d22 * d27;
michael@0 28564 HEAPF32[i2 >> 2] = d26;
michael@0 28565 HEAPF32[i2 + 4 >> 2] = d29;
michael@0 28566 HEAPF32[i2 + 8 >> 2] = d24;
michael@0 28567 HEAPF32[i2 + 12 >> 2] = 0.0;
michael@0 28568 if (i18) {
michael@0 28569 d30 = (d26 * +HEAPF32[i16 + 256 >> 2] + d29 * +HEAPF32[i16 + 260 >> 2] + d24 * +HEAPF32[i16 + 264 >> 2]) * +HEAPF32[i16 + 536 >> 2];
michael@0 28570 d31 = (d26 * +HEAPF32[i16 + 272 >> 2] + d29 * +HEAPF32[i16 + 276 >> 2] + d24 * +HEAPF32[i16 + 280 >> 2]) * +HEAPF32[i16 + 540 >> 2];
michael@0 28571 d32 = (d26 * +HEAPF32[i16 + 288 >> 2] + d29 * +HEAPF32[i16 + 292 >> 2] + d24 * +HEAPF32[i16 + 296 >> 2]) * +HEAPF32[i16 + 544 >> 2];
michael@0 28572 } else {
michael@0 28573 d30 = 0.0;
michael@0 28574 d31 = 0.0;
michael@0 28575 d32 = 0.0;
michael@0 28576 }
michael@0 28577 HEAPF32[i2 + 48 >> 2] = d30;
michael@0 28578 HEAPF32[i2 + 52 >> 2] = d31;
michael@0 28579 HEAPF32[i2 + 56 >> 2] = d32;
michael@0 28580 HEAPF32[i2 + 60 >> 2] = 0.0;
michael@0 28581 d22 = -0.0 - d27;
michael@0 28582 d28 = -0.0 - d25;
michael@0 28583 d33 = -0.0 - d23;
michael@0 28584 i7 = i8 + 4 | 0;
michael@0 28585 d34 = +HEAPF32[i7 >> 2];
michael@0 28586 i1 = i8 + 8 | 0;
michael@0 28587 d35 = +HEAPF32[i1 >> 2];
michael@0 28588 d36 = d34 * d33 - d35 * d28;
michael@0 28589 i20 = i8 | 0;
michael@0 28590 d37 = +HEAPF32[i20 >> 2];
michael@0 28591 d38 = d35 * d22 - d37 * d33;
michael@0 28592 d33 = d37 * d28 - d34 * d22;
michael@0 28593 HEAPF32[i2 + 32 >> 2] = d36;
michael@0 28594 HEAPF32[i2 + 36 >> 2] = d38;
michael@0 28595 HEAPF32[i2 + 40 >> 2] = d33;
michael@0 28596 HEAPF32[i2 + 44 >> 2] = 0.0;
michael@0 28597 if (i19) {
michael@0 28598 d39 = (d36 * +HEAPF32[i17 + 256 >> 2] + d38 * +HEAPF32[i17 + 260 >> 2] + d33 * +HEAPF32[i17 + 264 >> 2]) * +HEAPF32[i17 + 536 >> 2];
michael@0 28599 d40 = (d36 * +HEAPF32[i17 + 272 >> 2] + d38 * +HEAPF32[i17 + 276 >> 2] + d33 * +HEAPF32[i17 + 280 >> 2]) * +HEAPF32[i17 + 540 >> 2];
michael@0 28600 d41 = (d36 * +HEAPF32[i17 + 288 >> 2] + d38 * +HEAPF32[i17 + 292 >> 2] + d33 * +HEAPF32[i17 + 296 >> 2]) * +HEAPF32[i17 + 544 >> 2];
michael@0 28601 } else {
michael@0 28602 d39 = 0.0;
michael@0 28603 d40 = 0.0;
michael@0 28604 d41 = 0.0;
michael@0 28605 }
michael@0 28606 HEAPF32[i2 + 64 >> 2] = d39;
michael@0 28607 HEAPF32[i2 + 68 >> 2] = d40;
michael@0 28608 HEAPF32[i2 + 72 >> 2] = d41;
michael@0 28609 HEAPF32[i2 + 76 >> 2] = 0.0;
michael@0 28610 if (i18) {
michael@0 28611 d22 = +HEAPF32[i21 >> 2];
michael@0 28612 d34 = +HEAPF32[i6 >> 2];
michael@0 28613 d28 = +HEAPF32[i10 >> 2];
michael@0 28614 d42 = +HEAPF32[i16 + 336 >> 2] + ((d31 * d22 - d32 * d34) * +HEAPF32[i3 >> 2] + (d32 * d28 - d30 * d22) * +HEAPF32[i3 + 4 >> 2] + (d30 * d34 - d31 * d28) * +HEAPF32[i3 + 8 >> 2]);
michael@0 28615 } else {
michael@0 28616 d42 = 0.0;
michael@0 28617 }
michael@0 28618 if (i19) {
michael@0 28619 d28 = -0.0 - d39;
michael@0 28620 d39 = -0.0 - d40;
michael@0 28621 d40 = -0.0 - d41;
michael@0 28622 d41 = +HEAPF32[i1 >> 2];
michael@0 28623 d31 = +HEAPF32[i7 >> 2];
michael@0 28624 d34 = +HEAPF32[i20 >> 2];
michael@0 28625 d43 = +HEAPF32[i17 + 336 >> 2] + ((d41 * d39 - d31 * d40) * +HEAPF32[i3 >> 2] + (d34 * d40 - d41 * d28) * +HEAPF32[i3 + 4 >> 2] + (d31 * d28 - d34 * d39) * +HEAPF32[i3 + 8 >> 2]);
michael@0 28626 } else {
michael@0 28627 d43 = 0.0;
michael@0 28628 }
michael@0 28629 d39 = d11 / (d42 + d43);
michael@0 28630 HEAPF32[i2 + 92 >> 2] = d39;
michael@0 28631 if (i18) {
michael@0 28632 d44 = +HEAPF32[i16 + 320 >> 2];
michael@0 28633 d45 = +HEAPF32[i16 + 324 >> 2];
michael@0 28634 d46 = +HEAPF32[i16 + 328 >> 2];
michael@0 28635 d47 = d27 * +HEAPF32[i16 + 304 >> 2] + d25 * +HEAPF32[i16 + 308 >> 2] + d23 * +HEAPF32[i16 + 312 >> 2];
michael@0 28636 } else {
michael@0 28637 d44 = 0.0;
michael@0 28638 d45 = 0.0;
michael@0 28639 d46 = 0.0;
michael@0 28640 d47 = d23 * 0.0 + (d25 * 0.0 + d27 * 0.0);
michael@0 28641 }
michael@0 28642 d43 = d47 + (d24 * d46 + (d29 * d45 + d26 * d44));
michael@0 28643 if (i19) {
michael@0 28644 d48 = +HEAPF32[i17 + 320 >> 2];
michael@0 28645 d49 = +HEAPF32[i17 + 324 >> 2];
michael@0 28646 d50 = +HEAPF32[i17 + 328 >> 2];
michael@0 28647 d51 = d27 * +HEAPF32[i17 + 304 >> 2] + d25 * +HEAPF32[i17 + 308 >> 2] + d23 * +HEAPF32[i17 + 312 >> 2];
michael@0 28648 d52 = d36 * d48;
michael@0 28649 d53 = d38 * d49;
michael@0 28650 d54 = d53 + d52;
michael@0 28651 d55 = d33 * d50;
michael@0 28652 d56 = d55 + d54;
michael@0 28653 d57 = d56 - d51;
michael@0 28654 d58 = d43 + d57;
michael@0 28655 d59 = d12 - d58;
michael@0 28656 d60 = d39 * d59;
michael@0 28657 i61 = i2 + 116 | 0;
michael@0 28658 HEAPF32[i61 >> 2] = d60;
michael@0 28659 i62 = i2 + 120 | 0;
michael@0 28660 HEAPF32[i62 >> 2] = d13;
michael@0 28661 i63 = i2 + 124 | 0;
michael@0 28662 HEAPF32[i63 >> 2] = 0.0;
michael@0 28663 i64 = i2 + 128 | 0;
michael@0 28664 HEAPF32[i64 >> 2] = 1.0e10;
michael@0 28665 STACKTOP = i5;
michael@0 28666 return;
michael@0 28667 } else {
michael@0 28668 d48 = 0.0;
michael@0 28669 d49 = 0.0;
michael@0 28670 d50 = 0.0;
michael@0 28671 d51 = d23 * 0.0 + (d25 * 0.0 + d27 * 0.0);
michael@0 28672 d52 = d36 * d48;
michael@0 28673 d53 = d38 * d49;
michael@0 28674 d54 = d53 + d52;
michael@0 28675 d55 = d33 * d50;
michael@0 28676 d56 = d55 + d54;
michael@0 28677 d57 = d56 - d51;
michael@0 28678 d58 = d43 + d57;
michael@0 28679 d59 = d12 - d58;
michael@0 28680 d60 = d39 * d59;
michael@0 28681 i61 = i2 + 116 | 0;
michael@0 28682 HEAPF32[i61 >> 2] = d60;
michael@0 28683 i62 = i2 + 120 | 0;
michael@0 28684 HEAPF32[i62 >> 2] = d13;
michael@0 28685 i63 = i2 + 124 | 0;
michael@0 28686 HEAPF32[i63 >> 2] = 0.0;
michael@0 28687 i64 = i2 + 128 | 0;
michael@0 28688 HEAPF32[i64 >> 2] = 1.0e10;
michael@0 28689 STACKTOP = i5;
michael@0 28690 return;
michael@0 28691 }
michael@0 28692 }
michael@0 28693 function __ZNK10__cxxabiv121__vmi_class_type_info16search_below_dstEPNS_19__dynamic_cast_infoEPKvib(i1, i2, i3, i4, i5) {
michael@0 28694 i1 = i1 | 0;
michael@0 28695 i2 = i2 | 0;
michael@0 28696 i3 = i3 | 0;
michael@0 28697 i4 = i4 | 0;
michael@0 28698 i5 = i5 | 0;
michael@0 28699 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0;
michael@0 28700 i6 = i1 | 0;
michael@0 28701 if ((i6 | 0) == (HEAP32[i2 + 8 >> 2] | 0)) {
michael@0 28702 if ((HEAP32[i2 + 4 >> 2] | 0) != (i3 | 0)) {
michael@0 28703 return;
michael@0 28704 }
michael@0 28705 i7 = i2 + 28 | 0;
michael@0 28706 if ((HEAP32[i7 >> 2] | 0) == 1) {
michael@0 28707 return;
michael@0 28708 }
michael@0 28709 HEAP32[i7 >> 2] = i4;
michael@0 28710 return;
michael@0 28711 }
michael@0 28712 if ((i6 | 0) == (HEAP32[i2 >> 2] | 0)) {
michael@0 28713 do {
michael@0 28714 if ((HEAP32[i2 + 16 >> 2] | 0) != (i3 | 0)) {
michael@0 28715 i6 = i2 + 20 | 0;
michael@0 28716 if ((HEAP32[i6 >> 2] | 0) == (i3 | 0)) {
michael@0 28717 break;
michael@0 28718 }
michael@0 28719 HEAP32[i2 + 32 >> 2] = i4;
michael@0 28720 i7 = i2 + 44 | 0;
michael@0 28721 if ((HEAP32[i7 >> 2] | 0) == 4) {
michael@0 28722 return;
michael@0 28723 }
michael@0 28724 i8 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 28725 i9 = i1 + 16 + (i8 << 3) | 0;
michael@0 28726 L2740 : do {
michael@0 28727 if ((i8 | 0) > 0) {
michael@0 28728 i10 = i2 + 52 | 0;
michael@0 28729 i11 = i2 + 53 | 0;
michael@0 28730 i12 = i2 + 54 | 0;
michael@0 28731 i13 = i1 + 8 | 0;
michael@0 28732 i14 = i2 + 24 | 0;
michael@0 28733 i15 = i3;
michael@0 28734 i16 = 0;
michael@0 28735 i17 = i1 + 16 | 0;
michael@0 28736 i18 = 0;
michael@0 28737 L2742 : while (1) {
michael@0 28738 HEAP8[i10] = 0;
michael@0 28739 HEAP8[i11] = 0;
michael@0 28740 i19 = HEAP32[i17 + 4 >> 2] | 0;
michael@0 28741 i20 = i19 >> 8;
michael@0 28742 if ((i19 & 1 | 0) == 0) {
michael@0 28743 i21 = i20;
michael@0 28744 } else {
michael@0 28745 i21 = HEAP32[(HEAP32[i15 >> 2] | 0) + i20 >> 2] | 0;
michael@0 28746 }
michael@0 28747 i20 = HEAP32[i17 >> 2] | 0;
michael@0 28748 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i20 >> 2] | 0) + 20 >> 2] & 15](i20, i2, i3, i3 + i21 | 0, 2 - (i19 >>> 1 & 1) | 0, i5);
michael@0 28749 if ((HEAP8[i12] & 1) != 0) {
michael@0 28750 i22 = i18;
michael@0 28751 i23 = i16;
michael@0 28752 break;
michael@0 28753 }
michael@0 28754 do {
michael@0 28755 if ((HEAP8[i11] & 1) == 0) {
michael@0 28756 i24 = i18;
michael@0 28757 i25 = i16;
michael@0 28758 } else {
michael@0 28759 if ((HEAP8[i10] & 1) == 0) {
michael@0 28760 if ((HEAP32[i13 >> 2] & 1 | 0) == 0) {
michael@0 28761 i22 = 1;
michael@0 28762 i23 = i16;
michael@0 28763 break L2742;
michael@0 28764 } else {
michael@0 28765 i24 = 1;
michael@0 28766 i25 = i16;
michael@0 28767 break;
michael@0 28768 }
michael@0 28769 }
michael@0 28770 if ((HEAP32[i14 >> 2] | 0) == 1) {
michael@0 28771 i26 = 2075;
michael@0 28772 break L2740;
michael@0 28773 }
michael@0 28774 if ((HEAP32[i13 >> 2] & 2 | 0) == 0) {
michael@0 28775 i26 = 2075;
michael@0 28776 break L2740;
michael@0 28777 } else {
michael@0 28778 i24 = 1;
michael@0 28779 i25 = 1;
michael@0 28780 }
michael@0 28781 }
michael@0 28782 } while (0);
michael@0 28783 i19 = i17 + 8 | 0;
michael@0 28784 if (i19 >>> 0 < i9 >>> 0) {
michael@0 28785 i16 = i25;
michael@0 28786 i17 = i19;
michael@0 28787 i18 = i24;
michael@0 28788 } else {
michael@0 28789 i22 = i24;
michael@0 28790 i23 = i25;
michael@0 28791 break;
michael@0 28792 }
michael@0 28793 }
michael@0 28794 if (i23) {
michael@0 28795 i27 = i22;
michael@0 28796 i26 = 2074;
michael@0 28797 } else {
michael@0 28798 i28 = i22;
michael@0 28799 i26 = 2071;
michael@0 28800 }
michael@0 28801 } else {
michael@0 28802 i28 = 0;
michael@0 28803 i26 = 2071;
michael@0 28804 }
michael@0 28805 } while (0);
michael@0 28806 do {
michael@0 28807 if ((i26 | 0) == 2071) {
michael@0 28808 HEAP32[i6 >> 2] = i3;
michael@0 28809 i9 = i2 + 40 | 0;
michael@0 28810 HEAP32[i9 >> 2] = (HEAP32[i9 >> 2] | 0) + 1;
michael@0 28811 if ((HEAP32[i2 + 36 >> 2] | 0) != 1) {
michael@0 28812 i27 = i28;
michael@0 28813 i26 = 2074;
michael@0 28814 break;
michael@0 28815 }
michael@0 28816 if ((HEAP32[i2 + 24 >> 2] | 0) != 2) {
michael@0 28817 i27 = i28;
michael@0 28818 i26 = 2074;
michael@0 28819 break;
michael@0 28820 }
michael@0 28821 HEAP8[i2 + 54 | 0] = 1;
michael@0 28822 if (i28) {
michael@0 28823 i26 = 2075;
michael@0 28824 } else {
michael@0 28825 i26 = 2076;
michael@0 28826 }
michael@0 28827 }
michael@0 28828 } while (0);
michael@0 28829 if ((i26 | 0) == 2074) {
michael@0 28830 if (i27) {
michael@0 28831 i26 = 2075;
michael@0 28832 } else {
michael@0 28833 i26 = 2076;
michael@0 28834 }
michael@0 28835 }
michael@0 28836 if ((i26 | 0) == 2075) {
michael@0 28837 HEAP32[i7 >> 2] = 3;
michael@0 28838 return;
michael@0 28839 } else if ((i26 | 0) == 2076) {
michael@0 28840 HEAP32[i7 >> 2] = 4;
michael@0 28841 return;
michael@0 28842 }
michael@0 28843 }
michael@0 28844 } while (0);
michael@0 28845 if ((i4 | 0) != 1) {
michael@0 28846 return;
michael@0 28847 }
michael@0 28848 HEAP32[i2 + 32 >> 2] = 1;
michael@0 28849 return;
michael@0 28850 }
michael@0 28851 i27 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 28852 i28 = i1 + 16 + (i27 << 3) | 0;
michael@0 28853 i22 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 28854 i23 = i22 >> 8;
michael@0 28855 if ((i22 & 1 | 0) == 0) {
michael@0 28856 i29 = i23;
michael@0 28857 } else {
michael@0 28858 i29 = HEAP32[(HEAP32[i3 >> 2] | 0) + i23 >> 2] | 0;
michael@0 28859 }
michael@0 28860 i23 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 28861 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i23 >> 2] | 0) + 24 >> 2] & 63](i23, i2, i3 + i29 | 0, (i22 & 2 | 0) != 0 ? i4 : 2, i5);
michael@0 28862 i22 = i1 + 24 | 0;
michael@0 28863 if ((i27 | 0) <= 1) {
michael@0 28864 return;
michael@0 28865 }
michael@0 28866 i27 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 28867 do {
michael@0 28868 if ((i27 & 2 | 0) == 0) {
michael@0 28869 i1 = i2 + 36 | 0;
michael@0 28870 if ((HEAP32[i1 >> 2] | 0) == 1) {
michael@0 28871 break;
michael@0 28872 }
michael@0 28873 if ((i27 & 1 | 0) == 0) {
michael@0 28874 i29 = i2 + 54 | 0;
michael@0 28875 i23 = i3;
michael@0 28876 i25 = i22;
michael@0 28877 while (1) {
michael@0 28878 if ((HEAP8[i29] & 1) != 0) {
michael@0 28879 i26 = 2116;
michael@0 28880 break;
michael@0 28881 }
michael@0 28882 if ((HEAP32[i1 >> 2] | 0) == 1) {
michael@0 28883 i26 = 2117;
michael@0 28884 break;
michael@0 28885 }
michael@0 28886 i24 = HEAP32[i25 + 4 >> 2] | 0;
michael@0 28887 i21 = i24 >> 8;
michael@0 28888 if ((i24 & 1 | 0) == 0) {
michael@0 28889 i30 = i21;
michael@0 28890 } else {
michael@0 28891 i30 = HEAP32[(HEAP32[i23 >> 2] | 0) + i21 >> 2] | 0;
michael@0 28892 }
michael@0 28893 i21 = HEAP32[i25 >> 2] | 0;
michael@0 28894 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i21 >> 2] | 0) + 24 >> 2] & 63](i21, i2, i3 + i30 | 0, (i24 & 2 | 0) != 0 ? i4 : 2, i5);
michael@0 28895 i24 = i25 + 8 | 0;
michael@0 28896 if (i24 >>> 0 < i28 >>> 0) {
michael@0 28897 i25 = i24;
michael@0 28898 } else {
michael@0 28899 i26 = 2118;
michael@0 28900 break;
michael@0 28901 }
michael@0 28902 }
michael@0 28903 if ((i26 | 0) == 2116) {
michael@0 28904 return;
michael@0 28905 } else if ((i26 | 0) == 2117) {
michael@0 28906 return;
michael@0 28907 } else if ((i26 | 0) == 2118) {
michael@0 28908 return;
michael@0 28909 }
michael@0 28910 }
michael@0 28911 i25 = i2 + 24 | 0;
michael@0 28912 i23 = i2 + 54 | 0;
michael@0 28913 i29 = i3;
michael@0 28914 i7 = i22;
michael@0 28915 while (1) {
michael@0 28916 if ((HEAP8[i23] & 1) != 0) {
michael@0 28917 i26 = 2113;
michael@0 28918 break;
michael@0 28919 }
michael@0 28920 if ((HEAP32[i1 >> 2] | 0) == 1) {
michael@0 28921 if ((HEAP32[i25 >> 2] | 0) == 1) {
michael@0 28922 i26 = 2114;
michael@0 28923 break;
michael@0 28924 }
michael@0 28925 }
michael@0 28926 i24 = HEAP32[i7 + 4 >> 2] | 0;
michael@0 28927 i21 = i24 >> 8;
michael@0 28928 if ((i24 & 1 | 0) == 0) {
michael@0 28929 i31 = i21;
michael@0 28930 } else {
michael@0 28931 i31 = HEAP32[(HEAP32[i29 >> 2] | 0) + i21 >> 2] | 0;
michael@0 28932 }
michael@0 28933 i21 = HEAP32[i7 >> 2] | 0;
michael@0 28934 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i21 >> 2] | 0) + 24 >> 2] & 63](i21, i2, i3 + i31 | 0, (i24 & 2 | 0) != 0 ? i4 : 2, i5);
michael@0 28935 i24 = i7 + 8 | 0;
michael@0 28936 if (i24 >>> 0 < i28 >>> 0) {
michael@0 28937 i7 = i24;
michael@0 28938 } else {
michael@0 28939 i26 = 2115;
michael@0 28940 break;
michael@0 28941 }
michael@0 28942 }
michael@0 28943 if ((i26 | 0) == 2113) {
michael@0 28944 return;
michael@0 28945 } else if ((i26 | 0) == 2114) {
michael@0 28946 return;
michael@0 28947 } else if ((i26 | 0) == 2115) {
michael@0 28948 return;
michael@0 28949 }
michael@0 28950 }
michael@0 28951 } while (0);
michael@0 28952 i31 = i2 + 54 | 0;
michael@0 28953 i30 = i3;
michael@0 28954 i27 = i22;
michael@0 28955 while (1) {
michael@0 28956 if ((HEAP8[i31] & 1) != 0) {
michael@0 28957 i26 = 2111;
michael@0 28958 break;
michael@0 28959 }
michael@0 28960 i22 = HEAP32[i27 + 4 >> 2] | 0;
michael@0 28961 i7 = i22 >> 8;
michael@0 28962 if ((i22 & 1 | 0) == 0) {
michael@0 28963 i32 = i7;
michael@0 28964 } else {
michael@0 28965 i32 = HEAP32[(HEAP32[i30 >> 2] | 0) + i7 >> 2] | 0;
michael@0 28966 }
michael@0 28967 i7 = HEAP32[i27 >> 2] | 0;
michael@0 28968 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 24 >> 2] & 63](i7, i2, i3 + i32 | 0, (i22 & 2 | 0) != 0 ? i4 : 2, i5);
michael@0 28969 i22 = i27 + 8 | 0;
michael@0 28970 if (i22 >>> 0 < i28 >>> 0) {
michael@0 28971 i27 = i22;
michael@0 28972 } else {
michael@0 28973 i26 = 2112;
michael@0 28974 break;
michael@0 28975 }
michael@0 28976 }
michael@0 28977 if ((i26 | 0) == 2111) {
michael@0 28978 return;
michael@0 28979 } else if ((i26 | 0) == 2112) {
michael@0 28980 return;
michael@0 28981 }
michael@0 28982 }
michael@0 28983 function __ZN23btDiscreteDynamicsWorld19integrateTransformsEf(i1, d2) {
michael@0 28984 i1 = i1 | 0;
michael@0 28985 d2 = +d2;
michael@0 28986 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0;
michael@0 28987 i3 = STACKTOP;
michael@0 28988 STACKTOP = STACKTOP + 280 | 0;
michael@0 28989 i4 = i3 | 0;
michael@0 28990 i5 = i3 + 64 | 0;
michael@0 28991 i6 = i3 + 160 | 0;
michael@0 28992 i7 = i3 + 216 | 0;
michael@0 28993 __ZN15CProfileManager13Start_ProfileEPKc(120);
michael@0 28994 i8 = i1 + 204 | 0;
michael@0 28995 if ((HEAP32[i8 >> 2] | 0) <= 0) {
michael@0 28996 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 28997 STACKTOP = i3;
michael@0 28998 return;
michael@0 28999 }
michael@0 29000 i9 = i1 + 212 | 0;
michael@0 29001 i10 = i4 + 48 | 0;
michael@0 29002 i11 = i10 | 0;
michael@0 29003 i12 = i4 + 52 | 0;
michael@0 29004 i13 = i4 + 56 | 0;
michael@0 29005 i14 = i1 | 0;
michael@0 29006 i15 = i1 + 44 | 0;
michael@0 29007 i16 = i1 + 76 | 0;
michael@0 29008 i17 = i1 + 24 | 0;
michael@0 29009 i18 = i5 | 0;
michael@0 29010 i19 = i5 + 4 | 0;
michael@0 29011 i20 = i5 + 8 | 0;
michael@0 29012 i21 = i5 + 10 | 0;
michael@0 29013 i22 = i5 + 12 | 0;
michael@0 29014 i23 = i5 + 28 | 0;
michael@0 29015 i24 = i10;
michael@0 29016 i10 = i5 + 76 | 0;
michael@0 29017 i25 = i5 + 80 | 0;
michael@0 29018 i26 = i5 + 84 | 0;
michael@0 29019 i27 = i5 + 88 | 0;
michael@0 29020 i28 = i5 + 92 | 0;
michael@0 29021 i29 = i6 | 0;
michael@0 29022 i30 = i6 | 0;
michael@0 29023 i31 = i6 + 4 | 0;
michael@0 29024 i32 = i6 + 28 | 0;
michael@0 29025 i33 = i6 + 44 | 0;
michael@0 29026 i34 = i1 + 56 | 0;
michael@0 29027 i35 = i5 | 0;
michael@0 29028 i36 = i7;
michael@0 29029 i37 = i4;
michael@0 29030 i38 = i7 + 16 | 0;
michael@0 29031 i39 = i4 + 16 | 0;
michael@0 29032 i40 = i7 + 32 | 0;
michael@0 29033 i41 = i4 + 32 | 0;
michael@0 29034 i42 = i7 + 48 | 0;
michael@0 29035 i43 = i6 | 0;
michael@0 29036 i6 = i5 + 60 | 0;
michael@0 29037 i44 = i5 + 44 | 0;
michael@0 29038 i5 = i1 + 100 | 0;
michael@0 29039 i1 = 0;
michael@0 29040 do {
michael@0 29041 i45 = HEAP32[(HEAP32[i9 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 29042 i46 = i45 | 0;
michael@0 29043 i47 = i45 + 240 | 0;
michael@0 29044 HEAPF32[i47 >> 2] = 1.0;
michael@0 29045 i48 = HEAP32[i45 + 216 >> 2] | 0;
michael@0 29046 L734 : do {
michael@0 29047 if (!((i48 | 0) == 5 | (i48 | 0) == 2)) {
michael@0 29048 if ((HEAP32[i45 + 204 >> 2] & 3 | 0) != 0) {
michael@0 29049 break;
michael@0 29050 }
michael@0 29051 __ZN11btRigidBody26predictIntegratedTransformEfR11btTransform(i45, d2, i4);
michael@0 29052 i49 = i45 + 4 | 0;
michael@0 29053 i50 = i45 + 52 | 0;
michael@0 29054 d51 = +HEAPF32[i11 >> 2] - +HEAPF32[i50 >> 2];
michael@0 29055 d52 = +HEAPF32[i12 >> 2] - +HEAPF32[i45 + 56 >> 2];
michael@0 29056 d53 = +HEAPF32[i13 >> 2] - +HEAPF32[i45 + 60 >> 2];
michael@0 29057 do {
michael@0 29058 if ((HEAP8[i15] | 0) != 0) {
michael@0 29059 d54 = +HEAPF32[i45 + 248 >> 2];
michael@0 29060 d55 = d54 * d54;
michael@0 29061 if (!(d55 != 0.0 & d55 < d51 * d51 + d52 * d52 + d53 * d53)) {
michael@0 29062 break;
michael@0 29063 }
michael@0 29064 __ZN15CProfileManager13Start_ProfileEPKc(72);
michael@0 29065 if ((HEAP32[(HEAP32[i45 + 192 >> 2] | 0) + 4 >> 2] | 0) < 20) {
michael@0 29066 HEAP32[2996] = (HEAP32[2996] | 0) + 1;
michael@0 29067 i56 = HEAP32[i16 >> 2] | 0;
michael@0 29068 i57 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i56 >> 2] | 0) + 36 >> 2] & 127](i56) | 0;
michael@0 29069 i56 = HEAP32[i17 >> 2] | 0;
michael@0 29070 HEAPF32[i19 >> 2] = 1.0;
michael@0 29071 HEAP16[i20 >> 1] = 1;
michael@0 29072 HEAP16[i21 >> 1] = -1;
michael@0 29073 HEAP32[i18 >> 2] = 2248;
michael@0 29074 i58 = i50;
michael@0 29075 HEAP32[i22 >> 2] = HEAP32[i58 >> 2];
michael@0 29076 HEAP32[i22 + 4 >> 2] = HEAP32[i58 + 4 >> 2];
michael@0 29077 HEAP32[i22 + 8 >> 2] = HEAP32[i58 + 8 >> 2];
michael@0 29078 HEAP32[i22 + 12 >> 2] = HEAP32[i58 + 12 >> 2];
michael@0 29079 HEAP32[i23 >> 2] = HEAP32[i24 >> 2];
michael@0 29080 HEAP32[i23 + 4 >> 2] = HEAP32[i24 + 4 >> 2];
michael@0 29081 HEAP32[i23 + 8 >> 2] = HEAP32[i24 + 8 >> 2];
michael@0 29082 HEAP32[i23 + 12 >> 2] = HEAP32[i24 + 12 >> 2];
michael@0 29083 HEAP32[i10 >> 2] = 0;
michael@0 29084 HEAP32[i18 >> 2] = 2464;
michael@0 29085 HEAP32[i25 >> 2] = i46;
michael@0 29086 HEAPF32[i26 >> 2] = 0.0;
michael@0 29087 HEAP32[i27 >> 2] = i57;
michael@0 29088 HEAP32[i28 >> 2] = i56;
michael@0 29089 d55 = +HEAPF32[i45 + 244 >> 2];
michael@0 29090 __ZN21btConvexInternalShapeC2Ev(i29);
michael@0 29091 HEAP32[i30 >> 2] = 4728;
michael@0 29092 HEAP32[i31 >> 2] = 8;
michael@0 29093 HEAPF32[i32 >> 2] = d55;
michael@0 29094 HEAPF32[i33 >> 2] = d55;
michael@0 29095 HEAPF32[i26 >> 2] = +HEAPF32[i34 >> 2];
michael@0 29096 i56 = HEAP32[i45 + 188 >> 2] | 0;
michael@0 29097 HEAP16[i20 >> 1] = HEAP16[i56 + 4 >> 1] | 0;
michael@0 29098 HEAP16[i21 >> 1] = HEAP16[i56 + 6 >> 1] | 0;
michael@0 29099 HEAP32[i36 >> 2] = HEAP32[i37 >> 2];
michael@0 29100 HEAP32[i36 + 4 >> 2] = HEAP32[i37 + 4 >> 2];
michael@0 29101 HEAP32[i36 + 8 >> 2] = HEAP32[i37 + 8 >> 2];
michael@0 29102 HEAP32[i36 + 12 >> 2] = HEAP32[i37 + 12 >> 2];
michael@0 29103 HEAP32[i38 >> 2] = HEAP32[i39 >> 2];
michael@0 29104 HEAP32[i38 + 4 >> 2] = HEAP32[i39 + 4 >> 2];
michael@0 29105 HEAP32[i38 + 8 >> 2] = HEAP32[i39 + 8 >> 2];
michael@0 29106 HEAP32[i38 + 12 >> 2] = HEAP32[i39 + 12 >> 2];
michael@0 29107 HEAP32[i40 >> 2] = HEAP32[i41 >> 2];
michael@0 29108 HEAP32[i40 + 4 >> 2] = HEAP32[i41 + 4 >> 2];
michael@0 29109 HEAP32[i40 + 8 >> 2] = HEAP32[i41 + 8 >> 2];
michael@0 29110 HEAP32[i40 + 12 >> 2] = HEAP32[i41 + 12 >> 2];
michael@0 29111 HEAP32[i42 >> 2] = HEAP32[i24 >> 2];
michael@0 29112 HEAP32[i42 + 4 >> 2] = HEAP32[i24 + 4 >> 2];
michael@0 29113 HEAP32[i42 + 8 >> 2] = HEAP32[i24 + 8 >> 2];
michael@0 29114 HEAP32[i42 + 12 >> 2] = HEAP32[i24 + 12 >> 2];
michael@0 29115 i56 = i49;
michael@0 29116 HEAP32[i36 >> 2] = HEAP32[i56 >> 2];
michael@0 29117 HEAP32[i36 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 29118 HEAP32[i36 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 29119 HEAP32[i36 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 29120 i56 = i45 + 20 | 0;
michael@0 29121 HEAP32[i38 >> 2] = HEAP32[i56 >> 2];
michael@0 29122 HEAP32[i38 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 29123 HEAP32[i38 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 29124 HEAP32[i38 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 29125 i56 = i45 + 36 | 0;
michael@0 29126 HEAP32[i40 >> 2] = HEAP32[i56 >> 2];
michael@0 29127 HEAP32[i40 + 4 >> 2] = HEAP32[i56 + 4 >> 2];
michael@0 29128 HEAP32[i40 + 8 >> 2] = HEAP32[i56 + 8 >> 2];
michael@0 29129 HEAP32[i40 + 12 >> 2] = HEAP32[i56 + 12 >> 2];
michael@0 29130 __ZNK16btCollisionWorld15convexSweepTestEPK13btConvexShapeRK11btTransformS5_RNS_20ConvexResultCallbackEf(i14, i43, i49, i7, i35, 0.0);
michael@0 29131 d55 = +HEAPF32[i19 >> 2];
michael@0 29132 if (d55 < 1.0) {
michael@0 29133 HEAPF32[i47 >> 2] = d55;
michael@0 29134 __ZN11btRigidBody26predictIntegratedTransformEfR11btTransform(i45, d55 * d2, i4);
michael@0 29135 HEAPF32[i47 >> 2] = 0.0;
michael@0 29136 __ZN11btRigidBody18proceedToTransformERK11btTransform(i45, i4);
michael@0 29137 i56 = HEAP32[i10 >> 2] | 0;
michael@0 29138 +__Z22resolveSingleCollisionP11btRigidBodyP17btCollisionObjectRK9btVector3S5_RK19btContactSolverInfof(i45, i56, i6, i44, i5, 0.0);
michael@0 29139 i59 = 4;
michael@0 29140 } else {
michael@0 29141 i59 = 0;
michael@0 29142 }
michael@0 29143 __ZN13btConvexShapeD2Ev(i43);
michael@0 29144 if ((i59 | 0) == 0) {
michael@0 29145 i60 = 684;
michael@0 29146 } else {
michael@0 29147 i61 = i59;
michael@0 29148 }
michael@0 29149 } else {
michael@0 29150 i60 = 684;
michael@0 29151 }
michael@0 29152 if ((i60 | 0) == 684) {
michael@0 29153 i60 = 0;
michael@0 29154 i61 = 0;
michael@0 29155 }
michael@0 29156 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 29157 if ((i61 | 0) == 4) {
michael@0 29158 break L734;
michael@0 29159 }
michael@0 29160 }
michael@0 29161 } while (0);
michael@0 29162 __ZN11btRigidBody18proceedToTransformERK11btTransform(i45, i4);
michael@0 29163 }
michael@0 29164 } while (0);
michael@0 29165 i1 = i1 + 1 | 0;
michael@0 29166 } while ((i1 | 0) < (HEAP32[i8 >> 2] | 0));
michael@0 29167 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 29168 STACKTOP = i3;
michael@0 29169 return;
michael@0 29170 }
michael@0 29171 function __ZNK14btQuantizedBvh36walkStacklessQuantizedTreeAgainstRayEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_ii(i1, i2, i3, i4, i5, i6, i7, i8) {
michael@0 29172 i1 = i1 | 0;
michael@0 29173 i2 = i2 | 0;
michael@0 29174 i3 = i3 | 0;
michael@0 29175 i4 = i4 | 0;
michael@0 29176 i5 = i5 | 0;
michael@0 29177 i6 = i6 | 0;
michael@0 29178 i7 = i7 | 0;
michael@0 29179 i8 = i8 | 0;
michael@0 29180 var i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, d40 = 0.0, i41 = 0, d42 = 0.0, i43 = 0, d44 = 0.0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0, i68 = 0, i69 = 0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0;
michael@0 29181 i9 = STACKTOP;
michael@0 29182 STACKTOP = STACKTOP + 32 | 0;
michael@0 29183 i10 = i9 | 0;
michael@0 29184 i11 = (HEAP32[i1 + 136 >> 2] | 0) + (i7 << 4) | 0;
michael@0 29185 d12 = +HEAPF32[i4 >> 2];
michael@0 29186 i13 = i3 | 0;
michael@0 29187 d14 = +HEAPF32[i13 >> 2];
michael@0 29188 d15 = d12 - d14;
michael@0 29189 d16 = +HEAPF32[i4 + 4 >> 2];
michael@0 29190 i17 = i3 + 4 | 0;
michael@0 29191 d18 = +HEAPF32[i17 >> 2];
michael@0 29192 d19 = d16 - d18;
michael@0 29193 d20 = +HEAPF32[i4 + 8 >> 2];
michael@0 29194 i4 = i3 + 8 | 0;
michael@0 29195 d21 = +HEAPF32[i4 >> 2];
michael@0 29196 d22 = d20 - d21;
michael@0 29197 d23 = 1.0 / +Math_sqrt(+(d15 * d15 + d19 * d19 + d22 * d22));
michael@0 29198 d24 = d15 * d23;
michael@0 29199 d25 = d19 * d23;
michael@0 29200 d26 = d22 * d23;
michael@0 29201 d23 = d22 * d26 + (d15 * d24 + d19 * d25);
michael@0 29202 if (d24 == 0.0) {
michael@0 29203 d27 = 999999984306749400.0;
michael@0 29204 } else {
michael@0 29205 d27 = 1.0 / d24;
michael@0 29206 }
michael@0 29207 if (d25 == 0.0) {
michael@0 29208 d28 = 999999984306749400.0;
michael@0 29209 } else {
michael@0 29210 d28 = 1.0 / d25;
michael@0 29211 }
michael@0 29212 if (d26 == 0.0) {
michael@0 29213 d29 = 999999984306749400.0;
michael@0 29214 } else {
michael@0 29215 d29 = 1.0 / d26;
michael@0 29216 }
michael@0 29217 i3 = d27 < 0.0 | 0;
michael@0 29218 i30 = d28 < 0.0 | 0;
michael@0 29219 i31 = d29 < 0.0 | 0;
michael@0 29220 i32 = i5 | 0;
michael@0 29221 d26 = (d12 < d14 ? d12 : d14) + +HEAPF32[i32 >> 2];
michael@0 29222 i33 = i5 + 4 | 0;
michael@0 29223 d25 = (d16 < d18 ? d16 : d18) + +HEAPF32[i33 >> 2];
michael@0 29224 i34 = i5 + 8 | 0;
michael@0 29225 d24 = (d20 < d21 ? d20 : d21) + +HEAPF32[i34 >> 2];
michael@0 29226 i5 = i6 | 0;
michael@0 29227 d19 = (d14 < d12 ? d12 : d14) + +HEAPF32[i5 >> 2];
michael@0 29228 i35 = i6 + 4 | 0;
michael@0 29229 d14 = (d18 < d16 ? d16 : d18) + +HEAPF32[i35 >> 2];
michael@0 29230 i36 = i6 + 8 | 0;
michael@0 29231 d18 = (d21 < d20 ? d20 : d21) + +HEAPF32[i36 >> 2];
michael@0 29232 i6 = i1 + 4 | 0;
michael@0 29233 d21 = +HEAPF32[i6 >> 2];
michael@0 29234 d20 = d26 < d21 ? d21 : d26;
michael@0 29235 i37 = i1 + 8 | 0;
michael@0 29236 d26 = +HEAPF32[i37 >> 2];
michael@0 29237 d16 = d25 < d26 ? d26 : d25;
michael@0 29238 i38 = i1 + 12 | 0;
michael@0 29239 d25 = +HEAPF32[i38 >> 2];
michael@0 29240 d12 = d24 < d25 ? d25 : d24;
michael@0 29241 d24 = +HEAPF32[i1 + 20 >> 2];
michael@0 29242 d15 = +HEAPF32[i1 + 24 >> 2];
michael@0 29243 d22 = +HEAPF32[i1 + 28 >> 2];
michael@0 29244 i39 = i1 + 36 | 0;
michael@0 29245 d40 = +HEAPF32[i39 >> 2];
michael@0 29246 i41 = i1 + 40 | 0;
michael@0 29247 d42 = +HEAPF32[i41 >> 2];
michael@0 29248 i43 = i1 + 44 | 0;
michael@0 29249 d44 = +HEAPF32[i43 >> 2];
michael@0 29250 i1 = ~~(((d24 < d20 ? d24 : d20) - d21) * d40) & -2;
michael@0 29251 i45 = ~~(((d15 < d16 ? d15 : d16) - d26) * d42) & -2;
michael@0 29252 i46 = ~~(((d22 < d12 ? d22 : d12) - d25) * d44) & -2;
michael@0 29253 d12 = d19 < d21 ? d21 : d19;
michael@0 29254 d19 = d14 < d26 ? d26 : d14;
michael@0 29255 d14 = d18 < d25 ? d25 : d18;
michael@0 29256 i47 = ~~(((d24 < d12 ? d24 : d12) - d21) * d40 + 1.0) | 1;
michael@0 29257 i48 = ~~(((d15 < d19 ? d15 : d19) - d26) * d42 + 1.0) | 1;
michael@0 29258 i49 = ~~(((d22 < d14 ? d22 : d14) - d25) * d44 + 1.0) | 1;
michael@0 29259 if ((i7 | 0) < (i8 | 0)) {
michael@0 29260 i50 = i10 | 0;
michael@0 29261 i51 = i10 + 4 | 0;
michael@0 29262 i52 = i10 + 8 | 0;
michael@0 29263 i53 = i10 + 12 | 0;
michael@0 29264 i54 = i10 + 16 | 0;
michael@0 29265 i55 = i10 + 20 | 0;
michael@0 29266 i56 = i10 + 24 | 0;
michael@0 29267 i57 = i10 + 28 | 0;
michael@0 29268 i58 = i10 + (i3 << 4) | 0;
michael@0 29269 i59 = i10 + ((i3 ^ 1) << 4) | 0;
michael@0 29270 i3 = i10 + (i30 << 4) + 4 | 0;
michael@0 29271 i60 = i10 + ((i30 ^ 1) << 4) + 4 | 0;
michael@0 29272 i30 = i2;
michael@0 29273 i61 = i10 + (i31 << 4) + 8 | 0;
michael@0 29274 i62 = i10 + ((i31 ^ 1) << 4) + 8 | 0;
michael@0 29275 i31 = i11;
michael@0 29276 i11 = 0;
michael@0 29277 i10 = i7;
michael@0 29278 while (1) {
michael@0 29279 i7 = i11 + 1 | 0;
michael@0 29280 i63 = i31 + 6 | 0;
michael@0 29281 i64 = HEAP16[i31 >> 1] | 0;
michael@0 29282 i65 = i31 + 10 | 0;
michael@0 29283 i66 = HEAP16[i31 + 4 >> 1] | 0;
michael@0 29284 i67 = i31 + 8 | 0;
michael@0 29285 i68 = HEAP16[i31 + 2 >> 1] | 0;
michael@0 29286 i69 = i31 + 12 | 0;
michael@0 29287 i70 = (HEAP32[i69 >> 2] | 0) > -1;
michael@0 29288 do {
michael@0 29289 if ((-((i1 & 65535) <= (HEAPU16[i63 >> 1] | 0) & (i47 & 65535) >= (i64 & 65535) & (i46 & 65535) <= (HEAPU16[i65 >> 1] | 0) & (i49 & 65535) >= (i66 & 65535) & (i45 & 65535) <= (HEAPU16[i67 >> 1] | 0) & (i48 & 65535) >= (i68 & 65535) & 1) & 1 | 0) == 0) {
michael@0 29290 i71 = 1;
michael@0 29291 i72 = 498;
michael@0 29292 } else {
michael@0 29293 d44 = +HEAPF32[i39 >> 2];
michael@0 29294 d25 = +HEAPF32[i41 >> 2];
michael@0 29295 d14 = +HEAPF32[i43 >> 2];
michael@0 29296 d22 = +HEAPF32[i6 >> 2];
michael@0 29297 d42 = +HEAPF32[i37 >> 2];
michael@0 29298 d26 = +HEAPF32[i38 >> 2];
michael@0 29299 HEAPF32[i53 >> 2] = 0.0;
michael@0 29300 d19 = d22 + +((HEAPU16[i63 >> 1] | 0) >>> 0) / d44;
michael@0 29301 d15 = d42 + +((HEAPU16[i67 >> 1] | 0) >>> 0) / d25;
michael@0 29302 d40 = d26 + +((HEAPU16[i65 >> 1] | 0) >>> 0) / d14;
michael@0 29303 HEAPF32[i57 >> 2] = 0.0;
michael@0 29304 HEAPF32[i50 >> 2] = +((i64 & 65535) >>> 0) / d44 + d22 - +HEAPF32[i5 >> 2];
michael@0 29305 HEAPF32[i51 >> 2] = +((i68 & 65535) >>> 0) / d25 + d42 - +HEAPF32[i35 >> 2];
michael@0 29306 HEAPF32[i52 >> 2] = +((i66 & 65535) >>> 0) / d14 + d26 - +HEAPF32[i36 >> 2];
michael@0 29307 HEAPF32[i54 >> 2] = d19 - +HEAPF32[i32 >> 2];
michael@0 29308 HEAPF32[i55 >> 2] = d15 - +HEAPF32[i33 >> 2];
michael@0 29309 HEAPF32[i56 >> 2] = d40 - +HEAPF32[i34 >> 2];
michael@0 29310 d40 = +HEAPF32[i13 >> 2];
michael@0 29311 d15 = d27 * (+HEAPF32[i58 >> 2] - d40);
michael@0 29312 d19 = d27 * (+HEAPF32[i59 >> 2] - d40);
michael@0 29313 d40 = +HEAPF32[i17 >> 2];
michael@0 29314 d26 = d28 * (+HEAPF32[i3 >> 2] - d40);
michael@0 29315 d14 = d28 * (+HEAPF32[i60 >> 2] - d40);
michael@0 29316 if (d15 > d14 | d26 > d19) {
michael@0 29317 i71 = 1;
michael@0 29318 i72 = 498;
michael@0 29319 break;
michael@0 29320 }
michael@0 29321 d40 = d26 > d15 ? d26 : d15;
michael@0 29322 d15 = d14 < d19 ? d14 : d19;
michael@0 29323 d19 = +HEAPF32[i4 >> 2];
michael@0 29324 d14 = d29 * (+HEAPF32[i61 >> 2] - d19);
michael@0 29325 d26 = d29 * (+HEAPF32[i62 >> 2] - d19);
michael@0 29326 if (d40 > d26 | d14 > d15) {
michael@0 29327 i71 = 1;
michael@0 29328 i72 = 498;
michael@0 29329 break;
michael@0 29330 }
michael@0 29331 if ((d14 > d40 ? d14 : d40) >= d23) {
michael@0 29332 i71 = 1;
michael@0 29333 i72 = 498;
michael@0 29334 break;
michael@0 29335 }
michael@0 29336 i73 = (d26 < d15 ? d26 : d15) <= 0.0;
michael@0 29337 if (i73 | i70 ^ 1) {
michael@0 29338 i71 = i73;
michael@0 29339 i72 = 498;
michael@0 29340 break;
michael@0 29341 }
michael@0 29342 i73 = HEAP32[i69 >> 2] | 0;
michael@0 29343 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i30 >> 2] | 0) + 8 >> 2] & 127](i2, i73 >> 21, i73 & 2097151);
michael@0 29344 i72 = 499;
michael@0 29345 }
michael@0 29346 } while (0);
michael@0 29347 do {
michael@0 29348 if ((i72 | 0) == 498) {
michael@0 29349 i72 = 0;
michael@0 29350 if (i70 | i71 ^ 1) {
michael@0 29351 i72 = 499;
michael@0 29352 break;
michael@0 29353 }
michael@0 29354 i66 = HEAP32[i69 >> 2] | 0;
michael@0 29355 i74 = i10 - i66 | 0;
michael@0 29356 i75 = i31 + (-i66 << 4) | 0;
michael@0 29357 }
michael@0 29358 } while (0);
michael@0 29359 if ((i72 | 0) == 499) {
michael@0 29360 i72 = 0;
michael@0 29361 i74 = i10 + 1 | 0;
michael@0 29362 i75 = i31 + 16 | 0;
michael@0 29363 }
michael@0 29364 if ((i74 | 0) < (i8 | 0)) {
michael@0 29365 i31 = i75;
michael@0 29366 i11 = i7;
michael@0 29367 i10 = i74;
michael@0 29368 } else {
michael@0 29369 i76 = i7;
michael@0 29370 break;
michael@0 29371 }
michael@0 29372 }
michael@0 29373 } else {
michael@0 29374 i76 = 0;
michael@0 29375 }
michael@0 29376 if ((HEAP32[2982] | 0) >= (i76 | 0)) {
michael@0 29377 STACKTOP = i9;
michael@0 29378 return;
michael@0 29379 }
michael@0 29380 HEAP32[2982] = i76;
michael@0 29381 STACKTOP = i9;
michael@0 29382 return;
michael@0 29383 }
michael@0 29384 function __ZNK14btQuantizedBvh27walkStacklessTreeAgainstRayEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_ii(i1, i2, i3, i4, i5, i6, i7, i8) {
michael@0 29385 i1 = i1 | 0;
michael@0 29386 i2 = i2 | 0;
michael@0 29387 i3 = i3 | 0;
michael@0 29388 i4 = i4 | 0;
michael@0 29389 i5 = i5 | 0;
michael@0 29390 i6 = i6 | 0;
michael@0 29391 i7 = i7 | 0;
michael@0 29392 i8 = i8 | 0;
michael@0 29393 var i9 = 0, i10 = 0, d11 = 0.0, i12 = 0, d13 = 0.0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, i23 = 0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, i28 = 0, d29 = 0.0, d30 = 0.0, i31 = 0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0, i64 = 0, d65 = 0.0, d66 = 0.0, d67 = 0.0, d68 = 0.0, d69 = 0.0, i70 = 0, i71 = 0, i72 = 0, i73 = 0, i74 = 0, i75 = 0, i76 = 0, i77 = 0, i78 = 0;
michael@0 29394 i8 = STACKTOP;
michael@0 29395 STACKTOP = STACKTOP + 32 | 0;
michael@0 29396 i7 = i8 | 0;
michael@0 29397 i9 = HEAP32[i1 + 96 >> 2] | 0;
michael@0 29398 i10 = i3 | 0;
michael@0 29399 d11 = +HEAPF32[i10 >> 2];
michael@0 29400 i12 = i3 + 4 | 0;
michael@0 29401 d13 = +HEAPF32[i12 >> 2];
michael@0 29402 i14 = i3 + 8 | 0;
michael@0 29403 d15 = +HEAPF32[i14 >> 2];
michael@0 29404 d16 = +HEAPF32[i4 >> 2];
michael@0 29405 d17 = +HEAPF32[i4 + 4 >> 2];
michael@0 29406 d18 = +HEAPF32[i4 + 8 >> 2];
michael@0 29407 i4 = i5 | 0;
michael@0 29408 d19 = +HEAPF32[i4 >> 2];
michael@0 29409 d20 = (d16 < d11 ? d16 : d11) + d19;
michael@0 29410 i3 = i5 + 4 | 0;
michael@0 29411 d21 = +HEAPF32[i3 >> 2];
michael@0 29412 d22 = (d17 < d13 ? d17 : d13) + d21;
michael@0 29413 i23 = i5 + 8 | 0;
michael@0 29414 d24 = +HEAPF32[i23 >> 2];
michael@0 29415 d25 = (d18 < d15 ? d18 : d15) + d24;
michael@0 29416 i5 = i6 | 0;
michael@0 29417 d26 = +HEAPF32[i5 >> 2];
michael@0 29418 d27 = (d11 < d16 ? d16 : d11) + d26;
michael@0 29419 i28 = i6 + 4 | 0;
michael@0 29420 d29 = +HEAPF32[i28 >> 2];
michael@0 29421 d30 = (d13 < d17 ? d17 : d13) + d29;
michael@0 29422 i31 = i6 + 8 | 0;
michael@0 29423 d32 = +HEAPF32[i31 >> 2];
michael@0 29424 d33 = (d15 < d18 ? d18 : d15) + d32;
michael@0 29425 d34 = d16 - d11;
michael@0 29426 d11 = d17 - d13;
michael@0 29427 d13 = d18 - d15;
michael@0 29428 d15 = 1.0 / +Math_sqrt(+(d34 * d34 + d11 * d11 + d13 * d13));
michael@0 29429 d18 = d34 * d15;
michael@0 29430 d17 = d11 * d15;
michael@0 29431 d16 = d13 * d15;
michael@0 29432 d15 = d13 * d16 + (d34 * d18 + d11 * d17);
michael@0 29433 if (d18 == 0.0) {
michael@0 29434 d35 = 999999984306749400.0;
michael@0 29435 } else {
michael@0 29436 d35 = 1.0 / d18;
michael@0 29437 }
michael@0 29438 if (d17 == 0.0) {
michael@0 29439 d36 = 999999984306749400.0;
michael@0 29440 } else {
michael@0 29441 d36 = 1.0 / d17;
michael@0 29442 }
michael@0 29443 if (d16 == 0.0) {
michael@0 29444 d37 = 999999984306749400.0;
michael@0 29445 } else {
michael@0 29446 d37 = 1.0 / d16;
michael@0 29447 }
michael@0 29448 i6 = d35 < 0.0 | 0;
michael@0 29449 i38 = d36 < 0.0 | 0;
michael@0 29450 i39 = d37 < 0.0 | 0;
michael@0 29451 i40 = i1 + 56 | 0;
michael@0 29452 i1 = HEAP32[i40 >> 2] | 0;
michael@0 29453 L599 : do {
michael@0 29454 if ((i1 | 0) > 0) {
michael@0 29455 i41 = i7;
michael@0 29456 i42 = i7 + 16 | 0;
michael@0 29457 i43 = i42;
michael@0 29458 i44 = i7 | 0;
michael@0 29459 i45 = i7 + 4 | 0;
michael@0 29460 i46 = i7 + 8 | 0;
michael@0 29461 i47 = i42 | 0;
michael@0 29462 i42 = i7 + 20 | 0;
michael@0 29463 i48 = i7 + 24 | 0;
michael@0 29464 i49 = i7 + (i6 << 4) | 0;
michael@0 29465 i50 = i7 + ((i6 ^ 1) << 4) | 0;
michael@0 29466 i51 = i7 + (i38 << 4) + 4 | 0;
michael@0 29467 i52 = i7 + ((i38 ^ 1) << 4) + 4 | 0;
michael@0 29468 i53 = i7 + (i39 << 4) + 8 | 0;
michael@0 29469 i54 = i7 + ((i39 ^ 1) << 4) + 8 | 0;
michael@0 29470 i55 = i2;
michael@0 29471 i56 = 0;
michael@0 29472 i57 = 1;
michael@0 29473 i58 = i9;
michael@0 29474 d16 = d26;
michael@0 29475 d17 = d29;
michael@0 29476 d18 = d32;
michael@0 29477 d11 = d19;
michael@0 29478 d34 = d21;
michael@0 29479 d13 = d24;
michael@0 29480 i59 = i1;
michael@0 29481 while (1) {
michael@0 29482 i60 = i58;
michael@0 29483 HEAP32[i41 >> 2] = HEAP32[i60 >> 2];
michael@0 29484 HEAP32[i41 + 4 >> 2] = HEAP32[i60 + 4 >> 2];
michael@0 29485 HEAP32[i41 + 8 >> 2] = HEAP32[i60 + 8 >> 2];
michael@0 29486 HEAP32[i41 + 12 >> 2] = HEAP32[i60 + 12 >> 2];
michael@0 29487 i60 = i58 + 16 | 0;
michael@0 29488 i61 = i60;
michael@0 29489 HEAP32[i43 >> 2] = HEAP32[i61 >> 2];
michael@0 29490 HEAP32[i43 + 4 >> 2] = HEAP32[i61 + 4 >> 2];
michael@0 29491 HEAP32[i43 + 8 >> 2] = HEAP32[i61 + 8 >> 2];
michael@0 29492 HEAP32[i43 + 12 >> 2] = HEAP32[i61 + 12 >> 2];
michael@0 29493 HEAPF32[i44 >> 2] = +HEAPF32[i44 >> 2] - d16;
michael@0 29494 HEAPF32[i45 >> 2] = +HEAPF32[i45 >> 2] - d17;
michael@0 29495 HEAPF32[i46 >> 2] = +HEAPF32[i46 >> 2] - d18;
michael@0 29496 HEAPF32[i47 >> 2] = +HEAPF32[i47 >> 2] - d11;
michael@0 29497 HEAPF32[i42 >> 2] = +HEAPF32[i42 >> 2] - d34;
michael@0 29498 HEAPF32[i48 >> 2] = +HEAPF32[i48 >> 2] - d13;
michael@0 29499 do {
michael@0 29500 if (d20 > +HEAPF32[i60 >> 2]) {
michael@0 29501 i62 = 0;
michael@0 29502 } else {
michael@0 29503 if (d27 < +HEAPF32[i58 >> 2]) {
michael@0 29504 i62 = 0;
michael@0 29505 break;
michael@0 29506 }
michael@0 29507 i62 = 1;
michael@0 29508 }
michael@0 29509 } while (0);
michael@0 29510 do {
michael@0 29511 if (d25 > +HEAPF32[i58 + 24 >> 2]) {
michael@0 29512 i63 = 0;
michael@0 29513 } else {
michael@0 29514 if (d33 < +HEAPF32[i58 + 8 >> 2]) {
michael@0 29515 i63 = 0;
michael@0 29516 break;
michael@0 29517 }
michael@0 29518 i63 = i62;
michael@0 29519 }
michael@0 29520 } while (0);
michael@0 29521 do {
michael@0 29522 if (d22 > +HEAPF32[i58 + 20 >> 2]) {
michael@0 29523 i64 = 471;
michael@0 29524 } else {
michael@0 29525 if (d30 < +HEAPF32[i58 + 4 >> 2] | i63 ^ 1) {
michael@0 29526 i64 = 471;
michael@0 29527 break;
michael@0 29528 }
michael@0 29529 d65 = +HEAPF32[i10 >> 2];
michael@0 29530 d66 = d35 * (+HEAPF32[i49 >> 2] - d65);
michael@0 29531 d67 = d35 * (+HEAPF32[i50 >> 2] - d65);
michael@0 29532 d65 = +HEAPF32[i12 >> 2];
michael@0 29533 d68 = d36 * (+HEAPF32[i51 >> 2] - d65);
michael@0 29534 d69 = d36 * (+HEAPF32[i52 >> 2] - d65);
michael@0 29535 if (d66 > d69 | d68 > d67) {
michael@0 29536 i64 = 471;
michael@0 29537 break;
michael@0 29538 }
michael@0 29539 d65 = d68 > d66 ? d68 : d66;
michael@0 29540 d66 = d69 < d67 ? d69 : d67;
michael@0 29541 d67 = +HEAPF32[i14 >> 2];
michael@0 29542 d69 = d37 * (+HEAPF32[i53 >> 2] - d67);
michael@0 29543 d68 = d37 * (+HEAPF32[i54 >> 2] - d67);
michael@0 29544 if (d65 > d68 | d69 > d66) {
michael@0 29545 i64 = 471;
michael@0 29546 break;
michael@0 29547 }
michael@0 29548 if ((d69 > d65 ? d69 : d65) >= d15) {
michael@0 29549 i64 = 471;
michael@0 29550 break;
michael@0 29551 }
michael@0 29552 i60 = (d68 < d66 ? d68 : d66) > 0.0;
michael@0 29553 i61 = HEAP32[i58 + 32 >> 2] | 0;
michael@0 29554 i70 = (i61 | 0) == -1;
michael@0 29555 if (!(i70 & i60)) {
michael@0 29556 i71 = i60;
michael@0 29557 i72 = i70;
michael@0 29558 i73 = i61;
michael@0 29559 i64 = 474;
michael@0 29560 break;
michael@0 29561 }
michael@0 29562 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i55 >> 2] | 0) + 8 >> 2] & 127](i2, HEAP32[i58 + 36 >> 2] | 0, HEAP32[i58 + 40 >> 2] | 0);
michael@0 29563 i74 = HEAP32[i40 >> 2] | 0;
michael@0 29564 i64 = 475;
michael@0 29565 }
michael@0 29566 } while (0);
michael@0 29567 if ((i64 | 0) == 471) {
michael@0 29568 i64 = 0;
michael@0 29569 i61 = HEAP32[i58 + 32 >> 2] | 0;
michael@0 29570 i71 = 0;
michael@0 29571 i72 = (i61 | 0) == -1;
michael@0 29572 i73 = i61;
michael@0 29573 i64 = 474;
michael@0 29574 }
michael@0 29575 do {
michael@0 29576 if ((i64 | 0) == 474) {
michael@0 29577 i64 = 0;
michael@0 29578 if (i71 | i72) {
michael@0 29579 i74 = i59;
michael@0 29580 i64 = 475;
michael@0 29581 break;
michael@0 29582 }
michael@0 29583 i75 = i58 + (i73 << 6) | 0;
michael@0 29584 i76 = i73 + i56 | 0;
michael@0 29585 i77 = i59;
michael@0 29586 }
michael@0 29587 } while (0);
michael@0 29588 if ((i64 | 0) == 475) {
michael@0 29589 i64 = 0;
michael@0 29590 i75 = i58 + 64 | 0;
michael@0 29591 i76 = i56 + 1 | 0;
michael@0 29592 i77 = i74;
michael@0 29593 }
michael@0 29594 if ((i76 | 0) >= (i77 | 0)) {
michael@0 29595 i78 = i57;
michael@0 29596 break L599;
michael@0 29597 }
michael@0 29598 i56 = i76;
michael@0 29599 i57 = i57 + 1 | 0;
michael@0 29600 i58 = i75;
michael@0 29601 d16 = +HEAPF32[i5 >> 2];
michael@0 29602 d17 = +HEAPF32[i28 >> 2];
michael@0 29603 d18 = +HEAPF32[i31 >> 2];
michael@0 29604 d11 = +HEAPF32[i4 >> 2];
michael@0 29605 d34 = +HEAPF32[i3 >> 2];
michael@0 29606 d13 = +HEAPF32[i23 >> 2];
michael@0 29607 i59 = i77;
michael@0 29608 }
michael@0 29609 } else {
michael@0 29610 i78 = 0;
michael@0 29611 }
michael@0 29612 } while (0);
michael@0 29613 if ((HEAP32[2982] | 0) >= (i78 | 0)) {
michael@0 29614 STACKTOP = i8;
michael@0 29615 return;
michael@0 29616 }
michael@0 29617 HEAP32[2982] = i78;
michael@0 29618 STACKTOP = i8;
michael@0 29619 return;
michael@0 29620 }
michael@0 29621 function __ZN20btAlignedObjectArrayI16btBroadphasePairE17quickSortInternalI29btBroadphasePairSortPredicateEEvT_ii(i1, i2, i3, i4) {
michael@0 29622 i1 = i1 | 0;
michael@0 29623 i2 = i2 | 0;
michael@0 29624 i3 = i3 | 0;
michael@0 29625 i4 = i4 | 0;
michael@0 29626 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0;
michael@0 29627 i5 = STACKTOP;
michael@0 29628 STACKTOP = STACKTOP + 16 | 0;
michael@0 29629 i6 = i2;
michael@0 29630 i2 = STACKTOP;
michael@0 29631 STACKTOP = STACKTOP + 1 | 0;
michael@0 29632 STACKTOP = STACKTOP + 7 >> 3 << 3;
michael@0 29633 HEAP8[i2] = HEAP8[i6] | 0;
michael@0 29634 i6 = i5 | 0;
michael@0 29635 i2 = i5 + 8 | 0;
michael@0 29636 i7 = (i4 + i3 | 0) / 2 | 0;
michael@0 29637 i8 = i1 + 12 | 0;
michael@0 29638 i9 = HEAP32[i8 >> 2] | 0;
michael@0 29639 i10 = HEAP32[i9 + (i7 << 4) >> 2] | 0;
michael@0 29640 i11 = HEAP32[i9 + (i7 << 4) + 4 >> 2] | 0;
michael@0 29641 i12 = HEAP32[i9 + (i7 << 4) + 8 >> 2] | 0;
michael@0 29642 i7 = (i10 | 0) == 0;
michael@0 29643 i13 = (i11 | 0) == 0;
michael@0 29644 i14 = i11 + 12 | 0;
michael@0 29645 i15 = i10 + 12 | 0;
michael@0 29646 i16 = i4;
michael@0 29647 i17 = i3;
michael@0 29648 i18 = i9;
michael@0 29649 while (1) {
michael@0 29650 L1160 : do {
michael@0 29651 if (i7) {
michael@0 29652 i9 = i17;
michael@0 29653 while (1) {
michael@0 29654 i19 = HEAP32[i18 + (i9 << 4) >> 2] | 0;
michael@0 29655 i20 = (i19 | 0) == 0;
michael@0 29656 if (i20) {
michael@0 29657 i21 = -1;
michael@0 29658 } else {
michael@0 29659 i21 = HEAP32[i19 + 12 >> 2] | 0;
michael@0 29660 }
michael@0 29661 i22 = HEAP32[i18 + (i9 << 4) + 4 >> 2] | 0;
michael@0 29662 if ((i22 | 0) == 0) {
michael@0 29663 i23 = -1;
michael@0 29664 } else {
michael@0 29665 i23 = HEAP32[i22 + 12 >> 2] | 0;
michael@0 29666 }
michael@0 29667 if (i13) {
michael@0 29668 i24 = -1;
michael@0 29669 } else {
michael@0 29670 i24 = HEAP32[i14 >> 2] | 0;
michael@0 29671 }
michael@0 29672 do {
michael@0 29673 if ((i21 | 0) <= -1) {
michael@0 29674 i25 = i20 & (i23 | 0) > (i24 | 0);
michael@0 29675 if (i25 | i20 ^ 1) {
michael@0 29676 if (i25) {
michael@0 29677 break;
michael@0 29678 } else {
michael@0 29679 i26 = i9;
michael@0 29680 i27 = i19;
michael@0 29681 i28 = i22;
michael@0 29682 break L1160;
michael@0 29683 }
michael@0 29684 }
michael@0 29685 if ((i22 | 0) != (i11 | 0)) {
michael@0 29686 i26 = i9;
michael@0 29687 i27 = i19;
michael@0 29688 i28 = i22;
michael@0 29689 break L1160;
michael@0 29690 }
michael@0 29691 if ((HEAP32[i18 + (i9 << 4) + 8 >> 2] | 0) >>> 0 <= i12 >>> 0) {
michael@0 29692 i26 = i9;
michael@0 29693 i27 = i19;
michael@0 29694 i28 = i22;
michael@0 29695 break L1160;
michael@0 29696 }
michael@0 29697 }
michael@0 29698 } while (0);
michael@0 29699 i9 = i9 + 1 | 0;
michael@0 29700 }
michael@0 29701 } else {
michael@0 29702 if (i13) {
michael@0 29703 i9 = i17;
michael@0 29704 while (1) {
michael@0 29705 i22 = HEAP32[i18 + (i9 << 4) >> 2] | 0;
michael@0 29706 if ((i22 | 0) == 0) {
michael@0 29707 i29 = -1;
michael@0 29708 } else {
michael@0 29709 i29 = HEAP32[i22 + 12 >> 2] | 0;
michael@0 29710 }
michael@0 29711 i19 = HEAP32[i18 + (i9 << 4) + 4 >> 2] | 0;
michael@0 29712 i20 = (i19 | 0) == 0;
michael@0 29713 if (i20) {
michael@0 29714 i30 = -1;
michael@0 29715 } else {
michael@0 29716 i30 = HEAP32[i19 + 12 >> 2] | 0;
michael@0 29717 }
michael@0 29718 do {
michael@0 29719 if ((i29 | 0) <= (HEAP32[i15 >> 2] | 0)) {
michael@0 29720 i25 = (i22 | 0) == (i10 | 0);
michael@0 29721 i31 = i25 & (i30 | 0) > -1;
michael@0 29722 if (i31 | i25 ^ 1) {
michael@0 29723 if (i31) {
michael@0 29724 break;
michael@0 29725 } else {
michael@0 29726 i26 = i9;
michael@0 29727 i27 = i22;
michael@0 29728 i28 = i19;
michael@0 29729 break L1160;
michael@0 29730 }
michael@0 29731 }
michael@0 29732 if (!i20) {
michael@0 29733 i26 = i9;
michael@0 29734 i27 = i22;
michael@0 29735 i28 = i19;
michael@0 29736 break L1160;
michael@0 29737 }
michael@0 29738 if ((HEAP32[i18 + (i9 << 4) + 8 >> 2] | 0) >>> 0 <= i12 >>> 0) {
michael@0 29739 i26 = i9;
michael@0 29740 i27 = i22;
michael@0 29741 i28 = 0;
michael@0 29742 break L1160;
michael@0 29743 }
michael@0 29744 }
michael@0 29745 } while (0);
michael@0 29746 i9 = i9 + 1 | 0;
michael@0 29747 }
michael@0 29748 } else {
michael@0 29749 i9 = i17;
michael@0 29750 while (1) {
michael@0 29751 i22 = HEAP32[i18 + (i9 << 4) >> 2] | 0;
michael@0 29752 if ((i22 | 0) == 0) {
michael@0 29753 i32 = -1;
michael@0 29754 } else {
michael@0 29755 i32 = HEAP32[i22 + 12 >> 2] | 0;
michael@0 29756 }
michael@0 29757 i19 = HEAP32[i18 + (i9 << 4) + 4 >> 2] | 0;
michael@0 29758 if ((i19 | 0) == 0) {
michael@0 29759 i33 = -1;
michael@0 29760 } else {
michael@0 29761 i33 = HEAP32[i19 + 12 >> 2] | 0;
michael@0 29762 }
michael@0 29763 do {
michael@0 29764 if ((i32 | 0) <= (HEAP32[i15 >> 2] | 0)) {
michael@0 29765 i20 = (i22 | 0) == (i10 | 0);
michael@0 29766 i31 = i20 & (i33 | 0) > (HEAP32[i14 >> 2] | 0);
michael@0 29767 if (i31 | i20 ^ 1) {
michael@0 29768 if (i31) {
michael@0 29769 break;
michael@0 29770 } else {
michael@0 29771 i26 = i9;
michael@0 29772 i27 = i22;
michael@0 29773 i28 = i19;
michael@0 29774 break L1160;
michael@0 29775 }
michael@0 29776 }
michael@0 29777 if ((i19 | 0) != (i11 | 0)) {
michael@0 29778 i26 = i9;
michael@0 29779 i27 = i22;
michael@0 29780 i28 = i19;
michael@0 29781 break L1160;
michael@0 29782 }
michael@0 29783 if ((HEAP32[i18 + (i9 << 4) + 8 >> 2] | 0) >>> 0 <= i12 >>> 0) {
michael@0 29784 i26 = i9;
michael@0 29785 i27 = i22;
michael@0 29786 i28 = i19;
michael@0 29787 break L1160;
michael@0 29788 }
michael@0 29789 }
michael@0 29790 } while (0);
michael@0 29791 i9 = i9 + 1 | 0;
michael@0 29792 }
michael@0 29793 }
michael@0 29794 }
michael@0 29795 } while (0);
michael@0 29796 i9 = i16;
michael@0 29797 L1212 : while (1) {
michael@0 29798 if (i7) {
michael@0 29799 i34 = -1;
michael@0 29800 } else {
michael@0 29801 i34 = HEAP32[i15 >> 2] | 0;
michael@0 29802 }
michael@0 29803 i19 = HEAP32[i18 + (i9 << 4) >> 2] | 0;
michael@0 29804 if ((i19 | 0) == 0) {
michael@0 29805 i35 = -1;
michael@0 29806 } else {
michael@0 29807 i35 = HEAP32[i19 + 12 >> 2] | 0;
michael@0 29808 }
michael@0 29809 if (i13) {
michael@0 29810 i36 = -1;
michael@0 29811 } else {
michael@0 29812 i36 = HEAP32[i14 >> 2] | 0;
michael@0 29813 }
michael@0 29814 i22 = HEAP32[i18 + (i9 << 4) + 4 >> 2] | 0;
michael@0 29815 if ((i22 | 0) == 0) {
michael@0 29816 i37 = -1;
michael@0 29817 } else {
michael@0 29818 i37 = HEAP32[i22 + 12 >> 2] | 0;
michael@0 29819 }
michael@0 29820 do {
michael@0 29821 if ((i34 | 0) <= (i35 | 0)) {
michael@0 29822 i31 = (i10 | 0) == (i19 | 0);
michael@0 29823 i20 = i31 & (i36 | 0) > (i37 | 0);
michael@0 29824 if (i20 | i31 ^ 1) {
michael@0 29825 if (i20) {
michael@0 29826 break;
michael@0 29827 } else {
michael@0 29828 break L1212;
michael@0 29829 }
michael@0 29830 }
michael@0 29831 if ((i11 | 0) != (i22 | 0)) {
michael@0 29832 break L1212;
michael@0 29833 }
michael@0 29834 if (i12 >>> 0 <= (HEAP32[i18 + (i9 << 4) + 8 >> 2] | 0) >>> 0) {
michael@0 29835 break L1212;
michael@0 29836 }
michael@0 29837 }
michael@0 29838 } while (0);
michael@0 29839 i9 = i9 - 1 | 0;
michael@0 29840 }
michael@0 29841 if ((i26 | 0) > (i9 | 0)) {
michael@0 29842 i38 = i9;
michael@0 29843 i39 = i26;
michael@0 29844 } else {
michael@0 29845 i22 = HEAP32[i18 + (i26 << 4) + 8 >> 2] | 0;
michael@0 29846 i19 = HEAP32[i18 + (i26 << 4) + 12 >> 2] | 0;
michael@0 29847 i20 = i18 + (i26 << 4) | 0;
michael@0 29848 i31 = i18 + (i9 << 4) | 0;
michael@0 29849 HEAP32[i20 >> 2] = HEAP32[i31 >> 2];
michael@0 29850 HEAP32[i20 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 29851 HEAP32[i20 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 29852 HEAP32[i20 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 29853 i31 = HEAP32[i8 >> 2] | 0;
michael@0 29854 HEAP32[i31 + (i9 << 4) >> 2] = i27;
michael@0 29855 HEAP32[i31 + (i9 << 4) + 4 >> 2] = i28;
michael@0 29856 HEAP32[i31 + (i9 << 4) + 8 >> 2] = i22;
michael@0 29857 HEAP32[i31 + (i9 << 4) + 12 >> 2] = i19;
michael@0 29858 i38 = i9 - 1 | 0;
michael@0 29859 i39 = i26 + 1 | 0;
michael@0 29860 }
michael@0 29861 if ((i39 | 0) > (i38 | 0)) {
michael@0 29862 break;
michael@0 29863 }
michael@0 29864 i16 = i38;
michael@0 29865 i17 = i39;
michael@0 29866 i18 = HEAP32[i8 >> 2] | 0;
michael@0 29867 }
michael@0 29868 if ((i38 | 0) > (i3 | 0)) {
michael@0 29869 __ZN20btAlignedObjectArrayI16btBroadphasePairE17quickSortInternalI29btBroadphasePairSortPredicateEEvT_ii(i1, i6, i3, i38);
michael@0 29870 }
michael@0 29871 if ((i39 | 0) >= (i4 | 0)) {
michael@0 29872 STACKTOP = i5;
michael@0 29873 return;
michael@0 29874 }
michael@0 29875 __ZN20btAlignedObjectArrayI16btBroadphasePairE17quickSortInternalI29btBroadphasePairSortPredicateEEvT_ii(i1, i2, i39, i4);
michael@0 29876 STACKTOP = i5;
michael@0 29877 return;
michael@0 29878 }
michael@0 29879 function __ZN31btDefaultCollisionConfigurationC2ERK34btDefaultCollisionConstructionInfo(i1, i2) {
michael@0 29880 i1 = i1 | 0;
michael@0 29881 i2 = i2 | 0;
michael@0 29882 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0;
michael@0 29883 HEAP32[i1 >> 2] = 2608;
michael@0 29884 i3 = __Z22btAlignedAllocInternalji(360, 16) | 0;
michael@0 29885 if ((i3 | 0) == 0) {
michael@0 29886 i4 = 0;
michael@0 29887 } else {
michael@0 29888 HEAPF32[i3 + 308 >> 2] = 9999999747378752.0e-20;
michael@0 29889 i5 = i3 + 332 | 0;
michael@0 29890 HEAP16[i5 >> 1] = HEAP16[i5 >> 1] & -16;
michael@0 29891 i4 = i3;
michael@0 29892 }
michael@0 29893 i3 = i1 + 32 | 0;
michael@0 29894 HEAP32[i3 >> 2] = i4;
michael@0 29895 i4 = (HEAP32[i2 + 28 >> 2] | 0) == 0;
michael@0 29896 i5 = __Z22btAlignedAllocInternalji(4, 16) | 0;
michael@0 29897 i6 = (i5 | 0) == 0;
michael@0 29898 if (i4) {
michael@0 29899 if (i6) {
michael@0 29900 i7 = 0;
michael@0 29901 } else {
michael@0 29902 HEAP32[i5 >> 2] = 2496;
michael@0 29903 i7 = i5;
michael@0 29904 }
michael@0 29905 HEAP32[i1 + 36 >> 2] = i7;
michael@0 29906 } else {
michael@0 29907 if (i6) {
michael@0 29908 i8 = 0;
michael@0 29909 } else {
michael@0 29910 HEAP32[i5 >> 2] = 2696;
michael@0 29911 i8 = i5;
michael@0 29912 }
michael@0 29913 HEAP32[i1 + 36 >> 2] = i8;
michael@0 29914 }
michael@0 29915 i8 = __Z22btAlignedAllocInternalji(24, 16) | 0;
michael@0 29916 if ((i8 | 0) == 0) {
michael@0 29917 i9 = 0;
michael@0 29918 } else {
michael@0 29919 i5 = i8;
michael@0 29920 __ZN23btConvexConvexAlgorithm10CreateFuncC2EP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i5, HEAP32[i3 >> 2] | 0, HEAP32[i1 + 36 >> 2] | 0);
michael@0 29921 i9 = i5;
michael@0 29922 }
michael@0 29923 HEAP32[i1 + 40 >> 2] = i9;
michael@0 29924 i9 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29925 if ((i9 | 0) == 0) {
michael@0 29926 i10 = 0;
michael@0 29927 } else {
michael@0 29928 HEAP8[i9 + 4 | 0] = 0;
michael@0 29929 HEAP32[i9 >> 2] = 1992;
michael@0 29930 i10 = i9;
michael@0 29931 }
michael@0 29932 HEAP32[i1 + 44 >> 2] = i10;
michael@0 29933 i10 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29934 if ((i10 | 0) == 0) {
michael@0 29935 i11 = 0;
michael@0 29936 } else {
michael@0 29937 HEAP8[i10 + 4 | 0] = 0;
michael@0 29938 HEAP32[i10 >> 2] = 1960;
michael@0 29939 i11 = i10;
michael@0 29940 }
michael@0 29941 HEAP32[i1 + 48 >> 2] = i11;
michael@0 29942 i11 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29943 if ((i11 | 0) == 0) {
michael@0 29944 i12 = 0;
michael@0 29945 } else {
michael@0 29946 HEAP8[i11 + 4 | 0] = 0;
michael@0 29947 HEAP32[i11 >> 2] = 2120;
michael@0 29948 i12 = i11;
michael@0 29949 }
michael@0 29950 HEAP32[i1 + 52 >> 2] = i12;
michael@0 29951 i12 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29952 if ((i12 | 0) == 0) {
michael@0 29953 i13 = 0;
michael@0 29954 } else {
michael@0 29955 HEAP8[i12 + 4 | 0] = 0;
michael@0 29956 HEAP32[i12 >> 2] = 2088;
michael@0 29957 i13 = i12;
michael@0 29958 }
michael@0 29959 HEAP32[i1 + 56 >> 2] = i13;
michael@0 29960 i13 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29961 if ((i13 | 0) == 0) {
michael@0 29962 i14 = 0;
michael@0 29963 } else {
michael@0 29964 HEAP8[i13 + 4 | 0] = 0;
michael@0 29965 HEAP32[i13 >> 2] = 2216;
michael@0 29966 i14 = i13;
michael@0 29967 }
michael@0 29968 HEAP32[i1 + 60 >> 2] = i14;
michael@0 29969 i14 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29970 if ((i14 | 0) == 0) {
michael@0 29971 i15 = 0;
michael@0 29972 } else {
michael@0 29973 HEAP8[i14 + 4 | 0] = 0;
michael@0 29974 HEAP32[i14 >> 2] = 2024;
michael@0 29975 i15 = i14;
michael@0 29976 }
michael@0 29977 HEAP32[i1 + 64 >> 2] = i15;
michael@0 29978 i15 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29979 if ((i15 | 0) == 0) {
michael@0 29980 i16 = 0;
michael@0 29981 } else {
michael@0 29982 HEAP8[i15 + 4 | 0] = 0;
michael@0 29983 HEAP32[i15 >> 2] = 1928;
michael@0 29984 i16 = i15;
michael@0 29985 }
michael@0 29986 HEAP32[i1 + 72 >> 2] = i16;
michael@0 29987 i16 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29988 if ((i16 | 0) == 0) {
michael@0 29989 i17 = 0;
michael@0 29990 } else {
michael@0 29991 HEAP8[i16 + 4 | 0] = 0;
michael@0 29992 HEAP32[i16 >> 2] = 1928;
michael@0 29993 i17 = i16;
michael@0 29994 }
michael@0 29995 HEAP32[i1 + 76 >> 2] = i17;
michael@0 29996 HEAP8[i17 + 4 | 0] = 1;
michael@0 29997 i17 = __Z22btAlignedAllocInternalji(8, 16) | 0;
michael@0 29998 if ((i17 | 0) == 0) {
michael@0 29999 i18 = 0;
michael@0 30000 } else {
michael@0 30001 HEAP8[i17 + 4 | 0] = 0;
michael@0 30002 HEAP32[i17 >> 2] = 2152;
michael@0 30003 i18 = i17;
michael@0 30004 }
michael@0 30005 HEAP32[i1 + 68 >> 2] = i18;
michael@0 30006 i18 = __Z22btAlignedAllocInternalji(16, 16) | 0;
michael@0 30007 if ((i18 | 0) == 0) {
michael@0 30008 i19 = 0;
michael@0 30009 } else {
michael@0 30010 HEAP8[i18 + 4 | 0] = 0;
michael@0 30011 HEAP32[i18 >> 2] = 2056;
michael@0 30012 HEAP32[i18 + 8 >> 2] = 1;
michael@0 30013 HEAP32[i18 + 12 >> 2] = 1;
michael@0 30014 i19 = i18;
michael@0 30015 }
michael@0 30016 HEAP32[i1 + 84 >> 2] = i19;
michael@0 30017 i19 = __Z22btAlignedAllocInternalji(16, 16) | 0;
michael@0 30018 if ((i19 | 0) == 0) {
michael@0 30019 i20 = 0;
michael@0 30020 } else {
michael@0 30021 HEAP8[i19 + 4 | 0] = 0;
michael@0 30022 HEAP32[i19 >> 2] = 2056;
michael@0 30023 HEAP32[i19 + 8 >> 2] = 1;
michael@0 30024 HEAP32[i19 + 12 >> 2] = 1;
michael@0 30025 i20 = i19;
michael@0 30026 }
michael@0 30027 HEAP32[i1 + 80 >> 2] = i20;
michael@0 30028 HEAP8[i20 + 4 | 0] = 1;
michael@0 30029 i20 = HEAP32[i2 + 20 >> 2] | 0;
michael@0 30030 i19 = (i20 | 0) < 36 ? 36 : i20;
michael@0 30031 i20 = (i19 | 0) > 80 ? i19 : 80;
michael@0 30032 i19 = (i20 | 0) > 44 ? i20 : 44;
michael@0 30033 i20 = HEAP32[i2 >> 2] | 0;
michael@0 30034 i18 = i1 + 12 | 0;
michael@0 30035 if ((i20 | 0) == 0) {
michael@0 30036 HEAP8[i18] = 1;
michael@0 30037 i17 = __Z22btAlignedAllocInternalji(20, 16) | 0;
michael@0 30038 if ((i17 | 0) == 0) {
michael@0 30039 i21 = 0;
michael@0 30040 } else {
michael@0 30041 i16 = HEAP32[i2 + 24 >> 2] | 0;
michael@0 30042 _memset(i17 | 0, 0, 17);
michael@0 30043 i15 = i17;
michael@0 30044 HEAP32[i15 >> 2] = 0;
michael@0 30045 HEAP32[i17 + 8 >> 2] = 0;
michael@0 30046 HEAP32[i15 >> 2] = __Z22btAlignedAllocInternalji(i16, 16) | 0;
michael@0 30047 HEAP32[i17 + 4 >> 2] = i16;
michael@0 30048 i21 = i17;
michael@0 30049 }
michael@0 30050 HEAP32[i1 + 8 >> 2] = i21;
michael@0 30051 } else {
michael@0 30052 HEAP8[i18] = 0;
michael@0 30053 HEAP32[i1 + 8 >> 2] = i20;
michael@0 30054 }
michael@0 30055 i20 = HEAP32[i2 + 4 >> 2] | 0;
michael@0 30056 i18 = i1 + 20 | 0;
michael@0 30057 if ((i20 | 0) == 0) {
michael@0 30058 HEAP8[i18] = 1;
michael@0 30059 i21 = __Z22btAlignedAllocInternalji(20, 16) | 0;
michael@0 30060 if ((i21 | 0) == 0) {
michael@0 30061 i22 = 0;
michael@0 30062 } else {
michael@0 30063 i17 = i21;
michael@0 30064 i16 = HEAP32[i2 + 12 >> 2] | 0;
michael@0 30065 i15 = i21;
michael@0 30066 HEAP32[i15 >> 2] = 1140;
michael@0 30067 i14 = i21 + 4 | 0;
michael@0 30068 HEAP32[i14 >> 2] = i16;
michael@0 30069 i13 = __Z22btAlignedAllocInternalji(i16 * 1140 | 0, 16) | 0;
michael@0 30070 HEAP32[i21 + 16 >> 2] = i13;
michael@0 30071 HEAP32[i21 + 12 >> 2] = i13;
michael@0 30072 i16 = HEAP32[i14 >> 2] | 0;
michael@0 30073 HEAP32[i21 + 8 >> 2] = i16;
michael@0 30074 i21 = i16 - 1 | 0;
michael@0 30075 if ((i21 | 0) == 0) {
michael@0 30076 i23 = i13;
michael@0 30077 } else {
michael@0 30078 i16 = HEAP32[i15 >> 2] | 0;
michael@0 30079 i15 = i13;
michael@0 30080 i14 = i21;
michael@0 30081 while (1) {
michael@0 30082 i12 = i15 + i16 | 0;
michael@0 30083 HEAP32[i15 >> 2] = i12;
michael@0 30084 i11 = i14 - 1 | 0;
michael@0 30085 if ((i11 | 0) == 0) {
michael@0 30086 break;
michael@0 30087 } else {
michael@0 30088 i15 = i12;
michael@0 30089 i14 = i11;
michael@0 30090 }
michael@0 30091 }
michael@0 30092 i23 = i13 + (Math_imul(i16, i21) | 0) | 0;
michael@0 30093 }
michael@0 30094 HEAP32[i23 >> 2] = 0;
michael@0 30095 i22 = i17;
michael@0 30096 }
michael@0 30097 HEAP32[i1 + 16 >> 2] = i22;
michael@0 30098 } else {
michael@0 30099 HEAP8[i18] = 0;
michael@0 30100 HEAP32[i1 + 16 >> 2] = i20;
michael@0 30101 }
michael@0 30102 i20 = HEAP32[i2 + 8 >> 2] | 0;
michael@0 30103 i18 = i1 + 28 | 0;
michael@0 30104 if ((i20 | 0) != 0) {
michael@0 30105 HEAP8[i18] = 0;
michael@0 30106 HEAP32[i1 + 24 >> 2] = i20;
michael@0 30107 return;
michael@0 30108 }
michael@0 30109 HEAP8[i18] = 1;
michael@0 30110 i18 = __Z22btAlignedAllocInternalji(20, 16) | 0;
michael@0 30111 if ((i18 | 0) == 0) {
michael@0 30112 i24 = 0;
michael@0 30113 } else {
michael@0 30114 i20 = i18;
michael@0 30115 i22 = HEAP32[i2 + 16 >> 2] | 0;
michael@0 30116 i2 = i18;
michael@0 30117 HEAP32[i2 >> 2] = i19;
michael@0 30118 i17 = i18 + 4 | 0;
michael@0 30119 HEAP32[i17 >> 2] = i22;
michael@0 30120 i23 = __Z22btAlignedAllocInternalji(Math_imul(i22, i19) | 0, 16) | 0;
michael@0 30121 HEAP32[i18 + 16 >> 2] = i23;
michael@0 30122 HEAP32[i18 + 12 >> 2] = i23;
michael@0 30123 i19 = HEAP32[i17 >> 2] | 0;
michael@0 30124 HEAP32[i18 + 8 >> 2] = i19;
michael@0 30125 i18 = i19 - 1 | 0;
michael@0 30126 if ((i18 | 0) == 0) {
michael@0 30127 i25 = i23;
michael@0 30128 } else {
michael@0 30129 i19 = HEAP32[i2 >> 2] | 0;
michael@0 30130 i2 = i23;
michael@0 30131 i17 = i18;
michael@0 30132 while (1) {
michael@0 30133 i22 = i2 + i19 | 0;
michael@0 30134 HEAP32[i2 >> 2] = i22;
michael@0 30135 i21 = i17 - 1 | 0;
michael@0 30136 if ((i21 | 0) == 0) {
michael@0 30137 break;
michael@0 30138 } else {
michael@0 30139 i2 = i22;
michael@0 30140 i17 = i21;
michael@0 30141 }
michael@0 30142 }
michael@0 30143 i25 = i23 + (Math_imul(i19, i18) | 0) | 0;
michael@0 30144 }
michael@0 30145 HEAP32[i25 >> 2] = 0;
michael@0 30146 i24 = i20;
michael@0 30147 }
michael@0 30148 HEAP32[i1 + 24 >> 2] = i24;
michael@0 30149 return;
michael@0 30150 }
michael@0 30151 function __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i2, i3) {
michael@0 30152 i1 = i1 | 0;
michael@0 30153 i2 = i2 | 0;
michael@0 30154 i3 = i3 | 0;
michael@0 30155 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, i38 = 0, i39 = 0;
michael@0 30156 i4 = i1 + 1116 | 0;
michael@0 30157 i5 = HEAP32[i4 >> 2] | 0;
michael@0 30158 if ((i5 | 0) <= 0) {
michael@0 30159 return;
michael@0 30160 }
michael@0 30161 i6 = i2 | 0;
michael@0 30162 i7 = i2 + 4 | 0;
michael@0 30163 i8 = i2 + 8 | 0;
michael@0 30164 i9 = i2 + 48 | 0;
michael@0 30165 i10 = i2 + 16 | 0;
michael@0 30166 i11 = i2 + 20 | 0;
michael@0 30167 i12 = i2 + 24 | 0;
michael@0 30168 i13 = i2 + 52 | 0;
michael@0 30169 i14 = i2 + 32 | 0;
michael@0 30170 i15 = i2 + 36 | 0;
michael@0 30171 i16 = i2 + 40 | 0;
michael@0 30172 i17 = i2 + 56 | 0;
michael@0 30173 i2 = i3 | 0;
michael@0 30174 i18 = i3 + 4 | 0;
michael@0 30175 i19 = i3 + 8 | 0;
michael@0 30176 i20 = i3 + 48 | 0;
michael@0 30177 i21 = i3 + 16 | 0;
michael@0 30178 i22 = i3 + 20 | 0;
michael@0 30179 i23 = i3 + 24 | 0;
michael@0 30180 i24 = i3 + 52 | 0;
michael@0 30181 i25 = i3 + 32 | 0;
michael@0 30182 i26 = i3 + 36 | 0;
michael@0 30183 i27 = i3 + 40 | 0;
michael@0 30184 i28 = i3 + 56 | 0;
michael@0 30185 i3 = i5;
michael@0 30186 do {
michael@0 30187 i3 = i3 - 1 | 0;
michael@0 30188 d29 = +HEAPF32[i1 + 4 + (i3 * 276 | 0) >> 2];
michael@0 30189 d30 = +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 4 >> 2];
michael@0 30190 d31 = +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 8 >> 2];
michael@0 30191 d32 = +HEAPF32[i9 >> 2] + (+HEAPF32[i6 >> 2] * d29 + +HEAPF32[i7 >> 2] * d30 + +HEAPF32[i8 >> 2] * d31);
michael@0 30192 d33 = +HEAPF32[i13 >> 2] + (d29 * +HEAPF32[i10 >> 2] + d30 * +HEAPF32[i11 >> 2] + d31 * +HEAPF32[i12 >> 2]);
michael@0 30193 d34 = +HEAPF32[i17 >> 2] + (d29 * +HEAPF32[i14 >> 2] + d30 * +HEAPF32[i15 >> 2] + d31 * +HEAPF32[i16 >> 2]);
michael@0 30194 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 48 >> 2] = d32;
michael@0 30195 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 52 >> 2] = d33;
michael@0 30196 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 56 >> 2] = d34;
michael@0 30197 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 60 >> 2] = 0.0;
michael@0 30198 d31 = +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 16 >> 2];
michael@0 30199 d30 = +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 20 >> 2];
michael@0 30200 d29 = +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 24 >> 2];
michael@0 30201 d35 = +HEAPF32[i20 >> 2] + (+HEAPF32[i2 >> 2] * d31 + +HEAPF32[i18 >> 2] * d30 + +HEAPF32[i19 >> 2] * d29);
michael@0 30202 d36 = +HEAPF32[i24 >> 2] + (d31 * +HEAPF32[i21 >> 2] + d30 * +HEAPF32[i22 >> 2] + d29 * +HEAPF32[i23 >> 2]);
michael@0 30203 d37 = +HEAPF32[i28 >> 2] + (d31 * +HEAPF32[i25 >> 2] + d30 * +HEAPF32[i26 >> 2] + d29 * +HEAPF32[i27 >> 2]);
michael@0 30204 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 32 >> 2] = d35;
michael@0 30205 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 36 >> 2] = d36;
michael@0 30206 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 40 >> 2] = d37;
michael@0 30207 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 44 >> 2] = 0.0;
michael@0 30208 HEAPF32[i1 + 4 + (i3 * 276 | 0) + 80 >> 2] = (d32 - d35) * +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 64 >> 2] + (d33 - d36) * +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 68 >> 2] + (d34 - d37) * +HEAPF32[i1 + 4 + (i3 * 276 | 0) + 72 >> 2];
michael@0 30209 i5 = i1 + 4 + (i3 * 276 | 0) + 144 | 0;
michael@0 30210 HEAP32[i5 >> 2] = (HEAP32[i5 >> 2] | 0) + 1;
michael@0 30211 } while ((i3 | 0) > 0);
michael@0 30212 i3 = HEAP32[i4 >> 2] | 0;
michael@0 30213 if ((i3 | 0) <= 0) {
michael@0 30214 return;
michael@0 30215 }
michael@0 30216 i27 = i1 + 1120 | 0;
michael@0 30217 i26 = i1 + 1124 | 0;
michael@0 30218 i25 = i1 + 1108 | 0;
michael@0 30219 i28 = i1 + 1112 | 0;
michael@0 30220 i23 = i3;
michael@0 30221 do {
michael@0 30222 i23 = i23 - 1 | 0;
michael@0 30223 i3 = i1 + 4 + (i23 * 276 | 0) | 0;
michael@0 30224 d37 = +HEAPF32[i1 + 4 + (i23 * 276 | 0) + 80 >> 2];
michael@0 30225 do {
michael@0 30226 if (d37 > +HEAPF32[((HEAP32[i1 + 4 + (i23 * 276 | 0) + 144 >> 2] | 0) > 1 ? i27 : i26) >> 2]) {
michael@0 30227 i22 = i1 + 4 + (i23 * 276 | 0) + 108 | 0;
michael@0 30228 i21 = HEAP32[i22 >> 2] | 0;
michael@0 30229 do {
michael@0 30230 if ((i21 | 0) != 0) {
michael@0 30231 i24 = HEAP32[3008] | 0;
michael@0 30232 if ((i24 | 0) == 0) {
michael@0 30233 break;
michael@0 30234 }
michael@0 30235 FUNCTION_TABLE_ii[i24 & 127](i21) | 0;
michael@0 30236 HEAP32[i22 >> 2] = 0;
michael@0 30237 }
michael@0 30238 } while (0);
michael@0 30239 i22 = HEAP32[i4 >> 2] | 0;
michael@0 30240 i21 = i22 - 1 | 0;
michael@0 30241 if ((i21 | 0) == (i23 | 0)) {
michael@0 30242 i38 = i22;
michael@0 30243 } else {
michael@0 30244 i22 = i3;
michael@0 30245 i24 = i1 + 4 + (i21 * 276 | 0) | 0;
michael@0 30246 _memcpy(i22 | 0, i24 | 0, 276) | 0;
michael@0 30247 HEAP32[i1 + 4 + (i21 * 276 | 0) + 108 >> 2] = 0;
michael@0 30248 HEAPF32[i1 + 4 + (i21 * 276 | 0) + 208 >> 2] = 0.0;
michael@0 30249 HEAPF32[i1 + 4 + (i21 * 276 | 0) + 240 >> 2] = 0.0;
michael@0 30250 HEAPF32[i1 + 4 + (i21 * 276 | 0) + 272 >> 2] = 0.0;
michael@0 30251 HEAPF32[i1 + 4 + (i21 * 276 | 0) + 112 >> 2] = 0.0;
michael@0 30252 HEAP8[i1 + 4 + (i21 * 276 | 0) + 116 | 0] = 0;
michael@0 30253 HEAPF32[i1 + 4 + (i21 * 276 | 0) + 120 >> 2] = 0.0;
michael@0 30254 HEAPF32[i1 + 4 + (i21 * 276 | 0) + 124 >> 2] = 0.0;
michael@0 30255 HEAP32[i1 + 4 + (i21 * 276 | 0) + 144 >> 2] = 0;
michael@0 30256 i38 = HEAP32[i4 >> 2] | 0;
michael@0 30257 }
michael@0 30258 HEAP32[i4 >> 2] = i38 - 1;
michael@0 30259 } else {
michael@0 30260 d34 = +HEAPF32[i1 + 4 + (i23 * 276 | 0) + 32 >> 2] - (+HEAPF32[i1 + 4 + (i23 * 276 | 0) + 48 >> 2] - d37 * +HEAPF32[i1 + 4 + (i23 * 276 | 0) + 64 >> 2]);
michael@0 30261 d36 = +HEAPF32[i1 + 4 + (i23 * 276 | 0) + 36 >> 2] - (+HEAPF32[i1 + 4 + (i23 * 276 | 0) + 52 >> 2] - d37 * +HEAPF32[i1 + 4 + (i23 * 276 | 0) + 68 >> 2]);
michael@0 30262 d33 = +HEAPF32[i1 + 4 + (i23 * 276 | 0) + 40 >> 2] - (+HEAPF32[i1 + 4 + (i23 * 276 | 0) + 56 >> 2] - d37 * +HEAPF32[i1 + 4 + (i23 * 276 | 0) + 72 >> 2]);
michael@0 30263 d35 = +HEAPF32[i27 >> 2];
michael@0 30264 if (d34 * d34 + d36 * d36 + d33 * d33 <= d35 * d35) {
michael@0 30265 i21 = HEAP32[3006] | 0;
michael@0 30266 if ((i21 | 0) == 0) {
michael@0 30267 break;
michael@0 30268 }
michael@0 30269 i24 = HEAP32[i25 >> 2] | 0;
michael@0 30270 i22 = HEAP32[i28 >> 2] | 0;
michael@0 30271 FUNCTION_TABLE_iiii[i21 & 31](i3, i24, i22) | 0;
michael@0 30272 break;
michael@0 30273 }
michael@0 30274 i22 = i1 + 4 + (i23 * 276 | 0) + 108 | 0;
michael@0 30275 i24 = HEAP32[i22 >> 2] | 0;
michael@0 30276 do {
michael@0 30277 if ((i24 | 0) != 0) {
michael@0 30278 i21 = HEAP32[3008] | 0;
michael@0 30279 if ((i21 | 0) == 0) {
michael@0 30280 break;
michael@0 30281 }
michael@0 30282 FUNCTION_TABLE_ii[i21 & 127](i24) | 0;
michael@0 30283 HEAP32[i22 >> 2] = 0;
michael@0 30284 }
michael@0 30285 } while (0);
michael@0 30286 i22 = HEAP32[i4 >> 2] | 0;
michael@0 30287 i24 = i22 - 1 | 0;
michael@0 30288 if ((i24 | 0) == (i23 | 0)) {
michael@0 30289 i39 = i22;
michael@0 30290 } else {
michael@0 30291 i22 = i3;
michael@0 30292 i21 = i1 + 4 + (i24 * 276 | 0) | 0;
michael@0 30293 _memcpy(i22 | 0, i21 | 0, 276) | 0;
michael@0 30294 HEAP32[i1 + 4 + (i24 * 276 | 0) + 108 >> 2] = 0;
michael@0 30295 HEAPF32[i1 + 4 + (i24 * 276 | 0) + 208 >> 2] = 0.0;
michael@0 30296 HEAPF32[i1 + 4 + (i24 * 276 | 0) + 240 >> 2] = 0.0;
michael@0 30297 HEAPF32[i1 + 4 + (i24 * 276 | 0) + 272 >> 2] = 0.0;
michael@0 30298 HEAPF32[i1 + 4 + (i24 * 276 | 0) + 112 >> 2] = 0.0;
michael@0 30299 HEAP8[i1 + 4 + (i24 * 276 | 0) + 116 | 0] = 0;
michael@0 30300 HEAPF32[i1 + 4 + (i24 * 276 | 0) + 120 >> 2] = 0.0;
michael@0 30301 HEAPF32[i1 + 4 + (i24 * 276 | 0) + 124 >> 2] = 0.0;
michael@0 30302 HEAP32[i1 + 4 + (i24 * 276 | 0) + 144 >> 2] = 0;
michael@0 30303 i39 = HEAP32[i4 >> 2] | 0;
michael@0 30304 }
michael@0 30305 HEAP32[i4 >> 2] = i39 - 1;
michael@0 30306 }
michael@0 30307 } while (0);
michael@0 30308 } while ((i23 | 0) > 0);
michael@0 30309 return;
michael@0 30310 }
michael@0 30311 function __ZN31btConvexPlaneCollisionAlgorithm20collideSingleContactERK12btQuaternionP17btCollisionObjectS4_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5, i6) {
michael@0 30312 i1 = i1 | 0;
michael@0 30313 i2 = i2 | 0;
michael@0 30314 i3 = i3 | 0;
michael@0 30315 i4 = i4 | 0;
michael@0 30316 i5 = i5 | 0;
michael@0 30317 i6 = i6 | 0;
michael@0 30318 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, i42 = 0, d43 = 0.0, i44 = 0, d45 = 0.0, i46 = 0, d47 = 0.0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, d61 = 0.0, d62 = 0.0, d63 = 0.0, i64 = 0, i65 = 0;
michael@0 30319 i5 = STACKTOP;
michael@0 30320 STACKTOP = STACKTOP + 64 | 0;
michael@0 30321 i7 = i5 | 0;
michael@0 30322 i8 = i5 + 16 | 0;
michael@0 30323 i9 = i5 + 32 | 0;
michael@0 30324 i10 = i5 + 48 | 0;
michael@0 30325 i11 = (HEAP8[i1 + 16 | 0] | 0) != 0;
michael@0 30326 i12 = i11 ? i4 : i3;
michael@0 30327 i13 = i11 ? i3 : i4;
michael@0 30328 i4 = HEAP32[i12 + 192 >> 2] | 0;
michael@0 30329 i3 = HEAP32[i13 + 192 >> 2] | 0;
michael@0 30330 d14 = +HEAPF32[i12 + 4 >> 2];
michael@0 30331 d15 = +HEAPF32[i12 + 8 >> 2];
michael@0 30332 d16 = +HEAPF32[i12 + 12 >> 2];
michael@0 30333 d17 = +HEAPF32[i12 + 20 >> 2];
michael@0 30334 d18 = +HEAPF32[i12 + 24 >> 2];
michael@0 30335 d19 = +HEAPF32[i12 + 28 >> 2];
michael@0 30336 d20 = +HEAPF32[i12 + 36 >> 2];
michael@0 30337 d21 = +HEAPF32[i12 + 40 >> 2];
michael@0 30338 d22 = +HEAPF32[i12 + 44 >> 2];
michael@0 30339 d23 = +HEAPF32[i12 + 52 >> 2];
michael@0 30340 d24 = +HEAPF32[i12 + 56 >> 2];
michael@0 30341 d25 = +HEAPF32[i12 + 60 >> 2];
michael@0 30342 i12 = i13 + 4 | 0;
michael@0 30343 i11 = i13 + 20 | 0;
michael@0 30344 i26 = i13 + 36 | 0;
michael@0 30345 i27 = i13 + 8 | 0;
michael@0 30346 i28 = i13 + 24 | 0;
michael@0 30347 i29 = i13 + 40 | 0;
michael@0 30348 i30 = i13 + 12 | 0;
michael@0 30349 i31 = i13 + 28 | 0;
michael@0 30350 i32 = i13 + 44 | 0;
michael@0 30351 d33 = +HEAPF32[i12 >> 2];
michael@0 30352 d34 = +HEAPF32[i11 >> 2];
michael@0 30353 d35 = +HEAPF32[i26 >> 2];
michael@0 30354 d36 = +HEAPF32[i27 >> 2];
michael@0 30355 d37 = +HEAPF32[i28 >> 2];
michael@0 30356 d38 = +HEAPF32[i29 >> 2];
michael@0 30357 d39 = +HEAPF32[i30 >> 2];
michael@0 30358 d40 = +HEAPF32[i31 >> 2];
michael@0 30359 d41 = +HEAPF32[i32 >> 2];
michael@0 30360 i42 = i13 + 52 | 0;
michael@0 30361 d43 = -0.0 - +HEAPF32[i42 >> 2];
michael@0 30362 i44 = i13 + 56 | 0;
michael@0 30363 d45 = -0.0 - +HEAPF32[i44 >> 2];
michael@0 30364 i46 = i13 + 60 | 0;
michael@0 30365 d47 = -0.0 - +HEAPF32[i46 >> 2];
michael@0 30366 d48 = +HEAPF32[i2 >> 2];
michael@0 30367 d49 = +HEAPF32[i2 + 4 >> 2];
michael@0 30368 d50 = +HEAPF32[i2 + 8 >> 2];
michael@0 30369 d51 = +HEAPF32[i2 + 12 >> 2];
michael@0 30370 d52 = 2.0 / (d48 * d48 + d49 * d49 + d50 * d50 + d51 * d51);
michael@0 30371 d53 = d48 * d52;
michael@0 30372 d54 = d49 * d52;
michael@0 30373 d55 = d50 * d52;
michael@0 30374 d52 = d51 * d53;
michael@0 30375 d56 = d51 * d54;
michael@0 30376 d57 = d51 * d55;
michael@0 30377 d51 = d48 * d53;
michael@0 30378 d53 = d48 * d54;
michael@0 30379 d58 = d48 * d55;
michael@0 30380 d48 = d49 * d54;
michael@0 30381 d54 = d49 * d55;
michael@0 30382 d49 = d50 * d55;
michael@0 30383 d55 = 1.0 - (d48 + d49);
michael@0 30384 d50 = d53 - d57;
michael@0 30385 d59 = d58 + d56;
michael@0 30386 d60 = d53 + d57;
michael@0 30387 d57 = 1.0 - (d51 + d49);
michael@0 30388 d49 = d54 - d52;
michael@0 30389 d53 = d58 - d56;
michael@0 30390 d56 = d54 + d52;
michael@0 30391 d52 = 1.0 - (d51 + d48);
michael@0 30392 d48 = d16 * d53 + (d15 * d60 + d14 * d55);
michael@0 30393 d51 = d16 * d56 + (d14 * d50 + d15 * d57);
michael@0 30394 d54 = d14 * d59 + d15 * d49 + d16 * d52;
michael@0 30395 d58 = d19 * d53 + (d18 * d60 + d17 * d55);
michael@0 30396 d61 = d19 * d56 + (d17 * d50 + d18 * d57);
michael@0 30397 d62 = d17 * d59 + d18 * d49 + d19 * d52;
michael@0 30398 d63 = d22 * d53 + (d21 * d60 + d20 * d55);
michael@0 30399 d55 = d22 * d56 + (d20 * d50 + d21 * d57);
michael@0 30400 d57 = d20 * d59 + d21 * d49 + d22 * d52;
michael@0 30401 i2 = HEAP32[(HEAP32[i4 >> 2] | 0) + 60 >> 2] | 0;
michael@0 30402 i13 = i3 + 48 | 0;
michael@0 30403 d52 = -0.0 - +HEAPF32[i13 >> 2];
michael@0 30404 i64 = i3 + 52 | 0;
michael@0 30405 d49 = -0.0 - +HEAPF32[i64 >> 2];
michael@0 30406 i65 = i3 + 56 | 0;
michael@0 30407 d59 = -0.0 - +HEAPF32[i65 >> 2];
michael@0 30408 HEAPF32[i8 >> 2] = (d41 * d63 + (d39 * d48 + d40 * d58)) * d59 + ((d35 * d63 + (d33 * d48 + d34 * d58)) * d52 + (d38 * d63 + (d36 * d48 + d37 * d58)) * d49);
michael@0 30409 HEAPF32[i8 + 4 >> 2] = (d41 * d55 + (d39 * d51 + d40 * d61)) * d59 + ((d35 * d55 + (d33 * d51 + d34 * d61)) * d52 + (d38 * d55 + (d36 * d51 + d37 * d61)) * d49);
michael@0 30410 HEAPF32[i8 + 8 >> 2] = (d41 * d57 + (d39 * d54 + d40 * d62)) * d59 + ((d35 * d57 + (d33 * d54 + d34 * d62)) * d52 + (d38 * d57 + (d36 * d54 + d37 * d62)) * d49);
michael@0 30411 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 30412 FUNCTION_TABLE_viii[i2 & 127](i7, i4, i8);
michael@0 30413 d49 = +HEAPF32[i7 >> 2];
michael@0 30414 d62 = +HEAPF32[i7 + 4 >> 2];
michael@0 30415 d54 = +HEAPF32[i7 + 8 >> 2];
michael@0 30416 d57 = d23 * d33 + d24 * d34 + d25 * d35 + (d33 * d43 + d34 * d45 + d35 * d47) + ((d14 * d33 + d17 * d34 + d20 * d35) * d49 + (d15 * d33 + d18 * d34 + d21 * d35) * d62 + (d16 * d33 + d19 * d34 + d22 * d35) * d54);
michael@0 30417 d35 = d23 * d36 + d24 * d37 + d25 * d38 + (d36 * d43 + d37 * d45 + d38 * d47) + ((d14 * d36 + d17 * d37 + d20 * d38) * d49 + (d15 * d36 + d18 * d37 + d21 * d38) * d62 + (d16 * d36 + d19 * d37 + d22 * d38) * d54);
michael@0 30418 d38 = d23 * d39 + d24 * d40 + d25 * d41 + (d39 * d43 + d40 * d45 + d41 * d47) + ((d14 * d39 + d17 * d40 + d20 * d41) * d49 + (d15 * d39 + d18 * d40 + d21 * d41) * d62 + (d16 * d39 + d19 * d40 + d22 * d41) * d54);
michael@0 30419 d54 = +HEAPF32[i13 >> 2];
michael@0 30420 d41 = +HEAPF32[i64 >> 2];
michael@0 30421 d22 = +HEAPF32[i65 >> 2];
michael@0 30422 d40 = d22 * d38 + (d54 * d57 + d41 * d35) - +HEAPF32[i3 + 64 >> 2];
michael@0 30423 d19 = d57 - d54 * d40;
michael@0 30424 d54 = d35 - d41 * d40;
michael@0 30425 d41 = d38 - d22 * d40;
michael@0 30426 d22 = +HEAPF32[i12 >> 2];
michael@0 30427 d38 = +HEAPF32[i27 >> 2];
michael@0 30428 d35 = +HEAPF32[i30 >> 2];
michael@0 30429 d57 = +HEAPF32[i42 >> 2];
michael@0 30430 d39 = +HEAPF32[i11 >> 2];
michael@0 30431 d16 = +HEAPF32[i28 >> 2];
michael@0 30432 d62 = +HEAPF32[i31 >> 2];
michael@0 30433 d21 = +HEAPF32[i44 >> 2];
michael@0 30434 d18 = +HEAPF32[i26 >> 2];
michael@0 30435 d15 = +HEAPF32[i29 >> 2];
michael@0 30436 d49 = +HEAPF32[i32 >> 2];
michael@0 30437 d20 = +HEAPF32[i46 >> 2];
michael@0 30438 i46 = i1 + 12 | 0;
michael@0 30439 i1 = d40 < +__ZNK20btPersistentManifold27getContactBreakingThresholdEv(HEAP32[i46 >> 2] | 0);
michael@0 30440 HEAP32[i6 + 4 >> 2] = HEAP32[i46 >> 2];
michael@0 30441 if (!i1) {
michael@0 30442 STACKTOP = i5;
michael@0 30443 return;
michael@0 30444 }
michael@0 30445 d17 = +HEAPF32[i13 >> 2];
michael@0 30446 d14 = +HEAPF32[i64 >> 2];
michael@0 30447 d47 = +HEAPF32[i65 >> 2];
michael@0 30448 d45 = d17 * +HEAPF32[i11 >> 2] + d14 * +HEAPF32[i28 >> 2] + d47 * +HEAPF32[i31 >> 2];
michael@0 30449 d43 = d17 * +HEAPF32[i26 >> 2] + d14 * +HEAPF32[i29 >> 2] + d47 * +HEAPF32[i32 >> 2];
michael@0 30450 HEAPF32[i9 >> 2] = +HEAPF32[i12 >> 2] * d17 + +HEAPF32[i27 >> 2] * d14 + +HEAPF32[i30 >> 2] * d47;
michael@0 30451 HEAPF32[i9 + 4 >> 2] = d45;
michael@0 30452 HEAPF32[i9 + 8 >> 2] = d43;
michael@0 30453 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 30454 HEAPF32[i10 >> 2] = d57 + (d35 * d41 + (d22 * d19 + d38 * d54));
michael@0 30455 HEAPF32[i10 + 4 >> 2] = d21 + (d19 * d39 + d54 * d16 + d41 * d62);
michael@0 30456 HEAPF32[i10 + 8 >> 2] = d20 + (d19 * d18 + d54 * d15 + d41 * d49);
michael@0 30457 HEAPF32[i10 + 12 >> 2] = 0.0;
michael@0 30458 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i6 >> 2] | 0) + 16 >> 2] & 15](i6, i9, i10, d40);
michael@0 30459 STACKTOP = i5;
michael@0 30460 return;
michael@0 30461 }
michael@0 30462 function __ZN11btRigidBody14setupRigidBodyERKNS_27btRigidBodyConstructionInfoE(i1, i2) {
michael@0 30463 i1 = i1 | 0;
michael@0 30464 i2 = i2 | 0;
michael@0 30465 var i3 = 0, i4 = 0, i5 = 0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0;
michael@0 30466 HEAP32[i1 + 232 >> 2] = 2;
michael@0 30467 _memset(i1 + 304 | 0, 0, 32);
michael@0 30468 HEAPF32[i1 + 536 >> 2] = 1.0;
michael@0 30469 HEAPF32[i1 + 540 >> 2] = 1.0;
michael@0 30470 HEAPF32[i1 + 544 >> 2] = 1.0;
michael@0 30471 HEAPF32[i1 + 548 >> 2] = 0.0;
michael@0 30472 i3 = i1 + 340 | 0;
michael@0 30473 HEAPF32[i3 >> 2] = 1.0;
michael@0 30474 i4 = i1 + 344 | 0;
michael@0 30475 HEAPF32[i4 >> 2] = 1.0;
michael@0 30476 i5 = i1 + 348 | 0;
michael@0 30477 HEAPF32[i5 >> 2] = 1.0;
michael@0 30478 _memset(i1 + 352 | 0, 0, 36);
michael@0 30479 _memset(i1 + 404 | 0, 0, 32);
michael@0 30480 d6 = +HEAPF32[i2 + 92 >> 2];
michael@0 30481 d7 = +HEAPF32[i2 + 96 >> 2];
michael@0 30482 if (d6 < 0.0) {
michael@0 30483 d8 = 0.0;
michael@0 30484 } else {
michael@0 30485 d8 = d6 > 1.0 ? 1.0 : d6;
michael@0 30486 }
michael@0 30487 HEAPF32[i1 + 436 >> 2] = d8;
michael@0 30488 if (d7 < 0.0) {
michael@0 30489 d9 = 0.0;
michael@0 30490 } else {
michael@0 30491 d9 = d7 > 1.0 ? 1.0 : d7;
michael@0 30492 }
michael@0 30493 HEAPF32[i1 + 440 >> 2] = d9;
michael@0 30494 HEAPF32[i1 + 464 >> 2] = +HEAPF32[i2 + 108 >> 2];
michael@0 30495 HEAPF32[i1 + 468 >> 2] = +HEAPF32[i2 + 112 >> 2];
michael@0 30496 i10 = HEAP32[i2 + 4 >> 2] | 0;
michael@0 30497 HEAP32[i1 + 472 >> 2] = i10;
michael@0 30498 HEAP32[i1 + 600 >> 2] = 0;
michael@0 30499 HEAP32[i1 + 604 >> 2] = 0;
michael@0 30500 HEAP8[i1 + 444 | 0] = HEAP8[i2 + 116 | 0] | 0;
michael@0 30501 HEAPF32[i1 + 448 >> 2] = +HEAPF32[i2 + 120 >> 2];
michael@0 30502 HEAPF32[i1 + 452 >> 2] = +HEAPF32[i2 + 124 >> 2];
michael@0 30503 HEAPF32[i1 + 456 >> 2] = +HEAPF32[i2 + 128 >> 2];
michael@0 30504 HEAPF32[i1 + 460 >> 2] = +HEAPF32[i2 + 132 >> 2];
michael@0 30505 if ((i10 | 0) == 0) {
michael@0 30506 i11 = i1 + 4 | 0;
michael@0 30507 i12 = i2 + 8 | 0;
michael@0 30508 HEAP32[i11 >> 2] = HEAP32[i12 >> 2];
michael@0 30509 HEAP32[i11 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 30510 HEAP32[i11 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 30511 HEAP32[i11 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 30512 i12 = i1 + 20 | 0;
michael@0 30513 i13 = i2 + 24 | 0;
michael@0 30514 HEAP32[i12 >> 2] = HEAP32[i13 >> 2];
michael@0 30515 HEAP32[i12 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 30516 HEAP32[i12 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 30517 HEAP32[i12 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 30518 i13 = i1 + 36 | 0;
michael@0 30519 i14 = i2 + 40 | 0;
michael@0 30520 HEAP32[i13 >> 2] = HEAP32[i14 >> 2];
michael@0 30521 HEAP32[i13 + 4 >> 2] = HEAP32[i14 + 4 >> 2];
michael@0 30522 HEAP32[i13 + 8 >> 2] = HEAP32[i14 + 8 >> 2];
michael@0 30523 HEAP32[i13 + 12 >> 2] = HEAP32[i14 + 12 >> 2];
michael@0 30524 i14 = i1 + 52 | 0;
michael@0 30525 i15 = i2 + 56 | 0;
michael@0 30526 HEAP32[i14 >> 2] = HEAP32[i15 >> 2];
michael@0 30527 HEAP32[i14 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 30528 HEAP32[i14 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 30529 HEAP32[i14 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 30530 i16 = i11;
michael@0 30531 i17 = i12;
michael@0 30532 i18 = i13;
michael@0 30533 i19 = i14;
michael@0 30534 } else {
michael@0 30535 i14 = i1 + 4 | 0;
michael@0 30536 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i10 >> 2] | 0) + 8 >> 2] & 127](i10, i14);
michael@0 30537 i16 = i14;
michael@0 30538 i17 = i1 + 20 | 0;
michael@0 30539 i18 = i1 + 36 | 0;
michael@0 30540 i19 = i1 + 52 | 0;
michael@0 30541 }
michael@0 30542 i14 = i1 + 68 | 0;
michael@0 30543 HEAP32[i14 >> 2] = HEAP32[i16 >> 2];
michael@0 30544 HEAP32[i14 + 4 >> 2] = HEAP32[i16 + 4 >> 2];
michael@0 30545 HEAP32[i14 + 8 >> 2] = HEAP32[i16 + 8 >> 2];
michael@0 30546 HEAP32[i14 + 12 >> 2] = HEAP32[i16 + 12 >> 2];
michael@0 30547 i16 = i1 + 84 | 0;
michael@0 30548 HEAP32[i16 >> 2] = HEAP32[i17 >> 2];
michael@0 30549 HEAP32[i16 + 4 >> 2] = HEAP32[i17 + 4 >> 2];
michael@0 30550 HEAP32[i16 + 8 >> 2] = HEAP32[i17 + 8 >> 2];
michael@0 30551 HEAP32[i16 + 12 >> 2] = HEAP32[i17 + 12 >> 2];
michael@0 30552 i17 = i1 + 100 | 0;
michael@0 30553 HEAP32[i17 >> 2] = HEAP32[i18 >> 2];
michael@0 30554 HEAP32[i17 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 30555 HEAP32[i17 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 30556 HEAP32[i17 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 30557 i18 = i1 + 116 | 0;
michael@0 30558 HEAP32[i18 >> 2] = HEAP32[i19 >> 2];
michael@0 30559 HEAP32[i18 + 4 >> 2] = HEAP32[i19 + 4 >> 2];
michael@0 30560 HEAP32[i18 + 8 >> 2] = HEAP32[i19 + 8 >> 2];
michael@0 30561 HEAP32[i18 + 12 >> 2] = HEAP32[i19 + 12 >> 2];
michael@0 30562 _memset(i1 + 132 | 0, 0, 32);
michael@0 30563 HEAPF32[i1 + 224 >> 2] = +HEAPF32[i2 + 100 >> 2];
michael@0 30564 HEAPF32[i1 + 228 >> 2] = +HEAPF32[i2 + 104 >> 2];
michael@0 30565 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 12 >> 2] & 127](i1 | 0, HEAP32[i2 + 72 >> 2] | 0);
michael@0 30566 i19 = HEAP32[3574] | 0;
michael@0 30567 HEAP32[3574] = i19 + 1;
michael@0 30568 HEAP32[i1 + 500 >> 2] = i19;
michael@0 30569 d9 = +HEAPF32[i2 >> 2];
michael@0 30570 i19 = i1 + 204 | 0;
michael@0 30571 i18 = HEAP32[i19 >> 2] | 0;
michael@0 30572 if (d9 == 0.0) {
michael@0 30573 HEAP32[i19 >> 2] = i18 | 1;
michael@0 30574 HEAPF32[i1 + 336 >> 2] = 0.0;
michael@0 30575 d20 = 0.0;
michael@0 30576 } else {
michael@0 30577 HEAP32[i19 >> 2] = i18 & -2;
michael@0 30578 d7 = 1.0 / d9;
michael@0 30579 HEAPF32[i1 + 336 >> 2] = d7;
michael@0 30580 d20 = d7;
michael@0 30581 }
michael@0 30582 d7 = d9 * +HEAPF32[i1 + 376 >> 2];
michael@0 30583 d8 = d9 * +HEAPF32[i1 + 380 >> 2];
michael@0 30584 HEAPF32[i1 + 356 >> 2] = d9 * +HEAPF32[i1 + 372 >> 2];
michael@0 30585 HEAPF32[i1 + 360 >> 2] = d7;
michael@0 30586 HEAPF32[i1 + 364 >> 2] = d8;
michael@0 30587 HEAPF32[i1 + 368 >> 2] = 0.0;
michael@0 30588 d8 = +HEAPF32[i2 + 76 >> 2];
michael@0 30589 if (d8 != 0.0) {
michael@0 30590 d21 = 1.0 / d8;
michael@0 30591 } else {
michael@0 30592 d21 = 0.0;
michael@0 30593 }
michael@0 30594 d8 = +HEAPF32[i2 + 80 >> 2];
michael@0 30595 if (d8 != 0.0) {
michael@0 30596 d22 = 1.0 / d8;
michael@0 30597 } else {
michael@0 30598 d22 = 0.0;
michael@0 30599 }
michael@0 30600 d8 = +HEAPF32[i2 + 84 >> 2];
michael@0 30601 if (d8 != 0.0) {
michael@0 30602 d23 = 1.0 / d8;
michael@0 30603 } else {
michael@0 30604 d23 = 0.0;
michael@0 30605 }
michael@0 30606 HEAPF32[i1 + 388 >> 2] = d21;
michael@0 30607 HEAPF32[i1 + 392 >> 2] = d22;
michael@0 30608 HEAPF32[i1 + 396 >> 2] = d23;
michael@0 30609 HEAPF32[i1 + 400 >> 2] = 0.0;
michael@0 30610 d8 = d20 * +HEAPF32[i3 >> 2];
michael@0 30611 d7 = d20 * +HEAPF32[i4 >> 2];
michael@0 30612 d9 = d20 * +HEAPF32[i5 >> 2];
michael@0 30613 d20 = +HEAPF32[i1 + 4 >> 2];
michael@0 30614 d6 = d20 * d21;
michael@0 30615 d24 = +HEAPF32[i1 + 8 >> 2];
michael@0 30616 d25 = d24 * d22;
michael@0 30617 d26 = +HEAPF32[i1 + 12 >> 2];
michael@0 30618 d27 = d26 * d23;
michael@0 30619 d28 = +HEAPF32[i1 + 20 >> 2];
michael@0 30620 d29 = d21 * d28;
michael@0 30621 d30 = +HEAPF32[i1 + 24 >> 2];
michael@0 30622 d31 = d22 * d30;
michael@0 30623 d32 = +HEAPF32[i1 + 28 >> 2];
michael@0 30624 d33 = d23 * d32;
michael@0 30625 d34 = +HEAPF32[i1 + 36 >> 2];
michael@0 30626 d35 = d21 * d34;
michael@0 30627 d21 = +HEAPF32[i1 + 40 >> 2];
michael@0 30628 d36 = d22 * d21;
michael@0 30629 d22 = +HEAPF32[i1 + 44 >> 2];
michael@0 30630 d37 = d23 * d22;
michael@0 30631 HEAPF32[i1 + 256 >> 2] = d20 * d6 + d24 * d25 + d26 * d27;
michael@0 30632 HEAPF32[i1 + 260 >> 2] = d6 * d28 + d25 * d30 + d27 * d32;
michael@0 30633 HEAPF32[i1 + 264 >> 2] = d6 * d34 + d25 * d21 + d27 * d22;
michael@0 30634 HEAPF32[i1 + 268 >> 2] = 0.0;
michael@0 30635 HEAPF32[i1 + 272 >> 2] = d20 * d29 + d24 * d31 + d26 * d33;
michael@0 30636 HEAPF32[i1 + 276 >> 2] = d28 * d29 + d30 * d31 + d32 * d33;
michael@0 30637 HEAPF32[i1 + 280 >> 2] = d29 * d34 + d31 * d21 + d33 * d22;
michael@0 30638 HEAPF32[i1 + 284 >> 2] = 0.0;
michael@0 30639 HEAPF32[i1 + 288 >> 2] = d20 * d35 + d24 * d36 + d26 * d37;
michael@0 30640 HEAPF32[i1 + 292 >> 2] = d28 * d35 + d30 * d36 + d32 * d37;
michael@0 30641 HEAPF32[i1 + 296 >> 2] = d34 * d35 + d21 * d36 + d22 * d37;
michael@0 30642 HEAPF32[i1 + 300 >> 2] = 0.0;
michael@0 30643 HEAP32[i1 + 496 >> 2] = 0;
michael@0 30644 _memset(i1 + 504 | 0, 0, 32);
michael@0 30645 HEAPF32[i1 + 552 >> 2] = d8;
michael@0 30646 HEAPF32[i1 + 556 >> 2] = d7;
michael@0 30647 HEAPF32[i1 + 560 >> 2] = d9;
michael@0 30648 _memset(i1 + 564 | 0, 0, 36);
michael@0 30649 return;
michael@0 30650 }
michael@0 30651 function __ZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 30652 i1 = i1 | 0;
michael@0 30653 i2 = i2 | 0;
michael@0 30654 i3 = i3 | 0;
michael@0 30655 i4 = i4 | 0;
michael@0 30656 i5 = i5 | 0;
michael@0 30657 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, d50 = 0.0, i51 = 0, i52 = 0, i53 = 0, d54 = 0.0, d55 = 0.0, d56 = 0.0, i57 = 0;
michael@0 30658 i5 = STACKTOP;
michael@0 30659 STACKTOP = STACKTOP + 240 | 0;
michael@0 30660 i4 = i5 | 0;
michael@0 30661 i6 = i5 + 16 | 0;
michael@0 30662 i7 = i5 + 32 | 0;
michael@0 30663 i8 = (HEAP8[i1 + 8 | 0] | 0) != 0;
michael@0 30664 i1 = i8 ? i3 : i2;
michael@0 30665 i9 = i8 ? i2 : i3;
michael@0 30666 d10 = +HEAPF32[i1 + 116 >> 2];
michael@0 30667 d11 = +HEAPF32[i1 + 52 >> 2];
michael@0 30668 d12 = d10 - d11;
michael@0 30669 d13 = +HEAPF32[i1 + 120 >> 2];
michael@0 30670 d14 = +HEAPF32[i1 + 56 >> 2];
michael@0 30671 d15 = d13 - d14;
michael@0 30672 d16 = +HEAPF32[i1 + 124 >> 2];
michael@0 30673 d17 = +HEAPF32[i1 + 60 >> 2];
michael@0 30674 d18 = d16 - d17;
michael@0 30675 d19 = +HEAPF32[i1 + 248 >> 2];
michael@0 30676 if (d12 * d12 + d15 * d15 + d18 * d18 < d19 * d19) {
michael@0 30677 d20 = 1.0;
michael@0 30678 STACKTOP = i5;
michael@0 30679 return +d20;
michael@0 30680 }
michael@0 30681 d19 = +HEAPF32[i9 + 4 >> 2];
michael@0 30682 d18 = +HEAPF32[i9 + 20 >> 2];
michael@0 30683 d15 = +HEAPF32[i9 + 36 >> 2];
michael@0 30684 d12 = +HEAPF32[i9 + 8 >> 2];
michael@0 30685 d21 = +HEAPF32[i9 + 24 >> 2];
michael@0 30686 d22 = +HEAPF32[i9 + 40 >> 2];
michael@0 30687 d23 = +HEAPF32[i9 + 12 >> 2];
michael@0 30688 d24 = +HEAPF32[i9 + 28 >> 2];
michael@0 30689 d25 = +HEAPF32[i9 + 44 >> 2];
michael@0 30690 d26 = -0.0 - +HEAPF32[i9 + 52 >> 2];
michael@0 30691 d27 = -0.0 - +HEAPF32[i9 + 56 >> 2];
michael@0 30692 d28 = -0.0 - +HEAPF32[i9 + 60 >> 2];
michael@0 30693 d29 = d19 * d26 + d18 * d27 + d15 * d28;
michael@0 30694 d30 = d12 * d26 + d21 * d27 + d22 * d28;
michael@0 30695 d31 = d23 * d26 + d24 * d27 + d25 * d28;
michael@0 30696 d28 = +HEAPF32[i1 + 4 >> 2];
michael@0 30697 d27 = +HEAPF32[i1 + 20 >> 2];
michael@0 30698 d26 = +HEAPF32[i1 + 36 >> 2];
michael@0 30699 d32 = +HEAPF32[i1 + 8 >> 2];
michael@0 30700 d33 = +HEAPF32[i1 + 24 >> 2];
michael@0 30701 d34 = +HEAPF32[i1 + 40 >> 2];
michael@0 30702 d35 = +HEAPF32[i1 + 12 >> 2];
michael@0 30703 d36 = +HEAPF32[i1 + 28 >> 2];
michael@0 30704 d37 = +HEAPF32[i1 + 44 >> 2];
michael@0 30705 d38 = d11 * d19 + d14 * d18 + d17 * d15 + d29;
michael@0 30706 d39 = d11 * d12 + d14 * d21 + d17 * d22 + d30;
michael@0 30707 d40 = d11 * d23 + d14 * d24 + d17 * d25 + d31;
michael@0 30708 d17 = +HEAPF32[i1 + 68 >> 2];
michael@0 30709 d14 = +HEAPF32[i1 + 84 >> 2];
michael@0 30710 d11 = +HEAPF32[i1 + 100 >> 2];
michael@0 30711 d41 = +HEAPF32[i1 + 72 >> 2];
michael@0 30712 d42 = +HEAPF32[i1 + 88 >> 2];
michael@0 30713 d43 = +HEAPF32[i1 + 104 >> 2];
michael@0 30714 d44 = +HEAPF32[i1 + 76 >> 2];
michael@0 30715 d45 = +HEAPF32[i1 + 92 >> 2];
michael@0 30716 d46 = +HEAPF32[i1 + 108 >> 2];
michael@0 30717 d47 = d10 * d19 + d13 * d18 + d16 * d15 + d29;
michael@0 30718 d29 = d10 * d12 + d13 * d21 + d16 * d22 + d30;
michael@0 30719 d30 = d10 * d23 + d13 * d24 + d16 * d25 + d31;
michael@0 30720 i3 = HEAP32[i9 + 192 >> 2] | 0;
michael@0 30721 if (((HEAP32[i3 + 4 >> 2] | 0) - 21 | 0) >>> 0 >= 9) {
michael@0 30722 d20 = 1.0;
michael@0 30723 STACKTOP = i5;
michael@0 30724 return +d20;
michael@0 30725 }
michael@0 30726 i9 = i4 | 0;
michael@0 30727 HEAPF32[i9 >> 2] = d38;
michael@0 30728 i2 = i4 + 4 | 0;
michael@0 30729 HEAPF32[i2 >> 2] = d39;
michael@0 30730 i8 = i4 + 8 | 0;
michael@0 30731 HEAPF32[i8 >> 2] = d40;
michael@0 30732 HEAPF32[i4 + 12 >> 2] = 0.0;
michael@0 30733 if (d47 < d38) {
michael@0 30734 HEAPF32[i9 >> 2] = d47;
michael@0 30735 d48 = d47;
michael@0 30736 } else {
michael@0 30737 d48 = d38;
michael@0 30738 }
michael@0 30739 if (d29 < d39) {
michael@0 30740 HEAPF32[i2 >> 2] = d29;
michael@0 30741 d49 = d29;
michael@0 30742 } else {
michael@0 30743 d49 = d39;
michael@0 30744 }
michael@0 30745 if (d30 < d40) {
michael@0 30746 HEAPF32[i8 >> 2] = d30;
michael@0 30747 d50 = d30;
michael@0 30748 } else {
michael@0 30749 d50 = d40;
michael@0 30750 }
michael@0 30751 i51 = i6 | 0;
michael@0 30752 HEAPF32[i51 >> 2] = d38;
michael@0 30753 i52 = i6 + 4 | 0;
michael@0 30754 HEAPF32[i52 >> 2] = d39;
michael@0 30755 i53 = i6 + 8 | 0;
michael@0 30756 HEAPF32[i53 >> 2] = d40;
michael@0 30757 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 30758 if (d38 < d47) {
michael@0 30759 HEAPF32[i51 >> 2] = d47;
michael@0 30760 d54 = d47;
michael@0 30761 } else {
michael@0 30762 d54 = d38;
michael@0 30763 }
michael@0 30764 if (d39 < d29) {
michael@0 30765 HEAPF32[i52 >> 2] = d29;
michael@0 30766 d55 = d29;
michael@0 30767 } else {
michael@0 30768 d55 = d39;
michael@0 30769 }
michael@0 30770 if (d40 < d30) {
michael@0 30771 HEAPF32[i53 >> 2] = d30;
michael@0 30772 d56 = d30;
michael@0 30773 } else {
michael@0 30774 d56 = d40;
michael@0 30775 }
michael@0 30776 d31 = +HEAPF32[i1 + 244 >> 2];
michael@0 30777 HEAPF32[i9 >> 2] = d48 - d31;
michael@0 30778 HEAPF32[i2 >> 2] = d49 - d31;
michael@0 30779 HEAPF32[i8 >> 2] = d50 - d31;
michael@0 30780 HEAPF32[i51 >> 2] = d54 + d31;
michael@0 30781 HEAPF32[i52 >> 2] = d55 + d31;
michael@0 30782 HEAPF32[i53 >> 2] = d56 + d31;
michael@0 30783 HEAP32[i7 >> 2] = 1424;
michael@0 30784 HEAPF32[i7 + 4 >> 2] = d19 * d28 + d18 * d27 + d15 * d26;
michael@0 30785 HEAPF32[i7 + 8 >> 2] = d19 * d32 + d18 * d33 + d15 * d34;
michael@0 30786 HEAPF32[i7 + 12 >> 2] = d19 * d35 + d18 * d36 + d15 * d37;
michael@0 30787 HEAPF32[i7 + 16 >> 2] = 0.0;
michael@0 30788 HEAPF32[i7 + 20 >> 2] = d12 * d28 + d21 * d27 + d22 * d26;
michael@0 30789 HEAPF32[i7 + 24 >> 2] = d12 * d32 + d21 * d33 + d22 * d34;
michael@0 30790 HEAPF32[i7 + 28 >> 2] = d12 * d35 + d21 * d36 + d22 * d37;
michael@0 30791 HEAPF32[i7 + 32 >> 2] = 0.0;
michael@0 30792 HEAPF32[i7 + 36 >> 2] = d23 * d28 + d24 * d27 + d25 * d26;
michael@0 30793 HEAPF32[i7 + 40 >> 2] = d23 * d32 + d24 * d33 + d25 * d34;
michael@0 30794 HEAPF32[i7 + 44 >> 2] = d23 * d35 + d24 * d36 + d25 * d37;
michael@0 30795 HEAPF32[i7 + 48 >> 2] = 0.0;
michael@0 30796 HEAPF32[i7 + 52 >> 2] = d38;
michael@0 30797 HEAPF32[i7 + 56 >> 2] = d39;
michael@0 30798 HEAPF32[i7 + 60 >> 2] = d40;
michael@0 30799 HEAPF32[i7 + 64 >> 2] = 0.0;
michael@0 30800 HEAPF32[i7 + 68 >> 2] = d19 * d17 + d18 * d14 + d15 * d11;
michael@0 30801 HEAPF32[i7 + 72 >> 2] = d19 * d41 + d18 * d42 + d15 * d43;
michael@0 30802 HEAPF32[i7 + 76 >> 2] = d19 * d44 + d18 * d45 + d15 * d46;
michael@0 30803 HEAPF32[i7 + 80 >> 2] = 0.0;
michael@0 30804 HEAPF32[i7 + 84 >> 2] = d12 * d17 + d21 * d14 + d22 * d11;
michael@0 30805 HEAPF32[i7 + 88 >> 2] = d12 * d41 + d21 * d42 + d22 * d43;
michael@0 30806 HEAPF32[i7 + 92 >> 2] = d12 * d44 + d21 * d45 + d22 * d46;
michael@0 30807 HEAPF32[i7 + 96 >> 2] = 0.0;
michael@0 30808 HEAPF32[i7 + 100 >> 2] = d23 * d17 + d24 * d14 + d25 * d11;
michael@0 30809 HEAPF32[i7 + 104 >> 2] = d23 * d41 + d24 * d42 + d25 * d43;
michael@0 30810 HEAPF32[i7 + 108 >> 2] = d23 * d44 + d24 * d45 + d25 * d46;
michael@0 30811 HEAPF32[i7 + 112 >> 2] = 0.0;
michael@0 30812 HEAPF32[i7 + 116 >> 2] = d47;
michael@0 30813 HEAPF32[i7 + 120 >> 2] = d29;
michael@0 30814 HEAPF32[i7 + 124 >> 2] = d30;
michael@0 30815 HEAPF32[i7 + 128 >> 2] = 0.0;
michael@0 30816 HEAPF32[i7 + 196 >> 2] = d31;
michael@0 30817 i53 = i7 + 200 | 0;
michael@0 30818 i52 = i1 + 240 | 0;
michael@0 30819 HEAPF32[i53 >> 2] = +HEAPF32[i52 >> 2];
michael@0 30820 do {
michael@0 30821 if ((i3 | 0) == 0) {
michael@0 30822 i57 = i7 | 0;
michael@0 30823 } else {
michael@0 30824 i1 = i7 | 0;
michael@0 30825 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i3 >> 2] | 0) + 60 >> 2] & 127](i3, i1, i4, i6);
michael@0 30826 d31 = +HEAPF32[i53 >> 2];
michael@0 30827 if (d31 >= +HEAPF32[i52 >> 2]) {
michael@0 30828 i57 = i1;
michael@0 30829 break;
michael@0 30830 }
michael@0 30831 HEAPF32[i52 >> 2] = d31;
michael@0 30832 __ZN18btTriangleCallbackD2Ev(i1);
michael@0 30833 d20 = d31;
michael@0 30834 STACKTOP = i5;
michael@0 30835 return +d20;
michael@0 30836 }
michael@0 30837 } while (0);
michael@0 30838 __ZN18btTriangleCallbackD2Ev(i57);
michael@0 30839 d20 = 1.0;
michael@0 30840 STACKTOP = i5;
michael@0 30841 return +d20;
michael@0 30842 }
michael@0 30843 function __ZN25btSimulationIslandManager12buildIslandsEP12btDispatcherP16btCollisionWorld(i1, i2, i3) {
michael@0 30844 i1 = i1 | 0;
michael@0 30845 i2 = i2 | 0;
michael@0 30846 i3 = i3 | 0;
michael@0 30847 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0;
michael@0 30848 __ZN15CProfileManager13Start_ProfileEPKc(504);
michael@0 30849 i4 = i1 + 28 | 0;
michael@0 30850 i5 = HEAP32[i4 >> 2] | 0;
michael@0 30851 if ((i5 | 0) < 0) {
michael@0 30852 i6 = i1 + 32 | 0;
michael@0 30853 i7 = i1 + 36 | 0;
michael@0 30854 if ((HEAP32[i6 >> 2] | 0) < 0) {
michael@0 30855 i8 = HEAP32[i7 >> 2] | 0;
michael@0 30856 i9 = i1 + 40 | 0;
michael@0 30857 if ((i8 | 0) != 0) {
michael@0 30858 if ((HEAP8[i9] | 0) != 0) {
michael@0 30859 __Z21btAlignedFreeInternalPv(i8);
michael@0 30860 }
michael@0 30861 HEAP32[i7 >> 2] = 0;
michael@0 30862 }
michael@0 30863 HEAP8[i9] = 1;
michael@0 30864 HEAP32[i7 >> 2] = 0;
michael@0 30865 HEAP32[i6 >> 2] = 0;
michael@0 30866 i10 = i5;
michael@0 30867 } else {
michael@0 30868 i10 = i5;
michael@0 30869 }
michael@0 30870 do {
michael@0 30871 i5 = (HEAP32[i7 >> 2] | 0) + (i10 << 2) | 0;
michael@0 30872 if ((i5 | 0) != 0) {
michael@0 30873 HEAP32[i5 >> 2] = 0;
michael@0 30874 }
michael@0 30875 i10 = i10 + 1 | 0;
michael@0 30876 } while ((i10 | 0) < 0);
michael@0 30877 }
michael@0 30878 HEAP32[i4 >> 2] = 0;
michael@0 30879 __ZN11btUnionFind11sortIslandsEv(i1 + 4 | 0);
michael@0 30880 i10 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 30881 if ((i10 | 0) > 0) {
michael@0 30882 i7 = i1 + 16 | 0;
michael@0 30883 i5 = i3 + 16 | 0;
michael@0 30884 i3 = 0;
michael@0 30885 while (1) {
michael@0 30886 i6 = HEAP32[i7 >> 2] | 0;
michael@0 30887 i9 = HEAP32[i6 + (i3 << 3) >> 2] | 0;
michael@0 30888 i8 = i3;
michael@0 30889 while (1) {
michael@0 30890 i11 = i8 + 1 | 0;
michael@0 30891 if ((i11 | 0) >= (i10 | 0)) {
michael@0 30892 i12 = 0;
michael@0 30893 break;
michael@0 30894 }
michael@0 30895 if ((HEAP32[i6 + (i11 << 3) >> 2] | 0) == (i9 | 0)) {
michael@0 30896 i8 = i11;
michael@0 30897 } else {
michael@0 30898 i12 = 1;
michael@0 30899 break;
michael@0 30900 }
michael@0 30901 }
michael@0 30902 L212 : do {
michael@0 30903 if ((i3 | 0) < (i11 | 0)) {
michael@0 30904 i8 = HEAP32[i5 >> 2] | 0;
michael@0 30905 i13 = i3;
michael@0 30906 i14 = 1;
michael@0 30907 while (1) {
michael@0 30908 i15 = HEAP32[i8 + (HEAP32[i6 + (i13 << 3) + 4 >> 2] << 2) >> 2] | 0;
michael@0 30909 if ((HEAP32[i15 + 208 >> 2] | 0) == (i9 | 0)) {
michael@0 30910 i16 = HEAP32[i15 + 216 >> 2] | 0;
michael@0 30911 i17 = i14 & (i16 | 0) != 1 & (i16 | 0) != 4;
michael@0 30912 } else {
michael@0 30913 i17 = i14;
michael@0 30914 }
michael@0 30915 i16 = i13 + 1 | 0;
michael@0 30916 if ((i16 | 0) < (i11 | 0)) {
michael@0 30917 i13 = i16;
michael@0 30918 i14 = i17;
michael@0 30919 } else {
michael@0 30920 break;
michael@0 30921 }
michael@0 30922 }
michael@0 30923 if (i17) {
michael@0 30924 i14 = i3;
michael@0 30925 i13 = i6;
michael@0 30926 i16 = i8;
michael@0 30927 while (1) {
michael@0 30928 i15 = HEAP32[i16 + (HEAP32[i13 + (i14 << 3) + 4 >> 2] << 2) >> 2] | 0;
michael@0 30929 if ((HEAP32[i15 + 208 >> 2] | 0) == (i9 | 0)) {
michael@0 30930 __ZN17btCollisionObject18setActivationStateEi(i15, 2);
michael@0 30931 }
michael@0 30932 i15 = i14 + 1 | 0;
michael@0 30933 if ((i15 | 0) >= (i11 | 0)) {
michael@0 30934 break L212;
michael@0 30935 }
michael@0 30936 i14 = i15;
michael@0 30937 i13 = HEAP32[i7 >> 2] | 0;
michael@0 30938 i16 = HEAP32[i5 >> 2] | 0;
michael@0 30939 }
michael@0 30940 } else {
michael@0 30941 i18 = i3;
michael@0 30942 i19 = i6;
michael@0 30943 i20 = i8;
michael@0 30944 }
michael@0 30945 while (1) {
michael@0 30946 i16 = HEAP32[i20 + (HEAP32[i19 + (i18 << 3) + 4 >> 2] << 2) >> 2] | 0;
michael@0 30947 do {
michael@0 30948 if ((HEAP32[i16 + 208 >> 2] | 0) == (i9 | 0)) {
michael@0 30949 if ((HEAP32[i16 + 216 >> 2] | 0) != 2) {
michael@0 30950 break;
michael@0 30951 }
michael@0 30952 __ZN17btCollisionObject18setActivationStateEi(i16, 3);
michael@0 30953 HEAPF32[i16 + 220 >> 2] = 0.0;
michael@0 30954 }
michael@0 30955 } while (0);
michael@0 30956 i16 = i18 + 1 | 0;
michael@0 30957 if ((i16 | 0) >= (i11 | 0)) {
michael@0 30958 break L212;
michael@0 30959 }
michael@0 30960 i18 = i16;
michael@0 30961 i19 = HEAP32[i7 >> 2] | 0;
michael@0 30962 i20 = HEAP32[i5 >> 2] | 0;
michael@0 30963 }
michael@0 30964 }
michael@0 30965 } while (0);
michael@0 30966 if (i12) {
michael@0 30967 i3 = i11;
michael@0 30968 } else {
michael@0 30969 break;
michael@0 30970 }
michael@0 30971 }
michael@0 30972 }
michael@0 30973 i11 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i2 >> 2] | 0) + 36 >> 2] & 127](i2) | 0;
michael@0 30974 if ((i11 | 0) <= 0) {
michael@0 30975 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 30976 return;
michael@0 30977 }
michael@0 30978 i3 = i2;
michael@0 30979 i12 = i1 + 64 | 0;
michael@0 30980 i5 = i2;
michael@0 30981 i20 = i1 + 32 | 0;
michael@0 30982 i7 = i1 + 36 | 0;
michael@0 30983 i19 = i1 + 40 | 0;
michael@0 30984 i1 = 0;
michael@0 30985 do {
michael@0 30986 i18 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i3 >> 2] | 0) + 40 >> 2] & 63](i2, i1) | 0;
michael@0 30987 i17 = HEAP32[i18 + 1108 >> 2] | 0;
michael@0 30988 i10 = i17;
michael@0 30989 i9 = HEAP32[i18 + 1112 >> 2] | 0;
michael@0 30990 i6 = i9;
michael@0 30991 if ((i17 | 0) == 0) {
michael@0 30992 i21 = 230;
michael@0 30993 } else {
michael@0 30994 if ((HEAP32[i17 + 216 >> 2] | 0) == 2) {
michael@0 30995 i21 = 230;
michael@0 30996 } else {
michael@0 30997 i21 = 232;
michael@0 30998 }
michael@0 30999 }
michael@0 31000 do {
michael@0 31001 if ((i21 | 0) == 230) {
michael@0 31002 i21 = 0;
michael@0 31003 if ((i9 | 0) == 0) {
michael@0 31004 break;
michael@0 31005 }
michael@0 31006 if ((HEAP32[i9 + 216 >> 2] | 0) != 2) {
michael@0 31007 i21 = 232;
michael@0 31008 }
michael@0 31009 }
michael@0 31010 } while (0);
michael@0 31011 do {
michael@0 31012 if ((i21 | 0) == 232) {
michael@0 31013 i21 = 0;
michael@0 31014 do {
michael@0 31015 if ((HEAP32[i17 + 204 >> 2] & 2 | 0) != 0) {
michael@0 31016 if ((HEAP32[i17 + 216 >> 2] | 0) == 2) {
michael@0 31017 break;
michael@0 31018 }
michael@0 31019 __ZN17btCollisionObject8activateEb(i6, 0);
michael@0 31020 }
michael@0 31021 } while (0);
michael@0 31022 do {
michael@0 31023 if ((HEAP32[i9 + 204 >> 2] & 2 | 0) != 0) {
michael@0 31024 if ((HEAP32[i9 + 216 >> 2] | 0) == 2) {
michael@0 31025 break;
michael@0 31026 }
michael@0 31027 __ZN17btCollisionObject8activateEb(i10, 0);
michael@0 31028 }
michael@0 31029 } while (0);
michael@0 31030 if ((HEAP8[i12] | 0) == 0) {
michael@0 31031 break;
michael@0 31032 }
michael@0 31033 if (!(FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i5 >> 2] | 0) + 28 >> 2] & 31](i2, i10, i6) | 0)) {
michael@0 31034 break;
michael@0 31035 }
michael@0 31036 i8 = HEAP32[i4 >> 2] | 0;
michael@0 31037 do {
michael@0 31038 if ((i8 | 0) == (HEAP32[i20 >> 2] | 0)) {
michael@0 31039 i16 = (i8 | 0) == 0 ? 1 : i8 << 1;
michael@0 31040 if ((i8 | 0) >= (i16 | 0)) {
michael@0 31041 i22 = i8;
michael@0 31042 break;
michael@0 31043 }
michael@0 31044 if ((i16 | 0) == 0) {
michael@0 31045 i23 = 0;
michael@0 31046 i24 = i8;
michael@0 31047 } else {
michael@0 31048 i13 = __Z22btAlignedAllocInternalji(i16 << 2, 16) | 0;
michael@0 31049 i23 = i13;
michael@0 31050 i24 = HEAP32[i4 >> 2] | 0;
michael@0 31051 }
michael@0 31052 if ((i24 | 0) > 0) {
michael@0 31053 i13 = 0;
michael@0 31054 do {
michael@0 31055 i14 = i23 + (i13 << 2) | 0;
michael@0 31056 if ((i14 | 0) != 0) {
michael@0 31057 HEAP32[i14 >> 2] = HEAP32[(HEAP32[i7 >> 2] | 0) + (i13 << 2) >> 2];
michael@0 31058 }
michael@0 31059 i13 = i13 + 1 | 0;
michael@0 31060 } while ((i13 | 0) < (i24 | 0));
michael@0 31061 }
michael@0 31062 i13 = HEAP32[i7 >> 2] | 0;
michael@0 31063 if ((i13 | 0) == 0) {
michael@0 31064 i25 = i24;
michael@0 31065 } else {
michael@0 31066 if ((HEAP8[i19] | 0) == 0) {
michael@0 31067 i26 = i24;
michael@0 31068 } else {
michael@0 31069 __Z21btAlignedFreeInternalPv(i13);
michael@0 31070 i26 = HEAP32[i4 >> 2] | 0;
michael@0 31071 }
michael@0 31072 HEAP32[i7 >> 2] = 0;
michael@0 31073 i25 = i26;
michael@0 31074 }
michael@0 31075 HEAP8[i19] = 1;
michael@0 31076 HEAP32[i7 >> 2] = i23;
michael@0 31077 HEAP32[i20 >> 2] = i16;
michael@0 31078 i22 = i25;
michael@0 31079 } else {
michael@0 31080 i22 = i8;
michael@0 31081 }
michael@0 31082 } while (0);
michael@0 31083 i8 = (HEAP32[i7 >> 2] | 0) + (i22 << 2) | 0;
michael@0 31084 if ((i8 | 0) != 0) {
michael@0 31085 HEAP32[i8 >> 2] = i18;
michael@0 31086 }
michael@0 31087 HEAP32[i4 >> 2] = i22 + 1;
michael@0 31088 }
michael@0 31089 } while (0);
michael@0 31090 i1 = i1 + 1 | 0;
michael@0 31091 } while ((i1 | 0) < (i11 | 0));
michael@0 31092 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 31093 return;
michael@0 31094 }
michael@0 31095 function __ZN16btManifoldResult15addContactPointERK9btVector3S2_f(i1, i2, i3, d4) {
michael@0 31096 i1 = i1 | 0;
michael@0 31097 i2 = i2 | 0;
michael@0 31098 i3 = i3 | 0;
michael@0 31099 d4 = +d4;
michael@0 31100 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0;
michael@0 31101 i5 = STACKTOP;
michael@0 31102 STACKTOP = STACKTOP + 280 | 0;
michael@0 31103 i6 = i5 | 0;
michael@0 31104 i7 = i1 + 4 | 0;
michael@0 31105 i8 = HEAP32[i7 >> 2] | 0;
michael@0 31106 if (+HEAPF32[i8 + 1124 >> 2] < d4) {
michael@0 31107 STACKTOP = i5;
michael@0 31108 return;
michael@0 31109 }
michael@0 31110 i9 = i1 + 136 | 0;
michael@0 31111 i10 = (HEAP32[i8 + 1108 >> 2] | 0) != (HEAP32[i9 >> 2] | 0);
michael@0 31112 d11 = +HEAPF32[i3 >> 2];
michael@0 31113 d12 = +HEAPF32[i2 >> 2] * d4 + d11;
michael@0 31114 d13 = +HEAPF32[i3 + 4 >> 2];
michael@0 31115 d14 = +HEAPF32[i2 + 4 >> 2] * d4 + d13;
michael@0 31116 d15 = +HEAPF32[i3 + 8 >> 2];
michael@0 31117 d16 = +HEAPF32[i2 + 8 >> 2] * d4 + d15;
michael@0 31118 if (i10) {
michael@0 31119 d17 = d12 - +HEAPF32[i1 + 120 >> 2];
michael@0 31120 d18 = d14 - +HEAPF32[i1 + 124 >> 2];
michael@0 31121 d19 = d16 - +HEAPF32[i1 + 128 >> 2];
michael@0 31122 d20 = d11 - +HEAPF32[i1 + 56 >> 2];
michael@0 31123 d21 = d13 - +HEAPF32[i1 + 60 >> 2];
michael@0 31124 d22 = d15 - +HEAPF32[i1 + 64 >> 2];
michael@0 31125 d23 = d20 * +HEAPF32[i1 + 8 >> 2] + d21 * +HEAPF32[i1 + 24 >> 2] + d22 * +HEAPF32[i1 + 40 >> 2];
michael@0 31126 d24 = d20 * +HEAPF32[i1 + 12 >> 2] + d21 * +HEAPF32[i1 + 28 >> 2] + d22 * +HEAPF32[i1 + 44 >> 2];
michael@0 31127 d25 = d20 * +HEAPF32[i1 + 16 >> 2] + d21 * +HEAPF32[i1 + 32 >> 2] + d22 * +HEAPF32[i1 + 48 >> 2];
michael@0 31128 d26 = d17 * +HEAPF32[i1 + 72 >> 2] + d18 * +HEAPF32[i1 + 88 >> 2] + d19 * +HEAPF32[i1 + 104 >> 2];
michael@0 31129 d27 = d17 * +HEAPF32[i1 + 76 >> 2] + d18 * +HEAPF32[i1 + 92 >> 2] + d19 * +HEAPF32[i1 + 108 >> 2];
michael@0 31130 d28 = d17 * +HEAPF32[i1 + 80 >> 2] + d18 * +HEAPF32[i1 + 96 >> 2] + d19 * +HEAPF32[i1 + 112 >> 2];
michael@0 31131 } else {
michael@0 31132 d19 = d12 - +HEAPF32[i1 + 56 >> 2];
michael@0 31133 d18 = d14 - +HEAPF32[i1 + 60 >> 2];
michael@0 31134 d17 = d16 - +HEAPF32[i1 + 64 >> 2];
michael@0 31135 d22 = d11 - +HEAPF32[i1 + 120 >> 2];
michael@0 31136 d11 = d13 - +HEAPF32[i1 + 124 >> 2];
michael@0 31137 d13 = d15 - +HEAPF32[i1 + 128 >> 2];
michael@0 31138 d23 = d22 * +HEAPF32[i1 + 72 >> 2] + d11 * +HEAPF32[i1 + 88 >> 2] + d13 * +HEAPF32[i1 + 104 >> 2];
michael@0 31139 d24 = d22 * +HEAPF32[i1 + 76 >> 2] + d11 * +HEAPF32[i1 + 92 >> 2] + d13 * +HEAPF32[i1 + 108 >> 2];
michael@0 31140 d25 = d22 * +HEAPF32[i1 + 80 >> 2] + d11 * +HEAPF32[i1 + 96 >> 2] + d13 * +HEAPF32[i1 + 112 >> 2];
michael@0 31141 d26 = d19 * +HEAPF32[i1 + 8 >> 2] + d18 * +HEAPF32[i1 + 24 >> 2] + d17 * +HEAPF32[i1 + 40 >> 2];
michael@0 31142 d27 = d19 * +HEAPF32[i1 + 12 >> 2] + d18 * +HEAPF32[i1 + 28 >> 2] + d17 * +HEAPF32[i1 + 44 >> 2];
michael@0 31143 d28 = d19 * +HEAPF32[i1 + 16 >> 2] + d18 * +HEAPF32[i1 + 32 >> 2] + d17 * +HEAPF32[i1 + 48 >> 2];
michael@0 31144 }
michael@0 31145 HEAPF32[i6 >> 2] = d26;
michael@0 31146 HEAPF32[i6 + 4 >> 2] = d27;
michael@0 31147 HEAPF32[i6 + 8 >> 2] = d28;
michael@0 31148 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 31149 HEAPF32[i6 + 16 >> 2] = d23;
michael@0 31150 HEAPF32[i6 + 20 >> 2] = d24;
michael@0 31151 HEAPF32[i6 + 24 >> 2] = d25;
michael@0 31152 HEAPF32[i6 + 28 >> 2] = 0.0;
michael@0 31153 i29 = i6 + 64 | 0;
michael@0 31154 i30 = i2;
michael@0 31155 HEAP32[i29 >> 2] = HEAP32[i30 >> 2];
michael@0 31156 HEAP32[i29 + 4 >> 2] = HEAP32[i30 + 4 >> 2];
michael@0 31157 HEAP32[i29 + 8 >> 2] = HEAP32[i30 + 8 >> 2];
michael@0 31158 HEAP32[i29 + 12 >> 2] = HEAP32[i30 + 12 >> 2];
michael@0 31159 HEAPF32[i6 + 80 >> 2] = d4;
michael@0 31160 i30 = i6 + 84 | 0;
michael@0 31161 HEAPF32[i30 >> 2] = 0.0;
michael@0 31162 i29 = i6 + 88 | 0;
michael@0 31163 HEAPF32[i29 >> 2] = 0.0;
michael@0 31164 HEAP32[i6 + 108 >> 2] = 0;
michael@0 31165 HEAPF32[i6 + 112 >> 2] = 0.0;
michael@0 31166 HEAP8[i6 + 116 | 0] = 0;
michael@0 31167 HEAPF32[i6 + 208 >> 2] = 0.0;
michael@0 31168 HEAPF32[i6 + 240 >> 2] = 0.0;
michael@0 31169 HEAPF32[i6 + 272 >> 2] = 0.0;
michael@0 31170 _memset(i6 + 120 | 0, 0, 28);
michael@0 31171 HEAPF32[i6 + 48 >> 2] = d12;
michael@0 31172 HEAPF32[i6 + 52 >> 2] = d14;
michael@0 31173 HEAPF32[i6 + 56 >> 2] = d16;
michael@0 31174 HEAPF32[i6 + 60 >> 2] = 0.0;
michael@0 31175 i2 = i6 + 32 | 0;
michael@0 31176 i31 = i3;
michael@0 31177 HEAP32[i2 >> 2] = HEAP32[i31 >> 2];
michael@0 31178 HEAP32[i2 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 31179 HEAP32[i2 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 31180 HEAP32[i2 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 31181 i31 = __ZNK20btPersistentManifold13getCacheEntryERK15btManifoldPoint(i8, i6) | 0;
michael@0 31182 i8 = HEAP32[i9 >> 2] | 0;
michael@0 31183 i2 = i1 + 140 | 0;
michael@0 31184 i3 = HEAP32[i2 >> 2] | 0;
michael@0 31185 d16 = +HEAPF32[i8 + 224 >> 2] * +HEAPF32[i3 + 224 >> 2];
michael@0 31186 d14 = d16 < -10.0 ? -10.0 : d16;
michael@0 31187 HEAPF32[i30 >> 2] = d14 > 10.0 ? 10.0 : d14;
michael@0 31188 HEAPF32[i29 >> 2] = +HEAPF32[i8 + 228 >> 2] * +HEAPF32[i3 + 228 >> 2];
michael@0 31189 if (i10) {
michael@0 31190 HEAP32[i6 + 92 >> 2] = HEAP32[i1 + 148 >> 2];
michael@0 31191 HEAP32[i6 + 96 >> 2] = HEAP32[i1 + 144 >> 2];
michael@0 31192 HEAP32[i6 + 100 >> 2] = HEAP32[i1 + 156 >> 2];
michael@0 31193 HEAP32[i6 + 104 >> 2] = HEAP32[i1 + 152 >> 2];
michael@0 31194 } else {
michael@0 31195 HEAP32[i6 + 92 >> 2] = HEAP32[i1 + 144 >> 2];
michael@0 31196 HEAP32[i6 + 96 >> 2] = HEAP32[i1 + 148 >> 2];
michael@0 31197 HEAP32[i6 + 100 >> 2] = HEAP32[i1 + 152 >> 2];
michael@0 31198 HEAP32[i6 + 104 >> 2] = HEAP32[i1 + 156 >> 2];
michael@0 31199 }
michael@0 31200 i1 = HEAP32[i7 >> 2] | 0;
michael@0 31201 if ((i31 | 0) > -1) {
michael@0 31202 i3 = i1 + 4 + (i31 * 276 | 0) + 144 | 0;
michael@0 31203 i8 = HEAP32[i3 >> 2] | 0;
michael@0 31204 i29 = i1 + 4 + (i31 * 276 | 0) + 208 | 0;
michael@0 31205 d14 = +HEAPF32[i29 >> 2];
michael@0 31206 i30 = i1 + 4 + (i31 * 276 | 0) + 240 | 0;
michael@0 31207 d16 = +HEAPF32[i30 >> 2];
michael@0 31208 i32 = i1 + 4 + (i31 * 276 | 0) + 272 | 0;
michael@0 31209 d12 = +HEAPF32[i32 >> 2];
michael@0 31210 i33 = i1 + 4 + (i31 * 276 | 0) + 108 | 0;
michael@0 31211 i34 = HEAP32[i33 >> 2] | 0;
michael@0 31212 i35 = i1 + 4 + (i31 * 276 | 0) | 0;
michael@0 31213 i36 = i6;
michael@0 31214 _memcpy(i35 | 0, i36 | 0, 276) | 0;
michael@0 31215 HEAP32[i33 >> 2] = i34;
michael@0 31216 HEAPF32[i1 + 4 + (i31 * 276 | 0) + 112 >> 2] = d14;
michael@0 31217 HEAPF32[i1 + 4 + (i31 * 276 | 0) + 120 >> 2] = d16;
michael@0 31218 HEAPF32[i1 + 4 + (i31 * 276 | 0) + 124 >> 2] = d12;
michael@0 31219 HEAPF32[i29 >> 2] = d14;
michael@0 31220 HEAPF32[i30 >> 2] = d16;
michael@0 31221 HEAPF32[i32 >> 2] = d12;
michael@0 31222 HEAP32[i3 >> 2] = i8;
michael@0 31223 i37 = i31;
michael@0 31224 } else {
michael@0 31225 i37 = __ZN20btPersistentManifold16addManifoldPointERK15btManifoldPoint(i1, i6) | 0;
michael@0 31226 }
michael@0 31227 i1 = HEAP32[3010] | 0;
michael@0 31228 if ((i1 | 0) == 0) {
michael@0 31229 STACKTOP = i5;
michael@0 31230 return;
michael@0 31231 }
michael@0 31232 do {
michael@0 31233 if ((HEAP32[(HEAP32[i9 >> 2] | 0) + 204 >> 2] & 8 | 0) == 0) {
michael@0 31234 if ((HEAP32[(HEAP32[i2 >> 2] | 0) + 204 >> 2] & 8 | 0) != 0) {
michael@0 31235 break;
michael@0 31236 }
michael@0 31237 STACKTOP = i5;
michael@0 31238 return;
michael@0 31239 }
michael@0 31240 } while (0);
michael@0 31241 FUNCTION_TABLE_iiiiiiii[i1 & 1]((HEAP32[i7 >> 2] | 0) + 4 + (i37 * 276 | 0) | 0, HEAP32[(i10 ? i2 : i9) >> 2] | 0, HEAP32[i6 + 92 >> 2] | 0, HEAP32[i6 + 100 >> 2] | 0, HEAP32[(i10 ? i9 : i2) >> 2] | 0, HEAP32[i6 + 96 >> 2] | 0, HEAP32[i6 + 104 >> 2] | 0) | 0;
michael@0 31242 STACKTOP = i5;
michael@0 31243 return;
michael@0 31244 }
michael@0 31245 function __ZN16btDbvtBroadphase7collideEP12btDispatcher(i1, i2) {
michael@0 31246 i1 = i1 | 0;
michael@0 31247 i2 = i2 | 0;
michael@0 31248 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0;
michael@0 31249 i3 = STACKTOP;
michael@0 31250 STACKTOP = STACKTOP + 48 | 0;
michael@0 31251 i4 = i3 | 0;
michael@0 31252 i5 = i3 + 32 | 0;
michael@0 31253 i6 = i1 + 4 | 0;
michael@0 31254 i7 = i6 | 0;
michael@0 31255 __ZN6btDbvt19optimizeIncrementalEi(i7, ((Math_imul(HEAP32[i1 + 112 >> 2] | 0, HEAP32[i1 + 16 >> 2] | 0) | 0) / 100 | 0) + 1 | 0);
michael@0 31256 i8 = i1 + 124 | 0;
michael@0 31257 if ((HEAP32[i8 >> 2] | 0) != 0) {
michael@0 31258 i9 = ((Math_imul(HEAP32[i1 + 108 >> 2] | 0, HEAP32[i1 + 56 >> 2] | 0) | 0) / 100 | 0) + 1 | 0;
michael@0 31259 __ZN6btDbvt19optimizeIncrementalEi(i1 + 44 | 0, i9);
michael@0 31260 i10 = (HEAP32[i8 >> 2] | 0) - i9 | 0;
michael@0 31261 HEAP32[i8 >> 2] = (i10 | 0) < 0 ? 0 : i10;
michael@0 31262 }
michael@0 31263 i10 = i1 + 104 | 0;
michael@0 31264 i9 = ((HEAP32[i10 >> 2] | 0) + 1 | 0) % 2 | 0;
michael@0 31265 HEAP32[i10 >> 2] = i9;
michael@0 31266 i10 = HEAP32[i1 + 84 + (i9 << 2) >> 2] | 0;
michael@0 31267 if ((i10 | 0) != 0) {
michael@0 31268 i9 = i1 + 92 | 0;
michael@0 31269 i11 = i4;
michael@0 31270 i12 = i4 + 16 | 0;
michael@0 31271 i13 = i1 + 44 | 0;
michael@0 31272 i14 = i10;
michael@0 31273 while (1) {
michael@0 31274 i10 = i14 + 56 | 0;
michael@0 31275 i15 = HEAP32[i10 >> 2] | 0;
michael@0 31276 i16 = i14 + 60 | 0;
michael@0 31277 i17 = i14 + 52 | 0;
michael@0 31278 i18 = HEAP32[i17 >> 2] | 0;
michael@0 31279 if ((i18 | 0) == 0) {
michael@0 31280 HEAP32[i1 + 84 + (HEAP32[i16 >> 2] << 2) >> 2] = i15;
michael@0 31281 } else {
michael@0 31282 HEAP32[i18 + 56 >> 2] = i15;
michael@0 31283 }
michael@0 31284 i18 = HEAP32[i10 >> 2] | 0;
michael@0 31285 if ((i18 | 0) != 0) {
michael@0 31286 HEAP32[i18 + 52 >> 2] = HEAP32[i17 >> 2];
michael@0 31287 }
michael@0 31288 HEAP32[i17 >> 2] = 0;
michael@0 31289 HEAP32[i10 >> 2] = HEAP32[i9 >> 2];
michael@0 31290 i10 = HEAP32[i9 >> 2] | 0;
michael@0 31291 if ((i10 | 0) != 0) {
michael@0 31292 HEAP32[i10 + 52 >> 2] = i14;
michael@0 31293 }
michael@0 31294 HEAP32[i9 >> 2] = i14;
michael@0 31295 i10 = i14 + 48 | 0;
michael@0 31296 __ZN6btDbvt6removeEP10btDbvtNode(i7, HEAP32[i10 >> 2] | 0);
michael@0 31297 i17 = i14 + 16 | 0;
michael@0 31298 HEAP32[i11 >> 2] = HEAP32[i17 >> 2];
michael@0 31299 HEAP32[i11 + 4 >> 2] = HEAP32[i17 + 4 >> 2];
michael@0 31300 HEAP32[i11 + 8 >> 2] = HEAP32[i17 + 8 >> 2];
michael@0 31301 HEAP32[i11 + 12 >> 2] = HEAP32[i17 + 12 >> 2];
michael@0 31302 i17 = i14 + 32 | 0;
michael@0 31303 HEAP32[i12 >> 2] = HEAP32[i17 >> 2];
michael@0 31304 HEAP32[i12 + 4 >> 2] = HEAP32[i17 + 4 >> 2];
michael@0 31305 HEAP32[i12 + 8 >> 2] = HEAP32[i17 + 8 >> 2];
michael@0 31306 HEAP32[i12 + 12 >> 2] = HEAP32[i17 + 12 >> 2];
michael@0 31307 HEAP32[i10 >> 2] = __ZN6btDbvt6insertERK12btDbvtAabbMmPv(i13, i4, i14) | 0;
michael@0 31308 HEAP32[i16 >> 2] = 2;
michael@0 31309 if ((i15 | 0) == 0) {
michael@0 31310 break;
michael@0 31311 } else {
michael@0 31312 i14 = i15;
michael@0 31313 }
michael@0 31314 }
michael@0 31315 HEAP32[i8 >> 2] = HEAP32[i1 + 56 >> 2];
michael@0 31316 HEAP8[i1 + 154 | 0] = 1;
michael@0 31317 }
michael@0 31318 HEAP32[i5 >> 2] = 4064;
michael@0 31319 HEAP32[i5 + 4 >> 2] = i1;
michael@0 31320 i8 = i1 + 153 | 0;
michael@0 31321 do {
michael@0 31322 if ((HEAP8[i8] | 0) != 0) {
michael@0 31323 i14 = i6 | 0;
michael@0 31324 i4 = i5 | 0;
michael@0 31325 __ZN6btDbvt24collideTTpersistentStackEPK10btDbvtNodeS2_RNS_8ICollideE(i7, HEAP32[i14 >> 2] | 0, HEAP32[i1 + 44 >> 2] | 0, i4);
michael@0 31326 if ((HEAP8[i8] | 0) == 0) {
michael@0 31327 break;
michael@0 31328 }
michael@0 31329 i13 = HEAP32[i14 >> 2] | 0;
michael@0 31330 __ZN6btDbvt24collideTTpersistentStackEPK10btDbvtNodeS2_RNS_8ICollideE(i7, i13, i13, i4);
michael@0 31331 }
michael@0 31332 } while (0);
michael@0 31333 i7 = i1 + 154 | 0;
michael@0 31334 L1067 : do {
michael@0 31335 if ((HEAP8[i7] | 0) != 0) {
michael@0 31336 i8 = i1 + 96 | 0;
michael@0 31337 i5 = HEAP32[i8 >> 2] | 0;
michael@0 31338 i6 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i5 >> 2] | 0) + 28 >> 2] & 127](i5) | 0;
michael@0 31339 i5 = i6 + 4 | 0;
michael@0 31340 i4 = HEAP32[i5 >> 2] | 0;
michael@0 31341 if ((i4 | 0) <= 0) {
michael@0 31342 break;
michael@0 31343 }
michael@0 31344 i13 = (Math_imul(HEAP32[i1 + 116 >> 2] | 0, i4) | 0) / 100 | 0;
michael@0 31345 i14 = HEAP32[i1 + 120 >> 2] | 0;
michael@0 31346 i12 = (i14 | 0) > (i13 | 0) ? i14 : i13;
michael@0 31347 i13 = (i4 | 0) < (i12 | 0) ? i4 : i12;
michael@0 31348 i12 = i1 + 144 | 0;
michael@0 31349 do {
michael@0 31350 if ((i13 | 0) > 0) {
michael@0 31351 i14 = i6 + 12 | 0;
michael@0 31352 i11 = i13;
michael@0 31353 i9 = 0;
michael@0 31354 i15 = i4;
michael@0 31355 while (1) {
michael@0 31356 i16 = ((HEAP32[i12 >> 2] | 0) + i9 | 0) % (i15 | 0) | 0;
michael@0 31357 i10 = HEAP32[i14 >> 2] | 0;
michael@0 31358 i17 = HEAP32[i10 + (i16 << 4) >> 2] | 0;
michael@0 31359 i18 = HEAP32[i10 + (i16 << 4) + 4 >> 2] | 0;
michael@0 31360 i16 = HEAP32[i17 + 48 >> 2] | 0;
michael@0 31361 i10 = HEAP32[i18 + 48 >> 2] | 0;
michael@0 31362 do {
michael@0 31363 if (+HEAPF32[i16 >> 2] > +HEAPF32[i10 + 16 >> 2]) {
michael@0 31364 i19 = 976;
michael@0 31365 } else {
michael@0 31366 if (+HEAPF32[i16 + 16 >> 2] < +HEAPF32[i10 >> 2]) {
michael@0 31367 i19 = 976;
michael@0 31368 break;
michael@0 31369 }
michael@0 31370 if (+HEAPF32[i16 + 4 >> 2] > +HEAPF32[i10 + 20 >> 2]) {
michael@0 31371 i19 = 976;
michael@0 31372 break;
michael@0 31373 }
michael@0 31374 if (+HEAPF32[i16 + 20 >> 2] < +HEAPF32[i10 + 4 >> 2]) {
michael@0 31375 i19 = 976;
michael@0 31376 break;
michael@0 31377 }
michael@0 31378 if (+HEAPF32[i16 + 8 >> 2] > +HEAPF32[i10 + 24 >> 2]) {
michael@0 31379 i19 = 976;
michael@0 31380 break;
michael@0 31381 }
michael@0 31382 if (+HEAPF32[i16 + 24 >> 2] < +HEAPF32[i10 + 8 >> 2]) {
michael@0 31383 i19 = 976;
michael@0 31384 } else {
michael@0 31385 i20 = i9;
michael@0 31386 i21 = i11;
michael@0 31387 i22 = i15;
michael@0 31388 }
michael@0 31389 }
michael@0 31390 } while (0);
michael@0 31391 if ((i19 | 0) == 976) {
michael@0 31392 i19 = 0;
michael@0 31393 i10 = HEAP32[i8 >> 2] | 0;
michael@0 31394 i16 = i10 | 0;
michael@0 31395 i23 = HEAP32[(HEAP32[i10 >> 2] | 0) + 12 >> 2] | 0;
michael@0 31396 FUNCTION_TABLE_iiiii[i23 & 31](i16, i17, i18, i2) | 0;
michael@0 31397 i20 = i9 - 1 | 0;
michael@0 31398 i21 = i11 - 1 | 0;
michael@0 31399 i22 = HEAP32[i5 >> 2] | 0;
michael@0 31400 }
michael@0 31401 i16 = i20 + 1 | 0;
michael@0 31402 if ((i16 | 0) < (i21 | 0)) {
michael@0 31403 i11 = i21;
michael@0 31404 i9 = i16;
michael@0 31405 i15 = i22;
michael@0 31406 } else {
michael@0 31407 break;
michael@0 31408 }
michael@0 31409 }
michael@0 31410 if ((i22 | 0) > 0) {
michael@0 31411 i24 = i22;
michael@0 31412 i25 = i21;
michael@0 31413 break;
michael@0 31414 }
michael@0 31415 HEAP32[i12 >> 2] = 0;
michael@0 31416 break L1067;
michael@0 31417 } else {
michael@0 31418 i24 = i4;
michael@0 31419 i25 = i13;
michael@0 31420 }
michael@0 31421 } while (0);
michael@0 31422 HEAP32[i12 >> 2] = ((HEAP32[i12 >> 2] | 0) + i25 | 0) % (i24 | 0) | 0;
michael@0 31423 }
michael@0 31424 } while (0);
michael@0 31425 i24 = i1 + 140 | 0;
michael@0 31426 HEAP32[i24 >> 2] = (HEAP32[i24 >> 2] | 0) + 1;
michael@0 31427 HEAP32[i1 + 120 >> 2] = 1;
michael@0 31428 HEAP8[i7] = 0;
michael@0 31429 i7 = i1 + 128 | 0;
michael@0 31430 i24 = HEAP32[i7 >> 2] | 0;
michael@0 31431 if ((i24 | 0) == 0) {
michael@0 31432 HEAPF32[i1 + 136 >> 2] = 0.0;
michael@0 31433 i26 = HEAP32[i1 + 132 >> 2] | 0;
michael@0 31434 i27 = i1 + 132 | 0;
michael@0 31435 i28 = i26 >>> 1;
michael@0 31436 HEAP32[i27 >> 2] = i28;
michael@0 31437 i29 = i24 >>> 1;
michael@0 31438 HEAP32[i7 >> 2] = i29;
michael@0 31439 STACKTOP = i3;
michael@0 31440 return;
michael@0 31441 } else {
michael@0 31442 i25 = HEAP32[i1 + 132 >> 2] | 0;
michael@0 31443 HEAPF32[i1 + 136 >> 2] = +(i25 >>> 0 >>> 0) / +(i24 >>> 0 >>> 0);
michael@0 31444 i26 = i25;
michael@0 31445 i27 = i1 + 132 | 0;
michael@0 31446 i28 = i26 >>> 1;
michael@0 31447 HEAP32[i27 >> 2] = i28;
michael@0 31448 i29 = i24 >>> 1;
michael@0 31449 HEAP32[i7 >> 2] = i29;
michael@0 31450 STACKTOP = i3;
michael@0 31451 return;
michael@0 31452 }
michael@0 31453 }
michael@0 31454 function __ZN6btDbvt24collideTTpersistentStackEPK10btDbvtNodeS2_RNS_8ICollideE(i1, i2, i3, i4) {
michael@0 31455 i1 = i1 | 0;
michael@0 31456 i2 = i2 | 0;
michael@0 31457 i3 = i3 | 0;
michael@0 31458 i4 = i4 | 0;
michael@0 31459 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0;
michael@0 31460 if ((i2 | 0) == 0 | (i3 | 0) == 0) {
michael@0 31461 return;
michael@0 31462 }
michael@0 31463 i5 = i1 + 24 | 0;
michael@0 31464 i6 = i1 + 28 | 0;
michael@0 31465 do {
michael@0 31466 if ((HEAP32[i5 >> 2] | 0) < 128) {
michael@0 31467 if ((HEAP32[i6 >> 2] | 0) >= 128) {
michael@0 31468 break;
michael@0 31469 }
michael@0 31470 i7 = __Z22btAlignedAllocInternalji(1024, 16) | 0;
michael@0 31471 i8 = HEAP32[i5 >> 2] | 0;
michael@0 31472 i9 = i1 + 32 | 0;
michael@0 31473 if ((i8 | 0) > 0) {
michael@0 31474 i10 = 0;
michael@0 31475 do {
michael@0 31476 i11 = i7 + (i10 << 3) | 0;
michael@0 31477 if ((i11 | 0) != 0) {
michael@0 31478 i12 = (HEAP32[i9 >> 2] | 0) + (i10 << 3) | 0;
michael@0 31479 i13 = i11;
michael@0 31480 i11 = HEAP32[i12 + 4 >> 2] | 0;
michael@0 31481 HEAP32[i13 >> 2] = HEAP32[i12 >> 2];
michael@0 31482 HEAP32[i13 + 4 >> 2] = i11;
michael@0 31483 }
michael@0 31484 i10 = i10 + 1 | 0;
michael@0 31485 } while ((i10 | 0) < (i8 | 0));
michael@0 31486 }
michael@0 31487 i8 = HEAP32[i9 >> 2] | 0;
michael@0 31488 i10 = i1 + 36 | 0;
michael@0 31489 if ((i8 | 0) != 0) {
michael@0 31490 if ((HEAP8[i10] | 0) != 0) {
michael@0 31491 __Z21btAlignedFreeInternalPv(i8);
michael@0 31492 }
michael@0 31493 HEAP32[i9 >> 2] = 0;
michael@0 31494 }
michael@0 31495 HEAP8[i10] = 1;
michael@0 31496 HEAP32[i9 >> 2] = i7;
michael@0 31497 HEAP32[i6 >> 2] = 128;
michael@0 31498 }
michael@0 31499 } while (0);
michael@0 31500 HEAP32[i5 >> 2] = 128;
michael@0 31501 i10 = i1 + 32 | 0;
michael@0 31502 i8 = HEAP32[i10 >> 2] | 0;
michael@0 31503 HEAP32[i8 >> 2] = i2;
michael@0 31504 HEAP32[i8 + 4 >> 2] = i3;
michael@0 31505 i3 = i1 + 36 | 0;
michael@0 31506 i1 = i4;
michael@0 31507 i8 = 1;
michael@0 31508 i2 = 124;
michael@0 31509 while (1) {
michael@0 31510 i11 = i8 - 1 | 0;
michael@0 31511 i13 = HEAP32[i10 >> 2] | 0;
michael@0 31512 i12 = HEAP32[i13 + (i11 << 3) >> 2] | 0;
michael@0 31513 i14 = HEAP32[i13 + (i11 << 3) + 4 >> 2] | 0;
michael@0 31514 if ((i11 | 0) > (i2 | 0)) {
michael@0 31515 i15 = HEAP32[i5 >> 2] | 0;
michael@0 31516 i16 = i15 << 1;
michael@0 31517 do {
michael@0 31518 if ((i15 | 0) < (i16 | 0)) {
michael@0 31519 if ((HEAP32[i6 >> 2] | 0) >= (i16 | 0)) {
michael@0 31520 i17 = i13;
michael@0 31521 break;
michael@0 31522 }
michael@0 31523 if ((i16 | 0) == 0) {
michael@0 31524 i18 = 0;
michael@0 31525 i19 = i15;
michael@0 31526 } else {
michael@0 31527 i20 = __Z22btAlignedAllocInternalji(i15 << 4, 16) | 0;
michael@0 31528 i18 = i20;
michael@0 31529 i19 = HEAP32[i5 >> 2] | 0;
michael@0 31530 }
michael@0 31531 if ((i19 | 0) > 0) {
michael@0 31532 i20 = 0;
michael@0 31533 do {
michael@0 31534 i21 = i18 + (i20 << 3) | 0;
michael@0 31535 if ((i21 | 0) != 0) {
michael@0 31536 i22 = (HEAP32[i10 >> 2] | 0) + (i20 << 3) | 0;
michael@0 31537 i23 = i21;
michael@0 31538 i21 = HEAP32[i22 + 4 >> 2] | 0;
michael@0 31539 HEAP32[i23 >> 2] = HEAP32[i22 >> 2];
michael@0 31540 HEAP32[i23 + 4 >> 2] = i21;
michael@0 31541 }
michael@0 31542 i20 = i20 + 1 | 0;
michael@0 31543 } while ((i20 | 0) < (i19 | 0));
michael@0 31544 }
michael@0 31545 i20 = HEAP32[i10 >> 2] | 0;
michael@0 31546 if ((i20 | 0) != 0) {
michael@0 31547 if ((HEAP8[i3] | 0) != 0) {
michael@0 31548 __Z21btAlignedFreeInternalPv(i20);
michael@0 31549 }
michael@0 31550 HEAP32[i10 >> 2] = 0;
michael@0 31551 }
michael@0 31552 HEAP8[i3] = 1;
michael@0 31553 HEAP32[i10 >> 2] = i18;
michael@0 31554 HEAP32[i6 >> 2] = i16;
michael@0 31555 i17 = i18;
michael@0 31556 } else {
michael@0 31557 i17 = i13;
michael@0 31558 }
michael@0 31559 } while (0);
michael@0 31560 HEAP32[i5 >> 2] = i16;
michael@0 31561 i24 = i16 - 4 | 0;
michael@0 31562 i25 = i17;
michael@0 31563 } else {
michael@0 31564 i24 = i2;
michael@0 31565 i25 = i13;
michael@0 31566 }
michael@0 31567 do {
michael@0 31568 if ((i12 | 0) == (i14 | 0)) {
michael@0 31569 i15 = i12 + 40 | 0;
michael@0 31570 if ((HEAP32[i15 >> 2] | 0) == 0) {
michael@0 31571 i26 = i11;
michael@0 31572 break;
michael@0 31573 }
michael@0 31574 i7 = i12 + 36 | 0;
michael@0 31575 i9 = i25 + (i11 << 3) | 0;
michael@0 31576 i20 = HEAP32[i7 >> 2] | 0;
michael@0 31577 HEAP32[i9 >> 2] = i20;
michael@0 31578 HEAP32[i9 + 4 >> 2] = i20;
michael@0 31579 i20 = (HEAP32[i10 >> 2] | 0) + (i8 << 3) | 0;
michael@0 31580 i9 = HEAP32[i15 >> 2] | 0;
michael@0 31581 HEAP32[i20 >> 2] = i9;
michael@0 31582 HEAP32[i20 + 4 >> 2] = i9;
michael@0 31583 i9 = (HEAP32[i10 >> 2] | 0) + (i8 + 1 << 3) | 0;
michael@0 31584 i20 = HEAP32[i15 >> 2] | 0;
michael@0 31585 HEAP32[i9 >> 2] = HEAP32[i7 >> 2];
michael@0 31586 HEAP32[i9 + 4 >> 2] = i20;
michael@0 31587 i26 = i8 + 2 | 0;
michael@0 31588 } else {
michael@0 31589 if (+HEAPF32[i12 >> 2] > +HEAPF32[i14 + 16 >> 2]) {
michael@0 31590 i26 = i11;
michael@0 31591 break;
michael@0 31592 }
michael@0 31593 if (+HEAPF32[i12 + 16 >> 2] < +HEAPF32[i14 >> 2]) {
michael@0 31594 i26 = i11;
michael@0 31595 break;
michael@0 31596 }
michael@0 31597 if (+HEAPF32[i12 + 4 >> 2] > +HEAPF32[i14 + 20 >> 2]) {
michael@0 31598 i26 = i11;
michael@0 31599 break;
michael@0 31600 }
michael@0 31601 if (+HEAPF32[i12 + 20 >> 2] < +HEAPF32[i14 + 4 >> 2]) {
michael@0 31602 i26 = i11;
michael@0 31603 break;
michael@0 31604 }
michael@0 31605 if (+HEAPF32[i12 + 8 >> 2] > +HEAPF32[i14 + 24 >> 2]) {
michael@0 31606 i26 = i11;
michael@0 31607 break;
michael@0 31608 }
michael@0 31609 if (+HEAPF32[i12 + 24 >> 2] < +HEAPF32[i14 + 8 >> 2]) {
michael@0 31610 i26 = i11;
michael@0 31611 break;
michael@0 31612 }
michael@0 31613 i20 = i12 + 40 | 0;
michael@0 31614 i9 = i14 + 40 | 0;
michael@0 31615 i7 = (HEAP32[i9 >> 2] | 0) != 0;
michael@0 31616 if ((HEAP32[i20 >> 2] | 0) == 0) {
michael@0 31617 if (i7) {
michael@0 31618 i15 = i25 + (i11 << 3) | 0;
michael@0 31619 i21 = i12;
michael@0 31620 i23 = 0;
michael@0 31621 i22 = HEAP32[i14 + 36 >> 2] | i23;
michael@0 31622 HEAP32[i15 >> 2] = i21;
michael@0 31623 HEAP32[i15 + 4 >> 2] = i22;
michael@0 31624 i22 = (HEAP32[i10 >> 2] | 0) + (i8 << 3) | 0;
michael@0 31625 i15 = HEAP32[i9 >> 2] | i23;
michael@0 31626 HEAP32[i22 >> 2] = i21;
michael@0 31627 HEAP32[i22 + 4 >> 2] = i15;
michael@0 31628 i26 = i8 + 1 | 0;
michael@0 31629 break;
michael@0 31630 } else {
michael@0 31631 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i4, i12, i14);
michael@0 31632 i26 = i11;
michael@0 31633 break;
michael@0 31634 }
michael@0 31635 } else {
michael@0 31636 i15 = i25 + (i11 << 3) | 0;
michael@0 31637 i22 = i12 + 36 | 0;
michael@0 31638 i21 = HEAP32[i22 >> 2] | 0;
michael@0 31639 if (i7) {
michael@0 31640 i7 = i14 + 36 | 0;
michael@0 31641 i23 = i15;
michael@0 31642 i27 = HEAP32[i7 >> 2] | 0;
michael@0 31643 HEAP32[i23 >> 2] = i21;
michael@0 31644 HEAP32[i23 + 4 >> 2] = i27;
michael@0 31645 i27 = (HEAP32[i10 >> 2] | 0) + (i8 << 3) | 0;
michael@0 31646 i23 = HEAP32[i7 >> 2] | 0;
michael@0 31647 HEAP32[i27 >> 2] = HEAP32[i20 >> 2];
michael@0 31648 HEAP32[i27 + 4 >> 2] = i23;
michael@0 31649 i23 = (HEAP32[i10 >> 2] | 0) + (i8 + 1 << 3) | 0;
michael@0 31650 i27 = HEAP32[i9 >> 2] | 0;
michael@0 31651 HEAP32[i23 >> 2] = HEAP32[i22 >> 2];
michael@0 31652 HEAP32[i23 + 4 >> 2] = i27;
michael@0 31653 i27 = (HEAP32[i10 >> 2] | 0) + (i8 + 2 << 3) | 0;
michael@0 31654 i23 = HEAP32[i9 >> 2] | 0;
michael@0 31655 HEAP32[i27 >> 2] = HEAP32[i20 >> 2];
michael@0 31656 HEAP32[i27 + 4 >> 2] = i23;
michael@0 31657 i26 = i8 + 3 | 0;
michael@0 31658 break;
michael@0 31659 } else {
michael@0 31660 i23 = i15;
michael@0 31661 i15 = 0;
michael@0 31662 i27 = i14;
michael@0 31663 HEAP32[i23 >> 2] = i21 | i15;
michael@0 31664 HEAP32[i23 + 4 >> 2] = i27;
michael@0 31665 i23 = (HEAP32[i10 >> 2] | 0) + (i8 << 3) | 0;
michael@0 31666 HEAP32[i23 >> 2] = HEAP32[i20 >> 2] | i15;
michael@0 31667 HEAP32[i23 + 4 >> 2] = i27;
michael@0 31668 i26 = i8 + 1 | 0;
michael@0 31669 break;
michael@0 31670 }
michael@0 31671 }
michael@0 31672 }
michael@0 31673 } while (0);
michael@0 31674 if ((i26 | 0) == 0) {
michael@0 31675 break;
michael@0 31676 } else {
michael@0 31677 i8 = i26;
michael@0 31678 i2 = i24;
michael@0 31679 }
michael@0 31680 }
michael@0 31681 return;
michael@0 31682 }
michael@0 31683 function __ZN25btSimulationIslandManager22buildAndProcessIslandsEP12btDispatcherP16btCollisionWorldPNS_14IslandCallbackE(i1, i2, i3, i4) {
michael@0 31684 i1 = i1 | 0;
michael@0 31685 i2 = i2 | 0;
michael@0 31686 i3 = i3 | 0;
michael@0 31687 i4 = i4 | 0;
michael@0 31688 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0;
michael@0 31689 i5 = STACKTOP;
michael@0 31690 STACKTOP = STACKTOP + 8 | 0;
michael@0 31691 __ZN25btSimulationIslandManager12buildIslandsEP12btDispatcherP16btCollisionWorld(i1, i2, i3);
michael@0 31692 i6 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 31693 __ZN15CProfileManager13Start_ProfileEPKc(784);
michael@0 31694 if ((HEAP8[i1 + 64 | 0] | 0) == 0) {
michael@0 31695 i7 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i2 >> 2] | 0) + 44 >> 2] & 127](i2) | 0;
michael@0 31696 i8 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i2 >> 2] | 0) + 36 >> 2] & 127](i2) | 0;
michael@0 31697 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i4 >> 2] | 0) + 8 >> 2] & 15](i4, HEAP32[i3 + 16 >> 2] | 0, HEAP32[i3 + 8 >> 2] | 0, i7, i8, -1);
michael@0 31698 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 31699 STACKTOP = i5;
michael@0 31700 return;
michael@0 31701 }
michael@0 31702 i8 = HEAP32[i1 + 28 >> 2] | 0;
michael@0 31703 if ((i8 | 0) > 1) {
michael@0 31704 __ZN20btAlignedObjectArrayIP20btPersistentManifoldE17quickSortInternalI33btPersistentManifoldSortPredicateEEvT_ii(i1 + 24 | 0, i5 | 0, 0, i8 - 1 | 0);
michael@0 31705 }
michael@0 31706 if ((i6 | 0) <= 0) {
michael@0 31707 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 31708 STACKTOP = i5;
michael@0 31709 return;
michael@0 31710 }
michael@0 31711 i7 = i1 + 16 | 0;
michael@0 31712 i2 = i1 + 36 | 0;
michael@0 31713 i9 = i1 + 48 | 0;
michael@0 31714 i10 = i1 + 52 | 0;
michael@0 31715 i11 = i1 + 56 | 0;
michael@0 31716 i12 = i1 + 60 | 0;
michael@0 31717 i1 = i4;
michael@0 31718 i13 = i3 + 16 | 0;
michael@0 31719 i3 = 1;
michael@0 31720 i14 = 0;
michael@0 31721 i15 = 0;
michael@0 31722 while (1) {
michael@0 31723 i16 = HEAP32[i7 >> 2] | 0;
michael@0 31724 i17 = HEAP32[i16 + (i15 << 3) >> 2] | 0;
michael@0 31725 L304 : do {
michael@0 31726 if ((i15 | 0) < (i6 | 0)) {
michael@0 31727 i18 = i16;
michael@0 31728 i19 = i15;
michael@0 31729 i20 = 1;
michael@0 31730 i21 = HEAP32[i9 >> 2] | 0;
michael@0 31731 i22 = HEAP32[i10 >> 2] | 0;
michael@0 31732 while (1) {
michael@0 31733 i23 = HEAP32[(HEAP32[i13 >> 2] | 0) + (HEAP32[i18 + (i19 << 3) + 4 >> 2] << 2) >> 2] | 0;
michael@0 31734 do {
michael@0 31735 if ((i21 | 0) == (i22 | 0)) {
michael@0 31736 i24 = (i22 | 0) == 0 ? 1 : i22 << 1;
michael@0 31737 if ((i22 | 0) >= (i24 | 0)) {
michael@0 31738 i25 = i22;
michael@0 31739 i26 = i22;
michael@0 31740 break;
michael@0 31741 }
michael@0 31742 if ((i24 | 0) == 0) {
michael@0 31743 i27 = 0;
michael@0 31744 i28 = i22;
michael@0 31745 } else {
michael@0 31746 i29 = __Z22btAlignedAllocInternalji(i24 << 2, 16) | 0;
michael@0 31747 i27 = i29;
michael@0 31748 i28 = HEAP32[i9 >> 2] | 0;
michael@0 31749 }
michael@0 31750 if ((i28 | 0) > 0) {
michael@0 31751 i29 = 0;
michael@0 31752 do {
michael@0 31753 i30 = i27 + (i29 << 2) | 0;
michael@0 31754 if ((i30 | 0) != 0) {
michael@0 31755 HEAP32[i30 >> 2] = HEAP32[(HEAP32[i11 >> 2] | 0) + (i29 << 2) >> 2];
michael@0 31756 }
michael@0 31757 i29 = i29 + 1 | 0;
michael@0 31758 } while ((i29 | 0) < (i28 | 0));
michael@0 31759 }
michael@0 31760 i29 = HEAP32[i11 >> 2] | 0;
michael@0 31761 if ((i29 | 0) == 0) {
michael@0 31762 i31 = i28;
michael@0 31763 } else {
michael@0 31764 if ((HEAP8[i12] | 0) == 0) {
michael@0 31765 i32 = i28;
michael@0 31766 } else {
michael@0 31767 __Z21btAlignedFreeInternalPv(i29);
michael@0 31768 i32 = HEAP32[i9 >> 2] | 0;
michael@0 31769 }
michael@0 31770 HEAP32[i11 >> 2] = 0;
michael@0 31771 i31 = i32;
michael@0 31772 }
michael@0 31773 HEAP8[i12] = 1;
michael@0 31774 HEAP32[i11 >> 2] = i27;
michael@0 31775 HEAP32[i10 >> 2] = i24;
michael@0 31776 i25 = i31;
michael@0 31777 i26 = i24;
michael@0 31778 } else {
michael@0 31779 i25 = i21;
michael@0 31780 i26 = i22;
michael@0 31781 }
michael@0 31782 } while (0);
michael@0 31783 i29 = (HEAP32[i11 >> 2] | 0) + (i25 << 2) | 0;
michael@0 31784 if ((i29 | 0) != 0) {
michael@0 31785 HEAP32[i29 >> 2] = i23;
michael@0 31786 }
michael@0 31787 i29 = i25 + 1 | 0;
michael@0 31788 HEAP32[i9 >> 2] = i29;
michael@0 31789 i30 = HEAP32[i23 + 216 >> 2] | 0;
michael@0 31790 i33 = i20 & ((i30 | 0) == 2 | (i30 | 0) == 5);
michael@0 31791 i30 = i19 + 1 | 0;
michael@0 31792 if ((i30 | 0) >= (i6 | 0)) {
michael@0 31793 i34 = i33;
michael@0 31794 i35 = i30;
michael@0 31795 break L304;
michael@0 31796 }
michael@0 31797 i36 = HEAP32[i7 >> 2] | 0;
michael@0 31798 if ((HEAP32[i36 + (i30 << 3) >> 2] | 0) == (i17 | 0)) {
michael@0 31799 i18 = i36;
michael@0 31800 i19 = i30;
michael@0 31801 i20 = i33;
michael@0 31802 i21 = i29;
michael@0 31803 i22 = i26;
michael@0 31804 } else {
michael@0 31805 i34 = i33;
michael@0 31806 i35 = i30;
michael@0 31807 break;
michael@0 31808 }
michael@0 31809 }
michael@0 31810 } else {
michael@0 31811 i34 = 1;
michael@0 31812 i35 = i15;
michael@0 31813 }
michael@0 31814 } while (0);
michael@0 31815 do {
michael@0 31816 if ((i14 | 0) < (i8 | 0)) {
michael@0 31817 i16 = HEAP32[i2 >> 2] | 0;
michael@0 31818 i22 = i16 + (i14 << 2) | 0;
michael@0 31819 i21 = HEAP32[i22 >> 2] | 0;
michael@0 31820 i20 = HEAP32[(HEAP32[i21 + 1108 >> 2] | 0) + 208 >> 2] | 0;
michael@0 31821 if ((i20 | 0) > -1) {
michael@0 31822 i37 = i20;
michael@0 31823 } else {
michael@0 31824 i37 = HEAP32[(HEAP32[i21 + 1112 >> 2] | 0) + 208 >> 2] | 0;
michael@0 31825 }
michael@0 31826 if ((i37 | 0) == (i17 | 0)) {
michael@0 31827 i38 = i14;
michael@0 31828 } else {
michael@0 31829 i39 = 0;
michael@0 31830 i40 = 0;
michael@0 31831 i41 = i3;
michael@0 31832 break;
michael@0 31833 }
michael@0 31834 do {
michael@0 31835 i38 = i38 + 1 | 0;
michael@0 31836 if ((i38 | 0) >= (i8 | 0)) {
michael@0 31837 break;
michael@0 31838 }
michael@0 31839 i21 = HEAP32[i16 + (i38 << 2) >> 2] | 0;
michael@0 31840 i20 = HEAP32[(HEAP32[i21 + 1108 >> 2] | 0) + 208 >> 2] | 0;
michael@0 31841 if ((i20 | 0) > -1) {
michael@0 31842 i42 = i20;
michael@0 31843 } else {
michael@0 31844 i42 = HEAP32[(HEAP32[i21 + 1112 >> 2] | 0) + 208 >> 2] | 0;
michael@0 31845 }
michael@0 31846 } while ((i17 | 0) == (i42 | 0));
michael@0 31847 i39 = i22;
michael@0 31848 i40 = i38 - i14 | 0;
michael@0 31849 i41 = i38;
michael@0 31850 } else {
michael@0 31851 i39 = 0;
michael@0 31852 i40 = 0;
michael@0 31853 i41 = i3;
michael@0 31854 }
michael@0 31855 } while (0);
michael@0 31856 if (!i34) {
michael@0 31857 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 15](i4, HEAP32[i11 >> 2] | 0, HEAP32[i9 >> 2] | 0, i39, i40, i17);
michael@0 31858 }
michael@0 31859 i16 = (i40 | 0) == 0 ? i14 : i41;
michael@0 31860 i21 = HEAP32[i9 >> 2] | 0;
michael@0 31861 if ((i21 | 0) < 0) {
michael@0 31862 if ((HEAP32[i10 >> 2] | 0) < 0) {
michael@0 31863 i20 = HEAP32[i11 >> 2] | 0;
michael@0 31864 if ((i20 | 0) != 0) {
michael@0 31865 if ((HEAP8[i12] | 0) != 0) {
michael@0 31866 __Z21btAlignedFreeInternalPv(i20);
michael@0 31867 }
michael@0 31868 HEAP32[i11 >> 2] = 0;
michael@0 31869 }
michael@0 31870 HEAP8[i12] = 1;
michael@0 31871 HEAP32[i11 >> 2] = 0;
michael@0 31872 HEAP32[i10 >> 2] = 0;
michael@0 31873 i43 = i21;
michael@0 31874 } else {
michael@0 31875 i43 = i21;
michael@0 31876 }
michael@0 31877 do {
michael@0 31878 i21 = (HEAP32[i11 >> 2] | 0) + (i43 << 2) | 0;
michael@0 31879 if ((i21 | 0) != 0) {
michael@0 31880 HEAP32[i21 >> 2] = 0;
michael@0 31881 }
michael@0 31882 i43 = i43 + 1 | 0;
michael@0 31883 } while ((i43 | 0) < 0);
michael@0 31884 }
michael@0 31885 HEAP32[i9 >> 2] = 0;
michael@0 31886 if ((i35 | 0) < (i6 | 0)) {
michael@0 31887 i3 = i41;
michael@0 31888 i14 = i16;
michael@0 31889 i15 = i35;
michael@0 31890 } else {
michael@0 31891 break;
michael@0 31892 }
michael@0 31893 }
michael@0 31894 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 31895 STACKTOP = i5;
michael@0 31896 return;
michael@0 31897 }
michael@0 31898 function __ZN20btConvexHullInternal4DMulINS_6Int128EyE3mulES1_S1_RS1_S3_(i1, i2, i3, i4) {
michael@0 31899 i1 = i1 | 0;
michael@0 31900 i2 = i2 | 0;
michael@0 31901 i3 = i3 | 0;
michael@0 31902 i4 = i4 | 0;
michael@0 31903 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0;
michael@0 31904 i5 = STACKTOP;
michael@0 31905 i6 = i1;
michael@0 31906 i1 = STACKTOP;
michael@0 31907 STACKTOP = STACKTOP + 16 | 0;
michael@0 31908 HEAP32[i1 >> 2] = HEAP32[i6 >> 2];
michael@0 31909 HEAP32[i1 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 31910 HEAP32[i1 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 31911 HEAP32[i1 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 31912 i6 = i2;
michael@0 31913 i2 = STACKTOP;
michael@0 31914 STACKTOP = STACKTOP + 16 | 0;
michael@0 31915 HEAP32[i2 >> 2] = HEAP32[i6 >> 2];
michael@0 31916 HEAP32[i2 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 31917 HEAP32[i2 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 31918 HEAP32[i2 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 31919 i6 = i1 | 0;
michael@0 31920 i7 = HEAP32[i6 + 4 >> 2] | 0;
michael@0 31921 i8 = i1 + 8 | 0;
michael@0 31922 i1 = i2 | 0;
michael@0 31923 i9 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 31924 i10 = i2 + 8 | 0;
michael@0 31925 i2 = HEAP32[i6 >> 2] | 0;
michael@0 31926 i6 = i7 & 0;
michael@0 31927 i11 = HEAP32[i1 >> 2] | 0;
michael@0 31928 i1 = i9 & 0;
michael@0 31929 i12 = ___muldi3(i11, i1, i2, i6) | 0;
michael@0 31930 i13 = tempRet0;
michael@0 31931 i14 = i9;
michael@0 31932 i9 = 0;
michael@0 31933 i15 = ___muldi3(i14, i9, i2, i6) | 0;
michael@0 31934 i16 = tempRet0;
michael@0 31935 i17 = i7;
michael@0 31936 i7 = 0;
michael@0 31937 i18 = ___muldi3(i11, i1, i17, i7) | 0;
michael@0 31938 i19 = tempRet0;
michael@0 31939 i20 = ___muldi3(i14, i9, i17, i7) | 0;
michael@0 31940 i21 = tempRet0;
michael@0 31941 i22 = _i64Add(i15 | 0, i16 & 0, i18 | 0, i19 & 0) | 0;
michael@0 31942 i18 = tempRet0;
michael@0 31943 i15 = _i64Add(i16, 0, i20, i21) | 0;
michael@0 31944 i21 = _i64Add(i15, tempRet0, i19, 0) | 0;
michael@0 31945 i19 = tempRet0;
michael@0 31946 i15 = _llvm_uadd_with_overflow_i64(i12 | 0, i13 | 0, 0, i22 | 0) | 0;
michael@0 31947 i22 = i15;
michael@0 31948 i15 = tempRet0;
michael@0 31949 i13 = _i64Add(i21, i19, tempRet1 & 1, 0) | 0;
michael@0 31950 i19 = _i64Add(i13, tempRet0, i18, 0) | 0;
michael@0 31951 i18 = tempRet0;
michael@0 31952 i13 = HEAP32[i10 + 4 >> 2] | 0;
michael@0 31953 i21 = HEAP32[i10 >> 2] | 0;
michael@0 31954 i10 = i13 & 0;
michael@0 31955 i12 = ___muldi3(i21, i10, i2, i6) | 0;
michael@0 31956 i20 = tempRet0;
michael@0 31957 i16 = i13;
michael@0 31958 i13 = 0;
michael@0 31959 i23 = ___muldi3(i16, i13, i2, i6) | 0;
michael@0 31960 i6 = tempRet0;
michael@0 31961 i2 = ___muldi3(i21, i10, i17, i7) | 0;
michael@0 31962 i24 = tempRet0;
michael@0 31963 i25 = ___muldi3(i16, i13, i17, i7) | 0;
michael@0 31964 i7 = tempRet0;
michael@0 31965 i17 = _i64Add(i23 | 0, i6 & 0, i2 | 0, i24 & 0) | 0;
michael@0 31966 i2 = tempRet0;
michael@0 31967 i23 = _i64Add(i6, 0, i25, i7) | 0;
michael@0 31968 i7 = _i64Add(i23, tempRet0, i24, 0) | 0;
michael@0 31969 i24 = tempRet0;
michael@0 31970 i23 = _llvm_uadd_with_overflow_i64(i12 | 0, i20 | 0, 0, i17 | 0) | 0;
michael@0 31971 i17 = tempRet0;
michael@0 31972 i20 = _i64Add(i7, i24, tempRet1 & 1, 0) | 0;
michael@0 31973 i24 = _i64Add(i20, tempRet0, i2, 0) | 0;
michael@0 31974 i2 = tempRet0;
michael@0 31975 i20 = HEAP32[i8 + 4 >> 2] | 0;
michael@0 31976 i7 = HEAP32[i8 >> 2] | 0;
michael@0 31977 i8 = i20 & 0;
michael@0 31978 i12 = ___muldi3(i7, i8, i11, i1) | 0;
michael@0 31979 i25 = tempRet0;
michael@0 31980 i6 = ___muldi3(i7, i8, i14, i9) | 0;
michael@0 31981 i26 = tempRet0;
michael@0 31982 i27 = i20;
michael@0 31983 i20 = 0;
michael@0 31984 i28 = ___muldi3(i27, i20, i11, i1) | 0;
michael@0 31985 i1 = tempRet0;
michael@0 31986 i11 = ___muldi3(i27, i20, i14, i9) | 0;
michael@0 31987 i9 = tempRet0;
michael@0 31988 i14 = _i64Add(i6 | 0, i26 & 0, i28 | 0, i1 & 0) | 0;
michael@0 31989 i28 = tempRet0;
michael@0 31990 i6 = _i64Add(i26, 0, i11, i9) | 0;
michael@0 31991 i9 = _i64Add(i6, tempRet0, i1, 0) | 0;
michael@0 31992 i1 = tempRet0;
michael@0 31993 i6 = _llvm_uadd_with_overflow_i64(i12 | 0, i25 | 0, 0, i14 | 0) | 0;
michael@0 31994 i14 = tempRet0;
michael@0 31995 i25 = _i64Add(i9, i1, tempRet1 & 1, 0) | 0;
michael@0 31996 i1 = _i64Add(i25, tempRet0, i28, 0) | 0;
michael@0 31997 i28 = tempRet0;
michael@0 31998 i25 = ___muldi3(i7, i8, i21, i10) | 0;
michael@0 31999 i9 = tempRet0;
michael@0 32000 i12 = ___muldi3(i7, i8, i16, i13) | 0;
michael@0 32001 i8 = tempRet0;
michael@0 32002 i7 = ___muldi3(i27, i20, i21, i10) | 0;
michael@0 32003 i10 = tempRet0;
michael@0 32004 i21 = ___muldi3(i27, i20, i16, i13) | 0;
michael@0 32005 i13 = tempRet0;
michael@0 32006 i16 = _i64Add(i12 | 0, i8 & 0, i7 | 0, i10 & 0) | 0;
michael@0 32007 i7 = tempRet0;
michael@0 32008 i12 = _i64Add(i8, 0, i21, i13) | 0;
michael@0 32009 i13 = _i64Add(i12, tempRet0, i10, 0) | 0;
michael@0 32010 i10 = tempRet0;
michael@0 32011 i12 = _llvm_uadd_with_overflow_i64(i25 | 0, i9 | 0, 0, i16 | 0) | 0;
michael@0 32012 i16 = tempRet0;
michael@0 32013 i9 = tempRet1 & 1;
michael@0 32014 i25 = _llvm_uadd_with_overflow_i64(i23 | 0, i17 | 0, i6 | 0, i14 | 0) | 0;
michael@0 32015 i14 = tempRet0;
michael@0 32016 i6 = tempRet1 & 1;
michael@0 32017 i17 = _llvm_uadd_with_overflow_i64(i12 | 0, i16 | 0, i24 | 0, i2 | 0) | 0;
michael@0 32018 i2 = tempRet1 & 1;
michael@0 32019 i24 = _llvm_uadd_with_overflow_i64(i17 | 0, tempRet0 | 0, i1 | 0, i28 | 0) | 0;
michael@0 32020 i28 = tempRet1 & 1;
michael@0 32021 i1 = _llvm_uadd_with_overflow_i64(i24 | 0, tempRet0 | 0, i6 | 0, 0) | 0;
michael@0 32022 i6 = i1;
michael@0 32023 i1 = tempRet0;
michael@0 32024 i24 = tempRet1 & 1;
michael@0 32025 i17 = _i64Add(i13, i10, i9, 0) | 0;
michael@0 32026 i9 = _i64Add(i17, tempRet0, i7, 0) | 0;
michael@0 32027 i7 = _i64Add(i9, tempRet0, i2, 0) | 0;
michael@0 32028 i2 = _i64Add(i7, tempRet0, i28, 0) | 0;
michael@0 32029 i28 = _i64Add(i2, tempRet0, i24, 0) | 0;
michael@0 32030 i24 = tempRet0;
michael@0 32031 i2 = _llvm_uadd_with_overflow_i64(i19 | 0, i18 | 0, i25 | 0, i14 | 0) | 0;
michael@0 32032 i14 = i2;
michael@0 32033 i2 = tempRet0;
michael@0 32034 if (!tempRet1) {
michael@0 32035 i29 = i1;
michael@0 32036 i30 = i6;
michael@0 32037 i31 = i24;
michael@0 32038 i32 = i28;
michael@0 32039 i33 = i3 | 0;
michael@0 32040 i34 = i33 | 0;
michael@0 32041 HEAP32[i34 >> 2] = i22;
michael@0 32042 i35 = i33 + 4 | 0;
michael@0 32043 HEAP32[i35 >> 2] = i15;
michael@0 32044 i36 = i3 + 8 | 0;
michael@0 32045 i37 = i36 | 0;
michael@0 32046 HEAP32[i37 >> 2] = i14;
michael@0 32047 i38 = i36 + 4 | 0;
michael@0 32048 HEAP32[i38 >> 2] = i2;
michael@0 32049 i39 = i4 | 0;
michael@0 32050 i40 = i39 | 0;
michael@0 32051 HEAP32[i40 >> 2] = i30;
michael@0 32052 i41 = i39 + 4 | 0;
michael@0 32053 HEAP32[i41 >> 2] = i29;
michael@0 32054 i42 = i4 + 8 | 0;
michael@0 32055 i43 = i42 | 0;
michael@0 32056 HEAP32[i43 >> 2] = i32;
michael@0 32057 i44 = i42 + 4 | 0;
michael@0 32058 HEAP32[i44 >> 2] = i31;
michael@0 32059 STACKTOP = i5;
michael@0 32060 return;
michael@0 32061 }
michael@0 32062 i25 = _i64Add(i6, i1, 1, 0) | 0;
michael@0 32063 i1 = tempRet0;
michael@0 32064 i6 = _i64Add(i28, i24, (i25 | 0) == 0 & (i1 | 0) == 0 & 1, 0) | 0;
michael@0 32065 i29 = i1;
michael@0 32066 i30 = i25;
michael@0 32067 i31 = tempRet0;
michael@0 32068 i32 = i6;
michael@0 32069 i33 = i3 | 0;
michael@0 32070 i34 = i33 | 0;
michael@0 32071 HEAP32[i34 >> 2] = i22;
michael@0 32072 i35 = i33 + 4 | 0;
michael@0 32073 HEAP32[i35 >> 2] = i15;
michael@0 32074 i36 = i3 + 8 | 0;
michael@0 32075 i37 = i36 | 0;
michael@0 32076 HEAP32[i37 >> 2] = i14;
michael@0 32077 i38 = i36 + 4 | 0;
michael@0 32078 HEAP32[i38 >> 2] = i2;
michael@0 32079 i39 = i4 | 0;
michael@0 32080 i40 = i39 | 0;
michael@0 32081 HEAP32[i40 >> 2] = i30;
michael@0 32082 i41 = i39 + 4 | 0;
michael@0 32083 HEAP32[i41 >> 2] = i29;
michael@0 32084 i42 = i4 + 8 | 0;
michael@0 32085 i43 = i42 | 0;
michael@0 32086 HEAP32[i43 >> 2] = i32;
michael@0 32087 i44 = i42 + 4 | 0;
michael@0 32088 HEAP32[i44 >> 2] = i31;
michael@0 32089 STACKTOP = i5;
michael@0 32090 return;
michael@0 32091 }
michael@0 32092 function __ZN22SphereTriangleDetector7collideERK9btVector3RS0_S3_RfS4_f(i1, i2, i3, i4, i5, i6, d7) {
michael@0 32093 i1 = i1 | 0;
michael@0 32094 i2 = i2 | 0;
michael@0 32095 i3 = i3 | 0;
michael@0 32096 i4 = i4 | 0;
michael@0 32097 i5 = i5 | 0;
michael@0 32098 i6 = i6 | 0;
michael@0 32099 d7 = +d7;
michael@0 32100 var i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, i28 = 0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, i33 = 0, i34 = 0, i35 = 0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, i61 = 0, d62 = 0.0, d63 = 0.0, d64 = 0.0, i65 = 0, d66 = 0.0;
michael@0 32101 i6 = STACKTOP;
michael@0 32102 STACKTOP = STACKTOP + 64 | 0;
michael@0 32103 i8 = i6 | 0;
michael@0 32104 i9 = i6 + 16 | 0;
michael@0 32105 i10 = i6 + 32 | 0;
michael@0 32106 i11 = i6 + 48 | 0;
michael@0 32107 i12 = i1 + 8 | 0;
michael@0 32108 i13 = HEAP32[i12 >> 2] | 0;
michael@0 32109 i14 = i13 + 56 | 0;
michael@0 32110 i15 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 32111 d16 = +HEAPF32[i15 + 28 >> 2] * +HEAPF32[i15 + 12 >> 2];
michael@0 32112 d17 = d16 + d7;
michael@0 32113 d7 = +HEAPF32[i14 >> 2];
michael@0 32114 d18 = +HEAPF32[i13 + 72 >> 2] - d7;
michael@0 32115 d19 = +HEAPF32[i13 + 60 >> 2];
michael@0 32116 d20 = +HEAPF32[i13 + 76 >> 2] - d19;
michael@0 32117 d21 = +HEAPF32[i13 + 64 >> 2];
michael@0 32118 d22 = +HEAPF32[i13 + 80 >> 2] - d21;
michael@0 32119 d23 = +HEAPF32[i13 + 88 >> 2] - d7;
michael@0 32120 d24 = +HEAPF32[i13 + 92 >> 2] - d19;
michael@0 32121 d25 = +HEAPF32[i13 + 96 >> 2] - d21;
michael@0 32122 d26 = d20 * d25 - d22 * d24;
michael@0 32123 d27 = d22 * d23 - d18 * d25;
michael@0 32124 d25 = d18 * d24 - d20 * d23;
michael@0 32125 d23 = 1.0 / +Math_sqrt(+(d25 * d25 + (d26 * d26 + d27 * d27)));
michael@0 32126 d20 = d23 * d26;
michael@0 32127 d26 = d23 * d27;
michael@0 32128 d27 = d23 * d25;
michael@0 32129 i15 = i2 | 0;
michael@0 32130 d25 = +HEAPF32[i15 >> 2];
michael@0 32131 i1 = i2 + 4 | 0;
michael@0 32132 d23 = +HEAPF32[i1 >> 2];
michael@0 32133 i28 = i2 + 8 | 0;
michael@0 32134 d24 = +HEAPF32[i28 >> 2];
michael@0 32135 d18 = (d25 - d7) * d20 + d26 * (d23 - d19) + d27 * (d24 - d21);
michael@0 32136 if (d18 < 0.0) {
michael@0 32137 d29 = d18 * -1.0;
michael@0 32138 d30 = d20 * -1.0;
michael@0 32139 d31 = d26 * -1.0;
michael@0 32140 d32 = d27 * -1.0;
michael@0 32141 } else {
michael@0 32142 d29 = d18;
michael@0 32143 d30 = d20;
michael@0 32144 d31 = d26;
michael@0 32145 d32 = d27;
michael@0 32146 }
michael@0 32147 if (d29 >= d17) {
michael@0 32148 i33 = 0;
michael@0 32149 STACKTOP = i6;
michael@0 32150 return i33 | 0;
michael@0 32151 }
michael@0 32152 i34 = i8;
michael@0 32153 i35 = i2;
michael@0 32154 HEAP32[i34 >> 2] = HEAP32[i35 >> 2];
michael@0 32155 HEAP32[i34 + 4 >> 2] = HEAP32[i35 + 4 >> 2];
michael@0 32156 HEAP32[i34 + 8 >> 2] = HEAP32[i35 + 8 >> 2];
michael@0 32157 HEAP32[i34 + 12 >> 2] = HEAP32[i35 + 12 >> 2];
michael@0 32158 HEAPF32[i9 >> 2] = d30;
michael@0 32159 HEAPF32[i9 + 4 >> 2] = d31;
michael@0 32160 HEAPF32[i9 + 8 >> 2] = d32;
michael@0 32161 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 32162 do {
michael@0 32163 if (__ZN22SphereTriangleDetector15pointInTriangleEPK9btVector3RS1_PS0_(0, i14, i9, i8) | 0) {
michael@0 32164 d36 = d25 - d30 * d29;
michael@0 32165 d37 = d23 - d31 * d29;
michael@0 32166 d38 = d24 - d32 * d29;
michael@0 32167 d39 = d25;
michael@0 32168 d40 = d23;
michael@0 32169 d41 = d24;
michael@0 32170 d42 = d17 * d17;
michael@0 32171 } else {
michael@0 32172 d27 = d17 * d17;
michael@0 32173 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i13 >> 2] | 0) + 92 >> 2] & 127](i13) | 0) <= 0) {
michael@0 32174 i33 = 0;
michael@0 32175 STACKTOP = i6;
michael@0 32176 return i33 | 0;
michael@0 32177 }
michael@0 32178 i35 = i10 | 0;
michael@0 32179 i34 = i10 + 4 | 0;
michael@0 32180 i2 = i10 + 8 | 0;
michael@0 32181 i43 = i11 | 0;
michael@0 32182 i44 = i11 + 4 | 0;
michael@0 32183 i45 = i11 + 8 | 0;
michael@0 32184 d26 = 0.0;
michael@0 32185 d20 = 0.0;
michael@0 32186 d18 = 0.0;
michael@0 32187 i46 = 0;
michael@0 32188 i47 = 0;
michael@0 32189 while (1) {
michael@0 32190 i48 = HEAP32[i12 >> 2] | 0;
michael@0 32191 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i48 >> 2] | 0) + 96 >> 2] & 127](i48, i46, i10, i11);
michael@0 32192 d21 = +HEAPF32[i35 >> 2];
michael@0 32193 d19 = +HEAPF32[i15 >> 2] - d21;
michael@0 32194 d7 = +HEAPF32[i34 >> 2];
michael@0 32195 d22 = +HEAPF32[i1 >> 2] - d7;
michael@0 32196 d49 = +HEAPF32[i2 >> 2];
michael@0 32197 d50 = +HEAPF32[i28 >> 2] - d49;
michael@0 32198 d51 = +HEAPF32[i43 >> 2] - d21;
michael@0 32199 d52 = +HEAPF32[i44 >> 2] - d7;
michael@0 32200 d53 = +HEAPF32[i45 >> 2] - d49;
michael@0 32201 d54 = d19 * d51 + d22 * d52 + d50 * d53;
michael@0 32202 do {
michael@0 32203 if (d54 > 0.0) {
michael@0 32204 d55 = d51 * d51 + d52 * d52 + d53 * d53;
michael@0 32205 if (d54 < d55) {
michael@0 32206 d56 = d54 / d55;
michael@0 32207 d57 = d56;
michael@0 32208 d58 = d19 - d51 * d56;
michael@0 32209 d59 = d22 - d52 * d56;
michael@0 32210 d60 = d50 - d53 * d56;
michael@0 32211 break;
michael@0 32212 } else {
michael@0 32213 d57 = 1.0;
michael@0 32214 d58 = d19 - d51;
michael@0 32215 d59 = d22 - d52;
michael@0 32216 d60 = d50 - d53;
michael@0 32217 break;
michael@0 32218 }
michael@0 32219 } else {
michael@0 32220 d57 = 0.0;
michael@0 32221 d58 = d19;
michael@0 32222 d59 = d22;
michael@0 32223 d60 = d50;
michael@0 32224 }
michael@0 32225 } while (0);
michael@0 32226 if (d60 * d60 + (d59 * d59 + d58 * d58) < d27) {
michael@0 32227 i61 = 1;
michael@0 32228 d62 = d21 + d51 * d57;
michael@0 32229 d63 = d7 + d52 * d57;
michael@0 32230 d64 = d49 + d53 * d57;
michael@0 32231 } else {
michael@0 32232 i61 = i47;
michael@0 32233 d62 = d18;
michael@0 32234 d63 = d20;
michael@0 32235 d64 = d26;
michael@0 32236 }
michael@0 32237 i48 = i46 + 1 | 0;
michael@0 32238 i65 = HEAP32[i12 >> 2] | 0;
michael@0 32239 if ((i48 | 0) < (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i65 >> 2] | 0) + 92 >> 2] & 127](i65) | 0)) {
michael@0 32240 d26 = d64;
michael@0 32241 d20 = d63;
michael@0 32242 d18 = d62;
michael@0 32243 i46 = i48;
michael@0 32244 i47 = i61;
michael@0 32245 } else {
michael@0 32246 break;
michael@0 32247 }
michael@0 32248 }
michael@0 32249 if ((i61 & 1) == 0) {
michael@0 32250 i33 = 0;
michael@0 32251 STACKTOP = i6;
michael@0 32252 return i33 | 0;
michael@0 32253 } else {
michael@0 32254 d36 = d62;
michael@0 32255 d37 = d63;
michael@0 32256 d38 = d64;
michael@0 32257 d39 = +HEAPF32[i15 >> 2];
michael@0 32258 d40 = +HEAPF32[i1 >> 2];
michael@0 32259 d41 = +HEAPF32[i28 >> 2];
michael@0 32260 d42 = d27;
michael@0 32261 break;
michael@0 32262 }
michael@0 32263 }
michael@0 32264 } while (0);
michael@0 32265 d64 = d39 - d36;
michael@0 32266 d39 = d40 - d37;
michael@0 32267 d40 = d41 - d38;
michael@0 32268 d41 = d40 * d40 + (d39 * d39 + d64 * d64);
michael@0 32269 if (d41 >= d42) {
michael@0 32270 i33 = 0;
michael@0 32271 STACKTOP = i6;
michael@0 32272 return i33 | 0;
michael@0 32273 }
michael@0 32274 if (d41 > 1.1920928955078125e-7) {
michael@0 32275 d42 = +Math_sqrt(+d41);
michael@0 32276 HEAPF32[i4 + 12 >> 2] = 0.0;
michael@0 32277 d41 = 1.0 / d42;
michael@0 32278 HEAPF32[i4 >> 2] = d64 * d41;
michael@0 32279 HEAPF32[i4 + 4 >> 2] = d39 * d41;
michael@0 32280 HEAPF32[i4 + 8 >> 2] = d40 * d41;
michael@0 32281 HEAPF32[i3 >> 2] = d36;
michael@0 32282 HEAPF32[i3 + 4 >> 2] = d37;
michael@0 32283 HEAPF32[i3 + 8 >> 2] = d38;
michael@0 32284 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 32285 d66 = d16 - d42;
michael@0 32286 } else {
michael@0 32287 HEAPF32[i4 >> 2] = d30;
michael@0 32288 HEAPF32[i4 + 4 >> 2] = d31;
michael@0 32289 HEAPF32[i4 + 8 >> 2] = d32;
michael@0 32290 HEAPF32[i4 + 12 >> 2] = 0.0;
michael@0 32291 HEAPF32[i3 >> 2] = d36;
michael@0 32292 HEAPF32[i3 + 4 >> 2] = d37;
michael@0 32293 HEAPF32[i3 + 8 >> 2] = d38;
michael@0 32294 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 32295 d66 = d16;
michael@0 32296 }
michael@0 32297 HEAPF32[i5 >> 2] = -0.0 - d66;
michael@0 32298 i33 = 1;
michael@0 32299 STACKTOP = i6;
michael@0 32300 return i33 | 0;
michael@0 32301 }
michael@0 32302 function __ZN20btPersistentManifold16sortCachedPointsERK15btManifoldPoint(i1, i2) {
michael@0 32303 i1 = i1 | 0;
michael@0 32304 i2 = i2 | 0;
michael@0 32305 var d3 = 0.0, d4 = 0.0, i5 = 0, d6 = 0.0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, i23 = 0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, d45 = 0.0, d46 = 0.0, d47 = 0.0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, d61 = 0.0, d62 = 0.0, d63 = 0.0, d64 = 0.0, d65 = 0.0, d66 = 0.0, d67 = 0.0, d68 = 0.0, d69 = 0.0, d70 = 0.0, d71 = 0.0, d72 = 0.0, d73 = 0.0, d74 = 0.0, d75 = 0.0, d76 = 0.0, d77 = 0.0, d78 = 0.0, i79 = 0, i80 = 0, i81 = 0, d82 = 0.0, i83 = 0, i84 = 0, d85 = 0.0, i86 = 0, i87 = 0, d88 = 0.0, i89 = 0, i90 = 0;
michael@0 32306 d3 = +HEAPF32[i2 + 80 >> 2];
michael@0 32307 d4 = +HEAPF32[i1 + 84 >> 2];
michael@0 32308 i5 = d4 < d3;
michael@0 32309 d6 = i5 ? d4 : d3;
michael@0 32310 d3 = +HEAPF32[i1 + 360 >> 2];
michael@0 32311 i7 = d3 < d6;
michael@0 32312 d4 = i7 ? d3 : d6;
michael@0 32313 d6 = +HEAPF32[i1 + 636 >> 2];
michael@0 32314 i8 = d6 < d4;
michael@0 32315 i9 = +HEAPF32[i1 + 912 >> 2] < (i8 ? d6 : d4);
michael@0 32316 i10 = i9 ? 3 : i8 ? 2 : i7 ? 1 : (i5 ^ 1) << 31 >> 31;
michael@0 32317 d4 = +HEAPF32[i2 >> 2];
michael@0 32318 do {
michael@0 32319 if ((i10 | 0) == 0) {
michael@0 32320 d11 = 0.0;
michael@0 32321 d12 = +HEAPF32[i2 + 4 >> 2];
michael@0 32322 d13 = +HEAPF32[i2 + 8 >> 2];
michael@0 32323 d14 = +HEAPF32[i1 + 832 >> 2];
michael@0 32324 d15 = +HEAPF32[i1 + 556 >> 2];
michael@0 32325 d16 = +HEAPF32[i1 + 836 >> 2];
michael@0 32326 d17 = +HEAPF32[i1 + 560 >> 2];
michael@0 32327 d18 = +HEAPF32[i1 + 840 >> 2];
michael@0 32328 d19 = +HEAPF32[i1 + 564 >> 2];
michael@0 32329 d20 = +HEAPF32[i1 + 280 >> 2];
michael@0 32330 d21 = +HEAPF32[i1 + 284 >> 2];
michael@0 32331 d22 = +HEAPF32[i1 + 288 >> 2];
michael@0 32332 i23 = 1719;
michael@0 32333 } else {
michael@0 32334 d6 = +HEAPF32[i1 + 280 >> 2];
michael@0 32335 d3 = d4 - d6;
michael@0 32336 d24 = +HEAPF32[i2 + 4 >> 2];
michael@0 32337 d25 = +HEAPF32[i1 + 284 >> 2];
michael@0 32338 d26 = d24 - d25;
michael@0 32339 d27 = +HEAPF32[i2 + 8 >> 2];
michael@0 32340 d28 = +HEAPF32[i1 + 288 >> 2];
michael@0 32341 d29 = d27 - d28;
michael@0 32342 d30 = +HEAPF32[i1 + 832 >> 2];
michael@0 32343 d31 = +HEAPF32[i1 + 556 >> 2];
michael@0 32344 d32 = d30 - d31;
michael@0 32345 d33 = +HEAPF32[i1 + 836 >> 2];
michael@0 32346 d34 = +HEAPF32[i1 + 560 >> 2];
michael@0 32347 d35 = d33 - d34;
michael@0 32348 d36 = +HEAPF32[i1 + 840 >> 2];
michael@0 32349 d37 = +HEAPF32[i1 + 564 >> 2];
michael@0 32350 d38 = d36 - d37;
michael@0 32351 d39 = d26 * d38 - d29 * d35;
michael@0 32352 d40 = d29 * d32 - d3 * d38;
michael@0 32353 d38 = d3 * d35 - d26 * d32;
michael@0 32354 d32 = d38 * d38 + (d39 * d39 + d40 * d40);
michael@0 32355 if ((i10 | 0) != 1) {
michael@0 32356 d11 = d32;
michael@0 32357 d12 = d24;
michael@0 32358 d13 = d27;
michael@0 32359 d14 = d30;
michael@0 32360 d15 = d31;
michael@0 32361 d16 = d33;
michael@0 32362 d17 = d34;
michael@0 32363 d18 = d36;
michael@0 32364 d19 = d37;
michael@0 32365 d20 = d6;
michael@0 32366 d21 = d25;
michael@0 32367 d22 = d28;
michael@0 32368 i23 = 1719;
michael@0 32369 break;
michael@0 32370 }
michael@0 32371 d41 = 0.0;
michael@0 32372 d42 = d32;
michael@0 32373 d43 = d31;
michael@0 32374 d44 = d34;
michael@0 32375 d45 = d37;
michael@0 32376 d46 = d24;
michael@0 32377 d47 = d27;
michael@0 32378 d48 = d30;
michael@0 32379 d49 = d33;
michael@0 32380 d50 = d36;
michael@0 32381 d51 = +HEAPF32[i1 + 4 >> 2];
michael@0 32382 d52 = +HEAPF32[i1 + 8 >> 2];
michael@0 32383 d53 = +HEAPF32[i1 + 12 >> 2];
michael@0 32384 d54 = d6;
michael@0 32385 d55 = d25;
michael@0 32386 d56 = d28;
michael@0 32387 i23 = 1720;
michael@0 32388 }
michael@0 32389 } while (0);
michael@0 32390 if ((i23 | 0) == 1719) {
michael@0 32391 d28 = +HEAPF32[i1 + 4 >> 2];
michael@0 32392 d25 = d4 - d28;
michael@0 32393 d6 = +HEAPF32[i1 + 8 >> 2];
michael@0 32394 d36 = d12 - d6;
michael@0 32395 d33 = +HEAPF32[i1 + 12 >> 2];
michael@0 32396 d30 = d13 - d33;
michael@0 32397 d27 = d14 - d15;
michael@0 32398 d24 = d16 - d17;
michael@0 32399 d37 = d18 - d19;
michael@0 32400 d34 = d37 * d36 - d24 * d30;
michael@0 32401 d31 = d27 * d30 - d37 * d25;
michael@0 32402 d37 = d24 * d25 - d27 * d36;
michael@0 32403 d36 = d37 * d37 + (d34 * d34 + d31 * d31);
michael@0 32404 if ((i10 | 0) == 2) {
michael@0 32405 d57 = 0.0;
michael@0 32406 d58 = d36;
michael@0 32407 d59 = d11;
michael@0 32408 d60 = d28;
michael@0 32409 d61 = d12;
michael@0 32410 d62 = d6;
michael@0 32411 d63 = d13;
michael@0 32412 d64 = d33;
michael@0 32413 d65 = d15;
michael@0 32414 d66 = d17;
michael@0 32415 d67 = d19;
michael@0 32416 d68 = d20;
michael@0 32417 d69 = d21;
michael@0 32418 d70 = d22;
michael@0 32419 } else {
michael@0 32420 d41 = d36;
michael@0 32421 d42 = d11;
michael@0 32422 d43 = d15;
michael@0 32423 d44 = d17;
michael@0 32424 d45 = d19;
michael@0 32425 d46 = d12;
michael@0 32426 d47 = d13;
michael@0 32427 d48 = d14;
michael@0 32428 d49 = d16;
michael@0 32429 d50 = d18;
michael@0 32430 d51 = d28;
michael@0 32431 d52 = d6;
michael@0 32432 d53 = d33;
michael@0 32433 d54 = d20;
michael@0 32434 d55 = d21;
michael@0 32435 d56 = d22;
michael@0 32436 i23 = 1720;
michael@0 32437 }
michael@0 32438 }
michael@0 32439 do {
michael@0 32440 if ((i23 | 0) == 1720) {
michael@0 32441 d22 = d4 - d51;
michael@0 32442 d21 = d46 - d52;
michael@0 32443 d20 = d47 - d53;
michael@0 32444 d33 = d48 - d54;
michael@0 32445 d6 = d49 - d55;
michael@0 32446 d28 = d50 - d56;
michael@0 32447 d18 = d28 * d21 - d6 * d20;
michael@0 32448 d16 = d33 * d20 - d22 * d28;
michael@0 32449 d28 = d22 * d6 - d33 * d21;
michael@0 32450 d21 = d28 * d28 + (d16 * d16 + d18 * d18);
michael@0 32451 if (i9) {
michael@0 32452 d71 = 0.0;
michael@0 32453 d72 = d21;
michael@0 32454 d73 = d41;
michael@0 32455 d74 = d42;
michael@0 32456 } else {
michael@0 32457 d57 = d21;
michael@0 32458 d58 = d41;
michael@0 32459 d59 = d42;
michael@0 32460 d60 = d51;
michael@0 32461 d61 = d46;
michael@0 32462 d62 = d52;
michael@0 32463 d63 = d47;
michael@0 32464 d64 = d53;
michael@0 32465 d65 = d43;
michael@0 32466 d66 = d44;
michael@0 32467 d67 = d45;
michael@0 32468 d68 = d54;
michael@0 32469 d69 = d55;
michael@0 32470 d70 = d56;
michael@0 32471 break;
michael@0 32472 }
michael@0 32473 d75 = +Math_abs(+d74);
michael@0 32474 d76 = +Math_abs(+d73);
michael@0 32475 d77 = +Math_abs(+d72);
michael@0 32476 d78 = +Math_abs(+d71);
michael@0 32477 i79 = d75 > -999999984306749400.0;
michael@0 32478 i80 = i79 ^ 1;
michael@0 32479 i81 = i80 << 31 >> 31;
michael@0 32480 d82 = i79 ? d75 : -999999984306749400.0;
michael@0 32481 i83 = d76 > d82;
michael@0 32482 i84 = i83 ? 1 : i81;
michael@0 32483 d85 = i83 ? d76 : d82;
michael@0 32484 i86 = d77 > d85;
michael@0 32485 i87 = i86 ? 2 : i84;
michael@0 32486 d88 = i86 ? d77 : d85;
michael@0 32487 i89 = d78 > d88;
michael@0 32488 i90 = i89 ? 3 : i87;
michael@0 32489 return i90 | 0;
michael@0 32490 }
michael@0 32491 } while (0);
michael@0 32492 d56 = d4 - d60;
michael@0 32493 d60 = d61 - d62;
michael@0 32494 d62 = d63 - d64;
michael@0 32495 d64 = d65 - d68;
michael@0 32496 d68 = d66 - d69;
michael@0 32497 d69 = d67 - d70;
michael@0 32498 d70 = d69 * d60 - d68 * d62;
michael@0 32499 d67 = d64 * d62 - d69 * d56;
michael@0 32500 d69 = d68 * d56 - d64 * d60;
michael@0 32501 d71 = d69 * d69 + (d70 * d70 + d67 * d67);
michael@0 32502 d72 = d57;
michael@0 32503 d73 = d58;
michael@0 32504 d74 = d59;
michael@0 32505 d75 = +Math_abs(+d74);
michael@0 32506 d76 = +Math_abs(+d73);
michael@0 32507 d77 = +Math_abs(+d72);
michael@0 32508 d78 = +Math_abs(+d71);
michael@0 32509 i79 = d75 > -999999984306749400.0;
michael@0 32510 i80 = i79 ^ 1;
michael@0 32511 i81 = i80 << 31 >> 31;
michael@0 32512 d82 = i79 ? d75 : -999999984306749400.0;
michael@0 32513 i83 = d76 > d82;
michael@0 32514 i84 = i83 ? 1 : i81;
michael@0 32515 d85 = i83 ? d76 : d82;
michael@0 32516 i86 = d77 > d85;
michael@0 32517 i87 = i86 ? 2 : i84;
michael@0 32518 d88 = i86 ? d77 : d85;
michael@0 32519 i89 = d78 > d88;
michael@0 32520 i90 = i89 ? 3 : i87;
michael@0 32521 return i90 | 0;
michael@0 32522 }
michael@0 32523 function __ZN27btPolyhedralContactClipping19clipHullAgainstHullERK9btVector3RK18btConvexPolyhedronS5_RK11btTransformS8_ffRN36btDiscreteCollisionDetectorInterface6ResultE(i1, i2, i3, i4, i5, d6, d7, i8) {
michael@0 32524 i1 = i1 | 0;
michael@0 32525 i2 = i2 | 0;
michael@0 32526 i3 = i3 | 0;
michael@0 32527 i4 = i4 | 0;
michael@0 32528 i5 = i5 | 0;
michael@0 32529 d6 = +d6;
michael@0 32530 d7 = +d7;
michael@0 32531 i8 = i8 | 0;
michael@0 32532 var i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, i15 = 0, d16 = 0.0, i17 = 0, d18 = 0.0, i19 = 0, d20 = 0.0, i21 = 0, d22 = 0.0, i23 = 0, d24 = 0.0, i25 = 0, d26 = 0.0, i27 = 0, d28 = 0.0, i29 = 0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, i34 = 0, d35 = 0.0, i36 = 0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, d52 = 0.0, i53 = 0, i54 = 0, i55 = 0, d56 = 0.0, d57 = 0.0, d58 = 0.0, d59 = 0.0, d60 = 0.0, d61 = 0.0, i62 = 0, i63 = 0, i64 = 0, i65 = 0, i66 = 0, i67 = 0;
michael@0 32533 i9 = STACKTOP;
michael@0 32534 STACKTOP = STACKTOP + 24 | 0;
michael@0 32535 i10 = i9 | 0;
michael@0 32536 i11 = HEAP32[i3 + 28 >> 2] | 0;
michael@0 32537 if ((i11 | 0) <= 0) {
michael@0 32538 STACKTOP = i9;
michael@0 32539 return;
michael@0 32540 }
michael@0 32541 i12 = HEAP32[i3 + 36 >> 2] | 0;
michael@0 32542 i13 = i5 | 0;
michael@0 32543 d14 = +HEAPF32[i13 >> 2];
michael@0 32544 i15 = i5 + 4 | 0;
michael@0 32545 d16 = +HEAPF32[i15 >> 2];
michael@0 32546 i17 = i5 + 8 | 0;
michael@0 32547 d18 = +HEAPF32[i17 >> 2];
michael@0 32548 i19 = i5 + 16 | 0;
michael@0 32549 d20 = +HEAPF32[i19 >> 2];
michael@0 32550 i21 = i5 + 20 | 0;
michael@0 32551 d22 = +HEAPF32[i21 >> 2];
michael@0 32552 i23 = i5 + 24 | 0;
michael@0 32553 d24 = +HEAPF32[i23 >> 2];
michael@0 32554 i25 = i5 + 32 | 0;
michael@0 32555 d26 = +HEAPF32[i25 >> 2];
michael@0 32556 i27 = i5 + 36 | 0;
michael@0 32557 d28 = +HEAPF32[i27 >> 2];
michael@0 32558 i29 = i5 + 40 | 0;
michael@0 32559 d30 = +HEAPF32[i29 >> 2];
michael@0 32560 d31 = +HEAPF32[i1 >> 2];
michael@0 32561 d32 = +HEAPF32[i1 + 4 >> 2];
michael@0 32562 d33 = +HEAPF32[i1 + 8 >> 2];
michael@0 32563 i34 = 0;
michael@0 32564 d35 = -3.4028234663852886e+38;
michael@0 32565 i36 = -1;
michael@0 32566 while (1) {
michael@0 32567 d37 = +HEAPF32[i12 + (i34 * 56 | 0) + 40 >> 2];
michael@0 32568 d38 = +HEAPF32[i12 + (i34 * 56 | 0) + 44 >> 2];
michael@0 32569 d39 = +HEAPF32[i12 + (i34 * 56 | 0) + 48 >> 2];
michael@0 32570 d40 = d33 * (d26 * d37 + d28 * d38 + d30 * d39) + (d31 * (d14 * d37 + d16 * d38 + d18 * d39) + d32 * (d20 * d37 + d22 * d38 + d24 * d39));
michael@0 32571 i41 = d40 > d35;
michael@0 32572 i42 = i41 ? i34 : i36;
michael@0 32573 i43 = i34 + 1 | 0;
michael@0 32574 if ((i43 | 0) < (i11 | 0)) {
michael@0 32575 i34 = i43;
michael@0 32576 d35 = i41 ? d40 : d35;
michael@0 32577 i36 = i42;
michael@0 32578 } else {
michael@0 32579 break;
michael@0 32580 }
michael@0 32581 }
michael@0 32582 if ((i42 | 0) < 0) {
michael@0 32583 STACKTOP = i9;
michael@0 32584 return;
michael@0 32585 }
michael@0 32586 i36 = i10 + 16 | 0;
michael@0 32587 HEAP8[i36] = 1;
michael@0 32588 i34 = i10 + 12 | 0;
michael@0 32589 HEAP32[i34 >> 2] = 0;
michael@0 32590 i11 = i10 + 4 | 0;
michael@0 32591 HEAP32[i11 >> 2] = 0;
michael@0 32592 i41 = i10 + 8 | 0;
michael@0 32593 HEAP32[i41 >> 2] = 0;
michael@0 32594 i43 = HEAP32[i12 + (i42 * 56 | 0) + 4 >> 2] | 0;
michael@0 32595 L553 : do {
michael@0 32596 if ((i43 | 0) > 0) {
michael@0 32597 i44 = i12 + (i42 * 56 | 0) + 12 | 0;
michael@0 32598 i45 = i3 + 16 | 0;
michael@0 32599 i46 = i5 + 48 | 0;
michael@0 32600 i47 = i5 + 52 | 0;
michael@0 32601 i48 = i5 + 56 | 0;
michael@0 32602 i49 = 0;
michael@0 32603 i50 = 0;
michael@0 32604 i51 = 0;
michael@0 32605 d35 = d14;
michael@0 32606 d32 = d16;
michael@0 32607 d31 = d18;
michael@0 32608 d33 = d20;
michael@0 32609 d40 = d22;
michael@0 32610 d39 = d24;
michael@0 32611 d38 = d26;
michael@0 32612 d37 = d28;
michael@0 32613 d52 = d30;
michael@0 32614 i53 = 0;
michael@0 32615 while (1) {
michael@0 32616 i54 = HEAP32[(HEAP32[i44 >> 2] | 0) + (i49 << 2) >> 2] | 0;
michael@0 32617 i55 = HEAP32[i45 >> 2] | 0;
michael@0 32618 d56 = +HEAPF32[i55 + (i54 << 4) >> 2];
michael@0 32619 d57 = +HEAPF32[i55 + (i54 << 4) + 4 >> 2];
michael@0 32620 d58 = +HEAPF32[i55 + (i54 << 4) + 8 >> 2];
michael@0 32621 d59 = +HEAPF32[i46 >> 2] + (d35 * d56 + d32 * d57 + d31 * d58);
michael@0 32622 d60 = +HEAPF32[i47 >> 2] + (d56 * d33 + d57 * d40 + d58 * d39);
michael@0 32623 d61 = +HEAPF32[i48 >> 2] + (d56 * d38 + d57 * d37 + d58 * d52);
michael@0 32624 do {
michael@0 32625 if ((i50 | 0) == (i51 | 0)) {
michael@0 32626 i54 = (i51 | 0) == 0 ? 1 : i51 << 1;
michael@0 32627 if ((i51 | 0) >= (i54 | 0)) {
michael@0 32628 i62 = i51;
michael@0 32629 i63 = i53;
michael@0 32630 break;
michael@0 32631 }
michael@0 32632 if ((i54 | 0) == 0) {
michael@0 32633 i64 = 0;
michael@0 32634 } else {
michael@0 32635 i64 = __Z22btAlignedAllocInternalji(i54 << 4, 16) | 0;
michael@0 32636 }
michael@0 32637 if ((i51 | 0) > 0) {
michael@0 32638 i55 = 0;
michael@0 32639 do {
michael@0 32640 i65 = i64 + (i55 << 4) | 0;
michael@0 32641 if ((i65 | 0) != 0) {
michael@0 32642 i66 = i65;
michael@0 32643 i65 = i53 + (i55 << 4) | 0;
michael@0 32644 HEAP32[i66 >> 2] = HEAP32[i65 >> 2];
michael@0 32645 HEAP32[i66 + 4 >> 2] = HEAP32[i65 + 4 >> 2];
michael@0 32646 HEAP32[i66 + 8 >> 2] = HEAP32[i65 + 8 >> 2];
michael@0 32647 HEAP32[i66 + 12 >> 2] = HEAP32[i65 + 12 >> 2];
michael@0 32648 }
michael@0 32649 i55 = i55 + 1 | 0;
michael@0 32650 } while ((i55 | 0) < (i51 | 0));
michael@0 32651 }
michael@0 32652 if ((i53 | 0) != 0) {
michael@0 32653 __Z21btAlignedFreeInternalPv(i53);
michael@0 32654 HEAP32[i34 >> 2] = 0;
michael@0 32655 }
michael@0 32656 HEAP8[i36] = 1;
michael@0 32657 HEAP32[i34 >> 2] = i64;
michael@0 32658 HEAP32[i41 >> 2] = i54;
michael@0 32659 i62 = i51;
michael@0 32660 i63 = i64;
michael@0 32661 } else {
michael@0 32662 i62 = i50;
michael@0 32663 i63 = i53;
michael@0 32664 }
michael@0 32665 } while (0);
michael@0 32666 i55 = i63 + (i62 << 4) | 0;
michael@0 32667 if ((i55 | 0) == 0) {
michael@0 32668 i67 = i62;
michael@0 32669 } else {
michael@0 32670 HEAPF32[i55 >> 2] = d59;
michael@0 32671 HEAPF32[i63 + (i62 << 4) + 4 >> 2] = d60;
michael@0 32672 HEAPF32[i63 + (i62 << 4) + 8 >> 2] = d61;
michael@0 32673 HEAPF32[i63 + (i62 << 4) + 12 >> 2] = 0.0;
michael@0 32674 i67 = HEAP32[i11 >> 2] | 0;
michael@0 32675 }
michael@0 32676 i55 = i67 + 1 | 0;
michael@0 32677 HEAP32[i11 >> 2] = i55;
michael@0 32678 i65 = i49 + 1 | 0;
michael@0 32679 if ((i65 | 0) >= (i43 | 0)) {
michael@0 32680 break L553;
michael@0 32681 }
michael@0 32682 i49 = i65;
michael@0 32683 i50 = i55;
michael@0 32684 i51 = HEAP32[i41 >> 2] | 0;
michael@0 32685 d35 = +HEAPF32[i13 >> 2];
michael@0 32686 d32 = +HEAPF32[i15 >> 2];
michael@0 32687 d31 = +HEAPF32[i17 >> 2];
michael@0 32688 d33 = +HEAPF32[i19 >> 2];
michael@0 32689 d40 = +HEAPF32[i21 >> 2];
michael@0 32690 d39 = +HEAPF32[i23 >> 2];
michael@0 32691 d38 = +HEAPF32[i25 >> 2];
michael@0 32692 d37 = +HEAPF32[i27 >> 2];
michael@0 32693 d52 = +HEAPF32[i29 >> 2];
michael@0 32694 i53 = i63;
michael@0 32695 }
michael@0 32696 }
michael@0 32697 } while (0);
michael@0 32698 __ZN27btPolyhedralContactClipping19clipFaceAgainstHullERK9btVector3RK18btConvexPolyhedronRK11btTransformR20btAlignedObjectArrayIS0_EffRN36btDiscreteCollisionDetectorInterface6ResultE(i1, i2, i4, i10, d6, d7, i8);
michael@0 32699 i8 = HEAP32[i34 >> 2] | 0;
michael@0 32700 if ((i8 | 0) != 0) {
michael@0 32701 if ((HEAP8[i36] | 0) != 0) {
michael@0 32702 __Z21btAlignedFreeInternalPv(i8);
michael@0 32703 }
michael@0 32704 HEAP32[i34 >> 2] = 0;
michael@0 32705 }
michael@0 32706 HEAP8[i36] = 1;
michael@0 32707 HEAP32[i34 >> 2] = 0;
michael@0 32708 HEAP32[i11 >> 2] = 0;
michael@0 32709 HEAP32[i41 >> 2] = 0;
michael@0 32710 STACKTOP = i9;
michael@0 32711 return;
michael@0 32712 }
michael@0 32713 function __ZNK6btDbvt15rayTestInternalEPK10btDbvtNodeRK9btVector3S5_S5_PjfS5_S5_RNS_8ICollideE(i1, i2, i3, i4, i5, i6, d7, i8, i9, i10) {
michael@0 32714 i1 = i1 | 0;
michael@0 32715 i2 = i2 | 0;
michael@0 32716 i3 = i3 | 0;
michael@0 32717 i4 = i4 | 0;
michael@0 32718 i5 = i5 | 0;
michael@0 32719 i6 = i6 | 0;
michael@0 32720 d7 = +d7;
michael@0 32721 i8 = i8 | 0;
michael@0 32722 i9 = i9 | 0;
michael@0 32723 i10 = i10 | 0;
michael@0 32724 var i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, d36 = 0.0, d37 = 0.0, i38 = 0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, i52 = 0, i53 = 0, i54 = 0, i55 = 0, i56 = 0, i57 = 0, i58 = 0, i59 = 0, i60 = 0, i61 = 0, i62 = 0, i63 = 0;
michael@0 32725 i4 = STACKTOP;
michael@0 32726 STACKTOP = STACKTOP + 32 | 0;
michael@0 32727 i1 = i4 | 0;
michael@0 32728 if ((i2 | 0) == 0) {
michael@0 32729 STACKTOP = i4;
michael@0 32730 return;
michael@0 32731 }
michael@0 32732 i11 = __Z22btAlignedAllocInternalji(512, 16) | 0;
michael@0 32733 i12 = 0;
michael@0 32734 do {
michael@0 32735 i13 = i11 + (i12 << 2) | 0;
michael@0 32736 if ((i13 | 0) != 0) {
michael@0 32737 HEAP32[i13 >> 2] = 0;
michael@0 32738 }
michael@0 32739 i12 = i12 + 1 | 0;
michael@0 32740 } while ((i12 | 0) < 128);
michael@0 32741 HEAP32[i11 >> 2] = i2;
michael@0 32742 i2 = i9 | 0;
michael@0 32743 i12 = i9 + 4 | 0;
michael@0 32744 i13 = i9 + 8 | 0;
michael@0 32745 i9 = i1 | 0;
michael@0 32746 i14 = i1 + 4 | 0;
michael@0 32747 i15 = i1 + 8 | 0;
michael@0 32748 i16 = i1 + 12 | 0;
michael@0 32749 i17 = i8 | 0;
michael@0 32750 i18 = i8 + 4 | 0;
michael@0 32751 i19 = i8 + 8 | 0;
michael@0 32752 i8 = i1 + 16 | 0;
michael@0 32753 i20 = i1 + 20 | 0;
michael@0 32754 i21 = i1 + 24 | 0;
michael@0 32755 i22 = i1 + 28 | 0;
michael@0 32756 i23 = i3 | 0;
michael@0 32757 i24 = i5 | 0;
michael@0 32758 i25 = i6 + 4 | 0;
michael@0 32759 i26 = i3 + 4 | 0;
michael@0 32760 i27 = i5 + 4 | 0;
michael@0 32761 i28 = i6 + 8 | 0;
michael@0 32762 i29 = i3 + 8 | 0;
michael@0 32763 i3 = i5 + 8 | 0;
michael@0 32764 i5 = i10;
michael@0 32765 i30 = 1;
michael@0 32766 i31 = 126;
michael@0 32767 i32 = 128;
michael@0 32768 i33 = 128;
michael@0 32769 i34 = i11;
michael@0 32770 while (1) {
michael@0 32771 i11 = i30 - 1 | 0;
michael@0 32772 i35 = HEAP32[i34 + (i11 << 2) >> 2] | 0;
michael@0 32773 d36 = +HEAPF32[i35 + 4 >> 2] - +HEAPF32[i12 >> 2];
michael@0 32774 d37 = +HEAPF32[i35 + 8 >> 2] - +HEAPF32[i13 >> 2];
michael@0 32775 HEAPF32[i9 >> 2] = +HEAPF32[i35 >> 2] - +HEAPF32[i2 >> 2];
michael@0 32776 HEAPF32[i14 >> 2] = d36;
michael@0 32777 HEAPF32[i15 >> 2] = d37;
michael@0 32778 HEAPF32[i16 >> 2] = 0.0;
michael@0 32779 d37 = +HEAPF32[i35 + 20 >> 2] - +HEAPF32[i18 >> 2];
michael@0 32780 d36 = +HEAPF32[i35 + 24 >> 2] - +HEAPF32[i19 >> 2];
michael@0 32781 HEAPF32[i8 >> 2] = +HEAPF32[i35 + 16 >> 2] - +HEAPF32[i17 >> 2];
michael@0 32782 HEAPF32[i20 >> 2] = d37;
michael@0 32783 HEAPF32[i21 >> 2] = d36;
michael@0 32784 HEAPF32[i22 >> 2] = 0.0;
michael@0 32785 i38 = HEAP32[i6 >> 2] | 0;
michael@0 32786 d36 = +HEAPF32[i23 >> 2];
michael@0 32787 d37 = +HEAPF32[i24 >> 2];
michael@0 32788 d39 = (+HEAPF32[i1 + (i38 << 4) >> 2] - d36) * d37;
michael@0 32789 d40 = d37 * (+HEAPF32[i1 + (1 - i38 << 4) >> 2] - d36);
michael@0 32790 i38 = HEAP32[i25 >> 2] | 0;
michael@0 32791 d36 = +HEAPF32[i26 >> 2];
michael@0 32792 d37 = +HEAPF32[i27 >> 2];
michael@0 32793 d41 = (+HEAPF32[i1 + (i38 << 4) + 4 >> 2] - d36) * d37;
michael@0 32794 d42 = d37 * (+HEAPF32[i1 + (1 - i38 << 4) + 4 >> 2] - d36);
michael@0 32795 do {
michael@0 32796 if (d39 > d42 | d41 > d40) {
michael@0 32797 i43 = i11;
michael@0 32798 i44 = i31;
michael@0 32799 i45 = i32;
michael@0 32800 i46 = i33;
michael@0 32801 i47 = i34;
michael@0 32802 } else {
michael@0 32803 d36 = d41 > d39 ? d41 : d39;
michael@0 32804 d37 = d42 < d40 ? d42 : d40;
michael@0 32805 i38 = HEAP32[i28 >> 2] | 0;
michael@0 32806 d48 = +HEAPF32[i29 >> 2];
michael@0 32807 d49 = +HEAPF32[i3 >> 2];
michael@0 32808 d50 = (+HEAPF32[i1 + (i38 << 4) + 8 >> 2] - d48) * d49;
michael@0 32809 d51 = d49 * (+HEAPF32[i1 + (1 - i38 << 4) + 8 >> 2] - d48);
michael@0 32810 if (d36 > d51 | d50 > d37) {
michael@0 32811 i43 = i11;
michael@0 32812 i44 = i31;
michael@0 32813 i45 = i32;
michael@0 32814 i46 = i33;
michael@0 32815 i47 = i34;
michael@0 32816 break;
michael@0 32817 }
michael@0 32818 if ((d50 > d36 ? d50 : d36) >= d7) {
michael@0 32819 i43 = i11;
michael@0 32820 i44 = i31;
michael@0 32821 i45 = i32;
michael@0 32822 i46 = i33;
michael@0 32823 i47 = i34;
michael@0 32824 break;
michael@0 32825 }
michael@0 32826 if ((d51 < d37 ? d51 : d37) <= 0.0) {
michael@0 32827 i43 = i11;
michael@0 32828 i44 = i31;
michael@0 32829 i45 = i32;
michael@0 32830 i46 = i33;
michael@0 32831 i47 = i34;
michael@0 32832 break;
michael@0 32833 }
michael@0 32834 i38 = i35 + 40 | 0;
michael@0 32835 if ((HEAP32[i38 >> 2] | 0) == 0) {
michael@0 32836 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i5 >> 2] | 0) + 12 >> 2] & 127](i10, i35);
michael@0 32837 i43 = i11;
michael@0 32838 i44 = i31;
michael@0 32839 i45 = i32;
michael@0 32840 i46 = i33;
michael@0 32841 i47 = i34;
michael@0 32842 break;
michael@0 32843 }
michael@0 32844 if ((i11 | 0) > (i31 | 0)) {
michael@0 32845 i52 = i32 << 1;
michael@0 32846 if ((i32 | 0) < (i52 | 0)) {
michael@0 32847 do {
michael@0 32848 if ((i33 | 0) < (i52 | 0)) {
michael@0 32849 if ((i52 | 0) == 0) {
michael@0 32850 i53 = 0;
michael@0 32851 } else {
michael@0 32852 i53 = __Z22btAlignedAllocInternalji(i32 << 3, 16) | 0;
michael@0 32853 }
michael@0 32854 if ((i32 | 0) > 0) {
michael@0 32855 i54 = 0;
michael@0 32856 do {
michael@0 32857 i55 = i53 + (i54 << 2) | 0;
michael@0 32858 if ((i55 | 0) != 0) {
michael@0 32859 HEAP32[i55 >> 2] = HEAP32[i34 + (i54 << 2) >> 2];
michael@0 32860 }
michael@0 32861 i54 = i54 + 1 | 0;
michael@0 32862 } while ((i54 | 0) < (i32 | 0));
michael@0 32863 }
michael@0 32864 if ((i34 | 0) == 0) {
michael@0 32865 i56 = i52;
michael@0 32866 i57 = i53;
michael@0 32867 break;
michael@0 32868 }
michael@0 32869 __Z21btAlignedFreeInternalPv(i34);
michael@0 32870 i56 = i52;
michael@0 32871 i57 = i53;
michael@0 32872 } else {
michael@0 32873 i56 = i33;
michael@0 32874 i57 = i34;
michael@0 32875 }
michael@0 32876 } while (0);
michael@0 32877 i54 = i32;
michael@0 32878 while (1) {
michael@0 32879 i55 = i57 + (i54 << 2) | 0;
michael@0 32880 if ((i55 | 0) != 0) {
michael@0 32881 HEAP32[i55 >> 2] = 0;
michael@0 32882 }
michael@0 32883 i55 = i54 + 1 | 0;
michael@0 32884 if ((i55 | 0) < (i52 | 0)) {
michael@0 32885 i54 = i55;
michael@0 32886 } else {
michael@0 32887 i58 = i56;
michael@0 32888 i59 = i57;
michael@0 32889 break;
michael@0 32890 }
michael@0 32891 }
michael@0 32892 } else {
michael@0 32893 i58 = i33;
michael@0 32894 i59 = i34;
michael@0 32895 }
michael@0 32896 i60 = i52 - 2 | 0;
michael@0 32897 i61 = i52;
michael@0 32898 i62 = i58;
michael@0 32899 i63 = i59;
michael@0 32900 } else {
michael@0 32901 i60 = i31;
michael@0 32902 i61 = i32;
michael@0 32903 i62 = i33;
michael@0 32904 i63 = i34;
michael@0 32905 }
michael@0 32906 HEAP32[i63 + (i11 << 2) >> 2] = HEAP32[i35 + 36 >> 2];
michael@0 32907 HEAP32[i63 + (i30 << 2) >> 2] = HEAP32[i38 >> 2];
michael@0 32908 i43 = i30 + 1 | 0;
michael@0 32909 i44 = i60;
michael@0 32910 i45 = i61;
michael@0 32911 i46 = i62;
michael@0 32912 i47 = i63;
michael@0 32913 }
michael@0 32914 } while (0);
michael@0 32915 if ((i43 | 0) == 0) {
michael@0 32916 break;
michael@0 32917 } else {
michael@0 32918 i30 = i43;
michael@0 32919 i31 = i44;
michael@0 32920 i32 = i45;
michael@0 32921 i33 = i46;
michael@0 32922 i34 = i47;
michael@0 32923 }
michael@0 32924 }
michael@0 32925 if ((i47 | 0) == 0) {
michael@0 32926 STACKTOP = i4;
michael@0 32927 return;
michael@0 32928 }
michael@0 32929 __Z21btAlignedFreeInternalPv(i47);
michael@0 32930 STACKTOP = i4;
michael@0 32931 return;
michael@0 32932 }
michael@0 32933 function __ZN33btMinkowskiPenetrationDepthSolver24getPenetrationDirectionsEv() {
michael@0 32934 if ((HEAP8[14336] | 0) != 0) {
michael@0 32935 return 13144;
michael@0 32936 }
michael@0 32937 if ((___cxa_guard_acquire(14336) | 0) == 0) {
michael@0 32938 return 13144;
michael@0 32939 }
michael@0 32940 HEAPF32[3286] = 0.0;
michael@0 32941 HEAPF32[3287] = -0.0;
michael@0 32942 HEAPF32[3288] = -1.0;
michael@0 32943 HEAPF32[3289] = 0.0;
michael@0 32944 HEAPF32[3290] = .7236080169677734;
michael@0 32945 HEAPF32[3291] = -.5257250070571899;
michael@0 32946 HEAPF32[3292] = -.44721901416778564;
michael@0 32947 HEAPF32[3293] = 0.0;
michael@0 32948 HEAPF32[3294] = -.2763879895210266;
michael@0 32949 HEAPF32[3295] = -.8506489992141724;
michael@0 32950 HEAPF32[3296] = -.44721901416778564;
michael@0 32951 HEAPF32[3297] = 0.0;
michael@0 32952 HEAPF32[3298] = -.8944259881973267;
michael@0 32953 HEAPF32[3299] = -0.0;
michael@0 32954 HEAPF32[3300] = -.4472160041332245;
michael@0 32955 HEAPF32[3301] = 0.0;
michael@0 32956 HEAPF32[3302] = -.2763879895210266;
michael@0 32957 HEAPF32[3303] = .8506489992141724;
michael@0 32958 HEAPF32[3304] = -.44721999764442444;
michael@0 32959 HEAPF32[3305] = 0.0;
michael@0 32960 HEAPF32[3306] = .7236080169677734;
michael@0 32961 HEAPF32[3307] = .5257250070571899;
michael@0 32962 HEAPF32[3308] = -.44721901416778564;
michael@0 32963 HEAPF32[3309] = 0.0;
michael@0 32964 HEAPF32[3310] = .2763879895210266;
michael@0 32965 HEAPF32[3311] = -.8506489992141724;
michael@0 32966 HEAPF32[3312] = .44721999764442444;
michael@0 32967 HEAPF32[3313] = 0.0;
michael@0 32968 HEAPF32[3314] = -.7236080169677734;
michael@0 32969 HEAPF32[3315] = -.5257250070571899;
michael@0 32970 HEAPF32[3316] = .44721901416778564;
michael@0 32971 HEAPF32[3317] = 0.0;
michael@0 32972 HEAPF32[3318] = -.7236080169677734;
michael@0 32973 HEAPF32[3319] = .5257250070571899;
michael@0 32974 HEAPF32[3320] = .44721901416778564;
michael@0 32975 HEAPF32[3321] = 0.0;
michael@0 32976 HEAPF32[3322] = .2763879895210266;
michael@0 32977 HEAPF32[3323] = .8506489992141724;
michael@0 32978 HEAPF32[3324] = .44721901416778564;
michael@0 32979 HEAPF32[3325] = 0.0;
michael@0 32980 HEAPF32[3326] = .8944259881973267;
michael@0 32981 HEAPF32[3327] = 0.0;
michael@0 32982 HEAPF32[3328] = .4472160041332245;
michael@0 32983 HEAPF32[3329] = 0.0;
michael@0 32984 HEAPF32[3330] = -0.0;
michael@0 32985 HEAPF32[3331] = 0.0;
michael@0 32986 HEAPF32[3332] = 1.0;
michael@0 32987 HEAPF32[3333] = 0.0;
michael@0 32988 HEAPF32[3334] = .4253230094909668;
michael@0 32989 HEAPF32[3335] = -.3090110123157501;
michael@0 32990 HEAPF32[3336] = -.8506540060043335;
michael@0 32991 HEAPF32[3337] = 0.0;
michael@0 32992 HEAPF32[3338] = -.16245600581169128;
michael@0 32993 HEAPF32[3339] = -.49999499320983887;
michael@0 32994 HEAPF32[3340] = -.8506540060043335;
michael@0 32995 HEAPF32[3341] = 0.0;
michael@0 32996 HEAPF32[3342] = .2628690004348755;
michael@0 32997 HEAPF32[3343] = -.8090119957923889;
michael@0 32998 HEAPF32[3344] = -.525738000869751;
michael@0 32999 HEAPF32[3345] = 0.0;
michael@0 33000 HEAPF32[3346] = .4253230094909668;
michael@0 33001 HEAPF32[3347] = .3090110123157501;
michael@0 33002 HEAPF32[3348] = -.8506540060043335;
michael@0 33003 HEAPF32[3349] = 0.0;
michael@0 33004 HEAPF32[3350] = .8506479859352112;
michael@0 33005 HEAPF32[3351] = -0.0;
michael@0 33006 HEAPF32[3352] = -.5257359743118286;
michael@0 33007 HEAPF32[3353] = 0.0;
michael@0 33008 HEAPF32[3354] = -.5257300138473511;
michael@0 33009 HEAPF32[3355] = -0.0;
michael@0 33010 HEAPF32[3356] = -.8506519794464111;
michael@0 33011 HEAPF32[3357] = 0.0;
michael@0 33012 HEAPF32[3358] = -.6881899833679199;
michael@0 33013 HEAPF32[3359] = -.49999698996543884;
michael@0 33014 HEAPF32[3360] = -.5257359743118286;
michael@0 33015 HEAPF32[3361] = 0.0;
michael@0 33016 HEAPF32[3362] = -.16245600581169128;
michael@0 33017 HEAPF32[3363] = .49999499320983887;
michael@0 33018 HEAPF32[3364] = -.8506540060043335;
michael@0 33019 HEAPF32[3365] = 0.0;
michael@0 33020 HEAPF32[3366] = -.6881899833679199;
michael@0 33021 HEAPF32[3367] = .49999698996543884;
michael@0 33022 HEAPF32[3368] = -.5257359743118286;
michael@0 33023 HEAPF32[3369] = 0.0;
michael@0 33024 HEAPF32[3370] = .2628690004348755;
michael@0 33025 HEAPF32[3371] = .8090119957923889;
michael@0 33026 HEAPF32[3372] = -.525738000869751;
michael@0 33027 HEAPF32[3373] = 0.0;
michael@0 33028 HEAPF32[3374] = .9510579705238342;
michael@0 33029 HEAPF32[3375] = .3090130090713501;
michael@0 33030 HEAPF32[3376] = 0.0;
michael@0 33031 HEAPF32[3377] = 0.0;
michael@0 33032 HEAPF32[3378] = .9510579705238342;
michael@0 33033 HEAPF32[3379] = -.3090130090713501;
michael@0 33034 HEAPF32[3380] = 0.0;
michael@0 33035 HEAPF32[3381] = 0.0;
michael@0 33036 HEAPF32[3382] = .5877860188484192;
michael@0 33037 HEAPF32[3383] = -.80901700258255;
michael@0 33038 HEAPF32[3384] = 0.0;
michael@0 33039 HEAPF32[3385] = 0.0;
michael@0 33040 HEAPF32[3386] = 0.0;
michael@0 33041 HEAPF32[3387] = -1.0;
michael@0 33042 HEAPF32[3388] = 0.0;
michael@0 33043 HEAPF32[3389] = 0.0;
michael@0 33044 HEAPF32[3390] = -.5877860188484192;
michael@0 33045 HEAPF32[3391] = -.80901700258255;
michael@0 33046 HEAPF32[3392] = 0.0;
michael@0 33047 HEAPF32[3393] = 0.0;
michael@0 33048 HEAPF32[3394] = -.9510579705238342;
michael@0 33049 HEAPF32[3395] = -.3090130090713501;
michael@0 33050 HEAPF32[3396] = -0.0;
michael@0 33051 HEAPF32[3397] = 0.0;
michael@0 33052 HEAPF32[3398] = -.9510579705238342;
michael@0 33053 HEAPF32[3399] = .3090130090713501;
michael@0 33054 HEAPF32[3400] = -0.0;
michael@0 33055 HEAPF32[3401] = 0.0;
michael@0 33056 HEAPF32[3402] = -.5877860188484192;
michael@0 33057 HEAPF32[3403] = .80901700258255;
michael@0 33058 HEAPF32[3404] = -0.0;
michael@0 33059 HEAPF32[3405] = 0.0;
michael@0 33060 HEAPF32[3406] = -0.0;
michael@0 33061 HEAPF32[3407] = 1.0;
michael@0 33062 HEAPF32[3408] = -0.0;
michael@0 33063 HEAPF32[3409] = 0.0;
michael@0 33064 HEAPF32[3410] = .5877860188484192;
michael@0 33065 HEAPF32[3411] = .80901700258255;
michael@0 33066 HEAPF32[3412] = -0.0;
michael@0 33067 HEAPF32[3413] = 0.0;
michael@0 33068 HEAPF32[3414] = .6881899833679199;
michael@0 33069 HEAPF32[3415] = -.49999698996543884;
michael@0 33070 HEAPF32[3416] = .5257359743118286;
michael@0 33071 HEAPF32[3417] = 0.0;
michael@0 33072 HEAPF32[3418] = -.2628690004348755;
michael@0 33073 HEAPF32[3419] = -.8090119957923889;
michael@0 33074 HEAPF32[3420] = .525738000869751;
michael@0 33075 HEAPF32[3421] = 0.0;
michael@0 33076 HEAPF32[3422] = -.8506479859352112;
michael@0 33077 HEAPF32[3423] = 0.0;
michael@0 33078 HEAPF32[3424] = .5257359743118286;
michael@0 33079 HEAPF32[3425] = 0.0;
michael@0 33080 HEAPF32[3426] = -.2628690004348755;
michael@0 33081 HEAPF32[3427] = .8090119957923889;
michael@0 33082 HEAPF32[3428] = .525738000869751;
michael@0 33083 HEAPF32[3429] = 0.0;
michael@0 33084 HEAPF32[3430] = .6881899833679199;
michael@0 33085 HEAPF32[3431] = .49999698996543884;
michael@0 33086 HEAPF32[3432] = .5257359743118286;
michael@0 33087 HEAPF32[3433] = 0.0;
michael@0 33088 HEAPF32[3434] = .5257300138473511;
michael@0 33089 HEAPF32[3435] = 0.0;
michael@0 33090 HEAPF32[3436] = .8506519794464111;
michael@0 33091 HEAPF32[3437] = 0.0;
michael@0 33092 HEAPF32[3438] = .16245600581169128;
michael@0 33093 HEAPF32[3439] = -.49999499320983887;
michael@0 33094 HEAPF32[3440] = .8506540060043335;
michael@0 33095 HEAPF32[3441] = 0.0;
michael@0 33096 HEAPF32[3442] = -.4253230094909668;
michael@0 33097 HEAPF32[3443] = -.3090110123157501;
michael@0 33098 HEAPF32[3444] = .8506540060043335;
michael@0 33099 HEAPF32[3445] = 0.0;
michael@0 33100 HEAPF32[3446] = -.4253230094909668;
michael@0 33101 HEAPF32[3447] = .3090110123157501;
michael@0 33102 HEAPF32[3448] = .8506540060043335;
michael@0 33103 HEAPF32[3449] = 0.0;
michael@0 33104 HEAPF32[3450] = .16245600581169128;
michael@0 33105 HEAPF32[3451] = .49999499320983887;
michael@0 33106 HEAPF32[3452] = .8506540060043335;
michael@0 33107 HEAPF32[3453] = 0.0;
michael@0 33108 return 13144;
michael@0 33109 }
michael@0 33110 function __ZN6btDbvt7rayTestEPK10btDbvtNodeRK9btVector3S5_RNS_8ICollideE(i1, i2, i3, i4) {
michael@0 33111 i1 = i1 | 0;
michael@0 33112 i2 = i2 | 0;
michael@0 33113 i3 = i3 | 0;
michael@0 33114 i4 = i4 | 0;
michael@0 33115 var i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, i9 = 0, d10 = 0.0, i11 = 0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, d38 = 0.0, d39 = 0.0, d40 = 0.0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, i50 = 0, i51 = 0, i52 = 0;
michael@0 33116 i5 = STACKTOP;
michael@0 33117 STACKTOP = STACKTOP + 32 | 0;
michael@0 33118 i6 = i5 | 0;
michael@0 33119 if ((i1 | 0) == 0) {
michael@0 33120 STACKTOP = i5;
michael@0 33121 return;
michael@0 33122 }
michael@0 33123 i7 = i2 | 0;
michael@0 33124 d8 = +HEAPF32[i3 >> 2] - +HEAPF32[i7 >> 2];
michael@0 33125 i9 = i2 + 4 | 0;
michael@0 33126 d10 = +HEAPF32[i3 + 4 >> 2] - +HEAPF32[i9 >> 2];
michael@0 33127 i11 = i2 + 8 | 0;
michael@0 33128 d12 = +HEAPF32[i3 + 8 >> 2] - +HEAPF32[i11 >> 2];
michael@0 33129 d13 = 1.0 / +Math_sqrt(+(d8 * d8 + d10 * d10 + d12 * d12));
michael@0 33130 d14 = d8 * d13;
michael@0 33131 d15 = d10 * d13;
michael@0 33132 d16 = d12 * d13;
michael@0 33133 if (d14 == 0.0) {
michael@0 33134 d17 = 999999984306749400.0;
michael@0 33135 } else {
michael@0 33136 d17 = 1.0 / d14;
michael@0 33137 }
michael@0 33138 if (d15 == 0.0) {
michael@0 33139 d18 = 999999984306749400.0;
michael@0 33140 } else {
michael@0 33141 d18 = 1.0 / d15;
michael@0 33142 }
michael@0 33143 if (d16 == 0.0) {
michael@0 33144 d19 = 999999984306749400.0;
michael@0 33145 } else {
michael@0 33146 d19 = 1.0 / d16;
michael@0 33147 }
michael@0 33148 i3 = d17 < 0.0 | 0;
michael@0 33149 i2 = d18 < 0.0 | 0;
michael@0 33150 i20 = d19 < 0.0 | 0;
michael@0 33151 d13 = d12 * d16 + (d8 * d14 + d10 * d15);
michael@0 33152 i21 = __Z22btAlignedAllocInternalji(512, 16) | 0;
michael@0 33153 i22 = 0;
michael@0 33154 do {
michael@0 33155 i23 = i21 + (i22 << 2) | 0;
michael@0 33156 if ((i23 | 0) != 0) {
michael@0 33157 HEAP32[i23 >> 2] = 0;
michael@0 33158 }
michael@0 33159 i22 = i22 + 1 | 0;
michael@0 33160 } while ((i22 | 0) < 128);
michael@0 33161 HEAP32[i21 >> 2] = i1;
michael@0 33162 i1 = i6;
michael@0 33163 i22 = i6 + 16 | 0;
michael@0 33164 i23 = i6 + (i3 << 4) | 0;
michael@0 33165 i24 = i6 + ((i3 ^ 1) << 4) | 0;
michael@0 33166 i3 = i6 + (i2 << 4) + 4 | 0;
michael@0 33167 i25 = i6 + ((i2 ^ 1) << 4) + 4 | 0;
michael@0 33168 i2 = i6 + (i20 << 4) + 8 | 0;
michael@0 33169 i26 = i6 + ((i20 ^ 1) << 4) + 8 | 0;
michael@0 33170 i20 = i4;
michael@0 33171 i6 = 1;
michael@0 33172 i27 = 126;
michael@0 33173 i28 = 128;
michael@0 33174 i29 = 128;
michael@0 33175 i30 = i21;
michael@0 33176 while (1) {
michael@0 33177 i21 = i6 - 1 | 0;
michael@0 33178 i31 = HEAP32[i30 + (i21 << 2) >> 2] | 0;
michael@0 33179 i32 = i31;
michael@0 33180 HEAP32[i1 >> 2] = HEAP32[i32 >> 2];
michael@0 33181 HEAP32[i1 + 4 >> 2] = HEAP32[i32 + 4 >> 2];
michael@0 33182 HEAP32[i1 + 8 >> 2] = HEAP32[i32 + 8 >> 2];
michael@0 33183 HEAP32[i1 + 12 >> 2] = HEAP32[i32 + 12 >> 2];
michael@0 33184 i32 = i31 + 16 | 0;
michael@0 33185 HEAP32[i22 >> 2] = HEAP32[i32 >> 2];
michael@0 33186 HEAP32[i22 + 4 >> 2] = HEAP32[i32 + 4 >> 2];
michael@0 33187 HEAP32[i22 + 8 >> 2] = HEAP32[i32 + 8 >> 2];
michael@0 33188 HEAP32[i22 + 12 >> 2] = HEAP32[i32 + 12 >> 2];
michael@0 33189 d15 = +HEAPF32[i7 >> 2];
michael@0 33190 d10 = d17 * (+HEAPF32[i23 >> 2] - d15);
michael@0 33191 d14 = d17 * (+HEAPF32[i24 >> 2] - d15);
michael@0 33192 d15 = +HEAPF32[i9 >> 2];
michael@0 33193 d8 = d18 * (+HEAPF32[i3 >> 2] - d15);
michael@0 33194 d16 = d18 * (+HEAPF32[i25 >> 2] - d15);
michael@0 33195 do {
michael@0 33196 if (d10 > d16 | d8 > d14) {
michael@0 33197 i33 = i21;
michael@0 33198 i34 = i27;
michael@0 33199 i35 = i28;
michael@0 33200 i36 = i29;
michael@0 33201 i37 = i30;
michael@0 33202 } else {
michael@0 33203 d15 = d8 > d10 ? d8 : d10;
michael@0 33204 d12 = d16 < d14 ? d16 : d14;
michael@0 33205 d38 = +HEAPF32[i11 >> 2];
michael@0 33206 d39 = d19 * (+HEAPF32[i2 >> 2] - d38);
michael@0 33207 d40 = d19 * (+HEAPF32[i26 >> 2] - d38);
michael@0 33208 if (d15 > d40 | d39 > d12) {
michael@0 33209 i33 = i21;
michael@0 33210 i34 = i27;
michael@0 33211 i35 = i28;
michael@0 33212 i36 = i29;
michael@0 33213 i37 = i30;
michael@0 33214 break;
michael@0 33215 }
michael@0 33216 if ((d39 > d15 ? d39 : d15) >= d13) {
michael@0 33217 i33 = i21;
michael@0 33218 i34 = i27;
michael@0 33219 i35 = i28;
michael@0 33220 i36 = i29;
michael@0 33221 i37 = i30;
michael@0 33222 break;
michael@0 33223 }
michael@0 33224 if ((d40 < d12 ? d40 : d12) <= 0.0) {
michael@0 33225 i33 = i21;
michael@0 33226 i34 = i27;
michael@0 33227 i35 = i28;
michael@0 33228 i36 = i29;
michael@0 33229 i37 = i30;
michael@0 33230 break;
michael@0 33231 }
michael@0 33232 i32 = i31 + 40 | 0;
michael@0 33233 if ((HEAP32[i32 >> 2] | 0) == 0) {
michael@0 33234 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i20 >> 2] | 0) + 12 >> 2] & 127](i4, i31);
michael@0 33235 i33 = i21;
michael@0 33236 i34 = i27;
michael@0 33237 i35 = i28;
michael@0 33238 i36 = i29;
michael@0 33239 i37 = i30;
michael@0 33240 break;
michael@0 33241 }
michael@0 33242 if ((i21 | 0) > (i27 | 0)) {
michael@0 33243 i41 = i28 << 1;
michael@0 33244 if ((i28 | 0) < (i41 | 0)) {
michael@0 33245 do {
michael@0 33246 if ((i29 | 0) < (i41 | 0)) {
michael@0 33247 if ((i41 | 0) == 0) {
michael@0 33248 i42 = 0;
michael@0 33249 } else {
michael@0 33250 i42 = __Z22btAlignedAllocInternalji(i28 << 3, 16) | 0;
michael@0 33251 }
michael@0 33252 if ((i28 | 0) > 0) {
michael@0 33253 i43 = 0;
michael@0 33254 do {
michael@0 33255 i44 = i42 + (i43 << 2) | 0;
michael@0 33256 if ((i44 | 0) != 0) {
michael@0 33257 HEAP32[i44 >> 2] = HEAP32[i30 + (i43 << 2) >> 2];
michael@0 33258 }
michael@0 33259 i43 = i43 + 1 | 0;
michael@0 33260 } while ((i43 | 0) < (i28 | 0));
michael@0 33261 }
michael@0 33262 if ((i30 | 0) == 0) {
michael@0 33263 i45 = i41;
michael@0 33264 i46 = i42;
michael@0 33265 break;
michael@0 33266 }
michael@0 33267 __Z21btAlignedFreeInternalPv(i30);
michael@0 33268 i45 = i41;
michael@0 33269 i46 = i42;
michael@0 33270 } else {
michael@0 33271 i45 = i29;
michael@0 33272 i46 = i30;
michael@0 33273 }
michael@0 33274 } while (0);
michael@0 33275 i43 = i28;
michael@0 33276 while (1) {
michael@0 33277 i44 = i46 + (i43 << 2) | 0;
michael@0 33278 if ((i44 | 0) != 0) {
michael@0 33279 HEAP32[i44 >> 2] = 0;
michael@0 33280 }
michael@0 33281 i44 = i43 + 1 | 0;
michael@0 33282 if ((i44 | 0) < (i41 | 0)) {
michael@0 33283 i43 = i44;
michael@0 33284 } else {
michael@0 33285 i47 = i45;
michael@0 33286 i48 = i46;
michael@0 33287 break;
michael@0 33288 }
michael@0 33289 }
michael@0 33290 } else {
michael@0 33291 i47 = i29;
michael@0 33292 i48 = i30;
michael@0 33293 }
michael@0 33294 i49 = i41 - 2 | 0;
michael@0 33295 i50 = i41;
michael@0 33296 i51 = i47;
michael@0 33297 i52 = i48;
michael@0 33298 } else {
michael@0 33299 i49 = i27;
michael@0 33300 i50 = i28;
michael@0 33301 i51 = i29;
michael@0 33302 i52 = i30;
michael@0 33303 }
michael@0 33304 HEAP32[i52 + (i21 << 2) >> 2] = HEAP32[i31 + 36 >> 2];
michael@0 33305 HEAP32[i52 + (i6 << 2) >> 2] = HEAP32[i32 >> 2];
michael@0 33306 i33 = i6 + 1 | 0;
michael@0 33307 i34 = i49;
michael@0 33308 i35 = i50;
michael@0 33309 i36 = i51;
michael@0 33310 i37 = i52;
michael@0 33311 }
michael@0 33312 } while (0);
michael@0 33313 if ((i33 | 0) == 0) {
michael@0 33314 break;
michael@0 33315 } else {
michael@0 33316 i6 = i33;
michael@0 33317 i27 = i34;
michael@0 33318 i28 = i35;
michael@0 33319 i29 = i36;
michael@0 33320 i30 = i37;
michael@0 33321 }
michael@0 33322 }
michael@0 33323 if ((i37 | 0) == 0) {
michael@0 33324 STACKTOP = i5;
michael@0 33325 return;
michael@0 33326 }
michael@0 33327 __Z21btAlignedFreeInternalPv(i37);
michael@0 33328 STACKTOP = i5;
michael@0 33329 return;
michael@0 33330 }
michael@0 33331 function __ZN35btSequentialImpulseConstraintSolver29solveGroupCacheFriendlyFinishEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
michael@0 33332 i1 = i1 | 0;
michael@0 33333 i2 = i2 | 0;
michael@0 33334 i3 = i3 | 0;
michael@0 33335 i4 = i4 | 0;
michael@0 33336 i5 = i5 | 0;
michael@0 33337 i6 = i6 | 0;
michael@0 33338 i7 = i7 | 0;
michael@0 33339 i8 = i8 | 0;
michael@0 33340 i9 = i9 | 0;
michael@0 33341 i10 = i10 | 0;
michael@0 33342 var i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, d18 = 0.0, d19 = 0.0, i20 = 0, i21 = 0, i22 = 0;
michael@0 33343 i10 = STACKTOP;
michael@0 33344 STACKTOP = STACKTOP + 408 | 0;
michael@0 33345 i9 = i10 | 0;
michael@0 33346 i7 = i10 + 136 | 0;
michael@0 33347 i6 = i10 + 272 | 0;
michael@0 33348 i5 = i1 + 8 | 0;
michael@0 33349 i4 = HEAP32[i5 >> 2] | 0;
michael@0 33350 if ((i4 | 0) > 0) {
michael@0 33351 i11 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 33352 i12 = i1 + 56 | 0;
michael@0 33353 if ((HEAP32[i8 + 60 >> 2] & 8 | 0) == 0) {
michael@0 33354 i13 = 0;
michael@0 33355 do {
michael@0 33356 HEAPF32[(HEAP32[i11 + (i13 * 136 | 0) + 112 >> 2] | 0) + 112 >> 2] = +HEAPF32[i11 + (i13 * 136 | 0) + 84 >> 2];
michael@0 33357 i13 = i13 + 1 | 0;
michael@0 33358 } while ((i13 | 0) < (i4 | 0));
michael@0 33359 } else {
michael@0 33360 i13 = 0;
michael@0 33361 do {
michael@0 33362 i14 = HEAP32[i11 + (i13 * 136 | 0) + 112 >> 2] | 0;
michael@0 33363 HEAPF32[i14 + 112 >> 2] = +HEAPF32[i11 + (i13 * 136 | 0) + 84 >> 2];
michael@0 33364 i15 = HEAP32[i11 + (i13 * 136 | 0) + 100 >> 2] | 0;
michael@0 33365 i16 = HEAP32[i12 >> 2] | 0;
michael@0 33366 HEAPF32[i14 + 120 >> 2] = +HEAPF32[i16 + (i15 * 136 | 0) + 84 >> 2];
michael@0 33367 HEAPF32[i14 + 124 >> 2] = +HEAPF32[i16 + ((i15 + 1 | 0) * 136 | 0) + 84 >> 2];
michael@0 33368 i13 = i13 + 1 | 0;
michael@0 33369 } while ((i13 | 0) < (i4 | 0));
michael@0 33370 }
michael@0 33371 }
michael@0 33372 i4 = i1 + 28 | 0;
michael@0 33373 i13 = HEAP32[i4 >> 2] | 0;
michael@0 33374 if ((i13 | 0) > 0) {
michael@0 33375 i12 = HEAP32[i1 + 36 >> 2] | 0;
michael@0 33376 i11 = 0;
michael@0 33377 do {
michael@0 33378 i15 = HEAP32[i12 + (i11 * 136 | 0) + 112 >> 2] | 0;
michael@0 33379 i16 = i12 + (i11 * 136 | 0) + 84 | 0;
michael@0 33380 HEAPF32[i15 + 32 >> 2] = +HEAPF32[i16 >> 2];
michael@0 33381 if (+HEAPF32[i16 >> 2] > +HEAPF32[i15 + 16 >> 2]) {
michael@0 33382 HEAP8[i15 + 20 | 0] = 0;
michael@0 33383 }
michael@0 33384 i11 = i11 + 1 | 0;
michael@0 33385 } while ((i11 | 0) < (i13 | 0));
michael@0 33386 }
michael@0 33387 i13 = (i3 | 0) > 0;
michael@0 33388 do {
michael@0 33389 if ((HEAP32[i8 + 44 >> 2] | 0) == 0) {
michael@0 33390 if (i13) {
michael@0 33391 i17 = 0;
michael@0 33392 } else {
michael@0 33393 break;
michael@0 33394 }
michael@0 33395 do {
michael@0 33396 i11 = HEAP32[i2 + (i17 << 2) >> 2] | 0;
michael@0 33397 do {
michael@0 33398 if (!((HEAP32[i11 + 232 >> 2] & 2 | 0) == 0 | (i11 | 0) == 0)) {
michael@0 33399 if (+HEAPF32[i11 + 336 >> 2] == 0.0) {
michael@0 33400 break;
michael@0 33401 }
michael@0 33402 i12 = i11 + 304 | 0;
michael@0 33403 i15 = i11 + 308 | 0;
michael@0 33404 d18 = +HEAPF32[i15 >> 2] + +HEAPF32[i11 + 508 >> 2];
michael@0 33405 i16 = i11 + 312 | 0;
michael@0 33406 d19 = +HEAPF32[i16 >> 2] + +HEAPF32[i11 + 512 >> 2];
michael@0 33407 HEAPF32[i12 >> 2] = +HEAPF32[i12 >> 2] + +HEAPF32[i11 + 504 >> 2];
michael@0 33408 HEAPF32[i15 >> 2] = d18;
michael@0 33409 HEAPF32[i16 >> 2] = d19;
michael@0 33410 HEAPF32[i11 + 316 >> 2] = 0.0;
michael@0 33411 i16 = i11 + 320 | 0;
michael@0 33412 i15 = i11 + 324 | 0;
michael@0 33413 d19 = +HEAPF32[i15 >> 2] + +HEAPF32[i11 + 524 >> 2];
michael@0 33414 i12 = i11 + 328 | 0;
michael@0 33415 d18 = +HEAPF32[i12 >> 2] + +HEAPF32[i11 + 528 >> 2];
michael@0 33416 HEAPF32[i16 >> 2] = +HEAPF32[i16 >> 2] + +HEAPF32[i11 + 520 >> 2];
michael@0 33417 HEAPF32[i15 >> 2] = d19;
michael@0 33418 HEAPF32[i12 >> 2] = d18;
michael@0 33419 HEAPF32[i11 + 332 >> 2] = 0.0;
michael@0 33420 }
michael@0 33421 } while (0);
michael@0 33422 i17 = i17 + 1 | 0;
michael@0 33423 } while ((i17 | 0) < (i3 | 0));
michael@0 33424 } else {
michael@0 33425 if (!i13) {
michael@0 33426 break;
michael@0 33427 }
michael@0 33428 i11 = i8 + 12 | 0;
michael@0 33429 i12 = 0;
michael@0 33430 do {
michael@0 33431 i15 = HEAP32[i2 + (i12 << 2) >> 2] | 0;
michael@0 33432 if (!((HEAP32[i15 + 232 >> 2] & 2 | 0) == 0 | (i15 | 0) == 0)) {
michael@0 33433 __ZN11btRigidBody25internalWritebackVelocityEf(i15, +HEAPF32[i11 >> 2]);
michael@0 33434 }
michael@0 33435 i12 = i12 + 1 | 0;
michael@0 33436 } while ((i12 | 0) < (i3 | 0));
michael@0 33437 }
michael@0 33438 } while (0);
michael@0 33439 i3 = i9;
michael@0 33440 _memset(i3 | 0, 0, 136);
michael@0 33441 i9 = HEAP32[i5 >> 2] | 0;
michael@0 33442 if ((i9 | 0) < 0) {
michael@0 33443 i2 = i1 + 12 | 0;
michael@0 33444 i8 = i1 + 16 | 0;
michael@0 33445 if ((HEAP32[i2 >> 2] | 0) < 0) {
michael@0 33446 i13 = HEAP32[i8 >> 2] | 0;
michael@0 33447 i17 = i1 + 20 | 0;
michael@0 33448 if ((i13 | 0) != 0) {
michael@0 33449 if ((HEAP8[i17] | 0) != 0) {
michael@0 33450 __Z21btAlignedFreeInternalPv(i13);
michael@0 33451 }
michael@0 33452 HEAP32[i8 >> 2] = 0;
michael@0 33453 }
michael@0 33454 HEAP8[i17] = 1;
michael@0 33455 HEAP32[i8 >> 2] = 0;
michael@0 33456 HEAP32[i2 >> 2] = 0;
michael@0 33457 i20 = i9;
michael@0 33458 } else {
michael@0 33459 i20 = i9;
michael@0 33460 }
michael@0 33461 do {
michael@0 33462 i9 = (HEAP32[i8 >> 2] | 0) + (i20 * 136 | 0) | 0;
michael@0 33463 _memcpy(i9 | 0, i3 | 0, 136) | 0;
michael@0 33464 i20 = i20 + 1 | 0;
michael@0 33465 } while ((i20 | 0) < 0);
michael@0 33466 }
michael@0 33467 HEAP32[i5 >> 2] = 0;
michael@0 33468 i5 = i7;
michael@0 33469 _memset(i5 | 0, 0, 136);
michael@0 33470 i7 = HEAP32[i4 >> 2] | 0;
michael@0 33471 if ((i7 | 0) < 0) {
michael@0 33472 i20 = i1 + 32 | 0;
michael@0 33473 i3 = i1 + 36 | 0;
michael@0 33474 if ((HEAP32[i20 >> 2] | 0) < 0) {
michael@0 33475 i8 = HEAP32[i3 >> 2] | 0;
michael@0 33476 i9 = i1 + 40 | 0;
michael@0 33477 if ((i8 | 0) != 0) {
michael@0 33478 if ((HEAP8[i9] | 0) != 0) {
michael@0 33479 __Z21btAlignedFreeInternalPv(i8);
michael@0 33480 }
michael@0 33481 HEAP32[i3 >> 2] = 0;
michael@0 33482 }
michael@0 33483 HEAP8[i9] = 1;
michael@0 33484 HEAP32[i3 >> 2] = 0;
michael@0 33485 HEAP32[i20 >> 2] = 0;
michael@0 33486 i21 = i7;
michael@0 33487 } else {
michael@0 33488 i21 = i7;
michael@0 33489 }
michael@0 33490 do {
michael@0 33491 i7 = (HEAP32[i3 >> 2] | 0) + (i21 * 136 | 0) | 0;
michael@0 33492 _memcpy(i7 | 0, i5 | 0, 136) | 0;
michael@0 33493 i21 = i21 + 1 | 0;
michael@0 33494 } while ((i21 | 0) < 0);
michael@0 33495 }
michael@0 33496 HEAP32[i4 >> 2] = 0;
michael@0 33497 i4 = i6;
michael@0 33498 _memset(i4 | 0, 0, 136);
michael@0 33499 i6 = i1 + 48 | 0;
michael@0 33500 i21 = HEAP32[i6 >> 2] | 0;
michael@0 33501 if ((i21 | 0) >= 0) {
michael@0 33502 HEAP32[i6 >> 2] = 0;
michael@0 33503 STACKTOP = i10;
michael@0 33504 return +0.0;
michael@0 33505 }
michael@0 33506 i5 = i1 + 52 | 0;
michael@0 33507 i3 = i1 + 56 | 0;
michael@0 33508 if ((HEAP32[i5 >> 2] | 0) < 0) {
michael@0 33509 i7 = HEAP32[i3 >> 2] | 0;
michael@0 33510 i20 = i1 + 60 | 0;
michael@0 33511 if ((i7 | 0) != 0) {
michael@0 33512 if ((HEAP8[i20] | 0) != 0) {
michael@0 33513 __Z21btAlignedFreeInternalPv(i7);
michael@0 33514 }
michael@0 33515 HEAP32[i3 >> 2] = 0;
michael@0 33516 }
michael@0 33517 HEAP8[i20] = 1;
michael@0 33518 HEAP32[i3 >> 2] = 0;
michael@0 33519 HEAP32[i5 >> 2] = 0;
michael@0 33520 i22 = i21;
michael@0 33521 } else {
michael@0 33522 i22 = i21;
michael@0 33523 }
michael@0 33524 do {
michael@0 33525 i21 = (HEAP32[i3 >> 2] | 0) + (i22 * 136 | 0) | 0;
michael@0 33526 _memcpy(i21 | 0, i4 | 0, 136) | 0;
michael@0 33527 i22 = i22 + 1 | 0;
michael@0 33528 } while ((i22 | 0) < 0);
michael@0 33529 HEAP32[i6 >> 2] = 0;
michael@0 33530 STACKTOP = i10;
michael@0 33531 return +0.0;
michael@0 33532 }
michael@0 33533 function __ZN35btSequentialImpulseConstraintSolver28setFrictionConstraintImpulseER18btSolverConstraintP11btRigidBodyS3_R15btManifoldPointRK19btContactSolverInfo(i1, i2, i3, i4, i5, i6) {
michael@0 33534 i1 = i1 | 0;
michael@0 33535 i2 = i2 | 0;
michael@0 33536 i3 = i3 | 0;
michael@0 33537 i4 = i4 | 0;
michael@0 33538 i5 = i5 | 0;
michael@0 33539 i6 = i6 | 0;
michael@0 33540 var i7 = 0, i8 = 0, d9 = 0.0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0;
michael@0 33541 i7 = HEAP32[i6 + 60 >> 2] | 0;
michael@0 33542 i8 = HEAP32[i2 + 100 >> 2] | 0;
michael@0 33543 i2 = HEAP32[i1 + 56 >> 2] | 0;
michael@0 33544 if ((i7 & 8 | 0) == 0) {
michael@0 33545 HEAPF32[i2 + (i8 * 136 | 0) + 84 >> 2] = 0.0;
michael@0 33546 if ((i7 & 16 | 0) == 0) {
michael@0 33547 return;
michael@0 33548 }
michael@0 33549 HEAPF32[i2 + ((i8 + 1 | 0) * 136 | 0) + 84 >> 2] = 0.0;
michael@0 33550 return;
michael@0 33551 }
michael@0 33552 i1 = (i7 & 4 | 0) == 0;
michael@0 33553 do {
michael@0 33554 if (i1) {
michael@0 33555 HEAPF32[i2 + (i8 * 136 | 0) + 84 >> 2] = 0.0;
michael@0 33556 } else {
michael@0 33557 d9 = +HEAPF32[i5 + 120 >> 2] * +HEAPF32[i6 + 56 >> 2];
michael@0 33558 i10 = i2 + (i8 * 136 | 0) + 84 | 0;
michael@0 33559 HEAPF32[i10 >> 2] = d9;
michael@0 33560 do {
michael@0 33561 if ((i3 | 0) != 0) {
michael@0 33562 d11 = +HEAPF32[i3 + 336 >> 2];
michael@0 33563 if (d11 == 0.0) {
michael@0 33564 break;
michael@0 33565 }
michael@0 33566 d12 = d9 * d11 * +HEAPF32[i2 + (i8 * 136 | 0) + 20 >> 2] * +HEAPF32[i3 + 344 >> 2];
michael@0 33567 d13 = d9 * d11 * +HEAPF32[i2 + (i8 * 136 | 0) + 24 >> 2] * +HEAPF32[i3 + 348 >> 2];
michael@0 33568 i14 = i3 + 504 | 0;
michael@0 33569 HEAPF32[i14 >> 2] = +HEAPF32[i14 >> 2] + d9 * d11 * +HEAPF32[i2 + (i8 * 136 | 0) + 16 >> 2] * +HEAPF32[i3 + 340 >> 2];
michael@0 33570 i14 = i3 + 508 | 0;
michael@0 33571 HEAPF32[i14 >> 2] = d12 + +HEAPF32[i14 >> 2];
michael@0 33572 i14 = i3 + 512 | 0;
michael@0 33573 HEAPF32[i14 >> 2] = d13 + +HEAPF32[i14 >> 2];
michael@0 33574 d13 = d9 * +HEAPF32[i3 + 540 >> 2] * +HEAPF32[i2 + (i8 * 136 | 0) + 52 >> 2];
michael@0 33575 d12 = d9 * +HEAPF32[i3 + 544 >> 2] * +HEAPF32[i2 + (i8 * 136 | 0) + 56 >> 2];
michael@0 33576 i14 = i3 + 520 | 0;
michael@0 33577 HEAPF32[i14 >> 2] = d9 * +HEAPF32[i3 + 536 >> 2] * +HEAPF32[i2 + (i8 * 136 | 0) + 48 >> 2] + +HEAPF32[i14 >> 2];
michael@0 33578 i14 = i3 + 524 | 0;
michael@0 33579 HEAPF32[i14 >> 2] = d13 + +HEAPF32[i14 >> 2];
michael@0 33580 i14 = i3 + 528 | 0;
michael@0 33581 HEAPF32[i14 >> 2] = d12 + +HEAPF32[i14 >> 2];
michael@0 33582 }
michael@0 33583 } while (0);
michael@0 33584 if ((i4 | 0) == 0) {
michael@0 33585 break;
michael@0 33586 }
michael@0 33587 d9 = +HEAPF32[i4 + 336 >> 2];
michael@0 33588 d12 = -0.0 - +HEAPF32[i10 >> 2];
michael@0 33589 if (d9 == 0.0) {
michael@0 33590 break;
michael@0 33591 }
michael@0 33592 d13 = -0.0 - +HEAPF32[i2 + (i8 * 136 | 0) + 72 >> 2];
michael@0 33593 d11 = -0.0 - +HEAPF32[i2 + (i8 * 136 | 0) + 68 >> 2];
michael@0 33594 d15 = -0.0 - +HEAPF32[i2 + (i8 * 136 | 0) + 64 >> 2];
michael@0 33595 d16 = d9 * +HEAPF32[i2 + (i8 * 136 | 0) + 20 >> 2] * +HEAPF32[i4 + 344 >> 2] * d12;
michael@0 33596 d17 = d9 * +HEAPF32[i2 + (i8 * 136 | 0) + 24 >> 2] * +HEAPF32[i4 + 348 >> 2] * d12;
michael@0 33597 i14 = i4 + 504 | 0;
michael@0 33598 HEAPF32[i14 >> 2] = +HEAPF32[i14 >> 2] + d9 * +HEAPF32[i2 + (i8 * 136 | 0) + 16 >> 2] * +HEAPF32[i4 + 340 >> 2] * d12;
michael@0 33599 i14 = i4 + 508 | 0;
michael@0 33600 HEAPF32[i14 >> 2] = d16 + +HEAPF32[i14 >> 2];
michael@0 33601 i14 = i4 + 512 | 0;
michael@0 33602 HEAPF32[i14 >> 2] = d17 + +HEAPF32[i14 >> 2];
michael@0 33603 d17 = +HEAPF32[i4 + 540 >> 2] * d12 * d11;
michael@0 33604 d11 = +HEAPF32[i4 + 544 >> 2] * d12 * d13;
michael@0 33605 i14 = i4 + 520 | 0;
michael@0 33606 HEAPF32[i14 >> 2] = +HEAPF32[i4 + 536 >> 2] * d12 * d15 + +HEAPF32[i14 >> 2];
michael@0 33607 i14 = i4 + 524 | 0;
michael@0 33608 HEAPF32[i14 >> 2] = d17 + +HEAPF32[i14 >> 2];
michael@0 33609 i14 = i4 + 528 | 0;
michael@0 33610 HEAPF32[i14 >> 2] = d11 + +HEAPF32[i14 >> 2];
michael@0 33611 }
michael@0 33612 } while (0);
michael@0 33613 if ((i7 & 16 | 0) == 0) {
michael@0 33614 return;
michael@0 33615 }
michael@0 33616 i7 = i8 + 1 | 0;
michael@0 33617 if (i1) {
michael@0 33618 HEAPF32[i2 + (i7 * 136 | 0) + 84 >> 2] = 0.0;
michael@0 33619 return;
michael@0 33620 }
michael@0 33621 d11 = +HEAPF32[i5 + 124 >> 2] * +HEAPF32[i6 + 56 >> 2];
michael@0 33622 i6 = i2 + (i7 * 136 | 0) + 84 | 0;
michael@0 33623 HEAPF32[i6 >> 2] = d11;
michael@0 33624 do {
michael@0 33625 if ((i3 | 0) != 0) {
michael@0 33626 d17 = +HEAPF32[i3 + 336 >> 2];
michael@0 33627 if (d17 == 0.0) {
michael@0 33628 break;
michael@0 33629 }
michael@0 33630 d15 = d11 * d17 * +HEAPF32[i2 + (i7 * 136 | 0) + 20 >> 2];
michael@0 33631 d12 = d11 * d17 * +HEAPF32[i2 + (i7 * 136 | 0) + 24 >> 2];
michael@0 33632 i5 = i3 + 504 | 0;
michael@0 33633 HEAPF32[i5 >> 2] = +HEAPF32[i5 >> 2] + d11 * d17 * +HEAPF32[i2 + (i7 * 136 | 0) + 16 >> 2];
michael@0 33634 i5 = i3 + 508 | 0;
michael@0 33635 HEAPF32[i5 >> 2] = d15 + +HEAPF32[i5 >> 2];
michael@0 33636 i5 = i3 + 512 | 0;
michael@0 33637 HEAPF32[i5 >> 2] = d12 + +HEAPF32[i5 >> 2];
michael@0 33638 d12 = d11 * +HEAPF32[i3 + 540 >> 2] * +HEAPF32[i2 + (i7 * 136 | 0) + 52 >> 2];
michael@0 33639 d15 = d11 * +HEAPF32[i3 + 544 >> 2] * +HEAPF32[i2 + (i7 * 136 | 0) + 56 >> 2];
michael@0 33640 i5 = i3 + 520 | 0;
michael@0 33641 HEAPF32[i5 >> 2] = d11 * +HEAPF32[i3 + 536 >> 2] * +HEAPF32[i2 + (i7 * 136 | 0) + 48 >> 2] + +HEAPF32[i5 >> 2];
michael@0 33642 i5 = i3 + 524 | 0;
michael@0 33643 HEAPF32[i5 >> 2] = d12 + +HEAPF32[i5 >> 2];
michael@0 33644 i5 = i3 + 528 | 0;
michael@0 33645 HEAPF32[i5 >> 2] = d15 + +HEAPF32[i5 >> 2];
michael@0 33646 }
michael@0 33647 } while (0);
michael@0 33648 if ((i4 | 0) == 0) {
michael@0 33649 return;
michael@0 33650 }
michael@0 33651 d11 = +HEAPF32[i4 + 336 >> 2];
michael@0 33652 d15 = -0.0 - +HEAPF32[i6 >> 2];
michael@0 33653 if (d11 == 0.0) {
michael@0 33654 return;
michael@0 33655 }
michael@0 33656 d12 = -0.0 - +HEAPF32[i2 + (i7 * 136 | 0) + 72 >> 2];
michael@0 33657 d17 = -0.0 - +HEAPF32[i2 + (i7 * 136 | 0) + 68 >> 2];
michael@0 33658 d13 = -0.0 - +HEAPF32[i2 + (i7 * 136 | 0) + 64 >> 2];
michael@0 33659 d16 = d11 * +HEAPF32[i2 + (i7 * 136 | 0) + 20 >> 2] * d15;
michael@0 33660 d9 = d11 * +HEAPF32[i2 + (i7 * 136 | 0) + 24 >> 2] * d15;
michael@0 33661 i6 = i4 + 504 | 0;
michael@0 33662 HEAPF32[i6 >> 2] = +HEAPF32[i6 >> 2] + d11 * +HEAPF32[i2 + (i7 * 136 | 0) + 16 >> 2] * d15;
michael@0 33663 i7 = i4 + 508 | 0;
michael@0 33664 HEAPF32[i7 >> 2] = d16 + +HEAPF32[i7 >> 2];
michael@0 33665 i7 = i4 + 512 | 0;
michael@0 33666 HEAPF32[i7 >> 2] = d9 + +HEAPF32[i7 >> 2];
michael@0 33667 d9 = +HEAPF32[i4 + 540 >> 2] * d15 * d17;
michael@0 33668 d17 = +HEAPF32[i4 + 544 >> 2] * d15 * d12;
michael@0 33669 i7 = i4 + 520 | 0;
michael@0 33670 HEAPF32[i7 >> 2] = +HEAPF32[i4 + 536 >> 2] * d15 * d13 + +HEAPF32[i7 >> 2];
michael@0 33671 i7 = i4 + 524 | 0;
michael@0 33672 HEAPF32[i7 >> 2] = d9 + +HEAPF32[i7 >> 2];
michael@0 33673 i7 = i4 + 528 | 0;
michael@0 33674 HEAPF32[i7 >> 2] = d17 + +HEAPF32[i7 >> 2];
michael@0 33675 return;
michael@0 33676 }
michael@0 33677 function __ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_S3_S3_PfRj(i1, i2, i3, i4, i5, i6) {
michael@0 33678 i1 = i1 | 0;
michael@0 33679 i2 = i2 | 0;
michael@0 33680 i3 = i3 | 0;
michael@0 33681 i4 = i4 | 0;
michael@0 33682 i5 = i5 | 0;
michael@0 33683 i6 = i6 | 0;
michael@0 33684 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, d13 = 0.0, i14 = 0, d15 = 0.0, d16 = 0.0, i17 = 0, d18 = 0.0, i19 = 0, d20 = 0.0, d21 = 0.0, i22 = 0, d23 = 0.0, d24 = 0.0, d25 = 0.0, i26 = 0, d27 = 0.0, d28 = 0.0, i29 = 0, d30 = 0.0, d31 = 0.0, i32 = 0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, i37 = 0, d38 = 0.0, d39 = 0.0, i40 = 0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, d49 = 0.0, i50 = 0;
michael@0 33685 i7 = STACKTOP;
michael@0 33686 STACKTOP = STACKTOP + 88 | 0;
michael@0 33687 i8 = i7 | 0;
michael@0 33688 i9 = i7 + 16 | 0;
michael@0 33689 i10 = i7 + 64 | 0;
michael@0 33690 i11 = i7 + 80 | 0;
michael@0 33691 HEAP32[i8 >> 2] = i1;
michael@0 33692 HEAP32[i8 + 4 >> 2] = i2;
michael@0 33693 HEAP32[i8 + 8 >> 2] = i3;
michael@0 33694 HEAP32[i8 + 12 >> 2] = i4;
michael@0 33695 i12 = i1 | 0;
michael@0 33696 d13 = +HEAPF32[i12 >> 2];
michael@0 33697 i14 = i4 | 0;
michael@0 33698 d15 = +HEAPF32[i14 >> 2];
michael@0 33699 d16 = d13 - d15;
michael@0 33700 i17 = i1 + 4 | 0;
michael@0 33701 d18 = +HEAPF32[i17 >> 2];
michael@0 33702 i19 = i4 + 4 | 0;
michael@0 33703 d20 = +HEAPF32[i19 >> 2];
michael@0 33704 d21 = d18 - d20;
michael@0 33705 i22 = i1 + 8 | 0;
michael@0 33706 d23 = +HEAPF32[i22 >> 2];
michael@0 33707 i1 = i4 + 8 | 0;
michael@0 33708 d24 = +HEAPF32[i1 >> 2];
michael@0 33709 d25 = d23 - d24;
michael@0 33710 HEAPF32[i9 >> 2] = d16;
michael@0 33711 HEAPF32[i9 + 4 >> 2] = d21;
michael@0 33712 HEAPF32[i9 + 8 >> 2] = d25;
michael@0 33713 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 33714 i26 = i2 | 0;
michael@0 33715 d27 = +HEAPF32[i26 >> 2];
michael@0 33716 d28 = d27 - d15;
michael@0 33717 i29 = i2 + 4 | 0;
michael@0 33718 d30 = +HEAPF32[i29 >> 2];
michael@0 33719 d31 = d30 - d20;
michael@0 33720 i32 = i2 + 8 | 0;
michael@0 33721 d33 = +HEAPF32[i32 >> 2];
michael@0 33722 d34 = d33 - d24;
michael@0 33723 HEAPF32[i9 + 16 >> 2] = d28;
michael@0 33724 HEAPF32[i9 + 20 >> 2] = d31;
michael@0 33725 HEAPF32[i9 + 24 >> 2] = d34;
michael@0 33726 HEAPF32[i9 + 28 >> 2] = 0.0;
michael@0 33727 i2 = i3 | 0;
michael@0 33728 d35 = +HEAPF32[i2 >> 2];
michael@0 33729 d36 = d35 - d15;
michael@0 33730 i37 = i3 + 4 | 0;
michael@0 33731 d38 = +HEAPF32[i37 >> 2];
michael@0 33732 d39 = d38 - d20;
michael@0 33733 i40 = i3 + 8 | 0;
michael@0 33734 d41 = +HEAPF32[i40 >> 2];
michael@0 33735 d42 = d41 - d24;
michael@0 33736 HEAPF32[i9 + 32 >> 2] = d36;
michael@0 33737 HEAPF32[i9 + 36 >> 2] = d39;
michael@0 33738 HEAPF32[i9 + 40 >> 2] = d42;
michael@0 33739 HEAPF32[i9 + 44 >> 2] = 0.0;
michael@0 33740 d43 = d16 * d31 * d42 + (d21 * d34 * d36 + d25 * d28 * d39 - d16 * d34 * d39 - d21 * d28 * d42) - d25 * d31 * d36;
michael@0 33741 d36 = d27 - d35;
michael@0 33742 d35 = d30 - d38;
michael@0 33743 d38 = d33 - d41;
michael@0 33744 d41 = d13 - d27;
michael@0 33745 d27 = d18 - d30;
michael@0 33746 d30 = d23 - d33;
michael@0 33747 if (d43 * (d23 * (d27 * d36 - d41 * d35) + (d13 * (d30 * d35 - d27 * d38) + d18 * (d41 * d38 - d30 * d36))) > 0.0 | d43 == 0.0) {
michael@0 33748 d44 = -1.0;
michael@0 33749 STACKTOP = i7;
michael@0 33750 return +d44;
michael@0 33751 }
michael@0 33752 _memset(i10 | 0, 0, 12);
michael@0 33753 HEAP32[i11 >> 2] = 0;
michael@0 33754 i3 = i10 | 0;
michael@0 33755 i45 = i10 + 4 | 0;
michael@0 33756 i46 = i10 + 8 | 0;
michael@0 33757 i10 = i5 + 12 | 0;
michael@0 33758 i47 = 0;
michael@0 33759 d36 = -1.0;
michael@0 33760 d30 = d21;
michael@0 33761 d21 = d25;
michael@0 33762 d25 = d16;
michael@0 33763 d16 = d15;
michael@0 33764 d15 = d20;
michael@0 33765 d20 = d24;
michael@0 33766 while (1) {
michael@0 33767 i48 = HEAP32[1312 + (i47 << 2) >> 2] | 0;
michael@0 33768 d24 = +HEAPF32[i9 + (i48 << 4) + 8 >> 2];
michael@0 33769 d38 = +HEAPF32[i9 + (i48 << 4) + 4 >> 2];
michael@0 33770 d41 = +HEAPF32[i9 + (i48 << 4) >> 2];
michael@0 33771 do {
michael@0 33772 if (d43 * (d20 * (d25 * d38 - d30 * d41) + (d16 * (d30 * d24 - d21 * d38) + d15 * (d21 * d41 - d25 * d24))) > 0.0) {
michael@0 33773 d18 = +__ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_S3_PfRj(HEAP32[i8 + (i47 << 2) >> 2] | 0, HEAP32[i8 + (i48 << 2) >> 2] | 0, i4, i3, i11);
michael@0 33774 if (!(d36 < 0.0 | d18 < d36)) {
michael@0 33775 d49 = d36;
michael@0 33776 break;
michael@0 33777 }
michael@0 33778 i50 = HEAP32[i11 >> 2] | 0;
michael@0 33779 HEAP32[i6 >> 2] = ((i50 & 2 | 0) == 0 ? 0 : 1 << i48) + (i50 << 1 & 8) + ((i50 & 1 | 0) == 0 ? 0 : 1 << i47);
michael@0 33780 HEAPF32[i5 + (i47 << 2) >> 2] = +HEAPF32[i3 >> 2];
michael@0 33781 HEAPF32[i5 + (i48 << 2) >> 2] = +HEAPF32[i45 >> 2];
michael@0 33782 HEAPF32[i5 + (HEAP32[1312 + (i48 << 2) >> 2] << 2) >> 2] = 0.0;
michael@0 33783 HEAPF32[i10 >> 2] = +HEAPF32[i46 >> 2];
michael@0 33784 d49 = d18;
michael@0 33785 } else {
michael@0 33786 d49 = d36;
michael@0 33787 }
michael@0 33788 } while (0);
michael@0 33789 i48 = i47 + 1 | 0;
michael@0 33790 if (i48 >>> 0 >= 3) {
michael@0 33791 break;
michael@0 33792 }
michael@0 33793 i47 = i48;
michael@0 33794 d36 = d49;
michael@0 33795 d30 = +HEAPF32[i9 + (i48 << 4) + 4 >> 2];
michael@0 33796 d21 = +HEAPF32[i9 + (i48 << 4) + 8 >> 2];
michael@0 33797 d25 = +HEAPF32[i9 + (i48 << 4) >> 2];
michael@0 33798 d16 = +HEAPF32[i14 >> 2];
michael@0 33799 d15 = +HEAPF32[i19 >> 2];
michael@0 33800 d20 = +HEAPF32[i1 >> 2];
michael@0 33801 }
michael@0 33802 if (d49 >= 0.0) {
michael@0 33803 d44 = d49;
michael@0 33804 STACKTOP = i7;
michael@0 33805 return +d44;
michael@0 33806 }
michael@0 33807 HEAP32[i6 >> 2] = 15;
michael@0 33808 d49 = +HEAPF32[i37 >> 2];
michael@0 33809 d20 = +HEAPF32[i32 >> 2];
michael@0 33810 d15 = +HEAPF32[i14 >> 2];
michael@0 33811 d16 = +HEAPF32[i40 >> 2];
michael@0 33812 d25 = +HEAPF32[i26 >> 2];
michael@0 33813 d21 = +HEAPF32[i19 >> 2];
michael@0 33814 d30 = +HEAPF32[i2 >> 2];
michael@0 33815 d36 = +HEAPF32[i1 >> 2];
michael@0 33816 d24 = +HEAPF32[i29 >> 2];
michael@0 33817 d41 = (d49 * d20 * d15 + d16 * d25 * d21 - d21 * d20 * d30 - d49 * d25 * d36 + d36 * d30 * d24 - d15 * d16 * d24) / d43;
michael@0 33818 HEAPF32[i5 >> 2] = d41;
michael@0 33819 d24 = +HEAPF32[i17 >> 2];
michael@0 33820 d16 = +HEAPF32[i40 >> 2];
michael@0 33821 d15 = +HEAPF32[i14 >> 2];
michael@0 33822 d30 = +HEAPF32[i22 >> 2];
michael@0 33823 d36 = +HEAPF32[i2 >> 2];
michael@0 33824 d25 = +HEAPF32[i19 >> 2];
michael@0 33825 d49 = +HEAPF32[i12 >> 2];
michael@0 33826 d20 = +HEAPF32[i1 >> 2];
michael@0 33827 d21 = +HEAPF32[i37 >> 2];
michael@0 33828 d38 = (d24 * d16 * d15 + d30 * d36 * d25 - d25 * d16 * d49 - d24 * d36 * d20 + d20 * d49 * d21 - d15 * d30 * d21) / d43;
michael@0 33829 HEAPF32[i5 + 4 >> 2] = d38;
michael@0 33830 d21 = +HEAPF32[i29 >> 2];
michael@0 33831 d30 = +HEAPF32[i22 >> 2];
michael@0 33832 d15 = +HEAPF32[i14 >> 2];
michael@0 33833 d49 = +HEAPF32[i32 >> 2];
michael@0 33834 d20 = +HEAPF32[i12 >> 2];
michael@0 33835 d36 = +HEAPF32[i19 >> 2];
michael@0 33836 d24 = +HEAPF32[i26 >> 2];
michael@0 33837 d16 = +HEAPF32[i1 >> 2];
michael@0 33838 d25 = +HEAPF32[i17 >> 2];
michael@0 33839 d18 = (d21 * d30 * d15 + d49 * d20 * d36 - d36 * d30 * d24 - d21 * d20 * d16 + d16 * d24 * d25 - d15 * d49 * d25) / d43;
michael@0 33840 HEAPF32[i5 + 8 >> 2] = d18;
michael@0 33841 HEAPF32[i10 >> 2] = 1.0 - (d41 + d38 + d18);
michael@0 33842 d44 = 0.0;
michael@0 33843 STACKTOP = i7;
michael@0 33844 return +d44;
michael@0 33845 }
michael@0 33846 function __ZN22SphereTriangleDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i1, i2, i3, i4, i5) {
michael@0 33847 i1 = i1 | 0;
michael@0 33848 i2 = i2 | 0;
michael@0 33849 i3 = i3 | 0;
michael@0 33850 i4 = i4 | 0;
michael@0 33851 i5 = i5 | 0;
michael@0 33852 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, d15 = 0.0, i16 = 0, d17 = 0.0, i18 = 0, d19 = 0.0, i20 = 0, d21 = 0.0, d22 = 0.0, i23 = 0, d24 = 0.0, d25 = 0.0, i26 = 0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, i35 = 0, d36 = 0.0, i37 = 0, d38 = 0.0, i39 = 0, d40 = 0.0, i41 = 0, d42 = 0.0, i43 = 0, d44 = 0.0, i45 = 0, d46 = 0.0;
michael@0 33853 i4 = STACKTOP;
michael@0 33854 STACKTOP = STACKTOP + 168 | 0;
michael@0 33855 i6 = i4 | 0;
michael@0 33856 i7 = i4 + 16 | 0;
michael@0 33857 i8 = i4 + 32 | 0;
michael@0 33858 i9 = i4 + 40 | 0;
michael@0 33859 i10 = i4 + 104 | 0;
michael@0 33860 i11 = i4 + 120 | 0;
michael@0 33861 i12 = i4 + 136 | 0;
michael@0 33862 i13 = i4 + 152 | 0;
michael@0 33863 HEAPF32[i8 >> 2] = 0.0;
michael@0 33864 i14 = i2 + 112 | 0;
michael@0 33865 d15 = +HEAPF32[i2 + 48 >> 2] - +HEAPF32[i14 >> 2];
michael@0 33866 i16 = i2 + 116 | 0;
michael@0 33867 d17 = +HEAPF32[i2 + 52 >> 2] - +HEAPF32[i16 >> 2];
michael@0 33868 i18 = i2 + 120 | 0;
michael@0 33869 d19 = +HEAPF32[i2 + 56 >> 2] - +HEAPF32[i18 >> 2];
michael@0 33870 i20 = i2 + 64 | 0;
michael@0 33871 d21 = +HEAPF32[i20 >> 2];
michael@0 33872 d22 = +HEAPF32[i2 >> 2];
michael@0 33873 i23 = i2 + 80 | 0;
michael@0 33874 d24 = +HEAPF32[i23 >> 2];
michael@0 33875 d25 = +HEAPF32[i2 + 16 >> 2];
michael@0 33876 i26 = i2 + 96 | 0;
michael@0 33877 d27 = +HEAPF32[i26 >> 2];
michael@0 33878 d28 = +HEAPF32[i2 + 32 >> 2];
michael@0 33879 d29 = +HEAPF32[i2 + 4 >> 2];
michael@0 33880 d30 = +HEAPF32[i2 + 20 >> 2];
michael@0 33881 d31 = +HEAPF32[i2 + 36 >> 2];
michael@0 33882 d32 = +HEAPF32[i2 + 8 >> 2];
michael@0 33883 d33 = +HEAPF32[i2 + 24 >> 2];
michael@0 33884 d34 = +HEAPF32[i2 + 40 >> 2];
michael@0 33885 i35 = i2 + 68 | 0;
michael@0 33886 d36 = +HEAPF32[i35 >> 2];
michael@0 33887 i37 = i2 + 84 | 0;
michael@0 33888 d38 = +HEAPF32[i37 >> 2];
michael@0 33889 i39 = i2 + 100 | 0;
michael@0 33890 d40 = +HEAPF32[i39 >> 2];
michael@0 33891 i41 = i2 + 72 | 0;
michael@0 33892 d42 = +HEAPF32[i41 >> 2];
michael@0 33893 i43 = i2 + 88 | 0;
michael@0 33894 d44 = +HEAPF32[i43 >> 2];
michael@0 33895 i45 = i2 + 104 | 0;
michael@0 33896 d46 = +HEAPF32[i45 >> 2];
michael@0 33897 HEAPF32[i9 >> 2] = d21 * d22 + d24 * d25 + d27 * d28;
michael@0 33898 HEAPF32[i9 + 4 >> 2] = d21 * d29 + d24 * d30 + d27 * d31;
michael@0 33899 HEAPF32[i9 + 8 >> 2] = d21 * d32 + d24 * d33 + d27 * d34;
michael@0 33900 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 33901 HEAPF32[i9 + 16 >> 2] = d22 * d36 + d25 * d38 + d28 * d40;
michael@0 33902 HEAPF32[i9 + 20 >> 2] = d29 * d36 + d30 * d38 + d31 * d40;
michael@0 33903 HEAPF32[i9 + 24 >> 2] = d32 * d36 + d33 * d38 + d34 * d40;
michael@0 33904 HEAPF32[i9 + 28 >> 2] = 0.0;
michael@0 33905 HEAPF32[i9 + 32 >> 2] = d22 * d42 + d25 * d44 + d28 * d46;
michael@0 33906 HEAPF32[i9 + 36 >> 2] = d29 * d42 + d30 * d44 + d31 * d46;
michael@0 33907 HEAPF32[i9 + 40 >> 2] = d32 * d42 + d33 * d44 + d34 * d46;
michael@0 33908 HEAPF32[i9 + 44 >> 2] = 0.0;
michael@0 33909 HEAPF32[i9 + 48 >> 2] = d15 * d21 + d17 * d24 + d19 * d27;
michael@0 33910 HEAPF32[i9 + 52 >> 2] = d15 * d36 + d17 * d38 + d19 * d40;
michael@0 33911 HEAPF32[i9 + 56 >> 2] = d15 * d42 + d17 * d44 + d19 * d46;
michael@0 33912 HEAPF32[i9 + 60 >> 2] = 0.0;
michael@0 33913 if (!(__ZN22SphereTriangleDetector7collideERK9btVector3RS0_S3_RfS4_f(i1, i9 + 48 | 0, i6, i7, i8, 0, +HEAPF32[i1 + 12 >> 2]) | 0)) {
michael@0 33914 STACKTOP = i4;
michael@0 33915 return;
michael@0 33916 }
michael@0 33917 if (i5) {
michael@0 33918 d46 = +HEAPF32[i20 >> 2];
michael@0 33919 d19 = +HEAPF32[i7 >> 2];
michael@0 33920 d44 = +HEAPF32[i35 >> 2];
michael@0 33921 d17 = +HEAPF32[i7 + 4 >> 2];
michael@0 33922 d42 = +HEAPF32[i41 >> 2];
michael@0 33923 d15 = +HEAPF32[i7 + 8 >> 2];
michael@0 33924 d40 = d46 * d19 + d44 * d17 + d42 * d15;
michael@0 33925 d38 = +HEAPF32[i23 >> 2];
michael@0 33926 d36 = +HEAPF32[i37 >> 2];
michael@0 33927 d27 = +HEAPF32[i43 >> 2];
michael@0 33928 d24 = d19 * d38 + d17 * d36 + d15 * d27;
michael@0 33929 d21 = +HEAPF32[i26 >> 2];
michael@0 33930 d34 = +HEAPF32[i39 >> 2];
michael@0 33931 d33 = +HEAPF32[i45 >> 2];
michael@0 33932 d32 = d19 * d21 + d17 * d34 + d15 * d33;
michael@0 33933 HEAPF32[i10 >> 2] = -0.0 - d40;
michael@0 33934 HEAPF32[i10 + 4 >> 2] = -0.0 - d24;
michael@0 33935 HEAPF32[i10 + 8 >> 2] = -0.0 - d32;
michael@0 33936 HEAPF32[i10 + 12 >> 2] = 0.0;
michael@0 33937 d15 = +HEAPF32[i6 >> 2];
michael@0 33938 d17 = +HEAPF32[i6 + 4 >> 2];
michael@0 33939 d19 = +HEAPF32[i6 + 8 >> 2];
michael@0 33940 d31 = +HEAPF32[i8 >> 2];
michael@0 33941 d30 = +HEAPF32[i16 >> 2] + (d38 * d15 + d36 * d17 + d27 * d19) + d24 * d31;
michael@0 33942 d24 = d21 * d15 + d34 * d17 + d33 * d19 + +HEAPF32[i18 >> 2] + d32 * d31;
michael@0 33943 HEAPF32[i11 >> 2] = +HEAPF32[i14 >> 2] + (d46 * d15 + d44 * d17 + d42 * d19) + d40 * d31;
michael@0 33944 HEAPF32[i11 + 4 >> 2] = d30;
michael@0 33945 HEAPF32[i11 + 8 >> 2] = d24;
michael@0 33946 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 33947 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 15](i3, i10, i11, d31);
michael@0 33948 STACKTOP = i4;
michael@0 33949 return;
michael@0 33950 } else {
michael@0 33951 i11 = HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] | 0;
michael@0 33952 d31 = +HEAPF32[i20 >> 2];
michael@0 33953 d24 = +HEAPF32[i7 >> 2];
michael@0 33954 d30 = +HEAPF32[i35 >> 2];
michael@0 33955 d40 = +HEAPF32[i7 + 4 >> 2];
michael@0 33956 d19 = +HEAPF32[i41 >> 2];
michael@0 33957 d42 = +HEAPF32[i7 + 8 >> 2];
michael@0 33958 d17 = +HEAPF32[i23 >> 2];
michael@0 33959 d44 = +HEAPF32[i37 >> 2];
michael@0 33960 d15 = +HEAPF32[i43 >> 2];
michael@0 33961 d46 = +HEAPF32[i26 >> 2];
michael@0 33962 d32 = +HEAPF32[i39 >> 2];
michael@0 33963 d33 = +HEAPF32[i45 >> 2];
michael@0 33964 HEAPF32[i12 >> 2] = d31 * d24 + d30 * d40 + d19 * d42;
michael@0 33965 HEAPF32[i12 + 4 >> 2] = d24 * d17 + d40 * d44 + d42 * d15;
michael@0 33966 HEAPF32[i12 + 8 >> 2] = d24 * d46 + d40 * d32 + d42 * d33;
michael@0 33967 HEAPF32[i12 + 12 >> 2] = 0.0;
michael@0 33968 d42 = +HEAPF32[i6 >> 2];
michael@0 33969 d40 = +HEAPF32[i6 + 4 >> 2];
michael@0 33970 d24 = +HEAPF32[i6 + 8 >> 2];
michael@0 33971 d34 = +HEAPF32[i16 >> 2] + (d17 * d42 + d44 * d40 + d15 * d24);
michael@0 33972 d15 = d46 * d42 + d32 * d40 + d33 * d24 + +HEAPF32[i18 >> 2];
michael@0 33973 HEAPF32[i13 >> 2] = +HEAPF32[i14 >> 2] + (d31 * d42 + d30 * d40 + d19 * d24);
michael@0 33974 HEAPF32[i13 + 4 >> 2] = d34;
michael@0 33975 HEAPF32[i13 + 8 >> 2] = d15;
michael@0 33976 HEAPF32[i13 + 12 >> 2] = 0.0;
michael@0 33977 FUNCTION_TABLE_viiif[i11 & 15](i3, i12, i13, +HEAPF32[i8 >> 2]);
michael@0 33978 STACKTOP = i4;
michael@0 33979 return;
michael@0 33980 }
michael@0 33981 }
michael@0 33982 function __ZN20btConvexHullInternal12findMaxAngleEbPKNS_6VertexERKNS_7Point32ERKNS_7Point64ES8_RNS_10Rational64E(i1, i2, i3, i4, i5, i6, i7) {
michael@0 33983 i1 = i1 | 0;
michael@0 33984 i2 = i2 | 0;
michael@0 33985 i3 = i3 | 0;
michael@0 33986 i4 = i4 | 0;
michael@0 33987 i5 = i5 | 0;
michael@0 33988 i6 = i6 | 0;
michael@0 33989 i7 = i7 | 0;
michael@0 33990 var i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0;
michael@0 33991 i8 = STACKTOP;
michael@0 33992 STACKTOP = STACKTOP + 40 | 0;
michael@0 33993 i9 = i8 | 0;
michael@0 33994 i10 = i8 + 16 | 0;
michael@0 33995 i11 = i3 + 8 | 0;
michael@0 33996 i12 = HEAP32[i11 >> 2] | 0;
michael@0 33997 if ((i12 | 0) == 0) {
michael@0 33998 i13 = 0;
michael@0 33999 STACKTOP = i8;
michael@0 34000 return i13 | 0;
michael@0 34001 }
michael@0 34002 i14 = i1 + 100 | 0;
michael@0 34003 i1 = i3 + 88 | 0;
michael@0 34004 i15 = i3 + 92 | 0;
michael@0 34005 i16 = i3 + 96 | 0;
michael@0 34006 i3 = i9 | 0;
michael@0 34007 i17 = i9 + 4 | 0;
michael@0 34008 i18 = i9 + 8 | 0;
michael@0 34009 i19 = i9 + 12 | 0;
michael@0 34010 i20 = i6 | 0;
michael@0 34011 i21 = i6 + 8 | 0;
michael@0 34012 i22 = i6 + 16 | 0;
michael@0 34013 i6 = i5 | 0;
michael@0 34014 i23 = i5 + 8 | 0;
michael@0 34015 i24 = i5 + 16 | 0;
michael@0 34016 i5 = i10 + 16 | 0;
michael@0 34017 i25 = i10 | 0;
michael@0 34018 i26 = i10 + 8 | 0;
michael@0 34019 i27 = i7;
michael@0 34020 i28 = i10;
michael@0 34021 i29 = 0;
michael@0 34022 i30 = i12;
michael@0 34023 while (1) {
michael@0 34024 do {
michael@0 34025 if ((HEAP32[i30 + 20 >> 2] | 0) > (HEAP32[i14 >> 2] | 0)) {
michael@0 34026 i12 = HEAP32[i30 + 12 >> 2] | 0;
michael@0 34027 i31 = (HEAP32[i12 + 88 >> 2] | 0) - (HEAP32[i1 >> 2] | 0) | 0;
michael@0 34028 i32 = (HEAP32[i12 + 92 >> 2] | 0) - (HEAP32[i15 >> 2] | 0) | 0;
michael@0 34029 i33 = (HEAP32[i12 + 96 >> 2] | 0) - (HEAP32[i16 >> 2] | 0) | 0;
michael@0 34030 HEAP32[i3 >> 2] = i31;
michael@0 34031 HEAP32[i17 >> 2] = i32;
michael@0 34032 HEAP32[i18 >> 2] = i33;
michael@0 34033 HEAP32[i19 >> 2] = -1;
michael@0 34034 i12 = i31;
michael@0 34035 i34 = (i31 | 0) < 0 ? -1 : 0;
michael@0 34036 i31 = ___muldi3(HEAP32[i20 >> 2] | 0, HEAP32[i20 + 4 >> 2] | 0, i12, i34) | 0;
michael@0 34037 i35 = tempRet0;
michael@0 34038 i36 = i32;
michael@0 34039 i37 = (i32 | 0) < 0 ? -1 : 0;
michael@0 34040 i32 = ___muldi3(HEAP32[i21 >> 2] | 0, HEAP32[i21 + 4 >> 2] | 0, i36, i37) | 0;
michael@0 34041 i38 = _i64Add(i32, tempRet0, i31, i35) | 0;
michael@0 34042 i35 = tempRet0;
michael@0 34043 i31 = i33;
michael@0 34044 i32 = (i33 | 0) < 0 ? -1 : 0;
michael@0 34045 i33 = ___muldi3(HEAP32[i22 >> 2] | 0, HEAP32[i22 + 4 >> 2] | 0, i31, i32) | 0;
michael@0 34046 i39 = _i64Add(i38, i35, i33, tempRet0) | 0;
michael@0 34047 i33 = tempRet0;
michael@0 34048 i35 = ___muldi3(HEAP32[i6 >> 2] | 0, HEAP32[i6 + 4 >> 2] | 0, i12, i34) | 0;
michael@0 34049 i34 = tempRet0;
michael@0 34050 i12 = ___muldi3(HEAP32[i23 >> 2] | 0, HEAP32[i23 + 4 >> 2] | 0, i36, i37) | 0;
michael@0 34051 i37 = _i64Add(i12, tempRet0, i35, i34) | 0;
michael@0 34052 i34 = tempRet0;
michael@0 34053 i35 = ___muldi3(HEAP32[i24 >> 2] | 0, HEAP32[i24 + 4 >> 2] | 0, i31, i32) | 0;
michael@0 34054 i32 = _i64Add(i37, i34, i35, tempRet0) | 0;
michael@0 34055 i35 = tempRet0;
michael@0 34056 i34 = 0;
michael@0 34057 do {
michael@0 34058 if ((i33 | 0) > (i34 | 0) | (i33 | 0) == (i34 | 0) & i39 >>> 0 > 0 >>> 0) {
michael@0 34059 HEAP32[i5 >> 2] = 1;
michael@0 34060 HEAP32[i25 >> 2] = i39;
michael@0 34061 HEAP32[i25 + 4 >> 2] = i33;
michael@0 34062 i40 = 1;
michael@0 34063 } else {
michael@0 34064 i37 = 0;
michael@0 34065 if ((i33 | 0) < (i37 | 0) | (i33 | 0) == (i37 | 0) & i39 >>> 0 < 0 >>> 0) {
michael@0 34066 HEAP32[i5 >> 2] = -1;
michael@0 34067 i37 = _i64Subtract(0, 0, i39, i33) | 0;
michael@0 34068 HEAP32[i25 >> 2] = i37;
michael@0 34069 HEAP32[i25 + 4 >> 2] = tempRet0;
michael@0 34070 i40 = -1;
michael@0 34071 break;
michael@0 34072 } else {
michael@0 34073 HEAP32[i5 >> 2] = 0;
michael@0 34074 HEAP32[i25 >> 2] = 0;
michael@0 34075 HEAP32[i25 + 4 >> 2] = 0;
michael@0 34076 i40 = 0;
michael@0 34077 break;
michael@0 34078 }
michael@0 34079 }
michael@0 34080 } while (0);
michael@0 34081 i33 = 0;
michael@0 34082 if ((i35 | 0) > (i33 | 0) | (i35 | 0) == (i33 | 0) & i32 >>> 0 > 0 >>> 0) {
michael@0 34083 HEAP32[i26 >> 2] = i32;
michael@0 34084 HEAP32[i26 + 4 >> 2] = i35;
michael@0 34085 } else {
michael@0 34086 i33 = 0;
michael@0 34087 if ((i35 | 0) < (i33 | 0) | (i35 | 0) == (i33 | 0) & i32 >>> 0 < 0 >>> 0) {
michael@0 34088 i33 = -i40 | 0;
michael@0 34089 HEAP32[i5 >> 2] = i33;
michael@0 34090 i39 = _i64Subtract(0, 0, i32, i35) | 0;
michael@0 34091 i41 = i33;
michael@0 34092 i42 = 0;
michael@0 34093 i43 = tempRet0;
michael@0 34094 i44 = i39;
michael@0 34095 } else {
michael@0 34096 i41 = i40;
michael@0 34097 i42 = 1;
michael@0 34098 i43 = 0;
michael@0 34099 i44 = 0;
michael@0 34100 }
michael@0 34101 HEAP32[i26 >> 2] = i44;
michael@0 34102 HEAP32[i26 + 4 >> 2] = i43;
michael@0 34103 if ((i41 | 0) == 0 & i42) {
michael@0 34104 i45 = i29;
michael@0 34105 break;
michael@0 34106 }
michael@0 34107 }
michael@0 34108 if ((i29 | 0) == 0) {
michael@0 34109 HEAP32[i27 >> 2] = HEAP32[i28 >> 2];
michael@0 34110 HEAP32[i27 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 34111 HEAP32[i27 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 34112 HEAP32[i27 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 34113 HEAP32[i27 + 16 >> 2] = HEAP32[i28 + 16 >> 2];
michael@0 34114 i45 = i30;
michael@0 34115 break;
michael@0 34116 }
michael@0 34117 i39 = __ZNK20btConvexHullInternal10Rational647compareERKS0_(i10, i7) | 0;
michael@0 34118 if ((i39 | 0) < 0) {
michael@0 34119 HEAP32[i27 >> 2] = HEAP32[i28 >> 2];
michael@0 34120 HEAP32[i27 + 4 >> 2] = HEAP32[i28 + 4 >> 2];
michael@0 34121 HEAP32[i27 + 8 >> 2] = HEAP32[i28 + 8 >> 2];
michael@0 34122 HEAP32[i27 + 12 >> 2] = HEAP32[i28 + 12 >> 2];
michael@0 34123 HEAP32[i27 + 16 >> 2] = HEAP32[i28 + 16 >> 2];
michael@0 34124 i45 = i30;
michael@0 34125 break;
michael@0 34126 }
michael@0 34127 if ((i39 | 0) != 0) {
michael@0 34128 i45 = i29;
michael@0 34129 break;
michael@0 34130 }
michael@0 34131 i45 = (__ZN20btConvexHullInternal14getOrientationEPKNS_4EdgeES2_RKNS_7Point32ES5_(i29, i30, i4, i9) | 0) == 2 ^ i2 ? i29 : i30;
michael@0 34132 } else {
michael@0 34133 i45 = i29;
michael@0 34134 }
michael@0 34135 } while (0);
michael@0 34136 i39 = HEAP32[i30 >> 2] | 0;
michael@0 34137 if ((i39 | 0) == (HEAP32[i11 >> 2] | 0)) {
michael@0 34138 i13 = i45;
michael@0 34139 break;
michael@0 34140 } else {
michael@0 34141 i29 = i45;
michael@0 34142 i30 = i39;
michael@0 34143 }
michael@0 34144 }
michael@0 34145 STACKTOP = i8;
michael@0 34146 return i13 | 0;
michael@0 34147 }
michael@0 34148 function ___udivmoddi4(i1, i2, i3, i4, i5) {
michael@0 34149 i1 = i1 | 0;
michael@0 34150 i2 = i2 | 0;
michael@0 34151 i3 = i3 | 0;
michael@0 34152 i4 = i4 | 0;
michael@0 34153 i5 = i5 | 0;
michael@0 34154 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0;
michael@0 34155 i6 = i1;
michael@0 34156 i7 = i2;
michael@0 34157 i8 = i7;
michael@0 34158 i9 = i3;
michael@0 34159 i10 = i4;
michael@0 34160 i11 = i10;
michael@0 34161 if ((i8 | 0) == 0) {
michael@0 34162 i12 = (i5 | 0) != 0;
michael@0 34163 if ((i11 | 0) == 0) {
michael@0 34164 if (i12) {
michael@0 34165 HEAP32[i5 >> 2] = (i6 >>> 0) % (i9 >>> 0);
michael@0 34166 HEAP32[i5 + 4 >> 2] = 0;
michael@0 34167 }
michael@0 34168 i13 = 0;
michael@0 34169 i14 = (i6 >>> 0) / (i9 >>> 0) >>> 0;
michael@0 34170 return (tempRet0 = i13, i14) | 0;
michael@0 34171 } else {
michael@0 34172 if (!i12) {
michael@0 34173 i13 = 0;
michael@0 34174 i14 = 0;
michael@0 34175 return (tempRet0 = i13, i14) | 0;
michael@0 34176 }
michael@0 34177 HEAP32[i5 >> 2] = i1 | 0;
michael@0 34178 HEAP32[i5 + 4 >> 2] = i2 & 0;
michael@0 34179 i13 = 0;
michael@0 34180 i14 = 0;
michael@0 34181 return (tempRet0 = i13, i14) | 0;
michael@0 34182 }
michael@0 34183 }
michael@0 34184 i12 = (i11 | 0) == 0;
michael@0 34185 do {
michael@0 34186 if ((i9 | 0) == 0) {
michael@0 34187 if (i12) {
michael@0 34188 if ((i5 | 0) != 0) {
michael@0 34189 HEAP32[i5 >> 2] = (i8 >>> 0) % (i9 >>> 0);
michael@0 34190 HEAP32[i5 + 4 >> 2] = 0;
michael@0 34191 }
michael@0 34192 i13 = 0;
michael@0 34193 i14 = (i8 >>> 0) / (i9 >>> 0) >>> 0;
michael@0 34194 return (tempRet0 = i13, i14) | 0;
michael@0 34195 }
michael@0 34196 if ((i6 | 0) == 0) {
michael@0 34197 if ((i5 | 0) != 0) {
michael@0 34198 HEAP32[i5 >> 2] = 0;
michael@0 34199 HEAP32[i5 + 4 >> 2] = (i8 >>> 0) % (i11 >>> 0);
michael@0 34200 }
michael@0 34201 i13 = 0;
michael@0 34202 i14 = (i8 >>> 0) / (i11 >>> 0) >>> 0;
michael@0 34203 return (tempRet0 = i13, i14) | 0;
michael@0 34204 }
michael@0 34205 i15 = i11 - 1 | 0;
michael@0 34206 if ((i15 & i11 | 0) == 0) {
michael@0 34207 if ((i5 | 0) != 0) {
michael@0 34208 HEAP32[i5 >> 2] = i1 | 0;
michael@0 34209 HEAP32[i5 + 4 >> 2] = i15 & i8 | i2 & 0;
michael@0 34210 }
michael@0 34211 i13 = 0;
michael@0 34212 i14 = i8 >>> ((_llvm_cttz_i32(i11 | 0) | 0) >>> 0);
michael@0 34213 return (tempRet0 = i13, i14) | 0;
michael@0 34214 }
michael@0 34215 i15 = (_llvm_ctlz_i32(i11 | 0) | 0) - (_llvm_ctlz_i32(i8 | 0) | 0) | 0;
michael@0 34216 if (i15 >>> 0 <= 30) {
michael@0 34217 i16 = i15 + 1 | 0;
michael@0 34218 i17 = 31 - i15 | 0;
michael@0 34219 i18 = i16;
michael@0 34220 i19 = i8 << i17 | i6 >>> (i16 >>> 0);
michael@0 34221 i20 = i8 >>> (i16 >>> 0);
michael@0 34222 i21 = 0;
michael@0 34223 i22 = i6 << i17;
michael@0 34224 break;
michael@0 34225 }
michael@0 34226 if ((i5 | 0) == 0) {
michael@0 34227 i13 = 0;
michael@0 34228 i14 = 0;
michael@0 34229 return (tempRet0 = i13, i14) | 0;
michael@0 34230 }
michael@0 34231 HEAP32[i5 >> 2] = i1 | 0;
michael@0 34232 HEAP32[i5 + 4 >> 2] = i7 | i2 & 0;
michael@0 34233 i13 = 0;
michael@0 34234 i14 = 0;
michael@0 34235 return (tempRet0 = i13, i14) | 0;
michael@0 34236 } else {
michael@0 34237 if (!i12) {
michael@0 34238 i17 = (_llvm_ctlz_i32(i11 | 0) | 0) - (_llvm_ctlz_i32(i8 | 0) | 0) | 0;
michael@0 34239 if (i17 >>> 0 <= 31) {
michael@0 34240 i16 = i17 + 1 | 0;
michael@0 34241 i15 = 31 - i17 | 0;
michael@0 34242 i23 = i17 - 31 >> 31;
michael@0 34243 i18 = i16;
michael@0 34244 i19 = i6 >>> (i16 >>> 0) & i23 | i8 << i15;
michael@0 34245 i20 = i8 >>> (i16 >>> 0) & i23;
michael@0 34246 i21 = 0;
michael@0 34247 i22 = i6 << i15;
michael@0 34248 break;
michael@0 34249 }
michael@0 34250 if ((i5 | 0) == 0) {
michael@0 34251 i13 = 0;
michael@0 34252 i14 = 0;
michael@0 34253 return (tempRet0 = i13, i14) | 0;
michael@0 34254 }
michael@0 34255 HEAP32[i5 >> 2] = i1 | 0;
michael@0 34256 HEAP32[i5 + 4 >> 2] = i7 | i2 & 0;
michael@0 34257 i13 = 0;
michael@0 34258 i14 = 0;
michael@0 34259 return (tempRet0 = i13, i14) | 0;
michael@0 34260 }
michael@0 34261 i15 = i9 - 1 | 0;
michael@0 34262 if ((i15 & i9 | 0) != 0) {
michael@0 34263 i23 = (_llvm_ctlz_i32(i9 | 0) | 0) + 33 - (_llvm_ctlz_i32(i8 | 0) | 0) | 0;
michael@0 34264 i16 = 64 - i23 | 0;
michael@0 34265 i17 = 32 - i23 | 0;
michael@0 34266 i24 = i17 >> 31;
michael@0 34267 i25 = i23 - 32 | 0;
michael@0 34268 i26 = i25 >> 31;
michael@0 34269 i18 = i23;
michael@0 34270 i19 = i17 - 1 >> 31 & i8 >>> (i25 >>> 0) | (i8 << i17 | i6 >>> (i23 >>> 0)) & i26;
michael@0 34271 i20 = i26 & i8 >>> (i23 >>> 0);
michael@0 34272 i21 = i6 << i16 & i24;
michael@0 34273 i22 = (i8 << i16 | i6 >>> (i25 >>> 0)) & i24 | i6 << i17 & i23 - 33 >> 31;
michael@0 34274 break;
michael@0 34275 }
michael@0 34276 if ((i5 | 0) != 0) {
michael@0 34277 HEAP32[i5 >> 2] = i15 & i6;
michael@0 34278 HEAP32[i5 + 4 >> 2] = 0;
michael@0 34279 }
michael@0 34280 if ((i9 | 0) == 1) {
michael@0 34281 i13 = i7 | i2 & 0;
michael@0 34282 i14 = i1 | 0 | 0;
michael@0 34283 return (tempRet0 = i13, i14) | 0;
michael@0 34284 } else {
michael@0 34285 i15 = _llvm_cttz_i32(i9 | 0) | 0;
michael@0 34286 i13 = i8 >>> (i15 >>> 0) | 0;
michael@0 34287 i14 = i8 << 32 - i15 | i6 >>> (i15 >>> 0) | 0;
michael@0 34288 return (tempRet0 = i13, i14) | 0;
michael@0 34289 }
michael@0 34290 }
michael@0 34291 } while (0);
michael@0 34292 if ((i18 | 0) == 0) {
michael@0 34293 i27 = i22;
michael@0 34294 i28 = i21;
michael@0 34295 i29 = i20;
michael@0 34296 i30 = i19;
michael@0 34297 i31 = 0;
michael@0 34298 i32 = 0;
michael@0 34299 } else {
michael@0 34300 i6 = i3 | 0 | 0;
michael@0 34301 i3 = i10 | i4 & 0;
michael@0 34302 i4 = _i64Add(i6, i3, -1, -1) | 0;
michael@0 34303 i10 = tempRet0;
michael@0 34304 i8 = i22;
michael@0 34305 i22 = i21;
michael@0 34306 i21 = i20;
michael@0 34307 i20 = i19;
michael@0 34308 i19 = i18;
michael@0 34309 i18 = 0;
michael@0 34310 while (1) {
michael@0 34311 i33 = i22 >>> 31 | i8 << 1;
michael@0 34312 i34 = i18 | i22 << 1;
michael@0 34313 i9 = i20 << 1 | i8 >>> 31 | 0;
michael@0 34314 i1 = i20 >>> 31 | i21 << 1 | 0;
michael@0 34315 _i64Subtract(i4, i10, i9, i1) | 0;
michael@0 34316 i2 = tempRet0;
michael@0 34317 i7 = i2 >> 31 | ((i2 | 0) < 0 ? -1 : 0) << 1;
michael@0 34318 i35 = i7 & 1;
michael@0 34319 i36 = _i64Subtract(i9, i1, i7 & i6, (((i2 | 0) < 0 ? -1 : 0) >> 31 | ((i2 | 0) < 0 ? -1 : 0) << 1) & i3) | 0;
michael@0 34320 i37 = tempRet0;
michael@0 34321 i2 = i19 - 1 | 0;
michael@0 34322 if ((i2 | 0) == 0) {
michael@0 34323 break;
michael@0 34324 } else {
michael@0 34325 i8 = i33;
michael@0 34326 i22 = i34;
michael@0 34327 i21 = i37;
michael@0 34328 i20 = i36;
michael@0 34329 i19 = i2;
michael@0 34330 i18 = i35;
michael@0 34331 }
michael@0 34332 }
michael@0 34333 i27 = i33;
michael@0 34334 i28 = i34;
michael@0 34335 i29 = i37;
michael@0 34336 i30 = i36;
michael@0 34337 i31 = 0;
michael@0 34338 i32 = i35;
michael@0 34339 }
michael@0 34340 i35 = i28;
michael@0 34341 i28 = 0;
michael@0 34342 if ((i5 | 0) != 0) {
michael@0 34343 HEAP32[i5 >> 2] = i30;
michael@0 34344 HEAP32[i5 + 4 >> 2] = i29;
michael@0 34345 }
michael@0 34346 i13 = (i35 | 0) >>> 31 | (i27 | i28) << 1 | (i28 << 1 | i35 >>> 31) & 0 | i31;
michael@0 34347 i14 = (i35 << 1 | 0 >>> 31) & -2 | i32;
michael@0 34348 return (tempRet0 = i13, i14) | 0;
michael@0 34349 }
michael@0 34350 function __ZN11btRigidBody18proceedToTransformERK11btTransform(i1, i2) {
michael@0 34351 i1 = i1 | 0;
michael@0 34352 i2 = i2 | 0;
michael@0 34353 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0;
michael@0 34354 i3 = i1 + 68 | 0;
michael@0 34355 if ((HEAP32[i1 + 204 >> 2] & 3 | 0) == 0) {
michael@0 34356 i4 = i3;
michael@0 34357 i5 = i2;
michael@0 34358 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 34359 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 34360 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 34361 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 34362 i4 = i1 + 84 | 0;
michael@0 34363 i6 = i2 + 16 | 0;
michael@0 34364 HEAP32[i4 >> 2] = HEAP32[i6 >> 2];
michael@0 34365 HEAP32[i4 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 34366 HEAP32[i4 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 34367 HEAP32[i4 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 34368 i4 = i1 + 100 | 0;
michael@0 34369 i7 = i2 + 32 | 0;
michael@0 34370 HEAP32[i4 >> 2] = HEAP32[i7 >> 2];
michael@0 34371 HEAP32[i4 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 34372 HEAP32[i4 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 34373 HEAP32[i4 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 34374 i4 = i1 + 116 | 0;
michael@0 34375 i8 = i2 + 48 | 0;
michael@0 34376 HEAP32[i4 >> 2] = HEAP32[i8 >> 2];
michael@0 34377 HEAP32[i4 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 34378 HEAP32[i4 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 34379 HEAP32[i4 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 34380 i9 = i1 + 4 | 0;
michael@0 34381 i10 = i5;
michael@0 34382 i11 = i1 + 20 | 0;
michael@0 34383 i12 = i6;
michael@0 34384 i13 = i1 + 36 | 0;
michael@0 34385 i14 = i7;
michael@0 34386 i15 = i1 + 52 | 0;
michael@0 34387 i16 = i8;
michael@0 34388 } else {
michael@0 34389 i8 = i3;
michael@0 34390 i3 = i1 + 4 | 0;
michael@0 34391 HEAP32[i8 >> 2] = HEAP32[i3 >> 2];
michael@0 34392 HEAP32[i8 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 34393 HEAP32[i8 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 34394 HEAP32[i8 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 34395 i8 = i1 + 84 | 0;
michael@0 34396 i7 = i1 + 20 | 0;
michael@0 34397 HEAP32[i8 >> 2] = HEAP32[i7 >> 2];
michael@0 34398 HEAP32[i8 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 34399 HEAP32[i8 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 34400 HEAP32[i8 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 34401 i8 = i1 + 100 | 0;
michael@0 34402 i6 = i1 + 36 | 0;
michael@0 34403 HEAP32[i8 >> 2] = HEAP32[i6 >> 2];
michael@0 34404 HEAP32[i8 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 34405 HEAP32[i8 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 34406 HEAP32[i8 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 34407 i8 = i1 + 116 | 0;
michael@0 34408 i5 = i1 + 52 | 0;
michael@0 34409 HEAP32[i8 >> 2] = HEAP32[i5 >> 2];
michael@0 34410 HEAP32[i8 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 34411 HEAP32[i8 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 34412 HEAP32[i8 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 34413 i9 = i3;
michael@0 34414 i10 = i2;
michael@0 34415 i11 = i7;
michael@0 34416 i12 = i2 + 16 | 0;
michael@0 34417 i13 = i6;
michael@0 34418 i14 = i2 + 32 | 0;
michael@0 34419 i15 = i5;
michael@0 34420 i16 = i2 + 48 | 0;
michael@0 34421 }
michael@0 34422 i2 = i1 + 132 | 0;
michael@0 34423 i5 = i1 + 304 | 0;
michael@0 34424 HEAP32[i2 >> 2] = HEAP32[i5 >> 2];
michael@0 34425 HEAP32[i2 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 34426 HEAP32[i2 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 34427 HEAP32[i2 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 34428 i5 = i1 + 148 | 0;
michael@0 34429 i2 = i1 + 320 | 0;
michael@0 34430 HEAP32[i5 >> 2] = HEAP32[i2 >> 2];
michael@0 34431 HEAP32[i5 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 34432 HEAP32[i5 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 34433 HEAP32[i5 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 34434 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 34435 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 34436 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 34437 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 34438 HEAP32[i11 >> 2] = HEAP32[i12 >> 2];
michael@0 34439 HEAP32[i11 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 34440 HEAP32[i11 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 34441 HEAP32[i11 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 34442 HEAP32[i13 >> 2] = HEAP32[i14 >> 2];
michael@0 34443 HEAP32[i13 + 4 >> 2] = HEAP32[i14 + 4 >> 2];
michael@0 34444 HEAP32[i13 + 8 >> 2] = HEAP32[i14 + 8 >> 2];
michael@0 34445 HEAP32[i13 + 12 >> 2] = HEAP32[i14 + 12 >> 2];
michael@0 34446 HEAP32[i15 >> 2] = HEAP32[i16 >> 2];
michael@0 34447 HEAP32[i15 + 4 >> 2] = HEAP32[i16 + 4 >> 2];
michael@0 34448 HEAP32[i15 + 8 >> 2] = HEAP32[i16 + 8 >> 2];
michael@0 34449 HEAP32[i15 + 12 >> 2] = HEAP32[i16 + 12 >> 2];
michael@0 34450 d17 = +HEAPF32[i1 + 4 >> 2];
michael@0 34451 d18 = +HEAPF32[i1 + 388 >> 2];
michael@0 34452 d19 = d17 * d18;
michael@0 34453 d20 = +HEAPF32[i1 + 8 >> 2];
michael@0 34454 d21 = +HEAPF32[i1 + 392 >> 2];
michael@0 34455 d22 = d20 * d21;
michael@0 34456 d23 = +HEAPF32[i1 + 12 >> 2];
michael@0 34457 d24 = +HEAPF32[i1 + 396 >> 2];
michael@0 34458 d25 = d23 * d24;
michael@0 34459 d26 = +HEAPF32[i1 + 20 >> 2];
michael@0 34460 d27 = d18 * d26;
michael@0 34461 d28 = +HEAPF32[i1 + 24 >> 2];
michael@0 34462 d29 = d21 * d28;
michael@0 34463 d30 = +HEAPF32[i1 + 28 >> 2];
michael@0 34464 d31 = d24 * d30;
michael@0 34465 d32 = +HEAPF32[i1 + 36 >> 2];
michael@0 34466 d33 = d18 * d32;
michael@0 34467 d18 = +HEAPF32[i1 + 40 >> 2];
michael@0 34468 d34 = d21 * d18;
michael@0 34469 d21 = +HEAPF32[i1 + 44 >> 2];
michael@0 34470 d35 = d24 * d21;
michael@0 34471 HEAPF32[i1 + 256 >> 2] = d17 * d19 + d20 * d22 + d23 * d25;
michael@0 34472 HEAPF32[i1 + 260 >> 2] = d19 * d26 + d22 * d28 + d25 * d30;
michael@0 34473 HEAPF32[i1 + 264 >> 2] = d19 * d32 + d22 * d18 + d25 * d21;
michael@0 34474 HEAPF32[i1 + 268 >> 2] = 0.0;
michael@0 34475 HEAPF32[i1 + 272 >> 2] = d17 * d27 + d20 * d29 + d23 * d31;
michael@0 34476 HEAPF32[i1 + 276 >> 2] = d26 * d27 + d28 * d29 + d30 * d31;
michael@0 34477 HEAPF32[i1 + 280 >> 2] = d27 * d32 + d29 * d18 + d31 * d21;
michael@0 34478 HEAPF32[i1 + 284 >> 2] = 0.0;
michael@0 34479 HEAPF32[i1 + 288 >> 2] = d17 * d33 + d20 * d34 + d23 * d35;
michael@0 34480 HEAPF32[i1 + 292 >> 2] = d26 * d33 + d28 * d34 + d30 * d35;
michael@0 34481 HEAPF32[i1 + 296 >> 2] = d32 * d33 + d18 * d34 + d21 * d35;
michael@0 34482 HEAPF32[i1 + 300 >> 2] = 0.0;
michael@0 34483 return;
michael@0 34484 }
michael@0 34485 function __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeE6insertERKS0_RKS1_(i1, i2, i3) {
michael@0 34486 i1 = i1 | 0;
michael@0 34487 i2 = i2 | 0;
michael@0 34488 i3 = i3 | 0;
michael@0 34489 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0;
michael@0 34490 i4 = i2 | 0;
michael@0 34491 i5 = HEAP16[i4 >> 1] | 0;
michael@0 34492 i6 = i2 + 2 | 0;
michael@0 34493 i7 = HEAP16[i6 >> 1] | 0;
michael@0 34494 i8 = i1 + 48 | 0;
michael@0 34495 i9 = HEAP32[i8 >> 2] | 0;
michael@0 34496 i10 = ((i7 & 65535) << 16) + (i5 << 16 >> 16) & i9 - 1;
michael@0 34497 L2113 : do {
michael@0 34498 if (i10 >>> 0 < (HEAP32[i1 + 4 >> 2] | 0) >>> 0) {
michael@0 34499 i11 = HEAP32[(HEAP32[i1 + 12 >> 2] | 0) + (i10 << 2) >> 2] | 0;
michael@0 34500 if ((i11 | 0) == -1) {
michael@0 34501 break;
michael@0 34502 }
michael@0 34503 i12 = HEAP32[i1 + 72 >> 2] | 0;
michael@0 34504 i13 = i1 + 32 | 0;
michael@0 34505 i14 = i11;
michael@0 34506 while (1) {
michael@0 34507 if (i5 << 16 >> 16 == (HEAP16[i12 + (i14 << 2) >> 1] | 0)) {
michael@0 34508 if (i7 << 16 >> 16 == (HEAP16[i12 + (i14 << 2) + 2 >> 1] | 0)) {
michael@0 34509 break;
michael@0 34510 }
michael@0 34511 }
michael@0 34512 i11 = HEAP32[(HEAP32[i13 >> 2] | 0) + (i14 << 2) >> 2] | 0;
michael@0 34513 if ((i11 | 0) == -1) {
michael@0 34514 break L2113;
michael@0 34515 } else {
michael@0 34516 i14 = i11;
michael@0 34517 }
michael@0 34518 }
michael@0 34519 if ((i14 | 0) == -1) {
michael@0 34520 break;
michael@0 34521 }
michael@0 34522 i13 = i3;
michael@0 34523 i12 = (HEAP32[i1 + 52 >> 2] | 0) + (i14 << 2) | 0;
michael@0 34524 tempBigInt = HEAPU16[i13 >> 1] | HEAPU16[i13 + 2 >> 1] << 16;
michael@0 34525 HEAP16[i12 >> 1] = tempBigInt & 65535;
michael@0 34526 HEAP16[i12 + 2 >> 1] = tempBigInt >> 16;
michael@0 34527 return;
michael@0 34528 }
michael@0 34529 } while (0);
michael@0 34530 i7 = i1 + 44 | 0;
michael@0 34531 i5 = HEAP32[i7 >> 2] | 0;
michael@0 34532 do {
michael@0 34533 if ((i5 | 0) == (i9 | 0)) {
michael@0 34534 i12 = (i9 | 0) == 0 ? 1 : i9 << 1;
michael@0 34535 if ((i9 | 0) >= (i12 | 0)) {
michael@0 34536 i15 = i9;
michael@0 34537 break;
michael@0 34538 }
michael@0 34539 if ((i12 | 0) == 0) {
michael@0 34540 i16 = 0;
michael@0 34541 i17 = i9;
michael@0 34542 } else {
michael@0 34543 i13 = __Z22btAlignedAllocInternalji(i12 << 2, 16) | 0;
michael@0 34544 i16 = i13;
michael@0 34545 i17 = HEAP32[i7 >> 2] | 0;
michael@0 34546 }
michael@0 34547 i13 = i1 + 52 | 0;
michael@0 34548 if ((i17 | 0) > 0) {
michael@0 34549 i11 = 0;
michael@0 34550 do {
michael@0 34551 i18 = i16 + (i11 << 2) | 0;
michael@0 34552 if ((i18 | 0) != 0) {
michael@0 34553 i19 = (HEAP32[i13 >> 2] | 0) + (i11 << 2) | 0;
michael@0 34554 i20 = i18;
michael@0 34555 tempBigInt = HEAPU16[i19 >> 1] | HEAPU16[i19 + 2 >> 1] << 16;
michael@0 34556 HEAP16[i20 >> 1] = tempBigInt & 65535;
michael@0 34557 HEAP16[i20 + 2 >> 1] = tempBigInt >> 16;
michael@0 34558 }
michael@0 34559 i11 = i11 + 1 | 0;
michael@0 34560 } while ((i11 | 0) < (i17 | 0));
michael@0 34561 }
michael@0 34562 i11 = HEAP32[i13 >> 2] | 0;
michael@0 34563 i14 = i1 + 56 | 0;
michael@0 34564 if ((i11 | 0) != 0) {
michael@0 34565 if ((HEAP8[i14] | 0) != 0) {
michael@0 34566 __Z21btAlignedFreeInternalPv(i11);
michael@0 34567 }
michael@0 34568 HEAP32[i13 >> 2] = 0;
michael@0 34569 }
michael@0 34570 HEAP8[i14] = 1;
michael@0 34571 HEAP32[i13 >> 2] = i16;
michael@0 34572 HEAP32[i8 >> 2] = i12;
michael@0 34573 i15 = HEAP32[i7 >> 2] | 0;
michael@0 34574 } else {
michael@0 34575 i15 = i5;
michael@0 34576 }
michael@0 34577 } while (0);
michael@0 34578 i16 = (HEAP32[i1 + 52 >> 2] | 0) + (i15 << 2) | 0;
michael@0 34579 if ((i16 | 0) == 0) {
michael@0 34580 i21 = i15;
michael@0 34581 } else {
michael@0 34582 i15 = i3;
michael@0 34583 i3 = i16;
michael@0 34584 tempBigInt = HEAPU16[i15 >> 1] | HEAPU16[i15 + 2 >> 1] << 16;
michael@0 34585 HEAP16[i3 >> 1] = tempBigInt & 65535;
michael@0 34586 HEAP16[i3 + 2 >> 1] = tempBigInt >> 16;
michael@0 34587 i21 = HEAP32[i7 >> 2] | 0;
michael@0 34588 }
michael@0 34589 HEAP32[i7 >> 2] = i21 + 1;
michael@0 34590 i21 = i1 + 64 | 0;
michael@0 34591 i7 = HEAP32[i21 >> 2] | 0;
michael@0 34592 i3 = i1 + 68 | 0;
michael@0 34593 do {
michael@0 34594 if ((i7 | 0) == (HEAP32[i3 >> 2] | 0)) {
michael@0 34595 i15 = (i7 | 0) == 0 ? 1 : i7 << 1;
michael@0 34596 if ((i7 | 0) >= (i15 | 0)) {
michael@0 34597 i22 = i7;
michael@0 34598 break;
michael@0 34599 }
michael@0 34600 if ((i15 | 0) == 0) {
michael@0 34601 i23 = 0;
michael@0 34602 i24 = i7;
michael@0 34603 } else {
michael@0 34604 i16 = __Z22btAlignedAllocInternalji(i15 << 2, 16) | 0;
michael@0 34605 i23 = i16;
michael@0 34606 i24 = HEAP32[i21 >> 2] | 0;
michael@0 34607 }
michael@0 34608 i16 = i1 + 72 | 0;
michael@0 34609 if ((i24 | 0) > 0) {
michael@0 34610 i17 = 0;
michael@0 34611 do {
michael@0 34612 i14 = i23 + (i17 << 2) | 0;
michael@0 34613 if ((i14 | 0) != 0) {
michael@0 34614 i11 = (HEAP32[i16 >> 2] | 0) + (i17 << 2) | 0;
michael@0 34615 i20 = i14;
michael@0 34616 tempBigInt = HEAPU16[i11 >> 1] | HEAPU16[i11 + 2 >> 1] << 16;
michael@0 34617 HEAP16[i20 >> 1] = tempBigInt & 65535;
michael@0 34618 HEAP16[i20 + 2 >> 1] = tempBigInt >> 16;
michael@0 34619 }
michael@0 34620 i17 = i17 + 1 | 0;
michael@0 34621 } while ((i17 | 0) < (i24 | 0));
michael@0 34622 }
michael@0 34623 i17 = HEAP32[i16 >> 2] | 0;
michael@0 34624 i12 = i1 + 76 | 0;
michael@0 34625 if ((i17 | 0) != 0) {
michael@0 34626 if ((HEAP8[i12] | 0) != 0) {
michael@0 34627 __Z21btAlignedFreeInternalPv(i17);
michael@0 34628 }
michael@0 34629 HEAP32[i16 >> 2] = 0;
michael@0 34630 }
michael@0 34631 HEAP8[i12] = 1;
michael@0 34632 HEAP32[i16 >> 2] = i23;
michael@0 34633 HEAP32[i3 >> 2] = i15;
michael@0 34634 i22 = HEAP32[i21 >> 2] | 0;
michael@0 34635 } else {
michael@0 34636 i22 = i7;
michael@0 34637 }
michael@0 34638 } while (0);
michael@0 34639 i7 = (HEAP32[i1 + 72 >> 2] | 0) + (i22 << 2) | 0;
michael@0 34640 if ((i7 | 0) == 0) {
michael@0 34641 i25 = i22;
michael@0 34642 } else {
michael@0 34643 i22 = i2;
michael@0 34644 i2 = i7;
michael@0 34645 tempBigInt = HEAPU16[i22 >> 1] | HEAPU16[i22 + 2 >> 1] << 16;
michael@0 34646 HEAP16[i2 >> 1] = tempBigInt & 65535;
michael@0 34647 HEAP16[i2 + 2 >> 1] = tempBigInt >> 16;
michael@0 34648 i25 = HEAP32[i21 >> 2] | 0;
michael@0 34649 }
michael@0 34650 HEAP32[i21 >> 2] = i25 + 1;
michael@0 34651 if ((i9 | 0) < (HEAP32[i8 >> 2] | 0)) {
michael@0 34652 __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeE10growTablesERKS0_(i1, 0);
michael@0 34653 i26 = (HEAPU16[i6 >> 1] << 16) + (HEAP16[i4 >> 1] | 0) & (HEAP32[i8 >> 2] | 0) - 1;
michael@0 34654 } else {
michael@0 34655 i26 = i10;
michael@0 34656 }
michael@0 34657 i10 = (HEAP32[i1 + 12 >> 2] | 0) + (i26 << 2) | 0;
michael@0 34658 HEAP32[(HEAP32[i1 + 32 >> 2] | 0) + (i5 << 2) >> 2] = HEAP32[i10 >> 2];
michael@0 34659 HEAP32[i10 >> 2] = i5;
michael@0 34660 return;
michael@0 34661 }
michael@0 34662 function __ZN24btPerturbedContactResult15addContactPointERK9btVector3S2_f(i1, i2, i3, d4) {
michael@0 34663 i1 = i1 | 0;
michael@0 34664 i2 = i2 | 0;
michael@0 34665 i3 = i3 | 0;
michael@0 34666 d4 = +d4;
michael@0 34667 var i5 = 0, i6 = 0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0;
michael@0 34668 i5 = STACKTOP;
michael@0 34669 STACKTOP = STACKTOP + 16 | 0;
michael@0 34670 i6 = i5 | 0;
michael@0 34671 d7 = +HEAPF32[i2 >> 2];
michael@0 34672 d8 = +HEAPF32[i2 + 4 >> 2];
michael@0 34673 d9 = +HEAPF32[i2 + 8 >> 2];
michael@0 34674 d10 = +HEAPF32[i3 >> 2];
michael@0 34675 d11 = d7 * d4 + d10;
michael@0 34676 d12 = +HEAPF32[i3 + 4 >> 2];
michael@0 34677 d13 = d8 * d4 + d12;
michael@0 34678 d14 = +HEAPF32[i3 + 8 >> 2];
michael@0 34679 d15 = d9 * d4 + d14;
michael@0 34680 i3 = i1 + 292 | 0;
michael@0 34681 if ((HEAP8[i1 + 356 | 0] | 0) == 0) {
michael@0 34682 d4 = +HEAPF32[i1 + 228 >> 2];
michael@0 34683 d16 = +HEAPF32[i1 + 244 >> 2];
michael@0 34684 d17 = +HEAPF32[i1 + 260 >> 2];
michael@0 34685 d18 = +HEAPF32[i1 + 232 >> 2];
michael@0 34686 d19 = +HEAPF32[i1 + 248 >> 2];
michael@0 34687 d20 = +HEAPF32[i1 + 264 >> 2];
michael@0 34688 d21 = +HEAPF32[i1 + 236 >> 2];
michael@0 34689 d22 = +HEAPF32[i1 + 252 >> 2];
michael@0 34690 d23 = +HEAPF32[i1 + 268 >> 2];
michael@0 34691 d24 = -0.0 - +HEAPF32[i1 + 276 >> 2];
michael@0 34692 d25 = -0.0 - +HEAPF32[i1 + 280 >> 2];
michael@0 34693 d26 = -0.0 - +HEAPF32[i1 + 284 >> 2];
michael@0 34694 d27 = d4 * d24 + d16 * d25 + d17 * d26;
michael@0 34695 d28 = d18 * d24 + d19 * d25 + d20 * d26;
michael@0 34696 d29 = d21 * d24 + d22 * d25 + d23 * d26;
michael@0 34697 d26 = +HEAPF32[i3 >> 2];
michael@0 34698 d25 = +HEAPF32[i1 + 296 >> 2];
michael@0 34699 d24 = +HEAPF32[i1 + 300 >> 2];
michael@0 34700 d30 = +HEAPF32[i1 + 308 >> 2];
michael@0 34701 d31 = +HEAPF32[i1 + 312 >> 2];
michael@0 34702 d32 = +HEAPF32[i1 + 316 >> 2];
michael@0 34703 d33 = +HEAPF32[i1 + 324 >> 2];
michael@0 34704 d34 = +HEAPF32[i1 + 328 >> 2];
michael@0 34705 d35 = +HEAPF32[i1 + 332 >> 2];
michael@0 34706 d36 = d14 * (d17 * d26 + d20 * d25 + d23 * d24) + (d10 * (d4 * d26 + d18 * d25 + d21 * d24) + d12 * (d16 * d26 + d19 * d25 + d22 * d24)) + (d24 * d29 + (d26 * d27 + d25 * d28) + +HEAPF32[i1 + 340 >> 2]);
michael@0 34707 d25 = d14 * (d17 * d30 + d20 * d31 + d23 * d32) + (d10 * (d4 * d30 + d18 * d31 + d21 * d32) + d12 * (d16 * d30 + d19 * d31 + d22 * d32)) + (d27 * d30 + d28 * d31 + d29 * d32 + +HEAPF32[i1 + 344 >> 2]);
michael@0 34708 d32 = d27 * d33 + d28 * d34 + d29 * d35 + +HEAPF32[i1 + 348 >> 2] + (d14 * (d17 * d33 + d20 * d34 + d23 * d35) + (d10 * (d4 * d33 + d18 * d34 + d21 * d35) + d12 * (d16 * d33 + d19 * d34 + d22 * d35)));
michael@0 34709 HEAPF32[i6 >> 2] = d36;
michael@0 34710 HEAPF32[i6 + 4 >> 2] = d25;
michael@0 34711 HEAPF32[i6 + 8 >> 2] = d32;
michael@0 34712 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 34713 d37 = d7 * (d11 - d36) + d8 * (d13 - d25) + d9 * (d15 - d32);
michael@0 34714 i38 = i1 + 160 | 0;
michael@0 34715 i39 = HEAP32[i38 >> 2] | 0;
michael@0 34716 i40 = i39;
michael@0 34717 i41 = HEAP32[i40 >> 2] | 0;
michael@0 34718 i42 = i41 + 16 | 0;
michael@0 34719 i43 = HEAP32[i42 >> 2] | 0;
michael@0 34720 FUNCTION_TABLE_viiif[i43 & 15](i39, i2, i6, d37);
michael@0 34721 STACKTOP = i5;
michael@0 34722 return;
michael@0 34723 } else {
michael@0 34724 d32 = +HEAPF32[i1 + 164 >> 2];
michael@0 34725 d25 = +HEAPF32[i1 + 180 >> 2];
michael@0 34726 d36 = +HEAPF32[i1 + 196 >> 2];
michael@0 34727 d35 = +HEAPF32[i1 + 168 >> 2];
michael@0 34728 d22 = +HEAPF32[i1 + 184 >> 2];
michael@0 34729 d34 = +HEAPF32[i1 + 200 >> 2];
michael@0 34730 d19 = +HEAPF32[i1 + 172 >> 2];
michael@0 34731 d33 = +HEAPF32[i1 + 188 >> 2];
michael@0 34732 d16 = +HEAPF32[i1 + 204 >> 2];
michael@0 34733 d21 = -0.0 - +HEAPF32[i1 + 212 >> 2];
michael@0 34734 d18 = -0.0 - +HEAPF32[i1 + 216 >> 2];
michael@0 34735 d4 = -0.0 - +HEAPF32[i1 + 220 >> 2];
michael@0 34736 d23 = d32 * d21 + d25 * d18 + d36 * d4;
michael@0 34737 d20 = d35 * d21 + d22 * d18 + d34 * d4;
michael@0 34738 d17 = d19 * d21 + d33 * d18 + d16 * d4;
michael@0 34739 d4 = +HEAPF32[i3 >> 2];
michael@0 34740 d18 = +HEAPF32[i1 + 296 >> 2];
michael@0 34741 d21 = +HEAPF32[i1 + 300 >> 2];
michael@0 34742 d29 = +HEAPF32[i1 + 308 >> 2];
michael@0 34743 d28 = +HEAPF32[i1 + 312 >> 2];
michael@0 34744 d27 = +HEAPF32[i1 + 316 >> 2];
michael@0 34745 d31 = +HEAPF32[i1 + 324 >> 2];
michael@0 34746 d30 = +HEAPF32[i1 + 328 >> 2];
michael@0 34747 d26 = +HEAPF32[i1 + 332 >> 2];
michael@0 34748 d24 = d15 * (d36 * d4 + d34 * d18 + d16 * d21) + (d11 * (d32 * d4 + d35 * d18 + d19 * d21) + d13 * (d25 * d4 + d22 * d18 + d33 * d21)) + (d21 * d17 + (d4 * d23 + d18 * d20) + +HEAPF32[i1 + 340 >> 2]);
michael@0 34749 d18 = d15 * (d36 * d29 + d34 * d28 + d16 * d27) + (d11 * (d32 * d29 + d35 * d28 + d19 * d27) + d13 * (d25 * d29 + d22 * d28 + d33 * d27)) + (d23 * d29 + d20 * d28 + d17 * d27 + +HEAPF32[i1 + 344 >> 2]);
michael@0 34750 d27 = d23 * d31 + d20 * d30 + d17 * d26 + +HEAPF32[i1 + 348 >> 2] + (d15 * (d36 * d31 + d34 * d30 + d16 * d26) + (d11 * (d32 * d31 + d35 * d30 + d19 * d26) + d13 * (d25 * d31 + d22 * d30 + d33 * d26)));
michael@0 34751 d26 = d7 * (d24 - d10) + d8 * (d18 - d12) + d9 * (d27 - d14);
michael@0 34752 HEAPF32[i6 >> 2] = d24 + d7 * d26;
michael@0 34753 HEAPF32[i6 + 4 >> 2] = d18 + d8 * d26;
michael@0 34754 HEAPF32[i6 + 8 >> 2] = d27 + d9 * d26;
michael@0 34755 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 34756 d37 = d26;
michael@0 34757 i38 = i1 + 160 | 0;
michael@0 34758 i39 = HEAP32[i38 >> 2] | 0;
michael@0 34759 i40 = i39;
michael@0 34760 i41 = HEAP32[i40 >> 2] | 0;
michael@0 34761 i42 = i41 + 16 | 0;
michael@0 34762 i43 = HEAP32[i42 >> 2] | 0;
michael@0 34763 FUNCTION_TABLE_viiif[i43 & 15](i39, i2, i6, d37);
michael@0 34764 STACKTOP = i5;
michael@0 34765 return;
michael@0 34766 }
michael@0 34767 }
michael@0 34768 function __ZN16btDbvtBroadphase22performDeferredRemovalEP12btDispatcher(i1, i2) {
michael@0 34769 i1 = i1 | 0;
michael@0 34770 i2 = i2 | 0;
michael@0 34771 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0;
michael@0 34772 i3 = STACKTOP;
michael@0 34773 STACKTOP = STACKTOP + 16 | 0;
michael@0 34774 i4 = i3 | 0;
michael@0 34775 i5 = i1 + 96 | 0;
michael@0 34776 i1 = HEAP32[i5 >> 2] | 0;
michael@0 34777 if (!(FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 56 >> 2] & 127](i1) | 0)) {
michael@0 34778 STACKTOP = i3;
michael@0 34779 return;
michael@0 34780 }
michael@0 34781 i1 = HEAP32[i5 >> 2] | 0;
michael@0 34782 i6 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 28 >> 2] & 127](i1) | 0;
michael@0 34783 i1 = i6 + 4 | 0;
michael@0 34784 i7 = HEAP32[i1 >> 2] | 0;
michael@0 34785 if ((i7 | 0) > 1) {
michael@0 34786 __ZN20btAlignedObjectArrayI16btBroadphasePairE17quickSortInternalI29btBroadphasePairSortPredicateEEvT_ii(i6, i3 + 8 | 0, 0, i7 - 1 | 0);
michael@0 34787 i8 = HEAP32[i1 >> 2] | 0;
michael@0 34788 } else {
michael@0 34789 i8 = i7;
michael@0 34790 }
michael@0 34791 do {
michael@0 34792 if ((i8 | 0) > 0) {
michael@0 34793 i7 = i6 + 12 | 0;
michael@0 34794 i9 = 0;
michael@0 34795 i10 = 0;
michael@0 34796 i11 = 0;
michael@0 34797 i12 = 0;
michael@0 34798 i13 = i8;
michael@0 34799 while (1) {
michael@0 34800 i14 = HEAP32[i7 >> 2] | 0;
michael@0 34801 i15 = i14 + (i11 << 4) | 0;
michael@0 34802 i16 = i15 | 0;
michael@0 34803 i17 = HEAP32[i16 >> 2] | 0;
michael@0 34804 i18 = i14 + (i11 << 4) + 4 | 0;
michael@0 34805 i14 = HEAP32[i18 >> 2] | 0;
michael@0 34806 if ((i17 | 0) == (i10 | 0)) {
michael@0 34807 if ((i14 | 0) == (i9 | 0)) {
michael@0 34808 i19 = i10;
michael@0 34809 i20 = i9;
michael@0 34810 i21 = 1012;
michael@0 34811 } else {
michael@0 34812 i22 = i10;
michael@0 34813 i21 = 1006;
michael@0 34814 }
michael@0 34815 } else {
michael@0 34816 i22 = i17;
michael@0 34817 i21 = 1006;
michael@0 34818 }
michael@0 34819 do {
michael@0 34820 if ((i21 | 0) == 1006) {
michael@0 34821 i21 = 0;
michael@0 34822 i17 = HEAP32[i22 + 48 >> 2] | 0;
michael@0 34823 i23 = HEAP32[i14 + 48 >> 2] | 0;
michael@0 34824 if (+HEAPF32[i17 >> 2] > +HEAPF32[i23 + 16 >> 2]) {
michael@0 34825 i19 = i22;
michael@0 34826 i20 = i14;
michael@0 34827 i21 = 1012;
michael@0 34828 break;
michael@0 34829 }
michael@0 34830 if (+HEAPF32[i17 + 16 >> 2] < +HEAPF32[i23 >> 2]) {
michael@0 34831 i19 = i22;
michael@0 34832 i20 = i14;
michael@0 34833 i21 = 1012;
michael@0 34834 break;
michael@0 34835 }
michael@0 34836 if (+HEAPF32[i17 + 4 >> 2] > +HEAPF32[i23 + 20 >> 2]) {
michael@0 34837 i19 = i22;
michael@0 34838 i20 = i14;
michael@0 34839 i21 = 1012;
michael@0 34840 break;
michael@0 34841 }
michael@0 34842 if (+HEAPF32[i17 + 20 >> 2] < +HEAPF32[i23 + 4 >> 2]) {
michael@0 34843 i19 = i22;
michael@0 34844 i20 = i14;
michael@0 34845 i21 = 1012;
michael@0 34846 break;
michael@0 34847 }
michael@0 34848 if (+HEAPF32[i17 + 8 >> 2] > +HEAPF32[i23 + 24 >> 2]) {
michael@0 34849 i19 = i22;
michael@0 34850 i20 = i14;
michael@0 34851 i21 = 1012;
michael@0 34852 break;
michael@0 34853 }
michael@0 34854 if (+HEAPF32[i17 + 24 >> 2] < +HEAPF32[i23 + 8 >> 2]) {
michael@0 34855 i19 = i22;
michael@0 34856 i20 = i14;
michael@0 34857 i21 = 1012;
michael@0 34858 } else {
michael@0 34859 i24 = i12;
michael@0 34860 i25 = i22;
michael@0 34861 i26 = i14;
michael@0 34862 i27 = i13;
michael@0 34863 }
michael@0 34864 }
michael@0 34865 } while (0);
michael@0 34866 if ((i21 | 0) == 1012) {
michael@0 34867 i21 = 0;
michael@0 34868 i14 = HEAP32[i5 >> 2] | 0;
michael@0 34869 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i14 >> 2] | 0) + 32 >> 2] & 127](i14, i15, i2);
michael@0 34870 HEAP32[i16 >> 2] = 0;
michael@0 34871 HEAP32[i18 >> 2] = 0;
michael@0 34872 i24 = i12 + 1 | 0;
michael@0 34873 i25 = i19;
michael@0 34874 i26 = i20;
michael@0 34875 i27 = HEAP32[i1 >> 2] | 0;
michael@0 34876 }
michael@0 34877 i14 = i11 + 1 | 0;
michael@0 34878 if ((i14 | 0) < (i27 | 0)) {
michael@0 34879 i9 = i26;
michael@0 34880 i10 = i25;
michael@0 34881 i11 = i14;
michael@0 34882 i12 = i24;
michael@0 34883 i13 = i27;
michael@0 34884 } else {
michael@0 34885 break;
michael@0 34886 }
michael@0 34887 }
michael@0 34888 if ((i27 | 0) > 1) {
michael@0 34889 __ZN20btAlignedObjectArrayI16btBroadphasePairE17quickSortInternalI29btBroadphasePairSortPredicateEEvT_ii(i6, i4, 0, i27 - 1 | 0);
michael@0 34890 i28 = HEAP32[i1 >> 2] | 0;
michael@0 34891 } else {
michael@0 34892 i28 = i27;
michael@0 34893 }
michael@0 34894 i13 = i28 - i24 | 0;
michael@0 34895 if ((i24 | 0) >= 0) {
michael@0 34896 i29 = i13;
michael@0 34897 break;
michael@0 34898 }
michael@0 34899 i12 = i6 + 8 | 0;
michael@0 34900 if ((HEAP32[i12 >> 2] | 0) < (i13 | 0)) {
michael@0 34901 if ((i28 | 0) == (i24 | 0)) {
michael@0 34902 i30 = 0;
michael@0 34903 i31 = i24;
michael@0 34904 } else {
michael@0 34905 i11 = __Z22btAlignedAllocInternalji(i13 << 4, 16) | 0;
michael@0 34906 i30 = i11;
michael@0 34907 i31 = HEAP32[i1 >> 2] | 0;
michael@0 34908 }
michael@0 34909 if ((i31 | 0) > 0) {
michael@0 34910 i11 = 0;
michael@0 34911 do {
michael@0 34912 i10 = HEAP32[i7 >> 2] | 0;
michael@0 34913 HEAP32[i30 + (i11 << 4) >> 2] = HEAP32[i10 + (i11 << 4) >> 2];
michael@0 34914 HEAP32[i30 + (i11 << 4) + 4 >> 2] = HEAP32[i10 + (i11 << 4) + 4 >> 2];
michael@0 34915 HEAP32[i30 + (i11 << 4) + 8 >> 2] = HEAP32[i10 + (i11 << 4) + 8 >> 2];
michael@0 34916 HEAP32[i30 + (i11 << 4) + 12 >> 2] = HEAP32[i10 + (i11 << 4) + 12 >> 2];
michael@0 34917 i11 = i11 + 1 | 0;
michael@0 34918 } while ((i11 | 0) < (i31 | 0));
michael@0 34919 }
michael@0 34920 i11 = HEAP32[i7 >> 2] | 0;
michael@0 34921 i10 = i6 + 16 | 0;
michael@0 34922 if ((i11 | 0) != 0) {
michael@0 34923 if ((HEAP8[i10] | 0) != 0) {
michael@0 34924 __Z21btAlignedFreeInternalPv(i11);
michael@0 34925 }
michael@0 34926 HEAP32[i7 >> 2] = 0;
michael@0 34927 }
michael@0 34928 HEAP8[i10] = 1;
michael@0 34929 HEAP32[i7 >> 2] = i30;
michael@0 34930 HEAP32[i12 >> 2] = i13;
michael@0 34931 i32 = i28;
michael@0 34932 } else {
michael@0 34933 i32 = i28;
michael@0 34934 }
michael@0 34935 while (1) {
michael@0 34936 i10 = i32 + 1 | 0;
michael@0 34937 _memset((HEAP32[i7 >> 2] | 0) + (i32 << 4) | 0, 0, 16);
michael@0 34938 if ((i10 | 0) < (i13 | 0)) {
michael@0 34939 i32 = i10;
michael@0 34940 } else {
michael@0 34941 i29 = i13;
michael@0 34942 break;
michael@0 34943 }
michael@0 34944 }
michael@0 34945 } else {
michael@0 34946 i29 = i8;
michael@0 34947 }
michael@0 34948 } while (0);
michael@0 34949 HEAP32[i1 >> 2] = i29;
michael@0 34950 STACKTOP = i3;
michael@0 34951 return;
michael@0 34952 }
michael@0 34953 function __ZN20btConvexHullInternal15computeInternalEiiRNS_16IntermediateHullE(i1, i2, i3, i4) {
michael@0 34954 i1 = i1 | 0;
michael@0 34955 i2 = i2 | 0;
michael@0 34956 i3 = i3 | 0;
michael@0 34957 i4 = i4 | 0;
michael@0 34958 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0;
michael@0 34959 i5 = STACKTOP;
michael@0 34960 STACKTOP = STACKTOP + 16 | 0;
michael@0 34961 i6 = i5 | 0;
michael@0 34962 i7 = i3 - i2 | 0;
michael@0 34963 L889 : do {
michael@0 34964 if ((i7 | 0) == 1) {
michael@0 34965 i8 = HEAP32[(HEAP32[i1 + 92 >> 2] | 0) + (i2 << 2) >> 2] | 0;
michael@0 34966 } else if ((i7 | 0) == 2) {
michael@0 34967 i9 = HEAP32[(HEAP32[i1 + 92 >> 2] | 0) + (i2 << 2) >> 2] | 0;
michael@0 34968 i10 = i9 + 112 | 0;
michael@0 34969 i11 = HEAP32[i9 + 88 >> 2] | 0;
michael@0 34970 i12 = HEAP32[i9 + 200 >> 2] | 0;
michael@0 34971 i13 = (i11 | 0) == (i12 | 0);
michael@0 34972 i14 = HEAP32[i9 + 92 >> 2] | 0;
michael@0 34973 i15 = HEAP32[i9 + 204 >> 2] | 0;
michael@0 34974 i16 = (i14 | 0) == (i15 | 0);
michael@0 34975 do {
michael@0 34976 if (i13) {
michael@0 34977 if (i16) {
michael@0 34978 if ((HEAP32[i9 + 96 >> 2] | 0) == (HEAP32[i9 + 208 >> 2] | 0)) {
michael@0 34979 i8 = i9;
michael@0 34980 break L889;
michael@0 34981 } else {
michael@0 34982 i17 = i14;
michael@0 34983 }
michael@0 34984 } else {
michael@0 34985 i17 = i15;
michael@0 34986 }
michael@0 34987 if ((i14 | 0) != (i17 | 0)) {
michael@0 34988 i18 = i17;
michael@0 34989 i19 = 0;
michael@0 34990 i20 = 696;
michael@0 34991 break;
michael@0 34992 }
michael@0 34993 i21 = (HEAP32[i9 + 96 >> 2] | 0) > (HEAP32[i9 + 208 >> 2] | 0);
michael@0 34994 i22 = i21 ? i10 : i9;
michael@0 34995 HEAP32[i22 >> 2] = i22;
michael@0 34996 HEAP32[i22 + 4 >> 2] = i22;
michael@0 34997 HEAP32[i4 >> 2] = i22;
michael@0 34998 HEAP32[i4 + 4 >> 2] = i22;
michael@0 34999 HEAP32[i4 + 8 >> 2] = i22;
michael@0 35000 HEAP32[i4 + 12 >> 2] = i22;
michael@0 35001 i23 = i22;
michael@0 35002 i24 = i21 ? i9 : i10;
michael@0 35003 } else {
michael@0 35004 i18 = i15;
michael@0 35005 i19 = i16;
michael@0 35006 i20 = 696;
michael@0 35007 }
michael@0 35008 } while (0);
michael@0 35009 do {
michael@0 35010 if ((i20 | 0) == 696) {
michael@0 35011 i16 = i14 - i18 | 0;
michael@0 35012 HEAP32[i9 >> 2] = i10;
michael@0 35013 HEAP32[i9 + 4 >> 2] = i10;
michael@0 35014 HEAP32[i10 >> 2] = i9;
michael@0 35015 HEAP32[i9 + 116 >> 2] = i9;
michael@0 35016 i15 = (i11 - i12 | 0) < 0;
michael@0 35017 do {
michael@0 35018 if (i15) {
michael@0 35019 i20 = 698;
michael@0 35020 } else {
michael@0 35021 if (i13 & (i16 | 0) < 0) {
michael@0 35022 i20 = 698;
michael@0 35023 break;
michael@0 35024 }
michael@0 35025 HEAP32[i4 >> 2] = i10;
michael@0 35026 HEAP32[i4 + 4 >> 2] = i9;
michael@0 35027 }
michael@0 35028 } while (0);
michael@0 35029 if ((i20 | 0) == 698) {
michael@0 35030 HEAP32[i4 >> 2] = i9;
michael@0 35031 HEAP32[i4 + 4 >> 2] = i10;
michael@0 35032 }
michael@0 35033 i21 = i4 + 8 | 0;
michael@0 35034 if ((i16 | 0) < 0 | i19 & i15) {
michael@0 35035 HEAP32[i21 >> 2] = i9;
michael@0 35036 HEAP32[i4 + 12 >> 2] = i10;
michael@0 35037 i23 = i9;
michael@0 35038 i24 = i10;
michael@0 35039 break;
michael@0 35040 } else {
michael@0 35041 HEAP32[i21 >> 2] = i10;
michael@0 35042 HEAP32[i4 + 12 >> 2] = i9;
michael@0 35043 i23 = i9;
michael@0 35044 i24 = i10;
michael@0 35045 break;
michael@0 35046 }
michael@0 35047 }
michael@0 35048 } while (0);
michael@0 35049 i10 = i1 + 48 | 0;
michael@0 35050 i9 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i10) | 0;
michael@0 35051 i13 = __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i10) | 0;
michael@0 35052 i10 = i9 + 8 | 0;
michael@0 35053 HEAP32[i10 >> 2] = i13;
michael@0 35054 HEAP32[i13 + 8 >> 2] = i9;
michael@0 35055 i12 = i1 + 100 | 0;
michael@0 35056 HEAP32[i9 + 20 >> 2] = HEAP32[i12 >> 2];
michael@0 35057 HEAP32[i13 + 20 >> 2] = HEAP32[i12 >> 2];
michael@0 35058 HEAP32[i9 + 12 >> 2] = i24;
michael@0 35059 HEAP32[i13 + 12 >> 2] = i23;
michael@0 35060 HEAP32[i9 + 16 >> 2] = 0;
michael@0 35061 HEAP32[i13 + 16 >> 2] = 0;
michael@0 35062 i13 = i1 + 116 | 0;
michael@0 35063 i12 = (HEAP32[i13 >> 2] | 0) + 1 | 0;
michael@0 35064 HEAP32[i13 >> 2] = i12;
michael@0 35065 i13 = i1 + 120 | 0;
michael@0 35066 if ((i12 | 0) > (HEAP32[i13 >> 2] | 0)) {
michael@0 35067 HEAP32[i13 >> 2] = i12;
michael@0 35068 }
michael@0 35069 HEAP32[i9 >> 2] = i9;
michael@0 35070 HEAP32[i9 + 4 >> 2] = i9;
michael@0 35071 HEAP32[i23 + 8 >> 2] = i9;
michael@0 35072 i9 = HEAP32[i10 >> 2] | 0;
michael@0 35073 HEAP32[i9 >> 2] = i9;
michael@0 35074 HEAP32[i9 + 4 >> 2] = i9;
michael@0 35075 HEAP32[i24 + 8 >> 2] = i9;
michael@0 35076 STACKTOP = i5;
michael@0 35077 return;
michael@0 35078 } else if ((i7 | 0) == 0) {
michael@0 35079 _memset(i4 | 0, 0, 16);
michael@0 35080 STACKTOP = i5;
michael@0 35081 return;
michael@0 35082 } else {
michael@0 35083 i9 = ((i7 | 0) / 2 | 0) + i2 | 0;
michael@0 35084 i10 = HEAP32[i1 + 92 >> 2] | 0;
michael@0 35085 i12 = HEAP32[i10 + (i9 - 1 << 2) >> 2] | 0;
michael@0 35086 i13 = HEAP32[i12 + 88 >> 2] | 0;
michael@0 35087 i11 = HEAP32[i12 + 92 >> 2] | 0;
michael@0 35088 i14 = HEAP32[i12 + 96 >> 2] | 0;
michael@0 35089 i12 = i9;
michael@0 35090 while (1) {
michael@0 35091 if ((i12 | 0) >= (i3 | 0)) {
michael@0 35092 break;
michael@0 35093 }
michael@0 35094 i21 = HEAP32[i10 + (i12 << 2) >> 2] | 0;
michael@0 35095 if ((HEAP32[i21 + 88 >> 2] | 0) != (i13 | 0)) {
michael@0 35096 break;
michael@0 35097 }
michael@0 35098 if ((HEAP32[i21 + 92 >> 2] | 0) != (i11 | 0)) {
michael@0 35099 break;
michael@0 35100 }
michael@0 35101 if ((HEAP32[i21 + 96 >> 2] | 0) == (i14 | 0)) {
michael@0 35102 i12 = i12 + 1 | 0;
michael@0 35103 } else {
michael@0 35104 break;
michael@0 35105 }
michael@0 35106 }
michael@0 35107 __ZN20btConvexHullInternal15computeInternalEiiRNS_16IntermediateHullE(i1, i2, i9, i4);
michael@0 35108 _memset(i6 | 0, 0, 16);
michael@0 35109 __ZN20btConvexHullInternal15computeInternalEiiRNS_16IntermediateHullE(i1, i12, i3, i6);
michael@0 35110 __ZN20btConvexHullInternal5mergeERNS_16IntermediateHullES1_(i1, i4, i6);
michael@0 35111 STACKTOP = i5;
michael@0 35112 return;
michael@0 35113 }
michael@0 35114 } while (0);
michael@0 35115 HEAP32[i8 + 8 >> 2] = 0;
michael@0 35116 HEAP32[i8 >> 2] = i8;
michael@0 35117 HEAP32[i8 + 4 >> 2] = i8;
michael@0 35118 HEAP32[i4 >> 2] = i8;
michael@0 35119 HEAP32[i4 + 4 >> 2] = i8;
michael@0 35120 HEAP32[i4 + 8 >> 2] = i8;
michael@0 35121 HEAP32[i4 + 12 >> 2] = i8;
michael@0 35122 STACKTOP = i5;
michael@0 35123 return;
michael@0 35124 }
michael@0 35125 function __ZNK17btCollisionObject9serializeEPvP12btSerializer(i1, i2, i3) {
michael@0 35126 i1 = i1 | 0;
michael@0 35127 i2 = i2 | 0;
michael@0 35128 i3 = i3 | 0;
michael@0 35129 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, i13 = 0, i14 = 0, i15 = 0, d16 = 0.0, i17 = 0, i18 = 0, d19 = 0.0, i20 = 0, i21 = 0, i22 = 0, i23 = 0;
michael@0 35130 HEAPF32[i2 + 16 >> 2] = +HEAPF32[i1 + 4 >> 2];
michael@0 35131 HEAPF32[i2 + 20 >> 2] = +HEAPF32[i1 + 8 >> 2];
michael@0 35132 HEAPF32[i2 + 24 >> 2] = +HEAPF32[i1 + 12 >> 2];
michael@0 35133 HEAPF32[i2 + 28 >> 2] = +HEAPF32[i1 + 16 >> 2];
michael@0 35134 HEAPF32[i2 + 32 >> 2] = +HEAPF32[i1 + 20 >> 2];
michael@0 35135 HEAPF32[i2 + 36 >> 2] = +HEAPF32[i1 + 24 >> 2];
michael@0 35136 HEAPF32[i2 + 40 >> 2] = +HEAPF32[i1 + 28 >> 2];
michael@0 35137 HEAPF32[i2 + 44 >> 2] = +HEAPF32[i1 + 32 >> 2];
michael@0 35138 HEAPF32[i2 + 48 >> 2] = +HEAPF32[i1 + 36 >> 2];
michael@0 35139 HEAPF32[i2 + 52 >> 2] = +HEAPF32[i1 + 40 >> 2];
michael@0 35140 HEAPF32[i2 + 56 >> 2] = +HEAPF32[i1 + 44 >> 2];
michael@0 35141 HEAPF32[i2 + 60 >> 2] = +HEAPF32[i1 + 48 >> 2];
michael@0 35142 HEAPF32[i2 + 64 >> 2] = +HEAPF32[i1 + 52 >> 2];
michael@0 35143 HEAPF32[i2 + 68 >> 2] = +HEAPF32[i1 + 56 >> 2];
michael@0 35144 HEAPF32[i2 + 72 >> 2] = +HEAPF32[i1 + 60 >> 2];
michael@0 35145 HEAPF32[i2 + 76 >> 2] = +HEAPF32[i1 + 64 >> 2];
michael@0 35146 HEAPF32[i2 + 80 >> 2] = +HEAPF32[i1 + 68 >> 2];
michael@0 35147 HEAPF32[i2 + 84 >> 2] = +HEAPF32[i1 + 72 >> 2];
michael@0 35148 HEAPF32[i2 + 88 >> 2] = +HEAPF32[i1 + 76 >> 2];
michael@0 35149 HEAPF32[i2 + 92 >> 2] = +HEAPF32[i1 + 80 >> 2];
michael@0 35150 HEAPF32[i2 + 96 >> 2] = +HEAPF32[i1 + 84 >> 2];
michael@0 35151 HEAPF32[i2 + 100 >> 2] = +HEAPF32[i1 + 88 >> 2];
michael@0 35152 HEAPF32[i2 + 104 >> 2] = +HEAPF32[i1 + 92 >> 2];
michael@0 35153 HEAPF32[i2 + 108 >> 2] = +HEAPF32[i1 + 96 >> 2];
michael@0 35154 HEAPF32[i2 + 112 >> 2] = +HEAPF32[i1 + 100 >> 2];
michael@0 35155 HEAPF32[i2 + 116 >> 2] = +HEAPF32[i1 + 104 >> 2];
michael@0 35156 HEAPF32[i2 + 120 >> 2] = +HEAPF32[i1 + 108 >> 2];
michael@0 35157 HEAPF32[i2 + 124 >> 2] = +HEAPF32[i1 + 112 >> 2];
michael@0 35158 HEAPF32[i2 + 128 >> 2] = +HEAPF32[i1 + 116 >> 2];
michael@0 35159 HEAPF32[i2 + 132 >> 2] = +HEAPF32[i1 + 120 >> 2];
michael@0 35160 HEAPF32[i2 + 136 >> 2] = +HEAPF32[i1 + 124 >> 2];
michael@0 35161 HEAPF32[i2 + 140 >> 2] = +HEAPF32[i1 + 128 >> 2];
michael@0 35162 HEAPF32[i2 + 144 >> 2] = +HEAPF32[i1 + 132 >> 2];
michael@0 35163 HEAPF32[i2 + 148 >> 2] = +HEAPF32[i1 + 136 >> 2];
michael@0 35164 HEAPF32[i2 + 152 >> 2] = +HEAPF32[i1 + 140 >> 2];
michael@0 35165 HEAPF32[i2 + 156 >> 2] = +HEAPF32[i1 + 144 >> 2];
michael@0 35166 HEAPF32[i2 + 160 >> 2] = +HEAPF32[i1 + 148 >> 2];
michael@0 35167 HEAPF32[i2 + 164 >> 2] = +HEAPF32[i1 + 152 >> 2];
michael@0 35168 HEAPF32[i2 + 168 >> 2] = +HEAPF32[i1 + 156 >> 2];
michael@0 35169 HEAPF32[i2 + 172 >> 2] = +HEAPF32[i1 + 160 >> 2];
michael@0 35170 HEAPF32[i2 + 176 >> 2] = +HEAPF32[i1 + 164 >> 2];
michael@0 35171 HEAPF32[i2 + 180 >> 2] = +HEAPF32[i1 + 168 >> 2];
michael@0 35172 HEAPF32[i2 + 184 >> 2] = +HEAPF32[i1 + 172 >> 2];
michael@0 35173 HEAPF32[i2 + 188 >> 2] = +HEAPF32[i1 + 176 >> 2];
michael@0 35174 HEAP32[i2 + 220 >> 2] = HEAP32[i1 + 180 >> 2];
michael@0 35175 HEAPF32[i2 + 192 >> 2] = +HEAPF32[i1 + 184 >> 2];
michael@0 35176 HEAP32[i2 >> 2] = 0;
michael@0 35177 i4 = i3;
michael@0 35178 HEAP32[i2 + 4 >> 2] = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 28 >> 2] & 63](i3, HEAP32[i1 + 192 >> 2] | 0) | 0;
michael@0 35179 HEAP32[i2 + 8 >> 2] = 0;
michael@0 35180 HEAP32[i2 + 224 >> 2] = HEAP32[i1 + 204 >> 2];
michael@0 35181 HEAP32[i2 + 228 >> 2] = HEAP32[i1 + 208 >> 2];
michael@0 35182 HEAP32[i2 + 232 >> 2] = HEAP32[i1 + 212 >> 2];
michael@0 35183 i5 = i1 + 216 | 0;
michael@0 35184 i6 = i2 + 236 | 0;
michael@0 35185 HEAP32[i6 >> 2] = HEAP32[i5 >> 2];
michael@0 35186 HEAP32[i6 >> 2] = HEAP32[i5 >> 2];
michael@0 35187 HEAPF32[i2 + 196 >> 2] = +HEAPF32[i1 + 220 >> 2];
michael@0 35188 HEAPF32[i2 + 200 >> 2] = +HEAPF32[i1 + 224 >> 2];
michael@0 35189 HEAPF32[i2 + 204 >> 2] = +HEAPF32[i1 + 228 >> 2];
michael@0 35190 HEAP32[i2 + 240 >> 2] = HEAP32[i1 + 232 >> 2];
michael@0 35191 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 40 >> 2] & 63](i3, i1) | 0;
michael@0 35192 i6 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 28 >> 2] & 63](i3, i5) | 0;
michael@0 35193 HEAP32[i2 + 12 >> 2] = i6;
michael@0 35194 if ((i6 | 0) == 0) {
michael@0 35195 i7 = i1 + 240 | 0;
michael@0 35196 d8 = +HEAPF32[i7 >> 2];
michael@0 35197 i9 = i2 + 208 | 0;
michael@0 35198 i10 = i9;
michael@0 35199 HEAPF32[i10 >> 2] = d8;
michael@0 35200 i11 = i1 + 244 | 0;
michael@0 35201 d12 = +HEAPF32[i11 >> 2];
michael@0 35202 i13 = i2 + 212 | 0;
michael@0 35203 i14 = i13;
michael@0 35204 HEAPF32[i14 >> 2] = d12;
michael@0 35205 i15 = i1 + 248 | 0;
michael@0 35206 d16 = +HEAPF32[i15 >> 2];
michael@0 35207 i17 = i2 + 216 | 0;
michael@0 35208 i18 = i17;
michael@0 35209 HEAPF32[i18 >> 2] = d16;
michael@0 35210 d19 = +HEAPF32[i15 >> 2];
michael@0 35211 HEAPF32[i18 >> 2] = d19;
michael@0 35212 i20 = i1 + 252 | 0;
michael@0 35213 i21 = HEAP32[i20 >> 2] | 0;
michael@0 35214 i22 = i2 + 244 | 0;
michael@0 35215 i23 = i22;
michael@0 35216 HEAP32[i23 >> 2] = i21;
michael@0 35217 return 24;
michael@0 35218 }
michael@0 35219 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 48 >> 2] & 127](i3, i5);
michael@0 35220 i7 = i1 + 240 | 0;
michael@0 35221 d8 = +HEAPF32[i7 >> 2];
michael@0 35222 i9 = i2 + 208 | 0;
michael@0 35223 i10 = i9;
michael@0 35224 HEAPF32[i10 >> 2] = d8;
michael@0 35225 i11 = i1 + 244 | 0;
michael@0 35226 d12 = +HEAPF32[i11 >> 2];
michael@0 35227 i13 = i2 + 212 | 0;
michael@0 35228 i14 = i13;
michael@0 35229 HEAPF32[i14 >> 2] = d12;
michael@0 35230 i15 = i1 + 248 | 0;
michael@0 35231 d16 = +HEAPF32[i15 >> 2];
michael@0 35232 i17 = i2 + 216 | 0;
michael@0 35233 i18 = i17;
michael@0 35234 HEAPF32[i18 >> 2] = d16;
michael@0 35235 d19 = +HEAPF32[i15 >> 2];
michael@0 35236 HEAPF32[i18 >> 2] = d19;
michael@0 35237 i20 = i1 + 252 | 0;
michael@0 35238 i21 = HEAP32[i20 >> 2] | 0;
michael@0 35239 i22 = i2 + 244 | 0;
michael@0 35240 i23 = i22;
michael@0 35241 HEAP32[i23 >> 2] = i21;
michael@0 35242 return 24;
michael@0 35243 }
michael@0 35244 function __ZL10insertleafP6btDbvtP10btDbvtNodeS2_(i1, i2, i3) {
michael@0 35245 i1 = i1 | 0;
michael@0 35246 i2 = i2 | 0;
michael@0 35247 i3 = i3 | 0;
michael@0 35248 var i4 = 0, i5 = 0, i6 = 0, d7 = 0.0, d8 = 0.0, d9 = 0.0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, i16 = 0, i17 = 0, i18 = 0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0;
michael@0 35249 i4 = i1 | 0;
michael@0 35250 if ((HEAP32[i4 >> 2] | 0) == 0) {
michael@0 35251 HEAP32[i4 >> 2] = i3;
michael@0 35252 HEAP32[i3 + 32 >> 2] = 0;
michael@0 35253 return;
michael@0 35254 }
michael@0 35255 i5 = HEAP32[i2 + 40 >> 2] | 0;
michael@0 35256 if ((i5 | 0) == 0) {
michael@0 35257 i6 = i2;
michael@0 35258 } else {
michael@0 35259 d7 = +HEAPF32[i3 >> 2] + +HEAPF32[i3 + 16 >> 2];
michael@0 35260 d8 = +HEAPF32[i3 + 4 >> 2] + +HEAPF32[i3 + 20 >> 2];
michael@0 35261 d9 = +HEAPF32[i3 + 8 >> 2] + +HEAPF32[i3 + 24 >> 2];
michael@0 35262 i10 = i2;
michael@0 35263 i2 = i5;
michael@0 35264 while (1) {
michael@0 35265 i5 = HEAP32[i10 + 36 >> 2] | 0;
michael@0 35266 d11 = d8 - (+HEAPF32[i5 + 4 >> 2] + +HEAPF32[i5 + 20 >> 2]);
michael@0 35267 d12 = d9 - (+HEAPF32[i5 + 8 >> 2] + +HEAPF32[i5 + 24 >> 2]);
michael@0 35268 d13 = +Math_abs(+(d7 - (+HEAPF32[i5 >> 2] + +HEAPF32[i5 + 16 >> 2])));
michael@0 35269 d14 = d13 + +Math_abs(+d11);
michael@0 35270 d11 = d14 + +Math_abs(+d12);
michael@0 35271 d12 = d8 - (+HEAPF32[i2 + 4 >> 2] + +HEAPF32[i2 + 20 >> 2]);
michael@0 35272 d14 = d9 - (+HEAPF32[i2 + 8 >> 2] + +HEAPF32[i2 + 24 >> 2]);
michael@0 35273 d13 = +Math_abs(+(d7 - (+HEAPF32[i2 >> 2] + +HEAPF32[i2 + 16 >> 2])));
michael@0 35274 d15 = d13 + +Math_abs(+d12);
michael@0 35275 i5 = HEAP32[i10 + 36 + ((d11 >= d15 + +Math_abs(+d14)) << 2) >> 2] | 0;
michael@0 35276 i16 = HEAP32[i5 + 40 >> 2] | 0;
michael@0 35277 if ((i16 | 0) == 0) {
michael@0 35278 i6 = i5;
michael@0 35279 break;
michael@0 35280 } else {
michael@0 35281 i10 = i5;
michael@0 35282 i2 = i16;
michael@0 35283 }
michael@0 35284 }
michael@0 35285 }
michael@0 35286 i2 = i6 + 32 | 0;
michael@0 35287 i10 = HEAP32[i2 >> 2] | 0;
michael@0 35288 i16 = i1 + 4 | 0;
michael@0 35289 i1 = HEAP32[i16 >> 2] | 0;
michael@0 35290 do {
michael@0 35291 if ((i1 | 0) == 0) {
michael@0 35292 i5 = __Z22btAlignedAllocInternalji(44, 16) | 0;
michael@0 35293 if ((i5 | 0) == 0) {
michael@0 35294 i17 = 0;
michael@0 35295 break;
michael@0 35296 }
michael@0 35297 _memset(i5 | 0, 0, 44);
michael@0 35298 i17 = i5;
michael@0 35299 } else {
michael@0 35300 HEAP32[i16 >> 2] = 0;
michael@0 35301 i17 = i1;
michael@0 35302 }
michael@0 35303 } while (0);
michael@0 35304 HEAP32[i17 + 32 >> 2] = i10;
michael@0 35305 i1 = i17 + 36 | 0;
michael@0 35306 HEAP32[i1 >> 2] = 0;
michael@0 35307 i16 = i17 + 40 | 0;
michael@0 35308 HEAP32[i16 >> 2] = 0;
michael@0 35309 d7 = +HEAPF32[i3 >> 2];
michael@0 35310 d9 = +HEAPF32[i6 >> 2];
michael@0 35311 d8 = d7 < d9 ? d7 : d9;
michael@0 35312 HEAPF32[i17 >> 2] = d8;
michael@0 35313 d9 = +HEAPF32[i3 + 16 >> 2];
michael@0 35314 d7 = +HEAPF32[i6 + 16 >> 2];
michael@0 35315 d14 = d9 > d7 ? d9 : d7;
michael@0 35316 HEAPF32[i17 + 16 >> 2] = d14;
michael@0 35317 d7 = +HEAPF32[i3 + 4 >> 2];
michael@0 35318 d9 = +HEAPF32[i6 + 4 >> 2];
michael@0 35319 d15 = d7 < d9 ? d7 : d9;
michael@0 35320 HEAPF32[i17 + 4 >> 2] = d15;
michael@0 35321 d9 = +HEAPF32[i3 + 20 >> 2];
michael@0 35322 d7 = +HEAPF32[i6 + 20 >> 2];
michael@0 35323 d11 = d9 > d7 ? d9 : d7;
michael@0 35324 HEAPF32[i17 + 20 >> 2] = d11;
michael@0 35325 d7 = +HEAPF32[i3 + 8 >> 2];
michael@0 35326 d9 = +HEAPF32[i6 + 8 >> 2];
michael@0 35327 d12 = d7 < d9 ? d7 : d9;
michael@0 35328 HEAPF32[i17 + 8 >> 2] = d12;
michael@0 35329 d9 = +HEAPF32[i3 + 24 >> 2];
michael@0 35330 d7 = +HEAPF32[i6 + 24 >> 2];
michael@0 35331 d13 = d9 > d7 ? d9 : d7;
michael@0 35332 HEAPF32[i17 + 24 >> 2] = d13;
michael@0 35333 if ((i10 | 0) == 0) {
michael@0 35334 HEAP32[i1 >> 2] = i6;
michael@0 35335 HEAP32[i2 >> 2] = i17;
michael@0 35336 HEAP32[i16 >> 2] = i3;
michael@0 35337 HEAP32[i3 + 32 >> 2] = i17;
michael@0 35338 HEAP32[i4 >> 2] = i17;
michael@0 35339 return;
michael@0 35340 }
michael@0 35341 HEAP32[i10 + 36 + (((HEAP32[(HEAP32[i2 >> 2] | 0) + 40 >> 2] | 0) == (i6 | 0)) << 2) >> 2] = i17;
michael@0 35342 HEAP32[i1 >> 2] = i6;
michael@0 35343 HEAP32[i2 >> 2] = i17;
michael@0 35344 HEAP32[i16 >> 2] = i3;
michael@0 35345 HEAP32[i3 + 32 >> 2] = i17;
michael@0 35346 i17 = i10;
michael@0 35347 d7 = d8;
michael@0 35348 d8 = d15;
michael@0 35349 d15 = d12;
michael@0 35350 d12 = d14;
michael@0 35351 d14 = d11;
michael@0 35352 d11 = d13;
michael@0 35353 L2338 : while (1) {
michael@0 35354 i10 = i17 | 0;
michael@0 35355 i3 = i17 + 4 | 0;
michael@0 35356 do {
michael@0 35357 if (+HEAPF32[i10 >> 2] <= d7) {
michael@0 35358 if (+HEAPF32[i3 >> 2] > d8) {
michael@0 35359 break;
michael@0 35360 }
michael@0 35361 if (+HEAPF32[i17 + 8 >> 2] > d15) {
michael@0 35362 break;
michael@0 35363 }
michael@0 35364 if (+HEAPF32[i17 + 16 >> 2] < d12) {
michael@0 35365 break;
michael@0 35366 }
michael@0 35367 if (+HEAPF32[i17 + 20 >> 2] < d14) {
michael@0 35368 break;
michael@0 35369 }
michael@0 35370 if (+HEAPF32[i17 + 24 >> 2] >= d11) {
michael@0 35371 i18 = 1980;
michael@0 35372 break L2338;
michael@0 35373 }
michael@0 35374 }
michael@0 35375 } while (0);
michael@0 35376 i16 = HEAP32[i17 + 36 >> 2] | 0;
michael@0 35377 i2 = HEAP32[i17 + 40 >> 2] | 0;
michael@0 35378 d13 = +HEAPF32[i16 >> 2];
michael@0 35379 d9 = +HEAPF32[i2 >> 2];
michael@0 35380 d19 = d13 < d9 ? d13 : d9;
michael@0 35381 HEAPF32[i10 >> 2] = d19;
michael@0 35382 d9 = +HEAPF32[i16 + 16 >> 2];
michael@0 35383 d13 = +HEAPF32[i2 + 16 >> 2];
michael@0 35384 d20 = d9 > d13 ? d9 : d13;
michael@0 35385 HEAPF32[i17 + 16 >> 2] = d20;
michael@0 35386 d13 = +HEAPF32[i16 + 4 >> 2];
michael@0 35387 d9 = +HEAPF32[i2 + 4 >> 2];
michael@0 35388 d21 = d13 < d9 ? d13 : d9;
michael@0 35389 HEAPF32[i3 >> 2] = d21;
michael@0 35390 d9 = +HEAPF32[i16 + 20 >> 2];
michael@0 35391 d13 = +HEAPF32[i2 + 20 >> 2];
michael@0 35392 d22 = d9 > d13 ? d9 : d13;
michael@0 35393 HEAPF32[i17 + 20 >> 2] = d22;
michael@0 35394 d13 = +HEAPF32[i16 + 8 >> 2];
michael@0 35395 d9 = +HEAPF32[i2 + 8 >> 2];
michael@0 35396 d23 = d13 < d9 ? d13 : d9;
michael@0 35397 HEAPF32[i17 + 8 >> 2] = d23;
michael@0 35398 d9 = +HEAPF32[i16 + 24 >> 2];
michael@0 35399 d13 = +HEAPF32[i2 + 24 >> 2];
michael@0 35400 d24 = d9 > d13 ? d9 : d13;
michael@0 35401 HEAPF32[i17 + 24 >> 2] = d24;
michael@0 35402 i2 = HEAP32[i17 + 32 >> 2] | 0;
michael@0 35403 if ((i2 | 0) == 0) {
michael@0 35404 i18 = 1981;
michael@0 35405 break;
michael@0 35406 } else {
michael@0 35407 i17 = i2;
michael@0 35408 d7 = d19;
michael@0 35409 d8 = d21;
michael@0 35410 d15 = d23;
michael@0 35411 d12 = d20;
michael@0 35412 d14 = d22;
michael@0 35413 d11 = d24;
michael@0 35414 }
michael@0 35415 }
michael@0 35416 if ((i18 | 0) == 1980) {
michael@0 35417 return;
michael@0 35418 } else if ((i18 | 0) == 1981) {
michael@0 35419 return;
michael@0 35420 }
michael@0 35421 }
michael@0 35422 function __ZN16btDbvtBroadphase7setAabbEP17btBroadphaseProxyRK9btVector3S4_P12btDispatcher(i1, i2, i3, i4, i5) {
michael@0 35423 i1 = i1 | 0;
michael@0 35424 i2 = i2 | 0;
michael@0 35425 i3 = i3 | 0;
michael@0 35426 i4 = i4 | 0;
michael@0 35427 i5 = i5 | 0;
michael@0 35428 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, i22 = 0, i23 = 0, i24 = 0;
michael@0 35429 i5 = STACKTOP;
michael@0 35430 STACKTOP = STACKTOP + 64 | 0;
michael@0 35431 i6 = i5 | 0;
michael@0 35432 i7 = i5 + 32 | 0;
michael@0 35433 i8 = i5 + 48 | 0;
michael@0 35434 i9 = i2;
michael@0 35435 i10 = i6;
michael@0 35436 i11 = i3;
michael@0 35437 HEAP32[i10 >> 2] = HEAP32[i11 >> 2];
michael@0 35438 HEAP32[i10 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 35439 HEAP32[i10 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 35440 HEAP32[i10 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 35441 i10 = i6 + 16 | 0;
michael@0 35442 i12 = i4;
michael@0 35443 HEAP32[i10 >> 2] = HEAP32[i12 >> 2];
michael@0 35444 HEAP32[i10 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 35445 HEAP32[i10 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 35446 HEAP32[i10 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 35447 i10 = i2 + 60 | 0;
michael@0 35448 L880 : do {
michael@0 35449 if ((HEAP32[i10 >> 2] | 0) == 2) {
michael@0 35450 i4 = i2 + 48 | 0;
michael@0 35451 __ZN6btDbvt6removeEP10btDbvtNode(i1 + 44 | 0, HEAP32[i4 >> 2] | 0);
michael@0 35452 HEAP32[i4 >> 2] = __ZN6btDbvt6insertERK12btDbvtAabbMmPv(i1 + 4 | 0, i6, i2) | 0;
michael@0 35453 i13 = 1;
michael@0 35454 } else {
michael@0 35455 i4 = i1 + 128 | 0;
michael@0 35456 HEAP32[i4 >> 2] = (HEAP32[i4 >> 2] | 0) + 1;
michael@0 35457 i4 = HEAP32[i2 + 48 >> 2] | 0;
michael@0 35458 do {
michael@0 35459 if (+HEAPF32[i4 >> 2] <= +HEAPF32[i6 + 16 >> 2]) {
michael@0 35460 if (+HEAPF32[i4 + 16 >> 2] < +HEAPF32[i6 >> 2]) {
michael@0 35461 break;
michael@0 35462 }
michael@0 35463 if (+HEAPF32[i4 + 4 >> 2] > +HEAPF32[i6 + 20 >> 2]) {
michael@0 35464 break;
michael@0 35465 }
michael@0 35466 if (+HEAPF32[i4 + 20 >> 2] < +HEAPF32[i6 + 4 >> 2]) {
michael@0 35467 break;
michael@0 35468 }
michael@0 35469 if (+HEAPF32[i4 + 8 >> 2] > +HEAPF32[i6 + 24 >> 2]) {
michael@0 35470 break;
michael@0 35471 }
michael@0 35472 if (+HEAPF32[i4 + 24 >> 2] < +HEAPF32[i6 + 8 >> 2]) {
michael@0 35473 break;
michael@0 35474 }
michael@0 35475 d14 = +HEAPF32[i2 + 16 >> 2];
michael@0 35476 d15 = +HEAPF32[i3 >> 2] - d14;
michael@0 35477 d16 = +HEAPF32[i2 + 20 >> 2];
michael@0 35478 d17 = +HEAPF32[i3 + 4 >> 2] - d16;
michael@0 35479 d18 = +HEAPF32[i2 + 24 >> 2];
michael@0 35480 d19 = +HEAPF32[i3 + 8 >> 2] - d18;
michael@0 35481 d20 = +HEAPF32[i1 + 100 >> 2];
michael@0 35482 d21 = (+HEAPF32[i2 + 32 >> 2] - d14) * .5 * d20;
michael@0 35483 d14 = d20 * (+HEAPF32[i2 + 36 >> 2] - d16) * .5;
michael@0 35484 d16 = d20 * (+HEAPF32[i2 + 40 >> 2] - d18) * .5;
michael@0 35485 i22 = i7 | 0;
michael@0 35486 HEAPF32[i22 >> 2] = d21;
michael@0 35487 i23 = i7 + 4 | 0;
michael@0 35488 HEAPF32[i23 >> 2] = d14;
michael@0 35489 i24 = i7 + 8 | 0;
michael@0 35490 HEAPF32[i24 >> 2] = d16;
michael@0 35491 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 35492 if (d15 < 0.0) {
michael@0 35493 HEAPF32[i22 >> 2] = -0.0 - d21;
michael@0 35494 }
michael@0 35495 if (d17 < 0.0) {
michael@0 35496 HEAPF32[i23 >> 2] = -0.0 - d14;
michael@0 35497 }
michael@0 35498 if (d19 < 0.0) {
michael@0 35499 HEAPF32[i24 >> 2] = -0.0 - d16;
michael@0 35500 }
michael@0 35501 if (!(__ZN6btDbvt6updateEP10btDbvtNodeR12btDbvtAabbMmRK9btVector3f(i1 + 4 | 0, i4, i6, i7, .05000000074505806) | 0)) {
michael@0 35502 i13 = 0;
michael@0 35503 break L880;
michael@0 35504 }
michael@0 35505 i24 = i1 + 132 | 0;
michael@0 35506 HEAP32[i24 >> 2] = (HEAP32[i24 >> 2] | 0) + 1;
michael@0 35507 i13 = 1;
michael@0 35508 break L880;
michael@0 35509 }
michael@0 35510 } while (0);
michael@0 35511 __ZN6btDbvt6updateEP10btDbvtNodeR12btDbvtAabbMm(i1 + 4 | 0, i4, i6);
michael@0 35512 i24 = i1 + 132 | 0;
michael@0 35513 HEAP32[i24 >> 2] = (HEAP32[i24 >> 2] | 0) + 1;
michael@0 35514 i13 = 1;
michael@0 35515 }
michael@0 35516 } while (0);
michael@0 35517 i6 = i2 + 52 | 0;
michael@0 35518 i7 = HEAP32[i6 >> 2] | 0;
michael@0 35519 i3 = i2 + 56 | 0;
michael@0 35520 i24 = HEAP32[i3 >> 2] | 0;
michael@0 35521 if ((i7 | 0) == 0) {
michael@0 35522 HEAP32[i1 + 84 + (HEAP32[i10 >> 2] << 2) >> 2] = i24;
michael@0 35523 } else {
michael@0 35524 HEAP32[i7 + 56 >> 2] = i24;
michael@0 35525 }
michael@0 35526 i24 = HEAP32[i3 >> 2] | 0;
michael@0 35527 if ((i24 | 0) != 0) {
michael@0 35528 HEAP32[i24 + 52 >> 2] = HEAP32[i6 >> 2];
michael@0 35529 }
michael@0 35530 i24 = i2 + 16 | 0;
michael@0 35531 HEAP32[i24 >> 2] = HEAP32[i11 >> 2];
michael@0 35532 HEAP32[i24 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 35533 HEAP32[i24 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 35534 HEAP32[i24 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 35535 i11 = i2 + 32 | 0;
michael@0 35536 HEAP32[i11 >> 2] = HEAP32[i12 >> 2];
michael@0 35537 HEAP32[i11 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 35538 HEAP32[i11 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 35539 HEAP32[i11 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 35540 i12 = i1 + 104 | 0;
michael@0 35541 HEAP32[i10 >> 2] = HEAP32[i12 >> 2];
michael@0 35542 i10 = i1 + 84 + (HEAP32[i12 >> 2] << 2) | 0;
michael@0 35543 HEAP32[i6 >> 2] = 0;
michael@0 35544 HEAP32[i3 >> 2] = HEAP32[i10 >> 2];
michael@0 35545 i3 = HEAP32[i10 >> 2] | 0;
michael@0 35546 if ((i3 | 0) != 0) {
michael@0 35547 HEAP32[i3 + 52 >> 2] = i9;
michael@0 35548 }
michael@0 35549 HEAP32[i10 >> 2] = i9;
michael@0 35550 if (!i13) {
michael@0 35551 STACKTOP = i5;
michael@0 35552 return;
michael@0 35553 }
michael@0 35554 HEAP8[i1 + 154 | 0] = 1;
michael@0 35555 if ((HEAP8[i1 + 153 | 0] | 0) != 0) {
michael@0 35556 STACKTOP = i5;
michael@0 35557 return;
michael@0 35558 }
michael@0 35559 HEAP32[i8 >> 2] = 4064;
michael@0 35560 HEAP32[i8 + 4 >> 2] = i1;
michael@0 35561 i13 = i1 + 44 | 0;
michael@0 35562 i9 = i2 + 48 | 0;
michael@0 35563 i2 = i8 | 0;
michael@0 35564 __ZN6btDbvt24collideTTpersistentStackEPK10btDbvtNodeS2_RNS_8ICollideE(i13, HEAP32[i13 >> 2] | 0, HEAP32[i9 >> 2] | 0, i2);
michael@0 35565 i13 = i1 + 4 | 0;
michael@0 35566 __ZN6btDbvt24collideTTpersistentStackEPK10btDbvtNodeS2_RNS_8ICollideE(i13, HEAP32[i13 >> 2] | 0, HEAP32[i9 >> 2] | 0, i2);
michael@0 35567 STACKTOP = i5;
michael@0 35568 return;
michael@0 35569 }
michael@0 35570 function __ZN22btVoronoiSimplexSolver22closestPtPointTriangleERK9btVector3S2_S2_S2_R25btSubSimplexClosestResult(i1, i2, i3, i4, i5, i6) {
michael@0 35571 i1 = i1 | 0;
michael@0 35572 i2 = i2 | 0;
michael@0 35573 i3 = i3 | 0;
michael@0 35574 i4 = i4 | 0;
michael@0 35575 i5 = i5 | 0;
michael@0 35576 i6 = i6 | 0;
michael@0 35577 var i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, i31 = 0, d32 = 0.0, d33 = 0.0;
michael@0 35578 i1 = i6 + 16 | 0;
michael@0 35579 i7 = HEAP16[i1 >> 1] & -16;
michael@0 35580 HEAP16[i1 >> 1] = i7;
michael@0 35581 d8 = +HEAPF32[i4 >> 2];
michael@0 35582 d9 = +HEAPF32[i3 >> 2];
michael@0 35583 d10 = d8 - d9;
michael@0 35584 d11 = +HEAPF32[i4 + 4 >> 2];
michael@0 35585 d12 = +HEAPF32[i3 + 4 >> 2];
michael@0 35586 d13 = d11 - d12;
michael@0 35587 d14 = +HEAPF32[i4 + 8 >> 2];
michael@0 35588 d15 = +HEAPF32[i3 + 8 >> 2];
michael@0 35589 d16 = d14 - d15;
michael@0 35590 d17 = +HEAPF32[i5 >> 2];
michael@0 35591 d18 = d17 - d9;
michael@0 35592 d19 = +HEAPF32[i5 + 4 >> 2];
michael@0 35593 d20 = d19 - d12;
michael@0 35594 d21 = +HEAPF32[i5 + 8 >> 2];
michael@0 35595 d22 = d21 - d15;
michael@0 35596 d23 = +HEAPF32[i2 >> 2];
michael@0 35597 d24 = d23 - d9;
michael@0 35598 d25 = +HEAPF32[i2 + 4 >> 2];
michael@0 35599 d26 = d25 - d12;
michael@0 35600 d27 = +HEAPF32[i2 + 8 >> 2];
michael@0 35601 d28 = d27 - d15;
michael@0 35602 d29 = d10 * d24 + d13 * d26 + d16 * d28;
michael@0 35603 d30 = d18 * d24 + d20 * d26 + d22 * d28;
michael@0 35604 if (!(d29 > 0.0 | d30 > 0.0)) {
michael@0 35605 i2 = i6;
michael@0 35606 i31 = i3;
michael@0 35607 HEAP32[i2 >> 2] = HEAP32[i31 >> 2];
michael@0 35608 HEAP32[i2 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 35609 HEAP32[i2 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 35610 HEAP32[i2 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 35611 HEAP16[i1 >> 1] = i7 | 1;
michael@0 35612 HEAPF32[i6 + 20 >> 2] = 1.0;
michael@0 35613 HEAPF32[i6 + 24 >> 2] = 0.0;
michael@0 35614 HEAPF32[i6 + 28 >> 2] = 0.0;
michael@0 35615 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 35616 return 1;
michael@0 35617 }
michael@0 35618 d28 = d23 - d8;
michael@0 35619 d26 = d25 - d11;
michael@0 35620 d24 = d27 - d14;
michael@0 35621 d32 = d10 * d28 + d13 * d26 + d16 * d24;
michael@0 35622 d33 = d18 * d28 + d20 * d26 + d22 * d24;
michael@0 35623 if (!(d32 < 0.0 | d33 > d32)) {
michael@0 35624 i31 = i6;
michael@0 35625 i2 = i4;
michael@0 35626 HEAP32[i31 >> 2] = HEAP32[i2 >> 2];
michael@0 35627 HEAP32[i31 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 35628 HEAP32[i31 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 35629 HEAP32[i31 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 35630 HEAP16[i1 >> 1] = i7 | 2;
michael@0 35631 HEAPF32[i6 + 20 >> 2] = 0.0;
michael@0 35632 HEAPF32[i6 + 24 >> 2] = 1.0;
michael@0 35633 HEAPF32[i6 + 28 >> 2] = 0.0;
michael@0 35634 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 35635 return 1;
michael@0 35636 }
michael@0 35637 d24 = d29 * d33 - d32 * d30;
michael@0 35638 if (!(d24 > 0.0 | d29 < 0.0 | d32 > 0.0)) {
michael@0 35639 d26 = d29 / (d29 - d32);
michael@0 35640 HEAPF32[i6 >> 2] = d9 + d10 * d26;
michael@0 35641 HEAPF32[i6 + 4 >> 2] = d12 + d13 * d26;
michael@0 35642 HEAPF32[i6 + 8 >> 2] = d15 + d16 * d26;
michael@0 35643 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 35644 HEAP16[i1 >> 1] = i7 | 3;
michael@0 35645 HEAPF32[i6 + 20 >> 2] = 1.0 - d26;
michael@0 35646 HEAPF32[i6 + 24 >> 2] = d26;
michael@0 35647 HEAPF32[i6 + 28 >> 2] = 0.0;
michael@0 35648 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 35649 return 1;
michael@0 35650 }
michael@0 35651 d26 = d23 - d17;
michael@0 35652 d23 = d25 - d19;
michael@0 35653 d25 = d27 - d21;
michael@0 35654 d27 = d10 * d26 + d13 * d23 + d16 * d25;
michael@0 35655 d28 = d18 * d26 + d20 * d23 + d22 * d25;
michael@0 35656 if (!(d28 < 0.0 | d27 > d28)) {
michael@0 35657 i2 = i6;
michael@0 35658 i31 = i5;
michael@0 35659 HEAP32[i2 >> 2] = HEAP32[i31 >> 2];
michael@0 35660 HEAP32[i2 + 4 >> 2] = HEAP32[i31 + 4 >> 2];
michael@0 35661 HEAP32[i2 + 8 >> 2] = HEAP32[i31 + 8 >> 2];
michael@0 35662 HEAP32[i2 + 12 >> 2] = HEAP32[i31 + 12 >> 2];
michael@0 35663 HEAP16[i1 >> 1] = i7 | 4;
michael@0 35664 HEAPF32[i6 + 20 >> 2] = 0.0;
michael@0 35665 HEAPF32[i6 + 24 >> 2] = 0.0;
michael@0 35666 HEAPF32[i6 + 28 >> 2] = 1.0;
michael@0 35667 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 35668 return 1;
michael@0 35669 }
michael@0 35670 d25 = d27 * d30 - d29 * d28;
michael@0 35671 if (!(d25 > 0.0 | d30 < 0.0 | d28 > 0.0)) {
michael@0 35672 d29 = d30 / (d30 - d28);
michael@0 35673 HEAPF32[i6 >> 2] = d9 + d18 * d29;
michael@0 35674 HEAPF32[i6 + 4 >> 2] = d12 + d20 * d29;
michael@0 35675 HEAPF32[i6 + 8 >> 2] = d15 + d22 * d29;
michael@0 35676 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 35677 HEAP16[i1 >> 1] = i7 | 5;
michael@0 35678 HEAPF32[i6 + 20 >> 2] = 1.0 - d29;
michael@0 35679 HEAPF32[i6 + 24 >> 2] = 0.0;
michael@0 35680 HEAPF32[i6 + 28 >> 2] = d29;
michael@0 35681 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 35682 return 1;
michael@0 35683 }
michael@0 35684 d29 = d32 * d28 - d27 * d33;
michael@0 35685 do {
michael@0 35686 if (d29 <= 0.0) {
michael@0 35687 d30 = d33 - d32;
michael@0 35688 if (d30 < 0.0) {
michael@0 35689 break;
michael@0 35690 }
michael@0 35691 d23 = d27 - d28;
michael@0 35692 if (d23 < 0.0) {
michael@0 35693 break;
michael@0 35694 }
michael@0 35695 d26 = d30 / (d30 + d23);
michael@0 35696 HEAPF32[i6 >> 2] = d8 + (d17 - d8) * d26;
michael@0 35697 HEAPF32[i6 + 4 >> 2] = d11 + (d19 - d11) * d26;
michael@0 35698 HEAPF32[i6 + 8 >> 2] = d14 + (d21 - d14) * d26;
michael@0 35699 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 35700 HEAP16[i1 >> 1] = i7 | 6;
michael@0 35701 HEAPF32[i6 + 20 >> 2] = 0.0;
michael@0 35702 HEAPF32[i6 + 24 >> 2] = 1.0 - d26;
michael@0 35703 HEAPF32[i6 + 28 >> 2] = d26;
michael@0 35704 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 35705 return 1;
michael@0 35706 }
michael@0 35707 } while (0);
michael@0 35708 d14 = 1.0 / (d24 + (d29 + d25));
michael@0 35709 d29 = d25 * d14;
michael@0 35710 d25 = d24 * d14;
michael@0 35711 HEAPF32[i6 >> 2] = d18 * d25 + (d9 + d10 * d29);
michael@0 35712 HEAPF32[i6 + 4 >> 2] = d20 * d25 + (d12 + d13 * d29);
michael@0 35713 HEAPF32[i6 + 8 >> 2] = d22 * d25 + (d15 + d16 * d29);
michael@0 35714 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 35715 HEAP16[i1 >> 1] = i7 | 7;
michael@0 35716 HEAPF32[i6 + 20 >> 2] = 1.0 - d29 - d25;
michael@0 35717 HEAPF32[i6 + 24 >> 2] = d29;
michael@0 35718 HEAPF32[i6 + 28 >> 2] = d25;
michael@0 35719 HEAPF32[i6 + 32 >> 2] = 0.0;
michael@0 35720 return 1;
michael@0 35721 }
michael@0 35722 function __ZN16btCollisionWorld16updateSingleAabbEP17btCollisionObject(i1, i2) {
michael@0 35723 i1 = i1 | 0;
michael@0 35724 i2 = i2 | 0;
michael@0 35725 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, i12 = 0, d13 = 0.0, i14 = 0, d15 = 0.0, i16 = 0, d17 = 0.0, i18 = 0, d19 = 0.0, i20 = 0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, i28 = 0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0;
michael@0 35726 i3 = STACKTOP;
michael@0 35727 STACKTOP = STACKTOP + 64 | 0;
michael@0 35728 i4 = i3 | 0;
michael@0 35729 i5 = i3 + 16 | 0;
michael@0 35730 i6 = i3 + 32 | 0;
michael@0 35731 i7 = i3 + 48 | 0;
michael@0 35732 i8 = i2 + 192 | 0;
michael@0 35733 i9 = HEAP32[i8 >> 2] | 0;
michael@0 35734 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i9 >> 2] | 0) + 8 >> 2] & 127](i9, i2 + 4 | 0, i4, i5);
michael@0 35735 d10 = +HEAPF32[4];
michael@0 35736 i9 = i4 | 0;
michael@0 35737 d11 = +HEAPF32[i9 >> 2] - d10;
michael@0 35738 HEAPF32[i9 >> 2] = d11;
michael@0 35739 i12 = i4 + 4 | 0;
michael@0 35740 d13 = +HEAPF32[i12 >> 2] - d10;
michael@0 35741 HEAPF32[i12 >> 2] = d13;
michael@0 35742 i14 = i4 + 8 | 0;
michael@0 35743 d15 = +HEAPF32[i14 >> 2] - d10;
michael@0 35744 HEAPF32[i14 >> 2] = d15;
michael@0 35745 i16 = i5 | 0;
michael@0 35746 d17 = d10 + +HEAPF32[i16 >> 2];
michael@0 35747 HEAPF32[i16 >> 2] = d17;
michael@0 35748 i18 = i5 + 4 | 0;
michael@0 35749 d19 = d10 + +HEAPF32[i18 >> 2];
michael@0 35750 HEAPF32[i18 >> 2] = d19;
michael@0 35751 i20 = i5 + 8 | 0;
michael@0 35752 d21 = d10 + +HEAPF32[i20 >> 2];
michael@0 35753 HEAPF32[i20 >> 2] = d21;
michael@0 35754 do {
michael@0 35755 if ((HEAP8[i1 + 44 | 0] | 0) == 0) {
michael@0 35756 d22 = d17;
michael@0 35757 d23 = d11;
michael@0 35758 d24 = d19;
michael@0 35759 d25 = d13;
michael@0 35760 d26 = d21;
michael@0 35761 d27 = d15;
michael@0 35762 } else {
michael@0 35763 if ((HEAP32[i2 + 232 >> 2] | 0) != 2) {
michael@0 35764 d22 = d17;
michael@0 35765 d23 = d11;
michael@0 35766 d24 = d19;
michael@0 35767 d25 = d13;
michael@0 35768 d26 = d21;
michael@0 35769 d27 = d15;
michael@0 35770 break;
michael@0 35771 }
michael@0 35772 i28 = HEAP32[i8 >> 2] | 0;
michael@0 35773 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i28 >> 2] | 0) + 8 >> 2] & 127](i28, i2 + 68 | 0, i6, i7);
michael@0 35774 i28 = i6 | 0;
michael@0 35775 d29 = +HEAPF32[i28 >> 2] - d10;
michael@0 35776 HEAPF32[i28 >> 2] = d29;
michael@0 35777 i28 = i6 + 4 | 0;
michael@0 35778 d30 = +HEAPF32[i28 >> 2] - d10;
michael@0 35779 HEAPF32[i28 >> 2] = d30;
michael@0 35780 i28 = i6 + 8 | 0;
michael@0 35781 d31 = +HEAPF32[i28 >> 2] - d10;
michael@0 35782 HEAPF32[i28 >> 2] = d31;
michael@0 35783 i28 = i7 | 0;
michael@0 35784 d32 = d10 + +HEAPF32[i28 >> 2];
michael@0 35785 HEAPF32[i28 >> 2] = d32;
michael@0 35786 i28 = i7 + 4 | 0;
michael@0 35787 d33 = d10 + +HEAPF32[i28 >> 2];
michael@0 35788 HEAPF32[i28 >> 2] = d33;
michael@0 35789 i28 = i7 + 8 | 0;
michael@0 35790 d34 = d10 + +HEAPF32[i28 >> 2];
michael@0 35791 HEAPF32[i28 >> 2] = d34;
michael@0 35792 d35 = +HEAPF32[i9 >> 2];
michael@0 35793 if (d29 < d35) {
michael@0 35794 HEAPF32[i9 >> 2] = d29;
michael@0 35795 d36 = d29;
michael@0 35796 } else {
michael@0 35797 d36 = d35;
michael@0 35798 }
michael@0 35799 d35 = +HEAPF32[i12 >> 2];
michael@0 35800 if (d30 < d35) {
michael@0 35801 HEAPF32[i12 >> 2] = d30;
michael@0 35802 d37 = d30;
michael@0 35803 } else {
michael@0 35804 d37 = d35;
michael@0 35805 }
michael@0 35806 d35 = +HEAPF32[i14 >> 2];
michael@0 35807 if (d31 < d35) {
michael@0 35808 HEAPF32[i14 >> 2] = d31;
michael@0 35809 d38 = d31;
michael@0 35810 } else {
michael@0 35811 d38 = d35;
michael@0 35812 }
michael@0 35813 i28 = i4 + 12 | 0;
michael@0 35814 d35 = +HEAPF32[i6 + 12 >> 2];
michael@0 35815 if (d35 < +HEAPF32[i28 >> 2]) {
michael@0 35816 HEAPF32[i28 >> 2] = d35;
michael@0 35817 }
michael@0 35818 d35 = +HEAPF32[i16 >> 2];
michael@0 35819 if (d35 < d32) {
michael@0 35820 HEAPF32[i16 >> 2] = d32;
michael@0 35821 d39 = d32;
michael@0 35822 } else {
michael@0 35823 d39 = d35;
michael@0 35824 }
michael@0 35825 d35 = +HEAPF32[i18 >> 2];
michael@0 35826 if (d35 < d33) {
michael@0 35827 HEAPF32[i18 >> 2] = d33;
michael@0 35828 d40 = d33;
michael@0 35829 } else {
michael@0 35830 d40 = d35;
michael@0 35831 }
michael@0 35832 d35 = +HEAPF32[i20 >> 2];
michael@0 35833 if (d35 < d34) {
michael@0 35834 HEAPF32[i20 >> 2] = d34;
michael@0 35835 d41 = d34;
michael@0 35836 } else {
michael@0 35837 d41 = d35;
michael@0 35838 }
michael@0 35839 i28 = i5 + 12 | 0;
michael@0 35840 d35 = +HEAPF32[i7 + 12 >> 2];
michael@0 35841 if (+HEAPF32[i28 >> 2] >= d35) {
michael@0 35842 d22 = d39;
michael@0 35843 d23 = d36;
michael@0 35844 d24 = d40;
michael@0 35845 d25 = d37;
michael@0 35846 d26 = d41;
michael@0 35847 d27 = d38;
michael@0 35848 break;
michael@0 35849 }
michael@0 35850 HEAPF32[i28 >> 2] = d35;
michael@0 35851 d22 = d39;
michael@0 35852 d23 = d36;
michael@0 35853 d24 = d40;
michael@0 35854 d25 = d37;
michael@0 35855 d26 = d41;
michael@0 35856 d27 = d38;
michael@0 35857 }
michael@0 35858 } while (0);
michael@0 35859 i7 = HEAP32[i1 + 76 >> 2] | 0;
michael@0 35860 do {
michael@0 35861 if ((HEAP32[i2 + 204 >> 2] & 1 | 0) == 0) {
michael@0 35862 d38 = d22 - d23;
michael@0 35863 d41 = d24 - d25;
michael@0 35864 d37 = d26 - d27;
michael@0 35865 if (d37 * d37 + (d41 * d41 + d38 * d38) < 999999995904.0) {
michael@0 35866 break;
michael@0 35867 }
michael@0 35868 __ZN17btCollisionObject18setActivationStateEi(i2, 5);
michael@0 35869 if (HEAP8[1304] | 0) {
michael@0 35870 STACKTOP = i3;
michael@0 35871 return;
michael@0 35872 }
michael@0 35873 i20 = i1 + 80 | 0;
michael@0 35874 i18 = HEAP32[i20 >> 2] | 0;
michael@0 35875 if ((i18 | 0) == 0) {
michael@0 35876 STACKTOP = i3;
michael@0 35877 return;
michael@0 35878 }
michael@0 35879 HEAP8[1304] = 1;
michael@0 35880 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i18 >> 2] | 0) + 36 >> 2] & 127](i18, 880);
michael@0 35881 i18 = HEAP32[i20 >> 2] | 0;
michael@0 35882 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i18 >> 2] | 0) + 36 >> 2] & 127](i18, 960);
michael@0 35883 i18 = HEAP32[i20 >> 2] | 0;
michael@0 35884 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i18 >> 2] | 0) + 36 >> 2] & 127](i18, 624);
michael@0 35885 i18 = HEAP32[i20 >> 2] | 0;
michael@0 35886 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i18 >> 2] | 0) + 36 >> 2] & 127](i18, 488);
michael@0 35887 STACKTOP = i3;
michael@0 35888 return;
michael@0 35889 }
michael@0 35890 } while (0);
michael@0 35891 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 16 >> 2] & 63](i7, HEAP32[i2 + 188 >> 2] | 0, i4, i5, HEAP32[i1 + 24 >> 2] | 0);
michael@0 35892 STACKTOP = i3;
michael@0 35893 return;
michael@0 35894 }
michael@0 35895 function __ZN9btHashMapI9btHashPtrP16btCollisionShapeE6insertERKS0_RKS2_(i1, i2, i3) {
michael@0 35896 i1 = i1 | 0;
michael@0 35897 i2 = i2 | 0;
michael@0 35898 i3 = i3 | 0;
michael@0 35899 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0;
michael@0 35900 i4 = i2 | 0;
michael@0 35901 i5 = HEAP32[i4 >> 2] | 0;
michael@0 35902 i6 = i5 + ~(i5 << 15) | 0;
michael@0 35903 i7 = (i6 >> 10 ^ i6) * 9 | 0;
michael@0 35904 i6 = i7 >> 6 ^ i7;
michael@0 35905 i7 = i6 + ~(i6 << 11) | 0;
michael@0 35906 i6 = i1 + 48 | 0;
michael@0 35907 i8 = HEAP32[i6 >> 2] | 0;
michael@0 35908 i9 = (i7 >> 16 ^ i7) & i8 - 1;
michael@0 35909 i7 = i5;
michael@0 35910 L333 : do {
michael@0 35911 if (i9 >>> 0 < (HEAP32[i1 + 4 >> 2] | 0) >>> 0) {
michael@0 35912 i5 = HEAP32[(HEAP32[i1 + 12 >> 2] | 0) + (i9 << 2) >> 2] | 0;
michael@0 35913 if ((i5 | 0) == -1) {
michael@0 35914 break;
michael@0 35915 }
michael@0 35916 i10 = HEAP32[i1 + 72 >> 2] | 0;
michael@0 35917 i11 = i1 + 32 | 0;
michael@0 35918 i12 = i5;
michael@0 35919 while (1) {
michael@0 35920 if ((i7 | 0) == (HEAP32[i10 + (i12 << 3) >> 2] | 0)) {
michael@0 35921 break;
michael@0 35922 }
michael@0 35923 i5 = HEAP32[(HEAP32[i11 >> 2] | 0) + (i12 << 2) >> 2] | 0;
michael@0 35924 if ((i5 | 0) == -1) {
michael@0 35925 break L333;
michael@0 35926 } else {
michael@0 35927 i12 = i5;
michael@0 35928 }
michael@0 35929 }
michael@0 35930 if ((i12 | 0) == -1) {
michael@0 35931 break;
michael@0 35932 }
michael@0 35933 HEAP32[(HEAP32[i1 + 52 >> 2] | 0) + (i12 << 2) >> 2] = HEAP32[i3 >> 2];
michael@0 35934 return;
michael@0 35935 }
michael@0 35936 } while (0);
michael@0 35937 i7 = i1 + 44 | 0;
michael@0 35938 i11 = HEAP32[i7 >> 2] | 0;
michael@0 35939 do {
michael@0 35940 if ((i11 | 0) == (i8 | 0)) {
michael@0 35941 i10 = (i8 | 0) == 0 ? 1 : i8 << 1;
michael@0 35942 if ((i8 | 0) >= (i10 | 0)) {
michael@0 35943 i13 = i8;
michael@0 35944 break;
michael@0 35945 }
michael@0 35946 if ((i10 | 0) == 0) {
michael@0 35947 i14 = 0;
michael@0 35948 i15 = i8;
michael@0 35949 } else {
michael@0 35950 i5 = __Z22btAlignedAllocInternalji(i10 << 2, 16) | 0;
michael@0 35951 i14 = i5;
michael@0 35952 i15 = HEAP32[i7 >> 2] | 0;
michael@0 35953 }
michael@0 35954 i5 = i1 + 52 | 0;
michael@0 35955 if ((i15 | 0) > 0) {
michael@0 35956 i16 = 0;
michael@0 35957 do {
michael@0 35958 i17 = i14 + (i16 << 2) | 0;
michael@0 35959 if ((i17 | 0) != 0) {
michael@0 35960 HEAP32[i17 >> 2] = HEAP32[(HEAP32[i5 >> 2] | 0) + (i16 << 2) >> 2];
michael@0 35961 }
michael@0 35962 i16 = i16 + 1 | 0;
michael@0 35963 } while ((i16 | 0) < (i15 | 0));
michael@0 35964 }
michael@0 35965 i16 = HEAP32[i5 >> 2] | 0;
michael@0 35966 i12 = i1 + 56 | 0;
michael@0 35967 if ((i16 | 0) == 0) {
michael@0 35968 i18 = i15;
michael@0 35969 } else {
michael@0 35970 if ((HEAP8[i12] | 0) == 0) {
michael@0 35971 i19 = i15;
michael@0 35972 } else {
michael@0 35973 __Z21btAlignedFreeInternalPv(i16);
michael@0 35974 i19 = HEAP32[i7 >> 2] | 0;
michael@0 35975 }
michael@0 35976 HEAP32[i5 >> 2] = 0;
michael@0 35977 i18 = i19;
michael@0 35978 }
michael@0 35979 HEAP8[i12] = 1;
michael@0 35980 HEAP32[i5 >> 2] = i14;
michael@0 35981 HEAP32[i6 >> 2] = i10;
michael@0 35982 i13 = i18;
michael@0 35983 } else {
michael@0 35984 i13 = i11;
michael@0 35985 }
michael@0 35986 } while (0);
michael@0 35987 i18 = (HEAP32[i1 + 52 >> 2] | 0) + (i13 << 2) | 0;
michael@0 35988 if ((i18 | 0) != 0) {
michael@0 35989 HEAP32[i18 >> 2] = HEAP32[i3 >> 2];
michael@0 35990 }
michael@0 35991 HEAP32[i7 >> 2] = i13 + 1;
michael@0 35992 i13 = i1 + 64 | 0;
michael@0 35993 i7 = HEAP32[i13 >> 2] | 0;
michael@0 35994 i3 = i1 + 68 | 0;
michael@0 35995 do {
michael@0 35996 if ((i7 | 0) == (HEAP32[i3 >> 2] | 0)) {
michael@0 35997 i18 = (i7 | 0) == 0 ? 1 : i7 << 1;
michael@0 35998 if ((i7 | 0) >= (i18 | 0)) {
michael@0 35999 i20 = i7;
michael@0 36000 break;
michael@0 36001 }
michael@0 36002 if ((i18 | 0) == 0) {
michael@0 36003 i21 = 0;
michael@0 36004 i22 = i7;
michael@0 36005 } else {
michael@0 36006 i14 = __Z22btAlignedAllocInternalji(i18 << 3, 16) | 0;
michael@0 36007 i21 = i14;
michael@0 36008 i22 = HEAP32[i13 >> 2] | 0;
michael@0 36009 }
michael@0 36010 i14 = i1 + 72 | 0;
michael@0 36011 if ((i22 | 0) > 0) {
michael@0 36012 i19 = 0;
michael@0 36013 do {
michael@0 36014 i15 = i21 + (i19 << 3) | 0;
michael@0 36015 if ((i15 | 0) != 0) {
michael@0 36016 i12 = (HEAP32[i14 >> 2] | 0) + (i19 << 3) | 0;
michael@0 36017 i16 = i15;
michael@0 36018 i15 = HEAP32[i12 + 4 >> 2] | 0;
michael@0 36019 HEAP32[i16 >> 2] = HEAP32[i12 >> 2];
michael@0 36020 HEAP32[i16 + 4 >> 2] = i15;
michael@0 36021 }
michael@0 36022 i19 = i19 + 1 | 0;
michael@0 36023 } while ((i19 | 0) < (i22 | 0));
michael@0 36024 }
michael@0 36025 i19 = HEAP32[i14 >> 2] | 0;
michael@0 36026 i10 = i1 + 76 | 0;
michael@0 36027 if ((i19 | 0) != 0) {
michael@0 36028 if ((HEAP8[i10] | 0) != 0) {
michael@0 36029 __Z21btAlignedFreeInternalPv(i19);
michael@0 36030 }
michael@0 36031 HEAP32[i14 >> 2] = 0;
michael@0 36032 }
michael@0 36033 HEAP8[i10] = 1;
michael@0 36034 HEAP32[i14 >> 2] = i21;
michael@0 36035 HEAP32[i3 >> 2] = i18;
michael@0 36036 i20 = HEAP32[i13 >> 2] | 0;
michael@0 36037 } else {
michael@0 36038 i20 = i7;
michael@0 36039 }
michael@0 36040 } while (0);
michael@0 36041 i7 = (HEAP32[i1 + 72 >> 2] | 0) + (i20 << 3) | 0;
michael@0 36042 if ((i7 | 0) == 0) {
michael@0 36043 i23 = i20;
michael@0 36044 } else {
michael@0 36045 i20 = i2;
michael@0 36046 i2 = i7;
michael@0 36047 i7 = HEAP32[i20 + 4 >> 2] | 0;
michael@0 36048 HEAP32[i2 >> 2] = HEAP32[i20 >> 2];
michael@0 36049 HEAP32[i2 + 4 >> 2] = i7;
michael@0 36050 i23 = HEAP32[i13 >> 2] | 0;
michael@0 36051 }
michael@0 36052 HEAP32[i13 >> 2] = i23 + 1;
michael@0 36053 if ((i8 | 0) < (HEAP32[i6 >> 2] | 0)) {
michael@0 36054 __ZN9btHashMapI9btHashPtrP16btCollisionShapeE10growTablesERKS0_(i1, 0);
michael@0 36055 i8 = HEAP32[i4 >> 2] | 0;
michael@0 36056 i4 = i8 + ~(i8 << 15) | 0;
michael@0 36057 i8 = (i4 >> 10 ^ i4) * 9 | 0;
michael@0 36058 i4 = i8 >> 6 ^ i8;
michael@0 36059 i8 = i4 + ~(i4 << 11) | 0;
michael@0 36060 i24 = (i8 >> 16 ^ i8) & (HEAP32[i6 >> 2] | 0) - 1;
michael@0 36061 } else {
michael@0 36062 i24 = i9;
michael@0 36063 }
michael@0 36064 i9 = (HEAP32[i1 + 12 >> 2] | 0) + (i24 << 2) | 0;
michael@0 36065 HEAP32[(HEAP32[i1 + 32 >> 2] | 0) + (i11 << 2) >> 2] = HEAP32[i9 >> 2];
michael@0 36066 HEAP32[i9 >> 2] = i11;
michael@0 36067 return;
michael@0 36068 }
michael@0 36069 function __ZN28btHashedOverlappingPairCache20sortOverlappingPairsEP12btDispatcher(i1, i2) {
michael@0 36070 i1 = i1 | 0;
michael@0 36071 i2 = i2 | 0;
michael@0 36072 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0;
michael@0 36073 i3 = STACKTOP;
michael@0 36074 STACKTOP = STACKTOP + 32 | 0;
michael@0 36075 i4 = i3 | 0;
michael@0 36076 i5 = i3 + 8 | 0;
michael@0 36077 i6 = i5 + 16 | 0;
michael@0 36078 HEAP8[i6] = 1;
michael@0 36079 i7 = i5 + 12 | 0;
michael@0 36080 HEAP32[i7 >> 2] = 0;
michael@0 36081 i8 = i5 + 4 | 0;
michael@0 36082 HEAP32[i8 >> 2] = 0;
michael@0 36083 i9 = i5 + 8 | 0;
michael@0 36084 HEAP32[i9 >> 2] = 0;
michael@0 36085 i10 = i1 + 8 | 0;
michael@0 36086 i11 = HEAP32[i10 >> 2] | 0;
michael@0 36087 do {
michael@0 36088 if ((i11 | 0) > 0) {
michael@0 36089 i12 = i1 + 16 | 0;
michael@0 36090 i13 = 0;
michael@0 36091 i14 = 0;
michael@0 36092 i15 = 0;
michael@0 36093 i16 = i11;
michael@0 36094 while (1) {
michael@0 36095 i17 = HEAP32[i12 >> 2] | 0;
michael@0 36096 do {
michael@0 36097 if ((i14 | 0) == (i15 | 0)) {
michael@0 36098 i18 = (i15 | 0) == 0 ? 1 : i15 << 1;
michael@0 36099 if ((i15 | 0) >= (i18 | 0)) {
michael@0 36100 i19 = i15;
michael@0 36101 i20 = i15;
michael@0 36102 i21 = i16;
michael@0 36103 break;
michael@0 36104 }
michael@0 36105 if ((i18 | 0) == 0) {
michael@0 36106 i22 = 0;
michael@0 36107 i23 = i15;
michael@0 36108 } else {
michael@0 36109 i24 = __Z22btAlignedAllocInternalji(i18 << 4, 16) | 0;
michael@0 36110 i22 = i24;
michael@0 36111 i23 = HEAP32[i8 >> 2] | 0;
michael@0 36112 }
michael@0 36113 if ((i23 | 0) > 0) {
michael@0 36114 i24 = 0;
michael@0 36115 do {
michael@0 36116 i25 = HEAP32[i7 >> 2] | 0;
michael@0 36117 HEAP32[i22 + (i24 << 4) >> 2] = HEAP32[i25 + (i24 << 4) >> 2];
michael@0 36118 HEAP32[i22 + (i24 << 4) + 4 >> 2] = HEAP32[i25 + (i24 << 4) + 4 >> 2];
michael@0 36119 HEAP32[i22 + (i24 << 4) + 8 >> 2] = HEAP32[i25 + (i24 << 4) + 8 >> 2];
michael@0 36120 HEAP32[i22 + (i24 << 4) + 12 >> 2] = HEAP32[i25 + (i24 << 4) + 12 >> 2];
michael@0 36121 i24 = i24 + 1 | 0;
michael@0 36122 } while ((i24 | 0) < (i23 | 0));
michael@0 36123 }
michael@0 36124 i24 = HEAP32[i7 >> 2] | 0;
michael@0 36125 if ((i24 | 0) == 0) {
michael@0 36126 i26 = i23;
michael@0 36127 } else {
michael@0 36128 if ((HEAP8[i6] | 0) == 0) {
michael@0 36129 i27 = i23;
michael@0 36130 } else {
michael@0 36131 __Z21btAlignedFreeInternalPv(i24);
michael@0 36132 i27 = HEAP32[i8 >> 2] | 0;
michael@0 36133 }
michael@0 36134 HEAP32[i7 >> 2] = 0;
michael@0 36135 i26 = i27;
michael@0 36136 }
michael@0 36137 HEAP8[i6] = 1;
michael@0 36138 HEAP32[i7 >> 2] = i22;
michael@0 36139 HEAP32[i9 >> 2] = i18;
michael@0 36140 i19 = i26;
michael@0 36141 i20 = i18;
michael@0 36142 i21 = HEAP32[i10 >> 2] | 0;
michael@0 36143 } else {
michael@0 36144 i19 = i14;
michael@0 36145 i20 = i15;
michael@0 36146 i21 = i16;
michael@0 36147 }
michael@0 36148 } while (0);
michael@0 36149 i24 = HEAP32[i7 >> 2] | 0;
michael@0 36150 HEAP32[i24 + (i19 << 4) >> 2] = HEAP32[i17 + (i13 << 4) >> 2];
michael@0 36151 HEAP32[i24 + (i19 << 4) + 4 >> 2] = HEAP32[i17 + (i13 << 4) + 4 >> 2];
michael@0 36152 HEAP32[i24 + (i19 << 4) + 8 >> 2] = HEAP32[i17 + (i13 << 4) + 8 >> 2];
michael@0 36153 HEAP32[i24 + (i19 << 4) + 12 >> 2] = HEAP32[i17 + (i13 << 4) + 12 >> 2];
michael@0 36154 i28 = i19 + 1 | 0;
michael@0 36155 HEAP32[i8 >> 2] = i28;
michael@0 36156 i24 = i13 + 1 | 0;
michael@0 36157 if ((i24 | 0) < (i21 | 0)) {
michael@0 36158 i13 = i24;
michael@0 36159 i14 = i28;
michael@0 36160 i15 = i20;
michael@0 36161 i16 = i21;
michael@0 36162 } else {
michael@0 36163 break;
michael@0 36164 }
michael@0 36165 }
michael@0 36166 if ((i28 | 0) <= 0) {
michael@0 36167 i29 = i28;
michael@0 36168 break;
michael@0 36169 }
michael@0 36170 i16 = i1;
michael@0 36171 i15 = 0;
michael@0 36172 while (1) {
michael@0 36173 i14 = HEAP32[i7 >> 2] | 0;
michael@0 36174 FUNCTION_TABLE_iiiii[HEAP32[(HEAP32[i16 >> 2] | 0) + 12 >> 2] & 31](i1, HEAP32[i14 + (i15 << 4) >> 2] | 0, HEAP32[i14 + (i15 << 4) + 4 >> 2] | 0, i2) | 0;
michael@0 36175 i14 = i15 + 1 | 0;
michael@0 36176 i13 = HEAP32[i8 >> 2] | 0;
michael@0 36177 if ((i14 | 0) < (i13 | 0)) {
michael@0 36178 i15 = i14;
michael@0 36179 } else {
michael@0 36180 i29 = i13;
michael@0 36181 break;
michael@0 36182 }
michael@0 36183 }
michael@0 36184 } else {
michael@0 36185 i29 = 0;
michael@0 36186 }
michael@0 36187 } while (0);
michael@0 36188 i2 = i1 + 56 | 0;
michael@0 36189 if ((HEAP32[i2 >> 2] | 0) > 0) {
michael@0 36190 i28 = HEAP32[i1 + 64 >> 2] | 0;
michael@0 36191 i21 = 0;
michael@0 36192 do {
michael@0 36193 HEAP32[i28 + (i21 << 2) >> 2] = -1;
michael@0 36194 i21 = i21 + 1 | 0;
michael@0 36195 } while ((i21 | 0) < (HEAP32[i2 >> 2] | 0));
michael@0 36196 i30 = HEAP32[i8 >> 2] | 0;
michael@0 36197 } else {
michael@0 36198 i30 = i29;
michael@0 36199 }
michael@0 36200 if ((i30 | 0) > 1) {
michael@0 36201 __ZN20btAlignedObjectArrayI16btBroadphasePairE17quickSortInternalI29btBroadphasePairSortPredicateEEvT_ii(i5, i4, 0, i30 - 1 | 0);
michael@0 36202 i31 = HEAP32[i8 >> 2] | 0;
michael@0 36203 } else {
michael@0 36204 i31 = i30;
michael@0 36205 }
michael@0 36206 if ((i31 | 0) > 0) {
michael@0 36207 i31 = i1;
michael@0 36208 i30 = 0;
michael@0 36209 do {
michael@0 36210 i4 = HEAP32[i7 >> 2] | 0;
michael@0 36211 FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i31 >> 2] | 0) + 8 >> 2] & 31](i1, HEAP32[i4 + (i30 << 4) >> 2] | 0, HEAP32[i4 + (i30 << 4) + 4 >> 2] | 0) | 0;
michael@0 36212 i30 = i30 + 1 | 0;
michael@0 36213 } while ((i30 | 0) < (HEAP32[i8 >> 2] | 0));
michael@0 36214 }
michael@0 36215 i8 = HEAP32[i7 >> 2] | 0;
michael@0 36216 if ((i8 | 0) == 0) {
michael@0 36217 STACKTOP = i3;
michael@0 36218 return;
michael@0 36219 }
michael@0 36220 if ((HEAP8[i6] | 0) != 0) {
michael@0 36221 __Z21btAlignedFreeInternalPv(i8);
michael@0 36222 }
michael@0 36223 HEAP32[i7 >> 2] = 0;
michael@0 36224 STACKTOP = i3;
michael@0 36225 return;
michael@0 36226 }
michael@0 36227 function __ZN22btVoronoiSimplexSolver14reduceVerticesERK15btUsageBitfield(i1, i2) {
michael@0 36228 i1 = i1 | 0;
michael@0 36229 i2 = i2 | 0;
michael@0 36230 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 36231 i3 = i1 | 0;
michael@0 36232 i4 = HEAP32[i3 >> 2] | 0;
michael@0 36233 do {
michael@0 36234 if ((i4 | 0) > 3) {
michael@0 36235 i5 = HEAP16[i2 >> 1] | 0;
michael@0 36236 if ((i5 & 8) != 0) {
michael@0 36237 i6 = i4;
michael@0 36238 i7 = i5;
michael@0 36239 i8 = 588;
michael@0 36240 break;
michael@0 36241 }
michael@0 36242 i5 = i4 - 1 | 0;
michael@0 36243 HEAP32[i3 >> 2] = i5;
michael@0 36244 i9 = i1 + 52 | 0;
michael@0 36245 i10 = i1 + 4 + (i5 << 4) | 0;
michael@0 36246 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 36247 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 36248 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 36249 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 36250 i10 = i1 + 132 | 0;
michael@0 36251 i9 = i1 + 84 + (i5 << 4) | 0;
michael@0 36252 HEAP32[i10 >> 2] = HEAP32[i9 >> 2];
michael@0 36253 HEAP32[i10 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 36254 HEAP32[i10 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 36255 HEAP32[i10 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 36256 i9 = i1 + 212 | 0;
michael@0 36257 i10 = i1 + 164 + (i5 << 4) | 0;
michael@0 36258 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 36259 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 36260 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 36261 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 36262 i11 = i5;
michael@0 36263 i8 = 586;
michael@0 36264 } else {
michael@0 36265 i11 = i4;
michael@0 36266 i8 = 586;
michael@0 36267 }
michael@0 36268 } while (0);
michael@0 36269 do {
michael@0 36270 if ((i8 | 0) == 586) {
michael@0 36271 if ((i11 | 0) <= 2) {
michael@0 36272 i12 = i11;
michael@0 36273 break;
michael@0 36274 }
michael@0 36275 i6 = i11;
michael@0 36276 i7 = HEAP16[i2 >> 1] | 0;
michael@0 36277 i8 = 588;
michael@0 36278 }
michael@0 36279 } while (0);
michael@0 36280 do {
michael@0 36281 if ((i8 | 0) == 588) {
michael@0 36282 if ((i7 & 4) != 0) {
michael@0 36283 i12 = i6;
michael@0 36284 break;
michael@0 36285 }
michael@0 36286 i11 = i6 - 1 | 0;
michael@0 36287 HEAP32[i3 >> 2] = i11;
michael@0 36288 i4 = i1 + 36 | 0;
michael@0 36289 i5 = i1 + 4 + (i11 << 4) | 0;
michael@0 36290 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 36291 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 36292 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 36293 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 36294 i5 = i1 + 116 | 0;
michael@0 36295 i4 = i1 + 84 + (i11 << 4) | 0;
michael@0 36296 HEAP32[i5 >> 2] = HEAP32[i4 >> 2];
michael@0 36297 HEAP32[i5 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 36298 HEAP32[i5 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 36299 HEAP32[i5 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 36300 i4 = i1 + 196 | 0;
michael@0 36301 i5 = i1 + 164 + (i11 << 4) | 0;
michael@0 36302 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 36303 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 36304 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 36305 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 36306 i12 = i11;
michael@0 36307 }
michael@0 36308 } while (0);
michael@0 36309 do {
michael@0 36310 if ((i12 | 0) > 1) {
michael@0 36311 i6 = HEAP16[i2 >> 1] | 0;
michael@0 36312 if ((i6 & 2) != 0) {
michael@0 36313 i13 = i12;
michael@0 36314 i14 = i6;
michael@0 36315 break;
michael@0 36316 }
michael@0 36317 i6 = i12 - 1 | 0;
michael@0 36318 HEAP32[i3 >> 2] = i6;
michael@0 36319 i7 = i1 + 20 | 0;
michael@0 36320 i11 = i1 + 4 + (i6 << 4) | 0;
michael@0 36321 HEAP32[i7 >> 2] = HEAP32[i11 >> 2];
michael@0 36322 HEAP32[i7 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 36323 HEAP32[i7 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 36324 HEAP32[i7 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 36325 i11 = i1 + 100 | 0;
michael@0 36326 i7 = i1 + 84 + (i6 << 4) | 0;
michael@0 36327 HEAP32[i11 >> 2] = HEAP32[i7 >> 2];
michael@0 36328 HEAP32[i11 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 36329 HEAP32[i11 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 36330 HEAP32[i11 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 36331 i7 = i1 + 180 | 0;
michael@0 36332 i11 = i1 + 164 + (i6 << 4) | 0;
michael@0 36333 HEAP32[i7 >> 2] = HEAP32[i11 >> 2];
michael@0 36334 HEAP32[i7 + 4 >> 2] = HEAP32[i11 + 4 >> 2];
michael@0 36335 HEAP32[i7 + 8 >> 2] = HEAP32[i11 + 8 >> 2];
michael@0 36336 HEAP32[i7 + 12 >> 2] = HEAP32[i11 + 12 >> 2];
michael@0 36337 i15 = i6;
michael@0 36338 i8 = 593;
michael@0 36339 } else {
michael@0 36340 i15 = i12;
michael@0 36341 i8 = 593;
michael@0 36342 }
michael@0 36343 } while (0);
michael@0 36344 do {
michael@0 36345 if ((i8 | 0) == 593) {
michael@0 36346 if ((i15 | 0) > 0) {
michael@0 36347 i13 = i15;
michael@0 36348 i14 = HEAP16[i2 >> 1] | 0;
michael@0 36349 break;
michael@0 36350 } else {
michael@0 36351 return;
michael@0 36352 }
michael@0 36353 }
michael@0 36354 } while (0);
michael@0 36355 if ((i14 & 1) != 0) {
michael@0 36356 return;
michael@0 36357 }
michael@0 36358 i14 = i13 - 1 | 0;
michael@0 36359 HEAP32[i3 >> 2] = i14;
michael@0 36360 i3 = i1 + 4 | 0;
michael@0 36361 i13 = i1 + 4 + (i14 << 4) | 0;
michael@0 36362 HEAP32[i3 >> 2] = HEAP32[i13 >> 2];
michael@0 36363 HEAP32[i3 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 36364 HEAP32[i3 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 36365 HEAP32[i3 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 36366 i13 = i1 + 84 | 0;
michael@0 36367 i3 = i1 + 84 + (i14 << 4) | 0;
michael@0 36368 HEAP32[i13 >> 2] = HEAP32[i3 >> 2];
michael@0 36369 HEAP32[i13 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 36370 HEAP32[i13 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 36371 HEAP32[i13 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 36372 i3 = i1 + 164 | 0;
michael@0 36373 i13 = i1 + 164 + (i14 << 4) | 0;
michael@0 36374 HEAP32[i3 >> 2] = HEAP32[i13 >> 2];
michael@0 36375 HEAP32[i3 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 36376 HEAP32[i3 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 36377 HEAP32[i3 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 36378 return;
michael@0 36379 }
michael@0 36380 function __ZN31btConvexPlaneCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 36381 i1 = i1 | 0;
michael@0 36382 i2 = i2 | 0;
michael@0 36383 i3 = i3 | 0;
michael@0 36384 i4 = i4 | 0;
michael@0 36385 i5 = i5 | 0;
michael@0 36386 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0;
michael@0 36387 i4 = STACKTOP;
michael@0 36388 STACKTOP = STACKTOP + 32 | 0;
michael@0 36389 i6 = i4 | 0;
michael@0 36390 i7 = i4 + 16 | 0;
michael@0 36391 i8 = i1 + 12 | 0;
michael@0 36392 if ((HEAP32[i8 >> 2] | 0) == 0) {
michael@0 36393 STACKTOP = i4;
michael@0 36394 return;
michael@0 36395 }
michael@0 36396 i9 = (HEAP8[i1 + 16 | 0] | 0) != 0;
michael@0 36397 i10 = HEAP32[(i9 ? i3 : i2) + 192 >> 2] | 0;
michael@0 36398 i11 = HEAP32[(i9 ? i2 : i3) + 192 >> 2] | 0;
michael@0 36399 HEAPF32[i6 >> 2] = 0.0;
michael@0 36400 HEAPF32[i6 + 4 >> 2] = 0.0;
michael@0 36401 HEAPF32[i6 + 8 >> 2] = 0.0;
michael@0 36402 HEAPF32[i6 + 12 >> 2] = 1.0;
michael@0 36403 __ZN31btConvexPlaneCollisionAlgorithm20collideSingleContactERK12btQuaternionP17btCollisionObjectS4_RK16btDispatcherInfoP16btManifoldResult(i1, i6, i2, i3, 0, i5);
michael@0 36404 i6 = i5 + 4 | 0;
michael@0 36405 do {
michael@0 36406 if ((HEAP32[(HEAP32[i6 >> 2] | 0) + 1116 >> 2] | 0) < (HEAP32[i1 + 24 >> 2] | 0)) {
michael@0 36407 i9 = i11 + 48 | 0;
michael@0 36408 i12 = i11 + 56 | 0;
michael@0 36409 d13 = +HEAPF32[i12 >> 2];
michael@0 36410 if (+Math_abs(+d13) > .7071067690849304) {
michael@0 36411 d14 = +HEAPF32[i11 + 52 >> 2];
michael@0 36412 d15 = 1.0 / +Math_sqrt(+(d13 * d13 + d14 * d14));
michael@0 36413 d16 = 0.0;
michael@0 36414 d17 = d15 * (-0.0 - d13);
michael@0 36415 d18 = d14 * d15;
michael@0 36416 } else {
michael@0 36417 d15 = +HEAPF32[i9 >> 2];
michael@0 36418 d14 = +HEAPF32[i11 + 52 >> 2];
michael@0 36419 d13 = 1.0 / +Math_sqrt(+(d15 * d15 + d14 * d14));
michael@0 36420 d16 = d13 * (-0.0 - d14);
michael@0 36421 d17 = d15 * d13;
michael@0 36422 d18 = 0.0;
michael@0 36423 }
michael@0 36424 d13 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i10 >> 2] | 0) + 16 >> 2] & 7](i10);
michael@0 36425 d15 = +HEAPF32[4] / d13;
michael@0 36426 d13 = +Math_sqrt(+(d18 * d18 + (d17 * d17 + d16 * d16)));
michael@0 36427 d14 = d15 > .39269909262657166 ? .19634954631328583 : d15 * .5;
michael@0 36428 d15 = +Math_sin(+d14) / d13;
michael@0 36429 d13 = d16 * d15;
michael@0 36430 d19 = d17 * d15;
michael@0 36431 d20 = d18 * d15;
michael@0 36432 d15 = +Math_cos(+d14);
michael@0 36433 i21 = i1 + 20 | 0;
michael@0 36434 i22 = HEAP32[i21 >> 2] | 0;
michael@0 36435 if ((i22 | 0) <= 0) {
michael@0 36436 break;
michael@0 36437 }
michael@0 36438 i23 = i11 + 52 | 0;
michael@0 36439 i24 = i7 | 0;
michael@0 36440 i25 = i7 + 4 | 0;
michael@0 36441 i26 = i7 + 8 | 0;
michael@0 36442 i27 = i7 + 12 | 0;
michael@0 36443 i28 = 0;
michael@0 36444 i29 = i22;
michael@0 36445 do {
michael@0 36446 d14 = +HEAPF32[i9 >> 2];
michael@0 36447 d30 = +HEAPF32[i23 >> 2];
michael@0 36448 d31 = +HEAPF32[i12 >> 2];
michael@0 36449 d32 = +Math_sqrt(+(d14 * d14 + d30 * d30 + d31 * d31));
michael@0 36450 d33 = +(i28 | 0) * (6.2831854820251465 / +(i29 | 0)) * .5;
michael@0 36451 d34 = +Math_sin(+d33) / d32;
michael@0 36452 d32 = d14 * d34;
michael@0 36453 d14 = d30 * d34;
michael@0 36454 d30 = d31 * d34;
michael@0 36455 d34 = +Math_cos(+d33);
michael@0 36456 d33 = -0.0 - d32;
michael@0 36457 d31 = -0.0 - d14;
michael@0 36458 d35 = -0.0 - d30;
michael@0 36459 d36 = d20 * d31 + (d13 * d34 + d15 * d33) - d19 * d35;
michael@0 36460 d37 = d13 * d35 + (d19 * d34 + d15 * d31) - d20 * d33;
michael@0 36461 d38 = d19 * d33 + (d20 * d34 + d15 * d35) - d13 * d31;
michael@0 36462 d39 = d15 * d34 - d13 * d33 - d19 * d31 - d20 * d35;
michael@0 36463 HEAPF32[i24 >> 2] = d30 * d37 + (d32 * d39 + d34 * d36) - d14 * d38;
michael@0 36464 HEAPF32[i25 >> 2] = d32 * d38 + (d34 * d37 + d14 * d39) - d30 * d36;
michael@0 36465 HEAPF32[i26 >> 2] = d14 * d36 + (d30 * d39 + d34 * d38) - d32 * d37;
michael@0 36466 HEAPF32[i27 >> 2] = d34 * d39 - d32 * d36 - d14 * d37 - d30 * d38;
michael@0 36467 __ZN31btConvexPlaneCollisionAlgorithm20collideSingleContactERK12btQuaternionP17btCollisionObjectS4_RK16btDispatcherInfoP16btManifoldResult(i1, i7, i2, i3, 0, i5);
michael@0 36468 i28 = i28 + 1 | 0;
michael@0 36469 i29 = HEAP32[i21 >> 2] | 0;
michael@0 36470 } while ((i28 | 0) < (i29 | 0));
michael@0 36471 }
michael@0 36472 } while (0);
michael@0 36473 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 36474 STACKTOP = i4;
michael@0 36475 return;
michael@0 36476 }
michael@0 36477 if ((HEAP32[(HEAP32[i8 >> 2] | 0) + 1116 >> 2] | 0) == 0) {
michael@0 36478 STACKTOP = i4;
michael@0 36479 return;
michael@0 36480 }
michael@0 36481 i8 = HEAP32[i6 >> 2] | 0;
michael@0 36482 if ((HEAP32[i8 + 1116 >> 2] | 0) == 0) {
michael@0 36483 STACKTOP = i4;
michael@0 36484 return;
michael@0 36485 }
michael@0 36486 if ((HEAP32[i8 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 36487 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i8, i5 + 8 | 0, i5 + 72 | 0);
michael@0 36488 STACKTOP = i4;
michael@0 36489 return;
michael@0 36490 } else {
michael@0 36491 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i8, i5 + 72 | 0, i5 + 8 | 0);
michael@0 36492 STACKTOP = i4;
michael@0 36493 return;
michael@0 36494 }
michael@0 36495 }
michael@0 36496 function __ZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfo(i1, i2) {
michael@0 36497 i1 = i1 | 0;
michael@0 36498 i2 = i2 | 0;
michael@0 36499 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0;
michael@0 36500 i3 = STACKTOP;
michael@0 36501 STACKTOP = STACKTOP + 128 | 0;
michael@0 36502 i4 = i3 | 0;
michael@0 36503 i5 = i3 + 8 | 0;
michael@0 36504 i6 = i3 + 32 | 0;
michael@0 36505 __ZN15CProfileManager13Start_ProfileEPKc(240);
michael@0 36506 i7 = i5 + 16 | 0;
michael@0 36507 HEAP8[i7] = 1;
michael@0 36508 i8 = i5 + 12 | 0;
michael@0 36509 HEAP32[i8 >> 2] = 0;
michael@0 36510 i9 = i5 + 4 | 0;
michael@0 36511 HEAP32[i9 >> 2] = 0;
michael@0 36512 i10 = i5 + 8 | 0;
michael@0 36513 HEAP32[i10 >> 2] = 0;
michael@0 36514 i11 = HEAP32[i1 + 184 >> 2] | 0;
michael@0 36515 L632 : do {
michael@0 36516 if ((i11 | 0) > 0) {
michael@0 36517 i12 = __Z22btAlignedAllocInternalji(i11 << 2, 16) | 0;
michael@0 36518 i13 = HEAP32[i9 >> 2] | 0;
michael@0 36519 if ((i13 | 0) > 0) {
michael@0 36520 i14 = 0;
michael@0 36521 do {
michael@0 36522 i15 = i12 + (i14 << 2) | 0;
michael@0 36523 if ((i15 | 0) != 0) {
michael@0 36524 HEAP32[i15 >> 2] = HEAP32[(HEAP32[i8 >> 2] | 0) + (i14 << 2) >> 2];
michael@0 36525 }
michael@0 36526 i14 = i14 + 1 | 0;
michael@0 36527 } while ((i14 | 0) < (i13 | 0));
michael@0 36528 }
michael@0 36529 i13 = HEAP32[i8 >> 2] | 0;
michael@0 36530 if ((i13 | 0) != 0) {
michael@0 36531 if ((HEAP8[i7] | 0) != 0) {
michael@0 36532 __Z21btAlignedFreeInternalPv(i13);
michael@0 36533 }
michael@0 36534 HEAP32[i8 >> 2] = 0;
michael@0 36535 }
michael@0 36536 HEAP8[i7] = 1;
michael@0 36537 HEAP32[i8 >> 2] = i12;
michael@0 36538 HEAP32[i10 >> 2] = i11;
michael@0 36539 i13 = 0;
michael@0 36540 i14 = i12;
michael@0 36541 while (1) {
michael@0 36542 i15 = i14 + (i13 << 2) | 0;
michael@0 36543 if ((i15 | 0) != 0) {
michael@0 36544 HEAP32[i15 >> 2] = 0;
michael@0 36545 }
michael@0 36546 i15 = i13 + 1 | 0;
michael@0 36547 if ((i15 | 0) >= (i11 | 0)) {
michael@0 36548 break L632;
michael@0 36549 }
michael@0 36550 i13 = i15;
michael@0 36551 i14 = HEAP32[i8 >> 2] | 0;
michael@0 36552 }
michael@0 36553 }
michael@0 36554 } while (0);
michael@0 36555 HEAP32[i9 >> 2] = i11;
michael@0 36556 i14 = i1;
michael@0 36557 i13 = i1 + 192 | 0;
michael@0 36558 i12 = 0;
michael@0 36559 while (1) {
michael@0 36560 if ((i12 | 0) >= (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i14 >> 2] | 0) + 100 >> 2] & 127](i1) | 0)) {
michael@0 36561 break;
michael@0 36562 }
michael@0 36563 HEAP32[(HEAP32[i8 >> 2] | 0) + (i12 << 2) >> 2] = HEAP32[(HEAP32[i13 >> 2] | 0) + (i12 << 2) >> 2];
michael@0 36564 i12 = i12 + 1 | 0;
michael@0 36565 }
michael@0 36566 if ((i11 | 0) > 1) {
michael@0 36567 __ZN20btAlignedObjectArrayIP17btTypedConstraintE17quickSortInternalI33btSortConstraintOnIslandPredicateEEvT_ii(i5, i4, 0, i11 - 1 | 0);
michael@0 36568 }
michael@0 36569 i11 = (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i14 >> 2] | 0) + 100 >> 2] & 127](i1) | 0) == 0;
michael@0 36570 i14 = i11 ? 0 : HEAP32[i8 >> 2] | 0;
michael@0 36571 i11 = i1 + 172 | 0;
michael@0 36572 i4 = HEAP32[i11 >> 2] | 0;
michael@0 36573 i5 = HEAP32[i9 >> 2] | 0;
michael@0 36574 i12 = i1 + 80 | 0;
michael@0 36575 i13 = HEAP32[i12 >> 2] | 0;
michael@0 36576 i15 = i1 + 72 | 0;
michael@0 36577 i16 = HEAP32[i15 >> 2] | 0;
michael@0 36578 i17 = i1 + 24 | 0;
michael@0 36579 i18 = HEAP32[i17 >> 2] | 0;
michael@0 36580 HEAP32[i6 >> 2] = 1520;
michael@0 36581 HEAP32[i6 + 4 >> 2] = i2;
michael@0 36582 HEAP32[i6 + 8 >> 2] = i4;
michael@0 36583 HEAP32[i6 + 12 >> 2] = i14;
michael@0 36584 HEAP32[i6 + 16 >> 2] = i5;
michael@0 36585 HEAP32[i6 + 20 >> 2] = i13;
michael@0 36586 HEAP32[i6 + 24 >> 2] = i16;
michael@0 36587 HEAP32[i6 + 28 >> 2] = i18;
michael@0 36588 HEAP8[i6 + 48 | 0] = 1;
michael@0 36589 HEAP32[i6 + 44 >> 2] = 0;
michael@0 36590 HEAP32[i6 + 36 >> 2] = 0;
michael@0 36591 HEAP32[i6 + 40 >> 2] = 0;
michael@0 36592 HEAP8[i6 + 68 | 0] = 1;
michael@0 36593 HEAP32[i6 + 64 >> 2] = 0;
michael@0 36594 HEAP32[i6 + 56 >> 2] = 0;
michael@0 36595 HEAP32[i6 + 60 >> 2] = 0;
michael@0 36596 HEAP8[i6 + 88 | 0] = 1;
michael@0 36597 HEAP32[i6 + 84 >> 2] = 0;
michael@0 36598 HEAP32[i6 + 76 >> 2] = 0;
michael@0 36599 HEAP32[i6 + 80 >> 2] = 0;
michael@0 36600 i16 = HEAP32[(HEAP32[i4 >> 2] | 0) + 8 >> 2] | 0;
michael@0 36601 i13 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 36602 i5 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i18 >> 2] | 0) + 36 >> 2] & 127](i18) | 0;
michael@0 36603 FUNCTION_TABLE_viii[i16 & 127](i4, i13, i5);
michael@0 36604 __ZN25btSimulationIslandManager22buildAndProcessIslandsEP12btDispatcherP16btCollisionWorldPNS_14IslandCallbackE(HEAP32[i1 + 176 >> 2] | 0, HEAP32[i17 >> 2] | 0, i1 | 0, i6 | 0);
michael@0 36605 __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallback18processConstraintsEv(i6);
michael@0 36606 i1 = HEAP32[i11 >> 2] | 0;
michael@0 36607 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 16 >> 2] & 127](i1, i2, HEAP32[i12 >> 2] | 0, HEAP32[i15 >> 2] | 0);
michael@0 36608 __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallbackD2Ev(i6);
michael@0 36609 i6 = HEAP32[i8 >> 2] | 0;
michael@0 36610 if ((i6 | 0) == 0) {
michael@0 36611 HEAP8[i7] = 1;
michael@0 36612 HEAP32[i8 >> 2] = 0;
michael@0 36613 HEAP32[i9 >> 2] = 0;
michael@0 36614 HEAP32[i10 >> 2] = 0;
michael@0 36615 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 36616 STACKTOP = i3;
michael@0 36617 return;
michael@0 36618 }
michael@0 36619 if ((HEAP8[i7] | 0) != 0) {
michael@0 36620 __Z21btAlignedFreeInternalPv(i6);
michael@0 36621 }
michael@0 36622 HEAP32[i8 >> 2] = 0;
michael@0 36623 HEAP8[i7] = 1;
michael@0 36624 HEAP32[i8 >> 2] = 0;
michael@0 36625 HEAP32[i9 >> 2] = 0;
michael@0 36626 HEAP32[i10 >> 2] = 0;
michael@0 36627 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 36628 STACKTOP = i3;
michael@0 36629 return;
michael@0 36630 }
michael@0 36631 function __Z22resolveSingleCollisionP11btRigidBodyP17btCollisionObjectRK9btVector3S5_RK19btContactSolverInfof(i1, i2, i3, i4, i5, d6) {
michael@0 36632 i1 = i1 | 0;
michael@0 36633 i2 = i2 | 0;
michael@0 36634 i3 = i3 | 0;
michael@0 36635 i4 = i4 | 0;
michael@0 36636 i5 = i5 | 0;
michael@0 36637 d6 = +d6;
michael@0 36638 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, i31 = 0, i32 = 0, i33 = 0, d34 = 0.0, d35 = 0.0, i36 = 0;
michael@0 36639 i7 = STACKTOP;
michael@0 36640 STACKTOP = STACKTOP + 64 | 0;
michael@0 36641 i8 = i7 | 0;
michael@0 36642 i9 = i7 + 16 | 0;
michael@0 36643 i10 = i7 + 32 | 0;
michael@0 36644 i11 = i7 + 48 | 0;
michael@0 36645 if ((HEAP32[i2 + 232 >> 2] & 2 | 0) == 0) {
michael@0 36646 i12 = 0;
michael@0 36647 } else {
michael@0 36648 i12 = i2;
michael@0 36649 }
michael@0 36650 d13 = +HEAPF32[i3 >> 2];
michael@0 36651 d14 = d13 - +HEAPF32[i1 + 52 >> 2];
michael@0 36652 d15 = +HEAPF32[i3 + 4 >> 2];
michael@0 36653 d16 = d15 - +HEAPF32[i1 + 56 >> 2];
michael@0 36654 d17 = +HEAPF32[i3 + 8 >> 2];
michael@0 36655 d18 = d17 - +HEAPF32[i1 + 60 >> 2];
michael@0 36656 HEAPF32[i8 >> 2] = d14;
michael@0 36657 HEAPF32[i8 + 4 >> 2] = d16;
michael@0 36658 HEAPF32[i8 + 8 >> 2] = d18;
michael@0 36659 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 36660 d19 = d13 - +HEAPF32[i2 + 52 >> 2];
michael@0 36661 d20 = d15 - +HEAPF32[i2 + 56 >> 2];
michael@0 36662 d21 = d17 - +HEAPF32[i2 + 60 >> 2];
michael@0 36663 HEAPF32[i9 >> 2] = d19;
michael@0 36664 HEAPF32[i9 + 4 >> 2] = d20;
michael@0 36665 HEAPF32[i9 + 8 >> 2] = d21;
michael@0 36666 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 36667 d22 = +HEAPF32[i1 + 324 >> 2];
michael@0 36668 d23 = +HEAPF32[i1 + 328 >> 2];
michael@0 36669 d24 = +HEAPF32[i1 + 320 >> 2];
michael@0 36670 i3 = (i12 | 0) != 0;
michael@0 36671 if (i3) {
michael@0 36672 d25 = +HEAPF32[i12 + 324 >> 2];
michael@0 36673 d26 = +HEAPF32[i12 + 328 >> 2];
michael@0 36674 d27 = +HEAPF32[i12 + 320 >> 2];
michael@0 36675 d28 = d21 * d25 - d20 * d26 + +HEAPF32[i12 + 304 >> 2];
michael@0 36676 d29 = +HEAPF32[i12 + 308 >> 2] + (d19 * d26 - d21 * d27);
michael@0 36677 d30 = d20 * d27 - d19 * d25 + +HEAPF32[i12 + 312 >> 2];
michael@0 36678 } else {
michael@0 36679 d28 = 0.0;
michael@0 36680 d29 = 0.0;
michael@0 36681 d30 = 0.0;
michael@0 36682 }
michael@0 36683 i31 = i4 | 0;
michael@0 36684 d25 = +HEAPF32[i31 >> 2];
michael@0 36685 i32 = i4 + 4 | 0;
michael@0 36686 d19 = +HEAPF32[i32 >> 2];
michael@0 36687 i33 = i4 + 8 | 0;
michael@0 36688 d27 = +HEAPF32[i33 >> 2];
michael@0 36689 d20 = d25 * (d18 * d22 - d16 * d23 + +HEAPF32[i1 + 304 >> 2] - d28) + (+HEAPF32[i1 + 308 >> 2] + (d14 * d23 - d18 * d24) - d29) * d19 + (d16 * d24 - d14 * d22 + +HEAPF32[i1 + 312 >> 2] - d30) * d27;
michael@0 36690 d30 = d16 * d27 - d18 * d19;
michael@0 36691 d22 = d18 * d25 - d14 * d27;
michael@0 36692 d24 = d14 * d19 - d16 * d25;
michael@0 36693 d29 = d24 * +HEAPF32[i1 + 288 >> 2] + (d30 * +HEAPF32[i1 + 256 >> 2] + d22 * +HEAPF32[i1 + 272 >> 2]);
michael@0 36694 d23 = d30 * +HEAPF32[i1 + 260 >> 2] + d22 * +HEAPF32[i1 + 276 >> 2] + d24 * +HEAPF32[i1 + 292 >> 2];
michael@0 36695 d28 = d30 * +HEAPF32[i1 + 264 >> 2] + d22 * +HEAPF32[i1 + 280 >> 2] + d24 * +HEAPF32[i1 + 296 >> 2];
michael@0 36696 if (i3) {
michael@0 36697 d24 = d13 - +HEAPF32[i12 + 52 >> 2];
michael@0 36698 d13 = d15 - +HEAPF32[i12 + 56 >> 2];
michael@0 36699 d15 = d17 - +HEAPF32[i12 + 60 >> 2];
michael@0 36700 d17 = d27 * d13 - d19 * d15;
michael@0 36701 d22 = d25 * d15 - d27 * d24;
michael@0 36702 d30 = d19 * d24 - d25 * d13;
michael@0 36703 d21 = d30 * +HEAPF32[i12 + 288 >> 2] + (+HEAPF32[i12 + 256 >> 2] * d17 + +HEAPF32[i12 + 272 >> 2] * d22);
michael@0 36704 d26 = d17 * +HEAPF32[i12 + 260 >> 2] + d22 * +HEAPF32[i12 + 276 >> 2] + d30 * +HEAPF32[i12 + 292 >> 2];
michael@0 36705 d34 = d17 * +HEAPF32[i12 + 264 >> 2] + d22 * +HEAPF32[i12 + 280 >> 2] + d30 * +HEAPF32[i12 + 296 >> 2];
michael@0 36706 d35 = +HEAPF32[i12 + 336 >> 2] + (d27 * (d13 * d21 - d24 * d26) + (d25 * (d15 * d26 - d13 * d34) + d19 * (d24 * d34 - d15 * d21)));
michael@0 36707 i36 = 1;
michael@0 36708 } else {
michael@0 36709 d35 = 0.0;
michael@0 36710 i36 = 0;
michael@0 36711 }
michael@0 36712 d21 = 1.0 / (+HEAPF32[i1 + 336 >> 2] + (d27 * (d16 * d29 - d14 * d23) + (d25 * (d18 * d23 - d16 * d28) + d19 * (d14 * d28 - d18 * d29))) + d35);
michael@0 36713 d35 = +HEAPF32[i5 + 32 >> 2] * (-0.0 - d6) / +HEAPF32[i5 + 12 >> 2] * d21 + d20 * (-0.0 - (+HEAPF32[i1 + 228 >> 2] * +HEAPF32[i2 + 228 >> 2] * (-0.0 - d20) + 1.0)) * d21;
michael@0 36714 d21 = d35 < 0.0 ? 0.0 : d35;
michael@0 36715 HEAPF32[i10 >> 2] = d25 * d21;
michael@0 36716 HEAPF32[i10 + 4 >> 2] = d19 * d21;
michael@0 36717 HEAPF32[i10 + 8 >> 2] = d27 * d21;
michael@0 36718 HEAPF32[i10 + 12 >> 2] = 0.0;
michael@0 36719 __ZN11btRigidBody12applyImpulseERK9btVector3S2_(i1, i10, i8);
michael@0 36720 if (!i36) {
michael@0 36721 STACKTOP = i7;
michael@0 36722 return +d21;
michael@0 36723 }
michael@0 36724 d27 = d21 * (-0.0 - +HEAPF32[i32 >> 2]);
michael@0 36725 d19 = d21 * (-0.0 - +HEAPF32[i33 >> 2]);
michael@0 36726 HEAPF32[i11 >> 2] = d21 * (-0.0 - +HEAPF32[i31 >> 2]);
michael@0 36727 HEAPF32[i11 + 4 >> 2] = d27;
michael@0 36728 HEAPF32[i11 + 8 >> 2] = d19;
michael@0 36729 HEAPF32[i11 + 12 >> 2] = 0.0;
michael@0 36730 __ZN11btRigidBody12applyImpulseERK9btVector3S2_(i12, i11, i9);
michael@0 36731 STACKTOP = i7;
michael@0 36732 return +d21;
michael@0 36733 }
michael@0 36734 function __ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_S3_PfRj(i1, i2, i3, i4, i5) {
michael@0 36735 i1 = i1 | 0;
michael@0 36736 i2 = i2 | 0;
michael@0 36737 i3 = i3 | 0;
michael@0 36738 i4 = i4 | 0;
michael@0 36739 i5 = i5 | 0;
michael@0 36740 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, i13 = 0, d14 = 0.0, d15 = 0.0, i16 = 0, d17 = 0.0, i18 = 0, d19 = 0.0, d20 = 0.0, i21 = 0, d22 = 0.0, i23 = 0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, i28 = 0, d29 = 0.0, i30 = 0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, i36 = 0, d37 = 0.0, i38 = 0, d39 = 0.0, d40 = 0.0, i41 = 0;
michael@0 36741 i6 = STACKTOP;
michael@0 36742 STACKTOP = STACKTOP + 80 | 0;
michael@0 36743 i7 = i6 | 0;
michael@0 36744 i8 = i6 + 16 | 0;
michael@0 36745 i9 = i6 + 64 | 0;
michael@0 36746 i10 = i6 + 72 | 0;
michael@0 36747 HEAP32[i7 >> 2] = i1;
michael@0 36748 HEAP32[i7 + 4 >> 2] = i2;
michael@0 36749 HEAP32[i7 + 8 >> 2] = i3;
michael@0 36750 i11 = i1 | 0;
michael@0 36751 d12 = +HEAPF32[i11 >> 2];
michael@0 36752 i13 = i2 | 0;
michael@0 36753 d14 = +HEAPF32[i13 >> 2];
michael@0 36754 d15 = d12 - d14;
michael@0 36755 i16 = i1 + 4 | 0;
michael@0 36756 d17 = +HEAPF32[i16 >> 2];
michael@0 36757 i18 = i2 + 4 | 0;
michael@0 36758 d19 = +HEAPF32[i18 >> 2];
michael@0 36759 d20 = d17 - d19;
michael@0 36760 i21 = i1 + 8 | 0;
michael@0 36761 d22 = +HEAPF32[i21 >> 2];
michael@0 36762 i23 = i2 + 8 | 0;
michael@0 36763 d24 = +HEAPF32[i23 >> 2];
michael@0 36764 d25 = d22 - d24;
michael@0 36765 HEAPF32[i8 >> 2] = d15;
michael@0 36766 HEAPF32[i8 + 4 >> 2] = d20;
michael@0 36767 HEAPF32[i8 + 8 >> 2] = d25;
michael@0 36768 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 36769 i2 = i3 | 0;
michael@0 36770 d26 = +HEAPF32[i2 >> 2];
michael@0 36771 d27 = d14 - d26;
michael@0 36772 i28 = i3 + 4 | 0;
michael@0 36773 d14 = +HEAPF32[i28 >> 2];
michael@0 36774 d29 = d19 - d14;
michael@0 36775 i30 = i3 + 8 | 0;
michael@0 36776 d19 = +HEAPF32[i30 >> 2];
michael@0 36777 d31 = d24 - d19;
michael@0 36778 HEAPF32[i8 + 16 >> 2] = d27;
michael@0 36779 HEAPF32[i8 + 20 >> 2] = d29;
michael@0 36780 HEAPF32[i8 + 24 >> 2] = d31;
michael@0 36781 HEAPF32[i8 + 28 >> 2] = 0.0;
michael@0 36782 d24 = d26 - d12;
michael@0 36783 d26 = d14 - d17;
michael@0 36784 d14 = d19 - d22;
michael@0 36785 HEAPF32[i8 + 32 >> 2] = d24;
michael@0 36786 HEAPF32[i8 + 36 >> 2] = d26;
michael@0 36787 HEAPF32[i8 + 40 >> 2] = d14;
michael@0 36788 HEAPF32[i8 + 44 >> 2] = 0.0;
michael@0 36789 d19 = d20 * d31 - d25 * d29;
michael@0 36790 d32 = d25 * d27 - d15 * d31;
michael@0 36791 d33 = d15 * d29 - d20 * d27;
michael@0 36792 d34 = d33 * d33 + (d19 * d19 + d32 * d32);
michael@0 36793 if (d34 <= 0.0) {
michael@0 36794 d35 = -1.0;
michael@0 36795 STACKTOP = i6;
michael@0 36796 return +d35;
michael@0 36797 }
michael@0 36798 HEAP32[i9 >> 2] = 0;
michael@0 36799 HEAP32[i9 + 4 >> 2] = 0;
michael@0 36800 HEAP32[i10 >> 2] = 0;
michael@0 36801 i3 = i9;
michael@0 36802 i36 = i9 + 4 | 0;
michael@0 36803 i9 = 0;
michael@0 36804 d37 = -1.0;
michael@0 36805 i38 = i1;
michael@0 36806 d39 = d20;
michael@0 36807 d20 = d25;
michael@0 36808 d25 = d15;
michael@0 36809 d15 = d12;
michael@0 36810 d12 = d17;
michael@0 36811 d17 = d22;
michael@0 36812 while (1) {
michael@0 36813 do {
michael@0 36814 if (d17 * (d32 * d25 - d19 * d39) + (d12 * (d19 * d20 - d33 * d25) + d15 * (d33 * d39 - d32 * d20)) > 0.0) {
michael@0 36815 i1 = HEAP32[1328 + (i9 << 2) >> 2] | 0;
michael@0 36816 d22 = +__ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_PfRj(i38, HEAP32[i7 + (i1 << 2) >> 2] | 0, i3, i10);
michael@0 36817 if (!(d37 < 0.0 | d22 < d37)) {
michael@0 36818 d40 = d37;
michael@0 36819 break;
michael@0 36820 }
michael@0 36821 i41 = HEAP32[i10 >> 2] | 0;
michael@0 36822 HEAP32[i5 >> 2] = ((i41 & 1 | 0) == 0 ? 0 : 1 << i9) + ((i41 & 2 | 0) == 0 ? 0 : 1 << i1);
michael@0 36823 HEAPF32[i4 + (i9 << 2) >> 2] = +HEAPF32[i3 >> 2];
michael@0 36824 HEAPF32[i4 + (i1 << 2) >> 2] = +HEAPF32[i36 >> 2];
michael@0 36825 HEAPF32[i4 + (HEAP32[1328 + (i1 << 2) >> 2] << 2) >> 2] = 0.0;
michael@0 36826 d40 = d22;
michael@0 36827 } else {
michael@0 36828 d40 = d37;
michael@0 36829 }
michael@0 36830 } while (0);
michael@0 36831 i1 = i9 + 1 | 0;
michael@0 36832 if (i1 >>> 0 >= 3) {
michael@0 36833 break;
michael@0 36834 }
michael@0 36835 i41 = HEAP32[i7 + (i1 << 2) >> 2] | 0;
michael@0 36836 i9 = i1;
michael@0 36837 d37 = d40;
michael@0 36838 i38 = i41;
michael@0 36839 d39 = +HEAPF32[i8 + (i1 << 4) + 4 >> 2];
michael@0 36840 d20 = +HEAPF32[i8 + (i1 << 4) + 8 >> 2];
michael@0 36841 d25 = +HEAPF32[i8 + (i1 << 4) >> 2];
michael@0 36842 d15 = +HEAPF32[i41 >> 2];
michael@0 36843 d12 = +HEAPF32[i41 + 4 >> 2];
michael@0 36844 d17 = +HEAPF32[i41 + 8 >> 2];
michael@0 36845 }
michael@0 36846 if (d40 >= 0.0) {
michael@0 36847 d35 = d40;
michael@0 36848 STACKTOP = i6;
michael@0 36849 return +d35;
michael@0 36850 }
michael@0 36851 d40 = d19 * +HEAPF32[i11 >> 2] + d32 * +HEAPF32[i16 >> 2] + d33 * +HEAPF32[i21 >> 2];
michael@0 36852 d17 = +Math_sqrt(+d34);
michael@0 36853 d12 = d40 / d34;
michael@0 36854 d34 = d19 * d12;
michael@0 36855 d19 = d32 * d12;
michael@0 36856 d32 = d33 * d12;
michael@0 36857 HEAP32[i5 >> 2] = 7;
michael@0 36858 d12 = +HEAPF32[i13 >> 2] - d34;
michael@0 36859 d33 = +HEAPF32[i18 >> 2] - d19;
michael@0 36860 d40 = +HEAPF32[i23 >> 2] - d32;
michael@0 36861 d15 = d29 * d40 - d31 * d33;
michael@0 36862 d25 = d31 * d12 - d27 * d40;
michael@0 36863 d40 = d27 * d33 - d29 * d12;
michael@0 36864 d12 = +Math_sqrt(+(d40 * d40 + (d15 * d15 + d25 * d25))) / d17;
michael@0 36865 HEAPF32[i4 >> 2] = d12;
michael@0 36866 d25 = +HEAPF32[i2 >> 2] - d34;
michael@0 36867 d15 = +HEAPF32[i28 >> 2] - d19;
michael@0 36868 d40 = +HEAPF32[i30 >> 2] - d32;
michael@0 36869 d29 = d26 * d40 - d14 * d15;
michael@0 36870 d33 = d14 * d25 - d24 * d40;
michael@0 36871 d40 = d24 * d15 - d26 * d25;
michael@0 36872 d25 = +Math_sqrt(+(d40 * d40 + (d29 * d29 + d33 * d33))) / d17;
michael@0 36873 HEAPF32[i4 + 4 >> 2] = d25;
michael@0 36874 HEAPF32[i4 + 8 >> 2] = 1.0 - (d12 + d25);
michael@0 36875 d35 = d32 * d32 + (d34 * d34 + d19 * d19);
michael@0 36876 STACKTOP = i6;
michael@0 36877 return +d35;
michael@0 36878 }
michael@0 36879 function __ZN28btCompoundCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 36880 i1 = i1 | 0;
michael@0 36881 i2 = i2 | 0;
michael@0 36882 i3 = i3 | 0;
michael@0 36883 i4 = i4 | 0;
michael@0 36884 i5 = i5 | 0;
michael@0 36885 var i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0, d42 = 0.0, d43 = 0.0, d44 = 0.0, i45 = 0, i46 = 0, d47 = 0.0, d48 = 0.0, d49 = 0.0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0, d55 = 0.0, d56 = 0.0, d57 = 0.0, d58 = 0.0;
michael@0 36886 i6 = (HEAP8[i1 + 28 | 0] | 0) != 0;
michael@0 36887 i7 = i6 ? i3 : i2;
michael@0 36888 i8 = i6 ? i2 : i3;
michael@0 36889 i3 = i7 + 192 | 0;
michael@0 36890 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 36891 if ((i2 | 0) <= 0) {
michael@0 36892 d9 = 1.0;
michael@0 36893 return +d9;
michael@0 36894 }
michael@0 36895 i6 = HEAP32[i3 >> 2] | 0;
michael@0 36896 i10 = i6 + 24 | 0;
michael@0 36897 i11 = i7 + 4 | 0;
michael@0 36898 i12 = i7 + 8 | 0;
michael@0 36899 i13 = i7 + 12 | 0;
michael@0 36900 i14 = i7 + 16 | 0;
michael@0 36901 i15 = i7 + 20 | 0;
michael@0 36902 i16 = i7 + 24 | 0;
michael@0 36903 i17 = i7 + 28 | 0;
michael@0 36904 i18 = i7 + 32 | 0;
michael@0 36905 i19 = i7 + 36 | 0;
michael@0 36906 i20 = i7 + 40 | 0;
michael@0 36907 i21 = i7 + 44 | 0;
michael@0 36908 i22 = i7 + 48 | 0;
michael@0 36909 i23 = i7 + 52 | 0;
michael@0 36910 i24 = i7 + 56 | 0;
michael@0 36911 i25 = i7 + 60 | 0;
michael@0 36912 i26 = i7 + 64 | 0;
michael@0 36913 i27 = i1 + 20 | 0;
michael@0 36914 d28 = +HEAPF32[i11 >> 2];
michael@0 36915 d29 = +HEAPF32[i12 >> 2];
michael@0 36916 d30 = +HEAPF32[i13 >> 2];
michael@0 36917 d31 = +HEAPF32[i14 >> 2];
michael@0 36918 d32 = +HEAPF32[i15 >> 2];
michael@0 36919 d33 = +HEAPF32[i16 >> 2];
michael@0 36920 d34 = +HEAPF32[i17 >> 2];
michael@0 36921 d35 = +HEAPF32[i18 >> 2];
michael@0 36922 d36 = +HEAPF32[i19 >> 2];
michael@0 36923 d37 = +HEAPF32[i20 >> 2];
michael@0 36924 d38 = +HEAPF32[i21 >> 2];
michael@0 36925 d39 = +HEAPF32[i22 >> 2];
michael@0 36926 d40 = +HEAPF32[i23 >> 2];
michael@0 36927 d41 = +HEAPF32[i24 >> 2];
michael@0 36928 d42 = +HEAPF32[i25 >> 2];
michael@0 36929 d43 = +HEAPF32[i26 >> 2];
michael@0 36930 i1 = 0;
michael@0 36931 d44 = 1.0;
michael@0 36932 while (1) {
michael@0 36933 i45 = HEAP32[i10 >> 2] | 0;
michael@0 36934 i46 = HEAP32[i45 + (i1 * 80 | 0) + 64 >> 2] | 0;
michael@0 36935 d47 = +HEAPF32[i45 + (i1 * 80 | 0) >> 2];
michael@0 36936 d48 = +HEAPF32[i45 + (i1 * 80 | 0) + 16 >> 2];
michael@0 36937 d49 = +HEAPF32[i45 + (i1 * 80 | 0) + 32 >> 2];
michael@0 36938 d50 = +HEAPF32[i45 + (i1 * 80 | 0) + 4 >> 2];
michael@0 36939 d51 = +HEAPF32[i45 + (i1 * 80 | 0) + 20 >> 2];
michael@0 36940 d52 = +HEAPF32[i45 + (i1 * 80 | 0) + 36 >> 2];
michael@0 36941 d53 = +HEAPF32[i45 + (i1 * 80 | 0) + 8 >> 2];
michael@0 36942 d54 = +HEAPF32[i45 + (i1 * 80 | 0) + 24 >> 2];
michael@0 36943 d55 = +HEAPF32[i45 + (i1 * 80 | 0) + 40 >> 2];
michael@0 36944 d56 = +HEAPF32[i45 + (i1 * 80 | 0) + 48 >> 2];
michael@0 36945 d57 = +HEAPF32[i45 + (i1 * 80 | 0) + 52 >> 2];
michael@0 36946 d58 = +HEAPF32[i45 + (i1 * 80 | 0) + 56 >> 2];
michael@0 36947 HEAPF32[i11 >> 2] = d28 * d47 + d29 * d48 + d30 * d49;
michael@0 36948 HEAPF32[i12 >> 2] = d28 * d50 + d29 * d51 + d30 * d52;
michael@0 36949 HEAPF32[i13 >> 2] = d28 * d53 + d29 * d54 + d30 * d55;
michael@0 36950 HEAPF32[i14 >> 2] = 0.0;
michael@0 36951 HEAPF32[i15 >> 2] = d32 * d47 + d33 * d48 + d34 * d49;
michael@0 36952 HEAPF32[i16 >> 2] = d32 * d50 + d33 * d51 + d34 * d52;
michael@0 36953 HEAPF32[i17 >> 2] = d32 * d53 + d33 * d54 + d34 * d55;
michael@0 36954 HEAPF32[i18 >> 2] = 0.0;
michael@0 36955 HEAPF32[i19 >> 2] = d36 * d47 + d37 * d48 + d38 * d49;
michael@0 36956 HEAPF32[i20 >> 2] = d36 * d50 + d37 * d51 + d38 * d52;
michael@0 36957 HEAPF32[i21 >> 2] = d36 * d53 + d37 * d54 + d38 * d55;
michael@0 36958 HEAPF32[i22 >> 2] = 0.0;
michael@0 36959 HEAPF32[i23 >> 2] = d40 + (d28 * d56 + d29 * d57 + d30 * d58);
michael@0 36960 HEAPF32[i24 >> 2] = d41 + (d32 * d56 + d33 * d57 + d34 * d58);
michael@0 36961 HEAPF32[i25 >> 2] = d42 + (d36 * d56 + d37 * d57 + d38 * d58);
michael@0 36962 HEAPF32[i26 >> 2] = 0.0;
michael@0 36963 HEAP32[i3 >> 2] = i46;
michael@0 36964 i46 = HEAP32[(HEAP32[i27 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 36965 d58 = +FUNCTION_TABLE_fiiiii[HEAP32[(HEAP32[i46 >> 2] | 0) + 12 >> 2] & 31](i46, i7, i8, i4, i5);
michael@0 36966 d57 = d58 < d44 ? d58 : d44;
michael@0 36967 HEAP32[i3 >> 2] = i6;
michael@0 36968 HEAPF32[i11 >> 2] = d28;
michael@0 36969 HEAPF32[i12 >> 2] = d29;
michael@0 36970 HEAPF32[i13 >> 2] = d30;
michael@0 36971 HEAPF32[i14 >> 2] = d31;
michael@0 36972 HEAPF32[i15 >> 2] = d32;
michael@0 36973 HEAPF32[i16 >> 2] = d33;
michael@0 36974 HEAPF32[i17 >> 2] = d34;
michael@0 36975 HEAPF32[i18 >> 2] = d35;
michael@0 36976 HEAPF32[i19 >> 2] = d36;
michael@0 36977 HEAPF32[i20 >> 2] = d37;
michael@0 36978 HEAPF32[i21 >> 2] = d38;
michael@0 36979 HEAPF32[i22 >> 2] = d39;
michael@0 36980 HEAPF32[i23 >> 2] = d40;
michael@0 36981 HEAPF32[i24 >> 2] = d41;
michael@0 36982 HEAPF32[i25 >> 2] = d42;
michael@0 36983 HEAPF32[i26 >> 2] = d43;
michael@0 36984 i46 = i1 + 1 | 0;
michael@0 36985 if ((i46 | 0) < (i2 | 0)) {
michael@0 36986 i1 = i46;
michael@0 36987 d44 = d57;
michael@0 36988 } else {
michael@0 36989 d9 = d57;
michael@0 36990 break;
michael@0 36991 }
michael@0 36992 }
michael@0 36993 return +d9;
michael@0 36994 }
michael@0 36995 function __ZN12gjkepa2_impl3EPA7newfaceEPNS_3GJK3sSVES3_S3_b(i1, i2, i3, i4, i5) {
michael@0 36996 i1 = i1 | 0;
michael@0 36997 i2 = i2 | 0;
michael@0 36998 i3 = i3 | 0;
michael@0 36999 i4 = i4 | 0;
michael@0 37000 i5 = i5 | 0;
michael@0 37001 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, d16 = 0.0, d17 = 0.0, i18 = 0, i19 = 0, d20 = 0.0, d21 = 0.0, i22 = 0, d23 = 0.0, d24 = 0.0, d25 = 0.0, i26 = 0, i27 = 0, d28 = 0.0, i29 = 0, i30 = 0, i31 = 0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0, d39 = 0.0, d40 = 0.0, d41 = 0.0;
michael@0 37002 i6 = i1 + 9800 | 0;
michael@0 37003 i7 = HEAP32[i6 >> 2] | 0;
michael@0 37004 if ((i7 | 0) == 0) {
michael@0 37005 HEAP32[i1 >> 2] = 5;
michael@0 37006 i8 = 0;
michael@0 37007 return i8 | 0;
michael@0 37008 }
michael@0 37009 i9 = i7 + 52 | 0;
michael@0 37010 i10 = HEAP32[i9 >> 2] | 0;
michael@0 37011 i11 = i7 + 48 | 0;
michael@0 37012 if ((i10 | 0) != 0) {
michael@0 37013 HEAP32[i10 + 48 >> 2] = HEAP32[i11 >> 2];
michael@0 37014 }
michael@0 37015 i10 = HEAP32[i11 >> 2] | 0;
michael@0 37016 if ((i10 | 0) != 0) {
michael@0 37017 HEAP32[i10 + 52 >> 2] = HEAP32[i9 >> 2];
michael@0 37018 }
michael@0 37019 if ((HEAP32[i6 >> 2] | 0) == (i7 | 0)) {
michael@0 37020 HEAP32[i6 >> 2] = HEAP32[i9 >> 2];
michael@0 37021 }
michael@0 37022 i10 = i1 + 9804 | 0;
michael@0 37023 HEAP32[i10 >> 2] = (HEAP32[i10 >> 2] | 0) - 1;
michael@0 37024 HEAP32[i11 >> 2] = 0;
michael@0 37025 i12 = i1 + 9792 | 0;
michael@0 37026 HEAP32[i9 >> 2] = HEAP32[i12 >> 2];
michael@0 37027 i13 = HEAP32[i12 >> 2] | 0;
michael@0 37028 if ((i13 | 0) != 0) {
michael@0 37029 HEAP32[i13 + 48 >> 2] = i7;
michael@0 37030 }
michael@0 37031 HEAP32[i12 >> 2] = i7;
michael@0 37032 i13 = i1 + 9796 | 0;
michael@0 37033 HEAP32[i13 >> 2] = (HEAP32[i13 >> 2] | 0) + 1;
michael@0 37034 HEAP8[i7 + 59 | 0] = 0;
michael@0 37035 HEAP32[i7 + 24 >> 2] = i2;
michael@0 37036 HEAP32[i7 + 28 >> 2] = i3;
michael@0 37037 HEAP32[i7 + 32 >> 2] = i4;
michael@0 37038 i14 = i3 + 16 | 0;
michael@0 37039 i15 = i2 + 16 | 0;
michael@0 37040 d16 = +HEAPF32[i15 >> 2];
michael@0 37041 d17 = +HEAPF32[i14 >> 2] - d16;
michael@0 37042 i18 = i3 + 20 | 0;
michael@0 37043 i19 = i2 + 20 | 0;
michael@0 37044 d20 = +HEAPF32[i19 >> 2];
michael@0 37045 d21 = +HEAPF32[i18 >> 2] - d20;
michael@0 37046 i22 = i3 + 24 | 0;
michael@0 37047 i3 = i2 + 24 | 0;
michael@0 37048 d23 = +HEAPF32[i3 >> 2];
michael@0 37049 d24 = +HEAPF32[i22 >> 2] - d23;
michael@0 37050 i2 = i4 + 16 | 0;
michael@0 37051 d25 = +HEAPF32[i2 >> 2] - d16;
michael@0 37052 i26 = i4 + 20 | 0;
michael@0 37053 d16 = +HEAPF32[i26 >> 2] - d20;
michael@0 37054 i27 = i4 + 24 | 0;
michael@0 37055 d20 = +HEAPF32[i27 >> 2] - d23;
michael@0 37056 d23 = d21 * d20 - d24 * d16;
michael@0 37057 d28 = d24 * d25 - d17 * d20;
michael@0 37058 d20 = d17 * d16 - d21 * d25;
michael@0 37059 i4 = i7 | 0;
michael@0 37060 HEAPF32[i4 >> 2] = d23;
michael@0 37061 i29 = i7 + 4 | 0;
michael@0 37062 HEAPF32[i29 >> 2] = d28;
michael@0 37063 i30 = i7 + 8 | 0;
michael@0 37064 HEAPF32[i30 >> 2] = d20;
michael@0 37065 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 37066 d25 = +Math_sqrt(+(d20 * d20 + (d23 * d23 + d28 * d28)));
michael@0 37067 i31 = d25 > 9999999747378752.0e-20;
michael@0 37068 d21 = +HEAPF32[i15 >> 2];
michael@0 37069 d16 = +HEAPF32[i14 >> 2];
michael@0 37070 d17 = d21 - d16;
michael@0 37071 d24 = +HEAPF32[i19 >> 2];
michael@0 37072 d32 = +HEAPF32[i18 >> 2];
michael@0 37073 d33 = d24 - d32;
michael@0 37074 d34 = +HEAPF32[i3 >> 2];
michael@0 37075 d35 = +HEAPF32[i22 >> 2];
michael@0 37076 d36 = d34 - d35;
michael@0 37077 d37 = d34 * (d23 * d33 - d28 * d17) + (d21 * (d28 * d36 - d20 * d33) + d24 * (d20 * d17 - d23 * d36));
michael@0 37078 d36 = +HEAPF32[i2 >> 2];
michael@0 37079 d17 = d16 - d36;
michael@0 37080 d33 = +HEAPF32[i26 >> 2];
michael@0 37081 d38 = d32 - d33;
michael@0 37082 d39 = +HEAPF32[i27 >> 2];
michael@0 37083 d40 = d35 - d39;
michael@0 37084 d41 = d35 * (d23 * d38 - d28 * d17) + (d16 * (d28 * d40 - d20 * d38) + d32 * (d20 * d17 - d23 * d40));
michael@0 37085 d40 = d36 - d21;
michael@0 37086 d21 = d33 - d24;
michael@0 37087 d24 = d39 - d34;
michael@0 37088 d34 = d39 * (d23 * d21 - d28 * d40) + (d36 * (d28 * d24 - d20 * d21) + d33 * (d20 * d40 - d23 * d24));
michael@0 37089 d24 = d37 < d41 ? d37 : d41;
michael@0 37090 d41 = (d24 < d34 ? d24 : d34) / (i31 ? d25 : 1.0);
michael@0 37091 HEAPF32[i7 + 20 >> 2] = d41 < -.009999999776482582 ? d41 : 0.0;
michael@0 37092 do {
michael@0 37093 if (i31) {
michael@0 37094 d41 = (d23 * +HEAPF32[i15 >> 2] + d28 * +HEAPF32[i19 >> 2] + d20 * +HEAPF32[i3 >> 2]) / d25;
michael@0 37095 HEAPF32[i7 + 16 >> 2] = d41;
michael@0 37096 d34 = 1.0 / d25;
michael@0 37097 HEAPF32[i4 >> 2] = d23 * d34;
michael@0 37098 HEAPF32[i29 >> 2] = d28 * d34;
michael@0 37099 HEAPF32[i30 >> 2] = d20 * d34;
michael@0 37100 if (d41 < -9999999747378752.0e-21 & (i5 ^ 1)) {
michael@0 37101 HEAP32[i1 >> 2] = 3;
michael@0 37102 break;
michael@0 37103 } else {
michael@0 37104 i8 = i7;
michael@0 37105 return i8 | 0;
michael@0 37106 }
michael@0 37107 } else {
michael@0 37108 HEAP32[i1 >> 2] = 2;
michael@0 37109 }
michael@0 37110 } while (0);
michael@0 37111 i1 = HEAP32[i9 >> 2] | 0;
michael@0 37112 if ((i1 | 0) != 0) {
michael@0 37113 HEAP32[i1 + 48 >> 2] = HEAP32[i11 >> 2];
michael@0 37114 }
michael@0 37115 i1 = HEAP32[i11 >> 2] | 0;
michael@0 37116 if ((i1 | 0) != 0) {
michael@0 37117 HEAP32[i1 + 52 >> 2] = HEAP32[i9 >> 2];
michael@0 37118 }
michael@0 37119 if ((HEAP32[i12 >> 2] | 0) == (i7 | 0)) {
michael@0 37120 HEAP32[i12 >> 2] = HEAP32[i9 >> 2];
michael@0 37121 }
michael@0 37122 HEAP32[i13 >> 2] = (HEAP32[i13 >> 2] | 0) - 1;
michael@0 37123 HEAP32[i11 >> 2] = 0;
michael@0 37124 HEAP32[i9 >> 2] = HEAP32[i6 >> 2];
michael@0 37125 i9 = HEAP32[i6 >> 2] | 0;
michael@0 37126 if ((i9 | 0) != 0) {
michael@0 37127 HEAP32[i9 + 48 >> 2] = i7;
michael@0 37128 }
michael@0 37129 HEAP32[i6 >> 2] = i7;
michael@0 37130 HEAP32[i10 >> 2] = (HEAP32[i10 >> 2] | 0) + 1;
michael@0 37131 i8 = 0;
michael@0 37132 return i8 | 0;
michael@0 37133 }
michael@0 37134 function __ZNK21btConvexInternalShape11getAabbSlowERK11btTransformR9btVector3S4_(i1, i2, i3, i4) {
michael@0 37135 i1 = i1 | 0;
michael@0 37136 i2 = i2 | 0;
michael@0 37137 i3 = i3 | 0;
michael@0 37138 i4 = i4 | 0;
michael@0 37139 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, i33 = 0, i34 = 0, i35 = 0, i36 = 0, i37 = 0, i38 = 0, i39 = 0, i40 = 0, i41 = 0, i42 = 0, i43 = 0, i44 = 0, i45 = 0, i46 = 0, i47 = 0, i48 = 0, i49 = 0, d50 = 0.0, d51 = 0.0, d52 = 0.0, d53 = 0.0, d54 = 0.0;
michael@0 37140 i5 = STACKTOP;
michael@0 37141 STACKTOP = STACKTOP + 96 | 0;
michael@0 37142 i6 = i5 | 0;
michael@0 37143 i7 = i5 + 16 | 0;
michael@0 37144 i8 = i5 + 32 | 0;
michael@0 37145 i9 = i5 + 48 | 0;
michael@0 37146 i10 = i5 + 64 | 0;
michael@0 37147 i11 = i5 + 80 | 0;
michael@0 37148 d12 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i1 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 37149 i13 = i6 | 0;
michael@0 37150 i14 = i6 + 4 | 0;
michael@0 37151 i15 = i6 + 8 | 0;
michael@0 37152 i16 = i1;
michael@0 37153 i17 = i2 | 0;
michael@0 37154 i18 = i2 + 16 | 0;
michael@0 37155 i19 = i2 + 32 | 0;
michael@0 37156 i20 = i2 + 4 | 0;
michael@0 37157 i21 = i2 + 20 | 0;
michael@0 37158 i22 = i2 + 36 | 0;
michael@0 37159 i23 = i2 + 8 | 0;
michael@0 37160 i24 = i2 + 24 | 0;
michael@0 37161 i25 = i2 + 40 | 0;
michael@0 37162 i26 = i8 | 0;
michael@0 37163 i27 = i8 + 4 | 0;
michael@0 37164 i28 = i8 + 8 | 0;
michael@0 37165 i29 = i8 + 12 | 0;
michael@0 37166 i30 = i7 | 0;
michael@0 37167 i31 = i7 + 4 | 0;
michael@0 37168 i32 = i7 + 8 | 0;
michael@0 37169 i33 = i2 + 48 | 0;
michael@0 37170 i34 = i2 + 52 | 0;
michael@0 37171 i35 = i2 + 56 | 0;
michael@0 37172 i2 = i9 | 0;
michael@0 37173 i36 = i9 + 4 | 0;
michael@0 37174 i37 = i9 + 8 | 0;
michael@0 37175 i38 = i9 + 12 | 0;
michael@0 37176 i39 = i11 | 0;
michael@0 37177 i40 = i11 + 4 | 0;
michael@0 37178 i41 = i11 + 8 | 0;
michael@0 37179 i42 = i11 + 12 | 0;
michael@0 37180 i43 = i10 | 0;
michael@0 37181 i44 = i10 + 4 | 0;
michael@0 37182 i45 = i10 + 8 | 0;
michael@0 37183 i46 = i6;
michael@0 37184 i47 = 0;
michael@0 37185 do {
michael@0 37186 i48 = i6 + (i47 << 2) | 0;
michael@0 37187 _memset(i46 | 0, 0, 16);
michael@0 37188 HEAPF32[i48 >> 2] = 1.0;
michael@0 37189 i49 = HEAP32[(HEAP32[i16 >> 2] | 0) + 60 >> 2] | 0;
michael@0 37190 d50 = +HEAPF32[i13 >> 2];
michael@0 37191 d51 = +HEAPF32[i14 >> 2];
michael@0 37192 d52 = +HEAPF32[i15 >> 2];
michael@0 37193 d53 = d50 * +HEAPF32[i20 >> 2] + d51 * +HEAPF32[i21 >> 2] + d52 * +HEAPF32[i22 >> 2];
michael@0 37194 d54 = d50 * +HEAPF32[i23 >> 2] + d51 * +HEAPF32[i24 >> 2] + d52 * +HEAPF32[i25 >> 2];
michael@0 37195 HEAPF32[i26 >> 2] = +HEAPF32[i17 >> 2] * d50 + +HEAPF32[i18 >> 2] * d51 + +HEAPF32[i19 >> 2] * d52;
michael@0 37196 HEAPF32[i27 >> 2] = d53;
michael@0 37197 HEAPF32[i28 >> 2] = d54;
michael@0 37198 HEAPF32[i29 >> 2] = 0.0;
michael@0 37199 FUNCTION_TABLE_viii[i49 & 127](i7, i1, i8);
michael@0 37200 d54 = +HEAPF32[i30 >> 2];
michael@0 37201 d53 = +HEAPF32[i31 >> 2];
michael@0 37202 d52 = +HEAPF32[i32 >> 2];
michael@0 37203 d51 = +HEAPF32[i34 >> 2] + (d54 * +HEAPF32[i18 >> 2] + d53 * +HEAPF32[i21 >> 2] + d52 * +HEAPF32[i24 >> 2]);
michael@0 37204 d50 = +HEAPF32[i35 >> 2] + (d54 * +HEAPF32[i19 >> 2] + d53 * +HEAPF32[i22 >> 2] + d52 * +HEAPF32[i25 >> 2]);
michael@0 37205 HEAPF32[i2 >> 2] = +HEAPF32[i33 >> 2] + (+HEAPF32[i17 >> 2] * d54 + +HEAPF32[i20 >> 2] * d53 + +HEAPF32[i23 >> 2] * d52);
michael@0 37206 HEAPF32[i36 >> 2] = d51;
michael@0 37207 HEAPF32[i37 >> 2] = d50;
michael@0 37208 HEAPF32[i38 >> 2] = 0.0;
michael@0 37209 i49 = i9 + (i47 << 2) | 0;
michael@0 37210 HEAPF32[i4 + (i47 << 2) >> 2] = d12 + +HEAPF32[i49 >> 2];
michael@0 37211 HEAPF32[i48 >> 2] = -1.0;
michael@0 37212 i48 = HEAP32[(HEAP32[i16 >> 2] | 0) + 60 >> 2] | 0;
michael@0 37213 d50 = +HEAPF32[i13 >> 2];
michael@0 37214 d51 = +HEAPF32[i14 >> 2];
michael@0 37215 d52 = +HEAPF32[i15 >> 2];
michael@0 37216 d53 = d50 * +HEAPF32[i20 >> 2] + d51 * +HEAPF32[i21 >> 2] + d52 * +HEAPF32[i22 >> 2];
michael@0 37217 d54 = d50 * +HEAPF32[i23 >> 2] + d51 * +HEAPF32[i24 >> 2] + d52 * +HEAPF32[i25 >> 2];
michael@0 37218 HEAPF32[i39 >> 2] = +HEAPF32[i17 >> 2] * d50 + +HEAPF32[i18 >> 2] * d51 + +HEAPF32[i19 >> 2] * d52;
michael@0 37219 HEAPF32[i40 >> 2] = d53;
michael@0 37220 HEAPF32[i41 >> 2] = d54;
michael@0 37221 HEAPF32[i42 >> 2] = 0.0;
michael@0 37222 FUNCTION_TABLE_viii[i48 & 127](i10, i1, i11);
michael@0 37223 d54 = +HEAPF32[i43 >> 2];
michael@0 37224 d53 = +HEAPF32[i44 >> 2];
michael@0 37225 d52 = +HEAPF32[i45 >> 2];
michael@0 37226 d51 = +HEAPF32[i34 >> 2] + (d54 * +HEAPF32[i18 >> 2] + d53 * +HEAPF32[i21 >> 2] + d52 * +HEAPF32[i24 >> 2]);
michael@0 37227 d50 = +HEAPF32[i35 >> 2] + (d54 * +HEAPF32[i19 >> 2] + d53 * +HEAPF32[i22 >> 2] + d52 * +HEAPF32[i25 >> 2]);
michael@0 37228 HEAPF32[i2 >> 2] = +HEAPF32[i33 >> 2] + (+HEAPF32[i17 >> 2] * d54 + +HEAPF32[i20 >> 2] * d53 + +HEAPF32[i23 >> 2] * d52);
michael@0 37229 HEAPF32[i36 >> 2] = d51;
michael@0 37230 HEAPF32[i37 >> 2] = d50;
michael@0 37231 HEAPF32[i38 >> 2] = 0.0;
michael@0 37232 HEAPF32[i3 + (i47 << 2) >> 2] = +HEAPF32[i49 >> 2] - d12;
michael@0 37233 i47 = i47 + 1 | 0;
michael@0 37234 } while ((i47 | 0) < 3);
michael@0 37235 STACKTOP = i5;
michael@0 37236 return;
michael@0 37237 }
michael@0 37238 function __ZN28btHashedOverlappingPairCache21removeOverlappingPairEP17btBroadphaseProxyS1_P12btDispatcher(i1, i2, i3, i4) {
michael@0 37239 i1 = i1 | 0;
michael@0 37240 i2 = i2 | 0;
michael@0 37241 i3 = i3 | 0;
michael@0 37242 i4 = i4 | 0;
michael@0 37243 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0;
michael@0 37244 HEAP32[2984] = (HEAP32[2984] | 0) + 1;
michael@0 37245 i5 = (HEAP32[i2 + 12 >> 2] | 0) > (HEAP32[i3 + 12 >> 2] | 0);
michael@0 37246 i6 = i5 ? i3 : i2;
michael@0 37247 i7 = i5 ? i2 : i3;
michael@0 37248 i3 = HEAP32[i6 + 12 >> 2] | 0;
michael@0 37249 i2 = HEAP32[i7 + 12 >> 2] | 0;
michael@0 37250 i5 = i2 << 16 | i3;
michael@0 37251 i8 = i5 + ~(i5 << 15) | 0;
michael@0 37252 i5 = (i8 >> 10 ^ i8) * 9 | 0;
michael@0 37253 i8 = i5 >> 6 ^ i5;
michael@0 37254 i5 = i8 + ~(i8 << 11) | 0;
michael@0 37255 i8 = i1 + 12 | 0;
michael@0 37256 i9 = (i5 >> 16 ^ i5) & (HEAP32[i8 >> 2] | 0) - 1;
michael@0 37257 i5 = i1 + 44 | 0;
michael@0 37258 i10 = HEAP32[(HEAP32[i5 >> 2] | 0) + (i9 << 2) >> 2] | 0;
michael@0 37259 if ((i10 | 0) == -1) {
michael@0 37260 i11 = 0;
michael@0 37261 return i11 | 0;
michael@0 37262 }
michael@0 37263 i12 = i1 + 16 | 0;
michael@0 37264 i13 = HEAP32[i12 >> 2] | 0;
michael@0 37265 i14 = i1 + 64 | 0;
michael@0 37266 i15 = i10;
michael@0 37267 while (1) {
michael@0 37268 if ((HEAP32[(HEAP32[i13 + (i15 << 4) >> 2] | 0) + 12 >> 2] | 0) == (i3 | 0)) {
michael@0 37269 if ((HEAP32[(HEAP32[i13 + (i15 << 4) + 4 >> 2] | 0) + 12 >> 2] | 0) == (i2 | 0)) {
michael@0 37270 break;
michael@0 37271 }
michael@0 37272 }
michael@0 37273 i10 = HEAP32[(HEAP32[i14 >> 2] | 0) + (i15 << 2) >> 2] | 0;
michael@0 37274 if ((i10 | 0) == -1) {
michael@0 37275 i11 = 0;
michael@0 37276 i16 = 1623;
michael@0 37277 break;
michael@0 37278 } else {
michael@0 37279 i15 = i10;
michael@0 37280 }
michael@0 37281 }
michael@0 37282 if ((i16 | 0) == 1623) {
michael@0 37283 return i11 | 0;
michael@0 37284 }
michael@0 37285 i2 = i13 + (i15 << 4) | 0;
michael@0 37286 if ((i2 | 0) == 0) {
michael@0 37287 i11 = 0;
michael@0 37288 return i11 | 0;
michael@0 37289 }
michael@0 37290 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 32 >> 2] & 127](i1, i2, i4);
michael@0 37291 i3 = HEAP32[i13 + (i15 << 4) + 12 >> 2] | 0;
michael@0 37292 i15 = i2 - (HEAP32[i12 >> 2] | 0) >> 4;
michael@0 37293 i2 = (HEAP32[i5 >> 2] | 0) + (i9 << 2) | 0;
michael@0 37294 i9 = HEAP32[i2 >> 2] | 0;
michael@0 37295 i13 = HEAP32[i14 >> 2] | 0;
michael@0 37296 do {
michael@0 37297 if ((i9 | 0) == (i15 | 0)) {
michael@0 37298 i17 = HEAP32[i13 + (i15 << 2) >> 2] | 0;
michael@0 37299 i16 = 1609;
michael@0 37300 } else {
michael@0 37301 i10 = i9;
michael@0 37302 while (1) {
michael@0 37303 i18 = i13 + (i10 << 2) | 0;
michael@0 37304 i19 = HEAP32[i18 >> 2] | 0;
michael@0 37305 if ((i19 | 0) == (i15 | 0)) {
michael@0 37306 break;
michael@0 37307 } else {
michael@0 37308 i10 = i19;
michael@0 37309 }
michael@0 37310 }
michael@0 37311 i19 = HEAP32[i13 + (i15 << 2) >> 2] | 0;
michael@0 37312 if ((i10 | 0) == -1) {
michael@0 37313 i17 = i19;
michael@0 37314 i16 = 1609;
michael@0 37315 break;
michael@0 37316 }
michael@0 37317 HEAP32[i18 >> 2] = i19;
michael@0 37318 }
michael@0 37319 } while (0);
michael@0 37320 if ((i16 | 0) == 1609) {
michael@0 37321 HEAP32[i2 >> 2] = i17;
michael@0 37322 }
michael@0 37323 i17 = i1 + 8 | 0;
michael@0 37324 i2 = (HEAP32[i17 >> 2] | 0) - 1 | 0;
michael@0 37325 i18 = HEAP32[i1 + 72 >> 2] | 0;
michael@0 37326 if ((i18 | 0) != 0) {
michael@0 37327 i1 = HEAP32[(HEAP32[i18 >> 2] | 0) + 12 >> 2] | 0;
michael@0 37328 FUNCTION_TABLE_iiiii[i1 & 31](i18, i6, i7, i4) | 0;
michael@0 37329 }
michael@0 37330 if ((i2 | 0) == (i15 | 0)) {
michael@0 37331 HEAP32[i17 >> 2] = (HEAP32[i17 >> 2] | 0) - 1;
michael@0 37332 i11 = i3;
michael@0 37333 return i11 | 0;
michael@0 37334 }
michael@0 37335 i4 = HEAP32[i12 >> 2] | 0;
michael@0 37336 i12 = HEAP32[(HEAP32[i4 + (i2 << 4) + 4 >> 2] | 0) + 12 >> 2] << 16 | HEAP32[(HEAP32[i4 + (i2 << 4) >> 2] | 0) + 12 >> 2];
michael@0 37337 i7 = i12 + ~(i12 << 15) | 0;
michael@0 37338 i12 = (i7 >> 10 ^ i7) * 9 | 0;
michael@0 37339 i7 = i12 >> 6 ^ i12;
michael@0 37340 i12 = i7 + ~(i7 << 11) | 0;
michael@0 37341 i7 = (i12 >> 16 ^ i12) & (HEAP32[i8 >> 2] | 0) - 1;
michael@0 37342 i8 = (HEAP32[i5 >> 2] | 0) + (i7 << 2) | 0;
michael@0 37343 i12 = HEAP32[i8 >> 2] | 0;
michael@0 37344 i6 = HEAP32[i14 >> 2] | 0;
michael@0 37345 do {
michael@0 37346 if ((i12 | 0) == (i2 | 0)) {
michael@0 37347 i20 = HEAP32[i6 + (i2 << 2) >> 2] | 0;
michael@0 37348 i16 = 1619;
michael@0 37349 } else {
michael@0 37350 i18 = i12;
michael@0 37351 while (1) {
michael@0 37352 i21 = i6 + (i18 << 2) | 0;
michael@0 37353 i1 = HEAP32[i21 >> 2] | 0;
michael@0 37354 if ((i1 | 0) == (i2 | 0)) {
michael@0 37355 break;
michael@0 37356 } else {
michael@0 37357 i18 = i1;
michael@0 37358 }
michael@0 37359 }
michael@0 37360 i10 = HEAP32[i6 + (i2 << 2) >> 2] | 0;
michael@0 37361 if ((i18 | 0) == -1) {
michael@0 37362 i20 = i10;
michael@0 37363 i16 = 1619;
michael@0 37364 break;
michael@0 37365 }
michael@0 37366 HEAP32[i21 >> 2] = i10;
michael@0 37367 }
michael@0 37368 } while (0);
michael@0 37369 if ((i16 | 0) == 1619) {
michael@0 37370 HEAP32[i8 >> 2] = i20;
michael@0 37371 }
michael@0 37372 i20 = i4 + (i15 << 4) | 0;
michael@0 37373 i8 = i4 + (i2 << 4) | 0;
michael@0 37374 HEAP32[i20 >> 2] = HEAP32[i8 >> 2];
michael@0 37375 HEAP32[i20 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 37376 HEAP32[i20 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 37377 HEAP32[i20 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 37378 i8 = (HEAP32[i5 >> 2] | 0) + (i7 << 2) | 0;
michael@0 37379 HEAP32[(HEAP32[i14 >> 2] | 0) + (i15 << 2) >> 2] = HEAP32[i8 >> 2];
michael@0 37380 HEAP32[i8 >> 2] = i15;
michael@0 37381 HEAP32[i17 >> 2] = (HEAP32[i17 >> 2] | 0) - 1;
michael@0 37382 i11 = i3;
michael@0 37383 return i11 | 0;
michael@0 37384 }
michael@0 37385 function __Z11cullPoints2iPfiiPi(i1, i2, i3, i4, i5) {
michael@0 37386 i1 = i1 | 0;
michael@0 37387 i2 = i2 | 0;
michael@0 37388 i3 = i3 | 0;
michael@0 37389 i4 = i4 | 0;
michael@0 37390 i5 = i5 | 0;
michael@0 37391 var i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, i29 = 0, i30 = 0, i31 = 0, i32 = 0, d33 = 0.0, d34 = 0.0, i35 = 0, d36 = 0.0;
michael@0 37392 i6 = STACKTOP;
michael@0 37393 STACKTOP = STACKTOP + 64 | 0;
michael@0 37394 i7 = i6 | 0;
michael@0 37395 i8 = i6 + 32 | 0;
michael@0 37396 if ((i1 | 0) == 1) {
michael@0 37397 d9 = +HEAPF32[i2 >> 2];
michael@0 37398 d10 = +HEAPF32[i2 + 4 >> 2];
michael@0 37399 i11 = 825;
michael@0 37400 } else if ((i1 | 0) == 2) {
michael@0 37401 d9 = (+HEAPF32[i2 >> 2] + +HEAPF32[i2 + 8 >> 2]) * .5;
michael@0 37402 d10 = (+HEAPF32[i2 + 4 >> 2] + +HEAPF32[i2 + 12 >> 2]) * .5;
michael@0 37403 i11 = 825;
michael@0 37404 } else {
michael@0 37405 i12 = i1 - 1 | 0;
michael@0 37406 if ((i12 | 0) > 0) {
michael@0 37407 i13 = 0;
michael@0 37408 d14 = 0.0;
michael@0 37409 d15 = 0.0;
michael@0 37410 d16 = 0.0;
michael@0 37411 while (1) {
michael@0 37412 i17 = i13 << 1;
michael@0 37413 d18 = +HEAPF32[i2 + (i17 << 2) >> 2];
michael@0 37414 d19 = +HEAPF32[i2 + (i17 + 3 << 2) >> 2];
michael@0 37415 d20 = +HEAPF32[i2 + (i17 + 2 << 2) >> 2];
michael@0 37416 d21 = +HEAPF32[i2 + ((i17 | 1) << 2) >> 2];
michael@0 37417 d22 = d18 * d19 - d20 * d21;
michael@0 37418 d23 = d14 + d22;
michael@0 37419 d24 = d15 + (d18 + d20) * d22;
michael@0 37420 d20 = d16 + (d19 + d21) * d22;
michael@0 37421 i17 = i13 + 1 | 0;
michael@0 37422 if ((i17 | 0) < (i12 | 0)) {
michael@0 37423 i13 = i17;
michael@0 37424 d14 = d23;
michael@0 37425 d15 = d24;
michael@0 37426 d16 = d20;
michael@0 37427 } else {
michael@0 37428 d25 = d23;
michael@0 37429 d26 = d24;
michael@0 37430 d27 = d20;
michael@0 37431 break;
michael@0 37432 }
michael@0 37433 }
michael@0 37434 } else {
michael@0 37435 d25 = 0.0;
michael@0 37436 d26 = 0.0;
michael@0 37437 d27 = 0.0;
michael@0 37438 }
michael@0 37439 i13 = i1 << 1;
michael@0 37440 d16 = +HEAPF32[i2 + (i13 - 2 << 2) >> 2];
michael@0 37441 d15 = +HEAPF32[i2 + 4 >> 2];
michael@0 37442 d14 = +HEAPF32[i2 >> 2];
michael@0 37443 d20 = +HEAPF32[i2 + (i13 - 1 << 2) >> 2];
michael@0 37444 d24 = d16 * d15 - d14 * d20;
michael@0 37445 d23 = d25 + d24;
michael@0 37446 if (+Math_abs(+d23) > 1.1920928955078125e-7) {
michael@0 37447 d28 = 1.0 / (d23 * 3.0);
michael@0 37448 } else {
michael@0 37449 d28 = 999999984306749400.0;
michael@0 37450 }
michael@0 37451 if ((i1 | 0) > 0) {
michael@0 37452 d9 = (d26 + (d16 + d14) * d24) * d28;
michael@0 37453 d10 = (d27 + (d15 + d20) * d24) * d28;
michael@0 37454 i11 = 825;
michael@0 37455 } else {
michael@0 37456 i29 = 0;
michael@0 37457 }
michael@0 37458 }
michael@0 37459 if ((i11 | 0) == 825) {
michael@0 37460 i11 = 0;
michael@0 37461 while (1) {
michael@0 37462 i13 = i11 << 1;
michael@0 37463 HEAPF32[i7 + (i11 << 2) >> 2] = +Math_atan2(+(+HEAPF32[i2 + ((i13 | 1) << 2) >> 2] - d10), +(+HEAPF32[i2 + (i13 << 2) >> 2] - d9));
michael@0 37464 i13 = i11 + 1 | 0;
michael@0 37465 if ((i13 | 0) < (i1 | 0)) {
michael@0 37466 i11 = i13;
michael@0 37467 } else {
michael@0 37468 i30 = 0;
michael@0 37469 break;
michael@0 37470 }
michael@0 37471 }
michael@0 37472 while (1) {
michael@0 37473 HEAP32[i8 + (i30 << 2) >> 2] = 1;
michael@0 37474 i11 = i30 + 1 | 0;
michael@0 37475 if ((i11 | 0) < (i1 | 0)) {
michael@0 37476 i30 = i11;
michael@0 37477 } else {
michael@0 37478 i29 = 1;
michael@0 37479 break;
michael@0 37480 }
michael@0 37481 }
michael@0 37482 }
michael@0 37483 i30 = i8 + (i4 << 2) | 0;
michael@0 37484 HEAP32[i30 >> 2] = 0;
michael@0 37485 HEAP32[i5 >> 2] = i4;
michael@0 37486 if ((i3 | 0) <= 1) {
michael@0 37487 STACKTOP = i6;
michael@0 37488 return;
michael@0 37489 }
michael@0 37490 d9 = 6.2831854820251465 / +(i3 | 0);
michael@0 37491 d10 = +HEAPF32[i7 + (i4 << 2) >> 2];
michael@0 37492 if (i29) {
michael@0 37493 i31 = 1;
michael@0 37494 i32 = i5;
michael@0 37495 } else {
michael@0 37496 i29 = 1;
michael@0 37497 i11 = i5;
michael@0 37498 do {
michael@0 37499 i11 = i11 + 4 | 0;
michael@0 37500 HEAP32[i11 >> 2] = i4;
michael@0 37501 HEAP32[i30 >> 2] = 0;
michael@0 37502 i29 = i29 + 1 | 0;
michael@0 37503 } while ((i29 | 0) < (i3 | 0));
michael@0 37504 STACKTOP = i6;
michael@0 37505 return;
michael@0 37506 }
michael@0 37507 do {
michael@0 37508 i32 = i32 + 4 | 0;
michael@0 37509 d28 = d10 + d9 * +(i31 | 0);
michael@0 37510 if (d28 > 3.1415927410125732) {
michael@0 37511 d33 = d28 - 6.2831854820251465;
michael@0 37512 } else {
michael@0 37513 d33 = d28;
michael@0 37514 }
michael@0 37515 HEAP32[i32 >> 2] = i4;
michael@0 37516 i29 = 0;
michael@0 37517 d28 = 1.0e9;
michael@0 37518 i30 = i4;
michael@0 37519 while (1) {
michael@0 37520 do {
michael@0 37521 if ((HEAP32[i8 + (i29 << 2) >> 2] | 0) == 0) {
michael@0 37522 d34 = d28;
michael@0 37523 i35 = i30;
michael@0 37524 } else {
michael@0 37525 d24 = +Math_abs(+(+HEAPF32[i7 + (i29 << 2) >> 2] - d33));
michael@0 37526 if (d24 > 3.1415927410125732) {
michael@0 37527 d36 = 6.2831854820251465 - d24;
michael@0 37528 } else {
michael@0 37529 d36 = d24;
michael@0 37530 }
michael@0 37531 if (d36 >= d28) {
michael@0 37532 d34 = d28;
michael@0 37533 i35 = i30;
michael@0 37534 break;
michael@0 37535 }
michael@0 37536 HEAP32[i32 >> 2] = i29;
michael@0 37537 d34 = d36;
michael@0 37538 i35 = i29;
michael@0 37539 }
michael@0 37540 } while (0);
michael@0 37541 i11 = i29 + 1 | 0;
michael@0 37542 if ((i11 | 0) < (i1 | 0)) {
michael@0 37543 i29 = i11;
michael@0 37544 d28 = d34;
michael@0 37545 i30 = i35;
michael@0 37546 } else {
michael@0 37547 break;
michael@0 37548 }
michael@0 37549 }
michael@0 37550 HEAP32[i8 + (i35 << 2) >> 2] = 0;
michael@0 37551 i31 = i31 + 1 | 0;
michael@0 37552 } while ((i31 | 0) < (i3 | 0));
michael@0 37553 STACKTOP = i6;
michael@0 37554 return;
michael@0 37555 }
michael@0 37556 function __ZN6btDbvt9collideTVEPK10btDbvtNodeRK12btDbvtAabbMmRNS_8ICollideE(i1, i2, i3, i4) {
michael@0 37557 i1 = i1 | 0;
michael@0 37558 i2 = i2 | 0;
michael@0 37559 i3 = i3 | 0;
michael@0 37560 i4 = i4 | 0;
michael@0 37561 var d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0;
michael@0 37562 if ((i2 | 0) == 0) {
michael@0 37563 return;
michael@0 37564 }
michael@0 37565 d5 = +HEAPF32[i3 >> 2];
michael@0 37566 d6 = +HEAPF32[i3 + 4 >> 2];
michael@0 37567 d7 = +HEAPF32[i3 + 8 >> 2];
michael@0 37568 d8 = +HEAPF32[i3 + 16 >> 2];
michael@0 37569 d9 = +HEAPF32[i3 + 20 >> 2];
michael@0 37570 d10 = +HEAPF32[i3 + 24 >> 2];
michael@0 37571 i3 = __Z22btAlignedAllocInternalji(256, 16) | 0;
michael@0 37572 i1 = i3;
michael@0 37573 if ((i3 | 0) != 0) {
michael@0 37574 HEAP32[i1 >> 2] = i2;
michael@0 37575 }
michael@0 37576 i2 = i4;
michael@0 37577 i3 = 1;
michael@0 37578 i11 = 64;
michael@0 37579 i12 = i1;
michael@0 37580 while (1) {
michael@0 37581 i1 = i3 - 1 | 0;
michael@0 37582 i13 = HEAP32[i12 + (i1 << 2) >> 2] | 0;
michael@0 37583 do {
michael@0 37584 if (+HEAPF32[i13 >> 2] > d8) {
michael@0 37585 i14 = i1;
michael@0 37586 i15 = i11;
michael@0 37587 i16 = i12;
michael@0 37588 } else {
michael@0 37589 if (+HEAPF32[i13 + 16 >> 2] < d5) {
michael@0 37590 i14 = i1;
michael@0 37591 i15 = i11;
michael@0 37592 i16 = i12;
michael@0 37593 break;
michael@0 37594 }
michael@0 37595 if (+HEAPF32[i13 + 4 >> 2] > d9) {
michael@0 37596 i14 = i1;
michael@0 37597 i15 = i11;
michael@0 37598 i16 = i12;
michael@0 37599 break;
michael@0 37600 }
michael@0 37601 if (+HEAPF32[i13 + 20 >> 2] < d6) {
michael@0 37602 i14 = i1;
michael@0 37603 i15 = i11;
michael@0 37604 i16 = i12;
michael@0 37605 break;
michael@0 37606 }
michael@0 37607 if (+HEAPF32[i13 + 8 >> 2] > d10) {
michael@0 37608 i14 = i1;
michael@0 37609 i15 = i11;
michael@0 37610 i16 = i12;
michael@0 37611 break;
michael@0 37612 }
michael@0 37613 if (+HEAPF32[i13 + 24 >> 2] < d7) {
michael@0 37614 i14 = i1;
michael@0 37615 i15 = i11;
michael@0 37616 i16 = i12;
michael@0 37617 break;
michael@0 37618 }
michael@0 37619 i17 = i13 + 40 | 0;
michael@0 37620 if ((HEAP32[i17 >> 2] | 0) == 0) {
michael@0 37621 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i2 >> 2] | 0) + 12 >> 2] & 127](i4, i13);
michael@0 37622 i14 = i1;
michael@0 37623 i15 = i11;
michael@0 37624 i16 = i12;
michael@0 37625 break;
michael@0 37626 }
michael@0 37627 i18 = HEAP32[i13 + 36 >> 2] | 0;
michael@0 37628 do {
michael@0 37629 if ((i1 | 0) == (i11 | 0)) {
michael@0 37630 i19 = (i11 | 0) == 0 ? 1 : i11 << 1;
michael@0 37631 if ((i11 | 0) >= (i19 | 0)) {
michael@0 37632 i20 = i11;
michael@0 37633 i21 = i12;
michael@0 37634 break;
michael@0 37635 }
michael@0 37636 if ((i19 | 0) == 0) {
michael@0 37637 i22 = 0;
michael@0 37638 } else {
michael@0 37639 i22 = __Z22btAlignedAllocInternalji(i19 << 2, 16) | 0;
michael@0 37640 }
michael@0 37641 if ((i11 | 0) > 0) {
michael@0 37642 i23 = 0;
michael@0 37643 do {
michael@0 37644 i24 = i22 + (i23 << 2) | 0;
michael@0 37645 if ((i24 | 0) != 0) {
michael@0 37646 HEAP32[i24 >> 2] = HEAP32[i12 + (i23 << 2) >> 2];
michael@0 37647 }
michael@0 37648 i23 = i23 + 1 | 0;
michael@0 37649 } while ((i23 | 0) < (i11 | 0));
michael@0 37650 }
michael@0 37651 if ((i12 | 0) == 0) {
michael@0 37652 i20 = i19;
michael@0 37653 i21 = i22;
michael@0 37654 break;
michael@0 37655 }
michael@0 37656 __Z21btAlignedFreeInternalPv(i12);
michael@0 37657 i20 = i19;
michael@0 37658 i21 = i22;
michael@0 37659 } else {
michael@0 37660 i20 = i11;
michael@0 37661 i21 = i12;
michael@0 37662 }
michael@0 37663 } while (0);
michael@0 37664 i23 = i21 + (i1 << 2) | 0;
michael@0 37665 if ((i23 | 0) != 0) {
michael@0 37666 HEAP32[i23 >> 2] = i18;
michael@0 37667 }
michael@0 37668 i23 = HEAP32[i17 >> 2] | 0;
michael@0 37669 do {
michael@0 37670 if ((i3 | 0) == (i20 | 0)) {
michael@0 37671 i24 = (i3 | 0) == 0 ? 1 : i3 << 1;
michael@0 37672 if ((i3 | 0) >= (i24 | 0)) {
michael@0 37673 i25 = i3;
michael@0 37674 i26 = i21;
michael@0 37675 break;
michael@0 37676 }
michael@0 37677 if ((i24 | 0) == 0) {
michael@0 37678 i27 = 0;
michael@0 37679 } else {
michael@0 37680 i27 = __Z22btAlignedAllocInternalji(i24 << 2, 16) | 0;
michael@0 37681 }
michael@0 37682 if ((i3 | 0) > 0) {
michael@0 37683 i28 = 0;
michael@0 37684 do {
michael@0 37685 i29 = i27 + (i28 << 2) | 0;
michael@0 37686 if ((i29 | 0) != 0) {
michael@0 37687 HEAP32[i29 >> 2] = HEAP32[i21 + (i28 << 2) >> 2];
michael@0 37688 }
michael@0 37689 i28 = i28 + 1 | 0;
michael@0 37690 } while ((i28 | 0) < (i3 | 0));
michael@0 37691 }
michael@0 37692 if ((i21 | 0) == 0) {
michael@0 37693 i25 = i24;
michael@0 37694 i26 = i27;
michael@0 37695 break;
michael@0 37696 }
michael@0 37697 __Z21btAlignedFreeInternalPv(i21);
michael@0 37698 i25 = i24;
michael@0 37699 i26 = i27;
michael@0 37700 } else {
michael@0 37701 i25 = i20;
michael@0 37702 i26 = i21;
michael@0 37703 }
michael@0 37704 } while (0);
michael@0 37705 i17 = i26 + (i3 << 2) | 0;
michael@0 37706 if ((i17 | 0) != 0) {
michael@0 37707 HEAP32[i17 >> 2] = i23;
michael@0 37708 }
michael@0 37709 i14 = i3 + 1 | 0;
michael@0 37710 i15 = i25;
michael@0 37711 i16 = i26;
michael@0 37712 }
michael@0 37713 } while (0);
michael@0 37714 if ((i14 | 0) > 0) {
michael@0 37715 i3 = i14;
michael@0 37716 i11 = i15;
michael@0 37717 i12 = i16;
michael@0 37718 } else {
michael@0 37719 break;
michael@0 37720 }
michael@0 37721 }
michael@0 37722 if ((i16 | 0) == 0) {
michael@0 37723 return;
michael@0 37724 }
michael@0 37725 __Z21btAlignedFreeInternalPv(i16);
michael@0 37726 return;
michael@0 37727 }
michael@0 37728 function __ZNK20btConvexHullInternal11Rational1287compareERKS0_(i1, i2) {
michael@0 37729 i1 = i1 | 0;
michael@0 37730 i2 = i2 | 0;
michael@0 37731 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0;
michael@0 37732 i3 = STACKTOP;
michael@0 37733 STACKTOP = STACKTOP + 128 | 0;
michael@0 37734 i4 = i3 | 0;
michael@0 37735 i5 = i3 + 16 | 0;
michael@0 37736 i6 = i3 + 32 | 0;
michael@0 37737 i7 = i3 + 48 | 0;
michael@0 37738 i8 = i3 + 64 | 0;
michael@0 37739 i9 = i3 + 80 | 0;
michael@0 37740 i10 = i3 + 96 | 0;
michael@0 37741 i11 = i3 + 112 | 0;
michael@0 37742 i12 = i1 + 32 | 0;
michael@0 37743 i13 = HEAP32[i12 >> 2] | 0;
michael@0 37744 i14 = HEAP32[i2 + 32 >> 2] | 0;
michael@0 37745 if ((i13 | 0) != (i14 | 0)) {
michael@0 37746 i15 = i13 - i14 | 0;
michael@0 37747 STACKTOP = i3;
michael@0 37748 return i15 | 0;
michael@0 37749 }
michael@0 37750 if ((i13 | 0) == 0) {
michael@0 37751 i15 = 0;
michael@0 37752 STACKTOP = i3;
michael@0 37753 return i15 | 0;
michael@0 37754 }
michael@0 37755 if ((HEAP8[i1 + 36 | 0] | 0) != 0) {
michael@0 37756 i14 = i1 | 0;
michael@0 37757 i16 = ___muldi3(HEAP32[i14 >> 2] | 0, HEAP32[i14 + 4 >> 2] | 0, i13, (i13 | 0) < 0 ? -1 : 0) | 0;
michael@0 37758 i15 = -(__ZNK20btConvexHullInternal11Rational1287compareEx(i2, i16, tempRet0) | 0) | 0;
michael@0 37759 STACKTOP = i3;
michael@0 37760 return i15 | 0;
michael@0 37761 }
michael@0 37762 i16 = i8;
michael@0 37763 i13 = i1;
michael@0 37764 HEAP32[i16 >> 2] = HEAP32[i13 >> 2];
michael@0 37765 HEAP32[i16 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 37766 HEAP32[i16 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 37767 HEAP32[i16 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 37768 i13 = i9;
michael@0 37769 i16 = i2 + 16 | 0;
michael@0 37770 HEAP32[i13 >> 2] = HEAP32[i16 >> 2];
michael@0 37771 HEAP32[i13 + 4 >> 2] = HEAP32[i16 + 4 >> 2];
michael@0 37772 HEAP32[i13 + 8 >> 2] = HEAP32[i16 + 8 >> 2];
michael@0 37773 HEAP32[i13 + 12 >> 2] = HEAP32[i16 + 12 >> 2];
michael@0 37774 __ZN20btConvexHullInternal4DMulINS_6Int128EyE3mulES1_S1_RS1_S3_(i8, i9, i4, i5);
michael@0 37775 i9 = i10;
michael@0 37776 i8 = i1 + 16 | 0;
michael@0 37777 HEAP32[i9 >> 2] = HEAP32[i8 >> 2];
michael@0 37778 HEAP32[i9 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 37779 HEAP32[i9 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 37780 HEAP32[i9 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 37781 i8 = i11;
michael@0 37782 i9 = i2;
michael@0 37783 HEAP32[i8 >> 2] = HEAP32[i9 >> 2];
michael@0 37784 HEAP32[i8 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 37785 HEAP32[i8 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 37786 HEAP32[i8 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 37787 __ZN20btConvexHullInternal4DMulINS_6Int128EyE3mulES1_S1_RS1_S3_(i10, i11, i6, i7);
michael@0 37788 i11 = i5 + 8 | 0;
michael@0 37789 i10 = HEAP32[i11 >> 2] | 0;
michael@0 37790 i9 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37791 i11 = i7 + 8 | 0;
michael@0 37792 i8 = HEAP32[i11 >> 2] | 0;
michael@0 37793 i2 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37794 do {
michael@0 37795 if (i9 >>> 0 < i2 >>> 0 | i9 >>> 0 == i2 >>> 0 & i10 >>> 0 < i8 >>> 0) {
michael@0 37796 i17 = -1;
michael@0 37797 } else {
michael@0 37798 if (i9 >>> 0 > i2 >>> 0 | i9 >>> 0 == i2 >>> 0 & i10 >>> 0 > i8 >>> 0) {
michael@0 37799 i17 = 1;
michael@0 37800 break;
michael@0 37801 }
michael@0 37802 i11 = i5 | 0;
michael@0 37803 i1 = HEAP32[i11 >> 2] | 0;
michael@0 37804 i16 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37805 i11 = i7 | 0;
michael@0 37806 i13 = HEAP32[i11 >> 2] | 0;
michael@0 37807 i14 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37808 if (i16 >>> 0 < i14 >>> 0 | i16 >>> 0 == i14 >>> 0 & i1 >>> 0 < i13 >>> 0) {
michael@0 37809 i17 = -1;
michael@0 37810 break;
michael@0 37811 }
michael@0 37812 i11 = i16 >>> 0 > i14 >>> 0 | i16 >>> 0 == i14 >>> 0 & i1 >>> 0 > i13 >>> 0;
michael@0 37813 if (i11) {
michael@0 37814 i17 = i11 & 1;
michael@0 37815 break;
michael@0 37816 }
michael@0 37817 i11 = i4 + 8 | 0;
michael@0 37818 i13 = HEAP32[i11 >> 2] | 0;
michael@0 37819 i1 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37820 i11 = i6 + 8 | 0;
michael@0 37821 i14 = HEAP32[i11 >> 2] | 0;
michael@0 37822 i16 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37823 do {
michael@0 37824 if (i1 >>> 0 < i16 >>> 0 | i1 >>> 0 == i16 >>> 0 & i13 >>> 0 < i14 >>> 0) {
michael@0 37825 i18 = -1;
michael@0 37826 } else {
michael@0 37827 if (i1 >>> 0 > i16 >>> 0 | i1 >>> 0 == i16 >>> 0 & i13 >>> 0 > i14 >>> 0) {
michael@0 37828 i18 = 1;
michael@0 37829 break;
michael@0 37830 }
michael@0 37831 i11 = i4 | 0;
michael@0 37832 i19 = HEAP32[i11 >> 2] | 0;
michael@0 37833 i20 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37834 i11 = i6 | 0;
michael@0 37835 i21 = HEAP32[i11 >> 2] | 0;
michael@0 37836 i22 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 37837 if (i20 >>> 0 < i22 >>> 0 | i20 >>> 0 == i22 >>> 0 & i19 >>> 0 < i21 >>> 0) {
michael@0 37838 i18 = -1;
michael@0 37839 break;
michael@0 37840 }
michael@0 37841 i18 = (i20 >>> 0 > i22 >>> 0 | i20 >>> 0 == i22 >>> 0 & i19 >>> 0 > i21 >>> 0) & 1;
michael@0 37842 }
michael@0 37843 } while (0);
michael@0 37844 i15 = Math_imul(HEAP32[i12 >> 2] | 0, i18) | 0;
michael@0 37845 STACKTOP = i3;
michael@0 37846 return i15 | 0;
michael@0 37847 }
michael@0 37848 } while (0);
michael@0 37849 i15 = Math_imul(HEAP32[i12 >> 2] | 0, i17) | 0;
michael@0 37850 STACKTOP = i3;
michael@0 37851 return i15 | 0;
michael@0 37852 }
michael@0 37853 function __ZN23btConvexConvexAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 37854 i1 = i1 | 0;
michael@0 37855 i2 = i2 | 0;
michael@0 37856 i3 = i3 | 0;
michael@0 37857 i4 = i4 | 0;
michael@0 37858 i5 = i5 | 0;
michael@0 37859 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, i17 = 0, i18 = 0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, i25 = 0, i26 = 0, i27 = 0, d28 = 0.0, d29 = 0.0;
michael@0 37860 i5 = STACKTOP;
michael@0 37861 STACKTOP = STACKTOP + 1216 | 0;
michael@0 37862 i4 = i5 | 0;
michael@0 37863 i1 = i5 + 56 | 0;
michael@0 37864 i6 = i5 + 232 | 0;
michael@0 37865 i7 = i5 + 592 | 0;
michael@0 37866 i8 = i5 + 608 | 0;
michael@0 37867 i9 = i5 + 664 | 0;
michael@0 37868 i10 = i5 + 840 | 0;
michael@0 37869 i11 = i5 + 1200 | 0;
michael@0 37870 i12 = i2 + 68 | 0;
michael@0 37871 i13 = i2 + 4 | 0;
michael@0 37872 d14 = +HEAPF32[i2 + 116 >> 2] - +HEAPF32[i2 + 52 >> 2];
michael@0 37873 d15 = +HEAPF32[i2 + 120 >> 2] - +HEAPF32[i2 + 56 >> 2];
michael@0 37874 d16 = +HEAPF32[i2 + 124 >> 2] - +HEAPF32[i2 + 60 >> 2];
michael@0 37875 i17 = i3 + 68 | 0;
michael@0 37876 i18 = i3 + 4 | 0;
michael@0 37877 d19 = +HEAPF32[i3 + 116 >> 2] - +HEAPF32[i3 + 52 >> 2];
michael@0 37878 d20 = +HEAPF32[i3 + 120 >> 2] - +HEAPF32[i3 + 56 >> 2];
michael@0 37879 d21 = +HEAPF32[i3 + 124 >> 2] - +HEAPF32[i3 + 60 >> 2];
michael@0 37880 d22 = +HEAPF32[i2 + 248 >> 2];
michael@0 37881 do {
michael@0 37882 if (d14 * d14 + d15 * d15 + d16 * d16 < d22 * d22) {
michael@0 37883 d23 = +HEAPF32[i3 + 248 >> 2];
michael@0 37884 if (d19 * d19 + d20 * d20 + d21 * d21 >= d23 * d23 & (HEAP8[12056] | 0) == 0) {
michael@0 37885 break;
michael@0 37886 } else {
michael@0 37887 d24 = 1.0;
michael@0 37888 }
michael@0 37889 STACKTOP = i5;
michael@0 37890 return +d24;
michael@0 37891 } else {
michael@0 37892 if ((HEAP8[12056] | 0) == 0) {
michael@0 37893 break;
michael@0 37894 } else {
michael@0 37895 d24 = 1.0;
michael@0 37896 }
michael@0 37897 STACKTOP = i5;
michael@0 37898 return +d24;
michael@0 37899 }
michael@0 37900 } while (0);
michael@0 37901 i25 = HEAP32[i2 + 192 >> 2] | 0;
michael@0 37902 d21 = +HEAPF32[i3 + 244 >> 2];
michael@0 37903 __ZN21btConvexInternalShapeC2Ev(i4 | 0);
michael@0 37904 HEAP32[i4 >> 2] = 4728;
michael@0 37905 HEAP32[i4 + 4 >> 2] = 8;
michael@0 37906 HEAPF32[i4 + 28 >> 2] = d21;
michael@0 37907 HEAPF32[i4 + 44 >> 2] = d21;
michael@0 37908 HEAP32[i1 >> 2] = 2280;
michael@0 37909 i26 = i1 + 164 | 0;
michael@0 37910 HEAPF32[i26 >> 2] = 999999984306749400.0;
michael@0 37911 HEAP32[i1 + 168 >> 2] = 0;
michael@0 37912 HEAPF32[i1 + 172 >> 2] = 0.0;
michael@0 37913 HEAPF32[i6 + 308 >> 2] = 9999999747378752.0e-20;
michael@0 37914 HEAP16[i6 + 332 >> 1] = 0;
michael@0 37915 i27 = i4 | 0;
michael@0 37916 __ZN15btGjkConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver(i7, i25, i27, i6);
michael@0 37917 do {
michael@0 37918 if (__ZN15btGjkConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i7, i13, i12, i18, i17, i1) | 0) {
michael@0 37919 i6 = i2 + 240 | 0;
michael@0 37920 d21 = +HEAPF32[i26 >> 2];
michael@0 37921 if (+HEAPF32[i6 >> 2] > d21) {
michael@0 37922 HEAPF32[i6 >> 2] = d21;
michael@0 37923 }
michael@0 37924 i6 = i3 + 240 | 0;
michael@0 37925 if (+HEAPF32[i6 >> 2] > d21) {
michael@0 37926 HEAPF32[i6 >> 2] = d21;
michael@0 37927 }
michael@0 37928 if (d21 >= 1.0) {
michael@0 37929 d28 = 1.0;
michael@0 37930 break;
michael@0 37931 }
michael@0 37932 d28 = d21;
michael@0 37933 } else {
michael@0 37934 d28 = 1.0;
michael@0 37935 }
michael@0 37936 } while (0);
michael@0 37937 __ZN12btConvexCastD2Ev(i7 | 0);
michael@0 37938 __ZN13btConvexShapeD2Ev(i27);
michael@0 37939 i27 = HEAP32[i3 + 192 >> 2] | 0;
michael@0 37940 d21 = +HEAPF32[i2 + 244 >> 2];
michael@0 37941 __ZN21btConvexInternalShapeC2Ev(i8 | 0);
michael@0 37942 HEAP32[i8 >> 2] = 4728;
michael@0 37943 HEAP32[i8 + 4 >> 2] = 8;
michael@0 37944 HEAPF32[i8 + 28 >> 2] = d21;
michael@0 37945 HEAPF32[i8 + 44 >> 2] = d21;
michael@0 37946 HEAP32[i9 >> 2] = 2280;
michael@0 37947 i7 = i9 + 164 | 0;
michael@0 37948 HEAPF32[i7 >> 2] = 999999984306749400.0;
michael@0 37949 HEAP32[i9 + 168 >> 2] = 0;
michael@0 37950 HEAPF32[i9 + 172 >> 2] = 0.0;
michael@0 37951 HEAPF32[i10 + 308 >> 2] = 9999999747378752.0e-20;
michael@0 37952 HEAP16[i10 + 332 >> 1] = 0;
michael@0 37953 i26 = i8 | 0;
michael@0 37954 __ZN15btGjkConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver(i11, i26, i27, i10);
michael@0 37955 do {
michael@0 37956 if (__ZN15btGjkConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i11, i13, i12, i18, i17, i9) | 0) {
michael@0 37957 i10 = i2 + 240 | 0;
michael@0 37958 d21 = +HEAPF32[i7 >> 2];
michael@0 37959 if (+HEAPF32[i10 >> 2] > d21) {
michael@0 37960 HEAPF32[i10 >> 2] = d21;
michael@0 37961 }
michael@0 37962 i10 = i3 + 240 | 0;
michael@0 37963 if (+HEAPF32[i10 >> 2] > d21) {
michael@0 37964 HEAPF32[i10 >> 2] = d21;
michael@0 37965 }
michael@0 37966 if (d28 <= d21) {
michael@0 37967 d29 = d28;
michael@0 37968 break;
michael@0 37969 }
michael@0 37970 d29 = d21;
michael@0 37971 } else {
michael@0 37972 d29 = d28;
michael@0 37973 }
michael@0 37974 } while (0);
michael@0 37975 __ZN12btConvexCastD2Ev(i11 | 0);
michael@0 37976 __ZN13btConvexShapeD2Ev(i26);
michael@0 37977 d24 = d29;
michael@0 37978 STACKTOP = i5;
michael@0 37979 return +d24;
michael@0 37980 }
michael@0 37981 function __ZNK20btConvexHullInternal11Rational1287compareEx(i1, i2, i3) {
michael@0 37982 i1 = i1 | 0;
michael@0 37983 i2 = i2 | 0;
michael@0 37984 i3 = i3 | 0;
michael@0 37985 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0;
michael@0 37986 if ((HEAP8[i1 + 36 | 0] | 0) != 0) {
michael@0 37987 i4 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 37988 i5 = i1 | 0;
michael@0 37989 i6 = ___muldi3(i4, (i4 | 0) < 0 ? -1 : 0, HEAP32[i5 >> 2] | 0, HEAP32[i5 + 4 >> 2] | 0) | 0;
michael@0 37990 i5 = tempRet0;
michael@0 37991 if ((i5 | 0) > (i3 | 0) | (i5 | 0) == (i3 | 0) & i6 >>> 0 > i2 >>> 0) {
michael@0 37992 i7 = 1;
michael@0 37993 return i7 | 0;
michael@0 37994 }
michael@0 37995 i7 = ((i5 | 0) < (i3 | 0) | (i5 | 0) == (i3 | 0) & i6 >>> 0 < i2 >>> 0) << 31 >> 31;
michael@0 37996 return i7 | 0;
michael@0 37997 }
michael@0 37998 i6 = 0;
michael@0 37999 do {
michael@0 38000 if ((i3 | 0) > (i6 | 0) | (i3 | 0) == (i6 | 0) & i2 >>> 0 > 0 >>> 0) {
michael@0 38001 i5 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 38002 if ((i5 | 0) < 1) {
michael@0 38003 i7 = -1;
michael@0 38004 } else {
michael@0 38005 i8 = i3;
michael@0 38006 i9 = i2;
michael@0 38007 i10 = i5;
michael@0 38008 break;
michael@0 38009 }
michael@0 38010 return i7 | 0;
michael@0 38011 } else {
michael@0 38012 i5 = 0;
michael@0 38013 i4 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 38014 if (!((i3 | 0) < (i5 | 0) | (i3 | 0) == (i5 | 0) & i2 >>> 0 < 0 >>> 0)) {
michael@0 38015 i7 = i4;
michael@0 38016 return i7 | 0;
michael@0 38017 }
michael@0 38018 if ((i4 | 0) > -1) {
michael@0 38019 i7 = 1;
michael@0 38020 return i7 | 0;
michael@0 38021 } else {
michael@0 38022 i5 = _i64Subtract(0, 0, i2, i3) | 0;
michael@0 38023 i8 = tempRet0;
michael@0 38024 i9 = i5;
michael@0 38025 i10 = i4;
michael@0 38026 break;
michael@0 38027 }
michael@0 38028 }
michael@0 38029 } while (0);
michael@0 38030 i3 = i1 + 24 | 0;
michael@0 38031 i2 = HEAP32[i3 >> 2] | 0;
michael@0 38032 i6 = HEAP32[i3 + 4 >> 2] | 0;
michael@0 38033 i3 = 0;
michael@0 38034 i4 = (i6 | 0) < (i3 | 0) | (i6 | 0) == (i3 | 0) & i2 >>> 0 < 0 >>> 0;
michael@0 38035 i3 = i1 + 16 | 0;
michael@0 38036 i5 = HEAP32[i3 >> 2] | 0;
michael@0 38037 i11 = HEAP32[i3 + 4 >> 2] | 0;
michael@0 38038 if (i4) {
michael@0 38039 i3 = _i64Subtract(0, 0, i5, i11) | 0;
michael@0 38040 i12 = tempRet0;
michael@0 38041 i13 = _i64Add((i5 | 0) == 0 & (i11 | 0) == 0 & 1, 0, ~i2, ~i6) | 0;
michael@0 38042 i14 = i12;
michael@0 38043 i15 = i3;
michael@0 38044 i16 = tempRet0;
michael@0 38045 i17 = i13;
michael@0 38046 } else {
michael@0 38047 i14 = i11;
michael@0 38048 i15 = i5;
michael@0 38049 i16 = i6;
michael@0 38050 i17 = i2;
michael@0 38051 }
michael@0 38052 i2 = 0;
michael@0 38053 if ((i8 | 0) < (i2 | 0) | (i8 | 0) == (i2 | 0) & i9 >>> 0 < 0 >>> 0) {
michael@0 38054 i2 = _i64Subtract(0, 0, i9, i8) | 0;
michael@0 38055 i18 = i4 ^ 1;
michael@0 38056 i19 = tempRet0;
michael@0 38057 i20 = i2;
michael@0 38058 } else {
michael@0 38059 i18 = i4;
michael@0 38060 i19 = i8;
michael@0 38061 i20 = i9;
michael@0 38062 }
michael@0 38063 i9 = i15 | 0;
michael@0 38064 i15 = i14 & 0;
michael@0 38065 i8 = i20 | 0;
michael@0 38066 i4 = i19 & 0;
michael@0 38067 i2 = ___muldi3(i8, i4, i9, i15) | 0;
michael@0 38068 i6 = tempRet0;
michael@0 38069 i5 = i19;
michael@0 38070 i11 = 0;
michael@0 38071 i13 = ___muldi3(i5, i11, i9, i15) | 0;
michael@0 38072 i15 = tempRet0;
michael@0 38073 i9 = i14;
michael@0 38074 i14 = 0;
michael@0 38075 i3 = ___muldi3(i8, i4, i9, i14) | 0;
michael@0 38076 i4 = tempRet0;
michael@0 38077 i8 = ___muldi3(i5, i11, i9, i14) | 0;
michael@0 38078 i14 = tempRet0;
michael@0 38079 i9 = _i64Add(i13 | 0, i15 & 0, i3 | 0, i4 & 0) | 0;
michael@0 38080 i3 = tempRet0;
michael@0 38081 i13 = _llvm_uadd_with_overflow_i64(i2 | 0, i6 | 0, 0, i9 | 0) | 0;
michael@0 38082 i9 = i13;
michael@0 38083 i13 = tempRet0;
michael@0 38084 i6 = tempRet1 & 1;
michael@0 38085 i2 = ___muldi3(i20, i19, i17, i16) | 0;
michael@0 38086 i16 = _i64Add(i8, i14, i2, tempRet0) | 0;
michael@0 38087 i2 = _i64Add(i16, tempRet0, i15, 0) | 0;
michael@0 38088 i15 = _i64Add(i2, tempRet0, i4, 0) | 0;
michael@0 38089 i4 = _i64Add(i15, tempRet0, i6, 0) | 0;
michael@0 38090 i6 = _i64Add(i4, tempRet0, i3, 0) | 0;
michael@0 38091 i3 = tempRet0;
michael@0 38092 if (i18) {
michael@0 38093 i18 = _i64Subtract(0, 0, i9, i13) | 0;
michael@0 38094 i4 = tempRet0;
michael@0 38095 i15 = _i64Add((i9 | 0) == 0 & (i13 | 0) == 0 & 1, 0, ~i6, ~i3) | 0;
michael@0 38096 i21 = i4;
michael@0 38097 i22 = i18;
michael@0 38098 i23 = tempRet0;
michael@0 38099 i24 = i15;
michael@0 38100 } else {
michael@0 38101 i21 = i13;
michael@0 38102 i22 = i9;
michael@0 38103 i23 = i3;
michael@0 38104 i24 = i6;
michael@0 38105 }
michael@0 38106 i6 = i1 + 8 | 0;
michael@0 38107 i3 = HEAP32[i6 >> 2] | 0;
michael@0 38108 i9 = HEAP32[i6 + 4 >> 2] | 0;
michael@0 38109 do {
michael@0 38110 if (i9 >>> 0 < i23 >>> 0 | i9 >>> 0 == i23 >>> 0 & i3 >>> 0 < i24 >>> 0) {
michael@0 38111 i25 = -1;
michael@0 38112 } else {
michael@0 38113 if (i9 >>> 0 > i23 >>> 0 | i9 >>> 0 == i23 >>> 0 & i3 >>> 0 > i24 >>> 0) {
michael@0 38114 i25 = 1;
michael@0 38115 break;
michael@0 38116 }
michael@0 38117 i6 = i1 | 0;
michael@0 38118 i13 = HEAP32[i6 >> 2] | 0;
michael@0 38119 i15 = HEAP32[i6 + 4 >> 2] | 0;
michael@0 38120 if (i15 >>> 0 < i21 >>> 0 | i15 >>> 0 == i21 >>> 0 & i13 >>> 0 < i22 >>> 0) {
michael@0 38121 i25 = -1;
michael@0 38122 break;
michael@0 38123 }
michael@0 38124 i25 = (i15 >>> 0 > i21 >>> 0 | i15 >>> 0 == i21 >>> 0 & i13 >>> 0 > i22 >>> 0) & 1;
michael@0 38125 }
michael@0 38126 } while (0);
michael@0 38127 i7 = Math_imul(i10, i25) | 0;
michael@0 38128 return i7 | 0;
michael@0 38129 }
michael@0 38130 function __ZN31btDefaultCollisionConfigurationD2Ev(i1) {
michael@0 38131 i1 = i1 | 0;
michael@0 38132 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0;
michael@0 38133 HEAP32[i1 >> 2] = 2608;
michael@0 38134 if ((HEAP8[i1 + 12 | 0] | 0) != 0) {
michael@0 38135 i2 = i1 + 8 | 0;
michael@0 38136 i3 = HEAP32[i2 >> 2] | 0;
michael@0 38137 i4 = i3 + 8 | 0;
michael@0 38138 do {
michael@0 38139 if ((HEAP32[i4 >> 2] | 0) == 0) {
michael@0 38140 i5 = i3 | 0;
michael@0 38141 do {
michael@0 38142 if ((HEAP8[i3 + 16 | 0] | 0) == 0) {
michael@0 38143 i6 = HEAP32[i5 >> 2] | 0;
michael@0 38144 if ((i6 | 0) == 0) {
michael@0 38145 break;
michael@0 38146 }
michael@0 38147 __Z21btAlignedFreeInternalPv(i6);
michael@0 38148 }
michael@0 38149 } while (0);
michael@0 38150 HEAP32[i5 >> 2] = 0;
michael@0 38151 HEAP32[i4 >> 2] = 0;
michael@0 38152 i6 = HEAP32[i2 >> 2] | 0;
michael@0 38153 i7 = i6 + 8 | 0;
michael@0 38154 if ((HEAP32[i7 >> 2] | 0) != 0) {
michael@0 38155 i8 = i6;
michael@0 38156 break;
michael@0 38157 }
michael@0 38158 i9 = i6 | 0;
michael@0 38159 do {
michael@0 38160 if ((HEAP8[i6 + 16 | 0] | 0) == 0) {
michael@0 38161 i10 = HEAP32[i9 >> 2] | 0;
michael@0 38162 if ((i10 | 0) == 0) {
michael@0 38163 break;
michael@0 38164 }
michael@0 38165 __Z21btAlignedFreeInternalPv(i10);
michael@0 38166 }
michael@0 38167 } while (0);
michael@0 38168 HEAP32[i9 >> 2] = 0;
michael@0 38169 HEAP32[i7 >> 2] = 0;
michael@0 38170 i8 = HEAP32[i2 >> 2] | 0;
michael@0 38171 } else {
michael@0 38172 i8 = i3;
michael@0 38173 }
michael@0 38174 } while (0);
michael@0 38175 __Z21btAlignedFreeInternalPv(i8);
michael@0 38176 }
michael@0 38177 if ((HEAP8[i1 + 28 | 0] | 0) != 0) {
michael@0 38178 i8 = i1 + 24 | 0;
michael@0 38179 __Z21btAlignedFreeInternalPv(HEAP32[(HEAP32[i8 >> 2] | 0) + 16 >> 2] | 0);
michael@0 38180 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38181 }
michael@0 38182 if ((HEAP8[i1 + 20 | 0] | 0) != 0) {
michael@0 38183 i8 = i1 + 16 | 0;
michael@0 38184 __Z21btAlignedFreeInternalPv(HEAP32[(HEAP32[i8 >> 2] | 0) + 16 >> 2] | 0);
michael@0 38185 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38186 }
michael@0 38187 i8 = i1 + 40 | 0;
michael@0 38188 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38189 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38190 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38191 i8 = i1 + 44 | 0;
michael@0 38192 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38193 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38194 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38195 i8 = i1 + 48 | 0;
michael@0 38196 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38197 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38198 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38199 i8 = i1 + 52 | 0;
michael@0 38200 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38201 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38202 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38203 i8 = i1 + 56 | 0;
michael@0 38204 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38205 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38206 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38207 i8 = i1 + 60 | 0;
michael@0 38208 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38209 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38210 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38211 i8 = i1 + 64 | 0;
michael@0 38212 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38213 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38214 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38215 i8 = i1 + 72 | 0;
michael@0 38216 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38217 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38218 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38219 i8 = i1 + 76 | 0;
michael@0 38220 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38221 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38222 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38223 i8 = i1 + 68 | 0;
michael@0 38224 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38225 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38226 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38227 i8 = i1 + 84 | 0;
michael@0 38228 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38229 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38230 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38231 i8 = i1 + 80 | 0;
michael@0 38232 i3 = HEAP32[i8 >> 2] | 0;
michael@0 38233 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 38234 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38235 __Z21btAlignedFreeInternalPv(HEAP32[i1 + 32 >> 2] | 0);
michael@0 38236 i8 = i1 + 36 | 0;
michael@0 38237 i1 = HEAP32[i8 >> 2] | 0;
michael@0 38238 FUNCTION_TABLE_vi[HEAP32[HEAP32[i1 >> 2] >> 2] & 511](i1);
michael@0 38239 __Z21btAlignedFreeInternalPv(HEAP32[i8 >> 2] | 0);
michael@0 38240 return;
michael@0 38241 }
michael@0 38242 function __ZN20btAlignedObjectArrayIP20btPersistentManifoldE17quickSortInternalI33btPersistentManifoldSortPredicateEEvT_ii(i1, i2, i3, i4) {
michael@0 38243 i1 = i1 | 0;
michael@0 38244 i2 = i2 | 0;
michael@0 38245 i3 = i3 | 0;
michael@0 38246 i4 = i4 | 0;
michael@0 38247 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0;
michael@0 38248 i5 = STACKTOP;
michael@0 38249 STACKTOP = STACKTOP + 16 | 0;
michael@0 38250 i6 = i2;
michael@0 38251 i2 = STACKTOP;
michael@0 38252 STACKTOP = STACKTOP + 1 | 0;
michael@0 38253 STACKTOP = STACKTOP + 7 >> 3 << 3;
michael@0 38254 HEAP8[i2] = HEAP8[i6] | 0;
michael@0 38255 i6 = i5 | 0;
michael@0 38256 i2 = i5 + 8 | 0;
michael@0 38257 i7 = i1 + 12 | 0;
michael@0 38258 i8 = HEAP32[i7 >> 2] | 0;
michael@0 38259 i9 = HEAP32[i8 + (((i4 + i3 | 0) / 2 | 0) << 2) >> 2] | 0;
michael@0 38260 i10 = i9 + 1108 | 0;
michael@0 38261 i11 = i9 + 1112 | 0;
michael@0 38262 i9 = i3;
michael@0 38263 i12 = i4;
michael@0 38264 i13 = i8;
michael@0 38265 while (1) {
michael@0 38266 i8 = HEAP32[(HEAP32[i10 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38267 i14 = (i8 | 0) > -1;
michael@0 38268 if (i14) {
michael@0 38269 i15 = i9;
michael@0 38270 while (1) {
michael@0 38271 i16 = i13 + (i15 << 2) | 0;
michael@0 38272 i17 = HEAP32[i16 >> 2] | 0;
michael@0 38273 i18 = HEAP32[(HEAP32[i17 + 1108 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38274 if ((i18 | 0) > -1) {
michael@0 38275 i19 = i18;
michael@0 38276 } else {
michael@0 38277 i19 = HEAP32[(HEAP32[i17 + 1112 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38278 }
michael@0 38279 i18 = i15 + 1 | 0;
michael@0 38280 if ((i19 | 0) < (i8 | 0)) {
michael@0 38281 i15 = i18;
michael@0 38282 } else {
michael@0 38283 i20 = i15;
michael@0 38284 i21 = i16;
michael@0 38285 i22 = i17;
michael@0 38286 i23 = i18;
michael@0 38287 break;
michael@0 38288 }
michael@0 38289 }
michael@0 38290 } else {
michael@0 38291 i15 = i9;
michael@0 38292 while (1) {
michael@0 38293 i18 = i13 + (i15 << 2) | 0;
michael@0 38294 i17 = HEAP32[i18 >> 2] | 0;
michael@0 38295 i16 = HEAP32[(HEAP32[i17 + 1108 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38296 if ((i16 | 0) > -1) {
michael@0 38297 i24 = i16;
michael@0 38298 } else {
michael@0 38299 i24 = HEAP32[(HEAP32[i17 + 1112 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38300 }
michael@0 38301 i16 = i15 + 1 | 0;
michael@0 38302 if ((i24 | 0) < (HEAP32[(HEAP32[i11 >> 2] | 0) + 208 >> 2] | 0)) {
michael@0 38303 i15 = i16;
michael@0 38304 } else {
michael@0 38305 i20 = i15;
michael@0 38306 i21 = i18;
michael@0 38307 i22 = i17;
michael@0 38308 i23 = i16;
michael@0 38309 break;
michael@0 38310 }
michael@0 38311 }
michael@0 38312 }
michael@0 38313 if (i14) {
michael@0 38314 i15 = i12;
michael@0 38315 while (1) {
michael@0 38316 i16 = HEAP32[i13 + (i15 << 2) >> 2] | 0;
michael@0 38317 i17 = HEAP32[(HEAP32[i16 + 1108 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38318 if ((i17 | 0) > -1) {
michael@0 38319 i25 = i17;
michael@0 38320 } else {
michael@0 38321 i25 = HEAP32[(HEAP32[i16 + 1112 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38322 }
michael@0 38323 i17 = i15 - 1 | 0;
michael@0 38324 if ((i8 | 0) < (i25 | 0)) {
michael@0 38325 i15 = i17;
michael@0 38326 } else {
michael@0 38327 i26 = i15;
michael@0 38328 i27 = i16;
michael@0 38329 i28 = i17;
michael@0 38330 break;
michael@0 38331 }
michael@0 38332 }
michael@0 38333 } else {
michael@0 38334 i15 = i12;
michael@0 38335 while (1) {
michael@0 38336 i8 = HEAP32[i13 + (i15 << 2) >> 2] | 0;
michael@0 38337 i14 = HEAP32[(HEAP32[i8 + 1108 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38338 if ((i14 | 0) > -1) {
michael@0 38339 i29 = i14;
michael@0 38340 } else {
michael@0 38341 i29 = HEAP32[(HEAP32[i8 + 1112 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38342 }
michael@0 38343 i14 = i15 - 1 | 0;
michael@0 38344 if ((HEAP32[(HEAP32[i11 >> 2] | 0) + 208 >> 2] | 0) < (i29 | 0)) {
michael@0 38345 i15 = i14;
michael@0 38346 } else {
michael@0 38347 i26 = i15;
michael@0 38348 i27 = i8;
michael@0 38349 i28 = i14;
michael@0 38350 break;
michael@0 38351 }
michael@0 38352 }
michael@0 38353 }
michael@0 38354 if ((i20 | 0) > (i26 | 0)) {
michael@0 38355 i30 = i20;
michael@0 38356 i31 = i26;
michael@0 38357 } else {
michael@0 38358 HEAP32[i21 >> 2] = i27;
michael@0 38359 HEAP32[(HEAP32[i7 >> 2] | 0) + (i26 << 2) >> 2] = i22;
michael@0 38360 i30 = i23;
michael@0 38361 i31 = i28;
michael@0 38362 }
michael@0 38363 if ((i30 | 0) > (i31 | 0)) {
michael@0 38364 break;
michael@0 38365 }
michael@0 38366 i9 = i30;
michael@0 38367 i12 = i31;
michael@0 38368 i13 = HEAP32[i7 >> 2] | 0;
michael@0 38369 }
michael@0 38370 if ((i31 | 0) > (i3 | 0)) {
michael@0 38371 __ZN20btAlignedObjectArrayIP20btPersistentManifoldE17quickSortInternalI33btPersistentManifoldSortPredicateEEvT_ii(i1, i6, i3, i31);
michael@0 38372 }
michael@0 38373 if ((i30 | 0) >= (i4 | 0)) {
michael@0 38374 STACKTOP = i5;
michael@0 38375 return;
michael@0 38376 }
michael@0 38377 __ZN20btAlignedObjectArrayIP20btPersistentManifoldE17quickSortInternalI33btPersistentManifoldSortPredicateEEvT_ii(i1, i2, i30, i4);
michael@0 38378 STACKTOP = i5;
michael@0 38379 return;
michael@0 38380 }
michael@0 38381 function __ZN20btAlignedObjectArrayIP17btTypedConstraintE17quickSortInternalI33btSortConstraintOnIslandPredicateEEvT_ii(i1, i2, i3, i4) {
michael@0 38382 i1 = i1 | 0;
michael@0 38383 i2 = i2 | 0;
michael@0 38384 i3 = i3 | 0;
michael@0 38385 i4 = i4 | 0;
michael@0 38386 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0, i30 = 0, i31 = 0;
michael@0 38387 i5 = STACKTOP;
michael@0 38388 STACKTOP = STACKTOP + 16 | 0;
michael@0 38389 i6 = i2;
michael@0 38390 i2 = STACKTOP;
michael@0 38391 STACKTOP = STACKTOP + 1 | 0;
michael@0 38392 STACKTOP = STACKTOP + 7 >> 3 << 3;
michael@0 38393 HEAP8[i2] = HEAP8[i6] | 0;
michael@0 38394 i6 = i5 | 0;
michael@0 38395 i2 = i5 + 8 | 0;
michael@0 38396 i7 = i1 + 12 | 0;
michael@0 38397 i8 = HEAP32[i7 >> 2] | 0;
michael@0 38398 i9 = HEAP32[i8 + (((i4 + i3 | 0) / 2 | 0) << 2) >> 2] | 0;
michael@0 38399 i10 = i9 + 24 | 0;
michael@0 38400 i11 = i9 + 28 | 0;
michael@0 38401 i9 = i3;
michael@0 38402 i12 = i4;
michael@0 38403 i13 = i8;
michael@0 38404 while (1) {
michael@0 38405 i8 = HEAP32[(HEAP32[i10 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38406 i14 = (i8 | 0) > -1;
michael@0 38407 if (i14) {
michael@0 38408 i15 = i9;
michael@0 38409 while (1) {
michael@0 38410 i16 = i13 + (i15 << 2) | 0;
michael@0 38411 i17 = HEAP32[i16 >> 2] | 0;
michael@0 38412 i18 = HEAP32[(HEAP32[i17 + 24 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38413 if ((i18 | 0) > -1) {
michael@0 38414 i19 = i18;
michael@0 38415 } else {
michael@0 38416 i19 = HEAP32[(HEAP32[i17 + 28 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38417 }
michael@0 38418 i18 = i15 + 1 | 0;
michael@0 38419 if ((i19 | 0) < (i8 | 0)) {
michael@0 38420 i15 = i18;
michael@0 38421 } else {
michael@0 38422 i20 = i15;
michael@0 38423 i21 = i16;
michael@0 38424 i22 = i17;
michael@0 38425 i23 = i18;
michael@0 38426 break;
michael@0 38427 }
michael@0 38428 }
michael@0 38429 } else {
michael@0 38430 i15 = i9;
michael@0 38431 while (1) {
michael@0 38432 i18 = i13 + (i15 << 2) | 0;
michael@0 38433 i17 = HEAP32[i18 >> 2] | 0;
michael@0 38434 i16 = HEAP32[(HEAP32[i17 + 24 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38435 if ((i16 | 0) > -1) {
michael@0 38436 i24 = i16;
michael@0 38437 } else {
michael@0 38438 i24 = HEAP32[(HEAP32[i17 + 28 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38439 }
michael@0 38440 i16 = i15 + 1 | 0;
michael@0 38441 if ((i24 | 0) < (HEAP32[(HEAP32[i11 >> 2] | 0) + 208 >> 2] | 0)) {
michael@0 38442 i15 = i16;
michael@0 38443 } else {
michael@0 38444 i20 = i15;
michael@0 38445 i21 = i18;
michael@0 38446 i22 = i17;
michael@0 38447 i23 = i16;
michael@0 38448 break;
michael@0 38449 }
michael@0 38450 }
michael@0 38451 }
michael@0 38452 if (i14) {
michael@0 38453 i15 = i12;
michael@0 38454 while (1) {
michael@0 38455 i16 = HEAP32[i13 + (i15 << 2) >> 2] | 0;
michael@0 38456 i17 = HEAP32[(HEAP32[i16 + 24 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38457 if ((i17 | 0) > -1) {
michael@0 38458 i25 = i17;
michael@0 38459 } else {
michael@0 38460 i25 = HEAP32[(HEAP32[i16 + 28 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38461 }
michael@0 38462 i17 = i15 - 1 | 0;
michael@0 38463 if ((i8 | 0) < (i25 | 0)) {
michael@0 38464 i15 = i17;
michael@0 38465 } else {
michael@0 38466 i26 = i15;
michael@0 38467 i27 = i16;
michael@0 38468 i28 = i17;
michael@0 38469 break;
michael@0 38470 }
michael@0 38471 }
michael@0 38472 } else {
michael@0 38473 i15 = i12;
michael@0 38474 while (1) {
michael@0 38475 i8 = HEAP32[i13 + (i15 << 2) >> 2] | 0;
michael@0 38476 i14 = HEAP32[(HEAP32[i8 + 24 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38477 if ((i14 | 0) > -1) {
michael@0 38478 i29 = i14;
michael@0 38479 } else {
michael@0 38480 i29 = HEAP32[(HEAP32[i8 + 28 >> 2] | 0) + 208 >> 2] | 0;
michael@0 38481 }
michael@0 38482 i14 = i15 - 1 | 0;
michael@0 38483 if ((HEAP32[(HEAP32[i11 >> 2] | 0) + 208 >> 2] | 0) < (i29 | 0)) {
michael@0 38484 i15 = i14;
michael@0 38485 } else {
michael@0 38486 i26 = i15;
michael@0 38487 i27 = i8;
michael@0 38488 i28 = i14;
michael@0 38489 break;
michael@0 38490 }
michael@0 38491 }
michael@0 38492 }
michael@0 38493 if ((i20 | 0) > (i26 | 0)) {
michael@0 38494 i30 = i20;
michael@0 38495 i31 = i26;
michael@0 38496 } else {
michael@0 38497 HEAP32[i21 >> 2] = i27;
michael@0 38498 HEAP32[(HEAP32[i7 >> 2] | 0) + (i26 << 2) >> 2] = i22;
michael@0 38499 i30 = i23;
michael@0 38500 i31 = i28;
michael@0 38501 }
michael@0 38502 if ((i30 | 0) > (i31 | 0)) {
michael@0 38503 break;
michael@0 38504 }
michael@0 38505 i9 = i30;
michael@0 38506 i12 = i31;
michael@0 38507 i13 = HEAP32[i7 >> 2] | 0;
michael@0 38508 }
michael@0 38509 if ((i31 | 0) > (i3 | 0)) {
michael@0 38510 __ZN20btAlignedObjectArrayIP17btTypedConstraintE17quickSortInternalI33btSortConstraintOnIslandPredicateEEvT_ii(i1, i6, i3, i31);
michael@0 38511 }
michael@0 38512 if ((i30 | 0) >= (i4 | 0)) {
michael@0 38513 STACKTOP = i5;
michael@0 38514 return;
michael@0 38515 }
michael@0 38516 __ZN20btAlignedObjectArrayIP17btTypedConstraintE17quickSortInternalI33btSortConstraintOnIslandPredicateEEvT_ii(i1, i2, i30, i4);
michael@0 38517 STACKTOP = i5;
michael@0 38518 return;
michael@0 38519 }
michael@0 38520 function __ZN21btCollisionDispatcher14getNewManifoldEPvS0_(i1, i2, i3) {
michael@0 38521 i1 = i1 | 0;
michael@0 38522 i2 = i2 | 0;
michael@0 38523 i3 = i3 | 0;
michael@0 38524 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0;
michael@0 38525 i4 = STACKTOP;
michael@0 38526 STACKTOP = STACKTOP + 16 | 0;
michael@0 38527 i5 = i4 | 0;
michael@0 38528 i6 = i4 + 8 | 0;
michael@0 38529 HEAP32[2990] = (HEAP32[2990] | 0) + 1;
michael@0 38530 i7 = i1 + 4 | 0;
michael@0 38531 if ((HEAP32[i7 >> 2] & 2 | 0) == 0) {
michael@0 38532 i8 = 16;
michael@0 38533 } else {
michael@0 38534 i9 = HEAP32[i2 + 192 >> 2] | 0;
michael@0 38535 d10 = +FUNCTION_TABLE_fif[HEAP32[(HEAP32[i9 >> 2] | 0) + 20 >> 2] & 3](i9, +HEAPF32[4]);
michael@0 38536 HEAPF32[i5 >> 2] = d10;
michael@0 38537 i9 = HEAP32[i3 + 192 >> 2] | 0;
michael@0 38538 d11 = +FUNCTION_TABLE_fif[HEAP32[(HEAP32[i9 >> 2] | 0) + 20 >> 2] & 3](i9, +HEAPF32[4]);
michael@0 38539 HEAPF32[i6 >> 2] = d11;
michael@0 38540 i8 = d10 < d11 ? i5 : i6;
michael@0 38541 }
michael@0 38542 d11 = +HEAPF32[i8 >> 2];
michael@0 38543 d10 = +HEAPF32[i2 + 184 >> 2];
michael@0 38544 d12 = +HEAPF32[i3 + 184 >> 2];
michael@0 38545 d13 = d10 < d12 ? d10 : d12;
michael@0 38546 i8 = HEAP32[i1 + 196 >> 2] | 0;
michael@0 38547 i6 = i8 + 8 | 0;
michael@0 38548 i5 = HEAP32[i6 >> 2] | 0;
michael@0 38549 do {
michael@0 38550 if ((i5 | 0) == 0) {
michael@0 38551 if ((HEAP32[i7 >> 2] & 4 | 0) == 0) {
michael@0 38552 i14 = __Z22btAlignedAllocInternalji(1140, 16) | 0;
michael@0 38553 break;
michael@0 38554 } else {
michael@0 38555 i15 = 0;
michael@0 38556 STACKTOP = i4;
michael@0 38557 return i15 | 0;
michael@0 38558 }
michael@0 38559 } else {
michael@0 38560 i9 = i8 + 12 | 0;
michael@0 38561 i16 = HEAP32[i9 >> 2] | 0;
michael@0 38562 HEAP32[i9 >> 2] = HEAP32[i16 >> 2];
michael@0 38563 HEAP32[i6 >> 2] = i5 - 1;
michael@0 38564 i14 = i16;
michael@0 38565 }
michael@0 38566 } while (0);
michael@0 38567 i5 = i14;
michael@0 38568 HEAP32[i14 >> 2] = 1025;
michael@0 38569 HEAP32[i14 + 112 >> 2] = 0;
michael@0 38570 HEAPF32[i14 + 116 >> 2] = 0.0;
michael@0 38571 HEAP8[i14 + 120 | 0] = 0;
michael@0 38572 _memset(i14 + 124 | 0, 0, 28);
michael@0 38573 HEAP32[i14 + 388 >> 2] = 0;
michael@0 38574 HEAPF32[i14 + 392 >> 2] = 0.0;
michael@0 38575 HEAP8[i14 + 396 | 0] = 0;
michael@0 38576 _memset(i14 + 400 | 0, 0, 28);
michael@0 38577 HEAP32[i14 + 664 >> 2] = 0;
michael@0 38578 HEAPF32[i14 + 668 >> 2] = 0.0;
michael@0 38579 HEAP8[i14 + 672 | 0] = 0;
michael@0 38580 _memset(i14 + 676 | 0, 0, 28);
michael@0 38581 HEAP32[i14 + 940 >> 2] = 0;
michael@0 38582 HEAPF32[i14 + 944 >> 2] = 0.0;
michael@0 38583 HEAP8[i14 + 948 | 0] = 0;
michael@0 38584 _memset(i14 + 952 | 0, 0, 28);
michael@0 38585 HEAP32[i14 + 1108 >> 2] = i2;
michael@0 38586 HEAP32[i14 + 1112 >> 2] = i3;
michael@0 38587 HEAP32[i14 + 1116 >> 2] = 0;
michael@0 38588 HEAPF32[i14 + 1120 >> 2] = d11;
michael@0 38589 HEAPF32[i14 + 1124 >> 2] = d13;
michael@0 38590 i3 = i1 + 12 | 0;
michael@0 38591 HEAP32[i14 + 1136 >> 2] = HEAP32[i3 >> 2];
michael@0 38592 i14 = HEAP32[i3 >> 2] | 0;
michael@0 38593 i2 = i1 + 16 | 0;
michael@0 38594 do {
michael@0 38595 if ((i14 | 0) == (HEAP32[i2 >> 2] | 0)) {
michael@0 38596 i6 = (i14 | 0) == 0 ? 1 : i14 << 1;
michael@0 38597 if ((i14 | 0) >= (i6 | 0)) {
michael@0 38598 i17 = i14;
michael@0 38599 break;
michael@0 38600 }
michael@0 38601 if ((i6 | 0) == 0) {
michael@0 38602 i18 = 0;
michael@0 38603 i19 = i14;
michael@0 38604 } else {
michael@0 38605 i8 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 38606 i18 = i8;
michael@0 38607 i19 = HEAP32[i3 >> 2] | 0;
michael@0 38608 }
michael@0 38609 i8 = i1 + 20 | 0;
michael@0 38610 if ((i19 | 0) > 0) {
michael@0 38611 i7 = 0;
michael@0 38612 do {
michael@0 38613 i16 = i18 + (i7 << 2) | 0;
michael@0 38614 if ((i16 | 0) != 0) {
michael@0 38615 HEAP32[i16 >> 2] = HEAP32[(HEAP32[i8 >> 2] | 0) + (i7 << 2) >> 2];
michael@0 38616 }
michael@0 38617 i7 = i7 + 1 | 0;
michael@0 38618 } while ((i7 | 0) < (i19 | 0));
michael@0 38619 }
michael@0 38620 i7 = HEAP32[i8 >> 2] | 0;
michael@0 38621 i16 = i1 + 24 | 0;
michael@0 38622 if ((i7 | 0) == 0) {
michael@0 38623 i20 = i19;
michael@0 38624 } else {
michael@0 38625 if ((HEAP8[i16] | 0) == 0) {
michael@0 38626 i21 = i19;
michael@0 38627 } else {
michael@0 38628 __Z21btAlignedFreeInternalPv(i7);
michael@0 38629 i21 = HEAP32[i3 >> 2] | 0;
michael@0 38630 }
michael@0 38631 HEAP32[i8 >> 2] = 0;
michael@0 38632 i20 = i21;
michael@0 38633 }
michael@0 38634 HEAP8[i16] = 1;
michael@0 38635 HEAP32[i8 >> 2] = i18;
michael@0 38636 HEAP32[i2 >> 2] = i6;
michael@0 38637 i17 = i20;
michael@0 38638 } else {
michael@0 38639 i17 = i14;
michael@0 38640 }
michael@0 38641 } while (0);
michael@0 38642 i14 = (HEAP32[i1 + 20 >> 2] | 0) + (i17 << 2) | 0;
michael@0 38643 if ((i14 | 0) != 0) {
michael@0 38644 HEAP32[i14 >> 2] = i5;
michael@0 38645 }
michael@0 38646 HEAP32[i3 >> 2] = i17 + 1;
michael@0 38647 i15 = i5;
michael@0 38648 STACKTOP = i4;
michael@0 38649 return i15 | 0;
michael@0 38650 }
michael@0 38651 function __ZN17DebugDrawcallback15processTriangleEP9btVector3ii(i1, i2, i3, i4) {
michael@0 38652 i1 = i1 | 0;
michael@0 38653 i2 = i2 | 0;
michael@0 38654 i3 = i3 | 0;
michael@0 38655 i4 = i4 | 0;
michael@0 38656 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, i32 = 0, i33 = 0;
michael@0 38657 i4 = STACKTOP;
michael@0 38658 STACKTOP = STACKTOP + 96 | 0;
michael@0 38659 i3 = i4 | 0;
michael@0 38660 i5 = i4 + 16 | 0;
michael@0 38661 i6 = i4 + 32 | 0;
michael@0 38662 i7 = i4 + 48 | 0;
michael@0 38663 i8 = i4 + 64 | 0;
michael@0 38664 i9 = i4 + 80 | 0;
michael@0 38665 d10 = +HEAPF32[i1 + 28 >> 2];
michael@0 38666 d11 = +HEAPF32[i2 >> 2];
michael@0 38667 d12 = +HEAPF32[i1 + 32 >> 2];
michael@0 38668 d13 = +HEAPF32[i2 + 4 >> 2];
michael@0 38669 d14 = +HEAPF32[i1 + 36 >> 2];
michael@0 38670 d15 = +HEAPF32[i2 + 8 >> 2];
michael@0 38671 d16 = +HEAPF32[i1 + 76 >> 2];
michael@0 38672 d17 = d16 + (d10 * d11 + d12 * d13 + d14 * d15);
michael@0 38673 d18 = +HEAPF32[i1 + 44 >> 2];
michael@0 38674 d19 = +HEAPF32[i1 + 48 >> 2];
michael@0 38675 d20 = +HEAPF32[i1 + 52 >> 2];
michael@0 38676 d21 = +HEAPF32[i1 + 80 >> 2];
michael@0 38677 d22 = d21 + (d11 * d18 + d13 * d19 + d15 * d20);
michael@0 38678 d23 = +HEAPF32[i1 + 60 >> 2];
michael@0 38679 d24 = +HEAPF32[i1 + 64 >> 2];
michael@0 38680 d25 = +HEAPF32[i1 + 68 >> 2];
michael@0 38681 d26 = +HEAPF32[i1 + 84 >> 2];
michael@0 38682 d27 = d26 + (d11 * d23 + d13 * d24 + d15 * d25);
michael@0 38683 HEAPF32[i3 >> 2] = d17;
michael@0 38684 HEAPF32[i3 + 4 >> 2] = d22;
michael@0 38685 HEAPF32[i3 + 8 >> 2] = d27;
michael@0 38686 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 38687 d15 = +HEAPF32[i2 + 16 >> 2];
michael@0 38688 d13 = +HEAPF32[i2 + 20 >> 2];
michael@0 38689 d11 = +HEAPF32[i2 + 24 >> 2];
michael@0 38690 d28 = d16 + (d10 * d15 + d12 * d13 + d14 * d11);
michael@0 38691 d29 = d21 + (d18 * d15 + d19 * d13 + d20 * d11);
michael@0 38692 d30 = d26 + (d23 * d15 + d24 * d13 + d25 * d11);
michael@0 38693 HEAPF32[i5 >> 2] = d28;
michael@0 38694 HEAPF32[i5 + 4 >> 2] = d29;
michael@0 38695 HEAPF32[i5 + 8 >> 2] = d30;
michael@0 38696 HEAPF32[i5 + 12 >> 2] = 0.0;
michael@0 38697 d11 = +HEAPF32[i2 + 32 >> 2];
michael@0 38698 d13 = +HEAPF32[i2 + 36 >> 2];
michael@0 38699 d15 = +HEAPF32[i2 + 40 >> 2];
michael@0 38700 d31 = d16 + (d10 * d11 + d12 * d13 + d14 * d15);
michael@0 38701 d14 = d21 + (d18 * d11 + d19 * d13 + d20 * d15);
michael@0 38702 d20 = d26 + (d23 * d11 + d24 * d13 + d25 * d15);
michael@0 38703 HEAPF32[i6 >> 2] = d31;
michael@0 38704 HEAPF32[i6 + 4 >> 2] = d14;
michael@0 38705 HEAPF32[i6 + 8 >> 2] = d20;
michael@0 38706 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 38707 d15 = (d17 + d28 + d31) * .3333333432674408;
michael@0 38708 d25 = (d22 + d29 + d14) * .3333333432674408;
michael@0 38709 d13 = (d27 + d30 + d20) * .3333333432674408;
michael@0 38710 HEAPF32[i7 >> 2] = d15;
michael@0 38711 HEAPF32[i7 + 4 >> 2] = d25;
michael@0 38712 HEAPF32[i7 + 8 >> 2] = d13;
michael@0 38713 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 38714 d24 = d28 - d17;
michael@0 38715 d28 = d29 - d22;
michael@0 38716 d29 = d30 - d27;
michael@0 38717 d30 = d31 - d17;
michael@0 38718 d17 = d14 - d22;
michael@0 38719 d22 = d20 - d27;
michael@0 38720 d27 = d28 * d22 - d29 * d17;
michael@0 38721 d20 = d29 * d30 - d24 * d22;
michael@0 38722 d22 = d24 * d17 - d28 * d30;
michael@0 38723 d30 = 1.0 / +Math_sqrt(+(d22 * d22 + (d27 * d27 + d20 * d20)));
michael@0 38724 HEAPF32[i8 >> 2] = 1.0;
michael@0 38725 HEAPF32[i8 + 4 >> 2] = 1.0;
michael@0 38726 HEAPF32[i8 + 8 >> 2] = 0.0;
michael@0 38727 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 38728 i2 = i1 + 8 | 0;
michael@0 38729 i32 = HEAP32[i2 >> 2] | 0;
michael@0 38730 i33 = HEAP32[(HEAP32[i32 >> 2] | 0) + 8 >> 2] | 0;
michael@0 38731 HEAPF32[i9 >> 2] = d15 + d30 * d27;
michael@0 38732 HEAPF32[i9 + 4 >> 2] = d25 + d30 * d20;
michael@0 38733 HEAPF32[i9 + 8 >> 2] = d13 + d30 * d22;
michael@0 38734 HEAPF32[i9 + 12 >> 2] = 0.0;
michael@0 38735 FUNCTION_TABLE_viiii[i33 & 127](i32, i7, i9, i8);
michael@0 38736 i8 = HEAP32[i2 >> 2] | 0;
michael@0 38737 i9 = i1 + 12 | 0;
michael@0 38738 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i8 >> 2] | 0) + 8 >> 2] & 127](i8, i3, i5, i9);
michael@0 38739 i8 = HEAP32[i2 >> 2] | 0;
michael@0 38740 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i8 >> 2] | 0) + 8 >> 2] & 127](i8, i5, i6, i9);
michael@0 38741 i5 = HEAP32[i2 >> 2] | 0;
michael@0 38742 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i5 >> 2] | 0) + 8 >> 2] & 127](i5, i6, i3, i9);
michael@0 38743 STACKTOP = i4;
michael@0 38744 return;
michael@0 38745 }
michael@0 38746 function __ZN34btSphereTriangleCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 38747 i1 = i1 | 0;
michael@0 38748 i2 = i2 | 0;
michael@0 38749 i3 = i3 | 0;
michael@0 38750 i4 = i4 | 0;
michael@0 38751 i5 = i5 | 0;
michael@0 38752 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 38753 i6 = STACKTOP;
michael@0 38754 STACKTOP = STACKTOP + 152 | 0;
michael@0 38755 i7 = i6 | 0;
michael@0 38756 i8 = i6 + 16 | 0;
michael@0 38757 i9 = i1 + 12 | 0;
michael@0 38758 i10 = HEAP32[i9 >> 2] | 0;
michael@0 38759 if ((i10 | 0) == 0) {
michael@0 38760 STACKTOP = i6;
michael@0 38761 return;
michael@0 38762 }
michael@0 38763 i11 = i1 + 16 | 0;
michael@0 38764 i12 = (HEAP8[i11] | 0) != 0;
michael@0 38765 i13 = i12 ? i3 : i2;
michael@0 38766 i14 = i12 ? i2 : i3;
michael@0 38767 i3 = HEAP32[i13 + 192 >> 2] | 0;
michael@0 38768 i2 = HEAP32[i14 + 192 >> 2] | 0;
michael@0 38769 i12 = i5 + 4 | 0;
michael@0 38770 HEAP32[i12 >> 2] = i10;
michael@0 38771 __ZN22SphereTriangleDetectorC2EP13btSphereShapeP15btTriangleShapef(i7, i3, i2, +__ZNK20btPersistentManifold27getContactBreakingThresholdEv(HEAP32[i9 >> 2] | 0));
michael@0 38772 HEAP32[i8 + 132 >> 2] = 0;
michael@0 38773 HEAPF32[i8 + 128 >> 2] = 999999984306749400.0;
michael@0 38774 i9 = i8;
michael@0 38775 i2 = i13 + 4 | 0;
michael@0 38776 HEAP32[i9 >> 2] = HEAP32[i2 >> 2];
michael@0 38777 HEAP32[i9 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 38778 HEAP32[i9 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 38779 HEAP32[i9 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 38780 i2 = i8 + 16 | 0;
michael@0 38781 i9 = i13 + 20 | 0;
michael@0 38782 HEAP32[i2 >> 2] = HEAP32[i9 >> 2];
michael@0 38783 HEAP32[i2 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 38784 HEAP32[i2 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 38785 HEAP32[i2 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 38786 i9 = i8 + 32 | 0;
michael@0 38787 i2 = i13 + 36 | 0;
michael@0 38788 HEAP32[i9 >> 2] = HEAP32[i2 >> 2];
michael@0 38789 HEAP32[i9 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 38790 HEAP32[i9 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 38791 HEAP32[i9 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 38792 i2 = i8 + 48 | 0;
michael@0 38793 i9 = i13 + 52 | 0;
michael@0 38794 HEAP32[i2 >> 2] = HEAP32[i9 >> 2];
michael@0 38795 HEAP32[i2 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 38796 HEAP32[i2 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 38797 HEAP32[i2 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 38798 i9 = i8 + 64 | 0;
michael@0 38799 i2 = i14 + 4 | 0;
michael@0 38800 HEAP32[i9 >> 2] = HEAP32[i2 >> 2];
michael@0 38801 HEAP32[i9 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 38802 HEAP32[i9 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 38803 HEAP32[i9 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 38804 i2 = i8 + 80 | 0;
michael@0 38805 i9 = i14 + 20 | 0;
michael@0 38806 HEAP32[i2 >> 2] = HEAP32[i9 >> 2];
michael@0 38807 HEAP32[i2 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 38808 HEAP32[i2 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 38809 HEAP32[i2 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 38810 i9 = i8 + 96 | 0;
michael@0 38811 i2 = i14 + 36 | 0;
michael@0 38812 HEAP32[i9 >> 2] = HEAP32[i2 >> 2];
michael@0 38813 HEAP32[i9 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 38814 HEAP32[i9 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 38815 HEAP32[i9 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 38816 i2 = i8 + 112 | 0;
michael@0 38817 i9 = i14 + 52 | 0;
michael@0 38818 HEAP32[i2 >> 2] = HEAP32[i9 >> 2];
michael@0 38819 HEAP32[i2 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 38820 HEAP32[i2 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 38821 HEAP32[i2 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 38822 __ZN22SphereTriangleDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i7, i8, i5 | 0, HEAP32[i4 + 20 >> 2] | 0, (HEAP8[i11] | 0) != 0);
michael@0 38823 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 38824 STACKTOP = i6;
michael@0 38825 return;
michael@0 38826 }
michael@0 38827 i1 = HEAP32[i12 >> 2] | 0;
michael@0 38828 if ((HEAP32[i1 + 1116 >> 2] | 0) == 0) {
michael@0 38829 STACKTOP = i6;
michael@0 38830 return;
michael@0 38831 }
michael@0 38832 if ((HEAP32[i1 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 38833 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 8 | 0, i5 + 72 | 0);
michael@0 38834 STACKTOP = i6;
michael@0 38835 return;
michael@0 38836 } else {
michael@0 38837 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 72 | 0, i5 + 8 | 0);
michael@0 38838 STACKTOP = i6;
michael@0 38839 return;
michael@0 38840 }
michael@0 38841 }
michael@0 38842 function __ZN16btCollisionWorld25serializeCollisionObjectsEP12btSerializer(i1, i2) {
michael@0 38843 i1 = i1 | 0;
michael@0 38844 i2 = i2 | 0;
michael@0 38845 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0;
michael@0 38846 i3 = STACKTOP;
michael@0 38847 STACKTOP = STACKTOP + 96 | 0;
michael@0 38848 i4 = i3 | 0;
michael@0 38849 i5 = i3 + 80 | 0;
michael@0 38850 i6 = i3 + 88 | 0;
michael@0 38851 i7 = i1 + 8 | 0;
michael@0 38852 i8 = HEAP32[i7 >> 2] | 0;
michael@0 38853 if ((i8 | 0) > 0) {
michael@0 38854 i9 = i1 + 16 | 0;
michael@0 38855 i10 = 0;
michael@0 38856 i11 = i8;
michael@0 38857 while (1) {
michael@0 38858 i12 = HEAP32[(HEAP32[i9 >> 2] | 0) + (i10 << 2) >> 2] | 0;
michael@0 38859 if ((HEAP32[i12 + 232 >> 2] | 0) == 1) {
michael@0 38860 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i12 >> 2] | 0) + 24 >> 2] & 127](i12, i2);
michael@0 38861 i13 = HEAP32[i7 >> 2] | 0;
michael@0 38862 } else {
michael@0 38863 i13 = i11;
michael@0 38864 }
michael@0 38865 i12 = i10 + 1 | 0;
michael@0 38866 if ((i12 | 0) < (i13 | 0)) {
michael@0 38867 i10 = i12;
michael@0 38868 i11 = i13;
michael@0 38869 } else {
michael@0 38870 i14 = i13;
michael@0 38871 break;
michael@0 38872 }
michael@0 38873 }
michael@0 38874 } else {
michael@0 38875 i14 = i8;
michael@0 38876 }
michael@0 38877 HEAP8[i4 + 16 | 0] = 1;
michael@0 38878 i8 = i4 + 12 | 0;
michael@0 38879 HEAP32[i8 >> 2] = 0;
michael@0 38880 i13 = i4 + 4 | 0;
michael@0 38881 HEAP32[i13 >> 2] = 0;
michael@0 38882 HEAP32[i4 + 8 >> 2] = 0;
michael@0 38883 HEAP8[i4 + 36 | 0] = 1;
michael@0 38884 i11 = i4 + 32 | 0;
michael@0 38885 HEAP32[i11 >> 2] = 0;
michael@0 38886 HEAP32[i4 + 24 >> 2] = 0;
michael@0 38887 HEAP32[i4 + 28 >> 2] = 0;
michael@0 38888 HEAP8[i4 + 56 | 0] = 1;
michael@0 38889 i10 = i4 + 52 | 0;
michael@0 38890 HEAP32[i10 >> 2] = 0;
michael@0 38891 HEAP32[i4 + 44 >> 2] = 0;
michael@0 38892 i9 = i4 + 48 | 0;
michael@0 38893 HEAP32[i9 >> 2] = 0;
michael@0 38894 HEAP8[i4 + 76 | 0] = 1;
michael@0 38895 i12 = i4 + 72 | 0;
michael@0 38896 HEAP32[i12 >> 2] = 0;
michael@0 38897 HEAP32[i4 + 64 >> 2] = 0;
michael@0 38898 HEAP32[i4 + 68 >> 2] = 0;
michael@0 38899 if ((i14 | 0) <= 0) {
michael@0 38900 __ZN9btHashMapI9btHashPtrP16btCollisionShapeED2Ev(i4);
michael@0 38901 STACKTOP = i3;
michael@0 38902 return;
michael@0 38903 }
michael@0 38904 i15 = i1 + 16 | 0;
michael@0 38905 i1 = i6 | 0;
michael@0 38906 i16 = 0;
michael@0 38907 i17 = -1;
michael@0 38908 i18 = 0;
michael@0 38909 i19 = i14;
michael@0 38910 while (1) {
michael@0 38911 i14 = HEAP32[(HEAP32[(HEAP32[i15 >> 2] | 0) + (i16 << 2) >> 2] | 0) + 192 >> 2] | 0;
michael@0 38912 HEAP32[i5 >> 2] = i14;
michael@0 38913 i20 = i14;
michael@0 38914 i21 = i20 + ~(i20 << 15) | 0;
michael@0 38915 i22 = (i21 >> 10 ^ i21) * 9 | 0;
michael@0 38916 i21 = i22 >> 6 ^ i22;
michael@0 38917 i22 = i21 + ~(i21 << 11) | 0;
michael@0 38918 i21 = (i22 >> 16 ^ i22) & i17;
michael@0 38919 i22 = i14;
michael@0 38920 L410 : do {
michael@0 38921 if (i21 >>> 0 < i18 >>> 0) {
michael@0 38922 i14 = HEAP32[(HEAP32[i8 >> 2] | 0) + (i21 << 2) >> 2] | 0;
michael@0 38923 if ((i14 | 0) == -1) {
michael@0 38924 i23 = 364;
michael@0 38925 break;
michael@0 38926 }
michael@0 38927 i24 = HEAP32[i12 >> 2] | 0;
michael@0 38928 i25 = HEAP32[i11 >> 2] | 0;
michael@0 38929 i26 = i14;
michael@0 38930 while (1) {
michael@0 38931 if ((i22 | 0) == (HEAP32[i24 + (i26 << 3) >> 2] | 0)) {
michael@0 38932 break;
michael@0 38933 }
michael@0 38934 i14 = HEAP32[i25 + (i26 << 2) >> 2] | 0;
michael@0 38935 if ((i14 | 0) == -1) {
michael@0 38936 i23 = 364;
michael@0 38937 break L410;
michael@0 38938 } else {
michael@0 38939 i26 = i14;
michael@0 38940 }
michael@0 38941 }
michael@0 38942 if ((i26 | 0) == -1) {
michael@0 38943 i23 = 364;
michael@0 38944 break;
michael@0 38945 }
michael@0 38946 if (((HEAP32[i10 >> 2] | 0) + (i26 << 2) | 0) == 0) {
michael@0 38947 i23 = 364;
michael@0 38948 } else {
michael@0 38949 i27 = i19;
michael@0 38950 }
michael@0 38951 } else {
michael@0 38952 i23 = 364;
michael@0 38953 }
michael@0 38954 } while (0);
michael@0 38955 if ((i23 | 0) == 364) {
michael@0 38956 i23 = 0;
michael@0 38957 HEAP32[i1 >> 2] = i20;
michael@0 38958 __ZN9btHashMapI9btHashPtrP16btCollisionShapeE6insertERKS0_RKS2_(i4, i6, i5);
michael@0 38959 i22 = HEAP32[i5 >> 2] | 0;
michael@0 38960 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i22 >> 2] | 0) + 56 >> 2] & 127](i22, i2);
michael@0 38961 i27 = HEAP32[i7 >> 2] | 0;
michael@0 38962 }
michael@0 38963 i22 = i16 + 1 | 0;
michael@0 38964 if ((i22 | 0) >= (i27 | 0)) {
michael@0 38965 break;
michael@0 38966 }
michael@0 38967 i16 = i22;
michael@0 38968 i17 = (HEAP32[i9 >> 2] | 0) - 1 | 0;
michael@0 38969 i18 = HEAP32[i13 >> 2] | 0;
michael@0 38970 i19 = i27;
michael@0 38971 }
michael@0 38972 __ZN9btHashMapI9btHashPtrP16btCollisionShapeED2Ev(i4);
michael@0 38973 STACKTOP = i3;
michael@0 38974 return;
michael@0 38975 }
michael@0 38976 function __ZN28btHashedOverlappingPairCache10growTablesEv(i1) {
michael@0 38977 i1 = i1 | 0;
michael@0 38978 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 38979 i2 = i1 + 12 | 0;
michael@0 38980 i3 = HEAP32[i2 >> 2] | 0;
michael@0 38981 i4 = i1 + 36 | 0;
michael@0 38982 i5 = HEAP32[i4 >> 2] | 0;
michael@0 38983 if ((i5 | 0) >= (i3 | 0)) {
michael@0 38984 return;
michael@0 38985 }
michael@0 38986 if ((i5 | 0) <= (i3 | 0)) {
michael@0 38987 i6 = i1 + 40 | 0;
michael@0 38988 if ((HEAP32[i6 >> 2] | 0) < (i3 | 0)) {
michael@0 38989 if ((i3 | 0) == 0) {
michael@0 38990 i7 = 0;
michael@0 38991 i8 = i5;
michael@0 38992 } else {
michael@0 38993 i9 = __Z22btAlignedAllocInternalji(i3 << 2, 16) | 0;
michael@0 38994 i7 = i9;
michael@0 38995 i8 = HEAP32[i4 >> 2] | 0;
michael@0 38996 }
michael@0 38997 i9 = i1 + 44 | 0;
michael@0 38998 if ((i8 | 0) > 0) {
michael@0 38999 i10 = 0;
michael@0 39000 do {
michael@0 39001 i11 = i7 + (i10 << 2) | 0;
michael@0 39002 if ((i11 | 0) != 0) {
michael@0 39003 HEAP32[i11 >> 2] = HEAP32[(HEAP32[i9 >> 2] | 0) + (i10 << 2) >> 2];
michael@0 39004 }
michael@0 39005 i10 = i10 + 1 | 0;
michael@0 39006 } while ((i10 | 0) < (i8 | 0));
michael@0 39007 }
michael@0 39008 i8 = HEAP32[i9 >> 2] | 0;
michael@0 39009 i10 = i1 + 48 | 0;
michael@0 39010 if ((i8 | 0) != 0) {
michael@0 39011 if ((HEAP8[i10] | 0) != 0) {
michael@0 39012 __Z21btAlignedFreeInternalPv(i8);
michael@0 39013 }
michael@0 39014 HEAP32[i9 >> 2] = 0;
michael@0 39015 }
michael@0 39016 HEAP8[i10] = 1;
michael@0 39017 HEAP32[i9 >> 2] = i7;
michael@0 39018 HEAP32[i6 >> 2] = i3;
michael@0 39019 i12 = i7;
michael@0 39020 } else {
michael@0 39021 i12 = HEAP32[i1 + 44 >> 2] | 0;
michael@0 39022 }
michael@0 39023 i7 = i5;
michael@0 39024 do {
michael@0 39025 i6 = i12 + (i7 << 2) | 0;
michael@0 39026 if ((i6 | 0) != 0) {
michael@0 39027 HEAP32[i6 >> 2] = 0;
michael@0 39028 }
michael@0 39029 i7 = i7 + 1 | 0;
michael@0 39030 } while ((i7 | 0) < (i3 | 0));
michael@0 39031 }
michael@0 39032 HEAP32[i4 >> 2] = i3;
michael@0 39033 i4 = i1 + 56 | 0;
michael@0 39034 i7 = HEAP32[i4 >> 2] | 0;
michael@0 39035 if ((i7 | 0) < (i3 | 0)) {
michael@0 39036 i12 = i1 + 60 | 0;
michael@0 39037 if ((HEAP32[i12 >> 2] | 0) < (i3 | 0)) {
michael@0 39038 if ((i3 | 0) == 0) {
michael@0 39039 i13 = 0;
michael@0 39040 i14 = i7;
michael@0 39041 } else {
michael@0 39042 i6 = __Z22btAlignedAllocInternalji(i3 << 2, 16) | 0;
michael@0 39043 i13 = i6;
michael@0 39044 i14 = HEAP32[i4 >> 2] | 0;
michael@0 39045 }
michael@0 39046 i6 = i1 + 64 | 0;
michael@0 39047 if ((i14 | 0) > 0) {
michael@0 39048 i9 = 0;
michael@0 39049 do {
michael@0 39050 i10 = i13 + (i9 << 2) | 0;
michael@0 39051 if ((i10 | 0) != 0) {
michael@0 39052 HEAP32[i10 >> 2] = HEAP32[(HEAP32[i6 >> 2] | 0) + (i9 << 2) >> 2];
michael@0 39053 }
michael@0 39054 i9 = i9 + 1 | 0;
michael@0 39055 } while ((i9 | 0) < (i14 | 0));
michael@0 39056 }
michael@0 39057 i14 = HEAP32[i6 >> 2] | 0;
michael@0 39058 i9 = i1 + 68 | 0;
michael@0 39059 if ((i14 | 0) != 0) {
michael@0 39060 if ((HEAP8[i9] | 0) != 0) {
michael@0 39061 __Z21btAlignedFreeInternalPv(i14);
michael@0 39062 }
michael@0 39063 HEAP32[i6 >> 2] = 0;
michael@0 39064 }
michael@0 39065 HEAP8[i9] = 1;
michael@0 39066 HEAP32[i6 >> 2] = i13;
michael@0 39067 HEAP32[i12 >> 2] = i3;
michael@0 39068 i15 = i13;
michael@0 39069 } else {
michael@0 39070 i15 = HEAP32[i1 + 64 >> 2] | 0;
michael@0 39071 }
michael@0 39072 i13 = i7;
michael@0 39073 do {
michael@0 39074 i7 = i15 + (i13 << 2) | 0;
michael@0 39075 if ((i7 | 0) != 0) {
michael@0 39076 HEAP32[i7 >> 2] = 0;
michael@0 39077 }
michael@0 39078 i13 = i13 + 1 | 0;
michael@0 39079 } while ((i13 | 0) < (i3 | 0));
michael@0 39080 }
michael@0 39081 HEAP32[i4 >> 2] = i3;
michael@0 39082 if ((i3 | 0) > 0) {
michael@0 39083 i4 = i3 << 2;
michael@0 39084 _memset(HEAP32[i1 + 44 >> 2] | 0, -1 | 0, i4 | 0);
michael@0 39085 _memset(HEAP32[i1 + 64 >> 2] | 0, -1 | 0, i4 | 0);
michael@0 39086 }
michael@0 39087 if ((i5 | 0) <= 0) {
michael@0 39088 return;
michael@0 39089 }
michael@0 39090 i4 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 39091 i3 = HEAP32[i1 + 44 >> 2] | 0;
michael@0 39092 i13 = HEAP32[i1 + 64 >> 2] | 0;
michael@0 39093 i1 = 0;
michael@0 39094 do {
michael@0 39095 i15 = HEAP32[(HEAP32[i4 + (i1 << 4) + 4 >> 2] | 0) + 12 >> 2] << 16 | HEAP32[(HEAP32[i4 + (i1 << 4) >> 2] | 0) + 12 >> 2];
michael@0 39096 i7 = i15 + ~(i15 << 15) | 0;
michael@0 39097 i15 = (i7 >> 10 ^ i7) * 9 | 0;
michael@0 39098 i7 = i15 >> 6 ^ i15;
michael@0 39099 i15 = i7 + ~(i7 << 11) | 0;
michael@0 39100 i7 = i3 + (((i15 >> 16 ^ i15) & (HEAP32[i2 >> 2] | 0) - 1) << 2) | 0;
michael@0 39101 HEAP32[i13 + (i1 << 2) >> 2] = HEAP32[i7 >> 2];
michael@0 39102 HEAP32[i7 >> 2] = i1;
michael@0 39103 i1 = i1 + 1 | 0;
michael@0 39104 } while ((i1 | 0) < (i5 | 0));
michael@0 39105 return;
michael@0 39106 }
michael@0 39107 function __ZN15btTransformUtil22calculateDiffAxisAngleERK11btTransformS2_R9btVector3Rf(i1, i2, i3, i4) {
michael@0 39108 i1 = i1 | 0;
michael@0 39109 i2 = i2 | 0;
michael@0 39110 i3 = i3 | 0;
michael@0 39111 i4 = i4 | 0;
michael@0 39112 var i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, i26 = 0;
michael@0 39113 i5 = STACKTOP;
michael@0 39114 STACKTOP = STACKTOP + 64 | 0;
michael@0 39115 i6 = i5 | 0;
michael@0 39116 i7 = i5 + 48 | 0;
michael@0 39117 d8 = +HEAPF32[i1 + 20 >> 2];
michael@0 39118 d9 = +HEAPF32[i1 + 40 >> 2];
michael@0 39119 d10 = +HEAPF32[i1 + 24 >> 2];
michael@0 39120 d11 = +HEAPF32[i1 + 36 >> 2];
michael@0 39121 d12 = d8 * d9 - d10 * d11;
michael@0 39122 d13 = +HEAPF32[i1 + 32 >> 2];
michael@0 39123 d14 = +HEAPF32[i1 + 16 >> 2];
michael@0 39124 d15 = d10 * d13 - d9 * d14;
michael@0 39125 d16 = d11 * d14 - d8 * d13;
michael@0 39126 d17 = +HEAPF32[i1 >> 2];
michael@0 39127 d18 = +HEAPF32[i1 + 4 >> 2];
michael@0 39128 d19 = +HEAPF32[i1 + 8 >> 2];
michael@0 39129 d20 = 1.0 / (d12 * d17 + d18 * d15 + d16 * d19);
michael@0 39130 d21 = d12 * d20;
michael@0 39131 d12 = d20 * (d11 * d19 - d9 * d18);
michael@0 39132 d22 = d20 * (d10 * d18 - d8 * d19);
michael@0 39133 d23 = d15 * d20;
michael@0 39134 d15 = d20 * (d9 * d17 - d13 * d19);
michael@0 39135 d9 = d20 * (d14 * d19 - d10 * d17);
michael@0 39136 d10 = d16 * d20;
michael@0 39137 d16 = d20 * (d13 * d18 - d11 * d17);
michael@0 39138 d11 = d20 * (d8 * d17 - d14 * d18);
michael@0 39139 d18 = +HEAPF32[i2 >> 2];
michael@0 39140 d14 = +HEAPF32[i2 + 4 >> 2];
michael@0 39141 d17 = +HEAPF32[i2 + 8 >> 2];
michael@0 39142 d8 = +HEAPF32[i2 + 16 >> 2];
michael@0 39143 d20 = +HEAPF32[i2 + 20 >> 2];
michael@0 39144 d13 = +HEAPF32[i2 + 24 >> 2];
michael@0 39145 d19 = +HEAPF32[i2 + 32 >> 2];
michael@0 39146 d24 = +HEAPF32[i2 + 36 >> 2];
michael@0 39147 d25 = +HEAPF32[i2 + 40 >> 2];
michael@0 39148 HEAPF32[i6 >> 2] = d21 * d18 + d23 * d14 + d10 * d17;
michael@0 39149 HEAPF32[i6 + 4 >> 2] = d18 * d12 + d14 * d15 + d16 * d17;
michael@0 39150 HEAPF32[i6 + 8 >> 2] = d18 * d22 + d14 * d9 + d11 * d17;
michael@0 39151 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 39152 HEAPF32[i6 + 16 >> 2] = d21 * d8 + d23 * d20 + d10 * d13;
michael@0 39153 HEAPF32[i6 + 20 >> 2] = d12 * d8 + d15 * d20 + d16 * d13;
michael@0 39154 HEAPF32[i6 + 24 >> 2] = d22 * d8 + d9 * d20 + d11 * d13;
michael@0 39155 HEAPF32[i6 + 28 >> 2] = 0.0;
michael@0 39156 HEAPF32[i6 + 32 >> 2] = d21 * d19 + d23 * d24 + d10 * d25;
michael@0 39157 HEAPF32[i6 + 36 >> 2] = d12 * d19 + d15 * d24 + d16 * d25;
michael@0 39158 HEAPF32[i6 + 40 >> 2] = d22 * d19 + d9 * d24 + d11 * d25;
michael@0 39159 HEAPF32[i6 + 44 >> 2] = 0.0;
michael@0 39160 __ZNK11btMatrix3x311getRotationER12btQuaternion(i6, i7);
michael@0 39161 i6 = i7 | 0;
michael@0 39162 d25 = +HEAPF32[i6 >> 2];
michael@0 39163 i2 = i7 + 4 | 0;
michael@0 39164 d11 = +HEAPF32[i2 >> 2];
michael@0 39165 i1 = i7 + 8 | 0;
michael@0 39166 d24 = +HEAPF32[i1 >> 2];
michael@0 39167 i26 = i7 + 12 | 0;
michael@0 39168 d9 = +HEAPF32[i26 >> 2];
michael@0 39169 d19 = 1.0 / +Math_sqrt(+(d25 * d25 + d11 * d11 + d24 * d24 + d9 * d9));
michael@0 39170 d22 = d25 * d19;
michael@0 39171 HEAPF32[i6 >> 2] = d22;
michael@0 39172 d25 = d11 * d19;
michael@0 39173 HEAPF32[i2 >> 2] = d25;
michael@0 39174 d11 = d24 * d19;
michael@0 39175 HEAPF32[i1 >> 2] = d11;
michael@0 39176 d24 = d9 * d19;
michael@0 39177 HEAPF32[i26 >> 2] = d24;
michael@0 39178 d19 = d24 < -1.0 ? -1.0 : d24;
michael@0 39179 HEAPF32[i4 >> 2] = +Math_acos(+(d19 > 1.0 ? 1.0 : d19)) * 2.0;
michael@0 39180 i4 = i3 | 0;
michael@0 39181 HEAPF32[i4 >> 2] = d22;
michael@0 39182 i26 = i3 + 4 | 0;
michael@0 39183 HEAPF32[i26 >> 2] = d25;
michael@0 39184 i1 = i3 + 8 | 0;
michael@0 39185 HEAPF32[i1 >> 2] = d11;
michael@0 39186 i2 = i3 + 12 | 0;
michael@0 39187 HEAPF32[i2 >> 2] = 0.0;
michael@0 39188 d19 = d11 * d11 + (d22 * d22 + d25 * d25);
michael@0 39189 if (d19 < 1.4210854715202004e-14) {
michael@0 39190 HEAPF32[i4 >> 2] = 1.0;
michael@0 39191 HEAPF32[i26 >> 2] = 0.0;
michael@0 39192 HEAPF32[i1 >> 2] = 0.0;
michael@0 39193 HEAPF32[i2 >> 2] = 0.0;
michael@0 39194 STACKTOP = i5;
michael@0 39195 return;
michael@0 39196 } else {
michael@0 39197 d24 = 1.0 / +Math_sqrt(+d19);
michael@0 39198 HEAPF32[i4 >> 2] = d22 * d24;
michael@0 39199 HEAPF32[i26 >> 2] = d25 * d24;
michael@0 39200 HEAPF32[i1 >> 2] = d11 * d24;
michael@0 39201 STACKTOP = i5;
michael@0 39202 return;
michael@0 39203 }
michael@0 39204 }
michael@0 39205 function __ZNK11btRigidBody9serializeEPvP12btSerializer(i1, i2, i3) {
michael@0 39206 i1 = i1 | 0;
michael@0 39207 i2 = i2 | 0;
michael@0 39208 i3 = i3 | 0;
michael@0 39209 __ZNK17btCollisionObject9serializeEPvP12btSerializer(i1 | 0, i2, i3) | 0;
michael@0 39210 HEAPF32[i2 + 248 >> 2] = +HEAPF32[i1 + 256 >> 2];
michael@0 39211 HEAPF32[i2 + 252 >> 2] = +HEAPF32[i1 + 260 >> 2];
michael@0 39212 HEAPF32[i2 + 256 >> 2] = +HEAPF32[i1 + 264 >> 2];
michael@0 39213 HEAPF32[i2 + 260 >> 2] = +HEAPF32[i1 + 268 >> 2];
michael@0 39214 HEAPF32[i2 + 264 >> 2] = +HEAPF32[i1 + 272 >> 2];
michael@0 39215 HEAPF32[i2 + 268 >> 2] = +HEAPF32[i1 + 276 >> 2];
michael@0 39216 HEAPF32[i2 + 272 >> 2] = +HEAPF32[i1 + 280 >> 2];
michael@0 39217 HEAPF32[i2 + 276 >> 2] = +HEAPF32[i1 + 284 >> 2];
michael@0 39218 HEAPF32[i2 + 280 >> 2] = +HEAPF32[i1 + 288 >> 2];
michael@0 39219 HEAPF32[i2 + 284 >> 2] = +HEAPF32[i1 + 292 >> 2];
michael@0 39220 HEAPF32[i2 + 288 >> 2] = +HEAPF32[i1 + 296 >> 2];
michael@0 39221 HEAPF32[i2 + 292 >> 2] = +HEAPF32[i1 + 300 >> 2];
michael@0 39222 HEAPF32[i2 + 296 >> 2] = +HEAPF32[i1 + 304 >> 2];
michael@0 39223 HEAPF32[i2 + 300 >> 2] = +HEAPF32[i1 + 308 >> 2];
michael@0 39224 HEAPF32[i2 + 304 >> 2] = +HEAPF32[i1 + 312 >> 2];
michael@0 39225 HEAPF32[i2 + 308 >> 2] = +HEAPF32[i1 + 316 >> 2];
michael@0 39226 HEAPF32[i2 + 312 >> 2] = +HEAPF32[i1 + 320 >> 2];
michael@0 39227 HEAPF32[i2 + 316 >> 2] = +HEAPF32[i1 + 324 >> 2];
michael@0 39228 HEAPF32[i2 + 320 >> 2] = +HEAPF32[i1 + 328 >> 2];
michael@0 39229 HEAPF32[i2 + 324 >> 2] = +HEAPF32[i1 + 332 >> 2];
michael@0 39230 HEAPF32[i2 + 440 >> 2] = +HEAPF32[i1 + 336 >> 2];
michael@0 39231 HEAPF32[i2 + 328 >> 2] = +HEAPF32[i1 + 536 >> 2];
michael@0 39232 HEAPF32[i2 + 332 >> 2] = +HEAPF32[i1 + 540 >> 2];
michael@0 39233 HEAPF32[i2 + 336 >> 2] = +HEAPF32[i1 + 544 >> 2];
michael@0 39234 HEAPF32[i2 + 340 >> 2] = +HEAPF32[i1 + 548 >> 2];
michael@0 39235 HEAPF32[i2 + 344 >> 2] = +HEAPF32[i1 + 340 >> 2];
michael@0 39236 HEAPF32[i2 + 348 >> 2] = +HEAPF32[i1 + 344 >> 2];
michael@0 39237 HEAPF32[i2 + 352 >> 2] = +HEAPF32[i1 + 348 >> 2];
michael@0 39238 HEAPF32[i2 + 356 >> 2] = +HEAPF32[i1 + 352 >> 2];
michael@0 39239 HEAPF32[i2 + 360 >> 2] = +HEAPF32[i1 + 356 >> 2];
michael@0 39240 HEAPF32[i2 + 364 >> 2] = +HEAPF32[i1 + 360 >> 2];
michael@0 39241 HEAPF32[i2 + 368 >> 2] = +HEAPF32[i1 + 364 >> 2];
michael@0 39242 HEAPF32[i2 + 372 >> 2] = +HEAPF32[i1 + 368 >> 2];
michael@0 39243 HEAPF32[i2 + 376 >> 2] = +HEAPF32[i1 + 372 >> 2];
michael@0 39244 HEAPF32[i2 + 380 >> 2] = +HEAPF32[i1 + 376 >> 2];
michael@0 39245 HEAPF32[i2 + 384 >> 2] = +HEAPF32[i1 + 380 >> 2];
michael@0 39246 HEAPF32[i2 + 388 >> 2] = +HEAPF32[i1 + 384 >> 2];
michael@0 39247 HEAPF32[i2 + 392 >> 2] = +HEAPF32[i1 + 388 >> 2];
michael@0 39248 HEAPF32[i2 + 396 >> 2] = +HEAPF32[i1 + 392 >> 2];
michael@0 39249 HEAPF32[i2 + 400 >> 2] = +HEAPF32[i1 + 396 >> 2];
michael@0 39250 HEAPF32[i2 + 404 >> 2] = +HEAPF32[i1 + 400 >> 2];
michael@0 39251 HEAPF32[i2 + 408 >> 2] = +HEAPF32[i1 + 404 >> 2];
michael@0 39252 HEAPF32[i2 + 412 >> 2] = +HEAPF32[i1 + 408 >> 2];
michael@0 39253 HEAPF32[i2 + 416 >> 2] = +HEAPF32[i1 + 412 >> 2];
michael@0 39254 HEAPF32[i2 + 420 >> 2] = +HEAPF32[i1 + 416 >> 2];
michael@0 39255 HEAPF32[i2 + 424 >> 2] = +HEAPF32[i1 + 420 >> 2];
michael@0 39256 HEAPF32[i2 + 428 >> 2] = +HEAPF32[i1 + 424 >> 2];
michael@0 39257 HEAPF32[i2 + 432 >> 2] = +HEAPF32[i1 + 428 >> 2];
michael@0 39258 HEAPF32[i2 + 436 >> 2] = +HEAPF32[i1 + 432 >> 2];
michael@0 39259 HEAPF32[i2 + 444 >> 2] = +HEAPF32[i1 + 436 >> 2];
michael@0 39260 HEAPF32[i2 + 448 >> 2] = +HEAPF32[i1 + 440 >> 2];
michael@0 39261 HEAP32[i2 + 476 >> 2] = HEAPU8[i1 + 444 | 0] | 0;
michael@0 39262 HEAPF32[i2 + 452 >> 2] = +HEAPF32[i1 + 448 >> 2];
michael@0 39263 HEAPF32[i2 + 456 >> 2] = +HEAPF32[i1 + 452 >> 2];
michael@0 39264 HEAPF32[i2 + 460 >> 2] = +HEAPF32[i1 + 456 >> 2];
michael@0 39265 HEAPF32[i2 + 464 >> 2] = +HEAPF32[i1 + 460 >> 2];
michael@0 39266 HEAPF32[i2 + 468 >> 2] = +HEAPF32[i1 + 464 >> 2];
michael@0 39267 HEAPF32[i2 + 472 >> 2] = +HEAPF32[i1 + 468 >> 2];
michael@0 39268 return 600;
michael@0 39269 }
michael@0 39270 function __ZN25btTriangleRaycastCallback15processTriangleEP9btVector3ii(i1, i2, i3, i4) {
michael@0 39271 i1 = i1 | 0;
michael@0 39272 i2 = i2 | 0;
michael@0 39273 i3 = i3 | 0;
michael@0 39274 i4 = i4 | 0;
michael@0 39275 var i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, i25 = 0, i26 = 0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, i31 = 0, i32 = 0, d33 = 0.0, d34 = 0.0, d35 = 0.0;
michael@0 39276 i5 = STACKTOP;
michael@0 39277 STACKTOP = STACKTOP + 32 | 0;
michael@0 39278 i6 = i5 | 0;
michael@0 39279 i7 = i5 + 16 | 0;
michael@0 39280 d8 = +HEAPF32[i2 + 16 >> 2];
michael@0 39281 d9 = +HEAPF32[i2 >> 2];
michael@0 39282 d10 = d8 - d9;
michael@0 39283 d11 = +HEAPF32[i2 + 20 >> 2];
michael@0 39284 d12 = +HEAPF32[i2 + 4 >> 2];
michael@0 39285 d13 = d11 - d12;
michael@0 39286 d14 = +HEAPF32[i2 + 24 >> 2];
michael@0 39287 d15 = +HEAPF32[i2 + 8 >> 2];
michael@0 39288 d16 = d14 - d15;
michael@0 39289 d17 = +HEAPF32[i2 + 32 >> 2];
michael@0 39290 d18 = d17 - d9;
michael@0 39291 d19 = +HEAPF32[i2 + 36 >> 2];
michael@0 39292 d20 = d19 - d12;
michael@0 39293 d21 = +HEAPF32[i2 + 40 >> 2];
michael@0 39294 d22 = d21 - d15;
michael@0 39295 d23 = d13 * d22 - d16 * d20;
michael@0 39296 d24 = d16 * d18 - d10 * d22;
michael@0 39297 d22 = d10 * d20 - d13 * d18;
michael@0 39298 i2 = i6 | 0;
michael@0 39299 HEAPF32[i2 >> 2] = d23;
michael@0 39300 i25 = i6 + 4 | 0;
michael@0 39301 HEAPF32[i25 >> 2] = d24;
michael@0 39302 i26 = i6 + 8 | 0;
michael@0 39303 HEAPF32[i26 >> 2] = d22;
michael@0 39304 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 39305 d18 = d15 * d22 + (d9 * d23 + d12 * d24);
michael@0 39306 d13 = +HEAPF32[i1 + 4 >> 2];
michael@0 39307 d20 = +HEAPF32[i1 + 8 >> 2];
michael@0 39308 d10 = +HEAPF32[i1 + 12 >> 2];
michael@0 39309 d16 = d22 * d10 + (d13 * d23 + d20 * d24) - d18;
michael@0 39310 d27 = +HEAPF32[i1 + 20 >> 2];
michael@0 39311 d28 = +HEAPF32[i1 + 24 >> 2];
michael@0 39312 d29 = +HEAPF32[i1 + 28 >> 2];
michael@0 39313 d30 = d23 * d27 + d24 * d28 + d22 * d29 - d18;
michael@0 39314 if (d16 * d30 >= 0.0) {
michael@0 39315 STACKTOP = i5;
michael@0 39316 return;
michael@0 39317 }
michael@0 39318 i31 = HEAP32[i1 + 36 >> 2] | 0;
michael@0 39319 if ((i31 & 1 | 0) != 0 & d16 > 0.0) {
michael@0 39320 STACKTOP = i5;
michael@0 39321 return;
michael@0 39322 }
michael@0 39323 d18 = d16 / (d16 - d30);
michael@0 39324 i32 = i1 + 40 | 0;
michael@0 39325 if (d18 >= +HEAPF32[i32 >> 2]) {
michael@0 39326 STACKTOP = i5;
michael@0 39327 return;
michael@0 39328 }
michael@0 39329 d30 = d22 * d22 + (d23 * d23 + d24 * d24);
michael@0 39330 d33 = d30 * -9999999747378752.0e-20;
michael@0 39331 d34 = 1.0 - d18;
michael@0 39332 d35 = d27 * d18 + d13 * d34;
michael@0 39333 d13 = d28 * d18 + d20 * d34;
michael@0 39334 d20 = d29 * d18 + d10 * d34;
michael@0 39335 d34 = d9 - d35;
michael@0 39336 d9 = d12 - d13;
michael@0 39337 d12 = d15 - d20;
michael@0 39338 d15 = d8 - d35;
michael@0 39339 d8 = d11 - d13;
michael@0 39340 d11 = d14 - d20;
michael@0 39341 if (d22 * (d34 * d8 - d9 * d15) + (d23 * (d9 * d11 - d12 * d8) + d24 * (d12 * d15 - d34 * d11)) < d33) {
michael@0 39342 STACKTOP = i5;
michael@0 39343 return;
michael@0 39344 }
michael@0 39345 d14 = d17 - d35;
michael@0 39346 d35 = d19 - d13;
michael@0 39347 d13 = d21 - d20;
michael@0 39348 if (d22 * (d15 * d35 - d8 * d14) + (d23 * (d8 * d13 - d11 * d35) + d24 * (d11 * d14 - d15 * d13)) < d33) {
michael@0 39349 STACKTOP = i5;
michael@0 39350 return;
michael@0 39351 }
michael@0 39352 if (d22 * (d9 * d14 - d34 * d35) + (d23 * (d12 * d35 - d9 * d13) + d24 * (d34 * d13 - d12 * d14)) < d33) {
michael@0 39353 STACKTOP = i5;
michael@0 39354 return;
michael@0 39355 }
michael@0 39356 d33 = 1.0 / +Math_sqrt(+d30);
michael@0 39357 d30 = d23 * d33;
michael@0 39358 HEAPF32[i2 >> 2] = d30;
michael@0 39359 d23 = d24 * d33;
michael@0 39360 HEAPF32[i25 >> 2] = d23;
michael@0 39361 d24 = d22 * d33;
michael@0 39362 HEAPF32[i26 >> 2] = d24;
michael@0 39363 i26 = HEAP32[(HEAP32[i1 >> 2] | 0) + 12 >> 2] | 0;
michael@0 39364 if ((i31 & 2 | 0) == 0 & d16 > 0.0) {
michael@0 39365 HEAPF32[i32 >> 2] = +FUNCTION_TABLE_fiifii[i26 & 7](i1, i6, d18, i3, i4);
michael@0 39366 STACKTOP = i5;
michael@0 39367 return;
michael@0 39368 } else {
michael@0 39369 HEAPF32[i7 >> 2] = -0.0 - d30;
michael@0 39370 HEAPF32[i7 + 4 >> 2] = -0.0 - d23;
michael@0 39371 HEAPF32[i7 + 8 >> 2] = -0.0 - d24;
michael@0 39372 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 39373 HEAPF32[i32 >> 2] = +FUNCTION_TABLE_fiifii[i26 & 7](i1, i7, d18, i3, i4);
michael@0 39374 STACKTOP = i5;
michael@0 39375 return;
michael@0 39376 }
michael@0 39377 }
michael@0 39378 function __ZN9btHashMapI9btHashPtrP16btCollisionShapeE10growTablesERKS0_(i1, i2) {
michael@0 39379 i1 = i1 | 0;
michael@0 39380 i2 = i2 | 0;
michael@0 39381 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 39382 i2 = i1 + 48 | 0;
michael@0 39383 i3 = HEAP32[i2 >> 2] | 0;
michael@0 39384 i4 = i1 + 4 | 0;
michael@0 39385 i5 = HEAP32[i4 >> 2] | 0;
michael@0 39386 if ((i5 | 0) >= (i3 | 0)) {
michael@0 39387 return;
michael@0 39388 }
michael@0 39389 if ((i5 | 0) <= (i3 | 0)) {
michael@0 39390 i6 = i1 + 8 | 0;
michael@0 39391 if ((HEAP32[i6 >> 2] | 0) < (i3 | 0)) {
michael@0 39392 if ((i3 | 0) == 0) {
michael@0 39393 i7 = 0;
michael@0 39394 i8 = i5;
michael@0 39395 } else {
michael@0 39396 i9 = __Z22btAlignedAllocInternalji(i3 << 2, 16) | 0;
michael@0 39397 i7 = i9;
michael@0 39398 i8 = HEAP32[i4 >> 2] | 0;
michael@0 39399 }
michael@0 39400 i9 = i1 + 12 | 0;
michael@0 39401 if ((i8 | 0) > 0) {
michael@0 39402 i10 = 0;
michael@0 39403 do {
michael@0 39404 i11 = i7 + (i10 << 2) | 0;
michael@0 39405 if ((i11 | 0) != 0) {
michael@0 39406 HEAP32[i11 >> 2] = HEAP32[(HEAP32[i9 >> 2] | 0) + (i10 << 2) >> 2];
michael@0 39407 }
michael@0 39408 i10 = i10 + 1 | 0;
michael@0 39409 } while ((i10 | 0) < (i8 | 0));
michael@0 39410 }
michael@0 39411 i8 = HEAP32[i9 >> 2] | 0;
michael@0 39412 i10 = i1 + 16 | 0;
michael@0 39413 if ((i8 | 0) != 0) {
michael@0 39414 if ((HEAP8[i10] | 0) != 0) {
michael@0 39415 __Z21btAlignedFreeInternalPv(i8);
michael@0 39416 }
michael@0 39417 HEAP32[i9 >> 2] = 0;
michael@0 39418 }
michael@0 39419 HEAP8[i10] = 1;
michael@0 39420 HEAP32[i9 >> 2] = i7;
michael@0 39421 HEAP32[i6 >> 2] = i3;
michael@0 39422 i12 = i7;
michael@0 39423 } else {
michael@0 39424 i12 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 39425 }
michael@0 39426 i7 = i5;
michael@0 39427 do {
michael@0 39428 i6 = i12 + (i7 << 2) | 0;
michael@0 39429 if ((i6 | 0) != 0) {
michael@0 39430 HEAP32[i6 >> 2] = 0;
michael@0 39431 }
michael@0 39432 i7 = i7 + 1 | 0;
michael@0 39433 } while ((i7 | 0) < (i3 | 0));
michael@0 39434 }
michael@0 39435 HEAP32[i4 >> 2] = i3;
michael@0 39436 i4 = i1 + 24 | 0;
michael@0 39437 i7 = HEAP32[i4 >> 2] | 0;
michael@0 39438 if ((i7 | 0) < (i3 | 0)) {
michael@0 39439 i12 = i1 + 28 | 0;
michael@0 39440 if ((HEAP32[i12 >> 2] | 0) < (i3 | 0)) {
michael@0 39441 if ((i3 | 0) == 0) {
michael@0 39442 i13 = 0;
michael@0 39443 i14 = i7;
michael@0 39444 } else {
michael@0 39445 i6 = __Z22btAlignedAllocInternalji(i3 << 2, 16) | 0;
michael@0 39446 i13 = i6;
michael@0 39447 i14 = HEAP32[i4 >> 2] | 0;
michael@0 39448 }
michael@0 39449 i6 = i1 + 32 | 0;
michael@0 39450 if ((i14 | 0) > 0) {
michael@0 39451 i9 = 0;
michael@0 39452 do {
michael@0 39453 i10 = i13 + (i9 << 2) | 0;
michael@0 39454 if ((i10 | 0) != 0) {
michael@0 39455 HEAP32[i10 >> 2] = HEAP32[(HEAP32[i6 >> 2] | 0) + (i9 << 2) >> 2];
michael@0 39456 }
michael@0 39457 i9 = i9 + 1 | 0;
michael@0 39458 } while ((i9 | 0) < (i14 | 0));
michael@0 39459 }
michael@0 39460 i14 = HEAP32[i6 >> 2] | 0;
michael@0 39461 i9 = i1 + 36 | 0;
michael@0 39462 if ((i14 | 0) != 0) {
michael@0 39463 if ((HEAP8[i9] | 0) != 0) {
michael@0 39464 __Z21btAlignedFreeInternalPv(i14);
michael@0 39465 }
michael@0 39466 HEAP32[i6 >> 2] = 0;
michael@0 39467 }
michael@0 39468 HEAP8[i9] = 1;
michael@0 39469 HEAP32[i6 >> 2] = i13;
michael@0 39470 HEAP32[i12 >> 2] = i3;
michael@0 39471 i15 = i13;
michael@0 39472 } else {
michael@0 39473 i15 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 39474 }
michael@0 39475 i13 = i7;
michael@0 39476 do {
michael@0 39477 i7 = i15 + (i13 << 2) | 0;
michael@0 39478 if ((i7 | 0) != 0) {
michael@0 39479 HEAP32[i7 >> 2] = 0;
michael@0 39480 }
michael@0 39481 i13 = i13 + 1 | 0;
michael@0 39482 } while ((i13 | 0) < (i3 | 0));
michael@0 39483 }
michael@0 39484 HEAP32[i4 >> 2] = i3;
michael@0 39485 if ((i3 | 0) > 0) {
michael@0 39486 i4 = i3 << 2;
michael@0 39487 _memset(HEAP32[i1 + 12 >> 2] | 0, -1 | 0, i4 | 0);
michael@0 39488 _memset(HEAP32[i1 + 32 >> 2] | 0, -1 | 0, i4 | 0);
michael@0 39489 }
michael@0 39490 if ((i5 | 0) <= 0) {
michael@0 39491 return;
michael@0 39492 }
michael@0 39493 i4 = HEAP32[i1 + 72 >> 2] | 0;
michael@0 39494 i3 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 39495 i13 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 39496 i1 = 0;
michael@0 39497 do {
michael@0 39498 i15 = HEAP32[i4 + (i1 << 3) >> 2] | 0;
michael@0 39499 i7 = i15 + ~(i15 << 15) | 0;
michael@0 39500 i15 = (i7 >> 10 ^ i7) * 9 | 0;
michael@0 39501 i7 = i15 >> 6 ^ i15;
michael@0 39502 i15 = i7 + ~(i7 << 11) | 0;
michael@0 39503 i7 = i3 + (((i15 >> 16 ^ i15) & (HEAP32[i2 >> 2] | 0) - 1) << 2) | 0;
michael@0 39504 HEAP32[i13 + (i1 << 2) >> 2] = HEAP32[i7 >> 2];
michael@0 39505 HEAP32[i7 >> 2] = i1;
michael@0 39506 i1 = i1 + 1 | 0;
michael@0 39507 } while ((i1 | 0) < (i5 | 0));
michael@0 39508 return;
michael@0 39509 }
michael@0 39510 function __ZN35btSequentialImpulseConstraintSolver33resolveSingleConstraintRowGenericER11btRigidBodyS1_RK18btSolverConstraint(i1, i2, i3, i4) {
michael@0 39511 i1 = i1 | 0;
michael@0 39512 i2 = i2 | 0;
michael@0 39513 i3 = i3 | 0;
michael@0 39514 i4 = i4 | 0;
michael@0 39515 var d5 = 0.0, i6 = 0, d7 = 0.0, i8 = 0, i9 = 0, d10 = 0.0, i11 = 0, i12 = 0, d13 = 0.0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0;
michael@0 39516 i1 = i4 + 84 | 0;
michael@0 39517 d5 = +HEAPF32[i1 >> 2];
michael@0 39518 i6 = i4 + 16 | 0;
michael@0 39519 d7 = +HEAPF32[i6 >> 2];
michael@0 39520 i8 = i2 + 504 | 0;
michael@0 39521 i9 = i4 + 20 | 0;
michael@0 39522 d10 = +HEAPF32[i9 >> 2];
michael@0 39523 i11 = i2 + 508 | 0;
michael@0 39524 i12 = i4 + 24 | 0;
michael@0 39525 d13 = +HEAPF32[i12 >> 2];
michael@0 39526 i14 = i2 + 512 | 0;
michael@0 39527 i15 = i2 + 520 | 0;
michael@0 39528 i16 = i2 + 524 | 0;
michael@0 39529 i17 = i2 + 528 | 0;
michael@0 39530 i18 = i3 + 504 | 0;
michael@0 39531 i19 = i3 + 508 | 0;
michael@0 39532 i20 = i3 + 512 | 0;
michael@0 39533 i21 = i3 + 520 | 0;
michael@0 39534 i22 = i3 + 524 | 0;
michael@0 39535 i23 = i3 + 528 | 0;
michael@0 39536 d24 = +HEAPF32[i4 + 92 >> 2];
michael@0 39537 d25 = +HEAPF32[i4 + 116 >> 2] - d5 * +HEAPF32[i4 + 120 >> 2] - (d7 * +HEAPF32[i8 >> 2] + d10 * +HEAPF32[i11 >> 2] + d13 * +HEAPF32[i14 >> 2] + (+HEAPF32[i4 >> 2] * +HEAPF32[i15 >> 2] + +HEAPF32[i4 + 4 >> 2] * +HEAPF32[i16 >> 2] + +HEAPF32[i4 + 8 >> 2] * +HEAPF32[i17 >> 2])) * d24 - d24 * (+HEAPF32[i4 + 32 >> 2] * +HEAPF32[i21 >> 2] + +HEAPF32[i4 + 36 >> 2] * +HEAPF32[i22 >> 2] + +HEAPF32[i4 + 40 >> 2] * +HEAPF32[i23 >> 2] - (d7 * +HEAPF32[i18 >> 2] + d10 * +HEAPF32[i19 >> 2] + d13 * +HEAPF32[i20 >> 2]));
michael@0 39538 d24 = d5 + d25;
michael@0 39539 d26 = +HEAPF32[i4 + 124 >> 2];
michael@0 39540 do {
michael@0 39541 if (d24 < d26) {
michael@0 39542 HEAPF32[i1 >> 2] = d26;
michael@0 39543 d27 = d26 - d5;
michael@0 39544 } else {
michael@0 39545 d28 = +HEAPF32[i4 + 128 >> 2];
michael@0 39546 if (d24 > d28) {
michael@0 39547 HEAPF32[i1 >> 2] = d28;
michael@0 39548 d27 = d28 - d5;
michael@0 39549 break;
michael@0 39550 } else {
michael@0 39551 HEAPF32[i1 >> 2] = d24;
michael@0 39552 d27 = d25;
michael@0 39553 break;
michael@0 39554 }
michael@0 39555 }
michael@0 39556 } while (0);
michael@0 39557 if (+HEAPF32[i2 + 336 >> 2] != 0.0) {
michael@0 39558 d25 = d27 * d10 * +HEAPF32[i2 + 556 >> 2];
michael@0 39559 d10 = d27 * d13 * +HEAPF32[i2 + 560 >> 2];
michael@0 39560 HEAPF32[i8 >> 2] = +HEAPF32[i8 >> 2] + d27 * d7 * +HEAPF32[i2 + 552 >> 2];
michael@0 39561 HEAPF32[i11 >> 2] = d25 + +HEAPF32[i11 >> 2];
michael@0 39562 HEAPF32[i14 >> 2] = d10 + +HEAPF32[i14 >> 2];
michael@0 39563 d10 = d27 * +HEAPF32[i2 + 540 >> 2] * +HEAPF32[i4 + 52 >> 2];
michael@0 39564 d25 = d27 * +HEAPF32[i2 + 544 >> 2] * +HEAPF32[i4 + 56 >> 2];
michael@0 39565 HEAPF32[i15 >> 2] = d27 * +HEAPF32[i2 + 536 >> 2] * +HEAPF32[i4 + 48 >> 2] + +HEAPF32[i15 >> 2];
michael@0 39566 HEAPF32[i16 >> 2] = d10 + +HEAPF32[i16 >> 2];
michael@0 39567 HEAPF32[i17 >> 2] = d25 + +HEAPF32[i17 >> 2];
michael@0 39568 }
michael@0 39569 if (+HEAPF32[i3 + 336 >> 2] == 0.0) {
michael@0 39570 return;
michael@0 39571 }
michael@0 39572 d25 = d27 * +HEAPF32[i3 + 556 >> 2] * (-0.0 - +HEAPF32[i9 >> 2]);
michael@0 39573 d10 = d27 * +HEAPF32[i3 + 560 >> 2] * (-0.0 - +HEAPF32[i12 >> 2]);
michael@0 39574 HEAPF32[i18 >> 2] = +HEAPF32[i18 >> 2] + d27 * +HEAPF32[i3 + 552 >> 2] * (-0.0 - +HEAPF32[i6 >> 2]);
michael@0 39575 HEAPF32[i19 >> 2] = d25 + +HEAPF32[i19 >> 2];
michael@0 39576 HEAPF32[i20 >> 2] = d10 + +HEAPF32[i20 >> 2];
michael@0 39577 d10 = d27 * +HEAPF32[i3 + 540 >> 2] * +HEAPF32[i4 + 68 >> 2];
michael@0 39578 d25 = d27 * +HEAPF32[i3 + 544 >> 2] * +HEAPF32[i4 + 72 >> 2];
michael@0 39579 HEAPF32[i21 >> 2] = d27 * +HEAPF32[i3 + 536 >> 2] * +HEAPF32[i4 + 64 >> 2] + +HEAPF32[i21 >> 2];
michael@0 39580 HEAPF32[i22 >> 2] = d10 + +HEAPF32[i22 >> 2];
michael@0 39581 HEAPF32[i23 >> 2] = d25 + +HEAPF32[i23 >> 2];
michael@0 39582 return;
michael@0 39583 }
michael@0 39584 function __ZN26btBoxBoxCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 39585 i1 = i1 | 0;
michael@0 39586 i2 = i2 | 0;
michael@0 39587 i3 = i3 | 0;
michael@0 39588 i4 = i4 | 0;
michael@0 39589 i5 = i5 | 0;
michael@0 39590 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0;
michael@0 39591 i6 = STACKTOP;
michael@0 39592 STACKTOP = STACKTOP + 152 | 0;
michael@0 39593 i7 = i6 | 0;
michael@0 39594 i8 = i6 + 136 | 0;
michael@0 39595 i9 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 39596 if ((i9 | 0) == 0) {
michael@0 39597 STACKTOP = i6;
michael@0 39598 return;
michael@0 39599 }
michael@0 39600 i10 = HEAP32[i2 + 192 >> 2] | 0;
michael@0 39601 i11 = HEAP32[i3 + 192 >> 2] | 0;
michael@0 39602 i12 = i5 + 4 | 0;
michael@0 39603 HEAP32[i12 >> 2] = i9;
michael@0 39604 HEAP32[i7 + 132 >> 2] = 0;
michael@0 39605 HEAPF32[i7 + 128 >> 2] = 999999984306749400.0;
michael@0 39606 i9 = i7;
michael@0 39607 i13 = i2 + 4 | 0;
michael@0 39608 HEAP32[i9 >> 2] = HEAP32[i13 >> 2];
michael@0 39609 HEAP32[i9 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 39610 HEAP32[i9 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 39611 HEAP32[i9 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 39612 i13 = i7 + 16 | 0;
michael@0 39613 i9 = i2 + 20 | 0;
michael@0 39614 HEAP32[i13 >> 2] = HEAP32[i9 >> 2];
michael@0 39615 HEAP32[i13 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 39616 HEAP32[i13 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 39617 HEAP32[i13 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 39618 i9 = i7 + 32 | 0;
michael@0 39619 i13 = i2 + 36 | 0;
michael@0 39620 HEAP32[i9 >> 2] = HEAP32[i13 >> 2];
michael@0 39621 HEAP32[i9 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 39622 HEAP32[i9 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 39623 HEAP32[i9 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 39624 i13 = i7 + 48 | 0;
michael@0 39625 i9 = i2 + 52 | 0;
michael@0 39626 HEAP32[i13 >> 2] = HEAP32[i9 >> 2];
michael@0 39627 HEAP32[i13 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 39628 HEAP32[i13 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 39629 HEAP32[i13 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 39630 i9 = i7 + 64 | 0;
michael@0 39631 i13 = i3 + 4 | 0;
michael@0 39632 HEAP32[i9 >> 2] = HEAP32[i13 >> 2];
michael@0 39633 HEAP32[i9 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 39634 HEAP32[i9 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 39635 HEAP32[i9 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 39636 i13 = i7 + 80 | 0;
michael@0 39637 i9 = i3 + 20 | 0;
michael@0 39638 HEAP32[i13 >> 2] = HEAP32[i9 >> 2];
michael@0 39639 HEAP32[i13 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 39640 HEAP32[i13 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 39641 HEAP32[i13 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 39642 i9 = i7 + 96 | 0;
michael@0 39643 i13 = i3 + 36 | 0;
michael@0 39644 HEAP32[i9 >> 2] = HEAP32[i13 >> 2];
michael@0 39645 HEAP32[i9 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 39646 HEAP32[i9 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 39647 HEAP32[i9 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 39648 i13 = i7 + 112 | 0;
michael@0 39649 i9 = i3 + 52 | 0;
michael@0 39650 HEAP32[i13 >> 2] = HEAP32[i9 >> 2];
michael@0 39651 HEAP32[i13 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 39652 HEAP32[i13 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 39653 HEAP32[i13 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 39654 __ZN16btBoxBoxDetectorC2EP10btBoxShapeS1_(i8, i10, i11);
michael@0 39655 __ZN16btBoxBoxDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i8, i7, i5 | 0, HEAP32[i4 + 20 >> 2] | 0, 0);
michael@0 39656 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 39657 STACKTOP = i6;
michael@0 39658 return;
michael@0 39659 }
michael@0 39660 i1 = HEAP32[i12 >> 2] | 0;
michael@0 39661 if ((HEAP32[i1 + 1116 >> 2] | 0) == 0) {
michael@0 39662 STACKTOP = i6;
michael@0 39663 return;
michael@0 39664 }
michael@0 39665 if ((HEAP32[i1 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 39666 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 8 | 0, i5 + 72 | 0);
michael@0 39667 STACKTOP = i6;
michael@0 39668 return;
michael@0 39669 } else {
michael@0 39670 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 72 | 0, i5 + 8 | 0);
michael@0 39671 STACKTOP = i6;
michael@0 39672 return;
michael@0 39673 }
michael@0 39674 }
michael@0 39675 function __ZN22btCompoundLeafCallback7ProcessEPK10btDbvtNode(i1, i2) {
michael@0 39676 i1 = i1 | 0;
michael@0 39677 i2 = i2 | 0;
michael@0 39678 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, d31 = 0.0, d32 = 0.0, d33 = 0.0, d34 = 0.0, d35 = 0.0, d36 = 0.0, d37 = 0.0, d38 = 0.0;
michael@0 39679 i3 = STACKTOP;
michael@0 39680 STACKTOP = STACKTOP + 48 | 0;
michael@0 39681 i4 = i3 | 0;
michael@0 39682 i5 = i3 + 16 | 0;
michael@0 39683 i6 = i3 + 32 | 0;
michael@0 39684 i7 = HEAP32[i2 + 36 >> 2] | 0;
michael@0 39685 i8 = i1 + 4 | 0;
michael@0 39686 i9 = HEAP32[(HEAP32[(HEAP32[(HEAP32[i8 >> 2] | 0) + 192 >> 2] | 0) + 24 >> 2] | 0) + (i7 * 80 | 0) + 64 >> 2] | 0;
michael@0 39687 i10 = i1 + 16 | 0;
michael@0 39688 i11 = HEAP32[(HEAP32[i10 >> 2] | 0) + 20 >> 2] | 0;
michael@0 39689 if ((i11 | 0) == 0) {
michael@0 39690 __ZN22btCompoundLeafCallback17ProcessChildShapeEP16btCollisionShapei(i1, i9, i7);
michael@0 39691 STACKTOP = i3;
michael@0 39692 return;
michael@0 39693 }
michael@0 39694 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i11 >> 2] | 0) + 48 >> 2] & 127](i11) | 0) & 2 | 0) == 0) {
michael@0 39695 __ZN22btCompoundLeafCallback17ProcessChildShapeEP16btCollisionShapei(i1, i9, i7);
michael@0 39696 STACKTOP = i3;
michael@0 39697 return;
michael@0 39698 }
michael@0 39699 i11 = HEAP32[i8 >> 2] | 0;
michael@0 39700 d12 = +HEAPF32[i11 + 4 >> 2];
michael@0 39701 d13 = +HEAPF32[i11 + 8 >> 2];
michael@0 39702 d14 = +HEAPF32[i11 + 12 >> 2];
michael@0 39703 d15 = +HEAPF32[i11 + 20 >> 2];
michael@0 39704 d16 = +HEAPF32[i11 + 24 >> 2];
michael@0 39705 d17 = +HEAPF32[i11 + 28 >> 2];
michael@0 39706 d18 = +HEAPF32[i11 + 36 >> 2];
michael@0 39707 d19 = +HEAPF32[i11 + 40 >> 2];
michael@0 39708 d20 = +HEAPF32[i11 + 44 >> 2];
michael@0 39709 d21 = +HEAPF32[i11 + 52 >> 2];
michael@0 39710 d22 = +HEAPF32[i11 + 56 >> 2];
michael@0 39711 d23 = +HEAPF32[i11 + 60 >> 2];
michael@0 39712 d24 = +HEAPF32[i2 + 16 >> 2];
michael@0 39713 d25 = +HEAPF32[i2 >> 2];
michael@0 39714 d26 = +HEAPF32[i2 + 20 >> 2];
michael@0 39715 d27 = +HEAPF32[i2 + 4 >> 2];
michael@0 39716 d28 = +HEAPF32[i2 + 24 >> 2];
michael@0 39717 d29 = +HEAPF32[i2 + 8 >> 2];
michael@0 39718 d30 = (d24 - d25) * .5 + 0.0;
michael@0 39719 d31 = (d26 - d27) * .5 + 0.0;
michael@0 39720 d32 = (d28 - d29) * .5 + 0.0;
michael@0 39721 d33 = (d24 + d25) * .5;
michael@0 39722 d25 = (d26 + d27) * .5;
michael@0 39723 d27 = (d28 + d29) * .5;
michael@0 39724 d29 = +Math_abs(+d12);
michael@0 39725 d28 = +Math_abs(+d13);
michael@0 39726 d26 = +Math_abs(+d14);
michael@0 39727 d24 = +Math_abs(+d15);
michael@0 39728 d34 = +Math_abs(+d16);
michael@0 39729 d35 = +Math_abs(+d17);
michael@0 39730 d36 = +Math_abs(+d18);
michael@0 39731 d37 = +Math_abs(+d19);
michael@0 39732 d38 = d21 + (d12 * d33 + d13 * d25 + d14 * d27);
michael@0 39733 d14 = d22 + (d15 * d33 + d16 * d25 + d17 * d27);
michael@0 39734 d17 = d23 + (d18 * d33 + d19 * d25 + d20 * d27);
michael@0 39735 d27 = d30 * d29 + d31 * d28 + d32 * d26;
michael@0 39736 d26 = d30 * d24 + d31 * d34 + d32 * d35;
michael@0 39737 d35 = d30 * d36 + d31 * d37 + d32 * +Math_abs(+d20);
michael@0 39738 HEAPF32[i4 >> 2] = d38 - d27;
michael@0 39739 HEAPF32[i4 + 4 >> 2] = d14 - d26;
michael@0 39740 HEAPF32[i4 + 8 >> 2] = d17 - d35;
michael@0 39741 HEAPF32[i4 + 12 >> 2] = 0.0;
michael@0 39742 HEAPF32[i5 >> 2] = d27 + d38;
michael@0 39743 HEAPF32[i5 + 4 >> 2] = d14 + d26;
michael@0 39744 HEAPF32[i5 + 8 >> 2] = d17 + d35;
michael@0 39745 HEAPF32[i5 + 12 >> 2] = 0.0;
michael@0 39746 i2 = HEAP32[(HEAP32[i10 >> 2] | 0) + 20 >> 2] | 0;
michael@0 39747 i10 = HEAP32[(HEAP32[i2 >> 2] | 0) + 52 >> 2] | 0;
michael@0 39748 HEAPF32[i6 >> 2] = 1.0;
michael@0 39749 HEAPF32[i6 + 4 >> 2] = 0.0;
michael@0 39750 HEAPF32[i6 + 8 >> 2] = 0.0;
michael@0 39751 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 39752 FUNCTION_TABLE_viiii[i10 & 127](i2, i4, i5, i6);
michael@0 39753 __ZN22btCompoundLeafCallback17ProcessChildShapeEP16btCollisionShapei(i1, i9, i7);
michael@0 39754 STACKTOP = i3;
michael@0 39755 return;
michael@0 39756 }
michael@0 39757 function __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeE10growTablesERKS0_(i1, i2) {
michael@0 39758 i1 = i1 | 0;
michael@0 39759 i2 = i2 | 0;
michael@0 39760 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 39761 i2 = i1 + 48 | 0;
michael@0 39762 i3 = HEAP32[i2 >> 2] | 0;
michael@0 39763 i4 = i1 + 4 | 0;
michael@0 39764 i5 = HEAP32[i4 >> 2] | 0;
michael@0 39765 if ((i5 | 0) >= (i3 | 0)) {
michael@0 39766 return;
michael@0 39767 }
michael@0 39768 if ((i5 | 0) <= (i3 | 0)) {
michael@0 39769 i6 = i1 + 8 | 0;
michael@0 39770 if ((HEAP32[i6 >> 2] | 0) < (i3 | 0)) {
michael@0 39771 if ((i3 | 0) == 0) {
michael@0 39772 i7 = 0;
michael@0 39773 i8 = i5;
michael@0 39774 } else {
michael@0 39775 i9 = __Z22btAlignedAllocInternalji(i3 << 2, 16) | 0;
michael@0 39776 i7 = i9;
michael@0 39777 i8 = HEAP32[i4 >> 2] | 0;
michael@0 39778 }
michael@0 39779 i9 = i1 + 12 | 0;
michael@0 39780 if ((i8 | 0) > 0) {
michael@0 39781 i10 = 0;
michael@0 39782 do {
michael@0 39783 i11 = i7 + (i10 << 2) | 0;
michael@0 39784 if ((i11 | 0) != 0) {
michael@0 39785 HEAP32[i11 >> 2] = HEAP32[(HEAP32[i9 >> 2] | 0) + (i10 << 2) >> 2];
michael@0 39786 }
michael@0 39787 i10 = i10 + 1 | 0;
michael@0 39788 } while ((i10 | 0) < (i8 | 0));
michael@0 39789 }
michael@0 39790 i8 = HEAP32[i9 >> 2] | 0;
michael@0 39791 i10 = i1 + 16 | 0;
michael@0 39792 if ((i8 | 0) != 0) {
michael@0 39793 if ((HEAP8[i10] | 0) != 0) {
michael@0 39794 __Z21btAlignedFreeInternalPv(i8);
michael@0 39795 }
michael@0 39796 HEAP32[i9 >> 2] = 0;
michael@0 39797 }
michael@0 39798 HEAP8[i10] = 1;
michael@0 39799 HEAP32[i9 >> 2] = i7;
michael@0 39800 HEAP32[i6 >> 2] = i3;
michael@0 39801 i12 = i7;
michael@0 39802 } else {
michael@0 39803 i12 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 39804 }
michael@0 39805 i7 = i5;
michael@0 39806 do {
michael@0 39807 i6 = i12 + (i7 << 2) | 0;
michael@0 39808 if ((i6 | 0) != 0) {
michael@0 39809 HEAP32[i6 >> 2] = 0;
michael@0 39810 }
michael@0 39811 i7 = i7 + 1 | 0;
michael@0 39812 } while ((i7 | 0) < (i3 | 0));
michael@0 39813 }
michael@0 39814 HEAP32[i4 >> 2] = i3;
michael@0 39815 i4 = i1 + 24 | 0;
michael@0 39816 i7 = HEAP32[i4 >> 2] | 0;
michael@0 39817 if ((i7 | 0) < (i3 | 0)) {
michael@0 39818 i12 = i1 + 28 | 0;
michael@0 39819 if ((HEAP32[i12 >> 2] | 0) < (i3 | 0)) {
michael@0 39820 if ((i3 | 0) == 0) {
michael@0 39821 i13 = 0;
michael@0 39822 i14 = i7;
michael@0 39823 } else {
michael@0 39824 i6 = __Z22btAlignedAllocInternalji(i3 << 2, 16) | 0;
michael@0 39825 i13 = i6;
michael@0 39826 i14 = HEAP32[i4 >> 2] | 0;
michael@0 39827 }
michael@0 39828 i6 = i1 + 32 | 0;
michael@0 39829 if ((i14 | 0) > 0) {
michael@0 39830 i9 = 0;
michael@0 39831 do {
michael@0 39832 i10 = i13 + (i9 << 2) | 0;
michael@0 39833 if ((i10 | 0) != 0) {
michael@0 39834 HEAP32[i10 >> 2] = HEAP32[(HEAP32[i6 >> 2] | 0) + (i9 << 2) >> 2];
michael@0 39835 }
michael@0 39836 i9 = i9 + 1 | 0;
michael@0 39837 } while ((i9 | 0) < (i14 | 0));
michael@0 39838 }
michael@0 39839 i14 = HEAP32[i6 >> 2] | 0;
michael@0 39840 i9 = i1 + 36 | 0;
michael@0 39841 if ((i14 | 0) != 0) {
michael@0 39842 if ((HEAP8[i9] | 0) != 0) {
michael@0 39843 __Z21btAlignedFreeInternalPv(i14);
michael@0 39844 }
michael@0 39845 HEAP32[i6 >> 2] = 0;
michael@0 39846 }
michael@0 39847 HEAP8[i9] = 1;
michael@0 39848 HEAP32[i6 >> 2] = i13;
michael@0 39849 HEAP32[i12 >> 2] = i3;
michael@0 39850 i15 = i13;
michael@0 39851 } else {
michael@0 39852 i15 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 39853 }
michael@0 39854 i13 = i7;
michael@0 39855 do {
michael@0 39856 i7 = i15 + (i13 << 2) | 0;
michael@0 39857 if ((i7 | 0) != 0) {
michael@0 39858 HEAP32[i7 >> 2] = 0;
michael@0 39859 }
michael@0 39860 i13 = i13 + 1 | 0;
michael@0 39861 } while ((i13 | 0) < (i3 | 0));
michael@0 39862 }
michael@0 39863 HEAP32[i4 >> 2] = i3;
michael@0 39864 if ((i3 | 0) > 0) {
michael@0 39865 i4 = i3 << 2;
michael@0 39866 _memset(HEAP32[i1 + 12 >> 2] | 0, -1 | 0, i4 | 0);
michael@0 39867 _memset(HEAP32[i1 + 32 >> 2] | 0, -1 | 0, i4 | 0);
michael@0 39868 }
michael@0 39869 if ((i5 | 0) <= 0) {
michael@0 39870 return;
michael@0 39871 }
michael@0 39872 i4 = HEAP32[i1 + 72 >> 2] | 0;
michael@0 39873 i3 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 39874 i13 = HEAP32[i1 + 32 >> 2] | 0;
michael@0 39875 i1 = 0;
michael@0 39876 do {
michael@0 39877 i15 = i3 + (((HEAPU16[i4 + (i1 << 2) + 2 >> 1] << 16) + (HEAP16[i4 + (i1 << 2) >> 1] | 0) & (HEAP32[i2 >> 2] | 0) - 1) << 2) | 0;
michael@0 39878 HEAP32[i13 + (i1 << 2) >> 2] = HEAP32[i15 >> 2];
michael@0 39879 HEAP32[i15 >> 2] = i1;
michael@0 39880 i1 = i1 + 1 | 0;
michael@0 39881 } while ((i1 | 0) < (i5 | 0));
michael@0 39882 return;
michael@0 39883 }
michael@0 39884 function __ZN35btSequentialImpulseConstraintSolver43resolveSplitPenetrationImpulseCacheFriendlyER11btRigidBodyS1_RK18btSolverConstraint(i1, i2, i3, i4) {
michael@0 39885 i1 = i1 | 0;
michael@0 39886 i2 = i2 | 0;
michael@0 39887 i3 = i3 | 0;
michael@0 39888 i4 = i4 | 0;
michael@0 39889 var d5 = 0.0, d6 = 0.0, i7 = 0, d8 = 0.0, i9 = 0, i10 = 0, d11 = 0.0, i12 = 0, i13 = 0, d14 = 0.0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0;
michael@0 39890 d5 = +HEAPF32[i4 + 132 >> 2];
michael@0 39891 if (d5 == 0.0) {
michael@0 39892 return;
michael@0 39893 }
michael@0 39894 HEAP32[2988] = (HEAP32[2988] | 0) + 1;
michael@0 39895 i1 = i4 + 80 | 0;
michael@0 39896 d6 = +HEAPF32[i1 >> 2];
michael@0 39897 i7 = i4 + 16 | 0;
michael@0 39898 d8 = +HEAPF32[i7 >> 2];
michael@0 39899 i9 = i2 + 568 | 0;
michael@0 39900 i10 = i4 + 20 | 0;
michael@0 39901 d11 = +HEAPF32[i10 >> 2];
michael@0 39902 i12 = i2 + 572 | 0;
michael@0 39903 i13 = i4 + 24 | 0;
michael@0 39904 d14 = +HEAPF32[i13 >> 2];
michael@0 39905 i15 = i2 + 576 | 0;
michael@0 39906 i16 = i2 + 584 | 0;
michael@0 39907 i17 = i2 + 588 | 0;
michael@0 39908 i18 = i2 + 592 | 0;
michael@0 39909 i19 = i3 + 568 | 0;
michael@0 39910 i20 = i3 + 572 | 0;
michael@0 39911 i21 = i3 + 576 | 0;
michael@0 39912 i22 = i3 + 584 | 0;
michael@0 39913 i23 = i3 + 588 | 0;
michael@0 39914 i24 = i3 + 592 | 0;
michael@0 39915 d25 = +HEAPF32[i4 + 92 >> 2];
michael@0 39916 d26 = d5 - d6 * +HEAPF32[i4 + 120 >> 2] - (d8 * +HEAPF32[i9 >> 2] + d11 * +HEAPF32[i12 >> 2] + d14 * +HEAPF32[i15 >> 2] + (+HEAPF32[i4 >> 2] * +HEAPF32[i16 >> 2] + +HEAPF32[i4 + 4 >> 2] * +HEAPF32[i17 >> 2] + +HEAPF32[i4 + 8 >> 2] * +HEAPF32[i18 >> 2])) * d25 - d25 * (+HEAPF32[i4 + 32 >> 2] * +HEAPF32[i22 >> 2] + +HEAPF32[i4 + 36 >> 2] * +HEAPF32[i23 >> 2] + +HEAPF32[i4 + 40 >> 2] * +HEAPF32[i24 >> 2] - (d8 * +HEAPF32[i19 >> 2] + d11 * +HEAPF32[i20 >> 2] + d14 * +HEAPF32[i21 >> 2]));
michael@0 39917 d25 = d6 + d26;
michael@0 39918 d5 = +HEAPF32[i4 + 124 >> 2];
michael@0 39919 if (d25 < d5) {
michael@0 39920 d27 = d5 - d6;
michael@0 39921 d28 = d5;
michael@0 39922 } else {
michael@0 39923 d27 = d26;
michael@0 39924 d28 = d25;
michael@0 39925 }
michael@0 39926 HEAPF32[i1 >> 2] = d28;
michael@0 39927 if (+HEAPF32[i2 + 336 >> 2] != 0.0) {
michael@0 39928 d28 = d27 * d11 * +HEAPF32[i2 + 556 >> 2];
michael@0 39929 d11 = d27 * d14 * +HEAPF32[i2 + 560 >> 2];
michael@0 39930 HEAPF32[i9 >> 2] = +HEAPF32[i9 >> 2] + d27 * d8 * +HEAPF32[i2 + 552 >> 2];
michael@0 39931 HEAPF32[i12 >> 2] = d28 + +HEAPF32[i12 >> 2];
michael@0 39932 HEAPF32[i15 >> 2] = d11 + +HEAPF32[i15 >> 2];
michael@0 39933 d11 = d27 * +HEAPF32[i2 + 540 >> 2] * +HEAPF32[i4 + 52 >> 2];
michael@0 39934 d28 = d27 * +HEAPF32[i2 + 544 >> 2] * +HEAPF32[i4 + 56 >> 2];
michael@0 39935 HEAPF32[i16 >> 2] = d27 * +HEAPF32[i2 + 536 >> 2] * +HEAPF32[i4 + 48 >> 2] + +HEAPF32[i16 >> 2];
michael@0 39936 HEAPF32[i17 >> 2] = d11 + +HEAPF32[i17 >> 2];
michael@0 39937 HEAPF32[i18 >> 2] = d28 + +HEAPF32[i18 >> 2];
michael@0 39938 }
michael@0 39939 if (+HEAPF32[i3 + 336 >> 2] == 0.0) {
michael@0 39940 return;
michael@0 39941 }
michael@0 39942 d28 = d27 * +HEAPF32[i3 + 556 >> 2] * (-0.0 - +HEAPF32[i10 >> 2]);
michael@0 39943 d11 = d27 * +HEAPF32[i3 + 560 >> 2] * (-0.0 - +HEAPF32[i13 >> 2]);
michael@0 39944 HEAPF32[i19 >> 2] = +HEAPF32[i19 >> 2] + d27 * +HEAPF32[i3 + 552 >> 2] * (-0.0 - +HEAPF32[i7 >> 2]);
michael@0 39945 HEAPF32[i20 >> 2] = d28 + +HEAPF32[i20 >> 2];
michael@0 39946 HEAPF32[i21 >> 2] = d11 + +HEAPF32[i21 >> 2];
michael@0 39947 d11 = d27 * +HEAPF32[i3 + 540 >> 2] * +HEAPF32[i4 + 68 >> 2];
michael@0 39948 d28 = d27 * +HEAPF32[i3 + 544 >> 2] * +HEAPF32[i4 + 72 >> 2];
michael@0 39949 HEAPF32[i22 >> 2] = d27 * +HEAPF32[i3 + 536 >> 2] * +HEAPF32[i4 + 64 >> 2] + +HEAPF32[i22 >> 2];
michael@0 39950 HEAPF32[i23 >> 2] = d11 + +HEAPF32[i23 >> 2];
michael@0 39951 HEAPF32[i24 >> 2] = d28 + +HEAPF32[i24 >> 2];
michael@0 39952 return;
michael@0 39953 }
michael@0 39954 function __ZN24btConvexTriangleCallback22setTimeStepAndCountersEfRK16btDispatcherInfoP16btManifoldResult(i1, d2, i3, i4) {
michael@0 39955 i1 = i1 | 0;
michael@0 39956 d2 = +d2;
michael@0 39957 i3 = i3 | 0;
michael@0 39958 i4 = i4 | 0;
michael@0 39959 var i5 = 0, i6 = 0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0, d30 = 0.0, i31 = 0;
michael@0 39960 i5 = STACKTOP;
michael@0 39961 STACKTOP = STACKTOP + 64 | 0;
michael@0 39962 i6 = i5 | 0;
michael@0 39963 HEAP32[i1 + 52 >> 2] = i3;
michael@0 39964 HEAPF32[i1 + 56 >> 2] = d2;
michael@0 39965 HEAP32[i1 + 44 >> 2] = i4;
michael@0 39966 i4 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 39967 d7 = +HEAPF32[i4 + 4 >> 2];
michael@0 39968 d8 = +HEAPF32[i4 + 20 >> 2];
michael@0 39969 d9 = +HEAPF32[i4 + 36 >> 2];
michael@0 39970 d10 = +HEAPF32[i4 + 8 >> 2];
michael@0 39971 d11 = +HEAPF32[i4 + 24 >> 2];
michael@0 39972 d12 = +HEAPF32[i4 + 40 >> 2];
michael@0 39973 d13 = +HEAPF32[i4 + 12 >> 2];
michael@0 39974 d14 = +HEAPF32[i4 + 28 >> 2];
michael@0 39975 d15 = +HEAPF32[i4 + 44 >> 2];
michael@0 39976 d16 = -0.0 - +HEAPF32[i4 + 52 >> 2];
michael@0 39977 d17 = -0.0 - +HEAPF32[i4 + 56 >> 2];
michael@0 39978 d18 = -0.0 - +HEAPF32[i4 + 60 >> 2];
michael@0 39979 i4 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 39980 d19 = +HEAPF32[i4 + 4 >> 2];
michael@0 39981 d20 = +HEAPF32[i4 + 20 >> 2];
michael@0 39982 d21 = +HEAPF32[i4 + 36 >> 2];
michael@0 39983 d22 = +HEAPF32[i4 + 8 >> 2];
michael@0 39984 d23 = +HEAPF32[i4 + 24 >> 2];
michael@0 39985 d24 = +HEAPF32[i4 + 40 >> 2];
michael@0 39986 d25 = +HEAPF32[i4 + 12 >> 2];
michael@0 39987 d26 = +HEAPF32[i4 + 28 >> 2];
michael@0 39988 d27 = +HEAPF32[i4 + 44 >> 2];
michael@0 39989 d28 = +HEAPF32[i4 + 52 >> 2];
michael@0 39990 d29 = +HEAPF32[i4 + 56 >> 2];
michael@0 39991 d30 = +HEAPF32[i4 + 60 >> 2];
michael@0 39992 HEAPF32[i6 >> 2] = d7 * d19 + d8 * d20 + d9 * d21;
michael@0 39993 HEAPF32[i6 + 4 >> 2] = d7 * d22 + d8 * d23 + d9 * d24;
michael@0 39994 HEAPF32[i6 + 8 >> 2] = d7 * d25 + d8 * d26 + d9 * d27;
michael@0 39995 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 39996 HEAPF32[i6 + 16 >> 2] = d10 * d19 + d11 * d20 + d12 * d21;
michael@0 39997 HEAPF32[i6 + 20 >> 2] = d10 * d22 + d11 * d23 + d12 * d24;
michael@0 39998 HEAPF32[i6 + 24 >> 2] = d10 * d25 + d11 * d26 + d12 * d27;
michael@0 39999 HEAPF32[i6 + 28 >> 2] = 0.0;
michael@0 40000 HEAPF32[i6 + 32 >> 2] = d13 * d19 + d14 * d20 + d15 * d21;
michael@0 40001 HEAPF32[i6 + 36 >> 2] = d13 * d22 + d14 * d23 + d15 * d24;
michael@0 40002 HEAPF32[i6 + 40 >> 2] = d13 * d25 + d14 * d26 + d15 * d27;
michael@0 40003 HEAPF32[i6 + 44 >> 2] = 0.0;
michael@0 40004 HEAPF32[i6 + 48 >> 2] = d7 * d16 + d8 * d17 + d9 * d18 + (d7 * d28 + d8 * d29 + d9 * d30);
michael@0 40005 HEAPF32[i6 + 52 >> 2] = d10 * d16 + d11 * d17 + d12 * d18 + (d10 * d28 + d11 * d29 + d12 * d30);
michael@0 40006 HEAPF32[i6 + 56 >> 2] = d13 * d16 + d14 * d17 + d15 * d18 + (d13 * d28 + d14 * d29 + d15 * d30);
michael@0 40007 HEAPF32[i6 + 60 >> 2] = 0.0;
michael@0 40008 i3 = HEAP32[i4 + 192 >> 2] | 0;
michael@0 40009 i4 = i1 + 12 | 0;
michael@0 40010 i31 = i1 + 28 | 0;
michael@0 40011 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i3 >> 2] | 0) + 8 >> 2] & 127](i3, i6, i4, i31);
michael@0 40012 i6 = i31 | 0;
michael@0 40013 HEAPF32[i6 >> 2] = +HEAPF32[i6 >> 2] + d2;
michael@0 40014 i6 = i1 + 32 | 0;
michael@0 40015 HEAPF32[i6 >> 2] = +HEAPF32[i6 >> 2] + d2;
michael@0 40016 i6 = i1 + 36 | 0;
michael@0 40017 HEAPF32[i6 >> 2] = +HEAPF32[i6 >> 2] + d2;
michael@0 40018 i6 = i4 | 0;
michael@0 40019 HEAPF32[i6 >> 2] = +HEAPF32[i6 >> 2] - d2;
michael@0 40020 i6 = i1 + 16 | 0;
michael@0 40021 HEAPF32[i6 >> 2] = +HEAPF32[i6 >> 2] - d2;
michael@0 40022 i6 = i1 + 20 | 0;
michael@0 40023 HEAPF32[i6 >> 2] = +HEAPF32[i6 >> 2] - d2;
michael@0 40024 STACKTOP = i5;
michael@0 40025 return;
michael@0 40026 }
michael@0 40027 function __ZN35btSequentialImpulseConstraintSolver36resolveSingleConstraintRowLowerLimitER11btRigidBodyS1_RK18btSolverConstraint(i1, i2, i3, i4) {
michael@0 40028 i1 = i1 | 0;
michael@0 40029 i2 = i2 | 0;
michael@0 40030 i3 = i3 | 0;
michael@0 40031 i4 = i4 | 0;
michael@0 40032 var d5 = 0.0, i6 = 0, d7 = 0.0, i8 = 0, i9 = 0, d10 = 0.0, i11 = 0, i12 = 0, d13 = 0.0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0;
michael@0 40033 i1 = i4 + 84 | 0;
michael@0 40034 d5 = +HEAPF32[i1 >> 2];
michael@0 40035 i6 = i4 + 16 | 0;
michael@0 40036 d7 = +HEAPF32[i6 >> 2];
michael@0 40037 i8 = i2 + 504 | 0;
michael@0 40038 i9 = i4 + 20 | 0;
michael@0 40039 d10 = +HEAPF32[i9 >> 2];
michael@0 40040 i11 = i2 + 508 | 0;
michael@0 40041 i12 = i4 + 24 | 0;
michael@0 40042 d13 = +HEAPF32[i12 >> 2];
michael@0 40043 i14 = i2 + 512 | 0;
michael@0 40044 i15 = i2 + 520 | 0;
michael@0 40045 i16 = i2 + 524 | 0;
michael@0 40046 i17 = i2 + 528 | 0;
michael@0 40047 i18 = i3 + 504 | 0;
michael@0 40048 i19 = i3 + 508 | 0;
michael@0 40049 i20 = i3 + 512 | 0;
michael@0 40050 i21 = i3 + 520 | 0;
michael@0 40051 i22 = i3 + 524 | 0;
michael@0 40052 i23 = i3 + 528 | 0;
michael@0 40053 d24 = +HEAPF32[i4 + 92 >> 2];
michael@0 40054 d25 = +HEAPF32[i4 + 116 >> 2] - d5 * +HEAPF32[i4 + 120 >> 2] - (d7 * +HEAPF32[i8 >> 2] + d10 * +HEAPF32[i11 >> 2] + d13 * +HEAPF32[i14 >> 2] + (+HEAPF32[i4 >> 2] * +HEAPF32[i15 >> 2] + +HEAPF32[i4 + 4 >> 2] * +HEAPF32[i16 >> 2] + +HEAPF32[i4 + 8 >> 2] * +HEAPF32[i17 >> 2])) * d24 - d24 * (+HEAPF32[i4 + 32 >> 2] * +HEAPF32[i21 >> 2] + +HEAPF32[i4 + 36 >> 2] * +HEAPF32[i22 >> 2] + +HEAPF32[i4 + 40 >> 2] * +HEAPF32[i23 >> 2] - (d7 * +HEAPF32[i18 >> 2] + d10 * +HEAPF32[i19 >> 2] + d13 * +HEAPF32[i20 >> 2]));
michael@0 40055 d24 = d5 + d25;
michael@0 40056 d26 = +HEAPF32[i4 + 124 >> 2];
michael@0 40057 if (d24 < d26) {
michael@0 40058 d27 = d26 - d5;
michael@0 40059 d28 = d26;
michael@0 40060 } else {
michael@0 40061 d27 = d25;
michael@0 40062 d28 = d24;
michael@0 40063 }
michael@0 40064 HEAPF32[i1 >> 2] = d28;
michael@0 40065 if (+HEAPF32[i2 + 336 >> 2] != 0.0) {
michael@0 40066 d28 = d27 * d10 * +HEAPF32[i2 + 556 >> 2];
michael@0 40067 d10 = d27 * d13 * +HEAPF32[i2 + 560 >> 2];
michael@0 40068 HEAPF32[i8 >> 2] = +HEAPF32[i8 >> 2] + d27 * d7 * +HEAPF32[i2 + 552 >> 2];
michael@0 40069 HEAPF32[i11 >> 2] = d28 + +HEAPF32[i11 >> 2];
michael@0 40070 HEAPF32[i14 >> 2] = d10 + +HEAPF32[i14 >> 2];
michael@0 40071 d10 = d27 * +HEAPF32[i2 + 540 >> 2] * +HEAPF32[i4 + 52 >> 2];
michael@0 40072 d28 = d27 * +HEAPF32[i2 + 544 >> 2] * +HEAPF32[i4 + 56 >> 2];
michael@0 40073 HEAPF32[i15 >> 2] = d27 * +HEAPF32[i2 + 536 >> 2] * +HEAPF32[i4 + 48 >> 2] + +HEAPF32[i15 >> 2];
michael@0 40074 HEAPF32[i16 >> 2] = d10 + +HEAPF32[i16 >> 2];
michael@0 40075 HEAPF32[i17 >> 2] = d28 + +HEAPF32[i17 >> 2];
michael@0 40076 }
michael@0 40077 if (+HEAPF32[i3 + 336 >> 2] == 0.0) {
michael@0 40078 return;
michael@0 40079 }
michael@0 40080 d28 = d27 * +HEAPF32[i3 + 556 >> 2] * (-0.0 - +HEAPF32[i9 >> 2]);
michael@0 40081 d10 = d27 * +HEAPF32[i3 + 560 >> 2] * (-0.0 - +HEAPF32[i12 >> 2]);
michael@0 40082 HEAPF32[i18 >> 2] = +HEAPF32[i18 >> 2] + d27 * +HEAPF32[i3 + 552 >> 2] * (-0.0 - +HEAPF32[i6 >> 2]);
michael@0 40083 HEAPF32[i19 >> 2] = d28 + +HEAPF32[i19 >> 2];
michael@0 40084 HEAPF32[i20 >> 2] = d10 + +HEAPF32[i20 >> 2];
michael@0 40085 d10 = d27 * +HEAPF32[i3 + 540 >> 2] * +HEAPF32[i4 + 68 >> 2];
michael@0 40086 d28 = d27 * +HEAPF32[i3 + 544 >> 2] * +HEAPF32[i4 + 72 >> 2];
michael@0 40087 HEAPF32[i21 >> 2] = d27 * +HEAPF32[i3 + 536 >> 2] * +HEAPF32[i4 + 64 >> 2] + +HEAPF32[i21 >> 2];
michael@0 40088 HEAPF32[i22 >> 2] = d10 + +HEAPF32[i22 >> 2];
michael@0 40089 HEAPF32[i23 >> 2] = d28 + +HEAPF32[i23 >> 2];
michael@0 40090 return;
michael@0 40091 }
michael@0 40092 function __ZN16btCollisionWorld18addCollisionObjectEP17btCollisionObjectss(i1, i2, i3, i4) {
michael@0 40093 i1 = i1 | 0;
michael@0 40094 i2 = i2 | 0;
michael@0 40095 i3 = i3 | 0;
michael@0 40096 i4 = i4 | 0;
michael@0 40097 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0;
michael@0 40098 i5 = STACKTOP;
michael@0 40099 STACKTOP = STACKTOP + 96 | 0;
michael@0 40100 i6 = i5 | 0;
michael@0 40101 i7 = i5 + 64 | 0;
michael@0 40102 i8 = i5 + 80 | 0;
michael@0 40103 i9 = i1 + 8 | 0;
michael@0 40104 i10 = HEAP32[i9 >> 2] | 0;
michael@0 40105 i11 = i1 + 12 | 0;
michael@0 40106 do {
michael@0 40107 if ((i10 | 0) == (HEAP32[i11 >> 2] | 0)) {
michael@0 40108 i12 = (i10 | 0) == 0 ? 1 : i10 << 1;
michael@0 40109 if ((i10 | 0) >= (i12 | 0)) {
michael@0 40110 i13 = i10;
michael@0 40111 break;
michael@0 40112 }
michael@0 40113 if ((i12 | 0) == 0) {
michael@0 40114 i14 = 0;
michael@0 40115 i15 = i10;
michael@0 40116 } else {
michael@0 40117 i16 = __Z22btAlignedAllocInternalji(i12 << 2, 16) | 0;
michael@0 40118 i14 = i16;
michael@0 40119 i15 = HEAP32[i9 >> 2] | 0;
michael@0 40120 }
michael@0 40121 i16 = i1 + 16 | 0;
michael@0 40122 if ((i15 | 0) > 0) {
michael@0 40123 i17 = 0;
michael@0 40124 do {
michael@0 40125 i18 = i14 + (i17 << 2) | 0;
michael@0 40126 if ((i18 | 0) != 0) {
michael@0 40127 HEAP32[i18 >> 2] = HEAP32[(HEAP32[i16 >> 2] | 0) + (i17 << 2) >> 2];
michael@0 40128 }
michael@0 40129 i17 = i17 + 1 | 0;
michael@0 40130 } while ((i17 | 0) < (i15 | 0));
michael@0 40131 }
michael@0 40132 i17 = HEAP32[i16 >> 2] | 0;
michael@0 40133 i18 = i1 + 20 | 0;
michael@0 40134 if ((i17 | 0) == 0) {
michael@0 40135 i19 = i15;
michael@0 40136 } else {
michael@0 40137 if ((HEAP8[i18] | 0) == 0) {
michael@0 40138 i20 = i15;
michael@0 40139 } else {
michael@0 40140 __Z21btAlignedFreeInternalPv(i17);
michael@0 40141 i20 = HEAP32[i9 >> 2] | 0;
michael@0 40142 }
michael@0 40143 HEAP32[i16 >> 2] = 0;
michael@0 40144 i19 = i20;
michael@0 40145 }
michael@0 40146 HEAP8[i18] = 1;
michael@0 40147 HEAP32[i16 >> 2] = i14;
michael@0 40148 HEAP32[i11 >> 2] = i12;
michael@0 40149 i13 = i19;
michael@0 40150 } else {
michael@0 40151 i13 = i10;
michael@0 40152 }
michael@0 40153 } while (0);
michael@0 40154 i10 = (HEAP32[i1 + 16 >> 2] | 0) + (i13 << 2) | 0;
michael@0 40155 if ((i10 | 0) != 0) {
michael@0 40156 HEAP32[i10 >> 2] = i2;
michael@0 40157 }
michael@0 40158 HEAP32[i9 >> 2] = i13 + 1;
michael@0 40159 i13 = i6;
michael@0 40160 i9 = i2 + 4 | 0;
michael@0 40161 HEAP32[i13 >> 2] = HEAP32[i9 >> 2];
michael@0 40162 HEAP32[i13 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 40163 HEAP32[i13 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 40164 HEAP32[i13 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 40165 i9 = i6 + 16 | 0;
michael@0 40166 i13 = i2 + 20 | 0;
michael@0 40167 HEAP32[i9 >> 2] = HEAP32[i13 >> 2];
michael@0 40168 HEAP32[i9 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 40169 HEAP32[i9 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 40170 HEAP32[i9 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 40171 i13 = i6 + 32 | 0;
michael@0 40172 i9 = i2 + 36 | 0;
michael@0 40173 HEAP32[i13 >> 2] = HEAP32[i9 >> 2];
michael@0 40174 HEAP32[i13 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 40175 HEAP32[i13 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 40176 HEAP32[i13 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 40177 i9 = i6 + 48 | 0;
michael@0 40178 i13 = i2 + 52 | 0;
michael@0 40179 HEAP32[i9 >> 2] = HEAP32[i13 >> 2];
michael@0 40180 HEAP32[i9 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 40181 HEAP32[i9 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 40182 HEAP32[i9 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 40183 i13 = i2 + 192 | 0;
michael@0 40184 i9 = HEAP32[i13 >> 2] | 0;
michael@0 40185 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i9 >> 2] | 0) + 8 >> 2] & 127](i9, i6, i7, i8);
michael@0 40186 i6 = HEAP32[i1 + 76 >> 2] | 0;
michael@0 40187 HEAP32[i2 + 188 >> 2] = FUNCTION_TABLE_iiiiiiiiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 3](i6, i7, i8, HEAP32[(HEAP32[i13 >> 2] | 0) + 4 >> 2] | 0, i2, i3, i4, HEAP32[i1 + 24 >> 2] | 0, 0) | 0;
michael@0 40188 STACKTOP = i5;
michael@0 40189 return;
michael@0 40190 }
michael@0 40191 function __ZN28btTriangleConvexcastCallbackC2EPK13btConvexShapeRK11btTransformS5_S5_f(i1, i2, i3, i4, i5, d6) {
michael@0 40192 i1 = i1 | 0;
michael@0 40193 i2 = i2 | 0;
michael@0 40194 i3 = i3 | 0;
michael@0 40195 i4 = i4 | 0;
michael@0 40196 i5 = i5 | 0;
michael@0 40197 d6 = +d6;
michael@0 40198 var i7 = 0;
michael@0 40199 HEAP32[i1 >> 2] = 2768;
michael@0 40200 HEAP32[i1 + 4 >> 2] = i2;
michael@0 40201 i2 = i1 + 8 | 0;
michael@0 40202 i7 = i3;
michael@0 40203 HEAP32[i2 >> 2] = HEAP32[i7 >> 2];
michael@0 40204 HEAP32[i2 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 40205 HEAP32[i2 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 40206 HEAP32[i2 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 40207 i7 = i1 + 24 | 0;
michael@0 40208 i2 = i3 + 16 | 0;
michael@0 40209 HEAP32[i7 >> 2] = HEAP32[i2 >> 2];
michael@0 40210 HEAP32[i7 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 40211 HEAP32[i7 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 40212 HEAP32[i7 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 40213 i2 = i1 + 40 | 0;
michael@0 40214 i7 = i3 + 32 | 0;
michael@0 40215 HEAP32[i2 >> 2] = HEAP32[i7 >> 2];
michael@0 40216 HEAP32[i2 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 40217 HEAP32[i2 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 40218 HEAP32[i2 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 40219 i7 = i1 + 56 | 0;
michael@0 40220 i2 = i3 + 48 | 0;
michael@0 40221 HEAP32[i7 >> 2] = HEAP32[i2 >> 2];
michael@0 40222 HEAP32[i7 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 40223 HEAP32[i7 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 40224 HEAP32[i7 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 40225 i2 = i1 + 72 | 0;
michael@0 40226 i7 = i4;
michael@0 40227 HEAP32[i2 >> 2] = HEAP32[i7 >> 2];
michael@0 40228 HEAP32[i2 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 40229 HEAP32[i2 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 40230 HEAP32[i2 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 40231 i7 = i1 + 88 | 0;
michael@0 40232 i2 = i4 + 16 | 0;
michael@0 40233 HEAP32[i7 >> 2] = HEAP32[i2 >> 2];
michael@0 40234 HEAP32[i7 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 40235 HEAP32[i7 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 40236 HEAP32[i7 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 40237 i2 = i1 + 104 | 0;
michael@0 40238 i7 = i4 + 32 | 0;
michael@0 40239 HEAP32[i2 >> 2] = HEAP32[i7 >> 2];
michael@0 40240 HEAP32[i2 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 40241 HEAP32[i2 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 40242 HEAP32[i2 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 40243 i7 = i1 + 120 | 0;
michael@0 40244 i2 = i4 + 48 | 0;
michael@0 40245 HEAP32[i7 >> 2] = HEAP32[i2 >> 2];
michael@0 40246 HEAP32[i7 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 40247 HEAP32[i7 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 40248 HEAP32[i7 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 40249 i2 = i1 + 136 | 0;
michael@0 40250 i7 = i5;
michael@0 40251 HEAP32[i2 >> 2] = HEAP32[i7 >> 2];
michael@0 40252 HEAP32[i2 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 40253 HEAP32[i2 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 40254 HEAP32[i2 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 40255 i7 = i1 + 152 | 0;
michael@0 40256 i2 = i5 + 16 | 0;
michael@0 40257 HEAP32[i7 >> 2] = HEAP32[i2 >> 2];
michael@0 40258 HEAP32[i7 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 40259 HEAP32[i7 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 40260 HEAP32[i7 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 40261 i2 = i1 + 168 | 0;
michael@0 40262 i7 = i5 + 32 | 0;
michael@0 40263 HEAP32[i2 >> 2] = HEAP32[i7 >> 2];
michael@0 40264 HEAP32[i2 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 40265 HEAP32[i2 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 40266 HEAP32[i2 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 40267 i7 = i1 + 184 | 0;
michael@0 40268 i2 = i5 + 48 | 0;
michael@0 40269 HEAP32[i7 >> 2] = HEAP32[i2 >> 2];
michael@0 40270 HEAP32[i7 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 40271 HEAP32[i7 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 40272 HEAP32[i7 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 40273 HEAPF32[i1 + 200 >> 2] = 1.0;
michael@0 40274 HEAPF32[i1 + 204 >> 2] = d6;
michael@0 40275 HEAPF32[i1 + 208 >> 2] = 0.0;
michael@0 40276 return;
michael@0 40277 }
michael@0 40278 function __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallback18processConstraintsEv(i1) {
michael@0 40279 i1 = i1 | 0;
michael@0 40280 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0;
michael@0 40281 i2 = i1 + 56 | 0;
michael@0 40282 i3 = HEAP32[i2 >> 2] | 0;
michael@0 40283 i4 = i1 + 76 | 0;
michael@0 40284 i5 = HEAP32[i4 >> 2] | 0;
michael@0 40285 if ((i5 + i3 | 0) > 0) {
michael@0 40286 i6 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 40287 i7 = HEAP32[(HEAP32[i6 >> 2] | 0) + 12 >> 2] | 0;
michael@0 40288 i8 = HEAP32[i1 + 44 >> 2] | 0;
michael@0 40289 i9 = i1 + 36 | 0;
michael@0 40290 i10 = HEAP32[i9 >> 2] | 0;
michael@0 40291 i11 = HEAP32[i1 + 64 >> 2] | 0;
michael@0 40292 i12 = HEAP32[i1 + 84 >> 2] | 0;
michael@0 40293 i13 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 40294 i14 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 40295 i15 = HEAP32[i1 + 24 >> 2] | 0;
michael@0 40296 i16 = HEAP32[i1 + 28 >> 2] | 0;
michael@0 40297 +FUNCTION_TABLE_fiiiiiiiiiii[i7 & 3](i6, i8, i10, i11, i3, i12, i5, i13, i14, i15, i16);
michael@0 40298 i17 = i9;
michael@0 40299 } else {
michael@0 40300 i17 = i1 + 36 | 0;
michael@0 40301 }
michael@0 40302 i9 = HEAP32[i17 >> 2] | 0;
michael@0 40303 if ((i9 | 0) < 0) {
michael@0 40304 i16 = i1 + 40 | 0;
michael@0 40305 i15 = i1 + 44 | 0;
michael@0 40306 if ((HEAP32[i16 >> 2] | 0) < 0) {
michael@0 40307 i14 = HEAP32[i15 >> 2] | 0;
michael@0 40308 i13 = i1 + 48 | 0;
michael@0 40309 if ((i14 | 0) != 0) {
michael@0 40310 if ((HEAP8[i13] | 0) != 0) {
michael@0 40311 __Z21btAlignedFreeInternalPv(i14);
michael@0 40312 }
michael@0 40313 HEAP32[i15 >> 2] = 0;
michael@0 40314 }
michael@0 40315 HEAP8[i13] = 1;
michael@0 40316 HEAP32[i15 >> 2] = 0;
michael@0 40317 HEAP32[i16 >> 2] = 0;
michael@0 40318 i18 = i9;
michael@0 40319 } else {
michael@0 40320 i18 = i9;
michael@0 40321 }
michael@0 40322 do {
michael@0 40323 i9 = (HEAP32[i15 >> 2] | 0) + (i18 << 2) | 0;
michael@0 40324 if ((i9 | 0) != 0) {
michael@0 40325 HEAP32[i9 >> 2] = 0;
michael@0 40326 }
michael@0 40327 i18 = i18 + 1 | 0;
michael@0 40328 } while ((i18 | 0) < 0);
michael@0 40329 }
michael@0 40330 HEAP32[i17 >> 2] = 0;
michael@0 40331 i17 = HEAP32[i2 >> 2] | 0;
michael@0 40332 if ((i17 | 0) < 0) {
michael@0 40333 i18 = i1 + 60 | 0;
michael@0 40334 i15 = i1 + 64 | 0;
michael@0 40335 if ((HEAP32[i18 >> 2] | 0) < 0) {
michael@0 40336 i9 = HEAP32[i15 >> 2] | 0;
michael@0 40337 i16 = i1 + 68 | 0;
michael@0 40338 if ((i9 | 0) != 0) {
michael@0 40339 if ((HEAP8[i16] | 0) != 0) {
michael@0 40340 __Z21btAlignedFreeInternalPv(i9);
michael@0 40341 }
michael@0 40342 HEAP32[i15 >> 2] = 0;
michael@0 40343 }
michael@0 40344 HEAP8[i16] = 1;
michael@0 40345 HEAP32[i15 >> 2] = 0;
michael@0 40346 HEAP32[i18 >> 2] = 0;
michael@0 40347 i19 = i17;
michael@0 40348 } else {
michael@0 40349 i19 = i17;
michael@0 40350 }
michael@0 40351 do {
michael@0 40352 i17 = (HEAP32[i15 >> 2] | 0) + (i19 << 2) | 0;
michael@0 40353 if ((i17 | 0) != 0) {
michael@0 40354 HEAP32[i17 >> 2] = 0;
michael@0 40355 }
michael@0 40356 i19 = i19 + 1 | 0;
michael@0 40357 } while ((i19 | 0) < 0);
michael@0 40358 }
michael@0 40359 HEAP32[i2 >> 2] = 0;
michael@0 40360 i2 = HEAP32[i4 >> 2] | 0;
michael@0 40361 if ((i2 | 0) >= 0) {
michael@0 40362 HEAP32[i4 >> 2] = 0;
michael@0 40363 return;
michael@0 40364 }
michael@0 40365 i19 = i1 + 80 | 0;
michael@0 40366 i15 = i1 + 84 | 0;
michael@0 40367 if ((HEAP32[i19 >> 2] | 0) < 0) {
michael@0 40368 i17 = HEAP32[i15 >> 2] | 0;
michael@0 40369 i18 = i1 + 88 | 0;
michael@0 40370 if ((i17 | 0) != 0) {
michael@0 40371 if ((HEAP8[i18] | 0) != 0) {
michael@0 40372 __Z21btAlignedFreeInternalPv(i17);
michael@0 40373 }
michael@0 40374 HEAP32[i15 >> 2] = 0;
michael@0 40375 }
michael@0 40376 HEAP8[i18] = 1;
michael@0 40377 HEAP32[i15 >> 2] = 0;
michael@0 40378 HEAP32[i19 >> 2] = 0;
michael@0 40379 i20 = i2;
michael@0 40380 } else {
michael@0 40381 i20 = i2;
michael@0 40382 }
michael@0 40383 do {
michael@0 40384 i2 = (HEAP32[i15 >> 2] | 0) + (i20 << 2) | 0;
michael@0 40385 if ((i2 | 0) != 0) {
michael@0 40386 HEAP32[i2 >> 2] = 0;
michael@0 40387 }
michael@0 40388 i20 = i20 + 1 | 0;
michael@0 40389 } while ((i20 | 0) < 0);
michael@0 40390 HEAP32[i4 >> 2] = 0;
michael@0 40391 return;
michael@0 40392 }
michael@0 40393 function __ZNK10__cxxabiv121__vmi_class_type_info16search_above_dstEPNS_19__dynamic_cast_infoEPKvS4_ib(i1, i2, i3, i4, i5, i6) {
michael@0 40394 i1 = i1 | 0;
michael@0 40395 i2 = i2 | 0;
michael@0 40396 i3 = i3 | 0;
michael@0 40397 i4 = i4 | 0;
michael@0 40398 i5 = i5 | 0;
michael@0 40399 i6 = i6 | 0;
michael@0 40400 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0;
michael@0 40401 if ((i1 | 0) != (HEAP32[i2 + 8 >> 2] | 0)) {
michael@0 40402 i7 = i2 + 52 | 0;
michael@0 40403 i8 = HEAP8[i7] & 1;
michael@0 40404 i9 = i2 + 53 | 0;
michael@0 40405 i10 = HEAP8[i9] & 1;
michael@0 40406 i11 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 40407 i12 = i1 + 16 + (i11 << 3) | 0;
michael@0 40408 HEAP8[i7] = 0;
michael@0 40409 HEAP8[i9] = 0;
michael@0 40410 i13 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 40411 i14 = i13 >> 8;
michael@0 40412 if ((i13 & 1 | 0) == 0) {
michael@0 40413 i15 = i14;
michael@0 40414 } else {
michael@0 40415 i15 = HEAP32[(HEAP32[i4 >> 2] | 0) + i14 >> 2] | 0;
michael@0 40416 }
michael@0 40417 i14 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 40418 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i14 >> 2] | 0) + 20 >> 2] & 15](i14, i2, i3, i4 + i15 | 0, (i13 & 2 | 0) != 0 ? i5 : 2, i6);
michael@0 40419 L2889 : do {
michael@0 40420 if ((i11 | 0) > 1) {
michael@0 40421 i13 = i2 + 24 | 0;
michael@0 40422 i15 = i1 + 8 | 0;
michael@0 40423 i14 = i2 + 54 | 0;
michael@0 40424 i16 = i4;
michael@0 40425 i17 = i1 + 24 | 0;
michael@0 40426 do {
michael@0 40427 if ((HEAP8[i14] & 1) != 0) {
michael@0 40428 break L2889;
michael@0 40429 }
michael@0 40430 do {
michael@0 40431 if ((HEAP8[i7] & 1) == 0) {
michael@0 40432 if ((HEAP8[i9] & 1) == 0) {
michael@0 40433 break;
michael@0 40434 }
michael@0 40435 if ((HEAP32[i15 >> 2] & 1 | 0) == 0) {
michael@0 40436 break L2889;
michael@0 40437 }
michael@0 40438 } else {
michael@0 40439 if ((HEAP32[i13 >> 2] | 0) == 1) {
michael@0 40440 break L2889;
michael@0 40441 }
michael@0 40442 if ((HEAP32[i15 >> 2] & 2 | 0) == 0) {
michael@0 40443 break L2889;
michael@0 40444 }
michael@0 40445 }
michael@0 40446 } while (0);
michael@0 40447 HEAP8[i7] = 0;
michael@0 40448 HEAP8[i9] = 0;
michael@0 40449 i18 = HEAP32[i17 + 4 >> 2] | 0;
michael@0 40450 i19 = i18 >> 8;
michael@0 40451 if ((i18 & 1 | 0) == 0) {
michael@0 40452 i20 = i19;
michael@0 40453 } else {
michael@0 40454 i20 = HEAP32[(HEAP32[i16 >> 2] | 0) + i19 >> 2] | 0;
michael@0 40455 }
michael@0 40456 i19 = HEAP32[i17 >> 2] | 0;
michael@0 40457 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i19 >> 2] | 0) + 20 >> 2] & 15](i19, i2, i3, i4 + i20 | 0, (i18 & 2 | 0) != 0 ? i5 : 2, i6);
michael@0 40458 i17 = i17 + 8 | 0;
michael@0 40459 } while (i17 >>> 0 < i12 >>> 0);
michael@0 40460 }
michael@0 40461 } while (0);
michael@0 40462 HEAP8[i7] = i8;
michael@0 40463 HEAP8[i9] = i10;
michael@0 40464 return;
michael@0 40465 }
michael@0 40466 HEAP8[i2 + 53 | 0] = 1;
michael@0 40467 if ((HEAP32[i2 + 4 >> 2] | 0) != (i4 | 0)) {
michael@0 40468 return;
michael@0 40469 }
michael@0 40470 HEAP8[i2 + 52 | 0] = 1;
michael@0 40471 i4 = i2 + 16 | 0;
michael@0 40472 i10 = HEAP32[i4 >> 2] | 0;
michael@0 40473 if ((i10 | 0) == 0) {
michael@0 40474 HEAP32[i4 >> 2] = i3;
michael@0 40475 HEAP32[i2 + 24 >> 2] = i5;
michael@0 40476 HEAP32[i2 + 36 >> 2] = 1;
michael@0 40477 if (!((HEAP32[i2 + 48 >> 2] | 0) == 1 & (i5 | 0) == 1)) {
michael@0 40478 return;
michael@0 40479 }
michael@0 40480 HEAP8[i2 + 54 | 0] = 1;
michael@0 40481 return;
michael@0 40482 }
michael@0 40483 if ((i10 | 0) != (i3 | 0)) {
michael@0 40484 i3 = i2 + 36 | 0;
michael@0 40485 HEAP32[i3 >> 2] = (HEAP32[i3 >> 2] | 0) + 1;
michael@0 40486 HEAP8[i2 + 54 | 0] = 1;
michael@0 40487 return;
michael@0 40488 }
michael@0 40489 i3 = i2 + 24 | 0;
michael@0 40490 i10 = HEAP32[i3 >> 2] | 0;
michael@0 40491 if ((i10 | 0) == 2) {
michael@0 40492 HEAP32[i3 >> 2] = i5;
michael@0 40493 i21 = i5;
michael@0 40494 } else {
michael@0 40495 i21 = i10;
michael@0 40496 }
michael@0 40497 if (!((HEAP32[i2 + 48 >> 2] | 0) == 1 & (i21 | 0) == 1)) {
michael@0 40498 return;
michael@0 40499 }
michael@0 40500 HEAP8[i2 + 54 | 0] = 1;
michael@0 40501 return;
michael@0 40502 }
michael@0 40503 function __ZN16btBoxBoxDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i1, i2, i3, i4, i5) {
michael@0 40504 i1 = i1 | 0;
michael@0 40505 i2 = i2 | 0;
michael@0 40506 i3 = i3 | 0;
michael@0 40507 i4 = i4 | 0;
michael@0 40508 i5 = i5 | 0;
michael@0 40509 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0;
michael@0 40510 i5 = STACKTOP;
michael@0 40511 STACKTOP = STACKTOP + 160 | 0;
michael@0 40512 i4 = i5 | 0;
michael@0 40513 i6 = i5 + 48 | 0;
michael@0 40514 i7 = i5 + 128 | 0;
michael@0 40515 i8 = i5 + 144 | 0;
michael@0 40516 i9 = i4 | 0;
michael@0 40517 HEAPF32[i9 >> 2] = +HEAPF32[i2 >> 2];
michael@0 40518 i10 = i6 | 0;
michael@0 40519 HEAPF32[i10 >> 2] = +HEAPF32[i2 + 64 >> 2];
michael@0 40520 HEAPF32[i4 + 4 >> 2] = +HEAPF32[i2 + 4 >> 2];
michael@0 40521 HEAPF32[i6 + 4 >> 2] = +HEAPF32[i2 + 68 >> 2];
michael@0 40522 HEAPF32[i4 + 8 >> 2] = +HEAPF32[i2 + 8 >> 2];
michael@0 40523 HEAPF32[i6 + 8 >> 2] = +HEAPF32[i2 + 72 >> 2];
michael@0 40524 HEAPF32[i4 + 16 >> 2] = +HEAPF32[i2 + 16 >> 2];
michael@0 40525 HEAPF32[i6 + 16 >> 2] = +HEAPF32[i2 + 80 >> 2];
michael@0 40526 HEAPF32[i4 + 20 >> 2] = +HEAPF32[i2 + 20 >> 2];
michael@0 40527 HEAPF32[i6 + 20 >> 2] = +HEAPF32[i2 + 84 >> 2];
michael@0 40528 HEAPF32[i4 + 24 >> 2] = +HEAPF32[i2 + 24 >> 2];
michael@0 40529 HEAPF32[i6 + 24 >> 2] = +HEAPF32[i2 + 88 >> 2];
michael@0 40530 HEAPF32[i4 + 32 >> 2] = +HEAPF32[i2 + 32 >> 2];
michael@0 40531 HEAPF32[i6 + 32 >> 2] = +HEAPF32[i2 + 96 >> 2];
michael@0 40532 HEAPF32[i4 + 36 >> 2] = +HEAPF32[i2 + 36 >> 2];
michael@0 40533 HEAPF32[i6 + 36 >> 2] = +HEAPF32[i2 + 100 >> 2];
michael@0 40534 HEAPF32[i4 + 40 >> 2] = +HEAPF32[i2 + 40 >> 2];
michael@0 40535 HEAPF32[i6 + 40 >> 2] = +HEAPF32[i2 + 104 >> 2];
michael@0 40536 i6 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 40537 d11 = +HEAPF32[i6 + 28 >> 2];
michael@0 40538 d12 = +HEAPF32[i6 + 32 >> 2];
michael@0 40539 d13 = +HEAPF32[i6 + 36 >> 2];
michael@0 40540 i4 = i6 | 0;
michael@0 40541 i14 = i6;
michael@0 40542 d15 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i14 >> 2] | 0) + 44 >> 2] & 7](i4);
michael@0 40543 d16 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i14 >> 2] | 0) + 44 >> 2] & 7](i4);
michael@0 40544 d17 = (d13 + +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i14 >> 2] | 0) + 44 >> 2] & 7](i4)) * 2.0;
michael@0 40545 HEAPF32[i7 >> 2] = (d11 + d15) * 2.0;
michael@0 40546 HEAPF32[i7 + 4 >> 2] = (d12 + d16) * 2.0;
michael@0 40547 HEAPF32[i7 + 8 >> 2] = d17;
michael@0 40548 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 40549 i4 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 40550 d17 = +HEAPF32[i4 + 28 >> 2];
michael@0 40551 d16 = +HEAPF32[i4 + 32 >> 2];
michael@0 40552 d12 = +HEAPF32[i4 + 36 >> 2];
michael@0 40553 i1 = i4 | 0;
michael@0 40554 i14 = i4;
michael@0 40555 d15 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i14 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 40556 d11 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i14 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 40557 d13 = (d12 + +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i14 >> 2] | 0) + 44 >> 2] & 7](i1)) * 2.0;
michael@0 40558 HEAPF32[i8 >> 2] = (d17 + d15) * 2.0;
michael@0 40559 HEAPF32[i8 + 4 >> 2] = (d16 + d11) * 2.0;
michael@0 40560 HEAPF32[i8 + 8 >> 2] = d13;
michael@0 40561 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 40562 __Z8dBoxBox2RK9btVector3PKfS1_S1_S3_S1_RS_PfPiiP12dContactGeomiRN36btDiscreteCollisionDetectorInterface6ResultE(i2 + 48 | 0, i9, i7, i2 + 112 | 0, i10, i8, i5 + 96 | 0, i5 + 112 | 0, i5 + 120 | 0, 4, 0, 0, i3) | 0;
michael@0 40563 STACKTOP = i5;
michael@0 40564 return;
michael@0 40565 }
michael@0 40566 function __ZN32btSphereSphereCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 40567 i1 = i1 | 0;
michael@0 40568 i2 = i2 | 0;
michael@0 40569 i3 = i3 | 0;
michael@0 40570 i4 = i4 | 0;
michael@0 40571 i5 = i5 | 0;
michael@0 40572 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0;
michael@0 40573 i4 = STACKTOP;
michael@0 40574 STACKTOP = STACKTOP + 32 | 0;
michael@0 40575 i6 = i4 | 0;
michael@0 40576 i7 = i4 + 16 | 0;
michael@0 40577 i8 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 40578 if ((i8 | 0) == 0) {
michael@0 40579 STACKTOP = i4;
michael@0 40580 return;
michael@0 40581 }
michael@0 40582 i1 = i5 + 4 | 0;
michael@0 40583 HEAP32[i1 >> 2] = i8;
michael@0 40584 i9 = HEAP32[i2 + 192 >> 2] | 0;
michael@0 40585 i10 = HEAP32[i3 + 192 >> 2] | 0;
michael@0 40586 d11 = +HEAPF32[i3 + 52 >> 2];
michael@0 40587 d12 = +HEAPF32[i2 + 52 >> 2] - d11;
michael@0 40588 d13 = +HEAPF32[i3 + 56 >> 2];
michael@0 40589 d14 = +HEAPF32[i2 + 56 >> 2] - d13;
michael@0 40590 d15 = +HEAPF32[i3 + 60 >> 2];
michael@0 40591 d16 = +HEAPF32[i2 + 60 >> 2] - d15;
michael@0 40592 d17 = +Math_sqrt(+(d12 * d12 + d14 * d14 + d16 * d16));
michael@0 40593 d18 = +HEAPF32[i10 + 28 >> 2] * +HEAPF32[i10 + 12 >> 2];
michael@0 40594 d19 = +HEAPF32[i9 + 28 >> 2] * +HEAPF32[i9 + 12 >> 2] + d18;
michael@0 40595 if (d17 > d19) {
michael@0 40596 if ((HEAP32[i8 + 1116 >> 2] | 0) == 0) {
michael@0 40597 STACKTOP = i4;
michael@0 40598 return;
michael@0 40599 }
michael@0 40600 if ((HEAP32[i8 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 40601 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i8, i5 + 8 | 0, i5 + 72 | 0);
michael@0 40602 STACKTOP = i4;
michael@0 40603 return;
michael@0 40604 } else {
michael@0 40605 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i8, i5 + 72 | 0, i5 + 8 | 0);
michael@0 40606 STACKTOP = i4;
michael@0 40607 return;
michael@0 40608 }
michael@0 40609 }
michael@0 40610 i8 = i6 | 0;
michael@0 40611 HEAPF32[i8 >> 2] = 1.0;
michael@0 40612 i9 = i6 + 4 | 0;
michael@0 40613 HEAPF32[i9 >> 2] = 0.0;
michael@0 40614 i10 = i6 + 8 | 0;
michael@0 40615 HEAPF32[i10 >> 2] = 0.0;
michael@0 40616 i2 = i6 + 12 | 0;
michael@0 40617 HEAPF32[i2 >> 2] = 0.0;
michael@0 40618 if (d17 > 1.1920928955078125e-7) {
michael@0 40619 d20 = 1.0 / d17;
michael@0 40620 d21 = d12 * d20;
michael@0 40621 d12 = d14 * d20;
michael@0 40622 d14 = d16 * d20;
michael@0 40623 HEAPF32[i8 >> 2] = d21;
michael@0 40624 HEAPF32[i9 >> 2] = d12;
michael@0 40625 HEAPF32[i10 >> 2] = d14;
michael@0 40626 HEAPF32[i2 >> 2] = 0.0;
michael@0 40627 d22 = d21;
michael@0 40628 d23 = d12;
michael@0 40629 d24 = d14;
michael@0 40630 } else {
michael@0 40631 d22 = 1.0;
michael@0 40632 d23 = 0.0;
michael@0 40633 d24 = 0.0;
michael@0 40634 }
michael@0 40635 HEAPF32[i7 >> 2] = d11 + d18 * d22;
michael@0 40636 HEAPF32[i7 + 4 >> 2] = d13 + d18 * d23;
michael@0 40637 HEAPF32[i7 + 8 >> 2] = d15 + d18 * d24;
michael@0 40638 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 40639 FUNCTION_TABLE_viiif[HEAP32[(HEAP32[i5 >> 2] | 0) + 16 >> 2] & 15](i5, i6, i7, d17 - d19);
michael@0 40640 i7 = HEAP32[i1 >> 2] | 0;
michael@0 40641 if ((HEAP32[i7 + 1116 >> 2] | 0) == 0) {
michael@0 40642 STACKTOP = i4;
michael@0 40643 return;
michael@0 40644 }
michael@0 40645 if ((HEAP32[i7 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 40646 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i7, i5 + 8 | 0, i5 + 72 | 0);
michael@0 40647 STACKTOP = i4;
michael@0 40648 return;
michael@0 40649 } else {
michael@0 40650 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i7, i5 + 72 | 0, i5 + 8 | 0);
michael@0 40651 STACKTOP = i4;
michael@0 40652 return;
michael@0 40653 }
michael@0 40654 }
michael@0 40655 function __ZN23btDiscreteDynamicsWorld26calculateSimulationIslandsEv(i1) {
michael@0 40656 i1 = i1 | 0;
michael@0 40657 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0;
michael@0 40658 __ZN15CProfileManager13Start_ProfileEPKc(176);
michael@0 40659 i2 = i1 + 176 | 0;
michael@0 40660 i3 = HEAP32[i2 >> 2] | 0;
michael@0 40661 i4 = i1 | 0;
michael@0 40662 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i3 >> 2] | 0) + 8 >> 2] & 127](i3, i4, HEAP32[i1 + 24 >> 2] | 0);
michael@0 40663 i3 = HEAP32[i1 + 184 >> 2] | 0;
michael@0 40664 if ((i3 | 0) > 0) {
michael@0 40665 i5 = HEAP32[i1 + 192 >> 2] | 0;
michael@0 40666 i1 = 0;
michael@0 40667 do {
michael@0 40668 i6 = HEAP32[i5 + (i1 << 2) >> 2] | 0;
michael@0 40669 i7 = HEAP32[i6 + 24 >> 2] | 0;
michael@0 40670 i8 = HEAP32[i6 + 28 >> 2] | 0;
michael@0 40671 do {
michael@0 40672 if ((i7 | 0) != 0) {
michael@0 40673 if ((HEAP32[i7 + 204 >> 2] & 3 | 0) != 0 | (i8 | 0) == 0) {
michael@0 40674 break;
michael@0 40675 }
michael@0 40676 if ((HEAP32[i8 + 204 >> 2] & 3 | 0) != 0) {
michael@0 40677 break;
michael@0 40678 }
michael@0 40679 i6 = HEAP32[i7 + 216 >> 2] | 0;
michael@0 40680 if ((i6 | 0) == 5 | (i6 | 0) == 2) {
michael@0 40681 i6 = HEAP32[i8 + 216 >> 2] | 0;
michael@0 40682 if ((i6 | 0) == 5 | (i6 | 0) == 2) {
michael@0 40683 break;
michael@0 40684 }
michael@0 40685 }
michael@0 40686 i6 = HEAP32[i7 + 208 >> 2] | 0;
michael@0 40687 i9 = HEAP32[i8 + 208 >> 2] | 0;
michael@0 40688 i10 = HEAP32[(HEAP32[i2 >> 2] | 0) + 16 >> 2] | 0;
michael@0 40689 i11 = i10 + (i6 << 3) | 0;
michael@0 40690 i12 = HEAP32[i11 >> 2] | 0;
michael@0 40691 if ((i12 | 0) == (i6 | 0)) {
michael@0 40692 i13 = i6;
michael@0 40693 } else {
michael@0 40694 i6 = i11;
michael@0 40695 i11 = i12;
michael@0 40696 while (1) {
michael@0 40697 i12 = i10 + (i11 << 3) | 0;
michael@0 40698 HEAP32[i6 >> 2] = HEAP32[i12 >> 2];
michael@0 40699 i14 = HEAP32[i12 >> 2] | 0;
michael@0 40700 i12 = i10 + (i14 << 3) | 0;
michael@0 40701 i15 = HEAP32[i12 >> 2] | 0;
michael@0 40702 if ((i14 | 0) == (i15 | 0)) {
michael@0 40703 i13 = i14;
michael@0 40704 break;
michael@0 40705 } else {
michael@0 40706 i6 = i12;
michael@0 40707 i11 = i15;
michael@0 40708 }
michael@0 40709 }
michael@0 40710 }
michael@0 40711 i11 = i10 + (i9 << 3) | 0;
michael@0 40712 i6 = HEAP32[i11 >> 2] | 0;
michael@0 40713 if ((i6 | 0) == (i9 | 0)) {
michael@0 40714 i16 = i9;
michael@0 40715 } else {
michael@0 40716 i15 = i11;
michael@0 40717 i11 = i6;
michael@0 40718 while (1) {
michael@0 40719 i6 = i10 + (i11 << 3) | 0;
michael@0 40720 HEAP32[i15 >> 2] = HEAP32[i6 >> 2];
michael@0 40721 i12 = HEAP32[i6 >> 2] | 0;
michael@0 40722 i6 = i10 + (i12 << 3) | 0;
michael@0 40723 i14 = HEAP32[i6 >> 2] | 0;
michael@0 40724 if ((i12 | 0) == (i14 | 0)) {
michael@0 40725 i16 = i12;
michael@0 40726 break;
michael@0 40727 } else {
michael@0 40728 i15 = i6;
michael@0 40729 i11 = i14;
michael@0 40730 }
michael@0 40731 }
michael@0 40732 }
michael@0 40733 if ((i13 | 0) == (i16 | 0)) {
michael@0 40734 break;
michael@0 40735 }
michael@0 40736 HEAP32[i10 + (i13 << 3) >> 2] = i16;
michael@0 40737 i11 = i10 + (i16 << 3) + 4 | 0;
michael@0 40738 HEAP32[i11 >> 2] = (HEAP32[i11 >> 2] | 0) + (HEAP32[i10 + (i13 << 3) + 4 >> 2] | 0);
michael@0 40739 }
michael@0 40740 } while (0);
michael@0 40741 i1 = i1 + 1 | 0;
michael@0 40742 } while ((i1 | 0) < (i3 | 0));
michael@0 40743 }
michael@0 40744 i3 = HEAP32[i2 >> 2] | 0;
michael@0 40745 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 12 >> 2] & 127](i3, i4);
michael@0 40746 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 40747 return;
michael@0 40748 }
michael@0 40749 function __ZN23btDiscreteDynamicsWorld23synchronizeMotionStatesEv(i1) {
michael@0 40750 i1 = i1 | 0;
michael@0 40751 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 40752 i2 = STACKTOP;
michael@0 40753 STACKTOP = STACKTOP + 128 | 0;
michael@0 40754 i3 = i2 | 0;
michael@0 40755 i4 = i2 + 64 | 0;
michael@0 40756 __ZN15CProfileManager13Start_ProfileEPKc(936);
michael@0 40757 if ((HEAP8[i1 + 242 | 0] | 0) == 0) {
michael@0 40758 i5 = i1 + 204 | 0;
michael@0 40759 i6 = HEAP32[i5 >> 2] | 0;
michael@0 40760 if ((i6 | 0) <= 0) {
michael@0 40761 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 40762 STACKTOP = i2;
michael@0 40763 return;
michael@0 40764 }
michael@0 40765 i7 = i1 + 212 | 0;
michael@0 40766 i8 = i1 + 236 | 0;
michael@0 40767 i9 = 0;
michael@0 40768 i10 = i6;
michael@0 40769 while (1) {
michael@0 40770 i6 = HEAP32[(HEAP32[i7 >> 2] | 0) + (i9 << 2) >> 2] | 0;
michael@0 40771 i11 = HEAP32[i6 + 216 >> 2] | 0;
michael@0 40772 do {
michael@0 40773 if ((i11 | 0) == 5 | (i11 | 0) == 2) {
michael@0 40774 i12 = i10;
michael@0 40775 } else {
michael@0 40776 i13 = i6 + 472 | 0;
michael@0 40777 if ((HEAP32[i13 >> 2] | 0) == 0) {
michael@0 40778 i12 = i10;
michael@0 40779 break;
michael@0 40780 }
michael@0 40781 if ((HEAP32[i6 + 204 >> 2] & 3 | 0) != 0) {
michael@0 40782 i12 = i10;
michael@0 40783 break;
michael@0 40784 }
michael@0 40785 __ZN15btTransformUtil18integrateTransformERK11btTransformRK9btVector3S5_fRS0_(i6 + 68 | 0, i6 + 132 | 0, i6 + 148 | 0, +HEAPF32[i8 >> 2] * +HEAPF32[i6 + 240 >> 2], i4);
michael@0 40786 i14 = HEAP32[i13 >> 2] | 0;
michael@0 40787 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i14 >> 2] | 0) + 12 >> 2] & 127](i14, i4);
michael@0 40788 i12 = HEAP32[i5 >> 2] | 0;
michael@0 40789 }
michael@0 40790 } while (0);
michael@0 40791 i6 = i9 + 1 | 0;
michael@0 40792 if ((i6 | 0) < (i12 | 0)) {
michael@0 40793 i9 = i6;
michael@0 40794 i10 = i12;
michael@0 40795 } else {
michael@0 40796 break;
michael@0 40797 }
michael@0 40798 }
michael@0 40799 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 40800 STACKTOP = i2;
michael@0 40801 return;
michael@0 40802 } else {
michael@0 40803 i12 = i1 + 8 | 0;
michael@0 40804 i10 = HEAP32[i12 >> 2] | 0;
michael@0 40805 if ((i10 | 0) <= 0) {
michael@0 40806 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 40807 STACKTOP = i2;
michael@0 40808 return;
michael@0 40809 }
michael@0 40810 i9 = i1 + 16 | 0;
michael@0 40811 i5 = i1 + 236 | 0;
michael@0 40812 i1 = 0;
michael@0 40813 i4 = i10;
michael@0 40814 while (1) {
michael@0 40815 i10 = HEAP32[(HEAP32[i9 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 40816 do {
michael@0 40817 if ((HEAP32[i10 + 232 >> 2] & 2 | 0) == 0 | (i10 | 0) == 0) {
michael@0 40818 i15 = i4;
michael@0 40819 } else {
michael@0 40820 i8 = i10 + 472 | 0;
michael@0 40821 if ((HEAP32[i8 >> 2] | 0) == 0) {
michael@0 40822 i15 = i4;
michael@0 40823 break;
michael@0 40824 }
michael@0 40825 if ((HEAP32[i10 + 204 >> 2] & 3 | 0) != 0) {
michael@0 40826 i15 = i4;
michael@0 40827 break;
michael@0 40828 }
michael@0 40829 __ZN15btTransformUtil18integrateTransformERK11btTransformRK9btVector3S5_fRS0_(i10 + 68 | 0, i10 + 132 | 0, i10 + 148 | 0, +HEAPF32[i5 >> 2] * +HEAPF32[i10 + 240 >> 2], i3);
michael@0 40830 i7 = HEAP32[i8 >> 2] | 0;
michael@0 40831 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i7 >> 2] | 0) + 12 >> 2] & 127](i7, i3);
michael@0 40832 i15 = HEAP32[i12 >> 2] | 0;
michael@0 40833 }
michael@0 40834 } while (0);
michael@0 40835 i10 = i1 + 1 | 0;
michael@0 40836 if ((i10 | 0) < (i15 | 0)) {
michael@0 40837 i1 = i10;
michael@0 40838 i4 = i15;
michael@0 40839 } else {
michael@0 40840 break;
michael@0 40841 }
michael@0 40842 }
michael@0 40843 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 40844 STACKTOP = i2;
michael@0 40845 return;
michael@0 40846 }
michael@0 40847 }
michael@0 40848 function __ZN28btTriangleConvexcastCallback15processTriangleEP9btVector3ii(i1, i2, i3, i4) {
michael@0 40849 i1 = i1 | 0;
michael@0 40850 i2 = i2 | 0;
michael@0 40851 i3 = i3 | 0;
michael@0 40852 i4 = i4 | 0;
michael@0 40853 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0;
michael@0 40854 i5 = STACKTOP;
michael@0 40855 STACKTOP = STACKTOP + 672 | 0;
michael@0 40856 i6 = i5 | 0;
michael@0 40857 i7 = i5 + 104 | 0;
michael@0 40858 i8 = i5 + 464 | 0;
michael@0 40859 i9 = i5 + 472 | 0;
michael@0 40860 i10 = i5 + 496 | 0;
michael@0 40861 i11 = i6 | 0;
michael@0 40862 __ZN23btPolyhedralConvexShapeC2Ev(i11);
michael@0 40863 HEAP32[i6 >> 2] = 4560;
michael@0 40864 HEAP32[i6 + 4 >> 2] = 1;
michael@0 40865 i12 = i6 + 56 | 0;
michael@0 40866 i13 = i2;
michael@0 40867 HEAP32[i12 >> 2] = HEAP32[i13 >> 2];
michael@0 40868 HEAP32[i12 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 40869 HEAP32[i12 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 40870 HEAP32[i12 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 40871 i13 = i6 + 72 | 0;
michael@0 40872 i12 = i2 + 16 | 0;
michael@0 40873 HEAP32[i13 >> 2] = HEAP32[i12 >> 2];
michael@0 40874 HEAP32[i13 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 40875 HEAP32[i13 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 40876 HEAP32[i13 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 40877 i12 = i6 + 88 | 0;
michael@0 40878 i13 = i2 + 32 | 0;
michael@0 40879 HEAP32[i12 >> 2] = HEAP32[i13 >> 2];
michael@0 40880 HEAP32[i12 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 40881 HEAP32[i12 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 40882 HEAP32[i12 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 40883 HEAPF32[i6 + 44 >> 2] = +HEAPF32[i1 + 204 >> 2];
michael@0 40884 HEAPF32[i7 + 308 >> 2] = 9999999747378752.0e-20;
michael@0 40885 HEAP16[i7 + 332 >> 1] = 0;
michael@0 40886 HEAP32[i8 >> 2] = 2696;
michael@0 40887 __ZN27btContinuousConvexCollisionC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i9, HEAP32[i1 + 4 >> 2] | 0, i6 | 0, i7, i8 | 0);
michael@0 40888 HEAP32[i10 >> 2] = 2280;
michael@0 40889 i8 = i10 + 164 | 0;
michael@0 40890 HEAP32[i10 + 168 >> 2] = 0;
michael@0 40891 HEAPF32[i8 >> 2] = 1.0;
michael@0 40892 HEAPF32[i10 + 172 >> 2] = +HEAPF32[i1 + 208 >> 2];
michael@0 40893 i7 = i1 + 136 | 0;
michael@0 40894 do {
michael@0 40895 if (__ZN27btContinuousConvexCollision16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i9, i1 + 8 | 0, i1 + 72 | 0, i7, i7, i10) | 0) {
michael@0 40896 i6 = i10 + 132 | 0;
michael@0 40897 i13 = i6 | 0;
michael@0 40898 d14 = +HEAPF32[i13 >> 2];
michael@0 40899 i12 = i10 + 136 | 0;
michael@0 40900 d15 = +HEAPF32[i12 >> 2];
michael@0 40901 i2 = i10 + 140 | 0;
michael@0 40902 d16 = +HEAPF32[i2 >> 2];
michael@0 40903 d17 = d14 * d14 + d15 * d15 + d16 * d16;
michael@0 40904 if (d17 <= 9999999747378752.0e-20) {
michael@0 40905 break;
michael@0 40906 }
michael@0 40907 d18 = +HEAPF32[i8 >> 2];
michael@0 40908 if (d18 >= +HEAPF32[i1 + 200 >> 2]) {
michael@0 40909 break;
michael@0 40910 }
michael@0 40911 d19 = 1.0 / +Math_sqrt(+d17);
michael@0 40912 HEAPF32[i13 >> 2] = d14 * d19;
michael@0 40913 HEAPF32[i12 >> 2] = d15 * d19;
michael@0 40914 HEAPF32[i2 >> 2] = d16 * d19;
michael@0 40915 i2 = HEAP32[(HEAP32[i1 >> 2] | 0) + 12 >> 2] | 0;
michael@0 40916 i12 = i10 + 148 | 0;
michael@0 40917 +FUNCTION_TABLE_fiiifii[i2 & 7](i1, i6, i12, d18, i3, i4);
michael@0 40918 }
michael@0 40919 } while (0);
michael@0 40920 __ZN12btConvexCastD2Ev(i9 | 0);
michael@0 40921 __ZN23btPolyhedralConvexShapeD2Ev(i11);
michael@0 40922 STACKTOP = i5;
michael@0 40923 return;
michael@0 40924 }
michael@0 40925 function __ZN11btRigidBody12applyDampingEf(i1, d2) {
michael@0 40926 i1 = i1 | 0;
michael@0 40927 d2 = +d2;
michael@0 40928 var d3 = 0.0, d4 = 0.0, i5 = 0, d6 = 0.0, i7 = 0, d8 = 0.0, i9 = 0, d10 = 0.0, d11 = 0.0, i12 = 0, i13 = 0, d14 = 0.0, i15 = 0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0;
michael@0 40929 d3 = +HEAPF32[i1 + 436 >> 2];
michael@0 40930 d4 = +Math_pow(+(1.0 - d3), +d2);
michael@0 40931 i5 = i1 + 304 | 0;
michael@0 40932 d6 = d4 * +HEAPF32[i5 >> 2];
michael@0 40933 HEAPF32[i5 >> 2] = d6;
michael@0 40934 i7 = i1 + 308 | 0;
michael@0 40935 d8 = d4 * +HEAPF32[i7 >> 2];
michael@0 40936 HEAPF32[i7 >> 2] = d8;
michael@0 40937 i9 = i1 + 312 | 0;
michael@0 40938 d10 = d4 * +HEAPF32[i9 >> 2];
michael@0 40939 HEAPF32[i9 >> 2] = d10;
michael@0 40940 d4 = +HEAPF32[i1 + 440 >> 2];
michael@0 40941 d11 = +Math_pow(+(1.0 - d4), +d2);
michael@0 40942 i12 = i1 + 320 | 0;
michael@0 40943 d2 = d11 * +HEAPF32[i12 >> 2];
michael@0 40944 HEAPF32[i12 >> 2] = d2;
michael@0 40945 i13 = i1 + 324 | 0;
michael@0 40946 d14 = d11 * +HEAPF32[i13 >> 2];
michael@0 40947 HEAPF32[i13 >> 2] = d14;
michael@0 40948 i15 = i1 + 328 | 0;
michael@0 40949 d16 = d11 * +HEAPF32[i15 >> 2];
michael@0 40950 HEAPF32[i15 >> 2] = d16;
michael@0 40951 if ((HEAP8[i1 + 444 | 0] | 0) == 0) {
michael@0 40952 return;
michael@0 40953 }
michael@0 40954 do {
michael@0 40955 if (d16 * d16 + (d2 * d2 + d14 * d14) < +HEAPF32[i1 + 456 >> 2]) {
michael@0 40956 if (d6 * d6 + d8 * d8 + d10 * d10 >= +HEAPF32[i1 + 452 >> 2]) {
michael@0 40957 d17 = d6;
michael@0 40958 d18 = d8;
michael@0 40959 d19 = d10;
michael@0 40960 d20 = d2;
michael@0 40961 d21 = d14;
michael@0 40962 d22 = d16;
michael@0 40963 break;
michael@0 40964 }
michael@0 40965 d11 = +HEAPF32[i1 + 448 >> 2];
michael@0 40966 d23 = d2 * d11;
michael@0 40967 HEAPF32[i12 >> 2] = d23;
michael@0 40968 d24 = d14 * d11;
michael@0 40969 HEAPF32[i13 >> 2] = d24;
michael@0 40970 d25 = d16 * d11;
michael@0 40971 HEAPF32[i15 >> 2] = d25;
michael@0 40972 d26 = d6 * d11;
michael@0 40973 HEAPF32[i5 >> 2] = d26;
michael@0 40974 d27 = d8 * d11;
michael@0 40975 HEAPF32[i7 >> 2] = d27;
michael@0 40976 d28 = d10 * d11;
michael@0 40977 HEAPF32[i9 >> 2] = d28;
michael@0 40978 d17 = d26;
michael@0 40979 d18 = d27;
michael@0 40980 d19 = d28;
michael@0 40981 d20 = d23;
michael@0 40982 d21 = d24;
michael@0 40983 d22 = d25;
michael@0 40984 } else {
michael@0 40985 d17 = d6;
michael@0 40986 d18 = d8;
michael@0 40987 d19 = d10;
michael@0 40988 d20 = d2;
michael@0 40989 d21 = d14;
michael@0 40990 d22 = d16;
michael@0 40991 }
michael@0 40992 } while (0);
michael@0 40993 d16 = +Math_sqrt(+(d19 * d19 + (d18 * d18 + d17 * d17)));
michael@0 40994 do {
michael@0 40995 if (d16 < d3) {
michael@0 40996 if (d16 > .004999999888241291) {
michael@0 40997 d14 = 1.0 / d16;
michael@0 40998 HEAPF32[i5 >> 2] = d17 - d17 * d14 * .004999999888241291;
michael@0 40999 HEAPF32[i7 >> 2] = d18 - d18 * d14 * .004999999888241291;
michael@0 41000 HEAPF32[i9 >> 2] = d19 - d19 * d14 * .004999999888241291;
michael@0 41001 break;
michael@0 41002 } else {
michael@0 41003 _memset(i5 | 0, 0, 16);
michael@0 41004 break;
michael@0 41005 }
michael@0 41006 }
michael@0 41007 } while (0);
michael@0 41008 d19 = +Math_sqrt(+(d22 * d22 + (d21 * d21 + d20 * d20)));
michael@0 41009 if (d19 >= d4) {
michael@0 41010 return;
michael@0 41011 }
michael@0 41012 if (d19 > .004999999888241291) {
michael@0 41013 d4 = 1.0 / d19;
michael@0 41014 HEAPF32[i12 >> 2] = d20 - d20 * d4 * .004999999888241291;
michael@0 41015 HEAPF32[i13 >> 2] = d21 - d21 * d4 * .004999999888241291;
michael@0 41016 HEAPF32[i15 >> 2] = d22 - d22 * d4 * .004999999888241291;
michael@0 41017 return;
michael@0 41018 } else {
michael@0 41019 _memset(i12 | 0, 0, 16);
michael@0 41020 return;
michael@0 41021 }
michael@0 41022 }
michael@0 41023 function __ZNK20btConvexHullInternal10Rational647compareERKS0_(i1, i2) {
michael@0 41024 i1 = i1 | 0;
michael@0 41025 i2 = i2 | 0;
michael@0 41026 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0;
michael@0 41027 i3 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 41028 i4 = HEAP32[i2 + 16 >> 2] | 0;
michael@0 41029 if ((i3 | 0) != (i4 | 0)) {
michael@0 41030 i5 = i3 - i4 | 0;
michael@0 41031 return i5 | 0;
michael@0 41032 }
michael@0 41033 if ((i3 | 0) == 0) {
michael@0 41034 i5 = 0;
michael@0 41035 return i5 | 0;
michael@0 41036 }
michael@0 41037 i4 = i1 | 0;
michael@0 41038 i6 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 41039 i7 = i2 + 8 | 0;
michael@0 41040 i8 = HEAP32[i7 + 4 >> 2] | 0;
michael@0 41041 i9 = HEAP32[i4 >> 2] | 0;
michael@0 41042 i4 = i6 & 0;
michael@0 41043 i10 = HEAP32[i7 >> 2] | 0;
michael@0 41044 i7 = i8 & 0;
michael@0 41045 i11 = ___muldi3(i10, i7, i9, i4) | 0;
michael@0 41046 i12 = tempRet0;
michael@0 41047 i13 = i8;
michael@0 41048 i8 = 0;
michael@0 41049 i14 = ___muldi3(i13, i8, i9, i4) | 0;
michael@0 41050 i4 = tempRet0;
michael@0 41051 i9 = i6;
michael@0 41052 i6 = 0;
michael@0 41053 i15 = ___muldi3(i10, i7, i9, i6) | 0;
michael@0 41054 i7 = tempRet0;
michael@0 41055 i10 = ___muldi3(i13, i8, i9, i6) | 0;
michael@0 41056 i6 = tempRet0;
michael@0 41057 i9 = _i64Add(i14 | 0, i4 & 0, i15 | 0, i7 & 0) | 0;
michael@0 41058 i15 = tempRet0;
michael@0 41059 i14 = _i64Add(i4, 0, i10, i6) | 0;
michael@0 41060 i6 = _i64Add(i14, tempRet0, i7, 0) | 0;
michael@0 41061 i7 = tempRet0;
michael@0 41062 i14 = _llvm_uadd_with_overflow_i64(i11 | 0, i12 | 0, 0, i9 | 0) | 0;
michael@0 41063 i9 = i14;
michael@0 41064 i14 = tempRet0;
michael@0 41065 i12 = _i64Add(i6, i7, tempRet1 & 1, 0) | 0;
michael@0 41066 i7 = _i64Add(i12, tempRet0, i15, 0) | 0;
michael@0 41067 i15 = tempRet0;
michael@0 41068 i12 = i1 + 8 | 0;
michael@0 41069 i1 = HEAP32[i12 + 4 >> 2] | 0;
michael@0 41070 i6 = i2 | 0;
michael@0 41071 i2 = HEAP32[i6 + 4 >> 2] | 0;
michael@0 41072 i11 = HEAP32[i12 >> 2] | 0;
michael@0 41073 i12 = i1 & 0;
michael@0 41074 i10 = HEAP32[i6 >> 2] | 0;
michael@0 41075 i6 = i2 & 0;
michael@0 41076 i4 = ___muldi3(i10, i6, i11, i12) | 0;
michael@0 41077 i8 = tempRet0;
michael@0 41078 i13 = i2;
michael@0 41079 i2 = 0;
michael@0 41080 i16 = ___muldi3(i13, i2, i11, i12) | 0;
michael@0 41081 i12 = tempRet0;
michael@0 41082 i11 = i1;
michael@0 41083 i1 = 0;
michael@0 41084 i17 = ___muldi3(i10, i6, i11, i1) | 0;
michael@0 41085 i6 = tempRet0;
michael@0 41086 i10 = ___muldi3(i13, i2, i11, i1) | 0;
michael@0 41087 i1 = tempRet0;
michael@0 41088 i11 = _i64Add(i16 | 0, i12 & 0, i17 | 0, i6 & 0) | 0;
michael@0 41089 i17 = tempRet0;
michael@0 41090 i16 = _i64Add(i12, 0, i10, i1) | 0;
michael@0 41091 i1 = _i64Add(i16, tempRet0, i6, 0) | 0;
michael@0 41092 i6 = tempRet0;
michael@0 41093 i16 = _llvm_uadd_with_overflow_i64(i4 | 0, i8 | 0, 0, i11 | 0) | 0;
michael@0 41094 i11 = i16;
michael@0 41095 i16 = tempRet0;
michael@0 41096 i8 = _i64Add(i1, i6, tempRet1 & 1, 0) | 0;
michael@0 41097 i6 = _i64Add(i8, tempRet0, i17, 0) | 0;
michael@0 41098 i17 = tempRet0;
michael@0 41099 do {
michael@0 41100 if (i15 >>> 0 < i17 >>> 0 | i15 >>> 0 == i17 >>> 0 & i7 >>> 0 < i6 >>> 0) {
michael@0 41101 i18 = -1;
michael@0 41102 } else {
michael@0 41103 if (i15 >>> 0 > i17 >>> 0 | i15 >>> 0 == i17 >>> 0 & i7 >>> 0 > i6 >>> 0) {
michael@0 41104 i18 = 1;
michael@0 41105 break;
michael@0 41106 }
michael@0 41107 if (i14 >>> 0 < i16 >>> 0 | i14 >>> 0 == i16 >>> 0 & i9 >>> 0 < i11 >>> 0) {
michael@0 41108 i18 = -1;
michael@0 41109 break;
michael@0 41110 }
michael@0 41111 i18 = (i14 >>> 0 > i16 >>> 0 | i14 >>> 0 == i16 >>> 0 & i9 >>> 0 > i11 >>> 0) & 1;
michael@0 41112 }
michael@0 41113 } while (0);
michael@0 41114 i5 = Math_imul(i18, i3) | 0;
michael@0 41115 return i5 | 0;
michael@0 41116 }
michael@0 41117 function __ZN19btSingleRayCallbackC2ERK9btVector3S2_PK16btCollisionWorldRNS3_17RayResultCallbackE(i1, i2, i3, i4, i5) {
michael@0 41118 i1 = i1 | 0;
michael@0 41119 i2 = i2 | 0;
michael@0 41120 i3 = i3 | 0;
michael@0 41121 i4 = i4 | 0;
michael@0 41122 i5 = i5 | 0;
michael@0 41123 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0;
michael@0 41124 HEAP32[i1 >> 2] = 3984;
michael@0 41125 i6 = i1 + 36 | 0;
michael@0 41126 i7 = i6;
michael@0 41127 i8 = i2;
michael@0 41128 HEAP32[i7 >> 2] = HEAP32[i8 >> 2];
michael@0 41129 HEAP32[i7 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 41130 HEAP32[i7 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 41131 HEAP32[i7 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 41132 i8 = i1 + 52 | 0;
michael@0 41133 i9 = i8;
michael@0 41134 i10 = i3;
michael@0 41135 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 41136 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 41137 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 41138 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 41139 HEAP32[i1 + 212 >> 2] = i4;
michael@0 41140 HEAP32[i1 + 216 >> 2] = i5;
michael@0 41141 HEAPF32[i1 + 68 >> 2] = 1.0;
michael@0 41142 _memset(i1 + 72 | 0, 0, 16);
michael@0 41143 HEAPF32[i1 + 88 >> 2] = 1.0;
michael@0 41144 _memset(i1 + 92 | 0, 0, 16);
michael@0 41145 HEAPF32[i1 + 108 >> 2] = 1.0;
michael@0 41146 HEAP32[i1 + 112 >> 2] = 0;
michael@0 41147 i5 = i1 + 116 | 0;
michael@0 41148 HEAP32[i5 >> 2] = HEAP32[i7 >> 2];
michael@0 41149 HEAP32[i5 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 41150 HEAP32[i5 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 41151 HEAP32[i5 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 41152 HEAPF32[i1 + 132 >> 2] = 1.0;
michael@0 41153 _memset(i1 + 136 | 0, 0, 16);
michael@0 41154 HEAPF32[i1 + 152 >> 2] = 1.0;
michael@0 41155 _memset(i1 + 156 | 0, 0, 16);
michael@0 41156 HEAPF32[i1 + 172 >> 2] = 1.0;
michael@0 41157 HEAP32[i1 + 176 >> 2] = 0;
michael@0 41158 i7 = i1 + 180 | 0;
michael@0 41159 HEAP32[i7 >> 2] = HEAP32[i9 >> 2];
michael@0 41160 HEAP32[i7 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 41161 HEAP32[i7 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 41162 HEAP32[i7 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 41163 d11 = +HEAPF32[i3 >> 2] - +HEAPF32[i2 >> 2];
michael@0 41164 d12 = +HEAPF32[i3 + 4 >> 2] - +HEAPF32[i2 + 4 >> 2];
michael@0 41165 d13 = +HEAPF32[i3 + 8 >> 2] - +HEAPF32[i2 + 8 >> 2];
michael@0 41166 d14 = 1.0 / +Math_sqrt(+(d11 * d11 + d12 * d12 + d13 * d13));
michael@0 41167 d15 = d11 * d14;
michael@0 41168 d11 = d12 * d14;
michael@0 41169 d12 = d13 * d14;
michael@0 41170 if (d15 == 0.0) {
michael@0 41171 d16 = 999999984306749400.0;
michael@0 41172 } else {
michael@0 41173 d16 = 1.0 / d15;
michael@0 41174 }
michael@0 41175 HEAPF32[i1 + 4 >> 2] = d16;
michael@0 41176 if (d11 == 0.0) {
michael@0 41177 d17 = 999999984306749400.0;
michael@0 41178 } else {
michael@0 41179 d17 = 1.0 / d11;
michael@0 41180 }
michael@0 41181 HEAPF32[i1 + 8 >> 2] = d17;
michael@0 41182 if (d12 == 0.0) {
michael@0 41183 d18 = 999999984306749400.0;
michael@0 41184 } else {
michael@0 41185 d18 = 1.0 / d12;
michael@0 41186 }
michael@0 41187 HEAPF32[i1 + 12 >> 2] = d18;
michael@0 41188 HEAP32[i1 + 20 >> 2] = d16 < 0.0;
michael@0 41189 HEAP32[i1 + 24 >> 2] = d17 < 0.0;
michael@0 41190 HEAP32[i1 + 28 >> 2] = d18 < 0.0;
michael@0 41191 HEAPF32[i1 + 32 >> 2] = d15 * (+HEAPF32[i8 >> 2] - +HEAPF32[i6 >> 2]) + d11 * (+HEAPF32[i1 + 56 >> 2] - +HEAPF32[i1 + 40 >> 2]) + d12 * (+HEAPF32[i1 + 60 >> 2] - +HEAPF32[i1 + 44 >> 2]);
michael@0 41192 return;
michael@0 41193 }
michael@0 41194 function __ZN6btDbvt19optimizeIncrementalEi(i1, i2) {
michael@0 41195 i1 = i1 | 0;
michael@0 41196 i2 = i2 | 0;
michael@0 41197 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0;
michael@0 41198 i3 = STACKTOP;
michael@0 41199 STACKTOP = STACKTOP + 32 | 0;
michael@0 41200 if ((i2 | 0) < 0) {
michael@0 41201 i4 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 41202 } else {
michael@0 41203 i4 = i2;
michael@0 41204 }
michael@0 41205 i2 = i1 | 0;
michael@0 41206 i5 = HEAP32[i2 >> 2] | 0;
michael@0 41207 if (!((i5 | 0) != 0 & (i4 | 0) > 0)) {
michael@0 41208 STACKTOP = i3;
michael@0 41209 return;
michael@0 41210 }
michael@0 41211 i6 = i1 + 16 | 0;
michael@0 41212 i7 = i3 | 0;
michael@0 41213 i8 = i4;
michael@0 41214 i4 = i5;
michael@0 41215 while (1) {
michael@0 41216 i5 = i4 + 40 | 0;
michael@0 41217 L2296 : do {
michael@0 41218 if ((HEAP32[i5 >> 2] | 0) == 0) {
michael@0 41219 i9 = i4;
michael@0 41220 } else {
michael@0 41221 i10 = 0;
michael@0 41222 i11 = i4;
michael@0 41223 i12 = i5;
michael@0 41224 while (1) {
michael@0 41225 i13 = (HEAP32[i6 >> 2] | 0) >>> (i10 >>> 0) & 1;
michael@0 41226 i14 = i11 + 32 | 0;
michael@0 41227 i15 = HEAP32[i14 >> 2] | 0;
michael@0 41228 if (i15 >>> 0 > i11 >>> 0) {
michael@0 41229 i16 = i15 + 40 | 0;
michael@0 41230 i17 = (HEAP32[i16 >> 2] | 0) == (i11 | 0) | 0;
michael@0 41231 i18 = i17 ^ 1;
michael@0 41232 i19 = HEAP32[i15 + 36 + (i18 << 2) >> 2] | 0;
michael@0 41233 i20 = i15 + 32 | 0;
michael@0 41234 i21 = HEAP32[i20 >> 2] | 0;
michael@0 41235 if ((i21 | 0) == 0) {
michael@0 41236 HEAP32[i2 >> 2] = i11;
michael@0 41237 } else {
michael@0 41238 HEAP32[i21 + 36 + (((HEAP32[i21 + 40 >> 2] | 0) == (i15 | 0)) << 2) >> 2] = i11;
michael@0 41239 }
michael@0 41240 HEAP32[i19 + 32 >> 2] = i11;
michael@0 41241 HEAP32[i20 >> 2] = i11;
michael@0 41242 HEAP32[i14 >> 2] = i21;
michael@0 41243 i21 = i11 + 36 | 0;
michael@0 41244 HEAP32[i15 + 36 >> 2] = HEAP32[i21 >> 2];
michael@0 41245 HEAP32[i16 >> 2] = HEAP32[i12 >> 2];
michael@0 41246 HEAP32[(HEAP32[i21 >> 2] | 0) + 32 >> 2] = i15;
michael@0 41247 HEAP32[(HEAP32[i12 >> 2] | 0) + 32 >> 2] = i15;
michael@0 41248 HEAP32[i11 + 36 + (i17 << 2) >> 2] = i15;
michael@0 41249 HEAP32[i11 + 36 + (i18 << 2) >> 2] = i19;
michael@0 41250 i19 = i15;
michael@0 41251 _memcpy(i7 | 0, i19 | 0, 32) | 0;
michael@0 41252 i18 = i11;
michael@0 41253 _memcpy(i19 | 0, i18 | 0, 32) | 0;
michael@0 41254 _memcpy(i18 | 0, i7 | 0, 32) | 0;
michael@0 41255 i22 = i15;
michael@0 41256 } else {
michael@0 41257 i22 = i11;
michael@0 41258 }
michael@0 41259 i15 = HEAP32[i22 + 36 + (i13 << 2) >> 2] | 0;
michael@0 41260 i13 = i15 + 40 | 0;
michael@0 41261 if ((HEAP32[i13 >> 2] | 0) == 0) {
michael@0 41262 i9 = i15;
michael@0 41263 break L2296;
michael@0 41264 }
michael@0 41265 i10 = i10 + 1 & 31;
michael@0 41266 i11 = i15;
michael@0 41267 i12 = i13;
michael@0 41268 }
michael@0 41269 }
michael@0 41270 } while (0);
michael@0 41271 if ((__ZL10removeleafP6btDbvtP10btDbvtNode(i1, i9) | 0) == 0) {
michael@0 41272 i23 = 0;
michael@0 41273 } else {
michael@0 41274 i23 = HEAP32[i2 >> 2] | 0;
michael@0 41275 }
michael@0 41276 __ZL10insertleafP6btDbvtP10btDbvtNodeS2_(i1, i23, i9);
michael@0 41277 HEAP32[i6 >> 2] = (HEAP32[i6 >> 2] | 0) + 1;
michael@0 41278 i5 = i8 - 1 | 0;
michael@0 41279 if ((i5 | 0) == 0) {
michael@0 41280 break;
michael@0 41281 }
michael@0 41282 i8 = i5;
michael@0 41283 i4 = HEAP32[i2 >> 2] | 0;
michael@0 41284 }
michael@0 41285 STACKTOP = i3;
michael@0 41286 return;
michael@0 41287 }
michael@0 41288 function __ZN11btRigidBody18saveKinematicStateEf(i1, d2) {
michael@0 41289 i1 = i1 | 0;
michael@0 41290 d2 = +d2;
michael@0 41291 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0;
michael@0 41292 i3 = STACKTOP;
michael@0 41293 STACKTOP = STACKTOP + 24 | 0;
michael@0 41294 i4 = i3 | 0;
michael@0 41295 i5 = i3 + 16 | 0;
michael@0 41296 if (d2 == 0.0) {
michael@0 41297 STACKTOP = i3;
michael@0 41298 return;
michael@0 41299 }
michael@0 41300 i6 = HEAP32[i1 + 472 >> 2] | 0;
michael@0 41301 if ((i6 | 0) == 0) {
michael@0 41302 i7 = i1 + 4 | 0;
michael@0 41303 } else {
michael@0 41304 i8 = i1 + 4 | 0;
michael@0 41305 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 127](i6, i8);
michael@0 41306 i7 = i8;
michael@0 41307 }
michael@0 41308 i8 = i1 + 68 | 0;
michael@0 41309 i6 = i1 + 304 | 0;
michael@0 41310 i9 = i1 + 320 | 0;
michael@0 41311 d10 = 1.0 / d2;
michael@0 41312 d2 = (+HEAPF32[i1 + 56 >> 2] - +HEAPF32[i1 + 120 >> 2]) * d10;
michael@0 41313 d11 = d10 * (+HEAPF32[i1 + 60 >> 2] - +HEAPF32[i1 + 124 >> 2]);
michael@0 41314 HEAPF32[i6 >> 2] = (+HEAPF32[i1 + 52 >> 2] - +HEAPF32[i1 + 116 >> 2]) * d10;
michael@0 41315 HEAPF32[i1 + 308 >> 2] = d2;
michael@0 41316 HEAPF32[i1 + 312 >> 2] = d11;
michael@0 41317 HEAPF32[i1 + 316 >> 2] = 0.0;
michael@0 41318 __ZN15btTransformUtil22calculateDiffAxisAngleERK11btTransformS2_R9btVector3Rf(i8, i7, i4, i5);
michael@0 41319 d11 = +HEAPF32[i5 >> 2];
michael@0 41320 d2 = d10 * d11 * +HEAPF32[i4 + 4 >> 2];
michael@0 41321 d12 = d10 * d11 * +HEAPF32[i4 + 8 >> 2];
michael@0 41322 HEAPF32[i9 >> 2] = d10 * +HEAPF32[i4 >> 2] * d11;
michael@0 41323 HEAPF32[i1 + 324 >> 2] = d2;
michael@0 41324 HEAPF32[i1 + 328 >> 2] = d12;
michael@0 41325 HEAPF32[i1 + 332 >> 2] = 0.0;
michael@0 41326 i4 = i1 + 132 | 0;
michael@0 41327 i5 = i6;
michael@0 41328 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 41329 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 41330 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 41331 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 41332 i5 = i1 + 148 | 0;
michael@0 41333 i4 = i9;
michael@0 41334 HEAP32[i5 >> 2] = HEAP32[i4 >> 2];
michael@0 41335 HEAP32[i5 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 41336 HEAP32[i5 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 41337 HEAP32[i5 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 41338 i4 = i8;
michael@0 41339 i8 = i7;
michael@0 41340 HEAP32[i4 >> 2] = HEAP32[i8 >> 2];
michael@0 41341 HEAP32[i4 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 41342 HEAP32[i4 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 41343 HEAP32[i4 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 41344 i8 = i1 + 84 | 0;
michael@0 41345 i4 = i1 + 20 | 0;
michael@0 41346 HEAP32[i8 >> 2] = HEAP32[i4 >> 2];
michael@0 41347 HEAP32[i8 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 41348 HEAP32[i8 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 41349 HEAP32[i8 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 41350 i4 = i1 + 100 | 0;
michael@0 41351 i8 = i1 + 36 | 0;
michael@0 41352 HEAP32[i4 >> 2] = HEAP32[i8 >> 2];
michael@0 41353 HEAP32[i4 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 41354 HEAP32[i4 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 41355 HEAP32[i4 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 41356 i8 = i1 + 116 | 0;
michael@0 41357 i4 = i1 + 52 | 0;
michael@0 41358 HEAP32[i8 >> 2] = HEAP32[i4 >> 2];
michael@0 41359 HEAP32[i8 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 41360 HEAP32[i8 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 41361 HEAP32[i8 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 41362 STACKTOP = i3;
michael@0 41363 return;
michael@0 41364 }
michael@0 41365 function __ZN12gjkepa2_impl3EPA6expandEjPNS_3GJK3sSVEPNS0_5sFaceEjRNS0_8sHorizonE(i1, i2, i3, i4, i5, i6) {
michael@0 41366 i1 = i1 | 0;
michael@0 41367 i2 = i2 | 0;
michael@0 41368 i3 = i3 | 0;
michael@0 41369 i4 = i4 | 0;
michael@0 41370 i5 = i5 | 0;
michael@0 41371 i6 = i6 | 0;
michael@0 41372 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0;
michael@0 41373 i7 = i4 + 59 | 0;
michael@0 41374 if ((HEAPU8[i7] | 0 | 0) == (i2 | 0)) {
michael@0 41375 i8 = 0;
michael@0 41376 return i8 | 0;
michael@0 41377 }
michael@0 41378 i9 = HEAP32[1360 + (i5 << 2) >> 2] | 0;
michael@0 41379 if (+HEAPF32[i4 >> 2] * +HEAPF32[i3 + 16 >> 2] + +HEAPF32[i4 + 4 >> 2] * +HEAPF32[i3 + 20 >> 2] + +HEAPF32[i4 + 8 >> 2] * +HEAPF32[i3 + 24 >> 2] - +HEAPF32[i4 + 16 >> 2] < -9999999747378752.0e-21) {
michael@0 41380 i10 = __ZN12gjkepa2_impl3EPA7newfaceEPNS_3GJK3sSVES3_S3_b(i1, HEAP32[i4 + 24 + (i9 << 2) >> 2] | 0, HEAP32[i4 + 24 + (i5 << 2) >> 2] | 0, i3, 0) | 0;
michael@0 41381 if ((i10 | 0) == 0) {
michael@0 41382 i8 = 0;
michael@0 41383 return i8 | 0;
michael@0 41384 }
michael@0 41385 HEAP8[i10 + 56 | 0] = i5 & 255;
michael@0 41386 HEAP32[i10 + 36 >> 2] = i4;
michael@0 41387 HEAP8[i4 + 56 + i5 | 0] = 0;
michael@0 41388 HEAP32[i4 + 36 + (i5 << 2) >> 2] = i10;
michael@0 41389 i11 = i6 | 0;
michael@0 41390 i12 = HEAP32[i11 >> 2] | 0;
michael@0 41391 if ((i12 | 0) == 0) {
michael@0 41392 HEAP32[i6 + 4 >> 2] = i10;
michael@0 41393 } else {
michael@0 41394 HEAP8[i12 + 57 | 0] = 2;
michael@0 41395 HEAP32[i12 + 40 >> 2] = i10;
michael@0 41396 HEAP8[i10 + 58 | 0] = 1;
michael@0 41397 HEAP32[i10 + 44 >> 2] = i12;
michael@0 41398 }
michael@0 41399 HEAP32[i11 >> 2] = i10;
michael@0 41400 i10 = i6 + 8 | 0;
michael@0 41401 HEAP32[i10 >> 2] = (HEAP32[i10 >> 2] | 0) + 1;
michael@0 41402 i8 = 1;
michael@0 41403 return i8 | 0;
michael@0 41404 }
michael@0 41405 i10 = HEAP32[1344 + (i5 << 2) >> 2] | 0;
michael@0 41406 HEAP8[i7] = i2 & 255;
michael@0 41407 if (!(__ZN12gjkepa2_impl3EPA6expandEjPNS_3GJK3sSVEPNS0_5sFaceEjRNS0_8sHorizonE(i1, i2, i3, HEAP32[i4 + 36 + (i9 << 2) >> 2] | 0, HEAPU8[i4 + 56 + i9 | 0] | 0, i6) | 0)) {
michael@0 41408 i8 = 0;
michael@0 41409 return i8 | 0;
michael@0 41410 }
michael@0 41411 if (!(__ZN12gjkepa2_impl3EPA6expandEjPNS_3GJK3sSVEPNS0_5sFaceEjRNS0_8sHorizonE(i1, i2, i3, HEAP32[i4 + 36 + (i10 << 2) >> 2] | 0, HEAPU8[i4 + 56 + i10 | 0] | 0, i6) | 0)) {
michael@0 41412 i8 = 0;
michael@0 41413 return i8 | 0;
michael@0 41414 }
michael@0 41415 i6 = i4 + 52 | 0;
michael@0 41416 i10 = HEAP32[i6 >> 2] | 0;
michael@0 41417 i3 = i4 + 48 | 0;
michael@0 41418 if ((i10 | 0) != 0) {
michael@0 41419 HEAP32[i10 + 48 >> 2] = HEAP32[i3 >> 2];
michael@0 41420 }
michael@0 41421 i10 = HEAP32[i3 >> 2] | 0;
michael@0 41422 if ((i10 | 0) != 0) {
michael@0 41423 HEAP32[i10 + 52 >> 2] = HEAP32[i6 >> 2];
michael@0 41424 }
michael@0 41425 i10 = i1 + 9792 | 0;
michael@0 41426 if ((HEAP32[i10 >> 2] | 0) == (i4 | 0)) {
michael@0 41427 HEAP32[i10 >> 2] = HEAP32[i6 >> 2];
michael@0 41428 }
michael@0 41429 i10 = i1 + 9796 | 0;
michael@0 41430 HEAP32[i10 >> 2] = (HEAP32[i10 >> 2] | 0) - 1;
michael@0 41431 HEAP32[i3 >> 2] = 0;
michael@0 41432 i3 = i1 + 9800 | 0;
michael@0 41433 HEAP32[i6 >> 2] = HEAP32[i3 >> 2];
michael@0 41434 i6 = HEAP32[i3 >> 2] | 0;
michael@0 41435 if ((i6 | 0) != 0) {
michael@0 41436 HEAP32[i6 + 48 >> 2] = i4;
michael@0 41437 }
michael@0 41438 HEAP32[i3 >> 2] = i4;
michael@0 41439 i4 = i1 + 9804 | 0;
michael@0 41440 HEAP32[i4 >> 2] = (HEAP32[i4 >> 2] | 0) + 1;
michael@0 41441 i8 = 1;
michael@0 41442 return i8 | 0;
michael@0 41443 }
michael@0 41444 function __ZN30btGjkEpaPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 41445 i1 = i1 | 0;
michael@0 41446 i2 = i2 | 0;
michael@0 41447 i3 = i3 | 0;
michael@0 41448 i4 = i4 | 0;
michael@0 41449 i5 = i5 | 0;
michael@0 41450 i6 = i6 | 0;
michael@0 41451 i7 = i7 | 0;
michael@0 41452 i8 = i8 | 0;
michael@0 41453 i9 = i9 | 0;
michael@0 41454 i10 = i10 | 0;
michael@0 41455 i11 = i11 | 0;
michael@0 41456 var d12 = 0.0, d13 = 0.0, i14 = 0, i15 = 0;
michael@0 41457 i11 = STACKTOP;
michael@0 41458 STACKTOP = STACKTOP + 72 | 0;
michael@0 41459 i10 = i11 | 0;
michael@0 41460 i2 = i11 + 16 | 0;
michael@0 41461 d12 = +HEAPF32[i5 + 52 >> 2] - +HEAPF32[i6 + 52 >> 2];
michael@0 41462 d13 = +HEAPF32[i5 + 56 >> 2] - +HEAPF32[i6 + 56 >> 2];
michael@0 41463 HEAPF32[i10 >> 2] = +HEAPF32[i5 + 48 >> 2] - +HEAPF32[i6 + 48 >> 2];
michael@0 41464 HEAPF32[i10 + 4 >> 2] = d12;
michael@0 41465 HEAPF32[i10 + 8 >> 2] = d13;
michael@0 41466 HEAPF32[i10 + 12 >> 2] = 0.0;
michael@0 41467 if (__ZN15btGjkEpaSolver211PenetrationEPK13btConvexShapeRK11btTransformS2_S5_RK9btVector3RNS_8sResultsEb(i3, i5, i4, i6, i10, i2, 1) | 0) {
michael@0 41468 i1 = i8;
michael@0 41469 i14 = i2 + 4 | 0;
michael@0 41470 HEAP32[i1 >> 2] = HEAP32[i14 >> 2];
michael@0 41471 HEAP32[i1 + 4 >> 2] = HEAP32[i14 + 4 >> 2];
michael@0 41472 HEAP32[i1 + 8 >> 2] = HEAP32[i14 + 8 >> 2];
michael@0 41473 HEAP32[i1 + 12 >> 2] = HEAP32[i14 + 12 >> 2];
michael@0 41474 i14 = i9;
michael@0 41475 i1 = i2 + 20 | 0;
michael@0 41476 HEAP32[i14 >> 2] = HEAP32[i1 >> 2];
michael@0 41477 HEAP32[i14 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 41478 HEAP32[i14 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 41479 HEAP32[i14 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 41480 i1 = i7;
michael@0 41481 i14 = i2 + 36 | 0;
michael@0 41482 HEAP32[i1 >> 2] = HEAP32[i14 >> 2];
michael@0 41483 HEAP32[i1 + 4 >> 2] = HEAP32[i14 + 4 >> 2];
michael@0 41484 HEAP32[i1 + 8 >> 2] = HEAP32[i14 + 8 >> 2];
michael@0 41485 HEAP32[i1 + 12 >> 2] = HEAP32[i14 + 12 >> 2];
michael@0 41486 i15 = 1;
michael@0 41487 STACKTOP = i11;
michael@0 41488 return i15 | 0;
michael@0 41489 }
michael@0 41490 if (!(__ZN15btGjkEpaSolver28DistanceEPK13btConvexShapeRK11btTransformS2_S5_RK9btVector3RNS_8sResultsE(i3, i5, i4, i6, i10, i2) | 0)) {
michael@0 41491 i15 = 0;
michael@0 41492 STACKTOP = i11;
michael@0 41493 return i15 | 0;
michael@0 41494 }
michael@0 41495 i10 = i8;
michael@0 41496 i8 = i2 + 4 | 0;
michael@0 41497 HEAP32[i10 >> 2] = HEAP32[i8 >> 2];
michael@0 41498 HEAP32[i10 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 41499 HEAP32[i10 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 41500 HEAP32[i10 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 41501 i8 = i9;
michael@0 41502 i9 = i2 + 20 | 0;
michael@0 41503 HEAP32[i8 >> 2] = HEAP32[i9 >> 2];
michael@0 41504 HEAP32[i8 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 41505 HEAP32[i8 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 41506 HEAP32[i8 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 41507 i9 = i7;
michael@0 41508 i7 = i2 + 36 | 0;
michael@0 41509 HEAP32[i9 >> 2] = HEAP32[i7 >> 2];
michael@0 41510 HEAP32[i9 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 41511 HEAP32[i9 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 41512 HEAP32[i9 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 41513 i15 = 0;
michael@0 41514 STACKTOP = i11;
michael@0 41515 return i15 | 0;
michael@0 41516 }
michael@0 41517 function __ZZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN31LocalTriangleSphereCastCallback15processTriangleEP9btVector3ii(i1, i2, i3, i4) {
michael@0 41518 i1 = i1 | 0;
michael@0 41519 i2 = i2 | 0;
michael@0 41520 i3 = i3 | 0;
michael@0 41521 i4 = i4 | 0;
michael@0 41522 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, i13 = 0, i14 = 0, i15 = 0;
michael@0 41523 i4 = STACKTOP;
michael@0 41524 STACKTOP = STACKTOP + 776 | 0;
michael@0 41525 i3 = i4 | 0;
michael@0 41526 i5 = i4 + 64 | 0;
michael@0 41527 i6 = i4 + 240 | 0;
michael@0 41528 i7 = i4 + 296 | 0;
michael@0 41529 i8 = i4 + 400 | 0;
michael@0 41530 i9 = i4 + 760 | 0;
michael@0 41531 HEAPF32[i3 >> 2] = 1.0;
michael@0 41532 _memset(i3 + 4 | 0, 0, 16);
michael@0 41533 HEAPF32[i3 + 20 >> 2] = 1.0;
michael@0 41534 _memset(i3 + 24 | 0, 0, 16);
michael@0 41535 HEAPF32[i3 + 40 >> 2] = 1.0;
michael@0 41536 _memset(i3 + 44 | 0, 0, 20);
michael@0 41537 HEAP32[i5 >> 2] = 2280;
michael@0 41538 i10 = i5 + 164 | 0;
michael@0 41539 HEAP32[i5 + 168 >> 2] = 0;
michael@0 41540 HEAPF32[i5 + 172 >> 2] = 0.0;
michael@0 41541 i11 = i1 + 200 | 0;
michael@0 41542 HEAPF32[i10 >> 2] = +HEAPF32[i11 >> 2];
michael@0 41543 d12 = +HEAPF32[i1 + 196 >> 2];
michael@0 41544 __ZN21btConvexInternalShapeC2Ev(i6 | 0);
michael@0 41545 HEAP32[i6 >> 2] = 4728;
michael@0 41546 HEAP32[i6 + 4 >> 2] = 8;
michael@0 41547 HEAPF32[i6 + 28 >> 2] = d12;
michael@0 41548 HEAPF32[i6 + 44 >> 2] = d12;
michael@0 41549 i13 = i7 | 0;
michael@0 41550 __ZN23btPolyhedralConvexShapeC2Ev(i13);
michael@0 41551 HEAP32[i7 >> 2] = 4560;
michael@0 41552 HEAP32[i7 + 4 >> 2] = 1;
michael@0 41553 i14 = i7 + 56 | 0;
michael@0 41554 i15 = i2;
michael@0 41555 HEAP32[i14 >> 2] = HEAP32[i15 >> 2];
michael@0 41556 HEAP32[i14 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 41557 HEAP32[i14 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 41558 HEAP32[i14 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 41559 i15 = i7 + 72 | 0;
michael@0 41560 i14 = i2 + 16 | 0;
michael@0 41561 HEAP32[i15 >> 2] = HEAP32[i14 >> 2];
michael@0 41562 HEAP32[i15 + 4 >> 2] = HEAP32[i14 + 4 >> 2];
michael@0 41563 HEAP32[i15 + 8 >> 2] = HEAP32[i14 + 8 >> 2];
michael@0 41564 HEAP32[i15 + 12 >> 2] = HEAP32[i14 + 12 >> 2];
michael@0 41565 i14 = i7 + 88 | 0;
michael@0 41566 i15 = i2 + 32 | 0;
michael@0 41567 HEAP32[i14 >> 2] = HEAP32[i15 >> 2];
michael@0 41568 HEAP32[i14 + 4 >> 2] = HEAP32[i15 + 4 >> 2];
michael@0 41569 HEAP32[i14 + 8 >> 2] = HEAP32[i15 + 8 >> 2];
michael@0 41570 HEAP32[i14 + 12 >> 2] = HEAP32[i15 + 12 >> 2];
michael@0 41571 HEAPF32[i8 + 308 >> 2] = 9999999747378752.0e-20;
michael@0 41572 HEAP16[i8 + 332 >> 1] = 0;
michael@0 41573 i15 = i6 | 0;
michael@0 41574 __ZN22btSubsimplexConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver(i9, i15, i7 | 0, i8);
michael@0 41575 do {
michael@0 41576 if (__ZN22btSubsimplexConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE(i9, i1 + 4 | 0, i1 + 68 | 0, i3, i3, i5) | 0) {
michael@0 41577 d12 = +HEAPF32[i10 >> 2];
michael@0 41578 if (+HEAPF32[i11 >> 2] <= d12) {
michael@0 41579 break;
michael@0 41580 }
michael@0 41581 HEAPF32[i11 >> 2] = d12;
michael@0 41582 }
michael@0 41583 } while (0);
michael@0 41584 __ZN12btConvexCastD2Ev(i9 | 0);
michael@0 41585 __ZN23btPolyhedralConvexShapeD2Ev(i13);
michael@0 41586 __ZN13btConvexShapeD2Ev(i15);
michael@0 41587 STACKTOP = i4;
michael@0 41588 return;
michael@0 41589 }
michael@0 41590 function __ZN15btTransformUtil18integrateTransformERK11btTransformRK9btVector3S5_fRS0_(i1, i2, i3, d4, i5) {
michael@0 41591 i1 = i1 | 0;
michael@0 41592 i2 = i2 | 0;
michael@0 41593 i3 = i3 | 0;
michael@0 41594 d4 = +d4;
michael@0 41595 i5 = i5 | 0;
michael@0 41596 var i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0;
michael@0 41597 i6 = STACKTOP;
michael@0 41598 STACKTOP = STACKTOP + 16 | 0;
michael@0 41599 i7 = i6 | 0;
michael@0 41600 d8 = +HEAPF32[i2 + 4 >> 2] * d4 + +HEAPF32[i1 + 52 >> 2];
michael@0 41601 d9 = +HEAPF32[i2 + 8 >> 2] * d4 + +HEAPF32[i1 + 56 >> 2];
michael@0 41602 HEAPF32[i5 + 48 >> 2] = +HEAPF32[i2 >> 2] * d4 + +HEAPF32[i1 + 48 >> 2];
michael@0 41603 HEAPF32[i5 + 52 >> 2] = d8;
michael@0 41604 HEAPF32[i5 + 56 >> 2] = d9;
michael@0 41605 HEAPF32[i5 + 60 >> 2] = 0.0;
michael@0 41606 d9 = +HEAPF32[i3 >> 2];
michael@0 41607 d8 = +HEAPF32[i3 + 4 >> 2];
michael@0 41608 d10 = +HEAPF32[i3 + 8 >> 2];
michael@0 41609 d11 = +Math_sqrt(+(d9 * d9 + d8 * d8 + d10 * d10));
michael@0 41610 if (d11 * d4 > .7853981852531433) {
michael@0 41611 d12 = .7853981852531433 / d4;
michael@0 41612 } else {
michael@0 41613 d12 = d11;
michael@0 41614 }
michael@0 41615 if (d12 < .0010000000474974513) {
michael@0 41616 d13 = d4 * .5 - d12 * d4 * d4 * d4 * .02083333395421505 * d12;
michael@0 41617 } else {
michael@0 41618 d13 = +Math_sin(+(d12 * .5 * d4)) / d12;
michael@0 41619 }
michael@0 41620 d11 = d9 * d13;
michael@0 41621 d9 = d8 * d13;
michael@0 41622 d8 = d10 * d13;
michael@0 41623 d13 = +Math_cos(+(d12 * d4 * .5));
michael@0 41624 __ZNK11btMatrix3x311getRotationER12btQuaternion(i1 | 0, i7);
michael@0 41625 d4 = +HEAPF32[i7 >> 2];
michael@0 41626 d12 = +HEAPF32[i7 + 12 >> 2];
michael@0 41627 d10 = +HEAPF32[i7 + 8 >> 2];
michael@0 41628 d14 = +HEAPF32[i7 + 4 >> 2];
michael@0 41629 d15 = d13 * d4 + d11 * d12 + d9 * d10 - d8 * d14;
michael@0 41630 d16 = d8 * d4 + (d9 * d12 + d13 * d14) - d11 * d10;
michael@0 41631 d17 = d8 * d12 + d13 * d10 + d11 * d14 - d9 * d4;
michael@0 41632 d18 = d13 * d12 - d11 * d4 - d9 * d14 - d8 * d10;
michael@0 41633 d10 = 1.0 / +Math_sqrt(+(d18 * d18 + (d17 * d17 + (d15 * d15 + d16 * d16))));
michael@0 41634 d8 = d15 * d10;
michael@0 41635 d15 = d10 * d16;
michael@0 41636 d16 = d10 * d17;
michael@0 41637 d17 = d10 * d18;
michael@0 41638 d18 = 2.0 / (d17 * d17 + (d16 * d16 + (d8 * d8 + d15 * d15)));
michael@0 41639 d10 = d8 * d18;
michael@0 41640 d14 = d18 * d15;
michael@0 41641 d9 = d18 * d16;
michael@0 41642 d18 = d17 * d10;
michael@0 41643 d4 = d17 * d14;
michael@0 41644 d11 = d17 * d9;
michael@0 41645 d17 = d8 * d10;
michael@0 41646 d10 = d8 * d14;
michael@0 41647 d12 = d8 * d9;
michael@0 41648 d8 = d15 * d14;
michael@0 41649 d14 = d15 * d9;
michael@0 41650 d15 = d16 * d9;
michael@0 41651 HEAPF32[i5 >> 2] = 1.0 - (d15 + d8);
michael@0 41652 HEAPF32[i5 + 4 >> 2] = d10 - d11;
michael@0 41653 HEAPF32[i5 + 8 >> 2] = d12 + d4;
michael@0 41654 HEAPF32[i5 + 12 >> 2] = 0.0;
michael@0 41655 HEAPF32[i5 + 16 >> 2] = d11 + d10;
michael@0 41656 HEAPF32[i5 + 20 >> 2] = 1.0 - (d17 + d15);
michael@0 41657 HEAPF32[i5 + 24 >> 2] = d14 - d18;
michael@0 41658 HEAPF32[i5 + 28 >> 2] = 0.0;
michael@0 41659 HEAPF32[i5 + 32 >> 2] = d12 - d4;
michael@0 41660 HEAPF32[i5 + 36 >> 2] = d18 + d14;
michael@0 41661 HEAPF32[i5 + 40 >> 2] = 1.0 - (d17 + d8);
michael@0 41662 HEAPF32[i5 + 44 >> 2] = 0.0;
michael@0 41663 STACKTOP = i6;
michael@0 41664 return;
michael@0 41665 }
michael@0 41666 function __ZL10removeleafP6btDbvtP10btDbvtNode(i1, i2) {
michael@0 41667 i1 = i1 | 0;
michael@0 41668 i2 = i2 | 0;
michael@0 41669 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, i12 = 0, d13 = 0.0, i14 = 0, d15 = 0.0, i16 = 0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, i26 = 0;
michael@0 41670 i3 = i1 | 0;
michael@0 41671 if ((HEAP32[i3 >> 2] | 0) == (i2 | 0)) {
michael@0 41672 HEAP32[i3 >> 2] = 0;
michael@0 41673 i4 = 0;
michael@0 41674 return i4 | 0;
michael@0 41675 }
michael@0 41676 i5 = HEAP32[i2 + 32 >> 2] | 0;
michael@0 41677 i6 = HEAP32[i5 + 32 >> 2] | 0;
michael@0 41678 i7 = HEAP32[i5 + 36 + (((HEAP32[i5 + 40 >> 2] | 0) != (i2 | 0)) << 2) >> 2] | 0;
michael@0 41679 if ((i6 | 0) == 0) {
michael@0 41680 HEAP32[i3 >> 2] = i7;
michael@0 41681 HEAP32[i7 + 32 >> 2] = 0;
michael@0 41682 i2 = i1 + 4 | 0;
michael@0 41683 __Z21btAlignedFreeInternalPv(HEAP32[i2 >> 2] | 0);
michael@0 41684 HEAP32[i2 >> 2] = i5;
michael@0 41685 i4 = HEAP32[i3 >> 2] | 0;
michael@0 41686 return i4 | 0;
michael@0 41687 }
michael@0 41688 HEAP32[i6 + 36 + (((HEAP32[i6 + 40 >> 2] | 0) == (i5 | 0)) << 2) >> 2] = i7;
michael@0 41689 HEAP32[i7 + 32 >> 2] = i6;
michael@0 41690 i7 = i1 + 4 | 0;
michael@0 41691 __Z21btAlignedFreeInternalPv(HEAP32[i7 >> 2] | 0);
michael@0 41692 HEAP32[i7 >> 2] = i5;
michael@0 41693 i5 = i6;
michael@0 41694 do {
michael@0 41695 i6 = i5 | 0;
michael@0 41696 d8 = +HEAPF32[i6 >> 2];
michael@0 41697 i7 = i5 + 4 | 0;
michael@0 41698 d9 = +HEAPF32[i7 >> 2];
michael@0 41699 i1 = i5 + 8 | 0;
michael@0 41700 d10 = +HEAPF32[i1 >> 2];
michael@0 41701 i2 = i5 + 16 | 0;
michael@0 41702 d11 = +HEAPF32[i2 >> 2];
michael@0 41703 i12 = i5 + 20 | 0;
michael@0 41704 d13 = +HEAPF32[i12 >> 2];
michael@0 41705 i14 = i5 + 24 | 0;
michael@0 41706 d15 = +HEAPF32[i14 >> 2];
michael@0 41707 i16 = HEAP32[i5 + 36 >> 2] | 0;
michael@0 41708 i17 = HEAP32[i5 + 40 >> 2] | 0;
michael@0 41709 d18 = +HEAPF32[i16 >> 2];
michael@0 41710 d19 = +HEAPF32[i17 >> 2];
michael@0 41711 d20 = d18 < d19 ? d18 : d19;
michael@0 41712 HEAPF32[i6 >> 2] = d20;
michael@0 41713 d19 = +HEAPF32[i16 + 16 >> 2];
michael@0 41714 d18 = +HEAPF32[i17 + 16 >> 2];
michael@0 41715 d21 = d19 > d18 ? d19 : d18;
michael@0 41716 HEAPF32[i2 >> 2] = d21;
michael@0 41717 d18 = +HEAPF32[i16 + 4 >> 2];
michael@0 41718 d19 = +HEAPF32[i17 + 4 >> 2];
michael@0 41719 d22 = d18 < d19 ? d18 : d19;
michael@0 41720 HEAPF32[i7 >> 2] = d22;
michael@0 41721 d19 = +HEAPF32[i16 + 20 >> 2];
michael@0 41722 d18 = +HEAPF32[i17 + 20 >> 2];
michael@0 41723 d23 = d19 > d18 ? d19 : d18;
michael@0 41724 HEAPF32[i12 >> 2] = d23;
michael@0 41725 d18 = +HEAPF32[i16 + 8 >> 2];
michael@0 41726 d19 = +HEAPF32[i17 + 8 >> 2];
michael@0 41727 d24 = d18 < d19 ? d18 : d19;
michael@0 41728 HEAPF32[i1 >> 2] = d24;
michael@0 41729 d19 = +HEAPF32[i16 + 24 >> 2];
michael@0 41730 d18 = +HEAPF32[i17 + 24 >> 2];
michael@0 41731 d25 = d19 > d18 ? d19 : d18;
michael@0 41732 HEAPF32[i14 >> 2] = d25;
michael@0 41733 if (!(d8 != d20 | d9 != d22 | d10 != d24 | d11 != d21)) {
michael@0 41734 if (!(d13 != d23 | d15 != d25)) {
michael@0 41735 i4 = i5;
michael@0 41736 i26 = 1994;
michael@0 41737 break;
michael@0 41738 }
michael@0 41739 }
michael@0 41740 i5 = HEAP32[i5 + 32 >> 2] | 0;
michael@0 41741 } while ((i5 | 0) != 0);
michael@0 41742 if ((i26 | 0) == 1994) {
michael@0 41743 return i4 | 0;
michael@0 41744 }
michael@0 41745 i4 = HEAP32[i3 >> 2] | 0;
michael@0 41746 return i4 | 0;
michael@0 41747 }
michael@0 41748 function __ZN6btDbvt6updateEP10btDbvtNodeR12btDbvtAabbMmRK9btVector3f(i1, i2, i3, i4, d5) {
michael@0 41749 i1 = i1 | 0;
michael@0 41750 i2 = i2 | 0;
michael@0 41751 i3 = i3 | 0;
michael@0 41752 i4 = i4 | 0;
michael@0 41753 d5 = +d5;
michael@0 41754 var i6 = 0, d7 = 0.0, d8 = 0.0, d9 = 0.0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, d14 = 0.0, i15 = 0, d16 = 0.0, i17 = 0, d18 = 0.0, i19 = 0, i20 = 0, i21 = 0;
michael@0 41755 i6 = i3 | 0;
michael@0 41756 d7 = +HEAPF32[i6 >> 2];
michael@0 41757 do {
michael@0 41758 if (+HEAPF32[i2 >> 2] > d7) {
michael@0 41759 d8 = +HEAPF32[i3 + 4 >> 2];
michael@0 41760 } else {
michael@0 41761 d9 = +HEAPF32[i3 + 4 >> 2];
michael@0 41762 if (+HEAPF32[i2 + 4 >> 2] > d9) {
michael@0 41763 d8 = d9;
michael@0 41764 break;
michael@0 41765 }
michael@0 41766 if (+HEAPF32[i2 + 8 >> 2] > +HEAPF32[i3 + 8 >> 2]) {
michael@0 41767 d8 = d9;
michael@0 41768 break;
michael@0 41769 }
michael@0 41770 if (+HEAPF32[i2 + 16 >> 2] < +HEAPF32[i3 + 16 >> 2]) {
michael@0 41771 d8 = d9;
michael@0 41772 break;
michael@0 41773 }
michael@0 41774 if (+HEAPF32[i2 + 20 >> 2] < +HEAPF32[i3 + 20 >> 2]) {
michael@0 41775 d8 = d9;
michael@0 41776 break;
michael@0 41777 }
michael@0 41778 if (+HEAPF32[i2 + 24 >> 2] < +HEAPF32[i3 + 24 >> 2]) {
michael@0 41779 d8 = d9;
michael@0 41780 break;
michael@0 41781 } else {
michael@0 41782 i10 = 0;
michael@0 41783 }
michael@0 41784 return i10 | 0;
michael@0 41785 }
michael@0 41786 } while (0);
michael@0 41787 d9 = d7 - d5;
michael@0 41788 HEAPF32[i6 >> 2] = d9;
michael@0 41789 i11 = i3 + 4 | 0;
michael@0 41790 d7 = d8 - d5;
michael@0 41791 HEAPF32[i11 >> 2] = d7;
michael@0 41792 i12 = i3 + 8 | 0;
michael@0 41793 d8 = +HEAPF32[i12 >> 2] - d5;
michael@0 41794 HEAPF32[i12 >> 2] = d8;
michael@0 41795 i13 = i3 + 16 | 0;
michael@0 41796 d14 = +HEAPF32[i13 >> 2] + d5;
michael@0 41797 HEAPF32[i13 >> 2] = d14;
michael@0 41798 i15 = i3 + 20 | 0;
michael@0 41799 d16 = +HEAPF32[i15 >> 2] + d5;
michael@0 41800 HEAPF32[i15 >> 2] = d16;
michael@0 41801 i17 = i3 + 24 | 0;
michael@0 41802 d18 = +HEAPF32[i17 >> 2] + d5;
michael@0 41803 HEAPF32[i17 >> 2] = d18;
michael@0 41804 d5 = +HEAPF32[i4 >> 2];
michael@0 41805 if (d5 > 0.0) {
michael@0 41806 HEAPF32[i13 >> 2] = d14 + d5;
michael@0 41807 } else {
michael@0 41808 HEAPF32[i6 >> 2] = d9 + d5;
michael@0 41809 }
michael@0 41810 d5 = +HEAPF32[i4 + 4 >> 2];
michael@0 41811 if (d5 > 0.0) {
michael@0 41812 HEAPF32[i15 >> 2] = d16 + d5;
michael@0 41813 } else {
michael@0 41814 HEAPF32[i11 >> 2] = d7 + d5;
michael@0 41815 }
michael@0 41816 d5 = +HEAPF32[i4 + 8 >> 2];
michael@0 41817 if (d5 > 0.0) {
michael@0 41818 HEAPF32[i17 >> 2] = d18 + d5;
michael@0 41819 } else {
michael@0 41820 HEAPF32[i12 >> 2] = d8 + d5;
michael@0 41821 }
michael@0 41822 i12 = __ZL10removeleafP6btDbvtP10btDbvtNode(i1, i2) | 0;
michael@0 41823 L2399 : do {
michael@0 41824 if ((i12 | 0) == 0) {
michael@0 41825 i19 = 0;
michael@0 41826 } else {
michael@0 41827 i17 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 41828 if ((i17 | 0) > -1) {
michael@0 41829 i20 = 0;
michael@0 41830 i21 = i12;
michael@0 41831 } else {
michael@0 41832 i19 = HEAP32[i1 >> 2] | 0;
michael@0 41833 break;
michael@0 41834 }
michael@0 41835 while (1) {
michael@0 41836 if ((i20 | 0) >= (i17 | 0)) {
michael@0 41837 i19 = i21;
michael@0 41838 break L2399;
michael@0 41839 }
michael@0 41840 i4 = HEAP32[i21 + 32 >> 2] | 0;
michael@0 41841 if ((i4 | 0) == 0) {
michael@0 41842 i19 = i21;
michael@0 41843 break;
michael@0 41844 } else {
michael@0 41845 i20 = i20 + 1 | 0;
michael@0 41846 i21 = i4;
michael@0 41847 }
michael@0 41848 }
michael@0 41849 }
michael@0 41850 } while (0);
michael@0 41851 i21 = i2;
michael@0 41852 i20 = i3;
michael@0 41853 _memcpy(i21 | 0, i20 | 0, 32) | 0;
michael@0 41854 __ZL10insertleafP6btDbvtP10btDbvtNodeS2_(i1, i19, i2);
michael@0 41855 i10 = 1;
michael@0 41856 return i10 | 0;
michael@0 41857 }
michael@0 41858 function __ZN23btDiscreteDynamicsWorld21updateActivationStateEf(i1, d2) {
michael@0 41859 i1 = i1 | 0;
michael@0 41860 d2 = +d2;
michael@0 41861 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, i18 = 0, i19 = 0;
michael@0 41862 __ZN15CProfileManager13Start_ProfileEPKc(312);
michael@0 41863 i3 = i1 + 204 | 0;
michael@0 41864 if ((HEAP32[i3 >> 2] | 0) <= 0) {
michael@0 41865 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 41866 return;
michael@0 41867 }
michael@0 41868 i4 = i1 + 212 | 0;
michael@0 41869 i1 = 0;
michael@0 41870 do {
michael@0 41871 i5 = HEAP32[(HEAP32[i4 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 41872 L390 : do {
michael@0 41873 if ((i5 | 0) != 0) {
michael@0 41874 i6 = i5 | 0;
michael@0 41875 i7 = i5 + 216 | 0;
michael@0 41876 i8 = HEAP32[i7 >> 2] | 0;
michael@0 41877 L392 : do {
michael@0 41878 if ((i8 | 0) == 2 | (i8 | 0) == 4) {
michael@0 41879 i9 = i8;
michael@0 41880 } else {
michael@0 41881 d10 = +HEAPF32[i5 + 304 >> 2];
michael@0 41882 d11 = +HEAPF32[i5 + 308 >> 2];
michael@0 41883 d12 = +HEAPF32[i5 + 312 >> 2];
michael@0 41884 d13 = +HEAPF32[i5 + 464 >> 2];
michael@0 41885 do {
michael@0 41886 if (d10 * d10 + d11 * d11 + d12 * d12 < d13 * d13) {
michael@0 41887 d14 = +HEAPF32[i5 + 320 >> 2];
michael@0 41888 d15 = +HEAPF32[i5 + 324 >> 2];
michael@0 41889 d16 = +HEAPF32[i5 + 328 >> 2];
michael@0 41890 d17 = +HEAPF32[i5 + 468 >> 2];
michael@0 41891 if (d14 * d14 + d15 * d15 + d16 * d16 >= d17 * d17) {
michael@0 41892 break;
michael@0 41893 }
michael@0 41894 i18 = i5 + 220 | 0;
michael@0 41895 HEAPF32[i18 >> 2] = +HEAPF32[i18 >> 2] + d2;
michael@0 41896 i9 = i8;
michael@0 41897 break L392;
michael@0 41898 }
michael@0 41899 } while (0);
michael@0 41900 HEAPF32[i5 + 220 >> 2] = 0.0;
michael@0 41901 __ZN17btCollisionObject18setActivationStateEi(i6, 0);
michael@0 41902 i9 = HEAP32[i7 >> 2] | 0;
michael@0 41903 }
michael@0 41904 } while (0);
michael@0 41905 if ((i9 | 0) == 4) {
michael@0 41906 break;
michael@0 41907 }
michael@0 41908 d13 = +HEAPF32[2];
michael@0 41909 do {
michael@0 41910 if (!((HEAP8[12016] | 0) != 0 | d13 == 0.0)) {
michael@0 41911 if ((i9 - 2 | 0) >>> 0 >= 2) {
michael@0 41912 if (+HEAPF32[i5 + 220 >> 2] <= d13) {
michael@0 41913 break;
michael@0 41914 }
michael@0 41915 }
michael@0 41916 if ((HEAP32[i5 + 204 >> 2] & 3 | 0) != 0) {
michael@0 41917 __ZN17btCollisionObject18setActivationStateEi(i6, 2);
michael@0 41918 break L390;
michael@0 41919 }
michael@0 41920 if ((i9 | 0) == 1) {
michael@0 41921 __ZN17btCollisionObject18setActivationStateEi(i6, 3);
michael@0 41922 i19 = HEAP32[i7 >> 2] | 0;
michael@0 41923 } else {
michael@0 41924 i19 = i9;
michael@0 41925 }
michael@0 41926 if ((i19 | 0) != 2) {
michael@0 41927 break L390;
michael@0 41928 }
michael@0 41929 _memset(i5 + 304 | 0, 0, 32);
michael@0 41930 break L390;
michael@0 41931 }
michael@0 41932 } while (0);
michael@0 41933 __ZN17btCollisionObject18setActivationStateEi(i6, 1);
michael@0 41934 }
michael@0 41935 } while (0);
michael@0 41936 i1 = i1 + 1 | 0;
michael@0 41937 } while ((i1 | 0) < (HEAP32[i3 >> 2] | 0));
michael@0 41938 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 41939 return;
michael@0 41940 }
michael@0 41941 function __ZN20btAlignedObjectArrayIN20btConvexHullInternal7Point32EE17quickSortInternalIPFbRKS1_S5_EEEvT_ii(i1, i2, i3, i4) {
michael@0 41942 i1 = i1 | 0;
michael@0 41943 i2 = i2 | 0;
michael@0 41944 i3 = i3 | 0;
michael@0 41945 i4 = i4 | 0;
michael@0 41946 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0;
michael@0 41947 i5 = STACKTOP;
michael@0 41948 STACKTOP = STACKTOP + 32 | 0;
michael@0 41949 i6 = i5 + 16 | 0;
michael@0 41950 i7 = i1 + 12 | 0;
michael@0 41951 i8 = i6;
michael@0 41952 i9 = (HEAP32[i7 >> 2] | 0) + (((i4 + i3 | 0) / 2 | 0) << 4) | 0;
michael@0 41953 HEAP32[i8 >> 2] = HEAP32[i9 >> 2];
michael@0 41954 HEAP32[i8 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 41955 HEAP32[i8 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 41956 HEAP32[i8 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 41957 i9 = i5 | 0;
michael@0 41958 i8 = i4;
michael@0 41959 i10 = i3;
michael@0 41960 while (1) {
michael@0 41961 i11 = i10;
michael@0 41962 while (1) {
michael@0 41963 i12 = i11 + 1 | 0;
michael@0 41964 if (FUNCTION_TABLE_iii[i2 & 63]((HEAP32[i7 >> 2] | 0) + (i11 << 4) | 0, i6) | 0) {
michael@0 41965 i11 = i12;
michael@0 41966 } else {
michael@0 41967 i13 = i8;
michael@0 41968 break;
michael@0 41969 }
michael@0 41970 }
michael@0 41971 while (1) {
michael@0 41972 i14 = i13 - 1 | 0;
michael@0 41973 if (FUNCTION_TABLE_iii[i2 & 63](i6, (HEAP32[i7 >> 2] | 0) + (i13 << 4) | 0) | 0) {
michael@0 41974 i13 = i14;
michael@0 41975 } else {
michael@0 41976 break;
michael@0 41977 }
michael@0 41978 }
michael@0 41979 if ((i11 | 0) > (i13 | 0)) {
michael@0 41980 i15 = i13;
michael@0 41981 i16 = i11;
michael@0 41982 } else {
michael@0 41983 i17 = HEAP32[i7 >> 2] | 0;
michael@0 41984 i18 = i17 + (i11 << 4) | 0;
michael@0 41985 HEAP32[i9 >> 2] = HEAP32[i18 >> 2];
michael@0 41986 HEAP32[i9 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 41987 HEAP32[i9 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 41988 HEAP32[i9 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 41989 i19 = i17 + (i13 << 4) | 0;
michael@0 41990 HEAP32[i18 >> 2] = HEAP32[i19 >> 2];
michael@0 41991 HEAP32[i18 + 4 >> 2] = HEAP32[i19 + 4 >> 2];
michael@0 41992 HEAP32[i18 + 8 >> 2] = HEAP32[i19 + 8 >> 2];
michael@0 41993 HEAP32[i18 + 12 >> 2] = HEAP32[i19 + 12 >> 2];
michael@0 41994 i19 = (HEAP32[i7 >> 2] | 0) + (i13 << 4) | 0;
michael@0 41995 HEAP32[i19 >> 2] = HEAP32[i9 >> 2];
michael@0 41996 HEAP32[i19 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 41997 HEAP32[i19 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 41998 HEAP32[i19 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 41999 i15 = i14;
michael@0 42000 i16 = i12;
michael@0 42001 }
michael@0 42002 if ((i16 | 0) > (i15 | 0)) {
michael@0 42003 break;
michael@0 42004 } else {
michael@0 42005 i8 = i15;
michael@0 42006 i10 = i16;
michael@0 42007 }
michael@0 42008 }
michael@0 42009 if ((i15 | 0) > (i3 | 0)) {
michael@0 42010 __ZN20btAlignedObjectArrayIN20btConvexHullInternal7Point32EE17quickSortInternalIPFbRKS1_S5_EEEvT_ii(i1, i2, i3, i15);
michael@0 42011 }
michael@0 42012 if ((i16 | 0) >= (i4 | 0)) {
michael@0 42013 STACKTOP = i5;
michael@0 42014 return;
michael@0 42015 }
michael@0 42016 __ZN20btAlignedObjectArrayIN20btConvexHullInternal7Point32EE17quickSortInternalIPFbRKS1_S5_EEEvT_ii(i1, i2, i16, i4);
michael@0 42017 STACKTOP = i5;
michael@0 42018 return;
michael@0 42019 }
michael@0 42020 function __ZN23btDiscreteDynamicsWorldC2EP12btDispatcherP21btBroadphaseInterfaceP18btConstraintSolverP24btCollisionConfiguration(i1, i2, i3, i4, i5) {
michael@0 42021 i1 = i1 | 0;
michael@0 42022 i2 = i2 | 0;
michael@0 42023 i3 = i3 | 0;
michael@0 42024 i4 = i4 | 0;
michael@0 42025 i5 = i5 | 0;
michael@0 42026 var i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 42027 __ZN16btCollisionWorldC2EP12btDispatcherP21btBroadphaseInterfaceP24btCollisionConfiguration(i1 | 0, i2, i3, i5);
michael@0 42028 HEAP32[i1 + 88 >> 2] = 0;
michael@0 42029 HEAP32[i1 + 92 >> 2] = 0;
michael@0 42030 HEAP32[i1 + 96 >> 2] = 0;
michael@0 42031 HEAPF32[i1 + 100 >> 2] = .6000000238418579;
michael@0 42032 HEAPF32[i1 + 104 >> 2] = 1.0;
michael@0 42033 HEAPF32[i1 + 108 >> 2] = .30000001192092896;
michael@0 42034 HEAPF32[i1 + 116 >> 2] = 0.0;
michael@0 42035 HEAPF32[i1 + 124 >> 2] = 20.0;
michael@0 42036 HEAP32[i1 + 120 >> 2] = 10;
michael@0 42037 HEAPF32[i1 + 132 >> 2] = .20000000298023224;
michael@0 42038 HEAPF32[i1 + 136 >> 2] = .10000000149011612;
michael@0 42039 HEAPF32[i1 + 140 >> 2] = 0.0;
michael@0 42040 HEAPF32[i1 + 128 >> 2] = 1.0;
michael@0 42041 HEAP32[i1 + 144 >> 2] = 0;
michael@0 42042 HEAPF32[i1 + 148 >> 2] = -.019999999552965164;
michael@0 42043 HEAPF32[i1 + 152 >> 2] = 0.0;
michael@0 42044 HEAPF32[i1 + 156 >> 2] = .8500000238418579;
michael@0 42045 HEAP32[i1 + 160 >> 2] = 260;
michael@0 42046 HEAP32[i1 + 164 >> 2] = 2;
michael@0 42047 HEAP32[i1 + 168 >> 2] = 128;
michael@0 42048 HEAP32[i1 >> 2] = 3272;
michael@0 42049 i5 = i1 + 172 | 0;
michael@0 42050 HEAP32[i5 >> 2] = i4;
michael@0 42051 HEAP8[i1 + 196 | 0] = 1;
michael@0 42052 HEAP32[i1 + 192 >> 2] = 0;
michael@0 42053 HEAP32[i1 + 184 >> 2] = 0;
michael@0 42054 HEAP32[i1 + 188 >> 2] = 0;
michael@0 42055 HEAP8[i1 + 216 | 0] = 1;
michael@0 42056 HEAP32[i1 + 212 >> 2] = 0;
michael@0 42057 HEAP32[i1 + 204 >> 2] = 0;
michael@0 42058 HEAP32[i1 + 208 >> 2] = 0;
michael@0 42059 HEAPF32[i1 + 220 >> 2] = 0.0;
michael@0 42060 HEAPF32[i1 + 224 >> 2] = -10.0;
michael@0 42061 HEAPF32[i1 + 228 >> 2] = 0.0;
michael@0 42062 HEAPF32[i1 + 232 >> 2] = 0.0;
michael@0 42063 HEAPF32[i1 + 236 >> 2] = 0.0;
michael@0 42064 HEAP8[i1 + 242 | 0] = 0;
michael@0 42065 HEAP8[i1 + 260 | 0] = 1;
michael@0 42066 HEAP32[i1 + 256 >> 2] = 0;
michael@0 42067 HEAP32[i1 + 248 >> 2] = 0;
michael@0 42068 HEAP32[i1 + 252 >> 2] = 0;
michael@0 42069 HEAP32[i1 + 264 >> 2] = 0;
michael@0 42070 if ((i4 | 0) == 0) {
michael@0 42071 i4 = __Z22btAlignedAllocInternalji(128, 16) | 0;
michael@0 42072 if ((i4 | 0) == 0) {
michael@0 42073 i6 = 0;
michael@0 42074 } else {
michael@0 42075 i3 = i4;
michael@0 42076 __ZN35btSequentialImpulseConstraintSolverC2Ev(i3);
michael@0 42077 i6 = i3;
michael@0 42078 }
michael@0 42079 HEAP32[i5 >> 2] = i6;
michael@0 42080 HEAP8[i1 + 241 | 0] = 1;
michael@0 42081 } else {
michael@0 42082 HEAP8[i1 + 241 | 0] = 0;
michael@0 42083 }
michael@0 42084 i6 = __Z22btAlignedAllocInternalji(68, 16) | 0;
michael@0 42085 if ((i6 | 0) == 0) {
michael@0 42086 i7 = 0;
michael@0 42087 i8 = i1 + 176 | 0;
michael@0 42088 HEAP32[i8 >> 2] = i7;
michael@0 42089 i9 = i1 + 240 | 0;
michael@0 42090 HEAP8[i9] = 1;
michael@0 42091 return;
michael@0 42092 }
michael@0 42093 i5 = i6;
michael@0 42094 __ZN25btSimulationIslandManagerC2Ev(i5);
michael@0 42095 i7 = i5;
michael@0 42096 i8 = i1 + 176 | 0;
michael@0 42097 HEAP32[i8 >> 2] = i7;
michael@0 42098 i9 = i1 + 240 | 0;
michael@0 42099 HEAP8[i9] = 1;
michael@0 42100 return;
michael@0 42101 }
michael@0 42102 function __ZN16btDbvtBroadphase11createProxyERK9btVector3S2_iPvssP12btDispatcherS3_(i1, i2, i3, i4, i5, i6, i7, i8, i9) {
michael@0 42103 i1 = i1 | 0;
michael@0 42104 i2 = i2 | 0;
michael@0 42105 i3 = i3 | 0;
michael@0 42106 i4 = i4 | 0;
michael@0 42107 i5 = i5 | 0;
michael@0 42108 i6 = i6 | 0;
michael@0 42109 i7 = i7 | 0;
michael@0 42110 i8 = i8 | 0;
michael@0 42111 i9 = i9 | 0;
michael@0 42112 var i10 = 0, i11 = 0;
michael@0 42113 i9 = STACKTOP;
michael@0 42114 STACKTOP = STACKTOP + 48 | 0;
michael@0 42115 i8 = i9 | 0;
michael@0 42116 i4 = i9 + 32 | 0;
michael@0 42117 i10 = __Z22btAlignedAllocInternalji(64, 16) | 0;
michael@0 42118 i11 = i10;
michael@0 42119 HEAP32[i10 >> 2] = i5;
michael@0 42120 HEAP16[i10 + 4 >> 1] = i6;
michael@0 42121 HEAP16[i10 + 6 >> 1] = i7;
michael@0 42122 i7 = i10 + 16 | 0;
michael@0 42123 i6 = i2;
michael@0 42124 HEAP32[i7 >> 2] = HEAP32[i6 >> 2];
michael@0 42125 HEAP32[i7 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 42126 HEAP32[i7 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 42127 HEAP32[i7 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 42128 i7 = i10 + 32 | 0;
michael@0 42129 i2 = i3;
michael@0 42130 HEAP32[i7 >> 2] = HEAP32[i2 >> 2];
michael@0 42131 HEAP32[i7 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 42132 HEAP32[i7 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 42133 HEAP32[i7 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 42134 HEAP32[i10 + 8 >> 2] = 0;
michael@0 42135 i7 = i10 + 56 | 0;
michael@0 42136 HEAP32[i7 >> 2] = 0;
michael@0 42137 i3 = i10 + 52 | 0;
michael@0 42138 HEAP32[i3 >> 2] = 0;
michael@0 42139 i5 = i8;
michael@0 42140 HEAP32[i5 >> 2] = HEAP32[i6 >> 2];
michael@0 42141 HEAP32[i5 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 42142 HEAP32[i5 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 42143 HEAP32[i5 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 42144 i6 = i8 + 16 | 0;
michael@0 42145 HEAP32[i6 >> 2] = HEAP32[i2 >> 2];
michael@0 42146 HEAP32[i6 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 42147 HEAP32[i6 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 42148 HEAP32[i6 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 42149 i2 = i1 + 104 | 0;
michael@0 42150 HEAP32[i10 + 60 >> 2] = HEAP32[i2 >> 2];
michael@0 42151 i6 = i1 + 148 | 0;
michael@0 42152 i5 = (HEAP32[i6 >> 2] | 0) + 1 | 0;
michael@0 42153 HEAP32[i6 >> 2] = i5;
michael@0 42154 i6 = i10;
michael@0 42155 HEAP32[i10 + 12 >> 2] = i5;
michael@0 42156 i5 = i1 + 4 | 0;
michael@0 42157 HEAP32[i10 + 48 >> 2] = __ZN6btDbvt6insertERK12btDbvtAabbMmPv(i5 | 0, i8, i10) | 0;
michael@0 42158 i10 = i1 + 84 + (HEAP32[i2 >> 2] << 2) | 0;
michael@0 42159 HEAP32[i3 >> 2] = 0;
michael@0 42160 HEAP32[i7 >> 2] = HEAP32[i10 >> 2];
michael@0 42161 i7 = HEAP32[i10 >> 2] | 0;
michael@0 42162 if ((i7 | 0) != 0) {
michael@0 42163 HEAP32[i7 + 52 >> 2] = i11;
michael@0 42164 }
michael@0 42165 HEAP32[i10 >> 2] = i11;
michael@0 42166 if ((HEAP8[i1 + 153 | 0] | 0) != 0) {
michael@0 42167 STACKTOP = i9;
michael@0 42168 return i6 | 0;
michael@0 42169 }
michael@0 42170 HEAP32[i4 >> 2] = 4064;
michael@0 42171 HEAP32[i4 + 4 >> 2] = i1;
michael@0 42172 HEAP32[i4 + 8 >> 2] = i11;
michael@0 42173 i11 = i4 | 0;
michael@0 42174 __ZN6btDbvt9collideTVEPK10btDbvtNodeRK12btDbvtAabbMmRNS_8ICollideE(0, HEAP32[i5 >> 2] | 0, i8, i11);
michael@0 42175 __ZN6btDbvt9collideTVEPK10btDbvtNodeRK12btDbvtAabbMmRNS_8ICollideE(0, HEAP32[i1 + 44 >> 2] | 0, i8, i11);
michael@0 42176 STACKTOP = i9;
michael@0 42177 return i6 | 0;
michael@0 42178 }
michael@0 42179 function __ZN28btHashedOverlappingPairCache15internalAddPairEP17btBroadphaseProxyS1_(i1, i2, i3) {
michael@0 42180 i1 = i1 | 0;
michael@0 42181 i2 = i2 | 0;
michael@0 42182 i3 = i3 | 0;
michael@0 42183 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0;
michael@0 42184 i4 = (HEAP32[i2 + 12 >> 2] | 0) > (HEAP32[i3 + 12 >> 2] | 0);
michael@0 42185 i5 = i4 ? i3 : i2;
michael@0 42186 i6 = i4 ? i2 : i3;
michael@0 42187 i3 = i5 + 12 | 0;
michael@0 42188 i2 = HEAP32[i3 >> 2] | 0;
michael@0 42189 i4 = i6 + 12 | 0;
michael@0 42190 i7 = HEAP32[i4 >> 2] | 0;
michael@0 42191 i8 = i7 << 16 | i2;
michael@0 42192 i9 = i8 + ~(i8 << 15) | 0;
michael@0 42193 i8 = (i9 >> 10 ^ i9) * 9 | 0;
michael@0 42194 i9 = i8 >> 6 ^ i8;
michael@0 42195 i8 = i9 + ~(i9 << 11) | 0;
michael@0 42196 i9 = i8 >> 16 ^ i8;
michael@0 42197 i8 = i1 + 4 | 0;
michael@0 42198 i10 = i1 + 12 | 0;
michael@0 42199 i11 = HEAP32[i10 >> 2] | 0;
michael@0 42200 i12 = i9 & i11 - 1;
michael@0 42201 i13 = i1 + 44 | 0;
michael@0 42202 i14 = HEAP32[(HEAP32[i13 >> 2] | 0) + (i12 << 2) >> 2] | 0;
michael@0 42203 L1755 : do {
michael@0 42204 if ((i14 | 0) != -1) {
michael@0 42205 i15 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 42206 i16 = i1 + 64 | 0;
michael@0 42207 i17 = i14;
michael@0 42208 while (1) {
michael@0 42209 if ((HEAP32[(HEAP32[i15 + (i17 << 4) >> 2] | 0) + 12 >> 2] | 0) == (i2 | 0)) {
michael@0 42210 if ((HEAP32[(HEAP32[i15 + (i17 << 4) + 4 >> 2] | 0) + 12 >> 2] | 0) == (i7 | 0)) {
michael@0 42211 break;
michael@0 42212 }
michael@0 42213 }
michael@0 42214 i18 = HEAP32[(HEAP32[i16 >> 2] | 0) + (i17 << 2) >> 2] | 0;
michael@0 42215 if ((i18 | 0) == -1) {
michael@0 42216 break L1755;
michael@0 42217 } else {
michael@0 42218 i17 = i18;
michael@0 42219 }
michael@0 42220 }
michael@0 42221 i16 = i15 + (i17 << 4) | 0;
michael@0 42222 if ((i16 | 0) == 0) {
michael@0 42223 break;
michael@0 42224 } else {
michael@0 42225 i19 = i16;
michael@0 42226 }
michael@0 42227 return i19 | 0;
michael@0 42228 }
michael@0 42229 } while (0);
michael@0 42230 i7 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 42231 i2 = __ZN20btAlignedObjectArrayI16btBroadphasePairE21expandNonInitializingEv(i8) | 0;
michael@0 42232 i8 = HEAP32[i1 + 72 >> 2] | 0;
michael@0 42233 if ((i8 | 0) != 0) {
michael@0 42234 i14 = HEAP32[(HEAP32[i8 >> 2] | 0) + 8 >> 2] | 0;
michael@0 42235 FUNCTION_TABLE_iiii[i14 & 31](i8, i5, i6) | 0;
michael@0 42236 }
michael@0 42237 if ((i11 | 0) < (HEAP32[i10 >> 2] | 0)) {
michael@0 42238 __ZN28btHashedOverlappingPairCache10growTablesEv(i1);
michael@0 42239 i20 = (HEAP32[i10 >> 2] | 0) - 1 & i9;
michael@0 42240 } else {
michael@0 42241 i20 = i12;
michael@0 42242 }
michael@0 42243 i12 = i2 | 0;
michael@0 42244 if ((HEAP32[i3 >> 2] | 0) < (HEAP32[i4 >> 2] | 0)) {
michael@0 42245 HEAP32[i12 >> 2] = i5;
michael@0 42246 HEAP32[i2 + 4 >> 2] = i6;
michael@0 42247 } else {
michael@0 42248 HEAP32[i12 >> 2] = i6;
michael@0 42249 HEAP32[i2 + 4 >> 2] = i5;
michael@0 42250 }
michael@0 42251 i5 = i2 + 8 | 0;
michael@0 42252 HEAP32[i5 >> 2] = 0;
michael@0 42253 HEAP32[i5 + 4 >> 2] = 0;
michael@0 42254 i5 = (HEAP32[i13 >> 2] | 0) + (i20 << 2) | 0;
michael@0 42255 HEAP32[(HEAP32[i1 + 64 >> 2] | 0) + (i7 << 2) >> 2] = HEAP32[i5 >> 2];
michael@0 42256 HEAP32[i5 >> 2] = i7;
michael@0 42257 i19 = i2;
michael@0 42258 return i19 | 0;
michael@0 42259 }
michael@0 42260 function __ZNK15btTriangleShape8isInsideERK9btVector3f(i1, i2, d3) {
michael@0 42261 i1 = i1 | 0;
michael@0 42262 i2 = i2 | 0;
michael@0 42263 d3 = +d3;
michael@0 42264 var i4 = 0, i5 = 0, i6 = 0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0, i25 = 0, i26 = 0, i27 = 0, i28 = 0, i29 = 0;
michael@0 42265 i4 = STACKTOP;
michael@0 42266 STACKTOP = STACKTOP + 32 | 0;
michael@0 42267 i5 = i4 | 0;
michael@0 42268 i6 = i4 + 16 | 0;
michael@0 42269 d7 = +HEAPF32[i1 + 56 >> 2];
michael@0 42270 d8 = +HEAPF32[i1 + 72 >> 2] - d7;
michael@0 42271 d9 = +HEAPF32[i1 + 60 >> 2];
michael@0 42272 d10 = +HEAPF32[i1 + 76 >> 2] - d9;
michael@0 42273 d11 = +HEAPF32[i1 + 64 >> 2];
michael@0 42274 d12 = +HEAPF32[i1 + 80 >> 2] - d11;
michael@0 42275 d13 = +HEAPF32[i1 + 88 >> 2] - d7;
michael@0 42276 d14 = +HEAPF32[i1 + 92 >> 2] - d9;
michael@0 42277 d15 = +HEAPF32[i1 + 96 >> 2] - d11;
michael@0 42278 d16 = d10 * d15 - d12 * d14;
michael@0 42279 d17 = d12 * d13 - d8 * d15;
michael@0 42280 d15 = d8 * d14 - d10 * d13;
michael@0 42281 d13 = 1.0 / +Math_sqrt(+(d15 * d15 + (d16 * d16 + d17 * d17)));
michael@0 42282 d10 = d13 * d16;
michael@0 42283 d16 = d13 * d17;
michael@0 42284 d17 = d15 * d13;
michael@0 42285 i18 = i2 | 0;
michael@0 42286 i19 = i2 + 4 | 0;
michael@0 42287 i20 = i2 + 8 | 0;
michael@0 42288 d13 = +HEAPF32[i18 >> 2] * d10 + +HEAPF32[i19 >> 2] * d16 + d17 * +HEAPF32[i20 >> 2] - (d11 * d17 + (d7 * d10 + d9 * d16));
michael@0 42289 d9 = -0.0 - d3;
michael@0 42290 if (d13 < d9 | d13 > d3) {
michael@0 42291 i21 = 0;
michael@0 42292 STACKTOP = i4;
michael@0 42293 return i21 | 0;
michael@0 42294 }
michael@0 42295 i2 = i1;
michael@0 42296 i22 = i6 | 0;
michael@0 42297 i23 = i5 | 0;
michael@0 42298 i24 = i6 + 4 | 0;
michael@0 42299 i25 = i5 + 4 | 0;
michael@0 42300 i26 = i6 + 8 | 0;
michael@0 42301 i27 = i5 + 8 | 0;
michael@0 42302 i28 = 0;
michael@0 42303 while (1) {
michael@0 42304 if ((i28 | 0) >= 3) {
michael@0 42305 i21 = 1;
michael@0 42306 i29 = 139;
michael@0 42307 break;
michael@0 42308 }
michael@0 42309 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 96 >> 2] & 127](i1, i28, i5, i6);
michael@0 42310 d3 = +HEAPF32[i23 >> 2];
michael@0 42311 d13 = +HEAPF32[i22 >> 2] - d3;
michael@0 42312 d7 = +HEAPF32[i25 >> 2];
michael@0 42313 d11 = +HEAPF32[i24 >> 2] - d7;
michael@0 42314 d15 = +HEAPF32[i27 >> 2];
michael@0 42315 d14 = +HEAPF32[i26 >> 2] - d15;
michael@0 42316 d8 = d17 * d11 - d16 * d14;
michael@0 42317 d12 = d10 * d14 - d17 * d13;
michael@0 42318 d14 = d16 * d13 - d10 * d11;
michael@0 42319 d11 = 1.0 / +Math_sqrt(+(d14 * d14 + (d8 * d8 + d12 * d12)));
michael@0 42320 d13 = d11 * d8;
michael@0 42321 d8 = d11 * d12;
michael@0 42322 d12 = d14 * d11;
michael@0 42323 if (+HEAPF32[i18 >> 2] * d13 + +HEAPF32[i19 >> 2] * d8 + d12 * +HEAPF32[i20 >> 2] - (d15 * d12 + (d3 * d13 + d7 * d8)) < d9) {
michael@0 42324 i21 = 0;
michael@0 42325 i29 = 140;
michael@0 42326 break;
michael@0 42327 } else {
michael@0 42328 i28 = i28 + 1 | 0;
michael@0 42329 }
michael@0 42330 }
michael@0 42331 if ((i29 | 0) == 139) {
michael@0 42332 STACKTOP = i4;
michael@0 42333 return i21 | 0;
michael@0 42334 } else if ((i29 | 0) == 140) {
michael@0 42335 STACKTOP = i4;
michael@0 42336 return i21 | 0;
michael@0 42337 }
michael@0 42338 return 0;
michael@0 42339 }
michael@0 42340 function __ZZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_EN21MyNodeOverlapCallback11processNodeEii(i1, i2, i3) {
michael@0 42341 i1 = i1 | 0;
michael@0 42342 i2 = i2 | 0;
michael@0 42343 i3 = i3 | 0;
michael@0 42344 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, d20 = 0.0, d21 = 0.0;
michael@0 42345 i4 = STACKTOP;
michael@0 42346 STACKTOP = STACKTOP + 112 | 0;
michael@0 42347 i5 = i4 | 0;
michael@0 42348 i6 = i4 + 48 | 0;
michael@0 42349 i7 = i4 + 64 | 0;
michael@0 42350 i8 = i4 + 72 | 0;
michael@0 42351 i9 = i4 + 80 | 0;
michael@0 42352 i10 = i4 + 88 | 0;
michael@0 42353 i11 = i4 + 104 | 0;
michael@0 42354 i12 = i1 + 4 | 0;
michael@0 42355 i13 = HEAP32[i12 >> 2] | 0;
michael@0 42356 FUNCTION_TABLE_viiiiiiiiii[HEAP32[(HEAP32[i13 >> 2] | 0) + 16 >> 2] & 3](i13, i6, i4 + 56 | 0, i7, i8, i9, i10, i4 + 96 | 0, i11, i2);
michael@0 42357 i13 = HEAP32[i9 >> 2] | 0;
michael@0 42358 i9 = i13 + (Math_imul(HEAP32[i10 >> 2] | 0, i3) | 0) | 0;
michael@0 42359 i10 = i9;
michael@0 42360 i13 = HEAP32[i12 >> 2] | 0;
michael@0 42361 i14 = (HEAP32[i11 >> 2] | 0) == 3;
michael@0 42362 i11 = i9;
michael@0 42363 i9 = (HEAP32[i7 >> 2] | 0) == 0;
michael@0 42364 i7 = HEAP32[i6 >> 2] | 0;
michael@0 42365 i6 = i13 + 4 | 0;
michael@0 42366 i15 = i13 + 8 | 0;
michael@0 42367 i16 = i13 + 12 | 0;
michael@0 42368 i13 = 2;
michael@0 42369 while (1) {
michael@0 42370 if (i14) {
michael@0 42371 i17 = HEAPU16[i11 + (i13 << 1) >> 1] | 0;
michael@0 42372 } else {
michael@0 42373 i17 = HEAP32[i10 + (i13 << 2) >> 2] | 0;
michael@0 42374 }
michael@0 42375 i18 = Math_imul(HEAP32[i8 >> 2] | 0, i17) | 0;
michael@0 42376 i19 = i7 + i18 | 0;
michael@0 42377 if (i9) {
michael@0 42378 d20 = +HEAPF32[i7 + (i18 + 4) >> 2] * +HEAPF32[i15 >> 2];
michael@0 42379 d21 = +HEAPF32[i7 + (i18 + 8) >> 2] * +HEAPF32[i16 >> 2];
michael@0 42380 HEAPF32[i5 + (i13 << 4) >> 2] = +HEAPF32[i19 >> 2] * +HEAPF32[i6 >> 2];
michael@0 42381 HEAPF32[i5 + (i13 << 4) + 4 >> 2] = d20;
michael@0 42382 HEAPF32[i5 + (i13 << 4) + 8 >> 2] = d21;
michael@0 42383 HEAPF32[i5 + (i13 << 4) + 12 >> 2] = 0.0;
michael@0 42384 } else {
michael@0 42385 d21 = +HEAPF64[i7 + (i18 + 8) >> 3] * +HEAPF32[i15 >> 2];
michael@0 42386 d20 = +HEAPF64[i7 + (i18 + 16) >> 3] * +HEAPF32[i16 >> 2];
michael@0 42387 HEAPF32[i5 + (i13 << 4) >> 2] = +HEAPF64[i19 >> 3] * +HEAPF32[i6 >> 2];
michael@0 42388 HEAPF32[i5 + (i13 << 4) + 4 >> 2] = d21;
michael@0 42389 HEAPF32[i5 + (i13 << 4) + 8 >> 2] = d20;
michael@0 42390 HEAPF32[i5 + (i13 << 4) + 12 >> 2] = 0.0;
michael@0 42391 }
michael@0 42392 if ((i13 | 0) > 0) {
michael@0 42393 i13 = i13 - 1 | 0;
michael@0 42394 } else {
michael@0 42395 break;
michael@0 42396 }
michael@0 42397 }
michael@0 42398 i13 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 42399 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i13 >> 2] | 0) + 8 >> 2] & 127](i13, i5 | 0, i2, i3);
michael@0 42400 i3 = HEAP32[i12 >> 2] | 0;
michael@0 42401 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 24 >> 2] & 127](i3, i2);
michael@0 42402 STACKTOP = i4;
michael@0 42403 return;
michael@0 42404 }
michael@0 42405 function __ZN25btSimulationIslandManager10findUnionsEP12btDispatcherP16btCollisionWorld(i1, i2, i3) {
michael@0 42406 i1 = i1 | 0;
michael@0 42407 i2 = i2 | 0;
michael@0 42408 i3 = i3 | 0;
michael@0 42409 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 42410 i2 = HEAP32[i3 + 76 >> 2] | 0;
michael@0 42411 i3 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i2 >> 2] | 0) + 36 >> 2] & 127](i2) | 0;
michael@0 42412 i2 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 36 >> 2] & 127](i3) | 0;
michael@0 42413 i4 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 20 >> 2] & 127](i3) | 0;
michael@0 42414 if ((i2 | 0) <= 0) {
michael@0 42415 return;
michael@0 42416 }
michael@0 42417 i3 = i1 + 16 | 0;
michael@0 42418 i1 = 0;
michael@0 42419 do {
michael@0 42420 i5 = HEAP32[HEAP32[i4 + (i1 << 4) >> 2] >> 2] | 0;
michael@0 42421 i6 = HEAP32[HEAP32[i4 + (i1 << 4) + 4 >> 2] >> 2] | 0;
michael@0 42422 do {
michael@0 42423 if ((i5 | 0) != 0) {
michael@0 42424 if ((HEAP32[i5 + 204 >> 2] & 7 | 0) != 0 | (i6 | 0) == 0) {
michael@0 42425 break;
michael@0 42426 }
michael@0 42427 if ((HEAP32[i6 + 204 >> 2] & 7 | 0) != 0) {
michael@0 42428 break;
michael@0 42429 }
michael@0 42430 i7 = HEAP32[i5 + 208 >> 2] | 0;
michael@0 42431 i8 = HEAP32[i6 + 208 >> 2] | 0;
michael@0 42432 i9 = HEAP32[i3 >> 2] | 0;
michael@0 42433 i10 = i9 + (i7 << 3) | 0;
michael@0 42434 i11 = HEAP32[i10 >> 2] | 0;
michael@0 42435 if ((i11 | 0) == (i7 | 0)) {
michael@0 42436 i12 = i7;
michael@0 42437 } else {
michael@0 42438 i7 = i10;
michael@0 42439 i10 = i11;
michael@0 42440 while (1) {
michael@0 42441 i11 = i9 + (i10 << 3) | 0;
michael@0 42442 HEAP32[i7 >> 2] = HEAP32[i11 >> 2];
michael@0 42443 i13 = HEAP32[i11 >> 2] | 0;
michael@0 42444 i11 = i9 + (i13 << 3) | 0;
michael@0 42445 i14 = HEAP32[i11 >> 2] | 0;
michael@0 42446 if ((i13 | 0) == (i14 | 0)) {
michael@0 42447 i12 = i13;
michael@0 42448 break;
michael@0 42449 } else {
michael@0 42450 i7 = i11;
michael@0 42451 i10 = i14;
michael@0 42452 }
michael@0 42453 }
michael@0 42454 }
michael@0 42455 i10 = i9 + (i8 << 3) | 0;
michael@0 42456 i7 = HEAP32[i10 >> 2] | 0;
michael@0 42457 if ((i7 | 0) == (i8 | 0)) {
michael@0 42458 i15 = i8;
michael@0 42459 } else {
michael@0 42460 i14 = i10;
michael@0 42461 i10 = i7;
michael@0 42462 while (1) {
michael@0 42463 i7 = i9 + (i10 << 3) | 0;
michael@0 42464 HEAP32[i14 >> 2] = HEAP32[i7 >> 2];
michael@0 42465 i11 = HEAP32[i7 >> 2] | 0;
michael@0 42466 i7 = i9 + (i11 << 3) | 0;
michael@0 42467 i13 = HEAP32[i7 >> 2] | 0;
michael@0 42468 if ((i11 | 0) == (i13 | 0)) {
michael@0 42469 i15 = i11;
michael@0 42470 break;
michael@0 42471 } else {
michael@0 42472 i14 = i7;
michael@0 42473 i10 = i13;
michael@0 42474 }
michael@0 42475 }
michael@0 42476 }
michael@0 42477 if ((i12 | 0) == (i15 | 0)) {
michael@0 42478 break;
michael@0 42479 }
michael@0 42480 HEAP32[i9 + (i12 << 3) >> 2] = i15;
michael@0 42481 i10 = i9 + (i15 << 3) + 4 | 0;
michael@0 42482 HEAP32[i10 >> 2] = (HEAP32[i10 >> 2] | 0) + (HEAP32[i9 + (i12 << 3) + 4 >> 2] | 0);
michael@0 42483 }
michael@0 42484 } while (0);
michael@0 42485 i1 = i1 + 1 | 0;
michael@0 42486 } while ((i1 | 0) < (i2 | 0));
michael@0 42487 return;
michael@0 42488 }
michael@0 42489 function __ZZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_EN21MyNodeOverlapCallback11processNodeEii(i1, i2, i3) {
michael@0 42490 i1 = i1 | 0;
michael@0 42491 i2 = i2 | 0;
michael@0 42492 i3 = i3 | 0;
michael@0 42493 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, d20 = 0.0, d21 = 0.0;
michael@0 42494 i4 = STACKTOP;
michael@0 42495 STACKTOP = STACKTOP + 112 | 0;
michael@0 42496 i5 = i4 | 0;
michael@0 42497 i6 = i4 + 48 | 0;
michael@0 42498 i7 = i4 + 64 | 0;
michael@0 42499 i8 = i4 + 72 | 0;
michael@0 42500 i9 = i4 + 80 | 0;
michael@0 42501 i10 = i4 + 88 | 0;
michael@0 42502 i11 = i4 + 104 | 0;
michael@0 42503 i12 = i1 + 4 | 0;
michael@0 42504 i13 = HEAP32[i12 >> 2] | 0;
michael@0 42505 FUNCTION_TABLE_viiiiiiiiii[HEAP32[(HEAP32[i13 >> 2] | 0) + 16 >> 2] & 3](i13, i6, i4 + 56 | 0, i7, i8, i9, i10, i4 + 96 | 0, i11, i2);
michael@0 42506 i13 = HEAP32[i9 >> 2] | 0;
michael@0 42507 i9 = i13 + (Math_imul(HEAP32[i10 >> 2] | 0, i3) | 0) | 0;
michael@0 42508 i10 = i9;
michael@0 42509 i13 = HEAP32[i12 >> 2] | 0;
michael@0 42510 i14 = (HEAP32[i11 >> 2] | 0) == 3;
michael@0 42511 i11 = i9;
michael@0 42512 i9 = (HEAP32[i7 >> 2] | 0) == 0;
michael@0 42513 i7 = HEAP32[i6 >> 2] | 0;
michael@0 42514 i6 = i13 + 4 | 0;
michael@0 42515 i15 = i13 + 8 | 0;
michael@0 42516 i16 = i13 + 12 | 0;
michael@0 42517 i13 = 2;
michael@0 42518 while (1) {
michael@0 42519 if (i14) {
michael@0 42520 i17 = HEAPU16[i11 + (i13 << 1) >> 1] | 0;
michael@0 42521 } else {
michael@0 42522 i17 = HEAP32[i10 + (i13 << 2) >> 2] | 0;
michael@0 42523 }
michael@0 42524 i18 = Math_imul(HEAP32[i8 >> 2] | 0, i17) | 0;
michael@0 42525 i19 = i7 + i18 | 0;
michael@0 42526 if (i9) {
michael@0 42527 d20 = +HEAPF32[i7 + (i18 + 4) >> 2] * +HEAPF32[i15 >> 2];
michael@0 42528 d21 = +HEAPF32[i7 + (i18 + 8) >> 2] * +HEAPF32[i16 >> 2];
michael@0 42529 HEAPF32[i5 + (i13 << 4) >> 2] = +HEAPF32[i19 >> 2] * +HEAPF32[i6 >> 2];
michael@0 42530 HEAPF32[i5 + (i13 << 4) + 4 >> 2] = d20;
michael@0 42531 HEAPF32[i5 + (i13 << 4) + 8 >> 2] = d21;
michael@0 42532 HEAPF32[i5 + (i13 << 4) + 12 >> 2] = 0.0;
michael@0 42533 } else {
michael@0 42534 d21 = +HEAPF64[i7 + (i18 + 8) >> 3] * +HEAPF32[i15 >> 2];
michael@0 42535 d20 = +HEAPF64[i7 + (i18 + 16) >> 3] * +HEAPF32[i16 >> 2];
michael@0 42536 HEAPF32[i5 + (i13 << 4) >> 2] = +HEAPF64[i19 >> 3] * +HEAPF32[i6 >> 2];
michael@0 42537 HEAPF32[i5 + (i13 << 4) + 4 >> 2] = d21;
michael@0 42538 HEAPF32[i5 + (i13 << 4) + 8 >> 2] = d20;
michael@0 42539 HEAPF32[i5 + (i13 << 4) + 12 >> 2] = 0.0;
michael@0 42540 }
michael@0 42541 if ((i13 | 0) > 0) {
michael@0 42542 i13 = i13 - 1 | 0;
michael@0 42543 } else {
michael@0 42544 break;
michael@0 42545 }
michael@0 42546 }
michael@0 42547 i13 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 42548 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i13 >> 2] | 0) + 8 >> 2] & 127](i13, i5 | 0, i2, i3);
michael@0 42549 i3 = HEAP32[i12 >> 2] | 0;
michael@0 42550 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 24 >> 2] & 127](i3, i2);
michael@0 42551 STACKTOP = i4;
michael@0 42552 return;
michael@0 42553 }
michael@0 42554 function __ZNK11btMatrix3x311getRotationER12btQuaternion(i1, i2) {
michael@0 42555 i1 = i1 | 0;
michael@0 42556 i2 = i2 | 0;
michael@0 42557 var i3 = 0, i4 = 0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0, i24 = 0;
michael@0 42558 i3 = STACKTOP;
michael@0 42559 STACKTOP = STACKTOP + 16 | 0;
michael@0 42560 i4 = i3 | 0;
michael@0 42561 d5 = +HEAPF32[i1 >> 2];
michael@0 42562 d6 = +HEAPF32[i1 + 20 >> 2];
michael@0 42563 d7 = +HEAPF32[i1 + 40 >> 2];
michael@0 42564 d8 = d5 + d6 + d7;
michael@0 42565 if (d8 > 0.0) {
michael@0 42566 d9 = +Math_sqrt(+(d8 + 1.0));
michael@0 42567 d8 = d9 * .5;
michael@0 42568 HEAPF32[i4 + 12 >> 2] = d8;
michael@0 42569 d10 = .5 / d9;
michael@0 42570 d9 = d10 * (+HEAPF32[i1 + 36 >> 2] - +HEAPF32[i1 + 24 >> 2]);
michael@0 42571 HEAPF32[i4 >> 2] = d9;
michael@0 42572 d11 = d10 * (+HEAPF32[i1 + 8 >> 2] - +HEAPF32[i1 + 32 >> 2]);
michael@0 42573 HEAPF32[i4 + 4 >> 2] = d11;
michael@0 42574 d12 = d10 * (+HEAPF32[i1 + 16 >> 2] - +HEAPF32[i1 + 4 >> 2]);
michael@0 42575 HEAPF32[i4 + 8 >> 2] = d12;
michael@0 42576 d13 = d9;
michael@0 42577 d14 = d11;
michael@0 42578 d15 = d12;
michael@0 42579 d16 = d8;
michael@0 42580 i17 = i2 | 0;
michael@0 42581 HEAPF32[i17 >> 2] = d13;
michael@0 42582 i18 = i2 + 4 | 0;
michael@0 42583 HEAPF32[i18 >> 2] = d14;
michael@0 42584 i19 = i2 + 8 | 0;
michael@0 42585 HEAPF32[i19 >> 2] = d15;
michael@0 42586 i20 = i2 + 12 | 0;
michael@0 42587 HEAPF32[i20 >> 2] = d16;
michael@0 42588 STACKTOP = i3;
michael@0 42589 return;
michael@0 42590 }
michael@0 42591 if (d5 < d6) {
michael@0 42592 i21 = d6 < d7 ? 2 : 1;
michael@0 42593 } else {
michael@0 42594 i21 = d5 < d7 ? 2 : 0;
michael@0 42595 }
michael@0 42596 i22 = ((i21 + 1 | 0) >>> 0) % 3 | 0;
michael@0 42597 i23 = ((i21 + 2 | 0) >>> 0) % 3 | 0;
michael@0 42598 d7 = +Math_sqrt(+(+HEAPF32[i1 + (i21 << 4) + (i21 << 2) >> 2] - +HEAPF32[i1 + (i22 << 4) + (i22 << 2) >> 2] - +HEAPF32[i1 + (i23 << 4) + (i23 << 2) >> 2] + 1.0));
michael@0 42599 HEAPF32[i4 + (i21 << 2) >> 2] = d7 * .5;
michael@0 42600 d5 = .5 / d7;
michael@0 42601 i24 = i4 + 12 | 0;
michael@0 42602 HEAPF32[i24 >> 2] = d5 * (+HEAPF32[i1 + (i23 << 4) + (i22 << 2) >> 2] - +HEAPF32[i1 + (i22 << 4) + (i23 << 2) >> 2]);
michael@0 42603 HEAPF32[i4 + (i22 << 2) >> 2] = d5 * (+HEAPF32[i1 + (i22 << 4) + (i21 << 2) >> 2] + +HEAPF32[i1 + (i21 << 4) + (i22 << 2) >> 2]);
michael@0 42604 HEAPF32[i4 + (i23 << 2) >> 2] = d5 * (+HEAPF32[i1 + (i23 << 4) + (i21 << 2) >> 2] + +HEAPF32[i1 + (i21 << 4) + (i23 << 2) >> 2]);
michael@0 42605 d13 = +HEAPF32[i4 >> 2];
michael@0 42606 d14 = +HEAPF32[i4 + 4 >> 2];
michael@0 42607 d15 = +HEAPF32[i4 + 8 >> 2];
michael@0 42608 d16 = +HEAPF32[i24 >> 2];
michael@0 42609 i17 = i2 | 0;
michael@0 42610 HEAPF32[i17 >> 2] = d13;
michael@0 42611 i18 = i2 + 4 | 0;
michael@0 42612 HEAPF32[i18 >> 2] = d14;
michael@0 42613 i19 = i2 + 8 | 0;
michael@0 42614 HEAPF32[i19 >> 2] = d15;
michael@0 42615 i20 = i2 + 12 | 0;
michael@0 42616 HEAPF32[i20 >> 2] = d16;
michael@0 42617 STACKTOP = i3;
michael@0 42618 return;
michael@0 42619 }
michael@0 42620 function __ZN24btConvexTriangleCallback15processTriangleEP9btVector3ii(i1, i2, i3, i4) {
michael@0 42621 i1 = i1 | 0;
michael@0 42622 i2 = i2 | 0;
michael@0 42623 i3 = i3 | 0;
michael@0 42624 i4 = i4 | 0;
michael@0 42625 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 42626 i5 = STACKTOP;
michael@0 42627 STACKTOP = STACKTOP + 104 | 0;
michael@0 42628 i6 = i5 | 0;
michael@0 42629 i7 = HEAP32[i1 + 48 >> 2] | 0;
michael@0 42630 i8 = i1 + 8 | 0;
michael@0 42631 i9 = i1 + 4 | 0;
michael@0 42632 if ((HEAP32[(HEAP32[(HEAP32[i9 >> 2] | 0) + 192 >> 2] | 0) + 4 >> 2] | 0) >= 20) {
michael@0 42633 STACKTOP = i5;
michael@0 42634 return;
michael@0 42635 }
michael@0 42636 i10 = HEAP32[i8 >> 2] | 0;
michael@0 42637 i11 = i6 | 0;
michael@0 42638 __ZN23btPolyhedralConvexShapeC2Ev(i11);
michael@0 42639 HEAP32[i6 >> 2] = 4560;
michael@0 42640 HEAP32[i6 + 4 >> 2] = 1;
michael@0 42641 i12 = i6 + 56 | 0;
michael@0 42642 i13 = i2;
michael@0 42643 HEAP32[i12 >> 2] = HEAP32[i13 >> 2];
michael@0 42644 HEAP32[i12 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 42645 HEAP32[i12 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 42646 HEAP32[i12 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 42647 i13 = i6 + 72 | 0;
michael@0 42648 i12 = i2 + 16 | 0;
michael@0 42649 HEAP32[i13 >> 2] = HEAP32[i12 >> 2];
michael@0 42650 HEAP32[i13 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 42651 HEAP32[i13 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 42652 HEAP32[i13 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 42653 i12 = i6 + 88 | 0;
michael@0 42654 i13 = i2 + 32 | 0;
michael@0 42655 HEAP32[i12 >> 2] = HEAP32[i13 >> 2];
michael@0 42656 HEAP32[i12 + 4 >> 2] = HEAP32[i13 + 4 >> 2];
michael@0 42657 HEAP32[i12 + 8 >> 2] = HEAP32[i13 + 8 >> 2];
michael@0 42658 HEAP32[i12 + 12 >> 2] = HEAP32[i13 + 12 >> 2];
michael@0 42659 HEAPF32[i6 + 44 >> 2] = +HEAPF32[i1 + 56 >> 2];
michael@0 42660 i13 = i10 + 192 | 0;
michael@0 42661 i10 = HEAP32[i13 >> 2] | 0;
michael@0 42662 HEAP32[i13 >> 2] = i6;
michael@0 42663 i6 = FUNCTION_TABLE_iiiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 8 >> 2] & 31](i7, HEAP32[i9 >> 2] | 0, HEAP32[i8 >> 2] | 0, HEAP32[i1 + 64 >> 2] | 0) | 0;
michael@0 42664 i12 = i1 + 44 | 0;
michael@0 42665 i2 = HEAP32[i12 >> 2] | 0;
michael@0 42666 i14 = HEAP32[i2 >> 2] | 0;
michael@0 42667 if ((HEAP32[i2 + 136 >> 2] | 0) == (HEAP32[i8 >> 2] | 0)) {
michael@0 42668 FUNCTION_TABLE_viii[HEAP32[i14 + 8 >> 2] & 127](i2, i3, i4);
michael@0 42669 } else {
michael@0 42670 FUNCTION_TABLE_viii[HEAP32[i14 + 12 >> 2] & 127](i2, i3, i4);
michael@0 42671 }
michael@0 42672 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 63](i6, HEAP32[i9 >> 2] | 0, HEAP32[i8 >> 2] | 0, HEAP32[i1 + 52 >> 2] | 0, HEAP32[i12 >> 2] | 0);
michael@0 42673 FUNCTION_TABLE_vi[HEAP32[HEAP32[i6 >> 2] >> 2] & 511](i6);
michael@0 42674 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i7 >> 2] | 0) + 60 >> 2] & 127](i7, i6);
michael@0 42675 HEAP32[i13 >> 2] = i10;
michael@0 42676 __ZN23btPolyhedralConvexShapeD2Ev(i11);
michael@0 42677 STACKTOP = i5;
michael@0 42678 return;
michael@0 42679 }
michael@0 42680 function __ZN28btCompoundCollisionAlgorithm26preallocateChildAlgorithmsEP17btCollisionObjectS1_(i1, i2, i3) {
michael@0 42681 i1 = i1 | 0;
michael@0 42682 i2 = i2 | 0;
michael@0 42683 i3 = i3 | 0;
michael@0 42684 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 42685 i4 = (HEAP8[i1 + 28 | 0] | 0) != 0;
michael@0 42686 i5 = i4 ? i3 : i2;
michael@0 42687 i6 = i4 ? i2 : i3;
michael@0 42688 i3 = i5 + 192 | 0;
michael@0 42689 i2 = HEAP32[i3 >> 2] | 0;
michael@0 42690 i4 = HEAP32[i2 + 16 >> 2] | 0;
michael@0 42691 i7 = i1 + 12 | 0;
michael@0 42692 i8 = HEAP32[i7 >> 2] | 0;
michael@0 42693 if ((i8 | 0) < (i4 | 0)) {
michael@0 42694 i9 = i1 + 16 | 0;
michael@0 42695 if ((HEAP32[i9 >> 2] | 0) < (i4 | 0)) {
michael@0 42696 if ((i4 | 0) == 0) {
michael@0 42697 i10 = 0;
michael@0 42698 i11 = i8;
michael@0 42699 } else {
michael@0 42700 i12 = __Z22btAlignedAllocInternalji(i4 << 2, 16) | 0;
michael@0 42701 i10 = i12;
michael@0 42702 i11 = HEAP32[i7 >> 2] | 0;
michael@0 42703 }
michael@0 42704 i12 = i1 + 20 | 0;
michael@0 42705 if ((i11 | 0) > 0) {
michael@0 42706 i13 = 0;
michael@0 42707 do {
michael@0 42708 i14 = i10 + (i13 << 2) | 0;
michael@0 42709 if ((i14 | 0) != 0) {
michael@0 42710 HEAP32[i14 >> 2] = HEAP32[(HEAP32[i12 >> 2] | 0) + (i13 << 2) >> 2];
michael@0 42711 }
michael@0 42712 i13 = i13 + 1 | 0;
michael@0 42713 } while ((i13 | 0) < (i11 | 0));
michael@0 42714 }
michael@0 42715 i11 = HEAP32[i12 >> 2] | 0;
michael@0 42716 i13 = i1 + 24 | 0;
michael@0 42717 if ((i11 | 0) != 0) {
michael@0 42718 if ((HEAP8[i13] | 0) != 0) {
michael@0 42719 __Z21btAlignedFreeInternalPv(i11);
michael@0 42720 }
michael@0 42721 HEAP32[i12 >> 2] = 0;
michael@0 42722 }
michael@0 42723 HEAP8[i13] = 1;
michael@0 42724 HEAP32[i12 >> 2] = i10;
michael@0 42725 HEAP32[i9 >> 2] = i4;
michael@0 42726 i15 = i12;
michael@0 42727 } else {
michael@0 42728 i15 = i1 + 20 | 0;
michael@0 42729 }
michael@0 42730 i12 = i8;
michael@0 42731 do {
michael@0 42732 i8 = (HEAP32[i15 >> 2] | 0) + (i12 << 2) | 0;
michael@0 42733 if ((i8 | 0) != 0) {
michael@0 42734 HEAP32[i8 >> 2] = 0;
michael@0 42735 }
michael@0 42736 i12 = i12 + 1 | 0;
michael@0 42737 } while ((i12 | 0) < (i4 | 0));
michael@0 42738 }
michael@0 42739 HEAP32[i7 >> 2] = i4;
michael@0 42740 if ((i4 | 0) <= 0) {
michael@0 42741 return;
michael@0 42742 }
michael@0 42743 i7 = i2 + 64 | 0;
michael@0 42744 i12 = i2 + 24 | 0;
michael@0 42745 i2 = i1 + 4 | 0;
michael@0 42746 i15 = i1 + 32 | 0;
michael@0 42747 i8 = i1 + 20 | 0;
michael@0 42748 i1 = 0;
michael@0 42749 do {
michael@0 42750 if ((HEAP32[i7 >> 2] | 0) == 0) {
michael@0 42751 i9 = HEAP32[i3 >> 2] | 0;
michael@0 42752 HEAP32[i3 >> 2] = HEAP32[(HEAP32[i12 >> 2] | 0) + (i1 * 80 | 0) + 64 >> 2];
michael@0 42753 i10 = HEAP32[i2 >> 2] | 0;
michael@0 42754 i13 = FUNCTION_TABLE_iiiii[HEAP32[(HEAP32[i10 >> 2] | 0) + 8 >> 2] & 31](i10, i5, i6, HEAP32[i15 >> 2] | 0) | 0;
michael@0 42755 HEAP32[(HEAP32[i8 >> 2] | 0) + (i1 << 2) >> 2] = i13;
michael@0 42756 HEAP32[i3 >> 2] = i9;
michael@0 42757 } else {
michael@0 42758 HEAP32[(HEAP32[i8 >> 2] | 0) + (i1 << 2) >> 2] = 0;
michael@0 42759 }
michael@0 42760 i1 = i1 + 1 | 0;
michael@0 42761 } while ((i1 | 0) < (i4 | 0));
michael@0 42762 return;
michael@0 42763 }
michael@0 42764 function __ZN35btSequentialImpulseConstraintSolver45solveGroupCacheFriendlySplitImpulseIterationsEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
michael@0 42765 i1 = i1 | 0;
michael@0 42766 i2 = i2 | 0;
michael@0 42767 i3 = i3 | 0;
michael@0 42768 i4 = i4 | 0;
michael@0 42769 i5 = i5 | 0;
michael@0 42770 i6 = i6 | 0;
michael@0 42771 i7 = i7 | 0;
michael@0 42772 i8 = i8 | 0;
michael@0 42773 i9 = i9 | 0;
michael@0 42774 i10 = i10 | 0;
michael@0 42775 var i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 42776 if ((HEAP32[i8 + 44 >> 2] | 0) == 0) {
michael@0 42777 return;
michael@0 42778 }
michael@0 42779 i10 = i8 + 20 | 0;
michael@0 42780 i9 = HEAP32[i10 >> 2] | 0;
michael@0 42781 i7 = (i9 | 0) > 0;
michael@0 42782 if ((HEAP32[i8 + 60 >> 2] & 256 | 0) == 0) {
michael@0 42783 if (!i7) {
michael@0 42784 return;
michael@0 42785 }
michael@0 42786 i8 = i1 + 8 | 0;
michael@0 42787 i6 = i1 + 76 | 0;
michael@0 42788 i5 = i1 + 16 | 0;
michael@0 42789 i4 = 1;
michael@0 42790 i3 = i9;
michael@0 42791 while (1) {
michael@0 42792 i2 = HEAP32[i8 >> 2] | 0;
michael@0 42793 if ((i2 | 0) > 0) {
michael@0 42794 i11 = 0;
michael@0 42795 do {
michael@0 42796 i12 = HEAP32[(HEAP32[i6 >> 2] | 0) + (i11 << 2) >> 2] | 0;
michael@0 42797 i13 = HEAP32[i5 >> 2] | 0;
michael@0 42798 __ZN35btSequentialImpulseConstraintSolver43resolveSplitPenetrationImpulseCacheFriendlyER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i13 + (i12 * 136 | 0) + 104 >> 2] | 0, HEAP32[i13 + (i12 * 136 | 0) + 108 >> 2] | 0, i13 + (i12 * 136 | 0) | 0);
michael@0 42799 i11 = i11 + 1 | 0;
michael@0 42800 } while ((i11 | 0) < (i2 | 0));
michael@0 42801 i14 = HEAP32[i10 >> 2] | 0;
michael@0 42802 } else {
michael@0 42803 i14 = i3;
michael@0 42804 }
michael@0 42805 if ((i4 | 0) >= (i14 | 0)) {
michael@0 42806 break;
michael@0 42807 }
michael@0 42808 i4 = i4 + 1 | 0;
michael@0 42809 i3 = i14;
michael@0 42810 }
michael@0 42811 return;
michael@0 42812 } else {
michael@0 42813 if (!i7) {
michael@0 42814 return;
michael@0 42815 }
michael@0 42816 i7 = i1 + 8 | 0;
michael@0 42817 i14 = i1 + 76 | 0;
michael@0 42818 i3 = i1 + 16 | 0;
michael@0 42819 i1 = 1;
michael@0 42820 i4 = i9;
michael@0 42821 while (1) {
michael@0 42822 i9 = HEAP32[i7 >> 2] | 0;
michael@0 42823 if ((i9 | 0) > 0) {
michael@0 42824 i5 = 0;
michael@0 42825 do {
michael@0 42826 i6 = HEAP32[(HEAP32[i14 >> 2] | 0) + (i5 << 2) >> 2] | 0;
michael@0 42827 i8 = HEAP32[i3 >> 2] | 0;
michael@0 42828 __ZN35btSequentialImpulseConstraintSolver43resolveSplitPenetrationImpulseCacheFriendlyER11btRigidBodyS1_RK18btSolverConstraint(0, HEAP32[i8 + (i6 * 136 | 0) + 104 >> 2] | 0, HEAP32[i8 + (i6 * 136 | 0) + 108 >> 2] | 0, i8 + (i6 * 136 | 0) | 0);
michael@0 42829 i5 = i5 + 1 | 0;
michael@0 42830 } while ((i5 | 0) < (i9 | 0));
michael@0 42831 i15 = HEAP32[i10 >> 2] | 0;
michael@0 42832 } else {
michael@0 42833 i15 = i4;
michael@0 42834 }
michael@0 42835 if ((i1 | 0) >= (i15 | 0)) {
michael@0 42836 break;
michael@0 42837 }
michael@0 42838 i1 = i1 + 1 | 0;
michael@0 42839 i4 = i15;
michael@0 42840 }
michael@0 42841 return;
michael@0 42842 }
michael@0 42843 }
michael@0 42844 function __ZN23btDiscreteDynamicsWorld12addRigidBodyEP11btRigidBody(i1, i2) {
michael@0 42845 i1 = i1 | 0;
michael@0 42846 i2 = i2 | 0;
michael@0 42847 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0;
michael@0 42848 i3 = i2 | 0;
michael@0 42849 i4 = i2 + 204 | 0;
michael@0 42850 do {
michael@0 42851 if ((HEAP32[i4 >> 2] & 3 | 0) == 0) {
michael@0 42852 if ((HEAP32[i2 + 496 >> 2] & 1 | 0) != 0) {
michael@0 42853 break;
michael@0 42854 }
michael@0 42855 __ZN11btRigidBody10setGravityERK9btVector3(i2, i1 + 220 | 0);
michael@0 42856 }
michael@0 42857 } while (0);
michael@0 42858 if ((HEAP32[i2 + 192 >> 2] | 0) == 0) {
michael@0 42859 return;
michael@0 42860 }
michael@0 42861 if ((HEAP32[i4 >> 2] & 1 | 0) == 0) {
michael@0 42862 i5 = i1 + 204 | 0;
michael@0 42863 i6 = HEAP32[i5 >> 2] | 0;
michael@0 42864 i7 = i1 + 208 | 0;
michael@0 42865 do {
michael@0 42866 if ((i6 | 0) == (HEAP32[i7 >> 2] | 0)) {
michael@0 42867 i8 = (i6 | 0) == 0 ? 1 : i6 << 1;
michael@0 42868 if ((i6 | 0) >= (i8 | 0)) {
michael@0 42869 i9 = i6;
michael@0 42870 break;
michael@0 42871 }
michael@0 42872 if ((i8 | 0) == 0) {
michael@0 42873 i10 = 0;
michael@0 42874 i11 = i6;
michael@0 42875 } else {
michael@0 42876 i12 = __Z22btAlignedAllocInternalji(i8 << 2, 16) | 0;
michael@0 42877 i10 = i12;
michael@0 42878 i11 = HEAP32[i5 >> 2] | 0;
michael@0 42879 }
michael@0 42880 i12 = i1 + 212 | 0;
michael@0 42881 if ((i11 | 0) > 0) {
michael@0 42882 i13 = 0;
michael@0 42883 do {
michael@0 42884 i14 = i10 + (i13 << 2) | 0;
michael@0 42885 if ((i14 | 0) != 0) {
michael@0 42886 HEAP32[i14 >> 2] = HEAP32[(HEAP32[i12 >> 2] | 0) + (i13 << 2) >> 2];
michael@0 42887 }
michael@0 42888 i13 = i13 + 1 | 0;
michael@0 42889 } while ((i13 | 0) < (i11 | 0));
michael@0 42890 }
michael@0 42891 i13 = HEAP32[i12 >> 2] | 0;
michael@0 42892 i14 = i1 + 216 | 0;
michael@0 42893 if ((i13 | 0) == 0) {
michael@0 42894 i15 = i11;
michael@0 42895 } else {
michael@0 42896 if ((HEAP8[i14] | 0) == 0) {
michael@0 42897 i16 = i11;
michael@0 42898 } else {
michael@0 42899 __Z21btAlignedFreeInternalPv(i13);
michael@0 42900 i16 = HEAP32[i5 >> 2] | 0;
michael@0 42901 }
michael@0 42902 HEAP32[i12 >> 2] = 0;
michael@0 42903 i15 = i16;
michael@0 42904 }
michael@0 42905 HEAP8[i14] = 1;
michael@0 42906 HEAP32[i12 >> 2] = i10;
michael@0 42907 HEAP32[i7 >> 2] = i8;
michael@0 42908 i9 = i15;
michael@0 42909 } else {
michael@0 42910 i9 = i6;
michael@0 42911 }
michael@0 42912 } while (0);
michael@0 42913 i6 = (HEAP32[i1 + 212 >> 2] | 0) + (i9 << 2) | 0;
michael@0 42914 if ((i6 | 0) != 0) {
michael@0 42915 HEAP32[i6 >> 2] = i2;
michael@0 42916 }
michael@0 42917 HEAP32[i5 >> 2] = i9 + 1;
michael@0 42918 } else {
michael@0 42919 __ZN17btCollisionObject18setActivationStateEi(i3, 2);
michael@0 42920 }
michael@0 42921 i9 = HEAP32[i4 >> 2] | 0;
michael@0 42922 if ((i9 & 1 | 0) == 0) {
michael@0 42923 i17 = (i9 & 2 | 0) == 0;
michael@0 42924 } else {
michael@0 42925 i17 = 0;
michael@0 42926 }
michael@0 42927 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 32 >> 2] & 127](i1, i3, i17 ? 1 : 2, i17 ? -1 : -3);
michael@0 42928 return;
michael@0 42929 }
michael@0 42930 function __ZN23btDiscreteDynamicsWorld14debugDrawWorldEv(i1) {
michael@0 42931 i1 = i1 | 0;
michael@0 42932 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 42933 __ZN15CProfileManager13Start_ProfileEPKc(1112);
michael@0 42934 i2 = i1 | 0;
michael@0 42935 __ZN16btCollisionWorld14debugDrawWorldEv(i2);
michael@0 42936 i3 = i1;
michael@0 42937 L167 : do {
michael@0 42938 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i2) | 0) != 0) {
michael@0 42939 i4 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i2) | 0;
michael@0 42940 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i4 >> 2] | 0) + 48 >> 2] & 127](i4) | 0) & 6144 | 0) == 0) {
michael@0 42941 break;
michael@0 42942 }
michael@0 42943 i4 = i1;
michael@0 42944 i5 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 100 >> 2] & 127](i1) | 0;
michael@0 42945 while (1) {
michael@0 42946 i6 = i5 - 1 | 0;
michael@0 42947 if ((i5 | 0) <= 0) {
michael@0 42948 break L167;
michael@0 42949 }
michael@0 42950 __ZN23btDiscreteDynamicsWorld19debugDrawConstraintEP17btTypedConstraint(i1, FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 104 >> 2] & 63](i1, i6) | 0);
michael@0 42951 i5 = i6;
michael@0 42952 }
michael@0 42953 }
michael@0 42954 } while (0);
michael@0 42955 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i2) | 0) == 0) {
michael@0 42956 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 42957 return;
michael@0 42958 }
michael@0 42959 i5 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i2) | 0;
michael@0 42960 if (((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i5 >> 2] | 0) + 48 >> 2] & 127](i5) | 0) & 3 | 0) == 0) {
michael@0 42961 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 42962 return;
michael@0 42963 }
michael@0 42964 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i2) | 0) == 0) {
michael@0 42965 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 42966 return;
michael@0 42967 }
michael@0 42968 i5 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i2) | 0;
michael@0 42969 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i5 >> 2] | 0) + 48 >> 2] & 127](i5) | 0) == 0) {
michael@0 42970 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 42971 return;
michael@0 42972 }
michael@0 42973 i5 = i1 + 248 | 0;
michael@0 42974 if ((HEAP32[i5 >> 2] | 0) <= 0) {
michael@0 42975 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 42976 return;
michael@0 42977 }
michael@0 42978 i2 = i1 + 256 | 0;
michael@0 42979 i3 = i1 + 80 | 0;
michael@0 42980 i1 = 0;
michael@0 42981 do {
michael@0 42982 i4 = HEAP32[(HEAP32[i2 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 42983 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i4 >> 2] | 0) + 12 >> 2] & 127](i4, HEAP32[i3 >> 2] | 0);
michael@0 42984 i1 = i1 + 1 | 0;
michael@0 42985 } while ((i1 | 0) < (HEAP32[i5 >> 2] | 0));
michael@0 42986 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 42987 return;
michael@0 42988 }
michael@0 42989 function __ZNK20btDefaultMotionState17getWorldTransformER11btTransform(i1, i2) {
michael@0 42990 i1 = i1 | 0;
michael@0 42991 i2 = i2 | 0;
michael@0 42992 var d3 = 0.0, d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0;
michael@0 42993 d3 = +HEAPF32[i1 + 68 >> 2];
michael@0 42994 d4 = +HEAPF32[i1 + 84 >> 2];
michael@0 42995 d5 = +HEAPF32[i1 + 100 >> 2];
michael@0 42996 d6 = +HEAPF32[i1 + 72 >> 2];
michael@0 42997 d7 = +HEAPF32[i1 + 88 >> 2];
michael@0 42998 d8 = +HEAPF32[i1 + 104 >> 2];
michael@0 42999 d9 = +HEAPF32[i1 + 76 >> 2];
michael@0 43000 d10 = +HEAPF32[i1 + 92 >> 2];
michael@0 43001 d11 = +HEAPF32[i1 + 108 >> 2];
michael@0 43002 d12 = -0.0 - +HEAPF32[i1 + 116 >> 2];
michael@0 43003 d13 = -0.0 - +HEAPF32[i1 + 120 >> 2];
michael@0 43004 d14 = -0.0 - +HEAPF32[i1 + 124 >> 2];
michael@0 43005 d15 = +HEAPF32[i1 + 4 >> 2];
michael@0 43006 d16 = +HEAPF32[i1 + 20 >> 2];
michael@0 43007 d17 = +HEAPF32[i1 + 36 >> 2];
michael@0 43008 d18 = +HEAPF32[i1 + 8 >> 2];
michael@0 43009 d19 = +HEAPF32[i1 + 24 >> 2];
michael@0 43010 d20 = +HEAPF32[i1 + 40 >> 2];
michael@0 43011 d21 = +HEAPF32[i1 + 12 >> 2];
michael@0 43012 d22 = +HEAPF32[i1 + 28 >> 2];
michael@0 43013 d23 = +HEAPF32[i1 + 44 >> 2];
michael@0 43014 d24 = +HEAPF32[i1 + 52 >> 2];
michael@0 43015 d25 = +HEAPF32[i1 + 56 >> 2];
michael@0 43016 d26 = +HEAPF32[i1 + 60 >> 2];
michael@0 43017 HEAPF32[i2 >> 2] = d3 * d15 + d4 * d16 + d5 * d17;
michael@0 43018 HEAPF32[i2 + 4 >> 2] = d3 * d18 + d4 * d19 + d5 * d20;
michael@0 43019 HEAPF32[i2 + 8 >> 2] = d3 * d21 + d4 * d22 + d5 * d23;
michael@0 43020 HEAPF32[i2 + 12 >> 2] = 0.0;
michael@0 43021 HEAPF32[i2 + 16 >> 2] = d6 * d15 + d7 * d16 + d8 * d17;
michael@0 43022 HEAPF32[i2 + 20 >> 2] = d6 * d18 + d7 * d19 + d8 * d20;
michael@0 43023 HEAPF32[i2 + 24 >> 2] = d6 * d21 + d7 * d22 + d8 * d23;
michael@0 43024 HEAPF32[i2 + 28 >> 2] = 0.0;
michael@0 43025 HEAPF32[i2 + 32 >> 2] = d9 * d15 + d10 * d16 + d11 * d17;
michael@0 43026 HEAPF32[i2 + 36 >> 2] = d9 * d18 + d10 * d19 + d11 * d20;
michael@0 43027 HEAPF32[i2 + 40 >> 2] = d9 * d21 + d10 * d22 + d11 * d23;
michael@0 43028 HEAPF32[i2 + 44 >> 2] = 0.0;
michael@0 43029 HEAPF32[i2 + 48 >> 2] = d3 * d12 + d4 * d13 + d5 * d14 + (d3 * d24 + d4 * d25 + d5 * d26);
michael@0 43030 HEAPF32[i2 + 52 >> 2] = d6 * d12 + d7 * d13 + d8 * d14 + (d6 * d24 + d7 * d25 + d8 * d26);
michael@0 43031 HEAPF32[i2 + 56 >> 2] = d9 * d12 + d10 * d13 + d11 * d14 + (d9 * d24 + d10 * d25 + d11 * d26);
michael@0 43032 HEAPF32[i2 + 60 >> 2] = 0.0;
michael@0 43033 return;
michael@0 43034 }
michael@0 43035 function __ZNK16btDbvtBroadphase17getBroadphaseAabbER9btVector3S1_(i1, i2, i3) {
michael@0 43036 i1 = i1 | 0;
michael@0 43037 i2 = i2 | 0;
michael@0 43038 i3 = i3 | 0;
michael@0 43039 var i4 = 0, i5 = 0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0;
michael@0 43040 i4 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 43041 i5 = HEAP32[i1 + 44 >> 2] | 0;
michael@0 43042 i1 = (i5 | 0) == 0;
michael@0 43043 do {
michael@0 43044 if ((i4 | 0) == 0) {
michael@0 43045 if (i1) {
michael@0 43046 d6 = 0.0;
michael@0 43047 d7 = 0.0;
michael@0 43048 d8 = 0.0;
michael@0 43049 d9 = 0.0;
michael@0 43050 d10 = 0.0;
michael@0 43051 d11 = 0.0;
michael@0 43052 d12 = 0.0;
michael@0 43053 d13 = 0.0;
michael@0 43054 break;
michael@0 43055 }
michael@0 43056 d6 = +HEAPF32[i5 >> 2];
michael@0 43057 d7 = +HEAPF32[i5 + 4 >> 2];
michael@0 43058 d8 = +HEAPF32[i5 + 8 >> 2];
michael@0 43059 d9 = +HEAPF32[i5 + 12 >> 2];
michael@0 43060 d10 = +HEAPF32[i5 + 16 >> 2];
michael@0 43061 d11 = +HEAPF32[i5 + 20 >> 2];
michael@0 43062 d12 = +HEAPF32[i5 + 24 >> 2];
michael@0 43063 d13 = +HEAPF32[i5 + 28 >> 2];
michael@0 43064 } else {
michael@0 43065 d14 = +HEAPF32[i4 >> 2];
michael@0 43066 if (i1) {
michael@0 43067 d6 = d14;
michael@0 43068 d7 = +HEAPF32[i4 + 4 >> 2];
michael@0 43069 d8 = +HEAPF32[i4 + 8 >> 2];
michael@0 43070 d9 = +HEAPF32[i4 + 12 >> 2];
michael@0 43071 d10 = +HEAPF32[i4 + 16 >> 2];
michael@0 43072 d11 = +HEAPF32[i4 + 20 >> 2];
michael@0 43073 d12 = +HEAPF32[i4 + 24 >> 2];
michael@0 43074 d13 = +HEAPF32[i4 + 28 >> 2];
michael@0 43075 break;
michael@0 43076 } else {
michael@0 43077 d15 = +HEAPF32[i5 >> 2];
michael@0 43078 d16 = +HEAPF32[i4 + 16 >> 2];
michael@0 43079 d17 = +HEAPF32[i5 + 16 >> 2];
michael@0 43080 d18 = +HEAPF32[i4 + 4 >> 2];
michael@0 43081 d19 = +HEAPF32[i5 + 4 >> 2];
michael@0 43082 d20 = +HEAPF32[i4 + 20 >> 2];
michael@0 43083 d21 = +HEAPF32[i5 + 20 >> 2];
michael@0 43084 d22 = +HEAPF32[i4 + 8 >> 2];
michael@0 43085 d23 = +HEAPF32[i5 + 8 >> 2];
michael@0 43086 d24 = +HEAPF32[i4 + 24 >> 2];
michael@0 43087 d25 = +HEAPF32[i5 + 24 >> 2];
michael@0 43088 d6 = d14 < d15 ? d14 : d15;
michael@0 43089 d7 = d18 < d19 ? d18 : d19;
michael@0 43090 d8 = d22 < d23 ? d22 : d23;
michael@0 43091 d9 = 0.0;
michael@0 43092 d10 = d16 > d17 ? d16 : d17;
michael@0 43093 d11 = d20 > d21 ? d20 : d21;
michael@0 43094 d12 = d24 > d25 ? d24 : d25;
michael@0 43095 d13 = 0.0;
michael@0 43096 break;
michael@0 43097 }
michael@0 43098 }
michael@0 43099 } while (0);
michael@0 43100 HEAPF32[i2 >> 2] = d6;
michael@0 43101 HEAPF32[i2 + 4 >> 2] = d7;
michael@0 43102 HEAPF32[i2 + 8 >> 2] = d8;
michael@0 43103 HEAPF32[i2 + 12 >> 2] = d9;
michael@0 43104 HEAPF32[i3 >> 2] = d10;
michael@0 43105 HEAPF32[i3 + 4 >> 2] = d11;
michael@0 43106 HEAPF32[i3 + 8 >> 2] = d12;
michael@0 43107 HEAPF32[i3 + 12 >> 2] = d13;
michael@0 43108 return;
michael@0 43109 }
michael@0 43110 function __ZN35btSequentialImpulseConstraintSolverD2Ev(i1) {
michael@0 43111 i1 = i1 | 0;
michael@0 43112 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 43113 HEAP32[i1 >> 2] = 2368;
michael@0 43114 i2 = i1 + 108 | 0;
michael@0 43115 i3 = i1 + 116 | 0;
michael@0 43116 i4 = HEAP32[i3 >> 2] | 0;
michael@0 43117 i5 = i1 + 120 | 0;
michael@0 43118 if ((i4 | 0) != 0) {
michael@0 43119 if ((HEAP8[i5] | 0) != 0) {
michael@0 43120 __Z21btAlignedFreeInternalPv(i4);
michael@0 43121 }
michael@0 43122 HEAP32[i3 >> 2] = 0;
michael@0 43123 }
michael@0 43124 HEAP8[i5] = 1;
michael@0 43125 HEAP32[i3 >> 2] = 0;
michael@0 43126 HEAP32[i2 >> 2] = 0;
michael@0 43127 HEAP32[i1 + 112 >> 2] = 0;
michael@0 43128 i2 = i1 + 88 | 0;
michael@0 43129 i3 = i1 + 96 | 0;
michael@0 43130 i5 = HEAP32[i3 >> 2] | 0;
michael@0 43131 i4 = i1 + 100 | 0;
michael@0 43132 if ((i5 | 0) != 0) {
michael@0 43133 if ((HEAP8[i4] | 0) != 0) {
michael@0 43134 __Z21btAlignedFreeInternalPv(i5);
michael@0 43135 }
michael@0 43136 HEAP32[i3 >> 2] = 0;
michael@0 43137 }
michael@0 43138 HEAP8[i4] = 1;
michael@0 43139 HEAP32[i3 >> 2] = 0;
michael@0 43140 HEAP32[i2 >> 2] = 0;
michael@0 43141 HEAP32[i1 + 92 >> 2] = 0;
michael@0 43142 i2 = i1 + 68 | 0;
michael@0 43143 i3 = i1 + 76 | 0;
michael@0 43144 i4 = HEAP32[i3 >> 2] | 0;
michael@0 43145 i5 = i1 + 80 | 0;
michael@0 43146 if ((i4 | 0) != 0) {
michael@0 43147 if ((HEAP8[i5] | 0) != 0) {
michael@0 43148 __Z21btAlignedFreeInternalPv(i4);
michael@0 43149 }
michael@0 43150 HEAP32[i3 >> 2] = 0;
michael@0 43151 }
michael@0 43152 HEAP8[i5] = 1;
michael@0 43153 HEAP32[i3 >> 2] = 0;
michael@0 43154 HEAP32[i2 >> 2] = 0;
michael@0 43155 HEAP32[i1 + 72 >> 2] = 0;
michael@0 43156 i2 = i1 + 48 | 0;
michael@0 43157 i3 = i1 + 56 | 0;
michael@0 43158 i5 = HEAP32[i3 >> 2] | 0;
michael@0 43159 i4 = i1 + 60 | 0;
michael@0 43160 if ((i5 | 0) != 0) {
michael@0 43161 if ((HEAP8[i4] | 0) != 0) {
michael@0 43162 __Z21btAlignedFreeInternalPv(i5);
michael@0 43163 }
michael@0 43164 HEAP32[i3 >> 2] = 0;
michael@0 43165 }
michael@0 43166 HEAP8[i4] = 1;
michael@0 43167 HEAP32[i3 >> 2] = 0;
michael@0 43168 HEAP32[i2 >> 2] = 0;
michael@0 43169 HEAP32[i1 + 52 >> 2] = 0;
michael@0 43170 i2 = i1 + 28 | 0;
michael@0 43171 i3 = i1 + 36 | 0;
michael@0 43172 i4 = HEAP32[i3 >> 2] | 0;
michael@0 43173 i5 = i1 + 40 | 0;
michael@0 43174 if ((i4 | 0) != 0) {
michael@0 43175 if ((HEAP8[i5] | 0) != 0) {
michael@0 43176 __Z21btAlignedFreeInternalPv(i4);
michael@0 43177 }
michael@0 43178 HEAP32[i3 >> 2] = 0;
michael@0 43179 }
michael@0 43180 HEAP8[i5] = 1;
michael@0 43181 HEAP32[i3 >> 2] = 0;
michael@0 43182 HEAP32[i2 >> 2] = 0;
michael@0 43183 HEAP32[i1 + 32 >> 2] = 0;
michael@0 43184 i2 = i1 + 8 | 0;
michael@0 43185 i3 = i1 + 16 | 0;
michael@0 43186 i5 = HEAP32[i3 >> 2] | 0;
michael@0 43187 i4 = i1 + 20 | 0;
michael@0 43188 if ((i5 | 0) == 0) {
michael@0 43189 HEAP8[i4] = 1;
michael@0 43190 HEAP32[i3 >> 2] = 0;
michael@0 43191 HEAP32[i2 >> 2] = 0;
michael@0 43192 i6 = i1 + 12 | 0;
michael@0 43193 HEAP32[i6 >> 2] = 0;
michael@0 43194 return;
michael@0 43195 }
michael@0 43196 if ((HEAP8[i4] | 0) != 0) {
michael@0 43197 __Z21btAlignedFreeInternalPv(i5);
michael@0 43198 }
michael@0 43199 HEAP32[i3 >> 2] = 0;
michael@0 43200 HEAP8[i4] = 1;
michael@0 43201 HEAP32[i3 >> 2] = 0;
michael@0 43202 HEAP32[i2 >> 2] = 0;
michael@0 43203 i6 = i1 + 12 | 0;
michael@0 43204 HEAP32[i6 >> 2] = 0;
michael@0 43205 return;
michael@0 43206 }
michael@0 43207 function __ZN23btDiscreteDynamicsWorld12addRigidBodyEP11btRigidBodyss(i1, i2, i3, i4) {
michael@0 43208 i1 = i1 | 0;
michael@0 43209 i2 = i2 | 0;
michael@0 43210 i3 = i3 | 0;
michael@0 43211 i4 = i4 | 0;
michael@0 43212 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0;
michael@0 43213 i5 = i2 | 0;
michael@0 43214 i6 = i2 + 204 | 0;
michael@0 43215 do {
michael@0 43216 if ((HEAP32[i6 >> 2] & 3 | 0) == 0) {
michael@0 43217 if ((HEAP32[i2 + 496 >> 2] & 1 | 0) != 0) {
michael@0 43218 break;
michael@0 43219 }
michael@0 43220 __ZN11btRigidBody10setGravityERK9btVector3(i2, i1 + 220 | 0);
michael@0 43221 }
michael@0 43222 } while (0);
michael@0 43223 if ((HEAP32[i2 + 192 >> 2] | 0) == 0) {
michael@0 43224 return;
michael@0 43225 }
michael@0 43226 if ((HEAP32[i6 >> 2] & 1 | 0) == 0) {
michael@0 43227 i6 = i1 + 204 | 0;
michael@0 43228 i7 = HEAP32[i6 >> 2] | 0;
michael@0 43229 i8 = i1 + 208 | 0;
michael@0 43230 do {
michael@0 43231 if ((i7 | 0) == (HEAP32[i8 >> 2] | 0)) {
michael@0 43232 i9 = (i7 | 0) == 0 ? 1 : i7 << 1;
michael@0 43233 if ((i7 | 0) >= (i9 | 0)) {
michael@0 43234 i10 = i7;
michael@0 43235 break;
michael@0 43236 }
michael@0 43237 if ((i9 | 0) == 0) {
michael@0 43238 i11 = 0;
michael@0 43239 i12 = i7;
michael@0 43240 } else {
michael@0 43241 i13 = __Z22btAlignedAllocInternalji(i9 << 2, 16) | 0;
michael@0 43242 i11 = i13;
michael@0 43243 i12 = HEAP32[i6 >> 2] | 0;
michael@0 43244 }
michael@0 43245 i13 = i1 + 212 | 0;
michael@0 43246 if ((i12 | 0) > 0) {
michael@0 43247 i14 = 0;
michael@0 43248 do {
michael@0 43249 i15 = i11 + (i14 << 2) | 0;
michael@0 43250 if ((i15 | 0) != 0) {
michael@0 43251 HEAP32[i15 >> 2] = HEAP32[(HEAP32[i13 >> 2] | 0) + (i14 << 2) >> 2];
michael@0 43252 }
michael@0 43253 i14 = i14 + 1 | 0;
michael@0 43254 } while ((i14 | 0) < (i12 | 0));
michael@0 43255 }
michael@0 43256 i14 = HEAP32[i13 >> 2] | 0;
michael@0 43257 i15 = i1 + 216 | 0;
michael@0 43258 if ((i14 | 0) == 0) {
michael@0 43259 i16 = i12;
michael@0 43260 } else {
michael@0 43261 if ((HEAP8[i15] | 0) == 0) {
michael@0 43262 i17 = i12;
michael@0 43263 } else {
michael@0 43264 __Z21btAlignedFreeInternalPv(i14);
michael@0 43265 i17 = HEAP32[i6 >> 2] | 0;
michael@0 43266 }
michael@0 43267 HEAP32[i13 >> 2] = 0;
michael@0 43268 i16 = i17;
michael@0 43269 }
michael@0 43270 HEAP8[i15] = 1;
michael@0 43271 HEAP32[i13 >> 2] = i11;
michael@0 43272 HEAP32[i8 >> 2] = i9;
michael@0 43273 i10 = i16;
michael@0 43274 } else {
michael@0 43275 i10 = i7;
michael@0 43276 }
michael@0 43277 } while (0);
michael@0 43278 i7 = (HEAP32[i1 + 212 >> 2] | 0) + (i10 << 2) | 0;
michael@0 43279 if ((i7 | 0) != 0) {
michael@0 43280 HEAP32[i7 >> 2] = i2;
michael@0 43281 }
michael@0 43282 HEAP32[i6 >> 2] = i10 + 1;
michael@0 43283 } else {
michael@0 43284 __ZN17btCollisionObject18setActivationStateEi(i5, 2);
michael@0 43285 }
michael@0 43286 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 32 >> 2] & 127](i1, i5, i3, i4);
michael@0 43287 return;
michael@0 43288 }
michael@0 43289 function __ZNK13btConvexShape31localGetSupportVertexNonVirtualERK9btVector3(i1, i2, i3) {
michael@0 43290 i1 = i1 | 0;
michael@0 43291 i2 = i2 | 0;
michael@0 43292 i3 = i3 | 0;
michael@0 43293 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0;
michael@0 43294 i4 = STACKTOP;
michael@0 43295 STACKTOP = STACKTOP + 32 | 0;
michael@0 43296 i5 = i4 | 0;
michael@0 43297 i6 = i4 + 16 | 0;
michael@0 43298 i7 = i5;
michael@0 43299 i8 = i3;
michael@0 43300 HEAP32[i7 >> 2] = HEAP32[i8 >> 2];
michael@0 43301 HEAP32[i7 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 43302 HEAP32[i7 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 43303 HEAP32[i7 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 43304 i8 = i5 | 0;
michael@0 43305 d9 = +HEAPF32[i8 >> 2];
michael@0 43306 i7 = i5 + 4 | 0;
michael@0 43307 d10 = +HEAPF32[i7 >> 2];
michael@0 43308 i3 = i5 + 8 | 0;
michael@0 43309 d11 = +HEAPF32[i3 >> 2];
michael@0 43310 if (d9 * d9 + d10 * d10 + d11 * d11 < 1.4210854715202004e-14) {
michael@0 43311 HEAPF32[i8 >> 2] = -1.0;
michael@0 43312 HEAPF32[i7 >> 2] = -1.0;
michael@0 43313 HEAPF32[i3 >> 2] = -1.0;
michael@0 43314 HEAPF32[i5 + 12 >> 2] = 0.0;
michael@0 43315 d12 = -1.0;
michael@0 43316 d13 = -1.0;
michael@0 43317 d14 = -1.0;
michael@0 43318 } else {
michael@0 43319 d12 = d9;
michael@0 43320 d13 = d10;
michael@0 43321 d14 = d11;
michael@0 43322 }
michael@0 43323 d11 = 1.0 / +Math_sqrt(+(d14 * d14 + (d13 * d13 + d12 * d12)));
michael@0 43324 HEAPF32[i8 >> 2] = d12 * d11;
michael@0 43325 HEAPF32[i7 >> 2] = d13 * d11;
michael@0 43326 HEAPF32[i3 >> 2] = d14 * d11;
michael@0 43327 __ZNK13btConvexShape44localGetSupportVertexWithoutMarginNonVirtualERK9btVector3(i6, i2, i5);
michael@0 43328 switch (HEAP32[i2 + 4 >> 2] | 0) {
michael@0 43329 case 0:
michael@0 43330 {
michael@0 43331 d15 = +HEAPF32[i2 + 44 >> 2];
michael@0 43332 break;
michael@0 43333 }
michael@0 43334 case 1:
michael@0 43335 {
michael@0 43336 d15 = +HEAPF32[i2 + 44 >> 2];
michael@0 43337 break;
michael@0 43338 }
michael@0 43339 case 13:
michael@0 43340 {
michael@0 43341 d15 = +HEAPF32[i2 + 44 >> 2];
michael@0 43342 break;
michael@0 43343 }
michael@0 43344 case 10:
michael@0 43345 {
michael@0 43346 d15 = +HEAPF32[i2 + 44 >> 2];
michael@0 43347 break;
michael@0 43348 }
michael@0 43349 case 5:
michael@0 43350 case 4:
michael@0 43351 {
michael@0 43352 d15 = +HEAPF32[i2 + 44 >> 2];
michael@0 43353 break;
michael@0 43354 }
michael@0 43355 case 8:
michael@0 43356 {
michael@0 43357 d15 = +HEAPF32[i2 + 28 >> 2] * +HEAPF32[i2 + 12 >> 2];
michael@0 43358 break;
michael@0 43359 }
michael@0 43360 default:
michael@0 43361 {
michael@0 43362 d15 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i2 >> 2] | 0) + 44 >> 2] & 7](i2);
michael@0 43363 }
michael@0 43364 }
michael@0 43365 d11 = d15 * +HEAPF32[i7 >> 2] + +HEAPF32[i6 + 4 >> 2];
michael@0 43366 d14 = d15 * +HEAPF32[i3 >> 2] + +HEAPF32[i6 + 8 >> 2];
michael@0 43367 HEAPF32[i1 >> 2] = d15 * +HEAPF32[i8 >> 2] + +HEAPF32[i6 >> 2];
michael@0 43368 HEAPF32[i1 + 4 >> 2] = d11;
michael@0 43369 HEAPF32[i1 + 8 >> 2] = d14;
michael@0 43370 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 43371 STACKTOP = i4;
michael@0 43372 return;
michael@0 43373 }
michael@0 43374 function __ZN16btManifoldResultC2EP17btCollisionObjectS1_(i1, i2, i3) {
michael@0 43375 i1 = i1 | 0;
michael@0 43376 i2 = i2 | 0;
michael@0 43377 i3 = i3 | 0;
michael@0 43378 var i4 = 0, i5 = 0;
michael@0 43379 HEAP32[i1 >> 2] = 4312;
michael@0 43380 HEAP32[i1 + 4 >> 2] = 0;
michael@0 43381 HEAP32[i1 + 136 >> 2] = i2;
michael@0 43382 HEAP32[i1 + 140 >> 2] = i3;
michael@0 43383 i4 = i1 + 8 | 0;
michael@0 43384 i5 = i2 + 4 | 0;
michael@0 43385 _memset(i1 + 144 | 0, -1 | 0, 16);
michael@0 43386 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 43387 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 43388 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 43389 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 43390 i5 = i1 + 24 | 0;
michael@0 43391 i4 = i2 + 20 | 0;
michael@0 43392 HEAP32[i5 >> 2] = HEAP32[i4 >> 2];
michael@0 43393 HEAP32[i5 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 43394 HEAP32[i5 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 43395 HEAP32[i5 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 43396 i4 = i1 + 40 | 0;
michael@0 43397 i5 = i2 + 36 | 0;
michael@0 43398 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 43399 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 43400 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 43401 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 43402 i5 = i1 + 56 | 0;
michael@0 43403 i4 = i2 + 52 | 0;
michael@0 43404 HEAP32[i5 >> 2] = HEAP32[i4 >> 2];
michael@0 43405 HEAP32[i5 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 43406 HEAP32[i5 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 43407 HEAP32[i5 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 43408 i4 = i1 + 72 | 0;
michael@0 43409 i5 = i3 + 4 | 0;
michael@0 43410 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 43411 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 43412 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 43413 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 43414 i5 = i1 + 88 | 0;
michael@0 43415 i4 = i3 + 20 | 0;
michael@0 43416 HEAP32[i5 >> 2] = HEAP32[i4 >> 2];
michael@0 43417 HEAP32[i5 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 43418 HEAP32[i5 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 43419 HEAP32[i5 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 43420 i4 = i1 + 104 | 0;
michael@0 43421 i5 = i3 + 36 | 0;
michael@0 43422 HEAP32[i4 >> 2] = HEAP32[i5 >> 2];
michael@0 43423 HEAP32[i4 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 43424 HEAP32[i4 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 43425 HEAP32[i4 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 43426 i5 = i1 + 120 | 0;
michael@0 43427 i1 = i3 + 52 | 0;
michael@0 43428 HEAP32[i5 >> 2] = HEAP32[i1 >> 2];
michael@0 43429 HEAP32[i5 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 43430 HEAP32[i5 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 43431 HEAP32[i5 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 43432 return;
michael@0 43433 }
michael@0 43434 function __ZNK18btConvexPolyhedron7projectERK11btTransformRK9btVector3RfS6_(i1, i2, i3, i4, i5) {
michael@0 43435 i1 = i1 | 0;
michael@0 43436 i2 = i2 | 0;
michael@0 43437 i3 = i3 | 0;
michael@0 43438 i4 = i4 | 0;
michael@0 43439 i5 = i5 | 0;
michael@0 43440 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, i28 = 0, d29 = 0.0;
michael@0 43441 HEAPF32[i4 >> 2] = 3.4028234663852886e+38;
michael@0 43442 HEAPF32[i5 >> 2] = -3.4028234663852886e+38;
michael@0 43443 i6 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 43444 if ((i6 | 0) > 0) {
michael@0 43445 i7 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 43446 i1 = i2 | 0;
michael@0 43447 i8 = i2 + 4 | 0;
michael@0 43448 i9 = i2 + 8 | 0;
michael@0 43449 i10 = i2 + 48 | 0;
michael@0 43450 i11 = i2 + 16 | 0;
michael@0 43451 i12 = i2 + 20 | 0;
michael@0 43452 i13 = i2 + 24 | 0;
michael@0 43453 i14 = i2 + 52 | 0;
michael@0 43454 i15 = i2 + 32 | 0;
michael@0 43455 i16 = i2 + 36 | 0;
michael@0 43456 i17 = i2 + 40 | 0;
michael@0 43457 i18 = i2 + 56 | 0;
michael@0 43458 i2 = i3 | 0;
michael@0 43459 i19 = i3 + 4 | 0;
michael@0 43460 i20 = i3 + 8 | 0;
michael@0 43461 i3 = 0;
michael@0 43462 d21 = -3.4028234663852886e+38;
michael@0 43463 while (1) {
michael@0 43464 d22 = +HEAPF32[i7 + (i3 << 4) >> 2];
michael@0 43465 d23 = +HEAPF32[i7 + (i3 << 4) + 4 >> 2];
michael@0 43466 d24 = +HEAPF32[i7 + (i3 << 4) + 8 >> 2];
michael@0 43467 d25 = (+HEAPF32[i10 >> 2] + (+HEAPF32[i1 >> 2] * d22 + +HEAPF32[i8 >> 2] * d23 + +HEAPF32[i9 >> 2] * d24)) * +HEAPF32[i2 >> 2] + (+HEAPF32[i14 >> 2] + (d22 * +HEAPF32[i11 >> 2] + d23 * +HEAPF32[i12 >> 2] + d24 * +HEAPF32[i13 >> 2])) * +HEAPF32[i19 >> 2] + (+HEAPF32[i18 >> 2] + (d22 * +HEAPF32[i15 >> 2] + d23 * +HEAPF32[i16 >> 2] + d24 * +HEAPF32[i17 >> 2])) * +HEAPF32[i20 >> 2];
michael@0 43468 if (d25 < +HEAPF32[i4 >> 2]) {
michael@0 43469 HEAPF32[i4 >> 2] = d25;
michael@0 43470 d26 = +HEAPF32[i5 >> 2];
michael@0 43471 } else {
michael@0 43472 d26 = d21;
michael@0 43473 }
michael@0 43474 if (d25 > d26) {
michael@0 43475 HEAPF32[i5 >> 2] = d25;
michael@0 43476 d27 = d25;
michael@0 43477 } else {
michael@0 43478 d27 = d26;
michael@0 43479 }
michael@0 43480 i28 = i3 + 1 | 0;
michael@0 43481 if ((i28 | 0) < (i6 | 0)) {
michael@0 43482 i3 = i28;
michael@0 43483 d21 = d27;
michael@0 43484 } else {
michael@0 43485 d29 = d27;
michael@0 43486 break;
michael@0 43487 }
michael@0 43488 }
michael@0 43489 } else {
michael@0 43490 d29 = -3.4028234663852886e+38;
michael@0 43491 }
michael@0 43492 d27 = +HEAPF32[i4 >> 2];
michael@0 43493 if (d27 <= d29) {
michael@0 43494 return;
michael@0 43495 }
michael@0 43496 HEAPF32[i4 >> 2] = d29;
michael@0 43497 HEAPF32[i5 >> 2] = d27;
michael@0 43498 return;
michael@0 43499 }
michael@0 43500 function __ZNK10__cxxabiv120__si_class_type_info16search_below_dstEPNS_19__dynamic_cast_infoEPKvib(i1, i2, i3, i4, i5) {
michael@0 43501 i1 = i1 | 0;
michael@0 43502 i2 = i2 | 0;
michael@0 43503 i3 = i3 | 0;
michael@0 43504 i4 = i4 | 0;
michael@0 43505 i5 = i5 | 0;
michael@0 43506 var i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0;
michael@0 43507 i6 = i1 | 0;
michael@0 43508 if ((i6 | 0) == (HEAP32[i2 + 8 >> 2] | 0)) {
michael@0 43509 if ((HEAP32[i2 + 4 >> 2] | 0) != (i3 | 0)) {
michael@0 43510 return;
michael@0 43511 }
michael@0 43512 i7 = i2 + 28 | 0;
michael@0 43513 if ((HEAP32[i7 >> 2] | 0) == 1) {
michael@0 43514 return;
michael@0 43515 }
michael@0 43516 HEAP32[i7 >> 2] = i4;
michael@0 43517 return;
michael@0 43518 }
michael@0 43519 if ((i6 | 0) != (HEAP32[i2 >> 2] | 0)) {
michael@0 43520 i6 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 43521 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 24 >> 2] & 63](i6, i2, i3, i4, i5);
michael@0 43522 return;
michael@0 43523 }
michael@0 43524 do {
michael@0 43525 if ((HEAP32[i2 + 16 >> 2] | 0) != (i3 | 0)) {
michael@0 43526 i6 = i2 + 20 | 0;
michael@0 43527 if ((HEAP32[i6 >> 2] | 0) == (i3 | 0)) {
michael@0 43528 break;
michael@0 43529 }
michael@0 43530 HEAP32[i2 + 32 >> 2] = i4;
michael@0 43531 i7 = i2 + 44 | 0;
michael@0 43532 if ((HEAP32[i7 >> 2] | 0) == 4) {
michael@0 43533 return;
michael@0 43534 }
michael@0 43535 i8 = i2 + 52 | 0;
michael@0 43536 HEAP8[i8] = 0;
michael@0 43537 i9 = i2 + 53 | 0;
michael@0 43538 HEAP8[i9] = 0;
michael@0 43539 i10 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 43540 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i10 >> 2] | 0) + 20 >> 2] & 15](i10, i2, i3, i3, 1, i5);
michael@0 43541 if ((HEAP8[i9] & 1) == 0) {
michael@0 43542 i11 = 0;
michael@0 43543 i12 = 2131;
michael@0 43544 } else {
michael@0 43545 if ((HEAP8[i8] & 1) == 0) {
michael@0 43546 i11 = 1;
michael@0 43547 i12 = 2131;
michael@0 43548 }
michael@0 43549 }
michael@0 43550 L2842 : do {
michael@0 43551 if ((i12 | 0) == 2131) {
michael@0 43552 HEAP32[i6 >> 2] = i3;
michael@0 43553 i8 = i2 + 40 | 0;
michael@0 43554 HEAP32[i8 >> 2] = (HEAP32[i8 >> 2] | 0) + 1;
michael@0 43555 do {
michael@0 43556 if ((HEAP32[i2 + 36 >> 2] | 0) == 1) {
michael@0 43557 if ((HEAP32[i2 + 24 >> 2] | 0) != 2) {
michael@0 43558 i12 = 2134;
michael@0 43559 break;
michael@0 43560 }
michael@0 43561 HEAP8[i2 + 54 | 0] = 1;
michael@0 43562 if (i11) {
michael@0 43563 break L2842;
michael@0 43564 }
michael@0 43565 } else {
michael@0 43566 i12 = 2134;
michael@0 43567 }
michael@0 43568 } while (0);
michael@0 43569 if ((i12 | 0) == 2134) {
michael@0 43570 if (i11) {
michael@0 43571 break;
michael@0 43572 }
michael@0 43573 }
michael@0 43574 HEAP32[i7 >> 2] = 4;
michael@0 43575 return;
michael@0 43576 }
michael@0 43577 } while (0);
michael@0 43578 HEAP32[i7 >> 2] = 3;
michael@0 43579 return;
michael@0 43580 }
michael@0 43581 } while (0);
michael@0 43582 if ((i4 | 0) != 1) {
michael@0 43583 return;
michael@0 43584 }
michael@0 43585 HEAP32[i2 + 32 >> 2] = 1;
michael@0 43586 return;
michael@0 43587 }
michael@0 43588 function __ZN20btConvexHullInternal14getOrientationEPKNS_4EdgeES2_RKNS_7Point32ES5_(i1, i2, i3, i4) {
michael@0 43589 i1 = i1 | 0;
michael@0 43590 i2 = i2 | 0;
michael@0 43591 i3 = i3 | 0;
michael@0 43592 i4 = i4 | 0;
michael@0 43593 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0;
michael@0 43594 i5 = (HEAP32[i1 + 4 >> 2] | 0) == (i2 | 0);
michael@0 43595 if ((HEAP32[i1 >> 2] | 0) != (i2 | 0)) {
michael@0 43596 i6 = i5 & 1;
michael@0 43597 return i6 | 0;
michael@0 43598 }
michael@0 43599 if (!i5) {
michael@0 43600 i6 = 2;
michael@0 43601 return i6 | 0;
michael@0 43602 }
michael@0 43603 i5 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 43604 i7 = HEAP32[i3 + 8 >> 2] | 0;
michael@0 43605 i8 = Math_imul(i7, i5) | 0;
michael@0 43606 i9 = HEAP32[i4 + 8 >> 2] | 0;
michael@0 43607 i10 = HEAP32[i3 + 4 >> 2] | 0;
michael@0 43608 i11 = i8 - (Math_imul(i10, i9) | 0) | 0;
michael@0 43609 i8 = HEAP32[i3 >> 2] | 0;
michael@0 43610 i3 = Math_imul(i8, i9) | 0;
michael@0 43611 i9 = HEAP32[i4 >> 2] | 0;
michael@0 43612 i4 = i3 - (Math_imul(i9, i7) | 0) | 0;
michael@0 43613 i7 = Math_imul(i9, i10) | 0;
michael@0 43614 i10 = i7 - (Math_imul(i8, i5) | 0) | 0;
michael@0 43615 i5 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 43616 i1 = HEAP32[(HEAP32[i2 + 8 >> 2] | 0) + 12 >> 2] | 0;
michael@0 43617 i8 = HEAP32[i1 + 88 >> 2] | 0;
michael@0 43618 i7 = (HEAP32[i5 + 88 >> 2] | 0) - i8 | 0;
michael@0 43619 i9 = HEAP32[i1 + 92 >> 2] | 0;
michael@0 43620 i3 = (HEAP32[i5 + 92 >> 2] | 0) - i9 | 0;
michael@0 43621 i12 = HEAP32[i1 + 96 >> 2] | 0;
michael@0 43622 i1 = (HEAP32[i5 + 96 >> 2] | 0) - i12 | 0;
michael@0 43623 i5 = HEAP32[i2 + 12 >> 2] | 0;
michael@0 43624 i2 = (HEAP32[i5 + 88 >> 2] | 0) - i8 | 0;
michael@0 43625 i8 = (HEAP32[i5 + 92 >> 2] | 0) - i9 | 0;
michael@0 43626 i9 = (HEAP32[i5 + 96 >> 2] | 0) - i12 | 0;
michael@0 43627 i12 = Math_imul(i9, i3) | 0;
michael@0 43628 i5 = i12 - (Math_imul(i8, i1) | 0) | 0;
michael@0 43629 i12 = Math_imul(i2, i1) | 0;
michael@0 43630 i1 = i12 - (Math_imul(i9, i7) | 0) | 0;
michael@0 43631 i9 = Math_imul(i8, i7) | 0;
michael@0 43632 i7 = i9 - (Math_imul(i2, i3) | 0) | 0;
michael@0 43633 i3 = ___muldi3(i5, (i5 | 0) < 0 ? -1 : 0, i11, (i11 | 0) < 0 ? -1 : 0) | 0;
michael@0 43634 i11 = tempRet0;
michael@0 43635 i5 = ___muldi3(i1, (i1 | 0) < 0 ? -1 : 0, i4, (i4 | 0) < 0 ? -1 : 0) | 0;
michael@0 43636 i4 = tempRet0;
michael@0 43637 i1 = ___muldi3(i7, (i7 | 0) < 0 ? -1 : 0, i10, (i10 | 0) < 0 ? -1 : 0) | 0;
michael@0 43638 i10 = _i64Add(i3, i11, i1, tempRet0) | 0;
michael@0 43639 i1 = _i64Add(i10, tempRet0, i5, i4) | 0;
michael@0 43640 i4 = tempRet0;
michael@0 43641 i5 = 0;
michael@0 43642 i6 = (i4 | 0) > (i5 | 0) | (i4 | 0) == (i5 | 0) & i1 >>> 0 > 0 >>> 0 ? 2 : 1;
michael@0 43643 return i6 | 0;
michael@0 43644 }
michael@0 43645 function __ZNK11btTransformmlERKS_(i1, i2, i3) {
michael@0 43646 i1 = i1 | 0;
michael@0 43647 i2 = i2 | 0;
michael@0 43648 i3 = i3 | 0;
michael@0 43649 var d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0;
michael@0 43650 d4 = +HEAPF32[i3 >> 2];
michael@0 43651 d5 = +HEAPF32[i2 >> 2];
michael@0 43652 d6 = +HEAPF32[i3 + 16 >> 2];
michael@0 43653 d7 = +HEAPF32[i2 + 4 >> 2];
michael@0 43654 d8 = +HEAPF32[i3 + 32 >> 2];
michael@0 43655 d9 = +HEAPF32[i2 + 8 >> 2];
michael@0 43656 d10 = +HEAPF32[i3 + 4 >> 2];
michael@0 43657 d11 = +HEAPF32[i3 + 20 >> 2];
michael@0 43658 d12 = +HEAPF32[i3 + 36 >> 2];
michael@0 43659 d13 = +HEAPF32[i3 + 8 >> 2];
michael@0 43660 d14 = +HEAPF32[i3 + 24 >> 2];
michael@0 43661 d15 = +HEAPF32[i3 + 40 >> 2];
michael@0 43662 d16 = +HEAPF32[i2 + 16 >> 2];
michael@0 43663 d17 = +HEAPF32[i2 + 20 >> 2];
michael@0 43664 d18 = +HEAPF32[i2 + 24 >> 2];
michael@0 43665 d19 = +HEAPF32[i2 + 32 >> 2];
michael@0 43666 d20 = +HEAPF32[i2 + 36 >> 2];
michael@0 43667 d21 = +HEAPF32[i2 + 40 >> 2];
michael@0 43668 d22 = +HEAPF32[i3 + 48 >> 2];
michael@0 43669 d23 = +HEAPF32[i3 + 52 >> 2];
michael@0 43670 d24 = +HEAPF32[i3 + 56 >> 2];
michael@0 43671 d25 = +HEAPF32[i2 + 48 >> 2] + (d5 * d22 + d7 * d23 + d9 * d24);
michael@0 43672 d26 = +HEAPF32[i2 + 52 >> 2] + (d22 * d16 + d23 * d17 + d24 * d18);
michael@0 43673 d27 = +HEAPF32[i2 + 56 >> 2] + (d22 * d19 + d23 * d20 + d24 * d21);
michael@0 43674 HEAPF32[i1 >> 2] = d4 * d5 + d6 * d7 + d8 * d9;
michael@0 43675 HEAPF32[i1 + 4 >> 2] = d5 * d10 + d7 * d11 + d9 * d12;
michael@0 43676 HEAPF32[i1 + 8 >> 2] = d5 * d13 + d7 * d14 + d9 * d15;
michael@0 43677 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 43678 HEAPF32[i1 + 16 >> 2] = d4 * d16 + d6 * d17 + d8 * d18;
michael@0 43679 HEAPF32[i1 + 20 >> 2] = d10 * d16 + d11 * d17 + d12 * d18;
michael@0 43680 HEAPF32[i1 + 24 >> 2] = d13 * d16 + d14 * d17 + d15 * d18;
michael@0 43681 HEAPF32[i1 + 28 >> 2] = 0.0;
michael@0 43682 HEAPF32[i1 + 32 >> 2] = d4 * d19 + d6 * d20 + d8 * d21;
michael@0 43683 HEAPF32[i1 + 36 >> 2] = d10 * d19 + d11 * d20 + d12 * d21;
michael@0 43684 HEAPF32[i1 + 40 >> 2] = d13 * d19 + d14 * d20 + d15 * d21;
michael@0 43685 HEAPF32[i1 + 44 >> 2] = 0.0;
michael@0 43686 HEAPF32[i1 + 48 >> 2] = d25;
michael@0 43687 HEAPF32[i1 + 52 >> 2] = d26;
michael@0 43688 HEAPF32[i1 + 56 >> 2] = d27;
michael@0 43689 HEAPF32[i1 + 60 >> 2] = 0.0;
michael@0 43690 return;
michael@0 43691 }
michael@0 43692 function __ZN20btAlignedObjectArrayI9btElementE17quickSortInternalI31btUnionFindElementSortPredicateEEvT_ii(i1, i2, i3, i4) {
michael@0 43693 i1 = i1 | 0;
michael@0 43694 i2 = i2 | 0;
michael@0 43695 i3 = i3 | 0;
michael@0 43696 i4 = i4 | 0;
michael@0 43697 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0, i23 = 0;
michael@0 43698 i5 = STACKTOP;
michael@0 43699 STACKTOP = STACKTOP + 16 | 0;
michael@0 43700 i6 = i2;
michael@0 43701 i2 = STACKTOP;
michael@0 43702 STACKTOP = STACKTOP + 1 | 0;
michael@0 43703 STACKTOP = STACKTOP + 7 >> 3 << 3;
michael@0 43704 HEAP8[i2] = HEAP8[i6] | 0;
michael@0 43705 i6 = i5 | 0;
michael@0 43706 i2 = i5 + 8 | 0;
michael@0 43707 i7 = i1 + 12 | 0;
michael@0 43708 i8 = HEAP32[i7 >> 2] | 0;
michael@0 43709 i9 = HEAP32[i8 + (((i4 + i3 | 0) / 2 | 0) << 3) >> 2] | 0;
michael@0 43710 i10 = i4;
michael@0 43711 i11 = i3;
michael@0 43712 i12 = i8;
michael@0 43713 while (1) {
michael@0 43714 i8 = i11;
michael@0 43715 while (1) {
michael@0 43716 i13 = i8 + 1 | 0;
michael@0 43717 if ((HEAP32[i12 + (i8 << 3) >> 2] | 0) < (i9 | 0)) {
michael@0 43718 i8 = i13;
michael@0 43719 } else {
michael@0 43720 i14 = i10;
michael@0 43721 break;
michael@0 43722 }
michael@0 43723 }
michael@0 43724 while (1) {
michael@0 43725 i15 = i12 + (i14 << 3) | 0;
michael@0 43726 i16 = i14 - 1 | 0;
michael@0 43727 if ((i9 | 0) < (HEAP32[i15 >> 2] | 0)) {
michael@0 43728 i14 = i16;
michael@0 43729 } else {
michael@0 43730 break;
michael@0 43731 }
michael@0 43732 }
michael@0 43733 if ((i8 | 0) > (i14 | 0)) {
michael@0 43734 i17 = i14;
michael@0 43735 i18 = i8;
michael@0 43736 } else {
michael@0 43737 i19 = i12 + (i8 << 3) | 0;
michael@0 43738 i20 = HEAP32[i19 >> 2] | 0;
michael@0 43739 i21 = HEAP32[i19 + 4 >> 2] | 0;
michael@0 43740 i22 = i15;
michael@0 43741 i23 = HEAP32[i22 + 4 >> 2] | 0;
michael@0 43742 HEAP32[i19 >> 2] = HEAP32[i22 >> 2];
michael@0 43743 HEAP32[i19 + 4 >> 2] = i23;
michael@0 43744 i23 = (HEAP32[i7 >> 2] | 0) + (i14 << 3) | 0;
michael@0 43745 HEAP32[i23 >> 2] = i20;
michael@0 43746 HEAP32[i23 + 4 >> 2] = i21;
michael@0 43747 i17 = i16;
michael@0 43748 i18 = i13;
michael@0 43749 }
michael@0 43750 if ((i18 | 0) > (i17 | 0)) {
michael@0 43751 break;
michael@0 43752 }
michael@0 43753 i10 = i17;
michael@0 43754 i11 = i18;
michael@0 43755 i12 = HEAP32[i7 >> 2] | 0;
michael@0 43756 }
michael@0 43757 if ((i17 | 0) > (i3 | 0)) {
michael@0 43758 __ZN20btAlignedObjectArrayI9btElementE17quickSortInternalI31btUnionFindElementSortPredicateEEvT_ii(i1, i6, i3, i17);
michael@0 43759 }
michael@0 43760 if ((i18 | 0) >= (i4 | 0)) {
michael@0 43761 STACKTOP = i5;
michael@0 43762 return;
michael@0 43763 }
michael@0 43764 __ZN20btAlignedObjectArrayI9btElementE17quickSortInternalI31btUnionFindElementSortPredicateEEvT_ii(i1, i2, i18, i4);
michael@0 43765 STACKTOP = i5;
michael@0 43766 return;
michael@0 43767 }
michael@0 43768 function __ZN20btConvexHullInternal11getBtNormalEPNS_4FaceE(i1, i2, i3) {
michael@0 43769 i1 = i1 | 0;
michael@0 43770 i2 = i2 | 0;
michael@0 43771 i3 = i3 | 0;
michael@0 43772 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0;
michael@0 43773 i4 = STACKTOP;
michael@0 43774 STACKTOP = STACKTOP + 32 | 0;
michael@0 43775 i5 = i4 | 0;
michael@0 43776 i6 = i4 + 16 | 0;
michael@0 43777 i7 = HEAP32[i2 + 108 >> 2] | 0;
michael@0 43778 HEAPF32[i6 + (i7 << 2) >> 2] = +(HEAP32[i3 + 28 >> 2] | 0);
michael@0 43779 i8 = HEAP32[i2 + 112 >> 2] | 0;
michael@0 43780 HEAPF32[i6 + (i8 << 2) >> 2] = +(HEAP32[i3 + 32 >> 2] | 0);
michael@0 43781 i9 = HEAP32[i2 + 104 >> 2] | 0;
michael@0 43782 HEAPF32[i6 + (i9 << 2) >> 2] = +(HEAP32[i3 + 36 >> 2] | 0);
michael@0 43783 d10 = +HEAPF32[i2 >> 2];
michael@0 43784 d11 = +HEAPF32[i6 >> 2] * d10;
michael@0 43785 d12 = +HEAPF32[i2 + 4 >> 2];
michael@0 43786 d13 = +HEAPF32[i6 + 4 >> 2] * d12;
michael@0 43787 d14 = +HEAPF32[i2 + 8 >> 2];
michael@0 43788 d15 = +HEAPF32[i6 + 8 >> 2] * d14;
michael@0 43789 HEAPF32[i5 + (i7 << 2) >> 2] = +(HEAP32[i3 + 44 >> 2] | 0);
michael@0 43790 HEAPF32[i5 + (i8 << 2) >> 2] = +(HEAP32[i3 + 48 >> 2] | 0);
michael@0 43791 HEAPF32[i5 + (i9 << 2) >> 2] = +(HEAP32[i3 + 52 >> 2] | 0);
michael@0 43792 d16 = d10 * +HEAPF32[i5 >> 2];
michael@0 43793 d10 = d12 * +HEAPF32[i5 + 4 >> 2];
michael@0 43794 d12 = d14 * +HEAPF32[i5 + 8 >> 2];
michael@0 43795 d14 = d13 * d12 - d15 * d10;
michael@0 43796 d17 = d15 * d16 - d11 * d12;
michael@0 43797 d12 = d11 * d10 - d13 * d16;
michael@0 43798 i5 = i1 | 0;
michael@0 43799 HEAPF32[i5 >> 2] = d14;
michael@0 43800 i3 = i1 + 4 | 0;
michael@0 43801 HEAPF32[i3 >> 2] = d17;
michael@0 43802 i9 = i1 + 8 | 0;
michael@0 43803 HEAPF32[i9 >> 2] = d12;
michael@0 43804 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 43805 d16 = +Math_sqrt(+(d12 * d12 + (d14 * d14 + d17 * d17)));
michael@0 43806 if ((i7 + 1 | 0) == (i8 | 0) | (i7 - 2 | 0) == (i8 | 0)) {
michael@0 43807 d18 = d16;
michael@0 43808 d19 = 1.0 / d18;
michael@0 43809 d20 = d14 * d19;
michael@0 43810 HEAPF32[i5 >> 2] = d20;
michael@0 43811 d21 = d17 * d19;
michael@0 43812 HEAPF32[i3 >> 2] = d21;
michael@0 43813 d22 = d12 * d19;
michael@0 43814 HEAPF32[i9 >> 2] = d22;
michael@0 43815 STACKTOP = i4;
michael@0 43816 return;
michael@0 43817 }
michael@0 43818 d18 = -0.0 - d16;
michael@0 43819 d19 = 1.0 / d18;
michael@0 43820 d20 = d14 * d19;
michael@0 43821 HEAPF32[i5 >> 2] = d20;
michael@0 43822 d21 = d17 * d19;
michael@0 43823 HEAPF32[i3 >> 2] = d21;
michael@0 43824 d22 = d12 * d19;
michael@0 43825 HEAPF32[i9 >> 2] = d22;
michael@0 43826 STACKTOP = i4;
michael@0 43827 return;
michael@0 43828 }
michael@0 43829 function __ZNK16btCollisionShape21calculateTemporalAabbERK11btTransformRK9btVector3S5_fRS3_S6_(i1, i2, i3, i4, d5, i6, i7) {
michael@0 43830 i1 = i1 | 0;
michael@0 43831 i2 = i2 | 0;
michael@0 43832 i3 = i3 | 0;
michael@0 43833 i4 = i4 | 0;
michael@0 43834 d5 = +d5;
michael@0 43835 i6 = i6 | 0;
michael@0 43836 i7 = i7 | 0;
michael@0 43837 var d8 = 0.0, i9 = 0, d10 = 0.0, i11 = 0, d12 = 0.0, i13 = 0, d14 = 0.0, i15 = 0, d16 = 0.0, i17 = 0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0;
michael@0 43838 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i1, i2, i6, i7);
michael@0 43839 i2 = i7 | 0;
michael@0 43840 d8 = +HEAPF32[i2 >> 2];
michael@0 43841 i9 = i7 + 4 | 0;
michael@0 43842 d10 = +HEAPF32[i9 >> 2];
michael@0 43843 i11 = i7 + 8 | 0;
michael@0 43844 d12 = +HEAPF32[i11 >> 2];
michael@0 43845 i13 = i6 | 0;
michael@0 43846 d14 = +HEAPF32[i13 >> 2];
michael@0 43847 i15 = i6 + 4 | 0;
michael@0 43848 d16 = +HEAPF32[i15 >> 2];
michael@0 43849 i17 = i6 + 8 | 0;
michael@0 43850 d18 = +HEAPF32[i17 >> 2];
michael@0 43851 d19 = +HEAPF32[i3 >> 2] * d5;
michael@0 43852 d20 = +HEAPF32[i3 + 4 >> 2] * d5;
michael@0 43853 d21 = +HEAPF32[i3 + 8 >> 2] * d5;
michael@0 43854 if (d19 > 0.0) {
michael@0 43855 d22 = d14;
michael@0 43856 d23 = d8 + d19;
michael@0 43857 } else {
michael@0 43858 d22 = d14 + d19;
michael@0 43859 d23 = d8;
michael@0 43860 }
michael@0 43861 if (d20 > 0.0) {
michael@0 43862 d24 = d16;
michael@0 43863 d25 = d10 + d20;
michael@0 43864 } else {
michael@0 43865 d24 = d16 + d20;
michael@0 43866 d25 = d10;
michael@0 43867 }
michael@0 43868 if (d21 > 0.0) {
michael@0 43869 d26 = d18;
michael@0 43870 d27 = d12 + d21;
michael@0 43871 } else {
michael@0 43872 d26 = d18 + d21;
michael@0 43873 d27 = d12;
michael@0 43874 }
michael@0 43875 d12 = +HEAPF32[i4 >> 2];
michael@0 43876 d21 = +HEAPF32[i4 + 4 >> 2];
michael@0 43877 d18 = +HEAPF32[i4 + 8 >> 2];
michael@0 43878 d10 = +Math_sqrt(+(d12 * d12 + d21 * d21 + d18 * d18));
michael@0 43879 d18 = d10 * +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i1 >> 2] | 0) + 16 >> 2] & 7](i1) * d5;
michael@0 43880 HEAPF32[i13 >> 2] = d22;
michael@0 43881 HEAPF32[i15 >> 2] = d24;
michael@0 43882 HEAPF32[i17 >> 2] = d26;
michael@0 43883 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 43884 HEAPF32[i2 >> 2] = d23;
michael@0 43885 HEAPF32[i9 >> 2] = d25;
michael@0 43886 HEAPF32[i11 >> 2] = d27;
michael@0 43887 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 43888 HEAPF32[i13 >> 2] = +HEAPF32[i13 >> 2] - d18;
michael@0 43889 HEAPF32[i15 >> 2] = +HEAPF32[i15 >> 2] - d18;
michael@0 43890 HEAPF32[i17 >> 2] = +HEAPF32[i17 >> 2] - d18;
michael@0 43891 HEAPF32[i2 >> 2] = d18 + +HEAPF32[i2 >> 2];
michael@0 43892 HEAPF32[i9 >> 2] = d18 + +HEAPF32[i9 >> 2];
michael@0 43893 HEAPF32[i11 >> 2] = d18 + +HEAPF32[i11 >> 2];
michael@0 43894 return;
michael@0 43895 }
michael@0 43896 function __ZN11btRigidBody25internalWritebackVelocityEf(i1, d2) {
michael@0 43897 i1 = i1 | 0;
michael@0 43898 d2 = +d2;
michael@0 43899 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, d7 = 0.0, i8 = 0, d9 = 0.0;
michael@0 43900 i3 = STACKTOP;
michael@0 43901 STACKTOP = STACKTOP + 64 | 0;
michael@0 43902 i4 = i3 | 0;
michael@0 43903 if (+HEAPF32[i1 + 336 >> 2] == 0.0) {
michael@0 43904 STACKTOP = i3;
michael@0 43905 return;
michael@0 43906 }
michael@0 43907 i5 = i1 + 304 | 0;
michael@0 43908 i6 = i1 + 308 | 0;
michael@0 43909 d7 = +HEAPF32[i6 >> 2] + +HEAPF32[i1 + 508 >> 2];
michael@0 43910 i8 = i1 + 312 | 0;
michael@0 43911 d9 = +HEAPF32[i8 >> 2] + +HEAPF32[i1 + 512 >> 2];
michael@0 43912 HEAPF32[i5 >> 2] = +HEAPF32[i5 >> 2] + +HEAPF32[i1 + 504 >> 2];
michael@0 43913 HEAPF32[i6 >> 2] = d7;
michael@0 43914 HEAPF32[i8 >> 2] = d9;
michael@0 43915 HEAPF32[i1 + 316 >> 2] = 0.0;
michael@0 43916 i8 = i1 + 320 | 0;
michael@0 43917 i6 = i1 + 324 | 0;
michael@0 43918 d9 = +HEAPF32[i6 >> 2] + +HEAPF32[i1 + 524 >> 2];
michael@0 43919 i5 = i1 + 328 | 0;
michael@0 43920 d7 = +HEAPF32[i5 >> 2] + +HEAPF32[i1 + 528 >> 2];
michael@0 43921 HEAPF32[i8 >> 2] = +HEAPF32[i8 >> 2] + +HEAPF32[i1 + 520 >> 2];
michael@0 43922 HEAPF32[i6 >> 2] = d9;
michael@0 43923 HEAPF32[i5 >> 2] = d7;
michael@0 43924 HEAPF32[i1 + 332 >> 2] = 0.0;
michael@0 43925 i5 = i1 + 4 | 0;
michael@0 43926 __ZN15btTransformUtil18integrateTransformERK11btTransformRK9btVector3S5_fRS0_(i5, i1 + 568 | 0, i1 + 584 | 0, d2, i4);
michael@0 43927 i6 = i5;
michael@0 43928 i5 = i4;
michael@0 43929 HEAP32[i6 >> 2] = HEAP32[i5 >> 2];
michael@0 43930 HEAP32[i6 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 43931 HEAP32[i6 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 43932 HEAP32[i6 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 43933 i5 = i1 + 20 | 0;
michael@0 43934 i6 = i4 + 16 | 0;
michael@0 43935 HEAP32[i5 >> 2] = HEAP32[i6 >> 2];
michael@0 43936 HEAP32[i5 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 43937 HEAP32[i5 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 43938 HEAP32[i5 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 43939 i6 = i1 + 36 | 0;
michael@0 43940 i5 = i4 + 32 | 0;
michael@0 43941 HEAP32[i6 >> 2] = HEAP32[i5 >> 2];
michael@0 43942 HEAP32[i6 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 43943 HEAP32[i6 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 43944 HEAP32[i6 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 43945 i5 = i1 + 52 | 0;
michael@0 43946 i1 = i4 + 48 | 0;
michael@0 43947 HEAP32[i5 >> 2] = HEAP32[i1 >> 2];
michael@0 43948 HEAP32[i5 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 43949 HEAP32[i5 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 43950 HEAP32[i5 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 43951 STACKTOP = i3;
michael@0 43952 return;
michael@0 43953 }
michael@0 43954 function __ZN34btClosestNotMeConvexResultCallback15addSingleResultERN16btCollisionWorld17LocalConvexResultEb(i1, i2, i3) {
michael@0 43955 i1 = i1 | 0;
michael@0 43956 i2 = i2 | 0;
michael@0 43957 i3 = i3 | 0;
michael@0 43958 var i4 = 0, d5 = 0.0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0;
michael@0 43959 i4 = HEAP32[i2 >> 2] | 0;
michael@0 43960 if ((i4 | 0) == (HEAP32[i1 + 80 >> 2] | 0)) {
michael@0 43961 d5 = 1.0;
michael@0 43962 return +d5;
michael@0 43963 }
michael@0 43964 if ((HEAP32[i4 + 204 >> 2] & 4 | 0) != 0) {
michael@0 43965 d5 = 1.0;
michael@0 43966 return +d5;
michael@0 43967 }
michael@0 43968 i6 = i2 + 8 | 0;
michael@0 43969 i7 = i2 + 12 | 0;
michael@0 43970 i8 = i2 + 16 | 0;
michael@0 43971 if ((+HEAPF32[i1 + 28 >> 2] - +HEAPF32[i1 + 12 >> 2]) * +HEAPF32[i6 >> 2] + (+HEAPF32[i1 + 32 >> 2] - +HEAPF32[i1 + 16 >> 2]) * +HEAPF32[i7 >> 2] + (+HEAPF32[i1 + 36 >> 2] - +HEAPF32[i1 + 20 >> 2]) * +HEAPF32[i8 >> 2] >= -0.0 - +HEAPF32[i1 + 84 >> 2]) {
michael@0 43972 d5 = 1.0;
michael@0 43973 return +d5;
michael@0 43974 }
michael@0 43975 i9 = i2 + 40 | 0;
michael@0 43976 HEAPF32[i1 + 4 >> 2] = +HEAPF32[i9 >> 2];
michael@0 43977 HEAP32[i1 + 76 >> 2] = i4;
michael@0 43978 if (i3) {
michael@0 43979 i3 = i1 + 44 | 0;
michael@0 43980 i10 = i6;
michael@0 43981 HEAP32[i3 >> 2] = HEAP32[i10 >> 2];
michael@0 43982 HEAP32[i3 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 43983 HEAP32[i3 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 43984 HEAP32[i3 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 43985 } else {
michael@0 43986 d11 = +HEAPF32[i2 + 8 >> 2];
michael@0 43987 d12 = +HEAPF32[i7 >> 2];
michael@0 43988 d13 = +HEAPF32[i8 >> 2];
michael@0 43989 d14 = d11 * +HEAPF32[i4 + 20 >> 2] + d12 * +HEAPF32[i4 + 24 >> 2] + d13 * +HEAPF32[i4 + 28 >> 2];
michael@0 43990 d15 = d11 * +HEAPF32[i4 + 36 >> 2] + d12 * +HEAPF32[i4 + 40 >> 2] + d13 * +HEAPF32[i4 + 44 >> 2];
michael@0 43991 HEAPF32[i1 + 44 >> 2] = +HEAPF32[i4 + 4 >> 2] * d11 + +HEAPF32[i4 + 8 >> 2] * d12 + +HEAPF32[i4 + 12 >> 2] * d13;
michael@0 43992 HEAPF32[i1 + 48 >> 2] = d14;
michael@0 43993 HEAPF32[i1 + 52 >> 2] = d15;
michael@0 43994 HEAPF32[i1 + 56 >> 2] = 0.0;
michael@0 43995 }
michael@0 43996 i4 = i1 + 60 | 0;
michael@0 43997 i1 = i2 + 24 | 0;
michael@0 43998 HEAP32[i4 >> 2] = HEAP32[i1 >> 2];
michael@0 43999 HEAP32[i4 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 44000 HEAP32[i4 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 44001 HEAP32[i4 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 44002 d5 = +HEAPF32[i9 >> 2];
michael@0 44003 return +d5;
michael@0 44004 }
michael@0 44005 function __ZNK11btTransform12inverseTimesERKS_(i1, i2, i3) {
michael@0 44006 i1 = i1 | 0;
michael@0 44007 i2 = i2 | 0;
michael@0 44008 i3 = i3 | 0;
michael@0 44009 var d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0;
michael@0 44010 d4 = +HEAPF32[i3 + 48 >> 2] - +HEAPF32[i2 + 48 >> 2];
michael@0 44011 d5 = +HEAPF32[i3 + 52 >> 2] - +HEAPF32[i2 + 52 >> 2];
michael@0 44012 d6 = +HEAPF32[i3 + 56 >> 2] - +HEAPF32[i2 + 56 >> 2];
michael@0 44013 d7 = +HEAPF32[i2 >> 2];
michael@0 44014 d8 = +HEAPF32[i3 >> 2];
michael@0 44015 d9 = +HEAPF32[i2 + 16 >> 2];
michael@0 44016 d10 = +HEAPF32[i3 + 16 >> 2];
michael@0 44017 d11 = +HEAPF32[i2 + 32 >> 2];
michael@0 44018 d12 = +HEAPF32[i3 + 32 >> 2];
michael@0 44019 d13 = +HEAPF32[i3 + 4 >> 2];
michael@0 44020 d14 = +HEAPF32[i3 + 20 >> 2];
michael@0 44021 d15 = +HEAPF32[i3 + 36 >> 2];
michael@0 44022 d16 = +HEAPF32[i3 + 8 >> 2];
michael@0 44023 d17 = +HEAPF32[i3 + 24 >> 2];
michael@0 44024 d18 = +HEAPF32[i3 + 40 >> 2];
michael@0 44025 d19 = +HEAPF32[i2 + 4 >> 2];
michael@0 44026 d20 = +HEAPF32[i2 + 20 >> 2];
michael@0 44027 d21 = +HEAPF32[i2 + 36 >> 2];
michael@0 44028 d22 = +HEAPF32[i2 + 8 >> 2];
michael@0 44029 d23 = +HEAPF32[i2 + 24 >> 2];
michael@0 44030 d24 = +HEAPF32[i2 + 40 >> 2];
michael@0 44031 HEAPF32[i1 >> 2] = d7 * d8 + d9 * d10 + d11 * d12;
michael@0 44032 HEAPF32[i1 + 4 >> 2] = d7 * d13 + d9 * d14 + d11 * d15;
michael@0 44033 HEAPF32[i1 + 8 >> 2] = d7 * d16 + d9 * d17 + d11 * d18;
michael@0 44034 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 44035 HEAPF32[i1 + 16 >> 2] = d8 * d19 + d10 * d20 + d12 * d21;
michael@0 44036 HEAPF32[i1 + 20 >> 2] = d13 * d19 + d14 * d20 + d15 * d21;
michael@0 44037 HEAPF32[i1 + 24 >> 2] = d16 * d19 + d17 * d20 + d18 * d21;
michael@0 44038 HEAPF32[i1 + 28 >> 2] = 0.0;
michael@0 44039 HEAPF32[i1 + 32 >> 2] = d8 * d22 + d10 * d23 + d12 * d24;
michael@0 44040 HEAPF32[i1 + 36 >> 2] = d13 * d22 + d14 * d23 + d15 * d24;
michael@0 44041 HEAPF32[i1 + 40 >> 2] = d16 * d22 + d17 * d23 + d18 * d24;
michael@0 44042 HEAPF32[i1 + 44 >> 2] = 0.0;
michael@0 44043 HEAPF32[i1 + 48 >> 2] = d4 * d7 + d5 * d9 + d6 * d11;
michael@0 44044 HEAPF32[i1 + 52 >> 2] = d4 * d19 + d5 * d20 + d6 * d21;
michael@0 44045 HEAPF32[i1 + 56 >> 2] = d4 * d22 + d5 * d23 + d6 * d24;
michael@0 44046 HEAPF32[i1 + 60 >> 2] = 0.0;
michael@0 44047 return;
michael@0 44048 }
michael@0 44049 function __ZN20btAlignedObjectArrayI6btFaceE6resizeEiRKS0_(i1, i2, i3) {
michael@0 44050 i1 = i1 | 0;
michael@0 44051 i2 = i2 | 0;
michael@0 44052 i3 = i3 | 0;
michael@0 44053 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0;
michael@0 44054 i4 = i1 + 4 | 0;
michael@0 44055 i5 = HEAP32[i4 >> 2] | 0;
michael@0 44056 if ((i5 | 0) <= (i2 | 0)) {
michael@0 44057 if ((i5 | 0) >= (i2 | 0)) {
michael@0 44058 HEAP32[i4 >> 2] = i2;
michael@0 44059 return;
michael@0 44060 }
michael@0 44061 __ZN20btAlignedObjectArrayI6btFaceE7reserveEi(i1, i2);
michael@0 44062 i6 = i1 + 12 | 0;
michael@0 44063 i7 = i3 | 0;
michael@0 44064 i8 = i3 + 20 | 0;
michael@0 44065 i9 = i3 + 40 | 0;
michael@0 44066 i3 = i5;
michael@0 44067 do {
michael@0 44068 i10 = (HEAP32[i6 >> 2] | 0) + (i3 * 56 | 0) | 0;
michael@0 44069 if ((i10 | 0) != 0) {
michael@0 44070 __ZN20btAlignedObjectArrayIiEC2ERKS0_(i10, i7);
michael@0 44071 __ZN20btAlignedObjectArrayIiEC2ERKS0_(i10 + 20 | 0, i8);
michael@0 44072 i11 = i10 + 40 | 0;
michael@0 44073 HEAP32[i11 >> 2] = HEAP32[i9 >> 2];
michael@0 44074 HEAP32[i11 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 44075 HEAP32[i11 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 44076 HEAP32[i11 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 44077 }
michael@0 44078 i3 = i3 + 1 | 0;
michael@0 44079 } while ((i3 | 0) < (i2 | 0));
michael@0 44080 HEAP32[i4 >> 2] = i2;
michael@0 44081 return;
michael@0 44082 }
michael@0 44083 i3 = i1 + 12 | 0;
michael@0 44084 i1 = i2;
michael@0 44085 do {
michael@0 44086 i9 = HEAP32[i3 >> 2] | 0;
michael@0 44087 i8 = i9 + (i1 * 56 | 0) + 24 | 0;
michael@0 44088 i7 = i9 + (i1 * 56 | 0) + 32 | 0;
michael@0 44089 i6 = HEAP32[i7 >> 2] | 0;
michael@0 44090 i11 = i9 + (i1 * 56 | 0) + 36 | 0;
michael@0 44091 if ((i6 | 0) != 0) {
michael@0 44092 if ((HEAP8[i11] | 0) != 0) {
michael@0 44093 __Z21btAlignedFreeInternalPv(i6);
michael@0 44094 }
michael@0 44095 HEAP32[i7 >> 2] = 0;
michael@0 44096 }
michael@0 44097 HEAP8[i11] = 1;
michael@0 44098 HEAP32[i7 >> 2] = 0;
michael@0 44099 HEAP32[i8 >> 2] = 0;
michael@0 44100 HEAP32[i9 + (i1 * 56 | 0) + 28 >> 2] = 0;
michael@0 44101 i8 = i9 + (i1 * 56 | 0) + 4 | 0;
michael@0 44102 i7 = i9 + (i1 * 56 | 0) + 12 | 0;
michael@0 44103 i11 = HEAP32[i7 >> 2] | 0;
michael@0 44104 i6 = i9 + (i1 * 56 | 0) + 16 | 0;
michael@0 44105 if ((i11 | 0) != 0) {
michael@0 44106 if ((HEAP8[i6] | 0) != 0) {
michael@0 44107 __Z21btAlignedFreeInternalPv(i11);
michael@0 44108 }
michael@0 44109 HEAP32[i7 >> 2] = 0;
michael@0 44110 }
michael@0 44111 HEAP8[i6] = 1;
michael@0 44112 HEAP32[i7 >> 2] = 0;
michael@0 44113 HEAP32[i8 >> 2] = 0;
michael@0 44114 HEAP32[i9 + (i1 * 56 | 0) + 8 >> 2] = 0;
michael@0 44115 i1 = i1 + 1 | 0;
michael@0 44116 } while ((i1 | 0) < (i5 | 0));
michael@0 44117 HEAP32[i4 >> 2] = i2;
michael@0 44118 return;
michael@0 44119 }
michael@0 44120 function __ZN35btSequentialImpulseConstraintSolver21addFrictionConstraintERK9btVector3P11btRigidBodyS4_iR15btManifoldPointS2_S2_P17btCollisionObjectS8_fff(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, d11, d12, d13) {
michael@0 44121 i1 = i1 | 0;
michael@0 44122 i2 = i2 | 0;
michael@0 44123 i3 = i3 | 0;
michael@0 44124 i4 = i4 | 0;
michael@0 44125 i5 = i5 | 0;
michael@0 44126 i6 = i6 | 0;
michael@0 44127 i7 = i7 | 0;
michael@0 44128 i8 = i8 | 0;
michael@0 44129 i9 = i9 | 0;
michael@0 44130 i10 = i10 | 0;
michael@0 44131 d11 = +d11;
michael@0 44132 d12 = +d12;
michael@0 44133 d13 = +d13;
michael@0 44134 var i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, i20 = 0, i21 = 0, i22 = 0;
michael@0 44135 i4 = i1 + 48 | 0;
michael@0 44136 i3 = HEAP32[i4 >> 2] | 0;
michael@0 44137 i14 = i1 + 52 | 0;
michael@0 44138 do {
michael@0 44139 if ((i3 | 0) == (HEAP32[i14 >> 2] | 0)) {
michael@0 44140 i15 = (i3 | 0) == 0 ? 1 : i3 << 1;
michael@0 44141 if ((i3 | 0) >= (i15 | 0)) {
michael@0 44142 i16 = i3;
michael@0 44143 break;
michael@0 44144 }
michael@0 44145 if ((i15 | 0) == 0) {
michael@0 44146 i17 = 0;
michael@0 44147 i18 = i3;
michael@0 44148 } else {
michael@0 44149 i19 = __Z22btAlignedAllocInternalji(i15 * 136 | 0, 16) | 0;
michael@0 44150 i17 = i19;
michael@0 44151 i18 = HEAP32[i4 >> 2] | 0;
michael@0 44152 }
michael@0 44153 i19 = i1 + 56 | 0;
michael@0 44154 if ((i18 | 0) > 0) {
michael@0 44155 i20 = 0;
michael@0 44156 do {
michael@0 44157 i21 = i17 + (i20 * 136 | 0) | 0;
michael@0 44158 i22 = (HEAP32[i19 >> 2] | 0) + (i20 * 136 | 0) | 0;
michael@0 44159 _memcpy(i21 | 0, i22 | 0, 136) | 0;
michael@0 44160 i20 = i20 + 1 | 0;
michael@0 44161 } while ((i20 | 0) < (i18 | 0));
michael@0 44162 }
michael@0 44163 i20 = HEAP32[i19 >> 2] | 0;
michael@0 44164 i22 = i1 + 60 | 0;
michael@0 44165 if ((i20 | 0) != 0) {
michael@0 44166 if ((HEAP8[i22] | 0) != 0) {
michael@0 44167 __Z21btAlignedFreeInternalPv(i20);
michael@0 44168 }
michael@0 44169 HEAP32[i19 >> 2] = 0;
michael@0 44170 }
michael@0 44171 HEAP8[i22] = 1;
michael@0 44172 HEAP32[i19 >> 2] = i17;
michael@0 44173 HEAP32[i14 >> 2] = i15;
michael@0 44174 i16 = HEAP32[i4 >> 2] | 0;
michael@0 44175 } else {
michael@0 44176 i16 = i3;
michael@0 44177 }
michael@0 44178 } while (0);
michael@0 44179 HEAP32[i4 >> 2] = i16 + 1;
michael@0 44180 i16 = HEAP32[i1 + 56 >> 2] | 0;
michael@0 44181 i1 = i16 + (i3 * 136 | 0) | 0;
michael@0 44182 HEAP32[i16 + (i3 * 136 | 0) + 100 >> 2] = i5;
michael@0 44183 __ZN35btSequentialImpulseConstraintSolver23setupFrictionConstraintER18btSolverConstraintRK9btVector3P11btRigidBodyS6_R15btManifoldPointS4_S4_P17btCollisionObjectSA_fff(0, i1, i2, 0, 0, i6, i7, i8, i9, i10, d11, d12, d13);
michael@0 44184 return i1 | 0;
michael@0 44185 }
michael@0 44186 function __ZN23btDiscreteDynamicsWorld14stepSimulationEfif(i1, d2, i3, d4) {
michael@0 44187 i1 = i1 | 0;
michael@0 44188 d2 = +d2;
michael@0 44189 i3 = i3 | 0;
michael@0 44190 d4 = +d4;
michael@0 44191 var i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, i9 = 0, d10 = 0.0, i11 = 0;
michael@0 44192 __ZN15CProfileManager5ResetEv();
michael@0 44193 __ZN15CProfileManager13Start_ProfileEPKc(696);
michael@0 44194 i5 = i1 + 236 | 0;
michael@0 44195 do {
michael@0 44196 if ((i3 | 0) == 0) {
michael@0 44197 HEAPF32[i5 >> 2] = d2;
michael@0 44198 i6 = +Math_abs(+d2) >= 1.1920928955078125e-7 | 0;
michael@0 44199 i7 = i6;
michael@0 44200 d8 = d2;
michael@0 44201 i9 = i6;
michael@0 44202 } else {
michael@0 44203 d10 = +HEAPF32[i5 >> 2] + d2;
michael@0 44204 HEAPF32[i5 >> 2] = d10;
michael@0 44205 if (d10 < d4) {
michael@0 44206 i7 = i3;
michael@0 44207 d8 = d4;
michael@0 44208 i9 = 0;
michael@0 44209 break;
michael@0 44210 }
michael@0 44211 i6 = ~~(d10 / d4);
michael@0 44212 HEAPF32[i5 >> 2] = d10 - +(i6 | 0) * d4;
michael@0 44213 i7 = i3;
michael@0 44214 d8 = d4;
michael@0 44215 i9 = i6;
michael@0 44216 }
michael@0 44217 } while (0);
michael@0 44218 i3 = i1 | 0;
michael@0 44219 i5 = i1;
michael@0 44220 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i5 >> 2] | 0) + 16 >> 2] & 127](i3) | 0) != 0) {
michael@0 44221 i6 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i5 >> 2] | 0) + 16 >> 2] & 127](i3) | 0;
michael@0 44222 HEAP8[12016] = (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i6 >> 2] | 0) + 48 >> 2] & 127](i6) | 0) >>> 4 & 1;
michael@0 44223 }
michael@0 44224 do {
michael@0 44225 if ((i9 | 0) == 0) {
michael@0 44226 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i1 >> 2] | 0) + 76 >> 2] & 511](i1);
michael@0 44227 } else {
michael@0 44228 i6 = (i9 | 0) > (i7 | 0) ? i7 : i9;
michael@0 44229 i3 = i1;
michael@0 44230 FUNCTION_TABLE_vif[HEAP32[(HEAP32[i3 >> 2] | 0) + 160 >> 2] & 31](i1, d8 * +(i6 | 0));
michael@0 44231 i5 = i1;
michael@0 44232 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i5 >> 2] | 0) + 164 >> 2] & 511](i1);
michael@0 44233 if ((i6 | 0) > 0) {
michael@0 44234 i11 = 0;
michael@0 44235 } else {
michael@0 44236 break;
michael@0 44237 }
michael@0 44238 do {
michael@0 44239 FUNCTION_TABLE_vif[HEAP32[(HEAP32[i3 >> 2] | 0) + 156 >> 2] & 31](i1, d8);
michael@0 44240 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i5 >> 2] | 0) + 76 >> 2] & 511](i1);
michael@0 44241 i11 = i11 + 1 | 0;
michael@0 44242 } while ((i11 | 0) < (i6 | 0));
michael@0 44243 }
michael@0 44244 } while (0);
michael@0 44245 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i1 >> 2] | 0) + 116 >> 2] & 511](i1);
michael@0 44246 __ZN15CProfileManager23Increment_Frame_CounterEv();
michael@0 44247 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 44248 return i9 | 0;
michael@0 44249 }
michael@0 44250 function __ZN11btRigidBody16addConstraintRefEP17btTypedConstraint(i1, i2) {
michael@0 44251 i1 = i1 | 0;
michael@0 44252 i2 = i2 | 0;
michael@0 44253 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 44254 i3 = i1 + 480 | 0;
michael@0 44255 i4 = HEAP32[i3 >> 2] | 0;
michael@0 44256 i5 = i1 + 488 | 0;
michael@0 44257 i6 = 0;
michael@0 44258 while (1) {
michael@0 44259 if ((i6 | 0) >= (i4 | 0)) {
michael@0 44260 break;
michael@0 44261 }
michael@0 44262 if ((HEAP32[(HEAP32[i5 >> 2] | 0) + (i6 << 2) >> 2] | 0) == (i2 | 0)) {
michael@0 44263 i7 = 1084;
michael@0 44264 break;
michael@0 44265 } else {
michael@0 44266 i6 = i6 + 1 | 0;
michael@0 44267 }
michael@0 44268 }
michael@0 44269 do {
michael@0 44270 if ((i7 | 0) == 1084) {
michael@0 44271 if ((i6 | 0) == (i4 | 0)) {
michael@0 44272 break;
michael@0 44273 }
michael@0 44274 i8 = i1 + 252 | 0;
michael@0 44275 HEAP32[i8 >> 2] = 1;
michael@0 44276 return;
michael@0 44277 }
michael@0 44278 } while (0);
michael@0 44279 i6 = i1 + 484 | 0;
michael@0 44280 do {
michael@0 44281 if ((i4 | 0) == (HEAP32[i6 >> 2] | 0)) {
michael@0 44282 i7 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 44283 if ((i4 | 0) >= (i7 | 0)) {
michael@0 44284 i9 = i4;
michael@0 44285 break;
michael@0 44286 }
michael@0 44287 if ((i7 | 0) == 0) {
michael@0 44288 i10 = 0;
michael@0 44289 i11 = i4;
michael@0 44290 } else {
michael@0 44291 i12 = __Z22btAlignedAllocInternalji(i7 << 2, 16) | 0;
michael@0 44292 i10 = i12;
michael@0 44293 i11 = HEAP32[i3 >> 2] | 0;
michael@0 44294 }
michael@0 44295 if ((i11 | 0) > 0) {
michael@0 44296 i12 = 0;
michael@0 44297 do {
michael@0 44298 i13 = i10 + (i12 << 2) | 0;
michael@0 44299 if ((i13 | 0) != 0) {
michael@0 44300 HEAP32[i13 >> 2] = HEAP32[(HEAP32[i5 >> 2] | 0) + (i12 << 2) >> 2];
michael@0 44301 }
michael@0 44302 i12 = i12 + 1 | 0;
michael@0 44303 } while ((i12 | 0) < (i11 | 0));
michael@0 44304 }
michael@0 44305 i12 = HEAP32[i5 >> 2] | 0;
michael@0 44306 i13 = i1 + 492 | 0;
michael@0 44307 if ((i12 | 0) == 0) {
michael@0 44308 i14 = i11;
michael@0 44309 } else {
michael@0 44310 if ((HEAP8[i13] | 0) == 0) {
michael@0 44311 i15 = i11;
michael@0 44312 } else {
michael@0 44313 __Z21btAlignedFreeInternalPv(i12);
michael@0 44314 i15 = HEAP32[i3 >> 2] | 0;
michael@0 44315 }
michael@0 44316 HEAP32[i5 >> 2] = 0;
michael@0 44317 i14 = i15;
michael@0 44318 }
michael@0 44319 HEAP8[i13] = 1;
michael@0 44320 HEAP32[i5 >> 2] = i10;
michael@0 44321 HEAP32[i6 >> 2] = i7;
michael@0 44322 i9 = i14;
michael@0 44323 } else {
michael@0 44324 i9 = i4;
michael@0 44325 }
michael@0 44326 } while (0);
michael@0 44327 i4 = (HEAP32[i5 >> 2] | 0) + (i9 << 2) | 0;
michael@0 44328 if ((i4 | 0) != 0) {
michael@0 44329 HEAP32[i4 >> 2] = i2;
michael@0 44330 }
michael@0 44331 HEAP32[i3 >> 2] = i9 + 1;
michael@0 44332 i8 = i1 + 252 | 0;
michael@0 44333 HEAP32[i8 >> 2] = 1;
michael@0 44334 return;
michael@0 44335 }
michael@0 44336 function ___dynamic_cast(i1, i2, i3, i4) {
michael@0 44337 i1 = i1 | 0;
michael@0 44338 i2 = i2 | 0;
michael@0 44339 i3 = i3 | 0;
michael@0 44340 i4 = i4 | 0;
michael@0 44341 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0;
michael@0 44342 i5 = STACKTOP;
michael@0 44343 STACKTOP = STACKTOP + 56 | 0;
michael@0 44344 i6 = i5 | 0;
michael@0 44345 i7 = HEAP32[i1 >> 2] | 0;
michael@0 44346 i8 = i1 + (HEAP32[i7 - 8 >> 2] | 0) | 0;
michael@0 44347 i9 = HEAP32[i7 - 4 >> 2] | 0;
michael@0 44348 i7 = i9;
michael@0 44349 HEAP32[i6 >> 2] = i3;
michael@0 44350 HEAP32[i6 + 4 >> 2] = i1;
michael@0 44351 HEAP32[i6 + 8 >> 2] = i2;
michael@0 44352 HEAP32[i6 + 12 >> 2] = i4;
michael@0 44353 i4 = i6 + 16 | 0;
michael@0 44354 i2 = i6 + 20 | 0;
michael@0 44355 i1 = i6 + 24 | 0;
michael@0 44356 i10 = i6 + 28 | 0;
michael@0 44357 i11 = i6 + 32 | 0;
michael@0 44358 i12 = i6 + 40 | 0;
michael@0 44359 _memset(i4 | 0, 0, 39);
michael@0 44360 if ((i9 | 0) == (i3 | 0)) {
michael@0 44361 HEAP32[i6 + 48 >> 2] = 1;
michael@0 44362 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i9 >> 2] | 0) + 20 >> 2] & 15](i7, i6, i8, i8, 1, 0);
michael@0 44363 STACKTOP = i5;
michael@0 44364 return ((HEAP32[i1 >> 2] | 0) == 1 ? i8 : 0) | 0;
michael@0 44365 }
michael@0 44366 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i9 >> 2] | 0) + 24 >> 2] & 63](i7, i6, i8, 1, 0);
michael@0 44367 i8 = HEAP32[i6 + 36 >> 2] | 0;
michael@0 44368 if ((i8 | 0) == 1) {
michael@0 44369 do {
michael@0 44370 if ((HEAP32[i1 >> 2] | 0) != 1) {
michael@0 44371 if ((HEAP32[i12 >> 2] | 0) != 0) {
michael@0 44372 i13 = 0;
michael@0 44373 STACKTOP = i5;
michael@0 44374 return i13 | 0;
michael@0 44375 }
michael@0 44376 if ((HEAP32[i10 >> 2] | 0) != 1) {
michael@0 44377 i13 = 0;
michael@0 44378 STACKTOP = i5;
michael@0 44379 return i13 | 0;
michael@0 44380 }
michael@0 44381 if ((HEAP32[i11 >> 2] | 0) == 1) {
michael@0 44382 break;
michael@0 44383 } else {
michael@0 44384 i13 = 0;
michael@0 44385 }
michael@0 44386 STACKTOP = i5;
michael@0 44387 return i13 | 0;
michael@0 44388 }
michael@0 44389 } while (0);
michael@0 44390 i13 = HEAP32[i4 >> 2] | 0;
michael@0 44391 STACKTOP = i5;
michael@0 44392 return i13 | 0;
michael@0 44393 } else if ((i8 | 0) == 0) {
michael@0 44394 if ((HEAP32[i12 >> 2] | 0) != 1) {
michael@0 44395 i13 = 0;
michael@0 44396 STACKTOP = i5;
michael@0 44397 return i13 | 0;
michael@0 44398 }
michael@0 44399 if ((HEAP32[i10 >> 2] | 0) != 1) {
michael@0 44400 i13 = 0;
michael@0 44401 STACKTOP = i5;
michael@0 44402 return i13 | 0;
michael@0 44403 }
michael@0 44404 i13 = (HEAP32[i11 >> 2] | 0) == 1 ? HEAP32[i2 >> 2] | 0 : 0;
michael@0 44405 STACKTOP = i5;
michael@0 44406 return i13 | 0;
michael@0 44407 } else {
michael@0 44408 i13 = 0;
michael@0 44409 STACKTOP = i5;
michael@0 44410 return i13 | 0;
michael@0 44411 }
michael@0 44412 return 0;
michael@0 44413 }
michael@0 44414 function __ZN20btAlignedObjectArrayI16btBroadphasePairE21expandNonInitializingEv(i1) {
michael@0 44415 i1 = i1 | 0;
michael@0 44416 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0;
michael@0 44417 i2 = i1 + 4 | 0;
michael@0 44418 i3 = HEAP32[i2 >> 2] | 0;
michael@0 44419 i4 = i1 + 8 | 0;
michael@0 44420 if ((i3 | 0) != (HEAP32[i4 >> 2] | 0)) {
michael@0 44421 i5 = i3;
michael@0 44422 i6 = i5 + 1 | 0;
michael@0 44423 HEAP32[i2 >> 2] = i6;
michael@0 44424 i7 = i1 + 12 | 0;
michael@0 44425 i8 = HEAP32[i7 >> 2] | 0;
michael@0 44426 i9 = i8 + (i3 << 4) | 0;
michael@0 44427 return i9 | 0;
michael@0 44428 }
michael@0 44429 i10 = (i3 | 0) == 0 ? 1 : i3 << 1;
michael@0 44430 if ((i3 | 0) >= (i10 | 0)) {
michael@0 44431 i5 = i3;
michael@0 44432 i6 = i5 + 1 | 0;
michael@0 44433 HEAP32[i2 >> 2] = i6;
michael@0 44434 i7 = i1 + 12 | 0;
michael@0 44435 i8 = HEAP32[i7 >> 2] | 0;
michael@0 44436 i9 = i8 + (i3 << 4) | 0;
michael@0 44437 return i9 | 0;
michael@0 44438 }
michael@0 44439 if ((i10 | 0) == 0) {
michael@0 44440 i11 = 0;
michael@0 44441 i12 = i3;
michael@0 44442 } else {
michael@0 44443 i13 = __Z22btAlignedAllocInternalji(i10 << 4, 16) | 0;
michael@0 44444 i11 = i13;
michael@0 44445 i12 = HEAP32[i2 >> 2] | 0;
michael@0 44446 }
michael@0 44447 i13 = i1 + 12 | 0;
michael@0 44448 if ((i12 | 0) > 0) {
michael@0 44449 i14 = 0;
michael@0 44450 do {
michael@0 44451 i15 = HEAP32[i13 >> 2] | 0;
michael@0 44452 HEAP32[i11 + (i14 << 4) >> 2] = HEAP32[i15 + (i14 << 4) >> 2];
michael@0 44453 HEAP32[i11 + (i14 << 4) + 4 >> 2] = HEAP32[i15 + (i14 << 4) + 4 >> 2];
michael@0 44454 HEAP32[i11 + (i14 << 4) + 8 >> 2] = HEAP32[i15 + (i14 << 4) + 8 >> 2];
michael@0 44455 HEAP32[i11 + (i14 << 4) + 12 >> 2] = HEAP32[i15 + (i14 << 4) + 12 >> 2];
michael@0 44456 i14 = i14 + 1 | 0;
michael@0 44457 } while ((i14 | 0) < (i12 | 0));
michael@0 44458 }
michael@0 44459 i14 = HEAP32[i13 >> 2] | 0;
michael@0 44460 i15 = i1 + 16 | 0;
michael@0 44461 if ((i14 | 0) == 0) {
michael@0 44462 i16 = i12;
michael@0 44463 } else {
michael@0 44464 if ((HEAP8[i15] | 0) == 0) {
michael@0 44465 i17 = i12;
michael@0 44466 } else {
michael@0 44467 __Z21btAlignedFreeInternalPv(i14);
michael@0 44468 i17 = HEAP32[i2 >> 2] | 0;
michael@0 44469 }
michael@0 44470 HEAP32[i13 >> 2] = 0;
michael@0 44471 i16 = i17;
michael@0 44472 }
michael@0 44473 HEAP8[i15] = 1;
michael@0 44474 HEAP32[i13 >> 2] = i11;
michael@0 44475 HEAP32[i4 >> 2] = i10;
michael@0 44476 i5 = i16;
michael@0 44477 i6 = i5 + 1 | 0;
michael@0 44478 HEAP32[i2 >> 2] = i6;
michael@0 44479 i7 = i1 + 12 | 0;
michael@0 44480 i8 = HEAP32[i7 >> 2] | 0;
michael@0 44481 i9 = i8 + (i3 << 4) | 0;
michael@0 44482 return i9 | 0;
michael@0 44483 }
michael@0 44484 function __ZNK10__cxxabiv121__vmi_class_type_info27has_unambiguous_public_baseEPNS_19__dynamic_cast_infoEPvi(i1, i2, i3, i4) {
michael@0 44485 i1 = i1 | 0;
michael@0 44486 i2 = i2 | 0;
michael@0 44487 i3 = i3 | 0;
michael@0 44488 i4 = i4 | 0;
michael@0 44489 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0;
michael@0 44490 if ((i1 | 0) == (HEAP32[i2 + 8 >> 2] | 0)) {
michael@0 44491 i5 = i2 + 16 | 0;
michael@0 44492 i6 = HEAP32[i5 >> 2] | 0;
michael@0 44493 if ((i6 | 0) == 0) {
michael@0 44494 HEAP32[i5 >> 2] = i3;
michael@0 44495 HEAP32[i2 + 24 >> 2] = i4;
michael@0 44496 HEAP32[i2 + 36 >> 2] = 1;
michael@0 44497 return;
michael@0 44498 }
michael@0 44499 if ((i6 | 0) != (i3 | 0)) {
michael@0 44500 i6 = i2 + 36 | 0;
michael@0 44501 HEAP32[i6 >> 2] = (HEAP32[i6 >> 2] | 0) + 1;
michael@0 44502 HEAP32[i2 + 24 >> 2] = 2;
michael@0 44503 HEAP8[i2 + 54 | 0] = 1;
michael@0 44504 return;
michael@0 44505 }
michael@0 44506 i6 = i2 + 24 | 0;
michael@0 44507 if ((HEAP32[i6 >> 2] | 0) != 2) {
michael@0 44508 return;
michael@0 44509 }
michael@0 44510 HEAP32[i6 >> 2] = i4;
michael@0 44511 return;
michael@0 44512 }
michael@0 44513 i6 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 44514 i5 = i1 + 16 + (i6 << 3) | 0;
michael@0 44515 i7 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 44516 i8 = i7 >> 8;
michael@0 44517 if ((i7 & 1 | 0) == 0) {
michael@0 44518 i9 = i8;
michael@0 44519 } else {
michael@0 44520 i9 = HEAP32[(HEAP32[i3 >> 2] | 0) + i8 >> 2] | 0;
michael@0 44521 }
michael@0 44522 i8 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 44523 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i8 >> 2] | 0) + 28 >> 2] & 127](i8, i2, i3 + i9 | 0, (i7 & 2 | 0) != 0 ? i4 : 2);
michael@0 44524 if ((i6 | 0) <= 1) {
michael@0 44525 return;
michael@0 44526 }
michael@0 44527 i6 = i2 + 54 | 0;
michael@0 44528 i7 = i3;
michael@0 44529 i9 = i1 + 24 | 0;
michael@0 44530 while (1) {
michael@0 44531 i1 = HEAP32[i9 + 4 >> 2] | 0;
michael@0 44532 i8 = i1 >> 8;
michael@0 44533 if ((i1 & 1 | 0) == 0) {
michael@0 44534 i10 = i8;
michael@0 44535 } else {
michael@0 44536 i10 = HEAP32[(HEAP32[i7 >> 2] | 0) + i8 >> 2] | 0;
michael@0 44537 }
michael@0 44538 i8 = HEAP32[i9 >> 2] | 0;
michael@0 44539 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i8 >> 2] | 0) + 28 >> 2] & 127](i8, i2, i3 + i10 | 0, (i1 & 2 | 0) != 0 ? i4 : 2);
michael@0 44540 if ((HEAP8[i6] & 1) != 0) {
michael@0 44541 i11 = 2027;
michael@0 44542 break;
michael@0 44543 }
michael@0 44544 i1 = i9 + 8 | 0;
michael@0 44545 if (i1 >>> 0 < i5 >>> 0) {
michael@0 44546 i9 = i1;
michael@0 44547 } else {
michael@0 44548 i11 = 2028;
michael@0 44549 break;
michael@0 44550 }
michael@0 44551 }
michael@0 44552 if ((i11 | 0) == 2027) {
michael@0 44553 return;
michael@0 44554 } else if ((i11 | 0) == 2028) {
michael@0 44555 return;
michael@0 44556 }
michael@0 44557 }
michael@0 44558 function __ZN16btCollisionWorld27ClosestConvexResultCallback15addSingleResultERNS_17LocalConvexResultEb(i1, i2, i3) {
michael@0 44559 i1 = i1 | 0;
michael@0 44560 i2 = i2 | 0;
michael@0 44561 i3 = i3 | 0;
michael@0 44562 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0;
michael@0 44563 i4 = i2 + 40 | 0;
michael@0 44564 HEAPF32[i1 + 4 >> 2] = +HEAPF32[i4 >> 2];
michael@0 44565 i5 = HEAP32[i2 >> 2] | 0;
michael@0 44566 HEAP32[i1 + 76 >> 2] = i5;
michael@0 44567 if (i3) {
michael@0 44568 i3 = i1 + 44 | 0;
michael@0 44569 i6 = i2 + 8 | 0;
michael@0 44570 HEAP32[i3 >> 2] = HEAP32[i6 >> 2];
michael@0 44571 HEAP32[i3 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 44572 HEAP32[i3 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 44573 HEAP32[i3 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 44574 i7 = i1 + 60 | 0;
michael@0 44575 i8 = i2 + 24 | 0;
michael@0 44576 i9 = i7;
michael@0 44577 i10 = i8;
michael@0 44578 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 44579 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 44580 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 44581 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 44582 d11 = +HEAPF32[i4 >> 2];
michael@0 44583 return +d11;
michael@0 44584 } else {
michael@0 44585 d12 = +HEAPF32[i2 + 8 >> 2];
michael@0 44586 d13 = +HEAPF32[i2 + 12 >> 2];
michael@0 44587 d14 = +HEAPF32[i2 + 16 >> 2];
michael@0 44588 d15 = d12 * +HEAPF32[i5 + 20 >> 2] + d13 * +HEAPF32[i5 + 24 >> 2] + d14 * +HEAPF32[i5 + 28 >> 2];
michael@0 44589 d16 = d12 * +HEAPF32[i5 + 36 >> 2] + d13 * +HEAPF32[i5 + 40 >> 2] + d14 * +HEAPF32[i5 + 44 >> 2];
michael@0 44590 HEAPF32[i1 + 44 >> 2] = +HEAPF32[i5 + 4 >> 2] * d12 + +HEAPF32[i5 + 8 >> 2] * d13 + +HEAPF32[i5 + 12 >> 2] * d14;
michael@0 44591 HEAPF32[i1 + 48 >> 2] = d15;
michael@0 44592 HEAPF32[i1 + 52 >> 2] = d16;
michael@0 44593 HEAPF32[i1 + 56 >> 2] = 0.0;
michael@0 44594 i7 = i1 + 60 | 0;
michael@0 44595 i8 = i2 + 24 | 0;
michael@0 44596 i9 = i7;
michael@0 44597 i10 = i8;
michael@0 44598 HEAP32[i9 >> 2] = HEAP32[i10 >> 2];
michael@0 44599 HEAP32[i9 + 4 >> 2] = HEAP32[i10 + 4 >> 2];
michael@0 44600 HEAP32[i9 + 8 >> 2] = HEAP32[i10 + 8 >> 2];
michael@0 44601 HEAP32[i9 + 12 >> 2] = HEAP32[i10 + 12 >> 2];
michael@0 44602 d11 = +HEAPF32[i4 >> 2];
michael@0 44603 return +d11;
michael@0 44604 }
michael@0 44605 return 0.0;
michael@0 44606 }
michael@0 44607 function __ZN23btDiscreteDynamicsWorld28internalSingleStepSimulationEf(i1, d2) {
michael@0 44608 i1 = i1 | 0;
michael@0 44609 d2 = +d2;
michael@0 44610 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 44611 __ZN15CProfileManager13Start_ProfileEPKc(536);
michael@0 44612 i3 = i1 | 0;
michael@0 44613 i4 = HEAP32[i1 + 92 >> 2] | 0;
michael@0 44614 if ((i4 | 0) != 0) {
michael@0 44615 FUNCTION_TABLE_vif[i4 & 31](i3, d2);
michael@0 44616 }
michael@0 44617 i4 = i1;
michael@0 44618 FUNCTION_TABLE_vif[HEAP32[(HEAP32[i4 >> 2] | 0) + 136 >> 2] & 31](i1, d2);
michael@0 44619 i5 = i1 | 0;
michael@0 44620 HEAPF32[i1 + 28 >> 2] = d2;
michael@0 44621 HEAP32[i1 + 32 >> 2] = 0;
michael@0 44622 HEAP32[i1 + 48 >> 2] = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 16 >> 2] & 127](i5) | 0;
michael@0 44623 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i1 >> 2] | 0) + 40 >> 2] & 511](i5);
michael@0 44624 if ((HEAP8[i1 + 44 | 0] | 0) != 0) {
michael@0 44625 FUNCTION_TABLE_vif[HEAP32[(HEAP32[i4 >> 2] | 0) + 144 >> 2] & 31](i1, d2);
michael@0 44626 }
michael@0 44627 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i1 >> 2] | 0) + 148 >> 2] & 511](i1);
michael@0 44628 HEAPF32[i1 + 112 >> 2] = d2;
michael@0 44629 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 152 >> 2] & 127](i1, i1 + 100 | 0);
michael@0 44630 FUNCTION_TABLE_vif[HEAP32[(HEAP32[i4 >> 2] | 0) + 140 >> 2] & 31](i1, d2);
michael@0 44631 __ZN15CProfileManager13Start_ProfileEPKc(456);
michael@0 44632 i4 = i1 + 248 | 0;
michael@0 44633 if ((HEAP32[i4 >> 2] | 0) > 0) {
michael@0 44634 i6 = i1 + 256 | 0;
michael@0 44635 i7 = 0;
michael@0 44636 do {
michael@0 44637 i8 = HEAP32[(HEAP32[i6 >> 2] | 0) + (i7 << 2) >> 2] | 0;
michael@0 44638 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i8 >> 2] | 0) + 8 >> 2] & 3](i8, i5, d2);
michael@0 44639 i7 = i7 + 1 | 0;
michael@0 44640 } while ((i7 | 0) < (HEAP32[i4 >> 2] | 0));
michael@0 44641 }
michael@0 44642 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 44643 __ZN23btDiscreteDynamicsWorld21updateActivationStateEf(i1, d2);
michael@0 44644 i4 = HEAP32[i1 + 88 >> 2] | 0;
michael@0 44645 if ((i4 | 0) == 0) {
michael@0 44646 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 44647 return;
michael@0 44648 }
michael@0 44649 FUNCTION_TABLE_vif[i4 & 31](i3, d2);
michael@0 44650 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 44651 return;
michael@0 44652 }
michael@0 44653 function __ZN23btDiscreteDynamicsWorldD2Ev(i1) {
michael@0 44654 i1 = i1 | 0;
michael@0 44655 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 44656 HEAP32[i1 >> 2] = 3272;
michael@0 44657 if ((HEAP8[i1 + 240 | 0] | 0) != 0) {
michael@0 44658 i2 = i1 + 176 | 0;
michael@0 44659 i3 = HEAP32[i2 >> 2] | 0;
michael@0 44660 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 44661 __Z21btAlignedFreeInternalPv(HEAP32[i2 >> 2] | 0);
michael@0 44662 }
michael@0 44663 if ((HEAP8[i1 + 241 | 0] | 0) != 0) {
michael@0 44664 i2 = i1 + 172 | 0;
michael@0 44665 i3 = HEAP32[i2 >> 2] | 0;
michael@0 44666 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 44667 __Z21btAlignedFreeInternalPv(HEAP32[i2 >> 2] | 0);
michael@0 44668 }
michael@0 44669 i2 = i1 + 248 | 0;
michael@0 44670 i3 = i1 + 256 | 0;
michael@0 44671 i4 = HEAP32[i3 >> 2] | 0;
michael@0 44672 i5 = i1 + 260 | 0;
michael@0 44673 if ((i4 | 0) != 0) {
michael@0 44674 if ((HEAP8[i5] | 0) != 0) {
michael@0 44675 __Z21btAlignedFreeInternalPv(i4);
michael@0 44676 }
michael@0 44677 HEAP32[i3 >> 2] = 0;
michael@0 44678 }
michael@0 44679 HEAP8[i5] = 1;
michael@0 44680 HEAP32[i3 >> 2] = 0;
michael@0 44681 HEAP32[i2 >> 2] = 0;
michael@0 44682 HEAP32[i1 + 252 >> 2] = 0;
michael@0 44683 i2 = i1 + 204 | 0;
michael@0 44684 i3 = i1 + 212 | 0;
michael@0 44685 i5 = HEAP32[i3 >> 2] | 0;
michael@0 44686 i4 = i1 + 216 | 0;
michael@0 44687 if ((i5 | 0) != 0) {
michael@0 44688 if ((HEAP8[i4] | 0) != 0) {
michael@0 44689 __Z21btAlignedFreeInternalPv(i5);
michael@0 44690 }
michael@0 44691 HEAP32[i3 >> 2] = 0;
michael@0 44692 }
michael@0 44693 HEAP8[i4] = 1;
michael@0 44694 HEAP32[i3 >> 2] = 0;
michael@0 44695 HEAP32[i2 >> 2] = 0;
michael@0 44696 HEAP32[i1 + 208 >> 2] = 0;
michael@0 44697 i2 = i1 + 184 | 0;
michael@0 44698 i3 = i1 + 192 | 0;
michael@0 44699 i4 = HEAP32[i3 >> 2] | 0;
michael@0 44700 i5 = i1 + 196 | 0;
michael@0 44701 if ((i4 | 0) == 0) {
michael@0 44702 HEAP8[i5] = 1;
michael@0 44703 HEAP32[i3 >> 2] = 0;
michael@0 44704 HEAP32[i2 >> 2] = 0;
michael@0 44705 i6 = i1 + 188 | 0;
michael@0 44706 HEAP32[i6 >> 2] = 0;
michael@0 44707 i7 = i1 | 0;
michael@0 44708 __ZN16btCollisionWorldD2Ev(i7);
michael@0 44709 return;
michael@0 44710 }
michael@0 44711 if ((HEAP8[i5] | 0) != 0) {
michael@0 44712 __Z21btAlignedFreeInternalPv(i4);
michael@0 44713 }
michael@0 44714 HEAP32[i3 >> 2] = 0;
michael@0 44715 HEAP8[i5] = 1;
michael@0 44716 HEAP32[i3 >> 2] = 0;
michael@0 44717 HEAP32[i2 >> 2] = 0;
michael@0 44718 i6 = i1 + 188 | 0;
michael@0 44719 HEAP32[i6 >> 2] = 0;
michael@0 44720 i7 = i1 | 0;
michael@0 44721 __ZN16btCollisionWorldD2Ev(i7);
michael@0 44722 return;
michael@0 44723 }
michael@0 44724 function __ZNK12gjkepa2_impl13MinkowskiDiff8Support1ERK9btVector3(i1, i2, i3) {
michael@0 44725 i1 = i1 | 0;
michael@0 44726 i2 = i2 | 0;
michael@0 44727 i3 = i3 | 0;
michael@0 44728 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0;
michael@0 44729 i4 = STACKTOP;
michael@0 44730 STACKTOP = STACKTOP + 32 | 0;
michael@0 44731 i5 = i4 | 0;
michael@0 44732 i6 = i4 + 16 | 0;
michael@0 44733 i7 = i2 + 120 | 0;
michael@0 44734 i8 = (HEAP32[i2 + 4 >> 2] | 0) + (HEAP32[i7 + 4 >> 2] | 0) | 0;
michael@0 44735 i9 = HEAP32[i7 >> 2] | 0;
michael@0 44736 if ((i9 & 1 | 0) == 0) {
michael@0 44737 i10 = i9;
michael@0 44738 } else {
michael@0 44739 i10 = HEAP32[(HEAP32[i8 >> 2] | 0) + (i9 - 1) >> 2] | 0;
michael@0 44740 }
michael@0 44741 d11 = +HEAPF32[i3 >> 2];
michael@0 44742 d12 = +HEAPF32[i3 + 4 >> 2];
michael@0 44743 d13 = +HEAPF32[i3 + 8 >> 2];
michael@0 44744 d14 = d11 * +HEAPF32[i2 + 24 >> 2] + d12 * +HEAPF32[i2 + 28 >> 2] + d13 * +HEAPF32[i2 + 32 >> 2];
michael@0 44745 d15 = d11 * +HEAPF32[i2 + 40 >> 2] + d12 * +HEAPF32[i2 + 44 >> 2] + d13 * +HEAPF32[i2 + 48 >> 2];
michael@0 44746 HEAPF32[i6 >> 2] = +HEAPF32[i2 + 8 >> 2] * d11 + +HEAPF32[i2 + 12 >> 2] * d12 + +HEAPF32[i2 + 16 >> 2] * d13;
michael@0 44747 HEAPF32[i6 + 4 >> 2] = d14;
michael@0 44748 HEAPF32[i6 + 8 >> 2] = d15;
michael@0 44749 HEAPF32[i6 + 12 >> 2] = 0.0;
michael@0 44750 FUNCTION_TABLE_viii[i10 & 127](i5, i8, i6);
michael@0 44751 d15 = +HEAPF32[i5 >> 2];
michael@0 44752 d14 = +HEAPF32[i5 + 4 >> 2];
michael@0 44753 d13 = +HEAPF32[i5 + 8 >> 2];
michael@0 44754 d12 = +HEAPF32[i2 + 108 >> 2] + (d15 * +HEAPF32[i2 + 72 >> 2] + d14 * +HEAPF32[i2 + 76 >> 2] + d13 * +HEAPF32[i2 + 80 >> 2]);
michael@0 44755 d11 = +HEAPF32[i2 + 112 >> 2] + (d15 * +HEAPF32[i2 + 88 >> 2] + d14 * +HEAPF32[i2 + 92 >> 2] + d13 * +HEAPF32[i2 + 96 >> 2]);
michael@0 44756 HEAPF32[i1 >> 2] = +HEAPF32[i2 + 104 >> 2] + (+HEAPF32[i2 + 56 >> 2] * d15 + +HEAPF32[i2 + 60 >> 2] * d14 + +HEAPF32[i2 + 64 >> 2] * d13);
michael@0 44757 HEAPF32[i1 + 4 >> 2] = d12;
michael@0 44758 HEAPF32[i1 + 8 >> 2] = d11;
michael@0 44759 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 44760 STACKTOP = i4;
michael@0 44761 return;
michael@0 44762 }
michael@0 44763 function __ZN23btDiscreteDynamicsWorld20serializeRigidBodiesEP12btSerializer(i1, i2) {
michael@0 44764 i1 = i1 | 0;
michael@0 44765 i2 = i2 | 0;
michael@0 44766 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0;
michael@0 44767 i3 = i1 + 8 | 0;
michael@0 44768 i4 = HEAP32[i3 >> 2] | 0;
michael@0 44769 if ((i4 | 0) > 0) {
michael@0 44770 i5 = i1 + 16 | 0;
michael@0 44771 i6 = i2;
michael@0 44772 i7 = i2;
michael@0 44773 i8 = 0;
michael@0 44774 i9 = i4;
michael@0 44775 while (1) {
michael@0 44776 i4 = HEAP32[(HEAP32[i5 >> 2] | 0) + (i8 << 2) >> 2] | 0;
michael@0 44777 if ((HEAP32[i4 + 232 >> 2] & 2 | 0) == 0) {
michael@0 44778 i10 = i9;
michael@0 44779 } else {
michael@0 44780 i11 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i4 >> 2] | 0) + 16 >> 2] & 127](i4) | 0;
michael@0 44781 i12 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 16 >> 2] & 31](i2, i11, 1) | 0;
michael@0 44782 i11 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i4 >> 2] | 0) + 20 >> 2] & 31](i4, HEAP32[i12 + 8 >> 2] | 0, i2) | 0;
michael@0 44783 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 20 >> 2] & 63](i2, i12, i11, 1497645650, i4);
michael@0 44784 i10 = HEAP32[i3 >> 2] | 0;
michael@0 44785 }
michael@0 44786 i4 = i8 + 1 | 0;
michael@0 44787 if ((i4 | 0) < (i10 | 0)) {
michael@0 44788 i8 = i4;
michael@0 44789 i9 = i10;
michael@0 44790 } else {
michael@0 44791 break;
michael@0 44792 }
michael@0 44793 }
michael@0 44794 }
michael@0 44795 i10 = i1 + 184 | 0;
michael@0 44796 if ((HEAP32[i10 >> 2] | 0) <= 0) {
michael@0 44797 return;
michael@0 44798 }
michael@0 44799 i9 = i1 + 192 | 0;
michael@0 44800 i1 = i2;
michael@0 44801 i8 = i2;
michael@0 44802 i3 = 0;
michael@0 44803 do {
michael@0 44804 i7 = HEAP32[(HEAP32[i9 >> 2] | 0) + (i3 << 2) >> 2] | 0;
michael@0 44805 i6 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i7 >> 2] | 0) + 36 >> 2] & 127](i7) | 0;
michael@0 44806 i5 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 16 >> 2] & 31](i2, i6, 1) | 0;
michael@0 44807 i6 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 40 >> 2] & 31](i7, HEAP32[i5 + 8 >> 2] | 0, i2) | 0;
michael@0 44808 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i8 >> 2] | 0) + 20 >> 2] & 63](i2, i5, i6, 1397641027, i7);
michael@0 44809 i3 = i3 + 1 | 0;
michael@0 44810 } while ((i3 | 0) < (HEAP32[i10 >> 2] | 0));
michael@0 44811 return;
michael@0 44812 }
michael@0 44813 function __ZN23btDiscreteDynamicsWorld13addConstraintEP17btTypedConstraintb(i1, i2, i3) {
michael@0 44814 i1 = i1 | 0;
michael@0 44815 i2 = i2 | 0;
michael@0 44816 i3 = i3 | 0;
michael@0 44817 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 44818 i4 = i1 + 184 | 0;
michael@0 44819 i5 = HEAP32[i4 >> 2] | 0;
michael@0 44820 i6 = i1 + 188 | 0;
michael@0 44821 do {
michael@0 44822 if ((i5 | 0) == (HEAP32[i6 >> 2] | 0)) {
michael@0 44823 i7 = (i5 | 0) == 0 ? 1 : i5 << 1;
michael@0 44824 if ((i5 | 0) >= (i7 | 0)) {
michael@0 44825 i8 = i5;
michael@0 44826 break;
michael@0 44827 }
michael@0 44828 if ((i7 | 0) == 0) {
michael@0 44829 i9 = 0;
michael@0 44830 i10 = i5;
michael@0 44831 } else {
michael@0 44832 i11 = __Z22btAlignedAllocInternalji(i7 << 2, 16) | 0;
michael@0 44833 i9 = i11;
michael@0 44834 i10 = HEAP32[i4 >> 2] | 0;
michael@0 44835 }
michael@0 44836 i11 = i1 + 192 | 0;
michael@0 44837 if ((i10 | 0) > 0) {
michael@0 44838 i12 = 0;
michael@0 44839 do {
michael@0 44840 i13 = i9 + (i12 << 2) | 0;
michael@0 44841 if ((i13 | 0) != 0) {
michael@0 44842 HEAP32[i13 >> 2] = HEAP32[(HEAP32[i11 >> 2] | 0) + (i12 << 2) >> 2];
michael@0 44843 }
michael@0 44844 i12 = i12 + 1 | 0;
michael@0 44845 } while ((i12 | 0) < (i10 | 0));
michael@0 44846 }
michael@0 44847 i12 = HEAP32[i11 >> 2] | 0;
michael@0 44848 i13 = i1 + 196 | 0;
michael@0 44849 if ((i12 | 0) == 0) {
michael@0 44850 i14 = i10;
michael@0 44851 } else {
michael@0 44852 if ((HEAP8[i13] | 0) == 0) {
michael@0 44853 i15 = i10;
michael@0 44854 } else {
michael@0 44855 __Z21btAlignedFreeInternalPv(i12);
michael@0 44856 i15 = HEAP32[i4 >> 2] | 0;
michael@0 44857 }
michael@0 44858 HEAP32[i11 >> 2] = 0;
michael@0 44859 i14 = i15;
michael@0 44860 }
michael@0 44861 HEAP8[i13] = 1;
michael@0 44862 HEAP32[i11 >> 2] = i9;
michael@0 44863 HEAP32[i6 >> 2] = i7;
michael@0 44864 i8 = i14;
michael@0 44865 } else {
michael@0 44866 i8 = i5;
michael@0 44867 }
michael@0 44868 } while (0);
michael@0 44869 i5 = (HEAP32[i1 + 192 >> 2] | 0) + (i8 << 2) | 0;
michael@0 44870 if ((i5 | 0) != 0) {
michael@0 44871 HEAP32[i5 >> 2] = i2;
michael@0 44872 }
michael@0 44873 HEAP32[i4 >> 2] = i8 + 1;
michael@0 44874 if (!i3) {
michael@0 44875 return;
michael@0 44876 }
michael@0 44877 __ZN11btRigidBody16addConstraintRefEP17btTypedConstraint(HEAP32[i2 + 24 >> 2] | 0, i2);
michael@0 44878 __ZN11btRigidBody16addConstraintRefEP17btTypedConstraint(HEAP32[i2 + 28 >> 2] | 0, i2);
michael@0 44879 return;
michael@0 44880 }
michael@0 44881 function __ZNK23btPolyhedralConvexShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i(i1, i2, i3, i4) {
michael@0 44882 i1 = i1 | 0;
michael@0 44883 i2 = i2 | 0;
michael@0 44884 i3 = i3 | 0;
michael@0 44885 i4 = i4 | 0;
michael@0 44886 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, d20 = 0.0;
michael@0 44887 i5 = STACKTOP;
michael@0 44888 STACKTOP = STACKTOP + 16 | 0;
michael@0 44889 i6 = i5 | 0;
michael@0 44890 if ((i4 | 0) > 0) {
michael@0 44891 i7 = 0;
michael@0 44892 } else {
michael@0 44893 STACKTOP = i5;
michael@0 44894 return;
michael@0 44895 }
michael@0 44896 do {
michael@0 44897 HEAPF32[i3 + (i7 << 4) + 12 >> 2] = -999999984306749400.0;
michael@0 44898 i7 = i7 + 1 | 0;
michael@0 44899 } while ((i7 | 0) < (i4 | 0));
michael@0 44900 i7 = i1;
michael@0 44901 i8 = i1;
michael@0 44902 i9 = i6 | 0;
michael@0 44903 i10 = i6 + 4 | 0;
michael@0 44904 i11 = i6 + 8 | 0;
michael@0 44905 i12 = i6;
michael@0 44906 i13 = 0;
michael@0 44907 do {
michael@0 44908 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i7 >> 2] | 0) + 88 >> 2] & 127](i1) | 0) > 0) {
michael@0 44909 i14 = i2 + (i13 << 4) | 0;
michael@0 44910 i15 = i2 + (i13 << 4) + 4 | 0;
michael@0 44911 i16 = i2 + (i13 << 4) + 8 | 0;
michael@0 44912 i17 = i3 + (i13 << 4) + 12 | 0;
michael@0 44913 i18 = i3 + (i13 << 4) | 0;
michael@0 44914 i19 = 0;
michael@0 44915 do {
michael@0 44916 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i8 >> 2] | 0) + 100 >> 2] & 127](i1, i19, i6);
michael@0 44917 d20 = +HEAPF32[i14 >> 2] * +HEAPF32[i9 >> 2] + +HEAPF32[i15 >> 2] * +HEAPF32[i10 >> 2] + +HEAPF32[i16 >> 2] * +HEAPF32[i11 >> 2];
michael@0 44918 if (d20 > +HEAPF32[i17 >> 2]) {
michael@0 44919 HEAP32[i18 >> 2] = HEAP32[i12 >> 2];
michael@0 44920 HEAP32[i18 + 4 >> 2] = HEAP32[i12 + 4 >> 2];
michael@0 44921 HEAP32[i18 + 8 >> 2] = HEAP32[i12 + 8 >> 2];
michael@0 44922 HEAP32[i18 + 12 >> 2] = HEAP32[i12 + 12 >> 2];
michael@0 44923 HEAPF32[i17 >> 2] = d20;
michael@0 44924 }
michael@0 44925 i19 = i19 + 1 | 0;
michael@0 44926 } while ((i19 | 0) < (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i7 >> 2] | 0) + 88 >> 2] & 127](i1) | 0));
michael@0 44927 }
michael@0 44928 i13 = i13 + 1 | 0;
michael@0 44929 } while ((i13 | 0) < (i4 | 0));
michael@0 44930 STACKTOP = i5;
michael@0 44931 return;
michael@0 44932 }
michael@0 44933 function __ZN11btRigidBody12applyImpulseERK9btVector3S2_(i1, i2, i3) {
michael@0 44934 i1 = i1 | 0;
michael@0 44935 i2 = i2 | 0;
michael@0 44936 i3 = i3 | 0;
michael@0 44937 var d4 = 0.0, i5 = 0, d6 = 0.0, i7 = 0, d8 = 0.0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0;
michael@0 44938 d4 = +HEAPF32[i1 + 336 >> 2];
michael@0 44939 if (d4 == 0.0) {
michael@0 44940 return;
michael@0 44941 }
michael@0 44942 i5 = i2 | 0;
michael@0 44943 d6 = +HEAPF32[i1 + 340 >> 2];
michael@0 44944 i7 = i2 + 4 | 0;
michael@0 44945 d8 = +HEAPF32[i1 + 344 >> 2];
michael@0 44946 i9 = i2 + 8 | 0;
michael@0 44947 d10 = +HEAPF32[i1 + 348 >> 2];
michael@0 44948 d11 = d4 * +HEAPF32[i7 >> 2] * d8;
michael@0 44949 d12 = d4 * +HEAPF32[i9 >> 2] * d10;
michael@0 44950 i2 = i1 + 304 | 0;
michael@0 44951 HEAPF32[i2 >> 2] = d4 * +HEAPF32[i5 >> 2] * d6 + +HEAPF32[i2 >> 2];
michael@0 44952 i2 = i1 + 308 | 0;
michael@0 44953 HEAPF32[i2 >> 2] = d11 + +HEAPF32[i2 >> 2];
michael@0 44954 i2 = i1 + 312 | 0;
michael@0 44955 HEAPF32[i2 >> 2] = d12 + +HEAPF32[i2 >> 2];
michael@0 44956 i2 = i1 + 536 | 0;
michael@0 44957 if ((i2 | 0) == 0) {
michael@0 44958 return;
michael@0 44959 }
michael@0 44960 d12 = d6 * +HEAPF32[i5 >> 2];
michael@0 44961 d6 = d8 * +HEAPF32[i7 >> 2];
michael@0 44962 d8 = d10 * +HEAPF32[i9 >> 2];
michael@0 44963 d10 = +HEAPF32[i3 + 4 >> 2];
michael@0 44964 d11 = +HEAPF32[i3 + 8 >> 2];
michael@0 44965 d4 = d10 * d8 - d6 * d11;
michael@0 44966 d13 = +HEAPF32[i3 >> 2];
michael@0 44967 d14 = d12 * d11 - d8 * d13;
michael@0 44968 d8 = d6 * d13 - d12 * d10;
michael@0 44969 d10 = (d4 * +HEAPF32[i1 + 272 >> 2] + d14 * +HEAPF32[i1 + 276 >> 2] + d8 * +HEAPF32[i1 + 280 >> 2]) * +HEAPF32[i1 + 540 >> 2];
michael@0 44970 d12 = (d4 * +HEAPF32[i1 + 288 >> 2] + d14 * +HEAPF32[i1 + 292 >> 2] + d8 * +HEAPF32[i1 + 296 >> 2]) * +HEAPF32[i1 + 544 >> 2];
michael@0 44971 i3 = i1 + 320 | 0;
michael@0 44972 HEAPF32[i3 >> 2] = (+HEAPF32[i1 + 256 >> 2] * d4 + +HEAPF32[i1 + 260 >> 2] * d14 + d8 * +HEAPF32[i1 + 264 >> 2]) * +HEAPF32[i2 >> 2] + +HEAPF32[i3 >> 2];
michael@0 44973 i3 = i1 + 324 | 0;
michael@0 44974 HEAPF32[i3 >> 2] = d10 + +HEAPF32[i3 >> 2];
michael@0 44975 i3 = i1 + 328 | 0;
michael@0 44976 HEAPF32[i3 >> 2] = d12 + +HEAPF32[i3 >> 2];
michael@0 44977 return;
michael@0 44978 }
michael@0 44979 function __ZN34btSphereTriangleCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 44980 i1 = i1 | 0;
michael@0 44981 i2 = i2 | 0;
michael@0 44982 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 44983 i3 = i1 + 12 | 0;
michael@0 44984 if ((HEAP32[i3 >> 2] | 0) == 0) {
michael@0 44985 return;
michael@0 44986 }
michael@0 44987 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 44988 return;
michael@0 44989 }
michael@0 44990 i1 = i2 + 4 | 0;
michael@0 44991 i4 = HEAP32[i1 >> 2] | 0;
michael@0 44992 i5 = i2 + 8 | 0;
michael@0 44993 do {
michael@0 44994 if ((i4 | 0) == (HEAP32[i5 >> 2] | 0)) {
michael@0 44995 i6 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 44996 if ((i4 | 0) >= (i6 | 0)) {
michael@0 44997 i7 = i4;
michael@0 44998 break;
michael@0 44999 }
michael@0 45000 if ((i6 | 0) == 0) {
michael@0 45001 i8 = 0;
michael@0 45002 i9 = i4;
michael@0 45003 } else {
michael@0 45004 i10 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 45005 i8 = i10;
michael@0 45006 i9 = HEAP32[i1 >> 2] | 0;
michael@0 45007 }
michael@0 45008 i10 = i2 + 12 | 0;
michael@0 45009 if ((i9 | 0) > 0) {
michael@0 45010 i11 = 0;
michael@0 45011 do {
michael@0 45012 i12 = i8 + (i11 << 2) | 0;
michael@0 45013 if ((i12 | 0) != 0) {
michael@0 45014 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i10 >> 2] | 0) + (i11 << 2) >> 2];
michael@0 45015 }
michael@0 45016 i11 = i11 + 1 | 0;
michael@0 45017 } while ((i11 | 0) < (i9 | 0));
michael@0 45018 }
michael@0 45019 i11 = HEAP32[i10 >> 2] | 0;
michael@0 45020 i12 = i2 + 16 | 0;
michael@0 45021 if ((i11 | 0) == 0) {
michael@0 45022 i13 = i9;
michael@0 45023 } else {
michael@0 45024 if ((HEAP8[i12] | 0) == 0) {
michael@0 45025 i14 = i9;
michael@0 45026 } else {
michael@0 45027 __Z21btAlignedFreeInternalPv(i11);
michael@0 45028 i14 = HEAP32[i1 >> 2] | 0;
michael@0 45029 }
michael@0 45030 HEAP32[i10 >> 2] = 0;
michael@0 45031 i13 = i14;
michael@0 45032 }
michael@0 45033 HEAP8[i12] = 1;
michael@0 45034 HEAP32[i10 >> 2] = i8;
michael@0 45035 HEAP32[i5 >> 2] = i6;
michael@0 45036 i7 = i13;
michael@0 45037 } else {
michael@0 45038 i7 = i4;
michael@0 45039 }
michael@0 45040 } while (0);
michael@0 45041 i4 = (HEAP32[i2 + 12 >> 2] | 0) + (i7 << 2) | 0;
michael@0 45042 if ((i4 | 0) != 0) {
michael@0 45043 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 45044 }
michael@0 45045 HEAP32[i1 >> 2] = i7 + 1;
michael@0 45046 return;
michael@0 45047 }
michael@0 45048 function __ZN32btSphereSphereCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 45049 i1 = i1 | 0;
michael@0 45050 i2 = i2 | 0;
michael@0 45051 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 45052 i3 = i1 + 12 | 0;
michael@0 45053 if ((HEAP32[i3 >> 2] | 0) == 0) {
michael@0 45054 return;
michael@0 45055 }
michael@0 45056 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 45057 return;
michael@0 45058 }
michael@0 45059 i1 = i2 + 4 | 0;
michael@0 45060 i4 = HEAP32[i1 >> 2] | 0;
michael@0 45061 i5 = i2 + 8 | 0;
michael@0 45062 do {
michael@0 45063 if ((i4 | 0) == (HEAP32[i5 >> 2] | 0)) {
michael@0 45064 i6 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 45065 if ((i4 | 0) >= (i6 | 0)) {
michael@0 45066 i7 = i4;
michael@0 45067 break;
michael@0 45068 }
michael@0 45069 if ((i6 | 0) == 0) {
michael@0 45070 i8 = 0;
michael@0 45071 i9 = i4;
michael@0 45072 } else {
michael@0 45073 i10 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 45074 i8 = i10;
michael@0 45075 i9 = HEAP32[i1 >> 2] | 0;
michael@0 45076 }
michael@0 45077 i10 = i2 + 12 | 0;
michael@0 45078 if ((i9 | 0) > 0) {
michael@0 45079 i11 = 0;
michael@0 45080 do {
michael@0 45081 i12 = i8 + (i11 << 2) | 0;
michael@0 45082 if ((i12 | 0) != 0) {
michael@0 45083 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i10 >> 2] | 0) + (i11 << 2) >> 2];
michael@0 45084 }
michael@0 45085 i11 = i11 + 1 | 0;
michael@0 45086 } while ((i11 | 0) < (i9 | 0));
michael@0 45087 }
michael@0 45088 i11 = HEAP32[i10 >> 2] | 0;
michael@0 45089 i12 = i2 + 16 | 0;
michael@0 45090 if ((i11 | 0) == 0) {
michael@0 45091 i13 = i9;
michael@0 45092 } else {
michael@0 45093 if ((HEAP8[i12] | 0) == 0) {
michael@0 45094 i14 = i9;
michael@0 45095 } else {
michael@0 45096 __Z21btAlignedFreeInternalPv(i11);
michael@0 45097 i14 = HEAP32[i1 >> 2] | 0;
michael@0 45098 }
michael@0 45099 HEAP32[i10 >> 2] = 0;
michael@0 45100 i13 = i14;
michael@0 45101 }
michael@0 45102 HEAP8[i12] = 1;
michael@0 45103 HEAP32[i10 >> 2] = i8;
michael@0 45104 HEAP32[i5 >> 2] = i6;
michael@0 45105 i7 = i13;
michael@0 45106 } else {
michael@0 45107 i7 = i4;
michael@0 45108 }
michael@0 45109 } while (0);
michael@0 45110 i4 = (HEAP32[i2 + 12 >> 2] | 0) + (i7 << 2) | 0;
michael@0 45111 if ((i4 | 0) != 0) {
michael@0 45112 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 45113 }
michael@0 45114 HEAP32[i1 >> 2] = i7 + 1;
michael@0 45115 return;
michael@0 45116 }
michael@0 45117 function __ZN31btConvexPlaneCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 45118 i1 = i1 | 0;
michael@0 45119 i2 = i2 | 0;
michael@0 45120 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 45121 i3 = i1 + 12 | 0;
michael@0 45122 if ((HEAP32[i3 >> 2] | 0) == 0) {
michael@0 45123 return;
michael@0 45124 }
michael@0 45125 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 45126 return;
michael@0 45127 }
michael@0 45128 i1 = i2 + 4 | 0;
michael@0 45129 i4 = HEAP32[i1 >> 2] | 0;
michael@0 45130 i5 = i2 + 8 | 0;
michael@0 45131 do {
michael@0 45132 if ((i4 | 0) == (HEAP32[i5 >> 2] | 0)) {
michael@0 45133 i6 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 45134 if ((i4 | 0) >= (i6 | 0)) {
michael@0 45135 i7 = i4;
michael@0 45136 break;
michael@0 45137 }
michael@0 45138 if ((i6 | 0) == 0) {
michael@0 45139 i8 = 0;
michael@0 45140 i9 = i4;
michael@0 45141 } else {
michael@0 45142 i10 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 45143 i8 = i10;
michael@0 45144 i9 = HEAP32[i1 >> 2] | 0;
michael@0 45145 }
michael@0 45146 i10 = i2 + 12 | 0;
michael@0 45147 if ((i9 | 0) > 0) {
michael@0 45148 i11 = 0;
michael@0 45149 do {
michael@0 45150 i12 = i8 + (i11 << 2) | 0;
michael@0 45151 if ((i12 | 0) != 0) {
michael@0 45152 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i10 >> 2] | 0) + (i11 << 2) >> 2];
michael@0 45153 }
michael@0 45154 i11 = i11 + 1 | 0;
michael@0 45155 } while ((i11 | 0) < (i9 | 0));
michael@0 45156 }
michael@0 45157 i11 = HEAP32[i10 >> 2] | 0;
michael@0 45158 i12 = i2 + 16 | 0;
michael@0 45159 if ((i11 | 0) == 0) {
michael@0 45160 i13 = i9;
michael@0 45161 } else {
michael@0 45162 if ((HEAP8[i12] | 0) == 0) {
michael@0 45163 i14 = i9;
michael@0 45164 } else {
michael@0 45165 __Z21btAlignedFreeInternalPv(i11);
michael@0 45166 i14 = HEAP32[i1 >> 2] | 0;
michael@0 45167 }
michael@0 45168 HEAP32[i10 >> 2] = 0;
michael@0 45169 i13 = i14;
michael@0 45170 }
michael@0 45171 HEAP8[i12] = 1;
michael@0 45172 HEAP32[i10 >> 2] = i8;
michael@0 45173 HEAP32[i5 >> 2] = i6;
michael@0 45174 i7 = i13;
michael@0 45175 } else {
michael@0 45176 i7 = i4;
michael@0 45177 }
michael@0 45178 } while (0);
michael@0 45179 i4 = (HEAP32[i2 + 12 >> 2] | 0) + (i7 << 2) | 0;
michael@0 45180 if ((i4 | 0) != 0) {
michael@0 45181 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 45182 }
michael@0 45183 HEAP32[i1 >> 2] = i7 + 1;
michael@0 45184 return;
michael@0 45185 }
michael@0 45186 function __ZN26btBoxBoxCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 45187 i1 = i1 | 0;
michael@0 45188 i2 = i2 | 0;
michael@0 45189 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 45190 i3 = i1 + 12 | 0;
michael@0 45191 if ((HEAP32[i3 >> 2] | 0) == 0) {
michael@0 45192 return;
michael@0 45193 }
michael@0 45194 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 45195 return;
michael@0 45196 }
michael@0 45197 i1 = i2 + 4 | 0;
michael@0 45198 i4 = HEAP32[i1 >> 2] | 0;
michael@0 45199 i5 = i2 + 8 | 0;
michael@0 45200 do {
michael@0 45201 if ((i4 | 0) == (HEAP32[i5 >> 2] | 0)) {
michael@0 45202 i6 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 45203 if ((i4 | 0) >= (i6 | 0)) {
michael@0 45204 i7 = i4;
michael@0 45205 break;
michael@0 45206 }
michael@0 45207 if ((i6 | 0) == 0) {
michael@0 45208 i8 = 0;
michael@0 45209 i9 = i4;
michael@0 45210 } else {
michael@0 45211 i10 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 45212 i8 = i10;
michael@0 45213 i9 = HEAP32[i1 >> 2] | 0;
michael@0 45214 }
michael@0 45215 i10 = i2 + 12 | 0;
michael@0 45216 if ((i9 | 0) > 0) {
michael@0 45217 i11 = 0;
michael@0 45218 do {
michael@0 45219 i12 = i8 + (i11 << 2) | 0;
michael@0 45220 if ((i12 | 0) != 0) {
michael@0 45221 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i10 >> 2] | 0) + (i11 << 2) >> 2];
michael@0 45222 }
michael@0 45223 i11 = i11 + 1 | 0;
michael@0 45224 } while ((i11 | 0) < (i9 | 0));
michael@0 45225 }
michael@0 45226 i11 = HEAP32[i10 >> 2] | 0;
michael@0 45227 i12 = i2 + 16 | 0;
michael@0 45228 if ((i11 | 0) == 0) {
michael@0 45229 i13 = i9;
michael@0 45230 } else {
michael@0 45231 if ((HEAP8[i12] | 0) == 0) {
michael@0 45232 i14 = i9;
michael@0 45233 } else {
michael@0 45234 __Z21btAlignedFreeInternalPv(i11);
michael@0 45235 i14 = HEAP32[i1 >> 2] | 0;
michael@0 45236 }
michael@0 45237 HEAP32[i10 >> 2] = 0;
michael@0 45238 i13 = i14;
michael@0 45239 }
michael@0 45240 HEAP8[i12] = 1;
michael@0 45241 HEAP32[i10 >> 2] = i8;
michael@0 45242 HEAP32[i5 >> 2] = i6;
michael@0 45243 i7 = i13;
michael@0 45244 } else {
michael@0 45245 i7 = i4;
michael@0 45246 }
michael@0 45247 } while (0);
michael@0 45248 i4 = (HEAP32[i2 + 12 >> 2] | 0) + (i7 << 2) | 0;
michael@0 45249 if ((i4 | 0) != 0) {
michael@0 45250 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 45251 }
michael@0 45252 HEAP32[i1 >> 2] = i7 + 1;
michael@0 45253 return;
michael@0 45254 }
michael@0 45255 function __ZN23btConvexConvexAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 45256 i1 = i1 | 0;
michael@0 45257 i2 = i2 | 0;
michael@0 45258 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 45259 i3 = i1 + 20 | 0;
michael@0 45260 if ((HEAP32[i3 >> 2] | 0) == 0) {
michael@0 45261 return;
michael@0 45262 }
michael@0 45263 if ((HEAP8[i1 + 16 | 0] | 0) == 0) {
michael@0 45264 return;
michael@0 45265 }
michael@0 45266 i1 = i2 + 4 | 0;
michael@0 45267 i4 = HEAP32[i1 >> 2] | 0;
michael@0 45268 i5 = i2 + 8 | 0;
michael@0 45269 do {
michael@0 45270 if ((i4 | 0) == (HEAP32[i5 >> 2] | 0)) {
michael@0 45271 i6 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 45272 if ((i4 | 0) >= (i6 | 0)) {
michael@0 45273 i7 = i4;
michael@0 45274 break;
michael@0 45275 }
michael@0 45276 if ((i6 | 0) == 0) {
michael@0 45277 i8 = 0;
michael@0 45278 i9 = i4;
michael@0 45279 } else {
michael@0 45280 i10 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 45281 i8 = i10;
michael@0 45282 i9 = HEAP32[i1 >> 2] | 0;
michael@0 45283 }
michael@0 45284 i10 = i2 + 12 | 0;
michael@0 45285 if ((i9 | 0) > 0) {
michael@0 45286 i11 = 0;
michael@0 45287 do {
michael@0 45288 i12 = i8 + (i11 << 2) | 0;
michael@0 45289 if ((i12 | 0) != 0) {
michael@0 45290 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i10 >> 2] | 0) + (i11 << 2) >> 2];
michael@0 45291 }
michael@0 45292 i11 = i11 + 1 | 0;
michael@0 45293 } while ((i11 | 0) < (i9 | 0));
michael@0 45294 }
michael@0 45295 i11 = HEAP32[i10 >> 2] | 0;
michael@0 45296 i12 = i2 + 16 | 0;
michael@0 45297 if ((i11 | 0) == 0) {
michael@0 45298 i13 = i9;
michael@0 45299 } else {
michael@0 45300 if ((HEAP8[i12] | 0) == 0) {
michael@0 45301 i14 = i9;
michael@0 45302 } else {
michael@0 45303 __Z21btAlignedFreeInternalPv(i11);
michael@0 45304 i14 = HEAP32[i1 >> 2] | 0;
michael@0 45305 }
michael@0 45306 HEAP32[i10 >> 2] = 0;
michael@0 45307 i13 = i14;
michael@0 45308 }
michael@0 45309 HEAP8[i12] = 1;
michael@0 45310 HEAP32[i10 >> 2] = i8;
michael@0 45311 HEAP32[i5 >> 2] = i6;
michael@0 45312 i7 = i13;
michael@0 45313 } else {
michael@0 45314 i7 = i4;
michael@0 45315 }
michael@0 45316 } while (0);
michael@0 45317 i4 = (HEAP32[i2 + 12 >> 2] | 0) + (i7 << 2) | 0;
michael@0 45318 if ((i4 | 0) != 0) {
michael@0 45319 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 45320 }
michael@0 45321 HEAP32[i1 >> 2] = i7 + 1;
michael@0 45322 return;
michael@0 45323 }
michael@0 45324 function __ZNK23btPolyhedralConvexShape37localGetSupportingVertexWithoutMarginERK9btVector3(i1, i2, i3) {
michael@0 45325 i1 = i1 | 0;
michael@0 45326 i2 = i2 | 0;
michael@0 45327 i3 = i3 | 0;
michael@0 45328 var i4 = 0, i5 = 0, i6 = 0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, i15 = 0, i16 = 0, i17 = 0, i18 = 0, i19 = 0, d20 = 0.0, i21 = 0;
michael@0 45329 i4 = STACKTOP;
michael@0 45330 STACKTOP = STACKTOP + 16 | 0;
michael@0 45331 i5 = i4 | 0;
michael@0 45332 i6 = i1;
michael@0 45333 _memset(i6 | 0, 0, 16);
michael@0 45334 d7 = +HEAPF32[i3 >> 2];
michael@0 45335 d8 = +HEAPF32[i3 + 4 >> 2];
michael@0 45336 d9 = +HEAPF32[i3 + 8 >> 2];
michael@0 45337 d10 = d7 * d7 + d8 * d8 + d9 * d9;
michael@0 45338 if (d10 < 9999999747378752.0e-20) {
michael@0 45339 d11 = 1.0;
michael@0 45340 d12 = 0.0;
michael@0 45341 d13 = 0.0;
michael@0 45342 } else {
michael@0 45343 d14 = 1.0 / +Math_sqrt(+d10);
michael@0 45344 d11 = d7 * d14;
michael@0 45345 d12 = d8 * d14;
michael@0 45346 d13 = d9 * d14;
michael@0 45347 }
michael@0 45348 i3 = i2;
michael@0 45349 if ((FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 88 >> 2] & 127](i2) | 0) <= 0) {
michael@0 45350 STACKTOP = i4;
michael@0 45351 return;
michael@0 45352 }
michael@0 45353 i1 = i2;
michael@0 45354 i15 = i5 | 0;
michael@0 45355 i16 = i5 + 4 | 0;
michael@0 45356 i17 = i5 + 8 | 0;
michael@0 45357 i18 = i5;
michael@0 45358 d14 = -999999984306749400.0;
michael@0 45359 i19 = 0;
michael@0 45360 while (1) {
michael@0 45361 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 100 >> 2] & 127](i2, i19, i5);
michael@0 45362 d9 = d11 * +HEAPF32[i15 >> 2] + d12 * +HEAPF32[i16 >> 2] + d13 * +HEAPF32[i17 >> 2];
michael@0 45363 if (d9 > d14) {
michael@0 45364 HEAP32[i6 >> 2] = HEAP32[i18 >> 2];
michael@0 45365 HEAP32[i6 + 4 >> 2] = HEAP32[i18 + 4 >> 2];
michael@0 45366 HEAP32[i6 + 8 >> 2] = HEAP32[i18 + 8 >> 2];
michael@0 45367 HEAP32[i6 + 12 >> 2] = HEAP32[i18 + 12 >> 2];
michael@0 45368 d20 = d9;
michael@0 45369 } else {
michael@0 45370 d20 = d14;
michael@0 45371 }
michael@0 45372 i21 = i19 + 1 | 0;
michael@0 45373 if ((i21 | 0) < (FUNCTION_TABLE_ii[HEAP32[(HEAP32[i3 >> 2] | 0) + 88 >> 2] & 127](i2) | 0)) {
michael@0 45374 d14 = d20;
michael@0 45375 i19 = i21;
michael@0 45376 } else {
michael@0 45377 break;
michael@0 45378 }
michael@0 45379 }
michael@0 45380 STACKTOP = i4;
michael@0 45381 return;
michael@0 45382 }
michael@0 45383 function __ZN20btConvexHullInternal4PoolINS_4FaceEE9newObjectEv(i1) {
michael@0 45384 i1 = i1 | 0;
michael@0 45385 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 45386 i2 = i1 + 8 | 0;
michael@0 45387 i3 = HEAP32[i2 >> 2] | 0;
michael@0 45388 do {
michael@0 45389 if ((i3 | 0) == 0) {
michael@0 45390 i4 = i1 + 4 | 0;
michael@0 45391 i5 = HEAP32[i4 >> 2] | 0;
michael@0 45392 if ((i5 | 0) == 0) {
michael@0 45393 i6 = __Z22btAlignedAllocInternalji(12, 16) | 0;
michael@0 45394 if ((i6 | 0) == 0) {
michael@0 45395 i7 = 0;
michael@0 45396 } else {
michael@0 45397 i8 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 45398 HEAP32[i6 + 4 >> 2] = i8;
michael@0 45399 HEAP32[i6 + 8 >> 2] = 0;
michael@0 45400 HEAP32[i6 >> 2] = __Z22btAlignedAllocInternalji(i8 * 60 | 0, 16) | 0;
michael@0 45401 i7 = i6;
michael@0 45402 }
michael@0 45403 i6 = i1 | 0;
michael@0 45404 HEAP32[i7 + 8 >> 2] = HEAP32[i6 >> 2];
michael@0 45405 HEAP32[i6 >> 2] = i7;
michael@0 45406 i9 = i7;
michael@0 45407 } else {
michael@0 45408 HEAP32[i4 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 45409 i9 = i5;
michael@0 45410 }
michael@0 45411 i5 = i9 | 0;
michael@0 45412 i4 = HEAP32[i9 + 4 >> 2] | 0;
michael@0 45413 if ((i4 | 0) > 0) {
michael@0 45414 i6 = HEAP32[i5 >> 2] | 0;
michael@0 45415 i8 = 0;
michael@0 45416 while (1) {
michael@0 45417 i10 = i8 + 1 | 0;
michael@0 45418 i11 = (i10 | 0) < (i4 | 0);
michael@0 45419 i12 = i6 + 60 | 0;
michael@0 45420 HEAP32[i6 >> 2] = i11 ? i12 : 0;
michael@0 45421 if (i11) {
michael@0 45422 i6 = i12;
michael@0 45423 i8 = i10;
michael@0 45424 } else {
michael@0 45425 break;
michael@0 45426 }
michael@0 45427 }
michael@0 45428 }
michael@0 45429 i8 = HEAP32[i5 >> 2] | 0;
michael@0 45430 i6 = i8 | 0;
michael@0 45431 HEAP32[i2 >> 2] = HEAP32[i6 >> 2];
michael@0 45432 if ((i8 | 0) == 0) {
michael@0 45433 i13 = 0;
michael@0 45434 } else {
michael@0 45435 i14 = i8;
michael@0 45436 i15 = i6;
michael@0 45437 break;
michael@0 45438 }
michael@0 45439 return i13 | 0;
michael@0 45440 } else {
michael@0 45441 i6 = i3 | 0;
michael@0 45442 HEAP32[i2 >> 2] = HEAP32[i6 >> 2];
michael@0 45443 i14 = i3;
michael@0 45444 i15 = i6;
michael@0 45445 }
michael@0 45446 } while (0);
michael@0 45447 HEAP32[i15 >> 2] = 0;
michael@0 45448 HEAP32[i14 + 4 >> 2] = 0;
michael@0 45449 HEAP32[i14 + 8 >> 2] = 0;
michael@0 45450 i13 = i14;
michael@0 45451 return i13 | 0;
michael@0 45452 }
michael@0 45453 function __ZN16btCollisionWorldD2Ev(i1) {
michael@0 45454 i1 = i1 | 0;
michael@0 45455 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0;
michael@0 45456 HEAP32[i1 >> 2] = 4464;
michael@0 45457 i2 = i1 + 8 | 0;
michael@0 45458 i3 = HEAP32[i2 >> 2] | 0;
michael@0 45459 i4 = i1 + 16 | 0;
michael@0 45460 i5 = HEAP32[i4 >> 2] | 0;
michael@0 45461 if ((i3 | 0) > 0) {
michael@0 45462 i6 = i1 + 76 | 0;
michael@0 45463 i7 = i1 + 24 | 0;
michael@0 45464 i8 = 0;
michael@0 45465 i9 = i5;
michael@0 45466 i10 = i3;
michael@0 45467 while (1) {
michael@0 45468 i3 = (HEAP32[i9 + (i8 << 2) >> 2] | 0) + 188 | 0;
michael@0 45469 i11 = HEAP32[i3 >> 2] | 0;
michael@0 45470 if ((i11 | 0) == 0) {
michael@0 45471 i12 = i10;
michael@0 45472 i13 = i9;
michael@0 45473 } else {
michael@0 45474 i14 = HEAP32[i6 >> 2] | 0;
michael@0 45475 i15 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i14 >> 2] | 0) + 36 >> 2] & 127](i14) | 0;
michael@0 45476 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i15 >> 2] | 0) + 40 >> 2] & 127](i15, i11, HEAP32[i7 >> 2] | 0);
michael@0 45477 i15 = HEAP32[i6 >> 2] | 0;
michael@0 45478 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i15 >> 2] | 0) + 12 >> 2] & 127](i15, i11, HEAP32[i7 >> 2] | 0);
michael@0 45479 HEAP32[i3 >> 2] = 0;
michael@0 45480 i12 = HEAP32[i2 >> 2] | 0;
michael@0 45481 i13 = HEAP32[i4 >> 2] | 0;
michael@0 45482 }
michael@0 45483 i3 = i8 + 1 | 0;
michael@0 45484 if ((i3 | 0) < (i12 | 0)) {
michael@0 45485 i8 = i3;
michael@0 45486 i9 = i13;
michael@0 45487 i10 = i12;
michael@0 45488 } else {
michael@0 45489 i16 = i13;
michael@0 45490 break;
michael@0 45491 }
michael@0 45492 }
michael@0 45493 } else {
michael@0 45494 i16 = i5;
michael@0 45495 }
michael@0 45496 i5 = i1 + 20 | 0;
michael@0 45497 if ((i16 | 0) == 0) {
michael@0 45498 HEAP8[i5] = 1;
michael@0 45499 HEAP32[i4 >> 2] = 0;
michael@0 45500 HEAP32[i2 >> 2] = 0;
michael@0 45501 i17 = i1 + 12 | 0;
michael@0 45502 HEAP32[i17 >> 2] = 0;
michael@0 45503 return;
michael@0 45504 }
michael@0 45505 if ((HEAP8[i5] | 0) != 0) {
michael@0 45506 __Z21btAlignedFreeInternalPv(i16);
michael@0 45507 }
michael@0 45508 HEAP32[i4 >> 2] = 0;
michael@0 45509 HEAP8[i5] = 1;
michael@0 45510 HEAP32[i4 >> 2] = 0;
michael@0 45511 HEAP32[i2 >> 2] = 0;
michael@0 45512 i17 = i1 + 12 | 0;
michael@0 45513 HEAP32[i17 >> 2] = 0;
michael@0 45514 return;
michael@0 45515 }
michael@0 45516 function __ZN33btConvexConcaveCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 45517 i1 = i1 | 0;
michael@0 45518 i2 = i2 | 0;
michael@0 45519 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 45520 i3 = i1 + 76 | 0;
michael@0 45521 if ((HEAP32[i3 >> 2] | 0) == 0) {
michael@0 45522 return;
michael@0 45523 }
michael@0 45524 i1 = i2 + 4 | 0;
michael@0 45525 i4 = HEAP32[i1 >> 2] | 0;
michael@0 45526 i5 = i2 + 8 | 0;
michael@0 45527 do {
michael@0 45528 if ((i4 | 0) == (HEAP32[i5 >> 2] | 0)) {
michael@0 45529 i6 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 45530 if ((i4 | 0) >= (i6 | 0)) {
michael@0 45531 i7 = i4;
michael@0 45532 break;
michael@0 45533 }
michael@0 45534 if ((i6 | 0) == 0) {
michael@0 45535 i8 = 0;
michael@0 45536 i9 = i4;
michael@0 45537 } else {
michael@0 45538 i10 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 45539 i8 = i10;
michael@0 45540 i9 = HEAP32[i1 >> 2] | 0;
michael@0 45541 }
michael@0 45542 i10 = i2 + 12 | 0;
michael@0 45543 if ((i9 | 0) > 0) {
michael@0 45544 i11 = 0;
michael@0 45545 do {
michael@0 45546 i12 = i8 + (i11 << 2) | 0;
michael@0 45547 if ((i12 | 0) != 0) {
michael@0 45548 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i10 >> 2] | 0) + (i11 << 2) >> 2];
michael@0 45549 }
michael@0 45550 i11 = i11 + 1 | 0;
michael@0 45551 } while ((i11 | 0) < (i9 | 0));
michael@0 45552 }
michael@0 45553 i11 = HEAP32[i10 >> 2] | 0;
michael@0 45554 i12 = i2 + 16 | 0;
michael@0 45555 if ((i11 | 0) == 0) {
michael@0 45556 i13 = i9;
michael@0 45557 } else {
michael@0 45558 if ((HEAP8[i12] | 0) == 0) {
michael@0 45559 i14 = i9;
michael@0 45560 } else {
michael@0 45561 __Z21btAlignedFreeInternalPv(i11);
michael@0 45562 i14 = HEAP32[i1 >> 2] | 0;
michael@0 45563 }
michael@0 45564 HEAP32[i10 >> 2] = 0;
michael@0 45565 i13 = i14;
michael@0 45566 }
michael@0 45567 HEAP8[i12] = 1;
michael@0 45568 HEAP32[i10 >> 2] = i8;
michael@0 45569 HEAP32[i5 >> 2] = i6;
michael@0 45570 i7 = i13;
michael@0 45571 } else {
michael@0 45572 i7 = i4;
michael@0 45573 }
michael@0 45574 } while (0);
michael@0 45575 i4 = (HEAP32[i2 + 12 >> 2] | 0) + (i7 << 2) | 0;
michael@0 45576 if ((i4 | 0) != 0) {
michael@0 45577 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 45578 }
michael@0 45579 HEAP32[i1 >> 2] = i7 + 1;
michael@0 45580 return;
michael@0 45581 }
michael@0 45582 function __ZN22SphereTriangleDetector15pointInTriangleEPK9btVector3RS1_PS0_(i1, i2, i3, i4) {
michael@0 45583 i1 = i1 | 0;
michael@0 45584 i2 = i2 | 0;
michael@0 45585 i3 = i3 | 0;
michael@0 45586 i4 = i4 | 0;
michael@0 45587 var d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, d21 = 0.0, d22 = 0.0, d23 = 0.0, d24 = 0.0, d25 = 0.0, d26 = 0.0, d27 = 0.0, d28 = 0.0, d29 = 0.0;
michael@0 45588 d5 = +HEAPF32[i2 + 16 >> 2];
michael@0 45589 d6 = +HEAPF32[i2 >> 2];
michael@0 45590 d7 = d5 - d6;
michael@0 45591 d8 = +HEAPF32[i2 + 20 >> 2];
michael@0 45592 d9 = +HEAPF32[i2 + 4 >> 2];
michael@0 45593 d10 = d8 - d9;
michael@0 45594 d11 = +HEAPF32[i2 + 24 >> 2];
michael@0 45595 d12 = +HEAPF32[i2 + 8 >> 2];
michael@0 45596 d13 = d11 - d12;
michael@0 45597 d14 = +HEAPF32[i2 + 32 >> 2];
michael@0 45598 d15 = d14 - d5;
michael@0 45599 d16 = +HEAPF32[i2 + 36 >> 2];
michael@0 45600 d17 = d16 - d8;
michael@0 45601 d18 = +HEAPF32[i2 + 40 >> 2];
michael@0 45602 d19 = d18 - d11;
michael@0 45603 d20 = d6 - d14;
michael@0 45604 d21 = d9 - d16;
michael@0 45605 d22 = d12 - d18;
michael@0 45606 d23 = +HEAPF32[i4 >> 2];
michael@0 45607 d24 = +HEAPF32[i4 + 4 >> 2];
michael@0 45608 d25 = +HEAPF32[i4 + 8 >> 2];
michael@0 45609 d26 = +HEAPF32[i3 + 8 >> 2];
michael@0 45610 d27 = +HEAPF32[i3 + 4 >> 2];
michael@0 45611 d28 = +HEAPF32[i3 >> 2];
michael@0 45612 d29 = (d25 - d12) * (d7 * d27 - d10 * d28) + ((d23 - d6) * (d10 * d26 - d13 * d27) + (d24 - d9) * (d13 * d28 - d7 * d26));
michael@0 45613 d7 = (d25 - d11) * (d15 * d27 - d17 * d28) + ((d23 - d5) * (d17 * d26 - d19 * d27) + (d24 - d8) * (d19 * d28 - d15 * d26));
michael@0 45614 d15 = (d25 - d18) * (d20 * d27 - d21 * d28) + ((d23 - d14) * (d21 * d26 - d22 * d27) + (d24 - d16) * (d22 * d28 - d20 * d26));
michael@0 45615 if (d29 > 0.0 & d7 > 0.0 & d15 > 0.0) {
michael@0 45616 return 1;
michael@0 45617 } else {
michael@0 45618 return (d29 > 0.0 | d7 > 0.0 | d15 > 0.0) ^ 1 | 0;
michael@0 45619 }
michael@0 45620 return 0;
michael@0 45621 }
michael@0 45622 function __ZNK12gjkepa2_impl3GJK10getsupportERK9btVector3RNS0_3sSVE(i1, i2, i3) {
michael@0 45623 i1 = i1 | 0;
michael@0 45624 i2 = i2 | 0;
michael@0 45625 i3 = i3 | 0;
michael@0 45626 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, i12 = 0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0;
michael@0 45627 i4 = STACKTOP;
michael@0 45628 STACKTOP = STACKTOP + 48 | 0;
michael@0 45629 i5 = i4 | 0;
michael@0 45630 i6 = i4 + 16 | 0;
michael@0 45631 i7 = i4 + 32 | 0;
michael@0 45632 d8 = +HEAPF32[i2 >> 2];
michael@0 45633 d9 = +HEAPF32[i2 + 4 >> 2];
michael@0 45634 d10 = +HEAPF32[i2 + 8 >> 2];
michael@0 45635 d11 = 1.0 / +Math_sqrt(+(d8 * d8 + d9 * d9 + d10 * d10));
michael@0 45636 i2 = i3 | 0;
michael@0 45637 HEAPF32[i2 >> 2] = d8 * d11;
michael@0 45638 i12 = i3 + 4 | 0;
michael@0 45639 HEAPF32[i12 >> 2] = d9 * d11;
michael@0 45640 i13 = i3 + 8 | 0;
michael@0 45641 HEAPF32[i13 >> 2] = d10 * d11;
michael@0 45642 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 45643 i14 = i1 + 120 | 0;
michael@0 45644 i15 = (HEAP32[i1 >> 2] | 0) + (HEAP32[i14 + 4 >> 2] | 0) | 0;
michael@0 45645 i16 = HEAP32[i14 >> 2] | 0;
michael@0 45646 if ((i16 & 1 | 0) == 0) {
michael@0 45647 i17 = i16;
michael@0 45648 } else {
michael@0 45649 i17 = HEAP32[(HEAP32[i15 >> 2] | 0) + (i16 - 1) >> 2] | 0;
michael@0 45650 }
michael@0 45651 FUNCTION_TABLE_viii[i17 & 127](i5, i15, i3 | 0);
michael@0 45652 d11 = -0.0 - +HEAPF32[i12 >> 2];
michael@0 45653 d10 = -0.0 - +HEAPF32[i13 >> 2];
michael@0 45654 HEAPF32[i7 >> 2] = -0.0 - +HEAPF32[i2 >> 2];
michael@0 45655 HEAPF32[i7 + 4 >> 2] = d11;
michael@0 45656 HEAPF32[i7 + 8 >> 2] = d10;
michael@0 45657 HEAPF32[i7 + 12 >> 2] = 0.0;
michael@0 45658 __ZNK12gjkepa2_impl13MinkowskiDiff8Support1ERK9btVector3(i6, i1 | 0, i7);
michael@0 45659 d10 = +HEAPF32[i5 + 4 >> 2] - +HEAPF32[i6 + 4 >> 2];
michael@0 45660 d11 = +HEAPF32[i5 + 8 >> 2] - +HEAPF32[i6 + 8 >> 2];
michael@0 45661 HEAPF32[i3 + 16 >> 2] = +HEAPF32[i5 >> 2] - +HEAPF32[i6 >> 2];
michael@0 45662 HEAPF32[i3 + 20 >> 2] = d10;
michael@0 45663 HEAPF32[i3 + 24 >> 2] = d11;
michael@0 45664 HEAPF32[i3 + 28 >> 2] = 0.0;
michael@0 45665 STACKTOP = i4;
michael@0 45666 return;
michael@0 45667 }
michael@0 45668 function __ZN23btDiscreteDynamicsWorld9addActionEP17btActionInterface(i1, i2) {
michael@0 45669 i1 = i1 | 0;
michael@0 45670 i2 = i2 | 0;
michael@0 45671 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 45672 i3 = i1 + 248 | 0;
michael@0 45673 i4 = HEAP32[i3 >> 2] | 0;
michael@0 45674 i5 = i1 + 252 | 0;
michael@0 45675 do {
michael@0 45676 if ((i4 | 0) == (HEAP32[i5 >> 2] | 0)) {
michael@0 45677 i6 = (i4 | 0) == 0 ? 1 : i4 << 1;
michael@0 45678 if ((i4 | 0) >= (i6 | 0)) {
michael@0 45679 i7 = i4;
michael@0 45680 break;
michael@0 45681 }
michael@0 45682 if ((i6 | 0) == 0) {
michael@0 45683 i8 = 0;
michael@0 45684 i9 = i4;
michael@0 45685 } else {
michael@0 45686 i10 = __Z22btAlignedAllocInternalji(i6 << 2, 16) | 0;
michael@0 45687 i8 = i10;
michael@0 45688 i9 = HEAP32[i3 >> 2] | 0;
michael@0 45689 }
michael@0 45690 i10 = i1 + 256 | 0;
michael@0 45691 if ((i9 | 0) > 0) {
michael@0 45692 i11 = 0;
michael@0 45693 do {
michael@0 45694 i12 = i8 + (i11 << 2) | 0;
michael@0 45695 if ((i12 | 0) != 0) {
michael@0 45696 HEAP32[i12 >> 2] = HEAP32[(HEAP32[i10 >> 2] | 0) + (i11 << 2) >> 2];
michael@0 45697 }
michael@0 45698 i11 = i11 + 1 | 0;
michael@0 45699 } while ((i11 | 0) < (i9 | 0));
michael@0 45700 }
michael@0 45701 i11 = HEAP32[i10 >> 2] | 0;
michael@0 45702 i12 = i1 + 260 | 0;
michael@0 45703 if ((i11 | 0) == 0) {
michael@0 45704 i13 = i9;
michael@0 45705 } else {
michael@0 45706 if ((HEAP8[i12] | 0) == 0) {
michael@0 45707 i14 = i9;
michael@0 45708 } else {
michael@0 45709 __Z21btAlignedFreeInternalPv(i11);
michael@0 45710 i14 = HEAP32[i3 >> 2] | 0;
michael@0 45711 }
michael@0 45712 HEAP32[i10 >> 2] = 0;
michael@0 45713 i13 = i14;
michael@0 45714 }
michael@0 45715 HEAP8[i12] = 1;
michael@0 45716 HEAP32[i10 >> 2] = i8;
michael@0 45717 HEAP32[i5 >> 2] = i6;
michael@0 45718 i7 = i13;
michael@0 45719 } else {
michael@0 45720 i7 = i4;
michael@0 45721 }
michael@0 45722 } while (0);
michael@0 45723 i4 = (HEAP32[i1 + 256 >> 2] | 0) + (i7 << 2) | 0;
michael@0 45724 if ((i4 | 0) == 0) {
michael@0 45725 i15 = i7 + 1 | 0;
michael@0 45726 HEAP32[i3 >> 2] = i15;
michael@0 45727 return;
michael@0 45728 }
michael@0 45729 HEAP32[i4 >> 2] = i2;
michael@0 45730 i15 = i7 + 1 | 0;
michael@0 45731 HEAP32[i3 >> 2] = i15;
michael@0 45732 return;
michael@0 45733 }
michael@0 45734 function __ZN20btConvexHullInternal4PoolINS_6VertexEE9newObjectEv(i1) {
michael@0 45735 i1 = i1 | 0;
michael@0 45736 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 45737 i2 = i1 + 8 | 0;
michael@0 45738 i3 = HEAP32[i2 >> 2] | 0;
michael@0 45739 do {
michael@0 45740 if ((i3 | 0) == 0) {
michael@0 45741 i4 = i1 + 4 | 0;
michael@0 45742 i5 = HEAP32[i4 >> 2] | 0;
michael@0 45743 if ((i5 | 0) == 0) {
michael@0 45744 i6 = __Z22btAlignedAllocInternalji(12, 16) | 0;
michael@0 45745 if ((i6 | 0) == 0) {
michael@0 45746 i7 = 0;
michael@0 45747 } else {
michael@0 45748 i8 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 45749 HEAP32[i6 + 4 >> 2] = i8;
michael@0 45750 HEAP32[i6 + 8 >> 2] = 0;
michael@0 45751 HEAP32[i6 >> 2] = __Z22btAlignedAllocInternalji(i8 * 112 | 0, 16) | 0;
michael@0 45752 i7 = i6;
michael@0 45753 }
michael@0 45754 i6 = i1 | 0;
michael@0 45755 HEAP32[i7 + 8 >> 2] = HEAP32[i6 >> 2];
michael@0 45756 HEAP32[i6 >> 2] = i7;
michael@0 45757 i9 = i7;
michael@0 45758 } else {
michael@0 45759 HEAP32[i4 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 45760 i9 = i5;
michael@0 45761 }
michael@0 45762 i5 = i9 | 0;
michael@0 45763 i4 = HEAP32[i9 + 4 >> 2] | 0;
michael@0 45764 if ((i4 | 0) > 0) {
michael@0 45765 i6 = HEAP32[i5 >> 2] | 0;
michael@0 45766 i8 = 0;
michael@0 45767 while (1) {
michael@0 45768 i10 = i8 + 1 | 0;
michael@0 45769 i11 = (i10 | 0) < (i4 | 0);
michael@0 45770 i12 = i6 + 112 | 0;
michael@0 45771 HEAP32[i6 >> 2] = i11 ? i12 : 0;
michael@0 45772 if (i11) {
michael@0 45773 i6 = i12;
michael@0 45774 i8 = i10;
michael@0 45775 } else {
michael@0 45776 break;
michael@0 45777 }
michael@0 45778 }
michael@0 45779 }
michael@0 45780 i8 = HEAP32[i5 >> 2] | 0;
michael@0 45781 HEAP32[i2 >> 2] = HEAP32[i8 >> 2];
michael@0 45782 if ((i8 | 0) == 0) {
michael@0 45783 i13 = 0;
michael@0 45784 } else {
michael@0 45785 i14 = i8;
michael@0 45786 break;
michael@0 45787 }
michael@0 45788 return i13 | 0;
michael@0 45789 } else {
michael@0 45790 HEAP32[i2 >> 2] = HEAP32[i3 >> 2];
michael@0 45791 i14 = i3;
michael@0 45792 }
michael@0 45793 } while (0);
michael@0 45794 _memset(i14 | 0, 0, 20);
michael@0 45795 HEAP32[i14 + 104 >> 2] = -1;
michael@0 45796 i13 = i14;
michael@0 45797 return i13 | 0;
michael@0 45798 }
michael@0 45799 function __ZN20btConvexHullInternal14getCoordinatesEPKNS_6VertexE(i1, i2, i3) {
michael@0 45800 i1 = i1 | 0;
michael@0 45801 i2 = i2 | 0;
michael@0 45802 i3 = i3 | 0;
michael@0 45803 var i4 = 0, i5 = 0, d6 = 0.0, i7 = 0, d8 = 0.0, i9 = 0, d10 = 0.0;
michael@0 45804 i4 = STACKTOP;
michael@0 45805 STACKTOP = STACKTOP + 16 | 0;
michael@0 45806 i5 = i4 | 0;
michael@0 45807 if ((HEAP32[i3 + 100 >> 2] | 0) > -1) {
michael@0 45808 HEAPF32[i5 + (HEAP32[i2 + 108 >> 2] << 2) >> 2] = +(HEAP32[i3 + 88 >> 2] | 0);
michael@0 45809 HEAPF32[i5 + (HEAP32[i2 + 112 >> 2] << 2) >> 2] = +(HEAP32[i3 + 92 >> 2] | 0);
michael@0 45810 d6 = +(HEAP32[i3 + 96 >> 2] | 0);
michael@0 45811 i7 = i5 | 0;
michael@0 45812 } else {
michael@0 45813 d8 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i3 + 24 | 0);
michael@0 45814 i9 = i3 + 72 | 0;
michael@0 45815 d10 = d8 / +__ZNK20btConvexHullInternal6Int1288toScalarEv(i9);
michael@0 45816 HEAPF32[i5 + (HEAP32[i2 + 108 >> 2] << 2) >> 2] = d10;
michael@0 45817 d10 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i3 + 40 | 0);
michael@0 45818 d8 = d10 / +__ZNK20btConvexHullInternal6Int1288toScalarEv(i9);
michael@0 45819 HEAPF32[i5 + (HEAP32[i2 + 112 >> 2] << 2) >> 2] = d8;
michael@0 45820 d8 = +__ZNK20btConvexHullInternal6Int1288toScalarEv(i3 + 56 | 0);
michael@0 45821 d6 = d8 / +__ZNK20btConvexHullInternal6Int1288toScalarEv(i9);
michael@0 45822 i7 = i5 | 0;
michael@0 45823 }
michael@0 45824 HEAPF32[i5 + (HEAP32[i2 + 104 >> 2] << 2) >> 2] = d6;
michael@0 45825 d6 = +HEAPF32[i5 + 4 >> 2] * +HEAPF32[i2 + 4 >> 2] + +HEAPF32[i2 + 20 >> 2];
michael@0 45826 d8 = +HEAPF32[i5 + 8 >> 2] * +HEAPF32[i2 + 8 >> 2] + +HEAPF32[i2 + 24 >> 2];
michael@0 45827 HEAPF32[i1 >> 2] = +HEAPF32[i7 >> 2] * +HEAPF32[i2 >> 2] + +HEAPF32[i2 + 16 >> 2];
michael@0 45828 HEAPF32[i1 + 4 >> 2] = d6;
michael@0 45829 HEAPF32[i1 + 8 >> 2] = d8;
michael@0 45830 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 45831 STACKTOP = i4;
michael@0 45832 return;
michael@0 45833 }
michael@0 45834 function __ZN12gjkepa2_impl3GJK13projectoriginERK9btVector3S3_PfRj(i1, i2, i3, i4) {
michael@0 45835 i1 = i1 | 0;
michael@0 45836 i2 = i2 | 0;
michael@0 45837 i3 = i3 | 0;
michael@0 45838 i4 = i4 | 0;
michael@0 45839 var i5 = 0, i6 = 0, d7 = 0.0, d8 = 0.0, i9 = 0, i10 = 0, d11 = 0.0, d12 = 0.0, i13 = 0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0;
michael@0 45840 i5 = i2 | 0;
michael@0 45841 i6 = i1 | 0;
michael@0 45842 d7 = +HEAPF32[i6 >> 2];
michael@0 45843 d8 = +HEAPF32[i5 >> 2] - d7;
michael@0 45844 i9 = i2 + 4 | 0;
michael@0 45845 i10 = i1 + 4 | 0;
michael@0 45846 d11 = +HEAPF32[i10 >> 2];
michael@0 45847 d12 = +HEAPF32[i9 >> 2] - d11;
michael@0 45848 i13 = i2 + 8 | 0;
michael@0 45849 i2 = i1 + 8 | 0;
michael@0 45850 d14 = +HEAPF32[i2 >> 2];
michael@0 45851 d15 = +HEAPF32[i13 >> 2] - d14;
michael@0 45852 d16 = d8 * d8 + d12 * d12 + d15 * d15;
michael@0 45853 if (d16 <= 0.0) {
michael@0 45854 d17 = -1.0;
michael@0 45855 return +d17;
michael@0 45856 }
michael@0 45857 d18 = (-0.0 - (d7 * d8 + d11 * d12 + d14 * d15)) / d16;
michael@0 45858 if (d18 >= 1.0) {
michael@0 45859 HEAPF32[i3 >> 2] = 0.0;
michael@0 45860 HEAPF32[i3 + 4 >> 2] = 1.0;
michael@0 45861 HEAP32[i4 >> 2] = 2;
michael@0 45862 d16 = +HEAPF32[i5 >> 2];
michael@0 45863 d14 = +HEAPF32[i9 >> 2];
michael@0 45864 d11 = +HEAPF32[i13 >> 2];
michael@0 45865 d17 = d16 * d16 + d14 * d14 + d11 * d11;
michael@0 45866 return +d17;
michael@0 45867 }
michael@0 45868 if (d18 > 0.0) {
michael@0 45869 HEAPF32[i3 + 4 >> 2] = d18;
michael@0 45870 HEAPF32[i3 >> 2] = 1.0 - d18;
michael@0 45871 HEAP32[i4 >> 2] = 3;
michael@0 45872 d11 = d8 * d18 + +HEAPF32[i6 >> 2];
michael@0 45873 d8 = d12 * d18 + +HEAPF32[i10 >> 2];
michael@0 45874 d12 = d15 * d18 + +HEAPF32[i2 >> 2];
michael@0 45875 d17 = d11 * d11 + d8 * d8 + d12 * d12;
michael@0 45876 return +d17;
michael@0 45877 } else {
michael@0 45878 HEAPF32[i3 >> 2] = 1.0;
michael@0 45879 HEAPF32[i3 + 4 >> 2] = 0.0;
michael@0 45880 HEAP32[i4 >> 2] = 1;
michael@0 45881 d12 = +HEAPF32[i6 >> 2];
michael@0 45882 d8 = +HEAPF32[i10 >> 2];
michael@0 45883 d11 = +HEAPF32[i2 >> 2];
michael@0 45884 d17 = d12 * d12 + d8 * d8 + d11 * d11;
michael@0 45885 return +d17;
michael@0 45886 }
michael@0 45887 return 0.0;
michael@0 45888 }
michael@0 45889 function __ZN20btConvexHullInternal4PoolINS_4EdgeEE9newObjectEv(i1) {
michael@0 45890 i1 = i1 | 0;
michael@0 45891 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 45892 i2 = i1 + 8 | 0;
michael@0 45893 i3 = HEAP32[i2 >> 2] | 0;
michael@0 45894 do {
michael@0 45895 if ((i3 | 0) == 0) {
michael@0 45896 i4 = i1 + 4 | 0;
michael@0 45897 i5 = HEAP32[i4 >> 2] | 0;
michael@0 45898 if ((i5 | 0) == 0) {
michael@0 45899 i6 = __Z22btAlignedAllocInternalji(12, 16) | 0;
michael@0 45900 if ((i6 | 0) == 0) {
michael@0 45901 i7 = 0;
michael@0 45902 } else {
michael@0 45903 i8 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 45904 HEAP32[i6 + 4 >> 2] = i8;
michael@0 45905 HEAP32[i6 + 8 >> 2] = 0;
michael@0 45906 HEAP32[i6 >> 2] = __Z22btAlignedAllocInternalji(i8 * 24 | 0, 16) | 0;
michael@0 45907 i7 = i6;
michael@0 45908 }
michael@0 45909 i6 = i1 | 0;
michael@0 45910 HEAP32[i7 + 8 >> 2] = HEAP32[i6 >> 2];
michael@0 45911 HEAP32[i6 >> 2] = i7;
michael@0 45912 i9 = i7;
michael@0 45913 } else {
michael@0 45914 HEAP32[i4 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 45915 i9 = i5;
michael@0 45916 }
michael@0 45917 i5 = i9 | 0;
michael@0 45918 i4 = HEAP32[i9 + 4 >> 2] | 0;
michael@0 45919 if ((i4 | 0) > 0) {
michael@0 45920 i6 = HEAP32[i5 >> 2] | 0;
michael@0 45921 i8 = 0;
michael@0 45922 while (1) {
michael@0 45923 i10 = i8 + 1 | 0;
michael@0 45924 i11 = (i10 | 0) < (i4 | 0);
michael@0 45925 i12 = i6 + 24 | 0;
michael@0 45926 HEAP32[i6 >> 2] = i11 ? i12 : 0;
michael@0 45927 if (i11) {
michael@0 45928 i6 = i12;
michael@0 45929 i8 = i10;
michael@0 45930 } else {
michael@0 45931 break;
michael@0 45932 }
michael@0 45933 }
michael@0 45934 }
michael@0 45935 i8 = HEAP32[i5 >> 2] | 0;
michael@0 45936 HEAP32[i2 >> 2] = HEAP32[i8 >> 2];
michael@0 45937 if ((i8 | 0) == 0) {
michael@0 45938 i13 = 0;
michael@0 45939 } else {
michael@0 45940 i14 = i8;
michael@0 45941 break;
michael@0 45942 }
michael@0 45943 return i13 | 0;
michael@0 45944 } else {
michael@0 45945 HEAP32[i2 >> 2] = HEAP32[i3 >> 2];
michael@0 45946 i14 = i3;
michael@0 45947 }
michael@0 45948 } while (0);
michael@0 45949 _memset(i14 | 0, 0, 24);
michael@0 45950 i13 = i14;
michael@0 45951 return i13 | 0;
michael@0 45952 }
michael@0 45953 function __ZN9btHashMapI20btInternalVertexPair14btInternalEdgeED2Ev(i1) {
michael@0 45954 i1 = i1 | 0;
michael@0 45955 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 45956 i2 = i1 + 64 | 0;
michael@0 45957 i3 = i1 + 72 | 0;
michael@0 45958 i4 = HEAP32[i3 >> 2] | 0;
michael@0 45959 i5 = i1 + 76 | 0;
michael@0 45960 if ((i4 | 0) != 0) {
michael@0 45961 if ((HEAP8[i5] | 0) != 0) {
michael@0 45962 __Z21btAlignedFreeInternalPv(i4);
michael@0 45963 }
michael@0 45964 HEAP32[i3 >> 2] = 0;
michael@0 45965 }
michael@0 45966 HEAP8[i5] = 1;
michael@0 45967 HEAP32[i3 >> 2] = 0;
michael@0 45968 HEAP32[i2 >> 2] = 0;
michael@0 45969 HEAP32[i1 + 68 >> 2] = 0;
michael@0 45970 i2 = i1 + 44 | 0;
michael@0 45971 i3 = i1 + 52 | 0;
michael@0 45972 i5 = HEAP32[i3 >> 2] | 0;
michael@0 45973 i4 = i1 + 56 | 0;
michael@0 45974 if ((i5 | 0) != 0) {
michael@0 45975 if ((HEAP8[i4] | 0) != 0) {
michael@0 45976 __Z21btAlignedFreeInternalPv(i5);
michael@0 45977 }
michael@0 45978 HEAP32[i3 >> 2] = 0;
michael@0 45979 }
michael@0 45980 HEAP8[i4] = 1;
michael@0 45981 HEAP32[i3 >> 2] = 0;
michael@0 45982 HEAP32[i2 >> 2] = 0;
michael@0 45983 HEAP32[i1 + 48 >> 2] = 0;
michael@0 45984 i2 = i1 + 24 | 0;
michael@0 45985 i3 = i1 + 32 | 0;
michael@0 45986 i4 = HEAP32[i3 >> 2] | 0;
michael@0 45987 i5 = i1 + 36 | 0;
michael@0 45988 if ((i4 | 0) != 0) {
michael@0 45989 if ((HEAP8[i5] | 0) != 0) {
michael@0 45990 __Z21btAlignedFreeInternalPv(i4);
michael@0 45991 }
michael@0 45992 HEAP32[i3 >> 2] = 0;
michael@0 45993 }
michael@0 45994 HEAP8[i5] = 1;
michael@0 45995 HEAP32[i3 >> 2] = 0;
michael@0 45996 HEAP32[i2 >> 2] = 0;
michael@0 45997 HEAP32[i1 + 28 >> 2] = 0;
michael@0 45998 i2 = i1 + 4 | 0;
michael@0 45999 i3 = i1 + 12 | 0;
michael@0 46000 i5 = HEAP32[i3 >> 2] | 0;
michael@0 46001 i4 = i1 + 16 | 0;
michael@0 46002 if ((i5 | 0) == 0) {
michael@0 46003 HEAP8[i4] = 1;
michael@0 46004 HEAP32[i3 >> 2] = 0;
michael@0 46005 HEAP32[i2 >> 2] = 0;
michael@0 46006 i6 = i1 + 8 | 0;
michael@0 46007 HEAP32[i6 >> 2] = 0;
michael@0 46008 return;
michael@0 46009 }
michael@0 46010 if ((HEAP8[i4] | 0) != 0) {
michael@0 46011 __Z21btAlignedFreeInternalPv(i5);
michael@0 46012 }
michael@0 46013 HEAP32[i3 >> 2] = 0;
michael@0 46014 HEAP8[i4] = 1;
michael@0 46015 HEAP32[i3 >> 2] = 0;
michael@0 46016 HEAP32[i2 >> 2] = 0;
michael@0 46017 i6 = i1 + 8 | 0;
michael@0 46018 HEAP32[i6 >> 2] = 0;
michael@0 46019 return;
michael@0 46020 }
michael@0 46021 function __ZN11btRigidBody19integrateVelocitiesEf(i1, d2) {
michael@0 46022 i1 = i1 | 0;
michael@0 46023 d2 = +d2;
michael@0 46024 var d3 = 0.0, d4 = 0.0, d5 = 0.0, i6 = 0, d7 = 0.0, d8 = 0.0, d9 = 0.0, i10 = 0, i11 = 0;
michael@0 46025 if ((HEAP32[i1 + 204 >> 2] & 3 | 0) != 0) {
michael@0 46026 return;
michael@0 46027 }
michael@0 46028 d3 = +HEAPF32[i1 + 336 >> 2] * d2;
michael@0 46029 d4 = d3 * +HEAPF32[i1 + 408 >> 2];
michael@0 46030 d5 = d3 * +HEAPF32[i1 + 412 >> 2];
michael@0 46031 i6 = i1 + 304 | 0;
michael@0 46032 HEAPF32[i6 >> 2] = +HEAPF32[i1 + 404 >> 2] * d3 + +HEAPF32[i6 >> 2];
michael@0 46033 i6 = i1 + 308 | 0;
michael@0 46034 HEAPF32[i6 >> 2] = d4 + +HEAPF32[i6 >> 2];
michael@0 46035 i6 = i1 + 312 | 0;
michael@0 46036 HEAPF32[i6 >> 2] = d5 + +HEAPF32[i6 >> 2];
michael@0 46037 d5 = +HEAPF32[i1 + 420 >> 2];
michael@0 46038 d4 = +HEAPF32[i1 + 424 >> 2];
michael@0 46039 d3 = +HEAPF32[i1 + 428 >> 2];
michael@0 46040 d7 = (d5 * +HEAPF32[i1 + 272 >> 2] + d4 * +HEAPF32[i1 + 276 >> 2] + d3 * +HEAPF32[i1 + 280 >> 2]) * d2;
michael@0 46041 d8 = (d5 * +HEAPF32[i1 + 288 >> 2] + d4 * +HEAPF32[i1 + 292 >> 2] + d3 * +HEAPF32[i1 + 296 >> 2]) * d2;
michael@0 46042 i6 = i1 + 320 | 0;
michael@0 46043 d9 = (+HEAPF32[i1 + 256 >> 2] * d5 + +HEAPF32[i1 + 260 >> 2] * d4 + +HEAPF32[i1 + 264 >> 2] * d3) * d2 + +HEAPF32[i6 >> 2];
michael@0 46044 HEAPF32[i6 >> 2] = d9;
michael@0 46045 i10 = i1 + 324 | 0;
michael@0 46046 d3 = d7 + +HEAPF32[i10 >> 2];
michael@0 46047 HEAPF32[i10 >> 2] = d3;
michael@0 46048 i11 = i1 + 328 | 0;
michael@0 46049 d7 = d8 + +HEAPF32[i11 >> 2];
michael@0 46050 HEAPF32[i11 >> 2] = d7;
michael@0 46051 d8 = +Math_sqrt(+(d7 * d7 + (d9 * d9 + d3 * d3)));
michael@0 46052 if (d8 * d2 <= 1.5707963705062866) {
michael@0 46053 return;
michael@0 46054 }
michael@0 46055 d4 = 1.5707963705062866 / d2 / d8;
michael@0 46056 HEAPF32[i6 >> 2] = d9 * d4;
michael@0 46057 HEAPF32[i10 >> 2] = d3 * d4;
michael@0 46058 HEAPF32[i11 >> 2] = d7 * d4;
michael@0 46059 return;
michael@0 46060 }
michael@0 46061 function __ZN9btHashMapI9btHashPtrP16btCollisionShapeED2Ev(i1) {
michael@0 46062 i1 = i1 | 0;
michael@0 46063 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 46064 i2 = i1 + 64 | 0;
michael@0 46065 i3 = i1 + 72 | 0;
michael@0 46066 i4 = HEAP32[i3 >> 2] | 0;
michael@0 46067 i5 = i1 + 76 | 0;
michael@0 46068 if ((i4 | 0) != 0) {
michael@0 46069 if ((HEAP8[i5] | 0) != 0) {
michael@0 46070 __Z21btAlignedFreeInternalPv(i4);
michael@0 46071 }
michael@0 46072 HEAP32[i3 >> 2] = 0;
michael@0 46073 }
michael@0 46074 HEAP8[i5] = 1;
michael@0 46075 HEAP32[i3 >> 2] = 0;
michael@0 46076 HEAP32[i2 >> 2] = 0;
michael@0 46077 HEAP32[i1 + 68 >> 2] = 0;
michael@0 46078 i2 = i1 + 44 | 0;
michael@0 46079 i3 = i1 + 52 | 0;
michael@0 46080 i5 = HEAP32[i3 >> 2] | 0;
michael@0 46081 i4 = i1 + 56 | 0;
michael@0 46082 if ((i5 | 0) != 0) {
michael@0 46083 if ((HEAP8[i4] | 0) != 0) {
michael@0 46084 __Z21btAlignedFreeInternalPv(i5);
michael@0 46085 }
michael@0 46086 HEAP32[i3 >> 2] = 0;
michael@0 46087 }
michael@0 46088 HEAP8[i4] = 1;
michael@0 46089 HEAP32[i3 >> 2] = 0;
michael@0 46090 HEAP32[i2 >> 2] = 0;
michael@0 46091 HEAP32[i1 + 48 >> 2] = 0;
michael@0 46092 i2 = i1 + 24 | 0;
michael@0 46093 i3 = i1 + 32 | 0;
michael@0 46094 i4 = HEAP32[i3 >> 2] | 0;
michael@0 46095 i5 = i1 + 36 | 0;
michael@0 46096 if ((i4 | 0) != 0) {
michael@0 46097 if ((HEAP8[i5] | 0) != 0) {
michael@0 46098 __Z21btAlignedFreeInternalPv(i4);
michael@0 46099 }
michael@0 46100 HEAP32[i3 >> 2] = 0;
michael@0 46101 }
michael@0 46102 HEAP8[i5] = 1;
michael@0 46103 HEAP32[i3 >> 2] = 0;
michael@0 46104 HEAP32[i2 >> 2] = 0;
michael@0 46105 HEAP32[i1 + 28 >> 2] = 0;
michael@0 46106 i2 = i1 + 4 | 0;
michael@0 46107 i3 = i1 + 12 | 0;
michael@0 46108 i5 = HEAP32[i3 >> 2] | 0;
michael@0 46109 i4 = i1 + 16 | 0;
michael@0 46110 if ((i5 | 0) == 0) {
michael@0 46111 HEAP8[i4] = 1;
michael@0 46112 HEAP32[i3 >> 2] = 0;
michael@0 46113 HEAP32[i2 >> 2] = 0;
michael@0 46114 i6 = i1 + 8 | 0;
michael@0 46115 HEAP32[i6 >> 2] = 0;
michael@0 46116 return;
michael@0 46117 }
michael@0 46118 if ((HEAP8[i4] | 0) != 0) {
michael@0 46119 __Z21btAlignedFreeInternalPv(i5);
michael@0 46120 }
michael@0 46121 HEAP32[i3 >> 2] = 0;
michael@0 46122 HEAP8[i4] = 1;
michael@0 46123 HEAP32[i3 >> 2] = 0;
michael@0 46124 HEAP32[i2 >> 2] = 0;
michael@0 46125 i6 = i1 + 8 | 0;
michael@0 46126 HEAP32[i6 >> 2] = 0;
michael@0 46127 return;
michael@0 46128 }
michael@0 46129 function __ZN33btConvexConcaveCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 46130 i1 = i1 | 0;
michael@0 46131 i2 = i2 | 0;
michael@0 46132 i3 = i3 | 0;
michael@0 46133 i4 = i4 | 0;
michael@0 46134 i5 = i5 | 0;
michael@0 46135 var i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, i10 = 0, i11 = 0;
michael@0 46136 i6 = (HEAP8[i1 + 8 | 0] | 0) != 0;
michael@0 46137 i7 = i6 ? i3 : i2;
michael@0 46138 i8 = i6 ? i2 : i3;
michael@0 46139 i3 = HEAP32[i8 + 192 >> 2] | 0;
michael@0 46140 if (((HEAP32[i3 + 4 >> 2] | 0) - 21 | 0) >>> 0 >= 9) {
michael@0 46141 return;
michael@0 46142 }
michael@0 46143 i2 = i3;
michael@0 46144 if ((HEAP32[(HEAP32[i7 + 192 >> 2] | 0) + 4 >> 2] | 0) >= 20) {
michael@0 46145 return;
michael@0 46146 }
michael@0 46147 d9 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i3 >> 2] | 0) + 44 >> 2] & 7](i2);
michael@0 46148 i6 = i1 + 12 | 0;
michael@0 46149 i10 = i1 + 76 | 0;
michael@0 46150 i11 = i5 + 4 | 0;
michael@0 46151 HEAP32[i11 >> 2] = HEAP32[i10 >> 2];
michael@0 46152 __ZN24btConvexTriangleCallback22setTimeStepAndCountersEfRK16btDispatcherInfoP16btManifoldResult(i6, d9, i4, i5);
michael@0 46153 i4 = HEAP32[i10 >> 2] | 0;
michael@0 46154 HEAP32[i4 + 1108 >> 2] = i7;
michael@0 46155 HEAP32[i4 + 1112 >> 2] = i8;
michael@0 46156 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i3 >> 2] | 0) + 60 >> 2] & 127](i2, i6 | 0, i1 + 24 | 0, i1 + 40 | 0);
michael@0 46157 i1 = HEAP32[i11 >> 2] | 0;
michael@0 46158 if ((HEAP32[i1 + 1116 >> 2] | 0) == 0) {
michael@0 46159 return;
michael@0 46160 }
michael@0 46161 if ((HEAP32[i1 + 1108 >> 2] | 0) == (HEAP32[i5 + 136 >> 2] | 0)) {
michael@0 46162 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 8 | 0, i5 + 72 | 0);
michael@0 46163 return;
michael@0 46164 } else {
michael@0 46165 __ZN20btPersistentManifold20refreshContactPointsERK11btTransformS2_(i1, i5 + 72 | 0, i5 + 8 | 0);
michael@0 46166 return;
michael@0 46167 }
michael@0 46168 }
michael@0 46169 function __ZN11btRigidBodyC2EfP13btMotionStateP16btCollisionShapeRK9btVector3(i1, d2, i3, i4, i5) {
michael@0 46170 i1 = i1 | 0;
michael@0 46171 d2 = +d2;
michael@0 46172 i3 = i3 | 0;
michael@0 46173 i4 = i4 | 0;
michael@0 46174 i5 = i5 | 0;
michael@0 46175 var i6 = 0, i7 = 0;
michael@0 46176 i6 = STACKTOP;
michael@0 46177 STACKTOP = STACKTOP + 136 | 0;
michael@0 46178 i7 = i6 | 0;
michael@0 46179 __ZN17btCollisionObjectC2Ev(i1 | 0);
michael@0 46180 HEAP32[i1 >> 2] = 4936;
michael@0 46181 HEAP8[i1 + 492 | 0] = 1;
michael@0 46182 HEAP32[i1 + 488 >> 2] = 0;
michael@0 46183 HEAP32[i1 + 480 >> 2] = 0;
michael@0 46184 HEAP32[i1 + 484 >> 2] = 0;
michael@0 46185 HEAPF32[i7 >> 2] = d2;
michael@0 46186 HEAP32[i7 + 4 >> 2] = i3;
michael@0 46187 HEAP32[i7 + 72 >> 2] = i4;
michael@0 46188 i4 = i7 + 76 | 0;
michael@0 46189 i3 = i5;
michael@0 46190 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 46191 HEAP32[i4 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 46192 HEAP32[i4 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 46193 HEAP32[i4 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 46194 HEAPF32[i7 + 92 >> 2] = 0.0;
michael@0 46195 HEAPF32[i7 + 96 >> 2] = 0.0;
michael@0 46196 HEAPF32[i7 + 100 >> 2] = .5;
michael@0 46197 HEAPF32[i7 + 104 >> 2] = 0.0;
michael@0 46198 HEAPF32[i7 + 108 >> 2] = .800000011920929;
michael@0 46199 HEAPF32[i7 + 112 >> 2] = 1.0;
michael@0 46200 HEAP8[i7 + 116 | 0] = 0;
michael@0 46201 HEAPF32[i7 + 120 >> 2] = .004999999888241291;
michael@0 46202 HEAPF32[i7 + 124 >> 2] = .009999999776482582;
michael@0 46203 HEAPF32[i7 + 128 >> 2] = .009999999776482582;
michael@0 46204 HEAPF32[i7 + 132 >> 2] = .009999999776482582;
michael@0 46205 HEAPF32[i7 + 8 >> 2] = 1.0;
michael@0 46206 _memset(i7 + 12 | 0, 0, 16);
michael@0 46207 HEAPF32[i7 + 28 >> 2] = 1.0;
michael@0 46208 _memset(i7 + 32 | 0, 0, 16);
michael@0 46209 HEAPF32[i7 + 48 >> 2] = 1.0;
michael@0 46210 _memset(i7 + 52 | 0, 0, 20);
michael@0 46211 __ZN11btRigidBody14setupRigidBodyERKNS_27btRigidBodyConstructionInfoE(i1, i7);
michael@0 46212 STACKTOP = i6;
michael@0 46213 return;
michael@0 46214 }
michael@0 46215 function __ZN11btUnionFind8allocateEi(i1, i2) {
michael@0 46216 i1 = i1 | 0;
michael@0 46217 i2 = i2 | 0;
michael@0 46218 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0;
michael@0 46219 i3 = i1 + 4 | 0;
michael@0 46220 i4 = HEAP32[i3 >> 2] | 0;
michael@0 46221 if ((i4 | 0) >= (i2 | 0)) {
michael@0 46222 HEAP32[i3 >> 2] = i2;
michael@0 46223 return;
michael@0 46224 }
michael@0 46225 i5 = i1 + 8 | 0;
michael@0 46226 if ((HEAP32[i5 >> 2] | 0) < (i2 | 0)) {
michael@0 46227 if ((i2 | 0) == 0) {
michael@0 46228 i6 = 0;
michael@0 46229 i7 = i4;
michael@0 46230 } else {
michael@0 46231 i8 = __Z22btAlignedAllocInternalji(i2 << 3, 16) | 0;
michael@0 46232 i6 = i8;
michael@0 46233 i7 = HEAP32[i3 >> 2] | 0;
michael@0 46234 }
michael@0 46235 i8 = i1 + 12 | 0;
michael@0 46236 if ((i7 | 0) > 0) {
michael@0 46237 i9 = 0;
michael@0 46238 do {
michael@0 46239 i10 = i6 + (i9 << 3) | 0;
michael@0 46240 if ((i10 | 0) != 0) {
michael@0 46241 i11 = (HEAP32[i8 >> 2] | 0) + (i9 << 3) | 0;
michael@0 46242 i12 = i10;
michael@0 46243 i10 = HEAP32[i11 + 4 >> 2] | 0;
michael@0 46244 HEAP32[i12 >> 2] = HEAP32[i11 >> 2];
michael@0 46245 HEAP32[i12 + 4 >> 2] = i10;
michael@0 46246 }
michael@0 46247 i9 = i9 + 1 | 0;
michael@0 46248 } while ((i9 | 0) < (i7 | 0));
michael@0 46249 }
michael@0 46250 i7 = HEAP32[i8 >> 2] | 0;
michael@0 46251 i9 = i1 + 16 | 0;
michael@0 46252 if ((i7 | 0) != 0) {
michael@0 46253 if ((HEAP8[i9] | 0) != 0) {
michael@0 46254 __Z21btAlignedFreeInternalPv(i7);
michael@0 46255 }
michael@0 46256 HEAP32[i8 >> 2] = 0;
michael@0 46257 }
michael@0 46258 HEAP8[i9] = 1;
michael@0 46259 HEAP32[i8 >> 2] = i6;
michael@0 46260 HEAP32[i5 >> 2] = i2;
michael@0 46261 i13 = i8;
michael@0 46262 } else {
michael@0 46263 i13 = i1 + 12 | 0;
michael@0 46264 }
michael@0 46265 i1 = i4;
michael@0 46266 do {
michael@0 46267 i4 = (HEAP32[i13 >> 2] | 0) + (i1 << 3) | 0;
michael@0 46268 if ((i4 | 0) != 0) {
michael@0 46269 i8 = i4;
michael@0 46270 HEAP32[i8 >> 2] = 0;
michael@0 46271 HEAP32[i8 + 4 >> 2] = 0;
michael@0 46272 }
michael@0 46273 i1 = i1 + 1 | 0;
michael@0 46274 } while ((i1 | 0) < (i2 | 0));
michael@0 46275 HEAP32[i3 >> 2] = i2;
michael@0 46276 return;
michael@0 46277 }
michael@0 46278 function __ZNK10btBoxShape7getAabbERK11btTransformR9btVector3S4_(i1, i2, i3, i4) {
michael@0 46279 i1 = i1 | 0;
michael@0 46280 i2 = i2 | 0;
michael@0 46281 i3 = i3 | 0;
michael@0 46282 i4 = i4 | 0;
michael@0 46283 var d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0;
michael@0 46284 d5 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i1 >> 2] | 0) + 44 >> 2] & 7](i1 | 0);
michael@0 46285 d6 = d5 + +HEAPF32[i1 + 28 >> 2];
michael@0 46286 d7 = d5 + +HEAPF32[i1 + 32 >> 2];
michael@0 46287 d8 = d5 + +HEAPF32[i1 + 36 >> 2];
michael@0 46288 d5 = +Math_abs(+(+HEAPF32[i2 >> 2]));
michael@0 46289 d9 = +Math_abs(+(+HEAPF32[i2 + 4 >> 2]));
michael@0 46290 d10 = +Math_abs(+(+HEAPF32[i2 + 8 >> 2]));
michael@0 46291 d11 = +Math_abs(+(+HEAPF32[i2 + 16 >> 2]));
michael@0 46292 d12 = +Math_abs(+(+HEAPF32[i2 + 20 >> 2]));
michael@0 46293 d13 = +Math_abs(+(+HEAPF32[i2 + 24 >> 2]));
michael@0 46294 d14 = +Math_abs(+(+HEAPF32[i2 + 32 >> 2]));
michael@0 46295 d15 = +Math_abs(+(+HEAPF32[i2 + 36 >> 2]));
michael@0 46296 d16 = +Math_abs(+(+HEAPF32[i2 + 40 >> 2]));
michael@0 46297 d17 = +HEAPF32[i2 + 48 >> 2];
michael@0 46298 d18 = +HEAPF32[i2 + 52 >> 2];
michael@0 46299 d19 = +HEAPF32[i2 + 56 >> 2];
michael@0 46300 d20 = d6 * d5 + d7 * d9 + d8 * d10;
michael@0 46301 d10 = d6 * d11 + d7 * d12 + d8 * d13;
michael@0 46302 d13 = d6 * d14 + d7 * d15 + d8 * d16;
michael@0 46303 HEAPF32[i3 >> 2] = d17 - d20;
michael@0 46304 HEAPF32[i3 + 4 >> 2] = d18 - d10;
michael@0 46305 HEAPF32[i3 + 8 >> 2] = d19 - d13;
michael@0 46306 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 46307 HEAPF32[i4 >> 2] = d20 + d17;
michael@0 46308 HEAPF32[i4 + 4 >> 2] = d10 + d18;
michael@0 46309 HEAPF32[i4 + 8 >> 2] = d13 + d19;
michael@0 46310 HEAPF32[i4 + 12 >> 2] = 0.0;
michael@0 46311 return;
michael@0 46312 }
michael@0 46313 function __ZNK15btTriangleShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i(i1, i2, i3, i4) {
michael@0 46314 i1 = i1 | 0;
michael@0 46315 i2 = i2 | 0;
michael@0 46316 i3 = i3 | 0;
michael@0 46317 i4 = i4 | 0;
michael@0 46318 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0, i21 = 0, i22 = 0, i23 = 0;
michael@0 46319 if ((i4 | 0) <= 0) {
michael@0 46320 return;
michael@0 46321 }
michael@0 46322 i5 = i1 + 56 | 0;
michael@0 46323 i6 = i1 + 60 | 0;
michael@0 46324 i7 = i1 + 64 | 0;
michael@0 46325 i8 = i1 + 72 | 0;
michael@0 46326 i9 = i1 + 76 | 0;
michael@0 46327 i10 = i1 + 80 | 0;
michael@0 46328 i11 = i1 + 88 | 0;
michael@0 46329 i12 = i1 + 92 | 0;
michael@0 46330 i13 = i1 + 96 | 0;
michael@0 46331 i14 = 0;
michael@0 46332 do {
michael@0 46333 d15 = +HEAPF32[i2 + (i14 << 4) >> 2];
michael@0 46334 d16 = +HEAPF32[i2 + (i14 << 4) + 4 >> 2];
michael@0 46335 d17 = +HEAPF32[i2 + (i14 << 4) + 8 >> 2];
michael@0 46336 d18 = d15 * +HEAPF32[i5 >> 2] + d16 * +HEAPF32[i6 >> 2] + d17 * +HEAPF32[i7 >> 2];
michael@0 46337 d19 = d15 * +HEAPF32[i8 >> 2] + d16 * +HEAPF32[i9 >> 2] + d17 * +HEAPF32[i10 >> 2];
michael@0 46338 d20 = d15 * +HEAPF32[i11 >> 2] + d16 * +HEAPF32[i12 >> 2] + d17 * +HEAPF32[i13 >> 2];
michael@0 46339 if (d18 < d19) {
michael@0 46340 i21 = d19 < d20 ? 2 : 1;
michael@0 46341 } else {
michael@0 46342 i21 = d18 < d20 ? 2 : 0;
michael@0 46343 }
michael@0 46344 i22 = i3 + (i14 << 4) | 0;
michael@0 46345 i23 = i1 + 56 + (i21 << 4) | 0;
michael@0 46346 HEAP32[i22 >> 2] = HEAP32[i23 >> 2];
michael@0 46347 HEAP32[i22 + 4 >> 2] = HEAP32[i23 + 4 >> 2];
michael@0 46348 HEAP32[i22 + 8 >> 2] = HEAP32[i23 + 8 >> 2];
michael@0 46349 HEAP32[i22 + 12 >> 2] = HEAP32[i23 + 12 >> 2];
michael@0 46350 i14 = i14 + 1 | 0;
michael@0 46351 } while ((i14 | 0) < (i4 | 0));
michael@0 46352 return;
michael@0 46353 }
michael@0 46354 function __ZN20btAlignedObjectArrayI6btFaceE7reserveEi(i1, i2) {
michael@0 46355 i1 = i1 | 0;
michael@0 46356 i2 = i2 | 0;
michael@0 46357 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0;
michael@0 46358 i3 = i1 + 8 | 0;
michael@0 46359 if ((HEAP32[i3 >> 2] | 0) >= (i2 | 0)) {
michael@0 46360 return;
michael@0 46361 }
michael@0 46362 if ((i2 | 0) == 0) {
michael@0 46363 i4 = 0;
michael@0 46364 } else {
michael@0 46365 i4 = __Z22btAlignedAllocInternalji(i2 * 56 | 0, 16) | 0;
michael@0 46366 }
michael@0 46367 i5 = i1 + 4 | 0;
michael@0 46368 i6 = HEAP32[i5 >> 2] | 0;
michael@0 46369 i7 = i1 + 12 | 0;
michael@0 46370 if ((i6 | 0) > 0) {
michael@0 46371 i8 = 0;
michael@0 46372 do {
michael@0 46373 i9 = i4 + (i8 * 56 | 0) | 0;
michael@0 46374 if ((i9 | 0) != 0) {
michael@0 46375 i10 = HEAP32[i7 >> 2] | 0;
michael@0 46376 __ZN20btAlignedObjectArrayIiEC2ERKS0_(i9, i10 + (i8 * 56 | 0) | 0);
michael@0 46377 __ZN20btAlignedObjectArrayIiEC2ERKS0_(i9 + 20 | 0, i10 + (i8 * 56 | 0) + 20 | 0);
michael@0 46378 i11 = i9 + 40 | 0;
michael@0 46379 i9 = i10 + (i8 * 56 | 0) + 40 | 0;
michael@0 46380 HEAP32[i11 >> 2] = HEAP32[i9 >> 2];
michael@0 46381 HEAP32[i11 + 4 >> 2] = HEAP32[i9 + 4 >> 2];
michael@0 46382 HEAP32[i11 + 8 >> 2] = HEAP32[i9 + 8 >> 2];
michael@0 46383 HEAP32[i11 + 12 >> 2] = HEAP32[i9 + 12 >> 2];
michael@0 46384 }
michael@0 46385 i8 = i8 + 1 | 0;
michael@0 46386 } while ((i8 | 0) < (i6 | 0));
michael@0 46387 i12 = HEAP32[i5 >> 2] | 0;
michael@0 46388 } else {
michael@0 46389 i12 = i6;
michael@0 46390 }
michael@0 46391 __ZN20btAlignedObjectArrayI6btFaceE7destroyEii(i1, 0, i12);
michael@0 46392 i12 = HEAP32[i7 >> 2] | 0;
michael@0 46393 i6 = i1 + 16 | 0;
michael@0 46394 if ((i12 | 0) != 0) {
michael@0 46395 if ((HEAP8[i6] | 0) != 0) {
michael@0 46396 __Z21btAlignedFreeInternalPv(i12 | 0);
michael@0 46397 }
michael@0 46398 HEAP32[i7 >> 2] = 0;
michael@0 46399 }
michael@0 46400 HEAP8[i6] = 1;
michael@0 46401 HEAP32[i7 >> 2] = i4;
michael@0 46402 HEAP32[i3 >> 2] = i2;
michael@0 46403 return;
michael@0 46404 }
michael@0 46405 function __ZN28btHashedOverlappingPairCacheC2Ev(i1) {
michael@0 46406 i1 = i1 | 0;
michael@0 46407 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 46408 HEAP32[i1 >> 2] = 2800;
michael@0 46409 i2 = i1 + 20 | 0;
michael@0 46410 HEAP8[i2] = 1;
michael@0 46411 i3 = i1 + 16 | 0;
michael@0 46412 HEAP32[i3 >> 2] = 0;
michael@0 46413 i4 = i1 + 8 | 0;
michael@0 46414 HEAP32[i4 >> 2] = 0;
michael@0 46415 i5 = i1 + 12 | 0;
michael@0 46416 HEAP32[i5 >> 2] = 0;
michael@0 46417 HEAP32[i1 + 24 >> 2] = 0;
michael@0 46418 HEAP8[i1 + 28 | 0] = 0;
michael@0 46419 HEAP8[i1 + 48 | 0] = 1;
michael@0 46420 HEAP32[i1 + 44 >> 2] = 0;
michael@0 46421 HEAP32[i1 + 36 >> 2] = 0;
michael@0 46422 HEAP32[i1 + 40 >> 2] = 0;
michael@0 46423 HEAP8[i1 + 68 | 0] = 1;
michael@0 46424 HEAP32[i1 + 64 >> 2] = 0;
michael@0 46425 HEAP32[i1 + 56 >> 2] = 0;
michael@0 46426 HEAP32[i1 + 60 >> 2] = 0;
michael@0 46427 HEAP32[i1 + 72 >> 2] = 0;
michael@0 46428 i6 = __Z22btAlignedAllocInternalji(32, 16) | 0;
michael@0 46429 i7 = HEAP32[i4 >> 2] | 0;
michael@0 46430 if ((i7 | 0) > 0) {
michael@0 46431 i4 = 0;
michael@0 46432 do {
michael@0 46433 i8 = HEAP32[i3 >> 2] | 0;
michael@0 46434 HEAP32[i6 + (i4 << 4) >> 2] = HEAP32[i8 + (i4 << 4) >> 2];
michael@0 46435 HEAP32[i6 + (i4 << 4) + 4 >> 2] = HEAP32[i8 + (i4 << 4) + 4 >> 2];
michael@0 46436 HEAP32[i6 + (i4 << 4) + 8 >> 2] = HEAP32[i8 + (i4 << 4) + 8 >> 2];
michael@0 46437 HEAP32[i6 + (i4 << 4) + 12 >> 2] = HEAP32[i8 + (i4 << 4) + 12 >> 2];
michael@0 46438 i4 = i4 + 1 | 0;
michael@0 46439 } while ((i4 | 0) < (i7 | 0));
michael@0 46440 }
michael@0 46441 i7 = HEAP32[i3 >> 2] | 0;
michael@0 46442 if ((i7 | 0) != 0) {
michael@0 46443 if ((HEAP8[i2] | 0) != 0) {
michael@0 46444 __Z21btAlignedFreeInternalPv(i7);
michael@0 46445 }
michael@0 46446 HEAP32[i3 >> 2] = 0;
michael@0 46447 }
michael@0 46448 HEAP8[i2] = 1;
michael@0 46449 HEAP32[i3 >> 2] = i6;
michael@0 46450 HEAP32[i5 >> 2] = 2;
michael@0 46451 __ZN28btHashedOverlappingPairCache10growTablesEv(i1);
michael@0 46452 return;
michael@0 46453 }
michael@0 46454 function __ZN15CProfileManager13Start_ProfileEPKc(i1) {
michael@0 46455 i1 = i1 | 0;
michael@0 46456 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0;
michael@0 46457 i2 = STACKTOP;
michael@0 46458 STACKTOP = STACKTOP + 8 | 0;
michael@0 46459 i3 = i2 | 0;
michael@0 46460 i4 = HEAP32[2966] | 0;
michael@0 46461 if ((HEAP32[i4 >> 2] | 0) == (i1 | 0)) {
michael@0 46462 i5 = i4;
michael@0 46463 } else {
michael@0 46464 i6 = i4 + 24 | 0;
michael@0 46465 i7 = i6;
michael@0 46466 while (1) {
michael@0 46467 i8 = HEAP32[i7 >> 2] | 0;
michael@0 46468 if ((i8 | 0) == 0) {
michael@0 46469 i9 = 1900;
michael@0 46470 break;
michael@0 46471 }
michael@0 46472 if ((HEAP32[i8 >> 2] | 0) == (i1 | 0)) {
michael@0 46473 i10 = i8;
michael@0 46474 break;
michael@0 46475 } else {
michael@0 46476 i7 = i8 + 28 | 0;
michael@0 46477 }
michael@0 46478 }
michael@0 46479 if ((i9 | 0) == 1900) {
michael@0 46480 i9 = __Znwj(32) | 0;
michael@0 46481 i7 = i9;
michael@0 46482 HEAP32[i9 >> 2] = i1;
michael@0 46483 _memset(i9 + 4 | 0, 0, 16);
michael@0 46484 HEAP32[i9 + 20 >> 2] = i4;
michael@0 46485 HEAP32[i9 + 24 >> 2] = 0;
michael@0 46486 i4 = i9 + 28 | 0;
michael@0 46487 HEAP32[i4 >> 2] = 0;
michael@0 46488 __ZN12CProfileNode5ResetEv(i7);
michael@0 46489 HEAP32[i4 >> 2] = HEAP32[i6 >> 2];
michael@0 46490 HEAP32[i6 >> 2] = i7;
michael@0 46491 i10 = i7;
michael@0 46492 }
michael@0 46493 HEAP32[2966] = i10;
michael@0 46494 i5 = i10;
michael@0 46495 }
michael@0 46496 i10 = i5 + 4 | 0;
michael@0 46497 HEAP32[i10 >> 2] = (HEAP32[i10 >> 2] | 0) + 1;
michael@0 46498 i10 = i5 + 16 | 0;
michael@0 46499 i7 = HEAP32[i10 >> 2] | 0;
michael@0 46500 HEAP32[i10 >> 2] = i7 + 1;
michael@0 46501 if ((i7 | 0) != 0) {
michael@0 46502 STACKTOP = i2;
michael@0 46503 return;
michael@0 46504 }
michael@0 46505 _gettimeofday(i3 | 0, 0) | 0;
michael@0 46506 i7 = HEAP32[3578] | 0;
michael@0 46507 HEAP32[i5 + 12 >> 2] = (HEAP32[i3 + 4 >> 2] | 0) - (HEAP32[i7 + 4 >> 2] | 0) + (((HEAP32[i3 >> 2] | 0) - (HEAP32[i7 >> 2] | 0) | 0) * 1e6 | 0);
michael@0 46508 STACKTOP = i2;
michael@0 46509 return;
michael@0 46510 }
michael@0 46511 function __ZN20btAlignedObjectArrayIiEC2ERKS0_(i1, i2) {
michael@0 46512 i1 = i1 | 0;
michael@0 46513 i2 = i2 | 0;
michael@0 46514 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0;
michael@0 46515 i3 = i1 + 16 | 0;
michael@0 46516 HEAP8[i3] = 1;
michael@0 46517 i4 = i1 + 12 | 0;
michael@0 46518 HEAP32[i4 >> 2] = 0;
michael@0 46519 i5 = i1 + 4 | 0;
michael@0 46520 HEAP32[i5 >> 2] = 0;
michael@0 46521 i6 = i1 + 8 | 0;
michael@0 46522 HEAP32[i6 >> 2] = 0;
michael@0 46523 i1 = HEAP32[i2 + 4 >> 2] | 0;
michael@0 46524 if ((i1 | 0) <= 0) {
michael@0 46525 HEAP32[i5 >> 2] = i1;
michael@0 46526 return;
michael@0 46527 }
michael@0 46528 i7 = __Z22btAlignedAllocInternalji(i1 << 2, 16) | 0;
michael@0 46529 i8 = HEAP32[i5 >> 2] | 0;
michael@0 46530 if ((i8 | 0) > 0) {
michael@0 46531 i9 = 0;
michael@0 46532 do {
michael@0 46533 i10 = i7 + (i9 << 2) | 0;
michael@0 46534 if ((i10 | 0) != 0) {
michael@0 46535 HEAP32[i10 >> 2] = HEAP32[(HEAP32[i4 >> 2] | 0) + (i9 << 2) >> 2];
michael@0 46536 }
michael@0 46537 i9 = i9 + 1 | 0;
michael@0 46538 } while ((i9 | 0) < (i8 | 0));
michael@0 46539 }
michael@0 46540 i8 = HEAP32[i4 >> 2] | 0;
michael@0 46541 if ((i8 | 0) != 0) {
michael@0 46542 if ((HEAP8[i3] | 0) != 0) {
michael@0 46543 __Z21btAlignedFreeInternalPv(i8);
michael@0 46544 }
michael@0 46545 HEAP32[i4 >> 2] = 0;
michael@0 46546 }
michael@0 46547 HEAP8[i3] = 1;
michael@0 46548 HEAP32[i4 >> 2] = i7;
michael@0 46549 HEAP32[i6 >> 2] = i1;
michael@0 46550 i6 = 0;
michael@0 46551 do {
michael@0 46552 i4 = i7 + (i6 << 2) | 0;
michael@0 46553 if ((i4 | 0) != 0) {
michael@0 46554 HEAP32[i4 >> 2] = 0;
michael@0 46555 }
michael@0 46556 i6 = i6 + 1 | 0;
michael@0 46557 } while ((i6 | 0) < (i1 | 0));
michael@0 46558 HEAP32[i5 >> 2] = i1;
michael@0 46559 i5 = i2 + 12 | 0;
michael@0 46560 i2 = 0;
michael@0 46561 do {
michael@0 46562 i6 = i7 + (i2 << 2) | 0;
michael@0 46563 if ((i6 | 0) != 0) {
michael@0 46564 HEAP32[i6 >> 2] = HEAP32[(HEAP32[i5 >> 2] | 0) + (i2 << 2) >> 2];
michael@0 46565 }
michael@0 46566 i2 = i2 + 1 | 0;
michael@0 46567 } while ((i2 | 0) < (i1 | 0));
michael@0 46568 return;
michael@0 46569 }
michael@0 46570 function __ZN25btSimulationIslandManager26storeIslandActivationStateEP16btCollisionWorld(i1, i2) {
michael@0 46571 i1 = i1 | 0;
michael@0 46572 i2 = i2 | 0;
michael@0 46573 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0;
michael@0 46574 i3 = i2 + 8 | 0;
michael@0 46575 if ((HEAP32[i3 >> 2] | 0) <= 0) {
michael@0 46576 return;
michael@0 46577 }
michael@0 46578 i4 = HEAP32[i2 + 16 >> 2] | 0;
michael@0 46579 i2 = i1 + 16 | 0;
michael@0 46580 i1 = 0;
michael@0 46581 i5 = 0;
michael@0 46582 while (1) {
michael@0 46583 i6 = HEAP32[i4 + (i1 << 2) >> 2] | 0;
michael@0 46584 if ((HEAP32[i6 + 204 >> 2] & 3 | 0) == 0) {
michael@0 46585 i7 = HEAP32[i2 >> 2] | 0;
michael@0 46586 i8 = i7 + (i5 << 3) | 0;
michael@0 46587 i9 = HEAP32[i8 >> 2] | 0;
michael@0 46588 if ((i9 | 0) == (i5 | 0)) {
michael@0 46589 i10 = i5;
michael@0 46590 } else {
michael@0 46591 i11 = i8;
michael@0 46592 i8 = i9;
michael@0 46593 while (1) {
michael@0 46594 i9 = i7 + (i8 << 3) | 0;
michael@0 46595 HEAP32[i11 >> 2] = HEAP32[i9 >> 2];
michael@0 46596 i12 = HEAP32[i9 >> 2] | 0;
michael@0 46597 i9 = i7 + (i12 << 3) | 0;
michael@0 46598 i13 = HEAP32[i9 >> 2] | 0;
michael@0 46599 if ((i12 | 0) == (i13 | 0)) {
michael@0 46600 i10 = i12;
michael@0 46601 break;
michael@0 46602 } else {
michael@0 46603 i11 = i9;
michael@0 46604 i8 = i13;
michael@0 46605 }
michael@0 46606 }
michael@0 46607 }
michael@0 46608 HEAP32[i6 + 208 >> 2] = i10;
michael@0 46609 HEAP32[i7 + (i5 << 3) + 4 >> 2] = i1;
michael@0 46610 HEAP32[i6 + 212 >> 2] = -1;
michael@0 46611 i14 = i5 + 1 | 0;
michael@0 46612 } else {
michael@0 46613 HEAP32[i6 + 208 >> 2] = -1;
michael@0 46614 HEAP32[i6 + 212 >> 2] = -2;
michael@0 46615 i14 = i5;
michael@0 46616 }
michael@0 46617 i8 = i1 + 1 | 0;
michael@0 46618 if ((i8 | 0) < (HEAP32[i3 >> 2] | 0)) {
michael@0 46619 i1 = i8;
michael@0 46620 i5 = i14;
michael@0 46621 } else {
michael@0 46622 break;
michael@0 46623 }
michael@0 46624 }
michael@0 46625 return;
michael@0 46626 }
michael@0 46627 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN9RayTester7ProcessE_1PK10btDbvtNode(i1, i2) {
michael@0 46628 i1 = i1 | 0;
michael@0 46629 i2 = i2 | 0;
michael@0 46630 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0;
michael@0 46631 i3 = STACKTOP;
michael@0 46632 STACKTOP = STACKTOP + 96 | 0;
michael@0 46633 i4 = i3 | 0;
michael@0 46634 i5 = i3 + 64 | 0;
michael@0 46635 i6 = HEAP32[i2 + 36 >> 2] | 0;
michael@0 46636 i2 = HEAP32[(HEAP32[i1 + 8 >> 2] | 0) + 24 >> 2] | 0;
michael@0 46637 i7 = HEAP32[i2 + (i6 * 80 | 0) + 64 >> 2] | 0;
michael@0 46638 __ZNK11btTransformmlERKS_(i4, HEAP32[i1 + 12 >> 2] | 0, i2 + (i6 * 80 | 0) | 0);
michael@0 46639 i2 = i1 + 4 | 0;
michael@0 46640 i8 = (HEAP32[i2 >> 2] | 0) + 192 | 0;
michael@0 46641 i9 = HEAP32[i8 >> 2] | 0;
michael@0 46642 HEAP32[i8 >> 2] = i7;
michael@0 46643 i8 = HEAP32[i1 + 24 >> 2] | 0;
michael@0 46644 i10 = i5 + 4 | 0;
michael@0 46645 HEAPF32[i10 >> 2] = 1.0;
michael@0 46646 HEAP32[i5 + 8 >> 2] = 0;
michael@0 46647 HEAP16[i5 + 12 >> 1] = 1;
michael@0 46648 HEAP16[i5 + 14 >> 1] = -1;
michael@0 46649 HEAP32[i5 + 16 >> 2] = 0;
michael@0 46650 HEAP32[i5 >> 2] = 1864;
michael@0 46651 HEAP32[i5 + 20 >> 2] = i8;
michael@0 46652 HEAP32[i5 + 24 >> 2] = i6;
michael@0 46653 HEAPF32[i10 >> 2] = +HEAPF32[i8 + 4 >> 2];
michael@0 46654 __ZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackE(HEAP32[i1 + 16 >> 2] | 0, HEAP32[i1 + 20 >> 2] | 0, HEAP32[i2 >> 2] | 0, i7, i4, i5 | 0);
michael@0 46655 HEAP32[(HEAP32[i2 >> 2] | 0) + 192 >> 2] = i9;
michael@0 46656 STACKTOP = i3;
michael@0 46657 return;
michael@0 46658 }
michael@0 46659 function __ZN11btRigidBody12setMassPropsEfRK9btVector3(i1, d2, i3) {
michael@0 46660 i1 = i1 | 0;
michael@0 46661 d2 = +d2;
michael@0 46662 i3 = i3 | 0;
michael@0 46663 var i4 = 0, i5 = 0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0;
michael@0 46664 i4 = i1 + 204 | 0;
michael@0 46665 i5 = HEAP32[i4 >> 2] | 0;
michael@0 46666 if (d2 == 0.0) {
michael@0 46667 HEAP32[i4 >> 2] = i5 | 1;
michael@0 46668 HEAPF32[i1 + 336 >> 2] = 0.0;
michael@0 46669 d6 = 0.0;
michael@0 46670 } else {
michael@0 46671 HEAP32[i4 >> 2] = i5 & -2;
michael@0 46672 d7 = 1.0 / d2;
michael@0 46673 HEAPF32[i1 + 336 >> 2] = d7;
michael@0 46674 d6 = d7;
michael@0 46675 }
michael@0 46676 d7 = +HEAPF32[i1 + 376 >> 2] * d2;
michael@0 46677 d8 = +HEAPF32[i1 + 380 >> 2] * d2;
michael@0 46678 HEAPF32[i1 + 356 >> 2] = +HEAPF32[i1 + 372 >> 2] * d2;
michael@0 46679 HEAPF32[i1 + 360 >> 2] = d7;
michael@0 46680 HEAPF32[i1 + 364 >> 2] = d8;
michael@0 46681 HEAPF32[i1 + 368 >> 2] = 0.0;
michael@0 46682 d8 = +HEAPF32[i3 >> 2];
michael@0 46683 if (d8 != 0.0) {
michael@0 46684 d9 = 1.0 / d8;
michael@0 46685 } else {
michael@0 46686 d9 = 0.0;
michael@0 46687 }
michael@0 46688 d8 = +HEAPF32[i3 + 4 >> 2];
michael@0 46689 if (d8 != 0.0) {
michael@0 46690 d10 = 1.0 / d8;
michael@0 46691 } else {
michael@0 46692 d10 = 0.0;
michael@0 46693 }
michael@0 46694 d8 = +HEAPF32[i3 + 8 >> 2];
michael@0 46695 if (d8 != 0.0) {
michael@0 46696 d11 = 1.0 / d8;
michael@0 46697 } else {
michael@0 46698 d11 = 0.0;
michael@0 46699 }
michael@0 46700 HEAPF32[i1 + 388 >> 2] = d9;
michael@0 46701 HEAPF32[i1 + 392 >> 2] = d10;
michael@0 46702 HEAPF32[i1 + 396 >> 2] = d11;
michael@0 46703 HEAPF32[i1 + 400 >> 2] = 0.0;
michael@0 46704 d11 = d6 * +HEAPF32[i1 + 344 >> 2];
michael@0 46705 d10 = d6 * +HEAPF32[i1 + 348 >> 2];
michael@0 46706 HEAPF32[i1 + 552 >> 2] = d6 * +HEAPF32[i1 + 340 >> 2];
michael@0 46707 HEAPF32[i1 + 556 >> 2] = d11;
michael@0 46708 HEAPF32[i1 + 560 >> 2] = d10;
michael@0 46709 HEAPF32[i1 + 564 >> 2] = 0.0;
michael@0 46710 return;
michael@0 46711 }
michael@0 46712 function __ZN20btConvexHullInternalD2Ev(i1) {
michael@0 46713 i1 = i1 | 0;
michael@0 46714 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 46715 i2 = i1 + 84 | 0;
michael@0 46716 i3 = i1 + 92 | 0;
michael@0 46717 i4 = HEAP32[i3 >> 2] | 0;
michael@0 46718 i5 = i1 + 96 | 0;
michael@0 46719 if ((i4 | 0) != 0) {
michael@0 46720 if ((HEAP8[i5] | 0) != 0) {
michael@0 46721 __Z21btAlignedFreeInternalPv(i4);
michael@0 46722 }
michael@0 46723 HEAP32[i3 >> 2] = 0;
michael@0 46724 }
michael@0 46725 HEAP8[i5] = 1;
michael@0 46726 HEAP32[i3 >> 2] = 0;
michael@0 46727 HEAP32[i2 >> 2] = 0;
michael@0 46728 HEAP32[i1 + 88 >> 2] = 0;
michael@0 46729 i2 = i1 + 64 | 0;
michael@0 46730 i3 = HEAP32[i2 >> 2] | 0;
michael@0 46731 if ((i3 | 0) != 0) {
michael@0 46732 i5 = i3;
michael@0 46733 do {
michael@0 46734 HEAP32[i2 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 46735 __Z21btAlignedFreeInternalPv(HEAP32[i5 >> 2] | 0);
michael@0 46736 __Z21btAlignedFreeInternalPv(i5);
michael@0 46737 i5 = HEAP32[i2 >> 2] | 0;
michael@0 46738 } while ((i5 | 0) != 0);
michael@0 46739 }
michael@0 46740 i5 = i1 + 48 | 0;
michael@0 46741 i2 = HEAP32[i5 >> 2] | 0;
michael@0 46742 if ((i2 | 0) != 0) {
michael@0 46743 i3 = i2;
michael@0 46744 do {
michael@0 46745 HEAP32[i5 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 46746 __Z21btAlignedFreeInternalPv(HEAP32[i3 >> 2] | 0);
michael@0 46747 __Z21btAlignedFreeInternalPv(i3);
michael@0 46748 i3 = HEAP32[i5 >> 2] | 0;
michael@0 46749 } while ((i3 | 0) != 0);
michael@0 46750 }
michael@0 46751 i3 = i1 + 32 | 0;
michael@0 46752 i1 = HEAP32[i3 >> 2] | 0;
michael@0 46753 if ((i1 | 0) == 0) {
michael@0 46754 return;
michael@0 46755 } else {
michael@0 46756 i6 = i1;
michael@0 46757 }
michael@0 46758 do {
michael@0 46759 HEAP32[i3 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 46760 __Z21btAlignedFreeInternalPv(HEAP32[i6 >> 2] | 0);
michael@0 46761 __Z21btAlignedFreeInternalPv(i6);
michael@0 46762 i6 = HEAP32[i3 >> 2] | 0;
michael@0 46763 } while ((i6 | 0) != 0);
michael@0 46764 return;
michael@0 46765 }
michael@0 46766 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallback9reportHitE_0RK9btVector3fii(i1, i2, d3, i4, i5) {
michael@0 46767 i1 = i1 | 0;
michael@0 46768 i2 = i2 | 0;
michael@0 46769 d3 = +d3;
michael@0 46770 i4 = i4 | 0;
michael@0 46771 i5 = i5 | 0;
michael@0 46772 var i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0;
michael@0 46773 i6 = STACKTOP;
michael@0 46774 STACKTOP = STACKTOP + 40 | 0;
michael@0 46775 i7 = i6 | 0;
michael@0 46776 i8 = i6 + 8 | 0;
michael@0 46777 HEAP32[i7 >> 2] = i4;
michael@0 46778 HEAP32[i7 + 4 >> 2] = i5;
michael@0 46779 d9 = +HEAPF32[i2 >> 2];
michael@0 46780 d10 = +HEAPF32[i2 + 4 >> 2];
michael@0 46781 d11 = +HEAPF32[i2 + 8 >> 2];
michael@0 46782 d12 = +HEAPF32[i1 + 56 >> 2] * d9 + +HEAPF32[i1 + 60 >> 2] * d10 + +HEAPF32[i1 + 64 >> 2] * d11;
michael@0 46783 d13 = d9 * +HEAPF32[i1 + 72 >> 2] + d10 * +HEAPF32[i1 + 76 >> 2] + d11 * +HEAPF32[i1 + 80 >> 2];
michael@0 46784 d14 = d9 * +HEAPF32[i1 + 88 >> 2] + d10 * +HEAPF32[i1 + 92 >> 2] + d11 * +HEAPF32[i1 + 96 >> 2];
michael@0 46785 HEAP32[i8 >> 2] = HEAP32[i1 + 48 >> 2];
michael@0 46786 HEAP32[i8 + 4 >> 2] = i7;
michael@0 46787 HEAPF32[i8 + 8 >> 2] = d12;
michael@0 46788 HEAPF32[i8 + 12 >> 2] = d13;
michael@0 46789 HEAPF32[i8 + 16 >> 2] = d14;
michael@0 46790 HEAPF32[i8 + 20 >> 2] = 0.0;
michael@0 46791 HEAPF32[i8 + 24 >> 2] = d3;
michael@0 46792 i7 = HEAP32[i1 + 44 >> 2] | 0;
michael@0 46793 d3 = +FUNCTION_TABLE_fiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 12 >> 2] & 15](i7, i8, 1);
michael@0 46794 STACKTOP = i6;
michael@0 46795 return +d3;
michael@0 46796 }
michael@0 46797 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallback9reportHitERK9btVector3fii(i1, i2, d3, i4, i5) {
michael@0 46798 i1 = i1 | 0;
michael@0 46799 i2 = i2 | 0;
michael@0 46800 d3 = +d3;
michael@0 46801 i4 = i4 | 0;
michael@0 46802 i5 = i5 | 0;
michael@0 46803 var i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0;
michael@0 46804 i6 = STACKTOP;
michael@0 46805 STACKTOP = STACKTOP + 40 | 0;
michael@0 46806 i7 = i6 | 0;
michael@0 46807 i8 = i6 + 8 | 0;
michael@0 46808 HEAP32[i7 >> 2] = i4;
michael@0 46809 HEAP32[i7 + 4 >> 2] = i5;
michael@0 46810 d9 = +HEAPF32[i2 >> 2];
michael@0 46811 d10 = +HEAPF32[i2 + 4 >> 2];
michael@0 46812 d11 = +HEAPF32[i2 + 8 >> 2];
michael@0 46813 d12 = +HEAPF32[i1 + 56 >> 2] * d9 + +HEAPF32[i1 + 60 >> 2] * d10 + +HEAPF32[i1 + 64 >> 2] * d11;
michael@0 46814 d13 = d9 * +HEAPF32[i1 + 72 >> 2] + d10 * +HEAPF32[i1 + 76 >> 2] + d11 * +HEAPF32[i1 + 80 >> 2];
michael@0 46815 d14 = d9 * +HEAPF32[i1 + 88 >> 2] + d10 * +HEAPF32[i1 + 92 >> 2] + d11 * +HEAPF32[i1 + 96 >> 2];
michael@0 46816 HEAP32[i8 >> 2] = HEAP32[i1 + 48 >> 2];
michael@0 46817 HEAP32[i8 + 4 >> 2] = i7;
michael@0 46818 HEAPF32[i8 + 8 >> 2] = d12;
michael@0 46819 HEAPF32[i8 + 12 >> 2] = d13;
michael@0 46820 HEAPF32[i8 + 16 >> 2] = d14;
michael@0 46821 HEAPF32[i8 + 20 >> 2] = 0.0;
michael@0 46822 HEAPF32[i8 + 24 >> 2] = d3;
michael@0 46823 i7 = HEAP32[i1 + 44 >> 2] | 0;
michael@0 46824 d3 = +FUNCTION_TABLE_fiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 12 >> 2] & 15](i7, i8, 1);
michael@0 46825 STACKTOP = i6;
michael@0 46826 return +d3;
michael@0 46827 }
michael@0 46828 function __ZN31btDefaultCollisionConfiguration31getCollisionAlgorithmCreateFuncEii(i1, i2, i3) {
michael@0 46829 i1 = i1 | 0;
michael@0 46830 i2 = i2 | 0;
michael@0 46831 i3 = i3 | 0;
michael@0 46832 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 46833 i4 = (i2 | 0) == 8;
michael@0 46834 i5 = (i3 | 0) == 8;
michael@0 46835 L1262 : do {
michael@0 46836 if (i4 & i5) {
michael@0 46837 i6 = i1 + 64 | 0;
michael@0 46838 } else {
michael@0 46839 if (i4 & (i3 | 0) == 1) {
michael@0 46840 i6 = i1 + 72 | 0;
michael@0 46841 break;
michael@0 46842 }
michael@0 46843 if ((i2 | 0) == 1 & i5) {
michael@0 46844 i6 = i1 + 76 | 0;
michael@0 46845 break;
michael@0 46846 }
michael@0 46847 if ((i3 | i2 | 0) == 0) {
michael@0 46848 i6 = i1 + 68 | 0;
michael@0 46849 break;
michael@0 46850 }
michael@0 46851 i7 = (i2 | 0) < 20;
michael@0 46852 if (i7 & (i3 | 0) == 28) {
michael@0 46853 i6 = i1 + 84 | 0;
michael@0 46854 break;
michael@0 46855 }
michael@0 46856 i8 = (i3 | 0) < 20;
michael@0 46857 if (i8 & (i2 | 0) == 28) {
michael@0 46858 i6 = i1 + 80 | 0;
michael@0 46859 break;
michael@0 46860 }
michael@0 46861 do {
michael@0 46862 if (i7) {
michael@0 46863 if (i8) {
michael@0 46864 i6 = i1 + 40 | 0;
michael@0 46865 break L1262;
michael@0 46866 }
michael@0 46867 if ((i3 - 21 | 0) >>> 0 >= 9) {
michael@0 46868 break;
michael@0 46869 }
michael@0 46870 i6 = i1 + 44 | 0;
michael@0 46871 break L1262;
michael@0 46872 } else {
michael@0 46873 if (!i8) {
michael@0 46874 break;
michael@0 46875 }
michael@0 46876 if ((i2 - 21 | 0) >>> 0 >= 9) {
michael@0 46877 break;
michael@0 46878 }
michael@0 46879 i6 = i1 + 48 | 0;
michael@0 46880 break L1262;
michael@0 46881 }
michael@0 46882 } while (0);
michael@0 46883 if ((i2 | 0) == 31) {
michael@0 46884 i6 = i1 + 52 | 0;
michael@0 46885 break;
michael@0 46886 }
michael@0 46887 if ((i3 | 0) == 31) {
michael@0 46888 i6 = i1 + 56 | 0;
michael@0 46889 break;
michael@0 46890 } else {
michael@0 46891 i6 = i1 + 60 | 0;
michael@0 46892 break;
michael@0 46893 }
michael@0 46894 }
michael@0 46895 } while (0);
michael@0 46896 return HEAP32[i6 >> 2] | 0;
michael@0 46897 }
michael@0 46898 function __ZN28btHashedOverlappingPairCache8findPairEP17btBroadphaseProxyS1_(i1, i2, i3) {
michael@0 46899 i1 = i1 | 0;
michael@0 46900 i2 = i2 | 0;
michael@0 46901 i3 = i3 | 0;
michael@0 46902 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 46903 HEAP32[3002] = (HEAP32[3002] | 0) + 1;
michael@0 46904 i4 = (HEAP32[i2 + 12 >> 2] | 0) > (HEAP32[i3 + 12 >> 2] | 0);
michael@0 46905 i5 = HEAP32[(i4 ? i3 : i2) + 12 >> 2] | 0;
michael@0 46906 i6 = HEAP32[(i4 ? i2 : i3) + 12 >> 2] | 0;
michael@0 46907 i3 = i6 << 16 | i5;
michael@0 46908 i2 = i3 + ~(i3 << 15) | 0;
michael@0 46909 i3 = (i2 >> 10 ^ i2) * 9 | 0;
michael@0 46910 i2 = i3 >> 6 ^ i3;
michael@0 46911 i3 = i2 + ~(i2 << 11) | 0;
michael@0 46912 i2 = (i3 >> 16 ^ i3) & (HEAP32[i1 + 12 >> 2] | 0) - 1;
michael@0 46913 if ((i2 | 0) >= (HEAP32[i1 + 36 >> 2] | 0)) {
michael@0 46914 i7 = 0;
michael@0 46915 return i7 | 0;
michael@0 46916 }
michael@0 46917 i3 = HEAP32[(HEAP32[i1 + 44 >> 2] | 0) + (i2 << 2) >> 2] | 0;
michael@0 46918 if ((i3 | 0) == -1) {
michael@0 46919 i7 = 0;
michael@0 46920 return i7 | 0;
michael@0 46921 }
michael@0 46922 i2 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 46923 i4 = i1 + 64 | 0;
michael@0 46924 i1 = i3;
michael@0 46925 while (1) {
michael@0 46926 if ((HEAP32[(HEAP32[i2 + (i1 << 4) >> 2] | 0) + 12 >> 2] | 0) == (i5 | 0)) {
michael@0 46927 if ((HEAP32[(HEAP32[i2 + (i1 << 4) + 4 >> 2] | 0) + 12 >> 2] | 0) == (i6 | 0)) {
michael@0 46928 break;
michael@0 46929 }
michael@0 46930 }
michael@0 46931 i3 = HEAP32[(HEAP32[i4 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 46932 if ((i3 | 0) == -1) {
michael@0 46933 i7 = 0;
michael@0 46934 i8 = 1441;
michael@0 46935 break;
michael@0 46936 } else {
michael@0 46937 i1 = i3;
michael@0 46938 }
michael@0 46939 }
michael@0 46940 if ((i8 | 0) == 1441) {
michael@0 46941 return i7 | 0;
michael@0 46942 }
michael@0 46943 i7 = i2 + (i1 << 4) | 0;
michael@0 46944 return i7 | 0;
michael@0 46945 }
michael@0 46946 function __ZNK21btConeTwistConstraint16GetPointForAngleEff(i1, i2, d3, d4) {
michael@0 46947 i1 = i1 | 0;
michael@0 46948 i2 = i2 | 0;
michael@0 46949 d3 = +d3;
michael@0 46950 d4 = +d4;
michael@0 46951 var d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0;
michael@0 46952 d5 = +Math_cos(+d3);
michael@0 46953 d6 = +Math_sin(+d3);
michael@0 46954 d3 = +HEAPF32[i2 + 436 >> 2];
michael@0 46955 if (+Math_abs(+d5) > 1.1920928955078125e-7) {
michael@0 46956 d7 = d6 * d6;
michael@0 46957 d8 = d5 * d5;
michael@0 46958 d9 = d7 / d8;
michael@0 46959 d10 = +HEAPF32[i2 + 440 >> 2];
michael@0 46960 d11 = +Math_sqrt(+((d9 + 1.0) / (1.0 / (d10 * d10) + d9 / (d3 * d3))));
michael@0 46961 d12 = d8;
michael@0 46962 d13 = d7;
michael@0 46963 } else {
michael@0 46964 d11 = d3;
michael@0 46965 d12 = d5 * d5;
michael@0 46966 d13 = d6 * d6;
michael@0 46967 }
michael@0 46968 d3 = +Math_sqrt(+(d13 + (d12 + 0.0)));
michael@0 46969 d12 = d11 * .5;
michael@0 46970 d11 = +Math_sin(+d12) / d3;
michael@0 46971 d3 = d11 * 0.0;
michael@0 46972 d13 = d5 * d11;
michael@0 46973 d5 = d11 * (-0.0 - d6);
michael@0 46974 d6 = +Math_cos(+d12);
michael@0 46975 d12 = d13 * 0.0;
michael@0 46976 d11 = d5 * 0.0;
michael@0 46977 d7 = d6 * d4 + d12 - d11;
michael@0 46978 d8 = d6 * 0.0;
michael@0 46979 d9 = d3 * 0.0;
michael@0 46980 d10 = d5 * d4 + d8 - d9;
michael@0 46981 d14 = d8 + d9 - d13 * d4;
michael@0 46982 d9 = -0.0 - d3;
michael@0 46983 d3 = d4 * d9 - d12 - d11;
michael@0 46984 d11 = -0.0 - d13;
michael@0 46985 d13 = -0.0 - d5;
michael@0 46986 HEAPF32[i1 >> 2] = d10 * d13 + (d6 * d7 + d3 * d9) - d14 * d11;
michael@0 46987 HEAPF32[i1 + 4 >> 2] = d14 * d9 + (d6 * d10 + d3 * d11) - d7 * d13;
michael@0 46988 HEAPF32[i1 + 8 >> 2] = d7 * d11 + (d6 * d14 + d3 * d13) - d10 * d9;
michael@0 46989 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 46990 return;
michael@0 46991 }
michael@0 46992 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallback9reportHitE_0RK9btVector3SG_fii(i1, i2, i3, d4, i5, i6) {
michael@0 46993 i1 = i1 | 0;
michael@0 46994 i2 = i2 | 0;
michael@0 46995 i3 = i3 | 0;
michael@0 46996 d4 = +d4;
michael@0 46997 i5 = i5 | 0;
michael@0 46998 i6 = i6 | 0;
michael@0 46999 var i7 = 0, i8 = 0, i9 = 0, d10 = 0.0;
michael@0 47000 i7 = STACKTOP;
michael@0 47001 STACKTOP = STACKTOP + 56 | 0;
michael@0 47002 i8 = i7 | 0;
michael@0 47003 i9 = i7 + 8 | 0;
michael@0 47004 HEAP32[i8 >> 2] = i5;
michael@0 47005 HEAP32[i8 + 4 >> 2] = i6;
michael@0 47006 i6 = HEAP32[i1 + 212 >> 2] | 0;
michael@0 47007 if (+HEAPF32[i6 + 4 >> 2] < d4) {
michael@0 47008 d10 = d4;
michael@0 47009 STACKTOP = i7;
michael@0 47010 return +d10;
michael@0 47011 }
michael@0 47012 HEAP32[i9 >> 2] = HEAP32[i1 + 216 >> 2];
michael@0 47013 HEAP32[i9 + 4 >> 2] = i8;
michael@0 47014 i8 = i9 + 8 | 0;
michael@0 47015 i1 = i2;
michael@0 47016 HEAP32[i8 >> 2] = HEAP32[i1 >> 2];
michael@0 47017 HEAP32[i8 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 47018 HEAP32[i8 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 47019 HEAP32[i8 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 47020 i1 = i9 + 24 | 0;
michael@0 47021 i8 = i3;
michael@0 47022 HEAP32[i1 >> 2] = HEAP32[i8 >> 2];
michael@0 47023 HEAP32[i1 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 47024 HEAP32[i1 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 47025 HEAP32[i1 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 47026 HEAPF32[i9 + 40 >> 2] = d4;
michael@0 47027 d10 = +FUNCTION_TABLE_fiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 12 >> 2] & 15](i6, i9, 0);
michael@0 47028 STACKTOP = i7;
michael@0 47029 return +d10;
michael@0 47030 }
michael@0 47031 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallback9reportHitERK9btVector3SG_fii(i1, i2, i3, d4, i5, i6) {
michael@0 47032 i1 = i1 | 0;
michael@0 47033 i2 = i2 | 0;
michael@0 47034 i3 = i3 | 0;
michael@0 47035 d4 = +d4;
michael@0 47036 i5 = i5 | 0;
michael@0 47037 i6 = i6 | 0;
michael@0 47038 var i7 = 0, i8 = 0, i9 = 0, d10 = 0.0;
michael@0 47039 i7 = STACKTOP;
michael@0 47040 STACKTOP = STACKTOP + 56 | 0;
michael@0 47041 i8 = i7 | 0;
michael@0 47042 i9 = i7 + 8 | 0;
michael@0 47043 HEAP32[i8 >> 2] = i5;
michael@0 47044 HEAP32[i8 + 4 >> 2] = i6;
michael@0 47045 i6 = HEAP32[i1 + 212 >> 2] | 0;
michael@0 47046 if (+HEAPF32[i6 + 4 >> 2] < d4) {
michael@0 47047 d10 = d4;
michael@0 47048 STACKTOP = i7;
michael@0 47049 return +d10;
michael@0 47050 }
michael@0 47051 HEAP32[i9 >> 2] = HEAP32[i1 + 216 >> 2];
michael@0 47052 HEAP32[i9 + 4 >> 2] = i8;
michael@0 47053 i8 = i9 + 8 | 0;
michael@0 47054 i1 = i2;
michael@0 47055 HEAP32[i8 >> 2] = HEAP32[i1 >> 2];
michael@0 47056 HEAP32[i8 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 47057 HEAP32[i8 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 47058 HEAP32[i8 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 47059 i1 = i9 + 24 | 0;
michael@0 47060 i8 = i3;
michael@0 47061 HEAP32[i1 >> 2] = HEAP32[i8 >> 2];
michael@0 47062 HEAP32[i1 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 47063 HEAP32[i1 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 47064 HEAP32[i1 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 47065 HEAPF32[i9 + 40 >> 2] = d4;
michael@0 47066 d10 = +FUNCTION_TABLE_fiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 12 >> 2] & 15](i6, i9, 1);
michael@0 47067 STACKTOP = i7;
michael@0 47068 return +d10;
michael@0 47069 }
michael@0 47070 function __ZNK10btBoxShape16getPlaneEquationER9btVector4i(i1, i2, i3) {
michael@0 47071 i1 = i1 | 0;
michael@0 47072 i2 = i2 | 0;
michael@0 47073 i3 = i3 | 0;
michael@0 47074 var d4 = 0.0, d5 = 0.0, d6 = 0.0;
michael@0 47075 d4 = +HEAPF32[i1 + 28 >> 2];
michael@0 47076 d5 = +HEAPF32[i1 + 32 >> 2];
michael@0 47077 d6 = +HEAPF32[i1 + 36 >> 2];
michael@0 47078 switch (i3 | 0) {
michael@0 47079 case 5:
michael@0 47080 {
michael@0 47081 HEAPF32[i2 >> 2] = 0.0;
michael@0 47082 HEAPF32[i2 + 4 >> 2] = 0.0;
michael@0 47083 HEAPF32[i2 + 8 >> 2] = -1.0;
michael@0 47084 HEAPF32[i2 + 12 >> 2] = -0.0 - d6;
michael@0 47085 return;
michael@0 47086 }
michael@0 47087 case 3:
michael@0 47088 {
michael@0 47089 HEAPF32[i2 >> 2] = 0.0;
michael@0 47090 HEAPF32[i2 + 4 >> 2] = -1.0;
michael@0 47091 HEAPF32[i2 + 8 >> 2] = 0.0;
michael@0 47092 HEAPF32[i2 + 12 >> 2] = -0.0 - d5;
michael@0 47093 return;
michael@0 47094 }
michael@0 47095 case 0:
michael@0 47096 {
michael@0 47097 HEAPF32[i2 >> 2] = 1.0;
michael@0 47098 HEAPF32[i2 + 4 >> 2] = 0.0;
michael@0 47099 HEAPF32[i2 + 8 >> 2] = 0.0;
michael@0 47100 HEAPF32[i2 + 12 >> 2] = -0.0 - d4;
michael@0 47101 return;
michael@0 47102 }
michael@0 47103 case 1:
michael@0 47104 {
michael@0 47105 HEAPF32[i2 >> 2] = -1.0;
michael@0 47106 HEAPF32[i2 + 4 >> 2] = 0.0;
michael@0 47107 HEAPF32[i2 + 8 >> 2] = 0.0;
michael@0 47108 HEAPF32[i2 + 12 >> 2] = -0.0 - d4;
michael@0 47109 return;
michael@0 47110 }
michael@0 47111 case 2:
michael@0 47112 {
michael@0 47113 HEAPF32[i2 >> 2] = 0.0;
michael@0 47114 HEAPF32[i2 + 4 >> 2] = 1.0;
michael@0 47115 HEAPF32[i2 + 8 >> 2] = 0.0;
michael@0 47116 HEAPF32[i2 + 12 >> 2] = -0.0 - d5;
michael@0 47117 return;
michael@0 47118 }
michael@0 47119 case 4:
michael@0 47120 {
michael@0 47121 HEAPF32[i2 >> 2] = 0.0;
michael@0 47122 HEAPF32[i2 + 4 >> 2] = 0.0;
michael@0 47123 HEAPF32[i2 + 8 >> 2] = 1.0;
michael@0 47124 HEAPF32[i2 + 12 >> 2] = -0.0 - d6;
michael@0 47125 return;
michael@0 47126 }
michael@0 47127 default:
michael@0 47128 {
michael@0 47129 return;
michael@0 47130 }
michael@0 47131 }
michael@0 47132 }
michael@0 47133 function __ZN21btCollisionDispatcher19defaultNearCallbackER16btBroadphasePairRS_RK16btDispatcherInfo(i1, i2, i3) {
michael@0 47134 i1 = i1 | 0;
michael@0 47135 i2 = i2 | 0;
michael@0 47136 i3 = i3 | 0;
michael@0 47137 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, d9 = 0.0;
michael@0 47138 i4 = STACKTOP;
michael@0 47139 STACKTOP = STACKTOP + 160 | 0;
michael@0 47140 i5 = i4 | 0;
michael@0 47141 i6 = HEAP32[HEAP32[i1 >> 2] >> 2] | 0;
michael@0 47142 i7 = HEAP32[HEAP32[i1 + 4 >> 2] >> 2] | 0;
michael@0 47143 if (!(FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 24 >> 2] & 31](i2, i6, i7) | 0)) {
michael@0 47144 STACKTOP = i4;
michael@0 47145 return;
michael@0 47146 }
michael@0 47147 i8 = i1 + 8 | 0;
michael@0 47148 do {
michael@0 47149 if ((HEAP32[i8 >> 2] | 0) == 0) {
michael@0 47150 i1 = FUNCTION_TABLE_iiiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 8 >> 2] & 31](i2, i6, i7, 0) | 0;
michael@0 47151 HEAP32[i8 >> 2] = i1;
michael@0 47152 if ((i1 | 0) != 0) {
michael@0 47153 break;
michael@0 47154 }
michael@0 47155 STACKTOP = i4;
michael@0 47156 return;
michael@0 47157 }
michael@0 47158 } while (0);
michael@0 47159 __ZN16btManifoldResultC2EP17btCollisionObjectS1_(i5, i6, i7);
michael@0 47160 i2 = HEAP32[i8 >> 2] | 0;
michael@0 47161 if ((HEAP32[i3 + 8 >> 2] | 0) == 1) {
michael@0 47162 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 8 >> 2] & 63](i2, i6, i7, i3, i5);
michael@0 47163 STACKTOP = i4;
michael@0 47164 return;
michael@0 47165 }
michael@0 47166 d9 = +FUNCTION_TABLE_fiiiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 12 >> 2] & 31](i2, i6, i7, i3, i5);
michael@0 47167 i5 = i3 + 12 | 0;
michael@0 47168 if (+HEAPF32[i5 >> 2] <= d9) {
michael@0 47169 STACKTOP = i4;
michael@0 47170 return;
michael@0 47171 }
michael@0 47172 HEAPF32[i5 >> 2] = d9;
michael@0 47173 STACKTOP = i4;
michael@0 47174 return;
michael@0 47175 }
michael@0 47176 function __ZN18btConvexPolyhedronD2Ev(i1) {
michael@0 47177 i1 = i1 | 0;
michael@0 47178 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 47179 HEAP32[i1 >> 2] = 4112;
michael@0 47180 i2 = i1 + 48 | 0;
michael@0 47181 i3 = i1 + 56 | 0;
michael@0 47182 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47183 i5 = i1 + 60 | 0;
michael@0 47184 if ((i4 | 0) != 0) {
michael@0 47185 if ((HEAP8[i5] | 0) != 0) {
michael@0 47186 __Z21btAlignedFreeInternalPv(i4);
michael@0 47187 }
michael@0 47188 HEAP32[i3 >> 2] = 0;
michael@0 47189 }
michael@0 47190 HEAP8[i5] = 1;
michael@0 47191 HEAP32[i3 >> 2] = 0;
michael@0 47192 HEAP32[i2 >> 2] = 0;
michael@0 47193 HEAP32[i1 + 52 >> 2] = 0;
michael@0 47194 i2 = i1 + 28 | 0;
michael@0 47195 __ZN20btAlignedObjectArrayI6btFaceE7destroyEii(i1 + 24 | 0, 0, HEAP32[i2 >> 2] | 0);
michael@0 47196 i3 = i1 + 36 | 0;
michael@0 47197 i5 = HEAP32[i3 >> 2] | 0;
michael@0 47198 i4 = i1 + 40 | 0;
michael@0 47199 if ((i5 | 0) != 0) {
michael@0 47200 if ((HEAP8[i4] | 0) != 0) {
michael@0 47201 __Z21btAlignedFreeInternalPv(i5 | 0);
michael@0 47202 }
michael@0 47203 HEAP32[i3 >> 2] = 0;
michael@0 47204 }
michael@0 47205 HEAP8[i4] = 1;
michael@0 47206 HEAP32[i3 >> 2] = 0;
michael@0 47207 HEAP32[i2 >> 2] = 0;
michael@0 47208 HEAP32[i1 + 32 >> 2] = 0;
michael@0 47209 i2 = i1 + 8 | 0;
michael@0 47210 i3 = i1 + 16 | 0;
michael@0 47211 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47212 i5 = i1 + 20 | 0;
michael@0 47213 if ((i4 | 0) == 0) {
michael@0 47214 HEAP8[i5] = 1;
michael@0 47215 HEAP32[i3 >> 2] = 0;
michael@0 47216 HEAP32[i2 >> 2] = 0;
michael@0 47217 i6 = i1 + 12 | 0;
michael@0 47218 HEAP32[i6 >> 2] = 0;
michael@0 47219 return;
michael@0 47220 }
michael@0 47221 if ((HEAP8[i5] | 0) != 0) {
michael@0 47222 __Z21btAlignedFreeInternalPv(i4);
michael@0 47223 }
michael@0 47224 HEAP32[i3 >> 2] = 0;
michael@0 47225 HEAP8[i5] = 1;
michael@0 47226 HEAP32[i3 >> 2] = 0;
michael@0 47227 HEAP32[i2 >> 2] = 0;
michael@0 47228 i6 = i1 + 12 | 0;
michael@0 47229 HEAP32[i6 >> 2] = 0;
michael@0 47230 return;
michael@0 47231 }
michael@0 47232 function __ZN22btVoronoiSimplexSolver9inSimplexERK9btVector3(i1, i2) {
michael@0 47233 i1 = i1 | 0;
michael@0 47234 i2 = i2 | 0;
michael@0 47235 var i3 = 0, d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, i8 = 0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, i13 = 0, i14 = 0, i15 = 0, i16 = 0, i17 = 0;
michael@0 47236 i3 = HEAP32[i1 >> 2] | 0;
michael@0 47237 if ((i3 | 0) > 0) {
michael@0 47238 d4 = +HEAPF32[i2 >> 2];
michael@0 47239 d5 = +HEAPF32[i2 + 4 >> 2];
michael@0 47240 d6 = +HEAPF32[i2 + 8 >> 2];
michael@0 47241 d7 = +HEAPF32[i1 + 308 >> 2];
michael@0 47242 i8 = 0;
michael@0 47243 i9 = 0;
michael@0 47244 while (1) {
michael@0 47245 d10 = d4 - +HEAPF32[i1 + 4 + (i9 << 4) >> 2];
michael@0 47246 d11 = d5 - +HEAPF32[i1 + 4 + (i9 << 4) + 4 >> 2];
michael@0 47247 d12 = d6 - +HEAPF32[i1 + 4 + (i9 << 4) + 8 >> 2];
michael@0 47248 i13 = i8 | d10 * d10 + d11 * d11 + d12 * d12 <= d7;
michael@0 47249 i14 = i9 + 1 | 0;
michael@0 47250 if ((i14 | 0) < (i3 | 0)) {
michael@0 47251 i8 = i13;
michael@0 47252 i9 = i14;
michael@0 47253 } else {
michael@0 47254 i15 = i13;
michael@0 47255 break;
michael@0 47256 }
michael@0 47257 }
michael@0 47258 } else {
michael@0 47259 i15 = 0;
michael@0 47260 }
michael@0 47261 if (+HEAPF32[i2 + 12 >> 2] != +HEAPF32[i1 + 304 >> 2]) {
michael@0 47262 i16 = 0;
michael@0 47263 i17 = i16 | i15;
michael@0 47264 return i17 | 0;
michael@0 47265 }
michael@0 47266 if (+HEAPF32[i2 + 8 >> 2] != +HEAPF32[i1 + 300 >> 2]) {
michael@0 47267 i16 = 0;
michael@0 47268 i17 = i16 | i15;
michael@0 47269 return i17 | 0;
michael@0 47270 }
michael@0 47271 if (+HEAPF32[i2 + 4 >> 2] != +HEAPF32[i1 + 296 >> 2]) {
michael@0 47272 i16 = 0;
michael@0 47273 i17 = i16 | i15;
michael@0 47274 return i17 | 0;
michael@0 47275 }
michael@0 47276 i16 = +HEAPF32[i2 >> 2] == +HEAPF32[i1 + 292 >> 2];
michael@0 47277 i17 = i16 | i15;
michael@0 47278 return i17 | 0;
michael@0 47279 }
michael@0 47280 function __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallbackD2Ev(i1) {
michael@0 47281 i1 = i1 | 0;
michael@0 47282 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 47283 HEAP32[i1 >> 2] = 1520;
michael@0 47284 i2 = i1 + 76 | 0;
michael@0 47285 i3 = i1 + 84 | 0;
michael@0 47286 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47287 i5 = i1 + 88 | 0;
michael@0 47288 if ((i4 | 0) != 0) {
michael@0 47289 if ((HEAP8[i5] | 0) != 0) {
michael@0 47290 __Z21btAlignedFreeInternalPv(i4);
michael@0 47291 }
michael@0 47292 HEAP32[i3 >> 2] = 0;
michael@0 47293 }
michael@0 47294 HEAP8[i5] = 1;
michael@0 47295 HEAP32[i3 >> 2] = 0;
michael@0 47296 HEAP32[i2 >> 2] = 0;
michael@0 47297 HEAP32[i1 + 80 >> 2] = 0;
michael@0 47298 i2 = i1 + 56 | 0;
michael@0 47299 i3 = i1 + 64 | 0;
michael@0 47300 i5 = HEAP32[i3 >> 2] | 0;
michael@0 47301 i4 = i1 + 68 | 0;
michael@0 47302 if ((i5 | 0) != 0) {
michael@0 47303 if ((HEAP8[i4] | 0) != 0) {
michael@0 47304 __Z21btAlignedFreeInternalPv(i5);
michael@0 47305 }
michael@0 47306 HEAP32[i3 >> 2] = 0;
michael@0 47307 }
michael@0 47308 HEAP8[i4] = 1;
michael@0 47309 HEAP32[i3 >> 2] = 0;
michael@0 47310 HEAP32[i2 >> 2] = 0;
michael@0 47311 HEAP32[i1 + 60 >> 2] = 0;
michael@0 47312 i2 = i1 + 36 | 0;
michael@0 47313 i3 = i1 + 44 | 0;
michael@0 47314 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47315 i5 = i1 + 48 | 0;
michael@0 47316 if ((i4 | 0) == 0) {
michael@0 47317 HEAP8[i5] = 1;
michael@0 47318 HEAP32[i3 >> 2] = 0;
michael@0 47319 HEAP32[i2 >> 2] = 0;
michael@0 47320 i6 = i1 + 40 | 0;
michael@0 47321 HEAP32[i6 >> 2] = 0;
michael@0 47322 return;
michael@0 47323 }
michael@0 47324 if ((HEAP8[i5] | 0) != 0) {
michael@0 47325 __Z21btAlignedFreeInternalPv(i4);
michael@0 47326 }
michael@0 47327 HEAP32[i3 >> 2] = 0;
michael@0 47328 HEAP8[i5] = 1;
michael@0 47329 HEAP32[i3 >> 2] = 0;
michael@0 47330 HEAP32[i2 >> 2] = 0;
michael@0 47331 i6 = i1 + 40 | 0;
michael@0 47332 HEAP32[i6 >> 2] = 0;
michael@0 47333 return;
michael@0 47334 }
michael@0 47335 function __ZN21btCollisionDispatcher15releaseManifoldEP20btPersistentManifold(i1, i2) {
michael@0 47336 i1 = i1 | 0;
michael@0 47337 i2 = i2 | 0;
michael@0 47338 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 47339 HEAP32[2990] = (HEAP32[2990] | 0) - 1;
michael@0 47340 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 20 >> 2] & 127](i1, i2);
michael@0 47341 i3 = HEAP32[i2 + 1136 >> 2] | 0;
michael@0 47342 i4 = i1 + 12 | 0;
michael@0 47343 i5 = (HEAP32[i4 >> 2] | 0) - 1 | 0;
michael@0 47344 i6 = i1 + 20 | 0;
michael@0 47345 i7 = HEAP32[i6 >> 2] | 0;
michael@0 47346 i8 = i7 + (i3 << 2) | 0;
michael@0 47347 i9 = HEAP32[i8 >> 2] | 0;
michael@0 47348 HEAP32[i8 >> 2] = HEAP32[i7 + (i5 << 2) >> 2];
michael@0 47349 HEAP32[(HEAP32[i6 >> 2] | 0) + (i5 << 2) >> 2] = i9;
michael@0 47350 HEAP32[(HEAP32[(HEAP32[i6 >> 2] | 0) + (i3 << 2) >> 2] | 0) + 1136 >> 2] = i3;
michael@0 47351 HEAP32[i4 >> 2] = (HEAP32[i4 >> 2] | 0) - 1;
michael@0 47352 i4 = HEAP32[i1 + 196 >> 2] | 0;
michael@0 47353 i1 = i2;
michael@0 47354 do {
michael@0 47355 if ((i2 | 0) != 0) {
michael@0 47356 i3 = HEAP32[i4 + 16 >> 2] | 0;
michael@0 47357 if (i3 >>> 0 > i1 >>> 0) {
michael@0 47358 break;
michael@0 47359 }
michael@0 47360 if ((i3 + (Math_imul(HEAP32[i4 >> 2] | 0, HEAP32[i4 + 4 >> 2] | 0) | 0) | 0) >>> 0 <= i1 >>> 0) {
michael@0 47361 break;
michael@0 47362 }
michael@0 47363 i3 = i4 + 12 | 0;
michael@0 47364 HEAP32[i2 >> 2] = HEAP32[i3 >> 2];
michael@0 47365 HEAP32[i3 >> 2] = i1;
michael@0 47366 i3 = i4 + 8 | 0;
michael@0 47367 HEAP32[i3 >> 2] = (HEAP32[i3 >> 2] | 0) + 1;
michael@0 47368 return;
michael@0 47369 }
michael@0 47370 } while (0);
michael@0 47371 __Z21btAlignedFreeInternalPv(i1);
michael@0 47372 return;
michael@0 47373 }
michael@0 47374 function __ZN11btUnionFind11sortIslandsEv(i1) {
michael@0 47375 i1 = i1 | 0;
michael@0 47376 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0, i14 = 0, i15 = 0;
michael@0 47377 i2 = STACKTOP;
michael@0 47378 STACKTOP = STACKTOP + 8 | 0;
michael@0 47379 i3 = i2 | 0;
michael@0 47380 i4 = i1 | 0;
michael@0 47381 i5 = i1 + 4 | 0;
michael@0 47382 i6 = HEAP32[i5 >> 2] | 0;
michael@0 47383 if ((i6 | 0) <= 0) {
michael@0 47384 i7 = i3 | 0;
michael@0 47385 STACKTOP = i2;
michael@0 47386 return;
michael@0 47387 }
michael@0 47388 i8 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 47389 i1 = 0;
michael@0 47390 do {
michael@0 47391 i9 = i8 + (i1 << 3) | 0;
michael@0 47392 i10 = HEAP32[i9 >> 2] | 0;
michael@0 47393 if ((i10 | 0) == (i1 | 0)) {
michael@0 47394 i11 = i1;
michael@0 47395 } else {
michael@0 47396 i12 = i9;
michael@0 47397 i13 = i10;
michael@0 47398 while (1) {
michael@0 47399 i10 = i8 + (i13 << 3) | 0;
michael@0 47400 HEAP32[i12 >> 2] = HEAP32[i10 >> 2];
michael@0 47401 i14 = HEAP32[i10 >> 2] | 0;
michael@0 47402 i10 = i8 + (i14 << 3) | 0;
michael@0 47403 i15 = HEAP32[i10 >> 2] | 0;
michael@0 47404 if ((i14 | 0) == (i15 | 0)) {
michael@0 47405 i11 = i14;
michael@0 47406 break;
michael@0 47407 } else {
michael@0 47408 i12 = i10;
michael@0 47409 i13 = i15;
michael@0 47410 }
michael@0 47411 }
michael@0 47412 }
michael@0 47413 HEAP32[i9 >> 2] = i11;
michael@0 47414 i1 = i1 + 1 | 0;
michael@0 47415 } while ((i1 | 0) < (i6 | 0));
michael@0 47416 i6 = HEAP32[i5 >> 2] | 0;
michael@0 47417 i5 = i3 | 0;
michael@0 47418 if ((i6 | 0) <= 1) {
michael@0 47419 i7 = i5;
michael@0 47420 STACKTOP = i2;
michael@0 47421 return;
michael@0 47422 }
michael@0 47423 __ZN20btAlignedObjectArrayI9btElementE17quickSortInternalI31btUnionFindElementSortPredicateEEvT_ii(i4, i3, 0, i6 - 1 | 0);
michael@0 47424 i7 = i5;
michael@0 47425 STACKTOP = i2;
michael@0 47426 return;
michael@0 47427 }
michael@0 47428 function __Z24applyAnisotropicFrictionP17btCollisionObjectR9btVector3(i1, i2) {
michael@0 47429 i1 = i1 | 0;
michael@0 47430 i2 = i2 | 0;
michael@0 47431 var d3 = 0.0, i4 = 0, d5 = 0.0, d6 = 0.0, i7 = 0, d8 = 0.0, d9 = 0.0, i10 = 0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0, d17 = 0.0, d18 = 0.0, d19 = 0.0, d20 = 0.0;
michael@0 47432 if ((i1 | 0) == 0) {
michael@0 47433 return;
michael@0 47434 }
michael@0 47435 if ((HEAP32[i1 + 180 >> 2] | 0) == 0) {
michael@0 47436 return;
michael@0 47437 }
michael@0 47438 d3 = +HEAPF32[i1 + 4 >> 2];
michael@0 47439 i4 = i2 | 0;
michael@0 47440 d5 = +HEAPF32[i4 >> 2];
michael@0 47441 d6 = +HEAPF32[i1 + 20 >> 2];
michael@0 47442 i7 = i2 + 4 | 0;
michael@0 47443 d8 = +HEAPF32[i7 >> 2];
michael@0 47444 d9 = +HEAPF32[i1 + 36 >> 2];
michael@0 47445 i10 = i2 + 8 | 0;
michael@0 47446 d11 = +HEAPF32[i10 >> 2];
michael@0 47447 d12 = +HEAPF32[i1 + 8 >> 2];
michael@0 47448 d13 = +HEAPF32[i1 + 24 >> 2];
michael@0 47449 d14 = +HEAPF32[i1 + 40 >> 2];
michael@0 47450 d15 = +HEAPF32[i1 + 12 >> 2];
michael@0 47451 d16 = +HEAPF32[i1 + 28 >> 2];
michael@0 47452 d17 = +HEAPF32[i1 + 44 >> 2];
michael@0 47453 d18 = (d3 * d5 + d6 * d8 + d9 * d11) * +HEAPF32[i1 + 164 >> 2];
michael@0 47454 d19 = (d5 * d12 + d8 * d13 + d11 * d14) * +HEAPF32[i1 + 168 >> 2];
michael@0 47455 d20 = (d5 * d15 + d8 * d16 + d11 * d17) * +HEAPF32[i1 + 172 >> 2];
michael@0 47456 HEAPF32[i4 >> 2] = d3 * d18 + d12 * d19 + d15 * d20;
michael@0 47457 HEAPF32[i7 >> 2] = d6 * d18 + d13 * d19 + d16 * d20;
michael@0 47458 HEAPF32[i10 >> 2] = d9 * d18 + d14 * d19 + d17 * d20;
michael@0 47459 HEAPF32[i2 + 12 >> 2] = 0.0;
michael@0 47460 return;
michael@0 47461 }
michael@0 47462 function __ZNK10__cxxabiv120__si_class_type_info16search_above_dstEPNS_19__dynamic_cast_infoEPKvS4_ib(i1, i2, i3, i4, i5, i6) {
michael@0 47463 i1 = i1 | 0;
michael@0 47464 i2 = i2 | 0;
michael@0 47465 i3 = i3 | 0;
michael@0 47466 i4 = i4 | 0;
michael@0 47467 i5 = i5 | 0;
michael@0 47468 i6 = i6 | 0;
michael@0 47469 var i7 = 0, i8 = 0;
michael@0 47470 if ((i1 | 0) != (HEAP32[i2 + 8 >> 2] | 0)) {
michael@0 47471 i7 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 47472 FUNCTION_TABLE_viiiiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 20 >> 2] & 15](i7, i2, i3, i4, i5, i6);
michael@0 47473 return;
michael@0 47474 }
michael@0 47475 HEAP8[i2 + 53 | 0] = 1;
michael@0 47476 if ((HEAP32[i2 + 4 >> 2] | 0) != (i4 | 0)) {
michael@0 47477 return;
michael@0 47478 }
michael@0 47479 HEAP8[i2 + 52 | 0] = 1;
michael@0 47480 i4 = i2 + 16 | 0;
michael@0 47481 i6 = HEAP32[i4 >> 2] | 0;
michael@0 47482 if ((i6 | 0) == 0) {
michael@0 47483 HEAP32[i4 >> 2] = i3;
michael@0 47484 HEAP32[i2 + 24 >> 2] = i5;
michael@0 47485 HEAP32[i2 + 36 >> 2] = 1;
michael@0 47486 if (!((HEAP32[i2 + 48 >> 2] | 0) == 1 & (i5 | 0) == 1)) {
michael@0 47487 return;
michael@0 47488 }
michael@0 47489 HEAP8[i2 + 54 | 0] = 1;
michael@0 47490 return;
michael@0 47491 }
michael@0 47492 if ((i6 | 0) != (i3 | 0)) {
michael@0 47493 i3 = i2 + 36 | 0;
michael@0 47494 HEAP32[i3 >> 2] = (HEAP32[i3 >> 2] | 0) + 1;
michael@0 47495 HEAP8[i2 + 54 | 0] = 1;
michael@0 47496 return;
michael@0 47497 }
michael@0 47498 i3 = i2 + 24 | 0;
michael@0 47499 i6 = HEAP32[i3 >> 2] | 0;
michael@0 47500 if ((i6 | 0) == 2) {
michael@0 47501 HEAP32[i3 >> 2] = i5;
michael@0 47502 i8 = i5;
michael@0 47503 } else {
michael@0 47504 i8 = i6;
michael@0 47505 }
michael@0 47506 if (!((HEAP32[i2 + 48 >> 2] | 0) == 1 & (i8 | 0) == 1)) {
michael@0 47507 return;
michael@0 47508 }
michael@0 47509 HEAP8[i2 + 54 | 0] = 1;
michael@0 47510 return;
michael@0 47511 }
michael@0 47512 function __ZN28btCompoundCollisionAlgorithmD2Ev(i1) {
michael@0 47513 i1 = i1 | 0;
michael@0 47514 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 47515 HEAP32[i1 >> 2] = 2888;
michael@0 47516 i2 = i1 + 12 | 0;
michael@0 47517 i3 = HEAP32[i2 >> 2] | 0;
michael@0 47518 i4 = i1 + 20 | 0;
michael@0 47519 if ((i3 | 0) > 0) {
michael@0 47520 i5 = i1 + 4 | 0;
michael@0 47521 i6 = 0;
michael@0 47522 do {
michael@0 47523 i7 = HEAP32[(HEAP32[i4 >> 2] | 0) + (i6 << 2) >> 2] | 0;
michael@0 47524 if ((i7 | 0) != 0) {
michael@0 47525 FUNCTION_TABLE_vi[HEAP32[HEAP32[i7 >> 2] >> 2] & 511](i7);
michael@0 47526 i7 = HEAP32[i5 >> 2] | 0;
michael@0 47527 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i7 >> 2] | 0) + 60 >> 2] & 127](i7, HEAP32[(HEAP32[i4 >> 2] | 0) + (i6 << 2) >> 2] | 0);
michael@0 47528 }
michael@0 47529 i6 = i6 + 1 | 0;
michael@0 47530 } while ((i6 | 0) < (i3 | 0));
michael@0 47531 }
michael@0 47532 i3 = HEAP32[i4 >> 2] | 0;
michael@0 47533 i6 = i1 + 24 | 0;
michael@0 47534 if ((i3 | 0) == 0) {
michael@0 47535 HEAP8[i6] = 1;
michael@0 47536 HEAP32[i4 >> 2] = 0;
michael@0 47537 HEAP32[i2 >> 2] = 0;
michael@0 47538 i8 = i1 + 16 | 0;
michael@0 47539 HEAP32[i8 >> 2] = 0;
michael@0 47540 i9 = i1 | 0;
michael@0 47541 __ZN30btActivatingCollisionAlgorithmD2Ev(i9);
michael@0 47542 return;
michael@0 47543 }
michael@0 47544 if ((HEAP8[i6] | 0) != 0) {
michael@0 47545 __Z21btAlignedFreeInternalPv(i3);
michael@0 47546 }
michael@0 47547 HEAP32[i4 >> 2] = 0;
michael@0 47548 HEAP8[i6] = 1;
michael@0 47549 HEAP32[i4 >> 2] = 0;
michael@0 47550 HEAP32[i2 >> 2] = 0;
michael@0 47551 i8 = i1 + 16 | 0;
michael@0 47552 HEAP32[i8 >> 2] = 0;
michael@0 47553 i9 = i1 | 0;
michael@0 47554 __ZN30btActivatingCollisionAlgorithmD2Ev(i9);
michael@0 47555 return;
michael@0 47556 }
michael@0 47557 function __ZN28btHashedOverlappingPairCacheD2Ev(i1) {
michael@0 47558 i1 = i1 | 0;
michael@0 47559 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 47560 HEAP32[i1 >> 2] = 2800;
michael@0 47561 i2 = i1 + 56 | 0;
michael@0 47562 i3 = i1 + 64 | 0;
michael@0 47563 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47564 i5 = i1 + 68 | 0;
michael@0 47565 if ((i4 | 0) != 0) {
michael@0 47566 if ((HEAP8[i5] | 0) != 0) {
michael@0 47567 __Z21btAlignedFreeInternalPv(i4);
michael@0 47568 }
michael@0 47569 HEAP32[i3 >> 2] = 0;
michael@0 47570 }
michael@0 47571 HEAP8[i5] = 1;
michael@0 47572 HEAP32[i3 >> 2] = 0;
michael@0 47573 HEAP32[i2 >> 2] = 0;
michael@0 47574 HEAP32[i1 + 60 >> 2] = 0;
michael@0 47575 i2 = i1 + 36 | 0;
michael@0 47576 i3 = i1 + 44 | 0;
michael@0 47577 i5 = HEAP32[i3 >> 2] | 0;
michael@0 47578 i4 = i1 + 48 | 0;
michael@0 47579 if ((i5 | 0) != 0) {
michael@0 47580 if ((HEAP8[i4] | 0) != 0) {
michael@0 47581 __Z21btAlignedFreeInternalPv(i5);
michael@0 47582 }
michael@0 47583 HEAP32[i3 >> 2] = 0;
michael@0 47584 }
michael@0 47585 HEAP8[i4] = 1;
michael@0 47586 HEAP32[i3 >> 2] = 0;
michael@0 47587 HEAP32[i2 >> 2] = 0;
michael@0 47588 HEAP32[i1 + 40 >> 2] = 0;
michael@0 47589 i2 = i1 + 8 | 0;
michael@0 47590 i3 = i1 + 16 | 0;
michael@0 47591 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47592 i5 = i1 + 20 | 0;
michael@0 47593 if ((i4 | 0) == 0) {
michael@0 47594 HEAP8[i5] = 1;
michael@0 47595 HEAP32[i3 >> 2] = 0;
michael@0 47596 HEAP32[i2 >> 2] = 0;
michael@0 47597 i6 = i1 + 12 | 0;
michael@0 47598 HEAP32[i6 >> 2] = 0;
michael@0 47599 return;
michael@0 47600 }
michael@0 47601 if ((HEAP8[i5] | 0) != 0) {
michael@0 47602 __Z21btAlignedFreeInternalPv(i4);
michael@0 47603 }
michael@0 47604 HEAP32[i3 >> 2] = 0;
michael@0 47605 HEAP8[i5] = 1;
michael@0 47606 HEAP32[i3 >> 2] = 0;
michael@0 47607 HEAP32[i2 >> 2] = 0;
michael@0 47608 i6 = i1 + 12 | 0;
michael@0 47609 HEAP32[i6 >> 2] = 0;
michael@0 47610 return;
michael@0 47611 }
michael@0 47612 function __ZNK23btPolyhedralConvexShape21calculateLocalInertiaEfR9btVector3(i1, d2, i3) {
michael@0 47613 i1 = i1 | 0;
michael@0 47614 d2 = +d2;
michael@0 47615 i3 = i3 | 0;
michael@0 47616 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0;
michael@0 47617 i4 = STACKTOP;
michael@0 47618 STACKTOP = STACKTOP + 96 | 0;
michael@0 47619 i5 = i4 | 0;
michael@0 47620 i6 = i4 + 64 | 0;
michael@0 47621 i7 = i4 + 80 | 0;
michael@0 47622 i8 = i1 | 0;
michael@0 47623 d9 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i1 >> 2] | 0) + 44 >> 2] & 7](i8);
michael@0 47624 HEAPF32[i5 >> 2] = 1.0;
michael@0 47625 _memset(i5 + 4 | 0, 0, 16);
michael@0 47626 HEAPF32[i5 + 20 >> 2] = 1.0;
michael@0 47627 _memset(i5 + 24 | 0, 0, 16);
michael@0 47628 HEAPF32[i5 + 40 >> 2] = 1.0;
michael@0 47629 _memset(i5 + 44 | 0, 0, 20);
michael@0 47630 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i8, i5, i6, i7);
michael@0 47631 d10 = (d9 + (+HEAPF32[i7 >> 2] - +HEAPF32[i6 >> 2]) * .5) * 2.0;
michael@0 47632 d11 = (d9 + (+HEAPF32[i7 + 4 >> 2] - +HEAPF32[i6 + 4 >> 2]) * .5) * 2.0;
michael@0 47633 d12 = (d9 + (+HEAPF32[i7 + 8 >> 2] - +HEAPF32[i6 + 8 >> 2]) * .5) * 2.0;
michael@0 47634 d9 = d10 * d10;
michael@0 47635 d10 = d11 * d11;
michael@0 47636 d11 = d12 * d12;
michael@0 47637 d12 = d2 * .0833333283662796;
michael@0 47638 HEAPF32[i3 >> 2] = d12 * (d10 + d11);
michael@0 47639 HEAPF32[i3 + 4 >> 2] = d12 * (d9 + d11);
michael@0 47640 HEAPF32[i3 + 8 >> 2] = d12 * (d9 + d10);
michael@0 47641 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 47642 STACKTOP = i4;
michael@0 47643 return;
michael@0 47644 }
michael@0 47645 function __ZN16btCollisionWorld21removeCollisionObjectEP17btCollisionObject(i1, i2) {
michael@0 47646 i1 = i1 | 0;
michael@0 47647 i2 = i2 | 0;
michael@0 47648 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0;
michael@0 47649 i3 = i2 + 188 | 0;
michael@0 47650 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47651 if ((i4 | 0) != 0) {
michael@0 47652 i5 = i1 + 76 | 0;
michael@0 47653 i6 = HEAP32[i5 >> 2] | 0;
michael@0 47654 i7 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i6 >> 2] | 0) + 36 >> 2] & 127](i6) | 0;
michael@0 47655 i6 = i1 + 24 | 0;
michael@0 47656 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i7 >> 2] | 0) + 40 >> 2] & 127](i7, i4, HEAP32[i6 >> 2] | 0);
michael@0 47657 i7 = HEAP32[i5 >> 2] | 0;
michael@0 47658 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i7 >> 2] | 0) + 12 >> 2] & 127](i7, i4, HEAP32[i6 >> 2] | 0);
michael@0 47659 HEAP32[i3 >> 2] = 0;
michael@0 47660 }
michael@0 47661 i3 = i1 + 8 | 0;
michael@0 47662 i6 = HEAP32[i3 >> 2] | 0;
michael@0 47663 i4 = i1 + 16 | 0;
michael@0 47664 i1 = 0;
michael@0 47665 while (1) {
michael@0 47666 if ((i1 | 0) >= (i6 | 0)) {
michael@0 47667 i8 = 2093;
michael@0 47668 break;
michael@0 47669 }
michael@0 47670 i9 = HEAP32[i4 >> 2] | 0;
michael@0 47671 i10 = i9 + (i1 << 2) | 0;
michael@0 47672 if ((HEAP32[i10 >> 2] | 0) == (i2 | 0)) {
michael@0 47673 break;
michael@0 47674 } else {
michael@0 47675 i1 = i1 + 1 | 0;
michael@0 47676 }
michael@0 47677 }
michael@0 47678 if ((i8 | 0) == 2093) {
michael@0 47679 return;
michael@0 47680 }
michael@0 47681 i8 = i6 - 1 | 0;
michael@0 47682 HEAP32[i10 >> 2] = HEAP32[i9 + (i8 << 2) >> 2];
michael@0 47683 HEAP32[(HEAP32[i4 >> 2] | 0) + (i8 << 2) >> 2] = i2;
michael@0 47684 HEAP32[i3 >> 2] = i8;
michael@0 47685 return;
michael@0 47686 }
michael@0 47687 function __ZL11TestSepAxisRK18btConvexPolyhedronS1_RK11btTransformS4_RK9btVector3Rf(i1, i2, i3, i4, i5, i6) {
michael@0 47688 i1 = i1 | 0;
michael@0 47689 i2 = i2 | 0;
michael@0 47690 i3 = i3 | 0;
michael@0 47691 i4 = i4 | 0;
michael@0 47692 i5 = i5 | 0;
michael@0 47693 i6 = i6 | 0;
michael@0 47694 var i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, d12 = 0.0, d13 = 0.0, i14 = 0, d15 = 0.0, d16 = 0.0, d17 = 0.0;
michael@0 47695 i7 = STACKTOP;
michael@0 47696 STACKTOP = STACKTOP + 32 | 0;
michael@0 47697 i8 = i7 | 0;
michael@0 47698 i9 = i7 + 8 | 0;
michael@0 47699 i10 = i7 + 16 | 0;
michael@0 47700 i11 = i7 + 24 | 0;
michael@0 47701 __ZNK18btConvexPolyhedron7projectERK11btTransformRK9btVector3RfS6_(i1, i3, i5, i8, i9);
michael@0 47702 __ZNK18btConvexPolyhedron7projectERK11btTransformRK9btVector3RfS6_(i2, i4, i5, i10, i11);
michael@0 47703 d12 = +HEAPF32[i9 >> 2];
michael@0 47704 d13 = +HEAPF32[i10 >> 2];
michael@0 47705 if (d12 < d13) {
michael@0 47706 i14 = 0;
michael@0 47707 STACKTOP = i7;
michael@0 47708 return i14 | 0;
michael@0 47709 }
michael@0 47710 d15 = +HEAPF32[i11 >> 2];
michael@0 47711 d16 = +HEAPF32[i8 >> 2];
michael@0 47712 if (d15 < d16) {
michael@0 47713 i14 = 0;
michael@0 47714 STACKTOP = i7;
michael@0 47715 return i14 | 0;
michael@0 47716 }
michael@0 47717 d17 = d12 - d13;
michael@0 47718 if (d17 < 0.0) {
michael@0 47719 ___assert_func(336 | 0, 89, 1160 | 0, 720 | 0);
michael@0 47720 return 0;
michael@0 47721 }
michael@0 47722 d13 = d15 - d16;
michael@0 47723 if (d13 < 0.0) {
michael@0 47724 ___assert_func(336 | 0, 91, 1160 | 0, 568 | 0);
michael@0 47725 return 0;
michael@0 47726 }
michael@0 47727 HEAPF32[i6 >> 2] = d17 < d13 ? d17 : d13;
michael@0 47728 i14 = 1;
michael@0 47729 STACKTOP = i7;
michael@0 47730 return i14 | 0;
michael@0 47731 }
michael@0 47732 function __ZN22btVoronoiSimplexSolver9addVertexERK9btVector3S2_S2_(i1, i2, i3, i4) {
michael@0 47733 i1 = i1 | 0;
michael@0 47734 i2 = i2 | 0;
michael@0 47735 i3 = i3 | 0;
michael@0 47736 i4 = i4 | 0;
michael@0 47737 var i5 = 0, i6 = 0;
michael@0 47738 i5 = i1 + 292 | 0;
michael@0 47739 i6 = i2;
michael@0 47740 HEAP32[i5 >> 2] = HEAP32[i6 >> 2];
michael@0 47741 HEAP32[i5 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 47742 HEAP32[i5 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 47743 HEAP32[i5 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 47744 HEAP8[i1 + 356 | 0] = 1;
michael@0 47745 i5 = i1 | 0;
michael@0 47746 i2 = i1 + 4 + (HEAP32[i5 >> 2] << 4) | 0;
michael@0 47747 HEAP32[i2 >> 2] = HEAP32[i6 >> 2];
michael@0 47748 HEAP32[i2 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 47749 HEAP32[i2 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 47750 HEAP32[i2 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 47751 i6 = i1 + 84 + (HEAP32[i5 >> 2] << 4) | 0;
michael@0 47752 i2 = i3;
michael@0 47753 HEAP32[i6 >> 2] = HEAP32[i2 >> 2];
michael@0 47754 HEAP32[i6 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 47755 HEAP32[i6 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 47756 HEAP32[i6 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 47757 i2 = i1 + 164 + (HEAP32[i5 >> 2] << 4) | 0;
michael@0 47758 i1 = i4;
michael@0 47759 HEAP32[i2 >> 2] = HEAP32[i1 >> 2];
michael@0 47760 HEAP32[i2 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 47761 HEAP32[i2 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 47762 HEAP32[i2 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 47763 HEAP32[i5 >> 2] = (HEAP32[i5 >> 2] | 0) + 1;
michael@0 47764 return;
michael@0 47765 }
michael@0 47766 function __ZN20btConvexHullComputerD2Ev(i1) {
michael@0 47767 i1 = i1 | 0;
michael@0 47768 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 47769 i2 = i1 + 44 | 0;
michael@0 47770 i3 = i1 + 52 | 0;
michael@0 47771 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47772 i5 = i1 + 56 | 0;
michael@0 47773 if ((i4 | 0) != 0) {
michael@0 47774 if ((HEAP8[i5] | 0) != 0) {
michael@0 47775 __Z21btAlignedFreeInternalPv(i4);
michael@0 47776 }
michael@0 47777 HEAP32[i3 >> 2] = 0;
michael@0 47778 }
michael@0 47779 HEAP8[i5] = 1;
michael@0 47780 HEAP32[i3 >> 2] = 0;
michael@0 47781 HEAP32[i2 >> 2] = 0;
michael@0 47782 HEAP32[i1 + 48 >> 2] = 0;
michael@0 47783 i2 = i1 + 24 | 0;
michael@0 47784 i3 = i1 + 32 | 0;
michael@0 47785 i5 = HEAP32[i3 >> 2] | 0;
michael@0 47786 i4 = i1 + 36 | 0;
michael@0 47787 if ((i5 | 0) != 0) {
michael@0 47788 if ((HEAP8[i4] | 0) != 0) {
michael@0 47789 __Z21btAlignedFreeInternalPv(i5);
michael@0 47790 }
michael@0 47791 HEAP32[i3 >> 2] = 0;
michael@0 47792 }
michael@0 47793 HEAP8[i4] = 1;
michael@0 47794 HEAP32[i3 >> 2] = 0;
michael@0 47795 HEAP32[i2 >> 2] = 0;
michael@0 47796 HEAP32[i1 + 28 >> 2] = 0;
michael@0 47797 i2 = i1 + 4 | 0;
michael@0 47798 i3 = i1 + 12 | 0;
michael@0 47799 i4 = HEAP32[i3 >> 2] | 0;
michael@0 47800 i5 = i1 + 16 | 0;
michael@0 47801 if ((i4 | 0) == 0) {
michael@0 47802 HEAP8[i5] = 1;
michael@0 47803 HEAP32[i3 >> 2] = 0;
michael@0 47804 HEAP32[i2 >> 2] = 0;
michael@0 47805 i6 = i1 + 8 | 0;
michael@0 47806 HEAP32[i6 >> 2] = 0;
michael@0 47807 return;
michael@0 47808 }
michael@0 47809 if ((HEAP8[i5] | 0) != 0) {
michael@0 47810 __Z21btAlignedFreeInternalPv(i4);
michael@0 47811 }
michael@0 47812 HEAP32[i3 >> 2] = 0;
michael@0 47813 HEAP8[i5] = 1;
michael@0 47814 HEAP32[i3 >> 2] = 0;
michael@0 47815 HEAP32[i2 >> 2] = 0;
michael@0 47816 i6 = i1 + 8 | 0;
michael@0 47817 HEAP32[i6 >> 2] = 0;
michael@0 47818 return;
michael@0 47819 }
michael@0 47820 function __ZN31btConvexPlaneCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 47821 i1 = i1 | 0;
michael@0 47822 i2 = i2 | 0;
michael@0 47823 i3 = i3 | 0;
michael@0 47824 i4 = i4 | 0;
michael@0 47825 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 47826 i5 = HEAP32[i2 >> 2] | 0;
michael@0 47827 i6 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i5 >> 2] | 0) + 56 >> 2] & 63](i5, 28) | 0;
michael@0 47828 i5 = (i6 | 0) == 0;
michael@0 47829 if ((HEAP8[i1 + 4 | 0] | 0) == 0) {
michael@0 47830 if (i5) {
michael@0 47831 i7 = 0;
michael@0 47832 i8 = i7 | 0;
michael@0 47833 return i8 | 0;
michael@0 47834 }
michael@0 47835 i9 = i6;
michael@0 47836 __ZN31btConvexPlaneCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_bii(i9, 0, i2, i3, i4, 0, HEAP32[i1 + 8 >> 2] | 0, HEAP32[i1 + 12 >> 2] | 0);
michael@0 47837 i7 = i9;
michael@0 47838 i8 = i7 | 0;
michael@0 47839 return i8 | 0;
michael@0 47840 } else {
michael@0 47841 if (i5) {
michael@0 47842 i7 = 0;
michael@0 47843 i8 = i7 | 0;
michael@0 47844 return i8 | 0;
michael@0 47845 }
michael@0 47846 i5 = i6;
michael@0 47847 __ZN31btConvexPlaneCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_bii(i5, 0, i2, i3, i4, 1, HEAP32[i1 + 8 >> 2] | 0, HEAP32[i1 + 12 >> 2] | 0);
michael@0 47848 i7 = i5;
michael@0 47849 i8 = i7 | 0;
michael@0 47850 return i8 | 0;
michael@0 47851 }
michael@0 47852 return 0;
michael@0 47853 }
michael@0 47854 function __ZN20btDefaultMotionState17setWorldTransformERK11btTransform(i1, i2) {
michael@0 47855 i1 = i1 | 0;
michael@0 47856 i2 = i2 | 0;
michael@0 47857 var i3 = 0, i4 = 0, i5 = 0;
michael@0 47858 i3 = STACKTOP;
michael@0 47859 STACKTOP = STACKTOP + 64 | 0;
michael@0 47860 i4 = i3 | 0;
michael@0 47861 __ZNK11btTransformmlERKS_(i4, i2, i1 + 68 | 0);
michael@0 47862 i2 = i1 + 4 | 0;
michael@0 47863 i5 = i4;
michael@0 47864 HEAP32[i2 >> 2] = HEAP32[i5 >> 2];
michael@0 47865 HEAP32[i2 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 47866 HEAP32[i2 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 47867 HEAP32[i2 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 47868 i5 = i1 + 20 | 0;
michael@0 47869 i2 = i4 + 16 | 0;
michael@0 47870 HEAP32[i5 >> 2] = HEAP32[i2 >> 2];
michael@0 47871 HEAP32[i5 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 47872 HEAP32[i5 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 47873 HEAP32[i5 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 47874 i2 = i1 + 36 | 0;
michael@0 47875 i5 = i4 + 32 | 0;
michael@0 47876 HEAP32[i2 >> 2] = HEAP32[i5 >> 2];
michael@0 47877 HEAP32[i2 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 47878 HEAP32[i2 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 47879 HEAP32[i2 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 47880 i5 = i1 + 52 | 0;
michael@0 47881 i1 = i4 + 48 | 0;
michael@0 47882 HEAP32[i5 >> 2] = HEAP32[i1 >> 2];
michael@0 47883 HEAP32[i5 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 47884 HEAP32[i5 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 47885 HEAP32[i5 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 47886 STACKTOP = i3;
michael@0 47887 return;
michael@0 47888 }
michael@0 47889 function __ZNK16btCollisionShape17getBoundingSphereER9btVector3Rf(i1, i2, i3) {
michael@0 47890 i1 = i1 | 0;
michael@0 47891 i2 = i2 | 0;
michael@0 47892 i3 = i3 | 0;
michael@0 47893 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, d14 = 0.0, d15 = 0.0, d16 = 0.0;
michael@0 47894 i4 = STACKTOP;
michael@0 47895 STACKTOP = STACKTOP + 96 | 0;
michael@0 47896 i5 = i4 | 0;
michael@0 47897 i6 = i4 + 64 | 0;
michael@0 47898 i7 = i4 + 80 | 0;
michael@0 47899 HEAPF32[i5 >> 2] = 1.0;
michael@0 47900 _memset(i5 + 4 | 0, 0, 16);
michael@0 47901 HEAPF32[i5 + 20 >> 2] = 1.0;
michael@0 47902 _memset(i5 + 24 | 0, 0, 16);
michael@0 47903 HEAPF32[i5 + 40 >> 2] = 1.0;
michael@0 47904 _memset(i5 + 44 | 0, 0, 20);
michael@0 47905 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i1, i5, i6, i7);
michael@0 47906 d8 = +HEAPF32[i7 >> 2];
michael@0 47907 d9 = +HEAPF32[i6 >> 2];
michael@0 47908 d10 = d8 - d9;
michael@0 47909 d11 = +HEAPF32[i7 + 4 >> 2];
michael@0 47910 d12 = +HEAPF32[i6 + 4 >> 2];
michael@0 47911 d13 = d11 - d12;
michael@0 47912 d14 = +HEAPF32[i7 + 8 >> 2];
michael@0 47913 d15 = +HEAPF32[i6 + 8 >> 2];
michael@0 47914 d16 = d14 - d15;
michael@0 47915 HEAPF32[i3 >> 2] = +Math_sqrt(+(d10 * d10 + d13 * d13 + d16 * d16)) * .5;
michael@0 47916 HEAPF32[i2 >> 2] = (d8 + d9) * .5;
michael@0 47917 HEAPF32[i2 + 4 >> 2] = (d11 + d12) * .5;
michael@0 47918 HEAPF32[i2 + 8 >> 2] = (d14 + d15) * .5;
michael@0 47919 HEAPF32[i2 + 12 >> 2] = 0.0;
michael@0 47920 STACKTOP = i4;
michael@0 47921 return;
michael@0 47922 }
michael@0 47923 function __ZNK10btBoxShape32getPreferredPenetrationDirectionEiR9btVector3(i1, i2, i3) {
michael@0 47924 i1 = i1 | 0;
michael@0 47925 i2 = i2 | 0;
michael@0 47926 i3 = i3 | 0;
michael@0 47927 switch (i2 | 0) {
michael@0 47928 case 5:
michael@0 47929 {
michael@0 47930 HEAPF32[i3 >> 2] = 0.0;
michael@0 47931 HEAPF32[i3 + 4 >> 2] = 0.0;
michael@0 47932 HEAPF32[i3 + 8 >> 2] = -1.0;
michael@0 47933 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 47934 return;
michael@0 47935 }
michael@0 47936 case 3:
michael@0 47937 {
michael@0 47938 HEAPF32[i3 >> 2] = 0.0;
michael@0 47939 HEAPF32[i3 + 4 >> 2] = -1.0;
michael@0 47940 HEAPF32[i3 + 8 >> 2] = 0.0;
michael@0 47941 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 47942 return;
michael@0 47943 }
michael@0 47944 case 1:
michael@0 47945 {
michael@0 47946 HEAPF32[i3 >> 2] = -1.0;
michael@0 47947 HEAPF32[i3 + 4 >> 2] = 0.0;
michael@0 47948 HEAPF32[i3 + 8 >> 2] = 0.0;
michael@0 47949 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 47950 return;
michael@0 47951 }
michael@0 47952 case 2:
michael@0 47953 {
michael@0 47954 HEAPF32[i3 >> 2] = 0.0;
michael@0 47955 HEAPF32[i3 + 4 >> 2] = 1.0;
michael@0 47956 HEAPF32[i3 + 8 >> 2] = 0.0;
michael@0 47957 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 47958 return;
michael@0 47959 }
michael@0 47960 case 0:
michael@0 47961 {
michael@0 47962 HEAPF32[i3 >> 2] = 1.0;
michael@0 47963 HEAPF32[i3 + 4 >> 2] = 0.0;
michael@0 47964 HEAPF32[i3 + 8 >> 2] = 0.0;
michael@0 47965 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 47966 return;
michael@0 47967 }
michael@0 47968 case 4:
michael@0 47969 {
michael@0 47970 HEAPF32[i3 >> 2] = 0.0;
michael@0 47971 HEAPF32[i3 + 4 >> 2] = 0.0;
michael@0 47972 HEAPF32[i3 + 8 >> 2] = 1.0;
michael@0 47973 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 47974 return;
michael@0 47975 }
michael@0 47976 default:
michael@0 47977 {
michael@0 47978 return;
michael@0 47979 }
michael@0 47980 }
michael@0 47981 }
michael@0 47982 function __ZN35btSequentialImpulseConstraintSolver33solveGroupCacheFriendlyIterationsEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
michael@0 47983 i1 = i1 | 0;
michael@0 47984 i2 = i2 | 0;
michael@0 47985 i3 = i3 | 0;
michael@0 47986 i4 = i4 | 0;
michael@0 47987 i5 = i5 | 0;
michael@0 47988 i6 = i6 | 0;
michael@0 47989 i7 = i7 | 0;
michael@0 47990 i8 = i8 | 0;
michael@0 47991 i9 = i9 | 0;
michael@0 47992 i10 = i10 | 0;
michael@0 47993 var i11 = 0;
michael@0 47994 __ZN15CProfileManager13Start_ProfileEPKc(736);
michael@0 47995 FUNCTION_TABLE_viiiiiiiiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 24 >> 2] & 3](i1, i2, i3, i4, i5, i6, i7, i8, i9, i10);
michael@0 47996 i10 = i8 + 20 | 0;
michael@0 47997 if ((HEAP32[i10 >> 2] | 0) > 0) {
michael@0 47998 i11 = 0;
michael@0 47999 } else {
michael@0 48000 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 48001 return +0.0;
michael@0 48002 }
michael@0 48003 do {
michael@0 48004 +__ZN35btSequentialImpulseConstraintSolver20solveSingleIterationEiPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc(i1, i11, 0, 0, 0, 0, i6, i7, i8, 0, 0);
michael@0 48005 i11 = i11 + 1 | 0;
michael@0 48006 } while ((i11 | 0) < (HEAP32[i10 >> 2] | 0));
michael@0 48007 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 48008 return +0.0;
michael@0 48009 }
michael@0 48010 function __ZN20btAlignedObjectArrayI6btFaceE7destroyEii(i1, i2, i3) {
michael@0 48011 i1 = i1 | 0;
michael@0 48012 i2 = i2 | 0;
michael@0 48013 i3 = i3 | 0;
michael@0 48014 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 48015 if ((i2 | 0) >= (i3 | 0)) {
michael@0 48016 return;
michael@0 48017 }
michael@0 48018 i4 = i1 + 12 | 0;
michael@0 48019 i1 = i2;
michael@0 48020 do {
michael@0 48021 i2 = HEAP32[i4 >> 2] | 0;
michael@0 48022 i5 = i2 + (i1 * 56 | 0) + 24 | 0;
michael@0 48023 i6 = i2 + (i1 * 56 | 0) + 32 | 0;
michael@0 48024 i7 = HEAP32[i6 >> 2] | 0;
michael@0 48025 i8 = i2 + (i1 * 56 | 0) + 36 | 0;
michael@0 48026 if ((i7 | 0) != 0) {
michael@0 48027 if ((HEAP8[i8] | 0) != 0) {
michael@0 48028 __Z21btAlignedFreeInternalPv(i7);
michael@0 48029 }
michael@0 48030 HEAP32[i6 >> 2] = 0;
michael@0 48031 }
michael@0 48032 HEAP8[i8] = 1;
michael@0 48033 HEAP32[i6 >> 2] = 0;
michael@0 48034 HEAP32[i5 >> 2] = 0;
michael@0 48035 HEAP32[i2 + (i1 * 56 | 0) + 28 >> 2] = 0;
michael@0 48036 i5 = i2 + (i1 * 56 | 0) + 4 | 0;
michael@0 48037 i6 = i2 + (i1 * 56 | 0) + 12 | 0;
michael@0 48038 i8 = HEAP32[i6 >> 2] | 0;
michael@0 48039 i7 = i2 + (i1 * 56 | 0) + 16 | 0;
michael@0 48040 if ((i8 | 0) != 0) {
michael@0 48041 if ((HEAP8[i7] | 0) != 0) {
michael@0 48042 __Z21btAlignedFreeInternalPv(i8);
michael@0 48043 }
michael@0 48044 HEAP32[i6 >> 2] = 0;
michael@0 48045 }
michael@0 48046 HEAP8[i7] = 1;
michael@0 48047 HEAP32[i6 >> 2] = 0;
michael@0 48048 HEAP32[i5 >> 2] = 0;
michael@0 48049 HEAP32[i2 + (i1 * 56 | 0) + 8 >> 2] = 0;
michael@0 48050 i1 = i1 + 1 | 0;
michael@0 48051 } while ((i1 | 0) < (i3 | 0));
michael@0 48052 return;
michael@0 48053 }
michael@0 48054 function __ZNK20btConvexHullInternal6Int1288toScalarEv(i1) {
michael@0 48055 i1 = i1 | 0;
michael@0 48056 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, d7 = 0.0, i8 = 0, i9 = 0, i10 = 0;
michael@0 48057 i2 = STACKTOP;
michael@0 48058 STACKTOP = STACKTOP + 16 | 0;
michael@0 48059 i3 = i2 | 0;
michael@0 48060 i4 = i1 + 8 | 0;
michael@0 48061 i5 = HEAP32[i4 >> 2] | 0;
michael@0 48062 i6 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 48063 i4 = -1;
michael@0 48064 if ((i6 | 0) > (i4 | 0) | (i6 | 0) == (i4 | 0) & i5 >>> 0 > -1 >>> 0) {
michael@0 48065 i4 = i1 | 0;
michael@0 48066 d7 = (+(i5 >>> 0) + +(i6 >>> 0) * 4294967296.0) * 18446744073709552000.0 + (+((HEAP32[i4 >> 2] | 0) >>> 0) + +((HEAP32[i4 + 4 >> 2] | 0) >>> 0) * 4294967296.0);
michael@0 48067 STACKTOP = i2;
michael@0 48068 return +d7;
michael@0 48069 } else {
michael@0 48070 i4 = i1 | 0;
michael@0 48071 i1 = HEAP32[i4 >> 2] | 0;
michael@0 48072 i8 = HEAP32[i4 + 4 >> 2] | 0;
michael@0 48073 i4 = _i64Subtract(0, 0, i1, i8) | 0;
michael@0 48074 i9 = tempRet0;
michael@0 48075 i10 = _i64Add((i1 | 0) == 0 & (i8 | 0) == 0 & 1, 0, ~i5, ~i6) | 0;
michael@0 48076 i6 = i3 | 0;
michael@0 48077 HEAP32[i6 >> 2] = i4;
michael@0 48078 HEAP32[i6 + 4 >> 2] = i9;
michael@0 48079 i9 = i3 + 8 | 0;
michael@0 48080 HEAP32[i9 >> 2] = i10;
michael@0 48081 HEAP32[i9 + 4 >> 2] = tempRet0;
michael@0 48082 d7 = -0.0 - +__ZNK20btConvexHullInternal6Int1288toScalarEv(i3);
michael@0 48083 STACKTOP = i2;
michael@0 48084 return +d7;
michael@0 48085 }
michael@0 48086 return 0.0;
michael@0 48087 }
michael@0 48088 function __ZN10btBoxShape15setLocalScalingERK9btVector3(i1, i2) {
michael@0 48089 i1 = i1 | 0;
michael@0 48090 i2 = i2 | 0;
michael@0 48091 var i3 = 0, i4 = 0, d5 = 0.0, d6 = 0.0, d7 = 0.0, i8 = 0, i9 = 0, i10 = 0, d11 = 0.0, i12 = 0, d13 = 0.0, i14 = 0, d15 = 0.0, d16 = 0.0;
michael@0 48092 i3 = i1 | 0;
michael@0 48093 i4 = i1;
michael@0 48094 d5 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48095 d6 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48096 d7 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48097 i4 = i1 + 28 | 0;
michael@0 48098 i8 = i1 + 32 | 0;
michael@0 48099 i9 = i1 + 36 | 0;
michael@0 48100 i10 = i1 + 12 | 0;
michael@0 48101 d11 = (d5 + +HEAPF32[i4 >> 2]) / +HEAPF32[i10 >> 2];
michael@0 48102 i12 = i1 + 16 | 0;
michael@0 48103 d13 = (d6 + +HEAPF32[i8 >> 2]) / +HEAPF32[i12 >> 2];
michael@0 48104 i14 = i1 + 20 | 0;
michael@0 48105 d15 = (d7 + +HEAPF32[i9 >> 2]) / +HEAPF32[i14 >> 2];
michael@0 48106 __ZN21btConvexInternalShape15setLocalScalingERK9btVector3(i3, i2);
michael@0 48107 d16 = d13 * +HEAPF32[i12 >> 2] - d6;
michael@0 48108 d6 = d15 * +HEAPF32[i14 >> 2] - d7;
michael@0 48109 HEAPF32[i4 >> 2] = d11 * +HEAPF32[i10 >> 2] - d5;
michael@0 48110 HEAPF32[i8 >> 2] = d16;
michael@0 48111 HEAPF32[i9 >> 2] = d6;
michael@0 48112 HEAPF32[i1 + 40 >> 2] = 0.0;
michael@0 48113 return;
michael@0 48114 }
michael@0 48115 function __ZNK15btTriangleShape32getPreferredPenetrationDirectionEiR9btVector3(i1, i2, i3) {
michael@0 48116 i1 = i1 | 0;
michael@0 48117 i2 = i2 | 0;
michael@0 48118 i3 = i3 | 0;
michael@0 48119 var d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, i12 = 0, i13 = 0;
michael@0 48120 d4 = +HEAPF32[i1 + 56 >> 2];
michael@0 48121 d5 = +HEAPF32[i1 + 72 >> 2] - d4;
michael@0 48122 d6 = +HEAPF32[i1 + 60 >> 2];
michael@0 48123 d7 = +HEAPF32[i1 + 76 >> 2] - d6;
michael@0 48124 d8 = +HEAPF32[i1 + 64 >> 2];
michael@0 48125 d9 = +HEAPF32[i1 + 80 >> 2] - d8;
michael@0 48126 d10 = +HEAPF32[i1 + 88 >> 2] - d4;
michael@0 48127 d4 = +HEAPF32[i1 + 92 >> 2] - d6;
michael@0 48128 d6 = +HEAPF32[i1 + 96 >> 2] - d8;
michael@0 48129 d8 = d7 * d6 - d9 * d4;
michael@0 48130 d11 = d9 * d10 - d5 * d6;
michael@0 48131 d6 = d5 * d4 - d7 * d10;
michael@0 48132 i1 = i3 | 0;
michael@0 48133 i12 = i3 + 4 | 0;
michael@0 48134 i13 = i3 + 8 | 0;
michael@0 48135 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 48136 d10 = 1.0 / +Math_sqrt(+(d6 * d6 + (d8 * d8 + d11 * d11)));
michael@0 48137 d7 = d10 * d8;
michael@0 48138 HEAPF32[i1 >> 2] = d7;
michael@0 48139 d8 = d10 * d11;
michael@0 48140 HEAPF32[i12 >> 2] = d8;
michael@0 48141 d11 = d6 * d10;
michael@0 48142 HEAPF32[i13 >> 2] = d11;
michael@0 48143 if ((i2 | 0) == 0) {
michael@0 48144 return;
michael@0 48145 }
michael@0 48146 HEAPF32[i1 >> 2] = d7 * -1.0;
michael@0 48147 HEAPF32[i12 >> 2] = d8 * -1.0;
michael@0 48148 HEAPF32[i13 >> 2] = d11 * -1.0;
michael@0 48149 return;
michael@0 48150 }
michael@0 48151 function __ZNK10__cxxabiv117__class_type_info16search_above_dstEPNS_19__dynamic_cast_infoEPKvS4_ib(i1, i2, i3, i4, i5, i6) {
michael@0 48152 i1 = i1 | 0;
michael@0 48153 i2 = i2 | 0;
michael@0 48154 i3 = i3 | 0;
michael@0 48155 i4 = i4 | 0;
michael@0 48156 i5 = i5 | 0;
michael@0 48157 i6 = i6 | 0;
michael@0 48158 var i7 = 0;
michael@0 48159 if ((HEAP32[i2 + 8 >> 2] | 0) != (i1 | 0)) {
michael@0 48160 return;
michael@0 48161 }
michael@0 48162 HEAP8[i2 + 53 | 0] = 1;
michael@0 48163 if ((HEAP32[i2 + 4 >> 2] | 0) != (i4 | 0)) {
michael@0 48164 return;
michael@0 48165 }
michael@0 48166 HEAP8[i2 + 52 | 0] = 1;
michael@0 48167 i4 = i2 + 16 | 0;
michael@0 48168 i1 = HEAP32[i4 >> 2] | 0;
michael@0 48169 if ((i1 | 0) == 0) {
michael@0 48170 HEAP32[i4 >> 2] = i3;
michael@0 48171 HEAP32[i2 + 24 >> 2] = i5;
michael@0 48172 HEAP32[i2 + 36 >> 2] = 1;
michael@0 48173 if (!((HEAP32[i2 + 48 >> 2] | 0) == 1 & (i5 | 0) == 1)) {
michael@0 48174 return;
michael@0 48175 }
michael@0 48176 HEAP8[i2 + 54 | 0] = 1;
michael@0 48177 return;
michael@0 48178 }
michael@0 48179 if ((i1 | 0) != (i3 | 0)) {
michael@0 48180 i3 = i2 + 36 | 0;
michael@0 48181 HEAP32[i3 >> 2] = (HEAP32[i3 >> 2] | 0) + 1;
michael@0 48182 HEAP8[i2 + 54 | 0] = 1;
michael@0 48183 return;
michael@0 48184 }
michael@0 48185 i3 = i2 + 24 | 0;
michael@0 48186 i1 = HEAP32[i3 >> 2] | 0;
michael@0 48187 if ((i1 | 0) == 2) {
michael@0 48188 HEAP32[i3 >> 2] = i5;
michael@0 48189 i7 = i5;
michael@0 48190 } else {
michael@0 48191 i7 = i1;
michael@0 48192 }
michael@0 48193 if (!((HEAP32[i2 + 48 >> 2] | 0) == 1 & (i7 | 0) == 1)) {
michael@0 48194 return;
michael@0 48195 }
michael@0 48196 HEAP8[i2 + 54 | 0] = 1;
michael@0 48197 return;
michael@0 48198 }
michael@0 48199 function __ZNK10btBoxShape8getPlaneER9btVector3S1_i(i1, i2, i3, i4) {
michael@0 48200 i1 = i1 | 0;
michael@0 48201 i2 = i2 | 0;
michael@0 48202 i3 = i3 | 0;
michael@0 48203 i4 = i4 | 0;
michael@0 48204 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0;
michael@0 48205 i5 = STACKTOP;
michael@0 48206 STACKTOP = STACKTOP + 48 | 0;
michael@0 48207 i6 = i5 | 0;
michael@0 48208 i7 = i5 + 16 | 0;
michael@0 48209 i8 = i5 + 32 | 0;
michael@0 48210 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 116 >> 2] & 127](i1, i6, i4);
michael@0 48211 d9 = +HEAPF32[i6 >> 2];
michael@0 48212 d10 = +HEAPF32[i6 + 4 >> 2];
michael@0 48213 d11 = +HEAPF32[i6 + 8 >> 2];
michael@0 48214 HEAPF32[i2 >> 2] = d9;
michael@0 48215 HEAPF32[i2 + 4 >> 2] = d10;
michael@0 48216 HEAPF32[i2 + 8 >> 2] = d11;
michael@0 48217 HEAPF32[i2 + 12 >> 2] = 0.0;
michael@0 48218 i2 = HEAP32[(HEAP32[i1 >> 2] | 0) + 60 >> 2] | 0;
michael@0 48219 HEAPF32[i8 >> 2] = -0.0 - d9;
michael@0 48220 HEAPF32[i8 + 4 >> 2] = -0.0 - d10;
michael@0 48221 HEAPF32[i8 + 8 >> 2] = -0.0 - d11;
michael@0 48222 HEAPF32[i8 + 12 >> 2] = 0.0;
michael@0 48223 FUNCTION_TABLE_viii[i2 & 127](i7, i1, i8);
michael@0 48224 i8 = i3;
michael@0 48225 i3 = i7;
michael@0 48226 HEAP32[i8 >> 2] = HEAP32[i3 >> 2];
michael@0 48227 HEAP32[i8 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 48228 HEAP32[i8 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 48229 HEAP32[i8 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 48230 STACKTOP = i5;
michael@0 48231 return;
michael@0 48232 }
michael@0 48233 function __ZN28btHashedOverlappingPairCache26processAllOverlappingPairsEP17btOverlapCallbackP12btDispatcher(i1, i2, i3) {
michael@0 48234 i1 = i1 | 0;
michael@0 48235 i2 = i2 | 0;
michael@0 48236 i3 = i3 | 0;
michael@0 48237 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0;
michael@0 48238 i4 = i1 + 8 | 0;
michael@0 48239 if ((HEAP32[i4 >> 2] | 0) <= 0) {
michael@0 48240 return;
michael@0 48241 }
michael@0 48242 i5 = i1 + 16 | 0;
michael@0 48243 i6 = i2;
michael@0 48244 i7 = i1;
michael@0 48245 i8 = 0;
michael@0 48246 L1889 : while (1) {
michael@0 48247 while (1) {
michael@0 48248 i9 = HEAP32[i5 >> 2] | 0;
michael@0 48249 i10 = i9 + (i8 << 4) | 0;
michael@0 48250 if (!(FUNCTION_TABLE_iii[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 63](i2, i10) | 0)) {
michael@0 48251 break;
michael@0 48252 }
michael@0 48253 FUNCTION_TABLE_iiiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 12 >> 2] & 31](i1, HEAP32[i10 >> 2] | 0, HEAP32[i9 + (i8 << 4) + 4 >> 2] | 0, i3) | 0;
michael@0 48254 HEAP32[2986] = (HEAP32[2986] | 0) - 1;
michael@0 48255 if ((i8 | 0) >= (HEAP32[i4 >> 2] | 0)) {
michael@0 48256 i11 = 1636;
michael@0 48257 break L1889;
michael@0 48258 }
michael@0 48259 }
michael@0 48260 i9 = i8 + 1 | 0;
michael@0 48261 if ((i9 | 0) < (HEAP32[i4 >> 2] | 0)) {
michael@0 48262 i8 = i9;
michael@0 48263 } else {
michael@0 48264 i11 = 1635;
michael@0 48265 break;
michael@0 48266 }
michael@0 48267 }
michael@0 48268 if ((i11 | 0) == 1635) {
michael@0 48269 return;
michael@0 48270 } else if ((i11 | 0) == 1636) {
michael@0 48271 return;
michael@0 48272 }
michael@0 48273 }
michael@0 48274 function __ZNK10__cxxabiv117__class_type_info16search_below_dstEPNS_19__dynamic_cast_infoEPKvib(i1, i2, i3, i4, i5) {
michael@0 48275 i1 = i1 | 0;
michael@0 48276 i2 = i2 | 0;
michael@0 48277 i3 = i3 | 0;
michael@0 48278 i4 = i4 | 0;
michael@0 48279 i5 = i5 | 0;
michael@0 48280 if ((HEAP32[i2 + 8 >> 2] | 0) == (i1 | 0)) {
michael@0 48281 if ((HEAP32[i2 + 4 >> 2] | 0) != (i3 | 0)) {
michael@0 48282 return;
michael@0 48283 }
michael@0 48284 i5 = i2 + 28 | 0;
michael@0 48285 if ((HEAP32[i5 >> 2] | 0) == 1) {
michael@0 48286 return;
michael@0 48287 }
michael@0 48288 HEAP32[i5 >> 2] = i4;
michael@0 48289 return;
michael@0 48290 }
michael@0 48291 if ((HEAP32[i2 >> 2] | 0) != (i1 | 0)) {
michael@0 48292 return;
michael@0 48293 }
michael@0 48294 do {
michael@0 48295 if ((HEAP32[i2 + 16 >> 2] | 0) != (i3 | 0)) {
michael@0 48296 i1 = i2 + 20 | 0;
michael@0 48297 if ((HEAP32[i1 >> 2] | 0) == (i3 | 0)) {
michael@0 48298 break;
michael@0 48299 }
michael@0 48300 HEAP32[i2 + 32 >> 2] = i4;
michael@0 48301 HEAP32[i1 >> 2] = i3;
michael@0 48302 i1 = i2 + 40 | 0;
michael@0 48303 HEAP32[i1 >> 2] = (HEAP32[i1 >> 2] | 0) + 1;
michael@0 48304 do {
michael@0 48305 if ((HEAP32[i2 + 36 >> 2] | 0) == 1) {
michael@0 48306 if ((HEAP32[i2 + 24 >> 2] | 0) != 2) {
michael@0 48307 break;
michael@0 48308 }
michael@0 48309 HEAP8[i2 + 54 | 0] = 1;
michael@0 48310 }
michael@0 48311 } while (0);
michael@0 48312 HEAP32[i2 + 44 >> 2] = 4;
michael@0 48313 return;
michael@0 48314 }
michael@0 48315 } while (0);
michael@0 48316 if ((i4 | 0) != 1) {
michael@0 48317 return;
michael@0 48318 }
michael@0 48319 HEAP32[i2 + 32 >> 2] = 1;
michael@0 48320 return;
michael@0 48321 }
michael@0 48322 function __ZNK15btTriangleShape16getPlaneEquationEiR9btVector3S1_(i1, i2, i3, i4) {
michael@0 48323 i1 = i1 | 0;
michael@0 48324 i2 = i2 | 0;
michael@0 48325 i3 = i3 | 0;
michael@0 48326 i4 = i4 | 0;
michael@0 48327 var d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0, d12 = 0.0;
michael@0 48328 d5 = +HEAPF32[i1 + 56 >> 2];
michael@0 48329 d6 = +HEAPF32[i1 + 72 >> 2] - d5;
michael@0 48330 d7 = +HEAPF32[i1 + 60 >> 2];
michael@0 48331 d8 = +HEAPF32[i1 + 76 >> 2] - d7;
michael@0 48332 d9 = +HEAPF32[i1 + 64 >> 2];
michael@0 48333 d10 = +HEAPF32[i1 + 80 >> 2] - d9;
michael@0 48334 d11 = +HEAPF32[i1 + 88 >> 2] - d5;
michael@0 48335 d5 = +HEAPF32[i1 + 92 >> 2] - d7;
michael@0 48336 d7 = +HEAPF32[i1 + 96 >> 2] - d9;
michael@0 48337 d9 = d8 * d7 - d10 * d5;
michael@0 48338 d12 = d10 * d11 - d6 * d7;
michael@0 48339 d7 = d6 * d5 - d8 * d11;
michael@0 48340 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 48341 d11 = 1.0 / +Math_sqrt(+(d7 * d7 + (d9 * d9 + d12 * d12)));
michael@0 48342 HEAPF32[i3 >> 2] = d11 * d9;
michael@0 48343 HEAPF32[i3 + 4 >> 2] = d11 * d12;
michael@0 48344 HEAPF32[i3 + 8 >> 2] = d7 * d11;
michael@0 48345 i3 = i4;
michael@0 48346 i4 = i1 + 56 | 0;
michael@0 48347 HEAP32[i3 >> 2] = HEAP32[i4 >> 2];
michael@0 48348 HEAP32[i3 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 48349 HEAP32[i3 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 48350 HEAP32[i3 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 48351 return;
michael@0 48352 }
michael@0 48353 function __ZN23btConvexConvexAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 48354 i1 = i1 | 0;
michael@0 48355 i2 = i2 | 0;
michael@0 48356 i3 = i3 | 0;
michael@0 48357 i4 = i4 | 0;
michael@0 48358 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0;
michael@0 48359 i5 = HEAP32[i2 >> 2] | 0;
michael@0 48360 i6 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i5 >> 2] | 0) + 56 >> 2] & 63](i5, 36) | 0;
michael@0 48361 if ((i6 | 0) == 0) {
michael@0 48362 i7 = 0;
michael@0 48363 i8 = i7 | 0;
michael@0 48364 return i8 | 0;
michael@0 48365 }
michael@0 48366 i5 = HEAP32[i2 + 4 >> 2] | 0;
michael@0 48367 i9 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 48368 i10 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 48369 i11 = HEAP32[i1 + 16 >> 2] | 0;
michael@0 48370 i12 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 48371 __ZN30btActivatingCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i6, i2, i3, i4);
michael@0 48372 HEAP32[i6 >> 2] = 3464;
michael@0 48373 HEAP32[i6 + 8 >> 2] = i9;
michael@0 48374 HEAP32[i6 + 12 >> 2] = i10;
michael@0 48375 HEAP8[i6 + 16 | 0] = 0;
michael@0 48376 HEAP32[i6 + 20 >> 2] = i5;
michael@0 48377 HEAP8[i6 + 24 | 0] = 0;
michael@0 48378 HEAP32[i6 + 28 >> 2] = i11;
michael@0 48379 HEAP32[i6 + 32 >> 2] = i12;
michael@0 48380 i7 = i6;
michael@0 48381 i8 = i7 | 0;
michael@0 48382 return i8 | 0;
michael@0 48383 }
michael@0 48384 function __ZNK10btBoxShape7getEdgeEiR9btVector3S1_(i1, i2, i3, i4) {
michael@0 48385 i1 = i1 | 0;
michael@0 48386 i2 = i2 | 0;
michael@0 48387 i3 = i3 | 0;
michael@0 48388 i4 = i4 | 0;
michael@0 48389 var i5 = 0, i6 = 0;
michael@0 48390 switch (i2 | 0) {
michael@0 48391 case 0:
michael@0 48392 {
michael@0 48393 i5 = 1;
michael@0 48394 i6 = 0;
michael@0 48395 break;
michael@0 48396 }
michael@0 48397 case 11:
michael@0 48398 {
michael@0 48399 i5 = 7;
michael@0 48400 i6 = 6;
michael@0 48401 break;
michael@0 48402 }
michael@0 48403 case 2:
michael@0 48404 {
michael@0 48405 i5 = 3;
michael@0 48406 i6 = 1;
michael@0 48407 break;
michael@0 48408 }
michael@0 48409 case 5:
michael@0 48410 {
michael@0 48411 i5 = i2;
michael@0 48412 i6 = 1;
michael@0 48413 break;
michael@0 48414 }
michael@0 48415 case 4:
michael@0 48416 {
michael@0 48417 i5 = i2;
michael@0 48418 i6 = 0;
michael@0 48419 break;
michael@0 48420 }
michael@0 48421 case 3:
michael@0 48422 {
michael@0 48423 i5 = i2;
michael@0 48424 i6 = 2;
michael@0 48425 break;
michael@0 48426 }
michael@0 48427 case 6:
michael@0 48428 {
michael@0 48429 i5 = i2;
michael@0 48430 i6 = 2;
michael@0 48431 break;
michael@0 48432 }
michael@0 48433 case 7:
michael@0 48434 {
michael@0 48435 i5 = i2;
michael@0 48436 i6 = 3;
michael@0 48437 break;
michael@0 48438 }
michael@0 48439 case 1:
michael@0 48440 {
michael@0 48441 i5 = 2;
michael@0 48442 i6 = 0;
michael@0 48443 break;
michael@0 48444 }
michael@0 48445 case 8:
michael@0 48446 {
michael@0 48447 i5 = 5;
michael@0 48448 i6 = 4;
michael@0 48449 break;
michael@0 48450 }
michael@0 48451 case 9:
michael@0 48452 {
michael@0 48453 i5 = 6;
michael@0 48454 i6 = 4;
michael@0 48455 break;
michael@0 48456 }
michael@0 48457 case 10:
michael@0 48458 {
michael@0 48459 i5 = 7;
michael@0 48460 i6 = 5;
michael@0 48461 break;
michael@0 48462 }
michael@0 48463 default:
michael@0 48464 {
michael@0 48465 i5 = 0;
michael@0 48466 i6 = 0;
michael@0 48467 }
michael@0 48468 }
michael@0 48469 i2 = i1;
michael@0 48470 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i2 >> 2] | 0) + 100 >> 2] & 127](i1, i6, i3);
michael@0 48471 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i2 >> 2] | 0) + 100 >> 2] & 127](i1, i5, i4);
michael@0 48472 return;
michael@0 48473 }
michael@0 48474 function __ZN16btDbvtBroadphaseC2EP22btOverlappingPairCache(i1, i2) {
michael@0 48475 i1 = i1 | 0;
michael@0 48476 i2 = i2 | 0;
michael@0 48477 var i3 = 0, i4 = 0, i5 = 0;
michael@0 48478 HEAP32[i1 >> 2] = 4392;
michael@0 48479 __ZN6btDbvtC2Ev(i1 + 4 | 0);
michael@0 48480 __ZN6btDbvtC2Ev(i1 + 44 | 0);
michael@0 48481 HEAP8[i1 + 153 | 0] = 0;
michael@0 48482 HEAP8[i1 + 154 | 0] = 1;
michael@0 48483 i3 = (i2 | 0) != 0;
michael@0 48484 HEAP8[i1 + 152 | 0] = i3 & 1 ^ 1;
michael@0 48485 HEAPF32[i1 + 100 >> 2] = 0.0;
michael@0 48486 HEAP32[i1 + 104 >> 2] = 0;
michael@0 48487 HEAP32[i1 + 124 >> 2] = 0;
michael@0 48488 HEAP32[i1 + 108 >> 2] = 1;
michael@0 48489 HEAP32[i1 + 112 >> 2] = 0;
michael@0 48490 HEAP32[i1 + 116 >> 2] = 10;
michael@0 48491 HEAP32[i1 + 120 >> 2] = 1;
michael@0 48492 HEAP32[i1 + 128 >> 2] = 0;
michael@0 48493 HEAP32[i1 + 132 >> 2] = 0;
michael@0 48494 HEAPF32[i1 + 136 >> 2] = 0.0;
michael@0 48495 if (i3) {
michael@0 48496 i4 = i2;
michael@0 48497 } else {
michael@0 48498 i2 = __Z22btAlignedAllocInternalji(76, 16) | 0;
michael@0 48499 if ((i2 | 0) == 0) {
michael@0 48500 i5 = 0;
michael@0 48501 } else {
michael@0 48502 i3 = i2;
michael@0 48503 __ZN28btHashedOverlappingPairCacheC2Ev(i3);
michael@0 48504 i5 = i3;
michael@0 48505 }
michael@0 48506 i4 = i5 | 0;
michael@0 48507 }
michael@0 48508 HEAP32[i1 + 96 >> 2] = i4;
michael@0 48509 HEAP32[i1 + 148 >> 2] = 0;
michael@0 48510 HEAP32[i1 + 140 >> 2] = 0;
michael@0 48511 HEAP32[i1 + 144 >> 2] = 0;
michael@0 48512 _memset(i1 + 84 | 0, 0, 12);
michael@0 48513 return;
michael@0 48514 }
michael@0 48515 function __ZN16btDbvtBroadphase8aabbTestERK9btVector3S2_R24btBroadphaseAabbCallback(i1, i2, i3, i4) {
michael@0 48516 i1 = i1 | 0;
michael@0 48517 i2 = i2 | 0;
michael@0 48518 i3 = i3 | 0;
michael@0 48519 i4 = i4 | 0;
michael@0 48520 var i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 48521 i5 = STACKTOP;
michael@0 48522 STACKTOP = STACKTOP + 40 | 0;
michael@0 48523 i6 = i5 | 0;
michael@0 48524 i7 = i5 + 8 | 0;
michael@0 48525 HEAP32[i6 >> 2] = 3936;
michael@0 48526 HEAP32[i6 + 4 >> 2] = i4;
michael@0 48527 i4 = i7;
michael@0 48528 i8 = i2;
michael@0 48529 HEAP32[i4 >> 2] = HEAP32[i8 >> 2];
michael@0 48530 HEAP32[i4 + 4 >> 2] = HEAP32[i8 + 4 >> 2];
michael@0 48531 HEAP32[i4 + 8 >> 2] = HEAP32[i8 + 8 >> 2];
michael@0 48532 HEAP32[i4 + 12 >> 2] = HEAP32[i8 + 12 >> 2];
michael@0 48533 i8 = i7 + 16 | 0;
michael@0 48534 i4 = i3;
michael@0 48535 HEAP32[i8 >> 2] = HEAP32[i4 >> 2];
michael@0 48536 HEAP32[i8 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 48537 HEAP32[i8 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 48538 HEAP32[i8 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 48539 i4 = i6 | 0;
michael@0 48540 __ZN6btDbvt9collideTVEPK10btDbvtNodeRK12btDbvtAabbMmRNS_8ICollideE(0, HEAP32[i1 + 4 >> 2] | 0, i7, i4);
michael@0 48541 __ZN6btDbvt9collideTVEPK10btDbvtNodeRK12btDbvtAabbMmRNS_8ICollideE(0, HEAP32[i1 + 44 >> 2] | 0, i7, i4);
michael@0 48542 STACKTOP = i5;
michael@0 48543 return;
michael@0 48544 }
michael@0 48545 function __ZN10btBoxShape9setMarginEf(i1, d2) {
michael@0 48546 i1 = i1 | 0;
michael@0 48547 d2 = +d2;
michael@0 48548 var i3 = 0, i4 = 0, d5 = 0.0, d6 = 0.0, d7 = 0.0, i8 = 0, d9 = 0.0, i10 = 0, i11 = 0, d12 = 0.0;
michael@0 48549 i3 = i1 | 0;
michael@0 48550 i4 = i1;
michael@0 48551 d5 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48552 d6 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48553 d7 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48554 i8 = i1 + 28 | 0;
michael@0 48555 d9 = d5 + +HEAPF32[i8 >> 2];
michael@0 48556 i10 = i1 + 32 | 0;
michael@0 48557 d5 = d6 + +HEAPF32[i10 >> 2];
michael@0 48558 i11 = i1 + 36 | 0;
michael@0 48559 d6 = d7 + +HEAPF32[i11 >> 2];
michael@0 48560 HEAPF32[i1 + 44 >> 2] = d2;
michael@0 48561 d2 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48562 d7 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48563 d12 = d6 - +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 48564 HEAPF32[i8 >> 2] = d9 - d2;
michael@0 48565 HEAPF32[i10 >> 2] = d5 - d7;
michael@0 48566 HEAPF32[i11 >> 2] = d12;
michael@0 48567 HEAPF32[i1 + 40 >> 2] = 0.0;
michael@0 48568 return;
michael@0 48569 }
michael@0 48570 function __ZNK21btConvexInternalShape24localGetSupportingVertexERK9btVector3(i1, i2, i3) {
michael@0 48571 i1 = i1 | 0;
michael@0 48572 i2 = i2 | 0;
michael@0 48573 i3 = i3 | 0;
michael@0 48574 var i4 = 0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0;
michael@0 48575 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i2 >> 2] | 0) + 64 >> 2] & 127](i1, i2 | 0, i3);
michael@0 48576 i4 = i2;
michael@0 48577 if (+FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i2) == 0.0) {
michael@0 48578 return;
michael@0 48579 }
michael@0 48580 d5 = +HEAPF32[i3 >> 2];
michael@0 48581 d6 = +HEAPF32[i3 + 4 >> 2];
michael@0 48582 d7 = +HEAPF32[i3 + 8 >> 2];
michael@0 48583 i3 = d5 * d5 + d6 * d6 + d7 * d7 < 1.4210854715202004e-14;
michael@0 48584 d8 = i3 ? -1.0 : d7;
michael@0 48585 d7 = i3 ? -1.0 : d6;
michael@0 48586 d6 = i3 ? -1.0 : d5;
michael@0 48587 d5 = 1.0 / +Math_sqrt(+(d8 * d8 + (d6 * d6 + d7 * d7)));
michael@0 48588 d9 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i2);
michael@0 48589 i2 = i1 | 0;
michael@0 48590 HEAPF32[i2 >> 2] = d5 * d6 * d9 + +HEAPF32[i2 >> 2];
michael@0 48591 i2 = i1 + 4 | 0;
michael@0 48592 HEAPF32[i2 >> 2] = d9 * d5 * d7 + +HEAPF32[i2 >> 2];
michael@0 48593 i2 = i1 + 8 | 0;
michael@0 48594 HEAPF32[i2 >> 2] = d9 * d5 * d8 + +HEAPF32[i2 >> 2];
michael@0 48595 return;
michael@0 48596 }
michael@0 48597 function __ZN31btConvexPlaneCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_bii(i1, i2, i3, i4, i5, i6, i7, i8) {
michael@0 48598 i1 = i1 | 0;
michael@0 48599 i2 = i2 | 0;
michael@0 48600 i3 = i3 | 0;
michael@0 48601 i4 = i4 | 0;
michael@0 48602 i5 = i5 | 0;
michael@0 48603 i6 = i6 | 0;
michael@0 48604 i7 = i7 | 0;
michael@0 48605 i8 = i8 | 0;
michael@0 48606 var i9 = 0;
michael@0 48607 __ZN20btCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfo(i1 | 0, i3);
michael@0 48608 HEAP32[i1 >> 2] = 2656;
michael@0 48609 i3 = i1 + 8 | 0;
michael@0 48610 HEAP8[i3] = 0;
michael@0 48611 i9 = i1 + 12 | 0;
michael@0 48612 HEAP32[i9 >> 2] = i2;
michael@0 48613 HEAP8[i1 + 16 | 0] = i6 & 1;
michael@0 48614 HEAP32[i1 + 20 >> 2] = i7;
michael@0 48615 HEAP32[i1 + 24 >> 2] = i8;
michael@0 48616 i8 = i6 ? i5 : i4;
michael@0 48617 i7 = i6 ? i4 : i5;
michael@0 48618 if ((i2 | 0) != 0) {
michael@0 48619 return;
michael@0 48620 }
michael@0 48621 i2 = i1 + 4 | 0;
michael@0 48622 i1 = HEAP32[i2 >> 2] | 0;
michael@0 48623 if (!(FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 24 >> 2] & 31](i1, i8, i7) | 0)) {
michael@0 48624 return;
michael@0 48625 }
michael@0 48626 i1 = HEAP32[i2 >> 2] | 0;
michael@0 48627 HEAP32[i9 >> 2] = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 12 >> 2] & 31](i1, i8, i7) | 0;
michael@0 48628 HEAP8[i3] = 1;
michael@0 48629 return;
michael@0 48630 }
michael@0 48631 function __ZN23btDiscreteDynamicsWorld10setGravityERK9btVector3(i1, i2) {
michael@0 48632 i1 = i1 | 0;
michael@0 48633 i2 = i2 | 0;
michael@0 48634 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 48635 i3 = i1 + 220 | 0;
michael@0 48636 i4 = i2;
michael@0 48637 HEAP32[i3 >> 2] = HEAP32[i4 >> 2];
michael@0 48638 HEAP32[i3 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 48639 HEAP32[i3 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 48640 HEAP32[i3 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 48641 i4 = i1 + 204 | 0;
michael@0 48642 i3 = HEAP32[i4 >> 2] | 0;
michael@0 48643 if ((i3 | 0) <= 0) {
michael@0 48644 return;
michael@0 48645 }
michael@0 48646 i5 = i1 + 212 | 0;
michael@0 48647 i1 = 0;
michael@0 48648 i6 = i3;
michael@0 48649 while (1) {
michael@0 48650 i3 = HEAP32[(HEAP32[i5 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 48651 i7 = HEAP32[i3 + 216 >> 2] | 0;
michael@0 48652 do {
michael@0 48653 if ((i7 | 0) == 5 | (i7 | 0) == 2) {
michael@0 48654 i8 = i6;
michael@0 48655 } else {
michael@0 48656 if ((HEAP32[i3 + 496 >> 2] & 1 | 0) != 0) {
michael@0 48657 i8 = i6;
michael@0 48658 break;
michael@0 48659 }
michael@0 48660 __ZN11btRigidBody10setGravityERK9btVector3(i3, i2);
michael@0 48661 i8 = HEAP32[i4 >> 2] | 0;
michael@0 48662 }
michael@0 48663 } while (0);
michael@0 48664 i3 = i1 + 1 | 0;
michael@0 48665 if ((i3 | 0) < (i8 | 0)) {
michael@0 48666 i1 = i3;
michael@0 48667 i6 = i8;
michael@0 48668 } else {
michael@0 48669 break;
michael@0 48670 }
michael@0 48671 }
michael@0 48672 return;
michael@0 48673 }
michael@0 48674 function __ZN21btCollisionDispatcherC2EP24btCollisionConfiguration(i1, i2) {
michael@0 48675 i1 = i1 | 0;
michael@0 48676 i2 = i2 | 0;
michael@0 48677 var i3 = 0, i4 = 0, i5 = 0;
michael@0 48678 HEAP32[i1 >> 2] = 3784;
michael@0 48679 HEAP32[i1 + 4 >> 2] = 2;
michael@0 48680 HEAP8[i1 + 24 | 0] = 1;
michael@0 48681 HEAP32[i1 + 20 >> 2] = 0;
michael@0 48682 HEAP32[i1 + 12 >> 2] = 0;
michael@0 48683 HEAP32[i1 + 16 >> 2] = 0;
michael@0 48684 HEAP32[i1 + 28 >> 2] = 4312;
michael@0 48685 _memset(i1 + 172 | 0, -1 | 0, 16);
michael@0 48686 i3 = i1 + 5384 | 0;
michael@0 48687 HEAP32[i3 >> 2] = i2;
michael@0 48688 HEAP32[i1 + 188 >> 2] = 20;
michael@0 48689 i4 = i2;
michael@0 48690 HEAP32[i1 + 192 >> 2] = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i4 >> 2] | 0) + 12 >> 2] & 127](i2) | 0;
michael@0 48691 HEAP32[i1 + 196 >> 2] = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i4 >> 2] | 0) + 8 >> 2] & 127](i2) | 0;
michael@0 48692 i2 = 0;
michael@0 48693 do {
michael@0 48694 i4 = 0;
michael@0 48695 do {
michael@0 48696 i5 = HEAP32[i3 >> 2] | 0;
michael@0 48697 HEAP32[i1 + 200 + (i2 * 144 | 0) + (i4 << 2) >> 2] = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i5 >> 2] | 0) + 20 >> 2] & 31](i5, i2, i4) | 0;
michael@0 48698 i4 = i4 + 1 | 0;
michael@0 48699 } while ((i4 | 0) < 36);
michael@0 48700 i2 = i2 + 1 | 0;
michael@0 48701 } while ((i2 | 0) < 36);
michael@0 48702 return;
michael@0 48703 }
michael@0 48704 function __ZN16btCollisionWorldC2EP12btDispatcherP21btBroadphaseInterfaceP24btCollisionConfiguration(i1, i2, i3, i4) {
michael@0 48705 i1 = i1 | 0;
michael@0 48706 i2 = i2 | 0;
michael@0 48707 i3 = i3 | 0;
michael@0 48708 i4 = i4 | 0;
michael@0 48709 HEAP32[i1 >> 2] = 4464;
michael@0 48710 HEAP8[i1 + 20 | 0] = 1;
michael@0 48711 HEAP32[i1 + 16 >> 2] = 0;
michael@0 48712 HEAP32[i1 + 8 >> 2] = 0;
michael@0 48713 HEAP32[i1 + 12 >> 2] = 0;
michael@0 48714 HEAP32[i1 + 24 >> 2] = i2;
michael@0 48715 HEAPF32[i1 + 28 >> 2] = 0.0;
michael@0 48716 HEAP32[i1 + 32 >> 2] = 0;
michael@0 48717 HEAP32[i1 + 36 >> 2] = 1;
michael@0 48718 HEAPF32[i1 + 40 >> 2] = 1.0;
michael@0 48719 HEAP8[i1 + 44 | 0] = 1;
michael@0 48720 HEAP32[i1 + 48 >> 2] = 0;
michael@0 48721 HEAP8[i1 + 52 | 0] = 0;
michael@0 48722 HEAP8[i1 + 53 | 0] = 1;
michael@0 48723 HEAP8[i1 + 54 | 0] = 1;
michael@0 48724 HEAPF32[i1 + 56 >> 2] = .03999999910593033;
michael@0 48725 HEAP8[i1 + 60 | 0] = 0;
michael@0 48726 HEAPF32[i1 + 64 >> 2] = 0.0;
michael@0 48727 i2 = i1 + 68 | 0;
michael@0 48728 HEAP32[i2 >> 2] = 0;
michael@0 48729 HEAP32[i1 + 76 >> 2] = i3;
michael@0 48730 HEAP32[i1 + 80 >> 2] = 0;
michael@0 48731 HEAP8[i1 + 84 | 0] = 1;
michael@0 48732 i3 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i4 >> 2] | 0) + 16 >> 2] & 127](i4) | 0;
michael@0 48733 HEAP32[i1 + 72 >> 2] = i3;
michael@0 48734 HEAP32[i2 >> 2] = i3;
michael@0 48735 return;
michael@0 48736 }
michael@0 48737 function __ZN16btCollisionWorld33performDiscreteCollisionDetectionEv(i1) {
michael@0 48738 i1 = i1 | 0;
michael@0 48739 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 48740 __ZN15CProfileManager13Start_ProfileEPKc(272);
michael@0 48741 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 511](i1);
michael@0 48742 __ZN15CProfileManager13Start_ProfileEPKc(208);
michael@0 48743 i2 = i1 + 76 | 0;
michael@0 48744 i3 = HEAP32[i2 >> 2] | 0;
michael@0 48745 i4 = i1 + 24 | 0;
michael@0 48746 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 32 >> 2] & 127](i3, HEAP32[i4 >> 2] | 0);
michael@0 48747 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 48748 i3 = HEAP32[i4 >> 2] | 0;
michael@0 48749 __ZN15CProfileManager13Start_ProfileEPKc(144);
michael@0 48750 if ((i3 | 0) != 0) {
michael@0 48751 i5 = HEAP32[(HEAP32[i3 >> 2] | 0) + 32 >> 2] | 0;
michael@0 48752 i6 = HEAP32[i2 >> 2] | 0;
michael@0 48753 i2 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i6 >> 2] | 0) + 36 >> 2] & 127](i6) | 0;
michael@0 48754 FUNCTION_TABLE_viiii[i5 & 127](i3, i2, i1 + 28 | 0, HEAP32[i4 >> 2] | 0);
michael@0 48755 }
michael@0 48756 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 48757 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 48758 return;
michael@0 48759 }
michael@0 48760 function __ZN16btCollisionWorld11updateAabbsEv(i1) {
michael@0 48761 i1 = i1 | 0;
michael@0 48762 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0;
michael@0 48763 __ZN15CProfileManager13Start_ProfileEPKc(440);
michael@0 48764 i2 = i1 + 8 | 0;
michael@0 48765 i3 = HEAP32[i2 >> 2] | 0;
michael@0 48766 if ((i3 | 0) <= 0) {
michael@0 48767 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 48768 return;
michael@0 48769 }
michael@0 48770 i4 = i1 + 16 | 0;
michael@0 48771 i5 = i1 + 84 | 0;
michael@0 48772 i6 = 0;
michael@0 48773 i7 = i3;
michael@0 48774 while (1) {
michael@0 48775 i3 = HEAP32[(HEAP32[i4 >> 2] | 0) + (i6 << 2) >> 2] | 0;
michael@0 48776 if ((HEAP8[i5] | 0) == 0) {
michael@0 48777 i8 = HEAP32[i3 + 216 >> 2] | 0;
michael@0 48778 if ((i8 | 0) == 5 | (i8 | 0) == 2) {
michael@0 48779 i9 = i7;
michael@0 48780 } else {
michael@0 48781 i10 = 2061;
michael@0 48782 }
michael@0 48783 } else {
michael@0 48784 i10 = 2061;
michael@0 48785 }
michael@0 48786 if ((i10 | 0) == 2061) {
michael@0 48787 i10 = 0;
michael@0 48788 __ZN16btCollisionWorld16updateSingleAabbEP17btCollisionObject(i1, i3);
michael@0 48789 i9 = HEAP32[i2 >> 2] | 0;
michael@0 48790 }
michael@0 48791 i3 = i6 + 1 | 0;
michael@0 48792 if ((i3 | 0) < (i9 | 0)) {
michael@0 48793 i6 = i3;
michael@0 48794 i7 = i9;
michael@0 48795 } else {
michael@0 48796 break;
michael@0 48797 }
michael@0 48798 }
michael@0 48799 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 48800 return;
michael@0 48801 }
michael@0 48802 function __ZNK10__cxxabiv117__class_type_info9can_catchEPKNS_16__shim_type_infoERPv(i1, i2, i3) {
michael@0 48803 i1 = i1 | 0;
michael@0 48804 i2 = i2 | 0;
michael@0 48805 i3 = i3 | 0;
michael@0 48806 var i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 48807 i4 = STACKTOP;
michael@0 48808 STACKTOP = STACKTOP + 56 | 0;
michael@0 48809 i5 = i4 | 0;
michael@0 48810 if ((i1 | 0) == (i2 | 0)) {
michael@0 48811 i6 = 1;
michael@0 48812 STACKTOP = i4;
michael@0 48813 return i6 | 0;
michael@0 48814 }
michael@0 48815 if ((i2 | 0) == 0) {
michael@0 48816 i6 = 0;
michael@0 48817 STACKTOP = i4;
michael@0 48818 return i6 | 0;
michael@0 48819 }
michael@0 48820 i7 = ___dynamic_cast(i2, 10880, 10864, -1) | 0;
michael@0 48821 i2 = i7;
michael@0 48822 if ((i7 | 0) == 0) {
michael@0 48823 i6 = 0;
michael@0 48824 STACKTOP = i4;
michael@0 48825 return i6 | 0;
michael@0 48826 }
michael@0 48827 _memset(i5 | 0, 0, 56);
michael@0 48828 HEAP32[i5 >> 2] = i2;
michael@0 48829 HEAP32[i5 + 8 >> 2] = i1;
michael@0 48830 HEAP32[i5 + 12 >> 2] = -1;
michael@0 48831 HEAP32[i5 + 48 >> 2] = 1;
michael@0 48832 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i7 >> 2] | 0) + 28 >> 2] & 127](i2, i5, HEAP32[i3 >> 2] | 0, 1);
michael@0 48833 if ((HEAP32[i5 + 24 >> 2] | 0) != 1) {
michael@0 48834 i6 = 0;
michael@0 48835 STACKTOP = i4;
michael@0 48836 return i6 | 0;
michael@0 48837 }
michael@0 48838 HEAP32[i3 >> 2] = HEAP32[i5 + 16 >> 2];
michael@0 48839 i6 = 1;
michael@0 48840 STACKTOP = i4;
michael@0 48841 return i6 | 0;
michael@0 48842 }
michael@0 48843 function __ZNK20btPersistentManifold13getCacheEntryERK15btManifoldPoint(i1, i2) {
michael@0 48844 i1 = i1 | 0;
michael@0 48845 i2 = i2 | 0;
michael@0 48846 var d3 = 0.0, i4 = 0, i5 = 0, d6 = 0.0, d7 = 0.0, d8 = 0.0, i9 = 0, d10 = 0.0, d11 = 0.0, d12 = 0.0, d13 = 0.0, i14 = 0, i15 = 0, i16 = 0;
michael@0 48847 d3 = +HEAPF32[i1 + 1120 >> 2];
michael@0 48848 i4 = HEAP32[i1 + 1116 >> 2] | 0;
michael@0 48849 if ((i4 | 0) <= 0) {
michael@0 48850 i5 = -1;
michael@0 48851 return i5 | 0;
michael@0 48852 }
michael@0 48853 d6 = +HEAPF32[i2 >> 2];
michael@0 48854 d7 = +HEAPF32[i2 + 4 >> 2];
michael@0 48855 d8 = +HEAPF32[i2 + 8 >> 2];
michael@0 48856 i2 = 0;
michael@0 48857 i9 = -1;
michael@0 48858 d10 = d3 * d3;
michael@0 48859 while (1) {
michael@0 48860 d3 = +HEAPF32[i1 + 4 + (i2 * 276 | 0) >> 2] - d6;
michael@0 48861 d11 = +HEAPF32[i1 + 4 + (i2 * 276 | 0) + 4 >> 2] - d7;
michael@0 48862 d12 = +HEAPF32[i1 + 4 + (i2 * 276 | 0) + 8 >> 2] - d8;
michael@0 48863 d13 = d3 * d3 + d11 * d11 + d12 * d12;
michael@0 48864 i14 = d13 < d10;
michael@0 48865 i15 = i14 ? i2 : i9;
michael@0 48866 i16 = i2 + 1 | 0;
michael@0 48867 if ((i16 | 0) < (i4 | 0)) {
michael@0 48868 i2 = i16;
michael@0 48869 i9 = i15;
michael@0 48870 d10 = i14 ? d13 : d10;
michael@0 48871 } else {
michael@0 48872 i5 = i15;
michael@0 48873 break;
michael@0 48874 }
michael@0 48875 }
michael@0 48876 return i5 | 0;
michael@0 48877 }
michael@0 48878 function __ZNK13btSphereShape7getAabbERK11btTransformR9btVector3S4_(i1, i2, i3, i4) {
michael@0 48879 i1 = i1 | 0;
michael@0 48880 i2 = i2 | 0;
michael@0 48881 i3 = i3 | 0;
michael@0 48882 i4 = i4 | 0;
michael@0 48883 var i5 = 0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, i10 = 0, d11 = 0.0;
michael@0 48884 i5 = i1;
michael@0 48885 d6 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i5 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 48886 d7 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i5 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 48887 d8 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i5 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 48888 i1 = i2 + 48 | 0;
michael@0 48889 i5 = i2 + 52 | 0;
michael@0 48890 d9 = +HEAPF32[i5 >> 2] - d7;
michael@0 48891 i10 = i2 + 56 | 0;
michael@0 48892 d11 = +HEAPF32[i10 >> 2] - d8;
michael@0 48893 HEAPF32[i3 >> 2] = +HEAPF32[i1 >> 2] - d6;
michael@0 48894 HEAPF32[i3 + 4 >> 2] = d9;
michael@0 48895 HEAPF32[i3 + 8 >> 2] = d11;
michael@0 48896 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 48897 d11 = d7 + +HEAPF32[i5 >> 2];
michael@0 48898 d7 = d8 + +HEAPF32[i10 >> 2];
michael@0 48899 HEAPF32[i4 >> 2] = d6 + +HEAPF32[i1 >> 2];
michael@0 48900 HEAPF32[i4 + 4 >> 2] = d11;
michael@0 48901 HEAPF32[i4 + 8 >> 2] = d7;
michael@0 48902 HEAPF32[i4 + 12 >> 2] = 0.0;
michael@0 48903 return;
michael@0 48904 }
michael@0 48905 function __ZN15CProfileManager12Stop_ProfileEv() {
michael@0 48906 var i1 = 0, i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 48907 i1 = STACKTOP;
michael@0 48908 STACKTOP = STACKTOP + 8 | 0;
michael@0 48909 i2 = i1 | 0;
michael@0 48910 i3 = HEAP32[2966] | 0;
michael@0 48911 i4 = i3 + 16 | 0;
michael@0 48912 i5 = (HEAP32[i4 >> 2] | 0) - 1 | 0;
michael@0 48913 HEAP32[i4 >> 2] = i5;
michael@0 48914 if ((i5 | 0) != 0) {
michael@0 48915 STACKTOP = i1;
michael@0 48916 return;
michael@0 48917 }
michael@0 48918 do {
michael@0 48919 if ((HEAP32[i3 + 4 >> 2] | 0) == 0) {
michael@0 48920 i6 = i3;
michael@0 48921 } else {
michael@0 48922 _gettimeofday(i2 | 0, 0) | 0;
michael@0 48923 i5 = HEAP32[3578] | 0;
michael@0 48924 i7 = i3 + 8 | 0;
michael@0 48925 HEAPF32[i7 >> 2] = +(((HEAP32[i2 + 4 >> 2] | 0) - (HEAP32[i5 + 4 >> 2] | 0) + (((HEAP32[i2 >> 2] | 0) - (HEAP32[i5 >> 2] | 0) | 0) * 1e6 | 0) - (HEAP32[i3 + 12 >> 2] | 0) | 0) >>> 0 >>> 0) / 1.0e3 + +HEAPF32[i7 >> 2];
michael@0 48926 if ((HEAP32[i4 >> 2] | 0) == 0) {
michael@0 48927 i6 = HEAP32[2966] | 0;
michael@0 48928 break;
michael@0 48929 } else {
michael@0 48930 STACKTOP = i1;
michael@0 48931 return;
michael@0 48932 }
michael@0 48933 }
michael@0 48934 } while (0);
michael@0 48935 HEAP32[2966] = HEAP32[i6 + 20 >> 2];
michael@0 48936 STACKTOP = i1;
michael@0 48937 return;
michael@0 48938 }
michael@0 48939 function __ZN16btDbvtBroadphase12destroyProxyEP17btBroadphaseProxyP12btDispatcher(i1, i2, i3) {
michael@0 48940 i1 = i1 | 0;
michael@0 48941 i2 = i2 | 0;
michael@0 48942 i3 = i3 | 0;
michael@0 48943 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 48944 i4 = i2 + 60 | 0;
michael@0 48945 if ((HEAP32[i4 >> 2] | 0) == 2) {
michael@0 48946 __ZN6btDbvt6removeEP10btDbvtNode(i1 + 44 | 0, HEAP32[i2 + 48 >> 2] | 0);
michael@0 48947 } else {
michael@0 48948 __ZN6btDbvt6removeEP10btDbvtNode(i1 + 4 | 0, HEAP32[i2 + 48 >> 2] | 0);
michael@0 48949 }
michael@0 48950 i5 = i2 + 52 | 0;
michael@0 48951 i6 = HEAP32[i5 >> 2] | 0;
michael@0 48952 i7 = i2 + 56 | 0;
michael@0 48953 i8 = HEAP32[i7 >> 2] | 0;
michael@0 48954 if ((i6 | 0) == 0) {
michael@0 48955 HEAP32[i1 + 84 + (HEAP32[i4 >> 2] << 2) >> 2] = i8;
michael@0 48956 } else {
michael@0 48957 HEAP32[i6 + 56 >> 2] = i8;
michael@0 48958 }
michael@0 48959 i8 = HEAP32[i7 >> 2] | 0;
michael@0 48960 if ((i8 | 0) != 0) {
michael@0 48961 HEAP32[i8 + 52 >> 2] = HEAP32[i5 >> 2];
michael@0 48962 }
michael@0 48963 i5 = HEAP32[i1 + 96 >> 2] | 0;
michael@0 48964 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i5 >> 2] | 0) + 16 >> 2] & 127](i5 | 0, i2, i3);
michael@0 48965 __Z21btAlignedFreeInternalPv(i2);
michael@0 48966 HEAP8[i1 + 154 | 0] = 1;
michael@0 48967 return;
michael@0 48968 }
michael@0 48969 function __ZN17btCollisionObjectC2Ev(i1) {
michael@0 48970 i1 = i1 | 0;
michael@0 48971 HEAP32[i1 >> 2] = 4168;
michael@0 48972 HEAPF32[i1 + 164 >> 2] = 1.0;
michael@0 48973 HEAPF32[i1 + 168 >> 2] = 1.0;
michael@0 48974 HEAPF32[i1 + 172 >> 2] = 1.0;
michael@0 48975 HEAPF32[i1 + 176 >> 2] = 0.0;
michael@0 48976 HEAP32[i1 + 180 >> 2] = 0;
michael@0 48977 HEAPF32[i1 + 184 >> 2] = 999999984306749400.0;
michael@0 48978 _memset(i1 + 188 | 0, 0, 16);
michael@0 48979 HEAP32[i1 + 204 >> 2] = 1;
michael@0 48980 HEAP32[i1 + 208 >> 2] = -1;
michael@0 48981 HEAP32[i1 + 212 >> 2] = -1;
michael@0 48982 HEAP32[i1 + 216 >> 2] = 1;
michael@0 48983 HEAPF32[i1 + 220 >> 2] = 0.0;
michael@0 48984 HEAPF32[i1 + 224 >> 2] = .5;
michael@0 48985 HEAPF32[i1 + 228 >> 2] = 0.0;
michael@0 48986 HEAP32[i1 + 232 >> 2] = 1;
michael@0 48987 HEAP32[i1 + 236 >> 2] = 0;
michael@0 48988 HEAPF32[i1 + 240 >> 2] = 1.0;
michael@0 48989 HEAPF32[i1 + 244 >> 2] = 0.0;
michael@0 48990 HEAPF32[i1 + 248 >> 2] = 0.0;
michael@0 48991 HEAP32[i1 + 252 >> 2] = 0;
michael@0 48992 HEAPF32[i1 + 4 >> 2] = 1.0;
michael@0 48993 _memset(i1 + 8 | 0, 0, 16);
michael@0 48994 HEAPF32[i1 + 24 >> 2] = 1.0;
michael@0 48995 _memset(i1 + 28 | 0, 0, 16);
michael@0 48996 HEAPF32[i1 + 44 >> 2] = 1.0;
michael@0 48997 _memset(i1 + 48 | 0, 0, 20);
michael@0 48998 return;
michael@0 48999 }
michael@0 49000 function __ZNK15btTriangleShape37localGetSupportingVertexWithoutMarginERK9btVector3(i1, i2, i3) {
michael@0 49001 i1 = i1 | 0;
michael@0 49002 i2 = i2 | 0;
michael@0 49003 i3 = i3 | 0;
michael@0 49004 var d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0, d9 = 0.0, i10 = 0;
michael@0 49005 d4 = +HEAPF32[i3 >> 2];
michael@0 49006 d5 = +HEAPF32[i3 + 4 >> 2];
michael@0 49007 d6 = +HEAPF32[i3 + 8 >> 2];
michael@0 49008 d7 = d4 * +HEAPF32[i2 + 56 >> 2] + d5 * +HEAPF32[i2 + 60 >> 2] + d6 * +HEAPF32[i2 + 64 >> 2];
michael@0 49009 d8 = d4 * +HEAPF32[i2 + 72 >> 2] + d5 * +HEAPF32[i2 + 76 >> 2] + d6 * +HEAPF32[i2 + 80 >> 2];
michael@0 49010 d9 = d4 * +HEAPF32[i2 + 88 >> 2] + d5 * +HEAPF32[i2 + 92 >> 2] + d6 * +HEAPF32[i2 + 96 >> 2];
michael@0 49011 if (d7 < d8) {
michael@0 49012 i10 = d8 < d9 ? 2 : 1;
michael@0 49013 } else {
michael@0 49014 i10 = d7 < d9 ? 2 : 0;
michael@0 49015 }
michael@0 49016 i3 = i1;
michael@0 49017 i1 = i2 + 56 + (i10 << 4) | 0;
michael@0 49018 HEAP32[i3 >> 2] = HEAP32[i1 >> 2];
michael@0 49019 HEAP32[i3 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 49020 HEAP32[i3 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 49021 HEAP32[i3 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 49022 return;
michael@0 49023 }
michael@0 49024 function __ZN11btRigidBody19removeConstraintRefEP17btTypedConstraint(i1, i2) {
michael@0 49025 i1 = i1 | 0;
michael@0 49026 i2 = i2 | 0;
michael@0 49027 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0, i12 = 0, i13 = 0;
michael@0 49028 i3 = i1 + 480 | 0;
michael@0 49029 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49030 i5 = i1 + 488 | 0;
michael@0 49031 i6 = 0;
michael@0 49032 while (1) {
michael@0 49033 if ((i6 | 0) >= (i4 | 0)) {
michael@0 49034 i7 = i4;
michael@0 49035 i8 = 1064;
michael@0 49036 break;
michael@0 49037 }
michael@0 49038 i9 = HEAP32[i5 >> 2] | 0;
michael@0 49039 i10 = i9 + (i6 << 2) | 0;
michael@0 49040 if ((HEAP32[i10 >> 2] | 0) == (i2 | 0)) {
michael@0 49041 break;
michael@0 49042 } else {
michael@0 49043 i6 = i6 + 1 | 0;
michael@0 49044 }
michael@0 49045 }
michael@0 49046 if ((i8 | 0) == 1064) {
michael@0 49047 i11 = (i7 | 0) > 0;
michael@0 49048 i12 = i11 & 1;
michael@0 49049 i13 = i1 + 252 | 0;
michael@0 49050 HEAP32[i13 >> 2] = i12;
michael@0 49051 return;
michael@0 49052 }
michael@0 49053 i8 = i4 - 1 | 0;
michael@0 49054 HEAP32[i10 >> 2] = HEAP32[i9 + (i8 << 2) >> 2];
michael@0 49055 HEAP32[(HEAP32[i5 >> 2] | 0) + (i8 << 2) >> 2] = i2;
michael@0 49056 HEAP32[i3 >> 2] = i8;
michael@0 49057 i7 = i8;
michael@0 49058 i11 = (i7 | 0) > 0;
michael@0 49059 i12 = i11 & 1;
michael@0 49060 i13 = i1 + 252 | 0;
michael@0 49061 HEAP32[i13 >> 2] = i12;
michael@0 49062 return;
michael@0 49063 }
michael@0 49064 function __ZN35btSequentialImpulseConstraintSolver10solveGroupEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAllocP12btDispatcher(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 49065 i1 = i1 | 0;
michael@0 49066 i2 = i2 | 0;
michael@0 49067 i3 = i3 | 0;
michael@0 49068 i4 = i4 | 0;
michael@0 49069 i5 = i5 | 0;
michael@0 49070 i6 = i6 | 0;
michael@0 49071 i7 = i7 | 0;
michael@0 49072 i8 = i8 | 0;
michael@0 49073 i9 = i9 | 0;
michael@0 49074 i10 = i10 | 0;
michael@0 49075 i11 = i11 | 0;
michael@0 49076 __ZN15CProfileManager13Start_ProfileEPKc(584);
michael@0 49077 i11 = i1;
michael@0 49078 +FUNCTION_TABLE_fiiiiiiiiii[HEAP32[(HEAP32[i11 >> 2] | 0) + 32 >> 2] & 7](i1, i2, i3, i4, i5, i6, i7, i8, i9, i10);
michael@0 49079 +FUNCTION_TABLE_fiiiiiiiiii[HEAP32[(HEAP32[i11 >> 2] | 0) + 36 >> 2] & 7](i1, i2, i3, i4, i5, i6, i7, i8, i9, i10);
michael@0 49080 +FUNCTION_TABLE_fiiiiiiiiii[HEAP32[(HEAP32[i11 >> 2] | 0) + 28 >> 2] & 7](i1, i2, i3, i4, i5, i6, i7, i8, i9, i10);
michael@0 49081 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 49082 return +0.0;
michael@0 49083 }
michael@0 49084 function __ZN23btDiscreteDynamicsWorld25predictUnconstraintMotionEf(i1, d2) {
michael@0 49085 i1 = i1 | 0;
michael@0 49086 d2 = +d2;
michael@0 49087 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 49088 __ZN15CProfileManager13Start_ProfileEPKc(848);
michael@0 49089 i3 = i1 + 204 | 0;
michael@0 49090 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49091 if ((i4 | 0) <= 0) {
michael@0 49092 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 49093 return;
michael@0 49094 }
michael@0 49095 i5 = i1 + 212 | 0;
michael@0 49096 i1 = 0;
michael@0 49097 i6 = i4;
michael@0 49098 while (1) {
michael@0 49099 i4 = HEAP32[(HEAP32[i5 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 49100 if ((HEAP32[i4 + 204 >> 2] & 3 | 0) == 0) {
michael@0 49101 __ZN11btRigidBody19integrateVelocitiesEf(i4, d2);
michael@0 49102 __ZN11btRigidBody12applyDampingEf(i4, d2);
michael@0 49103 __ZN11btRigidBody26predictIntegratedTransformEfR11btTransform(i4, d2, i4 + 68 | 0);
michael@0 49104 i7 = HEAP32[i3 >> 2] | 0;
michael@0 49105 } else {
michael@0 49106 i7 = i6;
michael@0 49107 }
michael@0 49108 i4 = i1 + 1 | 0;
michael@0 49109 if ((i4 | 0) < (i7 | 0)) {
michael@0 49110 i1 = i4;
michael@0 49111 i6 = i7;
michael@0 49112 } else {
michael@0 49113 break;
michael@0 49114 }
michael@0 49115 }
michael@0 49116 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 49117 return;
michael@0 49118 }
michael@0 49119 function __ZN33btConvexConcaveCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b(i1, i2, i3, i4, i5) {
michael@0 49120 i1 = i1 | 0;
michael@0 49121 i2 = i2 | 0;
michael@0 49122 i3 = i3 | 0;
michael@0 49123 i4 = i4 | 0;
michael@0 49124 i5 = i5 | 0;
michael@0 49125 var i6 = 0, i7 = 0, i8 = 0;
michael@0 49126 __ZN30btActivatingCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1 | 0, i2, i3, i4);
michael@0 49127 HEAP32[i1 >> 2] = 2528;
michael@0 49128 HEAP8[i1 + 8 | 0] = i5 & 1;
michael@0 49129 i6 = HEAP32[i2 >> 2] | 0;
michael@0 49130 HEAP32[i1 + 12 >> 2] = 3104;
michael@0 49131 i2 = i1 + 60 | 0;
michael@0 49132 HEAP32[i2 >> 2] = i6;
michael@0 49133 HEAP32[i1 + 64 >> 2] = 0;
michael@0 49134 i7 = i5 ? i4 : i3;
michael@0 49135 HEAP32[i1 + 16 >> 2] = i7;
michael@0 49136 i8 = i5 ? i3 : i4;
michael@0 49137 HEAP32[i1 + 20 >> 2] = i8;
michael@0 49138 i4 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 12 >> 2] & 31](i6, i7, i8) | 0;
michael@0 49139 HEAP32[i1 + 76 >> 2] = i4;
michael@0 49140 i1 = HEAP32[i2 >> 2] | 0;
michael@0 49141 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 20 >> 2] & 127](i1, i4);
michael@0 49142 return;
michael@0 49143 }
michael@0 49144 function __ZN25btSimulationIslandManager21updateActivationStateEP16btCollisionWorldP12btDispatcher(i1, i2, i3) {
michael@0 49145 i1 = i1 | 0;
michael@0 49146 i2 = i2 | 0;
michael@0 49147 i3 = i3 | 0;
michael@0 49148 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 49149 i3 = i2 + 8 | 0;
michael@0 49150 if ((HEAP32[i3 >> 2] | 0) > 0) {
michael@0 49151 i4 = HEAP32[i2 + 16 >> 2] | 0;
michael@0 49152 i5 = 0;
michael@0 49153 i6 = 0;
michael@0 49154 while (1) {
michael@0 49155 i7 = HEAP32[i4 + (i5 << 2) >> 2] | 0;
michael@0 49156 if ((HEAP32[i7 + 204 >> 2] & 3 | 0) == 0) {
michael@0 49157 HEAP32[i7 + 208 >> 2] = i6;
michael@0 49158 i8 = i6 + 1 | 0;
michael@0 49159 } else {
michael@0 49160 i8 = i6;
michael@0 49161 }
michael@0 49162 HEAP32[i7 + 212 >> 2] = -1;
michael@0 49163 HEAPF32[i7 + 240 >> 2] = 1.0;
michael@0 49164 i7 = i5 + 1 | 0;
michael@0 49165 if ((i7 | 0) < (HEAP32[i3 >> 2] | 0)) {
michael@0 49166 i5 = i7;
michael@0 49167 i6 = i8;
michael@0 49168 } else {
michael@0 49169 i9 = i8;
michael@0 49170 break;
michael@0 49171 }
michael@0 49172 }
michael@0 49173 } else {
michael@0 49174 i9 = 0;
michael@0 49175 }
michael@0 49176 __ZN11btUnionFind5resetEi(i1 + 4 | 0, i9);
michael@0 49177 __ZN25btSimulationIslandManager10findUnionsEP12btDispatcherP16btCollisionWorld(i1, 0, i2);
michael@0 49178 return;
michael@0 49179 }
michael@0 49180 function __ZNK10btBoxShape24localGetSupportingVertexERK9btVector3(i1, i2, i3) {
michael@0 49181 i1 = i1 | 0;
michael@0 49182 i2 = i2 | 0;
michael@0 49183 i3 = i3 | 0;
michael@0 49184 var d4 = 0.0, d5 = 0.0, d6 = 0.0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0;
michael@0 49185 d4 = +HEAPF32[i2 + 28 >> 2];
michael@0 49186 d5 = +HEAPF32[i2 + 32 >> 2];
michael@0 49187 d6 = +HEAPF32[i2 + 36 >> 2];
michael@0 49188 i7 = i2 | 0;
michael@0 49189 i8 = i2;
michael@0 49190 d9 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49191 d10 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49192 d11 = d4 + d9;
michael@0 49193 d9 = d5 + d10;
michael@0 49194 d10 = d6 + +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49195 d6 = +HEAPF32[i3 + 4 >> 2] >= 0.0 ? d9 : -0.0 - d9;
michael@0 49196 d9 = +HEAPF32[i3 + 8 >> 2] >= 0.0 ? d10 : -0.0 - d10;
michael@0 49197 HEAPF32[i1 >> 2] = +HEAPF32[i3 >> 2] >= 0.0 ? d11 : -0.0 - d11;
michael@0 49198 HEAPF32[i1 + 4 >> 2] = d6;
michael@0 49199 HEAPF32[i1 + 8 >> 2] = d9;
michael@0 49200 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 49201 return;
michael@0 49202 }
michael@0 49203 function __ZNK10btBoxShape9getVertexEiR9btVector3(i1, i2, i3) {
michael@0 49204 i1 = i1 | 0;
michael@0 49205 i2 = i2 | 0;
michael@0 49206 i3 = i3 | 0;
michael@0 49207 var d4 = 0.0, d5 = 0.0, d6 = 0.0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0;
michael@0 49208 d4 = +HEAPF32[i1 + 28 >> 2];
michael@0 49209 d5 = +HEAPF32[i1 + 32 >> 2];
michael@0 49210 d6 = +HEAPF32[i1 + 36 >> 2];
michael@0 49211 i7 = i1 | 0;
michael@0 49212 i8 = i1;
michael@0 49213 d9 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49214 d10 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49215 d11 = d4 + d9;
michael@0 49216 d9 = d5 + d10;
michael@0 49217 d10 = d6 + +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49218 i7 = i2 & 1;
michael@0 49219 i8 = i2 >>> 1 & 1;
michael@0 49220 i1 = i2 >>> 2 & 1;
michael@0 49221 HEAPF32[i3 >> 2] = +(i7 ^ 1 | 0) * d11 - +(i7 | 0) * d11;
michael@0 49222 HEAPF32[i3 + 4 >> 2] = +(i8 ^ 1 | 0) * d9 - +(i8 | 0) * d9;
michael@0 49223 HEAPF32[i3 + 8 >> 2] = +(i1 ^ 1 | 0) * d10 - +(i1 | 0) * d10;
michael@0 49224 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 49225 return;
michael@0 49226 }
michael@0 49227 function __ZNK10btBoxShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i(i1, i2, i3, i4) {
michael@0 49228 i1 = i1 | 0;
michael@0 49229 i2 = i2 | 0;
michael@0 49230 i3 = i3 | 0;
michael@0 49231 i4 = i4 | 0;
michael@0 49232 var i5 = 0, i6 = 0, i7 = 0, d8 = 0.0, d9 = 0.0, d10 = 0.0, d11 = 0.0;
michael@0 49233 if ((i4 | 0) <= 0) {
michael@0 49234 return;
michael@0 49235 }
michael@0 49236 i5 = i1 + 28 | 0;
michael@0 49237 i6 = i1 + 32 | 0;
michael@0 49238 i7 = i1 + 36 | 0;
michael@0 49239 i1 = 0;
michael@0 49240 do {
michael@0 49241 d8 = +HEAPF32[i5 >> 2];
michael@0 49242 d9 = +HEAPF32[i6 >> 2];
michael@0 49243 d10 = +HEAPF32[i2 + (i1 << 4) + 4 >> 2] >= 0.0 ? d9 : -0.0 - d9;
michael@0 49244 d9 = +HEAPF32[i7 >> 2];
michael@0 49245 d11 = +HEAPF32[i2 + (i1 << 4) + 8 >> 2] >= 0.0 ? d9 : -0.0 - d9;
michael@0 49246 HEAPF32[i3 + (i1 << 4) >> 2] = +HEAPF32[i2 + (i1 << 4) >> 2] >= 0.0 ? d8 : -0.0 - d8;
michael@0 49247 HEAPF32[i3 + (i1 << 4) + 4 >> 2] = d10;
michael@0 49248 HEAPF32[i3 + (i1 << 4) + 8 >> 2] = d11;
michael@0 49249 HEAPF32[i3 + (i1 << 4) + 12 >> 2] = 0.0;
michael@0 49250 i1 = i1 + 1 | 0;
michael@0 49251 } while ((i1 | 0) < (i4 | 0));
michael@0 49252 return;
michael@0 49253 }
michael@0 49254 function __ZN23btDiscreteDynamicsWorld18saveKinematicStateEf(i1, d2) {
michael@0 49255 i1 = i1 | 0;
michael@0 49256 d2 = +d2;
michael@0 49257 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 49258 i3 = i1 + 8 | 0;
michael@0 49259 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49260 if ((i4 | 0) <= 0) {
michael@0 49261 return;
michael@0 49262 }
michael@0 49263 i5 = i1 + 16 | 0;
michael@0 49264 i1 = 0;
michael@0 49265 i6 = i4;
michael@0 49266 while (1) {
michael@0 49267 i4 = HEAP32[(HEAP32[i5 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 49268 do {
michael@0 49269 if ((HEAP32[i4 + 232 >> 2] & 2 | 0) == 0) {
michael@0 49270 i7 = i6;
michael@0 49271 } else {
michael@0 49272 if ((i4 | 0) == 0) {
michael@0 49273 i7 = i6;
michael@0 49274 break;
michael@0 49275 }
michael@0 49276 if ((HEAP32[i4 + 216 >> 2] | 0) == 2) {
michael@0 49277 i7 = i6;
michael@0 49278 break;
michael@0 49279 }
michael@0 49280 if ((HEAP32[i4 + 204 >> 2] & 2 | 0) == 0) {
michael@0 49281 i7 = i6;
michael@0 49282 break;
michael@0 49283 }
michael@0 49284 __ZN11btRigidBody18saveKinematicStateEf(i4, d2);
michael@0 49285 i7 = HEAP32[i3 >> 2] | 0;
michael@0 49286 }
michael@0 49287 } while (0);
michael@0 49288 i4 = i1 + 1 | 0;
michael@0 49289 if ((i4 | 0) < (i7 | 0)) {
michael@0 49290 i1 = i4;
michael@0 49291 i6 = i7;
michael@0 49292 } else {
michael@0 49293 break;
michael@0 49294 }
michael@0 49295 }
michael@0 49296 return;
michael@0 49297 }
michael@0 49298 function __ZN23btDiscreteDynamicsWorld16removeConstraintEP17btTypedConstraint(i1, i2) {
michael@0 49299 i1 = i1 | 0;
michael@0 49300 i2 = i2 | 0;
michael@0 49301 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 49302 i3 = i1 + 184 | 0;
michael@0 49303 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49304 i5 = i1 + 192 | 0;
michael@0 49305 i1 = 0;
michael@0 49306 while (1) {
michael@0 49307 if ((i1 | 0) >= (i4 | 0)) {
michael@0 49308 break;
michael@0 49309 }
michael@0 49310 i6 = HEAP32[i5 >> 2] | 0;
michael@0 49311 i7 = i6 + (i1 << 2) | 0;
michael@0 49312 if ((HEAP32[i7 >> 2] | 0) == (i2 | 0)) {
michael@0 49313 i8 = 512;
michael@0 49314 break;
michael@0 49315 } else {
michael@0 49316 i1 = i1 + 1 | 0;
michael@0 49317 }
michael@0 49318 }
michael@0 49319 if ((i8 | 0) == 512) {
michael@0 49320 i8 = i4 - 1 | 0;
michael@0 49321 HEAP32[i7 >> 2] = HEAP32[i6 + (i8 << 2) >> 2];
michael@0 49322 HEAP32[(HEAP32[i5 >> 2] | 0) + (i8 << 2) >> 2] = i2;
michael@0 49323 HEAP32[i3 >> 2] = i8;
michael@0 49324 }
michael@0 49325 __ZN11btRigidBody19removeConstraintRefEP17btTypedConstraint(HEAP32[i2 + 24 >> 2] | 0, i2);
michael@0 49326 __ZN11btRigidBody19removeConstraintRefEP17btTypedConstraint(HEAP32[i2 + 28 >> 2] | 0, i2);
michael@0 49327 return;
michael@0 49328 }
michael@0 49329 function __ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i1, i2, i3, i4, i5) {
michael@0 49330 i1 = i1 | 0;
michael@0 49331 i2 = i2 | 0;
michael@0 49332 i3 = i3 | 0;
michael@0 49333 i4 = i4 | 0;
michael@0 49334 i5 = i5 | 0;
michael@0 49335 HEAP32[i1 >> 2] = 4136;
michael@0 49336 HEAPF32[i1 + 4 >> 2] = 0.0;
michael@0 49337 HEAPF32[i1 + 8 >> 2] = 1.0;
michael@0 49338 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 49339 HEAPF32[i1 + 16 >> 2] = 0.0;
michael@0 49340 HEAP32[i1 + 20 >> 2] = i5;
michael@0 49341 HEAP32[i1 + 24 >> 2] = i4;
michael@0 49342 HEAP32[i1 + 28 >> 2] = i2;
michael@0 49343 HEAP32[i1 + 32 >> 2] = i3;
michael@0 49344 HEAP32[i1 + 36 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 49345 HEAP32[i1 + 40 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 49346 HEAPF32[i1 + 44 >> 2] = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i2 >> 2] | 0) + 44 >> 2] & 7](i2);
michael@0 49347 HEAPF32[i1 + 48 >> 2] = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i3 >> 2] | 0) + 44 >> 2] & 7](i3);
michael@0 49348 HEAP8[i1 + 52 | 0] = 0;
michael@0 49349 HEAP32[i1 + 60 >> 2] = -1;
michael@0 49350 HEAP32[i1 + 72 >> 2] = 1;
michael@0 49351 return;
michael@0 49352 }
michael@0 49353 function __ZNK10btBoxShape21calculateLocalInertiaEfR9btVector3(i1, d2, i3) {
michael@0 49354 i1 = i1 | 0;
michael@0 49355 d2 = +d2;
michael@0 49356 i3 = i3 | 0;
michael@0 49357 var d4 = 0.0, d5 = 0.0, d6 = 0.0, i7 = 0, i8 = 0, d9 = 0.0, d10 = 0.0, d11 = 0.0;
michael@0 49358 d4 = +HEAPF32[i1 + 28 >> 2];
michael@0 49359 d5 = +HEAPF32[i1 + 32 >> 2];
michael@0 49360 d6 = +HEAPF32[i1 + 36 >> 2];
michael@0 49361 i7 = i1 | 0;
michael@0 49362 i8 = i1;
michael@0 49363 d9 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49364 d10 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7);
michael@0 49365 d11 = (d4 + d9) * 2.0;
michael@0 49366 d9 = (d5 + d10) * 2.0;
michael@0 49367 d10 = (d6 + +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i8 >> 2] | 0) + 44 >> 2] & 7](i7)) * 2.0;
michael@0 49368 d6 = d2 / 12.0;
michael@0 49369 d2 = d9 * d9;
michael@0 49370 d9 = d10 * d10;
michael@0 49371 d10 = d11 * d11;
michael@0 49372 HEAPF32[i3 >> 2] = d6 * (d2 + d9);
michael@0 49373 HEAPF32[i3 + 4 >> 2] = d6 * (d10 + d9);
michael@0 49374 HEAPF32[i3 + 8 >> 2] = d6 * (d10 + d2);
michael@0 49375 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 49376 return;
michael@0 49377 }
michael@0 49378 function __ZNK13btSphereShape24localGetSupportingVertexERK9btVector3(i1, i2, i3) {
michael@0 49379 i1 = i1 | 0;
michael@0 49380 i2 = i2 | 0;
michael@0 49381 i3 = i3 | 0;
michael@0 49382 var d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0;
michael@0 49383 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i2 >> 2] | 0) + 64 >> 2] & 127](i1, i2, i3);
michael@0 49384 d4 = +HEAPF32[i3 >> 2];
michael@0 49385 d5 = +HEAPF32[i3 + 4 >> 2];
michael@0 49386 d6 = +HEAPF32[i3 + 8 >> 2];
michael@0 49387 i3 = d4 * d4 + d5 * d5 + d6 * d6 < 1.4210854715202004e-14;
michael@0 49388 d7 = i3 ? -1.0 : d6;
michael@0 49389 d6 = i3 ? -1.0 : d5;
michael@0 49390 d5 = i3 ? -1.0 : d4;
michael@0 49391 d4 = 1.0 / +Math_sqrt(+(d7 * d7 + (d5 * d5 + d6 * d6)));
michael@0 49392 d8 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i2 >> 2] | 0) + 44 >> 2] & 7](i2);
michael@0 49393 i2 = i1 | 0;
michael@0 49394 HEAPF32[i2 >> 2] = d4 * d5 * d8 + +HEAPF32[i2 >> 2];
michael@0 49395 i2 = i1 + 4 | 0;
michael@0 49396 HEAPF32[i2 >> 2] = d8 * d4 * d6 + +HEAPF32[i2 >> 2];
michael@0 49397 i2 = i1 + 8 | 0;
michael@0 49398 HEAPF32[i2 >> 2] = d8 * d4 * d7 + +HEAPF32[i2 >> 2];
michael@0 49399 return;
michael@0 49400 }
michael@0 49401 function __ZN20btPersistentManifold16addManifoldPointERK15btManifoldPoint(i1, i2) {
michael@0 49402 i1 = i1 | 0;
michael@0 49403 i2 = i2 | 0;
michael@0 49404 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 49405 i3 = i1 + 1116 | 0;
michael@0 49406 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49407 do {
michael@0 49408 if ((i4 | 0) == 4) {
michael@0 49409 i5 = __ZN20btPersistentManifold16sortCachedPointsERK15btManifoldPoint(i1, i2) | 0;
michael@0 49410 i6 = i1 + 4 + (i5 * 276 | 0) + 108 | 0;
michael@0 49411 i7 = HEAP32[i6 >> 2] | 0;
michael@0 49412 if ((i7 | 0) == 0) {
michael@0 49413 i8 = i5;
michael@0 49414 break;
michael@0 49415 }
michael@0 49416 i9 = HEAP32[3008] | 0;
michael@0 49417 if ((i9 | 0) == 0) {
michael@0 49418 i8 = i5;
michael@0 49419 break;
michael@0 49420 }
michael@0 49421 FUNCTION_TABLE_ii[i9 & 127](i7) | 0;
michael@0 49422 HEAP32[i6 >> 2] = 0;
michael@0 49423 i8 = i5;
michael@0 49424 } else {
michael@0 49425 HEAP32[i3 >> 2] = i4 + 1;
michael@0 49426 i8 = i4;
michael@0 49427 }
michael@0 49428 } while (0);
michael@0 49429 i4 = (i8 | 0) < 0 ? 0 : i8;
michael@0 49430 i8 = i1 + 4 + (i4 * 276 | 0) | 0;
michael@0 49431 i1 = i2;
michael@0 49432 _memcpy(i8 | 0, i1 | 0, 276) | 0;
michael@0 49433 return i4 | 0;
michael@0 49434 }
michael@0 49435 function __ZN11btRigidBody24checkCollideWithOverrideEP17btCollisionObject(i1, i2) {
michael@0 49436 i1 = i1 | 0;
michael@0 49437 i2 = i2 | 0;
michael@0 49438 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 49439 if ((HEAP32[i2 + 232 >> 2] & 2 | 0) == 0) {
michael@0 49440 i3 = 1;
michael@0 49441 return i3 | 0;
michael@0 49442 }
michael@0 49443 i4 = i2;
michael@0 49444 i2 = i1 + 488 | 0;
michael@0 49445 i5 = HEAP32[i1 + 480 >> 2] | 0;
michael@0 49446 i1 = 0;
michael@0 49447 while (1) {
michael@0 49448 if ((i1 | 0) >= (i5 | 0)) {
michael@0 49449 i3 = 1;
michael@0 49450 i6 = 1054;
michael@0 49451 break;
michael@0 49452 }
michael@0 49453 i7 = HEAP32[(HEAP32[i2 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 49454 if ((HEAP32[i7 + 24 >> 2] | 0) == (i4 | 0)) {
michael@0 49455 i3 = 0;
michael@0 49456 i6 = 1055;
michael@0 49457 break;
michael@0 49458 }
michael@0 49459 if ((HEAP32[i7 + 28 >> 2] | 0) == (i4 | 0)) {
michael@0 49460 i3 = 0;
michael@0 49461 i6 = 1057;
michael@0 49462 break;
michael@0 49463 } else {
michael@0 49464 i1 = i1 + 1 | 0;
michael@0 49465 }
michael@0 49466 }
michael@0 49467 if ((i6 | 0) == 1054) {
michael@0 49468 return i3 | 0;
michael@0 49469 } else if ((i6 | 0) == 1055) {
michael@0 49470 return i3 | 0;
michael@0 49471 } else if ((i6 | 0) == 1057) {
michael@0 49472 return i3 | 0;
michael@0 49473 }
michael@0 49474 return 0;
michael@0 49475 }
michael@0 49476 function __ZN26btBoxBoxCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_(i1, i2, i3, i4, i5) {
michael@0 49477 i1 = i1 | 0;
michael@0 49478 i2 = i2 | 0;
michael@0 49479 i3 = i3 | 0;
michael@0 49480 i4 = i4 | 0;
michael@0 49481 i5 = i5 | 0;
michael@0 49482 var i6 = 0;
michael@0 49483 __ZN30btActivatingCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1 | 0, i3, i4, i5);
michael@0 49484 HEAP32[i1 >> 2] = 2960;
michael@0 49485 i3 = i1 + 8 | 0;
michael@0 49486 HEAP8[i3] = 0;
michael@0 49487 i6 = i1 + 12 | 0;
michael@0 49488 HEAP32[i6 >> 2] = i2;
michael@0 49489 if ((i2 | 0) != 0) {
michael@0 49490 return;
michael@0 49491 }
michael@0 49492 i2 = i1 + 4 | 0;
michael@0 49493 i1 = HEAP32[i2 >> 2] | 0;
michael@0 49494 if (!(FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 24 >> 2] & 31](i1, i4, i5) | 0)) {
michael@0 49495 return;
michael@0 49496 }
michael@0 49497 i1 = HEAP32[i2 >> 2] | 0;
michael@0 49498 HEAP32[i6 >> 2] = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 12 >> 2] & 31](i1, i4, i5) | 0;
michael@0 49499 HEAP8[i3] = 1;
michael@0 49500 return;
michael@0 49501 }
michael@0 49502 function __ZNK10__cxxabiv120__si_class_type_info27has_unambiguous_public_baseEPNS_19__dynamic_cast_infoEPvi(i1, i2, i3, i4) {
michael@0 49503 i1 = i1 | 0;
michael@0 49504 i2 = i2 | 0;
michael@0 49505 i3 = i3 | 0;
michael@0 49506 i4 = i4 | 0;
michael@0 49507 var i5 = 0;
michael@0 49508 if ((i1 | 0) != (HEAP32[i2 + 8 >> 2] | 0)) {
michael@0 49509 i5 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 49510 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i5 >> 2] | 0) + 28 >> 2] & 127](i5, i2, i3, i4);
michael@0 49511 return;
michael@0 49512 }
michael@0 49513 i5 = i2 + 16 | 0;
michael@0 49514 i1 = HEAP32[i5 >> 2] | 0;
michael@0 49515 if ((i1 | 0) == 0) {
michael@0 49516 HEAP32[i5 >> 2] = i3;
michael@0 49517 HEAP32[i2 + 24 >> 2] = i4;
michael@0 49518 HEAP32[i2 + 36 >> 2] = 1;
michael@0 49519 return;
michael@0 49520 }
michael@0 49521 if ((i1 | 0) != (i3 | 0)) {
michael@0 49522 i3 = i2 + 36 | 0;
michael@0 49523 HEAP32[i3 >> 2] = (HEAP32[i3 >> 2] | 0) + 1;
michael@0 49524 HEAP32[i2 + 24 >> 2] = 2;
michael@0 49525 HEAP8[i2 + 54 | 0] = 1;
michael@0 49526 return;
michael@0 49527 }
michael@0 49528 i3 = i2 + 24 | 0;
michael@0 49529 if ((HEAP32[i3 >> 2] | 0) != 2) {
michael@0 49530 return;
michael@0 49531 }
michael@0 49532 HEAP32[i3 >> 2] = i4;
michael@0 49533 return;
michael@0 49534 }
michael@0 49535 function __ZN28btHashedOverlappingPairCache18addOverlappingPairEP17btBroadphaseProxyS1_(i1, i2, i3) {
michael@0 49536 i1 = i1 | 0;
michael@0 49537 i2 = i2 | 0;
michael@0 49538 i3 = i3 | 0;
michael@0 49539 var i4 = 0, i5 = 0;
michael@0 49540 HEAP32[3012] = (HEAP32[3012] | 0) + 1;
michael@0 49541 i4 = HEAP32[i1 + 24 >> 2] | 0;
michael@0 49542 do {
michael@0 49543 if ((i4 | 0) == 0) {
michael@0 49544 if ((HEAP16[i3 + 6 >> 1] & HEAP16[i2 + 4 >> 1]) << 16 >> 16 == 0) {
michael@0 49545 i5 = 0;
michael@0 49546 return i5 | 0;
michael@0 49547 }
michael@0 49548 if ((HEAP16[i2 + 6 >> 1] & HEAP16[i3 + 4 >> 1]) << 16 >> 16 == 0) {
michael@0 49549 i5 = 0;
michael@0 49550 } else {
michael@0 49551 break;
michael@0 49552 }
michael@0 49553 return i5 | 0;
michael@0 49554 } else {
michael@0 49555 if (FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i4 >> 2] | 0) + 8 >> 2] & 31](i4, i2, i3) | 0) {
michael@0 49556 break;
michael@0 49557 } else {
michael@0 49558 i5 = 0;
michael@0 49559 }
michael@0 49560 return i5 | 0;
michael@0 49561 }
michael@0 49562 } while (0);
michael@0 49563 i5 = __ZN28btHashedOverlappingPairCache15internalAddPairEP17btBroadphaseProxyS1_(i1, i2, i3) | 0;
michael@0 49564 return i5 | 0;
michael@0 49565 }
michael@0 49566 function __ZN6btDbvt6updateEP10btDbvtNodeR12btDbvtAabbMm(i1, i2, i3) {
michael@0 49567 i1 = i1 | 0;
michael@0 49568 i2 = i2 | 0;
michael@0 49569 i3 = i3 | 0;
michael@0 49570 var i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 49571 i4 = __ZL10removeleafP6btDbvtP10btDbvtNode(i1, i2) | 0;
michael@0 49572 L2369 : do {
michael@0 49573 if ((i4 | 0) == 0) {
michael@0 49574 i5 = 0;
michael@0 49575 } else {
michael@0 49576 i6 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 49577 if ((i6 | 0) > -1) {
michael@0 49578 i7 = 0;
michael@0 49579 i8 = i4;
michael@0 49580 } else {
michael@0 49581 i5 = HEAP32[i1 >> 2] | 0;
michael@0 49582 break;
michael@0 49583 }
michael@0 49584 while (1) {
michael@0 49585 if ((i7 | 0) >= (i6 | 0)) {
michael@0 49586 i5 = i8;
michael@0 49587 break L2369;
michael@0 49588 }
michael@0 49589 i9 = HEAP32[i8 + 32 >> 2] | 0;
michael@0 49590 if ((i9 | 0) == 0) {
michael@0 49591 i5 = i8;
michael@0 49592 break;
michael@0 49593 } else {
michael@0 49594 i7 = i7 + 1 | 0;
michael@0 49595 i8 = i9;
michael@0 49596 }
michael@0 49597 }
michael@0 49598 }
michael@0 49599 } while (0);
michael@0 49600 i8 = i2;
michael@0 49601 i7 = i3;
michael@0 49602 _memcpy(i8 | 0, i7 | 0, 32) | 0;
michael@0 49603 __ZL10insertleafP6btDbvtP10btDbvtNodeS2_(i1, i5, i2);
michael@0 49604 return;
michael@0 49605 }
michael@0 49606 function __ZN15CProfileManager5ResetEv() {
michael@0 49607 var i1 = 0, i2 = 0, i3 = 0, i4 = 0;
michael@0 49608 i1 = STACKTOP;
michael@0 49609 STACKTOP = STACKTOP + 16 | 0;
michael@0 49610 i2 = i1 | 0;
michael@0 49611 i3 = i1 + 8 | 0;
michael@0 49612 _gettimeofday(HEAP32[3578] | 0, 0) | 0;
michael@0 49613 __ZN12CProfileNode5ResetEv(14256);
michael@0 49614 HEAP32[3565] = (HEAP32[3565] | 0) + 1;
michael@0 49615 i4 = HEAP32[3568] | 0;
michael@0 49616 HEAP32[3568] = i4 + 1;
michael@0 49617 if ((i4 | 0) == 0) {
michael@0 49618 _gettimeofday(i3 | 0, 0) | 0;
michael@0 49619 i4 = HEAP32[3578] | 0;
michael@0 49620 HEAP32[3567] = (HEAP32[i3 + 4 >> 2] | 0) - (HEAP32[i4 + 4 >> 2] | 0) + (((HEAP32[i3 >> 2] | 0) - (HEAP32[i4 >> 2] | 0) | 0) * 1e6 | 0);
michael@0 49621 }
michael@0 49622 HEAP32[3572] = 0;
michael@0 49623 _gettimeofday(i2 | 0, 0) | 0;
michael@0 49624 i4 = HEAP32[3578] | 0;
michael@0 49625 HEAP32[3562] = (HEAP32[i2 + 4 >> 2] | 0) - (HEAP32[i4 + 4 >> 2] | 0) + (((HEAP32[i2 >> 2] | 0) - (HEAP32[i4 >> 2] | 0) | 0) * 1e6 | 0);
michael@0 49626 STACKTOP = i1;
michael@0 49627 return;
michael@0 49628 }
michael@0 49629 function __ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResult15addContactPointERKS8_SG_f(i1, i2, i3, d4) {
michael@0 49630 i1 = i1 | 0;
michael@0 49631 i2 = i2 | 0;
michael@0 49632 i3 = i3 | 0;
michael@0 49633 d4 = +d4;
michael@0 49634 var i5 = 0, i6 = 0;
michael@0 49635 i5 = i1 + 4 | 0;
michael@0 49636 i6 = i2;
michael@0 49637 HEAP32[i5 >> 2] = HEAP32[i6 >> 2];
michael@0 49638 HEAP32[i5 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 49639 HEAP32[i5 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 49640 HEAP32[i5 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 49641 i6 = i1 + 20 | 0;
michael@0 49642 i5 = i3;
michael@0 49643 HEAP32[i6 >> 2] = HEAP32[i5 >> 2];
michael@0 49644 HEAP32[i6 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 49645 HEAP32[i6 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 49646 HEAP32[i6 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 49647 HEAPF32[i1 + 36 >> 2] = d4;
michael@0 49648 HEAP8[i1 + 40 | 0] = 1;
michael@0 49649 return;
michael@0 49650 }
michael@0 49651 function __ZN35btSequentialImpulseConstraintSolverC2Ev(i1) {
michael@0 49652 i1 = i1 | 0;
michael@0 49653 HEAP32[i1 >> 2] = 2368;
michael@0 49654 HEAP8[i1 + 20 | 0] = 1;
michael@0 49655 HEAP32[i1 + 16 >> 2] = 0;
michael@0 49656 HEAP32[i1 + 8 >> 2] = 0;
michael@0 49657 HEAP32[i1 + 12 >> 2] = 0;
michael@0 49658 HEAP8[i1 + 40 | 0] = 1;
michael@0 49659 HEAP32[i1 + 36 >> 2] = 0;
michael@0 49660 HEAP32[i1 + 28 >> 2] = 0;
michael@0 49661 HEAP32[i1 + 32 >> 2] = 0;
michael@0 49662 HEAP8[i1 + 60 | 0] = 1;
michael@0 49663 HEAP32[i1 + 56 >> 2] = 0;
michael@0 49664 HEAP32[i1 + 48 >> 2] = 0;
michael@0 49665 HEAP32[i1 + 52 >> 2] = 0;
michael@0 49666 HEAP8[i1 + 80 | 0] = 1;
michael@0 49667 HEAP32[i1 + 76 >> 2] = 0;
michael@0 49668 HEAP32[i1 + 68 >> 2] = 0;
michael@0 49669 HEAP32[i1 + 72 >> 2] = 0;
michael@0 49670 HEAP8[i1 + 100 | 0] = 1;
michael@0 49671 HEAP32[i1 + 96 >> 2] = 0;
michael@0 49672 HEAP32[i1 + 88 >> 2] = 0;
michael@0 49673 HEAP32[i1 + 92 >> 2] = 0;
michael@0 49674 HEAP8[i1 + 120 | 0] = 1;
michael@0 49675 HEAP32[i1 + 116 >> 2] = 0;
michael@0 49676 HEAP32[i1 + 108 >> 2] = 0;
michael@0 49677 HEAP32[i1 + 112 >> 2] = 0;
michael@0 49678 HEAP32[i1 + 124 >> 2] = 0;
michael@0 49679 return;
michael@0 49680 }
michael@0 49681 function __ZN16btDbvtBroadphase7rayTestERK9btVector3S2_R23btBroadphaseRayCallbackS2_S2_(i1, i2, i3, i4, i5, i6) {
michael@0 49682 i1 = i1 | 0;
michael@0 49683 i2 = i2 | 0;
michael@0 49684 i3 = i3 | 0;
michael@0 49685 i4 = i4 | 0;
michael@0 49686 i5 = i5 | 0;
michael@0 49687 i6 = i6 | 0;
michael@0 49688 var i7 = 0, i8 = 0, i9 = 0, i10 = 0;
michael@0 49689 i3 = STACKTOP;
michael@0 49690 STACKTOP = STACKTOP + 8 | 0;
michael@0 49691 i7 = i3 | 0;
michael@0 49692 HEAP32[i7 >> 2] = 4016;
michael@0 49693 HEAP32[i7 + 4 >> 2] = i4;
michael@0 49694 i8 = i4 + 4 | 0;
michael@0 49695 i9 = i4 + 20 | 0;
michael@0 49696 i10 = i4 + 32 | 0;
michael@0 49697 i4 = i7 | 0;
michael@0 49698 __ZNK6btDbvt15rayTestInternalEPK10btDbvtNodeRK9btVector3S5_S5_PjfS5_S5_RNS_8ICollideE(0, HEAP32[i1 + 4 >> 2] | 0, i2, 0, i8, i9, +HEAPF32[i10 >> 2], i5, i6, i4);
michael@0 49699 __ZNK6btDbvt15rayTestInternalEPK10btDbvtNodeRK9btVector3S5_S5_PjfS5_S5_RNS_8ICollideE(0, HEAP32[i1 + 44 >> 2] | 0, i2, 0, i8, i9, +HEAPF32[i10 >> 2], i5, i6, i4);
michael@0 49700 STACKTOP = i3;
michael@0 49701 return;
michael@0 49702 }
michael@0 49703 function ___remdi3(i1, i2, i3, i4) {
michael@0 49704 i1 = i1 | 0;
michael@0 49705 i2 = i2 | 0;
michael@0 49706 i3 = i3 | 0;
michael@0 49707 i4 = i4 | 0;
michael@0 49708 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0, i10 = 0, i11 = 0;
michael@0 49709 i5 = STACKTOP;
michael@0 49710 STACKTOP = STACKTOP + 8 | 0;
michael@0 49711 i6 = i5 | 0;
michael@0 49712 i7 = i2 >> 31 | ((i2 | 0) < 0 ? -1 : 0) << 1;
michael@0 49713 i8 = ((i2 | 0) < 0 ? -1 : 0) >> 31 | ((i2 | 0) < 0 ? -1 : 0) << 1;
michael@0 49714 i9 = i4 >> 31 | ((i4 | 0) < 0 ? -1 : 0) << 1;
michael@0 49715 i10 = ((i4 | 0) < 0 ? -1 : 0) >> 31 | ((i4 | 0) < 0 ? -1 : 0) << 1;
michael@0 49716 i11 = _i64Subtract(i7 ^ i1, i8 ^ i2, i7, i8) | 0;
michael@0 49717 i2 = tempRet0;
michael@0 49718 i1 = _i64Subtract(i9 ^ i3, i10 ^ i4, i9, i10) | 0;
michael@0 49719 ___udivmoddi4(i11, i2, i1, tempRet0, i6) | 0;
michael@0 49720 i1 = _i64Subtract(HEAP32[i6 >> 2] ^ i7, HEAP32[i6 + 4 >> 2] ^ i8, i7, i8) | 0;
michael@0 49721 i8 = tempRet0;
michael@0 49722 STACKTOP = i5;
michael@0 49723 return (tempRet0 = i8, i1) | 0;
michael@0 49724 }
michael@0 49725 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN14LocalInfoAdder15addSingleResultE_1RNS_17LocalConvexResultEb(i1, i2, i3) {
michael@0 49726 i1 = i1 | 0;
michael@0 49727 i2 = i2 | 0;
michael@0 49728 i3 = i3 | 0;
michael@0 49729 var i4 = 0, i5 = 0, i6 = 0, d7 = 0.0;
michael@0 49730 i4 = STACKTOP;
michael@0 49731 STACKTOP = STACKTOP + 8 | 0;
michael@0 49732 i5 = i4 | 0;
michael@0 49733 HEAP32[i5 >> 2] = -1;
michael@0 49734 HEAP32[i5 + 4 >> 2] = HEAP32[i1 + 16 >> 2];
michael@0 49735 i6 = i2 + 4 | 0;
michael@0 49736 if ((HEAP32[i6 >> 2] | 0) == 0) {
michael@0 49737 HEAP32[i6 >> 2] = i5;
michael@0 49738 }
michael@0 49739 i5 = i1 + 12 | 0;
michael@0 49740 i6 = HEAP32[i5 >> 2] | 0;
michael@0 49741 d7 = +FUNCTION_TABLE_fiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 12 >> 2] & 15](i6, i2, i3);
michael@0 49742 HEAPF32[i1 + 4 >> 2] = +HEAPF32[(HEAP32[i5 >> 2] | 0) + 4 >> 2];
michael@0 49743 STACKTOP = i4;
michael@0 49744 return +d7;
michael@0 49745 }
michael@0 49746 function __ZN28btCompoundCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b(i1, i2, i3, i4, i5) {
michael@0 49747 i1 = i1 | 0;
michael@0 49748 i2 = i2 | 0;
michael@0 49749 i3 = i3 | 0;
michael@0 49750 i4 = i4 | 0;
michael@0 49751 i5 = i5 | 0;
michael@0 49752 __ZN30btActivatingCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1 | 0, i2, i3, i4);
michael@0 49753 HEAP32[i1 >> 2] = 2888;
michael@0 49754 HEAP8[i1 + 24 | 0] = 1;
michael@0 49755 HEAP32[i1 + 20 >> 2] = 0;
michael@0 49756 HEAP32[i1 + 12 >> 2] = 0;
michael@0 49757 HEAP32[i1 + 16 >> 2] = 0;
michael@0 49758 HEAP8[i1 + 28 | 0] = i5 & 1;
michael@0 49759 HEAP32[i1 + 32 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 49760 HEAP8[i1 + 36 | 0] = 0;
michael@0 49761 HEAP32[i1 + 40 >> 2] = HEAP32[(HEAP32[(i5 ? i4 : i3) + 192 >> 2] | 0) + 68 >> 2];
michael@0 49762 __ZN28btCompoundCollisionAlgorithm26preallocateChildAlgorithmsEP17btCollisionObjectS1_(i1, i3, i4);
michael@0 49763 return;
michael@0 49764 }
michael@0 49765 function __ZN25btSimulationIslandManagerD2Ev(i1) {
michael@0 49766 i1 = i1 | 0;
michael@0 49767 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 49768 HEAP32[i1 >> 2] = 3032;
michael@0 49769 i2 = i1 + 48 | 0;
michael@0 49770 i3 = i1 + 56 | 0;
michael@0 49771 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49772 i5 = i1 + 60 | 0;
michael@0 49773 if ((i4 | 0) != 0) {
michael@0 49774 if ((HEAP8[i5] | 0) != 0) {
michael@0 49775 __Z21btAlignedFreeInternalPv(i4);
michael@0 49776 }
michael@0 49777 HEAP32[i3 >> 2] = 0;
michael@0 49778 }
michael@0 49779 HEAP8[i5] = 1;
michael@0 49780 HEAP32[i3 >> 2] = 0;
michael@0 49781 HEAP32[i2 >> 2] = 0;
michael@0 49782 HEAP32[i1 + 52 >> 2] = 0;
michael@0 49783 i2 = i1 + 28 | 0;
michael@0 49784 i3 = i1 + 36 | 0;
michael@0 49785 i5 = HEAP32[i3 >> 2] | 0;
michael@0 49786 i4 = i1 + 40 | 0;
michael@0 49787 if ((i5 | 0) != 0) {
michael@0 49788 if ((HEAP8[i4] | 0) != 0) {
michael@0 49789 __Z21btAlignedFreeInternalPv(i5);
michael@0 49790 }
michael@0 49791 HEAP32[i3 >> 2] = 0;
michael@0 49792 }
michael@0 49793 HEAP8[i4] = 1;
michael@0 49794 HEAP32[i3 >> 2] = 0;
michael@0 49795 HEAP32[i2 >> 2] = 0;
michael@0 49796 HEAP32[i1 + 32 >> 2] = 0;
michael@0 49797 __ZN11btUnionFindD2Ev(i1 + 4 | 0);
michael@0 49798 return;
michael@0 49799 }
michael@0 49800 function __ZN21btSingleSweepCallback7processEPK17btBroadphaseProxy(i1, i2) {
michael@0 49801 i1 = i1 | 0;
michael@0 49802 i2 = i2 | 0;
michael@0 49803 var i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 49804 i3 = i1 + 184 | 0;
michael@0 49805 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49806 if (+HEAPF32[i4 + 4 >> 2] == 0.0) {
michael@0 49807 i5 = 0;
michael@0 49808 return i5 | 0;
michael@0 49809 }
michael@0 49810 i6 = HEAP32[i2 >> 2] | 0;
michael@0 49811 if (!(FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 8 >> 2] & 63](i4, HEAP32[i6 + 188 >> 2] | 0) | 0)) {
michael@0 49812 i5 = 1;
michael@0 49813 return i5 | 0;
michael@0 49814 }
michael@0 49815 __ZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEf(HEAP32[i1 + 192 >> 2] | 0, i1 + 36 | 0, i1 + 100 | 0, i6, HEAP32[i6 + 192 >> 2] | 0, i6 + 4 | 0, HEAP32[i3 >> 2] | 0, +HEAPF32[i1 + 188 >> 2]);
michael@0 49816 i5 = 1;
michael@0 49817 return i5 | 0;
michael@0 49818 }
michael@0 49819 function __ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_iiffP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i1, i2, i3, i4, i5, d6, d7, i8, i9) {
michael@0 49820 i1 = i1 | 0;
michael@0 49821 i2 = i2 | 0;
michael@0 49822 i3 = i3 | 0;
michael@0 49823 i4 = i4 | 0;
michael@0 49824 i5 = i5 | 0;
michael@0 49825 d6 = +d6;
michael@0 49826 d7 = +d7;
michael@0 49827 i8 = i8 | 0;
michael@0 49828 i9 = i9 | 0;
michael@0 49829 HEAP32[i1 >> 2] = 4136;
michael@0 49830 HEAPF32[i1 + 4 >> 2] = 0.0;
michael@0 49831 HEAPF32[i1 + 8 >> 2] = 1.0;
michael@0 49832 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 49833 HEAPF32[i1 + 16 >> 2] = 0.0;
michael@0 49834 HEAP32[i1 + 20 >> 2] = i9;
michael@0 49835 HEAP32[i1 + 24 >> 2] = i8;
michael@0 49836 HEAP32[i1 + 28 >> 2] = i2;
michael@0 49837 HEAP32[i1 + 32 >> 2] = i3;
michael@0 49838 HEAP32[i1 + 36 >> 2] = i4;
michael@0 49839 HEAP32[i1 + 40 >> 2] = i5;
michael@0 49840 HEAPF32[i1 + 44 >> 2] = d6;
michael@0 49841 HEAPF32[i1 + 48 >> 2] = d7;
michael@0 49842 HEAP8[i1 + 52 | 0] = 0;
michael@0 49843 HEAP32[i1 + 60 >> 2] = -1;
michael@0 49844 HEAP32[i1 + 72 >> 2] = 1;
michael@0 49845 return;
michael@0 49846 }
michael@0 49847 function __ZNK14btQuantizedBvh25reportRayOverlappingNodexEP21btNodeOverlapCallbackRK9btVector3S4_(i1, i2, i3, i4) {
michael@0 49848 i1 = i1 | 0;
michael@0 49849 i2 = i2 | 0;
michael@0 49850 i3 = i3 | 0;
michael@0 49851 i4 = i4 | 0;
michael@0 49852 var i5 = 0, i6 = 0, i7 = 0;
michael@0 49853 i5 = STACKTOP;
michael@0 49854 STACKTOP = STACKTOP + 32 | 0;
michael@0 49855 i6 = i5 | 0;
michael@0 49856 i7 = i5 + 16 | 0;
michael@0 49857 _memset(i6 | 0, 0, 16);
michael@0 49858 _memset(i7 | 0, 0, 16);
michael@0 49859 if ((HEAP8[i1 + 60 | 0] | 0) == 0) {
michael@0 49860 __ZNK14btQuantizedBvh27walkStacklessTreeAgainstRayEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_ii(i1, i2, i3, i4, i6, i7, 0, 0);
michael@0 49861 STACKTOP = i5;
michael@0 49862 return;
michael@0 49863 } else {
michael@0 49864 __ZNK14btQuantizedBvh36walkStacklessQuantizedTreeAgainstRayEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_ii(i1, i2, i3, i4, i6, i7, 0, HEAP32[i1 + 56 >> 2] | 0);
michael@0 49865 STACKTOP = i5;
michael@0 49866 return;
michael@0 49867 }
michael@0 49868 }
michael@0 49869 function __ZN23btDiscreteDynamicsWorld15removeRigidBodyEP11btRigidBody(i1, i2) {
michael@0 49870 i1 = i1 | 0;
michael@0 49871 i2 = i2 | 0;
michael@0 49872 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 49873 i3 = i1 + 204 | 0;
michael@0 49874 i4 = HEAP32[i3 >> 2] | 0;
michael@0 49875 i5 = i1 + 212 | 0;
michael@0 49876 i6 = 0;
michael@0 49877 while (1) {
michael@0 49878 if ((i6 | 0) >= (i4 | 0)) {
michael@0 49879 break;
michael@0 49880 }
michael@0 49881 i7 = HEAP32[i5 >> 2] | 0;
michael@0 49882 i8 = i7 + (i6 << 2) | 0;
michael@0 49883 if ((HEAP32[i8 >> 2] | 0) == (i2 | 0)) {
michael@0 49884 i9 = 433;
michael@0 49885 break;
michael@0 49886 } else {
michael@0 49887 i6 = i6 + 1 | 0;
michael@0 49888 }
michael@0 49889 }
michael@0 49890 if ((i9 | 0) == 433) {
michael@0 49891 i9 = i4 - 1 | 0;
michael@0 49892 HEAP32[i8 >> 2] = HEAP32[i7 + (i9 << 2) >> 2];
michael@0 49893 HEAP32[(HEAP32[i5 >> 2] | 0) + (i9 << 2) >> 2] = i2;
michael@0 49894 HEAP32[i3 >> 2] = i9;
michael@0 49895 }
michael@0 49896 __ZN16btCollisionWorld21removeCollisionObjectEP17btCollisionObject(i1 | 0, i2 | 0);
michael@0 49897 return;
michael@0 49898 }
michael@0 49899 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN15LocalInfoAdder215addSingleResultERNS_14LocalRayResultEb(i1, i2, i3) {
michael@0 49900 i1 = i1 | 0;
michael@0 49901 i2 = i2 | 0;
michael@0 49902 i3 = i3 | 0;
michael@0 49903 var i4 = 0, i5 = 0, i6 = 0, d7 = 0.0;
michael@0 49904 i4 = STACKTOP;
michael@0 49905 STACKTOP = STACKTOP + 8 | 0;
michael@0 49906 i5 = i4 | 0;
michael@0 49907 HEAP32[i5 >> 2] = -1;
michael@0 49908 HEAP32[i5 + 4 >> 2] = HEAP32[i1 + 24 >> 2];
michael@0 49909 i6 = i2 + 4 | 0;
michael@0 49910 if ((HEAP32[i6 >> 2] | 0) == 0) {
michael@0 49911 HEAP32[i6 >> 2] = i5;
michael@0 49912 }
michael@0 49913 i5 = i1 + 20 | 0;
michael@0 49914 i6 = HEAP32[i5 >> 2] | 0;
michael@0 49915 d7 = +FUNCTION_TABLE_fiii[HEAP32[(HEAP32[i6 >> 2] | 0) + 12 >> 2] & 15](i6, i2, i3);
michael@0 49916 HEAPF32[i1 + 4 >> 2] = +HEAPF32[(HEAP32[i5 >> 2] | 0) + 4 >> 2];
michael@0 49917 STACKTOP = i4;
michael@0 49918 return +d7;
michael@0 49919 }
michael@0 49920 function __ZN34btSphereTriangleCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_b(i1, i2, i3, i4, i5, i6) {
michael@0 49921 i1 = i1 | 0;
michael@0 49922 i2 = i2 | 0;
michael@0 49923 i3 = i3 | 0;
michael@0 49924 i4 = i4 | 0;
michael@0 49925 i5 = i5 | 0;
michael@0 49926 i6 = i6 | 0;
michael@0 49927 var i7 = 0;
michael@0 49928 __ZN30btActivatingCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1 | 0, i3, i4, i5);
michael@0 49929 HEAP32[i1 >> 2] = 2424;
michael@0 49930 i3 = i1 + 8 | 0;
michael@0 49931 HEAP8[i3] = 0;
michael@0 49932 i7 = i1 + 12 | 0;
michael@0 49933 HEAP32[i7 >> 2] = i2;
michael@0 49934 HEAP8[i1 + 16 | 0] = i6 & 1;
michael@0 49935 if ((i2 | 0) != 0) {
michael@0 49936 return;
michael@0 49937 }
michael@0 49938 i2 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 49939 HEAP32[i7 >> 2] = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 12 >> 2] & 31](i2, i4, i5) | 0;
michael@0 49940 HEAP8[i3] = 1;
michael@0 49941 return;
michael@0 49942 }
michael@0 49943 function __ZN6btDbvt6insertERK12btDbvtAabbMmPv(i1, i2, i3) {
michael@0 49944 i1 = i1 | 0;
michael@0 49945 i2 = i2 | 0;
michael@0 49946 i3 = i3 | 0;
michael@0 49947 var i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 49948 i4 = i1 + 4 | 0;
michael@0 49949 i5 = HEAP32[i4 >> 2] | 0;
michael@0 49950 do {
michael@0 49951 if ((i5 | 0) == 0) {
michael@0 49952 i6 = __Z22btAlignedAllocInternalji(44, 16) | 0;
michael@0 49953 if ((i6 | 0) == 0) {
michael@0 49954 i7 = 0;
michael@0 49955 break;
michael@0 49956 }
michael@0 49957 _memset(i6 | 0, 0, 44);
michael@0 49958 i7 = i6;
michael@0 49959 } else {
michael@0 49960 HEAP32[i4 >> 2] = 0;
michael@0 49961 i7 = i5;
michael@0 49962 }
michael@0 49963 } while (0);
michael@0 49964 HEAP32[i7 + 32 >> 2] = 0;
michael@0 49965 HEAP32[i7 + 36 >> 2] = i3;
michael@0 49966 HEAP32[i7 + 40 >> 2] = 0;
michael@0 49967 i3 = i7;
michael@0 49968 i5 = i2;
michael@0 49969 _memcpy(i3 | 0, i5 | 0, 32) | 0;
michael@0 49970 __ZL10insertleafP6btDbvtP10btDbvtNodeS2_(i1, HEAP32[i1 >> 2] | 0, i7);
michael@0 49971 i5 = i1 + 12 | 0;
michael@0 49972 HEAP32[i5 >> 2] = (HEAP32[i5 >> 2] | 0) + 1;
michael@0 49973 return i7 | 0;
michael@0 49974 }
michael@0 49975 function __ZN34btSphereTriangleCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 49976 i1 = i1 | 0;
michael@0 49977 i2 = i2 | 0;
michael@0 49978 i3 = i3 | 0;
michael@0 49979 i4 = i4 | 0;
michael@0 49980 var i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 49981 i5 = HEAP32[i2 >> 2] | 0;
michael@0 49982 i6 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i5 >> 2] | 0) + 56 >> 2] & 63](i5, 20) | 0;
michael@0 49983 if ((i6 | 0) == 0) {
michael@0 49984 i7 = 0;
michael@0 49985 i8 = i7 | 0;
michael@0 49986 return i8 | 0;
michael@0 49987 }
michael@0 49988 i5 = i6;
michael@0 49989 __ZN34btSphereTriangleCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_b(i5, HEAP32[i2 + 4 >> 2] | 0, i2, i3, i4, (HEAP8[i1 + 4 | 0] | 0) != 0);
michael@0 49990 i7 = i5;
michael@0 49991 i8 = i7 | 0;
michael@0 49992 return i8 | 0;
michael@0 49993 }
michael@0 49994 function __ZN16btPointCollector15addContactPointERK9btVector3S2_f(i1, i2, i3, d4) {
michael@0 49995 i1 = i1 | 0;
michael@0 49996 i2 = i2 | 0;
michael@0 49997 i3 = i3 | 0;
michael@0 49998 d4 = +d4;
michael@0 49999 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50000 i5 = i1 + 36 | 0;
michael@0 50001 if (+HEAPF32[i5 >> 2] <= d4) {
michael@0 50002 return;
michael@0 50003 }
michael@0 50004 HEAP8[i1 + 40 | 0] = 1;
michael@0 50005 i6 = i1 + 4 | 0;
michael@0 50006 i7 = i2;
michael@0 50007 HEAP32[i6 >> 2] = HEAP32[i7 >> 2];
michael@0 50008 HEAP32[i6 + 4 >> 2] = HEAP32[i7 + 4 >> 2];
michael@0 50009 HEAP32[i6 + 8 >> 2] = HEAP32[i7 + 8 >> 2];
michael@0 50010 HEAP32[i6 + 12 >> 2] = HEAP32[i7 + 12 >> 2];
michael@0 50011 i7 = i1 + 20 | 0;
michael@0 50012 i1 = i3;
michael@0 50013 HEAP32[i7 >> 2] = HEAP32[i1 >> 2];
michael@0 50014 HEAP32[i7 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 50015 HEAP32[i7 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 50016 HEAP32[i7 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 50017 HEAPF32[i5 >> 2] = d4;
michael@0 50018 return;
michael@0 50019 }
michael@0 50020 function __ZNK10__cxxabiv117__class_type_info27has_unambiguous_public_baseEPNS_19__dynamic_cast_infoEPvi(i1, i2, i3, i4) {
michael@0 50021 i1 = i1 | 0;
michael@0 50022 i2 = i2 | 0;
michael@0 50023 i3 = i3 | 0;
michael@0 50024 i4 = i4 | 0;
michael@0 50025 var i5 = 0;
michael@0 50026 if ((HEAP32[i2 + 8 >> 2] | 0) != (i1 | 0)) {
michael@0 50027 return;
michael@0 50028 }
michael@0 50029 i1 = i2 + 16 | 0;
michael@0 50030 i5 = HEAP32[i1 >> 2] | 0;
michael@0 50031 if ((i5 | 0) == 0) {
michael@0 50032 HEAP32[i1 >> 2] = i3;
michael@0 50033 HEAP32[i2 + 24 >> 2] = i4;
michael@0 50034 HEAP32[i2 + 36 >> 2] = 1;
michael@0 50035 return;
michael@0 50036 }
michael@0 50037 if ((i5 | 0) != (i3 | 0)) {
michael@0 50038 i3 = i2 + 36 | 0;
michael@0 50039 HEAP32[i3 >> 2] = (HEAP32[i3 >> 2] | 0) + 1;
michael@0 50040 HEAP32[i2 + 24 >> 2] = 2;
michael@0 50041 HEAP8[i2 + 54 | 0] = 1;
michael@0 50042 return;
michael@0 50043 }
michael@0 50044 i3 = i2 + 24 | 0;
michael@0 50045 if ((HEAP32[i3 >> 2] | 0) != 2) {
michael@0 50046 return;
michael@0 50047 }
michael@0 50048 HEAP32[i3 >> 2] = i4;
michael@0 50049 return;
michael@0 50050 }
michael@0 50051 function __ZNK13btConvexShape19getMarginNonVirtualEv(i1) {
michael@0 50052 i1 = i1 | 0;
michael@0 50053 var d2 = 0.0;
michael@0 50054 switch (HEAP32[i1 + 4 >> 2] | 0) {
michael@0 50055 case 0:
michael@0 50056 {
michael@0 50057 d2 = +HEAPF32[i1 + 44 >> 2];
michael@0 50058 return +d2;
michael@0 50059 }
michael@0 50060 case 13:
michael@0 50061 {
michael@0 50062 d2 = +HEAPF32[i1 + 44 >> 2];
michael@0 50063 return +d2;
michael@0 50064 }
michael@0 50065 case 1:
michael@0 50066 {
michael@0 50067 d2 = +HEAPF32[i1 + 44 >> 2];
michael@0 50068 return +d2;
michael@0 50069 }
michael@0 50070 case 5:
michael@0 50071 case 4:
michael@0 50072 {
michael@0 50073 d2 = +HEAPF32[i1 + 44 >> 2];
michael@0 50074 return +d2;
michael@0 50075 }
michael@0 50076 case 8:
michael@0 50077 {
michael@0 50078 d2 = +HEAPF32[i1 + 28 >> 2] * +HEAPF32[i1 + 12 >> 2];
michael@0 50079 return +d2;
michael@0 50080 }
michael@0 50081 case 10:
michael@0 50082 {
michael@0 50083 d2 = +HEAPF32[i1 + 44 >> 2];
michael@0 50084 return +d2;
michael@0 50085 }
michael@0 50086 default:
michael@0 50087 {
michael@0 50088 d2 = +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i1 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 50089 return +d2;
michael@0 50090 }
michael@0 50091 }
michael@0 50092 return 0.0;
michael@0 50093 }
michael@0 50094 function __ZN19btSingleRayCallback7processEPK17btBroadphaseProxy(i1, i2) {
michael@0 50095 i1 = i1 | 0;
michael@0 50096 i2 = i2 | 0;
michael@0 50097 var i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 50098 i3 = i1 + 216 | 0;
michael@0 50099 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50100 if (+HEAPF32[i4 + 4 >> 2] == 0.0) {
michael@0 50101 i5 = 0;
michael@0 50102 return i5 | 0;
michael@0 50103 }
michael@0 50104 i6 = HEAP32[i2 >> 2] | 0;
michael@0 50105 if (!(FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 8 >> 2] & 63](i4, HEAP32[i6 + 188 >> 2] | 0) | 0)) {
michael@0 50106 i5 = 1;
michael@0 50107 return i5 | 0;
michael@0 50108 }
michael@0 50109 __ZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackE(i1 + 68 | 0, i1 + 132 | 0, i6, HEAP32[i6 + 192 >> 2] | 0, i6 + 4 | 0, HEAP32[i3 >> 2] | 0);
michael@0 50110 i5 = 1;
michael@0 50111 return i5 | 0;
michael@0 50112 }
michael@0 50113 function __ZN32btSphereSphereCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_(i1, i2, i3, i4, i5) {
michael@0 50114 i1 = i1 | 0;
michael@0 50115 i2 = i2 | 0;
michael@0 50116 i3 = i3 | 0;
michael@0 50117 i4 = i4 | 0;
michael@0 50118 i5 = i5 | 0;
michael@0 50119 var i6 = 0;
michael@0 50120 __ZN30btActivatingCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1 | 0, i3, i4, i5);
michael@0 50121 HEAP32[i1 >> 2] = 2568;
michael@0 50122 i3 = i1 + 8 | 0;
michael@0 50123 HEAP8[i3] = 0;
michael@0 50124 i6 = i1 + 12 | 0;
michael@0 50125 HEAP32[i6 >> 2] = i2;
michael@0 50126 if ((i2 | 0) != 0) {
michael@0 50127 return;
michael@0 50128 }
michael@0 50129 i2 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 50130 HEAP32[i6 >> 2] = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 12 >> 2] & 31](i2, i4, i5) | 0;
michael@0 50131 HEAP8[i3] = 1;
michael@0 50132 return;
michael@0 50133 }
michael@0 50134 function __ZN28btCompoundCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 50135 i1 = i1 | 0;
michael@0 50136 i2 = i2 | 0;
michael@0 50137 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 50138 i3 = i1 + 12 | 0;
michael@0 50139 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50140 if ((i4 | 0) <= 0) {
michael@0 50141 return;
michael@0 50142 }
michael@0 50143 i5 = i1 + 20 | 0;
michael@0 50144 i1 = 0;
michael@0 50145 i6 = i4;
michael@0 50146 while (1) {
michael@0 50147 i4 = HEAP32[(HEAP32[i5 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 50148 if ((i4 | 0) == 0) {
michael@0 50149 i7 = i6;
michael@0 50150 } else {
michael@0 50151 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i4 >> 2] | 0) + 16 >> 2] & 127](i4, i2);
michael@0 50152 i7 = HEAP32[i3 >> 2] | 0;
michael@0 50153 }
michael@0 50154 i4 = i1 + 1 | 0;
michael@0 50155 if ((i4 | 0) < (i7 | 0)) {
michael@0 50156 i1 = i4;
michael@0 50157 i6 = i7;
michael@0 50158 } else {
michael@0 50159 break;
michael@0 50160 }
michael@0 50161 }
michael@0 50162 return;
michael@0 50163 }
michael@0 50164 function __ZNK21btConvexInternalShape9serializeEPvP12btSerializer(i1, i2, i3) {
michael@0 50165 i1 = i1 | 0;
michael@0 50166 i2 = i2 | 0;
michael@0 50167 i3 = i3 | 0;
michael@0 50168 __ZNK16btCollisionShape9serializeEPvP12btSerializer(i1 | 0, i2, i3) | 0;
michael@0 50169 HEAPF32[i2 + 28 >> 2] = +HEAPF32[i1 + 28 >> 2];
michael@0 50170 HEAPF32[i2 + 32 >> 2] = +HEAPF32[i1 + 32 >> 2];
michael@0 50171 HEAPF32[i2 + 36 >> 2] = +HEAPF32[i1 + 36 >> 2];
michael@0 50172 HEAPF32[i2 + 40 >> 2] = +HEAPF32[i1 + 40 >> 2];
michael@0 50173 HEAPF32[i2 + 12 >> 2] = +HEAPF32[i1 + 12 >> 2];
michael@0 50174 HEAPF32[i2 + 16 >> 2] = +HEAPF32[i1 + 16 >> 2];
michael@0 50175 HEAPF32[i2 + 20 >> 2] = +HEAPF32[i1 + 20 >> 2];
michael@0 50176 HEAPF32[i2 + 24 >> 2] = +HEAPF32[i1 + 24 >> 2];
michael@0 50177 HEAPF32[i2 + 44 >> 2] = +HEAPF32[i1 + 44 >> 2];
michael@0 50178 return 800;
michael@0 50179 }
michael@0 50180 function __ZN23btDiscreteDynamicsWorld12removeActionEP17btActionInterface(i1, i2) {
michael@0 50181 i1 = i1 | 0;
michael@0 50182 i2 = i2 | 0;
michael@0 50183 var i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 50184 i3 = i1 + 248 | 0;
michael@0 50185 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50186 i5 = i1 + 256 | 0;
michael@0 50187 i1 = 0;
michael@0 50188 while (1) {
michael@0 50189 if ((i1 | 0) >= (i4 | 0)) {
michael@0 50190 i6 = 422;
michael@0 50191 break;
michael@0 50192 }
michael@0 50193 i7 = HEAP32[i5 >> 2] | 0;
michael@0 50194 i8 = i7 + (i1 << 2) | 0;
michael@0 50195 if ((HEAP32[i8 >> 2] | 0) == (i2 | 0)) {
michael@0 50196 break;
michael@0 50197 } else {
michael@0 50198 i1 = i1 + 1 | 0;
michael@0 50199 }
michael@0 50200 }
michael@0 50201 if ((i6 | 0) == 422) {
michael@0 50202 return;
michael@0 50203 }
michael@0 50204 i6 = i4 - 1 | 0;
michael@0 50205 HEAP32[i8 >> 2] = HEAP32[i7 + (i6 << 2) >> 2];
michael@0 50206 HEAP32[(HEAP32[i5 >> 2] | 0) + (i6 << 2) >> 2] = i2;
michael@0 50207 HEAP32[i3 >> 2] = i6;
michael@0 50208 return;
michael@0 50209 }
michael@0 50210 function __ZN25btTriangleRaycastCallbackC2ERK9btVector3S2_j(i1, i2, i3, i4) {
michael@0 50211 i1 = i1 | 0;
michael@0 50212 i2 = i2 | 0;
michael@0 50213 i3 = i3 | 0;
michael@0 50214 i4 = i4 | 0;
michael@0 50215 var i5 = 0, i6 = 0;
michael@0 50216 HEAP32[i1 >> 2] = 3e3;
michael@0 50217 i5 = i1 + 4 | 0;
michael@0 50218 i6 = i2;
michael@0 50219 HEAP32[i5 >> 2] = HEAP32[i6 >> 2];
michael@0 50220 HEAP32[i5 + 4 >> 2] = HEAP32[i6 + 4 >> 2];
michael@0 50221 HEAP32[i5 + 8 >> 2] = HEAP32[i6 + 8 >> 2];
michael@0 50222 HEAP32[i5 + 12 >> 2] = HEAP32[i6 + 12 >> 2];
michael@0 50223 i6 = i1 + 20 | 0;
michael@0 50224 i5 = i3;
michael@0 50225 HEAP32[i6 >> 2] = HEAP32[i5 >> 2];
michael@0 50226 HEAP32[i6 + 4 >> 2] = HEAP32[i5 + 4 >> 2];
michael@0 50227 HEAP32[i6 + 8 >> 2] = HEAP32[i5 + 8 >> 2];
michael@0 50228 HEAP32[i6 + 12 >> 2] = HEAP32[i5 + 12 >> 2];
michael@0 50229 HEAP32[i1 + 36 >> 2] = i4;
michael@0 50230 HEAPF32[i1 + 40 >> 2] = 1.0;
michael@0 50231 return;
michael@0 50232 }
michael@0 50233 function __ZNK10btBoxShape8isInsideERK9btVector3f(i1, i2, d3) {
michael@0 50234 i1 = i1 | 0;
michael@0 50235 i2 = i2 | 0;
michael@0 50236 d3 = +d3;
michael@0 50237 var d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0, i8 = 0;
michael@0 50238 d4 = +HEAPF32[i1 + 28 >> 2];
michael@0 50239 d5 = +HEAPF32[i1 + 32 >> 2];
michael@0 50240 d6 = +HEAPF32[i1 + 36 >> 2];
michael@0 50241 d7 = +HEAPF32[i2 >> 2];
michael@0 50242 if (d7 > d4 + d3) {
michael@0 50243 i8 = 0;
michael@0 50244 return i8 | 0;
michael@0 50245 }
michael@0 50246 if (d7 < -0.0 - d4 - d3) {
michael@0 50247 i8 = 0;
michael@0 50248 return i8 | 0;
michael@0 50249 }
michael@0 50250 d4 = +HEAPF32[i2 + 4 >> 2];
michael@0 50251 if (d4 > d5 + d3) {
michael@0 50252 i8 = 0;
michael@0 50253 return i8 | 0;
michael@0 50254 }
michael@0 50255 if (d4 < -0.0 - d5 - d3) {
michael@0 50256 i8 = 0;
michael@0 50257 return i8 | 0;
michael@0 50258 }
michael@0 50259 d5 = +HEAPF32[i2 + 8 >> 2];
michael@0 50260 if (d5 > d6 + d3) {
michael@0 50261 i8 = 0;
michael@0 50262 return i8 | 0;
michael@0 50263 }
michael@0 50264 i8 = d5 >= -0.0 - d6 - d3;
michael@0 50265 return i8 | 0;
michael@0 50266 }
michael@0 50267 function ___divdi3(i1, i2, i3, i4) {
michael@0 50268 i1 = i1 | 0;
michael@0 50269 i2 = i2 | 0;
michael@0 50270 i3 = i3 | 0;
michael@0 50271 i4 = i4 | 0;
michael@0 50272 var i5 = 0, i6 = 0, i7 = 0, i8 = 0, i9 = 0;
michael@0 50273 i5 = i2 >> 31 | ((i2 | 0) < 0 ? -1 : 0) << 1;
michael@0 50274 i6 = ((i2 | 0) < 0 ? -1 : 0) >> 31 | ((i2 | 0) < 0 ? -1 : 0) << 1;
michael@0 50275 i7 = i4 >> 31 | ((i4 | 0) < 0 ? -1 : 0) << 1;
michael@0 50276 i8 = ((i4 | 0) < 0 ? -1 : 0) >> 31 | ((i4 | 0) < 0 ? -1 : 0) << 1;
michael@0 50277 i9 = _i64Subtract(i5 ^ i1, i6 ^ i2, i5, i6) | 0;
michael@0 50278 i2 = tempRet0;
michael@0 50279 i1 = i7 ^ i5;
michael@0 50280 i5 = i8 ^ i6;
michael@0 50281 i6 = _i64Subtract((___udivmoddi4(i9, i2, _i64Subtract(i7 ^ i3, i8 ^ i4, i7, i8) | 0, tempRet0, 0) | 0) ^ i1, tempRet0 ^ i5, i1, i5) | 0;
michael@0 50282 return (tempRet0 = tempRet0, i6) | 0;
michael@0 50283 }
michael@0 50284 function __ZN6btDbvt5clearEv(i1) {
michael@0 50285 i1 = i1 | 0;
michael@0 50286 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 50287 i2 = HEAP32[i1 >> 2] | 0;
michael@0 50288 if ((i2 | 0) != 0) {
michael@0 50289 __ZL17recursedeletenodeP6btDbvtP10btDbvtNode(i1, i2);
michael@0 50290 }
michael@0 50291 i2 = i1 + 4 | 0;
michael@0 50292 __Z21btAlignedFreeInternalPv(HEAP32[i2 >> 2] | 0);
michael@0 50293 HEAP32[i2 >> 2] = 0;
michael@0 50294 HEAP32[i1 + 8 >> 2] = -1;
michael@0 50295 i2 = i1 + 24 | 0;
michael@0 50296 i3 = i1 + 32 | 0;
michael@0 50297 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50298 i5 = i1 + 36 | 0;
michael@0 50299 if ((i4 | 0) != 0) {
michael@0 50300 if ((HEAP8[i5] | 0) != 0) {
michael@0 50301 __Z21btAlignedFreeInternalPv(i4);
michael@0 50302 }
michael@0 50303 HEAP32[i3 >> 2] = 0;
michael@0 50304 }
michael@0 50305 HEAP8[i5] = 1;
michael@0 50306 HEAP32[i3 >> 2] = 0;
michael@0 50307 HEAP32[i2 >> 2] = 0;
michael@0 50308 HEAP32[i1 + 28 >> 2] = 0;
michael@0 50309 HEAP32[i1 + 16 >> 2] = 0;
michael@0 50310 return;
michael@0 50311 }
michael@0 50312 function __ZN6btDbvtD2Ev(i1) {
michael@0 50313 i1 = i1 | 0;
michael@0 50314 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 50315 i2 = HEAP32[i1 >> 2] | 0;
michael@0 50316 if ((i2 | 0) != 0) {
michael@0 50317 __ZL17recursedeletenodeP6btDbvtP10btDbvtNode(i1, i2);
michael@0 50318 }
michael@0 50319 i2 = i1 + 4 | 0;
michael@0 50320 __Z21btAlignedFreeInternalPv(HEAP32[i2 >> 2] | 0);
michael@0 50321 HEAP32[i2 >> 2] = 0;
michael@0 50322 HEAP32[i1 + 8 >> 2] = -1;
michael@0 50323 i2 = i1 + 24 | 0;
michael@0 50324 i3 = i1 + 32 | 0;
michael@0 50325 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50326 i5 = i1 + 36 | 0;
michael@0 50327 if ((i4 | 0) != 0) {
michael@0 50328 if ((HEAP8[i5] | 0) != 0) {
michael@0 50329 __Z21btAlignedFreeInternalPv(i4);
michael@0 50330 }
michael@0 50331 HEAP32[i3 >> 2] = 0;
michael@0 50332 }
michael@0 50333 HEAP32[i1 + 16 >> 2] = 0;
michael@0 50334 HEAP8[i5] = 1;
michael@0 50335 HEAP32[i3 >> 2] = 0;
michael@0 50336 HEAP32[i2 >> 2] = 0;
michael@0 50337 HEAP32[i1 + 28 >> 2] = 0;
michael@0 50338 return;
michael@0 50339 }
michael@0 50340 function __ZN32btSphereSphereCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 50341 i1 = i1 | 0;
michael@0 50342 i2 = i2 | 0;
michael@0 50343 i3 = i3 | 0;
michael@0 50344 i4 = i4 | 0;
michael@0 50345 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50346 i1 = HEAP32[i2 >> 2] | 0;
michael@0 50347 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i1 >> 2] | 0) + 56 >> 2] & 63](i1, 16) | 0;
michael@0 50348 if ((i5 | 0) == 0) {
michael@0 50349 i6 = 0;
michael@0 50350 i7 = i6 | 0;
michael@0 50351 return i7 | 0;
michael@0 50352 }
michael@0 50353 i1 = i5;
michael@0 50354 __ZN32btSphereSphereCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_(i1, 0, i2, i3, i4);
michael@0 50355 i6 = i1;
michael@0 50356 i7 = i6 | 0;
michael@0 50357 return i7 | 0;
michael@0 50358 }
michael@0 50359 function __ZN11btRigidBody10setGravityERK9btVector3(i1, i2) {
michael@0 50360 i1 = i1 | 0;
michael@0 50361 i2 = i2 | 0;
michael@0 50362 var d3 = 0.0, d4 = 0.0, d5 = 0.0, i6 = 0;
michael@0 50363 d3 = +HEAPF32[i1 + 336 >> 2];
michael@0 50364 if (d3 != 0.0) {
michael@0 50365 d4 = 1.0 / d3;
michael@0 50366 d3 = d4 * +HEAPF32[i2 + 4 >> 2];
michael@0 50367 d5 = d4 * +HEAPF32[i2 + 8 >> 2];
michael@0 50368 HEAPF32[i1 + 356 >> 2] = d4 * +HEAPF32[i2 >> 2];
michael@0 50369 HEAPF32[i1 + 360 >> 2] = d3;
michael@0 50370 HEAPF32[i1 + 364 >> 2] = d5;
michael@0 50371 HEAPF32[i1 + 368 >> 2] = 0.0;
michael@0 50372 }
michael@0 50373 i6 = i1 + 372 | 0;
michael@0 50374 i1 = i2;
michael@0 50375 HEAP32[i6 >> 2] = HEAP32[i1 >> 2];
michael@0 50376 HEAP32[i6 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 50377 HEAP32[i6 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 50378 HEAP32[i6 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 50379 return;
michael@0 50380 }
michael@0 50381 function __ZNK16btCollisionWorld7rayTestERK9btVector3S2_RNS_17RayResultCallbackE(i1, i2, i3, i4) {
michael@0 50382 i1 = i1 | 0;
michael@0 50383 i2 = i2 | 0;
michael@0 50384 i3 = i3 | 0;
michael@0 50385 i4 = i4 | 0;
michael@0 50386 var i5 = 0, i6 = 0, i7 = 0, i8 = 0;
michael@0 50387 i5 = STACKTOP;
michael@0 50388 STACKTOP = STACKTOP + 256 | 0;
michael@0 50389 i6 = i5 | 0;
michael@0 50390 i7 = i5 + 224 | 0;
michael@0 50391 i8 = i5 + 240 | 0;
michael@0 50392 __ZN19btSingleRayCallbackC2ERK9btVector3S2_PK16btCollisionWorldRNS3_17RayResultCallbackE(i6, i2, i3, i1, i4);
michael@0 50393 i4 = HEAP32[i1 + 76 >> 2] | 0;
michael@0 50394 i1 = HEAP32[(HEAP32[i4 >> 2] | 0) + 24 >> 2] | 0;
michael@0 50395 _memset(i7 | 0, 0, 16);
michael@0 50396 _memset(i8 | 0, 0, 16);
michael@0 50397 FUNCTION_TABLE_viiiiii[i1 & 15](i4, i2, i3, i6 | 0, i7, i8);
michael@0 50398 STACKTOP = i5;
michael@0 50399 return;
michael@0 50400 }
michael@0 50401 function __ZN22btVoronoiSimplexSolver14compute_pointsER9btVector3S1_(i1, i2, i3) {
michael@0 50402 i1 = i1 | 0;
michael@0 50403 i2 = i2 | 0;
michael@0 50404 i3 = i3 | 0;
michael@0 50405 var i4 = 0;
michael@0 50406 __ZN22btVoronoiSimplexSolver28updateClosestVectorAndPointsEv(i1) | 0;
michael@0 50407 i4 = i2;
michael@0 50408 i2 = i1 + 244 | 0;
michael@0 50409 HEAP32[i4 >> 2] = HEAP32[i2 >> 2];
michael@0 50410 HEAP32[i4 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 50411 HEAP32[i4 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 50412 HEAP32[i4 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 50413 i2 = i3;
michael@0 50414 i3 = i1 + 260 | 0;
michael@0 50415 HEAP32[i2 >> 2] = HEAP32[i3 >> 2];
michael@0 50416 HEAP32[i2 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 50417 HEAP32[i2 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 50418 HEAP32[i2 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 50419 return;
michael@0 50420 }
michael@0 50421 function __ZN26btBoxBoxCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 50422 i1 = i1 | 0;
michael@0 50423 i2 = i2 | 0;
michael@0 50424 i3 = i3 | 0;
michael@0 50425 i4 = i4 | 0;
michael@0 50426 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50427 i1 = HEAP32[i2 >> 2] | 0;
michael@0 50428 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i1 >> 2] | 0) + 56 >> 2] & 63](i1, 16) | 0;
michael@0 50429 if ((i5 | 0) == 0) {
michael@0 50430 i6 = 0;
michael@0 50431 i7 = i6 | 0;
michael@0 50432 return i7 | 0;
michael@0 50433 }
michael@0 50434 i1 = i5;
michael@0 50435 __ZN26btBoxBoxCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_(i1, 0, i2, i3, i4);
michael@0 50436 i6 = i1;
michael@0 50437 i7 = i6 | 0;
michael@0 50438 return i7 | 0;
michael@0 50439 }
michael@0 50440 function __ZN33btConvexConcaveCollisionAlgorithm17SwappedCreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 50441 i1 = i1 | 0;
michael@0 50442 i2 = i2 | 0;
michael@0 50443 i3 = i3 | 0;
michael@0 50444 i4 = i4 | 0;
michael@0 50445 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50446 i1 = HEAP32[i2 >> 2] | 0;
michael@0 50447 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i1 >> 2] | 0) + 56 >> 2] & 63](i1, 80) | 0;
michael@0 50448 if ((i5 | 0) == 0) {
michael@0 50449 i6 = 0;
michael@0 50450 i7 = i6 | 0;
michael@0 50451 return i7 | 0;
michael@0 50452 }
michael@0 50453 i1 = i5;
michael@0 50454 __ZN33btConvexConcaveCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b(i1, i2, i3, i4, 1);
michael@0 50455 i6 = i1;
michael@0 50456 i7 = i6 | 0;
michael@0 50457 return i7 | 0;
michael@0 50458 }
michael@0 50459 function __ZNK34btClosestNotMeConvexResultCallback14needsCollisionEP17btBroadphaseProxy(i1, i2) {
michael@0 50460 i1 = i1 | 0;
michael@0 50461 i2 = i2 | 0;
michael@0 50462 var i3 = 0, i4 = 0, i5 = 0;
michael@0 50463 i3 = HEAP32[i2 >> 2] | 0;
michael@0 50464 i4 = HEAP32[i1 + 80 >> 2] | 0;
michael@0 50465 if ((i3 | 0) == (i4 | 0)) {
michael@0 50466 i5 = 0;
michael@0 50467 return i5 | 0;
michael@0 50468 }
michael@0 50469 if ((HEAP16[i1 + 10 >> 1] & HEAP16[i2 + 4 >> 1]) << 16 >> 16 == 0) {
michael@0 50470 i5 = 0;
michael@0 50471 return i5 | 0;
michael@0 50472 }
michael@0 50473 if ((HEAP16[i2 + 6 >> 1] & HEAP16[i1 + 8 >> 1]) << 16 >> 16 == 0) {
michael@0 50474 i5 = 0;
michael@0 50475 return i5 | 0;
michael@0 50476 }
michael@0 50477 i2 = HEAP32[i1 + 92 >> 2] | 0;
michael@0 50478 i5 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 28 >> 2] & 31](i2, i4, i3) | 0;
michael@0 50479 return i5 | 0;
michael@0 50480 }
michael@0 50481 function __ZN33btConvexConcaveCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 50482 i1 = i1 | 0;
michael@0 50483 i2 = i2 | 0;
michael@0 50484 i3 = i3 | 0;
michael@0 50485 i4 = i4 | 0;
michael@0 50486 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50487 i1 = HEAP32[i2 >> 2] | 0;
michael@0 50488 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i1 >> 2] | 0) + 56 >> 2] & 63](i1, 80) | 0;
michael@0 50489 if ((i5 | 0) == 0) {
michael@0 50490 i6 = 0;
michael@0 50491 i7 = i6 | 0;
michael@0 50492 return i7 | 0;
michael@0 50493 }
michael@0 50494 i1 = i5;
michael@0 50495 __ZN33btConvexConcaveCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b(i1, i2, i3, i4, 0);
michael@0 50496 i6 = i1;
michael@0 50497 i7 = i6 | 0;
michael@0 50498 return i7 | 0;
michael@0 50499 }
michael@0 50500 function __ZN28btCompoundCollisionAlgorithm17SwappedCreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 50501 i1 = i1 | 0;
michael@0 50502 i2 = i2 | 0;
michael@0 50503 i3 = i3 | 0;
michael@0 50504 i4 = i4 | 0;
michael@0 50505 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50506 i1 = HEAP32[i2 >> 2] | 0;
michael@0 50507 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i1 >> 2] | 0) + 56 >> 2] & 63](i1, 44) | 0;
michael@0 50508 if ((i5 | 0) == 0) {
michael@0 50509 i6 = 0;
michael@0 50510 i7 = i6 | 0;
michael@0 50511 return i7 | 0;
michael@0 50512 }
michael@0 50513 i1 = i5;
michael@0 50514 __ZN28btCompoundCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b(i1, i2, i3, i4, 1);
michael@0 50515 i6 = i1;
michael@0 50516 i7 = i6 | 0;
michael@0 50517 return i7 | 0;
michael@0 50518 }
michael@0 50519 function __ZN23btDiscreteDynamicsWorld12applyGravityEv(i1) {
michael@0 50520 i1 = i1 | 0;
michael@0 50521 var i2 = 0, i3 = 0, i4 = 0, i5 = 0, i6 = 0, i7 = 0;
michael@0 50522 i2 = i1 + 204 | 0;
michael@0 50523 i3 = HEAP32[i2 >> 2] | 0;
michael@0 50524 if ((i3 | 0) <= 0) {
michael@0 50525 return;
michael@0 50526 }
michael@0 50527 i4 = i1 + 212 | 0;
michael@0 50528 i1 = 0;
michael@0 50529 i5 = i3;
michael@0 50530 while (1) {
michael@0 50531 i3 = HEAP32[(HEAP32[i4 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 50532 i6 = HEAP32[i3 + 216 >> 2] | 0;
michael@0 50533 if ((i6 | 0) == 5 | (i6 | 0) == 2) {
michael@0 50534 i7 = i5;
michael@0 50535 } else {
michael@0 50536 __ZN11btRigidBody12applyGravityEv(i3);
michael@0 50537 i7 = HEAP32[i2 >> 2] | 0;
michael@0 50538 }
michael@0 50539 i3 = i1 + 1 | 0;
michael@0 50540 if ((i3 | 0) < (i7 | 0)) {
michael@0 50541 i1 = i3;
michael@0 50542 i5 = i7;
michael@0 50543 } else {
michael@0 50544 break;
michael@0 50545 }
michael@0 50546 }
michael@0 50547 return;
michael@0 50548 }
michael@0 50549 function __ZN28btCompoundCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 50550 i1 = i1 | 0;
michael@0 50551 i2 = i2 | 0;
michael@0 50552 i3 = i3 | 0;
michael@0 50553 i4 = i4 | 0;
michael@0 50554 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50555 i1 = HEAP32[i2 >> 2] | 0;
michael@0 50556 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i1 >> 2] | 0) + 56 >> 2] & 63](i1, 44) | 0;
michael@0 50557 if ((i5 | 0) == 0) {
michael@0 50558 i6 = 0;
michael@0 50559 i7 = i6 | 0;
michael@0 50560 return i7 | 0;
michael@0 50561 }
michael@0 50562 i1 = i5;
michael@0 50563 __ZN28btCompoundCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b(i1, i2, i3, i4, 0);
michael@0 50564 i6 = i1;
michael@0 50565 i7 = i6 | 0;
michael@0 50566 return i7 | 0;
michael@0 50567 }
michael@0 50568 function __ZN21btCollisionDispatcher22freeCollisionAlgorithmEPv(i1, i2) {
michael@0 50569 i1 = i1 | 0;
michael@0 50570 i2 = i2 | 0;
michael@0 50571 var i3 = 0;
michael@0 50572 i3 = HEAP32[i1 + 192 >> 2] | 0;
michael@0 50573 do {
michael@0 50574 if ((i2 | 0) != 0) {
michael@0 50575 i1 = HEAP32[i3 + 16 >> 2] | 0;
michael@0 50576 if (i1 >>> 0 > i2 >>> 0) {
michael@0 50577 break;
michael@0 50578 }
michael@0 50579 if ((i1 + (Math_imul(HEAP32[i3 >> 2] | 0, HEAP32[i3 + 4 >> 2] | 0) | 0) | 0) >>> 0 <= i2 >>> 0) {
michael@0 50580 break;
michael@0 50581 }
michael@0 50582 i1 = i3 + 12 | 0;
michael@0 50583 HEAP32[i2 >> 2] = HEAP32[i1 >> 2];
michael@0 50584 HEAP32[i1 >> 2] = i2;
michael@0 50585 i1 = i3 + 8 | 0;
michael@0 50586 HEAP32[i1 >> 2] = (HEAP32[i1 >> 2] | 0) + 1;
michael@0 50587 return;
michael@0 50588 }
michael@0 50589 } while (0);
michael@0 50590 __Z21btAlignedFreeInternalPv(i2);
michael@0 50591 return;
michael@0 50592 }
michael@0 50593 function __ZN23btDiscreteDynamicsWorld14updateVehiclesEf(i1, d2) {
michael@0 50594 i1 = i1 | 0;
michael@0 50595 d2 = +d2;
michael@0 50596 var i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 50597 __ZN15CProfileManager13Start_ProfileEPKc(456);
michael@0 50598 i3 = i1 + 248 | 0;
michael@0 50599 if ((HEAP32[i3 >> 2] | 0) <= 0) {
michael@0 50600 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 50601 return;
michael@0 50602 }
michael@0 50603 i4 = i1 + 256 | 0;
michael@0 50604 i5 = i1 | 0;
michael@0 50605 i1 = 0;
michael@0 50606 do {
michael@0 50607 i6 = HEAP32[(HEAP32[i4 >> 2] | 0) + (i1 << 2) >> 2] | 0;
michael@0 50608 FUNCTION_TABLE_viif[HEAP32[(HEAP32[i6 >> 2] | 0) + 8 >> 2] & 3](i6, i5, d2);
michael@0 50609 i1 = i1 + 1 | 0;
michael@0 50610 } while ((i1 | 0) < (HEAP32[i3 >> 2] | 0));
michael@0 50611 __ZN15CProfileManager12Stop_ProfileEv();
michael@0 50612 return;
michael@0 50613 }
michael@0 50614 function __ZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_(i1, i2, i3, i4, i5, i6) {
michael@0 50615 i1 = i1 | 0;
michael@0 50616 i2 = i2 | 0;
michael@0 50617 i3 = i3 | 0;
michael@0 50618 i4 = i4 | 0;
michael@0 50619 i5 = i5 | 0;
michael@0 50620 i6 = i6 | 0;
michael@0 50621 var i7 = 0, i8 = 0, i9 = 0;
michael@0 50622 i7 = STACKTOP;
michael@0 50623 STACKTOP = STACKTOP + 16 | 0;
michael@0 50624 i8 = i7 | 0;
michael@0 50625 i9 = HEAP32[i1 + 48 >> 2] | 0;
michael@0 50626 HEAP32[i8 >> 2] = 1592;
michael@0 50627 HEAP32[i8 + 4 >> 2] = i9;
michael@0 50628 HEAP32[i8 + 8 >> 2] = i2;
michael@0 50629 __ZNK14btQuantizedBvh29reportBoxCastOverlappingNodexEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_(HEAP32[i1 + 52 >> 2] | 0, i8 | 0, i3, i4, i5, i6);
michael@0 50630 STACKTOP = i7;
michael@0 50631 return;
michael@0 50632 }
michael@0 50633 function __ZNK14btQuantizedBvh29reportBoxCastOverlappingNodexEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_(i1, i2, i3, i4, i5, i6) {
michael@0 50634 i1 = i1 | 0;
michael@0 50635 i2 = i2 | 0;
michael@0 50636 i3 = i3 | 0;
michael@0 50637 i4 = i4 | 0;
michael@0 50638 i5 = i5 | 0;
michael@0 50639 i6 = i6 | 0;
michael@0 50640 if ((HEAP8[i1 + 60 | 0] | 0) == 0) {
michael@0 50641 __ZNK14btQuantizedBvh27walkStacklessTreeAgainstRayEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_ii(i1, i2, i3, i4, i5, i6, 0, 0);
michael@0 50642 return;
michael@0 50643 } else {
michael@0 50644 __ZNK14btQuantizedBvh36walkStacklessQuantizedTreeAgainstRayEP21btNodeOverlapCallbackRK9btVector3S4_S4_S4_ii(i1, i2, i3, i4, i5, i6, 0, HEAP32[i1 + 56 >> 2] | 0);
michael@0 50645 return;
michael@0 50646 }
michael@0 50647 }
michael@0 50648 function __ZN21btCollisionDispatcher13findAlgorithmEP17btCollisionObjectS1_P20btPersistentManifold(i1, i2, i3, i4) {
michael@0 50649 i1 = i1 | 0;
michael@0 50650 i2 = i2 | 0;
michael@0 50651 i3 = i3 | 0;
michael@0 50652 i4 = i4 | 0;
michael@0 50653 var i5 = 0, i6 = 0;
michael@0 50654 i5 = STACKTOP;
michael@0 50655 STACKTOP = STACKTOP + 8 | 0;
michael@0 50656 i6 = i5 | 0;
michael@0 50657 HEAP32[i6 >> 2] = i1;
michael@0 50658 HEAP32[i6 + 4 >> 2] = i4;
michael@0 50659 i4 = HEAP32[i1 + 200 + ((HEAP32[(HEAP32[i2 + 192 >> 2] | 0) + 4 >> 2] | 0) * 144 | 0) + (HEAP32[(HEAP32[i3 + 192 >> 2] | 0) + 4 >> 2] << 2) >> 2] | 0;
michael@0 50660 i1 = FUNCTION_TABLE_iiiii[HEAP32[(HEAP32[i4 >> 2] | 0) + 8 >> 2] & 31](i4, i6, i2, i3) | 0;
michael@0 50661 STACKTOP = i5;
michael@0 50662 return i1 | 0;
michael@0 50663 }
michael@0 50664 function __ZN33btConvexConcaveCollisionAlgorithmD0Ev(i1) {
michael@0 50665 i1 = i1 | 0;
michael@0 50666 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 50667 HEAP32[i1 >> 2] = 2528;
michael@0 50668 i2 = i1 + 12 | 0;
michael@0 50669 HEAP32[i2 >> 2] = 3104;
michael@0 50670 i3 = i1 + 60 | 0;
michael@0 50671 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50672 i5 = i1 + 76 | 0;
michael@0 50673 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i4 >> 2] | 0) + 20 >> 2] & 127](i4, HEAP32[i5 >> 2] | 0);
michael@0 50674 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50675 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i4 >> 2] | 0) + 16 >> 2] & 127](i4, HEAP32[i5 >> 2] | 0);
michael@0 50676 __ZN18btTriangleCallbackD2Ev(i2 | 0);
michael@0 50677 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 50678 __ZdlPv(i1);
michael@0 50679 return;
michael@0 50680 }
michael@0 50681 function __ZNK16btDbvtBroadphase7getAabbEP17btBroadphaseProxyR9btVector3S3_(i1, i2, i3, i4) {
michael@0 50682 i1 = i1 | 0;
michael@0 50683 i2 = i2 | 0;
michael@0 50684 i3 = i3 | 0;
michael@0 50685 i4 = i4 | 0;
michael@0 50686 i1 = i3;
michael@0 50687 i3 = i2 + 16 | 0;
michael@0 50688 HEAP32[i1 >> 2] = HEAP32[i3 >> 2];
michael@0 50689 HEAP32[i1 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 50690 HEAP32[i1 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 50691 HEAP32[i1 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 50692 i3 = i4;
michael@0 50693 i4 = i2 + 32 | 0;
michael@0 50694 HEAP32[i3 >> 2] = HEAP32[i4 >> 2];
michael@0 50695 HEAP32[i3 + 4 >> 2] = HEAP32[i4 + 4 >> 2];
michael@0 50696 HEAP32[i3 + 8 >> 2] = HEAP32[i4 + 8 >> 2];
michael@0 50697 HEAP32[i3 + 12 >> 2] = HEAP32[i4 + 12 >> 2];
michael@0 50698 return;
michael@0 50699 }
michael@0 50700 function __ZN33btConvexConcaveCollisionAlgorithmD2Ev(i1) {
michael@0 50701 i1 = i1 | 0;
michael@0 50702 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 50703 HEAP32[i1 >> 2] = 2528;
michael@0 50704 i2 = i1 + 12 | 0;
michael@0 50705 HEAP32[i2 >> 2] = 3104;
michael@0 50706 i3 = i1 + 60 | 0;
michael@0 50707 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50708 i5 = i1 + 76 | 0;
michael@0 50709 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i4 >> 2] | 0) + 20 >> 2] & 127](i4, HEAP32[i5 >> 2] | 0);
michael@0 50710 i4 = HEAP32[i3 >> 2] | 0;
michael@0 50711 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i4 >> 2] | 0) + 16 >> 2] & 127](i4, HEAP32[i5 >> 2] | 0);
michael@0 50712 __ZN18btTriangleCallbackD2Ev(i2 | 0);
michael@0 50713 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 50714 return;
michael@0 50715 }
michael@0 50716 function __ZL8pointCmpRKN20btConvexHullInternal7Point32ES2_(i1, i2) {
michael@0 50717 i1 = i1 | 0;
michael@0 50718 i2 = i2 | 0;
michael@0 50719 var i3 = 0, i4 = 0, i5 = 0;
michael@0 50720 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 50721 i4 = HEAP32[i2 + 4 >> 2] | 0;
michael@0 50722 if ((i3 | 0) < (i4 | 0)) {
michael@0 50723 i5 = 1;
michael@0 50724 return i5 | 0;
michael@0 50725 }
michael@0 50726 if ((i3 | 0) != (i4 | 0)) {
michael@0 50727 i5 = 0;
michael@0 50728 return i5 | 0;
michael@0 50729 }
michael@0 50730 i4 = HEAP32[i1 >> 2] | 0;
michael@0 50731 i3 = HEAP32[i2 >> 2] | 0;
michael@0 50732 if ((i4 | 0) < (i3 | 0)) {
michael@0 50733 i5 = 1;
michael@0 50734 return i5 | 0;
michael@0 50735 }
michael@0 50736 if ((i4 | 0) != (i3 | 0)) {
michael@0 50737 i5 = 0;
michael@0 50738 return i5 | 0;
michael@0 50739 }
michael@0 50740 i5 = (HEAP32[i1 + 8 >> 2] | 0) < (HEAP32[i2 + 8 >> 2] | 0);
michael@0 50741 return i5 | 0;
michael@0 50742 }
michael@0 50743 function __ZN21btCollisionDispatcher14needsCollisionEP17btCollisionObjectS1_(i1, i2, i3) {
michael@0 50744 i1 = i1 | 0;
michael@0 50745 i2 = i2 | 0;
michael@0 50746 i3 = i3 | 0;
michael@0 50747 var i4 = 0, i5 = 0;
michael@0 50748 i1 = HEAP32[i2 + 216 >> 2] | 0;
michael@0 50749 do {
michael@0 50750 if ((i1 | 0) == 5 | (i1 | 0) == 2) {
michael@0 50751 i4 = HEAP32[i3 + 216 >> 2] | 0;
michael@0 50752 if ((i4 | 0) == 5 | (i4 | 0) == 2) {
michael@0 50753 i5 = 0;
michael@0 50754 } else {
michael@0 50755 break;
michael@0 50756 }
michael@0 50757 return i5 | 0;
michael@0 50758 }
michael@0 50759 } while (0);
michael@0 50760 if ((HEAP32[i2 + 252 >> 2] | 0) == 0) {
michael@0 50761 i5 = 1;
michael@0 50762 return i5 | 0;
michael@0 50763 }
michael@0 50764 i5 = FUNCTION_TABLE_iii[HEAP32[HEAP32[i2 >> 2] >> 2] & 63](i2, i3) | 0;
michael@0 50765 return i5 | 0;
michael@0 50766 }
michael@0 50767 function __ZN16btDbvtBroadphase9resetPoolEP12btDispatcher(i1, i2) {
michael@0 50768 i1 = i1 | 0;
michael@0 50769 i2 = i2 | 0;
michael@0 50770 if ((HEAP32[i1 + 16 >> 2] | 0) != (-(HEAP32[i1 + 56 >> 2] | 0) | 0)) {
michael@0 50771 return;
michael@0 50772 }
michael@0 50773 __ZN6btDbvt5clearEv(i1 + 4 | 0);
michael@0 50774 __ZN6btDbvt5clearEv(i1 + 44 | 0);
michael@0 50775 HEAP8[i1 + 153 | 0] = 0;
michael@0 50776 HEAP8[i1 + 154 | 0] = 1;
michael@0 50777 HEAP32[i1 + 104 >> 2] = 0;
michael@0 50778 HEAP32[i1 + 124 >> 2] = 0;
michael@0 50779 HEAP32[i1 + 108 >> 2] = 1;
michael@0 50780 HEAP32[i1 + 112 >> 2] = 0;
michael@0 50781 HEAP32[i1 + 116 >> 2] = 10;
michael@0 50782 HEAP32[i1 + 120 >> 2] = 1;
michael@0 50783 _memset(i1 + 84 | 0, 0, 12);
michael@0 50784 _memset(i1 + 128 | 0, 0, 24);
michael@0 50785 return;
michael@0 50786 }
michael@0 50787 function _memcpy(i1, i2, i3) {
michael@0 50788 i1 = i1 | 0;
michael@0 50789 i2 = i2 | 0;
michael@0 50790 i3 = i3 | 0;
michael@0 50791 var i4 = 0;
michael@0 50792 i4 = i1 | 0;
michael@0 50793 if ((i1 & 3) == (i2 & 3)) {
michael@0 50794 while (i1 & 3) {
michael@0 50795 if ((i3 | 0) == 0) return i4 | 0;
michael@0 50796 HEAP8[i1] = HEAP8[i2] | 0;
michael@0 50797 i1 = i1 + 1 | 0;
michael@0 50798 i2 = i2 + 1 | 0;
michael@0 50799 i3 = i3 - 1 | 0;
michael@0 50800 }
michael@0 50801 while ((i3 | 0) >= 4) {
michael@0 50802 HEAP32[i1 >> 2] = HEAP32[i2 >> 2];
michael@0 50803 i1 = i1 + 4 | 0;
michael@0 50804 i2 = i2 + 4 | 0;
michael@0 50805 i3 = i3 - 4 | 0;
michael@0 50806 }
michael@0 50807 }
michael@0 50808 while ((i3 | 0) > 0) {
michael@0 50809 HEAP8[i1] = HEAP8[i2] | 0;
michael@0 50810 i1 = i1 + 1 | 0;
michael@0 50811 i2 = i2 + 1 | 0;
michael@0 50812 i3 = i3 - 1 | 0;
michael@0 50813 }
michael@0 50814 return i4 | 0;
michael@0 50815 }
michael@0 50816 function __ZNK10btBoxShape37localGetSupportingVertexWithoutMarginERK9btVector3(i1, i2, i3) {
michael@0 50817 i1 = i1 | 0;
michael@0 50818 i2 = i2 | 0;
michael@0 50819 i3 = i3 | 0;
michael@0 50820 var d4 = 0.0, d5 = 0.0, d6 = 0.0, d7 = 0.0;
michael@0 50821 d4 = +HEAPF32[i2 + 28 >> 2];
michael@0 50822 d5 = +HEAPF32[i2 + 32 >> 2];
michael@0 50823 d6 = +HEAPF32[i3 + 4 >> 2] >= 0.0 ? d5 : -0.0 - d5;
michael@0 50824 d5 = +HEAPF32[i2 + 36 >> 2];
michael@0 50825 d7 = +HEAPF32[i3 + 8 >> 2] >= 0.0 ? d5 : -0.0 - d5;
michael@0 50826 HEAPF32[i1 >> 2] = +HEAPF32[i3 >> 2] >= 0.0 ? d4 : -0.0 - d4;
michael@0 50827 HEAPF32[i1 + 4 >> 2] = d6;
michael@0 50828 HEAPF32[i1 + 8 >> 2] = d7;
michael@0 50829 HEAPF32[i1 + 12 >> 2] = 0.0;
michael@0 50830 return;
michael@0 50831 }
michael@0 50832 function __ZNK11btRigidBody21serializeSingleObjectEP12btSerializer(i1, i2) {
michael@0 50833 i1 = i1 | 0;
michael@0 50834 i2 = i2 | 0;
michael@0 50835 var i3 = 0, i4 = 0, i5 = 0;
michael@0 50836 i3 = HEAP32[(HEAP32[i2 >> 2] | 0) + 16 >> 2] | 0;
michael@0 50837 i4 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 50838 i5 = FUNCTION_TABLE_iiii[i3 & 31](i2, i4, 1) | 0;
michael@0 50839 i4 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 20 >> 2] & 31](i1, HEAP32[i5 + 8 >> 2] | 0, i2) | 0;
michael@0 50840 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 20 >> 2] & 63](i2, i5, i4, 1497645650, i1);
michael@0 50841 return;
michael@0 50842 }
michael@0 50843 function __ZN16btEmptyAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 50844 i1 = i1 | 0;
michael@0 50845 i2 = i2 | 0;
michael@0 50846 i3 = i3 | 0;
michael@0 50847 i4 = i4 | 0;
michael@0 50848 var i5 = 0, i6 = 0;
michael@0 50849 i4 = HEAP32[i2 >> 2] | 0;
michael@0 50850 i3 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 56 >> 2] & 63](i4, 8) | 0;
michael@0 50851 if ((i3 | 0) == 0) {
michael@0 50852 i5 = 0;
michael@0 50853 i6 = i5 | 0;
michael@0 50854 return i6 | 0;
michael@0 50855 }
michael@0 50856 i4 = i3;
michael@0 50857 __ZN16btEmptyAlgorithmC2ERK36btCollisionAlgorithmConstructionInfo(i4, i2);
michael@0 50858 i5 = i4;
michael@0 50859 i6 = i5 | 0;
michael@0 50860 return i6 | 0;
michael@0 50861 }
michael@0 50862 function __ZZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcherEN17CleanPairCallback14processOverlapER16btBroadphasePair(i1, i2) {
michael@0 50863 i1 = i1 | 0;
michael@0 50864 i2 = i2 | 0;
michael@0 50865 var i3 = 0;
michael@0 50866 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 50867 do {
michael@0 50868 if ((HEAP32[i2 >> 2] | 0) != (i3 | 0)) {
michael@0 50869 if ((HEAP32[i2 + 4 >> 2] | 0) == (i3 | 0)) {
michael@0 50870 break;
michael@0 50871 }
michael@0 50872 return 0;
michael@0 50873 }
michael@0 50874 } while (0);
michael@0 50875 i3 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 50876 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i3 >> 2] | 0) + 32 >> 2] & 127](i3, i2, HEAP32[i1 + 12 >> 2] | 0);
michael@0 50877 return 0;
michael@0 50878 }
michael@0 50879 function __ZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_(i1, i2, i3, i4) {
michael@0 50880 i1 = i1 | 0;
michael@0 50881 i2 = i2 | 0;
michael@0 50882 i3 = i3 | 0;
michael@0 50883 i4 = i4 | 0;
michael@0 50884 var i5 = 0, i6 = 0, i7 = 0;
michael@0 50885 i5 = STACKTOP;
michael@0 50886 STACKTOP = STACKTOP + 16 | 0;
michael@0 50887 i6 = i5 | 0;
michael@0 50888 i7 = HEAP32[i1 + 48 >> 2] | 0;
michael@0 50889 HEAP32[i6 >> 2] = 1624;
michael@0 50890 HEAP32[i6 + 4 >> 2] = i7;
michael@0 50891 HEAP32[i6 + 8 >> 2] = i2;
michael@0 50892 __ZNK14btQuantizedBvh25reportRayOverlappingNodexEP21btNodeOverlapCallbackRK9btVector3S4_(HEAP32[i1 + 52 >> 2] | 0, i6 | 0, i3, i4);
michael@0 50893 STACKTOP = i5;
michael@0 50894 return;
michael@0 50895 }
michael@0 50896 function __ZNK17btCollisionObject21serializeSingleObjectEP12btSerializer(i1, i2) {
michael@0 50897 i1 = i1 | 0;
michael@0 50898 i2 = i2 | 0;
michael@0 50899 var i3 = 0, i4 = 0;
michael@0 50900 i3 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 16 >> 2] & 127](i1) | 0;
michael@0 50901 i4 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 16 >> 2] & 31](i2, i3, 1) | 0;
michael@0 50902 i3 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 20 >> 2] & 31](i1, HEAP32[i4 + 8 >> 2] | 0, i2) | 0;
michael@0 50903 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 20 >> 2] & 63](i2, i4, i3, 1245859651, i1);
michael@0 50904 return;
michael@0 50905 }
michael@0 50906 function __ZN11btRigidBody12applyGravityEv(i1) {
michael@0 50907 i1 = i1 | 0;
michael@0 50908 var d2 = 0.0, d3 = 0.0, i4 = 0;
michael@0 50909 if ((HEAP32[i1 + 204 >> 2] & 3 | 0) != 0) {
michael@0 50910 return;
michael@0 50911 }
michael@0 50912 d2 = +HEAPF32[i1 + 360 >> 2] * +HEAPF32[i1 + 344 >> 2];
michael@0 50913 d3 = +HEAPF32[i1 + 364 >> 2] * +HEAPF32[i1 + 348 >> 2];
michael@0 50914 i4 = i1 + 404 | 0;
michael@0 50915 HEAPF32[i4 >> 2] = +HEAPF32[i1 + 356 >> 2] * +HEAPF32[i1 + 340 >> 2] + +HEAPF32[i4 >> 2];
michael@0 50916 i4 = i1 + 408 | 0;
michael@0 50917 HEAPF32[i4 >> 2] = d2 + +HEAPF32[i4 >> 2];
michael@0 50918 i4 = i1 + 412 | 0;
michael@0 50919 HEAPF32[i4 >> 2] = d3 + +HEAPF32[i4 >> 2];
michael@0 50920 return;
michael@0 50921 }
michael@0 50922 function __ZNK16btCollisionShape20serializeSingleShapeEP12btSerializer(i1, i2) {
michael@0 50923 i1 = i1 | 0;
michael@0 50924 i2 = i2 | 0;
michael@0 50925 var i3 = 0, i4 = 0;
michael@0 50926 i3 = FUNCTION_TABLE_ii[HEAP32[(HEAP32[i1 >> 2] | 0) + 48 >> 2] & 127](i1) | 0;
michael@0 50927 i4 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 16 >> 2] & 31](i2, i3, 1) | 0;
michael@0 50928 i3 = FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 52 >> 2] & 31](i1, HEAP32[i4 + 8 >> 2] | 0, i2) | 0;
michael@0 50929 FUNCTION_TABLE_viiiii[HEAP32[(HEAP32[i2 >> 2] | 0) + 20 >> 2] & 63](i2, i4, i3, 1346455635, i1);
michael@0 50930 return;
michael@0 50931 }
michael@0 50932 function _memset(i1, i2, i3) {
michael@0 50933 i1 = i1 | 0;
michael@0 50934 i2 = i2 | 0;
michael@0 50935 i3 = i3 | 0;
michael@0 50936 var i4 = 0, i5 = 0, i6 = 0;
michael@0 50937 i4 = i1 + i3 | 0;
michael@0 50938 if ((i3 | 0) >= 20) {
michael@0 50939 i2 = i2 & 255;
michael@0 50940 i3 = i1 & 3;
michael@0 50941 i5 = i2 | i2 << 8 | i2 << 16 | i2 << 24;
michael@0 50942 i6 = i4 & ~3;
michael@0 50943 if (i3) {
michael@0 50944 i3 = i1 + 4 - i3 | 0;
michael@0 50945 while ((i1 | 0) < (i3 | 0)) {
michael@0 50946 HEAP8[i1] = i2;
michael@0 50947 i1 = i1 + 1 | 0;
michael@0 50948 }
michael@0 50949 }
michael@0 50950 while ((i1 | 0) < (i6 | 0)) {
michael@0 50951 HEAP32[i1 >> 2] = i5;
michael@0 50952 i1 = i1 + 4 | 0;
michael@0 50953 }
michael@0 50954 }
michael@0 50955 while ((i1 | 0) < (i4 | 0)) {
michael@0 50956 HEAP8[i1] = i2;
michael@0 50957 i1 = i1 + 1 | 0;
michael@0 50958 }
michael@0 50959 }
michael@0 50960 function __ZNK16btCollisionShape9serializeEPvP12btSerializer(i1, i2, i3) {
michael@0 50961 i1 = i1 | 0;
michael@0 50962 i2 = i2 | 0;
michael@0 50963 i3 = i3 | 0;
michael@0 50964 var i4 = 0, i5 = 0, i6 = 0;
michael@0 50965 i4 = i3;
michael@0 50966 i5 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 40 >> 2] & 63](i3, i1) | 0;
michael@0 50967 i6 = FUNCTION_TABLE_iii[HEAP32[(HEAP32[i4 >> 2] | 0) + 28 >> 2] & 63](i3, i5) | 0;
michael@0 50968 HEAP32[i2 >> 2] = i6;
michael@0 50969 if ((i6 | 0) != 0) {
michael@0 50970 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 48 >> 2] & 127](i3, i5);
michael@0 50971 }
michael@0 50972 HEAP32[i2 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 50973 return 1064;
michael@0 50974 }
michael@0 50975 function __ZL17recursedeletenodeP6btDbvtP10btDbvtNode(i1, i2) {
michael@0 50976 i1 = i1 | 0;
michael@0 50977 i2 = i2 | 0;
michael@0 50978 var i3 = 0;
michael@0 50979 i3 = i2 + 40 | 0;
michael@0 50980 if ((HEAP32[i3 >> 2] | 0) != 0) {
michael@0 50981 __ZL17recursedeletenodeP6btDbvtP10btDbvtNode(i1, HEAP32[i2 + 36 >> 2] | 0);
michael@0 50982 __ZL17recursedeletenodeP6btDbvtP10btDbvtNode(i1, HEAP32[i3 >> 2] | 0);
michael@0 50983 }
michael@0 50984 i3 = i1 | 0;
michael@0 50985 if ((HEAP32[i3 >> 2] | 0) == (i2 | 0)) {
michael@0 50986 HEAP32[i3 >> 2] = 0;
michael@0 50987 }
michael@0 50988 i3 = i1 + 4 | 0;
michael@0 50989 __Z21btAlignedFreeInternalPv(HEAP32[i3 >> 2] | 0);
michael@0 50990 HEAP32[i3 >> 2] = i2;
michael@0 50991 return;
michael@0 50992 }
michael@0 50993 function __ZNK16btCollisionShape20getAngularMotionDiscEv(i1) {
michael@0 50994 i1 = i1 | 0;
michael@0 50995 var i2 = 0, i3 = 0, i4 = 0, d5 = 0.0, d6 = 0.0, d7 = 0.0, d8 = 0.0;
michael@0 50996 i2 = STACKTOP;
michael@0 50997 STACKTOP = STACKTOP + 24 | 0;
michael@0 50998 i3 = i2 | 0;
michael@0 50999 i4 = i2 + 16 | 0;
michael@0 51000 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 12 >> 2] & 127](i1, i3, i4);
michael@0 51001 d5 = +HEAPF32[i3 >> 2];
michael@0 51002 d6 = +HEAPF32[i3 + 4 >> 2];
michael@0 51003 d7 = +HEAPF32[i3 + 8 >> 2];
michael@0 51004 d8 = +Math_sqrt(+(d5 * d5 + d6 * d6 + d7 * d7));
michael@0 51005 STACKTOP = i2;
michael@0 51006 return +(d8 + +HEAPF32[i4 >> 2]);
michael@0 51007 }
michael@0 51008 function __ZN11btRigidBodyD0Ev(i1) {
michael@0 51009 i1 = i1 | 0;
michael@0 51010 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 51011 HEAP32[i1 >> 2] = 4936;
michael@0 51012 i2 = i1 + 480 | 0;
michael@0 51013 i3 = i1 + 488 | 0;
michael@0 51014 i4 = HEAP32[i3 >> 2] | 0;
michael@0 51015 i5 = i1 + 492 | 0;
michael@0 51016 if ((i4 | 0) != 0) {
michael@0 51017 if ((HEAP8[i5] | 0) != 0) {
michael@0 51018 __Z21btAlignedFreeInternalPv(i4);
michael@0 51019 }
michael@0 51020 HEAP32[i3 >> 2] = 0;
michael@0 51021 }
michael@0 51022 HEAP8[i5] = 1;
michael@0 51023 HEAP32[i3 >> 2] = 0;
michael@0 51024 HEAP32[i2 >> 2] = 0;
michael@0 51025 HEAP32[i1 + 484 >> 2] = 0;
michael@0 51026 __ZN17btCollisionObjectD2Ev(i1 | 0);
michael@0 51027 __Z21btAlignedFreeInternalPv(i1);
michael@0 51028 return;
michael@0 51029 }
michael@0 51030 function __Znwj(i1) {
michael@0 51031 i1 = i1 | 0;
michael@0 51032 var i2 = 0, i3 = 0, i4 = 0;
michael@0 51033 i2 = (i1 | 0) == 0 ? 1 : i1;
michael@0 51034 while (1) {
michael@0 51035 i3 = _malloc(i2) | 0;
michael@0 51036 if ((i3 | 0) != 0) {
michael@0 51037 i4 = 566;
michael@0 51038 break;
michael@0 51039 }
michael@0 51040 i1 = (tempValue = HEAP32[3580] | 0, HEAP32[3580] = tempValue + 0, tempValue);
michael@0 51041 if ((i1 | 0) == 0) {
michael@0 51042 break;
michael@0 51043 }
michael@0 51044 FUNCTION_TABLE_v[i1 & 3]();
michael@0 51045 }
michael@0 51046 if ((i4 | 0) == 566) {
michael@0 51047 return i3 | 0;
michael@0 51048 }
michael@0 51049 i3 = ___cxa_allocate_exception(4) | 0;
michael@0 51050 HEAP32[i3 >> 2] = 1896;
michael@0 51051 ___cxa_throw(i3 | 0, 10592, 32);
michael@0 51052 return 0;
michael@0 51053 }
michael@0 51054 function __ZN21btCollisionDispatcher25dispatchAllCollisionPairsEP22btOverlappingPairCacheRK16btDispatcherInfoP12btDispatcher(i1, i2, i3, i4) {
michael@0 51055 i1 = i1 | 0;
michael@0 51056 i2 = i2 | 0;
michael@0 51057 i3 = i3 | 0;
michael@0 51058 i4 = i4 | 0;
michael@0 51059 var i5 = 0, i6 = 0;
michael@0 51060 i5 = STACKTOP;
michael@0 51061 STACKTOP = STACKTOP + 16 | 0;
michael@0 51062 i6 = i5 | 0;
michael@0 51063 HEAP32[i6 >> 2] = 3504;
michael@0 51064 HEAP32[i6 + 4 >> 2] = i3;
michael@0 51065 HEAP32[i6 + 8 >> 2] = i1;
michael@0 51066 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i2 >> 2] | 0) + 48 >> 2] & 127](i2, i6 | 0, i4);
michael@0 51067 STACKTOP = i5;
michael@0 51068 return;
michael@0 51069 }
michael@0 51070 function __ZN21btCollisionDispatcherD0Ev(i1) {
michael@0 51071 i1 = i1 | 0;
michael@0 51072 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 51073 HEAP32[i1 >> 2] = 3784;
michael@0 51074 i2 = i1 + 12 | 0;
michael@0 51075 i3 = i1 + 20 | 0;
michael@0 51076 i4 = HEAP32[i3 >> 2] | 0;
michael@0 51077 i5 = i1 + 24 | 0;
michael@0 51078 if ((i4 | 0) != 0) {
michael@0 51079 if ((HEAP8[i5] | 0) != 0) {
michael@0 51080 __Z21btAlignedFreeInternalPv(i4);
michael@0 51081 }
michael@0 51082 HEAP32[i3 >> 2] = 0;
michael@0 51083 }
michael@0 51084 HEAP8[i5] = 1;
michael@0 51085 HEAP32[i3 >> 2] = 0;
michael@0 51086 HEAP32[i2 >> 2] = 0;
michael@0 51087 HEAP32[i1 + 16 >> 2] = 0;
michael@0 51088 __ZN12btDispatcherD2Ev(i1 | 0);
michael@0 51089 __ZdlPv(i1);
michael@0 51090 return;
michael@0 51091 }
michael@0 51092 function __ZN21btCollisionDispatcher26allocateCollisionAlgorithmEi(i1, i2) {
michael@0 51093 i1 = i1 | 0;
michael@0 51094 i2 = i2 | 0;
michael@0 51095 var i3 = 0, i4 = 0, i5 = 0;
michael@0 51096 i3 = HEAP32[i1 + 192 >> 2] | 0;
michael@0 51097 i1 = i3 + 8 | 0;
michael@0 51098 i4 = HEAP32[i1 >> 2] | 0;
michael@0 51099 if ((i4 | 0) == 0) {
michael@0 51100 i5 = __Z22btAlignedAllocInternalji(i2, 16) | 0;
michael@0 51101 return i5 | 0;
michael@0 51102 } else {
michael@0 51103 i2 = i3 + 12 | 0;
michael@0 51104 i3 = HEAP32[i2 >> 2] | 0;
michael@0 51105 HEAP32[i2 >> 2] = HEAP32[i3 >> 2];
michael@0 51106 HEAP32[i1 >> 2] = i4 - 1;
michael@0 51107 i5 = i3;
michael@0 51108 return i5 | 0;
michael@0 51109 }
michael@0 51110 return 0;
michael@0 51111 }
michael@0 51112 function __ZN18btDbvtTreeCollider7ProcessEPK10btDbvtNodeS2_(i1, i2, i3) {
michael@0 51113 i1 = i1 | 0;
michael@0 51114 i2 = i2 | 0;
michael@0 51115 i3 = i3 | 0;
michael@0 51116 var i4 = 0;
michael@0 51117 if ((i2 | 0) == (i3 | 0)) {
michael@0 51118 return;
michael@0 51119 }
michael@0 51120 i4 = i1 + 4 | 0;
michael@0 51121 i1 = HEAP32[(HEAP32[i4 >> 2] | 0) + 96 >> 2] | 0;
michael@0 51122 FUNCTION_TABLE_iiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 31](i1 | 0, HEAP32[i2 + 36 >> 2] | 0, HEAP32[i3 + 36 >> 2] | 0) | 0;
michael@0 51123 i3 = (HEAP32[i4 >> 2] | 0) + 120 | 0;
michael@0 51124 HEAP32[i3 >> 2] = (HEAP32[i3 >> 2] | 0) + 1;
michael@0 51125 return;
michael@0 51126 }
michael@0 51127 function __ZN12CProfileNodeD2Ev(i1) {
michael@0 51128 i1 = i1 | 0;
michael@0 51129 var i2 = 0;
michael@0 51130 i2 = HEAP32[i1 + 24 >> 2] | 0;
michael@0 51131 if ((i2 | 0) != 0) {
michael@0 51132 __ZN12CProfileNodeD2Ev(i2);
michael@0 51133 __ZdlPv(i2);
michael@0 51134 }
michael@0 51135 i2 = HEAP32[i1 + 28 >> 2] | 0;
michael@0 51136 if ((i2 | 0) == 0) {
michael@0 51137 return;
michael@0 51138 }
michael@0 51139 i1 = HEAP32[i2 + 24 >> 2] | 0;
michael@0 51140 if ((i1 | 0) != 0) {
michael@0 51141 __ZN12CProfileNodeD2Ev(i1);
michael@0 51142 __ZdlPv(i1);
michael@0 51143 }
michael@0 51144 i1 = HEAP32[i2 + 28 >> 2] | 0;
michael@0 51145 if ((i1 | 0) != 0) {
michael@0 51146 __ZN12CProfileNodeD2Ev(i1);
michael@0 51147 __ZdlPv(i1);
michael@0 51148 }
michael@0 51149 __ZdlPv(i2);
michael@0 51150 return;
michael@0 51151 }
michael@0 51152 function __ZN24btConvexTriangleCallbackD0Ev(i1) {
michael@0 51153 i1 = i1 | 0;
michael@0 51154 var i2 = 0, i3 = 0, i4 = 0;
michael@0 51155 HEAP32[i1 >> 2] = 3104;
michael@0 51156 i2 = i1 + 48 | 0;
michael@0 51157 i3 = HEAP32[i2 >> 2] | 0;
michael@0 51158 i4 = i1 + 64 | 0;
michael@0 51159 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 20 >> 2] & 127](i3, HEAP32[i4 >> 2] | 0);
michael@0 51160 i3 = HEAP32[i2 >> 2] | 0;
michael@0 51161 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, HEAP32[i4 >> 2] | 0);
michael@0 51162 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 51163 __ZdlPv(i1);
michael@0 51164 return;
michael@0 51165 }
michael@0 51166 function __ZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcher(i1, i2, i3) {
michael@0 51167 i1 = i1 | 0;
michael@0 51168 i2 = i2 | 0;
michael@0 51169 i3 = i3 | 0;
michael@0 51170 var i4 = 0, i5 = 0;
michael@0 51171 i4 = STACKTOP;
michael@0 51172 STACKTOP = STACKTOP + 16 | 0;
michael@0 51173 i5 = i4 | 0;
michael@0 51174 HEAP32[i5 >> 2] = 1488;
michael@0 51175 HEAP32[i5 + 4 >> 2] = i2;
michael@0 51176 HEAP32[i5 + 8 >> 2] = i1;
michael@0 51177 HEAP32[i5 + 12 >> 2] = i3;
michael@0 51178 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 48 >> 2] & 127](i1, i5 | 0, i3);
michael@0 51179 STACKTOP = i4;
michael@0 51180 return;
michael@0 51181 }
michael@0 51182 function __ZN21btCollisionDispatcherD2Ev(i1) {
michael@0 51183 i1 = i1 | 0;
michael@0 51184 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 51185 HEAP32[i1 >> 2] = 3784;
michael@0 51186 i2 = i1 + 12 | 0;
michael@0 51187 i3 = i1 + 20 | 0;
michael@0 51188 i4 = HEAP32[i3 >> 2] | 0;
michael@0 51189 i5 = i1 + 24 | 0;
michael@0 51190 if ((i4 | 0) != 0) {
michael@0 51191 if ((HEAP8[i5] | 0) != 0) {
michael@0 51192 __Z21btAlignedFreeInternalPv(i4);
michael@0 51193 }
michael@0 51194 HEAP32[i3 >> 2] = 0;
michael@0 51195 }
michael@0 51196 HEAP8[i5] = 1;
michael@0 51197 HEAP32[i3 >> 2] = 0;
michael@0 51198 HEAP32[i2 >> 2] = 0;
michael@0 51199 HEAP32[i1 + 16 >> 2] = 0;
michael@0 51200 __ZN12btDispatcherD2Ev(i1 | 0);
michael@0 51201 return;
michael@0 51202 }
michael@0 51203 function __ZN11btRigidBodyD1Ev(i1) {
michael@0 51204 i1 = i1 | 0;
michael@0 51205 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 51206 HEAP32[i1 >> 2] = 4936;
michael@0 51207 i2 = i1 + 480 | 0;
michael@0 51208 i3 = i1 + 488 | 0;
michael@0 51209 i4 = HEAP32[i3 >> 2] | 0;
michael@0 51210 i5 = i1 + 492 | 0;
michael@0 51211 if ((i4 | 0) != 0) {
michael@0 51212 if ((HEAP8[i5] | 0) != 0) {
michael@0 51213 __Z21btAlignedFreeInternalPv(i4);
michael@0 51214 }
michael@0 51215 HEAP32[i3 >> 2] = 0;
michael@0 51216 }
michael@0 51217 HEAP8[i5] = 1;
michael@0 51218 HEAP32[i3 >> 2] = 0;
michael@0 51219 HEAP32[i2 >> 2] = 0;
michael@0 51220 HEAP32[i1 + 484 >> 2] = 0;
michael@0 51221 __ZN17btCollisionObjectD2Ev(i1 | 0);
michael@0 51222 return;
michael@0 51223 }
michael@0 51224 function __ZNK13btSphereShape21calculateLocalInertiaEfR9btVector3(i1, d2, i3) {
michael@0 51225 i1 = i1 | 0;
michael@0 51226 d2 = +d2;
michael@0 51227 i3 = i3 | 0;
michael@0 51228 var i4 = 0, d5 = 0.0;
michael@0 51229 i4 = i1;
michael@0 51230 d5 = d2 * .4000000059604645 * +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 51231 d2 = d5 * +FUNCTION_TABLE_fi[HEAP32[(HEAP32[i4 >> 2] | 0) + 44 >> 2] & 7](i1);
michael@0 51232 HEAPF32[i3 >> 2] = d2;
michael@0 51233 HEAPF32[i3 + 4 >> 2] = d2;
michael@0 51234 HEAPF32[i3 + 8 >> 2] = d2;
michael@0 51235 HEAPF32[i3 + 12 >> 2] = 0.0;
michael@0 51236 return;
michael@0 51237 }
michael@0 51238 function __ZN24btConvexTriangleCallbackD2Ev(i1) {
michael@0 51239 i1 = i1 | 0;
michael@0 51240 var i2 = 0, i3 = 0, i4 = 0;
michael@0 51241 HEAP32[i1 >> 2] = 3104;
michael@0 51242 i2 = i1 + 48 | 0;
michael@0 51243 i3 = HEAP32[i2 >> 2] | 0;
michael@0 51244 i4 = i1 + 64 | 0;
michael@0 51245 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 20 >> 2] & 127](i3, HEAP32[i4 >> 2] | 0);
michael@0 51246 i3 = HEAP32[i2 >> 2] | 0;
michael@0 51247 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, HEAP32[i4 >> 2] | 0);
michael@0 51248 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 51249 return;
michael@0 51250 }
michael@0 51251 function __ZN34btSphereTriangleCollisionAlgorithmD0Ev(i1) {
michael@0 51252 i1 = i1 | 0;
michael@0 51253 var i2 = 0, i3 = 0;
michael@0 51254 HEAP32[i1 >> 2] = 2424;
michael@0 51255 do {
michael@0 51256 if ((HEAP8[i1 + 8 | 0] | 0) != 0) {
michael@0 51257 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51258 if ((i2 | 0) == 0) {
michael@0 51259 break;
michael@0 51260 }
michael@0 51261 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51262 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51263 }
michael@0 51264 } while (0);
michael@0 51265 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51266 __ZdlPv(i1);
michael@0 51267 return;
michael@0 51268 }
michael@0 51269 function __ZN21btCollisionDispatcher13needsResponseEP17btCollisionObjectS1_(i1, i2, i3) {
michael@0 51270 i1 = i1 | 0;
michael@0 51271 i2 = i2 | 0;
michael@0 51272 i3 = i3 | 0;
michael@0 51273 var i4 = 0;
michael@0 51274 i1 = HEAP32[i2 + 204 >> 2] | 0;
michael@0 51275 do {
michael@0 51276 if ((i1 & 4 | 0) == 0) {
michael@0 51277 i2 = HEAP32[i3 + 204 >> 2] | 0;
michael@0 51278 if ((i2 & 4 | 0) != 0) {
michael@0 51279 i4 = 0;
michael@0 51280 break;
michael@0 51281 }
michael@0 51282 if ((i1 & 3 | 0) == 0) {
michael@0 51283 i4 = 1;
michael@0 51284 break;
michael@0 51285 }
michael@0 51286 i4 = (i2 & 3 | 0) == 0;
michael@0 51287 } else {
michael@0 51288 i4 = 0;
michael@0 51289 }
michael@0 51290 } while (0);
michael@0 51291 return i4 | 0;
michael@0 51292 }
michael@0 51293 function __ZN32btSphereSphereCollisionAlgorithmD0Ev(i1) {
michael@0 51294 i1 = i1 | 0;
michael@0 51295 var i2 = 0, i3 = 0;
michael@0 51296 HEAP32[i1 >> 2] = 2568;
michael@0 51297 do {
michael@0 51298 if ((HEAP8[i1 + 8 | 0] | 0) != 0) {
michael@0 51299 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51300 if ((i2 | 0) == 0) {
michael@0 51301 break;
michael@0 51302 }
michael@0 51303 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51304 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51305 }
michael@0 51306 } while (0);
michael@0 51307 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51308 __ZdlPv(i1);
michael@0 51309 return;
michael@0 51310 }
michael@0 51311 function __ZN21btCollisionDispatcher13clearManifoldEP20btPersistentManifold(i1, i2) {
michael@0 51312 i1 = i1 | 0;
michael@0 51313 i2 = i2 | 0;
michael@0 51314 var i3 = 0;
michael@0 51315 i1 = i2 + 1116 | 0;
michael@0 51316 if ((HEAP32[i1 >> 2] | 0) > 0) {
michael@0 51317 i3 = 0;
michael@0 51318 } else {
michael@0 51319 HEAP32[i1 >> 2] = 0;
michael@0 51320 return;
michael@0 51321 }
michael@0 51322 do {
michael@0 51323 __ZN20btPersistentManifold14clearUserCacheER15btManifoldPoint(i2, i2 + 4 + (i3 * 276 | 0) | 0);
michael@0 51324 i3 = i3 + 1 | 0;
michael@0 51325 } while ((i3 | 0) < (HEAP32[i1 >> 2] | 0));
michael@0 51326 HEAP32[i1 >> 2] = 0;
michael@0 51327 return;
michael@0 51328 }
michael@0 51329 function copyTempDouble(i1) {
michael@0 51330 i1 = i1 | 0;
michael@0 51331 HEAP8[tempDoublePtr] = HEAP8[i1];
michael@0 51332 HEAP8[tempDoublePtr + 1 | 0] = HEAP8[i1 + 1 | 0];
michael@0 51333 HEAP8[tempDoublePtr + 2 | 0] = HEAP8[i1 + 2 | 0];
michael@0 51334 HEAP8[tempDoublePtr + 3 | 0] = HEAP8[i1 + 3 | 0];
michael@0 51335 HEAP8[tempDoublePtr + 4 | 0] = HEAP8[i1 + 4 | 0];
michael@0 51336 HEAP8[tempDoublePtr + 5 | 0] = HEAP8[i1 + 5 | 0];
michael@0 51337 HEAP8[tempDoublePtr + 6 | 0] = HEAP8[i1 + 6 | 0];
michael@0 51338 HEAP8[tempDoublePtr + 7 | 0] = HEAP8[i1 + 7 | 0];
michael@0 51339 }
michael@0 51340 function __ZN23btDiscreteDynamicsWorld9serializeEP12btSerializer(i1, i2) {
michael@0 51341 i1 = i1 | 0;
michael@0 51342 i2 = i2 | 0;
michael@0 51343 var i3 = 0;
michael@0 51344 i3 = i2;
michael@0 51345 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i3 >> 2] | 0) + 32 >> 2] & 511](i2);
michael@0 51346 __ZN23btDiscreteDynamicsWorld20serializeRigidBodiesEP12btSerializer(i1, i2);
michael@0 51347 __ZN16btCollisionWorld25serializeCollisionObjectsEP12btSerializer(i1 | 0, i2);
michael@0 51348 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i3 >> 2] | 0) + 36 >> 2] & 511](i2);
michael@0 51349 return;
michael@0 51350 }
michael@0 51351 function __ZN31btConvexPlaneCollisionAlgorithmD0Ev(i1) {
michael@0 51352 i1 = i1 | 0;
michael@0 51353 var i2 = 0, i3 = 0, i4 = 0;
michael@0 51354 HEAP32[i1 >> 2] = 2656;
michael@0 51355 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 51356 i2 = i1;
michael@0 51357 __ZdlPv(i2);
michael@0 51358 return;
michael@0 51359 }
michael@0 51360 i3 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51361 if ((i3 | 0) == 0) {
michael@0 51362 i2 = i1;
michael@0 51363 __ZdlPv(i2);
michael@0 51364 return;
michael@0 51365 }
michael@0 51366 i4 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51367 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i4 >> 2] | 0) + 16 >> 2] & 127](i4, i3);
michael@0 51368 i2 = i1;
michael@0 51369 __ZdlPv(i2);
michael@0 51370 return;
michael@0 51371 }
michael@0 51372 function __ZN26btBoxBoxCollisionAlgorithmD0Ev(i1) {
michael@0 51373 i1 = i1 | 0;
michael@0 51374 var i2 = 0, i3 = 0;
michael@0 51375 HEAP32[i1 >> 2] = 2960;
michael@0 51376 do {
michael@0 51377 if ((HEAP8[i1 + 8 | 0] | 0) != 0) {
michael@0 51378 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51379 if ((i2 | 0) == 0) {
michael@0 51380 break;
michael@0 51381 }
michael@0 51382 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51383 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51384 }
michael@0 51385 } while (0);
michael@0 51386 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51387 __ZdlPv(i1);
michael@0 51388 return;
michael@0 51389 }
michael@0 51390 function __ZN23btConvexConvexAlgorithmD0Ev(i1) {
michael@0 51391 i1 = i1 | 0;
michael@0 51392 var i2 = 0, i3 = 0;
michael@0 51393 HEAP32[i1 >> 2] = 3464;
michael@0 51394 do {
michael@0 51395 if ((HEAP8[i1 + 16 | 0] | 0) != 0) {
michael@0 51396 i2 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 51397 if ((i2 | 0) == 0) {
michael@0 51398 break;
michael@0 51399 }
michael@0 51400 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51401 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51402 }
michael@0 51403 } while (0);
michael@0 51404 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51405 __ZdlPv(i1);
michael@0 51406 return;
michael@0 51407 }
michael@0 51408 function __ZN22btVoronoiSimplexSolver5resetEv(i1) {
michael@0 51409 i1 = i1 | 0;
michael@0 51410 var i2 = 0;
michael@0 51411 HEAP8[i1 + 312 | 0] = 0;
michael@0 51412 HEAP32[i1 >> 2] = 0;
michael@0 51413 HEAP8[i1 + 356 | 0] = 1;
michael@0 51414 HEAPF32[i1 + 292 >> 2] = 999999984306749400.0;
michael@0 51415 HEAPF32[i1 + 296 >> 2] = 999999984306749400.0;
michael@0 51416 HEAPF32[i1 + 300 >> 2] = 999999984306749400.0;
michael@0 51417 HEAPF32[i1 + 304 >> 2] = 0.0;
michael@0 51418 i2 = i1 + 332 | 0;
michael@0 51419 _memset(i1 + 336 | 0, 0, 17);
michael@0 51420 HEAP16[i2 >> 1] = HEAP16[i2 >> 1] & -16;
michael@0 51421 return;
michael@0 51422 }
michael@0 51423 function __ZN34btSphereTriangleCollisionAlgorithmD2Ev(i1) {
michael@0 51424 i1 = i1 | 0;
michael@0 51425 var i2 = 0, i3 = 0;
michael@0 51426 HEAP32[i1 >> 2] = 2424;
michael@0 51427 do {
michael@0 51428 if ((HEAP8[i1 + 8 | 0] | 0) != 0) {
michael@0 51429 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51430 if ((i2 | 0) == 0) {
michael@0 51431 break;
michael@0 51432 }
michael@0 51433 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51434 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51435 }
michael@0 51436 } while (0);
michael@0 51437 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51438 return;
michael@0 51439 }
michael@0 51440 function __ZN32btSphereSphereCollisionAlgorithmD2Ev(i1) {
michael@0 51441 i1 = i1 | 0;
michael@0 51442 var i2 = 0, i3 = 0;
michael@0 51443 HEAP32[i1 >> 2] = 2568;
michael@0 51444 do {
michael@0 51445 if ((HEAP8[i1 + 8 | 0] | 0) != 0) {
michael@0 51446 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51447 if ((i2 | 0) == 0) {
michael@0 51448 break;
michael@0 51449 }
michael@0 51450 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51451 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51452 }
michael@0 51453 } while (0);
michael@0 51454 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51455 return;
michael@0 51456 }
michael@0 51457 function __ZN28btHashedOverlappingPairCache20cleanOverlappingPairER16btBroadphasePairP12btDispatcher(i1, i2, i3) {
michael@0 51458 i1 = i1 | 0;
michael@0 51459 i2 = i2 | 0;
michael@0 51460 i3 = i3 | 0;
michael@0 51461 i1 = i2 + 8 | 0;
michael@0 51462 i2 = HEAP32[i1 >> 2] | 0;
michael@0 51463 if ((i2 | 0) == 0) {
michael@0 51464 return;
michael@0 51465 }
michael@0 51466 FUNCTION_TABLE_vi[HEAP32[HEAP32[i2 >> 2] >> 2] & 511](i2);
michael@0 51467 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 60 >> 2] & 127](i3, HEAP32[i1 >> 2] | 0);
michael@0 51468 HEAP32[i1 >> 2] = 0;
michael@0 51469 return;
michael@0 51470 }
michael@0 51471 function __ZN26btBoxBoxCollisionAlgorithmD2Ev(i1) {
michael@0 51472 i1 = i1 | 0;
michael@0 51473 var i2 = 0, i3 = 0;
michael@0 51474 HEAP32[i1 >> 2] = 2960;
michael@0 51475 do {
michael@0 51476 if ((HEAP8[i1 + 8 | 0] | 0) != 0) {
michael@0 51477 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51478 if ((i2 | 0) == 0) {
michael@0 51479 break;
michael@0 51480 }
michael@0 51481 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51482 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51483 }
michael@0 51484 } while (0);
michael@0 51485 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51486 return;
michael@0 51487 }
michael@0 51488 function __ZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcher(i1, i2, i3) {
michael@0 51489 i1 = i1 | 0;
michael@0 51490 i2 = i2 | 0;
michael@0 51491 i3 = i3 | 0;
michael@0 51492 var i4 = 0, i5 = 0;
michael@0 51493 i4 = STACKTOP;
michael@0 51494 STACKTOP = STACKTOP + 8 | 0;
michael@0 51495 i5 = i4 | 0;
michael@0 51496 HEAP32[i5 >> 2] = 1456;
michael@0 51497 HEAP32[i5 + 4 >> 2] = i2;
michael@0 51498 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 48 >> 2] & 127](i1, i5 | 0, i3);
michael@0 51499 STACKTOP = i4;
michael@0 51500 return;
michael@0 51501 }
michael@0 51502 function __ZN23btConvexConvexAlgorithmD2Ev(i1) {
michael@0 51503 i1 = i1 | 0;
michael@0 51504 var i2 = 0, i3 = 0;
michael@0 51505 HEAP32[i1 >> 2] = 3464;
michael@0 51506 do {
michael@0 51507 if ((HEAP8[i1 + 16 | 0] | 0) != 0) {
michael@0 51508 i2 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 51509 if ((i2 | 0) == 0) {
michael@0 51510 break;
michael@0 51511 }
michael@0 51512 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51513 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51514 }
michael@0 51515 } while (0);
michael@0 51516 __ZN30btActivatingCollisionAlgorithmD2Ev(i1 | 0);
michael@0 51517 return;
michael@0 51518 }
michael@0 51519 function __ZN22btVoronoiSimplexSolver7closestER9btVector3(i1, i2) {
michael@0 51520 i1 = i1 | 0;
michael@0 51521 i2 = i2 | 0;
michael@0 51522 var i3 = 0, i4 = 0;
michael@0 51523 i3 = __ZN22btVoronoiSimplexSolver28updateClosestVectorAndPointsEv(i1) | 0;
michael@0 51524 i4 = i2;
michael@0 51525 i2 = i1 + 276 | 0;
michael@0 51526 HEAP32[i4 >> 2] = HEAP32[i2 >> 2];
michael@0 51527 HEAP32[i4 + 4 >> 2] = HEAP32[i2 + 4 >> 2];
michael@0 51528 HEAP32[i4 + 8 >> 2] = HEAP32[i2 + 8 >> 2];
michael@0 51529 HEAP32[i4 + 12 >> 2] = HEAP32[i2 + 12 >> 2];
michael@0 51530 return i3 | 0;
michael@0 51531 }
michael@0 51532 function __ZN18btConvexPolyhedronC2Ev(i1) {
michael@0 51533 i1 = i1 | 0;
michael@0 51534 HEAP32[i1 >> 2] = 4112;
michael@0 51535 HEAP8[i1 + 20 | 0] = 1;
michael@0 51536 HEAP32[i1 + 16 >> 2] = 0;
michael@0 51537 HEAP32[i1 + 8 >> 2] = 0;
michael@0 51538 HEAP32[i1 + 12 >> 2] = 0;
michael@0 51539 HEAP8[i1 + 40 | 0] = 1;
michael@0 51540 HEAP32[i1 + 36 >> 2] = 0;
michael@0 51541 HEAP32[i1 + 28 >> 2] = 0;
michael@0 51542 HEAP32[i1 + 32 >> 2] = 0;
michael@0 51543 HEAP8[i1 + 60 | 0] = 1;
michael@0 51544 HEAP32[i1 + 56 >> 2] = 0;
michael@0 51545 HEAP32[i1 + 48 >> 2] = 0;
michael@0 51546 HEAP32[i1 + 52 >> 2] = 0;
michael@0 51547 return;
michael@0 51548 }
michael@0 51549 function ___muldsi3(i1, i2) {
michael@0 51550 i1 = i1 | 0;
michael@0 51551 i2 = i2 | 0;
michael@0 51552 var i3 = 0, i4 = 0, i5 = 0, i6 = 0;
michael@0 51553 i3 = i1 & 65535;
michael@0 51554 i4 = i2 & 65535;
michael@0 51555 i5 = Math_imul(i4, i3) | 0;
michael@0 51556 i6 = i1 >>> 16;
michael@0 51557 i1 = (i5 >>> 16) + (Math_imul(i4, i6) | 0) | 0;
michael@0 51558 i4 = i2 >>> 16;
michael@0 51559 i2 = Math_imul(i4, i3) | 0;
michael@0 51560 return (tempRet0 = (i1 >>> 16) + (Math_imul(i4, i6) | 0) + (((i1 & 65535) + i2 | 0) >>> 16) | 0, i1 + i2 << 16 | i5 & 65535 | 0) | 0;
michael@0 51561 }
michael@0 51562 function __ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb(i1, i2, i3, i4, i5) {
michael@0 51563 i1 = i1 | 0;
michael@0 51564 i2 = i2 | 0;
michael@0 51565 i3 = i3 | 0;
michael@0 51566 i4 = i4 | 0;
michael@0 51567 i5 = i5 | 0;
michael@0 51568 __ZN17btGjkPairDetector26getClosestPointsNonVirtualERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDraw(i1, i2, i3, i4);
michael@0 51569 return;
michael@0 51570 }
michael@0 51571 function __ZZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcherEN18RemovePairCallback14processOverlapER16btBroadphasePair(i1, i2) {
michael@0 51572 i1 = i1 | 0;
michael@0 51573 i2 = i2 | 0;
michael@0 51574 var i3 = 0, i4 = 0;
michael@0 51575 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51576 if ((HEAP32[i2 >> 2] | 0) == (i3 | 0)) {
michael@0 51577 i4 = 1;
michael@0 51578 return i4 | 0;
michael@0 51579 }
michael@0 51580 i4 = (HEAP32[i2 + 4 >> 2] | 0) == (i3 | 0);
michael@0 51581 return i4 | 0;
michael@0 51582 }
michael@0 51583 function dynCall_iiiiiiiiiiii(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12) {
michael@0 51584 i1 = i1 | 0;
michael@0 51585 i2 = i2 | 0;
michael@0 51586 i3 = i3 | 0;
michael@0 51587 i4 = i4 | 0;
michael@0 51588 i5 = i5 | 0;
michael@0 51589 i6 = i6 | 0;
michael@0 51590 i7 = i7 | 0;
michael@0 51591 i8 = i8 | 0;
michael@0 51592 i9 = i9 | 0;
michael@0 51593 i10 = i10 | 0;
michael@0 51594 i11 = i11 | 0;
michael@0 51595 i12 = i12 | 0;
michael@0 51596 return FUNCTION_TABLE_iiiiiiiiiiii[i1 & 7](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0, i8 | 0, i9 | 0, i10 | 0, i11 | 0, i12 | 0) | 0;
michael@0 51597 }
michael@0 51598 function dynCall_fiiiiiiiiiii(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12) {
michael@0 51599 i1 = i1 | 0;
michael@0 51600 i2 = i2 | 0;
michael@0 51601 i3 = i3 | 0;
michael@0 51602 i4 = i4 | 0;
michael@0 51603 i5 = i5 | 0;
michael@0 51604 i6 = i6 | 0;
michael@0 51605 i7 = i7 | 0;
michael@0 51606 i8 = i8 | 0;
michael@0 51607 i9 = i9 | 0;
michael@0 51608 i10 = i10 | 0;
michael@0 51609 i11 = i11 | 0;
michael@0 51610 i12 = i12 | 0;
michael@0 51611 return +FUNCTION_TABLE_fiiiiiiiiiii[i1 & 3](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0, i8 | 0, i9 | 0, i10 | 0, i11 | 0, i12 | 0);
michael@0 51612 }
michael@0 51613 function __ZN21btConvexInternalShape15setLocalScalingERK9btVector3(i1, i2) {
michael@0 51614 i1 = i1 | 0;
michael@0 51615 i2 = i2 | 0;
michael@0 51616 var d3 = 0.0, d4 = 0.0, d5 = 0.0;
michael@0 51617 d3 = +Math_abs(+(+HEAPF32[i2 >> 2]));
michael@0 51618 d4 = +Math_abs(+(+HEAPF32[i2 + 4 >> 2]));
michael@0 51619 d5 = +Math_abs(+(+HEAPF32[i2 + 8 >> 2]));
michael@0 51620 HEAPF32[i1 + 12 >> 2] = d3;
michael@0 51621 HEAPF32[i1 + 16 >> 2] = d4;
michael@0 51622 HEAPF32[i1 + 20 >> 2] = d5;
michael@0 51623 HEAPF32[i1 + 24 >> 2] = 0.0;
michael@0 51624 return;
michael@0 51625 }
michael@0 51626 function __ZN16btDbvtBroadphaseD0Ev(i1) {
michael@0 51627 i1 = i1 | 0;
michael@0 51628 var i2 = 0, i3 = 0;
michael@0 51629 HEAP32[i1 >> 2] = 4392;
michael@0 51630 if ((HEAP8[i1 + 152 | 0] | 0) != 0) {
michael@0 51631 i2 = i1 + 96 | 0;
michael@0 51632 i3 = HEAP32[i2 >> 2] | 0;
michael@0 51633 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 51634 __Z21btAlignedFreeInternalPv(HEAP32[i2 >> 2] | 0);
michael@0 51635 }
michael@0 51636 __ZN6btDbvtD2Ev(i1 + 44 | 0);
michael@0 51637 __ZN6btDbvtD2Ev(i1 + 4 | 0);
michael@0 51638 __ZdlPv(i1);
michael@0 51639 return;
michael@0 51640 }
michael@0 51641 function __ZNK13btSphereShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i(i1, i2, i3, i4) {
michael@0 51642 i1 = i1 | 0;
michael@0 51643 i2 = i2 | 0;
michael@0 51644 i3 = i3 | 0;
michael@0 51645 i4 = i4 | 0;
michael@0 51646 var i5 = 0;
michael@0 51647 if ((i4 | 0) > 0) {
michael@0 51648 i5 = 0;
michael@0 51649 } else {
michael@0 51650 return;
michael@0 51651 }
michael@0 51652 while (1) {
michael@0 51653 i2 = i5 + 1 | 0;
michael@0 51654 _memset(i3 + (i5 << 4) | 0, 0, 16);
michael@0 51655 if ((i2 | 0) < (i4 | 0)) {
michael@0 51656 i5 = i2;
michael@0 51657 } else {
michael@0 51658 break;
michael@0 51659 }
michael@0 51660 }
michael@0 51661 return;
michael@0 51662 }
michael@0 51663 function __ZN27btContinuousConvexCollisionC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i1, i2, i3, i4, i5) {
michael@0 51664 i1 = i1 | 0;
michael@0 51665 i2 = i2 | 0;
michael@0 51666 i3 = i3 | 0;
michael@0 51667 i4 = i4 | 0;
michael@0 51668 i5 = i5 | 0;
michael@0 51669 HEAP32[i1 >> 2] = 2928;
michael@0 51670 HEAP32[i1 + 4 >> 2] = i4;
michael@0 51671 HEAP32[i1 + 8 >> 2] = i5;
michael@0 51672 HEAP32[i1 + 12 >> 2] = i2;
michael@0 51673 HEAP32[i1 + 16 >> 2] = i3;
michael@0 51674 HEAP32[i1 + 20 >> 2] = 0;
michael@0 51675 return;
michael@0 51676 }
michael@0 51677 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfENK14LocalInfoAdder14needsCollisionE_1P17btBroadphaseProxy(i1, i2) {
michael@0 51678 i1 = i1 | 0;
michael@0 51679 i2 = i2 | 0;
michael@0 51680 var i3 = 0;
michael@0 51681 i3 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51682 return FUNCTION_TABLE_iii[HEAP32[(HEAP32[i3 >> 2] | 0) + 8 >> 2] & 63](i3, i2) | 0;
michael@0 51683 }
michael@0 51684 function __ZN11btUnionFindD2Ev(i1) {
michael@0 51685 i1 = i1 | 0;
michael@0 51686 var i2 = 0, i3 = 0, i4 = 0, i5 = 0;
michael@0 51687 i2 = i1 + 4 | 0;
michael@0 51688 i3 = i1 + 12 | 0;
michael@0 51689 i4 = HEAP32[i3 >> 2] | 0;
michael@0 51690 i5 = i1 + 16 | 0;
michael@0 51691 if ((i4 | 0) != 0) {
michael@0 51692 if ((HEAP8[i5] | 0) != 0) {
michael@0 51693 __Z21btAlignedFreeInternalPv(i4);
michael@0 51694 }
michael@0 51695 HEAP32[i3 >> 2] = 0;
michael@0 51696 }
michael@0 51697 HEAP8[i5] = 1;
michael@0 51698 HEAP32[i3 >> 2] = 0;
michael@0 51699 HEAP32[i2 >> 2] = 0;
michael@0 51700 HEAP32[i1 + 8 >> 2] = 0;
michael@0 51701 return;
michael@0 51702 }
michael@0 51703 function __ZN16btDbvtBroadphaseD2Ev(i1) {
michael@0 51704 i1 = i1 | 0;
michael@0 51705 var i2 = 0, i3 = 0;
michael@0 51706 HEAP32[i1 >> 2] = 4392;
michael@0 51707 if ((HEAP8[i1 + 152 | 0] | 0) != 0) {
michael@0 51708 i2 = i1 + 96 | 0;
michael@0 51709 i3 = HEAP32[i2 >> 2] | 0;
michael@0 51710 FUNCTION_TABLE_vi[HEAP32[HEAP32[i3 >> 2] >> 2] & 511](i3);
michael@0 51711 __Z21btAlignedFreeInternalPv(HEAP32[i2 >> 2] | 0);
michael@0 51712 }
michael@0 51713 __ZN6btDbvtD2Ev(i1 + 44 | 0);
michael@0 51714 __ZN6btDbvtD2Ev(i1 + 4 | 0);
michael@0 51715 return;
michael@0 51716 }
michael@0 51717 function __ZN23btDiscreteDynamicsWorld21removeCollisionObjectEP17btCollisionObject(i1, i2) {
michael@0 51718 i1 = i1 | 0;
michael@0 51719 i2 = i2 | 0;
michael@0 51720 if ((HEAP32[i2 + 232 >> 2] & 2 | 0) == 0 | (i2 | 0) == 0) {
michael@0 51721 __ZN16btCollisionWorld21removeCollisionObjectEP17btCollisionObject(i1 | 0, i2);
michael@0 51722 return;
michael@0 51723 } else {
michael@0 51724 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 88 >> 2] & 127](i1, i2);
michael@0 51725 return;
michael@0 51726 }
michael@0 51727 }
michael@0 51728 function __ZN25btSimulationIslandManagerC2Ev(i1) {
michael@0 51729 i1 = i1 | 0;
michael@0 51730 HEAP32[i1 >> 2] = 3032;
michael@0 51731 __ZN11btUnionFindC2Ev(i1 + 4 | 0);
michael@0 51732 HEAP8[i1 + 40 | 0] = 1;
michael@0 51733 HEAP32[i1 + 36 >> 2] = 0;
michael@0 51734 HEAP32[i1 + 28 >> 2] = 0;
michael@0 51735 HEAP32[i1 + 32 >> 2] = 0;
michael@0 51736 HEAP8[i1 + 60 | 0] = 1;
michael@0 51737 HEAP32[i1 + 56 >> 2] = 0;
michael@0 51738 HEAP32[i1 + 48 >> 2] = 0;
michael@0 51739 HEAP32[i1 + 52 >> 2] = 0;
michael@0 51740 HEAP8[i1 + 64 | 0] = 1;
michael@0 51741 return;
michael@0 51742 }
michael@0 51743 function _llvm_cttz_i32(i1) {
michael@0 51744 i1 = i1 | 0;
michael@0 51745 var i2 = 0;
michael@0 51746 i2 = HEAP8[cttz_i8 + (i1 & 255) | 0] | 0;
michael@0 51747 if ((i2 | 0) < 8) return i2 | 0;
michael@0 51748 i2 = HEAP8[cttz_i8 + (i1 >> 8 & 255) | 0] | 0;
michael@0 51749 if ((i2 | 0) < 8) return i2 + 8 | 0;
michael@0 51750 i2 = HEAP8[cttz_i8 + (i1 >> 16 & 255) | 0] | 0;
michael@0 51751 if ((i2 | 0) < 8) return i2 + 16 | 0;
michael@0 51752 return (HEAP8[cttz_i8 + (i1 >>> 24) | 0] | 0) + 24 | 0;
michael@0 51753 }
michael@0 51754 function _llvm_ctlz_i32(i1) {
michael@0 51755 i1 = i1 | 0;
michael@0 51756 var i2 = 0;
michael@0 51757 i2 = HEAP8[ctlz_i8 + (i1 >>> 24) | 0] | 0;
michael@0 51758 if ((i2 | 0) < 8) return i2 | 0;
michael@0 51759 i2 = HEAP8[ctlz_i8 + (i1 >> 16 & 255) | 0] | 0;
michael@0 51760 if ((i2 | 0) < 8) return i2 + 8 | 0;
michael@0 51761 i2 = HEAP8[ctlz_i8 + (i1 >> 8 & 255) | 0] | 0;
michael@0 51762 if ((i2 | 0) < 8) return i2 + 16 | 0;
michael@0 51763 return (HEAP8[ctlz_i8 + (i1 & 255) | 0] | 0) + 24 | 0;
michael@0 51764 }
michael@0 51765 function __ZN11btRigidBodyC2ERKNS_27btRigidBodyConstructionInfoE(i1, i2) {
michael@0 51766 i1 = i1 | 0;
michael@0 51767 i2 = i2 | 0;
michael@0 51768 __ZN17btCollisionObjectC2Ev(i1 | 0);
michael@0 51769 HEAP32[i1 >> 2] = 4936;
michael@0 51770 HEAP8[i1 + 492 | 0] = 1;
michael@0 51771 HEAP32[i1 + 488 >> 2] = 0;
michael@0 51772 HEAP32[i1 + 480 >> 2] = 0;
michael@0 51773 HEAP32[i1 + 484 >> 2] = 0;
michael@0 51774 __ZN11btRigidBody14setupRigidBodyERKNS_27btRigidBodyConstructionInfoE(i1, i2);
michael@0 51775 return;
michael@0 51776 }
michael@0 51777 function dynCall_fiiiiiiiiii(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 51778 i1 = i1 | 0;
michael@0 51779 i2 = i2 | 0;
michael@0 51780 i3 = i3 | 0;
michael@0 51781 i4 = i4 | 0;
michael@0 51782 i5 = i5 | 0;
michael@0 51783 i6 = i6 | 0;
michael@0 51784 i7 = i7 | 0;
michael@0 51785 i8 = i8 | 0;
michael@0 51786 i9 = i9 | 0;
michael@0 51787 i10 = i10 | 0;
michael@0 51788 i11 = i11 | 0;
michael@0 51789 return +FUNCTION_TABLE_fiiiiiiiiii[i1 & 7](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0, i8 | 0, i9 | 0, i10 | 0, i11 | 0);
michael@0 51790 }
michael@0 51791 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEENK15LocalInfoAdder214needsCollisionEP17btBroadphaseProxy(i1, i2) {
michael@0 51792 i1 = i1 | 0;
michael@0 51793 i2 = i2 | 0;
michael@0 51794 var i3 = 0;
michael@0 51795 i3 = HEAP32[i1 + 20 >> 2] | 0;
michael@0 51796 return FUNCTION_TABLE_iii[HEAP32[(HEAP32[i3 >> 2] | 0) + 8 >> 2] & 63](i3, i2) | 0;
michael@0 51797 }
michael@0 51798 function dynCall_viiiiffffiif(i1, i2, i3, i4, i5, d6, d7, d8, d9, i10, i11, d12) {
michael@0 51799 i1 = i1 | 0;
michael@0 51800 i2 = i2 | 0;
michael@0 51801 i3 = i3 | 0;
michael@0 51802 i4 = i4 | 0;
michael@0 51803 i5 = i5 | 0;
michael@0 51804 d6 = +d6;
michael@0 51805 d7 = +d7;
michael@0 51806 d8 = +d8;
michael@0 51807 d9 = +d9;
michael@0 51808 i10 = i10 | 0;
michael@0 51809 i11 = i11 | 0;
michael@0 51810 d12 = +d12;
michael@0 51811 FUNCTION_TABLE_viiiiffffiif[i1 & 1](i2 | 0, i3 | 0, i4 | 0, i5 | 0, +d6, +d7, +d8, +d9, i10 | 0, i11 | 0, +d12);
michael@0 51812 }
michael@0 51813 function dynCall_viiiiiiiiii(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 51814 i1 = i1 | 0;
michael@0 51815 i2 = i2 | 0;
michael@0 51816 i3 = i3 | 0;
michael@0 51817 i4 = i4 | 0;
michael@0 51818 i5 = i5 | 0;
michael@0 51819 i6 = i6 | 0;
michael@0 51820 i7 = i7 | 0;
michael@0 51821 i8 = i8 | 0;
michael@0 51822 i9 = i9 | 0;
michael@0 51823 i10 = i10 | 0;
michael@0 51824 i11 = i11 | 0;
michael@0 51825 FUNCTION_TABLE_viiiiiiiiii[i1 & 3](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0, i8 | 0, i9 | 0, i10 | 0, i11 | 0);
michael@0 51826 }
michael@0 51827 function __ZNK14btAngularLimit7getHighEv(i1) {
michael@0 51828 i1 = i1 | 0;
michael@0 51829 var d2 = 0.0, d3 = 0.0;
michael@0 51830 d2 = +_fmod(+(+HEAPF32[i1 >> 2] + +HEAPF32[i1 + 4 >> 2]), 6.2831854820251465);
michael@0 51831 if (d2 < -3.1415927410125732) {
michael@0 51832 d3 = d2 + 6.2831854820251465;
michael@0 51833 return +d3;
michael@0 51834 }
michael@0 51835 if (d2 <= 3.1415927410125732) {
michael@0 51836 d3 = d2;
michael@0 51837 return +d3;
michael@0 51838 }
michael@0 51839 d3 = d2 - 6.2831854820251465;
michael@0 51840 return +d3;
michael@0 51841 }
michael@0 51842 function __ZN23btDiscreteDynamicsWorld11clearForcesEv(i1) {
michael@0 51843 i1 = i1 | 0;
michael@0 51844 var i2 = 0, i3 = 0;
michael@0 51845 i2 = i1 + 204 | 0;
michael@0 51846 if ((HEAP32[i2 >> 2] | 0) <= 0) {
michael@0 51847 return;
michael@0 51848 }
michael@0 51849 i3 = i1 + 212 | 0;
michael@0 51850 i1 = 0;
michael@0 51851 do {
michael@0 51852 _memset((HEAP32[(HEAP32[i3 >> 2] | 0) + (i1 << 2) >> 2] | 0) + 404 | 0, 0, 32);
michael@0 51853 i1 = i1 + 1 | 0;
michael@0 51854 } while ((i1 | 0) < (HEAP32[i2 >> 2] | 0));
michael@0 51855 return;
michael@0 51856 }
michael@0 51857 function __ZNK14btAngularLimit6getLowEv(i1) {
michael@0 51858 i1 = i1 | 0;
michael@0 51859 var d2 = 0.0, d3 = 0.0;
michael@0 51860 d2 = +_fmod(+(+HEAPF32[i1 >> 2] - +HEAPF32[i1 + 4 >> 2]), 6.2831854820251465);
michael@0 51861 if (d2 < -3.1415927410125732) {
michael@0 51862 d3 = d2 + 6.2831854820251465;
michael@0 51863 return +d3;
michael@0 51864 }
michael@0 51865 if (d2 <= 3.1415927410125732) {
michael@0 51866 d3 = d2;
michael@0 51867 return +d3;
michael@0 51868 }
michael@0 51869 d3 = d2 - 6.2831854820251465;
michael@0 51870 return +d3;
michael@0 51871 }
michael@0 51872 function dynCall_viiiifffffif(i1, i2, i3, i4, i5, d6, d7, d8, d9, d10, i11, d12) {
michael@0 51873 i1 = i1 | 0;
michael@0 51874 i2 = i2 | 0;
michael@0 51875 i3 = i3 | 0;
michael@0 51876 i4 = i4 | 0;
michael@0 51877 i5 = i5 | 0;
michael@0 51878 d6 = +d6;
michael@0 51879 d7 = +d7;
michael@0 51880 d8 = +d8;
michael@0 51881 d9 = +d9;
michael@0 51882 d10 = +d10;
michael@0 51883 i11 = i11 | 0;
michael@0 51884 d12 = +d12;
michael@0 51885 FUNCTION_TABLE_viiiifffffif[i1 & 1](i2 | 0, i3 | 0, i4 | 0, i5 | 0, +d6, +d7, +d8, +d9, +d10, i11 | 0, +d12);
michael@0 51886 }
michael@0 51887 function __ZN31btConvexPlaneCollisionAlgorithmD2Ev(i1) {
michael@0 51888 i1 = i1 | 0;
michael@0 51889 var i2 = 0, i3 = 0;
michael@0 51890 HEAP32[i1 >> 2] = 2656;
michael@0 51891 if ((HEAP8[i1 + 8 | 0] | 0) == 0) {
michael@0 51892 return;
michael@0 51893 }
michael@0 51894 i2 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51895 if ((i2 | 0) == 0) {
michael@0 51896 return;
michael@0 51897 }
michael@0 51898 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 51899 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i3 >> 2] | 0) + 16 >> 2] & 127](i3, i2);
michael@0 51900 return;
michael@0 51901 }
michael@0 51902 function __ZN16btCollisionWorld9serializeEP12btSerializer(i1, i2) {
michael@0 51903 i1 = i1 | 0;
michael@0 51904 i2 = i2 | 0;
michael@0 51905 var i3 = 0;
michael@0 51906 i3 = i2;
michael@0 51907 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i3 >> 2] | 0) + 32 >> 2] & 511](i2);
michael@0 51908 __ZN16btCollisionWorld25serializeCollisionObjectsEP12btSerializer(i1, i2);
michael@0 51909 FUNCTION_TABLE_vi[HEAP32[(HEAP32[i3 >> 2] | 0) + 36 >> 2] & 511](i2);
michael@0 51910 return;
michael@0 51911 }
michael@0 51912 function __ZNK15btTriangleShape9getVertexEiR9btVector3(i1, i2, i3) {
michael@0 51913 i1 = i1 | 0;
michael@0 51914 i2 = i2 | 0;
michael@0 51915 i3 = i3 | 0;
michael@0 51916 var i4 = 0;
michael@0 51917 i4 = i3;
michael@0 51918 i3 = i1 + 56 + (i2 << 4) | 0;
michael@0 51919 HEAP32[i4 >> 2] = HEAP32[i3 >> 2];
michael@0 51920 HEAP32[i4 + 4 >> 2] = HEAP32[i3 + 4 >> 2];
michael@0 51921 HEAP32[i4 + 8 >> 2] = HEAP32[i3 + 8 >> 2];
michael@0 51922 HEAP32[i4 + 12 >> 2] = HEAP32[i3 + 12 >> 2];
michael@0 51923 return;
michael@0 51924 }
michael@0 51925 function __ZNK15btTriangleShape7getEdgeEiR9btVector3S1_(i1, i2, i3, i4) {
michael@0 51926 i1 = i1 | 0;
michael@0 51927 i2 = i2 | 0;
michael@0 51928 i3 = i3 | 0;
michael@0 51929 i4 = i4 | 0;
michael@0 51930 var i5 = 0;
michael@0 51931 i5 = i1;
michael@0 51932 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i5 >> 2] | 0) + 100 >> 2] & 127](i1, i2, i3);
michael@0 51933 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i5 >> 2] | 0) + 100 >> 2] & 127](i1, (i2 + 1 | 0) % 3 | 0, i4);
michael@0 51934 return;
michael@0 51935 }
michael@0 51936 function __ZN11btUnionFind5resetEi(i1, i2) {
michael@0 51937 i1 = i1 | 0;
michael@0 51938 i2 = i2 | 0;
michael@0 51939 var i3 = 0;
michael@0 51940 __ZN11btUnionFind8allocateEi(i1, i2);
michael@0 51941 if ((i2 | 0) <= 0) {
michael@0 51942 return;
michael@0 51943 }
michael@0 51944 i3 = HEAP32[i1 + 12 >> 2] | 0;
michael@0 51945 i1 = 0;
michael@0 51946 do {
michael@0 51947 HEAP32[i3 + (i1 << 3) >> 2] = i1;
michael@0 51948 HEAP32[i3 + (i1 << 3) + 4 >> 2] = 1;
michael@0 51949 i1 = i1 + 1 | 0;
michael@0 51950 } while ((i1 | 0) < (i2 | 0));
michael@0 51951 return;
michael@0 51952 }
michael@0 51953 function __ZL21btAlignedAllocDefaultji(i1, i2) {
michael@0 51954 i1 = i1 | 0;
michael@0 51955 i2 = i2 | 0;
michael@0 51956 var i3 = 0, i4 = 0, i5 = 0;
michael@0 51957 i3 = i2 - 1 | 0;
michael@0 51958 i4 = FUNCTION_TABLE_ii[HEAP32[2974] & 127](i1 + 4 + i3 | 0) | 0;
michael@0 51959 if ((i4 | 0) == 0) {
michael@0 51960 i5 = 0;
michael@0 51961 return i5 | 0;
michael@0 51962 }
michael@0 51963 i1 = i2 - (i4 + 4) & i3;
michael@0 51964 HEAP32[i4 + i1 >> 2] = i4;
michael@0 51965 i5 = i4 + (i1 + 4) | 0;
michael@0 51966 return i5 | 0;
michael@0 51967 }
michael@0 51968 function __ZN23btConvexConvexAlgorithm10CreateFuncC2EP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver(i1, i2, i3) {
michael@0 51969 i1 = i1 | 0;
michael@0 51970 i2 = i2 | 0;
michael@0 51971 i3 = i3 | 0;
michael@0 51972 HEAP8[i1 + 4 | 0] = 0;
michael@0 51973 HEAP32[i1 >> 2] = 2184;
michael@0 51974 HEAP32[i1 + 16 >> 2] = 0;
michael@0 51975 HEAP32[i1 + 20 >> 2] = 3;
michael@0 51976 HEAP32[i1 + 12 >> 2] = i2;
michael@0 51977 HEAP32[i1 + 8 >> 2] = i3;
michael@0 51978 return;
michael@0 51979 }
michael@0 51980 function dynCall_iiiiiiiiii(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
michael@0 51981 i1 = i1 | 0;
michael@0 51982 i2 = i2 | 0;
michael@0 51983 i3 = i3 | 0;
michael@0 51984 i4 = i4 | 0;
michael@0 51985 i5 = i5 | 0;
michael@0 51986 i6 = i6 | 0;
michael@0 51987 i7 = i7 | 0;
michael@0 51988 i8 = i8 | 0;
michael@0 51989 i9 = i9 | 0;
michael@0 51990 i10 = i10 | 0;
michael@0 51991 return FUNCTION_TABLE_iiiiiiiiii[i1 & 3](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0, i8 | 0, i9 | 0, i10 | 0) | 0;
michael@0 51992 }
michael@0 51993 function __ZN20btPersistentManifold14clearUserCacheER15btManifoldPoint(i1, i2) {
michael@0 51994 i1 = i1 | 0;
michael@0 51995 i2 = i2 | 0;
michael@0 51996 var i3 = 0;
michael@0 51997 i1 = i2 + 108 | 0;
michael@0 51998 i2 = HEAP32[i1 >> 2] | 0;
michael@0 51999 if ((i2 | 0) == 0) {
michael@0 52000 return;
michael@0 52001 }
michael@0 52002 i3 = HEAP32[3008] | 0;
michael@0 52003 if ((i3 | 0) == 0) {
michael@0 52004 return;
michael@0 52005 }
michael@0 52006 FUNCTION_TABLE_ii[i3 & 127](i2) | 0;
michael@0 52007 HEAP32[i1 >> 2] = 0;
michael@0 52008 return;
michael@0 52009 }
michael@0 52010 function __ZN17btCollisionObject8activateEb(i1, i2) {
michael@0 52011 i1 = i1 | 0;
michael@0 52012 i2 = i2 | 0;
michael@0 52013 do {
michael@0 52014 if (!i2) {
michael@0 52015 if ((HEAP32[i1 + 204 >> 2] & 3 | 0) == 0) {
michael@0 52016 break;
michael@0 52017 }
michael@0 52018 return;
michael@0 52019 }
michael@0 52020 } while (0);
michael@0 52021 i2 = i1 + 216 | 0;
michael@0 52022 if (((HEAP32[i2 >> 2] | 0) - 4 | 0) >>> 0 >= 2) {
michael@0 52023 HEAP32[i2 >> 2] = 1;
michael@0 52024 }
michael@0 52025 HEAPF32[i1 + 220 >> 2] = 0.0;
michael@0 52026 return;
michael@0 52027 }
michael@0 52028 function __ZNK16btCollisionWorld20ConvexResultCallback14needsCollisionEP17btBroadphaseProxy(i1, i2) {
michael@0 52029 i1 = i1 | 0;
michael@0 52030 i2 = i2 | 0;
michael@0 52031 var i3 = 0;
michael@0 52032 if ((HEAP16[i1 + 10 >> 1] & HEAP16[i2 + 4 >> 1]) << 16 >> 16 == 0) {
michael@0 52033 i3 = 0;
michael@0 52034 return i3 | 0;
michael@0 52035 }
michael@0 52036 i3 = (HEAP16[i2 + 6 >> 1] & HEAP16[i1 + 8 >> 1]) << 16 >> 16 != 0;
michael@0 52037 return i3 | 0;
michael@0 52038 }
michael@0 52039 function _llvm_uadd_with_overflow_i64(i1, i2, i3, i4) {
michael@0 52040 i1 = i1 | 0;
michael@0 52041 i2 = i2 | 0;
michael@0 52042 i3 = i3 | 0;
michael@0 52043 i4 = i4 | 0;
michael@0 52044 var i5 = 0;
michael@0 52045 i5 = i1 + i3 >>> 0;
michael@0 52046 i3 = i2 + i4 >>> 0;
michael@0 52047 i4 = i3 >>> 0 < i2 >>> 0 | 0;
michael@0 52048 if (i5 >>> 0 < i1 >>> 0) {
michael@0 52049 i3 = i3 + 1 >>> 0;
michael@0 52050 i4 = i4 | !i3;
michael@0 52051 }
michael@0 52052 return (tempRet0 = i3, tempRet1 = i4, i5 | 0) | 0;
michael@0 52053 }
michael@0 52054 function __ZNK23btDiscreteDynamicsWorld10getGravityEv(i1, i2) {
michael@0 52055 i1 = i1 | 0;
michael@0 52056 i2 = i2 | 0;
michael@0 52057 var i3 = 0;
michael@0 52058 i3 = i1;
michael@0 52059 i1 = i2 + 220 | 0;
michael@0 52060 HEAP32[i3 >> 2] = HEAP32[i1 >> 2];
michael@0 52061 HEAP32[i3 + 4 >> 2] = HEAP32[i1 + 4 >> 2];
michael@0 52062 HEAP32[i3 + 8 >> 2] = HEAP32[i1 + 8 >> 2];
michael@0 52063 HEAP32[i3 + 12 >> 2] = HEAP32[i1 + 12 >> 2];
michael@0 52064 return;
michael@0 52065 }
michael@0 52066 function __ZN23btDiscreteDynamicsWorld19setConstraintSolverEP18btConstraintSolver(i1, i2) {
michael@0 52067 i1 = i1 | 0;
michael@0 52068 i2 = i2 | 0;
michael@0 52069 var i3 = 0, i4 = 0;
michael@0 52070 i3 = i1 + 241 | 0;
michael@0 52071 i4 = i1 + 172 | 0;
michael@0 52072 if ((HEAP8[i3] | 0) != 0) {
michael@0 52073 __Z21btAlignedFreeInternalPv(HEAP32[i4 >> 2] | 0);
michael@0 52074 }
michael@0 52075 HEAP8[i3] = 0;
michael@0 52076 HEAP32[i4 >> 2] = i2;
michael@0 52077 return;
michael@0 52078 }
michael@0 52079 function __ZN6btDbvt6removeEP10btDbvtNode(i1, i2) {
michael@0 52080 i1 = i1 | 0;
michael@0 52081 i2 = i2 | 0;
michael@0 52082 var i3 = 0;
michael@0 52083 __ZL10removeleafP6btDbvtP10btDbvtNode(i1, i2) | 0;
michael@0 52084 i3 = i1 + 4 | 0;
michael@0 52085 __Z21btAlignedFreeInternalPv(HEAP32[i3 >> 2] | 0);
michael@0 52086 HEAP32[i3 >> 2] = i2;
michael@0 52087 i2 = i1 + 12 | 0;
michael@0 52088 HEAP32[i2 >> 2] = (HEAP32[i2 >> 2] | 0) - 1;
michael@0 52089 return;
michael@0 52090 }
michael@0 52091 function dynCall_viiiiiffii(i1, i2, i3, i4, i5, i6, d7, d8, i9, i10) {
michael@0 52092 i1 = i1 | 0;
michael@0 52093 i2 = i2 | 0;
michael@0 52094 i3 = i3 | 0;
michael@0 52095 i4 = i4 | 0;
michael@0 52096 i5 = i5 | 0;
michael@0 52097 i6 = i6 | 0;
michael@0 52098 d7 = +d7;
michael@0 52099 d8 = +d8;
michael@0 52100 i9 = i9 | 0;
michael@0 52101 i10 = i10 | 0;
michael@0 52102 FUNCTION_TABLE_viiiiiffii[i1 & 3](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, +d7, +d8, i9 | 0, i10 | 0);
michael@0 52103 }
michael@0 52104 function __ZN27btContinuousConvexCollisionC2EPK13btConvexShapePK18btStaticPlaneShape(i1, i2, i3) {
michael@0 52105 i1 = i1 | 0;
michael@0 52106 i2 = i2 | 0;
michael@0 52107 i3 = i3 | 0;
michael@0 52108 HEAP32[i1 >> 2] = 2928;
michael@0 52109 HEAP32[i1 + 4 >> 2] = 0;
michael@0 52110 HEAP32[i1 + 8 >> 2] = 0;
michael@0 52111 HEAP32[i1 + 12 >> 2] = i2;
michael@0 52112 HEAP32[i1 + 16 >> 2] = 0;
michael@0 52113 HEAP32[i1 + 20 >> 2] = i3;
michael@0 52114 return;
michael@0 52115 }
michael@0 52116 function __ZN12CProfileNode5ResetEv(i1) {
michael@0 52117 i1 = i1 | 0;
michael@0 52118 var i2 = 0;
michael@0 52119 i2 = i1;
michael@0 52120 do {
michael@0 52121 HEAP32[i2 + 4 >> 2] = 0;
michael@0 52122 HEAPF32[i2 + 8 >> 2] = 0.0;
michael@0 52123 i1 = HEAP32[i2 + 24 >> 2] | 0;
michael@0 52124 if ((i1 | 0) != 0) {
michael@0 52125 __ZN12CProfileNode5ResetEv(i1);
michael@0 52126 }
michael@0 52127 i2 = HEAP32[i2 + 28 >> 2] | 0;
michael@0 52128 } while ((i2 | 0) != 0);
michael@0 52129 return;
michael@0 52130 }
michael@0 52131 function __ZN30btActivatingCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_(i1, i2, i3, i4) {
michael@0 52132 i1 = i1 | 0;
michael@0 52133 i2 = i2 | 0;
michael@0 52134 i3 = i3 | 0;
michael@0 52135 i4 = i4 | 0;
michael@0 52136 __ZN20btCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfo(i1 | 0, i2);
michael@0 52137 HEAP32[i1 >> 2] = 2728;
michael@0 52138 return;
michael@0 52139 }
michael@0 52140 function ___uremdi3(i1, i2, i3, i4) {
michael@0 52141 i1 = i1 | 0;
michael@0 52142 i2 = i2 | 0;
michael@0 52143 i3 = i3 | 0;
michael@0 52144 i4 = i4 | 0;
michael@0 52145 var i5 = 0, i6 = 0;
michael@0 52146 i5 = STACKTOP;
michael@0 52147 STACKTOP = STACKTOP + 8 | 0;
michael@0 52148 i6 = i5 | 0;
michael@0 52149 ___udivmoddi4(i1, i2, i3, i4, i6) | 0;
michael@0 52150 STACKTOP = i5;
michael@0 52151 return (tempRet0 = HEAP32[i6 + 4 >> 2] | 0, HEAP32[i6 >> 2] | 0) | 0;
michael@0 52152 }
michael@0 52153 function __ZN21btConvexInternalShapeC2Ev(i1) {
michael@0 52154 i1 = i1 | 0;
michael@0 52155 __ZN13btConvexShapeC2Ev(i1 | 0);
michael@0 52156 HEAP32[i1 >> 2] = 3680;
michael@0 52157 HEAPF32[i1 + 12 >> 2] = 1.0;
michael@0 52158 HEAPF32[i1 + 16 >> 2] = 1.0;
michael@0 52159 HEAPF32[i1 + 20 >> 2] = 1.0;
michael@0 52160 HEAPF32[i1 + 24 >> 2] = 0.0;
michael@0 52161 HEAPF32[i1 + 44 >> 2] = .03999999910593033;
michael@0 52162 return;
michael@0 52163 }
michael@0 52164 function __GLOBAL__I_a() {
michael@0 52165 var i1 = 0;
michael@0 52166 i1 = __Znwj(8) | 0;
michael@0 52167 HEAP32[3578] = i1;
michael@0 52168 _gettimeofday(i1 | 0, 0) | 0;
michael@0 52169 _atexit(336, 14312, ___dso_handle | 0) | 0;
michael@0 52170 HEAP32[3564] = 264;
michael@0 52171 _memset(14260, 0, 28);
michael@0 52172 __ZN12CProfileNode5ResetEv(14256);
michael@0 52173 _atexit(246, 14256, ___dso_handle | 0) | 0;
michael@0 52174 return;
michael@0 52175 }
michael@0 52176 function dynCall_viiiiiiii(i1, i2, i3, i4, i5, i6, i7, i8, i9) {
michael@0 52177 i1 = i1 | 0;
michael@0 52178 i2 = i2 | 0;
michael@0 52179 i3 = i3 | 0;
michael@0 52180 i4 = i4 | 0;
michael@0 52181 i5 = i5 | 0;
michael@0 52182 i6 = i6 | 0;
michael@0 52183 i7 = i7 | 0;
michael@0 52184 i8 = i8 | 0;
michael@0 52185 i9 = i9 | 0;
michael@0 52186 FUNCTION_TABLE_viiiiiiii[i1 & 3](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0, i8 | 0, i9 | 0);
michael@0 52187 }
michael@0 52188 function __ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResult20setShapeIdentifiersBEii(i1, i2, i3) {
michael@0 52189 i1 = i1 | 0;
michael@0 52190 i2 = i2 | 0;
michael@0 52191 i3 = i3 | 0;
michael@0 52192 return;
michael@0 52193 }
michael@0 52194 function __ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResult20setShapeIdentifiersAEii(i1, i2, i3) {
michael@0 52195 i1 = i1 | 0;
michael@0 52196 i2 = i2 | 0;
michael@0 52197 i3 = i3 | 0;
michael@0 52198 return;
michael@0 52199 }
michael@0 52200 function __ZN6btDbvtC2Ev(i1) {
michael@0 52201 i1 = i1 | 0;
michael@0 52202 HEAP8[i1 + 36 | 0] = 1;
michael@0 52203 HEAP32[i1 + 32 >> 2] = 0;
michael@0 52204 HEAP32[i1 + 24 >> 2] = 0;
michael@0 52205 HEAP32[i1 + 28 >> 2] = 0;
michael@0 52206 HEAP32[i1 >> 2] = 0;
michael@0 52207 HEAP32[i1 + 4 >> 2] = 0;
michael@0 52208 HEAP32[i1 + 8 >> 2] = -1;
michael@0 52209 HEAP32[i1 + 12 >> 2] = 0;
michael@0 52210 HEAP32[i1 + 16 >> 2] = 0;
michael@0 52211 return;
michael@0 52212 }
michael@0 52213 function __ZThn4_N17DebugDrawcallback28internalProcessTriangleIndexEP9btVector3ii(i1, i2, i3, i4) {
michael@0 52214 i1 = i1 | 0;
michael@0 52215 i2 = i2 | 0;
michael@0 52216 i3 = i3 | 0;
michael@0 52217 i4 = i4 | 0;
michael@0 52218 var i5 = 0;
michael@0 52219 i5 = i1 - 92 + 88 | 0;
michael@0 52220 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i5 >> 2] | 0) + 8 >> 2] & 127](i5, i2, i3, i4);
michael@0 52221 return;
michael@0 52222 }
michael@0 52223 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD0E_0v(i1) {
michael@0 52224 i1 = i1 | 0;
michael@0 52225 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52226 __ZdlPv(i1);
michael@0 52227 return;
michael@0 52228 }
michael@0 52229 function ___muldi3(i1, i2, i3, i4) {
michael@0 52230 i1 = i1 | 0;
michael@0 52231 i2 = i2 | 0;
michael@0 52232 i3 = i3 | 0;
michael@0 52233 i4 = i4 | 0;
michael@0 52234 var i5 = 0, i6 = 0;
michael@0 52235 i5 = i1;
michael@0 52236 i1 = i3;
michael@0 52237 i3 = ___muldsi3(i5, i1) | 0;
michael@0 52238 i6 = tempRet0;
michael@0 52239 return (tempRet0 = (Math_imul(i2, i1) | 0) + (Math_imul(i4, i5) | 0) + i6 | i6 & 0, i3 | 0 | 0) | 0;
michael@0 52240 }
michael@0 52241 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD0Ev(i1) {
michael@0 52242 i1 = i1 | 0;
michael@0 52243 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52244 __ZdlPv(i1);
michael@0 52245 return;
michael@0 52246 }
michael@0 52247 function __ZN22btSubsimplexConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver(i1, i2, i3, i4) {
michael@0 52248 i1 = i1 | 0;
michael@0 52249 i2 = i2 | 0;
michael@0 52250 i3 = i3 | 0;
michael@0 52251 i4 = i4 | 0;
michael@0 52252 HEAP32[i1 >> 2] = 3536;
michael@0 52253 HEAP32[i1 + 4 >> 2] = i4;
michael@0 52254 HEAP32[i1 + 8 >> 2] = i2;
michael@0 52255 HEAP32[i1 + 12 >> 2] = i3;
michael@0 52256 return;
michael@0 52257 }
michael@0 52258 function dynCall_iiiiiiii(i1, i2, i3, i4, i5, i6, i7, i8) {
michael@0 52259 i1 = i1 | 0;
michael@0 52260 i2 = i2 | 0;
michael@0 52261 i3 = i3 | 0;
michael@0 52262 i4 = i4 | 0;
michael@0 52263 i5 = i5 | 0;
michael@0 52264 i6 = i6 | 0;
michael@0 52265 i7 = i7 | 0;
michael@0 52266 i8 = i8 | 0;
michael@0 52267 return FUNCTION_TABLE_iiiiiiii[i1 & 1](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0, i8 | 0) | 0;
michael@0 52268 }
michael@0 52269 function __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallbackD0Ev(i1) {
michael@0 52270 i1 = i1 | 0;
michael@0 52271 __ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallbackD2Ev(i1);
michael@0 52272 __ZdlPv(i1);
michael@0 52273 return;
michael@0 52274 }
michael@0 52275 function __ZN23btPolyhedralConvexShapeD0Ev(i1) {
michael@0 52276 i1 = i1 | 0;
michael@0 52277 var i2 = 0;
michael@0 52278 HEAP32[i1 >> 2] = 3136;
michael@0 52279 i2 = HEAP32[i1 + 52 >> 2] | 0;
michael@0 52280 if ((i2 | 0) != 0) {
michael@0 52281 __Z21btAlignedFreeInternalPv(i2);
michael@0 52282 }
michael@0 52283 __ZN13btConvexShapeD2Ev(i1 | 0);
michael@0 52284 __Z21btAlignedFreeInternalPv(i1);
michael@0 52285 return;
michael@0 52286 }
michael@0 52287 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD2E_0v(i1) {
michael@0 52288 i1 = i1 | 0;
michael@0 52289 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52290 return;
michael@0 52291 }
michael@0 52292 function __ZN15btGjkConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver(i1, i2, i3, i4) {
michael@0 52293 i1 = i1 | 0;
michael@0 52294 i2 = i2 | 0;
michael@0 52295 i3 = i3 | 0;
michael@0 52296 i4 = i4 | 0;
michael@0 52297 HEAP32[i1 >> 2] = 4696;
michael@0 52298 HEAP32[i1 + 4 >> 2] = i4;
michael@0 52299 HEAP32[i1 + 8 >> 2] = i2;
michael@0 52300 HEAP32[i1 + 12 >> 2] = i3;
michael@0 52301 return;
michael@0 52302 }
michael@0 52303 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD2Ev(i1) {
michael@0 52304 i1 = i1 | 0;
michael@0 52305 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52306 return;
michael@0 52307 }
michael@0 52308 function __ZN22SphereTriangleDetectorC2EP13btSphereShapeP15btTriangleShapef(i1, i2, i3, d4) {
michael@0 52309 i1 = i1 | 0;
michael@0 52310 i2 = i2 | 0;
michael@0 52311 i3 = i3 | 0;
michael@0 52312 d4 = +d4;
michael@0 52313 HEAP32[i1 >> 2] = 3616;
michael@0 52314 HEAP32[i1 + 4 >> 2] = i2;
michael@0 52315 HEAP32[i1 + 8 >> 2] = i3;
michael@0 52316 HEAPF32[i1 + 12 >> 2] = d4;
michael@0 52317 return;
michael@0 52318 }
michael@0 52319 function __ZN11btRigidBody26predictIntegratedTransformEfR11btTransform(i1, d2, i3) {
michael@0 52320 i1 = i1 | 0;
michael@0 52321 d2 = +d2;
michael@0 52322 i3 = i3 | 0;
michael@0 52323 __ZN15btTransformUtil18integrateTransformERK11btTransformRK9btVector3S5_fRS0_(i1 + 4 | 0, i1 + 304 | 0, i1 + 320 | 0, d2, i3);
michael@0 52324 return;
michael@0 52325 }
michael@0 52326 function __ZZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN31LocalTriangleSphereCastCallbackD0Ev(i1) {
michael@0 52327 i1 = i1 | 0;
michael@0 52328 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52329 __ZdlPv(i1);
michael@0 52330 return;
michael@0 52331 }
michael@0 52332 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD0E_0v(i1) {
michael@0 52333 i1 = i1 | 0;
michael@0 52334 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52335 __ZdlPv(i1);
michael@0 52336 return;
michael@0 52337 }
michael@0 52338 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD0Ev(i1) {
michael@0 52339 i1 = i1 | 0;
michael@0 52340 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52341 __ZdlPv(i1);
michael@0 52342 return;
michael@0 52343 }
michael@0 52344 function __ZN23btDiscreteDynamicsWorld18addCollisionObjectEP17btCollisionObjectss(i1, i2, i3, i4) {
michael@0 52345 i1 = i1 | 0;
michael@0 52346 i2 = i2 | 0;
michael@0 52347 i3 = i3 | 0;
michael@0 52348 i4 = i4 | 0;
michael@0 52349 __ZN16btCollisionWorld18addCollisionObjectEP17btCollisionObjectss(i1 | 0, i2, i3, i4);
michael@0 52350 return;
michael@0 52351 }
michael@0 52352 function __ZN19BroadphaseRayTester7ProcessEPK10btDbvtNode(i1, i2) {
michael@0 52353 i1 = i1 | 0;
michael@0 52354 i2 = i2 | 0;
michael@0 52355 var i3 = 0;
michael@0 52356 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 52357 FUNCTION_TABLE_iii[HEAP32[(HEAP32[i3 >> 2] | 0) + 8 >> 2] & 63](i3 | 0, HEAP32[i2 + 36 >> 2] | 0) | 0;
michael@0 52358 return;
michael@0 52359 }
michael@0 52360 function __ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResult15addContactPointERK9btVector3SA_f(i1, i2, i3, d4) {
michael@0 52361 i1 = i1 | 0;
michael@0 52362 i2 = i2 | 0;
michael@0 52363 i3 = i3 | 0;
michael@0 52364 d4 = +d4;
michael@0 52365 return;
michael@0 52366 }
michael@0 52367 function __ZN23btCollisionPairCallback14processOverlapER16btBroadphasePair(i1, i2) {
michael@0 52368 i1 = i1 | 0;
michael@0 52369 i2 = i2 | 0;
michael@0 52370 var i3 = 0;
michael@0 52371 i3 = HEAP32[i1 + 8 >> 2] | 0;
michael@0 52372 FUNCTION_TABLE_viii[HEAP32[i3 + 188 >> 2] & 127](i2, i3, HEAP32[i1 + 4 >> 2] | 0);
michael@0 52373 return 0;
michael@0 52374 }
michael@0 52375 function __ZN16btDbvtBroadphase25calculateOverlappingPairsEP12btDispatcher(i1, i2) {
michael@0 52376 i1 = i1 | 0;
michael@0 52377 i2 = i2 | 0;
michael@0 52378 __ZN16btDbvtBroadphase7collideEP12btDispatcher(i1, i2);
michael@0 52379 __ZN16btDbvtBroadphase22performDeferredRemovalEP12btDispatcher(i1, i2);
michael@0 52380 return;
michael@0 52381 }
michael@0 52382 function __ZN20BroadphaseAabbTester7ProcessEPK10btDbvtNode(i1, i2) {
michael@0 52383 i1 = i1 | 0;
michael@0 52384 i2 = i2 | 0;
michael@0 52385 var i3 = 0;
michael@0 52386 i3 = HEAP32[i1 + 4 >> 2] | 0;
michael@0 52387 FUNCTION_TABLE_iii[HEAP32[(HEAP32[i3 >> 2] | 0) + 8 >> 2] & 63](i3, HEAP32[i2 + 36 >> 2] | 0) | 0;
michael@0 52388 return;
michael@0 52389 }
michael@0 52390 function __ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResultD0Ev(i1) {
michael@0 52391 i1 = i1 | 0;
michael@0 52392 __ZdlPv(i1);
michael@0 52393 return;
michael@0 52394 }
michael@0 52395 function dynCall_iiiiiii(i1, i2, i3, i4, i5, i6, i7) {
michael@0 52396 i1 = i1 | 0;
michael@0 52397 i2 = i2 | 0;
michael@0 52398 i3 = i3 | 0;
michael@0 52399 i4 = i4 | 0;
michael@0 52400 i5 = i5 | 0;
michael@0 52401 i6 = i6 | 0;
michael@0 52402 i7 = i7 | 0;
michael@0 52403 return FUNCTION_TABLE_iiiiiii[i1 & 7](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0) | 0;
michael@0 52404 }
michael@0 52405 function _bitshift64Ashr(i1, i2, i3) {
michael@0 52406 i1 = i1 | 0;
michael@0 52407 i2 = i2 | 0;
michael@0 52408 i3 = i3 | 0;
michael@0 52409 if ((i3 | 0) < 32) {
michael@0 52410 tempRet0 = i2 >> i3;
michael@0 52411 return i1 >>> i3 | (i2 & (1 << i3) - 1) << 32 - i3;
michael@0 52412 }
michael@0 52413 tempRet0 = (i2 | 0) < 0 ? -1 : 0;
michael@0 52414 return i2 >> i3 - 32 | 0;
michael@0 52415 }
michael@0 52416 function __ZNK21btConvexInternalShape7getAabbERK11btTransformR9btVector3S4_(i1, i2, i3, i4) {
michael@0 52417 i1 = i1 | 0;
michael@0 52418 i2 = i2 | 0;
michael@0 52419 i3 = i3 | 0;
michael@0 52420 i4 = i4 | 0;
michael@0 52421 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 72 >> 2] & 127](i1, i2, i3, i4);
michael@0 52422 return;
michael@0 52423 }
michael@0 52424 function __ZN17DebugDrawcallback28internalProcessTriangleIndexEP9btVector3ii(i1, i2, i3, i4) {
michael@0 52425 i1 = i1 | 0;
michael@0 52426 i2 = i2 | 0;
michael@0 52427 i3 = i3 | 0;
michael@0 52428 i4 = i4 | 0;
michael@0 52429 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i1, i2, i3, i4);
michael@0 52430 return;
michael@0 52431 }
michael@0 52432 function b12(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 52433 i1 = i1 | 0;
michael@0 52434 i2 = i2 | 0;
michael@0 52435 i3 = i3 | 0;
michael@0 52436 i4 = i4 | 0;
michael@0 52437 i5 = i5 | 0;
michael@0 52438 i6 = i6 | 0;
michael@0 52439 i7 = i7 | 0;
michael@0 52440 i8 = i8 | 0;
michael@0 52441 i9 = i9 | 0;
michael@0 52442 i10 = i10 | 0;
michael@0 52443 i11 = i11 | 0;
michael@0 52444 abort(12);
michael@0 52445 return 0.0;
michael@0 52446 }
michael@0 52447 function __ZZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN31LocalTriangleSphereCastCallbackD2Ev(i1) {
michael@0 52448 i1 = i1 | 0;
michael@0 52449 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52450 return;
michael@0 52451 }
michael@0 52452 function __ZNK15btTriangleShape7getAabbERK11btTransformR9btVector3S4_(i1, i2, i3, i4) {
michael@0 52453 i1 = i1 | 0;
michael@0 52454 i2 = i2 | 0;
michael@0 52455 i3 = i3 | 0;
michael@0 52456 i4 = i4 | 0;
michael@0 52457 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 72 >> 2] & 127](i1 | 0, i2, i3, i4);
michael@0 52458 return;
michael@0 52459 }
michael@0 52460 function b25(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11) {
michael@0 52461 i1 = i1 | 0;
michael@0 52462 i2 = i2 | 0;
michael@0 52463 i3 = i3 | 0;
michael@0 52464 i4 = i4 | 0;
michael@0 52465 i5 = i5 | 0;
michael@0 52466 i6 = i6 | 0;
michael@0 52467 i7 = i7 | 0;
michael@0 52468 i8 = i8 | 0;
michael@0 52469 i9 = i9 | 0;
michael@0 52470 i10 = i10 | 0;
michael@0 52471 i11 = i11 | 0;
michael@0 52472 abort(25);
michael@0 52473 return 0;
michael@0 52474 }
michael@0 52475 function __ZN34btSphereTriangleCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 52476 i1 = i1 | 0;
michael@0 52477 i2 = i2 | 0;
michael@0 52478 i3 = i3 | 0;
michael@0 52479 i4 = i4 | 0;
michael@0 52480 i5 = i5 | 0;
michael@0 52481 return +1.0;
michael@0 52482 }
michael@0 52483 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD2E_0v(i1) {
michael@0 52484 i1 = i1 | 0;
michael@0 52485 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52486 return;
michael@0 52487 }
michael@0 52488 function __ZN32btSphereSphereCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 52489 i1 = i1 | 0;
michael@0 52490 i2 = i2 | 0;
michael@0 52491 i3 = i3 | 0;
michael@0 52492 i4 = i4 | 0;
michael@0 52493 i5 = i5 | 0;
michael@0 52494 return +1.0;
michael@0 52495 }
michael@0 52496 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD2Ev(i1) {
michael@0 52497 i1 = i1 | 0;
michael@0 52498 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52499 return;
michael@0 52500 }
michael@0 52501 function __ZN31btConvexPlaneCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 52502 i1 = i1 | 0;
michael@0 52503 i2 = i2 | 0;
michael@0 52504 i3 = i3 | 0;
michael@0 52505 i4 = i4 | 0;
michael@0 52506 i5 = i5 | 0;
michael@0 52507 return +1.0;
michael@0 52508 }
michael@0 52509 function __ZN23btPolyhedralConvexShapeD2Ev(i1) {
michael@0 52510 i1 = i1 | 0;
michael@0 52511 var i2 = 0;
michael@0 52512 HEAP32[i1 >> 2] = 3136;
michael@0 52513 i2 = HEAP32[i1 + 52 >> 2] | 0;
michael@0 52514 if ((i2 | 0) != 0) {
michael@0 52515 __Z21btAlignedFreeInternalPv(i2);
michael@0 52516 }
michael@0 52517 __ZN13btConvexShapeD2Ev(i1 | 0);
michael@0 52518 return;
michael@0 52519 }
michael@0 52520 function dynCall_fiiifii(i1, i2, i3, i4, d5, i6, i7) {
michael@0 52521 i1 = i1 | 0;
michael@0 52522 i2 = i2 | 0;
michael@0 52523 i3 = i3 | 0;
michael@0 52524 i4 = i4 | 0;
michael@0 52525 d5 = +d5;
michael@0 52526 i6 = i6 | 0;
michael@0 52527 i7 = i7 | 0;
michael@0 52528 return +FUNCTION_TABLE_fiiifii[i1 & 7](i2 | 0, i3 | 0, i4 | 0, +d5, i6 | 0, i7 | 0);
michael@0 52529 }
michael@0 52530 function dynCall_viiiiii(i1, i2, i3, i4, i5, i6, i7) {
michael@0 52531 i1 = i1 | 0;
michael@0 52532 i2 = i2 | 0;
michael@0 52533 i3 = i3 | 0;
michael@0 52534 i4 = i4 | 0;
michael@0 52535 i5 = i5 | 0;
michael@0 52536 i6 = i6 | 0;
michael@0 52537 i7 = i7 | 0;
michael@0 52538 FUNCTION_TABLE_viiiiii[i1 & 15](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0, i7 | 0);
michael@0 52539 }
michael@0 52540 function __ZN26btBoxBoxCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 52541 i1 = i1 | 0;
michael@0 52542 i2 = i2 | 0;
michael@0 52543 i3 = i3 | 0;
michael@0 52544 i4 = i4 | 0;
michael@0 52545 i5 = i5 | 0;
michael@0 52546 return +1.0;
michael@0 52547 }
michael@0 52548 function __ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResultD2Ev(i1) {
michael@0 52549 i1 = i1 | 0;
michael@0 52550 return;
michael@0 52551 }
michael@0 52552 function copyTempFloat(i1) {
michael@0 52553 i1 = i1 | 0;
michael@0 52554 HEAP8[tempDoublePtr] = HEAP8[i1];
michael@0 52555 HEAP8[tempDoublePtr + 1 | 0] = HEAP8[i1 + 1 | 0];
michael@0 52556 HEAP8[tempDoublePtr + 2 | 0] = HEAP8[i1 + 2 | 0];
michael@0 52557 HEAP8[tempDoublePtr + 3 | 0] = HEAP8[i1 + 3 | 0];
michael@0 52558 }
michael@0 52559 function _bitshift64Shl(i1, i2, i3) {
michael@0 52560 i1 = i1 | 0;
michael@0 52561 i2 = i2 | 0;
michael@0 52562 i3 = i3 | 0;
michael@0 52563 if ((i3 | 0) < 32) {
michael@0 52564 tempRet0 = i2 << i3 | (i1 & (1 << i3) - 1 << 32 - i3) >>> 32 - i3;
michael@0 52565 return i1 << i3;
michael@0 52566 }
michael@0 52567 tempRet0 = i1 << i3 - 32;
michael@0 52568 return 0;
michael@0 52569 }
michael@0 52570 function __ZN16btEmptyAlgorithmC2ERK36btCollisionAlgorithmConstructionInfo(i1, i2) {
michael@0 52571 i1 = i1 | 0;
michael@0 52572 i2 = i2 | 0;
michael@0 52573 __ZN20btCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfo(i1 | 0, i2);
michael@0 52574 HEAP32[i1 >> 2] = 4352;
michael@0 52575 return;
michael@0 52576 }
michael@0 52577 function __ZN18btDbvtTreeCollider7ProcessEPK10btDbvtNode(i1, i2) {
michael@0 52578 i1 = i1 | 0;
michael@0 52579 i2 = i2 | 0;
michael@0 52580 FUNCTION_TABLE_viii[HEAP32[(HEAP32[i1 >> 2] | 0) + 8 >> 2] & 127](i1, i2, HEAP32[(HEAP32[i1 + 8 >> 2] | 0) + 48 >> 2] | 0);
michael@0 52581 return;
michael@0 52582 }
michael@0 52583 function dynCall_viiifii(i1, i2, i3, i4, d5, i6, i7) {
michael@0 52584 i1 = i1 | 0;
michael@0 52585 i2 = i2 | 0;
michael@0 52586 i3 = i3 | 0;
michael@0 52587 i4 = i4 | 0;
michael@0 52588 d5 = +d5;
michael@0 52589 i6 = i6 | 0;
michael@0 52590 i7 = i7 | 0;
michael@0 52591 FUNCTION_TABLE_viiifii[i1 & 1](i2 | 0, i3 | 0, i4 | 0, +d5, i6 | 0, i7 | 0);
michael@0 52592 }
michael@0 52593 function __ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResult20setShapeIdentifiersBEii(i1, i2, i3) {
michael@0 52594 i1 = i1 | 0;
michael@0 52595 i2 = i2 | 0;
michael@0 52596 i3 = i3 | 0;
michael@0 52597 return;
michael@0 52598 }
michael@0 52599 function __ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResult20setShapeIdentifiersAEii(i1, i2, i3) {
michael@0 52600 i1 = i1 | 0;
michael@0 52601 i2 = i2 | 0;
michael@0 52602 i3 = i3 | 0;
michael@0 52603 return;
michael@0 52604 }
michael@0 52605 function _i64Subtract(i1, i2, i3, i4) {
michael@0 52606 i1 = i1 | 0;
michael@0 52607 i2 = i2 | 0;
michael@0 52608 i3 = i3 | 0;
michael@0 52609 i4 = i4 | 0;
michael@0 52610 var i5 = 0;
michael@0 52611 i5 = i2 - i4 >>> 0;
michael@0 52612 i5 = i2 - i4 - (i3 >>> 0 > i1 >>> 0 | 0) >>> 0;
michael@0 52613 return (tempRet0 = i5, i1 - i3 >>> 0 | 0) | 0;
michael@0 52614 }
michael@0 52615 function _bitshift64Lshr(i1, i2, i3) {
michael@0 52616 i1 = i1 | 0;
michael@0 52617 i2 = i2 | 0;
michael@0 52618 i3 = i3 | 0;
michael@0 52619 if ((i3 | 0) < 32) {
michael@0 52620 tempRet0 = i2 >>> i3;
michael@0 52621 return i1 >>> i3 | (i2 & (1 << i3) - 1) << 32 - i3;
michael@0 52622 }
michael@0 52623 tempRet0 = 0;
michael@0 52624 return i2 >>> i3 - 32 | 0;
michael@0 52625 }
michael@0 52626 function __ZNK15btTriangleShape8getPlaneER9btVector3S1_i(i1, i2, i3, i4) {
michael@0 52627 i1 = i1 | 0;
michael@0 52628 i2 = i2 | 0;
michael@0 52629 i3 = i3 | 0;
michael@0 52630 i4 = i4 | 0;
michael@0 52631 FUNCTION_TABLE_viiii[HEAP32[(HEAP32[i1 >> 2] | 0) + 116 >> 2] & 127](i1, i4, i2, i3);
michael@0 52632 return;
michael@0 52633 }
michael@0 52634 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN14LocalInfoAdderD0E_1v(i1) {
michael@0 52635 i1 = i1 | 0;
michael@0 52636 __ZdlPv(i1);
michael@0 52637 return;
michael@0 52638 }
michael@0 52639 function __ZN16btEmptyAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 52640 i1 = i1 | 0;
michael@0 52641 i2 = i2 | 0;
michael@0 52642 i3 = i3 | 0;
michael@0 52643 i4 = i4 | 0;
michael@0 52644 i5 = i5 | 0;
michael@0 52645 return +1.0;
michael@0 52646 }
michael@0 52647 function b23(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
michael@0 52648 i1 = i1 | 0;
michael@0 52649 i2 = i2 | 0;
michael@0 52650 i3 = i3 | 0;
michael@0 52651 i4 = i4 | 0;
michael@0 52652 i5 = i5 | 0;
michael@0 52653 i6 = i6 | 0;
michael@0 52654 i7 = i7 | 0;
michael@0 52655 i8 = i8 | 0;
michael@0 52656 i9 = i9 | 0;
michael@0 52657 i10 = i10 | 0;
michael@0 52658 abort(23);
michael@0 52659 return 0.0;
michael@0 52660 }
michael@0 52661 function dynCall_viffiii(i1, i2, d3, d4, i5, i6, i7) {
michael@0 52662 i1 = i1 | 0;
michael@0 52663 i2 = i2 | 0;
michael@0 52664 d3 = +d3;
michael@0 52665 d4 = +d4;
michael@0 52666 i5 = i5 | 0;
michael@0 52667 i6 = i6 | 0;
michael@0 52668 i7 = i7 | 0;
michael@0 52669 FUNCTION_TABLE_viffiii[i1 & 1](i2 | 0, +d3, +d4, i5 | 0, i6 | 0, i7 | 0);
michael@0 52670 }
michael@0 52671 function __ZN17btCollisionObject18setActivationStateEi(i1, i2) {
michael@0 52672 i1 = i1 | 0;
michael@0 52673 i2 = i2 | 0;
michael@0 52674 var i3 = 0;
michael@0 52675 i3 = i1 + 216 | 0;
michael@0 52676 if (((HEAP32[i3 >> 2] | 0) - 4 | 0) >>> 0 < 2) {
michael@0 52677 return;
michael@0 52678 }
michael@0 52679 HEAP32[i3 >> 2] = i2;
michael@0 52680 return;
michael@0 52681 }
michael@0 52682 function __ZThn4_N17DebugDrawcallbackD0Ev(i1) {
michael@0 52683 i1 = i1 | 0;
michael@0 52684 var i2 = 0;
michael@0 52685 i2 = i1 - 92 + 88 | 0;
michael@0 52686 __ZN31btInternalTriangleIndexCallbackD2Ev(i1 - 92 + 92 | 0);
michael@0 52687 __ZN18btTriangleCallbackD2Ev(i2);
michael@0 52688 __ZdlPv(i2);
michael@0 52689 return;
michael@0 52690 }
michael@0 52691 function dynCall_fiiiii(i1, i2, i3, i4, i5, i6) {
michael@0 52692 i1 = i1 | 0;
michael@0 52693 i2 = i2 | 0;
michael@0 52694 i3 = i3 | 0;
michael@0 52695 i4 = i4 | 0;
michael@0 52696 i5 = i5 | 0;
michael@0 52697 i6 = i6 | 0;
michael@0 52698 return +FUNCTION_TABLE_fiiiii[i1 & 31](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0);
michael@0 52699 }
michael@0 52700 function b9(i1, i2, i3, i4, d5, d6, d7, d8, i9, i10, d11) {
michael@0 52701 i1 = i1 | 0;
michael@0 52702 i2 = i2 | 0;
michael@0 52703 i3 = i3 | 0;
michael@0 52704 i4 = i4 | 0;
michael@0 52705 d5 = +d5;
michael@0 52706 d6 = +d6;
michael@0 52707 d7 = +d7;
michael@0 52708 d8 = +d8;
michael@0 52709 i9 = i9 | 0;
michael@0 52710 i10 = i10 | 0;
michael@0 52711 d11 = +d11;
michael@0 52712 abort(9);
michael@0 52713 }
michael@0 52714 function __ZN16btEmptyAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult(i1, i2, i3, i4, i5) {
michael@0 52715 i1 = i1 | 0;
michael@0 52716 i2 = i2 | 0;
michael@0 52717 i3 = i3 | 0;
michael@0 52718 i4 = i4 | 0;
michael@0 52719 i5 = i5 | 0;
michael@0 52720 return;
michael@0 52721 }
michael@0 52722 function b29(i1, i2, i3, i4, d5, d6, d7, d8, d9, i10, d11) {
michael@0 52723 i1 = i1 | 0;
michael@0 52724 i2 = i2 | 0;
michael@0 52725 i3 = i3 | 0;
michael@0 52726 i4 = i4 | 0;
michael@0 52727 d5 = +d5;
michael@0 52728 d6 = +d6;
michael@0 52729 d7 = +d7;
michael@0 52730 d8 = +d8;
michael@0 52731 d9 = +d9;
michael@0 52732 i10 = i10 | 0;
michael@0 52733 d11 = +d11;
michael@0 52734 abort(29);
michael@0 52735 }
michael@0 52736 function __ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN14LocalInfoAdderD2E_1v(i1) {
michael@0 52737 i1 = i1 | 0;
michael@0 52738 return;
michael@0 52739 }
michael@0 52740 function b28(i1, i2, i3, i4, i5, i6, i7, i8, i9, i10) {
michael@0 52741 i1 = i1 | 0;
michael@0 52742 i2 = i2 | 0;
michael@0 52743 i3 = i3 | 0;
michael@0 52744 i4 = i4 | 0;
michael@0 52745 i5 = i5 | 0;
michael@0 52746 i6 = i6 | 0;
michael@0 52747 i7 = i7 | 0;
michael@0 52748 i8 = i8 | 0;
michael@0 52749 i9 = i9 | 0;
michael@0 52750 i10 = i10 | 0;
michael@0 52751 abort(28);
michael@0 52752 }
michael@0 52753 function dynCall_fiifii(i1, i2, i3, d4, i5, i6) {
michael@0 52754 i1 = i1 | 0;
michael@0 52755 i2 = i2 | 0;
michael@0 52756 i3 = i3 | 0;
michael@0 52757 d4 = +d4;
michael@0 52758 i5 = i5 | 0;
michael@0 52759 i6 = i6 | 0;
michael@0 52760 return +FUNCTION_TABLE_fiifii[i1 & 7](i2 | 0, i3 | 0, +d4, i5 | 0, i6 | 0);
michael@0 52761 }
michael@0 52762 function dynCall_viiiii(i1, i2, i3, i4, i5, i6) {
michael@0 52763 i1 = i1 | 0;
michael@0 52764 i2 = i2 | 0;
michael@0 52765 i3 = i3 | 0;
michael@0 52766 i4 = i4 | 0;
michael@0 52767 i5 = i5 | 0;
michael@0 52768 i6 = i6 | 0;
michael@0 52769 FUNCTION_TABLE_viiiii[i1 & 63](i2 | 0, i3 | 0, i4 | 0, i5 | 0, i6 | 0);
michael@0 52770 }
michael@0 52771 function _i64Add(i1, i2, i3, i4) {
michael@0 52772 i1 = i1 | 0;
michael@0 52773 i2 = i2 | 0;
michael@0 52774 i3 = i3 | 0;
michael@0 52775 i4 = i4 | 0;
michael@0 52776 var i5 = 0;
michael@0 52777 i5 = i1 + i3 >>> 0;
michael@0 52778 return (tempRet0 = i2 + i4 + (i5 >>> 0 < i1 >>> 0 | 0) >>> 0, i5 | 0) | 0;
michael@0 52779 }
michael@0 52780 function dynCall_viifii(i1, i2, i3, d4, i5, i6) {
michael@0 52781 i1 = i1 | 0;
michael@0 52782 i2 = i2 | 0;
michael@0 52783 i3 = i3 | 0;
michael@0 52784 d4 = +d4;
michael@0 52785 i5 = i5 | 0;
michael@0 52786 i6 = i6 | 0;
michael@0 52787 FUNCTION_TABLE_viifii[i1 & 1](i2 | 0, i3 | 0, +d4, i5 | 0, i6 | 0);
michael@0 52788 }
michael@0 52789 function dynCall_vifiii(i1, i2, d3, i4, i5, i6) {
michael@0 52790 i1 = i1 | 0;
michael@0 52791 i2 = i2 | 0;
michael@0 52792 d3 = +d3;
michael@0 52793 i4 = i4 | 0;
michael@0 52794 i5 = i5 | 0;
michael@0 52795 i6 = i6 | 0;
michael@0 52796 FUNCTION_TABLE_vifiii[i1 & 3](i2 | 0, +d3, i4 | 0, i5 | 0, i6 | 0);
michael@0 52797 }
michael@0 52798 function b20(i1, i2, i3, i4, i5, i6, i7, i8, i9) {
michael@0 52799 i1 = i1 | 0;
michael@0 52800 i2 = i2 | 0;
michael@0 52801 i3 = i3 | 0;
michael@0 52802 i4 = i4 | 0;
michael@0 52803 i5 = i5 | 0;
michael@0 52804 i6 = i6 | 0;
michael@0 52805 i7 = i7 | 0;
michael@0 52806 i8 = i8 | 0;
michael@0 52807 i9 = i9 | 0;
michael@0 52808 abort(20);
michael@0 52809 return 0;
michael@0 52810 }
michael@0 52811 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN15LocalInfoAdder2D0Ev(i1) {
michael@0 52812 i1 = i1 | 0;
michael@0 52813 __ZdlPv(i1);
michael@0 52814 return;
michael@0 52815 }
michael@0 52816 function __ZN23btDiscreteDynamicsWorld15removeCharacterEP17btActionInterface(i1, i2) {
michael@0 52817 i1 = i1 | 0;
michael@0 52818 i2 = i2 | 0;
michael@0 52819 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 64 >> 2] & 127](i1, i2);
michael@0 52820 return;
michael@0 52821 }
michael@0 52822 function __ZN23btDiscreteDynamicsWorld13removeVehicleEP17btActionInterface(i1, i2) {
michael@0 52823 i1 = i1 | 0;
michael@0 52824 i2 = i2 | 0;
michael@0 52825 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 64 >> 2] & 127](i1, i2);
michael@0 52826 return;
michael@0 52827 }
michael@0 52828 function __ZN23btDiscreteDynamicsWorld12addCharacterEP17btActionInterface(i1, i2) {
michael@0 52829 i1 = i1 | 0;
michael@0 52830 i2 = i2 | 0;
michael@0 52831 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 60 >> 2] & 127](i1, i2);
michael@0 52832 return;
michael@0 52833 }
michael@0 52834 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN9RayTesterD0E_1v(i1) {
michael@0 52835 i1 = i1 | 0;
michael@0 52836 __ZdlPv(i1);
michael@0 52837 return;
michael@0 52838 }
michael@0 52839 function __ZN23btDiscreteDynamicsWorld10addVehicleEP17btActionInterface(i1, i2) {
michael@0 52840 i1 = i1 | 0;
michael@0 52841 i2 = i2 | 0;
michael@0 52842 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 60 >> 2] & 127](i1, i2);
michael@0 52843 return;
michael@0 52844 }
michael@0 52845 function __ZN16btBoxBoxDetectorC2EP10btBoxShapeS1_(i1, i2, i3) {
michael@0 52846 i1 = i1 | 0;
michael@0 52847 i2 = i2 | 0;
michael@0 52848 i3 = i3 | 0;
michael@0 52849 HEAP32[i1 >> 2] = 4528;
michael@0 52850 HEAP32[i1 + 4 >> 2] = i2;
michael@0 52851 HEAP32[i1 + 8 >> 2] = i3;
michael@0 52852 return;
michael@0 52853 }
michael@0 52854 function __ZN6btDbvt8ICollide7ProcessEPK10btDbvtNodef(i1, i2, d3) {
michael@0 52855 i1 = i1 | 0;
michael@0 52856 i2 = i2 | 0;
michael@0 52857 d3 = +d3;
michael@0 52858 FUNCTION_TABLE_vii[HEAP32[(HEAP32[i1 >> 2] | 0) + 12 >> 2] & 127](i1, i2);
michael@0 52859 return;
michael@0 52860 }
michael@0 52861 function __ZN20btCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfo(i1, i2) {
michael@0 52862 i1 = i1 | 0;
michael@0 52863 i2 = i2 | 0;
michael@0 52864 HEAP32[i1 >> 2] = 3896;
michael@0 52865 HEAP32[i1 + 4 >> 2] = HEAP32[i2 >> 2];
michael@0 52866 return;
michael@0 52867 }
michael@0 52868 function dynCall_iiiii(i1, i2, i3, i4, i5) {
michael@0 52869 i1 = i1 | 0;
michael@0 52870 i2 = i2 | 0;
michael@0 52871 i3 = i3 | 0;
michael@0 52872 i4 = i4 | 0;
michael@0 52873 i5 = i5 | 0;
michael@0 52874 return FUNCTION_TABLE_iiiii[i1 & 31](i2 | 0, i3 | 0, i4 | 0, i5 | 0) | 0;
michael@0 52875 }
michael@0 52876 function ___udivdi3(i1, i2, i3, i4) {
michael@0 52877 i1 = i1 | 0;
michael@0 52878 i2 = i2 | 0;
michael@0 52879 i3 = i3 | 0;
michael@0 52880 i4 = i4 | 0;
michael@0 52881 var i5 = 0;
michael@0 52882 i5 = ___udivmoddi4(i1, i2, i3, i4, 0) | 0;
michael@0 52883 return (tempRet0 = tempRet0, i5) | 0;
michael@0 52884 }
michael@0 52885 function __ZZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcherEN18RemovePairCallbackD0Ev(i1) {
michael@0 52886 i1 = i1 | 0;
michael@0 52887 __ZdlPv(i1);
michael@0 52888 return;
michael@0 52889 }
michael@0 52890 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN15LocalInfoAdder2D2Ev(i1) {
michael@0 52891 i1 = i1 | 0;
michael@0 52892 return;
michael@0 52893 }
michael@0 52894 function __Z21btAlignedFreeInternalPv(i1) {
michael@0 52895 i1 = i1 | 0;
michael@0 52896 if ((i1 | 0) == 0) {
michael@0 52897 return;
michael@0 52898 }
michael@0 52899 HEAP32[2998] = (HEAP32[2998] | 0) + 1;
michael@0 52900 FUNCTION_TABLE_vi[HEAP32[2972] & 511](i1);
michael@0 52901 return;
michael@0 52902 }
michael@0 52903 function __ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResultD0Ev(i1) {
michael@0 52904 i1 = i1 | 0;
michael@0 52905 __ZdlPv(i1);
michael@0 52906 return;
michael@0 52907 }
michael@0 52908 function __ZNK16btCollisionShape27getContactBreakingThresholdEf(i1, d2) {
michael@0 52909 i1 = i1 | 0;
michael@0 52910 d2 = +d2;
michael@0 52911 return +(+FUNCTION_TABLE_fi[HEAP32[(HEAP32[i1 >> 2] | 0) + 16 >> 2] & 7](i1) * d2);
michael@0 52912 }
michael@0 52913 function b30(i1, i2, i3, i4, i5, d6, d7, i8, i9) {
michael@0 52914 i1 = i1 | 0;
michael@0 52915 i2 = i2 | 0;
michael@0 52916 i3 = i3 | 0;
michael@0 52917 i4 = i4 | 0;
michael@0 52918 i5 = i5 | 0;
michael@0 52919 d6 = +d6;
michael@0 52920 d7 = +d7;
michael@0 52921 i8 = i8 | 0;
michael@0 52922 i9 = i9 | 0;
michael@0 52923 abort(30);
michael@0 52924 }
michael@0 52925 function __ZThn4_N17DebugDrawcallbackD1Ev(i1) {
michael@0 52926 i1 = i1 | 0;
michael@0 52927 __ZN31btInternalTriangleIndexCallbackD2Ev(i1 - 92 + 92 | 0);
michael@0 52928 __ZN18btTriangleCallbackD2Ev(i1 - 92 + 88 | 0);
michael@0 52929 return;
michael@0 52930 }
michael@0 52931 function __ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN9RayTesterD2E_1v(i1) {
michael@0 52932 i1 = i1 | 0;
michael@0 52933 return;
michael@0 52934 }
michael@0 52935 function __ZN18btConstraintSolver9allSolvedERK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc(i1, i2, i3, i4) {
michael@0 52936 i1 = i1 | 0;
michael@0 52937 i2 = i2 | 0;
michael@0 52938 i3 = i3 | 0;
michael@0 52939 i4 = i4 | 0;
michael@0 52940 return;
michael@0 52941 }
michael@0 52942 function dynCall_viiii(i1, i2, i3, i4, i5) {
michael@0 52943 i1 = i1 | 0;
michael@0 52944 i2 = i2 | 0;
michael@0 52945 i3 = i3 | 0;
michael@0 52946 i4 = i4 | 0;
michael@0 52947 i5 = i5 | 0;
michael@0 52948 FUNCTION_TABLE_viiii[i1 & 127](i2 | 0, i3 | 0, i4 | 0, i5 | 0);
michael@0 52949 }
michael@0 52950 function __ZN16btManifoldResult20setShapeIdentifiersBEii(i1, i2, i3) {
michael@0 52951 i1 = i1 | 0;
michael@0 52952 i2 = i2 | 0;
michael@0 52953 i3 = i3 | 0;
michael@0 52954 HEAP32[i1 + 148 >> 2] = i2;
michael@0 52955 HEAP32[i1 + 156 >> 2] = i3;
michael@0 52956 return;
michael@0 52957 }
michael@0 52958 function __ZN16btManifoldResult20setShapeIdentifiersAEii(i1, i2, i3) {
michael@0 52959 i1 = i1 | 0;
michael@0 52960 i2 = i2 | 0;
michael@0 52961 i3 = i3 | 0;
michael@0 52962 HEAP32[i1 + 144 >> 2] = i2;
michael@0 52963 HEAP32[i1 + 152 >> 2] = i3;
michael@0 52964 return;
michael@0 52965 }
michael@0 52966 function __ZN28btHashedOverlappingPairCache28setInternalGhostPairCallbackEP25btOverlappingPairCallback(i1, i2) {
michael@0 52967 i1 = i1 | 0;
michael@0 52968 i2 = i2 | 0;
michael@0 52969 HEAP32[i1 + 72 >> 2] = i2;
michael@0 52970 return;
michael@0 52971 }
michael@0 52972 function dynCall_iifif(i1, i2, d3, i4, d5) {
michael@0 52973 i1 = i1 | 0;
michael@0 52974 i2 = i2 | 0;
michael@0 52975 d3 = +d3;
michael@0 52976 i4 = i4 | 0;
michael@0 52977 d5 = +d5;
michael@0 52978 return FUNCTION_TABLE_iifif[i1 & 3](i2 | 0, +d3, i4 | 0, +d5) | 0;
michael@0 52979 }
michael@0 52980 function __ZN17btCollisionObject17setCollisionShapeEP16btCollisionShape(i1, i2) {
michael@0 52981 i1 = i1 | 0;
michael@0 52982 i2 = i2 | 0;
michael@0 52983 HEAP32[i1 + 192 >> 2] = i2;
michael@0 52984 HEAP32[i1 + 200 >> 2] = i2;
michael@0 52985 return;
michael@0 52986 }
michael@0 52987 function __ZZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcherEN18RemovePairCallbackD2Ev(i1) {
michael@0 52988 i1 = i1 | 0;
michael@0 52989 return;
michael@0 52990 }
michael@0 52991 function __ZN17DebugDrawcallbackD0Ev(i1) {
michael@0 52992 i1 = i1 | 0;
michael@0 52993 __ZN31btInternalTriangleIndexCallbackD2Ev(i1 + 4 | 0);
michael@0 52994 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 52995 __ZdlPv(i1);
michael@0 52996 return;
michael@0 52997 }
michael@0 52998 function __Z22btAlignedAllocInternalji(i1, i2) {
michael@0 52999 i1 = i1 | 0;
michael@0 53000 i2 = i2 | 0;
michael@0 53001 HEAP32[3e3] = (HEAP32[3e3] | 0) + 1;
michael@0 53002 return FUNCTION_TABLE_iii[HEAP32[2970] & 63](i1, i2) | 0;
michael@0 53003 }
michael@0 53004 function dynCall_viiif(i1, i2, i3, i4, d5) {
michael@0 53005 i1 = i1 | 0;
michael@0 53006 i2 = i2 | 0;
michael@0 53007 i3 = i3 | 0;
michael@0 53008 i4 = i4 | 0;
michael@0 53009 d5 = +d5;
michael@0 53010 FUNCTION_TABLE_viiif[i1 & 15](i2 | 0, i3 | 0, i4 | 0, +d5);
michael@0 53011 }
michael@0 53012 function __ZZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_EN21MyNodeOverlapCallbackD0Ev(i1) {
michael@0 53013 i1 = i1 | 0;
michael@0 53014 __ZdlPv(i1);
michael@0 53015 return;
michael@0 53016 }
michael@0 53017 function dynCall_viifi(i1, i2, i3, d4, i5) {
michael@0 53018 i1 = i1 | 0;
michael@0 53019 i2 = i2 | 0;
michael@0 53020 i3 = i3 | 0;
michael@0 53021 d4 = +d4;
michael@0 53022 i5 = i5 | 0;
michael@0 53023 FUNCTION_TABLE_viifi[i1 & 1](i2 | 0, i3 | 0, +d4, i5 | 0);
michael@0 53024 }
michael@0 53025 function dynCall_vifii(i1, i2, d3, i4, i5) {
michael@0 53026 i1 = i1 | 0;
michael@0 53027 i2 = i2 | 0;
michael@0 53028 d3 = +d3;
michael@0 53029 i4 = i4 | 0;
michael@0 53030 i5 = i5 | 0;
michael@0 53031 FUNCTION_TABLE_vifii[i1 & 1](i2 | 0, +d3, i4 | 0, i5 | 0);
michael@0 53032 }
michael@0 53033 function __ZNK13btSphereShape37localGetSupportingVertexWithoutMarginERK9btVector3(i1, i2, i3) {
michael@0 53034 i1 = i1 | 0;
michael@0 53035 i2 = i2 | 0;
michael@0 53036 i3 = i3 | 0;
michael@0 53037 _memset(i1 | 0, 0, 16);
michael@0 53038 return;
michael@0 53039 }
michael@0 53040 function __ZN28btHashedOverlappingPairCache24setOverlapFilterCallbackEP23btOverlapFilterCallback(i1, i2) {
michael@0 53041 i1 = i1 | 0;
michael@0 53042 i2 = i2 | 0;
michael@0 53043 HEAP32[i1 + 24 >> 2] = i2;
michael@0 53044 return;
michael@0 53045 }
michael@0 53046 function b17(i1, i2, i3, i4, i5, i6, i7, i8) {
michael@0 53047 i1 = i1 | 0;
michael@0 53048 i2 = i2 | 0;
michael@0 53049 i3 = i3 | 0;
michael@0 53050 i4 = i4 | 0;
michael@0 53051 i5 = i5 | 0;
michael@0 53052 i6 = i6 | 0;
michael@0 53053 i7 = i7 | 0;
michael@0 53054 i8 = i8 | 0;
michael@0 53055 abort(17);
michael@0 53056 }
michael@0 53057 function __ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResultD2Ev(i1) {
michael@0 53058 i1 = i1 | 0;
michael@0 53059 return;
michael@0 53060 }
michael@0 53061 function __ZZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcherEN17CleanPairCallbackD0Ev(i1) {
michael@0 53062 i1 = i1 | 0;
michael@0 53063 __ZdlPv(i1);
michael@0 53064 return;
michael@0 53065 }
michael@0 53066 function __ZN21btCollisionDispatcher26getManifoldByIndexInternalEi(i1, i2) {
michael@0 53067 i1 = i1 | 0;
michael@0 53068 i2 = i2 | 0;
michael@0 53069 return HEAP32[(HEAP32[i1 + 20 >> 2] | 0) + (i2 << 2) >> 2] | 0;
michael@0 53070 }
michael@0 53071 function __ZL20btAlignedFreeDefaultPv(i1) {
michael@0 53072 i1 = i1 | 0;
michael@0 53073 if ((i1 | 0) == 0) {
michael@0 53074 return;
michael@0 53075 }
michael@0 53076 FUNCTION_TABLE_vi[HEAP32[2968] & 511](HEAP32[i1 - 4 >> 2] | 0);
michael@0 53077 return;
michael@0 53078 }
michael@0 53079 function __ZN23btPolyhedralConvexShapeC2Ev(i1) {
michael@0 53080 i1 = i1 | 0;
michael@0 53081 __ZN21btConvexInternalShapeC2Ev(i1 | 0);
michael@0 53082 HEAP32[i1 >> 2] = 3136;
michael@0 53083 HEAP32[i1 + 52 >> 2] = 0;
michael@0 53084 return;
michael@0 53085 }
michael@0 53086 function __ZZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_EN21MyNodeOverlapCallbackD0Ev(i1) {
michael@0 53087 i1 = i1 | 0;
michael@0 53088 __ZdlPv(i1);
michael@0 53089 return;
michael@0 53090 }
michael@0 53091 function __ZN11btUnionFindC2Ev(i1) {
michael@0 53092 i1 = i1 | 0;
michael@0 53093 HEAP8[i1 + 16 | 0] = 1;
michael@0 53094 HEAP32[i1 + 12 >> 2] = 0;
michael@0 53095 HEAP32[i1 + 4 >> 2] = 0;
michael@0 53096 HEAP32[i1 + 8 >> 2] = 0;
michael@0 53097 return;
michael@0 53098 }
michael@0 53099 function dynCall_iiii(i1, i2, i3, i4) {
michael@0 53100 i1 = i1 | 0;
michael@0 53101 i2 = i2 | 0;
michael@0 53102 i3 = i3 | 0;
michael@0 53103 i4 = i4 | 0;
michael@0 53104 return FUNCTION_TABLE_iiii[i1 & 31](i2 | 0, i3 | 0, i4 | 0) | 0;
michael@0 53105 }
michael@0 53106 function b0(i1, i2, i3, i4, i5, i6, i7) {
michael@0 53107 i1 = i1 | 0;
michael@0 53108 i2 = i2 | 0;
michael@0 53109 i3 = i3 | 0;
michael@0 53110 i4 = i4 | 0;
michael@0 53111 i5 = i5 | 0;
michael@0 53112 i6 = i6 | 0;
michael@0 53113 i7 = i7 | 0;
michael@0 53114 abort(0);
michael@0 53115 return 0;
michael@0 53116 }
michael@0 53117 function __ZNK23btDiscreteDynamicsWorld13getConstraintEi(i1, i2) {
michael@0 53118 i1 = i1 | 0;
michael@0 53119 i2 = i2 | 0;
michael@0 53120 return HEAP32[(HEAP32[i1 + 192 >> 2] | 0) + (i2 << 2) >> 2] | 0;
michael@0 53121 }
michael@0 53122 function __ZN17DebugDrawcallbackD1Ev(i1) {
michael@0 53123 i1 = i1 | 0;
michael@0 53124 __ZN31btInternalTriangleIndexCallbackD2Ev(i1 + 4 | 0);
michael@0 53125 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 53126 return;
michael@0 53127 }
michael@0 53128 function __ZN23btDiscreteDynamicsWorld13getConstraintEi(i1, i2) {
michael@0 53129 i1 = i1 | 0;
michael@0 53130 i2 = i2 | 0;
michael@0 53131 return HEAP32[(HEAP32[i1 + 192 >> 2] | 0) + (i2 << 2) >> 2] | 0;
michael@0 53132 }
michael@0 53133 function dynCall_fiii(i1, i2, i3, i4) {
michael@0 53134 i1 = i1 | 0;
michael@0 53135 i2 = i2 | 0;
michael@0 53136 i3 = i3 | 0;
michael@0 53137 i4 = i4 | 0;
michael@0 53138 return +FUNCTION_TABLE_fiii[i1 & 15](i2 | 0, i3 | 0, i4 | 0);
michael@0 53139 }
michael@0 53140 function __ZZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_EN21MyNodeOverlapCallbackD2Ev(i1) {
michael@0 53141 i1 = i1 | 0;
michael@0 53142 return;
michael@0 53143 }
michael@0 53144 function __ZZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcherEN17CleanPairCallbackD2Ev(i1) {
michael@0 53145 i1 = i1 | 0;
michael@0 53146 return;
michael@0 53147 }
michael@0 53148 function dynCall_iiif(i1, i2, i3, d4) {
michael@0 53149 i1 = i1 | 0;
michael@0 53150 i2 = i2 | 0;
michael@0 53151 i3 = i3 | 0;
michael@0 53152 d4 = +d4;
michael@0 53153 return FUNCTION_TABLE_iiif[i1 & 7](i2 | 0, i3 | 0, +d4) | 0;
michael@0 53154 }
michael@0 53155 function __ZNK15btTriangleShape21calculateLocalInertiaEfR9btVector3(i1, d2, i3) {
michael@0 53156 i1 = i1 | 0;
michael@0 53157 d2 = +d2;
michael@0 53158 i3 = i3 | 0;
michael@0 53159 _memset(i3 | 0, 0, 16);
michael@0 53160 return;
michael@0 53161 }
michael@0 53162 function stackAlloc(i1) {
michael@0 53163 i1 = i1 | 0;
michael@0 53164 var i2 = 0;
michael@0 53165 i2 = STACKTOP;
michael@0 53166 STACKTOP = STACKTOP + i1 | 0;
michael@0 53167 STACKTOP = STACKTOP + 7 >> 3 << 3;
michael@0 53168 return i2 | 0;
michael@0 53169 }
michael@0 53170 function dynCall_viii(i1, i2, i3, i4) {
michael@0 53171 i1 = i1 | 0;
michael@0 53172 i2 = i2 | 0;
michael@0 53173 i3 = i3 | 0;
michael@0 53174 i4 = i4 | 0;
michael@0 53175 FUNCTION_TABLE_viii[i1 & 127](i2 | 0, i3 | 0, i4 | 0);
michael@0 53176 }
michael@0 53177 function __ZN16btEmptyAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE(i1, i2) {
michael@0 53178 i1 = i1 | 0;
michael@0 53179 i2 = i2 | 0;
michael@0 53180 return;
michael@0 53181 }
michael@0 53182 function __ZZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_EN21MyNodeOverlapCallbackD2Ev(i1) {
michael@0 53183 i1 = i1 | 0;
michael@0 53184 return;
michael@0 53185 }
michael@0 53186 function __ZNK21btConvexInternalShape32getPreferredPenetrationDirectionEiR9btVector3(i1, i2, i3) {
michael@0 53187 i1 = i1 | 0;
michael@0 53188 i2 = i2 | 0;
michael@0 53189 i3 = i3 | 0;
michael@0 53190 return;
michael@0 53191 }
michael@0 53192 function __ZN35btSequentialImpulseConstraintSolverD0Ev(i1) {
michael@0 53193 i1 = i1 | 0;
michael@0 53194 __ZN35btSequentialImpulseConstraintSolverD2Ev(i1);
michael@0 53195 __ZdlPv(i1);
michael@0 53196 return;
michael@0 53197 }
michael@0 53198 function b22(i1, i2, i3, i4, i5, i6) {
michael@0 53199 i1 = i1 | 0;
michael@0 53200 i2 = i2 | 0;
michael@0 53201 i3 = i3 | 0;
michael@0 53202 i4 = i4 | 0;
michael@0 53203 i5 = i5 | 0;
michael@0 53204 i6 = i6 | 0;
michael@0 53205 abort(22);
michael@0 53206 return 0;
michael@0 53207 }
michael@0 53208 function dynCall_vifi(i1, i2, d3, i4) {
michael@0 53209 i1 = i1 | 0;
michael@0 53210 i2 = i2 | 0;
michael@0 53211 d3 = +d3;
michael@0 53212 i4 = i4 | 0;
michael@0 53213 FUNCTION_TABLE_vifi[i1 & 15](i2 | 0, +d3, i4 | 0);
michael@0 53214 }
michael@0 53215 function b38(i1, i2, i3, d4, i5, i6) {
michael@0 53216 i1 = i1 | 0;
michael@0 53217 i2 = i2 | 0;
michael@0 53218 i3 = i3 | 0;
michael@0 53219 d4 = +d4;
michael@0 53220 i5 = i5 | 0;
michael@0 53221 i6 = i6 | 0;
michael@0 53222 abort(38);
michael@0 53223 return 0.0;
michael@0 53224 }
michael@0 53225 function dynCall_viif(i1, i2, i3, d4) {
michael@0 53226 i1 = i1 | 0;
michael@0 53227 i2 = i2 | 0;
michael@0 53228 i3 = i3 | 0;
michael@0 53229 d4 = +d4;
michael@0 53230 FUNCTION_TABLE_viif[i1 & 3](i2 | 0, i3 | 0, +d4);
michael@0 53231 }
michael@0 53232 function __ZN7btClockD2Ev(i1) {
michael@0 53233 i1 = i1 | 0;
michael@0 53234 var i2 = 0;
michael@0 53235 i2 = HEAP32[i1 >> 2] | 0;
michael@0 53236 if ((i2 | 0) == 0) {
michael@0 53237 return;
michael@0 53238 }
michael@0 53239 __ZdlPv(i2);
michael@0 53240 return;
michael@0 53241 }
michael@0 53242 function __ZN15btTriangleShapeD0Ev(i1) {
michael@0 53243 i1 = i1 | 0;
michael@0 53244 __ZN23btPolyhedralConvexShapeD2Ev(i1 | 0);
michael@0 53245 __Z21btAlignedFreeInternalPv(i1);
michael@0 53246 return;
michael@0 53247 }
michael@0 53248 function __ZN31btDefaultCollisionConfigurationD0Ev(i1) {
michael@0 53249 i1 = i1 | 0;
michael@0 53250 __ZN31btDefaultCollisionConfigurationD2Ev(i1);
michael@0 53251 __ZdlPv(i1);
michael@0 53252 return;
michael@0 53253 }
michael@0 53254 function __ZN13btConvexShapeC2Ev(i1) {
michael@0 53255 i1 = i1 | 0;
michael@0 53256 HEAP32[i1 + 4 >> 2] = 35;
michael@0 53257 HEAP32[i1 + 8 >> 2] = 0;
michael@0 53258 HEAP32[i1 >> 2] = 4832;
michael@0 53259 return;
michael@0 53260 }
michael@0 53261 function __ZN21btConvexInternalShapeD0Ev(i1) {
michael@0 53262 i1 = i1 | 0;
michael@0 53263 __ZN13btConvexShapeD2Ev(i1 | 0);
michael@0 53264 __Z21btAlignedFreeInternalPv(i1);
michael@0 53265 return;
michael@0 53266 }
michael@0 53267 function __ZN16btCollisionWorld14setDebugDrawerEP12btIDebugDraw(i1, i2) {
michael@0 53268 i1 = i1 | 0;
michael@0 53269 i2 = i2 | 0;
michael@0 53270 HEAP32[i1 + 80 >> 2] = i2;
michael@0 53271 return;
michael@0 53272 }
michael@0 53273 function __ZNK23btGeneric6DofConstraint8getAngleEi(i1, i2) {
michael@0 53274 i1 = i1 | 0;
michael@0 53275 i2 = i2 | 0;
michael@0 53276 return +(+HEAPF32[i1 + 1184 + (i2 << 2) >> 2]);
michael@0 53277 }
michael@0 53278 function __ZN10btBoxShapeD0Ev(i1) {
michael@0 53279 i1 = i1 | 0;
michael@0 53280 __ZN23btPolyhedralConvexShapeD2Ev(i1 | 0);
michael@0 53281 __Z21btAlignedFreeInternalPv(i1);
michael@0 53282 return;
michael@0 53283 }
michael@0 53284 function __ZN28btHashedOverlappingPairCacheD0Ev(i1) {
michael@0 53285 i1 = i1 | 0;
michael@0 53286 __ZN28btHashedOverlappingPairCacheD2Ev(i1);
michael@0 53287 __ZdlPv(i1);
michael@0 53288 return;
michael@0 53289 }
michael@0 53290 function __ZN28btCompoundCollisionAlgorithmD0Ev(i1) {
michael@0 53291 i1 = i1 | 0;
michael@0 53292 __ZN28btCompoundCollisionAlgorithmD2Ev(i1);
michael@0 53293 __ZdlPv(i1);
michael@0 53294 return;
michael@0 53295 }
michael@0 53296 function b19(i1, i2, i3, i4, i5, i6) {
michael@0 53297 i1 = i1 | 0;
michael@0 53298 i2 = i2 | 0;
michael@0 53299 i3 = i3 | 0;
michael@0 53300 i4 = i4 | 0;
michael@0 53301 i5 = i5 | 0;
michael@0 53302 i6 = i6 | 0;
michael@0 53303 abort(19);
michael@0 53304 }
michael@0 53305 function dynCall_iii(i1, i2, i3) {
michael@0 53306 i1 = i1 | 0;
michael@0 53307 i2 = i2 | 0;
michael@0 53308 i3 = i3 | 0;
michael@0 53309 return FUNCTION_TABLE_iii[i1 & 63](i2 | 0, i3 | 0) | 0;
michael@0 53310 }
michael@0 53311 function __ZN13btSphereShapeD0Ev(i1) {
michael@0 53312 i1 = i1 | 0;
michael@0 53313 __ZN13btConvexShapeD2Ev(i1 | 0);
michael@0 53314 __Z21btAlignedFreeInternalPv(i1);
michael@0 53315 return;
michael@0 53316 }
michael@0 53317 function b6(i1, i2, i3, d4, i5, i6) {
michael@0 53318 i1 = i1 | 0;
michael@0 53319 i2 = i2 | 0;
michael@0 53320 i3 = i3 | 0;
michael@0 53321 d4 = +d4;
michael@0 53322 i5 = i5 | 0;
michael@0 53323 i6 = i6 | 0;
michael@0 53324 abort(6);
michael@0 53325 }
michael@0 53326 function b24(i1, i2, i3, i4, i5) {
michael@0 53327 i1 = i1 | 0;
michael@0 53328 i2 = i2 | 0;
michael@0 53329 i3 = i3 | 0;
michael@0 53330 i4 = i4 | 0;
michael@0 53331 i5 = i5 | 0;
michael@0 53332 abort(24);
michael@0 53333 return 0.0;
michael@0 53334 }
michael@0 53335 function __ZN31btDefaultCollisionConfiguration25getPersistentManifoldPoolEv(i1) {
michael@0 53336 i1 = i1 | 0;
michael@0 53337 return HEAP32[i1 + 16 >> 2] | 0;
michael@0 53338 }
michael@0 53339 function __ZN31btDefaultCollisionConfiguration25getCollisionAlgorithmPoolEv(i1) {
michael@0 53340 i1 = i1 | 0;
michael@0 53341 return HEAP32[i1 + 24 >> 2] | 0;
michael@0 53342 }
michael@0 53343 function __ZN28btTriangleConvexcastCallbackD0Ev(i1) {
michael@0 53344 i1 = i1 | 0;
michael@0 53345 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 53346 __ZdlPv(i1);
michael@0 53347 return;
michael@0 53348 }
michael@0 53349 function __ZN25btSimulationIslandManagerD0Ev(i1) {
michael@0 53350 i1 = i1 | 0;
michael@0 53351 __ZN25btSimulationIslandManagerD2Ev(i1);
michael@0 53352 __ZdlPv(i1);
michael@0 53353 return;
michael@0 53354 }
michael@0 53355 function b21(i1, d2, d3, i4, i5, i6) {
michael@0 53356 i1 = i1 | 0;
michael@0 53357 d2 = +d2;
michael@0 53358 d3 = +d3;
michael@0 53359 i4 = i4 | 0;
michael@0 53360 i5 = i5 | 0;
michael@0 53361 i6 = i6 | 0;
michael@0 53362 abort(21);
michael@0 53363 }
michael@0 53364 function __ZNK28btHashedOverlappingPairCache26getOverlappingPairArrayPtrEv(i1) {
michael@0 53365 i1 = i1 | 0;
michael@0 53366 return HEAP32[i1 + 16 >> 2] | 0;
michael@0 53367 }
michael@0 53368 function _strlen(i1) {
michael@0 53369 i1 = i1 | 0;
michael@0 53370 var i2 = 0;
michael@0 53371 i2 = i1;
michael@0 53372 while (HEAP8[i2] | 0) {
michael@0 53373 i2 = i2 + 1 | 0;
michael@0 53374 }
michael@0 53375 return i2 - i1 | 0;
michael@0 53376 }
michael@0 53377 function __ZN28btHashedOverlappingPairCache26getOverlappingPairArrayPtrEv(i1) {
michael@0 53378 i1 = i1 | 0;
michael@0 53379 return HEAP32[i1 + 16 >> 2] | 0;
michael@0 53380 }
michael@0 53381 function b13(i1, i2, d3, i4, i5) {
michael@0 53382 i1 = i1 | 0;
michael@0 53383 i2 = i2 | 0;
michael@0 53384 d3 = +d3;
michael@0 53385 i4 = i4 | 0;
michael@0 53386 i5 = i5 | 0;
michael@0 53387 abort(13);
michael@0 53388 return 0.0;
michael@0 53389 }
michael@0 53390 function __ZN25btTriangleRaycastCallbackD0Ev(i1) {
michael@0 53391 i1 = i1 | 0;
michael@0 53392 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 53393 __ZdlPv(i1);
michael@0 53394 return;
michael@0 53395 }
michael@0 53396 function __ZN10__cxxabiv121__vmi_class_type_infoD0Ev(i1) {
michael@0 53397 i1 = i1 | 0;
michael@0 53398 __ZNSt9type_infoD2Ev(i1 | 0);
michael@0 53399 __ZdlPv(i1);
michael@0 53400 return;
michael@0 53401 }
michael@0 53402 function __ZN23btDiscreteDynamicsWorldD0Ev(i1) {
michael@0 53403 i1 = i1 | 0;
michael@0 53404 __ZN23btDiscreteDynamicsWorldD2Ev(i1);
michael@0 53405 __ZdlPv(i1);
michael@0 53406 return;
michael@0 53407 }
michael@0 53408 function __ZN10__cxxabiv120__si_class_type_infoD0Ev(i1) {
michael@0 53409 i1 = i1 | 0;
michael@0 53410 __ZNSt9type_infoD2Ev(i1 | 0);
michael@0 53411 __ZdlPv(i1);
michael@0 53412 return;
michael@0 53413 }
michael@0 53414 function setThrew(i1, i2) {
michael@0 53415 i1 = i1 | 0;
michael@0 53416 i2 = i2 | 0;
michael@0 53417 if ((__THREW__ | 0) == 0) {
michael@0 53418 __THREW__ = i1;
michael@0 53419 threwValue = i2;
michael@0 53420 }
michael@0 53421 }
michael@0 53422 function __ZNK20btPersistentManifold27getContactBreakingThresholdEv(i1) {
michael@0 53423 i1 = i1 | 0;
michael@0 53424 return +(+HEAPF32[i1 + 1120 >> 2]);
michael@0 53425 }
michael@0 53426 function dynCall_vii(i1, i2, i3) {
michael@0 53427 i1 = i1 | 0;
michael@0 53428 i2 = i2 | 0;
michael@0 53429 i3 = i3 | 0;
michael@0 53430 FUNCTION_TABLE_vii[i1 & 127](i2 | 0, i3 | 0);
michael@0 53431 }
michael@0 53432 function dynCall_fif(i1, i2, d3) {
michael@0 53433 i1 = i1 | 0;
michael@0 53434 i2 = i2 | 0;
michael@0 53435 d3 = +d3;
michael@0 53436 return +FUNCTION_TABLE_fif[i1 & 3](i2 | 0, +d3);
michael@0 53437 }
michael@0 53438 function __ZNK28btHashedOverlappingPairCache22getNumOverlappingPairsEv(i1) {
michael@0 53439 i1 = i1 | 0;
michael@0 53440 return HEAP32[i1 + 8 >> 2] | 0;
michael@0 53441 }
michael@0 53442 function __ZN27btContinuousConvexCollisionD0Ev(i1) {
michael@0 53443 i1 = i1 | 0;
michael@0 53444 __ZN12btConvexCastD2Ev(i1 | 0);
michael@0 53445 __ZdlPv(i1);
michael@0 53446 return;
michael@0 53447 }
michael@0 53448 function __ZN12btConvexCast10CastResult13reportFailureEii(i1, i2, i3) {
michael@0 53449 i1 = i1 | 0;
michael@0 53450 i2 = i2 | 0;
michael@0 53451 i3 = i3 | 0;
michael@0 53452 return;
michael@0 53453 }
michael@0 53454 function __ZN10__cxxabiv117__class_type_infoD0Ev(i1) {
michael@0 53455 i1 = i1 | 0;
michael@0 53456 __ZNSt9type_infoD2Ev(i1 | 0);
michael@0 53457 __ZdlPv(i1);
michael@0 53458 return;
michael@0 53459 }
michael@0 53460 function __ZNK13btSphereShape9getMarginEv(i1) {
michael@0 53461 i1 = i1 | 0;
michael@0 53462 return +(+HEAPF32[i1 + 28 >> 2] * +HEAPF32[i1 + 12 >> 2]);
michael@0 53463 }
michael@0 53464 function __ZN21btConvexInternalShape9setMarginEf(i1, d2) {
michael@0 53465 i1 = i1 | 0;
michael@0 53466 d2 = +d2;
michael@0 53467 HEAPF32[i1 + 44 >> 2] = d2;
michael@0 53468 return;
michael@0 53469 }
michael@0 53470 function __ZN16btPointCollector20setShapeIdentifiersBEii(i1, i2, i3) {
michael@0 53471 i1 = i1 | 0;
michael@0 53472 i2 = i2 | 0;
michael@0 53473 i3 = i3 | 0;
michael@0 53474 return;
michael@0 53475 }
michael@0 53476 function __ZN16btPointCollector20setShapeIdentifiersAEii(i1, i2, i3) {
michael@0 53477 i1 = i1 | 0;
michael@0 53478 i2 = i2 | 0;
michael@0 53479 i3 = i3 | 0;
michael@0 53480 return;
michael@0 53481 }
michael@0 53482 function __ZN6btDbvt8ICollide7ProcessEPK10btDbvtNodeS3_(i1, i2, i3) {
michael@0 53483 i1 = i1 | 0;
michael@0 53484 i2 = i2 | 0;
michael@0 53485 i3 = i3 | 0;
michael@0 53486 return;
michael@0 53487 }
michael@0 53488 function __ZN31btDefaultCollisionConfiguration17getStackAllocatorEv(i1) {
michael@0 53489 i1 = i1 | 0;
michael@0 53490 return HEAP32[i1 + 8 >> 2] | 0;
michael@0 53491 }
michael@0 53492 function __ZN31btDefaultCollisionConfiguration16getSimplexSolverEv(i1) {
michael@0 53493 i1 = i1 | 0;
michael@0 53494 return HEAP32[i1 + 32 >> 2] | 0;
michael@0 53495 }
michael@0 53496 function __ZN21btCollisionDispatcher26getInternalManifoldPointerEv(i1) {
michael@0 53497 i1 = i1 | 0;
michael@0 53498 return HEAP32[i1 + 20 >> 2] | 0;
michael@0 53499 }
michael@0 53500 function __ZNK21btCollisionDispatcher23getInternalManifoldPoolEv(i1) {
michael@0 53501 i1 = i1 | 0;
michael@0 53502 return HEAP32[i1 + 196 >> 2] | 0;
michael@0 53503 }
michael@0 53504 function __ZN12btConvexCast10CastResult15drawCoordSystemERK11btTransform(i1, i2) {
michael@0 53505 i1 = i1 | 0;
michael@0 53506 i2 = i2 | 0;
michael@0 53507 return;
michael@0 53508 }
michael@0 53509 function __ZN21btCollisionDispatcher23getInternalManifoldPoolEv(i1) {
michael@0 53510 i1 = i1 | 0;
michael@0 53511 return HEAP32[i1 + 196 >> 2] | 0;
michael@0 53512 }
michael@0 53513 function __ZN22btSubsimplexConvexCastD0Ev(i1) {
michael@0 53514 i1 = i1 | 0;
michael@0 53515 __ZN12btConvexCastD2Ev(i1 | 0);
michael@0 53516 __ZdlPv(i1);
michael@0 53517 return;
michael@0 53518 }
michael@0 53519 function dynCall_vif(i1, i2, d3) {
michael@0 53520 i1 = i1 | 0;
michael@0 53521 i2 = i2 | 0;
michael@0 53522 d3 = +d3;
michael@0 53523 FUNCTION_TABLE_vif[i1 & 31](i2 | 0, +d3);
michael@0 53524 }
michael@0 53525 function __ZN23btDiscreteDynamicsWorld19getConstraintSolverEv(i1) {
michael@0 53526 i1 = i1 | 0;
michael@0 53527 return HEAP32[i1 + 172 >> 2] | 0;
michael@0 53528 }
michael@0 53529 function __ZNK23btDiscreteDynamicsWorld17getNumConstraintsEv(i1) {
michael@0 53530 i1 = i1 | 0;
michael@0 53531 return HEAP32[i1 + 184 >> 2] | 0;
michael@0 53532 }
michael@0 53533 function __ZN35btSequentialImpulseConstraintSolver5resetEv(i1) {
michael@0 53534 i1 = i1 | 0;
michael@0 53535 HEAP32[i1 + 124 >> 2] = 0;
michael@0 53536 return;
michael@0 53537 }
michael@0 53538 function __ZN28btTriangleConvexcastCallbackD1Ev(i1) {
michael@0 53539 i1 = i1 | 0;
michael@0 53540 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 53541 return;
michael@0 53542 }
michael@0 53543 function __ZN18btConvexPolyhedronD0Ev(i1) {
michael@0 53544 i1 = i1 | 0;
michael@0 53545 __ZN18btConvexPolyhedronD2Ev(i1);
michael@0 53546 __ZdlPv(i1);
michael@0 53547 return;
michael@0 53548 }
michael@0 53549 function __ZN18btConstraintSolver12prepareSolveEii(i1, i2, i3) {
michael@0 53550 i1 = i1 | 0;
michael@0 53551 i2 = i2 | 0;
michael@0 53552 i3 = i3 | 0;
michael@0 53553 return;
michael@0 53554 }
michael@0 53555 function b3(i1, i2, i3, i4, i5) {
michael@0 53556 i1 = i1 | 0;
michael@0 53557 i2 = i2 | 0;
michael@0 53558 i3 = i3 | 0;
michael@0 53559 i4 = i4 | 0;
michael@0 53560 i5 = i5 | 0;
michael@0 53561 abort(3);
michael@0 53562 }
michael@0 53563 function __ZN33btConvexConcaveCollisionAlgorithm17SwappedCreateFuncD0Ev(i1) {
michael@0 53564 i1 = i1 | 0;
michael@0 53565 __ZdlPv(i1);
michael@0 53566 return;
michael@0 53567 }
michael@0 53568 function __ZNK16btDbvtBroadphase23getOverlappingPairCacheEv(i1) {
michael@0 53569 i1 = i1 | 0;
michael@0 53570 return HEAP32[i1 + 96 >> 2] | 0;
michael@0 53571 }
michael@0 53572 function __ZN13btSphereShape9setMarginEf(i1, d2) {
michael@0 53573 i1 = i1 | 0;
michael@0 53574 d2 = +d2;
michael@0 53575 HEAPF32[i1 + 44 >> 2] = d2;
michael@0 53576 return;
michael@0 53577 }
michael@0 53578 function __ZN25btTriangleRaycastCallbackD1Ev(i1) {
michael@0 53579 i1 = i1 | 0;
michael@0 53580 __ZN18btTriangleCallbackD2Ev(i1 | 0);
michael@0 53581 return;
michael@0 53582 }
michael@0 53583 function __ZN16btDbvtBroadphase23getOverlappingPairCacheEv(i1) {
michael@0 53584 i1 = i1 | 0;
michael@0 53585 return HEAP32[i1 + 96 >> 2] | 0;
michael@0 53586 }
michael@0 53587 function b7(i1, d2, i3, i4, i5) {
michael@0 53588 i1 = i1 | 0;
michael@0 53589 d2 = +d2;
michael@0 53590 i3 = i3 | 0;
michael@0 53591 i4 = i4 | 0;
michael@0 53592 i5 = i5 | 0;
michael@0 53593 abort(7);
michael@0 53594 }
michael@0 53595 function b2(i1, i2, d3, i4, i5) {
michael@0 53596 i1 = i1 | 0;
michael@0 53597 i2 = i2 | 0;
michael@0 53598 d3 = +d3;
michael@0 53599 i4 = i4 | 0;
michael@0 53600 i5 = i5 | 0;
michael@0 53601 abort(2);
michael@0 53602 }
michael@0 53603 function __ZN17btCollisionObject24checkCollideWithOverrideEPS_(i1, i2) {
michael@0 53604 i1 = i1 | 0;
michael@0 53605 i2 = i2 | 0;
michael@0 53606 return 1;
michael@0 53607 }
michael@0 53608 function __ZN16btCollisionWorldD0Ev(i1) {
michael@0 53609 i1 = i1 | 0;
michael@0 53610 __ZN16btCollisionWorldD2Ev(i1);
michael@0 53611 __ZdlPv(i1);
michael@0 53612 return;
michael@0 53613 }
michael@0 53614 function __ZNK21btCollisionDispatcher15getNumManifoldsEv(i1) {
michael@0 53615 i1 = i1 | 0;
michael@0 53616 return HEAP32[i1 + 12 >> 2] | 0;
michael@0 53617 }
michael@0 53618 function __ZN28btHashedOverlappingPairCache23getOverlappingPairArrayEv(i1) {
michael@0 53619 i1 = i1 | 0;
michael@0 53620 return i1 + 4 | 0;
michael@0 53621 }
michael@0 53622 function __ZN15btGjkConvexCastD0Ev(i1) {
michael@0 53623 i1 = i1 | 0;
michael@0 53624 __ZN12btConvexCastD2Ev(i1 | 0);
michael@0 53625 __ZdlPv(i1);
michael@0 53626 return;
michael@0 53627 }
michael@0 53628 function __ZN15CProfileManager23Increment_Frame_CounterEv() {
michael@0 53629 HEAP32[3572] = (HEAP32[3572] | 0) + 1;
michael@0 53630 return;
michael@0 53631 }
michael@0 53632 function b32(i1, i2, i3, i4) {
michael@0 53633 i1 = i1 | 0;
michael@0 53634 i2 = i2 | 0;
michael@0 53635 i3 = i3 | 0;
michael@0 53636 i4 = i4 | 0;
michael@0 53637 abort(32);
michael@0 53638 return 0;
michael@0 53639 }
michael@0 53640 function __ZN28btCompoundCollisionAlgorithm17SwappedCreateFuncD0Ev(i1) {
michael@0 53641 i1 = i1 | 0;
michael@0 53642 __ZdlPv(i1);
michael@0 53643 return;
michael@0 53644 }
michael@0 53645 function __ZNK21btConvexInternalShape36getNumPreferredPenetrationDirectionsEv(i1) {
michael@0 53646 i1 = i1 | 0;
michael@0 53647 return 0;
michael@0 53648 }
michael@0 53649 function __ZN34btSphereTriangleCollisionAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53650 i1 = i1 | 0;
michael@0 53651 __ZdlPv(i1);
michael@0 53652 return;
michael@0 53653 }
michael@0 53654 function __ZN27btContinuousConvexCollisionD1Ev(i1) {
michael@0 53655 i1 = i1 | 0;
michael@0 53656 __ZN12btConvexCastD2Ev(i1 | 0);
michael@0 53657 return;
michael@0 53658 }
michael@0 53659 function __ZN33btConvexConcaveCollisionAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53660 i1 = i1 | 0;
michael@0 53661 __ZdlPv(i1);
michael@0 53662 return;
michael@0 53663 }
michael@0 53664 function __ZN16btCollisionWorld27ClosestConvexResultCallbackD0Ev(i1) {
michael@0 53665 i1 = i1 | 0;
michael@0 53666 __ZdlPv(i1);
michael@0 53667 return;
michael@0 53668 }
michael@0 53669 function __ZN15btTriangleShapeD1Ev(i1) {
michael@0 53670 i1 = i1 | 0;
michael@0 53671 __ZN23btPolyhedralConvexShapeD2Ev(i1 | 0);
michael@0 53672 return;
michael@0 53673 }
michael@0 53674 function __ZN10__cxxabiv116__shim_type_infoD2Ev(i1) {
michael@0 53675 i1 = i1 | 0;
michael@0 53676 __ZNSt9type_infoD2Ev(i1 | 0);
michael@0 53677 return;
michael@0 53678 }
michael@0 53679 function dynCall_ii(i1, i2) {
michael@0 53680 i1 = i1 | 0;
michael@0 53681 i2 = i2 | 0;
michael@0 53682 return FUNCTION_TABLE_ii[i1 & 127](i2 | 0) | 0;
michael@0 53683 }
michael@0 53684 function __ZN32btSphereSphereCollisionAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53685 i1 = i1 | 0;
michael@0 53686 __ZdlPv(i1);
michael@0 53687 return;
michael@0 53688 }
michael@0 53689 function __ZN31btConvexPlaneCollisionAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53690 i1 = i1 | 0;
michael@0 53691 __ZdlPv(i1);
michael@0 53692 return;
michael@0 53693 }
michael@0 53694 function __ZNK21btConvexInternalShape9getMarginEv(i1) {
michael@0 53695 i1 = i1 | 0;
michael@0 53696 return +(+HEAPF32[i1 + 44 >> 2]);
michael@0 53697 }
michael@0 53698 function b31(i1, d2, i3, d4) {
michael@0 53699 i1 = i1 | 0;
michael@0 53700 d2 = +d2;
michael@0 53701 i3 = i3 | 0;
michael@0 53702 d4 = +d4;
michael@0 53703 abort(31);
michael@0 53704 return 0;
michael@0 53705 }
michael@0 53706 function __ZN6btDbvt8ICollide9AllLeavesEPK10btDbvtNode(i1, i2) {
michael@0 53707 i1 = i1 | 0;
michael@0 53708 i2 = i2 | 0;
michael@0 53709 return 1;
michael@0 53710 }
michael@0 53711 function __ZN22btSubsimplexConvexCastD1Ev(i1) {
michael@0 53712 i1 = i1 | 0;
michael@0 53713 __ZN12btConvexCastD2Ev(i1 | 0);
michael@0 53714 return;
michael@0 53715 }
michael@0 53716 function __ZN21btConvexInternalShapeD1Ev(i1) {
michael@0 53717 i1 = i1 | 0;
michael@0 53718 __ZN13btConvexShapeD2Ev(i1 | 0);
michael@0 53719 return;
michael@0 53720 }
michael@0 53721 function __ZN16btCollisionWorld14getDebugDrawerEv(i1) {
michael@0 53722 i1 = i1 | 0;
michael@0 53723 return HEAP32[i1 + 80 >> 2] | 0;
michael@0 53724 }
michael@0 53725 function __ZNK15btTriangleShape36getNumPreferredPenetrationDirectionsEv(i1) {
michael@0 53726 i1 = i1 | 0;
michael@0 53727 return 2;
michael@0 53728 }
michael@0 53729 function __ZN28btCompoundCollisionAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53730 i1 = i1 | 0;
michael@0 53731 __ZdlPv(i1);
michael@0 53732 return;
michael@0 53733 }
michael@0 53734 function __ZN10btBoxShapeD1Ev(i1) {
michael@0 53735 i1 = i1 | 0;
michael@0 53736 __ZN23btPolyhedralConvexShapeD2Ev(i1 | 0);
michael@0 53737 return;
michael@0 53738 }
michael@0 53739 function dynCall_fi(i1, i2) {
michael@0 53740 i1 = i1 | 0;
michael@0 53741 i2 = i2 | 0;
michael@0 53742 return +FUNCTION_TABLE_fi[i1 & 7](i2 | 0);
michael@0 53743 }
michael@0 53744 function __ZNK21btConvexInternalShape28calculateSerializeBufferSizeEv(i1) {
michael@0 53745 i1 = i1 | 0;
michael@0 53746 return 52;
michael@0 53747 }
michael@0 53748 function __ZN6btDbvt8ICollide7DescentEPK10btDbvtNode(i1, i2) {
michael@0 53749 i1 = i1 | 0;
michael@0 53750 i2 = i2 | 0;
michael@0 53751 return 1;
michael@0 53752 }
michael@0 53753 function __ZN33btConvexConcaveCollisionAlgorithm17SwappedCreateFuncD1Ev(i1) {
michael@0 53754 i1 = i1 | 0;
michael@0 53755 return;
michael@0 53756 }
michael@0 53757 function __ZN26btBoxBoxCollisionAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53758 i1 = i1 | 0;
michael@0 53759 __ZdlPv(i1);
michael@0 53760 return;
michael@0 53761 }
michael@0 53762 function __ZN23btDiscreteDynamicsWorld11setNumTasksEi(i1, i2) {
michael@0 53763 i1 = i1 | 0;
michael@0 53764 i2 = i2 | 0;
michael@0 53765 return;
michael@0 53766 }
michael@0 53767 function __ZN17btCollisionObjectD0Ev(i1) {
michael@0 53768 i1 = i1 | 0;
michael@0 53769 __Z21btAlignedFreeInternalPv(i1);
michael@0 53770 return;
michael@0 53771 }
michael@0 53772 function b39(i1, i2, i3, i4) {
michael@0 53773 i1 = i1 | 0;
michael@0 53774 i2 = i2 | 0;
michael@0 53775 i3 = i3 | 0;
michael@0 53776 i4 = i4 | 0;
michael@0 53777 abort(39);
michael@0 53778 }
michael@0 53779 function __ZNK17btCollisionObject28calculateSerializeBufferSizeEv(i1) {
michael@0 53780 i1 = i1 | 0;
michael@0 53781 return 248;
michael@0 53782 }
michael@0 53783 function __ZNK21btConvexInternalShape15getLocalScalingEv(i1) {
michael@0 53784 i1 = i1 | 0;
michael@0 53785 return i1 + 12 | 0;
michael@0 53786 }
michael@0 53787 function __ZNK10btBoxShape36getNumPreferredPenetrationDirectionsEv(i1) {
michael@0 53788 i1 = i1 | 0;
michael@0 53789 return 6;
michael@0 53790 }
michael@0 53791 function __ZN23btConvexConvexAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53792 i1 = i1 | 0;
michael@0 53793 __ZdlPv(i1);
michael@0 53794 return;
michael@0 53795 }
michael@0 53796 function __ZNK16btCollisionShape28calculateSerializeBufferSizeEv(i1) {
michael@0 53797 i1 = i1 | 0;
michael@0 53798 return 12;
michael@0 53799 }
michael@0 53800 function __ZN34btClosestNotMeConvexResultCallbackD0Ev(i1) {
michael@0 53801 i1 = i1 | 0;
michael@0 53802 __ZdlPv(i1);
michael@0 53803 return;
michael@0 53804 }
michael@0 53805 function __ZN28btHashedOverlappingPairCache18hasDeferredRemovalEv(i1) {
michael@0 53806 i1 = i1 | 0;
michael@0 53807 return 0;
michael@0 53808 }
michael@0 53809 function __ZN15btGjkConvexCastD1Ev(i1) {
michael@0 53810 i1 = i1 | 0;
michael@0 53811 __ZN12btConvexCastD2Ev(i1 | 0);
michael@0 53812 return;
michael@0 53813 }
michael@0 53814 function __ZN13btConvexShapeD0Ev(i1) {
michael@0 53815 i1 = i1 | 0;
michael@0 53816 __Z21btAlignedFreeInternalPv(i1);
michael@0 53817 return;
michael@0 53818 }
michael@0 53819 function dynCall_vi(i1, i2) {
michael@0 53820 i1 = i1 | 0;
michael@0 53821 i2 = i2 | 0;
michael@0 53822 FUNCTION_TABLE_vi[i1 & 511](i2 | 0);
michael@0 53823 }
michael@0 53824 function b34(i1, i2, d3, i4) {
michael@0 53825 i1 = i1 | 0;
michael@0 53826 i2 = i2 | 0;
michael@0 53827 d3 = +d3;
michael@0 53828 i4 = i4 | 0;
michael@0 53829 abort(34);
michael@0 53830 }
michael@0 53831 function b26(i1, d2, i3, i4) {
michael@0 53832 i1 = i1 | 0;
michael@0 53833 d2 = +d2;
michael@0 53834 i3 = i3 | 0;
michael@0 53835 i4 = i4 | 0;
michael@0 53836 abort(26);
michael@0 53837 }
michael@0 53838 function b11(i1, i2, i3, d4) {
michael@0 53839 i1 = i1 | 0;
michael@0 53840 i2 = i2 | 0;
michael@0 53841 i3 = i3 | 0;
michael@0 53842 d4 = +d4;
michael@0 53843 abort(11);
michael@0 53844 }
michael@0 53845 function __ZN33btMinkowskiPenetrationDepthSolverD0Ev(i1) {
michael@0 53846 i1 = i1 | 0;
michael@0 53847 __ZdlPv(i1);
michael@0 53848 return;
michael@0 53849 }
michael@0 53850 function __ZN28btCompoundCollisionAlgorithm17SwappedCreateFuncD1Ev(i1) {
michael@0 53851 i1 = i1 | 0;
michael@0 53852 return;
michael@0 53853 }
michael@0 53854 function __ZN13btSphereShapeD1Ev(i1) {
michael@0 53855 i1 = i1 | 0;
michael@0 53856 __ZN13btConvexShapeD2Ev(i1 | 0);
michael@0 53857 return;
michael@0 53858 }
michael@0 53859 function __ZN12btConvexCast10CastResult9DebugDrawEf(i1, d2) {
michael@0 53860 i1 = i1 | 0;
michael@0 53861 d2 = +d2;
michael@0 53862 return;
michael@0 53863 }
michael@0 53864 function __ZN34btSphereTriangleCollisionAlgorithm10CreateFuncD1Ev(i1) {
michael@0 53865 i1 = i1 | 0;
michael@0 53866 return;
michael@0 53867 }
michael@0 53868 function b10(i1, i2, i3) {
michael@0 53869 i1 = i1 | 0;
michael@0 53870 i2 = i2 | 0;
michael@0 53871 i3 = i3 | 0;
michael@0 53872 abort(10);
michael@0 53873 return 0.0;
michael@0 53874 }
michael@0 53875 function __ZN33btConvexConcaveCollisionAlgorithm10CreateFuncD1Ev(i1) {
michael@0 53876 i1 = i1 | 0;
michael@0 53877 return;
michael@0 53878 }
michael@0 53879 function __ZN16btCollisionWorld27ClosestConvexResultCallbackD1Ev(i1) {
michael@0 53880 i1 = i1 | 0;
michael@0 53881 return;
michael@0 53882 }
michael@0 53883 function __ZNK11btRigidBody28calculateSerializeBufferSizeEv(i1) {
michael@0 53884 i1 = i1 | 0;
michael@0 53885 return 480;
michael@0 53886 }
michael@0 53887 function __ZN32btSphereSphereCollisionAlgorithm10CreateFuncD1Ev(i1) {
michael@0 53888 i1 = i1 | 0;
michael@0 53889 return;
michael@0 53890 }
michael@0 53891 function __ZN30btGjkEpaPenetrationDepthSolverD0Ev(i1) {
michael@0 53892 i1 = i1 | 0;
michael@0 53893 __ZdlPv(i1);
michael@0 53894 return;
michael@0 53895 }
michael@0 53896 function __ZN30btActivatingCollisionAlgorithmD0Ev(i1) {
michael@0 53897 i1 = i1 | 0;
michael@0 53898 __ZdlPv(i1);
michael@0 53899 return;
michael@0 53900 }
michael@0 53901 function b15(i1, i2, i3) {
michael@0 53902 i1 = i1 | 0;
michael@0 53903 i2 = i2 | 0;
michael@0 53904 i3 = i3 | 0;
michael@0 53905 abort(15);
michael@0 53906 return 0;
michael@0 53907 }
michael@0 53908 function __ZN31btConvexPlaneCollisionAlgorithm10CreateFuncD1Ev(i1) {
michael@0 53909 i1 = i1 | 0;
michael@0 53910 return;
michael@0 53911 }
michael@0 53912 function __ZN16btEmptyAlgorithm10CreateFuncD0Ev(i1) {
michael@0 53913 i1 = i1 | 0;
michael@0 53914 __ZdlPv(i1);
michael@0 53915 return;
michael@0 53916 }
michael@0 53917 function b37(i1, i2, d3) {
michael@0 53918 i1 = i1 | 0;
michael@0 53919 i2 = i2 | 0;
michael@0 53920 d3 = +d3;
michael@0 53921 abort(37);
michael@0 53922 return 0;
michael@0 53923 }
michael@0 53924 function __ZN28btCompoundCollisionAlgorithm10CreateFuncD1Ev(i1) {
michael@0 53925 i1 = i1 | 0;
michael@0 53926 return;
michael@0 53927 }
michael@0 53928 function __ZNK23btDiscreteDynamicsWorld12getWorldTypeEv(i1) {
michael@0 53929 i1 = i1 | 0;
michael@0 53930 return 2;
michael@0 53931 }
michael@0 53932 function __ZN26btBoxBoxCollisionAlgorithm10CreateFuncD1Ev(i1) {
michael@0 53933 i1 = i1 | 0;
michael@0 53934 return;
michael@0 53935 }
michael@0 53936 function __ZN24btPerturbedContactResultD0Ev(i1) {
michael@0 53937 i1 = i1 | 0;
michael@0 53938 __ZdlPv(i1);
michael@0 53939 return;
michael@0 53940 }
michael@0 53941 function __ZN12btConvexCast10CastResultD0Ev(i1) {
michael@0 53942 i1 = i1 | 0;
michael@0 53943 __ZdlPv(i1);
michael@0 53944 return;
michael@0 53945 }
michael@0 53946 function __ZN23btCollisionPairCallbackD0Ev(i1) {
michael@0 53947 i1 = i1 | 0;
michael@0 53948 __ZdlPv(i1);
michael@0 53949 return;
michael@0 53950 }
michael@0 53951 function __ZN22btCompoundLeafCallbackD0Ev(i1) {
michael@0 53952 i1 = i1 | 0;
michael@0 53953 __ZdlPv(i1);
michael@0 53954 return;
michael@0 53955 }
michael@0 53956 function __ZN22SphereTriangleDetectorD0Ev(i1) {
michael@0 53957 i1 = i1 | 0;
michael@0 53958 __ZdlPv(i1);
michael@0 53959 return;
michael@0 53960 }
michael@0 53961 function __ZdlPv(i1) {
michael@0 53962 i1 = i1 | 0;
michael@0 53963 if ((i1 | 0) != 0) {
michael@0 53964 _free(i1);
michael@0 53965 }
michael@0 53966 return;
michael@0 53967 }
michael@0 53968 function __ZN23btConvexConvexAlgorithm10CreateFuncD2Ev(i1) {
michael@0 53969 i1 = i1 | 0;
michael@0 53970 return;
michael@0 53971 }
michael@0 53972 function __ZN21btSingleSweepCallbackD0Ev(i1) {
michael@0 53973 i1 = i1 | 0;
michael@0 53974 __ZdlPv(i1);
michael@0 53975 return;
michael@0 53976 }
michael@0 53977 function __ZN34btClosestNotMeConvexResultCallbackD1Ev(i1) {
michael@0 53978 i1 = i1 | 0;
michael@0 53979 return;
michael@0 53980 }
michael@0 53981 function __ZN20btDefaultMotionStateD0Ev(i1) {
michael@0 53982 i1 = i1 | 0;
michael@0 53983 __ZdlPv(i1);
michael@0 53984 return;
michael@0 53985 }
michael@0 53986 function __ZN20btCollisionAlgorithmD0Ev(i1) {
michael@0 53987 i1 = i1 | 0;
michael@0 53988 __ZdlPv(i1);
michael@0 53989 return;
michael@0 53990 }
michael@0 53991 function __ZN20BroadphaseAabbTesterD0Ev(i1) {
michael@0 53992 i1 = i1 | 0;
michael@0 53993 __ZdlPv(i1);
michael@0 53994 return;
michael@0 53995 }
michael@0 53996 function __ZNK10__cxxabiv116__shim_type_info5noop2Ev(i1) {
michael@0 53997 i1 = i1 | 0;
michael@0 53998 return;
michael@0 53999 }
michael@0 54000 function __ZNK10__cxxabiv116__shim_type_info5noop1Ev(i1) {
michael@0 54001 i1 = i1 | 0;
michael@0 54002 return;
michael@0 54003 }
michael@0 54004 function __ZN33btMinkowskiPenetrationDepthSolverD1Ev(i1) {
michael@0 54005 i1 = i1 | 0;
michael@0 54006 return;
michael@0 54007 }
michael@0 54008 function __ZN19btSingleRayCallbackD0Ev(i1) {
michael@0 54009 i1 = i1 | 0;
michael@0 54010 __ZdlPv(i1);
michael@0 54011 return;
michael@0 54012 }
michael@0 54013 function __ZN19BroadphaseRayTesterD0Ev(i1) {
michael@0 54014 i1 = i1 | 0;
michael@0 54015 __ZdlPv(i1);
michael@0 54016 return;
michael@0 54017 }
michael@0 54018 function b33(i1, i2, i3) {
michael@0 54019 i1 = i1 | 0;
michael@0 54020 i2 = i2 | 0;
michael@0 54021 i3 = i3 | 0;
michael@0 54022 abort(33);
michael@0 54023 }
michael@0 54024 function __ZNK15btTriangleShape14getNumVerticesEv(i1) {
michael@0 54025 i1 = i1 | 0;
michael@0 54026 return 3;
michael@0 54027 }
michael@0 54028 function __ZN18btDbvtTreeColliderD0Ev(i1) {
michael@0 54029 i1 = i1 | 0;
michael@0 54030 __ZdlPv(i1);
michael@0 54031 return;
michael@0 54032 }
michael@0 54033 function __ZN31btInternalTriangleIndexCallbackD2Ev(i1) {
michael@0 54034 i1 = i1 | 0;
michael@0 54035 return;
michael@0 54036 }
michael@0 54037 function __ZN17btGjkPairDetectorD0Ev(i1) {
michael@0 54038 i1 = i1 | 0;
michael@0 54039 __ZdlPv(i1);
michael@0 54040 return;
michael@0 54041 }
michael@0 54042 function __ZNK15btTriangleShape7getNameEv(i1) {
michael@0 54043 i1 = i1 | 0;
michael@0 54044 return 832 | 0;
michael@0 54045 }
michael@0 54046 function __ZNK15btTriangleShape12getNumPlanesEv(i1) {
michael@0 54047 i1 = i1 | 0;
michael@0 54048 return 1;
michael@0 54049 }
michael@0 54050 function __ZN30btGjkEpaPenetrationDepthSolverD1Ev(i1) {
michael@0 54051 i1 = i1 | 0;
michael@0 54052 return;
michael@0 54053 }
michael@0 54054 function __ZN30btActivatingCollisionAlgorithmD2Ev(i1) {
michael@0 54055 i1 = i1 | 0;
michael@0 54056 return;
michael@0 54057 }
michael@0 54058 function __ZN16btPointCollectorD0Ev(i1) {
michael@0 54059 i1 = i1 | 0;
michael@0 54060 __ZdlPv(i1);
michael@0 54061 return;
michael@0 54062 }
michael@0 54063 function __ZN16btManifoldResultD0Ev(i1) {
michael@0 54064 i1 = i1 | 0;
michael@0 54065 __ZdlPv(i1);
michael@0 54066 return;
michael@0 54067 }
michael@0 54068 function __ZN16btEmptyAlgorithmD0Ev(i1) {
michael@0 54069 i1 = i1 | 0;
michael@0 54070 __ZdlPv(i1);
michael@0 54071 return;
michael@0 54072 }
michael@0 54073 function __ZN16btBoxBoxDetectorD0Ev(i1) {
michael@0 54074 i1 = i1 | 0;
michael@0 54075 __ZdlPv(i1);
michael@0 54076 return;
michael@0 54077 }
michael@0 54078 function b36(i1, i2, d3) {
michael@0 54079 i1 = i1 | 0;
michael@0 54080 i2 = i2 | 0;
michael@0 54081 d3 = +d3;
michael@0 54082 abort(36);
michael@0 54083 }
michael@0 54084 function b18(i1, d2, i3) {
michael@0 54085 i1 = i1 | 0;
michael@0 54086 d2 = +d2;
michael@0 54087 i3 = i3 | 0;
michael@0 54088 abort(18);
michael@0 54089 }
michael@0 54090 function __ZNK15btTriangleShape11getNumEdgesEv(i1) {
michael@0 54091 i1 = i1 | 0;
michael@0 54092 return 3;
michael@0 54093 }
michael@0 54094 function __ZNK13btSphereShape7getNameEv(i1) {
michael@0 54095 i1 = i1 | 0;
michael@0 54096 return 776 | 0;
michael@0 54097 }
michael@0 54098 function __ZN16btEmptyAlgorithm10CreateFuncD1Ev(i1) {
michael@0 54099 i1 = i1 | 0;
michael@0 54100 return;
michael@0 54101 }
michael@0 54102 function __ZNK10btBoxShape14getNumVerticesEv(i1) {
michael@0 54103 i1 = i1 | 0;
michael@0 54104 return 8;
michael@0 54105 }
michael@0 54106 function __ZL14btAllocDefaultj(i1) {
michael@0 54107 i1 = i1 | 0;
michael@0 54108 return _malloc(i1) | 0;
michael@0 54109 }
michael@0 54110 function __ZN16btDbvtBroadphase10printStatsEv(i1) {
michael@0 54111 i1 = i1 | 0;
michael@0 54112 return;
michael@0 54113 }
michael@0 54114 function b14(i1, i2) {
michael@0 54115 i1 = i1 | 0;
michael@0 54116 i2 = i2 | 0;
michael@0 54117 abort(14);
michael@0 54118 return 0;
michael@0 54119 }
michael@0 54120 function __ZNK10btBoxShape7getNameEv(i1) {
michael@0 54121 i1 = i1 | 0;
michael@0 54122 return 712 | 0;
michael@0 54123 }
michael@0 54124 function __ZNK10btBoxShape12getNumPlanesEv(i1) {
michael@0 54125 i1 = i1 | 0;
michael@0 54126 return 6;
michael@0 54127 }
michael@0 54128 function __ZNK10btBoxShape11getNumEdgesEv(i1) {
michael@0 54129 i1 = i1 | 0;
michael@0 54130 return 12;
michael@0 54131 }
michael@0 54132 function b16(i1, d2) {
michael@0 54133 i1 = i1 | 0;
michael@0 54134 d2 = +d2;
michael@0 54135 abort(16);
michael@0 54136 return 0.0;
michael@0 54137 }
michael@0 54138 function __ZNSt9bad_allocD0Ev(i1) {
michael@0 54139 i1 = i1 | 0;
michael@0 54140 __ZdlPv(i1);
michael@0 54141 return;
michael@0 54142 }
michael@0 54143 function __ZN24btPerturbedContactResultD1Ev(i1) {
michael@0 54144 i1 = i1 | 0;
michael@0 54145 return;
michael@0 54146 }
michael@0 54147 function __ZN12btConvexCast10CastResultD1Ev(i1) {
michael@0 54148 i1 = i1 | 0;
michael@0 54149 return;
michael@0 54150 }
michael@0 54151 function __ZN23btCollisionPairCallbackD1Ev(i1) {
michael@0 54152 i1 = i1 | 0;
michael@0 54153 return;
michael@0 54154 }
michael@0 54155 function __ZL13btFreeDefaultPv(i1) {
michael@0 54156 i1 = i1 | 0;
michael@0 54157 _free(i1);
michael@0 54158 return;
michael@0 54159 }
michael@0 54160 function __ZNKSt9bad_alloc4whatEv(i1) {
michael@0 54161 i1 = i1 | 0;
michael@0 54162 return 472 | 0;
michael@0 54163 }
michael@0 54164 function __ZN22btCompoundLeafCallbackD1Ev(i1) {
michael@0 54165 i1 = i1 | 0;
michael@0 54166 return;
michael@0 54167 }
michael@0 54168 function __ZN22SphereTriangleDetectorD1Ev(i1) {
michael@0 54169 i1 = i1 | 0;
michael@0 54170 return;
michael@0 54171 }
michael@0 54172 function __ZN21btSingleSweepCallbackD1Ev(i1) {
michael@0 54173 i1 = i1 | 0;
michael@0 54174 return;
michael@0 54175 }
michael@0 54176 function __ZN20btDefaultMotionStateD1Ev(i1) {
michael@0 54177 i1 = i1 | 0;
michael@0 54178 return;
michael@0 54179 }
michael@0 54180 function __ZN20btCollisionAlgorithmD1Ev(i1) {
michael@0 54181 i1 = i1 | 0;
michael@0 54182 return;
michael@0 54183 }
michael@0 54184 function __ZN20BroadphaseAabbTesterD1Ev(i1) {
michael@0 54185 i1 = i1 | 0;
michael@0 54186 return;
michael@0 54187 }
michael@0 54188 function v____cxa_pure_virtual__wrapper() {
michael@0 54189 ___cxa_pure_virtual();
michael@0 54190 }
michael@0 54191 function dynCall_v(i1) {
michael@0 54192 i1 = i1 | 0;
michael@0 54193 FUNCTION_TABLE_v[i1 & 3]();
michael@0 54194 }
michael@0 54195 function __ZN19btSingleRayCallbackD1Ev(i1) {
michael@0 54196 i1 = i1 | 0;
michael@0 54197 return;
michael@0 54198 }
michael@0 54199 function __ZN19BroadphaseRayTesterD1Ev(i1) {
michael@0 54200 i1 = i1 | 0;
michael@0 54201 return;
michael@0 54202 }
michael@0 54203 function __ZN18btTriangleCallbackD2Ev(i1) {
michael@0 54204 i1 = i1 | 0;
michael@0 54205 return;
michael@0 54206 }
michael@0 54207 function __ZN18btDbvtTreeColliderD1Ev(i1) {
michael@0 54208 i1 = i1 | 0;
michael@0 54209 return;
michael@0 54210 }
michael@0 54211 function __ZN17btGjkPairDetectorD1Ev(i1) {
michael@0 54212 i1 = i1 | 0;
michael@0 54213 return;
michael@0 54214 }
michael@0 54215 function __ZN17btCollisionObjectD2Ev(i1) {
michael@0 54216 i1 = i1 | 0;
michael@0 54217 return;
michael@0 54218 }
michael@0 54219 function __ZN16btPointCollectorD1Ev(i1) {
michael@0 54220 i1 = i1 | 0;
michael@0 54221 return;
michael@0 54222 }
michael@0 54223 function __ZN16btManifoldResultD1Ev(i1) {
michael@0 54224 i1 = i1 | 0;
michael@0 54225 return;
michael@0 54226 }
michael@0 54227 function __ZN16btEmptyAlgorithmD1Ev(i1) {
michael@0 54228 i1 = i1 | 0;
michael@0 54229 return;
michael@0 54230 }
michael@0 54231 function __ZN16btBoxBoxDetectorD1Ev(i1) {
michael@0 54232 i1 = i1 | 0;
michael@0 54233 return;
michael@0 54234 }
michael@0 54235 function __ZN13btConvexShapeD2Ev(i1) {
michael@0 54236 i1 = i1 | 0;
michael@0 54237 return;
michael@0 54238 }
michael@0 54239 function b5(i1, i2) {
michael@0 54240 i1 = i1 | 0;
michael@0 54241 i2 = i2 | 0;
michael@0 54242 abort(5);
michael@0 54243 }
michael@0 54244 function __ZN12btDispatcherD2Ev(i1) {
michael@0 54245 i1 = i1 | 0;
michael@0 54246 return;
michael@0 54247 }
michael@0 54248 function __ZN12btConvexCastD2Ev(i1) {
michael@0 54249 i1 = i1 | 0;
michael@0 54250 return;
michael@0 54251 }
michael@0 54252 function __ZNSt9type_infoD2Ev(i1) {
michael@0 54253 i1 = i1 | 0;
michael@0 54254 return;
michael@0 54255 }
michael@0 54256 function __ZNSt9bad_allocD2Ev(i1) {
michael@0 54257 i1 = i1 | 0;
michael@0 54258 return;
michael@0 54259 }
michael@0 54260 function stackRestore(i1) {
michael@0 54261 i1 = i1 | 0;
michael@0 54262 STACKTOP = i1;
michael@0 54263 }
michael@0 54264 function b27(i1) {
michael@0 54265 i1 = i1 | 0;
michael@0 54266 abort(27);
michael@0 54267 return 0.0;
michael@0 54268 }
michael@0 54269 function b1(i1, d2) {
michael@0 54270 i1 = i1 | 0;
michael@0 54271 d2 = +d2;
michael@0 54272 abort(1);
michael@0 54273 }
michael@0 54274 function setTempRet9(i1) {
michael@0 54275 i1 = i1 | 0;
michael@0 54276 tempRet9 = i1;
michael@0 54277 }
michael@0 54278 function setTempRet8(i1) {
michael@0 54279 i1 = i1 | 0;
michael@0 54280 tempRet8 = i1;
michael@0 54281 }
michael@0 54282 function setTempRet7(i1) {
michael@0 54283 i1 = i1 | 0;
michael@0 54284 tempRet7 = i1;
michael@0 54285 }
michael@0 54286 function setTempRet6(i1) {
michael@0 54287 i1 = i1 | 0;
michael@0 54288 tempRet6 = i1;
michael@0 54289 }
michael@0 54290 function setTempRet5(i1) {
michael@0 54291 i1 = i1 | 0;
michael@0 54292 tempRet5 = i1;
michael@0 54293 }
michael@0 54294 function setTempRet4(i1) {
michael@0 54295 i1 = i1 | 0;
michael@0 54296 tempRet4 = i1;
michael@0 54297 }
michael@0 54298 function setTempRet3(i1) {
michael@0 54299 i1 = i1 | 0;
michael@0 54300 tempRet3 = i1;
michael@0 54301 }
michael@0 54302 function setTempRet2(i1) {
michael@0 54303 i1 = i1 | 0;
michael@0 54304 tempRet2 = i1;
michael@0 54305 }
michael@0 54306 function setTempRet1(i1) {
michael@0 54307 i1 = i1 | 0;
michael@0 54308 tempRet1 = i1;
michael@0 54309 }
michael@0 54310 function setTempRet0(i1) {
michael@0 54311 i1 = i1 | 0;
michael@0 54312 tempRet0 = i1;
michael@0 54313 }
michael@0 54314 function b8(i1) {
michael@0 54315 i1 = i1 | 0;
michael@0 54316 abort(8);
michael@0 54317 return 0;
michael@0 54318 }
michael@0 54319 function stackSave() {
michael@0 54320 return STACKTOP | 0;
michael@0 54321 }
michael@0 54322 function b4(i1) {
michael@0 54323 i1 = i1 | 0;
michael@0 54324 abort(4);
michael@0 54325 }
michael@0 54326 function b35() {
michael@0 54327 abort(35);
michael@0 54328 }
michael@0 54329 // EMSCRIPTEN_END_FUNCS
michael@0 54330 var FUNCTION_TABLE_iiiiiiii = [b0,b0];
michael@0 54331 var FUNCTION_TABLE_vif = [b1,b1,__ZN10btBoxShape9setMarginEf,b1,__ZN21btConvexInternalShape9setMarginEf,b1,__ZN23btDiscreteDynamicsWorld14updateVehiclesEf,b1,__ZN23btDiscreteDynamicsWorld22addSpeculativeContactsEf,b1,__ZN23btDiscreteDynamicsWorld19integrateTransformsEf
michael@0 54332 ,b1,__ZN13btSphereShape9setMarginEf,b1,__ZN23btDiscreteDynamicsWorld25predictUnconstraintMotionEf,b1,__ZN23btDiscreteDynamicsWorld28internalSingleStepSimulationEf,b1,__ZN23btDiscreteDynamicsWorld18saveKinematicStateEf,b1,__ZN12btConvexCast10CastResult9DebugDrawEf,b1,b1,b1,b1,b1,b1,b1,b1,b1,b1,b1];
michael@0 54333 var FUNCTION_TABLE_viifii = [b2,b2];
michael@0 54334 var FUNCTION_TABLE_viiiii = [b3,b3,__ZN34btSphereTriangleCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b3,__ZN28btCompoundCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b3,__ZN27btContinuousConvexCollisionC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver,b3,__ZNK10__cxxabiv117__class_type_info16search_below_dstEPNS_19__dynamic_cast_infoEPKvib,b3,__ZNK10__cxxabiv120__si_class_type_info16search_below_dstEPNS_19__dynamic_cast_infoEPKvib
michael@0 54335 ,b3,__ZN16btDbvtBroadphase7setAabbEP17btBroadphaseProxyRK9btVector3S4_P12btDispatcher,b3,__ZN32btSphereSphereCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b3,__ZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b3,__ZN22SphereTriangleDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb,b3,__ZN31btConvexPlaneCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult
michael@0 54336 ,b3,__ZN17btGjkPairDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb,b3,__ZN28btCompoundCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b,b3,__ZN33btConvexConcaveCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b3,__ZN26btBoxBoxCollisionAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b3,__ZN32btSphereSphereCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_
michael@0 54337 ,b3,__ZNK10__cxxabiv121__vmi_class_type_info16search_below_dstEPNS_19__dynamic_cast_infoEPKvib,b3,__ZN23btDiscreteDynamicsWorldC2EP12btDispatcherP21btBroadphaseInterfaceP18btConstraintSolverP24btCollisionConfiguration,b3,__ZN16btBoxBoxDetector16getClosestPointsERKN36btDiscreteCollisionDetectorInterface17ClosestPointInputERNS0_6ResultEP12btIDebugDrawb,b3,__ZN16btEmptyAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b3,__ZN26btBoxBoxCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_,b3,__ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver,b3,__ZN33btConvexConcaveCollisionAlgorithmC2ERK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_b,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3,b3];
michael@0 54338 var FUNCTION_TABLE_vi = [b4,b4,__ZN34btSphereTriangleCollisionAlgorithmD0Ev,b4,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD2E_0v,b4,__ZN10__cxxabiv116__shim_type_infoD2Ev,b4,__ZN26btBoxBoxCollisionAlgorithmD2Ev,b4,__ZN15btGjkConvexCastD0Ev
michael@0 54339 ,b4,__ZN16btManifoldResultD1Ev,b4,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD0E_0v,b4,__ZN16btPointCollectorD1Ev,b4,__ZN22btSubsimplexConvexCastD1Ev,b4,__ZN33btConvexConcaveCollisionAlgorithm17SwappedCreateFuncD0Ev
michael@0 54340 ,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD2Ev,b4,__ZN20btCollisionAlgorithmD1Ev,b4,__ZN25btTriangleRaycastCallbackD0Ev,b4,__ZN33btConvexConcaveCollisionAlgorithm17SwappedCreateFuncD1Ev,b4,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD0Ev
michael@0 54341 ,b4,__ZNSt9bad_allocD2Ev,b4,__ZN16btCollisionWorld27ClosestConvexResultCallbackD1Ev,b4,__ZN21btCollisionDispatcherD0Ev,b4,__ZN35btSequentialImpulseConstraintSolverD0Ev,b4,__ZZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_EN21MyNodeOverlapCallbackD0Ev
michael@0 54342 ,b4,__ZZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN31LocalTriangleSphereCastCallbackD0Ev,b4,__ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResultD0Ev,b4,__ZN13btSphereShapeD1Ev,b4,__ZN23btCollisionPairCallbackD1Ev,b4,__ZN15btTriangleShapeD0Ev
michael@0 54343 ,b4,__ZN33btMinkowskiPenetrationDepthSolverD1Ev,b4,__ZN18btDbvtTreeColliderD1Ev,b4,__ZN11btUnionFindC2Ev,b4,__ZN18btConvexPolyhedronC2Ev,b4,__ZN32btSphereSphereCollisionAlgorithm10CreateFuncD0Ev
michael@0 54344 ,b4,__ZN23btDiscreteDynamicsWorld12applyGravityEv,b4,__ZN25btSimulationIslandManagerC2Ev,b4,__ZN16btDbvtBroadphaseD2Ev,b4,__ZN28btHashedOverlappingPairCacheC2Ev,b4,__ZN18btConvexPolyhedronD2Ev
michael@0 54345 ,b4,__ZN32btSphereSphereCollisionAlgorithm10CreateFuncD1Ev,b4,__ZNK10__cxxabiv116__shim_type_info5noop1Ev,b4,__ZN16btDbvtBroadphase10printStatsEv,b4,__ZN16btCollisionWorld14debugDrawWorldEv,b4,__ZN23btPolyhedralConvexShapeD2Ev
michael@0 54346 ,b4,__ZN23btConvexConvexAlgorithmD0Ev,b4,__ZZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN31LocalTriangleSphereCastCallbackD2Ev,b4,__ZN10btBoxShapeD0Ev,b4,__ZN31btDefaultCollisionConfigurationD2Ev,b4,__ZZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcherEN18RemovePairCallbackD2Ev
michael@0 54347 ,b4,__ZN31btConvexPlaneCollisionAlgorithm10CreateFuncD0Ev,b4,__ZN23btDiscreteDynamicsWorld26calculateSimulationIslandsEv,b4,__ZN16btCollisionWorld11updateAabbsEv,b4,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN14LocalInfoAdderD0E_1v,b4,__ZN12btConvexCast10CastResultD1Ev
michael@0 54348 ,b4,__ZN28btCompoundCollisionAlgorithmD2Ev,b4,__ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallbackD0Ev,b4,__ZN30btActivatingCollisionAlgorithmD2Ev,b4,__ZThn4_N17DebugDrawcallbackD0Ev,b4,__ZN22btCompoundLeafCallbackD0Ev
michael@0 54349 ,b4,__ZN28btCompoundCollisionAlgorithm17SwappedCreateFuncD1Ev,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN9RayTesterD2E_1v,b4,__ZN16btEmptyAlgorithmD1Ev,b4,__ZN17btCollisionObjectD2Ev,b4,__ZN15btGjkConvexCastD1Ev
michael@0 54350 ,b4,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallbackD2Ev,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD2E_0v,b4,__ZN12btConvexCast10CastResultD0Ev,b4,__ZN16btCollisionWorldD2Ev,b4,__ZThn4_N17DebugDrawcallbackD1Ev
michael@0 54351 ,b4,__ZN23btDiscreteDynamicsWorldD0Ev,b4,__ZN17DebugDrawcallbackD0Ev,b4,__ZN19btSingleRayCallbackD1Ev,b4,__ZN20BroadphaseAabbTesterD1Ev,b4,__ZN20btCollisionAlgorithmD0Ev
michael@0 54352 ,b4,__ZN28btCompoundCollisionAlgorithm17SwappedCreateFuncD0Ev,b4,__ZN28btHashedOverlappingPairCacheD2Ev,b4,__ZN33btConvexConcaveCollisionAlgorithmD2Ev,b4,__ZN10btBoxShapeD1Ev,b4,__ZN28btCompoundCollisionAlgorithm10CreateFuncD1Ev
michael@0 54353 ,b4,__ZN6btDbvtD2Ev,b4,__ZN23btDiscreteDynamicsWorld23synchronizeMotionStatesEv,b4,__ZN34btSphereTriangleCollisionAlgorithmD2Ev,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN9RayTesterD0E_1v,b4,__ZN16btEmptyAlgorithmD0Ev
michael@0 54354 ,b4,__ZN35btSequentialImpulseConstraintSolver5resetEv,b4,__ZL20btAlignedFreeDefaultPv,b4,__ZN15btTriangleShapeD1Ev,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD0E_0v,b4,__ZN19btSingleRayCallbackD0Ev
michael@0 54355 ,b4,__ZN22SphereTriangleDetectorD0Ev,b4,__ZN28btTriangleConvexcastCallbackD0Ev,b4,__ZN16btCollisionWorld33performDiscreteCollisionDetectionEv,b4,__ZN30btGjkEpaPenetrationDepthSolverD0Ev,b4,__ZNSt9bad_allocD0Ev
michael@0 54356 ,b4,__ZN33btMinkowskiPenetrationDepthSolverD0Ev,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallbackD0Ev,b4,__ZN21btConvexInternalShapeD1Ev,b4,__ZN16btDbvtBroadphaseD0Ev,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN15LocalInfoAdder2D0Ev
michael@0 54357 ,b4,__ZN10__cxxabiv120__si_class_type_infoD0Ev,b4,__ZN17DebugDrawcallbackD1Ev,b4,__ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallbackD2Ev,b4,__ZZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_EN21MyNodeOverlapCallbackD2Ev,b4,__ZN16btCollisionWorld27ClosestConvexResultCallbackD0Ev
michael@0 54358 ,b4,__ZN26btBoxBoxCollisionAlgorithm10CreateFuncD0Ev,b4,__ZZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcherEN18RemovePairCallbackD0Ev,b4,__ZN13btConvexShapeD2Ev,b4,__ZN21btConvexInternalShapeD0Ev,b4,__ZN23btDiscreteDynamicsWorld11clearForcesEv
michael@0 54359 ,b4,__ZN18btConvexPolyhedronD0Ev,b4,__ZNK10__cxxabiv116__shim_type_info5noop2Ev,b4,__ZN20btDefaultMotionStateD1Ev,b4,__ZN31btConvexPlaneCollisionAlgorithmD0Ev,b4,__ZN23btConvexConvexAlgorithm10CreateFuncD0Ev
michael@0 54360 ,b4,__ZN16btPointCollectorD0Ev,b4,__ZN31btDefaultCollisionConfigurationD0Ev,b4,__ZN16btBoxBoxDetectorD1Ev,b4,__ZN33btConvexConcaveCollisionAlgorithm10CreateFuncD1Ev,b4,__ZN19BroadphaseRayTesterD1Ev
michael@0 54361 ,b4,__ZN23btCollisionPairCallbackD0Ev,b4,__ZN11btUnionFindD2Ev,b4,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN14LocalInfoAdderD2E_1v,b4,__ZN24btPerturbedContactResultD0Ev,b4,__ZN34btSphereTriangleCollisionAlgorithm10CreateFuncD0Ev
michael@0 54362 ,b4,__ZN23btDiscreteDynamicsWorldD2Ev,b4,__ZN6btDbvtC2Ev,b4,__ZN12CProfileNodeD2Ev,b4,__ZN33btConvexConcaveCollisionAlgorithm10CreateFuncD0Ev,b4,__ZN30btActivatingCollisionAlgorithmD0Ev
michael@0 54363 ,b4,__ZN26btBoxBoxCollisionAlgorithmD0Ev,b4,__ZN21btSingleSweepCallbackD1Ev,b4,__ZN18btDbvtTreeColliderD0Ev,b4,__ZN20BroadphaseAabbTesterD0Ev,b4,__ZN22SphereTriangleDetectorD1Ev
michael@0 54364 ,b4,__ZN32btSphereSphereCollisionAlgorithmD0Ev,b4,__ZZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_EN21MyNodeOverlapCallbackD2Ev,b4,__ZN27btContinuousConvexCollisionD1Ev,b4,__ZN11btRigidBodyD1Ev,b4,__ZN10__cxxabiv121__vmi_class_type_infoD0Ev
michael@0 54365 ,b4,__ZN21btSingleSweepCallbackD0Ev,b4,__ZN22btSubsimplexConvexCastD0Ev,b4,__ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResultD2Ev,b4,__ZN27btContinuousConvexCollisionD0Ev,b4,__ZN17btCollisionObjectD0Ev
michael@0 54366 ,b4,__ZN23btPolyhedralConvexShapeD0Ev,b4,__ZN17btGjkPairDetectorD1Ev,b4,__ZN16btEmptyAlgorithm10CreateFuncD0Ev,b4,__ZN30btGjkEpaPenetrationDepthSolverD1Ev,b4,__ZN11btRigidBodyD0Ev
michael@0 54367 ,b4,__ZN35btSequentialImpulseConstraintSolverC2Ev,b4,__ZN28btHashedOverlappingPairCacheD0Ev,b4,__ZN24btConvexTriangleCallbackD2Ev,b4,__ZN22btCompoundLeafCallbackD1Ev,b4,__ZL13btFreeDefaultPv
michael@0 54368 ,b4,__ZN21btCollisionDispatcherD2Ev,b4,__ZN26btBoxBoxCollisionAlgorithm10CreateFuncD1Ev,b4,__ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResultD0Ev,b4,__ZN25btSimulationIslandManagerD2Ev,b4,__ZN34btClosestNotMeConvexResultCallbackD1Ev
michael@0 54369 ,b4,__ZZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_EN21MyNodeOverlapCallbackD0Ev,b4,__ZN25btTriangleRaycastCallbackD1Ev,b4,__ZN17btGjkPairDetectorD0Ev,b4,__ZN33btConvexConcaveCollisionAlgorithmD0Ev,b4,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN15LocalInfoAdder2D2Ev
michael@0 54370 ,b4,__ZN23btConvexConvexAlgorithmD2Ev,b4,__ZN28btCompoundCollisionAlgorithmD0Ev,b4,__ZN34btClosestNotMeConvexResultCallbackD0Ev,b4,__ZN16btBoxBoxDetectorD0Ev,b4,__ZN24btConvexTriangleCallbackD0Ev
michael@0 54371 ,b4,__ZN13btSphereShapeD0Ev,b4,__ZN13btConvexShapeD0Ev,b4,__ZN7btClockD2Ev,b4,__ZN31btConvexPlaneCollisionAlgorithm10CreateFuncD1Ev,b4,__ZN24btPerturbedContactResultD1Ev
michael@0 54372 ,b4,__ZN23btDiscreteDynamicsWorld14debugDrawWorldEv,b4,__ZN16btEmptyAlgorithm10CreateFuncD1Ev,b4,__ZZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcherEN17CleanPairCallbackD0Ev,b4,__ZN10__cxxabiv117__class_type_infoD0Ev,b4,__ZN34btSphereTriangleCollisionAlgorithm10CreateFuncD1Ev
michael@0 54373 ,b4,__ZN28btTriangleConvexcastCallbackD1Ev,b4,__ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResultD2Ev,b4,__ZN28btCompoundCollisionAlgorithm10CreateFuncD0Ev,b4,__ZN23btConvexConvexAlgorithm10CreateFuncD2Ev,b4,__ZN25btSimulationIslandManagerD0Ev
michael@0 54374 ,b4,__ZN16btCollisionWorldD0Ev,b4,__ZN19BroadphaseRayTesterD0Ev,b4,__ZN16btManifoldResultD0Ev,b4,__ZN35btSequentialImpulseConstraintSolverD2Ev,b4,__ZN20btDefaultMotionStateD0Ev,b4,__ZZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcherEN17CleanPairCallbackD2Ev,b4,__ZN32btSphereSphereCollisionAlgorithmD2Ev,b4,__ZN31btConvexPlaneCollisionAlgorithmD2Ev,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4,b4];
michael@0 54375 var FUNCTION_TABLE_vii = [b5,b5,__ZN21btConvexInternalShape15setLocalScalingERK9btVector3,b5,__ZN28btCompoundCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE,b5,__ZN20BroadphaseAabbTester7ProcessEPK10btDbvtNode,b5,__ZN23btDiscreteDynamicsWorld13removeVehicleEP17btActionInterface,b5,__ZN23btDiscreteDynamicsWorld12removeActionEP17btActionInterface
michael@0 54376 ,b5,__ZN21btCollisionDispatcher15releaseManifoldEP20btPersistentManifold,b5,__ZN23btConvexConvexAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE,b5,__ZN11btRigidBodyC2ERKNS_27btRigidBodyConstructionInfoE,b5,__ZN16btCollisionWorld9serializeEP12btSerializer,b5,__ZNK20btDefaultMotionState17getWorldTransformER11btTransform
michael@0 54377 ,b5,__ZN16btCollisionWorld14setDebugDrawerEP12btIDebugDraw,b5,__ZN16btCollisionWorld21removeCollisionObjectEP17btCollisionObject,b5,__ZN23btDiscreteDynamicsWorld12addCharacterEP17btActionInterface,b5,__ZNK11btRigidBody21serializeSingleObjectEP12btSerializer,b5,__ZN17btCollisionObject17setCollisionShapeEP16btCollisionShape
michael@0 54378 ,b5,__ZN25btSimulationIslandManager26storeIslandActivationStateEP16btCollisionWorld,b5,__ZN12btConvexCast10CastResult15drawCoordSystemERK11btTransform,b5,__ZN28btHashedOverlappingPairCache28setInternalGhostPairCallbackEP25btOverlappingPairCallback,b5,__ZN23btDiscreteDynamicsWorld10setGravityERK9btVector3,b5,__ZN23btDiscreteDynamicsWorld16removeConstraintEP17btTypedConstraint
michael@0 54379 ,b5,__ZN23btDiscreteDynamicsWorld12addRigidBodyEP11btRigidBody,b5,__ZNK23btDiscreteDynamicsWorld10getGravityEv,b5,__ZN23btDiscreteDynamicsWorld15removeCharacterEP17btActionInterface,b5,__ZN16btDbvtBroadphase9resetPoolEP12btDispatcher,b5,__ZN23btDiscreteDynamicsWorld9serializeEP12btSerializer
michael@0 54380 ,b5,__ZN22btCompoundLeafCallback7ProcessEPK10btDbvtNode,b5,__ZNK17btCollisionObject21serializeSingleObjectEP12btSerializer,b5,__ZN16btDbvtBroadphase25calculateOverlappingPairsEP12btDispatcher,b5,__ZN21btCollisionDispatcher22freeCollisionAlgorithmEPv,b5,__ZN26btBoxBoxCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE
michael@0 54381 ,b5,__ZN34btSphereTriangleCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE,b5,__ZN10btBoxShape15setLocalScalingERK9btVector3,b5,__ZN23btDiscreteDynamicsWorld11setNumTasksEi,b5,__ZN28btHashedOverlappingPairCache24setOverlapFilterCallbackEP23btOverlapFilterCallback,b5,__ZN23btDiscreteDynamicsWorld19setConstraintSolverEP18btConstraintSolver
michael@0 54382 ,b5,__ZN21btCollisionDispatcherC2EP24btCollisionConfiguration,b5,__ZN23btDiscreteDynamicsWorld10addVehicleEP17btActionInterface,b5,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN9RayTester7ProcessE_1PK10btDbvtNode,b5,__ZN23btDiscreteDynamicsWorld21removeCollisionObjectEP17btCollisionObject,b5,__ZN19BroadphaseRayTester7ProcessEPK10btDbvtNode
michael@0 54383 ,b5,__ZN28btHashedOverlappingPairCache20sortOverlappingPairsEP12btDispatcher,b5,__ZN31btDefaultCollisionConfigurationC2ERK34btDefaultCollisionConstructionInfo,b5,__ZNK16btCollisionShape20serializeSingleShapeEP12btSerializer,b5,__ZN16btEmptyAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE,b5,__ZN16btEmptyAlgorithmC2ERK36btCollisionAlgorithmConstructionInfo
michael@0 54384 ,b5,__ZN18btDbvtTreeCollider7ProcessEPK10btDbvtNode,b5,__ZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfo,b5,__ZN20btDefaultMotionState17setWorldTransformERK11btTransform,b5,__ZN33btConvexConcaveCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE,b5,__ZN21btCollisionDispatcher13clearManifoldEP20btPersistentManifold
michael@0 54385 ,b5,__ZN16btDbvtBroadphaseC2EP22btOverlappingPairCache,b5,__ZN23btDiscreteDynamicsWorld15removeRigidBodyEP11btRigidBody,b5,__ZN23btDiscreteDynamicsWorld9addActionEP17btActionInterface,b5,__ZN31btConvexPlaneCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE,b5,__ZN32btSphereSphereCollisionAlgorithm22getAllContactManifoldsER20btAlignedObjectArrayIP20btPersistentManifoldE,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5,b5];
michael@0 54386 var FUNCTION_TABLE_viiifii = [b6,b6];
michael@0 54387 var FUNCTION_TABLE_vifiii = [b7,b7,__ZN11btRigidBodyC2EfP13btMotionStateP16btCollisionShapeRK9btVector3,b7];
michael@0 54388 var FUNCTION_TABLE_ii = [b8,b8,__ZN23btPolyhedralConvexShape28initializePolyhedralFeaturesEv,b8,__ZNK15btTriangleShape11getNumEdgesEv,b8,__ZN28btHashedOverlappingPairCache26getOverlappingPairArrayPtrEv,b8,__ZNK23btDiscreteDynamicsWorld17getNumConstraintsEv,b8,__ZNK16btCollisionShape28calculateSerializeBufferSizeEv
michael@0 54389 ,b8,__ZNK21btConvexInternalShape36getNumPreferredPenetrationDirectionsEv,b8,__ZNK28btHashedOverlappingPairCache22getNumOverlappingPairsEv,b8,__ZNK13btSphereShape7getNameEv,b8,__ZNK15btTriangleShape7getNameEv,b8,__ZNK11btRigidBody28calculateSerializeBufferSizeEv
michael@0 54390 ,b8,__ZNK10btBoxShape14getNumVerticesEv,b8,__ZNK28btHashedOverlappingPairCache26getOverlappingPairArrayPtrEv,b8,__ZN21btCollisionDispatcher23getInternalManifoldPoolEv,b8,__ZNK15btTriangleShape12getNumPlanesEv,b8,__ZN16btCollisionWorld14getDebugDrawerEv
michael@0 54391 ,b8,__ZN31btDefaultCollisionConfiguration25getPersistentManifoldPoolEv,b8,__ZNK21btConvexInternalShape28calculateSerializeBufferSizeEv,b8,__ZN31btDefaultCollisionConfiguration25getCollisionAlgorithmPoolEv,b8,__ZNK10btBoxShape11getNumEdgesEv,b8,__ZN31btDefaultCollisionConfiguration17getStackAllocatorEv
michael@0 54392 ,b8,__ZNK15btTriangleShape36getNumPreferredPenetrationDirectionsEv,b8,__ZNK21btCollisionDispatcher15getNumManifoldsEv,b8,__ZNK10btBoxShape36getNumPreferredPenetrationDirectionsEv,b8,__ZN21btCollisionDispatcher26getInternalManifoldPointerEv,b8,__ZNK15btTriangleShape14getNumVerticesEv
michael@0 54393 ,b8,__ZNK10btBoxShape12getNumPlanesEv,b8,__ZNK23btDiscreteDynamicsWorld12getWorldTypeEv,b8,__ZNK21btConvexInternalShape15getLocalScalingEv,b8,__ZN28btHashedOverlappingPairCache18hasDeferredRemovalEv,b8,__ZN28btHashedOverlappingPairCache23getOverlappingPairArrayEv
michael@0 54394 ,b8,__ZN16btDbvtBroadphase23getOverlappingPairCacheEv,b8,__ZN23btDiscreteDynamicsWorld19getConstraintSolverEv,b8,__ZNKSt9bad_alloc4whatEv,b8,__ZNK16btDbvtBroadphase23getOverlappingPairCacheEv,b8,__ZNK21btCollisionDispatcher23getInternalManifoldPoolEv,b8,__ZNK10btBoxShape7getNameEv,b8,__ZN31btDefaultCollisionConfiguration16getSimplexSolverEv,b8,__ZNK17btCollisionObject28calculateSerializeBufferSizeEv,b8,__ZL14btAllocDefaultj,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8,b8];
michael@0 54395 var FUNCTION_TABLE_viiiiffffiif = [b9,b9];
michael@0 54396 var FUNCTION_TABLE_fiii = [b10,b10,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN14LocalInfoAdder15addSingleResultE_1RNS_17LocalConvexResultEb,b10,__ZN16btCollisionWorld27ClosestConvexResultCallback15addSingleResultERNS_17LocalConvexResultEb,b10,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN15LocalInfoAdder215addSingleResultERNS_14LocalRayResultEb,b10,__ZN34btClosestNotMeConvexResultCallback15addSingleResultERN16btCollisionWorld17LocalConvexResultEb,b10,b10,b10,b10,b10,b10,b10];
michael@0 54397 var FUNCTION_TABLE_viiif = [b11,b11,__ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResult15addContactPointERK9btVector3SA_f,b11,__ZN22SphereTriangleDetectorC2EP13btSphereShapeP15btTriangleShapef,b11,__ZN16btManifoldResult15addContactPointERK9btVector3S2_f,b11,__ZN24btPerturbedContactResult15addContactPointERK9btVector3S2_f,b11,__ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResult15addContactPointERKS8_SG_f,b11,__ZN16btPointCollector15addContactPointERK9btVector3S2_f,b11,b11,b11];
michael@0 54398 var FUNCTION_TABLE_fiiiiiiiiiii = [b12,b12,__ZN35btSequentialImpulseConstraintSolver10solveGroupEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAllocP12btDispatcher,b12];
michael@0 54399 var FUNCTION_TABLE_fiifii = [b13,b13,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallback9reportHitE_0RK9btVector3fii,b13,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEEN29BridgeTriangleRaycastCallback9reportHitERK9btVector3fii,b13,b13,b13];
michael@0 54400 var FUNCTION_TABLE_iii = [b14,b14,__ZN19btSingleRayCallback7processEPK17btBroadphaseProxy,b14,__ZL21btAlignedAllocDefaultji,b14,__ZN11btRigidBody24checkCollideWithOverrideEP17btCollisionObject,b14,__ZZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcherEN17CleanPairCallback14processOverlapER16btBroadphasePair,b14,__ZN6btDbvt8ICollide9AllLeavesEPK10btDbvtNode
michael@0 54401 ,b14,__ZN21btCollisionDispatcher26allocateCollisionAlgorithmEi,b14,__ZL8pointCmpRKN20btConvexHullInternal7Point32ES2_,b14,__ZN21btCollisionDispatcher26getManifoldByIndexInternalEi,b14,__ZZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcherEN18RemovePairCallback14processOverlapER16btBroadphasePair,b14,__ZN17btCollisionObject24checkCollideWithOverrideEPS_
michael@0 54402 ,b14,__ZZN16btCollisionWorld13rayTestSingleERK11btTransformS2_P17btCollisionObjectPK16btCollisionShapeS2_RNS_17RayResultCallbackEENK15LocalInfoAdder214needsCollisionEP17btBroadphaseProxy,b14,__ZNK34btClosestNotMeConvexResultCallback14needsCollisionEP17btBroadphaseProxy,b14,__ZN23btCollisionPairCallback14processOverlapER16btBroadphasePair,b14,__ZN21btSingleSweepCallback7processEPK17btBroadphaseProxy,b14,__ZNK16btCollisionWorld20ConvexResultCallback14needsCollisionEP17btBroadphaseProxy,b14,__ZN6btDbvt8ICollide7DescentEPK10btDbvtNode,b14,__ZN23btDiscreteDynamicsWorld13getConstraintEi,b14,__ZNK23btDiscreteDynamicsWorld13getConstraintEi,b14,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfENK14LocalInfoAdder14needsCollisionE_1P17btBroadphaseProxy,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14,b14];
michael@0 54403 var FUNCTION_TABLE_iiii = [b15,b15,__ZN21btCollisionDispatcher14getNewManifoldEPvS0_,b15,__ZNK10__cxxabiv117__class_type_info9can_catchEPKNS_16__shim_type_infoERPv,b15,__ZNK21btConvexInternalShape9serializeEPvP12btSerializer,b15,__ZN21btCollisionDispatcher14needsCollisionEP17btCollisionObjectS1_,b15,__ZN28btHashedOverlappingPairCache18addOverlappingPairEP17btBroadphaseProxyS1_
michael@0 54404 ,b15,__ZN28btHashedOverlappingPairCache8findPairEP17btBroadphaseProxyS1_,b15,__ZNK16btCollisionShape9serializeEPvP12btSerializer,b15,__ZN21btCollisionDispatcher13needsResponseEP17btCollisionObjectS1_,b15,__ZNK11btRigidBody9serializeEPvP12btSerializer,b15,__ZN31btDefaultCollisionConfiguration31getCollisionAlgorithmCreateFuncEii,b15,__ZNK17btCollisionObject9serializeEPvP12btSerializer,b15,b15,b15,b15,b15,b15,b15,b15,b15];
michael@0 54405 var FUNCTION_TABLE_fif = [b16,b16,__ZNK16btCollisionShape27getContactBreakingThresholdEf,b16];
michael@0 54406 var FUNCTION_TABLE_viiiiiiii = [b17,b17,__ZN31btConvexPlaneCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_bii,b17];
michael@0 54407 var FUNCTION_TABLE_vifi = [b18,b18,__ZNK15btTriangleShape21calculateLocalInertiaEfR9btVector3,b18,__ZNK23btPolyhedralConvexShape21calculateLocalInertiaEfR9btVector3,b18,__ZNK13btSphereShape21calculateLocalInertiaEfR9btVector3,b18,__ZNK10btBoxShape21calculateLocalInertiaEfR9btVector3,b18,b18,b18,b18,b18,b18,b18];
michael@0 54408 var FUNCTION_TABLE_viiiiii = [b19,b19,__ZNK10__cxxabiv121__vmi_class_type_info16search_above_dstEPNS_19__dynamic_cast_infoEPKvS4_ib,b19,__ZNK10__cxxabiv120__si_class_type_info16search_above_dstEPNS_19__dynamic_cast_infoEPKvS4_ib,b19,__ZN34btSphereTriangleCollisionAlgorithmC2EP20btPersistentManifoldRK36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS6_b,b19,__ZN16btDbvtBroadphase7rayTestERK9btVector3S2_R23btBroadphaseRayCallbackS2_S2_,b19,__ZNK10__cxxabiv117__class_type_info16search_above_dstEPNS_19__dynamic_cast_infoEPKvS4_ib,b19,__ZZN23btDiscreteDynamicsWorld16solveConstraintsER19btContactSolverInfoEN27InplaceSolverIslandCallback13ProcessIslandEPP17btCollisionObjectiPP20btPersistentManifoldii,b19,b19,b19];
michael@0 54409 var FUNCTION_TABLE_iiiiiiiiii = [b20,b20,__ZN16btDbvtBroadphase11createProxyERK9btVector3S2_iPvssP12btDispatcherS3_,b20];
michael@0 54410 var FUNCTION_TABLE_viffiii = [b21,b21];
michael@0 54411 var FUNCTION_TABLE_iiiiiii = [b22,b22,__ZN27btContinuousConvexCollision16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE,b22,__ZN22btSubsimplexConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE,b22,__ZN15btGjkConvexCast16calcTimeOfImpactERK11btTransformS2_S2_S2_RN12btConvexCast10CastResultE,b22];
michael@0 54412 var FUNCTION_TABLE_fiiiiiiiiii = [b23,b23,__ZN35btSequentialImpulseConstraintSolver28solveGroupCacheFriendlySetupEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc,b23,__ZN35btSequentialImpulseConstraintSolver33solveGroupCacheFriendlyIterationsEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc,b23,__ZN35btSequentialImpulseConstraintSolver29solveGroupCacheFriendlyFinishEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc,b23];
michael@0 54413 var FUNCTION_TABLE_fiiiii = [b24,b24,__ZN32btSphereSphereCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,__ZN26btBoxBoxCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,__ZN31btConvexPlaneCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,__ZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,__ZN28btCompoundCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,__ZN23btConvexConvexAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,__ZN16btEmptyAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,__ZN34btSphereTriangleCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResult,b24,b24,b24,b24,b24,b24,b24,b24,b24,b24,b24,b24,b24,b24,b24];
michael@0 54414 var FUNCTION_TABLE_iiiiiiiiiiii = [b25,b25,__ZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAlloc,b25,__ZN30btGjkEpaPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAlloc,b25,b25,b25];
michael@0 54415 var FUNCTION_TABLE_vifii = [b26,b26];
michael@0 54416 var FUNCTION_TABLE_fi = [b27,b27,__ZNK13btSphereShape9getMarginEv,b27,__ZNK16btCollisionShape20getAngularMotionDiscEv,b27,__ZNK21btConvexInternalShape9getMarginEv,b27];
michael@0 54417 var FUNCTION_TABLE_viiiiiiiiii = [b28,b28,__ZN35btSequentialImpulseConstraintSolver45solveGroupCacheFriendlySplitImpulseIterationsEPP17btCollisionObjectiPP20btPersistentManifoldiPP17btTypedConstraintiRK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc,b28];
michael@0 54418 var FUNCTION_TABLE_viiiifffffif = [b29,b29];
michael@0 54419 var FUNCTION_TABLE_viiiiiffii = [b30,b30,__ZN17btGjkPairDetectorC2EPK13btConvexShapeS2_iiffP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver,b30];
michael@0 54420 var FUNCTION_TABLE_iifif = [b31,b31,__ZN23btDiscreteDynamicsWorld14stepSimulationEfif,b31];
michael@0 54421 var FUNCTION_TABLE_iiiii = [b32,b32,__ZN28btCompoundCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN31btConvexPlaneCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN16btEmptyAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN21btCollisionDispatcher13findAlgorithmEP17btCollisionObjectS1_P20btPersistentManifold,b32,__ZN34btSphereTriangleCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_
michael@0 54422 ,b32,__ZN33btConvexConcaveCollisionAlgorithm17SwappedCreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN32btSphereSphereCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN33btConvexConcaveCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN26btBoxBoxCollisionAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN28btCompoundCollisionAlgorithm17SwappedCreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,__ZN28btHashedOverlappingPairCache21removeOverlappingPairEP17btBroadphaseProxyS1_P12btDispatcher,b32,__ZN23btConvexConvexAlgorithm10CreateFunc24CreateCollisionAlgorithmER36btCollisionAlgorithmConstructionInfoP17btCollisionObjectS4_,b32,b32,b32,b32,b32,b32,b32];
michael@0 54423 var FUNCTION_TABLE_viii = [b33,b33,__ZN18btDbvtTreeCollider7ProcessEPK10btDbvtNodeS2_,b33,__ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResult20setShapeIdentifiersBEii,b33,__ZNK15btTriangleShape37localGetSupportingVertexWithoutMarginERK9btVector3,b33,__ZNK10btBoxShape32getPreferredPenetrationDirectionEiR9btVector3,b33,__ZN6btDbvt8ICollide7ProcessEPK10btDbvtNodeS3_
michael@0 54424 ,b33,__ZNK15btTriangleShape32getPreferredPenetrationDirectionEiR9btVector3,b33,__ZN28btHashedOverlappingPairCache20cleanOverlappingPairER16btBroadphasePairP12btDispatcher,b33,__ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResult20setShapeIdentifiersBEii,b33,__ZNK13btSphereShape37localGetSupportingVertexWithoutMarginERK9btVector3,b33,__ZN21btCollisionDispatcher19defaultNearCallbackER16btBroadphasePairRS_RK16btDispatcherInfo
michael@0 54425 ,b33,__ZN25btSimulationIslandManager21updateActivationStateEP16btCollisionWorldP12btDispatcher,b33,__ZN28btHashedOverlappingPairCache19cleanProxyFromPairsEP17btBroadphaseProxyP12btDispatcher,b33,__ZZN23btConvexConvexAlgorithm16processCollisionEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN13btDummyResult20setShapeIdentifiersAEii,b33,__ZNK10btBoxShape16getPlaneEquationER9btVector4i,b33,__ZNK15btTriangleShape9getVertexEiR9btVector3
michael@0 54426 ,b33,__ZZN22btBvhTriangleMeshShape14performRaycastEP18btTriangleCallbackRK9btVector3S4_EN21MyNodeOverlapCallback11processNodeEii,b33,__ZN16btPointCollector20setShapeIdentifiersAEii,b33,__ZNK13btConvexShape31localGetSupportVertexNonVirtualERK9btVector3,b33,__ZNK21btConvexInternalShape24localGetSupportingVertexERK9btVector3,b33,__ZN23btConvexConvexAlgorithm10CreateFuncC2EP22btVoronoiSimplexSolverP30btConvexPenetrationDepthSolver
michael@0 54427 ,b33,__ZNK23btPolyhedralConvexShape37localGetSupportingVertexWithoutMarginERK9btVector3,b33,__ZN16btBoxBoxDetectorC2EP10btBoxShapeS1_,b33,__ZNK13btSphereShape24localGetSupportingVertexERK9btVector3,b33,__ZN28btHashedOverlappingPairCache37removeOverlappingPairsContainingProxyEP17btBroadphaseProxyP12btDispatcher,b33,__ZN16btPointCollector20setShapeIdentifiersBEii
michael@0 54428 ,b33,__ZN16btManifoldResult20setShapeIdentifiersAEii,b33,__ZNK10btBoxShape9getVertexEiR9btVector3,b33,__ZN18btConstraintSolver12prepareSolveEii,b33,__ZN16btDbvtBroadphase12destroyProxyEP17btBroadphaseProxyP12btDispatcher,b33,__ZNK16btCollisionShape17getBoundingSphereER9btVector3Rf
michael@0 54429 ,b33,__ZN28btHashedOverlappingPairCache26processAllOverlappingPairsEP17btOverlapCallbackP12btDispatcher,b33,__ZNK10btBoxShape37localGetSupportingVertexWithoutMarginERK9btVector3,b33,__ZN27btContinuousConvexCollisionC2EPK13btConvexShapePK18btStaticPlaneShape,b33,__ZN23btDiscreteDynamicsWorld13addConstraintEP17btTypedConstraintb,b33,__ZN16btManifoldResult20setShapeIdentifiersBEii
michael@0 54430 ,b33,__ZNK10btBoxShape24localGetSupportingVertexERK9btVector3,b33,__ZZN22btBvhTriangleMeshShape17performConvexcastEP18btTriangleCallbackRK9btVector3S4_S4_S4_EN21MyNodeOverlapCallback11processNodeEii,b33,__ZN16btManifoldResultC2EP17btCollisionObjectS1_,b33,__ZNK21btConvexInternalShape32getPreferredPenetrationDirectionEiR9btVector3,b33,__ZN12btConvexCast10CastResult13reportFailureEii,b33,__ZNK13btConvexShape44localGetSupportVertexWithoutMarginNonVirtualERK9btVector3,b33,__ZNK16btDbvtBroadphase17getBroadphaseAabbER9btVector3S1_,b33,__ZZN33btMinkowskiPenetrationDepthSolver12calcPenDepthER22btVoronoiSimplexSolverPK13btConvexShapeS4_RK11btTransformS7_R9btVector3S9_S9_P12btIDebugDrawP12btStackAllocEN20btIntermediateResult20setShapeIdentifiersAEii,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33,b33];
michael@0 54431 var FUNCTION_TABLE_viifi = [b34,b34];
michael@0 54432 var FUNCTION_TABLE_v = [b35,b35,v____cxa_pure_virtual__wrapper,b35];
michael@0 54433 var FUNCTION_TABLE_viif = [b36,b36,__ZN6btDbvt8ICollide7ProcessEPK10btDbvtNodef,b36];
michael@0 54434 var FUNCTION_TABLE_iiif = [b37,b37,__ZNK15btTriangleShape8isInsideERK9btVector3f,b37,__ZNK10btBoxShape8isInsideERK9btVector3f,b37,b37,b37];
michael@0 54435 var FUNCTION_TABLE_fiiifii = [b38,b38,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallback9reportHitERK9btVector3SG_fii,b38,__ZZN16btCollisionWorld17objectQuerySingleEPK13btConvexShapeRK11btTransformS5_P17btCollisionObjectPK16btCollisionShapeS5_RNS_20ConvexResultCallbackEfEN32BridgeTriangleConvexcastCallback9reportHitE_0RK9btVector3SG_fii,b38,b38,b38];
michael@0 54436 var FUNCTION_TABLE_viiii = [b39,b39,__ZN22btSubsimplexConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver,b39,__ZThn4_N17DebugDrawcallback28internalProcessTriangleIndexEP9btVector3ii,b39,__ZNK15btTriangleShape8getPlaneER9btVector3S1_i,b39,__ZN16btCollisionWorld18addCollisionObjectEP17btCollisionObjectss,b39,__ZNK13btSphereShape7getAabbERK11btTransformR9btVector3S4_
michael@0 54437 ,b39,__ZN16btDbvtBroadphase8aabbTestERK9btVector3S2_R24btBroadphaseAabbCallback,b39,__ZN16btCollisionWorld15debugDrawObjectERK11btTransformPK16btCollisionShapeRK9btVector3,b39,__ZN17DebugDrawcallback28internalProcessTriangleIndexEP9btVector3ii,b39,__ZNK10btBoxShape7getEdgeEiR9btVector3S1_,b39,__ZNK15btTriangleShape7getEdgeEiR9btVector3S1_
michael@0 54438 ,b39,__ZNK10__cxxabiv120__si_class_type_info27has_unambiguous_public_baseEPNS_19__dynamic_cast_infoEPvi,b39,__ZNK10__cxxabiv121__vmi_class_type_info27has_unambiguous_public_baseEPNS_19__dynamic_cast_infoEPvi,b39,__ZN28btTriangleConvexcastCallback15processTriangleEP9btVector3ii,b39,__ZNK23btPolyhedralConvexShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i,b39,__ZN18btConstraintSolver9allSolvedERK19btContactSolverInfoP12btIDebugDrawP12btStackAlloc
michael@0 54439 ,b39,__ZN24btConvexTriangleCallback15processTriangleEP9btVector3ii,b39,__ZNK13btSphereShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i,b39,__ZZN33btConvexConcaveCollisionAlgorithm21calculateTimeOfImpactEP17btCollisionObjectS1_RK16btDispatcherInfoP16btManifoldResultEN31LocalTriangleSphereCastCallback15processTriangleEP9btVector3ii,b39,__ZNK21btConvexInternalShape11getAabbSlowERK11btTransformR9btVector3S4_,b39,__ZN25btTriangleRaycastCallback15processTriangleEP9btVector3ii
michael@0 54440 ,b39,__ZNK10__cxxabiv117__class_type_info27has_unambiguous_public_baseEPNS_19__dynamic_cast_infoEPvi,b39,__ZN21btCollisionDispatcher25dispatchAllCollisionPairsEP22btOverlappingPairCacheRK16btDispatcherInfoP12btDispatcher,b39,__ZNK10btBoxShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i,b39,__ZNK10btBoxShape7getAabbERK11btTransformR9btVector3S4_,b39,__ZNK15btTriangleShape49batchedUnitVectorGetSupportingVertexWithoutMarginEPK9btVector3PS0_i
michael@0 54441 ,b39,__ZN15btGjkConvexCastC2EPK13btConvexShapeS2_P22btVoronoiSimplexSolver,b39,__ZNK16btDbvtBroadphase7getAabbEP17btBroadphaseProxyR9btVector3S3_,b39,__ZN23btDiscreteDynamicsWorld12addRigidBodyEP11btRigidBodyss,b39,__ZNK21btConvexInternalShape7getAabbERK11btTransformR9btVector3S4_,b39,__ZNK16btCollisionWorld7rayTestERK9btVector3S2_RNS_17RayResultCallbackE
michael@0 54442 ,b39,__ZNK10btBoxShape8getPlaneER9btVector3S1_i,b39,__ZNK15btTriangleShape16getPlaneEquationEiR9btVector3S1_,b39,__ZNK15btTriangleShape7getAabbERK11btTransformR9btVector3S4_,b39,__ZN17DebugDrawcallback15processTriangleEP9btVector3ii,b39,__ZN23btDiscreteDynamicsWorld18addCollisionObjectEP17btCollisionObjectss,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39,b39];
michael@0 54443 return { _strlen: _strlen, _free: _free, _main: _main, __GLOBAL__I_a: __GLOBAL__I_a, _memset: _memset, _malloc: _malloc, _memcpy: _memcpy, _llvm_uadd_with_overflow_i64: _llvm_uadd_with_overflow_i64, runPostSets: runPostSets, stackAlloc: stackAlloc, stackSave: stackSave, stackRestore: stackRestore, setThrew: setThrew, setTempRet0: setTempRet0, setTempRet1: setTempRet1, setTempRet2: setTempRet2, setTempRet3: setTempRet3, setTempRet4: setTempRet4, setTempRet5: setTempRet5, setTempRet6: setTempRet6, setTempRet7: setTempRet7, setTempRet8: setTempRet8, setTempRet9: setTempRet9, dynCall_iiiiiiii: dynCall_iiiiiiii, dynCall_vif: dynCall_vif, dynCall_viifii: dynCall_viifii, dynCall_viiiii: dynCall_viiiii, dynCall_vi: dynCall_vi, dynCall_vii: dynCall_vii, dynCall_viiifii: dynCall_viiifii, dynCall_vifiii: dynCall_vifiii, dynCall_ii: dynCall_ii, dynCall_viiiiffffiif: dynCall_viiiiffffiif, dynCall_fiii: dynCall_fiii, dynCall_viiif: dynCall_viiif, dynCall_fiiiiiiiiiii: dynCall_fiiiiiiiiiii, dynCall_fiifii: dynCall_fiifii, dynCall_iii: dynCall_iii, dynCall_iiii: dynCall_iiii, dynCall_fif: dynCall_fif, dynCall_viiiiiiii: dynCall_viiiiiiii, dynCall_vifi: dynCall_vifi, dynCall_viiiiii: dynCall_viiiiii, dynCall_iiiiiiiiii: dynCall_iiiiiiiiii, dynCall_viffiii: dynCall_viffiii, dynCall_iiiiiii: dynCall_iiiiiii, dynCall_fiiiiiiiiii: dynCall_fiiiiiiiiii, dynCall_fiiiii: dynCall_fiiiii, dynCall_iiiiiiiiiiii: dynCall_iiiiiiiiiiii, dynCall_vifii: dynCall_vifii, dynCall_fi: dynCall_fi, dynCall_viiiiiiiiii: dynCall_viiiiiiiiii, dynCall_viiiifffffif: dynCall_viiiifffffif, dynCall_viiiiiffii: dynCall_viiiiiffii, dynCall_iifif: dynCall_iifif, dynCall_iiiii: dynCall_iiiii, dynCall_viii: dynCall_viii, dynCall_viifi: dynCall_viifi, dynCall_v: dynCall_v, dynCall_viif: dynCall_viif, dynCall_iiif: dynCall_iiif, dynCall_fiiifii: dynCall_fiiifii, dynCall_viiii: dynCall_viiii };
michael@0 54444 };
michael@0 54445
michael@0 54446 var ffis = { "abort": abort, "assert": assert, "asmPrintInt": asmPrintInt, "asmPrintFloat": asmPrintFloat, "min": Math_min, "invoke_iiiiiiii": invoke_iiiiiiii, "invoke_vif": invoke_vif, "invoke_viifii": invoke_viifii, "invoke_viiiii": invoke_viiiii, "invoke_vi": invoke_vi, "invoke_vii": invoke_vii, "invoke_viiifii": invoke_viiifii, "invoke_vifiii": invoke_vifiii, "invoke_ii": invoke_ii, "invoke_viiiiffffiif": invoke_viiiiffffiif, "invoke_fiii": invoke_fiii, "invoke_viiif": invoke_viiif, "invoke_fiiiiiiiiiii": invoke_fiiiiiiiiiii, "invoke_fiifii": invoke_fiifii, "invoke_iii": invoke_iii, "invoke_iiii": invoke_iiii, "invoke_fif": invoke_fif, "invoke_viiiiiiii": invoke_viiiiiiii, "invoke_vifi": invoke_vifi, "invoke_viiiiii": invoke_viiiiii, "invoke_iiiiiiiiii": invoke_iiiiiiiiii, "invoke_viffiii": invoke_viffiii, "invoke_iiiiiii": invoke_iiiiiii, "invoke_fiiiiiiiiii": invoke_fiiiiiiiiii, "invoke_fiiiii": invoke_fiiiii, "invoke_iiiiiiiiiiii": invoke_iiiiiiiiiiii, "invoke_vifii": invoke_vifii, "invoke_fi": invoke_fi, "invoke_viiiiiiiiii": invoke_viiiiiiiiii, "invoke_viiiifffffif": invoke_viiiifffffif, "invoke_viiiiiffii": invoke_viiiiiffii, "invoke_iifif": invoke_iifif, "invoke_iiiii": invoke_iiiii, "invoke_viii": invoke_viii, "invoke_viifi": invoke_viifi, "invoke_v": invoke_v, "invoke_viif": invoke_viif, "invoke_iiif": invoke_iiif, "invoke_fiiifii": invoke_fiiifii, "invoke_viiii": invoke_viiii, "_llvm_lifetime_end": _llvm_lifetime_end, "_cosf": _cosf, "_fabsf": _fabsf, "_sysconf": _sysconf, "___cxa_throw": ___cxa_throw, "_atexit": _atexit, "_abort": _abort, "_fprintf": _fprintf, "_llvm_eh_exception": _llvm_eh_exception, "_printf": _printf, "_acosf": _acosf, "_fflush": _fflush, "__reallyNegative": __reallyNegative, "_sqrtf": _sqrtf, "_llvm_pow_f32": _llvm_pow_f32, "___setErrNo": ___setErrNo, "_fwrite": _fwrite, "_send": _send, "_write": _write, "_exit": _exit, "_atan2f": _atan2f, "___cxa_pure_virtual": ___cxa_pure_virtual, "___cxa_is_number_type": ___cxa_is_number_type, "_time": _time, "__formatString": __formatString, "___cxa_does_inherit": ___cxa_does_inherit, "___cxa_guard_acquire": ___cxa_guard_acquire, "__ZSt9terminatev": __ZSt9terminatev, "_gettimeofday": _gettimeofday, "___cxa_find_matching_catch": ___cxa_find_matching_catch, "_sinf": _sinf, "___assert_func": ___assert_func, "__ZSt18uncaught_exceptionv": __ZSt18uncaught_exceptionv, "_pwrite": _pwrite, "___cxa_call_unexpected": ___cxa_call_unexpected, "_sbrk": _sbrk, "___cxa_guard_abort": ___cxa_guard_abort, "___cxa_allocate_exception": ___cxa_allocate_exception, "___errno_location": ___errno_location, "___gxx_personality_v0": ___gxx_personality_v0, "_llvm_lifetime_start": _llvm_lifetime_start, "_fmod": _fmod, "___cxa_guard_release": ___cxa_guard_release, "__exit": __exit, "___resumeException": ___resumeException, "STACKTOP": STACKTOP, "STACK_MAX": STACK_MAX, "tempDoublePtr": tempDoublePtr, "ABORT": ABORT, "cttz_i8": cttz_i8, "ctlz_i8": ctlz_i8, "NaN": NaN, "Infinity": Infinity, "__ZTVN10__cxxabiv117__class_type_infoE": __ZTVN10__cxxabiv117__class_type_infoE, "__ZTVN10__cxxabiv120__si_class_type_infoE": __ZTVN10__cxxabiv120__si_class_type_infoE, "___dso_handle": ___dso_handle };
michael@0 54447
michael@0 54448 // Stress-test re-linking by linking once before the "real" one.
michael@0 54449 var throwAway = asmModule(this, ffis, new ArrayBuffer(4*4096));
michael@0 54450
michael@0 54451 var asm = asmModule(this, ffis, buffer);
michael@0 54452 var _strlen = Module["_strlen"] = asm["_strlen"];
michael@0 54453 var _free = Module["_free"] = asm["_free"];
michael@0 54454 var _main = Module["_main"] = asm["_main"];
michael@0 54455 var __GLOBAL__I_a = Module["__GLOBAL__I_a"] = asm["__GLOBAL__I_a"];
michael@0 54456 var _memset = Module["_memset"] = asm["_memset"];
michael@0 54457 var _malloc = Module["_malloc"] = asm["_malloc"];
michael@0 54458 var _memcpy = Module["_memcpy"] = asm["_memcpy"];
michael@0 54459 var _llvm_uadd_with_overflow_i64 = Module["_llvm_uadd_with_overflow_i64"] = asm["_llvm_uadd_with_overflow_i64"];
michael@0 54460 var runPostSets = Module["runPostSets"] = asm["runPostSets"];
michael@0 54461 var dynCall_iiiiiiii = Module["dynCall_iiiiiiii"] = asm["dynCall_iiiiiiii"];
michael@0 54462 var dynCall_vif = Module["dynCall_vif"] = asm["dynCall_vif"];
michael@0 54463 var dynCall_viifii = Module["dynCall_viifii"] = asm["dynCall_viifii"];
michael@0 54464 var dynCall_viiiii = Module["dynCall_viiiii"] = asm["dynCall_viiiii"];
michael@0 54465 var dynCall_vi = Module["dynCall_vi"] = asm["dynCall_vi"];
michael@0 54466 var dynCall_vii = Module["dynCall_vii"] = asm["dynCall_vii"];
michael@0 54467 var dynCall_viiifii = Module["dynCall_viiifii"] = asm["dynCall_viiifii"];
michael@0 54468 var dynCall_vifiii = Module["dynCall_vifiii"] = asm["dynCall_vifiii"];
michael@0 54469 var dynCall_ii = Module["dynCall_ii"] = asm["dynCall_ii"];
michael@0 54470 var dynCall_viiiiffffiif = Module["dynCall_viiiiffffiif"] = asm["dynCall_viiiiffffiif"];
michael@0 54471 var dynCall_fiii = Module["dynCall_fiii"] = asm["dynCall_fiii"];
michael@0 54472 var dynCall_viiif = Module["dynCall_viiif"] = asm["dynCall_viiif"];
michael@0 54473 var dynCall_fiiiiiiiiiii = Module["dynCall_fiiiiiiiiiii"] = asm["dynCall_fiiiiiiiiiii"];
michael@0 54474 var dynCall_fiifii = Module["dynCall_fiifii"] = asm["dynCall_fiifii"];
michael@0 54475 var dynCall_iii = Module["dynCall_iii"] = asm["dynCall_iii"];
michael@0 54476 var dynCall_iiii = Module["dynCall_iiii"] = asm["dynCall_iiii"];
michael@0 54477 var dynCall_fif = Module["dynCall_fif"] = asm["dynCall_fif"];
michael@0 54478 var dynCall_viiiiiiii = Module["dynCall_viiiiiiii"] = asm["dynCall_viiiiiiii"];
michael@0 54479 var dynCall_vifi = Module["dynCall_vifi"] = asm["dynCall_vifi"];
michael@0 54480 var dynCall_viiiiii = Module["dynCall_viiiiii"] = asm["dynCall_viiiiii"];
michael@0 54481 var dynCall_iiiiiiiiii = Module["dynCall_iiiiiiiiii"] = asm["dynCall_iiiiiiiiii"];
michael@0 54482 var dynCall_viffiii = Module["dynCall_viffiii"] = asm["dynCall_viffiii"];
michael@0 54483 var dynCall_iiiiiii = Module["dynCall_iiiiiii"] = asm["dynCall_iiiiiii"];
michael@0 54484 var dynCall_fiiiiiiiiii = Module["dynCall_fiiiiiiiiii"] = asm["dynCall_fiiiiiiiiii"];
michael@0 54485 var dynCall_fiiiii = Module["dynCall_fiiiii"] = asm["dynCall_fiiiii"];
michael@0 54486 var dynCall_iiiiiiiiiiii = Module["dynCall_iiiiiiiiiiii"] = asm["dynCall_iiiiiiiiiiii"];
michael@0 54487 var dynCall_vifii = Module["dynCall_vifii"] = asm["dynCall_vifii"];
michael@0 54488 var dynCall_fi = Module["dynCall_fi"] = asm["dynCall_fi"];
michael@0 54489 var dynCall_viiiiiiiiii = Module["dynCall_viiiiiiiiii"] = asm["dynCall_viiiiiiiiii"];
michael@0 54490 var dynCall_viiiifffffif = Module["dynCall_viiiifffffif"] = asm["dynCall_viiiifffffif"];
michael@0 54491 var dynCall_viiiiiffii = Module["dynCall_viiiiiffii"] = asm["dynCall_viiiiiffii"];
michael@0 54492 var dynCall_iifif = Module["dynCall_iifif"] = asm["dynCall_iifif"];
michael@0 54493 var dynCall_iiiii = Module["dynCall_iiiii"] = asm["dynCall_iiiii"];
michael@0 54494 var dynCall_viii = Module["dynCall_viii"] = asm["dynCall_viii"];
michael@0 54495 var dynCall_viifi = Module["dynCall_viifi"] = asm["dynCall_viifi"];
michael@0 54496 var dynCall_v = Module["dynCall_v"] = asm["dynCall_v"];
michael@0 54497 var dynCall_viif = Module["dynCall_viif"] = asm["dynCall_viif"];
michael@0 54498 var dynCall_iiif = Module["dynCall_iiif"] = asm["dynCall_iiif"];
michael@0 54499 var dynCall_fiiifii = Module["dynCall_fiiifii"] = asm["dynCall_fiiifii"];
michael@0 54500 var dynCall_viiii = Module["dynCall_viiii"] = asm["dynCall_viiii"];
michael@0 54501 Runtime.stackAlloc = function(size) { return asm['stackAlloc'](size) };
michael@0 54502 Runtime.stackSave = function() { return asm['stackSave']() };
michael@0 54503 Runtime.stackRestore = function(top) { asm['stackRestore'](top) };
michael@0 54504 // TODO: strip out parts of this we do not need
michael@0 54505 //======= begin closure i64 code =======
michael@0 54506 // Copyright 2009 The Closure Library Authors. All Rights Reserved.
michael@0 54507 //
michael@0 54508 // Licensed under the Apache License, Version 2.0 (the "License");
michael@0 54509 // you may not use this file except in compliance with the License.
michael@0 54510 // You may obtain a copy of the License at
michael@0 54511 //
michael@0 54512 // http://www.apache.org/licenses/LICENSE-2.0
michael@0 54513 //
michael@0 54514 // Unless required by applicable law or agreed to in writing, software
michael@0 54515 // distributed under the License is distributed on an "AS-IS" BASIS,
michael@0 54516 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
michael@0 54517 // See the License for the specific language governing permissions and
michael@0 54518 // limitations under the License.
michael@0 54519 /**
michael@0 54520 * @fileoverview Defines a Long class for representing a 64-bit two's-complement
michael@0 54521 * integer value, which faithfully simulates the behavior of a Java "long". This
michael@0 54522 * implementation is derived from LongLib in GWT.
michael@0 54523 *
michael@0 54524 */
michael@0 54525 var i64Math = (function() { // Emscripten wrapper
michael@0 54526 var goog = { math: {} };
michael@0 54527 /**
michael@0 54528 * Constructs a 64-bit two's-complement integer, given its low and high 32-bit
michael@0 54529 * values as *signed* integers. See the from* functions below for more
michael@0 54530 * convenient ways of constructing Longs.
michael@0 54531 *
michael@0 54532 * The internal representation of a long is the two given signed, 32-bit values.
michael@0 54533 * We use 32-bit pieces because these are the size of integers on which
michael@0 54534 * Javascript performs bit-operations. For operations like addition and
michael@0 54535 * multiplication, we split each number into 16-bit pieces, which can easily be
michael@0 54536 * multiplied within Javascript's floating-point representation without overflow
michael@0 54537 * or change in sign.
michael@0 54538 *
michael@0 54539 * In the algorithms below, we frequently reduce the negative case to the
michael@0 54540 * positive case by negating the input(s) and then post-processing the result.
michael@0 54541 * Note that we must ALWAYS check specially whether those values are MIN_VALUE
michael@0 54542 * (-2^63) because -MIN_VALUE == MIN_VALUE (since 2^63 cannot be represented as
michael@0 54543 * a positive number, it overflows back into a negative). Not handling this
michael@0 54544 * case would often result in infinite recursion.
michael@0 54545 *
michael@0 54546 * @param {number} low The low (signed) 32 bits of the long.
michael@0 54547 * @param {number} high The high (signed) 32 bits of the long.
michael@0 54548 * @constructor
michael@0 54549 */
michael@0 54550 goog.math.Long = function(low, high) {
michael@0 54551 /**
michael@0 54552 * @type {number}
michael@0 54553 * @private
michael@0 54554 */
michael@0 54555 this.low_ = low | 0; // force into 32 signed bits.
michael@0 54556 /**
michael@0 54557 * @type {number}
michael@0 54558 * @private
michael@0 54559 */
michael@0 54560 this.high_ = high | 0; // force into 32 signed bits.
michael@0 54561 };
michael@0 54562 // NOTE: Common constant values ZERO, ONE, NEG_ONE, etc. are defined below the
michael@0 54563 // from* methods on which they depend.
michael@0 54564 /**
michael@0 54565 * A cache of the Long representations of small integer values.
michael@0 54566 * @type {!Object}
michael@0 54567 * @private
michael@0 54568 */
michael@0 54569 goog.math.Long.IntCache_ = {};
michael@0 54570 /**
michael@0 54571 * Returns a Long representing the given (32-bit) integer value.
michael@0 54572 * @param {number} value The 32-bit integer in question.
michael@0 54573 * @return {!goog.math.Long} The corresponding Long value.
michael@0 54574 */
michael@0 54575 goog.math.Long.fromInt = function(value) {
michael@0 54576 if (-128 <= value && value < 128) {
michael@0 54577 var cachedObj = goog.math.Long.IntCache_[value];
michael@0 54578 if (cachedObj) {
michael@0 54579 return cachedObj;
michael@0 54580 }
michael@0 54581 }
michael@0 54582 var obj = new goog.math.Long(value | 0, value < 0 ? -1 : 0);
michael@0 54583 if (-128 <= value && value < 128) {
michael@0 54584 goog.math.Long.IntCache_[value] = obj;
michael@0 54585 }
michael@0 54586 return obj;
michael@0 54587 };
michael@0 54588 /**
michael@0 54589 * Returns a Long representing the given value, provided that it is a finite
michael@0 54590 * number. Otherwise, zero is returned.
michael@0 54591 * @param {number} value The number in question.
michael@0 54592 * @return {!goog.math.Long} The corresponding Long value.
michael@0 54593 */
michael@0 54594 goog.math.Long.fromNumber = function(value) {
michael@0 54595 if (isNaN(value) || !isFinite(value)) {
michael@0 54596 return goog.math.Long.ZERO;
michael@0 54597 } else if (value <= -goog.math.Long.TWO_PWR_63_DBL_) {
michael@0 54598 return goog.math.Long.MIN_VALUE;
michael@0 54599 } else if (value + 1 >= goog.math.Long.TWO_PWR_63_DBL_) {
michael@0 54600 return goog.math.Long.MAX_VALUE;
michael@0 54601 } else if (value < 0) {
michael@0 54602 return goog.math.Long.fromNumber(-value).negate();
michael@0 54603 } else {
michael@0 54604 return new goog.math.Long(
michael@0 54605 (value % goog.math.Long.TWO_PWR_32_DBL_) | 0,
michael@0 54606 (value / goog.math.Long.TWO_PWR_32_DBL_) | 0);
michael@0 54607 }
michael@0 54608 };
michael@0 54609 /**
michael@0 54610 * Returns a Long representing the 64-bit integer that comes by concatenating
michael@0 54611 * the given high and low bits. Each is assumed to use 32 bits.
michael@0 54612 * @param {number} lowBits The low 32-bits.
michael@0 54613 * @param {number} highBits The high 32-bits.
michael@0 54614 * @return {!goog.math.Long} The corresponding Long value.
michael@0 54615 */
michael@0 54616 goog.math.Long.fromBits = function(lowBits, highBits) {
michael@0 54617 return new goog.math.Long(lowBits, highBits);
michael@0 54618 };
michael@0 54619 /**
michael@0 54620 * Returns a Long representation of the given string, written using the given
michael@0 54621 * radix.
michael@0 54622 * @param {string} str The textual representation of the Long.
michael@0 54623 * @param {number=} opt_radix The radix in which the text is written.
michael@0 54624 * @return {!goog.math.Long} The corresponding Long value.
michael@0 54625 */
michael@0 54626 goog.math.Long.fromString = function(str, opt_radix) {
michael@0 54627 if (str.length == 0) {
michael@0 54628 throw Error('number format error: empty string');
michael@0 54629 }
michael@0 54630 var radix = opt_radix || 10;
michael@0 54631 if (radix < 2 || 36 < radix) {
michael@0 54632 throw Error('radix out of range: ' + radix);
michael@0 54633 }
michael@0 54634 if (str.charAt(0) == '-') {
michael@0 54635 return goog.math.Long.fromString(str.substring(1), radix).negate();
michael@0 54636 } else if (str.indexOf('-') >= 0) {
michael@0 54637 throw Error('number format error: interior "-" character: ' + str);
michael@0 54638 }
michael@0 54639 // Do several (8) digits each time through the loop, so as to
michael@0 54640 // minimize the calls to the very expensive emulated div.
michael@0 54641 var radixToPower = goog.math.Long.fromNumber(Math.pow(radix, 8));
michael@0 54642 var result = goog.math.Long.ZERO;
michael@0 54643 for (var i = 0; i < str.length; i += 8) {
michael@0 54644 var size = Math.min(8, str.length - i);
michael@0 54645 var value = parseInt(str.substring(i, i + size), radix);
michael@0 54646 if (size < 8) {
michael@0 54647 var power = goog.math.Long.fromNumber(Math.pow(radix, size));
michael@0 54648 result = result.multiply(power).add(goog.math.Long.fromNumber(value));
michael@0 54649 } else {
michael@0 54650 result = result.multiply(radixToPower);
michael@0 54651 result = result.add(goog.math.Long.fromNumber(value));
michael@0 54652 }
michael@0 54653 }
michael@0 54654 return result;
michael@0 54655 };
michael@0 54656 // NOTE: the compiler should inline these constant values below and then remove
michael@0 54657 // these variables, so there should be no runtime penalty for these.
michael@0 54658 /**
michael@0 54659 * Number used repeated below in calculations. This must appear before the
michael@0 54660 * first call to any from* function below.
michael@0 54661 * @type {number}
michael@0 54662 * @private
michael@0 54663 */
michael@0 54664 goog.math.Long.TWO_PWR_16_DBL_ = 1 << 16;
michael@0 54665 /**
michael@0 54666 * @type {number}
michael@0 54667 * @private
michael@0 54668 */
michael@0 54669 goog.math.Long.TWO_PWR_24_DBL_ = 1 << 24;
michael@0 54670 /**
michael@0 54671 * @type {number}
michael@0 54672 * @private
michael@0 54673 */
michael@0 54674 goog.math.Long.TWO_PWR_32_DBL_ =
michael@0 54675 goog.math.Long.TWO_PWR_16_DBL_ * goog.math.Long.TWO_PWR_16_DBL_;
michael@0 54676 /**
michael@0 54677 * @type {number}
michael@0 54678 * @private
michael@0 54679 */
michael@0 54680 goog.math.Long.TWO_PWR_31_DBL_ =
michael@0 54681 goog.math.Long.TWO_PWR_32_DBL_ / 2;
michael@0 54682 /**
michael@0 54683 * @type {number}
michael@0 54684 * @private
michael@0 54685 */
michael@0 54686 goog.math.Long.TWO_PWR_48_DBL_ =
michael@0 54687 goog.math.Long.TWO_PWR_32_DBL_ * goog.math.Long.TWO_PWR_16_DBL_;
michael@0 54688 /**
michael@0 54689 * @type {number}
michael@0 54690 * @private
michael@0 54691 */
michael@0 54692 goog.math.Long.TWO_PWR_64_DBL_ =
michael@0 54693 goog.math.Long.TWO_PWR_32_DBL_ * goog.math.Long.TWO_PWR_32_DBL_;
michael@0 54694 /**
michael@0 54695 * @type {number}
michael@0 54696 * @private
michael@0 54697 */
michael@0 54698 goog.math.Long.TWO_PWR_63_DBL_ =
michael@0 54699 goog.math.Long.TWO_PWR_64_DBL_ / 2;
michael@0 54700 /** @type {!goog.math.Long} */
michael@0 54701 goog.math.Long.ZERO = goog.math.Long.fromInt(0);
michael@0 54702 /** @type {!goog.math.Long} */
michael@0 54703 goog.math.Long.ONE = goog.math.Long.fromInt(1);
michael@0 54704 /** @type {!goog.math.Long} */
michael@0 54705 goog.math.Long.NEG_ONE = goog.math.Long.fromInt(-1);
michael@0 54706 /** @type {!goog.math.Long} */
michael@0 54707 goog.math.Long.MAX_VALUE =
michael@0 54708 goog.math.Long.fromBits(0xFFFFFFFF | 0, 0x7FFFFFFF | 0);
michael@0 54709 /** @type {!goog.math.Long} */
michael@0 54710 goog.math.Long.MIN_VALUE = goog.math.Long.fromBits(0, 0x80000000 | 0);
michael@0 54711 /**
michael@0 54712 * @type {!goog.math.Long}
michael@0 54713 * @private
michael@0 54714 */
michael@0 54715 goog.math.Long.TWO_PWR_24_ = goog.math.Long.fromInt(1 << 24);
michael@0 54716 /** @return {number} The value, assuming it is a 32-bit integer. */
michael@0 54717 goog.math.Long.prototype.toInt = function() {
michael@0 54718 return this.low_;
michael@0 54719 };
michael@0 54720 /** @return {number} The closest floating-point representation to this value. */
michael@0 54721 goog.math.Long.prototype.toNumber = function() {
michael@0 54722 return this.high_ * goog.math.Long.TWO_PWR_32_DBL_ +
michael@0 54723 this.getLowBitsUnsigned();
michael@0 54724 };
michael@0 54725 /**
michael@0 54726 * @param {number=} opt_radix The radix in which the text should be written.
michael@0 54727 * @return {string} The textual representation of this value.
michael@0 54728 */
michael@0 54729 goog.math.Long.prototype.toString = function(opt_radix) {
michael@0 54730 var radix = opt_radix || 10;
michael@0 54731 if (radix < 2 || 36 < radix) {
michael@0 54732 throw Error('radix out of range: ' + radix);
michael@0 54733 }
michael@0 54734 if (this.isZero()) {
michael@0 54735 return '0';
michael@0 54736 }
michael@0 54737 if (this.isNegative()) {
michael@0 54738 if (this.equals(goog.math.Long.MIN_VALUE)) {
michael@0 54739 // We need to change the Long value before it can be negated, so we remove
michael@0 54740 // the bottom-most digit in this base and then recurse to do the rest.
michael@0 54741 var radixLong = goog.math.Long.fromNumber(radix);
michael@0 54742 var div = this.div(radixLong);
michael@0 54743 var rem = div.multiply(radixLong).subtract(this);
michael@0 54744 return div.toString(radix) + rem.toInt().toString(radix);
michael@0 54745 } else {
michael@0 54746 return '-' + this.negate().toString(radix);
michael@0 54747 }
michael@0 54748 }
michael@0 54749 // Do several (6) digits each time through the loop, so as to
michael@0 54750 // minimize the calls to the very expensive emulated div.
michael@0 54751 var radixToPower = goog.math.Long.fromNumber(Math.pow(radix, 6));
michael@0 54752 var rem = this;
michael@0 54753 var result = '';
michael@0 54754 while (true) {
michael@0 54755 var remDiv = rem.div(radixToPower);
michael@0 54756 var intval = rem.subtract(remDiv.multiply(radixToPower)).toInt();
michael@0 54757 var digits = intval.toString(radix);
michael@0 54758 rem = remDiv;
michael@0 54759 if (rem.isZero()) {
michael@0 54760 return digits + result;
michael@0 54761 } else {
michael@0 54762 while (digits.length < 6) {
michael@0 54763 digits = '0' + digits;
michael@0 54764 }
michael@0 54765 result = '' + digits + result;
michael@0 54766 }
michael@0 54767 }
michael@0 54768 };
michael@0 54769 /** @return {number} The high 32-bits as a signed value. */
michael@0 54770 goog.math.Long.prototype.getHighBits = function() {
michael@0 54771 return this.high_;
michael@0 54772 };
michael@0 54773 /** @return {number} The low 32-bits as a signed value. */
michael@0 54774 goog.math.Long.prototype.getLowBits = function() {
michael@0 54775 return this.low_;
michael@0 54776 };
michael@0 54777 /** @return {number} The low 32-bits as an unsigned value. */
michael@0 54778 goog.math.Long.prototype.getLowBitsUnsigned = function() {
michael@0 54779 return (this.low_ >= 0) ?
michael@0 54780 this.low_ : goog.math.Long.TWO_PWR_32_DBL_ + this.low_;
michael@0 54781 };
michael@0 54782 /**
michael@0 54783 * @return {number} Returns the number of bits needed to represent the absolute
michael@0 54784 * value of this Long.
michael@0 54785 */
michael@0 54786 goog.math.Long.prototype.getNumBitsAbs = function() {
michael@0 54787 if (this.isNegative()) {
michael@0 54788 if (this.equals(goog.math.Long.MIN_VALUE)) {
michael@0 54789 return 64;
michael@0 54790 } else {
michael@0 54791 return this.negate().getNumBitsAbs();
michael@0 54792 }
michael@0 54793 } else {
michael@0 54794 var val = this.high_ != 0 ? this.high_ : this.low_;
michael@0 54795 for (var bit = 31; bit > 0; bit--) {
michael@0 54796 if ((val & (1 << bit)) != 0) {
michael@0 54797 break;
michael@0 54798 }
michael@0 54799 }
michael@0 54800 return this.high_ != 0 ? bit + 33 : bit + 1;
michael@0 54801 }
michael@0 54802 };
michael@0 54803 /** @return {boolean} Whether this value is zero. */
michael@0 54804 goog.math.Long.prototype.isZero = function() {
michael@0 54805 return this.high_ == 0 && this.low_ == 0;
michael@0 54806 };
michael@0 54807 /** @return {boolean} Whether this value is negative. */
michael@0 54808 goog.math.Long.prototype.isNegative = function() {
michael@0 54809 return this.high_ < 0;
michael@0 54810 };
michael@0 54811 /** @return {boolean} Whether this value is odd. */
michael@0 54812 goog.math.Long.prototype.isOdd = function() {
michael@0 54813 return (this.low_ & 1) == 1;
michael@0 54814 };
michael@0 54815 /**
michael@0 54816 * @param {goog.math.Long} other Long to compare against.
michael@0 54817 * @return {boolean} Whether this Long equals the other.
michael@0 54818 */
michael@0 54819 goog.math.Long.prototype.equals = function(other) {
michael@0 54820 return (this.high_ == other.high_) && (this.low_ == other.low_);
michael@0 54821 };
michael@0 54822 /**
michael@0 54823 * @param {goog.math.Long} other Long to compare against.
michael@0 54824 * @return {boolean} Whether this Long does not equal the other.
michael@0 54825 */
michael@0 54826 goog.math.Long.prototype.notEquals = function(other) {
michael@0 54827 return (this.high_ != other.high_) || (this.low_ != other.low_);
michael@0 54828 };
michael@0 54829 /**
michael@0 54830 * @param {goog.math.Long} other Long to compare against.
michael@0 54831 * @return {boolean} Whether this Long is less than the other.
michael@0 54832 */
michael@0 54833 goog.math.Long.prototype.lessThan = function(other) {
michael@0 54834 return this.compare(other) < 0;
michael@0 54835 };
michael@0 54836 /**
michael@0 54837 * @param {goog.math.Long} other Long to compare against.
michael@0 54838 * @return {boolean} Whether this Long is less than or equal to the other.
michael@0 54839 */
michael@0 54840 goog.math.Long.prototype.lessThanOrEqual = function(other) {
michael@0 54841 return this.compare(other) <= 0;
michael@0 54842 };
michael@0 54843 /**
michael@0 54844 * @param {goog.math.Long} other Long to compare against.
michael@0 54845 * @return {boolean} Whether this Long is greater than the other.
michael@0 54846 */
michael@0 54847 goog.math.Long.prototype.greaterThan = function(other) {
michael@0 54848 return this.compare(other) > 0;
michael@0 54849 };
michael@0 54850 /**
michael@0 54851 * @param {goog.math.Long} other Long to compare against.
michael@0 54852 * @return {boolean} Whether this Long is greater than or equal to the other.
michael@0 54853 */
michael@0 54854 goog.math.Long.prototype.greaterThanOrEqual = function(other) {
michael@0 54855 return this.compare(other) >= 0;
michael@0 54856 };
michael@0 54857 /**
michael@0 54858 * Compares this Long with the given one.
michael@0 54859 * @param {goog.math.Long} other Long to compare against.
michael@0 54860 * @return {number} 0 if they are the same, 1 if the this is greater, and -1
michael@0 54861 * if the given one is greater.
michael@0 54862 */
michael@0 54863 goog.math.Long.prototype.compare = function(other) {
michael@0 54864 if (this.equals(other)) {
michael@0 54865 return 0;
michael@0 54866 }
michael@0 54867 var thisNeg = this.isNegative();
michael@0 54868 var otherNeg = other.isNegative();
michael@0 54869 if (thisNeg && !otherNeg) {
michael@0 54870 return -1;
michael@0 54871 }
michael@0 54872 if (!thisNeg && otherNeg) {
michael@0 54873 return 1;
michael@0 54874 }
michael@0 54875 // at this point, the signs are the same, so subtraction will not overflow
michael@0 54876 if (this.subtract(other).isNegative()) {
michael@0 54877 return -1;
michael@0 54878 } else {
michael@0 54879 return 1;
michael@0 54880 }
michael@0 54881 };
michael@0 54882 /** @return {!goog.math.Long} The negation of this value. */
michael@0 54883 goog.math.Long.prototype.negate = function() {
michael@0 54884 if (this.equals(goog.math.Long.MIN_VALUE)) {
michael@0 54885 return goog.math.Long.MIN_VALUE;
michael@0 54886 } else {
michael@0 54887 return this.not().add(goog.math.Long.ONE);
michael@0 54888 }
michael@0 54889 };
michael@0 54890 /**
michael@0 54891 * Returns the sum of this and the given Long.
michael@0 54892 * @param {goog.math.Long} other Long to add to this one.
michael@0 54893 * @return {!goog.math.Long} The sum of this and the given Long.
michael@0 54894 */
michael@0 54895 goog.math.Long.prototype.add = function(other) {
michael@0 54896 // Divide each number into 4 chunks of 16 bits, and then sum the chunks.
michael@0 54897 var a48 = this.high_ >>> 16;
michael@0 54898 var a32 = this.high_ & 0xFFFF;
michael@0 54899 var a16 = this.low_ >>> 16;
michael@0 54900 var a00 = this.low_ & 0xFFFF;
michael@0 54901 var b48 = other.high_ >>> 16;
michael@0 54902 var b32 = other.high_ & 0xFFFF;
michael@0 54903 var b16 = other.low_ >>> 16;
michael@0 54904 var b00 = other.low_ & 0xFFFF;
michael@0 54905 var c48 = 0, c32 = 0, c16 = 0, c00 = 0;
michael@0 54906 c00 += a00 + b00;
michael@0 54907 c16 += c00 >>> 16;
michael@0 54908 c00 &= 0xFFFF;
michael@0 54909 c16 += a16 + b16;
michael@0 54910 c32 += c16 >>> 16;
michael@0 54911 c16 &= 0xFFFF;
michael@0 54912 c32 += a32 + b32;
michael@0 54913 c48 += c32 >>> 16;
michael@0 54914 c32 &= 0xFFFF;
michael@0 54915 c48 += a48 + b48;
michael@0 54916 c48 &= 0xFFFF;
michael@0 54917 return goog.math.Long.fromBits((c16 << 16) | c00, (c48 << 16) | c32);
michael@0 54918 };
michael@0 54919 /**
michael@0 54920 * Returns the difference of this and the given Long.
michael@0 54921 * @param {goog.math.Long} other Long to subtract from this.
michael@0 54922 * @return {!goog.math.Long} The difference of this and the given Long.
michael@0 54923 */
michael@0 54924 goog.math.Long.prototype.subtract = function(other) {
michael@0 54925 return this.add(other.negate());
michael@0 54926 };
michael@0 54927 /**
michael@0 54928 * Returns the product of this and the given long.
michael@0 54929 * @param {goog.math.Long} other Long to multiply with this.
michael@0 54930 * @return {!goog.math.Long} The product of this and the other.
michael@0 54931 */
michael@0 54932 goog.math.Long.prototype.multiply = function(other) {
michael@0 54933 if (this.isZero()) {
michael@0 54934 return goog.math.Long.ZERO;
michael@0 54935 } else if (other.isZero()) {
michael@0 54936 return goog.math.Long.ZERO;
michael@0 54937 }
michael@0 54938 if (this.equals(goog.math.Long.MIN_VALUE)) {
michael@0 54939 return other.isOdd() ? goog.math.Long.MIN_VALUE : goog.math.Long.ZERO;
michael@0 54940 } else if (other.equals(goog.math.Long.MIN_VALUE)) {
michael@0 54941 return this.isOdd() ? goog.math.Long.MIN_VALUE : goog.math.Long.ZERO;
michael@0 54942 }
michael@0 54943 if (this.isNegative()) {
michael@0 54944 if (other.isNegative()) {
michael@0 54945 return this.negate().multiply(other.negate());
michael@0 54946 } else {
michael@0 54947 return this.negate().multiply(other).negate();
michael@0 54948 }
michael@0 54949 } else if (other.isNegative()) {
michael@0 54950 return this.multiply(other.negate()).negate();
michael@0 54951 }
michael@0 54952 // If both longs are small, use float multiplication
michael@0 54953 if (this.lessThan(goog.math.Long.TWO_PWR_24_) &&
michael@0 54954 other.lessThan(goog.math.Long.TWO_PWR_24_)) {
michael@0 54955 return goog.math.Long.fromNumber(this.toNumber() * other.toNumber());
michael@0 54956 }
michael@0 54957 // Divide each long into 4 chunks of 16 bits, and then add up 4x4 products.
michael@0 54958 // We can skip products that would overflow.
michael@0 54959 var a48 = this.high_ >>> 16;
michael@0 54960 var a32 = this.high_ & 0xFFFF;
michael@0 54961 var a16 = this.low_ >>> 16;
michael@0 54962 var a00 = this.low_ & 0xFFFF;
michael@0 54963 var b48 = other.high_ >>> 16;
michael@0 54964 var b32 = other.high_ & 0xFFFF;
michael@0 54965 var b16 = other.low_ >>> 16;
michael@0 54966 var b00 = other.low_ & 0xFFFF;
michael@0 54967 var c48 = 0, c32 = 0, c16 = 0, c00 = 0;
michael@0 54968 c00 += a00 * b00;
michael@0 54969 c16 += c00 >>> 16;
michael@0 54970 c00 &= 0xFFFF;
michael@0 54971 c16 += a16 * b00;
michael@0 54972 c32 += c16 >>> 16;
michael@0 54973 c16 &= 0xFFFF;
michael@0 54974 c16 += a00 * b16;
michael@0 54975 c32 += c16 >>> 16;
michael@0 54976 c16 &= 0xFFFF;
michael@0 54977 c32 += a32 * b00;
michael@0 54978 c48 += c32 >>> 16;
michael@0 54979 c32 &= 0xFFFF;
michael@0 54980 c32 += a16 * b16;
michael@0 54981 c48 += c32 >>> 16;
michael@0 54982 c32 &= 0xFFFF;
michael@0 54983 c32 += a00 * b32;
michael@0 54984 c48 += c32 >>> 16;
michael@0 54985 c32 &= 0xFFFF;
michael@0 54986 c48 += a48 * b00 + a32 * b16 + a16 * b32 + a00 * b48;
michael@0 54987 c48 &= 0xFFFF;
michael@0 54988 return goog.math.Long.fromBits((c16 << 16) | c00, (c48 << 16) | c32);
michael@0 54989 };
michael@0 54990 /**
michael@0 54991 * Returns this Long divided by the given one.
michael@0 54992 * @param {goog.math.Long} other Long by which to divide.
michael@0 54993 * @return {!goog.math.Long} This Long divided by the given one.
michael@0 54994 */
michael@0 54995 goog.math.Long.prototype.div = function(other) {
michael@0 54996 if (other.isZero()) {
michael@0 54997 throw Error('division by zero');
michael@0 54998 } else if (this.isZero()) {
michael@0 54999 return goog.math.Long.ZERO;
michael@0 55000 }
michael@0 55001 if (this.equals(goog.math.Long.MIN_VALUE)) {
michael@0 55002 if (other.equals(goog.math.Long.ONE) ||
michael@0 55003 other.equals(goog.math.Long.NEG_ONE)) {
michael@0 55004 return goog.math.Long.MIN_VALUE; // recall that -MIN_VALUE == MIN_VALUE
michael@0 55005 } else if (other.equals(goog.math.Long.MIN_VALUE)) {
michael@0 55006 return goog.math.Long.ONE;
michael@0 55007 } else {
michael@0 55008 // At this point, we have |other| >= 2, so |this/other| < |MIN_VALUE|.
michael@0 55009 var halfThis = this.shiftRight(1);
michael@0 55010 var approx = halfThis.div(other).shiftLeft(1);
michael@0 55011 if (approx.equals(goog.math.Long.ZERO)) {
michael@0 55012 return other.isNegative() ? goog.math.Long.ONE : goog.math.Long.NEG_ONE;
michael@0 55013 } else {
michael@0 55014 var rem = this.subtract(other.multiply(approx));
michael@0 55015 var result = approx.add(rem.div(other));
michael@0 55016 return result;
michael@0 55017 }
michael@0 55018 }
michael@0 55019 } else if (other.equals(goog.math.Long.MIN_VALUE)) {
michael@0 55020 return goog.math.Long.ZERO;
michael@0 55021 }
michael@0 55022 if (this.isNegative()) {
michael@0 55023 if (other.isNegative()) {
michael@0 55024 return this.negate().div(other.negate());
michael@0 55025 } else {
michael@0 55026 return this.negate().div(other).negate();
michael@0 55027 }
michael@0 55028 } else if (other.isNegative()) {
michael@0 55029 return this.div(other.negate()).negate();
michael@0 55030 }
michael@0 55031 // Repeat the following until the remainder is less than other: find a
michael@0 55032 // floating-point that approximates remainder / other *from below*, add this
michael@0 55033 // into the result, and subtract it from the remainder. It is critical that
michael@0 55034 // the approximate value is less than or equal to the real value so that the
michael@0 55035 // remainder never becomes negative.
michael@0 55036 var res = goog.math.Long.ZERO;
michael@0 55037 var rem = this;
michael@0 55038 while (rem.greaterThanOrEqual(other)) {
michael@0 55039 // Approximate the result of division. This may be a little greater or
michael@0 55040 // smaller than the actual value.
michael@0 55041 var approx = Math.max(1, Math.floor(rem.toNumber() / other.toNumber()));
michael@0 55042 // We will tweak the approximate result by changing it in the 48-th digit or
michael@0 55043 // the smallest non-fractional digit, whichever is larger.
michael@0 55044 var log2 = Math.ceil(Math.log(approx) / Math.LN2);
michael@0 55045 var delta = (log2 <= 48) ? 1 : Math.pow(2, log2 - 48);
michael@0 55046 // Decrease the approximation until it is smaller than the remainder. Note
michael@0 55047 // that if it is too large, the product overflows and is negative.
michael@0 55048 var approxRes = goog.math.Long.fromNumber(approx);
michael@0 55049 var approxRem = approxRes.multiply(other);
michael@0 55050 while (approxRem.isNegative() || approxRem.greaterThan(rem)) {
michael@0 55051 approx -= delta;
michael@0 55052 approxRes = goog.math.Long.fromNumber(approx);
michael@0 55053 approxRem = approxRes.multiply(other);
michael@0 55054 }
michael@0 55055 // We know the answer can't be zero... and actually, zero would cause
michael@0 55056 // infinite recursion since we would make no progress.
michael@0 55057 if (approxRes.isZero()) {
michael@0 55058 approxRes = goog.math.Long.ONE;
michael@0 55059 }
michael@0 55060 res = res.add(approxRes);
michael@0 55061 rem = rem.subtract(approxRem);
michael@0 55062 }
michael@0 55063 return res;
michael@0 55064 };
michael@0 55065 /**
michael@0 55066 * Returns this Long modulo the given one.
michael@0 55067 * @param {goog.math.Long} other Long by which to mod.
michael@0 55068 * @return {!goog.math.Long} This Long modulo the given one.
michael@0 55069 */
michael@0 55070 goog.math.Long.prototype.modulo = function(other) {
michael@0 55071 return this.subtract(this.div(other).multiply(other));
michael@0 55072 };
michael@0 55073 /** @return {!goog.math.Long} The bitwise-NOT of this value. */
michael@0 55074 goog.math.Long.prototype.not = function() {
michael@0 55075 return goog.math.Long.fromBits(~this.low_, ~this.high_);
michael@0 55076 };
michael@0 55077 /**
michael@0 55078 * Returns the bitwise-AND of this Long and the given one.
michael@0 55079 * @param {goog.math.Long} other The Long with which to AND.
michael@0 55080 * @return {!goog.math.Long} The bitwise-AND of this and the other.
michael@0 55081 */
michael@0 55082 goog.math.Long.prototype.and = function(other) {
michael@0 55083 return goog.math.Long.fromBits(this.low_ & other.low_,
michael@0 55084 this.high_ & other.high_);
michael@0 55085 };
michael@0 55086 /**
michael@0 55087 * Returns the bitwise-OR of this Long and the given one.
michael@0 55088 * @param {goog.math.Long} other The Long with which to OR.
michael@0 55089 * @return {!goog.math.Long} The bitwise-OR of this and the other.
michael@0 55090 */
michael@0 55091 goog.math.Long.prototype.or = function(other) {
michael@0 55092 return goog.math.Long.fromBits(this.low_ | other.low_,
michael@0 55093 this.high_ | other.high_);
michael@0 55094 };
michael@0 55095 /**
michael@0 55096 * Returns the bitwise-XOR of this Long and the given one.
michael@0 55097 * @param {goog.math.Long} other The Long with which to XOR.
michael@0 55098 * @return {!goog.math.Long} The bitwise-XOR of this and the other.
michael@0 55099 */
michael@0 55100 goog.math.Long.prototype.xor = function(other) {
michael@0 55101 return goog.math.Long.fromBits(this.low_ ^ other.low_,
michael@0 55102 this.high_ ^ other.high_);
michael@0 55103 };
michael@0 55104 /**
michael@0 55105 * Returns this Long with bits shifted to the left by the given amount.
michael@0 55106 * @param {number} numBits The number of bits by which to shift.
michael@0 55107 * @return {!goog.math.Long} This shifted to the left by the given amount.
michael@0 55108 */
michael@0 55109 goog.math.Long.prototype.shiftLeft = function(numBits) {
michael@0 55110 numBits &= 63;
michael@0 55111 if (numBits == 0) {
michael@0 55112 return this;
michael@0 55113 } else {
michael@0 55114 var low = this.low_;
michael@0 55115 if (numBits < 32) {
michael@0 55116 var high = this.high_;
michael@0 55117 return goog.math.Long.fromBits(
michael@0 55118 low << numBits,
michael@0 55119 (high << numBits) | (low >>> (32 - numBits)));
michael@0 55120 } else {
michael@0 55121 return goog.math.Long.fromBits(0, low << (numBits - 32));
michael@0 55122 }
michael@0 55123 }
michael@0 55124 };
michael@0 55125 /**
michael@0 55126 * Returns this Long with bits shifted to the right by the given amount.
michael@0 55127 * @param {number} numBits The number of bits by which to shift.
michael@0 55128 * @return {!goog.math.Long} This shifted to the right by the given amount.
michael@0 55129 */
michael@0 55130 goog.math.Long.prototype.shiftRight = function(numBits) {
michael@0 55131 numBits &= 63;
michael@0 55132 if (numBits == 0) {
michael@0 55133 return this;
michael@0 55134 } else {
michael@0 55135 var high = this.high_;
michael@0 55136 if (numBits < 32) {
michael@0 55137 var low = this.low_;
michael@0 55138 return goog.math.Long.fromBits(
michael@0 55139 (low >>> numBits) | (high << (32 - numBits)),
michael@0 55140 high >> numBits);
michael@0 55141 } else {
michael@0 55142 return goog.math.Long.fromBits(
michael@0 55143 high >> (numBits - 32),
michael@0 55144 high >= 0 ? 0 : -1);
michael@0 55145 }
michael@0 55146 }
michael@0 55147 };
michael@0 55148 /**
michael@0 55149 * Returns this Long with bits shifted to the right by the given amount, with
michael@0 55150 * the new top bits matching the current sign bit.
michael@0 55151 * @param {number} numBits The number of bits by which to shift.
michael@0 55152 * @return {!goog.math.Long} This shifted to the right by the given amount, with
michael@0 55153 * zeros placed into the new leading bits.
michael@0 55154 */
michael@0 55155 goog.math.Long.prototype.shiftRightUnsigned = function(numBits) {
michael@0 55156 numBits &= 63;
michael@0 55157 if (numBits == 0) {
michael@0 55158 return this;
michael@0 55159 } else {
michael@0 55160 var high = this.high_;
michael@0 55161 if (numBits < 32) {
michael@0 55162 var low = this.low_;
michael@0 55163 return goog.math.Long.fromBits(
michael@0 55164 (low >>> numBits) | (high << (32 - numBits)),
michael@0 55165 high >>> numBits);
michael@0 55166 } else if (numBits == 32) {
michael@0 55167 return goog.math.Long.fromBits(high, 0);
michael@0 55168 } else {
michael@0 55169 return goog.math.Long.fromBits(high >>> (numBits - 32), 0);
michael@0 55170 }
michael@0 55171 }
michael@0 55172 };
michael@0 55173 //======= begin jsbn =======
michael@0 55174 var navigator = { appName: 'Modern Browser' }; // polyfill a little
michael@0 55175 // Copyright (c) 2005 Tom Wu
michael@0 55176 // All Rights Reserved.
michael@0 55177 // http://www-cs-students.stanford.edu/~tjw/jsbn/
michael@0 55178 /*
michael@0 55179 * Copyright (c) 2003-2005 Tom Wu
michael@0 55180 * All Rights Reserved.
michael@0 55181 *
michael@0 55182 * Permission is hereby granted, free of charge, to any person obtaining
michael@0 55183 * a copy of this software and associated documentation files (the
michael@0 55184 * "Software"), to deal in the Software without restriction, including
michael@0 55185 * without limitation the rights to use, copy, modify, merge, publish,
michael@0 55186 * distribute, sublicense, and/or sell copies of the Software, and to
michael@0 55187 * permit persons to whom the Software is furnished to do so, subject to
michael@0 55188 * the following conditions:
michael@0 55189 *
michael@0 55190 * The above copyright notice and this permission notice shall be
michael@0 55191 * included in all copies or substantial portions of the Software.
michael@0 55192 *
michael@0 55193 * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
michael@0 55194 * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
michael@0 55195 * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
michael@0 55196 *
michael@0 55197 * IN NO EVENT SHALL TOM WU BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
michael@0 55198 * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
michael@0 55199 * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
michael@0 55200 * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT
michael@0 55201 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
michael@0 55202 *
michael@0 55203 * In addition, the following condition applies:
michael@0 55204 *
michael@0 55205 * All redistributions must retain an intact copy of this copyright notice
michael@0 55206 * and disclaimer.
michael@0 55207 */
michael@0 55208 // Basic JavaScript BN library - subset useful for RSA encryption.
michael@0 55209 // Bits per digit
michael@0 55210 var dbits;
michael@0 55211 // JavaScript engine analysis
michael@0 55212 var canary = 0xdeadbeefcafe;
michael@0 55213 var j_lm = ((canary&0xffffff)==0xefcafe);
michael@0 55214 // (public) Constructor
michael@0 55215 function BigInteger(a,b,c) {
michael@0 55216 if(a != null)
michael@0 55217 if("number" == typeof a) this.fromNumber(a,b,c);
michael@0 55218 else if(b == null && "string" != typeof a) this.fromString(a,256);
michael@0 55219 else this.fromString(a,b);
michael@0 55220 }
michael@0 55221 // return new, unset BigInteger
michael@0 55222 function nbi() { return new BigInteger(null); }
michael@0 55223 // am: Compute w_j += (x*this_i), propagate carries,
michael@0 55224 // c is initial carry, returns final carry.
michael@0 55225 // c < 3*dvalue, x < 2*dvalue, this_i < dvalue
michael@0 55226 // We need to select the fastest one that works in this environment.
michael@0 55227 // am1: use a single mult and divide to get the high bits,
michael@0 55228 // max digit bits should be 26 because
michael@0 55229 // max internal value = 2*dvalue^2-2*dvalue (< 2^53)
michael@0 55230 function am1(i,x,w,j,c,n) {
michael@0 55231 while(--n >= 0) {
michael@0 55232 var v = x*this[i++]+w[j]+c;
michael@0 55233 c = Math.floor(v/0x4000000);
michael@0 55234 w[j++] = v&0x3ffffff;
michael@0 55235 }
michael@0 55236 return c;
michael@0 55237 }
michael@0 55238 // am2 avoids a big mult-and-extract completely.
michael@0 55239 // Max digit bits should be <= 30 because we do bitwise ops
michael@0 55240 // on values up to 2*hdvalue^2-hdvalue-1 (< 2^31)
michael@0 55241 function am2(i,x,w,j,c,n) {
michael@0 55242 var xl = x&0x7fff, xh = x>>15;
michael@0 55243 while(--n >= 0) {
michael@0 55244 var l = this[i]&0x7fff;
michael@0 55245 var h = this[i++]>>15;
michael@0 55246 var m = xh*l+h*xl;
michael@0 55247 l = xl*l+((m&0x7fff)<<15)+w[j]+(c&0x3fffffff);
michael@0 55248 c = (l>>>30)+(m>>>15)+xh*h+(c>>>30);
michael@0 55249 w[j++] = l&0x3fffffff;
michael@0 55250 }
michael@0 55251 return c;
michael@0 55252 }
michael@0 55253 // Alternately, set max digit bits to 28 since some
michael@0 55254 // browsers slow down when dealing with 32-bit numbers.
michael@0 55255 function am3(i,x,w,j,c,n) {
michael@0 55256 var xl = x&0x3fff, xh = x>>14;
michael@0 55257 while(--n >= 0) {
michael@0 55258 var l = this[i]&0x3fff;
michael@0 55259 var h = this[i++]>>14;
michael@0 55260 var m = xh*l+h*xl;
michael@0 55261 l = xl*l+((m&0x3fff)<<14)+w[j]+c;
michael@0 55262 c = (l>>28)+(m>>14)+xh*h;
michael@0 55263 w[j++] = l&0xfffffff;
michael@0 55264 }
michael@0 55265 return c;
michael@0 55266 }
michael@0 55267 if(j_lm && (navigator.appName == "Microsoft Internet Explorer")) {
michael@0 55268 BigInteger.prototype.am = am2;
michael@0 55269 dbits = 30;
michael@0 55270 }
michael@0 55271 else if(j_lm && (navigator.appName != "Netscape")) {
michael@0 55272 BigInteger.prototype.am = am1;
michael@0 55273 dbits = 26;
michael@0 55274 }
michael@0 55275 else { // Mozilla/Netscape seems to prefer am3
michael@0 55276 BigInteger.prototype.am = am3;
michael@0 55277 dbits = 28;
michael@0 55278 }
michael@0 55279 BigInteger.prototype.DB = dbits;
michael@0 55280 BigInteger.prototype.DM = ((1<<dbits)-1);
michael@0 55281 BigInteger.prototype.DV = (1<<dbits);
michael@0 55282 var BI_FP = 52;
michael@0 55283 BigInteger.prototype.FV = Math.pow(2,BI_FP);
michael@0 55284 BigInteger.prototype.F1 = BI_FP-dbits;
michael@0 55285 BigInteger.prototype.F2 = 2*dbits-BI_FP;
michael@0 55286 // Digit conversions
michael@0 55287 var BI_RM = "0123456789abcdefghijklmnopqrstuvwxyz";
michael@0 55288 var BI_RC = new Array();
michael@0 55289 var rr,vv;
michael@0 55290 rr = "0".charCodeAt(0);
michael@0 55291 for(vv = 0; vv <= 9; ++vv) BI_RC[rr++] = vv;
michael@0 55292 rr = "a".charCodeAt(0);
michael@0 55293 for(vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv;
michael@0 55294 rr = "A".charCodeAt(0);
michael@0 55295 for(vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv;
michael@0 55296 function int2char(n) { return BI_RM.charAt(n); }
michael@0 55297 function intAt(s,i) {
michael@0 55298 var c = BI_RC[s.charCodeAt(i)];
michael@0 55299 return (c==null)?-1:c;
michael@0 55300 }
michael@0 55301 // (protected) copy this to r
michael@0 55302 function bnpCopyTo(r) {
michael@0 55303 for(var i = this.t-1; i >= 0; --i) r[i] = this[i];
michael@0 55304 r.t = this.t;
michael@0 55305 r.s = this.s;
michael@0 55306 }
michael@0 55307 // (protected) set from integer value x, -DV <= x < DV
michael@0 55308 function bnpFromInt(x) {
michael@0 55309 this.t = 1;
michael@0 55310 this.s = (x<0)?-1:0;
michael@0 55311 if(x > 0) this[0] = x;
michael@0 55312 else if(x < -1) this[0] = x+DV;
michael@0 55313 else this.t = 0;
michael@0 55314 }
michael@0 55315 // return bigint initialized to value
michael@0 55316 function nbv(i) { var r = nbi(); r.fromInt(i); return r; }
michael@0 55317 // (protected) set from string and radix
michael@0 55318 function bnpFromString(s,b) {
michael@0 55319 var k;
michael@0 55320 if(b == 16) k = 4;
michael@0 55321 else if(b == 8) k = 3;
michael@0 55322 else if(b == 256) k = 8; // byte array
michael@0 55323 else if(b == 2) k = 1;
michael@0 55324 else if(b == 32) k = 5;
michael@0 55325 else if(b == 4) k = 2;
michael@0 55326 else { this.fromRadix(s,b); return; }
michael@0 55327 this.t = 0;
michael@0 55328 this.s = 0;
michael@0 55329 var i = s.length, mi = false, sh = 0;
michael@0 55330 while(--i >= 0) {
michael@0 55331 var x = (k==8)?s[i]&0xff:intAt(s,i);
michael@0 55332 if(x < 0) {
michael@0 55333 if(s.charAt(i) == "-") mi = true;
michael@0 55334 continue;
michael@0 55335 }
michael@0 55336 mi = false;
michael@0 55337 if(sh == 0)
michael@0 55338 this[this.t++] = x;
michael@0 55339 else if(sh+k > this.DB) {
michael@0 55340 this[this.t-1] |= (x&((1<<(this.DB-sh))-1))<<sh;
michael@0 55341 this[this.t++] = (x>>(this.DB-sh));
michael@0 55342 }
michael@0 55343 else
michael@0 55344 this[this.t-1] |= x<<sh;
michael@0 55345 sh += k;
michael@0 55346 if(sh >= this.DB) sh -= this.DB;
michael@0 55347 }
michael@0 55348 if(k == 8 && (s[0]&0x80) != 0) {
michael@0 55349 this.s = -1;
michael@0 55350 if(sh > 0) this[this.t-1] |= ((1<<(this.DB-sh))-1)<<sh;
michael@0 55351 }
michael@0 55352 this.clamp();
michael@0 55353 if(mi) BigInteger.ZERO.subTo(this,this);
michael@0 55354 }
michael@0 55355 // (protected) clamp off excess high words
michael@0 55356 function bnpClamp() {
michael@0 55357 var c = this.s&this.DM;
michael@0 55358 while(this.t > 0 && this[this.t-1] == c) --this.t;
michael@0 55359 }
michael@0 55360 // (public) return string representation in given radix
michael@0 55361 function bnToString(b) {
michael@0 55362 if(this.s < 0) return "-"+this.negate().toString(b);
michael@0 55363 var k;
michael@0 55364 if(b == 16) k = 4;
michael@0 55365 else if(b == 8) k = 3;
michael@0 55366 else if(b == 2) k = 1;
michael@0 55367 else if(b == 32) k = 5;
michael@0 55368 else if(b == 4) k = 2;
michael@0 55369 else return this.toRadix(b);
michael@0 55370 var km = (1<<k)-1, d, m = false, r = "", i = this.t;
michael@0 55371 var p = this.DB-(i*this.DB)%k;
michael@0 55372 if(i-- > 0) {
michael@0 55373 if(p < this.DB && (d = this[i]>>p) > 0) { m = true; r = int2char(d); }
michael@0 55374 while(i >= 0) {
michael@0 55375 if(p < k) {
michael@0 55376 d = (this[i]&((1<<p)-1))<<(k-p);
michael@0 55377 d |= this[--i]>>(p+=this.DB-k);
michael@0 55378 }
michael@0 55379 else {
michael@0 55380 d = (this[i]>>(p-=k))&km;
michael@0 55381 if(p <= 0) { p += this.DB; --i; }
michael@0 55382 }
michael@0 55383 if(d > 0) m = true;
michael@0 55384 if(m) r += int2char(d);
michael@0 55385 }
michael@0 55386 }
michael@0 55387 return m?r:"0";
michael@0 55388 }
michael@0 55389 // (public) -this
michael@0 55390 function bnNegate() { var r = nbi(); BigInteger.ZERO.subTo(this,r); return r; }
michael@0 55391 // (public) |this|
michael@0 55392 function bnAbs() { return (this.s<0)?this.negate():this; }
michael@0 55393 // (public) return + if this > a, - if this < a, 0 if equal
michael@0 55394 function bnCompareTo(a) {
michael@0 55395 var r = this.s-a.s;
michael@0 55396 if(r != 0) return r;
michael@0 55397 var i = this.t;
michael@0 55398 r = i-a.t;
michael@0 55399 if(r != 0) return (this.s<0)?-r:r;
michael@0 55400 while(--i >= 0) if((r=this[i]-a[i]) != 0) return r;
michael@0 55401 return 0;
michael@0 55402 }
michael@0 55403 // returns bit length of the integer x
michael@0 55404 function nbits(x) {
michael@0 55405 var r = 1, t;
michael@0 55406 if((t=x>>>16) != 0) { x = t; r += 16; }
michael@0 55407 if((t=x>>8) != 0) { x = t; r += 8; }
michael@0 55408 if((t=x>>4) != 0) { x = t; r += 4; }
michael@0 55409 if((t=x>>2) != 0) { x = t; r += 2; }
michael@0 55410 if((t=x>>1) != 0) { x = t; r += 1; }
michael@0 55411 return r;
michael@0 55412 }
michael@0 55413 // (public) return the number of bits in "this"
michael@0 55414 function bnBitLength() {
michael@0 55415 if(this.t <= 0) return 0;
michael@0 55416 return this.DB*(this.t-1)+nbits(this[this.t-1]^(this.s&this.DM));
michael@0 55417 }
michael@0 55418 // (protected) r = this << n*DB
michael@0 55419 function bnpDLShiftTo(n,r) {
michael@0 55420 var i;
michael@0 55421 for(i = this.t-1; i >= 0; --i) r[i+n] = this[i];
michael@0 55422 for(i = n-1; i >= 0; --i) r[i] = 0;
michael@0 55423 r.t = this.t+n;
michael@0 55424 r.s = this.s;
michael@0 55425 }
michael@0 55426 // (protected) r = this >> n*DB
michael@0 55427 function bnpDRShiftTo(n,r) {
michael@0 55428 for(var i = n; i < this.t; ++i) r[i-n] = this[i];
michael@0 55429 r.t = Math.max(this.t-n,0);
michael@0 55430 r.s = this.s;
michael@0 55431 }
michael@0 55432 // (protected) r = this << n
michael@0 55433 function bnpLShiftTo(n,r) {
michael@0 55434 var bs = n%this.DB;
michael@0 55435 var cbs = this.DB-bs;
michael@0 55436 var bm = (1<<cbs)-1;
michael@0 55437 var ds = Math.floor(n/this.DB), c = (this.s<<bs)&this.DM, i;
michael@0 55438 for(i = this.t-1; i >= 0; --i) {
michael@0 55439 r[i+ds+1] = (this[i]>>cbs)|c;
michael@0 55440 c = (this[i]&bm)<<bs;
michael@0 55441 }
michael@0 55442 for(i = ds-1; i >= 0; --i) r[i] = 0;
michael@0 55443 r[ds] = c;
michael@0 55444 r.t = this.t+ds+1;
michael@0 55445 r.s = this.s;
michael@0 55446 r.clamp();
michael@0 55447 }
michael@0 55448 // (protected) r = this >> n
michael@0 55449 function bnpRShiftTo(n,r) {
michael@0 55450 r.s = this.s;
michael@0 55451 var ds = Math.floor(n/this.DB);
michael@0 55452 if(ds >= this.t) { r.t = 0; return; }
michael@0 55453 var bs = n%this.DB;
michael@0 55454 var cbs = this.DB-bs;
michael@0 55455 var bm = (1<<bs)-1;
michael@0 55456 r[0] = this[ds]>>bs;
michael@0 55457 for(var i = ds+1; i < this.t; ++i) {
michael@0 55458 r[i-ds-1] |= (this[i]&bm)<<cbs;
michael@0 55459 r[i-ds] = this[i]>>bs;
michael@0 55460 }
michael@0 55461 if(bs > 0) r[this.t-ds-1] |= (this.s&bm)<<cbs;
michael@0 55462 r.t = this.t-ds;
michael@0 55463 r.clamp();
michael@0 55464 }
michael@0 55465 // (protected) r = this - a
michael@0 55466 function bnpSubTo(a,r) {
michael@0 55467 var i = 0, c = 0, m = Math.min(a.t,this.t);
michael@0 55468 while(i < m) {
michael@0 55469 c += this[i]-a[i];
michael@0 55470 r[i++] = c&this.DM;
michael@0 55471 c >>= this.DB;
michael@0 55472 }
michael@0 55473 if(a.t < this.t) {
michael@0 55474 c -= a.s;
michael@0 55475 while(i < this.t) {
michael@0 55476 c += this[i];
michael@0 55477 r[i++] = c&this.DM;
michael@0 55478 c >>= this.DB;
michael@0 55479 }
michael@0 55480 c += this.s;
michael@0 55481 }
michael@0 55482 else {
michael@0 55483 c += this.s;
michael@0 55484 while(i < a.t) {
michael@0 55485 c -= a[i];
michael@0 55486 r[i++] = c&this.DM;
michael@0 55487 c >>= this.DB;
michael@0 55488 }
michael@0 55489 c -= a.s;
michael@0 55490 }
michael@0 55491 r.s = (c<0)?-1:0;
michael@0 55492 if(c < -1) r[i++] = this.DV+c;
michael@0 55493 else if(c > 0) r[i++] = c;
michael@0 55494 r.t = i;
michael@0 55495 r.clamp();
michael@0 55496 }
michael@0 55497 // (protected) r = this * a, r != this,a (HAC 14.12)
michael@0 55498 // "this" should be the larger one if appropriate.
michael@0 55499 function bnpMultiplyTo(a,r) {
michael@0 55500 var x = this.abs(), y = a.abs();
michael@0 55501 var i = x.t;
michael@0 55502 r.t = i+y.t;
michael@0 55503 while(--i >= 0) r[i] = 0;
michael@0 55504 for(i = 0; i < y.t; ++i) r[i+x.t] = x.am(0,y[i],r,i,0,x.t);
michael@0 55505 r.s = 0;
michael@0 55506 r.clamp();
michael@0 55507 if(this.s != a.s) BigInteger.ZERO.subTo(r,r);
michael@0 55508 }
michael@0 55509 // (protected) r = this^2, r != this (HAC 14.16)
michael@0 55510 function bnpSquareTo(r) {
michael@0 55511 var x = this.abs();
michael@0 55512 var i = r.t = 2*x.t;
michael@0 55513 while(--i >= 0) r[i] = 0;
michael@0 55514 for(i = 0; i < x.t-1; ++i) {
michael@0 55515 var c = x.am(i,x[i],r,2*i,0,1);
michael@0 55516 if((r[i+x.t]+=x.am(i+1,2*x[i],r,2*i+1,c,x.t-i-1)) >= x.DV) {
michael@0 55517 r[i+x.t] -= x.DV;
michael@0 55518 r[i+x.t+1] = 1;
michael@0 55519 }
michael@0 55520 }
michael@0 55521 if(r.t > 0) r[r.t-1] += x.am(i,x[i],r,2*i,0,1);
michael@0 55522 r.s = 0;
michael@0 55523 r.clamp();
michael@0 55524 }
michael@0 55525 // (protected) divide this by m, quotient and remainder to q, r (HAC 14.20)
michael@0 55526 // r != q, this != m. q or r may be null.
michael@0 55527 function bnpDivRemTo(m,q,r) {
michael@0 55528 var pm = m.abs();
michael@0 55529 if(pm.t <= 0) return;
michael@0 55530 var pt = this.abs();
michael@0 55531 if(pt.t < pm.t) {
michael@0 55532 if(q != null) q.fromInt(0);
michael@0 55533 if(r != null) this.copyTo(r);
michael@0 55534 return;
michael@0 55535 }
michael@0 55536 if(r == null) r = nbi();
michael@0 55537 var y = nbi(), ts = this.s, ms = m.s;
michael@0 55538 var nsh = this.DB-nbits(pm[pm.t-1]); // normalize modulus
michael@0 55539 if(nsh > 0) { pm.lShiftTo(nsh,y); pt.lShiftTo(nsh,r); }
michael@0 55540 else { pm.copyTo(y); pt.copyTo(r); }
michael@0 55541 var ys = y.t;
michael@0 55542 var y0 = y[ys-1];
michael@0 55543 if(y0 == 0) return;
michael@0 55544 var yt = y0*(1<<this.F1)+((ys>1)?y[ys-2]>>this.F2:0);
michael@0 55545 var d1 = this.FV/yt, d2 = (1<<this.F1)/yt, e = 1<<this.F2;
michael@0 55546 var i = r.t, j = i-ys, t = (q==null)?nbi():q;
michael@0 55547 y.dlShiftTo(j,t);
michael@0 55548 if(r.compareTo(t) >= 0) {
michael@0 55549 r[r.t++] = 1;
michael@0 55550 r.subTo(t,r);
michael@0 55551 }
michael@0 55552 BigInteger.ONE.dlShiftTo(ys,t);
michael@0 55553 t.subTo(y,y); // "negative" y so we can replace sub with am later
michael@0 55554 while(y.t < ys) y[y.t++] = 0;
michael@0 55555 while(--j >= 0) {
michael@0 55556 // Estimate quotient digit
michael@0 55557 var qd = (r[--i]==y0)?this.DM:Math.floor(r[i]*d1+(r[i-1]+e)*d2);
michael@0 55558 if((r[i]+=y.am(0,qd,r,j,0,ys)) < qd) { // Try it out
michael@0 55559 y.dlShiftTo(j,t);
michael@0 55560 r.subTo(t,r);
michael@0 55561 while(r[i] < --qd) r.subTo(t,r);
michael@0 55562 }
michael@0 55563 }
michael@0 55564 if(q != null) {
michael@0 55565 r.drShiftTo(ys,q);
michael@0 55566 if(ts != ms) BigInteger.ZERO.subTo(q,q);
michael@0 55567 }
michael@0 55568 r.t = ys;
michael@0 55569 r.clamp();
michael@0 55570 if(nsh > 0) r.rShiftTo(nsh,r); // Denormalize remainder
michael@0 55571 if(ts < 0) BigInteger.ZERO.subTo(r,r);
michael@0 55572 }
michael@0 55573 // (public) this mod a
michael@0 55574 function bnMod(a) {
michael@0 55575 var r = nbi();
michael@0 55576 this.abs().divRemTo(a,null,r);
michael@0 55577 if(this.s < 0 && r.compareTo(BigInteger.ZERO) > 0) a.subTo(r,r);
michael@0 55578 return r;
michael@0 55579 }
michael@0 55580 // Modular reduction using "classic" algorithm
michael@0 55581 function Classic(m) { this.m = m; }
michael@0 55582 function cConvert(x) {
michael@0 55583 if(x.s < 0 || x.compareTo(this.m) >= 0) return x.mod(this.m);
michael@0 55584 else return x;
michael@0 55585 }
michael@0 55586 function cRevert(x) { return x; }
michael@0 55587 function cReduce(x) { x.divRemTo(this.m,null,x); }
michael@0 55588 function cMulTo(x,y,r) { x.multiplyTo(y,r); this.reduce(r); }
michael@0 55589 function cSqrTo(x,r) { x.squareTo(r); this.reduce(r); }
michael@0 55590 Classic.prototype.convert = cConvert;
michael@0 55591 Classic.prototype.revert = cRevert;
michael@0 55592 Classic.prototype.reduce = cReduce;
michael@0 55593 Classic.prototype.mulTo = cMulTo;
michael@0 55594 Classic.prototype.sqrTo = cSqrTo;
michael@0 55595 // (protected) return "-1/this % 2^DB"; useful for Mont. reduction
michael@0 55596 // justification:
michael@0 55597 // xy == 1 (mod m)
michael@0 55598 // xy = 1+km
michael@0 55599 // xy(2-xy) = (1+km)(1-km)
michael@0 55600 // x[y(2-xy)] = 1-k^2m^2
michael@0 55601 // x[y(2-xy)] == 1 (mod m^2)
michael@0 55602 // if y is 1/x mod m, then y(2-xy) is 1/x mod m^2
michael@0 55603 // should reduce x and y(2-xy) by m^2 at each step to keep size bounded.
michael@0 55604 // JS multiply "overflows" differently from C/C++, so care is needed here.
michael@0 55605 function bnpInvDigit() {
michael@0 55606 if(this.t < 1) return 0;
michael@0 55607 var x = this[0];
michael@0 55608 if((x&1) == 0) return 0;
michael@0 55609 var y = x&3; // y == 1/x mod 2^2
michael@0 55610 y = (y*(2-(x&0xf)*y))&0xf; // y == 1/x mod 2^4
michael@0 55611 y = (y*(2-(x&0xff)*y))&0xff; // y == 1/x mod 2^8
michael@0 55612 y = (y*(2-(((x&0xffff)*y)&0xffff)))&0xffff; // y == 1/x mod 2^16
michael@0 55613 // last step - calculate inverse mod DV directly;
michael@0 55614 // assumes 16 < DB <= 32 and assumes ability to handle 48-bit ints
michael@0 55615 y = (y*(2-x*y%this.DV))%this.DV; // y == 1/x mod 2^dbits
michael@0 55616 // we really want the negative inverse, and -DV < y < DV
michael@0 55617 return (y>0)?this.DV-y:-y;
michael@0 55618 }
michael@0 55619 // Montgomery reduction
michael@0 55620 function Montgomery(m) {
michael@0 55621 this.m = m;
michael@0 55622 this.mp = m.invDigit();
michael@0 55623 this.mpl = this.mp&0x7fff;
michael@0 55624 this.mph = this.mp>>15;
michael@0 55625 this.um = (1<<(m.DB-15))-1;
michael@0 55626 this.mt2 = 2*m.t;
michael@0 55627 }
michael@0 55628 // xR mod m
michael@0 55629 function montConvert(x) {
michael@0 55630 var r = nbi();
michael@0 55631 x.abs().dlShiftTo(this.m.t,r);
michael@0 55632 r.divRemTo(this.m,null,r);
michael@0 55633 if(x.s < 0 && r.compareTo(BigInteger.ZERO) > 0) this.m.subTo(r,r);
michael@0 55634 return r;
michael@0 55635 }
michael@0 55636 // x/R mod m
michael@0 55637 function montRevert(x) {
michael@0 55638 var r = nbi();
michael@0 55639 x.copyTo(r);
michael@0 55640 this.reduce(r);
michael@0 55641 return r;
michael@0 55642 }
michael@0 55643 // x = x/R mod m (HAC 14.32)
michael@0 55644 function montReduce(x) {
michael@0 55645 while(x.t <= this.mt2) // pad x so am has enough room later
michael@0 55646 x[x.t++] = 0;
michael@0 55647 for(var i = 0; i < this.m.t; ++i) {
michael@0 55648 // faster way of calculating u0 = x[i]*mp mod DV
michael@0 55649 var j = x[i]&0x7fff;
michael@0 55650 var u0 = (j*this.mpl+(((j*this.mph+(x[i]>>15)*this.mpl)&this.um)<<15))&x.DM;
michael@0 55651 // use am to combine the multiply-shift-add into one call
michael@0 55652 j = i+this.m.t;
michael@0 55653 x[j] += this.m.am(0,u0,x,i,0,this.m.t);
michael@0 55654 // propagate carry
michael@0 55655 while(x[j] >= x.DV) { x[j] -= x.DV; x[++j]++; }
michael@0 55656 }
michael@0 55657 x.clamp();
michael@0 55658 x.drShiftTo(this.m.t,x);
michael@0 55659 if(x.compareTo(this.m) >= 0) x.subTo(this.m,x);
michael@0 55660 }
michael@0 55661 // r = "x^2/R mod m"; x != r
michael@0 55662 function montSqrTo(x,r) { x.squareTo(r); this.reduce(r); }
michael@0 55663 // r = "xy/R mod m"; x,y != r
michael@0 55664 function montMulTo(x,y,r) { x.multiplyTo(y,r); this.reduce(r); }
michael@0 55665 Montgomery.prototype.convert = montConvert;
michael@0 55666 Montgomery.prototype.revert = montRevert;
michael@0 55667 Montgomery.prototype.reduce = montReduce;
michael@0 55668 Montgomery.prototype.mulTo = montMulTo;
michael@0 55669 Montgomery.prototype.sqrTo = montSqrTo;
michael@0 55670 // (protected) true iff this is even
michael@0 55671 function bnpIsEven() { return ((this.t>0)?(this[0]&1):this.s) == 0; }
michael@0 55672 // (protected) this^e, e < 2^32, doing sqr and mul with "r" (HAC 14.79)
michael@0 55673 function bnpExp(e,z) {
michael@0 55674 if(e > 0xffffffff || e < 1) return BigInteger.ONE;
michael@0 55675 var r = nbi(), r2 = nbi(), g = z.convert(this), i = nbits(e)-1;
michael@0 55676 g.copyTo(r);
michael@0 55677 while(--i >= 0) {
michael@0 55678 z.sqrTo(r,r2);
michael@0 55679 if((e&(1<<i)) > 0) z.mulTo(r2,g,r);
michael@0 55680 else { var t = r; r = r2; r2 = t; }
michael@0 55681 }
michael@0 55682 return z.revert(r);
michael@0 55683 }
michael@0 55684 // (public) this^e % m, 0 <= e < 2^32
michael@0 55685 function bnModPowInt(e,m) {
michael@0 55686 var z;
michael@0 55687 if(e < 256 || m.isEven()) z = new Classic(m); else z = new Montgomery(m);
michael@0 55688 return this.exp(e,z);
michael@0 55689 }
michael@0 55690 // protected
michael@0 55691 BigInteger.prototype.copyTo = bnpCopyTo;
michael@0 55692 BigInteger.prototype.fromInt = bnpFromInt;
michael@0 55693 BigInteger.prototype.fromString = bnpFromString;
michael@0 55694 BigInteger.prototype.clamp = bnpClamp;
michael@0 55695 BigInteger.prototype.dlShiftTo = bnpDLShiftTo;
michael@0 55696 BigInteger.prototype.drShiftTo = bnpDRShiftTo;
michael@0 55697 BigInteger.prototype.lShiftTo = bnpLShiftTo;
michael@0 55698 BigInteger.prototype.rShiftTo = bnpRShiftTo;
michael@0 55699 BigInteger.prototype.subTo = bnpSubTo;
michael@0 55700 BigInteger.prototype.multiplyTo = bnpMultiplyTo;
michael@0 55701 BigInteger.prototype.squareTo = bnpSquareTo;
michael@0 55702 BigInteger.prototype.divRemTo = bnpDivRemTo;
michael@0 55703 BigInteger.prototype.invDigit = bnpInvDigit;
michael@0 55704 BigInteger.prototype.isEven = bnpIsEven;
michael@0 55705 BigInteger.prototype.exp = bnpExp;
michael@0 55706 // public
michael@0 55707 BigInteger.prototype.toString = bnToString;
michael@0 55708 BigInteger.prototype.negate = bnNegate;
michael@0 55709 BigInteger.prototype.abs = bnAbs;
michael@0 55710 BigInteger.prototype.compareTo = bnCompareTo;
michael@0 55711 BigInteger.prototype.bitLength = bnBitLength;
michael@0 55712 BigInteger.prototype.mod = bnMod;
michael@0 55713 BigInteger.prototype.modPowInt = bnModPowInt;
michael@0 55714 // "constants"
michael@0 55715 BigInteger.ZERO = nbv(0);
michael@0 55716 BigInteger.ONE = nbv(1);
michael@0 55717 // jsbn2 stuff
michael@0 55718 // (protected) convert from radix string
michael@0 55719 function bnpFromRadix(s,b) {
michael@0 55720 this.fromInt(0);
michael@0 55721 if(b == null) b = 10;
michael@0 55722 var cs = this.chunkSize(b);
michael@0 55723 var d = Math.pow(b,cs), mi = false, j = 0, w = 0;
michael@0 55724 for(var i = 0; i < s.length; ++i) {
michael@0 55725 var x = intAt(s,i);
michael@0 55726 if(x < 0) {
michael@0 55727 if(s.charAt(i) == "-" && this.signum() == 0) mi = true;
michael@0 55728 continue;
michael@0 55729 }
michael@0 55730 w = b*w+x;
michael@0 55731 if(++j >= cs) {
michael@0 55732 this.dMultiply(d);
michael@0 55733 this.dAddOffset(w,0);
michael@0 55734 j = 0;
michael@0 55735 w = 0;
michael@0 55736 }
michael@0 55737 }
michael@0 55738 if(j > 0) {
michael@0 55739 this.dMultiply(Math.pow(b,j));
michael@0 55740 this.dAddOffset(w,0);
michael@0 55741 }
michael@0 55742 if(mi) BigInteger.ZERO.subTo(this,this);
michael@0 55743 }
michael@0 55744 // (protected) return x s.t. r^x < DV
michael@0 55745 function bnpChunkSize(r) { return Math.floor(Math.LN2*this.DB/Math.log(r)); }
michael@0 55746 // (public) 0 if this == 0, 1 if this > 0
michael@0 55747 function bnSigNum() {
michael@0 55748 if(this.s < 0) return -1;
michael@0 55749 else if(this.t <= 0 || (this.t == 1 && this[0] <= 0)) return 0;
michael@0 55750 else return 1;
michael@0 55751 }
michael@0 55752 // (protected) this *= n, this >= 0, 1 < n < DV
michael@0 55753 function bnpDMultiply(n) {
michael@0 55754 this[this.t] = this.am(0,n-1,this,0,0,this.t);
michael@0 55755 ++this.t;
michael@0 55756 this.clamp();
michael@0 55757 }
michael@0 55758 // (protected) this += n << w words, this >= 0
michael@0 55759 function bnpDAddOffset(n,w) {
michael@0 55760 if(n == 0) return;
michael@0 55761 while(this.t <= w) this[this.t++] = 0;
michael@0 55762 this[w] += n;
michael@0 55763 while(this[w] >= this.DV) {
michael@0 55764 this[w] -= this.DV;
michael@0 55765 if(++w >= this.t) this[this.t++] = 0;
michael@0 55766 ++this[w];
michael@0 55767 }
michael@0 55768 }
michael@0 55769 // (protected) convert to radix string
michael@0 55770 function bnpToRadix(b) {
michael@0 55771 if(b == null) b = 10;
michael@0 55772 if(this.signum() == 0 || b < 2 || b > 36) return "0";
michael@0 55773 var cs = this.chunkSize(b);
michael@0 55774 var a = Math.pow(b,cs);
michael@0 55775 var d = nbv(a), y = nbi(), z = nbi(), r = "";
michael@0 55776 this.divRemTo(d,y,z);
michael@0 55777 while(y.signum() > 0) {
michael@0 55778 r = (a+z.intValue()).toString(b).substr(1) + r;
michael@0 55779 y.divRemTo(d,y,z);
michael@0 55780 }
michael@0 55781 return z.intValue().toString(b) + r;
michael@0 55782 }
michael@0 55783 // (public) return value as integer
michael@0 55784 function bnIntValue() {
michael@0 55785 if(this.s < 0) {
michael@0 55786 if(this.t == 1) return this[0]-this.DV;
michael@0 55787 else if(this.t == 0) return -1;
michael@0 55788 }
michael@0 55789 else if(this.t == 1) return this[0];
michael@0 55790 else if(this.t == 0) return 0;
michael@0 55791 // assumes 16 < DB < 32
michael@0 55792 return ((this[1]&((1<<(32-this.DB))-1))<<this.DB)|this[0];
michael@0 55793 }
michael@0 55794 // (protected) r = this + a
michael@0 55795 function bnpAddTo(a,r) {
michael@0 55796 var i = 0, c = 0, m = Math.min(a.t,this.t);
michael@0 55797 while(i < m) {
michael@0 55798 c += this[i]+a[i];
michael@0 55799 r[i++] = c&this.DM;
michael@0 55800 c >>= this.DB;
michael@0 55801 }
michael@0 55802 if(a.t < this.t) {
michael@0 55803 c += a.s;
michael@0 55804 while(i < this.t) {
michael@0 55805 c += this[i];
michael@0 55806 r[i++] = c&this.DM;
michael@0 55807 c >>= this.DB;
michael@0 55808 }
michael@0 55809 c += this.s;
michael@0 55810 }
michael@0 55811 else {
michael@0 55812 c += this.s;
michael@0 55813 while(i < a.t) {
michael@0 55814 c += a[i];
michael@0 55815 r[i++] = c&this.DM;
michael@0 55816 c >>= this.DB;
michael@0 55817 }
michael@0 55818 c += a.s;
michael@0 55819 }
michael@0 55820 r.s = (c<0)?-1:0;
michael@0 55821 if(c > 0) r[i++] = c;
michael@0 55822 else if(c < -1) r[i++] = this.DV+c;
michael@0 55823 r.t = i;
michael@0 55824 r.clamp();
michael@0 55825 }
michael@0 55826 BigInteger.prototype.fromRadix = bnpFromRadix;
michael@0 55827 BigInteger.prototype.chunkSize = bnpChunkSize;
michael@0 55828 BigInteger.prototype.signum = bnSigNum;
michael@0 55829 BigInteger.prototype.dMultiply = bnpDMultiply;
michael@0 55830 BigInteger.prototype.dAddOffset = bnpDAddOffset;
michael@0 55831 BigInteger.prototype.toRadix = bnpToRadix;
michael@0 55832 BigInteger.prototype.intValue = bnIntValue;
michael@0 55833 BigInteger.prototype.addTo = bnpAddTo;
michael@0 55834 //======= end jsbn =======
michael@0 55835 // Emscripten wrapper
michael@0 55836 var Wrapper = {
michael@0 55837 abs: function(l, h) {
michael@0 55838 var x = new goog.math.Long(l, h);
michael@0 55839 var ret;
michael@0 55840 if (x.isNegative()) {
michael@0 55841 ret = x.negate();
michael@0 55842 } else {
michael@0 55843 ret = x;
michael@0 55844 }
michael@0 55845 HEAP32[tempDoublePtr>>2] = ret.low_;
michael@0 55846 HEAP32[tempDoublePtr+4>>2] = ret.high_;
michael@0 55847 },
michael@0 55848 ensureTemps: function() {
michael@0 55849 if (Wrapper.ensuredTemps) return;
michael@0 55850 Wrapper.ensuredTemps = true;
michael@0 55851 Wrapper.two32 = new BigInteger();
michael@0 55852 Wrapper.two32.fromString('4294967296', 10);
michael@0 55853 Wrapper.two64 = new BigInteger();
michael@0 55854 Wrapper.two64.fromString('18446744073709551616', 10);
michael@0 55855 Wrapper.temp1 = new BigInteger();
michael@0 55856 Wrapper.temp2 = new BigInteger();
michael@0 55857 },
michael@0 55858 lh2bignum: function(l, h) {
michael@0 55859 var a = new BigInteger();
michael@0 55860 a.fromString(h.toString(), 10);
michael@0 55861 var b = new BigInteger();
michael@0 55862 a.multiplyTo(Wrapper.two32, b);
michael@0 55863 var c = new BigInteger();
michael@0 55864 c.fromString(l.toString(), 10);
michael@0 55865 var d = new BigInteger();
michael@0 55866 c.addTo(b, d);
michael@0 55867 return d;
michael@0 55868 },
michael@0 55869 stringify: function(l, h, unsigned) {
michael@0 55870 var ret = new goog.math.Long(l, h).toString();
michael@0 55871 if (unsigned && ret[0] == '-') {
michael@0 55872 // unsign slowly using jsbn bignums
michael@0 55873 Wrapper.ensureTemps();
michael@0 55874 var bignum = new BigInteger();
michael@0 55875 bignum.fromString(ret, 10);
michael@0 55876 ret = new BigInteger();
michael@0 55877 Wrapper.two64.addTo(bignum, ret);
michael@0 55878 ret = ret.toString(10);
michael@0 55879 }
michael@0 55880 return ret;
michael@0 55881 },
michael@0 55882 fromString: function(str, base, min, max, unsigned) {
michael@0 55883 Wrapper.ensureTemps();
michael@0 55884 var bignum = new BigInteger();
michael@0 55885 bignum.fromString(str, base);
michael@0 55886 var bigmin = new BigInteger();
michael@0 55887 bigmin.fromString(min, 10);
michael@0 55888 var bigmax = new BigInteger();
michael@0 55889 bigmax.fromString(max, 10);
michael@0 55890 if (unsigned && bignum.compareTo(BigInteger.ZERO) < 0) {
michael@0 55891 var temp = new BigInteger();
michael@0 55892 bignum.addTo(Wrapper.two64, temp);
michael@0 55893 bignum = temp;
michael@0 55894 }
michael@0 55895 var error = false;
michael@0 55896 if (bignum.compareTo(bigmin) < 0) {
michael@0 55897 bignum = bigmin;
michael@0 55898 error = true;
michael@0 55899 } else if (bignum.compareTo(bigmax) > 0) {
michael@0 55900 bignum = bigmax;
michael@0 55901 error = true;
michael@0 55902 }
michael@0 55903 var ret = goog.math.Long.fromString(bignum.toString()); // min-max checks should have clamped this to a range goog.math.Long can handle well
michael@0 55904 HEAP32[tempDoublePtr>>2] = ret.low_;
michael@0 55905 HEAP32[tempDoublePtr+4>>2] = ret.high_;
michael@0 55906 if (error) throw 'range error';
michael@0 55907 }
michael@0 55908 };
michael@0 55909 return Wrapper;
michael@0 55910 })();
michael@0 55911 //======= end closure i64 code =======
michael@0 55912 // === Auto-generated postamble setup entry stuff ===
michael@0 55913 function ExitStatus(status) {
michael@0 55914 this.name = "ExitStatus";
michael@0 55915 this.message = "Program terminated with exit(" + status + ")";
michael@0 55916 this.status = status;
michael@0 55917 };
michael@0 55918 ExitStatus.prototype = new Error();
michael@0 55919 ExitStatus.prototype.constructor = ExitStatus;
michael@0 55920 function exit(status) {
michael@0 55921 ABORT = true;
michael@0 55922 EXITSTATUS = status;
michael@0 55923 STACKTOP = initialStackTop;
michael@0 55924 // exit the runtime
michael@0 55925 exitRuntime();
michael@0 55926 // TODO We should handle this differently based on environment.
michael@0 55927 // In the browser, the best we can do is throw an exception
michael@0 55928 // to halt execution, but in node we could process.exit and
michael@0 55929 // I'd imagine SM shell would have something equivalent.
michael@0 55930 // This would let us set a proper exit status (which
michael@0 55931 // would be great for checking test exit statuses).
michael@0 55932 // https://github.com/kripken/emscripten/issues/1371
michael@0 55933 // throw an exception to halt the current execution
michael@0 55934 throw new ExitStatus(status);
michael@0 55935 }
michael@0 55936 Module['exit'] = Module.exit = exit;
michael@0 55937 function abort(text) {
michael@0 55938 if (text) {
michael@0 55939 Module.print(text);
michael@0 55940 Module.printErr(text);
michael@0 55941 }
michael@0 55942 ABORT = true;
michael@0 55943 EXITSTATUS = 1;
michael@0 55944 throw 'abort() at ' + (new Error().stack);
michael@0 55945 }
michael@0 55946 Module['abort'] = Module.abort = abort;
michael@0 55947
michael@0 55948 var initialStackTop;
michael@0 55949 var calledMain = false;
michael@0 55950 Module['callMain'] = Module.callMain = function callMain(args) {
michael@0 55951 assert(runDependencies == 0, 'cannot call main when async dependencies remain! (listen on __ATMAIN__)');
michael@0 55952 assert(__ATPRERUN__.length == 0, 'cannot call main when preRun functions remain to be called');
michael@0 55953 args = args || [];
michael@0 55954 ensureInitRuntime();
michael@0 55955 var argc = args.length+1;
michael@0 55956 function pad() {
michael@0 55957 for (var i = 0; i < 4-1; i++) {
michael@0 55958 argv.push(0);
michael@0 55959 }
michael@0 55960 }
michael@0 55961 var argv = [allocate(intArrayFromString("/bin/this.program"), 'i8', ALLOC_NORMAL) ];
michael@0 55962 pad();
michael@0 55963 for (var i = 0; i < argc-1; i = i + 1) {
michael@0 55964 argv.push(allocate(intArrayFromString(args[i]), 'i8', ALLOC_NORMAL));
michael@0 55965 pad();
michael@0 55966 }
michael@0 55967 argv.push(0);
michael@0 55968 argv = allocate(argv, 'i32', ALLOC_NORMAL);
michael@0 55969 initialStackTop = STACKTOP;
michael@0 55970 try {
michael@0 55971 var ret = Module['_main'](argc, argv, 0);
michael@0 55972 // if we're not running an evented main loop, it's time to exit
michael@0 55973 if (!Module['noExitRuntime']) {
michael@0 55974 exit(ret);
michael@0 55975 }
michael@0 55976 }
michael@0 55977 catch(e) {
michael@0 55978 if (e instanceof ExitStatus) {
michael@0 55979 // exit() throws this once it's done to make sure execution
michael@0 55980 // has been stopped completely
michael@0 55981 return;
michael@0 55982 } else if (e == 'SimulateInfiniteLoop') {
michael@0 55983 // running an evented main loop, don't immediately exit
michael@0 55984 Module['noExitRuntime'] = true;
michael@0 55985 return;
michael@0 55986 } else {
michael@0 55987 throw e;
michael@0 55988 }
michael@0 55989 } finally {
michael@0 55990 calledMain = true;
michael@0 55991 }
michael@0 55992 }
michael@0 55993 function runBullet() {
michael@0 55994 assertEq(printedOutput, "");
michael@0 55995 assertEq(runDependencies > 0, false);
michael@0 55996 preRun();
michael@0 55997 assertEq(runDependencies > 0, false);
michael@0 55998 ensureInitRuntime();
michael@0 55999 preMain();
michael@0 56000 Module['callMain']([]);
michael@0 56001 postRun();
michael@0 56002
michael@0 56003 // This is a canned demo which prints the final positions of all the objects.
michael@0 56004 assertEq(printedOutput, "world pos = 2.00,10.00,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.99,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.98,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.97,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.96,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.94,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.92,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.90,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.88,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.85,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.82,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.78,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.75,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.71,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.67,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.62,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.57,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.52,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.47,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.42,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.36,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.30,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.23,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.17,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.10,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,9.02,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.95,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.87,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.79,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.71,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.62,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.53,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.44,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.35,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.25,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.15,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,8.05,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.94,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.83,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.72,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.61,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.49,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.37,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.25,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.13,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,7.00,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,6.87,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,6.73,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,6.60,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,6.46,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,6.32,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,6.17,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,6.03,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,5.88,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,5.72,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,5.57,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,5.41,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,5.25,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,5.08,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,4.92,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,4.75,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,4.58,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,4.40,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,4.22,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,4.04,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,3.86,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,3.67,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,3.48,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,3.29,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,3.10,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,2.90,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,2.70,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,2.50,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,2.29,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,2.08,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,1.87,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,1.66,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,1.44,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,1.22,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,1.00,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,0.77,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,0.55,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,0.32,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,0.08,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-0.15,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-0.39,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-0.63,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-0.88,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-1.13,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-1.38,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-1.63,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-1.88,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-2.14,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-2.40,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-2.67,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-2.93,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-3.20,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-3.48,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-3.75,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.03,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.31,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.59,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.88,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.17,0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.13,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.10,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.08,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.05,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.03,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.01,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.99,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.98,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.97,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.96,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.95,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.95,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.95,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.95,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.96,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.97,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.98,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-4.99,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00world pos = 2.00,-5.00,-0.00world pos = 0.00,-56.00,0.00");
michael@0 56005 printedOutput = "";
michael@0 56006
michael@0 56007 // Let the caller decide what should have happened.
michael@0 56008 return {
michael@0 56009 asmJSValidated: isAsmJSModule(asmModule) && isAsmJSFunction(asm._main),
michael@0 56010 loadedFromCache: isAsmJSModule(asmModule) && isAsmJSModuleLoadedFromCache(asmModule)
michael@0 56011 }
michael@0 56012 }

mercurial