WWDC24 SALE: Save 50% on all my Swift books and bundles! >>

What you learned

Project 13 was a trivial application if you look solely at the amount of code we had to write, but it’s remarkable behind the scenes thanks to the power of Core Images. Modern iPhones have extraordinary CPU and GPU hardware, and Core Image uses them both to the full so that advanced image transformations can happen in real time – if you didn’t try project 13 on a real device, you really ought to if only to marvel at how incredibly fast it is!

You also met UIKit’s animation framework for the first time, which is a wrapper on top of another of Apple’s cornerstone frameworks: Core Animation. This is a particularly useful framework to get familiar with because of its simplicity: you tell it what you want (“move this view to position X/Y”) then tell it a duration (“move it over three seconds”), and Core Animation figures out what each individual frame looks like.

Here are just some of the other things you’ve now learned:

  • How to let the user select from a range of values using UISlider.
  • How to move, rotate, and scale views using CGAffineTransform.
  • Saving images back to the user’s photo library by calling the UIImageWriteToSavedPhotosAlbum() function.
  • Create Core Image contexts using CIContext, and creating then applying Core Image filters using CIFilter.
  • Changing sprite images without moving the sprite, using SKTexture.
  • Cropping a sprite so that only part of it is visible, using SKCropNode.
  • More SKActions, including moveBy(x:y:), wait(forDuration:), sequence(), and even how to run custom closures using run(block:).
  • The asyncAfter() method of GCD, which causes code to be run after a delay.
  • Plus you had more practice using UIImagePickerController, to select pictures from the user’s photo library. We’ll be using this again – it’s a really helpful component to have in your arsenal!
Save 50% in my WWDC sale.

SAVE 50% To celebrate WWDC24, all our books and bundles are half price, so you can take your Swift knowledge further without spending big! Get the Swift Power Pack to build your iOS career faster, get the Swift Platform Pack to builds apps for macOS, watchOS, and beyond, or get the Swift Plus Pack to learn advanced design patterns, testing skills, and more.

Save 50% on all our books and bundles!

Buy Pro Swift Buy Pro SwiftUI Buy Swift Design Patterns Buy Testing Swift Buy Hacking with iOS Buy Swift Coding Challenges Buy Swift on Sundays Volume One Buy Server-Side Swift Buy Advanced iOS Volume One Buy Advanced iOS Volume Two Buy Advanced iOS Volume Three Buy Hacking with watchOS Buy Hacking with tvOS Buy Hacking with macOS Buy Dive Into SpriteKit Buy Swift in Sixty Seconds Buy Objective-C for Swift Developers Buy Beyond Code

Was this page useful? Let us know!

Average rating: 4.9/5

Unknown user

You are not logged in

Log in or create account

Link copied to your pasteboard.