• 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
CALayer renderInContext changes zPosition of some child layers
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CALayer renderInContext changes zPosition of some child layers


  • Subject: CALayer renderInContext changes zPosition of some child layers
  • From: Markus Spoettl <email@hidden>
  • Date: Thu, 03 Jan 2013 09:46:13 +0100

Hello,

  I'm having a hard time understanding a problem with CALayer's -renderInContext:

I have a custom UIView with custom delegate-drawn sublayers. Almost everything renders correctly when I do this:

 [[view layer] renderInContext:aContext];

(the context is set up correctly and produces the expected result - an image). But some parts of the original view (which is visible on screen when rendering) are missing.

I've been debugging this one for quite a while until I realized that missing layers are not missing but somehow their zPosition got messed up so they ended up below another sibling layer.

Since the affected layers need to be siblings in the same parent layer I can't fix this by making them sub-layers to enforce the hierarchy.

Why does this happen and how can I fix it?

Regards
Markus
--
__________________________________________
Markus Spoettl
_______________________________________________

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

  • Follow-Ups:
    • Re: CALayer renderInContext changes zPosition of some child layers
      • From: David Duncan <email@hidden>
  • Prev by Date: Re: [SOLVED] Text Field Cells in Table View: Enabled and Editable not working
  • Next by Date: Re: scroll bars and visible rect
  • Previous by thread: Re: scroll bars and visible rect
  • Next by thread: Re: CALayer renderInContext changes zPosition of some child layers
  • Index(es):
    • Date
    • Thread