From bb6f04c9f53f4318c3bd44b3e7398f6973f7b68d Mon Sep 17 00:00:00 2001 From: Tritium Oxide Date: Wed, 1 Jan 2020 19:14:51 +0700 Subject: [PATCH] Fix wrong return type `ERROR: _display_error_with_code: CanvasShaderGLES3: Fragment Program Compilation Failed: 0:166(2): error: `return' with wrong type int, in function `map_ninepatch_axis' returning float` caused by #34704 --- drivers/gles3/shaders/canvas.glsl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gles3/shaders/canvas.glsl b/drivers/gles3/shaders/canvas.glsl index cd1c669be5d..ec18c83df35 100644 --- a/drivers/gles3/shaders/canvas.glsl +++ b/drivers/gles3/shaders/canvas.glsl @@ -419,7 +419,7 @@ float map_ninepatch_axis(float pixel, float draw_size, float tex_pixel_size, flo // Scale to source texture. return (margin_begin + ratio * dst_area) * tex_pixel_size; } else { // Shouldn't happen, but silences compiler warning. - return 0; + return 0.0; } } }