CGContextStrokeLineSegments does improve performance significantly...
for my tiger users
To answer your question the line represents an oscilloscope.
Regards Nick
On 16 Jun 2005, at 16:06, Scott Thompson wrote:
Is there an optimization route for rendering lines >1.0f ?
The first thing that comes to mind is CGContextStrokeLineSegments.
This is a Tiger only routine that strokes lines very, very quickly.
If you can't be Tiger only, you should consider using
CGContextAddLines instead of explicitly using moveto-lineto-lineto....
If your path is very complex and intersects itself a lot then
turning off antialiasing may help (it's not clear what it's state
is in your sample code).
If you ask for a wider stroke, then the computer has to calculate
the joints between each segment. If having the joins perfect is
not as important, you might try using bevel joins instead of miter
or round joins. I don't know that bevel joins are faster to
calculate and render, but it might be worth a shot.
What do these lines represent? Is it strictly necessary to draw
800 of them? If you're trying to draw 800 lines in a window that's
only 300 pixels wide... you may be wasting a lot of time drawing
things that the user will never see.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartz-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartz-dev/email@hidden