On 2 May '08, at 4:20 AM, Jean-Daniel Dupas wrote:
You can have a look at DistributedObject. I think you can publish a drawer object in your drawing thread and then, just call draw fro your main thread.
DO might be overkill for this scenario. The background thread really just needs to run a while() loop that waits on a condition-lock, then draws. The main thread's -drawRect: method just sets the condition on the lock to trigger the background thread.
If more information needs to be passed to the thread, you can use a producer/consumer queue, but unfortunately Foundation doesn't come with one of those built-in; there must be source code for one lying around, though.
—Jens
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]