Received 4 May 2016; accepted 17 July 2016; published 20 July 2016
These days, the reproduction, manipulation, and distribution of the different digital multimedia and entertainment resources such as images, audio, and video via the internet become faster and easier. The various social networks and websites such as Facebook, Tweeter, and Instagram allow sharing of images and videos over a wide range. Meanwhile, such material could be available for the users to illegally download and copy them without the owner permission. Therefore, copyright protection and authentication schemes are becoming essential to effective security.
Digital watermarking technology is proposed as an effective solution for copyright protection and product authentication. Watermarking is the process of embedding some security information into the host digital contents without loss of the watermarked data quality and with the ability to extract this information lately to prove the ownership of intellectual property. There are two criteria that the watermarking techniques should achieve with trade-off among them, robustness and visual quality of watermarked data. However, increasing the robustness leads to increasing the ability to detect or extract the watermark under different kinds of intentional and unintentional attacks, at the expense of visual quality.
The watermark could be image, logo, pattern, license information; any information can identify the owner or prove the ownership. Any digital watermarking scheme consists of two basic parts: watermark embedding and watermark detection/extraction. In the embedding process, the watermark is embedded into a host data which may be an image, an audio or a video using a key. Some techniques embed the watermark in the spatial domain by modifying the pixel values directly. On the other hand, other techniques embed the watermark in the frequency domain by modifying the transformed coefficients and these techniques are more robust than spatial domain. The most commonly used transforms are the discrete fourier transform DFT, discrete cosine transform DCT and DWT  -  .
Many research proposed different techniques for video watermark in compressed  -  and uncompressed domains   . Some methods extend image watermarking algorithms by considering that video frames are still consecutive images while other methods based on inherent features of the video sequence like motion vectors. Watermarking in the motion vector between successive frames can be used in the compressed and uncompressed video with a little degradation in the video quality. Lee et al.  presented an adaptive video watermarking using motion information. A number of blocks are selected from the first frame based on some criteria. By using block matching algorithm, these blocks are tracked in each frame and transformed to DWT. The same watermark is embedded in the middle frequency band of the same block with adjustable strength. Zhongjie et al.  proposed a technique in which the watermark information is embedded by changing the horizontal or vertical component of motion vectors. This scheme has low computational complexity and could be extracted blindly. In Zhang et al.  the watermark is embedded in the compressed domain using the motion vectors that have greater amplitude than a certain threshold. Different watermarks are embedded in different pieces of the motion vectors. Mishra et al.  used Back-Propagation Neural network (BPN) to embed the watermark in a selected video frames that have a maximum motion in X and Y directions. After that, the watermark is embedded into the DWT coefficients of the blue channel of the selected frames. Nakano-Miyatake et al.  have proposed algorithm that embeds and detects the watermark in the compressed domain (MPEG-2). The watermark is embedded into the coefficient of the DCT blocks of I-frame and P-frame using the adequate embedding energy. However, the adequate embedding energy is computed for each block using Human Visual System (HVS) criteria.
This paper presents a new uncompressed video watermarking algorithm which embeds different parts of a single watermark into different frames of a video using motion vectors and DWT. The watermark is divided into blocks and each block of the watermark is embedded into a selected blocks in each frame. As the human eye cannot notice the details of fast moving region, the blocks with highest motion vector magnitude are chosen to embed the watermark. The selected blocks are transformed using wavelet transform and the coefficients are changed according to the watermark signal. Consequently, the watermark could be extracted from different locations in the same frame. Thus, if there is any distortion in a recovered watermark from one or more locations, the rest will be used to provide the correct watermark. The proposed embedding and extracting schemes make it robust against different attacks. Comparing to the work in the literature, the proposed techniques not only focus on making the watermark not noticeable but also to be robust against the different attacks which is a trade-off.
The rest of the paper is organized as follows: Section 2 describes the motion estimation. The proposed watermarking scheme is explained in Section 3. Section 4 demonstrates the experimental results and finally Section 5 concludes the paper.
2. Motion Estimation
The successive video frames contain temporal redundancy so any two adjacent frames are similar and changes may be caused by object movement. Motion estimation technique is used to reduce the inter-frame correlation and reduce the total transmission bit rate which plays an important role in the video compression process   . The block-matching algorithm (BMA) as shown in Figure 1 is the most common and efficient method for motion estimation  . In this algorithm each frame is divided into equal sized non-overlapping blocks then each block of current frame F is compared with the corresponding block and its neighbors within a search window on the previous frame F-1 to find the best matching block  . There are several criterion can be used to determine the candidate block as Mean Absolute Difference (MAD), Mean of Squared Error (MSE) and Sum of absolute difference (SAD)  . The proposed work uses Equation (1) to calculate the MAD.
where nxn is the block size and Bcij and Bpij are the pixel number (i, j) in the compared blocks in the current frame and the previous frame, respectively. The displacement between the block and the best matching one is defined as the motion vector MV and there is only one motion vector for each block. The larger motion vector magnitude means the faster moving of its block and less sensitive to the human eye to observe the change.
3. Proposed Watermarking Scheme
The block diagrams of embedding and extraction algorithms are shown in Figure 2 and Figure 3 in proposed method, video frames are taken as an input, and the watermark is embedded in selected blocks with high motion vector magnitude by altering the wavelet coefficients of selected DWT sub-bands.
3.1. Watermarking Embedding
The proposed watermarking process shown in Figure 2 is briefly described as following:
Figure 1. Block matching motion estimation.
Figure 2. Watermark embedding algorithm.
Figure 3. Watermark extraction algorithm.
The video sequence is taken as input and divided into N × N RGB frames. The RGB frames are converted into YUV components, and only the luminance Y component is used for watermark embedding. For each two consecutive frames F-1 and F, the Y component of each frame is divided into 16 × 16 blocks and the block matching algorithm is applied to calculate the motion vectors. The first L blocks with highest motion vector magnitude are chosen to embed the watermark. The motion vector magnitude is computed as following  :
where and are the x and y components of the motion vector of block i. The DWT is applied locally to all chosen blocks of frame F and get four multiresolution sub-bands n × n: LL, HL, LH, and HH  . The watermark is a binary logo image of n × n and it has been divided into 8 × 8 blocks. The same block of watermark is embedded L times in the same frame by modify the coefficients of LH sub-bands of all chosen blocks L. If BLH is the embedding sub-band then the embedding equation is:
where is the watermarked sub-band; α is the watermarking strength and WB is the watermark block. Apply the inverse DWT for each block to produce the watermarked luminance component of the frame. Then combine the modified luminance component with original U and V to obtain the watermarked frame and then reconstruct the watermarked video.
3.2. Watermarking Extraction
The watermark extraction process shown in Figure 3 is the inverse procedure of the watermark embedding process. The proposed algorithm is a non-blind algorithm so the original video sequence is required. The watermark extraction procedure is as follows:
The watermarked (and may be attacked) video is divided into frames and converts the N × N RGB frames into YUV components. For each two consecutive frames, the Y component of each frame is divided into 16 × 16 blocks. The block matching algorithm is applied to calculate the motion vectors. The DWT is applied to the L chosen blocks with highest motion vector magnitude of frame F, and from LH sub-bands the watermark block is extracted using the following equation:
where is the extracted watermark block and is the watermarked sub-band (and may be attacked). After the extraction process, multiple copies of each block of the watermark are obtained. As the watermarked video may expose to a different type of attacks and may create spurious matches, the watermark block is recovered by averaging the watermarked blocks extracted from the same frame to reduce the attack effects. Finally, all the blocks are combined together to produce the recovered watermark.
4. Experimental Results
The performance of the proposed algorithm is tested on three 256 × 256 video sequences; Foreman, Calendar, and Silent. Only the luminance components of the different frames are watermarked during the test procedures. For motion estimation algorithm each frame is divided into blocks of size 16 × 16. The DWT is applied to chosen blocks and a number of HL sub-bands of size 8 × 8 pixels are obtained. The watermark, shown in Figure 4, is a binary logo image with size 32 × 32 and is divided also into blocks of size 8 × 8. Different kinds of attacks are simulated to test the proposed watermarking scheme.
The algorithm performance is evaluated from the imperceptibility and robustness against various attacks points of view  . The visual quality of the watermarked frame is evaluated by PSNR and is defined as  :
where MSE (mean squared error) between the original and watermarked frames and is defined as follows  :
where m and n are the size of the frame and f(i, j) and f'(i, j) are the pixel values at location (i, j) of the original and watermarked frame. However, robustness is measured by NC and is given by  :
Figure 4. Watermark.
Figure 5. (a) The Foreman original frame. (b) The watermarked frame (PSNR = 45.24 db). (c) The extracted watermark (NC = 0.9895).
Figure 6. (a) The Mobile original frame. (b) The watermarked frame (PSNR = 44.7380 db). (c) The extracted watermark (NC = 0.9835).
Figure 7. (a) The Silent original frame. (b) The watermarked frame (PSNR = 42.75db). (c) The extracted watermark (NC = 0.9971).
sequence respectively and Figure 5(b), Figure 6(b), Figure 7(b) show the corresponding watermarked frame with PSNR = 45.24 db, 44.7380 db and 42.75 db respectively. The high computed values of PSNR, bigger than 40 db, indicate that the embedded watermark is imperceptible and the watermarked frame appears visually identical to the original. The extracted watermark from Foreman, Mobile and Silent video sequence without attack are shown in Figure 5(c), Figure 6(c), Figure 7(c). The high values of corresponding NC, 0.9895, 0.9835 and 0.9971, indicate that the watermark is successfully extracted.
To evaluate the robustness of the watermarking algorithm, the three video sequences are subject to different attacks. Tables 1-6 show the PSNR and NC for each case of the attacked videos. To test the robustness of the proposed algorithm against noise attack, Gaussian noise is added to the watermarked videos at mean = 0 and variance = 0.001. The watermark is still recognizable with human eyes and can be extracted from corrupted wa-
Table 1. Gaussian noise attack.
Table 2. Gamma correction attack.
Table 3. Contrast attack.
Table 4. Automatic equalization attack.
Table 5. Sharpen attack.
Table 6. JPEG compression attack.
termarked frame with high NC = 0.8114, 0.9835 and 0.8455 as shown in Table 1.
Table 2 illustrates the results of frame attacked by Gamma correction with different parameters (Par) 0.4 and 2. The watermark can be recovered with NC value greater than 0.9 except for Mobile video when the parameter = 2 so the scheme can resist this attack. In the same manner, the proposed scheme is robust against contrast adjustment with factor = 20 with NC = 0.9046, 0.9134 and 0.9576 as shown in Table 3, and robust against histogram equalization with NC = 0.9458, 0.9651 and 0.9849 as shown in Table 4, all the NC values exceed 0.9. The video frames are filtered by a sharpening filter with parameter value 0.6. The watermark is reconstructed with NC = 0.8596, 0.8767 and 0.8803 as in Table 5.
Finally, Table 6 shows the robustness of the proposed algorithm against JPEG attacks with different quality factors (QF = 90% and 80%). From NC values, it is found that the proposed watermark can survive under the compression process.
The proposed technique is compared to the proposed work in  for Foreman video results:
・ Gaussian noise attack: the achieved NC at variance 0.0007 was 0.8 in  while it was 0.8114 at variance 0.001 in the current work as shown in Table 1. This implies that the proposed technique is robust against a higher noise variance value.
・ JPEG compression attack: the achieved NC was 0.7 and 0.85 in  and 0.9204 and 0.9377 in the current work for QF equal 80% and 90% respectively. This indicates that the proposed technique is more resistant to this attack.
In this paper, a video watermarking scheme has been implemented. Embedding the watermark in motion blocks satisfies the requirement of imperceptibility besides applying block based DWT which satisfies the robustness of the algorithm. The proposed scheme is tested by applying some signal and image processing attack and measuring the robustness of the scheme by NC and visual quality by PSNR. The experimental results show that the proposed scheme is robust against common attacks such as Gaussian noise, gamma correction, and automatic equalization, contrast adjustment, sharpening filter and JPEG compression with different QF. In the future research, we will try to enhance our algorithm to be robust against geometric transformations like frame resizing, rotating and cropping.