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

Fix TGA save bug, add test #3169

Merged
merged 1 commit into from
Oct 13, 2024
Merged

Fix TGA save bug, add test #3169

merged 1 commit into from
Oct 13, 2024

Conversation

ankith26
Copy link
Member

My take for the TGA save bug discovered in #31686

The test was contributed by @Starbuck5

@ankith26 ankith26 requested a review from a team as a code owner October 12, 2024 08:15
@yunline yunline added image pygame.image bugfix PR that fixes bug labels Oct 13, 2024
Copy link
Member

@MyreMylar MyreMylar left a comment

Choose a reason for hiding this comment

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

OK, LGTM 👍

The new test passes locally with the fix on Windows.

Copy link
Contributor

@bilhox bilhox left a comment

Choose a reason for hiding this comment

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

Approving this while I don't fully understand the bug, so I'll not merge it yet. Also hey, I didn't know #31686 existed :)

@bilhox bilhox added this to the 2.5.3 milestone Oct 13, 2024
Copy link
Member

@Matiiss Matiiss left a comment

Choose a reason for hiding this comment

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

The algorithm does appear to skip the repetition chunk now if we're at the end of the line (x == w) and the last pixel was not repeated by the one before it.
LGTM

@Matiiss Matiiss merged commit 6e0e0c6 into main Oct 13, 2024
28 checks passed
@damusss damusss deleted the ankith26-tga-pallete branch October 13, 2024 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix PR that fixes bug image pygame.image
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants