<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <title>Applies a filter to an image</title> </head> <body><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.imagefilltoborder.html">imagefilltoborder</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.imageflip.html">imageflip</a></div> <div class="up"><a href="ref.image.html">GD and Image Functions</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div><hr /><div id="function.imagefilter" class="refentry"> <div class="refnamediv"> <h1 class="refname">imagefilter</h1> <p class="verinfo">(PHP 5, PHP 7)</p><p class="refpurpose"><span class="refname">imagefilter</span> — <span class="dc-title">Applies a filter to an image</span></p> </div> <div class="refsect1 description" id="refsect1-function.imagefilter-description"> <h3 class="title">Description</h3> <div class="methodsynopsis dc-description"> <span class="type">bool</span> <span class="methodname"><strong>imagefilter</strong></span> ( <span class="methodparam"><span class="type">resource</span> <code class="parameter">$image</code></span> , <span class="methodparam"><span class="type">int</span> <code class="parameter">$filtertype</code></span> [, <span class="methodparam"><span class="type">int</span> <code class="parameter">$arg1</code></span> [, <span class="methodparam"><span class="type">int</span> <code class="parameter">$arg2</code></span> [, <span class="methodparam"><span class="type">int</span> <code class="parameter">$arg3</code></span> [, <span class="methodparam"><span class="type">int</span> <code class="parameter">$arg4</code></span> ]]]] )</div> <p class="para rdfs-comment"> <span class="function"><strong>imagefilter()</strong></span> applies the given filter <code class="parameter">filtertype</code> on the <code class="parameter">image</code>. </p> </div> <div class="refsect1 parameters" id="refsect1-function.imagefilter-parameters"> <h3 class="title">Parameters</h3> <p class="para"> <dl> <dt> <code class="parameter"> image</code></dt> <dd> <p class="para">An image resource, returned by one of the image creation functions, such as <span class="function"><a href="function.imagecreatetruecolor.html" class="function">imagecreatetruecolor()</a></span>.</p></dd> <dt> <code class="parameter">filtertype</code></dt> <dd> <p class="para"> <code class="parameter">filtertype</code> can be one of the following: <ul class="itemizedlist"> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_NEGATE</code></strong>: Reverses all colors of the image. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_GRAYSCALE</code></strong>: Converts the image into grayscale by changing the red, green and blue components to their weighted sum using the same coefficients as the REC.601 luma (Y') calculation. The alpha components are retained. For palette images the result may differ due to palette limitations. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_BRIGHTNESS</code></strong>: Changes the brightness of the image. Use <code class="parameter">arg1</code> to set the level of brightness. The range for the brightness is -255 to 255. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_CONTRAST</code></strong>: Changes the contrast of the image. Use <code class="parameter">arg1</code> to set the level of contrast. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_COLORIZE</code></strong>: Like <strong><code>IMG_FILTER_GRAYSCALE</code></strong>, except you can specify the color. Use <code class="parameter">arg1</code>, <code class="parameter">arg2</code> and <code class="parameter">arg3</code> in the form of <code class="parameter">red</code>, <code class="parameter">green</code>, <code class="parameter">blue</code> and <code class="parameter">arg4</code> for the <code class="parameter">alpha</code> channel. The range for each color is 0 to 255. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_EDGEDETECT</code></strong>: Uses edge detection to highlight the edges in the image. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_EMBOSS</code></strong>: Embosses the image. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_GAUSSIAN_BLUR</code></strong>: Blurs the image using the Gaussian method. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_SELECTIVE_BLUR</code></strong>: Blurs the image. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_MEAN_REMOVAL</code></strong>: Uses mean removal to achieve a "sketchy" effect. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_SMOOTH</code></strong>: Makes the image smoother. Use <code class="parameter">arg1</code> to set the level of smoothness. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_PIXELATE</code></strong>: Applies pixelation effect to the image, use <code class="parameter">arg1</code> to set the block size and <code class="parameter">arg2</code> to set the pixelation effect mode. </span> </li> </ul> </p> </dd> <dt> <code class="parameter">arg1</code></dt> <dd> <p class="para"> <ul class="itemizedlist"> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_BRIGHTNESS</code></strong>: Brightness level. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_CONTRAST</code></strong>: Contrast level. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_COLORIZE</code></strong>: Value of red component. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_SMOOTH</code></strong>: Smoothness level. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_PIXELATE</code></strong>: Block size in pixels. </span> </li> </ul> </p> </dd> <dt> <code class="parameter">arg2</code></dt> <dd> <p class="para"> <ul class="itemizedlist"> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_COLORIZE</code></strong>: Value of green component. </span> </li> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_PIXELATE</code></strong>: Whether to use advanced pixelation effect or not (defaults to <strong><code>FALSE</code></strong>). </span> </li> </ul> </p> </dd> <dt> <code class="parameter">arg3</code></dt> <dd> <p class="para"> <ul class="itemizedlist"> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_COLORIZE</code></strong>: Value of blue component. </span> </li> </ul> </p> </dd> <dt> <code class="parameter">arg4</code></dt> <dd> <p class="para"> <ul class="itemizedlist"> <li class="listitem"> <span class="simpara"> <strong><code>IMG_FILTER_COLORIZE</code></strong>: Alpha channel, A value between 0 and 127. 0 indicates completely opaque while 127 indicates completely transparent. </span> </li> </ul> </p> </dd> </dl> </p> </div> <div class="refsect1 returnvalues" id="refsect1-function.imagefilter-returnvalues"> <h3 class="title">Return Values</h3> <p class="para"> Returns <strong><code>TRUE</code></strong> on success or <strong><code>FALSE</code></strong> on failure. </p> </div> <div class="refsect1 changelog" id="refsect1-function.imagefilter-changelog"> <h3 class="title">Changelog</h3> <p class="para"> <table class="doctable informaltable"> <thead> <tr> <th>Version</th> <th>Description</th> </tr> </thead> <tbody class="tbody"> <tr> <td>5.3.0</td> <td> Pixelation support (<strong><code>IMG_FILTER_PIXELATE</code></strong>) was added. </td> </tr> <tr> <td>5.2.5</td> <td> Alpha support for <strong><code>IMG_FILTER_COLORIZE</code></strong> was added. </td> </tr> </tbody> </table> </p> </div> <div class="refsect1 examples" id="refsect1-function.imagefilter-examples"> <h3 class="title">Examples</h3> <p class="para"> <div class="example" id="example-3797"> <p><strong>Example #1 <span class="function"><strong>imagefilter()</strong></span> grayscale example</strong></p> <div class="example-contents"> <div class="phpcode"><code><span style="color: #000000"> <span style="color: #0000BB"><?php<br />$im </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecreatefrompng</span><span style="color: #007700">(</span><span style="color: #DD0000">'dave.png'</span><span style="color: #007700">);<br /><br />if(</span><span style="color: #0000BB">$im </span><span style="color: #007700">&& </span><span style="color: #0000BB">imagefilter</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #0000BB">IMG_FILTER_GRAYSCALE</span><span style="color: #007700">))<br />{<br /> echo </span><span style="color: #DD0000">'Image converted to grayscale.'</span><span style="color: #007700">;<br /><br /> </span><span style="color: #0000BB">imagepng</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #DD0000">'dave.png'</span><span style="color: #007700">);<br />}<br />else<br />{<br /> echo </span><span style="color: #DD0000">'Conversion to grayscale failed.'</span><span style="color: #007700">;<br />}<br /><br /></span><span style="color: #0000BB">imagedestroy</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?></span> </span> </code></div> </div> </div> </p> <p class="para"> <div class="example" id="example-3798"> <p><strong>Example #2 <span class="function"><strong>imagefilter()</strong></span> brightness example</strong></p> <div class="example-contents"> <div class="phpcode"><code><span style="color: #000000"> <span style="color: #0000BB"><?php<br />$im </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecreatefrompng</span><span style="color: #007700">(</span><span style="color: #DD0000">'sean.png'</span><span style="color: #007700">);<br /><br />if(</span><span style="color: #0000BB">$im </span><span style="color: #007700">&& </span><span style="color: #0000BB">imagefilter</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #0000BB">IMG_FILTER_BRIGHTNESS</span><span style="color: #007700">, </span><span style="color: #0000BB">20</span><span style="color: #007700">))<br />{<br /> echo </span><span style="color: #DD0000">'Image brightness changed.'</span><span style="color: #007700">;<br /><br /> </span><span style="color: #0000BB">imagepng</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #DD0000">'sean.png'</span><span style="color: #007700">);<br /> </span><span style="color: #0000BB">imagedestroy</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">);<br />}<br />else<br />{<br /> echo </span><span style="color: #DD0000">'Image brightness change failed.'</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?></span> </span> </code></div> </div> </div> </p> <p class="para"> <div class="example" id="example-3799"> <p><strong>Example #3 <span class="function"><strong>imagefilter()</strong></span> colorize example</strong></p> <div class="example-contents"> <div class="phpcode"><code><span style="color: #000000"> <span style="color: #0000BB"><?php<br />$im </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecreatefrompng</span><span style="color: #007700">(</span><span style="color: #DD0000">'philip.png'</span><span style="color: #007700">);<br /><br /></span><span style="color: #FF8000">/* R, G, B, so 0, 255, 0 is green */<br /></span><span style="color: #007700">if(</span><span style="color: #0000BB">$im </span><span style="color: #007700">&& </span><span style="color: #0000BB">imagefilter</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #0000BB">IMG_FILTER_COLORIZE</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">255</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">))<br />{<br /> echo </span><span style="color: #DD0000">'Image successfully shaded green.'</span><span style="color: #007700">;<br /><br /> </span><span style="color: #0000BB">imagepng</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #DD0000">'philip.png'</span><span style="color: #007700">);<br /> </span><span style="color: #0000BB">imagedestroy</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">);<br />}<br />else<br />{<br /> echo </span><span style="color: #DD0000">'Green shading failed.'</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?></span> </span> </code></div> </div> </div> </p> <p class="para"> <div class="example" id="imagecrop.example.basic"> <p><strong>Example #4 <span class="function"><strong>imagefilter()</strong></span> negate example</strong></p> <div class="example-contents"> <div class="phpcode"><code><span style="color: #000000"> <span style="color: #0000BB"><?php<br /></span><span style="color: #FF8000">// Define our negate function so its portable for <br />// php versions without imagefilter()<br /></span><span style="color: #007700">function </span><span style="color: #0000BB">negate</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">)<br />{<br /> if(</span><span style="color: #0000BB">function_exists</span><span style="color: #007700">(</span><span style="color: #DD0000">'imagefilter'</span><span style="color: #007700">))<br /> {<br /> return </span><span style="color: #0000BB">imagefilter</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #0000BB">IMG_FILTER_NEGATE</span><span style="color: #007700">);<br /> }<br /><br /> for(</span><span style="color: #0000BB">$x </span><span style="color: #007700">= </span><span style="color: #0000BB">0</span><span style="color: #007700">; </span><span style="color: #0000BB">$x </span><span style="color: #007700">< </span><span style="color: #0000BB">imagesx</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">); ++</span><span style="color: #0000BB">$x</span><span style="color: #007700">)<br /> {<br /> for(</span><span style="color: #0000BB">$y </span><span style="color: #007700">= </span><span style="color: #0000BB">0</span><span style="color: #007700">; </span><span style="color: #0000BB">$y </span><span style="color: #007700">< </span><span style="color: #0000BB">imagesy</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">); ++</span><span style="color: #0000BB">$y</span><span style="color: #007700">)<br /> {<br /> </span><span style="color: #0000BB">$index </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecolorat</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #0000BB">$x</span><span style="color: #007700">, </span><span style="color: #0000BB">$y</span><span style="color: #007700">);<br /> </span><span style="color: #0000BB">$rgb </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecolorsforindex</span><span style="color: #007700">(</span><span style="color: #0000BB">$index</span><span style="color: #007700">);<br /> </span><span style="color: #0000BB">$color </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecolorallocate</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #0000BB">255 </span><span style="color: #007700">- </span><span style="color: #0000BB">$rgb</span><span style="color: #007700">[</span><span style="color: #DD0000">'red'</span><span style="color: #007700">], </span><span style="color: #0000BB">255 </span><span style="color: #007700">- </span><span style="color: #0000BB">$rgb</span><span style="color: #007700">[</span><span style="color: #DD0000">'green'</span><span style="color: #007700">], </span><span style="color: #0000BB">255 </span><span style="color: #007700">- </span><span style="color: #0000BB">$rgb</span><span style="color: #007700">[</span><span style="color: #DD0000">'blue'</span><span style="color: #007700">]);<br /><br /> </span><span style="color: #0000BB">imagesetpixel</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #0000BB">$x</span><span style="color: #007700">, </span><span style="color: #0000BB">$y</span><span style="color: #007700">, </span><span style="color: #0000BB">$color</span><span style="color: #007700">);<br /> }<br /> }<br /><br /> return(</span><span style="color: #0000BB">true</span><span style="color: #007700">);<br />}<br /><br /></span><span style="color: #0000BB">$im </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecreatefromjpeg</span><span style="color: #007700">(</span><span style="color: #DD0000">'kalle.jpg'</span><span style="color: #007700">);<br /><br />if(</span><span style="color: #0000BB">$im </span><span style="color: #007700">&& </span><span style="color: #0000BB">negate</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">))<br />{<br /> echo </span><span style="color: #DD0000">'Image successfully converted to negative colors.'</span><span style="color: #007700">;<br /><br /> </span><span style="color: #0000BB">imagejpeg</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">, </span><span style="color: #DD0000">'kalle.jpg'</span><span style="color: #007700">, </span><span style="color: #0000BB">100</span><span style="color: #007700">);<br /> </span><span style="color: #0000BB">imagedestroy</span><span style="color: #007700">(</span><span style="color: #0000BB">$im</span><span style="color: #007700">);<br />}<br />else<br />{<br /> echo </span><span style="color: #DD0000">'Converting to negative colors failed.'</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?></span> </span> </code></div> </div> </div> </p> <p class="para"> <div class="example" id="example-3801"> <p><strong>Example #5 <span class="function"><strong>imagefilter()</strong></span> pixelate example</strong></p> <div class="example-contents"> <div class="phpcode"><code><span style="color: #000000"> <span style="color: #0000BB"><?php<br /></span><span style="color: #FF8000">// Load the PHP logo, we need to create two instances <br />// to show the differences<br /></span><span style="color: #0000BB">$logo1 </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecreatefrompng</span><span style="color: #007700">(</span><span style="color: #DD0000">'./php.png'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$logo2 </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecreatefrompng</span><span style="color: #007700">(</span><span style="color: #DD0000">'./php.png'</span><span style="color: #007700">);<br /><br /></span><span style="color: #FF8000">// Create the image instance we want to show the <br />// differences on<br /></span><span style="color: #0000BB">$output </span><span style="color: #007700">= </span><span style="color: #0000BB">imagecreatetruecolor</span><span style="color: #007700">(</span><span style="color: #0000BB">imagesx</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo1</span><span style="color: #007700">) * </span><span style="color: #0000BB">2</span><span style="color: #007700">, </span><span style="color: #0000BB">imagesy</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo1</span><span style="color: #007700">));<br /><br /></span><span style="color: #FF8000">// Apply pixelation to each instance, with a block <br />// size of 3<br /></span><span style="color: #0000BB">imagefilter</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo1</span><span style="color: #007700">, </span><span style="color: #0000BB">IMG_FILTER_PIXELATE</span><span style="color: #007700">, </span><span style="color: #0000BB">3</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">imagefilter</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo2</span><span style="color: #007700">, </span><span style="color: #0000BB">IMG_FILTER_PIXELATE</span><span style="color: #007700">, </span><span style="color: #0000BB">3</span><span style="color: #007700">, </span><span style="color: #0000BB">true</span><span style="color: #007700">);<br /><br /></span><span style="color: #FF8000">// Merge the differences onto the output image<br /></span><span style="color: #0000BB">imagecopy</span><span style="color: #007700">(</span><span style="color: #0000BB">$output</span><span style="color: #007700">, </span><span style="color: #0000BB">$logo1</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">imagesx</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo1</span><span style="color: #007700">) - </span><span style="color: #0000BB">1</span><span style="color: #007700">, </span><span style="color: #0000BB">imagesy</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo1</span><span style="color: #007700">) - </span><span style="color: #0000BB">1</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">imagecopy</span><span style="color: #007700">(</span><span style="color: #0000BB">$output</span><span style="color: #007700">, </span><span style="color: #0000BB">$logo2</span><span style="color: #007700">, </span><span style="color: #0000BB">imagesx</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo2</span><span style="color: #007700">), </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">0</span><span style="color: #007700">, </span><span style="color: #0000BB">imagesx</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo2</span><span style="color: #007700">) - </span><span style="color: #0000BB">1</span><span style="color: #007700">, </span><span style="color: #0000BB">imagesy</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo2</span><span style="color: #007700">) - </span><span style="color: #0000BB">1</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">imagedestroy</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo1</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">imagedestroy</span><span style="color: #007700">(</span><span style="color: #0000BB">$logo2</span><span style="color: #007700">);<br /><br /></span><span style="color: #FF8000">// Output the differences<br /></span><span style="color: #0000BB">header</span><span style="color: #007700">(</span><span style="color: #DD0000">'Content-Type: image/png'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">imagepng</span><span style="color: #007700">(</span><span style="color: #0000BB">$output</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">imagedestroy</span><span style="color: #007700">(</span><span style="color: #0000BB">$output</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?></span> </span> </code></div> </div> <div class="example-contents"><p>The above example will output something similar to:</p></div> <div class="mediaobject"> <div class="imageobject"> <img src="images/21009b70229598c6a80eef8b45bf282b-imagefilterpixelate.png" alt="Output of example : imagefilter() pixelate" width="190" height="51" /> </div> </div> </div> </p> </div> <div class="refsect1 notes" id="refsect1-function.imagefilter-notes"> <h3 class="title">Notes</h3> </div> <div class="refsect1 seealso" id="refsect1-function.imagefilter-seealso"> <h3 class="title">See Also</h3> <p class="para"> <ul class="simplelist"> <li class="member"><span class="function"><a href="function.imageconvolution.html" class="function" rel="rdfs-seeAlso">imageconvolution()</a> - Apply a 3x3 convolution matrix, using coefficient and offset</span></li> </ul> </p> </div> </div><hr /><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.imagefilltoborder.html">imagefilltoborder</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.imageflip.html">imageflip</a></div> <div class="up"><a href="ref.image.html">GD and Image Functions</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div></body></html>