Guest User

Untitled

a guest
Jun 16th, 2018
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Delphi 0.82 KB | None | 0 0
  1. for j := 0 to image1.picture.Height -1 do
  2. begin
  3.   for i := 0 to image1.picture.width -1 do
  4.     begin
  5.       while length(text) > 0 do
  6.         begin
  7.            r := getrvalue(image1.Canvas.Pixels[i,j]);
  8.            if text[1] = '0' then r := r shr 1 shl 1 else r := r or 1; delete(text,1,1);
  9.            g := getgvalue(image1.Picture.Bitmap.Canvas.Pixels[i,j]);
  10.            if length(text) > 0 then if text[1] = '0' then g := g shr 1 shl 1 else g := g or 1; delete(text,1,1);
  11.            b := getbvalue(image1.Picture.Bitmap.Canvas.Pixels[i,j]);
  12.            if length(text) > 0 then if text[1] = '0' then b := b shr 1 shl 1 else b := b or 1; delete(text,1,1);
  13.            image1.Canvas.Pixels[i,j] := r + g shl 8 + b shl 16 ;
  14.            showmessage(format('%8.8X',[image1.Picture.Bitmap.Canvas.Pixels[i,j]]));
  15.         end;
  16.     end;
  17. end;
Add Comment
Please, Sign In to add comment