Cycles: Fix crash after recent subd fixes
Was happening when object only had curves (doe example, object with hair particle system and emitter rendering disabled).
This commit is contained in:
parent
086ec8af48
commit
86c719f796
|
@ -587,6 +587,10 @@ void Mesh::add_vertex_normals()
|
|||
void Mesh::pack_normals(Scene *scene, uint *tri_shader, float4 *vnormal)
|
||||
{
|
||||
Attribute *attr_vN = attributes.find(ATTR_STD_VERTEX_NORMAL);
|
||||
if(attr_vN == NULL) {
|
||||
/* Happens on objects with just hair. */
|
||||
return;
|
||||
}
|
||||
|
||||
float3 *vN = attr_vN->data_float3();
|
||||
uint shader_id = 0;
|
||||
|
|
Loading…
Reference in New Issue