Signature
glutMotionFunc(
function
)
Specify handler for GLUT 'Motion' events def handler( (int) x, (int) y ): return None
glutPassiveMotionFunc(
function
)
Specify handler for GLUT 'PassiveMotion' events def handler( (int) x, (int) y ): return None
Parameters
Variables | Description |
---|---|
func |
The new motion or passive motion callback function.
|
Description
glutMotionFunc
and
glutPassiveMotionFunc
set the motion and passive motion
callback respectively for the current window. The motion callback for a window is called when the mouse moves within
the window while one or more mouse buttons are pressed. The passive motion callback for a window is called when the
mouse moves within the window while no mouse buttons are pressed.
Passing
NULL
to
glutMotionFunc
or
glutPassiveMotionFunc
disables the generation of the mouse or passive motion callback respectively.
See Also
glutMouseFunc glutSpaceballMotionFunc glutTabletMotionFuncSample Code References
The following code samples have been found which appear to reference the functions described here. Take care that the code may be old, broken or not even use PyOpenGL.
glutMotionFunc
glutPassiveMotionFunc