JP2006308665A - Image processing apparatus - Google Patents

Image processing apparatus Download PDF

Info

Publication number
JP2006308665A
JP2006308665A JP2005128089A JP2005128089A JP2006308665A JP 2006308665 A JP2006308665 A JP 2006308665A JP 2005128089 A JP2005128089 A JP 2005128089A JP 2005128089 A JP2005128089 A JP 2005128089A JP 2006308665 A JP2006308665 A JP 2006308665A
Authority
JP
Japan
Prior art keywords
pixel
output
image
coefficient
edge
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.)
Withdrawn
Application number
JP2005128089A
Other languages
Japanese (ja)
Inventor
Kenji Inoue
井上  健治
Hidekazu Matsuzaki
英一 松崎
Takashi Tsunoda
孝 角田
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2005128089A priority Critical patent/JP2006308665A/en
Publication of JP2006308665A publication Critical patent/JP2006308665A/en
Withdrawn legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformation in the plane of the image
    • G06T3/40Scaling the whole image or part thereof
    • G06T3/403Edge-driven scaling

Abstract

<P>PROBLEM TO BE SOLVED: To provide an image processing apparatus, capable of attaining excellent image quality by improving image blurring generated when magnifying and pixel disappearance generated when contracting, regarding the image processing apparatus in which an image is displayed in an arbitrary resolution of a user. <P>SOLUTION: The apparatus comprises; an arithmetic device for calculating a pixel value which is interpolated by a three dimensional convolution interpolation method; a line buffer controller for outputting pixel data used for the calculation in a certain pixel group; a sorting device for sequentially sorting the pixel group; an edge detector for detecting an edge of an image from the pixel group; an inverse arithmetic circuit which is characterized by applying compensation to arguments of a coefficient table based on information from the edge detector; and a coefficient table for supplying an arithmetic coefficient from the arguments outputted by the inverse arithmetic circuit. When the edge is detected, compensation is applied to the arguments. <P>COPYRIGHT: (C)2007,JPO&INPIT

Description

本発明は、画像処理装置に関し、特にコンピュータやテレビ等の画像を表示する必要のある機器に関するものである。   The present invention relates to an image processing apparatus, and more particularly to a device such as a computer or a television that needs to display an image.

一般にコンピュータは表示装置の解像度にあわせて複数種類の解像度を表示させることが可能である。例えば表示装置の最高解像度がXGAであるならば、コンピュータはXGAとそれ以下の解像度(VGA,SVGA)の画像を表示させることが必要とされる場合が多い。これはユーザーの好みにより、より多くの情報を画面上に表示したり、より見やすくするために大きく表示したり、を選択できるようにするためである。   In general, a computer can display a plurality of types of resolutions in accordance with the resolution of a display device. For example, if the maximum resolution of the display device is XGA, the computer is often required to display images of XGA and lower resolutions (VGA, SVGA). This is because it is possible to select whether to display more information on the screen or to display the information larger for easier viewing according to the user's preference.

この時、コンピュータ本体が表示装置に対して所望の解像度を提供するために解像度変換技術が必要となる。   At this time, a resolution conversion technique is required for the computer main body to provide a desired resolution to the display device.

また、テレビに関しては従来日本ではNTSC方式が採用されてきた。これは走査線が483〜485本、走査線1本当たりの画素数は720〜760、総画素数約35万画素である。ただし通常はインターレースで表示されるため、実際は15万画素程度の分解能となっている。   In Japan, the NTSC system has been adopted in Japan. This is 483 to 485 scanning lines, the number of pixels per scanning line is 720 to 760, and the total number of pixels is about 350,000 pixels. However, since it is normally displayed in an interlaced manner, the resolution is actually about 150,000 pixels.

これに対し近年ではハイビジョン方式も多く使われるようになってきた。ハイビジョン方式はHDとも呼ばれ、約75万画素である。これに対応して従来のNTSC放送はSDと呼ばれる。   On the other hand, in recent years, the high-definition method has been widely used. The high-definition method is also called HD and has about 750,000 pixels. Corresponding to this, the conventional NTSC broadcast is called SD.

さらにはデジタル放送では480i、720p、1080iといった画像フォーマットがある。480iは640×480のインターレース、720pは1024×720のプログレッシブ、1080iは1280×1080のインターレースを表している。   Furthermore, there are image formats such as 480i, 720p, and 1080i in digital broadcasting. 480i represents a 640 × 480 interlace, 720p represents a 1024 × 720 progressive, and 1080i represents a 1280 × 1080 interlace.

他にもパソコンの画像表示やゲーム、デジカメの映像表示といった用途や、複数の画面を表示させるマルチ画面表示、といった用途があり、テレビ上に多くのフォーマットの画像を表示する機会が増えてきた。   There are other uses such as PC image display, game display, digital camera video display, and multi-screen display for displaying multiple screens, and the opportunity to display images in many formats on the TV has increased.

ここで、従来のNTSC放送のようなアナログデータならばサンプリングレートを変えることによって比較的容易に画像のフォーマット変換が可能である。しかし、デジタル放送やデジカメ画像といったデジタルデータのフォーマット変換を行うためには画像データの補間や間引きを行う必要がある。   Here, in the case of analog data such as conventional NTSC broadcasting, it is possible to convert the image format relatively easily by changing the sampling rate. However, in order to convert the format of digital data such as digital broadcasting and digital camera images, it is necessary to perform interpolation and thinning of the image data.

また、マルチ画面表示のような表示効果をもたせるためには画像のフォーマット変換と共に、画像を拡大縮小するための解像度変換が必要となる。   In addition, in order to provide a display effect such as multi-screen display, it is necessary to perform resolution conversion for enlarging / reducing an image as well as image format conversion.

解像度変換の技術を大別すると周波数変調と、時間変調と、に分けられる。   The resolution conversion techniques are roughly classified into frequency modulation and time modulation.

周波数変調は画像データをDCTなどにより一旦、周波数領域に変換してから解像度変換のための信号処理を行うものである。表示装置に画像を映し出すためには周波数領域のデータでは表示できないので、出力時には周波数領域から時間領域のデータに再変換する必要がある。このため回路規模が大きくなりやすい。   In frequency modulation, image data is once converted into a frequency domain by DCT or the like, and then signal processing for resolution conversion is performed. In order to display an image on the display device, since it cannot be displayed with frequency domain data, it is necessary to reconvert from frequency domain to time domain data at the time of output. For this reason, the circuit scale tends to increase.

一方、時間変調では入力されたデータを時間順に処理していく。補間しようとする画素値をその前後の画素値から推測する方式である。   On the other hand, in time modulation, input data is processed in time order. In this method, the pixel value to be interpolated is estimated from the pixel values before and after the pixel value.

時間変調では一般的には周波数変調より簡易な回路で構成することが可能である。   In general, the time modulation can be configured with a simpler circuit than the frequency modulation.

時間変調の代表例として、最近傍法、線形補間法、畳み込み内挿法がある。図10は各補間方式の画素補間方法を説明した図である。各図において、縦軸は画素値、横軸は解像度変換前の元座標を表している。図10(a)は変換前の元画像を表し、座標0,1,3,4,5の画素値が同じ値で座標2の画素値のみが異なる画像を表している。図10(b),(c),(d)では、元座標を3倍に解像度変換した場合の、補間画素の画素値のとり方を表している。本図では元画像のどの座標の値を参照したのかがわかるように、横軸の参照座標は元座標を表している。(b)は最近傍法、(c)は線形補間法、(d)は畳み込み内挿法、を表している。   Typical examples of time modulation include nearest neighbor method, linear interpolation method, and convolutional interpolation method. FIG. 10 is a diagram illustrating a pixel interpolation method of each interpolation method. In each figure, the vertical axis represents pixel values, and the horizontal axis represents original coordinates before resolution conversion. FIG. 10A shows an original image before conversion, and shows an image in which the pixel values at coordinates 0, 1, 3, 4, and 5 are the same and only the pixel value at coordinates 2 is different. FIGS. 10B, 10C, and 10D show how to obtain the pixel value of the interpolation pixel when the resolution of the original coordinates is converted to three times. In this figure, the reference coordinate on the horizontal axis represents the original coordinate so that it can be understood which coordinate value of the original image is referred to. (B) represents the nearest neighbor method, (c) represents a linear interpolation method, and (d) represents a convolutional interpolation method.

最近傍法は、補間画素の位置が元画素のどの位置に最も近いかを判断し、最も近い元画素の値をとる方式である。この方式は上記3方式の中で、最も回路を簡易にできる。しかし、参照画素が1画素になるため、画像のギザギザ感が発生しやすい。   The nearest neighbor method is a method of determining the position of the original pixel closest to the position of the interpolation pixel and taking the value of the closest original pixel. This method can simplify the circuit most among the above three methods. However, since the reference pixel is one pixel, a jagged feeling of the image is likely to occur.

線形補間法は、補間画素の前後2画素(縦横4画素)を参照し、その画素値を直線で結び、その直線上の値を補間画素の画素値とする方式である。これにより最近傍法で発生していたような画像のギザギザ感を解消することができる。しかし、この方式では2画素間の変化しか見ていないため、その部分の画素変化が急激な変化なのか滑らかな変化なのかが判断できない。線形補間法では、滑らかに変化しているものとして画素値を補間しているので、ボケた画像になってしまう、という問題がある。   The linear interpolation method is a method of referring to two pixels before and after an interpolation pixel (four pixels in length and width), connecting the pixel values with a straight line, and setting the value on the straight line as the pixel value of the interpolation pixel. As a result, it is possible to eliminate the jagged feeling of the image that occurs in the nearest neighbor method. However, since only a change between two pixels is observed in this method, it cannot be determined whether the pixel change in that portion is a sudden change or a smooth change. In the linear interpolation method, since the pixel values are interpolated on the assumption that they change smoothly, there is a problem that the image becomes blurred.

畳み込み内挿法は、補間画素の前後4画素(縦横16画素)を参照し、その画素値を曲線で結び、その曲線上の値を補間画素の画素値とする方式である。この方式では画素値変化を重み付けに反映させ、エッジを強調することができるので線形補間法よりも画像のボケを改善させることができる。   The convolutional interpolation method is a method in which four pixels before and after the interpolation pixel (16 pixels in length and width) are referred to, the pixel values are connected by a curve, and the value on the curve is used as the pixel value of the interpolation pixel. In this method, the pixel value change is reflected in the weighting and the edge can be emphasized, so that the blur of the image can be improved as compared with the linear interpolation method.

また、画像のボケを改善する手法として一般的に図11のようなエッジ強調回路が用いられている。この手法では注目画素の画素値にその前後の画素値の(−1/2)の値を加算することによって、エッジ成分を検出し、そのエッジ成分に任意の係数をかけたものを注目画素に加算することによってエッジの強弱を制御するものである。   Further, an edge enhancement circuit as shown in FIG. 11 is generally used as a method for improving image blur. In this method, an edge component is detected by adding (−½) of the pixel value before and after the pixel value of the target pixel, and an arbitrary coefficient is applied to the edge component as the target pixel. By adding, the strength of the edge is controlled.

また、畳み込み内挿法を用いずに、線形補間法で画像のボケを改善する手法が特許文献1に開示されている。この手法では、補間画素演算を行う前に、隣接する4つの画素からエッジの方向性を検出し、演算係数を変化させることにより画像のボケを改善しようとしている。   Further, Patent Document 1 discloses a method for improving image blur by linear interpolation without using convolution interpolation. In this method, before performing the interpolation pixel calculation, the directionality of the edge is detected from four adjacent pixels, and the calculation coefficient is changed to improve the blur of the image.

