制作广告网站的步骤,推广网站怎么做,百度搜索关键词查询,河池市民政局门户网站建设线模型Line渲染顶点数据
下面代码是把几何体作为线模型Line (opens new window)的参数#xff0c;你会发现渲染效果是从第一个点开始到最后一个点#xff0c;依次连成线。
// 线材质对象
const material new THREE.LineBasicMaterial({color: 0xff0000 //线条颜色
});
//…线模型Line渲染顶点数据
下面代码是把几何体作为线模型Line (opens new window)的参数你会发现渲染效果是从第一个点开始到最后一个点依次连成线。
// 线材质对象
const material new THREE.LineBasicMaterial({color: 0xff0000 //线条颜色
});
// 创建线模型对象
const line new THREE.Line(geometry, material);线模型LineLoop、LineSegments
threejs线模型除了Line还提供了LineLoop (opens new window)、LineSegments (opens new window)区别在于绘制线条的规则不同。
// 闭合线条
const line new THREE.LineLoop(geometry, material); //非连续的线条
const line new THREE.LineSegments(geometry, material);