JP2891821B2 - Barcode identification method - Google Patents

Barcode identification method

Info

Publication number
JP2891821B2
JP2891821B2 JP4151446A JP15144692A JP2891821B2 JP 2891821 B2 JP2891821 B2 JP 2891821B2 JP 4151446 A JP4151446 A JP 4151446A JP 15144692 A JP15144692 A JP 15144692A JP 2891821 B2 JP2891821 B2 JP 2891821B2
Authority
JP
Japan
Prior art keywords
barcode
pixel
area
barcode symbol
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP4151446A
Other languages
Japanese (ja)
Other versions
JPH05324896A (en
Inventor
秀樹 水落
邦治 原
真一 加藤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NIPPON DENKI SEIKI KK
Original Assignee
NIPPON DENKI SEIKI KK
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NIPPON DENKI SEIKI KK filed Critical NIPPON DENKI SEIKI KK
Priority to JP4151446A priority Critical patent/JP2891821B2/en
Publication of JPH05324896A publication Critical patent/JPH05324896A/en
Application granted granted Critical
Publication of JP2891821B2 publication Critical patent/JP2891821B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】この発明は、バーコードシンボル
を含む領域を撮影した画像において不要な背景やノイズ
を除去して必要なバーコードシンボルのみを識別・抽出
することができるバーコードの識別方法に関するもので
ある。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a barcode identification method capable of removing unnecessary background and noise from an image of a region including a barcode symbol and identifying and extracting only a necessary barcode symbol. It is about.

【0002】[0002]

【従来の技術】バーコードラベル上に記録されたバーコ
ードシンボルを読取るために、各種の読取り方法が提案
され開発されている。例えばこのバーコードシンボルを
読取る一般的な方法としては、バーコードシンボルの存
在するエリア内に光源からの光を順次投光・走査しなが
ら読取っていくものや、バーコードシンボルの存在する
エリアを含む部分をCCDカメラ(エリアセンサ)等で
撮像し、この撮像した画像からバーコードシンボルの部
分を識別して読取っていくもの等が知られている。
2. Description of the Related Art Various reading methods have been proposed and developed for reading barcode symbols recorded on barcode labels. For example, a general method of reading the barcode symbol includes a method of sequentially reading and scanning light from a light source in an area where a barcode symbol exists, and a method of reading an area including a barcode symbol. It is known that a part is imaged by a CCD camera (area sensor) or the like, and a barcode symbol part is identified and read from the imaged image.

【0003】[0003]

【発明が解決しようとする課題】ところで、先の読取方
法のうち前者の場合には特にそれ程問題はないが、後者
の場合には撮像した画像中に背景やノイズが多数含まれ
ていると、バーコードシンボルを誤って認識し、読取り
不能となったり、読取り誤差を生じることがあり、問題
となっている。そこで、この発明は、上記した従来の欠
点に鑑み、バーコードシンボルの周辺に背景やノイズ等
があっても、バーコードシンボルのみを正確に認識する
ことができるバーコードの認識方法を提供することを目
的とするものである。
In the former reading method, there is no particular problem in the former method. However, in the latter method, if the captured image contains many backgrounds and noises, A barcode symbol is erroneously recognized, and reading becomes impossible or a reading error occurs, which is a problem. In view of the above-described conventional disadvantages, the present invention provides a barcode recognition method capable of accurately recognizing only a barcode symbol even when there is a background or noise around the barcode symbol. It is intended for.

【0004】[0004]

【課題を解決するための手段】即ち、この発明のバーコ
ードの識別方法は、画像内の連続する黒画素について隣
接する白画素を黒画素に変更する太め処理を行い、この
太め処理された処理画像中の連結する各黒画素領域の面
積を求め、これらの黒画素領域のうち最大面積のものを
バーコードシンボル領域として認識し、前記処理画像内
のバーコードシンボル領域と前記原画像とについて各画
素の論理積をとり、得られた黒画素からバーコードを識
別するものである。
That is, according to the barcode identification method of the present invention, for a continuous black pixel in an image, a thickening process of changing an adjacent white pixel to a black pixel is performed, and the thickened processing is performed. The area of each connected black pixel region in the image is determined, the largest one of these black pixel regions is recognized as a barcode symbol region, and each of the barcode symbol region and the original image in the processed image is A logical product of the pixels is obtained, and a bar code is identified from the obtained black pixels.

【0005】[0005]

【作用】この発明では、太め処理によって得られた各黒
画素領域の面積を求め、これらの黒画素領域のうち最大
のものをバーコードシンボルが含まれるバーコードシン
ボル領域として認識する。次に、このバーコードシンボ
ル領域と原画像とにおける各対応した画素での論理積を
求め、これによってバーコードシンボルの形状を正確に
認識する。
According to the present invention, the area of each black pixel region obtained by the thickening process is obtained, and the largest of these black pixel regions is recognized as a barcode symbol region including a barcode symbol. Next, the logical product of each corresponding pixel in the bar code symbol area and the original image is obtained, thereby accurately recognizing the shape of the bar code symbol.

【0006】[0006]

【実施例】以下この発明の一実施例について添付図面を
参照しながら説明する。図1はこの発明に係るバーコー
ドの識別方法を示すものであり、第1ステップ1〜第5
ステップ5から構成されている。第1ステップ1では、
CCDカメラ(エリアセンサ)等の撮像手段を用い、図
2に示すようにバーコードシンボル1全体が完全に含ま
れているような状態でバーコードを撮影する。そして、
この撮影された原画像αについて次に説明する太め処理
を行う。この太め処理とは、例えば図3において各黒画
素(例えば点P(10,11))の周囲、つまり上下左右の
8画素A〜Hについて白画素を全て黒画素に交換するこ
とをいう(図4参照)。なお、この黒画素へ交換する画
素としては、特にこの8画素に限定されるものではな
く、例えば図3において上下左右の隣合った4画素(A
CEG)でもよい。なお、この図2において、各罫線は
便宜上縦横2画素ずつの領域を区切るように付されてい
るものであり、従って実際にはこの枡目の4倍に相当す
る画素が存在するものとする。
An embodiment of the present invention will be described below with reference to the accompanying drawings. FIG. 1 shows a method of identifying a barcode according to the present invention.
It consists of step 5. In the first step 1,
Using an imaging means such as a CCD camera (area sensor) or the like, the barcode is photographed in a state where the entire barcode symbol 1 is completely included as shown in FIG. And
The thickening process described below is performed on the photographed original image α. This thickening process means, for example, replacing all white pixels with black pixels around each black pixel (for example, point P (10, 11)) in FIG. 4). It should be noted that the pixel to be replaced with the black pixel is not particularly limited to the eight pixels. For example, in FIG.
CEG). In FIG. 2, for the sake of convenience, each ruled line is attached so as to divide a region of two pixels vertically and horizontally, and therefore, it is assumed that there are actually pixels corresponding to four times the mesh.

