JP4380268B2 - Image region selection method and apparatus - Google Patents
Image region selection method and apparatus Download PDFInfo
- Publication number
- JP4380268B2 JP4380268B2 JP2003306811A JP2003306811A JP4380268B2 JP 4380268 B2 JP4380268 B2 JP 4380268B2 JP 2003306811 A JP2003306811 A JP 2003306811A JP 2003306811 A JP2003306811 A JP 2003306811A JP 4380268 B2 JP4380268 B2 JP 4380268B2
- Authority
- JP
- Japan
- Prior art keywords
- area
- image
- designated
- partial
- designated area
- 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 - Lifetime
Links
- 238000010187 selection method Methods 0.000 title claims description 9
- 238000000034 method Methods 0.000 claims description 50
- 239000000203 mixture Substances 0.000 claims description 40
- 238000000605 extraction Methods 0.000 claims description 16
- 238000010586 diagram Methods 0.000 description 7
- 239000003086 colorant Substances 0.000 description 2
- 238000007796 conventional method Methods 0.000 description 2
- 239000000284 extract Substances 0.000 description 2
- 238000009966 trimming Methods 0.000 description 2
- 239000002131 composite material Substances 0.000 description 1
- 230000004043 responsiveness Effects 0.000 description 1
- 230000002194 synthesizing effect Effects 0.000 description 1
Images
Landscapes
- Image Processing (AREA)
- Image Analysis (AREA)
Description
本発明は、拡大、トリミング等の画像処理のために一つの画像から部分領域を選択する際に用いて好適な画像領域選択方法及び装置に関する。 The present invention relates to an image region selection method and apparatus suitable for use in selecting a partial region from one image for image processing such as enlargement and trimming.
デジタルカメラ、パーソナルコンピュータ(以下、PC)などの普及により、デジタルカメラで撮影した画像データをPC上で簡単に編集を行えるようになってきた。さらに、デジタルカメラや携帯電話など撮影した機器内で、簡易的な編集を行う要求や、撮影した画像のチェックが簡単に行いたいという要求がある。しかし、デジタルカメラや携帯電話といった携帯機器では、マウスなどのインターフェースが使えないため、画像のある部分を拡大したいといった場合、例えば所望の領域の左上と右下を十字キーを何度も押して指定する必要があるなど煩雑な操作を強いられていた。 With the widespread use of digital cameras, personal computers (hereinafter referred to as PCs), image data taken with digital cameras can be easily edited on PCs. Furthermore, there is a request for simple editing within a device such as a digital camera or a mobile phone, and a request for easily checking a captured image. However, since portable devices such as digital cameras and mobile phones cannot use an interface such as a mouse, when you want to enlarge a part of an image, for example, specify the upper left and lower right of the desired area by pressing the cross key repeatedly. It was forced to perform complicated operations such as necessity.
画像中のある点を指定して拡大する処理において、最も簡単な手法は、特許文献1に記載のように、所定の倍率で画像中心/所定の点を中心に領域を確定する方法が考えられる。しかし、この場合、最適な倍率というものは存在しないため、例えば、1.1倍ずつ拡大させていくというような操作をユーザーに強いることになる。 In the process of specifying and enlarging a certain point in the image, the simplest method is to determine the area centered on the image center / predetermined point at a predetermined magnification as described in Patent Document 1. . However, in this case, since there is no optimal magnification, for example, the user is forced to perform an operation of enlarging by 1.1 times.
また、特許文献2に記載のように倍率を指定することなく、複写物から有効画像領域を検出し、出力する用紙に合わせて拡大する手法も提案されている。しかし、有効画像領域とは、画像やテキストなどの無い空白領域以外のことであり、本発明が対象としているような、画像内の有効領域を検出する手法とは異なる。
In addition, as described in
次に、ユーザーに指定させた1点から、ある特徴を計算し領域を抽出する手法がある。例えば、特許文献3では、輪郭抽出を行い、画像から領域を抽出する。しかし、この方法では、1つの領域しか特定できず、背景などを同時に選択したいなど複数の領域に渡る抽出はすることはできない。
ところで写真画像では、人、物、景色等の複数種類の被写体を一枚の写真に含ませるようにすることが多くある。このような場合、例えばできるだけ人を表した範囲を大きくするとともに、適切に背景画像も含まれるようにしたいという要望がある。このようなときには拡大対象や非トリミング対象の範囲を直接指定することで、ユーザーの意図に適した部分領域を指定することができる。しかしながら、従来の技術では範囲を指定する際に、マウス等による微妙な操作が要求されたり、複数回の操作が必要となったりするという課題がある。 By the way, in a photographic image, a plurality of types of subjects such as people, things, and scenery are often included in one photograph. In such a case, for example, there is a demand for increasing the range representing a person as much as possible and appropriately including a background image. In such a case, a partial area suitable for the user's intention can be specified by directly specifying the range to be enlarged or non-trimmed. However, the conventional technique has a problem that when a range is specified, a delicate operation with a mouse or the like is required, or a plurality of operations are required.
一方、特許文献1〜3等に記載されたような従来の技術では、例えば指定した対象物を中心として拡大等の処理が行われるようになっている。このような技術では、指定した被写体以外の被写体については十分な配慮がなされない場合が発生する。つまり、操作者が意図したとおりに部分領域を指定することができない場合が発生する可能性がある。 On the other hand, in the conventional techniques described in Patent Documents 1 to 3 and the like, for example, a process such as enlargement is performed around a specified target. With such a technique, there are cases where sufficient consideration is not given to subjects other than the designated subject. That is, there is a possibility that the partial area cannot be designated as intended by the operator.
本発明は、上記の事情に鑑みてなされたものであり、簡単な操作でかつ操作者の意図にできるだけ合う形で写真画像における部分領域の選択を可能とすることができる画像領域選択方法及び画像領域選択装置を提供することを目的とする。 The present invention has been made in view of the above circumstances, and an image region selection method and an image that can enable selection of a partial region in a photographic image with a simple operation and in a form that suits the operator's intention as much as possible. An object is to provide an area selection device.
本発明は、一つの画像から部分領域を選択する方法であって、操作者が指定した画像上の指定点を含むその周囲の領域を指定領域として抽出する指定領域抽出過程と、指定領域抽出過程で抽出された指定領域の画像全体に占める位置関係を求める構図解析過程と、構図解析過程で求められた位置関係と、部分領域の大きさに係る値とに基づいて、指定領域抽出過程で抽出された指定領域を含む部分領域を選択する部分領域選択過程とを含むことを特徴とする。これによれば、指定領域が元の画像全体に占める位置関係を基準とし且つ選択する部分領域の大きさに係る値に基づいて部分領域が選択される。つまり写真の画面全体の構成(構図)を考慮した上で指定領域を含む部分領域を選択することが可能となる。写真では構図に人の意図が込められている場合が多いと考えられる。したがって、本発明によれば、操作者の意図にできるだけ合う形で部分領域を選択できる可能性が高くなると考えられる。また、操作者が指定した指定点の周囲の領域が自動的に指定領域として抽出されるので、操作は簡易である。 The present invention is a method for selecting a partial area from one image, a designated area extracting process for extracting a surrounding area including a designated point on an image designated by an operator as a designated area, and a designated area extracting process Extracted in the specified region extraction process based on the compositional analysis process to determine the positional relationship of the specified region extracted in the entire image, the positional relationship determined in the compositional analysis process, and the value related to the size of the partial region And a partial area selecting step of selecting a partial area including the designated area. According to this, the partial area is selected based on the value related to the size of the partial area to be selected on the basis of the positional relationship that the specified area occupies in the entire original image. That is, it is possible to select a partial area including the designated area in consideration of the configuration (composition) of the entire picture screen. It is thought that there are many cases where the intention of a person is included in the composition in the photograph. Therefore, according to the present invention, it is considered that there is a high possibility that the partial region can be selected in a form that matches the operator's intention as much as possible. Further, since the area around the designated point designated by the operator is automatically extracted as the designated area, the operation is simple.
本発明は、また、前記指定領域抽出過程で、画像を複数の分割領域に分割し、その後、操作者が指定した画像上の指定点を含む分割領域を前記指定領域として抽出することを特徴とする。これによれば、指定点を指示した後の応答性を良くしたり、例えば操作者の指定を受ける際に分割領域を表示することで指定点の指示をより容易にできたりする。 The present invention is also characterized in that, in the designated area extraction process, the image is divided into a plurality of divided areas, and then a divided area including a designated point on the image designated by the operator is extracted as the designated area. To do. According to this, the responsiveness after designating the designated point can be improved, or the designated point can be designated more easily by displaying the divided area when receiving the designation of the operator, for example.
本発明は、また、前記指定領域抽出過程で、操作者が指定した画像上の指定点の周囲でその指定点と類似した特徴を有する画像領域を前記指定領域として抽出することを特徴とする。これによれば、指定点を指示する前の処理時間を短縮できたり、例えば分割領域を用意する場合に比べより細かな領域指定を可能とすることができる。 The present invention is also characterized in that, in the designated region extraction process, an image region having characteristics similar to the designated point around the designated point on the image designated by the operator is extracted as the designated region. According to this, it is possible to shorten the processing time before designating the designated point, and it is possible to designate a region that is finer than when a divided region is prepared.
本発明は、また、前記構図解析過程で、前記指定領域の外周部から前記画像の外周部までの上下左右の各距離を基準として位置関係を求めることを特徴とする。これによれば、比較的簡単な計算処理で、構図を考慮した部分領域の選択が可能となる。 The present invention is also characterized in that, in the composition analysis process, the positional relationship is obtained based on respective distances from the outer periphery of the designated area to the outer periphery of the image. According to this, it is possible to select a partial region in consideration of the composition by a relatively simple calculation process.
本発明は、また、前記部分領域選択過程で、前記画像のアスペクト比を保持するように前記部分領域を選択することを特徴とする。これによれば、選択される部分領域の形状が一定となるので、操作者が処理結果を容易に予測できるようになり、例えば指定点の指定要領を把握しやすくなる。 The present invention is also characterized in that, in the partial region selection process, the partial region is selected so as to maintain the aspect ratio of the image. According to this, since the shape of the selected partial region is constant, the operator can easily predict the processing result, and for example, it becomes easy to grasp the specification point of the specified point.
本発明は、また、前記部分領域選択過程で、出力媒体のアスペクト比に適合するように前記部分領域を選択することを特徴とする。これによれば、ディスプレイ、プリンタ、表示パネル、テレビ画面等の出力媒体に出力したときに所望の結果を得やすくなる。 The present invention is also characterized in that, in the partial area selection process, the partial area is selected so as to match the aspect ratio of the output medium. This makes it easier to obtain a desired result when outputting to an output medium such as a display, printer, display panel, or television screen.
本発明は、また、前記部分領域選択過程ではさらに、選択した部分領域に所定のテンプレート画像を合成することを特徴とする。これによれば、簡易な操作で自由度の高い画像処理を行うことが可能となる。 The present invention is further characterized in that in the partial region selection step, a predetermined template image is synthesized with the selected partial region. According to this, it is possible to perform image processing with a high degree of freedom by a simple operation.
本発明は、また、前記大きさに係る値が、前記部分領域に対する拡大率又は拡大前後の面積比のいずれかであることを特徴とする。部分領域の大きさを拡大率や面積比といった値を基に選択することで、例えば画素数や縦横の長さの値で指定する場合と比べ、ユーザーが設定値を把握しやすくなる。 The present invention is also characterized in that the value relating to the size is either an enlargement ratio with respect to the partial region or an area ratio before and after enlargement. By selecting the size of the partial area based on values such as an enlargement ratio and an area ratio, the user can easily grasp the set value as compared with the case where the size is specified by, for example, the number of pixels or the length and width.
本発明は、また、前記部分領域選択過程で、前記部分領域を操作者の指示に応じて変更可能であることを特徴とする。これによれば、指定領域の自動抽出や構図を考慮した部分領域の選択に変更を加えたい場合に、ユーザーに対してその手段が提供される。 The present invention is also characterized in that the partial area can be changed in accordance with an instruction from an operator in the partial area selection process. According to this, when it is desired to change the selection of the partial area in consideration of the automatic extraction of the designated area and the composition, the means is provided to the user.
本発明は、また、一つの画像から部分領域を選択する装置であって、操作者が指定した画像上の指定点を含むその周囲の領域を指定領域として抽出する指定領域抽出手段と、指定領域抽出手段で抽出した指定領域の画像全体に占める位置関係を求める構図解析手段と、構図解析手段が求めた位置関係と、部分領域の大きさに係る値とに基づいて、指定領域抽出手段が抽出した指定領域を含む部分領域を選択する部分領域選択手段とを備えることを特徴とする。本発明は、また、一つの画像から部分領域を選択するためのプログラムであって、操作者が指定した画像上の指定点を含むその周囲の領域を指定領域として抽出する指定領域抽出過程と、指定領域抽出過程で抽出された指定領域の画像全体に占める位置関係を求める構図解析過程と、構図解析過程で求められた位置関係と、部分領域の大きさに係る値とに基づいて、指定領域抽出過程で抽出された指定領域を含む部分領域を選択する部分領域選択過程とをコンピュータによって実行するための記述を含むことを特徴とする。 The present invention is also an apparatus for selecting a partial area from one image, a designated area extracting means for extracting a surrounding area including a designated point on an image designated by an operator as a designated area, a designated area The designated area extracting means extracts the composition based on the composition relation calculating means for obtaining the positional relationship in the entire image of the designated area extracted by the extracting means, the positional relation obtained by the composition analyzing means, and the value related to the size of the partial area. And a partial area selecting means for selecting a partial area including the designated area. The present invention is also a program for selecting a partial region from one image, and a designated region extraction process for extracting a surrounding region including a designated point on an image designated by an operator as a designated region; Based on the composition analysis process for determining the positional relationship in the entire image of the specified area extracted in the specified area extraction process, the positional relationship determined in the composition analysis process, and the value related to the size of the partial area It includes a description for executing by a computer a partial area selection process for selecting a partial area including a designated area extracted in the extraction process.
以下、図面を参照して本発明を実施するための最良の形態について説明する。 The best mode for carrying out the present invention will be described below with reference to the drawings.
図1は、本実施の形態の画像領域選択装置の構成を説明するためのブロック図である。本発明の画像領域選択装置は、パーソナルコンピュータのハードウェア資源を利用して実行されるソフトウェア・プログラムとして実現されたり、携帯電話、デジタルカメラ等の携帯型情報装置の中央処理装置等を利用して実行されるソフトウェア・プログラムとして実現されたりすることができる。図1に示す例は、そのような装置に組み込まれて実現される場合のソフトウェア・プログラムを構成する各機能をブロックとして示したものである。ただし、画像記憶部10は、カード型の不揮発性記憶媒体等の記憶装置で構成されている。ここで、本実施の形態を構成するプログラムが実行される装置には、少なくと、ユーザーの操作を入力するための操作子と、画像情報を表示するための表示装置とが設けられているものとする。
FIG. 1 is a block diagram for explaining the configuration of the image region selection apparatus according to the present embodiment. The image area selection device of the present invention is realized as a software program executed using hardware resources of a personal computer, or using a central processing unit of a portable information device such as a mobile phone or a digital camera. It can be realized as a software program to be executed. The example shown in FIG. 1 shows each function constituting a software program as a block when implemented in such a device. However, the
画像選択部1は、ユーザーの操作に応じて、画像記憶部10内に記憶された複数の電子写真画像から、ユーザーが部分領域を選択しようとする1つの画像データを選択する。指定領域設定部2は、画像選択部1で選択された1つの画像上でユーザーの操作に応じて1または複数の指定点を設定する。指定領域設定部2は、さらに、その指定点を含む、その指定点の周囲の領域を指定領域として抽出する。構図解析/出力領域計算部3は、指定領域設定部2で抽出された指定領域の画像全体に占める位置関係を求めるとともに、求めた位置関係と出力領域となる部分領域の大きさに係る値とに基づいて指定領域を含む部分領域を選択する。構図解析/出力領域計算部3は、選択した部分領域に基づいて新たに作成した画像データを画像記憶部10内に記憶したり、所定の表示装置に選択した部分領域のみを拡大して表示したり、部分領域を示す情報をプリンタへ印刷したり、所定の表示装置への出力を行うための他の処理機能に対して出力したりする。
The image selection unit 1 selects one piece of image data that the user intends to select a partial area from a plurality of electrophotographic images stored in the
図2は、図1に示す画像領域選択装置の処理の流れを説明するためのフローチャートである。図2の(a)および(b)は、いずれも図1の画像選択部1、指定領域設定部2、および構図解析/出力領域計算部3の各部による処理を示している。ただし、図2の(a)と(b)では指定領域設定部2による指定領域の設定方法が異なっている。
FIG. 2 is a flowchart for explaining the processing flow of the image region selection apparatus shown in FIG. (A) and (b) of FIG. 2 show processing by each unit of the image selection unit 1, the designated
図2(a)に示す処理では、まず画像選択部1で画像が選択され(ステップS11)、次に指定領域設定部2で選択された画像が画像の特徴等に応じて複数の分割領域に分割される(ステップS12)。その後、ユーザーが指定したその画像上の指定点を含む分割領域が指定領域として指定される(ステップS13)。そして、構図解析/出力領域計算部3による構図解析処理と、部分領域を計算によって求めて選択してそれを出力領域として出力する処理とが行われる(ステップS14)。
In the process shown in FIG. 2A, an image is first selected by the image selection unit 1 (step S11), and then the image selected by the designated
指定領域設定部2によるステップS12の分割領域への分割処理は例えば次のようにして行うことができる。ここでは、与えられた画像の色情報がRGB(Red(赤)Green(緑)Blue(青))で表現されていることとする。指定領域設定部2では、まず、このRGB色情報をHSV(Hue(色相)Saturation(彩度)Value(明度))情報に変換する。H(色相)は、環状に表現されその角度によって色相が分類できる。例えば24色に分類する場合は、15度ずつに分類する。これにより、与えられた画像を、24色の近似色領域に分けて分類することができる。そして同一色に分類された連続する近似領域毎に分割領域を形成する。
The dividing process into the divided areas in step S12 by the designated
ここでは、HSV手法を用いたが、Lab(ラブ・カラー;色情報を数値化するカラーモデル)など色相情報をもつ手法で行っても良い。また、24色といった固定的な分類手法ではなく、k−means法のような分類手法を用いても良い。 Here, the HSV method is used, but a method having hue information such as Lab (love color; a color model for digitizing color information) may be used. Further, instead of a fixed classification method such as 24 colors, a classification method such as a k-means method may be used.
一方、図2(b)に示す処理では、まず画像選択部1で画像が選択される(ステップS21)。次にユーザーによる画像上の1点の(または複数点の)指定点の指定を受け(ステップS22)、その指定点の周囲でその指定点と類似した特徴を有する画像領域が指定領域として抽出される(ステップS23)。そして、構図解析/出力領域計算部3による構図解析処理と、部分領域を計算によって求めて選択してそれを出力領域として出力する処理とが行われる(ステップS24)。 On the other hand, in the process shown in FIG. 2B, an image is first selected by the image selection unit 1 (step S21). Next, the user designates one (or a plurality of) designated points on the image (step S22), and an image region having characteristics similar to the designated points is extracted as the designated region around the designated point. (Step S23). Then, composition analysis processing by the composition analysis / output region calculation unit 3 and processing for obtaining and selecting a partial region by calculation and outputting it as an output region are performed (step S24).
指定領域設定部2によるステップS23の指定点の周囲でその指定点と類似した特徴を有する画像領域を指定領域として抽出する処理は例えば次のようにして行うことができる。なお、領域抽出手法としては様々な手法が提案されていてどの手法を用いても良いが、ここでは最も簡単な手法を一例として示す。まず、与えられた画像の色情報がRGBで表現されていることとする。指定点が(R、G、B)=(222、151、135)の場合、あらかじめ設定しておいたしきい値によって近似色領域を決定する。例えば、しきい値を30とした場合、Rは192〜252、Gは121〜181、Bは105〜165の範囲内の色情報を持つ画素が近似色領域として決定できる。
The process of extracting an image area having characteristics similar to the designated point around the designated point in step S23 by the designated
さらに、近似色領域から、指定点と隣接する画素のみを抽出する。指定点と隣接する4点(上下左右)が、近似色領域である場合その点は抽出される。近似色領域で無い場合は、抽出領域に含まれない。抽出された隣接点に於いて、同様に近似色領域である隣接点を抽出していくことで、指定点と隣接し、かつ、近似色領域が抽出できる。ここでは、RGB手法のまま処理を行っているが、HSVやLabなどの色情報を変換して行っても良い。 Further, only pixels adjacent to the designated point are extracted from the approximate color region. If four points (up, down, left, and right) adjacent to the designated point are approximate color regions, the points are extracted. If it is not an approximate color area, it is not included in the extraction area. Similarly, by extracting adjacent points that are approximate color areas at the extracted adjacent points, it is possible to extract an approximate color area that is adjacent to the designated point. Here, the processing is performed in the RGB method, but color information such as HSV or Lab may be converted.
次に図3〜図8を参照して図1の構図解析/出力領域計算部3による処理の詳細を具体例を示して説明する。図3は画像選択部1で選択された元画像20を示している。元画像20には、人を表す領域30、空を表す領域40、山を表す領域50、および標識を表す領域60が被写体として映し出されている。また人を表す領域30は、頭部に対応する領域31と、胴部に対応する領域32とから形成されているものとする。図2のステップS12では少なくとも各領域が分割領域としてそれぞれ分割されているものとする。
Next, details of processing by the composition analysis / output region calculation unit 3 in FIG. 1 will be described with reference to FIGS. FIG. 3 shows the
ユーザーがこれらの分割された領域の1つを指示する(図2のステップS13)、あるいは指示する1点によって求まる1つの領域から(図2のステップS22)、上下左右の端を計算することでその領域を内包する長方形が求まる。この場合、図2のステップS13または図2のステップS22で領域31内の1点がユーザーによって指定されたものとする。そして、この場合、図1の指定領域設定部2によって、領域31内の1点の指定点で指定された分割領域あるいは1点の指定点を元に計算された領域を内包する領域が、図4に示す指定領域21として設定されたものとする。
By calculating one of these divided areas (step S13 in FIG. 2), or from one area determined by one point indicated (step S22 in FIG. 2), the top, bottom, left and right edges are calculated. A rectangle that encloses the area is obtained. In this case, it is assumed that one point in the
構図解析/出力領域計算部3は、まず、図4に示す指定領域21の左端から画像20の左端までの距離D_left、指定領域21の右端から画像20の右端までの距離D_right、指定領域21の上端から画像20の上端までの距離D_up、指定領域21の下端から画像20の下端までの距離D_downを計算する。次に構図解析/出力領域計算部3は、例えばあらかじめユーザーが設定した拡大比率によって、元画像20の拡大比率分の大きさを有する部分領域22(図5参照)を出力領域として求める。
The composition analysis / output area calculation unit 3 firstly has a distance D_left from the left end of the designated
図5は、元の画像20、指定領域21、部分領域22の関係を説明するための図である。元画像20は、横画素数X1、縦画素数Y1の画像である。指定領域21は、横画素数X2、縦画素数Y2の領域である。部分領域22は、横画素数Xout、縦画素数Youtの領域である。変数d_left、d_right、d_up、およびd_downは、それぞれ、指定領域21の左端から部分領域22の左端までの距離、指定領域21の右端から部分領域22の右端までの距離、指定領域21の上端から部分領域22の上端までの距離、および指定領域21の下端から部分領域22の下端までの距離を表している。
FIG. 5 is a diagram for explaining the relationship among the
構図解析/出力領域計算部3による部分領域22の選択は、指定領域21の画像20全体に占める位置関係と、出力領域となる部分領域22の大きさに係る値である面積比や拡大率とに基づいて行われる。ここで、大きさに係る値として、指定領域21と画像20との上下左右の各距離の比を用いた場合と、面積比を用いる場合と、拡大率を用いる場合の処理内容について説明する。
The selection of the
(1)各距離の比を用いた例:この例では、距離の比を拡大比率Rとした場合、図5に示す指定領域21から部分領域22までの各距離d_left、d_right、d_up、およびd_downは、指定領域21から画像20までの各距離D_left、D_right、D_up、およびD_downに拡大比率Rを掛けた値として計算される。すなわち、指定領域21から部分領域22までの各距離は、d_left=D_left*R、d_right=D_right*R、d_up=D_up*R、およびd_down=D_down*Rと求められる。ここで、拡大比率Rは0〜1に設定される。
(1) Example using ratios of distances: In this example, when the ratio of distances is an enlargement ratio R, the distances d_left, d_right, d_up, and d_down from the designated
(2)面積比を用いた例:この例では、例えば元画像20の面積を1として、部分領域22の面積を1未満0以上の値aに基づいて設定する。図5から、元画像20の面積S1は、S1=X1*Y1(X1:元画像横画素数、Y1:縦画素数)となる。一方、指定領域21の面積S2は、S2=X2*Y2(X2:指定領域横画素数、Y2:縦画素数)である。ユーザーが、面積比a(1>a≧0)を指定したとすると、部分領域22の横画素数Xoutと縦画素数Youtは、
上下左右それぞれの領域からの増分値は、元画像20と指定領域21の位置関係に係る値(上下左右の各距離D_left、D_right、D_up、およびd_down=D_down)を用いて、
(3)拡大率を用いた例:この例では、拡大率が1のときに部分領域22が元画像20に一致するものとして、部分領域22の縦横の画素数(長さ)の拡大率を1以上の値bで設定する。ユーザーが拡大率b(≧1)を指定したとすると、部分領域22の横画素数Xoutと縦画素数Youtは
また、上下左右それぞれの領域からの増分値は、元画像20と指定領域21の位置関係に係る値(上下左右の各距離D_left、D_right、D_up、およびd_down=D_down)を用いて、
次に、構図解析/出力領域計算部3によって、部分領域22のアスペクト比を調整する場合について説明する。構図解析/出力領域計算部3は、画像20のアスペクト比を保持するように部分領域22を選択したり、プリンタ等の出力媒体のアスペクト比に適合するように部分領域22を選択したりすることができる。ここでは、画像20のアスペクト比を保持する例について説明する。なお、上述した部分領域22の選択処理では、(1)の各距離の比を用いる場合、通常、部分領域22のアスペクト比が画像20のアスペクト比と異なることになる。(2)と(3)の面積比や拡大率を用いた場合には部分領域22のアスペクト比が画像20のアスペクト比に一致して得られる。
Next, a case where the aspect ratio of the
ここでは、構図解析/出力領域計算部3が、拡大比率Rによって選択した部分領域22のアスペクト比を元画像20のアスペクト比と同じa:b=X1:Y1に変更する場合を説明する。ここでは、図6に示すように、変更前の部分領域22の横画素数と縦画素数をxとyとして、変更後の部分領域22aの横画素数と縦画素数をXとYとする。
Here, a case will be described in which the composition analysis / output region calculation unit 3 changes the aspect ratio of the
部分領域22のアスペクト比y/xと元画像20のアスペクト比b/aがb/a<y/xの関係を有する場合、変更後の部分領域22aの横画素数Xと縦画素数Yは、次式で求められる。
同様に、b/a≧y/xのときは、
なお、図7に示すように、構図解析/出力領域計算部3は、さらに選択した部分領域22に所定のテンプレート画像23を合成する機能を備えていてもよい。構図解析/出力領域計算部3は、選択した部分領域22をテンプレート画像23にあわせて、アスペクト比などを変更したり、領域を拡大したりして、テンプレー画像23に合成して、出力する。
As shown in FIG. 7, the composition analysis / output region calculation unit 3 may further have a function of synthesizing a
あるいは、図8に示すように、ユーザーの指示に応じて選択した部分領域22を変更可能とする機能を備えていてもよい。ユーザーがその部分領域22に多少の微調整を加えるために、部分領域22の周辺をポインタ23などで操作できるようなインターフェースを持たすことで、出力領域となる部分領域22bを変更できるようにすることができる。
Alternatively, as shown in FIG. 8, a function may be provided that allows the
本実施の形態によれば、例えば画像中のある1点(1操作/あるいは数点の指定操作)にて特徴領域を抽出すると同時に、構図解析を行うことで元々の画像の意図(構図)を汲み取った領域を出力することが可能となる。特にマウスなどのような操作性の優れたインターフェースがない機器(デジタルカメラ、携帯電話等)において、所望の領域を簡単に獲得することが可能となる。 According to the present embodiment, for example, a feature region is extracted at one point (one operation / or several designation operations) in an image, and at the same time, composition analysis is performed to obtain the intention (composition) of the original image. The fetched area can be output. In particular, in a device (such as a digital camera or a mobile phone) that does not have an interface with excellent operability such as a mouse, a desired area can be easily acquired.
また、元々、ある程度の構図を考えて写真が撮られていると想定すると、その画像中の1つのオブジェクトを選択した際にも、構図を考慮に入れたトリミングか行われることは有効である。 Also, assuming that a photograph is originally taken in consideration of a certain amount of composition, it is effective to perform trimming in consideration of the composition even when one object in the image is selected.
また、本発明の実施の形態は、例えば、携帯機器(マウス、ペン型インターフェースなどの無い機器)の拡大用画像処理/IF(インターフェース)などとして応用することができる。また、テンプレートに合成するシステム/編集システム/印刷システムなどに適用することができる。例えば背景を中心とした人物の写真をテンプレート画像と合成したい場合、人物を指定すれば、人物を領域抽出し、構図解析から背景を含むような領域がトリミングされ、元画像から写真の元々の意図から外れずに拡大された合成写真が自動的に得られることになる。 Further, the embodiment of the present invention can be applied as, for example, enlargement image processing / IF (interface) for portable devices (devices without a mouse, pen-type interface, etc.). Further, the present invention can be applied to a system / editing system / printing system to be combined with a template. For example, if you want to synthesize a photograph of a person centered on the background with a template image, if you specify a person, the person is extracted, the area that includes the background is cropped from the composition analysis, and the original intent of the photograph is taken A composite photograph that has been enlarged without deviating from the above is automatically obtained.
1 画像選択部、2 指定領域選択部、3 構図解析/出力領域計算部
1 image selection unit, 2 designated area selection unit, 3 composition analysis / output area calculation unit
Claims (8)
する方法であって、
RGBで表現されている前記画像のRGB色情報をHSV情報に変換して算出した色相
に基づいて、前記画像を複数色の近似色領域に分けて分類し、同一色に分類された連続す
る近似領域毎に分割領域を形成し、操作者が指定した画像上の指定点を含む前記分割領域
を指定領域として抽出する指定領域抽出過程と、
指定領域抽出過程で抽出された指定領域の画像全体に占める位置関係を求める構図解析
過程と、
構図解析過程で求められた位置関係と、部分領域の大きさに係る値とに基づいて、指定
領域抽出過程で抽出された指定領域を含む部分領域を選択する部分領域選択過程と
を含むことを特徴とする画像領域選択方法。 A method in which a portable information device, which is a digital camera or a mobile phone, selects a partial area from one image,
Hue calculated by converting RGB color information of the image expressed in RGB into HSV information
Based on the image, the image is divided into a plurality of approximate color areas and classified, and continuous images classified into the same color are classified.
A designated area extracting step of forming a divided area for each approximate area and extracting the divided area including the designated point on the image designated by the operator as the designated area;
A composition analysis process for obtaining a positional relationship in the entire image of the designated area extracted in the designated area extraction process;
A partial area selection process for selecting a partial area including the designated area extracted in the designated area extraction process based on the positional relationship obtained in the composition analysis process and a value related to the size of the partial area. An image region selection method as a feature.
、前記指定領域の右端から画像の右端までの距離D_rightと、前記指定領域の上端
から画像の上端までの距離D_upと、前記指定領域の下端から画像の下端までの距離D_
downとを前記位置関係として求め、
前記部分領域選択過程では、前記部分領域の横画素数Xoutと縦画素数Youtとを
、前記画像の横画素数X1と、前記画像の縦画素数Y1と、横画素数X1と縦画素数Y1
とを乗じて得られる前記画像の面積S1と、操作者から指定された面積比a(1>a≧0
)とに基づく以下式
大率b(≧1)とに基づく以下式
素数Y2とに基づいて、指定領域から拡張すべき横増分値dxと縦増分値dyとを、以下
式
、前記指定領域の右端から前記部分領域の右端までの距離d_rightと、前記指定領
域の上端から前記部分領域の上端までの距離d_upと、前記指定領域の下端から前記部
分領域の下端までの距離d_downとを、以下式
ことを特徴とする請求項1記載の画像領域選択方法。 In the composition analysis process, a distance D_left from the left end of the designated area to the left end of the image
, The distance D_right from the right edge of the designated area to the right edge of the image, and the top edge of the designated area
The distance D_up from the lower end of the designated area to the lower end of the image D_up
down as the positional relationship,
In the partial area selection process, the horizontal pixel number Xout and the vertical pixel number Yout of the partial area are calculated.
The horizontal pixel count X1 of the image, the vertical pixel count Y1 of the image, the horizontal pixel count X1 and the vertical pixel count Y1
And an area ratio a (1> a ≧ 0) designated by the operator.
) And the following formula
The following formula based on large factor b (≧ 1)
Based on the prime number Y2, the horizontal increment value dx and the vertical increment value dy to be expanded from the specified area are expressed as follows:
formula
, A distance d_right from the right end of the specified area to the right end of the partial area, and the specified area
A distance d_up from the upper end of the area to the upper end of the partial area, and the lower end of the designated area to the part
The distance d_down to the lower end of the minute area is expressed as follows:
選択する
ことを特徴とする請求項1または2のいずれか1項記載の画像領域選択方法。 3. The image region selection method according to claim 1, wherein, in the partial region selection process, the partial region is selected so as to maintain an aspect ratio of the image.
選択する
ことを特徴とする請求項1〜3のいずれか1項記載の画像領域選択方法。 The image region selection method according to any one of claims 1 to 3, wherein, in the partial region selection step, the partial region is selected so as to match an aspect ratio of an output medium.
する
ことを特徴とする請求項1〜4のいずれか1項記載の画像領域選択方法。 5. The image region selection method according to claim 1, further comprising: combining a predetermined template image with the selected partial region in the partial region selection step.
ことを特徴とする請求項1〜5のいずれか1項記載の画像領域選択方法。 The image region selection method according to claim 1, wherein in the partial region selection process, the partial region can be changed in accordance with an instruction from an operator.
置であって、
RGBで表現されている前記画像のRGB色情報をHSV情報に変換して算出した色相
に基づいて、前記画像を複数色の近似色領域に分けて分類し、同一色に分類された連続す
る近似領域毎に分割領域を形成し、操作者が指定した画像上の指定点を含む前記分割領域
を指定領域として抽出する指定領域抽出手段と、
指定領域抽出手段で抽出した指定領域の画像全体に占める位置関係を求める構図解析手
段と、
構図解析手段が求めた位置関係と、部分領域の大きさに係る値とに基づいて、指定領域
抽出手段が抽出した指定領域を含む部分領域を選択する部分領域選択手段と
を備えることを特徴とする携帯型情報装置。 A portable information device that is a digital camera or mobile phone that selects a partial area from one image
Where
Hue calculated by converting RGB color information of the image expressed in RGB into HSV information
Based on the image, the image is divided into a plurality of approximate color areas and classified, and continuous images classified into the same color are classified.
A designated area extracting means for forming a divided area for each approximate area and extracting the divided area including the designated point on the image designated by the operator as the designated area;
Composition analysis means for obtaining a positional relationship in the entire image of the designated area extracted by the designated area extraction means;
A partial area selecting means for selecting a partial area including the designated area extracted by the designated area extracting means based on the positional relationship obtained by the composition analyzing means and a value relating to the size of the partial area. Portable information device .
するためのプログラムであって、
RGBで表現されている前記画像のRGB色情報をHSV情報に変換して算出した色相
に基づいて、前記画像を複数色の近似色領域に分けて分類し、同一色に分類された連続す
る近似領域毎に分割領域を形成し、操作者が指定した画像上の指定点を含む前記分割領域
を指定領域として抽出する指定領域抽出過程と、
指定領域抽出過程で抽出された指定領域の画像全体に占める位置関係を求める構図解析
過程と、
構図解析過程で求められた位置関係と、部分領域の大きさに係る値とに基づいて、指定
領域抽出過程で抽出された指定領域を含む部分領域を選択する部分領域選択過程と
をコンピュータによって実行するための記述を含むことを特徴とする画像領域選択プロ
グラム。 A portable information device that is a digital camera or a mobile phone is a program for selecting a partial area from one image,
Hue calculated by converting RGB color information of the image expressed in RGB into HSV information
Based on the image, the image is divided into a plurality of approximate color areas and classified, and continuous images classified into the same color are classified.
A designated area extracting step of forming a divided area for each approximate area and extracting the divided area including the designated point on the image designated by the operator as the designated area;
A composition analysis process for obtaining a positional relationship in the entire image of the designated area extracted in the designated area extraction process;
A partial area selection process for selecting a partial area including the specified area extracted in the specified area extraction process based on the positional relationship obtained in the composition analysis process and the value related to the size of the partial area is executed by a computer. An image region selection program characterized by including a description for
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2003306811A JP4380268B2 (en) | 2003-08-29 | 2003-08-29 | Image region selection method and apparatus |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2003306811A JP4380268B2 (en) | 2003-08-29 | 2003-08-29 | Image region selection method and apparatus |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2005078290A JP2005078290A (en) | 2005-03-24 |
| JP4380268B2 true JP4380268B2 (en) | 2009-12-09 |
Family
ID=34409789
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2003306811A Expired - Lifetime JP4380268B2 (en) | 2003-08-29 | 2003-08-29 | Image region selection method and apparatus |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP4380268B2 (en) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP7170051B2 (en) | 2018-09-20 | 2022-11-11 | 富士フイルム株式会社 | Image processing device, image processing method and program, and portable terminal device |
-
2003
- 2003-08-29 JP JP2003306811A patent/JP4380268B2/en not_active Expired - Lifetime
Also Published As
| Publication number | Publication date |
|---|---|
| JP2005078290A (en) | 2005-03-24 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US8139826B2 (en) | Device and method for creating photo album | |
| US20180182065A1 (en) | Apparatus, system, and method of controlling display, and recording medium | |
| WO2004015987A1 (en) | Image combination device, image combination method, image combination program, and recording medium containing the image combination program | |
| JP2005122320A (en) | Imaging apparatus, image processing method thereof, and program | |
| CN102572257B (en) | Image processing apparatus and image processing method | |
| EP1443462A2 (en) | Image editing device, method for trimming image, and program therefor | |
| JP2010074405A (en) | Image processing apparatus and method | |
| US7212674B1 (en) | Method, apparatus and recording medium for face extraction | |
| JP2014239367A (en) | Image processor, image processing method, and program | |
| JP6497030B2 (en) | Imaging system, information processing apparatus, imaging method, program, storage medium | |
| JP2008244997A (en) | Image processing system | |
| JP2008067110A (en) | Super-resolution image generator | |
| JP4380268B2 (en) | Image region selection method and apparatus | |
| JP2008228017A (en) | Color conversion processing program, color conversion processing device and image formation system | |
| JP2005293367A (en) | Image processing method and apparatus | |
| JP2005252739A (en) | Still image generating apparatus and method | |
| JP2006350936A (en) | Image forming device and image forming program | |
| JP4148114B2 (en) | Image processing apparatus and processing method | |
| JP4148165B2 (en) | Image composition to create a composite image by overlaying images | |
| KR20020084321A (en) | real-time character composition method using template | |
| JP7263846B2 (en) | Programs, terminals and controllers | |
| JP4363153B2 (en) | Imaging apparatus, image processing method thereof, and program | |
| JP5906745B2 (en) | Image display device, image display method, and program | |
| JP2011175309A (en) | Image processing apparatus and program | |
| JP2011188237A (en) | Image processing method and image processing apparatus |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20060828 |
|
| RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20070403 |
|
| A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20090608 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20090616 |
|
| A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20090806 |
|
| TRDD | Decision of grant or rejection written | ||
| A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20090901 |
|
| A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20090914 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20121002 Year of fee payment: 3 |
|
| R150 | Certificate of patent or registration of utility model |
Free format text: JAPANESE INTERMEDIATE CODE: R150 |