Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var
- b: Byte;
- function ColorToGrayL(Color: Integer): Byte;
- begin
- Result := Trunc((0.2126 * (Color and $FF)) +
- (0.7152 * ((Color shr 8) and $FF)) +
- (0.0722 * ((Color shr 16) and $FF)));
- end;
- begin
- b := ColorToGrayL(16777215);
- WriteLn(B);
- end.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement