[Pyopengl-users] [ pyopengl-Bugs-459892 ] glutMouseFunc handler button arg
Brought to you by:
mcfletch
From: <no...@so...> - 2001-09-09 02:19:27
|
Bugs item #459892, was opened at 2001-09-08 17:59 You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=105988&aid=459892&group_id=5988 Category: GLUT Group: v2.0 >Status: Closed >Resolution: Invalid Priority: 5 Submitted By: Richard Jones (richard) Assigned to: Tarn Weisner Burton (twburton) Summary: glutMouseFunc handler button arg Initial Comment: A handler defined on a modified version of the "simple" demo: def on_mouse(self, button, state, x, y): print (button, state, x, y) when used via glutMouseFunc(self.on_mouse) the button arg is always 0, the others are what is expected. That is, I get output like: (0, 0, 198, 203) (0, 1, 114, 262) (0, 0, 137, 43) (0, 1, 207, 105) (0, 0, 168, 30) (0, 1, 162, 240) (0, 0, 263, 220) (0, 1, 87, 130) (0, 0, 149, 230) (0, 1, 157, 88) I'm new to GL, so my apologies if I'm missing an additional initialisation or handler step. ---------------------------------------------------------------------- >Comment By: Richard Jones (richard) Date: 2001-09-08 19:19 Message: Logged In: YES user_id=6405 *sigh* Sorry, my mistake. ---------------------------------------------------------------------- Comment By: Tarn Weisner Burton (twburton) Date: 2001-09-08 19:10 Message: Logged In: YES user_id=21784 Tested on Win32 and Linux (RedHat). Works fine. The C code used to interface to glutMouseFunc and the callback is trivial, i.e. just passes the arguments straight through. Try this C program so we can determine if its' a PyOpenGL problem. This will probably work to compile gcc -o test test.c -lglut -lGL -lGLU ---------------------------------------------------------------------- Comment By: Richard Jones (richard) Date: 2001-09-08 18:44 Message: Logged In: YES user_id=6405 That test script didn't work - PyOpenGL_info.html attached. ---------------------------------------------------------------------- Comment By: Tarn Weisner Burton (twburton) Date: 2001-09-08 18:11 Message: Logged In: YES user_id=21784 Try out this test script. Works on my system. If it doesn't work on your system upload PyOpenGL_info.html produced by OpenGL/scripts/info.py ---------------------------------------------------------------------- You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=105988&aid=459892&group_id=5988 |