im 148 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 158 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 162 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 168 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 177 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 182 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 191 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 203 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 208 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 213 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 218 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 226 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 234 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 242 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 273 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 280 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 285 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 354 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 360 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 366 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 373 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 380 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 387 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 393 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 398 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 405 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 409 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 421 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 427 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 434 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 441 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 446 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 453 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 460 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 469 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 474 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 480 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 487 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 496 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 505 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 514 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 523 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 534 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 543 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 551 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 558 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 562 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 567 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 572 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 579 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 594 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 603 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 612 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 621 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 678 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 682 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 696 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 716 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 728 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 754 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 763 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 770 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 776 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 782 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 787 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 794 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 801 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 817 ext/gd/gd.c ZEND_ARG_INFO(0, im) im 1428 ext/gd/gd.c gdImagePtr im; im 1436 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1447 ext/gd/gd.c gdImageSetStyle(im, stylearr, index); im 1460 ext/gd/gd.c gdImagePtr im; im 1471 ext/gd/gd.c im = gdImageCreateTrueColor(x_size, y_size); im 1473 ext/gd/gd.c if (!im) { im 1477 ext/gd/gd.c RETURN_RES(zend_register_resource(im, le_gd)); im 1486 ext/gd/gd.c gdImagePtr im; im 1492 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1496 ext/gd/gd.c RETURN_BOOL(im->trueColor); im 1507 ext/gd/gd.c gdImagePtr im; im 1513 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1521 ext/gd/gd.c gdImageTrueColorToPalette(im, dither, ncolors); im 1532 ext/gd/gd.c gdImagePtr im; im 1538 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1542 ext/gd/gd.c if (gdImagePaletteToTrueColor(im) == 0) { im 1599 ext/gd/gd.c gdImagePtr im; im 1605 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1609 ext/gd/gd.c gdImageSetThickness(im, thick); im 1621 ext/gd/gd.c gdImagePtr im; im 1627 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1631 ext/gd/gd.c gdImageFilledEllipse(im, cx, cy, w, h, color); im 1643 ext/gd/gd.c gdImagePtr im; im 1650 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1664 ext/gd/gd.c gdImageFilledArc(im, cx, cy, w, h, st, e, col, style); im 1676 ext/gd/gd.c gdImagePtr im; im 1682 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1686 ext/gd/gd.c gdImageAlphaBlending(im, blend); im 1698 ext/gd/gd.c gdImagePtr im; im 1704 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1708 ext/gd/gd.c gdImageSaveAlpha(im, save); im 1720 ext/gd/gd.c gdImagePtr im; im 1726 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1730 ext/gd/gd.c gdImageAlphaBlending(im, effect); im 1742 ext/gd/gd.c gdImagePtr im; im 1749 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1753 ext/gd/gd.c ct = gdImageColorAllocateAlpha(im, red, green, blue, alpha); im 1767 ext/gd/gd.c gdImagePtr im; im 1773 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1777 ext/gd/gd.c RETURN_LONG(gdImageColorResolveAlpha(im, red, green, blue, alpha)); im 1787 ext/gd/gd.c gdImagePtr im; im 1793 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1797 ext/gd/gd.c RETURN_LONG(gdImageColorClosestAlpha(im, red, green, blue, alpha)); im 1807 ext/gd/gd.c gdImagePtr im; im 1813 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 1817 ext/gd/gd.c RETURN_LONG(gdImageColorExactAlpha(im, red, green, blue, alpha)); im 1875 ext/gd/gd.c gdImagePtr im = NULL; im 1922 ext/gd/gd.c im = gdImageCreateTrueColor(Width, Height); im 1923 ext/gd/gd.c if (im) { im 1928 ext/gd/gd.c gdImageSetPixel(im, x, y, gdTrueColor(GetRValue(c), GetGValue(c), GetBValue(c))); im 1939 ext/gd/gd.c if (!im) { im 1942 ext/gd/gd.c RETURN_RES(zend_register_resource(im, le_gd)); im 1960 ext/gd/gd.c gdImagePtr im; im 1982 ext/gd/gd.c im = gdImageCreateTrueColor(Width, Height); im 1983 ext/gd/gd.c if (im) { im 1988 ext/gd/gd.c gdImageSetPixel(im, x, y, gdTrueColor(GetRValue(c), GetGValue(c), GetBValue(c))); im 1998 ext/gd/gd.c if (!im) { im 2001 ext/gd/gd.c RETURN_RES(zend_register_resource(im, le_gd)); im 2040 ext/gd/gd.c gdImagePtr im, tile; im 2046 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2054 ext/gd/gd.c gdImageSetTile(im, tile); im 2065 ext/gd/gd.c gdImagePtr im, tile; im 2071 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2079 ext/gd/gd.c gdImageSetBrush(im, tile); im 2090 ext/gd/gd.c gdImagePtr im; im 2101 ext/gd/gd.c im = gdImageCreate(x_size, y_size); im 2103 ext/gd/gd.c if (!im) { im 2107 ext/gd/gd.c RETURN_RES(zend_register_resource(im, le_gd)); im 2198 ext/gd/gd.c gdImagePtr im; im 2207 ext/gd/gd.c im = (*ioctx_func_p)(io_ctx); im 2208 ext/gd/gd.c if (!im) { im 2216 ext/gd/gd.c return im; im 2225 ext/gd/gd.c gdImagePtr im; im 2246 ext/gd/gd.c im = _php_image_create_from_string(data, "JPEG", gdImageCreateFromJpegCtx); im 2255 ext/gd/gd.c im = _php_image_create_from_string(data, "PNG", gdImageCreateFromPngCtx); im 2263 ext/gd/gd.c im = _php_image_create_from_string(data, "GIF", gdImageCreateFromGifCtx); im 2267 ext/gd/gd.c im = _php_image_create_from_string(data, "WBMP", gdImageCreateFromWBMPCtx); im 2271 ext/gd/gd.c im = _php_image_create_from_string(data, "GD2", gdImageCreateFromGd2Ctx); im 2279 ext/gd/gd.c if (!im) { im 2284 ext/gd/gd.c RETURN_RES(zend_register_resource(im, le_gd)); im 2295 ext/gd/gd.c gdImagePtr im = NULL; im 2351 ext/gd/gd.c im = (*ioctx_func_p)(io_ctx, srcx, srcy, width, height); im 2353 ext/gd/gd.c im = (*ioctx_func_p)(io_ctx); im 2366 ext/gd/gd.c if (!im && fp) { im 2369 ext/gd/gd.c im = (*func_p)(fp, srcx, srcy, width, height); im 2373 ext/gd/gd.c im = gdImageCreateFromXpm(file); im 2380 ext/gd/gd.c im = gdImageCreateFromJpegEx(fp, ignore_warning); im 2385 ext/gd/gd.c im = (*func_p)(fp); im 2393 ext/gd/gd.c if (im) { im 2394 ext/gd/gd.c RETVAL_RES(zend_register_resource(im, le_gd)); im 2502 ext/gd/gd.c gdImagePtr im; im 2517 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(imgind), "Image", le_gd)) == NULL) { im 2548 ext/gd/gd.c gdImageWBMP(im, q, fp); im 2551 ext/gd/gd.c (*func_p)(im, fp, q); im 2554 ext/gd/gd.c for (i = 0; i < gdImageColorsTotal(im); i++) { im 2555 ext/gd/gd.c if (gdImageRed(im, i) == 0) break; im 2557 ext/gd/gd.c (*func_p)(im, i, fp); im 2560 ext/gd/gd.c if (im->trueColor){ im 2561 ext/gd/gd.c gdImageTrueColorToPalette(im,1,256); im 2563 ext/gd/gd.c (*func_p)(im, fp); im 2569 ext/gd/gd.c (*func_p)(im, fp, q, t); im 2575 ext/gd/gd.c (*func_p)(im, fp, q, t); im 2600 ext/gd/gd.c gdImageWBMP(im, q, tmp); im 2603 ext/gd/gd.c (*func_p)(im, tmp, q); im 2606 ext/gd/gd.c for (i = 0; i < gdImageColorsTotal(im); i++) { im 2607 ext/gd/gd.c if (gdImageRed(im, i) == 0) { im 2611 ext/gd/gd.c (*func_p)(im, q, tmp); im 2614 ext/gd/gd.c if (im->trueColor) { im 2615 ext/gd/gd.c gdImageTrueColorToPalette(im,1,256); im 2617 ext/gd/gd.c (*func_p)(im, tmp); im 2623 ext/gd/gd.c (*func_p)(im, tmp, q, t); im 2626 ext/gd/gd.c (*func_p)(im, tmp); im 2727 ext/gd/gd.c gdImagePtr im; im 2733 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2750 ext/gd/gd.c gdImagePtr im; im 2757 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2761 ext/gd/gd.c ct = gdImageColorAllocate(im, red, green, blue); im 2798 ext/gd/gd.c gdImagePtr im; im 2804 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2808 ext/gd/gd.c if (gdImageTrueColor(im)) { im 2809 ext/gd/gd.c if (im->tpixels && gdImageBoundsSafe(im, x, y)) { im 2810 ext/gd/gd.c RETURN_LONG(gdImageTrueColorPixel(im, x, y)); im 2816 ext/gd/gd.c if (im->pixels && gdImageBoundsSafe(im, x, y)) { im 2817 ext/gd/gd.c RETURN_LONG(im->pixels[y][x]); im 2832 ext/gd/gd.c gdImagePtr im; im 2838 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2842 ext/gd/gd.c RETURN_LONG(gdImageColorClosest(im, red, green, blue)); im 2852 ext/gd/gd.c gdImagePtr im; im 2858 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2862 ext/gd/gd.c RETURN_LONG(gdImageColorClosestHWB(im, red, green, blue)); im 2873 ext/gd/gd.c gdImagePtr im; im 2879 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2884 ext/gd/gd.c if (gdImageTrueColor(im)) { im 2890 ext/gd/gd.c if (col >= 0 && col < gdImageColorsTotal(im)) { im 2891 ext/gd/gd.c gdImageColorDeallocate(im, col); im 2906 ext/gd/gd.c gdImagePtr im; im 2912 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2916 ext/gd/gd.c RETURN_LONG(gdImageColorResolve(im, red, green, blue)); im 2926 ext/gd/gd.c gdImagePtr im; im 2932 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2936 ext/gd/gd.c RETURN_LONG(gdImageColorExact(im, red, green, blue)); im 2947 ext/gd/gd.c gdImagePtr im; im 2953 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2959 ext/gd/gd.c if (col >= 0 && col < gdImageColorsTotal(im)) { im 2960 ext/gd/gd.c im->red[col] = red; im 2961 ext/gd/gd.c im->green[col] = green; im 2962 ext/gd/gd.c im->blue[col] = blue; im 2963 ext/gd/gd.c im->alpha[col] = alpha; im 2977 ext/gd/gd.c gdImagePtr im; im 2983 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 2989 ext/gd/gd.c if ((col >= 0 && gdImageTrueColor(im)) || (!gdImageTrueColor(im) && col >= 0 && col < gdImageColorsTotal(im))) { im 2992 ext/gd/gd.c add_assoc_long(return_value,"red", gdImageRed(im,col)); im 2993 ext/gd/gd.c add_assoc_long(return_value,"green", gdImageGreen(im,col)); im 2994 ext/gd/gd.c add_assoc_long(return_value,"blue", gdImageBlue(im,col)); im 2995 ext/gd/gd.c add_assoc_long(return_value,"alpha", gdImageAlpha(im,col)); im 3008 ext/gd/gd.c gdImagePtr im; im 3016 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3020 ext/gd/gd.c if (gdImageTrueColor(im)) { im 3023 ext/gd/gd.c for (y = 0; y < gdImageSY(im); y++) { im 3024 ext/gd/gd.c for (x = 0; x < gdImageSX(im); x++) { im 3025 ext/gd/gd.c c = gdImageGetPixel(im, x, y); im 3026 ext/gd/gd.c gdImageSetPixel(im, x, y, im 3039 ext/gd/gd.c for (i = 0; i < gdImageColorsTotal(im); i++) { im 3040 ext/gd/gd.c im->red[i] = (int)((pow((pow((im->red[i] / 255.0), input)), 1.0 / output) * 255) + .5); im 3041 ext/gd/gd.c im->green[i] = (int)((pow((pow((im->green[i] / 255.0), input)), 1.0 / output) * 255) + .5); im 3042 ext/gd/gd.c im->blue[i] = (int)((pow((pow((im->blue[i] / 255.0), input)), 1.0 / output) * 255) + .5); im 3055 ext/gd/gd.c gdImagePtr im; im 3061 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3065 ext/gd/gd.c gdImageSetPixel(im, x, y, col); im 3076 ext/gd/gd.c gdImagePtr im; im 3082 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3087 ext/gd/gd.c if (im->antialias) { im 3088 ext/gd/gd.c gdImageAALine(im, x1, y1, x2, y2, col); im 3092 ext/gd/gd.c gdImageLine(im, x1, y1, x2, y2, col); im 3104 ext/gd/gd.c gdImagePtr im; im 3110 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3114 ext/gd/gd.c gdImageDashedLine(im, x1, y1, x2, y2, col); im 3125 ext/gd/gd.c gdImagePtr im; im 3131 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3135 ext/gd/gd.c gdImageRectangle(im, x1, y1, x2, y2, col); im 3146 ext/gd/gd.c gdImagePtr im; im 3152 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3155 ext/gd/gd.c gdImageFilledRectangle(im, x1, y1, x2, y2, col); im 3166 ext/gd/gd.c gdImagePtr im; im 3173 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3187 ext/gd/gd.c gdImageArc(im, cx, cy, w, h, st, e, col); im 3198 ext/gd/gd.c gdImagePtr im; im 3204 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3208 ext/gd/gd.c gdImageEllipse(im, cx, cy, w, h, color); im 3219 ext/gd/gd.c gdImagePtr im; im 3225 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3229 ext/gd/gd.c gdImageFillToBorder(im, x, y, border, col); im 3240 ext/gd/gd.c gdImagePtr im; im 3246 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3250 ext/gd/gd.c gdImageFill(im, x, y, col); im 3260 ext/gd/gd.c gdImagePtr im; im 3266 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3270 ext/gd/gd.c RETURN_LONG(gdImageColorsTotal(im)); im 3280 ext/gd/gd.c gdImagePtr im; im 3287 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3292 ext/gd/gd.c gdImageColorTransparent(im, COL); im 3295 ext/gd/gd.c RETURN_LONG(gdImageGetTransparent(im)); im 3306 ext/gd/gd.c gdImagePtr im; im 3312 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3317 ext/gd/gd.c gdImageInterlace(im, INT); im 3320 ext/gd/gd.c RETURN_LONG(gdImageGetInterlaced(im)); im 3333 ext/gd/gd.c gdImagePtr im; im 3341 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3374 ext/gd/gd.c gdImageFilledPolygon(im, points, npoints, col); im 3376 ext/gd/gd.c gdImagePolygon(im, points, npoints, col); im 3477 ext/gd/gd.c static void php_gdimagecharup(gdImagePtr im, gdFontPtr f, int x, int y, int c, int color) im 3491 ext/gd/gd.c gdImageSetPixel(im, px, py, color); im 3513 ext/gd/gd.c gdImagePtr im; im 3522 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3543 ext/gd/gd.c gdImageChar(im, font, x, y, ch, col); im 3546 ext/gd/gd.c php_gdimagecharup(im, font, x, y, ch, col); im 3550 ext/gd/gd.c gdImageChar(im, font, x, y, (int) ((unsigned char) str[i]), col); im 3557 ext/gd/gd.c gdImageCharUp(im, font, x, y, (int) str[i], col); im 3748 ext/gd/gd.c gdImagePtr im; im 3754 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3758 ext/gd/gd.c RETURN_LONG(gdImageSX(im)); im 3767 ext/gd/gd.c gdImagePtr im; im 3773 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3777 ext/gd/gd.c RETURN_LONG(gdImageSY(im)); im 3827 ext/gd/gd.c gdImagePtr im=NULL; im 3849 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 3887 ext/gd/gd.c error = gdImageStringFTEx(im, brect, col, fontname, ptsize, angle, x, y, str, &strex); im 3890 ext/gd/gd.c error = gdImageStringFT(im, brect, col, fontname, ptsize, angle, x, y, str); im 4360 ext/gd/gd.c gdImagePtr im; im 4368 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 4372 ext/gd/gd.c if (im == NULL) { im 4376 ext/gd/gd.c if (gdImagePixelate(im, (int) blocksize, (const unsigned int) mode)) { im 4478 ext/gd/gd.c gdImagePtr im; im 4484 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 4490 ext/gd/gd.c gdImageFlipVertical(im); im 4494 ext/gd/gd.c gdImageFlipHorizontal(im); im 4498 ext/gd/gd.c gdImageFlipBoth(im); im 4517 ext/gd/gd.c gdImagePtr im; im 4523 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 4526 ext/gd/gd.c gdImageAntialias(im, alias); im 4537 ext/gd/gd.c gdImagePtr im; im 4547 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 4579 ext/gd/gd.c im_crop = gdImageCrop(im, &rect); im 4597 ext/gd/gd.c gdImagePtr im; im 4604 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 4616 ext/gd/gd.c im_crop = gdImageCropAuto(im, mode); im 4624 ext/gd/gd.c im_crop = gdImageCropThreshold(im, color, (float) threshold); im 4644 ext/gd/gd.c gdImagePtr im; im 4655 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 4663 ext/gd/gd.c src_x = gdImageSX(im); im 4664 ext/gd/gd.c src_y = gdImageSY(im); im 4673 ext/gd/gd.c if (gdImageSetInterpolationMethod(im, method)) { im 4674 ext/gd/gd.c im_scaled = gdImageScale(im, new_width, new_height); im 4935 ext/gd/gd.c gdImagePtr im; im 4942 ext/gd/gd.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(IM), "Image", le_gd)) == NULL) { im 4949 ext/gd/gd.c RETURN_BOOL(gdImageSetInterpolationMethod(im, (gdInterpolationMethod) method)); im 78 ext/gd/gd_ctx.c gdImagePtr im; im 106 ext/gd/gd_ctx.c if ((im = (gdImagePtr)zend_fetch_resource(Z_RES_P(imgind), "Image", phpi_get_le_gd())) == NULL) { im 169 ext/gd/gd_ctx.c (*func_p)(im, ctx, q); im 175 ext/gd/gd_ctx.c (*func_p)(im, ctx, q); im 178 ext/gd/gd_ctx.c (*func_p)(im, ctx, q, f); im 183 ext/gd/gd_ctx.c for(i=0; i < gdImageColorsTotal(im); i++) { im 184 ext/gd/gd_ctx.c if(!gdImageRed(im, i) && !gdImageGreen(im, i) && !gdImageBlue(im, i)) break; im 189 ext/gd/gd_ctx.c (*func_p)(im, file ? file : "", q, ctx); im 191 ext/gd/gd_ctx.c (*func_p)(im, q, ctx); im 195 ext/gd/gd_ctx.c (*func_p)(im, ctx); im 94 ext/gd/libgd/gd.c static void gdImageBrushApply(gdImagePtr im, int x, int y); im 95 ext/gd/libgd/gd.c static void gdImageTileApply(gdImagePtr im, int x, int y); im 96 ext/gd/libgd/gd.c static void gdImageAntiAliasedApply(gdImagePtr im, int x, int y); im 99 ext/gd/libgd/gd.c int gdImageGetTrueColorPixel(gdImagePtr im, int x, int y); im 124 ext/gd/libgd/gd.c gdImagePtr im; im 134 ext/gd/libgd/gd.c im = (gdImage *) gdCalloc(1, sizeof(gdImage)); im 137 ext/gd/libgd/gd.c im->pixels = (unsigned char **) gdMalloc(sizeof(unsigned char *) * sy); im 138 ext/gd/libgd/gd.c im->AA_opacity = (unsigned char **) gdMalloc(sizeof(unsigned char *) * sy); im 139 ext/gd/libgd/gd.c im->polyInts = 0; im 140 ext/gd/libgd/gd.c im->polyAllocated = 0; im 141 ext/gd/libgd/gd.c im->brush = 0; im 142 ext/gd/libgd/gd.c im->tile = 0; im 143 ext/gd/libgd/gd.c im->style = 0; im 146 ext/gd/libgd/gd.c im->pixels[i] = (unsigned char *) gdCalloc(sx, sizeof(unsigned char)); im 147 ext/gd/libgd/gd.c im->AA_opacity[i] = (unsigned char *) gdCalloc(sx, sizeof(unsigned char)); im 149 ext/gd/libgd/gd.c im->sx = sx; im 150 ext/gd/libgd/gd.c im->sy = sy; im 151 ext/gd/libgd/gd.c im->colorsTotal = 0; im 152 ext/gd/libgd/gd.c im->transparent = (-1); im 153 ext/gd/libgd/gd.c im->interlace = 0; im 154 ext/gd/libgd/gd.c im->thick = 1; im 155 ext/gd/libgd/gd.c im->AA = 0; im 156 ext/gd/libgd/gd.c im->AA_polygon = 0; im 158 ext/gd/libgd/gd.c im->open[i] = 1; im 159 ext/gd/libgd/gd.c im->red[i] = 0; im 160 ext/gd/libgd/gd.c im->green[i] = 0; im 161 ext/gd/libgd/gd.c im->blue[i] = 0; im 163 ext/gd/libgd/gd.c im->trueColor = 0; im 164 ext/gd/libgd/gd.c im->tpixels = 0; im 165 ext/gd/libgd/gd.c im->cx1 = 0; im 166 ext/gd/libgd/gd.c im->cy1 = 0; im 167 ext/gd/libgd/gd.c im->cx2 = im->sx - 1; im 168 ext/gd/libgd/gd.c im->cy2 = im->sy - 1; im 169 ext/gd/libgd/gd.c im->interpolation = NULL; im 170 ext/gd/libgd/gd.c im->interpolation_id = GD_BILINEAR_FIXED; im 171 ext/gd/libgd/gd.c return im; im 177 ext/gd/libgd/gd.c gdImagePtr im; im 191 ext/gd/libgd/gd.c im = (gdImage *) gdMalloc(sizeof(gdImage)); im 192 ext/gd/libgd/gd.c memset(im, 0, sizeof(gdImage)); im 193 ext/gd/libgd/gd.c im->tpixels = (int **) gdMalloc(sizeof(int *) * sy); im 194 ext/gd/libgd/gd.c im->AA_opacity = (unsigned char **) gdMalloc(sizeof(unsigned char *) * sy); im 195 ext/gd/libgd/gd.c im->polyInts = 0; im 196 ext/gd/libgd/gd.c im->polyAllocated = 0; im 197 ext/gd/libgd/gd.c im->brush = 0; im 198 ext/gd/libgd/gd.c im->tile = 0; im 199 ext/gd/libgd/gd.c im->style = 0; im 201 ext/gd/libgd/gd.c im->tpixels[i] = (int *) gdCalloc(sx, sizeof(int)); im 202 ext/gd/libgd/gd.c im->AA_opacity[i] = (unsigned char *) gdCalloc(sx, sizeof(unsigned char)); im 204 ext/gd/libgd/gd.c im->sx = sx; im 205 ext/gd/libgd/gd.c im->sy = sy; im 206 ext/gd/libgd/gd.c im->transparent = (-1); im 207 ext/gd/libgd/gd.c im->interlace = 0; im 208 ext/gd/libgd/gd.c im->trueColor = 1; im 215 ext/gd/libgd/gd.c im->saveAlphaFlag = 0; im 216 ext/gd/libgd/gd.c im->alphaBlendingFlag = 1; im 217 ext/gd/libgd/gd.c im->thick = 1; im 218 ext/gd/libgd/gd.c im->AA = 0; im 219 ext/gd/libgd/gd.c im->AA_polygon = 0; im 220 ext/gd/libgd/gd.c im->cx1 = 0; im 221 ext/gd/libgd/gd.c im->cy1 = 0; im 222 ext/gd/libgd/gd.c im->cx2 = im->sx - 1; im 223 ext/gd/libgd/gd.c im->cy2 = im->sy - 1; im 224 ext/gd/libgd/gd.c im->interpolation = NULL; im 225 ext/gd/libgd/gd.c im->interpolation_id = GD_BILINEAR_FIXED; im 226 ext/gd/libgd/gd.c return im; im 229 ext/gd/libgd/gd.c void gdImageDestroy (gdImagePtr im) im 232 ext/gd/libgd/gd.c if (im->pixels) { im 233 ext/gd/libgd/gd.c for (i = 0; i < im->sy; i++) { im 234 ext/gd/libgd/gd.c gdFree(im->pixels[i]); im 236 ext/gd/libgd/gd.c gdFree(im->pixels); im 238 ext/gd/libgd/gd.c if (im->tpixels) { im 239 ext/gd/libgd/gd.c for (i = 0; i < im->sy; i++) { im 240 ext/gd/libgd/gd.c gdFree(im->tpixels[i]); im 242 ext/gd/libgd/gd.c gdFree(im->tpixels); im 244 ext/gd/libgd/gd.c if (im->AA_opacity) { im 245 ext/gd/libgd/gd.c for (i = 0; i < im->sy; i++) { im 246 ext/gd/libgd/gd.c gdFree(im->AA_opacity[i]); im 248 ext/gd/libgd/gd.c gdFree(im->AA_opacity); im 250 ext/gd/libgd/gd.c if (im->polyInts) { im 251 ext/gd/libgd/gd.c gdFree(im->polyInts); im 253 ext/gd/libgd/gd.c if (im->style) { im 254 ext/gd/libgd/gd.c gdFree(im->style); im 256 ext/gd/libgd/gd.c gdFree(im); im 259 ext/gd/libgd/gd.c int gdImageColorClosest (gdImagePtr im, int r, int g, int b) im 261 ext/gd/libgd/gd.c return gdImageColorClosestAlpha (im, r, g, b, gdAlphaOpaque); im 264 ext/gd/libgd/gd.c int gdImageColorClosestAlpha (gdImagePtr im, int r, int g, int b, int a) im 272 ext/gd/libgd/gd.c if (im->trueColor) { im 275 ext/gd/libgd/gd.c for (i = 0; i < im->colorsTotal; i++) { im 277 ext/gd/libgd/gd.c if (im->open[i]) { im 280 ext/gd/libgd/gd.c rd = im->red[i] - r; im 281 ext/gd/libgd/gd.c gd = im->green[i] - g; im 282 ext/gd/libgd/gd.c bd = im->blue[i] - b; im 284 ext/gd/libgd/gd.c ad = im->alpha[i] - a; im 430 ext/gd/libgd/gd.c int gdImageColorClosestHWB (gdImagePtr im, int r, int g, int b) im 437 ext/gd/libgd/gd.c if (im->trueColor) { im 440 ext/gd/libgd/gd.c for (i = 0; i < im->colorsTotal; i++) { im 442 ext/gd/libgd/gd.c if (im->open[i]) { im 445 ext/gd/libgd/gd.c dist = HWB_Diff(im->red[i], im->green[i], im->blue[i], r, g, b); im 455 ext/gd/libgd/gd.c int gdImageColorExact (gdImagePtr im, int r, int g, int b) im 457 ext/gd/libgd/gd.c return gdImageColorExactAlpha (im, r, g, b, gdAlphaOpaque); im 460 ext/gd/libgd/gd.c int gdImageColorExactAlpha (gdImagePtr im, int r, int g, int b, int a) im 463 ext/gd/libgd/gd.c if (im->trueColor) { im 466 ext/gd/libgd/gd.c for (i = 0; i < im->colorsTotal; i++) { im 467 ext/gd/libgd/gd.c if (im->open[i]) { im 470 ext/gd/libgd/gd.c if ((im->red[i] == r) && (im->green[i] == g) && (im->blue[i] == b) && (im->alpha[i] == a)) { im 477 ext/gd/libgd/gd.c int gdImageColorAllocate (gdImagePtr im, int r, int g, int b) im 479 ext/gd/libgd/gd.c return gdImageColorAllocateAlpha (im, r, g, b, gdAlphaOpaque); im 482 ext/gd/libgd/gd.c int gdImageColorAllocateAlpha (gdImagePtr im, int r, int g, int b, int a) im 486 ext/gd/libgd/gd.c if (im->trueColor) { im 489 ext/gd/libgd/gd.c for (i = 0; i < im->colorsTotal; i++) { im 490 ext/gd/libgd/gd.c if (im->open[i]) { im 496 ext/gd/libgd/gd.c ct = im->colorsTotal; im 500 ext/gd/libgd/gd.c im->colorsTotal++; im 502 ext/gd/libgd/gd.c im->red[ct] = r; im 503 ext/gd/libgd/gd.c im->green[ct] = g; im 504 ext/gd/libgd/gd.c im->blue[ct] = b; im 505 ext/gd/libgd/gd.c im->alpha[ct] = a; im 506 ext/gd/libgd/gd.c im->open[ct] = 0; im 522 ext/gd/libgd/gd.c int gdImageColorResolve (gdImagePtr im, int r, int g, int b) im 524 ext/gd/libgd/gd.c return gdImageColorResolveAlpha(im, r, g, b, gdAlphaOpaque); im 527 ext/gd/libgd/gd.c int gdImageColorResolveAlpha (gdImagePtr im, int r, int g, int b, int a) im 534 ext/gd/libgd/gd.c if (im->trueColor) im 539 ext/gd/libgd/gd.c for (c = 0; c < im->colorsTotal; c++) im 541 ext/gd/libgd/gd.c if (im->open[c]) im 546 ext/gd/libgd/gd.c if (c == im->transparent) im 552 ext/gd/libgd/gd.c rd = (long) (im->red[c] - r); im 553 ext/gd/libgd/gd.c gd = (long) (im->green[c] - g); im 554 ext/gd/libgd/gd.c bd = (long) (im->blue[c] - b); im 555 ext/gd/libgd/gd.c ad = (long) (im->alpha[c] - a); im 570 ext/gd/libgd/gd.c op = im->colorsTotal; im 575 ext/gd/libgd/gd.c im->colorsTotal++; im 577 ext/gd/libgd/gd.c im->red[op] = r; im 578 ext/gd/libgd/gd.c im->green[op] = g; im 579 ext/gd/libgd/gd.c im->blue[op] = b; im 580 ext/gd/libgd/gd.c im->alpha[op] = a; im 581 ext/gd/libgd/gd.c im->open[op] = 0; im 585 ext/gd/libgd/gd.c void gdImageColorDeallocate (gdImagePtr im, int color) im 587 ext/gd/libgd/gd.c if (im->trueColor) { im 591 ext/gd/libgd/gd.c im->open[color] = 1; im 594 ext/gd/libgd/gd.c void gdImageColorTransparent (gdImagePtr im, int color) im 596 ext/gd/libgd/gd.c if (!im->trueColor) { im 597 ext/gd/libgd/gd.c if (im->transparent != -1) { im 598 ext/gd/libgd/gd.c im->alpha[im->transparent] = gdAlphaOpaque; im 600 ext/gd/libgd/gd.c if (color > -1 && color < im->colorsTotal && color < gdMaxColors) { im 601 ext/gd/libgd/gd.c im->alpha[color] = gdAlphaTransparent; im 606 ext/gd/libgd/gd.c im->transparent = color; im 718 ext/gd/libgd/gd.c void gdImageSetPixel (gdImagePtr im, int x, int y, int color) im 723 ext/gd/libgd/gd.c if (!im->style) { im 727 ext/gd/libgd/gd.c p = im->style[im->stylePos++]; im 730 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y, p); im 732 ext/gd/libgd/gd.c im->stylePos = im->stylePos % im->styleLength; im 735 ext/gd/libgd/gd.c if (!im->style) { im 739 ext/gd/libgd/gd.c p = im->style[im->stylePos++]; im 741 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y, gdBrushed); im 743 ext/gd/libgd/gd.c im->stylePos = im->stylePos % im->styleLength; im 746 ext/gd/libgd/gd.c gdImageBrushApply(im, x, y); im 749 ext/gd/libgd/gd.c gdImageTileApply(im, x, y); im 752 ext/gd/libgd/gd.c gdImageAntiAliasedApply(im, x, y); im 755 ext/gd/libgd/gd.c if (gdImageBoundsSafe(im, x, y)) { im 756 ext/gd/libgd/gd.c if (im->trueColor) { im 757 ext/gd/libgd/gd.c switch (im->alphaBlendingFlag) { im 760 ext/gd/libgd/gd.c im->tpixels[y][x] = color; im 763 ext/gd/libgd/gd.c im->tpixels[y][x] = gdAlphaBlend(im->tpixels[y][x], color); im 766 ext/gd/libgd/gd.c im->tpixels[y][x] = gdAlphaBlend(im->tpixels[y][x], color); im 769 ext/gd/libgd/gd.c im->tpixels[y][x] = gdLayerOverlay(im->tpixels[y][x], color); im 773 ext/gd/libgd/gd.c im->pixels[y][x] = color; im 780 ext/gd/libgd/gd.c int gdImageGetTrueColorPixel (gdImagePtr im, int x, int y) im 782 ext/gd/libgd/gd.c int p = gdImageGetPixel(im, x, y); im 784 ext/gd/libgd/gd.c if (!im->trueColor) { im 785 ext/gd/libgd/gd.c return gdTrueColorAlpha(im->red[p], im->green[p], im->blue[p], (im->transparent == p) ? gdAlphaTransparent : im->alpha[p]); im 791 ext/gd/libgd/gd.c static void gdImageBrushApply (gdImagePtr im, int x, int y) im 798 ext/gd/libgd/gd.c if (!im->brush) { im 802 ext/gd/libgd/gd.c hy = gdImageSY(im->brush) / 2; im 804 ext/gd/libgd/gd.c y2 = y1 + gdImageSY(im->brush); im 805 ext/gd/libgd/gd.c hx = gdImageSX(im->brush) / 2; im 807 ext/gd/libgd/gd.c x2 = x1 + gdImageSX(im->brush); im 810 ext/gd/libgd/gd.c if (im->trueColor) { im 811 ext/gd/libgd/gd.c if (im->brush->trueColor) { im 816 ext/gd/libgd/gd.c p = gdImageGetTrueColorPixel(im->brush, srcx, srcy); im 818 ext/gd/libgd/gd.c if (p != gdImageGetTransparent(im->brush)) { im 819 ext/gd/libgd/gd.c gdImageSetPixel(im, lx, ly, p); im 831 ext/gd/libgd/gd.c p = gdImageGetPixel(im->brush, srcx, srcy); im 832 ext/gd/libgd/gd.c tc = gdImageGetTrueColorPixel(im->brush, srcx, srcy); im 834 ext/gd/libgd/gd.c if (p != gdImageGetTransparent(im->brush)) { im 835 ext/gd/libgd/gd.c gdImageSetPixel(im, lx, ly, tc); im 847 ext/gd/libgd/gd.c p = gdImageGetPixel(im->brush, srcx, srcy); im 849 ext/gd/libgd/gd.c if (p != gdImageGetTransparent(im->brush)) { im 851 ext/gd/libgd/gd.c if (im->brush->trueColor) { im 852 ext/gd/libgd/gd.c gdImageSetPixel(im, lx, ly, gdImageColorResolveAlpha(im, gdTrueColorGetRed(p), im 857 ext/gd/libgd/gd.c gdImageSetPixel(im, lx, ly, im->brushColorMap[p]); im 867 ext/gd/libgd/gd.c static void gdImageTileApply (gdImagePtr im, int x, int y) im 869 ext/gd/libgd/gd.c gdImagePtr tile = im->tile; im 877 ext/gd/libgd/gd.c if (im->trueColor) { im 883 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y, p); im 891 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y, gdImageColorResolveAlpha(im, im 897 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y, im->tileColorMap[p]); im 904 ext/gd/libgd/gd.c static int gdImageTileGet (gdImagePtr im, int x, int y) im 908 ext/gd/libgd/gd.c if (!im->tile) { im 911 ext/gd/libgd/gd.c srcx = x % gdImageSX(im->tile); im 912 ext/gd/libgd/gd.c srcy = y % gdImageSY(im->tile); im 913 ext/gd/libgd/gd.c p = gdImageGetPixel(im->tile, srcx, srcy); im 915 ext/gd/libgd/gd.c if (im->trueColor) { im 916 ext/gd/libgd/gd.c if (im->tile->trueColor) { im 919 ext/gd/libgd/gd.c tileColor = gdTrueColorAlpha( gdImageRed(im->tile,p), gdImageGreen(im->tile,p), gdImageBlue (im->tile,p), gdImageAlpha (im->tile,p)); im 922 ext/gd/libgd/gd.c if (im->tile->trueColor) { im 923 ext/gd/libgd/gd.c tileColor = gdImageColorResolveAlpha(im, gdTrueColorGetRed (p), gdTrueColorGetGreen (p), gdTrueColorGetBlue (p), gdTrueColorGetAlpha (p)); im 926 ext/gd/libgd/gd.c tileColor = gdImageColorResolveAlpha(im, gdImageRed (im->tile,p), gdImageGreen (im->tile,p), gdImageBlue (im->tile,p), gdImageAlpha (im->tile,p)); im 933 ext/gd/libgd/gd.c static void gdImageAntiAliasedApply (gdImagePtr im, int px, int py) im 946 ext/gd/libgd/gd.c int Ax_Cx = im->AAL_x1 - px; im 947 ext/gd/libgd/gd.c int Ay_Cy = im->AAL_y1 - py; im 949 ext/gd/libgd/gd.c int Bx_Cx = im->AAL_x2 - px; im 950 ext/gd/libgd/gd.c int By_Cy = im->AAL_y2 - py; im 957 ext/gd/libgd/gd.c if (!gdImageBoundsSafe(im, px, py)) { im 965 ext/gd/libgd/gd.c if (((im->AAL_LAB_2 + LAC_2) >= LBC_2) && ((im->AAL_LAB_2 + LBC_2) >= LAC_2)) { im 969 ext/gd/libgd/gd.c p_dist = fabs ((float) ((Ay_Cy * im->AAL_Bx_Ax) - (Ax_Cx * im->AAL_By_Ay)) / im->AAL_LAB); im 978 ext/gd/libgd/gd.c if ((p_dist >= 0) && (p_dist <= (float) (im->thick))) { im 987 ext/gd/libgd/gd.c if (!im->AA_polygon || (im->AA_opacity[py][px] < opacity)) { im 988 ext/gd/libgd/gd.c im->AA_opacity[py][px] = opacity; im 995 ext/gd/libgd/gd.c int gdImageGetPixel (gdImagePtr im, int x, int y) im 997 ext/gd/libgd/gd.c if (gdImageBoundsSafe(im, x, y)) { im 998 ext/gd/libgd/gd.c if (im->trueColor) { im 999 ext/gd/libgd/gd.c return im->tpixels[y][x]; im 1001 ext/gd/libgd/gd.c return im->pixels[y][x]; im 1008 ext/gd/libgd/gd.c void gdImageAABlend (gdImagePtr im) im 1011 ext/gd/libgd/gd.c int color = im->AA_color, color_red, color_green, color_blue; im 1016 ext/gd/libgd/gd.c color_red = gdImageRed(im, color); im 1017 ext/gd/libgd/gd.c color_green = gdImageGreen(im, color); im 1018 ext/gd/libgd/gd.c color_blue = gdImageBlue(im, color); im 1021 ext/gd/libgd/gd.c for (py = 0; py < im->sy; py++) { im 1022 ext/gd/libgd/gd.c for (px = 0; px < im->sx; px++) { im 1023 ext/gd/libgd/gd.c if (im->AA_opacity[py][px] != 0) { im 1024 ext/gd/libgd/gd.c old_color = gdImageGetPixel(im, px, py); im 1026 ext/gd/libgd/gd.c if ((old_color != color) && ((old_color != im->AA_dont_blend) || (im->AA_opacity[py][px] == 255))) { im 1028 ext/gd/libgd/gd.c p_alpha = (float) (im->AA_opacity[py][px]) / 255.0; im 1034 ext/gd/libgd/gd.c old_red = gdImageRed(im, old_color); im 1035 ext/gd/libgd/gd.c old_green = gdImageGreen(im, old_color); im 1036 ext/gd/libgd/gd.c old_blue = gdImageBlue(im, old_color); im 1041 ext/gd/libgd/gd.c p_color = gdImageColorResolve(im, p_red, p_green, p_blue); im 1043 ext/gd/libgd/gd.c gdImageSetPixel(im, px, py, p_color); im 1048 ext/gd/libgd/gd.c memset(im->AA_opacity[py], 0, im->sx); im 1052 ext/gd/libgd/gd.c static void gdImageHLine(gdImagePtr im, int y, int x1, int x2, int col) im 1054 ext/gd/libgd/gd.c if (im->thick > 1) { im 1055 ext/gd/libgd/gd.c int thickhalf = im->thick >> 1; im 1056 ext/gd/libgd/gd.c gdImageFilledRectangle(im, x1, y - thickhalf, x2, y + im->thick - thickhalf - 1, col); im 1065 ext/gd/libgd/gd.c gdImageSetPixel(im, x1, y, col); im 1071 ext/gd/libgd/gd.c static void gdImageVLine(gdImagePtr im, int x, int y1, int y2, int col) im 1073 ext/gd/libgd/gd.c if (im->thick > 1) { im 1074 ext/gd/libgd/gd.c int thickhalf = im->thick >> 1; im 1075 ext/gd/libgd/gd.c gdImageFilledRectangle(im, x - thickhalf, y1, x + im->thick - thickhalf - 1, y2, col); im 1084 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y1, col); im 1091 ext/gd/libgd/gd.c void gdImageLine (gdImagePtr im, int x1, int y1, int x2, int y2, int color) im 1096 ext/gd/libgd/gd.c int thick = im->thick; im 1104 ext/gd/libgd/gd.c gdImageAALine(im, x1, y1, x2, y2, im->AA_color); im 1109 ext/gd/libgd/gd.c if (!clip_1d(&x1,&y1,&x2,&y2,gdImageSX(im)) || !clip_1d(&y1,&x1,&y2,&x2,gdImageSY(im))) { im 1117 ext/gd/libgd/gd.c gdImageVLine(im, x1, y1, y2, color); im 1120 ext/gd/libgd/gd.c gdImageHLine(im, y1, x1, x2, color); im 1160 ext/gd/libgd/gd.c gdImageSetPixel(im, x, w, color); im 1174 ext/gd/libgd/gd.c gdImageSetPixel (im, x, w, color); im 1188 ext/gd/libgd/gd.c gdImageSetPixel (im, x, w, color); im 1224 ext/gd/libgd/gd.c gdImageSetPixel (im, w, y, color); im 1238 ext/gd/libgd/gd.c gdImageSetPixel (im, w, y, color); im 1252 ext/gd/libgd/gd.c gdImageSetPixel (im, w, y, color); im 1266 ext/gd/libgd/gd.c inline static void gdImageSetAAPixelColor(gdImagePtr im, int x, int y, int color, int t) im 1273 ext/gd/libgd/gd.c p = gdImageGetPixel(im,x,y); im 1281 ext/gd/libgd/gd.c im->tpixels[y][x]=gdTrueColorAlpha(dr, dg, db, gdAlphaOpaque); im 1287 ext/gd/libgd/gd.c void gdImageAALine (gdImagePtr im, int x1, int y1, int x2, int y2, int col) im 1306 ext/gd/libgd/gd.c if (y1 >= im->sy && y2 >= im->sy) { im 1309 ext/gd/libgd/gd.c if (y1 >= im->sy) { im 1310 ext/gd/libgd/gd.c x1 -= ((im->sy - y1) * (x1 - x2)) / (y2 - y1); im 1311 ext/gd/libgd/gd.c y1 = im->sy - 1; im 1313 ext/gd/libgd/gd.c if (y2 >= im->sy) { im 1314 ext/gd/libgd/gd.c x2 -= ((im->sy - y2) * (x1 - x2)) / (y2 - y1); im 1315 ext/gd/libgd/gd.c y2 = im->sy - 1; im 1331 ext/gd/libgd/gd.c if (x1 >= im->sx && x2 >= im->sx) { im 1334 ext/gd/libgd/gd.c if (x1 >= im->sx) { im 1335 ext/gd/libgd/gd.c y1 -= ((im->sx - x1) * (y1 - y2)) / (x2 - x1); im 1336 ext/gd/libgd/gd.c x1 = im->sx - 1; im 1338 ext/gd/libgd/gd.c if (x2 >= im->sx) { im 1339 ext/gd/libgd/gd.c y2 -= ((im->sx - x2) * (y1 - y2)) / (x2 - x1); im 1340 ext/gd/libgd/gd.c x2 = im->sx - 1; im 1364 ext/gd/libgd/gd.c gdImageSetAAPixelColor(im, x >> 16, y >> 16, col, (y >> 8) & 0xFF); im 1365 ext/gd/libgd/gd.c if ((y >> 16) + 1 < im->sy) { im 1366 ext/gd/libgd/gd.c gdImageSetAAPixelColor(im, x >> 16, (y >> 16) + 1,col, (~y >> 8) & 0xFF); im 1386 ext/gd/libgd/gd.c gdImageSetAAPixelColor(im, x >> 16, y >> 16, col, (x >> 8) & 0xFF); im 1387 ext/gd/libgd/gd.c if ((x >> 16) + 1 < im->sx) { im 1388 ext/gd/libgd/gd.c gdImageSetAAPixelColor(im, (x >> 16) + 1, (y >> 16),col, (~x >> 8) & 0xFF); im 1396 ext/gd/libgd/gd.c static void dashedSet (gdImagePtr im, int x, int y, int color, int *onP, int *dashStepP, int wid, int vert); im 1398 ext/gd/libgd/gd.c void gdImageDashedLine (gdImagePtr im, int x1, int y1, int x2, int y2, int color) im 1405 ext/gd/libgd/gd.c int thick = im->thick; im 1436 ext/gd/libgd/gd.c dashedSet(im, x, y, color, &on, &dashStep, wid, vert); im 1446 ext/gd/libgd/gd.c dashedSet(im, x, y, color, &on, &dashStep, wid, vert); im 1457 ext/gd/libgd/gd.c dashedSet(im, x, y, color, &on, &dashStep, wid, vert); im 1485 ext/gd/libgd/gd.c dashedSet(im, x, y, color, &on, &dashStep, wid, vert); im 1495 ext/gd/libgd/gd.c dashedSet(im, x, y, color, &on, &dashStep, wid, vert); im 1506 ext/gd/libgd/gd.c dashedSet(im, x, y, color, &on, &dashStep, wid, vert); im 1512 ext/gd/libgd/gd.c static void dashedSet (gdImagePtr im, int x, int y, int color, int *onP, int *dashStepP, int wid, int vert) im 1527 ext/gd/libgd/gd.c gdImageSetPixel(im, x, w, color); im 1532 ext/gd/libgd/gd.c gdImageSetPixel(im, w, y, color); im 1540 ext/gd/libgd/gd.c void gdImageChar (gdImagePtr im, gdFontPtr f, int x, int y, int c, int color) im 1557 ext/gd/libgd/gd.c gdImageSetPixel(im, px, py, color); im 1566 ext/gd/libgd/gd.c void gdImageCharUp (gdImagePtr im, gdFontPtr f, int x, int y, int c, int color) im 1583 ext/gd/libgd/gd.c gdImageSetPixel(im, px, py, color); im 1592 ext/gd/libgd/gd.c void gdImageString (gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color) im 1598 ext/gd/libgd/gd.c gdImageChar(im, f, x, y, s[i], color); im 1603 ext/gd/libgd/gd.c void gdImageStringUp (gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color) im 1609 ext/gd/libgd/gd.c gdImageCharUp(im, f, x, y, s[i], color); im 1616 ext/gd/libgd/gd.c void gdImageString16 (gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color) im 1622 ext/gd/libgd/gd.c gdImageChar(im, f, x, y, s[i], color); im 1627 ext/gd/libgd/gd.c void gdImageStringUp16 (gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color) im 1633 ext/gd/libgd/gd.c gdImageCharUp(im, f, x, y, s[i], color); im 1666 ext/gd/libgd/gd.c void gdImageArc (gdImagePtr im, int cx, int cy, int w, int h, int s, int e, int color) im 1669 ext/gd/libgd/gd.c gdImageEllipse(im, cx, cy, w, h, color); im 1671 ext/gd/libgd/gd.c gdImageFilledArc(im, cx, cy, w, h, s, e, color, gdNoFill); im 1675 ext/gd/libgd/gd.c void gdImageFilledArc (gdImagePtr im, int cx, int cy, int w, int h, int s, int e, int color, int style) im 1713 ext/gd/libgd/gd.c gdImageLine(im, lx, ly, x, y, color); im 1722 ext/gd/libgd/gd.c gdImageFilledPolygon(im, pts, 3, color); im 1735 ext/gd/libgd/gd.c gdImageLine(im, cx, cy, lx, ly, color); im 1736 ext/gd/libgd/gd.c gdImageLine(im, cx, cy, fx, fy, color); im 1738 ext/gd/libgd/gd.c gdImageLine(im, fx, fy, lx, ly, color); im 1746 ext/gd/libgd/gd.c gdImageFilledPolygon(im, pts, 3, color); im 1751 ext/gd/libgd/gd.c gdImageLine(im, cx, cy, lx, ly, color); im 1752 ext/gd/libgd/gd.c gdImageLine(im, cx, cy, fx, fy, color); im 1758 ext/gd/libgd/gd.c void gdImageFillToBorder (gdImagePtr im, int x, int y, int border, int color) im 1770 ext/gd/libgd/gd.c restoreAlphaBlending = im->alphaBlendingFlag; im 1771 ext/gd/libgd/gd.c im->alphaBlendingFlag = 0; im 1773 ext/gd/libgd/gd.c if (x >= im->sx) { im 1774 ext/gd/libgd/gd.c x = im->sx - 1; im 1778 ext/gd/libgd/gd.c if (y >= im->sy) { im 1779 ext/gd/libgd/gd.c y = im->sy - 1; im 1785 ext/gd/libgd/gd.c if (gdImageGetPixel(im, i, y) == border) { im 1788 ext/gd/libgd/gd.c gdImageSetPixel(im, i, y, color); im 1792 ext/gd/libgd/gd.c im->alphaBlendingFlag = restoreAlphaBlending; im 1797 ext/gd/libgd/gd.c for (i = (x + 1); i < im->sx; i++) { im 1798 ext/gd/libgd/gd.c if (gdImageGetPixel(im, i, y) == border) { im 1801 ext/gd/libgd/gd.c gdImageSetPixel(im, i, y, color); im 1809 ext/gd/libgd/gd.c int c = gdImageGetPixel(im, i, y - 1); im 1812 ext/gd/libgd/gd.c gdImageFillToBorder(im, i, y - 1, border, color); im 1822 ext/gd/libgd/gd.c if (y < ((im->sy) - 1)) { im 1825 ext/gd/libgd/gd.c int c = gdImageGetPixel(im, i, y + 1); im 1829 ext/gd/libgd/gd.c gdImageFillToBorder(im, i, y + 1, border, color); im 1837 ext/gd/libgd/gd.c im->alphaBlendingFlag = restoreAlphaBlending; im 1854 ext/gd/libgd/gd.c #define FILL_MAX ((int)(im->sy*im->sx)/4) im 1862 ext/gd/libgd/gd.c static void _gdImageFillTiled(gdImagePtr im, int x, int y, int nc); im 1864 ext/gd/libgd/gd.c void gdImageFill(gdImagePtr im, int x, int y, int nc) im 1877 ext/gd/libgd/gd.c if (!im->trueColor && nc > (im->colorsTotal -1)) { im 1881 ext/gd/libgd/gd.c alphablending_bak = im->alphaBlendingFlag; im 1882 ext/gd/libgd/gd.c im->alphaBlendingFlag = 0; im 1885 ext/gd/libgd/gd.c _gdImageFillTiled(im,x,y,nc); im 1886 ext/gd/libgd/gd.c im->alphaBlendingFlag = alphablending_bak; im 1890 ext/gd/libgd/gd.c wx2=im->sx;wy2=im->sy; im 1891 ext/gd/libgd/gd.c oc = gdImageGetPixel(im, x, y); im 1893 ext/gd/libgd/gd.c im->alphaBlendingFlag = alphablending_bak; im 1900 ext/gd/libgd/gd.c if (im->sx < 4) { im 1904 ext/gd/libgd/gd.c c = gdImageGetPixel(im, ix, iy); im 1908 ext/gd/libgd/gd.c gdImageSetPixel(im, ix, iy, nc); im 1909 ext/gd/libgd/gd.c } while(ix++ < (im->sx -1)); im 1911 ext/gd/libgd/gd.c } while(iy++ < (im->sy -1)); im 1915 ext/gd/libgd/gd.c stack = (struct seg *)safe_emalloc(sizeof(struct seg), ((int)(im->sy*im->sx)/4), 1); im 1925 ext/gd/libgd/gd.c for (x=x1; x>=0 && gdImageGetPixel(im,x, y)==oc; x--) { im 1926 ext/gd/libgd/gd.c gdImageSetPixel(im,x, y, nc); im 1939 ext/gd/libgd/gd.c for (; x<=wx2 && gdImageGetPixel(im,x, y)==oc; x++) { im 1940 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y, nc); im 1947 ext/gd/libgd/gd.c skip: for (x++; x<=x2 && (gdImageGetPixel(im, x, y)!=oc); x++); im 1956 ext/gd/libgd/gd.c im->alphaBlendingFlag = alphablending_bak; im 1959 ext/gd/libgd/gd.c static void _gdImageFillTiled(gdImagePtr im, int x, int y, int nc) im 1969 ext/gd/libgd/gd.c if (!im->tile) { im 1973 ext/gd/libgd/gd.c wx2=im->sx;wy2=im->sy; im 1975 ext/gd/libgd/gd.c nc = gdImageTileGet(im,x,y); im 1977 ext/gd/libgd/gd.c pts = (char **) ecalloc(im->sy + 1, sizeof(char *)); im 1978 ext/gd/libgd/gd.c for (i = 0; i < im->sy + 1; i++) { im 1979 ext/gd/libgd/gd.c pts[i] = (char *) ecalloc(im->sx + 1, sizeof(char)); im 1982 ext/gd/libgd/gd.c stack = (struct seg *)safe_emalloc(sizeof(struct seg), ((int)(im->sy*im->sx)/4), 1); im 1985 ext/gd/libgd/gd.c oc = gdImageGetPixel(im, x, y); im 1993 ext/gd/libgd/gd.c for (x=x1; x>=0 && (!pts[y][x] && gdImageGetPixel(im,x,y)==oc); x--) { im 1994 ext/gd/libgd/gd.c nc = gdImageTileGet(im,x,y); im 1996 ext/gd/libgd/gd.c gdImageSetPixel(im,x, y, nc); im 2009 ext/gd/libgd/gd.c for(; x<wx2 && (!pts[y][x] && gdImageGetPixel(im,x, y)==oc); x++) { im 2010 ext/gd/libgd/gd.c nc = gdImageTileGet(im,x,y); im 2012 ext/gd/libgd/gd.c gdImageSetPixel(im, x, y, nc); im 2019 ext/gd/libgd/gd.c skip: for(x++; x<=x2 && (pts[y][x] || gdImageGetPixel(im,x, y)!=oc); x++); im 2024 ext/gd/libgd/gd.c for(i = 0; i < im->sy + 1; i++) { im 2034 ext/gd/libgd/gd.c void gdImageRectangle (gdImagePtr im, int x1, int y1, int x2, int y2, int color) im 2037 ext/gd/libgd/gd.c int thick = im->thick; im 2041 ext/gd/libgd/gd.c gdImageSetPixel(im, x1, y1, color); im 2072 ext/gd/libgd/gd.c gdImageSetPixel(im, cx, cy, color); im 2080 ext/gd/libgd/gd.c gdImageSetPixel(im, cx, cy, color); im 2088 ext/gd/libgd/gd.c gdImageSetPixel(im, cx, cy, color); im 2096 ext/gd/libgd/gd.c gdImageSetPixel(im, cx, cy, color); im 2103 ext/gd/libgd/gd.c gdImageLine(im, x1, y1, x2, y2, color); im 2107 ext/gd/libgd/gd.c gdImageLine(im, x1h, y1h, x2h, y1h, color); im 2108 ext/gd/libgd/gd.c gdImageLine(im, x1h, y2h, x2h, y2h, color); im 2109 ext/gd/libgd/gd.c gdImageLine(im, x1v, y1v, x1v, y2v, color); im 2110 ext/gd/libgd/gd.c gdImageLine(im, x2v, y1v, x2v, y2v, color); im 2115 ext/gd/libgd/gd.c void gdImageFilledRectangle (gdImagePtr im, int x1, int y1, int x2, int y2, int color) im 2121 ext/gd/libgd/gd.c gdImageSetPixel(im, x1, y1, color); im 2141 ext/gd/libgd/gd.c if (x2 >= gdImageSX(im)) { im 2142 ext/gd/libgd/gd.c x2 = gdImageSX(im) - 1; im 2149 ext/gd/libgd/gd.c if (y2 >= gdImageSY(im)) { im 2150 ext/gd/libgd/gd.c y2 = gdImageSY(im) - 1; im 2155 ext/gd/libgd/gd.c gdImageSetPixel (im, x, y, color); im 2565 ext/gd/libgd/gd.c void gdImagePolygon (gdImagePtr im, gdPointPtr p, int n, int c) im 2569 ext/gd/libgd/gd.c typedef void (*image_line)(gdImagePtr im, int x1, int y1, int x2, int y2, int color); im 2580 ext/gd/libgd/gd.c im->AA_polygon = 1; im 2583 ext/gd/libgd/gd.c if ( im->antialias) { im 2590 ext/gd/libgd/gd.c draw_line(im, lx, ly, p[n - 1].x, p[n - 1].y, c); im 2593 ext/gd/libgd/gd.c draw_line(im, lx, ly, p->x, p->y, c); im 2599 ext/gd/libgd/gd.c im->AA_polygon = 0; im 2600 ext/gd/libgd/gd.c gdImageAABlend(im); im 2614 ext/gd/libgd/gd.c void gdImageFilledPolygon (gdImagePtr im, gdPointPtr p, int n, int c) im 2634 ext/gd/libgd/gd.c fill_color = im->AA_color; im 2639 ext/gd/libgd/gd.c if (!im->polyAllocated) { im 2640 ext/gd/libgd/gd.c im->polyInts = (int *) gdMalloc(sizeof(int) * n); im 2641 ext/gd/libgd/gd.c im->polyAllocated = n; im 2643 ext/gd/libgd/gd.c if (im->polyAllocated < n) { im 2644 ext/gd/libgd/gd.c while (im->polyAllocated < n) { im 2645 ext/gd/libgd/gd.c im->polyAllocated *= 2; im 2647 ext/gd/libgd/gd.c if (overflow2(sizeof(int), im->polyAllocated)) { im 2650 ext/gd/libgd/gd.c im->polyInts = (int *) gdRealloc(im->polyInts, sizeof(int) * im->polyAllocated); im 2667 ext/gd/libgd/gd.c if (maxy >= gdImageSY(im)) { im 2668 ext/gd/libgd/gd.c maxy = gdImageSY(im) - 1; im 2703 ext/gd/libgd/gd.c im->polyInts[ints++] = (float) ((y - y1) * (x2 - x1)) / (float) (y2 - y1) + 0.5 + x1; im 2705 ext/gd/libgd/gd.c im->polyInts[ints++] = x2; im 2708 ext/gd/libgd/gd.c qsort(im->polyInts, ints, sizeof(int), gdCompareInt); im 2711 ext/gd/libgd/gd.c gdImageLine(im, im->polyInts[i], y, im->polyInts[i + 1], y, fill_color); im 2717 ext/gd/libgd/gd.c gdImagePolygon(im, p, n, c); im 2726 ext/gd/libgd/gd.c void gdImageSetStyle (gdImagePtr im, int *style, int noOfPixels) im 2728 ext/gd/libgd/gd.c if (im->style) { im 2729 ext/gd/libgd/gd.c gdFree(im->style); im 2731 ext/gd/libgd/gd.c im->style = (int *) gdMalloc(sizeof(int) * noOfPixels); im 2732 ext/gd/libgd/gd.c memcpy(im->style, style, sizeof(int) * noOfPixels); im 2733 ext/gd/libgd/gd.c im->styleLength = noOfPixels; im 2734 ext/gd/libgd/gd.c im->stylePos = 0; im 2737 ext/gd/libgd/gd.c void gdImageSetThickness (gdImagePtr im, int thickness) im 2739 ext/gd/libgd/gd.c im->thick = thickness; im 2742 ext/gd/libgd/gd.c void gdImageSetBrush (gdImagePtr im, gdImagePtr brush) im 2745 ext/gd/libgd/gd.c im->brush = brush; im 2746 ext/gd/libgd/gd.c if (!im->trueColor && !im->brush->trueColor) { im 2749 ext/gd/libgd/gd.c index = gdImageColorResolveAlpha(im, gdImageRed(brush, i), gdImageGreen(brush, i), gdImageBlue(brush, i), gdImageAlpha(brush, i)); im 2750 ext/gd/libgd/gd.c im->brushColorMap[i] = index; im 2755 ext/gd/libgd/gd.c void gdImageSetTile (gdImagePtr im, gdImagePtr tile) im 2758 ext/gd/libgd/gd.c im->tile = tile; im 2759 ext/gd/libgd/gd.c if (!im->trueColor && !im->tile->trueColor) { im 2762 ext/gd/libgd/gd.c index = gdImageColorResolveAlpha(im, gdImageRed(tile, i), gdImageGreen(tile, i), gdImageBlue(tile, i), gdImageAlpha(tile, i)); im 2763 ext/gd/libgd/gd.c im->tileColorMap[i] = index; im 2768 ext/gd/libgd/gd.c void gdImageSetAntiAliased (gdImagePtr im, int c) im 2770 ext/gd/libgd/gd.c im->AA = 1; im 2771 ext/gd/libgd/gd.c im->AA_color = c; im 2772 ext/gd/libgd/gd.c im->AA_dont_blend = -1; im 2775 ext/gd/libgd/gd.c void gdImageSetAntiAliasedDontBlend (gdImagePtr im, int c, int dont_blend) im 2777 ext/gd/libgd/gd.c im->AA = 1; im 2778 ext/gd/libgd/gd.c im->AA_color = c; im 2779 ext/gd/libgd/gd.c im->AA_dont_blend = dont_blend; im 2783 ext/gd/libgd/gd.c void gdImageInterlace (gdImagePtr im, int interlaceArg) im 2785 ext/gd/libgd/gd.c im->interlace = interlaceArg; im 2928 ext/gd/libgd/gd.c void gdImageAlphaBlending (gdImagePtr im, int alphaBlendingArg) im 2930 ext/gd/libgd/gd.c im->alphaBlendingFlag = alphaBlendingArg; im 2933 ext/gd/libgd/gd.c void gdImageAntialias (gdImagePtr im, int antialias) im 2935 ext/gd/libgd/gd.c if (im->trueColor){ im 2936 ext/gd/libgd/gd.c im->antialias = antialias; im 2940 ext/gd/libgd/gd.c void gdImageSaveAlpha (gdImagePtr im, int saveAlphaArg) im 2942 ext/gd/libgd/gd.c im->saveAlphaFlag = saveAlphaArg; im 2978 ext/gd/libgd/gd.c void gdImageSetClip (gdImagePtr im, int x1, int y1, int x2, int y2) im 2983 ext/gd/libgd/gd.c if (x1 >= im->sx) { im 2984 ext/gd/libgd/gd.c x1 = im->sx - 1; im 2989 ext/gd/libgd/gd.c if (x2 >= im->sx) { im 2990 ext/gd/libgd/gd.c x2 = im->sx - 1; im 2995 ext/gd/libgd/gd.c if (y1 >= im->sy) { im 2996 ext/gd/libgd/gd.c y1 = im->sy - 1; im 3001 ext/gd/libgd/gd.c if (y2 >= im->sy) { im 3002 ext/gd/libgd/gd.c y2 = im->sy - 1; im 3004 ext/gd/libgd/gd.c im->cx1 = x1; im 3005 ext/gd/libgd/gd.c im->cy1 = y1; im 3006 ext/gd/libgd/gd.c im->cx2 = x2; im 3007 ext/gd/libgd/gd.c im->cy2 = y2; im 3010 ext/gd/libgd/gd.c void gdImageGetClip (gdImagePtr im, int *x1P, int *y1P, int *x2P, int *y2P) im 3012 ext/gd/libgd/gd.c *x1P = im->cx1; im 3013 ext/gd/libgd/gd.c *y1P = im->cy1; im 3014 ext/gd/libgd/gd.c *x2P = im->cx2; im 3015 ext/gd/libgd/gd.c *y2P = im->cy2; im 407 ext/gd/libgd/gd.h void gdImageDestroy(gdImagePtr im); im 416 ext/gd/libgd/gd.h void gdImageSetPixel(gdImagePtr im, int x, int y, int color); im 418 ext/gd/libgd/gd.h int gdImageGetTrueColorPixel (gdImagePtr im, int x, int y); im 419 ext/gd/libgd/gd.h int gdImageGetPixel(gdImagePtr im, int x, int y); im 421 ext/gd/libgd/gd.h void gdImageAABlend(gdImagePtr im); im 423 ext/gd/libgd/gd.h void gdImageLine(gdImagePtr im, int x1, int y1, int x2, int y2, int color); im 424 ext/gd/libgd/gd.h void gdImageAALine(gdImagePtr im, int x1, int y1, int x2, int y2, int color); im 428 ext/gd/libgd/gd.h void gdImageDashedLine(gdImagePtr im, int x1, int y1, int x2, int y2, int color); im 431 ext/gd/libgd/gd.h void gdImageRectangle(gdImagePtr im, int x1, int y1, int x2, int y2, int color); im 433 ext/gd/libgd/gd.h void gdImageFilledRectangle(gdImagePtr im, int x1, int y1, int x2, int y2, int color); im 434 ext/gd/libgd/gd.h void gdImageSetClip(gdImagePtr im, int x1, int y1, int x2, int y2); im 435 ext/gd/libgd/gd.h void gdImageGetClip(gdImagePtr im, int *x1P, int *y1P, int *x2P, int *y2P); im 436 ext/gd/libgd/gd.h void gdImageChar(gdImagePtr im, gdFontPtr f, int x, int y, int c, int color); im 437 ext/gd/libgd/gd.h void gdImageCharUp(gdImagePtr im, gdFontPtr f, int x, int y, int c, int color); im 438 ext/gd/libgd/gd.h void gdImageString(gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color); im 439 ext/gd/libgd/gd.h void gdImageStringUp(gdImagePtr im, gdFontPtr f, int x, int y, unsigned char *s, int color); im 440 ext/gd/libgd/gd.h void gdImageString16(gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color); im 441 ext/gd/libgd/gd.h void gdImageStringUp16(gdImagePtr im, gdFontPtr f, int x, int y, unsigned short *s, int color); im 463 ext/gd/libgd/gd.h char *gdImageStringTTF(gdImage *im, int *brect, int fg, char *fontlist, im 467 ext/gd/libgd/gd.h char *gdImageStringFT(gdImage *im, int *brect, int fg, char *fontlist, im 494 ext/gd/libgd/gd.h gdImageStringFTEx(gdImage * im, int *brect, int fg, char * fontlist, im 504 ext/gd/libgd/gd.h void gdImagePolygon(gdImagePtr im, gdPointPtr p, int n, int c); im 505 ext/gd/libgd/gd.h void gdImageFilledPolygon(gdImagePtr im, gdPointPtr p, int n, int c); im 509 ext/gd/libgd/gd.h int gdImageColorAllocate(gdImagePtr im, int r, int g, int b); im 511 ext/gd/libgd/gd.h int gdImageColorAllocateAlpha(gdImagePtr im, int r, int g, int b, int a); im 513 ext/gd/libgd/gd.h int gdImageColorClosest(gdImagePtr im, int r, int g, int b); im 518 ext/gd/libgd/gd.h int gdImageColorClosestAlpha(gdImagePtr im, int r, int g, int b, int a); im 520 ext/gd/libgd/gd.h int gdImageColorClosestHWB(gdImagePtr im, int r, int g, int b); im 522 ext/gd/libgd/gd.h int gdImageColorExact(gdImagePtr im, int r, int g, int b); im 524 ext/gd/libgd/gd.h int gdImageColorExactAlpha(gdImagePtr im, int r, int g, int b, int a); im 526 ext/gd/libgd/gd.h int gdImageColorResolve(gdImagePtr im, int r, int g, int b); im 528 ext/gd/libgd/gd.h int gdImageColorResolveAlpha(gdImagePtr im, int r, int g, int b, int a); im 546 ext/gd/libgd/gd.h void gdImageColorDeallocate(gdImagePtr im, int color); im 564 ext/gd/libgd/gd.h gdImagePtr gdImageCreatePaletteFromTrueColor (gdImagePtr im, int ditherFlag, int colorsWanted); im 566 ext/gd/libgd/gd.h void gdImageTrueColorToPalette(gdImagePtr im, int ditherFlag, int colorsWanted); im 583 ext/gd/libgd/gd.h void gdImageColorTransparent(gdImagePtr im, int color); im 586 ext/gd/libgd/gd.h void gdImagePng(gdImagePtr im, FILE *out); im 587 ext/gd/libgd/gd.h void gdImagePngCtx(gdImagePtr im, gdIOCtx *out); im 588 ext/gd/libgd/gd.h void gdImageGif(gdImagePtr im, FILE *out); im 589 ext/gd/libgd/gd.h void gdImageGifCtx(gdImagePtr im, gdIOCtx *out); im 595 ext/gd/libgd/gd.h void gdImagePngEx(gdImagePtr im, FILE * out, int level, int basefilter); im 596 ext/gd/libgd/gd.h void gdImagePngCtxEx(gdImagePtr im, gdIOCtx * out, int level, int basefilter); im 606 ext/gd/libgd/gd.h void *gdImageWBMPPtr(gdImagePtr im, int *size, int fg); im 610 ext/gd/libgd/gd.h void gdImageJpeg(gdImagePtr im, FILE *out, int quality); im 611 ext/gd/libgd/gd.h void gdImageJpegCtx(gdImagePtr im, gdIOCtx *out, int quality); im 613 ext/gd/libgd/gd.h void gdImageWebpCtx (gdImagePtr im, gdIOCtx * outfile, int quantization); im 616 ext/gd/libgd/gd.h void *gdImageJpegPtr(gdImagePtr im, int *size, int quality); im 632 ext/gd/libgd/gd.h void gdImagePngToSink(gdImagePtr im, gdSinkPtr out); im 634 ext/gd/libgd/gd.h void gdImageGd(gdImagePtr im, FILE *out); im 635 ext/gd/libgd/gd.h void gdImageGd2(gdImagePtr im, FILE *out, int cs, int fmt); im 638 ext/gd/libgd/gd.h void* gdImagePngPtr(gdImagePtr im, int *size); im 641 ext/gd/libgd/gd.h void* gdImageGdPtr(gdImagePtr im, int *size); im 642 ext/gd/libgd/gd.h void *gdImagePngPtrEx(gdImagePtr im, int *size, int level, int basefilter); im 645 ext/gd/libgd/gd.h void* gdImageGd2Ptr(gdImagePtr im, int cs, int fmt, int *size); im 647 ext/gd/libgd/gd.h void gdImageEllipse(gdImagePtr im, int cx, int cy, int w, int h, int c); im 666 ext/gd/libgd/gd.h void gdImageFilledArc(gdImagePtr im, int cx, int cy, int w, int h, int s, int e, int color, int style); im 667 ext/gd/libgd/gd.h void gdImageArc(gdImagePtr im, int cx, int cy, int w, int h, int s, int e, int color); im 668 ext/gd/libgd/gd.h void gdImageFilledEllipse(gdImagePtr im, int cx, int cy, int w, int h, int color); im 669 ext/gd/libgd/gd.h void gdImageFillToBorder(gdImagePtr im, int x, int y, int border, int color); im 670 ext/gd/libgd/gd.h void gdImageFill(gdImagePtr im, int x, int y, int color); im 700 ext/gd/libgd/gd.h void gdImageSetBrush(gdImagePtr im, gdImagePtr brush); im 701 ext/gd/libgd/gd.h void gdImageSetTile(gdImagePtr im, gdImagePtr tile); im 702 ext/gd/libgd/gd.h void gdImageSetAntiAliased(gdImagePtr im, int c); im 703 ext/gd/libgd/gd.h void gdImageSetAntiAliasedDontBlend(gdImagePtr im, int c, int dont_blend); im 704 ext/gd/libgd/gd.h void gdImageSetStyle(gdImagePtr im, int *style, int noOfPixels); im 707 ext/gd/libgd/gd.h void gdImageSetThickness(gdImagePtr im, int thickness); im 709 ext/gd/libgd/gd.h void gdImageInterlace(gdImagePtr im, int interlaceArg); im 710 ext/gd/libgd/gd.h void gdImageAlphaBlending(gdImagePtr im, int alphaBlendingArg); im 711 ext/gd/libgd/gd.h void gdImageAntialias(gdImagePtr im, int antialias); im 712 ext/gd/libgd/gd.h void gdImageSaveAlpha(gdImagePtr im, int saveAlphaArg); im 719 ext/gd/libgd/gd.h int gdImagePixelate(gdImagePtr im, int block_size, const unsigned int mode); im 726 ext/gd/libgd/gd.h #define gdImageTrueColor(im) ((im)->trueColor) im 728 ext/gd/libgd/gd.h #define gdImageSX(im) ((im)->sx) im 729 ext/gd/libgd/gd.h #define gdImageSY(im) ((im)->sy) im 730 ext/gd/libgd/gd.h #define gdImageColorsTotal(im) ((im)->colorsTotal) im 731 ext/gd/libgd/gd.h #define gdImageRed(im, c) ((im)->trueColor ? gdTrueColorGetRed(c) : \ im 732 ext/gd/libgd/gd.h (im)->red[(c)]) im 733 ext/gd/libgd/gd.h #define gdImageGreen(im, c) ((im)->trueColor ? gdTrueColorGetGreen(c) : \ im 734 ext/gd/libgd/gd.h (im)->green[(c)]) im 735 ext/gd/libgd/gd.h #define gdImageBlue(im, c) ((im)->trueColor ? gdTrueColorGetBlue(c) : \ im 736 ext/gd/libgd/gd.h (im)->blue[(c)]) im 737 ext/gd/libgd/gd.h #define gdImageAlpha(im, c) ((im)->trueColor ? gdTrueColorGetAlpha(c) : \ im 738 ext/gd/libgd/gd.h (im)->alpha[(c)]) im 739 ext/gd/libgd/gd.h #define gdImageGetTransparent(im) ((im)->transparent) im 740 ext/gd/libgd/gd.h #define gdImageGetInterlaced(im) ((im)->interlace) im 747 ext/gd/libgd/gd.h #define gdImagePalettePixel(im, x, y) (im)->pixels[(y)][(x)] im 748 ext/gd/libgd/gd.h #define gdImageTrueColorPixel(im, x, y) (im)->tpixels[(y)][(x)] im 793 ext/gd/libgd/gd.h int gdImageGaussianBlur(gdImagePtr im); im 797 ext/gd/libgd/gd.h int gdImageEmboss(gdImagePtr im); im 799 ext/gd/libgd/gd.h int gdImageMeanRemoval(gdImagePtr im); im 801 ext/gd/libgd/gd.h int gdImageSmooth(gdImagePtr im, float weight); im 806 ext/gd/libgd/gd.h void gdImageFlipHorizontal(gdImagePtr im); im 807 ext/gd/libgd/gd.h void gdImageFlipVertical(gdImagePtr im); im 808 ext/gd/libgd/gd.h void gdImageFlipBoth(gdImagePtr im); im 837 ext/gd/libgd/gd.h gdImagePtr gdImageCropAuto(gdImagePtr im, const unsigned int mode); im 838 ext/gd/libgd/gd.h gdImagePtr gdImageCropThreshold(gdImagePtr im, const unsigned int color, const float threshold); im 840 ext/gd/libgd/gd.h int gdImageSetInterpolationMethod(gdImagePtr im, gdInterpolationMethod id); im 842 ext/gd/libgd/gd.h gdImagePtr gdImageScaleBilinear(gdImagePtr im, const unsigned int new_width, const unsigned int new_height); im 845 ext/gd/libgd/gd.h gdImagePtr gdImageScaleNearestNeighbour(gdImagePtr im, const unsigned int width, const unsigned int height); im 905 ext/gd/libgd/gd.h #define gdImageBoundsSafe(im, x, y) (!((((y) < (im)->cy1) || ((y) > (im)->cy2)) || (((x) < (im)->cx1) || ((x) > (im)->cx2)))) im 14 ext/gd/libgd/gd2copypal.c gdImagePtr im; im 42 ext/gd/libgd/gd2copypal.c im = gdImageCreateFromGd2 (in); im 44 ext/gd/libgd/gd2copypal.c if (!im) im 50 ext/gd/libgd/gd2copypal.c gdImagePaletteCopy (im, pal); im 56 ext/gd/libgd/gd2copypal.c gdImageDestroy (im); im 59 ext/gd/libgd/gd2copypal.c gdImageGd2 (im, out, 128, 2); im 62 ext/gd/libgd/gd2copypal.c gdImageDestroy (im); im 15 ext/gd/libgd/gd2time.c gdImagePtr im; im 46 ext/gd/libgd/gd2time.c im = gdImageCreateFromGd2Part (in, x, y, w, h); im 49 ext/gd/libgd/gd2time.c if (!im) im 54 ext/gd/libgd/gd2time.c gdImageDestroy (im); im 13 ext/gd/libgd/gd2topng.c gdImagePtr im; im 26 ext/gd/libgd/gd2topng.c im = gdImageCreateFromGd2 (in); im 28 ext/gd/libgd/gd2topng.c if (!im) im 37 ext/gd/libgd/gd2topng.c gdImageDestroy (im); im 41 ext/gd/libgd/gd2topng.c gdImagePng (im, out); im 46 ext/gd/libgd/gd2topng.c gdImageDestroy (im); im 17 ext/gd/libgd/gd_arc.c void gdImageEllipse(gdImagePtr im, int mx, int my, int w, int h, int c) im 24 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,mx+a, my, c); im 25 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,mx-a, my, c); im 49 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,mx1, my1, c); im 50 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,mx1, my2, c); im 51 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,mx2, my1, c); im 52 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,mx2, my2, c); im 56 ext/gd/libgd/gd_arc.c void gdImageFilledEllipse (gdImagePtr im, int mx, int my, int w, int h, int c) im 67 ext/gd/libgd/gd_arc.c gdImageSetPixel(im, x, my, c); im 96 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,i,my1,c); im 97 ext/gd/libgd/gd_arc.c gdImageSetPixel(im,i,my2,c); im 16 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledEllipse (gdImagePtr im, int cx, int cy, int width, int height, int color) im 18 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, 0, 360, color, gdChord); im 22 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (gdImagePtr im, int cx, int cy, int width, int height, int s, int e, int color, int style) im 110 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, s, (i + 1) * 90, color, gdChord); im 118 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, (i + 1) * 90, e, color, gdChord); im 124 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 3, color); im 125 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 3, color); im 131 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 4, color); im 132 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 4, color); im 137 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, (i + 1) * 90, (i + 2) * 90, color, gdChord); im 142 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, (i + 2) * 90, e, color, gdChord); im 148 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 4, color); im 149 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 4, color); im 155 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 5, color); im 156 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 5, color); im 161 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, (i + 2) * 90, (i + 3) * 90, color, gdChord); im 166 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, (i + 3) * 90, e, color, gdChord); im 172 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 5, color); im 173 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 5, color); im 179 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 6, color); im 180 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 6, color); im 185 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, (i + 3) * 90, (i + 4) * 90, color, gdChord); im 189 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, cx, cy, width, height, (i + 4) * 90, e, color, gdChord); im 195 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 6, color); im 196 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 6, color); im 202 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 7, color); im 203 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 7, color); im 375 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 3, color); im 376 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 3, color); im 397 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledPolygon (im, pt, 3, color); im 398 ext/gd/libgd/gd_arc_f_buggy.c gdImagePolygon (im, pt, 3, color); im 461 ext/gd/libgd/gd_arc_f_buggy.c gdImageSetPixel (im, ((flip_x) ? (cx - x) : (cx + x)), im 526 ext/gd/libgd/gd_arc_f_buggy.c gdImageSetPixel (im, ((flip_x) ? (cx - x) : (cx + x)), im 704 ext/gd/libgd/gd_arc_f_buggy.c gdImagePtr im = gdImageCreate (WIDTH, HEIGHT); im 705 ext/gd/libgd/gd_arc_f_buggy.c int white = gdImageColorResolve (im, 0xFF, 0xFF, 0xFF), black = gdImageColorResolve (im, 0, 0, 0), im 706 ext/gd/libgd/gd_arc_f_buggy.c red = gdImageColorResolve (im, 0xFF, 0xA0, 0xA0); im 710 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, WIDTH / 5, HEIGHT / 4, 200, 200, 45, 90, red, gdPie); im 711 ext/gd/libgd/gd_arc_f_buggy.c gdImageArc (im, WIDTH / 5, HEIGHT / 4, 200, 200, 45, 90, black); im 714 ext/gd/libgd/gd_arc_f_buggy.c gdImageFilledArc (im, WIDTH / 2, HEIGHT / 4, 200, 150, 45, 90, red, gdPie); im 715 ext/gd/libgd/gd_arc_f_buggy.c gdImageArc (im, WIDTH / 2, HEIGHT / 4, 200, 150, 45, 90, black); im 719 ext/gd/libgd/gd_arc_f_buggy.c gdImageLine (im, 0, HEIGHT / 4, WIDTH, HEIGHT / 4, black); im 720 ext/gd/libgd/gd_arc_f_buggy.c gdImageLine (im, WIDTH / 5, 0, WIDTH / 5, HEIGHT, black); im 721 ext/gd/libgd/gd_arc_f_buggy.c gdImageLine (im, WIDTH / 2, 0, WIDTH / 2, HEIGHT, black); im 722 ext/gd/libgd/gd_arc_f_buggy.c gdImageLine (im, WIDTH / 2, HEIGHT / 4, WIDTH / 2 + 300, HEIGHT / 4 + 300, black); im 723 ext/gd/libgd/gd_arc_f_buggy.c gdImageLine (im, WIDTH / 5, HEIGHT / 4, WIDTH / 5 + 300, HEIGHT / 4 + 300, black); im 732 ext/gd/libgd/gd_arc_f_buggy.c gdImagePng (im, out); im 736 ext/gd/libgd/gd_arc_f_buggy.c gdImageDestroy (im); im 27 ext/gd/libgd/gd_crop.c static int gdGuessBackgroundColorFromCorners(gdImagePtr im, int *color); im 28 ext/gd/libgd/gd_crop.c static int gdColorMatch(gdImagePtr im, int col1, int col2, float threshold); im 114 ext/gd/libgd/gd_crop.c gdImagePtr gdImageCropAuto(gdImagePtr im, const unsigned int mode) im 116 ext/gd/libgd/gd_crop.c const int width = gdImageSX(im); im 117 ext/gd/libgd/gd_crop.c const int height = gdImageSY(im); im 130 ext/gd/libgd/gd_crop.c color = gdImageGetTransparent(im); im 134 ext/gd/libgd/gd_crop.c color = gdImageColorClosestAlpha(im, 0, 0, 0, 0); im 138 ext/gd/libgd/gd_crop.c color = gdImageColorClosestAlpha(im, 255, 255, 255, 0); im 142 ext/gd/libgd/gd_crop.c corners = gdGuessBackgroundColorFromCorners(im, &color); im 147 ext/gd/libgd/gd_crop.c color = gdImageGetTransparent(im); im 149 ext/gd/libgd/gd_crop.c corners = gdGuessBackgroundColorFromCorners(im, &color); im 161 ext/gd/libgd/gd_crop.c int c2 = gdImageGetPixel(im, x, y); im 177 ext/gd/libgd/gd_crop.c match = (color == gdImageGetPixel(im, x,y)); im 190 ext/gd/libgd/gd_crop.c match = (color == gdImageGetPixel(im, x,y)); im 198 ext/gd/libgd/gd_crop.c match = (color == gdImageGetPixel(im, x,y)); im 205 ext/gd/libgd/gd_crop.c return gdImageCrop(im, &crop); im 227 ext/gd/libgd/gd_crop.c gdImagePtr gdImageCropThreshold(gdImagePtr im, const unsigned int color, const float threshold) im 229 ext/gd/libgd/gd_crop.c const int width = gdImageSX(im); im 230 ext/gd/libgd/gd_crop.c const int height = gdImageSY(im); im 253 ext/gd/libgd/gd_crop.c match = (gdColorMatch(im, color, gdImageGetPixel(im, x,y), threshold)) > 0; im 269 ext/gd/libgd/gd_crop.c match = (gdColorMatch(im, color, gdImageGetPixel(im, x, y), threshold)) > 0; im 282 ext/gd/libgd/gd_crop.c match = (gdColorMatch(im, color, gdImageGetPixel(im, x,y), threshold)) > 0; im 290 ext/gd/libgd/gd_crop.c match = (gdColorMatch(im, color, gdImageGetPixel(im, x,y), threshold)) > 0; im 295 ext/gd/libgd/gd_crop.c return gdImageCrop(im, &crop); im 304 ext/gd/libgd/gd_crop.c static int gdGuessBackgroundColorFromCorners(gdImagePtr im, int *color) im 306 ext/gd/libgd/gd_crop.c const int tl = gdImageGetPixel(im, 0, 0); im 307 ext/gd/libgd/gd_crop.c const int tr = gdImageGetPixel(im, gdImageSX(im) - 1, 0); im 308 ext/gd/libgd/gd_crop.c const int bl = gdImageGetPixel(im, 0, gdImageSY(im) -1); im 309 ext/gd/libgd/gd_crop.c const int br = gdImageGetPixel(im, gdImageSX(im) - 1, gdImageSY(im) -1); im 335 ext/gd/libgd/gd_crop.c r = (int)(0.5f + (gdImageRed(im, tl) + gdImageRed(im, tr) + gdImageRed(im, bl) + gdImageRed(im, br)) / 4); im 336 ext/gd/libgd/gd_crop.c g = (int)(0.5f + (gdImageGreen(im, tl) + gdImageGreen(im, tr) + gdImageGreen(im, bl) + gdImageGreen(im, br)) / 4); im 337 ext/gd/libgd/gd_crop.c b = (int)(0.5f + (gdImageBlue(im, tl) + gdImageBlue(im, tr) + gdImageBlue(im, bl) + gdImageBlue(im, br)) / 4); im 338 ext/gd/libgd/gd_crop.c a = (int)(0.5f + (gdImageAlpha(im, tl) + gdImageAlpha(im, tr) + gdImageAlpha(im, bl) + gdImageAlpha(im, br)) / 4); im 339 ext/gd/libgd/gd_crop.c *color = gdImageColorClosestAlpha(im, r, g, b, a); im 344 ext/gd/libgd/gd_crop.c static int gdColorMatch(gdImagePtr im, int col1, int col2, float threshold) im 346 ext/gd/libgd/gd_crop.c const int dr = gdImageRed(im, col1) - gdImageRed(im, col2); im 347 ext/gd/libgd/gd_crop.c const int dg = gdImageGreen(im, col1) - gdImageGreen(im, col2); im 348 ext/gd/libgd/gd_crop.c const int db = gdImageBlue(im, col1) - gdImageBlue(im, col2); im 349 ext/gd/libgd/gd_crop.c const int da = gdImageAlpha(im, col1) - gdImageAlpha(im, col2); im 419 ext/gd/libgd/gd_filter.c int gdImageGaussianBlur(gdImagePtr im) im 425 ext/gd/libgd/gd_filter.c return gdImageConvolution(im, filter, 16, 0); im 428 ext/gd/libgd/gd_filter.c int gdImageEmboss(gdImagePtr im) im 439 ext/gd/libgd/gd_filter.c return gdImageConvolution(im, filter, 1, 127); im 442 ext/gd/libgd/gd_filter.c int gdImageMeanRemoval(gdImagePtr im) im 448 ext/gd/libgd/gd_filter.c return gdImageConvolution(im, filter, 1, 0); im 451 ext/gd/libgd/gd_filter.c int gdImageSmooth(gdImagePtr im, float weight) im 459 ext/gd/libgd/gd_filter.c return gdImageConvolution(im, filter, weight+8, 0); im 11 ext/gd/libgd/gd_gd.c extern void gdImageGd (gdImagePtr im, FILE * out); im 22 ext/gd/libgd/gd_gd.c int _gdGetColors (gdIOCtx * in, gdImagePtr im, int gd2xFlag) im 34 ext/gd/libgd/gd_gd.c if (trueColorFlag != im->trueColor) { im 38 ext/gd/libgd/gd_gd.c if (!im->trueColor) { im 39 ext/gd/libgd/gd_gd.c if (!gdGetWord(&im->colorsTotal, in)) { im 42 ext/gd/libgd/gd_gd.c if (im->colorsTotal > gdMaxColors) { im 47 ext/gd/libgd/gd_gd.c if (!gdGetInt(&im->transparent, in)) { im 51 ext/gd/libgd/gd_gd.c if (!gdGetByte(&im->colorsTotal, in)) { im 54 ext/gd/libgd/gd_gd.c if (!gdGetWord(&im->transparent, in)) { im 57 ext/gd/libgd/gd_gd.c if (im->transparent == 257) { im 58 ext/gd/libgd/gd_gd.c im->transparent = (-1); im 62 ext/gd/libgd/gd_gd.c GD2_DBG(printf("Pallette had %d colours (T=%d)\n", im->colorsTotal, im->transparent)); im 64 ext/gd/libgd/gd_gd.c if (im->trueColor) { im 69 ext/gd/libgd/gd_gd.c if (!gdGetByte(&im->red[i], in)) { im 72 ext/gd/libgd/gd_gd.c if (!gdGetByte(&im->green[i], in)) { im 75 ext/gd/libgd/gd_gd.c if (!gdGetByte(&im->blue[i], in)) { im 79 ext/gd/libgd/gd_gd.c if (!gdGetByte(&im->alpha[i], in)) { im 85 ext/gd/libgd/gd_gd.c for (i = 0; i < im->colorsTotal; i++) { im 86 ext/gd/libgd/gd_gd.c im->open[i] = 0; im 99 ext/gd/libgd/gd_gd.c gdImagePtr im; im 124 ext/gd/libgd/gd_gd.c im = gdImageCreateTrueColor(*sx, *sy); im 126 ext/gd/libgd/gd_gd.c im = gdImageCreate(*sx, *sy); im 128 ext/gd/libgd/gd_gd.c if(!im) { im 131 ext/gd/libgd/gd_gd.c if (!_gdGetColors(in, im, gd2xFlag)) { im 135 ext/gd/libgd/gd_gd.c return im; im 137 ext/gd/libgd/gd_gd.c gdImageDestroy(im); im 144 ext/gd/libgd/gd_gd.c gdImagePtr im; im 148 ext/gd/libgd/gd_gd.c im = gdImageCreateFromGdCtx(in); im 152 ext/gd/libgd/gd_gd.c return im; im 157 ext/gd/libgd/gd_gd.c gdImagePtr im; im 159 ext/gd/libgd/gd_gd.c im = gdImageCreateFromGdCtx(in); im 162 ext/gd/libgd/gd_gd.c return im; im 169 ext/gd/libgd/gd_gd.c gdImagePtr im; im 172 ext/gd/libgd/gd_gd.c im = _gdCreateFromFile(in, &sx, &sy); im 174 ext/gd/libgd/gd_gd.c if (im == NULL) { im 180 ext/gd/libgd/gd_gd.c if (im->trueColor) { im 187 ext/gd/libgd/gd_gd.c im->tpixels[y][x] = pix; im 199 ext/gd/libgd/gd_gd.c im->pixels[y][x] = ch; im 204 ext/gd/libgd/gd_gd.c return im; im 207 ext/gd/libgd/gd_gd.c gdImageDestroy (im); im 212 ext/gd/libgd/gd_gd.c void _gdPutColors (gdImagePtr im, gdIOCtx * out) im 216 ext/gd/libgd/gd_gd.c gdPutC(im->trueColor, out); im 217 ext/gd/libgd/gd_gd.c if (!im->trueColor) { im 218 ext/gd/libgd/gd_gd.c gdPutWord(im->colorsTotal, out); im 220 ext/gd/libgd/gd_gd.c gdPutInt(im->transparent, out); im 221 ext/gd/libgd/gd_gd.c if (!im->trueColor) { im 223 ext/gd/libgd/gd_gd.c gdPutC((unsigned char) im->red[i], out); im 224 ext/gd/libgd/gd_gd.c gdPutC((unsigned char) im->green[i], out); im 225 ext/gd/libgd/gd_gd.c gdPutC((unsigned char) im->blue[i], out); im 226 ext/gd/libgd/gd_gd.c gdPutC((unsigned char) im->alpha[i], out); im 231 ext/gd/libgd/gd_gd.c static void _gdPutHeader (gdImagePtr im, gdIOCtx * out) im 236 ext/gd/libgd/gd_gd.c if (im->trueColor) { im 241 ext/gd/libgd/gd_gd.c gdPutWord(im->sx, out); im 242 ext/gd/libgd/gd_gd.c gdPutWord(im->sy, out); im 244 ext/gd/libgd/gd_gd.c _gdPutColors(im, out); im 247 ext/gd/libgd/gd_gd.c static void _gdImageGd (gdImagePtr im, gdIOCtx * out) im 251 ext/gd/libgd/gd_gd.c _gdPutHeader(im, out); im 253 ext/gd/libgd/gd_gd.c for (y = 0; y < im->sy; y++) { im 254 ext/gd/libgd/gd_gd.c for (x = 0; x < im->sx; x++) { im 256 ext/gd/libgd/gd_gd.c if (im->trueColor) { im 257 ext/gd/libgd/gd_gd.c gdPutInt(im->tpixels[y][x], out); im 259 ext/gd/libgd/gd_gd.c gdPutC((unsigned char) im->pixels[y][x], out); im 265 ext/gd/libgd/gd_gd.c void gdImageGd (gdImagePtr im, FILE * outFile) im 268 ext/gd/libgd/gd_gd.c _gdImageGd(im, out); im 272 ext/gd/libgd/gd_gd.c void *gdImageGdPtr (gdImagePtr im, int *size) im 276 ext/gd/libgd/gd_gd.c _gdImageGd(im, out); im 48 ext/gd/libgd/gd_gd2.c extern int _gdGetColors(gdIOCtx * in, gdImagePtr im, int gd2xFlag); im 49 ext/gd/libgd/gd_gd2.c extern void _gdPutColors(gdImagePtr im, gdIOCtx * out); im 167 ext/gd/libgd/gd_gd2.c gdImagePtr im; im 175 ext/gd/libgd/gd_gd2.c im = gdImageCreateTrueColor(*sx, *sy); im 177 ext/gd/libgd/gd_gd2.c im = gdImageCreate(*sx, *sy); im 179 ext/gd/libgd/gd_gd2.c if (im == NULL) { im 184 ext/gd/libgd/gd_gd2.c if (!_gdGetColors(in, im, (*vers) == 2)) { im 188 ext/gd/libgd/gd_gd2.c GD2_DBG(php_gd_error("Image palette completed: %d colours", im->colorsTotal)); im 190 ext/gd/libgd/gd_gd2.c return im; im 193 ext/gd/libgd/gd_gd2.c gdImageDestroy(im); im 230 ext/gd/libgd/gd_gd2.c gdImagePtr im; im 232 ext/gd/libgd/gd_gd2.c im = gdImageCreateFromGd2Ctx(in); im 236 ext/gd/libgd/gd_gd2.c return im; im 241 ext/gd/libgd/gd_gd2.c gdImagePtr im; im 243 ext/gd/libgd/gd_gd2.c im = gdImageCreateFromGd2Ctx(in); im 246 ext/gd/libgd/gd_gd2.c return im; im 266 ext/gd/libgd/gd_gd2.c gdImagePtr im; im 269 ext/gd/libgd/gd_gd2.c if (!(im = _gd2CreateFromFile(in, &sx, &sy, &cs, &vers, &fmt, &ncx, &ncy, &chunkIdx))) { im 273 ext/gd/libgd/gd_gd2.c bytesPerPixel = im->trueColor ? 4 : 1; im 302 ext/gd/libgd/gd_gd2.c if (yhi > im->sy) { im 303 ext/gd/libgd/gd_gd2.c yhi = im->sy; im 322 ext/gd/libgd/gd_gd2.c if (xhi > im->sx) { im 323 ext/gd/libgd/gd_gd2.c xhi = im->sx; im 328 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 329 ext/gd/libgd/gd_gd2.c if (!gdGetInt(&im->tpixels[y][x], in)) { im 330 ext/gd/libgd/gd_gd2.c im->tpixels[y][x] = 0; im 337 ext/gd/libgd/gd_gd2.c im->pixels[y][x] = ch; im 342 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 348 ext/gd/libgd/gd_gd2.c im->tpixels[y][x] = a + r + g + b; im 350 ext/gd/libgd/gd_gd2.c im->pixels[y][x] = chunkBuf[chunkPos++]; im 373 ext/gd/libgd/gd_gd2.c return im; im 376 ext/gd/libgd/gd_gd2.c gdImageDestroy(im); im 392 ext/gd/libgd/gd_gd2.c gdImagePtr im; im 394 ext/gd/libgd/gd_gd2.c im = gdImageCreateFromGd2PartCtx(in, srcx, srcy, w, h); im 397 ext/gd/libgd/gd_gd2.c return im; im 402 ext/gd/libgd/gd_gd2.c gdImagePtr im; im 405 ext/gd/libgd/gd_gd2.c im = gdImageCreateFromGd2PartCtx(in, srcx, srcy, w, h); im 409 ext/gd/libgd/gd_gd2.c return im; im 431 ext/gd/libgd/gd_gd2.c gdImagePtr im; im 449 ext/gd/libgd/gd_gd2.c im = gdImageCreateTrueColor(w, h); im 451 ext/gd/libgd/gd_gd2.c im = gdImageCreate(w, h); im 453 ext/gd/libgd/gd_gd2.c if (im == NULL) { im 457 ext/gd/libgd/gd_gd2.c if (!_gdGetColors(in, im, vers == 2)) { im 460 ext/gd/libgd/gd_gd2.c GD2_DBG(php_gd_error("Image palette completed: %d colours", im->colorsTotal)); im 475 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 531 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 560 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 571 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 583 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 584 ext/gd/libgd/gd_gd2.c im->tpixels[y - srcy][x - srcx] = ch; im 586 ext/gd/libgd/gd_gd2.c im->pixels[y - srcy][x - srcx] = ch; im 604 ext/gd/libgd/gd_gd2.c return im; im 607 ext/gd/libgd/gd_gd2.c gdImageDestroy(im); im 622 ext/gd/libgd/gd_gd2.c static void _gd2PutHeader (gdImagePtr im, gdIOCtx * out, int cs, int fmt, int cx, int cy) im 634 ext/gd/libgd/gd_gd2.c gdPutWord(im->sx, out); im 635 ext/gd/libgd/gd_gd2.c gdPutWord(im->sy, out); im 642 ext/gd/libgd/gd_gd2.c static void _gdImageGd2 (gdImagePtr im, gdIOCtx * out, int cs, int fmt) im 655 ext/gd/libgd/gd_gd2.c int bytesPerPixel = im->trueColor ? 4 : 1; im 660 ext/gd/libgd/gd_gd2.c fmt = im->trueColor ? GD2_FMT_TRUECOLOR_COMPRESSED : GD2_FMT_COMPRESSED; im 662 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 679 ext/gd/libgd/gd_gd2.c ncx = im->sx / cs + 1; im 680 ext/gd/libgd/gd_gd2.c ncy = im->sy / cs + 1; im 683 ext/gd/libgd/gd_gd2.c _gd2PutHeader (im, out, cs, fmt, ncx, ncy); im 715 ext/gd/libgd/gd_gd2.c _gdPutColors (im, out); im 717 ext/gd/libgd/gd_gd2.c GD2_DBG(php_gd_error("Size: %dx%d", im->sx, im->sy)); im 724 ext/gd/libgd/gd_gd2.c if (yhi > im->sy) { im 725 ext/gd/libgd/gd_gd2.c yhi = im->sy; im 734 ext/gd/libgd/gd_gd2.c if (xhi > im->sx) { im 735 ext/gd/libgd/gd_gd2.c xhi = im->sx; im 741 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 742 ext/gd/libgd/gd_gd2.c int p = im->tpixels[y][x]; im 748 ext/gd/libgd/gd_gd2.c chunkData[chunkLen++] = im->pixels[y][x]; im 755 ext/gd/libgd/gd_gd2.c if (im->trueColor) { im 756 ext/gd/libgd/gd_gd2.c gdPutInt(im->tpixels[y][x], out); im 758 ext/gd/libgd/gd_gd2.c gdPutC((unsigned char) im->pixels[y][x], out); im 810 ext/gd/libgd/gd_gd2.c void gdImageGd2 (gdImagePtr im, FILE * outFile, int cs, int fmt) im 814 ext/gd/libgd/gd_gd2.c _gdImageGd2(im, out, cs, fmt); im 819 ext/gd/libgd/gd_gd2.c void *gdImageGd2Ptr (gdImagePtr im, int cs, int fmt, int *size) im 824 ext/gd/libgd/gd_gd2.c _gdImageGd2(im, out, cs, fmt); im 99 ext/gd/libgd/gd_gif_in.c static void ReadImage (gdImagePtr im, gdIOCtx *fd, int len, int height, unsigned char (*cmap)[256], int interlace, int *ZeroDataBlockP); /*1.4//, int ignore); */ im 104 ext/gd/libgd/gd_gif_in.c gdImagePtr im; im 106 ext/gd/libgd/gd_gif_in.c im = gdImageCreateFromGifCtx(in); im 110 ext/gd/libgd/gd_gif_in.c return im; im 117 ext/gd/libgd/gd_gif_in.c gdImagePtr im = 0; im 119 ext/gd/libgd/gd_gif_in.c im = gdImageCreateFromGifCtx(fd); im 123 ext/gd/libgd/gd_gif_in.c return im; im 148 ext/gd/libgd/gd_gif_in.c gdImagePtr im = 0; im 230 ext/gd/libgd/gd_gif_in.c if (!(im = gdImageCreate(width, height))) { im 233 ext/gd/libgd/gd_gif_in.c im->interlace = BitSet(buf[8], INTERLACE); im 236 ext/gd/libgd/gd_gif_in.c gdImageDestroy(im); im 239 ext/gd/libgd/gd_gif_in.c ReadImage(im, fd, width, height, localColorMap, im 243 ext/gd/libgd/gd_gif_in.c gdImageDestroy(im); im 246 ext/gd/libgd/gd_gif_in.c ReadImage(im, fd, width, height, im 251 ext/gd/libgd/gd_gif_in.c gdImageColorTransparent(im, Transparent); im 258 ext/gd/libgd/gd_gif_in.c if (!im) { im 261 ext/gd/libgd/gd_gif_in.c if (!im->colorsTotal) { im 262 ext/gd/libgd/gd_gif_in.c gdImageDestroy(im); im 268 ext/gd/libgd/gd_gif_in.c for (i=((im->colorsTotal-1)); (i>=0); i--) { im 269 ext/gd/libgd/gd_gif_in.c if (im->open[i]) { im 270 ext/gd/libgd/gd_gif_in.c im->colorsTotal--; im 275 ext/gd/libgd/gd_gif_in.c return im; im 553 ext/gd/libgd/gd_gif_in.c ReadImage(gdImagePtr im, gdIOCtx *fd, int len, int height, unsigned char (*cmap)[256], int interlace, int *ZeroDataBlockP) /*1.4//, int ignore) */ im 575 ext/gd/libgd/gd_gif_in.c im->red[i] = cmap[CM_RED][i]; im 576 ext/gd/libgd/gd_gif_in.c im->green[i] = cmap[CM_GREEN][i]; im 577 ext/gd/libgd/gd_gif_in.c im->blue[i] = cmap[CM_BLUE][i]; im 578 ext/gd/libgd/gd_gif_in.c im->open[i] = 1; im 581 ext/gd/libgd/gd_gif_in.c im->colorsTotal = gdMaxColors; im 601 ext/gd/libgd/gd_gif_in.c if (im->open[v]) { im 602 ext/gd/libgd/gd_gif_in.c im->open[v] = 0; im 604 ext/gd/libgd/gd_gif_in.c gdImageSetPixel(im, xpos, ypos, v); im 91 ext/gd/libgd/gd_gif_out.c static int GIFNextPixel (gdImagePtr im, GifCtx *ctx); im 92 ext/gd/libgd/gd_gif_out.c static void GIFEncode (gdIOCtxPtr fp, int GWidth, int GHeight, int GInterlace, int Background, int Transparent, int BitsPerPixel, int *Red, int *Green, int *Blue, gdImagePtr im); im 93 ext/gd/libgd/gd_gif_out.c static void compress (int init_bits, gdIOCtx *outfile, gdImagePtr im, GifCtx *ctx); im 100 ext/gd/libgd/gd_gif_out.c void * gdImageGifPtr (gdImagePtr im, int *size) im 104 ext/gd/libgd/gd_gif_out.c gdImageGifCtx (im, out); im 110 ext/gd/libgd/gd_gif_out.c void gdImageGif (gdImagePtr im, FILE * outFile) im 113 ext/gd/libgd/gd_gif_out.c gdImageGifCtx (im, out); im 117 ext/gd/libgd/gd_gif_out.c void gdImageGifCtx(gdImagePtr im, gdIOCtxPtr out) im 119 ext/gd/libgd/gd_gif_out.c gdImagePtr pim = 0, tim = im; im 121 ext/gd/libgd/gd_gif_out.c interlace = im->interlace; im 122 ext/gd/libgd/gd_gif_out.c if (im->trueColor) { im 126 ext/gd/libgd/gd_gif_out.c pim = gdImageCreatePaletteFromTrueColor(im, 1, 256); im 238 ext/gd/libgd/gd_gif_out.c GIFNextPixel(gdImagePtr im, GifCtx *ctx) im 247 ext/gd/libgd/gd_gif_out.c r = gdImageGetPixel(im, ctx->curx, ctx->cury); im 257 ext/gd/libgd/gd_gif_out.c GIFEncode(gdIOCtxPtr fp, int GWidth, int GHeight, int GInterlace, int Background, int Transparent, int BitsPerPixel, int *Red, int *Green, int *Blue, gdImagePtr im) im 397 ext/gd/libgd/gd_gif_out.c compress( InitCodeSize+1, fp, im, &ctx ); im 492 ext/gd/libgd/gd_gif_out.c compress(int init_bits, gdIOCtxPtr outfile, gdImagePtr im, GifCtx *ctx) im 524 ext/gd/libgd/gd_gif_out.c ent = GIFNextPixel( im, ctx ); im 537 ext/gd/libgd/gd_gif_out.c while ( (c = GIFNextPixel( im )) != (unsigned) EOF ) { im 539 ext/gd/libgd/gd_gif_out.c while ( (c = GIFNextPixel( im, ctx )) != EOF ) { /* } */ im 646 ext/gd/libgd/gd_interpolation.c static inline int getPixelOverflowTC(gdImagePtr im, const int x, const int y, const int bgColor) im 648 ext/gd/libgd/gd_interpolation.c if (gdImageBoundsSafe(im, x, y)) { im 649 ext/gd/libgd/gd_interpolation.c const int c = im->tpixels[y][x]; im 650 ext/gd/libgd/gd_interpolation.c if (c == im->transparent) { im 657 ext/gd/libgd/gd_interpolation.c if (y < im->cy1) { im 658 ext/gd/libgd/gd_interpolation.c border = im->tpixels[0][im->cx1]; im 662 ext/gd/libgd/gd_interpolation.c if (y < im->cy1) { im 663 ext/gd/libgd/gd_interpolation.c border = im->tpixels[0][im->cx1]; im 667 ext/gd/libgd/gd_interpolation.c if (y > im->cy2) { im 668 ext/gd/libgd/gd_interpolation.c if (x >= im->cx1 && x <= im->cx1) { im 669 ext/gd/libgd/gd_interpolation.c border = im->tpixels[im->cy2][x]; im 677 ext/gd/libgd/gd_interpolation.c if (x < im->cx1) { im 678 ext/gd/libgd/gd_interpolation.c border = im->tpixels[y][im->cx1]; im 682 ext/gd/libgd/gd_interpolation.c if (x > im->cx2) { im 683 ext/gd/libgd/gd_interpolation.c border = im->tpixels[y][im->cx2]; im 687 ext/gd/libgd/gd_interpolation.c if (border == im->transparent) { im 695 ext/gd/libgd/gd_interpolation.c #define colorIndex2RGBA(c) gdTrueColorAlpha(im->red[(c)], im->green[(c)], im->blue[(c)], im->alpha[(c)]) im 696 ext/gd/libgd/gd_interpolation.c #define colorIndex2RGBcustomA(c, a) gdTrueColorAlpha(im->red[(c)], im->green[(c)], im->blue[(c)], im->alpha[(a)]) im 697 ext/gd/libgd/gd_interpolation.c static inline int getPixelOverflowPalette(gdImagePtr im, const int x, const int y, const int bgColor) im 699 ext/gd/libgd/gd_interpolation.c if (gdImageBoundsSafe(im, x, y)) { im 700 ext/gd/libgd/gd_interpolation.c const int c = im->pixels[y][x]; im 701 ext/gd/libgd/gd_interpolation.c if (c == im->transparent) { im 707 ext/gd/libgd/gd_interpolation.c if (y < im->cy1) { im 708 ext/gd/libgd/gd_interpolation.c border = gdImageGetPixel(im, im->cx1, 0); im 712 ext/gd/libgd/gd_interpolation.c if (y < im->cy1) { im 713 ext/gd/libgd/gd_interpolation.c border = gdImageGetPixel(im, im->cx1, 0); im 717 ext/gd/libgd/gd_interpolation.c if (y > im->cy2) { im 718 ext/gd/libgd/gd_interpolation.c if (x >= im->cx1 && x <= im->cx1) { im 719 ext/gd/libgd/gd_interpolation.c border = gdImageGetPixel(im, x, im->cy2); im 727 ext/gd/libgd/gd_interpolation.c if (x < im->cx1) { im 728 ext/gd/libgd/gd_interpolation.c border = gdImageGetPixel(im, im->cx1, y); im 732 ext/gd/libgd/gd_interpolation.c if (x > im->cx2) { im 733 ext/gd/libgd/gd_interpolation.c border = gdImageGetPixel(im, im->cx2, y); im 737 ext/gd/libgd/gd_interpolation.c if (border == im->transparent) { im 745 ext/gd/libgd/gd_interpolation.c static int getPixelInterpolateWeight(gdImagePtr im, const double x, const double y, const int bgColor) im 760 ext/gd/libgd/gd_interpolation.c const int c1 = im->trueColor == 1 ? getPixelOverflowTC(im, sx, sy, bgColor) : getPixelOverflowPalette(im, sx, sy, bgColor); im 761 ext/gd/libgd/gd_interpolation.c const int c2 = im->trueColor == 1 ? getPixelOverflowTC(im, sx - 1, sy, bgColor) : getPixelOverflowPalette(im, sx - 1, sy, bgColor); im 762 ext/gd/libgd/gd_interpolation.c const int c3 = im->trueColor == 1 ? getPixelOverflowTC(im, sx, sy - 1, bgColor) : getPixelOverflowPalette(im, sx, sy - 1, bgColor); im 763 ext/gd/libgd/gd_interpolation.c const int c4 = im->trueColor == 1 ? getPixelOverflowTC(im, sx - 1, sy - 1, bgColor) : getPixelOverflowPalette(im, sx, sy - 1, bgColor); im 770 ext/gd/libgd/gd_interpolation.c if (im->trueColor) { im 776 ext/gd/libgd/gd_interpolation.c r = (int)(m1*im->red[(c1)] + m2*im->red[(c2)] + m3*im->red[(c3)] + m4*im->red[(c4)]); im 777 ext/gd/libgd/gd_interpolation.c g = (int)(m1*im->green[(c1)] + m2*im->green[(c2)] + m3*im->green[(c3)] + m4*im->green[(c4)]); im 778 ext/gd/libgd/gd_interpolation.c b = (int)(m1*im->blue[(c1)] + m2*im->blue[(c2)] + m3*im->blue[(c3)] + m4*im->blue[(c4)]); im 779 ext/gd/libgd/gd_interpolation.c a = (int)(m1*im->alpha[(c1)] + m2*im->alpha[(c2)] + m3*im->alpha[(c3)] + m4*im->alpha[(c4)]); im 806 ext/gd/libgd/gd_interpolation.c int getPixelInterpolated(gdImagePtr im, const double x, const double y, const int bgColor) im 817 ext/gd/libgd/gd_interpolation.c if (im->interpolation_id == GD_BILINEAR_FIXED || im->interpolation_id == GD_BICUBIC_FIXED || im->interpolation_id == GD_NEAREST_NEIGHBOUR) { im 821 ext/gd/libgd/gd_interpolation.c if (im->interpolation_id == GD_WEIGHTED4) { im 822 ext/gd/libgd/gd_interpolation.c return getPixelInterpolateWeight(im, x, y, bgColor); im 825 ext/gd/libgd/gd_interpolation.c if (im->interpolation_id == GD_NEAREST_NEIGHBOUR) { im 826 ext/gd/libgd/gd_interpolation.c if (im->trueColor == 1) { im 827 ext/gd/libgd/gd_interpolation.c return getPixelOverflowTC(im, xi, yi, bgColor); im 829 ext/gd/libgd/gd_interpolation.c return getPixelOverflowPalette(im, xi, yi, bgColor); im 832 ext/gd/libgd/gd_interpolation.c if (im->interpolation) { im 834 ext/gd/libgd/gd_interpolation.c kernel_x[i] = (double) im->interpolation((double)(xi+i-1-x)); im 835 ext/gd/libgd/gd_interpolation.c kernel_y[i] = (double) im->interpolation((double)(yi+i-1-y)); im 848 ext/gd/libgd/gd_interpolation.c if (im->trueColor) { im 850 ext/gd/libgd/gd_interpolation.c const int rgbs = getPixelOverflowTC(im, xii, yii, bgColor); im 860 ext/gd/libgd/gd_interpolation.c const int rgbs = getPixelOverflowPalette(im, xii, yii, bgColor); im 1109 ext/gd/libgd/gd_interpolation.c gdImagePtr gdImageScaleNearestNeighbour(gdImagePtr im, const unsigned int width, const unsigned int height) im 1113 ext/gd/libgd/gd_interpolation.c const float dx = (float)im->sx / (float)new_width; im 1114 ext/gd/libgd/gd_interpolation.c const float dy = (float)im->sy / (float)new_height; im 1132 ext/gd/libgd/gd_interpolation.c if (im->trueColor) { im 1141 ext/gd/libgd/gd_interpolation.c dst_img->tpixels[dst_offset_y][dst_offset_x++] = im->tpixels[m][n]; im 1152 ext/gd/libgd/gd_interpolation.c dst_img->tpixels[dst_offset_y][dst_offset_x++] = colorIndex2RGBA(im->pixels[m][n]); im 1160 ext/gd/libgd/gd_interpolation.c static inline int getPixelOverflowColorTC(gdImagePtr im, const int x, const int y, const int color) im 1162 ext/gd/libgd/gd_interpolation.c if (gdImageBoundsSafe(im, x, y)) { im 1163 ext/gd/libgd/gd_interpolation.c const int c = im->tpixels[y][x]; im 1164 ext/gd/libgd/gd_interpolation.c if (c == im->transparent) { im 1170 ext/gd/libgd/gd_interpolation.c if (y < im->cy1) { im 1171 ext/gd/libgd/gd_interpolation.c border = im->tpixels[0][im->cx1]; im 1175 ext/gd/libgd/gd_interpolation.c if (y < im->cy1) { im 1176 ext/gd/libgd/gd_interpolation.c border = im->tpixels[0][im->cx1]; im 1180 ext/gd/libgd/gd_interpolation.c if (y > im->cy2) { im 1181 ext/gd/libgd/gd_interpolation.c if (x >= im->cx1 && x <= im->cx1) { im 1182 ext/gd/libgd/gd_interpolation.c border = im->tpixels[im->cy2][x]; im 1190 ext/gd/libgd/gd_interpolation.c if (x < im->cx1) { im 1191 ext/gd/libgd/gd_interpolation.c border = im->tpixels[y][im->cx1]; im 1195 ext/gd/libgd/gd_interpolation.c if (x > im->cx2) { im 1196 ext/gd/libgd/gd_interpolation.c border = im->tpixels[y][im->cx2]; im 1200 ext/gd/libgd/gd_interpolation.c if (border == im->transparent) { im 1208 ext/gd/libgd/gd_interpolation.c static gdImagePtr gdImageScaleBilinearPalette(gdImagePtr im, const unsigned int new_width, const unsigned int new_height) im 1212 ext/gd/libgd/gd_interpolation.c float dx = (float)gdImageSX(im) / (float)_width; im 1213 ext/gd/libgd/gd_interpolation.c float dy = (float)gdImageSY(im) / (float)_height; im 1222 ext/gd/libgd/gd_interpolation.c const int transparent = im->transparent; im 1228 ext/gd/libgd/gd_interpolation.c new_img->transparent = gdTrueColorAlpha(im->red[transparent], im->green[transparent], im->blue[transparent], im->alpha[transparent]); im 1261 ext/gd/libgd/gd_interpolation.c pixel1 = getPixelOverflowPalette(im, n, m, 0); im 1262 ext/gd/libgd/gd_interpolation.c pixel2 = getPixelOverflowPalette(im, n + 1, m, 0); im 1263 ext/gd/libgd/gd_interpolation.c pixel3 = getPixelOverflowPalette(im, n, m + 1, 0); im 1264 ext/gd/libgd/gd_interpolation.c pixel4 = getPixelOverflowPalette(im, n + 1, m + 1, 0); im 1300 ext/gd/libgd/gd_interpolation.c static gdImagePtr gdImageScaleBilinearTC(gdImagePtr im, const unsigned int new_width, const unsigned int new_height) im 1304 ext/gd/libgd/gd_interpolation.c float dx = (float)gdImageSX(im) / (float)dst_w; im 1305 ext/gd/libgd/gd_interpolation.c float dy = (float)gdImageSY(im) / (float)dst_h; im 1349 ext/gd/libgd/gd_interpolation.c pixel1 = getPixelOverflowTC(im, n, m, 0); im 1350 ext/gd/libgd/gd_interpolation.c pixel2 = getPixelOverflowTC(im, n + 1, m, 0); im 1351 ext/gd/libgd/gd_interpolation.c pixel3 = getPixelOverflowTC(im, n, m + 1, 0); im 1352 ext/gd/libgd/gd_interpolation.c pixel4 = getPixelOverflowTC(im, n + 1, m + 1, 0); im 1387 ext/gd/libgd/gd_interpolation.c gdImagePtr gdImageScaleBilinear(gdImagePtr im, const unsigned int new_width, const unsigned int new_height) im 1389 ext/gd/libgd/gd_interpolation.c if (im->trueColor) { im 1390 ext/gd/libgd/gd_interpolation.c return gdImageScaleBilinearTC(im, new_width, new_height); im 1392 ext/gd/libgd/gd_interpolation.c return gdImageScaleBilinearPalette(im, new_width, new_height); im 2223 ext/gd/libgd/gd_interpolation.c static void gdImageClipRectangle(gdImagePtr im, gdRectPtr r) im 2228 ext/gd/libgd/gd_interpolation.c gdImageGetClip(im, &c1x, &c1y, &c2x, &c2y); im 2478 ext/gd/libgd/gd_interpolation.c int gdImageSetInterpolationMethod(gdImagePtr im, gdInterpolationMethod id) im 2480 ext/gd/libgd/gd_interpolation.c if (im == NULL || id < 0 || id > GD_METHOD_COUNT) { im 2492 ext/gd/libgd/gd_interpolation.c im->interpolation = NULL; im 2497 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_bell; im 2500 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_bessel; im 2503 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_bicubic; im 2506 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_blackman; im 2509 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_box; im 2512 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_bspline; im 2515 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_catmullrom; im 2518 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_gaussian; im 2521 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_generalized_cubic; im 2524 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_hermite; im 2527 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_hamming; im 2530 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_hanning; im 2533 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_mitchell; im 2536 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_power; im 2539 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_quadratic; im 2542 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_sinc; im 2545 ext/gd/libgd/gd_interpolation.c im->interpolation = filter_triangle; im 2552 ext/gd/libgd/gd_interpolation.c im->interpolation_id = id; im 144 ext/gd/libgd/gd_jpeg.c void gdImageJpeg (gdImagePtr im, FILE * outFile, int quality) im 147 ext/gd/libgd/gd_jpeg.c gdImageJpegCtx (im, out, quality); im 151 ext/gd/libgd/gd_jpeg.c void *gdImageJpegPtr (gdImagePtr im, int *size, int quality) im 155 ext/gd/libgd/gd_jpeg.c gdImageJpegCtx (im, out, quality); im 164 ext/gd/libgd/gd_jpeg.c void gdImageJpegCtx (gdImagePtr im, gdIOCtx * outfile, int quality) im 193 ext/gd/libgd/gd_jpeg.c cinfo.image_width = im->sx; im 194 ext/gd/libgd/gd_jpeg.c cinfo.image_height = im->sy; im 203 ext/gd/libgd/gd_jpeg.c if (gdImageGetInterlaced (im)) { im 221 ext/gd/libgd/gd_jpeg.c if (im->trueColor) { im 228 ext/gd/libgd/gd_jpeg.c for (i = 0; i < im->sy; i++) { im 229 ext/gd/libgd/gd_jpeg.c for (jidx = 0, j = 0; j < im->sx; j++) { im 230 ext/gd/libgd/gd_jpeg.c int val = im->tpixels[i][j]; im 243 ext/gd/libgd/gd_jpeg.c for (i = 0; i < im->sy; i++) { im 244 ext/gd/libgd/gd_jpeg.c for (jidx = 0, j = 0; j < im->sx; j++) { im 245 ext/gd/libgd/gd_jpeg.c int idx = im->pixels[i][j]; im 252 ext/gd/libgd/gd_jpeg.c row[jidx++] = im->red[idx]; im 253 ext/gd/libgd/gd_jpeg.c row[jidx++] = im->green[idx]; im 254 ext/gd/libgd/gd_jpeg.c row[jidx++] = im->blue[idx]; im 256 ext/gd/libgd/gd_jpeg.c row[jidx++] = im->red[idx] << 4; im 257 ext/gd/libgd/gd_jpeg.c row[jidx++] = im->green[idx] << 4; im 258 ext/gd/libgd/gd_jpeg.c row[jidx++] = im->blue[idx] << 4; im 283 ext/gd/libgd/gd_jpeg.c gdImagePtr im; im 285 ext/gd/libgd/gd_jpeg.c im = gdImageCreateFromJpegCtxEx(in, ignore_warning); im 288 ext/gd/libgd/gd_jpeg.c return im; im 298 ext/gd/libgd/gd_jpeg.c gdImagePtr im; im 300 ext/gd/libgd/gd_jpeg.c im = gdImageCreateFromJpegCtxEx(in, ignore_warning); im 303 ext/gd/libgd/gd_jpeg.c return im; im 327 ext/gd/libgd/gd_jpeg.c volatile gdImagePtr im = 0; im 350 ext/gd/libgd/gd_jpeg.c if (im) { im 351 ext/gd/libgd/gd_jpeg.c gdImageDestroy (im); im 378 ext/gd/libgd/gd_jpeg.c im = gdImageCreateTrueColor ((int) cinfo.image_width, (int) cinfo.image_height); im 379 ext/gd/libgd/gd_jpeg.c if (im == 0) { im 407 ext/gd/libgd/gd_jpeg.c gdImageInterlace (im, cinfo.progressive_mode != 0); im 448 ext/gd/libgd/gd_jpeg.c register int *tpix = im->tpixels[i]; im 461 ext/gd/libgd/gd_jpeg.c register int *tpix = im->tpixels[i]; im 485 ext/gd/libgd/gd_jpeg.c return im; im 492 ext/gd/libgd/gd_jpeg.c if (im) { im 493 ext/gd/libgd/gd_jpeg.c gdImageDestroy (im); im 3 ext/gd/libgd/gd_pixelate.c int gdImagePixelate(gdImagePtr im, int block_size, const unsigned int mode) im 14 ext/gd/libgd/gd_pixelate.c for (y = 0; y < im->sy; y += block_size) { im 15 ext/gd/libgd/gd_pixelate.c for (x = 0; x < im->sx; x += block_size) { im 16 ext/gd/libgd/gd_pixelate.c if (gdImageBoundsSafe(im, x, y)) { im 17 ext/gd/libgd/gd_pixelate.c int c = gdImageGetPixel(im, x, y); im 18 ext/gd/libgd/gd_pixelate.c gdImageFilledRectangle(im, x, y, x + block_size - 1, y + block_size - 1, c); im 24 ext/gd/libgd/gd_pixelate.c for (y = 0; y < im->sy; y += block_size) { im 25 ext/gd/libgd/gd_pixelate.c for (x = 0; x < im->sx; x += block_size) { im 34 ext/gd/libgd/gd_pixelate.c if (!gdImageBoundsSafe(im, x + cx, y + cy)) { im 37 ext/gd/libgd/gd_pixelate.c c = gdImageGetPixel(im, x + cx, y + cy); im 38 ext/gd/libgd/gd_pixelate.c a += gdImageAlpha(im, c); im 39 ext/gd/libgd/gd_pixelate.c r += gdImageRed(im, c); im 40 ext/gd/libgd/gd_pixelate.c g += gdImageGreen(im, c); im 41 ext/gd/libgd/gd_pixelate.c b += gdImageBlue(im, c); im 47 ext/gd/libgd/gd_pixelate.c c = gdImageColorResolveAlpha(im, r / total, g / total, b / total, a / total); im 48 ext/gd/libgd/gd_pixelate.c gdImageFilledRectangle(im, x, y, x + block_size - 1, y + block_size - 1, c); im 95 ext/gd/libgd/gd_png.c gdImagePtr im; im 97 ext/gd/libgd/gd_png.c im = gdImageCreateFromPngCtx(in); im 100 ext/gd/libgd/gd_png.c return im; im 105 ext/gd/libgd/gd_png.c gdImagePtr im; im 107 ext/gd/libgd/gd_png.c im = gdImageCreateFromPngCtx(in); im 109 ext/gd/libgd/gd_png.c return im; im 132 ext/gd/libgd/gd_png.c gdImagePtr im = NULL; im 196 ext/gd/libgd/gd_png.c im = gdImageCreateTrueColor((int) width, (int) height); im 198 ext/gd/libgd/gd_png.c im = gdImageCreate((int) width, (int) height); im 200 ext/gd/libgd/gd_png.c if (im == NULL) { im 222 ext/gd/libgd/gd_png.c if (im) { im 223 ext/gd/libgd/gd_png.c gdImageDestroy(im); im 245 ext/gd/libgd/gd_png.c im->alpha[i] = gdAlphaMax - (trans[i] >> 1); im 335 ext/gd/libgd/gd_png.c if (!im->trueColor) { im 336 ext/gd/libgd/gd_png.c im->colorsTotal = num_palette; im 338 ext/gd/libgd/gd_png.c open = im->open; im 340 ext/gd/libgd/gd_png.c im->red[i] = palette[i].red; im 341 ext/gd/libgd/gd_png.c im->green[i] = palette[i].green; im 342 ext/gd/libgd/gd_png.c im->blue[i] = palette[i].blue; im 353 ext/gd/libgd/gd_png.c im->transparent = transparent; im 354 ext/gd/libgd/gd_png.c im->interlace = (interlace_type == PNG_INTERLACE_ADAM7); im 366 ext/gd/libgd/gd_png.c im->tpixels[h][w] = gdTrueColor (r, g, b); im 386 ext/gd/libgd/gd_png.c im->tpixels[h][w] = gdTrueColorAlpha(r, g, b, a); im 396 ext/gd/libgd/gd_png.c im->pixels[h][w] = idx; im 402 ext/gd/libgd/gd_png.c if (!im->trueColor) { im 417 ext/gd/libgd/gd_png.c return im; im 420 ext/gd/libgd/gd_png.c void gdImagePngEx (gdImagePtr im, FILE * outFile, int level, int basefilter) im 423 ext/gd/libgd/gd_png.c gdImagePngCtxEx(im, out, level, basefilter); im 427 ext/gd/libgd/gd_png.c void gdImagePng (gdImagePtr im, FILE * outFile) im 430 ext/gd/libgd/gd_png.c gdImagePngCtxEx(im, out, -1, -1); im 434 ext/gd/libgd/gd_png.c void * gdImagePngPtr (gdImagePtr im, int *size) im 438 ext/gd/libgd/gd_png.c gdImagePngCtxEx(im, out, -1, -1); im 445 ext/gd/libgd/gd_png.c void * gdImagePngPtrEx (gdImagePtr im, int *size, int level, int basefilter) im 449 ext/gd/libgd/gd_png.c gdImagePngCtxEx(im, out, level, basefilter); im 455 ext/gd/libgd/gd_png.c void gdImagePngCtx (gdImagePtr im, gdIOCtx * outfile) im 457 ext/gd/libgd/gd_png.c gdImagePngCtxEx(im, outfile, -1, -1); im 464 ext/gd/libgd/gd_png.c void gdImagePngCtxEx (gdImagePtr im, gdIOCtx * outfile, int level, int basefilter) im 467 ext/gd/libgd/gd_png.c int width = im->sx; im 468 ext/gd/libgd/gd_png.c int height = im->sy; im 469 ext/gd/libgd/gd_png.c int colors = im->colorsTotal; im 470 ext/gd/libgd/gd_png.c int *open = im->open; im 477 ext/gd/libgd/gd_png.c volatile int transparent = im->transparent; im 535 ext/gd/libgd/gd_png.c if (!im->trueColor) { im 536 ext/gd/libgd/gd_png.c if (transparent >= im->colorsTotal || (transparent >= 0 && open[transparent])) { im 546 ext/gd/libgd/gd_png.c for (i = 0; i < im->colorsTotal; ++i) { im 556 ext/gd/libgd/gd_png.c if (colors < im->colorsTotal) { im 570 ext/gd/libgd/gd_png.c interlace_type = im->interlace ? PNG_INTERLACE_ADAM7 : PNG_INTERLACE_NONE; im 572 ext/gd/libgd/gd_png.c if (im->trueColor) { im 573 ext/gd/libgd/gd_png.c if (im->saveAlphaFlag) { im 585 ext/gd/libgd/gd_png.c if (im->trueColor && !im->saveAlphaFlag && (transparent >= 0)) { im 587 ext/gd/libgd/gd_png.c trans_rgb_value.red = gdTrueColorGetRed (im->transparent); im 588 ext/gd/libgd/gd_png.c trans_rgb_value.green = gdTrueColorGetGreen (im->transparent); im 589 ext/gd/libgd/gd_png.c trans_rgb_value.blue = gdTrueColorGetBlue (im->transparent); im 593 ext/gd/libgd/gd_png.c if (!im->trueColor) { im 604 ext/gd/libgd/gd_png.c for (i = 0; (i < im->colorsTotal); i++) { im 605 ext/gd/libgd/gd_png.c if ((!im->open[i]) && (im->alpha[i] != gdAlphaOpaque)) { im 611 ext/gd/libgd/gd_png.c for (i = 0; (i < im->colorsTotal); i++) { im 612 ext/gd/libgd/gd_png.c trans_values[i] = 255 - ((im->alpha[i] << 1) + (im->alpha[i] >> 6)); im 626 ext/gd/libgd/gd_png.c for (i = 0; i < im->colorsTotal; i++) { im 627 ext/gd/libgd/gd_png.c if (!im->open[i]) { im 628 ext/gd/libgd/gd_png.c if (im->alpha[i] != gdAlphaOpaque) { im 630 ext/gd/libgd/gd_png.c trans_values[j] = 255 - ((im->alpha[i] << 1) + (im->alpha[i] >> 6)); im 642 ext/gd/libgd/gd_png.c if (!im->trueColor) { im 644 ext/gd/libgd/gd_png.c for (i = 0; i < im->colorsTotal; ++i) { im 649 ext/gd/libgd/gd_png.c palette[mapping[i]].red = im->red[i]; im 650 ext/gd/libgd/gd_png.c palette[mapping[i]].green = im->green[i]; im 651 ext/gd/libgd/gd_png.c palette[mapping[i]].blue = im->blue[i]; im 655 ext/gd/libgd/gd_png.c palette[i].red = im->red[i]; im 656 ext/gd/libgd/gd_png.c palette[i].green = im->green[i]; im 657 ext/gd/libgd/gd_png.c palette[i].blue = im->blue[i]; im 677 ext/gd/libgd/gd_png.c if (im->trueColor) { im 679 ext/gd/libgd/gd_png.c int channels = im->saveAlphaFlag ? 4 : 3; im 683 ext/gd/libgd/gd_png.c int **ptpixels = im->tpixels; im 688 ext/gd/libgd/gd_png.c int saveAlphaFlag = im->saveAlphaFlag; im 735 ext/gd/libgd/gd_png.c row_pointers[j][i] = mapping[im->pixels[j][i]]; im 748 ext/gd/libgd/gd_png.c png_write_image(png_ptr, im->pixels); im 11 ext/gd/libgd/gd_ss.c extern void gdImagePngToSink (gdImagePtr im, gdSinkPtr out); im 20 ext/gd/libgd/gd_ss.c void gdImagePngToSink (gdImagePtr im, gdSinkPtr outSink) im 23 ext/gd/libgd/gd_ss.c gdImagePngCtx(im, out); im 30 ext/gd/libgd/gd_ss.c gdImagePtr im; im 32 ext/gd/libgd/gd_ss.c im = gdImageCreateFromPngCtx(in); im 36 ext/gd/libgd/gd_ss.c return im; im 39 ext/gd/libgd/gd_ss.c void gdImagePngToSink (gdImagePtr im, gdSinkPtr outSink) im 1759 ext/gd/libgd/gd_topal.c gdImagePtr gdImageCreatePaletteFromTrueColor (gdImagePtr im, int dither, int colorsWanted) im 1762 ext/gd/libgd/gd_topal.c gdImageTrueColorToPaletteBody(im, dither, colorsWanted, &nim); im 1766 ext/gd/libgd/gd_topal.c void gdImageTrueColorToPalette (gdImagePtr im, int dither, int colorsWanted) im 1768 ext/gd/libgd/gd_topal.c gdImageTrueColorToPaletteBody(im, dither, colorsWanted, 0); im 1957 ext/gd/libgd/gd_topal.c for (i = 0; (i < im->colorsTotal); i++) im 1959 ext/gd/libgd/gd_topal.c if (im->alpha[i] > mt) im 1962 ext/gd/libgd/gd_topal.c mt = im->alpha[i]; im 1965 ext/gd/libgd/gd_topal.c for (i = 0; (i < im->colorsTotal); i++) im 1967 ext/gd/libgd/gd_topal.c if (im->alpha[i] == mt) im 1969 ext/gd/libgd/gd_topal.c im->alpha[i] = gdAlphaTransparent; im 1977 ext/gd/libgd/gd_topal.c for (i = 0; (i < im->colorsTotal); i++) im 1979 ext/gd/libgd/gd_topal.c if (im->alpha[i] < mo) im 1982 ext/gd/libgd/gd_topal.c mo = im->alpha[i]; im 1985 ext/gd/libgd/gd_topal.c for (i = 0; (i < im->colorsTotal); i++) im 1987 ext/gd/libgd/gd_topal.c if (im->alpha[i] == mo) im 1989 ext/gd/libgd/gd_topal.c im->alpha[i] = gdAlphaOpaque; im 3 ext/gd/libgd/gd_transform.c void gdImageFlipVertical(gdImagePtr im) im 7 ext/gd/libgd/gd_transform.c if (im->trueColor) { im 8 ext/gd/libgd/gd_transform.c for (y = 0; y < im->sy / 2; y++) { im 9 ext/gd/libgd/gd_transform.c int *row_dst = im->tpixels[y]; im 10 ext/gd/libgd/gd_transform.c int *row_src = im->tpixels[im->sy - 1 - y]; im 11 ext/gd/libgd/gd_transform.c for (x = 0; x < im->sx; x++) { im 14 ext/gd/libgd/gd_transform.c row_dst[x] = im->tpixels[im->sy - 1 - y][x]; im 20 ext/gd/libgd/gd_transform.c for (y = 0; y < im->sy / 2; y++) { im 21 ext/gd/libgd/gd_transform.c for (x = 0; x < im->sx; x++) { im 22 ext/gd/libgd/gd_transform.c p = im->pixels[y][x]; im 23 ext/gd/libgd/gd_transform.c im->pixels[y][x] = im->pixels[im->sy - 1 - y][x]; im 24 ext/gd/libgd/gd_transform.c im->pixels[im->sy - 1 - y][x] = p; im 31 ext/gd/libgd/gd_transform.c void gdImageFlipHorizontal(gdImagePtr im) im 36 ext/gd/libgd/gd_transform.c if (im->trueColor) { im 39 ext/gd/libgd/gd_transform.c for (y = 0; y < im->sy; y++) { im 40 ext/gd/libgd/gd_transform.c px1 = im->tpixels[y]; im 41 ext/gd/libgd/gd_transform.c px2 = im->tpixels[y] + im->sx - 1; im 42 ext/gd/libgd/gd_transform.c for (x = 0; x < (im->sx >> 1); x++) { im 53 ext/gd/libgd/gd_transform.c for (y = 0; y < im->sy; y++) { im 54 ext/gd/libgd/gd_transform.c px1 = im->pixels[y]; im 55 ext/gd/libgd/gd_transform.c px2 = im->pixels[y] + im->sx - 1; im 56 ext/gd/libgd/gd_transform.c for (x = 0; x < (im->sx >> 1); x++) { im 67 ext/gd/libgd/gd_transform.c void gdImageFlipBoth(gdImagePtr im) im 69 ext/gd/libgd/gd_transform.c gdImageFlipVertical(im); im 70 ext/gd/libgd/gd_transform.c gdImageFlipHorizontal(im); im 131 ext/gd/libgd/gd_wbmp.c gdImagePtr im = NULL; im 139 ext/gd/libgd/gd_wbmp.c if (!(im = gdImageCreate (wbmp->width, wbmp->height))) { im 145 ext/gd/libgd/gd_wbmp.c white = gdImageColorAllocate(im, 255, 255, 255); im 147 ext/gd/libgd/gd_wbmp.c black = gdImageColorAllocate(im, 0, 0, 0); im 154 ext/gd/libgd/gd_wbmp.c gdImageSetPixel(im, col, row, white); im 156 ext/gd/libgd/gd_wbmp.c gdImageSetPixel(im, col, row, black); im 163 ext/gd/libgd/gd_wbmp.c return im; im 171 ext/gd/libgd/gd_wbmp.c gdImagePtr im; im 173 ext/gd/libgd/gd_wbmp.c im = gdImageCreateFromWBMPCtx(in); im 176 ext/gd/libgd/gd_wbmp.c return im; im 181 ext/gd/libgd/gd_wbmp.c gdImagePtr im; im 183 ext/gd/libgd/gd_wbmp.c im = gdImageCreateFromWBMPCtx(in); im 185 ext/gd/libgd/gd_wbmp.c return im; im 191 ext/gd/libgd/gd_wbmp.c void gdImageWBMP (gdImagePtr im, int fg, FILE * outFile) im 194 ext/gd/libgd/gd_wbmp.c gdImageWBMPCtx(im, fg, out); im 201 ext/gd/libgd/gd_wbmp.c void * gdImageWBMPPtr (gdImagePtr im, int *size, int fg) im 205 ext/gd/libgd/gd_wbmp.c gdImageWBMPCtx(im, fg, out); im 15 ext/gd/libgd/gd_webp.c gdImagePtr im; im 19 ext/gd/libgd/gd_webp.c im = gdImageCreateFromWebpCtx(in); im 22 ext/gd/libgd/gd_webp.c return im; im 28 ext/gd/libgd/gd_webp.c gdImagePtr im; im 32 ext/gd/libgd/gd_webp.c im = gdImageCreateFromWebpCtx(in); im 34 ext/gd/libgd/gd_webp.c return im; im 43 ext/gd/libgd/gd_webp.c gdImagePtr im; im 74 ext/gd/libgd/gd_webp.c im = gdImageCreateTrueColor(width, height); im 75 ext/gd/libgd/gd_webp.c if (!im) { im 83 ext/gd/libgd/gd_webp.c gdImageDestroy(im); im 92 ext/gd/libgd/gd_webp.c im->tpixels[y][x] = gdTrueColorAlpha(r, g, b, a); im 98 ext/gd/libgd/gd_webp.c im->saveAlphaFlag = 1; im 99 ext/gd/libgd/gd_webp.c return im; im 102 ext/gd/libgd/gd_webp.c void gdImageWebpCtx (gdImagePtr im, gdIOCtx * outfile, int quantization) im 110 ext/gd/libgd/gd_webp.c if (im == NULL) { im 114 ext/gd/libgd/gd_webp.c if (!gdImageTrueColor(im)) { im 123 ext/gd/libgd/gd_webp.c argb = (uint8_t *)gdMalloc(gdImageSX(im) * 4 * gdImageSY(im)); im 128 ext/gd/libgd/gd_webp.c for (y = 0; y < gdImageSY(im); y++) { im 129 ext/gd/libgd/gd_webp.c for (x = 0; x < gdImageSX(im); x++) { im 132 ext/gd/libgd/gd_webp.c c = im->tpixels[y][x]; im 145 ext/gd/libgd/gd_webp.c out_size = WebPEncodeRGBA(argb, gdImageSX(im), gdImageSY(im), gdImageSX(im) * 4, quantization, &out); im 157 ext/gd/libgd/gd_webp.c void gdImageWebpEx (gdImagePtr im, FILE * outFile, int quantization) im 160 ext/gd/libgd/gd_webp.c gdImageWebpCtx(im, out, quantization); im 164 ext/gd/libgd/gd_webp.c void gdImageWebp (gdImagePtr im, FILE * outFile) im 167 ext/gd/libgd/gd_webp.c gdImageWebpCtx(im, out, -1); im 171 ext/gd/libgd/gd_webp.c void * gdImageWebpPtr (gdImagePtr im, int *size) im 175 ext/gd/libgd/gd_webp.c gdImageWebpCtx(im, out, -1); im 182 ext/gd/libgd/gd_webp.c void * gdImageWebpPtrEx (gdImagePtr im, int *size, int quantization) im 186 ext/gd/libgd/gd_webp.c gdImageWebpCtx(im, out, quantization); im 39 ext/gd/libgd/gdft.c gdImageStringTTF (gdImage * im, int *brect, int fg, char *fontlist, im 43 ext/gd/libgd/gdft.c return gdImageStringFT (im, brect, fg, fontlist, ptsize, angle, x, y, string); im 48 ext/gd/libgd/gdft.c gdImageStringFTEx (gdImage * im, int *brect, int fg, char *fontlist, im 56 ext/gd/libgd/gdft.c gdImageStringFT (gdImage * im, int *brect, int fg, char *fontlist, im 138 ext/gd/libgd/gdft.c gdImagePtr im; /* key */ im 147 ext/gd/libgd/gdft.c gdImagePtr im; /* key */ im 563 ext/gd/libgd/gdft.c return (a->pixel == b->pixel && a->bgcolor == b->bgcolor && a->fgcolor == b->fgcolor && a->im == b->im); im 580 ext/gd/libgd/gdft.c gdImagePtr im; im 586 ext/gd/libgd/gdft.c im = a->im = b->im; im 597 ext/gd/libgd/gdft.c if (im->trueColor) { im 610 ext/gd/libgd/gdft.c a->tweencolor = gdImageColorResolve(im, im 611 ext/gd/libgd/gdft.c (pixel * im->red[fg] + npixel * im->red[bg]) / NUMCOLORS, im 612 ext/gd/libgd/gdft.c (pixel * im->green[fg] + npixel * im->green[bg]) / NUMCOLORS, im 613 ext/gd/libgd/gdft.c (pixel * im->blue[fg] + npixel * im->blue[bg]) / NUMCOLORS); im 625 ext/gd/libgd/gdft.c static char * gdft_draw_bitmap (gdCache_head_t *tc_cache, gdImage * im, int fg, FT_Bitmap bitmap, int pen_x, int pen_y) im 636 ext/gd/libgd/gdft.c tc_key.im = im; im 638 ext/gd/libgd/gdft.c if (im->trueColor) { im 645 ext/gd/libgd/gdft.c if ((y > im->cy2) || (y < im->cy1)) { im 661 ext/gd/libgd/gdft.c if ((fg >= 0) && (im->trueColor)) { im 673 ext/gd/libgd/gdft.c if ((x > im->cx2) || (x < im->cx1)) { im 677 ext/gd/libgd/gdft.c tpixel = &im->tpixels[y][x]; im 683 ext/gd/libgd/gdft.c if (im->alphaBlendingFlag) { im 704 ext/gd/libgd/gdft.c if (y >= im->sy || y < 0) { im 727 ext/gd/libgd/gdft.c if (x >= im->sx || x < 0) { im 731 ext/gd/libgd/gdft.c pixel = &im->pixels[y][x]; im 801 ext/gd/libgd/gdft.c gdImageStringFT (gdImage * im, int *brect, int fg, char *fontlist, im 804 ext/gd/libgd/gdft.c return gdImageStringFTEx(im, brect, fg, fontlist, ptsize, angle, x, y, string, 0); im 808 ext/gd/libgd/gdft.c gdImageStringFTEx (gdImage * im, int *brect, int fg, char *fontlist, double ptsize, double angle, int x, int y, char *string, gdFTStringExtraPtr strex) im 828 ext/gd/libgd/gdft.c int render = (im && (im->trueColor || (fg <= 255 && fg >= -255))); im 1150 ext/gd/libgd/gdft.c gdft_draw_bitmap(tc_cache, im, fg, bm->bitmap, x + x1 + ((pen.x + 31) >> 6) + bm->left, y + y1 + ((pen.y + 31) >> 6) - bm->top); im 13 ext/gd/libgd/gdparttopng.c gdImagePtr im; im 36 ext/gd/libgd/gdparttopng.c im = gdImageCreateFromGd2Part (in, x, y, w, h); im 38 ext/gd/libgd/gdparttopng.c if (!im) im 47 ext/gd/libgd/gdparttopng.c gdImageDestroy (im); im 51 ext/gd/libgd/gdparttopng.c gdImagePng (im, out); im 56 ext/gd/libgd/gdparttopng.c gdImageDestroy (im); im 22 ext/gd/libgd/gdtest.c gdImagePtr im, ref, im2, im3; im 44 ext/gd/libgd/gdtest.c im = gdImageCreateFromPng (in); im 53 ext/gd/libgd/gdtest.c CompareImages ("Initial Versions", ref, im); im 61 ext/gd/libgd/gdtest.c gdImagePng (im, out); im 78 ext/gd/libgd/gdtest.c iptr = gdImagePngPtr (im, &sz); im 93 ext/gd/libgd/gdtest.c gdImageGd2 (im, out, 128, 2); im 110 ext/gd/libgd/gdtest.c iptr = gdImageGd2Ptr (im, 128, 2, &sz); im 128 ext/gd/libgd/gdtest.c gdImageGd (im, out); im 145 ext/gd/libgd/gdtest.c iptr = gdImageGdPtr (im, &sz); im 187 ext/gd/libgd/gdtest.c gdImagePngToSink (im, &imgsnk); im 280 ext/gd/libgd/gdtest.c gdImageJpeg (im, out, -1); im 304 ext/gd/libgd/gdtest.c foreground = gdImageColorClosest (im, 0, 0, 0); im 318 ext/gd/libgd/gdtest.c gdImageWBMP (im, foreground, out); im 353 ext/gd/libgd/gdtest.c gdImageDestroy (im); im 31 ext/gd/libgd/gdtestft.c gdImagePtr im; im 71 ext/gd/libgd/gdtestft.c im = gdImageCreate (500, 500); im 74 ext/gd/libgd/gdtestft.c im = gdImageCreateTrueColor (x, y); im 79 ext/gd/libgd/gdtestft.c white = gdImageColorResolve (im, 255, 255, 255); im 80 ext/gd/libgd/gdtestft.c gdImageFilledRectangle (im, 0, 0, x, y, white); im 81 ext/gd/libgd/gdtestft.c black = gdImageColorResolve (im, 0, 0, 0); im 87 ext/gd/libgd/gdtestft.c err = gdImageStringFT (im, NULL, black, f, sz, angle, x, y, s); im 100 ext/gd/libgd/gdtestft.c gdImagePng (im, out); im 104 ext/gd/libgd/gdtestft.c gdImageDestroy (im); im 12 ext/gd/libgd/gdtopng.c gdImagePtr im; im 25 ext/gd/libgd/gdtopng.c im = gdImageCreateFromGd (in); im 27 ext/gd/libgd/gdtopng.c if (!im) im 36 ext/gd/libgd/gdtopng.c gdImageDestroy (im); im 39 ext/gd/libgd/gdtopng.c gdImagePng (im, out); im 41 ext/gd/libgd/gdtopng.c gdImageDestroy (im); im 24 ext/gd/libgd/gdxpm.c gdImagePtr im = 0; im 41 ext/gd/libgd/gdxpm.c if (!(im = gdImageCreate(image.width, image.height))) { im 122 ext/gd/libgd/gdxpm.c colors[i] = gdImageColorResolve(im, red, green, blue); im 129 ext/gd/libgd/gdxpm.c gdImageSetPixel(im, j, i, colors[k]); im 137 ext/gd/libgd/gdxpm.c return im; im 13 ext/gd/libgd/pngtogd.c gdImagePtr im; im 26 ext/gd/libgd/pngtogd.c im = gdImageCreateFromPng (in); im 28 ext/gd/libgd/pngtogd.c if (!im) im 37 ext/gd/libgd/pngtogd.c gdImageDestroy (im); im 40 ext/gd/libgd/pngtogd.c gdImageGd (im, out); im 42 ext/gd/libgd/pngtogd.c gdImageDestroy (im); im 14 ext/gd/libgd/pngtogd2.c gdImagePtr im; im 31 ext/gd/libgd/pngtogd2.c im = gdImageCreateFromPng (in); im 33 ext/gd/libgd/pngtogd2.c if (!im) im 42 ext/gd/libgd/pngtogd2.c gdImageDestroy (im); im 47 ext/gd/libgd/pngtogd2.c gdImageGd2 (im, out, cs, fmt); im 49 ext/gd/libgd/pngtogd2.c gdImageDestroy (im); im 28 ext/gd/libgd/webpng.c gdImagePtr im = 0; im 61 ext/gd/libgd/webpng.c im = gdImageCreateFromPng (in); im 64 ext/gd/libgd/webpng.c if (!im) im 92 ext/gd/libgd/webpng.c gdImageInterlace (im, 1); im 97 ext/gd/libgd/webpng.c gdImageInterlace (im, 0); im 124 ext/gd/libgd/webpng.c gdImageColorTransparent (im, -1); im 130 ext/gd/libgd/webpng.c gdImageColorTransparent (im, index); im 140 ext/gd/libgd/webpng.c if (!im->trueColor) im 144 ext/gd/libgd/webpng.c for (j = 0; (j < gdImageColorsTotal (im)); j++) im 149 ext/gd/libgd/webpng.c gdImageRed (im, j), im 150 ext/gd/libgd/webpng.c gdImageGreen (im, j), im 151 ext/gd/libgd/webpng.c gdImageBlue (im, j), im 152 ext/gd/libgd/webpng.c gdImageAlpha (im, j)); im 166 ext/gd/libgd/webpng.c gdImageSX (im), gdImageSY (im), im 167 ext/gd/libgd/webpng.c gdImageColorsTotal (im)); im 168 ext/gd/libgd/webpng.c t = gdImageGetTransparent (im); im 178 ext/gd/libgd/webpng.c if (gdImageGetInterlaced (im)) im 192 ext/gd/libgd/webpng.c maxx = gdImageSX(im); im 193 ext/gd/libgd/webpng.c maxy = gdImageSY(im); im 197 ext/gd/libgd/webpng.c if (im->trueColor) { im 200 ext/gd/libgd/webpng.c pix = gdImageGetPixel(im, x, y); im 267 ext/gd/libgd/webpng.c gdImagePng (im, out); im 283 ext/gd/libgd/webpng.c if (im) im 285 ext/gd/libgd/webpng.c gdImageDestroy (im); im 43 ext/gd/libgd/xbm.c gdImagePtr im; im 99 ext/gd/libgd/xbm.c if(!(im = gdImageCreate(width, height))) { im 102 ext/gd/libgd/xbm.c gdImageColorAllocate(im, 255, 255, 255); im 103 ext/gd/libgd/xbm.c gdImageColorAllocate(im, 0, 0, 0); im 140 ext/gd/libgd/xbm.c gdImageSetPixel(im, x++, y, (b & bit) ? 1 : 0); im 141 ext/gd/libgd/xbm.c if (x == im->sx) { im 144 ext/gd/libgd/xbm.c if (y == im->sy) { im 145 ext/gd/libgd/xbm.c return im; im 153 ext/gd/libgd/xbm.c gdImageDestroy(im);