Background technology
General television broadcast video signal adopts staggered (interlaced) form, for example NTSC, PAL, SECAM, it interlocks in regular turn with odd number figure field (field) and even number figure field and is shown in television screen, utilizes persistence of vision principle to demonstrate the video content of frame (frame).Interlace video signal only need use low frequency range can transmit acceptable video quality; Yet its shortcoming is to cause flicker (flicker) phenomenon in the reduction of vertical resolution, lines or zone.The vision signal of general computer display then is to adopt noninterlace (non-interlaced) or (progressive) form in proper order, and it directly is shown in the video content of frame on the computer display.
For interlace video signal can be shown in proper order on the display of signal format (for example display of computer), must earlier interlace video signal be converted to the vision signal of noninterlace/in proper order, this kind format conversion processing process is called deinterleave (de-interlacing) or frequency multiplication in proper order.By deinterleave conversion, with odd number figure field (field) originally and even number figure field in conjunction with producing a frame.
The interleaving removal conversation method of vision signal can reduce following several: space (spatial) conversion, time (temporal) conversion and space-time (spatial-temporal) mix conversion.In space conversion, the pixel (pixel) (or being called figure point or sampling point (sample)) of only using same figure field is to produce new pixel, and therefore, this kind conversion generally is called (intra-field) conversion in the figure field again.In the time conversion, use adjacent different figure pixel to produce new pixel, therefore, this kind conversion generally is called (inter-field) conversion between the figure field again.Mixing conversion as for space-time, then is that conversion of mixing usage space and time conversion are to produce new pixel.
In various conversions, space conversion is basic and important a kind of conversion method, particularly has mobilely when video content, perhaps changes when undesirable when the time.The basic principle of space conversion produces correlation (correlation) character that has between new location of pixels and the neighbor according to hope, uses interpolation (interpolation) method to produce new pixel.
Figure 1A and Figure 1B show traditional interpolating method, wherein are listed as n-1 and row n+1 and are two adjacent pixel columns in the figure field, and row n is a new pixel column for the treatment of that interpolation produces, and it is produced through interpolation by adjacent pixels.Shown in Figure 1A, new pixel X is produced through interpolation by the neighbor (as the oblique line those shown) of row k-1, row k, row k+1.Figure 1B shows that another new pixel X+1 is produced through interpolation by the neighbor (as the oblique line those shown) of row k, row k+1, row k+2.
The deinterleave conversion of above-mentioned traditional interpolation can produce zigzag (serrate) or fuzzy shape lines, particularly is positioned at image edge (edge) and locates.At this problem, need badly and propose a kind of new conversion method, make lines more level and smooth (smooth).
Summary of the invention
The present invention proposes a kind of far-end interpolating method, avoids producing zigzag (serrate) or fuzzy shape lines when being used for the deinterleave conversion, and makes lines more level and smooth.
The invention provides a kind of interleaving removal conversation method of far-end interpolation.At first, with a plurality of pixels in top of the new pixel for the treatment of interpolation as last window (up window), the a plurality of pixels conducts in below are window (down window) down, above-mentioned last window comprise upper left pixel, directly over pixel, upper right side pixel, above-mentioned following window comprise the lower left pixel, under pixel, lower right pixel.When pixel directly over this and under this numerical value difference of pixel then come interpolation to produce new pixel for hour with this two pixel, after new pixel produced, last window, each moved a pixel distance to time window to the right.When the numerical value difference of this upper left pixel and this lower right pixel for hour, then come interpolation to produce new pixel with this two pixel, after new pixel produced, following window at least two pixel distances that move right did not move and go up window.When the numerical value difference of this upper right side pixel and this lower left pixel for hour, then come interpolation to produce new pixel with this two pixel, after new pixel produces, last window at least two pixel distances that move right, and window is mobile down.
The present invention provides a kind of deinterleave conversion equipment of far-end interpolation in addition, comprise: two window buffers, keep in the pixel of adjacent two pixel columns respectively, reach window down as last window respectively, above-mentioned last window comprise upper left pixel, directly over pixel, upper right side pixel, above-mentioned following window comprise the lower left pixel, under pixel, lower right pixel; One comparator, in order to relatively determine window on this, down the pixel number difference of the various combination of pixels of window is minimum the two, these various combination of pixels comprise: should directly over pixel and should under pixel; This upper left pixel and this lower right pixel; And this upper right side pixel and this lower left pixel; One interpolation device, carry out interpolative operation to produce a new pixel according to difference for minimum combination of pixels, wherein: if should directly over pixel and under this numerical value difference of pixel for hour, then with pixel directly over this and should under pixel come this new pixel of interpolation generation; If the numerical value difference of this upper left pixel and this lower right pixel is then come this new pixel of interpolation generation with this upper left pixel and this lower right pixel for hour; And if the numerical value difference of this upper right side pixel and this lower left pixel for hour, is then come this new pixel of interpolation generation with this upper right side pixel and this lower left pixel; Wherein, above-mentioned comparator produces two control signals according to its comparative result and controls this two windows buffer respectively, wherein: if should directly over pixel and numerical value difference of pixel is for hour under this, after this new pixel produced, window on this, each moved a pixel distance to time window to the right; If the numerical value difference of this upper left pixel and this lower right pixel is for hour, after this new pixel produces, this play window at least two pixel distances that move right, and upward window is mobile; And if the numerical value difference of this upper right side pixel and this lower left pixel for hour, after this new pixel produces, window at least two pixel distances that move right on this, and this time window is mobile.
The interleaving removal conversation method of far-end interpolation of the present invention and device are avoided producing zigzag or fuzzy shape lines when being used for the deinterleave conversion, and are made lines more level and smooth.
Embodiment
The embodiment of the invention proposes a kind of deinterleave (de-interlacing) conversion method, and figure field (field) vision signal of be used for interlocking (interlaced) produces new pixel with interpolation (interpolation) method.
Fig. 2 A and Fig. 2 B show employed window when present embodiment carries out interpolation.In Fig. 2 A, get the adjacent upper left pixel UL of new pixel X, directly over pixel U, upper right side pixel UR as last window (up window), and get the adjacent lower left pixel DL of new pixel X, under pixel D, lower right pixel DR as following window (downwindow).Though the last window of the embodiment of the invention, following window respectively use three pixels, yet also can use the window of other number of pixels.In Fig. 2 B, last window (UL, U, UR) and following window (DL, D, DR) be not be positioned at new pixel X directly over, the below; And a window (being called leading window) another window (being called backward window) is in advance arranged wherein usually, therefore the present invention is called far-end interpolation method (remoteinterpolation) again, is different from traditional regional interpolation method (local interpolation).
No matter be the situation of Fig. 2 A or Fig. 2 B, the window pixel formed at least three kinds of combinations of pairs to each other under last window pixel reached: (1) pixel U and pixel D, and in Fig. 2 A, pixel U and pixel D are positioned at 90 ° of angles; (2) pixel UL and pixel DR, in Fig. 2 A, pixel UL and pixel DR are positioned at-45; (3) pixel UR and pixel DL, in Fig. 2 A, pixel UR and pixel DL are positioned at 45.
Fig. 3 shows the flow chart of the embodiment of the invention.At first, window in the decision, down in three kinds of combinations of window, the pixel intensity of any combination (luma) numerical value be near (for example both differences are minimum) (step 30).Though the brightness of present embodiment calculating pixel, yet the present invention also can calculating pixel colourity (chroma) replace.Three kinds of combinations of last window, following window are as follows:
(a) when one of them pixel of one of them pixel of last window and following window constitutes a vertical angle, for example pixel U and pixel D, if this group pixel intensity numerical value near the time, then come interpolation to produce new pixel (step 31A) with this two pixel, for example the mean value of plain U of capture and pixel D (=(U+D)/2) is as the value of new pixel.After producing new pixel, each moves (or a more than) pixel distance (step 32A) to the right for last window, time window, next promptly carries out another time interpolation at right-hand pixel of adjacent pixels X.
(b) when one of them pixel of one of them pixel of last window and following window constitutes a negative angle, for example pixel UL and pixel DR, if this group pixel intensity numerical value near the time, then come interpolation to produce new pixel (step 31B) with this two pixel, for example the mean value of plain UL of capture and pixel DR (=(UL+DR)/2) is as the value of new pixel.After producing new pixel, following window two (or other numbers) pixel distances that move right do not move (step 32B) and go up window.
(c) when one of them pixel of one of them pixel of last window and following window constitutes a positive-angle, for example pixel UR and pixel DL, if this group pixel intensity numerical value near the time, then come interpolation to produce new pixel (step 31C) with this two pixel, for example the mean value of plain UR of capture and pixel DL (=(UR+DL)/2) is as the value of new pixel.After producing new pixel, last window two (or other numbers) pixel distances that move right, and window mobile (step 32C) down.
In the present embodiment, if having the last window of two kinds of (or more than) angles, down the window pixel all equally near the time, then according to the priority of (a) and (b), (c).Yet, also can change its priority.
For the ease of understanding, be the running of example explanation present embodiment with Fig. 4 A to Fig. 4 I.In this example, demonstrate three row altogether, wherein first row and the 3rd are classified the pixel column of former figure field as, and second classifies the new pixel column of pending far-end interpolation as; The order of the new pixel of digitized representation of first side of listing; Numerical value in each pixel compartments is represented the brightness value of this pixel.
Fig. 4 A shows the interpolation carry out the 0th new pixel (numerical value 0 identical with row 0 is filled on the left side of row 0 respectively), and pixel UL, U, the UR numerical value of window on it (as the frame person of dotted line institute) are respectively 0,0,0; Pixel DL, D, the DR numerical value of window (as the frame person of dotted line institute) are respectively 0,0,0 down for they.According to rule (a), because the pixel intensity numerical value of pixel U and pixel D for the most approaching, therefore comes interpolation to produce new pixel with this two pixel, for example the mean value 0 of plain U (0) of capture and pixel D (0) (=(0+0)/2) is as the new value of pixel.After producing new pixel, last window, each moves a pixel distance to time window to the right, shown in Fig. 4 B.
Fig. 4 B shows the interpolation of carrying out the 1st new pixel, and pixel UL, U, the UR numerical value of window on it (as the frame person of dotted line institute) are maintained 0,0,0 respectively; Pixel DL, D, the DR numerical value of window (as the frame person of dotted line institute) are respectively 0,0,10 down for they.According to regular a, because the pixel intensity numerical value of pixel U and pixel D for the most approaching, therefore comes interpolation to produce new pixel with this two pixel, for example the mean value 0 of plain U (0) of capture and pixel D (0) (=(0+0)/2) is as the new value of pixel.After producing new pixel, last window, each moves a pixel distance to time window to the right, shown in Fig. 4 C.
Fig. 4 C shows the interpolation of carrying out the 2nd new pixel, and pixel UL, U, the UR numerical value of window on it (as the frame person of dotted line institute) are respectively 0,0,0; Pixel DL, D, the DR numerical value of window (as the frame person of dotted line institute) are maintained 0,10,10 respectively down for they.According to regular c, because the pixel intensity numerical value of pixel UR and pixel DL is for the most approaching, therefore come interpolation to produce new pixel with this two pixel, for example the mean value 0 of plain UR (0) of capture and pixel DL (0) (=(0+0)/2) is as the new value of pixel.After producing new pixel, last window two pixel distances that move right, and window is mobile down, shown in Fig. 4 D.
Fig. 4 D shows the interpolation of carrying out the 3rd new pixel, and pixel UL, U, the UR numerical value of window on it (as the frame person of dotted line institute) are respectively 0,0,0; Pixel DL, D, the DR numerical value of window (as the frame person of dotted line institute) are maintained 0,10,10 respectively down for they.According to rule (c), because the pixel intensity numerical value of pixel UR and pixel DL for the most approaching, therefore comes interpolation to produce new pixel with this two pixel, for example the mean value 0 of plain UR (0) of capture and pixel DL (0) (=(0+0)/2) is as the new value of pixel.After producing new pixel, last window two pixel distances that move right, and window is mobile down, shown in Fig. 4 E.
Fig. 4 E shows the interpolation of carrying out the 4th new pixel, and pixel UL, U, the UR numerical value of window on it (as the frame person of dotted line institute) are respectively 0,10,10; Pixel DL, D, the DR numerical value of window (as the frame person of dotted line institute) are maintained 0,10,10 respectively down for they.According to rule (a), because the pixel intensity numerical value of pixel U and pixel D for the most approaching, therefore comes interpolation to produce new pixel with this two pixel, for example the mean value 10 of plain U (10) of capture and pixel D (10) (=(10+10)/2) is as the new value of pixel.After producing new pixel, last window, each moves a pixel distance to time window to the right, shown in Fig. 4 F.5th, the interpolation of 6,7 new pixels is shown in Fig. 4 F, Fig. 4 G, Fig. 4 H respectively, and its details repeats no more.The generation of all the other new pixels principle is according to this analogized, and Fig. 4 I shows that the new pixel of permutation all produces.
Fig. 5 shows the system block diagrams of the embodiment of the invention.Use at least three pixels of adjacent two pixel columns in two window buffers (for example buffer) 50A, the 50B difference register map field, respectively as last window, following window.(meaning promptly relatively to determine window, three kinds of combinations of window down with comparator 52, (1) pixel U and pixel D, (2) pixel UL and pixel DR, (3) pixel UR and pixel DL), the pixel number of any combination is near (for example both differences are for minimum).Immediate one group of pixel is sent to carries out interpolative operation (for example getting the mean value of two pixels) in the interpolation device 54, to produce new pixel.Comparator 52 is according to its comparative result, control window buffer 50A, 50B respectively with control signal 56A, 56B, make the pixel in the window carry out moving or not moving of window pixel, prepare to carry out the interpolation of next new pixel according to the aforementioned rule (a) and (b) or (c).
The above only is preferred embodiment of the present invention; so it is not in order to limit scope of the present invention; any personnel that are familiar with this technology; without departing from the spirit and scope of the present invention; can do further improvement and variation on this basis, so the scope that claims were defined that protection scope of the present invention is worked as with the application is as the criterion.