提交 2c4729d4 编写于 作者: M Mr.doob

Editor: Removed numItems dependency in BufferGeometry info panel.

上级 0fb1f758
......@@ -167,15 +167,15 @@ Sidebar.Geometry = function ( editor ) {
} else if ( geometry instanceof THREE.BufferGeometry ) {
geometryVertices.setValue( geometry.attributes.position.numItems / 3 );
geometryVertices.setValue( geometry.attributes.position.array.length / 3 );
if ( geometry.attributes.index !== undefined ) {
geometryFaces.setValue( geometry.attributes.index.numItems / 3 );
geometryFaces.setValue( geometry.attributes.index.array.length / 3 );
} else {
geometryFaces.setValue( geometry.attributes.position.numItems / 3 / 3 );
geometryFaces.setValue( geometry.attributes.position.array.length / 3 / 3 );
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册