ここで、畳み込み内挿法について簡単に説明する。   Here, the convolution interpolation method will be briefly described.

畳み込み演算はOutput1画素につき元画像の16個の画素と、8個の係数を用いて算出する。   The convolution operation is calculated using 16 pixels of the original image and 8 coefficients for each Output 1 pixel.

ここで、
変換前座標:x,y
変換後座標:X,Y
変換式:X=A*x、Y=B*y(A:x方向倍率、B:y方向倍率)
とすると、実際には変換前座標(x,y)は非連続数であり、変換後座標(X,Y)は連続数となるから、
逆変換式:x=X/A
y=Y/B…(式1)
を用いて変換前座標を求める。
here,
Pre-conversion coordinates: x, y
Coordinates after conversion: X, Y
Conversion formula: X = A * x, Y = B * y (A: x-direction magnification, B: y-direction magnification)
Then, since the coordinates before conversion (x, y) are actually non-continuous and the coordinates after conversion (X, Y) are continuous,
Inverse conversion formula: x = X / A
y = Y / B (Formula 1)
Is used to obtain the coordinates before conversion.

この逆変換の整数部は変換前座標として元画像の画素値を引き出すために使われる。また小数部(余り)は係数作成に用いる。   The integer part of this inverse transformation is used to extract the pixel value of the original image as the pre-conversion coordinates. The decimal part (remainder) is used for coefficient creation.

(X,Y)各画素につき、元画像座標(x,y)から16個の元画像画素値Gを取得する。
y−1行 G11213141
y 行 G12223242
y+1行 G13233343
y+2行 G14243444
x−1列 x列 x+1列 x+2列
For each pixel (X, Y), 16 original image pixel values G are acquired from the original image coordinates (x, y).
y-1 line G 11 G 21 G 31 G 41
y lines G 12 G 22 G 32 G 42
y + 1 line G 13 G 23 G 33 G 43
y + 2 line G 14 G 24 G 34 G 44
x-1 column x column x + 1 column x + 2 column

また、逆変換により求まった値の小数部をx−[x]、y−[y]と表すと、係数f(t)は以下の計算により求まる。
Further, when the decimal part of the value obtained by the inverse transformation is expressed as x- [x], y- [y], the coefficient f (t) is obtained by the following calculation.

これら元画像の16個の画素値とx,y8個の係数から以下の計算により変換後の画像の画素値Pが求まる。   From the 16 pixel values of these original images and the x, y8 coefficients, the pixel value P of the converted image is obtained by the following calculation.

P:出力画素値
G:原画像画素値
f(t):係数
(x,y):逆変換座標
しかし、畳み込み内挿法を用いると、線形補間法に比べて回路規模やメモリの使用量が大きくなってしまう。
特開2001−8037号公報
P: Output pixel value G: Original image pixel value f (t): Coefficient (x, y): Inverse transformation coordinates However, when the convolution interpolation method is used, the circuit scale and the amount of memory used are larger than those of the linear interpolation method. It gets bigger.
JP 2001-8037 A

しかし、前述の図11の手法では画像の性質にかかわらずに強調処理をかけてしまうので、自然画部で不自然な絵になりやすいという問題があった。   However, the above-described method shown in FIG. 11 has a problem in that an emphasis process is applied regardless of the nature of the image, so that an unnatural picture tends to occur in the natural image portion.

また、特許文献1の手法では、線形補間法の欠点である画素の変化が急激であるか滑らかに変化している部分かの判断を、近傍4点で画像判断を行うことにより補っている。これによって、縦エッジ、横エッジ、また角度45度の斜めエッジ、の画像のボケを改善している。しかし、斜め45度以外の斜めエッジについては対応が不十分であり、縦エッジや横エッジと誤検知してしまう恐れがあった。   In the method of Patent Document 1, the determination of whether the pixel change, which is a drawback of the linear interpolation method, is abrupt or smoothly changing is made by performing image determination at four neighboring points. This improves the blurring of the image of the vertical edge, the horizontal edge, and the oblique edge with an angle of 45 degrees. However, it is not enough to deal with oblique edges other than 45 degrees, and there is a risk of erroneous detection as a vertical edge or a horizontal edge.

また、畳み込み内挿法においても、画素変化が大きい場合には画像のボケが目立つ場合がある。図12は図10と同様に図12(a)の画像を、(b)最近傍法、(c)線形補間法、(d)畳み込み内挿法、でそれぞれ3倍に拡大した場合の補間画素のとり方を示した図である。図12(a)は座標0,1,2と座標3,4,5の画素値がそれぞれ同じ値をとっている場合の図である。図12(d)で参照座標1−2間と3−4間の補間画素についてはエッジを強調するような画素値のとり方をしている。しかし、参照座標2−3間の補間画素については滑らかな変化と判断してしまい、線形補間法と変わらない値となってしまっている。   Also in the convolutional interpolation method, when the pixel change is large, the blurring of the image may be noticeable. 12 is an interpolation pixel when the image of FIG. 12A is enlarged three times by (b) nearest neighbor method, (c) linear interpolation method, and (d) convolution interpolation method, respectively, as in FIG. It is the figure which showed how to take. FIG. 12A is a diagram in the case where the pixel values of the coordinates 0, 1, 2 and the coordinates 3, 4, 5 are the same. In FIG. 12D, pixel values that emphasize edges are taken for interpolated pixels between the reference coordinates 1-2 and 3-4. However, the interpolated pixel between the reference coordinates 2-3 is determined to be a smooth change, and has a value that is not different from the linear interpolation method.

以下に上記内容を数式によって説明する。   The above content will be described below using mathematical formulas.

前述(式3)でY方向の倍率が1の時の係数(f(y1),f(y2),f(y3),f(y4))=(0,1,0,0)を代入し、展開すると次式になる。   Substituting the coefficients (f (y1), f (y2), f (y3), f (y4)) = (0, 1, 0, 0) when the magnification in the Y direction is 1 in the above (Equation 3). And expands to

P=G12×f(x1)+G22×f(x2)+G32×f(x3)+G42×f(x4)…(式4)
ここで、G12=G22,G32=G42であるとすると、
P=G22×(f(x1)+f(x2))+G32×(f(x3)+f(x4))…(式5)
さらに、参照座標の端数が0.3の時の係数を(f(x1),f(x2),f(x3),f(x4))=(−0.1,0.8,0.4,−0.1)とするとP=G22×0.7+G32×0.3となり、0.6の時の係数を(f(x1),f(x2),f(x3),f(x4))=(−0.1,0.5,0.7,−0.1)とするとP=G22×0.4+G32×0.6となる。これは、線形補間法を行った時の演算とほぼ同じになる。また、G12=G32,G22=G42の場合も同様の結果となる。
P = G12 * f (x1) + G22 * f (x2) + G32 * f (x3) + G42 * f (x4) (Formula 4)
Here, if G12 = G22 and G32 = G42,
P = G22 × (f (x1) + f (x2)) + G32 × (f (x3) + f (x4)) (Formula 5)
Further, the coefficients when the fraction of the reference coordinate is 0.3 are (f (x1), f (x2), f (x3), f (x4)) = (− 0.1, 0.8, 0.4). , −0.1), P = G22 × 0.7 + G32 × 0.3, and the coefficients when 0.6 are (f (x1), f (x2), f (x3), f (x4)) = (− 0.1, 0.5, 0.7, −0.1), P = G22 × 0.4 + G32 × 0.6. This is almost the same as the calculation when the linear interpolation method is performed. The same result is obtained when G12 = G32 and G22 = G42.

この、畳み込み内挿法における画像のボケを改善する手法として、当該画素ブロックが自然画か文字画像かを判断し、畳み込み演算の係数テーブルを切替えるという手法が考えられる。   As a technique for improving the blurring of the image in the convolution interpolation method, a technique of determining whether the pixel block is a natural image or a character image and switching the coefficient table for the convolution calculation can be considered.

しかし、この手法では複数の係数テーブルを持つか、係数演算をその都度行わねばならず、回路規模の増加を招く恐れがあった。また、上記例のG12=G22,G32=G42ような場合には、G12,G42の重み付けを変えてもG22,G32に掛け合わせる係数にまとめられてしまう。結局、係数テーブルを変えても畳み込み演算結果は変わらない値となってしまうケースが発生していた。   However, in this method, it is necessary to have a plurality of coefficient tables or to perform coefficient calculation each time, which may increase the circuit scale. In the case of G12 = G22 and G32 = G42 in the above example, even if the weights of G12 and G42 are changed, the coefficients multiplied by G22 and G32 are collected. Eventually, there was a case where the result of convolution calculation would not change even if the coefficient table was changed.

このように、従来の画像を拡大した時のボケの対策は不十分な部分があった。   As described above, there are insufficient measures for blurring when a conventional image is enlarged.

また、拡大における画像のボケとは別に、縮小時の画素消失という問題もある。図15は画素消失の例を説明した図である。   In addition to image blurring during enlargement, there is also a problem of pixel loss during reduction. FIG. 15 is a diagram illustrating an example of pixel disappearance.

図15(a)の上部は解像度変換前の画素の並びを表している。白丸および黒丸が画素を表し、画素の上の数字はアドレスを表している。また、下部は畳み込み内挿法および線形補間法において上部画素データ群を1/2に縮小した場合の画素の並びを表している。ここで、上部から下部に伸びている矢印はどの元画素を参照して変換後の画素を導き出しているか、を表している。   The upper part of FIG. 15A represents the arrangement of pixels before resolution conversion. White circles and black circles represent pixels, and the numbers above the pixels represent addresses. The lower part represents a pixel arrangement when the upper pixel data group is reduced to ½ in the convolution interpolation method and the linear interpolation method. Here, an arrow extending from the upper part to the lower part indicates which original pixel is referenced to derive the converted pixel.

畳み込み内挿法、線形補間法、共にまず逆演算によって参照画素を導出す。つまり、倍率1/2の場合、逆演算はx=X×2(x:変換前座標、X:変換後座標)となり、参照画素座標は偶数値のみとなる。   In both the convolutional interpolation method and the linear interpolation method, first, a reference pixel is derived by inverse operation. That is, when the magnification is 1/2, the inverse calculation is x = X × 2 (x: coordinates before conversion, X: coordinates after conversion), and the reference pixel coordinates are only even values.

ここで、前述のように畳み込み内挿法では、参照画素座標の前後4画素を参照することになる。しかし、逆演算で余りが発生しないことから、係数(f(x1),f(x2),f(x3),f(x4))は常に、(f(x1),f(x2),f(x3),f(x4))=(0,1,0,0)となり、前記(式4)に当てはめると、変換後の画素値Pは常に、P=G22となる。つまり、線形補間法と同じ値が導き出されることとなる。   Here, as described above, the convolutional interpolation method refers to the four pixels before and after the reference pixel coordinates. However, since no remainder is generated in the inverse operation, the coefficients (f (x1), f (x2), f (x3), f (x4)) are always (f (x1), f (x2), f ( x3), f (x4)) = (0, 1, 0, 0). When applied to the (Equation 4), the pixel value P after conversion is always P = G22. That is, the same value as that of the linear interpolation method is derived.

よって、元座標の奇数値画素の消失が発生する。図15(a)において、元座標5の画素値が変換後の画素に反映されていないことが示されている。   Therefore, the disappearance of the odd-numbered pixels of the original coordinates occurs. FIG. 15A shows that the pixel value of the original coordinate 5 is not reflected in the converted pixel.

このような画素消失を防ぐ手段として、図15(b)に示す平均操作法が用いられることが多い。平均操作法は一定範囲内の画素の平均値を用いる手法である。例えば図15(b)では元座標1と元座標2、といった隣り合った画素の値の平均値を求めることにより、1/2の解像度変換を行っている。   As a means for preventing such pixel disappearance, an average operation method shown in FIG. 15B is often used. The average operation method is a method using an average value of pixels within a certain range. For example, in FIG. 15B, 1/2 conversion of resolution is performed by obtaining an average value of adjacent pixel values such as the original coordinate 1 and the original coordinate 2.

平均操作法を用いると画素値の消失は無くなる。しかし、元画素の値が保存されず画像のボケが発生してしまう、という問題があった。   When the average operation method is used, the disappearance of the pixel value is eliminated. However, there is a problem that the original pixel value is not stored and the image is blurred.

本発明はこのような問題を解決し、拡大または縮小処理において高画質な画像を得ることの出来る画像処理装置を提供することを目的とする。   An object of the present invention is to solve such problems and to provide an image processing apparatus capable of obtaining a high-quality image in enlargement or reduction processing.

本発明においては、画像の拡大または縮小処理を実行する画像処理装置であって、画素データを入力する入力手段と、前記画素データの一部を一定の画素群にまとめて出力する出力手段と、前記画素群を時系列に並べ替える並べ替え手段と、前記画素群から画像のエッジを検出するエッジ検出器と、前記エッジ検出器からの情報を基に係数テーブルの引数を補正する補正回路と、前記補正回路から出力される引数から演算係数を決定する係数手段と、前記係数手段から出力される係数に基づいて前記並べ替え装置から出力される画素データを演算することにより補間画素データを求める演算手段とを備える。   In the present invention, an image processing apparatus that performs image enlargement or reduction processing, an input unit that inputs pixel data, an output unit that outputs a part of the pixel data in a certain pixel group, Rearrangement means for rearranging the pixel group in time series, an edge detector for detecting an edge of an image from the pixel group, a correction circuit for correcting an argument of a coefficient table based on information from the edge detector; Coefficient means for determining a calculation coefficient from an argument output from the correction circuit, and calculation for obtaining interpolated pixel data by calculating pixel data output from the rearrangement device based on a coefficient output from the coefficient means Means.

本発明によれば、拡大時における画像のボケの問題を解消し、良好な画質の拡大画像を得ることが可能となる。また、縮小時に発生する画素消失の問題に対しても効果がある。すなわち、画素消失を低減し、且つボケの少ない良好な画質の縮小画像を得ることが可能となる。   According to the present invention, it is possible to solve the problem of blurring of an image at the time of enlargement and obtain an enlarged image with good image quality. It is also effective for the problem of pixel loss that occurs during reduction. That is, it is possible to obtain a reduced image with good image quality with reduced pixel loss and less blur.

以下、本発明の実施形態を説明する。   Embodiments of the present invention will be described below.

まず、本実施形態における補間処理の考え方について説明する。   First, the concept of interpolation processing in this embodiment will be described.

3次畳み込み内挿法では変換倍率の逆変換を行い、その商から元画像の参照座標を割り出し、その余りから係数を割り出す。この場合、余りを引数としてルックアップテーブル(LUT)から係数を引き出す方式が一般的である。   In the cubic convolution interpolation, the conversion magnification is inversely converted, the reference coordinates of the original image are calculated from the quotient, and the coefficient is calculated from the remainder. In this case, a method of extracting a coefficient from a lookup table (LUT) using the remainder as an argument is common.

本案では3次畳み込み内挿法の演算に用いる画素データからエッジの検出を行い、その検出データに応じて引数の値を変化させる。図13は図12(d)の補間方法に本方式を適用した場合の画素値のとり方を示した図である。図13の斜線部が、補正が行われた範囲を表している。図12(d)では参照座標2−3間で引数0.3と0.6によって係数が決定され、その係数を用いて畳み込み演算を行った結果が補間画素値として採用されている。それに対し図13では、参照座標2−3間でエッジが検出された場合の画素値のとり方を示している。例えば、引数0.3は0.2に、引数0.6は0.7に、というように元画素の値により近づくように補正が行われる。この補正の度合いはエッジの大きさに比例する。つまり、図13の参照座標2と3の元画素値の差が大きいほど補正の度合いも大きくなる。ここで、エッジが検出されない場合はこのような補正は行われない。つまり、図13の参照座標1−2間や3−4間ではエッジ検出による補正は行われず、3次畳み込み内挿法による演算結果がそのまま採用される。   In this proposal, the edge is detected from the pixel data used for the calculation of the cubic convolution interpolation method, and the value of the argument is changed according to the detected data. FIG. 13 is a diagram showing how to take pixel values when the present method is applied to the interpolation method of FIG. A hatched portion in FIG. 13 represents a range in which correction is performed. In FIG. 12D, the coefficient is determined between the reference coordinates 2-3 by the arguments 0.3 and 0.6, and the result of performing the convolution operation using the coefficient is adopted as the interpolated pixel value. On the other hand, FIG. 13 shows how to take a pixel value when an edge is detected between the reference coordinates 2-3. For example, the correction is performed such that the argument 0.3 is set to 0.2, the argument 0.6 is set to 0.7, and the value of the original pixel is closer. The degree of correction is proportional to the size of the edge. That is, the greater the difference between the original pixel values of the reference coordinates 2 and 3 in FIG. Here, when no edge is detected, such correction is not performed. That is, the correction by edge detection is not performed between the reference coordinates 1-2 and 3-4 in FIG. 13, and the calculation result by the cubic convolution interpolation method is adopted as it is.

次に、エッジの検出手法について説明する。   Next, an edge detection method will be described.

エッジの検出については3次畳み込み内挿法に用いる4×4画素の画素データを使用する。4×4の画素の並びを判断して縦エッジ、横エッジを検出し、前述のエッジ部の補正を行う。斜めエッジについては3次畳み込み内挿法によるエッジの強調効果を利用する。   For edge detection, pixel data of 4 × 4 pixels used for the cubic convolution interpolation method is used. A vertical edge and a horizontal edge are detected by judging the arrangement of 4 × 4 pixels, and the edge portion is corrected as described above. For diagonal edges, the edge enhancement effect by the cubic convolution interpolation method is used.

図14は4×4の画素データをX方向に2倍し、4×8の画素データに変換した状態を表した図である。図14(a)は白地に黒の縦線、図14(b)は白地に黒の斜め線を表している。また、図14(a),(b)共、上の矢印は最近傍法による補間を表し、下の矢印は線形補間法または畳み込み内挿法による補間を表している。前述の説明のように畳み込み内挿法では強調効果が得られるため、線形補間法と畳み込み内挿法では厳密には同じにならないが、元画素にない中間調が発生するという意味でここでは同じものとして扱っている。   FIG. 14 is a diagram illustrating a state in which 4 × 4 pixel data is doubled in the X direction and converted into 4 × 8 pixel data. 14A shows a black vertical line on a white background, and FIG. 14B shows a black diagonal line on a white background. 14A and 14B, the upper arrow represents interpolation by the nearest neighbor method, and the lower arrow represents interpolation by linear interpolation or convolution interpolation. As described above, the convolutional interpolation method provides an emphasis effect, so the linear interpolation method and the convolutional interpolation method are not exactly the same, but the same here in the sense that a halftone that does not exist in the original pixel occurs. Treat it as a thing.

図14(a)の最近傍法では1画素で表された黒線が2倍拡大により2画素で表された黒線になっている。一方、線形補間法および畳み込み内挿法では1画素の黒線とそれを挟み込む1画素の中間調グレーの線で表現される。このような線の場合、前者のほうがはっきりと綺麗に表示され、後者はボケたかんじに表示される。   In the nearest neighbor method of FIG. 14A, the black line represented by one pixel is changed to a black line represented by two pixels by double enlargement. On the other hand, in the linear interpolation method and the convolutional interpolation method, a black line of one pixel and a halftone gray line of one pixel sandwiching it are expressed. In the case of such a line, the former is displayed more clearly and clearly, and the latter is displayed more clearly.

同様に図14(b)をみると、最近傍法ではギザギザ感が発生してしまうが、線形補間および畳み込み内挿法では、2値では表現できない部分を中間調で表現することにより、滑らかに表示することが可能となる。この時、線形補間法より畳み込み内挿法の方がエッジの効果を出すことができるのは前述のとおりである。   Similarly, when looking at FIG. 14B, the nearest neighbor method gives a jagged feeling, but the linear interpolation and the convolutional interpolation method can smoothly express a portion that cannot be expressed in binary by using halftones. It is possible to display. At this time, as described above, the convolutional interpolation method can produce the edge effect more than the linear interpolation method.

よって、斜めエッジでは3次畳み込み内挿法を用いて補間を行い、縦エッジもしくは横エッジではそのエッジの強度によって補正をかける。これらの操作により、より高品位な補間処理を行うことが可能となる。   Therefore, interpolation is performed using a cubic convolution interpolation method at an oblique edge, and correction is performed according to the intensity of the edge at a vertical edge or a horizontal edge. By these operations, higher-quality interpolation processing can be performed.

さらに、縮小時の画素消失の問題に対しても同様の手法で対応することが可能である。   Furthermore, it is possible to deal with the problem of pixel disappearance at the time of reduction by a similar method.

図16は各変換方法において1/2倍の変換を行った場合の画素値のとり方を表している。図16(a)は変換前の元画像、(b)は畳み込み内挿法および線形補間法による変換、(c)は平均操作法による変換、(d)は本発明による変換、を表している。(b),(c),(d)の横軸は元画像のどの座標の値を参照したのかがわかるように、横軸の参照画像は元座標を表している。また、各画素間を直線で結んでいるのは便宜上、画素の変化がわかりやすいようにしたものである。   FIG. 16 shows how to take pixel values when 1/2 conversion is performed in each conversion method. 16A shows an original image before conversion, FIG. 16B shows conversion by convolution interpolation method and linear interpolation method, FIG. 16C shows conversion by average operation method, and FIG. 16D shows conversion by the present invention. . The horizontal axis of (b), (c), and (d) represents the original coordinate so that it can be understood which coordinate value of the original image is referenced. Also, the reason for connecting the pixels with straight lines is to make it easy to understand the change of the pixels for the sake of convenience.

図16(b)の変換では、偶数座標のみが参照されるので座標5の値が反映されていない。   In the conversion of FIG. 16B, only the even coordinates are referred to, so the value of coordinate 5 is not reflected.

図16(c)の変換では、参照座標に対しそのひとつ前の座標の画素値との平均を求めている。例えば、参照座標2の時の値は(元座標1の値+元座標2の値)÷2で求められる。このため、座標の位置に関係なく中間値が出力されてしまう。   In the conversion of FIG. 16C, the average of the pixel value of the previous coordinate with respect to the reference coordinate is obtained. For example, the value at the reference coordinate 2 is obtained by (original coordinate 1 value + original coordinate 2 value) / 2. For this reason, an intermediate value is output regardless of the coordinate position.

