Hi all,

I've run across an odd segfault when using pyglet.text.Label objects.

Basically, initializing or setting the text attribute of a Label can
cause an eventual call to glTexImage2D as the glyph textures are
uploaded to the graphic card. Under specific circumstances, this seems
to cause a segfault on my machine (OS X 10.5.5; pyglet 1.1.1, python
2.5.2). If the glyphs are loaded *before* I upload any textures myself
(using just the GL calls, not the pyglet classes), things seem fine.
However, if the glyphs are loaded *after* I upload a texture, there
*may* be an error, depending on the size of the texture data I upload.
If I send a large texture before the label object calls glTexImage2D,
that segfaults. If I send less than 2**16 bytes (or so -- I haven't
figured it out exactly) of texture, the crash does not happen. Once
the glyphs are loaded, I can send textures as large as I want with no
trouble.

This seems to point to the use of some uninitialized resources by the
Label object (or its various components), or perhaps forgetting to
bind the correct texture ID before sending the data or something. I
tried and failed to trace this through the pyglet code, unfortunately.
Also unfortunately, I don't have time this week to create a reduced
test case. I hope that this description might be sufficient to get
someone thinking of where such an error might lurk, but if this is
insufficient, I'll try to create a test case as soon as I get a
chance.

Thanks, and sorry to not be more helpful,

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