From c4cea10402f16745d97dbae5d88169dd0c7d9513 Mon Sep 17 00:00:00 2001 From: RaphaelHunter Date: Tue, 29 Oct 2019 14:51:58 +0800 Subject: fix occluders positions error under canvas_layer, close #32880 --- servers/visual/visual_server_viewport.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/servers/visual/visual_server_viewport.cpp b/servers/visual/visual_server_viewport.cpp index f515af4d91..ae1f3712b0 100644 --- a/servers/visual/visual_server_viewport.cpp +++ b/servers/visual/visual_server_viewport.cpp @@ -184,7 +184,7 @@ void VisualServerViewport::_draw_viewport(Viewport *p_viewport, ARVRInterface::E for (Map::Element *E = p_viewport->canvas_map.front(); E; E = E->next()) { VisualServerCanvas::Canvas *canvas = static_cast(E->get().canvas); - Transform2D xf = p_viewport->global_transform * E->get().transform; + Transform2D xf = _canvas_get_transform(p_viewport, canvas, &E->get(), clip_rect.size); for (Set::Element *F = canvas->occluders.front(); F; F = F->next()) { -- cgit v1.2.3