summaryrefslogtreecommitdiff
path: root/scene
diff options
context:
space:
mode:
authorGilles Roudière <gilles.roudiere@gmail.com>2021-06-24 09:26:51 +0200
committerGilles Roudière <gilles.roudiere@gmail.com>2021-06-24 09:26:51 +0200
commitf8c03151be390f495ad2409b109abf7dfa7d9e44 (patch)
treeb5e3dd16b87eefd104a48030e5e8851000fb4d67 /scene
parent9ace46a7d292e768a108cb5ad2acf88dbc57e8a6 (diff)
Fix polygon 2D rendering black
Diffstat (limited to 'scene')
-rw-r--r--scene/2d/polygon_2d.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/2d/polygon_2d.cpp b/scene/2d/polygon_2d.cpp
index 1eec2a3833..860e95b51e 100644
--- a/scene/2d/polygon_2d.cpp
+++ b/scene/2d/polygon_2d.cpp
@@ -365,7 +365,7 @@ void Polygon2D::_notification(int p_what) {
arr[RS::ARRAY_INDEX] = index_array;
RS::get_singleton()->mesh_add_surface_from_arrays(mesh, RS::PRIMITIVE_TRIANGLES, arr, Array(), Dictionary(), RS::ARRAY_FLAG_USE_2D_VERTICES);
- RS::get_singleton()->canvas_item_add_mesh(get_canvas_item(), mesh, Transform2D(), Color(), texture.is_valid() ? texture->get_rid() : RID());
+ RS::get_singleton()->canvas_item_add_mesh(get_canvas_item(), mesh, Transform2D(), Color(1, 1, 1), texture.is_valid() ? texture->get_rid() : RID());
}
} break;