cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * Copyright © 2004 Keith Packard
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * Permission to use, copy, modify, distribute, and sell this software and its
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * documentation for any purpose is hereby granted without fee, provided that
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * the above copyright notice appear in all copies and that both that
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * copyright notice and this permission notice appear in supporting
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * documentation, and that the name of Keith Packard not be used in
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * advertising or publicity pertaining to distribution of the software without
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * specific, written prior permission. Keith Packard makes no
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * representations about the suitability of this software for any purpose. It
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * is provided "as is" without express or implied warranty.
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * PERFORMANCE OF THIS SOFTWARE.
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync#define N_Y_FRAC(n) ((n) == 1 ? 1 : (1 << ((n)/2)) - 1)
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync#define STEP_Y_BIG(n) (xFixed1 - (N_Y_FRAC(n) - 1) * STEP_Y_SMALL(n))
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync#define Y_FRAC_LAST(n) (Y_FRAC_FIRST(n) + (N_Y_FRAC(n) - 1) * STEP_Y_SMALL(n))
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync#define STEP_X_BIG(n) (xFixed1 - (N_X_FRAC(n) - 1) * STEP_X_SMALL(n))
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync#define X_FRAC_LAST(n) (X_FRAC_FIRST(n) + (N_X_FRAC(n) - 1) * STEP_X_SMALL(n))
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync#define RenderSamplesX(x,n) ((n) == 1 ? 0 : (xFixedFrac (x) + X_FRAC_FIRST(n)) / STEP_X_SMALL(n))
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * An edge structure. This represents a single polygon edge
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * and can be quickly stepped across small or large gaps in the
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * sample grid
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * Step across a small sample grid gap
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync if (edge->e > 0) \
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync * Step across a large sample grid gap
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync if (edge->e > 0) \
cabde247f900dcf6e58d009bbdd15099c028c6fcvboxsync#endif /* _RENDEREDGE_H_ */