[Bf-blender-cvs] [b2edc716c13] master: Fix Cycles OptiX runtime compilation broken after shader raytracing
Brecht Van Lommel
noreply at git.blender.org
Tue Dec 22 15:09:12 CET 2020
Commit: b2edc716c1311a11420c41ebd27dcac509685e2e
Author: Brecht Van Lommel
Date: Tue Dec 22 15:07:53 2020 +0100
Branches: master
https://developer.blender.org/rBb2edc716c1311a11420c41ebd27dcac509685e2e
Fix Cycles OptiX runtime compilation broken after shader raytracing
Need to pass the appropriate flags as we do for compilation as part of the
CMake build.
===================================================================
M intern/cycles/device/device_optix.cpp
===================================================================
diff --git a/intern/cycles/device/device_optix.cpp b/intern/cycles/device/device_optix.cpp
index a721f426dfe..223a9e9d6c0 100644
--- a/intern/cycles/device/device_optix.cpp
+++ b/intern/cycles/device/device_optix.cpp
@@ -314,6 +314,14 @@ class OptiXDevice : public CUDADevice {
common_cflags += string_printf(" -I\"%s/include\"", optix_sdk_path);
}
+ // Specialization for shader raytracing
+ if (requested_features.use_shader_raytrace) {
+ common_cflags += " --keep-device-functions";
+ }
+ else {
+ common_cflags += " -D __NO_SHADER_RAYTRACE__";
+ }
+
return common_cflags;
}
More information about the Bf-blender-cvs
mailing list