JP6485629B2 - Image processing apparatus and image processing method - Google Patents

Image processing apparatus and image processing method Download PDF

Info

Publication number
JP6485629B2
JP6485629B2 JP2015015361A JP2015015361A JP6485629B2 JP 6485629 B2 JP6485629 B2 JP 6485629B2 JP 2015015361 A JP2015015361 A JP 2015015361A JP 2015015361 A JP2015015361 A JP 2015015361A JP 6485629 B2 JP6485629 B2 JP 6485629B2
Authority
JP
Japan
Prior art keywords
face
makeup
image
screen
makeup image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2015015361A
Other languages
Japanese (ja)
Other versions
JP2016139381A (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.)
Panasonic Intellectual Property Management Co Ltd
Original Assignee
Panasonic Intellectual Property Management 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 Panasonic Intellectual Property Management Co Ltd filed Critical Panasonic Intellectual Property Management Co Ltd
Priority to JP2015015361A priority Critical patent/JP6485629B2/en
Priority to PCT/JP2016/000234 priority patent/WO2016121329A1/en
Priority to CN201680004714.7A priority patent/CN107111861B/en
Priority to US15/003,183 priority patent/US9984281B2/en
Publication of JP2016139381A publication Critical patent/JP2016139381A/en
Application granted granted Critical
Publication of JP6485629B2 publication Critical patent/JP6485629B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Studio Devices (AREA)
  • User Interface Of Digital Computer (AREA)

Description

本発明は、画像処理装置および画像処理方法に係り、特に、顔の撮影映像に化粧画像を重畳する画像処理装置および画像処理方法に関する。   The present invention relates to an image processing apparatus and an image processing method, and more particularly, to an image processing apparatus and an image processing method for superimposing a makeup image on a photographed face image.

従来、顔を撮影した画像に頬紅等の化粧画像を重畳して仮想的に化粧を行うバーチャル化粧の技術が存在する。かかる技術により、実際に顔に化粧を施すことなく、化粧を施したときの顔の画像を生成して表示することができる。   2. Description of the Related Art Conventionally, there is a virtual makeup technique in which makeup is virtually performed by superimposing a makeup image such as blusher on a face image. With this technique, it is possible to generate and display an image of a face when makeup is applied without actually applying makeup on the face.

ところで、近年、スマートフォン等を用いてユーザが自らを被写体として撮影する行為(自分撮り)が流行している。自分撮り画像の多くは、ソーシャルメディアで友人等の閲覧に供する目的で撮影される。撮影された自分撮り画像に対して、自分の顔を美しく見せる美顔処理を施すユーザも多い。その美顔処理の一つとして、バーチャル化粧があり、化粧効果を与えることが可能である。   By the way, in recent years, an action (self-portrait) in which a user takes a picture of himself as a subject using a smartphone or the like has become popular. Many self-portrait images are taken for the purpose of browsing by friends on social media. There are also many users who perform a beautiful face process on a photographed self-portrait image to make their face look beautiful. One of the facial treatments is virtual makeup, which can give a makeup effect.

画像の中から画像処理の対象となる顔領域を簡単に決定する技術は、例えば、特許文献1に記載されている。特許文献1に記載の技術(以下「従来技術」という)は、画像を画面に表示するとともに、画像に対して顔認識処理を行い、画面における顔領域を取得する。そして、従来技術は、画面に対するタッチ操作を受け付け、タッチ操作が行われた位置が取得された顔領域に含まれるとき、当該顔領域を画像処理の対象とする。   A technique for easily determining a face area to be subjected to image processing from an image is described in Patent Document 1, for example. The technique described in Patent Document 1 (hereinafter referred to as “conventional technique”) displays an image on a screen, performs face recognition processing on the image, and acquires a face area on the screen. The conventional technology receives a touch operation on the screen, and when the position where the touch operation is performed is included in the acquired face region, the face region is subjected to image processing.

このような従来技術を採用することにより、ユーザは、バーチャル化粧を施す対象を簡単に選択することができる。   By adopting such a conventional technique, the user can easily select an object to be subjected to virtual makeup.

特開2006−350967号公報JP 2006-350967 A

ところが、撮影後に、撮影された多数の自分撮り画像の中からバーチャル化粧の対象となる画像を探し出して選択するという作業は、時間と手間が掛かる。そこで、撮影中に、撮影映像に映し出されている顔に対してバーチャル化粧を施すことが考えられる。   However, it takes time and effort to search for and select an image to be subjected to virtual makeup from a large number of self-portraited images after shooting. Therefore, it is conceivable to apply virtual makeup to the face shown in the photographed image during photographing.

しかしながら、自分撮りは、通常、顔の見栄えを画面の映像で確認しながら行われるため、従来技術を用いて顔を選択しようとする場合、指が邪魔となる。したがって、自分撮りをしながらのバーチャル化粧操作を可能にする技術が望まれる。   However, since the self-taking is usually performed while checking the appearance of the face on the screen image, the finger becomes an obstacle when trying to select the face using the conventional technique. Therefore, a technology that enables virtual makeup operation while taking a selfie is desired.

本発明の目的は、自分撮りをしながらのバーチャル化粧操作を可能にする画像処理装置および画像処理方法を提供することである。   An object of the present invention is to provide an image processing apparatus and an image processing method that enable a virtual makeup operation while taking a selfie.

本開示の画像処理装置は、映像を撮影する撮影部と、撮影された前記映像を画面に表示する表示部と、前記映像に含まれる顔の前記画面における位置を取得する顔位置取得部と、前記画面に対するタッチ操作を受け付ける操作受付部と、前記映像の前記顔の部分に対して化粧画像を重畳する化粧画像重畳部と、を有し、前記化粧画像重畳部は、前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記化粧画像の重畳の状態を変更する。   An image processing apparatus of the present disclosure includes a photographing unit that captures a video, a display unit that displays the captured video on a screen, a face position acquisition unit that acquires a position of the face included in the video on the screen, An operation accepting unit that accepts a touch operation on the screen; and a makeup image superimposing unit that superimposes a makeup image on the face portion of the video, the makeup image superimposing unit heading toward the face position. On the condition that the swipe operation is performed in the direction, the superimposing state of the makeup image is changed.

本開示の画像処理方法は、映像を撮影するステップと、撮影された前記映像を画面に表示するステップと、前記映像に含まれる顔の前記画面における位置を取得するステップと、前記画面に対するタッチ操作を受け付けるステップと、前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記映像の前記顔の部分に対して化粧画像を重畳させるステップと、を有する。   The image processing method of the present disclosure includes a step of capturing a video, a step of displaying the captured video on a screen, a step of acquiring a position of the face included in the video on the screen, and a touch operation on the screen And a step of superimposing a makeup image on the face portion of the video on the condition that a swipe operation is performed in a direction toward the face position.

本開示によれば、自分撮りをしながらのバーチャル化粧操作を可能にする。   According to the present disclosure, it is possible to perform a virtual makeup operation while taking a selfie.

本実施の形態に係る画像処理装置の使用の様子の一例を示す図The figure which shows an example of the mode of use of the image processing apparatus which concerns on this Embodiment 本実施の形態に係る画像処理装置の構成の一例を示すブロック図1 is a block diagram showing an example of the configuration of an image processing apparatus according to the present embodiment 本実施の形態における化粧画像情報の内容の一例を示す図The figure which shows an example of the content of the makeup | decoration image information in this Embodiment 本実施の形態における状態記録テーブルの内容の一例を示す図The figure which shows an example of the content of the state recording table in this Embodiment 本実施の形態における化粧画像の重畳状態の変更の様子の一例を説明するための図The figure for demonstrating an example of the mode of a change of the superimposition state of a makeup image in this Embodiment 本実施の形態におけるタッチ操作の対象となる顔を決定する様子の一例を説明するための図The figure for demonstrating an example of a mode that the face used as the object of touch operation in this Embodiment is determined. 本実施の形態におけるタッチ操作の対象となる顔部品を決定する様子の一例を説明するための図The figure for demonstrating an example of a mode that the face component used as the object of touch operation in this Embodiment is determined. 本実施の形態における化粧設定の維持の判断の様子の一例を説明するための図The figure for demonstrating an example of the mode of judgment of the maintenance of makeup | decoration setting in this Embodiment 本実施の形態に係る画像処理装置の動作の一例を示すフローチャートA flowchart showing an example of the operation of the image processing apparatus according to the present embodiment 本実施の形態における相対位置解析処理の一例を示すフローチャートFlowchart showing an example of relative position analysis processing in the present embodiment

以下、本発明の一実施の形態について、図面を参照して詳細に説明する。   Hereinafter, an embodiment of the present invention will be described in detail with reference to the drawings.

<装置の使用の様子>
まず、本実施の形態に係る画像処理装置の使用の様子について説明する。
<How the device is used>
First, how the image processing apparatus according to the present embodiment is used will be described.

図1は、本実施の形態に係る画像処理装置の使用の様子の一例を示す図である。   FIG. 1 is a diagram illustrating an example of how the image processing apparatus according to the present embodiment is used.

図1に示すように、画像処理装置100は、例えば、スマートフォンである。画像処理装置100は、タッチパネル付き液晶ディスプレイと、当該ディスプレイと同じ側の面に配置された内側カメラおよび撮影ボタンを備えている(いずれも図示せず)。なお、撮影ボタンは、ディスプレイに表示されたボタン画像であってもよい。   As shown in FIG. 1, the image processing apparatus 100 is, for example, a smartphone. The image processing apparatus 100 includes a liquid crystal display with a touch panel, an inner camera and a photographing button arranged on the same side as the display (none of which are shown). The shooting button may be a button image displayed on the display.

画像処理装置100は、内側カメラで撮影した映像を左右方向に反転させて、ほぼリアルタイムでディスプレイに表示する。そして、画像処理装置100は、撮影ボタンが押下されたタイミングで、表示中の映像から静止画像を切り出して記録したり、映像の記録を開始したりする。   The image processing apparatus 100 inverts the image captured by the inner camera in the left-right direction and displays it on the display in substantially real time. Then, the image processing apparatus 100 cuts out and records a still image from the displayed video or starts recording the video at the timing when the shooting button is pressed.

ユーザ200は、例えば、内側カメラを自分の顔に向け、ディスプレイに映し出された映像で自分の顔の見栄えを確認しながら、所望のタイミングで撮影ボタンを押下する。これが、いわゆる自分撮りと呼ばれる行為である。   For example, the user 200 directs the inner camera toward his / her face and presses the shooting button at a desired timing while confirming the appearance of his / her face with the video displayed on the display. This is what is called selfie.

画像処理装置100は、更に、ユーザのタッチパネルに対するタッチ操作に応じて、画像処理により、映像の顔の部分に対して化粧画像を重畳する。このとき、上述の通り、ディスプレイに映し出されているユーザ200の顔の視認性が、指によって阻害されることは好ましくない。   The image processing apparatus 100 further superimposes a makeup image on the face portion of the video by image processing in response to a user's touch operation on the touch panel. At this time, as described above, it is not preferable that the visibility of the face of the user 200 displayed on the display is obstructed by the finger.

そこで、画像処理装置100は、ディスプレイに映し出され映像の画面における顔の位置を取得する。そして、画像処理装置100は、顔の位置に向かう方向にスワイプ操作が行われたことを条件として、化粧画像の重畳を行ったり、重畳されている化粧画像の内容を変更する等、化粧画像の重畳の状態を変更する。   Therefore, the image processing apparatus 100 obtains the position of the face on the screen of the video displayed on the display. Then, on the condition that the swipe operation is performed in the direction toward the face position, the image processing apparatus 100 superimposes the makeup image or changes the content of the makeup image that is superimposed. Change the overlay state.