これに対し、本発明による図16(d)の変換では、出力に対してすべての画素値の影響を残しつつ、座標の位置の影響も与えている。本手法は(b)の変換に加えて、画素値変化の大きい部分を検出し、画素値変化の大きい部分でその変化量に応じて補正をかける手法である。この時の補正のかけ方は拡大の時と異なる。すなわち、拡大の時は元画素に近づけるように補正をかけるが、縮小の時は通常参照されない画素に近づける方向、つまり中間値を発生させる方向に補正をかける。   On the other hand, in the conversion of FIG. 16D according to the present invention, the influence of the coordinate position is also given to the output while leaving the influence of all the pixel values. In this method, in addition to the conversion of (b), a portion where the pixel value change is large is detected, and the portion where the pixel value change is large is corrected according to the amount of change. The correction method at this time is different from that at the time of enlargement. That is, correction is performed so as to be close to the original pixel at the time of enlargement, but correction is performed in a direction close to a pixel that is not normally referred to at the time of reduction, that is, a direction in which an intermediate value is generated.

実際の変換の状態を図17に示す。   An actual conversion state is shown in FIG.

図17は各手法において、8×8の画素データ群を水平方向に1/2にした場合の画素値のとり方を表した図である。図17(a)は元画像であり、8×8の画素データで白地に黒の斜め線を表している。図17(b)は畳み込み内挿法および線形補間法による変換、図17(c)は平均操作法による変換、図17(d)は本案による変換、の画素値のとり方を表している。   FIG. 17 is a diagram illustrating how to obtain pixel values in the case where an 8 × 8 pixel data group is halved in the horizontal direction in each method. FIG. 17A shows an original image, which represents a diagonal black line on a white background with 8 × 8 pixel data. FIG. 17 (b) shows the conversion by the convolution interpolation method and the linear interpolation method, FIG. 17 (c) shows the conversion by the average operation method, and FIG.

図17(b)では前述の説明のように参照される座標が飛び飛びになるため、変換後のデータでは画素データの黒線も飛び飛びになってしまっている。また、図17(c)では画素データの黒線がすべてグレーになってしまっている。一方、図17(d)では黒線がすべてグレーになってしまっているが、画素位置による変化を濃淡により表している。   In FIG. 17B, since the coordinates referred to are skipped as described above, the black line of the pixel data is also skipped in the converted data. In FIG. 17C, the black lines of the pixel data are all gray. On the other hand, in FIG. 17D, all the black lines are gray, but the change due to the pixel position is represented by shading.

ただし、縮小の場合、縮小率によっては上記手法では表現できない場合が発生する。   However, in the case of reduction, there is a case where it cannot be expressed by the above method depending on the reduction ratio.

図18は縮小の場合の一例を表した図である。図18は各変換方法において1/2倍の変換を行った場合の画素値のとり方を表している。図18(a)は変換前の元画像であり1画素ごとに画素値が大きく変化している状態を表している。(b)は畳み込み内挿法および線形補間法による変換、(c)は平均操作法による変換、を表している。(b),(c)の横軸は元画像のどの座標の値を参照したのかがわかるように、横軸の参照画像は元座標を表している。   FIG. 18 is a diagram illustrating an example of reduction. FIG. 18 shows how to take pixel values when 1/2 conversion is performed in each conversion method. FIG. 18A is an original image before conversion, and shows a state in which the pixel value changes greatly for each pixel. (B) shows the conversion by the convolution interpolation method and the linear interpolation method, and (c) shows the conversion by the average operation method. The horizontal axis of (b) and (c) represents the original coordinate so that it can be understood which coordinate value of the original image is referenced.

図18に示すように、畳み込み内挿法および線形補間法での変換を行うと、(b)のような出力になってしまう。ここで図16の場合のように本案の手法を用いたとしても、画素値が補正されて少し大きくなるだけで見た目にあまり変わりがなくなってしまう。また、他の手法を用いて元画像にあるような1画素ごとに変化する画像を表現しようとしても1/2縮小では画素数が少ないので正確に表現することは不可能である。   As shown in FIG. 18, when conversion is performed by the convolution interpolation method and the linear interpolation method, an output as shown in (b) is obtained. Here, even if the method of the present invention is used as in the case of FIG. 16, the pixel value is corrected and becomes a little larger, so that it does not change much in appearance. Also, even if another method is used to express an image that changes for each pixel as in the original image, it cannot be expressed accurately because the number of pixels is small in 1/2 reduction.

そこで、このような場合には(c)のように平均操作法を用いて表現する。本発明ではこのような場合に係数の引数を変えるだけで平均操作法による変換を行うことも可能である。   In such a case, the average operation method is used as shown in (c). In the present invention, conversion by the average operation method can be performed only by changing the coefficient argument in such a case.

図19は本発明で使用する係数テーブルの一部を示した表である。この係数テーブルは引数「0」と「1.1」を除いて、引数「0.5」を中心に対称の関係にある。   FIG. 19 is a table showing a part of the coefficient table used in the present invention. This coefficient table is symmetrical with respect to the argument “0.5” except for the arguments “0” and “1.1”.

画素変化の大きさがユーザーの任意の値に設定された閾値を超えると、引数の補正が行われる。図19の表において拡大の場合は引数が「0.5」から離れる方向に補正され、縮小の場合は引数が「0.5」に近づく方向に補正される。この時の補正量は閾値を超えた量に比例する。また、表中の引数「1.1」は通常、逆演算では発生しない引数である。この引数は例外的な引数であり、上記の補正により適用されることもない。この引数は図18のような場合に選択され、固定係数が選ばれるようにする。この例では4つの画素の影響がほぼ均一にでるような係数を選択しているが、使用用途にあわせて係数のバランスを変えてもよい。また、このような特別なケースの引数を複数用意してそれに対応した固定係数を選択するようにしてもよい。   When the magnitude of the pixel change exceeds a threshold set to an arbitrary value of the user, the argument is corrected. In the table of FIG. 19, in the case of enlargement, the argument is corrected in a direction away from “0.5”, and in the case of reduction, the argument is corrected in a direction closer to “0.5”. The correction amount at this time is proportional to the amount exceeding the threshold. Also, the argument “1.1” in the table is an argument that does not normally occur in the inverse operation. This argument is an exceptional argument and is not applied by the above correction. This argument is selected in the case as shown in FIG. 18, and a fixed coefficient is selected. In this example, the coefficients are selected so that the influence of the four pixels is almost uniform. However, the balance of the coefficients may be changed according to the intended use. It is also possible to prepare a plurality of arguments for such a special case and select a fixed coefficient corresponding thereto.

[第1の実施例]
図1は本発明の解像度変換装置の全体構成を説明した図である。
[First embodiment]
FIG. 1 is a diagram illustrating the overall configuration of a resolution conversion apparatus according to the present invention.

101は入力範囲設定装置、102はラインバッファ制御装置、103はエッジ検出器、104は演算装置、105は出力制御装置、を表している。   Reference numeral 101 denotes an input range setting device, 102 denotes a line buffer control device, 103 denotes an edge detector, 104 denotes an arithmetic device, and 105 denotes an output control device.

また、S01は入力制御信号(IHSYNCは入力水平同期信号、IVSYNCは入力垂直同期信号、ISXは水平方向スタートアドレス、IEXは水平方向エンドアドレス、ISYは垂直方向スタートアドレス、IEYは垂直方向エンドアドレス)、S02は入力画像データ、S03は演算装置入力データ、S04はエッジ検出データ、S05は演算装置出力データ、S06は出力画像データ、S07は入力有効範囲を指定するIACT信号、S08は水平(X)/垂直(Y)の倍率設定データ、S09は演算装置からの所望データのアドレスを指定するアドレス指定信号(XQUOT,YQUOT)、S10は出力範囲指定信号(OSXは水平方向スタートアドレス、OEXは水平方向エンドアドレス、OSYは垂直方向スタートアドレス、OEYは垂直方向エンドアドレス)、S11は出力制御信号(OHSYNCは出力水平同期信号、OVSYNCは出力垂直同期信号、OACTは出力有効範囲指定信号)、を表している。   S01 is an input control signal (IHSYNC is an input horizontal sync signal, IVSYNC is an input vertical sync signal, ISX is a horizontal start address, IEX is a horizontal end address, ISY is a vertical start address, and IEY is a vertical end address). , S02 is input image data, S03 is arithmetic device input data, S04 is edge detection data, S05 is arithmetic device output data, S06 is output image data, S07 is an IACT signal designating an effective input range, and S08 is horizontal (X). / Vertical (Y) magnification setting data, S09 is an address designation signal (XQUOT, YQUOT) for designating an address of desired data from the arithmetic unit, S10 is an output range designation signal (OSX is a horizontal start address, OEX is a horizontal direction) End address, OSY is vertical start address , OEy the vertical end address), S11 is an output control signal (OHSYNC output horizontal sync signal, OVSYNC output vertical sync signal, OACT represents the output scope specification signal).

入力制御信号S01は入力範囲設定装置101に入力され、ユーザーの任意により画像の入力範囲を設定する。   The input control signal S01 is input to the input range setting device 101, and the input range of the image is set as desired by the user.

入力範囲設定装置101は入力された入力制御信号S01に基づき、入力画像の有効範囲でハイとなるIACT信号S07を生成する。   Based on the input control signal S01, the input range setting device 101 generates an IACT signal S07 that goes high in the effective range of the input image.

IACT信号S07と、入力画像データS02はラインバッファ制御装置102に入力される。ここで、図1中では入力画像データS02をYCbCrで表記してあるが、RGBもしくはYUVとしても、本発明においては影響のないものとする。   The IACT signal S07 and the input image data S02 are input to the line buffer controller 102. Here, in FIG. 1, the input image data S02 is represented by YCbCr, but RGB or YUV is not affected in the present invention.

ラインバッファ制御装置102は複数のラインバッファを持ち、複数ラインの入力画像データS02を保持する。ラインバッファ制御装置102は演算装置104によって生成されるアドレス指定信号(XQUOT,YQUOT)S09の指示に従い、指定されたアドレス(X,Y)に対し、(Xn−1,Yn−1)、(Xn−1,Y)、(Xn−1,Yn+1)、(Xn−1,Yn+2)、(X,Yn−1)、(X,Y)、(X,Yn+1)、(X,Yn+2)、(Xn+1,Yn−1)、(Xn+1,Y)、(Xn+1,Yn+1)、(Xn+1,Yn+2)、(Xn+2,Yn−1)、(Xn+2,Y)、(Xn+2,Yn+1)、(Xn+2,Yn+2)、のアドレスの計16画素分のデータを演算装置入力データS03として送出する。 The line buffer control device 102 has a plurality of line buffers and holds a plurality of lines of input image data S02. The line buffer control device 102 performs (X n−1 , Y n−1 ) for the specified address (X n , Y n ) in accordance with the instruction of the address specification signal (XQUOT, YQUOT) S09 generated by the arithmetic unit 104. ), (X n-1, Y n), (X n-1, Y n + 1), (X n-1, Y n + 2), (X n, Y n-1), (X n, Y n), (X n, Y n + 1 ), (X n, Y n + 2), (X n + 1, Y n-1), (X n + 1, Y n), (X n + 1, Y n + 1), (X n + 1, Y n + 2), (X n + 2, Y n -1), (X n + 2, Y n), (X n + 2, Y n + 1), as (X n + 2, Y n + 2), the arithmetic unit input data S03 a total of 16 pixels of data in the address Send it out.

エッジ検出器103は演算装置入力データS03からエッジ情報を抽出し、エッジ検出データS04を演算装置104に送る。   The edge detector 103 extracts edge information from the arithmetic device input data S03 and sends the edge detection data S04 to the arithmetic device 104.

演算装置104はエッジ検出器103からのエッジ検出データS04と、ラインバッファ制御装置102からの演算装置入力データS03と、水平および垂直の倍率設定データS08から解像度変換における補間データ演算を行う。演算されたデータは演算装置出力データS05として出力制御装置105に送出される。また、前述のアドレス指定信号(XQUOT,YQUOT)S09を生成し、ラインバッファ制御装置102に送出する。   The arithmetic unit 104 performs interpolation data calculation in resolution conversion from the edge detection data S04 from the edge detector 103, the arithmetic unit input data S03 from the line buffer control unit 102, and the horizontal and vertical magnification setting data S08. The computed data is sent to the output control device 105 as computing device output data S05. Further, the address designation signal (XQUOT, YQUOT) S09 is generated and sent to the line buffer controller 102.

出力制御装置105では、出力範囲指定信号(OSX,OEX,OSY,OEY)S10に従い、出力有効範囲内に画像データが生成されるよう、タイミング調整を行う。タイミング調整された画像データは出力画像データS06として出力される。また、演算に要した時間を調整し、入出力タイミングがあうように出力制御信号(OVSYNC,OHSYNC,OACT)S11も生成し、出力する。   The output control device 105 performs timing adjustment so that image data is generated within the effective output range in accordance with the output range designation signal (OSX, OEX, OSY, OEY) S10. The timing-adjusted image data is output as output image data S06. In addition, the time required for the calculation is adjusted, and an output control signal (OVSYNC, OHSYNC, OACT) S11 is also generated and output so that the input / output timing matches.

図2はラインバッファ制御装置102の内部構成例を説明した図である。   FIG. 2 is a diagram illustrating an internal configuration example of the line buffer control device 102.

201はラインバッファ制御装置102の入出力ラインデータを制御するライン制御装置、202は各ラインのX方向のアドレスを制御するアドレス制御装置、203はラインバッファへの書き込み/読み出しを制御するイネーブル信号制御装置、204は5本のラインバッファ(LINE_BUF1,LINE_BUF2,LINE_BUF3,LINE_BUF4,LINE_BUF5)を内包するラインバッファブロック、205はデータの並べ替えを行う並べ替え装置、を表している。   201 is a line controller that controls input / output line data of the line buffer controller 102, 202 is an address controller that controls the address of each line in the X direction, and 203 is an enable signal control that controls writing / reading to the line buffer. Reference numeral 204 denotes a line buffer block including five line buffers (LINE_BUF1, LINE_BUF2, LINE_BUF3, LINE_BUF4, and LINE_BUF5), and 205 denotes a rearrangement device for rearranging data.

ライン制御装置201は不図示の入力制御信号(IVSYNC,IHSYNC)S01およびIACT信号S07をもとに有効入力ラインをカウントする。さらにYQUOT信号で要求されるY方向の指定アドレスとの比較を行い、条件が合致した場合はラインイネーブル信号をイネーブル信号制御装置203に送出する。   The line control device 201 counts effective input lines based on unillustrated input control signals (IVSYNC, IHSYNC) S01 and IACT signal S07. Further, a comparison is made with the designated address in the Y direction required by the YQUOT signal, and if the condition is met, a line enable signal is sent to the enable signal control device 203.

アドレス制御装置202は不図示の入力制御信号(IVSYNC,IHSYNC)S01およびIACT信号S07をもとにX方向の有効ビット数をカウントする。さらにXQUOT信号で要求されるX方向の指定アドレスとの比較を行い、条件が合致した場合はビットイネーブル信号をイネーブル信号制御装置203に送出する。   The address control device 202 counts the number of effective bits in the X direction based on an input control signal (IVSYNC, IHSYNC) S01 (not shown) and the IACT signal S07. Further, comparison is made with a designated address in the X direction required by the XQUOT signal, and if the condition is met, a bit enable signal is sent to the enable signal controller 203.

イネーブル信号制御装置203は、ライン制御装置201から送られてくるラインイネーブル信号と、アドレス制御装置202から送られてくるビットイネーブル信号と、を調停し、ラインバッファブロック204に含まれる5つのラインバッファのうちどのラインバッファに書き込むかを指示するライトイネーブル信号と、どのラインバッファから読み出しを行うかを指示するリードイネーブル信号を送出する。   The enable signal control device 203 arbitrates the line enable signal sent from the line control device 201 and the bit enable signal sent from the address control device 202, and includes five line buffers included in the line buffer block 204. A write enable signal for instructing which line buffer to write to and a read enable signal for instructing from which line buffer to read out are transmitted.

ラインバッファブロック204は5つのラインバッファを内包し、イネーブル信号制御装置203の指示に従い、画像データの書き込み/読み出しを行う。例えば、ライトイネーブル信号,リードイネーブル信号をそれぞれ5ビットのバイナリーで表すとすると、00001bの時にはLINE_BUF1が選択され、00010bの時にはLINE_BUF2、00100bではLINE_BUF3、01000bではLINE_BUF4、10000bではLINE_BUF5、がそれぞれ選択されるものとする。ライトイネーブル信号はIHSYNCごとに00001b→00010b→00100b→01000b→10000b→00001b→…と変化し、1ラインごとの入力画像データがそれぞれのラインバッファに格納される。それに対しリードイネーブル信号はIHSYNCごとに11110b→11101b→11011b→10111b→01111b→11110b→…と変化し、書き込みが行われていない4ラインから指定されたX方向のアドレスのデータが同時に読み出されるようになっている。   The line buffer block 204 includes five line buffers, and writes / reads image data in accordance with instructions from the enable signal control device 203. For example, if the write enable signal and the read enable signal are expressed in binary form of 5 bits, LINE_BUF1 is selected for 00001b, LINE_BUF2 for 00001b, LINE_BUF3 for 0100b, LINE_BUF4 for 01000b, and LINE_BUF5 for 10000b. Shall. The write enable signal changes for each IHSYNC in the order of 00001b → 00010b → 00100b → 01000b → 10000b → 00001b →..., And input image data for each line is stored in each line buffer. On the other hand, the read enable signal changes from 11110b → 11101b → 11011b → 10111b → 01111b → 11110b →... So that the data in the address in the specified X direction is simultaneously read from the four lines where writing is not performed. It has become.

並び替え装置205はラインバッファブロック204から送られてくる画像データをラインごとに古いデータの順に並べ替える。また、X方向のデータを常に4画素分保持し、クロック毎に4×4=16画素分の画像データをまとめて送出する。   The rearrangement device 205 rearranges the image data sent from the line buffer block 204 in order of old data for each line. In addition, data in the X direction is always held for four pixels, and image data for 4 × 4 = 16 pixels is collectively transmitted for each clock.

図3は演算装置104の内部構成の一例を示した図である。   FIG. 3 is a diagram illustrating an example of the internal configuration of the arithmetic device 104.

301は逆演算回路、302は補正回路、303は係数テーブル、304はタイミング調整回路、305は第1のY方向畳み込み回路、306は第2のY方向畳み込み回路、307は第3のY方向畳み込み回路、308は第4のY方向畳み込み回路、309はX方向畳み込み回路、を表している。   301 is a reverse operation circuit, 302 is a correction circuit, 303 is a coefficient table, 304 is a timing adjustment circuit, 305 is a first Y direction convolution circuit, 306 is a second Y direction convolution circuit, and 307 is a third Y direction convolution. The circuit, 308 represents a fourth Y-direction convolution circuit, and 309 represents an X-direction convolution circuit.

逆演算回路301にはX方向およびY方向の倍率設定データS08が入力され、解像度変換倍率の逆演算が行われる。これにより、その逆演算の商がアドレス指定信号(XQUOT,YQUOT)S09として、ラインバッファ制御装置102に送出される。また、逆演算の余りは係数の引数(XREMD,YREMD)として係数テーブル303に送出される。   The inverse calculation circuit 301 receives the X-direction and Y-direction magnification setting data S08 and performs reverse calculation of the resolution conversion magnification. As a result, the quotient of the inverse operation is sent to the line buffer controller 102 as an address designation signal (XQUOT, YQUOT) S09. The remainder of the inverse operation is sent to the coefficient table 303 as a coefficient argument (XREMD, YREMD).

補正回路302にはエッジ検出器103により生成されるエッジ検出データS04が入力される。補正回路302はエッジの強弱により補正データを生成し逆演算回路301に送出する。逆演算回路301は補正データに従い、係数の引数(XREMD,YREMD)を変化させる。   The correction circuit 302 receives edge detection data S04 generated by the edge detector 103. The correction circuit 302 generates correction data based on the strength of the edge and sends it to the inverse operation circuit 301. The inverse operation circuit 301 changes coefficient arguments (XREMD, YREMD) according to the correction data.

係数テーブル303は逆演算回路301から送出される係数の引数(XREMD,YREMD)から、その値に対応する係数データを送出する。   The coefficient table 303 sends coefficient data corresponding to the value from the argument (XREMD, YREMD) of the coefficient sent from the inverse operation circuit 301.

タイミング調整回路304はX方向の係数に対し、演算タイミングの調整を行う。   The timing adjustment circuit 304 adjusts the calculation timing for the coefficient in the X direction.

第1のY方向畳み込み回路305は係数テーブル303から送られてくるY係数を用いて、(XQUOT,YQUOT)=(X,Y)に対し、(Xn−1,Yn−1)、(Xn−1,Y)、(Xn−1,Yn+1)、(Xn−1,Yn+2)、の4画素分のデータをY方向の畳み込み演算を行う。 The first Y-direction convolution circuit 305 by using the Y coefficients sent from the coefficient table 303, (XQUOT, YQUOT) = (X n, Y n) to, (X n-1, Y n-1) , (X n−1 , Y n ), (X n−1 , Y n + 1 ), and (X n−1 , Y n + 2 ) are subjected to a convolution operation in the Y direction.

同様に、第2のY方向畳み込み回路306は、(X,Yn−1)、(X,Y)、(X,Yn+1)、(X,Yn+2)、の4画素を、第3のY方向畳み込み回路307は、(Xn+1,Yn−1)、(Xn+1,Y)、(Xn+1,Yn+1)、(Xn+1,Yn+2)、の4画素を、第4のY方向畳み込み回路308は、(Xn+2,Yn−1)、(Xn+2,Y)、(Xn+2,Yn+1)、(Xn+2,Yn+2)の4画素を、それぞれY方向の畳み込み演算を行う。 Similarly, the second Y-direction convolution circuit 306 includes (X n , Y n−1 ), (X n , Y n ), (X n , Y n + 1 ), and (X n , Y n + 2 ) four pixels. The third Y-direction convolution circuit 307 includes four pixels (X n + 1 , Y n−1 ), (X n + 1 , Y n ), (X n + 1 , Y n + 1 ), and (X n + 1 , Y n + 2 ). , fourth Y-direction convolution circuit 308, the four pixels (X n + 2, Y n -1), (X n + 2, Y n), (X n + 2, Y n + 1), (X n + 2, Y n + 2), respectively Perform a convolution operation in the Y direction.

X方向畳み込み回路309は第1〜第4のY方向畳み込み回路(305〜308)の出力データを、タイミング調整回路304によりタイミング調整が行われたX係数を用いてX方向の畳み込み演算を行う。X方向畳み込み回路309の出力は演算装置出力データS05として出力される。   The X direction convolution circuit 309 performs a convolution operation in the X direction on the output data of the first to fourth Y direction convolution circuits (305 to 308) using the X coefficient whose timing is adjusted by the timing adjustment circuit 304. The output of the X direction convolution circuit 309 is output as the arithmetic unit output data S05.

