There is an average_color function in the transform module in Pygame SVN.
On Fri, Dec 26, 2008 at 9:44 PM, yanom @linuxmail.org <[email protected]> wrote: > if you wanted to get the overall average color of a sprite, you would have to > use a for loop to go through all the pixels and count the pixels of each > color or something > ----- Original Message ----- >> From: "Aaron Maupin" <[email protected]> >> To: [email protected] >> Subject: Re: [pygame] get coluor of a sprite >> Date: Sat, 27 Dec 2008 05:22:12 +0900 >> >> >> Gonzalo Castro wrote: >> > What function may I use to get the colour of a sprite? >> >> Very easy. Use Surface.get_at((x, y)) where x and y equals the >> pixel in the surface you want to check the color of. >> >> http://www.pygame.org/docs/ref/surface.html#Surface.get_at > >> > > > = > Military Relocation Service > Jan and Mary Team get you moving. Professional Real Estate Services. > http://a8-asy.a8ww.net/a8-ads/adftrclick?redirectid=e12ad774014ddc03c02fb38da65ab85a > > > -- > Powered by Outblaze >
