Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP6928772B2 - Image processing device - Google Patents
[go: Go Back, main page]

JP6928772B2 - Image processing device - Google Patents

Image processing device Download PDF

Info

Publication number
JP6928772B2
JP6928772B2 JP2017117786A JP2017117786A JP6928772B2 JP 6928772 B2 JP6928772 B2 JP 6928772B2 JP 2017117786 A JP2017117786 A JP 2017117786A JP 2017117786 A JP2017117786 A JP 2017117786A JP 6928772 B2 JP6928772 B2 JP 6928772B2
Authority
JP
Japan
Prior art keywords
image
enlarged
interlaced
interlaced image
original
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
JP2017117786A
Other languages
Japanese (ja)
Other versions
JP2018117334A (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.)
Noritsu Precision Co Ltd
Original Assignee
Noritsu Precision 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 Noritsu Precision Co Ltd filed Critical Noritsu Precision Co Ltd
Publication of JP2018117334A publication Critical patent/JP2018117334A/en
Application granted granted Critical
Publication of JP6928772B2 publication Critical patent/JP6928772B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Processing (AREA)
  • Television Systems (AREA)
  • Editing Of Facsimile Originals (AREA)
  • Image Analysis (AREA)

Description

本発明は、拡大インターレース画像からオリジナルインターレース画像を復元する画像処理装置、プログラム及び方法に関する。なお、オリジナルインターレース画像を復元することには、オリジナルインターレース画像に含まれるフィールド画像を復元することが含まれる。 The present invention relates to an image processing apparatus, program and method for restoring an original interlaced image from an enlarged interlaced image. Restoring the original interlaced image includes restoring the field image included in the original interlaced image.

周知のとおり、インターレース画像とは、2枚のフィールド画像を一方が奇数行を構成し、他方が偶数行を構成するように交互に合成した画像である。そのため、2枚のフィールド画像に時間差があり、被写体が動いている場合、インターレース画像には奇数行と偶数行とで同じ被写体が移動方向に互い違いにずれて写り、コーミングノイズと呼ばれる横方向の縞模様が現れる。 As is well known, an interlaced image is an image in which two field images are alternately combined so that one constitutes an odd number of rows and the other constitutes an even number of rows. Therefore, when there is a time lag between the two field images and the subject is moving, the same subject appears in the interlaced image with the odd-numbered rows and even-numbered rows staggered in the moving direction, and horizontal stripes called combing noise appear. A pattern appears.

映像の鮮明化の手法には、例えば、明るさやコントラストの調整、鮮やかさや色合いの調整、ノイズ除去、シャープネス、ぶれやボケの補正、拡大、歪曲補正やあおり補正等の様々な種類がある。しかしながら、これらの処理は、場合によっては映像が持つ問題点を強調したり、周囲に分散させたりし、むしろ画質を劣化させることがある。例えば、インターレース画像をインターレース解除せずに、すなわち、2枚のフィールド画像に分離せずにシャープネスや歪曲補正等の処理を実行すると、コーミングノイズが強調されたり、変形したりするため、明らかに画質が劣化する。従って、インターレース画像は、鮮明化の処理を行う前にインターレースを解除しておくことが好ましい。なお、インターレース画像は、上記のとおり、2枚のフィールド画像が交互に配列されるという規則性を有するため、この規則性に従えば、容易にインターレースを解除することができる(例えば、特許文献1参照)。 There are various types of image sharpening methods, such as brightness and contrast adjustment, vividness and hue adjustment, noise removal, sharpness, blur and blur correction, enlargement, distortion correction, and tilt correction. However, in some cases, these processes may emphasize the problems of the image or disperse it in the surroundings, and rather deteriorate the image quality. For example, if the interlaced image is not deinterlaced, that is, if processing such as sharpness or distortion correction is performed without separating the two field images, combing noise is emphasized or deformed, so that the image quality is clearly improved. Deteriorates. Therefore, it is preferable to deinterlace the interlaced image before performing the sharpening process. As described above, the interlaced image has a regularity that two field images are arranged alternately. Therefore, according to this regularity, the interlace can be easily released (for example, Patent Document 1). reference).

特開2014−033438号公報Japanese Unexamined Patent Publication No. 2014-033438

ところで、防犯カメラの専用のプレイヤーの中には、映像表示やファイル出力の際に、使用者の意図に関係なく勝手に画像の拡縮を行うものがある。また、キャプチャー機器を経由してインターレース画像を取得すると、自動的に画像サイズが変更されることもある。このとき、拡大後のインターレース画像(以下、拡大インターレース画像ということがある)の拡大時の拡大倍率が分からないと、拡大前のインターレース画像(以下、オリジナルインターレース画像ということがある)を復元することができず、2枚のフィールド画像に分離することもできなくなる。かといって、拡大インターレース画像をインターレース解除しないままに鮮明化すると、上記のとおり、画質の劣化を招来する。 By the way, some players dedicated to security cameras arbitrarily scale the image when displaying a video or outputting a file regardless of the intention of the user. Also, when an interlaced image is acquired via a capture device, the image size may be changed automatically. At this time, if the magnification at the time of enlargement of the enlarged interlaced image (hereinafter, may be referred to as an enlarged interlaced image) is unknown, the interlaced image before enlargement (hereinafter, may be referred to as an original interlaced image) is restored. Cannot be separated into two field images. However, if the enlarged interlaced image is sharpened without deinterlacing, the image quality will deteriorate as described above.

また、以上のように何らかの理由で少なくとも縦方向に画像が拡大されるとき、当該画像には拡大倍率に応じて所定の間隔で新しい行が挿入され得る。従って、インターレース画像が少なくとも縦方向に拡大された場合、拡大インターレース画像においては、元の2枚のフィールド画像の交互の配列の規則性が崩れている。従って、拡大インターレース画像において拡大時の追加行の位置等が分からないと、オリジナルインターレース画像を復元することができず、2枚のフィールド画像に分離することもできなくなる。かといって、拡大インターレース画像をインターレース解除しないままに鮮明化すると、上記のとおり、画質の劣化を招来する。 Further, when the image is enlarged at least in the vertical direction for some reason as described above, new rows may be inserted into the image at predetermined intervals according to the enlargement magnification. Therefore, when the interlaced image is enlarged at least in the vertical direction, the regularity of the alternating arrangement of the two original field images is broken in the enlarged interlaced image. Therefore, if the position of the additional line at the time of enlargement is not known in the enlarged interlaced image, the original interlaced image cannot be restored and cannot be separated into two field images. However, if the enlarged interlaced image is sharpened without deinterlacing, the image quality will deteriorate as described above.

本発明は、拡大インターレース画像からオリジナルインターレース画像を復元することを目的とする。 An object of the present invention is to restore an original interlaced image from an enlarged interlaced image.

本発明の第1観点に係る画像処理装置は、オリジナルインターレース画像が拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理装置であって、パターン検出部と、復元部とを備える。前記パターン検出部は、前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出し、前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への縮小倍率を算出する。前記復元部は、前記縮小倍率に基づいて、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成する。 The image processing device according to the first aspect of the present invention is an image processing device that restores the original interlaced image from an enlarged interlaced image in which the original interlaced image is enlarged, and includes a pattern detection unit and a restoration unit. The pattern detection unit detects a striped pattern due to combing noise included in the magnified interlaced image by performing image processing on the magnified interlaced image, and based on the striped pattern, the enlarged interlaced image is described as described above. Calculate the reduction ratio to the original interlaced image. The restoration unit creates at least one of a restoration image obtained by restoring the original interlaced image and a field image constituting the restored image based on the reduction magnification.

本発明の第2観点に係る画像処理装置は、第1観点に係る画像処理装置であって、前記パターン検出部は、前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への仮の縮小倍率を算出し、前記仮の縮小倍率及び前記拡大インターレース画像の縦画素数に基づいて、前記オリジナルインターレース画像の縦画素数の候補となる候補画素数を複数設定し、前記複数の候補画素数にそれぞれ対応する複数の前記縮小倍率を算出し、前記復元部は、前記複数の縮小倍率の各々に対し、前記復元画像及び前記フィールド画像の少なくとも一方を作成する。 The image processing apparatus according to the second aspect of the present invention is the image processing apparatus according to the first aspect, and the pattern detection unit changes from the enlarged interlaced image to the original interlaced image based on the striped pattern. The temporary reduction ratio of the above is calculated, and a plurality of candidate pixels that are candidates for the number of vertical pixels of the original interlaced image are set based on the provisional reduction ratio and the number of vertical pixels of the enlarged interlaced image. A plurality of the reduction ratios corresponding to the number of candidate pixels are calculated, and the restoration unit creates at least one of the restoration image and the field image for each of the plurality of reduction ratios.

本発明の第3観点に係る画像処理装置は、第2観点に係る画像処理装置であって、前記複数の候補画素数は、全て偶数である。 The image processing apparatus according to the third aspect of the present invention is the image processing apparatus according to the second aspect, and the number of the plurality of candidate pixels is an even number.

本発明の第4観点に係る画像処理装置は、第1観点から第3観点のいずれかに係る画像処理装置であって、前記復元部は、線形補間のアルゴリズムを用いて前記拡大インターレース画像を前記縮小倍率で縮小することにより、前記復元画像を作成する。 The image processing apparatus according to the fourth aspect of the present invention is an image processing apparatus according to any one of the first to third aspects, and the restoration unit uses a linear interpolation algorithm to obtain the enlarged interlaced image. The restored image is created by reducing the image at a reduction ratio.

本発明の第5観点に係る画像処理装置は、オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理装置であって、パターン検出部と、復元部とを備える。前記パターン検出部は、前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出し、前記縞模様のパターンに基づいて、前記拡大インターレース画像に含まれる前記追加行の位置を特定するパラメータを算出する。前記復元部は、前記追加行の位置を特定するパラメータに基づいて、前記拡大インターレース画像から前記追加行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成する。 The image processing apparatus according to the fifth aspect of the present invention has the original interlaced image from the enlarged interlaced image magnified at a certain magnification by adding additional lines at predetermined intervals to the original interlaced image. It is an image processing device that restores an image, and includes a pattern detection unit and a restoration unit. The pattern detection unit detects a striped pattern due to combing noise included in the magnified interlaced image by performing image processing on the magnified interlaced image, and includes the magnified interlaced image based on the striped pattern. Calculate the parameters that specify the position of the additional line. The restoration unit removes the additional row from the enlarged interlaced image based on a parameter for specifying the position of the additional row, thereby restoring the original interlaced image and a field image constituting the restored image. Create at least one of them.

本発明の第6観点に係る画像処理装置は、第5観点に係る画像処理装置であって、前記追加行の位置を特定するパラメータには、前記拡大倍率が含まれる。 The image processing apparatus according to the sixth aspect of the present invention is the image processing apparatus according to the fifth aspect, and the parameter for specifying the position of the additional row includes the enlargement magnification.

本発明の第7観点に係る画像処理装置は、第5観点又は第6観点に係る画像処理装置であって、前記パターン検出部は、1行おきの縞模様のパターンを有する画像を前記拡大倍率と同じ倍率で拡大した画像である拡大パターン画像と、前記拡大インターレース画像とを、両画像の前記縞模様のパターンが最も一致するように位置合わせし、前記位置合わせの結果に基づいて、前記追加行の位置を特定するパラメータを算出する。 The image processing apparatus according to the seventh aspect of the present invention is an image processing apparatus according to the fifth or sixth aspect, and the pattern detection unit captures an image having a striped pattern every other line at the magnification. The enlarged pattern image, which is an image enlarged at the same magnification as the above, and the enlarged interlaced image are aligned so that the striped patterns of both images match most, and the addition is based on the result of the alignment. Calculate the parameters that specify the row position.

本発明の第8観点に係る画像処理装置は、第5観点から第7観点のいずれかに係る画像処理装置であって、前記復元画像の滲みを除去する滲み補正部をさらに備える。 The image processing apparatus according to the eighth aspect of the present invention is an image processing apparatus according to any one of the fifth to seventh aspects, and further includes a bleeding correction unit for removing bleeding of the restored image.

本発明の第9観点に係る画像処理装置は、第8観点に係る画像処理装置であって、前記滲み補正部は、滲みパターン画像に含まれる画素値から補正係数を算出し、前記補正係数に基づいて前記復元画像の画素値を補正する。前記滲みパターン画像は、1行おきの縞模様のパターンを有する画像を、前記拡大倍率と同じ倍率で拡大した後、前記拡大倍率の逆数の縮小倍率で縮小した画像である。 The image processing apparatus according to the ninth aspect of the present invention is the image processing apparatus according to the eighth aspect, and the bleeding correction unit calculates a correction coefficient from a pixel value included in the bleeding pattern image and uses the correction coefficient as the correction coefficient. Based on this, the pixel value of the restored image is corrected. The blur pattern image is an image in which an image having a striped pattern every other line is enlarged at the same magnification as the enlargement magnification and then reduced at a reduction magnification that is the reciprocal of the enlargement magnification.

本発明の第10観点に係る画像処理装置は、第1観点から第9観点のいずれかに係る画像処理装置であって、前記縞模様のパターンには、前記縞模様の周期が含まれる。 The image processing apparatus according to the tenth aspect of the present invention is an image processing apparatus according to any one of the first to ninth aspects, and the striped pattern includes the period of the striped pattern.

本発明の第11観点に係る画像処理装置は、第10観点に係る画像処理装置であって、前記拡大インターレース画像は、複数枚のフレームを含む動画である。前記パターン検出部は、前記複数枚のフレームから前記コーミングノイズを強調したノイズ強調画像を作成し、前記ノイズ強調画像の各行間の差分を表す差分画像を作成し、前記差分画像の各行に含まれる画素値の特徴を表す縦方向プロファイルを作成し、前記縦方向プロファイルのパワースペクトルのピークの位置から、前記縞模様の周期を算出する。 The image processing apparatus according to the eleventh aspect of the present invention is the image processing apparatus according to the tenth aspect, and the enlarged interlaced image is a moving image including a plurality of frames. The pattern detection unit creates a noise-enhanced image in which the combing noise is emphasized from the plurality of frames, creates a difference image showing a difference between each line of the noise-enhanced image, and includes the difference image in each line of the difference image. A vertical profile representing the characteristics of the pixel values is created, and the period of the striped pattern is calculated from the position of the peak of the power spectrum of the vertical profile.

本発明の第12観点に係る画像処理プログラムは、オリジナルインターレース画像が拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理プログラムであって、以下のステップをコンピュータに実行させる。
(1)前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップ
(2)前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への縮小倍率を算出するステップ
(3)前記縮小倍率に基づいて、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップ
The image processing program according to the twelfth aspect of the present invention is an image processing program that restores the original interlaced image from an enlarged interlaced image in which the original interlaced image is enlarged, and causes a computer to execute the following steps.
(1) A step of detecting a striped pattern due to combing noise included in the magnified interlaced image by image processing the magnified interlaced image (2) Based on the striped pattern, the magnified interlaced image is described as described above. Step of calculating the reduction magnification to the original interlaced image (3) Based on the reduction magnification, a step of creating at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image.

本発明の第13観点に係る画像処理方法は、オリジナルインターレース画像が拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理プログラムであって、以下のステップを含む。
(1)前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップ
(2)前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への縮小倍率を算出するステップ
(3)前記縮小倍率に基づいて、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップ
The image processing method according to the thirteenth aspect of the present invention is an image processing program that restores the original interlaced image from an enlarged interlaced image in which the original interlaced image is enlarged, and includes the following steps.
(1) A step of detecting a striped pattern due to combing noise included in the magnified interlaced image by image processing the magnified interlaced image (2) Based on the striped pattern, the magnified interlaced image is described as described above. Step of calculating the reduction magnification to the original interlaced image (3) Based on the reduction magnification, a step of creating at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image.

本発明の第14観点に係る画像処理プログラムは、オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理プログラムであって、以下のステップをコンピュータに実行させる。
(1)前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップ
(2)前記縞模様のパターンに基づいて、前記拡大インターレース画像に含まれる前記追加行の位置を特定するパラメータを算出するステップ
(3)前記追加行の位置を特定するパラメータに基づいて、前記拡大インターレース画像から前記追加行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップ
In the image processing program according to the 14th aspect of the present invention, the original interlaced image is enlarged from the enlarged interlaced image at a certain magnification by adding additional lines at predetermined intervals to the original interlaced image. An image processing program that restores an image and causes a computer to perform the following steps.
(1) A step of detecting a striped pattern due to combing noise included in the magnified interlaced image by image processing the magnified interlaced image (2) Included in the magnified interlaced image based on the striped pattern. Step of calculating a parameter for specifying the position of the additional row (3) Restoring the original interlaced image by removing the additional row from the enlarged interlaced image based on the parameter for specifying the position of the additional row. A step of creating at least one of the restored image and the field image constituting the restored image.

本発明の第15観点に係る画像処理方法は、オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理方法であって、以下のステップを含む。
(1)前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップ
(2)前記縞模様のパターンに基づいて、前記拡大インターレース画像に含まれる前記追加行の位置を特定するパラメータを算出するステップ
(3)前記追加行の位置を特定するパラメータに基づいて、前記拡大インターレース画像から前記追加行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップ
In the image processing method according to the fifteenth aspect of the present invention, the original interlaced image is enlarged from the enlarged interlaced image at a certain magnification by adding additional lines at predetermined intervals to the original interlaced image. An image processing method for restoring an image, which includes the following steps.
(1) A step of detecting a striped pattern due to combing noise included in the magnified interlaced image by image processing the magnified interlaced image (2) Included in the magnified interlaced image based on the striped pattern. Step of calculating a parameter for specifying the position of the additional row (3) Restoring the original interlaced image by removing the additional row from the enlarged interlaced image based on the parameter for specifying the position of the additional row. A step of creating at least one of the restored image and the field image constituting the restored image.