図4は出力制御装置の内部構成の一例を示した図である。   FIG. 4 is a diagram showing an example of the internal configuration of the output control apparatus.

401はVSYNC調整回路、402はHSYNC調整回路、403は出力ACT生成回路、404は出力制御回路、405はラインバッファブロック、406は切替え回路、を表している。   Reference numeral 401 denotes a VSYNC adjustment circuit, 402 denotes an HSYNC adjustment circuit, 403 denotes an output ACT generation circuit, 404 denotes an output control circuit, 405 denotes a line buffer block, and 406 denotes a switching circuit.

VSYNC調整回路401は出力の垂直同期信号(OVSYNC)のタイミング調整を行う。本回路構成で、複数のラインをラインバッファに保持し演算を行うため、入出力のデータ間で演算遅延が発生する。VSYNC調整回路401ではこの演算遅延の調整を行う。   The VSYNC adjustment circuit 401 adjusts the timing of the output vertical synchronization signal (OVSYNC). In this circuit configuration, since a plurality of lines are held in a line buffer and an operation is performed, an operation delay occurs between input and output data. The VSYNC adjustment circuit 401 adjusts the calculation delay.

図5は演算遅延の調整状況を説明した図である。   FIG. 5 is a diagram for explaining the adjustment state of the operation delay.

入力の垂直同期信号(IVSYNC)に同期して入力データが入力されている。ここで入力データのブランキング期間をISYとする。   Input data is input in synchronization with the input vertical synchronization signal (IVSYNC). Here, the blanking period of the input data is ISY.

次に、出力データが出力可能となるのは入力データから演算遅延分だけ遅れた時間となる。ここで出力データのブランキング期間をOSYとすると、OVSYNCはIVSYNCと比べて周期は同じでV_delay分だけ遅れた信号となる。この時、V_delayは「V_delay=演算遅延+ISY−OSY」で表すことができる。   Next, the output data can be output at a time delayed from the input data by an operation delay. Assuming that the blanking period of the output data is OSY, OVSYNC is a signal having the same period and delayed by V_delay compared to IVSYNC. At this time, V_delay can be expressed as “V_delay = operation delay + ISY−OSY”.

HSYNC調整回路402は出力の水平同期信号(OHSYNC)の調整を行う。   The HSYNC adjustment circuit 402 adjusts an output horizontal synchronization signal (OHSYNC).

図6はY方向に1/2の縮小を行ったときの出力タイミング例を示した図である。   FIG. 6 is a diagram showing an example of output timing when 1/2 reduction is performed in the Y direction.

Y方向の1/2操作では入力2ラインで1ライン分の出力データを得ることになる。しかし、入力の水平同期信号(IHSYNC)をそのまま出力に使っていたのでは画像データのないラインが発生してしまう。この対処方法としては2つの方法が考えられる。ひとつはHSYNC調整回路402において出力の水平同期信号(OHSYNC)の周期を変化させる方法。もうひとつは、有効データ部にハイとなる出力ACT信号(OACT)を同時に出力し、解像度変換後の画像データの受け手側で画像データの有無を判断して処理する方法である。図6のOHSYNCは前者の方法をとった場合の出力例を表している。   In 1/2 operation in the Y direction, output data for one line is obtained with two input lines. However, if the input horizontal synchronization signal (IHSYNC) is used as it is for output, a line without image data is generated. There are two possible methods for dealing with this. One is a method of changing the cycle of the output horizontal synchronization signal (OHSYNC) in the HSYNC adjustment circuit 402. The other is a method in which an output ACT signal (OACT) that goes high is simultaneously output to the effective data portion, and the receiver of the image data after resolution conversion determines the presence or absence of the image data and performs processing. OHSYNC in FIG. 6 represents an output example when the former method is adopted.

出力ACT生成回路403は図6に示すOACT信号を発生する回路である。出力ACT生成回路403は前述のOVSYNCとOHSYNCと出力範囲指定信号S10からOACT信号を生成する。   The output ACT generation circuit 403 is a circuit that generates the OACT signal shown in FIG. The output ACT generation circuit 403 generates an OACT signal from the above-described OVSYNC, OHSYNC, and output range designation signal S10.

出力制御回路404はOACT信号からラインバッファのリード/ライト信号を生成する。   The output control circuit 404 generates a line buffer read / write signal from the OACT signal.

ラインバッファブロック405は2本のラインバッファ(LINE_BUF1,LINE_BUF2)を備え、それぞれ交互に画像データの読み書きが行われる。例えば、演算装置出力データS05がLINE_BUF1に書き込まれている時は、LINE_BUF2から読み出しが行われる。ラインバッファのリード/ライトはOHSYNC毎に切替えられ、次のOHSYNCではLINE_BUF2に書き込みが行なわれ、LINE_BUF2からはひとつ前のOHSYNCの時に書き込まれた画像データが読み出されることになる。   The line buffer block 405 includes two line buffers (LINE_BUF1, LINE_BUF2), and image data is read and written alternately. For example, when the arithmetic device output data S05 is written in LINE_BUF1, reading is performed from LINE_BUF2. The line buffer read / write is switched for each OHSYNC, and the next OHSYNC is written to LINE_BUF2, and the image data written at the previous OHSYNC is read from LINE_BUF2.

切替え回路406はどちらのラインバッファからデータが読み出されているかを判断し、読み出されている方のデータを出力画像データS06として出力する。   The switching circuit 406 determines from which line buffer the data is read, and outputs the read data as output image data S06.

次に、エッジ検出器103の動作について説明する。   Next, the operation of the edge detector 103 will be described.

エッジ検出器103では畳み込み内挿法の演算に用いる4×4画素のデータから補間画素のエッジ成分を判断する。   The edge detector 103 determines the edge component of the interpolation pixel from the 4 × 4 pixel data used for the calculation of the convolutional interpolation method.