ここで、スワイプ操作とは、指やスタイラス等の先の部分を、画面に接触したまま滑らせる操作である。また、顔の位置に向かう方向とは、例えば、その延長上に顔の領域が存在する方向や、指先の接触領域の代表位置(例えば重心位置)から顔の代表位置(例えば重心位置)までの距離が小さくなるようなスワイプ操作の方向である。   Here, the swipe operation is an operation of sliding a tip portion such as a finger or a stylus while touching the screen. The direction toward the face position is, for example, the direction in which the face area exists on the extension, or the representative position (for example, the center of gravity position) of the fingertip contact area to the representative position of the face (for example, the center of gravity position). The direction of the swipe operation is such that the distance becomes smaller.

すなわち、画像処理装置100は、ユーザ200が、顔が映し出されている領域を指で遮蔽せずに、化粧画像の重畳の状態を変更する操作を行うことを可能にする。   In other words, the image processing apparatus 100 allows the user 200 to perform an operation to change the superimposed state of the makeup image without blocking the area where the face is projected with a finger.

<装置の構成>
次に、画像処理装置100の構成について説明する。
<Device configuration>
Next, the configuration of the image processing apparatus 100 will be described.

図2は、画像処理装置100の構成の一例を示すブロック図である。   FIG. 2 is a block diagram illustrating an example of the configuration of the image processing apparatus 100.

図2において、画像処理装置100は、撮影部110、操作受付部120、情報格納部130、顔位置取得部140、化粧画像重畳部150、および表示部160を有する。   2, the image processing apparatus 100 includes a photographing unit 110, an operation receiving unit 120, an information storage unit 130, a face position acquisition unit 140, a makeup image superimposing unit 150, and a display unit 160.

撮影部110は、例えば、上述の内側カメラ(デジタルカメラ)を有し、映像を撮影する。なお、撮影部110は、自分撮りが行われる場合、ユーザ、あるいは、ユーザを含む複数の人の顔の映像を撮影する。そして、撮影部110は、撮影した映像を、左右方向に反転させて、顔位置取得部140および化粧画像重畳部150へ出力する。   The photographing unit 110 has, for example, the above-described inner camera (digital camera) and photographs an image. In addition, when the self-portrait is performed, the image capturing unit 110 captures images of the face of the user or a plurality of people including the user. Then, the photographing unit 110 inverts the photographed video image in the left-right direction and outputs it to the face position acquisition unit 140 and the makeup image superimposing unit 150.

操作受付部120は、例えば、上述のタッチパネルを有し、後述の表示部160が有する液晶ディスプレイの画面に対するタッチ操作を受け付ける。そして、操作受付部120は、所定の周期で、画面のどの部分に指が接触しているかを検出し、検出結果を示す座標情報を、化粧画像重畳部150へ出力する。座標情報の時系列データは、つまり、どのような内容のタッチ操作が行われたかを示す操作情報である。   The operation receiving unit 120 includes, for example, the above-described touch panel, and receives a touch operation on a screen of a liquid crystal display included in the display unit 160 described later. Then, operation accepting unit 120 detects which part of the screen is in contact with the finger at a predetermined cycle, and outputs coordinate information indicating the detection result to makeup image superimposing unit 150. The time-series data of the coordinate information is operation information indicating what kind of touch operation has been performed.

情報格納部130は、画像から画像に含まれる人の顔や顔部品を検出するための顔特徴情報、および、化粧画像を生成して映像の顔の部分に重畳するための化粧画像情報を、予め格納している。また情報格納部130は、映像から検出された各顔の状態を管理するための状態記録テーブルを格納する。   The information storage unit 130 includes facial feature information for detecting a human face and facial parts included in the image from the image, and makeup image information for generating a makeup image and superimposing it on the face portion of the video, Stored in advance. The information storage unit 130 stores a state recording table for managing the state of each face detected from the video.

顔特徴情報は、例えば、多数の顔画像サンプルに基づく学習により生成された、目や唇といった顔部品の形状等の画像特徴や、顔部品の配置や顔の色ヒストグラムといった顔全体の画像特徴を示す情報である。顔部品のそれぞれには、目尻や口角といった、顔特徴点が含まれる。   The face feature information includes, for example, image features such as the shape of face parts such as eyes and lips, and image features of the entire face such as face part arrangement and face color histogram, which are generated by learning based on many face image samples. It is information to show. Each facial part includes facial feature points such as the corners of the eyes and the corners of the mouth.

化粧画像情報は、複数の化粧のパターンと化粧の濃さとの組み合わせ毎に、顔に重畳すべき化粧画像の内容(以下「化粧画像データ」という)を記述した情報である。   The makeup image information is information describing the contents of a makeup image (hereinafter referred to as “makeup image data”) to be superimposed on the face for each combination of a plurality of makeup patterns and makeup darkness.

図3は、化粧画像情報の内容の一例を示す図である。   FIG. 3 is a diagram illustrating an example of the contents of the makeup image information.

図3に示すように、化粧画像情報310は、複数の化粧パターン311および複数の化粧濃さ312について、化粧パターン311と化粧濃さ312との組み合わせ毎に、化粧画像データ313を記述している。   As shown in FIG. 3, makeup image information 310 describes makeup image data 313 for each combination of makeup pattern 311 and makeup density 312 for a plurality of makeup patterns 311 and a plurality of makeup densities 312. .

化粧画像データ313は、例えば、口角等の顔特徴点の位置を基準として、化粧画像が示す化粧の塗布領域、化粧の色、および化粧の色の濃度(化粧画像の透明度)を規定する。化粧の塗布領域は、例えば、顔特徴点の位置を基準とする空間における座標値や関数によって定義される。化粧の色は、例えば、RGB(Red, Green, Blue)、HSV(Hue, Saturation, Value)といった所定の色空間における座標値によって定義される。化粧の濃さは、例えば、撮影画像に化粧画像をαブレンドによって重畳する際の、画素値に対する係数によって定義される。   The makeup image data 313 defines, for example, the makeup application area, makeup color, and makeup color density (transparency of the makeup image) indicated by the makeup image on the basis of the position of the facial feature point such as the mouth corner. The makeup application area is defined by, for example, coordinate values or functions in a space based on the position of the face feature point. The makeup color is defined by coordinate values in a predetermined color space such as RGB (Red, Green, Blue) and HSV (Hue, Saturation, Value). The darkness of the makeup is defined by, for example, a coefficient for the pixel value when the makeup image is superimposed on the captured image by α blending.

なお、ここでは、化粧画像を重畳しない状態を、第0の化粧パターンとしている。また、第1〜第3の化粧パターンは、化粧の塗布領域、化粧の色、および化粧の色の濃度のうち少なくとも1つにおいて異なる。化粧パターンは、例えば、可愛い印象を与える化粧パターンや、ゴージャスな印象を与える化粧パターンを含む。第1〜第3の化粧濃さ312は、この順に、化粧画像の色の濃度がより濃く(化粧画像の透明度が高く)なっている。   Here, the state where the makeup image is not superimposed is the 0th makeup pattern. The first to third makeup patterns differ in at least one of the makeup application area, the makeup color, and the makeup color density. The makeup pattern includes, for example, a makeup pattern that gives a cute impression and a makeup pattern that gives a gorgeous impression. In the first to third makeup densities 312, the makeup image color density is higher in this order (makeup image transparency is higher).

なお、化粧の塗布領域の違いは、頬紅の塗布領域が大きいか小さいかといった違いであってもよいし、口紅や頬紅といった複数のパーツのうちどのパーツに対する化粧塗布であるかという違いであってもよい。また、化粧の色の濃度の変化は、パーツ毎に異なっていてもよい。   The difference in the makeup application area may be a difference in whether the application area of the blusher is large or small, or a difference in which of the plurality of parts such as lipstick or blusher is the makeup application. Also good. Further, the change in makeup color density may be different for each part.

状態記録テーブルは、後述の顔位置取得部140および化粧画像重畳部150により適宜生成および更新されるテーブルであり、顔位置取得部140により追跡される顔の状態を記録するテーブルである。   The state recording table is a table that is appropriately generated and updated by a face position acquisition unit 140 and a makeup image superimposing unit 150, which will be described later, and is a table that records the state of the face tracked by the face position acquisition unit 140.

図4は、状態記録テーブルの内容の一例を示す図である。   FIG. 4 is a diagram showing an example of the contents of the status record table.

図4に示すように、状態記録テーブル320は、追跡識別子321毎に、化粧設定322、現在位置323、スワイプ開始時位置324、相対位置325、および追跡状態326を記述する。   As shown in FIG. 4, the state record table 320 describes makeup setting 322, current position 323, swipe start position 324, relative position 325, and tracking state 326 for each tracking identifier 321.

追跡識別子321は、後述の顔位置取得部140により同一の顔として追跡される対象識別子である。化粧設定322は、追跡識別子321が示す顔に現在設定されている化粧画像データである。現在位置323は、追跡識別子321が示す顔の、現在の画面における位置である。画面における位置は、例えば、画面に予め設定されたXY座標系の座標値により表される。   The tracking identifier 321 is a target identifier tracked as the same face by the face position acquisition unit 140 described later. The makeup setting 322 is makeup image data currently set for the face indicated by the tracking identifier 321. The current position 323 is a position on the current screen of the face indicated by the tracking identifier 321. The position on the screen is represented by, for example, coordinate values in an XY coordinate system preset on the screen.

スワイプ開始時位置324は、直近にスワイプ操作が開始されたときの、追跡識別子321が示す顔の画面における位置である。相対位置325は、他の顔に対する相対位置である。追跡状態326は、顔の位置の追跡が継続中であるか、終了したか、あるいは開始した直後か、を示す情報である。   The swipe start position 324 is a position on the face screen indicated by the tracking identifier 321 when the most recent swipe operation is started. The relative position 325 is a relative position with respect to another face. The tracking state 326 is information indicating whether tracking of the position of the face is continuing, completed, or just started.

なお、相対位置325は、少なくとも鉛直方向を含む、実世界における所定の方向を基準とする相対位置関係であることが望ましい。この場合、画像処理装置100は、加速度センサを備える必要がある。なお、相対位置325は、必ずしも実世界における方向を取得しなくてもよく、追跡が継続されている顔の複数の顔部品の画面における配置を基準として、当該顔に対する他の顔の相対位置を判定してもよい。   The relative position 325 is desirably a relative positional relationship based on a predetermined direction in the real world including at least the vertical direction. In this case, the image processing apparatus 100 needs to include an acceleration sensor. Note that the relative position 325 does not necessarily need to acquire the direction in the real world. The relative position of another face with respect to the face is determined based on the arrangement of a plurality of facial parts of the face being tracked on the screen. You may judge.

図2の顔位置取得部140は、入力された映像から、逐次、映像に含まれる画面における顔の位置、および顔内における顔部品の位置(顔特徴点の位置)の情報を取得する。   The face position acquisition unit 140 in FIG. 2 sequentially acquires information on the position of the face on the screen included in the image and the position of the face part (face feature point position) in the face from the input image.

より具体的には、顔位置取得部140は、まず、入力映像に対して顔検出を実施して、画像フレーム中の顔の位置情報を得る。次に、顔位置取得部140は、得られた顔の位置情報を元に顔部品位置の検出を実施し、顔部品の位置情報を得る。顔検出および顔部品の検出については、公知の技術を採用することができる。そして、顔位置取得部140は、抽出された顔の映像における位置を、予め定められた、映像と映像を映し出す画面との位置関係に基づいて、画面における位置に変換する。   More specifically, the face position acquisition unit 140 first performs face detection on the input video to obtain face position information in the image frame. Next, the face position acquisition unit 140 detects the face part position based on the obtained face position information, and obtains the face part position information. Known techniques can be employed for face detection and face part detection. Then, the face position acquisition unit 140 converts the position of the extracted face in the video into a position on the screen based on a predetermined positional relationship between the video and the screen on which the video is displayed.

また、顔位置取得部140は、映像において、顔毎に位置を追跡する。例えば、顔位置取得部140は、映像を構成する時系列の複数の画像フレームのうち、時間的に連続する複数の画像フレームのそれぞれで検出された顔が、位置の差異が所定の範囲内である場合、当該の顔を同一の顔と判定する。顔位置取得部140は、かかる判定を映像の時間軸に沿って連続して行うことにより、顔の位置を追跡する。   Further, the face position acquisition unit 140 tracks the position for each face in the video. For example, the face position acquisition unit 140 detects a face detected in each of a plurality of temporally continuous image frames from among a plurality of time-series image frames constituting a video within a predetermined range. If there is, the face is determined to be the same face. The face position acquisition unit 140 tracks the face position by continuously performing such determination along the video time axis.

そして、顔位置取得部140は、状態記録テーブル320において、顔の追跡が開始される毎に、追跡識別子321を追加し、顔の追跡が開始されると、追跡状態326を更新し、顔の追跡が行われている間、現在位置323を更新する。なお、顔の追跡とは、直前の画像フレームで検出された顔を、最新の画像フレームのうち直前の画像フレームで検出された位置の周辺においても検出することである。更に、顔位置取得部140は、状態記録テーブル320において、顔の追跡が終了する毎に、追跡状態326を更新する(図4参照)。   The face position acquisition unit 140 adds a tracking identifier 321 every time face tracking is started in the state recording table 320, and updates the tracking state 326 when face tracking is started. While the tracking is performed, the current position 323 is updated. Note that the face tracking is to detect the face detected in the immediately preceding image frame even in the vicinity of the position detected in the immediately preceding image frame in the latest image frame. Further, the face position acquisition unit 140 updates the tracking state 326 in the state recording table 320 every time face tracking is completed (see FIG. 4).

また、顔位置取得部140は、各画面に複数の顔が含まれるとき、画面における、各顔の他の顔に対する相対位置を取得し、相対位置が取得される毎に、取得された相対位置で、状態記録テーブル320の相対位置325を更新する。なお、追跡が終了した顔の相対位置325については、そのままとする。   Further, when a plurality of faces are included in each screen, the face position acquisition unit 140 acquires a relative position of each face with respect to the other face on the screen, and each time the relative position is acquired, the acquired relative position Thus, the relative position 325 of the state recording table 320 is updated. It should be noted that the relative position 325 of the face that has been tracked is left as it is.

また、顔位置取得部140は、取得された画面における顔の位置および顔部品の位置(以下、適宜「顔位置」という)を示す顔位置情報を、化粧画像重畳部150へ出力する。   The face position acquisition unit 140 also outputs face position information indicating the position of the face and the position of the face part (hereinafter referred to as “face position” as appropriate) on the acquired screen to the makeup image superimposing unit 150.

化粧画像重畳部150は、入力された操作情報(タッチ操作行われた領域の座標情報の時系列データ)および顔位置情報に基づいて、入力された映像の顔の部分に対して化粧画像を重畳する。より具体的には、化粧画像重畳部150は、操作情報に基づいて、顔の位置に向かう方向にスワイプ操作が行われたか否かを判定し、当該スワイプ操作が行われたことを条件として、化粧画像の重畳の状態を変更する。また、このとき、化粧画像重畳部150は、状態記録テーブル320において、スワイプ開始時位置324を更新する。なお、化粧画像重畳部150は、αブレンド等の公知の画像合成技術を用いて、画像の重畳を行う。そして、化粧画像重畳部150は、化粧画像が適宜重畳された映像を、表示部160へ出力する。   The makeup image superimposing unit 150 superimposes the makeup image on the face portion of the input video based on the input operation information (time series data of the coordinate information of the area where the touch operation is performed) and the face position information. To do. More specifically, the makeup image superimposing unit 150 determines whether or not the swipe operation is performed in the direction toward the face based on the operation information, and on the condition that the swipe operation is performed. The superimposition state of the makeup image is changed. At this time, the makeup image superimposing unit 150 updates the swipe start position 324 in the state recording table 320. The makeup image superimposing unit 150 performs image superimposition using a known image composition technique such as α blend. Then, makeup image superimposing unit 150 outputs a video on which a makeup image is appropriately superimposed to display unit 160.

なお、化粧画像重畳部150は、初期状態において、顔の部分に対して化粧画像を重畳していない。化粧画像重畳部150は、化粧画像が重畳されていない顔の位置に向かう方向へのスワイプ操作(以下「顔方向スワイプ操作」という)が行われたことを条件として、化粧画像の重畳を開始させる。なお、化粧画像重畳部150は、開始位置が、顔の領域、あるいは、顔の領域を一回り大きくした領域に含まれるスワイプ操作については、顔方向スワイプ操作ではないと判定してもよい。   The makeup image superimposing unit 150 does not superimpose the makeup image on the face portion in the initial state. The makeup image superimposing unit 150 starts superimposition of the makeup image on the condition that a swipe operation in a direction toward the face position where the makeup image is not superimposed (hereinafter referred to as “face direction swipe operation”) is performed. . The makeup image superimposing unit 150 may determine that the swipe operation in which the start position is included in the face area or an area that is slightly larger than the face area is not a face direction swipe operation.

また、化粧画像重畳部150は、化粧画像が重畳されている顔に対して、上下方向以外の方向(第1の方向)で顔方向スワイプ操作が行われたことを条件として、重畳されている化粧画像が示す化粧の濃さを変更する。また、化粧画像重畳部150は、化粧画像が重畳されている顔に対して、上下方向(第2の方向)でスワイプ操作が行われたことを条件として、重畳されている化粧画像が示す化粧のパターンを変更する。   The makeup image superimposing unit 150 is superimposed on the condition that the face direction swipe operation is performed on the face on which the makeup image is superimposed in a direction other than the vertical direction (first direction). The darkness of the makeup indicated by the makeup image is changed. The makeup image superimposing unit 150 also displays the makeup indicated by the superimposed makeup image on the condition that the swipe operation is performed in the vertical direction (second direction) on the face on which the makeup image is superimposed. Change the pattern.

また、化粧画像重畳部150は、タッチ操作が開始されたときの顔の位置を基準として、タッチ操作の対象を決定する。   The makeup image superimposing unit 150 also determines the target of the touch operation based on the position of the face when the touch operation is started.

また、化粧画像重畳部150は、画面に複数の顔が含まれるとき、当該複数の顔の相対位置関係を取得し、位置の追跡が継続しているか否か、および、相対位置関係が維持されているか否か、に基づいて、顔毎に、化粧設定を維持するか否かを判断する。   In addition, when a plurality of faces are included in the screen, makeup image superimposing unit 150 acquires the relative positional relationship between the plurality of faces, whether the position tracking is continued, and the relative positional relationship is maintained. It is determined whether or not the makeup setting is maintained for each face based on whether or not the face is on.

これらの、化粧画像の重畳状態の変更、タッチ操作の対象の決定、および、化粧設定の維持の判断についての詳細は、後述する。   Details of the change of the superposition state of the makeup image, the determination of the target of the touch operation, and the determination of the maintenance of the makeup setting will be described later.

表示部160は、例えば、上記液晶ディスプレイを有し、入力された、化粧画像が適宜重畳された映像(以下「バーチャル化粧映像」という)を、当該液晶ディスプレイの画面に表示する。   The display unit 160 includes, for example, the liquid crystal display, and displays the input video (hereinafter referred to as “virtual makeup video”) on which the makeup image is appropriately superimposed on the screen of the liquid crystal display.

なお、画像処理装置100は、図示しないが、更に、上述の撮影ボタン、および、情報記録部を有する。情報記録部は、撮影ボタンが押下されたとタイミングで、バーチャル化粧映像から静止画像を切り出して記録したり、バーチャル化粧映像の記録を開始したりする。   Although not shown, the image processing apparatus 100 further includes the above-described shooting button and an information recording unit. The information recording unit cuts out and records a still image from the virtual makeup video or starts recording the virtual makeup video at the timing when the shooting button is pressed.

画像処理装置100は、図示しないが、例えば、CPU(Central Processing Unit)、制御プログラムを格納したROM(Read Only Memory)等の記憶媒体、およびRAM(Random Access Memory)等の作業用メモリを有する。この場合、上記した各部の機能は、CPUが制御プログラムを実行することにより実現される。   Although not shown, the image processing apparatus 100 includes a CPU (Central Processing Unit), a storage medium such as a ROM (Read Only Memory) storing a control program, and a working memory such as a RAM (Random Access Memory). In this case, the function of each unit described above is realized by the CPU executing the control program.

このような構成を有する画像処理装置100は、画面において顔方向スワイプ操作が行われたことを条件として、映像に含まれる顔への化粧画像の重畳の状態を変更することができる。   The image processing apparatus 100 having such a configuration can change the superimposition state of the makeup image on the face included in the video on the condition that the face direction swipe operation is performed on the screen.

<化粧画像の重畳状態の変更>
ここで、化粧画像重畳部150が行う、化粧画像の重畳状態の変更の様子について説明する。
<Change of makeup image overlay state>
Here, how the makeup image superimposing unit 150 changes the makeup image overlay state will be described.

図5は、化粧画像の重畳状態の変更の様子の一例を説明するための図である。   FIG. 5 is a diagram for explaining an example of how the makeup image is superimposed.

図5の第1の画面状態411に示すように、顔401に化粧画像が重畳されていない状態(初期状態)にある画面に対して、ユーザの指402により、顔方向スワイプ操作が行われる。   As shown in a first screen state 411 in FIG. 5, a face direction swipe operation is performed with a user's finger 402 on a screen in a state where a makeup image is not superimposed on the face 401 (initial state).

すると、化粧画像重畳部150は、図5の第2の画面状態412に示すように、顔401に、化粧画像403を重畳する。これは、適用する化粧画像データ313を、第0の化粧パターンの化粧画像データ313(化粧画像なし)から、第1の化粧パターンと第1の化粧濃さ312と組み合わせの化粧画像データ313へと変更することに相当する(図3参照)。   Then, the makeup image superimposing unit 150 superimposes the makeup image 403 on the face 401 as shown in the second screen state 412 of FIG. This applies the makeup image data 313 to be applied from the makeup image data 313 of the 0th makeup pattern (no makeup image) to the makeup image data 313 combined with the first makeup pattern and the first makeup density 312. This corresponds to the change (see FIG. 3).

そして、図5の第3の画面状態413に示すように、化粧画像403が重畳された顔401に対して、更に、上下方向以外の方向で、顔方向スワイプ操作が行われる。   Then, as shown in the third screen state 413 in FIG. 5, a face direction swipe operation is further performed on the face 401 on which the makeup image 403 is superimposed in a direction other than the vertical direction.

すると、化粧画像重畳部150は、図5の第4の画面状態414に示すように、重畳されている化粧画像403を、当該化粧画像403よりも濃い化粧画像404に切り替える。これは、適用する化粧画像データ313を、状態記録テーブル320の化粧設定322を用いて、第1〜第3の化粧濃さ312の間で順次切り替えていくことに相当する(図3参照)。   Then, the makeup image superimposing unit 150 switches the superimposed makeup image 403 to a makeup image 404 that is darker than the makeup image 403, as shown in the fourth screen state 414 in FIG. This corresponds to sequentially switching the makeup image data 313 to be applied between the first to third makeup densities 312 using the makeup setting 322 of the state recording table 320 (see FIG. 3).

あるいは、図5の第5の画面状態415に示すように、化粧画像403が重畳された顔401に対して、更に、上方向および下方向のうち少なくとも1つの方向で、スワイプ操作が行われる。   Alternatively, as shown in a fifth screen state 415 in FIG. 5, a swipe operation is further performed on the face 401 on which the makeup image 403 is superimposed in at least one of an upward direction and a downward direction.

