Einzelnen Beitrag anzeigen

Benutzerbild von alcaeus
alcaeus

Registriert seit: 11. Aug 2003
Ort: München
6.537 Beiträge
 
#3

Re: color integer wert von "grau"

  Alt 13. Nov 2004, 23:34
Hi Nico,

sieh mal in der OH nach: Delphi-Referenz durchsuchenTColor. Dort steht:

Meine heißgeliebte OH schreibt:
If you specify TColor as a specific 4-byte hexadecimal number instead of using the constants defined in the Graphics unit, the low three bytes represent RGB color intensities for blue, green, and red, respectively. The value $00FF0000 represents full-intensity, pure blue, $0000FF00 is pure green, and $000000FF is pure red. $00000000 is black and $00FFFFFF is white.

If the highest-order byte is zero, the color obtained is the closest matching color in the system palette. If the highest-order byte is one ($01), the color obtained is the closest matching color in the currently realized palette. If the highest-order byte is two ($02), the value is matched with the nearest color in the logical palette of the current device context.

Bei Graustufen sind einfach die Bytes für Rot, Gelb und Blau genau gleich, somit ergeben sich die 256 verschiedenen Grautöne.
Beantwortet das deine Frage?

Greetz
alcaeus
Andreas B.
Die Mutter der Dummen ist immer schwanger.
Ein Portal für Informatik-Studenten: www.infler.de
  Mit Zitat antworten Zitat