JP5092958B2 - Image processing apparatus and program - Google Patents

Image processing apparatus and program Download PDF

Info

Publication number
JP5092958B2
JP5092958B2 JP2008185854A JP2008185854A JP5092958B2 JP 5092958 B2 JP5092958 B2 JP 5092958B2 JP 2008185854 A JP2008185854 A JP 2008185854A JP 2008185854 A JP2008185854 A JP 2008185854A JP 5092958 B2 JP5092958 B2 JP 5092958B2
Authority
JP
Japan
Prior art keywords
image
composite
subject
specifying
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 - Fee Related
Application number
JP2008185854A
Other languages
Japanese (ja)
Other versions
JP2010028346A5 (en
JP2010028346A (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.)
Casio Computer Co Ltd
Original Assignee
Casio Computer Co Ltd
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 Casio Computer Co Ltd filed Critical Casio Computer Co Ltd
Priority to JP2008185854A priority Critical patent/JP5092958B2/en
Publication of JP2010028346A publication Critical patent/JP2010028346A/en
Publication of JP2010028346A5 publication Critical patent/JP2010028346A5/ja
Application granted granted Critical
Publication of JP5092958B2 publication Critical patent/JP5092958B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Description

本発明は、画像処理装置、及び、プログラムに関する。 The present invention relates to an image processing apparatus, and relates to a program.

従来、撮像した画像から被写体を抽出し、当該被写体と背景画像を合成して合成写真を取得する撮像装置が知られている(例えば、特許文献1参照)。具体的には、絞り値を変更して少なくとも2枚の画像を取得し、被写体抽出用の画像から被写体を抽出して、当該被写体を背景画像と合成する。
特開2006−128754号公報
2. Description of the Related Art Conventionally, an imaging device that extracts a subject from a captured image and synthesizes the subject and a background image to obtain a composite photograph is known (see, for example, Patent Document 1). Specifically, at least two images are acquired by changing the aperture value, the subject is extracted from the subject extraction image, and the subject is combined with the background image.
JP 2006-128754 A

しかしながら、上記特許文献1にあっては、被写体を少なくとも2枚撮影・記録しなければならないので、撮影者にとっては、同じ撮影画角について、撮影条件の異なる画像を少なくとも2枚撮影しなければならないという問題があった。   However, in Patent Document 1, since at least two subjects must be photographed and recorded, the photographer must photograph at least two images with different photographing conditions for the same photographing angle of view. There was a problem.

そこで、本発明の課題は、一の被写体画像から主要被写体が含まれる画像領域を判別し、この画像領域の位置を考慮して画像合成することができる画像処理装置、及び、プログラムを提供することである。 Accordingly, an object of the present invention is to provide an image processing apparatus and a program capable of determining an image region including a main subject from one subject image and combining the images in consideration of the position of the image region. It is.

上記課題を解決するため、請求項1に記載の発明は、
素材画像を記憶する素材画像記憶手段と、一の被写体画像に含まれる主要被写体に対応する第1の画像領域の位置を特定する位置特定手段と、前記位置特定手段により特定された前記一の被写体画像の前記第1の画像領域の位置以外の第2の画像領域における前記素材画像の合成位置を、外部操作を検出することにより入力する合成位置入力手段と、この合成位置入力手段によって入力された合成位置よりも前記位置特定手段によって特定された第1の画像領域の位置に近づくような合成位置を取得し、この取得された合成位置に前記素材画像記憶手段に記憶されている前記素材画像を合成する処理を行う合成処理手段と、を備えることを特徴としている。
In order to solve the above-mentioned problem, the invention described in claim 1
Material image storage means for storing a material image, position specifying means for specifying the position of a first image area corresponding to a main subject included in one subject image, and the one subject specified by the position specifying means A composite position input means for inputting the composite position of the material image in the second image area other than the position of the first image area of the image by detecting an external operation, and the composite position input means A composite position that is closer to the position of the first image area specified by the position specifying means than the composite position is acquired, and the material image stored in the material image storage means is acquired at the acquired composite position. And a synthesis processing means for performing a process of synthesis.

請求項に記載の発明は、請求項に記載の発明において、
前記被写体画像を構成する画素集合の輪郭線を抽出する抽出手段と、この抽出手段によって抽出された輪郭線のうちの所定値よりも小さい画素集合の輪郭線を除くことにより、前記主要被写体を描画した主要輪郭線を特定する輪郭線特定手段と、を更に備え、前記位置特定手段は、前記輪郭線特定手段によって特定された前記主要輪郭線で囲まれた画像領域の位置を、前記主要画像領域の位置として特定することを特徴としている。
The invention according to claim 2 is the invention according to claim 1 ,
The main subject is drawn by excluding an outline of a pixel set that constitutes the subject image and an outline of a pixel set that is smaller than a predetermined value among the outlines extracted by the extraction means. Contour specifying means for specifying the main contour line, wherein the position specifying means determines the position of the image area surrounded by the main contour line specified by the contour specifying means as the main image area. It is characterized by specifying as the position of.

請求項に記載の発明は、請求項に記載の発明において、
前記一の被写体画像を複数の領域に分割する分割手段と、この分割手段によって分割された夫々の領域について、周波数成分情報を取得する情報取得手段と、を更に備え、前記位置特定手段は、前記情報取得手段によって取得された前記周波数成分情報に基づいて、高周波成分が所定値よりも多い領域を前記第1の画像領域を構成する画像領域と判断することを特徴としている。
The invention according to claim 3 is the invention according to claim 1 ,
A division unit that divides the one subject image into a plurality of regions; and an information acquisition unit that acquires frequency component information for each of the regions divided by the division unit. Based on the frequency component information acquired by the information acquisition means, an area where the high frequency component is larger than a predetermined value is determined as an image area constituting the first image area.

請求項に記載の発明は、請求項1乃至のいずれかに記載の発明において、前記被写体画像を撮像する撮像手段を更に備えることを特徴としている。 According to a fourth aspect of the invention, there is provided the method according to any one of the first to third aspects, further comprising an imaging unit that images the subject image.

請求項に記載の発明は、コンピュータを、一の被写体画像に含まれる主要被写体に対応する第1の画像領域の位置を特定する位置特定手段、前記位置特定手段により特定された前記一の被写体画像の前記第1の画像領域の位置以外の第2の画像領域における素材画像の合成位置を、外部操作を検出することにより入力する合成位置入力手段、この合成位置入力手段によって入力された合成位置よりも前記位置特定手段によって特定された第1の画像領域の位置に近づくような合成位置を取得し、この取得された合成位置に前記素材画像を合成する処理を行う合成処理手段、として機能させることを特徴としている。 According to the fifth aspect of the present invention, the computer specifies a position of a first image region corresponding to a main subject included in one subject image, and the one subject specified by the position specifying unit. Composite position input means for inputting the composite position of the material image in the second image area other than the position of the first image area of the image by detecting an external operation, and the composite position input by the composite position input means Rather than a composite processing unit that acquires a composite position that is closer to the position of the first image area specified by the position specifying unit, and performs a process of combining the material image with the acquired composite position . It is characterized by that.

本発明によれば、一の被写体画像から主要被写体が含まれる画像領域を判別し、この画像領域の位置を考慮して画像合成することができる。 According to the present invention, it is possible to discriminate an image region including a main subject from one subject image, and to combine the images in consideration of the position of the image region .

以下に、本発明について、図面を用いて具体的な態様を説明する。ただし、発明の範囲は、図示例に限定されない。
図1は、本発明を適用した一実施形態の撮像装置100の外観を模式的に示す図であり、図1(a)は、撮像装置100の正面図を表し、図1(b)は、撮像装置100の背面図を表し、図1(c)は、撮像装置100の平面図を表している。また、図2は、撮像装置100の概略構成を示すブロック図である。
Hereinafter, specific embodiments of the present invention will be described with reference to the drawings. However, the scope of the invention is not limited to the illustrated examples.
FIG. 1 is a diagram schematically illustrating an appearance of an imaging apparatus 100 according to an embodiment to which the present invention is applied. FIG. 1A illustrates a front view of the imaging apparatus 100, and FIG. A rear view of the imaging device 100 is shown, and FIG. 1C shows a plan view of the imaging device 100. FIG. 2 is a block diagram illustrating a schematic configuration of the imaging apparatus 100.

本実施形態の撮像装置100は、一のモニタ表示用画像や記録用画像における主要被写体Sに対応する主要画像領域(第1の画像領域)A1の位置を特定して、当該モニタ表示用画像や記録用画像における主要画像領域A1の位置以外の背景領域(第2の画像領域)A2に対して所定の加工処理を行う。
具体的には、図1(a)〜図1(c)に示すように、撮像装置100は、外形が略直方体状に形成され、その正面側に撮像部1の撮像レンズ1aが露出するように配設され、撮像レンズ1aの向かって右上側にストロボ発光窓2が配設されている(図1(a)参照)。また、撮像装置100の背面には、図1(b)に示すように、表示部3の表示画面3aが露出するように配設され、表示画面3aの向かって右側に、操作入力部4に備わるメニューキー4a、カーソルキー4b及びセットキー4cが配設されている。また、撮像装置100の上面には、操作入力部4に備わるシャッターボタン4d、電源ボタン4eが並んで配設されている。
なお、図示は省略するが、例えば、撮像装置100の左右何れかの側面には、PC等の外部機器とUSBケーブル(図示略)を介して接続するためのUSB接続端子5(図2参照)が配設されている。
The imaging apparatus 100 of the present embodiment specifies the position of the main image area (first image area) A1 corresponding to the main subject S in one monitor display image or recording image, and Predetermined processing is performed on the background area (second image area) A2 other than the position of the main image area A1 in the recording image.
Specifically, as illustrated in FIGS. 1A to 1C, the imaging device 100 has an outer shape formed in a substantially rectangular parallelepiped shape, and the imaging lens 1 a of the imaging unit 1 is exposed on the front side thereof. The strobe light emission window 2 is disposed on the upper right side of the imaging lens 1a (see FIG. 1A). Further, as shown in FIG. 1B, the display device 3 is disposed on the rear surface of the imaging device 100 so as to be exposed, and on the operation input unit 4 on the right side of the display screen 3a. A menu key 4a, a cursor key 4b and a set key 4c are provided. A shutter button 4d and a power button 4e provided in the operation input unit 4 are arranged side by side on the upper surface of the imaging apparatus 100.
Although illustration is omitted, for example, a USB connection terminal 5 (see FIG. 2) for connecting to an external device such as a PC via a USB cable (not shown) on either the left or right side of the imaging apparatus 100. Is arranged.

また、撮像装置100は、図2に示すように、撮像部1と、DMA制御部6と、ワークメモリ7と、画像エンジン8と、表示部3と、表示制御部9と、VRAM10と、操作入力部4と、USB制御部11と、CPU12と、フラッシュメモリ13とを備えている。   As shown in FIG. 2, the imaging apparatus 100 includes an imaging unit 1, a DMA control unit 6, a work memory 7, an image engine 8, a display unit 3, a display control unit 9, a VRAM 10, and an operation. An input unit 4, a USB control unit 11, a CPU 12, and a flash memory 13 are provided.

撮像部1は、撮像手段として、被写体を連続して撮像して複数の画像フレームを生成する。具体的には、撮像部1は、撮像レンズ1aと、電子撮像部1bと、ISP1c等を備えている。   The imaging unit 1, as an imaging unit, continuously captures a subject and generates a plurality of image frames. Specifically, the imaging unit 1 includes an imaging lens 1a, an electronic imaging unit 1b, an ISP 1c, and the like.

撮像レンズ1aは、例えば、複数のレンズから構成され、合焦レンズやズームレンズ等を備えている。
電子撮像部1bは、撮像レンズ1aを通過した被写体像を二次元の画像信号に変換するCCD(Charge Coupled Device)やCMOS(Complementary Metal-oxide Semiconductor)等から構成されている。また、電子撮像部1bは、光電変換された画像信号をA/D変換して、デジタルデータとしてISP1cに出力する。
なお、電子撮像部1bから出力されるデジタルデータは、カラーフィルタ(図示略)の配列(例えば、ベイヤ配列)に従った形式となっている。
ISP(Image Signal Processor)1cは、入力されたデジタルデータに基づいて、色の調整、データフォーマット変換(例えば、ベイヤ配設から8bitの輝度信号Y、色差信号Cb,Crへの変換)等を行う。
The imaging lens 1a is composed of, for example, a plurality of lenses and includes a focusing lens, a zoom lens, and the like.
The electronic imaging unit 1b includes a CCD (Charge Coupled Device), a CMOS (Complementary Metal-Oxide Semiconductor), or the like that converts a subject image that has passed through the imaging lens 1a into a two-dimensional image signal. Further, the electronic imaging unit 1b performs A / D conversion on the photoelectrically converted image signal and outputs it as digital data to the ISP 1c.
The digital data output from the electronic imaging unit 1b has a format according to an array (for example, Bayer array) of color filters (not shown).
An ISP (Image Signal Processor) 1c performs color adjustment, data format conversion (for example, conversion from a Bayer arrangement to an 8-bit luminance signal Y and color difference signals Cb and Cr) based on the input digital data. .

撮像部1から出力されるデータ(輝度信号Y、色差信号Cb,Cr)は、DMA制御部6の制御下にて、ワークメモリ7にDMA(Direct Memory Access)転送されて格納される。   Data (luminance signal Y, color difference signals Cb, Cr) output from the imaging unit 1 is DMA-transferred and stored in the work memory 7 under the control of the DMA control unit 6.

ワークメモリ7は、例えば、DRAM等で構成され、フラッシュメモリ13から読み出されたシステムプログラム、各種プログラム、各種データ及び各種パラメータ等を一時的に記憶する。   The work memory 7 is composed of, for example, a DRAM or the like, and temporarily stores a system program, various programs, various data, various parameters, and the like read from the flash memory 13.

画像エンジン8は、ワークメモリ7内の輝度信号Y、色差信号Cb,CrをRGBデータに変換してVRAM10に出力したり、画像撮影時にJPEG等の所定のファイルフォーマットに変換してフラッシュメモリ13に出力する。   The image engine 8 converts the luminance signal Y and the color difference signals Cb and Cr in the work memory 7 into RGB data and outputs them to the VRAM 10 or converts them into a predetermined file format such as JPEG at the time of image shooting to the flash memory 13. Output.

また、画像エンジン8は、CPU12の制御下における表示画像CG合成処理や撮像画像CG合成処理(後述)にて、モニタ表示用画像や記録用画像に対してフラッシュメモリ13に記憶されている所望のCG画像50を合成する。
ここで、画像エンジン8及びCPU12は、画像合成手段として機能する。
Further, the image engine 8 performs a display image CG synthesis process or a captured image CG synthesis process (described later) under the control of the CPU 12 with a desired image stored in the flash memory 13 for the monitor display image and the recording image. The CG image 50 is synthesized.
Here, the image engine 8 and the CPU 12 function as image composition means.

表示制御部9は、VRAM10に一時的に記憶されている表示データを読み出して表示部3に表示させる制御を行う。
表示部3は、表示制御部9からの出力信号に基づいて撮像部1により撮像された画像等を表示画面3aに表示する。具体的には、表示部3は、撮像部1による被写体の撮像により生成された複数の画像フレームに基づいてスルー画像や、フラッシュメモリ13に記録される本画像(記録画像)や、CG合成処理にて生成されるCG合成画像I6(図10参照)等を表示する。
The display control unit 9 performs control to read out display data temporarily stored in the VRAM 10 and display it on the display unit 3.
The display unit 3 displays an image captured by the imaging unit 1 on the display screen 3a based on an output signal from the display control unit 9. Specifically, the display unit 3 displays a through image, a main image (recorded image) recorded in the flash memory 13 based on a plurality of image frames generated by imaging the subject by the imaging unit 1, and CG synthesis processing. The CG composite image I6 (see FIG. 10) and the like generated in the above are displayed.

操作入力部4は、当該撮像装置100の所定操作を行うためのものであり、メニューキー4a、カーソルキー4b、セットキー4c、シャッターボタン4d、電源ボタン4e等を備え、これらのキーやボタンの操作に応じて所定の操作信号をCPU12に出力する。
メニューキー4aは、ユーザによる操作に基づいて、機能選択や表示設定等に係るメニュー画面の表示部3への表示を指示する。
The operation input unit 4 is for performing a predetermined operation of the imaging apparatus 100, and includes a menu key 4a, a cursor key 4b, a set key 4c, a shutter button 4d, a power button 4e, and the like. A predetermined operation signal is output to the CPU 12 according to the operation.
The menu key 4a instructs display on the display unit 3 of a menu screen related to function selection, display setting, and the like based on an operation by the user.

カーソルキー4bは、例えば、上下左右のカーソルキー4bを備えて構成され、ユーザによる操作に基づいて、メニュー画面に表示される各種項目の選択を指示する。具体的には、撮像装置100の動作モードとして、例えば、所定サイズの静止画像を撮影する通常撮影モードや、静止画像にCG画像50を合成するCG合成撮影モード、記録された画像を再生表示する再生モード等の選択を指示する。また、カーソルキー4bは、再生モードにて、表示部3に表示される画像の選択を指示する。さらに、カーソルキー4bは、CG合成撮影モードにて、静止画像に合成されるCG画像50の選択を指示する。   The cursor key 4b includes, for example, up / down / left / right cursor keys 4b, and instructs selection of various items displayed on the menu screen based on an operation by the user. Specifically, as an operation mode of the imaging apparatus 100, for example, a normal shooting mode for shooting a still image of a predetermined size, a CG composite shooting mode for combining the CG image 50 with a still image, and a recorded image are reproduced and displayed. Instructs selection of playback mode and the like. The cursor key 4b instructs selection of an image displayed on the display unit 3 in the reproduction mode. Furthermore, the cursor key 4b instructs selection of the CG image 50 to be combined with the still image in the CG composite shooting mode.

シャッターボタン4dは、ユーザによる操作に基づいて、撮像部1による被写体の撮像を指示する。
電源ボタン4eは、ユーザによる操作に基づいて、当該撮像装置100の電源のON/OFFを指示する。
The shutter button 4d instructs imaging of the subject by the imaging unit 1 based on an operation by the user.
The power button 4e instructs to turn on / off the power of the imaging apparatus 100 based on an operation by the user.

USB制御部11は、USB接続端子5にUSBケーブルを介して接続されたPC等の外部機器との間で、各種データの送受信を制御する。   The USB control unit 11 controls transmission / reception of various data to / from an external device such as a PC connected to the USB connection terminal 5 via a USB cable.

CPU12は、フラッシュメモリ13に記憶された撮像装置100用の各種処理プログラムに従って各種の制御動作を行うものである。   The CPU 12 performs various control operations in accordance with various processing programs for the imaging device 100 stored in the flash memory 13.

フラッシュメモリ13は、CPU12の動作に必要な各種プログラムやデータを記憶する。具体的には、フラッシュメモリ13は、図2に示すように、抽出プログラム13a、輪郭線特定プログラム13b、CG合成制御プログラム13c等を記憶している。   The flash memory 13 stores various programs and data necessary for the operation of the CPU 12. Specifically, as shown in FIG. 2, the flash memory 13 stores an extraction program 13a, an outline specifying program 13b, a CG synthesis control program 13c, and the like.

抽出プログラム13aは、CPU12を抽出手段として機能させるものである。即ち、抽出プログラム13aは、被写体画像を構成する画素集合の輪郭線を抽出する抽出処理に係る機能をCPU12に実現させるためのプログラムである。
具体的には、CPU12が抽出プログラム13aを実行することで、撮像部1により撮像され取得されたモニタ表示用画像や記録用画像に平滑化処理(後述)が施されたものに対して、ソーベルフィルタを用いた3×3のマトリックス演算により1階微分処理を行って、画素集合の輪郭線(エッジ部分)を抽出する(図8(b)参照)。
なお、抽出処理にあっては、ソーベルフィルタの代わりに、例えば、微分フィルタ、プリューウィットフィルタ、ラプラシアンフィルタ等を用いても良いし、これらのうちの何れか二つ以上を用いても良い。
The extraction program 13a causes the CPU 12 to function as extraction means. In other words, the extraction program 13a is a program for causing the CPU 12 to realize a function related to the extraction processing for extracting the outline of the pixel set constituting the subject image.
Specifically, when the CPU 12 executes the extraction program 13a, a monitor display image or a recording image captured and acquired by the imaging unit 1 is subjected to smoothing processing (described later). A first-order differentiation process is performed by a 3 × 3 matrix operation using a bell filter to extract a contour line (edge portion) of the pixel set (see FIG. 8B).
In the extraction process, for example, a differential filter, a Prewitt filter, a Laplacian filter, or the like may be used instead of the Sobel filter, or any two or more of these may be used.

輪郭線特定プログラム13bは、CPU12を輪郭線特定手段として機能させるものである。即ち、輪郭線特定プログラム13bは、抽出処理にて抽出された輪郭線のうち、所定値よりも小さい画素集合の輪郭線を除くことにより、主要被写体Sを描画した外周輪郭(主要輪郭線)L1を特定する輪郭線特定処理に係る機能をCPU12に実現させるためのプログラムである。
具体的には、CPU12が輪郭線特定プログラム13bを実行することで、抽出処理後の画像I2(図8(b)参照)に対してエッジの連結性を高めるための膨張処理、及び所定数よりも画素の連結数の少ない連結成分(画像集合)を除く小領域削除処理を行って、主要被写体Sの外周輪郭を特定する。
The contour specifying program 13b causes the CPU 12 to function as contour specifying means. That is, the contour specifying program 13b removes the contour of the pixel set smaller than the predetermined value from the contour extracted by the extraction process, thereby creating the outer peripheral contour (main contour) L1 depicting the main subject S. This is a program for causing the CPU 12 to realize the function related to the contour line specifying process for specifying the.
Specifically, the CPU 12 executes the contour line specifying program 13b, so that an expansion process for improving edge connectivity with respect to the image I2 after the extraction process (see FIG. 8B), and a predetermined number In addition, the outer contour of the main subject S is specified by performing small area deletion processing excluding connected components (image sets) having a small number of connected pixels.

CG合成制御プログラム13cは、画像エンジン8に、被写体画像の背景領域A2(第2の画像領域)にCG画像50を合成させるCG合成処理に係る制御をCPU12に実現させるためのプログラムである。
具体的には、CPU12がCG合成制御プログラム13cを実行することで、表示画像CG合成処理や撮像画像CG合成処理にて、画像エンジン8に、背景抽出処理(後述)にて抽出された被写体画像の背景領域(第2の画像領域)A2におけるCG合成座標にCG画像50を合成させる。
The CG composition control program 13c is a program for causing the CPU 12 to implement control related to the CG composition processing for causing the image engine 8 to compose the CG image 50 with the background area A2 (second image area) of the subject image.
Specifically, the subject image extracted by the background extraction process (described later) in the image engine 8 by the display image CG synthesis process or the captured image CG synthesis process by the CPU 12 executing the CG synthesis control program 13c. The CG image 50 is synthesized with the CG synthesis coordinates in the background area (second image area) A2.

また、フラッシュメモリ13は、素材画像記憶手段として、CG合成処理にて被写体画像と合成されるCG画像(素材画像)50を複数記憶する。
さらに、フラッシュメモリ13は、撮像部1により撮像された本画像(撮影画像)やCG合成処理後のCG合成画像I6(図10参照)等を記憶する。
Further, the flash memory 13 stores a plurality of CG images (material images) 50 to be combined with the subject image in the CG combining process as a material image storage unit.
Furthermore, the flash memory 13 stores a main image (captured image) captured by the imaging unit 1, a CG composite image I6 (see FIG. 10) after the CG composite processing, and the like.

次に、撮像装置100によるCG合成処理について図3〜図10を参照して説明する。
なお、以下の説明にあっては、予めユーザによる操作入力部4の所定操作に基づいてCG合成撮影モードに設定されているものとする。
CG合成処理としては、スルー画像にCG画像50を合成する表示画像CG合成処理と、本画像(記録画像)にCG画像50を合成する撮像画像CG合成処理がある。
Next, CG composition processing by the imaging apparatus 100 will be described with reference to FIGS.
In the following description, it is assumed that the CG composite shooting mode is set in advance based on a predetermined operation of the operation input unit 4 by the user.
As the CG synthesis process, there are a display image CG synthesis process for synthesizing the CG image 50 with the through image, and a captured image CG synthesis process for synthesizing the CG image 50 with the main image (recorded image).

先ず、表示画像CG合成処理について図3を参照して説明する。
図3は、表示画像CG合成処理に係る動作の一例を示すフローチャートである。
First, the display image CG composition processing will be described with reference to FIG.
FIG. 3 is a flowchart illustrating an example of an operation related to the display image CG composition process.

撮像装置100がCG合成撮影モードに設定されていると、図3に示すように、CPU12は、撮像部1によりモニタ表示用画像を撮像して取得する処理を実行する(ステップS1A)。
次に、CPU12は、取得したモニタ表示用画像に基づいて、当該モニタ表示用画像におけるCG合成座標を計算するCG合成座標計算処理を実行する(ステップS2A:詳細後述)。
続けて、CPU12がフラッシュメモリ13内のCG合成制御プログラム13cを実行して、画像エンジン8は、CG合成座標計算処理にて計算されたCG合成座標に基づいて、スルー画像(モニタ表示用画像)にCG画像50を合成して(ステップS3A)、表示部3は、合成されたCG合成画像I6(図10参照)を表示画面3aに表示する(ステップS4A)。
When the imaging apparatus 100 is set to the CG composite shooting mode, as shown in FIG. 3, the CPU 12 executes a process of capturing and acquiring a monitor display image by the imaging unit 1 (step S1A).
Next, based on the acquired monitor display image, the CPU 12 executes CG composite coordinate calculation processing for calculating CG composite coordinates in the monitor display image (step S2A: details will be described later).
Subsequently, the CPU 12 executes the CG composition control program 13c in the flash memory 13, and the image engine 8 performs a through image (monitor display image) based on the CG composition coordinates calculated in the CG composition coordinate calculation processing. The CG image 50 is synthesized (step S3A), and the display unit 3 displays the synthesized CG synthesized image I6 (see FIG. 10) on the display screen 3a (step S4A).

次に、撮像画像CG合成処理について図4を参照して説明する。
図4は、撮像画像CG合成処理に係る動作の一例を示すフローチャートである。
Next, the captured image CG composition processing will be described with reference to FIG.
FIG. 4 is a flowchart illustrating an example of an operation related to the captured image CG composition process.

表示画面3aにスルー画像を表示中や、上記の表示画像CG合成処理にて合成されたCG合成画像I6を表示中に、ユーザによりシャッターボタン4dが所定操作されると、CPU12は、光学系駆動制御部(図示略)により合焦レンズを光軸方向に移動させて主要被写体Sにピントが合っている記録用画像を撮像部1により撮像して取得する処理を実行する(ステップS1B)。
次に、CPU12は、取得した記録用画像に基づいて、当該記録用画像におけるCG合成座標を計算するCG合成座標計算処理を実行する(ステップS2B:詳細後述)。
続けて、CPU12がフラッシュメモリ13内のCG合成制御プログラム13cを実行して、画像エンジン8は、CG合成座標計算処理にて計算されたCG合成座標に基づいて、記録用画像にCG画像50を合成して(ステップS3B)、DMA制御部6は、合成されたCG合成画像I6(図10参照)をフラッシュメモリ13に転送して記憶する(ステップS4B)。
When the user operates the shutter button 4d for a predetermined time while displaying a through image on the display screen 3a or displaying the CG composite image I6 synthesized by the display image CG synthesis process, the CPU 12 drives the optical system. The control unit (not shown) moves the focusing lens in the optical axis direction, and executes a process of capturing and acquiring a recording image focused on the main subject S by the imaging unit 1 (step S1B).
Next, the CPU 12 executes CG composite coordinate calculation processing for calculating CG composite coordinates in the recording image based on the acquired recording image (step S2B: details will be described later).
Subsequently, the CPU 12 executes the CG composition control program 13c in the flash memory 13, and the image engine 8 adds the CG image 50 to the recording image based on the CG composition coordinates calculated in the CG composition coordinate calculation processing. After combining (step S3B), the DMA control unit 6 transfers the combined CG combined image I6 (see FIG. 10) to the flash memory 13 and stores it (step S4B).

次に、CG合成座標計算処理について、図5〜図9を参照して説明する。
図5は、CG合成座標計算処理に係る動作の一例を示すフローチャートである。また、図6は、CG合成座標計算処理における小領域削除処理に係る動作の一例を示すフローチャートであり、図7は、G合成座標計算処理における背景抽出処理に係る動作の一例を示すフローチャートである。また、図8(a)及び図8(b)並びに図9(a)〜図9(c)は、CG合成座標計算処理を説明するための画像を模式的に示す図である。
Next, the CG composite coordinate calculation process will be described with reference to FIGS.
FIG. 5 is a flowchart illustrating an example of an operation related to the CG composite coordinate calculation process. FIG. 6 is a flowchart illustrating an example of an operation related to the small area deletion process in the CG composite coordinate calculation process, and FIG. 7 is a flowchart illustrating an example of an operation related to the background extraction process in the G composite coordinate calculation process. . FIGS. 8A and 8B and FIGS. 9A to 9C are diagrams schematically showing images for explaining the CG composite coordinate calculation processing.

表示画像CG合成処理におけるCG合成座標計算処理(ステップS2A)と、撮像画像CG合成処理におけるCG合成座標計算処理(ステップS2B)は、略同様の処理であり、以下にまとめて説明する。
なお、以下に説明するCG合成座標計算処理にあっては、予めユーザによる操作入力部4の所定操作に基づいて、被写体画像に合成される所定のCG画像50が設定されているものとする。
The CG composite coordinate calculation process (step S2A) in the display image CG composite process and the CG composite coordinate calculation process (step S2B) in the captured image CG composite process are substantially the same processes, and will be described together below.
In the CG composite coordinate calculation process described below, it is assumed that a predetermined CG image 50 to be combined with the subject image is set in advance based on a predetermined operation of the operation input unit 4 by the user.

CG合成座標計算処理にあっては、図5に示すように、先ず、CPU12は、撮像部1により取得したモニタ表示用画像(記録用画像)I1の輝度信号Y(図8(a)参照)に対して、ガウシアンフィルタを用いて平滑化処理を行って、ノイズを除去する(ステップS21)。
次に、CPU12は、フラッシュメモリ13内の抽出プログラム13aを実行して、平滑化処理後の画像に対してソーベルフィルタを用いた3×3のマトリックス演算により1階微分処理を行って、画素集合の輪郭線(エッジ部分)を抽出する(ステップS22;図8(b)参照)。
In the CG composite coordinate calculation process, as shown in FIG. 5, first, the CPU 12 first displays the luminance signal Y of the monitor display image (recording image) I1 acquired by the imaging unit 1 (see FIG. 8A). Then, smoothing processing is performed using a Gaussian filter to remove noise (step S21).
Next, the CPU 12 executes the extraction program 13a in the flash memory 13, performs a first-order differentiation process on the smoothed image by a 3 × 3 matrix operation using a Sobel filter, and generates a pixel. The outline (edge portion) of the set is extracted (step S22; see FIG. 8B).

次に、CPU12は、フラッシュメモリ13内の輪郭線特定プログラム13bを実行して、抽出処理後の画像I2に対してエッジの連結性を高めるために膨張処理を行った後(ステップS23;図9(a)参照)、膨張処理後の画像I3に対して、所定数よりも画素の連結数の少ない孤立した連結成分(画像集合)を除く小領域削除処理を行う(ステップS24;図9(b)参照))。   Next, the CPU 12 executes the contour line specifying program 13b in the flash memory 13 and performs an expansion process on the extracted image I2 in order to enhance edge connectivity (step S23; FIG. 9). (Refer to (a)), the small area deletion process is performed on the image I3 after the expansion process to remove an isolated connected component (image set) whose number of connected pixels is smaller than a predetermined number (step S24; FIG. 9B). )reference)).

