Lines Matching refs:y

94 static void gdImageBrushApply(gdImagePtr im, int x, int y);
95 static void gdImageTileApply(gdImagePtr im, int x, int y);
96 static void gdImageAntiAliasedApply(gdImagePtr im, int x, int y);
99 int gdImageGetTrueColorPixel(gdImagePtr im, int x, int y);
619 int x, y, p; in gdImagePaletteCopy() local
629 for (y = 0; y < to->sy; y++) { in gdImagePaletteCopy()
631 p = gdImageGetPixel(to, x, y); in gdImagePaletteCopy()
636 gdImageSetPixel(to, x, y, xlate[p]); in gdImagePaletteCopy()
725 void gdImageSetPixel (gdImagePtr im, int x, int y, int color) in gdImageSetPixel() argument
737 gdImageSetPixel(im, x, y, p); in gdImageSetPixel()
748 gdImageSetPixel(im, x, y, gdBrushed); in gdImageSetPixel()
753 gdImageBrushApply(im, x, y); in gdImageSetPixel()
756 gdImageTileApply(im, x, y); in gdImageSetPixel()
759 gdImageAntiAliasedApply(im, x, y); in gdImageSetPixel()
762 if (gdImageBoundsSafe(im, x, y)) { in gdImageSetPixel()
767 im->tpixels[y][x] = color; in gdImageSetPixel()
770 im->tpixels[y][x] = gdAlphaBlend(im->tpixels[y][x], color); in gdImageSetPixel()
773 im->tpixels[y][x] = gdAlphaBlend(im->tpixels[y][x], color); in gdImageSetPixel()
776 im->tpixels[y][x] = gdLayerOverlay(im->tpixels[y][x], color); in gdImageSetPixel()
780 im->pixels[y][x] = color; in gdImageSetPixel()
787 int gdImageGetTrueColorPixel (gdImagePtr im, int x, int y) in gdImageGetTrueColorPixel() argument
789 int p = gdImageGetPixel(im, x, y); in gdImageGetTrueColorPixel()
798 static void gdImageBrushApply (gdImagePtr im, int x, int y) in gdImageBrushApply() argument
810 y1 = y - hy; in gdImageBrushApply()
874 static void gdImageTileApply (gdImagePtr im, int x, int y) in gdImageTileApply() argument
883 srcy = y % gdImageSY(tile); in gdImageTileApply()
890 gdImageSetPixel(im, x, y, p); in gdImageTileApply()
898 gdImageSetPixel(im, x, y, gdImageColorResolveAlpha(im, in gdImageTileApply()
904 gdImageSetPixel(im, x, y, im->tileColorMap[p]); in gdImageTileApply()
911 static int gdImageTileGet (gdImagePtr im, int x, int y) in gdImageTileGet() argument
919 srcy = y % gdImageSY(im->tile); in gdImageTileGet()
1002 int gdImageGetPixel (gdImagePtr im, int x, int y) in gdImageGetPixel() argument
1004 if (gdImageBoundsSafe(im, x, y)) { in gdImageGetPixel()
1006 return im->tpixels[y][x]; in gdImageGetPixel()
1008 return im->pixels[y][x]; in gdImageGetPixel()
1061 static void gdImageHLine(gdImagePtr im, int y, int x1, int x2, int col) in gdImageHLine() argument
1065 _gdImageFilledHRectangle(im, x1, y - thickhalf, x2, y + im->thick - thickhalf - 1, col); in gdImageHLine()
1074 gdImageSetPixel(im, x1, y, col); in gdImageHLine()
1102 int dx, dy, incr1, incr2, d, x, y, xend, yend, xdirflag, ydirflag; in gdImageLine() local
1156 y = y2; in gdImageLine()
1161 y = y1; in gdImageLine()
1167 wstart = y - wid / 2; in gdImageLine()
1178 y++; in gdImageLine()
1181 wstart = y - wid / 2; in gdImageLine()
1192 y--; in gdImageLine()
1195 wstart = y - wid / 2; in gdImageLine()
1219 y = y2; in gdImageLine()
1224 y = y1; in gdImageLine()
1233 gdImageSetPixel (im, w, y, color); in gdImageLine()
1237 while (y < yend) { in gdImageLine()
1238 y++; in gdImageLine()
1247 gdImageSetPixel (im, w, y, color); in gdImageLine()
1251 while (y < yend) { in gdImageLine()
1252 y++; in gdImageLine()
1261 gdImageSetPixel (im, w, y, color); in gdImageLine()
1275 inline static void gdImageSetAAPixelColor(gdImagePtr im, int x, int y, int color, int t) in gdImageSetAAPixelColor() argument
1282 p = gdImageGetPixel(im,x,y); in gdImageSetAAPixelColor()
1290 im->tpixels[y][x]=gdTrueColorAlpha(dr, dg, db, gdAlphaOpaque); in gdImageSetAAPixelColor()
1299 long x, y, inc, frac; in gdImageAALine() local
1324 y = y1; in gdImageAALine()
1328 gdImageSetAAPixelColor(im, x, y, col, (frac >> 8) & 0xFF); in gdImageAALine()
1329 if (y + 1 < im->sy) { in gdImageAALine()
1330 gdImageSetAAPixelColor(im, x, y + 1, col, (~frac >> 8) & 0xFF); in gdImageAALine()
1335 y++; in gdImageAALine()
1338 y--; in gdImageAALine()
1355 for (y = y1; y <= y2; y++) { in gdImageAALine()
1356 gdImageSetAAPixelColor(im, x, y, col, (frac >> 8) & 0xFF); in gdImageAALine()
1358 gdImageSetAAPixelColor(im, x + 1, y, col, (~frac >> 8) & 0xFF); in gdImageAALine()
1372 static void dashedSet (gdImagePtr im, int x, int y, int color, int *onP, int *dashStepP, int wid, i…
1376 int dx, dy, incr1, incr2, d, x, y, xend, yend, xdirflag, ydirflag; in gdImageDashedLine() local
1403 y = y2; in gdImageDashedLine()
1408 y = y1; in gdImageDashedLine()
1412 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1419 y++; in gdImageDashedLine()
1422 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1430 y--; in gdImageDashedLine()
1433 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1451 y = y2; in gdImageDashedLine()
1456 y = y1; in gdImageDashedLine()
1461 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1463 while (y < yend) { in gdImageDashedLine()
1464 y++; in gdImageDashedLine()
1471 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1474 while (y < yend) { in gdImageDashedLine()
1475 y++; in gdImageDashedLine()
1482 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1488 static void dashedSet (gdImagePtr im, int x, int y, int color, int *onP, int *dashStepP, int wid, i… in dashedSet() argument
1501 wstart = y - wid / 2; in dashedSet()
1508 gdImageSetPixel(im, w, y, color); in dashedSet()
1516 void gdImageChar (gdImagePtr im, gdFontPtr f, int x, int y, int c, int color) in gdImageChar() argument
1530 for (py = y; (py < (y + f->h)); py++) { in gdImageChar()
1542 void gdImageCharUp (gdImagePtr im, gdFontPtr f, int x, int y, int c, int color) in gdImageCharUp() argument
1556 for (py = y; py > (y - f->w); py--) { in gdImageCharUp()
1568 void gdImageString (gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color) in gdImageString() argument
1574 gdImageChar(im, f, x, y, s[i], color); in gdImageString()
1579 void gdImageStringUp (gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color) in gdImageStringUp() argument
1585 gdImageCharUp(im, f, x, y, s[i], color); in gdImageStringUp()
1586 y -= f->w; in gdImageStringUp()
1592 void gdImageString16 (gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color) in gdImageString16() argument
1598 gdImageChar(im, f, x, y, s[i], color); in gdImageString16()
1603 void gdImageStringUp16 (gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color) in gdImageStringUp16() argument
1609 gdImageCharUp(im, f, x, y, s[i], color); in gdImageStringUp16()
1610 y -= f->w; in gdImageStringUp16()
1677 int x, y; in gdImageFilledArc() local
1679 y = ((long) gdSinT[i % 360] * (long) h / (2 * 1024)) + cy; in gdImageFilledArc()
1683 gdImageLine(im, lx, ly, x, y, color); in gdImageFilledArc()
1685 if (y == ly) { in gdImageFilledArc()
1694 pts[pti].y = y; in gdImageFilledArc()
1700 fy = y; in gdImageFilledArc()
1703 pts[0].y = cy; in gdImageFilledArc()
1705 pts[pti].y = y; in gdImageFilledArc()
1709 ly = y; in gdImageFilledArc()
1720 pts[0].y = fy; in gdImageFilledArc()
1722 pts[1].y = ly; in gdImageFilledArc()
1724 pts[2].y = cy; in gdImageFilledArc()
1735 pts[pti].y = cy; in gdImageFilledArc()
1741 void gdImageFillToBorder (gdImagePtr im, int x, int y, int border, int color) in gdImageFillToBorder() argument
1767 if (y >= im->sy) { in gdImageFillToBorder()
1768 y = im->sy - 1; in gdImageFillToBorder()
1769 } else if (y < 0) { in gdImageFillToBorder()
1770 y = 0; in gdImageFillToBorder()
1774 if (gdImageGetPixel(im, i, y) == border) { in gdImageFillToBorder()
1777 gdImageSetPixel(im, i, y, color); in gdImageFillToBorder()
1787 if (gdImageGetPixel(im, i, y) == border) { in gdImageFillToBorder()
1790 gdImageSetPixel(im, i, y, color); in gdImageFillToBorder()
1795 if (y > 0) { in gdImageFillToBorder()
1798 int c = gdImageGetPixel(im, i, y - 1); in gdImageFillToBorder()
1801 gdImageFillToBorder(im, i, y - 1, border, color); in gdImageFillToBorder()
1811 if (y < ((im->sy) - 1)) { in gdImageFillToBorder()
1814 int c = gdImageGetPixel(im, i, y + 1); in gdImageFillToBorder()
1818 gdImageFillToBorder(im, i, y + 1, border, color); in gdImageFillToBorder()
1840 struct seg {int y, xl, xr, dy;}; member
1846 {sp->y = Y; sp->xl = XL; sp->xr = XR; sp->dy = DY; sp++;}
1849 {sp--; Y = sp->y+(DY = sp->dy); XL = sp->xl; XR = sp->xr;}
1851 static void _gdImageFillTiled(gdImagePtr im, int x, int y, int nc);
1853 void gdImageFill(gdImagePtr im, int x, int y, int nc) in gdImageFill() argument
1874 _gdImageFillTiled(im,x,y,nc); in gdImageFill()
1880 oc = gdImageGetPixel(im, x, y); in gdImageFill()
1881 if (oc==nc || x<0 || x>wx2 || y<0 || y>wy2) { in gdImageFill()
1890 int ix = x, iy = y, c; in gdImageFill()
1908 FILL_PUSH(y,x,x,1); in gdImageFill()
1910 FILL_PUSH(y+1, x, x, -1); in gdImageFill()
1912 FILL_POP(y, x1, x2, dy); in gdImageFill()
1914 for (x=x1; x>=0 && gdImageGetPixel(im,x, y)==oc; x--) { in gdImageFill()
1915 gdImageSetPixel(im,x, y, nc); in gdImageFill()
1924 FILL_PUSH(y, l, x1-1, -dy); in gdImageFill()
1928 for (; x<=wx2 && gdImageGetPixel(im,x, y)==oc; x++) { in gdImageFill()
1929 gdImageSetPixel(im, x, y, nc); in gdImageFill()
1931 FILL_PUSH(y, l, x-1, dy); in gdImageFill()
1934 FILL_PUSH(y, x2+1, x-1, -dy); in gdImageFill()
1936 skip: for (x++; x<=x2 && (gdImageGetPixel(im, x, y)!=oc); x++); in gdImageFill()
1948 static void _gdImageFillTiled(gdImagePtr im, int x, int y, int nc) in _gdImageFillTiled() argument
1964 nc = gdImageTileGet(im,x,y); in _gdImageFillTiled()
1974 oc = gdImageGetPixel(im, x, y); in _gdImageFillTiled()
1977 FILL_PUSH(y,x,x,1); in _gdImageFillTiled()
1979 FILL_PUSH(y+1, x, x, -1); in _gdImageFillTiled()
1981 FILL_POP(y, x1, x2, dy); in _gdImageFillTiled()
1982 for (x=x1; x>=0 && (!pts[y][x] && gdImageGetPixel(im,x,y)==oc); x--) { in _gdImageFillTiled()
1983 nc = gdImageTileGet(im,x,y); in _gdImageFillTiled()
1984 pts[y][x] = 1; in _gdImageFillTiled()
1985 gdImageSetPixel(im,x, y, nc); in _gdImageFillTiled()
1994 FILL_PUSH(y, l, x1-1, -dy); in _gdImageFillTiled()
1998 for(; x<wx2 && (!pts[y][x] && gdImageGetPixel(im,x, y)==oc); x++) { in _gdImageFillTiled()
1999 nc = gdImageTileGet(im,x,y); in _gdImageFillTiled()
2000 pts[y][x] = 1; in _gdImageFillTiled()
2001 gdImageSetPixel(im, x, y, nc); in _gdImageFillTiled()
2003 FILL_PUSH(y, l, x-1, dy); in _gdImageFillTiled()
2006 FILL_PUSH(y, x2+1, x-1, -dy); in _gdImageFillTiled()
2008 skip: for(x++; x<=x2 && (pts[y][x] || gdImageGetPixel(im,x, y)!=oc); x++); in _gdImageFillTiled()
2106 int x, y; in _gdImageFilledHRectangle() local
2120 y = y1; in _gdImageFilledHRectangle()
2122 y2 = y; in _gdImageFilledHRectangle()
2142 for (y = y1; (y <= y2); y++) { in _gdImageFilledHRectangle()
2143 gdImageSetPixel (im, x, y, color); in _gdImageFilledHRectangle()
2150 int x, y; in _gdImageFilledVRectangle() local
2164 y = y1; in _gdImageFilledVRectangle()
2166 y2 = y; in _gdImageFilledVRectangle()
2185 for (y = y1; (y <= y2); y++) { in _gdImageFilledVRectangle()
2187 gdImageSetPixel (im, x, y, color); in _gdImageFilledVRectangle()
2200 int x, y; in gdImageCopy() local
2212 for (y = 0; (y < h); y++) { in gdImageCopy()
2214 int c = gdImageGetTrueColorPixel (src, srcX + x, srcY + y); in gdImageCopy()
2216 gdImageSetPixel (dst, dstX + x, dstY + y, c); in gdImageCopy()
2222 for (y = 0; (y < h); y++) { in gdImageCopy()
2224 int c = gdImageGetPixel (src, srcX + x, srcY + y); in gdImageCopy()
2226 …gdImageSetPixel(dst, dstX + x, dstY + y, gdTrueColorAlpha(src->red[c], src->green[c], src->blue[c]… in gdImageCopy()
2239 for (y = srcY; y < (srcY + h); y++) { in gdImageCopy()
2244 c = gdImageGetPixel (src, x, y); in gdImageCopy()
2281 int x, y; in gdImageCopyMerge() local
2286 for (y = srcY; y < (srcY + h); y++) { in gdImageCopyMerge()
2290 c = gdImageGetPixel(src, x, y); in gdImageCopyMerge()
2321 int x, y; in gdImageCopyMergeGray() local
2327 for (y = srcY; (y < (srcY + h)); y++) { in gdImageCopyMergeGray()
2331 c = gdImageGetPixel (src, x, y); in gdImageCopyMergeGray()
2375 int x, y; in gdImageCopyResized() local
2404 for (y = srcY; (y < (srcY + srcH)); y++) { in gdImageCopyResized()
2405 for (ydest = 0; (ydest < sty[y - srcY]); ydest++) { in gdImageCopyResized()
2416 int tmp = gdImageGetPixel (src, x, y); in gdImageCopyResized()
2417 mapTo = gdImageGetTrueColorPixel (src, x, y); in gdImageCopyResized()
2425 mapTo = gdImageGetTrueColorPixel (src, x, y); in gdImageCopyResized()
2434 c = gdImageGetPixel (src, x, y); in gdImageCopyResized()
2484 int x, y; in gdImageCopyResampled() local
2491 for (y = dstY; (y < dstY + dstH); y++) { in gdImageCopyResampled()
2492 sy1 = ((double) y - (double) dstY) * (double) srcH / (double) dstH; in gdImageCopyResampled()
2493 sy2 = ((double) (y + 1) - (double) dstY) * (double) srcH / (double) dstH; in gdImageCopyResampled()
2579 gdImageSetPixel(dst, x, y, gdTrueColorAlpha ((int) red, (int) green, (int) blue, (int) alpha)); in gdImageCopyResampled()
2608 ly = p->y; in gdImagePolygon()
2609 draw_line(im, lx, ly, p[n - 1].x, p[n - 1].y, c); in gdImagePolygon()
2612 draw_line(im, lx, ly, p->x, p->y, c); in gdImagePolygon()
2614 ly = p->y; in gdImagePolygon()
2636 int y; in gdImageFilledPolygon() local
2671 miny = p[0].y; in gdImageFilledPolygon()
2672 maxy = p[0].y; in gdImageFilledPolygon()
2674 if (p[i].y < miny) { in gdImageFilledPolygon()
2675 miny = p[i].y; in gdImageFilledPolygon()
2677 if (p[i].y > maxy) { in gdImageFilledPolygon()
2678 maxy = p[i].y; in gdImageFilledPolygon()
2704 for (y = miny; y <= maxy; y++) { in gdImageFilledPolygon()
2717 y1 = p[ind1].y; in gdImageFilledPolygon()
2718 y2 = p[ind2].y; in gdImageFilledPolygon()
2723 y2 = p[ind1].y; in gdImageFilledPolygon()
2724 y1 = p[ind2].y; in gdImageFilledPolygon()
2734 if (y >= y1 && y < y2) { in gdImageFilledPolygon()
2735 im->polyInts[ints++] = (float) ((y - y1) * (x2 - x1)) / (float) (y2 - y1) + 0.5 + x1; in gdImageFilledPolygon()
2736 } else if (y == pmaxy && y == y2) { in gdImageFilledPolygon()
2743 gdImageLine(im, im->polyInts[i], y, im->polyInts[i + 1], y, fill_color); in gdImageFilledPolygon()
2822 int x, y; in gdImageCompare() local
2859 for (y = 0; y < sy; y++) { in gdImageCompare()
2861 p1 = im1->trueColor ? gdImageTrueColorPixel(im1, x, y) : gdImagePalettePixel(im1, x, y); in gdImageCompare()
2862 p2 = im2->trueColor ? gdImageTrueColorPixel(im2, x, y) : gdImagePalettePixel(im2, x, y); in gdImageCompare()
3053 unsigned int y; in gdImagePaletteToTrueColor() local
3072 for (y = 0; y < sy; y++) { in gdImagePaletteToTrueColor()
3073 const unsigned char *src_row = src->pixels[y]; in gdImagePaletteToTrueColor()
3077 src->tpixels[y] = (int *) gdMalloc(sx * sizeof(int)); in gdImagePaletteToTrueColor()
3078 if (src->tpixels[y] == NULL) { in gdImagePaletteToTrueColor()
3082 dst_row = src->tpixels[y]; in gdImagePaletteToTrueColor()
3095 for (yy = 0; yy < y; yy++) { in gdImagePaletteToTrueColor()
3113 for (yy = 0; yy < y; yy++) { in gdImagePaletteToTrueColor()