すると、化粧画像重畳部150は、重畳されている化粧画像403を、当該化粧画像403とは異なる化粧パターンの化粧画像405に切り替える。これは、適用する化粧画像データ313を、状態記録テーブル320の化粧設定322を用いて、第0〜第3の化粧パターン311の間で順次切り替えていくことに相当する(図3参照)。   Then, the makeup image superimposing unit 150 switches the superimposed makeup image 403 to a makeup image 405 having a makeup pattern different from the makeup image 403. This corresponds to sequentially switching the applied makeup image data 313 between the 0th to 3rd makeup patterns 311 using the makeup setting 322 of the state recording table 320 (see FIG. 3).

このように、化粧画像重畳部150は、画面に対するタッチ操作に応じて、化粧画像の重畳状態を変更する。   As described above, the makeup image superimposing unit 150 changes the overlay state of the makeup image according to the touch operation on the screen.

<タッチ操作の対象の決定>
次に、化粧画像重畳部150が行う、タッチ操作の対象の決定の様子について説明する。
<Determination of touch operation target>
Next, how the makeup image superimposing unit 150 determines the target of the touch operation will be described.

図6は、タッチ操作の対象となる顔を決定する様子の一例を説明するための図である。   FIG. 6 is a diagram for explaining an example of how a face to be touched is determined.

図6の第1の画面状態421に示すように、第1の顔401と第2の顔401とが含まれる画面において、ユーザの指402により、第1の顔401へと向かう方向でスワイプ操作が開始される。 As shown in the first screen state 421 in FIG. 6, the screen includes a first face 401 1 and a 2 second face 401, the user's finger 402, a direction toward the first face 401 1 The swipe operation starts.

ところが、図6の第2の画面状態422に示すように、スワイプ操作中に画像処理装置100の向きがぶれる等して、画面における、第1および第2の顔401、401の位置が変化する。そして、その結果、図6の第3の画面状態423に示すように、スワイプ操作のスワイプ方向に、第1の顔401ではなく、第2の顔401が位置するようになる。 However, as shown in the second screen state 422 in FIG. 6, the position of the first and second faces 401 1 and 401 2 on the screen is changed due to, for example, the orientation of the image processing apparatus 100 being shaken during the swipe operation. Change. Then, as a result, as shown in the third screen state 423 in FIG. 6, the swipe direction of the swipe operation, the first face 401 rather than 1, 2 a second face 401 will be positioned.

画面の変化が速い場合、かかる変化に合わせてスワイプ方向を途中で的確に変更することは難しい。そこで、化粧画像重畳部150は、スワイプ操作が開始されたときの顔401の位置を基準として、いずれの顔401の位置に向かう方向にスワイプ操作が行われたか否かを判定する。スワイプ操作が開始されたときの顔401の位置は、つまり、第1の画面状態421における、第1および第2の顔401、401の位置である。この例では、化粧画像重畳部150は、第1の顔401を、スワイプ操作の対象と判定する。 When the screen changes quickly, it is difficult to accurately change the swipe direction along the way. Therefore, the makeup image superimposing unit 150 determines whether the swipe operation is performed in the direction toward the position of any face 401 with reference to the position of the face 401 when the swipe operation is started. The position of the face 401 when the swipe operation is started is the positions of the first and second faces 401 1 and 401 2 in the first screen state 421. In this example, the decorative image superimposing unit 150, the first face 401 1 determines that the target of the swipe.

図7は、タッチ操作の対象となる顔部品を決定する様子の一例を説明するための図である。   FIG. 7 is a diagram for explaining an example of a state in which a face part to be touched is determined.

ここでは、化粧画像重畳部150が、顔部品に対してフリック操作が行われたことを条件として、フリック方向に応じて、該顔部品に対する化粧画像の色、形状、濃さ等を変更する場合を例示して説明する。フリック操作とは、指やスタイラス等の先の部分を、画面の一カ所で長めに接触した直後に、画面に接触したまま素早く滑らせる操作である。   Here, makeup image superimposing section 150 changes the color, shape, darkness, etc., of the makeup image for the face part according to the flick direction on the condition that the flick operation has been performed on the face part. An example will be described. The flick operation is an operation of quickly sliding the tip of a finger or stylus immediately after touching a part of the screen for a long time while touching the screen.

図7の第1の画面状態431に示すように、ユーザの指402が、顔401の右目406に対してフリック操作を開始する。ところが、図7の第2の画面状態432に示すように、フリック操作中に画像処理装置100の向きがぶれる等して、画面における、顔401の位置が変化する。そして、その結果、図7の第3の画面状態433に示すように、フリック操作が行われている位置に、右目406ではなく、左目407が位置することになる。   As shown in the first screen state 431 of FIG. 7, the user's finger 402 starts a flick operation on the right eye 406 of the face 401. However, as shown in the second screen state 432 of FIG. 7, the position of the face 401 on the screen changes due to, for example, the orientation of the image processing apparatus 100 being shaken during the flick operation. As a result, as shown in the third screen state 433 in FIG. 7, the left eye 407 is positioned instead of the right eye 406 at the position where the flick operation is performed.

画面の変化が速い場合、かかる変化に合わせてフリック位置を途中で的確に変更することは難しい。そこで、化粧画像重畳部150は、フリック操作が開始されたときの顔401の位置、つまり、第1の画面状態431における顔401を基準として、フリック操作の対象を決定する。この例では、化粧画像重畳部150は、左目407ではなく、右目406を、フリック操作の対象と判定する。   When the screen changes rapidly, it is difficult to accurately change the flick position along the way. Therefore, the makeup image superimposing unit 150 determines the target of the flick operation on the basis of the position of the face 401 when the flick operation is started, that is, the face 401 in the first screen state 431. In this example, the makeup image superimposing unit 150 determines not the left eye 407 but the right eye 406 as a target of the flick operation.

このように、化粧画像重畳部150は、画面に対するタッチ操作が開始されたときの顔(顔部品)の位置を基準として、スワイプ操作やフリック操作等のタッチ操作の対象を決定する。   As described above, the makeup image superimposing unit 150 determines a target of a touch operation such as a swipe operation or a flick operation based on the position of the face (face part) when the touch operation on the screen is started.

<化粧設定の維持の判断>
次に、化粧画像重畳部150が行う、化粧設定の維持の判断の様子について説明する。
<Judgment of maintaining makeup settings>
Next, a description will be given of how the makeup image superimposing unit 150 determines to maintain makeup settings.

図8は、化粧設定の維持の判断の様子の一例を説明するための図である。   FIG. 8 is a diagram for explaining an example of a state of determination of maintaining makeup settings.

図8の第1の画面状態441に示すように、第1の顔401と第2の顔401とが、画面に含まれている。 As shown in the first screen state 441 in FIG. 8, the first face 401 1 and a 2 second face 401 is included in the screen.

ところが、図8の第2の画面状態442に示すように、タッチ操作中に画像処理装置100の向きがぶれる等して、第2の顔401が画面から外れる。そして、図8の第3の画面状態443および第4の画面状態444に示すように、ユーザにより画像処理装置100の向きが修正される等して、第3の顔401が画面内に戻る。 However, as shown in the second screen state 442 in FIG. 8, and the like orientation of the image processing apparatus 100 is blurred during the touch operation, out of the second face 401 2 screen. Then, as shown in the third screen state 443 and the fourth screen state 444 in FIG. 8, and the like orientation of the image processing apparatus 100 by the user is modified, the third face 401 3 returns to the screen .

第3の顔401は、第2の顔401と同一人物の顔であるため、第2の顔401の化粧設定を、そのまま第3の顔401に適用すべきである。ところが、顔の識別処理を行って、第3の顔401が第2の顔401と同一であるか否かを判定すると、処理負荷が高くなる。 The third face 401 3 are the face of the second face 401 2 and the same person, the second face 401 2 cosmetic set, it should be directly applied to the third face 401 3. However, by performing the identification process of the face, the third face 401 3 to determine whether it is identical to the 2 second face 401, the processing load increases.

そこで、化粧画像重畳部150は、まず、第1の顔401の位置の追跡が継続していることを確認する。そして、化粧画像重畳部150は、位置の追跡が継続している第1の顔401を基準として、第1の顔401に対する第2の顔401の相対位置408に、第1の顔401に対する第3の顔401の相対位置408が同一であるか否かを判定する。そして、化粧画像重畳部150は、相対位置408、408が同一である場合、第2の顔401の化粧設定を、第3の顔401に適用する。 Therefore, the decorative image superimposing unit 150 first confirms that the tracking of the first face 401 1 of the position continues. Then, the decorative image superimposing unit 150, a first face 401 1 relative to the location tracking continues, the relative position 4081 of the second face 401 2 to the first face 401 1, the first It determines whether the relative position 408 2 of the third face 401 3 against face 401 1 are identical. Then, the decorative image superimposing unit 150, if the relative positions 4081, 408 2 are identical, the second face 401 2 cosmetic set is applied to the third face 401 3.

なお、ここでいう相対位置の同一とは、相対位置が異なっていても、その差異が所定の範囲内にある場合を含む。   Here, the same relative position includes the case where the relative position is different but the difference is within a predetermined range.

このように、化粧画像重畳部150は、画面に含まれる顔の数が変化したとき、位置の追跡が継続している顔を基準とした顔の相対位置関係が維持されているか否かに基づいて、画面から消えた顔の化粧設定を、画面に現れた顔に適用するか否かを判断する。   As described above, the makeup image superimposing unit 150 is based on whether or not the relative positional relationship of the face based on the face whose position is being tracked is maintained when the number of faces included in the screen changes. Then, it is determined whether or not the makeup setting for the face disappeared from the screen is applied to the face appearing on the screen.

<装置の動作>
次に、画像処理装置100の動作について説明する。
<Operation of the device>
Next, the operation of the image processing apparatus 100 will be described.

図9は、画像処理装置100の動作の一例を示すフローチャートである。なお、ここでは、スワイプ操作に関する動作に着目して説明を行う。   FIG. 9 is a flowchart illustrating an example of the operation of the image processing apparatus 100. Here, the description will be given focusing on the operation related to the swipe operation.

ステップS1100において、撮影部110は、映像の撮影を開始する。かかる映像には、特に自分撮りが行われている場合、1つあるいは複数の顔の画像が含まれ得る。   In step S1100, the photographing unit 110 starts photographing a video. Such video may include one or more facial images, particularly when a selfie is being taken.

ステップS1200において、顔位置取得部140は、顔を検出し、画面上の顔位置を取得するとともに、各顔の現在位置323を状態記録テーブル320に記録する(図4参照)。また、顔位置取得部140は、同一の顔が継続して画面に含まれている間、当該顔の位置を追跡するとともに、位置の追跡が開始、継続、あるいは終了する毎に、状態記録テーブル320の追跡状態326にその旨を記録する(図4参照)。   In step S1200, the face position acquisition unit 140 detects a face, acquires the face position on the screen, and records the current position 323 of each face in the state recording table 320 (see FIG. 4). Further, the face position acquisition unit 140 tracks the position of the face while the same face is continuously included in the screen, and whenever the position tracking starts, continues, or ends, the state recording table The fact is recorded in the tracking state 326 of 320 (see FIG. 4).

ステップS1300において、化粧画像重畳部150は、画面に含まれる顔が複数であるか否かを判定する。化粧画像重畳部150は、顔が複数である場合(S1300:YES)、処理をステップS1400へ進める。また、化粧画像重畳部150は、顔が複数ではない場合(S1300:NO)、処理を後述のステップS1500へ進める。   In step S1300, makeup image superimposing unit 150 determines whether there are a plurality of faces included in the screen. If there are a plurality of faces (S1300: YES), makeup image superimposing section 150 advances the process to step S1400. If there are not a plurality of faces (S1300: NO), makeup image superimposing section 150 advances the process to step S1500 described later.