【0007】第2ステップ2では、第1ステップ1にお
いて全黒画素について太め処理を行い、これによって得
られた図5に示す処理画像βにおいて、各黒画素領域S
1 〜S8 の面積(或は黒画素数)を求める。なお、この
図5でも、各罫線は便宜上縦横2画素ずつの単位領域を
示すために付されているものとする。第3ステップ3で
は、図5に示す処理画像βにおいて得られた各黒画素領
域S1 〜S8 のうち、最大面積のものS3 をバーコード
シンボル領域として認識する。第4ステップ4では、処
理画像βにおけるバーコードシンボル領域S3 として認
識されたエリア内の各画素と、原画像αにおける各画素
との間で、つまり対応する同一位置の画素どうしで論理
積をとる。例えば、黒画素を1、白画素を0として次表
のような演算を行う。これによって論理積が1となるも
ののみを黒画素として判別し、これがバーコードシンボ
ルの真正な形状の一部を示す画素として判別される。
In a second step 2, a thickening process is performed on all the black pixels in the first step 1, and in the processing image β thus obtained shown in FIG.
Determining the area of 1 to S 8 (or the number of black pixels). Note that in FIG. 5 as well, each ruled line is attached to indicate a unit area of two pixels vertically and horizontally for convenience. In the third step 3, out of the black pixel area S 1 to S 8 obtained in processing the image β shown in FIG. 5 recognizes the S 3 the largest area as a bar code symbol region. In a fourth step 4, each pixel in the recognized area as a bar code symbol area S 3 in the processed image beta, between each pixel in the original image alpha, a logical product in other words the corresponding pixel to each other at the same position Take. For example, a black pixel is set to 1 and a white pixel is set to 0 to perform an operation as shown in the following table. As a result, only the pixel whose logical product is 1 is determined as a black pixel, and this is determined as a pixel indicating a part of the true shape of the barcode symbol.

【0008】[0008]

【表1】 [Table 1]

【0009】第5ステップ5では、第4ステップ4で得
られた論理積が1となる画素のみを黒画素と判別し、こ
れによって与えられる形状をバーコードシンボルの形状
として識別する。
In a fifth step 5, only the pixel whose logical product obtained in the fourth step 4 is 1 is determined as a black pixel, and the shape given by this is identified as the shape of a barcode symbol.

【0010】[0010]

【発明の効果】以上説明してきたように、この発明に係
るバーコードの判別方法によれば、太め処理によって得
られた各黒画素領域の面積を求め、これらの黒画素領域
のうち最大のものをバーコードシンボルが含まれるバー
コードシンボル領域として認識し、このバーコードシン
ボル領域と原画像とにおいて各対応位置の画素について
論理積の演算を行い、黒画素として判別されたもののみ
からバーコードシンボルの形状を認識するようになって
いるので、不要な背景やノイズを除去することができ、
正確にバーコードシンボルの読取りが行える。
As described above, according to the bar code discrimination method according to the present invention, the area of each black pixel region obtained by the thickening process is obtained, and the largest one of these black pixel regions is obtained. Is recognized as a barcode symbol area including a barcode symbol, a logical AND operation is performed on the pixel at each corresponding position in the barcode symbol area and the original image, and the barcode symbol is determined from only those determined as black pixels. Because it recognizes the shape of, unnecessary background and noise can be removed,
Barcode symbols can be read accurately.

【図面の簡単な説明】[Brief description of the drawings]

【図1】この発明に係るバーコードの識別方法を示すフ
ローチャート。
FIG. 1 is a flowchart showing a barcode identification method according to the present invention.

【図2】この発明の識別方法に使用する原画像を示す説
明図。
FIG. 2 is an explanatory diagram showing an original image used in the identification method of the present invention.

【図3】この発明の識別方法に使用する太め処理の方法
を示す説明図。
FIG. 3 is an explanatory diagram showing a thickening method used in the identification method of the present invention.

【図4】この発明の識別方法に使用する太め処理の方法
を示す説明図。
FIG. 4 is an explanatory diagram showing a thickening method used in the identification method of the present invention.

【図5】この発明の識別方法において太め処理を行った
のちの処理画像を示す説明図。
FIG. 5 is an explanatory diagram showing a processed image after performing a thickening process in the identification method of the present invention.

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 画像内の各画素について隣接する白画素
を黒画素に変更する太め処理を行い、 この太め処理された処理画像中の連結する各黒画素領域
の面積を求め、 これらの黒画素領域のうち最大面積のものをバーコード
シンボル領域として認識し、 前記処理画像内のバーコードシンボル領域と前記原画像
とについて各画素の論理積をとり、 得られた黒画素からバーコードシンボルの領域を識別す
ることを特徴とするバーコードの識別方法。
1. A thickening process for changing an adjacent white pixel to a black pixel for each pixel in an image is performed, and an area of each connected black pixel region in the thickened processed image is obtained. Recognize the largest area of the area as a barcode symbol area, take the logical product of each pixel for the barcode symbol area in the processed image and the original image, and calculate the barcode symbol area from the obtained black pixels. A method of identifying a barcode, comprising: identifying a barcode.
JP4151446A 1992-05-19 1992-05-19 Barcode identification method Expired - Fee Related JP2891821B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP4151446A JP2891821B2 (en) 1992-05-19 1992-05-19 Barcode identification method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP4151446A JP2891821B2 (en) 1992-05-19 1992-05-19 Barcode identification method

Publications (2)

Publication Number Publication Date
JPH05324896A JPH05324896A (en) 1993-12-10
JP2891821B2 true JP2891821B2 (en) 1999-05-17

Family

ID=15518780

Family Applications (1)

Application Number Title Priority Date Filing Date
JP4151446A Expired - Fee Related JP2891821B2 (en) 1992-05-19 1992-05-19 Barcode identification method

Country Status (1)

Country Link
JP (1) JP2891821B2 (en)

Also Published As

Publication number Publication date
JPH05324896A (en) 1993-12-10

Similar Documents

Publication Publication Date Title
EP0372762A2 (en) Minutia data extraction in fingerprint identification
EP0669593A2 (en) Two-dimensional code recognition method
EP2093697A1 (en) Method and arrangement for retrieving information comprised in a barcode
US20050025344A1 (en) Biometric imaging capture system and method
JP2903923B2 (en) Car number recognition device
JPH041866A (en) Method and device for image processing
JP2891821B2 (en) Barcode identification method
JPH08305795A (en) Character recognizing method
KR100295360B1 (en) Image Processing Method Using Shading Algorithm
US6983071B2 (en) Character segmentation device, character segmentation method used thereby, and program therefor
JP4221534B2 (en) Feature extraction method for binary image
JP2004145592A (en) Motion vector extraction device, method and program, and its recording medium
JP3230368B2 (en) Binarization processing method
JP3545227B2 (en) Image processing method and apparatus, optical character reader
JPH08272956A (en) Method and device for noise removal
JP2001126027A (en) Number plate recognition system
JP4248700B2 (en) Ruled line identification method, ruled line identification apparatus and recording medium
JP2004152048A (en) Vehicle number reading device
RU2314564C1 (en) Method for finding barcodes in video image frame
JP3025290B2 (en) Pattern recognition method
JP3030814B2 (en) Noise component removal method and recording medium recording noise component removal program
JPH10240856A (en) Code reader
JPH08235493A (en) Vehicle number reader
CN113222837A (en) Automatic removing method of CT image scanning bed
JPH07160858A (en) Moving object detecting method and device

Legal Events

Date Code Title Description
R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees