Slow object graphics when plotting multiple lines [message #92954] |
Fri, 01 April 2016 05:51  |
steven.abel
Messages: 13 Registered: April 2016
|
Junior Member |
|
|
I am new to object graphics and struggling to speed up a simple plot that contains multiple lines.
Here is an example that plots 200 lines - the object graphics version is very slow compared to the direct graphics version.
;create some dummy data
x = replicate(0.,11,200)
y = x
FOR i=0,199 DO x[*,i] = FINDGEN(11)
FOR i=0,199 DO y[*,i] = RANDOMN(seed,11)
;plot in direct graphics
plot,[0,10],[-5,5],/nodata,yrange=[-5,5],ystyle=1
FOR i=0,199 DO oplot,x[*,i],y[*,i]
;plot in object graphics
w = window()
w.REFRESH, /DISABLE
p = plot([0,10],[-5,5],/nodata,yrange=[-5,5],/current)
FOR i=0,199 DO !NULL=plot(x[*,i],y[*,i],/overplot)
w.REFRESH
Is there any way to speed this up in object graphics?
Thanks
Steve
|
|
|