word里怎么画三棱锥,word基本棱锥图怎么增加层数

首页 > 经验 > 作者:YD1662024-02-12 03:54:14

11. 圆环几何体(TorusGeometry)2.11.1 构造函数

THREE.TorusGeometry(radius, tube, radialSegments, tubularSegments)

2.11.2 示例

const radius = 2; const tube = 1; const radialSegments = 8; const tubularSegments = 32; const torusGeometry = new THREE.TorusGeometry(radius, tube, radialSegments, tubularSegments); const material = new THREE.MeshBasicMaterial({ color: 0x00ffff, wireframe: true }); const myGeometry = new THREE.Mesh(torusGeometry, material); scene.add(myGeometry);

word里怎么画三棱锥,word基本棱锥图怎么增加层数(13)

12. 环面结扣几何体(TorusKnotGeometry)2.12.1 构造函数

THREE.TorusKnotGeometry(radius, tube, tubularSegments, radialSegments, p, q)

2.12.2 示例

const radius = 5; const tube = 1; const tubularSegments = 64; const radialSegments = 8; const p = 2; const q = 3; const torusKnotGeometry = new THREE.TorusKnotGeometry(radius, tube, tubularSegments, radialSegments, p, q); const material = new THREE.MeshBasicMaterial({ color: 0x00ff00, wireframe: true }); const torusKnot = new THREE.Mesh(torusKnotGeometry, material); scene.add(torusKnot);

word里怎么画三棱锥,word基本棱锥图怎么增加层数(14)

13. 沿路径管道几何体(创建沿着一系列路径的管道几何体。)2.13.1 构造函数

TubeGeometry(path,tubularSegments ,radius,radialSegments, closed )

2.13.2 示例

class CustomSinCurve extends THREE.Curve { constructor( scale = 1 ) { super(); this.scale = scale; } getPoint( t, optionalTarget = new THREE.Vector3() ) { const tx = t * 3 - 1.5; const ty = Math.sin( 2 * Math.PI * t ); const tz = 0; return optionalTarget.set( tx, ty, tz ).multiplyScalar( this.scale ); } } const path = new CustomSinCurve( 10 ); const geometry = new THREE.TubeGeometry( path, 20, 2, 8, false ); const material = new THREE.MeshPhongMaterial( { color: 0x00ffff } ); const myGeometry = new THREE.Mesh( geometry, material ); scene.add( myGeometry );

word里怎么画三棱锥,word基本棱锥图怎么增加层数(15)

14. 创建几何体的边框几何体2.14.1 构造函数

THREE.WireframeGeometry(geometry)

参数 geometry是原始的几何体。

2.14.2 示例

const geometry = new THREE.SphereGeometry( 10, 10, 10 ); const wireframe = new THREE.WireframeGeometry( geometry ); const myGeometry = new THREE.LineSegments( wireframe ); myGeometry.material.depthTest = false; myGeometry.material.opacity = 0.5; myGeometry.material.transparent = true; scene.add( myGeometry );

word里怎么画三棱锥,word基本棱锥图怎么增加层数(16)

上一页12345下一页

栏目热文

文档排行

本站推荐

Copyright © 2018 - 2021 www.yd166.com., All Rights Reserved.