CN109309869A - A kind of watermark embedding method, device and storage medium - Google Patents
A kind of watermark embedding method, device and storage medium Download PDFInfo
- Publication number
- CN109309869A CN109309869A CN201811058778.2A CN201811058778A CN109309869A CN 109309869 A CN109309869 A CN 109309869A CN 201811058778 A CN201811058778 A CN 201811058778A CN 109309869 A CN109309869 A CN 109309869A
- Authority
- CN
- China
- Prior art keywords
- watermark
- embedded
- value
- image
- extracted
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 49
- 239000000284 extract Substances 0.000 claims abstract description 16
- 238000003780 insertion Methods 0.000 claims description 27
- 230000037431 insertion Effects 0.000 claims description 27
- 238000000605 extraction Methods 0.000 claims description 17
- 238000012545 processing Methods 0.000 claims description 11
- XLYOFNOQVPJJNP-UHFFFAOYSA-N water Substances O XLYOFNOQVPJJNP-UHFFFAOYSA-N 0.000 claims description 8
- 238000010586 diagram Methods 0.000 description 18
- 230000015654 memory Effects 0.000 description 15
- 230000006854 communication Effects 0.000 description 5
- 238000012935 Averaging Methods 0.000 description 4
- 230000008859 change Effects 0.000 description 4
- 238000004891 communication Methods 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 4
- 230000006870 function Effects 0.000 description 4
- 238000004590 computer program Methods 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 2
- 230000008878 coupling Effects 0.000 description 2
- 230000008569 process Effects 0.000 description 2
- 238000010276 construction Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 235000013372 meat Nutrition 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000005192 partition Methods 0.000 description 1
- 238000007639 printing Methods 0.000 description 1
- 238000003672 processing method Methods 0.000 description 1
- 238000000926 separation method Methods 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
- 201000009032 substance abuse Diseases 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
- H04N21/44—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/20—Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
- H04N21/23—Processing of content or additional data; Elementary server operations; Server middleware
- H04N21/234—Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/80—Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
- H04N21/83—Generation or processing of protective or descriptive data associated with content; Content structuring
- H04N21/835—Generation of protective data, e.g. certificates
- H04N21/8358—Generation of protective data, e.g. certificates involving watermark
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Editing Of Facsimile Originals (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
- Image Processing (AREA)
Abstract
This application provides a kind of watermark embedding method, device and storage mediums, wherein this method comprises: obtaining watermark video to be embedded;The same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded.The embodiment of the present application is by that after frame loss occurs for video, based on the multiple image of redundant embedding watermark, still can extract complete watermark, to reduce influence of the frame loss to watermark extracting in the multiple image of watermark redundant embedding video.
Description
Technical field
This application involves technical field of multimedia information, more particularly, to a kind of watermark embedding method, device and deposit
Storage media.
Background technique
With the rapid development of cybertimes, video is faced with further serious as most intuitive, most efficient transmitting carrier
Piracy, illegal the abuses such as to propagate, to protect its copyright problem, video watermark technology is come into being.
But video inevitably can be there is a situation where frame loss, when frame loss occurs for video, in video in communication process
The watermark information of insertion is also no longer complete therewith, will lead to watermark when the video based on the generation frame loss carries out watermark extracting
Failure is extracted, the copyright of video also can not be just effectively protected in watermark.
Summary of the invention
In view of this, the application's is designed to provide a kind of watermark embedding method, device and storage medium, to reduce frame
Lose the influence to watermark information.
In a first aspect, the embodiment of the present application provides a kind of watermark embedding method, wherein include:
Obtain watermark video to be embedded;
The same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded.
With reference to first aspect, the embodiment of the present application provides the first possible embodiment of first aspect, wherein will
The same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded, comprising:
Every frame image averaging in the continuous multiple frames image is divided into multiple watermark regions to be embedded;
The same position watermark value of the watermark is embedded in the same watermark region to be embedded of the continuous multiple frames image.
The possible embodiment of with reference to first aspect the first, the embodiment of the present application provide second of first aspect
Possible embodiment, wherein the same position watermark value of the watermark is embedded in the same to embedding of the continuous multiple frames image
Enter watermark region, comprising:
Watermark block to be embedded is obtained to the watermark region piecemeal to be embedded according to presetted pixel value;
According to the coordinate of the watermark block to be embedded and the embedment strength coefficient of the watermark block to be embedded, it is calculated
The watermark stencil value of the watermark block to be embedded;
Based on the watermark stencil value, the watermark value in the watermark is embedded in the watermark block to be embedded.
The possible embodiment of second with reference to first aspect, the embodiment of the present application provide the third of first aspect
Possible embodiment, wherein the continuous multiple frames figure being embedded in the same position watermark value of watermark in the watermark video to be embedded
As in, comprising:
Described in the order being located in the continuous multiple frames image according to current frame image and the watermark block to be embedded
The watermark value in the watermark is embedded in the watermark block to be embedded by watermark stencil value.
The third possible embodiment with reference to first aspect, the embodiment of the present application provide the 4th kind of first aspect
Possible embodiment, wherein the continuous multiple frames figure being embedded in the same position watermark value of watermark in the watermark video to be embedded
As in, comprising:
The brightness change trend of the continuous multiple frames image is determined according to the watermark value;
It is located at the order in the continuous multiple frames image according to current frame image and determines that the current frame image uses watermark
The intensity of stencil value;
According to the brightness change trend of the continuous multiple frames image, by the watermark stencil value of respective strengths and it is described to
It is embedded in the brightness value superposition of watermark block.
The third possible embodiment with reference to first aspect, the embodiment of the present application provide the 5th kind of first aspect
Possible embodiment, wherein order in the continuous multiple frames image and described to be embedded is located at according to current frame image
The watermark value in the watermark is embedded in the watermark block to be embedded by the watermark stencil value of watermark block, comprising:
From the watermark video to be embedded, continuous 8 frame image is intercepted;
When the current frame image is located at preceding 4 frame in the continuous 8 frame image, the brightness value of the watermark block to be embedded
It is added with the watermark stencil value, the block after obtaining insertion watermark value;
When the current frame image is located at rear 4 frame in the continuous 8 frame image, the brightness value of the watermark block to be embedded
Subtract each other with the watermark stencil value, the block after obtaining insertion watermark value.
Second aspect, the embodiment of the present application also provide a kind of watermark extracting method, wherein include:
Obtain watermark video to be extracted;
The same position watermark value of watermark is extracted from the continuous multiple frames image of the watermark video to be extracted;
The watermark value is formed into watermark value sequence, and then obtains watermark.
In conjunction with second aspect, the embodiment of the present application provides the first possible embodiment of second aspect, wherein from
The same position watermark value of watermark is extracted in the continuous multiple frames image of the watermark video to be extracted, comprising:
Every frame image averaging in the continuous multiple frames image is divided into multiple watermark regions to be extracted;
The same position watermark value of the watermark is extracted from the same watermark region to be extracted of the continuous multiple frames image.
In conjunction with the first possible embodiment of second aspect, the embodiment of the present application provides second of second aspect
Possible embodiment, wherein extract the same of the watermark from the same watermark region to be extracted of the continuous multiple frames image
One watermark value, comprising:
By comparing the brightness value of the same watermark region to be extracted of consecutive frame image in the multiple image, mention
Take the watermark value.
In conjunction with the first possible embodiment of second aspect, the embodiment of the present application provides the third of second aspect
Possible embodiment, wherein extract the same of the watermark from the same watermark region to be extracted of the continuous multiple frames image
One watermark value, comprising:
By comparing 1/4th area of centre of the same watermark region to be extracted of consecutive frame image in the multiple image
The brightness value in domain extracts the watermark value.
In conjunction with second of possible embodiment of second aspect, the embodiment of the present application provides the 5th kind of second aspect
Possible embodiment, wherein by comparing the same watermark areas to be extracted of consecutive frame image in the multiple image
The brightness value in domain extracts the watermark value, comprising:
The number that former frame brightness value is greater than a later frame brightness value in the adjacent two field pictures is denoted as A, former frame brightness
The number that value is less than a later frame brightness value is denoted as B;
When A is greater than B, the watermark value of extraction is -1, and when A is less than B, the watermark value of extraction is 1.
The third aspect, the embodiment of the present application also provide a kind of watermark embedding device, wherein include:
First acquisition module, for obtaining watermark video to be embedded;
It is embedded in module, the continuous multiple frames figure for being embedded in the same position watermark value of watermark in the watermark video to be embedded
As in.
Fourth aspect, the embodiment of the present application also provide a kind of watermark extraction apparatus, wherein include:
Second acquisition module, for obtaining watermark video to be extracted;
Extraction module, for extracting the same position watermark of watermark from the continuous multiple frames image of the watermark video to be extracted
Value;
Processing module for the watermark value to be formed watermark value sequence, and then obtains watermark.
5th aspect, the embodiment of the present application also provide a kind of system for processing watermark, wherein include:
Watermark embedding device, it is for obtaining watermark video to be embedded, the same position watermark value insertion of watermark is described to embedding
Enter in the continuous multiple frames image in watermark video;
Watermark extraction apparatus, for obtaining watermark video to be extracted, from the continuous multiple frames figure of the watermark video to be extracted
The watermark value is formed watermark value sequence by the same position watermark value that watermark is extracted as in.
A kind of watermark embedding method, device and storage medium provided by the embodiments of the present application, when being embedded in watermark, by watermark
It is embedded in the multiple image of video, and then when extracting watermark, watermark can be extracted based on the multiple image of video.With
The relevant technologies can not extract watermark and compare, by the way that watermark redundancy is embedding when the missing of watermark caused by frame loss occurs for video
Enter in the multiple image of video, after frame loss occurs for video, based on the multiple image of redundant embedding watermark, still can extract
Complete watermark, to reduce influence of the frame loss to watermark extracting.
To enable the above objects, features, and advantages of the application to be clearer and more comprehensible, preferred embodiment is cited below particularly, and cooperate
Appended attached drawing, is described in detail below.
Detailed description of the invention
Technical solution in ord to more clearly illustrate embodiments of the present application, below will be to needed in the embodiment attached
Figure is briefly described, it should be understood that the following drawings illustrates only some embodiments of the application, therefore is not construed as pair
The restriction of range for those of ordinary skill in the art without creative efforts, can also be according to this
A little attached drawings obtain other relevant attached drawings.
Fig. 1 shows a kind of flow chart of watermark embedding method provided by the embodiment of the present application;
Fig. 2 shows the schematic diagrames of the insertion of watermark provided by the embodiment of the present application;
Fig. 3 shows the schematic diagram of watermark region to be embedded provided by the embodiment of the present application;
Fig. 4 shows the schematic diagram of watermark block to be embedded provided by the embodiment of the present application;
Fig. 5 shows the schematic diagram that continuous multiple frames image provided by the embodiment of the present application is embedded in same position watermark value;
Fig. 6 shows a kind of flow chart of watermark extracting method provided by the embodiment of the present application;
Fig. 7 shows a kind of schematic diagram of watermark extracting method provided by the embodiment of the present application;
Fig. 8 shows a kind of module diagram of watermark embedding device provided by the embodiment of the present application;
Fig. 9 shows a kind of module diagram of watermark extraction apparatus provided by the embodiment of the present application;
Figure 10 shows a kind of module diagram of system for processing watermark provided by the embodiment of the present application;
Figure 11 shows the hardware knot that a kind of electronic equipment of watermark embedding method is executed provided by the embodiment of the present application
The schematic diagram of structure.
Specific embodiment
To keep the purposes, technical schemes and advantages of the embodiment of the present application clearer, below in conjunction with the embodiment of the present application
Middle attached drawing, the technical scheme in the embodiment of the application is clearly and completely described, it is clear that described embodiment is only
It is some embodiments of the present application, instead of all the embodiments.The application being usually described and illustrated herein in the accompanying drawings is real
The component for applying example can be arranged and be designed with a variety of different configurations.Therefore, below to the application's provided in the accompanying drawings
The detailed description of embodiment is not intended to limit claimed scope of the present application, but is merely representative of the selected reality of the application
Apply example.Based on embodiments herein, those skilled in the art institute obtained without making creative work
There are other embodiments, shall fall in the protection scope of this application.
In view of the relevant technologies are when the missing of watermark caused by frame loss occurs for video, watermark can not be extracted, this is based on, this
Application embodiment provides a kind of watermark embedding method, device and storage medium, is described below by embodiment.
For convenient for understanding the present embodiment, first to a kind of watermark embedding method disclosed in the embodiment of the present application into
Row is discussed in detail.
Embodiment one
Fig. 1 is a kind of flow chart of watermark embedding method provided by the embodiments of the present application, as shown in Figure 1, watermark insertion side
Method the following steps are included:
S110, watermark video to be embedded is obtained;
S120, the same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded.
Specifically, Fig. 2 is the schematic diagram of watermark provided by the embodiments of the present application insertion, pass through load data as shown in Figure 2
Etc. modes, obtain watermark video to be embedded, the watermark video to be embedded be decoded into yuv data, extracts the Y in yuv data
Data form watermarking images sequence to be embedded as watermarking images to be embedded.Watermark character is processed into binary watermarking, by two
The watermark bit that gray value is 0 in value watermark is set as -1, and the watermark bit that gray value is 255 is set as 1.
According to pixel specification be 32 × 32 points for several pieces by watermarking images to be embedded, then by each pixel specification be 32 ×
32 block is divided into the block that 16 pixel specifications are 8 × 8, the block for being 8 × 8 using each plain specification as calculating watermark stencil value most
Subsection, i.e., watermark block to be embedded.It finds out the DC coefficient of each watermark block to be embedded and calculates 16 watermark block DC to be embedded
The average value of coefficient, the mean value calculation based on the DC coefficient of watermark block to be embedded and 16 watermark block DC coefficients to be embedded go out
The watermark stencil value of each watermark block to be embedded.
According to preset frame number, from watermarking images sequence to be embedded, continuous multiple frames image is intercepted, to continuous multiple frames video
The same position watermark value of each frame image insertion watermark in image, the image after obtaining insertion watermark value.According to watermark digit
Length, watermark value is embedded in multistage continuous multiple frames image, until whole watermark values of watermark are embedded in.
Image U, V data corresponding with the image after being embedded in watermark value merge, and are as embedded in the image after watermark.This
Invention is implicit insertion watermark, and the image before watermark can not be differentiated and be embedded in the image naked eyes after being embedded in watermark has what to distinguish.
In the embodiment of the present application, watermark size does not limit in principle, but its size determines watermarked frame to be embedded
The size of several length, watermark is bigger, and the frame number of the watermark to be embedded needed is more.
Using the method for the embodiment of the present application, by occurring in video by the multiple image of watermark redundant embedding video
After frame loss, based on the multiple image of redundant embedding watermark, complete watermark still can be extracted, to reduce frame loss to water
Print the influence extracted.
Optionally, the same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded,
Include:
Every frame image averaging in the continuous multiple frames image is divided into multiple watermark regions to be embedded;
The same position watermark value of the watermark is embedded in the same watermark region to be embedded of the continuous multiple frames image.
Specifically, Fig. 3 is the schematic diagram of watermark region to be embedded provided by the embodiments of the present application, as shown in figure 3, the application
It selects dimensions for 16 × 16 watermark in embodiment, watermarking images to be embedded is equally divided into four watermark areas to be embedded
Domain, a watermark value of each of watermarking images to be embedded watermark region insertion watermark to be embedded, i.e., every frame watermark to be embedded
Image can be embedded in 4 different watermark values.
For example, watermarking images to be embedded are equally divided into four watermark regions to be embedded, to the watermark to be embedded of every frame
First watermark value 1 of the first watermark region to be embedded insertion watermark in image, into every frame watermarking images to be embedded second to
It is embedded in second watermark value -1 of watermark region insertion watermark, the third watermark region to be embedded into every frame watermarking images to be embedded
It is embedded in third position watermark value -1 of watermark, the of 4th watermark region to be embedded insertion watermark into every frame watermarking images to be embedded
Four watermark values 1.
Optionally, the same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded,
Include:
According to presetted pixel value, piecemeal is carried out to the watermark region to be embedded, obtains watermark block to be embedded;
According to the coordinate of the watermark block to be embedded and the embedment strength coefficient of the watermark block to be embedded, it is calculated
The watermark stencil value of the watermark block to be embedded;
Based on the watermark stencil value, the watermark value in the watermark is embedded in the watermark block to be embedded.
Specifically, Fig. 4 is the schematic diagram of watermark block to be embedded provided by the embodiments of the present application, as shown in figure 4, by be embedded
The watermark region to be embedded of watermarking images is divided into several pieces according to 32 × 32 specification of pixel, then each 32 × 32 block is divided into 16
A 8 × 8 block, each 8 × 8 block is as the minimum unit for calculating watermark stencil value, i.e., watermark block to be embedded.Find out it is each to
It is embedded in the DC coefficient of watermark block and calculates the average value of 16 watermark block DC coefficients to be embedded, be based on each watermark to be embedded
The mean value calculation of the DC coefficient of block and 16 watermark block DC coefficients to be embedded goes out the watermark template of each watermark block to be embedded
Value.
Wherein seek the formula of DC coefficient are as follows:
The formula averaged are as follows:
Calculate the formula of each watermark block watermark stencil value to be embedded are as follows:
Wherein, i indicates that the frame number that watermark block to be embedded is located in continuous multiple frames image, M indicate the length of watermark block to be embedded
Degree, N indicate that the width of watermark block to be embedded, x indicate that the abscissa of watermark block to be embedded, y indicate the vertical seat of watermark block to be embedded
Mark, tx,yIndicate the embedment strength coefficient of watermark block to be embedded,Indicate embedment strength constant, value 0.649.
Optionally, the same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded,
Include:
Described in the order being located in the continuous multiple frames image according to current frame image and the watermark block to be embedded
The watermark value in the watermark is embedded in the watermark block to be embedded by watermark stencil value.
Optionally, the brightness change trend of the continuous multiple frames image is determined according to the watermark value;
It is located at the order in the continuous multiple frames image according to current frame image and determines that the current frame image uses watermark
The intensity of stencil value;
According to the brightness change trend of the continuous multiple frames image, by the watermark stencil value of respective strengths and it is described to
It is embedded in the brightness value superposition of watermark block.
Optionally, order and the watermark block to be embedded being located at according to current frame image in the continuous multiple frames image
The watermark stencil value, the watermark value in the watermark is embedded in the watermark block to be embedded, comprising:
From the watermark video to be embedded, continuous 8 frame image is intercepted;
When the current frame image is located at preceding 3 frame in the continuous 8 frame image, the brightness value of the watermark block to be embedded
It is added with the watermark stencil value, the block after obtaining insertion watermark value;
When the current frame image is located at rear 4 frame in the continuous 8 frame image, the brightness value of the watermark block to be embedded
Subtract each other with the watermark stencil value, the block after obtaining insertion watermark value.
Specifically, Fig. 5 is the schematic diagram that continuous multiple frames image provided by the embodiments of the present application is embedded in same position watermark value, such as
Shown in Fig. 5, continuous 8 frame watermark to be embedded is extracted from watermarking images sequence to be embedded, when what is be embedded in the watermark block to be embedded
When the watermark value of watermark is 1, insertion watermark rule is as follows:
When current frame image is the 1st frame image or the 2nd frame image of continuous 8 frame image, the brightness of the watermark block to be embedded
Value adds the watermark stencil value of 2 times of watermark blocks to be embedded;It, should be to when current frame image is the 3rd frame image of continuous 8 frame image
The brightness value for being embedded in watermark block adds the watermark stencil value of the watermark block to be embedded;Current frame image is the 4 of continuous 8 frame image
When frame image, the brightness value of the watermark block to be embedded adds 0 times of watermark block of the watermark stencil value to be embedded, the i.e. water to be embedded
The brightness value for printing block is constant;When current frame image is the 5th frame image of continuous 8 frame image, the brightness value of the watermark block to be embedded
Subtract the watermark stencil value of the watermark block to be embedded;When current frame image is the 6th frame image of continuous 8 frame image, this is to be embedded
The brightness value of watermark block subtracts the watermark stencil value of 2 times of watermark blocks to be embedded;Current frame image is the 7 of continuous 8 frame image
When frame image or the 8th frame image, the brightness value of the watermark block to be embedded subtracts the watermark stencil value of 3 times of watermark blocks to be embedded.
When the watermark value for the watermark being embedded in the watermark block to be embedded is -1, insertion watermark rule is as follows:
When current frame image is the 1st frame image or the 2nd frame image of continuous 8 frame image, the brightness of the watermark block to be embedded
Value adds the watermark stencil value of -2 times of watermark blocks to be embedded;It, should when current frame image is the 3rd frame image of continuous 8 frame image
The brightness value of watermark block to be embedded adds the watermark stencil value of -1 times of watermark block to be embedded;Current frame image is continuous 8 frame figure
When the 4th frame image of picture, the brightness value of the watermark block to be embedded is constant;Current frame image is the 5th frame image of continuous 8 frame image
When, the brightness value of the watermark block to be embedded subtracts the watermark stencil value of -1 times of watermark block to be embedded;Current frame image is continuous 8
When the 6th frame image of frame image, the brightness value of the watermark block to be embedded subtracts the watermark stencil value of -2 times of watermark blocks to be embedded;
When current frame image is the 7th frame image or the 8th frame image of continuous 8 frame image, the brightness value of the watermark block to be embedded subtracts -3
The watermark stencil value of the watermark block to be embedded again.
By the above-mentioned means, watermark value is embedded in multistage continuous multiple frames image according to the length of watermark digit, until by water
Whole watermark values of print are embedded in, the image after obtaining insertion watermark value, and the image after insertion watermark value is corresponding with the image
U, V data merge, and the image after obtaining insertion watermark is embedded in the video after watermark by the image construction after insertion watermark.Pass through
Screen recording software, the full frame video recorded after the insertion watermark generated, the video after saving recorded broadcast is AVI format.If when
Between it is inconsistent, that is, need to be embedded in a segment sync watermark information position.The present invention is implicit insertion watermark, the image meat after being embedded in watermark
What the image that eye can not differentiate and be embedded in front of watermark has distinguish.
Embodiment two
Fig. 6 is a kind of flow chart of watermark extracting method provided by the embodiments of the present application, as shown in fig. 6, watermark extracting side
Method the following steps are included:
S210, watermark video to be extracted is obtained;
S220, the same position watermark value that watermark is extracted from the continuous multiple frames image of the watermark video to be extracted;
S230, the watermark value is formed into watermark value sequence, and then obtains watermark.
Specifically, Fig. 7 is a kind of schematic diagram of watermark extracting method provided by the embodiments of the present application, as shown in fig. 7, obtaining
Watermark video to be extracted after detecting the synchronization watermarking information bit in watermark video to be extracted, starts to extract watermark.It decodes wait mention
Watermark video is taken, the yuv data of watermark video to be extracted is obtained, extracts Y data as watermarking images to be extracted, and form wait mention
Water intaking watermark image sequence.According to preset frame number, from watermarking images sequence to be extracted, continuous multiple frames image is intercepted, from continuous
The same position watermark value of each frame image zooming-out watermark in multi-frame video image, using aforesaid way, according to extraction watermark bit
Several length extracts whole watermark values of watermark from watermarking images sequence to be extracted, forms watermark value sequence, and then according to water
Print sequence obtains watermark.
Using the method for the embodiment of the present application, by occurring in video by the multiple image of watermark redundant embedding video
After frame loss, based on the multiple image of redundant embedding watermark, complete watermark still can be extracted, to reduce frame loss to water
Print the influence extracted.
Optionally, the same position watermark value of watermark, packet are extracted from the continuous multiple frames image of the watermark video to be extracted
It includes:
Every frame image averaging in the continuous multiple frames image is divided into multiple watermark regions to be extracted;
The same position watermark value of the watermark is extracted from the same watermark region to be extracted of the continuous multiple frames image.
Specifically, watermarking images to be extracted are equally divided into four watermark regions to be extracted, watermarking images to be extracted it is every
One watermark region to be extracted extracts a watermark value of watermark, i.e., every frame watermarking images to be extracted can extract 4 it is different
Watermark value.
Optionally, the same position water of the watermark is extracted from the same watermark region to be extracted of the continuous multiple frames image
Print value, comprising:
By comparing the brightness value of the same watermark region to be extracted of consecutive frame image in the multiple image, mention
Take the watermark value.
Optionally, in the same watermark region to be extracted by comparing consecutive frame image in the multiple image
Between 1/4 region brightness value, extract the watermark value.
Optionally, by comparing in the multiple image the same watermark region to be extracted of consecutive frame image it is bright
Angle value extracts the watermark value, comprising:
The number that previous frame image brightness value is greater than a later frame image brightness values in the adjacent two field pictures is denoted as M, preceding
The number that one frame image brightness values are less than a later frame image brightness values is denoted as N.
When M is greater than N, the watermark value of extraction is -1, and when M is less than N, the watermark value of extraction is 1.
Specifically, intercepting continuous 8 frame watermark to be extracted from watermarking images sequence to be extracted, it is to be extracted to choose continuous 8 frame
The 2nd frame image to the 6th frame image in watermarking images carries out watermark extracting.Above-mentioned 5 frame watermarking images to be extracted are equally divided into
Four watermark regions to be extracted calculate the luminance mean value in 1/4 region among each watermark region to be extracted, such as watermark areas to be extracted
The length in domain is j, width k, then taking J/2 is the length in 1/4 region of centre, and taking k/2 is the width in 1/4 region of centre,
Determine one with watermark region to be extracted with midpoint quadrangle as 1/4 region of centre.The luminance mean value is right as its
The brightness value for the watermark region to be extracted answered.
The brightness value of the same watermark region to be extracted of more adjacent two field pictures, by former frame in adjacent two field pictures
The number that the watermark region brightness value to be extracted of image is greater than the watermark region brightness value to be extracted of a later frame image is denoted as A, preceding
The number that the watermark region brightness value to be extracted of one frame image is less than the watermark region brightness value to be extracted of a later frame image is denoted as
B determines that the watermark value of the watermark region to be extracted is -1, when A is less than B, determines the watermark region to be extracted when A is greater than B
Watermark value be 1.
Using aforesaid way, according to the length for extracting watermark digit, watermark is extracted from watermarking images sequence to be extracted
Whole watermark values form watermark value sequence, and then obtain watermark according to watermark sequence.
Based on the same technical idea, the embodiment of the present application also provides a kind of watermark embedding device, a kind of watermark extracting dress
It sets, a kind of system for processing watermark, electronic equipment and computer storage medium etc., for details, reference can be made to following embodiments.
Embodiment three
Fig. 8 is a kind of module diagram of watermark embedding device provided by the embodiments of the present application, as shown in figure 8, watermark is embedding
Entering device includes:
First acquisition module 310, for obtaining watermark video to be embedded;
It is embedded in module 320, it is continuous more in the watermark video to be embedded for the same position watermark value of watermark to be embedded in
In frame image.
Example IV
Fig. 9 is a kind of module diagram of watermark extraction apparatus provided by the embodiments of the present application, as shown in figure 9, watermark mentions
The device is taken to include:
Second acquisition module 410, for obtaining watermark video to be extracted;
Extraction module 420, for extracting the same position of watermark from the continuous multiple frames image of the watermark video to be extracted
Watermark value;
Processing module 430, for the watermark value to be formed watermark value sequence.
Embodiment five
Figure 10 is a kind of module diagram of system for processing watermark provided by the embodiments of the present application, as shown in Figure 10, watermark
Processing system includes:
Watermark embedding device 300, for obtaining watermark video to be embedded, by the insertion of the same position watermark value of watermark it is described to
It is embedded in the continuous multiple frames image in watermark video;
Watermark extraction apparatus 400, for obtaining watermark video to be extracted, from the continuous multiple frames of the watermark video to be extracted
The watermark value is formed watermark value sequence by the same position watermark value that watermark is extracted in image.
Embodiment six
Figure 11 shows a kind of hardware configuration of the electronic equipment provided by the embodiments of the present application for executing watermark embedding method
Schematic diagram, as shown in figure 11, which includes:
One or more processors 610 and memory 620, in Figure 11 by taking a processor 610 as an example.
Processor 610 can be connected with memory 620 by bus or other modes, to be connected by bus in Figure 11
For.
Memory 620 is used as a kind of non-volatile computer readable storage medium storing program for executing, can be used for storing non-volatile software journey
Sequence, non-volatile computer executable program and module, as one of the embodiment of the present application watermark handling method is corresponding
Program instruction/module.Non-volatile software program, instruction and the mould that processor 610 is stored in memory 620 by operation
Block, thereby executing the various function application and data processing of server, i.e. one of realization above method embodiment watermark
Processing method.
Memory 620 may include storing program area and storage data area, wherein storing program area can store operation system
Application program required for system, at least one function;Storage data area, which can be stored, uses institute according to a kind of watermark handling method
The data etc. of creation.In addition, memory 620 may include high-speed random access memory, it can also include non-volatile memories
Device, for example, at least a disk memory, flush memory device or other non-volatile solid state memory parts.In some embodiments
In, optional memory 620 includes the memory remotely located relative to processor 610, these remote memories can pass through net
Network is connected to the processor for running a kind of watermark handling method.The example of above-mentioned network includes but is not limited to internet, in enterprise
Portion's net, local area network, mobile radio communication and combinations thereof.
One or more module is stored in memory 620, when being executed by one or more processor 610, is held
One of the above-mentioned any means embodiment of row watermark handling method.
Embodiment seven
The embodiment of the present application also provides a kind of computer readable storage medium, is stored on the computer readable storage medium
Computer program executes a kind of step of watermark embedding method in above method embodiment when the computer program is run by processor
Suddenly.
A kind of computer program product of watermark handling method is carried out provided by the embodiment of the present application, including stores place
The computer readable storage medium of the executable non-volatile program code of device is managed, the instruction that said program code includes can be used for
Previous methods method as described in the examples is executed, specific implementation can be found in embodiment of the method, and details are not described herein.
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description,
The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In several embodiments provided herein, it should be understood that disclosed systems, devices and methods, it can be with
It realizes by another way.The apparatus embodiments described above are merely exemplary, for example, the division of the unit,
Only a kind of logical function partition, there may be another division manner in actual implementation, in another example, multiple units or components can
To combine or be desirably integrated into another system, or some features can be ignored or not executed.Another point, it is shown or beg for
The mutual coupling, direct-coupling or communication connection of opinion can be through some communication interfaces, device or unit it is indirect
Coupling or communication connection can be electrical property, mechanical 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, each functional unit in each embodiment of the application can integrate in one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.
It, can be with if the function is realized in the form of SFU software functional unit and when sold or used as an independent product
It is stored in the executable non-volatile computer-readable storage medium of a processor.Based on this understanding, the application
Technical solution substantially the part of the part that contributes to existing technology or the technical solution can be with software in other words
The form of product embodies, which is stored in a storage medium, including some instructions use so that
One computer equipment (can be personal computer, server or the network equipment etc.) executes each embodiment institute of the application
State all or part of the steps of method.And storage medium above-mentioned includes: USB flash disk, mobile hard disk, read-only memory (Read-Only
Memory, ROM), random access memory (Random Access Memory, RAM), magnetic or disk etc. is various to deposit
Store up the medium of program code.
Finally, it should be noted that embodiment described above, the only specific embodiment of the application, to illustrate the application
Technical solution, rather than its limitations, the protection scope of the application is not limited thereto, although with reference to the foregoing embodiments to this Shen
It please be described in detail, those skilled in the art should understand that: anyone skilled in the art
Within the technical scope of the present application, it can still modify to technical solution documented by previous embodiment or can be light
It is readily conceivable that variation or equivalent replacement of some of the technical features;And these modifications, variation or replacement, do not make
The essence of corresponding technical solution is detached from the spirit and scope of the embodiment of the present application technical solution, should all cover the protection in the application
Within the scope of.Therefore, the protection scope of the application shall be subject to the protection scope of the claim.
Claims (12)
1. a kind of watermark embedding method characterized by comprising
Obtain watermark video to be embedded;
The same position watermark value of watermark is embedded in the continuous multiple frames image in the watermark video to be embedded.
2. a kind of watermark embedding method according to claim 1, which is characterized in that the same position watermark value of watermark to be embedded in
In continuous multiple frames image in the watermark video to be embedded, comprising:
Every frame image in the continuous multiple frames image is divided into multiple watermark regions to be embedded;
The same position watermark value of the watermark is embedded in the same watermark region to be embedded of the continuous multiple frames image.
3. a kind of watermark embedding method according to claim 2, which is characterized in that by the same position watermark value of the watermark
It is embedded in the same watermark region to be embedded of the continuous multiple frames image, comprising:
Watermark block to be embedded is obtained to the watermark region piecemeal to be embedded according to presetted pixel value;
According to the coordinate of the watermark block to be embedded and the embedment strength coefficient of the watermark block to be embedded, it is calculated described
The watermark stencil value of watermark block to be embedded;
Based on the watermark stencil value, the watermark value in the watermark is embedded in the watermark block to be embedded.
4. a kind of watermark embedding method according to claim 3, which is characterized in that the same position watermark value of watermark to be embedded in
In continuous multiple frames image in the watermark video to be embedded, comprising:
It is located at the watermark of the order and the watermark block to be embedded in the continuous multiple frames image according to current frame image
The watermark value in the watermark is embedded in the watermark block to be embedded by stencil value.
5. a kind of watermark embedding method according to claim 4, which is characterized in that be located at the company according to current frame image
The watermark stencil value of order and the watermark block to be embedded in continuous multiple image, by the watermark in the watermark
Value is embedded in the watermark block to be embedded, comprising:
From the watermark video to be embedded, continuous 8 frame image is intercepted;
When the current frame image is located at preceding 4 frame in the continuous 8 frame image, the brightness value of the watermark block to be embedded and institute
The addition of watermark stencil value is stated, the block after obtaining insertion watermark value;
When the current frame image is located at rear 4 frame in the continuous 8 frame image, the brightness value of the watermark block to be embedded and institute
It states watermark stencil value to subtract each other, the block after obtaining insertion watermark value.
6. a kind of watermark extracting method characterized by comprising
Obtain watermark video to be extracted;
The same position watermark value of watermark is extracted from the continuous multiple frames image of the watermark video to be extracted;
The watermark value is formed into watermark value sequence.
7. a kind of watermark extracting method according to claim 6, which is characterized in that from the company of the watermark video to be extracted
The same position watermark value of watermark is extracted in continuous multiple image, comprising:
Every frame image in the continuous multiple frames image includes multiple watermark regions to be extracted;
The same position watermark value of the watermark is extracted from the same watermark region to be extracted of the continuous multiple frames image.
8. a kind of watermark extracting method according to claim 7, which is characterized in that from the same of the continuous multiple frames image
A watermark region to be extracted extracts the same position watermark value of the watermark, comprising:
By comparing the brightness value of the same watermark region to be extracted of consecutive frame image in the multiple image, institute is extracted
State watermark value.
9. a kind of watermark extracting method according to claim 8, which is characterized in that by comparing phase in the multiple image
The brightness value of the same watermark region to be extracted of adjacent frame image, extracts the watermark value, comprising:
The number that former frame brightness value is greater than a later frame brightness value in the consecutive frame image is denoted as A, and former frame brightness value is less than
The number of a later frame brightness value is denoted as B;
When A is greater than B, the watermark value of extraction is -1, and when A is less than B, the watermark value of extraction is 1.
10. a kind of watermark embedding device characterized by comprising
First acquisition module, for obtaining watermark video to be embedded;
It is embedded in module, the continuous multiple frames image for being embedded in the same position watermark value of watermark in the watermark video to be embedded
In.
11. a kind of watermark extraction apparatus characterized by comprising
Second acquisition module, for obtaining watermark video to be extracted;
Extraction module, for extracting the same position watermark value of watermark from the continuous multiple frames image of the watermark video to be extracted;
Processing module for the watermark value to be formed watermark value sequence, and then obtains watermark.
12. a kind of system for processing watermark, which is characterized in that the system comprises:
The same position watermark value of watermark is embedded in the water to be embedded for obtaining watermark video to be embedded by watermark embedding device
It prints in the continuous multiple frames image in video;
Watermark extraction apparatus, for obtaining watermark video to be extracted, from the continuous multiple frames image of the watermark video to be extracted
The watermark value is formed watermark value sequence by the same position watermark value for extracting watermark.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811058778.2A CN109309869B (en) | 2018-09-11 | 2018-09-11 | Watermark embedding method, device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811058778.2A CN109309869B (en) | 2018-09-11 | 2018-09-11 | Watermark embedding method, device and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109309869A true CN109309869A (en) | 2019-02-05 |
CN109309869B CN109309869B (en) | 2021-01-26 |
Family
ID=65224742
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811058778.2A Active CN109309869B (en) | 2018-09-11 | 2018-09-11 | Watermark embedding method, device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109309869B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111641879A (en) * | 2020-06-08 | 2020-09-08 | 北京永新视博数字电视技术有限公司 | Video watermark adding method, device, storage medium and equipment |
CN112565780A (en) * | 2020-12-18 | 2021-03-26 | 咪咕互动娱乐有限公司 | Game state information sharing method, network device, and storage medium |
Citations (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101136104A (en) * | 2007-10-18 | 2008-03-05 | 李颖 | Self-adapting multiple domains watermark method |
US20080273861A1 (en) * | 2005-06-25 | 2008-11-06 | Huawei Technologies Co., Ltd. | Method for Measuring Multimedia Video Communication Quality |
CN101330610A (en) * | 2008-07-22 | 2008-12-24 | 华为技术有限公司 | Method and apparatus for embedding and extracting watermark as well as processing system |
CN101364300A (en) * | 2008-05-30 | 2009-02-11 | 西安电子科技大学 | Digital watermarking method based on gray theory |
CN101668170A (en) * | 2009-09-23 | 2010-03-10 | 中山大学 | Digital television program copyright protecting method for resisting time synchronization attacks |
CN102905127A (en) * | 2012-08-09 | 2013-01-30 | 山东师范大学 | Video watermark implementation method |
CN103237271A (en) * | 2013-04-02 | 2013-08-07 | 北京中视广信科技有限公司 | Method and system for embedding and detecting large-capacity video digital watermarks |
CN103248898A (en) * | 2013-05-22 | 2013-08-14 | 张炯 | Adding and extracting method for digital watermark and device thereof |
CN103458320A (en) * | 2013-08-29 | 2013-12-18 | 上海美琦浦悦通讯科技有限公司 | Copyright control system based on watermark technology and method for adding digital watermarks to video |
CN103955877A (en) * | 2014-01-21 | 2014-07-30 | 广州大学 | Multimedia-sensing-network watermark verification and image restoration method and device |
CN105848010A (en) * | 2016-03-31 | 2016-08-10 | 天津大学 | Mobile device video watermark embedding and extracting method based on block combination |
CN106878827A (en) * | 2017-03-22 | 2017-06-20 | 河海大学 | A kind of high robust audio frequency and video intersect watermarking algorithm |
CN107911641A (en) * | 2017-10-27 | 2018-04-13 | 北京达佳互联信息技术有限公司 | Video watermark generation method, device and terminal |
CN108055493A (en) * | 2017-12-13 | 2018-05-18 | 苏州科达科技股份有限公司 | The method and device of embedded watermark in video image |
-
2018
- 2018-09-11 CN CN201811058778.2A patent/CN109309869B/en active Active
Patent Citations (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20080273861A1 (en) * | 2005-06-25 | 2008-11-06 | Huawei Technologies Co., Ltd. | Method for Measuring Multimedia Video Communication Quality |
CN101136104A (en) * | 2007-10-18 | 2008-03-05 | 李颖 | Self-adapting multiple domains watermark method |
CN101364300A (en) * | 2008-05-30 | 2009-02-11 | 西安电子科技大学 | Digital watermarking method based on gray theory |
CN101330610A (en) * | 2008-07-22 | 2008-12-24 | 华为技术有限公司 | Method and apparatus for embedding and extracting watermark as well as processing system |
CN101668170A (en) * | 2009-09-23 | 2010-03-10 | 中山大学 | Digital television program copyright protecting method for resisting time synchronization attacks |
CN102905127A (en) * | 2012-08-09 | 2013-01-30 | 山东师范大学 | Video watermark implementation method |
CN103237271A (en) * | 2013-04-02 | 2013-08-07 | 北京中视广信科技有限公司 | Method and system for embedding and detecting large-capacity video digital watermarks |
CN103248898A (en) * | 2013-05-22 | 2013-08-14 | 张炯 | Adding and extracting method for digital watermark and device thereof |
CN103458320A (en) * | 2013-08-29 | 2013-12-18 | 上海美琦浦悦通讯科技有限公司 | Copyright control system based on watermark technology and method for adding digital watermarks to video |
CN103955877A (en) * | 2014-01-21 | 2014-07-30 | 广州大学 | Multimedia-sensing-network watermark verification and image restoration method and device |
CN105848010A (en) * | 2016-03-31 | 2016-08-10 | 天津大学 | Mobile device video watermark embedding and extracting method based on block combination |
CN106878827A (en) * | 2017-03-22 | 2017-06-20 | 河海大学 | A kind of high robust audio frequency and video intersect watermarking algorithm |
CN107911641A (en) * | 2017-10-27 | 2018-04-13 | 北京达佳互联信息技术有限公司 | Video watermark generation method, device and terminal |
CN108055493A (en) * | 2017-12-13 | 2018-05-18 | 苏州科达科技股份有限公司 | The method and device of embedded watermark in video image |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111641879A (en) * | 2020-06-08 | 2020-09-08 | 北京永新视博数字电视技术有限公司 | Video watermark adding method, device, storage medium and equipment |
CN111641879B (en) * | 2020-06-08 | 2022-04-12 | 北京永新视博数字电视技术有限公司 | Video watermark adding method, device, storage medium and equipment |
CN112565780A (en) * | 2020-12-18 | 2021-03-26 | 咪咕互动娱乐有限公司 | Game state information sharing method, network device, and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN109309869B (en) | 2021-01-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP2340527B1 (en) | Method and device for providing a layered depth model of a scene | |
CN106412720B (en) | Method and device for removing video watermark | |
AU2013336028B2 (en) | Image processing device, image processing method, and computer program | |
CN103139577A (en) | Depth image filtering method, method for acquiring depth image filtering threshold values and depth image filtering device | |
JP2001515688A (en) | Embedding and detecting watermarks in images | |
JP2009055591A (en) | Method and apparatus for detecting and removing pseudo-contour, method and apparatus for verifying whether pixel is contained in the contour, and method and apparatus for calculating simplicity | |
US9286653B2 (en) | System and method for increasing the bit depth of images | |
CN111179159A (en) | Method and device for eliminating target image in video, electronic equipment and storage medium | |
JP2007195053A (en) | Electronic watermark detecting device, electronic watermark detection method, and electronic watermark detection program | |
CN102473285A (en) | Retargeting of image with overlay graphic | |
WO2002051124A2 (en) | Deblurring and re-blurring image segments | |
CN109309869A (en) | A kind of watermark embedding method, device and storage medium | |
CN107636728A (en) | For the method and apparatus for the depth map for determining image | |
EP3238212A1 (en) | Apparatus and method for generating an extrapolated image using a recursive hierarchical process | |
CN116457828A (en) | Supervised learning and occlusion masking for optical flow estimation | |
WO2006020532A2 (en) | Fast area-selected filtering for pixel-noise and analog artifacts reduction | |
CN112907433B (en) | Digital watermark embedding method, digital watermark extracting method, digital watermark embedding device, digital watermark extracting device, digital watermark embedding equipment and digital watermark extracting medium | |
JP2009521181A (en) | Blind detection for digital cinema | |
JP2005057780A (en) | Insertion of watermark into image derived from source image and detection of it | |
CN113628091B (en) | Safety information extraction method and device for electronic display screen content reproduction scene | |
CN103139524B (en) | Method for optimizing video and messaging device | |
CN111953994B (en) | Video watermark adding method and device | |
JP2009105637A (en) | Method of deciding image blurring, device therefor and program thereof | |
JP2001203880A (en) | Method for embedding, extracting and making invisible and visible electronic watermark and device for embedding the same | |
CN106530204B (en) | Adaptive image information hiding method based on critical value |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
PP01 | Preservation of patent right | ||
PP01 | Preservation of patent right |
Effective date of registration: 20220726 Granted publication date: 20210126 |