UNPKG

awv3

Version:
1,796 lines (1,795 loc) 1.34 MB
{ "type": "File", "start": 0, "end": 5583, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 123, "column": 0 } }, "program": { "type": "Program", "start": 0, "end": 5583, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 123, "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": 77, "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 45 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 39, "end": 46, "loc": { "start": { "line": 2, "column": 7 }, "end": { "line": 2, "column": 14 } }, "local": { "type": "Identifier", "start": 39, "end": 46, "loc": { "start": { "line": 2, "column": 7 }, "end": { "line": 2, "column": 14 }, "identifierName": "Object3" }, "name": "Object3" } } ], "source": { "type": "StringLiteral", "start": 52, "end": 76, "loc": { "start": { "line": 2, "column": 20 }, "end": { "line": 2, "column": 44 } }, "extra": { "rawValue": "../../../three/object3", "raw": "'../../../three/object3'" }, "value": "../../../three/object3" } }, { "type": "VariableDeclaration", "start": 79, "end": 143, "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 64 } }, "declarations": [ { "type": "VariableDeclarator", "start": 85, "end": 142, "loc": { "start": { "line": 4, "column": 6 }, "end": { "line": 4, "column": 63 } }, "id": { "type": "Identifier", "start": 85, "end": 98, "loc": { "start": { "line": 4, "column": 6 }, "end": { "line": 4, "column": 19 }, "identifierName": "pointGeometry" }, "name": "pointGeometry" }, "init": { "type": "NewExpression", "start": 101, "end": 142, "loc": { "start": { "line": 4, "column": 22 }, "end": { "line": 4, "column": 63 } }, "callee": { "type": "MemberExpression", "start": 105, "end": 131, "loc": { "start": { "line": 4, "column": 26 }, "end": { "line": 4, "column": 52 } }, "object": { "type": "Identifier", "start": 105, "end": 110, "loc": { "start": { "line": 4, "column": 26 }, "end": { "line": 4, "column": 31 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 111, "end": 131, "loc": { "start": { "line": 4, "column": 32 }, "end": { "line": 4, "column": 52 }, "identifierName": "SphereBufferGeometry" }, "name": "SphereBufferGeometry" }, "computed": false }, "arguments": [ { "type": "NumericLiteral", "start": 132, "end": 133, "loc": { "start": { "line": 4, "column": 53 }, "end": { "line": 4, "column": 54 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 }, { "type": "NumericLiteral", "start": 135, "end": 137, "loc": { "start": { "line": 4, "column": 56 }, "end": { "line": 4, "column": 58 } }, "extra": { "rawValue": 32, "raw": "32" }, "value": 32 }, { "type": "NumericLiteral", "start": 139, "end": 141, "loc": { "start": { "line": 4, "column": 60 }, "end": { "line": 4, "column": 62 } }, "extra": { "rawValue": 32, "raw": "32" }, "value": 32 } ] } } ], "kind": "const" }, { "type": "VariableDeclaration", "start": 144, "end": 246, "loc": { "start": { "line": 5, "column": 0 }, "end": { "line": 5, "column": 102 } }, "declarations": [ { "type": "VariableDeclarator", "start": 150, "end": 245, "loc": { "start": { "line": 5, "column": 6 }, "end": { "line": 5, "column": 101 } }, "id": { "type": "Identifier", "start": 150, "end": 163, "loc": { "start": { "line": 5, "column": 6 }, "end": { "line": 5, "column": 19 }, "identifierName": "pointMaterial" }, "name": "pointMaterial" }, "init": { "type": "NewExpression", "start": 166, "end": 245, "loc": { "start": { "line": 5, "column": 22 }, "end": { "line": 5, "column": 101 } }, "callee": { "type": "MemberExpression", "start": 170, "end": 193, "loc": { "start": { "line": 5, "column": 26 }, "end": { "line": 5, "column": 49 } }, "object": { "type": "Identifier", "start": 170, "end": 175, "loc": { "start": { "line": 5, "column": 26 }, "end": { "line": 5, "column": 31 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 176, "end": 193, "loc": { "start": { "line": 5, "column": 32 }, "end": { "line": 5, "column": 49 }, "identifierName": "MeshBasicMaterial" }, "name": "MeshBasicMaterial" }, "computed": false }, "arguments": [ { "type": "ObjectExpression", "start": 194, "end": 244, "loc": { "start": { "line": 5, "column": 50 }, "end": { "line": 5, "column": 100 } }, "properties": [ { "type": "ObjectProperty", "start": 195, "end": 210, "loc": { "start": { "line": 5, "column": 51 }, "end": { "line": 5, "column": 66 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 195, "end": 200, "loc": { "start": { "line": 5, "column": 51 }, "end": { "line": 5, "column": 56 }, "identifierName": "color" }, "name": "color" }, "value": { "type": "NumericLiteral", "start": 202, "end": 210, "loc": { "start": { "line": 5, "column": 58 }, "end": { "line": 5, "column": 66 } }, "extra": { "rawValue": 2667735, "raw": "0x28b4d7" }, "value": 2667735 } }, { "type": "ObjectProperty", "start": 212, "end": 229, "loc": { "start": { "line": 5, "column": 68 }, "end": { "line": 5, "column": 85 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 212, "end": 223, "loc": { "start": { "line": 5, "column": 68 }, "end": { "line": 5, "column": 79 }, "identifierName": "transparent" }, "name": "transparent" }, "value": { "type": "BooleanLiteral", "start": 225, "end": 229, "loc": { "start": { "line": 5, "column": 81 }, "end": { "line": 5, "column": 85 } }, "value": true } }, { "type": "ObjectProperty", "start": 231, "end": 243, "loc": { "start": { "line": 5, "column": 87 }, "end": { "line": 5, "column": 99 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 231, "end": 238, "loc": { "start": { "line": 5, "column": 87 }, "end": { "line": 5, "column": 94 }, "identifierName": "opacity" }, "name": "opacity" }, "value": { "type": "NumericLiteral", "start": 240, "end": 243, "loc": { "start": { "line": 5, "column": 96 }, "end": { "line": 5, "column": 99 } }, "extra": { "rawValue": 0.1, "raw": "0.1" }, "value": 0.1 } } ] } ] } } ], "kind": "const" }, { "type": "VariableDeclaration", "start": 247, "end": 310, "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 6, "column": 63 } }, "declarations": [ { "type": "VariableDeclarator", "start": 253, "end": 309, "loc": { "start": { "line": 6, "column": 6 }, "end": { "line": 6, "column": 62 } }, "id": { "type": "Identifier", "start": 253, "end": 265, "loc": { "start": { "line": 6, "column": 6 }, "end": { "line": 6, "column": 18 }, "identifierName": "lineGeometry" }, "name": "lineGeometry" }, "init": { "type": "NewExpression", "start": 268, "end": 309, "loc": { "start": { "line": 6, "column": 21 }, "end": { "line": 6, "column": 62 } }, "callee": { "type": "MemberExpression", "start": 272, "end": 300, "loc": { "start": { "line": 6, "column": 25 }, "end": { "line": 6, "column": 53 } }, "object": { "type": "Identifier", "start": 272, "end": 277, "loc": { "start": { "line": 6, "column": 25 }, "end": { "line": 6, "column": 30 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 278, "end": 300, "loc": { "start": { "line": 6, "column": 31 }, "end": { "line": 6, "column": 53 }, "identifierName": "CylinderBufferGeometry" }, "name": "CylinderBufferGeometry" }, "computed": false }, "arguments": [ { "type": "NumericLiteral", "start": 301, "end": 302, "loc": { "start": { "line": 6, "column": 54 }, "end": { "line": 6, "column": 55 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 }, { "type": "NumericLiteral", "start": 304, "end": 305, "loc": { "start": { "line": 6, "column": 57 }, "end": { "line": 6, "column": 58 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 }, { "type": "NumericLiteral", "start": 307, "end": 308, "loc": { "start": { "line": 6, "column": 60 }, "end": { "line": 6, "column": 61 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 } ] } } ], "kind": "const" }, { "type": "VariableDeclaration", "start": 311, "end": 379, "loc": { "start": { "line": 7, "column": 0 }, "end": { "line": 7, "column": 68 } }, "declarations": [ { "type": "VariableDeclarator", "start": 317, "end": 378, "loc": { "start": { "line": 7, "column": 6 }, "end": { "line": 7, "column": 67 } }, "id": { "type": "Identifier", "start": 317, "end": 329, "loc": { "start": { "line": 7, "column": 6 }, "end": { "line": 7, "column": 18 }, "identifierName": "lineMaterial" }, "name": "lineMaterial" }, "init": { "type": "NewExpression", "start": 332, "end": 378, "loc": { "start": { "line": 7, "column": 21 }, "end": { "line": 7, "column": 67 } }, "callee": { "type": "MemberExpression", "start": 336, "end": 359, "loc": { "start": { "line": 7, "column": 25 }, "end": { "line": 7, "column": 48 } }, "object": { "type": "Identifier", "start": 336, "end": 341, "loc": { "start": { "line": 7, "column": 25 }, "end": { "line": 7, "column": 30 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 342, "end": 359, "loc": { "start": { "line": 7, "column": 31 }, "end": { "line": 7, "column": 48 }, "identifierName": "MeshBasicMaterial" }, "name": "MeshBasicMaterial" }, "computed": false }, "arguments": [ { "type": "ObjectExpression", "start": 360, "end": 377, "loc": { "start": { "line": 7, "column": 49 }, "end": { "line": 7, "column": 66 } }, "properties": [ { "type": "ObjectProperty", "start": 361, "end": 376, "loc": { "start": { "line": 7, "column": 50 }, "end": { "line": 7, "column": 65 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 361, "end": 366, "loc": { "start": { "line": 7, "column": 50 }, "end": { "line": 7, "column": 55 }, "identifierName": "color" }, "name": "color" }, "value": { "type": "NumericLiteral", "start": 368, "end": 376, "loc": { "start": { "line": 7, "column": 57 }, "end": { "line": 7, "column": 65 } }, "extra": { "rawValue": 16729156, "raw": "0xFF4444" }, "value": 16729156 } } ] } ] } } ], "kind": "const" }, { "type": "VariableDeclaration", "start": 380, "end": 432, "loc": { "start": { "line": 8, "column": 0 }, "end": { "line": 8, "column": 52 } }, "declarations": [ { "type": "VariableDeclarator", "start": 386, "end": 431, "loc": { "start": { "line": 8, "column": 6 }, "end": { "line": 8, "column": 51 } }, "id": { "type": "Identifier", "start": 386, "end": 397, "loc": { "start": { "line": 8, "column": 6 }, "end": { "line": 8, "column": 17 }, "identifierName": "arcGeometry" }, "name": "arcGeometry" }, "init": { "type": "NewExpression", "start": 400, "end": 431, "loc": { "start": { "line": 8, "column": 20 }, "end": { "line": 8, "column": 51 } }, "callee": { "type": "MemberExpression", "start": 404, "end": 429, "loc": { "start": { "line": 8, "column": 24 }, "end": { "line": 8, "column": 49 } }, "object": { "type": "Identifier", "start": 404, "end": 409, "loc": { "start": { "line": 8, "column": 24 }, "end": { "line": 8, "column": 29 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 410, "end": 429, "loc": { "start": { "line": 8, "column": 30 }, "end": { "line": 8, "column": 49 }, "identifierName": "TorusBufferGeometry" }, "name": "TorusBufferGeometry" }, "computed": false }, "arguments": [] } } ], "kind": "const" }, { "type": "VariableDeclaration", "start": 433, "end": 500, "loc": { "start": { "line": 9, "column": 0 }, "end": { "line": 9, "column": 67 } }, "declarations": [ { "type": "VariableDeclarator", "start": 439, "end": 499, "loc": { "start": { "line": 9, "column": 6 }, "end": { "line": 9, "column": 66 } }, "id": { "type": "Identifier", "start": 439, "end": 450, "loc": { "start": { "line": 9, "column": 6 }, "end": { "line": 9, "column": 17 }, "identifierName": "arcMaterial" }, "name": "arcMaterial" }, "init": { "type": "NewExpression", "start": 453, "end": 499, "loc": { "start": { "line": 9, "column": 20 }, "end": { "line": 9, "column": 66 } }, "callee": { "type": "MemberExpression", "start": 457, "end": 480, "loc": { "start": { "line": 9, "column": 24 }, "end": { "line": 9, "column": 47 } }, "object": { "type": "Identifier", "start": 457, "end": 462, "loc": { "start": { "line": 9, "column": 24 }, "end": { "line": 9, "column": 29 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 463, "end": 480, "loc": { "start": { "line": 9, "column": 30 }, "end": { "line": 9, "column": 47 }, "identifierName": "MeshBasicMaterial" }, "name": "MeshBasicMaterial" }, "computed": false }, "arguments": [ { "type": "ObjectExpression", "start": 481, "end": 498, "loc": { "start": { "line": 9, "column": 48 }, "end": { "line": 9, "column": 65 } }, "properties": [ { "type": "ObjectProperty", "start": 482, "end": 497, "loc": { "start": { "line": 9, "column": 49 }, "end": { "line": 9, "column": 64 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 482, "end": 487, "loc": { "start": { "line": 9, "column": 49 }, "end": { "line": 9, "column": 54 }, "identifierName": "color" }, "name": "color" }, "value": { "type": "NumericLiteral", "start": 489, "end": 497, "loc": { "start": { "line": 9, "column": 56 }, "end": { "line": 9, "column": 64 } }, "extra": { "rawValue": 16729156, "raw": "0xFF4444" }, "value": 16729156 } } ] } ] } } ], "kind": "const" }, { "type": "VariableDeclaration", "start": 501, "end": 558, "loc": { "start": { "line": 10, "column": 0 }, "end": { "line": 10, "column": 57 } }, "declarations": [ { "type": "VariableDeclarator", "start": 507, "end": 557, "loc": { "start": { "line": 10, "column": 6 }, "end": { "line": 10, "column": 56 } }, "id": { "type": "Identifier", "start": 507, "end": 520, "loc": { "start": { "line": 10, "column": 6 }, "end": { "line": 10, "column": 19 }, "identifierName": "arrowGeometry" }, "name": "arrowGeometry" }, "init": { "type": "NewExpression", "start": 523, "end": 557, "loc": { "start": { "line": 10, "column": 22 }, "end": { "line": 10, "column": 56 } }, "callee": { "type": "MemberExpression", "start": 527, "end": 551, "loc": { "start": { "line": 10, "column": 26 }, "end": { "line": 10, "column": 50 } }, "object": { "type": "Identifier", "start": 527, "end": 532, "loc": { "start": { "line": 10, "column": 26 }, "end": { "line": 10, "column": 31 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 533, "end": 551, "loc": { "start": { "line": 10, "column": 32 }, "end": { "line": 10, "column": 50 }, "identifierName": "ConeBufferGeometry" }, "name": "ConeBufferGeometry" }, "computed": false }, "arguments": [ { "type": "NumericLiteral", "start": 552, "end": 553, "loc": { "start": { "line": 10, "column": 51 }, "end": { "line": 10, "column": 52 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 }, { "type": "NumericLiteral", "start": 555, "end": 556, "loc": { "start": { "line": 10, "column": 54 }, "end": { "line": 10, "column": 55 } }, "extra": { "rawValue": 1, "raw": "1" }, "value": 1 } ] } } ], "kind": "const" }, { "type": "VariableDeclaration", "start": 559, "end": 628, "loc": { "start": { "line": 11, "column": 0 }, "end": { "line": 11, "column": 69 } }, "declarations": [ { "type": "VariableDeclarator", "start": 565, "end": 627, "loc": { "start": { "line": 11, "column": 6 }, "end": { "line": 11, "column": 68 } }, "id": { "type": "Identifier", "start": 565, "end": 578, "loc": { "start": { "line": 11, "column": 6 }, "end": { "line": 11, "column": 19 }, "identifierName": "arrowMaterial" }, "name": "arrowMaterial" }, "init": { "type": "NewExpression", "start": 581, "end": 627, "loc": { "start": { "line": 11, "column": 22 }, "end": { "line": 11, "column": 68 } }, "callee": { "type": "MemberExpression", "start": 585, "end": 608, "loc": { "start": { "line": 11, "column": 26 }, "end": { "line": 11, "column": 49 } }, "object": { "type": "Identifier", "start": 585, "end": 590, "loc": { "start": { "line": 11, "column": 26 }, "end": { "line": 11, "column": 31 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 591, "end": 608, "loc": { "start": { "line": 11, "column": 32 }, "end": { "line": 11, "column": 49 }, "identifierName": "MeshBasicMaterial" }, "name": "MeshBasicMaterial" }, "computed": false }, "arguments": [ { "type": "ObjectExpression", "start": 609, "end": 626, "loc": { "start": { "line": 11, "column": 50 }, "end": { "line": 11, "column": 67 } }, "properties": [ { "type": "ObjectProperty", "start": 610, "end": 625, "loc": { "start": { "line": 11, "column": 51 }, "end": { "line": 11, "column": 66 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 610, "end": 615, "loc": { "start": { "line": 11, "column": 51 }, "end": { "line": 11, "column": 56 }, "identifierName": "color" }, "name": "color" }, "value": { "type": "NumericLiteral", "start": 617, "end": 625, "loc": { "start": { "line": 11, "column": 58 }, "end": { "line": 11, "column": 66 } }, "extra": { "rawValue": 16729156, "raw": "0xFF4444" }, "value": 16729156 } } ] } ] } } ], "kind": "const" }, { "type": "ExportDefaultDeclaration", "start": 630, "end": 5582, "loc": { "start": { "line": 13, "column": 0 }, "end": { "line": 122, "column": 1 } }, "declaration": { "type": "ClassDeclaration", "start": 645, "end": 5582, "loc": { "start": { "line": 13, "column": 15 }, "end": { "line": 122, "column": 1 } }, "id": { "type": "Identifier", "start": 651, "end": 663, "loc": { "start": { "line": 13, "column": 21 }, "end": { "line": 13, "column": 33 }, "identifierName": "BaseGraphics" }, "name": "BaseGraphics" }, "superClass": { "type": "MemberExpression", "start": 672, "end": 686, "loc": { "start": { "line": 13, "column": 42 }, "end": { "line": 13, "column": 56 } }, "object": { "type": "Identifier", "start": 672, "end": 677, "loc": { "start": { "line": 13, "column": 42 }, "end": { "line": 13, "column": 47 }, "identifierName": "THREE" }, "name": "THREE" }, "property": { "type": "Identifier", "start": 678, "end": 686, "loc": { "start": { "line": 13, "column": 48 }, "end": { "line": 13, "column": 56 }, "identifierName": "Object3D" }, "name": "Object3D" }, "computed": false }, "body": { "type": "ClassBody", "start": 687, "end": 5582, "loc": { "start": { "line": 13, "column": 57 }, "end": { "line": 122, "column": 1 } }, "body": [ { "type": "ClassMethod", "start": 693, "end": 2919, "loc": { "start": { "line": 14, "column": 4 }, "end": { "line": 59, "column": 5 } }, "computed": false, "key": { "type": "Identifier", "start": 693, "end": 704, "loc": { "start": { "line": 14, "column": 4 }, "end": { "line": 14, "column": 15 },