/[opencvs]/eyes/extract_hidden_message.pl
ViewVC logotype

Contents of /eyes/extract_hidden_message.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations)
Thu Mar 8 11:49:30 2012 UTC (6 years, 6 months ago) by hib
Branch: MAIN
CVS Tags: HEAD
File MIME type: text/plain
building girl3 (jenni)
1 binmode(STDOUT);
2 binmode(STDIN);
3 $m = "";
4 $r = "";
5 $rr = 0;
6 $count = 1;
7 while (<>) {
8 @e = split(/\|/g);
9 $e[2] = $e[2] + 0;
10 if (substr($m,0,4) eq "nT9f") {
11 print "count $count $e[0]" . "|" . $e[1] . "|" . $e[2] . "\n";
12 }
13 $rr = $rr+$rr + ($e[0] % 2);
14 $rr = $rr+$rr + ($e[1] % 2);
15 $rr = $rr+$rr + ($e[2] % 2);
16 $r .= "abc";
17 if (substr($m,0,4) eq "nT9f") {
18 print "vv s $s (" . chr($s) . ") rr ($rr) r ($r) " . "$e[0]" . "|" . $e[1] . "|" . $e[2] . "m $m\n";
19 print "len(r) " . length($r) . "\n";
20 }
21 if (length($r) >=8) {
22 if (length($r) ==10) {
23 $s = int($rr >> 2);
24 $rr = $rr & 3;
25 $r = "12";
26 }
27 elsif (length($r) ==9) {
28 $s = int($rr >> 1);
29 $rr = $rr & 1;
30 $r = "1";
31 }
32 elsif (length($r) ==8) {
33 $s = $rr;
34 $rr = 0;
35 $r = "";
36 }
37 else {
38 print "\n\n\nwhatdhasdsahjsadsjakdjzk\n";
39 exit(-1);
40 }
41 if (substr($m,0,4) eq "nT9f") {
42 print "^^ s $s (" . chr($s) . ") rr ($rr) r ($r) " . "$e[0]" . "|" . $e[1] . "|" . $e[2] . "m $m\n";
43 }
44 if ($s == 10) {
45 print $m . "\n";
46 $m = "";
47 }
48 else {
49 $m .= chr($s);
50 }
51
52 # print "$s ";
53 }
54 $count++;
55 }
56 print $m;

  ViewVC Help
Powered by ViewVC 1.1.5