本発明の第16観点に係る画像処理装置は、オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理装置であって、検出部と、復元部とを備える。前記検出部は、前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれる画素値が同じ又は略同じ重複行を検出する。前記復元部は、前記拡大インターレース画像から前記重複行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成する。 In the image processing apparatus according to the 16th aspect of the present invention, the original interlaced image is enlarged from the enlarged interlaced image at a certain magnification by adding additional lines at predetermined intervals to the original interlaced image. It is an image processing device that restores an image, and includes a detection unit and a restoration unit. The detection unit detects duplicate rows having the same or substantially the same pixel value included in the enlarged interlaced image by performing image processing on the enlarged interlaced image. The restoration unit creates at least one of a restoration image obtained by restoring the original interlaced image and a field image constituting the restored image by removing the overlapping lines from the enlarged interlaced image.

本発明の第1観点によれば、拡大インターレース画像を画像処理することにより、拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンが検出される。そして、この縞模様のパターンに基づいて、拡大インターレース画像からオリジナルインターレース画像を復元するための縮小倍率が算出される。そして、この縮小倍率に基づいて、オリジナルインターレース画像を復元した復元画像及び復元画像を構成するフィールド画像の少なくとも一方が作成される。以上により、拡大インターレース画像からオリジナルインターレース画像を復元することができる。 According to the first aspect of the present invention, by performing image processing on the enlarged interlaced image, a striped pattern due to combing noise included in the enlarged interlaced image is detected. Then, based on this striped pattern, the reduction magnification for restoring the original interlaced image from the enlarged interlaced image is calculated. Then, based on this reduction magnification, at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image is created. From the above, the original interlaced image can be restored from the enlarged interlaced image.

本発明の第5観点によれば、拡大インターレース画像を画像処理することにより、拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンが検出される。そして、この縞模様のパターンに基づいて、拡大インターレース画像に含まれる拡大時の追加行の位置が特定される。そして、この追加行が除去され、オリジナルインターレース画像を復元した復元画像及び復元画像を構成するフィールド画像の少なくとも一方が作成される。以上により、拡大インターレース画像からオリジナルインターレース画像を復元することができる。 According to the fifth aspect of the present invention, by performing image processing on the enlarged interlaced image, a striped pattern due to combing noise included in the enlarged interlaced image is detected. Then, based on this striped pattern, the position of the additional line at the time of enlargement included in the enlarged interlaced image is specified. Then, this additional line is removed, and at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image is created. From the above, the original interlaced image can be restored from the enlarged interlaced image.

本発明の第16観点によれば、拡大インターレース画像を画像処理することにより、拡大インターレース画像に含まれる画素値が同じ又は略同じ重複行が検出される。そして、この重複行が除去されることにより、オリジナルインターレース画像を復元した復元画像及び復元画像を構成するフィールド画像の少なくとも一方が作成される。以上により、拡大インターレース画像からオリジナルインターレース画像を復元することができる。 According to the 16th aspect of the present invention, by performing image processing on the enlarged interlaced image, overlapping rows having the same or substantially the same pixel value included in the enlarged interlaced image are detected. Then, by removing the duplicated lines, at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image is created. From the above, the original interlaced image can be restored from the enlarged interlaced image.

本発明の第1実施形態に係る画像処理装置のブロック図。The block diagram of the image processing apparatus which concerns on 1st Embodiment of this invention. 画像データが取り込まれる前の基本画面の図。The figure of the basic screen before the image data is imported. 画像データが取り込まれた後の基本画面の図。The figure of the basic screen after the image data is imported. 1のタイムラインに属する静止画群を示す図。The figure which shows the still image group belonging to 1 timeline. 本発明の第1実施形態に係る特殊インターレース解除の処理の流れを示すフローチャート。The flowchart which shows the flow of the process of the special deinterlacing which concerns on 1st Embodiment of this invention. 拡大インターレース画像の差分画像から自己加重平均により作成したノイズ強調画像の例。An example of a noise-enhanced image created by self-weighted averaging from the difference image of the enlarged interlaced image. 図6Aと同じ拡大インターレース画像の差分画像から単なる平均により作成したノイズ強調画像の例。An example of a noise-enhanced image created by mere averaging from the difference image of the same enlarged interlaced image as in FIG. 6A. ニアレストネイバー法による拡大インターレース画像のノイズ強調画像の行間の差分を表す差分画像の例。An example of a difference image showing the difference between the lines of a noise-enhanced image of an enlarged interlaced image by the nearest neighbor method. バイリニア法による拡大インターレース画像のノイズ強調画像の行間の差分を表す差分画像の例。An example of a difference image showing the difference between the lines of a noise-enhanced image of an enlarged interlaced image by the bilinear method. 図7Aに示される四角枠内の拡大図。An enlarged view of the inside of the square frame shown in FIG. 7A. 図7Bに示される四角枠内の拡大図。An enlarged view of the inside of the square frame shown in FIG. 7B. 図7Bの差分画像から導出した縦方向プロファイルのグラフ。The graph of the vertical profile derived from the difference image of FIG. 7B. 図9の縦方向プロファイルのパワースペクトルのグラフ。The graph of the power spectrum of the vertical profile of FIG. (a)コーミングノイズを想定したパターン画像。(b)(a)をバイリニア法により拡大した拡大パターン画像。(c)(b)の行間の差分を表す差分画像。(d)(e)に対し位置合わせされた(c)の画像。(e)拡大インターレース画像から作成したノイズ強調画像の行間の差分を表す差分画像。(A) A pattern image assuming combing noise. (B) An enlarged pattern image obtained by enlarging (a) by the bilinear method. (C) A difference image showing the difference between the lines of (b). (D) The image of (c) aligned with respect to (e). (E) A difference image showing the difference between lines of a noise-enhanced image created from an enlarged interlaced image. 図11(c)の差分画像の画素値のグラフ。The graph of the pixel value of the difference image of FIG. 11C. 拡大パターン画像を1画素ずつ下方向にずらして配置した様子を示す図。The figure which shows the appearance that the enlarged pattern image is arranged by shifting it downward one pixel at a time. 図13の各拡大パターン画像をニアレストネイバー法により縮小した縮小画像の図。The figure of the reduced image which reduced each enlarged pattern image of FIG. 13 by the nearest neighbor method. (a)図11(b)の拡大パターン画像。(b)(a)をニアレストネイバー法により縮小した縮小画像。(c)図11(a)のパターン画像。(d)(b)及び(c)の枠内に示す画像の一部を抜き出した画像。(A) Enlarged pattern image of FIG. 11 (b). (B) A reduced image obtained by reducing (a) by the nearest neighbor method. (C) The pattern image of FIG. 11 (a). (D) An image obtained by extracting a part of the image shown in the frames of (b) and (c). 変形例に係る特殊インターレース解除の処理の流れを示すフローチャート。The flowchart which shows the flow of the process of the special deinterlacing which concerns on a modification. 拡大インターレース画像の例。An example of a magnified interlaced image. 図17Aの拡大インターレース画像に対し、通常のインターレース解除を行った結果を示す図(比較例)。FIG. 6 is a diagram showing the result of performing normal deinterlacing on the enlarged interlaced image of FIG. 17A (comparative example). 図17Aの拡大インターレース画像に対し、図5の特殊インターレース解除の縮小処理(S3)までを行った結果を示す図。It is a figure which shows the result of having performed the reduction process (S3) of the special deinterlacing cancellation of FIG. 5 with respect to the enlarged interlace image of FIG. 17A. 図17Aの拡大インターレース画像に対し、図5の特殊インターレース解除の滲み補正処理(S4)までを行った結果を示す図。It is a figure which shows the result of having performed the blur correction processing (S4) of the special deinterlacing cancellation of FIG. 5 on the enlarged interlace image of FIG. 17A. 図17Aの拡大インターレース画像に対し、図5の特殊インターレース解除を行った結果を示す図(実施例1)。FIG. 6 is a diagram showing the result of deinterlacing the special interlace of FIG. 5 with respect to the enlarged interlaced image of FIG. 17A (Example 1). 図17Cの縮小画像に対し、通常のインターレース解除を行った結果を示す図(実施例2)。FIG. 6 is a diagram showing the result of performing normal deinterlacing on the reduced image of FIG. 17C (Example 2). 本発明の第2実施形態に係る特殊インターレース解除の処理の流れを示すフローチャート。The flowchart which shows the flow of the process of the special deinterlacing which concerns on 2nd Embodiment of this invention. (A)コーミングノイズを想定したパターン画像。(B)(A)のパターン画像を通常のバイリニア法で拡大した後、通常のバイリニア法で元のサイズに縮小した画像。(C)(A)のパターン画像を通常のバイリニア法で拡大した後、第2実施形態に係るバイリニア法で元のサイズに縮小した画像。(A) A pattern image assuming combing noise. (B) An image obtained by enlarging the pattern image of (A) by a normal bilinear method and then reducing it to the original size by a normal bilinear method. (C) An image obtained by enlarging the pattern image of (A) by a normal bilinear method and then reducing it to the original size by the bilinear method according to the second embodiment. 図19(A)のパターン画像を様々な拡大倍率でバイリニア法で拡大した後、元のサイズに縮小したときの、各縮小画像と元のパターン画像とのPSNRのグラフ。The PSNR graph of each reduced image and the original pattern image when the pattern image of FIG. 19A is enlarged by the bilinear method at various magnifications and then reduced to the original size. 図17Aの拡大インターレース画像を、第2実施形態に係るアルゴリズムで特殊インターレース解除を行った結果を示す図(実施例3)。FIG. 17A is a diagram showing the result of performing special deinterlacing by the algorithm according to the second embodiment on the enlarged interlaced image of FIG. 17A (Example 3). 実施例4〜6に係る6種類のオリジナルインターレース画像のサンプルを示す図。The figure which shows the sample of 6 kinds of original interlaced images which concern on Examples 4-6. サンプル1を拡大倍率1.3倍及び1.6倍で拡大し、第2実施形態に係るバイリニア法及び通常のバイリニア法で元のサイズに復元した場合の復元画像(実施例5及び比較例5)。Restored images when sample 1 is magnified at 1.3 times and 1.6 times and restored to its original size by the bilinear method and the normal bilinear method according to the second embodiment (Example 5 and Comparative Example 5). ). サンプル2を拡大倍率1.3倍及び1.6倍で拡大し、第2実施形態に係るバイリニア法及び通常のバイリニア法で元のサイズに復元した場合の復元画像(実施例5及び比較例5)。Restored images when sample 2 is magnified at 1.3 times and 1.6 times and restored to its original size by the bilinear method and the normal bilinear method according to the second embodiment (Example 5 and Comparative Example 5). ). サンプル3を拡大倍率1.3倍及び1.6倍で拡大し、第2実施形態に係るバイリニア法及び通常のバイリニア法で元のサイズに復元した場合の復元画像(実施例5及び比較例5)。Restored images when sample 3 is magnified at 1.3 times and 1.6 times and restored to its original size by the bilinear method and the normal bilinear method according to the second embodiment (Example 5 and Comparative Example 5). ). サンプル4を拡大倍率1.3倍及び1.6倍で拡大し、第2実施形態に係るバイリニア法及び通常のバイリニア法で元のサイズに復元した場合の復元画像(実施例5及び比較例5)。Restored images when sample 4 is magnified at 1.3 times and 1.6 times and restored to the original size by the bilinear method and the normal bilinear method according to the second embodiment (Example 5 and Comparative Example 5). ). サンプル5を拡大倍率1.3倍及び1.6倍で拡大し、第2実施形態に係るバイリニア法及び通常のバイリニア法で元のサイズに復元した場合の復元画像(実施例5及び比較例5)。Restored images when sample 5 is magnified at 1.3 times and 1.6 times and restored to its original size by the bilinear method and the normal bilinear method according to the second embodiment (Example 5 and Comparative Example 5). ). サンプル6を拡大倍率1.3倍及び1.6倍で拡大し、第2実施形態に係るバイリニア法及び通常のバイリニア法で元のサイズに復元した場合の復元画像(実施例5及び比較例5)。Restored images when sample 6 is magnified at 1.3 times and 1.6 times and restored to its original size by the bilinear method and the normal bilinear method according to the second embodiment (Example 5 and Comparative Example 5). ). サンプル3の場合における拡大倍率とPSNRとの関係を示すグラフ。The graph which shows the relationship between the magnification and PSNR in the case of sample 3. サンプル6の場合における拡大倍率とPSNRとの関係を示すグラフ。The graph which shows the relationship between the magnification and PSNR in the case of sample 6. サンプル3に係る図25の画像をインターレース解除した画像(実施例6及び比較例6)。An image obtained by deinterlacing the image of FIG. 25 according to sample 3 (Example 6 and Comparative Example 6).

以下、図面を参照しつつ、本発明の幾つかの実施形態に係る画像処理装置、プログラム及び方法について説明する。 Hereinafter, the image processing apparatus, the program, and the method according to some embodiments of the present invention will be described with reference to the drawings.

<1.第1実施形態>
<1−1.画像処理装置の構成>
図1に示す画像処理装置1は、本発明の第1実施形態に係る画像処理装置である。画像処理装置1は、ハードウェアとしては、汎用のパーソナルコンピュータである。画像処理装置1には、CD−ROMやUSBメモリ等のコンピュータが読み取り可能な記録媒体60から、或いはLANやインターネット等のネットワーク経由で画像処理プログラム2が提供され、インストールされている。画像処理プログラム2は、動画及び静止画に対する画像処理を支援するためのアプリケーションソフトウェアである。画像処理プログラム2は、画像処理装置1に後述する動作に含まれるステップを実行させる。
<1. First Embodiment>
<1-1. Image processing device configuration>
The image processing device 1 shown in FIG. 1 is an image processing device according to the first embodiment of the present invention. The image processing device 1 is a general-purpose personal computer as hardware. The image processing program 2 is provided and installed in the image processing device 1 from a computer-readable recording medium 60 such as a CD-ROM or a USB memory, or via a network such as a LAN or the Internet. The image processing program 2 is application software for supporting image processing for moving images and still images. The image processing program 2 causes the image processing device 1 to execute the steps included in the operations described later.

画像処理装置1は、ディスプレイ10、入力部20、記憶部30及び制御部40を有する。これらの部10〜40は、互いにバス線やケーブル等の通信線5を介して接続されており、適宜、通信可能である。ディスプレイ10は、液晶ディスプレイ等から構成され、後述する画面等をユーザに対し表示する。入力部20は、マウスやキーボート、タッチパネル等から構成され、画像処理装置1に対するユーザからの操作を受け付ける。記憶部30は、ハードディスクやフラッシュメモリ等から構成される不揮発性の記憶領域である。制御部40は、CPU、ROM及びRAM等から構成される。 The image processing device 1 includes a display 10, an input unit 20, a storage unit 30, and a control unit 40. These units 10 to 40 are connected to each other via a communication line 5 such as a bus line or a cable, and can communicate with each other as appropriate. The display 10 is composed of a liquid crystal display or the like, and displays a screen or the like described later to the user. The input unit 20 is composed of a mouse, a keyboard, a touch panel, and the like, and receives an operation from the user on the image processing device 1. The storage unit 30 is a non-volatile storage area composed of a hard disk, a flash memory, or the like. The control unit 40 is composed of a CPU, a ROM, a RAM, and the like.

画像処理プログラム2は、記憶部30内に格納されている。記憶部30内には、ソフトウェア管理領域50が確保されている。ソフトウェア管理領域50は、画像処理プログラム2が使用する領域である。ソフトウェア管理領域50内には、オリジナル画像領域51及び加工ファイル領域52が確保されている。各領域51,52の役割については、後述する。 The image processing program 2 is stored in the storage unit 30. A software management area 50 is secured in the storage unit 30. The software management area 50 is an area used by the image processing program 2. An original image area 51 and a processed file area 52 are secured in the software management area 50. The roles of the regions 51 and 52 will be described later.

制御部40は、記憶部30内に格納されている画像処理プログラム2を読み出して実行することにより、仮想的に表示制御部41及び画像処理部42として動作する。表示制御部41は、ディスプレイ10上に表示される画面、ウィンドウ、ボタンその他の全ての要素の表示を制御する。画像処理部42は、様々な種類の画像処理を実行する。画像処理部42は、後述する特殊インターレース解除の処理の実行中、仮想的に検出部42a、復元部42b及び補正部42cとして動作する。各部41,42,42a〜42cの動作の詳細は、後述する。 The control unit 40 virtually operates as the display control unit 41 and the image processing unit 42 by reading and executing the image processing program 2 stored in the storage unit 30. The display control unit 41 controls the display of screens, windows, buttons and all other elements displayed on the display 10. The image processing unit 42 executes various types of image processing. The image processing unit 42 virtually operates as the detection unit 42a, the restoration unit 42b, and the correction unit 42c during the execution of the special deinterlacing process described later. Details of the operation of each part 41, 42, 42a to 42c will be described later.

<1−2.画像処理装置の動作>
制御部40は、ユーザが入力部20を介して所定の操作を行ったことを検出すると、画像処理プログラム2を起動する。画像処理プログラム2が起動されると、基本画面W1(図2参照)がディスプレイ10上に表示される。
<1-2. Operation of image processing device>
When the control unit 40 detects that the user has performed a predetermined operation via the input unit 20, the control unit 40 starts the image processing program 2. When the image processing program 2 is started, the basic screen W1 (see FIG. 2) is displayed on the display 10.

