help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

fill doesn't appear in png?


From: hydrodog
Subject: fill doesn't appear in png?
Date: Mon, 24 Mar 2014 13:57:45 -0700 (PDT)

The following script looks good on the screen, but the fill disappears on the
saved png.
Is this a known bug? Is there anything I can do about it?

# plot functions for numerical integration practice
function plotfuncs()
  close all
  plotpowerx([3,5], 'x.^5');
end

function plotpowerx(xr, ystr)
  x = xr(1):(xr(2)-xr(1))/500:xr(2); # generate enough points for graph
  x = [x x(end) x(1)]; # append duplicate last and first element
  y = eval(ystr);  # evaluate the y which will compute based on all the x
  y(end-1)= 0;
  y(end)=0;   # last 2 values of y should be zero to complete polygon
  fill(x,y);
  titlestr = ['y=' ystr];
  title(titlestr, 'FontSize', 20);
  filename=['area' ystr(1) ystr(4) '.png'];
  disp(filename);
  drawnow();
  saveas(gcf, filename, 'png');
end




--
View this message in context: 
http://octave.1599824.n4.nabble.com/fill-doesn-t-appear-in-png-tp4663304.html
Sent from the Octave - General mailing list archive at Nabble.com.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]