MarchingCubes.js 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909
  1. /**
  2. * @author alteredq / http://alteredqualia.com/
  3. *
  4. * Port of greggman's ThreeD version of marching cubes to Three.js
  5. * http://webglsamples.googlecode.com/hg/blob/blob.html
  6. */
  7. // do not crash if somebody includes the file in oldie browser
  8. if ( !window.Int32Array ) {
  9. window.Int32Array = Array;
  10. window.Float32Array = Array;
  11. }
  12. THREE.MarchingCubes = function ( resolution, materials ) {
  13. THREE.Object3D.call( this );
  14. this.materials = materials instanceof Array ? materials : [ materials ];
  15. // functions have to be object properties
  16. // prototype functions kill performance
  17. // (tested and it was 4x slower !!!)
  18. this.init = function( resolution ) {
  19. // parameters
  20. this.isolation = 80.0;
  21. // size of field, 32 is pushing it in Javascript :)
  22. this.size = resolution;
  23. this.size2 = this.size * this.size;
  24. this.size3 = this.size2 * this.size;
  25. this.halfsize = this.size / 2.0;
  26. // deltas
  27. this.delta = 2.0 / this.size;
  28. this.yd = this.size;
  29. this.zd = this.size2;
  30. this.field = new Float32Array( this.size3 );
  31. this.normal_cache = new Float32Array( this.size3 * 3 );
  32. // temp buffers used in polygonize
  33. this.vlist = new Float32Array( 12 * 3 );
  34. this.nlist = new Float32Array( 12 * 3 );
  35. this.firstDraw = true;
  36. // immediate render mode simulator
  37. this.maxCount = 4096; // TODO: find the fastest size for this buffer
  38. this.count = 0;
  39. this.hasPos = false;
  40. this.hasNormal = false;
  41. this.positionArray = new Float32Array( this.maxCount * 3 );
  42. this.normalArray = new Float32Array( this.maxCount * 3 );
  43. };
  44. ///////////////////////
  45. // Polygonization
  46. ///////////////////////
  47. this.lerp = function( a, b, t ) { return a + ( b - a ) * t; };
  48. this.VIntX = function( q, pout, nout, offset, isol, x, y, z, valp1, valp2 ) {
  49. var mu = ( isol - valp1 ) / ( valp2 - valp1 ),
  50. nc = this.normal_cache;
  51. pout[ offset ] = x + mu * this.delta;
  52. pout[ offset + 1 ] = y;
  53. pout[ offset + 2 ] = z;
  54. nout[ offset ] = this.lerp( nc[ q ], nc[ q + 3 ], mu );
  55. nout[ offset + 1 ] = this.lerp( nc[ q + 1 ], nc[ q + 4 ], mu );
  56. nout[ offset + 2 ] = this.lerp( nc[ q + 2 ], nc[ q + 5 ], mu );
  57. };
  58. this.VIntY = function( q, pout, nout, offset, isol, x, y, z, valp1, valp2 ) {
  59. var mu = ( isol - valp1 ) / ( valp2 - valp1 ),
  60. nc = this.normal_cache;
  61. pout[ offset ] = x;
  62. pout[ offset + 1 ] = y + mu * this.delta;
  63. pout[ offset + 2 ] = z;
  64. var q2 = q + this.yd * 3;
  65. nout[ offset ] = this.lerp( nc[ q ], nc[ q2 ], mu );
  66. nout[ offset + 1 ] = this.lerp( nc[ q + 1 ], nc[ q2 + 1 ], mu );
  67. nout[ offset + 2 ] = this.lerp( nc[ q + 2 ], nc[ q2 + 2 ], mu );
  68. };
  69. this.VIntZ = function( q, pout, nout, offset, isol, x, y, z, valp1, valp2 ) {
  70. var mu = ( isol - valp1 ) / ( valp2 - valp1 ),
  71. nc = this.normal_cache;
  72. pout[ offset ] = x;
  73. pout[ offset + 1 ] = y;
  74. pout[ offset + 2 ] = z + mu * this.delta;
  75. var q2 = q + this.zd * 3;
  76. nout[ offset ] = this.lerp( nc[ q ], nc[ q2 ], mu );
  77. nout[ offset + 1 ] = this.lerp( nc[ q + 1 ], nc[ q2 + 1 ], mu );
  78. nout[ offset + 2 ] = this.lerp( nc[ q + 2 ], nc[ q2 + 2 ], mu );
  79. };
  80. this.compNorm = function( q ) {
  81. var q3 = q * 3;
  82. if ( this.normal_cache [ q3 ] == 0.0 ) {
  83. this.normal_cache[ q3 ] = this.field[ q - 1 ] - this.field[ q + 1 ];
  84. this.normal_cache[ q3 + 1 ] = this.field[ q - this.yd ] - this.field[ q + this.yd ];
  85. this.normal_cache[ q3 + 2 ] = this.field[ q - this.zd ] - this.field[ q + this.zd ];
  86. }
  87. };
  88. // Returns total number of triangles. Fills triangles.
  89. // (this is where most of time is spent - it's inner work of O(n3) loop )
  90. this.polygonize = function( fx, fy, fz, q, isol, render_callback ) {
  91. // cache indices
  92. var q1 = q + 1,
  93. qy = q + this.yd,
  94. qz = q + this.zd,
  95. q1y = q1 + this.yd,
  96. q1z = q1 + this.zd,
  97. qyz = q + this.yd + this.zd,
  98. q1yz = q1 + this.yd + this.zd;
  99. var cubeindex = 0,
  100. field0 = this.field[ q ],
  101. field1 = this.field[ q1 ],
  102. field2 = this.field[ qy ],
  103. field3 = this.field[ q1y ],
  104. field4 = this.field[ qz ],
  105. field5 = this.field[ q1z ],
  106. field6 = this.field[ qyz ],
  107. field7 = this.field[ q1yz ];
  108. if ( field0 < isol ) cubeindex |= 1;
  109. if ( field1 < isol ) cubeindex |= 2;
  110. if ( field2 < isol ) cubeindex |= 8;
  111. if ( field3 < isol ) cubeindex |= 4;
  112. if ( field4 < isol ) cubeindex |= 16;
  113. if ( field5 < isol ) cubeindex |= 32;
  114. if ( field6 < isol ) cubeindex |= 128;
  115. if ( field7 < isol ) cubeindex |= 64;
  116. // if cube is entirely in/out of the surface - bail, nothing to draw
  117. var bits = THREE.edgeTable[ cubeindex ];
  118. if ( bits == 0 ) return 0;
  119. var d = this.delta,
  120. fx2 = fx + d,
  121. fy2 = fy + d,
  122. fz2 = fz + d;
  123. // top of the cube
  124. if ( bits & 1 ) {
  125. this.compNorm( q );
  126. this.compNorm( q1 );
  127. this.VIntX( q * 3, this.vlist, this.nlist, 0, isol, fx, fy, fz, field0, field1 );
  128. };
  129. if ( bits & 2 ) {
  130. this.compNorm( q1 );
  131. this.compNorm( q1y );
  132. this.VIntY( q1 * 3, this.vlist, this.nlist, 3, isol, fx2, fy, fz, field1, field3 );
  133. };
  134. if ( bits & 4 ) {
  135. this.compNorm( qy );
  136. this.compNorm( q1y );
  137. this.VIntX( qy * 3, this.vlist, this.nlist, 6, isol, fx, fy2, fz, field2, field3 );
  138. };
  139. if ( bits & 8 ) {
  140. this.compNorm( q );
  141. this.compNorm( qy );
  142. this.VIntY( q * 3, this.vlist, this.nlist, 9, isol, fx, fy, fz, field0, field2 );
  143. };
  144. // bottom of the cube
  145. if ( bits & 16 ) {
  146. this.compNorm( qz );
  147. this.compNorm( q1z );
  148. this.VIntX( qz * 3, this.vlist, this.nlist, 12, isol, fx, fy, fz2, field4, field5 );
  149. };
  150. if ( bits & 32 ) {
  151. this.compNorm( q1z );
  152. this.compNorm( q1yz );
  153. this.VIntY( q1z * 3, this.vlist, this.nlist, 15, isol, fx2, fy, fz2, field5, field7 );
  154. };
  155. if ( bits & 64 ) {
  156. this.compNorm( qyz );
  157. this.compNorm( q1yz );
  158. this.VIntX( qyz * 3, this.vlist, this.nlist, 18, isol, fx, fy2, fz2, field6, field7 );
  159. };
  160. if ( bits & 128 ) {
  161. this.compNorm( qz );
  162. this.compNorm( qyz );
  163. this.VIntY( qz * 3, this.vlist, this.nlist, 21, isol, fx, fy, fz2, field4, field6 );
  164. };
  165. // vertical lines of the cube
  166. if ( bits & 256 ) {
  167. this.compNorm( q );
  168. this.compNorm( qz );
  169. this.VIntZ( q * 3, this.vlist, this.nlist, 24, isol, fx, fy, fz, field0, field4 );
  170. };
  171. if ( bits & 512 ) {
  172. this.compNorm( q1 );
  173. this.compNorm( q1z );
  174. this.VIntZ( q1 * 3, this.vlist, this.nlist, 27, isol, fx2, fy, fz, field1, field5 );
  175. };
  176. if ( bits & 1024 ) {
  177. this.compNorm( q1y );
  178. this.compNorm( q1yz );
  179. this.VIntZ( q1y * 3, this.vlist, this.nlist, 30, isol, fx2, fy2, fz, field3, field7 );
  180. };
  181. if ( bits & 2048 ) {
  182. this.compNorm( qy );
  183. this.compNorm( qyz );
  184. this.VIntZ( qy * 3, this.vlist, this.nlist, 33, isol, fx, fy2, fz, field2, field6 );
  185. };
  186. cubeindex <<= 4; // re-purpose cubeindex into an offset into triTable
  187. var o1, o2, o3, numtris = 0, i = 0;
  188. // here is where triangles are created
  189. while ( THREE.triTable[ cubeindex + i ] != -1 ) {
  190. o1 = cubeindex + i;
  191. o2 = o1 + 1;
  192. o3 = o1 + 2;
  193. this.posnormtriv( this.vlist, this.nlist,
  194. 3 * THREE.triTable[ o1 ],
  195. 3 * THREE.triTable[ o2 ],
  196. 3 * THREE.triTable[ o3 ],
  197. render_callback );
  198. i += 3;
  199. numtris ++;
  200. }
  201. return numtris;
  202. };
  203. /////////////////////////////////////
  204. // Immediate render mode simulator
  205. /////////////////////////////////////
  206. this.posnormtriv = function( pos, norm, o1, o2, o3,render_callback ) {
  207. var c = this.count * 3;
  208. this.positionArray[ c ] = pos[ o1 ];
  209. this.positionArray[ c + 1 ] = pos[ o1 + 1 ];
  210. this.positionArray[ c + 2 ] = pos[ o1 + 2 ];
  211. this.positionArray[ c + 3 ] = pos[ o2 ];
  212. this.positionArray[ c + 4 ] = pos[ o2 + 1 ];
  213. this.positionArray[ c + 5 ] = pos[ o2 + 2 ];
  214. this.positionArray[ c + 6 ] = pos[ o3 ];
  215. this.positionArray[ c + 7 ] = pos[ o3 + 1 ];
  216. this.positionArray[ c + 8 ] = pos[ o3 + 2 ];
  217. this.normalArray[ c ] = norm[ o1 ];
  218. this.normalArray[ c + 1 ] = norm[ o1 + 1 ];
  219. this.normalArray[ c + 2 ] = norm[ o1 + 2 ];
  220. this.normalArray[ c + 3 ] = norm[ o2 ];
  221. this.normalArray[ c + 4 ] = norm[ o2 + 1 ];
  222. this.normalArray[ c + 5 ] = norm[ o2 + 2 ];
  223. this.normalArray[ c + 6 ] = norm[ o3 ];
  224. this.normalArray[ c + 7 ] = norm[ o3 + 1 ];
  225. this.normalArray[ c + 8 ] = norm[ o3 + 2 ];
  226. this.hasPos = true;
  227. this.hasNormal = true;
  228. this.count += 3;
  229. if ( this.count >= this.maxCount - 3 ) {
  230. render_callback( this );
  231. }
  232. };
  233. this.begin = function( ) {
  234. this.count = 0;
  235. this.hasPos = false;
  236. this.hasNormal = false;
  237. };
  238. this.end = function( render_callback ) {
  239. if ( this.count == 0 )
  240. return;
  241. for ( var i = this.count * 3; i < this.positionArray.length; i++ )
  242. this.positionArray[ i ] = 0.0;
  243. render_callback( this );
  244. };
  245. /////////////////////////////////////
  246. // Metaballs
  247. /////////////////////////////////////
  248. // Adds a reciprocal ball (nice and blobby) that, to be fast, fades to zero after
  249. // a fixed distance, determined by strength and subtract.
  250. this.addBall = function( ballx, bally, ballz, strength, subtract ) {
  251. // Let's solve the equation to find the radius:
  252. // 1.0 / (0.000001 + radius^2) * strength - subtract = 0
  253. // strength / (radius^2) = subtract
  254. // strength = subtract * radius^2
  255. // radius^2 = strength / subtract
  256. // radius = sqrt(strength / subtract)
  257. var radius = this.size * Math.sqrt( strength / subtract ),
  258. zs = ballz * this.size,
  259. ys = bally * this.size,
  260. xs = ballx * this.size;
  261. var min_z = Math.floor( zs - radius ); if ( min_z < 1 ) min_z = 1;
  262. var max_z = Math.floor( zs + radius ); if ( max_z > this.size - 1 ) max_z = this.size - 1;
  263. var min_y = Math.floor( ys - radius ); if ( min_y < 1 ) min_y = 1;
  264. var max_y = Math.floor( ys + radius ); if ( max_y > this.size - 1 ) max_y = this.size - 1;
  265. var min_x = Math.floor( xs - radius ); if ( min_x < 1 ) min_x = 1;
  266. var max_x = Math.floor( xs + radius ); if ( max_x > this.size - 1 ) max_x = this.size - 1;
  267. // Don't polygonize in the outer layer because normals aren't
  268. // well-defined there.
  269. var x, y, z, y_offset, z_offset, fx, fy, fz, fz2, fy2, val;
  270. for ( z = min_z; z < max_z; z++ ) {
  271. z_offset = this.size * this.size * z,
  272. fz = z / this.size - ballz,
  273. fz2 = fz * fz;
  274. for ( y = min_y; y < max_y; y++ ) {
  275. y_offset = z_offset + this.size * y;
  276. fy = y / this.size - bally;
  277. fy2 = fy * fy;
  278. for ( x = min_x; x < max_x; x++ ) {
  279. fx = x / this.size - ballx;
  280. val = strength / ( 0.000001 + fx*fx + fy2 + fz2 ) - subtract;
  281. if ( val > 0.0 ) this.field[ y_offset + x ] += val;
  282. }
  283. }
  284. }
  285. };
  286. this.addPlaneX = function( strength, subtract ) {
  287. var x, y, z, xx, val, xdiv, cxy,
  288. // cache attribute lookups
  289. size = this.size,
  290. yd = this.yd,
  291. zd = this.zd,
  292. field = this.field,
  293. dist = size * Math.sqrt( strength / subtract );
  294. if ( dist > size ) dist = size;
  295. for ( x = 0; x < dist; x++ ) {
  296. xdiv = x / size;
  297. xx = xdiv * xdiv;
  298. val = strength / ( 0.0001 + xx ) - subtract;
  299. if ( val > 0.0 ) {
  300. for ( y = 0; y < size; y++ ) {
  301. cxy = x + y * yd;
  302. for ( z = 0; z < size; z++ )
  303. field[ zd * z + cxy ] += val;
  304. }
  305. }
  306. }
  307. };
  308. this.addPlaneY = function( strength, subtract ) {
  309. var x, y, z, yy, val, ydiv, cy, cxy,
  310. // cache attribute lookups
  311. size = this.size,
  312. yd = this.yd,
  313. zd = this.zd,
  314. field = this.field,
  315. dist = size * Math.sqrt( strength / subtract );
  316. if ( dist > size ) dist = size;
  317. for ( y = 0; y < dist; y++ ) {
  318. ydiv = y / size;
  319. yy = ydiv * ydiv;
  320. val = strength / ( 0.0001 + yy ) - subtract;
  321. if ( val > 0.0 ) {
  322. cy = y * yd;
  323. for ( x = 0; x < size; x++ ) {
  324. cxy = cy + x;
  325. for ( z = 0; z < size; z++ )
  326. field[ zd * z + cxy ] += val;
  327. }
  328. }
  329. }
  330. };
  331. this.addPlaneZ = function( strength, subtract ) {
  332. var x, y, z, zz, val, zdiv, cz, cyz;
  333. // cache attribute lookups
  334. size = this.size,
  335. yd = this.yd,
  336. zd = this.zd,
  337. field = this.field,
  338. dist = size * Math.sqrt( strength / subtract );
  339. if ( dist > size ) dist = size;
  340. for ( z = 0; z < dist; z++ ) {
  341. zdiv = z / size;
  342. zz = zdiv * zdiv;
  343. val = strength / ( 0.0001 + zz ) - subtract;
  344. if ( val > 0.0 ) {
  345. cz = zd * z;
  346. for ( y = 0; y < size; y++ ) {
  347. cyz = cz + y * yd;
  348. for ( x = 0; x < size; x++ )
  349. field[ cyz + x ] += val;
  350. }
  351. }
  352. }
  353. };
  354. /////////////////////////////////////
  355. // Updates
  356. /////////////////////////////////////
  357. this.reset = function() {
  358. var i;
  359. // wipe the normal cache
  360. for ( i = 0; i < this.size3; i++ ) {
  361. this.normal_cache[ i * 3 ] = 0.0;
  362. this.field[ i ] = 0.0;
  363. }
  364. };
  365. this.render = function( render_callback ) {
  366. this.begin();
  367. // Triangulate. Yeah, this is slow.
  368. var q, x, y, z, fx, fy, fz, y_offset, z_offset, smin2 = this.size - 2;
  369. for ( z = 1; z < smin2; z++ ) {
  370. z_offset = this.size2 * z;
  371. fz = ( z - this.halfsize ) / this.halfsize; //+ 1
  372. for ( y = 1; y < smin2; y++ ) {
  373. y_offset = z_offset + this.size * y;
  374. fy = ( y - this.halfsize ) / this.halfsize; //+ 1
  375. for ( x = 1; x < smin2; x++ ) {
  376. fx = ( x - this.halfsize ) / this.halfsize; //+ 1
  377. q = y_offset + x;
  378. this.polygonize( fx, fy, fz, q, this.isolation, render_callback );
  379. }
  380. }
  381. }
  382. this.end( render_callback );
  383. };
  384. this.init( resolution );
  385. };
  386. THREE.MarchingCubes.prototype = new THREE.Object3D();
  387. THREE.MarchingCubes.prototype.constructor = THREE.MarchingCubes;
  388. /////////////////////////////////////
  389. // Marching cubes lookup tables
  390. /////////////////////////////////////
  391. // These tables are straight from Paul Bourke's page:
  392. // http://local.wasp.uwa.edu.au/~pbourke/geometry/polygonise/
  393. // who in turn got them from Cory Gene Bloyd.
  394. THREE.edgeTable = new Int32Array([
  395. 0x0 , 0x109, 0x203, 0x30a, 0x406, 0x50f, 0x605, 0x70c,
  396. 0x80c, 0x905, 0xa0f, 0xb06, 0xc0a, 0xd03, 0xe09, 0xf00,
  397. 0x190, 0x99 , 0x393, 0x29a, 0x596, 0x49f, 0x795, 0x69c,
  398. 0x99c, 0x895, 0xb9f, 0xa96, 0xd9a, 0xc93, 0xf99, 0xe90,
  399. 0x230, 0x339, 0x33 , 0x13a, 0x636, 0x73f, 0x435, 0x53c,
  400. 0xa3c, 0xb35, 0x83f, 0x936, 0xe3a, 0xf33, 0xc39, 0xd30,
  401. 0x3a0, 0x2a9, 0x1a3, 0xaa , 0x7a6, 0x6af, 0x5a5, 0x4ac,
  402. 0xbac, 0xaa5, 0x9af, 0x8a6, 0xfaa, 0xea3, 0xda9, 0xca0,
  403. 0x460, 0x569, 0x663, 0x76a, 0x66 , 0x16f, 0x265, 0x36c,
  404. 0xc6c, 0xd65, 0xe6f, 0xf66, 0x86a, 0x963, 0xa69, 0xb60,
  405. 0x5f0, 0x4f9, 0x7f3, 0x6fa, 0x1f6, 0xff , 0x3f5, 0x2fc,
  406. 0xdfc, 0xcf5, 0xfff, 0xef6, 0x9fa, 0x8f3, 0xbf9, 0xaf0,
  407. 0x650, 0x759, 0x453, 0x55a, 0x256, 0x35f, 0x55 , 0x15c,
  408. 0xe5c, 0xf55, 0xc5f, 0xd56, 0xa5a, 0xb53, 0x859, 0x950,
  409. 0x7c0, 0x6c9, 0x5c3, 0x4ca, 0x3c6, 0x2cf, 0x1c5, 0xcc ,
  410. 0xfcc, 0xec5, 0xdcf, 0xcc6, 0xbca, 0xac3, 0x9c9, 0x8c0,
  411. 0x8c0, 0x9c9, 0xac3, 0xbca, 0xcc6, 0xdcf, 0xec5, 0xfcc,
  412. 0xcc , 0x1c5, 0x2cf, 0x3c6, 0x4ca, 0x5c3, 0x6c9, 0x7c0,
  413. 0x950, 0x859, 0xb53, 0xa5a, 0xd56, 0xc5f, 0xf55, 0xe5c,
  414. 0x15c, 0x55 , 0x35f, 0x256, 0x55a, 0x453, 0x759, 0x650,
  415. 0xaf0, 0xbf9, 0x8f3, 0x9fa, 0xef6, 0xfff, 0xcf5, 0xdfc,
  416. 0x2fc, 0x3f5, 0xff , 0x1f6, 0x6fa, 0x7f3, 0x4f9, 0x5f0,
  417. 0xb60, 0xa69, 0x963, 0x86a, 0xf66, 0xe6f, 0xd65, 0xc6c,
  418. 0x36c, 0x265, 0x16f, 0x66 , 0x76a, 0x663, 0x569, 0x460,
  419. 0xca0, 0xda9, 0xea3, 0xfaa, 0x8a6, 0x9af, 0xaa5, 0xbac,
  420. 0x4ac, 0x5a5, 0x6af, 0x7a6, 0xaa , 0x1a3, 0x2a9, 0x3a0,
  421. 0xd30, 0xc39, 0xf33, 0xe3a, 0x936, 0x83f, 0xb35, 0xa3c,
  422. 0x53c, 0x435, 0x73f, 0x636, 0x13a, 0x33 , 0x339, 0x230,
  423. 0xe90, 0xf99, 0xc93, 0xd9a, 0xa96, 0xb9f, 0x895, 0x99c,
  424. 0x69c, 0x795, 0x49f, 0x596, 0x29a, 0x393, 0x99 , 0x190,
  425. 0xf00, 0xe09, 0xd03, 0xc0a, 0xb06, 0xa0f, 0x905, 0x80c,
  426. 0x70c, 0x605, 0x50f, 0x406, 0x30a, 0x203, 0x109, 0x0])
  427. THREE.triTable = new Int32Array([
  428. -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  429. 0, 8, 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  430. 0, 1, 9, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  431. 1, 8, 3, 9, 8, 1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  432. 1, 2, 10, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  433. 0, 8, 3, 1, 2, 10, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  434. 9, 2, 10, 0, 2, 9, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  435. 2, 8, 3, 2, 10, 8, 10, 9, 8, -1, -1, -1, -1, -1, -1, -1,
  436. 3, 11, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  437. 0, 11, 2, 8, 11, 0, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  438. 1, 9, 0, 2, 3, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  439. 1, 11, 2, 1, 9, 11, 9, 8, 11, -1, -1, -1, -1, -1, -1, -1,
  440. 3, 10, 1, 11, 10, 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  441. 0, 10, 1, 0, 8, 10, 8, 11, 10, -1, -1, -1, -1, -1, -1, -1,
  442. 3, 9, 0, 3, 11, 9, 11, 10, 9, -1, -1, -1, -1, -1, -1, -1,
  443. 9, 8, 10, 10, 8, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  444. 4, 7, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  445. 4, 3, 0, 7, 3, 4, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  446. 0, 1, 9, 8, 4, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  447. 4, 1, 9, 4, 7, 1, 7, 3, 1, -1, -1, -1, -1, -1, -1, -1,
  448. 1, 2, 10, 8, 4, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  449. 3, 4, 7, 3, 0, 4, 1, 2, 10, -1, -1, -1, -1, -1, -1, -1,
  450. 9, 2, 10, 9, 0, 2, 8, 4, 7, -1, -1, -1, -1, -1, -1, -1,
  451. 2, 10, 9, 2, 9, 7, 2, 7, 3, 7, 9, 4, -1, -1, -1, -1,
  452. 8, 4, 7, 3, 11, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  453. 11, 4, 7, 11, 2, 4, 2, 0, 4, -1, -1, -1, -1, -1, -1, -1,
  454. 9, 0, 1, 8, 4, 7, 2, 3, 11, -1, -1, -1, -1, -1, -1, -1,
  455. 4, 7, 11, 9, 4, 11, 9, 11, 2, 9, 2, 1, -1, -1, -1, -1,
  456. 3, 10, 1, 3, 11, 10, 7, 8, 4, -1, -1, -1, -1, -1, -1, -1,
  457. 1, 11, 10, 1, 4, 11, 1, 0, 4, 7, 11, 4, -1, -1, -1, -1,
  458. 4, 7, 8, 9, 0, 11, 9, 11, 10, 11, 0, 3, -1, -1, -1, -1,
  459. 4, 7, 11, 4, 11, 9, 9, 11, 10, -1, -1, -1, -1, -1, -1, -1,
  460. 9, 5, 4, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  461. 9, 5, 4, 0, 8, 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  462. 0, 5, 4, 1, 5, 0, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  463. 8, 5, 4, 8, 3, 5, 3, 1, 5, -1, -1, -1, -1, -1, -1, -1,
  464. 1, 2, 10, 9, 5, 4, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  465. 3, 0, 8, 1, 2, 10, 4, 9, 5, -1, -1, -1, -1, -1, -1, -1,
  466. 5, 2, 10, 5, 4, 2, 4, 0, 2, -1, -1, -1, -1, -1, -1, -1,
  467. 2, 10, 5, 3, 2, 5, 3, 5, 4, 3, 4, 8, -1, -1, -1, -1,
  468. 9, 5, 4, 2, 3, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  469. 0, 11, 2, 0, 8, 11, 4, 9, 5, -1, -1, -1, -1, -1, -1, -1,
  470. 0, 5, 4, 0, 1, 5, 2, 3, 11, -1, -1, -1, -1, -1, -1, -1,
  471. 2, 1, 5, 2, 5, 8, 2, 8, 11, 4, 8, 5, -1, -1, -1, -1,
  472. 10, 3, 11, 10, 1, 3, 9, 5, 4, -1, -1, -1, -1, -1, -1, -1,
  473. 4, 9, 5, 0, 8, 1, 8, 10, 1, 8, 11, 10, -1, -1, -1, -1,
  474. 5, 4, 0, 5, 0, 11, 5, 11, 10, 11, 0, 3, -1, -1, -1, -1,
  475. 5, 4, 8, 5, 8, 10, 10, 8, 11, -1, -1, -1, -1, -1, -1, -1,
  476. 9, 7, 8, 5, 7, 9, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  477. 9, 3, 0, 9, 5, 3, 5, 7, 3, -1, -1, -1, -1, -1, -1, -1,
  478. 0, 7, 8, 0, 1, 7, 1, 5, 7, -1, -1, -1, -1, -1, -1, -1,
  479. 1, 5, 3, 3, 5, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  480. 9, 7, 8, 9, 5, 7, 10, 1, 2, -1, -1, -1, -1, -1, -1, -1,
  481. 10, 1, 2, 9, 5, 0, 5, 3, 0, 5, 7, 3, -1, -1, -1, -1,
  482. 8, 0, 2, 8, 2, 5, 8, 5, 7, 10, 5, 2, -1, -1, -1, -1,
  483. 2, 10, 5, 2, 5, 3, 3, 5, 7, -1, -1, -1, -1, -1, -1, -1,
  484. 7, 9, 5, 7, 8, 9, 3, 11, 2, -1, -1, -1, -1, -1, -1, -1,
  485. 9, 5, 7, 9, 7, 2, 9, 2, 0, 2, 7, 11, -1, -1, -1, -1,
  486. 2, 3, 11, 0, 1, 8, 1, 7, 8, 1, 5, 7, -1, -1, -1, -1,
  487. 11, 2, 1, 11, 1, 7, 7, 1, 5, -1, -1, -1, -1, -1, -1, -1,
  488. 9, 5, 8, 8, 5, 7, 10, 1, 3, 10, 3, 11, -1, -1, -1, -1,
  489. 5, 7, 0, 5, 0, 9, 7, 11, 0, 1, 0, 10, 11, 10, 0, -1,
  490. 11, 10, 0, 11, 0, 3, 10, 5, 0, 8, 0, 7, 5, 7, 0, -1,
  491. 11, 10, 5, 7, 11, 5, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  492. 10, 6, 5, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  493. 0, 8, 3, 5, 10, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  494. 9, 0, 1, 5, 10, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  495. 1, 8, 3, 1, 9, 8, 5, 10, 6, -1, -1, -1, -1, -1, -1, -1,
  496. 1, 6, 5, 2, 6, 1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  497. 1, 6, 5, 1, 2, 6, 3, 0, 8, -1, -1, -1, -1, -1, -1, -1,
  498. 9, 6, 5, 9, 0, 6, 0, 2, 6, -1, -1, -1, -1, -1, -1, -1,
  499. 5, 9, 8, 5, 8, 2, 5, 2, 6, 3, 2, 8, -1, -1, -1, -1,
  500. 2, 3, 11, 10, 6, 5, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  501. 11, 0, 8, 11, 2, 0, 10, 6, 5, -1, -1, -1, -1, -1, -1, -1,
  502. 0, 1, 9, 2, 3, 11, 5, 10, 6, -1, -1, -1, -1, -1, -1, -1,
  503. 5, 10, 6, 1, 9, 2, 9, 11, 2, 9, 8, 11, -1, -1, -1, -1,
  504. 6, 3, 11, 6, 5, 3, 5, 1, 3, -1, -1, -1, -1, -1, -1, -1,
  505. 0, 8, 11, 0, 11, 5, 0, 5, 1, 5, 11, 6, -1, -1, -1, -1,
  506. 3, 11, 6, 0, 3, 6, 0, 6, 5, 0, 5, 9, -1, -1, -1, -1,
  507. 6, 5, 9, 6, 9, 11, 11, 9, 8, -1, -1, -1, -1, -1, -1, -1,
  508. 5, 10, 6, 4, 7, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  509. 4, 3, 0, 4, 7, 3, 6, 5, 10, -1, -1, -1, -1, -1, -1, -1,
  510. 1, 9, 0, 5, 10, 6, 8, 4, 7, -1, -1, -1, -1, -1, -1, -1,
  511. 10, 6, 5, 1, 9, 7, 1, 7, 3, 7, 9, 4, -1, -1, -1, -1,
  512. 6, 1, 2, 6, 5, 1, 4, 7, 8, -1, -1, -1, -1, -1, -1, -1,
  513. 1, 2, 5, 5, 2, 6, 3, 0, 4, 3, 4, 7, -1, -1, -1, -1,
  514. 8, 4, 7, 9, 0, 5, 0, 6, 5, 0, 2, 6, -1, -1, -1, -1,
  515. 7, 3, 9, 7, 9, 4, 3, 2, 9, 5, 9, 6, 2, 6, 9, -1,
  516. 3, 11, 2, 7, 8, 4, 10, 6, 5, -1, -1, -1, -1, -1, -1, -1,
  517. 5, 10, 6, 4, 7, 2, 4, 2, 0, 2, 7, 11, -1, -1, -1, -1,
  518. 0, 1, 9, 4, 7, 8, 2, 3, 11, 5, 10, 6, -1, -1, -1, -1,
  519. 9, 2, 1, 9, 11, 2, 9, 4, 11, 7, 11, 4, 5, 10, 6, -1,
  520. 8, 4, 7, 3, 11, 5, 3, 5, 1, 5, 11, 6, -1, -1, -1, -1,
  521. 5, 1, 11, 5, 11, 6, 1, 0, 11, 7, 11, 4, 0, 4, 11, -1,
  522. 0, 5, 9, 0, 6, 5, 0, 3, 6, 11, 6, 3, 8, 4, 7, -1,
  523. 6, 5, 9, 6, 9, 11, 4, 7, 9, 7, 11, 9, -1, -1, -1, -1,
  524. 10, 4, 9, 6, 4, 10, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  525. 4, 10, 6, 4, 9, 10, 0, 8, 3, -1, -1, -1, -1, -1, -1, -1,
  526. 10, 0, 1, 10, 6, 0, 6, 4, 0, -1, -1, -1, -1, -1, -1, -1,
  527. 8, 3, 1, 8, 1, 6, 8, 6, 4, 6, 1, 10, -1, -1, -1, -1,
  528. 1, 4, 9, 1, 2, 4, 2, 6, 4, -1, -1, -1, -1, -1, -1, -1,
  529. 3, 0, 8, 1, 2, 9, 2, 4, 9, 2, 6, 4, -1, -1, -1, -1,
  530. 0, 2, 4, 4, 2, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  531. 8, 3, 2, 8, 2, 4, 4, 2, 6, -1, -1, -1, -1, -1, -1, -1,
  532. 10, 4, 9, 10, 6, 4, 11, 2, 3, -1, -1, -1, -1, -1, -1, -1,
  533. 0, 8, 2, 2, 8, 11, 4, 9, 10, 4, 10, 6, -1, -1, -1, -1,
  534. 3, 11, 2, 0, 1, 6, 0, 6, 4, 6, 1, 10, -1, -1, -1, -1,
  535. 6, 4, 1, 6, 1, 10, 4, 8, 1, 2, 1, 11, 8, 11, 1, -1,
  536. 9, 6, 4, 9, 3, 6, 9, 1, 3, 11, 6, 3, -1, -1, -1, -1,
  537. 8, 11, 1, 8, 1, 0, 11, 6, 1, 9, 1, 4, 6, 4, 1, -1,
  538. 3, 11, 6, 3, 6, 0, 0, 6, 4, -1, -1, -1, -1, -1, -1, -1,
  539. 6, 4, 8, 11, 6, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  540. 7, 10, 6, 7, 8, 10, 8, 9, 10, -1, -1, -1, -1, -1, -1, -1,
  541. 0, 7, 3, 0, 10, 7, 0, 9, 10, 6, 7, 10, -1, -1, -1, -1,
  542. 10, 6, 7, 1, 10, 7, 1, 7, 8, 1, 8, 0, -1, -1, -1, -1,
  543. 10, 6, 7, 10, 7, 1, 1, 7, 3, -1, -1, -1, -1, -1, -1, -1,
  544. 1, 2, 6, 1, 6, 8, 1, 8, 9, 8, 6, 7, -1, -1, -1, -1,
  545. 2, 6, 9, 2, 9, 1, 6, 7, 9, 0, 9, 3, 7, 3, 9, -1,
  546. 7, 8, 0, 7, 0, 6, 6, 0, 2, -1, -1, -1, -1, -1, -1, -1,
  547. 7, 3, 2, 6, 7, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  548. 2, 3, 11, 10, 6, 8, 10, 8, 9, 8, 6, 7, -1, -1, -1, -1,
  549. 2, 0, 7, 2, 7, 11, 0, 9, 7, 6, 7, 10, 9, 10, 7, -1,
  550. 1, 8, 0, 1, 7, 8, 1, 10, 7, 6, 7, 10, 2, 3, 11, -1,
  551. 11, 2, 1, 11, 1, 7, 10, 6, 1, 6, 7, 1, -1, -1, -1, -1,
  552. 8, 9, 6, 8, 6, 7, 9, 1, 6, 11, 6, 3, 1, 3, 6, -1,
  553. 0, 9, 1, 11, 6, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  554. 7, 8, 0, 7, 0, 6, 3, 11, 0, 11, 6, 0, -1, -1, -1, -1,
  555. 7, 11, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  556. 7, 6, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  557. 3, 0, 8, 11, 7, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  558. 0, 1, 9, 11, 7, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  559. 8, 1, 9, 8, 3, 1, 11, 7, 6, -1, -1, -1, -1, -1, -1, -1,
  560. 10, 1, 2, 6, 11, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  561. 1, 2, 10, 3, 0, 8, 6, 11, 7, -1, -1, -1, -1, -1, -1, -1,
  562. 2, 9, 0, 2, 10, 9, 6, 11, 7, -1, -1, -1, -1, -1, -1, -1,
  563. 6, 11, 7, 2, 10, 3, 10, 8, 3, 10, 9, 8, -1, -1, -1, -1,
  564. 7, 2, 3, 6, 2, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  565. 7, 0, 8, 7, 6, 0, 6, 2, 0, -1, -1, -1, -1, -1, -1, -1,
  566. 2, 7, 6, 2, 3, 7, 0, 1, 9, -1, -1, -1, -1, -1, -1, -1,
  567. 1, 6, 2, 1, 8, 6, 1, 9, 8, 8, 7, 6, -1, -1, -1, -1,
  568. 10, 7, 6, 10, 1, 7, 1, 3, 7, -1, -1, -1, -1, -1, -1, -1,
  569. 10, 7, 6, 1, 7, 10, 1, 8, 7, 1, 0, 8, -1, -1, -1, -1,
  570. 0, 3, 7, 0, 7, 10, 0, 10, 9, 6, 10, 7, -1, -1, -1, -1,
  571. 7, 6, 10, 7, 10, 8, 8, 10, 9, -1, -1, -1, -1, -1, -1, -1,
  572. 6, 8, 4, 11, 8, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  573. 3, 6, 11, 3, 0, 6, 0, 4, 6, -1, -1, -1, -1, -1, -1, -1,
  574. 8, 6, 11, 8, 4, 6, 9, 0, 1, -1, -1, -1, -1, -1, -1, -1,
  575. 9, 4, 6, 9, 6, 3, 9, 3, 1, 11, 3, 6, -1, -1, -1, -1,
  576. 6, 8, 4, 6, 11, 8, 2, 10, 1, -1, -1, -1, -1, -1, -1, -1,
  577. 1, 2, 10, 3, 0, 11, 0, 6, 11, 0, 4, 6, -1, -1, -1, -1,
  578. 4, 11, 8, 4, 6, 11, 0, 2, 9, 2, 10, 9, -1, -1, -1, -1,
  579. 10, 9, 3, 10, 3, 2, 9, 4, 3, 11, 3, 6, 4, 6, 3, -1,
  580. 8, 2, 3, 8, 4, 2, 4, 6, 2, -1, -1, -1, -1, -1, -1, -1,
  581. 0, 4, 2, 4, 6, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  582. 1, 9, 0, 2, 3, 4, 2, 4, 6, 4, 3, 8, -1, -1, -1, -1,
  583. 1, 9, 4, 1, 4, 2, 2, 4, 6, -1, -1, -1, -1, -1, -1, -1,
  584. 8, 1, 3, 8, 6, 1, 8, 4, 6, 6, 10, 1, -1, -1, -1, -1,
  585. 10, 1, 0, 10, 0, 6, 6, 0, 4, -1, -1, -1, -1, -1, -1, -1,
  586. 4, 6, 3, 4, 3, 8, 6, 10, 3, 0, 3, 9, 10, 9, 3, -1,
  587. 10, 9, 4, 6, 10, 4, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  588. 4, 9, 5, 7, 6, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  589. 0, 8, 3, 4, 9, 5, 11, 7, 6, -1, -1, -1, -1, -1, -1, -1,
  590. 5, 0, 1, 5, 4, 0, 7, 6, 11, -1, -1, -1, -1, -1, -1, -1,
  591. 11, 7, 6, 8, 3, 4, 3, 5, 4, 3, 1, 5, -1, -1, -1, -1,
  592. 9, 5, 4, 10, 1, 2, 7, 6, 11, -1, -1, -1, -1, -1, -1, -1,
  593. 6, 11, 7, 1, 2, 10, 0, 8, 3, 4, 9, 5, -1, -1, -1, -1,
  594. 7, 6, 11, 5, 4, 10, 4, 2, 10, 4, 0, 2, -1, -1, -1, -1,
  595. 3, 4, 8, 3, 5, 4, 3, 2, 5, 10, 5, 2, 11, 7, 6, -1,
  596. 7, 2, 3, 7, 6, 2, 5, 4, 9, -1, -1, -1, -1, -1, -1, -1,
  597. 9, 5, 4, 0, 8, 6, 0, 6, 2, 6, 8, 7, -1, -1, -1, -1,
  598. 3, 6, 2, 3, 7, 6, 1, 5, 0, 5, 4, 0, -1, -1, -1, -1,
  599. 6, 2, 8, 6, 8, 7, 2, 1, 8, 4, 8, 5, 1, 5, 8, -1,
  600. 9, 5, 4, 10, 1, 6, 1, 7, 6, 1, 3, 7, -1, -1, -1, -1,
  601. 1, 6, 10, 1, 7, 6, 1, 0, 7, 8, 7, 0, 9, 5, 4, -1,
  602. 4, 0, 10, 4, 10, 5, 0, 3, 10, 6, 10, 7, 3, 7, 10, -1,
  603. 7, 6, 10, 7, 10, 8, 5, 4, 10, 4, 8, 10, -1, -1, -1, -1,
  604. 6, 9, 5, 6, 11, 9, 11, 8, 9, -1, -1, -1, -1, -1, -1, -1,
  605. 3, 6, 11, 0, 6, 3, 0, 5, 6, 0, 9, 5, -1, -1, -1, -1,
  606. 0, 11, 8, 0, 5, 11, 0, 1, 5, 5, 6, 11, -1, -1, -1, -1,
  607. 6, 11, 3, 6, 3, 5, 5, 3, 1, -1, -1, -1, -1, -1, -1, -1,
  608. 1, 2, 10, 9, 5, 11, 9, 11, 8, 11, 5, 6, -1, -1, -1, -1,
  609. 0, 11, 3, 0, 6, 11, 0, 9, 6, 5, 6, 9, 1, 2, 10, -1,
  610. 11, 8, 5, 11, 5, 6, 8, 0, 5, 10, 5, 2, 0, 2, 5, -1,
  611. 6, 11, 3, 6, 3, 5, 2, 10, 3, 10, 5, 3, -1, -1, -1, -1,
  612. 5, 8, 9, 5, 2, 8, 5, 6, 2, 3, 8, 2, -1, -1, -1, -1,
  613. 9, 5, 6, 9, 6, 0, 0, 6, 2, -1, -1, -1, -1, -1, -1, -1,
  614. 1, 5, 8, 1, 8, 0, 5, 6, 8, 3, 8, 2, 6, 2, 8, -1,
  615. 1, 5, 6, 2, 1, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  616. 1, 3, 6, 1, 6, 10, 3, 8, 6, 5, 6, 9, 8, 9, 6, -1,
  617. 10, 1, 0, 10, 0, 6, 9, 5, 0, 5, 6, 0, -1, -1, -1, -1,
  618. 0, 3, 8, 5, 6, 10, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  619. 10, 5, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  620. 11, 5, 10, 7, 5, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  621. 11, 5, 10, 11, 7, 5, 8, 3, 0, -1, -1, -1, -1, -1, -1, -1,
  622. 5, 11, 7, 5, 10, 11, 1, 9, 0, -1, -1, -1, -1, -1, -1, -1,
  623. 10, 7, 5, 10, 11, 7, 9, 8, 1, 8, 3, 1, -1, -1, -1, -1,
  624. 11, 1, 2, 11, 7, 1, 7, 5, 1, -1, -1, -1, -1, -1, -1, -1,
  625. 0, 8, 3, 1, 2, 7, 1, 7, 5, 7, 2, 11, -1, -1, -1, -1,
  626. 9, 7, 5, 9, 2, 7, 9, 0, 2, 2, 11, 7, -1, -1, -1, -1,
  627. 7, 5, 2, 7, 2, 11, 5, 9, 2, 3, 2, 8, 9, 8, 2, -1,
  628. 2, 5, 10, 2, 3, 5, 3, 7, 5, -1, -1, -1, -1, -1, -1, -1,
  629. 8, 2, 0, 8, 5, 2, 8, 7, 5, 10, 2, 5, -1, -1, -1, -1,
  630. 9, 0, 1, 5, 10, 3, 5, 3, 7, 3, 10, 2, -1, -1, -1, -1,
  631. 9, 8, 2, 9, 2, 1, 8, 7, 2, 10, 2, 5, 7, 5, 2, -1,
  632. 1, 3, 5, 3, 7, 5, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  633. 0, 8, 7, 0, 7, 1, 1, 7, 5, -1, -1, -1, -1, -1, -1, -1,
  634. 9, 0, 3, 9, 3, 5, 5, 3, 7, -1, -1, -1, -1, -1, -1, -1,
  635. 9, 8, 7, 5, 9, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  636. 5, 8, 4, 5, 10, 8, 10, 11, 8, -1, -1, -1, -1, -1, -1, -1,
  637. 5, 0, 4, 5, 11, 0, 5, 10, 11, 11, 3, 0, -1, -1, -1, -1,
  638. 0, 1, 9, 8, 4, 10, 8, 10, 11, 10, 4, 5, -1, -1, -1, -1,
  639. 10, 11, 4, 10, 4, 5, 11, 3, 4, 9, 4, 1, 3, 1, 4, -1,
  640. 2, 5, 1, 2, 8, 5, 2, 11, 8, 4, 5, 8, -1, -1, -1, -1,
  641. 0, 4, 11, 0, 11, 3, 4, 5, 11, 2, 11, 1, 5, 1, 11, -1,
  642. 0, 2, 5, 0, 5, 9, 2, 11, 5, 4, 5, 8, 11, 8, 5, -1,
  643. 9, 4, 5, 2, 11, 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  644. 2, 5, 10, 3, 5, 2, 3, 4, 5, 3, 8, 4, -1, -1, -1, -1,
  645. 5, 10, 2, 5, 2, 4, 4, 2, 0, -1, -1, -1, -1, -1, -1, -1,
  646. 3, 10, 2, 3, 5, 10, 3, 8, 5, 4, 5, 8, 0, 1, 9, -1,
  647. 5, 10, 2, 5, 2, 4, 1, 9, 2, 9, 4, 2, -1, -1, -1, -1,
  648. 8, 4, 5, 8, 5, 3, 3, 5, 1, -1, -1, -1, -1, -1, -1, -1,
  649. 0, 4, 5, 1, 0, 5, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  650. 8, 4, 5, 8, 5, 3, 9, 0, 5, 0, 3, 5, -1, -1, -1, -1,
  651. 9, 4, 5, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  652. 4, 11, 7, 4, 9, 11, 9, 10, 11, -1, -1, -1, -1, -1, -1, -1,
  653. 0, 8, 3, 4, 9, 7, 9, 11, 7, 9, 10, 11, -1, -1, -1, -1,
  654. 1, 10, 11, 1, 11, 4, 1, 4, 0, 7, 4, 11, -1, -1, -1, -1,
  655. 3, 1, 4, 3, 4, 8, 1, 10, 4, 7, 4, 11, 10, 11, 4, -1,
  656. 4, 11, 7, 9, 11, 4, 9, 2, 11, 9, 1, 2, -1, -1, -1, -1,
  657. 9, 7, 4, 9, 11, 7, 9, 1, 11, 2, 11, 1, 0, 8, 3, -1,
  658. 11, 7, 4, 11, 4, 2, 2, 4, 0, -1, -1, -1, -1, -1, -1, -1,
  659. 11, 7, 4, 11, 4, 2, 8, 3, 4, 3, 2, 4, -1, -1, -1, -1,
  660. 2, 9, 10, 2, 7, 9, 2, 3, 7, 7, 4, 9, -1, -1, -1, -1,
  661. 9, 10, 7, 9, 7, 4, 10, 2, 7, 8, 7, 0, 2, 0, 7, -1,
  662. 3, 7, 10, 3, 10, 2, 7, 4, 10, 1, 10, 0, 4, 0, 10, -1,
  663. 1, 10, 2, 8, 7, 4, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  664. 4, 9, 1, 4, 1, 7, 7, 1, 3, -1, -1, -1, -1, -1, -1, -1,
  665. 4, 9, 1, 4, 1, 7, 0, 8, 1, 8, 7, 1, -1, -1, -1, -1,
  666. 4, 0, 3, 7, 4, 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  667. 4, 8, 7, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  668. 9, 10, 8, 10, 11, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  669. 3, 0, 9, 3, 9, 11, 11, 9, 10, -1, -1, -1, -1, -1, -1, -1,
  670. 0, 1, 10, 0, 10, 8, 8, 10, 11, -1, -1, -1, -1, -1, -1, -1,
  671. 3, 1, 10, 11, 3, 10, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  672. 1, 2, 11, 1, 11, 9, 9, 11, 8, -1, -1, -1, -1, -1, -1, -1,
  673. 3, 0, 9, 3, 9, 11, 1, 2, 9, 2, 11, 9, -1, -1, -1, -1,
  674. 0, 2, 11, 8, 0, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  675. 3, 2, 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  676. 2, 3, 8, 2, 8, 10, 10, 8, 9, -1, -1, -1, -1, -1, -1, -1,
  677. 9, 10, 2, 0, 9, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  678. 2, 3, 8, 2, 8, 10, 0, 1, 8, 1, 10, 8, -1, -1, -1, -1,
  679. 1, 10, 2, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  680. 1, 3, 8, 9, 1, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  681. 0, 9, 1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  682. 0, 3, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
  683. -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]);
粤ICP备19079148号