<1−2−1.画像データの取込み>
基本画面W1は、オリジナル画像領域51への画像データの取込みの命令をユーザから受け付ける。オリジナル画像領域51へ取り込まれた画像データは、後述する再生処理及び画像処理の対象になる。制御部40は、静止画ファイル又は動画ファイルから、オリジナル画像領域51へ画像データを取り込む。なお、本明細書において、静止画ファイルとは、静止画形式のデータファイルであり、動画ファイルとは、動画形式のデータファイルである。
<1-2-1. Importing image data>
The basic screen W1 receives a command from the user to import image data into the original image area 51. The image data captured in the original image area 51 is subject to reproduction processing and image processing described later. The control unit 40 takes in image data from the still image file or the moving image file into the original image area 51. In the present specification, the still image file is a still image format data file, and the moving image file is a moving image format data file.

静止画ファイルから画像データを取り込む場合、ユーザは、入力部20を操作することにより、1の静止画ファイルを指定するか、又は1のフォルダを指定する。前者の場合、制御部40は、その静止画ファイルの記憶部30内のアドレスパス及びファイル名をユーザに入力させる。後者の場合、制御部40は、そのフォルダの記憶部30内のアドレスパス及びフォルダ名をユーザに入力させる。その後、制御部40は、指定された静止画ファイル又は指定されたフォルダ内の全ての静止画ファイルを、オリジナル画像領域51に静止画ファイル群として保存する。なお、本明細書において、「群」という場合には、その要素数は複数とは限らず、1つであってもよい。 When importing image data from a still image file, the user specifies one still image file or one folder by operating the input unit 20. In the former case, the control unit 40 causes the user to input the address path and the file name in the storage unit 30 of the still image file. In the latter case, the control unit 40 causes the user to input the address path and the folder name in the storage unit 30 of the folder. After that, the control unit 40 saves the designated still image file or all the still image files in the designated folder as a still image file group in the original image area 51. In addition, in this specification, the term "group" is not limited to a plurality of elements, and may be one.

一方、動画ファイルから画像データを取り込む場合、ユーザは、入力部20を操作することにより、1の動画ファイルの記憶部30内のアドレスパス及びファイル名を入力する。表示制御部41は、ユーザが動画ファイルを指定したことを検出すると、基本画面W1上に動画取込みウィンドウ(図示されない)を重ねて表示させる。動画取込みウィンドウは、指定された動画ファイルのタイムラインの全区間うち、任意の区間の選択をユーザから受け付ける。制御部40は、ユーザが入力部20を介して特定の区間を選択したことを検出すると、選択された区間に含まれるフレーム群に1対1で対応する静止画ファイル群を生成する。その後、制御部40は、この静止画ファイル群をオリジナル画像領域51に保存する。従って、本実施形態では、後述する再生処理及び画像処理の対象となる画像データは、動画ファイルではなく、静止画ファイルである。 On the other hand, when the image data is taken from the moving image file, the user inputs the address path and the file name in the storage unit 30 of the moving image file 1 by operating the input unit 20. When the display control unit 41 detects that the user has specified a moving image file, the display control unit 41 superimposes and displays a moving image import window (not shown) on the basic screen W1. The video capture window accepts the user to select any section of the entire timeline of the specified video file. When the control unit 40 detects that the user has selected a specific section via the input unit 20, the control unit 40 generates a still image file group corresponding to the frame group included in the selected section on a one-to-one basis. After that, the control unit 40 saves the still image file group in the original image area 51. Therefore, in the present embodiment, the image data to be reproduced and image processed, which will be described later, is not a moving image file but a still image file.

なお、制御部40は、オリジナル画像領域51へ取り込まれた静止画ファイル群が動画ファイルに由来するものではなく、静止画ファイルに由来するものであっても、静止画ファイル群に含まれるファイルをタイムラインに沿って配列されているものと認識する。配列は、ファイルの属性(ファイル名、作成日時、更新日時等)から自動的に判断される。 Note that the control unit 40 selects the files included in the still image file group even if the still image file group captured in the original image area 51 is not derived from the moving image file but is derived from the still image file. Recognize that they are arranged along the timeline. The array is automatically determined from the file attributes (file name, creation date and time, modification date and time, etc.).

<1−2−2.再生処理>
オリジナル画像領域51へ静止画ファイル群が取り込まれると、表示制御部41は、基本画面W1上に表示ウィンドウW2(図3参照)を重ねて表示させる。表示ウィンドウW2は、オリジナル画像領域51へ取り込まれた静止画ファイル群のタイムラインの数だけ作成される。
<1-2-2. Playback processing>
When the still image file group is taken into the original image area 51, the display control unit 41 superimposes the display window W2 (see FIG. 3) on the basic screen W1 and displays it. Display windows W2 are created for the number of timelines of the still image files captured in the original image area 51.

表示ウィンドウW2内には、まず、オリジナル画像領域51へ取り込まれた静止画ファイル群に含まれる1の静止画ファイル(例えば、タイムライン上で先頭のフレームに対応する静止画ファイル)が表示される。その後、後述するとおり、表示ウィンドウW2内に表示されるフレームは、ユーザの操作を受けて切り替わる。 In the display window W2, first, one still image file (for example, a still image file corresponding to the first frame on the timeline) included in the still image file group captured in the original image area 51 is displayed. .. After that, as will be described later, the frame displayed in the display window W2 is switched in response to a user operation.

図3に示すとおり、基本画面W1上には、ウィンドウ選択プルダウンメニューT1、再生ボタンT2、コマ送りボタンT3、コマ戻しボタンT4及びタイムラインバーT5が配置されている。 As shown in FIG. 3, a window selection pull-down menu T1, a play button T2, a frame advance button T3, a frame return button T4, and a timeline bar T5 are arranged on the basic screen W1.

表示ウィンドウW2が複数存在する場合であっても、アクティブな表示ウィンドウW2は1つである。ウィンドウ選択プルダウンメニューT1は、どの表示ウィンドウW2をアクティブとするかの選択をユーザから受け付ける。以下、アクティブな表示ウィンドウW2に対応するタイムラインを、アクティブタイムラインと呼び、アクティブタイムラインに属するフレーム群を、アクティブフレーム群と呼ぶ。また、アクティブな表示ウィンドウW2内に現在表示されているフレームを、アクティブフレームと呼ぶ。 Even if there are a plurality of display windows W2, there is only one active display window W2. The window selection pull-down menu T1 accepts from the user the selection of which display window W2 is to be activated. Hereinafter, the timeline corresponding to the active display window W2 is referred to as an active timeline, and the frame group belonging to the active timeline is referred to as an active frame group. Further, the frame currently displayed in the active display window W2 is called an active frame.

表示制御部41は、アクティブな表示ウィンドウW2内で、アクティブフレーム群を動画として再生可能である。再生ボタンT2は、アクティブフレーム群の動画としての再生の命令をユーザから受け付ける。表示制御部41は、ユーザが入力部20を介して再生ボタンT2を押下したことを検出すると、アクティブな表示ウィンドウW2内に、アクティブフレーム群に含まれるフレームを、タイムラインに沿って順次コマ送りの形式で表示させる。なお、再生は、再生ボタンT2が押下された時点のアクティブフレームから開始する。また、再生ボタンT2は、再生の停止の命令をユーザから受け付ける。表示制御部41は、再生中にユーザが入力部20を介して再生ボタンT2を押下したことを検出すると、アクティブな表示ウィンドウW2内の表示を、その時点のアクティブフレームに固定する。 The display control unit 41 can reproduce the active frame group as a moving image in the active display window W2. The play button T2 receives a command from the user to play the active frame group as a moving image. When the display control unit 41 detects that the user has pressed the play button T2 via the input unit 20, the frames included in the active frame group are sequentially frame-advanced along the timeline in the active display window W2. Display in the format of. The reproduction starts from the active frame at the time when the reproduction button T2 is pressed. Further, the play button T2 receives an instruction to stop playback from the user. When the display control unit 41 detects that the user presses the play button T2 via the input unit 20 during playback, the display control unit 41 fixes the display in the active display window W2 to the active frame at that time.

コマ送りボタンT3、コマ戻しボタンT4はそれぞれ、アクティブフレームを、アクティブタイムラインに沿って1つ後、1つ前のフレームへ切り替える命令をユーザから受け付ける。 Each of the frame advance button T3 and the frame return button T4 receives an instruction from the user to switch the active frame to the next frame after the active frame along the active timeline.

タイムラインバーT5は、アクティブタイムラインを図式的に示すオブジェクトである。タイムラインバーT5は、そのバーが延びる方向に、アクティブフレーム群に含まれるフレーム数で等分に分割されている。タイムラインバーT5上の左からn番目の分割領域は、アクティブタイムライン上でn番目のフレームに対応する(nは、自然数)。 The timeline bar T5 is an object that graphically represents the active timeline. The timeline bar T5 is equally divided by the number of frames included in the active frame group in the direction in which the bar extends. The nth division area from the left on the timeline bar T5 corresponds to the nth frame on the active timeline (n is a natural number).

図3に示すように、表示制御部41は、タイムラインバーT5上において、選択フレーム群に対応する分割領域A1と、非選択フレーム群に対応する分割領域A2とを、異なる表示形式で表示する。選択フレーム群とは、アクティブタイムライン上で現在選択されている区間に属するフレーム群である。非選択フレーム群とは、アクティブタイムライン上で現在選択されていない区間に属するフレーム群である。 As shown in FIG. 3, the display control unit 41 displays the divided area A1 corresponding to the selected frame group and the divided area A2 corresponding to the non-selected frame group in different display formats on the timeline bar T5. .. The selected frame group is a frame group belonging to the currently selected section on the active timeline. The non-selected frame group is a frame group belonging to a section that is not currently selected on the active timeline.

タイムラインバーT5は、アクティブタイムライン上の任意の区間の選択をユーザから受け付ける。このとき選択される区間は、連続区間であってもよいし、図3に示すように、不連続区間であってもよい。具体的には、ユーザは、入力部20を介してタイムラインバーT5上の分割領域を操作することにより、アクティブフレーム群の中から、任意のフレームを任意の数だけ選択することができる。分割領域は、同時に複数選択が可能である。表示制御部41は、ユーザによりタイムラインバーT5上の分割領域が選択される度に、アクティブフレームを最新に選択された分割領域に対応するフレームに直ちに切り替える。画像処理部42は、選択フレーム群を後述される画像処理の対象として認識する。 The timeline bar T5 receives from the user the selection of an arbitrary section on the active timeline. The section selected at this time may be a continuous section or may be a discontinuous section as shown in FIG. Specifically, the user can select an arbitrary number of arbitrary frames from the active frame group by operating the divided area on the timeline bar T5 via the input unit 20. Multiple division areas can be selected at the same time. The display control unit 41 immediately switches the active frame to the frame corresponding to the latest selected division area each time the division area on the timeline bar T5 is selected by the user. The image processing unit 42 recognizes the selected frame group as an image processing target described later.

<1−2−3.画像処理>
画像処理部42は、選択フレーム群に対し、明るさ/コントラスト/彩度調整、ノイズ除去、シャープネス、ぶれ/ぼけ補正、拡大/縮小、歪曲補正、あおり補正、通常のインターレース解除、特殊インターレース解除などの複数の画像処理モジュールを実行可能である。画像処理モジュールは、画像処理プログラム2に組み込まれている。
<1-2-3. Image processing>
The image processing unit 42 performs brightness / contrast / saturation adjustment, noise removal, sharpness, blur / blur correction, enlargement / reduction, distortion correction, tilt correction, normal deinterlacing, special deinterlacing, etc. for the selected frame group. It is possible to execute multiple image processing modules of. The image processing module is incorporated in the image processing program 2.

ユーザは、入力部20を介して基本画面W1を操作することにより、画像処理モジュールの中から任意のものを、任意の順番に、任意の回数だけ選択することが可能である。画像処理部42は、ユーザが画像処理モジュールを選択したことを検出する度に、その時点の選択フレーム群に対しその画像処理モジュールを実行する。なお、選択フレーム群に対し画像処理モジュールを実行するとは、選択フレーム群に含まれる各フレームに対しその画像処理モジュールを実行することである。 By operating the basic screen W1 via the input unit 20, the user can select any image processing module in any order and any number of times. Each time the image processing unit 42 detects that the user has selected the image processing module, the image processing unit 42 executes the image processing module for the selected frame group at that time. To execute the image processing module for the selected frame group means to execute the image processing module for each frame included in the selected frame group.

フレームに対し画像処理モジュールが1回、2回、3回,・・・と、順次実行されてゆくにつれて、そのフレームは、第1次、第2次、第3次,・・・と、順次加工されてゆく。第0次フレームは、オリジナル画像領域51に保存されている静止画ファイルに対応する。第(m+1)次フレームは、第m次フレームの静止画ファイルに対し画像処理モジュールを1回実行した後の静止画ファイルに対応する(mは、0以上の整数)。画像処理部42は、第1次以降のフレームに対応する静止画ファイルを順次生成し、これらの静止画ファイルを加工ファイル領域52内にそれぞれ別個に保存する。 As the image processing module is sequentially executed once, twice, three times, ... For the frame, the frame is sequentially executed as the first, second, third, ... It will be processed. The 0th frame corresponds to a still image file stored in the original image area 51. The (m + 1) th-th frame corresponds to the still image file after the image processing module is executed once for the still image file of the m-th frame (m is an integer of 0 or more). The image processing unit 42 sequentially generates still image files corresponding to the first and subsequent frames, and stores these still image files separately in the processed file area 52.

図4は、1のタイムラインに属する画像群が画像処理プログラム2によりどのように管理されるかを示す概念図である。図4において、横軸のN軸は、タイムライン上のフレームの順番を示しており、縦軸のM軸は、加工の順番を示している。図4のN−M空間内の座標(n,m)に対応する四角形は、画像I(n,m)を表している。画像I(n,m)は、タイムライン上でn番目のフレームの第m次の画像である(nは、自然数であり、mは、0以上の整数である)。 FIG. 4 is a conceptual diagram showing how the image group belonging to the timeline of 1 is managed by the image processing program 2. In FIG. 4, the N axis on the horizontal axis indicates the order of frames on the timeline, and the M axis on the vertical axis indicates the order of processing. The quadrangle corresponding to the coordinates (n, m) in the NM space of FIG. 4 represents the image I (n, m). Image I (n, m) is the m-th order image of the nth frame on the timeline (n is a natural number and m is an integer of 0 or more).

制御部40は、各フレームについて、現在選択されている座標mの値をパラメータmsとして管理する。オリジナル画像領域51へ静止画ファイル群が取り込まれた直後、座標msは、初期値0である。その後、画像処理モジュールが1回実行される度に、そのフレームの座標msは1ずつインクリメントされる。また、ユーザは、入力部20を介して所定の操作を行うことにより、任意のフレームの座標msを自在に変更することができる。なお、フレームに対し画像処理モジュールを実行するとは、そのフレームの第ms次の画像に対し画像処理モジュールを実行することである。従って、座標msを変更することには、画像処理モジュールの実行の対象を変更するという意味がある。また、フレームを表示するとは、そのフレームの座標msの画像を表示することである。従って、座標msを変更することには、アクティブな表示ウィンドウW2内に表示される対象を変更するという意味もある。 The control unit 40 manages the value of the currently selected coordinate m as the parameter m s for each frame. Immediately after the still image files are imported into the original image area 51, the coordinate ms has an initial value of 0. Thereafter, every time the image processing module is executed once, the coordinate m s of the frame is incremented by one. The user, by performing a predetermined operation via the input unit 20 can be changed freely coordinate m s of any frame. To execute the image processing module on a frame means to execute the image processing module on the image of the msth order of the frame. Therefore, to change the coordinate m s is meaningful that changes the target of the execution of the image processing module. Further, the display frame is to display the image coordinates m s of the frame. Therefore, to change the coordinate m s is also means to change the object to be displayed in the active display window W2.

<1−3.特殊インターレース解除>
以下、画像処理プログラム2に実装されている画像処理の1つである、特殊インターレース解除の処理について説明する。インターレース画像とは、2枚のフィールド画像を一方が奇数行を構成し、他方が偶数行を構成するように交互に合成した画像である。通常のインターレース解除とは、この規則性に従って、インターレース画像を奇数行からなる画像と偶数行からなる画像とに、すなわち、元の2枚のフィールド画像に分離することを言う。
<1-3. Special deinterlacing>
Hereinafter, the special deinterlacing process, which is one of the image processes implemented in the image processing program 2, will be described. The interlaced image is an image in which two field images are alternately combined so that one constitutes an odd-numbered row and the other constitutes an even-numbered row. Normal deinterlacing refers to separating an interlaced image into an image consisting of odd-numbered rows and an image consisting of even-numbered rows, that is, into two original field images according to this regularity.

