diff options
author | Brecht Van Lommel <brecht@blender.org> | 2020-02-26 19:31:33 +0300 |
---|---|---|
committer | Brecht Van Lommel <brecht@blender.org> | 2020-03-11 19:07:17 +0300 |
commit | f01bc597a8e6bf5df19f1af0c422918c96b25e41 (patch) | |
tree | 14e118d55e360186227c7d04d4f1ab6052acf2bf /intern/cycles/kernel/kernels/cpu | |
parent | 9910803574c4472e348ce140a49fc4fb212f9ee7 (diff) |
Cleanup: stop encoding image data type in slot index
This is legacy code from when we had a fixed number of textures.
Diffstat (limited to 'intern/cycles/kernel/kernels/cpu')
-rw-r--r-- | intern/cycles/kernel/kernels/cpu/kernel_cpu_image.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/intern/cycles/kernel/kernels/cpu/kernel_cpu_image.h b/intern/cycles/kernel/kernels/cpu/kernel_cpu_image.h index 8f311baf010..7eb66b0b4ca 100644 --- a/intern/cycles/kernel/kernels/cpu/kernel_cpu_image.h +++ b/intern/cycles/kernel/kernels/cpu/kernel_cpu_image.h @@ -474,7 +474,7 @@ ccl_device float4 kernel_tex_image_interp(KernelGlobals *kg, int id, float x, fl { const TextureInfo &info = kernel_tex_fetch(__texture_info, id); - switch (kernel_tex_type(id)) { + switch (info.data_type) { case IMAGE_DATA_TYPE_HALF: return TextureInterpolator<half>::interp(info, x, y); case IMAGE_DATA_TYPE_BYTE: @@ -503,7 +503,7 @@ ccl_device float4 kernel_tex_image_interp_3d( { const TextureInfo &info = kernel_tex_fetch(__texture_info, id); - switch (kernel_tex_type(id)) { + switch (info.data_type) { case IMAGE_DATA_TYPE_HALF: return TextureInterpolator<half>::interp_3d(info, x, y, z, interp); case IMAGE_DATA_TYPE_BYTE: |