mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-07 06:57:28 -06:00
Fix colors of compatibility mode. CURA-3273
This commit is contained in:
parent
4b02a425d8
commit
ed1fea2d3e
1 changed files with 4 additions and 3 deletions
|
@ -9,6 +9,7 @@ from UM.Scene.SceneNode import SceneNode
|
||||||
from UM.Application import Application
|
from UM.Application import Application
|
||||||
from UM.Mesh.MeshData import MeshData
|
from UM.Mesh.MeshData import MeshData
|
||||||
from UM.Preferences import Preferences
|
from UM.Preferences import Preferences
|
||||||
|
from UM.View.GL.OpenGLContext import OpenGLContext
|
||||||
|
|
||||||
from UM.Message import Message
|
from UM.Message import Message
|
||||||
from UM.i18n import i18nCatalog
|
from UM.i18n import i18nCatalog
|
||||||
|
@ -180,10 +181,10 @@ class ProcessSlicedLayersJob(Job):
|
||||||
material_color_map[0, :] = color
|
material_color_map[0, :] = color
|
||||||
|
|
||||||
# We have to scale the colors for compatibility mode
|
# We have to scale the colors for compatibility mode
|
||||||
if Application.getInstance().getRenderer().getSupportsGeometryShader():
|
if OpenGLContext.isLegacyOpenGL() or bool(Preferences.getInstance().getValue("view/force_layer_view_compatibility_mode")):
|
||||||
line_type_brightness = 1.0
|
|
||||||
else:
|
|
||||||
line_type_brightness = 0.5 # for compatibility mode
|
line_type_brightness = 0.5 # for compatibility mode
|
||||||
|
else:
|
||||||
|
line_type_brightness = 1.0
|
||||||
layer_mesh = layer_data.build(material_color_map, line_type_brightness)
|
layer_mesh = layer_data.build(material_color_map, line_type_brightness)
|
||||||
|
|
||||||
if self._abort_requested:
|
if self._abort_requested:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue