*7.1.1 Watermark embedding*

The steps of watermark embedding can be summarized as follows:

	- 1. The possibly corrupted watermarked image is transformed into the wavelet domain using the same wavelet transform as in the embedding process.
	- 2. The extraction is performed on the coefficients in the first level wavelet transform (HL1).
	- 3. All the wavelet coefficients of magnitude greater than or equal to t1 and less than or equal to t2 are selected. The watermark bits are extracted from each of the selected DWT coefficients with Eq. (9):

$$\text{If } < (\mathbf{t}\mathbf{1} + \mathbf{t}\mathbf{2})/2 \text{, then the recovered watermark bit is 0.}$$

$$\text{If } \mathbf{j} \ge (\mathbf{t}\mathbf{1} + \mathbf{t}\mathbf{2})/2 \text{, then the recovered watermark bit is 1.} \tag{9}$$

For all the tests in this chapter, MATLAB is used. All tests are performed upon the

watermarking schemes on the Mandrill image, we set t1 = 115, t2 = 200, and k = 0.1. The suitable thresholds are obtained from the curves in **Figure 4b**. The watermarked images are then attacked with JPEG compression with different compression ratios to make the quality of the images at levels 5 (Q5), 10 (Q10), and 15 (Q15) at the JPEG standard. Other attacks such as the additive white Gaussian noise (AWGN) and cropping attacks are also considered. The same schemes are also applied to the Hat image with similar attacks. The thresholds used for this case are t1 = 90 and t2 = 200. We find from the figures that the suitable thresholds are coming from the curves in **Figure 4d**. To investigate the watermarking methods, we calculate the threshold (t) by using fmax= 528.4 and k = 0.1 so the threshold t = 0.1\* fmax=52.84, we will use t1 = 90, t2 = 200 that give the tradeoff between PSNR and correlation as shown in **Figure 4**. The attacks were used to test the new algorithm, we choose the thresholds according to that gives the trade off between the high PSNR and the high Correlation ,in the case of mandrill we find that t1 = 115, t2 = 200, X1 = 20 and X2 = 10. **Figure 5** shows this Watermarked image and the effect of attacking this watermarked image with various attacks. The watermarked images are then attacked with JPEG at levels

*(a) Original image. (b) Mandrill image marked using watermarking scheme of Dugad in the absence of attacks. (c) Hat image marked using watermarking scheme of Miyazaki in the absence of attacks. (d) Mandrill image marked using LSB. (e) Mandrill image marked using the proposed watermarking method in the absence of attacks.*

It can be seen that the watermarking algorithm of Dugad is surviving all the attacks. The high compression ratio using JPEG with quality 5 is one of the attacks applied to the watermarked image and resizing from 256 to 128 is the other attack, it is found that the watermark was not always detected. Results are shown in **Tables 1–3**.

Miyazaki method with t1 = 115 and t2 = 200; we find that the results are better than that of Dugad method because it is a semi-blind method. Results are shown in

Similar experiments and attacks are carried out for the algorithm in

8-bit grayscale 256 256 Mandrill, Hat, and Lena images. To simulate the

Q5, Q10, and Q15, AWGN, and cropping.

*Blind Wavelet-Based Image Watermarking DOI: http://dx.doi.org/10.5772/intechopen.88131*

**Tables 1** and **3**.

**107**

**Figure 5.**