以下に、小領域削除処理(ステップS24)について図6を参照して詳細に説明する。
図6に示すように、先ず、CPU12は、膨張処理後の画像(2値化された画像)I3に対して、同じ連結成分を構成する画素集合に同じ番号(ラベル)を付けるラベリングを行って、ラベル数を「LN」に格納する(ステップS241)。
Hereinafter, the small area deletion process (step S24) will be described in detail with reference to FIG.
As shown in FIG. 6, first, the CPU 12 performs labeling for assigning the same number (label) to the pixel sets constituting the same connected component on the image (binarized image) I3 after the expansion processing. The number of labels is stored in “LN” (step S241).

次に、CPU12は、ループ変数nを1に初期化した後(ステップS242)、n(例えば、n=1)番目のラベルの連結数を「LS」に格納する(ステップS243)。そして、CPU12は、予め設定されている所定の閾値DEF_LSと「LS」に格納されているn番目のラベルの連結数を比較して、当該「LS」の値が所定の閾値DEF_LSよりも大きいか否かを判定する(ステップS244)。
ここで、「LS」の値が所定の閾値DEF_LS以下であると判定されると(ステップS244;NO)、CPU12は、当該「LS」に係るn番目のラベルを小領域と判断して削除する(ステップS245)。
Next, after initializing the loop variable n to 1 (step S242), the CPU 12 stores the number of connected n (for example, n = 1) th labels in “LS” (step S243). Then, the CPU 12 compares the predetermined threshold value DEF_LS set in advance with the number of connections of the nth label stored in “LS”, and determines whether the value of “LS” is larger than the predetermined threshold value DEF_LS. It is determined whether or not (step S244).
Here, when it is determined that the value of “LS” is equal to or smaller than the predetermined threshold DEF_LS (step S244; NO), the CPU 12 determines that the nth label related to the “LS” is a small area and deletes it. (Step S245).

その後、CPU12は、ラベルの番号に係る「n」を+1インクリメント(n=n+1)する(ステップS246)。また、ステップS244にて、「LS」の値が所定の閾値DEF_LSよりも大きいと判定されると、ステップS246に移行する。
その後、CPU12は、インクリメントされた「n」と「LN」に格納されているラベル数を比較して、当該「LN」の値よりも「n」が大きいか否かを判定する(ステップS247)。
ここで、「n」が「LN」の値以下であると判定されると(ステップS247;NO)、ステップS243に戻る。
Thereafter, the CPU 12 increments “n” related to the label number by +1 (n = n + 1) (step S246). If it is determined in step S244 that the value of “LS” is greater than the predetermined threshold DEF_LS, the process proceeds to step S246.
Thereafter, the CPU 12 compares the incremented “n” with the number of labels stored in “LN”, and determines whether “n” is larger than the value of “LN” (step S247). .
Here, when it is determined that “n” is equal to or less than the value of “LN” (step S247; NO), the process returns to step S243.

上記の処理を、ステップS247にて、「n」が「LN」の値よりも大きいと判定されるまで繰り返し実行し(ステップS247;YES)、全てのラベルに対する処理が行われると、当該小領域削除処理を終了する。図9(b)に、小領域削除処理後の画像I4を表す。
このようにして、CPU12は、位置特定手段として、モニタ表示用画像や記録用画像における主要被写体Sの外周輪郭で囲まれた画像領域の位置を、被写体画像に含まれる主要被写体Sに対応する主要画像領域(第1の画像領域)A1の位置として特定する(図9(b)参照)。
The above process is repeated until it is determined in step S247 that “n” is larger than the value of “LN” (step S247; YES). The deletion process ends. FIG. 9B shows the image I4 after the small area deletion process.
In this way, the CPU 12 serves as the position specifying means for the position of the image region surrounded by the outer peripheral contour of the main subject S in the monitor display image and the recording image as the main subject corresponding to the main subject S included in the subject image. The position is specified as the position of the image area (first image area) A1 (see FIG. 9B).

