hallöchen community
die panels haben von anfang an ne weisse farbe.
mal angenommen das foto was ich auf farbanteile durchsuche hat an der vorgegebenen Pixelposition keinen blau oder grünanteil, und somit ändert sich die panelfarbe auch nicht.
wie schreibe ich nun ne IF routine das wenn die panelfarbe nach dem prüfen immernoch weiss ist, an pixelposition X+1,Y+1 gesucht wird, bzw anstatt der 506 meinetwegen ne 508?
Code:
begin
DWord(AColor) := GetPixel(
dc,506,554);
//Blauanteil eines Fotos
if (AColor[1] > 220) and (AColor[2] > 95) and (AColor[3] > 190) then
panel1.color :=clBLUE;
//Grünanteil eines fotos
if (AColor[1] > 190) and (AColor[2] < 50) and (AColor[3] < 50) then
panel2.color :=clGREEN;
if panel1.color := clwhite then... ??!
danke.