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

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGhostkeeper <rubend@tutanota.com>2020-05-01 18:49:29 +0300
committerGhostkeeper <rubend@tutanota.com>2020-05-01 18:49:29 +0300
commit51378cae560036b3ad94a9bf94227bf3d18d2dab (patch)
treeb3a5e9047e4133867ecea60f919caa456e04516d /cura/PreviewPass.py
parent245a4435e1c92e899bd6316e0d23075c14924b07 (diff)
Don't crash if the shader fails to compile
Diffstat (limited to 'cura/PreviewPass.py')
-rw-r--r--cura/PreviewPass.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/cura/PreviewPass.py b/cura/PreviewPass.py
index 5e3982e1f3..7fcc4eb6cd 100644
--- a/cura/PreviewPass.py
+++ b/cura/PreviewPass.py
@@ -1,10 +1,11 @@
-# Copyright (c) 2018 Ultimaker B.V.
+# Copyright (c) 2020 Ultimaker B.V.
# Cura is released under the terms of the LGPLv3 or higher.
from typing import Optional, TYPE_CHECKING, cast
from UM.Application import Application
+from UM.Logger import Logger
from UM.Resources import Resources
from UM.View.RenderPass import RenderPass
@@ -63,6 +64,8 @@ class PreviewPass(RenderPass):
self._shader.setUniformValue("u_shininess", 20.0)
self._shader.setUniformValue("u_renderError", 0.0) # We don't want any error markers!.
self._shader.setUniformValue("u_faceId", -1) # Don't render any selected faces in the preview.
+ else:
+ Logger.error("Unable to compile shader program: overhang.shader")
if not self._non_printing_shader:
if self._non_printing_shader: