All,

This might strictly speaking be a GL question only, and if so I can
easily move it to a different forum. However since I'm implementing in
pyglet I thought I should at least try posting here.

So I'm trying to do color picking using pyglet and sprites, but
running into a problem reading color values from negative positions
within the back buffer. For positive x AND y coordinates, reading
pixel colors returns the values I expect. However if x OR y are
negative, the pixel colors that get read are always 0/black. Is the
back buffer able to contain coordinates less than 0, and if so how can
I read their color values?

For an example/demonstration of the problem, I created the following
git repository:

https://[email protected]/greenmoss/pick_test.git

On the "master" branch, glReadPixels always works, because 0,0 is the
lowest coordinate. However switch to branch "negative_offset" and run
the code again, and see how glReadPixels fails to detect anything with
a negative coordinate.

-- 
You received this message because you are subscribed to the Google Groups 
"pyglet-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/pyglet-users?hl=en.

Reply via email to