Browse Source

Merge pull request #78134 from kleonc/y-sort-initialize-modulate

Fix uninitialized Y-sort modulate for CanvasItems
Rémi Verschelde 2 years ago
parent
commit
66423d440e
1 changed files with 1 additions and 0 deletions
  1. 1 0
      servers/rendering/renderer_canvas_cull.cpp

+ 1 - 0
servers/rendering/renderer_canvas_cull.cpp

@@ -311,6 +311,7 @@ void RendererCanvasCull::_cull_canvas_item(Item *p_canvas_item, const Transform2
 			int i = 1;
 			_collect_ysort_children(ci, Transform2D(), p_material_owner, Color(1, 1, 1, 1), child_items, i, p_z);
 			ci->ysort_xform = ci->xform.affine_inverse();
+			ci->ysort_modulate = Color(1, 1, 1, 1);
 
 			SortArray<Item *, ItemPtrSort> sorter;
 			sorter.sort(child_items, child_item_count);