Lines Matching refs:y

136 static void gdImageBrushApply(gdImagePtr im, int x, int y);
137 static void gdImageTileApply(gdImagePtr im, int x, int y);
139 int gdImageGetTrueColorPixel(gdImagePtr im, int x, int y);
627 int x, y, p; in gdImagePaletteCopy() local
637 for (y = 0; y < to->sy; y++) { in gdImagePaletteCopy()
639 p = gdImageGetPixel(to, x, y); in gdImagePaletteCopy()
644 gdImageSetPixel(to, x, y, xlate[p]); in gdImagePaletteCopy()
733 void gdImageSetPixel (gdImagePtr im, int x, int y, int color) in gdImageSetPixel() argument
745 gdImageSetPixel(im, x, y, p); in gdImageSetPixel()
756 gdImageSetPixel(im, x, y, gdBrushed); in gdImageSetPixel()
761 gdImageBrushApply(im, x, y); in gdImageSetPixel()
764 gdImageTileApply(im, x, y); in gdImageSetPixel()
769 gdImageSetPixel(im, x, y, im->AA_color); in gdImageSetPixel()
772 if (gdImageBoundsSafe(im, x, y)) { in gdImageSetPixel()
777 im->tpixels[y][x] = color; in gdImageSetPixel()
781 im->tpixels[y][x] = gdAlphaBlend(im->tpixels[y][x], color); in gdImageSetPixel()
784 im->tpixels[y][x] = gdLayerOverlay(im->tpixels[y][x], color); in gdImageSetPixel()
787 im->tpixels[y][x] = gdLayerMultiply(im->tpixels[y][x], color); in gdImageSetPixel()
791 im->pixels[y][x] = color; in gdImageSetPixel()
798 int gdImageGetTrueColorPixel (gdImagePtr im, int x, int y) in gdImageGetTrueColorPixel() argument
800 int p = gdImageGetPixel(im, x, y); in gdImageGetTrueColorPixel()
809 static void gdImageBrushApply (gdImagePtr im, int x, int y) in gdImageBrushApply() argument
821 y1 = y - hy; in gdImageBrushApply()
885 static void gdImageTileApply (gdImagePtr im, int x, int y) in gdImageTileApply() argument
894 srcy = y % gdImageSY(tile); in gdImageTileApply()
901 gdImageSetPixel(im, x, y, p); in gdImageTileApply()
909 gdImageSetPixel(im, x, y, gdImageColorResolveAlpha(im, in gdImageTileApply()
915 gdImageSetPixel(im, x, y, im->tileColorMap[p]); in gdImageTileApply()
922 static int gdImageTileGet (gdImagePtr im, int x, int y) in gdImageTileGet() argument
930 srcy = y % gdImageSY(im->tile); in gdImageTileGet()
951 int gdImageGetPixel (gdImagePtr im, int x, int y) in gdImageGetPixel() argument
953 if (gdImageBoundsSafe(im, x, y)) { in gdImageGetPixel()
955 return im->tpixels[y][x]; in gdImageGetPixel()
957 return im->pixels[y][x]; in gdImageGetPixel()
971 static void gdImageHLine(gdImagePtr im, int y, int x1, int x2, int col) in gdImageHLine() argument
975 _gdImageFilledHRectangle(im, x1, y - thickhalf, x2, y + im->thick - thickhalf - 1, col); in gdImageHLine()
984 gdImageSetPixel(im, x1, y, col); in gdImageHLine()
1012 int dx, dy, incr1, incr2, d, x, y, xend, yend, xdirflag, ydirflag; in gdImageLine() local
1066 y = y2; in gdImageLine()
1071 y = y1; in gdImageLine()
1077 wstart = y - wid / 2; in gdImageLine()
1088 y++; in gdImageLine()
1091 wstart = y - wid / 2; in gdImageLine()
1102 y--; in gdImageLine()
1105 wstart = y - wid / 2; in gdImageLine()
1129 y = y2; in gdImageLine()
1134 y = y1; in gdImageLine()
1143 gdImageSetPixel (im, w, y, color); in gdImageLine()
1147 while (y < yend) { in gdImageLine()
1148 y++; in gdImageLine()
1157 gdImageSetPixel (im, w, y, color); in gdImageLine()
1161 while (y < yend) { in gdImageLine()
1162 y++; in gdImageLine()
1171 gdImageSetPixel (im, w, y, color); in gdImageLine()
1185 inline static void gdImageSetAAPixelColor(gdImagePtr im, int x, int y, int color, int t) in gdImageSetAAPixelColor() argument
1192 p = gdImageGetPixel(im,x,y); in gdImageSetAAPixelColor()
1200 im->tpixels[y][x]=gdTrueColorAlpha(dr, dg, db, gdAlphaOpaque); in gdImageSetAAPixelColor()
1209 long x, y, inc, frac; in gdImageAALine() local
1240 y = y1; in gdImageAALine()
1244 gdImageSetAAPixelColor(im, x, y, col, (frac >> 8) & 0xFF); in gdImageAALine()
1245 if (y + 1 < im->sy) { in gdImageAALine()
1246 gdImageSetAAPixelColor(im, x, y + 1, col, (~frac >> 8) & 0xFF); in gdImageAALine()
1251 y++; in gdImageAALine()
1254 y--; in gdImageAALine()
1271 for (y = y1; y <= y2; y++) { in gdImageAALine()
1272 gdImageSetAAPixelColor(im, x, y, col, (frac >> 8) & 0xFF); in gdImageAALine()
1274 gdImageSetAAPixelColor(im, x + 1, y, col, (~frac >> 8) & 0xFF); in gdImageAALine()
1288 static void dashedSet (gdImagePtr im, int x, int y, int color, int *onP, int *dashStepP, int wid, i…
1292 int dx, dy, incr1, incr2, d, x, y, xend, yend, xdirflag, ydirflag; in gdImageDashedLine() local
1318 y = y2; in gdImageDashedLine()
1323 y = y1; in gdImageDashedLine()
1327 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1334 y++; in gdImageDashedLine()
1337 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1345 y--; in gdImageDashedLine()
1348 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1366 y = y2; in gdImageDashedLine()
1371 y = y1; in gdImageDashedLine()
1376 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1378 while (y < yend) { in gdImageDashedLine()
1379 y++; in gdImageDashedLine()
1386 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1389 while (y < yend) { in gdImageDashedLine()
1390 y++; in gdImageDashedLine()
1397 dashedSet(im, x, y, color, &on, &dashStep, wid, vert); in gdImageDashedLine()
1403 static void dashedSet (gdImagePtr im, int x, int y, int color, int *onP, int *dashStepP, int wid, i… in dashedSet() argument
1416 wstart = y - wid / 2; in dashedSet()
1423 gdImageSetPixel(im, w, y, color); in dashedSet()
1431 void gdImageChar (gdImagePtr im, gdFontPtr f, int x, int y, int c, int color) in gdImageChar() argument
1437 const int yuppper = (y > INT_MAX - f->h) ? INT_MAX : y + f->h; in gdImageChar()
1447 for (py = y; py < yuppper; py++) { in gdImageChar()
1459 void gdImageCharUp (gdImagePtr im, gdFontPtr f, int x, int y, int c, int color) in gdImageCharUp() argument
1465 const int ylower = (y < INT_MIN + f->w) ? INT_MIN : y - f->w; in gdImageCharUp()
1475 for (py = y; py > ylower; py--) { in gdImageCharUp()
1487 void gdImageString (gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color) in gdImageString() argument
1493 gdImageChar(im, f, x, y, s[i], color); in gdImageString()
1498 void gdImageStringUp (gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color) in gdImageStringUp() argument
1504 gdImageCharUp(im, f, x, y, s[i], color); in gdImageStringUp()
1505 y -= f->w; in gdImageStringUp()
1511 void gdImageString16 (gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color) in gdImageString16() argument
1517 gdImageChar(im, f, x, y, s[i], color); in gdImageString16()
1522 void gdImageStringUp16 (gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color) in gdImageStringUp16() argument
1528 gdImageCharUp(im, f, x, y, s[i], color); in gdImageStringUp16()
1529 y -= f->w; in gdImageStringUp16()
1596 int x, y; in gdImageFilledArc() local
1598 y = endy = ((long) gdSinT[i % 360] * (long) h / (2 * 1024)) + cy; in gdImageFilledArc()
1602 gdImageLine(im, lx, ly, x, y, color); in gdImageFilledArc()
1604 if (y == ly) { in gdImageFilledArc()
1613 pts[pti].y = y; in gdImageFilledArc()
1619 fy = y; in gdImageFilledArc()
1622 pts[0].y = cy; in gdImageFilledArc()
1624 pts[pti].y = starty = y; in gdImageFilledArc()
1628 ly = y; in gdImageFilledArc()
1639 pts[0].y = fy; in gdImageFilledArc()
1641 pts[1].y = ly; in gdImageFilledArc()
1643 pts[2].y = cy; in gdImageFilledArc()
1654 if (pts[1].x != startx && pts[1].y == starty) { in gdImageFilledArc()
1658 pts[i].y = pts[i-1].y; in gdImageFilledArc()
1661 pts[1].y = starty; in gdImageFilledArc()
1664 if (pts[pti-1].x != endx && pts[pti-1].y == endy) { in gdImageFilledArc()
1667 pts[pti].y = endy; in gdImageFilledArc()
1672 pts[pti].y = cy; in gdImageFilledArc()
1772 void gdImageFillToBorder (gdImagePtr im, int x, int y, int border, int color) in gdImageFillToBorder() argument
1798 if (y >= im->sy) { in gdImageFillToBorder()
1799 y = im->sy - 1; in gdImageFillToBorder()
1800 } else if (y < 0) { in gdImageFillToBorder()
1801 y = 0; in gdImageFillToBorder()
1805 if (gdImageGetPixel(im, i, y) == border) { in gdImageFillToBorder()
1808 gdImageSetPixel(im, i, y, color); in gdImageFillToBorder()
1818 if (gdImageGetPixel(im, i, y) == border) { in gdImageFillToBorder()
1821 gdImageSetPixel(im, i, y, color); in gdImageFillToBorder()
1826 if (y > 0) { in gdImageFillToBorder()
1829 int c = gdImageGetPixel(im, i, y - 1); in gdImageFillToBorder()
1832 gdImageFillToBorder(im, i, y - 1, border, color); in gdImageFillToBorder()
1842 if (y < ((im->sy) - 1)) { in gdImageFillToBorder()
1845 int c = gdImageGetPixel(im, i, y + 1); in gdImageFillToBorder()
1849 gdImageFillToBorder(im, i, y + 1, border, color); in gdImageFillToBorder()
1871 struct seg {int y, xl, xr, dy;}; member
1877 {sp->y = Y; sp->xl = XL; sp->xr = XR; sp->dy = DY; sp++;}
1880 {sp--; Y = sp->y+(DY = sp->dy); XL = sp->xl; XR = sp->xr;}
1882 static void _gdImageFillTiled(gdImagePtr im, int x, int y, int nc);
1884 void gdImageFill(gdImagePtr im, int x, int y, int nc) in gdImageFill() argument
1905 _gdImageFillTiled(im,x,y,nc); in gdImageFill()
1911 oc = gdImageGetPixel(im, x, y); in gdImageFill()
1912 if (oc==nc || x<0 || x>wx2 || y<0 || y>wy2) { in gdImageFill()
1921 int ix = x, iy = y, c; in gdImageFill()
1939 FILL_PUSH(y,x,x,1); in gdImageFill()
1941 FILL_PUSH(y+1, x, x, -1); in gdImageFill()
1943 FILL_POP(y, x1, x2, dy); in gdImageFill()
1945 for (x=x1; x>=0 && gdImageGetPixel(im,x, y)==oc; x--) { in gdImageFill()
1946 gdImageSetPixel(im,x, y, nc); in gdImageFill()
1955 FILL_PUSH(y, l, x1-1, -dy); in gdImageFill()
1959 for (; x<=wx2 && gdImageGetPixel(im,x, y)==oc; x++) { in gdImageFill()
1960 gdImageSetPixel(im, x, y, nc); in gdImageFill()
1962 FILL_PUSH(y, l, x-1, dy); in gdImageFill()
1965 FILL_PUSH(y, x2+1, x-1, -dy); in gdImageFill()
1968 for (x++; x<=x2 && (gdImageGetPixel(im, x, y)!=oc); x++); in gdImageFill()
1980 static void _gdImageFillTiled(gdImagePtr im, int x, int y, int nc) in _gdImageFillTiled() argument
1996 nc = gdImageTileGet(im,x,y); in _gdImageFillTiled()
2006 oc = gdImageGetPixel(im, x, y); in _gdImageFillTiled()
2009 FILL_PUSH(y,x,x,1); in _gdImageFillTiled()
2011 FILL_PUSH(y+1, x, x, -1); in _gdImageFillTiled()
2013 FILL_POP(y, x1, x2, dy); in _gdImageFillTiled()
2014 for (x=x1; x>=0 && (!pts[y][x] && gdImageGetPixel(im,x,y)==oc); x--) { in _gdImageFillTiled()
2015 nc = gdImageTileGet(im,x,y); in _gdImageFillTiled()
2016 pts[y][x] = 1; in _gdImageFillTiled()
2017 gdImageSetPixel(im,x, y, nc); in _gdImageFillTiled()
2026 FILL_PUSH(y, l, x1-1, -dy); in _gdImageFillTiled()
2030 for(; x<wx2 && (!pts[y][x] && gdImageGetPixel(im,x, y)==oc); x++) { in _gdImageFillTiled()
2031 nc = gdImageTileGet(im,x,y); in _gdImageFillTiled()
2032 pts[y][x] = 1; in _gdImageFillTiled()
2033 gdImageSetPixel(im, x, y, nc); in _gdImageFillTiled()
2035 FILL_PUSH(y, l, x-1, dy); in _gdImageFillTiled()
2038 FILL_PUSH(y, x2+1, x-1, -dy); in _gdImageFillTiled()
2041 for(x++; x<=x2 && (pts[y][x] || gdImageGetPixel(im,x, y)!=oc); x++); in _gdImageFillTiled()
2135 int x, y; in _gdImageFilledHRectangle() local
2149 y = y1; in _gdImageFilledHRectangle()
2151 y2 = y; in _gdImageFilledHRectangle()
2171 for (y = y1; (y <= y2); y++) { in _gdImageFilledHRectangle()
2172 gdImageSetPixel (im, x, y, color); in _gdImageFilledHRectangle()
2179 int x, y; in _gdImageFilledVRectangle() local
2193 y = y1; in _gdImageFilledVRectangle()
2195 y2 = y; in _gdImageFilledVRectangle()
2214 for (y = y1; (y <= y2); y++) { in _gdImageFilledVRectangle()
2216 gdImageSetPixel (im, x, y, color); in _gdImageFilledVRectangle()
2229 int x, y; in gdImageCopy() local
2241 for (y = 0; (y < h); y++) { in gdImageCopy()
2243 int c = gdImageGetTrueColorPixel (src, srcX + x, srcY + y); in gdImageCopy()
2245 gdImageSetPixel (dst, dstX + x, dstY + y, c); in gdImageCopy()
2251 for (y = 0; (y < h); y++) { in gdImageCopy()
2253 int c = gdImageGetPixel (src, srcX + x, srcY + y); in gdImageCopy()
2255 …gdImageSetPixel(dst, dstX + x, dstY + y, gdTrueColorAlpha(src->red[c], src->green[c], src->blue[c]… in gdImageCopy()
2268 for (y = srcY; y < (srcY + h); y++) { in gdImageCopy()
2273 c = gdImageGetPixel (src, x, y); in gdImageCopy()
2310 int x, y; in gdImageCopyMerge() local
2315 for (y = srcY; y < (srcY + h); y++) { in gdImageCopyMerge()
2319 c = gdImageGetPixel(src, x, y); in gdImageCopyMerge()
2350 int x, y; in gdImageCopyMergeGray() local
2356 for (y = srcY; (y < (srcY + h)); y++) { in gdImageCopyMergeGray()
2360 c = gdImageGetPixel (src, x, y); in gdImageCopyMergeGray()
2404 int x, y; in gdImageCopyResized() local
2433 for (y = srcY; (y < (srcY + srcH)); y++) { in gdImageCopyResized()
2434 for (ydest = 0; (ydest < sty[y - srcY]); ydest++) { in gdImageCopyResized()
2445 int tmp = gdImageGetPixel (src, x, y); in gdImageCopyResized()
2446 mapTo = gdImageGetTrueColorPixel (src, x, y); in gdImageCopyResized()
2454 mapTo = gdImageGetTrueColorPixel (src, x, y); in gdImageCopyResized()
2463 c = gdImageGetPixel (src, x, y); in gdImageCopyResized()
2513 int x, y; in gdImageCopyResampled() local
2520 for (y = dstY; (y < dstY + dstH); y++) { in gdImageCopyResampled()
2521 sy1 = ((double) y - (double) dstY) * (double) srcH / (double) dstH; in gdImageCopyResampled()
2522 sy2 = ((double) (y + 1) - (double) dstY) * (double) srcH / (double) dstH; in gdImageCopyResampled()
2599 gdImageSetPixel(dst, x, y, gdTrueColorAlpha ((int)red, (int)green, (int)blue, (int)alpha)); in gdImageCopyResampled()
2611 gdImageLine (im, p->x, p->y, p[n - 1].x, p[n - 1].y, c); in gdImagePolygon()
2625 ly = p->y; in gdImageOpenPolygon()
2628 gdImageLine(im, lx, ly, p->x, p->y, c); in gdImageOpenPolygon()
2630 ly = p->y; in gdImageOpenPolygon()
2647 int y; in gdImageFilledPolygon() local
2682 miny = p[0].y; in gdImageFilledPolygon()
2683 maxy = p[0].y; in gdImageFilledPolygon()
2685 if (p[i].y < miny) { in gdImageFilledPolygon()
2686 miny = p[i].y; in gdImageFilledPolygon()
2688 if (p[i].y > maxy) { in gdImageFilledPolygon()
2689 maxy = p[i].y; in gdImageFilledPolygon()
2715 for (y = miny; y <= maxy; y++) { in gdImageFilledPolygon()
2728 y1 = p[ind1].y; in gdImageFilledPolygon()
2729 y2 = p[ind2].y; in gdImageFilledPolygon()
2734 y2 = p[ind1].y; in gdImageFilledPolygon()
2735 y1 = p[ind2].y; in gdImageFilledPolygon()
2745 if (y >= y1 && y < y2) { in gdImageFilledPolygon()
2746 im->polyInts[ints++] = (float) ((y - y1) * (x2 - x1)) / (float) (y2 - y1) + 0.5 + x1; in gdImageFilledPolygon()
2747 } else if (y == pmaxy && y == y2) { in gdImageFilledPolygon()
2754 gdImageLine(im, im->polyInts[i], y, im->polyInts[i + 1], y, fill_color); in gdImageFilledPolygon()
2836 int x, y; in gdImageCompare() local
2873 for (y = 0; y < sy; y++) { in gdImageCompare()
2875 p1 = im1->trueColor ? gdImageTrueColorPixel(im1, x, y) : gdImagePalettePixel(im1, x, y); in gdImageCompare()
2876 p2 = im2->trueColor ? gdImageTrueColorPixel(im2, x, y) : gdImagePalettePixel(im2, x, y); in gdImageCompare()
3065 unsigned int y; in gdImagePaletteToTrueColor() local
3084 for (y = 0; y < sy; y++) { in gdImagePaletteToTrueColor()
3085 const unsigned char *src_row = src->pixels[y]; in gdImagePaletteToTrueColor()
3089 src->tpixels[y] = (int *) gdMalloc(sx * sizeof(int)); in gdImagePaletteToTrueColor()
3090 if (src->tpixels[y] == NULL) { in gdImagePaletteToTrueColor()
3094 dst_row = src->tpixels[y]; in gdImagePaletteToTrueColor()
3107 for (yy = 0; yy < y; yy++) { in gdImagePaletteToTrueColor()
3125 for (yy = 0; yy < y; yy++) { in gdImagePaletteToTrueColor()