How do I identify the colour of a pixel at the location of a mouse click in Firemonkey?

  

I have done something similar in VCL. I’m by no means a professional, and I do not expect this to be the best way to do it, but here’s what I had:

pt := TImage(Sender).ScreenToClient(Mouse.CursorPos);
color := image1.Canvas.Pixels[pt.X, pt.Y];

I’m basically looking for some assistance in effectively porting this code into firemonkey, to get the same result, considering images/canvases etc. seem to work a little differently and I’m pretty unfamiliar with it.

Thanks in advance.

Comments are closed.