comparison src/redraw_man.c @ 148:fce696643b1e

-
author Thinker K.F. Li <thinker@branda.to>
date Thu, 25 Sep 2008 10:14:19 +0800
parents 995ee8fd5f1a
children 0824f4804ee0
comparison
equal deleted inserted replaced
147:995ee8fd5f1a 148:fce696643b1e
582 SWAP(geo->cur_area, geo->last_area, area_t *); 582 SWAP(geo->cur_area, geo->last_area, area_t *);
583 clean_shape(geo->shape); 583 clean_shape(geo->shape);
584 cnt++; 584 cnt++;
585 } 585 }
586 586
587 /* Compute area of the coord. */
588 if(max_poses < (cnt * 2)) { 587 if(max_poses < (cnt * 2)) {
589 free(poses); 588 free(poses);
590 max_poses = cnt * 2; 589 max_poses = cnt * 2;
591 poses = (co_aix (*)[2])malloc(sizeof(co_aix [2]) * max_poses); 590 poses = (co_aix (*)[2])malloc(sizeof(co_aix [2]) * max_poses);
592 if(poses == NULL) 591 if(poses == NULL)
593 return ERR; 592 return ERR;
594 } 593 }
595 594
595 /* Compute area of the coord. */
596 pos_cnt = 0; 596 pos_cnt = 0;
597 FORMEMBERS(coord, geo) { 597 FORMEMBERS(coord, geo) {
598 area_to_positions(geo->cur_area, poses + pos_cnt); 598 area_to_positions(geo->cur_area, poses + pos_cnt);
599 pos_cnt += 2; 599 pos_cnt += 2;
600 } 600 }