CN104469289B - Video broadcasting method and device - Google Patents
Video broadcasting method and device Download PDFInfo
- Publication number
- CN104469289B CN104469289B CN201410662504.XA CN201410662504A CN104469289B CN 104469289 B CN104469289 B CN 104469289B CN 201410662504 A CN201410662504 A CN 201410662504A CN 104469289 B CN104469289 B CN 104469289B
- Authority
- CN
- China
- Prior art keywords
- image
- adjacent
- field pictures
- video
- video data
- 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
Landscapes
- Studio Devices (AREA)
- Studio Circuits (AREA)
Abstract
The invention discloses a kind of video broadcasting method and devices.Wherein, video broadcasting method includes: load video data to be played, and video data includes the image data being continuously shot;Target image is detected from video data, target image is the identical image of content of image adjacent thereto;The corresponding image data of target image is filtered, obtains filtering out the video data after target image;And it plays and filters out the video data after target image.Through the invention, it solves the problems, such as that the broadcasting of monitor video in the prior art takes a long time, has achieved the effect that reduce the time that monitor video plays.And then quick browse video is achieved the effect that.
Description
Technical field
The present invention relates to data processing fields, in particular to a kind of video broadcasting method and device.
Background technique
Video refers to is captured a series of static images in a manner of electric signal, is noted down, and is handled, and is stored, transmission, and again
Existing various technologies.Continuous image change it is per second more than more than 24 frames (frame) picture when, according to persistence of vision principle, people
Eye can not distinguish the tableaux of single width;Smooth continuous visual effect is appeared to be, picture continuous in this way is called video.
Video monitoring system generally has monitoring point is more, fix laying, camera quantity is more, monitoring period is long (to acquire number
According to time be often up to several days or tens days), data volume is big the features such as, therefore video monitoring system storage must support great Rong
Amount, and capacity has high scalability, meets the needs of long-time large-capacity video image storage.
Inventors have found that staff is when checking monitoring is recorded a video, it usually needs from the beginning in playing video data
To every one-frame video data, and often there is a large amount of repeated data in video data, this will make these video playings time-consuming
It is longer, the plenty of time of staff's checking monitoring video is wasted, is then easy to ignore in monitor video by the way of F.F. to clap
The slight change for the image taken the photograph.
Aiming at the problem that broadcasting of monitor video in the prior art takes a long time, effective solution side is not yet proposed at present
Case.
Summary of the invention
The main purpose of the present invention is to provide a kind of video broadcasting method and devices, to solve monitoring view in the prior art
The broadcasting of frequency take a long time the problem of.
To achieve the goals above, according to an aspect of an embodiment of the present invention, a kind of video broadcasting method is provided.Root
It include: load video data to be played according to video broadcasting method of the invention, the video data includes the figure being continuously shot
As data;Target image is detected from the video data, the target image is that the content of image adjacent thereto is identical
Image;The corresponding image data of the target image is filtered, obtains filtering out the video data after the target image;
And the video data after the target image is filtered out described in playing.
It further, include: by two frames adjacent in the video data from target image is detected in the video data
Image compares, and obtains comparing result;The picture material for judging the adjacent two field pictures according to the comparing result is
It is no identical;If it is judged that the picture material of the adjacent two field pictures is identical, then it will be in the adjacent two field pictures
One frame image is as the target image.
Further, two field pictures adjacent in the video data are compared, obtaining comparing result includes: successively
The pixel for comparing same position in the adjacent two field pictures, obtains pixel comparing result, judged according to comparing result described in
The whether identical picture material of adjacent two field pictures includes: to judge the two adjacent frame figures according to the pixel comparing result
As whether the pixel of upper same position all identical, wherein if it is judged that in the adjacent two field pictures same position picture
Element is all identical, it is determined that the picture material of the adjacent two field pictures is identical.
Further, two field pictures adjacent in the video data are compared, obtaining comparing result includes: to utilize
Perceptual hash algorithm calculates the cryptographic Hash of image in the video data;The cryptographic Hash for comparing the adjacent two field pictures, obtains
To cryptographic Hash comparing result, according to comparing result judge the picture material of the adjacent two field pictures it is whether identical include: root
Judge whether the cryptographic Hash of the adjacent two field pictures is identical according to the cryptographic Hash comparing result, wherein if it is judged that institute
The cryptographic Hash for stating adjacent two field pictures is identical, it is determined that the picture material of the adjacent two field pictures is identical.
It further, include: to the view using the cryptographic Hash that perceptual hash algorithm calculates image in the video data
Frequency image in is pre-processed, the image that obtains that treated;Calculate the average gray of treated the image;And
The cryptographic Hash is calculated using the average gray.
To achieve the goals above, according to another aspect of an embodiment of the present invention, a kind of video play device is provided.Root
It include: loading unit according to video play device of the invention, for loading video data to be played, the video data includes
The image data being continuously shot;Detection unit, for detecting target image from the video data, the target image be with
The identical image of content of its adjacent image;Filter element, for being carried out to the corresponding image data of the target image
Filter, obtains filtering out the video data after the target image;And broadcast unit, described the target is filtered out for playing
Video data after image.
Further, the detection unit includes: comparing subunit, for by two frame figures adjacent in the video data
As comparing, comparing result is obtained;Judgment sub-unit, for judging the adjacent two field pictures according to the comparing result
Picture material it is whether identical;And selection subelement, for if it is judged that the adjacent two field pictures picture material
It is identical, then using the frame image in the adjacent two field pictures as the target image.
Further, the comparing subunit includes: the first comparison module, for the successively two adjacent frame figures
As the pixel of upper same position, pixel comparing result is obtained, the judgment sub-unit includes: first judgment module, is used for basis
The pixel comparing result judges whether the pixel of same position in the adjacent two field pictures is all identical, wherein if sentenced
The pixel of same position is all identical in the disconnected adjacent two field pictures out, it is determined that in the image of the adjacent two field pictures
Hold identical.
Further, the comparing subunit includes: computing module, for calculating the video using perceptual hash algorithm
The cryptographic Hash of image in data;Second comparison module obtains cryptographic Hash for the cryptographic Hash of the adjacent two field pictures
Comparing result, the judgment sub-unit include: the second judgment module, for judging the phase according to the cryptographic Hash comparing result
Whether the cryptographic Hash of adjacent two field pictures is identical, wherein if it is judged that the cryptographic Hash of the adjacent two field pictures is identical, then
Determine that the picture material of the adjacent two field pictures is identical.
Further, the computing module includes: pretreatment submodule, pre- for carrying out to image in the video data
Processing, the image that obtains that treated;First computational submodule, for calculating the average gray of treated the image;With
And second computational submodule, for the cryptographic Hash to be calculated using the average gray.
According to embodiments of the present invention, by loading video data to be played, target image, mesh are detected from video data
Logo image is the identical image of content of image adjacent thereto, is filtered, obtains to the corresponding image data of target image
Video data after filtering out target image, broadcasting filters out the video data after target image, due to skipping in playing process
The duplicate image data of content avoids broadcasting from largely repeating identical image, solves the broadcasting of monitor video in the prior art
Take a long time the problem of, achieved the effect that reduce monitor video play time.And then quick browse video is reached
Effect.
Detailed description of the invention
The attached drawing constituted part of this application is used to provide further understanding of the present invention, schematic reality of the invention
It applies example and its explanation is used to explain the present invention, do not constitute improper limitations of the present invention.In the accompanying drawings:
Fig. 1 is the flow chart of video broadcasting method according to an embodiment of the present invention;
Fig. 2 is the flow chart of preferred video broadcasting method according to embodiments of the present invention;
Fig. 3 is the flow chart of another preferred video broadcasting method according to embodiments of the present invention;
Fig. 4 is the schematic diagram of video play device according to an embodiment of the present invention;And
Fig. 5 is the schematic diagram of preferred video play device according to embodiments of the present invention.
Specific embodiment
It should be noted that in the absence of conflict, the features in the embodiments and the embodiments of the present application can phase
Mutually combination.The present invention will be described in detail below with reference to the accompanying drawings and embodiments.
In order to enable those skilled in the art to better understand the solution of the present invention, below in conjunction in the embodiment of the present invention
Attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is only
The embodiment of a part of the invention, instead of all the embodiments.Based on the embodiments of the present invention, ordinary skill people
The model that the present invention protects all should belong in member's every other embodiment obtained without making creative work
It encloses.
It should be noted that description and claims of this specification and term " first " in above-mentioned attached drawing, "
Two " etc. be to be used to distinguish similar objects, without being used to describe a particular order or precedence order.It should be understood that using in this way
Data be interchangeable under appropriate circumstances, so as to the embodiment of the present invention described herein.In addition, term " includes " and " tool
Have " and their any deformation, it is intended that cover it is non-exclusive include, for example, containing a series of steps or units
Process, method, system, product or equipment those of are not necessarily limited to be clearly listed step or unit, but may include without clear
Other step or units listing to Chu or intrinsic for these process, methods, product or equipment.
According to embodiments of the present invention, a kind of video broadcasting method is provided.The video broadcasting method may operate in broadcasting
In the equipment such as device.
Fig. 1 is the flow chart of video broadcasting method according to an embodiment of the present invention.As shown in Figure 1, the video broadcasting method
May include:
Step S102 loads video data to be played.
Video data may include the image data being continuously shot by video camera.Such as in monitor video, video camera connects
The video image of continuous shooting is the monitor video image obtained within one or more periods, and video image here can be
Without the video data of time interval within one or more periods.When staff checks this kind of monitor video, Ke Yixiang
Player input control order after player receives control command, starts to load video data to be played, in order to show
It plays.
Step S104, detects target image from video data, and target image can be the content of image adjacent thereto
Identical image.
The wherein frame image for such as choosing video camera shooting is saved, and records the shooting time of the image, will be chosen
The adjacent image of this frame image be compared, if the content of its adjacent image is identical as it, which is made
For target image.If the content of its adjacent image is not identical as it, which is not present target image.
Such as the video data of load includes continuous image A, image B and image C, wherein image A is to choose wherein
One frame image, here it is possible to record the shooting time of image A, image B is the adjacent image of image A, by this two frames adjacent image
It is compared, if image B is identical as the picture material of image A, image B can be set as target image.Image C be and figure
As the adjacent image of B, image C is compared with image B, if image C is identical as the picture material of image B, image C is
Target image;If image C is not identical as the picture material of image B, image C is not target image.
Step S106 is filtered the corresponding image data of target image, obtains filtering out the video after target image
Data.
Step S108, broadcasting filter out the video data after target image.
The corresponding image data of target image is filtered out, i.e., filters out the corresponding image data of image B in the example above, obtains
Image A and image C are arrived, skip pictures B plays image A and image C.Wherein, two adjacent images be according to same sequence into
Row compares.In this way, what is obtained is the different view of continuous picture material after filtering out the corresponding video data of target image
Frequency evidence, the broadcasting of repetition video data can be greatly reduced by playing the video data, to reduce the time-consuming of video playing.
According to embodiments of the present invention, by loading video data to be played, target image, mesh are detected from video data
Logo image is the identical image of content of image adjacent thereto, is filtered, obtains to the corresponding image data of target image
Video data after filtering out target image, broadcasting filters out the video data after target image, due to skipping in playing process
The duplicate image data of content avoids broadcasting from largely repeating identical image, solves the broadcasting of monitor video in the prior art
Take a long time the problem of, achieved the effect that reduce monitor video play time.And then quick browse video is reached
Effect.
Fig. 2 is the flow chart of preferred video broadcasting method according to embodiments of the present invention.The video playing side of the embodiment
Method can be a kind of preferred embodiment of the video broadcasting method of above-described embodiment.As shown in Fig. 2, the video broadcasting method can
To be the improvement to video broadcasting method shown in FIG. 1, specifically, detecting target image from video data may include:
Two field pictures adjacent in video data are compared, obtain comparing result by step S202.
Two field pictures adjacent in video data are compared, can be and the pixel of adjacent two field pictures is carried out pair
Than can also be that the cryptographic Hash to adjacent two field pictures compares.
In the video data to be played of load, the first frame image in adjacent two field pictures can be chosen as base
Quasi- image, another frame image are the adjacent next frame image of benchmark image, then this two frames adjacent image are carried out picture material
Compare, obtains comparing result.Wherein, two frame adjacent images are compared according to same sequence.
Step S204 judges whether the picture material of adjacent two field pictures is identical according to comparing result.
Step S206, if it is judged that the picture material of adjacent two field pictures is identical, then it will be in adjacent two field pictures
A frame image as target image.
Target image can be any frame image in adjacent two field pictures.In the presence of the image obtained due to video capture
Between sequence therefore can be using the image shot after in the adjacent image of identical two frame of content as target image.For example, will
The next frame image of the benchmark image is compared with the benchmark image as benchmark image, judges base by the image first shot
Whether the picture material of quasi- image next frame image adjacent thereto is identical, if it is judged that benchmark image next frame figure adjacent thereto
The picture material of picture is identical, then using the next frame image as target image.
If it is judged that the picture material of benchmark image next frame image adjacent thereto is not identical, then the next frame figure is saved
Picture.
Such as the video data of load includes continuous image A, image B and image C, wherein image A is the first of shooting
Frame image, using image A as benchmark image, image B is the adjacent image of image A, this two frames adjacent image is compared, such as
Fruit image B is identical as the picture material of image A, then image B can be set as target image.Image C is the neighbor map with image B
Image C is compared by picture with image B, if image C is identical as the picture material of image B, image C is target image;Such as
Fruit image C is not identical as the picture material of image B, then image C is not target image, meanwhile, using image C as benchmark image.
It optionally,, can be with when the next frame image for determining benchmark image is target image in video display process
The image is directly skipped, using the next frame image of target image as the adjacent image of benchmark image, recycles benchmark image
Judge whether content repeats the image.For example, in the example above, it, then can be with skip pictures after determining image B is target image
B can then compare image C and image A at this point, image A is adjacent with image C.
A large amount of identical invalid video image data can be effectively detected by the above method, play changed figure
As information.
Preferably, in embodiments of the present invention, which can also include:
Step S4, successively in more adjacent two field pictures same position pixel, obtain pixel comparing result.
Step S4, which can be, " compares two field pictures adjacent in video data, obtain comparing result " step
Further improvement in the video data of load, the first frame image conduct in adjacent two field pictures specifically can be chosen
Benchmark image, another frame image are the adjacent next frame image of benchmark image, then this two adjacent images are carried out phase on image
With the comparison of the pixel of position, comparing result is obtained.Pixel is the basic unit that image is shown, by comparing image same position
Pixel, comparing result can be accurately obtained.
Step S6 judges whether the pixel of same position in adjacent two field pictures is all identical according to pixel comparing result.
Step S6 can be to step " judging whether the picture material of adjacent two field pictures is identical according to comparing result "
Further improvement specifically according to pixel comparing result, judge same position on benchmark image next frame image adjacent thereto
Pixel it is whether identical.
Step S8, if it is judged that the pixel of same position is all identical in adjacent two field pictures, it is determined that adjacent two
The picture material of frame image is identical.
If it is judged that benchmark image next frame image adjacent thereto is all identical in the pixel of same position, it is determined that adjacent
This two field pictures picture material it is identical.
If it is judged that benchmark image next frame image adjacent thereto is not all identical in the pixel of same position, it is determined that phase
The picture material of this adjacent two field pictures is not identical.
Such as the video of load includes continuous image A, image B and image C, wherein image A is the first frame figure of shooting
Picture, using image A as benchmark image, image B is the adjacent image of image A, by the pixel of this two frames adjacent image same position
It is compared, if the pixel of image B and image A same position is all identical, image B can be set as target image.Image C
For the adjacent image with image B, image C is compared with the pixel of image B same position, if image C is identical as image B
The pixel of position is identical, then image C is target image;If image C is not all identical as the pixel of image B same position, scheme
As C is not target image, meanwhile, using image C as benchmark image.
A large amount of identical invalid video image data can be effectively filtered out by the above method, are changed to play
Video data.
Preferably, in embodiments of the present invention, which can also include:
Step S10 calculates the cryptographic Hash of image in video data using perceptual hash algorithm.
Step S12, the cryptographic Hash of more adjacent two field pictures obtain cryptographic Hash comparing result.
Step S10 and step S12, which can be, " to be compared two field pictures adjacent in video data, obtains to step
The further improvement of comparing result ".
Specifically, in the video data to be played of load, the first frame figure in adjacent two field pictures can be chosen
As being used as benchmark image, another frame image is the adjacent next frame image of benchmark image, then by the Hash of this two adjacent images
Value is compared, and obtains comparing result.Comparing result can accurately and quickly be obtained using Hash perception algorithm.
Step S14 judges whether the cryptographic Hash of adjacent two field pictures is identical according to cryptographic Hash comparing result.
Judged according to comparing result the picture material of adjacent two field pictures it is whether identical can also include: according to cryptographic Hash
Comparing result judges whether the cryptographic Hash of adjacent two field pictures is identical.
Step S16, if it is judged that the cryptographic Hash of adjacent two field pictures is identical, it is determined that the figure of adjacent two field pictures
As content is identical.
If it is judged that the cryptographic Hash of benchmark image next frame image adjacent thereto is all identical, it is determined that this adjacent two frame
The picture material of image is identical.
If it is judged that the cryptographic Hash of benchmark image next frame image adjacent thereto is not identical, it is determined that this adjacent two frame
The picture material of image is not identical.
Preferably, in embodiments of the present invention, the step in video broadcasting method " cryptographic Hash of image in video data "
May include:
Step S16 pre-processes image in video data, the image that obtains that treated.
The pretreatment can be that the video image that will acquire reduces the size and is converted to gray level image.For example, picture is pressed
8 × 8 size is narrowed down to according to same method, in total 64 pixels.Using this method, the details of picture can be removed, is only protected
Stay the essential informations such as structure, light and shade.
Simplify color and the picture after diminution is switched into 64 grades of gray scales.That is, all pixels point only has 64 kinds of colors in total.
Step S18, the average gray of the image after calculation processing.
Calculate the average gray of all 64 pixels in pretreated video image.
Cryptographic Hash is calculated using average gray in step S20.
The gray scale of each pixel is compared by the gray scale of compared pixels with average value.More than or equal to average value, note
It is 1;Less than average value, it is denoted as 0.The comparison of the cryptographic Hash of adjacent two field pictures is carried out according still further to same sequence.
It by the comparison result of previous step, combines, just constitutes one 64 integers, here it is this pictures
Fingerprint.Combined order is not important, as long as guaranteeing that all pictures all use same order.Due to same monitoring camera
Picture size, the ratio of machine output are consistent.It is all according to identical side in the image processing process such as minification, simplified color
Method is handled.Therefore influence of the entire treatment process to cryptographic Hash can be ignored.
Using the first frame image of load as benchmark image, the Hash of first frame image is obtained by the above perceptual hash algorithm
Value, calculates the cryptographic Hash of adjacent next frame picture.The Kazakhstan of benchmark picture and adjacent next frame image in that same order
Uncommon value.
If comparison result shows that every data value is all identical, picture and the reference base picture phase of adjacent next frame
Together, this picture is directly abandoned not save.The image cryptographic Hash of the adjacent next frame after abandoning image is calculated again, and by above-mentioned
Method is compared calculating.
If comparison result shows that the value in data bit is different, then it is assumed that the picture and reference base picture of adjacent next frame
Difference then using the picture of adjacent next frame as reference base picture, and saves original picture.
Such as the video of load includes continuous image A, image B and image C, wherein image A is the first frame figure of shooting
Picture, using image A as benchmark image, image B is the adjacent image of image A, and the cryptographic Hash of this two frames adjacent image is compared
Compared with image B being set as target image if image B is identical as image A cryptographic Hash.Image C is adjacent with image B
Image C is compared by image with the cryptographic Hash of image B, if image C is identical as the cryptographic Hash of image B, image C is mesh
Logo image;If image C is not identical as the cryptographic Hash of image B, image C is not target image, meanwhile, using image C as base
Quasi- image.
Fig. 3 is the flow chart of another preferred video broadcasting method according to embodiments of the present invention.As shown in figure 3, the video
The process of playback method may include:
Step S302 chooses the first frame image of load as benchmark image, and calculates the cryptographic Hash of the image.
Step S304 calculates the cryptographic Hash of next frame image adjacent thereto.
Step S306 compares first frame image and each data bit of next frame image adjacent thereto according to same sequence
Cryptographic Hash.
Step S308 judges that this two field pictures content is identical, filters out the next frame image if comparing result is identical
Corresponding image data, the i.e. image are target image.Then S304 is returned to step.
Calculate target image adjacent next frame image cryptographic Hash, then with the previously stored image of next frame image
Cryptographic Hash be compared, comparative approach is the same, and details are not described herein.Wherein, the comparison of two adjacent images is according to identical
Sequence is compared.
Step S310 judges that this two field pictures content is not identical, if comparing result is not identical with the next frame image
As benchmark image, returns again to and execute step 304.
Through the embodiment of the present invention, a large amount of identical invalid image datas can effectively be skipped by the above method, broadcast
Changed video data is put, achievees the effect that quick browse video.
The embodiment of the invention also provides a kind of video play devices.The device can realize it by equipment such as players
Function.It should be noted that the video play device of the embodiment of the present invention can be used for executing provided by the embodiment of the present invention
Video broadcasting method, the video broadcasting method of the embodiment of the present invention can also through the embodiment of the present invention provided by video playing
Device executes.
Fig. 4 is the schematic diagram of video play device according to an embodiment of the present invention.As shown in figure 4, the video play device
It may include: loading unit 10, detection unit 20, filter element 30 and broadcast unit 40.
For loading unit 10 for loading video data to be played, video data includes the image data being continuously shot.
Video data may include the image data being continuously shot by video camera.Such as in monitor video, video camera connects
The video image of continuous shooting is the monitor video image obtained within one or more periods, and video image here can be
Without the video data of time interval within one or more periods.When staff checks this kind of monitor video, Ke Yixiang
Player input control order after player receives control command, starts to load video data to be played, in order to show
It plays.
Detection unit 20 is the content of image adjacent thereto for detecting target image, target image from video data
Identical image.
The wherein frame image for such as choosing video camera shooting is saved, and records the shooting time of the image, will be chosen
The adjacent image of this frame image be compared, if the content of its adjacent image is identical as it, which is made
For target image.If the content of its adjacent image is not identical as it, which is not present target image.
Such as the video data of load includes continuous image A, image B and image C, wherein image A is to choose wherein
One frame image, here it is possible to record the shooting time of image A, image B is the adjacent image of image A, by this two frames adjacent image
It is compared, if image B is identical as the picture material of image A, image B can be set as target image.Image C be and figure
As the adjacent image of B, image C is compared with image B, if image C is identical as the picture material of image B, image C is
Target image;If image C is not identical as the picture material of image B, image C is not target image.
Filter element 30 obtains after filtering out target image for being filtered to the corresponding image data of target image
Video data.
Broadcast unit 40 is for playing the video data after filtering out target image.
The corresponding image data of target image is filtered out, i.e., filters out the corresponding image data of image B in the example above, obtains
Image A and image C are arrived, skip pictures B plays image A and image C.Wherein, two adjacent images be according to same sequence into
Row compares.In this way, what is obtained is the different view of continuous picture material after filtering out the corresponding video data of target image
Frequency evidence, the broadcasting of repetition video data can be greatly reduced by playing the video data, to reduce the time-consuming of video playing.
Through the embodiment of the present invention, by loading video data to be played, target image, mesh are detected from video data
Logo image is the identical image of content of image adjacent thereto, is filtered, obtains to the corresponding image data of target image
Video data after filtering out target image, broadcasting filters out the video data after target image, due to skipping in playing process
The duplicate image data of content avoids broadcasting from largely repeating identical image, solves the broadcasting of monitor video in the prior art
Take a long time the problem of, achieved the effect that reduce monitor video play time.And then quick browse video is reached
Effect.
Fig. 5 is the schematic diagram of preferred video play device according to embodiments of the present invention.The video playing of the embodiment fills
Set a kind of preferred embodiment for the video play device that can be above-described embodiment.As shown in figure 5, the video play device
In, detection unit 20 may include: comparing subunit 201, judgment sub-unit 202 and selection subelement 203.
Comparing subunit 201 obtains comparing result for comparing two field pictures adjacent in video data.
Two field pictures adjacent in video data are compared, can be and the pixel of adjacent two field pictures is carried out pair
Than can also be that the cryptographic Hash to adjacent two field pictures compares.
In the video data to be played of load, the first frame image in adjacent two field pictures can be chosen as base
Quasi- image, another frame image are the adjacent next frame image of benchmark image, then this two frames adjacent image are carried out picture material
Compare, obtains comparing result.Wherein, two frame adjacent images are compared according to same sequence.
Judgment sub-unit 202 is for judging whether the picture material of adjacent two field pictures is identical according to comparing result.
Subelement 203 is selected to be used for if it is judged that the picture material of adjacent two field pictures is identical, then by adjacent two
A frame image in frame image is as target image.
Target image can be any frame image in adjacent two field pictures.In the presence of the image obtained due to video capture
Between sequence therefore can be using the image shot after in the adjacent image of identical two frame of content as target image.For example, will
The next frame image of the benchmark image is compared with the benchmark image as benchmark image, judges base by the image first shot
Whether the picture material of quasi- image next frame image adjacent thereto is identical, if it is judged that benchmark image next frame figure adjacent thereto
The picture material of picture is identical, then using the next frame image as target image.
If it is judged that the picture material of benchmark image next frame image adjacent thereto is not identical, then the next frame figure is saved
Picture.
Such as the video data of load includes continuous image A, image B and image C, wherein image A is the first of shooting
Frame image, using image A as benchmark image, image B is the adjacent image of image A, this two frames adjacent image is compared, such as
Fruit image B is identical as the picture material of image A, then image B can be set as target image.Image C is the neighbor map with image B
Image C is compared by picture with image B, if image C is identical as the picture material of image B, image C is target image;Such as
Fruit image C is not identical as the picture material of image B, then image C is not target image, meanwhile, using image C as benchmark image.
It optionally,, can be with when the next frame image for determining benchmark image is target image in video display process
The image is directly skipped, using the next frame image of target image as the adjacent image of benchmark image, recycles benchmark image
Judge whether content repeats the image.For example, in the example above, it, then can be with skip pictures after determining image B is target image
B can then compare image C and image A at this point, image A is adjacent with image C.
A large amount of identical invalid video image data can be effectively detected by the above method, play changed figure
As information.
Preferably, in embodiments of the present invention, detection unit 20 can also include: first to compare in the video play device
Module, first judgment module.Wherein, comparing subunit 201 may include: the first comparison module;Judgment sub-unit 202 can wrap
It includes: first judgment module.
Comparing subunit 201 includes: the first comparison module, the same position in successively more adjacent two field pictures
Pixel obtains pixel comparing result.
First comparison module can be the further improvement to comparing subunit 201, specifically, the video data of load
In, the first frame image in adjacent two field pictures can be chosen as benchmark image, another frame image is the phase of benchmark image
Adjacent next frame image, then by the comparison of the pixel of same position on this two adjacent images progress images, obtain comparing result.Picture
Element is that the basic unit that image is shown can be accurately obtained comparing result by comparing the pixel of image same position.
Judgment sub-unit 202 includes: first judgment module, for judging adjacent two field pictures according to pixel comparing result
Whether the pixel of upper same position is all identical, wherein if it is judged that the pixel of same position all phases in adjacent two field pictures
Together, it is determined that the picture material of adjacent two field pictures is identical.
First judgment module can be the further improvement to judgment sub-unit 202, specifically, is compared and is tied according to pixel
Fruit judges whether the pixel of same position on benchmark image next frame image adjacent thereto is identical.
If it is judged that benchmark image next frame image adjacent thereto is all identical in the pixel of same position, it is determined that adjacent
This two field pictures picture material it is identical.
If it is judged that benchmark image next frame image adjacent thereto is not all identical in the pixel of same position, it is determined that phase
The picture material of this adjacent two field pictures is not identical.
Such as the video of load includes continuous image A, image B and image C, wherein image A is the first frame figure of shooting
Picture, using image A as benchmark image, image B is the adjacent image of image A, by the pixel of this two frames adjacent image same position
It is compared, if the pixel of image B and image A same position is all identical, image B can be set as target image.Image C
For the adjacent image with image B, image C is compared with the pixel of image B same position, if image C is identical as image B
The pixel of position is identical, then image C is target image;If image C is not all identical as the pixel of image B same position, scheme
As C is not target image, meanwhile, using image C as benchmark image.Then, it is periodically deleted according to the preset time cycle
Determining target image.
A large amount of identical invalid video image data can be effectively filtered out by the above method, are changed to play
Video data.
Preferably, in embodiments of the present invention, in the video play device, detection unit 20 can also include: calculating mould
Block, the second comparison module and the second judgment module.Wherein comparing subunit 201 includes: computing module, the second comparison module;Sentence
Disconnected subelement 202 includes: the second judgment module computing module.
Second comparison module obtains cryptographic Hash comparing result for the cryptographic Hash of more adjacent two field pictures.
Computing module and the second comparison module can be the further improvement to comparing subunit.
Specifically, in the adjacent two field pictures of video camera shooting, the first frame in adjacent two field pictures can be chosen
For image as benchmark image, another frame image is the adjacent next frame image of benchmark image, then by the Kazakhstan of this two adjacent images
Uncommon value is compared, and obtains comparing result.Comparing result can accurately and quickly be obtained using Hash perception algorithm.
Second judgment module, for judged according to cryptographic Hash comparing result adjacent two field pictures cryptographic Hash whether phase
Together, wherein if it is judged that the cryptographic Hash of adjacent two field pictures is identical, it is determined that the picture material phase of adjacent two field pictures
Together.
If it is judged that the cryptographic Hash of benchmark image next frame image adjacent thereto is all identical, it is determined that this adjacent two frame
The picture material of image is identical.
If it is judged that the cryptographic Hash of benchmark image next frame image adjacent thereto is not identical, it is determined that this adjacent two frame
The picture material of image is not identical.
Preferably, in embodiments of the present invention, the computing module in video play device may include: pretreatment submodule
Block, the first computational submodule and the second computational submodule.
Submodule is pre-processed, for being pre-processed to image in video data, the image that obtains that treated.
The pretreatment can be that the video image that will acquire reduces the size and is converted to gray level image.For example, picture is pressed
8 × 8 size is narrowed down to according to same method, in total 64 pixels.Using this method, the details of picture can be removed, is only protected
Stay the essential informations such as structure, light and shade.
Simplify color and the picture after diminution is switched into 64 grades of gray scales.That is, all pixels point only has 64 kinds of colors in total.
First computational submodule, the average gray for the image after calculation processing.
Calculate the average gray of all 64 pixels in pretreated video image.
Second computational submodule, for cryptographic Hash to be calculated using average gray.
The gray scale of each pixel is compared by the gray scale of compared pixels with average value.More than or equal to average value, note
It is 1;Less than average value, it is denoted as 0.The comparison of the cryptographic Hash of adjacent two field pictures is carried out according still further to same sequence.
It by the comparison result of previous step, combines, just constitutes one 64 integers, here it is this pictures
Fingerprint.Combined order is not important, as long as guaranteeing that all pictures all use same order.Due to same monitoring camera
Picture size, the ratio of machine output are consistent.It is all according to identical side in the image processing process such as minification, simplified color
Method is handled.Therefore influence of the entire treatment process to cryptographic Hash can be ignored.
Using the first frame image of load as benchmark image, the Hash of first frame image is obtained by the above perceptual hash algorithm
Value, calculates the cryptographic Hash of adjacent next frame picture.The Kazakhstan of benchmark picture and adjacent next frame image in that same order
Uncommon value.
If comparison result shows that every data value is all identical, picture and the reference base picture phase of adjacent next frame
Together, this picture is directly abandoned not save.The image cryptographic Hash of the adjacent next frame after abandoning image is calculated again, and by above-mentioned
Method is compared calculating.
If comparison result shows that the value in data bit is different, then it is assumed that the picture and reference base picture of adjacent next frame
Difference then using the picture of adjacent next frame as reference base picture, and saves original picture.
Such as the video of load includes continuous image A, image B and image C, wherein image A is the first frame figure of shooting
Picture, using image A as benchmark image, image B is the adjacent image of image A, and the cryptographic Hash of this two frames adjacent image is compared
Compared with image B being set as target image if image B is identical as image A cryptographic Hash.Image C is adjacent with image B
Image C is compared by image with the cryptographic Hash of image B, if image C is identical as the cryptographic Hash of image B, image C is mesh
Logo image;If image C is not identical as the cryptographic Hash of image B, image C is not target image, meanwhile, using image C as base
Quasi- image.
By the description above to video broadcasting method and device, having the beneficial effect that for reaching can be skipped effectively greatly
Identical invalid image data is measured, changed video data is played, achievees the effect that quick browse video.
It should be noted that for the various method embodiments described above, for simple description, therefore, it is stated as a series of
Combination of actions, but those skilled in the art should understand that, the present invention is not limited by the sequence of acts described because
According to the present invention, some steps may be performed in other sequences or simultaneously.Secondly, those skilled in the art should also know
It knows, the embodiments described in the specification are all preferred embodiments, and related actions and modules is not necessarily of the invention
It is necessary.
In the above-described embodiments, it all emphasizes particularly on different fields to the description of each embodiment, there is no the portion being described in detail in some embodiment
Point, reference can be made to the related descriptions of other embodiments.
In several embodiments provided herein, it should be understood that disclosed device, it can be by another way
It realizes.For example, the apparatus embodiments described above are merely exemplary, such as the division of the unit, it is only a kind of
Logical function partition, there may be another division manner in actual implementation, such as multiple units or components can combine or can
To be integrated into another system, or some features can be ignored or not executed.Another point, shown or discussed is mutual
Coupling, direct-coupling or communication connection can be through some interfaces, the indirect coupling or communication connection of device or unit,
It can be electrical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list
Member both can take the form of hardware realization, can also realize in the form of software functional units.
If the integrated unit is realized in the form of SFU software functional unit and sells or use as independent product
When, it can store in a computer readable storage medium.Based on this understanding, technical solution of the present invention is substantially
The all or part of the part that contributes to existing technology or the technical solution can be in the form of software products in other words
It embodies, which is stored in a storage medium, including some instructions are used so that a computer
Equipment (can be personal computer, mobile terminal, server or network equipment etc.) executes side described in each embodiment of the present invention
The all or part of the steps of method.And storage medium above-mentioned include: USB flash disk, read-only memory (ROM, Read-Only Memory),
Random access memory (RAM, Random Access Memory), mobile hard disk, magnetic or disk etc. are various to be can store
The medium of program code.
The foregoing is only a preferred embodiment of the present invention, is not intended to restrict the invention, for the skill of this field
For art personnel, the invention may be variously modified and varied.All within the spirits and principles of the present invention, made any to repair
Change, equivalent replacement, improvement etc., should all be included in the protection scope of the present invention.
Claims (10)
1. a kind of video broadcasting method characterized by comprising
Video data to be played is loaded, the video data includes the image data being continuously shot;
Target image is detected from the video data, the target image is the identical figure of content of image adjacent thereto
Picture;
The corresponding image data of the target image is filtered, obtains filtering out the video data after the target image;
And
Video data after filtering out the target image described in broadcasting;
Wherein, the target image that detects from the video data includes: to compare to the pixel of adjacent two field pictures,
Or, being compared to the cryptographic Hash of adjacent two field pictures;
There are time sequencings for the image obtained due to video capture, by the figure shot rear in the adjacent image of identical two frame of content
As being used as target image.
2. video broadcasting method according to claim 1, which is characterized in that detect target image from the video data
Include:
Two field pictures adjacent in the video data are compared, comparing result is obtained;
Judge whether the picture material of the adjacent two field pictures is identical according to the comparing result;
If it is judged that the picture material of the adjacent two field pictures is identical, then by the frame in the adjacent two field pictures
Image is as the target image.
3. video broadcasting method according to claim 2, which is characterized in that
Two field pictures adjacent in the video data are compared, it includes: successively more described adjacent for obtaining comparing result
Two field pictures on same position pixel, obtain pixel comparing result,
According to comparing result judge the picture material of the adjacent two field pictures it is whether identical include: according to the pixel compare
As a result judge whether the pixel of same position in the adjacent two field pictures is all identical, wherein if it is judged that described adjacent
Two field pictures on same position pixel it is all identical, it is determined that the picture material of the adjacent two field pictures is identical.
4. video broadcasting method according to claim 2, which is characterized in that
Two field pictures adjacent in the video data are compared, obtaining comparing result includes: to utilize perceptual hash algorithm
Calculate the cryptographic Hash of image in the video data;The cryptographic Hash for comparing the adjacent two field pictures obtains cryptographic Hash comparison
As a result,
According to comparing result judge the picture material of the adjacent two field pictures it is whether identical include: according to the cryptographic Hash pair
Judge whether the cryptographic Hash of the adjacent two field pictures is identical than result, wherein if it is judged that the two adjacent frame figures
The cryptographic Hash of picture is identical, it is determined that the picture material of the adjacent two field pictures is identical.
5. video broadcasting method according to claim 4, which is characterized in that calculate the video using perceptual hash algorithm
The cryptographic Hash of image includes: in data
Image in the video data is pre-processed, the image that obtains that treated;
Calculate the average gray of treated the image;And
The cryptographic Hash is calculated using the average gray.
6. a kind of video play device characterized by comprising
Loading unit, for loading video data to be played, the video data includes the image data being continuously shot;
Detection unit, for detecting target image from the video data, the target image is image adjacent thereto
The identical image of content;
Filter element obtains filtering out the target image for being filtered the corresponding image data of the target image
Video data afterwards;And
Broadcast unit, for playing the video data filtered out after the target image;
Wherein, the target image that detects from the video data includes: to compare to the pixel of adjacent two field pictures,
Or, being compared to the cryptographic Hash of the adjacent two field pictures;
There are time sequencings for the image obtained due to video capture, by the figure shot rear in the adjacent image of identical two frame of content
As being used as target image.
7. video play device according to claim 6, which is characterized in that the detection unit includes:
Comparing subunit obtains comparing result for comparing two field pictures adjacent in the video data;
Judgment sub-unit, for judging whether the picture material of the adjacent two field pictures is identical according to the comparing result;
And
Subelement is selected, it, then will be described adjacent for if it is judged that the picture material of the adjacent two field pictures is identical
A frame image in two field pictures is as the target image.
8. video play device according to claim 7, which is characterized in that
The comparing subunit includes: the first comparison module, the same position in the successively adjacent two field pictures
Pixel, obtain pixel comparing result,
The judgment sub-unit includes: first judgment module, for judging described adjacent two according to the pixel comparing result
Whether the pixel of same position is all identical on frame image, wherein if it is judged that same position in the adjacent two field pictures
Pixel it is all identical, it is determined that the picture material of the adjacent two field pictures is identical.
9. video play device according to claim 7, which is characterized in that
The comparing subunit includes: computing module, for calculating image in the video data using perceptual hash algorithm
Cryptographic Hash;Second comparison module obtains cryptographic Hash comparing result for the cryptographic Hash of the adjacent two field pictures,
The judgment sub-unit includes: the second judgment module, described adjacent for being judged according to the cryptographic Hash comparing result
Whether the cryptographic Hash of two field pictures is identical, wherein if it is judged that the cryptographic Hash of the adjacent two field pictures is identical, it is determined that
The picture material of the adjacent two field pictures is identical.
10. video play device according to claim 9, which is characterized in that the computing module includes:
Submodule is pre-processed, for being pre-processed to image in the video data, the image that obtains that treated;
First computational submodule, for calculating the average gray of treated the image;And
Second computational submodule, for the cryptographic Hash to be calculated using the average gray.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410662504.XA CN104469289B (en) | 2014-11-18 | 2014-11-18 | Video broadcasting method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410662504.XA CN104469289B (en) | 2014-11-18 | 2014-11-18 | Video broadcasting method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104469289A CN104469289A (en) | 2015-03-25 |
CN104469289B true CN104469289B (en) | 2019-01-15 |
Family
ID=52914564
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410662504.XA Active CN104469289B (en) | 2014-11-18 | 2014-11-18 | Video broadcasting method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104469289B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104936021B (en) * | 2015-06-02 | 2018-03-09 | 无锡天脉聚源传媒科技有限公司 | The monitoring method and device of a kind of video playback |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102348115A (en) * | 2010-08-02 | 2012-02-08 | 南京壹进制信息技术有限公司 | Method and device for removing redundant images from video |
WO2012059008A1 (en) * | 2010-11-02 | 2012-05-10 | 华为终端有限公司 | Method and device for processing image display |
CN102946530A (en) * | 2012-11-27 | 2013-02-27 | 北京恒华伟业科技股份有限公司 | Video transmission method and device and video playing method and device |
CN103327306A (en) * | 2013-06-14 | 2013-09-25 | 广东威创视讯科技股份有限公司 | Method and device for storing video surveillance image |
-
2014
- 2014-11-18 CN CN201410662504.XA patent/CN104469289B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102348115A (en) * | 2010-08-02 | 2012-02-08 | 南京壹进制信息技术有限公司 | Method and device for removing redundant images from video |
WO2012059008A1 (en) * | 2010-11-02 | 2012-05-10 | 华为终端有限公司 | Method and device for processing image display |
CN102457701A (en) * | 2010-11-02 | 2012-05-16 | 华为终端有限公司 | Image display processing method and device for same |
CN102946530A (en) * | 2012-11-27 | 2013-02-27 | 北京恒华伟业科技股份有限公司 | Video transmission method and device and video playing method and device |
CN103327306A (en) * | 2013-06-14 | 2013-09-25 | 广东威创视讯科技股份有限公司 | Method and device for storing video surveillance image |
Also Published As
Publication number | Publication date |
---|---|
CN104469289A (en) | 2015-03-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108062507B (en) | Video processing method and device | |
US9473702B2 (en) | Controlling image capture and/or controlling image processing | |
CN103795920B (en) | Photo processing method and device | |
US10298896B2 (en) | Method and apparatus for generating HDRI | |
CN107483860B (en) | Security monitoring video storage and playback method suitable for improving case solving efficiency | |
CN106412555A (en) | Game recording method and device, and virtual reality device | |
JP6040655B2 (en) | Image processing apparatus, image processing method, control program, and recording medium | |
CN105049728A (en) | Method and device for acquiring shot image | |
CN108632666B (en) | Video detection method and video detection equipment | |
CN111835982B (en) | Image acquisition method, image acquisition device, electronic device, and storage medium | |
US20140376882A1 (en) | Computing device with video analyzing function and video analyzing method | |
CN109756622B (en) | Image caching method and device, mobile terminal and storage medium | |
CN108184165A (en) | Video broadcasting method, electronic device and computer readable storage medium | |
CN112926385A (en) | Video processing method of monitoring equipment and related product | |
CN105574813A (en) | Image processing method and device | |
CN105808645A (en) | Picture processing method and device and electronic equipment | |
CN105578035B (en) | A kind of image processing method and electronic equipment | |
JP2006333249A5 (en) | ||
CN106303724B (en) | The method and apparatus that smart television adds dynamic expression automatically | |
CN104469289B (en) | Video broadcasting method and device | |
CN104168415A (en) | Moving image reproducing apparatus and method for controlling the same | |
CN109064526A (en) | Method and device for generating jigsaw puzzle | |
JP2017092609A (en) | Imaging apparatus, flicker detection method and program | |
CN106792149B (en) | Picture playing method and device | |
CN109640170B (en) | Speed processing method of self-shooting video, terminal and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |