mrdoob / three.js

JavaScript 3D Library.
https://threejs.org/
MIT License
102.4k stars 35.35k forks source link

Is there a way to clear vertex normals of a Geometry Object #6579

Closed xizhonghua closed 9 years ago

xizhonghua commented 9 years ago

Hi,

I'm dealing with deformable objects in which the geometry will be updated frame by frame. I want to toggle between face normals and vertex normals to see different rendering results. I wonder if there is a easy way for user to clear all the vertex normals that the mesh will be rendered using face normals, otherwise the mesh will be rendered with previous frame's vertex normals if I don't compute them again in this frame (face normals will always be computed at each frame in my case, there is no need to clear it).

BTW, the doc for Geoemtry.computeVertexNormals () also needs to be updated, I noticed that there is a areaWeighted parameter in the source code which is missed in the doc.

WestLangley commented 9 years ago

Thanks for the doc tip. You can edit it yourself if you want to make a contribution.

Please get help on stackoverflow for your other issues.