Professional Documents
Culture Documents
Dr Khurram Khurshid
2
Steganography
wBefore Moving On ….
wRecall – Logical Shift Operators
Logical left shift one bit Logical right shift one bit
3
Steganography
b = 0 or 1 always 0
L-Shift 2
This introduces the
possibility of logical
Image Out
OR
encoding other
information in the X-Shift n = logical left or right shift by n
low-order bits. bits.
5
Steganography
182
1 0 1 1 0 1 1 0
220
R-Shift 2 1 1 0 1 1 1 0 0
0 0 1 0 1 1 0 1
R-Shift 6
L-Shift 2 03
180 0 0 0 0 0 0 1 1
1 0 1 1 0 1 0 0
183
⊕
1 0 1 1 0 1 1 1
Steganography
183
1 0 1 1 0 1 1 1
L-Shift 6
How to get the second image
192
1 1 0 0 0 0 0 0
183
⊕ No need to shift right
1 0 1 1 0 1 1 1
What would you
do to get back
original data?
Steganography
8-bit-per-band, 3-band,
“original” image
9
Steganography
6-bit-per-band, 3-band,
quantized image
10
Steganography
The histograms of the two versions indicate which is which. If the 6-bit
version is displayed as an 8-bit image it has only pixels with values 0, 4,
8, … , 252.
11
Steganography
The second image is invisible because the value of each pixel is between 0
and 3. For any given pixel, its value is added to the to the collocated pixel in
the first image that has a value from the set {0, 4, 8, … , 252}. The 2nd image
is noise on the 1st .
12
L-Shift 6
Steganography
?
To recover the second image (which is 2 bits per
pixel per band) simply left shift the combined image
by 6 bits.
13
L-Shift 6
Steganography
image
Image Out
15
Steganography
Original Image
16
Steganography
Image quantized to
4-bits per pixel.
17
Steganography
18
Steganography
Extracted Image
19
Steganography
http://mozaiq.org/encrypt/
20
Relationships between pixels
y-1
y+1
21
4- Neighbors of a Pixel –N4(p)
y-1
y-1
22
Diagonal Neighbors of a Pixel –
ND(p)
x-1 x x+1
y-1
y-1
23
8- Neighbors of a Pixel –N8(p)
x-1 x x+1
y-1
y-1
N8 ( p ) = N 4 ( p ) ∪ N D ( p )
(x-1,y), (x+1,y), (x, y-1), (x,
y +1 )
(x-1,y-1), (x+1,y-1), (x-1, y+1), (x+1,
y +1 )
24
Determine different regions in
the image
25
Connectivity
similarity
n
26
Connectivity
V: Set of gray levels used to define the criterion of similarity
4-connectivity
27
Connectivity
V: Set of gray levels used to define the criterion of similarity
8-connectivity
28
Connectivity
V: Set of gray levels used to define the criterion of similarity
If gray level
29
Example: m – Connectivity
Note: Mixed connectivity can eliminate the multiple path connections that often
occurs in 8-connectivity
30
Paths
where (x0, y0) = (x, y) & (xn,yn) = (s, t), and (xi,yi) is
adjacent to (xi-1 ,yi-1 ) 1≤i ≤n
31
CC labeling – 4 Connectivity
wProcess the image from left to
right, top to bottom:
1.) If the next pixel to process is 1
i.) If only one of its neighbors
(top or left) is 1, copy its
label.
Pass
wRe-label with the smallest of equivalent 2
labels
32
CC labeling – 4 Connectivity
33
CC labeling – 4 Connectivity
34
CC labeling – 8 Connectivity
35
CC labeling – 8 Connectivity
Background pixel
Background pixel
Unlabeled Pixel
Unlabeled Pixel
Label 1
36
CC labeling – 8 Connectivity
Label 3
37
CC labeling – 8 Connectivity
38
CC labeling – 8 Connectivity
Label 1 Label 1
Label 2 Label 2
Label 3 Label 3
39
CC labeling – 8 Connectivity
40
Distance Metrics
41
City block distance (D4
distance)
D4 ( p, q ) = x − s + y − t
42
Chessboard distance (D8
distance)
D8 ( p, q ) = max( x − s , y − t )
43
Euclidean Distance
w
w De ( p, q ) = ( x − s )2 + ( y − t )2
w
q(s,t)
w
r
w
w
p(x,y)
44
Arithmetic Operations
45
Arithmetic Operations
46
Arithmetic Operations
f s = K [ f m max( f m )]
47
Logical Operations (Binary
Images)
48
Acknowledgements
wDigital Image Processing”, Rafael C. Gonzalez & Richard E. Woods, Addison-Wesley, 2002
wPeters, Richard Alan, II, Lectures on Image Processing, Vanderbilt University, Nashville,
TN, April 2008
Material in these slides has been taken from the following
wBrian Mac Namee, Digitial Image Processing, School of Computing, Dublin Institute of
Technology
wComputer Vision for Computer Graphics, Mark Borg
resources
49
Acknowledgements
wStatistical Pattern Recognition: A Review – A.K Jain et al., PAMI (22) 2000
wPattern Recognition and Analysis Course – A.K. Jain, MSU
Material in these slides has been taken from, the following
w
w
50