CN104580978B - A kind of video detection and processing method, device - Google Patents
A kind of video detection and processing method, device Download PDFInfo
- Publication number
- CN104580978B CN104580978B CN201510071223.1A CN201510071223A CN104580978B CN 104580978 B CN104580978 B CN 104580978B CN 201510071223 A CN201510071223 A CN 201510071223A CN 104580978 B CN104580978 B CN 104580978B
- Authority
- CN
- China
- Prior art keywords
- field
- pixel
- frame
- broach
- film
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Abstract
The present invention relates to video detection and processing method, predict whether current field is film field by calculating the overall relevancy of adjacent field picture, when being judged as YES, current field is merged into framing with opposite field, then the detection comb pseudomorphism pixel-by-pixel in the synthetic frame, if without broach pseudomorphism, it is film mode to confirm current regional area, the frame of video using described synthetic frame as reduction;If broach pseudomorphism, then it is non-film mode to judge current regional area, now calculates interpolated frame using Motion Adaptive method or spatial domain interpolation method, the frame of video as reduction.The present invention can correctly detect movie field and interlacing region in mixed video, and be handled respectively using different deinterlacing techniques, both recover the details of movie field, avoid producing jagged edge again.Meanwhile identical input can be used in film mode detection module and de interlacing module, reduce field caching and DDR bandwidth, be advantageous to save hardware cost.
Description
Technical field
The present invention relates to video mode detection field, more particularly to a kind of video detection and processing method, device.
Background technology
Film is typically what is shot by row-by-row system with 24 frame per second.In order to play film festival glibly on a television set
Mesh carries out broadcast transmission, it is necessary to which moving-picture frame is split as into TV field signal, and this technology is referred to as pulling down conversion process, common bag
Include 3 in being broadcasted for TSC-system formula:2 drop-downs convert and for 2 in pal mode broadcast:2 drop-down converter techniques.With 3:Under 2
Exemplified by drawing conversion, represented if film frame sequence is with A, B, C, D ..., as shown in figure 1, first Liang Chang, such as A will be splitted into per frametWith
Ab, wherein subscript t and b represents to push up field and bottom field respectively, by 3:The TV field signal obtained after 2 drop-down conversion process is At、
Ab、At、Bb、Bt、Ct、Cb、Ct、Dt、Db、Dt..., its rate is 60 per second.2:2 drop-down converter techniques are similarly.
Film mode is detected as follow-up de interlacing processing and provides necessary information.If it is known that currently pending field
FtIt is film video, and it is front court F to be also known as with other one of this from same moving-picture framet-1Or back court Ft+1, then only
Need that this two weave ins simply can be restored into original moving-picture frame, the process is referred to as anti-drop-down conversion process.With it is general
The conventional deinterlacing technique (such as field interpolation or Motion Adaptive de interlacing) of logical television video is different, counter to pull down conversion process
Image detail can farthest be kept.But broach pseudomorphism can then be caused by pair doing anti-drop-down conversion process with non-movie field.One
As think, result caused by flase drop occurs in film mode (being film i.e. by non-movie video detection) is than missing inspection (i.e. by film
Video detection is non-movie) it is serious.
The general principle converted according to above-mentioned drop-down, the content of the adjacent two field picture from same moving-picture frame often have
Stronger correlation (two of synchronization record, such as the A in Fig. 1tAnd Ab), and adjacent two phases from different moving-picture frames
Smaller (two recorded at different moments, such as Fig. 1 A of closing propertytAnd Bb), while these strong correlations and weak dependence are continuous
Certain periodicity is shown in film sequence.If with 1 represent current field with close to back court correlation it is stronger, with 0 represent work as
Front court with close to back court correlation it is weaker, then TV Field can be found shown in analysis chart 1,3:2 drop-down conversion film sequences have
Following correlation rule:
11010 11010 11010 11010 ……
Respectively with first At, Ab, second At, BbField and BtAs starting field, then 3:2 drop-down conversion film sequences
Show five kinds of possible correlation rules:11010,10101,01011,10110,01101, it is close to field to define this five kinds of patterns
Correlation reference model.It can be seen that if the vision signal of input is 3:2 drop-down conversion film sequences, then per continuous five field picture
Five kinds of the above must be met close to one kind in the correlation reference model of field, and every continuous five field picture afterwards all has therewith
Identical correlation rule.
Further, since 3:In 2 drop-down conversion film sequences a content (such as A is always had per in continuous fivet) repeat
Occur, so by continuously counting the correlation between the front court of current field and back court, can also find certain periodic regularity.
Still exemplified by shown in Fig. 1, if representing that there is strong correlation between the front court of current field and back court with 1, and current field is represented with 0
Front court and back court between have compared with weak dependence, respectively with first At, Ab, second At, BbField and BtField is used as
Beginning field, it is possible to find five kinds of possible correlation rules:01000,10000,00001,00010,00100, define this five kinds matchings
Rule is interval field correlation reference model.It can be seen that if the vision signal of input is 3:2 drop-down conversion film sequences, then often connect
Five continuous field pictures must meet one kind in five kinds of interval field correlation reference models of the above, and every continuous five figures afterwards
As all having same correlation rule.
Existing film mode detection technique mostly, which is also exactly based on, calculates the overall relevancy of adjacent field picture judge ought
Whether front court is film field.Fig. 2 gives currently used film mode detection and de interlacing flow, and wherein film mode detects
Module needs three field datas input such as Ft,Ft-1And Ft-2To calculate the correlation between opposite field, the output of module is to field Ft-1
Testing result, including whether it is film field and and FtOr Ft-2From same moving-picture frame.De interlacing module is also required to three
Field data input such as Ft-1, Ft-2And Ft-3To carry out Motion Adaptive de interlacing processing, it exports Ft-2* F is representedt-2The interpolation of field
Result frame, now need to obtain F from film mode detection modulet-2Film mode information is (with M corresponding tot-2Represent), if
Ft-2Field is film field, just using anti-drop-down transform method acquisition progressive frame, is otherwise just calculated using Motion Adaptive method slotting
It is worth frame.It can be seen that in prior art, the result of the result of de interlacing module always than film mode detection module has
The delay of one, this needs more field cachings and DDR bandwidth.
On the other hand, usually contained in the mute of actual transmissions later stage compilation addition interlacing information, such as captions,
Station symbol that scroll bar, sign language window even rotate etc..Prior art only gives the testing result of whole field, and this causes de interlacing module
The interlacing region in these mixed videos is also served as into film mode to handle by mistake, so as to broach pseudomorphism (such as Figure 11) occur.
The content of the invention
In view of the problems of the prior art, in a first aspect, the embodiment of the present invention provides a kind of video detection and processing side
Method, judge whether current field is film field by calculating the overall relevancy of adjacent field picture, ought when being judged as film field
Front court merges framing with opposite field, then the detection comb pseudomorphism pixel-by-pixel in the synthetic frame, if without broach pseudomorphism, it is determined that
Current regional area is film mode, the frame of video using described synthetic frame as reduction;If broach pseudomorphism, then judge to work as
Preceding regional area is non-film mode, now calculates interpolated frame using Motion Adaptive method or spatial domain interpolation method, is made
For the frame of video of reduction, described current regional area includes described current field and opposite field.
It is preferably, described that the method for detection comb pseudomorphism includes pixel-by-pixel in the synthetic frame:Obtain and merge in frame currently
Pixel characteristic value in pixel NxN neighborhoods;Calculate the pixel characteristic value intermediate value of the neighborhood territory pixel of first direction three of current pixel, meter
Calculate the pixel characteristic value of the respective neighborhood territory pixel of first direction three of two pixels most adjacent with current pixel in a first direction
Intermediate value;The poor absolute value of each intermediate value and the pixel characteristic value of each center pixel is calculated respectively;By these three absolute values and threshold value
It is compared, if any of they are more than threshold value, it is believed that first direction detects broach, that is, has broach pseudomorphism, otherwise recognize
Do not detect broach for the direction, i.e., be positive integer without broach pseudomorphism, the N, the NxN represent one using current pixel as
The rectangular area of central point.
It is noted that so-called pixel characteristic value here refers to the property value of each pixel in image, such as each
Pixel can use tri- component values of Y, Cb, Cr, or tri- component values of R, G, B (typically can be by collecting device or head end video
Decoder provides) represent, and be separate relation between these three components (or being passage).The present invention herein both can be single
Solely selection Y or Cb or Cr or R or G or channel B handled as pixel characteristic value, can also will wherein several combination of channels into
New pixel characteristic value is handled.I.e., it is preferable that described pixel characteristic value is YCbCr values or rgb value.If represented with P
Described pixel characteristic value, some of YCbCr or RGB components can be individually selected in the embodiment of the present invention as pixel characteristic value,
Such as P=Y;Wherein several component combination Cheng Xin pixel characteristic value, such as P=(R+G+B)/3 can not also be spy herein
Do not limit.
Preferably, described first direction be vertically oriented, horizontal direction or other directions.
In second aspect, the present invention also provides a kind of video detection and processing unit, including film mode detection module, electricity
Shadow model-based optimization module and de interlacing module, the film mode optimization module include generation and merge frame module and broach detection mould
Block, the film mode detection module, for by calculating the overall relevancy of adjacent field picture to detect current field be film
During field, generation testing result being sent in the film mode optimization module merges frame module;The generation merges frame mould
Block, for when receiving film field testing result, being sent by current field occasion adjacent thereto and framing, and by the frame for merging generation
To described broach detection module;The broach detection module, for the detection comb pseudomorphism pixel-by-pixel of the synthetic frame to receiving, such as
Fruit has broach pseudomorphism, it is determined that current regional area is non-film mode, and the de interlacing module described by result notice is determined;
Described de interlacing module, for receive determine result be non-movie pattern when, inserted using Motion Adaptive method or spatial domain
Value method calculates interpolated frame, and as the frame of video of reduction, described current regional area includes described current field and adjacent
.
Preferably, the step of broach detection module carries out detection comb pseudomorphism pixel-by-pixel to synthetic frame includes:Obtain
Merge the pixel characteristic value in current pixel NxN neighborhoods in frame;Calculate the pixel of the neighborhood territory pixel of first direction three of current pixel
Characteristic value intermediate value, calculate the respective neighborhood territory pixel of first direction three of two pixels most adjacent with current pixel in a first direction
Pixel characteristic value intermediate value;The poor absolute value of each intermediate value and the pixel characteristic value of each center pixel is calculated respectively;By these three
Absolute value is compared with threshold value, if any of they are more than threshold value, it is believed that first direction detects broach, that is, has broach
Pseudomorphism, otherwise it is assumed that the direction does not detect broach, i.e., it is positive integer without broach pseudomorphism, the N, the NxN represents one
The rectangular area put centered on current pixel.
In the third aspect, the present invention also provides a kind of video detection and processing unit, including film mode detection module, electricity
Shadow model-based optimization module and de interlacing module, the film mode optimization module include film mode prediction module, and generation merges
Frame module and broach detection module, the film mode detection module, for the overall relevancy by calculating adjacent field picture
When to detect current field being film field, film mode testing result being sent in the film mode optimization module predicts mould
Block;The film mode prediction module, for based on existing for the film mode information between opposite field periodically, according to foregoing
It is film mode that film field testing result, which predicts next field, and the prediction result is sent into generation and merges frame module;It is described
Generation merges frame module, for when receiving film field prediction result, by described next field occasion adjacent thereto and framing, and
The frame for merging generation is sent to described broach detection module;The broach detection module, for the synthetic frame to receiving by
Pixel detection broach pseudomorphism, if broach pseudomorphism, it is determined that current regional area is non-film mode, and will determine that result is led to
Know described de interlacing module;Described de interlacing module, for receive determine result be non-movie pattern when, using move oneself
Adaptive method or spatial domain interpolation method calculate interpolated frame, and as the frame of video of reduction, described current regional area includes
Described next field and its opposite field.
Preferably, the step of broach detection module carries out detection comb pseudomorphism pixel-by-pixel to synthetic frame includes:Obtain
Merge the pixel characteristic value in current pixel NxN neighborhoods in frame;Calculate the pixel of the neighborhood territory pixel of first direction three of current pixel
Characteristic value intermediate value, calculate the respective neighborhood territory pixel of first direction three of two pixels most adjacent with current pixel in a first direction
Pixel characteristic value intermediate value;The poor absolute value of each intermediate value and the pixel characteristic value of each center pixel is calculated respectively;By these three
Absolute value is compared with threshold value, if any of they are more than threshold value, it is believed that first direction detects broach, that is, has broach
Pseudomorphism, otherwise it is assumed that the direction does not detect broach, i.e., it is positive integer without broach pseudomorphism, the N, the NxN represents one
The rectangular area put centered on current pixel.
Preferably, described pixel characteristic value is YCbCr values or rgb value.
Preferably, described first direction be vertically oriented, horizontal direction or other directions.
Brief description of the drawings
Fig. 1 is the 3 of prior art:2 drop-down conversion processes and anti-drop-down conversion process schematic diagram;
Fig. 2 is film mode detection and the de-interlacing apparatus schematic diagram of prior art;
Fig. 3 is a kind of schematic device of the embodiment of the present invention;
Fig. 4 is that film mode optimizes schematic device in Fig. 3;
Fig. 5 is film mode detection method flow chart in Fig. 3;
Fig. 6 be described in the embodiment of the present invention close to field with interval field reference point position relationship schematic diagram;
Fig. 7 is another schematic device of the embodiment of the present invention;
Fig. 8 is the film mode optimization schematic device described in Fig. 7;
Fig. 9 is another schematic device of the embodiment of the present invention;
Figure 10 is another schematic device of the embodiment of the present invention;
Figure 11 is that film mode flase drop causes to move the broach pseudomorphism schematic diagram that interlacing region occurs;
Figure 12 is the broach detection location of pixels relation schematic diagram described in the embodiment of the present invention;
Figure 13 is the broach testing process schematic diagram described in the embodiment of the present invention;
Figure 14 is the spatial domain interpolating pixel position relationship schematic diagram described in the embodiment of the present invention.
Embodiment
The embodiment of the present invention is further elaborated below based on accompanying drawing, these are set forth to allow reader to be easier to manage
The solution present invention, and limitation of the present invention can not be considered as.
The present invention proposes a kind of local film mode detection method based on broach detection, the prediction knot to film mode
Fruit is corrected, and can correctly detect movie field and interlacing region in mixed video, and use different deinterlacing techniques
Handle respectively, so as to both recover the details of movie field, avoid producing interlacing jagged edge again.Simultaneously as film mode
Detection need to only provide prediction result, and film mode detection module and de interlacing module can be used identical input, reduce field and delay
Deposit with DDR bandwidth, saved hardware implementation cost.
Carried out due to interlaced video is considered as into film mode after instead pulling down conversion process, it may appear that jagged edge.The present invention
Basic ideas be exactly after film mode is judged as based on whole field correlation, increase local broach detection module, detect
Interlaced content region in mixed video.Again due to there is broach detection module, so film mode detection module is without providing essence
True current field testing result, predicted value only need to be provided, so as to save a caching and bandwidth.
Fig. 3 is a kind of schematic device of the embodiment of the present invention.It represents that film mode proposed by the present invention can be optimized
Module is appended to behind existing film mode detection module, you can detects current interpolation field Ft-2In interlacing region.Wherein
Mt-2It is to Ft-2The global film mode detection information of field;In the film mode optimization module that Fig. 4 is provided, first according to Mt-2
Current field and opposite field (are specifically F by informationt-1Field or Ft-3, by Mt-2Information indicate) merge framing (it is counter pull down it is transformed
Journey), then whether the detection comb pseudomorphism pixel-by-pixel in the synthetic frame, judge current regional area according to broach pseudomorphism is whether there is
It is film mode, Mt-2* it is exactly local film mode information of the output to follow-up de interlacing module.
Fig. 5 provides a kind of film mode detection method of the embodiment of the present invention, and this method comprises the following steps:
Step 1:Correlation reference model ordered set is defined, including close to field correlation reference model collection PATTERN_
FIELD={ 11010,10101,01011,10110,01101 } and interval field correlation reference model collection PATTERN_FRAME=
{ 01000,10000,00001,00010,00100 }, wherein each reference model is a 5bit number;
Step 2:The opposite field correlation of every input picture is detected, including close to field correlation and is spaced field correlation;
Step 3:The relevance detection results of the field picture of Coutinuous store five, correlation sequence is formed, by often continuous five
Correlation sequence compares with the correlation reference model defined in step 1, obtains the film mode testing result of current field.
Detection described in above-mentioned steps 2 is per field picture close to field correlation, in addition to following specific steps:
Step 2.1:With the F of inputt-1Field is current field, with its back court FtField is close to field, calculates the pending point of current field
With the absolute difference close to field reference point;
Step 2.2:Travel through current field in institute a little, the absolute difference that step 2.1 is calculated is added up, calculate close to
The absolute difference sum Sum_diff_field of field;
Step 2.3:By compared with a threshold value T1, determined close to the absolute difference sum of field current field close to field phase
Closing property testing result:If absolute difference sum is less than threshold value T1, current field is represented with stronger close to field correlation, will be related close to field
Property testing result with " 1 " represent;Otherwise represent that correlation is weaker, will be represented close to field relevance detection results with " 0 ".
Calculating current field and the absolute difference close to field reference point, specific method described in above-mentioned steps 2.1 also include:
With the F of inputt-1Field is current field, with its back court FtField is close to field, by the characteristic value of the pending point of current field
Represented, chosen close to field with currently pending point at vertically adjacent 2 points up and down, its characteristic value uses P1 respectively with P0
Represented with P2.P0, P1 and P2 position relationship are as shown in Figure 6.So the pending point of current field with close to the absolute of field reference point
Difference (represents) that calculation formula is as follows with diff_field:
Diff_field=abs (P0- (P1+P2)/2),
Wherein abs () represents the operation that takes absolute value.
Interval field correlation of the detection per field picture described in above-mentioned steps 2, in addition to following specific steps:
Step 2.4:With the F of inputt-1Field is current field, with the front court F of current fieldt-2Field and back court FtField is interval field,
Calculate the absolute difference of front court reference point and back court reference point;
Step 2.5:A little, the absolute difference that step 2.4 is calculated is added up, the counting period for institute in traversal current field
The absolute difference sum Sum_diff_frame of field;
Step 2.6:By the absolute difference sum for being spaced field compared with a threshold value, determine that the interval field of current field is related
Property testing result:If absolute difference sum is less than the threshold value, represent that the front court of current field and back court correlation are stronger, field phase will be spaced
Closing property testing result is represented with " 1 ";Otherwise represent that correlation is weaker, interval field relevance detection results are represented with " 0 ".
Calculating current field and the absolute difference close to field reference point, specific method described in above-mentioned steps 2.4 also include:
With the F of inputt-1Field is current field, with the front court F of current fieldt-2Field and back court FtFor interval field, respectively
Every being chosen in field with currently pending point P0 at vertically adjacent 2 points up and down, its characteristic value uses P1 and P2 and P3 respectively
Represented with P4.P0, P1, P2, P3 and P4 position relationship are as shown in Figure 6.So the pending point of current field with close to field reference point
Absolute difference (represent) that calculation formula is as follows with diff_frame:
Diff_frame=abs ((P1+P2)/2- (P3+P4)/2),
Wherein abs () represents the operation that takes absolute value.
Above-mentioned steps 3 also include following specific steps:
Step 3.1:Using current field close to field relevance detection results as lowest order, with above continuous four close to
Field relevance detection results form a 5bit number, i.e., close to field correlation sequence S;
Step 3.2:Using the interval field relevance detection results of current field as lowest order, the interval with above continuous four
Field relevance detection results form a 5bit number, that is, are spaced field correlation sequence Q;
Step 3.3:If meet following three conditions simultaneously, you can judge that current field is film mode:It is 1. related close to field
Property sequence S with defined in step 1 close to identical (its of i-th of pattern in the correlation reference model collection PATTERN_FIELD of field
Middle i is the mode index in PATTERN_FIELD, i=1,2 ... 5);2. it is spaced defined in field correlation sequence Q and step 1
Interval field correlation reference model collection PATTERN_FRAME in j-th of pattern identical (wherein j is in PATTERN_FRAME
Mode index, j=1,2 ... 5);3. i=j.If for example, S=10101, Q=10000, because of S=PATTERN_FIELD
(i), Q=PATTERN_FRAME (j), and i=j=2, therefore can determine that current field is film mode.If three above condition can not
Meet simultaneously, you can judge that current field is non-film mode.If for example, S=10101, Q=01000, although there is S=
PATTERN_FIELD (i), i=2, and Q=PATTERN_FRAME (j), j=1, but because of i ≠ j, therefore think that current field is non-
Film mode.
Step 3.4:Determine current field Ft-1Film mode testing result Mt-1:If current field is film mode, Mt-1=i,
Wherein i is the mode index described in step 3.3;If current field non-movie pattern, Mt-1=0.
In figure 3, film mode optimization module and de interlacing module are with the F of inputt-2It is currently pending field, Ft-2
Film mode testing result corresponding to is Mt-2, that is, by Mt-1Result after a delay.It is electricity that if current field, which belongs to,
Shadow pattern, according to Mt-2Information can determine that and Ft-2Field source is its front court F from same moving-picture framet-3Or back court Ft-1.Specifically
Comprise the following steps:
Step 1:By Mt-2As mode index, selected in the above-mentioned correlation reference model collection PATTERN_FIELD close to field
Reference model E=PATTERN_FIELD (M corresponding to takingt-2);
Step 2:F is judged according to reference model E lowest ordert-2Field will merge framing with its front court or back court:If E's
Lowest order is 1, then by Ft-2Field and its back court Ft-1Merge;If E lowest order is 0, by Ft-2Field and its front court Ft-3Merge.
For example, if Mt-2=3, then reference model E=PATTERN_FIELD (3)=01011, due to E lowest order
It is 1, then by Ft-2Field and its back court Ft-1Merge;If Mt-2=4, then reference model E=PATTERN_FIELD (3)=10110, by
In E lowest order be 0, then by Ft-2Field and its front court Ft-3Merge.
Fig. 7 is another schematic device of the embodiment of the present invention.Because broach detection module can be detected in frame out
Broach pseudomorphism, film mode detection module before it occurs flase drop, can also enter by broach detection module
Row correction, therefore can be simultaneously to film mode detection and de interlacing module input identical three field data (such as Ft,Ft-1With
Ft-2), so as to save a caching and respective bandwidth.
In the film mode optimization module that Fig. 8 is provided, that from film mode detection module is Ft-2The film mode of field
Information Mt-2, first according to existing for the film mode information between opposite field periodically, by Mt-2Predict next Ft-1Electricity
Shadow pattern information Mt-1', then according to Mt-1' information is by current field Ft-1With FtOr Ft-2Merge framing, finally detection should pixel-by-pixel
Broach region in synthetic frame, corrects global Mt-1' information is local film mode information Mt-1*, for subsequently to Ft-1Field go every
Used during row processing.
Formula is calculated as below by M in film mode prediction module use in Fig. 8t-2Predict next Ft-1Film mode letter
Cease Mt-1’:
For example, if the F from film mode detection modulet-2The film mode information M of fieldt-2For 2, then film mode
Prediction module predicts next F according to above-mentioned formulat-1Film mode information Mt-1' it is 3.
Fig. 9 and Figure 10 is other two kinds of schematic devices of the embodiment of the present invention.They represent that film mode can be optimized
Module-embedding uses into existing film mode detection module or de interlacing module, so as to realize local film mode information
Detection.
When film mode flase drop occurs, opposite field merging treatment is done in interlacing region as film mode, so as to occur
Jagged edge.Figure 11 shows the broach pseudomorphism for three kinds of angles that the moving object in frame is merged often occurs, and corresponds to respectively
(a) 135 degree of broach, (b) 90 degree of broach, (c) 45 degree of broach.Certainly the broach of other more low-angles can also be detected, detection
Broach angle is more, as a result more accurate, but cost of implementation can increase.
Figure 13 provides a kind of flow chart of the algorithm of local broach detection, by taking 90 degree of direction broach detections as an example:
First, the pixel characteristic value merged in frame in current pixel 5x5 neighborhoods is obtained.Assuming that current pixel is in frame is merged
Position coordinates be (x, y), the location of pixels relation in its 5x5 neighborhood is as shown in figure 12.Square represents to belong to current field in figure
(such as Ft-1) pixel, circle represents that opposite field is probably front court (such as F with belonging to the pixel of opposite fieldt-2) can also be back court
(Ft), this is determined according to film detection module output result.Pixel characteristic value P (x, y) can be YCbCr values or rgb value etc.,
Wherein Y represents the luminance component of pixel, and Cb and Cr represent two chromatic components of pixel respectively, and R, G, B then represent picture respectively
Red component, green component and the blue component of element.
Secondly, respectively centered on (x, y-1), (x, y) and (x, y+1), three neighborhood intermediate values of vertical direction pixel are calculated:
M_90_1=median (P (x, y-2), P (x, y-1), P (x, y))
M_90_2=median (P (x, y-1), P (x, y), P (x, y+1))
M_90_3=median (P (x, y), P (x, y+1), P (x, y+2))
Wherein, median () is to take median function.
Again, the poor absolute value of each intermediate value and each center pixel is calculated respectively:
D_90_1=abs (M_90_1-P (x, y-1))
D_90_2=abs (M_90_2-P (x, y))
D_90_3=abs (M_90_3-P (x, y+1))
Wherein, abs () is the function that takes absolute value.
Finally, by these three absolute values compared with threshold value, if any of they are more than threshold value, it is considered as the direction
Detect broach:
if(D_90_1>T_90||D_90_2>T_90||D_90_3>T_90)
Cm_90=1;
else
Cm_90=0.
The threshold value of defined when wherein T_90 is 90 degree of direction broach detections, Cm_90 indicating positions (x, y) place whether there is
90 degree of direction broach pseudomorphisms.
Broach Cleaning Principle on other directions (such as 45 degree and 135 degree) is similar with said process.Finally integrate each side
Upward testing result, as long as detecting broach on any one direction, the region where deciding that current pixel occurs
Broach, and be marked as non-movie pattern, i.e. Cm (x, y)=1;Otherwise Cm (x, y)=0.
According to the local broach pseudomorphism indicated value Cm (x, y) calculated, when carrying out de interlacing processing, if Cm (x, y)=
0, result line by line is obtained using frame method is merged, so as to maintain the details of movie field;If Cm (x, y)=1 on the contrary, use is general
Logical deinterlacing technique (such as spatial domain interpolation or Motion Adaptive method) obtains result line by line, so as to avoid broach pseudomorphism
Occur.
In one example, the common deinterlacing technique in the embodiment of the present invention uses a kind of spatial domain interpolation method, including such as
Lower specific steps:
Step 1:With the F of inputt-2Field is current field, and the location of pixels in its interpolation point (coordinate is (x, y)) neighborhood closes
System is as shown in figure 14.Circle represents the pixel for belonging to current field in figure, and cross then represents the pixel of interpolation.Choose with it is to be inserted
Value puts adjacent in vertical direction 2 points up and down, it is assumed that its characteristic value is respectively P (x, y-1) and P (x, y+1);
Step 2:Ask for the characteristic value P (x, y) of interpolation point:
P (x, y)=(P (x, y-1)+P (x, y+1))/2;
Step 3:After the characteristic value that all interpolation points are calculated by step 1 and step 2, an interpolation field figure will be obtained
Picture, the interpolation field picture is merged into framing with current field, produces result line by line.
Advantage of the invention is that:1) movie contents region and TV interlaced content region in mixed video are can detect that,
So that de interlacing module can distinguish processing;2) Double Data Rate synchronous DRAM DDR cachings and bandwidth resources are saved.
It will be appreciated by those of skill in the art that each exemplary unit/mould described with reference to the embodiments described herein
Block, it can be realized with electronic hardware, computer software or the combination of the two, can in order to clearly demonstrate hardware and software
Interchangeability, the composition of each example is generally described according to function in the above description.These functions are actually with hardware
Or software mode performs, application-specific and design constraint depending on technical scheme.Professional and technical personnel can be right
Described function is realized in each specific application using distinct methods, but this is realized it is not considered that beyond the present invention
Scope.
It should be noted last that the above embodiments are merely illustrative of the technical solutions of the present invention and it is unrestricted.Although ginseng
The present invention is described in detail according to embodiment, it will be appreciated by those skilled in the art that being carried out to technical scheme
Modification or equivalent substitution, without departure from the spirit and scope of technical solution of the present invention, it all should cover the right in the present invention
Among claimed range.
Claims (8)
1. a kind of video detection and processing method, it is characterised in that:
Detect whether current field is film field by calculating the overall relevancy of adjacent field picture, the adjacent field picture it is whole
Body correlation is included close to field correlation and interval field correlation;
It is next according to film field testing result prediction before based on periodicity existing for the film mode information between opposite field
Whether field is film field;
Under conditions of current field is non-movie field, Motion Adaptive method or spatial domain interpolation method is taken to calculate interpolation
Frame, the frame of video using the interpolated frame as reduction;
Under conditions of current field is film field, current field and opposite field are merged into synthetic frame, in the part of the synthetic frame
Detection comb pseudomorphism pixel-by-pixel in region;
If not detecting broach pseudomorphism in the regional area, the regional area is judged for film-mode regions,
And using the synthetic frame the regional area value as reduction frame of video the regional area result;
If detecting local broach pseudomorphism in the regional area, judge the regional area for non-movie Mode Areas
Domain, row interpolation is entered in the regional area using Motion Adaptive method or spatial domain interpolation method, and interpolation result is made
For reduction frame of video the regional area result.
2. video detection according to claim 1 and processing method, it is characterised in that:The office in the synthetic frame
The method of portion region detection comb pseudomorphism pixel-by-pixel includes:Obtain the pixel characteristic value in current pixel NxN neighborhoods in merging frame;
Calculate current pixel the neighborhood territory pixel of first direction three pixel characteristic value intermediate value, calculate in a first direction with current pixel most
The pixel characteristic value intermediate value of the adjacent respective neighborhood territory pixel of first direction three of two pixels;Each intermediate value and each center are calculated respectively
The poor absolute value of the pixel characteristic value of pixel;By these three absolute values compared with threshold value, if any of they are more than
Threshold value, it is believed that first direction detects broach, that is, has broach pseudomorphism, otherwise it is assumed that the direction does not detect broach, i.e., without
Broach pseudomorphism, the N are positive integers, and the NxN represents a rectangular area put centered on current pixel.
3. video detection according to claim 2 and processing method, it is characterised in that:Described pixel characteristic value is
YCbCr values or rgb value.
4. video detection and processing method according to Claims 2 or 3, it is characterised in that:Described first direction is vertical
Nogata is to, horizontal direction or other directions.
5. a kind of video detection and processing unit, it is characterised in that:
Including film mode detection module, film mode optimization module and de interlacing module, the film mode optimization module bag
Film mode prediction module is included, generation merges frame module and broach detection module, wherein
The film mode detection module, for whether detecting current field by calculating the overall relevancy of adjacent field picture
For film field when, testing result is sent to the film mode prediction module, the overall relevancy bag of the adjacent field picture
Include close to field correlation and interval field correlation;
The film mode prediction module, for based on existing for the film mode information between opposite field periodically, according to preceding
State film field testing result and predict whether next field is film field, and the prediction result is sent to the generation and merges frame mould
Block;
The generation merges frame module, for when receiving film field prediction result, current field and opposite field to be merged into synthesis
Frame, and the synthetic frame is sent to the broach detection module;
The broach detection module, for the detection comb pseudomorphism pixel-by-pixel in the regional area of the synthetic frame, if in institute
State and broach pseudomorphism is not detected in regional area, then judge the regional area for film-mode regions, and by the conjunction
Framing the regional area value as reduction frame of video the regional area result, if in the regional area
In detect local broach pseudomorphism, then judge the regional area for non-movie mode region, and described in result of determination notified
De interlacing module;
The de interlacing module, for when receiving the prediction result of non-movie field, taking Motion Adaptive method or spatial domain
Interpolation method calculates interpolated frame, the frame of video using the interpolated frame as reduction, and is receiving non-movie mode region
During result of determination, row interpolation is entered in the regional area using Motion Adaptive method or spatial domain interpolation method, and will insert
Be worth result as reduce frame of video the regional area result.
6. video detection according to claim 5 and processing unit, it is characterised in that:The broach detection module is described
In the regional area of synthetic frame pixel-by-pixel detection comb pseudomorphism the step of include:Obtain and merge in frame in current pixel NxN neighborhoods
Pixel characteristic value;The pixel characteristic value intermediate value of the neighborhood territory pixel of first direction three of current pixel is calculated, is calculated in a first direction
The pixel characteristic value intermediate value of the upper and most adjacent current pixel respective neighborhood territory pixel of first direction three of two pixels;Calculate respectively
The poor absolute value of each intermediate value and the pixel characteristic value of each center pixel;By these three absolute values compared with threshold value, if it
Any of be more than threshold value, it is believed that first direction detects broach, that is, has broach pseudomorphism, otherwise it is assumed that the direction is not examined
Broach is measured, i.e., is positive integer without broach pseudomorphism, the N, the NxN represents a rectangle region put centered on current pixel
Domain.
7. video detection according to claim 6 and processing unit, it is characterised in that:Described pixel characteristic value is
YCbCr values or rgb value.
8. video detection and processing unit according to claim 6 or 7, it is characterised in that:Described first direction is vertical
Nogata is to, horizontal direction or other directions.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510071223.1A CN104580978B (en) | 2015-02-11 | 2015-02-11 | A kind of video detection and processing method, device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510071223.1A CN104580978B (en) | 2015-02-11 | 2015-02-11 | A kind of video detection and processing method, device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104580978A CN104580978A (en) | 2015-04-29 |
CN104580978B true CN104580978B (en) | 2017-12-22 |
Family
ID=53096060
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510071223.1A Active CN104580978B (en) | 2015-02-11 | 2015-02-11 | A kind of video detection and processing method, device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104580978B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105227887B (en) * | 2015-08-26 | 2018-08-21 | 华为技术有限公司 | A kind of drop-down film source processing method and processing device |
CN106488312B (en) * | 2015-08-31 | 2019-04-30 | 展讯通信(上海)有限公司 | The detection method and device of video source |
CN105898179A (en) * | 2015-12-14 | 2016-08-24 | 乐视云计算有限公司 | Deinterlace method and device for interlaced video |
CN111476803B (en) * | 2020-04-14 | 2022-08-26 | 展讯通信(上海)有限公司 | Video processing method and related equipment |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1937753A (en) * | 2006-10-25 | 2007-03-28 | 北京中星微电子有限公司 | Foldable field sequence detecting method and digital video deinterleaving device and method |
CN101483790A (en) * | 2008-12-22 | 2009-07-15 | 四川虹微技术有限公司 | Movie mode video signal detection method |
CN101729841A (en) * | 2008-10-27 | 2010-06-09 | 富士通株式会社 | Comb-like pseudoscopic image detection apparatus and method |
CN103826082A (en) * | 2014-01-21 | 2014-05-28 | 华为技术有限公司 | Video processing method and device |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8471962B2 (en) * | 2011-06-30 | 2013-06-25 | Stmicroelectronics Asia Pacific Pte Ltd. | Apparatus and method for local video detector for mixed cadence sequence |
-
2015
- 2015-02-11 CN CN201510071223.1A patent/CN104580978B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1937753A (en) * | 2006-10-25 | 2007-03-28 | 北京中星微电子有限公司 | Foldable field sequence detecting method and digital video deinterleaving device and method |
CN101729841A (en) * | 2008-10-27 | 2010-06-09 | 富士通株式会社 | Comb-like pseudoscopic image detection apparatus and method |
CN101483790A (en) * | 2008-12-22 | 2009-07-15 | 四川虹微技术有限公司 | Movie mode video signal detection method |
CN103826082A (en) * | 2014-01-21 | 2014-05-28 | 华为技术有限公司 | Video processing method and device |
Also Published As
Publication number | Publication date |
---|---|
CN104580978A (en) | 2015-04-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106210767B (en) | Video frame rate up-conversion method and system for intelligently improving motion fluency | |
CN102055947B (en) | Frame rate convertor using motion estimation and pixel interpolation | |
CN104580978B (en) | A kind of video detection and processing method, device | |
US6563550B1 (en) | Detection of progressive frames in a video field sequence | |
TW494686B (en) | A system and method for motion compensation of image planes in color sequential displays | |
US9148622B2 (en) | Halo reduction in frame-rate-conversion using hybrid bi-directional motion vectors for occlusion/disocclusion detection | |
CN104219533B (en) | A kind of bi-directional motion estimation method and up-conversion method of video frame rate and system | |
US20100328529A1 (en) | Still subtitle detection apparatus, visual display equipment, and image processing method | |
US20090208123A1 (en) | Enhanced video processing using motion vector data | |
US20110211111A1 (en) | Interpolation frame generating apparatus and method | |
JPH08307820A (en) | System and method for generating high image quality still picture from interlaced video | |
CN101600061A (en) | De-interlaced method of video motion-adaptive and device | |
CN103402098A (en) | Video frame interpolation method based on image interpolation | |
JP5669523B2 (en) | Frame interpolation apparatus and method, program, and recording medium | |
CN102509311B (en) | Motion detection method and device | |
CN102447870A (en) | Detection method for static objects and motion compensation device | |
US20090028391A1 (en) | Motion detecting method and apparatus thereof | |
US9659353B2 (en) | Object speed weighted motion compensated interpolation | |
JP2009207137A (en) | Method and system of processing video signal, and computer-readable storage medium | |
CN111294545B (en) | Image data interpolation method and device, storage medium and terminal | |
CN101282415B (en) | Motion adaptive image processing | |
US20160366366A1 (en) | Frame rate conversion system | |
CN1312924C (en) | Texture information based video image motion detecting method | |
KR100931110B1 (en) | Deinterlacing apparatus and method using fuzzy rule-based edge recovery algorithm | |
CN105898179A (en) | Deinterlace method and device for interlaced video |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |