• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to draw from a thread.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to draw from a thread.


  • Subject: Re: How to draw from a thread.
  • From: j o a r <email@hidden>
  • Date: Thu, 9 Jun 2005 08:32:56 -0700

Hej!

On 9 jun 2005, at 07.36, Tommy Nordgren wrote:

I've got a fractal drawing application written in Cocoa.
Because the main window takes a significant time to render, I wonder how I can do
to update the window from a separate Thread.
I know Carbon supports Multithreaded drawing, but what about Cocoa?
I'm using Mac OS X 10.4 Tiger.

You can draw from non-main threads, check the documentation:

<http://developer.apple.com/documentation/Cocoa/Conceptual/ Multithreading/articles/CocoaSafety.html#//apple_ref/doc/uid/ 20000736-123351-BBCFIIEB>

You might know that the animations in buttons and progress indicators on Mac OS X is driven by a thread called the "heartbeat" thread. It most likely uses this type of implementation to do it's drawing.

j o a r


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

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >How to draw from a thread. (From: Tommy Nordgren <email@hidden>)

  • Prev by Date: Re: NSTableView, its data source, and their document.
  • Next by Date: Multi-User using Core Data?
  • Previous by thread: How to draw from a thread.
  • Next by thread: Core Data date defaults
  • Index(es):
    • Date
    • Thread