title: How to implement flood fill in a Pygame surface
body: <p>I would like to know a good way of filling part of a Pygame surface.
  The best example of what I want is the way the paint bucket works in MS Paint.</p>
  
  <p>For example, if there were a circle drawn in black on a white surface, I want to fill the white inside the circle(or whatever the shape might be).</p>
  
  <p>To give you an idea of what I'm working on, I'm making a pixel art tool and I'm working on a feature similar to the bucket from MS Paint. (Watch This: <a href="https://imgur.com/a/ogtPV" rel="nofollow noreferrer">http://imgur.com/a/ogtPV</a>)</p>
  
  <p>I've tried using <code>Surface.get_at()</code> and <code>Surface.set_at()</code> a bunch to fill, but once you get around 100x100 pixels of an area to fill, it lags too much.</p>
  
  <p>I'm also open to any other methods of doing it that don't lag.</p>