ステップS1400において、化粧画像重畳部150は、相対位置解析処理を行う。相対位置解析処理は、複数の顔の相対位置を解析して、適宜、化粧設定の再適用を行う処理である。相対位置解析処理の詳細については、後述する。   In step S1400, the makeup image superimposing unit 150 performs a relative position analysis process. The relative position analysis process is a process of analyzing the relative positions of a plurality of faces and reapplying makeup settings as appropriate. Details of the relative position analysis processing will be described later.

ステップS1500において、化粧画像重畳部150は、スワイプ操作か否かを判定する。スワイプ操作が開始されたか否かは、例えば、接触位置が1つであり、接触が開始されてから接触位置が連続的に移動したという条件が満たされるか否かに基づいて判定される。   In step S1500, makeup image superimposing unit 150 determines whether or not a swipe operation is performed. Whether or not the swipe operation has been started is determined based on whether or not the condition that there is one contact position and the contact position has continuously moved since the start of contact is satisfied, for example.

化粧画像重畳部150は、スワイプ操作が開始された場合(S1500:YES)、処理をステップS1600へ進める。また、化粧画像重畳部150は、スワイプ操作が開始されていない場合(S1500:NO)、処理を後述のステップS1700へ進める。   If the swipe operation is started (S1500: YES), makeup image superimposing unit 150 advances the process to step S1600. If the swipe operation has not started (S1500: NO), makeup image superimposing unit 150 advances the process to step S1700, which will be described later.

ステップS1600において、化粧画像重畳部150は、スワイプ操作が開始された位置(以下「スワイプ開始位置」という)を取得する。また、化粧画像重畳部150は、各顔の顔位置を、スワイプ開始時位置324として状態記録テーブル320に記録する(図4参照)。   In step S1600, makeup image superimposing unit 150 acquires a position where the swipe operation is started (hereinafter referred to as “swipe start position”). The makeup image superimposing unit 150 records the face position of each face in the state recording table 320 as a swipe start position 324 (see FIG. 4).

ステップS1700において、化粧画像重畳部150は、いずれかの顔の位置の付近で、上下方向のスワイプ操作(以下「上下スワイプ」という)が行われたか否かを判定する。かかる操作は、図5の第5の画面状態415で説明した操作に相当する。   In step S1700, makeup image superimposing section 150 determines whether or not a vertical swipe operation (hereinafter referred to as “vertical swipe”) has been performed near any face position. Such an operation corresponds to the operation described in the fifth screen state 415 of FIG.

化粧画像重畳部150は、顔位置付近で上下スワイプが行われている場合(S1700:YES)、処理を後述のステップS2000へ進める。化粧画像重畳部150は、顔位置付近で上下スワイプが行われていない場合(S1700:NO)、処理をステップS1800へ進める。   The makeup image superimposing unit 150 advances the process to step S2000 described later when the vertical swipe is performed near the face position (S1700: YES). If the up / down swipe is not performed near the face position (S1700: NO), makeup image superimposing unit 150 advances the process to step S1800.

ステップS1800において、化粧画像重畳部150は、化粧画像重畳部150は、スワイプ開始位置と、スワイプ方向と、各顔のスワイプ開始時位置324(図4参照)とに基づいて、スワイプ方向はいずれかの顔の位置に向かっているか否かを判定する。すなわち、化粧画像重畳部150は、行われたスワイプ操作が、顔方向スワイプ操作であるか否かを判定する。かかる操作は、図5の第1の画面状態411で説明した操作、図5の第3の画面状態413で説明した操作、あるいは、図6の第1の画面状態421で説明した操作に相当する。   In step S1800, the makeup image superimposing unit 150 determines which one of the swipe directions is based on the swipe start position, the swipe direction, and the swipe start position 324 of each face (see FIG. 4). It is determined whether or not the user is facing the position of the face. That is, makeup image superimposing section 150 determines whether or not the performed swipe operation is a face direction swipe operation. Such an operation corresponds to the operation described in the first screen state 411 in FIG. 5, the operation described in the third screen state 413 in FIG. 5, or the operation described in the first screen state 421 in FIG. .

化粧画像重畳部150は、スワイプ方向が顔位置に向かっている場合(S1800:YES)、処理をステップS1900へ進める。また、化粧画像重畳部150は、スワイプ方向が顔位置に向かっていない場合(S1800:NO)、処理を後続のステップS2100へ進める。   If the swipe direction is toward the face position (S1800: YES), makeup image superimposing unit 150 advances the process to step S1900. In addition, makeup image superimposing unit 150 advances the process to subsequent step S2100 when the swipe direction is not directed to the face position (S1800: NO).

ステップS1900において、化粧画像重畳部150は、スワイプ方向が向いている顔について、化粧の有無あるいは濃さを変更し、変更後の化粧設定322を状態記録テーブル320に記録する(図4参照)。かかる化粧の有無あるいは濃さの変更は、図5の第2の画面状態412、あるいは、図5の第4の画面状態414で説明した重畳画像の変更に相当する。   In step S1900, the makeup image superimposing unit 150 changes the presence / absence or darkness of makeup for the face facing the swipe direction, and records the changed makeup setting 322 in the state recording table 320 (see FIG. 4). Such a change in presence / absence or darkness of makeup corresponds to the change in the superimposed image described in the second screen state 412 in FIG. 5 or the fourth screen state 414 in FIG. 5.

一方、ステップS2000において、化粧画像重畳部150は、スワイプ開始位置に最も近い顔について、化粧のパターンを変更し、変更後の化粧設定322を状態記録テーブル320に記録する(図4参照)。かかる化粧のパターンの変更は、図5の第6の画面状態416で説明した重畳画像の変更に相当する。   On the other hand, in step S2000, makeup image superimposing section 150 changes the makeup pattern for the face closest to the swipe start position, and records the changed makeup setting 322 in state recording table 320 (see FIG. 4). The change of the makeup pattern corresponds to the change of the superimposed image described in the sixth screen state 416 in FIG.

ステップS2100において、化粧画像重畳部150は、スワイプ操作が終了したか否かを判定する。スワイプ操作が終了したか否かは、例えば、接触が検出されなくなったか否かに基づいて判定される。   In step S2100, makeup image superimposing unit 150 determines whether or not the swipe operation has ended. Whether or not the swipe operation has ended is determined based on, for example, whether or not contact has been detected.

化粧画像重畳部150は、スワイプ操作が終了した場合(S2100:YES)、処理をステップS2200へ進める。また、化粧画像重畳部150は、スワイプ操作が終了していない場合(S2100:NO)、処理を後述のステップS2300へ進める。   If the swipe operation is completed (S2100: YES), makeup image superimposing unit 150 advances the process to step S2200. If makeup operation is not completed (S2100: NO), makeup image superimposing unit 150 advances the process to step S2300, which will be described later.

ステップS2200において、化粧画像重畳部150は、取得したスワイプ開始位置を破棄し、各顔のスワイプ開始時位置324の記録を状態記録テーブル320から削除する(図4参照)。なお、化粧画像重畳部150は、スワイプ操作が終了したか否かによらず、スワイプ操作が開始されてから所定の時間が経過したとき、対応するスワイプ開始位置を破棄し、スワイプ開始時位置324の記録を削除してもよい。   In step S2200, makeup image superimposing section 150 discards the acquired swipe start position and deletes the record of swipe start position 324 for each face from state record table 320 (see FIG. 4). Note that the makeup image superimposing unit 150 discards the corresponding swipe start position when a predetermined time has elapsed from the start of the swipe operation, regardless of whether or not the swipe operation has ended, and the swipe start time position 324. Records may be deleted.

ステップS2300において、化粧画像重畳部150は、適宜化粧画像を生成して映像に重畳し、バーチャル化粧映像を生成する。表示部160は、生成されたバーチャル化粧映像を表示する。なお、バーチャル化粧映像は、化粧画像が重畳されている映像だけではなく、化粧画像が重畳されていない映像をも含む。   In step S2300, makeup image superimposing section 150 generates a makeup image as appropriate and superimposes it on the video to generate a virtual makeup video. The display unit 160 displays the generated virtual makeup image. Note that the virtual makeup video includes not only a video on which a makeup image is superimposed, but also a video on which a makeup image is not superimposed.

ステップS2400において、化粧画像重畳部150は、ユーザ操作等によりバーチャル化粧映像を生成して表示する処理の終了を指示されたか否かを判定する。化粧画像重畳部150は、処理の終了を指示されていない場合(S2400:NO)、処理をステップS1200へ戻す。また、化粧画像重畳部150は、処理の終了を指示された場合(S2400:YES)、一連の処理を終了する。   In step S2400, makeup image superimposing section 150 determines whether or not an instruction to end a process of generating and displaying a virtual makeup image is made by a user operation or the like. If the makeup image superimposing unit 150 is not instructed to end the process (S2400: NO), the process returns to step S1200. In addition, makeup image superimposing section 150 ends a series of processes when instructed to end the processes (S2400: YES).

図10は、相対位置解析処理(図9のステップS1400)の一例を示すフローチャートである。   FIG. 10 is a flowchart showing an example of the relative position analysis process (step S1400 in FIG. 9).

ステップS1410において、化粧画像重畳部150は、画面に含まれる複数の顔の相対位置関係を取得し、状態記録テーブル320の相対位置325に記録する。かかる相対位置関係の取得は、図8において説明した、相対位置408、408の取得に相当する。 In step S1410, makeup image superimposing unit 150 acquires the relative positional relationship between a plurality of faces included in the screen and records it in relative position 325 of state recording table 320. The acquisition of the relative positional relationship corresponds to the acquisition of the relative positions 408 1 and 408 2 described in FIG.

ステップS1420において、化粧画像重畳部150は、状態記録テーブル320の追跡状態326を参照して、新たに追跡が開始された顔が存在するか否かを判定する。化粧画像重畳部150は、追跡が開始された顔が存在する場合(S1420:YES)、処理をステップS1430へ進める。また、化粧画像重畳部150は、追跡が開始された顔が存在しない場合(S1420:NO)、処理を上述の図9のステップS1500へ進める。   In step S1420, makeup image superimposing section 150 refers to tracking state 326 of state recording table 320, and determines whether or not a face for which tracking has been newly started exists. If there is a face for which tracking has been started (S1420: YES), makeup image superimposing unit 150 advances the process to step S1430. If there is no face for which tracking has been started (S1420: NO), makeup image superimposing section 150 advances the process to step S1500 in FIG. 9 described above.

ステップS1430において、化粧画像重畳部150は、状態記録テーブル320の追跡状態326(図4参照)を参照して、過去に、追跡が終了した顔が存在するか否かを判定する。化粧画像重畳部150は、追跡が終了した顔が存在する場合(S1430:YES)、処理をステップS1440へ進める。また、化粧画像重畳部150は、追跡が終了した顔が存在しない場合(S1430:NO)、処理を上述の図9のステップS1500へ進める。   In step S1430, makeup image superimposing section 150 refers to tracking state 326 (see FIG. 4) in state recording table 320, and determines whether or not there is a face that has been tracked in the past. If there is a face for which tracking has ended (S1430: YES), makeup image superimposing unit 150 advances the process to step S1440. If there is no face for which tracking has been completed (S1430: NO), makeup image superimposing section 150 advances the process to step S1500 in FIG. 9 described above.

