diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2019-04-06 13:15:01 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-06 13:15:01 +0200 |
commit | 2db0613fb0d4586436cf17b3afa2cf5b64bc96b5 (patch) | |
tree | fde2b719e1d0cc84641bca32dce5049110ca7345 /servers | |
parent | 0b747f5312504d51097382fd6e39fd9a743a6086 (diff) | |
parent | 8b84638322f75e96f7220a1040652ff41fa9d06c (diff) | |
download | redot-engine-2db0613fb0d4586436cf17b3afa2cf5b64bc96b5.tar.gz |
Merge pull request #25624 from nekomatata/texture-rect-flip
Add ability to flip TextureRect horizontally or vertically
Diffstat (limited to 'servers')
-rw-r--r-- | servers/visual/visual_server_canvas.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/servers/visual/visual_server_canvas.cpp b/servers/visual/visual_server_canvas.cpp index af6e3db149..4adf53c183 100644 --- a/servers/visual/visual_server_canvas.cpp +++ b/servers/visual/visual_server_canvas.cpp @@ -629,7 +629,7 @@ void VisualServerCanvas::canvas_item_add_texture_rect(RID p_item, const Rect2 &p if (p_tile) { rect->flags |= RasterizerCanvas::CANVAS_RECT_TILE; rect->flags |= RasterizerCanvas::CANVAS_RECT_REGION; - rect->source = Rect2(0, 0, p_rect.size.width, p_rect.size.height); + rect->source = Rect2(0, 0, fabsf(p_rect.size.width), fabsf(p_rect.size.height)); } if (p_rect.size.x < 0) { |