[ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "Renders the final tree of ", "position": { "start": { "line": 1, "column": 3, "offset": 2 }, "end": { "line": 1, "column": 29, "offset": 28 }, "indent": [] } }, { "type": "link", "title": null, "url": "#node", "children": [ { "type": "text", "value": "Node", "position": { "start": { "line": 1, "column": 30, "offset": 29 }, "end": { "line": 1, "column": 34, "offset": 33 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 29, "offset": 28 }, "end": { "line": 1, "column": 42, "offset": 41 }, "indent": [] } }, { "type": "text", "value": " in a WebGL Canvas / OpenGLView /...", "position": { "start": { "line": 1, "column": 42, "offset": 41 }, "end": { "line": 1, "column": 78, "offset": 77 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 80, "offset": 79 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 80, "offset": 79 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "", "position": { "start": { "line": 3, "column": 1, "offset": 81 }, "end": { "line": 3, "column": 12, "offset": 92 }, "indent": [] } }, { "type": "text", "value": " performs the final GL draws for a given implementation.", "position": { "start": { "line": 3, "column": 12, "offset": 92 }, "end": { "line": 3, "column": 68, "offset": 148 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 81 }, "end": { "line": 3, "column": 68, "offset": 148 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "width", "position": { "start": { "line": 5, "column": 1, "offset": 150 }, "end": { "line": 5, "column": 8, "offset": 157 }, "indent": [] } }, { "type": "text", "value": " and ", "position": { "start": { "line": 5, "column": 8, "offset": 157 }, "end": { "line": 5, "column": 13, "offset": 162 }, "indent": [] } }, { "type": "inlineCode", "value": "height", "position": { "start": { "line": 5, "column": 13, "offset": 162 }, "end": { "line": 5, "column": 21, "offset": 170 }, "indent": [] } }, { "type": "text", "value": " props are required for ", "position": { "start": { "line": 5, "column": 21, "offset": 170 }, "end": { "line": 5, "column": 45, "offset": 194 }, "indent": [] } }, { "type": "inlineCode", "value": "gl-react-dom", "position": { "start": { "line": 5, "column": 45, "offset": 194 }, "end": { "line": 5, "column": 59, "offset": 208 }, "indent": [] } }, { "type": "text", "value": " and ", "position": { "start": { "line": 5, "column": 59, "offset": 208 }, "end": { "line": 5, "column": 64, "offset": 213 }, "indent": [] } }, { "type": "inlineCode", "value": "gl-react-headless", "position": { "start": { "line": 5, "column": 64, "offset": 213 }, "end": { "line": 5, "column": 83, "offset": 232 }, "indent": [] } }, { "type": "text", "value": ", but are not supported for React Native, where the paradigm is to use ", "position": { "start": { "line": 5, "column": 83, "offset": 232 }, "end": { "line": 5, "column": 154, "offset": 303 }, "indent": [] } }, { "type": "inlineCode", "value": "style", "position": { "start": { "line": 5, "column": 154, "offset": 303 }, "end": { "line": 5, "column": 161, "offset": 310 }, "indent": [] } }, { "type": "text", "value": " (and either use flexbox or set a width/height from there).", "position": { "start": { "line": 5, "column": 161, "offset": 310 }, "end": { "line": 5, "column": 220, "offset": 369 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 1, "offset": 150 }, "end": { "line": 5, "column": 220, "offset": 369 }, "indent": [] } }, { "type": "blockquote", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Surface is the only component that isn't \"universal\",\ntherefore ", "position": { "start": { "line": 7, "column": 3, "offset": 373 }, "end": { "line": 8, "column": 11, "offset": 437 }, "indent": [ 1 ] } }, { "type": "strong", "children": [ { "type": "text", "value": "Surface is exposed by the platform implementation", "position": { "start": { "line": 8, "column": 13, "offset": 439 }, "end": { "line": 8, "column": 62, "offset": 488 }, "indent": [] } } ], "position": { "start": { "line": 8, "column": 11, "offset": 437 }, "end": { "line": 8, "column": 64, "offset": 490 }, "indent": [] } }, { "type": "text", "value": "\n(", "position": { "start": { "line": 8, "column": 64, "offset": 490 }, "end": { "line": 9, "column": 2, "offset": 492 }, "indent": [ 1 ] } }, { "type": "inlineCode", "value": "gl-react-dom", "position": { "start": { "line": 9, "column": 2, "offset": 492 }, "end": { "line": 9, "column": 16, "offset": 506 }, "indent": [] } }, { "type": "text", "value": " / ", "position": { "start": { "line": 9, "column": 16, "offset": 506 }, "end": { "line": 9, "column": 19, "offset": 509 }, "indent": [] } }, { "type": "inlineCode", "value": "gl-react-native", "position": { "start": { "line": 9, "column": 19, "offset": 509 }, "end": { "line": 9, "column": 36, "offset": 526 }, "indent": [] } }, { "type": "text", "value": " / ...),\nunlike the rest of the API exposed through ", "position": { "start": { "line": 9, "column": 36, "offset": 526 }, "end": { "line": 10, "column": 44, "offset": 578 }, "indent": [ 1 ] } }, { "type": "inlineCode", "value": "gl-react", "position": { "start": { "line": 10, "column": 44, "offset": 578 }, "end": { "line": 10, "column": 54, "offset": 588 }, "indent": [] } }, { "type": "text", "value": ".\nEach platform have its own implementation but most props are shared.\nIf you write a gl-react library, you shouldn't use ", "position": { "start": { "line": 10, "column": 54, "offset": 588 }, "end": { "line": 12, "column": 52, "offset": 710 }, "indent": [ 1, 1 ] } }, { "type": "inlineCode", "value": "", "position": { "start": { "line": 12, "column": 52, "offset": 710 }, "end": { "line": 12, "column": 63, "offset": 721 }, "indent": [] } }, { "type": "text", "value": " but only\nlet the final user doing it. Therefore your code should remain platform-independant.", "position": { "start": { "line": 12, "column": 63, "offset": 721 }, "end": { "line": 13, "column": 85, "offset": 815 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 7, "column": 3, "offset": 373 }, "end": { "line": 13, "column": 85, "offset": 815 }, "indent": [ 1, 1, 1, 1, 1, 1 ] } } ], "position": { "start": { "line": 7, "column": 1, "offset": 371 }, "end": { "line": 13, "column": 85, "offset": 815 }, "indent": [ 1, 1, 1, 1, 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 13, "column": 85, "offset": 815 } } }, "tags": [ { "title": "class", "description": null, "lineNumber": 15, "type": null, "name": "Surface" }, { "title": "extends", "description": null, "lineNumber": 16, "type": null, "name": "Component" }, { "title": "prop", "description": "a tree of React Element that renders some [Node](#node) and/or [Bus](#bus).", "lineNumber": 17, "type": { "type": "NameExpression", "name": "any" }, "name": "children" }, { "title": "prop", "description": "**(only for DOM)** - width of the Surface. multiplied by `pixelRatio` for the actual canvas pixel size.", "lineNumber": 18, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } }, "name": "width" }, { "title": "prop", "description": "**(only for DOM)** - height of the Surface. multiplied by `pixelRatio` for the actual canvas pixel size.", "lineNumber": 19, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } }, "name": "height" }, { "title": "prop", "description": "CSS styles that get passed to the underlying `` or ``", "lineNumber": 20, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "object" } }, "name": "style" }, { "title": "prop", "description": "an array of things to preload before the Surface start rendering. Help avoiding blinks and providing required textures to render an initial state.", "lineNumber": 21, "type": { "type": "OptionalType", "expression": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "any" } ] } }, "name": "preload" }, { "title": "prop", "description": "a callback called when Surface is ready and just after it rendered.", "lineNumber": 22, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "function" } }, "name": "onLoad" }, { "title": "prop", "description": "a callback called when the Surface was not able to load initially.", "lineNumber": 23, "type": { "type": "OptionalType", "expression": { "type": "FunctionType", "params": [ { "type": "ParameterType", "name": "error", "expression": { "type": "NameExpression", "name": "Error" } } ], "result": { "type": "VoidLiteral" } } }, "name": "onLoadError" }, { "title": "prop", "description": "a callback called when the Surface context was lost.", "lineNumber": 24, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "function" } }, "name": "onContextLost" }, { "title": "prop", "description": "a callback called when the Surface was restored and ready.", "lineNumber": 25, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "function" } }, "name": "onContextRestored" }, { "title": "prop", "description": "an internal visitor used for logs and tests.", "lineNumber": 26, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Visitor" } }, "name": "visitor" }, { "title": "prop", "description": "**(gl-react-dom only)** a optional set of attributes to init WebGL with.", "lineNumber": 28, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "WebGLContextAttributes" } }, "name": "webglContextAttributes" }, { "title": "prop", "description": "**(gl-react-dom only)** allows to override the pixelRatio. (default `devicePixelRatio`)", "lineNumber": 29, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } }, "name": "pixelRatio", "default": "window.devicePixelRatio" }, { "title": "example", "description": "\n \n ", "lineNumber": 31 }, { "title": "example", "description": "\n \n ", "lineNumber": 37 }, { "title": "example", "description": "\n \n \n https://i.imgur.com/wxqlQkh.jpg\n \n \n ", "lineNumber": 43 } ], "loc": { "start": { "line": 99, "column": 0 }, "end": { "line": 151, "column": 3 } }, "context": { "loc": { "start": { "line": 152, "column": 0 }, "end": { "line": 556, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/createSurface.js", "path": "packages/gl-react/src/createSurface.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/createSurface.js#L152-L556" }, "kind": "class", "name": "Surface", "augments": [ { "title": "extends", "description": null, "lineNumber": 16, "type": null, "name": "Component" } ], "properties": [ { "name": "children", "lineNumber": 17, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a tree of React Element that renders some ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 43, "offset": 42 }, "indent": [] } }, { "type": "link", "title": null, "url": "#node", "children": [ { "type": "text", "value": "Node", "position": { "start": { "line": 1, "column": 44, "offset": 43 }, "end": { "line": 1, "column": 48, "offset": 47 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 43, "offset": 42 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } }, { "type": "text", "value": " and/or ", "position": { "start": { "line": 1, "column": 56, "offset": 55 }, "end": { "line": 1, "column": 64, "offset": 63 }, "indent": [] } }, { "type": "link", "title": null, "url": "#bus", "children": [ { "type": "text", "value": "Bus", "position": { "start": { "line": 1, "column": 65, "offset": 64 }, "end": { "line": 1, "column": 68, "offset": 67 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 64, "offset": 63 }, "end": { "line": 1, "column": 75, "offset": 74 }, "indent": [] } }, { "type": "text", "value": ".", "position": { "start": { "line": 1, "column": 75, "offset": 74 }, "end": { "line": 1, "column": 76, "offset": 75 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 76, "offset": 75 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 76, "offset": 75 } } }, "type": { "type": "NameExpression", "name": "any" } }, { "name": "width", "lineNumber": 18, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "(only for DOM)", "position": { "start": { "line": 1, "column": 3, "offset": 2 }, "end": { "line": 1, "column": 17, "offset": 16 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 19, "offset": 18 }, "indent": [] } }, { "type": "text", "value": " - width of the Surface. multiplied by ", "position": { "start": { "line": 1, "column": 19, "offset": 18 }, "end": { "line": 1, "column": 58, "offset": 57 }, "indent": [] } }, { "type": "inlineCode", "value": "pixelRatio", "position": { "start": { "line": 1, "column": 58, "offset": 57 }, "end": { "line": 1, "column": 70, "offset": 69 }, "indent": [] } }, { "type": "text", "value": " for the actual canvas pixel size.", "position": { "start": { "line": 1, "column": 70, "offset": 69 }, "end": { "line": 1, "column": 104, "offset": 103 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 104, "offset": 103 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 104, "offset": 103 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } } }, { "name": "height", "lineNumber": 19, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "(only for DOM)", "position": { "start": { "line": 1, "column": 3, "offset": 2 }, "end": { "line": 1, "column": 17, "offset": 16 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 19, "offset": 18 }, "indent": [] } }, { "type": "text", "value": " - height of the Surface. multiplied by ", "position": { "start": { "line": 1, "column": 19, "offset": 18 }, "end": { "line": 1, "column": 59, "offset": 58 }, "indent": [] } }, { "type": "inlineCode", "value": "pixelRatio", "position": { "start": { "line": 1, "column": 59, "offset": 58 }, "end": { "line": 1, "column": 71, "offset": 70 }, "indent": [] } }, { "type": "text", "value": " for the actual canvas pixel size.", "position": { "start": { "line": 1, "column": 71, "offset": 70 }, "end": { "line": 1, "column": 105, "offset": 104 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 105, "offset": 104 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 105, "offset": 104 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } } }, { "name": "style", "lineNumber": 20, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "CSS styles that get passed to the underlying ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 46, "offset": 45 }, "indent": [] } }, { "type": "inlineCode", "value": "", "position": { "start": { "line": 1, "column": 46, "offset": 45 }, "end": { "line": 1, "column": 57, "offset": 56 }, "indent": [] } }, { "type": "text", "value": " or ", "position": { "start": { "line": 1, "column": 57, "offset": 56 }, "end": { "line": 1, "column": 61, "offset": 60 }, "indent": [] } }, { "type": "inlineCode", "value": "", "position": { "start": { "line": 1, "column": 61, "offset": 60 }, "end": { "line": 1, "column": 70, "offset": 69 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 70, "offset": 69 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 70, "offset": 69 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "object" } } }, { "name": "preload", "lineNumber": 21, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "an array of things to preload before the Surface start rendering. Help avoiding blinks and providing required textures to render an initial state.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 147, "offset": 146 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 147, "offset": 146 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 147, "offset": 146 } } }, "type": { "type": "OptionalType", "expression": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "any" } ] } } }, { "name": "onLoad", "lineNumber": 22, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a callback called when Surface is ready and just after it rendered.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 68, "offset": 67 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 68, "offset": 67 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 68, "offset": 67 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "function" } } }, { "name": "onLoadError", "lineNumber": 23, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a callback called when the Surface was not able to load initially.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 } } }, "type": { "type": "OptionalType", "expression": { "type": "FunctionType", "params": [ { "type": "ParameterType", "name": "error", "expression": { "type": "NameExpression", "name": "Error" } } ], "result": { "type": "VoidLiteral" } } } }, { "name": "onContextLost", "lineNumber": 24, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a callback called when the Surface context was lost.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 53, "offset": 52 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 53, "offset": 52 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 53, "offset": 52 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "function" } } }, { "name": "onContextRestored", "lineNumber": 25, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a callback called when the Surface was restored and ready.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 59, "offset": 58 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 59, "offset": 58 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 59, "offset": 58 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "function" } } }, { "name": "visitor", "lineNumber": 26, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "an internal visitor used for logs and tests.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 45, "offset": 44 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 45, "offset": 44 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 45, "offset": 44 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Visitor" } } }, { "name": "webglContextAttributes", "lineNumber": 28, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "(gl-react-dom only)", "position": { "start": { "line": 1, "column": 3, "offset": 2 }, "end": { "line": 1, "column": 22, "offset": 21 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 24, "offset": 23 }, "indent": [] } }, { "type": "text", "value": " a optional set of attributes to init WebGL with.", "position": { "start": { "line": 1, "column": 24, "offset": 23 }, "end": { "line": 1, "column": 73, "offset": 72 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 73, "offset": 72 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 73, "offset": 72 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "WebGLContextAttributes" } } }, { "name": "pixelRatio", "lineNumber": 29, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "(gl-react-dom only)", "position": { "start": { "line": 1, "column": 3, "offset": 2 }, "end": { "line": 1, "column": 22, "offset": 21 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 24, "offset": 23 }, "indent": [] } }, { "type": "text", "value": " allows to override the pixelRatio. (default ", "position": { "start": { "line": 1, "column": 24, "offset": 23 }, "end": { "line": 1, "column": 69, "offset": 68 }, "indent": [] } }, { "type": "inlineCode", "value": "devicePixelRatio", "position": { "start": { "line": 1, "column": 69, "offset": 68 }, "end": { "line": 1, "column": 87, "offset": 86 }, "indent": [] } }, { "type": "text", "value": ")", "position": { "start": { "line": 1, "column": 87, "offset": 86 }, "end": { "line": 1, "column": 88, "offset": 87 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 88, "offset": 87 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 88, "offset": 87 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } } } ], "examples": [ { "description": "\n \n " }, { "description": "\n \n " }, { "description": "\n \n \n https://i.imgur.com/wxqlQkh.jpg\n \n \n " } ], "members": { "instance": [ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "see ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 5, "offset": 4 }, "indent": [] } }, { "type": "link", "title": null, "url": "https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toDataURL", "children": [ { "type": "text", "value": "https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toDataURL", "position": { "start": { "line": 1, "column": 5, "offset": 4 }, "end": { "line": 1, "column": 81, "offset": 80 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 5, "offset": 4 }, "end": { "line": 1, "column": 81, "offset": 80 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 81, "offset": 80 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 81, "offset": 80 } } }, "tags": [ { "title": "param", "description": "(optional) the image MimeType", "lineNumber": 2, "type": { "type": "NameExpression", "name": "string" }, "name": "mimeType" }, { "title": "param", "description": "(optional) the image quality", "lineNumber": 3, "type": { "type": "NameExpression", "name": "number" }, "name": "quality" }, { "title": "memberof", "description": "Surface", "lineNumber": 4 }, { "title": "instance", "description": null, "lineNumber": 5 } ], "loc": { "start": { "line": 267, "column": 2 }, "end": { "line": 273, "column": 5 } }, "context": { "loc": { "start": { "line": 274, "column": 2 }, "end": { "line": 277, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/createSurface.js", "path": "packages/gl-react/src/createSurface.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/createSurface.js#L274-L277" }, "params": [ { "name": "mimeType", "lineNumber": 2, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "(optional) the image MimeType", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 } } }, "type": { "type": "NameExpression", "name": "string" } }, { "name": "quality", "lineNumber": 3, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "(optional) the image quality", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 29, "offset": 28 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 29, "offset": 28 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 29, "offset": 28 } } }, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "args", "lineNumber": 274, "type": { "type": "RestType", "expression": { "type": "AllLiteral" } } } ], "memberof": "Surface", "scope": "instance", "name": "captureAsDataURL", "kind": "function", "returns": [ { "type": { "type": "NameExpression", "name": "string" } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Surface", "kind": "class" }, { "name": "captureAsDataURL", "kind": "function", "scope": "instance" } ], "namespace": "Surface#captureAsDataURL" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "see ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 5, "offset": 4 }, "indent": [] } }, { "type": "link", "title": null, "url": "https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob", "children": [ { "type": "text", "value": "https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob", "position": { "start": { "line": 1, "column": 5, "offset": 4 }, "end": { "line": 1, "column": 78, "offset": 77 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 5, "offset": 4 }, "end": { "line": 1, "column": 78, "offset": 77 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 78, "offset": 77 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 78, "offset": 77 } } }, "tags": [ { "title": "param", "description": "(optional) the image MimeType", "lineNumber": 2, "type": { "type": "NameExpression", "name": "string" }, "name": "mimeType" }, { "title": "param", "description": "(optional) the image quality", "lineNumber": 3, "type": { "type": "NameExpression", "name": "number" }, "name": "quality" }, { "title": "memberof", "description": "Surface", "lineNumber": 4 }, { "title": "instance", "description": null, "lineNumber": 5 } ], "loc": { "start": { "line": 279, "column": 2 }, "end": { "line": 285, "column": 5 } }, "context": { "loc": { "start": { "line": 286, "column": 2 }, "end": { "line": 289, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/createSurface.js", "path": "packages/gl-react/src/createSurface.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/createSurface.js#L286-L289" }, "params": [ { "name": "mimeType", "lineNumber": 2, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "(optional) the image MimeType", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 } } }, "type": { "type": "NameExpression", "name": "string" } }, { "name": "quality", "lineNumber": 3, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "(optional) the image quality", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 29, "offset": 28 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 29, "offset": 28 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 29, "offset": 28 } } }, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "args", "lineNumber": 286, "type": { "type": "RestType", "expression": { "type": "AllLiteral" } } } ], "memberof": "Surface", "scope": "instance", "name": "captureAsBlob", "kind": "function", "returns": [ { "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Promise" }, "applications": [ { "type": "NameExpression", "name": "Blob" } ] } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Surface", "kind": "class" }, { "name": "captureAsBlob", "kind": "function", "scope": "instance" } ], "namespace": "Surface#captureAsBlob" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "capture the root Node pixels. Make sure you have set ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 54, "offset": 53 }, "indent": [] } }, { "type": "inlineCode", "value": "preserveDrawingBuffer: true", "position": { "start": { "line": 1, "column": 54, "offset": 53 }, "end": { "line": 1, "column": 83, "offset": 82 }, "indent": [] } }, { "type": "text", "value": " in ", "position": { "start": { "line": 1, "column": 83, "offset": 82 }, "end": { "line": 1, "column": 87, "offset": 86 }, "indent": [] } }, { "type": "inlineCode", "value": "webglContextAttributes", "position": { "start": { "line": 1, "column": 87, "offset": 86 }, "end": { "line": 1, "column": 111, "offset": 110 }, "indent": [] } }, { "type": "text", "value": " prop.", "position": { "start": { "line": 1, "column": 111, "offset": 110 }, "end": { "line": 1, "column": 117, "offset": 116 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 117, "offset": 116 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 117, "offset": 116 } } }, "tags": [ { "title": "memberof", "description": "Surface", "lineNumber": 2 }, { "title": "instance", "description": null, "lineNumber": 3 } ], "loc": { "start": { "line": 291, "column": 2 }, "end": { "line": 295, "column": 5 } }, "context": { "loc": { "start": { "line": 296, "column": 2 }, "end": { "line": 299, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/createSurface.js", "path": "packages/gl-react/src/createSurface.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/createSurface.js#L296-L299" }, "memberof": "Surface", "scope": "instance", "name": "capture", "kind": "function", "params": [ { "title": "param", "name": "x", "lineNumber": 296, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "y", "lineNumber": 296, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "w", "lineNumber": 296, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "h", "lineNumber": 296, "type": { "type": "NameExpression", "name": "number" } } ], "returns": [ { "type": { "type": "NameExpression", "name": "NDArray" } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Surface", "kind": "class" }, { "name": "capture", "kind": "function", "scope": "instance" } ], "namespace": "Surface#capture" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Schedule a redraw of the Surface.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 34, "offset": 33 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 34, "offset": 33 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 34, "offset": 33 } } }, "tags": [ { "title": "memberof", "description": "Surface", "lineNumber": 2 }, { "title": "instance", "description": null, "lineNumber": 3 }, { "title": "function", "description": null, "lineNumber": 4, "name": null } ], "loc": { "start": { "line": 301, "column": 2 }, "end": { "line": 306, "column": 5 } }, "context": { "loc": { "start": { "line": 307, "column": 2 }, "end": { "line": 309, "column": 4 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/createSurface.js", "path": "packages/gl-react/src/createSurface.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/createSurface.js#L307-L309" }, "memberof": "Surface", "scope": "instance", "kind": "function", "name": "redraw", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Surface", "kind": "class" }, { "name": "redraw", "kind": "function", "scope": "instance" } ], "namespace": "Surface#redraw" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Force the redraw (if any) to happen now, synchronously.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 } } }, "tags": [ { "title": "memberof", "description": "Surface", "lineNumber": 2 }, { "title": "instance", "description": null, "lineNumber": 3 }, { "title": "function", "description": null, "lineNumber": 4, "name": null } ], "loc": { "start": { "line": 311, "column": 2 }, "end": { "line": 316, "column": 5 } }, "context": { "loc": { "start": { "line": 317, "column": 2 }, "end": { "line": 319, "column": 4 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/createSurface.js", "path": "packages/gl-react/src/createSurface.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/createSurface.js#L317-L319" }, "memberof": "Surface", "scope": "instance", "kind": "function", "name": "flush", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Surface", "kind": "class" }, { "name": "flush", "kind": "function", "scope": "instance" } ], "namespace": "Surface#flush" } ], "static": [], "events": [] }, "path": [ { "name": "Surface", "kind": "class" } ], "namespace": "Surface" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 9, "offset": 8 }, "indent": [] } }, { "type": "text", "value": " is the primitive that renders a shader program into a Framebuffer.\nIt can be composed with other ", "position": { "start": { "line": 1, "column": 9, "offset": 8 }, "end": { "line": 2, "column": 31, "offset": 106 }, "indent": [ 1 ] } }, { "type": "inlineCode", "value": "Node", "position": { "start": { "line": 2, "column": 31, "offset": 106 }, "end": { "line": 2, "column": 37, "offset": 112 }, "indent": [] } }, { "type": "text", "value": " via using a sampler2D uniforms.", "position": { "start": { "line": 2, "column": 37, "offset": 112 }, "end": { "line": 2, "column": 69, "offset": 144 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 69, "offset": 144 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 69, "offset": 144 } } }, "tags": [ { "title": "prop", "description": "created with `Shaders.create`", "lineNumber": 4, "type": { "type": "NameExpression", "name": "ShaderIdentifier" }, "name": "shader" }, { "title": "prop", "description": "uniform values that gets passed to the fragment shader.", "lineNumber": 5, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Uniforms" } }, "name": "uniforms" }, { "title": "prop", "description": "allows to configure things like interpolation of a sampler2D texture.", "lineNumber": 6, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Object" } }, "name": "uniformsOptions" }, { "title": "prop", "description": "the width in in real pixels unit (unlike Surface, no pixel ratio)", "lineNumber": 7, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } }, "name": "width" }, { "title": "prop", "description": "the height in in real pixels unit (unlike Surface, no pixel ratio)", "lineNumber": 8, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } }, "name": "height" }, { "title": "prop", "description": "If true, a React update will always force a sync redraw of the Node framebuffer.", "lineNumber": 9, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "bool" } }, "name": "sync" }, { "title": "prop", "description": "enable the backbuffering that allows to use `Backbuffer` in uniforms to get the previous framebuffer texture state in the fragment shader.", "lineNumber": 10, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "bool" } }, "name": "backbuffering" }, { "title": "prop", "description": "configure the blending function to use", "lineNumber": 11, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "BlendFuncSrcDst" } }, "name": "blendFunc" }, { "title": "prop", "description": "configure the clear to use (color,...)", "lineNumber": 12, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Clear" } }, "name": "clear" }, { "title": "prop", "description": "in advanced use-cases, you can render things like Bus or contents to be used by Node", "lineNumber": 13, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "any" } }, "name": "children" }, { "title": "example", "description": "", "lineNumber": 14 } ], "loc": { "start": { "line": 336, "column": 0 }, "end": { "line": 352, "column": 3 } }, "context": { "loc": { "start": { "line": 353, "column": 0 }, "end": { "line": 1010, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L353-L1010" }, "properties": [ { "name": "shader", "lineNumber": 4, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "created with ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 14, "offset": 13 }, "indent": [] } }, { "type": "inlineCode", "value": "Shaders.create", "position": { "start": { "line": 1, "column": 14, "offset": 13 }, "end": { "line": 1, "column": 30, "offset": 29 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 30, "offset": 29 } } }, "type": { "type": "NameExpression", "name": "ShaderIdentifier" } }, { "name": "uniforms", "lineNumber": 5, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "uniform values that gets passed to the fragment shader.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Uniforms" } } }, { "name": "uniformsOptions", "lineNumber": 6, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "allows to configure things like interpolation of a sampler2D texture.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 70, "offset": 69 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 70, "offset": 69 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 70, "offset": 69 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Object" } } }, { "name": "width", "lineNumber": 7, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "the width in in real pixels unit (unlike Surface, no pixel ratio)", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 66, "offset": 65 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 66, "offset": 65 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 66, "offset": 65 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } } }, { "name": "height", "lineNumber": 8, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "the height in in real pixels unit (unlike Surface, no pixel ratio)", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "number" } } }, { "name": "sync", "lineNumber": 9, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "If true, a React update will always force a sync redraw of the Node framebuffer.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 81, "offset": 80 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 81, "offset": 80 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 81, "offset": 80 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "bool" } } }, { "name": "backbuffering", "lineNumber": 10, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "enable the backbuffering that allows to use ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 45, "offset": 44 }, "indent": [] } }, { "type": "inlineCode", "value": "Backbuffer", "position": { "start": { "line": 1, "column": 45, "offset": 44 }, "end": { "line": 1, "column": 57, "offset": 56 }, "indent": [] } }, { "type": "text", "value": " in uniforms to get the previous framebuffer texture state in the fragment shader.", "position": { "start": { "line": 1, "column": 57, "offset": 56 }, "end": { "line": 1, "column": 139, "offset": 138 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 139, "offset": 138 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 139, "offset": 138 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "bool" } } }, { "name": "blendFunc", "lineNumber": 11, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "configure the blending function to use", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "BlendFuncSrcDst" } } }, { "name": "clear", "lineNumber": 12, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "configure the clear to use (color,...)", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "Clear" } } }, { "name": "children", "lineNumber": 13, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "in advanced use-cases, you can render things like Bus or contents to be used by Node", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 85, "offset": 84 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 85, "offset": 84 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 85, "offset": 84 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "any" } } } ], "examples": [ { "description": "" } ], "name": "Node", "augments": [ { "title": "augments", "name": "Component" } ], "kind": "class", "members": { "instance": [ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Capture the node pixels.\nWithout parameters, it will capture the full rectangle,\notherwise you can provide (x, y) or (x, y, w, h) to provide a subset of this rectangle.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 88, "offset": 168 }, "indent": [ 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 88, "offset": 168 }, "indent": [ 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 88, "offset": 168 } } }, "tags": [], "loc": { "start": { "line": 508, "column": 2 }, "end": { "line": 512, "column": 5 } }, "context": { "loc": { "start": { "line": 513, "column": 2 }, "end": { "line": 531, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L513-L531" }, "name": "capture", "kind": "function", "params": [ { "title": "param", "name": "x", "lineNumber": 513, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "y", "lineNumber": 513, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "w", "lineNumber": 513, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "h", "lineNumber": 513, "type": { "type": "NameExpression", "name": "number" } } ], "returns": [ { "type": { "type": "NameExpression", "name": "NDArray" } } ], "memberof": "Node", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Node", "kind": "class" }, { "name": "capture", "kind": "function", "scope": "instance" } ], "namespace": "Node#capture" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Schedule a redraw of this node and all dependent nodes.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 } } }, "tags": [ { "title": "function", "description": null, "lineNumber": 3, "name": null } ], "loc": { "start": { "line": 533, "column": 2 }, "end": { "line": 537, "column": 5 } }, "context": { "loc": { "start": { "line": 538, "column": 2 }, "end": { "line": 543, "column": 4 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L538-L543" }, "kind": "function", "name": "redraw", "memberof": "Node", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Node", "kind": "class" }, { "name": "redraw", "kind": "function", "scope": "instance" } ], "namespace": "Node#redraw" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Force the redraw (if any) to happen now, synchronously.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 } } }, "tags": [ { "title": "function", "description": null, "lineNumber": 3, "name": null } ], "loc": { "start": { "line": 545, "column": 2 }, "end": { "line": 549, "column": 5 } }, "context": { "loc": { "start": { "line": 550, "column": 2 }, "end": { "line": 552, "column": 4 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L550-L552" }, "kind": "function", "name": "flush", "memberof": "Node", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Node", "kind": "class" }, { "name": "flush", "kind": "function", "scope": "instance" } ], "namespace": "Node#flush" } ], "static": [], "events": [] }, "path": [ { "name": "Node", "kind": "class" } ], "namespace": "Node" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Define shaders statically.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 27, "offset": 26 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 27, "offset": 26 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 27, "offset": 26 } } }, "tags": [ { "title": "namespace", "description": null, "lineNumber": 2, "name": null } ], "loc": { "start": { "line": 104, "column": 0 }, "end": { "line": 107, "column": 3 } }, "context": { "loc": { "start": { "line": 108, "column": 0 }, "end": { "line": 149, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Shaders.js", "path": "packages/gl-react/src/Shaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Shaders.js#L108-L149" }, "kind": "namespace", "name": "Shaders", "members": { "instance": [], "static": [ { "description": "", "tags": [ { "title": "memberof", "description": "Shaders", "lineNumber": 1 }, { "title": "param", "description": "an object that statically define all shaders.", "lineNumber": 2, "type": { "type": "NameExpression", "name": "ShadersDefinition" }, "name": "shadersDef" }, { "title": "returns", "description": ", an object map that returns a ShaderIdentifier for each shader key defined in the shaders definition.", "lineNumber": 3, "type": { "type": "NameExpression", "name": "ShadersSheet" } }, { "title": "example", "description": "const shaders = Shaders.create({\n helloGL: {\n frag: GLSL`...`\n }\n });\n ...\n ", "lineNumber": 4 } ], "loc": { "start": { "line": 109, "column": 2 }, "end": { "line": 121, "column": 5 } }, "context": { "loc": { "start": { "line": 122, "column": 2 }, "end": { "line": 138, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Shaders.js", "path": "packages/gl-react/src/Shaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Shaders.js#L122-L138" }, "memberof": "Shaders", "params": [ { "name": "shadersDef", "lineNumber": 2, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "an object that statically define all shaders.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 46, "offset": 45 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 46, "offset": 45 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 46, "offset": 45 } } }, "type": { "type": "NameExpression", "name": "ShadersDefinition" } } ], "returns": [ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": ", an object map that returns a ShaderIdentifier for each shader key defined in the shaders definition.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 103, "offset": 102 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 103, "offset": 102 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 103, "offset": 102 } } }, "type": { "type": "NameExpression", "name": "ShadersSheet" } } ], "examples": [ { "description": "const shaders = Shaders.create({\n helloGL: {\n frag: GLSL`...`\n }\n });\n ...\n " } ], "name": "create", "kind": "function", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Shaders", "kind": "namespace" }, { "name": "create", "kind": "function" } ], "namespace": "Shaderscreate" } ], "events": [] }, "path": [ { "name": "Shaders", "kind": "namespace" } ], "namespace": "Shaders" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "copy pixel with a linear interpolation", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 39, "offset": 38 } } }, "tags": [ { "title": "prop", "description": "content to render", "lineNumber": 2, "type": { "type": "NameExpression", "name": "any" }, "name": "children" } ], "loc": { "start": { "line": 10, "column": 0 }, "end": { "line": 13, "column": 3 } }, "context": { "loc": { "start": { "line": 14, "column": 0 }, "end": { "line": 24, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/LinearCopy.js", "path": "packages/gl-react/src/LinearCopy.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/LinearCopy.js#L14-L24" }, "properties": [ { "name": "children", "lineNumber": 2, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "content to render", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 18, "offset": 17 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 18, "offset": 17 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 18, "offset": 17 } } }, "type": { "type": "NameExpression", "name": "any" } } ], "name": "LinearCopy", "augments": [ { "title": "augments", "name": "Component" } ], "kind": "class", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "LinearCopy", "kind": "class" } ], "namespace": "LinearCopy" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "copy pixel with no interpolation (nearest pixel)", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 49, "offset": 48 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 49, "offset": 48 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 49, "offset": 48 } } }, "tags": [ { "title": "prop", "description": "content to render", "lineNumber": 2, "type": { "type": "NameExpression", "name": "any" }, "name": "children" } ], "loc": { "start": { "line": 10, "column": 0 }, "end": { "line": 13, "column": 3 } }, "context": { "loc": { "start": { "line": 14, "column": 0 }, "end": { "line": 25, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/NearestCopy.js", "path": "packages/gl-react/src/NearestCopy.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/NearestCopy.js#L14-L25" }, "properties": [ { "name": "children", "lineNumber": 2, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "content to render", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 18, "offset": 17 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 18, "offset": 17 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 18, "offset": 17 } } }, "type": { "type": "NameExpression", "name": "any" } } ], "name": "NearestCopy", "augments": [ { "title": "augments", "name": "Component" } ], "kind": "class", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "NearestCopy", "kind": "class" } ], "namespace": "NearestCopy" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 3, "offset": 2 }, "indent": [] } }, { "type": "strong", "children": [ { "type": "text", "value": "Bus is a container to \"cache\" and re-use content", "position": { "start": { "line": 1, "column": 5, "offset": 4 }, "end": { "line": 1, "column": 53, "offset": 52 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 3, "offset": 2 }, "end": { "line": 1, "column": 55, "offset": 54 }, "indent": [] } }, { "type": "text", "value": " (tree of Node, canvas, video,...) somewhere else in your GL graph.\nTo use it, use the Bus ", "position": { "start": { "line": 1, "column": 55, "offset": 54 }, "end": { "line": 2, "column": 24, "offset": 145 }, "indent": [ 1 ] } }, { "type": "inlineCode", "value": "ref", "position": { "start": { "line": 2, "column": 24, "offset": 145 }, "end": { "line": 2, "column": 29, "offset": 150 }, "indent": [] } }, { "type": "text", "value": ":", "position": { "start": { "line": 2, "column": 29, "offset": 150 }, "end": { "line": 2, "column": 30, "offset": 151 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 30, "offset": 151 }, "indent": [ 1 ] } }, { "type": "list", "ordered": false, "start": null, "loose": false, "children": [ { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "provide it in another Node texture uniform so you can share computation (send a Node texture to multiple Nodes dependent) (more exactly, a working pattern is to give a ", "position": { "start": { "line": 3, "column": 3, "offset": 154 }, "end": { "line": 3, "column": 171, "offset": 322 }, "indent": [] } }, { "type": "inlineCode", "value": "()=>ref", "position": { "start": { "line": 3, "column": 171, "offset": 322 }, "end": { "line": 3, "column": 180, "offset": 331 }, "indent": [] } }, { "type": "text", "value": " function that will be resolved in ", "position": { "start": { "line": 3, "column": 180, "offset": 331 }, "end": { "line": 3, "column": 215, "offset": 366 }, "indent": [] } }, { "type": "inlineCode", "value": "DidUpdate", "position": { "start": { "line": 3, "column": 215, "offset": 366 }, "end": { "line": 3, "column": 226, "offset": 377 }, "indent": [] } }, { "type": "text", "value": " lifecycle)", "position": { "start": { "line": 3, "column": 226, "offset": 377 }, "end": { "line": 3, "column": 237, "offset": 388 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 3, "offset": 154 }, "end": { "line": 3, "column": 237, "offset": 388 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 152 }, "end": { "line": 3, "column": 237, "offset": 388 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "You have a ", "position": { "start": { "line": 4, "column": 3, "offset": 391 }, "end": { "line": 4, "column": 14, "offset": 402 }, "indent": [] } }, { "type": "inlineCode", "value": "capture()", "position": { "start": { "line": 4, "column": 14, "offset": 402 }, "end": { "line": 4, "column": 25, "offset": 413 }, "indent": [] } }, { "type": "text", "value": " method to snapshot the underlying Node (because Node can be hidden being nested React components).", "position": { "start": { "line": 4, "column": 25, "offset": 413 }, "end": { "line": 4, "column": 124, "offset": 512 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 3, "offset": 391 }, "end": { "line": 4, "column": 124, "offset": 512 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 1, "offset": 389 }, "end": { "line": 4, "column": 124, "offset": 512 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 152 }, "end": { "line": 4, "column": 124, "offset": 512 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 4, "column": 124, "offset": 512 } } }, "tags": [ { "title": "prop", "description": "the content to render. It can also be a function that takes a redraw function and render an element.", "lineNumber": 7, "type": { "type": "NameExpression", "name": "any" }, "name": "children" }, { "title": "prop", "description": "In case you want to explicitely draw Bus directly into a uniform, you can give the uniform name of the parent node.\nIf this prop is not used, the Bus does not directly belong to a Node and a ref can be used to indirectly give a texture to a node.\n`uniform` is equivalent to directly pass your VDOM inside the Node uniforms prop.\n\n**Usage Example**\n\n[![](https://github.com/gre/gl-react/raw/master/docs/examples/blur.gif)](/blurmapmouse)", "lineNumber": 8, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "string" } }, "name": "uniform" }, { "title": "example", "description": "\n \n //here, glEffects or content like a canvas/video...\n \n this.refs.myBus\n }} ... />\n", "lineNumber": 16 } ], "loc": { "start": { "line": 16, "column": 0 }, "end": { "line": 43, "column": 3 } }, "context": { "loc": { "start": { "line": 44, "column": 0 }, "end": { "line": 201, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Bus.js", "path": "packages/gl-react/src/Bus.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Bus.js#L44-L201" }, "properties": [ { "name": "children", "lineNumber": 7, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "the content to render. It can also be a function that takes a redraw function and render an element.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 101, "offset": 100 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 101, "offset": 100 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 101, "offset": 100 } } }, "type": { "type": "NameExpression", "name": "any" } }, { "name": "uniform", "lineNumber": 8, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "In case you want to explicitely draw Bus directly into a uniform, you can give the uniform name of the parent node.\nIf this prop is not used, the Bus does not directly belong to a Node and a ref can be used to indirectly give a texture to a node.\n", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 1, "offset": 247 }, "indent": [ 1, 1 ] } }, { "type": "inlineCode", "value": "uniform", "position": { "start": { "line": 3, "column": 1, "offset": 247 }, "end": { "line": 3, "column": 10, "offset": 256 }, "indent": [] } }, { "type": "text", "value": " is equivalent to directly pass your VDOM inside the Node uniforms prop.", "position": { "start": { "line": 3, "column": 10, "offset": 256 }, "end": { "line": 3, "column": 82, "offset": 328 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 82, "offset": 328 }, "indent": [ 1, 1 ] } }, { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "Usage Example", "position": { "start": { "line": 5, "column": 3, "offset": 332 }, "end": { "line": 5, "column": 16, "offset": 345 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 1, "offset": 330 }, "end": { "line": 5, "column": 18, "offset": 347 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 1, "offset": 330 }, "end": { "line": 5, "column": 18, "offset": 347 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "link", "title": null, "url": "/blurmapmouse", "children": [ { "type": "image", "title": null, "url": "https://github.com/gre/gl-react/raw/master/docs/examples/blur.gif", "alt": null, "position": { "start": { "line": 7, "column": 2, "offset": 350 }, "end": { "line": 7, "column": 72, "offset": 420 }, "indent": [] } } ], "position": { "start": { "line": 7, "column": 1, "offset": 349 }, "end": { "line": 7, "column": 88, "offset": 436 }, "indent": [] } } ], "position": { "start": { "line": 7, "column": 1, "offset": 349 }, "end": { "line": 7, "column": 88, "offset": 436 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 7, "column": 88, "offset": 436 } } }, "type": { "type": "OptionalType", "expression": { "type": "NameExpression", "name": "string" } } } ], "examples": [ { "description": "\n \n //here, glEffects or content like a canvas/video...\n \n this.refs.myBus\n }} ... />\n" } ], "name": "Bus", "augments": [ { "title": "augments", "name": "Component" } ], "kind": "class", "members": { "instance": [ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Capture the underlying Node pixels.\nNB it only works for nodes, not for content like video/canvas.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 63, "offset": 98 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 63, "offset": 98 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 63, "offset": 98 } } }, "tags": [], "loc": { "start": { "line": 150, "column": 2 }, "end": { "line": 153, "column": 5 } }, "context": { "loc": { "start": { "line": 154, "column": 2 }, "end": { "line": 157, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Bus.js", "path": "packages/gl-react/src/Bus.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Bus.js#L154-L157" }, "name": "capture", "kind": "function", "params": [ { "title": "param", "name": "x", "lineNumber": 154, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "y", "lineNumber": 154, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "w", "lineNumber": 154, "type": { "type": "NameExpression", "name": "number" } }, { "title": "param", "name": "h", "lineNumber": 154, "type": { "type": "NameExpression", "name": "number" } } ], "returns": [ { "type": { "type": "NameExpression", "name": "NDArray" } } ], "memberof": "Bus", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Bus", "kind": "class" }, { "name": "capture", "kind": "function", "scope": "instance" } ], "namespace": "Bus#capture" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Schedule a redraw of all nodes that depends on this Bus.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 57, "offset": 56 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 57, "offset": 56 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 57, "offset": 56 } } }, "tags": [ { "title": "function", "description": null, "lineNumber": 3, "name": null } ], "loc": { "start": { "line": 164, "column": 2 }, "end": { "line": 168, "column": 5 } }, "context": { "loc": { "start": { "line": 169, "column": 2 }, "end": { "line": 171, "column": 4 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Bus.js", "path": "packages/gl-react/src/Bus.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Bus.js#L169-L171" }, "kind": "function", "name": "redraw", "memberof": "Bus", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Bus", "kind": "class" }, { "name": "redraw", "kind": "function", "scope": "instance" } ], "namespace": "Bus#redraw" } ], "static": [], "events": [] }, "path": [ { "name": "Bus", "kind": "class" } ], "namespace": "Bus" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "A High Order Component (HOC) function that provides\nthe contextual ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 16, "offset": 67 }, "indent": [ 1 ] } }, { "type": "inlineCode", "value": "width", "position": { "start": { "line": 2, "column": 16, "offset": 67 }, "end": { "line": 2, "column": 23, "offset": 74 }, "indent": [] } }, { "type": "text", "value": " and ", "position": { "start": { "line": 2, "column": 23, "offset": 74 }, "end": { "line": 2, "column": 28, "offset": 79 }, "indent": [] } }, { "type": "inlineCode", "value": "height", "position": { "start": { "line": 2, "column": 28, "offset": 79 }, "end": { "line": 2, "column": 36, "offset": 87 }, "indent": [] } }, { "type": "text", "value": " props to a GL Component.\nIt also merge optional width,height props to override the contextual size", "position": { "start": { "line": 2, "column": 36, "offset": 87 }, "end": { "line": 3, "column": 74, "offset": 186 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 74, "offset": 186 }, "indent": [ 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 74, "offset": 186 } } }, "tags": [ { "title": "function", "description": null, "lineNumber": 4, "name": "connectSize" }, { "title": "param", "description": "a React Component that receives width and height props", "lineNumber": 5, "type": null, "name": "GLComponent" }, { "title": "returns", "description": "a Component that merge width and height props\nwith context and renders `GLComponent`.", "lineNumber": 6, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "ReactClass" }, "applications": [ { "type": "AllLiteral" } ] } }, { "title": "example", "description": "const Foo = ({ width, height }) => ;\n const FooConnected = connectSize(Foo);\n // you don't have to provide width, height.\n // If you do, you override width,height in the context as well, so is implicitly receiving the new width/height.", "lineNumber": 8 } ], "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 17, "column": 3 } }, "context": { "loc": { "start": { "line": 18, "column": 0 }, "end": { "line": 60, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/connectSize.js", "path": "packages/gl-react/src/connectSize.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/connectSize.js#L18-L60" }, "kind": "function", "name": "connectSize", "params": [ { "name": "GLComponent", "lineNumber": 5, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a React Component that receives width and height props", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 55, "offset": 54 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 55, "offset": 54 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 55, "offset": 54 } } }, "type": { "type": "UnionType", "elements": [ { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "ReactClass" }, "applications": [ null ] }, { "type": "FunctionType", "params": [ { "type": "ParameterType", "name": "props", "expression": { "type": "AllLiteral" } } ], "result": { "type": "TypeApplication", "expression": { "type": "NameExpression" }, "applications": [ null ] } } ] } } ], "returns": [ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "a Component that merge width and height props\nwith context and renders ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 26, "offset": 71 }, "indent": [ 1 ] } }, { "type": "inlineCode", "value": "GLComponent", "position": { "start": { "line": 2, "column": 26, "offset": 71 }, "end": { "line": 2, "column": 39, "offset": 84 }, "indent": [] } }, { "type": "text", "value": ".", "position": { "start": { "line": 2, "column": 39, "offset": 84 }, "end": { "line": 2, "column": 40, "offset": 85 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 40, "offset": 85 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 40, "offset": 85 } } }, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "ReactClass" }, "applications": [ { "type": "AllLiteral" } ] } } ], "examples": [ { "description": "const Foo = ({ width, height }) => ;\n const FooConnected = connectSize(Foo);\n // you don't have to provide width, height.\n // If you do, you override width,height in the context as well, so is implicitly receiving the new width/height." } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "connectSize", "kind": "function" } ], "namespace": "connectSize" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "GLSL string template to write your shader.\nThe library use a string template for esthetic reason (e.g. syntax color support) but also so we can more strongly type things.\nNote that later, we might do static analysis to generate at compile time the uniform types for instance.\nSee ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 4, "column": 5, "offset": 280 }, "indent": [ 1, 1, 1 ] } }, { "type": "link", "title": null, "url": "http://www.khronos.org/registry/gles/specs/2.0/GLSL_ES_Specification_1.0.17.pdf", "children": [ { "type": "text", "value": "GLSL spec", "position": { "start": { "line": 4, "column": 6, "offset": 281 }, "end": { "line": 4, "column": 15, "offset": 290 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 5, "offset": 280 }, "end": { "line": 4, "column": 97, "offset": 372 }, "indent": [] } }, { "type": "text", "value": ".", "position": { "start": { "line": 4, "column": 97, "offset": 372 }, "end": { "line": 4, "column": 98, "offset": 373 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 4, "column": 98, "offset": 373 }, "indent": [ 1, 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 4, "column": 98, "offset": 373 } } }, "tags": [ { "title": "return", "description": ", an object you can give to `Shaders.create`'s `frag`.", "lineNumber": 6, "type": { "type": "NameExpression", "name": "GLSLCode" } }, { "title": "example", "description": "GLSL`\nprecision highp float;\nvarying vec2 uv;\nvoid main() {\n gl_FragColor = vec4(uv.x, uv.y, 0.5, 1.0);\n}\n`", "lineNumber": 7 } ], "loc": { "start": { "line": 10, "column": 0 }, "end": { "line": 25, "column": 3 } }, "context": { "loc": { "start": { "line": 26, "column": 0 }, "end": { "line": 32, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/GLSL.js", "path": "packages/gl-react/src/GLSL.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/GLSL.js#L26-L32" }, "returns": [ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": ", an object you can give to ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 29, "offset": 28 }, "indent": [] } }, { "type": "inlineCode", "value": "Shaders.create", "position": { "start": { "line": 1, "column": 29, "offset": 28 }, "end": { "line": 1, "column": 45, "offset": 44 }, "indent": [] } }, { "type": "text", "value": "'s ", "position": { "start": { "line": 1, "column": 45, "offset": 44 }, "end": { "line": 1, "column": 48, "offset": 47 }, "indent": [] } }, { "type": "inlineCode", "value": "frag", "position": { "start": { "line": 1, "column": 48, "offset": 47 }, "end": { "line": 1, "column": 54, "offset": 53 }, "indent": [] } }, { "type": "text", "value": ".", "position": { "start": { "line": 1, "column": 54, "offset": 53 }, "end": { "line": 1, "column": 55, "offset": 54 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 55, "offset": 54 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 55, "offset": 54 } } }, "type": { "type": "NameExpression", "name": "GLSLCode" } } ], "examples": [ { "description": "GLSL`\nprecision highp float;\nvarying vec2 uv;\nvoid main() {\n gl_FragColor = vec4(uv.x, uv.y, 0.5, 1.0);\n}\n`" } ], "name": "GLSL", "kind": "class", "params": [ { "title": "param", "name": "strings", "lineNumber": 26, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "string" } ] } }, { "title": "param", "name": "values", "lineNumber": 26, "type": { "type": "RestType", "expression": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "string" } ] } } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "GLSL", "kind": "class" } ], "namespace": "GLSL" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "object created by ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 19, "offset": 18 }, "indent": [] } }, { "type": "strong", "children": [ { "type": "text", "value": "GLSL", "position": { "start": { "line": 1, "column": 21, "offset": 20 }, "end": { "line": 1, "column": 25, "offset": 24 }, "indent": [] } }, { "type": "inlineCode", "value": "", "position": { "start": { "line": 1, "column": 25, "offset": 24 }, "end": { "line": 1, "column": 27, "offset": 26 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 19, "offset": 18 }, "end": { "line": 1, "column": 29, "offset": 28 }, "indent": [] } }, { "type": "text", "value": " string template", "position": { "start": { "line": 1, "column": 29, "offset": 28 }, "end": { "line": 1, "column": 45, "offset": 44 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 45, "offset": 44 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 45, "offset": 44 } } }, "tags": [], "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 6, "column": 3 } }, "context": { "loc": { "start": { "line": 7, "column": 0 }, "end": { "line": 7, "column": 23 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/GLSL.js", "path": "packages/gl-react/src/GLSL.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/GLSL.js#L7-L7" }, "name": "GLSLCode", "kind": "typedef", "type": { "type": "NameExpression", "name": "string" }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "GLSLCode", "kind": "typedef" } ], "namespace": "GLSLCode" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "An object map from a key string to a ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 38, "offset": 37 }, "indent": [] } }, { "type": "strong", "children": [ { "type": "text", "value": "ShaderDefinition", "position": { "start": { "line": 1, "column": 40, "offset": 39 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 38, "offset": 37 }, "end": { "line": 1, "column": 58, "offset": 57 }, "indent": [] } }, { "type": "text", "value": ".", "position": { "start": { "line": 1, "column": 58, "offset": 57 }, "end": { "line": 1, "column": 59, "offset": 58 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 59, "offset": 58 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 59, "offset": 58 } } }, "tags": [ { "title": "example", "description": "{\n helloGL: {\n frag: GLSL`...`\n }\n }", "lineNumber": 2 } ], "loc": { "start": { "line": 35, "column": 0 }, "end": { "line": 43, "column": 3 } }, "context": { "loc": { "start": { "line": 44, "column": 0 }, "end": { "line": 46, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Shaders.js", "path": "packages/gl-react/src/Shaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Shaders.js#L44-L46" }, "examples": [ { "description": "{\n helloGL: {\n frag: GLSL`...`\n }\n }" } ], "name": "ShadersDefinition", "kind": "typedef", "type": { "type": "RecordType", "fields": [] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "ShadersDefinition", "kind": "typedef" } ], "namespace": "ShadersDefinition" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "An object that contains a ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 27, "offset": 26 }, "indent": [] } }, { "type": "inlineCode", "value": "frag", "position": { "start": { "line": 1, "column": 27, "offset": 26 }, "end": { "line": 1, "column": 33, "offset": 32 }, "indent": [] } }, { "type": "text", "value": " GLSLCode.", "position": { "start": { "line": 1, "column": 33, "offset": 32 }, "end": { "line": 1, "column": 43, "offset": 42 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 43, "offset": 42 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 43, "offset": 42 } } }, "tags": [ { "title": "example", "description": "{\n frag: GLSL`...`\n }", "lineNumber": 2 } ], "loc": { "start": { "line": 8, "column": 0 }, "end": { "line": 14, "column": 3 } }, "context": { "loc": { "start": { "line": 15, "column": 0 }, "end": { "line": 17, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Shaders.js", "path": "packages/gl-react/src/Shaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Shaders.js#L15-L17" }, "examples": [ { "description": "{\n frag: GLSL`...`\n }" } ], "name": "ShaderDefinition", "kind": "typedef", "properties": [ { "title": "property", "name": "frag", "lineNumber": 16, "type": { "type": "NameExpression", "name": "GLSLCode" } } ], "type": { "type": "RecordType", "fields": [ { "type": "FieldType", "key": "frag", "value": { "type": "NameExpression", "name": "GLSLCode" } } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "ShaderDefinition", "kind": "typedef" } ], "namespace": "ShaderDefinition" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "An object map from a key string to a ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 38, "offset": 37 }, "indent": [] } }, { "type": "strong", "children": [ { "type": "text", "value": "ShaderIdentifier", "position": { "start": { "line": 1, "column": 40, "offset": 39 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 38, "offset": 37 }, "end": { "line": 1, "column": 58, "offset": 57 }, "indent": [] } }, { "type": "text", "value": " that you can pass to ", "position": { "start": { "line": 1, "column": 58, "offset": 57 }, "end": { "line": 1, "column": 80, "offset": 79 }, "indent": [] } }, { "type": "inlineCode", "value": "", "position": { "start": { "line": 1, "column": 80, "offset": 79 }, "end": { "line": 1, "column": 95, "offset": 94 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 95, "offset": 94 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 95, "offset": 94 } } }, "tags": [], "loc": { "start": { "line": 48, "column": 0 }, "end": { "line": 50, "column": 3 } }, "context": { "loc": { "start": { "line": 51, "column": 0 }, "end": { "line": 53, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Shaders.js", "path": "packages/gl-react/src/Shaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Shaders.js#L51-L53" }, "name": "ShadersSheet", "kind": "typedef", "type": { "type": "RecordType", "fields": [] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "ShadersSheet", "kind": "typedef" } ], "namespace": "ShadersSheet" }, { "description": "", "tags": [], "loc": { "start": { "line": 21, "column": 0 }, "end": { "line": 23, "column": 3 } }, "context": { "loc": { "start": { "line": 24, "column": 0 }, "end": { "line": 27, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Shaders.js", "path": "packages/gl-react/src/Shaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Shaders.js#L24-L27" }, "name": "ShaderIdentifier", "kind": "typedef", "properties": [ { "title": "property", "name": "type", "lineNumber": 25 }, { "title": "property", "name": "id", "lineNumber": 26, "type": { "type": "NameExpression", "name": "string" } } ], "type": { "type": "RecordType", "fields": [ { "type": "FieldType", "key": "type" }, { "type": "FieldType", "key": "id", "value": { "type": "NameExpression", "name": "string" } } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "ShaderIdentifier", "kind": "typedef" } ], "namespace": "ShaderIdentifier" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Uniforms is an map object from uniform name to a value.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 56, "offset": 55 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "The library support numerous uniform types via different formats.\nLet's describe them:", "position": { "start": { "line": 3, "column": 3, "offset": 59 }, "end": { "line": 4, "column": 21, "offset": 145 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 57 }, "end": { "line": 4, "column": 23, "offset": 147 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 57 }, "end": { "line": 4, "column": 23, "offset": 147 }, "indent": [ 1 ] } }, { "type": "heading", "depth": 3, "children": [ { "type": "text", "value": "int or float", "position": { "start": { "line": 6, "column": 5, "offset": 153 }, "end": { "line": 6, "column": 17, "offset": 165 }, "indent": [] } } ], "position": { "start": { "line": 6, "column": 1, "offset": 149 }, "end": { "line": 6, "column": 17, "offset": 165 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "a JavaScript number", "position": { "start": { "line": 8, "column": 1, "offset": 167 }, "end": { "line": 8, "column": 20, "offset": 186 }, "indent": [] } } ], "position": { "start": { "line": 8, "column": 1, "offset": 167 }, "end": { "line": 8, "column": 20, "offset": 186 }, "indent": [] } }, { "type": "heading", "depth": 3, "children": [ { "type": "text", "value": "bool", "position": { "start": { "line": 10, "column": 5, "offset": 192 }, "end": { "line": 10, "column": 9, "offset": 196 }, "indent": [] } } ], "position": { "start": { "line": 10, "column": 1, "offset": 188 }, "end": { "line": 10, "column": 9, "offset": 196 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "a JavaScript Boolean", "position": { "start": { "line": 12, "column": 1, "offset": 198 }, "end": { "line": 12, "column": 21, "offset": 218 }, "indent": [] } } ], "position": { "start": { "line": 12, "column": 1, "offset": 198 }, "end": { "line": 12, "column": 21, "offset": 218 }, "indent": [] } }, { "type": "heading", "depth": 3, "children": [ { "type": "text", "value": "int[], float[], bool[] arrays", "position": { "start": { "line": 14, "column": 5, "offset": 224 }, "end": { "line": 14, "column": 34, "offset": 253 }, "indent": [] } } ], "position": { "start": { "line": 14, "column": 1, "offset": 220 }, "end": { "line": 14, "column": 34, "offset": 253 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "an array of the number (0/1 for bool can be used as well as bools)", "position": { "start": { "line": 16, "column": 1, "offset": 255 }, "end": { "line": 16, "column": 67, "offset": 321 }, "indent": [] } } ], "position": { "start": { "line": 16, "column": 1, "offset": 255 }, "end": { "line": 16, "column": 67, "offset": 321 }, "indent": [] } }, { "type": "heading", "depth": 3, "children": [ { "type": "text", "value": "vec2, vec3, vec4", "position": { "start": { "line": 18, "column": 5, "offset": 327 }, "end": { "line": 18, "column": 21, "offset": 343 }, "indent": [] } } ], "position": { "start": { "line": 18, "column": 1, "offset": 323 }, "end": { "line": 18, "column": 21, "offset": 343 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "an array of number, of size respectively 2, 3 and 4.", "position": { "start": { "line": 20, "column": 1, "offset": 345 }, "end": { "line": 20, "column": 53, "offset": 397 }, "indent": [] } } ], "position": { "start": { "line": 20, "column": 1, "offset": 345 }, "end": { "line": 20, "column": 53, "offset": 397 }, "indent": [] } }, { "type": "blockquote", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "same is available for ivec* variants.", "position": { "start": { "line": 22, "column": 3, "offset": 401 }, "end": { "line": 22, "column": 40, "offset": 438 }, "indent": [] } } ], "position": { "start": { "line": 22, "column": 3, "offset": 401 }, "end": { "line": 22, "column": 40, "offset": 438 }, "indent": [] } } ], "position": { "start": { "line": 22, "column": 1, "offset": 399 }, "end": { "line": 22, "column": 40, "offset": 438 }, "indent": [] } }, { "type": "heading", "depth": 3, "children": [ { "type": "text", "value": "mat2, mat3, mat4", "position": { "start": { "line": 24, "column": 5, "offset": 444 }, "end": { "line": 24, "column": 21, "offset": 460 }, "indent": [] } } ], "position": { "start": { "line": 24, "column": 1, "offset": 440 }, "end": { "line": 24, "column": 21, "offset": 460 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "Similarly to vectorial types, you can pass an array of numbers.\nFor matrix, you actually define them in a flatten way (not arrays of arrays).", "position": { "start": { "line": 26, "column": 1, "offset": 462 }, "end": { "line": 27, "column": 78, "offset": 603 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 26, "column": 1, "offset": 462 }, "end": { "line": 27, "column": 78, "offset": 603 }, "indent": [ 1 ] } }, { "type": "heading", "depth": 3, "children": [ { "type": "text", "value": "sampler2D type (aka texture)", "position": { "start": { "line": 29, "column": 5, "offset": 609 }, "end": { "line": 29, "column": 33, "offset": 637 }, "indent": [] } } ], "position": { "start": { "line": 29, "column": 1, "offset": 605 }, "end": { "line": 29, "column": 33, "offset": 637 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "The library support numerous and extensible uniform value format.", "position": { "start": { "line": 31, "column": 1, "offset": 639 }, "end": { "line": 31, "column": 66, "offset": 704 }, "indent": [] } } ], "position": { "start": { "line": 31, "column": 1, "offset": 639 }, "end": { "line": 31, "column": 66, "offset": 704 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "strong", "children": [ { "type": "text", "value": "FIXME: to be documented.", "position": { "start": { "line": 33, "column": 3, "offset": 708 }, "end": { "line": 33, "column": 27, "offset": 732 }, "indent": [] } } ], "position": { "start": { "line": 33, "column": 1, "offset": 706 }, "end": { "line": 33, "column": 29, "offset": 734 }, "indent": [] } } ], "position": { "start": { "line": 33, "column": 1, "offset": 706 }, "end": { "line": 33, "column": 29, "offset": 734 }, "indent": [] } }, { "type": "heading", "depth": 3, "children": [ { "type": "text", "value": "struct types", "position": { "start": { "line": 35, "column": 5, "offset": 740 }, "end": { "line": 35, "column": 17, "offset": 752 }, "indent": [] } } ], "position": { "start": { "line": 35, "column": 1, "offset": 736 }, "end": { "line": 35, "column": 17, "offset": 752 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "Consider it unsupported even though it ", "position": { "start": { "line": 37, "column": 1, "offset": 754 }, "end": { "line": 37, "column": 40, "offset": 793 }, "indent": [] } }, { "type": "emphasis", "children": [ { "type": "text", "value": "might", "position": { "start": { "line": 37, "column": 41, "offset": 794 }, "end": { "line": 37, "column": 46, "offset": 799 }, "indent": [] } } ], "position": { "start": { "line": 37, "column": 40, "offset": 793 }, "end": { "line": 37, "column": 47, "offset": 800 }, "indent": [] } }, { "type": "text", "value": " work since gl-react is based on ", "position": { "start": { "line": 37, "column": 47, "offset": 800 }, "end": { "line": 37, "column": 80, "offset": 833 }, "indent": [] } }, { "type": "inlineCode", "value": "gl-texture2d", "position": { "start": { "line": 37, "column": 80, "offset": 833 }, "end": { "line": 37, "column": 94, "offset": 847 }, "indent": [] } }, { "type": "text", "value": ".", "position": { "start": { "line": 37, "column": 94, "offset": 847 }, "end": { "line": 37, "column": 95, "offset": 848 }, "indent": [] } } ], "position": { "start": { "line": 37, "column": 1, "offset": 754 }, "end": { "line": 37, "column": 95, "offset": 848 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 37, "column": 95, "offset": 848 } } }, "tags": [], "loc": { "start": { "line": 119, "column": 0 }, "end": { "line": 158, "column": 3 } }, "context": { "loc": { "start": { "line": 159, "column": 0 }, "end": { "line": 161, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L159-L161" }, "name": "Uniforms", "kind": "typedef", "type": { "type": "RecordType", "fields": [] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Uniforms", "kind": "typedef" } ], "namespace": "Uniforms" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Options on a texture.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 22, "offset": 21 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 22, "offset": 21 }, "indent": [] } }, { "type": "list", "ordered": false, "start": null, "loose": false, "children": [ { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "interpolation define how the pixel lookup get mapped to screen.", "position": { "start": { "line": 2, "column": 3, "offset": 24 }, "end": { "line": 2, "column": 66, "offset": 87 }, "indent": [] } } ], "position": { "start": { "line": 2, "column": 3, "offset": 24 }, "end": { "line": 2, "column": 66, "offset": 87 }, "indent": [] } } ], "position": { "start": { "line": 2, "column": 1, "offset": 22 }, "end": { "line": 2, "column": 66, "offset": 87 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "wrap define how the edge lookup behaves. It can be either a ", "position": { "start": { "line": 3, "column": 3, "offset": 90 }, "end": { "line": 3, "column": 63, "offset": 150 }, "indent": [] } }, { "type": "linkReference", "identifier": "x,y", "referenceType": "shortcut", "children": [ { "type": "text", "value": "x,y", "position": { "start": { "line": 3, "column": 64, "offset": 151 }, "end": { "line": 3, "column": 67, "offset": 154 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 63, "offset": 150 }, "end": { "line": 3, "column": 68, "offset": 155 }, "indent": [] } }, { "type": "text", "value": " wrap or a wrap value for both.", "position": { "start": { "line": 3, "column": 68, "offset": 155 }, "end": { "line": 3, "column": 99, "offset": 186 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 3, "offset": 90 }, "end": { "line": 3, "column": 99, "offset": 186 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 88 }, "end": { "line": 3, "column": 99, "offset": 186 }, "indent": [] } } ], "position": { "start": { "line": 2, "column": 1, "offset": 22 }, "end": { "line": 3, "column": 99, "offset": 186 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 99, "offset": 186 } } }, "tags": [], "loc": { "start": { "line": 61, "column": 0 }, "end": { "line": 65, "column": 3 } }, "context": { "loc": { "start": { "line": 66, "column": 0 }, "end": { "line": 69, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L66-L69" }, "name": "TextureOptions", "kind": "typedef", "properties": [ { "title": "property", "name": "interpolation", "lineNumber": 67, "type": { "type": "NameExpression", "name": "Interpolation" } }, { "title": "property", "name": "wrap", "lineNumber": 68, "type": { "type": "UnionType", "elements": [ { "type": "ArrayType", "elements": [ { "type": "NameExpression", "name": "WrapMode" }, { "type": "NameExpression", "name": "WrapMode" } ] }, { "type": "NameExpression", "name": "WrapMode" } ] } } ], "type": { "type": "RecordType", "fields": [ { "type": "FieldType", "key": "interpolation", "value": { "type": "NameExpression", "name": "Interpolation" } }, { "type": "FieldType", "key": "wrap", "value": { "type": "UnionType", "elements": [ { "type": "ArrayType", "elements": [ { "type": "NameExpression", "name": "WrapMode" }, { "type": "NameExpression", "name": "WrapMode" } ] }, { "type": "NameExpression", "name": "WrapMode" } ] } } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureOptions", "kind": "typedef" } ], "namespace": "TextureOptions" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "The texture pixel interpolation mode.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 38, "offset": 37 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 38, "offset": 37 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "One of:", "position": { "start": { "line": 3, "column": 1, "offset": 39 }, "end": { "line": 3, "column": 8, "offset": 46 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 39 }, "end": { "line": 3, "column": 8, "offset": 46 }, "indent": [] } }, { "type": "list", "ordered": false, "start": null, "loose": false, "children": [ { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "linear", "position": { "start": { "line": 4, "column": 3, "offset": 49 }, "end": { "line": 4, "column": 11, "offset": 57 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 3, "offset": 49 }, "end": { "line": 4, "column": 11, "offset": 57 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 1, "offset": 47 }, "end": { "line": 4, "column": 11, "offset": 57 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "nearest", "position": { "start": { "line": 5, "column": 3, "offset": 60 }, "end": { "line": 5, "column": 12, "offset": 69 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 3, "offset": 60 }, "end": { "line": 5, "column": 12, "offset": 69 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 1, "offset": 58 }, "end": { "line": 5, "column": 12, "offset": 69 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 1, "offset": 47 }, "end": { "line": 5, "column": 12, "offset": 69 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 5, "column": 12, "offset": 69 } } }, "tags": [], "loc": { "start": { "line": 39, "column": 0 }, "end": { "line": 45, "column": 3 } }, "context": { "loc": { "start": { "line": 46, "column": 0 }, "end": { "line": 46, "column": 42 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L46-L46" }, "name": "Interpolation", "kind": "typedef", "type": { "type": "UnionType", "elements": [ { "type": "StringLiteralType", "value": "linear" }, { "type": "StringLiteralType", "value": "nearest" } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Interpolation", "kind": "typedef" } ], "namespace": "Interpolation" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "A texture wrap mode define how the texture lookup repeat over edges.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 69, "offset": 68 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 69, "offset": 68 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "One of:", "position": { "start": { "line": 3, "column": 1, "offset": 70 }, "end": { "line": 3, "column": 8, "offset": 77 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 70 }, "end": { "line": 3, "column": 8, "offset": 77 }, "indent": [] } }, { "type": "list", "ordered": false, "start": null, "loose": false, "children": [ { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "clamp to edge", "position": { "start": { "line": 4, "column": 3, "offset": 80 }, "end": { "line": 4, "column": 18, "offset": 95 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 3, "offset": 80 }, "end": { "line": 4, "column": 18, "offset": 95 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 1, "offset": 78 }, "end": { "line": 4, "column": 18, "offset": 95 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "repeat", "position": { "start": { "line": 5, "column": 3, "offset": 98 }, "end": { "line": 5, "column": 11, "offset": 106 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 3, "offset": 98 }, "end": { "line": 5, "column": 11, "offset": 106 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 1, "offset": 96 }, "end": { "line": 5, "column": 11, "offset": 106 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "mirrored repeat", "position": { "start": { "line": 6, "column": 3, "offset": 109 }, "end": { "line": 6, "column": 20, "offset": 126 }, "indent": [] } } ], "position": { "start": { "line": 6, "column": 3, "offset": 109 }, "end": { "line": 6, "column": 20, "offset": 126 }, "indent": [] } } ], "position": { "start": { "line": 6, "column": 1, "offset": 107 }, "end": { "line": 6, "column": 20, "offset": 126 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 1, "offset": 78 }, "end": { "line": 6, "column": 20, "offset": 126 }, "indent": [ 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 6, "column": 20, "offset": 126 } } }, "tags": [], "loc": { "start": { "line": 48, "column": 0 }, "end": { "line": 55, "column": 3 } }, "context": { "loc": { "start": { "line": 56, "column": 0 }, "end": { "line": 59, "column": 20 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L56-L59" }, "name": "WrapMode", "kind": "typedef", "type": { "type": "UnionType", "elements": [ { "type": "StringLiteralType", "value": "clamp to edge" }, { "type": "StringLiteralType", "value": "repeat" }, { "type": "StringLiteralType", "value": "mirrored repeat" } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "WrapMode", "kind": "typedef" } ], "namespace": "WrapMode" }, { "description": "", "tags": [], "loc": { "start": { "line": 93, "column": 0 }, "end": { "line": 95, "column": 3 } }, "context": { "loc": { "start": { "line": 96, "column": 0 }, "end": { "line": 99, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L96-L99" }, "name": "BlendFuncSrcDst", "kind": "typedef", "properties": [ { "title": "property", "name": "src", "lineNumber": 97, "type": { "type": "NameExpression", "name": "BlendFunc" } }, { "title": "property", "name": "dst", "lineNumber": 98, "type": { "type": "NameExpression", "name": "BlendFunc" } } ], "type": { "type": "RecordType", "fields": [ { "type": "FieldType", "key": "src", "value": { "type": "NameExpression", "name": "BlendFunc" } }, { "type": "FieldType", "key": "dst", "value": { "type": "NameExpression", "name": "BlendFunc" } } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "BlendFuncSrcDst", "kind": "typedef" } ], "namespace": "BlendFuncSrcDst" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "The GL blending function.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 26, "offset": 25 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 26, "offset": 25 }, "indent": [] } }, { "type": "paragraph", "children": [ { "type": "text", "value": "One of:", "position": { "start": { "line": 3, "column": 1, "offset": 27 }, "end": { "line": 3, "column": 8, "offset": 34 }, "indent": [] } } ], "position": { "start": { "line": 3, "column": 1, "offset": 27 }, "end": { "line": 3, "column": 8, "offset": 34 }, "indent": [] } }, { "type": "list", "ordered": false, "start": null, "loose": false, "children": [ { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "zero", "position": { "start": { "line": 4, "column": 3, "offset": 37 }, "end": { "line": 4, "column": 9, "offset": 43 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 3, "offset": 37 }, "end": { "line": 4, "column": 9, "offset": 43 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 1, "offset": 35 }, "end": { "line": 4, "column": 9, "offset": 43 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "one", "position": { "start": { "line": 5, "column": 3, "offset": 46 }, "end": { "line": 5, "column": 8, "offset": 51 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 3, "offset": 46 }, "end": { "line": 5, "column": 8, "offset": 51 }, "indent": [] } } ], "position": { "start": { "line": 5, "column": 1, "offset": 44 }, "end": { "line": 5, "column": 8, "offset": 51 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "src color", "position": { "start": { "line": 6, "column": 3, "offset": 54 }, "end": { "line": 6, "column": 14, "offset": 65 }, "indent": [] } } ], "position": { "start": { "line": 6, "column": 3, "offset": 54 }, "end": { "line": 6, "column": 14, "offset": 65 }, "indent": [] } } ], "position": { "start": { "line": 6, "column": 1, "offset": 52 }, "end": { "line": 6, "column": 14, "offset": 65 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "one minus src color", "position": { "start": { "line": 7, "column": 3, "offset": 68 }, "end": { "line": 7, "column": 24, "offset": 89 }, "indent": [] } } ], "position": { "start": { "line": 7, "column": 3, "offset": 68 }, "end": { "line": 7, "column": 24, "offset": 89 }, "indent": [] } } ], "position": { "start": { "line": 7, "column": 1, "offset": 66 }, "end": { "line": 7, "column": 24, "offset": 89 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "src alpha", "position": { "start": { "line": 8, "column": 3, "offset": 92 }, "end": { "line": 8, "column": 14, "offset": 103 }, "indent": [] } } ], "position": { "start": { "line": 8, "column": 3, "offset": 92 }, "end": { "line": 8, "column": 14, "offset": 103 }, "indent": [] } } ], "position": { "start": { "line": 8, "column": 1, "offset": 90 }, "end": { "line": 8, "column": 14, "offset": 103 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "one minus src alpha", "position": { "start": { "line": 9, "column": 3, "offset": 106 }, "end": { "line": 9, "column": 24, "offset": 127 }, "indent": [] } } ], "position": { "start": { "line": 9, "column": 3, "offset": 106 }, "end": { "line": 9, "column": 24, "offset": 127 }, "indent": [] } } ], "position": { "start": { "line": 9, "column": 1, "offset": 104 }, "end": { "line": 9, "column": 24, "offset": 127 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "dst color", "position": { "start": { "line": 10, "column": 3, "offset": 130 }, "end": { "line": 10, "column": 14, "offset": 141 }, "indent": [] } } ], "position": { "start": { "line": 10, "column": 3, "offset": 130 }, "end": { "line": 10, "column": 14, "offset": 141 }, "indent": [] } } ], "position": { "start": { "line": 10, "column": 1, "offset": 128 }, "end": { "line": 10, "column": 14, "offset": 141 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "one minus dst color", "position": { "start": { "line": 11, "column": 3, "offset": 144 }, "end": { "line": 11, "column": 24, "offset": 165 }, "indent": [] } } ], "position": { "start": { "line": 11, "column": 3, "offset": 144 }, "end": { "line": 11, "column": 24, "offset": 165 }, "indent": [] } } ], "position": { "start": { "line": 11, "column": 1, "offset": 142 }, "end": { "line": 11, "column": 24, "offset": 165 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "dst alpha", "position": { "start": { "line": 12, "column": 3, "offset": 168 }, "end": { "line": 12, "column": 14, "offset": 179 }, "indent": [] } } ], "position": { "start": { "line": 12, "column": 3, "offset": 168 }, "end": { "line": 12, "column": 14, "offset": 179 }, "indent": [] } } ], "position": { "start": { "line": 12, "column": 1, "offset": 166 }, "end": { "line": 12, "column": 14, "offset": 179 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "one minus dst alpha", "position": { "start": { "line": 13, "column": 3, "offset": 182 }, "end": { "line": 13, "column": 24, "offset": 203 }, "indent": [] } } ], "position": { "start": { "line": 13, "column": 3, "offset": 182 }, "end": { "line": 13, "column": 24, "offset": 203 }, "indent": [] } } ], "position": { "start": { "line": 13, "column": 1, "offset": 180 }, "end": { "line": 13, "column": 24, "offset": 203 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "constant color", "position": { "start": { "line": 14, "column": 3, "offset": 206 }, "end": { "line": 14, "column": 19, "offset": 222 }, "indent": [] } } ], "position": { "start": { "line": 14, "column": 3, "offset": 206 }, "end": { "line": 14, "column": 19, "offset": 222 }, "indent": [] } } ], "position": { "start": { "line": 14, "column": 1, "offset": 204 }, "end": { "line": 14, "column": 19, "offset": 222 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "one minus constant color", "position": { "start": { "line": 15, "column": 3, "offset": 225 }, "end": { "line": 15, "column": 29, "offset": 251 }, "indent": [] } } ], "position": { "start": { "line": 15, "column": 3, "offset": 225 }, "end": { "line": 15, "column": 29, "offset": 251 }, "indent": [] } } ], "position": { "start": { "line": 15, "column": 1, "offset": 223 }, "end": { "line": 15, "column": 29, "offset": 251 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "constant alpha", "position": { "start": { "line": 16, "column": 3, "offset": 254 }, "end": { "line": 16, "column": 19, "offset": 270 }, "indent": [] } } ], "position": { "start": { "line": 16, "column": 3, "offset": 254 }, "end": { "line": 16, "column": 19, "offset": 270 }, "indent": [] } } ], "position": { "start": { "line": 16, "column": 1, "offset": 252 }, "end": { "line": 16, "column": 19, "offset": 270 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "one minus constant alpha", "position": { "start": { "line": 17, "column": 3, "offset": 273 }, "end": { "line": 17, "column": 29, "offset": 299 }, "indent": [] } } ], "position": { "start": { "line": 17, "column": 3, "offset": 273 }, "end": { "line": 17, "column": 29, "offset": 299 }, "indent": [] } } ], "position": { "start": { "line": 17, "column": 1, "offset": 271 }, "end": { "line": 17, "column": 29, "offset": 299 }, "indent": [] } }, { "type": "listItem", "loose": false, "checked": null, "children": [ { "type": "paragraph", "children": [ { "type": "inlineCode", "value": "src alpha saturate", "position": { "start": { "line": 18, "column": 3, "offset": 302 }, "end": { "line": 18, "column": 23, "offset": 322 }, "indent": [] } } ], "position": { "start": { "line": 18, "column": 3, "offset": 302 }, "end": { "line": 18, "column": 23, "offset": 322 }, "indent": [] } } ], "position": { "start": { "line": 18, "column": 1, "offset": 300 }, "end": { "line": 18, "column": 23, "offset": 322 }, "indent": [] } } ], "position": { "start": { "line": 4, "column": 1, "offset": 35 }, "end": { "line": 18, "column": 23, "offset": 322 }, "indent": [ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 18, "column": 23, "offset": 322 } } }, "tags": [], "loc": { "start": { "line": 71, "column": 0 }, "end": { "line": 90, "column": 3 } }, "context": { "loc": { "start": { "line": 91, "column": 0 }, "end": { "line": 91, "column": 48 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L91-L91" }, "name": "BlendFunc", "kind": "typedef", "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "$Keys" }, "applications": [ null ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "BlendFunc", "kind": "typedef" } ], "namespace": "BlendFunc" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "The GL clear mode.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 19, "offset": 18 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 19, "offset": 18 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 19, "offset": 18 } } }, "tags": [], "loc": { "start": { "line": 111, "column": 0 }, "end": { "line": 113, "column": 3 } }, "context": { "loc": { "start": { "line": 114, "column": 0 }, "end": { "line": 116, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L114-L116" }, "name": "Clear", "kind": "typedef", "properties": [ { "title": "property", "name": "color", "lineNumber": 115, "type": { "type": "NameExpression", "name": "Vec4" } } ], "type": { "type": "RecordType", "fields": [ { "type": "FieldType", "key": "color", "value": { "type": "NameExpression", "name": "Vec4" } } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Clear", "kind": "typedef" } ], "namespace": "Clear" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Array of 4 numbers. Useful to represent colors. ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 49, "offset": 48 }, "indent": [] } }, { "type": "emphasis", "children": [ { "type": "linkReference", "identifier": " r, g, b, a ", "referenceType": "shortcut", "children": [ { "type": "text", "value": " r, g, b, a ", "position": { "start": { "line": 1, "column": 51, "offset": 50 }, "end": { "line": 1, "column": 63, "offset": 62 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 50, "offset": 49 }, "end": { "line": 1, "column": 64, "offset": 63 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 49, "offset": 48 }, "end": { "line": 1, "column": 65, "offset": 64 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 65, "offset": 64 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 65, "offset": 64 } } }, "tags": [], "loc": { "start": { "line": 101, "column": 0 }, "end": { "line": 103, "column": 3 } }, "context": { "loc": { "start": { "line": 104, "column": 0 }, "end": { "line": 109, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Node.js", "path": "packages/gl-react/src/Node.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Node.js#L104-L109" }, "name": "Vec4", "kind": "typedef", "type": { "type": "ArrayType", "elements": [ { "type": "NameExpression", "name": "number" }, { "type": "NameExpression", "name": "number" }, { "type": "NameExpression", "name": "number" }, { "type": "NameExpression", "name": "number" } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Vec4", "kind": "typedef" } ], "namespace": "Vec4" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Multidimensional Arrays object from library\n", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 1, "offset": 44 }, "indent": [ 1 ] } }, { "type": "link", "title": null, "url": "https://www.npmjs.com/package/ndarray", "children": [ { "type": "text", "value": "ndarray", "position": { "start": { "line": 2, "column": 2, "offset": 45 }, "end": { "line": 2, "column": 9, "offset": 52 }, "indent": [] } } ], "position": { "start": { "line": 2, "column": 1, "offset": 44 }, "end": { "line": 2, "column": 49, "offset": 92 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 49, "offset": 92 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 49, "offset": 92 } } }, "tags": [], "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 6, "column": 3 } }, "context": { "loc": { "start": { "line": 7, "column": 0 }, "end": { "line": 13, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/flow/ndarray.js", "path": "packages/gl-react/flow/ndarray.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/flow/ndarray.js#L7-L13" }, "name": "NDArray", "kind": "typedef", "properties": [ { "title": "property", "name": "shape", "lineNumber": 8, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "number" } ] } }, { "title": "property", "name": "data", "lineNumber": 9, "type": { "type": "UnionType", "elements": [ { "type": "NameExpression", "name": "$TypedArray" }, { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "number" } ] } ] } }, { "title": "property", "name": "stride", "lineNumber": 10, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "number" } ] } }, { "title": "property", "name": "transpose", "lineNumber": 11, "type": { "type": "FunctionType", "params": [], "result": { "type": "NameExpression", "name": "NDArray" } } }, { "title": "property", "name": "step", "lineNumber": 12, "type": { "type": "FunctionType", "params": [], "result": { "type": "NameExpression", "name": "NDArray" } } } ], "type": { "type": "RecordType", "fields": [ { "type": "FieldType", "key": "shape", "value": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "number" } ] } }, { "type": "FieldType", "key": "data", "value": { "type": "UnionType", "elements": [ { "type": "NameExpression", "name": "$TypedArray" }, { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "number" } ] } ] } }, { "type": "FieldType", "key": "stride", "value": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "NameExpression", "name": "number" } ] } }, { "type": "FieldType", "key": "transpose", "value": { "type": "FunctionType", "params": [], "result": { "type": "NameExpression", "name": "NDArray" } } }, { "type": "FieldType", "key": "step", "value": { "type": "FunctionType", "params": [], "result": { "type": "NameExpression", "name": "NDArray" } } } ] }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "NDArray", "kind": "typedef" } ], "namespace": "NDArray" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "A texture loader is an extensible way to add more \"renderable texture\" into gl-react.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 86, "offset": 85 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 86, "offset": 85 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 86, "offset": 85 } } }, "tags": [], "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 8, "column": 3 } }, "context": { "loc": { "start": { "line": 9, "column": 0 }, "end": { "line": 50, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoader.js", "path": "packages/gl-react/src/TextureLoader.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoader.js#L9-L50" }, "name": "TextureLoader", "kind": "class", "members": { "instance": [ { "description": "", "tags": [ { "title": "property", "description": "the contextual rendering context", "lineNumber": 1, "type": { "type": "NameExpression", "name": "WebGLRenderingContext" }, "name": "gl" } ], "loc": { "start": { "line": 11, "column": 2 }, "end": { "line": 13, "column": 5 } }, "context": { "loc": { "start": { "line": 14, "column": 2 }, "end": { "line": 14, "column": 28 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoader.js", "path": "packages/gl-react/src/TextureLoader.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoader.js#L14-L14" }, "properties": [ { "name": "gl", "lineNumber": 1, "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "the contextual rendering context", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 33, "offset": 32 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 33, "offset": 32 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 33, "offset": 32 } } }, "type": { "type": "NameExpression", "name": "WebGLRenderingContext" } } ], "name": "gl", "kind": "member", "memberof": "TextureLoader", "scope": "instance", "type": { "type": "NameExpression", "name": "WebGLRenderingContext" }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoader", "kind": "class" }, { "name": "gl", "kind": "member", "scope": "instance" } ], "namespace": "TextureLoader#gl" }, { "description": "", "tags": [], "loc": { "start": { "line": 16, "column": 2 }, "end": { "line": 18, "column": 5 } }, "context": { "loc": { "start": { "line": 19, "column": 2 }, "end": { "line": 21, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoader.js", "path": "packages/gl-react/src/TextureLoader.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoader.js#L19-L21" }, "name": "constructor", "kind": "function", "params": [ { "title": "param", "name": "gl", "lineNumber": 19, "type": { "type": "NameExpression", "name": "WebGLRenderingContext" } } ], "memberof": "TextureLoader", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoader", "kind": "class" }, { "name": "constructor", "kind": "function", "scope": "instance" } ], "namespace": "TextureLoader#constructor" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "You must free everything you have done and stop all pending load() calls.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 74, "offset": 73 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 74, "offset": 73 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 74, "offset": 73 } } }, "tags": [], "loc": { "start": { "line": 23, "column": 2 }, "end": { "line": 25, "column": 5 } }, "context": { "loc": { "start": { "line": 26, "column": 2 }, "end": { "line": 26, "column": 21 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoader.js", "path": "packages/gl-react/src/TextureLoader.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoader.js#L26-L26" }, "name": "dispose", "kind": "member", "memberof": "TextureLoader", "scope": "instance", "type": { "type": "FunctionType", "params": [], "result": { "type": "VoidLiteral" } }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoader", "kind": "class" }, { "name": "dispose", "kind": "member", "scope": "instance" } ], "namespace": "TextureLoader#dispose" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Check if the loader should handle a given input", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 48, "offset": 47 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 48, "offset": 47 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 48, "offset": 47 } } }, "tags": [], "loc": { "start": { "line": 28, "column": 2 }, "end": { "line": 30, "column": 5 } }, "context": { "loc": { "start": { "line": 31, "column": 2 }, "end": { "line": 31, "column": 34 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoader.js", "path": "packages/gl-react/src/TextureLoader.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoader.js#L31-L31" }, "name": "canLoad", "kind": "member", "memberof": "TextureLoader", "scope": "instance", "type": { "type": "FunctionType", "params": [ { "type": "ParameterType", "name": "input", "expression": { "type": "AllLiteral" } } ], "result": { "type": "NameExpression", "name": "boolean" } }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoader", "kind": "class" }, { "name": "canLoad", "kind": "member", "scope": "instance" } ], "namespace": "TextureLoader#canLoad" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "try to get in sync the texture for a given output. otherwise null.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 67, "offset": 66 } } }, "tags": [], "loc": { "start": { "line": 33, "column": 2 }, "end": { "line": 35, "column": 5 } }, "context": { "loc": { "start": { "line": 36, "column": 2 }, "end": { "line": 36, "column": 34 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoader.js", "path": "packages/gl-react/src/TextureLoader.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoader.js#L36-L36" }, "name": "get", "kind": "member", "memberof": "TextureLoader", "scope": "instance", "type": { "type": "FunctionType", "params": [ { "type": "ParameterType", "name": "input", "expression": { "type": "NameExpression", "name": "T" } } ], "result": { "type": "NullableType", "expression": { "type": "NameExpression", "name": "WebGLTexture" } } }, "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoader", "kind": "class" }, { "name": "get", "kind": "member", "scope": "instance" } ], "namespace": "TextureLoader#get" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "load() called if get() was null. it returns a promise and a dispose function.\nIt is your responsability to cache the disposable per input.\nIf load() is called twice, same value should be returned. but you can drop it when it's loaded.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 96, "offset": 234 }, "indent": [ 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 96, "offset": 234 }, "indent": [ 1, 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 3, "column": 96, "offset": 234 } } }, "tags": [], "loc": { "start": { "line": 38, "column": 2 }, "end": { "line": 42, "column": 5 } }, "context": { "loc": { "start": { "line": 43, "column": 2 }, "end": { "line": 49, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoader.js", "path": "packages/gl-react/src/TextureLoader.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoader.js#L43-L49" }, "name": "load", "kind": "function", "params": [ { "title": "param", "name": "input", "lineNumber": 43, "type": { "type": "NameExpression", "name": "T" } } ], "returns": [ { "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "DisposablePromise" }, "applications": [ { "type": "NameExpression", "name": "WebGLTexture" } ] } } ], "memberof": "TextureLoader", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoader", "kind": "class" }, { "name": "load", "kind": "function", "scope": "instance" } ], "namespace": "TextureLoader#load" } ], "static": [], "events": [] }, "path": [ { "name": "TextureLoader", "kind": "class" } ], "namespace": "TextureLoader" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Utility to visit the Surface & Node draw lifecycle (used for logging and testing)", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 82, "offset": 81 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 82, "offset": 81 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 82, "offset": 81 } } }, "tags": [ { "title": "namespace", "description": null, "lineNumber": 2, "name": null } ], "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 9, "column": 3 } }, "context": { "loc": { "start": { "line": 10, "column": 0 }, "end": { "line": 28, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitors.js", "path": "packages/gl-react/src/Visitors.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitors.js#L10-L28" }, "kind": "namespace", "name": "Visitors", "members": { "instance": [], "static": [ { "description": "", "tags": [ { "title": "memberof", "description": "Visitors", "lineNumber": 1 } ], "loc": { "start": { "line": 11, "column": 2 }, "end": { "line": 13, "column": 5 } }, "context": { "loc": { "start": { "line": 14, "column": 2 }, "end": { "line": 16, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitors.js", "path": "packages/gl-react/src/Visitors.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitors.js#L14-L16" }, "memberof": "Visitors", "name": "add", "kind": "function", "params": [ { "title": "param", "name": "visitor", "lineNumber": 14, "type": { "type": "NameExpression", "name": "VisitorLike" } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitors", "kind": "namespace" }, { "name": "add", "kind": "function" } ], "namespace": "Visitorsadd" }, { "description": "", "tags": [ { "title": "memberof", "description": "Visitors", "lineNumber": 1 } ], "loc": { "start": { "line": 17, "column": 2 }, "end": { "line": 19, "column": 5 } }, "context": { "loc": { "start": { "line": 20, "column": 2 }, "end": { "line": 23, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitors.js", "path": "packages/gl-react/src/Visitors.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitors.js#L20-L23" }, "memberof": "Visitors", "name": "remove", "kind": "function", "params": [ { "title": "param", "name": "visitor", "lineNumber": 20, "type": { "type": "NameExpression", "name": "VisitorLike" } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitors", "kind": "namespace" }, { "name": "remove", "kind": "function" } ], "namespace": "Visitorsremove" } ], "events": [] }, "path": [ { "name": "Visitors", "kind": "namespace" } ], "namespace": "Visitors" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Extensible way to support more sampler2D uniform texture formats.\nYou must call the methods statically before the ", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 49, "offset": 114 }, "indent": [ 1 ] } }, { "type": "inlineCode", "value": "", "position": { "start": { "line": 2, "column": 49, "offset": 114 }, "end": { "line": 2, "column": 60, "offset": 125 }, "indent": [] } }, { "type": "text", "value": " is instanciated.", "position": { "start": { "line": 2, "column": 60, "offset": 125 }, "end": { "line": 2, "column": 77, "offset": 142 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 77, "offset": 142 }, "indent": [ 1 ] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 2, "column": 77, "offset": 142 } } }, "tags": [ { "title": "namespace", "description": null, "lineNumber": 3, "name": null } ], "loc": { "start": { "line": 9, "column": 0 }, "end": { "line": 13, "column": 3 } }, "context": { "loc": { "start": { "line": 14, "column": 0 }, "end": { "line": 33, "column": 2 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoaders.js", "path": "packages/gl-react/src/TextureLoaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoaders.js#L14-L33" }, "kind": "namespace", "name": "TextureLoaders", "members": { "instance": [], "static": [ { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Add a TextureLoader class to extend texture format support.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 60, "offset": 59 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 60, "offset": 59 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 60, "offset": 59 } } }, "tags": [ { "title": "memberof", "description": "TextureLoaders", "lineNumber": 2 } ], "loc": { "start": { "line": 15, "column": 2 }, "end": { "line": 18, "column": 5 } }, "context": { "loc": { "start": { "line": 19, "column": 2 }, "end": { "line": 21, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoaders.js", "path": "packages/gl-react/src/TextureLoaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoaders.js#L19-L21" }, "memberof": "TextureLoaders", "name": "add", "kind": "function", "params": [ { "title": "param", "name": "loader", "lineNumber": 19, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Class" }, "applications": [ { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "TextureLoader" }, "applications": [ { "type": "AllLiteral" } ] } ] } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoaders", "kind": "namespace" }, { "name": "add", "kind": "function" } ], "namespace": "TextureLoadersadd" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "Remove a previously added TextureLoader class.", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 47, "offset": 46 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 47, "offset": 46 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 47, "offset": 46 } } }, "tags": [ { "title": "memberof", "description": "TextureLoaders", "lineNumber": 2 } ], "loc": { "start": { "line": 22, "column": 2 }, "end": { "line": 25, "column": 5 } }, "context": { "loc": { "start": { "line": 26, "column": 2 }, "end": { "line": 29, "column": 3 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/TextureLoaders.js", "path": "packages/gl-react/src/TextureLoaders.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/TextureLoaders.js#L26-L29" }, "memberof": "TextureLoaders", "name": "remove", "kind": "function", "params": [ { "title": "param", "name": "loader", "lineNumber": 26, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Class" }, "applications": [ { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "TextureLoader" }, "applications": [ { "type": "AllLiteral" } ] } ] } } ], "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "TextureLoaders", "kind": "namespace" }, { "name": "remove", "kind": "function" } ], "namespace": "TextureLoadersremove" } ], "events": [] }, "path": [ { "name": "TextureLoaders", "kind": "namespace" } ], "namespace": "TextureLoaders" }, { "description": "", "tags": [], "loc": { "start": { "line": 17, "column": 0 }, "end": { "line": 19, "column": 3 } }, "context": { "loc": { "start": { "line": 20, "column": 0 }, "end": { "line": 101, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/VisitorLogger.js", "path": "packages/gl-react/src/VisitorLogger.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/VisitorLogger.js#L20-L101" }, "name": "VisitorLogger", "augments": [ { "title": "augments", "name": "Visitor" } ], "kind": "class", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "VisitorLogger", "kind": "class" } ], "namespace": "VisitorLogger" }, { "description": "", "tags": [], "loc": { "start": { "line": 21, "column": 0 }, "end": { "line": 23, "column": 3 } }, "context": { "loc": { "start": { "line": 24, "column": 0 }, "end": { "line": 65, "column": 1 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L24-L65" }, "name": "Visitor", "kind": "class", "members": { "instance": [ { "description": "", "tags": [], "loc": { "start": { "line": 25, "column": 2 }, "end": { "line": 27, "column": 5 } }, "context": { "loc": { "start": { "line": 28, "column": 2 }, "end": { "line": 28, "column": 37 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L28-L28" }, "name": "onSurfaceMount", "kind": "function", "params": [ { "title": "param", "name": "surface", "lineNumber": 28, "type": { "type": "NameExpression", "name": "Surface" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onSurfaceMount", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onSurfaceMount" }, { "description": "", "tags": [], "loc": { "start": { "line": 29, "column": 2 }, "end": { "line": 31, "column": 5 } }, "context": { "loc": { "start": { "line": 32, "column": 2 }, "end": { "line": 32, "column": 39 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L32-L32" }, "name": "onSurfaceUnmount", "kind": "function", "params": [ { "title": "param", "name": "surface", "lineNumber": 32, "type": { "type": "NameExpression", "name": "Surface" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onSurfaceUnmount", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onSurfaceUnmount" }, { "description": "", "tags": [], "loc": { "start": { "line": 33, "column": 2 }, "end": { "line": 35, "column": 5 } }, "context": { "loc": { "start": { "line": 36, "column": 2 }, "end": { "line": 36, "column": 75 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L36-L36" }, "name": "onSurfaceGLContextChange", "kind": "function", "params": [ { "title": "param", "name": "surface", "lineNumber": 36, "type": { "type": "NameExpression", "name": "Surface" } }, { "title": "param", "name": "gl", "lineNumber": 36, "type": { "type": "NullableType", "expression": { "type": "NameExpression", "name": "WebGLRenderingContext" } } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onSurfaceGLContextChange", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onSurfaceGLContextChange" }, { "description": "", "tags": [], "loc": { "start": { "line": 37, "column": 2 }, "end": { "line": 38, "column": 5 } }, "context": { "loc": { "start": { "line": 39, "column": 2 }, "end": { "line": 39, "column": 43 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L39-L39" }, "name": "onSurfaceDrawSkipped", "kind": "function", "params": [ { "title": "param", "name": "surface", "lineNumber": 39, "type": { "type": "NameExpression", "name": "Surface" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onSurfaceDrawSkipped", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onSurfaceDrawSkipped" }, { "description": "", "tags": [], "loc": { "start": { "line": 40, "column": 2 }, "end": { "line": 41, "column": 5 } }, "context": { "loc": { "start": { "line": 42, "column": 2 }, "end": { "line": 42, "column": 41 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L42-L42" }, "name": "onSurfaceDrawStart", "kind": "function", "params": [ { "title": "param", "name": "surface", "lineNumber": 42, "type": { "type": "NameExpression", "name": "Surface" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onSurfaceDrawStart", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onSurfaceDrawStart" }, { "description": { "type": "root", "children": [ { "type": "paragraph", "children": [ { "type": "text", "value": "if returns true, it prevent a throw to happen from the request animation frame loop (or from a surface.flush() call).", "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 118, "offset": 117 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 118, "offset": 117 }, "indent": [] } } ], "position": { "start": { "line": 1, "column": 1, "offset": 0 }, "end": { "line": 1, "column": 118, "offset": 117 } } }, "tags": [], "loc": { "start": { "line": 43, "column": 2 }, "end": { "line": 45, "column": 5 } }, "context": { "loc": { "start": { "line": 46, "column": 2 }, "end": { "line": 46, "column": 49 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L46-L46" }, "name": "onSurfaceDrawError", "kind": "function", "params": [ { "title": "param", "name": "e", "lineNumber": 46, "type": { "type": "NameExpression", "name": "Error" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onSurfaceDrawError", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onSurfaceDrawError" }, { "description": "", "tags": [], "loc": { "start": { "line": 47, "column": 2 }, "end": { "line": 48, "column": 5 } }, "context": { "loc": { "start": { "line": 49, "column": 2 }, "end": { "line": 49, "column": 39 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L49-L49" }, "name": "onSurfaceDrawEnd", "kind": "function", "params": [ { "title": "param", "name": "surface", "lineNumber": 49, "type": { "type": "NameExpression", "name": "Surface" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onSurfaceDrawEnd", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onSurfaceDrawEnd" }, { "description": "", "tags": [], "loc": { "start": { "line": 50, "column": 2 }, "end": { "line": 51, "column": 5 } }, "context": { "loc": { "start": { "line": 52, "column": 2 }, "end": { "line": 52, "column": 34 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L52-L52" }, "name": "onNodeDrawSkipped", "kind": "function", "params": [ { "title": "param", "name": "node", "lineNumber": 52, "type": { "type": "NameExpression", "name": "Node" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onNodeDrawSkipped", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onNodeDrawSkipped" }, { "description": "", "tags": [], "loc": { "start": { "line": 53, "column": 2 }, "end": { "line": 54, "column": 5 } }, "context": { "loc": { "start": { "line": 55, "column": 2 }, "end": { "line": 55, "column": 32 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L55-L55" }, "name": "onNodeDrawStart", "kind": "function", "params": [ { "title": "param", "name": "node", "lineNumber": 55, "type": { "type": "NameExpression", "name": "Node" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onNodeDrawStart", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onNodeDrawStart" }, { "description": "", "tags": [], "loc": { "start": { "line": 56, "column": 2 }, "end": { "line": 57, "column": 5 } }, "context": { "loc": { "start": { "line": 58, "column": 2 }, "end": { "line": 58, "column": 92 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L58-L58" }, "name": "onNodeSyncDeps", "kind": "function", "params": [ { "title": "param", "name": "node", "lineNumber": 58, "type": { "type": "NameExpression", "name": "Node" } }, { "title": "param", "name": "additions", "lineNumber": 58, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "UnionType", "elements": [ { "type": "NameExpression", "name": "Node" }, { "type": "NameExpression", "name": "Bus" } ] } ] } }, { "title": "param", "name": "deletions", "lineNumber": 58, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ { "type": "UnionType", "elements": [ { "type": "NameExpression", "name": "Node" }, { "type": "NameExpression", "name": "Bus" } ] } ] } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onNodeSyncDeps", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onNodeSyncDeps" }, { "description": "", "tags": [], "loc": { "start": { "line": 59, "column": 2 }, "end": { "line": 60, "column": 5 } }, "context": { "loc": { "start": { "line": 61, "column": 2 }, "end": { "line": 61, "column": 55 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L61-L61" }, "name": "onNodeDraw", "kind": "function", "params": [ { "title": "param", "name": "node", "lineNumber": 61, "type": { "type": "NameExpression", "name": "Node" } }, { "title": "param", "name": "preparedUniforms", "lineNumber": 61, "type": { "type": "TypeApplication", "expression": { "type": "NameExpression", "name": "Array" }, "applications": [ null ] } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onNodeDraw", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onNodeDraw" }, { "description": "", "tags": [], "loc": { "start": { "line": 62, "column": 2 }, "end": { "line": 63, "column": 5 } }, "context": { "loc": { "start": { "line": 64, "column": 2 }, "end": { "line": 64, "column": 30 } }, "file": "/Users/gre/dev/gl-react-next/packages/gl-react/src/Visitor.js", "path": "packages/gl-react/src/Visitor.js", "github": "https://github.com/gre/gl-react/blob/80eb9e95839a7dae1f4390d2570f0422020ae14e/packages/gl-react/src/Visitor.js#L64-L64" }, "name": "onNodeDrawEnd", "kind": "function", "params": [ { "title": "param", "name": "node", "lineNumber": 64, "type": { "type": "NameExpression", "name": "Node" } } ], "memberof": "Visitor", "scope": "instance", "members": { "instance": [], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" }, { "name": "onNodeDrawEnd", "kind": "function", "scope": "instance" } ], "namespace": "Visitor#onNodeDrawEnd" } ], "static": [], "events": [] }, "path": [ { "name": "Visitor", "kind": "class" } ], "namespace": "Visitor" } ]