ステップS1440において、化粧画像重畳部150は、状態記録テーブル320の相対位置325(図4参照)を参照して、追跡が継続している顔に対する、過去に追跡が終了した顔の相対位置を取得する。そして、化粧画像重畳部150は、追跡が継続している顔に対する、追跡が開始された顔の相対位置が、取得された相対位置と同一であるか否かを判定する。かかる相対位置の判定は、図8において説明した、相対位置408と、相対位置408との比較に相当する。 In step S1440, the makeup image superimposing unit 150 refers to the relative position 325 (see FIG. 4) of the state recording table 320, and acquires the relative position of the face that has been tracked in the past with respect to the face that has been tracked. To do. Then, makeup image superimposing unit 150 determines whether or not the relative position of the face for which tracking has been started is the same as the acquired relative position with respect to the face that is being tracked. The determination of the relative position corresponds to the comparison between the relative position 408 1 and the relative position 408 2 described in FIG.

化粧画像重畳部150は、相対位置と同一である場合(S1440:YES)、処理をステップS1450へ進める。また、化粧画像重畳部150は、相対位置と同一ではない場合(S1440:NO)、処理を上述の図9のステップS1500へ進める。   If makeup image superimposing section 150 is the same as the relative position (S1440: YES), processing proceeds to step S1450. If makeup image superimposing section 150 is not the same as the relative position (S1440: NO), processing proceeds to step S1500 in FIG. 9 described above.

ステップS1450において、化粧画像重畳部150は、追跡が開始された顔に、過去に追跡が終了した顔の化粧設定を適用し、記録する。すなわち、化粧画像重畳部150は、状態記録テーブル320において、過去に追跡が終了した顔の化粧設定322を、追跡が開始された顔の化粧設定322に記述する。そして、化粧画像重畳部150は、処理を上述の図9のステップS1500へ進める。   In step S1450, makeup image superimposing unit 150 applies and records the makeup setting of the face that has been tracked in the past to the face for which tracking has been started. That is, makeup image superimposing unit 150 describes face makeup setting 322 for which tracking has been completed in the state recording table 320 as face makeup setting 322 for which tracking has been started. Then, makeup image superimposing unit 150 advances the process to step S1500 in FIG. 9 described above.

このような動作により、画像処理装置100は、顔領域を指で遮蔽せず、画面における顔位置のぶれに影響されず、かつ、複数の顔のうちの1つが一時的に画面から外れてしまっても化粧設定が維持されるようなバーチャル化粧操作を、実現することができる。   By such an operation, the image processing apparatus 100 does not shield the face area with a finger, is not affected by the movement of the face position on the screen, and one of the plurality of faces temporarily comes off the screen. However, it is possible to realize a virtual makeup operation in which makeup settings are maintained.

<本実施の形態の効果>
以上説明したように、本実施の形態に係る画像処理装置100は、画面において顔方向スワイプ操作が行われたことを条件として、映像に含まれる顔への化粧画像の重畳の状態を変更することができる。すなわち、画像処理装置100を用いることにより、ユーザは、顔が映し出されている領域を指で遮蔽せずに、化粧画像の重畳の状態を変更する操作を行うことができ、顔の見栄えを画面の映像で確認しながら自分撮りを行うことができる。したがって、画像処理装置100は、自分撮りをしながらのバーチャル化粧操作を可能にする。
<Effects of the present embodiment>
As described above, the image processing apparatus 100 according to the present embodiment changes the state of superimposition of the makeup image on the face included in the video on the condition that the face direction swipe operation is performed on the screen. Can do. That is, by using the image processing apparatus 100, the user can perform an operation of changing the superimposition state of the makeup image without shielding the area where the face is projected with a finger, and the appearance of the face can be displayed on the screen. You can take a selfie while checking on the video. Therefore, the image processing apparatus 100 enables a virtual makeup operation while taking a selfie.

また、本実施の形態に係る画像処理装置100は、スワイプ操作を含むタッチ操作が開始されたときの顔の位置を基準として、タッチ操作の対象を決定する。これにより、画像処理装置100は、被写体あるいは画像処理装置100の動きに起因する画面上の顔の位置のぶれに影響されずに、ユーザが望む操作を実現することができる。   In addition, the image processing apparatus 100 according to the present embodiment determines the target of the touch operation based on the position of the face when the touch operation including the swipe operation is started. As a result, the image processing apparatus 100 can realize an operation desired by the user without being affected by the movement of the face position on the screen due to the subject or the movement of the image processing apparatus 100.

また、本実施の形態に係る画像処理装置100は、画面に複数の顔が含まれるときその相対位置関係を取得し、位置の追跡が継続しているか否か、および、相対位置関係が維持されているか否か、に基づいて、顔毎に、化粧設定を維持するか否かを判断する。これにより、画像処理装置100は、画像処理装置100の動きに起因して、複数の顔のいずれかが一時的に画面から外れてしまった場合でも、ユーザが設定した化粧画像をその顔に継続して重畳することができる。   Further, the image processing apparatus 100 according to the present embodiment acquires the relative positional relationship when a plurality of faces are included on the screen, whether the position tracking is continued, and the relative positional relationship is maintained. It is determined whether or not the makeup setting is maintained for each face based on whether or not the face is on. As a result, the image processing apparatus 100 continues the makeup image set by the user to the face even if any of the plurality of faces temporarily falls off the screen due to the movement of the image processing apparatus 100. And can be superimposed.

すなわち、本実施の形態に係る画像処理装置100によれば、従来技術に比べて、よりシンプルかつ直感的なバーチャル化粧操作インタフェースを実現することができる。   That is, according to the image processing apparatus 100 according to the present embodiment, a simpler and more intuitive virtual makeup operation interface can be realized as compared with the prior art.

<本実施の形態の変形例>
なお、スワイプ操作の対象となる顔の決定手法は、上述の例に限定されない。化粧画像重畳部150は、例えば、顔の位置に向かう方向のスワイプ操作が行われた位置と、顔の位置との間の画面における距離が、所定の閾値以下であることを条件として、化粧画像の重畳の状態を変更してもよい。
<Modification of the present embodiment>
Note that the method of determining the face that is the target of the swipe operation is not limited to the above example. The makeup image superimposing unit 150, for example, on the condition that the distance on the screen between the position where the swipe operation in the direction toward the face position is performed and the position of the face is equal to or less than a predetermined threshold value. You may change the state of superimposition.

また、化粧画像重畳部150は、例えば、画面に含まれる複数の顔の位置に向かう方向にスワイプ操作が行われたとき、当該複数の顔のうち、当該スワイプ操作が行われた位置との画面における距離が最も短い顔を、化粧画像の重畳の状態を変更する対象としてもよい。   For example, when the swipe operation is performed in the direction toward the positions of the plurality of faces included in the screen, the makeup image superimposing unit 150 displays the screen with the position where the swipe operation is performed among the plurality of faces. The face with the shortest distance may be the target for changing the superimposed state of the makeup image.

また、化粧画像重畳部150は、例えば、スワイプ操作の顔位置との方向差と、スワイプ操作の顔位置との距離とに基づいて、顔を化粧画像の重畳の状態を変更する対象とするか否かを決定してもよい。より具体的には、化粧画像重畳部150は、例えば、方向差に第1の係数を乗じた値と距離に第2の係数を乗じた値とを加算して得られる値が、所定の閾値以下であることを、化粧画像の重畳の状態を変更する対象となる顔の条件とする。ここで、方向差とは、画面における、スワイプ操作のスワイプ方向と、スワイプ操作が行われた位置に対する顔の方向との間の方向差である。また、距離とは、スワイプ操作が行われた位置と顔の位置との間の距離である。なお、スワイプ操作が行われた位置とは、スワイプ操作の開始位置、終了位置、あるいはスワイプ操作全体の接触領域の重心位置等である。   Also, the makeup image superimposing unit 150 sets the face as a target for changing the superposition state of the makeup image based on, for example, the direction difference from the face position of the swipe operation and the distance from the face position of the swipe operation. You may decide whether or not. More specifically, the makeup image superimposing unit 150, for example, has a predetermined threshold value obtained by adding a value obtained by multiplying the direction difference by a first coefficient and a value obtained by multiplying the distance by a second coefficient. The following conditions are used as the condition of the face to be changed in the makeup image superimposition state. Here, the direction difference is a direction difference between the swipe direction of the swipe operation on the screen and the face direction with respect to the position where the swipe operation is performed. The distance is a distance between the position where the swipe operation is performed and the position of the face. Note that the position where the swipe operation is performed is the start position and end position of the swipe operation, or the center of gravity position of the contact area of the entire swipe operation.

また、化粧画像の重畳の状態の変更の仕方は、上述の例に限定されない。化粧画像重畳部150は、例えば、化粧画像が重畳されている顔の位置に向かう方向にスワイプ操作が行われたとき、化粧パターンを変更してもよい。   Further, the method of changing the makeup image superimposition state is not limited to the above example. For example, the makeup image superimposing unit 150 may change the makeup pattern when a swipe operation is performed in a direction toward the face position on which the makeup image is superimposed.

また、化粧画像データの数および内容は、上述の例に限定されない。化粧画像情報310は、例えば、4つ以上の化粧パターンおよび4つ以上の化粧濃さの組み合わせについて、化粧画像データを記述していてもよい。また、化粧画像情報310は、例えば、化粧パターンおよび化粧濃さのうち少なくとも1つについて、1種類のみの化粧画像データを記述していてもよい。更に、化粧画像情報310は、男性用メイクと女性用メイクというように、化粧の対象に応じて異なる化粧画像データを記述していてもよい。この場合、化粧画像重畳部150は、化粧の対象を切り替える操作を認識する必要がある。   Further, the number and contents of the makeup image data are not limited to the above example. The makeup image information 310 may describe makeup image data for combinations of four or more makeup patterns and four or more makeup densities, for example. Further, the makeup image information 310 may describe only one type of makeup image data for at least one of the makeup pattern and the makeup density, for example. Further, the makeup image information 310 may describe different makeup image data depending on the makeup object, such as male makeup and female makeup. In this case, the makeup image superimposing unit 150 needs to recognize an operation for switching the makeup target.

また、スワイプ操作以外で受け付けるタッチ操作は、上述の例に限定されない。化粧画像重畳部150は、例えば、化粧画像が重畳されている顔に対して、顔に丸印を付けるタッチ操作が行われたとき、化粧パターンや化粧濃さを変更してもよい。   Further, the touch operation accepted other than the swipe operation is not limited to the above example. For example, the makeup image superimposing unit 150 may change the makeup pattern and the makeup density when a touch operation for marking a face with a circle is performed on the face on which the makeup image is superimposed.

また、タッチ操作が開始されたときの顔の位置を基準としてタッチ操作の対象を決定する手法は、スワイプ操作以外の各種タッチ操作に適用してもよい。   Further, the method for determining the target of the touch operation based on the position of the face when the touch operation is started may be applied to various touch operations other than the swipe operation.

また、タッチ操作が開始されたときの顔の位置を基準としてタッチ操作の対象を決定するための手法は、上述の例に限定されない。化粧画像重畳部150は、例えば、タッチ操作が開始されてからタッチ操作が完了するまでの間、映像と、顔位置および顔部品位置を示す情報の入力(更新)を停止してもよい。また、かかる情報の入力の停止は、撮影部110および顔位置取得部140が、操作情報を取得して行ってもよい。   Further, the method for determining the target of the touch operation on the basis of the position of the face when the touch operation is started is not limited to the above example. For example, the makeup image superimposing unit 150 may stop inputting (updating) the video and information indicating the face position and the face part position from when the touch operation is started until the touch operation is completed. Further, the stop of the input of information may be performed by the photographing unit 110 and the face position acquisition unit 140 acquiring operation information.

また、画面から外れた顔に対する化粧設定の維持の手法は、上述の例に限定されない。化粧画像重畳部150は、例えば、画面からいずれかの顔が外れた場合、追跡が継続している顔の位置を基準として、最後に画面に映し出されていたときの当該顔の相対位置を、所定のタイムアウト時間が経過するまで保持していてもよい。この場合、タイムアウト時間が経過する前に、画面から外れた顔が画面内に戻ってきたとき、当該顔の追跡が継続されることになる。   Further, the method for maintaining the makeup setting for a face that is off the screen is not limited to the above example. For example, when any face is removed from the screen, the makeup image superimposing unit 150 uses the position of the face that is being tracked as a reference, and the relative position of the face that was last displayed on the screen, You may hold | maintain until predetermined | prescribed timeout time passes. In this case, when a face that is off the screen returns to the screen before the timeout time elapses, the tracking of the face is continued.

