385 int n,x1,y1,x2,y2,lastX,lastY,newX,newY,pathnum=0;
401 while(n < path->nvertices){
402 newX = path->
xy[n + n];
403 newY = path->
xy[n + n + 1];
406 if(left <= newX && right >= newX && bottom <= newY && top >= newY)
417 if(
MFBLineClip(&x1,&y1,&x2,&y2,left,bottom,right,top))
420 pbuf[pathnum].
xy[0] = x1;
421 pbuf[pathnum].
xy[1] = y1;
422 pbuf[pathnum].
xy[2] = x2;
423 pbuf[pathnum].
xy[3] = y2;
427 pbuf[pathnum].
xy[0] = newX;
428 pbuf[pathnum].
xy[1] = newY;
431 while(n < path->nvertices && pathnum < 5){
432 x1 = lastX = newX; y1 = lastY = newY;
433 x2 = newX = path->
xy[n + n]; y2 = newY = path->
xy[n + n + 1];
435 MFBLineClip(&x1,&y1,&x2,&y2,left,bottom,right,top);
437 if(left < lastX && right > lastX && bottom < lastY && top > lastY){
442 else if(left < newX && right > newX && bottom < newY && top > newY){
444 pbuf[pathnum].
xy[0] = x1; pbuf[pathnum].
xy[1] = y1;
445 pbuf[pathnum].
xy[2] = x2; pbuf[pathnum].
xy[3] = y2;
451 pbuf[n].nvertices /= 2;
#define MFBPOLYGONBUFSIZE
Bool MFBLineClip(int *pX1, int *pY1, int *pX2, int *pY2, int l, int b, int r, int t)
#define MFBSwapInt(f1, f2)