OOF: Finite Element Analysis of Microstructures

/select/modify/despeckle

/select/modify/despeckle

/select/modify/despeckle -- remove holes from a selected set of pixels

Synopsis

The purpose of this function is to capture unselected pixels which are not part of the current selection.

Some colors are represented in images by mixing ``microscopic'' textures of pixels so that the ``macroscopic'' color appears to be closer to a specified value. When a selection is obtained through a Burn or RGB Burn operation, pixels which were intended to become part of the current selection can be ``left behind''. Noise in a micrgraph can lead to the same effect.

Despeckle works by asking each non-selected pixel how many of its neighbors are selected. If that number is greater than equal to despeckle's argument, then the non-selected pixel becomes part of the current selection. Despeckle is recursive, so that when a new pixel is selected, the neighbor counts of its neighbors are updated.

Arguments

neighbors

The minimum number of selected neighbors an unselected pixel must have to become part of the current selection . The only reasonable values are 4-8. [26] A value of 4 tends to produce selected regions with unrealistic straight edges. Default: 8



[26] Because despeckle is recursive, values less than 4 would make the selected region grow without bound.