deb4998ba50060c48cce222fd18a8eed053918d7vboxsync/*
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * Copyright IBM Corporation 1987,1988,1989
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync *
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * All Rights Reserved
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync *
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * Permission to use, copy, modify, and distribute this software and its
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * documentation for any purpose and without fee is hereby granted,
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * provided that the above copyright notice appear in all copies and that
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * both that copyright notice and this permission notice appear in
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * supporting documentation, and that the name of IBM not be
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * used in advertising or publicity pertaining to distribution of the
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * software without specific, written prior permission.
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync *
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * IBM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * IBM BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync * SOFTWARE.
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync *
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync*/
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync/* $XConsortium: ppcSpMcro.h /main/3 1996/02/21 17:58:36 kaleb $ */
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync/* This screwy macro is used in all the spans routines and you find
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync it all over the place, so it is a macro just to tidy things up.
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync*/
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync#define SETSPANPTRS(IN,N,IPW,PW,IPPT,PPT,FPW,FPPT,FSORT) \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync { \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync N = IN * miFindMaxBand(pGC->pCompositeClip); \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync if(!(PW = (int *)ALLOCATE_LOCAL(N * sizeof(int)))) \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync return; \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync if(!(PPT = (DDXPointRec *)ALLOCATE_LOCAL(N * sizeof(DDXPointRec)))) \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync { \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync DEALLOCATE_LOCAL(PW); \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync return; \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync } \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync FPW = PW; \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync FPPT = PPT; \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync N = miClipSpans(pGC->pCompositeClip, IPPT, IPW, IN, \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync PPT, PW, FSORT); \
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync }
deb4998ba50060c48cce222fd18a8eed053918d7vboxsync