図7は3次畳み込み演算に用いる参照画素を表した図である。(1),(2),(3),(4)はX方向の画素の並びを表し、I,II,III,IVはY方向の画素の並びを表している。これらの画素をそれぞれ、I(1),I(2),…,IV(4)と表し、X方向の係数を(AX,BX,CX,DX)、Y方向の係数を(AY,BY,CY,DY)と表すと、3次畳み込み演算による出力画素値Pは以下の式で表される。   FIG. 7 is a diagram showing reference pixels used for the cubic convolution operation. (1), (2), (3), and (4) represent the arrangement of pixels in the X direction, and I, II, III, and IV represent the arrangement of pixels in the Y direction. These pixels are represented as I (1), I (2),..., IV (4), the coefficients in the X direction are (AX, BX, CX, DX), and the coefficients in the Y direction are (AY, BY, When expressed as (CY, DY), the output pixel value P obtained by the cubic convolution operation is expressed by the following equation.

P=(I(1)×AY+II(1)×BY+III(1)×CY+IV(1)×DY)×AX
+(I(2)×AY+II(2)×BY+III(2)×CY+IV(2)×DY)×BX
+(I(3)×AY+II(3)×BY+III(3)×CY+IV(3)×DY)×CX
+(I(4)×AY+II(4)×BY+III(4)×CY+IV(4)×DY)×DX…(式6)
ここで、X方向の係数(AX,BX,CX,DX)、Y方向の係数(AY,BY,CY,DY)はそれぞれ引数XREMD,YREMDによってLUTより引き出される。
P = (I (1) × AY + II (1) × BY + III (1) × CY + IV (1) × DY) × AX
+ (I (2) × AY + II (2) × BY + III (2) × CY + IV (2) × DY) × BX
+ (I (3) × AY + II (3) × BY + III (3) × CY + IV (3) × DY) × CX
+ (I (4) × AY + II (4) × BY + III (4) × CY + IV (4) × DY) × DX (formula 6)
Here, the X-direction coefficients (AX, BX, CX, DX) and the Y-direction coefficients (AY, BY, CY, DY) are extracted from the LUT by arguments XREMD and YREMD, respectively.

エッジ検出器103では、例えば以下の条件を検出した場合に検出信号を発生する。   For example, the edge detector 103 generates a detection signal when the following conditions are detected.

・縦エッジ条件
|II(2)−II(3)|>TX and II(2)=III(2) and II(3)=III(3)
・横エッジ条件
|II(2)−III(2)|>TY and II(2)=II(3) and III(2)=III(3)
ここで、TX,TYはユーザーの任意により設定可能な閾値であるとする。また、判定条件を以下のようにすることにより、エッジの精度を高めることも可能である。
Vertical edge condition | II (2) -II (3) |> TX and II (2) = III (2) and II (3) = III (3)
-Lateral edge condition | II (2) -III (2) |> TY and II (2) = II (3) and III (2) = III (3)
Here, TX and TY are thresholds that can be set arbitrarily by the user. In addition, the accuracy of the edge can be increased by setting the determination conditions as follows.

・縦エッジ条件
|II(2)−II(3)|>TX
and I(2)=II(2)=III(2)=IV(2) and I(3)=II(3)=III(3)=IV(3)
・横エッジ条件
|II(2)−III(2)|>TY
and II(1)=II(2)=II(3)=II(4) and III(1)=III(2)=III(3)=III(4)
こうして検知されたエッジの有無と|II(2)−II(3)|もしくは|II(2)−III(2)|で表されるエッジの強度によって、前述図3の補正回路302により引数XREMD,YREMDの補正がかけられる。
・ Vertical edge condition | II (2) -II (3) |> TX
and I (2) = II (2) = III (2) = IV (2) and I (3) = II (3) = III (3) = IV (3)
・ Horizontal edge condition | II (2) -III (2) |> TY
and II (1) = II (2) = II (3) = II (4) and III (1) = III (2) = III (3) = III (4)
The correction circuit 302 in FIG. 3 described above determines the argument XREMD according to the presence / absence of the detected edge and the intensity of the edge represented by | II (2) -II (3) | or | II (2) -III (2) | , YREMD correction is applied.

[第2の実施例]
図8は本案における第2の実施例の構成を示した図である。第2の実施例は第1の実施例の構成を変形したものである。以下に説明するように、Y方向の畳み込み演算回路をまとめることによって、回路規模を短縮することが可能である。
[Second Embodiment]
FIG. 8 is a diagram showing the configuration of the second embodiment of the present plan. The second embodiment is a modification of the configuration of the first embodiment. As described below, it is possible to reduce the circuit scale by combining the convolution operation circuits in the Y direction.

801は入力範囲設定装置、802は演算制御装置、803は出力制御装置、を表している。また、信号線として、S81は入力制御信号(IHSYNCは入力水平同期信号、IVSYNCは入力垂直同期信号、ISXは水平方向スタートアドレス、IEXは水平方向エンドアドレス、ISYは垂直方向スタートアドレス、IEYは垂直方向エンドアドレス)、S82は入力有効範囲を指定するIACT信号、S83は水平(X)/垂直(Y)の倍率設定データ、S84は入力画像データ、S85は演算装置出力データ、S86は出力範囲指定信号(OSXは水平方向スタートアドレス、OEXは水平方向エンドアドレス、OSYは垂直方向スタートアドレス、OEYは垂直方向エンドアドレス)、S87は出力画像データ、S88は出力制御信号(OHSYNCは出力水平同期信号、OVSYNCは出力垂直同期信号、OACTは出力有効範囲指定信号)、を表している。   Reference numeral 801 denotes an input range setting device, 802 denotes an arithmetic control device, and 803 denotes an output control device. As signal lines, S81 is an input control signal (IHSYNC is an input horizontal sync signal, IVSYNC is an input vertical sync signal, ISX is a horizontal start address, IEX is a horizontal end address, ISY is a vertical start address, and IEY is vertical. Direction end address), S82 is an IACT signal designating an input effective range, S83 is horizontal (X) / vertical (Y) magnification setting data, S84 is input image data, S85 is arithmetic device output data, and S86 is an output range designation. Signal (OSX is horizontal start address, OEX is horizontal end address, OSY is vertical start address, OEY is vertical end address), S87 is output image data, S88 is output control signal (OHSYNC is output horizontal sync signal, OVSYNC is the output vertical sync signal, OACT is the output Scope specification signal) represents.

入力制御信号S81は入力範囲設定装置801に入力され、ユーザーの任意により画像の入力範囲を設定する。   The input control signal S81 is input to the input range setting device 801, and the input range of the image is set as desired by the user.

入力範囲設定装置801は入力された入力制御信号S81に基づき、入力画像の有効範囲でハイとなるIACT信号S82を生成する。   The input range setting device 801 generates an IACT signal S82 that goes high in the effective range of the input image based on the input control signal S81.

IACT信号S82と、入力画像データS84と、倍率設定データS83、は演算制御装置802に入力される。   The IACT signal S82, the input image data S84, and the magnification setting data S83 are input to the arithmetic control device 802.

演算制御装置802は倍率設定データS83に基づく解像度変換演算を行う。これにより、入力信号S84は補間され、演算装置出力データS85として出力される。   The arithmetic control device 802 performs resolution conversion calculation based on the magnification setting data S83. As a result, the input signal S84 is interpolated and output as arithmetic device output data S85.

演算装置出力データS85は出力制御装置803に入力される。出力制御装置803では、出力範囲指定信号(OSX,OEX,OSY,OEY)S86に従い、出力有効範囲内に画像データが生成されるよう、タイミング調整を行う。タイミング調整された画像データは出力画像データS87として出力される。また、演算に要した時間を調整し、入出力タイミングがあうように出力制御信号(OVSYNC,OHSYNC,OACT)S88も生成し、出力する。   The arithmetic device output data S85 is input to the output control device 803. The output control device 803 performs timing adjustment so that image data is generated within the effective output range in accordance with the output range designation signal (OSX, OEX, OSY, OEY) S86. The timing-adjusted image data is output as output image data S87. In addition, the time required for the calculation is adjusted, and an output control signal (OVSYNC, OHSYNC, OACT) S88 is also generated and output so that the input / output timing matches.

図9は、図8の演算制御装置802の内部を説明したブロック図である。   FIG. 9 is a block diagram illustrating the inside of the arithmetic and control unit 802 in FIG.

901は逆演算回路、902はイネーブル信号発生装置、903はラインバッファブロック、904は並べ替え装置、905はY方向エッジ検出器、906はY方向係数テーブル、907はY方向畳み込み回路、908はレジスタブロック、909はX方向エッジ検出器、910はX方向係数テーブル、911はタイミング調整回路、912はX方向畳み込み回路、を表している。   901 is an inverse operation circuit, 902 is an enable signal generator, 903 is a line buffer block, 904 is a rearranger, 905 is a Y-direction edge detector, 906 is a Y-direction coefficient table, 907 is a Y-direction convolution circuit, and 908 is a register Block 909 represents an X direction edge detector, 910 represents an X direction coefficient table, 911 represents a timing adjustment circuit, and 912 represents an X direction convolution circuit.

逆演算回路901は、前述の倍率設定データと、不図示の内部カウンタのカウント値、から逆演算を行いアドレス指定信号(XQUOT,YQOT)と係数テーブル引数(XREMD,YREMD)を生成する。XQUOT,YQUOTはイネーブル信号発生装置902に、XREMDはX方向係数テーブル910に、YREMDはY方向係数テーブル906に、それぞれ送られる。   The inverse operation circuit 901 performs an inverse operation from the magnification setting data described above and the count value of an internal counter (not shown) to generate an address designation signal (XQUOT, YQOT) and a coefficient table argument (XREMD, YREMD). XQUOT and YQUOT are sent to the enable signal generator 902, XREMD is sent to the X direction coefficient table 910, and YREMD is sent to the Y direction coefficient table 906, respectively.

イネーブル信号発生装置902は、アドレス制御装置、ライン制御装置、イネーブル信号制御装置、から構成される。XQUOTはアドレス制御装置に入力され、アドレスイネーブル信号を生成する。また、YQUOTはライン制御装置に入力され、ラインイネーブル信号を生成する。アドレスイネーブル信号とラインイネーブル信号はイネーブル信号制御装置に入力されて、ライトイネーブル信号/リードイネーブル信号を出力する。   The enable signal generation device 902 includes an address control device, a line control device, and an enable signal control device. XQUOT is input to the address controller and generates an address enable signal. YQUOT is input to the line control device to generate a line enable signal. The address enable signal and the line enable signal are input to the enable signal control device to output a write enable signal / read enable signal.

ライトイネーブル信号/リードイネーブル信号はラインバッファブロック903に入力される。ラインバッファブロック903は5つのラインバッファによって構成されていて、ライトイネーブル信号はどのラインバッファに画像データを書き込むかを制御し、リードイネーブル信号はどのラインバッファから画像データを読み出すかを制御する。このようにして、入力画像データは一旦ラインバッファブロック903に書き込まれた後、リードイネーブル信号の読み出しタイミングに従って適宜必要なデータが読み出される。   The write enable signal / read enable signal is input to the line buffer block 903. The line buffer block 903 includes five line buffers. The write enable signal controls which line buffer the image data is written to, and the read enable signal controls from which line buffer the image data is read. In this way, after the input image data is once written in the line buffer block 903, necessary data is read as appropriate according to the read timing of the read enable signal.

ラインバッファブロック903から読み出された画像データは、並べ替え回路904に入力される。並べ替え回路904ではラインバッファブロック903から同時に読み出される複数のデータを時系列順に並べ替えて出力する。   Image data read from the line buffer block 903 is input to the rearrangement circuit 904. The rearrangement circuit 904 rearranges and outputs a plurality of data simultaneously read from the line buffer block 903 in time series.

並べ替え回路904から出力されたデータは、Y方向エッジ検出器905と、Y方向畳み込み回路907に入力される。   The data output from the rearrangement circuit 904 is input to the Y direction edge detector 905 and the Y direction convolution circuit 907.

Y方向エッジ検出器905は入力された4画素分のデータからエッジの有る無し、エッジの強度を検出する。エッジの検出方法は、例えば以下の方法により検出を行う。時系列順の2番目と3番目のデータの差を比較し、ユーザーの任意により設定される第1の閾値より大きいか小さいかを判断する。さらに、1番目と2番目のデータの差、2番目と4番目のデータの差、を検出し、ユーザーの任意により設定される第2の閾値との比較を行う。こうして生成された第1の閾値との差、第2の閾値との差、の情報をY方向係数テーブル906に送出する。   The Y-direction edge detector 905 detects the presence or absence of an edge and the intensity of the edge from the input data for four pixels. As an edge detection method, for example, detection is performed by the following method. The difference between the second and third data in time series order is compared, and it is determined whether the difference is larger or smaller than the first threshold set by the user. Further, the difference between the first and second data is detected, and the difference between the second and fourth data is detected and compared with a second threshold value set arbitrarily by the user. Information on the difference between the first threshold value and the second threshold value generated in this way is sent to the Y-direction coefficient table 906.

Y方向係数テーブル906は逆演算回路901から送られてくるYREMDに基づきY方向の係数を選択する。この時、Y方向エッジ検出器905から第1の閾値との差の情報があれば、その値に応じて係数の補正を行う。係数の補正は、拡大モードならばYREMDの値を「0.5」から離れる方向に補正し、縮小モードならばYREMDの値を「0.5」に近づける方向に補正する。また、第2の閾値との差の情報があれば4点を平均化する固定係数が選択される。こうして決定された係数はY方向畳み込み回路907に送出される。   A Y-direction coefficient table 906 selects a Y-direction coefficient based on YREMD sent from the inverse operation circuit 901. At this time, if there is information on the difference from the first threshold value from the Y-direction edge detector 905, the coefficient is corrected according to the value. In the coefficient correction, the YREMD value is corrected in a direction away from “0.5” in the enlargement mode, and the YREMD value is corrected in a direction closer to “0.5” in the reduction mode. If there is information on the difference from the second threshold, a fixed coefficient for averaging four points is selected. The coefficient thus determined is sent to the Y-direction convolution circuit 907.

Y方向畳み込み回路907は画像データとY方向の係数を用いて畳み込み演算を行う。Y方向の畳み込みが行われた画像データはレジスタブロック908に送出される。   A Y-direction convolution circuit 907 performs a convolution operation using image data and a coefficient in the Y direction. The image data that has been convolved in the Y direction is sent to the register block 908.

レジスタブロック908は4つのレジスタから成っている。Y方向畳み込み回路907から送られてくる画像データは最初にREG1に入力される。次に新しいデータがREG1に入力されると、それまでREG1に保持されていたデータはREG2に入力される。以下、順送りにREG3,REG4への入力が行われる。この時のデータ送りのタイミングはX方向の畳み込み演算のタイミングによって制御される。また、各レジスタに保持された画像データは畳み込み演算のタイミングによって読み出される。   Register block 908 consists of four registers. The image data sent from the Y-direction convolution circuit 907 is first input to REG1. Next, when new data is input to REG1, the data held in REG1 until then is input to REG2. Thereafter, input to REG3 and REG4 is performed in order. The data sending timing at this time is controlled by the timing of the convolution calculation in the X direction. Further, the image data held in each register is read at the timing of the convolution operation.

読み出された画像データはX方向エッジ検出器909と、X方向畳み込み回路912に入力される。   The read image data is input to the X direction edge detector 909 and the X direction convolution circuit 912.

X方向エッジ検出器909は前述のY方向の時と同様に第1の閾値との差、第2の閾値との差、の情報をX方向係数テーブル910に送出する。   The X-direction edge detector 909 sends information on the difference from the first threshold and the difference from the second threshold to the X-direction coefficient table 910 as in the case of the Y direction.

X方向係数テーブル910は逆演算回路901から送られてくるXREMDに基づきX方向の係数を選択する。この時、Y方向の時と同様にX方向エッジ検出器909から第1の閾値との差と、第2の閾値との差、の情報から係数が選択される。こうして決定された係数はX方向畳み込み回路912に送出される。   The X direction coefficient table 910 selects a coefficient in the X direction based on XREMD sent from the inverse operation circuit 901. At this time, as in the Y direction, a coefficient is selected from the X direction edge detector 909 based on the difference between the first threshold value and the second threshold value. The coefficient thus determined is sent to the X-direction convolution circuit 912.

X方向畳み込み回路912は画像データとX方向の係数を用いて畳み込み演算を行う。こうして算出されたデータは演算装置出力データとして出力される。   The X direction convolution circuit 912 performs a convolution operation using the image data and the X direction coefficient. The data calculated in this way is output as arithmetic device output data.

[第3の実施例]
図20は線形補間法にて本手法を適用した場合の画素値のとり方を表した図である。
[Third embodiment]
FIG. 20 is a diagram showing how to take pixel values when this method is applied by the linear interpolation method.

図20に示すように線形補間法においても同様にエッジ部の効果を表すことが可能である。また線形補間の場合は3次畳み込み内挿法に比べて係数が簡単なため係数テーブルを用いずに演算によって係数を算出することも可能である。その場合は演算の元となる倍率の逆数に補正をかけることとなる。   As shown in FIG. 20, the effect of the edge portion can be similarly expressed in the linear interpolation method. In the case of linear interpolation, since the coefficients are simpler than those of the cubic convolution interpolation method, it is possible to calculate the coefficients by calculation without using the coefficient table. In that case, the reciprocal of the magnification that is the basis of the calculation is corrected.

本発明第1の実施例における全体構成の一例のブロック図The block diagram of an example of the whole structure in 1st Example of this invention ラインバッファ制御装置の内部ブロック図Internal block diagram of line buffer controller 演算装置の内部ブロック図Internal block diagram of computing device 出力制御装置の内部ブロック図Output control device internal block diagram 演算遅延の調整状況を説明した図Diagram explaining the calculation delay adjustment status Y方向に1/2縮小を行ったときの出力タイミングを説明した図The figure explaining the output timing when 1/2 reduction is performed in the Y direction 3次畳み込み演算に用いる参照画素を表した図A diagram showing reference pixels used for the cubic convolution operation 本発明第2の実施例における全体構成の一例のブロック図The block diagram of an example of the whole structure in 2nd Example of this invention 演算制御装置の内部ブロック図Internal block diagram of arithmetic control unit 各変換方式における画素値のとり方を説明した図Diagram explaining how to take pixel values in each conversion method 一般的なエッジ強調回路例を説明した図Diagram illustrating an example of a general edge enhancement circuit 各変換方式における画素値のとり方を説明した図Diagram explaining how to take pixel values in each conversion method 本発明における拡大時の画素値のとり方を説明した図The figure explaining how to take the pixel value at the time of expansion in the present invention 拡大時の画素値のとり方を説明した図A diagram explaining how to take pixel values at the time of enlargement 画素消失の例を説明した図A diagram explaining an example of pixel loss 各変換方法における縮小時の画素値のとり方を説明した図The figure explaining how to take the pixel value at the time of reduction in each conversion method 縮小時の画素値のとり方を説明した図Diagram explaining how to take pixel values at the time of reduction 各変換方法における縮小時の画素値のとり方を説明した図The figure explaining how to take the pixel value at the time of reduction in each conversion method 本発明で使用する係数テーブルの一部を示した表Table showing a part of the coefficient table used in the present invention 線形補間法にて本手法を適用した場合の画素値のとり方を表した図Diagram showing how to take pixel values when this method is applied by the linear interpolation method

符号の説明Explanation of symbols

101 入力範囲設定装置
102 ラインバッファ制御装置
103 エッジ検出器
104 演算装置
105 出力制御装置
S01 入力制御信号
S02 入力画像データ
S03 演算装置入力データ
S04 エッジ検出データ
S05 演算装置出力データ
S06 出力画像データ
S07 入力有効範囲を指定するIATC信号
S08 水平(X)/垂直(Y)の倍率設定データ
S09 演算装置からの所望データのアドレスを指定するアドレス指定信号
S10 出力範囲指定信号
S11 出力制御信号
101 Input Range Setting Device 102 Line Buffer Control Device 103 Edge Detector 104 Arithmetic Device 105 Output Control Device S01 Input Control Signal S02 Input Image Data S03 Arithmetic Device Input Data S04 Edge Detection Data S05 Arithmetic Device Output Data S06 Output Image Data S07 Input Valid IATC signal S08 for designating a range Horizontal (X) / vertical (Y) magnification setting data S09 Address designating signal S10 for designating the address of desired data from the arithmetic unit Output range designating signal S11 Output control signal

Claims (6)

画像の拡大または縮小処理を実行する画像処理装置であって、
画素データを入力する入力手段と、
前記画素データの一部を一定の画素群にまとめて出力する出力手段と、
前記画素群を時系列に並べ替える並べ替え手段と、
前記画素群から画像のエッジを検出するエッジ検出器と、
前記エッジ検出器からの情報を基に係数テーブルの引数を補正する補正回路と、
前記補正回路から出力される引数から演算係数を決定する係数手段と、
前記係数手段から出力される係数に基づいて前記並べ替え装置から出力される画素データを演算することにより補間画素データを求める演算手段とを備えたことを特徴とする画像処理装置。
An image processing apparatus that executes image enlargement or reduction processing,
An input means for inputting pixel data;
Output means for collectively outputting a part of the pixel data to a certain pixel group;
Rearrangement means for rearranging the pixel groups in time series;
An edge detector for detecting an edge of an image from the pixel group;
A correction circuit for correcting an argument of a coefficient table based on information from the edge detector;
Coefficient means for determining a calculation coefficient from an argument output from the correction circuit;
An image processing apparatus comprising: an operation unit that obtains interpolated pixel data by calculating pixel data output from the rearrangement device based on a coefficient output from the coefficient unit.
前記演算手段において3次畳み込み内挿法により演算を行うことを特徴とする請求項1に記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the calculation unit performs a calculation by a cubic convolution interpolation method. 前記補正回路は、拡大の場合と縮小の場合とで異なる補正をすることを特徴とする請求項1記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the correction circuit performs different corrections for enlargement and reduction. 前記補正回路は、エッジ検出の差分量を参照し、その差分量に応じて補正量を変化させることを特徴とする請求項1記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the correction circuit refers to a difference amount of edge detection and changes the correction amount according to the difference amount. 前記エッジ検出器は、整数値成分である注目画素と前記注目画素に隣接する画素の画素データ値の差分情報と、次のラインの画素値との比較情報とから縦エッジもしくは横エッジを検出し、隣接画素の差分情報に応じて変化する補正情報を出力することを特徴とする請求項4に記載の画像処理装置。   The edge detector detects a vertical edge or a horizontal edge from difference information between a pixel data value of a pixel of interest which is an integer value component and a pixel adjacent to the pixel of interest, and comparison information between pixel values of the next line. The image processing apparatus according to claim 4, wherein correction information that changes in accordance with difference information between adjacent pixels is output. 前記エッジ検出器は、縮小処理の場合、整数値成分である注目画素と前記注目画素に隣接する画素の画素データ値の差分情報と、その両側の画素値との比較情報とから1画素毎に変化する画像の高周波成分を検出し特殊補正情報を出力し、前記補正回路は前記特殊補正情報から特殊引数を出力し、前記係数手段は前記特殊引数から固定係数を出力することを特徴とする請求項4に記載の画像処理装置。   In the case of the reduction process, the edge detector performs, for each pixel, the difference information between the pixel data value of the pixel of interest that is an integer value component and the pixel adjacent to the pixel of interest, and the comparison information between the pixel values on both sides thereof. The high-frequency component of a changing image is detected and special correction information is output, the correction circuit outputs a special argument from the special correction information, and the coefficient means outputs a fixed coefficient from the special argument. Item 5. The image processing apparatus according to Item 4.
JP2005128089A 2005-04-26 2005-04-26 Image processing apparatus Withdrawn JP2006308665A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005128089A JP2006308665A (en) 2005-04-26 2005-04-26 Image processing apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005128089A JP2006308665A (en) 2005-04-26 2005-04-26 Image processing apparatus

Publications (1)

Publication Number Publication Date
JP2006308665A true JP2006308665A (en) 2006-11-09

Family

ID=37475659

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005128089A Withdrawn JP2006308665A (en) 2005-04-26 2005-04-26 Image processing apparatus

Country Status (1)

Country Link
JP (1) JP2006308665A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009005235A (en) * 2007-06-25 2009-01-08 Seiko Epson Corp Projector, and image processor
WO2009130820A1 (en) * 2008-04-21 2009-10-29 シャープ株式会社 Image processing device, display, image processing method, program, and recording medium
JP2009296515A (en) * 2008-06-09 2009-12-17 Nec Corp Two-dimensional digital filter system, two-dimensional digital filtering method and program
US8917293B2 (en) 2008-06-27 2014-12-23 Sharp Kabushiki Kaisha Control device for liquid crystal display device, liquid crystal display device, method for controlling liquid crystal display device, program, and storage medium
US9105243B2 (en) 2008-06-27 2015-08-11 Sharp Kabushiki Kaisha Control device for liquid crystal display device, liquid crystal display device, method for controlling liquid crystal display device, program, and storage medium for program

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009005235A (en) * 2007-06-25 2009-01-08 Seiko Epson Corp Projector, and image processor
JP4609458B2 (en) * 2007-06-25 2011-01-12 セイコーエプソン株式会社 Projector and image processing apparatus
US8659508B2 (en) 2007-06-25 2014-02-25 Seiko Epson Corporation Projector and image processing apparatus
WO2009130820A1 (en) * 2008-04-21 2009-10-29 シャープ株式会社 Image processing device, display, image processing method, program, and recording medium
US8358307B2 (en) 2008-04-21 2013-01-22 Sharp Kabushiki Kaisha Image processing device, display device, image processing method, program, and storage medium
JP2009296515A (en) * 2008-06-09 2009-12-17 Nec Corp Two-dimensional digital filter system, two-dimensional digital filtering method and program
US8917293B2 (en) 2008-06-27 2014-12-23 Sharp Kabushiki Kaisha Control device for liquid crystal display device, liquid crystal display device, method for controlling liquid crystal display device, program, and storage medium
US9105243B2 (en) 2008-06-27 2015-08-11 Sharp Kabushiki Kaisha Control device for liquid crystal display device, liquid crystal display device, method for controlling liquid crystal display device, program, and storage medium for program

Similar Documents

Publication Publication Date Title
US9036939B2 (en) Video acquisition with processing based on ancillary data
US8451284B2 (en) Video acquisition with integrated GPU processing
US7596280B2 (en) Video acquisition with integrated GPU processing
US20090040246A1 (en) Image processing device, display device, image processing method, and program
JP5436020B2 (en) Image processing apparatus and image processing method
JP4035408B2 (en) Resolution conversion apparatus and method, and information processing apparatus
JP4274238B2 (en) Image processing apparatus, image processing method, and computer program
JP2006308665A (en) Image processing apparatus
JP2007249436A (en) Image signal processor and processing method
US6961479B1 (en) Image processing device, image processing method, image-processing program recorded medium
JP5341483B2 (en) Image transmitting apparatus and image receiving apparatus
JPWO2011155258A1 (en) Image processing apparatus and method, image display apparatus and method
JP4467416B2 (en) Tone correction device
JP4556982B2 (en) Video signal processing apparatus and video signal processing method
JP6403720B2 (en) Image processing apparatus, image processing method, and computer program
JP2008139828A (en) Image processing apparatus, image processing method, electro-optical device and electronic device
JP2008017321A (en) Image processing apparatus and image processing method
JP4483255B2 (en) Liquid crystal display
JP4910254B2 (en) Image processing apparatus and method
JP4551343B2 (en) Video processing apparatus and video processing method
JP5045119B2 (en) Color transient correction device
JP4628524B2 (en) Image composition processing device
JP2006276870A (en) Image processing device
JP3719385B2 (en) Image processing apparatus, image processing method, and image display apparatus
JP2000115720A (en) Scanning line interpolation device and scanning line interpolation method

Legal Events

Date Code Title Description
A300 Application deemed to be withdrawn because no request for examination was validly filed

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20080701