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

Lawson English lenglish5 at cox.net
Fri Feb 12 06:33:11 UTC 2010

Lawson English wrote:
> Josh Gargus wrote:
>> Very cool, nice work!
>> If it turns out that you need more CPU cycles, you might try using 
>> PBOs to asynchronously read the pixels... when you call 
>> glReadPixels(), the function does not return until the pixels have 
>> been completely read, and while you're waiting for the pixels to 
>> cross the PCI-E bus, Squeak isn't doing any processing.  If you're 
>> reading back 30fps at 5ms per frame (according to your measurements 
>> below), you're sitting idle about 15% of the time.
>> Search for "Asynchronous glReadPixels:" in the PBO extension spec 
>> (http://www.opengl.org/registry/specs/ARB/pixel_buffer_object.txt).  
>> Google will turn up many more tutorials.
>> It probably won't be your top priority right now, but I wanted to 
>> ensure that you're aware of the option.
>> Cheers,
>> Josh
> Thanks. I was aware of PBOs and the like but didn't want to get into 
> them until I got something simple working. Am I misunderstanding 
> 1000x1000x1000x4/6?
> I get more like 160fps x 1megapixel raw blitting speed which sounds 
> fast until one realizes that not much else is going on period.

doh 160 MB/sec ~ 30fps, like you said. LOL

More information about the Squeak-dev mailing list