Archived

This topic is now archived and is closed to further replies.

shalrath

Reading Pixel Colours

Recommended Posts

shalrath    128
For my 2D tile based game I have two images involved in a collision test (there is also a background drawn), I detect that they are over one another, and want to test each at a per-pixel level, to see if they both have a non-transparent colour anywhere in my collision space, is there any way to do this real-time with open GL calls?

Share this post


Link to post
Share on other sites
zedzeek    528
well what we used to do years back for 2d stuff is store the image data some where as 1''s and 0''s + just do an AND operation between the two.

Share this post


Link to post
Share on other sites