• 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 UIImageView for animations
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using UIImageView for animations


  • Subject: Re: Using UIImageView for animations
  • From: Robert Marini <email@hidden>
  • Date: Sun, 11 Jan 2009 13:06:34 -0500

As Glenn indicated, this is largely a factor of the size of the images. Layers are considerably lighter weight than Views (with the associated functionality loss). Of course, doing what you want to do - depending on the animation involved - might simply be having two image views and animating between then while changing their image backings (UIImageView is the presentation layer for a UIImage and so it is generally most appropriate to have only the max number of UIImageViews that you need to display at once in memory). Of course, if you absolutely need 20 images on screen at once to do something like the apple tv screensaver, I'd advise looking at layers as you may not always be able to control the size of the images.

-rob.

On Jan 11, 2009, at 12:04 PM, Glenn Bloom wrote:

I don't think I see this issue in my own code using UIImageView with a like
number of JPEG's. How large are yours? For a variety of reasons, I have
found that optimizing mine as 150KB or less each is acceptable for 480 * 320
pixel images. On the other hand, while speed appears fine (and I can easily
speed it up or slow it down by setting duration), I am just eyeballing it to
confirm that there are no skipped frames - my next step should be to use
Instruments to confirm this - I believe there is a Instrument that supports
doing this as well.
Message: 3
Date: Sat, 10 Jan 2009 12:01:46 -0800
From: Alex Strand <email@hidden>
Subject: Using UIImageView for animations
To: email@hidden
Message-ID: <email@hidden>
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes


Hi!

I'm taking a set of 10-20 jpegs that I'd like to animate.  I started
out just using a UIImageView using setAnimationImages: and everything
worked fantastically in the simulator but testing it on my device
basically makes it slow to the point where it is unresponsive.  I've
done some searching around and some people indicate that they are able
to use CALayers to get this same effect but before going down that
path I thought I would ask you folks.

What is the best way of doing this?

Alex
_______________________________________________

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

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

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: 
 >Re: Using UIImageView for animations (From: "Glenn Bloom" <email@hidden>)

  • Prev by Date: Re: 2 questions
  • Next by Date: Re: CALayer, CATextLayer, and inheritance . . .
  • Previous by thread: Re: Using UIImageView for animations
  • Next by thread: How to add a -(unsigned long long)unsignedLongLongValue method to NSString
  • Index(es):
    • Date
    • Thread