hackathon-dev #1

Merged
amy merged 101 commits from hackathon-dev into develop 2019-12-12 13:56:11 -07:00
Showing only changes of commit ab16513e3a - Show all commits

View File

@ -19,7 +19,7 @@ inline static BYTE line_clip_outcode(INT32 x, INT32 y, INT32 xmin, INT32 ymin, I
return rc; return rc;
} }
#define CPX 4 /* clipping precision in bits */ #define CPX 8 /* clipping precision in bits */
/* these macros keep the number of bits straight when doing fixed-point multiply & divide */ /* these macros keep the number of bits straight when doing fixed-point multiply & divide */
#define M(a, b) ((((a) * (b))) >> CPX) #define M(a, b) ((((a) * (b))) >> CPX)
@ -106,7 +106,7 @@ static BOOL internal_line(PDCTXT pdctxt, INT32 x1, INT32 y1, INT32 x2, INT32 y2)
{ {
INT32 buffer[4]; INT32 buffer[4];
if (line_clip(buffer, x1 << CPX, y1 << CPX, x2 << CPX, y2 << CPX, pdctxt->cliprect.left << CPX, pdctxt->cliprect.top << CPX, if (line_clip(buffer, x1 << CPX, y1 << CPX, x2 << CPX, y2 << CPX, pdctxt->cliprect.left << CPX, pdctxt->cliprect.top << CPX,
(pdctxt->cliprect.right - 1) << CPX, (pdctxt->cliprect.bottom - 1) << CPX)) pdctxt->cliprect.right << CPX, pdctxt->cliprect.bottom << CPX))
return (*pdctxt->funcs->line)(pdctxt->privdata, buffer[0] >> CPX, buffer[1] >> CPX, buffer[2] >> CPX, buffer[3] >> CPX, pdctxt->color, pdctxt->rop2); return (*pdctxt->funcs->line)(pdctxt->privdata, buffer[0] >> CPX, buffer[1] >> CPX, buffer[2] >> CPX, buffer[3] >> CPX, pdctxt->color, pdctxt->rop2);
return TRUE; return TRUE;
} }