From: Alan W. I. <ir...@be...> - 2006-08-03 17:19:57
|
On 2006-08-03 08:05-0700 Alan W. Irwin wrote: >> Another problem for me with the collor ps drivers that I could not find the >> simple way to get the black color (with white background). >> For plplot5.3.1 in yplot I find that plscol0,1,1,1,1 gives the perfectly >> black color. However its python conterpart plscol0(1,1,1,1) gives gray >> color. > > The first index in cmap0 is the special background colour index, and it must > be set before plinit in order for it to work at all. The simple way is > to use the -bg option on the command line. (Use the -h option on the > command line to see all the options available.) > I answered this part of your post too quickly without much thought. Obviously, it is the zero index which is the background so my comment about that case is not relevant to your issue. To answer your original question, to get black on white results just use -dev ps or -dev psttf rather than -dev psc or -dev psttfc. Note also to get true black you should specify plscol0(index,0,0,0), although since the allowed range is 0-255 (see http://plplot.sourceforge.net/docbook-manual/plplot-html-5.6.1/plscol0.html), specifying plscol0(index,1,1,1) should be indistinguishable from true black. I have just checked that with python, and that is indeed the case on my system with both -dev xwin and -dev psttfc. I had to change to plscol0(1,100,100,100) to get a grey result. I have no idea why you are getting a grey result with plscol0(1,1,1,1). Could you give more specifics such as a simple python test code that produces that result? Also, tell us your PLplot version, the devices that produce the grey result, etc. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); PLplot scientific plotting software package (plplot.org); the Yorick front-end to PLplot (yplot.sf.net); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ |