set_colorkey

Code junkies hangout here

Moderators: ChrisThornett, LXF moderators

set_colorkey

Postby graemev » Sun May 16, 2010 5:09 pm

I thought the pyinvaders game (LXF110) would make a good intro from my son (and if he takes the bait ... he won't need to wait a month to carry on)

... mostly fine but:
self.bitmap.set_colorkey(....) did not seem to work (always got a black border ... wracked my brains ...seems familiar
...finally (:-)) resorted to this forum (18+ months after the article was published ... yea right!) ...no joy , so started to write this up ... amazing how putting it down in black and white throws it in to stark contrast (;-)) ... nobody else was having the problems .. I've got custom sprites (my son is more motivated by the images) ...so I go back to originals ... all works ... after a series of binary chops the answer is:

"the BMP need to be 16 bit ... gimp default of 32 bit does not work"

..so thanks to the ability to download original article and grep it ....I see no mention of 16bits ...so it's worth posting.

..so thanks for that , sorted , fixed my problem, couldn't do it without you :-)
--

Graeme - $(fortune)
User avatar
graemev
 
Posts: 14
Joined: Sun Mar 09, 2008 5:17 pm
Location: Berkshire, England

Return to Programming

Who is online

Users browsing this forum: No registered users and 1 guest

cron