• 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: NSViewAnimation choppy animations
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSViewAnimation choppy animations


  • Subject: Re: NSViewAnimation choppy animations
  • From: Ben Lachman <email@hidden>
  • Date: Fri, 23 Mar 2007 01:30:50 -0400

Joar,

The views are a set of custom views inside a split view. One is a container and the rest are small custom views that contain a search field, a box and a check box. None of the small views do any custom drawing and the container view only draws a gray wash bg. The animation slides the box and checkbox out from underneath the search field and adjusts the rest of the views accordingly. The view hierarchy is as follows:

Splitview
*	Container
*		CustomView
			NSSearchField
*			NSView
*				NSBox
					NSButton (switch/checkbox)

*		CustomView
			NSSearchField
*		CustomView
			NSSearchField
*		CustomView
			NSSearchField
etc.

Views that are animated are marked with a *. Only one custom view is animated with the box sliding out at a time. Obviously the fewer of these custom views I have the better the performance (and the less likely the user is to notice one out of sync).

After running the animation sequence through Shark it looks like the only call that is taking up much time (~14%) is an unknown library call (Unknown Library - 0xfffeff00 [92B]) made from within a bunch of appkit drawing code descending from NSWindow/NSView -displayIfNeeded, in particular recursive calls like _recursiveDisplayInRect2.

Hopefully that provides a bit more in depth explanation of the issue. I'm assuming from your response that NSViewAnimation doesn't have a limit to the number of views it can smoothly animate at once that you know of.


Let me know if anything is still unclear.

Thanks for the response,
->Ben
--
The user's going to pick dancing pigs over security every time. — Bruce Schneier


On Mar 22, 2007, at 10:16 PM, Joar Wingfors wrote:


On Mar 22, 2007, at 5:10 PM, Ben Lachman wrote:

Any suggestions on ways to make everything a bit smoother.


Use Shark to see what the problem really is. Before we know that, it's difficult for us to give you meaningful suggestions. It would probably also help if you could provide a bit more information on the types of views that are being animated. Custom, or Cocoa?

j o a r



_______________________________________________

Cocoa-dev mailing list (email@hidden)

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: 
 >NSViewAnimation choppy animations (From: Ben Lachman <email@hidden>)
 >Re: NSViewAnimation choppy animations (From: Joar Wingfors <email@hidden>)

  • Prev by Date: NSNull/NSarray .. count
  • Next by Date: Re: NSNull/NSarray .. count
  • Previous by thread: Re: NSViewAnimation choppy animations
  • Next by thread: setKeyEquivalent: gives two action invocations
  • Index(es):
    • Date
    • Thread