Ejemplo n.º 1
0
static void randomBlots (struct nerverotstate *st)
{
    int which = RAND_FLOAT_01 * 11;
    freeBlots (st);
    setupBlots(st,which);
    st->cur_num=which;
}    
Ejemplo n.º 2
0
static void
nerverot_free (Display *dpy, Window window, void *closure)
{
  struct state *st = (struct state *) closure;
  freeBlots (st);
  free (st);
}
Ejemplo n.º 3
0
/* set up the initial arrays of blots */
static void setupBlots (struct state *st)
{
    int which = RAND_FLOAT_01 * 11;

    freeBlots (st);

    switch (which)
    {
	case 0:
	    setupBlotsCube (st);
	    break;
	case 1:
	    setupBlotsSphere (st);
	    break;
	case 2:
	    setupBlotsCylinder (st);
	    break;
	case 3:
	    setupBlotsSquiggle (st);
	    break;
	case 4:
	    setupBlotsCubeCorners (st);
	    break;
	case 5:
	    setupBlotsTetrahedron (st);
	    break;
	case 6:
	    setupBlotsSheet (st);
	    break;
	case 7:
	    setupBlotsSwirlyCone (st);
	    break;
	case 8:
	case 9:
	case 10:
	    setupBlotsDuo (st);
	    break;
    }
}
Ejemplo n.º 4
0
static void commandBlots (struct nerverotstate *st)
{
    freeBlots (st);
    setupBlots(st, st->please_num);
    st->cur_num=st->please_num;
}
Ejemplo n.º 5
0
static void
nerverot_free (struct nerverotstate *st)
{
  freeBlots (st);
  free (st);
}