Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.graphics.apps.gnuplot > #440 > unrolled thread
| Started by | Ingo Thies <ingo.thies@gmx.de> |
|---|---|
| First post | 2011-07-17 15:00 +0200 |
| Last post | 2011-07-17 18:59 +0200 |
| Articles | 7 — 2 participants |
Back to article view | Back to comp.graphics.apps.gnuplot
Postscript fill pattern broken? Ingo Thies <ingo.thies@gmx.de> - 2011-07-17 15:00 +0200
Filledcurves with manual color also broken? Ingo Thies <ingo.thies@gmx.de> - 2011-07-17 18:00 +0200
Re: Filledcurves with manual color also broken? sfeam <sfeam@users.sourceforge.net> - 2011-07-17 09:33 -0700
Re: Filledcurves with manual color also broken? Ingo Thies <ingo.thies@gmx.de> - 2011-07-17 18:39 +0200
Re: Filledcurves with manual color also broken? Ingo Thies <ingo.thies@gmx.de> - 2011-07-17 18:36 +0200
Re: Postscript fill pattern broken? sfeam <sfeam@users.sourceforge.net> - 2011-07-17 09:32 -0700
Re: Postscript fill pattern broken? Ingo Thies <ingo.thies@gmx.de> - 2011-07-17 18:59 +0200
| From | Ingo Thies <ingo.thies@gmx.de> |
|---|---|
| Date | 2011-07-17 15:00 +0200 |
| Subject | Postscript fill pattern broken? |
| Message-ID | <98g4n1F3o9U1@mid.individual.net> |
Hi, I have noticed some strange behaviour with fill patterns in Postscript. I don't know since when it is present, but at least gnuplot 4.4 or later (CVS version from July) seems to be affected. When I try to use pattern fill in Postscript the pattern for fillecurves appears to be extremely pixeled, rather than smooth as in the style test page. I am wondering how the patterns on the test page (i.e. with the command "test") are actually created. But obviously not using the actual commands for pattern-filled rectangles. Here is an example script (note that the current gnuplot syntax only works with data-based curves rather than functions for fill between two curves; for this reason 'set table' is used. If there is an easier way, please describe this in the manual, if not already done so): reset set term push set term postscript eps size 15cm,10cm "Helvetica" 20 set output 'testfill.eps' set samples 100 set xrange [-2.*pi:+2.*pi] set yrange [-1.1:2.4] set table 'tmp.asc' plot sin(x)+0.5 unset table set style fill pattern 4 plot 'tmp.asc' u 1:($2-0.5):($2+0.5) w filledcu unset output set term pop I would have expected that "fill pattern" would draw lines, but actually a pixeled pattern is used (use the magnifying function in ghostview). But please note that the sample pattern in the key looks OK, only the plotted pattern looks chunky. Is there a workaround, or is this an old and not yet resolved bug? Best whishes, Ingo
[toc] | [next] | [standalone]
| From | Ingo Thies <ingo.thies@gmx.de> |
|---|---|
| Date | 2011-07-17 18:00 +0200 |
| Subject | Filledcurves with manual color also broken? |
| Message-ID | <98gf95FjajU1@mid.individual.net> |
| In reply to | #440 |
Additional issue: manual selection of fillcolor seems to be broken, too. The following script returns a monochrome image although a dark red tone one has been set: reset set samples 100 set xrange [-2.*pi:+2.*pi] set yrange [-1.1:2.4] set table 'tmp.asc' set mxtics 2; set mytics 2 set format y "%.2f" plot sin(x)+0.5 unset table set style fill solid 1. plot 'tmp.asc' u 1:($2-0.5):($2+0.5) w filledcu lc rgb '#777777' Best wishes, Ingo
[toc] | [prev] | [next] | [standalone]
| From | sfeam <sfeam@users.sourceforge.net> |
|---|---|
| Date | 2011-07-17 09:33 -0700 |
| Subject | Re: Filledcurves with manual color also broken? |
| Message-ID | <ivv2sd$gbu$2@dont-email.me> |
| In reply to | #441 |
Ingo Thies wrote: > Additional issue: > > manual selection of fillcolor seems to be broken, too. The following > script returns a monochrome image although a dark red tone one has > been set: > > reset > set samples 100 > set xrange [-2.*pi:+2.*pi] > set yrange [-1.1:2.4] > set table 'tmp.asc' > set mxtics 2; set mytics 2 > set format y "%.2f" > plot sin(x)+0.5 > unset table > set style fill solid 1. > plot 'tmp.asc' u 1:($2-0.5):($2+0.5) w filledcu lc rgb '#777777' rgb "#777777" is grey, not dark red
[toc] | [prev] | [next] | [standalone]
| From | Ingo Thies <ingo.thies@gmx.de> |
|---|---|
| Date | 2011-07-17 18:39 +0200 |
| Subject | Re: Filledcurves with manual color also broken? |
| Message-ID | <98ghhcF5fuU2@mid.individual.net> |
| In reply to | #443 |
Am 2011-07-17 18:33, schrieb sfeam: > rgb "#777777" is grey, not dark red Ok, sorry. But I found that colors even disappear if set by hex (e.g. the above appears white rather than grey), e.g. '#ff0000' (should be read, but is nothing). Best wishes, Ingo
[toc] | [prev] | [next] | [standalone]
| From | Ingo Thies <ingo.thies@gmx.de> |
|---|---|
| Date | 2011-07-17 18:36 +0200 |
| Subject | Re: Filledcurves with manual color also broken? |
| Message-ID | <98ghdbF5fuU1@mid.individual.net> |
| In reply to | #441 |
Addition #2 Coloured filledcurves seem to work only if the colour is specified by name rather than by hexcode. Filed a bug (#3369407). The pattern problem, in contrast, may be caused by the antialiasing of gv, since it disappears when antialiasing is switched off. Best wishes, Ingo
[toc] | [prev] | [next] | [standalone]
| From | sfeam <sfeam@users.sourceforge.net> |
|---|---|
| Date | 2011-07-17 09:32 -0700 |
| Message-ID | <ivv2q7$gbu$1@dont-email.me> |
| In reply to | #440 |
Ingo Thies wrote: > Hi, > > I have noticed some strange behaviour with fill patterns in > Postscript. I don't know since when it is present, but at least > gnuplot 4.4 or later (CVS version from July) seems to be affected. > > When I try to use pattern fill in Postscript the pattern for > fillecurves appears to be extremely pixeled, rather than smooth as in > the style test page. Your test script produces an acceptable plot when run here. I suspect you have hit the well known long-standing bug in ghostscript that fails to correctly render pattern fill if antialiasing is enabled. Try turning off antialiasing in your viewer, or try sending the file to a real postscript printer rather than rendering it in ghostscript. Ethan > I am wondering how the patterns on the test page (i.e. with the > command "test") are actually created. But obviously not using the > actual commands for pattern-filled rectangles. > > Here is an example script (note that the current gnuplot syntax only > works with data-based curves rather than functions for fill between > two curves; for this reason 'set table' is used. If there is an easier > way, please describe this in the manual, if not already done so): > > reset > set term push > set term postscript eps size 15cm,10cm "Helvetica" 20 > set output 'testfill.eps' > set samples 100 > set xrange [-2.*pi:+2.*pi] > set yrange [-1.1:2.4] > set table 'tmp.asc' > plot sin(x)+0.5 > unset table > set style fill pattern 4 > plot 'tmp.asc' u 1:($2-0.5):($2+0.5) w filledcu > unset output > set term pop > > I would have expected that "fill pattern" would draw lines, but > actually a pixeled pattern is used (use the magnifying function in > ghostview). But please note that the sample pattern in the key looks > OK, only the plotted pattern looks chunky. > > Is there a workaround, or is this an old and not yet resolved bug? > > Best whishes, > > Ingo
[toc] | [prev] | [next] | [standalone]
| From | Ingo Thies <ingo.thies@gmx.de> |
|---|---|
| Date | 2011-07-17 18:59 +0200 |
| Message-ID | <98ginlFfpfU1@mid.individual.net> |
| In reply to | #442 |
Am 2011-07-17 18:32, schrieb sfeam: > I suspect you have hit the well known long-standing bug in ghostscript > that fails to correctly render pattern fill if antialiasing is enabled. > Try turning off antialiasing in your viewer, or try sending the > file to a real postscript printer rather than rendering it in > ghostscript. I will try the printer soon. But indeed, gv indeed failed to render the pattern in antialiasing mode. I remember that the error appeared earlier, but than it appeared just as a solid block instead of a pattern fill, or a solid fill didn't appear at all. I will look whether this might have caused the color fill issue; sorry again for the confusion I caused when mistakenly announcing a similar error with png or even standard terminal; it may definitely have been the postscript error. However, I could not reproduce this after some sort of panic (I have to submit a plot with such filled curves for a publication to the corresponding author of the paper as soon as possible). Please see my e-mail, too. Best wishes, Ingo
[toc] | [prev] | [standalone]
Back to top | Article view | comp.graphics.apps.gnuplot
csiph-web