A semi-fragile watermark embedding method resistant to video compression
By tiling and extracting watermark information of the brightness image of video frames, embedding and extracting watermark information, the stability and security problems of video semi-fragile watermarks during video content modification and tampering are solved, and efficient watermarking under video compression conditions is achieved Embed and extract, with applicability and concealment.
Patent Information
- Application Number
- CN202411466798.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-21
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2044-10-21
AI Technical Summary
Video semi-frail watermarks are difficult to maintain stability when video content suffers minor modifications, and cannot sensitively trigger alarms when malicious tampering. Due to the diversity of video formats and complexity of processing methods, watermark embedding and extraction are difficult, and security and concealment are required. Continuously improving.
Using chunking and DCT transformation of the brightness image of the video frame, select candidate areas in the DCT coefficient matrix to embed fragile watermark information, and modify the DCT coefficients through pseudo-random numbers to increase robustness and concealment, use sliding window verification to extract Watermark information to locate the tampered location.
It realizes stable embedding and extraction of watermarks under video compression conditions, and is suitable for various encoding formats. It has fast algorithm speed and low image quality distortion. It can effectively locate the location of video or image tampering, improving the security and concealment of watermarks.
Smart Images

Figure CN118984356B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of digital watermarking, and in particular to a semi-fragile watermark embedding method capable of resisting video compression. Background Art
[0002] Digital watermarks can be generally divided into three types according to the robustness of information: fragile watermarks, robust watermarks and semi-fragile watermarks. Fragile watermarks are a special type of watermark that is highly sensitive to any modification in the host signal.
[0003] When applied to multimedia data, the main purpose of fragile watermarks is to protect its integrity. By extracting and analyzing the changed watermarks, the changes experienced by the original multimedia itself can be measured and evaluated, and the integrity of the multimedia data, the authenticity of the content, etc. can be further identified or authenticated. Robust watermarks refer to watermarks that are not only able to resist non-malicious attacks, but also to resist malicious attacks within a certain degree of distortion. Even if the signal carrier embedded with the watermark undergoes various signal processing, the watermark can still be maintained in the signal and extracted when needed. This type of watermark is difficult for unauthorized persons to detect, but can be easily detected by authorized persons. The purpose of robust watermarks is to ensure that the watermark can exist stably under various conditions to facilitate data tracking and verification.
[0004] Semi-fragile watermark is a watermarking technology between fragile watermark and robust watermark. It can withstand some accidental non-malicious modifications, such as JPEG or video compression, but is very sensitive to malicious content-level tampering. This watermark is mainly used for content authentication of multimedia data and can detect and even locate the tampered part.
[0005] As a technology between fragile watermarking and robust watermarking, video semi-fragile watermarking has always had some problems to be solved in its research.
[0006] First, how to ensure that the watermark remains stable when the video content is slightly modified, while sensitively triggering an alarm when it is maliciously tampered with, is a key challenge.
[0007] Secondly, the diversity of video formats and the complexity of processing methods make it difficult to embed and extract watermarks. How to ensure that watermarks can work effectively in various video formats and processing methods is also a technical challenge.
[0008] In addition, with the continuous development of video technology, the requirements for the security and concealment of watermarks are becoming higher and higher. How to improve the security and concealment of watermarks while ensuring the functionality of watermarks is also an important issue in current research. Therefore, the research on video semi-fragile watermarks still needs continuous exploration and innovation to meet the various challenges in practical applications. Summary of the invention
[0009] In order to solve the above technical problems, the present invention provides a semi-fragile watermark embedding method that can resist video compression. The following technical solutions are adopted:
[0010] A semi-fragile watermark embedding method resistant to video compression, the watermark embedding comprises the following steps:
[0011] Step 1, obtaining a brightness image of a decoded video frame;
[0012] Step 2, performing a block operation on the brightness image with a height and a width of s×s to obtain a brightness image block matrix after N blocks;
[0013] Step 3, performing DCT transformation on each block matrix to convert the pixel values in the spatial domain into a DCT coefficient matrix with a height and width of s×s;
[0014] Step 4, select an embedding candidate region and an embedding position, and select a candidate region of embedding coefficients in the DCT coefficient matrix of s×s dimensions;
[0015] Step 5, assign and embed fragile watermark information to each s×s dimensional DCT coefficient matrix;
[0016] Step 6, repeating the above steps 4 and 5 until all the brightness image block matrix blocks in the video frame have completed the embedding of the corresponding fragile watermark information;
[0017] Step 7: Perform inverse DCT transformation on all DCT coefficient matrices containing fragile watermark information to reconstruct a brightness image containing the watermark information.
[0018] By adopting the above technical solution, the brightness image is first divided into blocks, and then the divided blocks are subjected to DCT transformation to obtain the DCT coefficient matrix of each block. This transformation can convert the image spatial domain signal into a frequency domain signal, which is convenient for subsequent targeted frequency modification, so that the embedded watermark has a certain robustness while not causing image distortion. Then, 1-bit watermark information is generated for each DCT coefficient matrix. Some DCT coefficients in the candidate area in the DCT coefficient matrix are used as carriers to embed the 1-bit watermark information.
[0019] Embedding watermark verification information that can resist secondary compression of the video into the video frame realizes the ability to locate the position of video or image tampering. It has many advantages such as being applicable to various encoding formats, fast algorithm speed, and low image quality distortion.
[0020] Optionally, the specific method of step 2 is:
[0021] Assume the brightness image of step 1 is ,right Perform block division with a height and width of s×s to obtain N blocks of brightness image blocks;
[0022] ;
[0023] in To round down, h and w are the height and width of the image respectively, and s represents the height and width of the block operation.
[0024] Optionally, s is chosen to be a common divisor of h and w.
[0025] By adopting the above technical solution, the selection of the size of s can effectively control the watermark strength and the length of the single-frame watermark information. In order to achieve perfect cutting, s is generally selected as the common divisor of h and w.
[0026] Optionally, in step 4, the candidate region for embedding coefficients includes M DCT coefficients, and pseudo-random numbers are used to select The coefficients are used to modify the embedded watermark, is the floor rounding operation; the m DCT coefficients used as carriers are recorded as .
[0027] By adopting the above technical solution, the m DCT coefficients as carriers are recorded as Through the selection of candidate regions and DCT coefficients, we can avoid modifying some sensitive DCT coefficients, such as DCT DC coefficients and low-frequency AC coefficients, which may cause image distortion, and effectively cover up the specific watermark embedding position, preventing attackers from locating the embedding position of the watermark to reversely extract the watermark or attack the watermark.
[0028] Optionally, the specific method of step 5 is:
[0029] Assign 1 bit of fragile watermark information b to each s×s dimensional DCT coefficient matrix. The fragile watermark will be embedded in When b=0, After embedding ; When b=1 After embedding ; The specific embedding method is:
[0030] ;
[0031] ;
[0032] in .
[0033] By adopting the above technical solution, the embedding algorithm can ensure that m DCT coefficients are used as the carrier of 1-bit watermark information, which increases the robustness of the information and avoids the loss of watermark information caused by video compression disturbance errors. Control the embedding strength. When the signs are the same and the absolute value is large enough, keep the original DCT coefficients unchanged. When the signs are opposite or the signs are the same but the absolute value is not large enough, modify the DCT coefficients to have the same sign and the absolute value This modification strategy ensures the strength of the watermark while minimizing the image distortion caused by modifying the original DCT coefficients.
[0034] Optionally, the watermark extraction preparation process is the same as step 1 to step 4 of the watermark embedding process, and the watermark bit extraction includes the following steps:
[0035] Sum the m carrier DCT coefficients related to all watermarks b. When the sum is less than 0, the watermark information b is 0, otherwise b is 1. The extraction method is as follows:
[0036] ;
[0037] in , repeatedly extracting all the luminance blocks in the video frame completes the extraction of the corresponding watermark information bits.
[0038] Optionally, after extracting the watermark information, a sliding window of a fixed size is used to include the T blocks. If the total score in the sliding window reaches or exceeds a threshold t, the T blocks are determined to be error blocks, otherwise they are determined to be correct blocks.
[0039] If any block in the sliding window is judged to be a correct block, the block is judged to be untampered; if at least one block is judged to be an error block, it is judged to be a tampered block.
[0040] By adopting the above technical solution, the complete process of watermark extraction is as follows:
[0041] Get the brightness image of the decoded video frame, decode the video frame to be checked, and get the brightness image of the video frame , where h and w are the height and width of the image respectively.
[0042] Luminance image segmentation, luminance image The height and width of the image are divided into blocks of s×s to obtain N blocks of brightness image blocks. , The s here is determined by the embedding process and remains unchanged during watermark extraction.
[0043] The brightness image is divided into blocks and DCT is performed on each block matrix to convert the pixel values in the spatial domain into a DCT coefficient matrix of s×s dimensions. This conversion can convert the image spatial domain signal into a frequency domain signal, which is convenient for subsequent targeted watermark extraction.
[0044] Select the candidate extraction area and extraction position, select a candidate area for embedding coefficients in the s×s dimensional DCT coefficient matrix, and the coefficients that need to be modified when embedding the watermark are only selected in this area. This area contains M DCT coefficients, and pseudo-random numbers are used to select The coefficients are used to extract the embedded watermark, which are recorded as . Where b is The DCT coefficient is the 1-bit watermark information to be extracted.
[0045] Watermark bit extraction
[0046] Sum the m carrier DCT coefficients related to all watermarks b. When the sum is less than 0, the watermark information b is 0, otherwise b is 1. The extraction method can be expressed as follows:
[0047] ;
[0048] Here .
[0049] The watermark bits are extracted in batches, and the above steps are repeated until all the luminance blocks in the video frame have completed the extraction of the corresponding watermark information bits.
[0050] Sliding window pooling watermark verification, after the above steps, 1 bit of fragile watermark information is extracted from the frequency coefficient of the brightness image of each block. Check whether the bit watermark information is consistent with the embedded watermark bit. When the two are consistent, the block is scored as 1, otherwise the score is 0. Use a sliding window of fixed size to include T blocks. If the total score in the sliding window reaches or exceeds the threshold t, it is determined that the T blocks are all error blocks, otherwise they are all correct blocks. As the window moves, each block will be judged as an error block several times, and will also be judged as a correct block several times. When it is judged as a correct block in any sliding window, the block is judged not to have been tampered with. As long as the block is judged as an error block once, the block is judged to be a tampered block. This verification method takes into account the fact that conventional video compression will disturb the watermark of each block and the tampered area in real scenes generally presents a non-discrete sheet distribution. It can ignore the small amount of discrete verification errors caused by conventional video compression, reduce the false alarms sensitive to tampering positioning, and can also merge densely distributed verification error areas to reduce the underreporting of tampered areas.
[0051] In summary, the present invention includes at least the following beneficial technical effects:
[0052] The present invention can provide a semi-fragile watermark embedding method that can resist video compression, embed watermark verification information that can resist video secondary compression into the video frame, and realize the ability to locate the position of video or image tampering. It has the advantages of being applicable to various encoding formats, fast algorithm speed, and low image quality distortion. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Figure 1 It is a flow chart of a semi-fragile watermark embedding method resistant to video compression according to the present invention;
[0054] Figure 2 It is a schematic diagram of the brightness image of a video frame and the effect of the first block in a specific embodiment of a semi-fragile watermark embedding method that can resist video compression of the present invention;
[0055] Figure 3 It is a schematic diagram of the effect of the original DCT coefficients of the first luminance block of a video frame according to a specific embodiment of a semi-fragile watermark embedding method resistant to video compression of the present invention;
[0056] Figure 4 It is a schematic diagram of the effect of DCT coefficients after watermark embedding according to a specific embodiment of a semi-fragile watermark embedding method that can resist video compression of the present invention;
[0057] Figure 5 It is a schematic diagram of the effect of extracting candidate areas and DCT coefficients of watermarks according to a specific embodiment of a semi-fragile watermark embedding method that can resist video compression of the present invention;
[0058] Figure 6 It is a schematic diagram of the effect of all sliding windows with scores reaching a threshold of 8 in a specific embodiment of a semi-fragile watermark embedding method resistant to video compression of the present invention;
[0059] Figure 7 It is a schematic diagram of the effect of the final judgment result of a specific embodiment of a semi-fragile watermark embedding method that can resist video compression of the present invention. DETAILED DESCRIPTION
[0060] The present invention is further described in detail below in conjunction with the accompanying drawings. The embodiment of the present invention discloses a semi-fragile watermark embedding method that can resist video compression.
[0061] Reference Figure 1-Figure 7 , a semi-fragile watermark embedding method that can resist video compression, the watermark embedding includes the following steps:
[0062] Step 1, obtaining a brightness image of a decoded video frame;
[0063] Step 2, performing a block operation on the brightness image with a height and a width of s×s to obtain a brightness image block matrix after N blocks;
[0064] Step 3, performing DCT transformation on each block matrix to convert the pixel values in the spatial domain into a DCT coefficient matrix with a height and width of s×s;
[0065] Step 4, select an embedding candidate region and an embedding position, and select a candidate region of embedding coefficients in the DCT coefficient matrix of s×s dimensions;
[0066] Step 5, assign and embed fragile watermark information to each s×s dimensional DCT coefficient matrix;
[0067] Step 6, repeating the above steps 4 and 5 until all the brightness image block matrix blocks in the video frame have completed the embedding of the corresponding fragile watermark information;
[0068] Step 7: Perform inverse DCT transformation on all DCT coefficient matrices containing fragile watermark information to reconstruct a brightness image containing the watermark information.
[0069] First, the brightness image is divided into blocks, and then the divided blocks are transformed by DCT to obtain the DCT coefficient matrix of each block. This conversion can convert the image spatial domain signal into a frequency domain signal, which is convenient for subsequent targeted frequency modification, so that the embedded watermark has a certain robustness while not causing image distortion. Then, 1-bit watermark information is generated for each DCT coefficient matrix. Some DCT coefficients in the candidate area of the DCT coefficient matrix are used as carriers to embed the 1-bit watermark information.
[0070] Embedding watermark verification information that can resist secondary compression of the video into the video frame realizes the ability to locate the position of video or image tampering. It has many advantages such as being applicable to various encoding formats, fast algorithm speed, and low image quality distortion.
[0071] The specific method of step 2 is:
[0072] Assume the brightness image of step 1 is ,right Perform block division with a height and width of s×s to obtain N blocks of brightness image blocks;
[0073] ;
[0074] in To round down, h and w are the height and width of the image respectively, and s represents the height and width of the block operation.
[0075] Choose s to be the common divisor of h and w.
[0076] The selection of s can effectively control the watermark strength and the length of a single frame of watermark information. In order to achieve perfect cutting, s is generally selected as the common divisor of h and w.
[0077] In step 4, the candidate region for embedding coefficients contains M DCT coefficients, and pseudo-random numbers are used to select The coefficients are used to modify the embedded watermark, is the floor rounding operation; the m DCT coefficients used as carriers are recorded as .
[0078] The m DCT coefficients used as carriers are recorded as Through the selection of candidate regions and DCT coefficients, we can avoid modifying some sensitive DCT coefficients, such as DCT DC coefficients and low-frequency AC coefficients, which may cause image distortion, and effectively cover up the specific watermark embedding position, preventing attackers from locating the embedding position of the watermark to reversely extract the watermark or attack the watermark.
[0079] The specific method of step 5 is:
[0080] Assign 1 bit of fragile watermark information b to each s×s dimensional DCT coefficient matrix. The fragile watermark will be embedded in When b=0, After embedding ; When b=1 After embedding ; The specific embedding method is:
[0081] ;
[0082] ;
[0083] in .
[0084] The embedding algorithm can ensure that m DCT coefficients are used as the carrier of 1-bit watermark information, which increases the robustness of the information and avoids the loss of watermark information caused by video compression disturbance errors. Control the embedding strength. When the signs are the same and the absolute value is large enough, keep the original DCT coefficients unchanged. When the signs are opposite or the signs are the same but the absolute value is not large enough, modify the DCT coefficients to have the same sign and the absolute value This modification strategy ensures the strength of the watermark while minimizing the image distortion caused by modifying the original DCT coefficients.
[0085] The watermark extraction preparation process is the same as steps 1 to 4 of the watermark embedding process. The watermark bit extraction includes the following steps:
[0086] Sum the m carrier DCT coefficients related to all watermarks b. When the sum is less than 0, the watermark information b is 0, otherwise b is 1. The extraction method is as follows:
[0087] ;
[0088] in , repeatedly extracting all the luminance blocks in the video frame completes the extraction of the corresponding watermark information bits.
[0089] After extracting the watermark information, a fixed-size sliding window is used to include T blocks. If the total score in the sliding window reaches or exceeds the threshold t, the T blocks are judged to be error blocks, otherwise they are judged to be correct blocks.
[0090] If any block in the sliding window is judged to be a correct block, the block is judged to be untampered; if at least one block is judged to be an error block, it is judged to be a tampered block.
[0091] The complete process of watermark extraction is as follows:
[0092] Get the brightness image of the decoded video frame, decode the video frame to be checked, and get the brightness image of the video frame , where h and w are the height and width of the image respectively.
[0093] Luminance image segmentation, luminance image The height and width of the image are divided into blocks of s×s to obtain N blocks of brightness image blocks. , The s here is determined by the embedding process and remains unchanged during watermark extraction.
[0094] The brightness image is divided into blocks and DCT is performed on each block matrix to convert the pixel values in the spatial domain into a DCT coefficient matrix of s×s dimensions. This conversion can convert the image spatial domain signal into a frequency domain signal, which is convenient for subsequent targeted watermark extraction.
[0095] Select the candidate extraction area and extraction position, select a candidate area for embedding coefficients in the s×s dimensional DCT coefficient matrix, and the coefficients that need to be modified when embedding the watermark are only selected in this area. This area contains M DCT coefficients, and pseudo-random numbers are used to select The coefficients are used to extract the embedded watermark, which are recorded as . Where b is The DCT coefficient is the 1-bit watermark information to be extracted.
[0096] Watermark bit extraction
[0097] Sum the m carrier DCT coefficients related to all watermarks b. When the sum is less than 0, the watermark information b is 0, otherwise b is 1. The extraction method can be expressed as follows:
[0098] ;
[0099] Here .
[0100] The watermark bits are extracted in batches, and the above steps are repeated until all the luminance blocks in the video frame have completed the extraction of the corresponding watermark information bits.
[0101] Sliding window pooling watermark verification, after the above steps, 1 bit of fragile watermark information is extracted from the frequency coefficient of the brightness image of each block. Check whether the bit watermark information is consistent with the embedded watermark bit. When the two are consistent, the block is scored as 1, otherwise the score is 0. Use a sliding window of fixed size to include T blocks. If the total score in the sliding window reaches or exceeds the threshold t, it is determined that the T blocks are all error blocks, otherwise they are all correct blocks. As the window moves, each block will be judged as an error block several times, and will also be judged as a correct block several times. When it is judged as a correct block in any sliding window, the block is judged not to have been tampered with. As long as the block is judged as an error block once, the block is judged to be a tampered block.
[0102] The following is an implementation principle of a semi-fragile watermark embedding method that can resist video compression based on an embodiment:
[0103] Here is a video as an example:
[0104] Get the brightness image of the decoded video frame. Decode a video with a width and height of 352×288, that is, h=288 and w=352, to get a color image, and convert it into a brightness image. See Figure 2 ;
[0105] Luminance image is divided into blocks. Here, the luminance image is divided into blocks of 8×8, that is, s=8. Figure 2 , the upper left corner indicates the position of the first 8×8 block.
[0106] The brightness image is divided into blocks and DCT transformation is performed on each block matrix to convert the pixel values in the spatial domain into a DCT coefficient matrix with a height and width of s×s. This transformation can convert the image spatial domain signal into a frequency domain signal, which is convenient for subsequent targeted frequency modification and makes the embedded watermark have a certain robustness. Figure 2 The DCT coefficient matrix after DCT transformation of the first 8×8 luminance block in is as follows Figure 3 shown.
[0107] Select the embedding candidate area and embedding position. Here, the dark background area is used as the embedding candidate area. The candidate area can be arbitrarily specified by the embedder through key control. The area contains M=34 DCT coefficients, such as Figure 3In general, selecting DCT coefficients near the mid-frequency, i.e., the sub-diagonal, as candidate regions can effectively ensure algorithm robustness and invisibility. Then, m=17 coefficients are selected from the candidate regions to be used as the carrier for embedding the watermark, i.e. Figure 3 The bold DCT coefficients.
[0108] Watermark bit embedding, such as Figure 3 , the selected DCT coefficient is used as a carrier to embed the watermark bit 0, the embedding amplitude α=4, and after embedding, the coefficients greater than -4 are modified to -4, and the other coefficients remain unchanged. The result after embedding is as follows Figure 4 :
[0109] Watermark bits are embedded in batches, and steps 4 and 5 are repeated until all luminance blocks in the video frame have completed the embedding of corresponding watermark information. The 1-bit watermark information corresponding to each luminance block is given by the watermark embedder.
[0110] Luminance image reconstruction, after the above steps, the frequency coefficients of each block of luminance image have been embedded with 1 bit of fragile watermark information. Figure 4 ) to perform inverse DCT transform, and the brightness image can be reconstructed. The brightness image also contains watermark information and can be sent to the video encoder to complete the video frame watermark embedding process.
[0111] Steps 1 to 6 of extracting the watermark are exactly the opposite of the embedding steps:
[0112] After the video is compressed in the usual way, the video block is decoded again and DCT transformed to obtain Figure 5 The DCT coefficient matrix of the block. The candidate regions and embedding positions (bold parts) are determined in turn. The coefficients of all the bold parts are summed up to get a sum of -21.18, which is less than 0, indicating that the watermark bit extracted from the block is 0. The watermark is successfully extracted. Since the watermark bit 0 is the same as the embedded watermark bit 0, the block is determined to be the original block and has not been tampered with. All blocks in the video frame are checked in turn to determine whether the video frame has been tampered with.
[0113] Step 7. Sliding window pooling watermark verification, assuming the score matrix, and using a 4×4 sliding window for pooling, each sliding window contains T=16 blocks and corresponds to 16 scores, and the threshold t is set to 8. As the window moves, there are only 3 windows with scores of 8 or above, and the specific scores are 8, 9, and 9 respectively. Figure 6 As shown;
[0114] Finally, all the blocks covered by the three windows are marked as tampered blocks. The judgment results are as follows: Figure 7 As shown. Among them, × indicates that the block is a tampered block. It indicates that the block is the original block, and the × area is the location of the tampering.
[0115] The above are all preferred embodiments of the present invention, and are not intended to limit the protection scope of the present invention. Therefore, any equivalent changes made based on the structure, shape, and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A semi-fragile watermark embedding method resistant to video compression, characterized in that: Watermark embedding includes the following steps: Step 1, obtaining a brightness image of a decoded video frame; Step 2, performing a block operation on the brightness image with a height and a width of s×s to obtain a brightness image block matrix after N blocks; Step 3, performing DCT transformation on each block matrix to convert the pixel values in the spatial domain into a DCT coefficient matrix with a height and width of s×s; Step 4, select an embedding candidate region and an embedding position, and select a candidate region of embedding coefficients in the DCT coefficient matrix of s×s dimensions; Step 5, assign and embed fragile watermark information to each s×s dimensional DCT coefficient matrix; Step 6, repeating the above steps 4 and 5 until all the brightness image block matrix blocks in the video frame have completed the embedding of the corresponding fragile watermark information; Step 7, performing inverse DCT transformation on all DCT coefficient matrices containing fragile watermark information to reconstruct a brightness image containing the watermark information; The specific method of step 2 is: Assume the brightness image of step 1 is ,right Perform block division with a height and width of s×s to obtain N blocks of brightness image blocks; ; in To round down, h and w are the height and width of the image respectively, and s represents the height and width of the block operation; In step 4, the candidate region for embedding coefficients contains M DCT coefficients, and pseudo-random numbers are used to select The coefficients are used to modify the embedded watermark, is the floor rounding operation; the m DCT coefficients used as carriers are recorded as ; The specific method of step 5 is: Assign 1 bit of fragile watermark information b to each s×s dimensional DCT coefficient matrix. The fragile watermark will be embedded in When b=0, After embedding ; When b=1 After embedding ; The specific embedding method is: ; ; in ; is the embedding amplitude.
2. A semi-fragile watermark embedding method resistant to video compression according to claim 1, characterized in that: Choose s to be the common divisor of h and w.
3. A semi-fragile watermark embedding method resistant to video compression according to claim 2, characterized in that: The watermark extraction preparation process is the same as steps 1 to 4 of the watermark embedding process. The watermark bit extraction includes the following steps: Sum the m carrier DCT coefficients related to all watermarks b. When the sum is less than 0, the watermark information b is 0, otherwise b is 1. The extraction method is as follows: ; in , repeatedly extracting all the luminance blocks in the video frame completes the extraction of the corresponding watermark information bits.
4. A semi-fragile watermark embedding method resistant to video compression according to claim 3, characterized in that: After extracting the watermark information, a fixed-size sliding window is used to include T blocks. If the total score in the sliding window reaches or exceeds the threshold t, the T blocks are judged to be error blocks, otherwise they are judged to be correct blocks. If any block in the sliding window is judged to be a correct block, the block is judged to be untampered; if at least one block is judged to be an error block, it is judged to be a tampered block.