その後、図5に示すように、CPU12は、背景抽出処理を行う(ステップS25)。
以下に、背景抽出処理について図7を参照して詳細に説明する。
図7に示すように、先ず、予めユーザによる操作入力部4の所定操作に基づいて指定されたCG画像50の合成位置に応じて分岐する(ステップS251)。
ここで、CG画像50の合成位置が主要被写体Sの左側に指定されている場合には、画像の左端から右側に向けて走査して連結成分の境界(輪郭線)の追跡を行い(ステップS252)、一方、CG画像50の合成位置が主要被写体Sの右側に指定されている場合には、画像の右端から左側に向けて走査して連結成分の境界の追跡を行う(ステップS253)。
Thereafter, as shown in FIG. 5, the CPU 12 performs background extraction processing (step S25).
The background extraction process will be described in detail below with reference to FIG.
As shown in FIG. 7, first, the process branches according to the combination position of the CG image 50 designated in advance based on a predetermined operation of the operation input unit 4 by the user (step S251).
Here, when the synthesis position of the CG image 50 is designated on the left side of the main subject S, scanning is performed from the left end of the image toward the right side to track the boundary (contour line) of the connected components (step S252). On the other hand, when the synthesis position of the CG image 50 is designated on the right side of the main subject S, the boundary of the connected component is traced by scanning from the right end to the left side of the image (step S253).

そして、CPU12は、小領域削除処理により特定された主要画像領域A1に到達するまで(黒画素から白画素に変化するまで)の領域を背景領域(第2の画像領域)A2として抽出する(ステップS254)。   Then, the CPU 12 extracts a region until the main image region A1 specified by the small region deletion process is reached (from the black pixel to the white pixel) as a background region (second image region) A2 (step S1). S254).

その後、図5に示すように、CPU12は、膨張処理(ステップS223)による膨張分を修正するために略等しい量の収縮処理を行う(ステップS26;図9(c)参照)。   Thereafter, as shown in FIG. 5, the CPU 12 performs a substantially equal amount of contraction processing to correct the expansion due to the expansion processing (step S223) (step S26; see FIG. 9C).

次に、CPU12は、背景領域A2におけるCG合成座標を算出する。具体的には、先ず、予めユーザによる操作入力部4の所定操作に基づいて指定されたCG画像50の合成位置に応じて分岐する(ステップS27)。
ここで、CG画像50の合成位置が主要被写体Sの左側に指定されている場合には、画像I5の左端から右側に向けて走査して、背景領域A2内でできる限り右側にCG画像50を合成できるようにCG合成座標を算出し(ステップS28)、一方、CG画像50の合成位置が主要被写体Sの右側に指定されている場合には、画像I5の右端から左側に向けて走査して、背景領域A2内でできる限り左側にCG画像50を合成できるようにCG合成座標を算出する(ステップS29;図9(c)参照)。
なお、CG合成座標の上下位置は、例えば、予め略中央に設定されているが、ユーザによる操作入力部4の所定操作に基づいて適宜任意に変更可能となっている。
Next, the CPU 12 calculates CG composite coordinates in the background area A2. Specifically, first, a branch is made according to the combination position of the CG image 50 designated in advance based on a predetermined operation of the operation input unit 4 by the user (step S27).
Here, when the synthesis position of the CG image 50 is designated on the left side of the main subject S, scanning is performed from the left end of the image I5 toward the right side, and the CG image 50 is placed on the right side as much as possible in the background area A2. CG composite coordinates are calculated so that they can be combined (step S28). On the other hand, when the composite position of the CG image 50 is designated on the right side of the main subject S, scanning is performed from the right end of the image I5 toward the left side. Then, the CG synthesis coordinates are calculated so that the CG image 50 can be synthesized as much as possible in the background area A2 (step S29; see FIG. 9C).
The vertical position of the CG composite coordinates is set, for example, approximately in the center in advance, but can be arbitrarily changed as appropriate based on a predetermined operation of the operation input unit 4 by the user.

その後、表示画像CG合成処理にあっては、図3に示すように、CPU12がフラッシュメモリ13内のCG合成制御プログラム13cを実行して、画像エンジン8は、CG合成座標計算処理にて計算されたCG合成座標に基づいて、スルー画像とCG画像50を合成してCG合成画像I6(図10参照)を生成し(ステップS3A)、続けて、当該CG合成画像I6を表示部3の表示画面3aに表示する(ステップS4A)。
また、撮像画像CG合成処理にあっては、図4に示すように、CPU12がフラッシュメモリ13内のCG合成制御プログラム13cを実行して、画像エンジン8は、CG合成座標計算処理にて計算されたCG合成座標に基づいて、記録用画像とCG画像50を合成してCG合成画像I6(図10参照)を生成し(ステップS3B)、続けて、当該CG合成画像I6をフラッシュメモリ13に転送して記憶する(ステップS4B)。
このようにして、CPU12及び画像エンジン8は、加工処理手段として、モニタ表示用画像や記録用画像の主要画像領域A1以外の背景領域A2に対して所定の加工処理として、表示画像CG合成処理や撮像画像CG合成処理を行う。
Thereafter, in the display image CG composition process, as shown in FIG. 3, the CPU 12 executes the CG composition control program 13c in the flash memory 13, and the image engine 8 is calculated by the CG composition coordinate calculation process. Based on the CG composite coordinates, the through image and the CG image 50 are combined to generate a CG composite image I6 (see FIG. 10) (step S3A), and then the CG composite image I6 is displayed on the display screen of the display unit 3. It is displayed on 3a (step S4A).
Further, in the captured image CG composition process, as shown in FIG. 4, the CPU 12 executes the CG composition control program 13c in the flash memory 13, and the image engine 8 is calculated by the CG composition coordinate calculation process. Based on the CG composite coordinates, the recording image and the CG image 50 are combined to generate a CG composite image I6 (see FIG. 10) (step S3B), and then the CG composite image I6 is transferred to the flash memory 13. (Step S4B).
In this way, the CPU 12 and the image engine 8 serve as a processing unit as a predetermined processing for the background image A2 other than the main image region A1 of the monitor display image or the recording image. A captured image CG synthesis process is performed.

