UNPKG

awv3

Version:
1,567 lines (1,566 loc) 343 kB
{ "type": "File", "start": 0, "end": 1637, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 74, "column": 0 } }, "program": { "type": "Program", "start": 0, "end": 1637, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 74, "column": 0 } }, "sourceType": "module", "body": [ { "type": "ImportDeclaration", "start": 0, "end": 31, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 31 } }, "specifiers": [ { "type": "ImportNamespaceSpecifier", "start": 7, "end": 17, "loc": { "start": { "line": 1, "column": 7 }, "end": { "line": 1, "column": 17 } }, "local": { "type": "Identifier", "start": 12, "end": 17, "loc": { "start": { "line": 1, "column": 12 }, "end": { "line": 1, "column": 17 }, "identifierName": "THREE" }, "name": "THREE" } } ], "source": { "type": "StringLiteral", "start": 23, "end": 30, "loc": { "start": { "line": 1, "column": 23 }, "end": { "line": 1, "column": 30 } }, "extra": { "rawValue": "three", "raw": "'three'" }, "value": "three" } }, { "type": "ImportDeclaration", "start": 32, "end": 62, "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 30 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 39, "end": 45, "loc": { "start": { "line": 2, "column": 7 }, "end": { "line": 2, "column": 13 } }, "local": { "type": "Identifier", "start": 39, "end": 45, "loc": { "start": { "line": 2, "column": 7 }, "end": { "line": 2, "column": 13 }, "identifierName": "Events" }, "name": "Events" } } ], "source": { "type": "StringLiteral", "start": 51, "end": 61, "loc": { "start": { "line": 2, "column": 19 }, "end": { "line": 2, "column": 29 } }, "extra": { "rawValue": "./events", "raw": "'./events'" }, "value": "./events" } }, { "type": "ImportDeclaration", "start": 63, "end": 113, "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 3, "column": 50 } }, "specifiers": [ { "type": "ImportSpecifier", "start": 72, "end": 76, "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 13 } }, "imported": { "type": "Identifier", "start": 72, "end": 76, "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 13 }, "identifierName": "Pool" }, "name": "Pool" }, "local": { "type": "Identifier", "start": 72, "end": 76, "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 13 }, "identifierName": "Pool" }, "name": "Pool" } }, { "type": "ImportSpecifier", "start": 78, "end": 93, "loc": { "start": { "line": 3, "column": 15 }, "end": { "line": 3, "column": 30 } }, "imported": { "type": "Identifier", "start": 78, "end": 93, "loc": { "start": { "line": 3, "column": 15 }, "end": { "line": 3, "column": 30 }, "identifierName": "ObjectPrototype" }, "name": "ObjectPrototype" }, "local": { "type": "Identifier", "start": 78, "end": 93, "loc": { "start": { "line": 3, "column": 15 }, "end": { "line": 3, "column": 30 }, "identifierName": "ObjectPrototype" }, "name": "ObjectPrototype" } } ], "source": { "type": "StringLiteral", "start": 101, "end": 112, "loc": { "start": { "line": 3, "column": 38 }, "end": { "line": 3, "column": 49 } }, "extra": { "rawValue": "./helpers", "raw": "'./helpers'" }, "value": "./helpers" } }, { "type": "VariableDeclaration", "start": 115, "end": 1120, "loc": { "start": { "line": 5, "column": 0 }, "end": { "line": 49, "column": 2 } }, "declarations": [ { "type": "VariableDeclarator", "start": 121, "end": 1119, "loc": { "start": { "line": 5, "column": 6 }, "end": { "line": 49, "column": 1 } }, "id": { "type": "Identifier", "start": 121, "end": 129, "loc": { "start": { "line": 5, "column": 6 }, "end": { "line": 5, "column": 14 }, "identifierName": "defaults" }, "name": "defaults" }, "init": { "type": "ObjectExpression", "start": 132, "end": 1119, "loc": { "start": { "line": 5, "column": 17 }, "end": { "line": 49, "column": 1 } }, "properties": [ { "type": "ObjectProperty", "start": 138, "end": 151, "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 17 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 138, "end": 148, "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 14 }, "identifierName": "resolution" }, "name": "resolution" }, "value": { "type": "NumericLiteral", "start": 150, "end": 151, "loc": { "start": { "line": 6, "column": 16 }, "end": { "line": 6, "column": 17 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 } }, { "type": "ObjectProperty", "start": 157, "end": 170, "loc": { "start": { "line": 7, "column": 4 }, "end": { "line": 7, "column": 17 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 157, "end": 159, "loc": { "start": { "line": 7, "column": 4 }, "end": { "line": 7, "column": 6 }, "identifierName": "up" }, "name": "up" }, "value": { "type": "ArrayExpression", "start": 161, "end": 170, "loc": { "start": { "line": 7, "column": 8 }, "end": { "line": 7, "column": 17 } }, "elements": [ { "type": "NumericLiteral", "start": 162, "end": 163, "loc": { "start": { "line": 7, "column": 9 }, "end": { "line": 7, "column": 10 } }, "extra": { "rawValue": 0, "raw": "0" }, "value": 0 }, { "type": "NumericLiteral", "start": 165, "end": 166, "loc": { "start": { "line": 7, "column": 12 }, "end": { "line": 7, "column": 13 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 }, { "type": "NumericLiteral", "start": 168, "end": 169, "loc": { "start": { "line": 7, "column": 15 }, "end": { "line": 7, "column": 16 } }, "extra": { "rawValue": 0, "raw": "0" }, "value": 0 } ] } }, { "type": "ObjectProperty", "start": 176, "end": 188, "loc": { "start": { "line": 8, "column": 4 }, "end": { "line": 8, "column": 16 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 176, "end": 181, "loc": { "start": { "line": 8, "column": 4 }, "end": { "line": 8, "column": 9 }, "identifierName": "stats" }, "name": "stats" }, "value": { "type": "BooleanLiteral", "start": 183, "end": 188, "loc": { "start": { "line": 8, "column": 11 }, "end": { "line": 8, "column": 16 } }, "value": false } }, { "type": "ObjectProperty", "start": 194, "end": 206, "loc": { "start": { "line": 9, "column": 4 }, "end": { "line": 9, "column": 16 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 194, "end": 199, "loc": { "start": { "line": 9, "column": 4 }, "end": { "line": 9, "column": 9 }, "identifierName": "debug" }, "name": "debug" }, "value": { "type": "BooleanLiteral", "start": 201, "end": 206, "loc": { "start": { "line": 9, "column": 11 }, "end": { "line": 9, "column": 16 } }, "value": false } }, { "type": "ObjectProperty", "start": 212, "end": 233, "loc": { "start": { "line": 10, "column": 4 }, "end": { "line": 10, "column": 25 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 212, "end": 228, "loc": { "start": { "line": 10, "column": 4 }, "end": { "line": 10, "column": 20 }, "identifierName": "ambientIntensity" }, "name": "ambientIntensity" }, "value": { "type": "NumericLiteral", "start": 230, "end": 233, "loc": { "start": { "line": 10, "column": 22 }, "end": { "line": 10, "column": 25 } }, "extra": { "rawValue": 1, "raw": "1.0" }, "value": 1 } }, { "type": "ObjectProperty", "start": 239, "end": 303, "loc": { "start": { "line": 11, "column": 4 }, "end": { "line": 14, "column": 5 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 239, "end": 250, "loc": { "start": { "line": 11, "column": 4 }, "end": { "line": 11, "column": 15 }, "identifierName": "renderOrder" }, "name": "renderOrder" }, "value": { "type": "ObjectExpression", "start": 252, "end": 303, "loc": { "start": { "line": 11, "column": 17 }, "end": { "line": 14, "column": 5 } }, "properties": [ { "type": "ObjectProperty", "start": 262, "end": 269, "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 15 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 262, "end": 266, "loc": { "start": { "line": 12, "column": 8 }, "end": { "line": 12, "column": 12 }, "identifierName": "Mesh" }, "name": "Mesh" }, "value": { "type": "NumericLiteral", "start": 268, "end": 269, "loc": { "start": { "line": 12, "column": 14 }, "end": { "line": 12, "column": 15 } }, "extra": { "rawValue": 0, "raw": "0" }, "value": 0 } }, { "type": "ObjectProperty", "start": 279, "end": 296, "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 25 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 279, "end": 291, "loc": { "start": { "line": 13, "column": 8 }, "end": { "line": 13, "column": 20 }, "identifierName": "LineSegments" }, "name": "LineSegments" }, "value": { "type": "NumericLiteral", "start": 293, "end": 296, "loc": { "start": { "line": 13, "column": 22 }, "end": { "line": 13, "column": 25 } }, "extra": { "rawValue": 100, "raw": "100" }, "value": 100 } } ] } }, { "type": "ObjectProperty", "start": 309, "end": 417, "loc": { "start": { "line": 15, "column": 4 }, "end": { "line": 20, "column": 5 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 309, "end": 319, "loc": { "start": { "line": 15, "column": 4 }, "end": { "line": 15, "column": 14 }, "identifierName": "updateView" }, "name": "updateView" }, "value": { "type": "ObjectExpression", "start": 321, "end": 417, "loc": { "start": { "line": 15, "column": 16 }, "end": { "line": 20, "column": 5 } }, "properties": [ { "type": "ObjectProperty", "start": 331, "end": 343, "loc": { "start": { "line": 16, "column": 8 }, "end": { "line": 16, "column": 20 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 331, "end": 336, "loc": { "start": { "line": 16, "column": 8 }, "end": { "line": 16, "column": 13 }, "identifierName": "focus" }, "name": "focus" }, "value": { "type": "BooleanLiteral", "start": 338, "end": 343, "loc": { "start": { "line": 16, "column": 15 }, "end": { "line": 16, "column": 20 } }, "value": false } }, { "type": "ObjectProperty", "start": 353, "end": 364, "loc": { "start": { "line": 17, "column": 8 }, "end": { "line": 17, "column": 19 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 353, "end": 357, "loc": { "start": { "line": 17, "column": 8 }, "end": { "line": 17, "column": 12 }, "identifierName": "zoom" }, "name": "zoom" }, "value": { "type": "BooleanLiteral", "start": 359, "end": 364, "loc": { "start": { "line": 17, "column": 14 }, "end": { "line": 17, "column": 19 } }, "value": false } }, { "type": "ObjectProperty", "start": 374, "end": 387, "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 21 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 374, "end": 380, "loc": { "start": { "line": 18, "column": 8 }, "end": { "line": 18, "column": 14 }, "identifierName": "rotate" }, "name": "rotate" }, "value": { "type": "BooleanLiteral", "start": 382, "end": 387, "loc": { "start": { "line": 18, "column": 16 }, "end": { "line": 18, "column": 21 } }, "value": false } }, { "type": "ObjectProperty", "start": 397, "end": 410, "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 21 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 397, "end": 403, "loc": { "start": { "line": 19, "column": 8 }, "end": { "line": 19, "column": 14 }, "identifierName": "layers" }, "name": "layers" }, "value": { "type": "BooleanLiteral", "start": 405, "end": 410, "loc": { "start": { "line": 19, "column": 16 }, "end": { "line": 19, "column": 21 } }, "value": false } } ] } }, { "type": "ObjectProperty", "start": 423, "end": 557, "loc": { "start": { "line": 21, "column": 4 }, "end": { "line": 27, "column": 5 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 423, "end": 432, "loc": { "start": { "line": 21, "column": 4 }, "end": { "line": 21, "column": 13 }, "identifierName": "materials" }, "name": "materials" }, "value": { "type": "ObjectExpression", "start": 434, "end": 557, "loc": { "start": { "line": 21, "column": 15 }, "end": { "line": 27, "column": 5 } }, "properties": [ { "type": "ObjectProperty", "start": 444, "end": 455, "loc": { "start": { "line": 22, "column": 8 }, "end": { "line": 22, "column": 19 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 444, "end": 448, "loc": { "start": { "line": 22, "column": 8 }, "end": { "line": 22, "column": 12 }, "identifierName": "lazy" }, "name": "lazy" }, "value": { "type": "BooleanLiteral", "start": 450, "end": 455, "loc": { "start": { "line": 22, "column": 14 }, "end": { "line": 22, "column": 19 } }, "value": false } }, { "type": "ObjectProperty", "start": 465, "end": 476, "loc": { "start": { "line": 23, "column": 8 }, "end": { "line": 23, "column": 19 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 465, "end": 470, "loc": { "start": { "line": 23, "column": 8 }, "end": { "line": 23, "column": 13 }, "identifierName": "multi" }, "name": "multi" }, "value": { "type": "BooleanLiteral", "start": 472, "end": 476, "loc": { "start": { "line": 23, "column": 15 }, "end": { "line": 23, "column": 19 } }, "value": true } }, { "type": "ObjectProperty", "start": 486, "end": 505, "loc": { "start": { "line": 24, "column": 8 }, "end": { "line": 24, "column": 27 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 486, "end": 499, "loc": { "start": { "line": 24, "column": 8 }, "end": { "line": 24, "column": 21 }, "identifierName": "lineDistances" }, "name": "lineDistances" }, "value": { "type": "BooleanLiteral", "start": 501, "end": 505, "loc": { "start": { "line": 24, "column": 23 }, "end": { "line": 24, "column": 27 } }, "value": true } }, { "type": "ObjectProperty", "start": 515, "end": 528, "loc": { "start": { "line": 25, "column": 8 }, "end": { "line": 25, "column": 21 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 515, "end": 522, "loc": { "start": { "line": 25, "column": 8 }, "end": { "line": 25, "column": 15 }, "identifierName": "shadows" }, "name": "shadows" }, "value": { "type": "BooleanLiteral", "start": 524, "end": 528, "loc": { "start": { "line": 25, "column": 17 }, "end": { "line": 25, "column": 21 } }, "value": true } }, { "type": "ObjectProperty", "start": 538, "end": 550, "loc": { "start": { "line": 26, "column": 8 }, "end": { "line": 26, "column": 20 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 538, "end": 544, "loc": { "start": { "line": 26, "column": 8 }, "end": { "line": 26, "column": 14 }, "identifierName": "lights" }, "name": "lights" }, "value": { "type": "BooleanLiteral", "start": 546, "end": 550, "loc": { "start": { "line": 26, "column": 16 }, "end": { "line": 26, "column": 20 } }, "value": true } } ] } }, { "type": "ObjectProperty", "start": 563, "end": 598, "loc": { "start": { "line": 28, "column": 4 }, "end": { "line": 28, "column": 39 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 563, "end": 573, "loc": { "start": { "line": 28, "column": 4 }, "end": { "line": 28, "column": 14 }, "identifierName": "lineShader" }, "name": "lineShader" }, "value": { "type": "MemberExpression", "start": 575, "end": 598, "loc": { "start": { "line": 28, "column": 16 }, "end": { "line": 28, "column": 39 } }, "object": { "type": "Identifier", "start": 575, "end": 580, "loc": { "start": { "line": 28, "column": 16 }, "end": { "line": 28, "column": 21 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 581, "end": 598, "loc": { "start": { "line": 28, "column": 22 }, "end": { "line": 28, "column": 39 }, "identifierName": "LineBasicMaterial" }, "name": "LineBasicMaterial" }, "computed": false } }, { "type": "ObjectProperty", "start": 604, "end": 677, "loc": { "start": { "line": 29, "column": 4 }, "end": { "line": 32, "column": 5 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 604, "end": 621, "loc": { "start": { "line": 29, "column": 4 }, "end": { "line": 29, "column": 21 }, "identifierName": "lineShaderOptions" }, "name": "lineShaderOptions" }, "value": { "type": "ObjectExpression", "start": 623, "end": 677, "loc": { "start": { "line": 29, "column": 23 }, "end": { "line": 32, "column": 5 } }, "properties": [ { "type": "ObjectProperty", "start": 633, "end": 650, "loc": { "start": { "line": 30, "column": 8 }, "end": { "line": 30, "column": 25 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier",