aboutsummaryrefslogtreecommitdiffstats
path: root/x11/xscreensaver
diff options
context:
space:
mode:
authordougb <dougb@FreeBSD.org>2005-10-29 14:26:23 +0800
committerdougb <dougb@FreeBSD.org>2005-10-29 14:26:23 +0800
commit8572df392674d85774c273130814c9074c0a2b18 (patch)
tree345e1612a51f01bf28a25e824603f804de6af03c /x11/xscreensaver
parenteeeadcf0a69dbae958280bdd7cbdf141007f2ba0 (diff)
downloadfreebsd-ports-gnome-8572df392674d85774c273130814c9074c0a2b18.tar.gz
freebsd-ports-gnome-8572df392674d85774c273130814c9074c0a2b18.tar.zst
freebsd-ports-gnome-8572df392674d85774c273130814c9074c0a2b18.zip
Re-add this patch that is needed for 4.22. I am seeing weird behavior
with 4.23, and therefore plan to delay the upgrade till I'm sure it's ok.
Diffstat (limited to 'x11/xscreensaver')
-rw-r--r--x11/xscreensaver/files/patch-hacks_glx_antmaze.c57
1 files changed, 57 insertions, 0 deletions
diff --git a/x11/xscreensaver/files/patch-hacks_glx_antmaze.c b/x11/xscreensaver/files/patch-hacks_glx_antmaze.c
new file mode 100644
index 000000000000..dc67f38d966f
--- /dev/null
+++ b/x11/xscreensaver/files/patch-hacks_glx_antmaze.c
@@ -0,0 +1,57 @@
+--- hacks/glx/antmaze.c.orig Sun Jun 26 16:22:35 2005
++++ hacks/glx/antmaze.c Sun Jun 26 16:26:02 2005
+@@ -975,6 +975,7 @@ void update_ants(void) {
+
+ /* fade out */
+ if(fadeoutspeed < -0.00001) {
++ GLfloat df[4];
+
+ if(fadeout <= 0.0) {
+ /* switch boards: rebuild old board, increment current */
+@@ -985,20 +986,27 @@ void update_ants(void) {
+
+ fadeout += fadeoutspeed;
+
+- GLfloat df[4] = {0.8*fadeout, 0.8*fadeout, 0.8*fadeout, 1.0};
++ df[0] = 0.8*fadeout;
++ df[1] = 0.8*fadeout;
++ df[2] = 0.8*fadeout;
++ df[3] = 1.0;
+ glLightfv(GL_LIGHT0, GL_DIFFUSE, df);
+ glLightfv(GL_LIGHT1, GL_DIFFUSE, df);
+ }
+
+ /* fade in */
+ if(fadeoutspeed > 0.0001) {
++ GLfloat df[4];
+ fadeout += fadeoutspeed;
+ if(fadeout >= 1.0) {
+ fadeout = 1.0;
+ fadeoutspeed = 0.0;
+ entroducing = 12;
+ }
+- GLfloat df[4] = {0.8*fadeout, 0.8*fadeout, 0.8*fadeout, 1.0};
++ df[0] = 0.8*fadeout;
++ df[1] = 0.8*fadeout;
++ df[2] = 0.8*fadeout;
++ df[3] = 1.0;
+ glLightfv(GL_LIGHT0, GL_DIFFUSE, df);
+ glLightfv(GL_LIGHT1, GL_DIFFUSE, df);
+ }
+@@ -1160,6 +1168,7 @@ void update_ants(void) {
+ double dx = antpath[i][part[i]][0] - antposition[i][0];
+ double dz = - antpath[i][part[i]][1] + antposition[i][1];
+ double theta, ideal;
++ double dt;
+
+ if(dz > EPSILON)
+ theta = atan(dz/dx);
+@@ -1171,7 +1180,7 @@ void update_ants(void) {
+ ideal += Pi;
+
+ /* compute correction */
+- double dt = sign(ideal) * min(fabs(ideal), PI/90.0);
++ dt = sign(ideal) * min(fabs(ideal), PI/90.0);
+ antdirection[i] += dt;
+ if(antdirection[i] > 2.0*PI)
+ antdirection[i] = 0.0;