• 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: Using CALayer's renderInContext: method with geometryFlipped
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using CALayer's renderInContext: method with geometryFlipped


  • Subject: Re: Using CALayer's renderInContext: method with geometryFlipped
  • From: Graham Cox <email@hidden>
  • Date: Sun, 23 Oct 2011 10:19:36 +1100

On 22/10/2011, at 9:09 PM, Nial Giacomelli wrote:

> The PNG file that is ultimately generated renders the content
> correctly, but doesn't seem to takes the flipped geometry into account. I'm
> obviously looking for test.png to accurately represent the content shown to
> the left.


When -renderInContext: is invoked, the CALayer captures that content as an image and when it's displayed by the OpenGL system the geometry is applied. So none of the geometric properties, transforms, etc apply at that time - they are applied to display that content, not to generate it.

I think you may have the idea of -renderInContext: backwards - it's not invoked when the layer is drawn on screen, but to supply some content for the layer which is drawn later, with transformations.

I think you'll have to grab all the properties you want to apply and take them into account when generating your png image.

--Graham_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

References: 
 >Using CALayer's renderInContext: method with geometryFlipped (From: Nial Giacomelli <email@hidden>)

  • Prev by Date: Re: Core Data: Determine if managed object is deleted
  • Next by Date: Re: core data store type and icloud
  • Previous by thread: Using CALayer's renderInContext: method with geometryFlipped
  • Next by thread: CFRunLoopObserver causes crash on NSView drag.
  • Index(es):
    • Date
    • Thread