Background technology
In TV specification PAL (Phase Alternating Line), during chrominance signal in the demodulation television signal, can produce and have regular chrominance phase error (chroma phase error); That is in each figure (field), the chromatic value of each pixel of each scan line comprises an error amount; And this error amount is positive and negative staggered appearance between adjacent scanning lines, and shown in Fig. 1 (a), figure the f with small letter representes; Four figure fields that f0~f3 representative is continuous, f0 and f2 are bigraph field (even field), f1 and f3 are Qi Tuchang (odd field); L0, L1, L2 ... Deng being the numbering of scan line then, represent which the bar scan line in the picture frame (frame).By finding out among Fig. 1 (a), the scan line that the field comprises even-numbered and odd-numbered is respectively schemed with strange in the bigraph field, and with regard to same figure, the error amount that adjacent scanning lines comprised is an equal and opposite in direction and positive and negative opposite.With bigraph field f0 is example, scan line L0, L2, L4, L6 ... Error amount Deng being comprised is respectively+E0 ,-E0 ,+E0 ,-E0 ... Deng.In addition, different figure the error amount that scan line had is also inequality, for instance, the error amount that scan line had of a figure f0 and f1 respectively with ± E0 and ± E1 representes.
When the figure field among Fig. 1 (a) is passed through release of an interleave (de-interlacing) with the formation picture frame, can present situation like Fig. 1 (b).Among Fig. 1 (b), picture frame representes that with the F of capitalization picture frame F0 is formed by a figure f0, f1 release of an interleave, and picture frame F1 is formed by a figure f2, f3 release of an interleave.Therefore, the figure field of Fig. 1 (a) after handling through release of an interleave, wantonly two adjacent even number lines (like L0, L2 or L2, L4) of each picture frame and the error amount that wantonly two adjacent odd number lines (like L1, L3 or L3, L5) are had be equal and opposite in direction and positive and negative on the contrary.These error amounts are essential to be eliminated, otherwise can influence the signal quality of image.
Fig. 2 is the framework of existing processing television signal, and wherein, video decoder 21 is delivered to the television signal decoding that is received release of an interleave circuit 22 and carried out the release of an interleave processing, exports behind the convergent-divergent by scaler (scaler) 23 execution images more at last.In the existing framework of Fig. 2; The error amount of aforementioned PAL television signal is to be eliminated by video decoder 21; Thereby must be provided with at least one in the video decoder 21 or two scan line buffer devices (line buffer) come the scan line in the register map field more; So that carry out the elimination of error amount, so not only increase the cost of hardware, also can increase the time that signal is handled.
Summary of the invention
Technical problem to be solved by this invention provides a kind of filter and method and relevant display circuit in order to the elimination image error, can eliminate the error amount that image signal has, to save hardware cost and signal processing time.
In order to solve above technical problem, the invention provides following technical scheme:
The invention provides a kind ofly, comprise in order to eliminate the filter of image error: a plurality of multipliers, in order to receiving a plurality of pixel values, and export after each pixel value multiply by a corresponding weight coefficient from a plurality of scan lines; And an adder, in order to the output of totalling multiplier, to produce an output pixel value; Wherein, pixel value comprises error amount, and the size of error amount has a regularity, and the respective weights coefficient is relevant to the regularity of this error amount, so that adder is when producing output pixel value, the error amount of at least one part is repealed by implication.
The present invention provides a kind of method in order to the elimination image error in addition, and comprise the following step: receive a plurality of pixel values from a plurality of scan lines, pixel value comprises error amount, and the size of error amount has a regularity; Each pixel value multiply by a corresponding weight coefficient respectively, and to produce a plurality of medians, wherein this respective weights coefficient system is according to the regularity of this error amount; And the totalling median, to produce an output pixel value, make error amount repeal by implication.
The present invention provides a kind of display circuit of television signal in addition, comprises: video decoder, and in order to the reception television signal, and decoding generation chrominance signal, it has a signal error; The release of an interleave circuit is coupled to video decoder, in order to the release of an interleave chrominance signal; And scaler, be coupled to the release of an interleave circuit, in order to chrominance signal and this signal error of filtering of this release of an interleave of convergent-divergent.
Filter and method and relevant display circuit in order to the elimination image error that the present invention adopts can be eliminated the error amount that image signal has, to save hardware cost and signal processing time; In the time of also can presenting a regularity at the error amount of image signal, according to the coefficient of this regular decision filter, to eliminate the error amount of image signal; Wherein, the display circuit of television signal can be eliminated the error amount that chrominance signal had in the television signal when the vertically scale of carrying out television signal, to save hardware cost and signal processing time.
Embodiment
The following embodiments of the invention of narrating; Can be for the chrominance signal in the PAL television signal or any image signal with like error characteristic; That is has an image signal of the systematic error shown in similar Fig. 1 (b); When carrying out the image vertically scale, eliminate the error amount that is comprised in the signal.In other words, in the image processing architecture of Fig. 2, prior art is in video decoder 21, to carry out the elimination of error amount, and therefore need set up the scan line buffer device keeps in scan line, and needs the extra processing time to eliminate error amount; The present invention then can eliminate error amount when carrying out the vertically scale of image in scaler 23 in the lump; And owing to itself promptly have the scan line buffer device in the scaler 23; Therefore the scan line buffer device needn't be increased in addition newly, so hardware cost and signal processing time can be saved simultaneously.
Fig. 3 is the circuit diagram in order to the filter 30 of eliminating image error of preferred embodiment of the present invention; Comprise a N multiplier 32-1~32-N and an adder 33; That is; Filter 30 is the filter (N-tap filter) with N tap, and this N tap has corresponding weight coefficient (or being called tap coefficient (tap coefficient)) C respectively
0, C
1And C
N-1N multiplier 32-1~32-N can receive pixel value respectively from N bar scan line, exports after it multiply by corresponding weight coefficient; The output of 33 totalling N multipliers of adder is to produce output pixel value.The error amount size that comprises when the pixel value that is received has one when regular; For example; Error amount is positive and negative staggered appearance, and then the big I of respective weights coefficient is set according to this regularity dexterously, so that adder 33 is when producing output pixel value; Eliminate error amount, reduce the complexity of circuit.
For example; When filter 30 can be implemented in the vertical scaler is a vertically scale filter 30; Can receive the picture frame of the PAL television signal of handling through release of an interleave, perhaps, receive the image frame that other has similar systematic error; It is carried out vertically scale, and utilize adder 33 that the error amount that is comprised in the picture frame is eliminated dexterously.For example, N multiplier 32-1~32-N receives N pixel value P of N continuous bar scan line in the picture frame respectively
0, P
1... And P
N-1, that is multiplier 32-1 receives P from article one scan line
0, multiplier 32-2 receives P from the second scan line
1The rest may be inferred for all the other; Then, this N multiplier is exported after this N pixel value multiply by corresponding weight coefficient respectively, that is multiplier 32-1 is with P
0Multiply by C
0, multiplier 32-2 is P
1Multiply by C
1The rest may be inferred for all the other; The output of this N of adder 33 totallings multiplier is to produce an inter polated pixel value P
iTherefore:
P
i=P
0* C
0+ P
1* C
1+ ... + P
N-1* C
N-1Formula (1)
If this N pixel value is the chromatic value under the PAL specification, the error amount that then it had will have the regularity shown in Fig. 1 (b), that is, pixel value P
0, P
4Respectively comprise first error amount, P
2, P
6Respectively comprise second error amount, P
1, P
5Respectively comprise the 3rd error amount, P
3, P
7Respectively comprise the 4th error amount, first error amount and the second error amount equal and opposite in direction and positive and negative opposite, the 3rd error amount and the 4th error amount equal and opposite in direction and positive and negative opposite.In filter 30, the weight coefficient C of N tap
0, C
1And C
N-1System is designed to C
0, C
4Sum equals C
2, C
6Sum, C
1, C
5Sum equals C
3, C
7Sum, in this embodiment, in formula (1), all error term can be expressed as:
(C
0+ C
4) * first error amount+(C
2+ C
6) * second error amount+(C
1+ C
5) * the 3rd error amount+(C
3+ C
7) * the 4th error amount=0
Therefore, error amount can positive and negatively balance out.In other words, filter 30 produces the inter polated pixel value by formula (1), can reach simultaneously to carry out vertically scale and the dual purpose of eliminating error amount.
When N equaled four, the relation between the weight coefficient of tap can be reduced to C
0Equal C
2, C
1Equal C
3Below to equal four with N be example, illustrate two kinds of producing methods of the respective weights coefficient of tap.First kind of producing method is as shown in Figure 4, inter polated pixel P
iBe according to P
0, P
1, P
2And P
3Four pixels produce, and P
iThe position be between P
1With P
2Between.Suppose P
iThe position near P
1, and P
1With P
2The weight proportion that is provided is respectively 6 and 4 (because P
iNear P
1So, P
1The weight that provides is bigger).Preferably, P
0With P
2Weight coefficient should be identical, so P
1But weight 6 average marks that provided are to P
0With P
2, and produce P
0With P
2Weight coefficient be respectively 3, i.e. C
0=C
2=3; Preferably, P
1With P
3Weight coefficient should be identical, so P
2But weight 4 average marks that provided are to P
1With P
3, and produce P
1With P
3Weight coefficient be respectively 2, i.e. C
1=C
3=2.As inter polated pixel P
iBe positioned at P
1With P
2Between diverse location the time, P
1With P
2The weight proportion that is provided also can change thereupon, and aforementioned manner all capable of using decides the respective weights coefficient of each tap.
Second kind of producing method is as shown in Figure 5, inter polated pixel P
iBe according to P
0, P
1, P
2And P
3Four pixels produce, and P
iThe position be between P
1With P
2Between.In Fig. 5, introduced a parameter Δ, also can be described as zoom factor (scaling factor), it represents the distance between Pi and P1, and on behalf of Pi, Δ=0 be positioned at the position of P1, and on behalf of Pi, Δ=1 be positioned at the position of P2.In this embodiment; Need preestablish each weight coefficient of Δ=0 and Δ=1 o'clock, then when Δ equals any value between 0 and 1, can be by predefined two groups of weight coefficient values; Carry out α according to the Δ value and mix (alphablending) computing, can obtain required weight coefficient.For instance, as shown in Figure 5, each the weight coefficient (C in Δ=0 and Δ=1 o'clock
0, C
1, C
2, C
3) be to be redefined for (1,2,1,2) and (2,1,2,1) respectively, then when Δ=0.2, C
0=2 * Δ+1 * (1-Δ)=1.2, C
1=1 * Δ+2 * (1-Δ)=1.8, C
2With C
3Also can utilize this method to calculate.Δ=0.8 o'clock algorithm is also similar, does not give unnecessary details now.
Fig. 6 is the calcspar of display circuit 60 of the television signal of preferred embodiment of the present invention, comprises video decoder 61, release of an interleave circuit 62 and scaler 63.Video decoder 61 is in order to receiving a television signal, and decoding produces a colourity signal, and it has a signal error, and for example, this television signal can be the PAL television signal, and its signal error is the chrominance phase error; Release of an interleave circuit 62 is coupled to video decoder 61, but the chrominance signal that 61 decodings of release of an interleave video decoder produce; Scaler 63 is coupled to release of an interleave circuit 62, scalable chrominance signal and its signal error of filtering through release of an interleave.Comprise vertical scaler 631 in the scaler 63, it is the filter (4-tap filter) with four taps, and circuit structure is similar to the filter 30 of Fig. 3.Four taps receive the pixel value of continuous four scan lines in the chrominance signal of release of an interleave respectively, to produce the inter polated pixel value.When television signal was the PAL television signal, its chrominance phase error can present the regularity shown in Fig. 1 (b), preferably, and with the respective weights coefficient D of these four taps
0, D
1, D
2And D
3Set D for
0Equal D
2, D
1Equal D
3, vertical scaler 631 just can be when carrying out vertically scale, in the lump with the chrominance phase error concealment, and line buffer that need not be extra.
Fig. 7 is the flow chart in order to the method for eliminating image error of preferred embodiment of the present invention.In the step 71, receive N pixel value P
0, P
1... And P
N-1, this N pixel value belongs to N bar scan line respectively, for example, and the N continuous bar scan line in the picture frame.This N pixel value can be the chromatic value under the PAL specification, or other has the pixel value of similar systematic error.
In the step 72, this N pixel value multiply by corresponding weight coefficient C respectively
0, C
1And C
N-1, to produce N median, wherein C
0, C
4Sum equals C
2, C
6Sum, C
1, C
5Sum equals C
3, C
7Sum.
In the step 73, this N of totalling median is to produce an inter polated pixel value.
In sum, the present invention discloses a kind of filter in order to the elimination image error, comprises a N multiplier and an adder, and N multiplier is respectively in order to receive N pixel value P
0, P
1... And P
N-1, N pixel value belongs to N bar scan line respectively, and this N multiplier is exported after each pixel value multiply by a corresponding weight coefficient; Adder is in order to the output of this N of totalling multiplier, to produce an output pixel value; Wherein, the error amount size that pixel value comprised has a regularity, and the respective weights coefficient is relevant to this regularity, so that adder is when producing output pixel value, error amount can be repealed by implication.When this N pixel value is the chromatic value under the PAL specification, can be with this respective weights coefficient C
0, C
1And C
N-1Be set at C
0, C
4Sum equals C
2, C
6Sum, C
1, C
5Sum equals C
3, C
7Sum is to eliminate this N the chrominance phase error that pixel value was comprised.It should be noted that; Know this skill personage and all can understand, can make many possibly the variation according to the announcement of above embodiment, for example; Though the foregoing description describes with the PAL television signal; The processing of the regular signal error that repeats when knowing this skill personage and can understand this kind circuit design and can be applied to picture and handle, for example, the regular signal error that repeats possibly appear at the cross wires that is occurred in the process of release of an interleave; Its regularity then is not limited to four multiple, possibly be the error that appears between adjacent scanning lines.
The above is to utilize preferred embodiment to specify the present invention, and unrestricted scope of the present invention.Allly know this skill personage and all can understand, can make many possibly the variation, still do not break away from the spirit and scope of the present invention according to the announcement of above embodiment.