diff options
author | Brecht Van Lommel <brecht@blender.org> | 2021-01-22 21:30:23 +0300 |
---|---|---|
committer | Brecht Van Lommel <brecht@blender.org> | 2021-01-22 21:30:23 +0300 |
commit | aaa1d580548d27d946a8f97fc7c6e99f8fd40f1c (patch) | |
tree | 7ab66637f51d939affba32665fe5de49a7199878 /intern/cycles | |
parent | 90bcd5e724f3ca6d6f38e3a0551c300751382e62 (diff) | |
parent | a1f44e43a253eabee74f40315b62cc0c0ff4cb9c (diff) |
Merge branch 'blender-v2.92-release'
Diffstat (limited to 'intern/cycles')
-rw-r--r-- | intern/cycles/util/util_tbb.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/intern/cycles/util/util_tbb.h b/intern/cycles/util/util_tbb.h index 206ba106ca6..168bd5db961 100644 --- a/intern/cycles/util/util_tbb.h +++ b/intern/cycles/util/util_tbb.h @@ -36,7 +36,14 @@ using tbb::parallel_for; static inline void parallel_for_cancel() { +#if TBB_INTERFACE_VERSION_MAJOR >= 12 + tbb::task_group_context *ctx = tbb::task::current_context(); + if (ctx) { + ctx->cancel_group_execution(); + } +#else tbb::task::self().cancel_group_execution(); +#endif } CCL_NAMESPACE_END |