Cycles: Fix calculation of normals for subdivision meshes

Not sure what happened here. Will have only effected Cycles standalone with
linear subdivision in use.
This commit is contained in:
Mai Lavelle
2016-08-30 12:22:50 -04:00
parent 959b06b3c8
commit 7aedd0e6b0

View File

@@ -567,10 +567,11 @@ void Mesh::add_vertex_normals()
for(size_t i = 0; i < subd_faces.size(); i++) {
SubdFace& face = subd_faces[i];
float3 fN = face.normal(this);
for(size_t j = 0; j < face.num_corners; j++) {
size_t corner = subd_face_corners[face.start_corner+j];
vN[corner] += verts[corner];
vN[corner] += fN;
}
}