jmichelsen / py-lepton

Automatically exported from code.google.com/p/py-lepton
MIT License
0 stars 0 forks source link

successful built on Debian, GL error on eee pc #3

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Dear Casey,
having read about lepton in the Python Magazine I was very eager to try it
out myself.
At first the compilation did not run on my Debian Testing box, I always got
the error that glew.h could not be found until I realized that I had to
rename the folder <gl> provided under <glew> in the installation tarball
into <GL>, then it worked. I successfully built lepton on my terra notebook
(nvidia graphics) and on an eee pc 901. On the notebook all examples run
fine and I am completely enthusiastic about the spectacular effects. You
have really created a great and very entertaining tool, thanks a lot. I
can't wait to show it to my kids. On the eee pc however, so far only the
flyby example runs (very smoothly). When I run other examples, I get the
following traceback:
Traceback (most recent call last):
  File "./fire.py", line 78, in <module>
    pyglet.app.run()
  File "/usr/lib/pymodules/python2.5/pyglet/app/__init__.py", line 264, in run
    EventLoop().run()
  File "/usr/lib/pymodules/python2.5/pyglet/app/xlib.py", line 94, in run
    sleep_time = self.idle()
  File "/usr/lib/pymodules/python2.5/pyglet/app/__init__.py", line 193, in idle
    window.dispatch_event('on_draw')
  File "/usr/lib/pymodules/python2.5/pyglet/window/__init__.py", line 1217,
in dispatch_event
    EventDispatcher.dispatch_event(self, *args)
  File "/usr/lib/pymodules/python2.5/pyglet/event.py", line 340, in
dispatch_event
    if handler(*args):
  File "./fire.py", line 74, in on_draw
    default_system.draw()
  File "/home/user/progs/lepton/lepton/system.py", line 94, in draw
    group.draw()
RuntimeError: GL error 1280

Do you have any idea, what the cause for this could be ? Also, when I start
the examples I always get this warning:
do_wait: drmWaitVBlank returned -1, IRQs don't seem to be working correctly.
Try adjusting the vblank_mode configuration parameter.

But this  does not seem to influence the execution of the scripts, since it
also occurs in the working flyby example.

Many thanks again and maybe you have an idea how I could circumvent the GL
error.
Kind regards,
 Axel

Original issue reported on code.google.com by chemis...@gmx.de on 19 Aug 2009 at 3:47

GoogleCodeExporter commented 9 years ago
That's strange about the directory name, when I unpack the tarball or zip file, 
glew/include/GL is there as 
expected. Can you tell me the exact sequence of commands you used to reproduce 
this? Any chance there 
was something funky about the filesystem you were using (i.e., samba, or other 
fs with different case rules)?

As for the error, 1280 is an invalid enum error, which means the example is 
trying to use an OpenGL feature 
that is not supported on that hardware. Netbooks typically have very 
lightweight (literally and figuratively) 
graphics cards. I have a hunch that it does not support GL_POINT_SPRITE, which 
is used when texturing 
points. This feature requires OpenGL 1.5 which is probably not supported on 
your hardware. The flyby 
example does not use points. Ideally the point renderer would fall back to 
using textured quads when point 
sprites are not available. I will definitely consider doing that.

To learn for sure if this is the problem you could use gdb to get a backtrace 
like so:

% gdb python
(gdb) run -m lepton.examples.fire
(gdb) c
...Should see error here...
(gdb) bt

Then paste the backtrace here.

I'm not sure what the origin of the drmWaitVBlank warning is, probably 
something emitted when pyglet 
initializes the OpenGL context. This probably means that vsync isn't 
functional, which might introduce flicker 
or tearing artifacts. But shouldn't otherwise hurt anything.

Thanks for trying lepton, and thanks for the report!

Original comment by casey.du...@gmail.com on 19 Aug 2009 at 5:34

GoogleCodeExporter commented 9 years ago

Original comment by casey.du...@gmail.com on 19 Aug 2009 at 5:35

GoogleCodeExporter commented 9 years ago
Hi Casey,
thanks a lot for your quick answer and your help.
Here is the output of gdb:
$ gdb python
GNU gdb 6.8-debian
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu"...
(no debugging symbols found)
(gdb) run -m examples.fire
Starting program: /usr/bin/python -m examples.fire
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
[Thread debugging using libthread_db enabled]
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
[New Thread 0xb7e768d0 (LWP 5413)]
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
---Type <return> to continue, or q <return> to quit---
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
do_wait: drmWaitVBlank returned -1, IRQs don't seem to be working correctly.
Try adjusting the vblank_mode configuration parameter.
Traceback (most recent call last):
  File "/usr/lib/python2.5/runpy.py", line 95, in run_module
    filename, loader, alter_sys)
  File "/usr/lib/python2.5/runpy.py", line 52, in _run_module_code
    mod_name, mod_fname, mod_loader)
  File "/usr/lib/python2.5/runpy.py", line 32, in _run_code
    exec code in run_globals
  File "/media/SD/progs/lepton/examples/fire.py", line 78, in <module>
    pyglet.app.run()
  File "/usr/lib/pymodules/python2.5/pyglet/app/__init__.py", line 264, in run
    EventLoop().run()
  File "/usr/lib/pymodules/python2.5/pyglet/app/xlib.py", line 94, in run
    sleep_time = self.idle()
  File "/usr/lib/pymodules/python2.5/pyglet/app/__init__.py", line 193, in idle
    window.dispatch_event('on_draw')
  File "/usr/lib/pymodules/python2.5/pyglet/window/__init__.py", line 1217, in
dispatch_event
    EventDispatcher.dispatch_event(self, *args)
  File "/usr/lib/pymodules/python2.5/pyglet/event.py", line 340, in dispatch_event
    if handler(*args):
  File "/media/SD/progs/lepton/examples/fire.py", line 74, in on_draw
    default_system.draw()
  File "/home/apl/progs/lepton/lepton/system.py", line 94, in draw
    group.draw()
RuntimeError: GL error 1280

Program exited with code 0377.
(gdb) q

Concerning the <GL> folder: I re-downloaded the tarball and indeed the folder is
uppercase in it. I now remember that I downloaded the tarball the first time 
with a
Windows computer and unpacked it with Total Commander to a fat32 usb stick. The 
error
here definitely occurred on my side.
Thanks again for your help.
 Axel

Original comment by chemis...@gmx.de on 19 Aug 2009 at 7:45