あるいは、化粧画像重畳部150は、複数の顔の間の相対位置関係によらず、位置の追跡が開始された顔に対して、過去の所定の時間内(例えば3秒以内)に位置の追跡が終了した顔の化粧設定を適用してもよい。例えば、映像に映り込む顔が1つしかない等、一時に映像から外れる顔が1つのみである場合、化粧設定を適切に保持することができる。   Alternatively, the makeup image superimposing unit 150 tracks the position within a predetermined past time (for example, within 3 seconds) with respect to the face whose position has been started, regardless of the relative positional relationship between the plurality of faces. You may apply the makeup setting of the face for which is finished. For example, when there is only one face that is removed from the video at a time, such as when there is only one face reflected in the video, the makeup setting can be appropriately maintained.

また、化粧画像重畳部150は、化粧パターンや化粧濃さの変更を行ったとき、当該変更が行われたことを、ユーザに通知してもよい。当該通知はユーザが認識し易いものであることが望ましく、例えば、化粧画像の点滅や色変化、点滅する星画像等の効果画像の表示、あるいは星がきらめくような音等の効果音の出力といった、各種エフェクト処理により行うことができる。   Further, when the makeup image superimposing unit 150 changes the makeup pattern or the makeup density, the makeup image superimposing unit 150 may notify the user that the modification has been performed. The notification is preferably easy to recognize by the user, for example, blinking or color change of a makeup image, display of an effect image such as a blinking star image, or output of a sound effect such as a sound that makes a star glitter. It can be performed by various effect processes.

また、画像処理装置100が適用される装置は、上述の例に限定されない。画像処理装置100は、例えば、タブレット型端末、パーソナルコンピュータ、あるいはデジタルカメラ等に適用されてもよい。   The apparatus to which the image processing apparatus 100 is applied is not limited to the above-described example. The image processing apparatus 100 may be applied to, for example, a tablet terminal, a personal computer, or a digital camera.

また、画像処理装置100の構成の一部は、ネットワーク上のサーバ等に配置される等して、画像処理装置100の構成の他の部分と離隔していてもよい。この場合、これら部分のそれぞれは、互いに通信を行うための通信部を備える必要がある。   In addition, a part of the configuration of the image processing apparatus 100 may be separated from other parts of the configuration of the image processing apparatus 100 by being arranged in a server or the like on a network. In this case, each of these portions needs to include a communication unit for performing communication with each other.

<本開示のまとめ>
本開示の画像処理装置は、映像を撮影する撮影部と、撮影された前記映像を画面に表示する表示部と、前記映像に含まれる顔の前記画面における位置を取得する顔位置取得部と、前記画面に対するタッチ操作を受け付ける操作受付部と、前記映像の前記顔の部分に対して化粧画像を重畳する化粧画像重畳部と、を有し、前記化粧画像重畳部は、前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記化粧画像の重畳の状態を変更する。
<Summary of this disclosure>
An image processing apparatus of the present disclosure includes a photographing unit that captures a video, a display unit that displays the captured video on a screen, a face position acquisition unit that acquires a position of the face included in the video on the screen, An operation accepting unit that accepts a touch operation on the screen; and a makeup image superimposing unit that superimposes a makeup image on the face portion of the video, the makeup image superimposing unit heading toward the face position. On the condition that the swipe operation is performed in the direction, the superimposing state of the makeup image is changed.

なお、上記画像処理装置において、前記化粧画像重畳部は、前記顔の位置に向かう方向のスワイプ操作が行われた位置と前記顔の位置との間の前記画面における距離が、所定の閾値以下であることを条件として、前記化粧画像の重畳の状態を変更してもよい。   In the image processing apparatus, the makeup image superimposing unit is configured such that a distance on the screen between the position where the swipe operation in the direction toward the face position is performed and the face position is a predetermined threshold value or less. The superposition state of the makeup image may be changed on the condition that it exists.

また、上記画像処理装置において、前記化粧画像重畳部は、前記画面に複数の顔が含まれている状態で、前記複数の顔の位置に向かう方向にスワイプ操作が行われたとき、当該複数の顔のうち、当該スワイプ操作が行われた位置との前記画面における距離が最も短い前記顔を、前記化粧画像の重畳の状態を変更する対象としてもよい。   In the image processing apparatus, the makeup image superimposing unit may be configured such that when a swipe operation is performed in a direction toward the positions of the plurality of faces while the screen includes a plurality of faces, Of the faces, the face having the shortest distance on the screen from the position where the swipe operation is performed may be the target for changing the makeup image superposition state.

また、上記画像処理装置において、前記化粧画像重畳部は、前記画面における、スワイプ操作のスワイプ方向と前記スワイプ操作が行われた位置に対する前記顔の方向との間の方向差と、前記スワイプ操作が行われた位置と前記顔の位置との間の距離と、に基づいて、前記顔を前記化粧画像の重畳の状態を変更する対象とするか否かを決定してもよい。   In the image processing apparatus, the makeup image superimposing unit may be configured such that a direction difference between a swipe direction of a swipe operation on the screen and a face direction with respect to a position where the swipe operation is performed, and the swipe operation is performed. Based on the distance between the performed position and the position of the face, it may be determined whether or not the face is to be a target for changing the superposition state of the makeup image.

また、上記画像処理装置において、前記化粧画像重畳部は、初期状態において、前記顔の部分に対して前記化粧画像を重畳せず、前記化粧画像が重畳されていない前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記化粧画像の重畳を開始させ、前記化粧画像が重畳されている前記顔の位置に向かう方向のうち第1の方向にスワイプ操作が行われたことを条件として、重畳されている前記化粧画像を、当該前記化粧画像とは異なる第1の化粧画像に変更し、第2の方向にスワイプ操作が行われたことを条件として、重畳されている前記化粧画像を、当該前記化粧画像とは異なる第2の化粧画像に変更してもよい。   Further, in the image processing device, the makeup image superimposing unit does not superimpose the makeup image on the face portion in an initial state, and moves in a direction toward the face position where the makeup image is not superimposed. On the condition that the swipe operation has been performed, the superimposition of the makeup image is started, and the swipe operation has been performed in the first direction among the directions toward the face position on which the makeup image is superimposed. As a condition, the superimposed makeup image is changed to a first makeup image different from the makeup image and a swipe operation is performed in the second direction. The image may be changed to a second makeup image different from the makeup image.

また、上記画像処理装置において、前記第1の化粧画像は、重畳されている前記化粧画像とは化粧の濃さが異なり、前記第2の化粧画像は、重畳されている前記化粧画像とは化粧のパターンが異なってもよい。   In the image processing apparatus, the first makeup image has a makeup intensity different from that of the superimposed makeup image, and the second makeup image differs from the makeup image superimposed. The pattern may be different.

また、上記画像処理装置において、前記第2の方向は、上方向および下方向のうち少なくとも1つであってもよい。   In the image processing apparatus, the second direction may be at least one of an upward direction and a downward direction.

また、上記画像処理装置において、前記化粧画像重畳部は、タッチ操作が開始されたときの前記顔の位置を基準として、前記タッチ操作の対象を決定してもよい。   In the image processing apparatus, the makeup image superimposing unit may determine the target of the touch operation on the basis of the position of the face when the touch operation is started.

また、上記画像処理装置において、前記化粧画像重畳部は、スワイプ操作が開始されたときの前記顔の位置を基準として、前記顔の位置に向かう方向にスワイプ操作が行われたか否かを判定してもよい。   Further, in the image processing device, the makeup image superimposing unit determines whether or not the swipe operation is performed in a direction toward the face position with reference to the position of the face when the swipe operation is started. May be.

また、上記画像処理装置において、前記顔位置取得部は、前記映像において、前記顔毎に前記位置を追跡し、前記化粧画像重畳部は、前記位置の追跡が開始された顔に対して、過去に前記位置の追跡が終了した顔の化粧設定を適用してもよい。   In the image processing apparatus, the face position acquisition unit tracks the position for each face in the video, and the makeup image superimposing unit applies the past to the face whose position has been started. The face makeup setting for which the tracking of the position has ended may be applied.

また、上記画像処理装置において、前記顔位置取得部は、前記映像において、前記顔毎に前記位置を追跡し、前記化粧画像重畳部は、前記画面に複数の顔が含まれるとき、当該複数の顔の相対位置関係を取得し、前記位置の追跡が継続しているか否か、および、前記相対位置関係が維持されているか否か、に基づいて、前記顔毎に、当該顔の化粧設定を維持するか否かを判断してもよい。   In the image processing device, the face position acquisition unit tracks the position for each face in the video, and the makeup image superimposing unit includes the plurality of faces when the screen includes a plurality of faces. Based on whether the relative positional relationship of the face is acquired, and tracking of the position is continued, and whether the relative positional relationship is maintained, the makeup setting of the face is set for each face. It may be determined whether or not to maintain.

また、上記画像処理装置において、前記化粧画像重畳部は、前記位置の追跡が継続している第1の顔と、前記位置の追跡が終了した第2の顔と、前記第2の顔の追跡が終了した後に前記位置の追跡が開始された第3の顔と、が存在し、前記第1の顔に対する前記第2の顔の相対位置と、前記第1の顔に対する前記第3の顔の相対位置と、が同一であることを条件として、前記第2の顔の前記化粧設定を、前記第3の顔に適用してもよい。   In the image processing apparatus, the makeup image superimposing unit may be configured to track the first face whose position is being tracked, the second face whose position is being tracked, and the second face. A third face for which tracking of the position is started after the end of the first face, a relative position of the second face with respect to the first face, and a third face of the third face with respect to the first face The makeup setting of the second face may be applied to the third face on condition that the relative position is the same.

また、上記画像処理装置において、前記相対位置関係は、鉛直方向を基準とする相対位置関係であってもよい。   In the image processing apparatus, the relative positional relationship may be a relative positional relationship based on a vertical direction.

本開示の画像処理方法は、映像を撮影するステップと、撮影された前記映像を画面に表示するステップと、前記映像に含まれる顔の前記画面における位置を取得するステップと、前記画面に対するタッチ操作を受け付けるステップと、前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記映像の前記顔の部分に対して化粧画像を重畳させるステップと、を有する。   The image processing method of the present disclosure includes a step of capturing a video, a step of displaying the captured video on a screen, a step of acquiring a position of the face included in the video on the screen, and a touch operation on the screen And a step of superimposing a makeup image on the face portion of the video on the condition that a swipe operation is performed in a direction toward the face position.

本発明は、自分撮りをしながらのバーチャル化粧操作を可能にする画像処理装置および画像処理方法として有用である。   The present invention is useful as an image processing apparatus and an image processing method that enable a virtual makeup operation while taking a selfie.

100 画像処理装置
110 撮影部
120 操作受付部
130 情報格納部
140 顔位置取得部
150 化粧画像重畳部
160 表示部
DESCRIPTION OF SYMBOLS 100 Image processing apparatus 110 Image pick-up part 120 Operation reception part 130 Information storage part 140 Face position acquisition part 150 Makeup image superimposition part 160 Display part

Claims (14)