以上のように、本実施形態の撮像装置100によれば、一のモニタ表示用画像や記録用画像における主要被写体Sに対応する主要画像領域A1の位置を特定して、当該モニタ表示用画像や記録用画像における主要画像領域A1の位置以外の背景領域A2に対してCG合成処理等の所定の加工処理を行うことができる。具体的には、モニタ表示用画像や記録用画像を構成する画素集合の輪郭線を抽出して、抽出された輪郭線のうちの所定値よりも小さい画素集合の輪郭線を除くことにより、主要被写体Sの外周輪郭を特定するので、従来のように、被写体画像を2枚撮影することなく、一の被写体画像から主要被写体Sが含まれる画像領域を判別することができる。
そして、特定された主要画像領域A1の位置以外の背景領域A2内にフラッシュメモリ13に記憶されているCG画像50を合成するので、主要被写体Sを除いた背景領域A2の加工を容易に行うことができる。
As described above, according to the imaging apparatus 100 of the present embodiment, the position of the main image area A1 corresponding to the main subject S in one monitor display image or recording image is specified, and the monitor display image or Predetermined processing such as CG synthesis processing can be performed on the background area A2 other than the position of the main image area A1 in the recording image. Specifically, by extracting the contour lines of the pixel set constituting the monitor display image and the recording image, and removing the contour lines of the pixel set smaller than a predetermined value from the extracted contour lines, Since the outer peripheral contour of the subject S is specified, an image region including the main subject S can be determined from one subject image without taking two subject images as in the conventional art.
Since the CG image 50 stored in the flash memory 13 is synthesized in the background area A2 other than the specified position of the main image area A1, the background area A2 excluding the main subject S can be easily processed. Can do.

なお、上記実施形態にあっては、抽出処理後の画像I2に対して膨張処理を行った後(ステップS23)、膨張処理による膨張分を修正するための収縮処理を行う(ステップS26)ようにしたが、これに限られるものではなく、被写体画像にノイズが少なく、主要被写体Sに対応する主要画像領域A1を適正に特定することができる場合には、必ずしも上記の膨張処理や収縮処理を行う必要はない。   In the above embodiment, after performing the expansion process on the image I2 after the extraction process (step S23), the contraction process for correcting the expansion due to the expansion process is performed (step S26). However, the present invention is not limited to this. When the subject image has little noise and the main image area A1 corresponding to the main subject S can be properly specified, the above expansion processing and contraction processing are necessarily performed. There is no need.

また、本発明は、上記実施形態に限定されることなく、本発明の趣旨を逸脱しない範囲において、種々の改良並びに設計の変更を行っても良い。
以下に、撮像装置の変形例1〜3について説明する。
The present invention is not limited to the above-described embodiment, and various improvements and design changes may be made without departing from the spirit of the present invention.
Below, the modifications 1-3 of an imaging device are demonstrated.

<変形例1>
変形例1の撮像装置200は、図11〜図16に示すように、CG合成座標計算処理にて、モニタ表示用画像や記録用画像を複数の画像領域B、…に分割して、夫々の画像領域Bについて、周波数成分情報を取得して、当該周波数成分情報に基づいて、高周波成分が所定値よりも多い画像領域Bを主要画像領域A1を構成する画像領域と判断する処理を行う。
なお、変形例1の撮像装置200は、以下に説明するCG合成座標計算処理以外の点で上記実施形態の撮像装置100と略同様の構成をなし、その説明は省略する。
<Modification 1>
As shown in FIGS. 11 to 16, the imaging apparatus 200 of Modification 1 divides the monitor display image and the recording image into a plurality of image areas B,... For the image region B, frequency component information is acquired, and based on the frequency component information, a process of determining an image region B having a high frequency component larger than a predetermined value as an image region constituting the main image region A1 is performed.
Note that the imaging apparatus 200 of Modification 1 has substantially the same configuration as the imaging apparatus 100 of the above-described embodiment except for the CG composite coordinate calculation process described below, and a description thereof is omitted.

即ち、図11に示すように、変形例1の撮像装置200のフラッシュメモリ13は、抽出プログラム13a、輪郭線特定プログラム13b、CG合成制御プログラム13cに加えて、分割プログラム13d、情報取得プログラム13eを記憶している。   That is, as shown in FIG. 11, the flash memory 13 of the imaging apparatus 200 according to the first modification includes a division program 13d and an information acquisition program 13e in addition to the extraction program 13a, the contour specifying program 13b, and the CG synthesis control program 13c. I remember it.

分割プログラム13dは、CPU12を分割手段として機能させるものである。即ち、分割プログラム13dは、モニタ表示用画像(記録用画像)I7を複数の画像領域B、…に分割する分割処理に係る機能をCPU12に実現させるためのプログラムである。
具体的には、CPU12による分割プログラム13dの実行に基づいて、モニタ表示用画像(記録用画像)I7の輝度信号Y(図14(a)参照)を複数の画像領域B、…(例えば、縦「YS」×横「XS」が6×8の48領域)に分割する。
The dividing program 13d causes the CPU 12 to function as a dividing unit. That is, the division program 13d is a program for causing the CPU 12 to realize a function related to the division processing for dividing the monitor display image (recording image) I7 into a plurality of image regions B,.
Specifically, based on the execution of the division program 13d by the CPU 12, the luminance signal Y (see FIG. 14A) of the monitor display image (recording image) I7 is converted into a plurality of image regions B,. “YS” × horizontal “XS” is divided into 48 regions of 6 × 8).

情報取得プログラム13eは、CPU12を情報取得手段として機能させるものである。即ち、情報取得プログラム13eは、分割処理によって分割された夫々の画像領域Bについて、周波数成分情報を取得する情報取得処理に係る機能をCPU12に実現させるためのプログラムである。
具体的には、CPU12による情報取得プログラム13eの実行に基づいて、分割処理によって分割された複数の画像領域B、…(例えば、48領域)の夫々について、2次元フーリエ変換を行って絶対値をとることにより周波数振幅情報を取得する。
The information acquisition program 13e causes the CPU 12 to function as information acquisition means. That is, the information acquisition program 13e is a program for causing the CPU 12 to realize a function related to the information acquisition process for acquiring the frequency component information for each image region B divided by the division process.
Specifically, based on the execution of the information acquisition program 13e by the CPU 12, a two-dimensional Fourier transform is performed on each of a plurality of image areas B,. The frequency amplitude information is acquired by taking this.

次に、CG合成座標計算処理について、図12〜図15を参照して説明する。
図12は、CG合成座標計算処理に係る動作の一例を示すフローチャートである。また、図13は、CG合成座標計算処理に係る複数の画像領域B、…の振幅値のソート結果を示す図である。また、図14(a)及び図14(b)並びに図15(a)〜図15(c)は、CG合成座標計算処理を説明するための画像を模式的に示す図である。
Next, CG composite coordinate calculation processing will be described with reference to FIGS.
FIG. 12 is a flowchart illustrating an example of an operation related to the CG composite coordinate calculation process. FIG. 13 is a diagram illustrating the sorting result of the amplitude values of the plurality of image regions B,... According to the CG composite coordinate calculation process. FIGS. 14A and 14B and FIGS. 15A to 15C are diagrams schematically showing images for explaining the CG composite coordinate calculation processing.

CG合成座標計算処理にあっては、図12に示すように、CPU12は、フラッシュメモリ13内の分割プログラム13dを実行して、横方向の分割数「XS」=8、縦方向の分割数「YS」=6として、モニタ表示用画像(記録用画像)I7の輝度信号Y(図14(a)参照)を複数の画像領域B、…(例えば、48領域)に分割する(ステップS201;図14(b)参照)。
これにより、複数の画像領域B、…の各々について、横方向のサイズ(XStep)が輝度信号Yの横方向のサイズ(XSize)を「XS」で除算した値となり、縦方向のサイズ(YStep)が輝度信号Yの縦方向のサイズ(YSize)を「YS」で除算した値となる(ステップS202)。例えば、輝度信号Yの画像サイズが横方向400ドット、縦方向264ドットの場合、各画像領域BのXStepは50(400÷8)ドットとなり、YStepは44(264÷6)ドットとなる。
In the CG composite coordinate calculation process, as shown in FIG. 12, the CPU 12 executes the division program 13 d in the flash memory 13 to obtain the horizontal division number “XS” = 8 and the vertical division number “ Assuming that “YS” = 6, the luminance signal Y (see FIG. 14A) of the monitor display image (recording image) I7 is divided into a plurality of image areas B,... (For example, 48 areas) (step S201; FIG. 14 (b)).
Thus, for each of the plurality of image regions B,..., The horizontal size (XStep) becomes a value obtained by dividing the horizontal size (XSize) of the luminance signal Y by “XS”, and the vertical size (YStep). Is a value obtained by dividing the vertical size (YSize) of the luminance signal Y by “YS” (step S202). For example, when the image size of the luminance signal Y is 400 dots in the horizontal direction and 264 dots in the vertical direction, the XStep of each image region B is 50 (400 ÷ 8) dots and the YStep is 44 (264 ÷ 6) dots.

次に、全ての画像領域Bについて周波数振幅情報を取得する情報取得処理を行う。
なお、横方向にx、縦方向にyのインデックスを用いて、複数の画像領域B、…のうち、左上隅の領域をx=1,y=1とし、右下隅の領域をx=XS,y=YSとする。
Next, an information acquisition process for acquiring frequency amplitude information for all image regions B is performed.
Of the plurality of image regions B,..., X = 1, y = 1, and the lower right corner region are x = XS, y using the index of x in the horizontal direction and y in the vertical direction. Let y = YS.

先ず、CPU12は、フラッシュメモリ13内の情報取得プログラム13eを実行して、ループ変数yを1に設定した後(ステップS203)、yの値と縦方向の分割数「YS」を比較して、yの値が縦方向の分割数「YS」よりも大きいか否かを判定する(ステップS204)。   First, after executing the information acquisition program 13e in the flash memory 13 and setting the loop variable y to 1 (step S203), the CPU 12 compares the value of y with the number of vertical divisions “YS”. It is determined whether or not the value of y is larger than the vertical division number “YS” (step S204).

ステップS204にて、yの値が縦方向の分割数「YS」以下であると判定されると(ステップS204;NO)、CPU12は、ループ変数xを1に設定した後(ステップS205)、xの値と横方向の分割数「XS」を比較して、xの値が横方向の分割数「XS」よりも大きいか否かを判定する(ステップS206)。
ここで、xの値が横方向の分割数「XS」以下であると判定されると(ステップS206;NO)、CPU12は、複数の領域のうち、x=1,y=1の画像領域BをI{x,y}に格納する(ステップS207)。
If it is determined in step S204 that the value of y is less than or equal to the vertical division number “YS” (step S204; NO), the CPU 12 sets the loop variable x to 1 (step S205), and then x And the horizontal division number “XS” are compared to determine whether the x value is larger than the horizontal division number “XS” (step S206).
Here, if it is determined that the value of x is equal to or smaller than the horizontal division number “XS” (step S206; NO), the CPU 12 sets the image area B where x = 1 and y = 1 among the plurality of areas. Is stored in I {x, y} (step S207).

続けて、CPU12は、I{x,y}に対して2次元フーリエ変換を行って振幅情報と位相情報を含んだ周波数成分情報を取得した後、絶対値をとることにより周波数振幅情報を算出してFFT_I{x,y}に格納する(ステップS208)。
ここで、各画像領域Bについて、周波数振幅情報の原点を中央に移動したものを図15(a)に図示しており、周辺部が白ければ白い程高周波成分が多いことを表している。
そして、CPU12は、FFT_I{x,y}に格納されている周波数振幅情報のうち、最大周波数の1/K(例えば、K=2)倍以上のものを積算して、FFT_IS{x,y}とする(ステップS209)。
その後、CPU12は、ループ変数xを+1インクリメント(x=x+1)して(ステップS210)、ステップS206に移行する。
Subsequently, the CPU 12 obtains frequency component information including amplitude information and phase information by performing a two-dimensional Fourier transform on I {x, y}, and then calculates frequency amplitude information by taking an absolute value. And stored in FFT_I {x, y} (step S208).
Here, for each image area B, the origin of the frequency amplitude information moved to the center is shown in FIG. 15A, and the whiter the peripheral part is, the higher the frequency component is.
Then, the CPU 12 accumulates frequency amplitude information stored in FFT_I {x, y} that is 1 / K (for example, K = 2) times or more of the maximum frequency, and FFT_IS {x, y}. (Step S209).
Thereafter, the CPU 12 increments the loop variable x by +1 (x = x + 1) (step S210), and proceeds to step S206.

そして、ステップS206にて、xの値が横方向の分割数「XS」よりも大きいと判定されるまで(ステップS206;YES)、ステップS206〜S210の処理を繰り返し実行する。
xの値が横方向の分割数「XS」よりも大きいと判定されると(ステップS206;YES)、CPU12は、ループ変数yを+1インクリメント(y=y+1)して(ステップS211)、ステップS204に移行する。
Then, until it is determined in step S206 that the value of x is larger than the horizontal division number “XS” (step S206; YES), the processes of steps S206 to S210 are repeatedly executed.
If it is determined that the value of x is larger than the horizontal division number “XS” (step S206; YES), the CPU 12 increments the loop variable y by +1 (y = y + 1) (step S211), and step S204. Migrate to

そして、ステップS204にて、yの値が縦方向の分割数「YS」よりも大きいと判定されるまで(ステップS204;YES)、ステップS204〜S210の処理を繰り返し実行する。
yの値が縦方向の分割数「YS」よりも大きいと判定されると(ステップS204;YES)、CPU12は、高周波成分が多いところを撮影対象、それ以外を背景領域A2とするための判定を行う。
Then, until it is determined in step S204 that the value of y is larger than the vertical division number “YS” (step S204; YES), the processes in steps S204 to S210 are repeatedly executed.
If it is determined that the value of y is larger than the number of divisions “YS” in the vertical direction (step S204; YES), the CPU 12 makes a determination for setting a portion with a high frequency component as a subject to be photographed and the other as a background region A2. I do.

先ず、CPU12は、複数の画像領域B、…について、離散点からFFT後に得られる最大周波数の1/R(例えば、R=4)以上の周期となる高周波成分の振幅値(例えば、X周期;4/XStep、Y周期;4/YStep)を加算して、FFT_IS{x,y}に代入する(ステップS212)。これにより、FFT_IS{x,y}には、低い周波数を除去した高周波成分の振幅値が代入されることとなり、FFT_IS{x,y}の値が大きければ大きい程、その画像領域Bの空間周波数は高いことになる。
続けて、CPU12は、複数の画像領域B、…に係る全てのFFT_IS{x,y}をソートして、振幅値が急峻に変化している点を閾値THとする(ステップS213)。例えば、図13に示すように、横方向の分割数「XS」=8とし、縦方向の分割数「YS」=6とする48の画像領域Bの振幅値をソートした場合、100000を境にして振幅値が急峻に変化していることから、閾値THを100000とする。
First, for a plurality of image regions B,..., The amplitude value (for example, X period; for example) of a high frequency component having a period of 1 / R (for example, R = 4) or more of the maximum frequency obtained after FFT from discrete points 4 / XStep, Y cycle; 4 / YStep) is added and substituted into FFT_IS {x, y} (step S212). As a result, the amplitude value of the high frequency component from which the low frequency is removed is substituted for FFT_IS {x, y}. The larger the value of FFT_IS {x, y}, the larger the spatial frequency of the image region B. Will be expensive.
Subsequently, the CPU 12 sorts all the FFT_IS {x, y} relating to the plurality of image regions B,..., And sets the threshold value TH as a point where the amplitude value changes sharply (step S213). For example, as shown in FIG. 13, when the amplitude values of 48 image regions B in which the horizontal division number “XS” = 8 and the vertical division number “YS” = 6 are sorted, 100000 is the boundary. Therefore, the threshold value TH is set to 100,000.

次に、CPU12は、複数の画像領域B、…について、当該画像領域Bに係る全てのFFT_IS{x,y}と閾値THを比較して、当該閾値THよりも小さいFFT_IS{x,y}の画像領域Bを背景領域A2とし、それ以外を主要被写体S(撮影対象)とする(ステップS214)。
このようにして、CPU12は、位置特定手段として、周波数成分情報に基づいて、高周波成分が所定値よりも多い画像領域Bを主要被写体Sに対応する主要画像領域A1(第1の画像領域)を構成する画像領域と判断する(図15(b)参照)。
なお、図15(b)には、背景領域A2を構成する画像領域Bが黒く塗りつぶされたものを表しており、それ以外の画像領域Bは、主要画像領域A1に対応している。
Next, the CPU 12 compares the threshold TH with all the FFT_IS {x, y} related to the image area B for a plurality of image areas B,... And the FFT_IS {x, y} smaller than the threshold TH. The image area B is set as the background area A2, and the other area is set as the main subject S (photographing target) (step S214).
In this way, the CPU 12 determines, as the position specifying means, the main image area A1 (first image area) corresponding to the main subject S from the image area B having a high frequency component larger than the predetermined value based on the frequency component information. It is determined that the image area is to be configured (see FIG. 15B).
In FIG. 15B, the image area B constituting the background area A2 is shown in black, and the other image areas B correspond to the main image area A1.

次に、CPU12は、上記実施形態の撮像装置100におけるステップS27〜S29と略同様の処理を行って、背景領域A2におけるCG合成座標を算出する。具体的には、先ず、予めユーザによる操作入力部4の所定操作に基づいて指定されたCG画像50の合成位置に応じて分岐する(ステップS215)。
ここで、CG画像50の合成位置が主要被写体Sの左側に指定されている場合には、画像I8の左端から右側に向けて走査して、背景領域A2内でできる限り右側にCG画像50を合成できるようにCG合成座標を算出し(ステップS216)、一方、CG画像50の合成位置が主要被写体Sの右側に指定されている場合には、画像I8の右端から左側に向けて走査して、背景領域A2内でできる限り左側にCG画像50を合成できるようにCG合成座標を算出する(ステップS217:図15(c)参照)。
なお、図15(c)にあっては、CG合成座標を破線で囲まれた領域Cとして表している。
Next, the CPU 12 performs substantially the same processing as steps S27 to S29 in the imaging device 100 of the above embodiment, and calculates the CG composite coordinates in the background area A2. Specifically, first, branching is performed according to the combination position of the CG image 50 designated in advance based on a predetermined operation of the operation input unit 4 by the user (step S215).
Here, when the synthesis position of the CG image 50 is designated on the left side of the main subject S, scanning is performed from the left end of the image I8 toward the right side, and the CG image 50 is placed on the right side as much as possible in the background area A2. CG composite coordinates are calculated so that they can be combined (step S216). On the other hand, when the composite position of the CG image 50 is designated on the right side of the main subject S, scanning is performed from the right end of the image I8 toward the left side. Then, the CG synthesis coordinates are calculated so that the CG image 50 can be synthesized as far as possible in the background area A2 (step S217: see FIG. 15C).
In FIG. 15C, the CG composite coordinates are represented as a region C surrounded by a broken line.

その後、図3におけるステップS3A(或いは、図4におけるステップS4A)にて、CPU12がフラッシュメモリ13内のCG合成制御プログラム13cを実行して、画像エンジン8は、CG合成座標計算処理にて計算されたCG合成座標に基づいて、スルー画像(或いは、記録用画像)とCG画像50を合成してCG合成画像I9(図16参照)を生成し、続けて、ステップS4Aにて、当該CG合成画像I6を表示部3の表示画面3aに表示する(或いは、ステップS4Bにて、CG合成画像I9をフラッシュメモリ13に転送して記憶する)。   Thereafter, in step S3A in FIG. 3 (or step S4A in FIG. 4), the CPU 12 executes the CG synthesis control program 13c in the flash memory 13, and the image engine 8 is calculated by CG synthesis coordinate calculation processing. Based on the CG synthesized coordinates, the through image (or recording image) and the CG image 50 are synthesized to generate a CG synthesized image I9 (see FIG. 16), and then in step S4A, the CG synthesized image. I6 is displayed on the display screen 3a of the display unit 3 (or, in step S4B, the CG composite image I9 is transferred to the flash memory 13 and stored).

従って、変形例1の撮像装置200によれば、CG合成座標計算処理にて、モニタ表示用画像や記録用画像を複数の画像領域B、…に分割して、夫々の画像領域Bについて、周波数成分情報を取得して、当該周波数成分情報に基づいて、高周波成分が所定値よりも多い画像領域Bを主要画像領域A1を構成する画像領域と判断するので、ノイズに影響されることなく、一の被写体画像から主要被写体Sが含まれる画像領域を判別することができる。   Therefore, according to the imaging apparatus 200 of Modification 1, the monitor display image and the recording image are divided into a plurality of image areas B,... Component information is acquired, and based on the frequency component information, an image region B having a high frequency component larger than a predetermined value is determined as an image region constituting the main image region A1, so that it is not affected by noise. The image area including the main subject S can be determined from the subject images.

