QTKit Thread Saftey and Screen Mimic

February 8th, 2006

I have received two support emails from customers stating that Screen Mimic crashes under the latest version of Quick Time (7.0.4).

After some investigation, I discovered that when the QTMovie object was being created, an exception was thrown that stated:

QTMovieInitializedOnWrongThread

Evidently, sometime leading up to this version of QuickTime, someone at Apple realized that QTKit (The Cocoa wrapper to the QuickTime API) wasn’t completely thread safe.

So instead of issuing a warning or a fix, Apple decided to make a change to the API which prevented users from calling “movieWithQuickTimeMovie” from a background thread. Which unfortunately is what Screen Mimic 1.2 did.

Screen Mimic 1.2.1 addresses this problem by creating the QTMovie object on the main thread, and then sending it to the background thread as suggested here by Tim Monroe from QuickTime Engineering at Apple.

Other developers have mentioned this problem as well, but there is still no reference to it in the API documentation or anywhere on the ADC.

2 Responses to “QTKit Thread Saftey and Screen Mimic”

  1. At

    Thanks for this. It would have taken me a long time to figure this out if you hadn’t posted. Yours and one other blog are the only references to what happened. Nothing from Apple at all as far as I can see.

  2. At

    I cant seem to find the fix for the quicktime bug…I bought the program and when I upgraded QT…well u know the rest… Software crashes for me always. Can you spell it oput step by step…how to fix the bug…. I appreciate it. I really love the software.
    Thx

Leave a Reply