Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EditorAtlasPacker Fix incorrectly deducing zero height in some cases #56111

Merged

Conversation

kleonc
Copy link
Member

@kleonc kleonc commented Dec 20, 2021

Prior to this PR for images with width equal to the resulting atlas width the "tetris"/fitting part of the packing algorithm wouldn't be performed. As a result such images would be (possibly incorrectly) deducted to take zero height in the atlas.

Fixes #55998.

Not 100% sure it fixes packing for all cases but it seems to fix every test case provided in #55998.

@Calinou Calinou added bug cherrypick:3.4 cherrypick:3.x Considered for cherry-picking into a future 3.x release topic:2d topic:import labels Dec 20, 2021
@Calinou Calinou added this to the 4.0 milestone Dec 20, 2021
@akien-mga akien-mga merged commit 4a58c08 into godotengine:master Dec 21, 2021
@akien-mga
Copy link
Member

Thanks!

@akien-mga
Copy link
Member

Cherry-picked for 3.5.

@akien-mga akien-mga removed the cherrypick:3.x Considered for cherry-picking into a future 3.x release label Dec 21, 2021
@kleonc kleonc deleted the editor-atlas-packer-zero-height-fix branch December 21, 2021 17:41
@akien-mga
Copy link
Member

Cherry-picked for 3.4.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TextureAtlas fail - Error: Image height must be greater than 0.
3 participants