<変形例2>
変形例2の撮像装置は、図17(a)及び図17(b)並びに図18(a)及び図18(b)に示すように、モニタ表示用画像I10の背景領域A2内でCG画像50を合成する位置をユーザによる操作入力部4の所定操作に基づいて入力して、入力された合成位置にCG画像50を合成する。
なお、変形例2の撮像装置は、以下に説明するCG合成位置決定処理以外の点で上記変形例1の撮像装置200と略同様の構成をなし、その説明は省略する。
<Modification 2>
As shown in FIGS. 17 (a), 17 (b), 18 (a), and 18 (b), the imaging apparatus according to the second modification includes a CG image 50 in the background area A2 of the monitor display image I10. Is input based on a predetermined operation of the operation input unit 4 by the user, and the CG image 50 is combined with the input combining position.
Note that the imaging apparatus of Modification 2 has substantially the same configuration as that of the imaging apparatus 200 of Modification 1 except for the CG composite position determination process described below, and a description thereof will be omitted.

カーソルキー4bは、合成位置入力手段として、被写体画像に対するCG画像50の合成位置を指示入力する。
そして、CPU12は、ユーザによるカーソルキー4bの操作に応じて入力された所定の操作信号に基づいて、モニタ表示用画像I10におけるCG画像50の合成位置を決定するCG合成位置決定処理を行う。
具体的には、ユーザにより左カーソルキー(右カーソルキー)4bが操作される毎に、CPU12は、モニタ表示用画像I10におけるCG画像50の合成位置を決定していき、モニタ表示用画像I10の背景領域A2(図17(a)及び図18(a)参照)内でCG画像50が主要被写体Sに対して左回りに(右回りに)移動する。そして、表示部3の表示画面3aには、CG合成位置決定処理にて設定されたCG画像50の合成位置に基づいて、画像エンジン8によりCG画像50がモニタ表示用画像I10に合成された合成イメージI11(図17(b)及び図18(b)参照)が表示されることとなる。
このように、CPU12は、CG画像50の合成位置を決定する合成位置決定手段として機能する。
The cursor key 4b, as a composite position input means, inputs an instruction for the composite position of the CG image 50 with respect to the subject image.
Then, the CPU 12 performs CG combination position determination processing for determining the combination position of the CG image 50 in the monitor display image I10 based on a predetermined operation signal input in response to the operation of the cursor key 4b by the user.
Specifically, every time the left cursor key (right cursor key) 4b is operated by the user, the CPU 12 determines the synthesis position of the CG image 50 in the monitor display image I10, and the monitor display image I10 The CG image 50 moves counterclockwise (clockwise) with respect to the main subject S in the background area A2 (see FIGS. 17A and 18A). Then, on the display screen 3a of the display unit 3, the CG image 50 is synthesized with the monitor display image I10 by the image engine 8 based on the synthesis position of the CG image 50 set in the CG synthesis position determination process. The image I11 (see FIGS. 17B and 18B) is displayed.
As described above, the CPU 12 functions as a composite position determination unit that determines the composite position of the CG image 50.

なお、CG画像50は、左カーソルキー(右カーソルキー)4bの操作回数に応じて移動するようにしても良いし、押圧操作している時間だけ移動するようにしても良い。   The CG image 50 may be moved according to the number of operations of the left cursor key (right cursor key) 4b, or may be moved only for the time during which the pressing operation is performed.

従って、変形例2の撮像装置によれば、モニタ表示用画像I10の背景領域A2内でCG画像50を合成する位置をユーザによる操作入力部4の所定操作に基づいて入力して、入力された合成位置にCG画像50を合成するので、CG画像50をモニタ表示画像における任意の位置に合成することができ、ユーザ所望のCG合成画像I11を得ることができる。   Therefore, according to the imaging apparatus of the second modification, the position where the CG image 50 is synthesized within the background area A2 of the monitor display image I10 is input based on a predetermined operation of the operation input unit 4 by the user. Since the CG image 50 is synthesized at the synthesis position, the CG image 50 can be synthesized at an arbitrary position in the monitor display image, and a CG composite image I11 desired by the user can be obtained.

<変形例3>
変形例3の撮像装置は、図19(a)及び図19(b)に示すように、被写体画像I12の背景領域A2内で主要被写体Sの周囲の領域の大きさに基づいて、CG画像50の合成位置を自動的に設定する。
具体的には、CPU12は、被写体画像I12の背景領域A2内で主要被写体Sの周囲(例えば、上側、左側、右側等)の領域の大きさを判定して、最も大きい領域内にCG画像50の合成位置を設定する。例えば、CPU12は、主要被写体Sから上側縁までの距離D1、左側縁までの距離D2、右側縁までの距離D3を算出して(図19(a)参照)、最も長い距離D3を有する右側領域をCG画像50が合成される領域として指定する(図19(b)参照)。
<Modification 3>
As shown in FIGS. 19A and 19B, the imaging apparatus according to the third modification has a CG image 50 based on the size of the area around the main subject S in the background area A2 of the subject image I12. The composite position of is automatically set.
Specifically, the CPU 12 determines the size of the area around the main subject S (for example, the upper side, the left side, and the right side) in the background area A2 of the subject image I12, and the CG image 50 in the largest area. Set the composite position. For example, the CPU 12 calculates the distance D1 from the main subject S to the upper edge, the distance D2 to the left edge, and the distance D3 to the right edge (see FIG. 19A), and the right area having the longest distance D3. Is designated as an area where the CG image 50 is synthesized (see FIG. 19B).

従って、変形例3の撮像装置によれば、被写体画像I12の背景領域A2内で主要被写体Sの周囲の領域の大きさに基づいて、CG画像50の合成位置を自動的に設定するので、ユーザが操作入力部4等を所定操作することなく、背景領域A2内の適正な位置にCG画像50を合成することができる。   Therefore, according to the imaging apparatus of the third modification, since the synthesis position of the CG image 50 is automatically set based on the size of the area around the main subject S in the background area A2 of the subject image I12, the user However, the CG image 50 can be synthesized at an appropriate position in the background area A2 without performing a predetermined operation on the operation input unit 4 or the like.

なお、上記実施形態にあっては、被写体画像に対する所定の加工処理としてCG合成処理を例示したが、これに限られるものではなく、被写体画像における主要画像領域以外の背景領域に対する加工処理であれば如何なるものであっても良い。   In the above embodiment, the CG composition processing is exemplified as the predetermined processing for the subject image. However, the present invention is not limited to this, and any processing processing for the background region other than the main image region in the subject image may be used. It can be anything.

また、上記実施形態にあっては、主要画像領域A1の位置を特定する処理として、被写体画像を構成する画素集合の輪郭線を抽出して、抽出された輪郭線のうちの所定値よりも小さい画素集合の輪郭線を除くことにより、主要被写体Sの外周輪郭を特定するようにしたが、処理内容は一例であって、これに限られるものではない。   In the above embodiment, as a process for specifying the position of the main image region A1, the contour line of the pixel set constituting the subject image is extracted, and is smaller than a predetermined value of the extracted contour lines. The outer contour of the main subject S is specified by removing the contour line of the pixel set. However, the processing content is an example, and the present invention is not limited to this.

さらに、素材画像として、CG画像50を例示したが、これに限られるものではなく、被写体画像に合成可能なものであれば如何なるものであっても良い。例えば、図示は省略するが、予め撮影しておいた人物や動物の画像などであっても良い。   Furthermore, although the CG image 50 is illustrated as the material image, the present invention is not limited to this, and any material image can be used as long as it can be combined with the subject image. For example, although illustration is omitted, it may be an image of a person or an animal photographed in advance.

また、撮像装置100、200の構成は、上記実施形態に例示したものは一例であり、これに限られるものではない。
さらに、上記実施形態にあっては、位置特定手段、加工処理手段、抽出手段、輪郭線特定手段、分割手段、情報取得手段、合成位置決定手段としての機能を、CPU12によって所定のプログラム等が実行されることにより実現される構成としたが、これに限られるものではなく、例えば、各種機能を実現するためのロジック回路等から構成しても良い。
Further, the configurations of the imaging apparatuses 100 and 200 are merely examples as illustrated in the above-described embodiment, and are not limited thereto.
Furthermore, in the above embodiment, the CPU 12 executes a function as a position specifying unit, a processing unit, an extracting unit, an outline specifying unit, a dividing unit, an information acquiring unit, and a composite position determining unit by a predetermined program or the like. However, the present invention is not limited to this. For example, a configuration including a logic circuit for realizing various functions may be used.

加えて、画像合成装置として撮像装置100、200を例示したが、これに限られるものではなく、撮像部1により生成した複数の画像データをUSB接続端子5を介して接続されたコンピュータ等の外部機器に出力して、当該外部機器にて位置特定処理、CG合成処理、抽出処理、輪郭線特定処理、分割処理、情報取得処理、合成位置決定処理等を行うようにしても良い。   In addition, the image capturing apparatuses 100 and 200 are illustrated as the image synthesizing apparatus. However, the present invention is not limited to this, and an external device such as a computer connected with the plurality of image data generated by the image capturing unit 1 via the USB connection terminal 5 is not limited thereto. The information may be output to a device, and the external device may perform position specifying processing, CG combining processing, extraction processing, contour specifying processing, division processing, information acquisition processing, combining position determination processing, and the like.

