WWDC 2015 Sample Code

Learn how to implement the latest Apple technologies with sample code from WWDC 2015 sessions.

  • AVCam-iOS: Using AVFoundation to Capture Images and Movies

    Demonstrates how to use the AVFoundation capture API to record movies and capture still images.

    Platforms
    • iOS
  • AVCamManual: Extending AVCam to Use Manual Capture API

    Demonstrates how to add manual controls for focus, exposure, and white balance to the AVCam sample application.

    Platforms
    • iOS
  • AVFoundationExporter: Exporting and Transcoding Movies

    A simple command-line utility that demonstrates using AVFoundation APIs for exporting and transcoding movies.

    Platforms
    • OS X
  • AVFoundationPiPPlayer: Picture-in-Picture Playback with AVKit

    Demonstrates how to use the AVPictureInPictureController class to implement picture-in-picture video playback.

    Platforms
    • iOS
  • AVFoundationQueuePlayer-iOS: Using a Mixture of Local File Based Assets and HTTP Live Streaming Assets with AVFoundation

    Demonstrates how to create a movie queue playback app using only the AVQueuePlayer and AVPlayerLayer classes of AVFoundation (not AVKit).

    Platforms
    • iOS
  • AVFoundationSimplePlayer-iOS: Using AVFoundation to Play Media

    Demonstrates how to create a simple movie playback app using only the AVPlayer and AVPlayerLayer classes from AVFoundation (not AVKit).

    Platforms
    • iOS
  • AVMetadataRecordPlay: Timed Metadata Capture Recording and Playback

    Demonstrates how to use AVFoundation capture APIs to record and play movies with timed metadata content.

    Platforms
    • iOS
  • AVMovieEditor: Editing the QuickTime File Format

    Demonstrates how to use AVMovie and AVMutableMovie to create a cut, copy, paste editor performing all edits in place with AVFoundation.

    Platforms
    • OS X
  • AVReaderWriter: Offline Audio / Video Processing

    Demonstrates how to use AVAssetReader and AVAssetWriter to perform offline processing of video and audio.

    Platforms
    • OS X
    • iOS
  • AdaptivePhotos: Using UIKit Traits and Size Classes

    Illustrates how to make your app universal and adaptive.

    Platforms
    • iOS
  • Advanced NSOperations

    Shows how to simplify app architecture by using the NSOperation class.

    Platforms
    • OS X
    • iOS
  • AdvancedCollectionView: Advanced User Interfaces Using Collection View

    Demonstrates code factoring, swipe to edit, drag reordering, and a sophisticated custom collection view layout.

    Platforms
    • iOS
  • AgentsCatalog: Using the Agents System in GameplayKit

    Demonstrates how to use the GameplayKit Agents system.

    Platforms
    • OS X
    • iOS
  • AlignmentGuides: AppKit Haptic Feedback Filtering using NSAlignmentFeedbackFilter

    Shows how to use the AppKit NSAlignmentFeedbackFilter class for haptic feedback filtering.

    Platforms
    • OS X
  • AstroLayout: Building Adaptive UI with Auto Layout

    Demonstrates how to properly activate and deactivate groups of constraints in response to a size class change, and how to animate layout changes using UIView animations.

    Platforms
    • iOS
  • AudioUnitV3Example: A Basic AudioUnit Extension and Host Implementation

    Demonstrates how to build an Audio Unit extension and host using the version 3 of the Audio Unit APIs.

    Platforms
    • iOS
  • CloudKit Catalog: An Introduction to CloudKit (Cocoa and JavaScript)

    Demonstrates the basics of using CloudKit on both iOS and JavaScript.

    Platforms
    • iOS
    • CloudKit JS
  • CocoaSlideCollection: Using NSCollectionView on OS X 10.11

    Demonstrates use of the NSCollectionView API added in OS X 10.11.

    Platforms
    • OS X
  • CompressionSample: Compressing Blocks and Streams of Data

    Demonstrates how to use functions from the Compression library to compress and decompress blocks or streams of data.

    Platforms
    • OS X
  • DemoBots: Building a Cross Platform Game with SpriteKit and GameplayKit

    Shows how to create a cross-platform game that provides the best possible experience on every supported device. DemoBots is a fully-featured 2D game built with SpriteKit and GameplayKit, and written in Swift 2.0.

    Platforms
    • OS X
    • iOS
  • Earthquakes: Populating a Core Data Store Using a Background Queue

    Shows how to populate a Core Data store using data retrieved on a background queue.

    Platforms
    • OS X
  • Emporium: A Simple Shopping Experience with Apple Pay

    Shows how to make Apple Pay payment requests, collect shipping and contact information, apply discounts for debit/credit cards, and use the Apple Pay button.

    Platforms
    • iOS
    • watchOS
  • Exhibition: An Adaptive OS X App

    Demonstrates techniques for making windows more adaptive.

    Platforms
    • OS X
  • Footprint: Indoor Positioning with Core Location

    Shows how to use Core Location's Indoor Location API. Also learn how to transform Geographic coordinates (Latitude/Longitude) to an image coordinate system.

    Platforms
    • iOS
  • ForceTouchCatalog: Using the Force Touch Trackpad API

    Demonstrates how to use the Force Touch Trackpad APIs.

    Platforms
    • OS X
  • FourInARow: Using the GameplayKit Minmax Strategist for Opponent AI

    Demonstrates how to use the GPMinmaxStrategist class to implement a computer-controlled opponent for turn-based, adversarial games.

    Platforms
    • iOS
  • Fox: Building a SceneKit Game with the Xcode Scene Editor

    Demonstrates how to build a SceneKit-based game using the Xcode Scene Editor.

    Platforms
    • OS X
    • iOS
  • HomeKit Catalog: Creating Homes, Pairing and Controlling Accessories, and Setting Up Triggers

    Demonstrates how to use the HomeKit API.

    Platforms
    • iOS
  • KeychainTouchID: Using Touch ID with Keychain and LocalAuthentication

    Shows how to use Touch ID with keychain items and how to invoke Touch ID authentication.

    Platforms
    • iOS
  • Lister (for watchOS, iOS, and OS X)

    A document based productivity app that showcases important features in iOS 9, OS X 10.11, and watchOS 2.0 including embedded frameworks, UI extensions, and other modern Cocoa features and design patterns.

    Platforms
    • OS X
    • iOS
    • watchOS
  • MetalKitEssentials: Using the MetalKit View, Texture Loader, and Model I/O

    Demonstrates how to use MetalKit on both iOS and OS X, including the MetalKit view, texture loader, and Model I/O.

    Platforms
    • OS X
    • iOS
  • MetalPerformanceShadersHelloWorld: An Intro to MetalPerformanceShaders

    Demonstrates how to use the basics of the MetalPerformanceShaders framework.

    Platforms
    • iOS
  • MusicMotion: Adding Motion Awareness to a Music App

    Demonstrates best practices for using the CoreMotion API.

    Platforms
    • iOS
  • PhotoProgress: Using NSProgress

    Demonstrates how to create and compose NSProgress objects, and show their progress in your app.

    Platforms
    • iOS
  • PotLoc: CoreLocation with iPhone and Apple Watch

    Demonstrates how to use the CoreLocation framework with Apple Watch and iPhone using iOS 9.0.

    Platforms
    • iOS
    • watchOS
  • SegueCatalog: Customizing and Unwinding with View Controller Containment

    Demonstrates how to use External References, how to combine UIStoryboardSegue subclasses, and how to use unwind segues.

    Platforms
    • iOS
  • ShapeEdit: Building a Simple iCloud Document App

    Demonstrates best practices for building a modern document-based app that integrates with iCloud Drive APIs.

    Platforms
    • iOS
  • SignalProcessing: Using Biquadratic Filter Functions

    This sample illustrates the use of functions from the Accelerate/vDSP for filtering a stereo signal with cascading biquadratic IIR filters.

    Platforms
    • OS X
  • StickyCorners: Using UIFieldBehavior and other UIDynamicBehaviors

    StickyCorners showcases the usage of UIFieldBehavior using UIKit Dynamics.

    Platforms
    • iOS
  • StoreKitSuite

    StoreKitSuite is a set of sample code projects that demonstrates how to implement In-App Purchase.

    Platforms
    • iOS
  • UICatalog: Creating and Customizing UIKit Controls

    Demonstrates how to create and customize user interface controls in UIKit whether you are using Objective-C or Swift.

    Platforms
    • iOS
  • WatchKitAudioRecorder: Audio Recording and Playback

    Demonstrates how to use the WKInterfaceController class to perform an audio recording.

    Platforms
    • watchOS
  • WatchKitMoviePlayer: Using WKInterfaceMovie for Video Playback

    Demonstrates how to use WatchKit elements to perform local video playback.

    Platforms
    • watchOS
  • WebKitPhotoBrowser: Using Modern Web Techniques in WebKit

    Shows how to use many of the WebKit techniques introduced in Safari 9, including backdrop filters, scroll snap effects, and force touch support.

    Platforms
    • OS X
    • iOS
    • Safari
    • Safari (Mobile)