mansrz / pymt

Automatically exported from code.google.com/p/pymt
0 stars 0 forks source link

PyMT examples crash after duration or clicking #63

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
[INFO   ] Fbo will use hardware Framebuffer
[INFO   ] listening for Tuio on 127.0.0.1:3333
[INFO   ] Leaving application in progress...
Traceback (most recent call last):
 File "flickthepic.py", line 114, in <module>
   runTouchApp()
 File "/usr/lib/python2.5/site-packages/pymt/mtpyglet.py", line 477,
in runTouchApp
   pymt_evloop.run()
 File "/usr/lib/python2.5/site-packages/pyglet/app/xlib.py", line 94, in run
   sleep_time = self.idle()
 File "/usr/lib/python2.5/site-packages/pymt/mtpyglet.py", line 357, in idle
   frame_dt = pyglet.clock.tick()
 File "/usr/lib/python2.5/site-packages/pyglet/clock.py", line 698, in tick
   return _default.tick(poll)
 File "/usr/lib/python2.5/site-packages/pyglet/clock.py", line 317, in tick
   item.next_ts = self._get_soft_next_ts(ts, item.interval)
 File "/usr/lib/python2.5/site-packages/pyglet/clock.py", line 585,
in _get_soft_next_ts
   if not taken(next_ts, interval / 4):
 File "/usr/lib/python2.5/site-packages/pyglet/clock.py", line 563, in taken
   if abs(item.next_ts - ts) <= e:
TypeError: unsupported operand type(s) for -: 'NoneType' and 'float'

This occurs with both Linux and Windows with:
PyMT 0.2
Pyglet 1.1.3
Numpy 1.3.0
Python 2.5 and 2.6

Example taken from "Flickthepic", but occurs with most tested apps.

Original issue reported on code.google.com by mach...@gmail.com on 9 Apr 2009 at 2:34

GoogleCodeExporter commented 9 years ago
Bug report in pyglet: http://code.google.com/p/pyglet/issues/detail?id=407

Original comment by txprog on 9 Apr 2009 at 3:37

GoogleCodeExporter commented 9 years ago
Not a viable repair, but a quick fix for continued use while testing, a simple 
try/catch can be put around the "if 
abs()" statement in order to catch the TypeError.

Original comment by mach...@gmail.com on 27 Apr 2009 at 6:46

GoogleCodeExporter commented 9 years ago
You can do that in your own installation of pyglet :)
We cannot release a special-pymt version of pyglet anyway :/

Original comment by txprog on 27 Apr 2009 at 6:55

GoogleCodeExporter commented 9 years ago
Sorry for any confusion!  That's all I meant it as; for user testing purposes.  

Original comment by mach...@gmail.com on 27 Apr 2009 at 8:22

GoogleCodeExporter commented 9 years ago

Original comment by txprog on 7 May 2009 at 12:34

GoogleCodeExporter commented 9 years ago

Original comment by txprog on 7 May 2009 at 12:36

GoogleCodeExporter commented 9 years ago

Original comment by txprog on 29 Aug 2009 at 4:14

GoogleCodeExporter commented 9 years ago
With the switch to pyopengl, clock have been rewrited. No more bug on this.

Original comment by txprog on 30 Oct 2009 at 12:35

GoogleCodeExporter commented 9 years ago

Original comment by txprog on 30 Oct 2009 at 12:35