[PyOpenGL-Devel] [ pyopengl-Bugs-3441875 ] Unable to send null pointer (or zero) to glTexSubImage()
Brought to you by:
mcfletch
From: SourceForge.net <no...@so...> - 2011-11-24 20:27:52
|
Bugs item #3441875, was opened at 2011-11-24 12:27 Message generated for change (Tracker Item Submitted) made by fizzgig You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105988&aid=3441875&group_id=5988 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: GL Group: v3.0.0 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Marcus Lindblom (fizzgig) Assigned to: Mike C. Fletcher (mcfletch) Summary: Unable to send null pointer (or zero) to glTexSubImage() Initial Comment: When updating a texture from a PBO, the value for pixels is an offset into the PBO. This cannot be done using the pythonic API in PyOpenGL. (it fails to convert None to an array, and a zero-int is treated as a small array, yielding an gl error) The workaround is to use the raw api thusly: raw.GL.glTexSubImage2D(GL.GL_TEXTURE_2D, 0, 0, 0, width, height, GL.GL_BGR, GL.GL_UNSIGNED_BYTE, POINTER(ctypes.c_ubyte)()) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105988&aid=3441875&group_id=5988 |