映像を撮影する撮影部と、
撮影された前記映像を画面に表示する表示部と、
前記映像に含まれる顔の前記画面における位置を取得する顔位置取得部と、
前記画面に対するタッチ操作を受け付ける操作受付部と、
前記映像の前記顔の部分に対して化粧画像を重畳する化粧画像重畳部と、を有し、
前記化粧画像重畳部は、
前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記化粧画像の重畳の状態を変更する、
画像処理装置。
A shooting section for shooting images;
A display unit for displaying the captured video on a screen;
A face position acquisition unit for acquiring a position of the face included in the video on the screen;
An operation receiving unit for receiving a touch operation on the screen;
A makeup image superimposing unit that superimposes a makeup image on the face portion of the video,
The makeup image superimposing unit is
Changing the overlay state of the makeup image on the condition that a swipe operation has been performed in a direction toward the face position;
Image processing device.
前記化粧画像重畳部は、
前記顔の位置に向かう方向のスワイプ操作が行われた位置と前記顔の位置との間の前記画面における距離が、所定の閾値以下であることを条件として、前記化粧画像の重畳の状態を変更する、
請求項1に記載の画像処理装置。
The makeup image superimposing unit is
The makeup image superposition state is changed on the condition that the distance on the screen between the position where the swipe operation in the direction toward the face position is performed and the face position is equal to or less than a predetermined threshold. To
The image processing apparatus according to claim 1.
前記化粧画像重畳部は、
前記画面に複数の顔が含まれている状態で、前記複数の顔の位置に向かう方向にスワイプ操作が行われたとき、当該複数の顔のうち、当該スワイプ操作が行われた位置との前記画面における距離が最も短い前記顔を、前記化粧画像の重畳の状態を変更する対象とする、
請求項1に記載の画像処理装置。
The makeup image superimposing unit is
When a swipe operation is performed in a direction toward the positions of the plurality of faces in a state where the screen includes a plurality of faces, the position of the plurality of faces with the position where the swipe operation is performed The face with the shortest distance on the screen is a target for changing the superposition state of the makeup image,
The image processing apparatus according to claim 1.
前記化粧画像重畳部は、
前記画面における、スワイプ操作のスワイプ方向と前記スワイプ操作が行われた位置に対する前記顔の方向との間の方向差と、前記スワイプ操作が行われた位置と前記顔の位置との間の距離と、に基づいて、前記顔を前記化粧画像の重畳の状態を変更する対象とするか否かを決定する、
請求項1に記載の画像処理装置。
The makeup image superimposing unit is
A direction difference between the swipe direction of the swipe operation and the face direction with respect to the position where the swipe operation is performed on the screen, and a distance between the position where the swipe operation is performed and the position of the face Based on the above, it is determined whether or not the face is a target for changing the state of superimposition of the makeup image.
The image processing apparatus according to claim 1.
前記化粧画像重畳部は、
初期状態において、前記顔の部分に対して前記化粧画像を重畳せず、前記化粧画像が重畳されていない前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記化粧画像の重畳を開始させ、前記化粧画像が重畳されている前記顔の位置に向かう方向のうち第1の方向にスワイプ操作が行われたことを条件として、重畳されている前記化粧画像を、当該前記化粧画像とは異なる第1の化粧画像に変更し、第2の方向にスワイプ操作が行われたことを条件として、重畳されている前記化粧画像を、当該前記化粧画像とは異なる第2の化粧画像に変更する、
請求項1に記載の画像処理装置。
The makeup image superimposing unit is
In the initial state, on the condition that the makeup image is not superimposed on the face portion, and a swipe operation is performed in a direction toward the face where the makeup image is not superimposed, Superimposition is started, and on the condition that the swipe operation is performed in the first direction among the directions toward the face position on which the makeup image is superimposed, the superimposed makeup image is displayed on the makeup A second makeup image that is different from the makeup image is changed to a first makeup image that is different from the image, and on the condition that the swipe operation is performed in the second direction. Change to
The image processing apparatus according to claim 1.
前記第1の化粧画像は、重畳されている前記化粧画像とは化粧の濃さが異なり、前記第2の化粧画像は、重畳されている前記化粧画像とは化粧のパターンが異なる、
請求項5に記載の画像処理装置。
The first makeup image has a makeup darkness different from the superimposed makeup image, and the second makeup image has a makeup pattern different from the superimposed makeup image,
The image processing apparatus according to claim 5.
前記第2の方向は、上方向および下方向のうち少なくとも1つである、
請求項6に記載の画像処理装置。
The second direction is at least one of an upward direction and a downward direction.
The image processing apparatus according to claim 6.
前記化粧画像重畳部は、
タッチ操作が開始されたときの前記顔の位置を基準として、前記タッチ操作の対象を決定する、
請求項1に記載の画像処理装置。
The makeup image superimposing unit is
Determining a target of the touch operation based on the position of the face when the touch operation is started;
The image processing apparatus according to claim 1.
前記化粧画像重畳部は、
スワイプ操作が開始されたときの前記顔の位置を基準として、前記顔の位置に向かう方向にスワイプ操作が行われたか否かを判定する、
請求項7に記載の画像処理装置。
The makeup image superimposing unit is
It is determined whether or not a swipe operation is performed in a direction toward the face position with reference to the position of the face when the swipe operation is started.
The image processing apparatus according to claim 7.
前記顔位置取得部は、
前記映像において、前記顔毎に前記位置を追跡し、
前記化粧画像重畳部は、
前記位置の追跡が開始された顔に対して、過去に前記位置の追跡が終了した顔の化粧設定を適用する、
請求項1に記載の画像処理装置。
The face position acquisition unit
In the video, track the position for each face,
The makeup image superimposing unit is
Applying the makeup setting of the face whose position has been tracked in the past to the face whose position has been tracked,
The image processing apparatus according to claim 1.
前記顔位置取得部は、
前記映像において、前記顔毎に前記位置を追跡し、
前記化粧画像重畳部は、
前記画面に複数の顔が含まれるとき、当該複数の顔の相対位置関係を取得し、前記位置の追跡が継続しているか否か、および、前記相対位置関係が維持されているか否か、に基づいて、前記顔毎に、当該顔の化粧設定を維持するか否かを判断する、
請求項1に記載の画像処理装置。
The face position acquisition unit
In the video, track the position for each face,
The makeup image superimposing unit is
When a plurality of faces are included in the screen, the relative positional relationship between the plurality of faces is acquired, whether the tracking of the position is continued, and whether the relative positional relationship is maintained. Based on each face, determine whether to maintain the makeup settings of the face,
The image processing apparatus according to claim 1.
前記化粧画像重畳部は、
前記位置の追跡が継続している第1の顔と、前記位置の追跡が終了した第2の顔と、前記第2の顔の追跡が終了した後に前記位置の追跡が開始された第3の顔と、が存在し、前記第1の顔に対する前記第2の顔の相対位置と、前記第1の顔に対する前記第3の顔の相対位置と、が同一であることを条件として、前記第2の顔の前記化粧設定を、前記第3の顔に適用する、
請求項11に記載の画像処理装置。
The makeup image superimposing unit is
A first face on which tracking of the position continues, a second face on which tracking of the position has ended, and a third face on which tracking of the position has started after the tracking of the second face has ended. And the relative position of the second face with respect to the first face and the relative position of the third face with respect to the first face are the same. Applying the makeup settings of the second face to the third face;
The image processing apparatus according to claim 11.
前記相対位置関係は、鉛直方向を基準とする相対位置関係である、
請求項11に記載の画像処理装置。
The relative positional relationship is a relative positional relationship with respect to the vertical direction.
The image processing apparatus according to claim 11.
映像を撮影するステップと、
撮影された前記映像を画面に表示するステップと、
前記映像に含まれる顔の前記画面における位置を取得するステップと、
前記画面に対するタッチ操作を受け付けるステップと、
前記顔の位置に向かう方向にスワイプ操作が行われたことを条件として、前記映像の前記顔の部分に対して化粧画像を重畳させるステップと、を有する、
画像処理方法。
A step of shooting a video;
Displaying the captured video on a screen;
Obtaining a position on the screen of a face included in the video;
Receiving a touch operation on the screen;
Superimposing a makeup image on the face portion of the video on the condition that a swipe operation has been performed in a direction toward the face position,
Image processing method.
JP2015015361A 2015-01-29 2015-01-29 Image processing apparatus and image processing method Active JP6485629B2 (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
JP2015015361A JP6485629B2 (en) 2015-01-29 2015-01-29 Image processing apparatus and image processing method
PCT/JP2016/000234 WO2016121329A1 (en) 2015-01-29 2016-01-19 Image processing device, stylus, and image processing method
CN201680004714.7A CN107111861B (en) 2015-01-29 2016-01-19 Image processing apparatus, stylus pen, and image processing method
US15/003,183 US9984281B2 (en) 2015-01-29 2016-01-21 Image processing apparatus, stylus, and image processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2015015361A JP6485629B2 (en) 2015-01-29 2015-01-29 Image processing apparatus and image processing method

Publications (2)

Publication Number Publication Date
JP2016139381A JP2016139381A (en) 2016-08-04
JP6485629B2 true JP6485629B2 (en) 2019-03-20

Family

ID=56560376

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2015015361A Active JP6485629B2 (en) 2015-01-29 2015-01-29 Image processing apparatus and image processing method

Country Status (1)

Country Link
JP (1) JP6485629B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109288233A (en) * 2017-07-25 2019-02-01 丽宝大数据股份有限公司 It is signable to repair the biological information analytical equipment for holding region
JP7314767B2 (en) * 2019-10-30 2023-07-26 大日本印刷株式会社 IMAGE PROCESSING APPARATUS, PRINT MAKING SYSTEM AND PRINT MAKING METHOD
CN112508777A (en) * 2020-12-18 2021-03-16 咪咕文化科技有限公司 Beautifying method, electronic equipment and storage medium

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2189198B1 (en) * 2008-11-20 2017-06-21 Braun GmbH Personal body care device
US9224248B2 (en) * 2012-07-12 2015-12-29 Ulsee Inc. Method of virtual makeup achieved by facial tracking
US9603437B2 (en) * 2013-04-08 2017-03-28 Panasonic Intellectual Property Corporation Of America Image processing device, image processing method, and program, capable of virtual reproduction of makeup application state

Also Published As

Publication number Publication date
JP2016139381A (en) 2016-08-04

Similar Documents

Publication Publication Date Title
WO2016121329A1 (en) Image processing device, stylus, and image processing method
JP6435516B2 (en) Makeup support device, makeup support method, and makeup support program
US20240193833A1 (en) System and method for digital makeup mirror
JP5991536B2 (en) Makeup support device, makeup support method, and makeup support program
JP6264665B2 (en) Image processing method and image processing apparatus
TWI651640B (en) Organize digital notes on the user interface
US9846803B2 (en) Makeup supporting device, makeup supporting system, makeup supporting method, and non-transitory computer-readable recording medium
US8941687B2 (en) System and method of user interaction for augmented reality
US9055267B2 (en) System and method of input processing for augmented reality
JP6731616B2 (en) Virtual makeup device, virtual makeup method, and virtual makeup program
US20140184644A1 (en) Rendering augmented reality based on foreground object
US10373348B2 (en) Image processing apparatus, image processing system, and program
JP2016509293A5 (en)
JP5769277B2 (en) Input device, input method, and program
WO2018076622A1 (en) Image processing method and device, and terminal
JP6485629B2 (en) Image processing apparatus and image processing method
WO2018005884A1 (en) System and method for digital makeup mirror
JP2014157557A (en) Image generation device, image generation method and program
TW200534705A (en) A specific image extraction method, storage medium and image pickup device using the same
JP2010066853A (en) Image processing device, method and program
WO2018059258A1 (en) Implementation method and apparatus for providing palm decoration virtual image using augmented reality technology
CN110246206B (en) Eyebrow penciling assisting method, device and system
JP5741660B2 (en) Image processing apparatus, image processing method, and program
JP2012065049A (en) Image processing device and image processing method
JP2017004258A (en) Image processing apparatus, image processing method, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180125

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20190205

R151 Written notification of patent or utility model registration

Ref document number: 6485629

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151