これに対し、特殊インターレース解除とは、拡大インターレース画像を元の2枚のフィールド画像に分離することを言う。拡大インターレース画像とは、オリジナルインターレース画像が少なくとも縦方向にある拡大倍率で拡大された画像であり、言い換えると、オリジナルインターレース画像に拡大倍率に応じて所定の間隔で追加行が追加された画像である(追加列が追加されている場合も含む)。従って、拡大インターレース画像においては、これらの追加行の存在により、合成前の2枚のフィールド画像の交互の配列の規則性が崩れている。よって、拡大インターレース画像は、通常のインターレース解除の処理ではインターレースを解除できない特殊なインターレース画像である。特殊インターレース解除は、このような特殊なインターレース画像のインターレースを解除する処理である。具体的には、拡大インターレース画像から追加行を除去することにより、拡大インターレース画像を少なくとも縦方向に元のサイズに復元した復元画像を作成し、この復元画像を奇数行のフィールド画像と偶数行のフィールド画像とに分離する。このとき、拡大インターレース画像に含まれる追加行の位置は、拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンに基づいて画像処理により特定される。なお、コーミングノイズとは、横方向の縞模様として現れる、インターレース画像に特有のノイズである。すなわち、合成前の2枚のフィールド画像の時間差により、奇数行と偶数行とで動いている被写体が移動方向に互い違いにずれて写ることにより生じるノイズである。 On the other hand, special deinterlacing means separating the enlarged interlaced image into two original field images. The magnified interlaced image is an image in which the original interlaced image is magnified at least at a magnification in the vertical direction, in other words, an image in which additional lines are added at predetermined intervals according to the magnified magnification to the original interlaced image. (Including when additional columns have been added). Therefore, in the magnified interlaced image, the presence of these additional rows breaks the regularity of the alternating arrangement of the two field images before compositing. Therefore, the enlarged interlaced image is a special interlaced image that cannot be deinterlaced by a normal deinterlacing process. The special deinterlacing is a process for deinterlacing such a special interlaced image. Specifically, by removing additional rows from the magnified interlaced image, a restored image is created in which the magnified interlaced image is restored to its original size at least vertically, and this restored image is used as an odd-numbered field image and an even-numbered row. Separated from the field image. At this time, the position of the additional line included in the enlarged interlaced image is specified by image processing based on the striped pattern due to the combing noise included in the enlarged interlaced image. The combing noise is noise peculiar to an interlaced image that appears as a striped pattern in the horizontal direction. That is, it is noise generated when subjects moving in odd-numbered rows and even-numbered rows are alternately shifted in the moving direction due to the time difference between the two field images before composition.

以下、図5を参照しつつ、特殊インターレース解除のアルゴリズムについて詳細に説明する。図5は、本実施形態に係る特殊インターレース解除の処理の流れを示すフローチャートである。特殊インターレース解除の処理は、選択フレーム群に含まれる各フレームを対象として実行される。ただし、本実施形態に係る特殊インターレース解除の処理は、少なくとも2枚のフレームを必要とするため、選択フレーム群に少なくとも2枚のフレームが含まれる場合にのみ実行される。従って、図5のフローチャートに係る処理は、ユーザが入力部20を介してアクティブタイムライン上で2枚以上のフレームを選択している状態で本処理の実行を命令した場合に開始する。 Hereinafter, the special deinterlacing algorithm will be described in detail with reference to FIG. FIG. 5 is a flowchart showing the flow of the special deinterlacing process according to the present embodiment. The special deinterlacing process is executed for each frame included in the selected frame group. However, since the special deinterlacing process according to the present embodiment requires at least two frames, it is executed only when the selected frame group includes at least two frames. Therefore, the process according to the flowchart of FIG. 5 starts when the user orders the execution of this process in a state where two or more frames are selected on the active timeline via the input unit 20.

最初のステップS1では、検出部42aが、選択フレーム群に含まれるフレームF1,F2,・・・,FN(Nは、2以上の整数)のコーミングノイズによる縞模様のパターンを検出する。縞模様のパターンは、以下のアルゴリズムにより検出される。まず、検出部42aは、n=1,2,・・・,N−1に対し、時間的に隣接する2枚のフレームFnとFn+1との差分画像FDifnを作成する。具体的には、以下の式に従って、x=1,2,・・・,W、y=1,2,・・・,Hに対し、差分画像FDifnに含まれる各画素値FDifn,x,yを算出する。なお、フレームFnは、H(縦)×W(横)ピクセルの画像であり、FDifn,x,yは、FDifnのy行x列の画素値あり、Datn,x,yは、フレームFnのy行x列の画素値ある。

Figure 0006928772
In the first step S1, the detection unit 42a detects a striped pattern due to combing noise of frames F 1 , F 2 , ..., F N (N is an integer of 2 or more) included in the selected frame group. .. The striped pattern is detected by the following algorithm. First, the detection unit 42a creates a difference image FDif n between two frames F n and F n + 1, which are temporally adjacent to each other with respect to n = 1, 2, ..., N-1. Specifically, according to the following equation, for x = 1, 2, ..., W, y = 1, 2, ..., H, each pixel value FDif n, x included in the difference image FDif n , Y is calculated. Note that the frame F n is an image of H (vertical) × W (horizontal) pixels, FDif n, x, y have pixel values in y rows and x columns of FDif n , and Dat n, x, y are There is a pixel value of y row x column of frame F n.
Figure 0006928772

差分画像FDifnにおいては、静止している物体が消え、相対的に動体部分が強調される。コーミングノイズは、フレームF1,F2,・・・,FNに写る動体部分に現れるため、差分画像FDifnにおいては、コーミングノイズが強調される。 In the difference image FDif n , the stationary object disappears and the moving body portion is relatively emphasized. Since the combing noise appears in the moving body portion reflected in the frames F 1 , F 2 , ..., F N , the combing noise is emphasized in the difference image FDif n.

次に、検出部42aは、差分画像FDif1,FDif2,・・・,FDifN-1を重ね合わせた画像WFDifを作成する。具体的には、以下の式に従って、x=1,2,・・・,W、y=1,2,・・・,Hに対し、画像WFDifに含まれる各画素値WFDifx,yを算出する。なお、WFDifx,yは、画像WFDifのy行x列の画素値である。画像WFDifは、差分画像FDif1,FDif2,・・・,FDifN-1を重ね合わせることにより、フレームF1,F2,・・・,FNに含まれるコーミングノイズをさらに強調した画像(以下、ノイズ強調画像ということがある)である。

Figure 0006928772
Next, the detection unit 42a creates an image WFDif in which the difference images FDif 1 , FDif 2 , ..., FDif N-1 are superimposed. Specifically, each pixel value WFDif x, y included in the image WFDif is calculated for x = 1, 2, ..., W, y = 1, 2, ..., H according to the following equation. do. Note that WFDif x, y is a pixel value of the y row x column of the image WFDif. The image WFDef is an image in which the combing noise contained in the frames F 1 , F 2 , ..., F N is further emphasized by superimposing the difference images FDif 1 , FDif 2 , ..., FDif N-1. Hereinafter, it may be referred to as a noise-enhanced image).
Figure 0006928772

数2の式では、自己加重平均による重ね合わせが行われている。すなわち、数2の式によるノイズ強調画像WFDifは、各画素について、差分画像FDif1,FDif2,・・・,FDifN-1に含まれる画素値を、それぞれ自身の画素値を重みとして平均化した画像である。なお、ノイズ強調画像WFDifの算出方法はこれに限らず、例えば、差分画像FDif1,FDif2,・・・,FDifN-1の単なる平均画像とすることもできる。また、差分画像FDif1,FDif2,・・・,FDifN-1を重ね合わせることなく、任意の1枚の差分画像FDifnをそのままノイズ強調画像WFDifとして、その後の処理を進めることもできる。 In the equation of Equation 2, superposition is performed by self-weighted average. That is, the noise-enhanced image WFDif according to the equation of Equation 2 averages the pixel values included in the difference images FDif 1 , FDif 2, ..., FDif N-1 for each pixel with their own pixel values as weights. It is an image that was made. The calculation method of the noise-enhanced image WFDif is not limited to this, and for example, it may be a simple average image of the difference images FDif 1 , FDif 2 , ..., FDif N-1. Further, without superimposing the difference images FDif 1 , FDif 2 , ..., FDif N-1 , any one difference image FDif n can be used as it is as the noise-enhanced image WFDif, and the subsequent processing can proceed.

図6Aは、96枚の拡大インターレース画像から数2の式に従って作成したノイズ強調画像WFDifである。一方、図6Bは、同じ96枚の拡大インターレース画像の差分画像FDif1,FDif2,・・・,FDifN-1の単なる平均画像として作成したノイズ強調画像WFDifである。これらを比較すれば明らかなとおり、自己加重平均を行うことで、コーミングノイズがより強調されることが分かる。 FIG. 6A is a noise-enhanced image WFDif created from 96 enlarged interlaced images according to the equation of Equation 2. On the other hand, FIG. 6B is a noise-enhanced image WFDef created as a mere average image of the difference images FDif 1 , FDif 2 , ..., FDif N-1 of the same 96 enlarged interlaced images. As is clear from a comparison of these, it can be seen that the combing noise is further emphasized by performing the self-weighted averaging.

次に、検出部42aは、ノイズ強調画像WFDifの隣接する各行間の差分を表す差分画像LDifを作成する。具体的には、以下の式に従って、x=1,2,・・・,W、y=1,2,・・・,H−1に対し、差分画像LDifに含まれる各画素値LDifx,yを算出する。なお、LDifx,yは、差分画像LDifのy行x列の画素値である。

Figure 0006928772
Next, the detection unit 42a creates a difference image LDif representing the difference between adjacent lines of the noise-enhanced image WFDif. Specifically, according to the following equation, for x = 1, 2, ..., W, y = 1, 2, ..., H-1, each pixel value LDif x, included in the difference image LDif x, Calculate y. In addition, LDif x, y is a pixel value of y row x column of the difference image LDif.
Figure 0006928772

図7Aは、図6Aの画像から数3の式に従って作成した差分画像LDifである。図7Bは、図6Aとは異なる60枚の拡大インターレース画像から数3の式に従って作成した差分画像LDifである。 FIG. 7A is a difference image LDif created from the image of FIG. 6A according to the equation of Equation 3. FIG. 7B is a difference image LDif created according to the equation of Equation 3 from 60 enlarged interlaced images different from those in FIG. 6A.

次に、検出部42aは、差分画像LDifの各行に含まれる画素値の特徴を表す縦方向プロファイルYproを作成する。具体的には、以下の式に従って、y=1,2,・・・,H−1に対し、Yproyを算出する。なお、Yproは、(H−1)行1列の行列であり、Yproyは、Yproのy行目の値である。

Figure 0006928772
Next, the detection unit 42a creates a vertical profile Ypro that represents the characteristics of the pixel values included in each row of the difference image LDif. Specifically, Ypro y is calculated for y = 1, 2, ..., H-1 according to the following formula. In addition, Ypro is a matrix of (H-1) rows and 1 column, and Ypro y is a value of the yth row of Ypro.
Figure 0006928772

次に、検出部42aは、縦方向プロファイルYproに含まれる(H−1)個の値のデータ列をフーリエ変換し、パワースペクトルを導出する。ただし、このとき、縦方向プロファイルYproに含まれる1行目からH'行目までの値が用いられる。H'は、(H−1)以下の2のべき乗の最大値である。 Next, the detection unit 42a Fourier transforms a data string of (H-1) values included in the vertical profile Ypro to derive a power spectrum. However, at this time, the values from the first line to the H'line included in the vertical profile Ypro are used. H'is the maximum value of the power of 2 below (H-1).

縦方向プロファイルYproには、コーミングノイズによる縞模様のパターンから生じる波形の特徴が現れるため、Yproのパワースペクトルには、縞模様の幅の変化の周期に対応するピークが現れる。そのため、縞模様の周期Cpは、以下の式に従って、H'及びYproのパワースペクトルのピークの位置Ypeakから算出することができる。

Figure 0006928772
Since the vertical profile Ypro shows the characteristics of the waveform resulting from the striped pattern due to combing noise, the Ypro power spectrum shows peaks corresponding to the period of change in the width of the striped pattern. Therefore, the period C p of the striped pattern can be calculated from the peak position Y peak of the power spectrum of H'and Ypro according to the following equation.
Figure 0006928772

図8A及び図8Bは、それぞれ図7A及び図7Bの差分画像LDif上に示される四角枠内の拡大図である。図8Aからは、縞模様の間隔に8行単位の周期性があることが分かる(つまり、Cp=8)。また、1周期に相当する各8行の中には、黒い又は黒っぽい行が3行ずつあることが分かる。ノイズ強調画像WFDifの各行間の差分を表す差分画像LDif上に現れる黒い又は黒っぽい行は、ノイズ強調画像WFDifにおいて当該行の画素値が隣接する行の画素値と同じ又は略同じであったことを表す。言い換えると、黒い又は黒っぽい行は、オリジナルインターレース画像から拡大インターレース画像への拡大時にコーミングノイズの幅が広がった行、つまり追加行を表す。通常のインターレース画像では、縞模様は1行おきに変化するため、このような黒い又は黒っぽい行は存在しない。従って、1周期内の本来の行数Corgは、以下の式のとおり、周期Cpから1周期Cp当たりの黒い又は黒っぽい行の数Cntを引くことで算出される。図7A及び図8Aの例では、Corg=8−3=5行である。

Figure 0006928772
8A and 8B are enlarged views in the square frame shown on the difference image LDif of FIGS. 7A and 7B, respectively. From FIG. 8A, it can be seen that the interval of the striped pattern has a periodicity of 8 lines (that is, C p = 8). It can also be seen that there are three black or blackish lines in each of the eight lines corresponding to one cycle. The black or blackish lines appearing on the difference image LDif showing the difference between each line of the noise-enhanced image WFDif are the same or substantially the same as the pixel values of the adjacent lines in the noise-enhanced image WFDif. show. In other words, a black or blackish line represents a line in which the combing noise is widened when the original interlaced image is enlarged to the enlarged interlaced image, that is, an additional line. In a normal interlaced image, such black or blackish lines do not exist because the striped pattern changes every other line. Thus, the original number of lines C org in one cycle, the following equation is calculated by subtracting the number Cnt black or dark row of per period C p from the cycle C p. In the example of FIGS. 7A and 8A, Corg = 8-3 = 5 lines.
Figure 0006928772

一方、図7B及び図8Bからは、黒い又は黒っぽい行が目視では判別し難い。しかしながら、Cp及びCntは、差分画像LDifから算出することができる。図9は、図7Bの差分画像LDifから導出した縦方向プロファイルYproのグラフであり、図10は、そのパワースペクトルを示す。図10の例では、H'=512であり、ピークの位置Ypeak=51であるため、数5の式より、Cp=512/51=10.039・・・となり、周期Cpが10行と特定される。また、図9を見ると、10行の1周期当たりに1回、下に凸となる箇所が現れている。そして、この下に凸となる箇所が、目視では検出し難いこともある黒い又は黒っぽい行に相当する。従って、この例では、Cnt=1である。 On the other hand, from FIGS. 7B and 8B, it is difficult to visually distinguish black or blackish lines. However, C p and Cnt can be calculated from the difference image LDif. FIG. 9 is a graph of the vertical profile Ypro derived from the difference image LDif of FIG. 7B, and FIG. 10 shows the power spectrum thereof. In the example of FIG. 10, since H'= 512 and the peak position Ypeak = 51, C p = 512/51 = 10.039 ... From the equation of Equation 5, and the period C p is 10 rows. Is specified. Further, looking at FIG. 9, a downwardly convex portion appears once per cycle of 10 rows. The downwardly convex portion corresponds to a black or blackish line that may be difficult to detect visually. Therefore, in this example, Cnt = 1.

以上より、検出部42aは、縦方向プロファイルYproのパワースペクトルから、数5の式に従って周期Cpを算出し、さらに縦方向プロファイルYproの値の配列の中から、1周期Cp当たりの下に凸となる箇所の数Cntを算出する。また、これらのCp及びCntから、数6の式に従ってCorgを算出する。 From the above, the detection unit 42a calculates the period C p from the power spectrum of the vertical profile Ypro according to the equation of Equation 5 , and further lowers the period C p from the array of values of the vertical profile Ypro. Calculate the number Cnt of the convex parts. Further, from these C p and Cnt, Corg is calculated according to the formula of Equation 6.

次に、検出部42aは、縞模様のパターンを表すパラメータとなるCp及びCntに基づいて、以下の式により、オリジナルインターレース画像から拡大インターレース画像への縦方向の拡大倍率REを算出する。

Figure 0006928772
Next, the detection unit 42a calculates the vertical enlargement magnification R E from the original interlaced image to the enlarged interlaced image by the following formula based on C p and Cnt which are parameters representing the striped pattern.
Figure 0006928772

以上より、図7A及び図8Aの例では、拡大倍率RE=8/5=1.6倍である。一方、図7B及び図8Bの例では、拡大倍率RE=10/9=1.111・・・倍である。 Thus, in the example of FIGS. 7A and 8A, a magnification ratio R E = 8/5 = 1.6 . On the other hand, in the example of FIG. 7B and 8B, an enlarged magnification R E = 10/9 = 1.111 ··· times.

ところで、図7A及び図8Aは、ニアレストネイバー(最近傍補間)法により拡大された拡大インターレース画像由来の画像であり、図7B及び図8Bは、周辺の複数の画素値から1つの画素値を決定する補間アルゴリズムの1つである、バイリニア法により拡大された拡大インターレース画像由来の画像である。前者のニアレストネイバー法では、拡大時の追加行が隣接行のコピーとなるため、Cp及びCntを目視でも特定できる。一方、バイリニア法のように拡大時の追加行が複数の行の画素値の混合値である後者の例では、目視での特定が困難となる。この点、数5〜数7の式により縞模様のパターンを検出するアルゴリズムは、ニアレストネイバー法のみならず、バイリニア法のようなアルゴリズムで拡大された拡大インターレース画像にも対応することができる。 By the way, FIGS. 7A and 8A are images derived from an enlarged interlaced image enlarged by the nearest neighbor (nearest neighbor interpolation) method, and FIGS. 7B and 8B show one pixel value from a plurality of peripheral pixel values. It is an image derived from an enlarged interlaced image enlarged by the bilinear method, which is one of the interpolation algorithms for determining. In the former Nearest Neighbor method, since the additional line at the time of enlargement is a copy of the adjacent line, C p and Cnt can be visually specified. On the other hand, in the latter example in which the additional row at the time of enlargement is a mixed value of the pixel values of a plurality of rows as in the bilinear method, it is difficult to visually identify the row. In this regard, the algorithm for detecting the striped pattern by the equations of several 5 to 7 can correspond not only to the nearest neighbor method but also to the enlarged interlaced image enlarged by an algorithm such as the bilinear method.

