[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[pygame] Surface.set_clip()




Hi,

How should Surface.set_clip() work? I've been using it for ages to
constrain some painting of hexes to a square area, and it has worked fine.
Now I want to turn off clipping at some places. The solution I've been
using so far has been to set the rect to the full size of the surface, but
according to the docs:

	http://pygame.seul.org/docs/ref/Surface.html#set_clip

I should be able to clear the clipping rectangle:

"If no rectangle is passed, the clipping region is set to the entire
Surface area."

So, how do I pass the "no rectangle"? Empty won't work, None won't work,
() won't work either? Is there any performance penalty for having a clip
setto the full surface vs. having no clip at all?

The docs say:

	Surface.set_clip([rectstyle])) -> None

There's a ")" too much there. :)


-- 
               "Stercus, stercus, stercus, moriturus sum."
                                       -- Terry Pratchett, Interesting Times

____________________________________
pygame mailing list
pygame-users@seul.org
http://pygame.seul.org