| 22 | } |
| 23 | |
| 24 | static bool is_optix_specific_kernel(DeviceKernel kernel, bool osl_shading, bool osl_camera) |
| 25 | { |
| 26 | # ifdef WITH_OSL |
| 27 | /* OSL uses direct callables to execute, so shading needs to be done in OptiX if OSL is used. */ |
| 28 | if (osl_shading && device_kernel_has_shading(kernel)) { |
| 29 | return true; |
| 30 | } |
| 31 | if (osl_camera && kernel == DEVICE_KERNEL_INTEGRATOR_INIT_FROM_CAMERA) { |
| 32 | return true; |
| 33 | } |
| 34 | # else |
| 35 | (void)osl_shading; |
| 36 | (void)osl_camera; |
| 37 | # endif |
| 38 | |
| 39 | return device_kernel_has_intersection(kernel); |
| 40 | } |
| 41 | |
| 42 | bool OptiXDeviceQueue::enqueue(DeviceKernel kernel, |
| 43 | const int work_size, |
no test coverage detected