X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=hacks%2Fglx%2Fcircuit.c;h=da3be7709efc75e882a47dec68a44f35a51b5d9e;hb=5f9c47ca98dd43d8f59b7c27d3fde6edfde4fe21;hp=b7a0c256c9734b3c51a1e9bb36b238aa83324ab1;hpb=c1b9b55ad8d59dc05ef55e316aebf5863e7dfa56;p=xscreensaver diff --git a/hacks/glx/circuit.c b/hacks/glx/circuit.c index b7a0c256..da3be770 100644 --- a/hacks/glx/circuit.c +++ b/hacks/glx/circuit.c @@ -423,7 +423,6 @@ static int createCylinder (Circuit *ci, int a; /* current angle around cylinder */ int angle, norm; float z1, y1, z2, y2,ex; - int step; int nsegs; glPushMatrix(); @@ -432,7 +431,6 @@ static int createCylinder (Circuit *ci, if (nsegs % 2) nsegs += 1; angle = (half) ? (180 - 90/nsegs) : 374; - step = angle/nsegs; z1 = radius; y1 = 0; glBegin(GL_QUADS); for (a = 0 ; a <= angle ; a+= angle/nsegs) { @@ -1859,7 +1857,7 @@ static void makebandlist(Circuit *ci) GLfloat shine = 40; for (i = 0 ; i < 12 ; i++) { - ci->band_list[i] = glGenLists(i); + ci->band_list[i] = glGenLists(1); glNewList(ci->band_list[i], GL_COMPILE); col[0] = colorcodes[i][0]; col[1] = colorcodes[i][1]; @@ -1880,7 +1878,6 @@ static int bandedCylinder(Circuit *ci, { int polys = 0; int n; /* band number */ - int p = 0; /* prev number + 1; */ GLfloat col[] = {0,0,0,0}; col[0] = r; col[1] = g; col[2] = bl; @@ -1893,7 +1890,6 @@ static int bandedCylinder(Circuit *ci, glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col); polys += createCylinder(ci, b[n]->len*l, radius*1.05, 0, 0); /* band */ glPopMatrix(); - p = n+1; } return polys; } @@ -2235,7 +2231,6 @@ Circuit *ci; } if (uselight == 0) ci->light = 1; - glClearColor(0.0,0.0,0.0,0.0); glShadeModel(GL_SMOOTH); glPolygonMode(GL_FRONT_AND_BACK,GL_FILL); glEnable(GL_DEPTH_TEST);