How to plot streamtube like threejs

how to plot streamtube like threejs using param {
startPoint:{
x: 0, y:0, z:0, radius:5
},
endPoint:{
x: 70, y:80, z:90, radius:8
}
}