Arch/Draft: Fix transparency vs. alpha issues

Fix #18295
This commit is contained in:
wmayer
2024-12-07 16:17:37 +01:00
committed by Yorik van Havre
parent 8d0efd4b21
commit 4666fe8a5b
9 changed files with 13 additions and 13 deletions

View File

@@ -625,7 +625,7 @@ class ViewProviderBuildingPart:
if hasattr(child.ViewObject,"DiffuseColor") and len(child.ViewObject.DiffuseColor) == len(child.Shape.Faces):
colors.extend(child.ViewObject.DiffuseColor)
else:
c = child.ViewObject.ShapeColor[:3]+(child.ViewObject.Transparency/100.0,)
c = child.ViewObject.ShapeColor[:3]+(1.0 - child.ViewObject.Transparency/100.0,)
for i in range(len(child.Shape.Faces)):
colors.append(c)
return colors