From 70648683a2aa97c7d0ebd310d7a2ab564bcd4fed Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 24 Jun 2022 10:21:45 +1000 Subject: Cleanup: add C++ compatible WL_ARRAY_FOR_EACH macro --- .clang-format | 1 + 1 file changed, 1 insertion(+) (limited to '.clang-format') diff --git a/.clang-format b/.clang-format index f7b785adaf2..7b8e0ef8eba 100644 --- a/.clang-format +++ b/.clang-format @@ -265,6 +265,7 @@ ForEachMacros: - SET_SLOT_PROBING_BEGIN - MAP_SLOT_PROBING_BEGIN - VECTOR_SET_SLOT_PROBING_BEGIN + - WL_ARRAY_FOR_EACH StatementMacros: - PyObject_HEAD -- cgit v1.2.3 From d832d993c5b47b0de7ca24914ad9c064607830c7 Mon Sep 17 00:00:00 2001 From: Andrii Symkin Date: Fri, 29 Jul 2022 13:41:37 +0200 Subject: Cycles: add new Spectrum and PackedSpectrum types These replace float3 and packed_float3 in various places in the kernel where a spectral color representation will be used in the future. That representation will require more than 3 channels and conversion to from/RGB. The kernel code was refactored to remove the assumption that Spectrum and RGB colors are the same thing. There are no functional changes, Spectrum is still a float3 and the conversion functions are no-ops. Differential Revision: https://developer.blender.org/D15535 --- .clang-format | 1 + 1 file changed, 1 insertion(+) (limited to '.clang-format') diff --git a/.clang-format b/.clang-format index 7b8e0ef8eba..7e88e6d1cb1 100644 --- a/.clang-format +++ b/.clang-format @@ -266,6 +266,7 @@ ForEachMacros: - MAP_SLOT_PROBING_BEGIN - VECTOR_SET_SLOT_PROBING_BEGIN - WL_ARRAY_FOR_EACH + - FOREACH_SPECTRUM_CHANNEL StatementMacros: - PyObject_HEAD -- cgit v1.2.3 From 8611c37f975737efe0d159822edfc21733268f51 Mon Sep 17 00:00:00 2001 From: Patrick Mours Date: Thu, 8 Sep 2022 19:31:44 +0200 Subject: Cycles: Generate OSL closures using macros and a template file This has the advantage of being able to use information about the existing OSL closures in various places without code duplication. In addition, the setup code for all closures was moved to standalone functions to avoid usage of virtual function calls in preparation for GPU support. This patch was split from D15902. Differential Revision: https://developer.blender.org/D15917 --- .clang-format | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.clang-format') diff --git a/.clang-format b/.clang-format index 7e88e6d1cb1..72add4594a4 100644 --- a/.clang-format +++ b/.clang-format @@ -273,5 +273,5 @@ StatementMacros: - PyObject_VAR_HEAD - ccl_gpu_kernel_postfix -MacroBlockBegin: "^BSDF_CLOSURE_CLASS_BEGIN$" -MacroBlockEnd: "^BSDF_CLOSURE_CLASS_END$" +MacroBlockBegin: "^OSL_CLOSURE_STRUCT_BEGIN$" +MacroBlockEnd: "^OSL_CLOSURE_STRUCT_END$" -- cgit v1.2.3