 <p>You asked about Java, but in case you meant something more basic I will try to answer more generally.</p> <p>Given a Filter Coefficients (You have an approximation of the Laplacian filter) the way to apply it on an image is <a href="http://en.wikipedia.org/wiki/Convolution" rel="nofollow">Convolution</a> (Assuming the Filter is LSI - Linear Spatially Invariant).</p> <p>The convolution can be computed directly (Loops) of in the frequency domain (Using <a href="http://en.wikipedia.org/wiki/Convolution_theorem" rel="nofollow">Convolution Theorem</a>).</p> <p>There are few things to consider (Real World Problems):</p> <ol> <li>The convolution "Asks" for pixels beyond the image. Hence boundary conditions should be imposed ("Pixels" beyond the image are zero, constant, nearest neighbor, etc...).</li> <li>The result of the convolution is bigger then the input image due to the "Filter Transient". Again, logical decision should be made.</li> <li>If you're limited to Fixed Point math, proper scaling should be made after the operation (Rule of Thumb, built to keep the image mean, says the sum of all filter coefficients should be 1, hence you need the scaling).</li> </ol> <p>Good Luck.</p>