Search code examples
ioscore-animation

Is there a way to create a scrolling background(right to left) using Core Animator for Mac? (Swift 2 / Xcode)


I have the Core Animator software and I was wondering if there was any way to animate a scrolling background to export into Xcode?

Thank you!


Solution

  • Yea there is. Have you run through the tutorials, or the sample projects? They might help you get started.

    What you would want to do is make your background loop animation and then modify the generated source so the animation loops forever.

    backgroundAnimation.repeatCount = .infinity
    

    Not clear from your question if it's about Core Animator itself or the code to make it loop forever.