続くステップS2では、検出部42aは、ステップS1の結果に基づいて、拡大インターレース画像であるフレームFnに含まれる追加行の位置を特定するパラメータを算出する。このパラメータは、以下のアルゴリズムにより算出される。 In the following step S2, the detection unit 42a calculates a parameter for specifying the position of the additional line included in the frame F n which is the enlarged interlaced image based on the result of step S1. This parameter is calculated by the following algorithm.

検出部42aは、図11(a)に示すようなコーミングノイズを想定したパターン画像CP0を作成する。パターン画像CP0は、白の画素値を有する行と、黒の画素値を有する行とが1行おきに交互に配列された縞模様のパターンを有する画像である。追加行の位置を特定するパラメータは、このパターン画像CP0から特殊なインターレース画像(インターレース画像を拡大した画像)を生成するシミュレーションにより算出される。具体的には、検出部42aは、パターン画像CP0を所定の補間法により縦方向に拡大倍率REで拡大した画像(拡大パターン画像)CP1(図11(b)参照)を作成する。図11の例では、バイリニア法が用いられている。バイリニア法では、各画素の新たな画素値が当該画素と4つの周辺画素との距離に基づく線形補間によって生成されるため、図11の拡大パターン画像CP1には、白と黒の中間濃度の画素が出現している。ただし、ここで用いられる補間法としては、フレームFnが作成されたときの補間法が選択されるべきであり、従って、バイリニア法に限らず、ニアレストネイバー法やバイキュービック法等、任意の補間法を選択することができる。なお、フレームFnが作成されたときの補間法は未知であることが多いため、様々な補間法で同様の処理を行い、最も良い結果をユーザ自ら又は自動的に選択するように構成することができる。 The detection unit 42a creates a pattern image CP0 assuming combing noise as shown in FIG. 11A. The pattern image CP0 is an image having a striped pattern in which rows having white pixel values and rows having black pixel values are alternately arranged every other row. The parameter for specifying the position of the additional row is calculated by a simulation of generating a special interlaced image (an enlarged image of the interlaced image) from the pattern image CP0. Specifically, the detection unit 42a generates an image obtained by enlarging the pattern image CP0 at magnification R E in the longitudinal direction by a predetermined interpolation method (magnified pattern image) CP1 (see FIG. 11 (b)). In the example of FIG. 11, the bilinear method is used. In the bilinear method, a new pixel value of each pixel is generated by linear interpolation based on the distance between the pixel and the four peripheral pixels. Therefore, in the enlarged pattern image CP1 of FIG. 11, pixels having an intermediate density between white and black are used. Has appeared. However, as the interpolation method used here, the interpolation method when the frame F n is created should be selected. Therefore, the interpolation method is not limited to the bilinear method, and any method such as the nearest neighbor method or the bicubic method can be selected. You can select the interpolation method. Since the interpolation method when the frame F n is created is often unknown, the same processing should be performed by various interpolation methods, and the best result should be selected by the user himself or automatically. Can be done.

さらに、検出部42aは、数3の式と同様の以下の式に従って、拡大パターン画像CP1の隣接する各行間の差分を表す差分画像CP2(図11(c)参照)を作成する。図12は、差分画像CP2の画素値のグラフである。具体的には、以下の式に従って、x=1,2,・・・,W、y=1,2,・・・,H−1に対し、差分画像CP2に含まれる各画素値MDifx,yを算出する。なお、MDifx,yは、差分画像CP2のy行x列の画素値であり、Nx,yは、拡大パターン画像CP1のy行x列の画素値である。

Figure 0006928772
Further, the detection unit 42a creates a difference image CP2 (see FIG. 11C) representing the difference between adjacent lines of the enlarged pattern image CP1 according to the following equation similar to the equation of Equation 3. FIG. 12 is a graph of pixel values of the difference image CP2. Specifically, according to the following equation, for x = 1, 2, ..., W, y = 1, 2, ..., H-1, each pixel value MDif x, included in the difference image CP2 Calculate y. In addition, MDif x, y is the pixel value of y row x column of the difference image CP2, and N x, y is the pixel value of y row x column of the enlarged pattern image CP1.
Figure 0006928772

続いて、検出部42aは、差分画像LDifと差分画像CP2とを、両画像の濃淡が最も一致するように、差分画像CP2を上下方向にシフトさせる。そして、最も一致したときの差分画像CP2のシフト量を、オフセット値O1として特定する。なお、このシフトは、パターン画像CP0から作成した拡大インターレース画像である拡大パターン画像CP1と、同じく拡大インターレース画像であるフレームF1,F2,・・・,FNとを、両画像の縞模様のパターンが最も一致するように位置合わせしていることを意味する。 Subsequently, the detection unit 42a shifts the difference image CP2 in the vertical direction so that the difference image LDif and the difference image CP2 match the shades of both images most. Then, the shift amount of the difference image CP2 at the time of the most matching is specified as the offset value O 1. In this shift, the enlarged pattern image CP1 which is an enlarged interlaced image created from the pattern image CP0 and the frames F 1 , F 2 , ..., F N which are also enlarged interlaced images are striped in both images. It means that the patterns of are aligned so that they match best.

図13は、拡大パターン画像CP1を1画素ずつ下方向にずらして配置した様子を示している。また、図14は、図13の各拡大パターン画像CP1をニアレストネイバー法により拡大倍率REの逆数の倍率で縦方向に縮小した縮小画像CP3を示している。検出部42aは、このような縮小画像CP3を作成し、各縮小画像CP3と、同じサイズのパターン画像CP0とを比較して、両画像の濃淡が最も一致する縮小画像CP3を特定する。なお、縮小画像CP3をニアレストネイバー法により作成するのは、線形補間による平滑化効果がこれ以上進まないようにするためであるが、別の補間法を選択することもできる。図14の例では、左から5番目の縮小画像CP3、すなわち、下方向に4行シフトさせた拡大パターン画像CP1を縮小した縮小画像CP3が最もパターン画像CP0と類似している。検出部42aは、このようなシフト量を、オフセット値O2として特定する。すなわち、オフセット値O2は、パターン画像CP0を縦方向に拡大した後、元のサイズに縮小するときに、元のパターン画像CP0を最も正しく復元することが可能な、当該縮小処理時のパラメータである。 FIG. 13 shows a state in which the enlarged pattern image CP1 is arranged by shifting it downward by one pixel. Further, FIG. 14 shows a reduced image CP3 obtained by reducing the longitudinal direction at a magnification of the reciprocal of the magnification R E by the nearest neighbor method each magnified pattern picture CP1 FIG. The detection unit 42a creates such a reduced image CP3, compares each reduced image CP3 with the pattern image CP0 of the same size, and identifies the reduced image CP3 in which the shades of both images match most. The reduced image CP3 is created by the nearest neighbor method in order to prevent the smoothing effect by linear interpolation from further progressing, but another interpolation method can be selected. In the example of FIG. 14, the fifth reduced image CP3 from the left, that is, the reduced image CP3 obtained by reducing the enlarged pattern image CP1 shifted downward by four lines is most similar to the pattern image CP0. The detection unit 42a specifies such a shift amount as an offset value O 2. That is, the offset value O 2 is a parameter at the time of the reduction process that can restore the original pattern image CP0 most correctly when the pattern image CP0 is enlarged in the vertical direction and then reduced to the original size. be.

検出部42aは、以上のオフセット値O1,O2を加算したオフセット値O=O1+O2を、フレームF1,F2,・・・,FNに含まれる追加行の位置を表すパラメータとして特定する。すなわち、フレームF1,F2,・・・,FNをオフセット値Oだけ縦方向にシフトさせた上で、拡大倍率REの逆数の倍率で縦方向に縮小するときに削除されることになる行が、追加行に相当する。この意味で、拡大倍率REもまた、追加行の位置を特定するパラメータと言える。すなわち、拡大倍率REは、追加行の挿入パターンの1周期を表し、オフセット値Oは、この周期の開始位置を表す。 The detection unit 42a sets the offset value O = O 1 + O 2 obtained by adding the above offset values O 1 and O 2 to a parameter representing the position of an additional line included in the frames F 1 , F 2 , ..., F N. Identify as. That is, the frames F 1 , F 2 , ..., F N are shifted in the vertical direction by the offset value O, and then deleted when the frames are reduced in the vertical direction by the reciprocal of the enlargement magnification R E. The line that becomes corresponds to the additional line. In this sense, the magnifying power R E can also be said to be a parameter that specifies the position of the additional row. That is, the enlargement magnification R E represents one cycle of the insertion pattern of the additional row, and the offset value O represents the start position of this cycle.

続くステップS3では、復元部42bは、ステップS1,S2の結果に基づいて、フレームF1,F2,・・・,FNをそれぞれオフセット値Oだけ縦方向にシフトさせた後、ニアレストネイバー法により拡大倍率REの逆数の縮小倍率で縦方向に縮小することにより、復元画像G1,G2,・・・,GNを作成する。すなわち、復元部42bは、各フレームF1,F2,・・・,FNから、当該フレームへの少なくとも縦方向の拡大時に追加されていた追加行が除去される。なお、このときニアレストネイバー法が用いられるのは、平滑化効果がこれ以上進まないようにするためであるが、バイリニア法やバイキュービック法等の別の補間法を選択することもできる。 In the following step S3, the restoration unit 42b shifts the frames F 1 , F 2 , ..., F N in the vertical direction by the offset value O, respectively, based on the results of steps S1 and S2, and then the nearest neighbor. Restored images G 1 , G 2 , ..., GN are created by reducing in the vertical direction at the reduction magnification of the reciprocal of the enlargement magnification R E by the method. That is, the restoration unit 42b removes from each frame F 1 , F 2 , ..., F N the additional line added at least at the time of expansion in the vertical direction to the frame. At this time, the nearest neighbor method is used to prevent the smoothing effect from further progressing, but another interpolation method such as the bilinear method or the bicubic method can be selected.

続くステップS4では、復元画像G1,G2,・・・,GNの滲みを除去する。図15(a)は、図11(b)の拡大パターン画像CP1を示しており、図15(c)は、図11(a)のパターン画像CP0を示している。図15(b)は、図14においてパターン画像CP0に最も類似する、左から5番目の拡大パターン画像CP1の縮小画像CP3を示している。図15(b)の縮小画像CP3は、パターン画像CP0の拡大及び縮小により生じる滲みのパターンを表す画像(以下、滲みパターン画像ということがある)であると言うことができる。図15(c)は、復元画像として理想の状態であるが、図15(b)及び(c)を比較すれば明らかなとおり、拡大時に発生した中間濃度は、縮小しても解消されることはない。そこで、以下のアルゴリズムに従って、この滲みを解消する。ここでも、オフセット値Oを決定したときと同様に、パターン画像CP0に基づくシミュレーションが実行される。 In step S4, the restored image G 1, G 2, ···, removes blurring of G N. 15 (a) shows the enlarged pattern image CP1 of FIG. 11 (b), and FIG. 15 (c) shows the pattern image CP0 of FIG. 11 (a). FIG. 15B shows a reduced image CP3 of the fifth enlarged pattern image CP1 from the left, which is most similar to the pattern image CP0 in FIG. It can be said that the reduced image CP3 of FIG. 15B is an image (hereinafter, may be referred to as a bleeding pattern image) representing the pattern of bleeding caused by the enlargement / reduction of the pattern image CP0. FIG. 15 (c) is an ideal state as a restored image, but as is clear from a comparison of FIGS. 15 (b) and (c), the intermediate density generated at the time of enlargement can be eliminated even if the image is reduced. There is no. Therefore, this bleeding is eliminated according to the following algorithm. Here, too, the simulation based on the pattern image CP0 is executed in the same manner as when the offset value O is determined.

復元画像G1,G2,・・・,GNの各画素の滲みは、当該画素とその上下の画素の画素値を用いて補正される。図15(d)は、図15(b)及び(c)の枠内に示す画像の一部を抜き出した画像である。そして、同図において、滲みパターン画像CP3に含まれるA、B及びCの画素値が、パターン画像CP0に含まれるDの画素値になるような補正を行う。具体的には、補正部42cは、以下の式に従って補正係数αy,βyを算出する。ただし、yは、復元画像G1,G2,・・・,GNの縞模様のパターンの1周期(Corg)分の縦座標である。

Figure 0006928772
Restored image G 1, G 2, · · ·, for each pixel of G N bleeding is corrected using the pixel values of the pixels of the pixel and its vertically. FIG. 15 (d) is an image obtained by extracting a part of the image shown in the frame of FIGS. 15 (b) and 15 (c). Then, in the figure, correction is performed so that the pixel values of A, B, and C included in the blur pattern image CP3 become the pixel values of D included in the pattern image CP0. Specifically, the correction unit 42c calculates the correction coefficients α y and β y according to the following equation. However, y is the restored image G 1, G 2, · · ·, a vertical coordinate of one cycle (C org) content of striped pattern of G N.
Figure 0006928772

補正部42cは、図15(b)及び(c)に示される3行を含む枠を1画素ずつずらしながら、y=1,2,・・・,Corgに対し、補正係数αy,βyを算出する。そして、これらの補正係数αy,βyに基づいて、復元画像G1,G2,・・・,GNの各画素値から滲みを除去した補正値を算出する。具体的には、復元画像G1,G2,・・・,GNの各画素に対し、当該画素の画素値をBとし、その上下の画素の画素値をA及びCとして数9の第1式に代入し、得られるDを当該画素の画素値の補正値とする。このとき、各画素に対して用いられる補正係数αy,βyとして、Corg通りの補正係数αy,βyの中から、上述のオフセット値Oに基づいて、当該画素の行番号に対応するαy,βyが選択される。 The correction unit 42c shifts the frame including the three lines shown in FIGS. 15B and 15C by one pixel, and has correction coefficients α y , β with respect to y = 1, 2, ..., Corg. Calculate y. Then, the correction coefficient alpha y, based on the beta y, the restored image G 1, G 2, · · ·, calculates a correction value obtained by removing the blur from each pixel value of G N. Specifically, the restored image G 1, G 2, · · ·, for each pixel of G N, then the pixel value of the pixel is B, the number 9 pixel value of the upper and lower pixels as A and C Substituting into 1 equation, the obtained D is used as the correction value of the pixel value of the pixel. In this case, the correction coefficient alpha y used for each pixel, as beta y, correction coefficient C org as alpha y, from the beta y, based on the offset value O described above, corresponds to the row number of the pixel Α y and β y are selected.

続くステップS5では、復元部42bは、ステップS4による補正後の復元画像G1,G2,・・・,GNからそれぞれ2枚のフィールド画像を作成する。すなわち、通常のインターレース解除と同様に、ステップS4による補正後の各復元画像Gnを、奇数行からなるフィールド画像Onと偶数行からなるフィールド画像Enとに分離する。なお、1枚のフレームFnから2枚のフレームが作成されることになるため、本実施形態では、新たな1つのタイムラインが作成され、当該タイムラインに属するものとしてフィールド画像O1,O2,・・・,ON及びE1,E2,・・・,ENはオリジナル画像領域51内に保存される。このとき、予め定められている設定に従って、或いは自動判定により、奇数行ファーストか偶数行ファーストかが判定され、新たな1つの動画が作成される。新たなタイムライン上では、奇数行ファーストの場合には、O1,E1,O2,E2,・・・,ON,ENの順にフレームが配列され、偶数行ファーストの場合には、E1,O1,E2,O2,・・・,EN,ONの順にフレームが配列される。 In step S5, the restoration unit 42b are restored image G 1, G 2 corrected by the step S4, · · ·, to create a two field images from each G N. That is, as in the case of normal deinterlacing, each restored image G n after correction in step S4 is separated into a field image O n composed of odd-numbered rows and a field image E n composed of even-numbered rows. Since two frames are created from one frame F n , in the present embodiment, one new timeline is created, and the field images O 1 and O are assumed to belong to the timeline. 2, ···, O N and E 1, E 2, ···, E N is stored in the original image area 51. At this time, an odd-numbered line first or an even-numbered line first is determined according to a predetermined setting or by automatic determination, and a new moving image is created. On new timeline, in the case of the odd lines first are, O 1, E 1, O 2, E 2, ···, O N, frames are arranged in the order of E N, in the case of the even lines first is , E 1, O 1, E 2, O 2, ···, frames are arranged in the order of E N, O N.

<1−4.用途>
画像処理プログラム2は、多種多様な静止画及び動画に対する画像処理を取り扱うことができるが、例えば、警察等の機関が事件の捜査のために防犯カメラの監視映像を解析するのにも利用され得る。防犯カメラ及びこれに接続される記録装置及び再生機器においては、インターレース画像が意図せず拡大されてしまうことがあるが、このようなインターレース画像を解析しなければならない場面において、上述の特殊インターレース解除の処理は有用である。
<1-4. Uses>
The image processing program 2 can handle image processing for a wide variety of still images and moving images, and can also be used, for example, by an organization such as the police to analyze surveillance images of a security camera for investigating an incident. .. In a security camera and a recording device and a playback device connected to the security camera, the interlaced image may be unintentionally enlarged. However, in a situation where such an interlaced image must be analyzed, the above-mentioned special deinterlacing is canceled. Processing is useful.

<1−5.変形例>
以上、第1実施形態について説明したが、本発明は上記実施形態に限定されるものではなく、その趣旨を逸脱しない限りにおいて、種々の変更が可能である。例えば、以下の変更が可能である。
<1-5. Modification example>
Although the first embodiment has been described above, the present invention is not limited to the above embodiment, and various modifications can be made without departing from the spirit of the present invention. For example, the following changes can be made.

