GithubHelp home page GithubHelp logo

calayer-speed-bug's Introduction

Setting CALayer speed < 1 drops frames in animation

Sample project for rdar://30143339

Summary:

If a CALayer has a speed set to a value lower than 1, frames are dropped when it animates (unless iOS is displaying a double height status bar)

Steps to Reproduce:

  1. Ensure your iOS device is not in a mode where it would display a double height status bar
  2. Create a UIView
  3. Set its layer’s speed to 0.1
  4. Add the view to the view hierarchy
  5. Animate the view’s position

Expected Results:

The view animates smoothly from one position to another 10 times slower than the duration set on the animation

Actual Results:

The view animates to the new position but 90% of the frames are dropped

Regression:

  • Reproduced on iPhone 6S running iOS 10.2, 5S running 10.2, and 5S running 10.0.2
  • Tested on iPad mini running iOS 9.3.5 and the issue does not reproduce there

Notes:

  • If you put the iOS device in a mode where it has a double height status bar (start GPS directions or a phone call for example) then the animation runs smoothly (and this is the case whether the app is currently displaying the status bar or not)
  • This behaviour also effects transition if you set the completionSpeed on UIPercentDrivenInteractiveTransition which I presume is in turn setting the CALayer's speed

calayer-speed-bug's People

Contributors

prendio2 avatar

Watchers

 avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.