Re: Data-dependent slowdown of NSBezierPath
Re: Data-dependent slowdown of NSBezierPath
- Subject: Re: Data-dependent slowdown of NSBezierPath
- From: Warren Nagourney <email@hidden>
- Date: Mon, 20 May 2002 00:28:17 -0700
Thanks, Scott.
Yes, it seems that crossings are the culprit. When I use *frequency* noise
of a certain amplitude, the ordering of the points is no longer monotonic
and some of the lines can cross.
Drawing the lines (1000 of them) separately slows things down enormously
(and removes most of the nice antialiasing).
-Cheers,
Warren Nagourney
--On Monday, May 20, 2002 1:45 AM -0400 Scott Anguish
<email@hidden> wrote:
On Monday, May 20, 2002, at 01:17 AM, Warren Nagourney wrote:
I have noticed a strange thing when using NSBezierPath: there is a
dramatic drawing slowdown when I display "noisy" data.
My application is a simulation of a Fourier Transform Spectrometer
which generates simulated data that depends upon several parameters and
then takes the Fourier transform (to retrieve the original spectrum).
It is extremely fast: with 1000 points of data, I can smoothly change
the various parameters (using sliders) and see the transform smoothly
change in the expected manner.
NSBezierPath bogs down badly when lines cross each other... the
noise might be causing this. It's because it actually has to compute out
the places where the lines write over each other (think about the
situation of using alpha, where the crossing points need to be computed
out)
If you're just using straight forward opaque colors, you might get a
speed increase by drawing the lines separately..
--------------------------------------------------------------------------
Warren Nagourney <email@hidden> Voice: 206-543-9585
University of Washington 206-543-0143
Physics Dept., Box 351560, Seattle, WA 98195 Fax: 206-685-0635
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.