Cycles: set hit values in-order
This commit is contained in:
@@ -63,10 +63,10 @@ ccl_device bool BVH_FUNCTION_NAME
|
||||
#endif
|
||||
|
||||
isect->t = ray->t;
|
||||
isect->object = OBJECT_NONE;
|
||||
isect->prim = PRIM_NONE;
|
||||
isect->u = 0.0f;
|
||||
isect->v = 0.0f;
|
||||
isect->prim = PRIM_NONE;
|
||||
isect->object = OBJECT_NONE;
|
||||
|
||||
#if defined(__KERNEL_DEBUG__)
|
||||
isect->num_traversal_steps = 0;
|
||||
|
@@ -61,10 +61,10 @@ ccl_device bool BVH_FUNCTION_NAME(KernelGlobals *kg,
|
||||
#endif
|
||||
|
||||
isect->t = ray->t;
|
||||
isect->object = OBJECT_NONE;
|
||||
isect->prim = PRIM_NONE;
|
||||
isect->u = 0.0f;
|
||||
isect->v = 0.0f;
|
||||
isect->prim = PRIM_NONE;
|
||||
isect->object = OBJECT_NONE;
|
||||
|
||||
#if defined(__KERNEL_SSE2__)
|
||||
const shuffle_swap_t shuf_identity = shuffle_swap_identity();
|
||||
|
@@ -600,12 +600,12 @@ ccl_device_inline bool bvh_cardinal_curve_intersect(KernelGlobals *kg, Intersect
|
||||
#endif
|
||||
{
|
||||
/* record intersection */
|
||||
isect->t = t;
|
||||
isect->u = u;
|
||||
isect->v = gd;
|
||||
isect->prim = curveAddr;
|
||||
isect->object = object;
|
||||
isect->type = type;
|
||||
isect->u = u;
|
||||
isect->v = gd;
|
||||
isect->t = t;
|
||||
hit = true;
|
||||
}
|
||||
|
||||
@@ -835,12 +835,12 @@ ccl_device_inline bool bvh_curve_intersect(KernelGlobals *kg, Intersection *isec
|
||||
#endif
|
||||
{
|
||||
/* record intersection */
|
||||
isect->t = t;
|
||||
isect->u = z*invl;
|
||||
isect->v = gd;
|
||||
isect->prim = curveAddr;
|
||||
isect->object = object;
|
||||
isect->type = type;
|
||||
isect->u = z*invl;
|
||||
isect->v = gd;
|
||||
isect->t = t;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@@ -336,12 +336,12 @@ ccl_device_inline bool motion_triangle_intersect(KernelGlobals *kg, Intersection
|
||||
if(kernel_tex_fetch(__prim_visibility, triAddr) & visibility)
|
||||
#endif
|
||||
{
|
||||
isect->t = t;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->prim = triAddr;
|
||||
isect->object = object;
|
||||
isect->type = PRIMITIVE_MOTION_TRIANGLE;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->t = t;
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -388,12 +388,12 @@ ccl_device_inline void motion_triangle_intersect_subsurface(KernelGlobals *kg, I
|
||||
|
||||
/* record intersection */
|
||||
Intersection *isect = &isect_array[hit];
|
||||
isect->t = t;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->prim = triAddr;
|
||||
isect->object = object;
|
||||
isect->type = PRIMITIVE_MOTION_TRIANGLE;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->t = t;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
@@ -334,12 +334,12 @@ ccl_device_inline bool triangle_intersect(KernelGlobals *kg, Intersection *isect
|
||||
#endif
|
||||
{
|
||||
/* record intersection */
|
||||
isect->t = t;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->prim = triAddr;
|
||||
isect->object = object;
|
||||
isect->type = PRIMITIVE_TRIANGLE;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->t = t;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -397,12 +397,12 @@ ccl_device_inline void triangle_intersect_subsurface(KernelGlobals *kg, Intersec
|
||||
|
||||
/* record intersection */
|
||||
Intersection *isect = &isect_array[hit];
|
||||
isect->t = t;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->prim = triAddr;
|
||||
isect->object = object;
|
||||
isect->type = PRIMITIVE_TRIANGLE;
|
||||
isect->u = u;
|
||||
isect->v = v;
|
||||
isect->t = t;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user