[squeak-dev] Still pounding head against wall over glReadPixels => external buffer

Lawson English lenglish5 at cox.net
Wed Feb 10 13:05:09 UTC 2010


Hey all...

I'm still having problems with my external shared memory thingie. I can 
evoke the unix shm* calls and obtain a reference to a shared memory 
buffer and attach it to squeak's heap. I can write into it and read 
back. I can even attach the same shared memory to two different 
instances of squeak and write to the buffer in one and read it with the 
other. What I still cannot figure out is how to take that external 
buffer and direct the OpenGL>>glReadPixels call to it so that I can draw 
using squeak and have it become a bitmap for a different application.

I've tried to figure out how forms and bitmaps work. I've looked over a 
reasonably large bit of source code and read various bits of the wiki 
and example code and what not. I still can't get glReadPixels to change 
the contents of my shared buffer, however. OTOH, I've become very good 
at getting Squeak to crash, sometimes silently and sometimes with the 
typical Mac OS X crash report dialog.  Anyone know how to simply take an 
arbitrary raw pointer and successfully direct glReadPixels to it?  I've 
looked at the source for the Tweak-OpenGL code, but can't wrap my brain 
around how it is [correctly] using a bitmap as the target buffer for 
glReadPixels... Or rather, how to properly create a bitmap from the raw 
pointer so that I can use the example code as a starting point.

http://www.croquetconsortium.org/index.php/Procedural_Texturing


thanks in advance.



Lawson











More information about the Squeak-dev mailing list