28 March 2011
Experience with Flash Professional, developing Flash or AIR applications, and knowledge of ActionScript 3 programming.
Sample files require AIR 2.5 SDK (or later) or Flash Professional CS5.
Intermediate
To help developers jump-start their Adobe AIR for TV application development, we are providing several developer application tools that can help you test how your AIR for TV apps perform on a supported smart TV, and also help you understand some of the performance features of the TV hardware as you develop AIR for TV applications. You can download these sample application tools and source files at the top of this page.
If you don't have a supported smart TV, you can still design AIR applications for TV as well as learn best practices by running these AIR applications on your desktop computer:
The PerfMaster Deluxe application shows the performance of different operations that your AIR application might perform on an image, letting you choose from simple, common capabilities such as moving an image across the screen or rotating it and moving a vector across the screen. It compares different implementations of the same capability.
Suppose you want to move an image but you want to find out if it's faster to move a bitmap, a solid vector, or a vector image. PerfMaster shows you the performance of each option so that you can choose the best one for your application. For example, PerfMaster Deluxe illustrates how bitmap operations, including CacheAsBitmap, are generally highly accelerated on television hardware (see Figure 1).
PerfMaster Deluxe shows you a list of options, each of which lets you test a different kind of image:
Choose from among 58 tests by using the Up and Down arrow buttons on the AIR for TV device remote control (or keys on your desktop computer keyboard) to scroll through the list. As you navigate through the tests, PerfMaster shows a description of the highlighted test on the right side of the screen. For example, next to the test called Sletten Index, you'll see the description, "This calculates Pi using the Gregory-Leibniz series. This performs 50,000 loops each frame."
Once you select the test you want to run, press the OK button on the remote control (or the Enter key on the desktop keyboard) to run the test. The test runs for five seconds. The results appear in the bottom-right corner of the screen. Press the Left arrow to go back to select another test. The result of the test you just ran appears to the right of the test in the test list.
You can also choose to run every test by selecting the first item in the test list, Run All. When you select Run All and press OK (Enter), PerfMaster Deluxe runs each of the 58 tests sequentially. When it completes the tests, PerfMaster Deluxe returns to the list and displays the test results next to the names of each test automatically. Running all the tests this way takes about five minutes, since each test runs for five seconds.
You can use FontMaster Deluxe to enumerate available fonts and compare the way that fonts appear on a device (see Figure 2).
After you open the FontMaster Deluxe application, you'll see a list of font types. Choose the fonts you'd like to compare:
Use the Up and Down buttons/keys on the AIR for TV device remote control (or on the desktop keyboard) to navigate through each item in the list. Select the one you want to use by pressing the OK button on the remote or the Enter button on the desktop keyboard. You'll see a list of all the fonts in that category.
Use the Up and Down buttons/keys to scroll through the list of fonts and press OK (Enter) to pick a font. The Compare screen shows you the selected font with various ways of displaying it. If you're looking at fonts in the Device category, you can choose between Classic or TLF (Text Layout Framework) versions of fonts.
Here's how you control the font comparisons once you've selected a font:
The HogMaster Deluxe application illustrates how memory consumption grows as images are used in your application. Using the arrow keys, you can add various sized images to the stage and HogMaster Deluxe shows you how much memory has been used on screen (see Figure 3).
When you run HogMaster Deluxe, you will see a set of instructions for using the application. Here's how you control HogMaster Deluxe:
HogMaster Deluxe uses the corners of the screen to tell you what's going on in the application:
Download these sample application tools and source files at the top of this page. We hope you'll find these applications to be useful. Let us know what you think.
Special thanks to Adobe Digital Home engineering team members Don Woodward, who defined the sample application features, and John Simpson, who developed them.
This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License. Permissions beyond the scope of this license, pertaining to the examples of code included within this work are available at Adobe.