help-octave
[Top][All Lists]
Advanced

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

Re: Graphics Objects -> Line Lists?


From: Martin Werner
Subject: Re: Graphics Objects -> Line Lists?
Date: Wed, 24 Aug 2011 09:27:42 +0200
User-agent: Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20110812 Thunderbird/6.0

Perfect, thank you very much. I guess, this could be added as a hint to the help line text...

Best regards,
  Martin

Am 23.08.2011 23:44, schrieb Michael Goffioul:
Try to insert NaN between each line segment. IIRC this is how "stem" function
is implemented.

Michael.


On Tue, Aug 23, 2011 at 12:34 PM, Martin Werner
<address@hidden>  wrote:
Hello all,

I am working with octave on a simulation system which relies on external
CAD-Data.

For the time being, the CAD-Data is externally rendered down to a list of
lines and imported in octave as a matrix, each row representing a lines
starting and endpoint.

LINES=[x1,y1,x2,y2;...]

Now, if I want to transport this data into a plot, I have severe performance
problems:

For a small CAD file (~200m^2) containing ~4500 lines, rendering them all
with a for loop using either plot or line command takes ~50 seconds.

for i = 1:size(LINES)(1);
   plot(LINES(...))
endfor

If I use a better type of plotting creating exactly one line object with
4500 lines, it is fast enough:

line([A(:,1),A(:,3)],[A(:,2),A(:,4)])

runs below 15ms. But of course, this does not what I want. It essentially
renders a line strip. Is there a possibility to render a line list in a fast
manner? Quickly diving into the code of plot,line and __do_line__
  functions, it seems to me, that there is no possibility to do that, am I
right?

Wouldn't it be good to have a plotting primitive set similar to OpenGL
rendering primitives:

GL_LINES, GL_LINESTRIP,GL_TRIANGLES,...


Am I missing something? The question in short:

Given a list of (many) independent lines, how can I (quickly) draw them to a
plot window?

Best regards,
  Martin Werner




--
Martin Werner
Mobile and Distributed Systems Group
Institute for Computer Science, Ludwig-Maximilians-Universität München
Room E 011, Oettingenstraße 67, 80538 Munich, Germany
Phone: +49 89 2180 9127
http://www.mobile.ifi.lmu.de/
_______________________________________________
Help-octave mailing list
address@hidden
https://mailman.cae.wisc.edu/listinfo/help-octave



--
Martin Werner
Mobile and Distributed Systems Group
Institute for Computer Science, Ludwig-Maximilians-Universität München
Room E 011, Oettingenstraße 67, 80538 Munich, Germany
Phone: +49 89 2180 9127
http://www.mobile.ifi.lmu.de/


reply via email to

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