diff options
author | Gaia Clary <gaia.clary@machinimatrix.org> | 2020-01-22 20:00:33 +0300 |
---|---|---|
committer | Gaia Clary <gaia.clary@machinimatrix.org> | 2020-01-22 20:04:08 +0300 |
commit | 8fc68a2e9cf1d983b3d249988ab05905bd24f06f (patch) | |
tree | ae7929ff0ea5aa08b1e71865a1cb576326878e00 /source/blender/collada/Materials.cpp | |
parent | 084f072aae73de39fecc35ac97d602b1db7d0d98 (diff) |
Fix T69090: Collada Exporter now exports the base color if Nodes are disabled
I also changed the Collada importer scuh that the diffuse Alpha is now set
for the generated PBSDF Shader AND for the base color.
Note: we can not export the base color AND the color
from the PBSDF Shaders at the same time. And when importing
we do not know if the color was originally coming from a base
material or from a shader. Setting them both in import seems
to give the most consistent results.
Diffstat (limited to 'source/blender/collada/Materials.cpp')
-rw-r--r-- | source/blender/collada/Materials.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/collada/Materials.cpp b/source/blender/collada/Materials.cpp index 3b2c68ef95e..06f54884668 100644 --- a/source/blender/collada/Materials.cpp +++ b/source/blender/collada/Materials.cpp @@ -202,6 +202,7 @@ void MaterialNode::set_alpha(COLLADAFW::EffectCommon::OpaqueMode mode, bNodeSocket *socket = nodeFindSocket(shader_node, SOCK_IN, "Alpha"); ((bNodeSocketValueFloat *)socket->default_value)->value = alpha; + material->a = alpha; } else if (cot.isTexture()) { int locy = -300 * (node_map.size() - 2); |