6.2.15.1. SETTING BASIC COLORS

next, previous Section / Table of Contents / Index Option [P] selected from the basic parameter menu P, see Sec. 6.2.15, allows you to redefine all basic parameters connected with color painting in plots which includes color selection and shading. The paint menu PP reads ========== BASIC PARAMETER OPTIONS ======================================== Basic color table: ncolb colors, nsh tones Shading (Diff,Lamb,Spec/Theta,Phi) = qdiff, qlamb, qspec / thtsh, phish B/W/LC= ib iw ilc, palette= nptot, font= [ fontname ] Painting: [B]ascol [S]hade [C]odes [W]orkb [G]ray(fgr) c[T]abl [F]ont [X]plot [?,]esc =================================================================== 39 ==== Here ncolb is the total number of paint colors and nsh the number of tones of each paint color defined at present, see Sec. 5.4. Ball shading is determined by weights qdiff (diffuse background), qlamb (Lambert shading), qspec (specular reflection) which are relative values ranging between 0.0 and 1.0 with qdiff + qlam + qspc = 1.0. Further, thtsh and phish give the incident light direction with respect to the screen normal used for shading, see Sec. 5.4. The numbers ib, iw, ilc are the present color table entries of the base colors "black", "white" and of the default link color while nptot gives the number of entries in the color palette determining the sequence of paint colors used to paint atoms. The gray switch flag fgr reads "on" or "off" depending on whether screen colors are replaced by respective gray tones, see Sec. 5.4. > [B] selected from submenu PP allows you to reset and list all basic paint color definitions. The basic paint color menu PPB reads ======================================================================== Basic color table: ncolb colors, nsh tones Basic colors: [N]ew [M]od [A]dd [D]el t[O]ne [R]gbmx [L]ist c[T]abl [X]plot [?,]esc ================================================================== 40 == where ncolb is the total number of paint colors and nsh the number of color tones of each paint color defined at present, see Sec. 5.4. Note that existing colors can be changed also interactively with the color/shading workbench, see Sec. 6.2.15.2. > > [N] selected from submenu PPB allows you to redefine all basic paint colors from scratch. The prompt No. of basic colors NCOLB ( <ncmax, 0=esc) : asks for the number ncolb of basic colors to be defined in the following where ncmax gives the maximum number of colors available. Dummy input ncolb = 0 returns to submenu PPB without affecting the present color definitions while for ncolb > 0, the prompts Input ncolb basic colors : 1) NR,NG,NB/Qbot,Qbas,Qenh,Qtop/Qgam : ... ncolb) NR,NG,NB/Qbot,Qbas,Qenh,Qtop/Qgam : ask for ncolb sets of eight numbers, nr, ng, nb, qbot, qbas, qenh, qtop, qgam, defining each new paint color after which BALSAC returns to submenu PPB. Here (nr, ng, nb) gives the RGB definition of the generating color where all values must lie within the range [0, rgb] with rgb = 63 for DOS/VGA and = 65635 for Unix. Further, qbot, qbas, qenh, qtop are factors determining the darkest, default dark, default light, and lightest tone of the paint color where all values must lie within the range [0, 1]. Finally, qgam is the gamma factor determining the distribution of color tones between darkest and lightest tone used for continuous shading. The color definitions are discussed in detail in Sec. 5.4. Note that the above input of 8*ncolb numbers may be tedious and editing the respective initialization file, see Sec. 6.4.10, may be faster and safer. > > [M] selected from submenu PPB allows you to modify a specific basic paint color from the present set. The prompt Modify selected basic color N (1- ncolb, 0=esc) : asks for the number n of a basic paint color within the range [1,ncolb] to be modified. Dummy input n = 0 returns to submenu PPB without affecting the present color definitions while for n > 0, the prompt Color( n)= nr ng nb / qbot qbas qenh qtop / qgam Redefine NR,NG,NB/Qbot,Qbas,Qenh,Qtop/Qgam ("/"=esc) : shows the present definition of paint color n and asks for eight numbers, nr, ng, nb, qbot, qbas, qenh, qtop, qgam, defining the modified paint color after which BALSAC returns to submenu PPB. The color parameters are explained in option [N] above and in Sec. 5.4. Dummy input "/" will keep the original definition of paint color n. > > [A] selected from submenu PPB allows you to add a basic paint color to the present set. The prompt Add basic color NR,NG,NB/Qbot,Qbas,Qenh,Qtop/Qgam ("8*0"=esc) : asks for eight numbers, nr, ng, nb, qbot, qbas, qenh, qtop, qgam, defining the new paint color to be added after which BALSAC returns to submenu PPB. The color parameters are explained in option [N] above and in Sec. 5.4. Dummy input "8*0" will return to submenu PPB without a color added. > > [D] selected from submenu PPB allows you to remove a basic paint color from the present set. The prompt Remove basic color N (1-ncolb, 0=esc) : asks for the number n of a basic paint color within the range [1,ncolb] to be removed. Dummy input n = 0 returns to submenu PPB without affecting the present color definitions while for n > 0 basic color no. n will be removed from the set and all entries in the color palette referring to the removed color will be replaced by basic color no. 1 after which BALSAC returns to submenu PPB. > > [O] selected from submenu PPB allows you to change the number of color tones generated for each basic paint color and used for ball shading as well as for background painting in plots. The prompt No. of tones NSH (nsho, max=nshmax, 0=esc) asks for an integer defining the number of color tones to be generated for each basic paint color. Here nsho gives the present value and nshmax (= nctot/ncolb) denotes the largest available value determined by the total number of colors nctot and the number of paint colors ncolb. Dummy input nsh = 0 keeps the present definition while for nsh > 0 the internal color table is modified according to the new number of tones after which BALSAC returns to submenu PPB. Values nsh > nshmax will be truncated to nsh = nshmax. > > [R] selected from submenu PPB allows you to change the global maximum value allowed for components (r, g, b) in RGB color settings. The prompt RGB maximum (rgbmaxo, 0=esc) : asks for an integer giving the new maximum value rgbmax where rgbmaxo in the prompt gives the old value. The input leads to a global rescaling of all RGB definitions by a factor rgbmax/rgbmaxo after which BALSAC returns to submenu PPB. Allowed values for rgbmax depend on the graphics adapter where the standard values are N = 63 (2**6-1) for DOS and N = 65535 (2**16-1) for Unix/X.11 Windows systems. RGB rescaling may become necessary if BALSAC output files of LATUSE or PLOT3D type include initialization information and are transferred between DOS and Unix systems. WARNING: RGB rescaling can result in strange color definitions and should generally be avoided. > > [L] selected from submenu PPB allows you to list all basic paint color definitions of the present set. The prompt ncolb basic colors : list NA,NE : asks for a range [na, ne] of the set of ncolb basic paint colors to be listed. For < na <= ne <= ncolb the listing shows as NR NG NB / Qbot Qbas Qenh Qtop / Qgam na) nr ng nb / qbot qbas qenh qtop / qgam ... ne) nr ng nb / qbot qbas qenh qtop / qgam after which BALSAC returns to submenu PPB. The color parameters in this list are explained in option [N] above and in Sec. 5.4. > > [T] selected from submenu PPB displays a color test table (in a separate graphics window, Unix) showing all color definitions together with color numbers available inside BALSAC. The colors are described in the initialization file and generated when BALSAC is started, see Sec. 5.4. The first line from the top of the table shows blocks of the base colors together with their names where the DOS/VGA version of BALSAC lists four colors defining "black", "white", "stereo red", "stereo blue" by black white (st)red (st)blue and the Unix/X.11 version lists eight colors defining "black", "white", "background", "text", "bonds", "stereo red", "stereo blue", "stereo white" by blck wht bckg txt bnd srd sbl swt Then the dark and light tones of all paint colors in the sequence of the palette definition are shown together with a line colors: palette= nptot, total= nctot where nptot is the number of entries in the color palette and nctot is the total number of RGB colors defined at present. Next for each of the ncolb paint colors the sequence of nsh tones, see Sec. 5.4, is displayed by a row of blocks going from darkest to lightest tones. The line to the right of each block sequence reads j ( def.dark(j) , def.light(j) ) ns(j)+1 - ns(j)+nsh where j is the paint color index (to be used in the palette for painting (shaded) balls), def.dark(j) and def.light(j) are color table entries of the default dark and light tones, and ns(j)+1 denotes the darkest, ns(j)+nsh the lightest tone of paint color j. In addition the two default color tones are marked by crossing lines in the respective color blocks (def.dark = white lines, def.light = black lines). Pressing any key clears the window and returns to the previous menu. The Unix/X.11 version of BALSAC shows in addition glossy-shaded balls next to each of the paint color rows using the respective color tones and demonstrating the incident light direction as well as diffuse, Lambert shading, and specular reflection contributions. > > [X] selected from submenu PPB plots the present lattice section (switching to graphics mode (DOS) or opening a graphics window (Unix)) or lists its atom coordinates depending on the plot/list mode defined in the graphics option, see Sec. 6.2.7. > > [,] selected from submenu PPB returns to the paint menu PP. > [S] selected from submenu PP allows you to list and reset all parameters relevant for ball shading in plots. The shading menu PPS reads ================================================= Shading: [W]eights [A]ngles c[T]abl [?,]esc =========================================== 41 == > > [W] selected from submenu PPS allows you to redefine the relative weights of different contributions to shading. The prompt Shading weights DIFF,LAMB,SPEC (qdiff qlamb qspec|"3*-1"=esc) : asks for three numbers, qdiff, qlamb, qspec, defining the relative weights of shading contributions due to the diffuse background, to Lambert shading, and to specular reflection as described in detail in Sec. 5.4. Meaningful values should range between 0 and 1 with qdiff + qlamb + qspec = 1 (defaults are qdiff = 0.1, qlamb = 0.35, qspec = 0.55). After the input BALSAC returns to submenu PPS. Dummy input "3*-1" will keep the present shading values. > > [A] selected from submenu PPS allows you to redefine the direction of the incident light used for shading. The prompt Shading angles THETA,PHI (theta phi | "/"=esc) : asks for two numbers, theta, phi, defining the polar and azimuthal angles of the incident light. The angles are taken with respect to the screen normal direction where polar angle phi = 0 corresponds to the vertical y direction on the screen (defaults are theta, phi = 65, -25 degrees referring to light shining from the upper left front location relative to the viewer). For further details consult Sec. 5.4. After the input BALSAC returns to submenu PPS. Dummy input "/" will keep the present angle values. Note that shading angles can be changed also interactively with the color/shading workbench, see Sec. 6.2.15.2. > > [T] selected from submenu PPS displays a color test table (in a separate graphics window, Unix) showing all color definitions together with color numbers available inside BALSAC. This option is identical to option [T] of the basic paint color menu PPB described above. > > [,] selected from submenu PPS returns to the paint menu PP. > [C] selected from submenu PP allows you to redefine the default colors for "black", "white", and for links between atoms (base colors) as well as all entries of the color palette which determines the sequence of colors used to paint atoms. The color palette menu PPC reads ============================================================== Basic codes : B/W/LC= ib iw ilc gray= fgr Palette(nptot) : np(1) ... np(nptot) Palette description (partial) Colors: [B]lack/white/links [P]alette c[T]abl [?,]esc ======================================================== 42 == where the numbers ib, iw, ilc give the color codes (color table entries, see Sec. 5.4) of default colors for "black", "white", and for links between atoms. The gray switch flag fgr reads "on" or "off" depending on whether screen colors are replaced by respective gray tones. The next line lists the complete color palette of nptot entries np(i), i=1...nptot defined at present which determines the sequence of basic paint colors used to paint atoms. The line "Palette description (partial)" contains a listing of the palette part which is used in the present atom painting. For a BALSAC/LATTICE session producing plots where atoms are painted according to layer number the palette listing reads n3 layers: np(1) ... np(n3) where np(1) ... np(n3) are palette entries (pointing at a basic paint color) of each of the n3 layers of the lattice section. For a BALSAC/LATTICE or BALSAC/CLUSTER session where atoms are painted according to element (nuclear charge) the palette listing reads nel elements: El(np(1)) ... El(np(n3)) where np(1) ... np(n3) are palette entries of each of the nel different elements appearing in the lattice section or cluster with the element names given by El. Note that all base colors and the palette definition can be changed also interactively with the color/shading workbench, see Sec. 6.2.15.2. > > [B] selected from submenu PPC allows you to redefine the default colors used for "black", "white", and for links between atoms. The prompt Black/white/links color codes IB,IW,ILC ( ib, iw, ilc) : asks for three integers defining the color codes ib, iw, ilc (entries of the internal color table) used for default colors "black", "white", and for links between atoms where the values in parenthesis give the present settings. Colors "black" and "white" are used for circle/dot/ball drawings in graphics output, for the title line and for the wire frame about the lattice section or cluster. Lines/sticks connecting atoms are painted with default color ilc if not redefined by individual values, see Sec. 6.2.7.1. Resetting these colors may improve the visibility or can achieve special color effects. After complete input BALSAC returns to submenu PPC. > > [P] selected from submenu PPC allows you to redefine the complete color palette which determines the sequence of basic paint colors used to paint atoms. The prompt Palette description (partial) Input N, N color codes (0=esc) : gives a listing of the palette part which is used in the present atom painting, for the complete palette see above, and asks for a new (complete) color palette. The input starts with the palette size nptot (denoted N in the prompt) and is followed by nptot integers np(i), i=1,...nptot, defining the palette entries (pointing at basic paint colors). As an example, a palette of three entries (paint colors 7, 4, 11) would be input as " 3, 7, 4, 11 ". Different entries in the palette can have the same color code value thus allowing e.g. to show different lattice planes with the same color. Note that the palette redefinition may contain more entries than actually needed for the present lattice section or cluster. After input of a new color palette BALSAC returns to submenu PPC. Dummy input nptot = 0 leaves the present palette definition unchanged. > > [T] selected from submenu PPC displays a color test table (in a separate graphics window, Unix) showing all color definitions together with color numbers available inside BALSAC. This option is identical to option [T] of the basic paint color menu PPB described above. > > [,] selected from submenu PPC returns to the paint menu PP. > [W] selected from submenu PP moves to the color/shading workbench switching to graphics mode (DOS) or opening a graphics window (Unix). This allows you to change all basic and paint colors as well as ball shading angles in a very intuitive way using the mouse or a graphics pointer. Further details are given in Sec. 6.2.15.2. > [G] selected from submenu PP switches the gray switch flag fgr between "on" and "off" and shows the updated submenu PP. For fgr = "on" all screen colors are replaced by respective gray tones determined by the RGB transformation (r,g,b) -> (s,s,s) with s = 0.30*r + 0.59*g + 0.11*b after which plots and PostScript file output will use gray tones rather than colors, see also Sec. 5.4. > [T] selected from submenu PP displays a color test table (in a separate graphics window, Unix) showing all color definitions together with color numbers available inside BALSAC. This option is identical to option [T] of the basic paint color menu PPB described above. > [F] selected from submenu PP allows you to redefine the character font used in graphics windows. NOTE that this option is available only with the Unix/X.11 version of BALSAC. The prompt Input font name [fontname] ("-"=esc) : asks for a character string fontname (up to 30 characters) defining the font name to be used for text in graphics windows after which BALSAC returns to submenu PP. The previous font name fontname is shown in the prompt where valid names have to be consistent with the X.11 Windows standard. Examples are "8x13","8x13bold","9x15". > [X] selected from submenu PP plots the present lattice section (switching to graphics mode (DOS) or opening a graphics window (Unix)) or lists its atom coordinates depending on the plot/list mode defined in the graphics option, see Sec. 6.2.7. > [,] selected from submenu PP returns to the basic parameter menu P. next, previous Section / Table of Contents / Index