unit
Unit2;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, pngimage, ExtCtrls, StdCtrls;
type
TForm2 =
class
(TForm)
Button1: TButton;
Image1: TImage;
procedure
Button1Click(Sender: TObject);
private
public
end
;
var
Form2: TForm2;
implementation
{$R *.dfm}
procedure
TForm2
.
Button1Click(Sender: TObject);
var
Color: TColor;
begin
Image1
.
Picture
.
LoadFromFile(
'1.png'
);
Color:=Image1
.
Picture
.
Bitmap
.
Canvas
.
Pixels[
10
,
10
];
Showmessage(inttostr(Color));
end
;
end
.