For a initial time given Apple introduced a Apple TV in 2007, eccentric developers can now build applications for a hardware, interjection to Apple’s recover yesterday of a tvOS program growth pack (SDK).
The demo of a revamped Apple TV with tvOS flew by during Apple’s large Hey Siri event. But a tvOS formula and support are out there now, so developers can take a demeanour and see if they’d like to build for it. And non-technical forms quite meddlesome in a new Apple TV can also get a clarity of a capabilities by holding a demeanour during a developer tools.
We checked it out, and so should you. To assistance we along, I’ve put together a brief overview of what’s out there and what developers can do right now. (Hat tip to developer Rick Walter over during Made Up By People for creation a good educational video on tvOS, that desirous this article.)
Getting a tvOS SDK
The formula new Xcode 7.1 beta integrated growth sourroundings (IDE) comes with tvOS and a SDK, so you’ll wish to start by downloading that. You’ll need a latest book of OS X Yosemite, chronicle 10.10.5. Fair warning: updating your Mac could take 15 mins or longer, and downloading a 4.57GB Xcode beta record won’t occur instantly, either.
Once we have a new Xcode running, name “Create a new Xcode project” in a pop-up window, “tvOS,” and afterwards “Single View Application.” Give your app a product name and an classification identifier. Choose possibly Objective-C or Apple’s Swift programming language. Set it adult with Core Data and territory tests if we want, strike Next, and afterwards save a app to your desktop.
Hit a play symbol during a tip left dilemma of a window. At this indicate we might have to capacitate developer mode on your Mac and form in your mechanism account’s password. Go forward and do that.
A Simulator focus will cocktail up. You can make a window smaller by going to a Window dropdown menu, selecting Scale, and selecting, for instance, a 75 percent option.
To use a simulator for a remote, go to a Hardware dropdown menu and click Show Apple TV Remote. Hold down a choice pivotal and use your trackpad or rodent in a black block on a Apple TV Remote in sequence to copy regulating your finger to appropriate on a genuine remote. A prolonged press on a remote simulator, achieved by holding choice and holding your rodent down on a black square) will concede we to drag and dump an app to opposite positions in this menu.
You can otherwise use a arrow keys on your keyboard to navigate. You might have to strike a Menu symbol on a remote simulator a integrate of times to get that to work.
First, get a feel for a settings of a Apple TV.
Use a arrow keys or a remote simulator to name Settings and strike Enter. Note that a Menu symbol on a Remote brings we behind a screen. Unlike many iOS apps, Apple TV apps will not generally embody behind buttons.
You can do a lot with Settings. You can control screensaver options, nap options, a character of sealed captions, shade contrast, motion, parental controls, iTunes Store purchasing capabilities, multiplayer support, and plcae services. You can extent ad tracking, too.
Users can pointer in to iTunes to use apps and iCloud for storing app data. Users can pointer in to Game Center here as well. Users can also configure AirPlay in Settings.
You can bond remotes other than a central one for a new Apple TV, and we can spin high-definition previews of video calm in iTunes depending on a speed of your Internet connection. You can also confirm if we wish Apple TV to automatically or manually refurbish a software.
Now we can go and try building an app for a new Apple TV. So go behind to a Xcode application.
Building a exam app
In a plan navigator — a left mainstay of a window — you’ll find components standard of apps for iOS, like AppDelegate, ViewController, and Main.storyboard. Go to Main.storyboard. In a second column, click a triangle to enhance a View Control Scene section, and afterwards click a triangle to enhance a View Controller section.
With View Controller selected, click on a small block wedged between a curly braces and a rectangle nearby a bottom side of a right mainstay of Xcode — it represents a intent library — and in a calm box during a really bottom, form in “button”, and drag a few of them into a large becloud box only to a left, that is a View Controller. Hit a play symbol during a tip left again to see how it looks in a simulator. (You might need to set a active intrigue again as “Apple TV 1080p” underneath a tvOS Simulator bar to a right of a stop button.)
Navigate around regulating possibly a arrow keys or a remote simulator. (Apple has best practices for app pattern in pre-release support for tvOS here.) Go behind to Xcode’s intent library and demeanour around for other things we can add, including an Activity Indicator View, a Progress View, and a Navigation Bar.
If we wish, we can supplement calm to your app when it’s in a Top Shelf, that is located during a tip of a categorical menu. The Top Shelf is a place where Apple TV users can peek during featured calm from their 5 favorite apps. Go to a File dropdown menu, name New, and name Target, click Application Extension underneath tvOS, and strike Next. Give it a product name and strike Finish. Xcode will ask if we wish to activate this scheme, and we should click Activate. Then it will uncover adult in a left column. Click a triangle to enhance that section. The ServiceProvider.swift record is a critical one for adding calm like images to a Top Shelf.
Inside a ViewController.Swift territory in a left mainstay in Xcode, we can use a new Tap Gesture Recognizer, a Swipe Gesture Recognizer, and other user-experience inventions for a new Apple TV.
To try a garland of buttons, print views, and other user interface options for tvOS, download a new UIKit Catalog representation code. Unzip a record and run a plan “UIKitCatalog.xcodeproj”. Then strike a play button.
Apple has also prepared sample code for client-server apps, that arrangement calm in a new Apple TV markup language, or TVML. After we download and unzip a file, open a TVMLCatalog folder, run a “TVMLCatalog.xcodeproj” file, and strike a play button. In box we run into errors here, follow a instructions during a bottom of a project’s README.md record in Xcode.
Parallax Previewer app
You can install and run a Parallax Previewer beta app to see how certain images will demeanour with Apple’s nifty Parallax effect, that happens when we float over an app and kindly pierce your finger around it with a remote.
Using a app is as easy as attack a and pointer on a bottom left, uploading an picture (choose a print for example), and afterwards clicking a play symbol in a core during a bottom of a application.
You can get somewhat opposite effects if we spin a picture into an “Apple TV icon,” and we can change a credentials as well. If we wish to have some fun, try relocating your rodent around a box in a center of a application. You can trade customized parallax images in .LSR format.
The representation diversion Apple showed developers to denote iOS 9 progressing this year is also accessible for developers looking to know tvOS.
You can find it online. Unzip a file, name Swift, and open “DemoBots.xcodeproj”. Make certain to name “DemoBots (tvOS)” from a Active Scheme menu nearby a tip left in Xcode. Then press play. This one will take a notation or so to load. Hit a play-pause symbol on a remote simulator to get started.
This small run-through isn’t adequate to assistance us establish either a new Apple TV can turn as common as iPhones and iPads, with their mobile app store. Still, developers have a lot to play around with, and formed on what we’ve seen, there will shortly be many some-more Apple TV apps for consumers to name from.