Lines Matching refs:im
3 int gdImagePixelate(gdImagePtr im, int block_size, const unsigned int mode) in gdImagePixelate() argument
14 for (y = 0; y < im->sy; y += block_size) { in gdImagePixelate()
15 for (x = 0; x < im->sx; x += block_size) { in gdImagePixelate()
16 if (gdImageBoundsSafe(im, x, y)) { in gdImagePixelate()
17 int c = gdImageGetPixel(im, x, y); in gdImagePixelate()
18 gdImageFilledRectangle(im, x, y, x + block_size - 1, y + block_size - 1, c); in gdImagePixelate()
24 for (y = 0; y < im->sy; y += block_size) { in gdImagePixelate()
25 for (x = 0; x < im->sx; x += block_size) { in gdImagePixelate()
34 if (!gdImageBoundsSafe(im, x + cx, y + cy)) { in gdImagePixelate()
37 c = gdImageGetPixel(im, x + cx, y + cy); in gdImagePixelate()
38 a += gdImageAlpha(im, c); in gdImagePixelate()
39 r += gdImageRed(im, c); in gdImagePixelate()
40 g += gdImageGreen(im, c); in gdImagePixelate()
41 b += gdImageBlue(im, c); in gdImagePixelate()
47 c = gdImageColorResolveAlpha(im, r / total, g / total, b / total, a / total); in gdImagePixelate()
48 gdImageFilledRectangle(im, x, y, x + block_size - 1, y + block_size - 1, c); in gdImagePixelate()