Open Kert opened 4 years ago
@kert thanks for reaching out.
If you set nodeThreeObjectExtend
and linkThreeObjectExtend
to false
(as is by default), the default node/link objects will not be included in the scene, and the lib will rely purely on your implementation of the objects in the nodeThreeObject
, linkThreeObject
and linkPositionUpdate
methods.
@vasturiano The problem here as I said is that the implementation of these objects in my case must be made outside of nodeThreeObject/linkThreeObject because buffered geometry only has one "object", the rest differ by attributes, I can't use these methods in this case because nodeThreeObject/linkThreeObject return a separate object per node/link.
@kert if I understand correctly you wish to have a shared single buffer geometry in all of your node/link objects? If that's the case, you can still do that using the nodeThreeObject
method. Just create a new Mesh
object which references the shared geometry.
You can do the same for the mesh material too, to save rendering performance.
In my project I hid 3d-force-graph links and implemented my own using buffered objects because of performance problems. That includes updating positions through onEngineTicks e.t.c. But I can't seem to remove in-built link three.js objects from the scene no matter what method I use Is there any? Can this be implemented by for e.g. passing -1 to linkThreeObject?