summaryrefslogtreecommitdiff
path: root/servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp
diff options
context:
space:
mode:
authorYuri Roubinsky <chaosus89@gmail.com>2021-08-16 11:25:20 +0300
committerYuri Roubinsky <chaosus89@gmail.com>2021-08-16 11:25:20 +0300
commit9de779344c33033b89a2e08417934cecc9cb4756 (patch)
tree2d987344a5c3d412128b1b9386f55e2ba4572957 /servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp
parent437b0dd5f62ec1b949380493889e9351bbc34892 (diff)
Makes a clear error message if shader compilation failed
Diffstat (limited to 'servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp')
-rw-r--r--servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp b/servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp
index 14b2768c29..f8aefdb29c 100644
--- a/servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp
+++ b/servers/rendering/renderer_rd/renderer_canvas_render_rd.cpp
@@ -1970,8 +1970,7 @@ void RendererCanvasRenderRD::ShaderData::set_code(const String &p_code) {
RendererCanvasRenderRD *canvas_singleton = (RendererCanvasRenderRD *)RendererCanvasRender::singleton;
Error err = canvas_singleton->shader.compiler.compile(RS::SHADER_CANVAS_ITEM, code, &actions, path, gen_code);
-
- ERR_FAIL_COND(err != OK);
+ ERR_FAIL_COND_MSG(err != OK, "Shader compilation failed.");
if (version.is_null()) {
version = canvas_singleton->shader.canvas_shader.version_create();