diff --git a/doc/en/Gdk/VisualType.xml b/doc/en/Gdk/VisualType.xml index a5dde36d6..126fe3717 100644 --- a/doc/en/Gdk/VisualType.xml +++ b/doc/en/Gdk/VisualType.xml @@ -1,5 +1,5 @@ - + gdk-sharp 0.0.0.0 @@ -7,8 +7,20 @@ Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - To be added - To be added + Describe the how pixel values are converted into RGB values for display. + + + Visuals are a very important concept that is often + overlooked. Roughly, a visual defines the memory + representation that a piece of hardware uses to store the + contents of an image. X supports different kinds of visuals to + suit the different kinds of hardware out there. + + + Some of this information comes from Federico Mena's excellent + "X Concepts" document from http://www.nuclecu.unam.mx/~federico/docs/x-concepts. + + System.Enum @@ -34,8 +46,15 @@ - To be added - To be added + Static gray visuals are those in which you cannot change the gray intensities of the hardware. + + Plain monochrome (B/W) displays or fixed 4-gray displays may + be of the static gray kind. Grayscale visuals are those in + which you can change the gray intensities used by the + hardware. Exotic 12-bit grayscale displays (as used for + medical visualization) that let you change the gray + intensities may be of the grayscale type. + @@ -46,8 +65,12 @@ - To be added - To be added + Grayscale visuals are used for displays that use a single channel of color information. + + Black and white or grayscale monitors (including amber and + green monitors) may use this type of visual. These visuals + can be either static gray or grayscale. + @@ -58,8 +81,14 @@ - To be added - To be added + An indexed color visual, where colors can not be changed. + + Static color visuals are those in which you cannot change + the actual colors that the indexes correspond to (a static + palette). Remember the old CGA cards with four fixed colors + in graphics mode? These could be considered of the static + color type. + @@ -70,8 +99,17 @@ - To be added - To be added + An indexed color visual, where colors can change. + + Pseudo color visuals are those in which you can change the + actual colors that the indexes correspond to. Each index + maps to an RGB triplet that defines the color that will be + displayed on the screen. You can change these RGB triplets + for each index. Pseudo color visuals are very common in + graphics cards. Graphics cards with 256 colors that you can + change, for example, VGA cards, are of the pseudo color + type. + @@ -82,8 +120,20 @@ - To be added - To be added + True color visuals use the exact RGB values you specified + for a pixel + + + TrueColor visuals store explicit RGB values for every + pixel, instead of storing a single value like indexed + visuals. + + + TrueColor visuals map the RGB into the screens RGB values + without any changes. There is no transformation applied to + it. + + @@ -94,8 +144,30 @@ - To be added - To be added + DirectColor visuals use RGB encoding, with a + correction palette. + + + TrueColor visuals store explicit RGB values for every + pixel, instead of storing a single value like indexed + visuals. + + + The values in a direct color visual go through an + indirection step before being sent to the display. Each of + the R/G/B values you specify is an index in separate + tables, and those tables contain a translated value. So an + RGB triplet gets translated into an R'G'B' triplet, + i.e. the three tables together define an f(r, g, b) -> + (r', g', b') function. For most purposes, your tables will + be filled by the identity function and you will get + linearly increasing intensity values for each of the RGB + channels. Things can become quite interesting, however, + when you modify the tables to have a nonlinear mapping. If + you fill them using an exponential function, you can do + color correction on hardware + +