<1−5−1>
上記実施形態に係る特殊インターレース解除の処理に代えて、図16に示す特殊インターレース解除の処理を実行することができる。本処理は、オリジナルインターレース画像をニアレストネイバー法により拡大した拡大インターレース画像を復元するのに適している。
<1-5-1>
Instead of the special deinterlacing process according to the above embodiment, the special deinterlacing process shown in FIG. 16 can be executed. This process is suitable for restoring an enlarged interlaced image obtained by enlarging the original interlaced image by the nearest neighbor method.

まず、ステップS11では、検出部42aが、n=1,2,・・・,Nに対し、選択フレーム群に含まれるフレームFnを画像処理することにより、フレームFnに含まれる重複行を検出する。ここでいう重複行とは、隣接する行において、画素値が同じ又は略同じ行である。より具体的には、検出部42aは、以下の式に従って、y=1,2,・・・,H−1に対し、Datn,y+1とDatn,yとの差分を表すHDifn,yを作成する。

Figure 0006928772
First, in step S11, the detection unit 42a performs image processing on the frame F n included in the selected frame group for n = 1, 2, ..., N to obtain duplicate rows included in the frame F n. To detect. The overlapping line referred to here is a line having the same or substantially the same pixel value in adjacent lines. More specifically, the detecting unit 42a according to the following equation, y = 1, 2, · · ·, to the H-1, HDif n representing the difference between Dat n, y + 1 and Dat n, y Create , y.
Figure 0006928772

なお、Datn,yは、フレームFnのy行目の画素値の配列を表す行列である。そして、HDifn,yに含まれる全ての要素の絶対値の合計値が所定値以下の場合には、フレームFnの(y+1)行をy行との重複行と判断する。 Note that Dat n and y are matrices representing an array of pixel values in the y-th row of the frame F n. Then, when the total value of the absolute values of all the elements included in HDif n and y is equal to or less than a predetermined value, the (y + 1) line of the frame F n is determined to be an overlapping line with the y line.

続くステップS12では、復元部42bは、n=1,2,・・・,Nに対し、フレームFnから、ステップS11で検出された重複行を除去することにより、復元画像Gnを作成する。ニアレストネイバー法では、拡大倍率に応じた周期で隣接行のデータをそのままコピーした追加行を挿入することにより、画像が拡大される。従って、ここで除去される重複行は、オリジナルインターレース画像からフレームFnへの拡大時の追加行である。よって、復元画像Gnは、オリジナルインターレース画像からフレームFnへの拡大時の拡大倍率の逆数の縮小倍率で縮小した画像となる。また、このとき、除去されるべき重複行と、これと重複していると判断された行(除去されない行)とに基づいて、後者の行の画素値を決定してもよい。ニアレストネイバー法により拡大した場合であっても、ノイズ等の影響により、追加行がそのコピー元の行と完全に一致するとは限らないからである。従って、2つの行を合成する(例えば、平均する)ことにより、ノイズの影響をキャンセルすることができる。 In the following step S12, the restoration unit 42b creates the restoration image G n by removing the overlapping rows detected in the step S11 from the frame F n for n = 1, 2, ..., N. .. In the nearest neighbor method, the image is magnified by inserting an additional row in which the data of the adjacent row is copied as it is at a cycle corresponding to the enlargement magnification. Therefore, the duplicate line removed here is an additional line when the original interlaced image is enlarged to the frame F n. Therefore, the restored image G n is an image reduced by a reduction magnification that is the reciprocal of the enlargement magnification when the original interlaced image is enlarged to the frame F n. Further, at this time, the pixel value of the latter row may be determined based on the overlapping row to be removed and the row determined to be duplicated (the row not to be removed). This is because even when enlarged by the nearest neighbor method, the additional line does not always exactly match the copy source line due to the influence of noise and the like. Therefore, the effect of noise can be canceled by synthesizing (for example, averaging) the two rows.

続くステップS13は、ステップS5と同様である。すなわち、復元部42bは、ステップS12による復元画像G1,G2,・・・,GNから、それぞれを構成する2枚のフィールド画像を作成する。 Subsequent step S13 is the same as step S5. That is, the restoration unit 42b are restored image G 1, G 2 by step S12, · · ·, a G N, to create a two field images constituting each.

<1−5−2>
第1実施形態に係る特殊インターレース解除の処理では、ステップS2が終了した段階で追加行の位置が特定されている。従って、これらの追加行を削除しつつ、ステップS3を省略して復元画像G1,G2,・・・,GNを作成することなく、直接的にフレームF1,F2,・・・,FNのインターレース解除を行うこともできる。
<1-5-2>
In the special deinterlacing process according to the first embodiment, the position of the additional line is specified at the stage when step S2 is completed. Thus, while deleting these additional lines, restore omit steps S3 image G 1, G 2, · · ·, without creating a G N, directly frames F 1, F 2, · · · , F N can also be deinterlaced.

<2.第2実施形態>
以下、第2実施形態に係る特殊インターレース解除の処理について説明する。なお、本処理を実行する画像処理装置のハードウェア構成は、第1実施形態と共通しているため、以下の説明においては、各要素に同様の符号が付される。
<2. Second Embodiment>
Hereinafter, the special deinterlacing process according to the second embodiment will be described. Since the hardware configuration of the image processing apparatus that executes this process is the same as that of the first embodiment, the same reference numerals are given to each element in the following description.

<2−1.特殊インターレース解除>
第1実施形態と同様、第2実施形態に係る特殊インターレース解除でも、拡大インターレース画像が元の2枚のフィールド画像に分離される。ここでいう拡大インターレース画像とは、オリジナルインターレース画像が少なくとも縦方向にある拡大倍率で拡大された画像であり、言い換えると、拡大倍率に応じてオリジナルインターレース画像の縦画素数が増加した画像である(横画素数が増加した場合も含む)。従って、拡大インターレース画像の生成時の拡大倍率が分からないと、元のサイズに戻し、オリジナルインターレース画像に復元することができず、2枚のフィールド画像に分離することもできなくなる。また、拡大インターレース画像においては、縦画素数の増加により、合成前の2枚のフィールド画像の交互の配列の規則性が崩れている可能性がある。よって、拡大インターレース画像は、通常のインターレース解除の処理ではインターレースを解除できない特殊なインターレース画像である。第2実施形態に係る特殊インターレース解除も、このような特殊なインターレース画像のインターレースを解除する処理である。具体的には、拡大インターレース画像からオリジナルインターレース画像を復元するための少なくとも縦方向の縮小倍率を算出し、拡大インターレース画像を少なくとも縦方向に元のサイズに復元した復元画像を作成し、この復元画像を奇数行のフィールド画像と偶数行のフィールド画像とに分離する。このとき、縮小倍率は、拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンに基づいて画像処理により特定される。
<2-1. Special deinterlacing>
Similar to the first embodiment, in the special deinterlacing according to the second embodiment, the enlarged interlaced image is separated into the original two field images. The enlarged interlaced image referred to here is an image in which the original interlaced image is enlarged at least at a magnification in the vertical direction, in other words, an image in which the number of vertical pixels of the original interlaced image is increased according to the magnification (). Including the case where the number of horizontal pixels increases). Therefore, if the magnification at the time of generating the enlarged interlaced image is not known, the original size cannot be restored and the original interlaced image cannot be restored, and the two field images cannot be separated. Further, in the enlarged interlaced image, there is a possibility that the regularity of the alternating arrangement of the two field images before compositing is broken due to the increase in the number of vertical pixels. Therefore, the enlarged interlaced image is a special interlaced image that cannot be deinterlaced by a normal deinterlacing process. The special deinterlacing according to the second embodiment is also a process for deinterlacing such a special interlaced image. Specifically, at least the vertical reduction magnification for restoring the original interlaced image from the enlarged interlaced image is calculated, and a restored image obtained by restoring the enlarged interlaced image to at least the original size in the vertical direction is created, and this restored image is created. Is separated into an odd-numbered row field image and an even-numbered row field image. At this time, the reduction magnification is specified by image processing based on the striped pattern due to combing noise included in the enlarged interlaced image.

以下、図18を参照しつつ、第2実施形態に係る特殊インターレース解除のアルゴリズムについて詳細に説明する。図18は、第2実施形態に係る特殊インターレース解除の処理の流れを示すフローチャートである。本処理も、第1実施形態と同様に、選択フレーム群に含まれる各フレームを対象として実行される。また、本処理も、少なくとも2枚のフレームを必要とするため、選択フレーム群に少なくとも2枚のフレームが含まれる場合にのみ実行される。 Hereinafter, the special deinterlacing algorithm according to the second embodiment will be described in detail with reference to FIG. FIG. 18 is a flowchart showing a flow of processing for deinterlacing the special interlace according to the second embodiment. Similar to the first embodiment, this process is also executed for each frame included in the selected frame group. Further, since this process also requires at least two frames, it is executed only when the selected frame group includes at least two frames.

最初のステップS21では、ステップS1と同様、検出部42aが、選択フレーム群に含まれるフレームF1,F2,・・・,FN(Nは、2以上の整数)を画像処理することにより、これに含まれるコーミングノイズによる縞模様のパターンを検出する。具体的には、検出部42aは、ステップS1と同様に、n=1,2,・・・,N−1に対し、時間的に隣接する2枚のフレームFnとFn+1との差分画像FDifnを作成する。次に、検出部42aは、差分画像FDif1,FDif2,・・・,FDifN-1を重ね合わせた画像WFDifを作成する。さらに、検出部42aは、ノイズ強調画像WFDifの隣接する各行間の差分を表す差分画像LDifを作成する。続いて、検出部42aは、差分画像LDifの各行に含まれる画素値の特徴を表す縦方向プロファイルYproを作成する。 In the first step S21, as in step S1, the detection unit 42a performs image processing on the frames F 1 , F 2 , ..., F N (N is an integer of 2 or more) included in the selected frame group. , Detects a striped pattern due to combing noise contained in this. Specifically, the detection unit 42a has two frames F n and F n + 1, which are temporally adjacent to n = 1, 2, ..., N-1, as in step S1. Create a difference image FDif n. Next, the detection unit 42a creates an image WFDif in which the difference images FDif 1 , FDif 2 , ..., FDif N-1 are superimposed. Further, the detection unit 42a creates a difference image LDif representing the difference between adjacent lines of the noise-enhanced image WFDif. Subsequently, the detection unit 42a creates a vertical profile Ypro that represents the characteristics of the pixel values included in each row of the difference image LDif.

続いて、ステップS1と同様、検出部42aは、縦方向プロファイルYproに含まれる(H−1)個の値のデータ列をフーリエ変換し、パワースペクトルを導出する。縦方向プロファイルYproには、第1実施形態の説明でも触れたとおり、コーミングノイズによる縞模様のパターンから生じる波形の特徴が現れるため、Yproのパワースペクトルには、縞模様の幅の変化の周期に対応するピークが現れる。本実施形態では、検出部42aは、Yproのパワースペクトルから、以下のアルゴリズムに従って、ピークの位置Ypeakを自動検出する。

Figure 0006928772
ただし、Ypwrは、以下のとおり定義されるパワースペクトルである。
Figure 0006928772
Subsequently, as in step S1, the detection unit 42a Fourier transforms the data sequence of (H-1) values included in the vertical profile Ypro to derive the power spectrum. As mentioned in the description of the first embodiment, the vertical profile Ypro shows the characteristics of the waveform generated from the striped pattern due to the combing noise. Therefore, the Ypro power spectrum shows the period of change in the width of the striped pattern. The corresponding peak appears. In the present embodiment, the detection unit 42a automatically detects the peak position Ypeak from the power spectrum of Ypro according to the following algorithm.
Figure 0006928772
However, Ypwr is a power spectrum defined as follows.
Figure 0006928772

次に、検出部42aは、以下の式に従って、H及びピークの位置Ypeakから縞模様の周期Cpを算出する。

Figure 0006928772
Next, the detection unit 42a calculates the period C p of the striped pattern from the positions Y peak of H and the peak according to the following equation.
Figure 0006928772

次に、検出部42aは、縞模様のパターンを表すパラメータとなるCpに基づいて、以下の式により、拡大インターレース画像からオリジナルインターレース画像への縦方向の縮小倍率RRを算出する。なお、この縮小倍率RRは、続くステップS22で更新される縮小倍率であり、言い換えると、仮の縮小倍率である。

Figure 0006928772
Next, the detection unit 42a, based on C p as a parameter representing the striped pattern, according to the following equation to calculate the vertical reduction ratio R R from enlarged interlaced image to the original interlaced image. Note that the reduction ratio R R is a reduction ratio which is updated at the next step S22, in other words, is a temporary reduction ratio.
Figure 0006928772

数14の式について考察すると、例えば、オリジナルインターレース画像が1.1倍されて拡大インターレース画像が生成されていた場合、10画素当たりに1画素が追加されたことになるため、Cpは10+1=11と計算される。この場合、数14の式により、10/11倍が縮小倍率RRとなるが、その逆数である拡大倍率REは、1.1倍となり、正しく計算できていることが分かる。また、オリジナルインターレース画像が1.5倍されて拡大インターレース画像が生成されていた場合、2画素当たりに1画素が追加されたことになるため、Cpは2+1=3と計算される。この場合、数14の式により、2/3倍が縮小倍率RRとなるが、その逆数である拡大倍率REは、1.5倍となり、正しく計算できていることが分かる。 Considering the equation of Eq. 14, for example, if the original interlaced image is multiplied by 1.1 to generate an enlarged interlaced image, one pixel is added for every 10 pixels, so C p is 10 + 1 = It is calculated as 11. In this case, according to the equation of Equation 14, 10/11 times is the reduction magnification R R , but the reciprocal of the enlargement magnification R E is 1.1 times, which shows that the calculation can be performed correctly. Further, when the original interlaced image is multiplied by 1.5 to generate an enlarged interlaced image, one pixel is added for every two pixels, so C p is calculated as 2 + 1 = 3. In this case, according to the equation of Equation 14, 2/3 times is the reduction magnification R R , but the reciprocal of the enlargement magnification R E is 1.5 times, which shows that the calculation can be performed correctly.

なお、数13,14の式により縞模様のパターンを検出するアルゴリズムは、ニアレストネイバー法や、線形補間法であるバイリニア法、バイキュービック法のような様々なアルゴリズムで拡大された拡大インターレース画像に対し、適用することができる。 The algorithm for detecting the striped pattern by the equations 13 and 14 is an enlarged interlaced image enlarged by various algorithms such as the nearest neighbor method, the bilinear interpolation method, and the bicubic method. On the other hand, it can be applied.

続くステップS22では、検出部42aは、仮の縮小倍率RR及びフレームF1,F2,・・・,FNの縦画素数であるHに基づいて、復元画像G1,G2,・・・,GNの縦画素数の候補となる複数の候補画素数Horgを設定する。Horgは、下式に従って設定される。下式中、hは、計算途中の一時的な値であり、[ ]は、小数点以下を切り捨てて整数を得る関数である。

Figure 0006928772
In step S22, the detection unit 42a is temporary reduction ratio R R and the frame F 1, F 2, · · ·, based on the H is the number of vertical pixels of F N, the restored image G 1, G 2, · ··· , Set a plurality of candidate pixel number orgs that are candidates for the number of vertical pixels of GN. Horg is set according to the following formula. In the following formula, h is a temporary value in the middle of calculation, and [] is a function that rounds down after the decimal point to obtain an integer.
Figure 0006928772

インターレース画像の縦画素数は、通常偶数である。そのため、hが奇数となった場合には、上段の式の1の加減算に連動して下段の式のhが加減算され、偶数となる。また、上段の式で1が加減算されるのは、単にHorg=[H・RR]としたのでは、Horgが真値からずれることがあるからである。そのため、検出部42aは、H・RRに1を加減算することにより、2つのhを算出して、2つの候補画素数Horgを算出する。なお、加減算される1の値は、実験的に決定した数値である。そして、これら2つの候補画素数Horg間に偶数が存在する場合には、その偶数も候補画素数Horgとする。例えば、拡大インターレース画像の縦画素数H=100であり、RR=0.9である場合、h=89,91となる。よって、88,92という2つのHorgが算出され、この例では、その間に挟まれる90もHorgとなる。 The number of vertical pixels in an interlaced image is usually an even number. Therefore, when h becomes an odd number, h in the lower equation is added / subtracted in conjunction with the addition / subtraction of 1 in the upper equation, and becomes an even number. In addition, 1 is added or subtracted in the above equation because if H org = [ HR R ] is simply set, H org may deviate from the true value. Therefore, the detection unit 42a calculates two h by adding / subtracting 1 to H / R R , and calculates the number of two candidate pixels H org. The value of 1 to be added or subtracted is an experimentally determined value. Then, when an even number exists between these two candidate pixel number H org , the even number is also set as the candidate pixel number H org . For example, when the number of vertical pixels H = 100 and RR = 0.9 of the enlarged interlaced image, h = 89,91. Therefore, the calculated two H org as 88 and 92, in this example, 90 also becomes H org sandwiched therebetween.

続くステップS23では、検出部42aは、下式に従って、複数の候補画素数Horgにそれぞれ対応する複数の縮小倍率RR’を算出する。

Figure 0006928772
In step S23, the detection unit 42a, in accordance with the following equation, calculates a plurality of reduction ratio R R 'respectively corresponding to a plurality of candidate pixel number H org.
Figure 0006928772

