• 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: Efficiency Question...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Efficiency Question...


  • Subject: Re: Efficiency Question...
  • From: R <email@hidden>
  • Date: Tue, 06 Mar 2012 11:16:21 -0800 (PST)

Thanks to all!

Ron


On Mar 6, 9:24 am, Kyle Sluder <email@hidden> wrote:
> On Mar 5, 2012, at 11:21 PM, Graham Cox <email@hidden> wrote:
>
>
>
> > Is the goal to go from red to blue from left to right?
>
> > Why not add a single layer with red on the left, alpha = 1, and blue on the right, alpha = 1? I don't see why you need to composite two layers.
>
> > Drawing a gradient dynamically is probably more efficient than blitting a PNG, and will be resolution independent.
>
> These scenarios are rarely so cut and dry.
>
> If all you want is a simple gradient, then using a CAGradientLayer should be the fastest approach. It should result in zero backing store allocation.
>
> If you want to do something more complex, you might well do best to load a PNG and set it as the layer's content, rather than perform the rendering yourself. Tour VRAM usage will be known, and drawing your layer will involve zero CPU usage or texture uploads.
>
> It all depends on your willingness to accept visual artifacts, the size constraints of your binary, and what Instruments tells you is e best approach.
>
> --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
>
>
> This email sent to email@hidden

_______________________________________________

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: 
 >Efficiency Question... (From: R <email@hidden>)
 >Re: Efficiency Question... (From: Graham Cox <email@hidden>)
 >Re: Efficiency Question... (From: Kyle Sluder <email@hidden>)

  • Prev by Date: Re: JSON validator for Xcode
  • Next by Date: Accessing array in thread safe way
  • Previous by thread: Re: Efficiency Question...
  • Next by thread: How do we know if iCloud actually contains a key/value pair?
  • Index(es):
    • Date
    • Thread