Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulien Duroure <julien.duroure@gmail.com>2022-05-24 22:24:20 +0300
committerJulien Duroure <julien.duroure@gmail.com>2022-05-24 22:24:20 +0300
commitc28c92c1494cbe67a0d5b26e74ebbe82856e6a7a (patch)
tree45561d6ee99e27e48f48e3670a4fb990f037bc2b /io_scene_gltf2/blender/exp/gltf2_blender_gather_image.py
parentf07a4456f8d85c8706cc277bf8670984489d67fb (diff)
glTF: Replace Separate RGB shader node by new Separate Color node
Diffstat (limited to 'io_scene_gltf2/blender/exp/gltf2_blender_gather_image.py')
-rwxr-xr-xio_scene_gltf2/blender/exp/gltf2_blender_gather_image.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_image.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_image.py
index 7b9335cf..0dfce9f9 100755
--- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_image.py
+++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_image.py
@@ -193,11 +193,11 @@ def __get_image_data(sockets, export_settings) -> ExportImage:
# rudimentarily try follow the node tree to find the correct image data.
src_chan = Channel.R
for elem in result.path:
- if isinstance(elem.from_node, bpy.types.ShaderNodeSeparateRGB):
+ if isinstance(elem.from_node, bpy.types.ShaderNodeSeparateColor):
src_chan = {
- 'R': Channel.R,
- 'G': Channel.G,
- 'B': Channel.B,
+ 'Red': Channel.R,
+ 'Green': Channel.G,
+ 'Blue': Channel.B,
}[elem.from_socket.name]
if elem.from_socket.name == 'Alpha':
src_chan = Channel.A