I have a CALayer
that needs to display frames of video. Every time a frame is rendered (as a CGImageRef
), this method is called:
- (void)displayFrame:(CGImageRef)frame {
[view layer].contents = (id)frame;
}
What's strange is that this, at first, will not display anything. Every time view
is resized, a new frame
is displayed, but sticks until view
is resized again.
How do I fix this?