Sunteți pe pagina 1din 5

Image Watermarking in Dct-Dwt Domain

IRNet Transactions on Electrical and Electronics Engineering (ITEEE) ISSN 2319 2577, Vol-1, Iss-2, 2012
1
IMAGE WATERMARKING IN DCT-DWT DOMAIN

ANGSHUMI SARMA
1
& AMRITA GANGULY
2


1,2
Dept. of Electronics and Communication Engineering, Gauhati University, Guwahati, Assam, India
Dept. of Electrical Engineering, Assam Engineering College, Guwahati, Assam, India
Email:angshumi@yahoo.com, aganguly.ele@aec.ac.in



Abstract The interest in the field of digital watermarking is increasing day by day with the increase in concern over
copyright protection of digital information and prevention of unauthorized access, duplication and manipulation of digital
data. In this paper, two different methods of image watermarking are described, using combined DCT-DWT transform. The
host image is decomposed into four subbands using the first level DWT and then second level DWT is performed on the HL
subband. In the first approach, the two smaller sub bands of the HL sub band LH2 and HL2 are used to embed the watermark
and in the second approach all the four smaller subbands of the HL subband are used to embed the watermark. In both the
cases, 8x8 DCT is carried out on the subbands and the middle frequency DCT coefficients are selected for embedding the
watermark. Experimental results show that both the methods provide high imperceptibility as well as high robustness against
different attacks such as J PEG compression, Gaussian noise, Salt & Pepper noise, Speckle noise, Scaling, Cropping etc,
however, the imperceptibility and robustness of the four subband method is comparatively higher than the two subband
method.

Keywords -Digital Image Watermarking, Discrete Wavelet Transform (DWT), Discrete Cosine Transform (DCT),
Robustness, Imperceptibility.


I. INTRODUCTION

In recent years, with the fast development in the
field of information technology and multimedia,
digital media has become the primary means of
communication in almost all aspects of our life along
with the wide use of network. At the same time,
digital information security problem has emerged as a
threat. Digital data can easily be accessed,
manipulated and pirated without error, putting the
rights of their owners at risk. Hence, copyright
protection has become an urgent requirement. Digital
watermarking has emerged as a solution to this
problem. Digital watermarking can be defined as the
process of embedding a certain piece of information
(known as watermark) into multimedia content
including text documents, images, audio or video
streams, such that the watermark can be detected or
extracted later in order to provide copyright protection
to the data and prevent illegal copying.
There are certain factors affecting the quality of
any watermarking scheme. These are robustness,
imperceptibility, security and low complexity.
Robustness is a measure of immunity of the
watermark against attempts to image modification and
manipulation. It is measured in terms of correlation
factor, which measures the similarity and difference
between the original watermark and the extracted
watermark. Its value is generally 0 to 1. Ideally it
should be 1 but the value 0.7 is acceptable [1].
Imperceptibility is related to the quality of host image
in presence of the watermark. The quality of
watermarked image is measured by PSNR (Peak
signal to Noise Ratio). High PSNR indicates better
quality of the watermarked image. In general,
Watermarked Images with PSNR greater than 28 are
acceptable [1]. Security is another factor related to
watermarking. Watermark information owns the
unique correct sign, so that only the authorized users
can legally detect, extract and even modify the
watermark, and thus be able to achieve the purpose of
copyright protection. Complexity involved in inserting
and extracting the watermark in the host image should
be low to ensure effective and timely implementation
for watermark embedding, detection and extraction.
Current digital image watermarking techniques
may be grouped into spatial-domain techniques and
frequency-domain techniques. Compared to spatial
domain watermarking techniques, frequency-domain
watermarking techniques proved to be more effective
with respect to achieving the imperceptibility and
robustness requirements of digital watermarking
algorithms [2, 3]. Commonly used frequency-domain
transforms are the Discrete Wavelet Transform
(DWT), the Discrete Cosine Transform (DCT) and
Discrete Fourier Transform (DFT). However, DWT
has been used in digital image watermarking more
frequently due to its time/frequency decomposition
characteristics and its resemblance to the theoretical
models of the human visual system [3]. DWT-based
watermarking algorithms could further be improved
by combining DWT with DCT [2, 3]. The
combination of the two transforms namely the DWT
and the DCT could compensate for the drawbacks of
each other, resulting in effective watermarking.
In this paper, two image watermarking methods in
the DCT-DWT domain are proposed. In the proposed
work two level DWT is performed on the host image.
The first level DWT results in decomposition of the
image into four subbands LL1, HL1, LH1 and HH1.

Image Watermarking in Dct-Dwt Domain

IRNet Transactions on Electrical and Electronics Engineering (ITEEE) ISSN 2319 2577, Vol-1, Iss-2, 2012
2
The second level DWT is performed on the HL1
subband which results in the subbands LL2, HL2,
LH2 and HH2. Out of these four subbands, the LH2
and HL2 subbands are chosen for watermark
embedding in the first method and in the second
method all the four subbands are chosen for
embedding the watermark. The subbands are then
divided into 8x8 non overlapping blocks and DCT is
carried out on them and the watermark is embedded
into the middle frequency DCT coefficients.

II. THEORETICAL BACKGROUND

The proposed work requires certain theoretical
considerations related to Discrete Cosine Transform
(DCT), Discrete Wavelet Transform (DWT) and their
application in image processing. Hence, a brief
description of these concepts is included in the
following sections.
A. Discrete Cosine Transform (DCT)
The discrete cosine transform (DCT) represents
an image as a sum of sinusoids of varying magnitudes
and frequencies [1, 3]. For an input image, X, of size
N x N the DCT coefficients for the transformed
output image, Y, are computed according to (1). X (i,
j) is the intensity of the pixel in row i and column j of
the image, and Y (u, v) is the DCT coefficient in row
u and column v of the DCT matrix.

1 1
u v
0 0
((2 1) ) ((2 1) )
Y(u,v)=CC cos cos
2 2
N N
i j
j y i x
N N





(1)
where
u, v
1
C C =
N
for u, v=0 and
u, v
2
C C =
N
for u, v=1, 2,.N-1

Performing DCT of an image gives rise to three
different frequency coefficient sets: low frequency,
mid frequency and high frequency coefficient sets [3,
4]. The DCT has a special property that most of the
visually significant information of the image is
concentrated in just a few coefficients of the DCT [1].
This is referred to as the Energy compaction
Property. Most of the signal energy is concentrated
at the low frequency coefficients, which contains the
most important visual parts of the image. And high
frequency coefficients of the image are usually
removed through compression and are more prone to
noise attacks. Hence watermark is embedded in the
mid frequency coefficients so that the visibility of the
image is not affected and the watermark is not
removed by compression or noise attacks.
B. Discrete Wavelet Transform (DWT)
Wavelet transform decomposes an image into a
set of band limited components which can be
reassembled to reconstruct the original image without
error [3, 5]. For 2-D images, applying DWT
corresponds to processing the image by 2-D filters in
each dimension. The filters divide the input image
into four non-overlapping multi-resolution sub bands,
a lower resolution approximation image (LL1),
horizontal (HL1), vertical (LH1) and diagonal (HH1)
detail components. The process can be repeated to
obtain multiple scale wavelet decomposition.
















Figure 1. Two level Wavelet Decomposition

One of the advantages of DWT over DCT is that
it can more accurately model the aspects of the HVS
as compared to DCT [3, 5]. In general most of the
image energy is concentrated at the LL subband and
hence embedding watermarks in this sub band may
degrade the image quality, but embedding watermark
in this subband can provide higher robustness. On the
other hand, the detail subbands LH, HL and HH
include the edges and textures of the image and the
human eye is generally not much sensitive to changes
in these subbands. Hence embedding watermarks in
these subbands can provide higher imperceptibility,
without being perceived by human eye. But the noise
attacks and lossy compression results in data loss at
high frequencies and hence the robustness may suffer
for the watermarks embedded in the HH subband.
Hence many of the watermark embedding schemes
opt for the LH or HL subband for embedding the
watermark in order to provide both imperceptibility
and robustness [3, 5, 6].
C. Performance Measures
The performance of any watermarking scheme can
be evaluated on the basis of its robustness and
imperceptibility. The imperceptibility can be
measured by the Peak Signal to Noise Ratio (PSNR),
calculated between the original image and the
watermarked image. The PSNR [1, 3, 6] is given by

2
(255)
PSNR =10log dB
MSE
(4)

where MSE is the Mean Square Error given by

Image Watermarking in Dct-Dwt Domain

IRNet Transactions on Electrical and Electronics Engineering (ITEEE) ISSN 2319 2577, Vol-1, Iss-2, 2012
3
2
1 1
1
MSE= ( )
*
M N
ij ij
i j
X W
M N



(5)

where X
ij
is a pixel of the Original Image of size MxN
and W
ij
is a pixel of the Watermarked Image of size
MxN.
The robustness can be measured by the
Normalized Correlation (NC), calculated between the
original watermark and the extracted watermark. The
Normalized Correlation [1, 2] is given by
1 1
2 2
1 1 1 1
*
NC
M N
oij rij
i j
M N M N
oij rij
i j i j
W W
W W



(6)

where W
oij
is a pixel of the Original Watermark of
size MxN and W
rij
is a pixel of the Extracted
Watermark of size MxN.

III. PROPOSED SCHEMES

The watermarking schemes proposed here are
combined DCT/DWT based processes, where the
benefits of DWT are taken into consideration in
choosing the most proper subband for watermark
embedding in order to provide both robustness and
imperceptibility and hence the HL subband is chosen
after performing one level DWT on the host image.
Secondly, a key is used to generate the two PN
sequences used for watermark embedding and
watermark extraction process in order to provide
security to the watermarking schemes. Thirdly,
watermark is divided into the smaller subbands of HL
subband during embedding instead of being embedded
into one single subabnd, which enhances the security
of the schemes. Lastly, DCT is applied on the DWT
subbands and for watermark embedding purpose the
middle frequency DCT coefficients are selected to
provide further robustness to the schemes.
Compared to the different DCT/DWT based
algorithms proposed in the literature the proposed
methods exhibit higher robustness and
imperceptibility and the computational complexity
involved is also less. The proposed methods can be
summarized by the depiction in Figure 2. The
watermarking algorithm consists of the embedding
algorithm and the extraction algorithm.
A. Embedding Algorithm
The embedding algorithm can be divided into the
following steps:

o Step 1: First level DWT is performed on the
host image to decompose it into four subbands
LL1, HL1, LH1 and HH1.
o Step 2: The second level DWT is performed
on the HL1 subband to get four smaller
subbands LL2, HL2, LH2 and HH2.
o Step 3: Firstly the HL2 and LH2 subbands are
considered and divided into 8x8 non
overlapping blocks and DCT is carried out on
them. Secondly, all the four subbands are
considered and divided into 8x8 non
overlapping blocks and DCT is carried out on
them.
o Step 4: The watermark is embedded into the
sixteen middle frequency DCT coefficients.
Zig-zag scanning is performed on the 8x8
DCT blocks as shown in the























Figure 2. Flow Diagram for Watermark embedding and
extraction

scanning pattern inFigure 3 and the sixteen
middle frequency coefficients from 6 to 21 are
selected for embedding the watermark. The
selection of the DCT coefficients is done as
shown in Table I and Table II for the first and
second method respectively.
o Step 5: The watermark is converted into a
message vector of 0s and 1s.
o Step 6: Two PN sequences pn_zero and
pn_one are generated respectively for 0 and 1
with the help of a key. Watermark embedding
is done as follows

If
w(i,j)=0, H1(i,j)=H(i,j)+k*pn_zero
(2)
If
w(i,j)=1,H1(i,j)=H(i,j)+k*pn_one
(3)

where k stands for embedment strength, w (i,
j) stands for the value of watermark bit, H (i, j)
represents middle frequency coefficient before

Image Watermarking in Dct-Dwt Domain

IRNet Transactions on Electrical and Electronics Engineering (ITEEE) ISSN 2319 2577, Vol-1, Iss-2, 2012
4
embedding and H1 (i, j) stands for the middle
frequency coefficient after embedding.
o Step 7: Inverse DCT (IDCT) is carried out on
each block after its middle frequency
coefficients have been modified to embed the
watermark bits.
o Step 8: Inverse DWT (IDWT) is carried out
on HL and other high resolution subbands of
wavelet decomposition to produce the
watermarked image.
B. Extraction Algorithm
The watermark extraction algorithm consists of the
following steps:
o Step 1: First level DWT is performed on the
watermarked image to decompose it into four
subbands LL1, HL1, LH1 and HH1.
o Step 2: The second level DWT is performed
on the HL1 subband to get four smaller
subbands LL2, HL2, LH2 and HH2.
o Step 3: Firstly the HL2 and LH2 subbands are
considered and divided into 8x8 non
overlapping blocks and DCT is carried out on
them. Secondly, all the four subbands are
considered and divided into 8x8 non
overlapping blocks and DCT is carried out on
them.
o Step 4: The sixteen middle frequency DCT
coefficients are then selected taking eight each
from each of the two smaller subbands and
four each from each of the four smaller
subbands as done in the embedding algorithm.
o Step 5: Two PN sequences r_pn_zero and
r_pn_one are generated respectively for 0 and
1with the help of the same key used in
embedding.
o Step 6: Correlation is calculated between the
middle frequency coefficients and the two PN
sequences. If the correlation with r_pn_one is
greater than the correlation with r_pn_zero,
then the extracted watermark bit is considered
1, otherwise the extracted watermark bit is
considered 0.
o Step 7: The vector of 0s and 1s is then
converted into image form to get the recovered
watermark.

TABLE I. SUBBANDWISE COEFFICIENT SELECTION FOR THE
FIRST METHOD
Subband Mid frequency coefficients
HL2 6-13
LH2 14-21
TABLE II. SUBBANDWISE COEFFICIENT SELECTION FOR THE
SECOND METHOD
Subband Mid frequency coefficients
LL2 6-9
HL2 10-13
LH2 14-17
HH2 18-21









Figure 3. Zig-Zag scanning pattern

IV. EXPERIMENTAL RESULTS

The experiments are carried out on the lenna test
image of size 512x512 and the binary watermark of
size 15x9. The experiments are carried out for attack
free and with different attacks cases.
A. Attack free case
For the experimental purpose the watermark
embedment strength k is taken as 32. Without any
noise attack the PSNR obtained is 40.65 dB using two
subbands and 43.04 dB using four subbands. The
PSNR for the four subband approach is about 5.87%
higher compared to the PSNR with the two subband
approach. It is observed that for both the cases the
PSNR obtained is better compared to the PSNR
obtained for the traditional method cited in [4]. The
NC value is 1 for both the cases. Figure 4 and Figure 5
shows the original host image and the watermarked
image in attack free case for the two subband and four
subband cases respectively.
B. With different noise attacks
The watermarked image is exposed to Gaussian
noise, Speckle noise and Salt and Pepper noise with
various densities. For all the noise attacks the
watermark could be extracted with a good correlation
with the original watermark.
C. With JPEG Compression
The methods are quite robust against JPEG
compression attack. The watermarked image is
exposed to JPEG compression with Q=90, Q=70,
Q=50 and Q=30. With the increase in Q value the
compression ratio increases and the quality of the
watermarked image degrades. With Q=30 a
compression ratio of about 11:1 is achieved with both
the two subband and four subband cases. It is
observed that for all the cases the extracted watermark
shows a good correlation value with the original
watermark.




Figure 4. Original and Watermarked Image with Two subbands




Image Watermarking in Dct-Dwt Domain

IRNet Transactions on Electrical and Electronics Engineering (ITEEE) ISSN 2319 2577, Vol-1, Iss-2, 2012
5











Figure 5. Original and Watermarked Image with Four
subbands
D. With Scaling
When exposed to 75% and 60% scaling attack the
watermarked image is shrunk. It is then brought back
to the original size of 512x512 using interpolation.
The watermark could exactly be extracted in case of
75% scaling with a correlation value 1.
E. With Change in Brightness
The change in brightness of the watermarked
image does not affect the quality of the extracted
watermark. The watermarked image is subjected to
increase and decrease in brightness and in both the
cases the extracted watermark shows a correlation
value of 1.
F. With Cropping
The watermarked image is subjected to 5%, 10%
and 20% cropping respectively. With 5% and 10%
cropping the watermark could exactly be extracted.
With 20% cropping there is degradation in the quality
of the extracted watermark; however its value is well
within the acceptable limit.

The experimental results are summarized in
Table III. It is observed that the imperceptibility with
the four subband method is comparatively higher than
the two subband method. Also, the four subband
method is more secure than the two subband method,
as the watermark is spread into all the four subbands.
In terms of robustness both the methods are quite
robust against different attacks.

V. CONCLUSION

In this paper, two image watermarking methods
in the DCT/DWT domain are described. The
experimental results prove the robustness of the two
methods against different attacks and the
imperceptibility of the watermarked image is also
quite high. However, the methods fail to show
satisfactory results against rotation attack. Our future
work will be to make the performance of the
algorithm better against rotation attack.

REFERENCES

[1] B. L. Gunjal, R.R. Manthalkar: An Overview of Transform
Domain Robust Digital Image Watermarking Algorithms,
J ournal of Emerging Trends in Computing and Information
Sciences, Vol. 2, No. 1.
[2] A. Al-Haj: Combined DWT-DCT digital image
watermarking, J ournal of Computer Science 3 (9): pp. 740-
746, 2007.

[3] S.K. Amirgholipour, A. R. Naghsh-Nilchi: Robust Digital
Image Watermarking Based on J oint DWT-DCT,
International J ournal of Digital Content Technology and its
Applications Vol. 3, No. 2, pp. 42-54, J une 2009.

[4] W. H. Bin, Y. H. Liang, W. C. Dong, W. S. Ming: A New
Watermarking AlgorithmBased on DCT and DWT Fusion,"
International Conference on Electrical and Control
Engineering, pp. 2614 - 2617, 2010.

[5] M. Chandra, S. Pandey: A DWT Domain Visible
Watermarking Techniques for Digital Images," International
Conference on Electronics and Information Engineering, pp.
V2-421 - V2-427, 2010.

[6] R. Dubolia, R. Singh, S.S. Bhadoria and R. Gupta: Digital
Image Watermarking by Using Discrete Wavelet Transform
and Discrete Cosine Transform and Comparison Based on
PSNR, Communication Systems and Network Technologies
(CSNT) International Conference on, pp. 593 - 596, 2011.

[7] A. Sarma, A. Ganguly: A Combined DCT/DWT based
Image Watermarking Algorithm, In Proceedings of ICECE,
Guwahati, 2012.

[8] A. Sarma, A. Ganguly: Subband/DCT based novel Image
Watermarking Scheme, In Proceedings of NCETACS,
Shillong, 2012.

TABLE III. EXPERIMENTAL RESULTS SHOWING PSNR, NC
AND THE EXTRACTED WATERMARK

S-ar putea să vă placă și