Shannon V. OKeets
Posts: 22095
Joined: 5/19/2005 From: Honolulu, Hawaii Status: offline
|
Here is my current design document for redesigning how colors are stored in the data files for each country and where they are used when rendering the unit counter images on the screen. ================================== Unit Colors (as of January 9, 2006) There are 3 levels of resolution for the unit counters: high, medium, and low. The high resolution contains the most information and requires the most control over colors. There are 3 basic unit types: land, air, and naval. The land is the most demanding because of the wide variety of unit types within that group. The colors are stored by country, though there are some subcountries for which colors are irrelevant because they have no units (e.g., Karelia, Bessarabia). The colors for the Communist Chinese are hard coded into the program, as are the colors for airborne, marine, and artillery units. That might change at a later date. All the colors are stored in RGB format. This is a hexadecimal number of 6 digits. The leftmost two digits are the Blue intensity, the middle are the Green intensity, and the rightmost are the Red intensity. This is backwards (i.e., BGR), but I didn’t design the format. Each 2 hexadecimal number ranges from $00 to $FF (0 to 255). The $ indicates that it is hexadecimal. Pure red is $0000FF; pure green is $00FF00; and pure blue is $FF0000. White is $FFFFFF and black is $000000. The program also accepts these basic colors as clRed, clGreen, clBlue, clWhite, and clBlack. There are about a dozen others available as clXXXX but you can get perfect control using the hexadecimal digits. Here are the data fields for the colors that are part of each country’s data. 1 Basic color. This is the background color for all the country’s units: land, air, and naval. 2 Icon color. This is the color used for the icon silhouette for the air and naval units at medium and low resolution. 3 Text color. This is the color used for all the numbers for air and naval units that do not appear in circles/rectangles. It is also used for a land unit when writing its name, size (XXX), reserve status (R), and country abbreviation. 4 Strength-movement color for non-elite. The color used for the strength and movement factor for non-elite land units. 5 Strength-movement outline flag for elite. When this boolean variable is true (i.e., -1), the elite unit’s strength - movement numbers are written inside a black outline. This is used for countries that have a very light basic color (#1) so the white numbers used for elite units have higher contrast and can be seen. It is set to true for the Chinese, Italians, and French. 6 Strength-movement outline flag for non-elite. This is similar to #5. It is not used in the default color setting for any country but is available to players for making increasing the contrast for non-elite units. For example, it can be used when using red for #4 for the German SS. 7 Outline color for #6. This is the color that is used for the outline when #6 is set to true. 8 Outline color for NATO symbol for non-elite. Non-elite units use this color for the outline of the NATO symbol and the graphic (e.g., X for infantry, / for cavalry). 9 Outline color for NATO symbol for elite. Elite units use this color for the outline of the NATO symbol and the graphic (e.g., X for infantry, / for cavalry). 10 Letter color for NATO symbol non-elite . This color is used for non-elite units for the M, T, and P letters inside the NATO symbol (for Militia, Territorial, and Partisan units respectively). 11 Letter color for NATO symbol for elite . This color is used for elite units for the M, T, and P letters inside the NATO symbol (for Militia, Territorial, and Partisan units respectively). 12 Interior color for NATO symbol for non-elite. This is the color used for the interior of the NATO symbol for non-elite, non-division units. Elite units have white interiors (exception: Commonwealth member nations do not have white interiors). Divisional units use the color #13. This color is typically a darker version of #1. This color is not used for airborne or marine units. Instead, those units have the hard coded colors for their respective types (light blue and light green). 13 Interior color for NATO symbol for divisions. This is the color used for the interior of the NATO symbol for divisional units. This color is not used for artillery, airborne, or marine divisions. Instead, those units have the hard coded colors for their respective types (light blue, light blue, and light green).
_____________________________
Steve Perfection is an elusive goal.
|