Thanks Tristam. I've started to play around with what you suggested
and I'm hopeful though I haven't gotten too far into it.

I suppose I better question than my original may be: if I'm
exclusively using 2D graphics, and if my intent is to have a lot of
pixel-level manipulation, is OpenGL even the right tool? I realize
that OpenGL can handle what I'm after, but is the purely-2D usage of
OpenGL unorthodox, or will it cause problems in the future should the
project grow?

Best regards,
Dex

On Mar 30, 2:51 pm, Tristam MacDonald <[email protected]> wrote:
> On Tue, Mar 30, 2010 at 4:09 AM, Dexter Collins <[email protected]> wrote:
> > But it gives me the error: ctypes.ArgumentError: argument 9: <type
> > 'exceptions.TypeError'>: wrong type
>
> > Obviously the last argument I'm passing to glTexSubImage2D is
> > incorrect. How do I correctly tell the glTexSubImage2D method that I
> > want the specified pixel to be red? And how do I get the original
> > color of that pixel in the first place for the purpose of making it
> > slightly more transparent?
>
> You need to pass a ctypes pointer in, probably made with a ctypes string 
> buffer.
>
> However, keep in mind that this is going to be terrible from a
> performance standpoint - OpenGL is not designed for pixel access in
> this manner. A better approach would be to use render-to-texture with
> an FBO, and render points as needed to the texture.
>
> --
> Tristam MacDonaldhttp://swiftcoder.wordpress.com/

-- 
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