diff options
author | Ninni Pipping <over999ships@gmail.com> | 2023-02-24 15:58:42 +0100 |
---|---|---|
committer | Ninni Pipping <over999ships@gmail.com> | 2023-06-22 19:20:56 +0200 |
commit | 818fe886a356855001e0c32e7235cdefcfc7192c (patch) | |
tree | 724088e2f99751347c1aa10ccfd42bcf0ef53276 /editor/editor_atlas_packer.cpp | |
parent | 522a2ea3f41fef616980b4d3287f470dd3af9109 (diff) | |
download | redot-engine-818fe886a356855001e0c32e7235cdefcfc7192c.tar.gz |
Bounds fixes in `TextureAtlas` import
Diffstat (limited to 'editor/editor_atlas_packer.cpp')
-rw-r--r-- | editor/editor_atlas_packer.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/editor_atlas_packer.cpp b/editor/editor_atlas_packer.cpp index 04eac0a9fd..5de4869c88 100644 --- a/editor/editor_atlas_packer.cpp +++ b/editor/editor_atlas_packer.cpp @@ -59,7 +59,7 @@ void EditorAtlasPacker::chart_pack(Vector<Chart> &charts, int &r_width, int &r_h Ref<BitMap> src_bitmap; src_bitmap.instantiate(); - src_bitmap->create(aabb.size / divide_by); + src_bitmap->create((aabb.size + Vector2(divide_by - 1, divide_by - 1)) / divide_by); int w = src_bitmap->get_size().width; int h = src_bitmap->get_size().height; |