Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Mours <pmours@nvidia.com>2019-09-12 15:46:47 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2019-09-13 12:46:22 +0300
commit53932f1f068501bfb095c407a7777a964dc5ec1c (patch)
tree82dfda8cd109d61ab0bf3601e5caf140001146c8 /intern/cycles/kernel/geom
parent7eb293a37b868ffab53be056b85d6e1f5444f62f (diff)
Cycles: add Optix support in the kernel
This adds all the kernel side changes for the Optix backend. Ref D5363
Diffstat (limited to 'intern/cycles/kernel/geom')
-rw-r--r--intern/cycles/kernel/geom/geom_curve_intersect.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/intern/cycles/kernel/geom/geom_curve_intersect.h b/intern/cycles/kernel/geom/geom_curve_intersect.h
index 0327ebf8890..7a770470150 100644
--- a/intern/cycles/kernel/geom/geom_curve_intersect.h
+++ b/intern/cycles/kernel/geom/geom_curve_intersect.h
@@ -38,12 +38,14 @@ ccl_device_forceinline bool cardinal_curve_intersect(KernelGlobals *kg,
{
const bool is_curve_primitive = (type & PRIMITIVE_CURVE);
+# ifndef __KERNEL_OPTIX__ /* see OptiX motion flag OPTIX_MOTION_FLAG_[START|END]_VANISH */
if (!is_curve_primitive && kernel_data.bvh.use_bvh_steps) {
const float2 prim_time = kernel_tex_fetch(__prim_time, curveAddr);
if (time < prim_time.x || time > prim_time.y) {
return false;
}
}
+# endif
int segment = PRIMITIVE_UNPACK_SEGMENT(type);
float epsilon = 0.0f;
@@ -505,12 +507,14 @@ ccl_device_forceinline bool curve_intersect(KernelGlobals *kg,
const bool is_curve_primitive = (type & PRIMITIVE_CURVE);
+# ifndef __KERNEL_OPTIX__ /* see OptiX motion flag OPTIX_MOTION_FLAG_[START|END]_VANISH */
if (!is_curve_primitive && kernel_data.bvh.use_bvh_steps) {
const float2 prim_time = kernel_tex_fetch(__prim_time, curveAddr);
if (time < prim_time.x || time > prim_time.y) {
return false;
}
}
+# endif
int segment = PRIMITIVE_UNPACK_SEGMENT(type);
/* curve Intersection check */