3d-force-graph icon indicating copy to clipboard operation
3d-force-graph copied to clipboard

use a circle sprite as a node ?

Open 1455667325 opened this issue 4 years ago • 1 comments

Hello: when I use img as a node ,I need use the sprite and I can set it's scale (sprite.scale.set(12, 12);) ,but get a rect, How can I set the sprite and then get a circle, (due to the rect can cover the relation line) . thanks.

1455667325 avatar Sep 22 '20 02:09 1455667325

Even though a Sprite needs to be a rectangular planar object, you can paint only a portion of it, like a circle in your case. To make the sprite background fully transparent, make sure that you set depthWrite: false on the sprite material, otherwise it can obfuscate the link lines as you've mentioned.

vasturiano avatar Oct 14 '20 09:10 vasturiano