X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=hacks%2Fglx%2Fcircuit.c;h=123bc7e63e00ef62a78af35ed539b3f545e7b1eb;hb=de460e831dc8578acfa8b72251ab9346c99c1f96;hp=9e8f2dcf0b6cf8515e8e286da9fcadf675579aa9;hpb=49f5b54f312fe4ac2e9bc47581a72451bd0e8439;p=xscreensaver diff --git a/hacks/glx/circuit.c b/hacks/glx/circuit.c index 9e8f2dcf..123bc7e6 100644 --- a/hacks/glx/circuit.c +++ b/hacks/glx/circuit.c @@ -104,7 +104,7 @@ ModStruct circuit_description = #endif -#define MAX_COMPONENTS 30 +#define MAX_COMPONENTS 400 #define MOVE_MULT 0.02 static float f_rand(void) @@ -2155,6 +2155,9 @@ Circuit *ci; ci->grid_col2[1] = 0.125; ci->grid_col2[2] = 0.05; + if (maxparts >= MAX_COMPONENTS) + maxparts = MAX_COMPONENTS-1; + if ((ci->glx_context = init_GL(mi)) != NULL) { reshape_circuit(mi, MI_WIDTH(mi), MI_HEIGHT(mi)); } else {