创建对象的属性参数。可包含此类的所有属性。
params.width: box的宽度params.height: box的高度params.depth: box的深度params.widthSegments: 水平分割面的数量params.heightSegments: 垂直分割面的数量params.depthSegments: 深度分割面的数量Readonlyclasscolor 数据
box的深度
深度分割面的数量
box的高度
垂直分割面的数量
Readonlyid顶点索引数据
ReadonlyisReadonlyis是否是静态
绘制模式
骨骼索引
骨骼权重数据
使用 aabb 碰撞检测
用户数据
uv 数据
uv1 数据
顶点数据
box的宽度
水平分割面的数量
法向量数据,如果没有的话会自动生成
Monotonic geometry-state revision observed independently by every backend.
切线向量数据,如果没有的话会自动生成
切线向量数据,如果没有的话会自动生成
添加顶点索引
顶点索引,如 addIndices(0, 1, 2)
将三角形模式转换为线框模式,即 Material 中的 wireframe
将 Geometry 转换成无 indices
转换结果的顶点数据的位数(3 or 4),如果为4会补1
获取数据的内存大小,只处理顶点数据,单位为字节
内存占用大小
Converts primitive modes that WebGPU cannot represent into explicit indexed lists.
Both rendering backends call this method before creating backend resources, so LINE_LOOP and TRIANGLE_FAN have one canonical CPU representation and identical draw semantics. Existing unsigned index width is preserved; non-indexed geometry receives the smallest unsigned index type that can address all of its vertices.
Whether the geometry topology was converted.
旋转
旋转角度x
旋转角度y
旋转角度z
this
缩放
this
设置所有面的uv,不支持设置带有 widthSegments heightSegments depthSegments 的实例
uv数据,如
[
[[0, 1], [1, 1], [1, 0], [0, 0]],
[[0, 1], [1, 1], [1, 0], [0, 0]],
[[0, 1], [1, 1], [1, 0], [0, 0]],
[[0, 1], [1, 1], [1, 0], [0, 0]],
[[0, 1], [1, 1], [1, 0], [0, 0]],
[[0, 1], [1, 1], [1, 0], [0, 0]]
]
设置朝后面的uv,不支持设置带有 widthSegments heightSegments depthSegments 的实例
uv数据,如 [[0, 1], [1, 1], [1, 0], [0, 0]]
设置底部面的uv,不支持设置带有 widthSegments heightSegments depthSegments 的实例
uv数据,如 [[0, 1], [1, 1], [1, 0], [0, 0]]
设置朝前面的uv,不支持设置带有 widthSegments heightSegments depthSegments 的实例
uv数据,如 [[0, 1], [1, 1], [1, 0], [0, 0]]
设置左侧面的uv,不支持设置带有 widthSegments heightSegments depthSegments 的实例
uv数据,如 [[0, 1], [1, 1], [1, 0], [0, 0]]
设置右侧面的uv,不支持设置带有 widthSegments heightSegments depthSegments 的实例
uv数据,如 [[0, 1], [1, 1], [1, 0], [0, 0]]
设置顶部面的uv,不支持设置带有 widthSegments heightSegments depthSegments 的实例
uv数据,如 [[0, 1], [1, 1], [1, 0], [0, 0]]
设置顶点对应的uv坐标
开始的顶点索引
uv坐标数据,如 [[0, 0], [1, 0]]
平移
this
长方体几何体