I have run into two fairly serious performance issues.
Issue 1: Performance on a PPC machine drops off a cliff. PPC machines that could play videos smoothly in the old version have unusable framerates on the new version. To the best of my belief, the only significant difference between the two (as far as video playback is concerned) is simply that the frames are being rendered with QC in the new version. Is there a known performance hit for Quartz Composer on PPC hardware? Is there some kind of optimization flag I need to set to target a build for PPC? I don't yet have PPC hardware to test on, so can't yet investigate directly. I'm trying to scrounge up some hardware now; I wasn't expecting to hear of factor-of-ten (or more!) type slowdowns from the PPC crowd.

There's no severe inherent performance hit from using PPC as far as I've seen. Depending on how you're feeding images to QC, it might be doing colorspace conversions (BGRA->ARGB or whatever) or some other bookkeeping that takes a long time. What size video are you typically using? SD? HD? For smaller video, I wouldn't expect the performance hit to be too severe if it was in fact color space conversion.

Do you have any technical users that could use Shark to profile it, and see what the hangup is?

Issue 2: NSOpenGLCPSwapInterval. When I force vertical sync with NSOpenGLCPSwapInterval, QC rendering on the display link callback thread will frequently stall when the main thread is busy, such as during a big GUI redraw of the application's workspace window. If I turn off vertical sync then the stalls cease, but of course then I get tearing. Is there some way to both enforce vertical sync and also keep QC rendering at a consistent rate on the background threads?


Since you're using a QCRenderer, are you using a CVDisplayLink to render it? This will render on a separate thread, which usually won't stall on GUI updates (QCViews, and QCRenderers that are rendered with the main thread will compete with GUI drawing, and will stall frequently -- this sounds like what's happening, but it's difficult to tell from casual inspection. it appears that you are in fact using display links, but I don't know the structure of the app). Or, perchance, is the GUI update/display code in the display link thread (by design or mistake)? I've seen a number of weird quirks where GUI updates inadvertently happen on display link threads due to simple mistakes. Or are any synchronization blocks or locks in place that could be in conflict?

Otherwise, the composition is, as you said, very simple. Is there a reason you switched to QC from OpenGL for this? (there's no way you're going to realize a significant performance benefit from QC when you're drawing a single mostly unfiltered quad.)

--
[ christopher wright ]
[email protected]
http://kineme.net/

Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to