+ if (!do_blur || MI_IS_WIREFRAME(mi)) {
+ glTranslatef(ball.x += mo.x,
+ ball.y += mo.y,
+ ball.z += mo.z);
+
+ glScalef(2,2,2);
+ glCallList(ballList);
+
+ } else {
+
+# define blur_detail 24.0
+ float ball_alpha = 1 / blur_detail;
+
+ glBlendFunc(GL_SRC_ALPHA,GL_ONE);
+ glTranslatef(ball.x, ball.y, ball.z);
+
+ for (i = 0; i < blur_detail; ++i) {
+ glTranslatef(mo.x / blur_detail,
+ mo.y / blur_detail,
+ mo.z / blur_detail);
+
+ /* comment the following line for quick but boring linear blur */
+ ball_alpha = sin((M_PI / blur_detail) * i) / blur_detail;
+
+ glColor4f(1, 1, 1, ball_alpha);
+
+ glScalef(2, 2, 2);
+ glCallList(ballList);
+ glScalef(.5, .5, .5);
+ }
+ i = 0;
+
+ ball.x += mo.x;
+ ball.y += mo.y;
+ ball.z += mo.z;
+ }
+