Skip to content

Ensure .premul_alpha_ip() works with zero sized Surfaces #2980

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

Merged
merged 2 commits into from
Jul 8, 2024

Conversation

itzpr3d4t0r
Copy link
Member

Before this change zero sized surfaces would return None instead of self. Now it correctly returns self. I also added a test to check for this.

@itzpr3d4t0r itzpr3d4t0r added Surface pygame.Surface bugfix PR that fixes bug labels Jul 7, 2024
@itzpr3d4t0r itzpr3d4t0r requested a review from a team as a code owner July 7, 2024 21:41
Copy link
Member

@oddbookworm oddbookworm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Copy link
Member

@ankith26 ankith26 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, I wonder how we reviewers missed it in the original PR 😅

But no issues, this function hasn't seen a release yet. Thanks for the fix.

@ankith26 ankith26 added this to the 2.5.1 milestone Jul 8, 2024
@ankith26 ankith26 merged commit 79a1c58 into pygame-community:main Jul 8, 2024
39 checks passed
@itzpr3d4t0r itzpr3d4t0r deleted the fix-premul-alpha-ip branch July 24, 2024 13:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix PR that fixes bug Surface pygame.Surface
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants