-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDisplaying_n.m
48 lines (39 loc) · 943 Bytes
/
Displaying_n.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
% Order of Running These Codes
% 1) EncodingImage.m
% 2) Converting.m
% 3) Embedding.m
% 4) Decoding.m
% 5) Displaying.m
figure
tiledlayout(3,3)
nexttile
imshow(Input_Image)
title("Image To be Hidden");
nexttile
imshow(Cover_Image)
title("Cover Image");
nexttile
imshow(round(Quantized_Image)/255)
title("Quantized Image");
nexttile
imshow(Final_Steganographed_Image)
title("Steganographed Image");
nexttile
imshow(Obtained_Image)
title('Decoded Hidden Image');
mse = double(Red_Part) - Steganographed_Image1;
mse = double(mse);
Mse = [];
for i = 1 : DCT_Block_Size : n3
for j = 1 : DCT_Block_Size : n4
Block_Matrix = mse(i:i+DCT_Block_Size-1,j:j+DCT_Block_Size-1);
Mse = [Mse zigzag(Block_Matrix)];
end
end
sum = 0.00;
N = 1024*1024;
for j = 1:Embedding_Length
sum = sum + (Mse(i)^2)/N;
end
MAX = 255*255;
PSNR = 10*log10(double(MAX/sum))