続くステップS24では、複数の縮小倍率RR’のそれぞれに対し、フレームF1,F2,・・・,FNを元のサイズに縮小した復元画像G1,G2,・・・,GNを作成する。本実施形態では、復元部42bは、線形補間のバイリニア法により、フレームF1,F2,・・・,FNの縮小を行う。 In the following step S24, the restored images G 1 , G 2 , ..., G in which the frames F 1 , F 2 , ..., F N are reduced to the original size for each of the plurality of reduction magnifications R R' Create N. In the present embodiment, the restoration unit 42b reduces the frames F 1 , F 2 , ..., F N by the bilinear method of linear interpolation.

具体的には、本実施形態では、下式に従って、n=1,2,・・・,Nに対し、フレームFnの縮小が行われ、復元画像Gnが作成される。Dsti,jは、復元画像Gnのi列j行の画素値を意味する(i=1,2,・・・,W・RR’,j=1,2,・・・,H・RR’)。

Figure 0006928772
Specifically, in the present embodiment, the frame F n is reduced for n = 1, 2, ..., N according to the following equation, and the restored image G n is created. Dst i, j means the pixel value of the restored image G n in column i, row j (i = 1, 2, ..., WR R ', j = 1, 2, ..., H. R R ').
Figure 0006928772

上式中の各記号の意味は、以下のとおりである。なお、offsetは、0又は−0.5であり、フレームF1,F2,・・・,FNがオリジナルインターレース画像から作成されたときのアルゴリズムの違いに応じて、すなわち、拡大演算の起点が画素端か画素中心かに応じて定まる値である。本実施形態では、offset=0及びoffset=−0.5の両方のパターンでDsti,jを算出する、すなわち、復元画像Gnを生成する。

Figure 0006928772
The meaning of each symbol in the above formula is as follows. Note that offset is 0 or -0.5, depending on the difference in the algorithm when frames F 1 , F 2 , ..., F N are created from the original interlaced image, that is, the starting point of the enlargement calculation. Is a value determined according to whether is the pixel edge or the pixel center. In the present embodiment, Dst i and j are calculated with both the patterns of offset = 0 and offset = −0.5, that is, the restored image G n is generated.
Figure 0006928772

第2実施形態に係るバイリニア法のアルゴリズムは、通常のバイリニア法の一部が変更されたものである。すなわち、通常のバイリニア法では、新たに生成される画素の画素値は、当該画素とその周辺画素との距離に基づく重みu0,u1,v0,v1を付けて、周辺画素の画素値P0,0,P1,0,P0,1,P1,1を加算することにより算出される。しかしながら、数17の式に表れているとおり、本実施形態では、P1,0,P0,1の係数が負の値となっている。 The algorithm of the bilinear method according to the second embodiment is a modification of a part of the normal bilinear method. That is, in the normal bilinear method, the pixel value of the newly generated pixel is added with weights u 0 , u 1 , v 0 , v 1 based on the distance between the pixel and its peripheral pixels, and the pixels of the peripheral pixels are added. It is calculated by adding the values P 0 , 0, P 1 , 0, P 0, 1, and P 1 , 1. However, as it is reflected in the numerical formula 17, in the present embodiment, P 1, 0, has become coefficients P 0, 1 is a negative value.

以上のアルゴリズムにより、拡大インターレース画像をオリジナルインターレース画像へと復元した効果について、説明する。図19(A)の画像は、図11(a)のCP0と同様のコーミングノイズを想定したパターン画像である。図19(B)の画像は、図19(A)のパターン画像を125%の拡大倍率で通常のバイリニア法で拡大した後、通常のバイリニア法で元のサイズに縮小した画像である。一方、図19(C)の画像は、図19(A)のパターン画像を125%の拡大倍率で通常のバイリニア法で拡大した後、第2実施形態に係るバイリニア法で元のサイズに縮小した画像である。同図から分かるとおり、第2実施形態に係るバイリニア法によれば、完全ではないものの、オリジナルインターレース画像をより正しく復元できることが分かる。 The effect of restoring the enlarged interlaced image to the original interlaced image by the above algorithm will be described. The image of FIG. 19A is a pattern image assuming combing noise similar to CP0 of FIG. 11A. The image of FIG. 19 (B) is an image obtained by enlarging the pattern image of FIG. 19 (A) at a magnification of 125% by a normal bilinear method and then reducing it to the original size by a normal bilinear method. On the other hand, the image of FIG. 19C was enlarged by the normal bilinear method at a magnification of 125%, and then reduced to the original size by the bilinear method according to the second embodiment. It is an image. As can be seen from the figure, according to the bilinear method according to the second embodiment, although it is not perfect, the original interlaced image can be restored more correctly.

また、図20は、図19(A)のパターン画像を1.00倍から2.00倍まで0.01刻みの拡大倍率で通常のバイリニア法で拡大した後、元のサイズに縮小したときの、各縮小画像と元のパターン画像とのPSNR(ピーク信号対雑音比)のグラフである。図20には、通常のバイリニア法で縮小した場合と、第2実施形態に係るバイリニア法で縮小した場合の2つのグラフが示されている。同図によると、後者の場合の方がPSNRが大きく、特に拡大倍率が大きい程、その傾向が顕著であることが分かる。このことからも、第2実施形態に係るバイリニア法によれば、オリジナルインターレース画像をより正しく復元できることが分かる。 Further, FIG. 20 shows a case where the pattern image of FIG. 19 (A) is enlarged from 1.00 times to 2.00 times by a normal bilinear method at a magnification of 0.01 and then reduced to the original size. , It is a graph of PSNR (peak signal-to-noise ratio) of each reduced image and the original pattern image. FIG. 20 shows two graphs, one is reduced by the normal bilinear method and the other is reduced by the bilinear method according to the second embodiment. According to the figure, it can be seen that the latter case has a larger PSNR, and the larger the magnification is, the more remarkable the tendency is. From this, it can be seen that the original interlaced image can be restored more correctly according to the bilinear method according to the second embodiment.

下表1〜4は、横画素数1のオリジナルインターレース画像をある拡大倍率で拡大し、さらにその逆数の縮小倍率で縮小したときの、拡縮後の画素値を形成する、拡縮前の各画素の画素値の構成割合を示す。言い換えると、下表1〜4は、下式中の拡縮前の画素値P0,jと、拡縮後の数17のDsti,jとの一致度を示している。なお、下式中のDst0,jは、拡縮後の画像のj行の画素値を意味する(j=1,2,・・・,H)。また、下式中、P0,jは、オリジナルインターレース画像のj行の画素値であり、vjは、その係数である。

Figure 0006928772
Tables 1 to 4 below show the pixel values after scaling when the original interlaced image with 1 horizontal pixel is enlarged at a certain magnification and then reduced at the reciprocal of the reduction magnification. The composition ratio of the pixel value is shown. In other words, Tables 1 to 4 below show the degree of agreement between the pixel values P 0, j before scaling in the following equation and the number 17 Dst i, j after scaling. Note that Dst 0, j in the following equation means the pixel value of row j of the image after scaling (j = 1, 2, ..., H). Further, in the following equation, P 0, j is the pixel value of row j of the original interlaced image, and v j is the coefficient thereof.
Figure 0006928772

表1は、拡大倍率125%で通常のバイリニア法で拡大した後、第2実施形態に係るバイリニア法により元のサイズに縮小した結果を示しており、表2は、同倍率で通常のバイリニア法で拡大した後、通常のバイリニア法により元のサイズに縮小した結果を示している。一方、表3は、拡大倍率175%で通常のバイリニア法で拡大した後、第2実施形態に係るバイリニア法により元のサイズに縮小した結果を示しており、表4は、同倍率で通常のバイリニア法で拡大した後、通常のバイリニア法により元のサイズに縮小した結果を示している。 Table 1 shows the results of enlargement by the ordinary bilinear method at a magnification of 125% and then reduced to the original size by the bilinear method according to the second embodiment. Table 2 shows the results of reduction to the original size by the ordinary bilinear method at the same magnification. After enlarging with, the result of reducing to the original size by the usual bilinear method is shown. On the other hand, Table 3 shows the results of enlargement by the normal bilinear method at a magnification of 175% and then reduced to the original size by the bilinear method according to the second embodiment, and Table 4 shows the results of reduction to the original size at the same magnification. After enlarging by the bilinear method, it is reduced to the original size by the normal bilinear method.

Figure 0006928772
Figure 0006928772
Figure 0006928772
Figure 0006928772
Figure 0006928772
Figure 0006928772
Figure 0006928772
Figure 0006928772

新たな1つの画素値を生成するために、バイリニア法で使用する元の画素数は、横画素数を1とした場合、通常2画素である。そして、再度バイリニア法により、元のサイズまでサイズ調整するために使用される画素数も、2画素である。よって、拡縮後の2画素は、元の2画素又は3画素から生成されることになり、その構成割合が表1〜表4に示されている。拡縮後に元の画像を完全に復元するには、同じ画素の画素値が1:1に対応するようにしなければならないが、表2,4によれば、通常のバイリニア法で縮小すると、概ね元の2つの画素値が平均されて、拡縮後の画素値が生成されている。一方で、表1,3によれば、第2実施形態に係るバイリニア法で縮小すると、概ね拡縮の前後で同じ画素の画素値が1:1で対応しており、さらに倍率が高い程、この傾向が顕著である。よって、このことからも、第2実施形態に係るバイリニア法によれば、オリジナルインターレース画像をより正しく復元できることが分かる。 The original number of pixels used in the bilinear method for generating one new pixel value is usually two when the number of horizontal pixels is one. Then, the number of pixels used for adjusting the size to the original size by the bilinear method again is also two pixels. Therefore, the two pixels after scaling are generated from the original two pixels or three pixels, and the composition ratio thereof is shown in Tables 1 to 4. In order to completely restore the original image after scaling, the pixel values of the same pixels must correspond to 1: 1. The two pixel values of are averaged to generate the pixel value after scaling. On the other hand, according to Tables 1 and 3, when the reduction is performed by the bilinear method according to the second embodiment, the pixel values of the same pixels correspond to each other at a ratio of 1: 1 before and after the enlargement / reduction. The tendency is remarkable. Therefore, from this as well, it can be seen that the original interlaced image can be restored more correctly according to the bilinear method according to the second embodiment.

続くステップS25では、復元部42bは、複数の縮小倍率RR’及び2種類のOffset値の各組み合わせに対し、ステップS24の復元画像G1,G2,・・・,GNからそれぞれ2枚のフィールド画像を作成する。同ステップは、ステップS5と同様に実行される。また、表示制御部41により、複数の縮小倍率RR’及び2種類のOffset値の各組み合わせに対する復元画像G1,G2,・・・,GNがディスプレイ10上に表示される。ユーザは、これらの中から、目視にて最も良いものを選択することができる。 In subsequent step S25, restoring portion 42b, for each combination of a plurality of reduction ratio R R 'and two Offset value, the restored image G 1, G 2 step S24, · · ·, 2 sheets each of G N Create a field image of. This step is executed in the same manner as in step S5. Further, the display control unit 41, recovery with respect to each combination of the plurality of reduction ratio R R 'and two Offset value image G 1, G 2, ···, G N is displayed on the display 10. The user can visually select the best one from these.

以下に、本発明の実施例について説明するが、本発明はこれに限定されない。 Examples of the present invention will be described below, but the present invention is not limited thereto.

(1)実施例1及び2
比較例1として、図17Aに示す拡大インターレース画像(映像)に対し、通常のインターレース解除を行った結果を図17Bに示す。
(1) Examples 1 and 2
As Comparative Example 1, FIG. 17B shows the result of performing normal deinterlacing on the enlarged interlaced image (video) shown in FIG. 17A.

また、同じく図17Aに示す拡大インターレース画像に対し、図5のフローチャートに示される特殊インターレース解除を行った。図17Cは、ステップS3による縮小処理の結果を示しており、図17Dは、ステップS4による滲み補正処理の結果を示しており、図17Eは、ステップS5によるインターレース解除の結果(実施例1)を示している。さらに、図17Fは、図17Cの画像に対し、通常のインターレース解除を行った結果(実施例2)を示している。 Further, the enlarged interlaced image also shown in FIG. 17A was deinterlaced as shown in the flowchart of FIG. FIG. 17C shows the result of the reduction process in step S3, FIG. 17D shows the result of the bleeding correction process in step S4, and FIG. 17E shows the result of deinterlacing in step S5 (Example 1). Shown. Further, FIG. 17F shows the result (Example 2) of performing normal deinterlacing on the image of FIG. 17C.

実施例1(図17E)及び実施例2(図17F)と比較例1(図17B)と比較すれば明らかなとおり、比較例1に対し実施例1,2ではいずれも正しく元の画像を復元できていることが分かる。また、実施例1と実施例2とを比較すれば明らかな通り、ステップS4の滲み補正処理により、より正しく元の画像を復元できることが分かる。 As is clear from comparison between Example 1 (FIG. 17E) and Example 2 (FIG. 17F) and Comparative Example 1 (FIG. 17B), the original images are correctly restored in each of Examples 1 and 2 with respect to Comparative Example 1. You can see that it is done. Further, as is clear from comparing Example 1 and Example 2, it can be seen that the original image can be restored more accurately by the bleeding correction process in step S4.

(2)実施例3
図17Aの拡大インターレース画像(映像)に対し、ステップS21〜S24と同様の方法により複数の縮小倍率を推定し、複数の復元画像を復元した。そして、複数の復元画像の中から、目視により最も良いと思われる復元画像を選択し、インターレース解除を行ったところ、図21に示す結果が得られた。図21の2枚のフィールド画像には、互いの絵柄の影響が残っているものの、通常のインターレース解除の結果を示す図17Bの比較例1に比べてその影響が少なく、第2実施形態に係る特殊インターレース解除により、より正しく元の画像を復元できることが分かる。
(2) Example 3
With respect to the enlarged interlaced image (video) of FIG. 17A, a plurality of reduction magnifications were estimated by the same method as in steps S21 to S24, and a plurality of restored images were restored. Then, the most suitable restored image was visually selected from the plurality of restored images, and deinterlacing was performed. As a result, the result shown in FIG. 21 was obtained. Although the influence of each other's patterns remains on the two field images of FIG. 21, the influence is less than that of Comparative Example 1 of FIG. 17B showing the result of normal deinterlacing, and the second embodiment is related to the second embodiment. It can be seen that the original image can be restored more correctly by deinterlacing the special image.

(3)実施例4〜6
第2実施形態に係る特殊インターレース解除の効果を確認するため、図22に示す6種類の画像(映像)を用意した。これらの画像は拡大がされていない通常のインターレース画像である。図22中、最小サイズの画像がサンプル5で、320×240画素であり、最大サイズの画像がサンプル6で、640×480画素である。他の画像も相対的なサイズが保持されている。また、サンプル3は、小さく映った人々が動いている映像であり、サンプル6は、上下方向に大きく手振れしている映像である。
(3) Examples 4 to 6
In order to confirm the effect of the special deinterlacing according to the second embodiment, six types of images (videos) shown in FIG. 22 were prepared. These images are normal interlaced images that have not been magnified. In FIG. 22, the smallest size image is sample 5 and has 320 × 240 pixels, and the maximum size image is sample 6 and has 640 × 480 pixels. Other images also retain their relative size. Further, the sample 3 is an image in which people appearing small are moving, and the sample 6 is an image in which the camera shakes greatly in the vertical direction.

以上の6種類の画像を、1.000倍から2.000倍まで0.001刻みの拡大倍率で通常のバイリニア法で拡大した後、ステップS21〜S23と同様の方法により候補となる複数の縮小倍率を推定した。なお、サンプル1〜6については、拡大前の元画像のサイズが分かっているため、候補となる複数の縮小倍率の中に正解が含まれているか否かを調べた。その結果を正答率として、表5に示す。また、縮小倍率の推定時において、自己加重平均画像の生成には、各サンプルに対し、50枚のフレームを使用した。

Figure 0006928772
After enlarging the above six types of images from 1.000 times to 2.000 times at a magnification of 0.001 by the usual bilinear method, a plurality of candidate reductions are performed by the same method as in steps S21 to S23. The magnification was estimated. Since the size of the original image before enlargement is known for samples 1 to 6, it was examined whether or not the correct answer was included in the plurality of candidate reduction magnifications. The results are shown in Table 5 as the correct answer rate. Further, at the time of estimating the reduction magnification, 50 frames were used for each sample to generate the self-weighted average image.
Figure 0006928772

正答率について考察すると、候補内に縮小倍率の正答が含まれる割合は、98.5%〜99.5%であり、候補の中にほぼ正解が含まれると言える。また、候補の中間の値が正答となる割合について調べたところ、79.8%〜97.55%となり、こちらも高い値が得られた。従って、ステップS22に関し、Horgが真値からずれることがある問題について述べたが、中間の値を正答とすることも可能であることが分かった。なお、数15の第1式のhが偶数の場合、候補は2つになるが、この場合、2つの候補のうち小数部を切り捨てる前の値に近い方を選択し、ここでいう中間の値とした。 Considering the correct answer rate, the ratio of the correct answers of the reduction ratio included in the candidates is 98.5% to 99.5%, and it can be said that the candidates include almost the correct answers. In addition, when the ratio of the middle value of the candidates being the correct answer was investigated, it was 79.8% to 97.55%, which was also a high value. Accordingly relates step S22, although H org is described issues that may deviate from the true value, it was found that it is possible to make the intermediate value and the correct answer. If h in the first equation of Equation 15 is an even number, there are two candidates. In this case, the one of the two candidates that is closer to the value before the fractional part is truncated is selected, and the middle one is referred to here. It was set as a value.

