Hi, how can I update the line end-position? On updating the end position, the lines are being aggregated to the scene as shown in fig. There are six such lines.
I want to update the end coordinates i.e. PH by moving the slider. A new line should be made, deleting old line…
var material, geometry1
function addline(PH){
//line1
material = new THREE.LineBasicMaterial( { color: 0x0000ff } );
points1.push( new THREE.Vector3( PH[0][0], PH[0][1], PH[0][2] ) );
points1.push( new THREE.Vector3( 104.80, 771.82, 0 ) );
geometry1 = new THREE.BufferGeometry().setFromPoints( points1 );
line1 = new THREE.Line( geometry1, material );
sys.add(line1);
}
function clearline(){
material.dispose();
geometry1.dispose();
sys.remove(line1);
}