本発明を適用した一実施形態の撮像装置の外観を模式的に示す図である。1 is a diagram schematically illustrating an appearance of an imaging apparatus according to an embodiment to which the present invention is applied. 図1の撮像装置の概略構成を示すブロック図である。It is a block diagram which shows schematic structure of the imaging device of FIG. 図1の撮像装置による表示画像CG合成処理に係る動作の一例を示すフローチャートである。3 is a flowchart illustrating an example of an operation related to a display image CG composition process by the imaging apparatus of FIG. 1. 図1の撮像装置による撮像画像CG合成処理に係る動作の一例を示すフローチャートである。3 is a flowchart illustrating an example of an operation related to a captured image CG synthesis process performed by the imaging apparatus of FIG. 1. 図1の撮像装置によるCG合成座標計算処理に係る動作の一例を示すフローチャートである。3 is a flowchart illustrating an example of an operation related to a CG composite coordinate calculation process by the imaging apparatus of FIG. 1. 図5のCG合成座標計算処理における小領域削除処理に係る動作の一例を示すフローチャートである。It is a flowchart which shows an example of the operation | movement which concerns on the small area deletion process in the CG synthetic | combination coordinate calculation process of FIG. 図5のCG合成座標計算処理における背景抽出処理に係る動作の一例を示すフローチャートである。It is a flowchart which shows an example of the operation | movement which concerns on the background extraction process in the CG synthetic | combination coordinate calculation process of FIG. 図5のCG合成座標計算処理を説明するための画像を模式的に示す図である。It is a figure which shows typically the image for demonstrating the CG synthetic | combination coordinate calculation process of FIG. 図5のCG合成座標計算処理を説明するための画像を模式的に示す図である。It is a figure which shows typically the image for demonstrating the CG synthetic | combination coordinate calculation process of FIG. 図1の撮像装置によるCG画像の合成処理後の画像を模式的に示す図である。It is a figure which shows typically the image after the synthesis process of the CG image by the imaging device of FIG. 変形例1の撮像装置の概略構成を示すブロック図である。It is a block diagram which shows schematic structure of the imaging device of the modification 1. 図11の撮像装置によるCG合成座標計算処理に係る動作の一例を示すフローチャートである。12 is a flowchart illustrating an example of an operation related to a CG composite coordinate calculation process by the imaging apparatus of FIG. 11. 図12のCG合成座標計算処理に係る複数の画像領域の振幅値のソート結果を示す図である。It is a figure which shows the sorting result of the amplitude value of the several image area which concerns on the CG synthetic | combination coordinate calculation process of FIG. 図12のCG合成座標計算処理を説明するための画像を模式的に示す図である。It is a figure which shows typically the image for demonstrating the CG synthetic | combination coordinate calculation process of FIG. 図12のCG合成座標計算処理を説明するための画像を模式的に示す図である。It is a figure which shows typically the image for demonstrating the CG synthetic | combination coordinate calculation process of FIG. 図11の撮像装置によるCG画像の合成処理後の画像を模式的に示す図である。It is a figure which shows typically the image after the synthesis process of the CG image by the imaging device of FIG. 変形例2の撮像装置によるCG合成処理に係る画像を模式的に示す図である。FIG. 10 is a diagram schematically illustrating an image related to CG synthesis processing by an imaging apparatus according to Modification 2. 図17の撮像装置によるCG合成処理に係る画像を模式的に示す図である。It is a figure which shows typically the image which concerns on CG synthetic | combination processing by the imaging device of FIG. 変形例3の撮像装置によるCG合成処理に係る画像を模式的に示す図である。FIG. 10 is a diagram schematically showing an image related to CG composition processing by an imaging apparatus according to Modification 3.

符号の説明Explanation of symbols

100 撮像装置
1 撮像部
4 操作入力部
4b カーソルキー
8 画像エンジン
12 CPU
13 フラッシュメモリ
50 CG画像
I6、I9、I11 CG合成画像
DESCRIPTION OF SYMBOLS 100 Imaging device 1 Imaging part 4 Operation input part 4b Cursor key 8 Image engine 12 CPU
13 Flash memory 50 CG image I6, I9, I11 CG composite image

Claims (5)

素材画像を記憶する素材画像記憶手段と、
一の被写体画像に含まれる主要被写体に対応する第1の画像領域の位置を特定する位置特定手段と、
前記位置特定手段により特定された前記一の被写体画像の前記第1の画像領域の位置以外の第2の画像領域における前記素材画像の合成位置を、外部操作を検出することにより入力する合成位置入力手段と、
この合成位置入力手段によって入力された合成位置よりも前記位置特定手段によって特定された第1の画像領域の位置に近づくような合成位置を取得し、この取得された合成位置に前記素材画像記憶手段に記憶されている前記素材画像を合成する処理を行う合成処理手段と、
を備えることを特徴とする画像処理装置。
Material image storage means for storing material images;
Position specifying means for specifying the position of the first image area corresponding to the main subject included in one subject image;
A composite position input for inputting a composite position of the material image in a second image area other than the position of the first image area of the one subject image specified by the position specifying means by detecting an external operation Means,
A composite position that is closer to the position of the first image area specified by the position specifying means than the composite position input by the composite position input means is acquired, and the material image storage means is acquired at the acquired composite position. Combining processing means for performing processing for combining the material images stored in
An image processing apparatus comprising:
前記被写体画像を構成する画素集合の輪郭線を抽出する抽出手段と、
この抽出手段によって抽出された輪郭線のうちの所定値よりも小さい画素集合の輪郭線を除くことにより、前記主要被写体を描画した主要輪郭線を特定する輪郭線特定手段と、
を更に備え、
前記位置特定手段は、
前記輪郭線特定手段によって特定された前記主要輪郭線で囲まれた画像領域の位置を、前記主要画像領域の位置として特定することを特徴とする請求項1に記載の画像処理装置。
Extracting means for extracting a contour line of a pixel group constituting the subject image;
An outline specifying means for specifying a main outline on which the main subject is drawn by excluding an outline of a pixel set smaller than a predetermined value from the outline extracted by the extracting means;
Further comprising
The position specifying means includes
The image processing apparatus according to claim 1 , wherein the position of the image area surrounded by the main outline specified by the outline specifying unit is specified as the position of the main image area .
前記一の被写体画像を複数の領域に分割する分割手段と、
この分割手段によって分割された夫々の領域について、周波数成分情報を取得する情報取得手段と、
を更に備え、
前記位置特定手段は、
前記情報取得手段によって取得された前記周波数成分情報に基づいて、高周波成分が所定値よりも多い領域を前記第1の画像領域を構成する画像領域と判断することを特徴とする請求項に記載の画像処理装置。
Dividing means for dividing the one subject image into a plurality of regions;
Information acquisition means for acquiring frequency component information for each region divided by the dividing means;
Further comprising
The position specifying means includes
Based on the frequency component information acquired by the information acquiring unit, according to claim 1 in which the high-frequency component is characterized in that it is determined that the image areas constituting the first image region more area than a predetermined value Image processing apparatus.
前記被写体画像を撮像する撮像手段を更に備えることを特徴とする請求項1乃至3の何れかに記載の画像処理装置。 The image processing apparatus according to claim 1 , further comprising an imaging unit that captures the subject image . コンピュータを、Computer
一の被写体画像に含まれる主要被写体に対応する第1の画像領域の位置を特定する位置特定手段、Position specifying means for specifying the position of the first image area corresponding to the main subject included in one subject image;
前記位置特定手段により特定された前記一の被写体画像の前記第1の画像領域の位置以外の第2の画像領域における素材画像の合成位置を、外部操作を検出することにより入力する合成位置入力手段、  Composite position input means for inputting the composite position of the material image in the second image area other than the position of the first image area of the one subject image specified by the position specifying means by detecting an external operation. ,
この合成位置入力手段によって入力された合成位置よりも前記位置特定手段によって特定された第1の画像領域の位置に近づくような合成位置を取得し、この取得された合成位置に前記素材画像を合成する処理を行う合成処理手段、  A composite position that is closer to the position of the first image area specified by the position specifying means than the composite position input by the composite position input means is acquired, and the material image is combined with the acquired composite position. Synthesis processing means for performing processing,
として機能させることを特徴とするプログラム。A program characterized by functioning as
JP2008185854A 2008-07-17 2008-07-17 Image processing apparatus and program Expired - Fee Related JP5092958B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008185854A JP5092958B2 (en) 2008-07-17 2008-07-17 Image processing apparatus and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008185854A JP5092958B2 (en) 2008-07-17 2008-07-17 Image processing apparatus and program

Publications (3)

Publication Number Publication Date
JP2010028346A JP2010028346A (en) 2010-02-04
JP2010028346A5 JP2010028346A5 (en) 2011-08-25
JP5092958B2 true JP5092958B2 (en) 2012-12-05

Family

ID=41733776

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008185854A Expired - Fee Related JP5092958B2 (en) 2008-07-17 2008-07-17 Image processing apparatus and program

Country Status (1)

Country Link
JP (1) JP5092958B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5605289B2 (en) * 2011-04-05 2014-10-15 トヨタ自動車株式会社 Fault recognition method and fault recognition system for moving body

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4161769B2 (en) * 2003-03-31 2008-10-08 カシオ計算機株式会社 Image output device, image output method, image output processing program, image distribution server, and image distribution processing program
JP2006128754A (en) * 2004-10-26 2006-05-18 Matsushita Electric Ind Co Ltd Imaging apparatus and imaging method
JP2007036312A (en) * 2005-07-22 2007-02-08 Kowa Co Digital camera and program for the digital camera
JP4645413B2 (en) * 2005-11-01 2011-03-09 株式会社ニコン Imaging device
JP2006081224A (en) * 2005-12-02 2006-03-23 Casio Comput Co Ltd Electronic still camera and image processing method
JP4867428B2 (en) * 2006-03-30 2012-02-01 カシオ計算機株式会社 Imaging apparatus, imaging method, and program
JP2008124830A (en) * 2006-11-13 2008-05-29 Funai Electric Co Ltd Imaging apparatus

Also Published As

Publication number Publication date
JP2010028346A (en) 2010-02-04

Similar Documents

Publication Publication Date Title
JP5105550B2 (en) Image composition apparatus and program
US8472747B2 (en) Image composition device, image composition method, and storage medium storing program
WO2016008359A1 (en) Object movement track image synthesizing method, device and computer storage medium
JP6011569B2 (en) Imaging apparatus, subject tracking method, and program
JP4868046B2 (en) Image processing apparatus, image processing method, and program
JP2010239447A (en) Image capturing apparatus, image processing method, and program
JP2009111716A (en) Imaging apparatus, program and template generating method
JP2016178608A (en) Image processing apparatus, image processing method and program
JP5504990B2 (en) Imaging apparatus, image processing apparatus, and program
KR20110034958A (en) Digital photographing apparatus and method
JP5509621B2 (en) Image processing apparatus, camera, and program
JP2011066827A (en) Image processing apparatus, image processing method and program
JP5267279B2 (en) Image composition apparatus and program
JP5092958B2 (en) Image processing apparatus and program
JP2009009206A (en) Extraction method of outline inside image and image processor therefor
JP2019191661A (en) Image processing apparatus, imaging device, image processing method, and program
JP2006128793A (en) Image pickup device and control method thereof
JP2010154390A (en) Imaging device, imaging method, and program
KR101905813B1 (en) Device for comparing image files
JP2011182014A (en) Image pickup device, image processing method and program
JP2010016693A (en) Electronic camera
JP5636660B2 (en) Image processing apparatus, image processing method, and program
JP2016129281A (en) Image processor
JP6776532B2 (en) Image processing equipment, imaging equipment, electronic devices and image processing programs
JP7476361B2 (en) Information processing device, imaging device, information processing method, and program

Legal Events

Date Code Title Description
A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20110712

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20110712

RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20110712

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20120514

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120522

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120723

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: 20120821

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: 20120903

R150 Certificate of patent or registration of utility model

Ref document number: 5092958

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20150928

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees