Adobe Scout and how to use ANT to enable Advanced Telemetry in FDT

Hello there,

So as you might have heard by now adobe just launched the Game Developer Tools in their Creative Cloud including the Adobe Gaming SDK 1.0 which includes the latest Adobe Flash platforms tools to get started creating cross-platform desktop and mobile games.

The SDK contains the following:

  • The AIR SDK 3.5 for compiling and packaging your mobile (AIR) and web (Flash Player) based games.
  • Native Extensions (ANE) Beta including extensions for iOS Game center, Product Store, SOcial, StageAD, BetaTesting.
  • Starling The 2D (Stage3D) open-source framework.
  • Feathers The 2D (Stage3D) open-source UI component framework.
  • Away3D The 3D open-source framework to power your 3D games.
  • ATF Tools Command-line utilities for the creation of ATF ( compressed textures) for Stage3D
  • Samples 3 Flash Builder 4.7 example Projects that use a combination of the tools included in the SDK.

Alongside the release of this SDK Adobe also released the first public beta of Adobe Scout (previously codenamed Monocle) the next-generation advanced profiling tool for Flash Player and AIR.

Quoting Adobe:

“Adobe Scout will revolutionize the way developers profile and optimize ActionScript based content. For the first time, developers have access to very granular information about CPU and GPU rendering, network or ActionScript stack.”

Which lead us to the second part of this post

Using ANT to enable Advanced Telemetry in FDT

So if you follow me on twitter or are a frequent reader of this blog you must know by  now that my weapon of choice for Flash Platform projects is FDT  so i wanted  to try the advanced features of Adobe Scout in my FDT projects, in order to use those advanced features Scout relies on the telemetry feature that was introduced in Flash Player 11.4 and Adobe AIR 3.4. This feature gathers detailed information about the internals of the Flash runtime, as well as the ActionScript code that it executes, and sends it all to Scout. To access all the data that is available, such as information on your ActionScript code and detailed information about DisplayList rendering and Stage3D, you need to enable advanced telemetry on your SWF.

If You’re a Flash Builder 4.7 user the enable advanced telemetry is built in so all you need to do is to click a checkbox in order to enable it. The FDT is currently working to implement an advanced telemetry option in the FDT IDE. But being the obsessive folk that i am i wanted to try those features “RIGHT NOW!” so i build a little ANT task file that enables advanced telemetry in your SWF by using a Python script (add-opt-in.py).

Heres how to use it:

To use this ANT task You need to have the following components:

1.- At least Adobe Flex 4.6 SDK with AIR 3.4 or the Flash Player 11.4.
Adobe Scout desktop application. You can find the Adobe Scout and the latest AIR SDK at:
http://gaming.adobe.com/

2.- In order to run the add-opt-in.py script  you’ll need to have python installed (I’m using Python 2.7.3 Mac OS X 64-bit/32-bit x86-64/i386)

Download Python at:
http://www.python.org/download/

3.- You can download or fork the add-opt-in.py script (it’s already included in this project in the scripts folder)  from:
https://github.com/adamcath/telemetry-utils

4.- Learn more about Adobe Scout reading the “Getting started with Adobe Scout” article by Thibault Imbert:
http://www.adobe.com/devnet/flashruntimes/articles/adobe-scout-getting-started.html

Here’s the ANT task project:

The Ant project has instructions and comments on how to use each of the tasks.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<!--?xml version="1.0" encoding="UTF-8"?-->
<?xml version="1.0" encoding="UTF-8"?>
<project name="Advanced Telemetry" default="03. Run Application">
	<!--/////////////////////// Project Properies //////////////////////-->
	<!-- Your Project's name -->
	<property name="project_name" value="AdvancedTelemetryAntExample"/>
	<!-- Your Project's source folder. -->
	<property name="src_dir" value="${basedir}/../../src/classes"/>
	<!-- Your Project's deploy folder. -->
	<property name="deploy.dir" value="${basedir}/../../bin"/>
	<!-- Your Project's script folder (where your Python Script is). -->
	<property name="scripts_dir" value="${basedir}/scripts"/>
	<!-- Path to the 'Main' or 'Document' class for your .SWF file.-->
	<property name="main_class" value= "${src_dir}/com/swfgeek/test/AdvancedTelemetryAntExample.as"/>
	<!-- Flag whether to compile the SWF for debugging.-->
	<property name="debug_enabled" value="false"/>
	<!-- The name of your swf file.-->
	<property name="swf_name" value="${deploy.dir}/AdvancedTelemetryAntExample"/>
	<!-- The launcher you'll be using once your SWF is compiled.
	The below values are applicable when using the swflauncher argument:
		External SWF Viewer
		Adobe Flash Player
		Browser
		Internal SWF Viewer
		AIR Debug Launcher -->
	<property name="launcher" value="Adobe Flash Player"/>
 
	<!-- The "Build SWF File" task will compile your SWF and add it to your deploy directory.-->
	<target name="01.Build SWF File">
		<fdt.launch.application 
			projectname="${project_name}" 
			mainclass="${main_class}" 
			debug="${debug_enabled}"  
    		target="${swf_name}.swf" 
    		startswf="false" 
    		swflauncher="${launcher}"/>
	</target>
 
	<!-- The "Add Advanced Telemetry" task will execute the add-opt-in.py thon script on  your SWF and add the  EnableTelemetry tag to for use with Adobe Scout (You can also run this task if you've already compiled the SWF).
	When adding [password] just after the ${swf_name}.swf advanced telemetry will only be visible
	if a matching password is entered in Adobe Scout. -->
	<target name="02. Add Advanced Telemetry"  depends="01.Build SWF File">
		<exec dir="${scripts_dir}" executable="python" failonerror="true">
		    <arg line="add-opt-in.py ${swf_name}.swf" />
		</exec>
	</target>
 
	<!-- The "Run Application" task is the default in your ANT project and will compile, add telemetry and run your SWF. Once your SWF is running you'll be able to see the Advanced Telemetry options in Adobe Scout.-->
	<target name="03. Run Application" depends="02. Add Advanced Telemetry">
		<fdt.loadProjectProperties/>
		<fdt.startSwf projectname="${project_name}" swflocation="${swf_name}.swf" swflauncher="${launcher}" />
	</target>
</project>

Examples

Here are the examples with advanced telemetry enabled, you can open both this SWFs in your browser and if you have Adobe Scout opened you’ll see the the advanced telemetry information the file outputs to Scout.

Starling Example (with a cool animated character stolen from Chris Georgenes).
Flash Display Example (just random color circles)

Here is the zipped project including the AdvancedTelemetryANT Project and the source code for compiling both examples:

Advanced Telemetry ANT Example Project

SWFObject 2.2 Released

swfobject_logo

SWFObject version 2.2 was recently released and it’s available on their Google Code Project,  after almost one year in development it comes with several new features and changes, some of them  listed below.

1.- Improved DomContentLoaded emulation for Internet Explorer:

2.- Dynamic Library support.

3.- Callback method for embbeding Flash Content.

4.- Propietary HTML embed no longer used.

5.- Improved Flash Player Detection for non- Internet Explorer browsers.

6.- Improved Adobe Express Install.

7.-Improved createCSS method.

8.-Detected user agents properties are now public via the swfobject.ua object.

9.- No more conditional compilation directives.

10.- The option to switch SWFObject’s default show/hide behavior.

To download the SWFObject 2.2 version visit SWFObject google project. and learn more about it’s new features.

Flex Builder gets renamed as Flash Builder

Flash Builder

So it finally happened  the IDE(Integrated development environment) known till now as Flex Builder it going to be    renamed as  Flash Builder , why ?  To me it’s easy It makes a lot more sense,  yes you can use the Flex Framework and yes you can use also build AIR apps and ActionScript 3.0 projects but at the end the result  its the same your project gets compiled as an .swf file , so maybe this rename of the IDE should have happened earlier,  it would have evited some confusion. This means that the Flex Framework it’s going to be renamed ? apparently no the flex framework stills and the Flex SDK stills the same but who better to explain it than Lee Brimelow and Duane “Chaos” Nickull check out their posts on the subject.

Hope this is the first step towards the process of integrating  the Flash tools and not just renaming them.  I haven’t used Flash IDE coding panel since who knows when, hope the Flash Builder and the Flash Professional IDES one day get along real well.

UPDATES:

Serge Jespers (Adobe Platform Evangelist ) explains in a little more detail why the renaming of Flex Builder to Flash Builder.

Keith Peters thoughts on Flash Builder

Ryan Stewart post Flex Builder “Gumbo” is Being Renamed Flash Builder

Lee Brimelow’s Flash Builder rebrand FAQ

Peter Elst Flex Builder gets rebranded to Flash Builder

Mihai Corlan (Adobe Platform Evangelist ) About the rebranding of Flex Builder into Flash Builder

Chuck Freedman The FlashFlex name game.

SWF Searchability a dream about to come true ?

Flash Player  SWF SEO

According to Adobe a long time headache for the developers of Flash Content its about to reach its end as Adobe is joining efforts with the major search industry leaders (A.K.A. Google & Yahoo), to optimize the way they index the Flash file format (SWF) , they claim that Google has already begun using their search spiders on live SWF Applications as if they where users, this thanks to Flash Player technology that Adobe has provide them. In the F.A.Q. that Adobe released today, they also say that as Developer you need to do nothing that all RIAS and content published under the SWF format will benefit from this although they’re beginning with the search of dynamic text and links in rich content created with Adobe Flash technology, and that it’s happening right now at least on Google.
To good to be true ? Let’s wait and see.

The Adobe SWF searchability FAQ

Adobe opens the SWF and FLV formats

Adobe has just dropped the licensing restrictions on the SWF and FLV formats as part of the open screen project .

Here’s an excerpt of the text in the Open Screen Project’s site.
The Open Screen Project is dedicated to driving consistent rich Internet experiences across televisions, personal computers, mobile devices, and consumer electronics. The Open Screen Project is supported by technology leaders, including Adobe, ARM, Chunghwa Telecom, Cisco, Intel, LG Electronics Inc., Marvell, Motorola, Nokia, NTT DoCoMo, Qualcomm, Samsung Electronics Co., Sony Ericsson, Toshiba and Verizon Wireless, and leading content providers, including BBC, MTV Networks, and NBC Universal, who want to deliver rich Web and video experiences, live and on-demand across a variety of devices.
Specifically, this work will include:

* Removing restrictions on use of the SWF and FLV/F4V specifications
* Publishing the device porting layer APIs for Adobe Flash Player
* Publishing the Adobe Flash® Cast™ protocol and the AMF protocol for robust data services
* Removing licensing fees – making next major releases of Adobe Flash Player and Adobe AIR for devices free.

What does this means for us developers ? It means that now you can use this formats to create players that read in this formats… exiting huhh !!!!.
More info and a video of Kevin Lynch Adobe CTO explaining more deeply what this means for the developer community visit the Developer section of the Open Screen Project on Adobe’s site.

Flash Player 9 (Flash Player 9,0,124,0) Security Update

Flash Player Update

Adobe hast just released (as a matter of fact on April 8 of 2008, but haven’t had the time to write this post until now) the Flash Player 9 (9,0,124,0), to strengthen the security of the player and to cover previous vulnerabilities.
This update will take effect on your content if:
Continue reading “Flash Player 9 (Flash Player 9,0,124,0) Security Update”