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

flood fill #2840

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open

flood fill #2840

wants to merge 9 commits into from

Conversation

robertpfeiffer
Copy link
Contributor

Flood fill drawing operation, like in GIMP and ASEprite.

This still needs docs and tests, and perhaps some more special-case handling of indexed surfaces. Can take a pattern surface as color argument. If you like this, maybe we can add pattern surfaces to polygons also, but in a pinch, you can draw a polygon and then use flood fill, or draw a polygon on an intermediate surface, use flood fill, and then blit the surface.

One thing this can't do that you can do in GIMP is gradients.

@robertpfeiffer robertpfeiffer requested a review from a team as a code owner May 5, 2024 08:44
@robertpfeiffer robertpfeiffer changed the title WIP: draw flood fill flood fill May 5, 2024
This is no longer fun. Is my local install of clang-format bugged?
@yunline yunline added New API This pull request may need extra debate as it adds a new class or function to pygame draw pygame.draw labels May 8, 2024
src_c/draw.c Show resolved Hide resolved
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.

A couple of questions

src_c/draw.c Show resolved Hide resolved
src_c/draw.c Show resolved Hide resolved
src_c/draw.c Show resolved Hide resolved
src_c/draw.c Outdated Show resolved Hide resolved
robertpfeiffer and others added 3 commits May 21, 2024 09:52
… up, I will add ascii art to illustrate drawing algorithms. This commit message is longer than the diff!
@MyreMylar MyreMylar requested a review from a team as a code owner May 26, 2024 19:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
draw pygame.draw New API This pull request may need extra debate as it adds a new class or function to pygame
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants