He llo my friends. I desperatly need your help.
I have to create selective bloom like energy wave, something similar to yellow lines from example that I found on the internet https://codepen.io/prisoner849/pen/RwjQaeO
But lines should be thicker and some of them all over the place.
So for some of them I used THREE.TubeGeometry with CatmullRomCurve3 as given bellow:
const points = [];
points.push(new THREE.Vector3(-10,-4.5,2));
points.push(new THREE.Vector3(-1,-0.4,1));
points.push(new THREE.Vector3(0.2,0.2,2));
points.push(new THREE.Vector3(0.8,0.5,0.5));
points.push(new THREE.Vector3(12,4,-2));
let geometry = new THREE.TubeGeometry(new THREE.CatmullRomCurve3(points, false, "catmullrom", 0), 512, 0.001, 64, false);
const material = new THREE.MeshPhongMaterial({
color: 0xffffff,
shininess: 150,
side: THREE.DoubleSide,
vertexColors: false
});
const line = new THREE.LineSegments( geometry, material );
line.computeLineDistances();
scene.add(line);
But lines are neither white, neither have that wave effect, they just pulse from gray to white. I found out that vLineDistance paramether is what gives that wave, and that it is set with computeLineDistances() function but not for my geometry. And if I use THREE.BufferGeometry().setFromPoints(points) I get line that is not from point to point.
Please help me,
Thank you