Transition animation shows previous contents

Christiaan Hofman <[email protected]>
Newsgroups gmane.comp.macosx.devel
Message-ID <[email protected]>
I am having problems showing a transitions using CoreAnimation.  
Basically, I am doing the following:

1. get a window containing a layer-hosting view (this is reused)
2. set the animation action for "contents" of the relevant layer to nil
3. set the contents of the layer to an initial CGImage
4. show the window
5. set the animation action for "contents" to a prepared CATransition
6. set the "contents" of the layer to a final CGImage

The problem is that the transition animation I get starts from the  
final image was from the /previous/ animation (or an empty image the  
first time), rather than starting with the initial image I set in step  
3.

I have tried various NSView and CALayer setNeedsDisplay and display  
methods in various places, but so far without any success.

Could anyone please tell me what I forget?

Thanks,
Christiaan
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.