summaryrefslogtreecommitdiff
path: root/drivers/gles3/rasterizer_canvas_gles3.cpp
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-03-08 23:44:39 +0100
committerGitHub <noreply@github.com>2019-03-08 23:44:39 +0100
commit86d6a72c9745bd15e3217d63b2cc5ba73fe4ad34 (patch)
tree3acaf61fbcbbc2795a92561da1fadce19e0bd07f /drivers/gles3/rasterizer_canvas_gles3.cpp
parent60d910b1916305c4b0ac5f92415083995b4f7c7a (diff)
parentfbaee40b1dcc9fcd9a4c643698314ffa85cafbe2 (diff)
Merge pull request #26738 from samH-FIT/MeshColor
Fixed MeshInstance2d copying Line2d's default color
Diffstat (limited to 'drivers/gles3/rasterizer_canvas_gles3.cpp')
-rw-r--r--drivers/gles3/rasterizer_canvas_gles3.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gles3/rasterizer_canvas_gles3.cpp b/drivers/gles3/rasterizer_canvas_gles3.cpp
index 4f4608dca0..4817a524f4 100644
--- a/drivers/gles3/rasterizer_canvas_gles3.cpp
+++ b/drivers/gles3/rasterizer_canvas_gles3.cpp
@@ -834,6 +834,8 @@ void RasterizerCanvasGLES3::_canvas_item_render_commands(Item *p_item, Item *cur
// materials are ignored in 2D meshes, could be added but many things (ie, lighting mode, reading from screen, etc) would break as they are not meant be set up at this point of drawing
glBindVertexArray(s->array_id);
+ glVertexAttrib4f(VS::ARRAY_COLOR, 1, 1, 1, 1);
+
if (s->index_array_len) {
glDrawElements(gl_primitive[s->primitive], s->index_array_len, (s->array_len >= (1 << 16)) ? GL_UNSIGNED_INT : GL_UNSIGNED_SHORT, 0);
} else {