Tag: Advanced Telemetry

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.

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)

<!--?xml version="1.0" encoding="UTF-8"?--><?xmlversion="1.0"encoding="UTF-8"?><projectname="Advanced Telemetry"default="03. Run Application"><!--/////////////////////// Project Properies //////////////////////--><!-- Your Project's name --><propertyname="project_name"value="AdvancedTelemetryAntExample"/><!-- Your Project's source folder. --><propertyname="src_dir"value="${basedir}/../../src/classes"/><!-- Your Project's deploy folder. --><propertyname="deploy.dir"value="${basedir}/../../bin"/><!-- Your Project's script folder (where your Python Script is). --><propertyname="scripts_dir"value="${basedir}/scripts"/><!-- Path to the 'Main' or 'Document' class for your .SWF file.--><propertyname="main_class"value= "${src_dir}/com/swfgeek/test/AdvancedTelemetryAntExample.as"/><!-- Flag whether to compile the SWF for debugging.--><propertyname="debug_enabled"value="false"/><!-- The name of your swf file.--><propertyname="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 --><propertyname="launcher"value="Adobe Flash Player"/><!-- The "Build SWF File" task will compile your SWF and add it to your deploy directory.--><targetname="01.Build SWF File"><fdt.launch.applicationprojectname="${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. --><targetname="02. Add Advanced Telemetry"depends="01.Build SWF File"><execdir="${scripts_dir}"executable="python"failonerror="true"><argline="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.--><targetname="03. Run Application"depends="02. Add Advanced Telemetry"><fdt.loadProjectProperties/><fdt.startSwfprojectname="${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.