Content deleted Content added
→Microsoft Windows: Grammar fixes |
Maxeto0910 (talk | contribs) no sentences |
||
(19 intermediate revisions by 16 users not shown) | |||
Line 1:
{{More citations needed|date=September 2021}}
{{about|color lookup tables|color schemes used in design software|color scheme|the UI element also known as utility window|Palette window}}
{{short description|In computer graphics, a finite set of available colors}}
{{Color depth}}
{{multiple image
}}
In [[computer graphics]], a '''palette''' is the set of available colors from which an image can be made. In some systems,
==Description==
As of 2019, the most common image colorspace in
==Master palette==
[[File:Palette sizes.ogv|right|thumb|300px|An adaptive color palette expanding from 2 colors to 256 colors, demonstrating how the image changes (click to see animation)
In an application showing many different [[thumbnail|image thumbnail]]s in a mosaic on screen, the program may not be able to load all the adaptive palettes of every displayed image thumbnail at the same time in the hardware color registers. A solution is to use a unique, common ''[[List of software palettes#RGB arrangements|master palette]]'' or ''universal palette'', which can be used to display with reasonable accuracy any kind of image.
This is done by selecting colors in such way that the master palette comprises a full [[RGB color space]] "in miniature", limiting the possible levels that the red, green, and blue components may have. This kind of arrangement is sometimes referred to as a ''uniform palette''.<ref>[http://tex.imm.uran.ru/alchemy.pdf Handmade Software's ''Image Alchemy'' User's Manual.]</ref> The normal [[human eye]] has sensibility to the three primary colors in different degrees: the more to the green, the less to the blue. So RGB arrangements can take advantage of this by assigning more levels for the green component and
A master palette built this way can be filled with up to {{nowrap|[[List of software palettes#8-8-4 levels RGB|8R×8G×4B {{=}} 256 colors]]}}, but this does not leave space in the palette for reserved colors, color indices that the program could use for special purposes. It is more general to use only {{nowrap|[[List of software palettes#6 level RGB|6R×6G×6B {{=}} 216]]}} (as in the [[Web colors]] case), {{nowrap|[[List of software palettes#6-8-5 levels RGB|6R×8G×5B {{=}} 240]]}} or {{nowrap|[[List of software palettes#6-7-6 levels RGB|6R×7G×6B {{=}} 252]]}}, which leaves room for some reserved colors.
Line 34 ⟶ 35:
==Adaptive palette==
When using [[indexed color]] techniques, real life images are represented with better fidelity to the [[24-bit color|truecolor]] original one by using [[List of software palettes#Adaptive palettes|adaptive palette]]s (sometimes
But this creates a heavy dependence between the image [[pixel]]s and its adaptive palette. Assuming a limited 8-bit depth graphic display, it is necessary to load a given image's adaptive palette into the color hardware registers prior to loading the image surface itself into the [[Framebuffer|frame buffer]]. To display different images with different adaptive palettes, they must be loaded one by one, as in a [[slideshow]]. Here are samples of four different indexed color images with color patches to show their respective (and largely incompatible) adaptive palettes:
Line 72 ⟶ 73:
[[2D computer graphics|2-D painting programs]], like [[Microsoft Paint]] and [[Deluxe Paint]], can employ the user designated ''background color'' as the transparent color when performing [[cut, copy, and paste]] operations.
Although related (due to they are used for the same purposes), [[Image mask|image bit masks]] and [[alpha channel]]s are techniques which do not involve the use of palettes nor transparent color at all, but off-image added extra binary data layers.
==Software palettes==
Line 79 ⟶ 80:
[[Microsoft Windows]] applications manage the palette of 4-bit or 8-bit indexed color display devices through specialized functions of the [[Win32 API]]. The applicability of palettes in [[Highcolor]] and [[24-bit color|Truecolor]] display modes becomes questionable. These APIs deals with the so-called "system palette" and with many "logical palettes".
The "system palette" is a copy in [[Random-access memory|RAM]] of the color display's hardware registers, primarily a physical palette, and it is a unique, shared common resource of the system. At boot, it is loaded with the [[List of software palettes#Microsoft Windows and IBM OS/2 default 16-
When a given application intends to output colorized graphics and/or images, it can set their own "logical palette", that is, its own private selection of colors (up to 256). It is supposed that every graphic element that the application tries to show on screen employs the colors of its logical palette. Every program can manage freely one or more logical palettes without further expected interference (in advance).
Line 96 ⟶ 97:
==References==
* Julio Sanchez and Maria P. Canton (2003). ''[https://books.google.com/books?id=gZ5SDTpMR-MC
* [http://msdn.microsoft.com/en-us/library/dd183459(VS.85).aspx Color palettes at Microsoft Developer Network (MSDN)]
* [http://msdn.microsoft.com/en-us/library/dd162938%28VS.85%29.aspx The RGBQUAD color table entry in BITMAPINFO structure at Microsoft Developer Network (MSDN)]
Line 105 ⟶ 106:
[[Category:Computer graphics data structures]]
[[Category:Color depths]]
[[Category:
[[Category:Articles containing video clips]]
|