octave-maintainers
[Top][All Lists]
Advanced

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

Re: more graphics changes.


From: Daniel J Sebald
Subject: Re: more graphics changes.
Date: Wed, 14 Mar 2007 20:00:09 -0600
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3) Gecko/20041020

John W. Eaton wrote:
I just checked in another largeish patch for graphics that moves all
the property database handling code to C++ (src/graphics.cc).  Other
than removing the .m files that were handling this task, there were
not many big changes.

The new code can do some things that the old could not, including
setting and removing default properties and setting factory defaults
in ways that should be compatible with Matlab.  For example,

  set (0, 'defaultlinelinewidth', 2);

sets the default line object linewidth property at the root level, and

  set (gcf, 'defaultlinelinewidth', 2);

does the same for the current figure.  And yes, that is
"defaultlinelinewidth".  The format is "default" + "graphics object
type name" + "property name".

You can use

  set (h, 'defaultlinelinewidth', 'remove')

to remove the default property and

  set (h, 'linewidth', 'factory')

to set a "factory default" value.

The code that traverses the property database and calls gnuplot is
still a .m file, but that seems to be fast enough, at least for
"small" plots.  For example, on my system with

  x = 1:1000;
  y = rand (1000, 100);

the command

  plot (x, y);

takes about .5 seconds, though it is another few seconds before
gnuplot renders the plot.

I definitely see a speed up. But there is still some lag. Something like "image" with the default image should be processed by gnuplot with little effort. With the latest, there is still a one to two second delay on my machine.

I recall when writing some of the image.m code and testing with various size images that the test image would plot almost immediately. Has there been a change in the pipe that causes it to pause when the buffer is full?

Dan


reply via email to

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