JP2015102915A - Information processing apparatus, control method, and computer program - Google Patents
Information processing apparatus, control method, and computer program Download PDFInfo
- Publication number
- JP2015102915A JP2015102915A JP2013241337A JP2013241337A JP2015102915A JP 2015102915 A JP2015102915 A JP 2015102915A JP 2013241337 A JP2013241337 A JP 2013241337A JP 2013241337 A JP2013241337 A JP 2013241337A JP 2015102915 A JP2015102915 A JP 2015102915A
- Authority
- JP
- Japan
- Prior art keywords
- character
- document frame
- information processing
- document
- processing apparatus
- 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.)
- Pending
Links
Images
Abstract
Description
本発明は、撮像機能を持った情報処理装置に関する。 The present invention relates to an information processing apparatus having an imaging function.
カメラを搭載した携帯端末などの情報処理装置を利用して、原稿を撮影して原稿画像を得ることができるようになってきている。また、近年では、携帯端末が、撮影した原稿画像をネットワーク経由で印刷装置に送信して、簡易な操作で印刷することができる。つまり、撮影機能を持った情報処理装置および印刷装置を、簡易なデジタル複合機として利用できる。 Using an information processing device such as a portable terminal equipped with a camera, it is now possible to capture a document and obtain a document image. In recent years, a portable terminal can transmit a photographed document image to a printing apparatus via a network and print it with a simple operation. That is, an information processing apparatus and a printing apparatus having a photographing function can be used as a simple digital multi-function peripheral.
携帯端末で撮影した原稿画像をそのまま印刷した場合、撮像面が紙面に対して平行でない状態のときには、撮影した画像に遠近効果による歪みが生じる。特許文献1は、撮像された画像の歪みを補正する画像処理装置を開示している。 When a document image photographed with a mobile terminal is printed as it is, when the imaging surface is not parallel to the paper surface, the photographed image is distorted by the perspective effect. Patent Document 1 discloses an image processing apparatus that corrects distortion of a captured image.
しかし、撮影機能を持った情報処理装置で原稿を撮影する場合、遠近効果やピンボケによって、撮影レンズから遠い文字は、解像し難くなる。一方、撮影レンズから近い文字についても、文字のサイズが小さければ、更にカメラを近づかせなければ解像できない。このような場合に、特許文献1が開示する画像処理装置を適用して画像の歪みを補正しても、解像できていない文字を含む画像が出力されてしまうことが考えられる。そして、解像できなかった文字は、デジタル化されると見た目が良くない。更に、解像できていない文字を含む撮影画像を確認しないで印刷をした場合、解像できていない文字が印刷されてしまい、利用者にとっては、再度撮影などをする必要があるなど、利便性が損なわれてしまう。 However, when a document is photographed by an information processing apparatus having a photographing function, characters far from the photographing lens are difficult to resolve due to perspective effects and blurring. On the other hand, even if the character is close to the photographic lens, if the character size is small, it cannot be resolved unless the camera is further brought closer. In such a case, it is conceivable that even if the image processing apparatus disclosed in Patent Document 1 is applied to correct image distortion, an image including characters that cannot be resolved is output. Characters that could not be resolved do not look good when digitized. Furthermore, when printing is performed without confirming a captured image that includes characters that cannot be resolved, the characters that cannot be resolved are printed, which requires the user to re-shoot, etc. Will be damaged.
本発明は、撮影原稿に含まれる文字が解像できないまま出力されてしまうことを防止する情報処理装置の提供を目的とする。 An object of the present invention is to provide an information processing apparatus that prevents characters included in a photographed document from being output without being resolved.
本発明の一実施形態の情報処理装置は、撮影画像から原稿枠を検知する検知手段と、前記原稿枠で囲まれた領域から文字ブロックを特定する特定手段と、前記文字ブロックに含まれる文字を解像できるかを判断する判断手段と、前記文字を解像できないと判断された場合に、当該文字を解像できるようにするための推奨原稿枠を生成する生成手段と、前記推奨原稿枠を表示する表示手段とを備える。 An information processing apparatus according to an embodiment of the present invention includes a detecting unit that detects a document frame from a photographed image, a specifying unit that specifies a character block from an area surrounded by the document frame, and a character included in the character block. A determination unit that determines whether the character can be resolved, a generation unit that generates a recommended document frame for enabling the character to be resolved when it is determined that the character cannot be resolved, and the recommended document frame. Display means for displaying.
本発明の情報処理装置によれば、撮影原稿に含まれる文字が解像できないまま出力されてしまうことを防止できる。 According to the information processing apparatus of the present invention, it is possible to prevent characters included in a photographed document from being output without being resolved.
(実施例1)
図1は、本実施形態のシステム構成の一例を示す図である。
図1に示すシステムは、携帯端末101、無線ルータ102、プリンタ104、サーバ105を備える。LAN110には、プリンタ104、サーバ105および無線ルータ102が接続されている。携帯端末101は、無線ルータ102を介して、プリンタ104およびサーバ105と通信可能である。
Example 1
FIG. 1 is a diagram illustrating an example of a system configuration of the present embodiment.
The system shown in FIG. 1 includes a
携帯端末101は、不図示の水平に近い机などに置かれた原稿を撮影する。もちろん、携帯端末101は、机に置かれた原稿に限らず、例えば、壁に貼り付けられた掲示物、例えばポスターなどを撮影してもよい。サーバ105は、携帯端末101によって撮影された画像に対応する印刷ジョブを生成し、プリンタ104に投入する。プリンタ104は、サーバ105が生成した印刷ジョブを実行して印刷出力する。
The
図2は、本実施例の携帯端末の外観の一例を示す図である。図2(A)は、携帯端末101の表面を示す。表面には、タッチパネル201、操作ボタン202が設けられている。タッチパネル201は、詳細には操作に必要な情報やボタン、画像などを表示するための表示装置と、人体の指などで触れることにより位置入力をする装置とが組み合わされた装置である。
FIG. 2 is a diagram illustrating an example of the appearance of the mobile terminal according to the present embodiment. FIG. 2A shows the surface of the
図2(B)は、携帯端末101の裏面を示す。裏面には撮影部203が設けられている。なお、本発明は、携帯端末に限らず、カメラ機能を持つ任意の情報処理装置に適用可能である。すわなち、本発明は、カメラ機能をもったスマートフォンや携帯電話にも、通信機能を持ったデジタルカメラにも適用可能である。また、図2(B)に示す携帯端末101が備えるカメラ機能として、図示しないオートフォーカス装置が搭載されている。このオートフォーカス装置により、コントラスト比や赤外線の送受信タイミングなどによってピントの合った状態を自動的に検出し、焦点距離や被写体距離を測定することができる。本実施例で利用するオートフォーカス装置は一例であり、焦点距離や被写体距離を測定できる任意の装置を用いることができる。
FIG. 2B shows the back surface of the
図3は、携帯端末の内部構成の一例を示す図である。図3には、本実施形態に必要な構成のみを示す。携帯端末101は、CPU301乃至画像処理部310を備える。
CPU301は、データバス311を介して、RAM302、ROM303との間でプログラムやデータを送受信する。CPU301は、ROM303の保持するプログラムに基づき、携帯端末101が備える各処理部の制御を行う。
FIG. 3 is a diagram illustrating an example of the internal configuration of the mobile terminal. FIG. 3 shows only the configuration necessary for this embodiment. The
The
また、データバス311には、タッチパネル201、撮像装置203、画像処理部310、モーションセンサ309が接続されている。画像処理部310は、原稿枠判定部3101、文字ブロック検知部3102、解像度判定部3103、推奨原稿枠生成部3104、原稿枠比較部3105、歪み補正処理部3106を備える。
In addition, a
原稿枠判定部3101は、連続撮影される原稿の画像(動画)のフレームから原稿領域を特定する。原稿領域の特定処理の対象となるのは、画像内容を確認するための撮影画像である。文字ブロック検知部3102は、原稿枠に囲まれた領域から文字ブロックを検出する。解像度判定部3103は、文字ブロックの解像度を判定する。推奨原稿枠生成部3104は、判定された文字ブロックの解像度に基づいて、推奨原稿枠を生成する。推奨原稿枠は、文字を解像できるようにするための、原稿の撮影時に表示される枠(ガイド枠)である。原稿枠比較部3105は、推奨原稿枠の表示後に得られる原稿枠と推奨原稿枠とを比較する。歪み補正処理部3106は、原稿枠と推奨原稿枠との比較結果に応じて画像の歪みを補正する。
A document
画像処理部310が備える各処理部は、DSPやCPUによるプログラム演算によっても実現が可能である。また、データバス311には、無線LAN装置306が接続されており、無線ルータ102とデータ送受信が可能である。
Each processing unit included in the
モーションセンサ309は、3軸加速度センサ、電子コンパス、3軸角速度センサを搭載しており、公知の技術を利用することにより、携帯端末101の姿勢や移動を検知することが可能である。
The
図4は、携帯端末の全体動作処理の例を説明するフローチャートである。なお、特に記載をしない限り、図4のフローチャートの処理は、CPU301が、ROM303に格納されたプログラムに従って制御を実施するものである。
FIG. 4 is a flowchart for explaining an example of the overall operation process of the mobile terminal. Unless otherwise specified, the processing of the flowchart of FIG. 4 is performed by the
まず、CPU301が、撮像装置203で動画として撮像された原稿を含む画像をタッチパネル201に表示する(ステップS1001)。この時、撮像された動画の各フレームは、RAM302に格納されている。
First, the
次に、原稿枠判定部3101が、各フレーム画像の中から原稿枠を検知して特定する(ステップS1002)。具体的には、原稿枠判定部3101は、各フレーム画像の中でエッジ抽出処理を実施し、抽出されたエッジの中で閉じた矩形のものを原稿枠として特定する。あるいは、原稿の四隅に特定のマークを予め印刷しておき、原稿枠判定部3101が、このマークを各フレーム画像から検出することで、原稿の四隅を特定し、直線で繋いで原稿枠を特定するようにしてもよい。原稿枠判定部3101は、特定した原稿枠を形成する四隅の座標を、RAM302に格納する。
Next, the document
次に、文字ブロック検知部3102が、特定された原稿枠内における文字領域(文字ブロック)を検出する(ステップS1003)。
Next, the character
図5は、図4のステップS1003における文字領域の検出処理の例を説明するフローチャートである。
まず、文字ブロック検知部3102が、原稿枠内のブロック分割を行う(ステップS2001)。ブロック分割は、領域分割として、従来から様々な手法が研究、提案されている。例えば、文字ブロック検知部3102は、画像のエッジなどの特徴量を求めて、エッジの分布密度から領域分割を求める。また、文字ブロック検知部3102が、特徴量の分布をパターン認識や統計的手法でブロック分割してもよい。これにより、例えば、図6(A)、(B)に示すように、原稿枠の中にブロックを検出することができる。
FIG. 5 is a flowchart for explaining an example of the character area detection processing in step S1003 of FIG.
First, the character
文字ブロック検知部3102が、分割したブロックの座標と、ブロックが文字ブロックか否かを示す情報を、RAM302内のテーブル(表1)に記憶する。
例えば、図6(A)に示すようにブロック分割された場合、ブロック1とブロック2の座標と、文字ブロックか否かを示す情報(表1中の文字項目に設定される「○」、「×」)とがテーブルに記憶される。図6(B)に示すようにブロック分割された場合、ブロック1乃至3の座標と、文字ブロックか否かを示す情報とがテーブルに記憶される。なお、図5のステップS2001でブロックが検出されない場合には、処理を終了する。 For example, when the block is divided as shown in FIG. 6A, the coordinates of the block 1 and the block 2 and information indicating whether the block is a character block (“◯”, “ × ”) is stored in the table. When the blocks are divided as shown in FIG. 6B, the coordinates of the blocks 1 to 3 and information indicating whether or not the block is a character block are stored in the table. If no block is detected in step S2001 in FIG. 5, the process ends.
図5に戻って、文字ブロック検知部3102が、ステップS2002以降の処理で、分割したブロックの解析を行い、文字ブロックを特定する。
文字ブロック検知部3102が、全ブロックが解析済みであるかを判断する(ステップS2002)。全ブロックが解析済みである場合は、処理を終了する。解析済みでないブロックがある場合には、処理がステップS2003に進む。
Returning to FIG. 5, the character
The character
次に、文字ブロック検知部3102が、文字ブロックの特徴を検出する(ステップS2003)。文字ブロックには、様々な特徴がある。但し、撮像装置で撮影された原稿であるので、ボケによって特徴が解析し難い場合がある。したがって、検出方法を組み合わせるのが望ましい。例えば、文字ブロック検知部3102は、2値化処理を含んだOCR判定によって、文字が検出できれば文字ブロックと判定する。
Next, the character
図6(A)のブロック2のように、原稿枠の上下に大きいブロックであれば、撮像装置203のフォーカス位置が合っている場所も多い。よって、ボケの少ない領域も含むので、OCR処理での判断は可能である。
If the block is large at the top and bottom of the document frame, as in block 2 in FIG. 6A, there are many places where the focus position of the
図5に戻って、文字ブロック検知部3102が、文字ブロックの特徴があるかを判断する(ステップS2004)。計算中のブロックの一部でも文字ブロックの特徴が検出されれば、文字ブロック検知部3102はそのブロックを文字ブロックであると判断する(ステップS2005)。文字ブロックの特徴が検出されない場合は、処理がステップS2002に戻る。
Returning to FIG. 5, the character
文字ブロック検知部3102が、図7(A),(B)に示すように、文章としての特徴によって、文字ブロックの特徴を検出してもよい。図6(B)のブロック2のように、文字領域が小さくてOCR判定をしてもボケが大きくて判断ができない場合がある。この場合、文字を書く方向と垂直な方向(行方向)に対しては空間が空いているという特徴を利用する。具体的には、文字ブロック検知部3102は、エッジ抽出や特徴量の分布をパターンマッチングで、図7(A)または図7(B)に示すようなパターンがあるかを検出する。図7(A)は、文字ブロックが横書きの場合、若しくは縦書きの原稿を横向きに撮影した場合のパターンである。また、図7(B)は、文字ブロックが縦書きの場合、若しくは横書きの原稿を縦向きに撮影した場合のパターンである。
As shown in FIGS. 7A and 7B, the character
文字ブロックと判断されたブロックは、表1のテーブルに、文字ブロックとして記録される。以上、図5のステップS2001からS2004の処理によって、S1003の文字ブロック検知を実行することができる。 Blocks determined to be character blocks are recorded as character blocks in the table of Table 1. As described above, the character block detection of S1003 can be executed by the processing of steps S2001 to S2004 in FIG.
図4の説明に戻る。文字ブロック検知部3102が、文字ブロックが検出されたかを判断する(ステップS1004)。文字ブロックが検出されない場合は、処理がステップS1012に進む。文字ブロックが検出された場合は、処理がステップS1005に進む。続いて、解像度判定部3103が、文字ブロックの解像度を判定する。解像の判定方法については、図8のフローチャートを参照して詳細に説明する。
Returning to the description of FIG. The character
図8は、文字ブロックの解像度の判定処理を説明するフローチャートである。
まず、解像度判定部3103が、文字ブロックを矩形に分割する(ステップS3001)。
FIG. 8 is a flowchart for explaining the character block resolution determination process.
First, the
図9は、原稿に含まれる文字ブロックの分割と、解像度の判定を説明する図である。図9(A)に示される原稿は、横書きの原稿である。原稿の上下は、遠近効果により、同じ文字ブロックで同じ文字のポイント数でも文字を構成する画素数が違う。したがって、解像度判定部3103は、文字ブロック1を上下A,Bの2つの矩形領域に分割する。
FIG. 9 is a diagram for explaining division of character blocks included in a document and determination of resolution. The document shown in FIG. 9A is a horizontally written document. Due to the perspective effect, the upper and lower sides of the original have different numbers of pixels that make up a character even with the same number of points in the same character block. Therefore, the
図8に戻って、解像度判定部3103が、各矩形領域の文字画素数を算出する(ステップS3002)。具体的には、解像度判定部3103は、各矩形領域で文字の高さや幅に応じた画素数を算出することで、文字の画素数(文字画素数)を決定する。
Returning to FIG. 8, the
文字を構成する画素数を決定する際に、実際には文字がピンボケによって高さを割り出すためのエッジを判断し難い場合がある。この場合には、例えば、解像度判定部3103は、空間フィルタによるエッジ抽出処理と2値化処理など、一般的な画像処理を使って高さを割り出す。特に撮像装置203の焦点深度が浅い場合には、撮像装置203と原稿との角度と、焦点の位置からの距離によって、更にピンボケになる。焦点の位置からの距離とは、注目している画素と、原稿画像中のピントが合っている画素との距離(画素数)である。文字がピンボケである状態では、空間フィルタとエッジ抽出処理だけでは、高さの割り出し精度が落ちる。したがって、エッジ抽出処理と二値化閾値を、下記の表2中に示す設定値にしたがって実行するようにしてもよい。
表2に利用する角度は、モーションセンサ309から取得できる。但し、壁に貼り付けた原稿を携帯端末で撮影する場合は、携帯端末と原稿との角度は90度変わる。したがって、携帯端末101は、撮影前に、タッチパネル201に、机上の原稿か、壁に貼り付けた原稿かを選択する画面を表示し、貼り付けた原稿であった場合は、表2の角度に90度を加算して判断する。
The angle used in Table 2 can be acquired from the
図8に戻って、解像度判定部3103が、ステップS3002で算出された各矩形領域の文字画素数が閾値以上であるかを判断する(ステップS3003)。文字画素数が閾値以上である場合、解像度判定部3103は、矩形領域に含まれる文字が解像可能であると判断して、処理がステップS3005に進む。文字画素数が閾値以上でない場合、解像度判定部3103は、矩形領域に含まれる文字が解像可能でないと判断して、処理がステップS3004に進む。
Returning to FIG. 8, the
閾値は、撮像装置203の被写界深度や解像度などの性能に応じて予め決められた値である。また、閾値は文字として利用できる画素数を表すので、目的によっても変わる。例えば、プリンタ104で印刷することを目的としているならば、文字としての美しさも必要である為、閾値を上げて、文字を大きく取得させる。一方、OCRなどで認識されることが目的であれば、閾値の大きさをOCRの性能に合わせる。例えば、印刷に必要な解像量は300dpiとすることが一般的である。この場合、文字の画素数は30画素以上が必要になり、閾値を30画素とする。一方、OCR処理には、150dpiが必要とすることが一般的である。この場合、閾値を15画素とする。
The threshold value is a value determined in advance according to the performance of the
図9を参照して、矩形領域の解像度の判定について説明する。図9(A)中に示す矩形領域A乃至Cは、横書きの原稿の画像における矩形領域を示す。横書きの場合は、文字の高さ方向の画素数を文字画素数とする。矩形領域Aに書かれた文字は、原稿上の文字の高さが3.5mmの場合、45画素で構成されたとする。これは、326dpiの解像度で撮影した場合と同等の解像力を持つ。 The determination of the resolution of the rectangular area will be described with reference to FIG. Rectangular areas A to C shown in FIG. 9A indicate rectangular areas in an image of a horizontally written document. In the case of horizontal writing, the number of pixels in the height direction of the character is set as the number of character pixels. The character written in the rectangular area A is assumed to be composed of 45 pixels when the height of the character on the document is 3.5 mm. This has the same resolving power as that obtained when shooting at a resolution of 326 dpi.
矩形領域Bに書かれた文字は、原稿上の文字の高さが3.5mmの場合、遠近効果により、矩形領域Aよりも低解像度で撮影される。例えば、文字の高さが30画素で構成されていた場合、矩形領域Bは、217dpiで撮影されたことになる。 Characters written in the rectangular area B are photographed at a lower resolution than the rectangular area A due to the perspective effect when the height of the characters on the document is 3.5 mm. For example, when the height of the character is composed of 30 pixels, the rectangular area B is captured at 217 dpi.
また、文字ブロック2は、原稿上の文字の高さが3.5mmの場合、遠近効果により更に低解像度で撮影される。例えば、文字の高さが15画素で構成されていた場合、文字ブロック2の領域は、解像度が109dpiになる。つまり、同じ文字の大きさでも構成する画素数が変わるので、文字画素数と閾値との比較により、文字を解像できるかの判断ができる。但し、原稿上の文字が大きなポイントで印刷されていた場合には、文字の高さは高くなる。例えば、文字ブロック2でも文字のサイズが5.0mmあれば、28画素になるので、文字は解像され易い。 The character block 2 is photographed at a lower resolution due to the perspective effect when the height of the character on the document is 3.5 mm. For example, when the character height is composed of 15 pixels, the resolution of the area of the character block 2 is 109 dpi. In other words, since the number of pixels constituting the same character size changes, it can be determined whether or not the character can be resolved by comparing the number of character pixels with a threshold value. However, when the characters on the document are printed at large points, the height of the characters is increased. For example, even in the character block 2, if the character size is 5.0 mm, it becomes 28 pixels, so that the character is easily resolved.
一般的には、市販の原稿読取装置は300dpiの製品が多く、7ポイント(2.5mm)の文字も十分に読み取れる性能である。2.5mmの文字を300dpiの解像度で読み取ると、文字の高さや幅は30画素で構成される。これを考慮すると、矩形領域Bの文字は解像できることになるが、文字ブロック2は解像が困難になる。 In general, many commercially available document readers have a 300 dpi product, and are capable of sufficiently reading 7-point (2.5 mm) characters. When a 2.5 mm character is read at a resolution of 300 dpi, the height and width of the character are composed of 30 pixels. Considering this, the character in the rectangular area B can be resolved, but the character block 2 is difficult to resolve.
図9(B)は、原稿が縦書きである場合の矩形領域を示す。縦書きの場合は、文字の幅方向の画素数を文字画素数とする。例えば、図9(B)中の矩形領域Aは、原稿上の文字の幅が3.5mmの場合、45画素で構成されたとする。これは、326dpiの解像度で撮影した場合と同等の解像力を持つ。矩形領域Bの文字の幅は、原稿上の文字の幅が3.5mmの場合、30画素で構成されていたとする。この場合、矩形領域Bは、217dpiの解像度で撮影されたことになる。ここで、文字の画素数が、閾値である基準画素数未満(例えば20画素未満)である場合、解像度判定部3103が、前もって原稿を適正に撮影しても解像できないと判断する。この場合には、タッチパネル201に適正に処理ができないという注意を促すため、携帯端末は、例えば、図15に示す警告画面を表示する。図15に示す警告画面上では、解像できない場所と、処理を続けるか否かを問い合わせるポップアップが表示される。
FIG. 9B shows a rectangular area when the document is vertically written. In the case of vertical writing, the number of pixels in the width direction of the character is the number of character pixels. For example, it is assumed that the rectangular area A in FIG. 9B is composed of 45 pixels when the character width on the document is 3.5 mm. This has the same resolving power as that obtained when shooting at a resolution of 326 dpi. It is assumed that the character width of the rectangular area B is composed of 30 pixels when the character width on the document is 3.5 mm. In this case, the rectangular area B is captured at a resolution of 217 dpi. Here, when the number of pixels of the character is less than the threshold number of reference pixels (for example, less than 20 pixels), the
図8に戻って、解像度判定部3103が、文字画素数が閾値以上でない、つまり画素数の足りない矩形領域の位置を返す(ステップS3004)。具体的には、解像度判定部3103は、矩形領域のタッチパネル201上の座標を返す。
Returning to FIG. 8, the
次に、解像度判定部3103が、文字ブロックの全ての矩形領域について処理を終了したかを判断する(ステップS3005)。処理を終了していない矩形領域がある場合は、処理がステップS3003に戻る。文字ブロックの全ての矩形領域について処理を終了した場合は、本サブルーチンから抜ける。
Next, the
図4の説明に戻る。推奨原稿枠生成部3104が、原稿に含まれる文字の解像度が足りているかを判断する(ステップS1006)。具体的には、推奨原稿枠生成部3104は、ステップS1005での解像度の判定結果にもとづいて、全ての文字ブロックが閾値よりも多くの文字画素数で構成されているかを判断する。全ての文字ブロックが閾値以上の文字画素数で構成されている場合、推奨原稿枠生成部3104は、原稿に含まれる文字の解像度が足りている、つまり当該文字を解像できると判断する。閾値よりも少ない文字画素数で構成されている文字ブロックがある場合、推奨原稿枠生成部3104は、原稿に含まれる文字の解像度が足りていないと判断する。
Returning to the description of FIG. The recommended document
原稿に含まれる文字の解像度が足りている場合、CPU301が、記録対象の画像である本画像を取得する(ステップS1012)。原稿に含まれる文字の解像度が足りていない場合は、処理がステップS1007に進み、推奨原稿枠生成部3104が、推奨原稿枠を生成する。
When the resolution of the characters included in the document is sufficient, the
図10は、推奨原稿枠の生成処理の例を説明するフローチャートである。
推奨原稿枠生成部3104が、図4のステップS1003で作成された全ての文字ブロックの全ての矩形領域の文字画素数を読み込む(ステップS4001)。
FIG. 10 is a flowchart illustrating an example of recommended document frame generation processing.
The recommended document
次に、推奨原稿枠生成部3104が、ステップS4001で読み込んだ全ての矩形領域の必要倍率を計算する(ステップS4002)。必要倍率は、図8のステップS3003の判断処理で利用した閾値と、各矩形領域の文字画素数の比率である。
Next, the recommended document
横書の場合には、必要倍率は以下の式で算出される。
必要倍率=閾値[画素]÷文字の高さ[画素]
縦書の場合には、必要倍率は以下の式で算出される。
必要倍率=閾値[画素]÷文字の幅[画素]
In the case of horizontal writing, the required magnification is calculated by the following formula.
Required magnification = threshold [pixel] ÷ text height [pixel]
In the case of vertical writing, the required magnification is calculated by the following formula.
Required magnification = threshold [pixel] ÷ character width [pixel]
次に、推奨原稿枠生成部3104が、原稿枠を必要倍率に基づいて修正することで、推奨原稿枠の作成を行う(ステップS4003)。具体的には、推奨原稿枠生成部3104は、全ての矩形領域の必要倍率が倍率1倍以下になるように、つまり全ての矩形領域が閾値以上の文字画素数になるように調整して、推奨原稿枠を作成する。倍率1倍以下とは、文字の高さ、幅の画素数が、閾値の画素数と同じかそれ以上の状態である。撮影者が推奨原稿枠を参照して、原稿を撮影することで、撮影画像の文字を構成する画素数が増え、解像され易くなる。
Next, the recommended document
図11(A)は、原稿枠を検知した状態での携帯端末の画面例である。図11(A)中に示す矩形領域Aは、必要倍率が0.5倍であるので、十分に解像できている。矩形領域Bは、必要倍率が1.0倍であるので、解像できている。しかし、矩形領域Cは、必要倍率が1.1倍であるので、文字部を解像するために、大きく画像を取得する必要がある。この場合、矩形領域Cを大きく撮影するために、推奨原稿枠生成部3104は、図11(A)の原稿枠の上部を必要倍率分、つまり1.1倍に大きく調整し、矩形領域Aを調整しないで、推奨原稿枠を生成する。
FIG. 11A shows a screen example of the portable terminal in a state where the document frame is detected. Since the required magnification is 0.5 times, the rectangular area A shown in FIG. The rectangular area B can be resolved because the required magnification is 1.0. However, since the necessary magnification of the rectangular area C is 1.1 times, it is necessary to acquire a large image in order to resolve the character portion. In this case, in order to photograph the rectangular area C large, the recommended document
図11(B)は、図11(A)の原稿枠が修正されることで作成された推奨原稿枠を表示した携帯端末の画面である。推奨原稿枠生成部3104は、原稿枠の4つの頂点のうち、上の2つの頂点を変更し、矩形領域Cの全体が1.1倍に拡大されるように、新たに推奨原稿枠の頂点を生成する。すなわち、推奨原稿枠生成部3104は、原稿枠で囲まれる領域のうち、文字画素数が閾値より少ないと判断された矩形領域の近傍の領域が拡大されるように原稿枠を変換して推奨原稿枠を生成する。
FIG. 11B is a screen of the mobile terminal that displays a recommended document frame created by correcting the document frame of FIG. The recommended document
図4の説明に戻る。推奨原稿枠生成部3104が、例えば、図12に示すように、推奨原稿枠をタッチパネル201に表示する(ステップS1008)。推奨枠生成部3104は、推奨原稿枠を表示するとともに、推奨原稿枠で囲まれる領域のうち、文字画素数が閾値よりも低い領域をマーク(強調表示)することで、撮影者の注意を促す。撮影者は、表示された推奨原稿枠を参照して、携帯端末101を原稿に向ける。これにより、原稿の撮影画像が再取得される。
Returning to the description of FIG. The recommended document
図4に戻って、原稿枠判定部3101が、再取得された原稿の撮影画像に基づいて、原稿枠の再検知を行う(ステップS1002)。原稿枠の再検知方法は、ステップS1002での原稿枠の検知方法と同様である。
Returning to FIG. 4, the document
原稿枠比較部3105が、ステップS1009で再検知された原稿枠と推奨原稿枠とを比較する(ステップS1010)。原稿枠は台形の頂点で構成されているので、原稿枠比較部3105は、再検知された原稿枠と推奨原稿枠の頂点座標を比較する。
The document
次に、原稿枠比較部3105が、ステップS1010での比較処理の結果に基づいて、再検知された原稿枠が推奨原稿枠よりも大きいかを判断する(ステップS1011)。再検知された原稿枠が推奨原稿枠よりも大きくない場合は、処理がステップS1009に進む。図13に示すように、再検知された原稿枠が推奨原稿枠よりも大きい場合は、処理がステップ1012に進む。
Next, the document
次に、CPU301が、ステップS1009の原稿枠の検知処理で利用した画像、つまり撮影者が推奨原稿枠を参照して撮影した画像を、本画像として取得する(ステップS1012)。撮影者が推奨原稿枠を参照して携帯端末101を原稿に向けた状態で、CPU301が、撮像装置203を高画質モードに切り替えて、画像を再取得してもよい。高画質モードとは、撮像装置の光学条件やデジタル変換時の処理を切り替えて、ノイズを抑えたり明るく撮影したりできる動作モードである。
Next, the
次に、歪み補正処理部3106が、本画像の歪みを補正し(ステップS1013)、処理を終了する。歪み補正処理部3106は、例えば、射影変換を用いて本画像の歪みを補正するが、射影変換以外の補正方法を用いてもよい。補正された本画像は、無線ルータ102を介してプリンタ104で印刷される。
Next, the distortion
実施例1の情報処理装置によれば、携帯端末で撮影した原稿に含まれる文字が解像できていないまま印刷されてしまうことを防ぐことができる。 According to the information processing apparatus of the first embodiment, it is possible to prevent characters included in an original photographed with a mobile terminal from being printed without being resolved.
(実施例2)
実施例1の情報処理装置は、動画のフレームを取り込んで得られる原稿枠に基づいて推奨原稿枠を作成する構成である。実施例2の情報処理装置は、既に撮影され、保存されている画像ファイルに基づいて検知されるを原稿枠を用いる。なお、実施例2の全体構成、携帯端末の構成や携帯端末の機能ブロックは同じである。したがって、実施例1との差分のみを説明する。
(Example 2)
The information processing apparatus according to the first embodiment is configured to create a recommended document frame based on a document frame obtained by capturing a moving image frame. The information processing apparatus according to the second embodiment uses a document frame that is detected based on an image file that has already been shot and stored. In addition, the whole structure of Example 2, the structure of a portable terminal, and the functional block of a portable terminal are the same. Therefore, only differences from the first embodiment will be described.
図14は、実施例2における携帯端末の全体動作処理の例を説明するフローチャートである。
まず、CPU301が、予め撮影されてHDD(図示を省略)等に保存されている原稿の画像ファイルから画像を取得する。例えば、CPU301は、タッチパネル201に画像ファイルに含まれる画像(写真)のリストを表示し、撮影者が選択した画像を取得する(ステップS5001)。CPU301は、取得した画像をRAM302に読み込む。
FIG. 14 is a flowchart illustrating an example of the overall operation process of the mobile terminal according to the second embodiment.
First, the
次に、原稿枠判定部3101が、ステップS5001で取得されてRAM302に読み込まれた画像から原稿枠を検知する(ステップS5002)。原稿枠の検知方法は、実施例1と同様である。
Next, the document
ステップS5003乃至S5008は、図4のステップS1003乃至S1008と同様である。撮影者が、表示された推奨原稿枠(S5008)を参照して携帯端末101を原稿に向けることで、原稿の撮影画像が再取得される。
Steps S5003 to S5008 are the same as steps S1003 to S1008 in FIG. The photographer refers to the displayed recommended document frame (S5008) and points the
実施例2では、CPU301が、画像の歪み補正を行うか否かを選択させる案内をタッチパネル201に表示する(ステップS5009)。
In the second embodiment, the
図15は、再取得された原稿の撮影画像から検知された新たな原稿枠の表示例である。CPU301は、図15の画面に示すように、ポップアップを表示することで、画像の歪み補正を行うか否かの選択を撮影者に促す。
FIG. 15 is a display example of a new document frame detected from a photographed image of a re-acquired document. As shown in the screen of FIG. 15, the
CPU301が、ユーザの選択にしたがって、歪み補正を行うかを判断する(ステップS5010)。歪み補正を行わない場合は、処理を終了する。この場合、プリンタ104への印刷も中止される。歪み補正を行う場合、歪み補正処理部3106が、歪み補正を実施する。補正された画像は、無線ルータ102を介してプリンタ104で印刷される。
The
実施例2の情報処理装置によれば、予め記憶されたファイルに含まれる原稿画像が有する文字が解像できていないまま印刷されることを防ぐことができる。 According to the information processing apparatus of the second embodiment, it is possible to prevent characters included in a document image included in a file stored in advance from being printed without being resolved.
(その他の実施例)
また、本発明は、以下の処理を実行することによっても実現される。上述した実施形態の機能を実現するソフトウェア(コンピュータプログラム)を、ネットワーク又は各種記憶媒体を介してシステム或いは装置に供給し、システム或いは装置のコンピュータ(またはCPUやMPU等)がプログラムを読み出して実行する処理である。この場合、そのプログラム、及び該プログラムを記憶した記憶媒体は本発明を構成することになる。
(Other examples)
The present invention can also be realized by executing the following processing. Software (computer program) that realizes the functions of the above-described embodiments is supplied to the system or apparatus via a network or various storage media, and the computer of the system or apparatus (or CPU, MPU, etc.) reads and executes the program. It is processing. In this case, the program and the storage medium storing the program constitute the present invention.
101 携帯端末
104 プリンタ
105 サーバ
101
Claims (12)
前記原稿枠で囲まれた領域から文字ブロックを特定する特定手段と、
前記文字ブロックに含まれる文字を解像できるかを判断する判断手段と、
前記文字を解像できないと判断された場合に、当該文字を解像できるようにするための推奨原稿枠を生成する生成手段と、
前記推奨原稿枠を表示する表示手段とを備える
ことを特徴とする情報処理装置。 Detection means for detecting a document frame from a captured image;
A specifying means for specifying a character block from an area surrounded by the document frame;
Determining means for determining whether the character included in the character block can be resolved;
Generating means for generating a recommended document frame for enabling resolution of the character when it is determined that the character cannot be resolved;
An information processing apparatus comprising: display means for displaying the recommended document frame.
前記文字ブロックを矩形領域に分割し、
前記矩形領域の文字画素数を算出し、
前記算出された文字画素数が閾値以上であるかを判断し、
前記文字画素数が閾値以上でないと判断した場合に、前記文字ブロックに含まれる文字を解像できないと判断する
ことを特徴とする請求項1に記載の情報処理装置。 The determination means includes
Dividing the character block into rectangular regions;
Calculating the number of character pixels in the rectangular area;
Determining whether the calculated number of character pixels is equal to or greater than a threshold;
The information processing apparatus according to claim 1, wherein when it is determined that the number of character pixels is not equal to or greater than a threshold value, it is determined that the character included in the character block cannot be resolved.
ことを特徴とする請求項2に記載の情報処理装置。 When the character included in the character block is written horizontally, the determination means calculates the number of pixels in the height direction of the character corresponding to the rectangular area of the character block as the character pixel number, and includes the character block. The information processing apparatus according to claim 2, wherein when the character to be written is vertically written, the number of pixels in the width direction of the character corresponding to the rectangular area of the character block is calculated as the number of character pixels.
ことを特徴とする請求項2または請求項3に記載の情報処理装置。 The generating means converts the document frame so as to generate the recommended document frame so that the number of character pixels in all rectangular areas of the character block including the character determined to be unresolvable is equal to or greater than the threshold value. The information processing apparatus according to claim 2, wherein the information processing apparatus is an information processing apparatus.
ことを特徴とする請求項2乃至4のいずれか1項に記載の情報処理装置。 The generating unit calculates a ratio between the number of character pixels in a rectangular area determined not to be equal to or greater than the threshold and the threshold, and converts the document frame based on the calculated ratio to generate the recommended document frame. The information processing apparatus according to claim 2, wherein the information processing apparatus is an information processing apparatus.
ことを特徴とする請求項2乃至5のいずれか1項に記載の情報処理装置。 The generating means converts the document frame so that a region in the vicinity of a rectangular region in which the number of character pixels is determined not to be greater than or equal to the threshold among the regions surrounded by the document frame is converted to the recommended document. The information processing apparatus according to claim 2, wherein a frame is generated.
ことを特徴とする請求項2乃至6のいずれか1項に記載の情報処理装置。 The generation unit generates the recommended document frame by changing a position of a vertex in the vicinity of a rectangular area in which the number of character pixels is determined not to be greater than or equal to the threshold value among vertices of the document frame. The information processing apparatus according to any one of claims 2 to 6.
ことを特徴とする請求項1乃至7のいずれか1項に記載の情報処理装置。 The display unit highlights a character block including a character determined to be unresolvable in an area surrounded by the recommended document frame to be displayed. The information processing apparatus described in 1.
画像を確認するための撮影画像を対象として前記原稿枠を検知し、
前記推奨原稿枠が表示された後に再取得される撮影画像から新たな原稿枠を検知し、
前記新たな原稿枠が前記推奨原稿枠より大きい場合に、記録対象の画像である本画像を撮影する撮影手段を備える
ことを特徴とする請求項1乃至8のいずれか1項に記載の情報処理装置。 The detection means includes
Detecting the document frame for a captured image for confirming the image,
A new document frame is detected from a captured image re-acquired after the recommended document frame is displayed;
9. The information processing according to claim 1, further comprising photographing means for photographing a main image that is an image to be recorded when the new document frame is larger than the recommended document frame. apparatus.
ことを特徴とする請求項1乃至8のいずれか1項に記載の情報処理装置。 The information processing apparatus according to claim 1, wherein the detection unit detects the document frame from a captured image included in a file stored in advance.
前記原稿枠で囲まれた領域から文字ブロックを特定する工程と、
前記文字ブロックに含まれる文字を解像できるかを判断する工程と、
前記文字を解像できないと判断された場合に、当該文字を解像するための推奨原稿枠を生成する工程と、
前記推奨原稿枠を表示する工程とを有する
ことを特徴とする情報処理装置の制御方法。 A process of detecting a document frame from a photographed image;
Identifying a character block from an area surrounded by the document frame;
Determining whether a character included in the character block can be resolved;
When it is determined that the character cannot be resolved, generating a recommended document frame for resolving the character;
And a step of displaying the recommended manuscript frame.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013241337A JP2015102915A (en) | 2013-11-21 | 2013-11-21 | Information processing apparatus, control method, and computer program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013241337A JP2015102915A (en) | 2013-11-21 | 2013-11-21 | Information processing apparatus, control method, and computer program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2015102915A true JP2015102915A (en) | 2015-06-04 |
Family
ID=53378589
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2013241337A Pending JP2015102915A (en) | 2013-11-21 | 2013-11-21 | Information processing apparatus, control method, and computer program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2015102915A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPWO2017109998A1 (en) * | 2015-12-25 | 2018-05-24 | 株式会社Pfu | Mobile terminal, image processing method, and program |
JP2018182451A (en) * | 2017-04-07 | 2018-11-15 | カシオ計算機株式会社 | Image checking apparatus, image checking method, and program |
-
2013
- 2013-11-21 JP JP2013241337A patent/JP2015102915A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPWO2017109998A1 (en) * | 2015-12-25 | 2018-05-24 | 株式会社Pfu | Mobile terminal, image processing method, and program |
US10628713B2 (en) | 2015-12-25 | 2020-04-21 | Pfu Limited | Mobile terminal, image processing method, and computer-readable recording medium |
JP2018182451A (en) * | 2017-04-07 | 2018-11-15 | カシオ計算機株式会社 | Image checking apparatus, image checking method, and program |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4341629B2 (en) | Imaging apparatus, image processing method, and program | |
US10484610B2 (en) | Image-capturing apparatus, captured image processing system, program, and recording medium | |
US9208550B2 (en) | Smart document capture based on estimated scanned-image quality | |
JP4363151B2 (en) | Imaging apparatus, image processing method thereof, and program | |
JP4556813B2 (en) | Image processing apparatus and program | |
JP6448674B2 (en) | A portable information processing apparatus having a camera function for performing guide display for capturing an image capable of character recognition, a display control method thereof, and a program | |
TWI392343B (en) | Automatic image capturing system | |
JP2011055467A (en) | Captured image processing system, image output method, program, and recording medium | |
JP6755787B2 (en) | Image processing equipment, image processing methods and programs | |
KR101642402B1 (en) | Apparatus and method for capturing digital image for guiding photo composition | |
JP2012027687A (en) | Image processing apparatus and program | |
JP2007074578A (en) | Image processor, photography instrument, and program | |
CN103019537A (en) | Image preview method and image preview device | |
JP2013070212A (en) | Image processor and image processing program | |
JP2018046337A (en) | Information processing device, program and control method | |
CN107085699B (en) | Information processing apparatus, control method of information processing apparatus, and storage medium | |
WO2018196854A1 (en) | Photographing method, photographing apparatus and mobile terminal | |
JP2010130181A (en) | Image acquiring apparatus | |
JP4898655B2 (en) | Imaging apparatus and image composition program | |
JP2015102915A (en) | Information processing apparatus, control method, and computer program | |
US9712697B1 (en) | Detecting sizes of documents scanned using handheld devices | |
JP4363154B2 (en) | Imaging apparatus, image processing method thereof, and program | |
CN112997217A (en) | Document detection from video images | |
KR102135961B1 (en) | Apparatus and method of processing images | |
JP2017208655A (en) | Information processing system, information processing method and program |