- SDL_Surface *screen;
- SDL_Surface *image;
- SDL_Event event;
- ReadPoints ("pro-gnu");
- SDL_Init (SDL_INIT_VIDEO | SDL_INIT_TIMER);
- screen = SDL_SetVideoMode (800, 600, 32, SDL_HWSURFACE | SDL_DOUBLEBUF);
- image = IMG_Load ("/home/cascardo/fotos/debconf.jpg");
- SDL_AddTimer (0, ShowNext, NULL);
- while (SDL_WaitEvent (&event))
- {
- if (event.type == SDL_KEYDOWN)
- break;
- else if (event.type == SDL_USEREVENT)
- ShowPoint (screen, image, GetNextPoint ());
- }
- SDL_FreeSurface (image);
- SDL_Quit ();
- free (points);
- return 0;
+ Point *point;
+ double scale;
+ int i;
+ for (i = 0; i < points->len; i++)
+ {
+ point = &(g_array_index (points, Point, i));
+ scale = g_array_index (scales, double, (i % scales->len));
+ point->rx = scale;
+ point->ry = scale;
+ point->x *= point->rx;
+ point->y *= point->ry;
+ }