• 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: CALayer UIImage rendered on top of content instead of below
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CALayer UIImage rendered on top of content instead of below


  • Subject: Re: CALayer UIImage rendered on top of content instead of below
  • From: Kyle Sluder <email@hidden>
  • Date: Fri, 14 Dec 2012 15:37:16 -0800

On Dec 14, 2012, at 3:07 PM, Markus Spoettl <email@hidden> wrote:

> Hi,
>
>  I have custom UIView with multiple layers, all custom drawn via delegate. In one layer, I draw an image and on top of that image, I draw bezier paths and rects. Or so I try. For some reason the image is rendered ABOVE what I draw OVER it later.
>
> So basically I have this (this is the actual code I reduced it to):
>
> [img drawInRect:imgRect blendMode:kCGBlendModeNormal alpha:1.0];
>
> followed by
>
> [[UIColor redColor] setFill];
> UIRectFill(imgRect);
>
> I would expect to see a red rectangle, I get the image. Why? Would someone set me straight, I feel I'm missing something basic.

So if you create a new project, subclass UIView, and implement -drawLayer:inContext: like this, you get bad drawing?

--Kyle Sluder
_______________________________________________

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: 
 >CALayer UIImage rendered on top of content instead of below (From: Markus Spoettl <email@hidden>)

  • Prev by Date: Re: CALayer UIImage rendered on top of content instead of below
  • Next by Date: Re: NSWorkspace recycleURLs:completionHandler error -5000 (afpAccessDenied)
  • Previous by thread: Re: CALayer UIImage rendered on top of content instead of below
  • Next by thread: Correct way to make mutable and immutable objects?
  • Index(es):
    • Date
    • Thread