Trouble with pyglet on Ubuntu?
Of course there are plenty of Pyweek games that segfault on me for no reason, but it seems to happen disproportionately with pyglet games. A few like that are Robot Underground, Ninja Tower, Bungie Chopper, and Intestinvaders. It's certainly not all pyglet games: I never recall having any trouble at all with any of Alex's games. I seem to remember this is a common problem every time for Ubuntu users, but I can't remember if anyone ever explained what the issue is. I wonder if it has something to do with sound, because for the pyglet games that run, I seem to have lots of issues with sound as well. Does anyone know?(log in to comment)
Comments
Avbin also could be a source of crashes. I vaguely remember it giving me some trouble, although I wouldn't swear it.
(gdb) r run_game.py
Starting program: /usr/bin/python run_game.py
[Thread debugging using libthread_db enabled]
[New Thread 0xb748fb70 (LWP 1357)]
Program received signal SIGSEGV, Segmentation fault.
0x02c291b5 in ?? () from /usr/lib/i686/cmov/libavcodec.so.52
For Bungie Chopper, something with fonts I guess:
(gdb) r run_game.py
Starting program: /usr/bin/python run_game.py
[Thread debugging using libthread_db enabled]
[New Thread 0xb76f5b70 (LWP 1747)]
Program received signal SIGSEGV, Segmentation fault.
0x0221d250 in FT_Request_Size () from /usr/lib/libfreetype.so.6
I suspect that AVBin is probably the culprit in the majority of cases.
AVBin is a thin wrapper about ffmpeg - did you compile it yourself? Perhaps there's some incompatibility that's been introduced in a recent (or old) ffmpeg release (I would not be surprised in the least - that's why avbin exists).
Perhaps Bungie Chopper uses a strange font? Can you check what version of freetype is installed?
I don't compile hardly anything myself. I pretty much just use Synaptic for installing everything. According to Synaptic, my libfreetype6 version is 2.3.11-1ubuntu2.1. My ffmpeg version is 4:0.5.1-1ubuntu1. And my libavbin0 version is 7-1build2.
I seem to remember there was an environment variable I could set that would disable sound on pyglet. Is that true? It would be a good workaround if I can't figure this out before the competition.
I believe the environment var would be:
PYGLET_AUDIO=silent
richard on 2010/07/31 01:31:
Are your video drivers as up-to-date as humanly possible?