Digital Image Processing (using Java)
Digital Image Processing (using Java)
Digital Image Processing (using Java)
- No tags were found...
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Dilation: ƒ ♁ s(p.282)LISTING 11.1 BinaryErodeOp’s filter() method.public Buffered<strong>Image</strong> filter(Buffered<strong>Image</strong> src, Buffered<strong>Image</strong> dest) {check<strong>Image</strong>(src);if (dest == null)dest = createCompatibleDest<strong>Image</strong>(src, null);int w = src.getWidth();int h = src.getHeight();Raster srcRaster = src.getRaster();WritableRaster destRaster = dest.getRaster();// Determine range of pixels for which operation can be performedPoint origin = structElement.getOrigin(null);int xmin = Math.max(origin.x, 0);int ymin = Math.max(origin.y, 0);int xmax = origin.x + w - structElement.getWidth();- 69 -