BufferGeometry

平面缓冲几何体(PlaneBufferGeometry)

这是PlaneGeometry中的BufferGeometry接口。

代码示例

const geometry = new v3d.PlaneBufferGeometry(5, 20, 32); const material = new v3d.MeshBasicMaterial({color: 0xffff00, side: v3d.DoubleSide}); const plane = new v3d.Mesh(geometry, material); scene.add(plane);

构造函数

PlaneBufferGeometry(width : Float, height : Float, widthSegments : Integer, heightSegments : Integer)

width — 平面沿着X轴的宽度。默认值是1。
height — 平面沿着Y轴的高度。默认值是1。
widthSegments — (可选)平面的宽度分段数,默认值是1。
heightSegments — (可选)平面的高度分段数,默认值是1。

属性

共有属性请参见其基类BufferGeometry

.parameters

一个包含着构造函数中每个参数的对象。在对象实例化之后,对该属性的任何修改都不会改变这个几何体。

方法(Methods)

共有方法请参见其基类BufferGeometry

源代码

src/geometries/PlaneBufferGeometry.js