縮小倍率の候補の中に正解が含まれるか否かに関わらず、各サンプルに由来する拡大インターレース画像(映像)に対し、ステップS21〜S24と同様の方法で複数の復元画像を作成した(実施例4)。同時に、各サンプルに由来する拡大インターレース画像(映像)に対し、通常のバイリニア法で複数の復元画像を作成した(比較例4)。そして、これらの復元画像の中から無作為に1フレームを選択し、拡縮前後の絵柄の一致度合いをPSNRによって評価した結果を表5に示す。これによると、1.833〜5.508の改善効果(復元効果)が認められた。サンプル3のように動いている物体が小さい場合には、実施例4及び比較例4間の差が小さくなっている。一方、非常に動きの激しいサンプル6のような画像では、改善効果が特に大きいことが確認された。なお、インターレース解除後の画像についても同様の比較を行ったが、同様の結果であった。 Regardless of whether or not the correct answer is included in the reduction magnification candidates, a plurality of restored images were created for the enlarged interlaced image (video) derived from each sample by the same method as in steps S21 to S24 (implementation). Example 4). At the same time, a plurality of restored images were created for the enlarged interlaced image (video) derived from each sample by a normal bilinear method (Comparative Example 4). Then, one frame is randomly selected from these restored images, and the result of evaluating the degree of matching of the patterns before and after scaling by PSNR is shown in Table 5. According to this, an improvement effect (restoration effect) of 1.833 to 5.508 was recognized. When the moving object is small as in sample 3, the difference between Example 4 and Comparative Example 4 is small. On the other hand, it was confirmed that the improvement effect was particularly large in an image such as Sample 6 in which the movement was extremely vigorous. Similar comparisons were made for the images after deinterlacing, but the results were similar.

図23〜図28に、それぞれサンプル1〜6の画像を拡大倍率1.3倍及び1.6倍で通常のバイリニア法で拡大し、第2実施形態に係るバイリニア法及び通常のバイリニア法で元のサイズに復元した場合の復元画像と、それぞれの場合のPSNRとを示す(実施例5、比較例5)。また、例として、サンプル3,6の場合における拡大倍率とPSNRとの関係を図29及び図30に示す。図29及び図30に示すように、図20の場合と同様、サンプル3では、第2実施形態に係るアルゴリズムの効果が低倍率において薄れるものの、高倍率では効果の上昇が確認された。また、サンプル6では、第2実施形態に係るアルゴリズムの効果が常に確認された。また、図23〜図28を見ると、目視においては、常に第2実施形態に係るアルゴリズムが通常のバイリニア法よりも効果が高いことが分かる。 In FIGS. 23 to 28, the images of the samples 1 to 6 are magnified by the usual bilinear method at magnifications of 1.3 times and 1.6 times, respectively, and the original bilinear method and the normal bilinear method according to the second embodiment are used. The restored image when restored to the size of (Example 5, Comparative Example 5) is shown. Further, as an example, the relationship between the magnification and PSNR in the case of Samples 3 and 6 is shown in FIGS. 29 and 30. As shown in FIGS. 29 and 30, in Sample 3, the effect of the algorithm according to the second embodiment diminishes at a low magnification, but an increase in the effect is confirmed at a high magnification, as in the case of FIG. Further, in sample 6, the effect of the algorithm according to the second embodiment was always confirmed. Further, from FIGS. 23 to 28, it can be visually seen that the algorithm according to the second embodiment is always more effective than the ordinary bilinear method.

図31に、サンプル3に係る図25の画像をインターレース解除した画像を示す(実施例6、比較例6)。同図に示すように、実施例6では、比較例6よりも、多少コントラストが強まっているものの、低倍率でも特に問題はないことが分かり、第2実施形態に係るアルゴリズムの優位性が示された。 FIG. 31 shows an image obtained by deinterlacing the image of FIG. 25 according to the sample 3 (Example 6, Comparative Example 6). As shown in the figure, in Example 6, although the contrast is slightly stronger than that in Comparative Example 6, it was found that there is no particular problem even at a low magnification, and the superiority of the algorithm according to the second embodiment is shown. rice field.

1 画像処理装置
2 画像処理プログラム
42a 検出部(パターン検出部)
42b 復元部
42c 補正部(滲み補正部)
1 Image processing device 2 Image processing program 42a Detection unit (Pattern detection unit)
42b Restoration unit 42c Correction unit (bleeding correction unit)

Claims (16)

オリジナルインターレース画像が拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理装置であって、
前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出し、前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への縮小倍率を算出するパターン検出部と、
前記縮小倍率に基づいて、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成する復元部と
を備える、画像処理装置。
An image processing device that restores the original interlaced image from an enlarged interlaced image in which the original interlaced image is enlarged.
By image processing the enlarged interlaced image, a striped pattern due to combing noise included in the magnified interlaced image is detected, and the enlarged interlaced image is reduced to the original interlaced image based on the striped pattern. A pattern detector that calculates the magnification and
An image processing device including a restored image obtained by restoring the original interlaced image based on the reduced magnification and a restoration unit for creating at least one of a field image constituting the restored image.
前記パターン検出部は、
前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への仮の縮小倍率を算出し、
前記仮の縮小倍率及び前記拡大インターレース画像の縦画素数に基づいて、前記オリジナルインターレース画像の縦画素数の候補となる候補画素数を複数設定し、
前記複数の候補画素数にそれぞれ対応する複数の前記縮小倍率を算出し、
前記復元部は、前記複数の縮小倍率の各々に対し、前記復元画像及び前記フィールド画像の少なくとも一方を作成する、
請求項1に記載の画像処理装置。
The pattern detection unit
Based on the striped pattern, a temporary reduction magnification from the enlarged interlaced image to the original interlaced image is calculated.
Based on the provisional reduction magnification and the number of vertical pixels of the enlarged interlaced image, a plurality of candidate pixels that are candidates for the number of vertical pixels of the original interlaced image are set.
A plurality of the reduction magnifications corresponding to the plurality of candidate pixels are calculated, and the reduction ratios are calculated.
The restoration unit creates at least one of the restoration image and the field image for each of the plurality of reduction magnifications.
The image processing apparatus according to claim 1.
前記複数の候補画素数は、全て偶数である、
請求項2に記載の画像処理装置。
The plurality of candidate pixels are all even numbers.
The image processing apparatus according to claim 2.
前記復元部は、線形補間のアルゴリズムを用いて前記拡大インターレース画像を前記縮小倍率で縮小することにより、前記復元画像を作成する、
請求項1から3のいずれかに記載の画像処理装置。
The restoration unit creates the restoration image by reducing the enlarged interlaced image at the reduction magnification using an algorithm of linear interpolation.
The image processing apparatus according to any one of claims 1 to 3.
オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理装置であって、
前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出し、前記縞模様のパターンに基づいて、前記拡大インターレース画像に含まれる前記追加行の位置を特定するパラメータを算出するパターン検出部と、
前記追加行の位置を特定するパラメータに基づいて、前記拡大インターレース画像から前記追加行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成する復元部と、
を備える、画像処理装置。
An image processing device that restores the original interlaced image from an enlarged interlaced image magnified at a certain magnification by adding additional lines to the original interlaced image at predetermined intervals.
By image processing the enlarged interlaced image, a striped pattern due to combing noise included in the magnified interlaced image is detected, and the position of the additional line included in the magnified interlaced image is determined based on the striped pattern. A pattern detector that calculates the parameters that specify
By removing the additional row from the enlarged interlaced image based on the parameter for specifying the position of the additional row, at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image is created. Restoration part and
An image processing device.
前記追加行の位置を特定するパラメータには、前記拡大倍率が含まれる、
請求項5に記載の画像処理装置。
The parameter that identifies the position of the additional row includes the magnification factor.
The image processing apparatus according to claim 5.
前記パターン検出部は、
1行おきの縞模様のパターンを有する画像を前記拡大倍率と同じ倍率で拡大した画像である拡大パターン画像と、前記拡大インターレース画像とを、両画像の前記縞模様のパターンが最も一致するように位置合わせし、
前記位置合わせの結果に基づいて、前記追加行の位置を特定するパラメータを算出する、
請求項5又は6に記載の画像処理装置。
The pattern detection unit
The magnified pattern image, which is an image obtained by enlarging an image having a striped pattern every other line at the same magnification as the magnified magnification, and the magnified interlaced image so that the striped patterns of both images match most. Align and
Based on the result of the alignment, a parameter for specifying the position of the additional row is calculated.
The image processing apparatus according to claim 5 or 6.
前記復元画像の滲みを除去する滲み補正部
をさらに備える、
請求項5から7のいずれかに記載の画像処理装置。
A bleeding correction unit for removing bleeding of the restored image is further provided.
The image processing apparatus according to any one of claims 5 to 7.
前記滲み補正部は、滲みパターン画像に含まれる画素値から補正係数を算出し、前記補正係数に基づいて前記復元画像の画素値を補正し、
前記滲みパターン画像は、1行おきの縞模様のパターンを有する画像を、前記拡大倍率と同じ倍率で拡大した後、前記拡大倍率の逆数の縮小倍率で縮小した画像である、
請求項8に記載の画像処理装置。
The bleeding correction unit calculates a correction coefficient from the pixel value included in the bleeding pattern image, and corrects the pixel value of the restored image based on the correction coefficient.
The blur pattern image is an image in which an image having a striped pattern every other line is enlarged at the same magnification as the enlargement magnification and then reduced at a reduction magnification that is the reciprocal of the enlargement magnification.
The image processing apparatus according to claim 8.
前記縞模様のパターンには、前記縞模様の周期が含まれる、
請求項1から9のいずれかに記載の画像処理装置。
The striped pattern includes the striped cycle.
The image processing apparatus according to any one of claims 1 to 9.
前記拡大インターレース画像は、複数枚のフレームを含む動画であり、
前記パターン検出部は、
前記複数枚のフレームから前記コーミングノイズを強調したノイズ強調画像を作成し、
前記ノイズ強調画像の各行間の差分を表す差分画像を作成し、
前記差分画像の各行に含まれる画素値の特徴を表す縦方向プロファイルを作成し、
前記縦方向プロファイルのパワースペクトルのピークの位置から、前記縞模様の周期を算出する、
請求項10に記載の画像処理装置。
The enlarged interlaced image is a moving image including a plurality of frames.
The pattern detection unit
A noise-enhanced image in which the combing noise is emphasized is created from the plurality of frames, and the noise-enhanced image is created.
A difference image showing the difference between each line of the noise-enhanced image is created.
A vertical profile representing the characteristics of the pixel values included in each line of the difference image is created.
The period of the striped pattern is calculated from the position of the peak of the power spectrum of the vertical profile.
The image processing apparatus according to claim 10.
オリジナルインターレース画像が拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理プログラムであって、
前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップと、
前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への縮小倍率を算出するステップと、
前記縮小倍率に基づいて、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップと
をコンピュータに実行させる、画像処理プログラム。
An image processing program that restores the original interlaced image from the enlarged interlaced image in which the original interlaced image is enlarged.
A step of detecting a striped pattern due to combing noise included in the enlarged interlaced image by image processing the enlarged interlaced image, and a step of detecting the striped pattern due to combing noise.
A step of calculating the reduction magnification from the enlarged interlaced image to the original interlaced image based on the striped pattern, and
An image processing program that causes a computer to perform a step of creating at least one of a restored image obtained by restoring the original interlaced image and a field image constituting the restored image based on the reduced magnification.
オリジナルインターレース画像が拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理方法であって、
前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップと、
前記縞模様のパターンに基づいて、前記拡大インターレース画像から前記オリジナルインターレース画像への縮小倍率を算出するステップと、
前記縮小倍率に基づいて、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップと
を含む、画像処理方法。
This is an image processing method for restoring the original interlaced image from the enlarged interlaced image in which the original interlaced image is enlarged.
A step of detecting a striped pattern due to combing noise included in the enlarged interlaced image by image processing the enlarged interlaced image, and a step of detecting the striped pattern due to combing noise.
A step of calculating the reduction magnification from the enlarged interlaced image to the original interlaced image based on the striped pattern, and
An image processing method including a step of creating at least one of a restored image obtained by restoring the original interlaced image and a field image constituting the restored image based on the reduced magnification.
オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理プログラムであって、
前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップと、
前記縞模様のパターンに基づいて、前記拡大インターレース画像に含まれる前記追加行の位置を特定するパラメータを算出するステップと、
前記追加行の位置を特定するパラメータに基づいて、前記拡大インターレース画像から前記追加行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップと
をコンピュータに実行させる、画像処理プログラム。
An image processing program that restores the original interlaced image from an enlarged interlaced image magnified at a certain magnification by adding additional lines to the original interlaced image at predetermined intervals.
A step of detecting a striped pattern due to combing noise included in the enlarged interlaced image by image processing the enlarged interlaced image, and a step of detecting the striped pattern due to combing noise.
A step of calculating a parameter for specifying the position of the additional row included in the enlarged interlaced image based on the striped pattern, and a step of calculating the parameter.
By removing the additional row from the enlarged interlaced image based on the parameter for specifying the position of the additional row, at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image is created. An image processing program that lets your computer perform the steps you want to take.
オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理方法であって、
前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれるコーミングノイズによる縞模様のパターンを検出するステップと、
前記縞模様のパターンに基づいて、前記拡大インターレース画像に含まれる前記追加行の位置を特定するパラメータを算出するステップと、
前記追加行の位置を特定するパラメータに基づいて、前記拡大インターレース画像から前記追加行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成するフィールド画像の少なくとも一方を作成するステップと
を含む、画像処理方法。
An image processing method for restoring an original interlaced image from an enlarged interlaced image enlarged at a certain magnification by adding additional lines to the original interlaced image at predetermined intervals.
A step of detecting a striped pattern due to combing noise included in the enlarged interlaced image by image processing the enlarged interlaced image, and a step of detecting the striped pattern due to combing noise.
A step of calculating a parameter for specifying the position of the additional row included in the enlarged interlaced image based on the striped pattern, and a step of calculating the parameter.
By removing the additional row from the enlarged interlaced image based on the parameter for specifying the position of the additional row, at least one of the restored image obtained by restoring the original interlaced image and the field image constituting the restored image is created. Image processing methods, including steps to be performed.
オリジナルインターレース画像に所定の間隔で追加行が追加されたことにより、前記オリジナルインターレース画像がある拡大倍率で拡大された拡大インターレース画像から、前記オリジナルインターレース画像を復元する画像処理装置であって、
前記拡大インターレース画像を画像処理することにより、前記拡大インターレース画像に含まれる画素値が同じ又は略同じ重複行を検出する検出部と、
前記拡大インターレース画像から前記重複行を除去することにより、前記オリジナルインターレース画像を復元した復元画像及び前記復元画像を構成する2枚のフィールド画像の少なくとも一方を作成する復元部と
を備える、画像処理装置。
An image processing device that restores the original interlaced image from an enlarged interlaced image magnified at a certain magnification by adding additional lines to the original interlaced image at predetermined intervals.
By performing image processing on the enlarged interlaced image, a detection unit that detects overlapping rows having the same or substantially the same pixel value included in the enlarged interlaced image, and a detection unit.
An image processing apparatus including a restored image obtained by restoring the original interlaced image and a restoration unit for creating at least one of two field images constituting the restored image by removing the overlapping lines from the enlarged interlaced image. ..
JP2017117786A 2017-01-17 2017-06-15 Image processing device Active JP6928772B2 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2017006188 2017-01-17
JP2017006188 2017-01-17

Publications (2)

Publication Number Publication Date
JP2018117334A JP2018117334A (en) 2018-07-26
JP6928772B2 true JP6928772B2 (en) 2021-09-01

Family

ID=62984393

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017117786A Active JP6928772B2 (en) 2017-01-17 2017-06-15 Image processing device

Country Status (1)

Country Link
JP (1) JP6928772B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112947822B (en) * 2019-12-10 2024-09-10 中兴通讯股份有限公司 A method, device, equipment and storage medium for picture selection operation feedback

Also Published As

Publication number Publication date
JP2018117334A (en) 2018-07-26

Similar Documents

Publication Publication Date Title
JP5243833B2 (en) Image signal processing circuit, image display device, and image signal processing method
CN107169927B (en) An image processing system, method and display device
JP5038483B2 (en) Video data deinterlacing
JP5039192B2 (en) Spatio-temporal adaptive video deinterlacing
CN105264567A (en) Methods of image fusion for image stabilizaton
JPWO2011111819A1 (en) Image processing apparatus, image processing program, and method for generating image
CN106031145A (en) Image processing apparatus and image processing method
JP2015180048A (en) Image processing apparatus and image processing method
US9215353B2 (en) Image processing device, image processing method, image display device, and image display method
JP6928772B2 (en) Image processing device
US8749706B2 (en) Image processing apparatus and recording medium storing image processing program
JP5962278B2 (en) Image processing program, image processing apparatus, and image processing method
JP5095263B2 (en) Image evaluation apparatus and image evaluation program
JP5364264B2 (en) Location detection of block defect using neural network
JP6520920B2 (en) Image processing device
JP4492100B2 (en) Image signal processing apparatus and processing method
WO2011027422A9 (en) Image processing apparatus and video reproducing device
JP4982331B2 (en) Image evaluation apparatus and image evaluation program
JP2005084088A (en) Image comparison display method and its device, and image comparison display program
JP4714062B2 (en) Image enlarging apparatus for generating a high resolution image, image enlarging method thereof, and recording medium recording the image enlarging program
JP5121639B2 (en) Image processing apparatus and image processing method
WO2024214381A1 (en) Image processing device, image processing method, and program
JP2008271085A (en) Video scaling device
JP5884482B2 (en) Image processing program, image processing apparatus, and image processing method
JP4708811B2 (en) Method for converting interlaced image data into progressive image data, apparatus therefor and program therefor

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20200604

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20210528

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20210625

R150 Certificate of patent or registration of utility model

Ref document number: 6928772

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250