CN104469289A - Video playing method and device - Google Patents

Video playing method and device Download PDF

Info

Publication number
CN104469289A
CN104469289A CN201410662504.XA CN201410662504A CN104469289A CN 104469289 A CN104469289 A CN 104469289A CN 201410662504 A CN201410662504 A CN 201410662504A CN 104469289 A CN104469289 A CN 104469289A
Authority
CN
China
Prior art keywords
image
adjacent
field pictures
video data
video
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.)
Granted
Application number
CN201410662504.XA
Other languages
Chinese (zh)
Other versions
CN104469289B (en
Inventor
陈晓龙
陈显龙
杨志鹏
罗新伟
贺志刚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Forever Technology Co Ltd
Original Assignee
Beijing Forever Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Forever Technology Co Ltd filed Critical Beijing Forever Technology Co Ltd
Priority to CN201410662504.XA priority Critical patent/CN104469289B/en
Publication of CN104469289A publication Critical patent/CN104469289A/en
Application granted granted Critical
Publication of CN104469289B publication Critical patent/CN104469289B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Studio Devices (AREA)
  • Studio Circuits (AREA)

Abstract

The invention discloses a video playing method and device. The method comprises the steps of loading video data to be played, wherein the video data include continuously shot image data; detecting a target image from the video data, wherein the target image is an image the content of which is identical with that of an adjacent image; filtering the image data corresponding to the target image to obtain video data without the target image; playing the video data obtained after the target image is filtered out. By the adoption of the method and device, the problem of the prior art that the time for playing a monitoring video is long is solved, the effect of shortening the time for playing a monitoring video is realized, and then quick video browsing is achieved.

Description

Video broadcasting method and device
Technical field
The present invention relates to data processing field, in particular to a kind of video broadcasting method and device.
Background technology
A series of static image is caught in signal of telecommunication mode by video general reference, record, and process stores, and transmits, with the various technology of reappearing.Continuous print image change per second more than more than 24 frames (frame) picture time, according to persistence of vision principle, human eye cannot distinguish the tableaux of single width; Look it is level and smooth continuous print visual effect, such continuous print picture is called video.
The features such as video monitoring system generally has many, the fixing layings in control point, camera quantity is many, monitoring period long (time of image data often reaches several days or tens days), data volume are large, therefore video monitoring system storage must support Large Copacity, and capacity has high scalability, meet the demand that long-time large-capacity video image stores.
Inventor finds, staff is when checking monitoring is recorded a video, usually need to start anew to obtain every one-frame video data in playing video data, and in video data, often there is a large amount of repeating datas, this will make these video playback consuming time longer, the plenty of time of waste staff checking monitoring video, the mode of F.F. is adopted then easily to ignore the slight change of the image taken in monitor video.
For the longer problem consuming time of the broadcasting of monitor video in prior art, at present effective solution is not yet proposed.
Summary of the invention
Main purpose of the present invention is to provide a kind of video broadcasting method and device, to solve the longer problem consuming time of the broadcasting of monitor video in prior art.
To achieve these goals, according to an aspect of the embodiment of the present invention, a kind of video broadcasting method is provided.Video broadcasting method according to the present invention comprises: load video data to be played, and described video data comprises the view data of shooting continuously; From described video data, detect target image, described target image is the image that the content of the image be adjacent is identical; The view data corresponding to described target image is filtered, and obtains the video data after filtering out described target image; And the video data filtered out described in playing after described target image.
Further, from described video data, detect target image comprise: two two field pictures adjacent in described video data are contrasted, obtains comparing result; Judge that whether the picture material of described two adjacent two field pictures is identical according to described comparing result; If judge that the picture material of described two adjacent two field pictures is identical, then using the two field picture in described two adjacent two field pictures as described target image.
Further, two two field pictures adjacent in described video data are contrasted, obtain comparing result to comprise: the pixel of same position on more described two adjacent two field pictures successively, obtain pixel comparison result, judge that whether the picture material of described two adjacent two field pictures is identical according to comparing result to comprise: judge that whether the pixel of same position on described two adjacent two field pictures is all identical according to described pixel comparison result, wherein, if judge that the pixel of same position on described two adjacent two field pictures is all identical, then determine that the picture material of described two adjacent two field pictures is identical.
Further, two two field pictures adjacent in described video data are contrasted, obtains comparing result and comprise: utilize perception hash algorithm to calculate the cryptographic Hash of image in described video data; The cryptographic Hash of more described two adjacent two field pictures, obtain cryptographic Hash comparing result, judge that whether the picture material of described two adjacent two field pictures is identical according to comparing result to comprise: judge that whether the cryptographic Hash of described two adjacent two field pictures is identical according to described cryptographic Hash comparing result, wherein, if judge that the cryptographic Hash of described two adjacent two field pictures is identical, then determine that the picture material of described two adjacent two field pictures is identical.
Further, the cryptographic Hash utilizing perception hash algorithm to calculate image in described video data comprises: carry out preliminary treatment to image in described video data, obtains the image after processing; Calculate the average gray of the image after described process; And utilize described average gray to calculate described cryptographic Hash.
To achieve these goals, according to the another aspect of the embodiment of the present invention, provide a kind of video play device.Video play device according to the present invention comprises: loading unit, and for loading video data to be played, described video data comprises the view data of shooting continuously; Detecting unit, for detecting target image from described video data, described target image is the image that the content of the image be adjacent is identical; Filter element, filters for the view data corresponding to described target image, obtains the video data after filtering out described target image; And broadcast unit, described in playing, filter out the video data after described target image.
Further, described detecting unit comprises: compare subelement, for being contrasted by two two field pictures adjacent in described video data, obtains comparing result; Whether judgment sub-unit is identical for judging the picture material of described two adjacent two field pictures according to described comparing result; And chooser unit, if identical for judging the picture material of described two adjacent two field pictures, then using the two field picture in described two adjacent two field pictures as described target image.
Further, the described subelement that compares comprises: the first comparison module, the pixel of same position on more described two adjacent two field pictures successively, obtain pixel comparison result, described judgment sub-unit comprises: the first judge module, for judging that according to described pixel comparison result whether the pixel of same position on described two adjacent two field pictures is all identical, wherein, if judge that the pixel of same position on described two adjacent two field pictures is all identical, then determine that the picture material of described two adjacent two field pictures is identical.
Further, the described subelement that compares comprises: computing module, for the cryptographic Hash utilizing perception hash algorithm to calculate image in described video data; Second comparison module, for the cryptographic Hash of more described two adjacent two field pictures, obtain cryptographic Hash comparing result, described judgment sub-unit comprises: the second judge module, for judging that according to described cryptographic Hash comparing result whether the cryptographic Hash of described two adjacent two field pictures is identical, wherein, if judge that the cryptographic Hash of described two adjacent two field pictures is identical, then determine that the picture material of described two adjacent two field pictures is identical.
Further, described computing module comprises: preliminary treatment submodule, for carrying out preliminary treatment to image in described video data, obtains the image after processing; First calculating sub module, for calculating the average gray of the image after described process; And second calculating sub module, calculate described cryptographic Hash for utilizing described average gray.
According to the embodiment of the present invention, by loading video data to be played, target image is detected from video data, target image is the image that the content of the image be adjacent is identical, the view data corresponding to target image is filtered, obtain the video data after filtering out target image, play the video data after filtering out target image, owing to skipping the view data that content repeats in playing process, avoid playing and repeat identical image in a large number, solve the longer problem consuming time of the broadcasting of monitor video in prior art, reach the effect reducing the time that monitor video is play.And then reach the effect of quick browse video.
Accompanying drawing explanation
The accompanying drawing forming a application's part is used to provide a further understanding of the present invention, and schematic description and description of the present invention, for explaining the present invention, does not form inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is the flow chart of the video broadcasting method according to the embodiment of the present invention;
Fig. 2 is the flow chart according to the preferred video broadcasting method of the embodiment of the present invention;
Fig. 3 is the flow chart according to another preferred video broadcasting method of the embodiment of the present invention;
Fig. 4 is the schematic diagram of the video play device according to the embodiment of the present invention; And
Fig. 5 is the schematic diagram according to the preferred video play device of the embodiment of the present invention.
Embodiment
It should be noted that, when not conflicting, the embodiment in the application and the feature in embodiment can combine mutually.Below with reference to the accompanying drawings and describe the present invention in detail in conjunction with the embodiments.
The present invention program is understood better in order to make those skilled in the art person, below in conjunction with the accompanying drawing in the embodiment of the present invention, technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the embodiment of a part of the present invention, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, should belong to the scope of protection of the invention.
It should be noted that, term " first ", " second " etc. in specification of the present invention and claims and above-mentioned accompanying drawing are for distinguishing similar object, and need not be used for describing specific order or precedence.Should be appreciated that the data used like this can be exchanged, in the appropriate case so that embodiments of the invention described herein.In addition, term " comprises " and " having " and their any distortion, intention is to cover not exclusive comprising, such as, contain those steps or unit that the process of series of steps or unit, method, system, product or equipment is not necessarily limited to clearly list, but can comprise clearly do not list or for intrinsic other step of these processes, method, product or equipment or unit.
According to the embodiment of the present invention, provide a kind of video broadcasting method.This video broadcasting method may operate on the equipment such as player.
Fig. 1 is the flow chart of the video broadcasting method according to the embodiment of the present invention.As shown in Figure 1, this video broadcasting method can comprise:
Step S102, loads video data to be played.
Video data can comprise the view data of being taken continuously by video camera.As in monitor video, the video image that video camera is taken continuously is the monitor video image obtained within one or more time period, and video image here can be the video data without the time interval within one or more time period.When staff checks this kind of monitor video, can, to player input of control commands, after player receives control command, start to load video data to be played, so that show broadcasting.
Step S104, detects target image from video data, and target image can be the identical image of the content of the image be adjacent.
A wherein two field picture as chosen video camera shooting is preserved, and records the shooting time of this image, is compared by the adjacent image of this two field picture chosen, if the content of its adjacent image is identical with it, then using this adjacent image as target image.If the content of its adjacent image is not identical with it, then there is not target image in this adjacent image.
The video data such as loaded comprises continuous print image A, image B and image C, wherein, image A is the wherein two field picture chosen, here, can the shooting time of document image A, image B is the adjacent image of image A, is compared by this two frames adjacent image, if image B is identical with the picture material of image A, then image B can be set to target image.Image C is the adjacent image with image B, is compared by image C and image B, if image C is identical with the picture material of image B, then image C is target image; If image C is not identical with the picture material of image B, then image C is not target image.
Step S106, the view data corresponding to target image is filtered, and obtains the video data after filtering out target image.
Step S108, plays the video data after filtering out target image.
Filter out the view data that target image is corresponding, namely filter out view data corresponding to image B in above-mentioned citing, obtain image A and image C, skip pictures B, playing image A and image C.Wherein, two adjacent images compare according to same sequence.Like this, after filtering out video data corresponding to target image, what obtain is the video data that continuous print picture material is not identical, plays the broadcasting that this video data can greatly reduce palinopsia audio data, thus reduces the consuming time of video playback.
According to the embodiment of the present invention, by loading video data to be played, target image is detected from video data, target image is the image that the content of the image be adjacent is identical, the view data corresponding to target image is filtered, obtain the video data after filtering out target image, play the video data after filtering out target image, owing to skipping the view data that content repeats in playing process, avoid playing and repeat identical image in a large number, solve the longer problem consuming time of the broadcasting of monitor video in prior art, reach the effect reducing the time that monitor video is play.And then reach the effect of quick browse video.
Fig. 2 is the flow chart according to the preferred video broadcasting method of the embodiment of the present invention.The video broadcasting method of this embodiment can be a kind of preferred implementation of the video broadcasting method of above-described embodiment.As shown in Figure 2, this video broadcasting method can be the improvement to the video broadcasting method shown in Fig. 1, and particularly, from video data, detect target image can comprise:
Two two field pictures adjacent in video data are contrasted, obtain comparing result by step S202.
Being contrasted by two two field pictures adjacent in video data, can be contrast the pixel of adjacent two two field pictures, can also be contrast the cryptographic Hash of adjacent two two field pictures.
In the video data to be played loaded, the first two field picture in two adjacent two field pictures can be chosen as benchmark image, another two field picture is the adjacent next frame image of benchmark image, then this two frames adjacent image is carried out the comparison of picture material, obtains comparing result.Wherein, two frame adjacent images compare according to same sequence.
According to comparing result, step S204, judges that whether the picture material of two adjacent two field pictures is identical.
Step S206, if judge that the picture material of two adjacent two field pictures is identical, then using the two field picture in two adjacent two field pictures as target image.
Target image can be any frame image in adjacent two two field pictures.Due to the image life period order that video capture obtains, therefore, can using the image of shooting rear in image adjacent for two identical for content frames as target image.Such as, using the image first taken as benchmark image, the next frame image of this benchmark image and this benchmark image are compared, whether the picture material that judgment standard image is adjacent next frame image is identical, if it is identical to judge that benchmark image is adjacent the picture material of next frame image, then using this next frame image as target image.
If it is not identical to judge that benchmark image is adjacent the picture material of next frame image, then preserve this next frame image.
The video data such as loaded comprises continuous print image A, image B and image C, wherein, image A is the first two field picture of shooting, using image A as benchmark image, image B is the adjacent image of image A, this two frames adjacent image is compared, if image B is identical with the picture material of image A, then image B can be set to target image.Image C is the adjacent image with image B, is compared by image C and image B, if image C is identical with the picture material of image B, then image C is target image; If image C is not identical with the picture material of image B, then image C is not target image, meanwhile, using image C as benchmark image.
Alternatively, in video display process, when the next frame image determining benchmark image is target image, can directly skip this image, using the adjacent image of the next frame image of target image as benchmark image, recycling benchmark image judges whether content repeats this image.Such as, in above-mentioned citing, after determining that image B is target image, then can skip pictures B, now, image A is adjacent with image C, then image C and image A can be contrasted.
A large amount of identical invalid vedio data effectively can be detected by said method, play the image information changed.
Preferably, in embodiments of the present invention, this video broadcasting method can also comprise:
Step S4, on two more adjacent successively two field pictures, the pixel of same position, obtains pixel comparison result.
This step S4 can be the further improvement " contrasted by two two field pictures adjacent in video data; obtain comparing result " step, particularly, in the video data loaded, the first two field picture in two adjacent two field pictures can be chosen as benchmark image, another two field picture is the adjacent next frame image of benchmark image, then these two adjacent images is carried out the comparison of the pixel of same position on image, obtains comparing result.Pixel is the base unit of image display, by the pixel of movement images same position, accurately can obtain comparing result.
According to pixel comparison result, step S6, judges that whether the pixel of same position on two adjacent two field pictures is all identical.
Step S6 can be the further improvement " judging that whether the picture material of two adjacent two field pictures is identical according to comparing result " to step, particularly, according to pixel comparison result, whether the pixel that judgment standard image is adjacent same position on next frame image is identical.
Step S8, if judge that the pixel of same position on two adjacent two field pictures is all identical, then determines that the picture material of two adjacent two field pictures is identical.
If it is all identical in the pixel of same position to judge that benchmark image is adjacent next frame image, then determine that the picture material of this adjacent two two field picture is identical.
If it is not all identical in the pixel of same position to judge that benchmark image is adjacent next frame image, then determine that the picture material of this adjacent two two field picture is not identical.
The video such as loaded comprises continuous print image A, image B and image C, wherein, image A is the first two field picture of shooting, using image A as benchmark image, image B is the adjacent image of image A, the pixel of this two frames adjacent image same position is compared, if image B is identical with the pixel of image A same position, then image B can be set to target image.Image C is the adjacent image with image B, and the pixel of image C and image B same position compared, if image C is identical with the pixel of image B same position, then image C is target image; If image C is not all identical with the pixel of image B same position, then image C is not target image, meanwhile, using image C as benchmark image.
Effectively can filter out a large amount of identical invalid vedio data by said method, thus play the video data changed.
Preferably, in embodiments of the present invention, this video broadcasting method can also comprise:
Step S10, utilizes perception hash algorithm to calculate the cryptographic Hash of image in video data.
Step S12, the cryptographic Hash of two more adjacent two field pictures, obtains cryptographic Hash comparing result.
Step S10 and step S12 can be the further improvement " two two field pictures adjacent in video data being contrasted step, obtain comparing result ".
Particularly, in the video data to be played loaded, can choose the first two field picture in two adjacent two field pictures as benchmark image, another two field picture is the adjacent next frame image of benchmark image, again the cryptographic Hash of these two adjacent images is compared, obtain comparing result.Adopt Hash perception algorithm accurately can obtain comparing result rapidly.
According to cryptographic Hash comparing result, step S14, judges that whether the cryptographic Hash of two adjacent two field pictures is identical.
Judge that whether the picture material of two adjacent two field pictures is identical according to comparing result can also comprise: judge that whether the cryptographic Hash of two adjacent two field pictures is identical according to cryptographic Hash comparing result.
Step S16, if judge that the cryptographic Hash of two adjacent two field pictures is identical, then determines that the picture material of two adjacent two field pictures is identical.
If it is all identical to judge that benchmark image is adjacent the cryptographic Hash of next frame image, then determine that the picture material of this adjacent two two field picture is identical.
If it is not identical to judge that benchmark image is adjacent the cryptographic Hash of next frame image, then determine that the picture material of this adjacent two two field picture is not identical.
Preferably, in embodiments of the present invention, step in the video broadcasting method cryptographic Hash of image " in the video data " can comprise:
Step S16, carries out preliminary treatment to image in video data, obtains the image after processing.
This preliminary treatment can be by the video image minification of acquisition and be converted to gray level image.Such as, picture is narrowed down to after the same method the size of 8 × 8, altogether 64 pixels.Adopt the method, the details of picture can be removed, only retain the essential information such as structure, light and shade.
Simplify color, by the picture after reducing, transfer 64 grades of gray scales to.Also namely, all pixels only have 64 kinds of colors altogether.
Step S18, the average gray of the image after computing.
Calculate the average gray of all 64 pixels in pretreated video image.
Step S20, utilizes average gray to calculate cryptographic Hash.
The gray scale of compared pixels, by the gray scale of each pixel, compares with mean value.Be more than or equal to mean value, be designated as 1; Be less than mean value, be designated as 0.The comparison of the cryptographic Hash of adjacent two two field pictures is carried out again according to same sequence.
By the comparative result of previous step, combine, just constitute the integer of 64, the fingerprint of Here it is this pictures.The order of combination is unimportant, as long as ensure that all pictures all adopt same order.The picture size exported due to same CCTV camera, ratio are consistent.All process according to identical method in the image processing process such as minification, simplification color.Therefore the impact of whole processing procedure on cryptographic Hash can be ignored.
With the first two field picture loaded for benchmark image, obtained the cryptographic Hash of the first two field picture by above perception hash algorithm, calculate the cryptographic Hash of adjacent next frame picture.According to the cryptographic Hash of identical order benchmark picture and adjacent next frame image.
If the data value that the result compared shows every is all identical, then the picture of adjacent next frame is identical with reference base picture, directly abandons this picture and does not preserve.Again calculate the image cryptographic Hash of the adjacent next frame after abandoning image, and compare calculating by said method.
If the value in the result display data bit compared is different, then think that the picture of adjacent next frame is different from reference base picture, then using the picture of adjacent next frame as reference base picture, and preserve former picture.
The video such as loaded comprises continuous print image A, image B and image C, wherein, image A is the first two field picture of shooting, using image A as benchmark image, image B is the adjacent image of image A, the cryptographic Hash of this two frames adjacent image is compared, if image B is identical with image A cryptographic Hash, then image B can be set to target image.Image C is the adjacent image with image B, the cryptographic Hash of image C and image B is compared, if image C is identical with the cryptographic Hash of image B, then image C is target image; If image C is not identical with the cryptographic Hash of image B, then image C is not target image, meanwhile, using image C as benchmark image.
Fig. 3 is the flow chart according to another preferred video broadcasting method of the embodiment of the present invention.As shown in Figure 3, the flow process of this video broadcasting method can comprise:
Step S302, chooses the first two field picture of loading as benchmark image, and calculates the cryptographic Hash of this image.
Step S304, calculates the cryptographic Hash of the next frame image be adjacent.
Step S306, the cryptographic Hash of each data bit of next frame image comparing the first two field picture according to same sequence and be adjacent.
Step S308, if comparing result is identical, then judge that this two two field pictures content is identical, filter out the view data that this next frame image is corresponding, namely this image is target image.Then return and perform step S304.
Calculate the cryptographic Hash of image of the adjacent next frame of target image, then with this next frame image before the cryptographic Hash of image of preserving compare, comparative approach is the same, does not repeat them here.Wherein, two adjacent images is relatively compare according to same sequence.
Step S310, if comparing result is not identical, then judges that this two two field pictures content is not identical, using this next frame image as benchmark image, then returns execution step 304.
By the embodiment of the present invention, effectively can skip a large amount of identical invalid image data by said method, play the video data changed, reach the effect of quick browse video.
The embodiment of the present invention additionally provides a kind of video play device.This device can realize its function by equipment such as players.It should be noted that, the video play device of the embodiment of the present invention may be used for performing the video broadcasting method that the embodiment of the present invention provides, and the video play device that the video broadcasting method of the embodiment of the present invention also can be provided by the embodiment of the present invention performs.
Fig. 4 is the schematic diagram of the video play device according to the embodiment of the present invention.As shown in Figure 4, this video play device can comprise: loading unit 10, detecting unit 20, filter element 30 and broadcast unit 40.
Loading unit 10 is for loading video data to be played, and video data comprises the view data of shooting continuously.
Video data can comprise the view data of being taken continuously by video camera.As in monitor video, the video image that video camera is taken continuously is the monitor video image obtained within one or more time period, and video image here can be the video data without the time interval within one or more time period.When staff checks this kind of monitor video, can, to player input of control commands, after player receives control command, start to load video data to be played, so that show broadcasting.
Detecting unit 20 for detecting target image from video data, and target image is the image that the content of the image be adjacent is identical.
A wherein two field picture as chosen video camera shooting is preserved, and records the shooting time of this image, is compared by the adjacent image of this two field picture chosen, if the content of its adjacent image is identical with it, then using this adjacent image as target image.If the content of its adjacent image is not identical with it, then there is not target image in this adjacent image.
The video data such as loaded comprises continuous print image A, image B and image C, wherein, image A is the wherein two field picture chosen, here, can the shooting time of document image A, image B is the adjacent image of image A, is compared by this two frames adjacent image, if image B is identical with the picture material of image A, then image B can be set to target image.Image C is the adjacent image with image B, is compared by image C and image B, if image C is identical with the picture material of image B, then image C is target image; If image C is not identical with the picture material of image B, then image C is not target image.
Filter element 30 filters for the view data corresponding to target image, obtains the video data after filtering out target image.
Broadcast unit 40 is for playing the video data after filtering out target image.
Filter out the view data that target image is corresponding, namely filter out view data corresponding to image B in above-mentioned citing, obtain image A and image C, skip pictures B, playing image A and image C.Wherein, two adjacent images compare according to same sequence.Like this, after filtering out video data corresponding to target image, what obtain is the video data that continuous print picture material is not identical, plays the broadcasting that this video data can greatly reduce palinopsia audio data, thus reduces the consuming time of video playback.
Pass through the embodiment of the present invention, by loading video data to be played, target image is detected from video data, target image is the image that the content of the image be adjacent is identical, the view data corresponding to target image is filtered, obtain the video data after filtering out target image, play the video data after filtering out target image, owing to skipping the view data that content repeats in playing process, avoid playing and repeat identical image in a large number, solve the longer problem consuming time of the broadcasting of monitor video in prior art, reach the effect reducing the time that monitor video is play.And then reach the effect of quick browse video.
Fig. 5 is the schematic diagram according to the preferred video play device of the embodiment of the present invention.The video play device of this embodiment can be a kind of preferred implementation of the video play device of above-described embodiment.As shown in Figure 5, in this video play device, detecting unit 20 can comprise: compare subelement 201, judgment sub-unit 202 and chooser unit 203.
Relatively subelement 201 is for contrasting two two field pictures adjacent in video data, obtains comparing result.
Being contrasted by two two field pictures adjacent in video data, can be contrast the pixel of adjacent two two field pictures, can also be contrast the cryptographic Hash of adjacent two two field pictures.
In the video data to be played loaded, the first two field picture in two adjacent two field pictures can be chosen as benchmark image, another two field picture is the adjacent next frame image of benchmark image, then this two frames adjacent image is carried out the comparison of picture material, obtains comparing result.Wherein, two frame adjacent images compare according to same sequence.
Whether judgment sub-unit 202 is identical for judging the picture material of two adjacent two field pictures according to comparing result.
If chooser unit 203 is identical for judging the picture material of two adjacent two field pictures, then using the two field picture in two adjacent two field pictures as target image.
Target image can be any frame image in adjacent two two field pictures.Due to the image life period order that video capture obtains, therefore, can using the image of shooting rear in image adjacent for two identical for content frames as target image.Such as, using the image first taken as benchmark image, the next frame image of this benchmark image and this benchmark image are compared, whether the picture material that judgment standard image is adjacent next frame image is identical, if it is identical to judge that benchmark image is adjacent the picture material of next frame image, then using this next frame image as target image.
If it is not identical to judge that benchmark image is adjacent the picture material of next frame image, then preserve this next frame image.
The video data such as loaded comprises continuous print image A, image B and image C, wherein, image A is the first two field picture of shooting, using image A as benchmark image, image B is the adjacent image of image A, this two frames adjacent image is compared, if image B is identical with the picture material of image A, then image B can be set to target image.Image C is the adjacent image with image B, is compared by image C and image B, if image C is identical with the picture material of image B, then image C is target image; If image C is not identical with the picture material of image B, then image C is not target image, meanwhile, using image C as benchmark image.
Alternatively, in video display process, when the next frame image determining benchmark image is target image, can directly skip this image, using the adjacent image of the next frame image of target image as benchmark image, recycling benchmark image judges whether content repeats this image.Such as, in above-mentioned citing, after determining that image B is target image, then can skip pictures B, now, image A is adjacent with image C, then image C and image A can be contrasted.
A large amount of identical invalid vedio data effectively can be detected by said method, play the image information changed.
Preferably, in embodiments of the present invention, in this video play device, detecting unit 20 can also comprise: the first comparison module, the first judge module.Wherein, compare subelement 201 can comprise: the first comparison module; Judgment sub-unit 202 can comprise: the first judge module.
Relatively subelement 201 comprises: the first comparison module, on two more adjacent successively two field pictures, the pixel of same position, obtains pixel comparison result.
This first comparison module can be the further improvement to comparing subelement 201, particularly, in the video data loaded, the first two field picture in two adjacent two field pictures can be chosen as benchmark image, another two field picture is the adjacent next frame image of benchmark image, again these two adjacent images are carried out the comparison of the pixel of same position on image, obtain comparing result.Pixel is the base unit of image display, by the pixel of movement images same position, accurately can obtain comparing result.
Judgment sub-unit 202 comprises: the first judge module, whether all identical for judging the pixel of same position on two adjacent two field pictures according to pixel comparison result, wherein, if judge that the pixel of same position on two adjacent two field pictures is all identical, then determine that the picture material of two adjacent two field pictures is identical.
First judge module can be the further improvement to judgment sub-unit 202, and particularly, according to pixel comparison result, whether the pixel that judgment standard image is adjacent same position on next frame image is identical.
If it is all identical in the pixel of same position to judge that benchmark image is adjacent next frame image, then determine that the picture material of this adjacent two two field picture is identical.
If it is not all identical in the pixel of same position to judge that benchmark image is adjacent next frame image, then determine that the picture material of this adjacent two two field picture is not identical.
The video such as loaded comprises continuous print image A, image B and image C, wherein, image A is the first two field picture of shooting, using image A as benchmark image, image B is the adjacent image of image A, the pixel of this two frames adjacent image same position is compared, if image B is identical with the pixel of image A same position, then image B can be set to target image.Image C is the adjacent image with image B, and the pixel of image C and image B same position compared, if image C is identical with the pixel of image B same position, then image C is target image; If image C is not all identical with the pixel of image B same position, then image C is not target image, meanwhile, using image C as benchmark image.Then, regularly delete according to the time cycle of presetting the target image determined.
Effectively can filter out a large amount of identical invalid vedio data by said method, thus play the video data changed.
Preferably, in embodiments of the present invention, in this video play device, detecting unit 20 can also comprise: computing module, the second comparison module and the second judge module.Wherein compare subelement 201 to comprise: computing module, the second comparison module; Judgment sub-unit 202 comprises: the second judge module computing module.
Second comparison module, for the cryptographic Hash of two more adjacent two field pictures, obtains cryptographic Hash comparing result.
Computing module and the second comparison module can be the further improvement to comparing subelement.
Particularly, in the two adjacent two field pictures of video camera shooting, can choose the first two field picture in two adjacent two field pictures as benchmark image, another two field picture is the adjacent next frame image of benchmark image, again the cryptographic Hash of these two adjacent images is compared, obtain comparing result.Adopt Hash perception algorithm accurately can obtain comparing result rapidly.
Second judge module, for judging that according to cryptographic Hash comparing result whether the cryptographic Hash of two adjacent two field pictures is identical, wherein, if judge that the cryptographic Hash of two adjacent two field pictures is identical, then determines that the picture material of two adjacent two field pictures is identical.
If it is all identical to judge that benchmark image is adjacent the cryptographic Hash of next frame image, then determine that the picture material of this adjacent two two field picture is identical.
If it is not identical to judge that benchmark image is adjacent the cryptographic Hash of next frame image, then determine that the picture material of this adjacent two two field picture is not identical.
Preferably, in embodiments of the present invention, the computing module in video play device can comprise: preliminary treatment submodule, the first calculating sub module and the second calculating sub module.
Preliminary treatment submodule, for carrying out preliminary treatment to image in video data, obtains the image after processing.
This preliminary treatment can be by the video image minification of acquisition and be converted to gray level image.Such as, picture is narrowed down to after the same method the size of 8 × 8, altogether 64 pixels.Adopt the method, the details of picture can be removed, only retain the essential information such as structure, light and shade.
Simplify color, by the picture after reducing, transfer 64 grades of gray scales to.Also namely, all pixels only have 64 kinds of colors altogether.
First calculating sub module, for the average gray of the image after computing.
Calculate the average gray of all 64 pixels in pretreated video image.
Second calculating sub module, calculates cryptographic Hash for utilizing average gray.
The gray scale of compared pixels, by the gray scale of each pixel, compares with mean value.Be more than or equal to mean value, be designated as 1; Be less than mean value, be designated as 0.The comparison of the cryptographic Hash of adjacent two two field pictures is carried out again according to same sequence.
By the comparative result of previous step, combine, just constitute the integer of 64, the fingerprint of Here it is this pictures.The order of combination is unimportant, as long as ensure that all pictures all adopt same order.The picture size exported due to same CCTV camera, ratio are consistent.All process according to identical method in the image processing process such as minification, simplification color.Therefore the impact of whole processing procedure on cryptographic Hash can be ignored.
With the first two field picture loaded for benchmark image, obtained the cryptographic Hash of the first two field picture by above perception hash algorithm, calculate the cryptographic Hash of adjacent next frame picture.According to the cryptographic Hash of identical order benchmark picture and adjacent next frame image.
If the data value that the result compared shows every is all identical, then the picture of adjacent next frame is identical with reference base picture, directly abandons this picture and does not preserve.Again calculate the image cryptographic Hash of the adjacent next frame after abandoning image, and compare calculating by said method.
If the value in the result display data bit compared is different, then think that the picture of adjacent next frame is different from reference base picture, then using the picture of adjacent next frame as reference base picture, and preserve former picture.
The video such as loaded comprises continuous print image A, image B and image C, wherein, image A is the first two field picture of shooting, using image A as benchmark image, image B is the adjacent image of image A, the cryptographic Hash of this two frames adjacent image is compared, if image B is identical with image A cryptographic Hash, then image B can be set to target image.Image C is the adjacent image with image B, the cryptographic Hash of image C and image B is compared, if image C is identical with the cryptographic Hash of image B, then image C is target image; If image C is not identical with the cryptographic Hash of image B, then image C is not target image, meanwhile, using image C as benchmark image.
By the above description to video broadcasting method and device, the beneficial effect reached is: effectively can skip a large amount of identical invalid image data, plays the video data changed, reaches the effect of quick browse video.
It should be noted that, for aforesaid each embodiment of the method, in order to simple description, therefore it is all expressed as a series of combination of actions, but those skilled in the art should know, the present invention is not by the restriction of described sequence of movement, because according to the present invention, some step can adopt other orders or carry out simultaneously.Secondly, those skilled in the art also should know, the embodiment described in specification all belongs to preferred embodiment, and involved action and module might not be that the present invention is necessary.
In the above-described embodiments, the description of each embodiment is all emphasized particularly on different fields, in certain embodiment, there is no the part described in detail, can see the associated description of other embodiments.
In several embodiments that the application provides, should be understood that, disclosed device, the mode by other realizes.Such as, device embodiment described above is only schematic, the such as division of described unit, be only a kind of logic function to divide, actual can have other dividing mode when realizing, such as multiple unit or assembly can in conjunction with or another system can be integrated into, or some features can be ignored, or do not perform.Another point, shown or discussed coupling each other or direct-coupling or communication connection can be by some interfaces, and the indirect coupling of device or unit or communication connection can be electrical or other form.
The described unit illustrated as separating component or can may not be and physically separates, and the parts as unit display can be or may not be physical location, namely can be positioned at a place, or also can be distributed in multiple network element.Some or all of unit wherein can be selected according to the actual needs to realize the object of the present embodiment scheme.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, also can be that the independent physics of unit exists, also can two or more unit in a unit integrated.Above-mentioned integrated unit both can adopt the form of hardware to realize, and the form of SFU software functional unit also can be adopted to realize.
If described integrated unit using the form of SFU software functional unit realize and as independently production marketing or use time, can be stored in a computer read/write memory medium.Based on such understanding, the part that technical scheme of the present invention contributes to prior art in essence in other words or all or part of of this technical scheme can embody with the form of software product, this computer software product is stored in a storage medium, comprises all or part of step of some instructions in order to make a computer equipment (can be personal computer, mobile terminal, server or the network equipment etc.) perform method described in each embodiment of the present invention.And aforesaid storage medium comprises: USB flash disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), portable hard drive, magnetic disc or CD etc. various can be program code stored medium.
The foregoing is only the preferred embodiments of the present invention, be not limited to the present invention, for a person skilled in the art, the present invention can have various modifications and variations.Within the spirit and principles in the present invention all, any amendment done, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1. a video broadcasting method, is characterized in that, comprising:
Load video data to be played, described video data comprises the view data of shooting continuously;
From described video data, detect target image, described target image is the image that the content of the image be adjacent is identical;
The view data corresponding to described target image is filtered, and obtains the video data after filtering out described target image; And
The video data after described target image is filtered out described in broadcasting.
2. video broadcasting method according to claim 1, is characterized in that, detects target image and comprise from described video data:
Two two field pictures adjacent in described video data are contrasted, obtains comparing result;
Judge that whether the picture material of described two adjacent two field pictures is identical according to described comparing result;
If judge that the picture material of described two adjacent two field pictures is identical, then using the two field picture in described two adjacent two field pictures as described target image.
3. video broadcasting method according to claim 2, is characterized in that,
Two two field pictures adjacent in described video data are contrasted, obtain comparing result and comprise: the pixel of same position on more described two adjacent two field pictures successively, obtains pixel comparison result,
Judge that whether the picture material of described two adjacent two field pictures is identical according to comparing result to comprise: judge that whether the pixel of same position on described two adjacent two field pictures is all identical according to described pixel comparison result, wherein, if judge that the pixel of same position on described two adjacent two field pictures is all identical, then determine that the picture material of described two adjacent two field pictures is identical.
4. video broadcasting method according to claim 2, is characterized in that,
Two two field pictures adjacent in described video data are contrasted, obtains comparing result and comprise: utilize perception hash algorithm to calculate the cryptographic Hash of image in described video data; The cryptographic Hash of more described two adjacent two field pictures, obtains cryptographic Hash comparing result,
Judge that whether the picture material of described two adjacent two field pictures is identical according to comparing result to comprise: judge that whether the cryptographic Hash of described two adjacent two field pictures is identical according to described cryptographic Hash comparing result, wherein, if judge that the cryptographic Hash of described two adjacent two field pictures is identical, then determine that the picture material of described two adjacent two field pictures is identical.
5. video broadcasting method according to claim 4, is characterized in that, the cryptographic Hash utilizing perception hash algorithm to calculate image in described video data comprises:
Preliminary treatment is carried out to image in described video data, obtains the image after processing;
Calculate the average gray of the image after described process; And
Described average gray is utilized to calculate described cryptographic Hash.
6. a video play device, is characterized in that, comprising:
Loading unit, for loading video data to be played, described video data comprises the view data of shooting continuously;
Detecting unit, for detecting target image from described video data, described target image is the image that the content of the image be adjacent is identical;
Filter element, filters for the view data corresponding to described target image, obtains the video data after filtering out described target image; And
Broadcast unit, filters out the video data after described target image described in playing.
7. video play device according to claim 6, is characterized in that, described detecting unit comprises:
Relatively subelement, for being contrasted by two two field pictures adjacent in described video data, obtains comparing result;
Whether judgment sub-unit is identical for judging the picture material of described two adjacent two field pictures according to described comparing result; And
Chooser unit, if identical for judging the picture material of described two adjacent two field pictures, then using the two field picture in described two adjacent two field pictures as described target image.
8. video play device according to claim 7, is characterized in that,
The described subelement that compares comprises: the first comparison module, and on more described two adjacent two field pictures successively, the pixel of same position, obtains pixel comparison result,
Described judgment sub-unit comprises: the first judge module, for judging that according to described pixel comparison result whether the pixel of same position on described two adjacent two field pictures is all identical, wherein, if judge that the pixel of same position on described two adjacent two field pictures is all identical, then determine that the picture material of described two adjacent two field pictures is identical.
9. video play device according to claim 7, is characterized in that,
The described subelement that compares comprises: computing module, for the cryptographic Hash utilizing perception hash algorithm to calculate image in described video data; Second comparison module, for the cryptographic Hash of more described two adjacent two field pictures, obtains cryptographic Hash comparing result,
Described judgment sub-unit comprises: the second judge module, for judging that according to described cryptographic Hash comparing result whether the cryptographic Hash of described two adjacent two field pictures is identical, wherein, if judge that the cryptographic Hash of described two adjacent two field pictures is identical, then determine that the picture material of described two adjacent two field pictures is identical.
10. video play device according to claim 9, is characterized in that, described computing module comprises:
Preliminary treatment submodule, for carrying out preliminary treatment to image in described video data, obtains the image after processing;
First calculating sub module, for calculating the average gray of the image after described process; And
Second calculating sub module, calculates described cryptographic Hash for utilizing described average gray.
CN201410662504.XA 2014-11-18 2014-11-18 Video broadcasting method and device Active CN104469289B (en)

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 true CN104469289A (en) 2015-03-25
CN104469289B 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)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104936021A (en) * 2015-06-02 2015-09-23 无锡天脉聚源传媒科技有限公司 Video play monitoring method and apparatus

Citations (4)

* Cited by examiner, † Cited by third party
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

Patent Citations (5)

* Cited by examiner, † Cited by third party
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

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104936021A (en) * 2015-06-02 2015-09-23 无锡天脉聚源传媒科技有限公司 Video play monitoring method and apparatus

Also Published As

Publication number Publication date
CN104469289B (en) 2019-01-15

Similar Documents

Publication Publication Date Title
CN104469229A (en) Video data storing method and device
US10579669B2 (en) System, apparatus, method, program and recording medium for processing image
US20200005468A1 (en) Method and system of event-driven object segmentation for image processing
KR101512584B1 (en) Limited-context-based identifying key frame from video sequence
US9514225B2 (en) Video recording apparatus supporting smart search and smart search method performed using video recording apparatus
EP1986193B1 (en) Method of displaying moving image and image playback apparatus to display the same
US8723935B2 (en) Image processing device, computer readable storage medium storing image processing program and image processing method
GB2431793A (en) Image comparison
CN107483859B (en) Security monitoring video storage and playback method capable of rapidly calling security event pictures
US8340412B2 (en) Image processing
US6434320B1 (en) Method of searching recorded digital video for areas of activity
CN108632666B (en) Video detection method and video detection equipment
CN103826109A (en) Video monitoring image data processing method and system
CN102333174A (en) Video image processing method and device for the same
US20110064319A1 (en) Electronic apparatus, image display method, and content reproduction program
CN105635667B (en) Method and apparatus for visualization digital Video stream information
CN106603885B (en) Method of video image processing and device
US10565469B2 (en) Apparatus and method for processing images and storage medium
CN104469289A (en) Video playing method and device
CN109543628B (en) Face unlocking method, bottom library inputting method, device and electronic equipment
CN112926385A (en) Video processing method of monitoring equipment and related product
KR102108618B1 (en) Method of searching crime using video synopsis
CN116193049A (en) Video processing method, device, computer equipment and storage medium
US10165223B2 (en) Pre-selectable video file playback system and method, and computer program product
JP2000244849A (en) Representative image selecting arrangement and image reproducing device

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