Open bostondevin opened 3 years ago
@bostondevin thanks for reaching out.
It's easier to debug if you make a reproducing example on https://codepen.io/ for instance. But, one issue that I can see already is that you should instantiate your renderer before passing on to the module:
ForceGraph3D({ extraRenderers: [new SVGRenderer()] })
@bostondevin I do not yet have experience with SVGRenderer directly but one possible approach is to load the desired svg files in advance with SVGLoader and reference them as appropriate when it comes time to render each node. I believe SVGLoader suffers from this lack of support for synchronous loading and so accessing SVG data is not as straightforward as one would like, and as one can see from the results, not all SVG attributes are supported. Best of luck.
Is there any solution to this?
Looking for an example using SVGRenderer as an extraRenderer - so I can use an SVG icon as a node. Just including the renderer seems to give an error - how does nodeThreeObject change here? I can't find any examples...
Uncaught (in promise) TypeError: Cannot read property 'style' of undefined at three-render-objects.module.js:540 at Array.forEach ()
at Function.init (three-render-objects.module.js:538)
at initStatic (kapsule.module.js:103)
at Object.comp [as renderObjs] (kapsule.module.js:97)
at Function.init (3d-force-graph.module.js:342)
at initStatic (kapsule.module.js:103)
at comp (kapsule.module.js:97)