संदर्भ vertexNormals

vertexNormals

An array with the vectors that are normal to the geometry's vertices.

A face's orientation is defined by its normal vector which points out of the face and is normal (perpendicular) to the surface. Calling myGeometry.computeNormals() first calculates each face's normal vector. Then it calculates the normal vector for each vertex by averaging the normal vectors of the faces surrounding the vertex. The vertex normals are stored as p5.Vector objects in the myGeometry.vertexNormals array.

उदाहरण

This page is generated from the comments in src/webgl/p5.Geometry.js . Please feel free to edit it and submit a pull request!

संबंधित संदर्भ