摘要 |
The invention relates to a method and an apparatus for cutting out, from a gray-scale image of a character string, each character in the character string. A first step of repeating projection processing for an axis along the character string in the gray-scale image with a projection target position changed, a second step of extracting a local maximum value and a local minimum value from a generated projected pattern P and setting, between a variable range of the local maximum value and a variable range of the local minimum value, a straight line M inclined in accordance with the variation of the values, and a third step of setting a cut out target range and cutting out an image in the range, are performed. When the character in the gray-scale image is darker than a background, a lowest gray level in the line along the character string is projected in the first step, and a range, in which a gray level lower than the straight line M in the projected pattern P is projected, is set as the cut out target range in the third step. When the character in the gray-scale image is brighter than the background, a highest gray level in the line along the character string is projected in the first step, and a range, in which a gray level higher than the straight line M in the projected pattern P is projected, is set as the cut out target range in the third step. |