Abstract An apparatus and method for reading, at high speed and with high precision, an angle of an angular modulation bar code directly from a multilevel brightness image of the bar code without the need for subjecting the image to preprocessing, such as binarization (conversion to a black-and-white image). The apparatus includes: means for dividing a multilevel brightness image of a bar code into a plurality of small sampling regions having the same area; means for detecting a maximum brightness value and a minimum brightness value among brightness values of pixels in each of the small sampling regions; means for setting a measurement origin and a threshold of light and dark in each of the small regions on the basis of the maximum and minimum brightness values; means for measuring a length from the measurement origin to a point where the brightness of the pixel reaches the threshold of light and dark in each of the small regions; means for accumulating, for each direction, length values measured in all the small regions, and for judging a direction having a maximum accumulated length value to be the bar code direction.
An apparatus for detecting the direction of a line segment in a multilevel brightness image, comprising: brightness detecting means for detecting brightness of a pixel in said image; means for selecting, from said image, a plurality of small sampling regions, each region having approximately the same area; means for detecting a maximum brightness value and a minimum brightness value among brightness values of the pixels in each of said small regions; means for setting a threshold of light and dark for each of said small regions on the basis of said maximum and minimum brightness values; means for setting a measurement origin in each of said small regions on the basis of said maximum and minimum brightness values; means for measuring a length from said measurement origin to a point where the brightness of the pixel reaches said threshold of light and dark for all directions in each of said small regions; and means for accumulating, for each direction, length values measured in said respective small regions and for selecting a direction having a maximum accumulated length value to be said line segment direction.
Claim 2
Independent Claim
184 words
An apparatus for detecting the direction of a line segment in a multilevel brightness image, comprising: brightness detecting means for detecting brightness of a pixel in said image; means for selecting, from said image, a plurality of small sampling regions, each region having approximately the same area; means for detecting a maximum brightness value and a minimum brightness value among brightness values of the pixels in each of said small regions; means for setting a threshold of light and dark for each of said small regions on the basis of said maximum and minimum brightness values; means for setting a measurement origin in each of said small regions on the basis of said maximum and minimum brightness values; means for measuring a length from said measurement origin to a point where the brightness of the pixel reaches said threshold of light and dark for all directions in each of said small regions; and means for accumulating, for each direction, length values measured in said respective small regions and for selecting a direction having a maximum accumulated length value to be said line segment direction.
Claim 3
Dependent Claim
13 words
The apparatus of claim 1, further comprising means for generating said multilevel image.
Claim 4
Independent Claim
150 words
A method for detecting the direction of a line segment in a multilevel brightness image, comprising the steps of: selecting, from said image, a plurality of sampling regions, each region having approximately the same area; detecting a maximum brightness value and a minimum brightness value among brightness values of pixels in each of said regions; selecting a threshold of light and dark for each of said regions in accordance with maximum and minimum brightness values; setting a measurement origin in each of said regions in accordance with said maximum and minimum brightness values; measuring a length from said measurement origin to a point where brightness of the pixel reaches said threshold of light and dark for all directions in each of said regions; accumulating, for each direction, length values measured in said respective regions; and selecting a direction having a maximum accumulated length value to be said line segment direction.
Claim 5
Independent Claim
150 words
A method for detecting the direction of a line segment in a multilevel brightness image, comprising the steps of: selecting, from said image, a plurality of sampling regions, each region having approximately the same area; detecting a maximum brightness value and a minimum brightness value among brightness values of pixels in each of said regions; selecting a threshold of light and dark for each of said regions in accordance with maximum and minimum brightness values; setting a measurement origin in each of said regions in accordance with said maximum and minimum brightness values; measuring a length from said measurement origin to a point where brightness of the pixel reaches said threshold of light and dark for all directions in each of said regions; accumulating, for each direction, length values measured in said respective regions; and selecting a direction having a maximum accumulated length value to be said line segment direction.
Claim 6
Dependent Claim
15 words
The method of claim 3 further comprising the step of generating said multilevel brightness image.