[PD] [GEM-dev] gl stack underflow

IOhannes m zmölnig zmoelnig at iem.at
Fri Jan 1 21:07:30 CET 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Matteo Sisti Sette wrote:
> chris clepper escribió:
>> pix_snap is probably using texunit 0 which is the default for any
>> texturing call.  pix_snap actually uses a function called
>> glReadPixels(), and that might use texture units internally to grab
>> the frame and store it before read back to main memory. 
> 
> Uh, so I guess I should use texunits starting from 1 for
> [gemframebuffer] and [pix_texture]s?
> 
> I actually have 2 [pix_snap]s, not one.
> Will they both use texunit 0, or 0 and 1?
> Can I safely assume they won't use any higher texunit?
> 

i wouldn't assume anything here.
i haven't looked at the code, but i doubt that it mentions the used
texunit somewhere, so it is implicitely "assumed".

if glReadPixels() internally uses texture units for grabbing, then you
cannot really know anything about it.


finally, you can get the number of available texture units in your
system with [GEMglGetIntegerv GL_MAX_TEXTURE_UNITS]


fgmasdr
IOhannes


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAks+VgIACgkQkX2Xpv6ydvRtxQCgrYgsW9WTm2RCiBGaGvYUBKyb
G6wAoIZvo6DJjiobwqw9nMLp9J46tt1i
=0+2L
-----END PGP SIGNATURE-----




More information about the Pd-list mailing list